summaryrefslogtreecommitdiff
path: root/gcc/ada/sinfo.adb
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/ada/sinfo.adb')
-rw-r--r--gcc/ada/sinfo.adb43
1 files changed, 30 insertions, 13 deletions
diff --git a/gcc/ada/sinfo.adb b/gcc/ada/sinfo.adb
index 65ee94ef2c0..33f330143e5 100644
--- a/gcc/ada/sinfo.adb
+++ b/gcc/ada/sinfo.adb
@@ -6,7 +6,7 @@
-- --
-- B o d y --
-- --
--- Copyright (C) 1992-2004, Free Software Foundation, Inc. --
+-- Copyright (C) 1992-2005, 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- --
@@ -315,7 +315,7 @@ package body Sinfo is
pragma Assert (False
or else NT (N).Nkind = N_Component_Association
or else NT (N).Nkind = N_Formal_Package_Declaration
- or else NT (N).Nkind = N_Formal_Subprogram_Declaration);
+ or else NT (N).Nkind in N_Formal_Subprogram_Declaration);
return Flag15 (N);
end Box_Present;
@@ -328,11 +328,11 @@ package body Sinfo is
end By_Ref;
function Char_Literal_Value
- (N : Node_Id) return Char_Code is
+ (N : Node_Id) return Uint is
begin
pragma Assert (False
or else NT (N).Nkind = N_Character_Literal);
- return Char_Code2 (N);
+ return Uint2 (N);
end Char_Literal_Value;
function Chars
@@ -539,6 +539,14 @@ package body Sinfo is
return Node5 (N);
end Corresponding_Body;
+ function Corresponding_Formal_Spec
+ (N : Node_Id) return Node_Id is
+ begin
+ pragma Assert (False
+ or else NT (N).Nkind = N_Subprogram_Renaming_Declaration);
+ return Node3 (N);
+ end Corresponding_Formal_Spec;
+
function Corresponding_Generic_Association
(N : Node_Id) return Node_Id is
begin
@@ -620,7 +628,7 @@ package body Sinfo is
(N : Node_Id) return Node_Id is
begin
pragma Assert (False
- or else NT (N).Nkind = N_Formal_Subprogram_Declaration);
+ or else NT (N).Nkind in N_Formal_Subprogram_Declaration);
return Node2 (N);
end Default_Name;
@@ -2288,14 +2296,14 @@ package body Sinfo is
begin
pragma Assert (False
or else NT (N).Nkind = N_Abstract_Subprogram_Declaration
- or else NT (N).Nkind = N_Formal_Subprogram_Declaration
or else NT (N).Nkind = N_Generic_Package_Declaration
or else NT (N).Nkind = N_Generic_Subprogram_Declaration
or else NT (N).Nkind = N_Package_Declaration
or else NT (N).Nkind = N_Subprogram_Body
or else NT (N).Nkind = N_Subprogram_Body_Stub
or else NT (N).Nkind = N_Subprogram_Declaration
- or else NT (N).Nkind = N_Subprogram_Renaming_Declaration);
+ or else NT (N).Nkind = N_Subprogram_Renaming_Declaration
+ or else NT (N).Nkind in N_Formal_Subprogram_Declaration);
return Node1 (N);
end Specification;
@@ -2809,7 +2817,7 @@ package body Sinfo is
pragma Assert (False
or else NT (N).Nkind = N_Component_Association
or else NT (N).Nkind = N_Formal_Package_Declaration
- or else NT (N).Nkind = N_Formal_Subprogram_Declaration);
+ or else NT (N).Nkind in N_Formal_Subprogram_Declaration);
Set_Flag15 (N, Val);
end Set_Box_Present;
@@ -2822,11 +2830,11 @@ package body Sinfo is
end Set_By_Ref;
procedure Set_Char_Literal_Value
- (N : Node_Id; Val : Char_Code) is
+ (N : Node_Id; Val : Uint) is
begin
pragma Assert (False
or else NT (N).Nkind = N_Character_Literal);
- Set_Char_Code2 (N, Val);
+ Set_Uint2 (N, Val);
end Set_Char_Literal_Value;
procedure Set_Chars
@@ -3033,6 +3041,14 @@ package body Sinfo is
Set_Node5 (N, Val); -- semantic field, no parent set
end Set_Corresponding_Body;
+ procedure Set_Corresponding_Formal_Spec
+ (N : Node_Id; Val : Node_Id) is
+ begin
+ pragma Assert (False
+ or else NT (N).Nkind = N_Subprogram_Renaming_Declaration);
+ Set_Node3 (N, Val); -- semantic field, no parent set
+ end Set_Corresponding_Formal_Spec;
+
procedure Set_Corresponding_Generic_Association
(N : Node_Id; Val : Node_Id) is
begin
@@ -3041,6 +3057,7 @@ package body Sinfo is
or else NT (N).Nkind = N_Object_Renaming_Declaration);
Set_Node5 (N, Val); -- semantic field, no parent set
end Set_Corresponding_Generic_Association;
+
procedure Set_Corresponding_Integer_Value
(N : Node_Id; Val : Uint) is
begin
@@ -3113,7 +3130,7 @@ package body Sinfo is
(N : Node_Id; Val : Node_Id) is
begin
pragma Assert (False
- or else NT (N).Nkind = N_Formal_Subprogram_Declaration);
+ or else NT (N).Nkind in N_Formal_Subprogram_Declaration);
Set_Node2_With_Parent (N, Val);
end Set_Default_Name;
@@ -4772,14 +4789,14 @@ package body Sinfo is
begin
pragma Assert (False
or else NT (N).Nkind = N_Abstract_Subprogram_Declaration
- or else NT (N).Nkind = N_Formal_Subprogram_Declaration
or else NT (N).Nkind = N_Generic_Package_Declaration
or else NT (N).Nkind = N_Generic_Subprogram_Declaration
or else NT (N).Nkind = N_Package_Declaration
or else NT (N).Nkind = N_Subprogram_Body
or else NT (N).Nkind = N_Subprogram_Body_Stub
or else NT (N).Nkind = N_Subprogram_Declaration
- or else NT (N).Nkind = N_Subprogram_Renaming_Declaration);
+ or else NT (N).Nkind = N_Subprogram_Renaming_Declaration
+ or else NT (N).Nkind in N_Formal_Subprogram_Declaration);
Set_Node1_With_Parent (N, Val);
end Set_Specification;