Re: gtk-doc confused about symbols



David Nečas schrieb:
> On Mon, Jan 26, 2009 at 10:23:14AM +0100, David Nečas wrote:
>   
>> Should the parser really consume this?
>>
>> /**
>>  * Adds a subscription to be monitored.
>>  */ 
>>
>> The first line is not an identifier followed by a colon, so it cannot be
>> a symbol documentation.  Or is such a vague matching necessary for some
>> legacy documentation?
>>     
>
> I mean something like this (I would even remove the warning about
> comments where we cannot find a symbol because if there is no symbol the
> comment is not intended for our consumption).
>
> Index: gtkdoc-mkdb.in
> ===================================================================
> --- gtkdoc-mkdb.in	(revision 665)
> +++ gtkdoc-mkdb.in	(working copy)
> @@ -3397,7 +3397,7 @@
>  		$symbol = $1;
>  		#print "SECTION DOCS found in source for : '$symbol'\n";
>  		$ignore_broken_returns = 1;
> -	    } elsif (m%^\s*([\w:-]*\w)\s*:?%) {
> +	    } elsif (m%^\s*([\w:-]*\w)\s*:?\s*$%) {
>  		$symbol = $1;
>  		#print "SYMBOL DOCS found in source for : '$symbol'\n";
>  	    }
>
>   
Matthias, how does this sound. We take anything that is one word
followed by a ':' or not as a symbol and I remove the warning about
"Symbol name not found at the start of the comment block.".
We should probably also only look for the symbol name before anything else.

Or would yo like to keep it as it is and turning the /** into /* comments?

Stefan


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]