mirror of
https://https.git.savannah.gnu.org/git/bash.git
synced 2026-08-10 20:20:38 +02:00
commit bash-20180112 snapshot
This commit is contained in:
@@ -681,6 +681,8 @@ compgen_builtin (list)
|
||||
COMPSPEC *cs;
|
||||
STRINGLIST *sl;
|
||||
char *word, **matches;
|
||||
char *old_line;
|
||||
int old_ind;
|
||||
|
||||
if (list == 0)
|
||||
return (EXECUTION_SUCCESS);
|
||||
@@ -721,7 +723,15 @@ compgen_builtin (list)
|
||||
cs->filterpat = STRDUP (Xarg);
|
||||
|
||||
rval = EXECUTION_FAILURE;
|
||||
|
||||
/* probably don't have to save these, just being safe */
|
||||
old_line = pcomp_line;
|
||||
old_ind = pcomp_ind;
|
||||
pcomp_line = (char *)NULL;
|
||||
pcomp_ind = 0;
|
||||
sl = gen_compspec_completions (cs, "compgen", word, 0, 0, 0);
|
||||
pcomp_line = old_line;
|
||||
pcomp_ind = old_ind;
|
||||
|
||||
/* If the compspec wants the bash default completions, temporarily
|
||||
turn off programmable completion and call the bash completion code. */
|
||||
|
||||
@@ -40,11 +40,11 @@ Options which set attributes:
|
||||
-a to make NAMEs indexed arrays (if supported)
|
||||
-A to make NAMEs associative arrays (if supported)
|
||||
-i to make NAMEs have the `integer' attribute
|
||||
-l to convert NAMEs to lower case on assignment
|
||||
-l to convert the value of each NAME to lower case on assignment
|
||||
-n make NAME a reference to the variable named by its value
|
||||
-r to make NAMEs readonly
|
||||
-t to make NAMEs have the `trace' attribute
|
||||
-u to convert NAMEs to upper case on assignment
|
||||
-u to convert the value of each NAME to upper case on assignment
|
||||
-x to make NAMEs export
|
||||
|
||||
Using `+' instead of `-' turns off the given attribute.
|
||||
|
||||
Reference in New Issue
Block a user