You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: error.rs
    path of file: ./repos/exa/src/options
    
    the code of the file until where you have to start completion: use std::ffi::OsString;
use std::fmt;
use std::num::ParseIntError;

use crate::options::flags;
use crate::options::parser::{Arg, Flag, ParseError};


/// Something wrong with the combination of options the user has picked.
#[derive(PartialEq, Eq, Debug)]
pub enum OptionsError {

    /// There was an error (from `getopts`) parsing the arguments.
    Parse(ParseError),

    /// The user supplied an illegal choice to an Argument.
    BadArgument(&'static Arg, OsString),

    /// The user supplied a set of options that are unsupported
    Unsupported(String),

    /// An option was given twice or more in strict mode.
    Duplicate(Flag, Flag),

    /// Two options were given that conflict with one another.
    Conflict(&'static Arg, &'static Arg),

    /// An option was given that does nothing when another one either is or
    ///
    
    fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
        use crate::options::parser::TakesValue;

        match self {
            Self::BadArgument(arg, attempt) => {
                if let TakesValue::Necessary(Some(values)) = arg.takes_value {
                    write!(f, "Option {} has no {:?} setting ({})", arg, attempt, Choices(values))
                }
                else {
                    write!(f, "Option {} has no {:?} setting", arg, attempt)
                }
            }
            Self::Parse(e)                   => write!(f, "{}", e),
            Self::Unsupported(e)             => write!(f, "{}", e),
            Self::Conflict(a, b)             => write!(f, "Option {} conflicts with option {}", a, b),
            Self::Duplicate(a, b) if a == b  => write!(f, "Flag {} was given twice", a),
            Self::Duplicate(a, b)            => write!(f, "Flag {} conflicts with flag {}", a, b),
            Self::Useless(a, false, b)       => write!(f, "Option {} is useless without option {}", a, b),
            Self::Useless(a, true, b)        => write!(f, "Option {} is useless given option {}", a, b),
            Self::Useless2(a, b1, b2)        => write!(f, "Option {} is useless without options {} or {}", a, b1, b2),
            Self::TreeAllAll                 => write!(f, "Option --tree is useless given --all --all"),
            Self::FailedParse(s, n, e)       => write!(f, "Value {:?} not valid for {}: {}", s, n, e),
            Self::FailedGlobPattern(ref e)   => write!(f, "Failed to parse glob pattern: {}", e),
        }
    }