summaryrefslogtreecommitdiff
path: root/test/files/neg/aladdin1055
diff options
context:
space:
mode:
Diffstat (limited to 'test/files/neg/aladdin1055')
-rw-r--r--test/files/neg/aladdin1055/A.scala6
-rw-r--r--test/files/neg/aladdin1055/Test_1.scala5
2 files changed, 11 insertions, 0 deletions
diff --git a/test/files/neg/aladdin1055/A.scala b/test/files/neg/aladdin1055/A.scala
new file mode 100644
index 0000000000..862336e30c
--- /dev/null
+++ b/test/files/neg/aladdin1055/A.scala
@@ -0,0 +1,6 @@
+object A {
+ sealed trait T { def f: Int }
+ class TT extends T { def f = 0 }
+
+ def foo = new T { def f = 1 } // local subclass of sealed trait T
+}
diff --git a/test/files/neg/aladdin1055/Test_1.scala b/test/files/neg/aladdin1055/Test_1.scala
new file mode 100644
index 0000000000..39d9b1dc98
--- /dev/null
+++ b/test/files/neg/aladdin1055/Test_1.scala
@@ -0,0 +1,5 @@
+object Test {
+ def foo(t: A.T) = t match {
+ case a: A.TT => 0
+ }
+}