From ca7e6c2640e197797b544a7238d1e362f85c2921 Mon Sep 17 00:00:00 2001 From: Arnaud Charlet Date: Mon, 26 Oct 2015 12:29:13 +0100 Subject: [multiple changes] 2015-10-26 Hristian Kirtchev * inline.adb: Minor reformatting. 2015-10-26 Yannick Moy * get_spark_xrefs.adb (get_SPARK_Xrefs): Remove obsolete assertion. * lib-xref-spark_specific.adb (Traverse_Declaration_Or_Statement): New procedure to factor duplicated code and add treatment of protected entries. (Add_SPARK_Scope, Traverse_Declarations_Or_Statements): Call the new procedure Traverse_Declaration_Or_Statement. Use same character used in normal xrefs for SPARK xrefs, for a given entity used as scope. * spark_xrefs.ads Document character used for entries. * sem_prag.adb (Check_Loop_Pragma_Placement): Account for possible introduction of declarations and statements by the expansion, between two otherwise consecutive loop pragmas. * sem_util.ads, sem_util.adb (Is_Suspension_Object): Lifted from nested function. (Is_Descendant_Of_Suspension_Object): nested function lifted. 2015-10-26 Hristian Kirtchev * sem_attr.adb (Eval_Attribute): Attribute 'Enum_Rep can be folded when its prefix denotes a constant, an enumeration literal or an enumeration type. Use the expression of the attribute in the enumeration type form, otherwise use the prefix to fold. From-SVN: r229334 --- gcc/ada/inline.adb | 23 ++++++++--------------- 1 file changed, 8 insertions(+), 15 deletions(-) (limited to 'gcc/ada/inline.adb') diff --git a/gcc/ada/inline.adb b/gcc/ada/inline.adb index 2bee192..99b536c 100644 --- a/gcc/ada/inline.adb +++ b/gcc/ada/inline.adb @@ -3462,14 +3462,12 @@ package body Inline is if Nkind (D) = N_Package_Declaration then Cannot_Inline - ("cannot inline & (nested package declaration)?", - D, Subp); + ("cannot inline & (nested package declaration)?", D, Subp); return True; elsif Nkind (D) = N_Package_Instantiation then Cannot_Inline - ("cannot inline & (nested package instantiation)?", - D, Subp); + ("cannot inline & (nested package instantiation)?", D, Subp); return True; end if; @@ -3482,8 +3480,7 @@ package body Inline is or else Nkind (D) = N_Single_Task_Declaration then Cannot_Inline - ("cannot inline & (nested task type declaration)?", - D, Subp); + ("cannot inline & (nested task type declaration)?", D, Subp); return True; elsif Nkind (D) = N_Protected_Type_Declaration @@ -3496,22 +3493,19 @@ package body Inline is elsif Nkind (D) = N_Subprogram_Body then Cannot_Inline - ("cannot inline & (nested subprogram)?", - D, Subp); + ("cannot inline & (nested subprogram)?", D, Subp); return True; elsif Nkind (D) = N_Function_Instantiation and then not Is_Unchecked_Conversion (D) then Cannot_Inline - ("cannot inline & (nested function instantiation)?", - D, Subp); + ("cannot inline & (nested function instantiation)?", D, Subp); return True; elsif Nkind (D) = N_Procedure_Instantiation then Cannot_Inline - ("cannot inline & (nested procedure instantiation)?", - D, Subp); + ("cannot inline & (nested procedure instantiation)?", D, Subp); return True; -- Subtype declarations with predicates will generate predicate @@ -3535,9 +3529,8 @@ package body Inline is or else A_Id = Aspect_Dynamic_Predicate then Cannot_Inline - ("cannot inline & " - & "(subtype declaration with predicate)?", - D, Subp); + ("cannot inline & (subtype declaration with " + & "predicate)?", D, Subp); return True; end if; -- cgit v1.1