diff options
Diffstat (limited to 'crates/ra_syntax/src/reparsing.rs')
-rw-r--r-- | crates/ra_syntax/src/reparsing.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/crates/ra_syntax/src/reparsing.rs b/crates/ra_syntax/src/reparsing.rs index 3c4ea5c22..d48133166 100644 --- a/crates/ra_syntax/src/reparsing.rs +++ b/crates/ra_syntax/src/reparsing.rs | |||
@@ -180,7 +180,7 @@ fn merge_errors( | |||
180 | #[cfg(test)] | 180 | #[cfg(test)] |
181 | mod tests { | 181 | mod tests { |
182 | use super::{ | 182 | use super::{ |
183 | super::{test_utils::extract_range, text_utils::replace_range, utils::dump_tree, File}, | 183 | super::{test_utils::extract_range, text_utils::replace_range, utils::dump_tree, SourceFileNode}, |
184 | reparse_block, reparse_leaf, AtomEdit, GreenNode, SyntaxError, SyntaxNodeRef, | 184 | reparse_block, reparse_leaf, AtomEdit, GreenNode, SyntaxError, SyntaxNodeRef, |
185 | }; | 185 | }; |
186 | 186 | ||
@@ -192,9 +192,9 @@ mod tests { | |||
192 | let (range, before) = extract_range(before); | 192 | let (range, before) = extract_range(before); |
193 | let after = replace_range(before.clone(), range, replace_with); | 193 | let after = replace_range(before.clone(), range, replace_with); |
194 | 194 | ||
195 | let fully_reparsed = File::parse(&after); | 195 | let fully_reparsed = SourceFileNode::parse(&after); |
196 | let incrementally_reparsed = { | 196 | let incrementally_reparsed = { |
197 | let f = File::parse(&before); | 197 | let f = SourceFileNode::parse(&before); |
198 | let edit = AtomEdit { | 198 | let edit = AtomEdit { |
199 | delete: range, | 199 | delete: range, |
200 | insert: replace_with.to_string(), | 200 | insert: replace_with.to_string(), |
@@ -203,7 +203,7 @@ mod tests { | |||
203 | reparser(f.syntax(), &edit).expect("cannot incrementally reparse"); | 203 | reparser(f.syntax(), &edit).expect("cannot incrementally reparse"); |
204 | let green_root = node.replace_with(green); | 204 | let green_root = node.replace_with(green); |
205 | let errors = super::merge_errors(f.errors(), new_errors, node, &edit); | 205 | let errors = super::merge_errors(f.errors(), new_errors, node, &edit); |
206 | File::new(green_root, errors) | 206 | SourceFileNode::new(green_root, errors) |
207 | }; | 207 | }; |
208 | 208 | ||
209 | assert_eq_text!( | 209 | assert_eq_text!( |