one-of
Macro to represent a type that can be converted either From
or Into
the given types
This crate only works on the nightly version of Rust
Usage
use one_of;
// either `u32` or `char`
let x: one_of! = 42.into;
assert_eq!;
assert_eq!;
// some type of integer
let x: one_of! = 42.into;
assert_eq!;
assert_eq!;
assert_eq!;
assert_eq!;
assert_eq!;
assert_eq!;
assert_eq!;
assert_eq!;
Changelog
See CHANGELOG.md