about summary refs log tree commit diff
diff options
context:
space:
mode:
authorRalf Jung <post@ralfj.de>2024-09-21 09:17:31 +0200
committerRalf Jung <post@ralfj.de>2024-09-21 09:17:31 +0200
commitb94f2931b30402f8a7284832dd4b4b7d251e82a4 (patch)
tree70726e9db61987a6854f312dd9c6d914a07bafeb
parentc0838c8ebec23fb87855bb6de3a287981cb1df98 (diff)
downloadrust-b94f2931b30402f8a7284832dd4b4b7d251e82a4.tar.gz
rust-b94f2931b30402f8a7284832dd4b4b7d251e82a4.zip
ABI compatibility: mention Result guarantee
-rw-r--r--library/core/src/primitive_docs.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/library/core/src/primitive_docs.rs b/library/core/src/primitive_docs.rs
index 5451e45f6c8..962da6643dd 100644
--- a/library/core/src/primitive_docs.rs
+++ b/library/core/src/primitive_docs.rs
@@ -1761,6 +1761,8 @@ mod prim_ref {}
 /// - `i32` is ABI-compatible with `NonZero<i32>`, and similar for all other integer types.
 /// - If `T` is guaranteed to be subject to the [null pointer
 ///   optimization](option/index.html#representation), then `T` and `Option<T>` are ABI-compatible.
+///   Furthermore, if `U` satisfies the requirements [outlined here](result/index.html#representation),
+///   then `T` and `Result<T, U>` and `Result<U, T>` are all ABI-compatible.
 ///
 /// Furthermore, ABI compatibility satisfies the following general properties:
 ///