[rules-dev] getNestedConstraintPrefixLenght method in DRL6Parser.java
Claudio Jesús Sánchez Casanueva
claudio.sanchez at andanta.es
Thu Jan 30 11:16:50 EST 2014
I am studying the drools code and i have seen strange the method
'getNestedConstraintPrefixLenght()' in DRL6Parser.java: If i translate
that function to a regular expression in antlr lexer, it would be "ID? (
(DOT | HASH) ID)* DOT LEFT_PARENT", which have few sense.
The header
of 'nestedConstraint()' describes the expected the expected result as "(
ID ( DOT | HASH ) )* ID DOT LEFT_PAREN constraints RIGHT_PAREN" : it
internally calls to 'getNestedConstraintPrefixLenght()', consumes the
numbers of items retuned by this, calls to 'constrains()' and cosumes a
RIGHT_TOKEN.
For me the expected results described in the header of
'nestedConstraint()' do not correspond with the real results.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-dev/attachments/20140130/077f6177/attachment.html
More information about the rules-dev
mailing list