CMSIS_5 icon indicating copy to clipboard operation
CMSIS_5 copied to clipboard

system headers (system_ARMxxxx) should include headers they require

Open 0xc0170 opened this issue 3 years ago • 1 comments

https://github.com/ARM-software/CMSIS_5/blob/develop/Device/ARM/ARMCM4/Include/system_ARMCM4.h#L41 - I checked couple of system headers like this one.

The workaround like this is required in whatever includes them:

// system_ARMCM55.h CMSIS header requires stdint.h, so include it first.
#include <stdint.h>
#include "system_ARMCM55.h"

system_ARMxxxx headers should include what they require and not require this workaround to applications. Or refactor the headers not being dependent on external headers (in this case stdint header).

0xc0170 avatar Jul 21 '22 11:07 0xc0170

System headers are typically not included directly but used through device header. I guess that's why this laziness never became a real issue.

JonatanAntoni avatar Jul 21 '22 12:07 JonatanAntoni