Skip to content

Latest commit

 

History

History
25 lines (21 loc) · 1.86 KB

File metadata and controls

25 lines (21 loc) · 1.86 KB

MISRA Compliance

The Device Shadow library files conform to the MISRA C:2012 guidelines, with some noted exceptions. Compliance is checked with Coverity static analysis. Deviations from the MISRA standard are listed below:

Deviation Category Justification
Directive 4.5 Advisory Allow names that MISRA considers ambiguous (such as LogInfo and LogError)
Directive 4.8 Advisory Allow inclusion of unused types. Header files for a specific port, which are needed by all files, may define types that are not used by a specific file.
Directive 4.9 Advisory Allow inclusion of function like macros. The assert macro is used throughout the library for parameter validation, and logging is done using function like macros.
Rule 2.3 Advisory Allow unused types. Library headers may define types intended for the application's use, but not used within the library files.
Rule 2.4 Advisory Allow unused tags. Some compilers warn if types are not tagged.
Rule 2.5 Advisory Allow unused macros. Library headers may define macros intended for the application's use, but are not used by a specific file.
Rule 3.1 Required Allow nested comments. C++ style // comments are used in example code within Doxygen documentation blocks.
Rule 11.5 Advisory Allow casts from void *. Fields may be passed as void *, requiring a cast to the correct data type before use.

Flagged by Coverity

Deviation Category Justification
Rule 8.7 Advisory API functions are not used by the library outside of the files they are defined; however, they must be externally visible in order to be used by an application.

Suppressed with Coverity Comments

None.