GCC gives a warning implicit declaration of function foo
when you use foo()
before its declaration. Is there any GCC flag that would make treat this warning as error and stop compilation? Sometime it would save you some debugging work...
-Werror
will treat all warnings as errors. You can be more specific with -Werror-implicit-function-declaration
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.