/// Check for unimplemented command line arguments.
///
/// Either return the degenerate Ok value, or an Err with string.
///
/// # Errors
///
/// Error datum is a string of the unimplemented argument.
///
///
Check for unimplemented command line arguments.
Either return the degenerate Ok value, or an Err with string.
Check for unimplemented command line arguments . Either return the degenerate Ok value or an Err with string .
fn check_unimplemented<'a>(matches: &ArgMatches) -> Result<(), &'a str> {
    if matches.is_present(OPT_BACKUP) {
        Err("--backup")
    } else if matches.is_present(OPT_BACKUP_2) {
        Err("-b")
    } else if matches.is_present(OPT_COMPARE) {
        Err("--compare, -C")
    } else if matches.is_present(OPT_CREATED) {
        Err("-D")
    } else if matches.is_present(OPT_GROUP) {
        Err("--group, -g")
    } else if matches.is_present(OPT_OWNER) {
        Err("--owner, -o")
    } else if matches.is_present(OPT_PRESERVE_TIMESTAMPS) {
        Err("--preserve-timestamps, -p")
    } else if matches.is_present(OPT_STRIP) {
        Err("--strip, -s")
    } else if matches.is_present(OPT_STRIP_PROGRAM) {
        Err("--strip-program")
    } else if matches.is_present(OPT_SUFFIX) {
        Err("--suffix, -S")
    } else if matches.is_present(OPT_TARGET_DIRECTORY) {
        Err("--target-directory, -t")
    } else if matches.is_present(OPT_NO_TARGET_DIRECTORY) {
        Err("--no-target-directory, -T")
    } else if matches.is_present(OPT_PRESERVE_CONTEXT) {
        Err("--preserve-context, -P")
    } else if matches.is_present(OPT_CONTEXT) {
        Err("--context, -Z")
    } else {
        Ok(())
    }
}
fn check_unimplemented < ' a > ( matches : & ArgMatches ) -> Result < ( ) , & ' a str > { if matches . is_present ( OPT_BACKUP ) { Err ( " " ) } else if matches . is_present ( OPT_BACKUP_2 ) { Err ( " " ) } else if matches . is_present ( OPT_COMPARE ) { Err ( " " ) } else if matches . is_present ( OPT_CREATED ) { Err ( " " ) } else if matches . is_present ( OPT_GROUP ) { Err ( " " ) } else if matches . is_present ( OPT_OWNER ) { Err ( " " ) } else if matches . is_present ( OPT_PRESERVE_TIMESTAMPS ) { Err ( " " ) } else if matches . is_present ( OPT_STRIP ) { Err ( " " ) } else if matches . is_present ( OPT_STRIP_PROGRAM ) { Err ( " " ) } else if matches . is_present ( OPT_SUFFIX ) { Err ( " " ) } else if matches . is_present ( OPT_TARGET_DIRECTORY ) { Err ( " " ) } else if matches . is_present ( OPT_NO_TARGET_DIRECTORY ) { Err ( " " ) } else if matches . is_present ( OPT_PRESERVE_CONTEXT ) { Err ( " " ) } else if matches . is_present ( OPT_CONTEXT ) { Err ( " " ) } else { Ok ( ( ) ) } }
Check for unimplemented command line arguments.
Check for unimplemented command line arguments .
matches
&ArgMatches
errors
Error datum is a string of the unimplemented argument.
Error datum is a string of the unimplemented argument .