summaryrefslogtreecommitdiff
path: root/test/files/neg/t7171.scala
diff options
context:
space:
mode:
Diffstat (limited to 'test/files/neg/t7171.scala')
-rw-r--r--test/files/neg/t7171.scala11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/files/neg/t7171.scala b/test/files/neg/t7171.scala
new file mode 100644
index 0000000000..534b2070a3
--- /dev/null
+++ b/test/files/neg/t7171.scala
@@ -0,0 +1,11 @@
+trait T {
+ final case class A()
+
+ // Was:
+ // error: scrutinee is incompatible with pattern type;
+ // found : T.this.A
+ // required: T#A
+ def foo(a: T#A) = a match {
+ case _: A => true; case _ => false
+ }
+}