Skip to content

Commit 90b0f84

Browse files
authored
Rollup merge of rust-lang#76910 - lcnr:foreign-item-like, r=oli-obk
transmute: use diagnostic item closes rust-lang#66075, we now have no remaining uses of `match_def_path` in the compiler while some uses still remain in `clippy`. cc @RalfJung
2 parents fc556db + 39392f2 commit 90b0f84

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

core/src/intrinsics.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1071,6 +1071,7 @@ extern "rust-intrinsic" {
10711071
// NOTE: While this makes the intrinsic const stable, we have some custom code in const fn
10721072
// checks that prevent its use within `const fn`.
10731073
#[rustc_const_stable(feature = "const_transmute", since = "1.46.0")]
1074+
#[cfg_attr(not(bootstrap), rustc_diagnostic_item = "transmute")]
10741075
pub fn transmute<T, U>(e: T) -> U;
10751076

10761077
/// Returns `true` if the actual type given as `T` requires drop

0 commit comments

Comments
 (0)