-
Notifications
You must be signed in to change notification settings - Fork 740
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
Missing error when struct.new
has too many arguments in assembler
#6739
Comments
Unfortunately the wat text format considers code like this equal: (struct.new $t (local.get 0))
(local.get 0)
(struct.new $t) So the parser has to accept it. Though if an error happens later, as in this testcase, then we could perhaps look back at the wat to see if we can print a better error message. But connecting the validator to the wat text that was already fully processed at that point might not be easy. @tlively what do you think? |
In particular, when the parser parses the |
When assembling the following invalid WAT code:
the assembler rejects it with the following error message:
I think, it will be better that it generates an error about the fact that
struct.new
has too many arguments.The text was updated successfully, but these errors were encountered: