tkobayas commented on code in PR #5806:
URL:
https://github.com/apache/incubator-kie-drools/pull/5806#discussion_r1540800031
##########
drools-drl/drools-drl-parser/src/main/antlr4/org/drools/drl/parser/antlr4/DRLParser.g4:
##########
@@ -321,8 +323,11 @@ drlPrimary
| nonWildcardTypeArguments (explicitGenericInvocationSuffix | THIS
arguments)
| inlineListExpression
| inlineMapExpression
+ | inlineCast
;
+inlineCast : drlIdentifier HASH drlIdentifier ;
Review Comment:
In `DRLParser.g4`, we mimic the parser syntax of `DRL6Expressions.g4`.
However, here looks a little different. `DRL6Expressions.g4`'s `primary` rule
handles more complex structure (e.g. `DOT` chaining) while such structure is
handled in `drlExpression` in `DRLParser.g4` because `drlExpression` is
inherited from `JavaParser.g4`'s `expression`.
This time, I prioritized simplicity for the changes in `DRLParser.g4`. But I
filed https://github.com/apache/incubator-kie-drools/issues/5807 to review
`drlExpression` and `drlPrimary` to make them closer to `DRL6Expressions.g4`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]