[previous] 1335 [next] Parameter identifiers missing in function prototype declaration.
Functions

In this prototype declaration of a function, the parameter types have been specified but not the parameter names.

Supplying names for parameters in a function declaration has no semantic significance but it does improve readability. Message 1335 is only generated when parameter names are missing in the declaration of a named function. Message 1336 is generated when parameter names are missing in the declaration of a function type, for example in a typedef or when defining a pointer to a function.

For example:


/*PRQA S 553,2017,3205,3210,3447,3672 ++*/

extern int foo1(int, float);            /* Message 1335 */

typedef int (typ1)(int, float);         /* Message 1336 */

extern int (*pf1)(int);                 /* Message 1336 */

See also:

QA·C Source Code Analyser 8.1.2
© 2013 Programming Research.
www.programmingresearch.com
Personality Groups | Glossary | Message Index Contents