mirror of
https://github.com/clap-rs/clap
synced 2024-12-14 06:42:33 +00:00
19 lines
286 B
Rust
19 lines
286 B
Rust
|
#![feature(test)]
|
||
|
|
||
|
extern crate clap;
|
||
|
extern crate test;
|
||
|
|
||
|
use clap::App;
|
||
|
|
||
|
use test::Bencher;
|
||
|
|
||
|
#[bench]
|
||
|
fn build_app(b: &mut Bencher) {
|
||
|
b.iter(|| App::new("claptests"));
|
||
|
}
|
||
|
|
||
|
#[bench]
|
||
|
fn parse_clean(b: &mut Bencher) {
|
||
|
b.iter(|| App::new("claptests").get_matches_from(vec![""]));
|
||
|
}
|