This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: patch: Add test for international currency formatting
[Joseph S. Myers]
> If you're looking at strfmon in general: there are, or were, cases
> where left-justification ('-' flag) is handled improperly.
I might do that, so thanks for the references. First I will look at
the formatting of international currency, and update the currently
broken locales which are revealed when the implementation is
corrected.
> Testcases in the examples in the standard
> <http://www.opengroup.org/onlinepubs/007904975/functions/strfmon.html>
Thanks. I added the test cases to tst-fmon.data in my tree, and
discovered that the following fail (The rest are OK):
# Disable the currency symbol
en_US.ISO-8859-1 %!(#5n 123.45 123.45
en_US.ISO-8859-1 %!(#5n 3456.781 3,456.78
# Left-justify the output
en_US.ISO-8859-1 %-14#5.4n 123.45 $ 123.4500
en_US.ISO-8859-1 %-14#5.4n -123.45 -$ 123.4500
en_US.ISO-8859-1 %-14#5.4n 3456.781 $ 3,456.7810
So, I guess glibc is broken in this regard too.