Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:77238 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 45702 invoked from network); 16 Sep 2014 09:16:24 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 16 Sep 2014 09:16:24 -0000 Authentication-Results: pb1.pair.com header.from=dmitry@zend.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=dmitry@zend.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain zend.com designates 209.85.220.177 as permitted sender) X-PHP-List-Original-Sender: dmitry@zend.com X-Host-Fingerprint: 209.85.220.177 mail-vc0-f177.google.com Received: from [209.85.220.177] ([209.85.220.177:41816] helo=mail-vc0-f177.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id A2/2B-64534-6EFF7145 for ; Tue, 16 Sep 2014 05:16:23 -0400 Received: by mail-vc0-f177.google.com with SMTP id la4so4583720vcb.8 for ; Tue, 16 Sep 2014 02:16:18 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=rflzXGydIouPsgz1iDSelQ6pecLQnL1+M7POiAG4pyY=; b=MuwaxHb0E8FDkyzi9hJR2QN6CjjL8YdEUzNKNYPV8I2c3JthGdpQGHLiUFlEMQLSXH cpz+V+VPrXNzOiLlBosZ+GrUP2kCAoNr9x06mWlqJxLNUR1426Sr48xrExSmA3YY+Ifw DFFf8daNayk89QbL/5vmZLkfqxYXK+r8bRjfr3MYFrjM+FY0ewfOKmg+DE4LDVjWs3Pa aR9dqTIKUyzYKxN2H9PwlKqRMK541GTvlqtelwAyiAVQyrmyNEhGXd0OB8LFss45sT+A maXkqUxFc3YTIkgQyyNCqV+Af9mHC90CZ6id19vxTH2op/eEWUxIcNxjusN2TPQcAgzV 7+zA== X-Gm-Message-State: ALoCoQnOQAEZlFM10tza1ZO9rvZVBGKQFEAk57Qw9oDRIMLQ7QQBkBPn+EamWmjjzlILSQvAKU1V9XTShoVuaa5oTABwggksZ3TkRPb7zV72ajghexM9DJb8QL9nff4rlyoQTD36qT14oOdXSS3TbdwLSDhJWp2Veg== MIME-Version: 1.0 X-Received: by 10.220.160.66 with SMTP id m2mr8204455vcx.56.1410858978554; Tue, 16 Sep 2014 02:16:18 -0700 (PDT) Received: by 10.52.158.197 with HTTP; Tue, 16 Sep 2014 02:16:18 -0700 (PDT) In-Reply-To: <528B8D9E-58FF-47DD-9B91-013F8844EC70@ajf.me> References: <528B8D9E-58FF-47DD-9B91-013F8844EC70@ajf.me> Date: Tue, 16 Sep 2014 13:16:18 +0400 Message-ID: To: Andrea Faulds Cc: Levi Morrison , PHP Developers Mailing List Content-Type: multipart/alternative; boundary=001a11c2a9f23ed48a05032b34e7 Subject: Re: [PHP-DEV] [VOTE][RFC] Integer Semantics From: dmitry@zend.com (Dmitry Stogov) --001a11c2a9f23ed48a05032b34e7 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Hi Andrea, Shifts by negative number may make sense. (N << -1) =3D> (N >> 1) At least receiving "false" from shift is not very pleasant. In the patch you use SIZEOF_LONG. It probably should be changed to SIZEOF_ZEND_LONG. Thanks. Dmitry. On Mon, Sep 15, 2014 at 8:31 PM, Andrea Faulds wrote: > > On 15 Sep 2014, at 17:24, Levi Morrison wrote: > > >> This RFC has been put to a vote. It starts today (2014-09-14) and ends > in a week=E2=80=99s time (2014-09-21). > >> > >> https://wiki.php.net/rfc/integer_semantics#vote > > > > A few people have asked why I voted no; the only reason is that > > division by zero will return `false` and emit a warning. Integers can > > be converted to floating point numbers and dividing by zero in IEEE > > 754 is defined as INF. I would rather leave behavior undefined by > > voting no on this RFC than by defining it to a value which does not > > make sense to me. The value false will get converted to zero in any > > additional math, which is not the same as INF. > > The RFC does not touch division by zero. That was a suggestion for a > future RFC. > > I=E2=80=99ve now removed that section to avoid confusion. > -- > Andrea Faulds > http://ajf.me/ > > > > > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > --001a11c2a9f23ed48a05032b34e7--