1
0
forked from VimPlug/jedi

Fix an issue with mixed objects.

This commit is contained in:
Dave Halter
2016-09-27 01:28:42 +02:00
parent 9b85d5517f
commit a96eec8058

View File

@@ -127,7 +127,11 @@ def find_syntax_node_name(evaluator, python_object):
if name_str == '<lambda>':
return None # It's too hard to find lambdas.
names = module.used_names[name_str]
# Doesn't always work (e.g. os.stat_result)
try:
names = module.used_names[name_str]
except KeyError:
return None
names = [n for n in names if n.is_definition()]
try: