Hacker Timesnew | past | comments | ask | show | jobs | submitlogin

The difference is subtle. With high order function you coule define (abstract out) a new idiom, while with proper macros you could define a new special form.

In case of using high-order procedure all its arguments will be evaluated in order before application of the procedure while in case if a macro you could explicitly define all the transformations (evaluation rules) for each argument. This is why it is called a special form - it has its own evalustion rules.

Shortcircuiting if or and are canonical examples.

So, with macros you are extending Lisp with new special forms.



Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: