mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-11-27 15:14:31 +00:00
Fix an issue where the @lldb.command marker would not work with the new 5-argument version of the Python command function
This: a) teaches PythonCallable to look inside a callable object b) teaches PythonCallable to discover whether a callable method is bound c) teaches lldb.command to dispatch to either the older 4 argument version or the newer 5 argument version llvm-svn: 273640
This commit is contained in:
1 parent
68f7f1cf00
commit
a5d6765cb0
4 files changed
+36
-6
No files matched your search
@@ -610,7 +610,7 @@ LLDBSwigPythonCallCommand
|
||||
PythonObject exe_ctx_arg(PyRefType::Owned, SBTypeToSWIGWrapper(exe_ctx_sb));
|
||||
PythonObject cmd_retobj_arg(PyRefType::Owned, SBTypeToSWIGWrapper(&cmd_retobj_sb));
|
||||
|
||||
if (argc.count == 5 || argc.has_varargs)
|
||||
if (argc.count == 5 || argc.is_bound_method || argc.has_varargs)
|
||||
pfunc(debugger_arg, PythonString(args), exe_ctx_arg, cmd_retobj_arg, dict);
|
||||
else
|
||||
pfunc(debugger_arg, PythonString(args), cmd_retobj_arg, dict);
|
||||
|
||||
Reference in new issue
Block a user