Opened 9 years ago

Closed 9 years ago

#3065 closed defect (fixed)

Variable outside interval wrongly reported for integer variables

Reported by: adrpo Owned by: sjoelund.se
Priority: high Milestone: 1.9.2
Component: Backend Version: trunk
Keywords: Cc:

Description

See for example the test in r23970.
We get a message:

messages = "Warning: Variable state.phase out of [min, max] interval: state.phase >= 0 and state.phase <= 2 has value: 1"

which is clearly wrong.

Change History (4)

comment:1 Changed 9 years ago by sjoelund.se

The error is the modelica_integer_to_modelica_string_format function, which uses %d instead of %ld as the format string.

comment:2 Changed 9 years ago by adrpo

That might be the case as on 32 bit Windows this message does not show.

comment:3 Changed 9 years ago by sjoelund.se

  • Owner changed from somebody to sjoelund.se
  • Status changed from new to accepted

I will change the String conversion functions to parse the format string correctly

comment:4 Changed 9 years ago by sjoelund.se

  • Resolution set to fixed
  • Status changed from accepted to closed
Note: See TracTickets for help on using tickets.