diff options
Diffstat (limited to 'src/syntax_kinds/generated.rs.tera')
-rw-r--r-- | src/syntax_kinds/generated.rs.tera | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/syntax_kinds/generated.rs.tera b/src/syntax_kinds/generated.rs.tera index 2a47c6632..d719c8312 100644 --- a/src/syntax_kinds/generated.rs.tera +++ b/src/syntax_kinds/generated.rs.tera | |||
@@ -58,5 +58,18 @@ impl SyntaxKind { | |||
58 | }; | 58 | }; |
59 | Some(tok) | 59 | Some(tok) |
60 | } | 60 | } |
61 | |||
62 | pub(crate) fn static_text(self) -> Option<&'static str> { | ||
63 | let tok = match self { | ||
64 | {%- for t in concat(a=single_byte_tokens, b=multi_byte_tokens) %} | ||
65 | {{t.1}} => "{{t.0}}", | ||
66 | {%- endfor %} | ||
67 | {% for kw in concat(a=keywords, b=contextual_keywords) %} | ||
68 | {{kw | upper}}_KW => "{{kw}}", | ||
69 | {%- endfor %} | ||
70 | _ => return None, | ||
71 | }; | ||
72 | Some(tok) | ||
73 | } | ||
61 | } | 74 | } |
62 | 75 | ||