Details
-
Bug
-
Resolution: Done
-
Major
-
5.2.0.Final, 5.4.0.Final, 5.5.0.Final
-
None
Description
The right parenthesis is improperly parsed when creating a new object:
rule "Test Rule"
dialect "mvel"
when
Person()
then
SuggestedAction s = new SuggestedAction("suggest something with ) a paren")
end
This happens any time you use a new object declaration. It appears to blindly use the parenthesis without considering the quote which results in the following error message during rule compile:
[Error: unterminated string literal]
The following syntax compiles without problems:
rule "Test Rule"
dialect "mvel"
when
Person()
then
SuggestedAction sa = new SuggestedAction("Now no parens here")
sa.putValue("RELEVENCE", "with a ) paren ")
System.out.println(“I am a ) paren ”)
end
Using a left parenthesis does not cause an error. Switching to java dialect does not cause the error.