ci: enable clang-analyzer warnings

This adds the checks in https://neovim.io/doc/reports/clang/ when using
clang-tidy. The strategy is to enable all clang-analyzer checks, and
disable only the checks for the warnings that exist currently. This
allows us to eliminate each warning type without blocking ongoing work,
but also without adding bugs for already eliminated warnings.

The plan is to eventually eliminate https://neovim.io/doc/reports/clang/
by completely integrating it into the clang-tidy check.

Also add make and cmake targets `clang-analyzer` to run this check.
This commit is contained in:
dundargoc
2023-10-06 17:43:23 +02:00
committed by dundargoc
parent 55be4a4e26
commit 6c0f900699
4 changed files with 38 additions and 2 deletions

View File

@@ -5641,7 +5641,7 @@ void get_user_input(const typval_T *const argvars, typval_T *const rettv, const
rettv->v_type = VAR_STRING;
rettv->vval.v_string = NULL;
const char *prompt = "";
const char *prompt;
const char *defstr = "";
typval_T *cancelreturn = NULL;
typval_T cancelreturn_strarg2 = TV_INITIAL_VALUE;