[llvm] [orc-rt] Fix -Wctad-maybe-unsupported warning in unit test. (PR #221399)
Lang Hames via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 4 23:27:04 PDT 2026
https://github.com/lhames created https://github.com/llvm/llvm-project/pull/221399
Avoid the warning by naming the mutex type on scoped_lock.
'std::scoped_lock' may not intend to support class template argument deduction
>From ff3c0bc98eea576e2494729cca6b59bf76e7e937 Mon Sep 17 00:00:00 2001
From: Lang Hames <lhames at gmail.com>
Date: Sat, 5 Sep 2026 06:18:20 +0000
Subject: [PATCH] [orc-rt] Fix -Wctad-maybe-unsupported warning in unit test.
Avoid the warning by naming the mutex type on scoped_lock.
'std::scoped_lock' may not intend to support class template argument deduction
---
orc-rt/test/unit/bedrock/SessionTest.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/orc-rt/test/unit/bedrock/SessionTest.cpp b/orc-rt/test/unit/bedrock/SessionTest.cpp
index 3d5cf4df15f39..4bffc26c82f3f 100644
--- a/orc-rt/test/unit/bedrock/SessionTest.cpp
+++ b/orc-rt/test/unit/bedrock/SessionTest.cpp
@@ -107,7 +107,7 @@ class MockControllerAccess : public Session::ControllerAccess {
if (MCA) {
bool Notify;
{
- std::scoped_lock Lock(MCA->M);
+ std::scoped_lock<std::mutex> Lock(MCA->M);
--MCA->Outstanding;
Notify = MCA->Shutdown && MCA->Outstanding == 0;
}
More information about the llvm-commits
mailing list