3 ms·
I can offer a counterexample: the Elixir community, despite having a (very good) macro facility at our fingertips, is largely free of macro-mania as you describ
by gamache 4y ago
I can offer a counterexample: the Elixir community, despite having a (very good) macro facility at our fingertips, is largely free of macro-mania as you describe it.
Culturally, most folks use macros to import a few things into the caller namespace, or to wrap functions somehow (e.g., add timing metrics to every function in a module), and virtually all the functionality should reside in regular functions in regular modules, rather than having the macro inject a bunch of code that doesn't exist in a testable form.
I'm not sure why we have it so good. Dreams can come true I guess. But I bet a community of low-level systems programmers might not be so well behaved :D
- WalterBright 4y ago> I haven't seen your code, so take this next comment as you see fit: Every person who advocates macros argues that they are not susceptible to the siren of creating their own incomprehensible and undocumented language. Every one who's code I had to work with, I'd point to it and say "what about that!" Even I was lured in by the Lorelei.