From 39fe29bf0ca4d105a6118b4a1ca5ce17a59b71b1 Mon Sep 17 00:00:00 2001 From: Josh Triplett Date: Thu, 29 Mar 2018 09:43:26 +0200 Subject: [PATCH] src/libcore/ptr.rs: Fix documentation for size of `Option>` Seems more useful to say that it has the same size as `*mut T`. --- src/libcore/ptr.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libcore/ptr.rs b/src/libcore/ptr.rs index aebd50d9c6b3c..5a54de06b5ef2 100644 --- a/src/libcore/ptr.rs +++ b/src/libcore/ptr.rs @@ -2653,7 +2653,7 @@ impl<'a, T: ?Sized> From> for Unique { /// /// Unlike `*mut T`, the pointer must always be non-null, even if the pointer /// is never dereferenced. This is so that enums may use this forbidden value -/// as a discriminant -- `Option>` has the same size as `NonNull`. +/// as a discriminant -- `Option>` has the same size as `*mut T`. /// However the pointer may still dangle if it isn't dereferenced. /// /// Unlike `*mut T`, `NonNull` is covariant over `T`. If this is incorrect