Locke Cole wrote:
On 4/14/06, William Allen Simpson
It doesn't make sense to have whitespace
between the # and the if, and no
demonstrable reason to have it before the colon.
For formatting, to make it easier to read.
I've never found adding a space before the colon at the end of a sentence
fragment to be easier to read, either.
What's hard to read about "#if:"? "#ifeq:"? "#ifexpr:"?
allowed after the colon, correct?
The logic of
qif was often confusing. There's only very short term
advantage to backward compatibility. Having #eval and #if work like
other languages will be easiest to document in the long term. Remember,
features aren't of much use without easy to understand documentation.
Having #if test for blank/non-blank makes more sense. #ifexpr now
wraps what would have previously been a call to #if *and* #expr into a
single call. If you still need to test against 0 or 1, you can use
The documentation just changed today, so it's a done deal.
Note that even the documentation says:
... It is intended as an "if defined" structure. ...
So, it should be called "#ifdef:" to match ingrained expectations. Could
"#if:" be quickly retired?
Also, "#ifexpr:" just showed up in the documentation today, so you'll
forgive me for not knowing about it. And wouldn't we just use
"#ifexpr: X = 0" otherwise?
"#ifeq:" is for matching strings, not against "0". See what I mean
about ingrained expectations?