Skip to content

Commit 38bb88c

Browse files
committed
Disable assert_unsafe_precondition to measure compile-time cost
1 parent ff24ef9 commit 38bb88c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: library/core/src/ub_checks.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ macro_rules! assert_unsafe_precondition {
6969
}
7070
}
7171

72-
if ::core::ub_checks::$kind() {
72+
if cfg!(debug_assertions) {
7373
precondition_check($($arg,)*);
7474
}
7575
}

0 commit comments

Comments
 (0)