unordered_set 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. // -*- C++ -*-
  2. //===----------------------------------------------------------------------===//
  3. //
  4. // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
  5. // See https://llvm.org/LICENSE.txt for license information.
  6. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  7. //
  8. //===----------------------------------------------------------------------===//
  9. #ifndef _LIBCPP_EXPERIMENTAL_UNORDERED_SET
  10. #define _LIBCPP_EXPERIMENTAL_UNORDERED_SET
  11. /*
  12. experimental/unordered_set synopsis
  13. // C++1z
  14. namespace std {
  15. namespace experimental {
  16. inline namespace fundamentals_v1 {
  17. namespace pmr {
  18. template <class T, class Hash = hash<T>, class Pred = equal_to<T>>
  19. using unordered_set = std::unordered_set<T, Hash, Pred,
  20. polymorphic_allocator<T>>;
  21. template <class T, class Hash = hash<T>, class Pred = equal_to<T>>
  22. using unordered_multiset = std::unordered_multiset<T, Hash, Pred,
  23. polymorphic_allocator<T>>;
  24. } // namespace pmr
  25. } // namespace fundamentals_v1
  26. } // namespace experimental
  27. } // namespace std
  28. */
  29. #include <experimental/__config>
  30. #include <experimental/memory_resource>
  31. #include <unordered_set>
  32. #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
  33. # pragma GCC system_header
  34. #endif
  35. _LIBCPP_BEGIN_NAMESPACE_LFTS_PMR
  36. template <class _Value,
  37. class _Hash = hash<_Value>, class _Pred = equal_to<_Value>>
  38. using unordered_set = _VSTD::unordered_set<_Value, _Hash, _Pred,
  39. polymorphic_allocator<_Value>>;
  40. template <class _Value,
  41. class _Hash = hash<_Value>, class _Pred = equal_to<_Value>>
  42. using unordered_multiset = _VSTD::unordered_multiset<_Value, _Hash, _Pred,
  43. polymorphic_allocator<_Value>>;
  44. _LIBCPP_END_NAMESPACE_LFTS_PMR
  45. #endif /* _LIBCPP_EXPERIMENTAL_UNORDERED_SET */