Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:98719 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 29958 invoked from network); 1 Apr 2017 15:33:33 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 1 Apr 2017 15:33:33 -0000 Authentication-Results: pb1.pair.com smtp.mail=php@duncanc.co.uk; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=php@duncanc.co.uk; sender-id=unknown Received-SPF: error (pb1.pair.com: domain duncanc.co.uk from 209.85.216.178 cause and error) X-PHP-List-Original-Sender: php@duncanc.co.uk X-Host-Fingerprint: 209.85.216.178 mail-qt0-f178.google.com Received: from [209.85.216.178] ([209.85.216.178:34241] helo=mail-qt0-f178.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 3F/82-02743-A48CFD85 for ; Sat, 01 Apr 2017 10:33:32 -0500 Received: by mail-qt0-f178.google.com with SMTP id n21so85975602qta.1 for ; Sat, 01 Apr 2017 08:33:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=duncanc-co-uk.20150623.gappssmtp.com; s=20150623; h=mime-version:from:date:message-id:subject:to; bh=Vbp9/sV5/wuj84lWvn7//YIxyySBGGRPVS9P59p5k2s=; b=MB+XvYAeFXC83V3TCdr0na4vkdeS6GOEuQ47IIldDI5+Gnq75lo8wUHIeR9MqBDGWZ 2/4qbu0+VvWvlJkQ6t1fDYSypCKn2dH8E2QQ65S7+KQPMZu9zUY8rrbtV2N1w0NQQFkG v4OCMd74pRiy/iXtqtX+TcWyIRxtFqEiLL1aK0OSBRyKl/3pGo7rD/Xfoz8S7gh7Qw6y nm/uQrhTnYXhHXTaxl0AOabaAQPXtcw9KgGbWqZIgO306akcM11KrGlkUIL8VBZvfmWb HXNWa4/AO3lH6QueyFQZ0mLuf4EPIKIjdez2pifDvMyqbk+f/6c1IHxxznkh37j4dvjm HqNA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=Vbp9/sV5/wuj84lWvn7//YIxyySBGGRPVS9P59p5k2s=; b=qkxatdf5oHYAtnz/HuUqrhxF5+AkCfWH+dNgPqbYMJ2jfTDRnEwmKSneZwIaP+H1M+ Mx2690Z2U2sDUK6FMPIFFY6Hn9f94U5HdocprB1wWHr5hwoe8STNx3Rv+tpYANoKMakQ jVUvELiuUo8GV2jAcDl9C/qf7wLiNZWYXy8oRHwrXyldfbzF8XrC6cMpi/AwxBl5nf2X MuXsnm+TI+iH/kKMh2uKW6a2mrDLrNG0s4+8k6RkvIDxlY3UwtXidF2K1TLZZ+kA/Pqp dMbZV0BQN65Hn+5L4Qebqc3obnvoDD9YJs56/2m3FcnunjXtNFZb+ipghxOmsVNRfvhK 5KVQ== X-Gm-Message-State: AFeK/H28fMoyzdSagYQ82rbk1KCIqLk/9mHjm+B9FZE48BZTTOcU08ho6b+3g67hkGvJQw== X-Received: by 10.237.59.8 with SMTP id p8mr8451806qte.270.1491060808133; Sat, 01 Apr 2017 08:33:28 -0700 (PDT) Received: from mail-qk0-f173.google.com (mail-qk0-f173.google.com. [209.85.220.173]) by smtp.gmail.com with ESMTPSA id t25sm5819033qkt.25.2017.04.01.08.33.26 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 01 Apr 2017 08:33:27 -0700 (PDT) Received: by mail-qk0-f173.google.com with SMTP id g195so15427902qke.2 for ; Sat, 01 Apr 2017 08:33:26 -0700 (PDT) X-Received: by 10.55.185.131 with SMTP id j125mr7891248qkf.206.1491060806307; Sat, 01 Apr 2017 08:33:26 -0700 (PDT) MIME-Version: 1.0 Received: by 10.140.34.182 with HTTP; Sat, 1 Apr 2017 08:33:25 -0700 (PDT) X-Originating-IP: [81.157.185.91] Date: Sat, 1 Apr 2017 16:33:25 +0100 X-Gmail-Original-Message-ID: Message-ID: To: Internals Content-Type: multipart/alternative; boundary=94eb2c049078b30f33054c1ca523 Subject: [PHP-DEV] [RFC] Prevent number_format() from returning negative zero From: php@duncanc.co.uk (Craig Duncan) --94eb2c049078b30f33054c1ca523 Content-Type: text/plain; charset=UTF-8 Hi internals. Following a brief discussion on the behaviour of number_format() last year I'd like to start discussion around an RFC to bring consistency to negative zero. When number_format() is passed -0 it doesn't display the negative sign, however if it's passed something that rounds to -0 then it does display the negative sign. https://3v4l.org/k4roB I believe these two operations should yield the same result. The RFC takes the stance that the rounding version should be changed to never display -0, but I'm open to hearing arguments to change number_format() to always display the negative sign when it's working with a negative number. https://wiki.php.net/rfc/number_format_negative_zero Thanks, Craig --94eb2c049078b30f33054c1ca523--