[PATCH] gdb: remove bpstat typedef, rename bpstats to bpstat

Simon Marchi simark@simark.ca
Mon Nov 8 21:37:52 GMT 2021


On 2021-11-08 12:39 p.m., Andrew Burgess via Gdb-patches wrote:
> * Simon Marchi via Gdb-patches <gdb-patches@sourceware.org> [2021-11-05 15:29:20 -0400]:
>
>> From: Simon Marchi <simon.marchi@polymtl.ca>
>>
>> I don't find that the bpstat typedef, which hides a pointer, is
>> particularly useful.  In fact, it confused me many times, and I just see
>> it as something to remember that adds cognitive load.  Also, with C++,
>> we might want to be able to pass bpstats objects by const-reference, not
>> necessarily by pointer.
>>
>> So, remove the bpstat typedef and rename struct bpstats to bpstat (since
>> it represents one bpstat, it makes sense that it is singular).
>
> I only had one suggestion, but not a blocker.  I usually do
> s/NULL/nullptr/ on any lines that I've touched.  Entirely up to you
> though.

That's typically what I advocate for too.  Here, most of the changes
were automated, so I didn't spot them.  I changed the few occurences I
could find and I'll push the patch shortly, thanks.

Simon


More information about the Gdb-patches mailing list