diff options
Diffstat (limited to 'crates/ra_syntax/src/syntax_kinds')
-rw-r--r-- | crates/ra_syntax/src/syntax_kinds/generated.rs | 1 | ||||
-rw-r--r-- | crates/ra_syntax/src/syntax_kinds/generated.rs.tera | 1 | ||||
-rw-r--r-- | crates/ra_syntax/src/syntax_kinds/mod.rs | 26 |
3 files changed, 0 insertions, 28 deletions
diff --git a/crates/ra_syntax/src/syntax_kinds/generated.rs b/crates/ra_syntax/src/syntax_kinds/generated.rs index c43a8bf65..3a869ad34 100644 --- a/crates/ra_syntax/src/syntax_kinds/generated.rs +++ b/crates/ra_syntax/src/syntax_kinds/generated.rs | |||
@@ -560,4 +560,3 @@ impl SyntaxKind { | |||
560 | Some(tok) | 560 | Some(tok) |
561 | } | 561 | } |
562 | } | 562 | } |
563 | |||
diff --git a/crates/ra_syntax/src/syntax_kinds/generated.rs.tera b/crates/ra_syntax/src/syntax_kinds/generated.rs.tera index c37e57702..21f9444b1 100644 --- a/crates/ra_syntax/src/syntax_kinds/generated.rs.tera +++ b/crates/ra_syntax/src/syntax_kinds/generated.rs.tera | |||
@@ -75,4 +75,3 @@ impl SyntaxKind { | |||
75 | Some(tok) | 75 | Some(tok) |
76 | } | 76 | } |
77 | } | 77 | } |
78 | |||
diff --git a/crates/ra_syntax/src/syntax_kinds/mod.rs b/crates/ra_syntax/src/syntax_kinds/mod.rs deleted file mode 100644 index d53886676..000000000 --- a/crates/ra_syntax/src/syntax_kinds/mod.rs +++ /dev/null | |||
@@ -1,26 +0,0 @@ | |||
1 | mod generated; | ||
2 | |||
3 | use crate::SyntaxKind::*; | ||
4 | use std::fmt; | ||
5 | |||
6 | pub use self::generated::SyntaxKind; | ||
7 | |||
8 | impl fmt::Debug for SyntaxKind { | ||
9 | fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { | ||
10 | let name = self.info().name; | ||
11 | f.write_str(name) | ||
12 | } | ||
13 | } | ||
14 | |||
15 | pub(crate) struct SyntaxInfo { | ||
16 | pub name: &'static str, | ||
17 | } | ||
18 | |||
19 | impl SyntaxKind { | ||
20 | pub fn is_trivia(self) -> bool { | ||
21 | match self { | ||
22 | WHITESPACE | COMMENT => true, | ||
23 | _ => false, | ||
24 | } | ||
25 | } | ||
26 | } | ||