3 ms·
True, macros in Rust can feel heavy, but they also enable some powerful abstractions you just can’t get otherwise. I guess the “don’t write macros” advice is mo
by iambacktomyword 1y ago
True, macros in Rust can feel heavy, but they also enable some powerful abstractions you just can’t get otherwise. I guess the “don’t write macros” advice is more about avoiding overuse than rejecting them completely.
- kachapopopow 1y agoThe only macro I ever use is json! or for applying 10 derives to more than 1 struct
- stephenlf 1y agovec!? println!?
- kachapopopow 1y agothose are language macros iirc (hardcoded in the language) hence I consider those the same as when, fn etc.