HP Code Advisor Diagnostics Reference Guide (5900-1865, July 2011)

Action:
The recommended way to declare a function that takes no parameters is to use "void" in the
parameter list.
Reference:
2.114 4244 extern storage class used with a function definition
Cause:
The compiler has detected the usage of an extern storage class specifier with a function definition.
Example:
extern int foo() {
return 0;
}
Action:
Remove the extern storage class specifier in function definition.
Reference:
2.115 4245 storage class used with a data definition
Cause:
The compiler has detected the usage of an extern storage class specifier with a data definition.
Example:extern int i = 1;
Action:
Remove the extern storage class specifier in the data definition.
Reference:
2.116 4247 function called with different argument counts (%s vs. %s2)
Cause:
Two calls to an unprototyped function differ in the number of arguments being passed, at least one
of these calls is passing wrong arguments.
Example:
int main() {
foo(10);
foo(10, 100);
}
Action:
Correct the function call which is passing wrong number of arguments. Preferably declare the
function before calling it.
Reference:
2.117 4248 comparison of unsigned integer with a signed integer
Cause:
This occurs due to mixing signed and unsigned operands with relational operators <, ≤, >, ≥.
One of the operands in signed and the other unsigned. The signed quantity may be negative as
well.
Example:
int a = -1;
unsigned int b = 1;
2.114 4244 extern storage class used with a function definition 57