3 ms·
The next logical step is to mark with parentheses the two branches of the if expression: (if (or cond1 cond2) (then) (else)) although i suppose it's not rea
by cmsd2 9y ago
The next logical step is to mark with parentheses the two branches of the if expression:
(if (or cond1 cond2) (then) (else))
although i suppose it's not really hugo anymore..
- seanwilson 9y agoIs there a reason something more standard like "if cond1 or cond2 then x else y" isn't supported? Parsing speed?
- kaushalmodi 9y agoGoing along with the joke, that's almost how elisp (most of the other lisps too, I believe) works: (if (or cond1 .. condn) (progn (true1) (true2)) (false1) (false2)) But in Go templates, it would be: {{ if (or cond1 .. condn) }} true1 true2 {{ else }} false1 false2 {{ endif }}