> The following fixes an issue with nonoverlapping_component_refs_of_decl_p > (and the latent same issue in nonoverlapping_component_refs_p). We > can't rely on all variant types having the same TYPE_FIELDS, so the > following simply uses DECL_FIELD_CONTEXT directly (which is either > the same for shared TYPE_FIELDS or not - in which case we can't > use TYPE_MAIN_VARIANT anyway).
Thanks for fixing this. IIRC I wondered for a few moments about this apparently superfluous usage of TYPE_MAIN_VARIANT in the original version of nonoverlapping_component_refs_p, but I didn't realize that it could in fact lead to wrong code... -- Eric Botcazou