From: Jakub Jelinek Date: Mon, 13 Dec 2021 08:51:17 +0000 (+0100) Subject: pch: Small cleanup X-Git-Tag: basepoints/gcc-13~2391 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7ed58b4274c58b11afdb52a3928c6cf2af92e8d0;p=thirdparty%2Fgcc.git pch: Small cleanup > Fixed thusly, compile tested on x86_64-linux, committed to trunk. Here is a small cleanup. IMHO we should use gt_pointer_operator instead of specifying manually void (*) (void *, void *) or void (*) (void *, void *, void *) so that next time we want to change it, we don't have to trace all the spots. I was afraid it wouldn't work due to header dependencies, but it works well. gengtype generated files also use gt_pointer_operator. 2021-12-13 Jakub Jelinek * machmode.h (gt_pch_nx): Use gt_pointer_operator as type of second argument instead of equivalent void (*) (void *, void *, void *). * poly-int.h (gt_pch_nx): Likewise. * wide-int.h (gt_pch_nx): Likewise. * config/aarch64/aarch64-sve-builtins.cc (gt_pch_nx): Likewise. --- diff --git a/gcc/config/aarch64/aarch64-sve-builtins.cc b/gcc/config/aarch64/aarch64-sve-builtins.cc index 27be8b9253d0..4250eaf785fe 100644 --- a/gcc/config/aarch64/aarch64-sve-builtins.cc +++ b/gcc/config/aarch64/aarch64-sve-builtins.cc @@ -3913,7 +3913,7 @@ gt_pch_nx (function_instance *) } inline void -gt_pch_nx (function_instance *, void (*) (void *, void *, void *), void *) +gt_pch_nx (function_instance *, gt_pointer_operator, void *) { } diff --git a/gcc/machmode.h b/gcc/machmode.h index 2e5bafd0f967..5a43c66a70f0 100644 --- a/gcc/machmode.h +++ b/gcc/machmode.h @@ -1199,7 +1199,7 @@ gt_pch_nx (pod_mode *) template void -gt_pch_nx (pod_mode *, void (*) (void *, void *, void *), void *) +gt_pch_nx (pod_mode *, gt_pointer_operator, void *) { } diff --git a/gcc/poly-int.h b/gcc/poly-int.h index 60a38c3ea617..f7226e68d427 100644 --- a/gcc/poly-int.h +++ b/gcc/poly-int.h @@ -2717,7 +2717,7 @@ gt_pch_nx (poly_int_pod *) template void -gt_pch_nx (poly_int_pod *, void (*) (void *, void *, void *), void *) +gt_pch_nx (poly_int_pod *, gt_pointer_operator, void *) { } diff --git a/gcc/wide-int.h b/gcc/wide-int.h index d03a17412536..bc51aa9309f0 100644 --- a/gcc/wide-int.h +++ b/gcc/wide-int.h @@ -3338,7 +3338,7 @@ gt_pch_nx (generic_wide_int *) template void -gt_pch_nx (generic_wide_int *, void (*) (void *, void *, void *), void *) +gt_pch_nx (generic_wide_int *, gt_pointer_operator, void *) { } @@ -3356,7 +3356,7 @@ gt_pch_nx (trailing_wide_ints *) template void -gt_pch_nx (trailing_wide_ints *, void (*) (void *, void *, void *), void *) +gt_pch_nx (trailing_wide_ints *, gt_pointer_operator, void *) { }