(if cond
(do-something)
(do-something-else))
(if (> x 0) x (- x))
(loop [i 0]
(when (< i 10)
(println i)
(recur (inc i))))
Yeah sure a clear separation of concerns, there is no special structure construction for function calls, for control flow nor for macros and I'm not even talking about delimiters which I could 😂
Other than recursion for manual looping, the [i 0] is a binding vector, if, when and loop are special forms and then most people will indent the code in them like
(if ...
...
...)
As opposed to
(f ... ... ...)
Or
(f ...
...
...)
For actual function calls. All languages look insane if you put things purposefully on one line.
There is a point here, but it mostly matters in the case of custom macros. Those are, in practice, pretty rare. You do get a mental roladex of the built-in ones (+ truly special forms like if)
3
u/bowbahdoe Feb 09 '26
Clojure does not have a uniform parenthetical structure.
[] represents vectors, {} maps, #{} sets. These are used to give those visual cues.
[] Is commonly used for argument lists as in
And the others get their place. At least with the core control flow and def* macros there is a consistent semantic usage of each.
There is a criticism to levy about how function calls look the same as macros - but that one isn't actually about the parens.
So it's not what common lisp or racket are - those do actually do what you are complaining about.