1
0
forked from VimPlug/jedi

Fix an attribute error in static analysis code.

This commit is contained in:
Dave Halter
2015-02-26 14:40:33 +01:00
parent 9b4385fb24
commit a998c36fa3
2 changed files with 7 additions and 0 deletions

View File

@@ -40,6 +40,7 @@ class CompiledObject(Base):
# comply with the parser # comply with the parser
start_pos = 0, 0 start_pos = 0, 0
path = None # modules have this attribute - set it to None. path = None # modules have this attribute - set it to None.
used_names = {} # To be consistent with modules.
def __init__(self, obj, parent=None): def __init__(self, obj, parent=None):
self.obj = obj self.obj = obj

View File

@@ -111,3 +111,9 @@ import import_tree
import_tree.a import_tree.a
import_tree.b import_tree.b
# This is something that raised an error, because it was using a complex
# mixture of Jedi fakes and compiled objects.
import _sre
#! 15 attribute-error
_sre.compile().not_existing