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 1/9]#2 Rename `enum target_signal' to target_signal_t


On Wed, 01 Sep 2010 21:07:55 +0200, Pedro Alves wrote:
> I wonder if switching on "-Wc++-compat" wouldn't catch these (at
> least with recent enough gccs) and be more productive than
> switching to a struct.  /me ducks.

I wanted to argue with this great point myself but during my tests (gcc-4.5)
enum unfortunately IS compatible with int even in C++ (tried -Wall/-pedantic
etc.).  I haven't checked the C++ spec.

enum a is not compatible with enum b in C++; while it is compatible in C.
This does not help for the GDB case, though.


Thanks,
Jan


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