Skip to content

Commit

Permalink
Update macro check
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolasstucki committed Oct 23, 2023
1 parent bb8cb81 commit 947c808
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,7 @@ class YCheckPositions extends Phase {
private def isMacro(call: Tree)(using Context) =
call.symbol.is(Macro) ||
(call.symbol.isClass && call.tpe.derivesFrom(defn.MacroAnnotationClass)) ||
// The call of a macro after typer is encoded as a Select while other inlines are Ident
// TODO remove this distinction once Inline nodes of expanded macros can be trusted (also in Inliner.inlineCallTrace)
(!(ctx.phase <= postTyperPhase) && call.isInstanceOf[Select])
(!(ctx.phase <= postTyperPhase) && call.symbol.is(Macro))

}

Expand Down

0 comments on commit 947c808

Please sign in to comment.