Yegappan wrote:

> There are several places in quickfix.c where a command index is
> checked to see whether it refers to a location list command.
> For readability reasons, it is better to add a function that checks
> for location list commands. I am attaching a patch which adds
> this function and uses it. The patch also includes simplification
> for a couple of long checks in a function call.
> 
> There is a minor performance penalty from the additional checks
> for the various supported location list commands. But this is
> negligible as this function is not called from any frequently
> executed code path.

Hmm, I don't really like the long case list.

Can't we use:  eap->cmd[0] == 'l'

Another way would be to use a flag in the command table.  But we are
already close to running out of bits.


-- 
My Go, this amn keyboar oesn't have a .

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui