mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-28 01:34:21 +00:00
Rollup merge of #61273 - RalfJung:maybe-uninit, r=Centril
mention that MaybeUninit is a bit like Option
This commit is contained in:
commit
9121a73ab1
@ -966,6 +966,9 @@ impl<T: ?Sized> DerefMut for ManuallyDrop<T> {
|
||||
///
|
||||
/// The compiler then knows to not make any incorrect assumptions or optimizations on this code.
|
||||
///
|
||||
/// You can think of `MaybeUninit<T>` as being a bit like `Option<T>` but without
|
||||
/// any of the run-time tracking and without any of the safety checks.
|
||||
///
|
||||
/// ## out-pointers
|
||||
///
|
||||
/// You can use `MaybeUninit<T>` to implement "out-pointers": instead of returning data
|
||||
|
Loading…
Reference in New Issue
Block a user