This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch 3/9]#2 Change target_signal_t to a struct
- From: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- To: Joel Brobecker <brobecker at adacore dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Wed, 1 Sep 2010 20:39:41 +0200
- Subject: Re: [patch 3/9]#2 Change target_signal_t to a struct
- References: <20100830071150.GD6831@host1.dyn.jankratochvil.net> <20100901182558.GA2422@adacore.com>
On Wed, 01 Sep 2010 20:25:58 +0200, Joel Brobecker wrote:
> I don't know what people think, but I'd rather have an opaque structure
> in this case.
I do not understand now. The struct must be defined, not just declared.
GDB sources use variables of its type, not just pointers to it.
> How about defining this struct in common/gdb_signals.h and then the
> accessors in common/signals.c?
Or do you just mean to move
TARGET_SIGNAL_NUMBER
target_signal_from_number
TARGET_SIGNAL_EQ
TARGET_SIGNAL_NE
TARGET_SIGNAL_LT
TARGET_SIGNAL_GT
TARGET_SIGNAL_LE
TARGET_SIGNAL_GE
from common/gdb_signals.h to common/signals.c and remove
TARGET_SIGNAL_INITIALIZER
?
I can do that, LTO should even make it efficient the same.
Thanks,
Jan