diff options
Diffstat (limited to 'crates/mbe/src/subtree_source.rs')
-rw-r--r-- | crates/mbe/src/subtree_source.rs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/crates/mbe/src/subtree_source.rs b/crates/mbe/src/subtree_source.rs index 396ce8b16..ccc56c479 100644 --- a/crates/mbe/src/subtree_source.rs +++ b/crates/mbe/src/subtree_source.rs | |||
@@ -7,9 +7,9 @@ use tt::buffer::{Cursor, TokenBuffer}; | |||
7 | 7 | ||
8 | #[derive(Debug, Clone, Eq, PartialEq)] | 8 | #[derive(Debug, Clone, Eq, PartialEq)] |
9 | struct TtToken { | 9 | struct TtToken { |
10 | pub kind: SyntaxKind, | 10 | kind: SyntaxKind, |
11 | pub is_joint_to_next: bool, | 11 | is_joint_to_next: bool, |
12 | pub text: SmolStr, | 12 | text: SmolStr, |
13 | } | 13 | } |
14 | 14 | ||
15 | pub(crate) struct SubtreeTokenSource<'a> { | 15 | pub(crate) struct SubtreeTokenSource<'a> { |
@@ -21,7 +21,7 @@ pub(crate) struct SubtreeTokenSource<'a> { | |||
21 | impl<'a> SubtreeTokenSource<'a> { | 21 | impl<'a> SubtreeTokenSource<'a> { |
22 | // Helper function used in test | 22 | // Helper function used in test |
23 | #[cfg(test)] | 23 | #[cfg(test)] |
24 | pub fn text(&self) -> SmolStr { | 24 | pub(crate) fn text(&self) -> SmolStr { |
25 | match *self.get(self.curr.1) { | 25 | match *self.get(self.curr.1) { |
26 | Some(ref tt) => tt.text.clone(), | 26 | Some(ref tt) => tt.text.clone(), |
27 | _ => SmolStr::new(""), | 27 | _ => SmolStr::new(""), |
@@ -30,7 +30,7 @@ impl<'a> SubtreeTokenSource<'a> { | |||
30 | } | 30 | } |
31 | 31 | ||
32 | impl<'a> SubtreeTokenSource<'a> { | 32 | impl<'a> SubtreeTokenSource<'a> { |
33 | pub fn new(buffer: &'a TokenBuffer) -> SubtreeTokenSource<'a> { | 33 | pub(crate) fn new(buffer: &'a TokenBuffer) -> SubtreeTokenSource<'a> { |
34 | let cursor = buffer.begin(); | 34 | let cursor = buffer.begin(); |
35 | 35 | ||
36 | let mut res = SubtreeTokenSource { | 36 | let mut res = SubtreeTokenSource { |