std::piecewise_construct_t (3) - Linux Manuals
std::piecewise_construct_t: std::piecewise_construct_t
NAME
std::piecewise_construct_t - std::piecewise_construct_t
Synopsis
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
Defined in header <utility>
struct piecewise_construct_t { };                                              (since C++11)
 
struct piecewise_construct_t { explicit piecewise_construct_t() = default; };  (since C++17)
std::piecewise_construct_t is an empty struct tag type used to disambiguate between different functions that take two tuple arguments.
The overloads that do not use std::piecewise_construct_t assume that each tuple argument becomes the element of a pair. The overloads that use std::piecewise_construct_t assume that each tuple argument is used to construct, piecewise, a new object of specified type, which will become the element of the pair.
Example
// Run this code
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 Output:
 
 
 
 See also
piecewise_construct an object of type piecewise_construct_t used to disambiguate functions for piecewise construction
 
(C++11)
 
constructor         (public member function of std::pair<T1,T2>)