Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:76496 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 84688 invoked from network); 13 Aug 2014 19:05:16 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 13 Aug 2014 19:05:16 -0000 Authentication-Results: pb1.pair.com smtp.mail=nikita.ppv@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=nikita.ppv@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.219.44 as permitted sender) X-PHP-List-Original-Sender: nikita.ppv@gmail.com X-Host-Fingerprint: 209.85.219.44 mail-oa0-f44.google.com Received: from [209.85.219.44] ([209.85.219.44:41135] helo=mail-oa0-f44.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 1B/62-03780-CE6BBE35 for ; Wed, 13 Aug 2014 15:05:16 -0400 Received: by mail-oa0-f44.google.com with SMTP id eb12so150335oac.31 for ; Wed, 13 Aug 2014 12:05:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=XXZfA+KPo1rYVdSspMaFWi3B907mCkzLoneD0EcuSK0=; b=NFZVsGM7PnPFTkPh9ujVm5wDYz2ccZ2Pg3MrbMiNREAyoMZqp9+yqzDcGRgJ9oOb4a 0sBFhzj/V/sNKrJINZgtgE8x3jODGsRQsytq22RK66oyX8f6phJSISA25sCB3NeF2wxv Bp0dNjzSvHUGAs0zvOeX4a33cijOHbI04caSG4BzxU7y4LGI1O8LpZoOAAcdjOtS7WD4 r8uX0k+pc66el7d6RgI356qpvujTtsmB79JP6LcDRb/LX845mf3DUmX+1HjZ2jkBAvkX z1wXXX9mzOQRUq1X1q7+c4hRDxa2lGEd0k/14G/CQLfPf5ENIXJLVulsEVjrpd0iCaw8 qKQg== MIME-Version: 1.0 X-Received: by 10.182.118.193 with SMTP id ko1mr6812597obb.45.1407956713674; Wed, 13 Aug 2014 12:05:13 -0700 (PDT) Received: by 10.182.65.229 with HTTP; Wed, 13 Aug 2014 12:05:13 -0700 (PDT) In-Reply-To: References: <3F1B2834-3939-4F86-86E0-207D2CE469D6@ajf.me> Date: Wed, 13 Aug 2014 21:05:13 +0200 Message-ID: To: "guilhermeblanco@gmail.com" Cc: Andrea Faulds , PHP internals Content-Type: multipart/alternative; boundary=089e0115ea30c71c2405008777da Subject: Re: [PHP-DEV] [RFC] Introduce Abstract Syntax Tree From: nikita.ppv@gmail.com (Nikita Popov) --089e0115ea30c71c2405008777da Content-Type: text/plain; charset=UTF-8 On Wed, Aug 13, 2014 at 7:18 PM, guilhermeblanco@gmail.com < guilhermeblanco@gmail.com> wrote: > When is this planned to go through voting process? > Before voting I'd like to have some opinions on the behavioral differences the proposal introduces. In particular I'd like to know whether we are okay with changing order of evaluation in some places. We document that evaluation order is undefined, we document that it can change without warning between versions and that it is inconsistent within one version. However in the current implementation evaluation is usually left-to-right. The AST implementation introduces some places where evaluation is explicitly right-to-left, and not just incidentally. So basically the question is whether we are committed to things like $a[$i++] = $i++ or $a[$i++][$i++] = $j being undefined behavior, in which case order doesn't matter. If not, I can preserve left-to-right behavior here (CVs notwithstanding of course), but it would come at the cost of a good bit of additional complexity in the implementation (I suspect that I'd have to reintroduce parts of the bp stack to properly shuffle the oplines around). My personal opinion is that things like $a[$i++] = $i++ have zero practical relevance (and also think that anyone using something like this deserves any breakage he gets). I'd rather save some lines of code than maintain any behavior guarantees for that. But some people have contrary opinions on this, so I'm bringing up the point for discussion. Nikita --089e0115ea30c71c2405008777da--