aboutsummaryrefslogtreecommitdiff
path: root/tests/pos/virtpatmat_exist_uncurry.scala
diff options
context:
space:
mode:
Diffstat (limited to 'tests/pos/virtpatmat_exist_uncurry.scala')
-rw-r--r--tests/pos/virtpatmat_exist_uncurry.scala6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/pos/virtpatmat_exist_uncurry.scala b/tests/pos/virtpatmat_exist_uncurry.scala
new file mode 100644
index 000000000..727922b31
--- /dev/null
+++ b/tests/pos/virtpatmat_exist_uncurry.scala
@@ -0,0 +1,6 @@
+object Test {
+ trait Leaf[T] {
+ def collect[U](f: PartialFunction[Leaf[_], U]): List[U]
+ def leaves: List[Leaf[T]] = collect { case l: Leaf[T] => l }
+ }
+}