Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add validation for array size declaration with unresolved reference #1105

Open
mhasel opened this issue Feb 22, 2024 · 0 comments
Open

Add validation for array size declaration with unresolved reference #1105

mhasel opened this issue Feb 22, 2024 · 0 comments
Assignees
Labels
medium-priority validation candidate for syntactic or semantic validation

Comments

@mhasel
Copy link
Member

mhasel commented Feb 22, 2024

Is your feature request related to a problem? Please describe.
Currently, initializing an array with an unresolved reference will be caught during the codegen phase:

VAR
    x : ARRAY[0..UNRESOLVED_REF] OF DINT;
END_VAR

We should add a validation for this and check to see if other unresolved references or non-constant references where we expect constants cause similar behaviour.

@mhasel mhasel self-assigned this Feb 22, 2024
@mhasel mhasel linked a pull request Feb 22, 2024 that will close this issue
3 tasks
@mhasel mhasel added validation candidate for syntactic or semantic validation medium-priority labels Mar 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
medium-priority validation candidate for syntactic or semantic validation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant