Re: [PATCH v7 02/17] ref-filter: include reference to 'used_atom' within 'atom_value'
- From
Karthik Nayak <karthik.188@gmail.com>
- Date
- Nov 10, 2016, 17:16 UTC
- Message-ID
- <CAOLa=ZT-RZw1RoKHVXMu9syrTp67iMVCDv1LtyysekJuhJQSpA@mail.gmail.com>
- In-Reply-To
- <CA+P7+xqVAEuc12eQJ7-Et0CtXc12t5zDUg3Qsh3214cTh_brbA@mail.gmail.com>
Show 15 quoted lines
>> >> /* >> @@ -370,7 +368,7 @@ static void align_atom_handler(struct atom_value *atomv, struct ref_formatting_s >> push_stack_element(&state->stack); >> new = state->stack; >> new->at_end = end_align_handler; >> - new->at_end_data = &atomv->u.align; >> + new->at_end_data = &atomv->atom->u.align; > > At first, this confused me. I was like "we dropped the union, why are > we still referencing it. But I realized that the "used_atom" struct > actually contains the same union and we were copying it. > > Ok, so this looks good. >
It is confusing if one only looks at the patch without actually going through ref-filter.c. I'm sure your comment will help anyone going through these patches.
-- Regards, Karthik Nayak