diff options
Diffstat (limited to 'test/files/pos/bug1279a.scala')
-rw-r--r-- | test/files/pos/bug1279a.scala | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/test/files/pos/bug1279a.scala b/test/files/pos/bug1279a.scala index 7568d3afcd..9212b583d4 100644 --- a/test/files/pos/bug1279a.scala +++ b/test/files/pos/bug1279a.scala @@ -1,3 +1,4 @@ +// see #13 // providing the type parameter in the recursive call to all4Impl // avoids the problem @@ -31,8 +32,9 @@ abstract class M object Unrelated { - def all4Impl[U](first: M {type T <: U}): Stream[M {type T <: U}] = Stream.cons(first, all4Impl(first.next)) + // TODO!!! fix this bug for real, it compiles successfully, but weird types are inferred + // def all4Impl[U](first: M {type T <: U}): Stream[M {type T <: U}] = Stream.cons(first, all4Impl(first.next)) // compiles successfully -// def all4Impl[U](first: M {type T <: U}): Stream[M {type T <: U}] = Stream.cons(first, all4Impl[U](first.next)) + def all4Impl[U](first: M {type T <: U}): Stream[M {type T <: U}] = Stream.cons(first, all4Impl[U](first.next)) } |