Thanks to everyone who has commented about ternary operators. In particular; thanks to Steve Alexander for pointing out PEP 308 to me along with this opinion that the python guys made the right choice.

Thanks also to the several people (namely Jonathon Jongsma, Matthew Good and Ross Burton ) for either emailing me or finding me on IRC to tell me about the fact that cond and truth or falsehood is also a python idiom for the ternary operator with the same caveats as the lua structure of the same form. Gunnar Wolf made a posting about ternary operators too. Thanks for your comments there Gunnar; interesting that perl6 will change the ternary operator from ? : to ?? ::. I wonder how that will affect class/module members etc.

Unfortunately noone yet has come up with a nice plausible luaish idiom for me to use in Aranha so I’m going to have to continue to ponder them. The best I have so far is: (if cond then truth else falsehood) where the parentheses are obligatory.

Comments on this page are closed.