Skip to content

AST for MultiplicityRange with 2 bounds does not seem correct #16

Open
@gdaniel

Description

@gdaniel

Checklist before submitting a bug report

  • I have reviewed CONTRIBUTING.md document
  • I have done a quick search on the issue tracker to check if the bug report is not redundant

Context

SysIDE produces an AST that doesn't seem correct for MultiplicityRanges with two bounds, e.g. part a[1..2].
The AST contains an OperatorExpression with the .. function.

Based on KerML 8.2.5.8.1 OperatorExpression referring to the ".." function can exist, but the specification does not allow them in MultiplicityRange (see SysML 8.2.2.6.6 and KerML 8.2.5.11).

Steps to reproduce the bug

Parse the following input:

part a[1..2];

Current result

The AST contains an OperatorExpression with the .. function in the MultiplicityRange.

Expected result

The AST contains the LiteralInteger elements in the MultiplicityRange.

Additional context

[Any additional context. If applicable, you may provide screenshots and/or error logs.]

Possible fix

[Not required but you can suggest possible fixes for the bug or link a place in the code that could possibly be causing the bug]

Technical data

  • Operating system: Windows 11
  • Version of the repo: 0.8.0
  • VSCode version: 1.100.2

/label ~"bug report"

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