Skip to content

Commit

Permalink
fixed makeNoEvent?
Browse files Browse the repository at this point in the history
git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@24873 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
Vitalij Ruge committed Mar 3, 2015
1 parent ab6c8f4 commit 94a443a
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions Compiler/FrontEnd/Expression.mo
Expand Up @@ -819,7 +819,7 @@ traversal function for addNoEventToRelations"
output DAE.Exp outExp;
algorithm
outExp := match e
case DAE.RELATION() then DAE.CALL(Absyn.IDENT("noEvent"),{e},DAE.callAttrBuiltinBool);
case DAE.RELATION() then makeNoEvent(e);
else e;
end match;
end addNoEventToRelationExp;
Expand All @@ -840,8 +840,8 @@ algorithm
outExp := match e
local
DAE.Exp e1,e2,e3;
case DAE.RELATION() then DAE.CALL(Absyn.IDENT("noEvent"),{e},DAE.callAttrBuiltinBool);
case DAE.IFEXP(e1,e2,e3) then DAE.IFEXP(DAE.CALL(Absyn.IDENT("noEvent"),{e1},DAE.callAttrBuiltinBool),e2,e3);
case DAE.RELATION() then makeNoEvent(e);
case DAE.IFEXP(e1,e2,e3) then DAE.IFEXP(makeNoEvent(e1),e2,e3);
else e;
end match;
end addNoEventToRelationandCondExp;
Expand All @@ -863,7 +863,7 @@ algorithm
case DAE.CALL()
equation
true = isEventTriggeringFunctionExp(e);
then DAE.CALL(Absyn.IDENT("noEvent"),{e},DAE.callAttrBuiltinBool);
then makeNoEvent(e);
else e;
end matchcontinue;
end addNoEventToEventTriggeringFunctionsExp;
Expand Down Expand Up @@ -3037,7 +3037,7 @@ public function makeNoEvent " adds a noEvent call around an expression"
input DAE.Exp e1;
output DAE.Exp res;
algorithm
res := DAE.CALL(Absyn.IDENT("noEvent"),{e1},DAE.callAttrBuiltinBool);
res := Expression.makePureBuiltinCall("noEvent", {e1}, DAE.T_BOOL_DEFAULT);
end makeNoEvent;

public function makeNestedIf "creates a nested if expression given a list of conditions and
Expand Down

0 comments on commit 94a443a

Please sign in to comment.