diff --git a/pmd/src/net/sourceforge/pmd/ast/ASTArguments.java b/pmd/src/net/sourceforge/pmd/ast/ASTArguments.java index 0e7ebaf09f..248491b35e 100644 --- a/pmd/src/net/sourceforge/pmd/ast/ASTArguments.java +++ b/pmd/src/net/sourceforge/pmd/ast/ASTArguments.java @@ -18,6 +18,7 @@ public class ASTArguments extends SimpleNode { } return this.jjtGetChild(0).jjtGetNumChildren(); } + /** Accept the visitor. **/ public Object jjtAccept(JavaParserVisitor visitor, Object data) { return visitor.visit(this, data); diff --git a/pmd/src/net/sourceforge/pmd/ast/ASTExplicitConstructorInvocation.java b/pmd/src/net/sourceforge/pmd/ast/ASTExplicitConstructorInvocation.java index 1cd66cabc8..1c6fe043b6 100644 --- a/pmd/src/net/sourceforge/pmd/ast/ASTExplicitConstructorInvocation.java +++ b/pmd/src/net/sourceforge/pmd/ast/ASTExplicitConstructorInvocation.java @@ -17,6 +17,10 @@ public class ASTExplicitConstructorInvocation extends SimpleNode { return visitor.visit(this, data); } + public int getArgumentCount() { + return ((ASTArguments)this.jjtGetChild(0)).getArgumentCount(); + } + private boolean isThis; private boolean isSuper; diff --git a/pmd/src/net/sourceforge/pmd/rules/SymbolTableTestRule.java b/pmd/src/net/sourceforge/pmd/rules/SymbolTableTestRule.java index aa922b3b37..d174e49a3f 100644 --- a/pmd/src/net/sourceforge/pmd/rules/SymbolTableTestRule.java +++ b/pmd/src/net/sourceforge/pmd/rules/SymbolTableTestRule.java @@ -11,7 +11,7 @@ import net.sourceforge.pmd.ast.ASTArguments; public class SymbolTableTestRule extends AbstractRule implements Rule { public Object visit(ASTExplicitConstructorInvocation node, Object data) { - System.out.println("ASTExplicitConstructorInvocation: arg count = " + ((ASTArguments)node.jjtGetChild(0)).getArgumentCount()); + System.out.println("ASTExplicitConstructorInvocation: arg count = " + node.getArgumentCount()); return super.visit(node,data); }