# Struct clap::Error [−] [src]

    pub struct Error {
        pub message: String,
        pub kind: ErrorKind,
        pub info: Option<Vec<String>>,
    }

Command Line Argument Parser Error

## Fields

`message` | Formated error message
`kind` | The type of error
`info` | Any additional information passed along, such as the argument name that caused the error

## Methods

### `impl Error`

#### `fn use_stderr(&self) -> bool`

Should the message be written to `stdout` or not

#### `fn exit(&self) -> !`

Prints the error to `stderr` and exits with a status of `1`

## Trait Implementations

### `impl StdError for Error`

#### `fn description(&self) -> &str`

#### `fn cause(&self) -> Option<&Error>`1.0.0

### `impl Display for Error`

#### `fn fmt(&self, f: &mut Formatter) -> Result`

### `impl From<Error> for Error`

#### `fn from(e: Error) -> Self`

### `impl From<Error> for Error`

#### `fn from(e: Error) -> Self`

### Derived Implementations

### `impl Debug for Error`

#### `fn fmt(&self, __arg_0: &mut Formatter) -> Result`

# Help

## Keyboard Shortcuts

?
  Show this help dialog
S
  Focus the search field
⇤
  Move up in search results
⇥
  Move down in search results
⏎
  Go to active search result

## Search Tricks

Prefix searches with a type followed by a colon (e.g. `fn:`) to restrict the search to a given type.

Accepted types are: `fn`, `mod`, `struct`, `enum`, `trait`, `type`, `macro`, and `const`.

Search functions by type signature (e.g. `vec -> usize` or `* -> vec`)