File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -122,7 +122,7 @@ impl<O: Offset> Offsets<O> {
122122 /// # Error
123123 /// This function errors iff the new last item is larger than what `O` supports.
124124 /// # Panic
125- /// This function asserts that `length > 0 `.
125+ /// This function asserts that `length >= O::zero() `.
126126 #[ inline]
127127 pub fn try_push ( & mut self , length : O ) -> Result < ( ) , Error > {
128128 let old_length = self . last ( ) ;
@@ -171,7 +171,7 @@ impl<O: Offset> Offsets<O> {
171171
172172 /// Returns a range (start, end) corresponding to the position `index`
173173 /// # Panic
174- /// This function panics iff `index >= self.len ()`
174+ /// This function panics iff `index >= self.len_proxy ()`
175175 #[ inline]
176176 pub fn start_end ( & self , index : usize ) -> ( usize , usize ) {
177177 // soundness: the invariant of the function
@@ -456,7 +456,7 @@ impl<O: Offset> OffsetsBuffer<O> {
456456
457457 /// Returns a range (start, end) corresponding to the position `index`
458458 /// # Panic
459- /// This function panics iff `index >= self.len ()`
459+ /// This function panics iff `index >= self.len_proxy ()`
460460 #[ inline]
461461 pub fn start_end ( & self , index : usize ) -> ( usize , usize ) {
462462 // soundness: the invariant of the function
You can’t perform that action at this time.
0 commit comments