From: Arnaud Charlet Date: Tue, 8 Apr 2008 07:04:25 +0000 (+0200) Subject: Update comments. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=d5316f684c43291075518fd1a52e3a77db3ba6a7;p=gcc.git Update comments. From-SVN: r134073 --- diff --git a/gcc/ada/itypes.ads b/gcc/ada/itypes.ads index d677bf9f8fd..0d70c1d382d 100644 --- a/gcc/ada/itypes.ads +++ b/gcc/ada/itypes.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2007, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2008, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -38,7 +38,8 @@ package Itypes is -- Implicit types (Itypes) are types and subtypes created by the semantic -- phase or the expander to reflect the underlying semantics. These could -- be generated by building trees for corresponding declarations and then - -- analyzing these trees, but there are three reasons for not doing this: + -- analyzing these trees, but there are three reasons for not doing this + -- in some cases: -- 1. The declarations would require more tree nodes @@ -81,6 +82,25 @@ package Itypes is -- and for the array subtype. The associated node of each index subtype -- is the corresponding range expression. + -- Notes on the use of the Parent field of an Itype + + -- In some cases, we do create a declaration node for an itype, and in + -- such cases, the Parent field of the Itype points to this declaration + -- in the normal manner. This case can be detected by checking for a + -- non-empty Parent field referencing a declaration whose Defining_Entity + -- is the Itype in question. + + -- In some other cases, where we don't generate such a declaration, as + -- described above, the Itype is attached to the tree implicitly by being + -- referenced elsewhere, e.g. as the Etype of some object. In this case + -- the Parent field may be Empty. + + -- In other cases where we don't generate a declaration for the Itype, + -- the Itype may be attached to an arbitrary node in the tree, using + -- the Parent field. This Parent field may even reference a declaration + -- for a related different entity (hence the description of the tests + -- needed for the case where a declaration for the Itype is created). + ------------------ -- Create_Itype -- ------------------ @@ -115,8 +135,10 @@ package Itypes is -- The Scope_Id parameter specifies the scope of the created type, and -- is normally the Current_Scope as shown, but can be set otherwise. -- - -- If Ekind is in Access_Subprogram_Type_Kind, Can_Use_Internal_Rep is set - -- True, unless Always_Compatible_Rep_On_Target is True. + -- The size/align fields are initialized to unknown (Uint_0). + -- + -- If Ekind is in Access_Subprogram_Kind, Can_Use_Internal_Rep is set True, + -- unless Always_Compatible_Rep_On_Target is True. --------------------------------- -- Create_Null_Excluding_Itype --