[jboss-jira] [JBoss JIRA] Commented: (JBRULES-2819) DSL parsing/expansion: '\', '$', empty value, empty condition

Wolfgang Laun (JIRA) jira-events at lists.jboss.org
Mon Dec 6 03:58:47 EST 2010


    [ https://jira.jboss.org/browse/JBRULES-2819?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12567727#comment-12567727 ] 

Wolfgang Laun commented on JBRULES-2819:
----------------------------------------

Errors caught by  DSLTokenizedMappingFile in parseAndLoad are not reported by the builder. This is due to org.drools.compiler.PackageBuilder, in addDsl, just calling parseAndLoad, but not bothering to check the reutrn avlua and/or get the errors  from the DSLTokenizedMappingFile object.

> DSL parsing/expansion: '\', '$', empty value, empty condition  
> ---------------------------------------------------------------
>
>                 Key: JBRULES-2819
>                 URL: https://jira.jboss.org/browse/JBRULES-2819
>             Project: Drools
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: drools-compiler-DSL
>    Affects Versions: 5.1.1.FINAL
>            Reporter: Wolfgang Laun
>            Assignee: Mark Proctor
>             Fix For: 5.2.0.M1
>
>
> DSL parser does not accept an empty "value" section, e.g.
>    [when] a man loves a woman=
> Expansion of a rule with an empty condition results in "whenthen".
> The DSL parser escapes '$', but not '\' in value sections. It should not modify the value section except for "normalizing" variable references. Variable references should be restricted to a "clean" character sequence (e.g. Java identifier). The current expansion using replaceAll is too fragile.
> I have emailed three reworked source files AntlrDSLMappingEntry.java  DefaultExpander.java  DSLTokenizedMappingFile.java to Edson, but I didn't change the parser itself.

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the jboss-jira mailing list