rust/library
Matthias Krüger c16ee19dd4
Rollup merge of #90162 - WaffleLapkin:const_array_slice_from_ref_mut, r=oli-obk
Mark `{array, slice}::{from_ref, from_mut}` as const fn

This PR marks the following APIs as `const`:
```rust
// core::array
pub const fn from_ref<T>(s: &T) -> &[T; 1];
pub const fn from_mut<T>(s: &mut T) -> &mut [T; 1];

// core::slice
pub const fn from_ref<T>(s: &T) -> &[T];
pub const fn from_mut<T>(s: &mut T) -> &mut [T];
```

Note that `from_ref` methods require `const_raw_ptr_deref` feature (which seems totally fine, since it's being stabilized, see #89551), `from_mut` methods require `const_mut_refs` (which seems fine too since this PR marks `from_mut` functions as const unstable).

r? ````@oli-obk````
2021-10-24 15:48:44 +02:00
..
alloc Clarify undefined behaviour for binary heap, btree and hashset 2021-10-21 09:30:46 -04:00
backtrace@7f14f76c8b bump backtrace 2021-10-17 21:20:18 -04:00
core Rollup merge of #90162 - WaffleLapkin:const_array_slice_from_ref_mut, r=oli-obk 2021-10-24 15:48:44 +02:00
panic_abort
panic_unwind
proc_macro Stabilize proc_macro::is_available 2021-10-10 14:09:54 +02:00
profiler_builtins
rtstartup
rustc-std-workspace-alloc
rustc-std-workspace-core
rustc-std-workspace-std
std Rollup merge of #89558 - lcnr:query-stable-lint, r=estebank 2021-10-24 15:48:42 +02:00
stdarch@5fdbc476af
test Rollup merge of #89082 - smoelius:master, r=kennytm 2021-10-07 20:26:12 -07:00
unwind Add new target armv7-unknown-linux-uclibceabihf 2021-10-06 14:33:13 +00:00