Skip to content

Commit

Permalink
- get rid of equality()/failure(equality())
Browse files Browse the repository at this point in the history
git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@6218 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
adrpo committed Sep 25, 2010
1 parent 5a7990e commit a6c9f4b
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions Compiler/InstSection.mo
Expand Up @@ -671,17 +671,15 @@ algorithm
// Implicit range
case (cache,env,ih,mod,pre,csets,ci_state,SCode.EQ_FOR(index = i,range = Absyn.END(),eEquationLst = el),initial_,impl,graph)
equation
lst=SCode.findIteratorInEEquationLst(i,el);
equality(lst={});
(lst as {}) = SCode.findIteratorInEEquationLst(i,el);
Error.addMessage(Error.IMPLICIT_ITERATOR_NOT_FOUND_IN_LOOP_BODY,{i});
then
fail();

// for i loop ... end for; NOTE: This construct is encoded as range being Absyn.END()
case (cache,env,ih,mod,pre,csets,ci_state,SCode.EQ_FOR(index = i,range = Absyn.END(),eEquationLst = el),initial_,impl,graph)
equation
lst=SCode.findIteratorInEEquationLst(i,el);
failure(equality(lst={}));
(lst as _::_)=SCode.findIteratorInEEquationLst(i,el);
tpl=Util.listFirst(lst);
e=rangeExpression(tpl);
(cache,e_1,DAE.PROP(type_ = (DAE.T_ARRAY(arrayType = id_t),_), constFlag = cnst),_,fdae1) =
Expand Down

0 comments on commit a6c9f4b

Please sign in to comment.