From: Andy Whitcroft Date: Thu, 24 Jul 2008 04:29:08 +0000 (-0700) Subject: checkpatch: handle return types of pointers to functions X-Git-Tag: v2.6.27-rc1~698 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8ea3eb9a20f39d5afa52900a34092b4b5f6b55cb;p=linux-2.6 checkpatch: handle return types of pointers to functions Make sure we correctly mark the return type of the pointer to a function declaration. const void *(*sb_tag)(struct sysfs_tag_info *info); Signed-off-by: Andy Whitcroft Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 775f2b146a..6d07b6778c 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -715,7 +715,7 @@ sub annotate_values { $av_preprocessor = 0; } - } elsif ($cur =~ /^($Type)\s*(?:$Ident|,|\))/) { + } elsif ($cur =~ /^($Type)\s*(?:$Ident|,|\)|\()/) { print "DECLARE($1)\n" if ($dbg_values > 1); $type = 'T';