Skip to content

Commit 3f9987c

Browse files
committed
Preserve attachments in Mixin phase
1 parent 0736cd4 commit 3f9987c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ class Mixin extends MiniPhase with SymTransformer { thisPhase =>
226226
case _ =>
227227
val Apply(sel @ Select(New(_), nme.CONSTRUCTOR), args) = tree: @unchecked
228228
val (callArgs, initArgs) = if (tree.symbol.owner.is(Trait)) (Nil, args) else (args, Nil)
229-
(superRef(tree.symbol, tree.span).appliedToTermArgs(callArgs), Nil, initArgs)
229+
(superRef(tree.symbol, tree.span).appliedToTermArgs(callArgs).withAttachmentsFrom(sel), Nil, initArgs)
230230
}
231231

232232
val superCallsAndArgs: Map[Symbol, (Tree, List[Tree], List[Tree])] = (

0 commit comments

Comments
 (0)