error[E0606]: casting `&'static str` as `*const u8` is invalid --> $DIR/const-cast-different-types.rs:2:22 | LL | const b: *const u8 = a as *const u8; | ^^^^^^^^^^^^^^ error[E0606]: casting `&&'static str` as `*const u8` is invalid --> $DIR/const-cast-different-types.rs:3:22 | LL | const c: *const u8 = &a as *const u8; | ^^^^^^^^^^^^^^^ error: aborting due to 2 previous errors For more information about this error, try `rustc --explain E0606`.