Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:80399 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 57703 invoked from network); 12 Jan 2015 01:11:19 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 12 Jan 2015 01:11:19 -0000 Authentication-Results: pb1.pair.com header.from=pierre.php@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=pierre.php@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.215.46 as permitted sender) X-PHP-List-Original-Sender: pierre.php@gmail.com X-Host-Fingerprint: 209.85.215.46 mail-la0-f46.google.com Received: from [209.85.215.46] ([209.85.215.46:51036] helo=mail-la0-f46.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 20/A4-34383-73F13B45 for ; Sun, 11 Jan 2015 20:11:19 -0500 Received: by mail-la0-f46.google.com with SMTP id q1so21917667lam.5 for ; Sun, 11 Jan 2015 17:11:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=STnU546uXVGsKf0cS8KhrXLWJx9VgrLejJMh4gKTp5g=; b=GqS7F3Qk1uOEhU23fRthEEVQIm+zJZtDmK5ES170TGfGwNG0MKNS6/6dTzLFl8AWWq nmcLdH7rf1AMnii6q8Yv2RJf/4VkdB2wjfS89AVArdWLm45TxcXm4PfI55RA7f6+GYeu 39sPFRcqhLBIPhwfH8EwYiPZR4abnfvr0W1sd8s2CwiP0whvMn5ldvQ+eisiIWsPaxeb PPu0ONukCqyFDu93c96Nlt8Pu6gSEkjz0jK+TB+ZPg4DhTYQvUgH8Haq6NBiHxz5k7IF E89RWMgFy/0DZhVRWLsVZNdhIQDl/gPunv46eU9L8Z2MfjMxg7k+ZeTtEo6GrBg80OlK r5Dg== MIME-Version: 1.0 X-Received: by 10.152.23.98 with SMTP id l2mr33569265laf.46.1421025076441; Sun, 11 Jan 2015 17:11:16 -0800 (PST) Received: by 10.112.154.133 with HTTP; Sun, 11 Jan 2015 17:11:16 -0800 (PST) Received: by 10.112.154.133 with HTTP; Sun, 11 Jan 2015 17:11:16 -0800 (PST) In-Reply-To: <976B7B2E-7BC9-4514-ABF3-C0DA3ED98897@ajf.me> References: <54B30DB9.3000003@seld.be> <76B8D342-43E7-42E6-AD82-FCF7C5CA8658@ajf.me> <54B31D77.9010100@gmail.com> <976B7B2E-7BC9-4514-ABF3-C0DA3ED98897@ajf.me> Date: Sun, 11 Jan 2015 17:11:16 -0800 Message-ID: To: Andrea Faulds Cc: PHP internals , Yasuo Ohgaki , Jordi Boggiano , Stanislav Malyshev Content-Type: multipart/alternative; boundary=089e0158b7e4e5f74b050c6a2e85 Subject: Re: [PHP-DEV] rand(), mt_rand() and limits From: pierre.php@gmail.com (Pierre Joye) --089e0158b7e4e5f74b050c6a2e85 Content-Type: text/plain; charset=UTF-8 On Jan 12, 2015 8:08 AM, "Andrea Faulds" wrote: > > Hey Stas, > > > On 12 Jan 2015, at 01:03, Stanislav Malyshev wrote: > > > > 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. Breaking APIs means to drop functions. Functions not present anymore break codes. New implementations are fine and match the doc. > -- > Andrea Faulds > http://ajf.me/ > > > > > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > --089e0158b7e4e5f74b050c6a2e85--