summaryrefslogtreecommitdiff
path: root/scripts/checkpatch.pl
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2015-10-05 14:45:55 +0200
committerPaolo Bonzini <pbonzini@redhat.com>2015-10-12 18:29:26 +0200
commit5b906129524d564d61760d04586d6c2301457ead (patch)
tree8875533dbee57dd054fd8648db2ac29934a536b7 /scripts/checkpatch.pl
parent32857f4d5e165329c03d66000d666975d85f882a (diff)
downloadqemu-5b906129524d564d61760d04586d6c2301457ead.tar.gz
checkpatch: allow open braces on typedef lines
The style here seems to be split according to the maintainer, but traditionally open braces were placed on typedef lines. Suggested-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'scripts/checkpatch.pl')
-rwxr-xr-xscripts/checkpatch.pl5
1 files changed, 0 insertions, 5 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index b6d71eae17..d51346a4f9 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -1704,11 +1704,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);