Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:68235 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 1767 invoked from network); 20 Jul 2013 02:17:09 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 20 Jul 2013 02:17:09 -0000 Authentication-Results: pb1.pair.com smtp.mail=yohgaki@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=yohgaki@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.217.174 as permitted sender) X-PHP-List-Original-Sender: yohgaki@gmail.com X-Host-Fingerprint: 209.85.217.174 mail-lb0-f174.google.com Received: from [209.85.217.174] ([209.85.217.174:33961] helo=mail-lb0-f174.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 70/B7-13120-323F9E15 for ; Fri, 19 Jul 2013 22:17:08 -0400 Received: by mail-lb0-f174.google.com with SMTP id x10so3878145lbi.5 for ; Fri, 19 Jul 2013 19:17:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=Kprdk4cnF8DSJmzTkqQfpZE2jUHNwSrDiJXHToLajWw=; b=OXjhcr9Gqy0JCgr5WXvXmoJBETmJzD/By1/S5ZPpTeGYKhcR7x/MrlFnEtuWd1ILiD qGycwjYUOKzwiCbl44qE16D3VV+ZzFMQ06XFf5KuyCJ6yyxDbOBjyzwdex7cUdJzNBhS oWFqOYC2TS6DzHZs9uxMp0ybN1mOvaOlyGPW1A1V4fTwNE0cQpeOrfo8MnQ3hyRfV8kL 5ZGGg1+NJkVhsY+LOW8fWCagNFdmZC2OuQPrE1DS+zosysIZ+MuL8Aoh3V7omZKS6mVl AD2flCkFNZ/FNrYPlUmh+THJCfsyOd0KI4o4gy9sS+nhfId4dDr/g4h7mrQqEgasRzyV Ugig== X-Received: by 10.112.14.33 with SMTP id m1mr8488656lbc.17.1374286625135; Fri, 19 Jul 2013 19:17:05 -0700 (PDT) MIME-Version: 1.0 Sender: yohgaki@gmail.com Received: by 10.112.4.233 with HTTP; Fri, 19 Jul 2013 19:16:24 -0700 (PDT) In-Reply-To: References: Date: Sat, 20 Jul 2013 11:16:24 +0900 X-Google-Sender-Auth: yUSHnIHBgdZwrcMUvbdhhKcxP5Q Message-ID: To: Sherif Ramadan Cc: Sara Golemon , PHP internals Content-Type: multipart/alternative; boundary=001a11c37b0a1c63b104e1e80a52 Subject: Re: [PHP-DEV] Operator precedence is undefined? From: yohgaki@ohgaki.net (Yasuo Ohgaki) --001a11c37b0a1c63b104e1e80a52 Content-Type: text/plain; charset=ISO-8859-1 Hi Sherif, Thank you for your info! 2013/7/20 Sherif Ramadan > I don't see where there is a bug in the documentation, no. It is in doc's example code. ------ // mixing ++ and + produces undefined behavior $a = 1; echo ++$a + $a++; // may print 4 or 5 ------ http://www.php.net/manual/en/language.operators.precedence.php I think ?: operator is good for an example, since it has different associativity than C/C++. If there aren't comments, I'll rewrite the example. Regards, -- Yasuo Ohgaki yohgaki@ohgaki.net --001a11c37b0a1c63b104e1e80a52--