LibreOffice Module onlineupdate (master) 1
|
MakeUnsigned produces the corresponding unsigned integer type for a given integral type T, with the const/volatile qualifiers of T. More...
#include <TypeTraits.h>
MakeUnsigned produces the corresponding unsigned integer type for a given integral type T, with the const/volatile qualifiers of T.
T must be a possibly-const/volatile-qualified integral type that isn't bool.
If T is already an unsigned integer type (not including char!), then T is produced.
Otherwise, if T is a signed integer type, the unsigned variety of T, with T's const/volatile qualifiers, is produced.
Otherwise, the unsigned integral type of the same size as T, with the lowest rank, with T's const/volatile qualifiers, is produced. (This basically only acts to produce unsigned char when T = char.)
mozilla::MakeUnsigned<signed long>::Type is unsigned long; mozilla::MakeUnsigned<volatile unsigned int>::Type is volatile unsigned int; mozilla::MakeUnsigned<const signed short>::Type is const unsigned short; mozilla::MakeUnsigned<const char>::Type is const unsigned char; mozilla::MakeUnsigned<bool> is an error; mozilla::MakeUnsigned<void*> is an error.
Definition at line 992 of file TypeTraits.h.