Skip to content

Commit 9995dcc

Browse files
committed
remove TextRange::after
1 parent 283cb68 commit 9995dcc

File tree

1 file changed

+1
-12
lines changed

1 file changed

+1
-12
lines changed

src/range.rs

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ use {
1111
/// # Translation from `text_unit`
1212
///
1313
/// - `TextRange::from_to(from, to)` ⟹ `TextRange(from, to)`
14-
/// - `TextRange::offset_len(offset, size)` ⟹ `TextRange::to(size).offset(offset)`
14+
/// - `TextRange::offset_len(offset, size)` ⟹ `TextRange::before(size).offset(offset)`
1515
/// - `range.start()` ⟹ `range.start()`
1616
/// - `range.end()` ⟹ `range.end()`
1717
/// - `range.len()` ⟹ `range.len()`
@@ -65,17 +65,6 @@ impl TextRange {
6565
}
6666
}
6767

68-
/// Create a range after the given start (`start..`).
69-
///
70-
/// This returns a std [`RangeFrom`] rather than `TextRange` because
71-
/// `TextRange` does not support right-unbounded ranges. As such, this
72-
/// should only be used for direct indexing, and bounded ranges should be
73-
/// used for persistent ranges (`TextRange(start, TextSize::of(text))`).
74-
#[inline]
75-
pub const fn after(start: TextSize) -> RangeFrom<usize> {
76-
start.raw as usize..
77-
}
78-
7968
/// Offset this range by some amount.
8069
///
8170
/// This is typically used to convert a range from one coordinate space to

0 commit comments

Comments
 (0)