Re: RFC: mt_* functions
| From: | Sterling Hughes | Date: | Sat, 04 Aug 2001 21:17:48 +0000 |
| Subject: | Re: RFC: mt_* functions | ||
| References: | 1 2 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-62091@lists.php.net to get a copy of this message | ||
At 11:15 PM 8/4/2001 +0200, Stig Sæther Bakken wrote:
[<jeroen@php.net>] Hi, Currently, the rand_functions all have mt_ clones, which use a in-PHP-implementation (Mersenne-Twister) rather than an external implementation. This is IMHO a bit strange way of chosing between implementation. My suggestion is to make it only one familiy of functions, the implementation of which is determined by an ini-entry. (rand = system vs. rand = mt, or something like that, default: mt). The functionality is the same (*), and IMO it's a per-system-decision wether you want to use the mt-algorithms or the system ones. (usually mt, unless your system has a real good / very special one) For backwards compatibility, mt_* can be aliased to their normal equivalents. Please don't. Ini settings that change semantics are a bother, and people should be able to choose their random function.+1 for the -1 (does that equal 0?) -Sterling