diff options
author | Martin Odersky <odersky@gmail.com> | 2008-07-09 09:55:15 +0000 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2008-07-09 09:55:15 +0000 |
commit | 323fe887df30250c96c9945e28c1be85441cdc7f (patch) | |
tree | b7a6592179f0927df0ed2ed635d691e2d7330d47 /src/compiler/scala/tools/nsc/ast/TreeInfo.scala | |
parent | 1133f0f05f0767ca2548cf49ef633b48f021e6e0 (diff) | |
download | scala-323fe887df30250c96c9945e28c1be85441cdc7f.tar.gz scala-323fe887df30250c96c9945e28c1be85441cdc7f.tar.bz2 scala-323fe887df30250c96c9945e28c1be85441cdc7f.zip |
early initialization fixes.
fix: interface methods read by JavaParser are now deferred. fix: List
extends Product. fixes to Java : _* that make it possible to compile
ObjectRunner without warnings. NEW STARR
Diffstat (limited to 'src/compiler/scala/tools/nsc/ast/TreeInfo.scala')
-rw-r--r-- | src/compiler/scala/tools/nsc/ast/TreeInfo.scala | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/compiler/scala/tools/nsc/ast/TreeInfo.scala b/src/compiler/scala/tools/nsc/ast/TreeInfo.scala index 48fdfe0f7f..76feeef0e2 100644 --- a/src/compiler/scala/tools/nsc/ast/TreeInfo.scala +++ b/src/compiler/scala/tools/nsc/ast/TreeInfo.scala @@ -203,6 +203,13 @@ abstract class TreeInfo { case _ => false } + /** Is this argument node of the form <expr> : _* ? + */ + def isWildcardStarArg(tree: Tree): Boolean = tree match { + case Typed(expr, Ident(name)) => name == nme.WILDCARD_STAR.toTypeName + case _ => false + } + /** Is this pattern node a catch-all (wildcard or variable) pattern? */ def isDefaultCase(cdef: CaseDef) = cdef match { case CaseDef(Ident(nme.WILDCARD), EmptyTree, _) => true |