diff options
author | Bram Moolenaar <Bram@vim.org> | 2017-12-18 19:48:58 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2017-12-18 19:48:58 +0100 |
commit | b254af312d1696b12367085acfbe41a41b7f1ea5 (patch) | |
tree | 4b1c72636ceb95fd861db631c9931278b4364adf /runtime | |
parent | c9e649ae816cdff0d1da8a97d40e695c6d3991bd (diff) |
patch 8.0.1406: difficult to track changes to a quickfix listv8.0.1406
Problem: Difficult to track changes to a quickfix list.
Solution: Add a "changedtick" value. (Yegappan Lakshmanan, closes #2460)
Diffstat (limited to 'runtime')
-rw-r--r-- | runtime/doc/eval.txt | 4 | ||||
-rw-r--r-- | runtime/doc/quickfix.txt | 8 |
2 files changed, 12 insertions, 0 deletions
diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt index e17181b31e..c621ba1ffe 100644 --- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -4674,6 +4674,8 @@ getqflist([{what}]) *getqflist()* If the optional {what} dictionary argument is supplied, then returns only the items listed in {what} as a dictionary. The following string items are supported in {what}: + changedtick get the total number of changes made + to the list context get the context stored with |setqflist()| efm errorformat to use when parsing "lines". If not present, then the 'errorformat' option @@ -4707,6 +4709,8 @@ getqflist([{what}]) *getqflist()* "items" with the list of entries. The returned dictionary contains the following entries: + changedtick total number of changes made to the + list |quickfix-changedtick| context context information stored with |setqflist()|. If not present, set to "". id quickfix list ID |quickfix-ID|. If not diff --git a/runtime/doc/quickfix.txt b/runtime/doc/quickfix.txt index 29752db8fb..75ff404db2 100644 --- a/runtime/doc/quickfix.txt +++ b/runtime/doc/quickfix.txt @@ -64,6 +64,14 @@ When a window with a location list is split, the new window gets a copy of the location list. When there are no longer any references to a location list, the location list is destroyed. + *quickfix-changedtick* +Every quickfix and location list has a read-only changedtick variable that +tracks the total number of changes made to the list. Every time the quickfix +list is modified, this count is incremented. This can be used to perform an +action only when the list has changed. The getqflist() and getloclist() +functions can be used to query the current value of changedtick. You cannot +change the changedtick variable. + The following quickfix commands can be used. The location list commands are similar to the quickfix commands, replacing the 'c' prefix in the quickfix command with 'l'. |