2021年9月23日(木) 2:05 Dan Ackroyd <dan...@basereality.com>:

> Go Kudo wrote:
> > Dan Ackroyd wrote:
> >> you can _simply_ include ext/random/random.h." sounds pretty
> >> dismissive of causing possibly unneeded work for downstream projects.
> >
> > The point I was trying to make was that while BC Breaks do occur, they
> are very easy to solve.
>
>
> I've found it useful to think about "value = benefit minus cost".
>
> I was calling out that it seems to be that this is a change you want
> to do for aesthetic reasons and are justifying it by trivialising the
> work involved. i.e. it has a tiny benefit that only has a positive
> value if the cost is also tiny.
>
> Although the change is simple:
>
> * Any code base that includes standard/php_rand.h won't compile, and
> people will have to find out what changed. Even though the fix may be
> easy to implement, each of those people will have to figure it out for
> themselves.
>
> * quite a few people will have to learn (or relearn) how to use #if to
> compare PHP version to include either standard/php_rand.h or
> random/php_random.h if they want their code to work on more than 1 PHP
> version.
>
> * it makes more work for downstream distributors of PHP, as their
> patches (including security patches) will need to be moved around.
>
> If there's a good reason to move stuff around, then fine, but avoiding
> creating extra work downstream is worth doing. And possibly is a hot
> topic right now.
>
> You could probably avoid a lot of downstream work by leaving a stub
> file at standard/php_rand.h that includes random/php_random.h.
>
> cheers
> Dan
> Ack
>
> btw, if you could please avoid top-posting, that would be appreciated:
> https://github.com/php/php-src/blob/master/docs/mailinglist-rules.md
>
> "Do not top post. Place your answer underneath anyone you wish to
> quote and remove any previous comment that is not relevant to your
> post."
>

I apologize for not knowing the rules of ML.
Is this correct?

It is true that it is better to maintain compatibility that can be
maintained.
However, I think this should be sorted out sometime. Perhaps it will be in
PHP 9.0.

First of all, I would like to change these RFC and implementations.

https://wiki.php.net/rfc/random_ext
https://wiki.php.net/rfc/rng_extension

Thank you.

Reply via email to