macro-attr
This crate provides the macro_attr!
macro that enables the use of custom, macro-based attributes and derivations. Supercedes the custom_derive
crate.
Links
Compatibility
macro-attr
is compatible with Rust 1.2 and higher.
Example
extern crate macro_attr;
// Define some traits to be derived.
// Define macros which derive implementations of these macros.
};
=> ;
}
// Here is a macro that *modifies* the item.
};
}
macro_attr!
License
Licensed under either of
- MIT license (see LICENSE or http://opensource.org/licenses/MIT)
- Apache License, Version 2.0 (see LICENSE or http://www.apache.org/licenses/LICENSE-2.0)
at your option.
Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you shall be dual licensed as above, without any additional terms or conditions.