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 | //===----------------------------------------------------------------------===// |
8 | |
9 | // UNSUPPORTED: c++03 |
10 | |
11 | // <queue> |
12 | |
13 | // queue() |
14 | // noexcept(is_nothrow_default_constructible<container_type>::value); |
15 | |
16 | // This tests a conforming extension |
17 | |
18 | #include <queue> |
19 | #include <cassert> |
20 | |
21 | #include "test_macros.h" |
22 | #include "MoveOnly.h" |
23 | |
24 | int main(int, char**) |
25 | { |
26 | #if defined(_LIBCPP_VERSION) |
27 | { |
28 | typedef std::queue<MoveOnly> C; |
29 | static_assert(std::is_nothrow_default_constructible<C>::value, "" ); |
30 | } |
31 | #endif |
32 | |
33 | return 0; |
34 | } |
35 | |