Skip to content

Proper check-phase #50

Open
Open
@garritfra

Description

@garritfra

The checking of the AST currently happens through running the generated code. This is obviously a bad idea.

We should implement a check phase after parsing the AST. For now, the following checks should be in place:

  • Check, if an accessed symbol is defined in the scope
  • Check, if types are compatible (function parameters should have the correct type, let x: int = "Hello" is invalid, etc.)

Room for discussion

  • Should this be done while parsing the tree instead?
  • Should this be one large check, or modular checkers that run sequentially?

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