Make Tree::changed_ranges return an Iterator instead of a Vec (#437)
* Make Tree::changed_ranges return an Iterator instead of a Vec * Remove CBufferIter.free parameter
This commit is contained in:
parent
d5b5d473ab
commit
d96ba09391
5 changed files with 49 additions and 19 deletions
|
|
@ -767,7 +767,7 @@ fn test_parsing_with_a_newly_excluded_range() {
|
|||
);
|
||||
|
||||
assert_eq!(
|
||||
tree.changed_ranges(&first_tree),
|
||||
tree.changed_ranges(&first_tree).collect::<Vec<_>>(),
|
||||
vec![
|
||||
// The first range that has changed syntax is the range of the newly-inserted text.
|
||||
Range {
|
||||
|
|
@ -837,7 +837,7 @@ fn test_parsing_with_a_newly_included_range() {
|
|||
);
|
||||
|
||||
assert_eq!(
|
||||
tree.changed_ranges(&first_tree),
|
||||
tree.changed_ranges(&first_tree).collect::<Vec<_>>(),
|
||||
vec![Range {
|
||||
start_byte: first_code_end_index + 1,
|
||||
end_byte: second_code_end_index + 1,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue