[Lldb-commits] [lldb] [lldb][test] Wait for a file before attempting to attach to lldb-server test inferior (PR #162064)
via lldb-commits
lldb-commits at lists.llvm.org
Mon Oct 6 03:47:33 PDT 2025
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff origin/main HEAD --extensions cpp -- lldb/test/API/tools/lldb-server/main.cpp
``````````
:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/lldb/test/API/tools/lldb-server/main.cpp b/lldb/test/API/tools/lldb-server/main.cpp
index 688c17a36..7e84552b0 100644
--- a/lldb/test/API/tools/lldb-server/main.cpp
+++ b/lldb/test/API/tools/lldb-server/main.cpp
@@ -5,8 +5,8 @@
#include <cstdlib>
#include <cstring>
#include <errno.h>
-#include <future>
#include <fstream>
+#include <future>
#include <inttypes.h>
#include <memory>
#include <mutex>
@@ -267,7 +267,8 @@ int main(int argc, char **argv) {
for (int i = 1; i < argc; ++i) {
std::string arg = argv[i];
if (consume_front(arg, "syncfile:")) {
- // Write to this file to tell test framework that attaching is now possible.
+ // Write to this file to tell test framework that attaching is now
+ // possible.
std::ofstream(arg).close();
} else if (consume_front(arg, "stderr:")) {
// Treat remainder as text to go to stderr.
``````````
</details>
https://github.com/llvm/llvm-project/pull/162064
More information about the lldb-commits
mailing list