File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -161,16 +161,15 @@ fn black_box(input: u8) -> u8 {
161
161
//
162
162
// Note: Rust's notion of "volatile" is subject to change over time. While this code may break
163
163
// in a non-destructive way in the future, it is better than doing nothing.
164
- //
165
- debug_assert ! ( !core:: mem:: needs_drop:: <u8 >( ) ) ;
164
+
166
165
unsafe {
167
166
// Optimization barrier
168
167
//
169
168
// Unsafe is ok, because:
170
169
// - &input is not NULL;
171
170
// - size of input is not zero;
172
171
// - u8 is neither Sync, nor Send;
173
- // - u8 is Copy (also asserted just before) , so input is always live;
172
+ // - u8 is Copy, so input is always live;
174
173
// - u8 type is always properly aligned.
175
174
core:: ptr:: read_volatile ( & input as * const u8 )
176
175
}
You can’t perform that action at this time.
0 commit comments