Skip to content
This repository has been archived by the owner on May 18, 2019. It is now read-only.

Commit

Permalink
Change size of array equations to 1 if -nfScalarize
Browse files Browse the repository at this point in the history
This makes many backend modules work for models with arrays.

Belonging to [master]:
  - #2698
  - OpenModelica/OpenModelica-testsuite#1045
  • Loading branch information
rfranke authored and OpenModelica-Hudson committed Oct 6, 2018
1 parent dad3995 commit eda1ea2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Compiler/BackEnd/BackendDAEUtil.mo
Expand Up @@ -2532,7 +2532,7 @@ algorithm
// ARRAY_EQUATION
case BackendDAE.ARRAY_EQUATION(dimSize=dimsize,left=e1,right=e2)
equation
size = List.reduce(dimsize, intMul);
size = if Flags.isSet(Flags.NF_SCALARIZE) then List.reduce(dimsize, intMul) else 1;
lst1 = incidenceRowExp(e1, vars, iRow, functionTree, inIndexType);
res = incidenceRowExp(e2, vars, lst1, functionTree, inIndexType);
then
Expand Down

0 comments on commit eda1ea2

Please sign in to comment.