diff options
-rw-r--r-- | src/nvim/buffer.c | 2 | ||||
-rw-r--r-- | src/nvim/globals.h | 4 | ||||
-rw-r--r-- | src/nvim/mark.c | 2 | ||||
-rw-r--r-- | src/nvim/normal.c | 2 | ||||
-rw-r--r-- | src/nvim/pos.h | 1 | ||||
-rw-r--r-- | src/nvim/tag.c | 2 |
6 files changed, 6 insertions, 7 deletions
diff --git a/src/nvim/buffer.c b/src/nvim/buffer.c index 6e4e7afeb2..8cb4e32815 100644 --- a/src/nvim/buffer.c +++ b/src/nvim/buffer.c @@ -2446,7 +2446,7 @@ void get_winopts(buf_T *buf) */ pos_T *buflist_findfpos(buf_T *buf) { - static pos_T no_position = INIT_POS_T(1, 0, 0); + static pos_T no_position = { 1, 0, 0 }; wininfo_T *wip = find_wininfo(buf, FALSE); return (wip == NULL) ? &no_position : &(wip->wi_fpos); diff --git a/src/nvim/globals.h b/src/nvim/globals.h index 52c5d65512..004b3252da 100644 --- a/src/nvim/globals.h +++ b/src/nvim/globals.h @@ -602,7 +602,7 @@ EXTERN bool can_si INIT(= false); EXTERN bool can_si_back INIT(= false); // w_cursor before formatting text. -EXTERN pos_T saved_cursor INIT(= INIT_POS_T(0, 0, 0)); +EXTERN pos_T saved_cursor INIT(= { 0, 0, 0 }); /* * Stuff for insert mode. @@ -789,7 +789,7 @@ EXTERN int autocmd_bufnr INIT(= 0); // fnum for <abuf> on cmdline EXTERN char_u *autocmd_match INIT(= NULL); // name for <amatch> on cmdline EXTERN int did_cursorhold INIT(= false); // set when CursorHold t'gerd // for CursorMoved event -EXTERN pos_T last_cursormoved INIT(= INIT_POS_T(0, 0, 0)); +EXTERN pos_T last_cursormoved INIT(= { 0, 0, 0 }); EXTERN int postponed_split INIT(= 0); /* for CTRL-W CTRL-] command */ EXTERN int postponed_split_flags INIT(= 0); /* args for win_split() */ diff --git a/src/nvim/mark.c b/src/nvim/mark.c index 05f78c76bc..602648c27c 100644 --- a/src/nvim/mark.c +++ b/src/nvim/mark.c @@ -924,7 +924,7 @@ static void mark_adjust_internal(linenr_T line1, linenr_T line2, int i; int fnum = curbuf->b_fnum; linenr_T *lp; - static pos_T initpos = INIT_POS_T(1, 0, 0); + static pos_T initpos = { 1, 0, 0 }; if (line2 < line1 && amount_after == 0L) /* nothing to do */ return; diff --git a/src/nvim/normal.c b/src/nvim/normal.c index 49eef72a05..01e7ef6781 100644 --- a/src/nvim/normal.c +++ b/src/nvim/normal.c @@ -5443,7 +5443,7 @@ static void nv_csearch(cmdarg_T *cap) */ static void nv_brackets(cmdarg_T *cap) { - pos_T new_pos = INIT_POS_T(0, 0, 0); + pos_T new_pos = { 0, 0, 0 }; pos_T prev_pos; pos_T *pos = NULL; /* init for GCC */ pos_T old_pos; /* cursor position before command */ diff --git a/src/nvim/pos.h b/src/nvim/pos.h index 0a2afd5847..47d253e083 100644 --- a/src/nvim/pos.h +++ b/src/nvim/pos.h @@ -24,7 +24,6 @@ typedef struct { colnr_T coladd; } pos_T; -# define INIT_POS_T(l, c, ca) {l, c, ca} /* * Same, but without coladd. diff --git a/src/nvim/tag.c b/src/nvim/tag.c index 50397d40e6..75bad047ac 100644 --- a/src/nvim/tag.c +++ b/src/nvim/tag.c @@ -109,7 +109,7 @@ static char_u *tagmatchname = NULL; /* name of last used tag */ * Tag for preview window is remembered separately, to avoid messing up the * normal tagstack. */ -static taggy_T ptag_entry = {NULL, {INIT_POS_T(0, 0, 0), 0, 0, NULL}, 0, 0}; +static taggy_T ptag_entry = { NULL, { { 0, 0, 0 }, 0, 0, NULL }, 0, 0 }; /* * Jump to tag; handling of tag commands and tag stack |