Replace package name with class name
Co-authored-by: Andreas Dangel <andreas.dangel@adangel.org>
This commit is contained in:
@ -2759,7 +2759,7 @@ void ModuleDirective() #void:
|
||||
ModuleName() ";" ) #ModuleRequiresDirective
|
||||
| ( LOOKAHEAD({isKeyword("exports")}) <IDENTIFIER> packageName=VoidNameNoLookahead() {jjtThis.setPackageName(packageName);} [ LOOKAHEAD({isKeyword("to")}) <IDENTIFIER> ModuleName() ("," ModuleName())* ] ";" ) #ModuleExportsDirective
|
||||
| ( LOOKAHEAD({isKeyword("opens")}) <IDENTIFIER> packageName=VoidNameNoLookahead() {jjtThis.setPackageName(packageName);} [ LOOKAHEAD({isKeyword("to")}) <IDENTIFIER> ModuleName() ("," ModuleName())* ] ";" ) #ModuleOpensDirective
|
||||
| ( LOOKAHEAD({isKeyword("uses")}) <IDENTIFIER> packageName=VoidNameNoLookahead() {jjtThis.setPackageName(packageName);} ";" ) #ModuleUsesDirective
|
||||
| ( LOOKAHEAD({isKeyword("uses")}) <IDENTIFIER> ClassName() ";" ) #ModuleUsesDirective
|
||||
| ( LOOKAHEAD({isKeyword("provides")}) <IDENTIFIER> ClassName() LOOKAHEAD({isKeyword("with")}) <IDENTIFIER> ClassName() ("," ClassName() )* ";" ) #ModuleProvidesDirective
|
||||
}
|
||||
|
||||
|
@ -13,7 +13,7 @@ package net.sourceforge.pmd.lang.java.ast;
|
||||
*
|
||||
* </pre>
|
||||
*/
|
||||
public final class ASTModuleUsesDirective extends AbstractPackageNameModuleDirective {
|
||||
public final class ASTModuleUsesDirective extends ASTModuleDirective {
|
||||
|
||||
ASTModuleUsesDirective(int id) {
|
||||
super(id, DirectiveType.USES);
|
||||
|
Reference in New Issue
Block a user