From 156734dda02737d6462e72163d7a62acd05a6802 Mon Sep 17 00:00:00 2001 From: Daniel Henry-Mantilla Date: Fri, 18 Mar 2022 18:14:34 +0100 Subject: [PATCH] Document that `Option` discriminant elision applies for any ABI The current phrasing was not very clear on that aspect. --- library/core/src/option.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/library/core/src/option.rs b/library/core/src/option.rs index de1628f83ad..bcba18a4a3e 100644 --- a/library/core/src/option.rs +++ b/library/core/src/option.rs @@ -80,11 +80,13 @@ //! * [`Box`] //! * `&U` //! * `&mut U` -//! * `fn`, `extern "C" fn` +//! * `fn`, `extern "C" fn`[^extern_fn] //! * [`num::NonZero*`] //! * [`ptr::NonNull`] //! * `#[repr(transparent)]` struct around one of the types in this list. //! +//! [^extern_fn]: this remains true for any other ABI: `extern "abi" fn` (_e.g._, `extern "system" fn`) +//! //! [`Box`]: ../../std/boxed/struct.Box.html //! [`num::NonZero*`]: crate::num //! [`ptr::NonNull`]: crate::ptr::NonNull