Skip to content
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

Ensure strings are always UTF-8 #34

Open
3 tasks
mbeckem opened this issue Mar 17, 2022 · 0 comments
Open
3 tasks

Ensure strings are always UTF-8 #34

mbeckem opened this issue Mar 17, 2022 · 0 comments

Comments

@mbeckem
Copy link
Owner

mbeckem commented Mar 17, 2022

Ensure that string objects in the vm are always utf-8 encoded.

This is already the case for strings created from literals, but the C API and dynamic constructors should enforce this as well.

  • VM: Assert that static strings inside bytecode modules use utf-8 encoding
  • C-API: Check string encoding, return error if not utf-8
  • String constructor: Check string encoding, return error if not utf-8 (maybe also provide a non-panicking constructor function)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant