mirror of
https://github.com/clap-rs/clap
synced 2024-11-10 06:44:16 +00:00
docs: Make more resilient across rust versions
This commit is contained in:
parent
08f8d6ca30
commit
cef5006e4f
1 changed files with 3 additions and 6 deletions
|
@ -2104,10 +2104,8 @@ pub mod via_prelude {
|
|||
/// assert_eq!(format!("{:?}", parser), "ValueParser::os_string");
|
||||
/// let parser = clap::value_parser!(std::path::PathBuf);
|
||||
/// assert_eq!(format!("{:?}", parser), "ValueParser::path_buf");
|
||||
/// let parser = clap::value_parser!(u16).range(3000..);
|
||||
/// assert_eq!(format!("{:?}", parser), "RangedI64ValueParser { bounds: (Included(3000), Included(65535)), target: PhantomData }");
|
||||
/// let parser = clap::value_parser!(u64).range(3000..);
|
||||
/// assert_eq!(format!("{:?}", parser), "RangedU64ValueParser { bounds: (Included(3000), Unbounded), target: PhantomData }");
|
||||
/// let _parser = clap::value_parser!(u16).range(3000..);
|
||||
/// let _parser = clap::value_parser!(u64).range(3000..);
|
||||
///
|
||||
/// // FromStr types
|
||||
/// let parser = clap::value_parser!(usize);
|
||||
|
@ -2133,8 +2131,7 @@ pub mod via_prelude {
|
|||
/// # }
|
||||
/// # }
|
||||
/// }
|
||||
/// let parser = clap::value_parser!(ColorChoice);
|
||||
/// assert_eq!(format!("{:?}", parser), "EnumValueParser(PhantomData)");
|
||||
/// let _parser = clap::value_parser!(ColorChoice);
|
||||
/// ```
|
||||
#[macro_export]
|
||||
macro_rules! value_parser {
|
||||
|
|
Loading…
Reference in a new issue