Skip to content

Commit e02a991

Browse files
committed
WIP
1 parent 9e85373 commit e02a991

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

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

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -438,6 +438,13 @@ class ReifyQuotes extends MacroTransformWithImplicits {
438438
val captured = mutable.LinkedHashMap.empty[Symbol, Tree]
439439
val captured2 = capturer(captured)
440440
outer.enteredSyms.foreach(s => capturers.put(s, captured2))
441+
if (ctx.owner.owner.is(Macro)) {
442+
outer.enteredSyms.foreach(s => {
443+
assert(s.is(Param))
444+
assert(s.owner == ctx.owner.owner)
445+
captured2(ref(s).asInstanceOf[RefTree])
446+
})
447+
}
441448
val tree2 = transform(tree)
442449
capturers --= outer.enteredSyms
443450
seq(captured.result().valuesIterator.toList, tree2)

0 commit comments

Comments
 (0)