Skip to content

Illegal Modelica code accessing value of Real #12

@AnHeuermann

Description

@AnHeuermann

When testing TransiEnt in OpenModelica we noticed that some models are trying to access attribute value.

E.g. for TransiEnt.Storage.Gas.Check.TestGasStorage_varXi:

[/home/hudson/saved_omc/libraries/.openmodelica/libraries/TransiEnt 2.0.2-master/SimCenter.mo:388:54-388:133:writable] Error: Modified element value not found in class Real.

SimCenter.mo

  Modelica.Blocks.Interfaces.RealOutput T_ground_var(value=if variable_T_ground then Variable_Ground_Temperature.value else T_ground)  "Diffuse solar radiation (from component ambientConditions)";

According to the Modelica 3.6 specification section 4.8.1 it is not allowed to access attribute value of a variable of type Real.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions