This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320F28379D: Is there an issue with nested switch statements?

Part Number: TMS320F28379D

Tool/software:

CCS has an issue properly formatting a nested switch statement.  Is there some device or compiler issue that I should be aware of?

"Correct Indentation" produces the formatting below:

The "case Receive16" should be one tab to the left, lining up with "case ReceiveCommand".  

  • I agree and interestingly, if you use "Source -> Format" (CTRL+SHIFT+F), it does exactly that. But when you use "Source -> Correct Indentation" (CTRL+I), it looks as it does in your screenshot. You can likely tweak the behavior by editing the Code Style -> Formatter settings. in the C/C++ Advanced settings.