Browse files

more precise isMacroApplication check

Replaces the `symbol.isMacro` check with `symbol.isTermMacro`.
Doesn’t make any difference to trunk but helps a lot with macro annotations.
  • Loading branch information...
1 parent d2cee3a commit 34358ee1e884b2e760c5aec40d1f7d844b18053c @xeno-by xeno-by committed Nov 13, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/reflect/scala/reflect/internal/TreeInfo.scala
View
2 src/reflect/scala/reflect/internal/TreeInfo.scala
@@ -842,7 +842,7 @@ abstract class TreeInfo {
})
def isMacroApplication(tree: Tree): Boolean =
- !tree.isDef && tree.symbol != null && tree.symbol.isMacro && !tree.symbol.isErroneous
+ !tree.isDef && tree.symbol != null && tree.symbol.isTermMacro && !tree.symbol.isErroneous
def isMacroApplicationOrBlock(tree: Tree): Boolean = tree match {
case Block(_, expr) => isMacroApplicationOrBlock(expr)

0 comments on commit 34358ee

Please sign in to comment.