Level 2: Minor

Arrays, structures, unions and bit-fields

MessageMessage Text
0693 Struct initializer is missing the optional {.
0694 Array initializer is missing the optional {.
0750 A union type specifier has been defined.
0759 An object of union type has been defined.
3111 Redundant comma at end of braced initializer will be ignored.
3617 Assignment of a struct/union by value.
3621 A bit-field is being defined as a member of a struct or union.
3623 Passing a struct/union by value as a function argument.
3624 Function returns a struct/union by value.
3659 Unnamed zero-width bit-field declared with a signed type.
3660 Named bit-field consisting of a single bit declared with a signed type.
3661 Plain int bit-field compared with zero.
3662 Plain int bit-field compared with negative constant.
3663 Unnamed bit-field defined with non-zero width.
3665 Unnamed bit-field consisting of a single bit declared with a signed type.
3674 Array size defined implicitly by the number of initializers.
3684 Array declared with unknown size.

Arithmetic type - Assignment

MessageMessage Text
1256 An integer constant suffixed with L is being converted to type signed or unsigned long long on assignment.
1257 An integer constant suffixed with L or LL is being converted to a type of lower rank on assignment.
1264 A suffixed floating constant is being converted to a different floating type on assignment.
1265 An unsuffixed floating constant is being converted to a different floating type on assignment.
1266 A floating constant is being converted to integral type on assignment.
1290 An integer constant of 'essentially signed' type is being converted to unsigned type on assignment.
1291 An integer constant of 'essentially unsigned' type is being converted to signed type on assignment.
1292 An integer constant of 'essentially signed' type is being converted to type char on assignment.
1293 An integer constant of 'essentially unsigned' type is being converted to type char on assignment.
1294 An integer constant of 'essentially signed' type is being converted to type _Bool on assignment.
1295 An integer constant of 'essentially unsigned' type is being converted to type _Bool on assignment.
1298 An integer constant of 'essentially signed' type is being converted to floating type on assignment.
1299 An integer constant of 'essentially unsigned' type is being converted to floating type on assignment.
4413 An expression of 'essentially character' type (%1s) is being converted to signed type, '%2s' on assignment.
4414 An expression of 'essentially character' type (%1s) is being converted to unsigned type, '%2s' on assignment.
4423 An expression of 'essentially enum' type (%1s) is being converted to signed type, '%2s' on assignment.
4424 An expression of 'essentially enum' type (%1s) is being converted to unsigned type, '%2s' on assignment.
4431 An expression of 'essentially signed' type (%1s) is being converted to character type, '%2s' on assignment.
4435 A non-constant expression of 'essentially signed' type (%1s) is being converted to floating type, '%2s' on assignment.
4436 A constant expression of 'essentially signed' type (%1s) is being converted to unsigned type, '%2s' on assignment.
4437 A constant expression of 'essentially signed' type (%1s) is being converted to floating type, '%2s' on assignment.
4441 An expression of 'essentially unsigned' type (%1s) is being converted to character type, '%2s' on assignment.
4443 A non-constant expression of 'essentially unsigned' type (%1s) is being converted to a wider signed type, '%2s' on assignment.
4445 An expression of 'essentially unsigned' type (%1s) is being converted to floating type, '%2s' on assignment.
4446 A non-constant expression of 'essentially unsigned' type (%1s) is being converted to signed type, '%2s' on assignment.
4447 A constant expression of 'essentially unsigned' type (%1s) is being converted to signed type, '%2s' on assignment.
4463 A constant expression of 'essentially signed' type (%1s) is being converted to narrower signed type, '%2s' on assignment.
4464 A constant expression of 'essentially unsigned' type (%1s) is being converted to narrower unsigned type, '%2s' on assignment.
4465 A constant expression of 'essentially floating' type (%1s) is being converted to narrower floating type, '%2s' on assignment.
4470 A non-constant expression of 'essentially signed' type (%1s) is being passed to a function parameter of wider signed type, '%2s'.
4471 A non-constant expression of 'essentially unsigned' type (%1s) is being passed to a function parameter of wider unsigned type, '%2s'.
4472 A non-constant expression of 'essentially floating' type (%1s) is being passed to a function parameter of wider floating type, '%2s'.
4480 A non-constant expression of 'essentially signed' type (%1s) is being returned from a function defined with a wider signed return type, '%2s'.
4481 A non-constant expression of 'essentially unsigned' type (%1s) is being returned from a function defined with a wider unsigned return type, '%2s'.
4482 A non-constant expression of 'essentially floating' type (%1s) is being returned from a function defined with a wider floating return type, '%2s'.
4498 An expression which is the result of a ~ or << operation has been converted to a different essential type category on assignment.
4499 An expression which is the result of a ~ or << operation has been converted to a wider essential type on assignment.

Arithmetic type - Balancing

MessageMessage Text
1250 Unsuffixed integer constant causes implicit conversion of other operand.
1251 Suffixed integer constant causes implicit conversion of other operand.
1252 Suffixed integer constant implicitly converted to different integer type.
1253 Unsuffixed integer constant implicitly converted to different integer type.
1260 Integer constant implicitly converted to a floating type.
1261 Suffixed floating constant implicitly converted to different floating type.
1262 Unsuffixed floating constant implicitly converted to different floating type.
1263 Floating constant causes implicit conversion of other (integral) operand.
1274 Unsuffixed floating constant causes implicit conversion of other (floating) operand.
1275 Suffixed floating constant causes implicit conversion of other (floating) operand.
1800 The %1s operand (essential type: '%2s') will be implicitly converted to a floating type, '%3s', in this arithmetic operation.
1840 The %1s operand is constant, 'essentially signed' (%2s) and non-negative but will be implicitly converted to an unsigned type (%3s) in this arithmetic operation.
1841 The %1s operand is constant, 'essentially signed' (%2s) and non-negative but will be implicitly converted to an unsigned type (%3s) in this bitwise operation.
1842 The %1s operand is constant, 'essentially signed' (%2s) and non-negative but will be implicitly converted to an unsigned type (%3s) in this relational operation.
1843 The %1s operand is constant, 'essentially signed' (%2s) and non-negative but will be implicitly converted to an unsigned type (%3s) in this equality operation.
1844 The %1s operand is constant, 'essentially signed' (%2s) and non-negative but will be implicitly converted to an unsigned type (%3s) in this conditional operation.
1850 The %1s operand is 'essentially unsigned' (%2s) but will be implicitly converted to a signed type (%3s) in this arithmetic operation.
1851 The %1s operand is 'essentially unsigned' (%2s) but will be implicitly converted to a signed type (%3s) in this bitwise operation.
1852 The %1s operand is 'essentially unsigned' (%2s) but will be implicitly converted to a signed type (%3s) in this relational operation.
1853 The %1s operand is 'essentially unsigned' (%2s) but will be implicitly converted to a signed type (%3s) in this equality operation.
1854 The %1s operand is 'essentially unsigned' (%2s) but will be implicitly converted to a signed type (%3s) in this conditional operation.
1860 The operands of this arithmetic operator are of different 'essential signedness' but will generate a result of type 'signed int'.
1861 The operands of this bitwise operator are of different 'essential signedness' but will generate a result of type 'signed int'.
1862 The operands of this relational operator are of different 'essential signedness' but will both be promoted to 'signed int' for comparison.
1863 The operands of this equality operator are of different 'essential signedness' but will both be promoted to 'signed int' for comparison.
1864 The 2nd and 3rd operands of this conditional operator are of different 'essential signedness'. The result will be in the promoted type 'signed int'.
1880 The operands of this relational operator are expressions of different 'essential type' categories (%1s and %2s).
1881 The operands of this equality operator are expressions of different 'essential type' categories (%1s and %2s).
1882 The 2nd and 3rd operands of this conditional operator are expressions of different 'essential type' categories (%1s and %2s).

Arithmetic type - Casts

MessageMessage Text
1258 Suffixed integer constant cast to a different integral type.
1259 Unsuffixed integer constant cast to a different integral type.
1267 Suffixed floating constant cast to another type.
1268 Unsuffixed floating constant cast to another type.
1269 Floating constant cast to integral type.
4302 An expression of 'essentially Boolean' type (%1s) is being cast to enum type '%2s'.
4303 An expression of 'essentially Boolean' type (%1s) is being cast to signed type '%2s'.
4304 An expression of 'essentially Boolean' type (%1s) is being cast to unsigned type '%2s'.
4320 An expression of 'essentially enum' type (%1s) is being cast to Boolean type, '%2s'.
4322 An expression of 'essentially enum' type (%1s) is being cast to a different enum type, '%2s'.
4325 An expression of 'essentially enum' type (%1s) is being cast to floating type, '%2s'.
4330 An expression of 'essentially signed' type (%1s) is being cast to Boolean type '%2s'.
4332 An expression of 'essentially signed' type (%1s) is being cast to enum type, '%2s'.
4340 An expression of 'essentially unsigned' type (%1s) is being cast to Boolean type '%2s'.
4342 An expression of 'essentially unsigned' type (%1s) is being cast to enum type '%2s'.
4397 An expression which is the result of a ~ or << operation has not been cast to its essential type.
4398 An expression which is the result of a ~ or << operation has been cast to a different essential type category.
4399 An expression which is the result of a ~ or << operation has been cast to a wider type.

Arithmetic type - Composite expressions

MessageMessage Text
1890 A composite expression of 'essentially signed' type (%1s) is being implicitly converted to a wider signed type, '%2s'.
1891 A composite expression of 'essentially unsigned' type (%1s) is being implicitly converted to a wider unsigned type, '%2s'.
1892 A composite expression of 'essentially floating' type (%1s) is being implicitly converted to a wider floating type, '%2s'.
1893 The 2nd and 3rd operands of this conditional operator are both 'essentially signed' ('%1s' and '%2s') but one is a composite expression of a narrower type than the other.
1894 The 2nd and 3rd operands of this conditional operator are both 'essentially unsigned' ('%1s' and '%2s') but one is a composite expression of a narrower type than the other.
1895 The 2nd and 3rd operands of this conditional operator are both 'essentially floating' ('%1s' and '%2s') but one is a composite expression of a narrower type than the other.
4390 A composite expression of 'essentially signed' type (%1s) is being cast to a wider signed type, '%2s'.
4391 A composite expression of 'essentially unsigned' type (%1s) is being cast to a wider unsigned type, '%2s'.
4392 A composite expression of 'essentially floating' type (%1s) is being cast to a wider floating type, '%2s'.
4393 A composite expression of 'essentially signed' type (%1s) is being cast to a different type category, '%2s'.
4394 A composite expression of 'essentially unsigned' type (%1s) is being cast to a different type category, '%2s'.
4395 A composite expression of 'essentially floating' type (%1s) is being cast to a different type category, '%2s'.
4490 A composite expression of 'essentially signed' type (%1s) is being converted to wider signed type, '%2s' on assignment.
4491 A composite expression of 'essentially unsigned' type (%1s) is being converted to wider unsigned type, '%2s' on assignment.
4492 A composite expression of 'essentially floating' type (%1s) is being converted to wider floating type, '%2s' on assignment.

Arithmetic type - Integral promotion

MessageMessage Text
2100 Integral promotion : unsigned char promoted to signed int.
2101 Integral promotion : unsigned short promoted to signed int.
2102 Integral promotion : unsigned char promoted to unsigned int.
2103 Integral promotion : unsigned short promoted to unsigned int.
2104 Integral promotion : signed char promoted to signed int.
2105 Integral promotion : signed short promoted to signed int.
2106 Integral promotion : plain char promoted to signed int.
2107 Integral promotion : plain char promoted to unsigned int.
2109 Integral promotion : _Bool promoted to signed int.
2110 Default argument promotion : unsigned char promoted to signed int.
2111 Default argument promotion : unsigned short promoted to signed int.
2112 Default argument promotion : unsigned char promoted to unsigned int.
2113 Default argument promotion : unsigned short promoted to unsigned int.
2114 Default argument promotion : signed char promoted to signed int.
2115 Default argument promotion : signed short promoted to signed int.
2116 Default argument promotion : plain char promoted to signed int.
2117 Default argument promotion : plain char promoted to unsigned int.
2118 Default argument promotion : float promoted to double.
2119 Default argument promotion : _Bool promoted to signed int.
2120 Integral promotion : unsigned bit-field promoted to signed int.
2122 Integral promotion : unsigned bit-field promoted to unsigned int.
2124 Integral promotion : signed bit-field promoted to signed int.
2130 Default argument promotion : unsigned bit-field promoted to signed int.
2132 Default argument promotion : unsigned bit-field promoted to unsigned int.
2134 Default argument promotion : signed bit-field promoted to signed int.

Arithmetic type - Operands

MessageMessage Text
4101 Both operands of & operator are 'Boolean' expressions.
4102 Both operands of | operator are 'Boolean' expressions.
4103 Both operands of arithmetic or bitwise operator are 'Boolean' expressions.
4104 Left hand operand of arithmetic or bitwise operator is a 'Boolean' expression.
4105 Right hand operand of arithmetic or bitwise operator is a 'Boolean' expression.
4106 Both operands of && operator are arithmetic or bitwise expressions.
4107 Both operands of || operator are arithmetic or bitwise expressions.
4108 Left hand operand of logical operator is an arithmetic or bitwise expression.
4109 Right hand operand of logical operator is an arithmetic or bitwise expression.
4110 Operand of ! operator is an arithmetic or bitwise expression.
4111 Right hand operand of relational operator is a 'Boolean' expression.
4112 Left hand operand of relational operator is a 'Boolean' expression.
4113 Both operands of relational operator are 'Boolean' expressions.
4114 Operand of ~ operator is a 'Boolean' expression.
4115 Operand of logical && or || operator is not an 'essentially Boolean' expression.
4116 Operand of logical ! operator is not an 'essentially Boolean' expression.
4517 An expression of 'essentially character' type (%1s) is being used as the operand of this increment/decrement operator (%2s).
4518 An expression of 'essentially character' type (%1s) is being used as the %2s operand of this logical operator (%3s).
4519 An expression of 'essentially character' type (%1s) is being used as the first operand of this conditional operator (%2s).
4521 An expression of 'essentially enum' type (%1s) is being used as the %2s operand of this arithmetic operator (%3s).
4522 An expression of 'essentially enum' type (%1s) is being used as the %2s operand of this bitwise operator (%3s).
4523 An expression of 'essentially enum' type (%1s) is being used as the left-hand operand of this shift operator (%2s).
4524 An expression of 'essentially enum' type (%1s) is being used as the right-hand operand of this shift operator (%2s).
4527 An expression of 'essentially enum' type is being used as the operand of this increment/decrement operator.
4528 An expression of 'essentially enum' type (%1s) is being used as the %2s operand of this logical operator (%3s).
4529 An expression of 'essentially enum' type (%1s) is being used as the first operand of this conditional operator (%2s).
4534 An expression of 'essentially signed' type (%1s) is being used as the right-hand operand of this shift operator (%2s).
4538 An expression of 'essentially signed' type (%1s) is being used as the %2s operand of this logical operator (%3s).
4539 An expression of 'essentially signed' type (%1s) is being used as the first operand of this conditional operator (%2s).
4542 A non-negative constant expression of 'essentially signed' type (%1s) is being used as the %2s operand of this bitwise operator (%3s).
4543 A non-negative constant expression of 'essentially signed' type (%1s) is being used as the left-hand operand of this shift operator (%2s).
4544 A non-negative constant expression of 'essentially signed' type (%1s) is being used as the right-hand operand of this shift operator (%2s).
4548 A non-negative constant expression of 'essentially signed' type (%1s) is being used as the %2s operand of this logical operator (%3s).
4549 A non-negative constant expression of 'essentially signed' type (%1s) is being used as the first operand of this conditional operator (%2s).
4558 An expression of 'essentially unsigned' type (%1s) is being used as the %2s operand of this logical operator (%3s).
4559 An expression of 'essentially unsigned' type (%1s) is being used as the first operand of this conditional operator (%2s).
4568 An expression of 'essentially floating' type (%1s) is being used as the %2s operand of this logical operator (%3s).
4569 An expression of 'essentially floating' type (%1s) is being used as the first operand of this conditional operator (%2s).
4570 The operand of this ~ operator has an 'essential type' which is narrower than type 'int'.
4571 The left-hand operand of this << operator has an 'essential type' which is narrower than type 'int'.

Arithmetic type - Operations

MessageMessage Text
0702 Result of sizeof operator is not explicitly cast.
3103 Result of signed division or remainder operation may be implementation defined.
3212 This cast is redundant.
3226 The result of an assignment is being used in an arithmetic operation or another assigning operation.
3417 The comma operator has been used outside a 'for' statement.
3418 The comma operator has been used in a 'for' statement.
3440 Using the value resulting from a ++ or -- operation.
3491 Using conditional operator in a macro.
3492 Using conditional operator outside a macro.
3495 Using a conditional operator in place of a selection statement.
3892 The result of this cast is implicitly converted to another type.

Bracing and Indentation

MessageMessage Text
2200 Indentation of this line is to the left of the line above.
2201 This indentation is not consistent with previous indentation in this file.
2203 This closing brace is not aligned appropriately with the matching opening brace.
2204 '%s' is not aligned to match its controlling 'switch' statement.
2205 More than one declaration or statement on the same line.
2207 This brace style is not consistent with 'K&R' style.
2208 This brace style is not consistent with 'indented' style.
2209 This brace style is not consistent with 'exdented' style.
2210 Tab character encountered in this line.
2211 '%s' is not aligned with the previously declared identifier.
2212 Body of control statement is not enclosed within braces.
2213 Matching braces appear on the same line - proper indentation would be preferred.
2214 Body of control statement is on the same line and is not enclosed within braces.
2215 This indentation is not consistent with configured depth.
2216 More than one structure or union member declared on the same line.
2217 Line length exceeds %s characters.
3402 Braces are needed to clarify the structure of this 'if'-'if'-'else' statement.

C++ compatibility

MessageMessage Text
1300 '%s' is a keyword in C++.
1301 '%s' is a keyword in some C++ implementations.
1303 An empty parameter list in a function type has a different meaning in C++.
1305 The global object '%s' declared 'const' has external linkage in C but internal linkage in C++.
1306 Multiple tentative definitions of '%s'. This is not allowed in C++.
1307 Unnamed 'struct' and 'union' types may cause portability problems when moving to C++.
1308 The tag '%s' would clash with an existing typedef in C++.
1309 The typedef '%s' would clash with an existing 'struct' / 'union' / 'enum' tag in C++.
1314 The tag '%s' is defined within another 'struct' / 'union'.
1318 Object of enum type is being modified with a compound assignment operator.
1319 Object of enum type is being modified with an increment or decrement operator.
1322 In C, sizeof('c') == sizeof(int), but in C++, sizeof('c') == sizeof(char) == 1.
1324 Function 'main' cannot be called or have its address taken in C++.
1327 The macro __STDC__ has been used. It may not be present in a C++ environment.
1329 The global object '%s' declared 'const' has been defined without an explicit initializer. This is not allowed in C++.

CMA declaration checks

MessageMessage Text
1500 The object 'name' is declared but is not used within this project.
1501 The function 'name' is declared but is not used within this project.
1502 The object 'name' is defined but is not used within this project.
1503 The function 'name' is defined but is not used within this project.

CMA maintenance checks

MessageMessage Text
1504 The object 'name' is only referenced in the translation unit where it is defined.
1505 The function 'name' is only referenced in the translation unit where it is defined.
1506 The identifier 'name' is declared as a typedef and is used elsewhere for a different kind of declaration.
1507 'name' is used as a typedef for different types.
1508 The typedef 'name' is declared in more than one location.
1512 Identifier 'name' with external linkage has separate declarations in multiple translation units.
1513 Identifier 'name' with external linkage has separate non-defining declarations in more than one location.
1514 The object 'entity' is only referenced by function 'func', in the translation unit where it is defined
1515 Different files are being used which have the same filename 'filename'.
1516 Different files are being used which have similar filenames 'filename', but with different case.
1517 Different files are being used which have the same filename 'filename', and one includes the other.
1520 Functions are indirectly recursive.
1525 Object/function with external linkage has same identifier as another object/function with internal linkage.
1526 Object with no linkage has same identifier as another object/function with external linkage.
1527 Object/function with internal linkage has same identifier as another object/function with internal linkage.
1528 Object with no linkage has same identifier as another object/function with internal linkage.
1529 Object with no linkage has same identifier as another object with static storage duration but no linkage.
1531 The object 'name' is referenced in only one translation unit - but not the one in which it is defined.
1532 The function '%1s' is only referenced in one translation unit - but not the one in which it is defined.
1533 The object 'entity' is only referenced by function 'func'.

Constants

MessageMessage Text
0336 Macro defined as an octal constant.
0339 Octal constant used.
0878 Using wide character or string literals.
1254 Suffix is not consistent with a type of unsigned long.
1255 Unsuffixed integer constant is not of type int.
1272 Redundant leading zeroes on a numeric constant.
1277 Hex constant does not include a "U" suffix.
1278 Decimal constant includes a suffix.
1279 Hex constant includes an "L" suffix.
1280 A lowercase letter L (l) has been used in an integer or floating suffix.
1281 Integer literal constant is of an unsigned type but does not include a "U" suffix.
3120 Hard-coded 'magic' integer constant, '%s'.
3121 Hard-coded 'magic' floating constant, '%s'.
3122 Hard-coded 'magic' string literal, %s.
3123 Hard coded 'magic' character constant, %s.
3131 Hard coded 'magic' number, '%s', used to define the size of a bit-field.
3132 Hard coded 'magic' number, '%s', used to define the size of an array.
3601 Trigraphs (??x) are an ISO feature.
3610 Hexadecimal escape sequence used.
3613 Some pre-ISO compilers would treat this 8 or 9 as an octal digit.
3626 Double-quote character in a character constant is not preceded by a backslash character.
3627 Single-quote character in a string literal is not preceded by a backslash character.
3628 Octal escape sequences used in a character constant or string literal.

Control flow

MessageMessage Text
0769 A 'break' statement has been used to terminate an iteration statement.
0770 A 'continue' statement has been used.
0771 More than one 'break' statement has been used to terminate this iteration statement.
2000 No 'else' clause exists for this 'if' statement.
2001 A 'goto' statement has been used.
2004 No concluding 'else' exists in this 'if'-'else'-'if' statement.
2015 A statement 'label' has been used.
2461 Loop control variable, %s, has file scope.
2462 The variable initialized in the first expression of this 'for' statement is not the variable identified as the 'loop control variable' (%s).
2463 The variable incremented in the third expression of this 'for' statement is not the variable identified as the 'loop control variable' (%s).
2464 Loop control variable, %s, modified twice in for-loop header.
2467 Loop control variable, %s, is not modified inside loop.
2468 Loop control variable, %s, is not modified inside loop but has file scope.
2469 Loop control variable in this 'for' statement, %s, is modified in the body of the loop.
2470 Taking address of loop control variable, %s.
2471 Unable to identify a loop control variable.
2472 More than one possible loop control variable.
3314 This controlling expression is an assignment.
3333 A 'break' statement has been used in the middle of a 'switch' 'case'/'default' clause.
3340 Floating point variable used as 'for' loop control variable.
3342 Controlling expression of 'for' loop is a floating point comparison.
3344 Controlling expression is not an 'essentially Boolean' expression.

Declarations and Definitions

MessageMessage Text
0553 Translation unit contains no object or function definitions with external linkage.
0606 Object '%s' is declared using typedefs which are different to those in a previous declaration.
0624 Function '%s' is declared using typedefs which are different to those in a previous declaration.
0790 This translation unit makes use of floating types.
2007 'auto' does not add information to a declaration, and is best avoided.
2011 The 'register' storage class specifier has been used.
2022 A tentative definition is being used. Is it appropriate to include an explicit initializer ?
2050 The 'int' type specifier has been omitted from a function declaration.
2051 The 'int' type specifier has been omitted from an object declaration.
3204 The variable '%s' is only set once and so it could be declared with the 'const' qualifier.
3211 The global identifier '%s' is defined here but is not used in this translation unit.
3218 File scope static, '%s', is only accessed in one function.
3220 Identifier declared at a nested level of block scope.
3221 Function with external linkage declared at block scope.
3222 Object with external linkage declared at block scope.
3223 Object with static storage duration declared at block scope.
3224 This identifier has previously been declared with internal linkage but is not declared here with the static storage class specifier.
3227 The parameter '%s' is never modified and so it could be declared with the 'const' qualifier.
3228 Storage class specifier not positioned at the beginning of declaration.
3232 File scope static, '%s', is never modified. It could be declared const.
3233 File scope static, '%s', is not explicitly initialized but its value is used.
3308 'static %s()' has been declared but no definition has been provided. This is redundant.
3313 No definition has been found for structure/union tag '%s'.
3408 '%s' has external linkage and is being defined without any previous declaration.
3447 '%s' is being declared with external linkage but this declaration is not in a header file.
3448 Declaration of typedef '%s' is not in a header file although it is used in a definition or declaration with external linkage.
3450 Function '%s', with internal linkage, is being defined without a previous declaration.
3451 The global identifier '%s' has been declared in more than one file.
3625 Type 'char' has been used in the declaration of an object or a function.
3629 Union contains member of floating type.
3631 Type 'char' has been used in a cast.
3632 Type 'char' has been used in the declaration of a typedef.
3633 Type 'char' has been used in the operand of the sizeof operator.

Enumerations

MessageMessage Text
0722 Enum constant not explicitly initialized, but a previous constant has been.
0723 Initialize none, first only, or all entries in this enumerator list.
1271 Using a non-int expression to define an enum constant.
1317 Value of constant expression is not in the enum type to which it is being converted.
1323 The sizeof operator has been applied to an enum constant.
1434 This enum constant is not representable in a 16 bit integer type.
1461 Value of constant expression is not in the enum type to which it is being converted, but is bitwise OR of constants in the enum type.
1475 Range of possible enum values suggests this test is always true.
1476 Range of possible enum values suggests this test is always false.
1477 Object of enum type is being implicitly compared against zero in a controlling expression.
1478 Object of an enum type which does not include a zero value, is being implicitly compared against zero in a controlling expression.

Functions

MessageMessage Text
0428 Function identifier is not followed by () but a function call may be intended.
0652 Identifiers have been provided for some but not all of the parameters in a function prototype.
1302 '%s()' must be declared before use in C++.
1304 Old style definition of function '%s()' is not portable to C++.
1325 '%s()' is defined with a non-void return type but contains 'return;'. This is not allowed in C++.
1330 The parameter identifiers in this function declaration differ from those in a previous declaration.
1334 The parameter identifiers in the prototypes of these functions/function pointers are different.
1335 Parameter identifiers missing in function prototype declaration.
1336 Parameter identifiers missing in declaration of a function type.
1337 Function defined with a variable number of parameters.
3001 Function has been declared with an empty parameter list.
3006 This function contains a mixture of in-line assembler statements and C statements.
3007 "void" has been omitted when defining a function with no parameters.
3200 '%s' returns a value which is not being used.
3208 '%s()' returns a value which is sometimes ignored.
3209 '%s()' returns a value which is always ignored.
3240 inline function '%s' is being defined with external linkage.
3243 inline function '%s' is also an 'external definition'.
3330 '%s()' has been called with a variable number of arguments.
3607 Parameter '%s' declared with function type in a K&R style function definition.
3635 Function identifier used as a pointer without a preceding & operator.
3671 Function called via pointer to function.
3672 Using non-const pointer to function.
3675 Function parameter declared with type qualification which differs from previous declaration.

Identifiers

MessageMessage Text
0780 Another identifier '%s' is already in scope in a different namespace.
0781 '%s' is being used as a structure/union member as well as being a label, tag or ordinary identifier.
0782 This identifier, '%s', will still be in scope when the same identifier is declared later in a different namespace.
0783 A subsequent declaration of '%s' means that it is being used both as a structure/union member and also as a label, tag or ordinary identifier.
1100 The label '%s' is also declared as a typedef.
1310 '%s' is used as a tag and a typedef for the same 'struct' / 'union' / 'enum'.
4150 The identifier '%s' may cause confusion because it contains only the letter 'l' and and the number '1'.
4151 The identifier '%s' may cause confusion because it contains only the letter 'O' and the number '0'.
4152 The identifier '%s' may cause confusion because the letter 'l' and the number '1' are adjacent.
4153 The identifier '%s' may cause confusion because the letter 'O' and the number '0' are adjacent.
4600 The macro '%1s' is also defined in '<%2s>'.
4601 The macro '%1s' is the name of an identifier in '<%2s>'.
4602 The identifier '%1s' is declared as a macro in '<%2s>'.
4603 The object/function '%1s'is being defined with the same name as an ordinary identifier defined in '<%2s>'.
4604 The object/function '%1s' is being declared with the same name as an ordinary identifier defined in '<%2s>'.
4605 The typedef '%1s' is also defined in '<%2s>'.
4606 The typedef '%1s' has the same name as another ordinary identifier in '<%2s>'.
4607 The enum constant '%1s' has the same name as another ordinary identifier in '<%2s>'.
4608 The tag '%1s' is also defined in '<%2s>'.
4620 The macro '%1s' may also be defined as a macro in '<%2s>'.
4621 The macro '%1s' may also be defined as a typedef in '<%2s>'.
4622 The identifier '%1s' may be defined as a macro in '<%2s>'.
4623 The typedef '%1s' may also be defined in '<%2s>'.
4624 The ordinary identifier '%1s' may be defined as a typedef in '<%2s>'.
4640 The macro '%1s' could conflict in the future with the name of a macro in '<%2s>'.
4641 The identifier '%1s' could conflict in the future with the name of a macro in '<%2s>'.
4642 The macro '%1s' could conflict in the future with the name of a function in '<%2s>'.
4643 The identifier '%1s' could conflict in the future with the name of a function in '<%2s>'.
4644 The macro '%1s' could conflict in the future with the name of a typedef in '<%2s>'.
4645 The identifier '%1s' could conflict in the future with the name of a typedef in '<%2s>'.

K+R compatibility

MessageMessage Text
0340 Using the '#error' preprocessing directive.
0341 Using the stringify operator '#'.
0342 Using the glue operator '##'.
0343 Using string literal concatenation.
0344 Using function prototype syntax.
0345 Using the keyword 'void'.
0346 Using one of the keywords 'signed', 'const' or 'volatile'.
0347 Using 'extern' in the definition of a global variable.
0348 Using a bit-field.
0349 Using the unary '+' operator.
0350 Using the keyword 'enum'.
0351 Using an initializer when defining an automatic object of struct, union or array type.
0352 Using the '#elif' preprocessing directive.
1483 Enum object or constant passed as argument to function declared in K&R style.
3600 Using the unary '+' operator.
3602 Using one of the keywords 'signed', 'const', 'volatile' or 'enum'.
3603 Using 'extern' in the definition of a global variable.
3604 Using an initializer when defining an automatic object of struct, union or array type.
3605 Type of 'switch' controlling expression cannot be represented in type 'int'.
3606 This unsuffixed decimal constant has type 'long', but had type 'unsigned int' in K&R C.
3608 Using the '#elif' preprocessing directive.
3609 Using the alert escape sequence '\\a'.
3615 Using 'entry' as an identifier.
3618 Whitespace used after '#' at the start of this preprocessing directive.
3619 Whitespace used before '#' at the start of this preprocessing directive.

Macro Definition

MessageMessage Text
0880 Using # and ## operators in the same macro definition.
0881 Using multiple ## operators in the same macro definition.
3409 The replacement list of function-like macro '%s' is not enclosed in ().
3410 Macro parameter not enclosed in ().
3411 Macro defined with unbalanced brackets, parentheses or braces.
3412 Macro defines an unrecognized code-fragment.
3413 Macro definition could be replaced by a typedef.
3414 Macro defines a storage-class or function specifier keyword.
3428 Macro defines a type qualifier keyword.
3429 A function-like macro is being defined.
3431 Macro defines an operator, a punctuator or a control statement keyword.
3439 Macro redefines a keyword.
3443 Macro '%s' has a replacement list which appears recursive.
3452 The replacement list of object-like macro '%s' is not enclosed in ().
3453 A function could probably be used instead of this function-like macro.
3456 Parameter '%s' will be evaluated more than once when this macro is used.
3457 Macro defines a braced initializer.
3458 Macro defines a braced code statement block.
3459 Macro defines a 'do-while-zero' construct.
3460 Macro defines a type specifier keyword.
3461 Macro defines a storage-class specifier/type qualifier sequence.

Metric thresholds

MessageMessage Text
4700 Metric value out of threshold range: %s.

Pointers

MessageMessage Text
0303 [I] Cast between a pointer to volatile object and an integral type.
0305 [I] Cast between a pointer to function and an integral type.
0306 [I] Cast between a pointer to object and an integral type.
0308 Non-portable cast involving pointer to an incomplete type.
0310 Casting to different object pointer type.
0313 Casting to different function pointer type.
0314 [I] Cast from a pointer to object type to a pointer to void.
0315 [I] Implicit conversion from a pointer to object type to a pointer to void.
0316 [I] Cast from a pointer to void to a pointer to object type.
0317 [I] Implicit conversion from a pointer to void to a pointer to object type.
0488 Performing pointer arithmetic.
0489 The integer value 1 is being added or subtracted from a pointer.
0490 Relational operator used to compare two pointers.
0491 Array subscripting applied to an object of pointer type.
0492 Array subscripting applied to a function parameter declared as a pointer.
0752 String literal passed as argument to function whose parameter is not a 'pointer to const'.
0753 String literal assigned to pointer which is not a 'pointer to const'.
3004 This integral constant expression is being interpreted as a NULL pointer constant.
3216 Address of local static object exported to a pointer with linkage or wider scope.
3231 Address of local static object exported using a function parameter.
3260 Typedef defined with more than 2 levels of indirection.
3261 Member of struct/union defined with more than 2 levels of indirection.
3262 Object defined or declared with more than 2 levels of indirection.
3263 Function defined or declared with a return type which has more than 2 levels of indirection.
3673 The object addressed by the pointer parameter '%s' is not modified and so the pointer could be of type 'pointer to const'.
4139 Address of local static object exported in function return value.

Preprocessing

MessageMessage Text
0832 Macro substitution in #include preprocessing directive.
0838 File '%1s' has already been included directly from within file '%2s'.
0839 File '%1s' has already been included indirectly from within file '%2s'.
0841 Using '#undef'.
0842 Using #define or #undef inside a function.
0843 / character used in an include file name.
0868 An absolute path has been specified in a #include statement.
0882 The forceinclude file '%s' is redundant in this translation unit.
0883 Include file code is not protected against repeated inclusion
0884 Using multiple # operators in the same macro definition.
0889 #undef refers to a macro that has previously been #undef'd.
0890 #ifdef refers to a macro that has been #undef'd in a previous #if block.
0891 #ifdef refers to a macro that has been #undef'd previously.
1690 Null preprocessing directive used.
1691 Null preprocessing directive used in an excluded section of code.
2017 Comment spans more than one line.
3106 This preprocessing directive has been ignored because it lies within a #pragma block. #pragma '%s' expected.
3108 Nested comments are not recognized in the ISO standard.
3115 Unrecognized preprocessing directive has been ignored because of conditional inclusion directives.
3116 Unrecognized #pragma arguments '%s' This #pragma directive has been ignored.
3117 Expected 'on' or 'off' after '#pragma' flag.
3118 Using the #line preprocessing directive.
3430 Macro argument expression may require parentheses.
3454 Macro argument contains an increment, decrement or assignment operator.
3455 Macro argument contains a function call.
3616 Character constants may have different values in preprocessor arithmetic than in actual code.

Readability

MessageMessage Text
3109 Null statement follows other code on the same line.
3138 Null statement is located close to other code or comments.
3139 Null statement is obscured by code or comment on the same line.
3140 Null statement occurs on a line by itself.
3141 Null statement does not occur on a line by itself.
3389 Extra parentheses recommended to clarify the ordering of a % operator and another arithmetic operator (* / % + -).
3391 Extra parentheses recommended. A conditional operation is the operand of another conditional operator.
3392 Extra parentheses recommended. A shift, relational or equality operation is the operand of a second identical operator.
3393 Extra parentheses recommended. An arithmetic operation (* / + -) is the operand of a different operator with the same precedence.
3394 Extra parentheses recommended. A shift, relational or equality operation is the operand of a different operator with the same precedence.
3395 Extra parentheses recommended. A * or / operation is the operand of a + or - operator.
3396 Extra parentheses recommended. A binary operation is the operand of a conditional operator.
3397 Extra parentheses recommended. A binary operation is the operand of a binary operator with different precedence.
3398 Extra parentheses recommended. A function call, array subscript, or member operation is the operand of a logical && or ||.
3399 Extra parentheses recommended. A unary operation is the operand of a logical && or ||.
3400 Extra parentheses recommended. A binary operation is the operand of a logical && or ||.
3403 This sequence of operators is difficult to read without intervening spaces.
3501 Absence of space between assignment operator and following unary operator may cause confusion.

Redundancy

MessageMessage Text
0318 Redundant type qualifier used in cast
0861 This #include <%s> directive is redundant.
0862 This #include "%s" directive is redundant.
3202 The label '%s:' is not used in this function and could be removed.
3205 The identifier '%s' is not used and could be removed.
3206 The parameter '%s' is not used in this function.
3207 File scope static, '%s', is not used, and could be removed.
3210 The global identifier '%s' is declared here but is not used in this translation unit.
3219 Static function '%s()' is not used within this translation unit.
3470 The operand of 'sizeof' is not an expression which designates either an object or a type.

Side Effects

MessageMessage Text
3307 The operand of 'sizeof' is an expression with implied side effects, but they will not be evaluated.
3345 Statement contains more than one access to objects that are volatile.
3415 Right hand operand of '&&' or '||' is an expression with possible side effects.
3416 Logical operation performed on expression with possible side effects.
3441 Function call argument is an expression with possible side effects.
3442 Operator other than & (address-of) or = (assignment) applied to a volatile object.
3446 The 2nd or 3rd operand of this conditional operator is an expression with possible side effects.

Switch statements

MessageMessage Text
0597 Type of 'case' label expression is not consistent with type of controlling expression in 'switch' statement.
2002 No 'default' label found in this 'switch' statement.
2003 The preceding 'switch' clause is not empty and does not end with a 'jump' statement. Execution will fall through.
2009 This 'default' label is not the final 'case' label within the 'switch' block.
2016 This 'switch' statement 'default' clause is empty.
2020 Final 'switch' clause does not end with an explicit 'jump' statement.

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