Commit f179be1
committed
Avoid regeneration of candidates. Store them when state is 0 and returns
them one by one on subsequent calls
http://tiswww.case.edu/php/chet/readline/readline.html#How-Completing-Works
> *state* is zero the first time the function is called, allowing the
> generator to perform any necessary initialization, and a positive
> non-zero integer for each subsequent call. Usually the generator
> function computes the list of possible completions when *state* is zero,
> and returns them one at a time on subsequent calls.1 parent 22652ae commit f179be1
1 file changed
+5
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
| 30 | + | |
30 | 31 | | |
31 | 32 | | |
32 | | - | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
33 | 36 | | |
34 | | - | |
| 37 | + | |
35 | 38 | | |
36 | 39 | | |
37 | 40 | | |
| |||
0 commit comments