summaryrefslogtreecommitdiff
path: root/test/files/run/lazy-locals.scala
diff options
context:
space:
mode:
authorIulian Dragos <jaguarul@gmail.com>2008-12-03 16:52:00 +0000
committerIulian Dragos <jaguarul@gmail.com>2008-12-03 16:52:00 +0000
commitc8107b0d95890b29ffebe101fc54ce0885511de4 (patch)
tree5ab6b29e313861f1ca3824485184bd7412b9fcc5 /test/files/run/lazy-locals.scala
parentc3c87411ce473b7f1f2e9638d682adbf27ea8b49 (diff)
downloadscala-c8107b0d95890b29ffebe101fc54ce0885511de4.tar.gz
scala-c8107b0d95890b29ffebe101fc54ce0885511de4.tar.bz2
scala-c8107b0d95890b29ffebe101fc54ce0885511de4.zip
Fixed #1358.
Diffstat (limited to 'test/files/run/lazy-locals.scala')
-rw-r--r--test/files/run/lazy-locals.scala6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/files/run/lazy-locals.scala b/test/files/run/lazy-locals.scala
index 324f7c00e4..000f4d2faf 100644
--- a/test/files/run/lazy-locals.scala
+++ b/test/files/run/lazy-locals.scala
@@ -133,6 +133,11 @@ object Test extends Application {
()
}
+ def testReturnInLazyVal: Boolean = {
+ lazy val go = { return false }
+ go
+ }
+
{
lazy val inCtor = "I am initialized when the constructor is run"
inCtor
@@ -155,4 +160,5 @@ object Test extends Application {
println(testLazyRecMany(5))
testRecVal
new CtorBlock
+ println(testReturnInLazyVal)
}