-
Notifications
You must be signed in to change notification settings - Fork 2
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
Stringref as a toolchain concept #64
Comments
But one of the major goals of stringref is to provide efficient interop with the host (e.g. JavaScript). Using an Another major goal of stringref is to avoid hardcoding a single encoding, but So |
|
An update: replacing In the case of the Hoot compiler, we only emit dynamic checks against |
So, the CG does not currently have consensus to move stringref forward. It may in the future, but that's not where we're at right now.
For the moment, the Hoot compiler does emit stringref, but to ship to current WebAssembly, it lowers strings to WTF-8 arrays (
array i8
). For information on what kinds of use-cases stringref is fulfilling for Hoot, see the lower-stringref pass: https://gitlab.com/spritely/guile-hoot/-/blob/main/module/wasm/lower-stringrefs.scm. There is a discussion of the tradeoffs in the top of that file.So, in summary, it is possible to be productive with stringref on the toolchain level, even in the world where stringref is not available on the wasm hosts.
The text was updated successfully, but these errors were encountered: