diff options
author | Justin M. Keyes <justinkz@gmail.com> | 2019-08-31 14:06:45 +0200 |
---|---|---|
committer | Justin M. Keyes <justinkz@gmail.com> | 2019-09-04 21:21:28 +0200 |
commit | 83c5701fe6d182c2f458b95d09114d9c861f8893 (patch) | |
tree | 76b83432a84a3f603bb35bd0452c73d12d4d6020 /runtime | |
parent | d7aea13fee879a5e7854f2ebe9b7321cd8daf84f (diff) | |
download | rneovim-83c5701fe6d182c2f458b95d09114d9c861f8893.tar.gz rneovim-83c5701fe6d182c2f458b95d09114d9c861f8893.tar.bz2 rneovim-83c5701fe6d182c2f458b95d09114d9c861f8893.zip |
vim-patch:8.1.1498: ":write" increments b:changedtick even though nothing changed
Problem: ":write" increments b:changedtick even though nothing changed.
(Daniel Hahler)
Solution: Only increment b:changedtick if the modified flag is reset.
https://github.com/vim/vim/commit/c024b4667875e5bc6fd0ed791530e33c3161bff7
Diffstat (limited to 'runtime')
-rw-r--r-- | runtime/doc/eval.txt | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt index 06f88955c9..8ec9dbdbdf 100644 --- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -1313,8 +1313,10 @@ One local buffer variable is predefined: *b:changedtick* *changetick* b:changedtick The total number of changes to the current buffer. It is incremented for each change. An undo command is also a change - in this case. This can be used to perform an action only when - the buffer has changed. Example: > + in this case. Resetting 'modified' when writing the buffer is + also counted. + This can be used to perform an action only when the buffer has + changed. Example: > :if my_changedtick != b:changedtick : let my_changedtick = b:changedtick : call My_Update() |