aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/option.c
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2022-03-09 08:15:18 +0800
committerGitHub <noreply@github.com>2022-03-09 08:15:18 +0800
commit205b3765f2c04e3839b15a8d1ce79bd7ea8e4d3d (patch)
treeb3db8da594fd829224607a11d21b43b3d329b76f /src/nvim/option.c
parentf33cea4682340ea2b622fa879dd6fca2c80ea1d5 (diff)
parentff032f2710974dcf5930187f1925534da93db199 (diff)
downloadrneovim-205b3765f2c04e3839b15a8d1ce79bd7ea8e4d3d.tar.gz
rneovim-205b3765f2c04e3839b15a8d1ce79bd7ea8e4d3d.tar.bz2
rneovim-205b3765f2c04e3839b15a8d1ce79bd7ea8e4d3d.zip
Merge pull request #17622 from dundargoc/refactor/clang-tidy/remove-redundant-casts
refactor/clang tidy/remove redundant casts
Diffstat (limited to 'src/nvim/option.c')
-rw-r--r--src/nvim/option.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/nvim/option.c b/src/nvim/option.c
index 9068c90dd1..a0706dfa14 100644
--- a/src/nvim/option.c
+++ b/src/nvim/option.c
@@ -3851,7 +3851,7 @@ static bool parse_winhl_opt(win_T *wp)
if (strncmp("Normal", p, nlen) == 0) {
w_hl_id_normal = hl_id;
} else {
- for (hlf = 0; hlf < (int)HLF_COUNT; hlf++) {
+ for (hlf = 0; hlf < HLF_COUNT; hlf++) {
if (strlen(hlf_names[hlf]) == nlen
&& strncmp(hlf_names[hlf], p, nlen) == 0) {
w_hl_ids[hlf] = hl_id;
@@ -5267,7 +5267,7 @@ static void showoptions(int all, int opt_flags)
&& Columns + GAP >= INT_MIN + 3
&& (Columns + GAP - 3) / INC >= INT_MIN
&& (Columns + GAP - 3) / INC <= INT_MAX);
- cols = (int)((Columns + GAP - 3) / INC);
+ cols = (Columns + GAP - 3) / INC;
if (cols == 0) {
cols = 1;
}
@@ -5666,11 +5666,11 @@ void comp_col(void)
assert(sc_col >= 0
&& INT_MIN + sc_col <= Columns
&& Columns - sc_col <= INT_MAX);
- sc_col = (int)(Columns - sc_col);
+ sc_col = Columns - sc_col;
assert(ru_col >= 0
&& INT_MIN + ru_col <= Columns
&& Columns - ru_col <= INT_MAX);
- ru_col = (int)(Columns - ru_col);
+ ru_col = Columns - ru_col;
if (sc_col <= 0) { // screen too narrow, will become a mess
sc_col = 1;
}