Skip to content

Commit 15d6851

Browse files
vwaurichOpenModelica-Hudson
authored andcommitted
single eval of knvars
1 parent 2d51ecf commit 15d6851

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Compiler/SimCode/SimCodeUtil.mo

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5773,6 +5773,7 @@ algorithm
57735773

57745774
//evaluate function calls in variable attributes (start-value)
57755775
(vars,_) := BackendVariable.traverseBackendDAEVarsWithUpdate(vars,evaluateStartValues,funcTree);
5776+
57765777
//BackendDump.dumpVariables(vars,"VAR AFTER");
57775778
systOut := BackendDAEUtil.setEqSystVars(systIn, vars);
57785779
end preCalculateStartValues;
@@ -6016,7 +6017,8 @@ algorithm
60166017
systs2 := List.filterOnFalse(systs1, BackendDAEUtil.isClockedSyst);
60176018

60186019
if not Flags.isSet(Flags.NO_START_CALC) then
6019-
systs1 := List.map2(systs1, preCalculateStartValues, knvars1, funcTree);
6020+
(systs1) := List.map2(systs1, preCalculateStartValues, knvars1, funcTree);
6021+
(knvars1,_) := BackendVariable.traverseBackendDAEVarsWithUpdate(knvars1,evaluateStartValues,funcTree);
60206022
//systs2 := List.map1(systs2, preCalculateStartValues, knvars2);
60216023
end if;
60226024

0 commit comments

Comments
 (0)