[Lldb-commits] [lldb] [lldb] Fix `po` alias by printing fix-its to the console. (PR #68755)
via lldb-commits
lldb-commits at lists.llvm.org
Tue Oct 10 17:05:18 PDT 2023
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {darker}-->
:warning: Python code formatter, darker found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
darker --check --diff -r 4df74963ea0f6c8650d5837ab52e3cdcf1dcf016..ee8e9b698edac7c44d77441a86844f94b045b9d1 lldb/test/API/lang/cpp/dwim-print-fixit/TestCppDWIMPrintFixIt.py lldb/test/API/lang/cpp/expression-fixit/TestCppExpressionFixIt.py lldb/test/API/commands/expression/fixits/TestFixIts.py
``````````
</details>
<details>
<summary>
View the diff from darker here.
</summary>
``````````diff
--- commands/expression/fixits/TestFixIts.py 2023-10-10 23:52:02.000000 +0000
+++ commands/expression/fixits/TestFixIts.py 2023-10-11 00:05:10.993363 +0000
@@ -20,11 +20,13 @@
"expression ((1 << 16) - 1))", ret_val
)
self.assertEqual(
result, lldb.eReturnStatusSuccessFinishResult, ret_val.GetError()
)
- self.assertIn("Evaluated this expression after applying Fix-It(s):", ret_val.GetError())
+ self.assertIn(
+ "Evaluated this expression after applying Fix-It(s):", ret_val.GetError()
+ )
def test_with_target(self):
"""Test calling expressions with errors that can be fixed by the FixIts."""
self.build()
(target, process, self.thread, bkpt) = lldbutil.run_to_source_breakpoint(
@@ -97,11 +99,13 @@
result = self.dbg.GetCommandInterpreter().HandleCommand(
"expression null_pointer.first", ret_val
)
self.assertEqual(result, lldb.eReturnStatusFailed, ret_val.GetError())
- self.assertIn("Evaluated this expression after applying Fix-It(s):", ret_val.GetError())
+ self.assertIn(
+ "Evaluated this expression after applying Fix-It(s):", ret_val.GetError()
+ )
self.assertIn("null_pointer->first", ret_val.GetError())
# The final function call runs into SIGILL on aarch64-linux.
@expectedFailureAll(
archs=["aarch64"], oslist=["freebsd", "linux"], bugnumber="llvm.org/pr49407"
``````````
</details>
https://github.com/llvm/llvm-project/pull/68755
More information about the lldb-commits
mailing list