Rust 1.81 stabilized std::hint::assert_unchecked, which is what we want our assume to be. Our assume is a slightly different implementation (that just calls unreachable_unchecked in the false case), and assert_unchecked is implemented more directly with regards to LLVM IR generation. They are largely the same, but assert_unchecked may be optimized slightly better, and Rust is standardizing around this new interface, so we should switch to it.
Rust 1.81 stabilized
std::hint::assert_unchecked
, which is what we want ourassume
to be. Ourassume
is a slightly different implementation (that just callsunreachable_unchecked
in thefalse
case), andassert_unchecked
is implemented more directly with regards to LLVM IR generation. They are largely the same, butassert_unchecked
may be optimized slightly better, and Rust is standardizing around this new interface, so we should switch to it.