GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
deductionguidesforstd::tuple(3) C++ Standard Libary deductionguidesforstd::tuple(3)

deductionguidesforstd::tuple - deductionguidesforstd::tuple


Defined in header <tuple>
template<class... UTypes> (1) (since C++17)
tuple(UTypes...) -> tuple<UTypes...>;
template<class T1, class T2> (2) (since C++17)
tuple(std::pair<T1, T2>) -> tuple<T1, T2>;
template<class Alloc, class... UTypes> (3) (since C++17)
tuple(std::allocator_arg_t, Alloc, UTypes...) -> tuple<UTypes...>;
template<class Alloc, class T1, class T2>
tuple(std::allocator_arg_t, Alloc, std::pair<T1, T2>) -> tuple<T1, (4) (since C++17)
T2>;
template<class Alloc, class... UTypes>
tuple(std::allocator_arg_t, Alloc, tuple<UTypes...>) -> (5) (since C++17)
tuple<UTypes...>;


These deduction guides are provided for std::tuple to account for the edge cases
missed by the implicit deduction guides, in particular, non-copyable arguments and
array to pointer conversion.

// Run this code


#include <tuple>
int main()
{
int a[2], b[3], c[4];
std::tuple t1{a, b, c}; // explicit deduction guide is used in this case
}

2022.07.31 http://cppreference.com

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.