fitzgen opened PR #8542 from fitzgen:eq-and-noextern-heap-types
to bytecodealliance:main
:
With this commit, we now support all GC heap types.
<!--
Please make sure you include the following information:
If this work has been discussed elsewhere, please include a link to that
conversation. If it was discussed in an issue, just mention "issue #...".Explain why this change is needed. If the details are in an issue already,
this can be brief.Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.htmlPlease ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->
fitzgen requested alexcrichton for a review on PR #8542.
fitzgen requested wasmtime-core-reviewers for a review on PR #8542.
alexcrichton submitted PR review.
alexcrichton submitted PR review.
alexcrichton created PR review comment:
Out of curiosity is the term "internal" used at the spec level as well? It makes sense to mirror "external" but I figured these'd be called "any types" or... something along those lines. Anyway I'm just musing here.
alexcrichton created PR review comment:
The word "with" here makes me think that cats are replaced with animals, but I think you're intending the opposite here, so perhaps something like "s/with/for/"?
alexcrichton created PR review comment:
Wait sort of unrelated question on this, in the type section you can explicitly list the supertype and there's also
is_final
which say "no one else can subtype this". With the logic you're explaining below though that's not quite right is it? Anis_final
function type can still be subtyped so long as you align the parameters correctly?(totally unrelated to this PR I'm just trying to reconcile two different ways I've understood how subtyping is done in wasm)
alexcrichton created PR review comment:
Ascii Art Diagrams: The Return Of The King
fitzgen submitted PR review.
fitzgen created PR review comment:
Yeah I've seen it around, eg https://github.com/WebAssembly/gc/blob/main/proposals/gc/MVP.md#heap-types
Also turning an
externref
into ananyref
is called "internalizing"
fitzgen submitted PR review.
fitzgen created PR review comment:
:crown:
fitzgen submitted PR review.
fitzgen created PR review comment:
Yeah honestly I don't fully understand how all the dots connect in the way that the spec is written/defined, I just know what the intended behavior is.
FWIW, we don't supertypes and finality yet, but this code (and I suppose these docs) will need to be updated at that point.
fitzgen submitted PR review.
fitzgen created PR review comment:
With the logic you're explaining below though that's not quite right is it? An
is_final
function type can still be subtyped so long as you align the parameters correctly?And to be clear, yeah you can't subtype something (including a func type) that is declared final.
fitzgen merged PR #8542.
Last updated: Dec 23 2024 at 13:07 UTC