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

Pass index argument to getfield function #463

Merged
merged 2 commits into from
Nov 3, 2023
Merged

Conversation

ShinWonho
Copy link
Contributor

@ShinWonho ShinWonho commented Nov 3, 2023

As far as I know, array.get instruction requires a type index, so type index should be passed to getfield function.

Screenshot 2023-11-03 at 1 57 00 PM
  • Current specification
Screenshot 2023-11-03 at 2 02 53 PM
  • Suggested change

Copy link
Member

@rossberg rossberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, thanks!

But note that this wants the source type, so it ought to be y. (There was a similar bug in spectec wasm3, which I just fixed.)

Also, getfield is sort of a local definition in a "where" clause, so we can assume that it can use y directly, it doesn't need to be passed as a parameter.

@ShinWonho
Copy link
Contributor Author

Screenshot 2023-11-03 at 5 36 10 PM

Thanks for the review!
Now, I fixed it.

Copy link
Member

@rossberg rossberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@rossberg rossberg merged commit 267426c into WebAssembly:main Nov 3, 2023
4 checks passed
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

Successfully merging this pull request may close these issues.

2 participants