aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/mark.c
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2022-06-14 21:57:08 +0800
committerGitHub <noreply@github.com>2022-06-14 21:57:08 +0800
commit8ba64dd3ad1822efd6f986349e99f5f85afd7be7 (patch)
tree66b2987707cf6616614fb251d7e342ccdfd96c28 /src/nvim/mark.c
parent2a2fb8be74f9147773416be63334ea6a74c66869 (diff)
parent0a0cda95286bf62fbce2776a0c0081cea39a88a8 (diff)
downloadrneovim-8ba64dd3ad1822efd6f986349e99f5f85afd7be7.tar.gz
rneovim-8ba64dd3ad1822efd6f986349e99f5f85afd7be7.tar.bz2
rneovim-8ba64dd3ad1822efd6f986349e99f5f85afd7be7.zip
Merge pull request #18947 from zeertzjq/vim-8.2.1897
vim-patch:8.2.{1897,1898,5088}
Diffstat (limited to 'src/nvim/mark.c')
-rw-r--r--src/nvim/mark.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/nvim/mark.c b/src/nvim/mark.c
index 7b7441ebcf..8d1a917600 100644
--- a/src/nvim/mark.c
+++ b/src/nvim/mark.c
@@ -171,7 +171,7 @@ void setpcmark(void)
xfmark_T *fm;
// for :global the mark is set only once
- if (global_busy || listcmd_busy || cmdmod.keepjumps) {
+ if (global_busy || listcmd_busy || (cmdmod.cmod_flags & CMOD_KEEPJUMPS)) {
return;
}
@@ -990,7 +990,7 @@ static void mark_adjust_internal(linenr_T line1, linenr_T line2, linenr_T amount
return;
}
- if (!cmdmod.lockmarks) {
+ if ((cmdmod.cmod_flags & CMOD_LOCKMARKS) == 0) {
// named marks, lower case and upper case
for (i = 0; i < NMARKS; i++) {
ONE_ADJUST(&(curbuf->b_namedm[i].mark.lnum));
@@ -1059,7 +1059,7 @@ static void mark_adjust_internal(linenr_T line1, linenr_T line2, linenr_T amount
* Adjust items in all windows related to the current buffer.
*/
FOR_ALL_TAB_WINDOWS(tab, win) {
- if (!cmdmod.lockmarks) {
+ if ((cmdmod.cmod_flags & CMOD_LOCKMARKS) == 0) {
// Marks in the jumplist. When deleting lines, this may create
// duplicate marks in the jumplist, they will be removed later.
for (i = 0; i < win->w_jumplistlen; i++) {
@@ -1070,7 +1070,7 @@ static void mark_adjust_internal(linenr_T line1, linenr_T line2, linenr_T amount
}
if (win->w_buffer == curbuf) {
- if (!cmdmod.lockmarks) {
+ if ((cmdmod.cmod_flags & CMOD_LOCKMARKS) == 0) {
// marks in the tag stack
for (i = 0; i < win->w_tagstacklen; i++) {
if (win->w_tagstack[i].fmark.fnum == fnum) {
@@ -1159,7 +1159,7 @@ void mark_col_adjust(linenr_T lnum, colnr_T mincol, linenr_T lnum_amount, long c
int fnum = curbuf->b_fnum;
pos_T *posp;
- if ((col_amount == 0L && lnum_amount == 0L) || cmdmod.lockmarks) {
+ if ((col_amount == 0L && lnum_amount == 0L) || (cmdmod.cmod_flags & CMOD_LOCKMARKS)) {
return; // nothing to do
}
// named marks, lower case and upper case