Lines Matching full:type

114   --types TYPE(,TYPE2...)    show only these comma separated message types
115 --ignore TYPE(,TYPE2...) ignore various comma separated message types
116 --show-types show the specific message type in the output
127 'values', 'possible', 'type', and 'attr' (default
176 # Also catch when type or level is passed through a variable
189 print("#\tMessage type\n\n");
202 foreach my $type (sort keys %types) {
203 my $orig_type = $type;
205 my $level = $types{$type};
207 $type = RED . $type . RESET;
209 $type = YELLOW . $type . RESET;
211 $type = GREEN . $type . RESET;
214 print(++$count . "\t" . $type . "\n");
255 my $type = '';
266 $verbose_messages{$type} = trim($desc);
268 $type = $1;
277 $verbose_messages{$type} = trim($desc);
278 $type = '';
286 $verbose_messages{$type} = trim($desc);
560 our $Type;
1062 $Type = qr{
1072 $Declare = qr{(?:$Storage\s+(?:$Inline\s+)?)?$Type};
1131 if ($line =~ /^[ \t]*(?:#[ \t]*define|typedef\s+$Type)\s+(\w*(?:[A-Z][a-z]|[a-z][A-Z])\w*)/) {
1688 my $type = '';
1720 $type = '#';
1727 #warn "CSB: c<$c> type<$type> level<$level> remainder<$remainder> coff_set<$coff_set>\n";
1731 push(@stack, [ $type, $level ]);
1733 ($type, $level) = @{$stack[$#stack - 1]};
1735 ($type, $level) = @{pop(@stack)};
1755 if (($type eq '' || $type eq '(') && $c eq '(') {
1757 $type = '(';
1759 if ($type eq '(' && $c eq ')') {
1761 $type = ($level != 0)? '(' : '';
1769 if (($type eq '' || $type eq '{') && $c eq '{') {
1771 $type = '{';
1773 if ($type eq '{' && $c eq '}') {
1775 $type = ($level != 0)? '{' : '';
1785 if ($type eq '#' && $c eq "\n" && $p ne "\\") {
1787 $type = '';
2081 my ($stream, $type) = @_;
2092 "> <$type> <$av_pending>" if ($dbg_values > 1);
2096 $type = pop(@av_paren_type);
2100 } elsif ($cur =~ /^(\(\s*$Type\s*)\)/ && $av_pending eq '_') {
2102 push(@av_paren_type, $type);
2103 $type = 'c';
2105 } elsif ($cur =~ /^($Type)\s*(?:$Ident|,|\)|\(|\s*$)/) {
2107 $type = 'T';
2111 $type = 'T';
2116 push(@av_paren_type, $type);
2120 $type = 'E';
2125 push(@av_paren_type, $type);
2131 push(@av_paren_type, $type);
2132 push(@av_paren_type, $type);
2133 $type = 'E';
2141 $type = 'E';
2151 push(@av_paren_type, $type);
2152 $type = 'E';
2159 $av_pending = $type;
2160 $type = 'N';
2167 $type = 'N';
2172 $type = 'N';
2177 $type = 'N';
2181 $type = 'N';
2187 $type = 'N';
2192 $type = $new_type;
2193 print "PAREN('$1') -> $type\n"
2201 $type = 'V';
2205 if (defined $2 && $type eq 'C' || $type eq 'T') {
2207 } elsif ($type eq 'E') {
2210 print "IDENT_COLON($1,$type>$av_pend_colon)\n" if ($dbg_values > 1);
2211 $type = 'V';
2215 $type = 'V';
2219 $type = 'N';
2223 $type = 'E';
2228 $type = 'C';
2232 $type = 'N';
2239 $type = 'E';
2241 $type = 'N';
2247 $type = 'N';
2253 if ($type eq 'V') {
2260 $type = 'N';
2265 $type = 'N';
2273 $res .= $type x length($1);
2286 $Type|
2309 $possible =~ s/\s*$Type\s*//g;
2330 my ($type) = @_;
2332 $type =~ tr/[a-z]/[A-Z]/;
2334 return defined $use_type{$type} if (scalar keys %use_type > 0);
2336 return !defined $ignore_type{$type};
2340 my ($level, $type, $msg) = @_;
2342 if (!show_type($type) ||
2359 $output .= "$type:";
2374 if ($verbose && exists($verbose_messages{$type}) &&
2375 !exists($verbose_emitted{$type})) {
2376 $output .= $verbose_messages{$type} . "\n\n";
2377 $verbose_emitted{$type} = 1;
2474 my ($type, $msg) = @_;
2476 if (report("ERROR", $type, $msg)) {
2484 my ($type, $msg) = @_;
2486 if (report("WARNING", $type, $msg)) {
2494 my ($type, $msg) = @_;
2496 if ($check && report("CHECK", $type, $msg)) {
3475 $rawline =~ /^Content-Type:.+charset="(.+)".*$/ &&
3677 "MAINTAINERS entries use one tab after TYPE:\n" . $herecurr) &&
3696 "Unknown MAINTAINERS entry type: '$cur'\n" . $herecurr);
4007 # "sizeof(<type>)" or "__alignof__(<type>)"
4012 if ($line =~ /^\+(.*)\(\s*$Type\s*\)([ \t]++)((?![={]|\\$|$Attribute|__attribute__))/ &&
4018 s/(\(\s*$Type\s*\))[ \t]+/$1/;
4179 $prevline =~ /^\+(?:(?:(?:$Storage|$Inline)\s*)*\s*$Type\s*)?($Ident)\(/) {
4270 my $type = $1;
4271 $type =~ s/\s+/ /g;
4272 possible($type, "A:" . $s);
4279 # any (foo ... *) is a pointer cast, and foo is a type
4287 …if ($prev_values eq 'E' && $s =~ /^(.(?:typedef\s*)?(?:(?:$Storage|$Inline)\s*)*\s*$Type\s*(?:\b$I…
4520 my $type = $1;
4523 if ($type =~ /^(?:(?:$Storage|$Inline|$Attribute)\s+)*((?:un)?signed)((?:\s*\*)*)\s*$/) {
4542 # TEST: allow direct testing of the type matcher.
4546 "TEST: is type\n" . $herecurr);
4549 "TEST: is not type ($1 is)\n". $herecurr);
4638 ^.(?:$Storage\s+)?$Type\s*\(\s*\*\s*\Q$name\E\s*\)\s*\(|
4660 if ($line =~ /^\+$Type\s*$Ident(?:\s+$Modifier)*\s*=\s*($zero_initializer)\s*;/ &&
4665 $fixed[$fixlinenr] =~ s/(^.$Type\s*$Ident(?:\s+$Modifier)*)\s*=\s*$zero_initializer\s*;/$1;/;
4682 … "type '$tmp' should be specified in [[un]signed] [short|int|long|long long] order\n" . $herecurr);
4687 my $type = trim($1);
4688 next if ($type !~ /\bint\b/);
4689 next if ($type !~ /\b(?:short|long\s+long|long)\b/);
4690 my $new_type = $type;
4694 $new_type = "unsigned $new_type" if ($type =~ /\bunsigned\b/);
4695 $new_type = "const $new_type" if ($type =~ /^const\b/);
4699 "Prefer '$new_type' over '$type' as the int is unnecessary\n" . $herecurr) &&
4701 $fixed[$fixlinenr] =~ s/\b\Q$type\E\b/$new_type/;
4728 # check for const <foo> const where <foo> is not a pointer or array type
4740 # check for const static or static <non ptr type> const declarations
4742 if ($sline =~ /^\+\s*const\s+static\s+($Type)\b/ ||
4773 if ($line =~ /(\b$Type\s*$Ident)\s*\(\s*\)/) {
4777 $fixed[$fixlinenr] =~ s/(\b($Type)\s+($Ident))\s*\(\s*\)/$2 $3(void)/;
4784 $line !~ /\btypedef\s+$Type\s*\(\s*\*?$Ident\s*\)\s*\(/ &&
4785 $line !~ /\btypedef\s+$Type\s+$Ident\s*\(/ &&
4792 # * goes on variable not on type
4915 # Folks usually mean EOPNOTSUPP (also called ENOTSUP), when they type ENOTSUPP.
4928 $sline =~ /$Type\s*$Ident\s*$balanced_parens\s*\{/ &&
4936 $fixed_line =~ /(^..*$Type\s*$Ident\(.*\)\s*)\{(.*)$/;
4976 # check spacing between type, funcptr, and args
4977 # canonical declaration is "type (*funcptr)(args...)"
4986 # the $Declare variable will capture all spaces after the type
4996 "missing space after return type\n" . $herecurr);
5000 # unnecessary space "type (*funcptr)(args...)"
5008 # "Multiple spaces after return type\n" . $herecurr);
5011 # unnecessary space "type ( *funcptr)(args...)"
5018 # unnecessary space "type (* funcptr)(args...)"
5025 # unnecessary space "type (*funcptr )(args...)"
5032 # unnecessary space "type (*funcptr) (args...)"
5046 # 1. with a type on the left -- int [] a;
5051 if ($prefix !~ /$Type\s+$/ &&
5084 # If this whole things ends with a type its most
5086 } elsif ($ctx =~ /$Type$/) {
5250 # '*' as part of a type definition -- reported already.
5252 #warn "'*' is part of type\n";
5427 ## if ($line =~ /^.\s*$Type\s+$Ident(?:\s*=[^,{]*)?\s*,\s*$Ident.*/ &&
5428 ## $line !~ /^.\s*$Type\s+$Ident(?:\s*=[^,{]*)?\s*,\s*$Type\s*$Ident.*/) {
5442 if (($line =~ /\(.*\)\{/ && $line !~ /\($Type\)\{/) ||
5452 ## if ($line =~ /^.\t+$Type\s+$Ident(?:\s*=.*)?;/ &&
6045 # check if any macro arguments are reused (ignore '...' and 'type')
6048 next if ($arg =~ /^type$/i);
6050 …sizeof_field|__stringify|typeof|__typeof__|__builtin\w+|typecheck\s*\(\s*$Type\s*,|\#+)\s*\(*\s*$a…
6470 …if ($s =~ /(?:^|\n)[ \+]\s*(?:$Type\s*)?\Q$testval\E\s*=\s*(?:\([^\)]*\)\s*)?\s*$allocFunctions\s*…
6587 $line =~ /($Type)\s*$Ident/ && $1 !~ /\*\s*$/ && $1 =~ /\bconst\b/) {
6589 "Invalid use of __read_mostly with const type\n" . $herecurr) &&
6729 # check that the storage class is not after a type
6730 if ($line =~ /\b($Type)\s+($Storage)\b/) {
6732 "storage class '$2' should be located before type '$1'\n" . $herecurr);
6744 # storage class and type.
6745 if ($line =~ /\b$Type\s+$Inline\b/ ||
6748 "inline keyword should sit between storage class and type\n" . $herecurr);
6840 my $type = $1;
6841 if ($type =~ /\b($typeC99Typedefs)\b/) {
6842 $type = $1;
6844 $kernel_type = 's' if ($type =~ /^_*[si]/);
6845 $type =~ /(\d+)/;
6848 "Prefer kernel type '$kernel_type' over '$type'\n" . $herecurr) &&
6850 $fixed[$fixlinenr] =~ s/\b$type\b/$kernel_type/;
6882 if ($line =~ /\bsizeof\s+((?:\*\s*|)$Lval|$Type(?:\s+$Lval|))/) {
6886 …$fixed[$fixlinenr] =~ s/\bsizeof\s+((?:\*\s*|)$Lval|$Type(?:\s+$Lval|))/"sizeof(" . trim($1) . ")"…
7129 "Prefer kstrto<type> to single variable sscanf\n" . "$here\n$stat_real\n");
7136 $line =~ /^\+\s*(extern\s+)$Type\s*$Ident\s*\(/s) {
7146 $stat =~ /^.\s*(?:extern\s+)?$Type\s+($Ident)(\s*)\(/s)
7177 "found a file-scoped extern type:$st_type name:$st_name in .c file\n"
7190 … $stat =~ /^.\s*(?:extern\s+)?$Type\s*(?:$Ident|\(\s*\*\s*$Ident\s*\))\s*\(\s*([^{]+)\s*\)\s*;/s &&
7193 while ($args =~ m/\s*($Type\s*(?:$Ident|\(\s*\*\s*$Ident?\s*\)\s*$balanced_parens)?)/g) {
7195 if ($arg =~ /^$Type$/ && $arg !~ /enum\s+$Ident$/) {
7205 $stat =~ /^.\s*(?:$Storage\s+)?$Type\s*($Ident)\s*$balanced_parens\s*{/s) {
7396 my $type = lc($otype);
7397 if ($type =~ /^(?:true|false)$/) {
7398 if (("$test" eq "==" && "$type" eq "true") ||
7399 ("$test" eq "!=" && "$type" eq "false")) {
7494 $prevline =~ /^\+\s*(?:\}(?:\s*__packed\s*)?|$Type)\s*$Ident\s*\[\s*(0|1)\s*\]\s*;\s*$/) {