std::basic_streambuf::setp

void setp( char_type* pbeg, char_type* pend ); Sets the values of the pointers defining the put area. Specifically, after the call pbase() == pbeg, pptr() == pbeg, epptr() == pend. Parameters pbeg - pointer to the new beginning of the put area pend - pointer to the new end of the put area Return value (none). Example #include <iostream> #include <array> // Buffer for std::ostream implemented by std::array template<std::size_t SIZE, class CharT =

requires

Usage in a function or function template declaration, specifies an associated constraint (concepts TS) specifies an constant expression on template parameters that evaluates a requirement(concepts TS)

std::basic_string::front

CharT& front(); (since C++11) const CharT& front() const; (since C++11) Returns reference to the first character in the string. The behavior is undefined if empty() == true. Parameters (none). Return value reference to the first character, equivalent to operator[](0). Complexity Constant. Example #include <iostream> #include <string> int main() { { std::string s("Exemplary"); char& f = s.front(); f = 'e'; std::cout <<

Error numbers

Each of the macros defined in <cerrno> expands to integer constant expressions with type int, each with a positive value, matching most of the POSIX error codes. The following constants are defined (the implementation may define more, as long as they begin with 'E' followed by digits or uppercase letters). Defined in header <cerrno> E2BIG (C++11) Argument list too long (macro constant) EACCES (C++11) Permission denied (macro constant) EADDRINUSE (C++11) Address i

std::promise::promise

promise(); (1) (since C++11) template< class Alloc > promise( std::allocator_arg_t, const Alloc& alloc ); (2) (since C++11) promise( promise&& other ); (3) (since C++11) promise( const promise& other ) = delete; (4) (since C++11) Constructs a promise object. 1) Default constructor. Constructs the promise with an empty shared state. 2) Constructs the promise with an empty shared state. The shared state is allocated using alloc. Alloc must meet th

std::array::fill

void fill( const T& value ); (since C++11) Assigns the given value value to all elements in the container. Parameters value - the value to assign to the elements Return value (none). Complexity Linear in the size of the container.

std::domain_error

Defined in header <stdexcept> class domain_error; Defines a type of object to be thrown as exception. It may be used by the implementation to report domain errors, that is, situations where the inputs are outside of the domain on which an operation is defined. The standard library components do not throw this exception (mathematical functions report domain errors as specified in math_errhandling). Third-party libraries, however, use this. For example, boost.math throws std:

std::ratio_greater_equal

Defined in header <ratio> template< class R1, class R2 > struct ratio_greater_equal : std::integral_constant; If the ratio R1 is greater than or equal to the ratio R2, provides the member constant value equal true. Otherwise, value is false. Helper variable template template< class R1, class R2 > constexpr bool ratio_greater_equal_v = ratio_greater_equal<R1, R2>::value; (since C++17) Inherited from std::integral_constant Member constants

std::shared_future::wait

void wait() const; (since C++11) Blocks until the result becomes available. valid() == true after the call. The behavior is undefined if valid()== false before the call to this function. Parameters (none). Return value (none). Exceptions (none). Notes The implementations are encouraged to detect the case when valid == false before the call and throw a std::future_error with an error condition of std::future_errc::no_state. Calling wait on the same std::shared_future from mul

std::uniform_real_distribution::a

result_type a() const; (1) (since C++11) result_type b() const; (2) (since C++11) Returns the parameters the distribution has been constructed with. 1) Returns the a distribution parameter. It defines the minimum possibly generated value. The default value is 0.0. 2) Returns the b distribution parameter. It defines the maximum possibly generated value. The default value is 1.0 Parameters (none). Return value 1) The a distribution parameter. 2) The b distribution paramet