MESSAGES
Function
-Wpd
None
None
None
None
This option prompts the Compiler to issues an ERROR message instead of a WARNING message when an implicit declaration is encountered. This occurs if the Compiler does not have a prototype for the called function.
This option helps to prevent parameter-passing errors, which can only be detected at runtime. It requires that each function that is called is prototyped before use. The correct ANSI behavior is to assume that parameters are correct for the stated call.
This option is the same as using -WmsgSe1801.
-Wpd
main() {
char a, b;
func(a, b); // <- Error here - only two parameters
}
func(a, b, c)
char a, b, c;
{
...
}