-
Notifications
You must be signed in to change notification settings - Fork 5.4k
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
fix(repl): don't panic on lone surrogates #12899
Conversation
This commit fixes the pancis that occur when a user does various actions using strings containing lone surrogates in the REPL. It does this by introducing a new `LossyString` type that implements `serde::Deserialize`. This deserializer supprots deserializing JSON strings that contain lone surrogates. It replaces lone surrogates with the unicode replacement character.
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. |
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. |
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. |
This commit fixes the pancis that occur when a user does various actions
using strings containing lone surrogates in the REPL. It does this by
introducing a new
LossyString
type that implementsserde::Deserialize
. This deserializer supprots deserializing JSONstrings that contain lone surrogates. It replaces lone surrogates with
the unicode replacement character.
Fixes #12226 and #12447.
Waiting on merge and release of serde-rs/json#830.