Skip to content

Commit

Permalink
Use crefToExp when creating backend DAE with arrays
Browse files Browse the repository at this point in the history
  • Loading branch information
rfranke authored and OpenModelica-Hudson committed Oct 27, 2018
1 parent 76f3ceb commit 01a2928
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions Compiler/BackEnd/BackendDAECreate.mo
Expand Up @@ -1302,8 +1302,14 @@ algorithm

case DAE.EQUEQUATION(cr1 = cr1, cr2 = cr2,source = source)
equation
e1 = Expression.crefExp(cr1);
e2 = Expression.crefExp(cr2);
if Flags.isSet(Flags.NF_SCALARIZE) then
e1 = Expression.crefExp(cr1);
e2 = Expression.crefExp(cr2);
else
// consider array dimensions
e1 = Expression.crefToExp(cr1);
e2 = Expression.crefToExp(cr2);
end if;
eqns = lowerExtendedRecordEqn(e1,e2,source,BackendDAE.EQ_ATTR_DEFAULT_DYNAMIC,functionTree,inEquations);
then
(eqns,inREquations,inIEquations);
Expand Down

0 comments on commit 01a2928

Please sign in to comment.