diff options
Diffstat (limited to 'test/files/pos')
-rw-r--r-- | test/files/pos/bug3972.scala | 11 | ||||
-rw-r--r-- | test/files/pos/bug4269.scala | 5 |
2 files changed, 16 insertions, 0 deletions
diff --git a/test/files/pos/bug3972.scala b/test/files/pos/bug3972.scala new file mode 100644 index 0000000000..5dfc10fcef --- /dev/null +++ b/test/files/pos/bug3972.scala @@ -0,0 +1,11 @@ +object CompilerCrash { + def main(args: Array[String]) { + args match { + case Array("a", a @ _*) => { } // The code compiles fine if this line is commented out or "@ _*" is deleted or this line is swapped for the next line + case Array("b") => { } // The code compiles fine if this line is commented out + case Array("c", c) => { + 0 // The code compiles fine if this line is commented out + } + } + } +} diff --git a/test/files/pos/bug4269.scala b/test/files/pos/bug4269.scala new file mode 100644 index 0000000000..99a30785b4 --- /dev/null +++ b/test/files/pos/bug4269.scala @@ -0,0 +1,5 @@ +class A { + PartialFunction.condOpt(Nil) { + case items@List(_*) if true => + } +} |