Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
- Allow empty arrays on lhs of assignment


git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@13658 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
sjoelund committed Oct 26, 2012
1 parent d2995bb commit bf072ed
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Compiler/FrontEnd/InstSection.mo
Original file line number Diff line number Diff line change
Expand Up @@ -4639,7 +4639,7 @@ algorithm
// v := expr;
case (cache,env,ih,pre,Absyn.CREF(cr),e_1,eprop,_,source,_,impl,_,_)
equation
(cache,SOME((DAE.CREF(ce,t),cprop,attr))) = Static.elabCref(cache, env, cr, impl, false, pre, info);
(cache,SOME((DAE.CREF(ce,t),cprop,attr))) = Static.elabCrefNoEval(cache, env, cr, impl, false, pre, info);
Static.checkAssignmentToInput(var, attr, env, Static.bDisallowTopLevelInputs, info);
(cache, ce_1) = Static.canonCref(cache, env, ce, impl);
(cache, ce_1) = PrefixUtil.prefixCref(cache, env, ih, pre, ce_1);
Expand All @@ -4653,7 +4653,7 @@ algorithm
// der(x) := ...
case (cache,env,ih,pre,e2 as Absyn.CALL(function_ = Absyn.CREF_IDENT(name="der"),functionArgs=(Absyn.FUNCTIONARGS(args={Absyn.CREF(cr)})) ),e_1,eprop,_,source,_,impl,_,_)
equation
(cache,SOME((_,cprop,attr))) = Static.elabCref(cache,env, cr, impl,false,pre,info);
(cache,SOME((_,cprop,attr))) = Static.elabCrefNoEval(cache,env, cr, impl,false,pre,info);
(cache,(e2_2 as DAE.CALL(path=_)),_,_) = Static.elabExp(cache,env, e2, impl,NONE(),true,pre,info);
(cache,e2_2_2) = PrefixUtil.prefixExp(cache, env, ih, e2_2, pre);
(cache, e_1, eprop) = Ceval.cevalIfConstant(cache, env, e_1, eprop, impl, info);
Expand All @@ -4666,7 +4666,7 @@ algorithm
// v[i] := expr (in e.g. for loops)
case (cache,env,ih,pre,Absyn.CREF(cr),e_1,eprop,_,source,_,impl,_,_)
equation
(cache,SOME((cre,cprop,attr))) = Static.elabCref(cache,env, cr, impl,false,pre,info);
(cache,SOME((cre,cprop,attr))) = Static.elabCrefNoEval(cache,env, cr, impl,false,pre,info);
Static.checkAssignmentToInput(var, attr, env, Static.bDisallowTopLevelInputs, info);
(cache,cre2) = PrefixUtil.prefixExp(cache, env, ih, cre, pre);
(cache, e_1, eprop) = Ceval.cevalIfConstant(cache, env, e_1, eprop, impl, info);
Expand Down

0 comments on commit bf072ed

Please sign in to comment.