From d6de75d526bf5958fe9e66195dc0bf1c458e9b06 Mon Sep 17 00:00:00 2001 From: Eric Botcazou Date: Tue, 16 Feb 2021 09:00:11 +0100 Subject: [Ada] Fix type mismatch warnings during LTO bootstrap #2 gcc/ada/ * init.c (__gnat_raise_program_error): Fix parameter type. (Raise_From_Signal_Handler): Likewise and mark as no-return. * raise-gcc.c (__gnat_others_value): Fix type. (__gnat_all_others_value): Likewise. (__gnat_unhandled_others_value): Likewise. * seh_init.c (Raise_From_Signal_Handler): Fix parameter type. * libgnat/a-except.ads (Raise_From_Signal_Handler): Use convention C and new symbol name, move declaration to... (Raise_From_Controlled_Operation): Minor tweak. * libgnat/a-except.adb (Raise_From_Signal_Handler): ...here. * libgnat/a-exexpr.adb (bool): New C compatible boolean type. (Is_Handled_By_Others): Use it as return type for the function. --- gcc/ada/raise-gcc.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'gcc/ada/raise-gcc.c') diff --git a/gcc/ada/raise-gcc.c b/gcc/ada/raise-gcc.c index 9e09ffa..6a50a51 100644 --- a/gcc/ada/raise-gcc.c +++ b/gcc/ada/raise-gcc.c @@ -542,17 +542,17 @@ typedef struct /* ABI header, maximally aligned. */ } _GNAT_Exception; -/* The two constants below are specific ttype identifiers for special +/* The three constants below are specific ttype identifiers for special exception ids. Their type should match what a-exexpr exports. */ -extern const int __gnat_others_value; -#define GNAT_OTHERS ((_Unwind_Ptr) &__gnat_others_value) +extern const char __gnat_others_value; +#define GNAT_OTHERS ((_Unwind_Ptr) &__gnat_others_value) -extern const int __gnat_all_others_value; -#define GNAT_ALL_OTHERS ((_Unwind_Ptr) &__gnat_all_others_value) +extern const char __gnat_all_others_value; +#define GNAT_ALL_OTHERS ((_Unwind_Ptr) &__gnat_all_others_value) -extern const int __gnat_unhandled_others_value; -#define GNAT_UNHANDLED_OTHERS ((_Unwind_Ptr) &__gnat_unhandled_others_value) +extern const char __gnat_unhandled_others_value; +#define GNAT_UNHANDLED_OTHERS ((_Unwind_Ptr) &__gnat_unhandled_others_value) /* Describe the useful region data associated with an unwind context. */ -- cgit v1.1