From 5697e1115b8895e06cb91a4a6e70d0f73e5aa9ab Mon Sep 17 00:00:00 2001 From: Lukas Rytz Date: Wed, 2 Dec 2009 16:20:48 +0000 Subject: another test for #2489 --- test/files/run/names-defaults.scala | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'test/files/run') diff --git a/test/files/run/names-defaults.scala b/test/files/run/names-defaults.scala index 0d4f3df42e..7e6fcf3f3c 100644 --- a/test/files/run/names-defaults.scala +++ b/test/files/run/names-defaults.scala @@ -268,6 +268,15 @@ object Test extends Application { // #2489 class A2489 { def foo { def bar(a: Int = 1) = a; bar(); val u = 0 } } + // a bug reported on the mailing lists, related to #2489 + class Test2489 { + def foo(): Int = { + val i = 10 + case class Foo(j: Int) + i + } + } + // DEFINITIONS def test1(a: Int, b: String) = println(a +": "+ b) def test2(u: Int, v: Int)(k: String, l: Int) = println(l +": "+ k +", "+ (u + v)) -- cgit v1.2.3