Hacker News new | ask | show | jobs
by mapgrep 1962 days ago
What you said is true and perceptive — it is at base like writing the AST - but most of the time you’re just doing function calls with the opening paren shifted to the other side of the function name.

In other words, in Algol like languages you’re typically calling like(this) (or the dotted.equivalent(form)) and in lisp it’s (like this).

You do eventually take advantage of the fact that you’re writing an AST, when you get into macros. But that feels pretty simple once you’re used to the function syntax, since macros just manipulate the resulting structures.

What used to throw me off was the special syntax for lists - ‘(structures looking like this) - but once you get used to using the lisp structure for function calls it becomes clear why and when this kind of quoting is necessary (any time you want a list as data instead of a function call).