summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorMartin Waitz <tali@admingilde.org>2005-03-11 16:36:44 -0800
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-03-11 16:36:44 -0800
commitae093336be560d4c9259442303ead98662ffcfce (patch)
treece7f2152a5193578c4ebe5fab40393c4bddc3b12 /scripts
parent95500fb7eb1e0531fefc3b012680d92580c14bb2 (diff)
[PATCH] docbook: allow preprocessor directives between kernel-doc and function
Allow preprocessor directives between kernel-doc and function Signed-off-by: Martin Waitz <tali@admingilde.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/kernel-doc4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/kernel-doc b/scripts/kernel-doc
index a2eaf382aa48..e019ff102f7e 100755
--- a/scripts/kernel-doc
+++ b/scripts/kernel-doc
@@ -1578,13 +1578,13 @@ sub process_state3_function($$) {
my $x = shift;
my $file = shift;
- if ($x =~ m#\s*/\*\s+MACDOC\s*#io) {
+ if ($x =~ m#\s*/\*\s+MACDOC\s*#io || ($x =~ /^#/ && $x !~ /^#define/)) {
# do nothing
}
elsif ($x =~ /([^\{]*)/) {
$prototype .= $1;
}
- if (($x =~ /\{/) || ($x =~ /\#/) || ($x =~ /;/)) {
+ if (($x =~ /\{/) || ($x =~ /\#define/) || ($x =~ /;/)) {
$prototype =~ s@/\*.*?\*/@@gos; # strip comments.
$prototype =~ s@[\r\n]+@ @gos; # strip newlines/cr's.
$prototype =~ s@^\s+@@gos; # strip leading spaces