File tree 1 file changed +1
-7
lines changed
compiler/src/dotty/tools/dotc/typer 1 file changed +1
-7
lines changed Original file line number Diff line number Diff line change @@ -471,7 +471,7 @@ class Typer extends Namer
471
471
checkStableIdentPattern(tree2, pt)
472
472
tree2
473
473
474
- def isLocalExtensionMethodRef : Boolean = { rawType match
474
+ def isLocalExtensionMethodRef : Boolean = rawType match
475
475
case rawType : TermRef =>
476
476
rawType.denot.hasAltWith(_.symbol.is(ExtensionMethod ))
477
477
&& ! pt.isExtensionApplyProto
@@ -484,7 +484,6 @@ class Typer extends Namer
484
484
}
485
485
case _ =>
486
486
false
487
- }
488
487
489
488
if ctx.mode.is(Mode .InExtensionMethod ) && isLocalExtensionMethodRef then
490
489
val xmethod = ctx.owner.enclosingExtensionMethod
@@ -2932,12 +2931,7 @@ class Typer extends Namer
2932
2931
def adaptOverloaded (ref : TermRef ) = {
2933
2932
val altDenots =
2934
2933
val allDenots = ref.denot.alternatives
2935
- def isIdent = tree match
2936
- case _ : Ident => true
2937
- case Select (qual, name) => qual.span.isZeroExtent
2938
- case _ => false
2939
2934
if pt.isExtensionApplyProto then allDenots.filter(_.symbol.is(ExtensionMethod ))
2940
- else if isIdent then allDenots.filterNot(_.symbol.is(ExtensionMethod ))
2941
2935
else allDenots
2942
2936
typr.println(i " adapt overloaded $ref with alternatives ${altDenots map (_.info)}% \n\n % " )
2943
2937
def altRef (alt : SingleDenotation ) = TermRef (ref.prefix, ref.name, alt)
You can’t perform that action at this time.
0 commit comments