You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
caseFOR_EQUATION(body = {_}) then getLHS(List.first(eq.body));
1562
+
caseFOR_EQUATION(body = {_}) then getLHS(listHead(eq.body));
1563
1563
caseIF_EQUATION() algorithm
1564
1564
(lhs, success) :=IfEquationBody.getLHS(eq.body);
1565
1565
ifnot success then
@@ -1582,7 +1582,7 @@ public
1582
1582
caseSCALAR_EQUATION() then eq.rhs;
1583
1583
caseARRAY_EQUATION() then eq.rhs;
1584
1584
caseRECORD_EQUATION() then eq.rhs;
1585
-
caseFOR_EQUATION(body = {_}) then getRHS(List.first(eq.body));
1585
+
caseFOR_EQUATION(body = {_}) then getRHS(listHead(eq.body));
1586
1586
caseIF_EQUATION() then IfEquationBody.getRHS(eq.body);
1587
1587
else algorithm
1588
1588
Error.addMessage(Error.INTERNAL_ERROR,{getInstanceName() +" failed because RHS was ambiguous for: "+ toString(eq)});
@@ -1600,7 +1600,7 @@ public
1600
1600
caseARRAY_EQUATION() algorithm eq.lhs := lhs; then eq;
1601
1601
caseRECORD_EQUATION() algorithm eq.lhs := lhs; then eq;
1602
1602
caseFOR_EQUATION(body = {_}) algorithm
1603
-
eq.body := {setLHS(List.first(eq.body), lhs)};
1603
+
eq.body := {setLHS(listHead(eq.body), lhs)};
1604
1604
then eq;
1605
1605
else algorithm
1606
1606
Error.addMessage(Error.INTERNAL_ERROR,{getInstanceName() +" failed because LHS "+Expression.toString(lhs) +" could not be set for:\n "+ toString(eq)});
@@ -1618,7 +1618,7 @@ public
1618
1618
caseARRAY_EQUATION() algorithm eq.rhs := rhs; then eq;
1619
1619
caseRECORD_EQUATION() algorithm eq.rhs := rhs; then eq;
1620
1620
caseFOR_EQUATION(body = {_}) algorithm
1621
-
eq.body := {setRHS(List.first(eq.body), rhs)};
1621
+
eq.body := {setRHS(listHead(eq.body), rhs)};
1622
1622
then eq;
1623
1623
else algorithm
1624
1624
Error.addMessage(Error.INTERNAL_ERROR,{getInstanceName() +" failed because RHS could not be set for: "+ toString(eq)});
@@ -1756,7 +1756,7 @@ public
1756
1756
if isNone(if_body.else_if) andnotList.hasSeveralElements(if_body.then_eqns) then
1757
1757
// first if-branch is true and has only one equation
0 commit comments