[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH] checkpatch: allow open braces on typedef lines
From: |
Paolo Bonzini |
Subject: |
[Qemu-devel] [PATCH] checkpatch: allow open braces on typedef lines |
Date: |
Mon, 5 Oct 2015 14:46:08 +0200 |
The style here seems to be split according to the maintainer, but
traditionally open braces were placed on typedef lines.
Suggested-by: Peter Maydell <address@hidden>
Signed-off-by: Paolo Bonzini <address@hidden>
---
scripts/checkpatch.pl | 5 -----
1 file changed, 5 deletions(-)
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 3c19f9f..c814281 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -1714,11 +1714,6 @@ sub process {
ERROR("open brace '{' following $1 go on the same
line\n" . $hereprev);
}
-# ... however, open braces on typedef lines should be avoided.
- if ($line =~
/^.\s*typedef\s+(enum|union|struct)(?:\s+$Ident\b)?.*[^;]$/) {
- ERROR("typedefs should be separate from struct
declaration\n" . $herecurr);
- }
-
# missing space after union, struct or enum definition
if ($line =~
/^.\s*(?:typedef\s+)?(enum|union|struct)(?:\s+$Ident)?(?:\s+$Ident)?[=\{]/) {
ERROR("missing space after $1 definition\n" . $herecurr);
--
2.5.0
- [Qemu-devel] [PATCH] checkpatch: allow open braces on typedef lines,
Paolo Bonzini <=