On Friday 15 January 2010, Freddy Vulto wrote:

> Maybe we'd also better merge _get_cword and _get_pword together to a new:
> 
>    _get_cwords_by_ref 'nonwordbreakchars' cur [prev [prevprev] ...]
> 
> with `prev', `prevprev', etc.  being optional arguments.
> 
> This circumvents doing the same cwords-parsing repeatedly when calling
> both _get_cword and _get_pword.  This also fixes situations where
> `nonwordbreakchars' passed to _get_cword and _get_pword aren't the same,
> which they should be.  Plus it saves us a subshell call and we have
> consistent naming.

Sounds good to me, even better if it was necessary to specify 
nonwordbreakchars only when one actually needs to, like
_get_cwords_by_ref [-n 'nonwordbreakchars'] cur [prev [prevprev] ...]

_______________________________________________
Bash-completion-devel mailing list
[email protected]
http://lists.alioth.debian.org/mailman/listinfo/bash-completion-devel

Reply via email to