File tree Expand file tree Collapse file tree 3 files changed +10
-2
lines changed Expand file tree Collapse file tree 3 files changed +10
-2
lines changed Original file line number Diff line number Diff line change 1+ #![ unstable( feature = "std_internals" , issue = "none" ) ]
2+ #![ doc( hidden) ]
13use crate :: iter:: { FusedIterator , TrustedLen } ;
24use crate :: num:: NonZero ;
35use crate :: ub_checks;
@@ -9,7 +11,7 @@ use crate::ub_checks;
911/// (Normal `Range` code needs to handle degenerate ranges like `10..0`,
1012/// which takes extra checks compared to only handling the canonical form.)
1113#[ derive( Clone , Debug , PartialEq , Eq ) ]
12- pub ( crate ) struct IndexRange {
14+ pub struct IndexRange {
1315 start : usize ,
1416 end : usize ,
1517}
Original file line number Diff line number Diff line change @@ -181,7 +181,9 @@ pub(crate) use self::drop::fallback_surface_drop;
181181pub use self :: function:: { Fn , FnMut , FnOnce } ;
182182#[ stable( feature = "rust1" , since = "1.0.0" ) ]
183183pub use self :: index:: { Index , IndexMut } ;
184- pub ( crate ) use self :: index_range:: IndexRange ;
184+ #[ doc( hidden) ]
185+ #[ unstable( feature = "std_internals" , issue = "none" ) ]
186+ pub use self :: index_range:: IndexRange ;
185187#[ unstable( feature = "one_sided_range" , issue = "69780" ) ]
186188pub use self :: range:: OneSidedRange ;
187189#[ stable( feature = "inclusive_range" , since = "1.26.0" ) ]
Original file line number Diff line number Diff line change @@ -149,6 +149,8 @@ mod private_slice_index {
149149 #[ unstable( feature = "new_range_api" , issue = "125687" ) ]
150150 impl Sealed for range:: RangeFrom < usize > { }
151151
152+ #[ doc( hidden) ]
153+ #[ unstable( feature = "std_internals" , issue = "none" ) ]
152154 impl Sealed for ops:: IndexRange { }
153155}
154156
@@ -283,6 +285,8 @@ unsafe impl<T> SliceIndex<[T]> for usize {
283285
284286/// Because `IndexRange` guarantees `start <= end`, fewer checks are needed here
285287/// than there are for a general `Range<usize>` (which might be `100..3`).
288+ #[ doc( hidden) ]
289+ #[ unstable( feature = "std_internals" , issue = "none" ) ]
286290unsafe impl < T > SliceIndex < [ T ] > for ops:: IndexRange {
287291 type Output = [ T ] ;
288292
You can’t perform that action at this time.
0 commit comments