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

Re: How to disable completion for a builtin? (actually a reserved word) + an apparent bug

On Wed, 24 Jul 2019 at 17:48, Peter Stephenson <p.stephenson@xxxxxxxxxxx> wrote:
> On Wed, 2019-07-24 at 17:39 +0200, Sebastian Gniazdowski wrote:
> > I don't want to change disable's completion. What I want is that:
> >
> > % decl<TAB>
> >
> > will not try to complete "declare".
> declare is usually a builtin.  If you disabled that it should
> remove it from the list of enabled builtins and reserved words
> and it won't complete.
> disable -r declare
> disable declare

Ah, didn't expect that declare can disable reserved words. Thanks!

> (they're different because the reserved word needs to do
> special parsing for arrays that an ordinary builtin doesn't.)

Good to know.
Sebastian Gniazdowski
News: https://twitter.com/ZdharmaI
IRC: https://kiwiirc.com/client/chat.freenode.net:+6697/#zplugin
Blog: http://zdharma.org

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