Apply suggestions from code review

(removing confusing comment from my test, since the comment reflects the bad undesirable behavior that is being fixed here.)
This commit is contained in:
Felix S Klock II 2021-05-21 15:10:56 -04:00 committed by GitHub
parent 4742bbb48b
commit 0d073c9174
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -15,9 +15,6 @@ fn main() {
let u8_ptr: *const u8 = &val;
let _closure = || {
unsafe {
// Fails compilation with:
// error[E0133]: dereference of raw pointer is unsafe and
// requires unsafe function or block
let tmp = *u8_ptr;
tmp