diff options
author | Dundar Göc <gocdundar@gmail.com> | 2022-03-06 12:40:31 +0100 |
---|---|---|
committer | Dundar Göc <gocdundar@gmail.com> | 2022-03-06 23:02:10 +0100 |
commit | ff032f2710974dcf5930187f1925534da93db199 (patch) | |
tree | 0791529e147a564b35f87880832583641ecae01c /src/nvim/option.c | |
parent | 918ab6bf0064d5d147d3b10a56fb4f95d355c171 (diff) | |
download | rneovim-ff032f2710974dcf5930187f1925534da93db199.tar.gz rneovim-ff032f2710974dcf5930187f1925534da93db199.tar.bz2 rneovim-ff032f2710974dcf5930187f1925534da93db199.zip |
refactor: remove redundant casts
Diffstat (limited to 'src/nvim/option.c')
-rw-r--r-- | src/nvim/option.c | 8 |
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; } |