classification
Title: IDLE: use rlcompleter suffixed for completions
Type: Stage:
Components: Versions:
process
Status: open Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: terry.reedy
Priority: normal Keywords:

Created on 2020-06-06 19:23 by terry.reedy, last changed 2020-06-06 19:23 by terry.reedy.

Messages (1)
msg370845 - (view) Author: Terry J. Reedy (terry.reedy) * (Python committer) Date: 2020-06-06 19:23
Tab completions may be suffixed with ' ' (keywords), ':' (keywords)*, or '(' (callables) if one of those is required.  Ex. 'import ', 'finally:', 'len('.  Attributes may get '('.  The possible downside is needing to remove the suffix if one does not want the completion for what it is but as a prefix to a longer word.  Ex. 'imports','elsewhere', 'length'.  But this should be much less common in code.

* 'else ' should be 'else:'

With keywords added (#37765) tab list is sorted(Completer().global_match('') + list(__main__.dict__.keys())).  Whatever decide on, calculate first part once (if not already).  list.sort used preexisting order.  key are sorted.  builtins might be.
History
Date User Action Args
2020-06-06 19:25:44terry.reedylinkissue27609 dependencies
2020-06-06 19:23:27terry.reedycreate