python and macros (again) [Was: python3: 'where' keyword]
Craig Ringer
craig at postnewspapers.com.au
Thu Jan 13 14:18:56 EST 2005
On Thu, 2005-01-13 at 08:39 +0000, Antoon Pardon wrote:
> > At best it would offer new paradigms for existing constructs (violating
> > the "there should be one obvious way to do it" zen); at worst it would
> > obfuscate the whole language.
>
> That zen is already broken. Look at the number of answers one gets
> if a newbee askes for a ternary operator. I think that a simple
> ternary operator or macro's with an official supported macro that
> implemented the ternary operator would have been far closer to
> the spirit of only having one obvious way than what we have now.
And then we have iteration ....
(generator expressions, list comprehensions, for loops, ...?) over
(sequences, iterators, generators)
I happen to be extremely fond of the flexibility this provides, but one
obvious way to do it there is not.
--
Craig Ringer
More information about the Python-list
mailing list