Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:86923 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 75483 invoked from network); 28 Jun 2015 09:58:55 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 28 Jun 2015 09:58:55 -0000 Authentication-Results: pb1.pair.com header.from=ml@anderiasch.de; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=ml@anderiasch.de; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain anderiasch.de designates 81.169.138.148 as permitted sender) X-PHP-List-Original-Sender: ml@anderiasch.de X-Host-Fingerprint: 81.169.138.148 ares.art-core.org Received: from [81.169.138.148] ([81.169.138.148:43779] helo=ares.art-core.org) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 38/10-05436-A55CF855 for ; Sun, 28 Jun 2015 05:58:51 -0400 Received: from [192.168.178.20] (p5089787A.dip0.t-ipconnect.de [80.137.120.122]) by ares.art-core.org (mail.art-core.org) with ESMTPSA id 823702EE163; Sun, 28 Jun 2015 11:58:47 +0200 (CEST) Message-ID: <558FC556.40405@anderiasch.de> Date: Sun, 28 Jun 2015 11:58:46 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: Stanislav Malyshev , PHP Internals References: <558F43CA.8000700@gmail.com> In-Reply-To: <558F43CA.8000700@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] NAN/INF->int conversion in 5.6 From: ml@anderiasch.de (Florian Anderiasch) On 28.06.2015 02:46, Stanislav Malyshev wrote: > My question is: should we backport code from PHP 7 that checks for > infinity/nan and put it into 5.6? Or it's not worth it and it's ok for > 5.6 to return random weird stuff there? (I know it's not exactly random > and there's a reason why it's that number but it looks that way). While I can't imagine many people would stumble over this (as apparently there was no bug report) it could be a tricky one if you're not extra paranoid when working with INF, I don't think it's worth changing this behaviour so long after 5.6.0 was released. Good that it's fixed in 7 though. It should absolutely be documented (and I still can't fathom why searching for INF on the website only gives me function results and not a direct hit for a 1:1 match on a pre-defined constant in core, but let's not start this discussion.) Greetings, Florian