From 0f5356c4bfeb42fcab6e2681709a386abf2c0ba1 Mon Sep 17 00:00:00 2001 From: Ghjuvan Lacambre Date: Fri, 18 Jun 2021 17:18:41 +0200 Subject: [PATCH] [Ada] Only assign type to op if compatible gcc/ada/ * sem_ch4.adb (Find_Non_Universal_Interpretations): Check if types are compatible before adding interpretation. --- gcc/ada/sem_ch4.adb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/ada/sem_ch4.adb b/gcc/ada/sem_ch4.adb index c052022..553e194 100644 --- a/gcc/ada/sem_ch4.adb +++ b/gcc/ada/sem_ch4.adb @@ -6626,7 +6626,7 @@ package body Sem_Ch4 is Get_Next_Interp (Index, It); end loop; end if; - else + elsif Has_Compatible_Type (R, T1) then Add_One_Interp (N, Op_Id, Standard_Boolean, Base_Type (T1)); end if; end Find_Non_Universal_Interpretations; -- 2.7.4