X-Git-Url: http://git.ipfire.org/?a=blobdiff_plain;f=libstdc%2B%2B-v3%2Ftestsuite%2F30_threads%2Flock%2F4.cc;h=7ba15cba84b49e7d3c04be99eb94cd35d7582d07;hb=99dee82307f1e163e150c9c810452979994047ce;hp=adcbeaa1fcdaea44a0c3a19e32438251f161de92;hpb=4415f7a53887ebd1d79b5614d30a1a329671a4ae;p=thirdparty%2Fgcc.git diff --git a/libstdc++-v3/testsuite/30_threads/lock/4.cc b/libstdc++-v3/testsuite/30_threads/lock/4.cc index adcbeaa1fcda..7ba15cba84b4 100644 --- a/libstdc++-v3/testsuite/30_threads/lock/4.cc +++ b/libstdc++-v3/testsuite/30_threads/lock/4.cc @@ -1,11 +1,9 @@ -// { dg-do run { target *-*-freebsd* *-*-dragonfly* *-*-netbsd* *-*-linux* *-*-gnu* *-*-solaris* *-*-cygwin *-*-darwin* powerpc-ibm-aix* } } -// { dg-options " -std=gnu++11 -pthread" { target *-*-freebsd* *-*-dragonfly* *-*-netbsd* *-*-linux* *-*-gnu* powerpc-ibm-aix* } } -// { dg-options " -std=gnu++11 -pthreads" { target *-*-solaris* } } -// { dg-options " -std=gnu++11 " { target *-*-cygwin *-*-darwin* } } -// { dg-require-cstdint "" } +// { dg-do run } +// { dg-additional-options "-pthread" { target pthread } } +// { dg-require-effective-target c++11 } // { dg-require-gthreads "" } -// Copyright (C) 2010-2014 Free Software Foundation, Inc. +// Copyright (C) 2010-2021 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -39,7 +37,6 @@ struct unreliable_lock ~unreliable_lock() { - bool test __attribute__((unused)) = true; VERIFY( !l.owns_lock() ); } @@ -63,7 +60,6 @@ struct unreliable_lock void unlock() { - bool test __attribute__((unused)) = true; VERIFY( l.owns_lock() ); l.unlock(); } @@ -76,8 +72,6 @@ int unreliable_lock::lock_on = -1; void test01() { - bool test __attribute__((unused)) = true; - unreliable_lock l1, l2, l3; try @@ -97,8 +91,6 @@ void test01() void test02() { - bool test __attribute__((unused)) = true; - // test behaviour when a lock is already held try {