Why "'X' used but never defined" is a warning and not error in gcc?

Ilya Basin basinilya@gmail.com
Mon Oct 8 10:19:00 GMT 2012


test.c:
    static void foo();
    
    void bar() {
        foo();
    }

$ gcc -c test.c
test.c:1: warning: 'foo' used but never defined

Why warning and not error? Another *.o can refer this static function?



More information about the Gcc-help mailing list