27-09-2017, 10:00 AM
Dear community,
our analysis tool reports the following array initialization to violate rule 11.9 (macro NULL is the only permitted form of integer null pointer constant):
uint8 myBuffer[8] = {0u}; // with "typedef unsigned char uint8;"
Unfortunately, neither from the tool documentation nor from the MISRA documentation we can conclude why this "standard" construct would be non-compliant. Also we cannot see what the risk behind this deviation would be. Is this deviation false-positive? Does it introduce any portability, maintainability etc. risk?
Thanks for your support.
Frank
our analysis tool reports the following array initialization to violate rule 11.9 (macro NULL is the only permitted form of integer null pointer constant):
uint8 myBuffer[8] = {0u}; // with "typedef unsigned char uint8;"
Unfortunately, neither from the tool documentation nor from the MISRA documentation we can conclude why this "standard" construct would be non-compliant. Also we cannot see what the risk behind this deviation would be. Is this deviation false-positive? Does it introduce any portability, maintainability etc. risk?
Thanks for your support.
Frank
<t></t>