Kommentar
Åtkomst till den här sidan kräver auktorisering. Du kan prova att logga in eller ändra kataloger.
Åtkomst till den här sidan kräver auktorisering. Du kan prova att ändra kataloger.
The type of the wrapped reference.
typedef Ty type;
Remarks
The typedef is a synonym for the template argument Ty.
Example
// std_tr1__functional__reference_wrapper_type.cpp
// compile with: /EHsc
#include <functional>
#include <iostream>
int neg(int val)
{
return (-val);
}
int main()
{
int i = 1;
typedef std::reference_wrapper<int> Mywrapper;
Mywrapper rwi(i);
Mywrapper::type val = rwi.get();
std::cout << "i = " << i << std::endl;
std::cout << "rwi = " << val << std::endl;
return (0);
}
i = 1 rwi = 1
Requirements
Header: <functional>
Namespace: std