This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Default arguments and FUNCTION_TYPEs
Mark Mitchell <mark@codesourcery.com> writes:
| Gabriel Dos Reis wrote:
| > Hi,
| >
| > In the C++ front end, default arguments are recorded in
| > FUNCTION_TYPEs intead of being part of the FUNCTION_DECLs. What are
| > the reasons for that?
|
| There used to be an extension that allowed default arguments on function
| pointer types. We agreed to kill it, although I don't know if it was
| actually removed. If that's been done, there's no longer any reason.
Great! I seem to remember it was killed (and I would say you killed
it but I may be wrong.) I'll investigate.
Assuming the extension was gone, do you see a reason we not move the
default arguments to FUNCTION_DECLs and have FUNCTION_TYPEs use
TREE_VEC instead of TREE_LIST to hold the parameter-type list?
-- Gaby