zed
zed copied to clipboard
(GPUI issue) Zed crashes when encountering a color containing different chars with the same symbol in a theme
Check for existing issues
- [X] Completed
Describe the bug / provide steps to reproduce it
Say you have a color code #fаfаfa and the a's in this color color are for one part the latin character a and for the other the cyrillic character а, which has a different unicode codepoint. If you passed this color code inside of a theme to zed, the function crates/gpui/src/color.rs::[impl TryFrom<&'_ str> for Rgba]::try_from(value: &'_ str) would create a very confusing panic:
byte index 2 is not a char boundary; it is inside 'а' (bytes 1..3) of fаfаfa
Please see this other issue for Reference: #11997
Environment
Platform-independend
If applicable, attach your ~/Library/Logs/Zed/Zed.log file to this issue.
No response