diff options
Diffstat (limited to 'test/files/pos')
-rw-r--r-- | test/files/pos/t1648.scala | 4 | ||||
-rw-r--r-- | test/files/pos/t3943/Client_2.scala | 7 | ||||
-rw-r--r-- | test/files/pos/t3943/Outer_1.java | 14 | ||||
-rw-r--r-- | test/files/pos/t5692c.check | 0 | ||||
-rw-r--r-- | test/files/pos/t5692c.scala | 4 |
5 files changed, 25 insertions, 4 deletions
diff --git a/test/files/pos/t1648.scala b/test/files/pos/t1648.scala deleted file mode 100644 index 6d53ce11ee..0000000000 --- a/test/files/pos/t1648.scala +++ /dev/null @@ -1,4 +0,0 @@ -object Test { - class MyClass extends scala.util.logging.Logged { } - val x = new MyClass with scala.util.logging.ConsoleLogger -} diff --git a/test/files/pos/t3943/Client_2.scala b/test/files/pos/t3943/Client_2.scala new file mode 100644 index 0000000000..650ac9b7a9 --- /dev/null +++ b/test/files/pos/t3943/Client_2.scala @@ -0,0 +1,7 @@ +object Test { + val x: Child = new Child + x.getInner.foo("meh") +// error: type mismatch; +// found : java.lang.String("meh") +// required: E +} diff --git a/test/files/pos/t3943/Outer_1.java b/test/files/pos/t3943/Outer_1.java new file mode 100644 index 0000000000..1d38c5e76b --- /dev/null +++ b/test/files/pos/t3943/Outer_1.java @@ -0,0 +1,14 @@ +class Outer<E> { + abstract class Inner { + abstract public void foo(E e); + } +} + +class Child extends Outer<String> { + // the implicit prefix for Inner is Outer<E> instead of Outer<String> + public Inner getInner() { + return new Inner() { + public void foo(String e) { System.out.println("meh "+e); } + }; + } +} diff --git a/test/files/pos/t5692c.check b/test/files/pos/t5692c.check new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/test/files/pos/t5692c.check diff --git a/test/files/pos/t5692c.scala b/test/files/pos/t5692c.scala new file mode 100644 index 0000000000..fa5f0b2dcd --- /dev/null +++ b/test/files/pos/t5692c.scala @@ -0,0 +1,4 @@ +class C { + def foo[T: scala.reflect.ClassTag](xs: T*): Array[T] = ??? + foo() +}
\ No newline at end of file |