-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Open
Labels
itype:bugstat:needs triageEvery issue needs to have an "area" and "itype" labelEvery issue needs to have an "area" and "itype" label
Description
Compiler version
3.8.0-RC1-bin-20251002-b7cae74-NIGHTLY
Minimized code
trait R[T]:
extension (x: T) def m: T
trait S[T] extends R[T]
trait A[T]:
given R[T] = scala.compiletime.deferred
class B[T : S](x: T) extends A[T]:
override given S[T] = summon
x.m
Output
x.m
^
Found: (B.this.x : T)
Required: ?{ m: ? }
Note that implicit extension methods cannot be applied because they are ambiguous;
both given instance evidence$1 in class B and given instance given_S_T in class B provide an extension method `m` on (B.this.x : T)
Expectation
Should not be ambiguous since the typeclass instance is the same.
Metadata
Metadata
Assignees
Labels
itype:bugstat:needs triageEvery issue needs to have an "area" and "itype" labelEvery issue needs to have an "area" and "itype" label