From 92b751fdc698c7b2040f986aaa125e4163003a2d Mon Sep 17 00:00:00 2001 From: Pierre-Marie de Rodat Date: Sat, 14 Oct 2017 17:07:35 +0000 Subject: [multiple changes] 2017-10-14 Eric Botcazou * layout.ads (Set_Elem_Alignment): Add Align parameter defaulted to 0. * layout.adb (Set_Elem_Alignment): Likewise. Use M name as maximum alignment for consistency. If Align is non-zero, use the minimum of Align and M for the alignment. * cstand.adb (Build_Float_Type): Use Set_Elem_Alignment instead of setting the alignment directly. 2017-10-14 Ed Schonberg * sem_prag.adb (Analyze_Pragma, case Check): Defer evaluation of the optional string in an Assert pragma until the expansion of the pragma has rewritten it as a conditional statement, so that the string argument is only evaluaed if the assertion fails. This is mandated by RM 11.4.2. 2017-10-14 Hristian Kirtchev * debug.adb: Switch -gnatd.v and associated flag are now used to enforce the SPARK rules for elaboration in SPARK code. * sem_elab.adb: Describe switch -gnatd.v. (Process_Call): Verify the SPARK rules only when -gnatd.v is in effect. (Process_Instantiation): Verify the SPARK rules only when -gnatd.v is in effect. (Process_Variable_Assignment): Clarify why variable assignments are processed reglardless of whether -gnatd.v is in effect. * doc/gnat_ugn/elaboration_order_handling_in_gnat.rst: Update the sections on elaboration code and compilation switches. * gnat_ugn.texi: Regenerate. 2017-10-14 Gary Dismukes * exp_util.adb, freeze.adb, sem_aggr.adb, sem_util.ads, sem_util.adb, sem_warn.adb: Minor reformattings. From-SVN: r253757 --- gcc/ada/layout.ads | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'gcc/ada/layout.ads') diff --git a/gcc/ada/layout.ads b/gcc/ada/layout.ads index 57aa93e4..246970f 100644 --- a/gcc/ada/layout.ads +++ b/gcc/ada/layout.ads @@ -74,10 +74,11 @@ package Layout is -- types, the RM_Size is simply set to zero. This routine also sets -- the Is_Constrained flag in Def_Id. - procedure Set_Elem_Alignment (E : Entity_Id); + procedure Set_Elem_Alignment (E : Entity_Id; Align : Nat := 0); -- The front end always sets alignments for elementary types by calling -- this procedure. Note that we have to do this for discrete types (since -- the Alignment attribute is static), so we might as well do it for all - -- elementary types, since the processing is the same. + -- elementary types, as the processing is the same. If Align is nonzero, + -- it is an external alignment setting that we must respect. end Layout; -- cgit v1.1