[Lldb-commits] [lldb] [lldb][windows] fix scope_exit warning (PR #200439)
Charles Zablit via lldb-commits
lldb-commits at lists.llvm.org
Fri May 29 08:54:01 PDT 2026
https://github.com/charles-zablit created https://github.com/llvm/llvm-project/pull/200439
Using the constructor rather than `make_scope_exit` is preferred.
>From 9ca41038ddaa5b5e34e4961e56b099cccd4f0826 Mon Sep 17 00:00:00 2001
From: Charles Zablit <c_zablit at apple.com>
Date: Fri, 29 May 2026 16:53:21 +0100
Subject: [PATCH] [lldb][windows] fix scope_exit warning
---
lldb/source/Plugins/Process/Windows/Common/DebuggerThread.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lldb/source/Plugins/Process/Windows/Common/DebuggerThread.cpp b/lldb/source/Plugins/Process/Windows/Common/DebuggerThread.cpp
index 22a836f9cbed5..a672f24209090 100644
--- a/lldb/source/Plugins/Process/Windows/Common/DebuggerThread.cpp
+++ b/lldb/source/Plugins/Process/Windows/Common/DebuggerThread.cpp
@@ -497,7 +497,7 @@ ConvertNtDevicePathToDosPath(llvm::ArrayRef<wchar_t> nt_path) {
::GetLastError());
return std::nullopt;
}
- auto close_iter = llvm::make_scope_exit([&] { ::FindVolumeClose(vol_iter); });
+ llvm::scope_exit close_iter([&] { ::FindVolumeClose(vol_iter); });
do {
// FindFirstVolumeW yields "\\?\Volume{GUID}\".
More information about the lldb-commits
mailing list