Rust Macros and Functions

Rust Macros and Functions

Introduction The term macro refers to a family of features in Rust: declarative macros with macro_rules! and three sorts of procedural macros: Custom #[derive] macros that specify code added with the derive attribute used on structs and enums Attribute-like macros that outline custom attributes usable on any item Function-like macros that appear as if the … Read more