Skip to content

Commit 2559181

Browse files
author
Jens Frenkel
committed
- use consOnTrue instead of Util.if_(res, e :: inAccum, inAccum)), save memory
- fix bootstrapping git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@13354 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
1 parent 24df196 commit 2559181

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

Compiler/BackEnd/BackendDAE.mo

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -202,8 +202,8 @@ uniontype WhenOperator "- Reinit Statement"
202202
Typically sideeffect call of external function but also
203203
Connections.* i.e. Connections.root(...) functions."
204204
Absyn.Path functionName;
205-
list<DAE.Exp> functionArgs;
206-
DAE.ElementSource source "the origin of the component/equation/algorithm";
205+
list<.DAE.Exp> functionArgs;
206+
.DAE.ElementSource source "the origin of the component/equation/algorithm";
207207
end NORETCALL;
208208

209209
end WhenOperator;

Compiler/Util/List.mo

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6929,7 +6929,7 @@ algorithm
69296929
equation
69306930
res = inFunc(e);
69316931
then
6932-
select_tail(rest, inFunc, Util.if_(res, e :: inAccum, inAccum));
6932+
select_tail(rest, inFunc, consOnTrue(res, e , inAccum));
69336933
end match;
69346934
end select_tail;
69356935

@@ -7033,7 +7033,7 @@ algorithm
70337033
equation
70347034
res = inFunc(e, inArg1);
70357035
then
7036-
select1_tail(rest, inFunc, inArg1, Util.if_(res, e :: inAccum, inAccum));
7036+
select1_tail(rest, inFunc, inArg1, consOnTrue(res, e ,inAccum));
70377037
end match;
70387038
end select1_tail;
70397039

@@ -7079,7 +7079,7 @@ algorithm
70797079
equation
70807080
res = inFunc(inArg1, e);
70817081
then
7082-
select1r_tail(rest, inFunc, inArg1, Util.if_(res, e :: inAccum, inAccum));
7082+
select1r_tail(rest, inFunc, inArg1, consOnTrue(res, e, inAccum));
70837083
end match;
70847084
end select1r_tail;
70857085

@@ -7132,7 +7132,7 @@ algorithm
71327132
res = inFunc(e, inArg1, inArg2);
71337133
then
71347134
select2_tail(rest, inFunc, inArg1, inArg2,
7135-
Util.if_(res, e :: inAccum, inAccum));
7135+
consOnTrue(res, e, inAccum));
71367136
end match;
71377137
end select2_tail;
71387138

0 commit comments

Comments
 (0)