Skip to content

Commit

Permalink
- Do not do unsafe operations like saying ceval arr[i] = arr just bec…
Browse files Browse the repository at this point in the history
…ause we are in a for-iterator scope...

git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@9684 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
sjoelund committed Aug 25, 2011
1 parent 0b1b5b3 commit 40acb4b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Compiler/FrontEnd/Ceval.mo
Expand Up @@ -5382,13 +5382,15 @@ algorithm
// we have no subscripts but we have a value, return it
case (cache,env,{},v,_,_) then (cache,v);

// if we are in a for loop scope, the subs might be a for iterator, check
// if we are in a for loop scope, the subs might be a for iterator, check
/*
case (cache,env,{DAE.INDEX(DAE.CREF(cr, _))},v,_,_)
equation
// we have a iterator, return the value as it is
(cache,_,_,_,SOME(_),_,_,_,_) = Lookup.lookupVarLocal(cache, env, cr);
then
(cache,v);
*/

/*// failtrace
case (cache, env, subs, inValue, dims, _, _)
Expand Down

0 comments on commit 40acb4b

Please sign in to comment.