Section: 126.96.36.199.2 [locale.ctype.virtuals] Status: CD1 Submitter: Martin Sebor Opened: 2002-09-06 Last modified: 2016-02-10
Priority: Not Prioritized
View all other issues in [locale.ctype.virtuals].
View all issues with CD1 status.
The last sentence in 188.8.131.52.2, p11 below doesn't seem to make sense.
charT do_widen (char c) const; -11- Effects: Applies the simplest reasonable transformation from a char value or sequence of char values to the corresponding charT value or values. The only characters for which unique transformations are required are those in the basic source character set (2.2). For any named ctype category with a ctype<charT> facet ctw and valid ctype_base::mask value M (is(M, c) || !ctw.is(M, do_widen(c))) is true.
Shouldn't the last sentence instead read
For any named ctype category with a ctype<char> facet ctc and valid ctype_base::mask value M (ctc.is(M, c) || !is(M, do_widen(c))) is true.
I.e., if the narrow character c is not a member of a class of characters then neither is the widened form of c. (To paraphrase footnote 224.)
Replace the last sentence of 184.108.40.206.2 [locale.ctype.virtuals], p11 with the following text:
For any named ctype category with a ctype<char> facet ctc and valid ctype_base::mask value M, (ctc.is(M, c) || !is(M, do_widen(c))) is true.
[Kona: Minor edit. Added a comma after the M for clarity.]
The LWG believes this is just a typo, and that this is the correct fix.