1 #[cfg_attr(rustfmt, rustfmt_skip)]
2 static RUST_KEYWORDS: &'static [&'static str] = &[
3     "as",
4     "async",
5     "await",
6     "break",
7     "crate",
8     "dyn",
9     "else",
10     "enum",
11     "extern",
12     "false",
13     "fn",
14     "for",
15     "if",
16     "impl",
17     "in",
18     "let",
19     "loop",
20     "match",
21     "mod",
22     "move",
23     "mut",
24     "pub",
25     "ref",
26     "return",
27     "static",
28     "self",
29     "Self",
30     "struct",
31     "super",
32     "true",
33     "trait",
34     "type",
35     "unsafe",
36     "use",
37     "while",
38     "continue",
39     "box",
40     "const",
41     "where",
42     "virtual",
43     "proc",
44     "alignof",
45     "become",
46     "offsetof",
47     "priv",
48     "pure",
49     "sizeof",
50     "typeof",
51     "unsized",
52     "yield",
53     "do",
54     "abstract",
55     "final",
56     "override",
57     "macro",
58 ];
59 
is_rust_keyword(ident: &str) -> bool60 pub fn is_rust_keyword(ident: &str) -> bool {
61     RUST_KEYWORDS.contains(&ident)
62 }
63