From: Arnaud Charlet Date: Mon, 6 Apr 2020 12:33:13 +0000 (-0400) Subject: [Ada] ACATS 4.1P - BC55001 - Error missed X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=e7680763dfd9ee980f95ffb865ef3ca7879d10c2;p=gcc.git [Ada] ACATS 4.1P - BC55001 - Error missed 2020-06-16 Arnaud Charlet gcc/ada/ * sem_ch6.adb (Analyze_Subprogram_Specification): Generate error message for functions returning interfaces. --- diff --git a/gcc/ada/sem_ch6.adb b/gcc/ada/sem_ch6.adb index 188ee7597dd..55f0c6bb102 100644 --- a/gcc/ada/sem_ch6.adb +++ b/gcc/ada/sem_ch6.adb @@ -5464,9 +5464,7 @@ package body Sem_Ch6 is N_Formal_Abstract_Subprogram_Declaration, N_Subprogram_Renaming_Declaration) then - if Is_Abstract_Type (Etype (Designator)) - and then not Is_Interface (Etype (Designator)) - then + if Is_Abstract_Type (Etype (Designator)) then Error_Msg_N ("function that returns abstract type must be abstract", N);