Hacker News new | ask | show | jobs
by CatDancer 6230 days ago
Hmm, I don't know if I'm going to be able to explain it very well without an example. My general experience was that I'd start with syntax-rules, which would turn out to not be powerful enough for the particular macro I wanted to write, so I'd turn to the more complex but more powerful syntax-case. Which then might turn out to not be powerful enough either, or else it might be powerful enough but I'm struggling to understand how to implement my macro using it, plowing my way through pages of documentation and reading examples.

Then there's a macro in Arc, for example,

  (mac awhen (expr . body)
    `(let it ,expr (if it (do ,@body))))
which, on the one hand, yes it is true it's not hygienic. But, on the other hand, I can bang out in seconds. So now I'm moving ahead writing my program instead of struggling to write a macro. And the lack of hygiene has never been an actual problem for me in practice.

I imagine that a Scheme programmer who was experienced in writing hygienic macros and so could write them quickly, and who was more bothered by the lack of hygiene than I am, could well reach a different cost/benefit decision than I do and decide they'd rather go with hygienic macros.