LuchianMihai commented on code in PR #15847: URL: https://github.com/apache/nuttx/pull/15847#discussion_r1957369872
########## tools/nxstyle.c: ########## @@ -2042,6 +2033,17 @@ int main(int argc, char **argv, char **envp) { bswitch = true; } + else if (strncmp(&line[indent], "switch(", 7) == 0) + { + ERROR("Missing whitespace after keyword", lineno, n); + + bswitch = true; + } + else if (strncmp(&line[indent], "case ", 5) == 0 || + strncmp(&line[indent], "default ", 8) == 0) Review Comment: Nice catch, I find them both throughout the code base. I did not thought about that, both strncmp (for case and default) were already present in the nxstyle.c but thrown out with #if 0, I just copy-pasted that part. Will fix this also, thank you. -- 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: commits-unsubscr...@nuttx.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org