]> git.ipfire.org Git - thirdparty/gcc.git/commit
c: reorganize recursive type checking
authorMartin Uecker <uecker@tugraz.at>
Wed, 21 Dec 2022 09:52:34 +0000 (10:52 +0100)
committerMartin Uecker <uecker@tugraz.at>
Tue, 12 Sep 2023 04:49:46 +0000 (06:49 +0200)
commit26da1970a4011893cdf3f38793dc856e2a88be25
tree3cf7e7049868cf60207cea6e4a610e6c9c63bdf1
parentc1e4efd8ae3488c5a2c11ac42d4670b67e1f7bf4
c: reorganize recursive type checking

Reorganize recursive type checking to use a structure to
store information collected during the recursion and
returned to the caller (warning_needed, enum_and_init_p,
different_types_p).

gcc/c:
* c-typeck.cc (struct comptypes_data): Add structure.
(tagged_types_tu_compatible_p,
function_types_compatible_p, type_lists_compatible_p,
comptypes_internal): Add structure to interface, change
return type to bool, and adapt calls.
(comptarget_types): Change return type too bool.
(comptypes, comptypes_check_enum_int,
comptypes_check_different_types): Adapt calls.
gcc/c/c-typeck.cc