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++/15276] Erroneous Comparisons of Negative Characters


------- Additional Comments From pcarlini at suse dot de  2004-05-05 17:12 -------
> One way to solve this is to provide the generic version only when you
> know that char is not unsigned -- in GCC, that is detectable with
>
>   #if !defined(__CHAR_UNSIGNED__)

Thanks for the suggestion, which, actually, I had already (only vaguely)
envisaged in my mind. As you can easily imagine, I'm not super happy with this
solution, since at run time comparing a basic_string with a basic_string, and
a basic_string with a "C"-string will be done in a way, comparing a "C"-string
with a "C"-string in another, inconsistent, way (for signed char type)

Don't you find this rather unsatisfactory?

Anyway, let's wait a bit for feedback from comp.std.c++...






-- 


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


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