Is this possible to get a full prototype of a given function in a
standardized, easily parsable form?  The point is I need to get a
number of parameters for a number of functions as I am writing a
custom REPL-like tool that will call functions from an external API.
I need to know how many parameters every function takes in order to
inform user that he gave too few parameters. What I do now is this:

$ gtags -v -f LIST
$ global -f diff.h
foo                 5 diff.h           foo(

But it doesn't show any arguments that foo() takes.  It's written like
this in a source file:

void
foo(
int a,
         int b, int c, char
*f)
{
}

It's possible to do this in ctags:

$ ctags  --fields=+S diff.h
$ less tags
(...)
foo     diff.h  /^foo($/;"      f       signature:( int a, int b, int
c, char *f)

Now I can easily parse `signature:part' and get a number of
parameters.  I could use ctags but I got used to global, is this
possible here?

-- 
<[email protected]>

_______________________________________________
Help-global mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/help-global

Reply via email to