MISRA Discussion Forums

Full Version: Rule 2.1 deviation permit?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Typically, on embedded systems with a simple RTOS, main is used as background task, so it never returns:

Code:
int main(void)
{
  Setup_Rtos();
  for (;;)
  {
    Background_Task();
  }
  return 0;// Violates MISRA C 2012 2.1: unreachable code
}

Would this be a candidate for your deviation permits document?
Thank you for your suggestion for a deviation permit.