File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -974,9 +974,10 @@ pub const fn dangling_mut<T>() -> *mut T {
974
974
#[ must_use]
975
975
#[ inline( always) ]
976
976
#[ stable( feature = "exposed_provenance" , since = "1.84.0" ) ]
977
+ #[ rustc_const_unstable( feature = "const_exposed_provenance" , issue = "144538" ) ]
977
978
#[ cfg_attr( miri, track_caller) ] // even without panics, this helps for Miri backtraces
978
979
#[ allow( fuzzy_provenance_casts) ] // this *is* the explicit provenance API one should use instead
979
- pub fn with_exposed_provenance < T > ( addr : usize ) -> * const T {
980
+ pub const fn with_exposed_provenance < T > ( addr : usize ) -> * const T {
980
981
addr as * const T
981
982
}
982
983
@@ -1014,9 +1015,10 @@ pub fn with_exposed_provenance<T>(addr: usize) -> *const T {
1014
1015
#[ must_use]
1015
1016
#[ inline( always) ]
1016
1017
#[ stable( feature = "exposed_provenance" , since = "1.84.0" ) ]
1018
+ #[ rustc_const_unstable( feature = "const_exposed_provenance" , issue = "144538" ) ]
1017
1019
#[ cfg_attr( miri, track_caller) ] // even without panics, this helps for Miri backtraces
1018
1020
#[ allow( fuzzy_provenance_casts) ] // this *is* the explicit provenance API one should use instead
1019
- pub fn with_exposed_provenance_mut < T > ( addr : usize ) -> * mut T {
1021
+ pub const fn with_exposed_provenance_mut < T > ( addr : usize ) -> * mut T {
1020
1022
addr as * mut T
1021
1023
}
1022
1024
You can’t perform that action at this time.
0 commit comments