]
Petr Široký resolved DROOLS-452.
--------------------------------
Fix Version/s: 6.4.x
Resolution: Done
This has been somehow fixed over the time (without a link to specific commit). Compiler
now reports error.
MVEL validates illegal expressions using ":"
--------------------------------------------
Key: DROOLS-452
URL:
https://issues.jboss.org/browse/DROOLS-452
Project: Drools
Issue Type: Bug
Reporter: Davide Sottara
Assignee: Petr Široký
Priority: Minor
Fix For: 6.4.x
A rule like this
{code}
rule "Typo"
dialect "mvel"
when
...
then
// Notice the ":" in place of ";". There is also a \n at the end of
the line
System.out.println( "Hello" ):
// more statements here
end
{code}
MVEL will validate the RHS at compile time.
At runtime, the printout (actually any statement ending with ":") will be
executed, but MVEL will fail silently thereafter. The rest of the conclusion
will not be evaluated.