summaryrefslogtreecommitdiff
path: root/test/files/run/backreferences.scala
diff options
context:
space:
mode:
authorPaul Phillips <paulp@improving.org>2012-05-10 23:19:55 -0700
committerPaul Phillips <paulp@improving.org>2012-05-10 23:20:56 -0700
commitef32a8b9334307d15d9fa68d3da3f6f80b200788 (patch)
treee4727e50d595de563c8d6c6936389c4090e4db60 /test/files/run/backreferences.scala
parentdf10f921158ea13ce8fb53c8e15ec290ace69d83 (diff)
downloadscala-ef32a8b9334307d15d9fa68d3da3f6f80b200788.tar.gz
scala-ef32a8b9334307d15d9fa68d3da3f6f80b200788.tar.bz2
scala-ef32a8b9334307d15d9fa68d3da3f6f80b200788.zip
Removing redunant/passing tests from pending.
Diffstat (limited to 'test/files/run/backreferences.scala')
-rw-r--r--test/files/run/backreferences.scala13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/files/run/backreferences.scala b/test/files/run/backreferences.scala
new file mode 100644
index 0000000000..335cd6c7de
--- /dev/null
+++ b/test/files/run/backreferences.scala
@@ -0,0 +1,13 @@
+case class Elem[T](x: T, y: T)
+
+object Test {
+ def unrolled[T](x: Any, y: Any, z: Any) = (x, y, z) match {
+ case (el: Elem[_], el.x, el.y) => true
+ case _ => false
+ }
+
+ def main(args: Array[String]): Unit = {
+ println(unrolled(Elem("bippy", 5), "bippy", 6))
+ println(unrolled(Elem("bippy", 5), "bippy", 5))
+ }
+}