We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 92a9d05 + ad6c683 commit 9917029Copy full SHA for 9917029
compiler/src/dotty/tools/dotc/core/TypeApplications.scala
@@ -429,7 +429,7 @@ class TypeApplications(val self: Type) extends AnyVal {
429
case dealiased: LazyRef =>
430
LazyRef(() => dealiased.ref.appliedTo(args))
431
case dealiased: WildcardType =>
432
- dealiased
+ WildcardType(dealiased.optBounds.appliedTo(args).bounds)
433
case dealiased: TypeRef if dealiased.symbol == defn.NothingClass =>
434
dealiased
435
case _ if typParams.isEmpty || typParams.head.isInstanceOf[LambdaParam] =>
tests/pos/i2219.scala
@@ -0,0 +1,7 @@
1
+object Test {
2
+ type Inv[T[_]] = T[_]
3
+
4
+ class Hi[T[_]](x: Inv[T]) {
5
+ def foo[T[_]](value: Inv[T] = x) = {}
6
+ }
7
+}
0 commit comments