Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:71662 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 71705 invoked from network); 28 Jan 2014 09:39:53 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 28 Jan 2014 09:39:53 -0000 Authentication-Results: pb1.pair.com smtp.mail=php@tutteli.ch; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=php@tutteli.ch; sender-id=pass Received-SPF: pass (pb1.pair.com: domain tutteli.ch designates 80.74.154.78 as permitted sender) X-PHP-List-Original-Sender: php@tutteli.ch X-Host-Fingerprint: 80.74.154.78 ns73.kreativmedia.ch Linux 2.6 Received: from [80.74.154.78] ([80.74.154.78:41176] helo=hyperion.kreativmedia.ch) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 7A/AA-01140-7EA77E25 for ; Tue, 28 Jan 2014 04:39:52 -0500 Received: (qmail 1429 invoked from network); 28 Jan 2014 10:39:48 +0100 Received: from heim-032-99.raab-heim.uni-linz.ac.at (HELO RoLaptop) (193.171.32.99) by ns73.kreativmedia.ch with (AES128-SHA encrypted) SMTP; 28 Jan 2014 10:39:48 +0100 To: =?iso-8859-1?Q?'Rouven_We=DFling'?= , "'Tjerk Meesters'" Cc: "'Yasuo Ohgaki'" , "'Andrea Faulds'" , "'PHP internals'" References: <52DDBAE5.2010803@ajf.me> <52E6FD70.4010005@ajf.me> <52E70943.3010700@ajf.me> In-Reply-To: Date: Tue, 28 Jan 2014 10:39:46 +0100 Message-ID: <002101cf1c0c$e1fb93e0$a5f2bba0$@tutteli.ch> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Outlook 14.0 Thread-Index: AQH9ZmxKdrBodlptjB8Sdi9eVTNnnAGwZ+zJATOrPSwDRuftsQIBlADjAq6JE6kBNDO9VQJ62K6Kmcj6vlA= Content-Language: de-ch Subject: RE: [PHP-DEV] Re: [VOTE] [RFC] Alphanumeric Decrement From: php@tutteli.ch ("Robert Stoll") > -----Original Message----- > From: Rouven We=DFling [mailto:me@rouvenwessling.de] > Sent: Tuesday, January 28, 2014 10:20 AM > To: Tjerk Meesters > Cc: Yasuo Ohgaki; Andrea Faulds; PHP internals > Subject: Re: [PHP-DEV] Re: [VOTE] [RFC] Alphanumeric Decrement >=20 >=20 > > On 28.01.2014, at 07:12, Tjerk Meesters = wrote: > > > > Btw, doing flip/flop can be done with `$val =3D (bool)1 - $val;` as = well :) >=20 > There's an even easier way: >=20 > $val =3D !$val; >=20 > Personally I don't see a need to support increment/decrement for = booleans. If at all they should be treated like they were > cast to an int first. >=20 In my opinion, it really should behave like an int for ++/-- Yet, I would not mind if ++false =3D true and beginning with true it = would change to int -> ++true =3D 2, --true=3Dfalse, --false =3D -1 respectively