> On 22 Nov 2021, at 11:32 PM, Nils Adermann wrote:
>
> On 22.11.21 23:07, Kim Hallberg wrote:
>>
>>> On 22 Nov 2021, at 10:53 PM, Sara Golemon wrote:
>>>
>>> Now that the new PHP Foundation has been announced, I've been asked if we'd
>>>
> On 22 Nov 2021, at 10:53 PM, Sara Golemon wrote:
>
> Now that the new PHP Foundation has been announced, I've been asked if we'd
> mind configuring a Sponsor button on our github.com project profile.
>
> On 23 Jun 2021, at 8:42 PM, Kim Hallberg wrote:
>
> Hello internals,
>
> The RFC for the clamp function is now open and under discussion, you now have
> 2 weeks
> to discuss, suggest improvements and open issues before voting is considered.
>
> Any a
> On 23 Jun 2021, at 8:42 PM, Kim Hallberg wrote:
>
> Hello internals,
>
> The RFC for the clamp function is now open and under discussion, you now have
> 2 weeks
> to discuss, suggest improvements and open issues before voting is considered.
>
> Any a
> On 28 Jun 2021, at 11:16 AM, Nikita Popov wrote:
>
> The RFC is missing a precise description of how this function works with NaN
> and negative zero. The expected behavior is that if min or max are NaN, an
> exception is thrown, if num if NaN then NaN is returned, and the behavior wrt
>
> On 24 Jun 2021, at 1:50 AM, tyson andre wrote:
>
> So I think the major objections are that:
>
> 1. This is easy to implement in userland and there's negligible performance
> benefit
> (in code that is a performance sensitive loop, it may still be worse
> compared to `$num < $min ? $min :
tps://wiki.php.net/rfc/clamp>
The implementation is available in a PR here:
https://github.com/php/php-src/pull/7191
<https://github.com/php/php-src/pull/7191>
Thank you,
Kim Hallberg
Hi internals,
With the initial attitude for the clamp proposal being mostly positive
I am moving ahead with the RFC and am therefore requesting RFC karma
to create this RFC.
If anyone would like to grant me this karma my username for the wiki is:
thinkverse
Thank you,
Kim Hallberg.
--
PHP
> On 23 Jun 2021, at 2:25 AM, Kim Hallberg wrote:
>
> Greetings internals,
>
> I present to you a proposal for a new basic math function: clamp.
>
> function clamp(int|float $num, int|float $min, int|float $max): int|float {}
Instead of answering each response i
since the function cannot be
redeclared.
I've implemented this feature a few months ago already.
- Link: https://github.com/thinkverse/php-src/pull/1
<https://github.com/thinkverse/php-src/pull/1>
What are your opinions on this function?
Regards,
Kim Hallberg.
10 matches
Mail list logo