diff --git a/crates/text/src/text.rs b/crates/text/src/text.rs index 91767d99841b721d529de45229c1b067a563cf72..8ed80417ea38eadf5e7490ab225898084b2836b7 100644 --- a/crates/text/src/text.rs +++ b/crates/text/src/text.rs @@ -2402,12 +2402,12 @@ impl BufferSnapshot { } /// Returns an anchor range for the given input position range that is anchored to the text inbetween. - pub fn anchor_range_around(&self, position: Range) -> Range { + pub fn anchor_range_between(&self, position: Range) -> Range { self.anchor_before(position.start)..self.anchor_after(position.end) } /// Returns an anchor range for the given input position range that is anchored to the text before the start position and after the end position. - pub fn anchor_range_between(&self, position: Range) -> Range { + pub fn anchor_range_around(&self, position: Range) -> Range { self.anchor_before(position.start)..self.anchor_after(position.end) }