You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Go supports the use of multiple results. So does WebAssembly. However, due to compiler limitations, TinyGo cannot yet produce WebAssembly that uses the supported WebAssembly syntax.
TinyGo uses a workaround of placing multiple values into linear memory for consumption by the embedder. The embedder must supply the address (a byte offset) in linear memory where the values are to be stored.
This issue contains a full explanation of how multi-value works in TinyGo, and an example of how to implement Javascript that consumes multiple values. The guide on Using WebAssembly should have a section describing this functionality.
The text was updated successfully, but these errors were encountered:
However, due to compiler limitations, TinyGo cannot yet produce WebAssembly that uses the supported WebAssembly syntax.
No. These are not compiler limitations. We do this for backwards compatibility. I think you can enable multi-value using something like -llvm-features=multivalue but I haven't tested this.
Go supports the use of multiple results. So does WebAssembly. However, due to compiler limitations, TinyGo cannot yet produce WebAssembly that uses the supported WebAssembly syntax.
TinyGo uses a workaround of placing multiple values into linear memory for consumption by the embedder. The embedder must supply the address (a byte offset) in linear memory where the values are to be stored.
This issue contains a full explanation of how multi-value works in TinyGo, and an example of how to implement Javascript that consumes multiple values. The guide on Using WebAssembly should have a section describing this functionality.
The text was updated successfully, but these errors were encountered: