From 83d3f475da9ab4db3bb35613639e55008b39b495 Mon Sep 17 00:00:00 2001 From: Martin Odersky Date: Mon, 10 Mar 2008 12:00:03 +0000 Subject: 1. 2. Added * operator to RichString 3. changed zip in Array to accept arrays of different length 4. changed takeWhile/dropWhile in Array to yield Projections 5. Added Manifest types --- test/files/pos/manifest1.scala | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100755 test/files/pos/manifest1.scala (limited to 'test/files') 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) + +} -- cgit v1.2.3