-
Bug
-
Resolution: Done
-
Major
-
7.9.0.GA
-
The issue was found in RHDM 7.9.0.
-
False
-
False
-
Release Notes
-
-
-
-
-
-
CR1
-
+
-
Undefined
-
-
-
2020 Week 49-51 (from Nov 30)
Compiling a rule like (*1) which is described in MVEL dialect and uses a compound assignment operation like BigDecimal_type_property += BigDecimal_value, for example,
- $bus.weight += $bus.weight; ..... (6c) or
- BigDecimal bd1 = 1000; $bus.weight += bd1; ..... (6d)
with executable rule models enabled, an error like (*2) occurs. $bus.weight is a BigDecimal type property.
The same issue also occurs in the case of using '-='.
For '*=' and '/=', no compilation error occurs but the value of $bus.weight does not change by the operation.
(*1)
package com.example.reproducer import com.example.reproducer.Bus dialect "mvel" rule "bus6c" when $bus : Bus() then $bus.weight += $bus.weight; ..... (6c) System.out.println("***** " + $bus + ", weight = " + $bus.weight); update($bus); end
(*2)
[ERROR] /work2/cases/02801729/reproducer_02801729_6c_6d/target/generated-sources/drools-model-compiler/main/java/com/example/reproducer/PF9/LambdaConsequenceF9B783ABDBE8B65F49FDA13227908E7F.java:[19,56] void cannot be dereferenced
- is cloned by
-
DROOLS-5895 Compound assignment operation like BigDecimal_type_property += BigDecimal_value causes a compilation error in executable model.
- Closed