Subject: bug#47103: numfmt: invalid suffix 'k'

From: Glenn Golden <[email-masked]>
Date: Sun, 26 Nov 2023 10:12:13 -0700

Sven Köhler <[email-masked]> [2023-11-26 17:09:23 +0100]:
> So Pádraig's patch does allow for parsing lowercase k, but it does not
> change numfmt to use lowercase k in its output in si mode.
> 
> As Pádraig has shown, ls uses lowercase k in --si mode. So it uses lowercase
> k for 1000. I think that numfmt should behave the same for consistency
> reasons.
> 
> Also, the texinfo then seems incomplete. It lists kB but not k alone, as
> used by ls in --si mode.
> 

Danger Will Robinson...  The situation w.r.t. B vs. B-less is more complicated
than that; the texinfo doc is (and has been for years) self-contradictory
regarding the semantics of B vs. B-less suffixes. It just depends which
section you happen to refer to.

This thread from a few years back lays out the B-vs.-no-B confusion in
gory detail:

    https://lists.gnu.org/archive/html/coreutils/2020-09/msg00001.html

NOTE: The above was posted in 2020 when coreutils 8.32 was current; the
texinfo sections referred to in the initial message of that thread have
changed: In particular, the section referred to in the above thread as
"Section 2.3 "Block size" is now Section 2.2 of the present (coreutils 9.4)
texinfo.

Glenn