summaryrefslogtreecommitdiffstats
path: root/tests/ui/rfcs/rfc-3348-c-string-literals/non-ascii.rs
blob: 066505c23dfc0f63bf8d7757dbe004034369f227 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
// FIXME(c_str_literals): This should be `run-pass`
// known-bug: #113333
// edition: 2021

#![feature(c_str_literals)]

fn main() {
    assert_eq!(
        c"\xEF\x80🦀\u{1F980}".to_bytes_with_nul(),
        &[0xEF, 0x80, 0xF0, 0x9F, 0xA6, 0x80, 0xF0, 0x9F, 0xA6, 0x80, 0x00],
    );
}