#[document_compatibility]
Expand description
A macro to document enum variants by the things that they are compatible with.
ยงExamples
use enum_compatability_macro::document_compatibility;
#[document_compatibility]
pub enum Expression {
#[compatible(Minion)]
ConstantInt(i32),
// ...
#[compatible(Chuffed)]
#[compatible(Minion)]
Sum(Vec<Expression>)
}
The Expression type will have the following lists appended to its documentation:
## Supported by `minion`
ConstantInt(i32)
Sum(Vec<Expression>)
## Supported by `chuffed`
ConstantInt(i32)
Sum(Vec<Expression>)
Two equivalent syntaxes exist for specifying supported solvers:
#[compatible(Chuffed)]
#[compatible(Minion)]
Sum(Vec<Expression>)
#[compatible(Minion,Chuffed)]
Sum(Vec<Expression>)