Skip to content

Commit d52c3b2

Browse files
committed
Add topLevelClass and do not assume transformation of posttyper
1 parent 53e85d6 commit d52c3b2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ object Inliner {
165165
case _ =>
166166
val transformed = super.transform(tree)
167167
enclosingInlineds match {
168-
case call :: _ if call.symbol != ctx.owner.topLevelClass =>
168+
case call :: _ if call.symbol.topLevelClass != ctx.owner.topLevelClass =>
169169
// reposition tree inlined from some other file
170170
transformed.withPos(inlinedAtPos)
171171
case _ => transformed

0 commit comments

Comments
 (0)