Skip to content

Commit

Permalink
- use match instead of matchontinue (to hopefully get tail recursion …
Browse files Browse the repository at this point in the history
…in these functions)

git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@23513 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
adrpo committed Nov 21, 2014
1 parent 9180027 commit 36d923a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Compiler/FrontEnd/CevalFunction.mo
Expand Up @@ -1377,7 +1377,7 @@ protected function evaluateForLoopArray
output LoopControl outLoopControl;
output SymbolTable outST;
algorithm
(outCache, outEnv, outLoopControl, outST) := matchcontinue(inCache, inEnv, inIter,
(outCache, outEnv, outLoopControl, outST) := match(inCache, inEnv, inIter,
inIterType, inValues, inStatements, inLoopControl, inST)
local
Values.Value value;
Expand All @@ -1399,7 +1399,7 @@ algorithm
inIterType, rest_vals, inStatements, loop_ctrl, st);
then
(cache, env, loop_ctrl, st);
end matchcontinue;
end match;
end evaluateForLoopArray;

protected function evaluateWhileStatement
Expand All @@ -1416,7 +1416,7 @@ protected function evaluateWhileStatement
output SymbolTable outST;
algorithm
(outCache, outEnv, outLoopControl, outST) :=
matchcontinue(inCondition, inStatements, inCache, inEnv, inLoopControl, inST)
match(inCondition, inStatements, inCache, inEnv, inLoopControl, inST)
local
FCore.Cache cache;
FCore.Graph env;
Expand All @@ -1439,7 +1439,7 @@ algorithm
then
(cache, env, loop_ctrl, st);

end matchcontinue;
end match;
end evaluateWhileStatement;

protected function extractLhsComponentRef
Expand Down

0 comments on commit 36d923a

Please sign in to comment.