This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 3/6] gdbserver: Add debugging printf when setting last_resume_kind.
- From: Pedro Alves <palves at redhat dot com>
- To: Doug Evans <dje at google dot com>
- Cc: gdb-patches <gdb-patches at sourceware dot org>
- Date: Wed, 18 Dec 2013 17:52:17 +0000
- Subject: Re: [PATCH 3/6] gdbserver: Add debugging printf when setting last_resume_kind.
- Authentication-results: sourceware.org; auth=none
- References: <yjt238lrup75 dot fsf at ruffy dot mtv dot corp dot google dot com> <52B18420 dot 5060303 at redhat dot com> <CADPb22S=kQiQYaw47AgD_KKJEHbwE8w6v5kBzPKhMDgj7F1F5Q at mail dot gmail dot com>
On 12/18/2013 05:31 PM, Doug Evans wrote:
> For three values? Aren't we getting into over-engineering territory?
The macro way has the nice property that when reading the code
you never have to wonder "is the string actually matching the
enum name correctly?", so IMO it's worth it even with 3 values.
Plus it's 3 today, but might be more tomorrow. At which point
will we switch over? So it might seem that way in isolation,
but I'd rather every place that converts enums to strings
always used the same pattern everywhere.
--
Pedro Alves