Hi all,

On Mon, Jan 30, 2017 at 7:54 PM, Yasuo Ohgaki <yohg...@ohgaki.net> wrote:

> On Mon, Jan 30, 2017 at 7:47 PM, Yasuo Ohgaki <yohg...@ohgaki.net> wrote:
>
>> On Mon, Jan 30, 2017 at 7:41 PM, Lauri Kenttä <lauri.ken...@gmail.com>
>> wrote:
>>
>>> On 2017-01-30 04:25, Yasuo Ohgaki wrote:
>>>
>>>> I'll prepare patch that allows int array
>>>> initialization for mt_srand() so that whole state buffer can be
>>>> initialized as user specifies.
>>>>
>>>
>>> Don't.
>>>
>>> See these:
>>> https://github.com/php/php-src/pull/2089
>>> https://www.mail-archive.com/internals@lists.php.net/msg87590.html
>>
>>
>> Nice!
>>
>> Thank you for letting me know.
>> BTW, do you have good idea for the seeding issue?
>>
>
> I got it now. Object based PRNG sounds nice. I may write it, but
> I have long todo lists already.
>
> Anyway, we have to take care existing API and make usable.
> We must have MT rand reseed API somehow.
>
> Ideas are appreciated.
>

Posting RFC draft before discussion

https://wiki.php.net/rfc/improve_predictable_prng_random

This RFC includes results of recent PRNG related discussions.
I would like to keep it simple, but basic object feature will be
implemented.

Methods could raise exceptions for invalid operations rather than ignoring.

Comments?

--
Yasuo Ohgaki
yohg...@ohgaki.net

Reply via email to