diff options
author | KunMing Xie <qqzz014@gmail.com> | 2018-01-31 03:29:15 +0800 |
---|---|---|
committer | Justin M. Keyes <justinkz@gmail.com> | 2018-01-30 20:29:15 +0100 |
commit | 8728a5d50bc3339db81c7f29d59c55f9f817f06c (patch) | |
tree | e5ecd3e8bc2310d35889731dacf2cbcab38887dd /src/nvim/search.c | |
parent | 2a1a624878ec70caf1e61b7440a6b9e4dce6c36f (diff) | |
download | rneovim-8728a5d50bc3339db81c7f29d59c55f9f817f06c.tar.gz rneovim-8728a5d50bc3339db81c7f29d59c55f9f817f06c.tar.bz2 rneovim-8728a5d50bc3339db81c7f29d59c55f9f817f06c.zip |
vim-patch:8.0.0448: some macros are lower case (#7936)
Problem: Some macros are in lower case, which can be confusing.
Solution: Make a few lower case macros upper case.
https://github.com/vim/vim/commit/b5aedf3e228d35821591da9ae8501b61cf2e264c
ref #6297
Diffstat (limited to 'src/nvim/search.c')
-rw-r--r-- | src/nvim/search.c | 25 |
1 files changed, 16 insertions, 9 deletions
diff --git a/src/nvim/search.c b/src/nvim/search.c index 0a266382ec..6e56f5f25d 100644 --- a/src/nvim/search.c +++ b/src/nvim/search.c @@ -2227,10 +2227,11 @@ int findsent(int dir, long count) break; found_dot = TRUE; } - if (decl(&pos) == -1) + if (decl(&pos) == -1) { break; - /* when going forward: Stop in front of empty line */ - if (lineempty(pos.lnum) && dir == FORWARD) { + } + // when going forward: Stop in front of empty line + if (LINEEMPTY(pos.lnum) && dir == FORWARD) { incl(&pos); goto found; } @@ -2534,10 +2535,12 @@ int bck_word(long count, int bigword, int stop) */ while (cls() == 0) { if (curwin->w_cursor.col == 0 - && lineempty(curwin->w_cursor.lnum)) + && LINEEMPTY(curwin->w_cursor.lnum)) { goto finished; - if (dec_cursor() == -1) /* hit start of file, stop here */ + } + if (dec_cursor() == -1) { // hit start of file, stop here return OK; + } } /* @@ -2601,10 +2604,12 @@ int end_word(long count, int bigword, int stop, int empty) */ while (cls() == 0) { if (empty && curwin->w_cursor.col == 0 - && lineempty(curwin->w_cursor.lnum)) + && LINEEMPTY(curwin->w_cursor.lnum)) { goto finished; - if (inc_cursor() == -1) /* hit end of file, stop here */ + } + if (inc_cursor() == -1) { // hit end of file, stop here return FAIL; + } } /* @@ -2657,10 +2662,12 @@ bckend_word ( * Move backward to end of the previous word */ while (cls() == 0) { - if (curwin->w_cursor.col == 0 && lineempty(curwin->w_cursor.lnum)) + if (curwin->w_cursor.col == 0 && LINEEMPTY(curwin->w_cursor.lnum)) { break; - if ((i = dec_cursor()) == -1 || (eol && i == 1)) + } + if ((i = dec_cursor()) == -1 || (eol && i == 1)) { return OK; + } } } return OK; |