diff options
| author | Yuki Okushi <jtitor@2k36.org> | 2021-10-20 04:35:15 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-10-20 04:35:15 +0900 |
| commit | 9f2ad0a06185db6a3184780c665778bdcc33f0b2 (patch) | |
| tree | a1611422c2d304bec92bf7b832f0649f5b2f5123 /compiler/rustc_mir_transform/src/coverage/counters.rs | |
| parent | f7024998c7eae5b582de680effaca105198aa95c (diff) | |
| parent | 7936ecff4803e30ec0d3d85a531860025bb6b346 (diff) | |
| download | rust-9f2ad0a06185db6a3184780c665778bdcc33f0b2.tar.gz rust-9f2ad0a06185db6a3184780c665778bdcc33f0b2.zip | |
Rollup merge of #90009 - woppopo:const_from_more, r=dtolnay
Make more `From` impls `const` (libcore) Adding `const` to `From` implementations in the core. `rustc_const_unstable` attribute is not added to unstable implementations. Tracking issue: #88674 <details> <summary>Done</summary><div> - `T` from `T` - `T` from `!` - `Option<T>` from `T` - `Option<&T>` from `&Option<T>` - `Option<&mut T>` from `&mut Option<T>` - `Cell<T>` from `T` - `RefCell<T>` from `T` - `UnsafeCell<T>` from `T` - `OnceCell<T>` from `T` - `Poll<T>` from `T` - `u32` from `char` - `u64` from `char` - `u128` from `char` - `char` from `u8` - `AtomicBool` from `bool` - `AtomicPtr<T>` from `*mut T` - `AtomicI(bits)` from `i(bits)` - `AtomicU(bits)` from `u(bits)` - `i(bits)` from `NonZeroI(bits)` - `u(bits)` from `NonZeroU(bits)` - `NonNull<T>` from `Unique<T>` - `NonNull<T>` from `&T` - `NonNull<T>` from `&mut T` - `Unique<T>` from `&mut T` - `Infallible` from `!` - `TryIntError` from `!` - `TryIntError` from `Infallible` - `TryFromSliceError` from `Infallible` - `FromResidual for Option<T>` </div></details> <details> <summary>Remaining</summary><dev> - `NonZero` from `NonZero` These can't be made const at this time because these use Into::into. https://github.com/rust-lang/rust/blob/master/library/core/src/convert/num.rs#L393 - `std`, `alloc` There may still be many implementations that can be made `const`. </div></details>
Diffstat (limited to 'compiler/rustc_mir_transform/src/coverage/counters.rs')
0 files changed, 0 insertions, 0 deletions
