File tree Expand file tree Collapse file tree 6 files changed +9
-0
lines changed Expand file tree Collapse file tree 6 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -512,6 +512,7 @@ impl<T, const N: usize> [T; N] {
512
512
513
513
/// Returns a slice containing the entire array. Equivalent to `&s[..]`.
514
514
#[ stable( feature = "array_as_slice" , since = "1.57.0" ) ]
515
+ #[ rustc_const_stable( feature = "array_as_slice" , since = "1.57.0" ) ]
515
516
pub const fn as_slice ( & self ) -> & [ T ] {
516
517
self
517
518
}
Original file line number Diff line number Diff line change @@ -1959,6 +1959,7 @@ impl<T: ?Sized> UnsafeCell<T> {
1959
1959
/// ```
1960
1960
#[ inline( always) ]
1961
1961
#[ stable( feature = "unsafe_cell_raw_get" , since = "1.56.0" ) ]
1962
+ #[ rustc_const_stable( feature = "unsafe_cell_raw_get" , since = "1.56.0" ) ]
1962
1963
pub const fn raw_get ( this : * const Self ) -> * mut T {
1963
1964
// We can just cast the pointer from `UnsafeCell<T>` to `T` because of
1964
1965
// #[repr(transparent)]. This exploits libstd's special status, there is
Original file line number Diff line number Diff line change @@ -1064,6 +1064,7 @@ macro_rules! int_impl {
1064
1064
///
1065
1065
/// ```
1066
1066
#[ stable( feature = "saturating_div" , since = "1.58.0" ) ]
1067
+ #[ rustc_const_stable( feature = "saturating_div" , since = "1.58.0" ) ]
1067
1068
#[ must_use = "this returns the result of the operation, \
1068
1069
without modifying the original"]
1069
1070
#[ inline]
Original file line number Diff line number Diff line change @@ -972,6 +972,7 @@ macro_rules! nonzero_unsigned_is_power_of_two {
972
972
/// ```
973
973
#[ must_use]
974
974
#[ stable( feature = "nonzero_is_power_of_two" , since = "1.59.0" ) ]
975
+ #[ rustc_const_stable( feature = "nonzero_is_power_of_two" , since = "1.59.0" ) ]
975
976
#[ inline]
976
977
pub const fn is_power_of_two( self ) -> bool {
977
978
// LLVM 11 normalizes `unchecked_sub(x, 1) & x == 0` to the implementation seen here.
Original file line number Diff line number Diff line change @@ -1132,6 +1132,7 @@ macro_rules! uint_impl {
1132
1132
///
1133
1133
/// ```
1134
1134
#[ stable( feature = "saturating_div" , since = "1.58.0" ) ]
1135
+ #[ rustc_const_stable( feature = "saturating_div" , since = "1.58.0" ) ]
1135
1136
#[ must_use = "this returns the result of the operation, \
1136
1137
without modifying the original"]
1137
1138
#[ inline]
Original file line number Diff line number Diff line change @@ -136,6 +136,10 @@ impl<'a> PanicInfo<'a> {
136
136
/// This is true for most kinds of panics with the exception of panics
137
137
/// caused by trying to unwind out of a `Drop` implementation or a function
138
138
/// whose ABI does not support unwinding.
139
+ ///
140
+ /// It is safe for a panic handler to unwind even when this function returns
141
+ /// true, however this will simply cause the panic handler to be called
142
+ /// again.
139
143
#[ must_use]
140
144
#[ unstable( feature = "panic_can_unwind" , issue = "92988" ) ]
141
145
pub fn can_unwind ( & self ) -> bool {
You can’t perform that action at this time.
0 commit comments