Macro recital::constraints [] [src]

macro_rules! constraints {
    ($a:ident, $($b:expr), *) => { ... };
}

Creates a new set of constraints.

use recital::resolve::Constraints::And;
use recital::resolve::Operation::Exactly;

let constraints = constraints!(And,
                               Exactly(version!(1, 2, 3)),
                               Exactly(version!(4, 5, 6)));

is the same as

use recital::resolve::Constraints::And;
use recital::resolve::Operation::Exactly;

let constraints = And(vec![Box::new(Exactly(version!(1, 2, 3))),
                           Box::new(Exactly(version!(4, 5, 6)))]);