]> git.lizzy.rs Git - rust.git/blob - tests/target/raw_identifiers.rs
Handle raw identifiers in chain
[rust.git] / tests / target / raw_identifiers.rs
1 #![feature(custom_attribute)]
2 #![feature(raw_identifiers)]
3 #![feature(extern_types)]
4 #![allow(invalid_type_param_default)]
5 #![allow(unused_attributes)]
6
7 use r#foo as r#alias_foo;
8
9 fn main() {
10     #[r#attr]
11     r#foo::r#bar();
12
13     let r#local = r#Struct { r#field: () };
14     r#local.r#field = 1;
15     r#foo.r#barr();
16     let r#async = r#foo(r#local);
17     r#macro!();
18
19     if let r#sub_pat @ r#Foo(_) = r#Foo(3) {}
20
21     match r#async {
22         r#Foo | r#Bar => r#foo(),
23     }
24 }
25
26 fn r#bar<'a, r#T>(r#x: &'a r#T) {}
27
28 mod r#foo {
29     pub fn r#bar() {}
30 }
31
32 enum r#Foo {
33     r#Bar {},
34 }
35
36 struct r#Struct {
37     r#field: r#FieldType,
38 }
39
40 trait r#Trait {
41     type r#Type;
42 }
43
44 impl r#Trait for r#Impl {
45     type r#Type = r#u32;
46     fn r#xxx(r#fjio: r#u32) {}
47 }
48
49 extern "C" {
50     type r#ccc;
51     static r#static_val: u32;
52 }
53
54 macro_rules! r#macro {
55     () => {};
56 }
57
58 macro_rules! foo {
59     ($x:expr) => {
60         let r#catch = $x + 1;
61         println!("{}", r#catch);
62     };
63 }