On Tue, 26 Sep 2006 at 11:03am, Bram Moolenaar wrote:

>
> Hari Krishna Dara wrote:
>
> > I am observing that the taglist() function is not sensitive to the
> > changes in 'tags' value. It also seems to cache the value of 'tags' as
> > of the time the function is called for the first time. To reproduce the
> > problem (you need to have patch 96 applied, otherwise there is another
> > bug in 7.0GA that could mask the bug that the below is trying to show),
> >
> > - create a directory with at least one file that ctags recognizes. Make
> >   a copy of this directory.
> > - Run ctags in both directories to create tags file. They will
> >   essentially be identical.
> > - Start vim/gvim and cd to one of the directories. Have 'tags' set to
> >   "./tags".
> > - Execute taglist() on a tag that you know exists, something like:
> >     :echo taglist('main')
> > - Now, cd into the other directory, and run the same command. You will
> >   see that the tags are reported from the other directory.
> > - Change 'tags' to the absolute path to the second directory and run the
> >   echo command again. You will still observe that taglist() is using the
> >   previous tags file.
> >
> > Can anyone confirm that they can reproduce this?
>
> Did you take into account that Vim uses "./tags" as the tags file
> relative to the current file?  Try editing another file after the ":cd"
> command.  Or use the value "tags", which means the tags file in the
> current directory.

Frankly speaking I didn't know that ./tags is relative to the current
file (I was expecting it to be relative to the current directory),
however that makes no difference to this bug.
- when you run taglist() in the above steps, there is no file opened.
- I repeated the experiment with just "tags" as the value for 'tags'.
- I also tried hardcoding the tags value to the absolution paths of both
  tags files, something like: "c:/tmp/t1/tags,c:/tmp/t2/tags" and later
  changing it to something like "c:/tmp/t1/tags", but it continues to
  show results from both tags files.

-- 
Thanks,
Hari

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

Reply via email to