-
Notifications
You must be signed in to change notification settings - Fork 62
Closed
Labels
trackingA tracking issue for a big featureA tracking issue for a big featurevalidationcandidate for syntactic or semantic validationcandidate for syntactic or semantic validation
Description
Is your feature request related to a problem? Please describe.
Rusty currently lacks if
, for
and while
specific validations. Specifically all of the following control statements will panic without any validation errors
FUNCTION main : DINT
VAR
i : DINT;
x : STRING;
END_VAR
IF x THEN END_IF
WHILE x DO END_WHILE
FOR i := 0 TO x DO END_FOR
END_FUNCTION
Describe the solution you'd like
Implement specific validation for the given control statements, i.e. if conditions are only allowed to have a type / type-hint of bool, for loops and their counter, start, end and step value are only allowed to have integers of the same type and are not allowed to be modified inside the for body (as specified in the norm), etc...
Additional context
This is a tracking issue, the following need to be implemented in order to close this
Metadata
Metadata
Assignees
Labels
trackingA tracking issue for a big featureA tracking issue for a big featurevalidationcandidate for syntactic or semantic validationcandidate for syntactic or semantic validation