diff options
author | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-10-22 10:26:01 +0000 |
---|---|---|
committer | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-10-22 10:26:01 +0000 |
commit | 9b1d6aeb6f58709871e1b2a00e5b430aa01c6cfb (patch) | |
tree | 3a1452e51a811170156c699e84b2cbe12f49dc63 /gcc/ada/par-ch5.adb | |
parent | c9d7c2c0013262f8fbd9b41320c1c5eccbd8bdac (diff) | |
download | gcc-9b1d6aeb6f58709871e1b2a00e5b430aa01c6cfb.tar.gz |
2010-10-22 Thomas Quinot <quinot@adacore.com>
* sem_ch3.adb (Complete_Private_Subtype): The full view of the subtype
may already have a rep item chain inherited from the full view of the
base type, so do not overwrite it when propagating rep items from the
partial view of the subtype.
* sem_ch3.adb: Minor code reorganization. Minor reformatting.
2010-10-22 Sergey Rybin <rybin@adacore.com>
* gnat_ugn.texi (gnatmetric): Remove description of debug option.
2010-10-22 Tristan Gingold <gingold@adacore.com>
* adaint.c (__gnat_number_of_cpus): Add implementation for VMS.
2010-10-22 Ed Schonberg <schonberg@adacore.com>
* par-ch5.adb: Set properly starting sloc of loop parameter.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@165818 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/par-ch5.adb')
-rw-r--r-- | gcc/ada/par-ch5.adb | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/gcc/ada/par-ch5.adb b/gcc/ada/par-ch5.adb index 400b3e1deb5..489707ece97 100644 --- a/gcc/ada/par-ch5.adb +++ b/gcc/ada/par-ch5.adb @@ -1711,11 +1711,19 @@ package body Ch5 is -- during analysis of the loop parameter specification. if Token = Tok_Of or else Token = Tok_Colon then + + if Ada_Version < Ada_2012 then + Error_Msg_SC ("iterator is an Ada2012 feature"); + end if; + return P_Iterator_Specification (ID_Node); end if; + -- The span of the Loop_Parameter_Specification starts at the + -- defining identifier. + Loop_Param_Specification_Node := - New_Node (N_Loop_Parameter_Specification, Token_Ptr); + New_Node (N_Loop_Parameter_Specification, Sloc (ID_Node)); Set_Defining_Identifier (Loop_Param_Specification_Node, ID_Node); if Token = Tok_Left_Paren then @@ -1753,7 +1761,7 @@ package body Ch5 is Node1 : Node_Id; begin - Node1 := New_Node (N_Iterator_Specification, Token_Ptr); + Node1 := New_Node (N_Iterator_Specification, Sloc (Def_Id)); Set_Defining_Identifier (Node1, Def_Id); if Token = Tok_Colon then |