Skip to content

Commit fdbbf66

Browse files
authored
Merge pull request #5938 from ilyagr/error-insert-docs
document `clap::Error::insert` a bit better
2 parents 94c774b + b86dc51 commit fdbbf66

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

clap_builder/src/error/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,8 @@ impl<F: ErrorFormatter> Error<F> {
195195
}
196196

197197
/// Insert a piece of context
198+
///
199+
/// If this `ContextKind` is already present, its value is replaced and the old value is returned.
198200
#[inline(never)]
199201
#[cfg(feature = "error-context")]
200202
pub fn insert(&mut self, kind: ContextKind, value: ContextValue) -> Option<ContextValue> {

0 commit comments

Comments
 (0)