diff options
author | James <89495599+IAKOBVS@users.noreply.github.com> | 2024-06-11 22:40:24 +0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-11 16:40:24 +0100 |
commit | c37695a5d5f2e8914fff86f3581bed70b4c85d3c (patch) | |
tree | 89c5f523768f3fe31a938e497fb7ff9657049e4b /src/nvim/indent.c | |
parent | 44410d063ad23544f87d1c8a553de336ae7939d8 (diff) | |
download | rneovim-c37695a5d5f2e8914fff86f3581bed70b4c85d3c.tar.gz rneovim-c37695a5d5f2e8914fff86f3581bed70b4c85d3c.tar.bz2 rneovim-c37695a5d5f2e8914fff86f3581bed70b4c85d3c.zip |
refactor: use S_LEN(s) instead of s, n (#29219)
Diffstat (limited to 'src/nvim/indent.c')
-rw-r--r-- | src/nvim/indent.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/nvim/indent.c b/src/nvim/indent.c index 66cb443e4d..a4964db465 100644 --- a/src/nvim/indent.c +++ b/src/nvim/indent.c @@ -782,20 +782,20 @@ bool briopt_check(win_T *wp) char *p = wp->w_p_briopt; while (*p != NUL) { // Note: Keep this in sync with p_briopt_values - if (strncmp(p, "shift:", 6) == 0 + if (strncmp(p, S_LEN("shift:")) == 0 && ((p[6] == '-' && ascii_isdigit(p[7])) || ascii_isdigit(p[6]))) { p += 6; bri_shift = getdigits_int(&p, true, 0); - } else if (strncmp(p, "min:", 4) == 0 && ascii_isdigit(p[4])) { + } else if (strncmp(p, S_LEN("min:")) == 0 && ascii_isdigit(p[4])) { p += 4; bri_min = getdigits_int(&p, true, 0); - } else if (strncmp(p, "sbr", 3) == 0) { + } else if (strncmp(p, S_LEN("sbr")) == 0) { p += 3; bri_sbr = true; - } else if (strncmp(p, "list:", 5) == 0) { + } else if (strncmp(p, S_LEN("list:")) == 0) { p += 5; bri_list = (int)getdigits(&p, false, 0); - } else if (strncmp(p, "column:", 7) == 0) { + } else if (strncmp(p, S_LEN("column:")) == 0) { p += 7; bri_vcol = (int)getdigits(&p, false, 0); } |