Skip to content

Commit

Permalink
- In unelabMod, call simplify before trying to unelab the expression
Browse files Browse the repository at this point in the history
git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@8480 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
sjoelund committed Apr 4, 2011
1 parent 5bd5f68 commit ebc9dc0
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
2 changes: 1 addition & 1 deletion Compiler/FrontEnd/Mod.mo
Expand Up @@ -403,7 +403,7 @@ algorithm
equation
//es = ExpressionDump.printExpStr(e);
subs_1 = unelabSubmods(subs);
e_1 = Expression.unelabExp(dexp);
e_1 = Expression.unelabExp(ExpressionSimplify.simplify1(dexp));
then
SCode.MOD(finalPrefix,each_,subs_1,SOME((e_1,false))); // default typechecking non-delayed

Expand Down
1 change: 0 additions & 1 deletion Compiler/FrontEnd/Static.mo
Expand Up @@ -1068,7 +1068,6 @@ algorithm
(cache,foldExp,_,st) = elabExpOptAndMatchType(cache, env_foldExp, afoldExp, expty, impl, st, doVect,pre,info);
// print("make reduction: " +& Absyn.pathString(fn_1) +& " exp_1: " +& ExpressionDump.printExpStr(exp_1) +& "\n");
exp_1 = DAE.REDUCTION(DAE.REDUCTIONINFO(fn_1,expty,v,foldExp),exp_1,reductionIters);
exp_1 = ExpressionSimplify.simplify1(exp_1) "only needed because unelabMod is silly";
then
(cache,exp_1,prop,st);

Expand Down

0 comments on commit ebc9dc0

Please sign in to comment.