.TH "__gnu_cxx::char_traits< _CharT >" 3cxx "Wed Jul 28 2021" "libstdc++" \" -*- nroff -*- .ad l .nh .SH NAME __gnu_cxx::char_traits< _CharT > \- Base class used to implement std::char_traits\&. .SH SYNOPSIS .br .PP .PP Inherited by \fBstd::char_traits< _CharT >\fP\&. .SS "Public Types" .in +1c .ti -1c .RI "typedef _CharT \fBchar_type\fP" .br .ti -1c .RI "typedef \fB_Char_types\fP< _CharT >::int_type \fBint_type\fP" .br .ti -1c .RI "typedef \fB_Char_types\fP< _CharT >::off_type \fBoff_type\fP" .br .ti -1c .RI "typedef \fB_Char_types\fP< _CharT >::\fBpos_type\fP \fBpos_type\fP" .br .ti -1c .RI "typedef \fB_Char_types\fP< _CharT >::state_type \fBstate_type\fP" .br .in -1c .SS "Static Public Member Functions" .in +1c .ti -1c .RI "static constexpr void \fBassign\fP (char_type &__c1, const char_type &__c2)" .br .ti -1c .RI "static constexpr char_type * \fBassign\fP (char_type *__s, std::size_t __n, char_type __a)" .br .ti -1c .RI "static constexpr int \fBcompare\fP (const char_type *__s1, const char_type *__s2, std::size_t __n)" .br .ti -1c .RI "static constexpr char_type * \fBcopy\fP (char_type *__s1, const char_type *__s2, std::size_t __n)" .br .ti -1c .RI "static constexpr int_type \fBeof\fP ()" .br .ti -1c .RI "static constexpr bool \fBeq\fP (const char_type &__c1, const char_type &__c2)" .br .ti -1c .RI "static constexpr bool \fBeq_int_type\fP (const int_type &__c1, const int_type &__c2)" .br .ti -1c .RI "static constexpr const char_type * \fBfind\fP (const char_type *__s, std::size_t __n, const char_type &__a)" .br .ti -1c .RI "static constexpr std::size_t \fBlength\fP (const char_type *__s)" .br .ti -1c .RI "static constexpr bool \fBlt\fP (const char_type &__c1, const char_type &__c2)" .br .ti -1c .RI "static constexpr char_type * \fBmove\fP (char_type *__s1, const char_type *__s2, std::size_t __n)" .br .ti -1c .RI "static constexpr int_type \fBnot_eof\fP (const int_type &__c)" .br .ti -1c .RI "static constexpr char_type \fBto_char_type\fP (const int_type &__c)" .br .ti -1c .RI "static constexpr int_type \fBto_int_type\fP (const char_type &__c)" .br .in -1c .SH "Detailed Description" .PP .SS "template .br struct __gnu_cxx::char_traits< _CharT >" Base class used to implement std::char_traits\&. .PP \fBNote\fP .RS 4 For any given actual character type, this definition is probably wrong\&. (Most of the member functions are likely to be right, but the int_type and state_type typedefs, and the eof() member function, are likely to be wrong\&.) The reason this class exists is so users can specialize it\&. Classes in namespace std may not be specialized for fundamental types, but classes in namespace __gnu_cxx may be\&. .RE .PP See https://gcc.gnu.org/onlinedocs/libstdc++/manual/strings.html#strings.string.character_types for advice on how to make use of this class for \fIunusual\fP character types\&. Also, check out include/ext/pod_char_traits\&.h\&. .br .PP Definition at line 90 of file char_traits\&.h\&. .SH "Author" .PP Generated automatically by Doxygen for libstdc++ from the source code\&.