Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:80398 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 56221 invoked from network); 12 Jan 2015 01:08:15 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 12 Jan 2015 01:08:15 -0000 Authentication-Results: pb1.pair.com smtp.mail=ajf@ajf.me; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=ajf@ajf.me; sender-id=pass Received-SPF: pass (pb1.pair.com: domain ajf.me designates 192.64.116.199 as permitted sender) X-PHP-List-Original-Sender: ajf@ajf.me X-Host-Fingerprint: 192.64.116.199 imap11-2.ox.privateemail.com Received: from [192.64.116.199] ([192.64.116.199:52629] helo=imap11-2.ox.privateemail.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id FA/44-34383-F7E13B45 for ; Sun, 11 Jan 2015 20:08:15 -0500 Received: from localhost (localhost [127.0.0.1]) by mail.privateemail.com (Postfix) with ESMTP id E37A48800E5; Sun, 11 Jan 2015 20:08:12 -0500 (EST) X-Virus-Scanned: Debian amavisd-new at imap11.ox.privateemail.com Received: from mail.privateemail.com ([127.0.0.1]) by localhost (imap11.ox.privateemail.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id yxUqfROgcGWC; Sun, 11 Jan 2015 20:08:12 -0500 (EST) Received: from oa-res-26-240.wireless.abdn.ac.uk (oa-res-26-240.wireless.abdn.ac.uk [137.50.26.240]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.privateemail.com (Postfix) with ESMTPSA id 2C2588800E2; Sun, 11 Jan 2015 20:08:12 -0500 (EST) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 8.1 \(1993\)) In-Reply-To: <54B31D77.9010100@gmail.com> Date: Mon, 12 Jan 2015 01:08:10 +0000 Cc: Jordi Boggiano , Yasuo Ohgaki , PHP Internals List Content-Transfer-Encoding: quoted-printable Message-ID: <976B7B2E-7BC9-4514-ABF3-C0DA3ED98897@ajf.me> References: <54B30DB9.3000003@seld.be> <76B8D342-43E7-42E6-AD82-FCF7C5CA8658@ajf.me> <54B31D77.9010100@gmail.com> To: Stanislav Malyshev X-Mailer: Apple Mail (2.1993) Subject: Re: [PHP-DEV] rand(), mt_rand() and limits From: ajf@ajf.me (Andrea Faulds) Hey Stas, > On 12 Jan 2015, at 01:03, Stanislav Malyshev = wrote: >=20 > Having new, better API is fine. Breaking existing working code because > new, better API is possible, is not fine. The manual explicitly guarantees that code should not rely on the random = number generator being predictable. If people want their existing code to continue to work, we could of = course allow this new API to support the C stdlib rand() as an algorithm = for BC reasons. But such code was never supposed to work in this first = place. -- Andrea Faulds http://ajf.me/