rust/tests/ui/parser/macro/literals-are-validated-before-expansion.rs

11 lines
247 B
Rust
Raw Normal View History

macro_rules! black_hole {
($($tt:tt)*) => {}
}
fn main() {
black_hole! { '\u{FFFFFF}' }
//~^ ERROR: invalid unicode character escape
black_hole! { "this is surrogate: \u{DAAA}" }
//~^ ERROR: invalid unicode character escape
}