I have a condition in my Hamlet template that looks like this:
$if (&&) (index == 0) (row == 0)
which works fine. If I try to re-write this as the more natural
$if (index == 0) && (row == 0)
or
$if ((index == 0) && (row == 0))
then it doesn’t parse. The error message is:
Exception when trying to run compile-time code:
unexpected "&"
expecting ")"
This is puzzling; does it support some binary operators but not others?
What are the rules governing what kinds of expressions can be used in an $if
statement in Hamlet?