derive-error 0.0.0

Derive macro for Error using macros 1.1

Derive Rust Errors

Build Status Latest Version Docs

This crate uses macros 1.1 to derive custom errors.

Getting Started

Add this crate to your dependencies section:-

[dependencies]
derive-error = "0.0.0"

Import it in your main.rs or lib.rs:-

#[macro_use]
extern crate derive-error;

Deriving errors is simple. Here is an example:

#[derive(Error)]
pub enum Error {
  Io(::std::io::Error),
}

That's it!