aboutsummaryrefslogtreecommitdiff
path: root/tests/pos/t0002.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2014-03-10 11:06:49 +0100
committerMartin Odersky <odersky@gmail.com>2014-03-10 15:09:26 +0100
commitba8d9ea2e4b887fc0faa1f636aade84c45292144 (patch)
tree32df76e7d56184974e3f615131288601a8a97181 /tests/pos/t0002.scala
parentac45e122b76a454a06026f280197af0f72140903 (diff)
downloaddotty-ba8d9ea2e4b887fc0faa1f636aade84c45292144.tar.gz
dotty-ba8d9ea2e4b887fc0faa1f636aade84c45292144.tar.bz2
dotty-ba8d9ea2e4b887fc0faa1f636aade84c45292144.zip
Fix for t1002
Need to compile the self type of a class not in the context of the class members but one context further out. Reason: self type should not be able to see the members.
Diffstat (limited to 'tests/pos/t0002.scala')
-rw-r--r--tests/pos/t0002.scala6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/pos/t0002.scala b/tests/pos/t0002.scala
new file mode 100644
index 000000000..4c58ed3f4
--- /dev/null
+++ b/tests/pos/t0002.scala
@@ -0,0 +1,6 @@
+object main {
+ def main(args: Array[String]) = {
+ val b = true;
+ while (b == true) { }
+ }
+}