Why these dot chars in scripts/checkpatch.pl?

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Andy Whitcroft <apw@...>
Cc: <linux-kernel@...>
Date: Monday, April 28, 2008 - 4:31 pm

Andy,

Perhaps I'm loosing my magic regex pixie dust, but the dot '.' char
in the pattern "/^.#" in the following lines looks wrong to me, as if
one were trying to match pre-processor directives that were set in by
one character:

The command:

	grep '^[^#].*\/\^\.#' scripts/checkpatch.pl

displays:

        if ($res =~ /^.#\s*include\s+\<(.*)\>/) {
        } elsif ($res =~ /^.#\s*(?:error|warning)\s+(.*)\b/) {
                if ($line =~ /(.*)\b((?:if|while|for|switch)\s*\(|do\b|else\b)/ && $line !~ /^.#/) {
                if ($line =~ /^.#\s*if\s+0\b/) {
                if ($line =~ /^.#\s*(ifdef|ifndef|elif)\s\s+/) {
                    $line !~ /^.#\s*if\b.*\bNR_CPUS\b/ &&
                    $line !~ /^.#\s*define\b.*\bNR_CPUS\b/ &&

-- 
                  I won't rest till it's the best ...
                  Programmer, Linux Scalability
                  Paul Jackson <pj@sgi.com> 1.940.382.4214
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Why these dot chars in scripts/checkpatch.pl?, Paul Jackson, (Mon Apr 28, 4:31 pm)
Re: Why these dot chars in scripts/checkpatch.pl?, Andy Whitcroft, (Mon Apr 28, 7:02 pm)
Re: Why these dot chars in scripts/checkpatch.pl?, Rogan Dawes, (Mon Apr 28, 4:47 pm)
Re:+patch Why these dot chars in scripts/checkpatch.pl?, Jan Engelhardt, (Mon Apr 28, 6:10 pm)
Re: +patch Why these dot chars in scripts/checkpatch.pl?, Andy Whitcroft, (Mon Apr 28, 7:06 pm)
Re: +patch Why these dot chars in scripts/checkpatch.pl?, Segher Boessenkool, (Tue Apr 29, 5:51 am)
Re: Why these dot chars in scripts/checkpatch.pl?, Paul Jackson, (Mon Apr 28, 4:51 pm)