summaryrefslogtreecommitdiff
path: root/test/files/pos
diff options
context:
space:
mode:
Diffstat (limited to 'test/files/pos')
-rw-r--r--test/files/pos/bug1241.scala8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/files/pos/bug1241.scala b/test/files/pos/bug1241.scala
new file mode 100644
index 0000000000..333e6c5490
--- /dev/null
+++ b/test/files/pos/bug1241.scala
@@ -0,0 +1,8 @@
+object test extends Application {
+ // more..
+ type T = { def hello() }
+ //val x4 = new AnyRef { def hello() { println("4") } } // ok!
+ val x4: T = new { def hello() { println("4") } } // error!
+ x4.hello()
+ // more..
+}