From: Miek Gieben Date: Tue, 26 Apr 2005 14:06:04 +0000 (+0000) Subject: ugly as hell, but hopefully sufficient X-Git-Tag: release-0.50~68 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7f12806a57e07dbe9b062140a67a0aade7064455;p=thirdparty%2Fldns.git ugly as hell, but hopefully sufficient --- diff --git a/doc/doxyparse.pl b/doc/doxyparse.pl index 6b33f699..e0de46ea 100755 --- a/doc/doxyparse.pl +++ b/doc/doxyparse.pl @@ -23,6 +23,7 @@ my $key; my $return; my $param; my $api; +my $const; my %description; my %api; @@ -103,6 +104,14 @@ while(<>) { $description = $description . "\n" . $_; #$description = $description . "\n.br\n" . $_; } + if ($state == 2 and /const/) { + # the const word exists in the function call + $const = "const"; + s/[\t ]*const[\t ]*//; + } else { + undef $const; + } + if (/([\w\*]*)[\t ]+(.*?)\((.*)\);/ and $state == 2) { # this should also end the current comment parsing $return = $1; @@ -113,7 +122,11 @@ while(<>) { if ($key =~ /^\*/) { #print"Name starts with *\n"; $key =~ s/^\*//; - $return = '*' . $return; + if (defined($const)) { + $return = $const . " " . $return . '*'; + } else { + $return = $return . '*'; + } } $description =~ s/\\param\[in\][ \t]*([\*\w]+)[ \t]+/.br\n\\fB$1\\fR: /g; $description =~ s/\\param\[out\][ \t]*([\*\w]+)[ \t]+/.br\n\\fB$1\\fR: /g;