From 5f6061af2d05babf0c0053d51592a0612d23a196 Mon Sep 17 00:00:00 2001 From: Arnaud Charlet Date: Tue, 24 Mar 2015 13:21:37 +0100 Subject: [PATCH] [multiple changes] 2015-03-24 Ed Schonberg * sem_ch13.adb (Rep_Item_Too_Early): allow pragma Convention on generic type. 2015-03-24 Gary Dismukes * inline.adb: Minor typo fix. From-SVN: r221629 --- gcc/ada/ChangeLog | 9 +++++++++ gcc/ada/inline.adb | 2 +- gcc/ada/sem_ch13.adb | 2 ++ 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index dc0f8537f9d..e0613e527eb 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,12 @@ +2015-03-24 Ed Schonberg + + * sem_ch13.adb (Rep_Item_Too_Early): allow pragma Convention + on generic type. + +2015-03-24 Gary Dismukes + + * inline.adb: Minor typo fix. + 2015-03-24 Arnaud Charlet * doc/gnat_ugn/building_executable_programs_with_gnat.rst, diff --git a/gcc/ada/inline.adb b/gcc/ada/inline.adb index 936b056d6da..cf53aae810a 100644 --- a/gcc/ada/inline.adb +++ b/gcc/ada/inline.adb @@ -1337,7 +1337,7 @@ package body Inline is is function Has_Formal_With_Discriminant_Dependent_Fields (Id : Entity_Id) return Boolean; - -- Returns true if the subprogram has at least one formal parameters of + -- Returns true if the subprogram has at least one formal parameter of -- an unconstrained record type with per-object constraints on component -- types. diff --git a/gcc/ada/sem_ch13.adb b/gcc/ada/sem_ch13.adb index fc230109044..6f68e9afbfb 100644 --- a/gcc/ada/sem_ch13.adb +++ b/gcc/ada/sem_ch13.adb @@ -11738,6 +11738,8 @@ package body Sem_Ch13 is elsif Is_Type (T) and then Is_Generic_Type (Root_Type (T)) + and then (Nkind (N) /= N_Pragma + or else Get_Pragma_Id (N) /= Pragma_Convention) then Error_Msg_N ("representation item not allowed for generic type", N); return True; -- 2.30.2