Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:21587 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 30504 invoked by uid 1010); 20 Jan 2006 13:30:34 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 30488 invoked from network); 20 Jan 2006 13:30:34 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 20 Jan 2006 13:30:34 -0000 Received: from ([127.0.0.1:24429]) by pb1.pair.com (ecelerity 2.0 beta r(6323M)) with ECSTREAM id 0F/D6-05698-AF5E0D34 for ; Fri, 20 Jan 2006 08:30:34 -0500 X-Host-Fingerprint: 80.68.92.31 alcopop.org Linux 2.4/2.6 Received: from ([80.68.92.31:4220] helo=alcopop.org) by pb1.pair.com (ecelerity 2.0 beta r(6323M)) with SMTP id 4A/22-05698-82BC0D34 for ; Fri, 20 Jan 2006 06:36:08 -0500 Received: from jon by alcopop.org with local (Exim 3.36 #1 (Debian)) id 1EzuYj-0005Wq-00; Fri, 20 Jan 2006 11:36:01 +0000 Date: Fri, 20 Jan 2006 11:36:01 +0000 To: internals@lists.php.net Message-ID: <20060120113601.GL17465@alcopop.org> Mail-Followup-To: internals@lists.php.net References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.9i Sender: Jon Dowland Subject: Re: [PHP-DEV] 23 nothing is so as it seems, but why From: lists@alcopop.org (Jon Dowland) On Thu, Jan 19, 2006 at 06:41:17PM +0200, Marco Kaiser wrote: > Today during a session i had a strange "magic" feature found in php. > > $a = 10; > echo ++$a + $a++; > ?> > > this works perfect as expected. it returns 22. Odd, I expected 21: echo (11 + 10) a = a + 1 -- Jon Dowland http://alcopop.org/