Skip to content

Trailing if statements without a body inside a block parse really weirdly #74

@thinker227

Description

@thinker227

Currently this code parses as if the closing } is the closing brace of the body of the incomplete if statement. This is extremely confusing, it would be better if it parsed as an if where the entire body is missing and the surrounding block is perfectly fine.

{
    if x
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions