Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: "Gavino" Newsgroups: comp.lang.java.programmer Subject: Re: Java blunders Date: Sat, 26 Jul 2014 19:43:39 +0200 Lines: 30 Message-ID: References: X-Trace: individual.net mxw8QgBuVsUaERPhm/zbYgBEYCNakuhEVa7W+5qwcZsnxzs5z8 Cancel-Lock: sha1:sQ8kwYBMvdY9UzfG6CrhrPlR6bs= X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.5931 X-RFC2646: Format=Flowed; Original X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-Antivirus: avast! (VPS 140722-1, 22/07/2014), Outbound message X-Antivirus-Status: Clean Xref: csiph.com comp.lang.java.programmer:29344 "thinbluernime" wrote in message news:lqvlb1$c87$1@speranza.aioe.org... > On Fri, 25 Jul 2014 00:32:47 -0500, Leif Roar Moldskred wrote: > >> thinbluernime wrote: >>> On Wed, 23 Jul 2014 02:01:05 -0500, Leif Roar Moldskred wrote: >>> >>>> * No Elvis-operator or similar (it would make logging logic a lot >>>> more >>>> pleasant to write.) >>> >>> "Elvis-operator"? (And please don't anybody suggest that googling >>> "Elvis" could *possibly* be useful here.) >> >> Well, you could try googling "?:", but I suspect it would be more >> fruitful to google for "elvis operator". > > It clearly wasn't for you, if that resulted in you thinking the OP meant > the ?: operator, when he clearly didn't (as whatever he meant is > something Java lacks, but Jave *has* the ?: operator). Java has the ?: operator, but only as a ternary operator. The (so-called) Elvis operator is a BINARY one, used as a 'null-coalescing' operator: x ?: y meaning x !=null ? x : y