[Lldb-commits] [lldb] Add warning message to `session save` when transcript isn't saved. (PR #109020)

via lldb-commits lldb-commits at lists.llvm.org
Tue Sep 17 10:35:16 PDT 2024


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 2d13302d3851747a023ffecc6388585e888cd0e9 60045b710e1102d6f220dfd4367f997b73bb64df --extensions cpp -- lldb/source/Commands/CommandObjectSession.cpp lldb/source/Interpreter/CommandInterpreter.cpp
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/lldb/source/Commands/CommandObjectSession.cpp b/lldb/source/Commands/CommandObjectSession.cpp
index 3f714cec41..ac7eec5e04 100644
--- a/lldb/source/Commands/CommandObjectSession.cpp
+++ b/lldb/source/Commands/CommandObjectSession.cpp
@@ -20,7 +20,8 @@ public:
                             "Save the current session transcripts to a file.\n"
                             "If no file if specified, transcripts will be "
                             "saved to a temporary file.\n"
-                            "Note: transcripts will only be saved if interpreter.save-transcript is true.\n",
+                            "Note: transcripts will only be saved if "
+                            "interpreter.save-transcript is true.\n",
                             "session save [file]") {
     AddSimpleArgumentList(eArgTypePath, eArgRepeatOptional);
   }
diff --git a/lldb/source/Interpreter/CommandInterpreter.cpp b/lldb/source/Interpreter/CommandInterpreter.cpp
index 05426771ba..f6537a0135 100644
--- a/lldb/source/Interpreter/CommandInterpreter.cpp
+++ b/lldb/source/Interpreter/CommandInterpreter.cpp
@@ -3307,7 +3307,9 @@ bool CommandInterpreter::SaveTranscript(
   result.AppendMessageWithFormat("Session's transcripts saved to %s\n",
                                  output_file->c_str());
   if (!GetSaveTranscript())
-    result.AppendError("Note: the setting interpreter.save-transcript is set to false, so the transcript might not have been recorded.");
+    result.AppendError(
+        "Note: the setting interpreter.save-transcript is set to false, so the "
+        "transcript might not have been recorded.");
 
   if (GetOpenTranscriptInEditor() && Host::IsInteractiveGraphicSession()) {
     const FileSpec file_spec;

``````````

</details>


https://github.com/llvm/llvm-project/pull/109020


More information about the lldb-commits mailing list