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.
1 parent 4d79205 commit c084742Copy full SHA for c084742
compiler/src/dotty/tools/dotc/typer/Typer.scala
@@ -1071,9 +1071,11 @@ class Typer extends Namer
1071
*/
1072
lazy val calleeType: Type = untpd.stripAnnotated(fnBody) match {
1073
case ident: untpd.Ident if isContextual =>
1074
- val tp = typedIdent(ident, WildcardType).tpe.widen
+ val ident1 = typedIdent(ident, WildcardType)
1075
+ val tp = ident1.tpe.widen
1076
if defn.isContextFunctionType(tp) && params.size == defn.functionArity(tp) then
1077
paramIndex = params.map(_.name).zipWithIndex.toMap
1078
+ fnBody = untpd.TypedSplice(ident1)
1079
tp.select(nme.apply)
1080
else NoType
1081
case app @ Apply(expr, args) =>
0 commit comments