summaryrefslogtreecommitdiff
path: root/test/files/pos
diff options
context:
space:
mode:
authorHubert Plociniczak <hubert.plociniczak@epfl.ch>2010-10-01 17:10:27 +0000
committerHubert Plociniczak <hubert.plociniczak@epfl.ch>2010-10-01 17:10:27 +0000
commit256aca612204f1316e5281af6d10a14300d58ad1 (patch)
tree207ec6cdb99b473b9a21811d4d903ed75a289ed7 /test/files/pos
parent1148daec9c6aeba69d5d37fde877ab20b310db5b (diff)
downloadscala-256aca612204f1316e5281af6d10a14300d58ad1.tar.gz
scala-256aca612204f1316e5281af6d10a14300d58ad1.tar.bz2
scala-256aca612204f1316e5281af6d10a14300d58ad1.zip
Another attempt for #1591.
Diffstat (limited to 'test/files/pos')
-rw-r--r--test/files/pos/t1591_pos.scala7
-rw-r--r--test/files/pos/t1591b.scala13
2 files changed, 20 insertions, 0 deletions
diff --git a/test/files/pos/t1591_pos.scala b/test/files/pos/t1591_pos.scala
new file mode 100644
index 0000000000..4f55d7ce19
--- /dev/null
+++ b/test/files/pos/t1591_pos.scala
@@ -0,0 +1,7 @@
+trait A
+
+object Test {
+ lazy val a = new A {
+ object Zenek
+ }
+}
diff --git a/test/files/pos/t1591b.scala b/test/files/pos/t1591b.scala
new file mode 100644
index 0000000000..c671ad6472
--- /dev/null
+++ b/test/files/pos/t1591b.scala
@@ -0,0 +1,13 @@
+import scala.tools.nsc._
+
+class SemanticTokens(val compiler: Global) {
+ import compiler._
+
+ def build() = ErrorType
+
+ class Process {
+ def f() = analyzer
+ // or to crash the compiler instead of a nice message,
+ // def f() = analyzer underlying _
+ }
+}