20-02-2012, 12:45 PM
The code fragment in file1.c needs a little more context in order to answer the question.
Is the intention that the definition of j occur outside of any block?
The initialisation of j seems to violate constraints because initialisers for objects with static storage duration must be constant expressions.
Please could you amend the example?
Is the intention that the definition of j occur outside of any block?
The initialisation of j seems to violate constraints because initialisers for objects with static storage duration must be constant expressions.
Please could you amend the example?
Posted by and on behalf of the MISRA C Working Group