Title
Equivalent of %'d, or rather, lack thereof?
Status
nad
Section
[locale.nm.put]
Submitter
Peter Dimov

Created on 2008-04-07.00:00:00 last changed 164 months ago

Messages

Date: 2010-10-21.18:28:33

[ Sophia Antipolis: ]

This is not a part of C99. LWG suggests submitting a paper may be appropriate.

Date: 2010-10-21.18:28:33

[ Martin Sebor: ]

I don't know if it qualifies as a defect but I agree that there should be an easy way to control whether the thousands separator should or shouldn't be inserted. A new flag would be in line with the current design of iostreams (like boolalpha, showpos, or showbase).

Date: 2010-10-21.18:28:33

[ Pablo Halpern: ]

I'm not sure it constitutes a defect, but I would be in favor of adding another flag (and corresponding manipulator).

Date: 2008-04-07.00:00:00

In the spirit of printf vs iostream...

POSIX printf says that %'d should insert grouping characters (and the implication is that in the absence of ' no grouping characters are inserted). The num_put facet, on the other hand, seems to always insert grouping characters. Can this be considered a defect worth fixing for C++0x? Maybe ios_base needs an additional flag?

History
Date User Action Args
2010-10-21 18:28:33adminsetmessages: + msg3941
2010-10-21 18:28:33adminsetmessages: + msg3940
2010-10-21 18:28:33adminsetmessages: + msg3939
2008-04-07 00:00:00admincreate