On Fri, May 31, 2024, at 4:41 PM, Jorg Sowa wrote:
> Hey Saki,
> I like this change. When I was implementing additional rounding modes 
> for the next PHP version I was initially struggling with the naming and 
> this change will be helpful.
>
> I have only one concern about the names `NegativeInfinity` and 
> `PositiveInfinity`. They may be too formal from the user's perspective. 
> As we already have functions `ceil` and `floor` it's more intuitive for 
> developers to understand the logic of ceiling and floor rounding.
>
> But if voters will prefer those terms then it makes sense to change the 
> constants implemented in PHP 8.4 (and thus not released yet) from 
> `PHP_ROUND_(CEILING|FLOOR)` to 
> `PHP_ROUND_(POSITIVE_INFINITY|NEGATIVE_INFINITY)` for the sake of 
> consistency.
>
> Kind regards,
> Jorg

I was confused by those as well.  It's not obvious to me what those even do.  
Do they mean "away from 0"?  If not, then I have no clue what they are. :-)

--Larry Garfield

Reply via email to