On Sun, Jan 20, 2002 at 05:39:16PM +0000, Jonathan Stowe wrote:

> The conditional operator should never be used purely for its side effects
> IMO - It should always been an assignment.

I'd agree with that, though I have occassionally used ?: as an lvalue.

Perlop used to say "This is not necessarily guaranteed to contribute to
the readability of your program", but that seems to have gone from
recent versions.  Anyone know why?

I suspect it's for the same reason that the tunefs manpage no longer
says "You can tune a file system, but you can't tuna fish".  Trying to
make Perl more acceptable to management bods who probably don't even
know how to read a manpage.

Or maybe it's because it is now guaranteed to contribute to the
readability of your program :-)

I also happen to think that nested ?:s can aid readability, provided
they are formatted correctly ...

-- 
Paul Johnson - [EMAIL PROTECTED]
http://www.pjcj.net

Reply via email to