acassis commented on PR #15847:
URL: https://github.com/apache/nuttx/pull/15847#issuecomment-2672742681
> I have a question about this one:
>
> ```
> /work/NuttX/nuttx/arch/arm/src/cxd56xx/cxd56_dmac.c:316:10: error: Case
statement should be on a new line
> ```
>
> This is when a switch looks like this:
>
> ```
> static int ch2dmac(int ch)
> {
> switch (ch)
> {
> case 0: case 1:
> return 1;
> case 2: case 3: case 4: case 5: case 6: /* APP IDMAC */
> return 3;
> case 7: case 8: /* APP SKDMAC */
> return 2;
> default:
> return 0;
> }
> }
> ```
>
> Do we want to allow this shorthand format (like `case 0: case 1:`) or do
we want to force each case on a separate line?
I think two cases in the same line are not correct, probably it passed
because our nxstyle wasn't able to catch this kind of thing. It is better to
fix it
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]