pub struct ValueOptions {
pub negative_numbers: bool,
pub hyphen_values: bool,
pub require_equals: bool,
pub keep_equals: bool,
}Expand description
How a flag takes a detached value, beyond the default of any word that is not flag-like.
More options may be added: build one from ValueOptions::DEFAULT
(ValueOptions { hyphen_values: true, ..ValueOptions::DEFAULT }).
Fields§
§negative_numbers: boolA negative number is a value, not a flag: --offset -1.
hyphen_values: boolAny next word is the value, -- and flag-like ones included: --args -x.
require_equals: boolOnly an attached value: --inspect=9229, -i9229; the next word is never taken.
keep_equals: boolA short option’s attached value keeps a leading =: -L=dir is
=dir, as GNU ld reads it (a sysroot-relative path), not dir.
Implementations§
Source§impl ValueOptions
impl ValueOptions
Trait Implementations§
Source§impl Clone for ValueOptions
impl Clone for ValueOptions
impl Copy for ValueOptions
Source§impl Debug for ValueOptions
impl Debug for ValueOptions
Source§impl Default for ValueOptions
impl Default for ValueOptions
impl Eq for ValueOptions
Source§impl Hash for ValueOptions
impl Hash for ValueOptions
Source§impl PartialEq for ValueOptions
impl PartialEq for ValueOptions
impl StructuralPartialEq for ValueOptions
Auto Trait Implementations§
impl Freeze for ValueOptions
impl RefUnwindSafe for ValueOptions
impl Send for ValueOptions
impl Sync for ValueOptions
impl Unpin for ValueOptions
impl UnsafeUnpin for ValueOptions
impl UnwindSafe for ValueOptions
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more