Skip to content
This repository was archived by the owner on Apr 25, 2025. It is now read-only.
This repository was archived by the owner on Apr 25, 2025. It is now read-only.

Clarify if_except text format #51

Closed
@binji

Description

@binji

The if_except format is described like this:

if_except block_type except_index
  Instruction*
end

But this doesn't include the optional label, which all other block types have. Assuming that comes first, as with others, it should be:

if_except label_opt block_type except_index
  Instruction*
end

This introduces a slightly tricky parse:

(except $e i32)
...
if_except $e
end

In this case, $e is the exception index, but that's not known until end, as it could be the label name.

It's not too hard to make this parse, but I wonder if it would be better to put the exception_index first instead to simplify things.

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