[Lldb-commits] [lldb] fe96d1e - [lldb/SWIG] Guard Python type map in SWIG interface by SWIGPYTHON

Jonas Devlieghere via lldb-commits lldb-commits at lists.llvm.org
Mon Dec 9 09:36:18 PST 2019


Author: Jonas Devlieghere
Date: 2019-12-09T09:35:48-08:00
New Revision: fe96d1ee788d3e8dcdc6fb984bc5376d9ec84d7d

URL: https://github.com/llvm/llvm-project/commit/fe96d1ee788d3e8dcdc6fb984bc5376d9ec84d7d
DIFF: https://github.com/llvm/llvm-project/commit/fe96d1ee788d3e8dcdc6fb984bc5376d9ec84d7d.diff

LOG: [lldb/SWIG] Guard Python type map in SWIG interface by SWIGPYTHON

Guard the Python type map in SBTarget by the SWIGPYTHON define to
ensures the rest of the interface can be reused for other languages
supported by SWIG.

Added: 
    

Modified: 
    lldb/scripts/interface/SBTarget.i

Removed: 
    


################################################################################
diff  --git a/lldb/scripts/interface/SBTarget.i b/lldb/scripts/interface/SBTarget.i
index 36492f5eed01..b31622889e52 100644
--- a/lldb/scripts/interface/SBTarget.i
+++ b/lldb/scripts/interface/SBTarget.i
@@ -596,6 +596,7 @@ public:
                             const SBFileSpecList &module_list,
                             const SBFileSpecList &comp_unit_list);
 
+#ifdef SWIGPYTHON
 %typemap(in) (const char **symbol_name, uint32_t num_names) {
   using namespace lldb_private;
   /* Check if is a list  */
@@ -622,11 +623,7 @@ public:
     return NULL;
   }
 }
-
-//%typecheck(SWIG_TYPECHECK_STRING_ARRAY) (const char *symbol_name[], uint32_t num_names) {
-//    $1 = 1;
-//    $2 = 1;
-//}
+#endif
 
     lldb::SBBreakpoint
     BreakpointCreateByNames (const char **symbol_name,


        


More information about the lldb-commits mailing list