From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr1-x432.google.com (mail-wr1-x432.google.com [IPv6:2a00:1450:4864:20::432]) by sourceware.org (Postfix) with ESMTPS id 92154388883B for ; Mon, 22 May 2023 08:51:12 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 92154388883B Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=adacore.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=adacore.com Received: by mail-wr1-x432.google.com with SMTP id ffacd0b85a97d-30a8dc89c33so698568f8f.0 for ; Mon, 22 May 2023 01:51:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=adacore.com; s=google; t=1684745471; x=1687337471; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=nX1O91XPeNjoSTljvl/kKOtGqF70O4AQqxdx5Mhs3rg=; b=Gplvz3XJWNta36lpK7bY4pREKeHZZaka2g+qdljqS1iONy8Z4SR/Xymqq0IMISAdwK vMP4MHHa1o2WyK37MvCxw2L1CsXaNDt8g8icocFGvj9x6Q2EXYhtGdmQZu8ewGPJXFMX SmGGIt8eS1u9NZ7n3Ycm/VrSDXmxVR491+ZUuzNfyGlOJQH/VnOq4DrUj4FeRulX3G7b IrWhHeqRXgDyDWdpuXlP7JOaCoyYaAUuHf0YuOSC5/Ezm/pudxbC/YZcceuOR8tqMFtG +y/Wxh+o4z4oMKHIDnO6fB/NvWWlmsVnJmDoH/ZhR8iBp+lI4Lceo0JBW5jyB+7P7k7b E0rQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684745471; x=1687337471; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=nX1O91XPeNjoSTljvl/kKOtGqF70O4AQqxdx5Mhs3rg=; b=FsHObTjHUOUgiQmgJ+xlu2k6Z9jnstmMRewA3kSCKOEixrhvjCZTRuTq3647ASRDlA rdPwmZlxX2NH3KwvtZX73qbAiu0E7kWWXqHY1sdzNP1BGq12N38kvqR1Q1BpQ+zcqAKE CY9f4I3DqdmlE63sWrdPI0IzydMBLxqxXNYGqK3K6NrBbmoptpxOJHROLMRNkrzbU75Q RQJJJShcJ4VVJxA94n/BIWEhx+7JPTjsjLEFEvyNlNOe8e6EQxr5V5TxnOKakioaZFwX NxF+h4yPgKEQYg5JNNQF9pUWGNDrW6d0F8axVcdYAcoU4xzeMcAF9w30+UEM0z6LVB2z l3mA== X-Gm-Message-State: AC+VfDxLFxpPL8xXSdpEIn9o12VyrDIYzckkk5nS96kpmcOmhtmrjOel a8WERCxpjVPf2Y1KCqmUIV4Ihv6IDVOuchRApnZsDw== X-Google-Smtp-Source: ACHHUZ5D3QHGWrtHQwa4RfXEet31JeglJTcB2UUtxvK/NHvHHw+GNkst5oXXVRMoYZztTVA0Zx+Jiw== X-Received: by 2002:adf:f211:0:b0:306:372d:7891 with SMTP id p17-20020adff211000000b00306372d7891mr7149563wro.59.1684745471347; Mon, 22 May 2023 01:51:11 -0700 (PDT) Received: from poulhies-Precision-5550.telnowedge.local (lmontsouris-659-1-24-67.w81-250.abo.wanadoo.fr. [81.250.175.67]) by smtp.gmail.com with ESMTPSA id f20-20020a7bc8d4000000b003f6038faa19sm3811619wml.19.2023.05.22.01.51.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 22 May 2023 01:51:10 -0700 (PDT) From: =?UTF-8?q?Marc=20Poulhi=C3=A8s?= To: gcc-patches@gcc.gnu.org Cc: Bob Duff Subject: [COMMITTED] ada: Rename Is_Past_Self_Hiding_Point flag to be Is_Not_Self_Hidden Date: Mon, 22 May 2023 10:51:09 +0200 Message-Id: <20230522085109.1726939-1-poulhies@adacore.com> X-Mailer: git-send-email 2.40.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-13.5 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: From: Bob Duff ...which seems clearer. Still work in progress. gcc/ada/ * cstand.adb (Is_Past_Self_Hiding_Point): Rename to be Is_Not_Self_Hidden. * einfo.ads: Likewise. * exp_aggr.adb: Likewise. * gen_il-fields.ads: Likewise. * gen_il-gen-gen_entities.adb: Likewise. * sem.adb: Likewise. * sem_aggr.adb: Likewise. * sem_ch11.adb: Likewise. * sem_ch12.adb: Likewise. * sem_ch5.adb: Likewise. * sem_ch6.adb: Likewise. * sem_ch7.adb: Likewise. * sem_prag.adb: Likewise. Tested on x86_64-pc-linux-gnu, committed on master. --- gcc/ada/cstand.adb | 4 ++-- gcc/ada/einfo.ads | 4 ++-- gcc/ada/exp_aggr.adb | 2 +- gcc/ada/gen_il-fields.ads | 2 +- gcc/ada/gen_il-gen-gen_entities.adb | 2 +- gcc/ada/sem.adb | 6 +++--- gcc/ada/sem_aggr.adb | 6 +++--- gcc/ada/sem_ch11.adb | 2 +- gcc/ada/sem_ch12.adb | 8 ++++---- gcc/ada/sem_ch5.adb | 8 ++++---- gcc/ada/sem_ch6.adb | 4 ++-- gcc/ada/sem_ch7.adb | 4 ++-- gcc/ada/sem_prag.adb | 2 +- 13 files changed, 27 insertions(+), 27 deletions(-) diff --git a/gcc/ada/cstand.adb b/gcc/ada/cstand.adb index f53015d1e0c..3646003b330 100644 --- a/gcc/ada/cstand.adb +++ b/gcc/ada/cstand.adb @@ -1784,7 +1784,7 @@ package body CStand is Set_Is_Immediately_Visible (Ident_Node, True); Set_Is_Intrinsic_Subprogram (Ident_Node, True); - Set_Is_Past_Self_Hiding_Point (Ident_Node); + Set_Is_Not_Self_Hidden (Ident_Node); Set_Name_Entity_Id (Op, Ident_Node); Append_Entity (Ident_Node, Standard_Standard); @@ -1810,7 +1810,7 @@ package body CStand is -- frozen and not self-hidden as soon as they are created. Set_Is_Frozen (E); - Set_Is_Past_Self_Hiding_Point (E); + Set_Is_Not_Self_Hidden (E); -- Set debug information required for all standard types diff --git a/gcc/ada/einfo.ads b/gcc/ada/einfo.ads index c67731c1298..0cc4b495bd9 100644 --- a/gcc/ada/einfo.ads +++ b/gcc/ada/einfo.ads @@ -3104,7 +3104,7 @@ package Einfo is -- procedure which verifies the invariants of the partial view of a -- private type or private extension. --- Is_Past_Self_Hiding_Point +-- Is_Not_Self_Hidden -- Defined in all entities. Roughly speaking, this is False if the -- declaration of the entity is hidden from all visibility because -- we are within its declaration, as defined by 8.3(16-18). When @@ -4957,7 +4957,7 @@ package Einfo is -- Is_Obsolescent -- Is_Package_Body_Entity -- Is_Packed_Array_Impl_Type - -- Is_Past_Self_Hiding_Point + -- Is_Not_Self_Hidden -- Is_Potentially_Use_Visible -- Is_Preelaborated -- Is_Primitive_Wrapper diff --git a/gcc/ada/exp_aggr.adb b/gcc/ada/exp_aggr.adb index e2f0ccdb34a..40dd1c4d41b 100644 --- a/gcc/ada/exp_aggr.adb +++ b/gcc/ada/exp_aggr.adb @@ -2057,7 +2057,7 @@ package body Exp_Aggr is Set_Etype (L_J, Any_Type); Mutate_Ekind (L_J, E_Variable); - Set_Is_Past_Self_Hiding_Point (L_J); + Set_Is_Not_Self_Hidden (L_J); Set_Scope (L_J, Ent); else L_J := Make_Temporary (Loc, 'J', L); diff --git a/gcc/ada/gen_il-fields.ads b/gcc/ada/gen_il-fields.ads index 19ebf6744d0..fd89fac869d 100644 --- a/gcc/ada/gen_il-fields.ads +++ b/gcc/ada/gen_il-fields.ads @@ -752,7 +752,7 @@ package Gen_IL.Fields is Is_Package_Body_Entity, Is_Packed, Is_Packed_Array_Impl_Type, - Is_Past_Self_Hiding_Point, + Is_Not_Self_Hidden, Is_Param_Block_Component_Type, Is_Partial_Invariant_Procedure, Is_Potentially_Use_Visible, diff --git a/gcc/ada/gen_il-gen-gen_entities.adb b/gcc/ada/gen_il-gen-gen_entities.adb index 6356de0ee2e..d531e4a8efa 100644 --- a/gcc/ada/gen_il-gen-gen_entities.adb +++ b/gcc/ada/gen_il-gen-gen_entities.adb @@ -177,7 +177,7 @@ begin -- Gen_IL.Gen.Gen_Entities Sm (Is_Package_Body_Entity, Flag), Sm (Is_Packed, Flag, Impl_Base_Type_Only), Sm (Is_Packed_Array_Impl_Type, Flag), - Sm (Is_Past_Self_Hiding_Point, Flag), + Sm (Is_Not_Self_Hidden, Flag), Sm (Is_Potentially_Use_Visible, Flag), Sm (Is_Preelaborated, Flag), Sm (Is_Private_Descendant, Flag), diff --git a/gcc/ada/sem.adb b/gcc/ada/sem.adb index b0b492b0099..3bff8d26a0d 100644 --- a/gcc/ada/sem.adb +++ b/gcc/ada/sem.adb @@ -760,7 +760,7 @@ package body Sem is Debug_A_Exit ("analyzing ", N, " (done)"); - -- Set Is_Past_Self_Hiding_Point flag. RM-8.3(16) says a declaration + -- Set Is_Not_Self_Hidden flag. RM-8.3(16) says a declaration -- is no longer hidden from all visibility after "the end of the -- declaration", so we set the flag here (in addition to setting it -- elsewhere to handle the "except..." cases of 8.3(16)). However, @@ -777,8 +777,8 @@ package body Sem is and then Ekind (Scope (E)) = E_Record_Type then null; -- Set it later, in Analyze_Component_Declaration - elsif not Is_Past_Self_Hiding_Point (E) then - Set_Is_Past_Self_Hiding_Point (E); + elsif not Is_Not_Self_Hidden (E) then + Set_Is_Not_Self_Hidden (E); end if; end if; end; diff --git a/gcc/ada/sem_aggr.adb b/gcc/ada/sem_aggr.adb index bd01903a2d2..b44708a3e8c 100644 --- a/gcc/ada/sem_aggr.adb +++ b/gcc/ada/sem_aggr.adb @@ -1844,7 +1844,7 @@ package body Sem_Aggr is Set_Etype (Id, Index_Typ); Mutate_Ekind (Id, E_Variable); - Set_Is_Past_Self_Hiding_Point (Id); + Set_Is_Not_Self_Hidden (Id); Set_Scope (Id, Scop); end if; @@ -3133,7 +3133,7 @@ package body Sem_Aggr is end if; Mutate_Ekind (Id, E_Variable); - Set_Is_Past_Self_Hiding_Point (Id); + Set_Is_Not_Self_Hidden (Id); Set_Scope (Id, Ent); Set_Referenced (Id); @@ -3506,7 +3506,7 @@ package body Sem_Aggr is if No (Scope (Id)) then Set_Etype (Id, Index_Type); Mutate_Ekind (Id, E_Variable); - Set_Is_Past_Self_Hiding_Point (Id); + Set_Is_Not_Self_Hidden (Id); Set_Scope (Id, Ent); end if; Enter_Name (Id); diff --git a/gcc/ada/sem_ch11.adb b/gcc/ada/sem_ch11.adb index d07c480b042..6d519ebdd41 100644 --- a/gcc/ada/sem_ch11.adb +++ b/gcc/ada/sem_ch11.adb @@ -234,7 +234,7 @@ package body Sem_Ch11 is Enter_Name (Choice); Mutate_Ekind (Choice, E_Variable); - Set_Is_Past_Self_Hiding_Point (Choice); + Set_Is_Not_Self_Hidden (Choice); if RTE_Available (RE_Exception_Occurrence) then Set_Etype (Choice, RTE (RE_Exception_Occurrence)); diff --git a/gcc/ada/sem_ch12.adb b/gcc/ada/sem_ch12.adb index 7191e42fecb..181392c2132 100644 --- a/gcc/ada/sem_ch12.adb +++ b/gcc/ada/sem_ch12.adb @@ -3186,7 +3186,7 @@ package body Sem_Ch12 is Renaming_In_Par := Make_Defining_Identifier (Loc, Chars (Gen_Unit)); Mutate_Ekind (Renaming_In_Par, E_Package); - Set_Is_Past_Self_Hiding_Point (Renaming_In_Par); + Set_Is_Not_Self_Hidden (Renaming_In_Par); Set_Etype (Renaming_In_Par, Standard_Void_Type); Set_Scope (Renaming_In_Par, Parent_Instance); Set_Parent (Renaming_In_Par, Parent (Formal)); @@ -3847,7 +3847,7 @@ package body Sem_Ch12 is Enter_Name (Id); Mutate_Ekind (Id, E_Generic_Package); - Set_Is_Past_Self_Hiding_Point (Id); + Set_Is_Not_Self_Hidden (Id); Set_Etype (Id, Standard_Void_Type); -- Set SPARK_Mode from context @@ -4095,7 +4095,7 @@ package body Sem_Ch12 is Set_Etype (Id, Standard_Void_Type); end if; - Set_Is_Past_Self_Hiding_Point (Id); + Set_Is_Not_Self_Hidden (Id); -- Analyze the aspects of the generic copy to ensure that all generated -- pragmas (if any) perform their semantic effects. @@ -4340,7 +4340,7 @@ package body Sem_Ch12 is Generate_Definition (Act_Decl_Id); Mutate_Ekind (Act_Decl_Id, E_Package); - Set_Is_Past_Self_Hiding_Point (Act_Decl_Id); + Set_Is_Not_Self_Hidden (Act_Decl_Id); -- Initialize list of incomplete actuals before analysis diff --git a/gcc/ada/sem_ch5.adb b/gcc/ada/sem_ch5.adb index 4919e5372ac..f2fb0c74b73 100644 --- a/gcc/ada/sem_ch5.adb +++ b/gcc/ada/sem_ch5.adb @@ -2374,7 +2374,7 @@ package body Sem_Ch5 is -- iterator name. Mutate_Ekind (Def_Id, E_Variable); - Set_Is_Past_Self_Hiding_Point (Def_Id); + Set_Is_Not_Self_Hidden (Def_Id); -- Provide a link between the iterator variable and the container, for -- subsequent use in cross-reference and modification information. @@ -2653,7 +2653,7 @@ package body Sem_Ch5 is else Mutate_Ekind (Def_Id, E_Loop_Parameter); - Set_Is_Past_Self_Hiding_Point (Def_Id); + Set_Is_Not_Self_Hidden (Def_Id); Error_Msg_Ada_2012_Feature ("container iterator", Sloc (N)); -- OF present @@ -2707,7 +2707,7 @@ package body Sem_Ch5 is if Has_Aspect (Typ, Aspect_Variable_Indexing) then Mutate_Ekind (Def_Id, E_Variable); - Set_Is_Past_Self_Hiding_Point (Def_Id); + Set_Is_Not_Self_Hidden (Def_Id); end if; -- If the container is a constant, iterating over it @@ -3332,7 +3332,7 @@ package body Sem_Ch5 is end if; Mutate_Ekind (Id, E_Loop_Parameter); - Set_Is_Past_Self_Hiding_Point (Id); + Set_Is_Not_Self_Hidden (Id); -- A quantified expression which appears in a pre- or post-condition may -- be analyzed multiple times. The analysis of the range creates several diff --git a/gcc/ada/sem_ch6.adb b/gcc/ada/sem_ch6.adb index df069670ad0..0b374c2f01d 100644 --- a/gcc/ada/sem_ch6.adb +++ b/gcc/ada/sem_ch6.adb @@ -5245,7 +5245,7 @@ package body Sem_Ch6 is Set_Etype (Designator, Standard_Void_Type); end if; - Set_Is_Past_Self_Hiding_Point (Designator); + Set_Is_Not_Self_Hidden (Designator); -- Flag Is_Inlined_Always is True by default, and reversed to False for -- those subprograms which could be inlined in GNATprove mode (because @@ -13427,7 +13427,7 @@ package body Sem_Ch6 is Mutate_Ekind (Formal_Id, E_In_Parameter); end if; - Set_Is_Past_Self_Hiding_Point (Formal_Id); + Set_Is_Not_Self_Hidden (Formal_Id); -- Set Is_Known_Non_Null for access parameters since the language -- guarantees that access parameters are always non-null. We also set diff --git a/gcc/ada/sem_ch7.adb b/gcc/ada/sem_ch7.adb index fe0429a2044..5021d0ee04f 100644 --- a/gcc/ada/sem_ch7.adb +++ b/gcc/ada/sem_ch7.adb @@ -1187,7 +1187,7 @@ package body Sem_Ch7 is Generate_Definition (Id); Enter_Name (Id); Mutate_Ekind (Id, E_Package); - Set_Is_Past_Self_Hiding_Point (Id); + Set_Is_Not_Self_Hidden (Id); -- Needed early because of Set_Categorization_From_Pragmas below Set_Etype (Id, Standard_Void_Type); @@ -2729,7 +2729,7 @@ package body Sem_Ch7 is Mutate_Ekind (Id, E_Private_Type); end if; - Set_Is_Past_Self_Hiding_Point (Id); + Set_Is_Not_Self_Hidden (Id); Set_Etype (Id, Id); Set_Has_Delayed_Freeze (Id); Set_Is_First_Subtype (Id); diff --git a/gcc/ada/sem_prag.adb b/gcc/ada/sem_prag.adb index ba4c75e7c96..234b02d7b72 100644 --- a/gcc/ada/sem_prag.adb +++ b/gcc/ada/sem_prag.adb @@ -12205,7 +12205,7 @@ package body Sem_Prag is Set_Comes_From_Source (State_Id, not Is_Null); Set_Parent (State_Id, State); Mutate_Ekind (State_Id, E_Abstract_State); - Set_Is_Past_Self_Hiding_Point (State_Id); + Set_Is_Not_Self_Hidden (State_Id); Set_Etype (State_Id, Standard_Void_Type); Set_Encapsulating_State (State_Id, Empty); -- 2.40.0