diff options
Diffstat (limited to 'test/files/run/patmatnew.scala')
-rw-r--r-- | test/files/run/patmatnew.scala | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/test/files/run/patmatnew.scala b/test/files/run/patmatnew.scala index 6ec3928757..d78be53eef 100644 --- a/test/files/run/patmatnew.scala +++ b/test/files/run/patmatnew.scala @@ -824,6 +824,21 @@ object Test extends TestConsoleMain { } } + object Ticket495bis { // compile-only + def signum(x: Int): Int = + x match { + case 0 => 0 + case _ if x < 0 => -1 + case _ if x > 0 => 1 + } + def pair_m(x: Int, y: Int) = + (x,y) match { + case (_, 0) => 0 + case (-1, _) => -1 + case (_, _) => 1 + } + } + object Ticket522 { // compile-only class Term[X] object App { |