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 2/6] DW attribute macro MACRO_AT_func and MACRO_AT_range


Doug Evans <dje@google.com> writes:

Hi Doug,

> The sequence of ifs to test for each macro name is akin to the switch
> statement we removed.
> It's less code of course, but it still involves continual additions
> for each new macro.
> I was thinking of still having a wrapper function that checks for macros,
> but it could do "info proc _handle_$attr_name" or some such and
> call(via eval?) the function if it exists or flag an error if it
> doesn't.  We don't have to go down this road though until we need to.

Yeah, that is a very clear trick.  I'll adapt the code for it when new
macro attribute is added later.

Thanks for your review, and this series is pushed in.

-- 
Yao (éå)


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