summaryrefslogtreecommitdiff
path: root/test/files/neg/t5189b.check
blob: 7f78cbb4383c92395bff9c3ac115a9011711af28 (plain) (blame)
1
2
3
4
5
6
7
8
t5189b.scala:25: error: type mismatch;
 found   : TestNeg.Wrapped[?T2] where type ?T2 <: T
 required: TestNeg.Wrapped[T]
Note: ?T2 <: T, but class Wrapped is invariant in type W.
You may wish to define W as +W instead. (SLS 4.5)
    case Wrapper/*[_ <: T ]*/(wrapped) => wrapped // : Wrapped[_ <: T], which is a subtype of Wrapped[T] if and only if Wrapped is covariant in its type parameter
                                          ^
one error found