#5157 closed defect (invalid)
Another issue with NFTyping.typeBindings
| Reported by: | Francesco Casella | Owned by: | Per Östlund |
|---|---|---|---|
| Priority: | high | Milestone: | 2.0.0 |
| Component: | New Instantiation | Version: | |
| Keywords: | Cc: |
Description
Please check Modelica.Magnetic.FundamentalWave.Examples.BasicMachines.SMEE_DOL. The NF fails with
[/Modelica trunk/Magnetic/FundamentalWave.mo:7031:9-7035:80:writable] Error: Type mismatch in binding fixed = true, expected subtype of Boolean[2], got type Boolean.
Change History (3)
comment:1 by , 7 years ago
| Component: | *unknown* → New Instantiation |
|---|---|
| Milestone: | Future → 2.0.0 |
| Owner: | changed from to |
comment:2 by , 7 years ago
| Resolution: | → invalid |
|---|---|
| Status: | new → closed |
comment:3 by , 7 years ago
I came across this type or error message a few times, and found it a little cryptic for the final user.
It would be clearer to read
Error: Type mismatch in binding fixed = true, expected type Boolean[2], got type Boolean.
but I understand that this would be somewhat imprecise.
I have two ideas to improve the situation:
option 1) OM uses the message I proposed (i.e. using the word type instead of subtype of) for built-in types (Real, Integer, String, Boolean and, hopefully, Complex) and the message containing
subtype of in the other cases
option 2) OM uses the message I proposed (i.e. using the word type instead of subtype of) outright. In this case we leave to the user the understanding that also subtypes would be allowable

The error is correct, I've opened a pull request for the MSL here.