diff options
author | Andy Whitcroft <apw@canonical.com> | 2012-03-23 18:02:18 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-03-23 19:58:36 -0400 |
commit | b337d8b82f235d0212f7adcaeb431fd4e688bb98 (patch) | |
tree | 1caccc45dbd1edfec3ff4d02e268f76444330ccf /scripts/checkpatch.pl | |
parent | fd1b57ac73f169a5ba7a9569989aad40184f6340 (diff) |
checkpatch: add [] to type extensions
Add [] to a type extensions. Fixes false positives on:
.attrs = (struct attribute *[]) {
Signed-off-by: Andy Whitcroft <apw@canonical.com>
Cc: Joe Perches <joe@perches.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'scripts/checkpatch.pl')
-rwxr-xr-x | scripts/checkpatch.pl | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index ec58d3152e71..07d718415c5c 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl | |||
@@ -323,7 +323,7 @@ sub build_types { | |||
323 | }x; | 323 | }x; |
324 | $Type = qr{ | 324 | $Type = qr{ |
325 | $NonptrType | 325 | $NonptrType |
326 | (?:[\s\*]+\s*const|[\s\*]+|(?:\s*\[\s*\])+)? | 326 | (?:(?:\s|\*|\[\])+\s*const|(?:\s|\*|\[\])+|(?:\s*\[\s*\])+)? |
327 | (?:\s+$Inline|\s+$Modifier)* | 327 | (?:\s+$Inline|\s+$Modifier)* |
328 | }x; | 328 | }x; |
329 | $Declare = qr{(?:$Storage\s+)?$Type}; | 329 | $Declare = qr{(?:$Storage\s+)?$Type}; |