diff options
Diffstat (limited to 'libcxx/test/std/thread/futures/futures.async/async.fail.cpp')
-rw-r--r-- | libcxx/test/std/thread/futures/futures.async/async.fail.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libcxx/test/std/thread/futures/futures.async/async.fail.cpp b/libcxx/test/std/thread/futures/futures.async/async.fail.cpp index f93c3ef20ff..3e7fb80e0e1 100644 --- a/libcxx/test/std/thread/futures/futures.async/async.fail.cpp +++ b/libcxx/test/std/thread/futures/futures.async/async.fail.cpp @@ -30,8 +30,10 @@ int foo (int x) { return x; } -int main () +int main(int, char**) { std::async( foo, 3); // expected-error {{ignoring return value of function declared with 'nodiscard' attribute}} std::async(std::launch::async, foo, 3); // expected-error {{ignoring return value of function declared with 'nodiscard' attribute}} + + return 0; } |