[Ada] Fix assertion failure on qualified type names in predicates
authorPiotr Trojanek <trojanek@adacore.com>
Mon, 6 Apr 2020 12:52:27 +0000 (14:52 +0200)
committerPierre-Marie de Rodat <derodat@adacore.com>
Tue, 16 Jun 2020 13:07:14 +0000 (09:07 -0400)
2020-06-16  Piotr Trojanek  <trojanek@adacore.com>

gcc/ada/

* sem_ch13.adb (Membership_Entry): Relax assertion to also
recognize qualified identifiers.

gcc/ada/sem_ch13.adb

index 19a0780cc1e27d0491eb2fd5fdcf5d24da20a34f..d7d5a47fded4e23ed9dffcc4642f3f4d5045befa 100644 (file)
@@ -8566,7 +8566,7 @@ package body Sem_Ch13 is
 
          --  Identifier (other than static expression) case
 
-         else pragma Assert (Nkind (N) = N_Identifier);
+         else pragma Assert (Nkind_In (N, N_Expanded_Name, N_Identifier));
 
             --  Type case