summaryrefslogtreecommitdiff
path: root/test/files/pos/manifest1.scala
diff options
context:
space:
mode:
Diffstat (limited to 'test/files/pos/manifest1.scala')
-rwxr-xr-xtest/files/pos/manifest1.scala20
1 files changed, 20 insertions, 0 deletions
diff --git a/test/files/pos/manifest1.scala b/test/files/pos/manifest1.scala
new file mode 100755
index 0000000000..4d3b3bfa48
--- /dev/null
+++ b/test/files/pos/manifest1.scala
@@ -0,0 +1,20 @@
+import scala.reflect.Manifest
+
+object Test {
+ def foo[T](x: T)(implicit m: Manifest[T]) {
+ foo(List(x))
+ }
+ foo(1)
+ foo("abc")
+ foo(List(1, 2, 3))
+ val x: List[Int] with Ordered[List[Int]] = null
+ foo(x)
+ foo[x.type](x)
+ abstract class C { type T = String; val x: T }
+ val c = new C { val x = "abc" }
+ foo(c.x)
+ abstract class D { type T; val x: T }
+ val d: D = new D { type T = String; val x = "x" }
+ foo(d.x)
+
+}