From: Junio C Hamano <gitster@pobox.com>
To: David Kastrup <dak@gnu.org>
Cc: Alex Riesen <raa.lkml@gmail.com>,
martin f krafft <madduck@madduck.net>,
git discussion list <git@vger.kernel.org>,
439992-quiet@bugs.debian.org
Subject: Re: [PATCH] Remove duplicate pathspecs from ls-files command line
Date: Wed, 29 Aug 2007 18:25:50 -0700 [thread overview]
Message-ID: <7vr6llak4h.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <85tzqic9bf.fsf@lola.goethe.zz> (David Kastrup's message of "Wed, 29 Aug 2007 23:36:20 +0200")
David Kastrup <dak@gnu.org> writes:
> Does anything speak against sorting the pathspecs? That is an O(n log
> n) operation,
Not sorting is O(0) operation without losing cycles for the
normal case. I think you can sort first in that error handling
path to avoid O(n^2) but sorting upfront to remove duplicates
for every case is unnecessary bloat that penalizes sane callers.
next prev parent reply other threads:[~2007-08-30 1:26 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-29 8:11 double occurrence of filenames on command lines martin f krafft
2007-08-29 19:44 ` [PATCH] Remove duplicate pathspecs from ls-files command line Alex Riesen
2007-08-29 20:44 ` Junio C Hamano
2007-08-29 21:04 ` martin f krafft
2007-08-29 21:15 ` Alex Riesen
2007-08-29 21:36 ` David Kastrup
2007-08-30 1:25 ` Junio C Hamano [this message]
2007-08-30 5:52 ` David Kastrup
2007-08-29 20:57 ` martin f krafft
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7vr6llak4h.fsf@gitster.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=439992-quiet@bugs.debian.org \
--cc=dak@gnu.org \
--cc=git@vger.kernel.org \
--cc=madduck@madduck.net \
--cc=raa.lkml@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox