04-11-2015, 02:51 PM
Does MISRA-C 2012 mandate prototypes for functions with internal linkage?
While MISRA-C 2012 rule 8.4 is very explicit about prototypes for functions with external linkage, we have not found a corresponding rule for internally linked functions.
Our static analysis tool takes the simplistic approach that prototypes are required in any case due to MISRA-C 2004 8.1 rule. I like to challenge its reasoning.
Thanks.
While MISRA-C 2012 rule 8.4 is very explicit about prototypes for functions with external linkage, we have not found a corresponding rule for internally linked functions.
Our static analysis tool takes the simplistic approach that prototypes are required in any case due to MISRA-C 2004 8.1 rule. I like to challenge its reasoning.
Thanks.