Skip to content

Commit 5b3c798

Browse files
committed
wip
1 parent fdf8522 commit 5b3c798

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

compiler/src/dotty/tools/dotc/transform/Splicing.scala

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,12 @@ class Splicing extends MacroTransform {
150150
case tree: RefTree =>
151151
if tree.isTerm then
152152
if quoteDefs.contains(tree.symbol) then
153-
splicedTerm(tree).spliced(tree.tpe.widenTermRefExpr)
153+
val tree1 = splicedTerm(tree)
154+
val tpe = tree.tpe.widenTermRefExpr match {
155+
case tpw: MethodicType => tpw.toFunctionType(isJava = false)
156+
case tpw => tpw
157+
}
158+
tree1.spliced(tpe)
154159
else super.transform(tree)
155160
else // tree.isType then
156161
if containsCapturedType(tree.tpe) then

0 commit comments

Comments
 (0)