Skip to content

Commit

Permalink
Primary rule should accept this keyword (apache#5791)
Browse files Browse the repository at this point in the history
As in `String(this == "x")`.
  • Loading branch information
yurloc authored and tkobayas committed Jun 11, 2024
1 parent c0004f3 commit 3a7d63c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,7 @@ public void testNestedExpression() throws Exception {
"(long) l",
"(float) f",
"(double) d",
"this",
"<Type>this()",
"Object[][].class.getName()",
"new<Integer>ArrayList<Integer>()"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -671,7 +671,7 @@ primary returns [BaseDescr result]
: expr=parExpression { if( buildDescr ) { $result = $expr.result; } }
| nonWildcardTypeArguments (explicitGenericInvocationSuffix | this_key arguments)
| literal { if( buildDescr ) { $result = new AtomicExprDescr( $literal.text, true ); } }
//| this_key ({!helper.validateSpecialID(2)}? DOT IDENTIFIER)* ({helper.validateIdentifierSufix()}? identifierSuffix)?
| this_key (DOT drlIdentifier)* identifierSuffix?
| super_key superSuffix
| new_key creator
| primitiveType (LBRACK RBRACK)* DOT class_key
Expand Down

0 comments on commit 3a7d63c

Please sign in to comment.