From 0c367104ae382f8e3d91c5dba99728c7f96c4301 Mon Sep 17 00:00:00 2001 From: Ed Page Date: Mon, 13 Jun 2022 18:54:43 -0500 Subject: [PATCH] docs(derive): Update deprecation notice --- examples/derive_ref/README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/examples/derive_ref/README.md b/examples/derive_ref/README.md index dd973ed3992..4643d8534a3 100644 --- a/examples/derive_ref/README.md +++ b/examples/derive_ref/README.md @@ -208,7 +208,10 @@ These correspond to a `clap::Arg`. - When `Option`, the subcommand becomes optional - `from_global`: Read a `clap::Arg::global` argument (raw attribute), regardless of what subcommand you are in - `parse( [= ])`: `clap::Arg::validator` and `clap::ArgMatches::values_of_t` - - **Deprecated:** except for `from_flag` or `from_occurrences`, instead use `value_parser` + - **Deprecated:** + - Use `value_parser(...)` for `from_str`, `try_from_str`, `from_os_str`, and `try_from_os_str` + - Use `action(ArgAction::Count` for `from_occurrences` + - Use `action(ArgAction::SetTrue` for `from_flag` - Default: `try_from_str` - Warning: for `Path` / `OsString`, be sure to use `try_from_os_str` - See [Arg Types](#arg-types) for more details