Skip to content

Potential inconsistencies between the CRML specification and examples #40

@folmate

Description

@folmate

Hi @audrey-jardin,

I have been going through the specification with LLMs and see what they can do with it, and some examples seem to cause issues in generated models.

In 4.13.2, Example 6, 7, and 8 fails as the parameter types are also in brackets, not just the return type. Is this an error, or I'm missing something?

In 4.6.1, Example 2, Integer x10 is E3; // No digit before the decimal exponent is marked as incorrect, but it is technically correct, as E3 can be (and is) interpreted as a variable.

In 4.21.2, partial type Quantity also fails, but this seems to be an issue with the parser. Can you confirm that the following model should parse or not?

model TestModel is {
    partial type Quantity is (Real q is rate*u + offset)  {  
        String SIUnit; // SI unit for quantity q 
        String userUnit; // User unit for quantity q 
        Real u; // Quantity q expressed in user units 
        Real rate; // Conversion rate between user units and SI units 
        Real offset; // offset between user units and SI units 
    }; 
    //Quantity x = Quantity (SIUnit = "Pa", userUnit = "bar", rate = 1.e5, offset = 0, u = 3); 
}

Thank you.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions