impl_feature_adder

Macro impl_feature_adder 

Source
macro_rules! impl_feature_adder {
    ($struct_name:ident) => { ... };
}
Expand description

A macro to provide an automatic implementation of the FeatureAdder trait for types that implement LengthCheckedFeatureAdder. This allows you to take advantage of the compile-time guarantees provided by LengthCheckedFeatureAdder, while still being able to use your type in contexts that require a FeatureAdder object. This macro is used to bridge the gap between the two traits, as Rust’s type system does not currently provide a way to prove to the compiler that there will always be exactly one implementation of LengthCheckedFeatureAdder for each type.