Skip to content

Commit 9c40db2

Browse files
authored
Rollup merge of rust-lang#95083 - danielhenrymantilla:patch-2, r=RalfJung
Document that `Option<extern "abi" fn>` discriminant elision applies for any ABI The current phrasing was not very clear on that aspect. r? `@RalfJung` `@rustbot` modify labels: A-docs A-ffi
2 parents c8cf9e3 + 156734d commit 9c40db2

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

library/core/src/option.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -80,11 +80,13 @@
8080
//! * [`Box<U>`]
8181
//! * `&U`
8282
//! * `&mut U`
83-
//! * `fn`, `extern "C" fn`
83+
//! * `fn`, `extern "C" fn`[^extern_fn]
8484
//! * [`num::NonZero*`]
8585
//! * [`ptr::NonNull<U>`]
8686
//! * `#[repr(transparent)]` struct around one of the types in this list.
8787
//!
88+
//! [^extern_fn]: this remains true for any other ABI: `extern "abi" fn` (_e.g._, `extern "system" fn`)
89+
//!
8890
//! [`Box<U>`]: ../../std/boxed/struct.Box.html
8991
//! [`num::NonZero*`]: crate::num
9092
//! [`ptr::NonNull<U>`]: crate::ptr::NonNull

0 commit comments

Comments
 (0)