mirror of
https://github.com/clap-rs/clap
synced 2025-03-05 07:47:40 +00:00
Add assert to make doc test fails.
This commit is contained in:
parent
50fb4ca63d
commit
acdb94c1a5
1 changed files with 1 additions and 0 deletions
|
@ -710,6 +710,7 @@ impl ArgMatches {
|
||||||
/// // clap sees the above as 'myapp -o val1 val2 val3'
|
/// // clap sees the above as 'myapp -o val1 val2 val3'
|
||||||
/// // ^0 ^1 ^2 ^3 ^4
|
/// // ^0 ^1 ^2 ^3 ^4
|
||||||
/// assert_eq!(m.index_of("option"), Some(2));
|
/// assert_eq!(m.index_of("option"), Some(2));
|
||||||
|
/// assert_eq!(m.indices_of("option").unwrap().collect::<Vec<_>>(), &[2, 3, 4]);
|
||||||
/// ```
|
/// ```
|
||||||
/// [`ArgMatches`]: ./struct.ArgMatches.html
|
/// [`ArgMatches`]: ./struct.ArgMatches.html
|
||||||
/// [delimiter]: ./struct.Arg.html#method.value_delimiter
|
/// [delimiter]: ./struct.Arg.html#method.value_delimiter
|
||||||
|
|
Loading…
Add table
Reference in a new issue