aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/getchar.c
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2016-05-01 17:30:38 -0400
committerJustin M. Keyes <justinkz@gmail.com>2016-05-01 17:30:38 -0400
commitd542de4a76dd9e600ebcf1405efdc9d3090ad9a8 (patch)
tree60b1d2aad6205c74b7c2611fbbed45759a302f4f /src/nvim/getchar.c
parent91afb30b667bbc321d351708f694d00b256be585 (diff)
parentcf4e1fb0f4962319eee292248d9c1f73be3a8d0c (diff)
downloadrneovim-d542de4a76dd9e600ebcf1405efdc9d3090ad9a8.tar.gz
rneovim-d542de4a76dd9e600ebcf1405efdc9d3090ad9a8.tar.bz2
rneovim-d542de4a76dd9e600ebcf1405efdc9d3090ad9a8.zip
Merge pull request #4688 from ZyX-I/clint-checks
Add check for boolean operators placement
Diffstat (limited to 'src/nvim/getchar.c')
-rw-r--r--src/nvim/getchar.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/nvim/getchar.c b/src/nvim/getchar.c
index 43cdd7a033..050862d811 100644
--- a/src/nvim/getchar.c
+++ b/src/nvim/getchar.c
@@ -2669,13 +2669,14 @@ do_map (
p = keys;
do_backslash = (vim_strchr(p_cpo, CPO_BSLASH) == NULL);
while (*p && (maptype == 1 || !ascii_iswhite(*p))) {
- if ((p[0] == Ctrl_V || (do_backslash && p[0] == '\\')) &&
- p[1] != NUL)
- ++p; /* skip CTRL-V or backslash */
- ++p;
+ if ((p[0] == Ctrl_V || (do_backslash && p[0] == '\\')) && p[1] != NUL) {
+ p++; // skip CTRL-V or backslash
+ }
+ p++;
}
- if (*p != NUL)
+ if (*p != NUL) {
*p++ = NUL;
+ }
p = skipwhite(p);
rhs = p;