[jboss-jira] [JBoss JIRA] (DROOLS-5271) RHS statements ordering changes with modify block in executable model
Toshiya Kobayashi (Jira)
issues at jboss.org
Fri Apr 24 01:51:00 EDT 2020
[ https://issues.redhat.com/browse/DROOLS-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Toshiya Kobayashi updated DROOLS-5271:
--------------------------------------
Sprint: 2020 Week 16-18 (from Apr 13)
> RHS statements ordering changes with modify block in executable model
> ---------------------------------------------------------------------
>
> Key: DROOLS-5271
> URL: https://issues.redhat.com/browse/DROOLS-5271
> Project: Drools
> Issue Type: Bug
> Components: executable model
> Affects Versions: 7.36.0.Final
> Reporter: Toshiya Kobayashi
> Assignee: Toshiya Kobayashi
> Priority: Major
>
> The order of statements in RHS changes with executable model when modify block is involved. The below rule can tell the difference with standard-drl.
> {noformat}
> import org.drools.modelcompiler.domain.Person;global java.util.List list;
> rule R when
> $p1 : Person(name == "John")
> $p2 : Person(name == "Paul")
> then
> list.add($p1.getAge());
> list.add($p2.getAge());
> modify($p1) { setAge($p1.getAge()+1) }
> list.add($p1.getAge());
> list.add($p2.getAge());
> modify($p2) { setAge($p2.getAge()+5) }
> list.add($p1.getAge());
> list.add($p2.getAge());
> end
> {noformat}
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
More information about the jboss-jira
mailing list