Mirror of the lttng-dev mailing list
 help / color / mirror / Atom feed
From: christian.babeux@efficios.com (Christian Babeux)
Subject: [lttng-dev] [PATCH lttng-tools 2/3] Extras: Change TYPE of braces around single statement warning in checkpatch
Date: Mon,  7 Jan 2013 17:12:41 -0500	[thread overview]
Message-ID: <1357596762-14132-2-git-send-email-christian.babeux@efficios.com> (raw)
In-Reply-To: <1357596762-14132-1-git-send-email-christian.babeux@efficios.com>

Change the TYPE of the "braces {} are not necessary for single statement
blocks" warning from BRACES to BRACES_SINGLE_STMT in order to correctly
ignore this particular warning and continue to warn for other BRACES warnings.

Signed-off-by: Christian Babeux <christian.babeux at efficios.com>
---
 extras/checkpatch.pl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/extras/checkpatch.pl b/extras/checkpatch.pl
index 4d2c7df..7b2d29b 100755
--- a/extras/checkpatch.pl
+++ b/extras/checkpatch.pl
@@ -3198,7 +3198,7 @@ sub process {
 					$herectx .= raw_line($linenr, $n) . "\n";
 				}
 
-				WARN("BRACES",
+				WARN("BRACES_SINGLE_STMT",
 				     "braces {} are not necessary for single statement blocks\n" . $herectx);
 			}
 		}
-- 
1.8.0.2




  reply	other threads:[~2013-01-07 22:12 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-07 22:12 [lttng-dev] [PATCH lttng-tools 1/3] Extras: Add the checkpatch coding style script Christian Babeux
2013-01-07 22:12 ` Christian Babeux [this message]
2013-01-07 22:12 ` [lttng-dev] [PATCH lttng-tools 3/3] Extras: Add a checkpatch git pre-commit hook to detect style issue Christian Babeux
2013-01-10 17:54 ` [lttng-dev] [PATCH lttng-tools 1/3] Extras: Add the checkpatch coding style script David Goulet

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1357596762-14132-2-git-send-email-christian.babeux@efficios.com \
    --to=christian.babeux@efficios.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox