forked from VimPlug/jedi
fix a problem with python3
This commit is contained in:
@@ -192,7 +192,7 @@ class Completion(BaseDefinition):
|
||||
return [self]
|
||||
|
||||
self._followed_definitions = \
|
||||
[BaseDefinition(d, start_pos=None) for d in defs]
|
||||
[BaseDefinition(d, d.start_pos) for d in defs]
|
||||
evaluate.clear_caches()
|
||||
|
||||
return self._followed_definitions
|
||||
|
||||
@@ -462,7 +462,7 @@ def check_flow_information(flow, search_name, pos):
|
||||
result = []
|
||||
if isinstance(flow, parsing.Scope) and not result:
|
||||
for ass in reversed(flow.asserts):
|
||||
if ass.start_pos > pos:
|
||||
if pos is None or ass.start_pos > pos:
|
||||
continue
|
||||
result = check_statement_information(ass, search_name)
|
||||
if result:
|
||||
|
||||
@@ -301,7 +301,7 @@ class TestSpeed(Base):
|
||||
for i in range(number):
|
||||
func(self)
|
||||
single_time = (time.time() - first) / number
|
||||
print('speed', func, single_time)
|
||||
print('\nspeed', func, single_time)
|
||||
assert single_time < time_per_run
|
||||
return wrapper
|
||||
return decorated
|
||||
|
||||
Reference in New Issue
Block a user