diff options
author | Eric Botcazou <ebotcazou@adacore.com> | 2010-04-16 15:04:26 +0000 |
---|---|---|
committer | Eric Botcazou <ebotcazou@gcc.gnu.org> | 2010-04-16 15:04:26 +0000 |
commit | 860603449e04d4a21c9b695e72232639d8bf4f34 (patch) | |
tree | 1b898ebbf96f3d1614cf445a68b90becfcb2e0a9 /gcc/ada/gcc-interface/trans.c | |
parent | 9b04d6de98437348c1423741c6987ad3c958913b (diff) | |
download | gcc-860603449e04d4a21c9b695e72232639d8bf4f34.zip gcc-860603449e04d4a21c9b695e72232639d8bf4f34.tar.gz gcc-860603449e04d4a21c9b695e72232639d8bf4f34.tar.bz2 |
gigi.h (gnat_init_decl_processing): Delete.
* gcc-interface/gigi.h (gnat_init_decl_processing): Delete.
* gcc-interface/decl.c (gnat_to_gnu_entity): Constify a few variables.
<object>: Do not create the fake PARM_DECL if no debug info is needed.
Do not create the corresponding VAR_DECL of a CONST_DECL for debugging
purposes if no debug info is needed.
Fix formatting. Reorder and add comments.
* gcc-interface/trans.c (gnat_to_gnu) <N_Attribute_Reference>: Constify
variable and remove obsolete comment.
* gcc-interface/utils.c (convert_vms_descriptor64): Tweak comment.
(convert_vms_descriptor32): Likewise.
(convert): Remove dead code.
<UNCONSTRAINED_ARRAY_REF>: Pass the field instead of its name to build
the reference to the P_ARRAY pointer.
<POINTER_TYPE>: Likewise.
(maybe_unconstrained_array) <UNCONSTRAINED_ARRAY_TYPE>: Likewise.
(gnat_init_decl_processing): Delete, move contents to...
* gcc-interface/misc.c (gnat_init): ...here.
From-SVN: r158428
Diffstat (limited to 'gcc/ada/gcc-interface/trans.c')
-rw-r--r-- | gcc/ada/gcc-interface/trans.c | 29 |
1 files changed, 14 insertions, 15 deletions
diff --git a/gcc/ada/gcc-interface/trans.c b/gcc/ada/gcc-interface/trans.c index e2a480d..7f35bc2 100644 --- a/gcc/ada/gcc-interface/trans.c +++ b/gcc/ada/gcc-interface/trans.c @@ -4285,21 +4285,20 @@ gnat_to_gnu (Node_Id gnat_node) case N_Attribute_Reference: { - /* The attribute designator (like an enumeration value). */ - int attribute = Get_Attribute_Id (Attribute_Name (gnat_node)); - - /* The Elab_Spec and Elab_Body attributes are special in that - Prefix is a unit, not an object with a GCC equivalent. Similarly - for Elaborated, since that variable isn't otherwise known. */ - if (attribute == Attr_Elab_Body || attribute == Attr_Elab_Spec) - return (create_subprog_decl - (create_concat_name (Entity (Prefix (gnat_node)), - attribute == Attr_Elab_Body - ? "elabb" : "elabs"), - NULL_TREE, void_ftype, NULL_TREE, false, true, true, NULL, - gnat_node)); - - gnu_result = Attribute_to_gnu (gnat_node, &gnu_result_type, attribute); + /* The attribute designator. */ + const int attr = Get_Attribute_Id (Attribute_Name (gnat_node)); + + /* The Elab_Spec and Elab_Body attributes are special in that Prefix + is a unit, not an object with a GCC equivalent. */ + if (attr == Attr_Elab_Spec || attr == Attr_Elab_Body) + return + create_subprog_decl (create_concat_name + (Entity (Prefix (gnat_node)), + attr == Attr_Elab_Body ? "elabb" : "elabs"), + NULL_TREE, void_ftype, NULL_TREE, false, + true, true, NULL, gnat_node); + + gnu_result = Attribute_to_gnu (gnat_node, &gnu_result_type, attr); } break; |