std::collate::compare

Defined in header <locale> public: int compare( const CharT* low1, const CharT* high1, const CharT* low2, const CharT* high2 ) const; (1) protected: virtual int do_compare( const CharT* low1, const CharT* high1, const CharT* low2, const CharT* high2 ) const; (2) 1) Public member function, calls the protected virtual member function do_compare of the most derived class. 2) Compares the character sequence [low1, high1) to the chara

typeid

Usage typeid operator

std::numeric_limits::digits10

static const int digits10; (until C++11) static constexpr int digits10 (since C++11) The value of std::numeric_limits<T>::digits10 is the number of base-10 digits that can be represented by the type T without change, that is, any number with this many decimal digits can be converted to a value of type T and back to decimal form, without change due to rounding or overflow. For base-radix types, it is the value of digits (digits-1 for floating-point types) multiplied by log10(

std::list::empty

bool empty() const; Checks if the container has no elements, i.e. whether begin() == end(). Parameters (none). Return value true if the container is empty, false otherwise. Exceptions (none) (until C++11) noexcept specification: noexcept (since C++11) Complexity Constant. Example The following code uses empty to check if a std::list<int> contains any elements: #include <list> #include <iostream> int main() { std::list<int> numbers; s

std::stack::stack

(1) explicit stack( const Container& cont = Container() ); (until C++11) explicit stack( const Container& cont ); (since C++11) explicit stack( Container&& cont = Container() ); (2) (since C++11) stack( const stack& other ); (3) stack( stack&& other ); (4) (since C++11) template< class Alloc > explicit stack( const Alloc& alloc ); (5) (since C++11) template< class Alloc > stack( const Container& cont, const A

std::is_destructible

Defined in header <type_traits> template< class T > struct is_destructible; (1) (since C++11) template< class T > struct is_trivially_destructible; (2) (since C++11) template< class T > struct is_nothrow_destructible; (3) (since C++11) 1) If an imaginary struct containing a member object of type T has a non-deleted destructor, provides the member constant value equal true. For any other type, value is false. (until C++14) 1) If T is a refere

std::iswupper

Defined in header <cwctype> int iswupper( std::wint_t ch ); Checks if the given wide character is an uppercase letter, i.e. one of ABCDEFGHIJKLMNOPQRSTUVWXYZ or any uppercase letter specific to the current locale. Parameters ch - wide character Return value Non-zero value if the wide character is an uppercase letter, zero otherwise. Example #include <iostream> #include <cwctype> #include <clocale> int main() { wchar_t c = L'\u053d'

std::unordered_map::max_load_factor

float max_load_factor() const; (1) (since C++11) void max_load_factor( float ml ); (2) (since C++11) Manages the maximum load factor (number of elements per bucket). The container automatically increases the number of buckets if the load factor exceeds this threshold. 1) Returns current maximum load factor. 2) Sets the maximum load factor to ml. Parameters ml - new maximum load factor setting Return value 1) current maximum load factor. 2) none. Complexity Constan

std::wctomb

Defined in header <cstdlib> int wctomb( char *s, wchar_t wc ); Converts a wide character wc to multibyte encoding and stores it (including any shift sequences) in the char array whose first element is pointed to by s. No more than MB_CUR_MAX characters are stored. If wc is the null character, the null byte is written to s, preceded by any shift sequences necessary to restore the initial shift state. If s is a null pointer, resets the global conversion state and determines w

ATOMIC_FLAG_INIT

Defined in header <atomic> #define ATOMIC_FLAG_INIT /* implementation-defined */ Defines the expression which can be used to initialize std::atomic_flag to clear (false) state with the statement std::atomic_flag v = ATOMIC_FLAG_INIT;. It is unspecified if it can be used with other initialization contexts. If the flag has static storage duration, this initialization is static. This is the only way to initialize std::atomic_flag to a definite value: the value held after any o