Auto merge of #13866 - Nilstrieb:rustc_safe_intrinsic, r=Veykril
Use `rustc_safe_intrinsic` attribute to check for intrinsic safety Instead of maintaining a list that is poorly kept in sync we can just use the attribute. This will make new RA versions unusable with old toolchains that don't have the attribute yet. Should we keep maintaining the list as a fallback or just don't care?
This commit is contained in:
@@ -86,6 +86,7 @@ fn main() {
|
||||
check_diagnostics(
|
||||
r#"
|
||||
extern "rust-intrinsic" {
|
||||
#[rustc_safe_intrinsic]
|
||||
pub fn bitreverse(x: u32) -> u32; // Safe intrinsic
|
||||
pub fn floorf32(x: f32) -> f32; // Unsafe intrinsic
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user