Hi Anatol, On Tue, Sep 22, 2015 at 4:35 AM, Anatol Belski <[email protected]> wrote: >> -----Original Message----- >> From: [email protected] [mailto:[email protected]] On Behalf Of Yasuo >> Ohgaki >> Sent: Sunday, September 20, 2015 11:49 PM >> To: Kalle Sommer Nielsen <[email protected]> >> Cc: Anatoliy Belsky <[email protected]>; Ferenc Kovacs <[email protected]>; >> [email protected] >> Subject: Re: [PHP-DEV] Re: [RFC] [DISCUSSION] More precise float value >> >> Hi Anatol and Ferenc, >> >> On Sat, Sep 19, 2015 at 7:15 AM, Kalle Sommer Nielsen <[email protected]> wrote: >> > I'm sorry I have not caught this any earlier, but even without >> > consulting with Anatol, I'm not keen on adding this into 7.0, we are >> > in RC stage, and I want us to focus on a stable release instead of >> > adding more potential issues, I suggest you target 7.1 instead in the >> > RFC. >> > >> > (Ferenc and Anatol cc'd) >> >> I was expecting this kind of reply for this RFC. >> What do you think? >> >> This RFC contains JSON float value precision change for PHP 5.6 so that PHP >> would not loose floating number information, as well as more precise float >> handling option for PHP 7.0. >> >> FYI, var_dump()'s float precision was changed to use serialize_precision as >> bug >> fix before. >> > Thanks for the ping. IMHO this is the stuff for 7.1. I actually saw the > discussions previously, but was rather thinking you was targeting 7.1 as that > was already the time of the feature freeze.
No problem. I'll update so that 0 mode is for 7.1. JSON's is better to use larger precision. So this change is targeted to 5.6 and 7.0. Let me know if you have comments on this. > > Please keep in mind that we effectively have two RCs to do the remaining > stabilizations. And we probably should as much as possible. Because this > patch it's rather an enhancement to the current functionality which is not > indeed broken - I wouldn't see it as critical for 7.0. It should be voted > (and discussed if necessary) for 7.1, so we don't loop away from our current > situation. > > BTW I also had a comment there in the PR about > https://github.com/php/php-src/pull/1455/files#diff-c84859666ff690a113d55ef1899d8bf4R149 > - so if mode 0 ignores ndigits, why set it to 17 (or anything else). Seems > like an unnecessary action, but snprintf is used quite frequently. But just > as a notice on the side. "-1" which is invalid precision is used to indicate 0 mode. 0 mode is supposed to use max precision for double (it seems many implementations use 16, but PHP uses 17), when 0 mode is used, it uses 17 as precision always. Regards, -- Yasuo Ohgaki [email protected] -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
