Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:105039 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 2445 invoked from network); 3 Apr 2019 14:52:44 -0000 Received: from unknown (HELO mail-wr1-f49.google.com) (209.85.221.49) by pb1.pair.com with SMTP; 3 Apr 2019 14:52:44 -0000 Received: by mail-wr1-f49.google.com with SMTP id g3so20895339wrx.9 for ; Wed, 03 Apr 2019 04:48:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=wZvU/3iTglTlSw0B1rdeLz6XhoxPoLykQiOrgx8CvmU=; b=CpqEr1Wk3Jmy2FYGH4woB/heiw0iC1Ga9GhMDM+sbOaz5e5o0WK2crb6pIiSBCGMj2 l6wrm2erGV4PTK6OruYUd4A5CEJMzP353RnGH7oU2I41cNaRMgfB37BRB0FE14XyLUge oMniiCKx9H9EwX6gs615hgorGiEHHi6c66Hk+gDl87Ywm+3x4wV6VZs0qYy0/ZPI6rQV Xo8ULu8cwK4BqF6BgzlSlJ963nw7xk3+snLXqrObdzjg8MjGyaVCtXxV9+KpSpG0L+0t MCWXVk5BlmJSZcXExLw5c+98vWRopiBXBSZTT6YIamsmWG5+Za9qi3VR7HVOE8PMTYVZ 8K0Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=wZvU/3iTglTlSw0B1rdeLz6XhoxPoLykQiOrgx8CvmU=; b=rbTXyaztpD983HSpx6k7OiCZykE5T7lhfLEaoKZo7Eht89h8fvCrHk/+rbQvl9tOLg 3Zzih+oYG/Mhes5sv8bpMHMaXcBknqrIjCGPIpzD+8R2fGIWb5GJTPuMM1IVKDvzlYFO fwvw/3Ciam2eRIxEqKOVnvz9OQa0SemuhDRhjHc1HxWFpuj9F3EqmcZA2dV9vt16E/tY Jst3VSc2WEBCsXwKkiGPiVcw6wCrIZOJ7HlywgKqGrUzqr7dSIZJbHVnIfzbVclYEvTD 3jIxy8qoWBTG7SHk9hYU9BbSnpKsqOdaBE5OXNLCidoVewFsuMhDA2SiXgGnI1WWBZbX tbLw== X-Gm-Message-State: APjAAAU/FTM24nNg90zjFYbxy1nzDJ7BcESnhE7dWuxum1Os/IswFx28 h6rzjTkVwuZhXhKi4mlQZIIWvGSSVq3LPsorZXA= X-Google-Smtp-Source: APXvYqxjeI85iP3Qqiw6LGmnIQ9rOrm7RIFrj6WAr1T+6RKgJ7AEVg1y5b4Pv+Ith8ZDdcH2jO56vTZqqHz1O5xaBp8= X-Received: by 2002:adf:db05:: with SMTP id s5mr47875169wri.247.1554292086488; Wed, 03 Apr 2019 04:48:06 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Wed, 3 Apr 2019 13:47:55 +0200 Message-ID: To: Diogo Neves Cc: PHP Internals Content-Type: multipart/alternative; boundary="000000000000b1409705859ed359" Subject: Re: [PHP-DEV] PHP_FLOAT_MIN is positive From: krakjoe@gmail.com (Joe Watkins) --000000000000b1409705859ed359 Content-Type: text/plain; charset="UTF-8" 2.2250738585072E-308 This is negative. Cheers Joe On Wed, 3 Apr 2019 at 12:27, Diogo Neves wrote: > It really don't make much sense: > > > var_dump( PHP_FLOAT_MIN < 0 ); > var_dump( PHP_INT_MIN < 0 ); > > On Wed, Apr 3, 2019 at 10:52 AM Benjamin Morel > wrote: > > > Hi internals, > > > > I just used PHP_FLOAT_MIN for the first time, and was surprised that it > is > > the smallest **positive** number representable. Is this expected? > > > > This is unlike PHP_INT_MIN, which is the absolute smallest representable > > integer, and as such is negative: > > > > echo PHP_INT_MIN; // -9223372036854775808 > > echo PHP_FLOAT_MIN; // 2.2250738585072E-308 > > > > If it is intended, maybe the doc > > should be clear > > about this, at the moment it is just: > > > > Smallest representable floating point number. > > > > > > Which is confusing IMO. > > > > Cheers, > > Ben > > > --000000000000b1409705859ed359--