Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / libcxx / test / std / containers / container.adaptors / stack / stack.cons / move_assign_noexcept.pass.cpp
blobd4da48e835dc453f99aa446d7e957e846b7c621f
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 // <stack>
11 // stack& operator=(stack&& c)
12 // noexcept(is_nothrow_move_assignable<container_type>::value);
14 // This tests a conforming extension
16 // UNSUPPORTED: c++03
18 #include <stack>
19 #include <cassert>
21 #include "test_macros.h"
22 #include "MoveOnly.h"
24 int main(int, char**)
27 typedef std::stack<MoveOnly> C;
28 static_assert(std::is_nothrow_move_assignable<C>::value, "");
31 return 0;