We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 58dd3ed commit 67baf5eCopy full SHA for 67baf5e
libcxx/test/std/atomics/atomics.types.generic/trivially_copyable.verify.cpp
@@ -20,12 +20,13 @@
20
#include <atomic>
21
22
struct NotTriviallyCopyable {
23
- explicit NotTriviallyCopyable(int i) : i_(i) { }
24
- NotTriviallyCopyable(const NotTriviallyCopyable &rhs) : i_(rhs.i_) { }
+ explicit NotTriviallyCopyable(int i) : i_(i) {}
+ NotTriviallyCopyable(const NotTriviallyCopyable& rhs) : i_(rhs.i_) {}
25
int i_;
26
};
27
28
void f() {
29
NotTriviallyCopyable x(42);
30
- std::atomic<NotTriviallyCopyable> a(x); // expected-error@*:* {{std::atomic<T> requires that 'T' be a trivially copyable type}}
+ std::atomic<NotTriviallyCopyable> a(
31
+ x); // expected-error@*:* {{std::atomic<T> requires that 'T' be a trivially copyable type}}
32
}
0 commit comments