Re: [PHP-DEV] Re: [RFC] Traits with interfaces

2016-02-22 Thread Alex Bowers
Would a fair solution to this be having the using class define whether to inherit the implementations? Perhaps a new keyword akin to 'propagated', so the code will read Class Foo { Use propagated TraitName; } Only then will the implementations from that trait bubble through. If it isn't declar

Re: [PHP-DEV] PRNG: Raise warning and/or provide better pseudo random generator?

2016-02-22 Thread Yasuo Ohgaki
Hi Scott, On Tue, Feb 23, 2016 at 7:14 AM, Scott Arciszewski wrote: > Have I shared this here? > > https://github.com/paragonie/seedspring > > Warning: May summon Cthulhu if deployed to production. I didn't know at least. Nice class! -- Yasuo Ohgaki yohg...@ohgaki.net -- PHP Internals - PHP R

Re: [PHP-DEV] PRNG: Raise warning and/or provide better pseudo random generator?

2016-02-22 Thread Scott Arciszewski
On Mon, Feb 22, 2016 at 4:42 PM, Yasuo Ohgaki wrote: > Hi Andrey, > > On Tue, Feb 23, 2016 at 6:38 AM, Andrey Andreev wrote: >> On Mon, Feb 22, 2016 at 11:30 PM, Yasuo Ohgaki wrote: >>> >>> >>> IMO, we should provide better pseudo random generators than now. >> >> >> We already have a better PRN

Re: [PHP-DEV] PRNG: Raise warning and/or provide better pseudo random generator?

2016-02-22 Thread Yasuo Ohgaki
Hi Andrey, On Tue, Feb 23, 2016 at 6:38 AM, Andrey Andreev wrote: > On Mon, Feb 22, 2016 at 11:30 PM, Yasuo Ohgaki wrote: >> >> >> IMO, we should provide better pseudo random generators than now. > > > We already have a better PRNG in random_int(). randon_int() is _not_ a alternative of rand()/

Re: [PHP-DEV] PRNG: Raise warning and/or provide better pseudo random generator?

2016-02-22 Thread Andrey Andreev
Hi, On Mon, Feb 22, 2016 at 11:30 PM, Yasuo Ohgaki wrote: > > IMO, we should provide better pseudo random generators than now. > We already have a better PRNG in random_int(). Cheers, Andrey.

[PHP-DEV] PRNG: Raise warning and/or provide better pseudo random generator?

2016-02-22 Thread Yasuo Ohgaki
Hi all, We have issue on pseudo random generators generates only odd/even numbers. https://bugs.php.net/bug.php?id=63174 https://news.ycombinator.com/item?id=9941364 We should raise E_WARNING/E_NOTICE if user supplies random number range that generated random number cannot be random at least. Pa

[PHP-DEV] Re: [RFC] Traits with interfaces

2016-02-22 Thread Kevin Gessner
On Thu, Feb 18, 2016 at 4:13 PM, Kevin Gessner wrote: > On Wed, Feb 17, 2016 at 2:05 PM, Kevin Gessner wrote: > >> I've created a proper RFC wiki page here with the draft: >> https://wiki.php.net/rfc/traits-with-interfaces >> >> It includes more detail and several example code snippets. Thanks

Re: [PHP-DEV] [RFC Proposal] var keyword deprecation/removal

2016-02-22 Thread Stanislav Malyshev
Hi! > Old cellphones were shipped with a user manual that contained precise > instructions on how to deal with the installed OS. You don't really need a whole manual to know two things are the same. You only need one line from that manual. It's a minimal effort, well within expected of what may b

[PHP-DEV] UGLY Benchmark Results for PHP Master 2016-02-22

2016-02-22 Thread lp_benchmark_robot
Results for project PHP master, build date 2016-02-22 06:31:19+02:00 commit: 6ae4c11 previous commit:8b410c5 revision date: 2016-02-21 17:11:51-08:00 environment:Haswell-EP cpu:Intel(R) Xeon(R) CPU E5-2699 v3 @ 2.30GHz 2x18 cores, stepping 2, LLC 45 MB

[PHP-DEV] Re: [PHP-CVS] com php-src: Revert "Fix #71152: mt_rand()returnsthedifferent values from original mt19937ar.c":ext/standard/rand.cext/standard/tests/math/mt_rand_value.phpt

2016-02-22 Thread Tom Worster
embarrassing correction to my message: the last four words of the 2nd para here should have been at the end of the previous para. On 2/22/16 8:23 AM, Tom Worster wrote: PHP is an unlikely language for the typical programs that specifically need MT19937. I doubt we would sort out anyone's exist

[PHP-DEV] Re: [PHP-CVS] com php-src: Revert "Fix #71152: mt_rand() returnsthedifferent values from original mt19937ar.c": ext/standard/rand.cext/standard/tests/math/mt_rand_value.phpt

2016-02-22 Thread Tom Worster
I ran mt_rand() through dieharder and it appears to perform well. I put the results here: https://gist.github.com/tom--/a12175047578b3ae9ef8 On 2/19/16 8:39 PM, Andrea Faulds wrote: PHP's implementation of the Mersenne Twister algorithm is buggy, so it doesn't produce the same output as in o