From daa51685ecb8781a5db42813953918c2279c1093 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Fournier?= Date: Fri, 7 Aug 2020 02:38:45 +0200 Subject: [PATCH] Make JS visitor generic --- .../pmd/lang/ast/AstVisitorBase.java | 29 +-- .../ecmascript/ast/ASTArrayComprehension.java | 2 +- .../ast/ASTArrayComprehensionLoop.java | 2 +- .../lang/ecmascript/ast/ASTArrayLiteral.java | 2 +- .../lang/ecmascript/ast/ASTAssignment.java | 2 +- .../pmd/lang/ecmascript/ast/ASTAstRoot.java | 2 +- .../pmd/lang/ecmascript/ast/ASTBlock.java | 2 +- .../ecmascript/ast/ASTBreakStatement.java | 2 +- .../lang/ecmascript/ast/ASTCatchClause.java | 2 +- .../pmd/lang/ecmascript/ast/ASTComment.java | 2 +- .../ast/ASTConditionalExpression.java | 2 +- .../ecmascript/ast/ASTContinueStatement.java | 2 +- .../pmd/lang/ecmascript/ast/ASTDoLoop.java | 2 +- .../lang/ecmascript/ast/ASTElementGet.java | 2 +- .../ecmascript/ast/ASTEmptyExpression.java | 2 +- .../ecmascript/ast/ASTEmptyStatement.java | 2 +- .../ast/ASTExpressionStatement.java | 2 +- .../pmd/lang/ecmascript/ast/ASTForInLoop.java | 2 +- .../pmd/lang/ecmascript/ast/ASTForLoop.java | 2 +- .../lang/ecmascript/ast/ASTFunctionCall.java | 2 +- .../lang/ecmascript/ast/ASTFunctionNode.java | 2 +- .../lang/ecmascript/ast/ASTIfStatement.java | 2 +- .../ecmascript/ast/ASTInfixExpression.java | 2 +- .../ecmascript/ast/ASTKeywordLiteral.java | 2 +- .../pmd/lang/ecmascript/ast/ASTLabel.java | 2 +- .../ecmascript/ast/ASTLabeledStatement.java | 2 +- .../pmd/lang/ecmascript/ast/ASTLetNode.java | 2 +- .../pmd/lang/ecmascript/ast/ASTName.java | 2 +- .../lang/ecmascript/ast/ASTNewExpression.java | 2 +- .../lang/ecmascript/ast/ASTNumberLiteral.java | 2 +- .../lang/ecmascript/ast/ASTObjectLiteral.java | 2 +- .../ecmascript/ast/ASTObjectProperty.java | 2 +- .../ast/ASTParenthesizedExpression.java | 2 +- .../lang/ecmascript/ast/ASTPropertyGet.java | 2 +- .../lang/ecmascript/ast/ASTRegExpLiteral.java | 2 +- .../ecmascript/ast/ASTReturnStatement.java | 2 +- .../pmd/lang/ecmascript/ast/ASTScope.java | 2 +- .../lang/ecmascript/ast/ASTStringLiteral.java | 2 +- .../lang/ecmascript/ast/ASTSwitchCase.java | 2 +- .../ecmascript/ast/ASTSwitchStatement.java | 2 +- .../ecmascript/ast/ASTThrowStatement.java | 2 +- .../lang/ecmascript/ast/ASTTryStatement.java | 2 +- .../ecmascript/ast/ASTUnaryExpression.java | 2 +- .../ast/ASTVariableDeclaration.java | 2 +- .../ast/ASTVariableInitializer.java | 2 +- .../pmd/lang/ecmascript/ast/ASTWhileLoop.java | 2 +- .../lang/ecmascript/ast/ASTWithStatement.java | 2 +- .../lang/ecmascript/ast/ASTXmlDotQuery.java | 2 +- .../lang/ecmascript/ast/ASTXmlExpression.java | 2 +- .../lang/ecmascript/ast/ASTXmlMemberGet.java | 2 +- .../pmd/lang/ecmascript/ast/ASTXmlString.java | 2 +- .../ast/AbstractEcmascriptNode.java | 14 +- .../lang/ecmascript/ast/EcmascriptNode.java | 5 - .../ast/EcmascriptParserVisitor.java | 218 ++---------------- .../ast/EcmascriptParserVisitorAdapter.java | 9 +- .../ecmascript/ast/EcmascriptTreeBuilder.java | 9 +- .../ecmascript/ast/EcmascriptVisitor.java | 218 ++++++++++++++++++ .../ecmascript/ast/EcmascriptVisitorBase.java | 17 ++ .../rule/AbstractEcmascriptRule.java | 3 +- 59 files changed, 328 insertions(+), 294 deletions(-) create mode 100644 pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/EcmascriptVisitor.java create mode 100644 pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/EcmascriptVisitorBase.java diff --git a/pmd-core/src/main/java/net/sourceforge/pmd/lang/ast/AstVisitorBase.java b/pmd-core/src/main/java/net/sourceforge/pmd/lang/ast/AstVisitorBase.java index b2fc648550..4a26623efe 100644 --- a/pmd-core/src/main/java/net/sourceforge/pmd/lang/ast/AstVisitorBase.java +++ b/pmd-core/src/main/java/net/sourceforge/pmd/lang/ast/AstVisitorBase.java @@ -10,29 +10,10 @@ package net.sourceforge.pmd.lang.ast; */ public abstract class AstVisitorBase implements AstVisitor { - /** Initial value when combining values returned by children. */ - protected R zero() { - return null; - } - - /** - * Merge two values of type R, used to combine values returned by children. - * - * @param acc Current accumulated value for the previous siblings - * (or {@link #zero()} if the child is the first child) - * @param childValue Value for the new child - * - * @return New accumulated value to use for the next sibling - */ - protected R combine(R acc, R childValue) { - return acc; - } - /** * Visit the children. By default the data parameter is passed unchanged - * to all descendants. The {@link #zero() zero} and {@link #combine(Object, Object) combine} - * functions should be implemented if this is to return something else - * than null. + * to all descendants, and null is returned. Override this method to customize + * this behavior. * * @param node Node whose children should be visited * @param data Parameter of the visit @@ -41,12 +22,10 @@ public abstract class AstVisitorBase implements AstVisitor { */ // kept separate from super.visit for clarity protected R visitChildren(Node node, P data) { - R result = zero(); for (Node child : node.children()) { - R r1 = child.acceptVisitor(this, data); - result = combine(result, r1); + child.acceptVisitor(this, data); } - return result; + return null; } @Override diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTArrayComprehension.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTArrayComprehension.java index 660fdc1547..6700f1c08d 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTArrayComprehension.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTArrayComprehension.java @@ -12,7 +12,7 @@ public final class ASTArrayComprehension extends AbstractEcmascriptNode R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTArrayComprehensionLoop.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTArrayComprehensionLoop.java index d2705db202..f1c2459d22 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTArrayComprehensionLoop.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTArrayComprehensionLoop.java @@ -12,7 +12,7 @@ public final class ASTArrayComprehensionLoop extends AbstractEcmascriptNode R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTArrayLiteral.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTArrayLiteral.java index a3fea1f8e3..0d31e5ea05 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTArrayLiteral.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTArrayLiteral.java @@ -15,7 +15,7 @@ public final class ASTArrayLiteral extends AbstractEcmascriptNode } @Override - public Object jjtAccept(EcmascriptParserVisitor visitor, Object data) { + protected R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTAssignment.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTAssignment.java index 1ca45f45ce..04a3c928fd 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTAssignment.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTAssignment.java @@ -12,7 +12,7 @@ public final class ASTAssignment extends AbstractInfixEcmascriptNode } @Override - public Object jjtAccept(EcmascriptParserVisitor visitor, Object data) { + protected R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTAstRoot.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTAstRoot.java index ca2afd9f03..c87c140b95 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTAstRoot.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTAstRoot.java @@ -20,7 +20,7 @@ public final class ASTAstRoot extends AbstractEcmascriptNode implements } @Override - public Object jjtAccept(EcmascriptParserVisitor visitor, Object data) { + protected R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTBlock.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTBlock.java index 42f084523b..c4a7c1df2c 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTBlock.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTBlock.java @@ -12,7 +12,7 @@ public final class ASTBlock extends AbstractEcmascriptNode { } @Override - public Object jjtAccept(EcmascriptParserVisitor visitor, Object data) { + protected R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTBreakStatement.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTBreakStatement.java index babe207902..f5d52feb74 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTBreakStatement.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTBreakStatement.java @@ -13,7 +13,7 @@ public final class ASTBreakStatement extends AbstractEcmascriptNode R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTCatchClause.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTCatchClause.java index 9407d1e77c..986098b017 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTCatchClause.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTCatchClause.java @@ -12,7 +12,7 @@ public final class ASTCatchClause extends AbstractEcmascriptNode { } @Override - public Object jjtAccept(EcmascriptParserVisitor visitor, Object data) { + protected R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTComment.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTComment.java index 62900dd699..d4635fd374 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTComment.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTComment.java @@ -12,7 +12,7 @@ public final class ASTComment extends AbstractEcmascriptNode { } @Override - public Object jjtAccept(EcmascriptParserVisitor visitor, Object data) { + protected R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTConditionalExpression.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTConditionalExpression.java index 7fa0d3e449..0b55705c0c 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTConditionalExpression.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTConditionalExpression.java @@ -12,7 +12,7 @@ public final class ASTConditionalExpression extends AbstractEcmascriptNode R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTContinueStatement.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTContinueStatement.java index c47501ef7a..a24c838180 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTContinueStatement.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTContinueStatement.java @@ -13,7 +13,7 @@ public final class ASTContinueStatement extends AbstractEcmascriptNode R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTDoLoop.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTDoLoop.java index 6d579b5069..225da24d9a 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTDoLoop.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTDoLoop.java @@ -12,7 +12,7 @@ public final class ASTDoLoop extends AbstractEcmascriptNode { } @Override - public Object jjtAccept(EcmascriptParserVisitor visitor, Object data) { + protected R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTElementGet.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTElementGet.java index f689d2079c..80bf56bb1f 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTElementGet.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTElementGet.java @@ -12,7 +12,7 @@ public final class ASTElementGet extends AbstractEcmascriptNode { } @Override - public Object jjtAccept(EcmascriptParserVisitor visitor, Object data) { + protected R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTEmptyExpression.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTEmptyExpression.java index ad0d48abd0..94d0acb198 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTEmptyExpression.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTEmptyExpression.java @@ -12,7 +12,7 @@ public final class ASTEmptyExpression extends AbstractEcmascriptNode R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTEmptyStatement.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTEmptyStatement.java index 5e5a1abcce..44300258cd 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTEmptyStatement.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTEmptyStatement.java @@ -12,7 +12,7 @@ public final class ASTEmptyStatement extends AbstractEcmascriptNode R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTExpressionStatement.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTExpressionStatement.java index 9780b27117..28173de980 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTExpressionStatement.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTExpressionStatement.java @@ -13,7 +13,7 @@ public final class ASTExpressionStatement extends AbstractEcmascriptNode R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTForInLoop.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTForInLoop.java index 1df83c1d53..a97f348ff3 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTForInLoop.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTForInLoop.java @@ -12,7 +12,7 @@ public final class ASTForInLoop extends AbstractEcmascriptNode { } @Override - public Object jjtAccept(EcmascriptParserVisitor visitor, Object data) { + protected R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTForLoop.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTForLoop.java index 746435a92e..2405a2f3b6 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTForLoop.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTForLoop.java @@ -12,7 +12,7 @@ public final class ASTForLoop extends AbstractEcmascriptNode { } @Override - public Object jjtAccept(EcmascriptParserVisitor visitor, Object data) { + protected R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTFunctionCall.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTFunctionCall.java index 10d7404adf..4b338e3bac 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTFunctionCall.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTFunctionCall.java @@ -12,7 +12,7 @@ public final class ASTFunctionCall extends AbstractEcmascriptNode } @Override - public Object jjtAccept(EcmascriptParserVisitor visitor, Object data) { + protected R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTFunctionNode.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTFunctionNode.java index bc4d94055b..349358af93 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTFunctionNode.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTFunctionNode.java @@ -13,7 +13,7 @@ public final class ASTFunctionNode extends AbstractEcmascriptNode } @Override - public Object jjtAccept(EcmascriptParserVisitor visitor, Object data) { + protected R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTIfStatement.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTIfStatement.java index 8b407db87c..2abaa8a04f 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTIfStatement.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTIfStatement.java @@ -12,7 +12,7 @@ public final class ASTIfStatement extends AbstractEcmascriptNode { } @Override - public Object jjtAccept(EcmascriptParserVisitor visitor, Object data) { + protected R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTInfixExpression.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTInfixExpression.java index 9deb017a34..3283fc4a59 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTInfixExpression.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTInfixExpression.java @@ -12,7 +12,7 @@ public final class ASTInfixExpression extends AbstractInfixEcmascriptNode R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTKeywordLiteral.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTKeywordLiteral.java index 8d52211df1..dd64f99db3 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTKeywordLiteral.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTKeywordLiteral.java @@ -16,7 +16,7 @@ public final class ASTKeywordLiteral extends AbstractEcmascriptNode R acceptJsVisitor(EcmascriptVisitor visitor, P data) { return visitor.visit(this, data); } diff --git a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTLabel.java b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTLabel.java index 4c1b2bf161..7b1cc44bf6 100644 --- a/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTLabel.java +++ b/pmd-javascript/src/main/java/net/sourceforge/pmd/lang/ecmascript/ast/ASTLabel.java @@ -13,7 +13,7 @@ public final class ASTLabel extends AbstractEcmascriptNode