This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: C++ Darwin Port BUG in source code
"Joseph S. Myers" <joseph@codesourcery.com> writes:
> On Sun, 6 Feb 2005, Zack Weinberg wrote:
>>
>> At this stage of code slush, the appropriate cure is probably to make
>> the C version grow an extra unused argument, and change all callers to
>> match. Without changing any function names. That'll be large, but
>> it'll be completely mechanical and therefore low risk.
>>
>> Joseph, as C front end maintainer, do you have an opinion?
>
> Even simpler and avoiding cluttering callers with an extra argument would
> be renaming lookup_name to c_lookup_name and adding a lookup_name wrapper
> which discards the extra parameter.
That makes sense if adjusted slightly. The C version of the routine
doesn't have the extra parameter; it's the C++ version that would need
renaming. I count 12 calls with the C type signature and 6 with the
C++ signature, so that is indeed a smaller, simpler change.
I observe that darwin_pragma_unused is the ONLY place that calls
lookup_name that does not clearly belong to a specific front end.
Maybe it ought to be calling identifier_global_value instead?
zw