aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/nvim/edit.c1
-rw-r--r--src/nvim/eval.c7
-rw-r--r--src/nvim/option.c6
-rw-r--r--src/nvim/quickfix.c3
-rw-r--r--src/nvim/screen.c1
-rw-r--r--src/nvim/viml/parser/expressions.c2
6 files changed, 12 insertions, 8 deletions
diff --git a/src/nvim/edit.c b/src/nvim/edit.c
index 6355000175..a3487e012a 100644
--- a/src/nvim/edit.c
+++ b/src/nvim/edit.c
@@ -3110,6 +3110,7 @@ void get_complete_info(list_T *what_list, dict_T *retdict)
? compl_curr_match->cp_number - 1 : -1);
}
+ (void)ret;
// TODO(vim):
// if (ret == OK && (what_flag & CI_WHAT_INSERTED))
}
diff --git a/src/nvim/eval.c b/src/nvim/eval.c
index 38df22a2cb..d13b5965f9 100644
--- a/src/nvim/eval.c
+++ b/src/nvim/eval.c
@@ -16032,10 +16032,12 @@ static void f_sign_getplaced(typval_T *argvars, typval_T *rettv, FunPtr fptr)
}
if ((di = tv_dict_find(dict, "lnum", -1)) != NULL) {
// get signs placed at this line
- lnum = tv_get_lnum(&di->di_tv);
- if (lnum <= 0) {
+ lnum = (linenr_T)tv_get_number_chk(&di->di_tv, &notanum);
+ if (notanum) {
return;
}
+ (void)lnum;
+ lnum = tv_get_lnum(&di->di_tv);
}
if ((di = tv_dict_find(dict, "id", -1)) != NULL) {
// get sign placed with this identifier
@@ -16164,6 +16166,7 @@ static void f_sign_place(typval_T *argvars, typval_T *rettv, FunPtr fptr)
if (notanum) {
goto cleanup;
}
+ (void)lnum;
lnum = tv_get_lnum(&di->di_tv);
}
if ((di = tv_dict_find(dict, "priority", -1)) != NULL) {
diff --git a/src/nvim/option.c b/src/nvim/option.c
index 35151ab81c..40c1358fa5 100644
--- a/src/nvim/option.c
+++ b/src/nvim/option.c
@@ -3508,7 +3508,9 @@ static char_u *set_chars_option(win_T *wp, char_u **varp)
{
int round, i, len, entries;
char_u *p, *s;
- int c1 = 0, c2 = 0, c3 = 0;
+ int c1;
+ int c2 = 0;
+ int c3 = 0;
struct chars_tab {
int *cp; ///< char value
@@ -3575,7 +3577,7 @@ static char_u *set_chars_option(win_T *wp, char_u **varp)
if (STRNCMP(p, tab[i].name, len) == 0
&& p[len] == ':'
&& p[len + 1] != NUL) {
- c1 = c2 = c3 = 0;
+ c2 = c3 = 0;
s = p + len + 1;
// TODO(bfredl): use schar_T representation and utfc_ptr2len
diff --git a/src/nvim/quickfix.c b/src/nvim/quickfix.c
index 8c53c6d80d..1eb616bca7 100644
--- a/src/nvim/quickfix.c
+++ b/src/nvim/quickfix.c
@@ -2056,7 +2056,7 @@ static int qf_jump_to_usable_window(int qf_fnum, int *opened_window)
win_T *usable_win_ptr = NULL;
int usable_win;
int flags;
- win_T *win = NULL;
+ win_T *win;
win_T *altwin;
usable_win = 0;
@@ -2079,7 +2079,6 @@ static int qf_jump_to_usable_window(int qf_fnum, int *opened_window)
// Locate a window showing a normal buffer
FOR_ALL_WINDOWS_IN_TAB(win2, curtab) {
if (win2->w_buffer->b_p_bt[0] == NUL) {
- win = win2;
usable_win = 1;
break;
}
diff --git a/src/nvim/screen.c b/src/nvim/screen.c
index 877bd2db21..06f886d411 100644
--- a/src/nvim/screen.c
+++ b/src/nvim/screen.c
@@ -3143,7 +3143,6 @@ win_line (
c = '>';
mb_c = c;
mb_l = 1;
- mb_utf8 = false;
multi_attr = win_hl_attr(wp, HLF_AT);
// put the pointer back to output the double-width
diff --git a/src/nvim/viml/parser/expressions.c b/src/nvim/viml/parser/expressions.c
index dcc64db8a0..b4a0f57e99 100644
--- a/src/nvim/viml/parser/expressions.c
+++ b/src/nvim/viml/parser/expressions.c
@@ -2330,7 +2330,7 @@ viml_pexpr_parse_invalid_comma:
break;
} else if (eastnode_type == kExprNodeSubscript) {
is_subscript = true;
- can_be_ternary = false;
+ // can_be_ternary = false;
assert(!is_ternary);
break;
} else if (eastnode_type == kExprNodeColon) {