[previous] 1315 [next] The 'static' qualifier has been used in the declaration of a tag.
Declarations and definitions

The static storage class specifier is being applied to the declaration which defines a tag but doesn't define an object based on that tag. This is permitted in ISO:C Standard, but is meaningless; the "static" qualifier will simply be ignored. In C++ the statement is illegal.

For example:


/*PRQA S 0553,0750,2017,2211,2213,2216,3602,3629 ++*/


static struct ST { int a; int b; };         /* Message 1315 */
static union UN { float x; long m; };       /* Message 1315 */
static enum EN { A, B, C };                 /* Message 1315 */

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