This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libstdc++/11740] ctype<wchar_t>::do_is(mask, wchar_t) doesn't handle multiple bits in mask.


PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11740



------- Additional Comments From paolo at gcc dot gnu dot org  2003-10-06 19:13 -------
Pétur wrote:
>> This is the rationale: a character *cannot* belong simultaneously to
>> two different values of the ctype_base enum:
>
>It can, for example alpha and upper.

Yes, sorry.

>> That's why do_is must be intended to mean "any".
>
>The only use for this feature that I see is to be able to use
>alnum and graph. ct.is(alnum, c) should return true if c if either
>ct.is(digit, c) is true or ct.is(alpha, c) is true. I can't think of
>any character for which both are true.

Ok. This is the point at the root of my (too general) intuition.

Now... If I understand well you see an inconsistency in the standard
between 22.2.1.1.2 (which we already correctly implement as per your
previous message) and the definitions of alnum == alpha | digit and
graph == alnum | punct, right?


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]