diff --git a/tests/pos/i3264.scala b/tests/pos/i3264.scala new file mode 100644 index 000000000000..08d98aa227dc --- /dev/null +++ b/tests/pos/i3264.scala @@ -0,0 +1,15 @@ +trait Foo[+F[_]] { + def bar: Bar[F] +} + +trait Bar[+F[_]] + +trait Base[+A] +trait Sub[A] extends Base[A] + +class Test { + def makeFoo(barSub: Bar[Sub]): Foo[Base] = + new Foo[Base] { + def bar/*: Bar[Base]*/ = barSub + } +}