Revert "[libc] Use best-fit binary trie to make malloc logarithmic" (#117065)
[llvm-project.git] / libcxx / test / std / utilities / utility / pairs / pair.astuple / tuple_size.pass.cpp
blob104f89811086aaf83e5b7ed55a4468119685b435
1 //===----------------------------------------------------------------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
9 // <utility>
11 // template <class T1, class T2> struct pair
13 // tuple_size<pair<T1, T2> >::value
15 #include <utility>
17 #include "test_macros.h"
19 int main(int, char**)
22 typedef std::pair<int, short> P1;
23 static_assert((std::tuple_size<P1>::value == 2), "");
26 typedef std::pair<int, short> const P1;
27 static_assert((std::tuple_size<P1>::value == 2), "");
30 typedef std::pair<int, short> volatile P1;
31 static_assert((std::tuple_size<P1>::value == 2), "");
34 typedef std::pair<int, short> const volatile P1;
35 static_assert((std::tuple_size<P1>::value == 2), "");
38 return 0;