Skip to content

Implement Range Checks for Immediate Values in Global Variable Initializers #89

Description

@Y-Nak

Currently, the Sonatina-ir parser does not perform range validation on integer Immediate values within global variable initializers. This lack of checking can lead to the assignment of out-of-range integer values, potentially causing unexpected behavior or runtime errors.

Proposed Solution:

  • Add Range Validation:
    • Implement checks to ensure that integer Immediate values are within the valid range for their specified integer types.
  • Error Handling:
    • Generate informative error messages when an out-of-range value is detected during parsing/ir-building.
  • Testing:
    • Create test cases to verify that the parser correctly identifies and handles out-of-range values.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions