-
Notifications
You must be signed in to change notification settings - Fork 23
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
Internal symbols array is publicly exposed and unsound #75
Comments
The implementation itself (`InternalEncoding`) is already hidden, but the field in the definition of `Encoding` is not. Fixes #75
The implementation itself (`InternalEncoding`) is already hidden, but the field in the definition of `Encoding` is not. Fixes #75
Thanks for the bug report! I didn't know it was possible to have Note that eventually, when |
The implementation itself (`InternalEncoding`) is already hidden, but the field in the definition of `Encoding` is not. Fixes #75
@ia0 it may also be worth renaming the field something suitably scary, because it is relatively easy to not notice that I'd also recommend against using doc(hidden) fields when there are unsafe invariants; if possible it would be better to expose a |
Yes, I think the |
Yeah I think a |
This does involve tweaking the field of the
Encoding
, but that's a public and notdoc(hidden)
field. At the very least it should bedoc(hidden)
.(at a meta level, this code would probably benefit from some kind of internal
#[repr(transparent)] pub Ascii(u8);
type so that it is very clear that the invariants are being upheld)The text was updated successfully, but these errors were encountered: