diff options
| author | Simon Sapin <simon.sapin@exyr.org> | 2020-05-06 07:43:18 +0200 |
|---|---|---|
| committer | Simon Sapin <simon.sapin@exyr.org> | 2020-05-18 21:29:43 +0200 |
| commit | 49d5f5a977a1c0e0dffc8e189cef1977476f5253 (patch) | |
| tree | 77a1498ff5e66aba467389200b71c76a7976e129 /src/libcore/lib.rs | |
| parent | d4bf05693c2c16e299f1adc279b54c37a8edef27 (diff) | |
| download | rust-49d5f5a977a1c0e0dffc8e189cef1977476f5253.tar.gz rust-49d5f5a977a1c0e0dffc8e189cef1977476f5253.zip | |
Add `len` and `slice_from_raw_parts` to `NonNull<[T]>`
This follows the precedent of the recently-added `<*const [T]>::len` (adding to its tracking issue https://github.com/rust-lang/rust/issues/71146) and `ptr::slice_from_raw_parts`.
Diffstat (limited to 'src/libcore/lib.rs')
| -rw-r--r-- | src/libcore/lib.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/libcore/lib.rs b/src/libcore/lib.rs index 3b7929f0016..ca13433caec 100644 --- a/src/libcore/lib.rs +++ b/src/libcore/lib.rs @@ -87,6 +87,8 @@ #![feature(const_generics)] #![feature(const_ptr_offset_from)] #![feature(const_result)] +#![feature(const_slice_from_raw_parts)] +#![feature(const_slice_ptr_len)] #![feature(const_type_name)] #![feature(custom_inner_attributes)] #![feature(decl_macro)] |
