X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=parser.c;h=0c4fec0452b1633c4e10253115ee047fa85f8843;hb=5d50990437f0dfeccfd6fa44f74681ea94bbe4f2;hp=6b044243760c88b9de3f6363d97c8294baddccbd;hpb=d131bdbba35bab12311e07ccc47e697393002e7b;p=cparser diff --git a/parser.c b/parser.c index 6b04424..0c4fec0 100644 --- a/parser.c +++ b/parser.c @@ -2375,7 +2375,7 @@ warn_redundant_declaration: errorf(declaration->source_position, "static declaration of '%Y' follows non-static declaration", symbol); errorf(previous_declaration->source_position, "previous declaration of '%Y' was here", symbol); } else { - if (old_storage_class != STORAGE_CLASS_EXTERN) { + if (old_storage_class != STORAGE_CLASS_EXTERN && !is_function_definition) { goto warn_redundant_declaration; } if (new_storage_class == STORAGE_CLASS_NONE) {