|
| 1 | +class C1Inv[A] { type T } |
| 2 | +class C1Cov[+A] { type T } |
| 3 | +class C1Con[-A] { type T } |
| 4 | + |
| 5 | +class C2InvInv[A, B] { type T } |
| 6 | +class C2InvCov[A, +B] { type T } |
| 7 | +class C2InvCon[A, -B] { type T } |
| 8 | +class C2CovInv[+A, B] { type T } |
| 9 | +class C2CovCov[+A, +B] { type T } |
| 10 | +class C2CovCon[+A, -B] { type T } |
| 11 | +class C2ConInv[-A, B] { type T } |
| 12 | +class C2ConCov[-A, +B] { type T } |
| 13 | +class C2ConCon[-A, -B] { type T } |
| 14 | + |
| 15 | +@main def Test = |
| 16 | + println(classVariances[C1Inv]) |
| 17 | + println(classVariances[C1Cov]) |
| 18 | + println(classVariances[C1Con]) |
| 19 | + println(classVariances[C2InvInv]) |
| 20 | + println(classVariances[C2InvCov]) |
| 21 | + println(classVariances[C2InvCon]) |
| 22 | + println(classVariances[C2CovInv]) |
| 23 | + println(classVariances[C2CovCov]) |
| 24 | + println(classVariances[C2CovCon]) |
| 25 | + println(classVariances[C2ConInv]) |
| 26 | + println(classVariances[C2ConCov]) |
| 27 | + println(classVariances[C2ConCon]) |
0 commit comments