-
Notifications
You must be signed in to change notification settings - Fork 17
Make anyfunc an alias of funcref #34
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 2 commits
cbc8527
5d432ee
e411acb
6402a30
9aa66d5
fa0897b
9a9a143
eb42622
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 |
|---|---|---|
|
|
@@ -794,7 +794,7 @@ The <dfn method for="Memory">type()</dfn> method steps are: | |
| <pre class="idl"> | ||
| enum TableKind { | ||
| "externref", | ||
| "anyfunc", | ||
| "funcref", | ||
| // Note: More values may be added in future iterations, | ||
| // e.g., typed function references, typed GC references | ||
| }; | ||
|
|
@@ -848,7 +848,7 @@ Each {{Table}} object has a \[[Table]] internal slot, which is a [=table address | |
|
|
||
| The algorithm <dfn abstract-op>ToTableKind</dfn>(|t|) performs the following steps: | ||
|
|
||
| 1. If |t| equals [=funcref=], return "{{TableKind/anyfunc}}". | ||
| 1. If |t| equals [=funcref=], return "{{TableKind/funcref}}". | ||
| 1. If |t| equals [=externref=], return "{{TableKind/externref}}". | ||
| 1. Assert: This step is not reached. | ||
|
|
||
|
|
@@ -950,7 +950,7 @@ enum ValueType { | |
| "f32", | ||
| "f64", | ||
| "externref", | ||
| "anyfunc", | ||
| "funcref", | ||
|
Comment on lines
953
to
+954
Contributor
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. You should keep both, and test that
Contributor
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. How would it work if we keep both? Wouldn't that mean that they are different types? How should I define then what the result of
Contributor
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. Internally, we only use the "core" types, and the IDL enum here is only a way to expose them to JS.
Contributor
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. You are saying that this is the set of strings that is allowed to be used in a |
||
| }; | ||
| </pre> | ||
|
|
||
|
|
@@ -1002,6 +1002,7 @@ which can be simultaneously referenced by multiple {{Instance}} objects. Each | |
| 1. If |s| equals "i64", return [=i64=]. | ||
| 1. If |s| equals "f32", return [=f32=]. | ||
| 1. If |s| equals "f64", return [=f64=]. | ||
| 1. If |s| equals "funcref", return [=funcref=]. | ||
| 1. If |s| equals "anyfunc", return [=funcref=]. | ||
| 1. If |s| equals "externref", return [=externref=]. | ||
| 1. Assert: This step is not reached. | ||
|
|
@@ -1015,7 +1016,7 @@ The algorithm <dfn abstract-op>FromValueType</dfn>(|s|) performs the following s | |
| 1. If |s| equals [=i64=], return "{{ValueType/i64}}". | ||
| 1. If |s| equals [=f32=], return "{{ValueType/f32}}". | ||
| 1. If |s| equals [=f64=], return "{{ValueType/f64}}". | ||
| 1. If |s| equals [=funcref=], return "{{ValueType/anyfunc}}". | ||
| 1. If |s| equals [=funcref=], return "{{ValueType/funcref}}". | ||
| 1. If |s| equals [=externref=], return "{{ValueType/externref}}". | ||
| 1. Assert: This step is not reached. | ||
|
|
||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.