Let's write a macro in Rust - Part 1
Macros are required to do some very helpful things in Rust, but this isn’t an article about any of those things.
I became ennamored with macros many years ago when I read Practical Common Lisp and saw the implementation of a SQL DSL that works with built in data structures. The whole implementation took less than a screen of code and absolutely blew away my expectations of what it took to create DSLs.
In this article, I will try to share some of that excitement with you while using Rust’s macro ...
Read more at hackeryarn.com