-
Notifications
You must be signed in to change notification settings - Fork 829
Make final types the default #5918
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,5 @@ | ||
| (module | ||
| (type $struct (struct (field i32))) | ||
| (type $struct (sub (struct (field i32)))) | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why did this change?
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is a non-final type. Now that we interpret the shorthand
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm still confused then, sorry. Why is this non-final? Final is the default, and I don't see "open" here, so isn't it final?
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Right now Binaryen's text format does not include any of the changes from WebAssembly/gc#413, so |
||
| (type $1 (func (result i32))) | ||
| (global $ctor-eval$global_4 (ref $struct) (struct.new $struct | ||
| (i32.const 9999) | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do the new types need to be open? I'd expect the opposite, since they are fresh types created here with no subtypes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was the easiest way to get the test for clashing rec groups to work out. It should be fine, since the optimal thing for us to be doing is to make all types open up front and then have another pass (not written yet) to close all the types we can at the end.