Return-Path: Delivered-To: apmail-harmony-commits-archive@www.apache.org Received: (qmail 5541 invoked from network); 27 Aug 2009 23:51:21 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 27 Aug 2009 23:51:21 -0000 Received: (qmail 46797 invoked by uid 500); 27 Aug 2009 23:51:21 -0000 Delivered-To: apmail-harmony-commits-archive@harmony.apache.org Received: (qmail 46736 invoked by uid 500); 27 Aug 2009 23:51:20 -0000 Mailing-List: contact commits-help@harmony.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@harmony.apache.org Delivered-To: mailing list commits@harmony.apache.org Received: (qmail 46727 invoked by uid 99); 27 Aug 2009 23:51:20 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 27 Aug 2009 23:51:20 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 27 Aug 2009 23:51:19 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 45CD0234C044 for ; Thu, 27 Aug 2009 16:50:59 -0700 (PDT) Message-ID: <1133773076.1251417059271.JavaMail.jira@brutus> Date: Thu, 27 Aug 2009 16:50:59 -0700 (PDT) From: "Jesse Wilson (JIRA)" To: commits@harmony.apache.org Subject: [jira] Updated: (HARMONY-6323) Simplify and speed-up shuffle, add a non-probabilistic test In-Reply-To: <1769229822.1251416939245.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HARMONY-6323?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Jesse Wilson updated HARMONY-6323: ---------------------------------- Attachment: Shuffle-fixes.patch > Simplify and speed-up shuffle, add a non-probabilistic test > ----------------------------------------------------------- > > Key: HARMONY-6323 > URL: https://issues.apache.org/jira/browse/HARMONY-6323 > Project: Harmony > Issue Type: Improvement > Components: Classlib > Environment: SVN Revision 801399 > Reporter: Jesse Wilson > Attachments: Shuffle-fixes.patch > > Original Estimate: 0.25h > Remaining Estimate: 0.25h > > Shuffle needlessly tests Random.nextInt() for a negative value > It iterates from index N-1 to 0, which means it always swaps index 0 with itself needlessly. > It is only tested with probabilistic tests, the patch adds a proper test. Note that the attached test also passes on the RI. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.