Opened 10 years ago
Last modified 3 years ago
#3450 closed defect
Cyclic dependant parameter error in replaceable function — at Version 6
Reported by: | Markus Dahl | Owned by: | somebody |
---|---|---|---|
Priority: | high | Milestone: | 1.19.0 |
Component: | New Instantiation | Version: | |
Keywords: | Cc: |
Description (last modified by )
Validation of P.M
in the package below yields the following error in the message browser (but also reports the validation as successful):
Error: Cyclically dependent constants or parameters found in scope : {x}.
In the Base
model, changing the modifier x = x
in the redeclaration of the function to x = 5
will resolve the error. However those two statements should be equivalent.
Package:
package P function f input Real x; output Real y; algorithm y := x + 2; end f; partial model Base replaceable partial function func = f; end Base; model M extends Base(redeclare final function func = f(x = x)); parameter Real x = 5; Real y = func(1); end M; end P;
Change History (7)
by , 10 years ago
comment:2 by , 10 years ago
comment:3 by , 10 years ago
Description: | modified (diff) |
---|
comment:4 by , 10 years ago
Description: | modified (diff) |
---|
comment:5 by , 10 years ago
Description: | modified (diff) |
---|
comment:6 by , 10 years ago
Description: | modified (diff) |
---|
Note:
See TracTickets
for help on using tickets.
Package file needed to reproduce the error