Friday, June 14, 2013

Re: loss of tags


On Jun 15, 2013 12:30 AM, "Charles Campbell" <Charles.E.Campbell@nasa.gov> wrote:
>
> Benji Fisher wrote:
>>
>>      Why not either
>>
>> let s:taglist = taglist()
>>
>> to save the tags before switching windows or
>>
>> wincmd p
>> " Do something with taglist()
>> wincmd p
>>
>> so that you return to the right window before issuing the taglist() command.
>>
>>      Variants:  s:taglist could be a Dictionary, keyed on the buffer name or number.  If you save the buffer number, then you can switch to the right buffer even if there are more window-switching commands than you have told us about.
>>
>>      IWBNI taglist() accepted an optional buffer identifier.
>>
>> HTH  --Benji Fisher
>>
> Hello!
>
> Interesting idea...
> It seems to me that there's a bug involved with vim losing the tags database it had loaded.  I wish there was a way to get reload tags, anyway.
>
> I'll look into saving the output of taglist(".*") and working with that.  The output of taglist() is a List, not a Dictionary, so I'll need to convert it.  Another issue: taglist() takes regular expressions, so one can use
>
>    proc holds a string...
>    taglist(proc.".*") and get a list of tags which match proc.*; ie. do regular expression matching.  I'll have to check to see if the tags database is still retained by a window.
>
> I'll need to figure out how to do that, too.
>
> Regards, and thank you,
>
> Chip Campbell

Can't say whether this database is hold anywhere, but I did not find any caching when exploring taglist() code. It just always reads tags files.

> --
> --
> You received this message from the "vim_use" 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_use" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>

--
--
You received this message from the "vim_use" 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_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

No comments: