Skip to content

Commit

Permalink
[NF] Fix Expression.mapFoldShallow for BOX.
Browse files Browse the repository at this point in the history
  • Loading branch information
perost committed Jun 18, 2020
1 parent 97bd8e7 commit ae03612
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions OMCompiler/Compiler/NFFrontEnd/NFExpression.mo
Expand Up @@ -3189,6 +3189,12 @@ public
then
if referenceEq(exp.recordExp, e1) then exp else RECORD_ELEMENT(e1, exp.index, exp.fieldName, exp.ty);

case BOX()
algorithm
(e1, arg) := func(exp.exp, arg);
then
if referenceEq(exp.exp, e1) then exp else BOX(e1);

case MUTABLE()
algorithm
(e1, arg) := func(Mutable.access(exp.exp), arg);
Expand Down

0 comments on commit ae03612

Please sign in to comment.