Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Sort autocomplete identifiers

  • Loading branch information...
commit 3f50e6776a664ff640408d4833c4a14574d9704f 1 parent 76a9de4
adonohue authored
Showing with 4 additions and 4 deletions.
  1. +4 −4 src/__init__.py
View
8 src/__init__.py
@@ -480,7 +480,7 @@ def __init__(self, cmd_incs, do_color, do_echo, codebase_mode,
# couldn't read history (probably one hasn't been created yet)
pass
- self.autocomplete_identifiers = list(PHP_RESERVED_WORDS)
+ self.autocomplete_identifiers = sorted(PHP_RESERVED_WORDS)
self.autocomplete_cache = None
self.autocomplete_match = None
@@ -504,8 +504,8 @@ def tab_complete(text, state):
pos = bisect(self.autocomplete_identifiers, text)
while self.autocomplete_identifiers[pos].startswith(text):
- identifiers = self.autocomplete_identifiers[pos]
- self.autocomplete_cache.append(identifiers)
+ identifier = self.autocomplete_identifiers[pos]
+ self.autocomplete_cache.append(identifier)
pos = pos + 1
if self.function_signatures.has_key(text):
@@ -674,7 +674,7 @@ def php_restart(self):
return self.php_open_and_check()
def php_open(self):
- self.autocomplete_identifiers = list(PHP_RESERVED_WORDS)
+ self.autocomplete_identifiers = sorted(PHP_RESERVED_WORDS)
cmd = " ".join([self.comm_base] + list(self.cmd_incs))
if self.with_xdebug:
os.putenv("XDEBUG_CONFIG", "remote_port=" + str(self.dbgp_port) +
Please sign in to comment.
Something went wrong with that request. Please try again.