Stream: git-wasmtime

Topic: wasmtime / issue #4361 Support enums with more then 256 v...


view this post on Zulip Wasmtime GitHub notifications bot (Jun 30 2022 at 21:20):

dicej opened issue #4361:

As of https://github.com/bytecodealliance/wasmtime/pull/4359, the ComponentType/Lift/Lower derive macros can't handle enums with more than 256 variants because they assume the discriminant is a single byte. This limitation should be easy enough to remove.

This looks fantastic to me, thanks for this! I've got one question about the u8 limit, but if it's what I suspect (just more effort needed) mind filing a follow-up issue? I think it's ok to leave as-is for awhile since we're unlikely to get >256 variant-things any time in the near future.

_Originally posted by @alexcrichton in https://github.com/bytecodealliance/wasmtime/pull/4359#pullrequestreview-1025451951_

view this post on Zulip Wasmtime GitHub notifications bot (Jun 30 2022 at 23:18):

alexcrichton labeled issue #4361:

As of https://github.com/bytecodealliance/wasmtime/pull/4359, the ComponentType/Lift/Lower derive macros can't handle enums with more than 256 variants because they assume the discriminant is a single byte. This limitation should be easy enough to remove.

This looks fantastic to me, thanks for this! I've got one question about the u8 limit, but if it's what I suspect (just more effort needed) mind filing a follow-up issue? I think it's ok to leave as-is for awhile since we're unlikely to get >256 variant-things any time in the near future.

_Originally posted by @alexcrichton in https://github.com/bytecodealliance/wasmtime/pull/4359#pullrequestreview-1025451951_


Last updated: Oct 23 2024 at 20:03 UTC