Revert "[libc] Use best-fit binary trie to make malloc logarithmic" (#117065)
[llvm-project.git] / libcxx / include / __fwd / tuple.h
blob2ed32bc0df4e14929e51667769ba28d76abdb0d1
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 #ifndef _LIBCPP___FWD_TUPLE_H
10 #define _LIBCPP___FWD_TUPLE_H
12 #include <__config>
13 #include <__cstddef/size_t.h>
15 #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
16 # pragma GCC system_header
17 #endif
19 _LIBCPP_BEGIN_NAMESPACE_STD
21 template <size_t, class>
22 struct _LIBCPP_TEMPLATE_VIS tuple_element;
24 #ifndef _LIBCPP_CXX03_LANG
26 template <class...>
27 class _LIBCPP_TEMPLATE_VIS tuple;
29 template <class>
30 struct _LIBCPP_TEMPLATE_VIS tuple_size;
32 template <size_t _Ip, class... _Tp>
33 _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX14 typename tuple_element<_Ip, tuple<_Tp...> >::type&
34 get(tuple<_Tp...>&) _NOEXCEPT;
36 template <size_t _Ip, class... _Tp>
37 _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX14 const typename tuple_element<_Ip, tuple<_Tp...> >::type&
38 get(const tuple<_Tp...>&) _NOEXCEPT;
40 template <size_t _Ip, class... _Tp>
41 _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX14 typename tuple_element<_Ip, tuple<_Tp...> >::type&&
42 get(tuple<_Tp...>&&) _NOEXCEPT;
44 template <size_t _Ip, class... _Tp>
45 _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX14 const typename tuple_element<_Ip, tuple<_Tp...> >::type&&
46 get(const tuple<_Tp...>&&) _NOEXCEPT;
48 #endif // _LIBCPP_CXX03_LANG
50 _LIBCPP_END_NAMESPACE_STD
52 #endif // _LIBCPP___FWD_TUPLE_H