summaryrefslogtreecommitdiff
path: root/test/files/jvm/t6941/Analyzed_1.scala
diff options
context:
space:
mode:
Diffstat (limited to 'test/files/jvm/t6941/Analyzed_1.scala')
-rw-r--r--test/files/jvm/t6941/Analyzed_1.scala11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/files/jvm/t6941/Analyzed_1.scala b/test/files/jvm/t6941/Analyzed_1.scala
new file mode 100644
index 0000000000..549abd5e64
--- /dev/null
+++ b/test/files/jvm/t6941/Analyzed_1.scala
@@ -0,0 +1,11 @@
+// this class's bytecode, compiled under -optimize is analyzed by the test
+// method a's bytecode should be identical to method b's bytecode
+class SameBytecode {
+ def a(xs: List[Int]) = xs match {
+ case x :: _ => x
+ }
+
+ def b(xs: List[Int]) = xs match {
+ case xs: ::[Int] => xs.hd$1
+ }
+} \ No newline at end of file