Apply clippy::let_and_return suggestion
This commit is contained in:
parent
7f4aba40fc
commit
edabcddf4d
1 changed files with 1 additions and 2 deletions
|
@ -3026,8 +3026,7 @@ macro_rules! len {
|
||||||
if size == 0 {
|
if size == 0 {
|
||||||
// This _cannot_ use `unchecked_sub` because we depend on wrapping
|
// This _cannot_ use `unchecked_sub` because we depend on wrapping
|
||||||
// to represent the length of long ZST slice iterators.
|
// to represent the length of long ZST slice iterators.
|
||||||
let diff = ($self.end as usize).wrapping_sub(start as usize);
|
($self.end as usize).wrapping_sub(start as usize)
|
||||||
diff
|
|
||||||
} else {
|
} else {
|
||||||
// We know that `start <= end`, so can do better than `offset_from`,
|
// We know that `start <= end`, so can do better than `offset_from`,
|
||||||
// which needs to deal in signed. By setting appropriate flags here
|
// which needs to deal in signed. By setting appropriate flags here
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue