1 //===----------------------------------------------------------------------===//
3 // The LLVM Compiler Infrastructure
5 // This file is dual licensed under the MIT and the University of Illinois Open
6 // Source Licenses. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
12 // template <class T1, class T2> struct pair
14 // pair(const T1& x, const T2& y);
23 A(int data) : data_(data) {}
25 bool operator==(const A& a) const {return data_ == a.data_;}
31 typedef std::pair<float, short*> P;
33 assert(p.first == 3.5f);
34 assert(p.second == nullptr);
37 typedef std::pair<A, int> P;
39 assert(p.first == A(1));
40 assert(p.second == 2);