Skip to content

Commit

Permalink
checkpatch: allow for type modifiers on multiple declarations
Browse files Browse the repository at this point in the history
Allow for type modifiers mid declaration on multiple declarations:

	struct mxser_mstatus ms, __user *msu = argp;

Reported by Jiri Slaby.

Signed-off-by: Andy Whitcroft <apw@shadowen.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
awhitcroft authored and torvalds committed Jul 24, 2008
1 parent 3c23214 commit 389a2fe
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions scripts/checkpatch.pl
Original file line number Diff line number Diff line change
Expand Up @@ -721,6 +721,10 @@ sub annotate_values {
print "DECLARE($1)\n" if ($dbg_values > 1);
$type = 'T';

} elsif ($cur =~ /^($Modifier)\s*/) {
print "MODIFIER($1)\n" if ($dbg_values > 1);
$type = 'T';

} elsif ($cur =~ /^(\#\s*define\s*$Ident)(\(?)/o) {
print "DEFINE($1,$2)\n" if ($dbg_values > 1);
$av_preprocessor = 1;
Expand Down

0 comments on commit 389a2fe

Please sign in to comment.