This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFA 05/42] Move pending_macros to buildsym_compunit
- From: Tom Tromey <tom at tromey dot com>
- To: Simon Marchi <simark at simark dot ca>
- Cc: Tom Tromey <tom at tromey dot com>, gdb-patches at sourceware dot org
- Date: Sun, 08 Jul 2018 10:35:17 -0600
- Subject: Re: [RFA 05/42] Move pending_macros to buildsym_compunit
- References: <20180523045851.11660-1-tom@tromey.com> <20180523045851.11660-6-tom@tromey.com> <97a59543-69e0-e330-61f2-f8bd64eaf4ce@simark.ca>
>>>>> "Simon" == Simon Marchi <simark@simark.ca> writes:
Simon> On 2018-05-23 12:58 AM, Tom Tromey wrote:
>> This moves the pending_macros global into buildsym_compunit.
Simon> LGTM. As in the other patch, I would like it if the new fields
Simon> were private though.
Simon> The only access of m_pending_macros outside the class is to check if
Simon> the macro table is instantiated. So it could be replaced with this
Simon> method:
Simon> bool has_macro_table () const
Simon> { return m_pending_macros != nullptr; }
In the end the members are all private, and nothing outside the class
refers to this member directly. I didn't look to see where this
reference occurred at this point in the series, but maybe
augment_type_symtab, which ends up as a method of buildsym_compunit?
Anyway I think the final result should be to your liking.
Tom