Skip to content

[spec] Should functions return a resulttype? #559

@littledan

Description

@littledan

Looking at https://webassembly.github.io/spec/syntax/types.html#function-types , I was wondering if

functype::=[vec(valtype)]→[vec(valtype)]

Should actually be defined as

functype::=[vec(valtype)]→resulttype

given that resulttype was defined immediately prior, is not used in the AST, and would make sense as a way to enforce in the grammar that there is at most one value (which is otherwise only enforced in a note as far as I can tell).

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