aboutsummaryrefslogtreecommitdiff
path: root/clap/src/args/matched_arg.rs
diff options
context:
space:
mode:
Diffstat (limited to 'clap/src/args/matched_arg.rs')
-rw-r--r--clap/src/args/matched_arg.rs24
1 files changed, 24 insertions, 0 deletions
diff --git a/clap/src/args/matched_arg.rs b/clap/src/args/matched_arg.rs
new file mode 100644
index 0000000..eeda261
--- /dev/null
+++ b/clap/src/args/matched_arg.rs
@@ -0,0 +1,24 @@
+// Std
+use std::ffi::OsString;
+
+#[doc(hidden)]
+#[derive(Debug, Clone)]
+pub struct MatchedArg {
+ #[doc(hidden)] pub occurs: u64,
+ #[doc(hidden)] pub indices: Vec<usize>,
+ #[doc(hidden)] pub vals: Vec<OsString>,
+}
+
+impl Default for MatchedArg {
+ fn default() -> Self {
+ MatchedArg {
+ occurs: 1,
+ indices: Vec::new(),
+ vals: Vec::new(),
+ }
+ }
+}
+
+impl MatchedArg {
+ pub fn new() -> Self { MatchedArg::default() }
+}