-
Notifications
You must be signed in to change notification settings - Fork 94
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
Errors include unprintable or awkwardly printed characters. #333
Comments
It'd be nice if I'd be willing to implement this, just want the go ahead first. |
I assume we'd either do a debug representation of the string or only do this if the string is 1 character long. |
Just using https://doc.rust-lang.org/std/primitive.str.html#method.escape_default and the same method of |
I think the main question is handling of unicode, whether those should be escaped or not. I think most users can see and understand a unicode character but the escaped form is a It can be a good start though |
My proposal is we'd escape
I'd personally not escape The challenge with any of this is the |
That list seems fine to me, it can always be tweaked later. |
cargo has a test that tries null characters: https://github.com/rust-lang/cargo/pull/10086/files#diff-4980c43ff583070e4cb20d00368e0c15d57a0c0127d7ddc5676e1ee12b899d18R927
it also exposes that a newline is shown for errors: toml-rs/toml#259
The text was updated successfully, but these errors were encountered: