diff options
author | Aleksey Kladov <[email protected]> | 2019-09-25 15:19:16 +0100 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2019-09-25 15:19:16 +0100 |
commit | b7422bd1abd03c02b4aa4a6a5d3dcc1136d37a42 (patch) | |
tree | c1f25fa59902c3ceab9e6c54a9faba655fa24baa /crates/ra_syntax | |
parent | d9b4835625ac96c7628e2ef66ef6e26cc48d231f (diff) |
fewer monomorphisations
Diffstat (limited to 'crates/ra_syntax')
-rw-r--r-- | crates/ra_syntax/src/algo.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/ra_syntax/src/algo.rs b/crates/ra_syntax/src/algo.rs index 45f624810..7ee5aa85b 100644 --- a/crates/ra_syntax/src/algo.rs +++ b/crates/ra_syntax/src/algo.rs | |||
@@ -70,7 +70,7 @@ pub enum InsertPosition<T> { | |||
70 | pub fn insert_children( | 70 | pub fn insert_children( |
71 | parent: &SyntaxNode, | 71 | parent: &SyntaxNode, |
72 | position: InsertPosition<SyntaxElement>, | 72 | position: InsertPosition<SyntaxElement>, |
73 | to_insert: impl Iterator<Item = SyntaxElement>, | 73 | to_insert: &mut dyn Iterator<Item = SyntaxElement>, |
74 | ) -> SyntaxNode { | 74 | ) -> SyntaxNode { |
75 | let mut delta = TextUnit::default(); | 75 | let mut delta = TextUnit::default(); |
76 | let to_insert = to_insert.map(|element| { | 76 | let to_insert = to_insert.map(|element| { |
@@ -108,7 +108,7 @@ pub fn insert_children( | |||
108 | pub fn replace_children( | 108 | pub fn replace_children( |
109 | parent: &SyntaxNode, | 109 | parent: &SyntaxNode, |
110 | to_delete: RangeInclusive<SyntaxElement>, | 110 | to_delete: RangeInclusive<SyntaxElement>, |
111 | to_insert: impl Iterator<Item = SyntaxElement>, | 111 | to_insert: &mut dyn Iterator<Item = SyntaxElement>, |
112 | ) -> SyntaxNode { | 112 | ) -> SyntaxNode { |
113 | let start = position_of_child(parent, to_delete.start().clone()); | 113 | let start = position_of_child(parent, to_delete.start().clone()); |
114 | let end = position_of_child(parent, to_delete.end().clone()); | 114 | let end = position_of_child(parent, to_delete.end().clone()); |