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
- From: "Joseph S. Myers" <jsm28 at cam dot ac dot uk>
- To: Petter Reinholdtsen <pere at hungry dot com>
- Cc: libc-alpha at sources dot redhat dot com
- Date: Sat, 21 Jun 2003 17:10:48 +0100 (BST)
- Subject: Re: patch: Add test for international currency formatting
- References: <E19ThdX-0007uw-00@minerva.hungry.com>
On Sat, 21 Jun 2003, Petter Reinholdtsen wrote:
> The current formatting of international currency is broken. Here is a
> test case demonstrating the current output. My next step is to change
> stdlib/strfmon.c to produce the correct result, and update the test
> case to demonstrate it.
If you're looking at strfmon in general: there are, or were, cases where
left-justification ('-' flag) is handled improperly. (Some Austin Group
drafts were unclear in the specification; I submitted reports of the
problem with the drafts and the specification was clarified to follow the
cleaner interpretation of Solaris rather than that of glibc. I don't
think glibc has subsequently been fixed to follow the specification. The
drafts used to say "all fields are left-justified" and this was fixed to
"the result of the conversion is left-justified", and it is now specified
that this flag is ignored unless a field width is specified. Testcases in
the examples in the standard
<http://www.opengroup.org/onlinepubs/007904975/functions/strfmon.html> and
in the original Austin Group comments
<http://www.opengroup.org/austin/docs/austin_77r2.txt>.)
--
Joseph S. Myers
jsm28@cam.ac.uk