Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wat2wasm fails converting .wast files in testsuite: error: unexpected token (, expected EOF. #2375

Closed
AbeWJS opened this issue Jan 29, 2024 · 4 comments

Comments

@AbeWJS
Copy link

AbeWJS commented Jan 29, 2024

Fresh clone of WABT on macOS built with CMake and make results in wat2wasm reporting errors like this one:

local build % ./wat2wasm ../third_party/testsuite/f32.wast -o ~/wasm_test.wasm ../third_party/testsuite/f32.wast:19:1: error: unexpected token (, expected EOF. (assert_return (invoke "add" (f32.const -0x0p+0) (f32.const -0x0p+0)) (f32.co... ^

Perhaps a configuration issue, but unsure why this would happen, everything suggests this should work out of the box.

@AbeWJS
Copy link
Author

AbeWJS commented Jan 29, 2024

Ah, is this just the assert firing as ARM isn't supported?

@SoniEx2
Copy link
Contributor

SoniEx2 commented Jan 29, 2024

wat (webassembly text format) 2 wasm does not support wast (which we believe originally stood for webassembly spec test?) files

@sbc100
Copy link
Member

sbc100 commented Jan 29, 2024

If you want to process .wast files, the only option in wabt is wast2json.

As mentioned above, the other other tools only accept wat and wasm files.

@sbc100 sbc100 closed this as completed Jan 29, 2024
@AbeWJS
Copy link
Author

AbeWJS commented Jan 29, 2024

Aye, understood. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants