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// <stack>
10
11// ~stack() // implied noexcept;
12
13// UNSUPPORTED: c++03
14
15#include <stack>
16#include <cassert>
17
18#include "test_macros.h"
19#include "MoveOnly.h"
20
21int main(int, char**)
22{
23 {
24 typedef std::stack<MoveOnly> C;
25 static_assert(std::is_nothrow_destructible<C>::value, "");
26 }
27
28 return 0;
29}
30

source code of libcxx/test/std/containers/container.adaptors/stack/stack.cons/dtor_noexcept.pass.cpp