Lines Matching refs:file

35 my $file;
125 my ($name, $num, $col, $file, $line, $msg, $error) = @_;
145 enable_warn($name, $num, $file, $line);
168 print "$file:$num:$col: $w: $msg ($name)\n";
177 $file = shift @ARGV;
181 if($file =~ /-D(.*)/) {
183 $file = shift @ARGV;
186 elsif($file =~ /-W(.*)/) {
188 $file = shift @ARGV;
191 elsif($file =~ /-A(.+)/) {
193 $file = shift @ARGV;
196 elsif($file =~ /-i([1-9])/) {
198 $file = shift @ARGV;
201 elsif($file =~ /-m([0-9]+)/) {
203 $file = shift @ARGV;
206 elsif($file =~ /^(-h|--help)/) {
207 undef $file;
214 if(!$file) {
234 if("$wlist" !~ / $file /) {
235 my $fullname = $file;
236 $fullname = "$dir/$file" if ($fullname !~ '^\.?\.?/');
239 $file = shift @ARGV;
241 } while($file);
261 my ($file) = @_;
265 length($_)+11, $file,
273 my ($what, $line, $file, $l) = @_;
278 $line, length($what) + 11, $file, $l,
286 my ($cmd, $line, $file, $l) = @_;
311 $line, 0, $file, $l,
316 $line, 0, $file, $l,
326 enable_warn($what, $line, $file, $l);
330 $line, 0, $file, $l,
343 my ($file) = @_;
348 open(R, "<$file") || die "failed to open $file";
364 checksrc($cmd, $line, $file, $l)
381 checkwarn("LONGLINE", $line, length($l), $file, $l,
387 $line, length($1), $file, $l, "Contains TAB character", 1);
392 $line, length($1), $file, $l, "Trailing whitespace");
433 $line, length($1), $file, $l, "\/\/ comment");
455 checkwarn("SPACEBEFOREPAREN", $line, length($1)+length($2), $file, $l,
464 $line, $pos+1, $file, $l,
471 $line, length($1)+1, $file, $l,
479 $line, length($1)+1, $file, $l,
486 $line, length($1)+1, $file, $l,
496 checkwarn("RETURNNOSPACE", $line, length($1)+6, $file, $l,
507 checkwarn("SIZEOFNOPAREN", $line, length($1)+6, $file, $l,
539 checkwarn("COMMANOSPACE", $line, length($pref)+1, $file, $l,
547 $line, length($1), $file, $l, "else after closing brace on same line");
552 $line, length($1)+1, $file, $l, "missing space after close paren");
558 $line, length($1), $file, $ol, "space before last semicolon");
571 $line, length($1), $file, $ol,
578 $line, length($1), $file, $ol,
587 $line, length($1), $file, $ol,
597 $line, length($1), $file, $ol, "badly placed open brace");
612 checkwarn("INDENTATION", $line, length($1), $file, $ol,
622 $line, length($1), $file, $ol,
628 $line, length($1)-1, $file, $ol,
640 $line, length($l)-1, $file, $ol,
648 $line, length($1)+1, $file, $ol,
654 $line, length($1)+1, $file, $ol,
661 $line, length($1)+1, $file, $ol,
667 $line, length($1)+1, $file, $ol,
674 $line, length($1)+1, $file, $ol,
684 $line, length($1)+1, $file, $ol,
695 checkwarn("COPYRIGHT", 1, 0, $file, "", "Missing copyright statement", 1);
720 if(`git status -s -- $file` =~ /^ [MARCU]/) {
723 elsif (`git rev-list --count origin/master..HEAD -- $file` !~ /^0/) {
724 my $grl = `git rev-list --max-count=1 --timestamp HEAD -- $file`;
731 $file, $copyright[0]{code},
738 checkwarn("OPENCOMMENT", 1, 0, $file, "", "Missing closing comment", 1);
741 checksrc_endoffile($file);