summaryrefslogtreecommitdiffstats
path: root/lldb/scripts/Python/interface
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/scripts/Python/interface')
-rw-r--r--lldb/scripts/Python/interface/SBCommandInterpreter.i65
-rw-r--r--lldb/scripts/Python/interface/SBDebugger.i8
2 files changed, 70 insertions, 3 deletions
diff --git a/lldb/scripts/Python/interface/SBCommandInterpreter.i b/lldb/scripts/Python/interface/SBCommandInterpreter.i
index 9dc842e87c2..856038094f7 100644
--- a/lldb/scripts/Python/interface/SBCommandInterpreter.i
+++ b/lldb/scripts/Python/interface/SBCommandInterpreter.i
@@ -10,6 +10,71 @@
namespace lldb {
%feature("docstring",
+"SBCommandInterpreterRunOptions controls how the RunCommandInterpreter runs the code it is fed.
+A default SBCommandInterpreterRunOptions object has:
+ StopOnContinue: false
+ StopOnError: false
+ StopOnCrash: false
+ EchoCommands: true
+ PrintResults: true
+ AddToHistory: true
+
+
+") SBCommandInterpreterRunOptions;
+class SBCommandInterpreterRunOptions
+{
+friend class SBDebugger;
+public:
+ SBCommandInterpreterRunOptions();
+ ~SBCommandInterpreterRunOptions();
+
+ bool
+ GetStopOnContinue () const;
+
+ void
+ SetStopOnContinue (bool);
+
+ bool
+ GetStopOnError () const;
+
+ void
+ SetStopOnError (bool);
+
+ bool
+ GetStopOnCrash () const;
+
+ void
+ SetStopOnCrash (bool);
+
+ bool
+ GetEchoCommands () const;
+
+ void
+ SetEchoCommands (bool);
+
+ bool
+ GetPrintResults () const;
+
+ void
+ SetPrintResults (bool);
+
+ bool
+ GetAddToHistory () const;
+
+ void
+ SetAddToHistory (bool);
+private:
+ lldb_private::CommandInterpreterRunOptions *
+ get () const;
+
+ lldb_private::CommandInterpreterRunOptions &
+ ref () const;
+
+ // This is set in the constructor and will always be valid.
+ mutable std::unique_ptr<lldb_private::CommandInterpreterRunOptions> m_opaque_up;
+};
+
+%feature("docstring",
"SBCommandInterpreter handles/interprets commands for lldb. You get the
command interpreter from the SBDebugger instance. For example (from test/
python_api/interpreter/TestCommandInterpreterAPI.py),
diff --git a/lldb/scripts/Python/interface/SBDebugger.i b/lldb/scripts/Python/interface/SBDebugger.i
index ba1c18914e3..fb63fc362dc 100644
--- a/lldb/scripts/Python/interface/SBDebugger.i
+++ b/lldb/scripts/Python/interface/SBDebugger.i
@@ -363,11 +363,13 @@ public:
lldb::SBTypeSynthetic
GetSyntheticForType (lldb::SBTypeNameSpecifier);
-
+
void
RunCommandInterpreter (bool auto_handle_events,
- bool spawn_thread);
-
+ bool spawn_thread,
+ SBCommandInterpreterRunOptions &options,
+ int &num_errors,
+ bool &quit_requested);
}; // class SBDebugger
} // namespace lldb
OpenPOWER on IntegriCloud