This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Remove unnecessary function prototypes.


On 9/7/17 4:53 PM, Simon Marchi wrote:
> On 2017-09-07 09:53 PM, John Baldwin wrote:
>> These prototypes were required when compiling GDB as C but are not
>> required for C++.
> 
> Thanks a lot for doing this!  This patch is ok.  Just to understand your
> intentions, do you plan to remove the remaining ones as well later?

No, just insufficient grepping on my part.  I'll send a V2 in a bit that
removes all the remaining cases found by your pattern.

> Before patch:
> 
> $ egrep "(void|initialize_file_ftype) _initialize_" */*.c *.c  | wc -l
> 346
> 
> After patch:
> 
> $ egrep "(void|initialize_file_ftype) _initialize_" */*.c *.c  | wc -l
> 68
> 
> In the end, I think we'll be able to move the initialize_file_ftype typedef
> to the generated init.c file, since it won't be used anywhere else.

Yes, the only remaining reference now is in defs.h outside of init.c.

-- 
John Baldwin


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]