This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Halcogen generated code not MISRA compatible

Other Parts Discussed in Thread: HALCOGEN, TMS570LS0914

How to repoduce

1) In halcogen create simple TMS570LS0914 project

2) In Halcogen enable all drivers (add FEE driver).

3) Create new CSS project.

4) Add FlashApi library to project

5) Setup include options, enable strict ANSI

6) Select check to "required" MISRA rules

7) Compile!

Result - 768 warnings

I expect what when I use TI Halcogen tool to generate code, select "Use Texas Instruments Tools" and compile using TI  compiler, code must compile w/o errors.  Please fix MISRA errors, or add instructions for TI compiler to avoid misreporting errors.

For sample:

/*SAFETYMCUSW 122 S MR:20.11 <APPROVED> "Startup code(exit and abort need to be present)" */
/*SAFETYMCUSW 354 S MR:NA <APPROVED> " Startup code(Extern declaration present in the library)" */
#if defined(__TI_COMPILER_VERSION__)
#pragma diag_push
#pragma CHECK_MISRA ("-20.2")
#endif
extern void exit(int _status);
#if defined(__TI_COMPILER_VERSION__)
#pragma diag_pop
#endif