Auto merge of #130867 - michirakara:steps_between, r=dtolnay
distinguish overflow and unimplemented in Step::steps_between
This commit is contained in:
@@ -638,7 +638,7 @@ impl AddAssign for Size {
|
||||
#[cfg(feature = "nightly")]
|
||||
impl Step for Size {
|
||||
#[inline]
|
||||
fn steps_between(start: &Self, end: &Self) -> Option<usize> {
|
||||
fn steps_between(start: &Self, end: &Self) -> (usize, Option<usize>) {
|
||||
u64::steps_between(&start.bytes(), &end.bytes())
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user