File tree 1 file changed +0
-2
lines changed
1 file changed +0
-2
lines changed Original file line number Diff line number Diff line change @@ -1425,7 +1425,6 @@ pub const unsafe fn read<T>(src: *const T) -> T {
1425
1425
1426
1426
// SAFETY: the caller must guarantee that `src` is valid for reads.
1427
1427
unsafe {
1428
- #[ cfg( debug_assertions) ] // Too expensive to always enable (for now?)
1429
1428
ub_checks:: assert_unsafe_precondition!(
1430
1429
check_language_ub,
1431
1430
"ptr::read requires that the pointer argument is aligned and non-null" ,
@@ -1634,7 +1633,6 @@ pub const unsafe fn write<T>(dst: *mut T, src: T) {
1634
1633
// `dst` cannot overlap `src` because the caller has mutable access
1635
1634
// to `dst` while `src` is owned by this function.
1636
1635
unsafe {
1637
- #[ cfg( debug_assertions) ] // Too expensive to always enable (for now?)
1638
1636
ub_checks:: assert_unsafe_precondition!(
1639
1637
check_language_ub,
1640
1638
"ptr::write requires that the pointer argument is aligned and non-null" ,
You can’t perform that action at this time.
0 commit comments