Sunday, April 12, 2015

Re: quickfix information

On Sa, 11 Apr 2015, LCD 47 wrote:
> On 11 April 2015, Christian Brabandt <cblists@256bit.org> wrote:
> > On Sa, 11 Apr 2015, LCD 47 wrote:
> >
> > > Being able to save "ancillary" data in quickfix lists / loclists
> > > as the OP suggests would be quite useful too. Then w:quickfix_title
> > > could be saved there, and that would be easier to implement than
> > > keeping track of updates to w:quickfix_title.
> >
> > Like what? Only save a custom dict, like w:quickfix_data?
>
> Right now setqflist() takes a list of dictionaries as an
> argument. What I had in mind was an extra field (say, 'data') in these
> dictionaries, pointing to a value of some unspecified type. These
> fields would be saved by setqflist() and restored by getqflist(), but
> would be ignored when showing the quickfix list in a window.

You need a custom data type for each quickfix item?

> Also it would be tremendously useful to have a new %-format for
> errorformat and friends, that would write to (subfields of) the new
> 'data' field. Or perhaps some kind of mechanism that would direct the
> output of an existing %-format to (subfields of) the 'data' field.
> Right now, the only way to parse things like multiple column numbers
> from a single line of compiler output is to do it with the (otherwise
> mostly useless) %n, and post-process the resulting quickfix.

I am not sure about how to approach this one.

> Alternatively, saving a single string value along with the list
> of dictionaries would still work (it might point to a dictionary when
> needed), but using the data in practice would be a pain.
>
> And of course all this would also apply to loclists.

Sure.

Best,
Christian
--
Die bedauernswürdigsten Menschen sind die gewissenhaften, denen das
Leben unerfüllbare Pflichten aufgebürdet hat.
-- Marie von Ebner-Eschenbach

--
--
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/d/optout.

No comments:

Post a Comment