Opened 13 years ago
Closed 11 years ago
#1642 closed defect (fixed)
Invalid model gives wrong error
Reported by: | Per Östlund | Owned by: | Per Östlund |
---|---|---|---|
Priority: | high | Milestone: | |
Component: | Backend | Version: | |
Keywords: | Cc: | Per Östlund |
Description
The following model is invalid, since foo doesn't exist:
partial model M1 parameter Integer n = 2; parameter Real x[n]; end M1; model M2 extends M1(final x = y); final parameter Real y[n] = foo; end M2;
The compiler will give the error:
[cyclicmod.mo:3:3-3:22:writable] Error: Type mismatch in modifier of component x, declared type .Real[n], got modifier y of type #NOTYPE#
which is not the expected error message. It seems like the compiler always gives this error if y has a binding it can't handle, and it only happens if x and y are arrays. The correct error message is generated but not shown.
Change History (1)
comment:1 by , 11 years ago
Cc: | perost, perost → perost |
---|---|
Component: | → Backend |
Resolution: | → fixed |
Status: | accepted → closed |
Note:
See TracTickets
for help on using tickets.
Seems to have been fixed sometime ago.