We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 62d8ea0 commit 6dd581bCopy full SHA for 6dd581b
library/core/src/intrinsics.rs
@@ -2617,8 +2617,9 @@ macro_rules! assert_unsafe_precondition {
2617
#[cfg(bootstrap)]
2618
let should_check = cfg!(debug_assertions);
2619
2620
+ // Turn assertions off in Miri, but otherwise check in codegen
2621
#[cfg(not(bootstrap))]
- let should_check = ::core::intrinsics::debug_assertions();
2622
+ let should_check = !cfg!(miri) && ::core::intrinsics::debug_assertions();
2623
2624
if should_check {
2625
// allow non_snake_case to allow capturing const generics
0 commit comments