Commit b337d8b8 authored by Andy Whitcroft's avatar Andy Whitcroft Committed by Linus Torvalds

checkpatch: add [] to type extensions

Add [] to a type extensions.  Fixes false positives on:

    .attrs = (struct attribute *[]) {
Signed-off-by: default avatarAndy Whitcroft <apw@canonical.com>
Cc: Joe Perches <joe@perches.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent fd1b57ac
...@@ -323,7 +323,7 @@ sub build_types { ...@@ -323,7 +323,7 @@ sub build_types {
}x; }x;
$Type = qr{ $Type = qr{
$NonptrType $NonptrType
(?:[\s\*]+\s*const|[\s\*]+|(?:\s*\[\s*\])+)? (?:(?:\s|\*|\[\])+\s*const|(?:\s|\*|\[\])+|(?:\s*\[\s*\])+)?
(?:\s+$Inline|\s+$Modifier)* (?:\s+$Inline|\s+$Modifier)*
}x; }x;
$Declare = qr{(?:$Storage\s+)?$Type}; $Declare = qr{(?:$Storage\s+)?$Type};
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment