[Ada] Add guard against previous error for peculiar ACATS test
authorEric Botcazou <ebotcazou@adacore.com>
Tue, 2 Nov 2021 15:54:36 +0000 (16:54 +0100)
committerPierre-Marie de Rodat <derodat@adacore.com>
Wed, 10 Nov 2021 08:57:38 +0000 (08:57 +0000)
gcc/ada/

* sem_ch4.adb (Find_Non_Universal_Interpretations): Add guard.

gcc/ada/sem_ch4.adb

index 9b1d908..6a3d857 100644 (file)
@@ -6685,6 +6685,12 @@ package body Sem_Ch4 is
       It    : Interp;
 
    begin
+      --  Defend against previous error
+
+      if Nkind (R) = N_Error then
+         return;
+      end if;
+
       if T1 = Universal_Integer or else T1 = Universal_Real
 
         --  If the left operand of an equality operator is null, the visibility