[jboss-jira] [JBoss JIRA] (JBRULES-3698) Improper parsing of right parenthesis in rule consequence

Mario Fusco (JIRA) jira-events at lists.jboss.org
Fri Jan 25 12:49:47 EST 2013


     [ https://issues.jboss.org/browse/JBRULES-3698?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mario Fusco resolved JBRULES-3698.
----------------------------------

    Fix Version/s: 6.0.0.Alpha2
       Resolution: Done


fixed in mvel 2.1.4
                
> Improper parsing of right parenthesis in rule consequence
> ---------------------------------------------------------
>
>                 Key: JBRULES-3698
>                 URL: https://issues.jboss.org/browse/JBRULES-3698
>             Project: JBRULES
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: drools-core  (expert)
>    Affects Versions: 5.2.0.Final, 5.4.0.Final, 5.5.0.Final
>            Reporter: Chris Beesley
>            Assignee: Mario Fusco
>             Fix For: 6.0.0.Alpha2
>
>
> 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.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira



More information about the jboss-jira mailing list