Return-Path: X-Original-To: apmail-commons-issues-archive@minotaur.apache.org Delivered-To: apmail-commons-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 3B18EE9C3 for ; Sat, 2 Mar 2013 16:17:14 +0000 (UTC) Received: (qmail 59144 invoked by uid 500); 2 Mar 2013 16:17:13 -0000 Delivered-To: apmail-commons-issues-archive@commons.apache.org Received: (qmail 59054 invoked by uid 500); 2 Mar 2013 16:17:13 -0000 Mailing-List: contact issues-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: issues@commons.apache.org Delivered-To: mailing list issues@commons.apache.org Received: (qmail 59030 invoked by uid 99); 2 Mar 2013 16:17:13 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 02 Mar 2013 16:17:13 +0000 Date: Sat, 2 Mar 2013 16:17:13 +0000 (UTC) From: "Thomas Neidhart (JIRA)" To: issues@commons.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (COLLECTIONS-433) TreeList.addAll() complexity MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/COLLECTIONS-433?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13591435#comment-13591435 ] Thomas Neidhart commented on COLLECTIONS-433: --------------------------------------------- Regarding the bug wrt the iterator: I tried to come up with a testcase for this bug but failed. Do you have one at hand that illustrates the problem? We should also create a separate issue for this. The patch also uses an ArrayStack, but this one will at least be deprecated for the 4.0 release if not removed completely, could you adapt the patch with a different datastructure that is available either in CC or JDK 1.5+? Thanks, Thomas > TreeList.addAll() complexity > ---------------------------- > > Key: COLLECTIONS-433 > URL: https://issues.apache.org/jira/browse/COLLECTIONS-433 > Project: Commons Collections > Issue Type: Improvement > Affects Versions: 3.2.1 > Reporter: Adrian Nistor > Attachments: COLLECTIONS-433.patch > > > "TreeList.addAll(Collection coll)" has a higher complexity than > necessary when "coll" is a "TreeList" object (because "addAll" just > adds one element at a time). This can be done in just O(N) as > described for example here: > http://stackoverflow.com/questions/4458489/merging-2-diferent-avl-trees > Are there any plans to improve this? -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira