[AMDGPU] Add True16 register classes.
[llvm-project.git] / lldb / test / API / commands / expression / call-function / TestCallStopAndContinue.py
blob69f02ec99f64b24c1743daed36d3b06c11bcba7f
1 """
2 Test calling a function, stopping in the call, continue and gather the result on stop.
3 """
5 import lldb
6 from lldbsuite.test.lldbtest import *
7 from lldbsuite.test import lldbutil
10 class ExprCommandCallStopContinueTestCase(TestBase):
11 def setUp(self):
12 # Call super's setUp().
13 TestBase.setUp(self)
14 # Find the line number to break for main.c.
16 def test(self):
17 """Test gathering result from interrupted function call."""
18 self.build()
19 lldbutil.run_to_source_breakpoint(
20 self, "// break here", lldb.SBFileSpec("main.cpp")
23 lldbutil.run_break_set_by_file_and_line(
24 self,
25 "main.cpp",
26 line_number("main.cpp", '{5, "five"}'),
27 num_expected_locations=-1,
28 loc_exact=True,
31 self.expect(
32 "expr -i false -- returnsFive()",
33 error=True,
34 substrs=["Execution was interrupted, reason: breakpoint"],
37 self.runCmd("continue", "Continue completed")
38 self.expect(
39 "thread list",
40 substrs=[
41 "stop reason = User Expression thread plan",
42 r'Completed expression: (Five) $0 = (number = 5, name = "five")',