Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:107373 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 31197 invoked from network); 4 Oct 2019 22:47:39 -0000 Received: from unknown (HELO php-smtp3.php.net) (208.43.231.12) by pb1.pair.com with SMTP; 4 Oct 2019 22:47:39 -0000 Received: from php-smtp3.php.net (localhost [127.0.0.1]) by php-smtp3.php.net (Postfix) with ESMTP id A4FD12C047A for ; Fri, 4 Oct 2019 13:29:04 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp3.php.net X-Spam-Level: X-Spam-Status: No, score=-2.4 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: X-Spam-Virus: No Received: from mo6-p00-ob.smtp.rzone.de (mo6-p00-ob.smtp.rzone.de [IPv6:2a01:238:20a:202:5300::10]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by php-smtp3.php.net (Postfix) with ESMTPS for ; Fri, 4 Oct 2019 13:29:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1570220940; s=strato-dkim-0002; d=kelunik.com; h=Cc:To:Subject:Message-ID:Date:From:In-Reply-To:References: X-RZG-CLASS-ID:X-RZG-AUTH:From:Subject:Sender; bh=GzF/QAPH1dWgoHTkJD6sW00nywPf1/o2uy5YP+FT6Qw=; b=s6CgXV+CtR0KIBjxkgpoukO7ci0WDmxERYX7q/huJKp0lWTwLfP7ugkyxI/h/FlREv 9prs0ltkc15qkRKsLb3hY4H1d5B9b9aHcKVpOq1qYex6QpxlAWZDNFHJNzSpzVNhGC1P MJXGJ81aN3/ZQfYVvwq+GI/6PoRPTIfrmrXfzhvCi/qyKfOWgh8Bh6SWFbg4rcl5MEW0 KZqGTnsdSUX53n7Hr4vOEK7m+6PtxgcR3vWe+zkfStYHElzSwJNfUKEzXy8TfOaH1Tgn 8k5xOnuyNno7Q8D+mMTCCEezp3MJm/86sPtz7Rtw0GFCuuyVOrufaygiKSRO/V7Dj/BN r5aw== X-RZG-AUTH: ":IWkkfkWkbvHsXQGmRYmUo9mlsGbEv0XHBzMIJSS+jKTzde5mDb8AaBYcZiAucA==" X-RZG-CLASS-ID: mo00 Received: from mail-pf1-f172.google.com by smtp.strato.de (RZmta 44.28.0 AUTH) with ESMTPSA id J084cav94KT0tIT (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (curve secp384r1 with 384 ECDH bits, eq. 7680 bits RSA)) (Client did not present a certificate) for ; Fri, 4 Oct 2019 22:29:00 +0200 (CEST) Received: by mail-pf1-f172.google.com with SMTP id q12so4562819pff.9 for ; Fri, 04 Oct 2019 13:29:00 -0700 (PDT) X-Gm-Message-State: APjAAAW4AXGyNA57AMjLG2oxW+fpN1fvdYhmHCSvLqNwya1OkPgBQZSJ ic8pgL5yHkD97WuTnmORRjeQ8tsFdWxIaIlWryI= X-Google-Smtp-Source: APXvYqzhgR0nzpp3TOLt2+L80kTvP54q3ev9dK0XXrhxmb2vV7Ap0lg4MS8NHqTndfMzoDX835HN+TNkxVKWNmm+93M= X-Received: by 2002:a17:90a:3acf:: with SMTP id b73mr18836825pjc.88.1570220939700; Fri, 04 Oct 2019 13:28:59 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Fri, 4 Oct 2019 22:28:48 +0200 X-Gmail-Original-Message-ID: Message-ID: To: Nikita Popov Cc: PHP internals Content-Type: text/plain; charset="UTF-8" X-Envelope-From: Subject: Re: [PHP-DEV] fdiv() function From: me@kelunik.com (Niklas Keller) Hi Nikita, > The fdiv() function will perform a floating-point division while treating > division by zero as a perfectly legal operation, and will not emit any kind > of diagnostic in that case. Instead it will return the INF/-INF/NAN result > mandated by IEEE-754. It mirrors the existing fmod() function. I'd prefer floatdiv() as name matching intdiv(), but wasn't aware fmod() is already a thing. So now I think fdiv() might be the slightly more consistent name. Regards, Niklas