[NFC][Py Reformat] Reformat python files in libcxx/libcxxabi
[llvm-project.git] / libcxx / test / support / test.workarounds / c1xx_broken_is_trivially_copyable.pass.cpp
blobec85bdce27db62ef5fbc5f48f868bbd9c412fe6c
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 // UNSUPPORTED: c++03
11 // Verify TEST_WORKAROUND_MSVC_BROKEN_IS_TRIVIALLY_COPYABLE.
13 #include <type_traits>
15 #include "test_macros.h"
16 #include "test_workarounds.h"
18 struct S {
19 S(S const&) = default;
20 S(S&&) = default;
21 S& operator=(S const&) = delete;
22 S& operator=(S&&) = delete;
25 int main(int, char**) {
26 #ifdef TEST_WORKAROUND_MSVC_BROKEN_IS_TRIVIALLY_COPYABLE
27 static_assert(!std::is_trivially_copyable<S>::value, "");
28 #else
29 static_assert(std::is_trivially_copyable<S>::value, "");
30 #endif
32 return 0;