summaryrefslogtreecommitdiff
path: root/gcc/ada/par-ch3.adb
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@gcc.gnu.org>2004-01-12 12:45:26 +0100
committerArnaud Charlet <charlet@gcc.gnu.org>2004-01-12 12:45:26 +0100
commita397db9637a45274b4acc4ebcba14ae3506d5b80 (patch)
tree9a40f2549e1bdb5877d519b870509751de706702 /gcc/ada/par-ch3.adb
parent16bf3959da2377ebbb88ff56ecdc618e70acae6d (diff)
downloadgcc-a397db9637a45274b4acc4ebcba14ae3506d5b80.tar.gz
[multiple changes]
2004-01-12 Laurent Pautet <pautet@act-europe.fr> * 3vsocthi.adb, 3vsocthi.ads, 3wsocthi.adb, 3wsocthi.ads, 3zsocthi.adb, 3zsocthi.ads, g-socthi.adb, g-socthi.ads (Socket_Error_Message): Return C.Strings.chars_ptr instead of String. * g-socket.adb (Raise_Socket_Error): Use new Socket_Error_Message signature. 2004-01-12 Javier Miranda <miranda@gnat.com> * cstand.adb, exp_aggr.adb, exp_ch3.adb, exp_ch9.adb, exp_dist.adb, exp_imgv.adb, exp_pakd.adb, exp_util.adb, par-ch3.adb, sem.adb, sem_ch3.adb, sem_dist.adb, sem_prag.adb, sem_res.adb, sem_util.adb, sinfo.adb, sinfo.ads, sprint.adb: Addition of Component_Definition node. 2004-01-12 Ed Falis <falis@gnat.com> * impunit.adb: Add GNAT.Secondary_Stack_Info as user-visible unit 2004-01-12 Thomas Quinot <quinot@act-europe.fr> * link.c: Change default libgnat kind to STATIC for FreeBSD. 2004-01-12 Ed Schonberg <schonberg@gnat.com> * lib-xref.adb (Get_Type_Reference): If the type is the subtype entity generated to rename a generic actual, go to the actual itself, the subtype is not a user-visible entity. * sem_ch7.adb (Uninstall_Declarations): If an entity in the visible part is a private subtype, reset the visibility of its full view, if any, to be consistent. 2004-01-12 Robert Dewar <dewar@gnat.com> * trans.c (Eliminate_Error_Msg): New procedure called to generate msg * usage.adb: Remove mention of obsolete -gnatwb switch Noticed during code reading 2004-01-12 Jerome Guitton <guitton@act-europe.fr> * 1ssecsta.adb: Minor changes for -gnatwa warnings 2004-01-12 GNAT Script <nobody@gnat.com> * Make-lang.in: Makefile automatically updated From-SVN: r75714
Diffstat (limited to 'gcc/ada/par-ch3.adb')
-rw-r--r--gcc/ada/par-ch3.adb39
1 files changed, 24 insertions, 15 deletions
diff --git a/gcc/ada/par-ch3.adb b/gcc/ada/par-ch3.adb
index 8236c5897d7..44c809d9738 100644
--- a/gcc/ada/par-ch3.adb
+++ b/gcc/ada/par-ch3.adb
@@ -6,7 +6,7 @@
-- --
-- B o d y --
-- --
--- Copyright (C) 1992-2003, Free Software Foundation, Inc. --
+-- Copyright (C) 1992-2004, 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- --
@@ -2018,10 +2018,11 @@ package body Ch3 is
-- Error recovery: can raise Error_Resync
function P_Array_Type_Definition return Node_Id is
- Array_Loc : Source_Ptr;
- Def_Node : Node_Id;
- Subs_List : List_Id;
- Scan_State : Saved_Scan_State;
+ Array_Loc : Source_Ptr;
+ CompDef_Node : Node_Id;
+ Def_Node : Node_Id;
+ Subs_List : List_Id;
+ Scan_State : Saved_Scan_State;
begin
Array_Loc := Token_Ptr;
@@ -2079,12 +2080,16 @@ package body Ch3 is
T_Right_Paren;
T_Of;
+ CompDef_Node := New_Node (N_Component_Definition, Token_Ptr);
+
if Token = Tok_Aliased then
- Set_Aliased_Present (Def_Node, True);
+ Set_Aliased_Present (CompDef_Node, True);
Scan; -- past ALIASED
end if;
- Set_Subtype_Indication (Def_Node, P_Subtype_Indication);
+ Set_Subtype_Indication (CompDef_Node, P_Subtype_Indication);
+ Set_Component_Definition (Def_Node, CompDef_Node);
+
return Def_Node;
end P_Array_Type_Definition;
@@ -2728,11 +2733,12 @@ package body Ch3 is
-- items, do we need to add this capability sometime in the future ???
procedure P_Component_Items (Decls : List_Id) is
- Decl_Node : Node_Id;
- Scan_State : Saved_Scan_State;
- Num_Idents : Nat;
- Ident : Nat;
- Ident_Sloc : Source_Ptr;
+ CompDef_Node : Node_Id;
+ Decl_Node : Node_Id;
+ Scan_State : Saved_Scan_State;
+ Num_Idents : Nat;
+ Ident : Nat;
+ Ident_Sloc : Source_Ptr;
Idents : array (Int range 1 .. 4096) of Entity_Id;
-- This array holds the list of defining identifiers. The upper bound
@@ -2783,13 +2789,15 @@ package body Ch3 is
Scan;
end if;
+ CompDef_Node := New_Node (N_Component_Definition, Token_Ptr);
+
if Token_Name = Name_Aliased then
Check_95_Keyword (Tok_Aliased, Tok_Identifier);
end if;
if Token = Tok_Aliased then
Scan; -- past ALIASED
- Set_Aliased_Present (Decl_Node, True);
+ Set_Aliased_Present (CompDef_Node, True);
end if;
if Token = Tok_Array then
@@ -2797,8 +2805,9 @@ package body Ch3 is
raise Error_Resync;
end if;
- Set_Subtype_Indication (Decl_Node, P_Subtype_Indication);
- Set_Expression (Decl_Node, Init_Expr_Opt);
+ Set_Subtype_Indication (CompDef_Node, P_Subtype_Indication);
+ Set_Component_Definition (Decl_Node, CompDef_Node);
+ Set_Expression (Decl_Node, Init_Expr_Opt);
if Ident > 1 then
Set_Prev_Ids (Decl_Node, True);