Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: zle messes up 'words' variable?
On Apr 27, 11:26am, Felipe Contreras wrote:
}
} Strangely enough, if I use the #compdef tag, the code works fine
} (words="foo").
}
} Any ideas?
Hrm. #compdef is equivalent to "compdef -na ..." and causes the
function to be autoloaded at the time it's referenced. I don't know
of any other reason the -na options would change the behavior. Does
the code work fine on repeated attempts or only the first time?
What may be happening is that "sticky emulation" is in effect, so that
when the function is autoloaded in bash compatibility mode, "words"
becomes non-special. If so, I'm not familiar enough with bashcompinit
to say whether that's intentional or an accidental side-effect.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author