From 863791a66d1b2d3033e111930684214f41ed0220 Mon Sep 17 00:00:00 2001 From: David Tolnay Date: Tue, 3 Dec 2024 11:00:19 -0800 Subject: [PATCH] Align naming between Ok function argument and its documentation The documentation refers to `Ok::<_, anyhow::Error>(value)`. ^^^^^ --- src/lib.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index 7124eb0..7da01dd 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -646,8 +646,8 @@ pub trait Context: context::private::Sealed { /// | consider giving this pattern the explicit type `std::result::Result`, where the type parameter `E` is specified /// ``` #[allow(non_snake_case)] -pub fn Ok(t: T) -> Result { - Result::Ok(t) +pub fn Ok(value: T) -> Result { + Result::Ok(value) } // Not public API. Referenced by macro-generated code.