From: Daniel King Date: Tue, 18 Apr 2023 08:18:36 +0000 (+0100) Subject: ada: Add No_Elaboration_Code_All pragma to System.Storage_Elements X-Git-Tag: basepoints/gcc-15~8382 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=416bb154d5c36f25dd6f54fb0d81bf6b0132ee20;p=thirdparty%2Fgcc.git ada: Add No_Elaboration_Code_All pragma to System.Storage_Elements Allows System.Storage_Elements to be used in units that have the No_Elaboration_Code_All restriction. gcc/ada/ * libgnat/s-stoele.ads: Add No_Elaboration_Code_All pragma. --- diff --git a/gcc/ada/libgnat/s-stoele.ads b/gcc/ada/libgnat/s-stoele.ads index 3262d0329c34..7de150dab59c 100644 --- a/gcc/ada/libgnat/s-stoele.ads +++ b/gcc/ada/libgnat/s-stoele.ads @@ -43,6 +43,9 @@ package System.Storage_Elements is -- this unit Pure instead of Preelaborable; see RM 13.7.1(15). In Ada 2005, -- this is Pure in any case (AI-362). + pragma No_Elaboration_Code_All; + -- Allow the use of that restriction in units that WITH this unit + pragma Annotate (GNATprove, Always_Return, Storage_Elements); type Storage_Offset is range -Memory_Size / 2 .. Memory_Size / 2 - 1;