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

Commit 0f5c4be

Browse files
perostOpenModelica-Hudson
authored andcommitted
[NF] Handle inner/outer in records.
Belonging to [master]: - #2908
1 parent 58af603 commit 0f5c4be

1 file changed

Lines changed: 7 additions & 6 deletions

File tree

Compiler/NFFrontEnd/NFRecord.mo

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -163,22 +163,23 @@ function collectRecordParam
163163
input output list<InstNode> locals;
164164
protected
165165
Component comp;
166+
InstNode comp_node = InstNode.resolveInner(component);
166167
algorithm
167-
if InstNode.isEmpty(component) then
168+
if InstNode.isEmpty(comp_node) then
168169
return;
169170
end if;
170171

171-
if InstNode.isProtected(component) then
172-
locals := component :: locals;
172+
if InstNode.isProtected(comp_node) then
173+
locals := comp_node :: locals;
173174
return;
174175
end if;
175176

176-
comp := InstNode.component(component);
177+
comp := InstNode.component(comp_node);
177178

178179
if Component.isConst(comp) and Component.hasBinding(comp) then
179-
locals := component :: locals;
180+
locals := comp_node :: locals;
180181
else
181-
inputs := component :: inputs;
182+
inputs := comp_node :: inputs;
182183
end if;
183184
end collectRecordParam;
184185

0 commit comments

Comments
 (0)