From f764947c731fbc65d33aceb4da3e25513a2013c6 Mon Sep 17 00:00:00 2001 From: Johanne Schock Date: Mon, 9 Mar 2020 16:16:06 +0100 Subject: [PATCH] Signal error for multiline comment right of #if --- tools/nxstyle.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tools/nxstyle.c b/tools/nxstyle.c index 71ca4c2815..9b7baddafc 100644 --- a/tools/nxstyle.c +++ b/tools/nxstyle.c @@ -968,6 +968,12 @@ int main(int argc, char **argv, char **envp) /* Signal rhcomment, but ignore position */ rhcomment = -1; + + if (ncomment > 0 && !strncmp(&line[ii], "if", 2)) + { + ERROR("No multiline comment right of code allowed here", + lineno, n); + } } }