Simplify conditions like x + 1 <= y to x < y
This commit is contained in:
parent
e364c283fd
commit
5abaeb3d67
@ -1191,7 +1191,7 @@ impl<'a, K, V> Handle<NodeRef<marker::Mut<'a>, K, V, marker::Internal>, marker::
|
||||
let right_len = right_node.len();
|
||||
|
||||
// necessary for correctness, but in a private module
|
||||
assert!(left_len + right_len + 1 <= CAPACITY);
|
||||
assert!(left_len + right_len < CAPACITY);
|
||||
|
||||
unsafe {
|
||||
ptr::write(
|
||||
|
@ -189,7 +189,7 @@ impl<'tcx> Body<'tcx> {
|
||||
) -> Self {
|
||||
// We need `arg_count` locals, and one for the return place.
|
||||
assert!(
|
||||
local_decls.len() >= arg_count + 1,
|
||||
local_decls.len() > arg_count,
|
||||
"expected at least {} locals, got {}",
|
||||
arg_count + 1,
|
||||
local_decls.len()
|
||||
|
Loading…
Reference in New Issue
Block a user