3 ms·
The built-in macros haven't but there's good support for procedural macros ("proc macros"), which are Rust code run at compile time that transform AST to AST.
by geofft 7y ago
The built-in macros haven't but there's good support for procedural macros ("proc macros"), which are Rust code run at compile time that transform AST to AST.
However, this is "just" a particularly well-polished form of compiler plugins - technically you can run C code at compile time with a GCC plugin, do cool things with libclang, etc. Writing project-specific compiler plugins is unusual but not totally unheard of: Linux has a couple, for instance.