Skip to content

Commit b5bcb30

Browse files
committed
Drop redundant method
It turns out the faulty method should not even have existed since it was trying to duplicate functionality defined elsewhere.
1 parent e09a1f1 commit b5bcb30

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

compiler/src/dotty/tools/dotc/typer/Typer.scala

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3704,16 +3704,8 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
37043704
missingArgs(wtp)
37053705
}
37063706

3707-
def isContextFunctionRef(wtp: Type): Boolean = wtp.dealias match {
3708-
case RefinedType(parent, nme.apply, _) =>
3709-
isContextFunctionRef(parent) // apply refinements indicate a dependent CFT
3710-
case _ =>
3711-
val underlying = wtp.underlyingClassRef(refinementOK = false) // other refinements are not OK
3712-
defn.isContextFunctionClass(underlying.classSymbol)
3713-
}
3714-
37153707
def adaptNoArgsOther(wtp: Type, functionExpected: Boolean): Tree = {
3716-
val implicitFun = isContextFunctionRef(wtp) && !untpd.isContextualClosure(tree)
3708+
val implicitFun = defn.isContextFunctionType(wtp) && !untpd.isContextualClosure(tree)
37173709
def caseCompanion =
37183710
functionExpected &&
37193711
tree.symbol.is(Module) &&

0 commit comments

Comments
 (0)