Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:70349 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 29773 invoked from network); 24 Nov 2013 10:38:00 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 24 Nov 2013 10:38:00 -0000 Authentication-Results: pb1.pair.com header.from=kris.craig@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=kris.craig@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.219.50 as permitted sender) X-PHP-List-Original-Sender: kris.craig@gmail.com X-Host-Fingerprint: 209.85.219.50 mail-oa0-f50.google.com Received: from [209.85.219.50] ([209.85.219.50:35779] helo=mail-oa0-f50.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 19/33-10115-707D1925 for ; Sun, 24 Nov 2013 05:37:59 -0500 Received: by mail-oa0-f50.google.com with SMTP id n16so3164076oag.23 for ; Sun, 24 Nov 2013 02:37:57 -0800 (PST) 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=vPz2baf42Pgkdy4C4J4rRXAV8Jk3iIpQ/30n8sS9fIk=; b=YU9Y+Q7NKTzQh2fLvm5/9tfMsIO2fUwqDrBK7nfqgmp0VZi7JN/ozL0vSIHxyoOLbV hAoKzgCoWYYpryRdQOeK0xMlTHgg+veLL+aKpjWijEk8kxyZOcsmmvQji+pKpEHArfGR npBs9g36mRhJLHgRGeSI17l53mDjiEFU7xMr59k9w46Yn47NRsyDvBYJCV2xk5EbRNoR Ohdyz7uPz9BVRKDM2a5vylUpQvpsJ5+lqUad/jlPgyoTyofahj4ofvBKxpJ5xD6YKL80 G2jxLecaUufAdZVJPh1Kp2CroyBOX6YtbrTLHtW/hftdVrdZipqwtzZJelPtCsjIVS7P wjJg== MIME-Version: 1.0 X-Received: by 10.60.78.227 with SMTP id e3mr19418388oex.5.1385289477300; Sun, 24 Nov 2013 02:37:57 -0800 (PST) Received: by 10.182.221.170 with HTTP; Sun, 24 Nov 2013 02:37:57 -0800 (PST) In-Reply-To: References: Date: Sun, 24 Nov 2013 02:37:57 -0800 Message-ID: To: Tjerk Meesters Cc: Derick Rethans , PHP Internals Content-Type: multipart/alternative; boundary=089e0111bca434a76704ebe9d7d6 Subject: Re: [PHP-DEV] rfc: pow-operator From: kris.craig@gmail.com (Kris Craig) --089e0111bca434a76704ebe9d7d6 Content-Type: text/plain; charset=ISO-8859-1 On Sat, Nov 23, 2013 at 10:58 PM, Tjerk Meesters wrote: > > To support the latter "-3 ** 2 == 9" we would require a unary minus that > has a higher precedence than the exponent operator and as such falls > outside of the scope of this RFC. > > That said, I'm not even sure whether we can support a unary minus with the > current parser. > > Ok, I can accept that argument. I'm tempted to chase that unary rabbit down the hole further, but as you said that would take us off-topic. I'll just ask this, then: Hypothetically, if a unary minus for negative numbers was added in the future, how would that affect the behavior being discussed here with the proposed ** operator? I.e. if we had "-3 ** 2" with a unary minus, would the outcome be 9 or -9? --Kris --089e0111bca434a76704ebe9d7d6--