On Saturday 2005-09-24 04:21, Terry Reedy wrote: > Never wrote a single line, and may have not read one (in DDJ? Byte?) for > 15-20 years. How do *you* read such C? Cond 'Qmark' ....?
I seldom have to read C code aloud, and the ?: operator is rare-ish; but I would suggest reading a?b:c as "a chooses b else c" or (shaving a syllable) "a gives b else c" or something like that. Or, ploddingly but unambiguously, "a query b colon c". > Now, can you honestly say that you would (naively) read > > return foo if bar else baz > > and be certain you knew what it meant? I can't imagine *actually* reading it as if "foo" were the condition. But I can imagine reading it, to begin with, as if it were a Perlish conditionalized statement: "(return foo) if bar else ... aw heck, that can't be right". Which is probably benign but slows down comprehension. -- g _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com