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

Fix "duplicate identifier for field" for subtype fields #1117

Merged
merged 5 commits into from
Jul 12, 2023

Conversation

imikushin
Copy link
Contributor

Field namespaces are per struct now. Inherited fields' names must be exactly the same as in the super-type.

Fixes #1092.

Field namespaces are per struct now. Inherited fields' names must be exactly the same as in the super-type.

Fixes bytecodealliance#1092.
Copy link
Member

@alexcrichton alexcrichton left a comment

Choose a reason for hiding this comment

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

Thanks, I think it would be worth adding more tests here too which exercise the implementation as well for example by passing struct.get instructions with varying levels of validity in the indices specified.

crates/wast/src/core/resolve/names.rs Outdated Show resolved Hide resolved
crates/wast/src/core/resolve/names.rs Outdated Show resolved Hide resolved
crates/wast/src/names.rs Outdated Show resolved Hide resolved
tests/local/gc/gc-subtypes-invalid.wast Outdated Show resolved Hide resolved
@alexcrichton alexcrichton merged commit aa16158 into bytecodealliance:main Jul 12, 2023
15 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.

wasmparser: "duplicate identifier for field" in subtype
2 participants