sem_ch8.adb (Analyze_Package_Renaming): Skip analysis if Name is Error.
authorRobert Dewar <dewar@gnat.com>
Fri, 26 Oct 2001 01:46:11 +0000 (01:46 +0000)
committerGeert Bosch <bosch@gcc.gnu.org>
Fri, 26 Oct 2001 01:46:11 +0000 (03:46 +0200)
* sem_ch8.adb (Analyze_Package_Renaming): Skip analysis if Name
        is Error. Similar change for other renaming cases.

From-SVN: r46519

gcc/ada/ChangeLog
gcc/ada/sem_ch8.adb

index 763f741..d65039b 100644 (file)
@@ -1,5 +1,10 @@
 2001-10-25  Robert Dewar <dewar@gnat.com>
 
+       * sem_ch8.adb (Analyze_Package_Renaming): Skip analysis if Name 
+        is Error. Similar change for other renaming cases.
+
+2001-10-25  Robert Dewar <dewar@gnat.com>
+
        * s-atacco.ads: Add pragma Inline_Always for functions.
        Fix header format. Add copyright 2001
 
index ab90a10..3947eb8 100644 (file)
@@ -6,7 +6,7 @@
 --                                                                          --
 --                                 B o d y                                  --
 --                                                                          --
---                            $Revision: 1.583 $
+--                            $Revision$
 --                                                                          --
 --          Copyright (C) 1992-2001, Free Software Foundation, Inc.         --
 --                                                                          --
@@ -545,6 +545,10 @@ package body Sem_Ch8 is
       Inst  : Boolean   := False; -- prevent junk warning
 
    begin
+      if Name (N) = Error then
+         return;
+      end if;
+
       Generate_Definition (New_P);
 
       if Current_Scope /= Standard_Standard then
@@ -605,6 +609,10 @@ package body Sem_Ch8 is
       T2  : Entity_Id;
 
    begin
+      if Nam = Error then
+         return;
+      end if;
+
       Set_Is_Pure (Id, Is_Pure (Current_Scope));
       Enter_Name (Id);
 
@@ -716,6 +724,10 @@ package body Sem_Ch8 is
       Spec  : Node_Id;
 
    begin
+      if Name (N) = Error then
+         return;
+      end if;
+
       --  Apply Text_IO kludge here, since we may be renaming one of
       --  the children of Text_IO