aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorJavier Miranda <miranda@adacore.com>2005-03-18 12:51:32 +0100
committerArnaud Charlet <charlet@gcc.gnu.org>2005-03-18 12:51:32 +0100
commit725e2a15a1d1d22063f0fbaf9d4b18565b846fd1 (patch)
treeaae9f57fedbe822cd05ca7e4ab0eea25e693a4f0 /gcc
parent5b846f5abbf88a936869bd31f8d154e88790529e (diff)
downloadgcc-725e2a15a1d1d22063f0fbaf9d4b18565b846fd1.zip
gcc-725e2a15a1d1d22063f0fbaf9d4b18565b846fd1.tar.gz
gcc-725e2a15a1d1d22063f0fbaf9d4b18565b846fd1.tar.bz2
sem_ch4.adb (Try_Primitive_Operation, [...]): Analyze the object that is accessible through the prefix of the subprogram call...
2005-03-17 Javier Miranda <miranda@adacore.com> * sem_ch4.adb (Try_Primitive_Operation, Class_Wide_Operation and Try_Object_Operation): Analyze the object that is accessible through the prefix of the subprogram call before we apply the transformation of the object-operation notation. From-SVN: r96674
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ada/sem_ch4.adb13
1 files changed, 10 insertions, 3 deletions
diff --git a/gcc/ada/sem_ch4.adb b/gcc/ada/sem_ch4.adb
index 21b962c..a7931e9 100644
--- a/gcc/ada/sem_ch4.adb
+++ b/gcc/ada/sem_ch4.adb
@@ -4805,7 +4805,6 @@ package body Sem_Ch4 is
Set_Analyzed (Call_Node, False);
Rewrite (Node_To_Replace, Call_Node);
Analyze (Node_To_Replace);
-
end Complete_Object_Operation;
--------------------------------
@@ -4920,6 +4919,9 @@ package body Sem_Ch4 is
-- Allocate the node only once
if not Present (Call_Node_Case) then
+ Analyze_Expression (Obj);
+ Set_Analyzed (Obj);
+
Transform_Object_Operation (
Call_Node => Call_Node_Case,
First_Actual => Obj,
@@ -5018,6 +5020,9 @@ package body Sem_Ch4 is
-- Allocate the node only once
if not Present (Call_Node_Case) then
+ Analyze_Expression (Obj);
+ Set_Analyzed (Obj);
+
Transform_Object_Operation (
Call_Node => Call_Node_Case,
First_Actual => Obj,
@@ -5093,8 +5098,7 @@ package body Sem_Ch4 is
if Is_Subprg_Call and then N = Name (Parent (N)) then
Actual := First (Parameter_Associations (Parent (N)));
while Present (Actual) loop
- Analyze (Actual);
- Check_Parameterless_Call (Actual);
+ Analyze_Expression (Actual);
Next (Actual);
end loop;
end if;
@@ -5110,6 +5114,9 @@ package body Sem_Ch4 is
First_Actual := Obj;
end if;
+ Analyze_Expression (First_Actual);
+ Set_Analyzed (First_Actual);
+
-- Build a subprogram call node
Transform_Object_Operation (