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 // ~unordered_multiset() // implied noexcept;
14 #include <unordered_set>
18 #include "test_allocator.h"
20 #if __has_feature(cxx_noexcept)
26 ~some_comp() noexcept(false);
34 some_hash(const some_hash&);
35 ~some_hash() noexcept(false);
42 #if __has_feature(cxx_noexcept)
44 typedef std::unordered_multiset<MoveOnly> C;
45 static_assert(std::is_nothrow_destructible<C>::value, "");
48 typedef std::unordered_multiset<MoveOnly, std::hash<MoveOnly>,
49 std::equal_to<MoveOnly>, test_allocator<MoveOnly>> C;
50 static_assert(std::is_nothrow_destructible<C>::value, "");
53 typedef std::unordered_multiset<MoveOnly, std::hash<MoveOnly>,
54 std::equal_to<MoveOnly>, other_allocator<MoveOnly>> C;
55 static_assert(std::is_nothrow_destructible<C>::value, "");
58 typedef std::unordered_multiset<MoveOnly, some_hash<MoveOnly>> C;
59 static_assert(!std::is_nothrow_destructible<C>::value, "");
62 typedef std::unordered_multiset<MoveOnly, std::hash<MoveOnly>,
63 some_comp<MoveOnly>> C;
64 static_assert(!std::is_nothrow_destructible<C>::value, "");