From e7f7018c2a5f07e6e8a045b6ba18c023daed7010 Mon Sep 17 00:00:00 2001 From: Bob Duff Date: Mon, 30 Jan 2023 16:56:08 -0500 Subject: ada: update Ada_Version_Type in fe.h to match opt.ads Remove Ada_With_Extensions, which is not used on the C side. Do not add Ada_With_Core_Extensions and Ada_With_All_Extensions, which are also not used on the C side, and on the Ada side are always used via functions All_Extensions_Allowed and Core_Extensions_Allowed. Explain this in comments. Move the functions closer to the type declaration, so the usage style is clearer. Cleanup only -- no change in compiler behavior. gcc/ada/ * fe.h: Remove Ada_With_Extensions and add commentary. * opt.ads: Rearrange code and add commentary. --- gcc/ada/fe.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'gcc/ada/fe.h') diff --git a/gcc/ada/fe.h b/gcc/ada/fe.h index dd1ee51..2d8f299 100644 --- a/gcc/ada/fe.h +++ b/gcc/ada/fe.h @@ -220,8 +220,11 @@ extern Boolean In_Extended_Main_Code_Unit (Entity_Id); #define Unnest_Subprogram_Mode opt__unnest_subprogram_mode typedef enum { - Ada_83, Ada_95, Ada_2005, Ada_2012, Ada_2022, Ada_With_Extensions + Ada_83, Ada_95, Ada_2005, Ada_2012, Ada_2022 } Ada_Version_Type; +// Ada_With_Core_Extensions and Ada_With_All_Extensions (see opt.ads) are not +// used on the C side for now. If we decide to use them, we should import +// All_Extensions_Allowed and Core_Extensions_Allowed functions. extern Ada_Version_Type Ada_Version; extern Boolean Back_End_Inlining; -- cgit v1.1