Skip to content

Commit b20aff2

Browse files
authored
Rollup merge of #97269 - RalfJung:transmute, r=m-ou-se
adjust transmute const stabilization version With 1.46, this became callable only in `const`/`static` items. Only since 1.56 is this callable in `const fn`: [changelog](https://github.com/rust-lang/rust/blob/master/RELEASES.md#version-1560-2021-10-21) Also see [Zulip discussion](https://rust-lang.zulipchat.com/#narrow/stream/122651-general/topic/transmute.20const.20fn.20stabilization).
2 parents 84c17c2 + 4505579 commit b20aff2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/core/src/intrinsics.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1144,7 +1144,7 @@ extern "rust-intrinsic" {
11441144
/// }
11451145
/// ```
11461146
#[stable(feature = "rust1", since = "1.0.0")]
1147-
#[rustc_const_stable(feature = "const_transmute", since = "1.46.0")]
1147+
#[rustc_const_stable(feature = "const_transmute", since = "1.56.0")]
11481148
#[rustc_diagnostic_item = "transmute"]
11491149
pub fn transmute<T, U>(e: T) -> U;
11501150

0 commit comments

Comments
 (0)