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

Commit

Permalink
fix reverse ranges n:-1:1
Browse files Browse the repository at this point in the history
  • Loading branch information
hkiel authored and OpenModelica-Hudson committed Jul 8, 2017
1 parent 89f3548 commit 743991c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Compiler/Util/List.mo
Original file line number Diff line number Diff line change
Expand Up @@ -1752,7 +1752,7 @@ algorithm
a := addPos(inList1, a, 1);
a := addPos(inList2, a, 1);

for i in inN:1 loop
for i in inN:-1:1 loop
if arrayGet(a, i) == 1 then
outDifference := i :: outDifference;
end if;
Expand Down Expand Up @@ -1820,7 +1820,7 @@ algorithm
a := addPos(inList1, a, 1);
a := addPos(inList2, a, 1);

for i in inN:1 loop
for i in inN:-1:1 loop
if arrayGet(a, i) > 0 then
outUnion := i :: outUnion;
end if;
Expand Down

0 comments on commit 743991c

Please sign in to comment.