MISRA Discussion Forums

Full Version: Rule 15.0 - Required or Adviosry?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
TC1 introduced the concept of rule 15.0.
However it does not explicitly state if this rule is "Required" or "Advisory"
Is rule 15.0 "required" or "advisory"?
IMHO, specifying the preamble text as rule "15.0" is somewhat confusing. I would suggest to change its wording to clearly identify the preamble to be a rule.
At the same time, the wording is clear: "... the syntax for switch statements as defined by MISRA-C and is normative". To me this means that 15.0 is required, possibly even stronger than normal 'required' rules. In my own responsibility, I would not allow deviations from rule 15.0, not even when commented heavily or using a genarlly accepted deviation procedure.
If such a deviation seems necessary, other contsructs (like chained if ... else if ... else) might be better suited for the occasion.

Best regards,

Johan
Rule 15.0 is required although this is not explicitly stated in TC1. Note that edition 2 of the MISRA-C:2004 Guidelines, which incorporates TC1, is explicit that the rule is required.
Clarification required, please:
Does this mean that edition 2 is more than the sum of edition 1 + TC1? So if I bought ed.1 and downloaded TC1, I still have less than ed.2?
Is an overview of the additional changes available separately?

TIA,

Johan Bezem
TC1 made all "supporting text" normative. The introductory text to Rules 15.x was made into Rule 15.0 in TC1. When the reprint of MISRA C2, and the corresponding PDF version, were prepared the text was more closely integrated including giving Rule 15.0 a title "The MISRA C switch syntax shall be used".

While there may be some minor editorial differences between edition 1 + TC1 and edition 2, the content is essentially the same.