Broad Mapping: JPL

This table contains broad mappings between JPL rule numbers and CodeSonar warning classes.

The close mapping from JPL rule numbers to CodeSonar warning classes is shown in JPL Checks.

A CSV version of this table is provided in JPL-mapping-broad.csv

JPL C/C++ Warning Classes
JPL:1 Do not stray outside the language definition.
closely mapped
JPL:2 Compile with all warnings enabled; use static source code analyzers.
closely mapped
JPL:3 Use verifiable loop bounds for all loops meant to be terminating.
closely mapped
JPL:4 Do not use direct or indirect recursion.
closely mapped
JPL:5 Do not use dynamic memory allocation after task initialization.
closely mapped
JPL:7 Do not use task delays for task synchronization.
closely mapped
JPL:9 Place restrictions on the use of semaphores and locks.
closely mapped
JPL:11 Do not use goto, setjmp or longjmp.
closely mapped
JPL:12 Do not use selective value assignments to elements of an enum list.
closely mapped
JPL:13 Declare data objects at smallest possible level of scope.
closely mapped
JPL:14 Check the return value of non-void functions, or explicitly cast to (void).
closely mapped
JPL:15 Check the validity of values passed to functions.
closely mapped
JPL:16 Use static and dynamic assertions as sanity checks.
closely mapped
JPL:17 Use U32, I16, etc instead of predefined C data types such as int, short, etc.
closely mapped
JPL:18 Make the order of evaluation in compound expressions explicit.
closely mapped
JPL:19 Do not use expressions with side effects.
closely mapped
also related
JPL:20 Make only very limited use of the C pre-processor.
closely mapped
JPL:21 Do not define macros within a function or a block.
closely mapped
JPL:22 Do not undefine or redefine macros.
closely mapped
JPL:23 Place #else, #elif, and #endif in the same file as the matching #if or #ifdef.
closely mapped
JPL:24 Place no more than one statement or declaration per line of text.
closely mapped
JPL:25 Use short functions with a limited number of parameters.
closely mapped
JPL:26 Use no more than two levels of indirection per declaration.
closely mapped
JPL:27 Use no more than two levels of dereferencing per object reference.
closely mapped
JPL:28 Do not hide dereference operations inside macros or typedefs.
closely mapped
JPL:30 Do not cast function pointers into other types.
closely mapped
JPL:31 Do not place code or declarations before an #include directive.
closely mapped