Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

PATCH: 3.1.6-test-2: _parameters



This tidies up _parameters a bit.  I'd have liked to use something like

  if zmodload -e parameter; then
    compadd "$@" - ${(k)parameters}
    return
  fi

but then there's no way of getting rid of local parameters, which is a
shame.

--- Completion/Core/_parameters~	Fri Jun  4 15:18:48 1999
+++ Completion/Core/_parameters	Fri Jul 23 09:55:38 1999
@@ -4,4 +4,4 @@
 # extra options of compadd. It completes only non-local parameters. All
 # arguments are given to compadd.
 
-compadd "$@" - "${(@)${(@)${(@)${(@f)$(typeset)}:#*local *\=*}%%\=*}##* }"
+compadd "$@" - ${${${(f)"$(typeset +)"}:#*local *}##* }

-- 
Peter Stephenson <pws@xxxxxxxxxxxxxxxxx>       Tel: +39 050 844536
WWW:  http://www.ifh.de/~pws/
Dipartimento di Fisica, Via Buonarroti 2, 56127 Pisa, Italy



Messages sorted by: Reverse Date, Date, Thread, Author