get_union_members_from_root function

Extract members of unions