File tree 1 file changed +4
-4
lines changed 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -420,8 +420,8 @@ _comp_compgen__error_fallback()
420
420
# -a Append to the array
421
421
# -v arr Store the results to the array ARR. The default is `COMPREPLY`.
422
422
# The array name should not start with an underscores "_", which is
423
- # internally used. The array name should not be either "IFS" or
424
- # "OPT{IND,ARG,ERR}".
423
+ # internally used. The array name should not be any of "cur", "IFS"
424
+ # or "OPT{IND,ARG,ERR}".
425
425
# -U var Unlocalize VAR before performing the assignments. This option can
426
426
# be specified multiple times to register multiple variables. This
427
427
# option is supposed to be used in implementing a generator (G1) when
@@ -538,7 +538,7 @@ _comp_compgen()
538
538
case $_opt in
539
539
a) _append=set ;;
540
540
v)
541
- if [[ $OPTARG == @ (* [^_a-zA-Z0-9]* | [0-9]* | ' ' | _* | IFS| OPTIND| OPTARG| OPTERR) ]]; then
541
+ if [[ $OPTARG == @ (* [^_a-zA-Z0-9]* | [0-9]* | ' ' | _* | IFS| OPTIND| OPTARG| OPTERR| cur ) ]]; then
542
542
printf ' bash_completion: %s: -v: invalid array name `%s' \' ' \n' " $FUNCNAME " " $OPTARG " >&2
543
543
return 2
544
544
fi
@@ -548,7 +548,7 @@ _comp_compgen()
548
548
if [[ $OPTARG == @ (* [^_a-zA-Z0-9]* | [0-9]* | ' ' ) ]]; then
549
549
printf ' bash_completion: %s: -U: invalid variable name `%s' \' ' \n' " $FUNCNAME " " $OPTARG " >&2
550
550
return 2
551
- elif [[ $OPTARG == @ (_* | IFS| OPTIND| OPTARG| OPTERR) ]]; then
551
+ elif [[ $OPTARG == @ (_* | IFS| OPTIND| OPTARG| OPTERR| cur ) ]]; then
552
552
printf ' bash_completion: %s: -U: unnecessary to mark `%s' \' ' as upvar\n' " $FUNCNAME " " $OPTARG " >&2
553
553
return 2
554
554
fi
You can’t perform that action at this time.
0 commit comments