build: enable -Wshadow

Note about shada.c:
- shada_read_next_item_start was intentionally shadowing `unpacked` and
  `i` because many of the macros (e.g. ADDITIONAL_KEY) implicitly
  depended on those variable names.
- Macros were changed to parameterize `unpacked` (but not `i`). Macros
  like CLEAR_GA_AND_ERROR_OUT do control-flow (goto), so any other
  approach is messy.
This commit is contained in:
Justin M. Keyes
2016-03-09 09:52:07 -05:00
parent 5fba815921
commit a70fde1b45
18 changed files with 178 additions and 166 deletions

View File

@@ -781,7 +781,6 @@ static void command_line_scan(mparm_T *parmp)
bool had_minmin = false; // found "--" argument
int want_argument; // option argument with argument
int c;
char_u *p = NULL;
long n;
argc--;
@@ -1227,7 +1226,7 @@ scripterror:
// Add the file to the global argument list.
ga_grow(&global_alist.al_ga, 1);
p = vim_strsave((char_u *)argv[0]);
char_u *p = vim_strsave((char_u *)argv[0]);
if (parmp->diff_mode && os_isdir(p) && GARGCOUNT > 0
&& !os_isdir(alist_name(&GARGLIST[0]))) {