On 2006-10-12, Hari Krishna Dara <[EMAIL PROTECTED]> wrote:
> On Thu, 12 Oct 2006 at 12:51am, Gary Johnson wrote:
> 
> > On 2006-10-11, Hari Krishna Dara <[EMAIL PROTECTED]> wrote:
> > > On Wed, 11 Oct 2006 at 10:30pm, David Fishburn wrote:
> >
> > > > > From: Hari Krishna Dara [mailto:[EMAIL PROTECTED]
> > > > > Sent: Wednesday, October 11, 2006 9:18 PM
> >
> > > > > Is anyone working or planning to work on enhancing exuberant
> > > > > ctags to recognize the dict and autoloaded functions ? Does
> > > > > this require modifying the code, or just some regex patterns?
> >
> > > > What language elements are you referring to?
> > > > That would allow me to create a test case.
> >
> > > What I see is that ctags fails to extract the right function name, in
> > > the below syntax (it basically reports dict and plug as functions):
> > >
> > > function! dict.func()
> > > function! plug#func()
> > >
> > > In my new plugins, most of the functions are these so I hardly get to
> > > make use of ctags.
> >
> > As a workaround, you could create a ~/.ctags file and put something
> > like this line in it:
> >
> > --regex-Vim=/^[ \t]*function!?[ \t]+([a-zA-Z0-9_\.#]*)\(/\1/f,function/
> >
> > That will include the "dict." and "plug#" prefixes in the tag.  If
> > you want only the "func" portion, that's easy to fix.
> >
> > HTH,
> > Gary
> 
> Will this not override the default functionality for Vim scripts (ie.,
> parsing of the fields etc.). I was thinking this will replace the
> built-in support, so it has to be complete by itself, or the default
> support should be enhanced.

I wondered about that at first, too, but the ctags man page says, in 
the description of the --regex-<LANG> option,

    The regular expression defined by this option is added to the 
    current list of regular expressions for the specified language 
    unless the parameter is omitted, in which case the current list 
    is cleared.

So, that regex should supplement, not replace, the built-in support.

> In any case, David Fishburn has taken over the maintenance for Vim 
> scripts and he is working on improving the vim.c of ctags.

I received e-mail from Dave this morning.  It appears that he's done 
with the changes except for testing.

Regards,
Gary

-- 
Gary Johnson                 | Agilent Technologies
[EMAIL PROTECTED]     | Wireless Division
                             | Spokane, Washington, USA

Reply via email to