mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-30 05:45:12 +00:00
Keep SyntaxNodePtr::range private
This commit is contained in:
parent
66cea8cbaa
commit
fb0ab9f745
4 changed files with 17 additions and 9 deletions
|
@ -23,10 +23,6 @@ impl SyntaxNodePtr {
|
|||
SyntaxNodePtr { range: node.text_range(), kind: node.kind() }
|
||||
}
|
||||
|
||||
pub fn text_range(&self) -> TextRange {
|
||||
self.range.clone()
|
||||
}
|
||||
|
||||
pub fn to_node(&self, root: &SyntaxNode) -> SyntaxNode {
|
||||
assert!(root.parent().is_none());
|
||||
successors(Some(root.clone()), |node| {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue