diff options
author | Hristian Kirtchev <kirtchev@adacore.com> | 2017-01-13 10:19:19 +0000 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2017-01-13 11:19:19 +0100 |
commit | d8f43ee6d0921b73670e8e123cdd0850dfeb330e (patch) | |
tree | f478a14a0fa94b8594e529f0aa178c5afedad3df /gcc/ada/sem.adb | |
parent | d4bf622fbf9018b4ffbb743fef37c7af0fa419c6 (diff) | |
download | gcc-d8f43ee6d0921b73670e8e123cdd0850dfeb330e.zip gcc-d8f43ee6d0921b73670e8e123cdd0850dfeb330e.tar.gz gcc-d8f43ee6d0921b73670e8e123cdd0850dfeb330e.tar.bz2 |
sem_aggr.adb, [...]: Update all eligible case statements to reflect the new style for case alternatives.
2017-01-13 Hristian Kirtchev <kirtchev@adacore.com>
* sem_aggr.adb, par_sco.adb, s-osprim-mingw.adb, exp_ch5.adb,
exp_prag.adb, sem_ch3.adb, xr_tabls.adb, lib-xref-spark_specific.adb,
layout.adb, sem_dist.adb, exp_spark.adb, exp_ch7.adb, gnatcmd.adb,
exp_util.adb, prj-proc.adb, sem_aux.adb, comperr.adb, g-memdum.adb,
exp_attr.adb, s-intman-solaris.adb, exp_ch9.adb, make.adb, live.adb,
g-sercom-linux.adb, sem_dim.adb, mlib-prj.adb, s-intman-posix.adb,
sem_ch9.adb, sem_ch10.adb, prep.adb, einfo.adb, scng.adb, checks.adb,
prj-strt.adb, sem_prag.adb, eval_fat.adb, sem_ch12.adb, sem.adb,
a-numaux-x86.adb, a-stwifi.adb, i-cobol.adb, prj.adb,
get_spark_xrefs.adb, s-tasini.adb, rtsfind.adb, freeze.adb,
g-arrspl.adb, par-ch4.adb, sem_util.adb, sem_res.adb, expander.adb,
sem_attr.adb, exp_dbug.adb, prj-pp.adb, a-stzfix.adb, s-interr.adb,
s-wchcnv.adb, switch-m.adb, gnat1drv.adb, sinput-l.adb, stylesw.adb,
contracts.adb, s-intman-android.adb, g-expect.adb, exp_ch4.adb,
g-comlin.adb, errout.adb, sinput.adb, s-exctra.adb, repinfo.adb,
g-spipat.adb, g-debpoo.adb, exp_ch6.adb, sem_ch4.adb, exp_ch13.adb,
a-wtedit.adb, validsw.adb, pprint.adb, widechar.adb, makeutl.adb,
ali.adb, set_targ.adb, sem_mech.adb, sem_ch6.adb, gnatdll.adb,
get_scos.adb, g-pehage.adb, s-tratas-default.adb, gnatbind.adb,
prj-dect.adb, g-socthi-mingw.adb, par-prag.adb, prj-nmsc.adb,
exp_disp.adb, par-ch12.adb, binde.adb, sem_ch8.adb,
s-tfsetr-default.adb, s-regexp.adb, gprep.adb, s-tpobop.adb,
a-teioed.adb, sem_warn.adb, sem_eval.adb, g-awk.adb, s-io.adb,
a-ztedit.adb, xoscons.adb, exp_intr.adb, sem_cat.adb, sprint.adb,
g-socket.adb, exp_dist.adb, sem_ch13.adb, s-tfsetr-vxworks.adb,
par-ch3.adb, treepr.adb, g-forstr.adb, g-catiio.adb, par-ch5.adb,
uname.adb, osint.adb, exp_ch3.adb, prj-env.adb, a-strfix.adb,
a-stzsup.adb, prj-tree.adb, s-fileio.adb: Update all eligible case
statements to reflect the new style for case alternatives. Various
code clean up and reformatting.
From-SVN: r244406
Diffstat (limited to 'gcc/ada/sem.adb')
-rw-r--r-- | gcc/ada/sem.adb | 152 |
1 files changed, 77 insertions, 75 deletions
diff --git a/gcc/ada/sem.adb b/gcc/ada/sem.adb index 74d77ab..f06f684 100644 --- a/gcc/ada/sem.adb +++ b/gcc/ada/sem.adb @@ -643,9 +643,10 @@ package body Sem is -- the call to analyze them is generated when the full list is -- analyzed. - when N_SCIL_Dispatch_Table_Tag_Init | - N_SCIL_Dispatching_Call | - N_SCIL_Membership_Test => + when N_SCIL_Dispatch_Table_Tag_Init + | N_SCIL_Dispatching_Call + | N_SCIL_Membership_Test + => null; -- For the remaining node types, we generate compiler abort, because @@ -655,64 +656,65 @@ package body Sem is -- node appears only in the context of a type declaration, and is -- processed by the analyze routine for type declarations. - when N_Abortable_Part | - N_Access_Definition | - N_Access_Function_Definition | - N_Access_Procedure_Definition | - N_Access_To_Object_Definition | - N_Aspect_Specification | - N_Case_Expression_Alternative | - N_Case_Statement_Alternative | - N_Compilation_Unit_Aux | - N_Component_Association | - N_Component_Clause | - N_Component_Definition | - N_Component_List | - N_Constrained_Array_Definition | - N_Contract | - N_Decimal_Fixed_Point_Definition | - N_Defining_Character_Literal | - N_Defining_Identifier | - N_Defining_Operator_Symbol | - N_Defining_Program_Unit_Name | - N_Delta_Constraint | - N_Derived_Type_Definition | - N_Designator | - N_Digits_Constraint | - N_Discriminant_Association | - N_Discriminant_Specification | - N_Elsif_Part | - N_Entry_Call_Statement | - N_Enumeration_Type_Definition | - N_Exception_Handler | - N_Floating_Point_Definition | - N_Formal_Decimal_Fixed_Point_Definition | - N_Formal_Derived_Type_Definition | - N_Formal_Discrete_Type_Definition | - N_Formal_Floating_Point_Definition | - N_Formal_Modular_Type_Definition | - N_Formal_Ordinary_Fixed_Point_Definition | - N_Formal_Private_Type_Definition | - N_Formal_Incomplete_Type_Definition | - N_Formal_Signed_Integer_Type_Definition | - N_Function_Specification | - N_Generic_Association | - N_Index_Or_Discriminant_Constraint | - N_Iterated_Component_Association | - N_Iteration_Scheme | - N_Mod_Clause | - N_Modular_Type_Definition | - N_Ordinary_Fixed_Point_Definition | - N_Parameter_Specification | - N_Pragma_Argument_Association | - N_Procedure_Specification | - N_Real_Range_Specification | - N_Record_Definition | - N_Signed_Integer_Type_Definition | - N_Unconstrained_Array_Definition | - N_Unused_At_Start | - N_Unused_At_End | - N_Variant => + when N_Abortable_Part + | N_Access_Definition + | N_Access_Function_Definition + | N_Access_Procedure_Definition + | N_Access_To_Object_Definition + | N_Aspect_Specification + | N_Case_Expression_Alternative + | N_Case_Statement_Alternative + | N_Compilation_Unit_Aux + | N_Component_Association + | N_Component_Clause + | N_Component_Definition + | N_Component_List + | N_Constrained_Array_Definition + | N_Contract + | N_Decimal_Fixed_Point_Definition + | N_Defining_Character_Literal + | N_Defining_Identifier + | N_Defining_Operator_Symbol + | N_Defining_Program_Unit_Name + | N_Delta_Constraint + | N_Derived_Type_Definition + | N_Designator + | N_Digits_Constraint + | N_Discriminant_Association + | N_Discriminant_Specification + | N_Elsif_Part + | N_Entry_Call_Statement + | N_Enumeration_Type_Definition + | N_Exception_Handler + | N_Floating_Point_Definition + | N_Formal_Decimal_Fixed_Point_Definition + | N_Formal_Derived_Type_Definition + | N_Formal_Discrete_Type_Definition + | N_Formal_Floating_Point_Definition + | N_Formal_Modular_Type_Definition + | N_Formal_Ordinary_Fixed_Point_Definition + | N_Formal_Private_Type_Definition + | N_Formal_Incomplete_Type_Definition + | N_Formal_Signed_Integer_Type_Definition + | N_Function_Specification + | N_Generic_Association + | N_Index_Or_Discriminant_Constraint + | N_Iterated_Component_Association + | N_Iteration_Scheme + | N_Mod_Clause + | N_Modular_Type_Definition + | N_Ordinary_Fixed_Point_Definition + | N_Parameter_Specification + | N_Pragma_Argument_Association + | N_Procedure_Specification + | N_Real_Range_Specification + | N_Record_Definition + | N_Signed_Integer_Type_Definition + | N_Unconstrained_Array_Definition + | N_Unused_At_End + | N_Unused_At_Start + | N_Variant + => raise Program_Error; end case; @@ -1745,16 +1747,16 @@ package body Sem is pragma Assert (No (CU) or else Nkind (CU) = N_Compilation_Unit); case Nkind (Item) is - when N_Generic_Subprogram_Declaration | - N_Generic_Package_Declaration | - N_Package_Declaration | - N_Subprogram_Declaration | - N_Subprogram_Renaming_Declaration | - N_Package_Renaming_Declaration | - N_Generic_Function_Renaming_Declaration | - N_Generic_Package_Renaming_Declaration | - N_Generic_Procedure_Renaming_Declaration => - + when N_Generic_Function_Renaming_Declaration + | N_Generic_Package_Declaration + | N_Generic_Package_Renaming_Declaration + | N_Generic_Procedure_Renaming_Declaration + | N_Generic_Subprogram_Declaration + | N_Package_Declaration + | N_Package_Renaming_Declaration + | N_Subprogram_Declaration + | N_Subprogram_Renaming_Declaration + => -- Specs are OK null; @@ -1774,10 +1776,10 @@ package body Sem is or else CU = Cunit (Main_Unit)); null; - when N_Function_Instantiation | - N_Procedure_Instantiation | - N_Package_Instantiation => - + when N_Function_Instantiation + | N_Package_Instantiation + | N_Procedure_Instantiation + => -- Can only happen if some generic body (needed for gnat2scil -- traversal, but not by GNAT) is not available, ignore. |