diff options
Diffstat (limited to 'test/files/jvm')
-rw-r--r-- | test/files/jvm/OuterTParams.java | 6 | ||||
-rw-r--r-- | test/files/jvm/nest.check | 1 | ||||
-rw-r--r-- | test/files/jvm/nest.java | 21 | ||||
-rw-r--r-- | test/files/jvm/nest.scala | 10 |
4 files changed, 26 insertions, 12 deletions
diff --git a/test/files/jvm/OuterTParams.java b/test/files/jvm/OuterTParams.java deleted file mode 100644 index 1d3db49fcf..0000000000 --- a/test/files/jvm/OuterTParams.java +++ /dev/null @@ -1,6 +0,0 @@ -public class OuterTParams<A> { - class InnerClass { - // Cannot parse method signature: "()TA;" - public A method() { return null; } - } -} diff --git a/test/files/jvm/nest.check b/test/files/jvm/nest.check index 445369969e..dc63855b14 100644 --- a/test/files/jvm/nest.check +++ b/test/files/jvm/nest.check @@ -1,3 +1,4 @@ 2 3 10 +Instantiating public inner class: Inn Outer name x: 42 diff --git a/test/files/jvm/nest.java b/test/files/jvm/nest.java index 581eaa4972..3f6f0bebbd 100644 --- a/test/files/jvm/nest.java +++ b/test/files/jvm/nest.java @@ -14,4 +14,25 @@ public class nest { } } } + + + String name = "Outer name"; + + public class Inn { + int x; + + public Inn(int x) { + this.x = x; + } + + public void doSomething() { + System.out.println("Inn " + name + " x: " + x); + } + } + + protected class ProtInn { + public void doSomething() { + System.out.println("ProtInn " + name); + } + } } diff --git a/test/files/jvm/nest.scala b/test/files/jvm/nest.scala index 71f6064f31..60f3a3155f 100644 --- a/test/files/jvm/nest.scala +++ b/test/files/jvm/nest.scala @@ -14,11 +14,9 @@ object Test extends Application { val r = new nest.best.rest; Console.println(nest.best.rest.test.inc(2)) Console.println(nest.best.rest.x) -} -// bug #695 -object ForceParse extends OuterTParams[AnyRef] { - // Force import of HarderToParse<A>.InnerClass, - // which has confusing method signature. - var field: InnerClass = null + print("Instantiating public inner class: ") + val outer = new nest + val inn = new outer.Inn(42) + inn.doSomething } |