diff options
Diffstat (limited to 'test/files/neg')
-rw-r--r-- | test/files/neg/bug2102.check | 6 | ||||
-rw-r--r-- | test/files/neg/bug2102.scala | 3 | ||||
-rw-r--r-- | test/files/neg/names-defaults-neg.check | 4 |
3 files changed, 11 insertions, 2 deletions
diff --git a/test/files/neg/bug2102.check b/test/files/neg/bug2102.check new file mode 100644 index 0000000000..075aa85e48 --- /dev/null +++ b/test/files/neg/bug2102.check @@ -0,0 +1,6 @@ +bug2102.scala:2: error: type mismatch; + found : java.util.Iterator[Int] + required: scala.Iterator[_] + val x: Iterator[_] = new java.util.ArrayList[Int]().iterator + ^ +one error found diff --git a/test/files/neg/bug2102.scala b/test/files/neg/bug2102.scala new file mode 100644 index 0000000000..6a85eba0ae --- /dev/null +++ b/test/files/neg/bug2102.scala @@ -0,0 +1,3 @@ +object Test { + val x: Iterator[_] = new java.util.ArrayList[Int]().iterator +}
\ No newline at end of file diff --git a/test/files/neg/names-defaults-neg.check b/test/files/neg/names-defaults-neg.check index 0a1ddf8286..f4ab2e5f99 100644 --- a/test/files/neg/names-defaults-neg.check +++ b/test/files/neg/names-defaults-neg.check @@ -94,10 +94,10 @@ List[Int]'s type parameters do not match type T's expected parameters: class Lis ^ error: type mismatch; found : List[Int] - required: List[List[List[List[X forSome { type X }]]]] + required: List[List[scala.List[List[X forSome { type X }]]]] names-defaults-neg.scala:80: error: type mismatch; found : List[Int] - required: List[List[?]] + required: scala.List[scala.List[?]] def test6[T](x: List[List[T]] = List(1,2)) = x ^ names-defaults-neg.scala:83: error: type mismatch; |