throwing-macros 0.1.1

Create explicit errors easily with a handy macro
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
use syn::{Ident, Type, Visibility};

pub struct CompositeError {
    pub visibility: Visibility,
    pub name: Ident,
    pub variants: Vec<Variant>,
    pub composed: Vec<Type>,
}

pub struct Variant {
    pub typ: Type,
    pub name: Ident,
}