I would guess it checks what `defun` is, which is a macro...then expands it, and the expansion should ultimately result in an s-expression, which is then parses? Is this right?
Yes, but macros (like special forms, but macros can be user implementable) have some "special" powers regarding controlling the evaluation of the code they produce.
Comments
It's quite easy to see, there are interpeters for Lisp in like 20 lines or so.
Here's a good one:
https://norvig.com/lispy.html
(It has the full code in a link towards the bottom)
There's also this:
https://github.com/kanaka/mal
Yes, but macros (like special forms, but macros can be user implementable) have some "special" powers regarding controlling the evaluation of the code they produce.
Here's some more discussion with examples:
https://stackoverflow.com/questions/42470940/how-is-the-defu...
Thanks! Lisp is so damn cool.