aboutsummaryrefslogtreecommitdiff
path: root/crates/libsyntax2/src/yellow/syntax.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/libsyntax2/src/yellow/syntax.rs')
-rw-r--r--crates/libsyntax2/src/yellow/syntax.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/libsyntax2/src/yellow/syntax.rs b/crates/libsyntax2/src/yellow/syntax.rs
index ede9ad3c8..444dbeb30 100644
--- a/crates/libsyntax2/src/yellow/syntax.rs
+++ b/crates/libsyntax2/src/yellow/syntax.rs
@@ -153,7 +153,7 @@ impl<R: TreeRoot> SyntaxNode<R> {
153 } 153 }
154 154
155 pub fn leaf_text(&self) -> Option<SmolStr> { 155 pub fn leaf_text(&self) -> Option<SmolStr> {
156 self.red().green().leaf_text() 156 self.borrowed().leaf_text_ref().map(|it| it.clone())
157 } 157 }
158 158
159 pub(crate) fn replace_with(&self, green: GreenNode) -> GreenNode { 159 pub(crate) fn replace_with(&self, green: GreenNode) -> GreenNode {