From cfe9a3a4419630de87023a8456becf29ddcff602 Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Mon, 31 Aug 2026 17:08:52 -0500 Subject: [PATCH] Tweak Infallible docs Link to the never type and restore the note about possibly deprecating in the future. --- library/core/src/convert/mod.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/library/core/src/convert/mod.rs b/library/core/src/convert/mod.rs index 7e675815edb2e..e0e58474fd4d2 100644 --- a/library/core/src/convert/mod.rs +++ b/library/core/src/convert/mod.rs @@ -886,7 +886,8 @@ const impl AsMut for str { /// } /// ``` /// -/// Note: since CURRENT_RUSTC_VERSION this is an alias to `!`. If targeting that or future versions, -/// prefer using the never type directly. +/// Note: Since [`!`] (the "never" type) was stabilized in Rust CURRENT_RUSTC_VERSION, it is +/// preferred to use `!` directly unless targeting older Rust versions. `Infallible` may be +/// deprecated in a future Rust version. #[stable(feature = "convert_infallible", since = "1.34.0")] pub type Infallible = !;