diff options
Diffstat (limited to 'tests/run/t3980.scala')
-rw-r--r-- | tests/run/t3980.scala | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/run/t3980.scala b/tests/run/t3980.scala new file mode 100644 index 000000000..dbe9644ea --- /dev/null +++ b/tests/run/t3980.scala @@ -0,0 +1,19 @@ +object A { + def run1: Unit = { + lazy val x: Unit = {(); println("once")} + x + x + } + def run2: Unit = { + lazy val y: Int = 2 + println(y) + println(y) + } +} + +object Test { + def main(args: Array[String]) = { + A.run1 + A.run2 + } +} |