summaryrefslogtreecommitdiff
path: root/gcc/ada/par-ch9.adb
diff options
context:
space:
mode:
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2009-04-17 09:30:39 +0000
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2009-04-17 09:30:39 +0000
commit557df72fbfb9353abc6fdf027a770043d4a1aeb7 (patch)
treedc9767c938b339ff6ffccf318357c7538dcffd5f /gcc/ada/par-ch9.adb
parent723bd33267a8f139333ce119effb718ca5d30c89 (diff)
downloadgcc-557df72fbfb9353abc6fdf027a770043d4a1aeb7.tar.gz
2009-04-17 Gary Dismukes <dismukes@adacore.com>
* par-ch6.adb (P_Subprogram): Overriding indicators should be allowed on protected subprogram bodies, so exclude the case where Pf_Flags is Pf_Decl_Pbod from the error check. * par-ch9.adb (P_Protected_Operation_Items): Permit overriding indicators on subprograms in protected bodies, and proceed with parsing the subprogram. * sem_ch6.adb (Verify_Overriding_Indicator): Exclude protected subprograms from the check for primitiveness on subprograms with overriding indicators. (Check_Overriding_Indicator): Include protected subprograms in the style check for missing overriding indicators. 2009-04-17 Tristan Gingold <gingold@adacore.com> * init.c: Fix stack checking for x86 Darwin. 2009-04-17 Vincent Celier <celier@adacore.com> * prj-attr.adb: New project level attribute Object_File_Suffix (<language>). * prj-nmsc.adb (Add_Source): Use the object file suffix to get the object file name (Process_Compiler): Process attribute Object_File_Suffix * prj.adb (Object_Name): Use suffix Object_File_Suffix instead of platform suffix, when specified. * prj.ads (Language_Config): New component Object_File_Suffix, defaulted to No_Name. (Object_Name): New parameter Object_File_Suffix, defaulted to No_Name * snames.ads-tmpl: New standard name Object_File_Suffix git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@146228 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/par-ch9.adb')
-rw-r--r--gcc/ada/par-ch9.adb7
1 files changed, 7 insertions, 0 deletions
diff --git a/gcc/ada/par-ch9.adb b/gcc/ada/par-ch9.adb
index fcf2d3c69b4..d5c3549f23d 100644
--- a/gcc/ada/par-ch9.adb
+++ b/gcc/ada/par-ch9.adb
@@ -736,9 +736,16 @@ package body Ch9 is
if Token = Tok_Entry or else Bad_Spelling_Of (Tok_Entry) then
Append (P_Entry_Body, Item_List);
+ -- If the operation starts with procedure, function, or an overriding
+ -- indicator ("overriding" or "not overriding"), parse a subprogram.
+
elsif Token = Tok_Function or else Bad_Spelling_Of (Tok_Function)
or else
Token = Tok_Procedure or else Bad_Spelling_Of (Tok_Procedure)
+ or else
+ Token = Tok_Overriding or else Bad_Spelling_Of (Tok_Overriding)
+ or else
+ Token = Tok_Not or else Bad_Spelling_Of (Tok_Not)
then
Append (P_Subprogram (Pf_Decl_Pbod), Item_List);