mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-22 14:55:26 +00:00
Auto merge of #117697 - WaffleLapkin:non-null-convenience-ops, r=Amanieu
Non null convenience ops Based on https://github.com/rust-lang/libs-team/issues/251. I went through all of the methods on `*mut` and added every method, which does not require additional safety conditions, to `NonNull`. (exceptions: `guaranteed_eq`, `guaranteed_ne`, `with_metadata_of`, it's unclear if they are useful here...) I'm also not sure what types should the "second pointer parameter" be. `*mut`/`*const` might be more permissible, but given that `NonNull` doesn't coerce to them, it might also be annoying. For now I chose the "use `NonNull` everywhere" path, but I'm not sure it's the correct one... <sub>I'm eepy, so I probably messed up somewhere while copying...</sub> cc `@scottmcm` r? libs-api
This commit is contained in:
commit
1bcbb7c93b
@ -178,6 +178,7 @@
|
||||
#![feature(is_ascii_octdigit)]
|
||||
#![feature(isqrt)]
|
||||
#![feature(maybe_uninit_uninit_array)]
|
||||
#![feature(non_null_convenience)]
|
||||
#![feature(offset_of)]
|
||||
#![feature(offset_of_enum)]
|
||||
#![feature(ptr_alignment_type)]
|
||||
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user