|It seems to make things harder.|
How would you write a function that takes 3 "elements" and arranges them in a certain way?
The problem is: a, b and c have already been evaluated, so what you will end up with is (roughly):
(def something (a b c)
(re-arragne a b c))
So everything now has to be a macro, to prevent arguments from evaluating before the structure is generated. It just makes things harder and counter intuitive.
<output of a>
<output of b>
<output of c>
<empty structure generated by re-arrange>
Let's look at 'row, it takes objects and prints them:
But it can also take expressions that print html:
arc> (row 1 2 3)
How does it do that? Let's look at the definition:
arc> (row (tag div (pr 1)) 2 3)
Too many tricks. Too clever.
(mac row args
`(tr ,@(map [list 'td _] args)))
What's the point?
Wouldn't it be easier if everything just returned strings and then these strings were concatenated together?
This way, 'row can be just:
Or something like that.
(def row args
(tab:tr (apply td args))