History

checkpatch: Allow comments in macros tested for single statements

Convert all the comments to spaces before testing for single statement macros.

Joe Perches committed 11 years ago

Commit 1b36b201 parent 327953e1 file · +1 −0Browse files

Unified · Split

scripts/checkpatch.pl+1−0
@@ -4260,6 +4260,7 @@ sub process { · 4259 unmodified lines
42604260 $ctx = $dstat;
42614261
42624262 $dstat =~ s/\\\n.//g;
4263+ $dstat =~ s/$;/ /g;
42634264
42644265 if ($dstat =~ /^\+\s*#\s*define\s+$Ident\s*${balanced_parens}\s*do\s*{(.*)\s*}\s*while\s*\(\s*0\s*\)\s*([;\s]*)\s*$/) {
42654266 my $stmts = $2;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t