[CodeGenPrepare] Drop nsw flags in `optimizeLoadExt` (#118180)
[llvm-project.git] / lldb / bindings / interface / SBCommandInterpreterDocstrings.i
blobcad276018e14028d5a36329e00741db1d7b5568e
1 %feature("docstring",
2 "SBCommandInterpreter handles/interprets commands for lldb.
4 You get the command interpreter from the :py:class:`SBDebugger` instance.
6 For example (from test/ python_api/interpreter/TestCommandInterpreterAPI.py),::
8 def command_interpreter_api(self):
9 '''Test the SBCommandInterpreter APIs.'''
10 exe = os.path.join(os.getcwd(), 'a.out')
12 # Create a target by the debugger.
13 target = self.dbg.CreateTarget(exe)
14 self.assertTrue(target, VALID_TARGET)
16 # Retrieve the associated command interpreter from our debugger.
17 ci = self.dbg.GetCommandInterpreter()
18 self.assertTrue(ci, VALID_COMMAND_INTERPRETER)
20 # Exercise some APIs....
22 self.assertTrue(ci.HasCommands())
23 self.assertTrue(ci.HasAliases())
24 self.assertTrue(ci.HasAliasOptions())
25 self.assertTrue(ci.CommandExists('breakpoint'))
26 self.assertTrue(ci.CommandExists('target'))
27 self.assertTrue(ci.CommandExists('platform'))
28 self.assertTrue(ci.AliasExists('file'))
29 self.assertTrue(ci.AliasExists('run'))
30 self.assertTrue(ci.AliasExists('bt'))
32 res = lldb.SBCommandReturnObject()
33 ci.HandleCommand('breakpoint set -f main.c -l %d' % self.line, res)
34 self.assertTrue(res.Succeeded())
35 ci.HandleCommand('process launch', res)
36 self.assertTrue(res.Succeeded())
38 process = ci.GetProcess()
39 self.assertTrue(process)
41 ...
43 The HandleCommand() instance method takes two args: the command string and
44 an SBCommandReturnObject instance which encapsulates the result of command
45 execution.") lldb::SBCommandInterpreter;