From 9e6d35490a6542f9c97607f93c2ef8ca8e03cbcc Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Wed, 6 Jan 2016 20:12:03 +0000 Subject: Vendor import of lldb trunk r256945: https://llvm.org/svn/llvm-project/lldb/trunk@256945 --- .../test/functionalities/command_script/import/bar/bar.py | 12 ++++++++++++ .../functionalities/command_script/import/bar/barutil.py | 2 ++ 2 files changed, 14 insertions(+) create mode 100644 packages/Python/lldbsuite/test/functionalities/command_script/import/bar/bar.py create mode 100644 packages/Python/lldbsuite/test/functionalities/command_script/import/bar/barutil.py (limited to 'packages/Python/lldbsuite/test/functionalities/command_script/import/bar') diff --git a/packages/Python/lldbsuite/test/functionalities/command_script/import/bar/bar.py b/packages/Python/lldbsuite/test/functionalities/command_script/import/bar/bar.py new file mode 100644 index 000000000000..bbc41f3b217d --- /dev/null +++ b/packages/Python/lldbsuite/test/functionalities/command_script/import/bar/bar.py @@ -0,0 +1,12 @@ +from __future__ import print_function + +def bar_function(debugger, args, result, dict): + global UtilityModule + print(UtilityModule.barutil_function("bar told me " + args), file=result) + return None + +def __lldb_init_module(debugger, session_dict): + global UtilityModule + UtilityModule = __import__("barutil") + debugger.HandleCommand("command script add -f bar.bar_function barothercmd") + return None \ No newline at end of file diff --git a/packages/Python/lldbsuite/test/functionalities/command_script/import/bar/barutil.py b/packages/Python/lldbsuite/test/functionalities/command_script/import/bar/barutil.py new file mode 100644 index 000000000000..0d3d2eb1b2d7 --- /dev/null +++ b/packages/Python/lldbsuite/test/functionalities/command_script/import/bar/barutil.py @@ -0,0 +1,2 @@ +def barutil_function(x): + return "barutil says: " + x -- cgit v1.2.3