forked from OSchip/llvm-project
<rdar://problem/13759177>
Allowing LLDB to resolve names of Python functions when they are located in classes This allows things like *bound* classmethods to be used for formatters, commands, ... llvm-svn: 183772
This commit is contained in:
parent
d45b9f15f9
commit
8d6e5ec292
|
@ -45,7 +45,13 @@ ResolvePythonName(const char* name,
|
|||
return NULL;
|
||||
}
|
||||
|
||||
if (!PyDict_Check(pmodule))
|
||||
if (PyType_Check(pmodule))
|
||||
{
|
||||
main_dict = ((PyTypeObject*)pmodule)->tp_dict;
|
||||
if (!main_dict)
|
||||
return NULL;
|
||||
}
|
||||
else if (!PyDict_Check(pmodule))
|
||||
{
|
||||
main_dict = PyModule_GetDict (pmodule);
|
||||
if (!main_dict)
|
||||
|
|
Loading…
Reference in New Issue