Skip to content

Show error for statements after return or break #7

@steveRoll-git

Description

@steveRoll-git

Currently, the parser stops parsing statements entirely when it reaches a return or break statement. While this is correct behavior in terms of Lua syntax, it can lead to very messy syntax errors afterwards.
Instead the parser should continue parsing statements as usual, but show a separate diagnostic pointing out that they cannot appear after return or break statements.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions