diff options
| author | Aaron Puchert <aaronpuchert@alice-dsl.net> | 2018-10-10 22:05:33 +0000 |
|---|---|---|
| committer | Aaron Puchert <aaronpuchert@alice-dsl.net> | 2018-10-10 22:05:33 +0000 |
| commit | 0e192395f162e7571a1f92ba1528a8080e507777 (patch) | |
| tree | 868784484a0e29e2a0e13eee4d99dbc6e4c60dd8 | |
| parent | 336db683782ba037b6e6b11711fc8d199d48f1c4 (diff) | |
| download | bcm5719-llvm-0e192395f162e7571a1f92ba1528a8080e507777.tar.gz bcm5719-llvm-0e192395f162e7571a1f92ba1528a8080e507777.zip | |
Use std::scoped_lock only for C++17 and newer
This fixes a test failure caused by D53049.
llvm-svn: 344192
| -rw-r--r-- | libcxx/test/libcxx/thread/thread.mutex/thread_safety_lock_guard.pass.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libcxx/test/libcxx/thread/thread.mutex/thread_safety_lock_guard.pass.cpp b/libcxx/test/libcxx/thread/thread.mutex/thread_safety_lock_guard.pass.cpp index bd015feedb3..d9bd0481e2e 100644 --- a/libcxx/test/libcxx/thread/thread.mutex/thread_safety_lock_guard.pass.cpp +++ b/libcxx/test/libcxx/thread/thread.mutex/thread_safety_lock_guard.pass.cpp @@ -25,8 +25,10 @@ std::mutex m; int foo __attribute__((guarded_by(m))); static void scoped() { +#if __cplusplus >= 201703L std::scoped_lock<std::mutex> lock(m); foo++; +#endif } int main() { |

