[DTrace-devel] [PATCH v2 03/11] htab: add dt_htab_entries
Eugene Loh
eugene.loh at oracle.com
Wed Oct 27 11:23:41 PDT 2021
On 10/27/21 9:26 AM, Nick Alcock wrote:
> On 21 Oct 2021, Eugene Loh stated:
>
>> Reviewed-by: Eugene Loh <eugene.loh at oracle.com>
>> Only one comment this time:
>>
>> On 10/20/21 2:53 PM, Nick Alcock wrote:
>>> diff --git a/libdtrace/dt_htab.c b/libdtrace/dt_htab.c
>>> @@ -44,6 +44,7 @@ struct dt_htab {
>>> int mask;
>>> int nbuckets;
>>> dt_htab_ops_t *ops;
>>> + size_t nentries;
>>>
>>> @@ -59,6 +60,7 @@ dt_htab_t *dt_htab_create(dtrace_hdl_t *dtp, dt_htab_ops_t *ops)
>>> htab->size = 1;
>>> htab->mask = htab->size - 1;
>>> htab->nbuckets = 0;
>>> + htab->nentries = 0;
>>> htab->ops = ops;
>> It would be incrementally nicer if the initializations were in the same
>> order as the declarations. Obviously, no big deal.
> Solved by reordering the declaration, which looks prettier too.
Does reordering the declarations then mean that some other spots (e.g.,
within dt_htab.h) are now out of order?
More information about the DTrace-devel
mailing list