You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Introducing some abstractions into the AST (like done in #1759, argumented on the wiki) has a number of advantages, but the current rulechain implementation doesn't scale. Adding a rulechain visit to an abstract node type currently does nothing, instead of visiting all nodes having the specified supertype.
Rulechain visits are for now entirely handled as strings:
pmd/pmd-core/src/main/java/net/sourceforge/pmd/lang/rule/AbstractRule.java
Line 44 in 4bb55e4
The implementation also throws an exception (!) if the node class doesn't have a hardcoded "AST" prefix:
pmd/pmd-core/src/main/java/net/sourceforge/pmd/lang/rule/AbstractRule.java
Lines 319 to 324 in 4bb55e4
Introducing some abstractions into the AST (like done in #1759, argumented on the wiki) has a number of advantages, but the current rulechain implementation doesn't scale. Adding a rulechain visit to an abstract node type currently does nothing, instead of visiting all nodes having the specified supertype.
Refs #1772
There's the exact same problem with XPath queries, which I'll explain in another issue
The text was updated successfully, but these errors were encountered: