Compound assignment operation like BigDecimal_type_property <op> Numeric/BigDecimal_value causes an unexpected result or error in MVEL (org.mvel2).
When using MVEL.eval method, the result of "+=" operation is incorrect, and "-=", "*=", "/=" operations result in an error.
- BigDecimal_type_property <op> Numeric_value (Initial value of $bus.weight is 12000B)
- $bus.weight += 1000 ==> 1000 // incorrect result
- $bus.weight -= 1000 ==> Error
- $bus.weight *= 1000 ==> Error
- $bus.weight /= 1000 ==> Error
- BigDecimal_type_property <op> BigDecimal_value (Initial value of $bus.weight and bdv are 12000B and 1000B respectively)
- $bus.weight += bdv ==> 1000 // incorrect result
- $bus.weight -= bdv ==> Error
- $bus.weight *= bdv ==> Error
- $bus.weight /= bdv ==> Error
When using MVEL.executeExpression method, the result of "+=" operation is correct, while "-=", "*=", "/=" operations cause an error.
- BigDecimal_type_property <op> Numeric_value (Initial value of $bus.weight is 12000B)
- $bus.weight += 1000 ==> 13000 // correct
- $bus.weight -= 1000 ==> Error
- $bus.weight *= 1000 ==> Error
- $bus.weight /= 1000 ==> Error
- BigDecimal_type_property <op> BigDecimal_value (Initial value of $bus.weight and bdv are 12000B and 1000B respectively)
- $bus.weight += bdv ==> 13000 // correct
- $bus.weight -= bdv ==> Error
- $bus.weight *= bdv ==> Error
- $bus.weight /= bdv ==> Error
$bus.weight is a BigDecimal type property.
MVEL library should return correct result for any operations above.
- incorporates
-
DROOLS-5897 Compound BigDecimal operator is translated to assignOperator in MVEL
- Closed
-
DROOLS-5937 Compound assignment operation like BigDecimal_type_property <op> Numeric/BigDecimal_value causes an unexpected result or error in MVEL.
- Closed
- is blocked by
-
RHDM-1574 Consume Mvel version to 2.4.12+ in RHDM 7.10.1
- Closed