mirror of
https://github.com/rust-lang/rust.git
synced 2025-11-25 07:16:54 +00:00
Added error for invalid char cast fixes rust-lang/rust#143597 not really sure if I did it right, but according to cast-char test -- it is right, also this code gave me false positive result ``` for _ in 0..(256 as u8) {} ``` so this is why I added this check `if lit_val <= 0xFF` Also I believe that error message could be improved, but I'm not sure how exactly cc ```@hkBst``` r? compiler