From: Alejandro Colomar <alx@kernel.org>
To: наб <nabijaczleweli@nabijaczleweli.xyz>
Cc: linux-man@vger.kernel.org
Subject: Re: [PATCH v2] strverscmp.3: this is NOT the ordering used by ls -v
Date: Sun, 15 Dec 2024 22:44:26 +0100 [thread overview]
Message-ID: <20241215214426.bykmhqabmmy7xyi7@devuan> (raw)
In-Reply-To: <wrudkskbkovv2hll3j4mfvd3hm5e5onagijixk6ymov5maolsk@tarta.nabijaczleweli.xyz>
[-- Attachment #1: Type: text/plain, Size: 1214 bytes --]
Hi,
On Sun, Dec 15, 2024 at 10:02:42PM +0100, наб wrote:
> > Should we file a bug against glibc strverscmp(3)? We probably should.
> >
> > And the reference to sort(1), I'd put it in BUGS, saying that this API
> > is broken, and does not sort properly. Sounds good?
> No, this API works as-documented, and the implementation is useful.
What does useful mean?
> It's just not what ls -v does.
While version sort isn't something standard, I think GNU should be
self-consistent.
> @@ -44,6 +33,10 @@ .SH DESCRIPTION
> .BR LC_COLLATE ,
> so is meant mostly for situations
> where the strings are expected to be in ASCII.
> +This is different from the ordering produced by
> +.BR sort (1)
> +.BR -V .
> +.\" because it considers a-1.0.1a < a-1.0a; this is not what you want
Re: "it": sort(1) -V or strverscmp(3)?
(it's the latter, I think, but don't use "it".)
Re: "this is not what you want": Who is "you"? What is "this"? And why
does "you" not want "this"?
Please clarify.
Cheers,
Alex
> .P
> What this function does is the following.
> If both strings are equal, return 0.
> --
> 2.39.5
>
--
<https://www.alejandro-colomar.es/>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2024-12-15 21:44 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-15 20:17 [PATCH] strverscmp.3: this is NOT the ordering used by ls -v Ahelenia Ziemiańska
2024-12-15 20:43 ` Alejandro Colomar
2024-12-15 21:02 ` [PATCH v2] " наб
2024-12-15 21:44 ` Alejandro Colomar [this message]
2024-12-16 1:00 ` [PATCH v3] " наб
2024-12-16 9:57 ` Alejandro Colomar
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=20241215214426.bykmhqabmmy7xyi7@devuan \
--to=alx@kernel.org \
--cc=linux-man@vger.kernel.org \
--cc=nabijaczleweli@nabijaczleweli.xyz \
/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