Avoided "Variable 'XXX' is defined but never used" error message resulted from an earlier error.

This commit is contained in:
acqn 2023-12-09 17:33:46 +08:00
parent 519a52d92c
commit 87f8893886
1 changed files with 1 additions and 1 deletions

View File

@ -178,7 +178,7 @@ static void CheckSymTable (SymTable* Tab)
if (IS_Get (&WarnUnusedFunc)) {
Warning ("Function '%s' is defined but never used", Entry->Name);
}
} else {
} else if (!IsAnonName (Entry->Name)) {
if (IS_Get (&WarnUnusedVar)) {
Warning ("Variable '%s' is defined but never used", Entry->Name);
}