Skip to content

s2wasm emits invalid drops or types #708

@kripken

Description

@kripken

e.g. in test/dot_s/alias.wast,

  (type $FUNCSIG$v (func))
  (func $__exit (type $FUNCSIG$v)
    (return
      (i32.add [..])
    )
  )
  (func $__needs_exit (result i32)
    (drop
      (call $__exit)
    )

So __exit is declared as not returning, but does have a return for some reason, and is dropped in __needs_exit. I'm not sure if the drop is wrong or the type is wrong or both (not sure how to read the .s file to tell).

cc @dschuff @sunfishcode

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