-
Bug
-
Resolution: Won't Do
-
Major
-
None
-
5.2.0.M1
-
None
This (stupid) rule:
rule "Testing contains" dialect "mvel" when Response( $answerSelections : answerSelections ) AnswerSelection( answer.ID in (2, 3) ) # AnswerSelection( answer.ID == 2 || == 3 ) # AnswerSelection( answer.ID == 2 || answer.ID == 3 ) then System.out.println("Testing contains activated") end
...produces this error message:
Unable to Analyse Expression answer.ID == 2 || answer.ID == 3: [Error: Failed to compile: 1 compilation error(s): - (1,9) unqualified type in strict mode for: ID] [Near : {... Unknown ....}] ^ [Line: 1, Column: 0] : [Rule name='Testing contains']
Response has a getAnswerSelections() method that returns a Collection type. AnswerSelection has a getAnswer() method that returns an Answer. Answer has a getID() method that returns an int.
This rule compiled fine under Drools 5.1.1 and 5.2.0.M1 and fails under 5.2.0-SNAPSHOT.