#3051 closed defect (fixed)
extends and modification of attributes
| Reported by: | Willi Braun | Owned by: | Adrian Pop |
|---|---|---|---|
| Priority: | high | Milestone: | 1.9.4 |
| Component: | Frontend | Version: | trunk |
| Keywords: | Cc: | Adrian Pop, Rüdiger Franke, dersh@… |
Description
The following model is motivated by some Modelica.Media models, which seems to have some issue with modification of the attributes like min, max, nominal and start.
The following script
loadString("
package p
package types
type crazyT = Real(min=2, max=12, nominal=5, start=2.1);
end types;
package p1
model A
extends types;
end A;
model B
extends A(crazyT(start=1.6));
end B;
end p1;
model C
p1.A.crazyT a;
p1.B.crazyT b;
equation
der(a) = 0;
der(b) = 0;
end C;
end p;
");
getErrorString();
instantiateModel(p.C);
getErrorString();
outputs:
"class p.C Real a(min = 2.0, max = 12.0, start = 2.1, nominal = 5.0); Real b(min = 2.0, max = 12.0, start = 2.1, nominal = 5.0); equation der(a) = 0.0; der(b) = 0.0; end p.C;
As far as I see the start attribute of a and b should be different, or did I miss something?
Change History (7)
comment:1 by , 11 years ago
| Owner: | changed from to |
|---|---|
| Status: | new → accepted |
comment:2 by , 11 years ago
| Cc: | added |
|---|
comment:3 by , 11 years ago
| Cc: | added |
|---|
comment:4 by , 11 years ago
comment:5 by , 11 years ago
| Resolution: | → fixed |
|---|---|
| Status: | accepted → closed |
comment:6 by , 10 years ago
| Milestone: | Future → pre1.9.4 |
|---|
It doesn't make sense to keep closed ticket in the "Future" milestone that were simply forgotten to assign to the correct milestone in the past.
comment:7 by , 8 years ago
| Milestone: | pre1.9.4 → 1.9.4 |
|---|
Removing the pre1.9.4 milestone in favor of 1.9.4.
Note:
See TracTickets
for help on using tickets.

See also #3095