This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Prototyped function types
- From: Jim Blandy <jimb at redhat dot com>
- To: Daniel Jacobowitz <drow at mvista dot com>
- Cc: gdb at sources dot redhat dot com
- Date: Thu, 21 Feb 2002 16:06:26 -0500 (EST)
- Subject: Prototyped function types
(I can't find the old thread on this subject, so I'm starting a new
one. Sorry.)
I recently added support to GDB for the stabs 'g' type descriptor, as
described in Sun's STABS manual. I was hoping Daniel would jump in
and add the corresponding support to gcc/dbxout.c, but he seemed to
have concerns about the types' syntax.
Daniel, I think you were concerned about the lack of separators
between the argument types; that is, a function taking three ints and
returning an int will look something like this:
g(0,1)(0,1)(0,1)(0,1)
Since there's no punctuation between the types, this syntax becomes
ambiguous if you're using the older type number notation, in which
type numbers are just numbers, not pairs of numbers separated by
commas and surrounded by parens. Then you'd get:
g1111
which is obviously Not Okay.
However, I don't think this is a problem. The compiler simply
shouldn't use 'g' if it's not using (file,number) pairs.
But in general, I have no attachment to that particular syntax;
whatever you propose, I'll try to implement. Do you want semicolons?
I just want to get this dealt with. :)