Re: Parsing args problems



Paolo Casarini wrote:
> 
> Hi, I've two problems with gtk-doc 0.6.
> 
> The first is with the following prototype:
> GdomeDocument *gdome_di_createDocFromURIWithEntityTable
> (GdomeDOMImplementation *self, const char *uri, char *entityTable[][4],
> GdomeLoadingCode mode, GdomeException *exc);
> 
> make templates says:
> ###Can't parse args for function
> gdome_di_createDocFromURIWithEntityTable: char *entityTable[][4],
> GdomeLoadingCode mode, GdomeException *exc

gtk-doc doesn't understand the '[][4]' part.

You could try changing the perl regular expressions so it matches.
Maybe this will work, I'm not sure:
(I just changed the '?' to a '*' after the "(\[\d*\])" )


--- gtkdoc-mktmpl.in.orig	Fri Apr 13 15:04:20 2001
+++ gtkdoc-mktmpl.in	Sat May 12 15:38:47 2001
@@ -372,7 +372,7 @@
 					 $template_exists, 1, "");
 
 		# Try to match a standard parameter.
-	    } elsif ($declaration =~ s/^(const\s+|unsigned\s+)*(struct\s+)?(\w+)\s*(\**)\s*(const\s+)?(\**)?\s*(\w+)?\s*(\[\d*\])?\s*[,\n]//) {
+	    } elsif ($declaration =~ s/^(const\s+|unsigned\s+)*(struct\s+)?(\w+)\s*(\**)\s*(const\s+)?(\**)?\s*(\w+)?\s*(\[\d*\])*\s*[,\n]//) {
 		if (defined ($7)) {
 		    $name = $7;
 		} else {


You'd probably need to change this in a few other places as well.
Send me a patch when it works ;)

 
> The second one for functions that return void * like:
> void *gdome_n_query_interface (GdomeNode *self,
>                                const char *interface,
>                                GdomeException *exc);
> make sgml says:
> WARNING: Parameter described in source code comment block but does not
> exist - Func: gdome_n_query_interface Param: Returns.

I'm not sure where the problem is here.
What is output in the tmpl/ file for this function?
(i.e. does it include the void* return value, or has that been dropped?)

Damon




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