This is the mail archive of the
mailing list for the libstdc++ project.
Re: Char_traits (part 2+)
"Jack Reeves" <firstname.lastname@example.org> writes:
| > The consensus seems to be that failing to provide a definition for
| > char_traits<_CharT> is strictly conforming, although not all that
| > friendly to users.
| I'm afraid that I don't see how providing a definition either without an
| implementation, or with one that generates a version that does not
| meet the requirements is any friendlier.
This is a very good argument *for* defining the primary template as
per the Standard requirement.
If your disagree with the Standard requirements, I think a better
place is to fill a Defect Report.
| Any attempt by users, no matter how they go about it, is undefined behavior.
True, but "undefined behaviour" is also a freedom for us to choose to define
that behaviour by allowing users to do the thing the standard poses no
| I can not really address it yet because I have not investigated it enough.
| suggestion that the library implementation should ignore the
Since CharT is a POD, the copy-and-assignment operator can certainly
provide a general definition for char_traits<>assign.