On Tue, 26 Sept 2023 at 11:10, Saki Takamachi <s...@sakiot.com> wrote:

> Hi, internals.
>
> I'm currently working on renovating the `round()` function.
>
> The current `round()` function rounds a value like 0.285 (0.28499....) to
> 0.29 using pre-round.
> This is a mistake for FP, so discussions are underway to abolish such
> pre-round behavior.
>
> However, there is definitely a user request to round 0.285 to 0.29, so I
> thought why not add a function similar to the round function to BCMath.
>
> Similarly, I'm considering adding similar functionality to `floor()` and
> `ceil()`. In rare cases, when dealing with very large values, these will
> return a different value than expected as a decimal number.
>
> I would love to hear everyone's opinions.
>

I think regardless of the issues around round(), ceil(), floor(), etc.
having the equivalent functions for BCMath makes a lot of sense to me.

Best regards,

George P. Banyard

Reply via email to