#autoload # This should be used to complete parameter names if you need some of the # extra options of compadd. It completes only non-local parameters. All # arguments are given to compadd. local expl _description expl parameter if zmodload -e parameter; then setopt localoptions extendedglob compadd "$expl[@]" "$@" - ${(k)parameters[(R)^*local*]} else compadd "$expl[@]" "$@" - ${${${(f)"$(typeset +)"}:#*local *}##* } fi