From: Arnaud Charlet Date: Thu, 25 Jun 2020 09:36:54 +0000 (-0400) Subject: [Ada] Crash when specifying an abstract subprogram with Stream_Convert X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=6f238680dd3091f7431f3e1b571ea3c51f8ce2b4;p=gcc.git [Ada] Crash when specifying an abstract subprogram with Stream_Convert gcc/ada/ * sem_prag.adb (Check_OK_Stream_Convert_Function): Check for abstract subprograms. --- diff --git a/gcc/ada/sem_prag.adb b/gcc/ada/sem_prag.adb index b3fa7344dac..38761983508 100644 --- a/gcc/ada/sem_prag.adb +++ b/gcc/ada/sem_prag.adb @@ -23719,6 +23719,9 @@ package body Sem_Prag is Error_Pragma_Arg ("argument for pragma% must be function of one argument", Arg); + elsif Is_Abstract_Subprogram (Ent) then + Error_Pragma_Arg + ("argument for pragma% cannot be abstract", Arg); end if; end Check_OK_Stream_Convert_Function;