[][src]Macro cfgmap::value

macro_rules! value {
    ($($tt:tt)*) => { ... };
}

Creates a CfgValue value using the passed variable.

Examples:

let s = value!(4);
let x = value!(3.2);
let y = value!("hello there");
let a = value!(vec![value!(3), value!(9.4), value!("amazing")]);
let m = value!(CfgMap::new());

assert!(s.check_that(IsInt));
assert!(x.check_that(IsFloat));
assert!(y.check_that(IsStr));
assert!(a.check_that(IsListWith(Box::new(IsInt | IsFloat | IsStr))));
assert!(m.check_that(IsMap));