aboutsummaryrefslogtreecommitdiff
path: root/crates/syntax/src/ast
diff options
context:
space:
mode:
authorDawer <[email protected]>2021-05-06 06:07:06 +0100
committerDawer <[email protected]>2021-05-06 06:07:06 +0100
commit0a156c80af8df24543323bdf47d75c5a339cfe48 (patch)
tree91b2769ecfb11632b9f20e9f1e13dcca28df7582 /crates/syntax/src/ast
parentd9b4ac81285985f384d1a9f0708ba54434b7f231 (diff)
Hide implementation details of TokenText
Diffstat (limited to 'crates/syntax/src/ast')
-rw-r--r--crates/syntax/src/ast/node_ext.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/syntax/src/ast/node_ext.rs b/crates/syntax/src/ast/node_ext.rs
index 88f9a0e97..bef49238f 100644
--- a/crates/syntax/src/ast/node_ext.rs
+++ b/crates/syntax/src/ast/node_ext.rs
@@ -40,8 +40,8 @@ fn text_of_first_token(node: &SyntaxNode) -> TokenText<'_> {
40 } 40 }
41 41
42 match node.green() { 42 match node.green() {
43 Cow::Borrowed(green_ref) => TokenText::Borrowed(first_token(green_ref).text()), 43 Cow::Borrowed(green_ref) => TokenText::borrowed(first_token(green_ref).text()),
44 Cow::Owned(green) => TokenText::Owned(first_token(&green).to_owned()), 44 Cow::Owned(green) => TokenText::owned(first_token(&green).to_owned()),
45 } 45 }
46} 46}
47 47