2018-02-06 07:57:08 -06:00
|
|
|
#![deny(overflowing_literals)]
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
const XYZ: char = 0x1F888 as char;
|
2019-04-27 06:56:57 -05:00
|
|
|
//~^ ERROR only `u8` can be cast into `char`
|
2018-02-06 07:57:08 -06:00
|
|
|
const XY: char = 129160 as char;
|
2019-04-27 06:56:57 -05:00
|
|
|
//~^ ERROR only `u8` can be cast into `char`
|
2018-02-06 07:57:08 -06:00
|
|
|
const ZYX: char = '\u{01F888}';
|
|
|
|
println!("{}", XYZ);
|
|
|
|
}
|