summaryrefslogtreecommitdiff
path: root/gcc/ada/sinfo.ads
Commit message (Collapse)AuthorAgeFilesLines
* 2014-05-21 Robert Dewar <dewar@adacore.com>charlet2014-05-211-1/+1
| | | | | | | | * sinfo.ads, sem_ch12.adb, sem_warn.adb: Minor reformatting. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@210706 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-05-21 Robert Dewar <dewar@adacore.com>charlet2014-05-211-3/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * sem_elab.adb: Minor reformatting. * s-taprop.ads: Minor comment fix. * sem_ch8.adb (Analyze_Subprogram_Renaming): Remove call to Kill_Elaboration_Checks. * errout.adb, erroutc.adb: Minor reformatting. 2014-05-21 Thomas Quinot <quinot@adacore.com> * exp_pakd.adb (Byte_Swap): Handle the case of a sub-byte component. No byte swapping occurs, but this procedure also takes care of appropriately justifying the argument. 2014-05-21 Hristian Kirtchev <kirtchev@adacore.com> * sem_ch6.adb: sem_ch6.adb (Analyze_Aspects_On_Body_Or_Stub): New routine. (Analyze_Subprogram_Body_Helper): Move the analysis of aspect specifications and the processing of the subprogram body contract after inlining has taken place. (Diagnose_Misplaced_Aspect_Specifications): Removed. 2014-05-21 Javier Miranda <miranda@adacore.com> * sem_ch3.adb (Build_Derived_Record_Type): Revert previous change. 2014-05-21 Robert Dewar <dewar@adacore.com> * sem_eval.ads, sem_eval.adb (Why_Not_Static): Messages are not continuations any more. 2014-05-21 Ed Schonberg <schonberg@adacore.com> * sinfo.ads, sinfo.adb: New flag Needs_Initialized_Actual, present in formal_Private_Definitions and on private extension declarations of a formal derived type. Set when the use of the formal type in a generic suggests that the actual should be a fully initialized type. * sem_warn.adb (May_Need_Initialized_Actual): new subprogram to indicate that an entity of a generic type has default initialization, and that the corresponing actual type in any subsequent instantiation should be fully initialized. * sem_ch12.adb (Check_Initialized_Type): new subprogram, to emit a warning if the actual for a generic type on which Needs_Initialized_Actual is set is not a fully initialized type. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@210705 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-25 Robert Dewar <dewar@adacore.com>charlet2014-02-251-48/+50
| | | | | | | | | | | | | | | | * sinfo.ads: Minor reformatting. 2014-02-25 Tristan Gingold <gingold@adacore.com> * s-expllu.ads, s-expuns.ads, s-expmod.ads: Minor comment fix. 2014-02-25 Pascal Obry <obry@adacore.com> * sinput-l.adb, osint.adb, osint.ads: Add Prep_Suffix to factorize code. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@208132 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-25 Yannick Moy <moy@adacore.com>charlet2014-02-251-0/+4
| | | | | | | | | | | | | | * sem_prag.adb: Minor reformatting to get consistent messages. 2014-02-25 Robert Dewar <dewar@adacore.com> * checks.adb: Minor reformatting. * sinfo.ads (Do_Range_Check): Document that this flag is never passed to the back end. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@208129 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-24 Robert Dewar <dewar@adacore.com>charlet2014-02-241-8/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * sinfo.ads, sem_ch12.adb, sem_res.adb, sem_ch4.adb, par-ch12.adb: Minor reformatting. * atree.ads, atree.adb (Node35): New function. (Set_Node35): New procedure. * debug.adb: Define new debug flag -gnatd.X. * einfo.ads, einfo.adb (Import_Pragma): New field. * freeze.adb (Wrap_Imported_Procedure): New procedure (not really active yet, has to be activated with -gnatd.X. * sem_prag.adb (Set_Imported): Set new Import_Pragma field (Set_Imported): Don't set Is_Public (see Freeze.Wrap_Imported_Subprogram) * par-ch3.adb (P_Component_List): Handle unexpected null component. 2014-02-24 Yannick Moy <moy@adacore.com> * sem_ch3.adb: Correct reference to SPARK RM in error messages. * gnat_rm.texi: Correct documentation of attribute Update. 2014-02-24 Ed Schonberg <schonberg@adacore.com> * sem_ch5.adb (Analyze_Iterator_Specification): Reject container iterator in older versions of Ada. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@208076 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-24 Ed Schonberg <schonberg@adacore.com>charlet2014-02-241-1/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * sinfo.ads, sinfo.adb: New attribute Generalized_Indexing, for indexed_components that are instances of Ada 2012 container indexing operations. Analysis and resolution of such nodes is performed on the attribute, and the original source is preserved for ASIS operations. If expansion is enabled, the indexed component is replaced by the value of this attribute, which is in a call to an Indexing aspect, in most case wrapped in a dereference operation. * sem_ch4.adb (Analyze_Indexed_Component): Create Generalized_Indexing attribute when appropriate. (Analyze_Call): If prefix is not overloadable and has an indexing aspect, transform into an indexed component so it can be analyzed as a potential container indexing. (Analyze_Expression): If node is an indexed component with a Generalized_ Indexing, do not re-analyze. * sem_res.adb (Resolve_Generalized_Indexing): Complete resolution of an indexed_component that has been transformed into a container indexing operation. (Resolve_Indexed_Component): Call the above when required. (Resolve): Do not insert an explicit dereference operation on an indexed_component whose type has an implicit dereference: the operation is inserted when resolving the related Generalized_Indexing. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@208074 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-19 Robert Dewar <dewar@adacore.com>charlet2014-02-191-8/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * exp_attr.adb (Expand_Min_Max_Attribute): Use Insert_Declaration (Expand_Min_Max_Attribute): Use Matching_Standard_Type. * exp_ch4.adb (Expand_N_Expression_With_Actions): Remove special handling for the case of Modify_Tree_For_C, this approach did not work. * exp_util.adb (Matching_Standard_Type): New function (Side_Effect_Free): New top level functions (from Remove_Side_Effects). * exp_util.ads (Side_Effect_Free): New top level functions (moved from body). * sinfo.ads: Minor comment updates. 2014-02-19 Ed Schonberg <schonberg@adacore.com> * exp_ch6.adb (Expand_Simple_Function_Return): If return type is unconstrained and uses the secondary stack, mark the enclosing function accordingly, to ensure that the value is not prematurely removed. 2014-02-19 Hristian Kirtchev <kirtchev@adacore.com> * par.adb Alphabetize the routines in Par.Sync. (Resync_Past_Malformed_Aspect): New routine. * par-ch13.adb (Get_Aspect_Specifications): Alphabetize local variables. Code and comment reformatting. Detect missing parentheses on aspects [Refined_]Global and [Refined_]Depends with a non-null definition. * par-sync.adb: Alphabetize all routines in this separate unit. (Resync_Past_Malformed_Aspect): New routine. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207890 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-19 Yannick Moy <moy@adacore.com>charlet2014-02-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * sinfo.ads: Minor comment update. 2014-02-19 Hristian Kirtchev <kirtchev@adacore.com> * atree.ads: Minor reformatting (change Entity_Info to Einfo). 2014-02-19 Thomas Quinot <quinot@adacore.com> * exp_ch7.adb (Find_Node_To_Be_Wrapped): An assignment statement that has the No_Ctrl_Actions flag is a suitable node to be wrapped if the assigned expression has no finalization actions. * sem_eval.adb (Eval_Entity_Name): For a compile time known boolean value, mark the corresponding condition SCO as constant. 2014-02-19 Robert Dewar <dewar@adacore.com> * exp_util.adb: Minor reformatting. * exp_util.ads (Matching_Standard_Type): New function. * exp_ch7.adb: Minor reformatting. 2014-02-19 Ed Schonberg <schonberg@adacore.com> * sem_ch13.adb (Get_Cursor_Type): Use scope of iterable type to find declaration for Cursor, to handle properly the case of a discriminated iterable type. 2014-02-19 Vincent Celier <celier@adacore.com> * gnatcmd.adb (GNATCmd): Always replace the object dirs of imported library projects with the library ALI dirs, when setting the object paths. * prj-env.ads (Ada_Objects_Path): Correct comments about argument Including_Libraries. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207888 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-19 Yannick Moy <moy@adacore.com>charlet2014-02-191-0/+4
| | | | | | | | | | | | | | | | | | | | | | | * sem_ch10.adb (Analyze_Proper_Body): Issue error on missing subunit in GNATprove_Mode. * sinfo.ads (GNATprove_Mode): Document error issued in GNATprove_Mode. 2014-02-19 Hristian Kirtchev <kirtchev@adacore.com> * lib-xref.ads Alphabetize the contents of table Xref_Entity_Letters. Add an entry in table Xref_Entity_Letters for E_Abstract_State. List all letters and symbols in use. * sem_prag.adb (Analyze_Abstract_State): Update all calls to Create_Abstract_State to reflect the new signature. (Create_Abstract_State): Change subprogram profile and update the comment on usage. Use the proper location of the state declaration when creating a new abstract state entity. Do not generate an external name, but simply reuse the name coming from the state declaration. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207884 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-19 Robert Dewar <dewar@adacore.com>charlet2014-02-191-0/+4
| | | | | | | | | | * exp_ch4.adb (Expand_N_Expression_With_Actions): Make sure declarations get properly inserted in Modify_Tree_For_C mode. * sinfo.ads: Minor comment addition. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207883 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-19 Robert Dewar <dewar@adacore.com>charlet2014-02-191-0/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * exp_attr.adb (Expand_Min_Max_Attribute): New procedure (Expand_N_Attribute_Reference): Use this procedure for Min and Max. * exp_ch4.adb (Expand_N_Expression_With_Actions): Remove object declarations from list of actions. * output.ads, output.adb (Delete_Last_Char): New procedure. * sinfo.ads: Document handling of Mod and expression with actions in Modify_Tree_For_C mode. 2014-02-19 Ed Schonberg <schonberg@adacore.com> * par-ch9.adb (P_Task): Add a null statement to produce a well-formed task body when due to a previous syntax error the statement list is empty. 2014-02-19 Hristian Kirtchev <kirtchev@adacore.com> * sem_prag.adb (Check_Dependency_Clause): Account for the case where a state with a non-null refinement matches a null output list. Comment reformatting. (Inputs_Match): Copy a solitary input to avoid an assertion failure when trying to match the same input in multiple clauses. 2014-02-19 Gary Dismukes <dismukes@adacore.com> * sem_attr.adb: Minor typo fix. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207880 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-18 Robert Dewar <dewar@adacore.com>charlet2014-02-181-14/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * cstand.adb (Build_Signed_Integer_Type): Minor change of formal from Int to Nat (Build_Unsigned_Integer_Type): New procedure (Create_Standard): Create new unsigned types. * exp_ch4.adb (Expand_N_Op_Mod): Expand mod in Modify_Tree_For_C mode (Expand_N_Reference): Removed, problematic and not needed for now. * exp_ch4.ads (Expand_N_Reference): Removed, problematic and not needed for now. * exp_util.ads, exp_util.adb (Power_Of_Two): New function. * expander.adb: Remove call to Expand_N_Reference (problematic, and not needed now). * sem_aux.ads, sem_aux.adb (Corresponding_Unsigned_Type): New function. * stand.adb: Read and write unsigned type entities. * stand.ads: Add new unsigned types. 2014-02-18 Hristian Kirtchev <kirtchev@adacore.com> * sem_ch4.adb (Analyze_Call): Do not mark a function call as being inside an assertion expression as the flag is now removed. (Check_Ghost_Subprogram_Call): Do not query the In_Assertion_Expression flag as it is now removed, instead use a predicate function. * sem_elab.adb (Check_Internal_Call_Continue): Do not query the In_Assertion_Expression flag as it is now removed, instead use a predicate function. * sem_prag.ads: Add new table Assertion_Expression_Pragma. * sem_util.adb Add with and use clause for Sem_Prag. (In_Assertion_Expression_Pragma): New routine. * sem_util.ads (In_Assertion_Expression_Pragma): New routine. * sinfo.adb (In_Assertion_Expression): Removed. (Set_In_Assertion_Expression): Removed. * sinfo.ads Remove flag In_Assertion_Expression along with its use in nodes. (In_Assertion_Expression): Removed along with pragma Inline. (Set_In_Assertion_Expression): Removed along with pragma Inline. 2014-02-18 Sergey Rybin <rybin@adacore.com frybin> * gnat_ugn.texi: gnatpp section: add note that '-j' cannot be used together with '-r', '-rf' or '-rnb' options. 2014-02-18 Hristian Kirtchev <kirtchev@adacore.com> * sem_attr.adb (Analyze_Attribute): Comment and code reformatting. Use separate routines to check the legality of attribute 'Old in certain pragmas. Verify the use of 'Old, 'Result and locally declared entities within the prefix of 'Old. (Check_References_In_Prefix): New routine. (Check_Use_In_Contract_Cases): New routine. (Check_Use_In_Test_Case): New routine. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207843 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-06 Hristian Kirtchev <kirtchev@adacore.com>charlet2014-02-061-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * sem_prag.adb (Analyze_Refined_Pragma): Remove local variable Pack_Spec. Refinement pragmas may now apply to bodies of both visible and private subprograms. 2014-02-06 Robert Dewar <dewar@adacore.com> * exp_attr.adb (Expand_Loop_Entry_Attribute): Minor change (Attr => N) (Expand_Pred_Succ): New name Expand_Pred_Succ_Attribute (Expand_N_Attribute_Reference, case Max): Expand into if expression if Modify_Tree_For_C mode. (Expand_N_Attribute_Reference, case Min): ditto * sinfo.ads: Modify_Tree_For_C takes care of expanding Min and Max attributes. 2014-02-06 Ed Schonberg <schonberg@adacore.com> * sem_ch3.adb (Analyze_Object_Declaration): Do not generate predicate check if this is an internal declaration with No_Initialization set, as for an expanded aggregate component. 2014-02-06 Doug Rupp <rupp@adacore.com> * init.c (__gnat_default_resignal_p) [VMS]: Test for and resignal conditions with severity of "SUCCESS" or "INFORMATIONAL". git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207559 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-06 Sergey Rybin <rybin@adacore.com frybin>charlet2014-02-061-0/+28
| | | | | | | | | | | | | | | | | | | | | | * gnat_ugn.texi, vms_data.ads: Add documentation of -j option for gnatmetric. 2014-02-06 Robert Dewar <dewar@adacore.com> * exp_ch4.adb (Expand_N_Shift_Left): Handle shift counts greater than the word size when operating in Modify_Tree_For_C mode. * sinfo.ads: Add documentation section on Modify_Tree_For_C mode. 2014-02-06 Robert Dewar <dewar@adacore.com> * erroutc.adb (Warning_Specifically_Suppressed.Matches): compare is case insensitive. * gnat_rm.texi: Document that string compare for Warnings Off is now case insensitive. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207546 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-04 Robert Dewar <dewar@adacore.com>charlet2014-02-041-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * sinfo.ads: Further comments on N_Expression_With_Actions node. 2014-02-04 Hristian Kirtchev <kirtchev@adacore.com> * sem_prag.adb (Analyze_Refined_Depends_In_Decl_Part): Remove global variables Out_Items and Ref_Global. Remove local constant Body_Id along with dummy variables D1, D2, D3, D4, D5, D6, D7 and D8. Remove the useless collection of global items as this was a leftover from an earlier version of the routine. Move several routines out to avoid deep nesting and indentation. (Inputs_Match): Add formal parameter Dep_Clause. Rename formal parameter Do_Checks to Post_Errors. Update the comment on usage. (Is_Matching_Input): Renamed to Input_Match. Add formal parameters Ref_Inputs and Do_Checks. Rename formal parameter Do_Checks to Post_Errors. Update the comment on usage. Account for the case where a self referential state may have a null input_list. (Is_Self_Referential): New routine. 2014-02-04 Ed Schonberg <schonberg@adacore.com> * sem_ch13.adb (Analyze_Attribute_Definition_Clause): If the entity renames an expression, as in the case of an object of an unconstrained type initialized by a function call, defer the rewriting of the expression to the expander. * exp_ch13.adb (Expand_N_Attribute_Definition_Clause, case 'Alignment): If the entity renames an expression, introduce temporary to capture value, and rewrite original declaration to use temporary. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207467 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-02-04 Gary Dismukes <dismukes@adacore.com>charlet2014-02-041-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | * g-comlin.adb: Minor typo fix. 2014-02-04 Ed Schonberg <schonberg@adacore.com> * freeze.adb (Freeze_All): Types derived from a formal access_to_classwide type do not have a finalization master. 2014-02-04 Robert Dewar <dewar@adacore.com> * sprint.adb: Minor reformatting. 2014-02-04 Robert Dewar <dewar@adacore.com> * exp_ch4.adb (Expand_N_Expression_With_Actions): Eliminate cases where Actions is a null list. * sinfo.ads (N_Expression_With_Actions): Actions can be temporarily empty during semantic analysis, but must be non-empty in the final expanded tree. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207466 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-01-29 Hristian Kirtchev <kirtchev@adacore.com>charlet2014-01-291-0/+1
| | | | | | | | | | | | | | | | | | | | | | | * einfo.adb (Get_Pragma): Handle the retrieval of pragma Refined_Post. * einfo.ads (Get_Pragma): Update the comment on special pragmas handled by this routine. * sem_prag.adb (Analyze_Pragma): Add a legal pragma Refined_Post to the contract of the related subprogram body. * sem_util.adb (Add_Contract_Item): Handle the insertion of pragma Refined_Post into the contract of a subprogram body. * sinfo.ads Update the documentation of node N_Contract. * sem_res.adb (Resolve_Entity_Name): Add a guard to detect abstract states and variables only when checking the SPARK 2014 rules concerning volatile object placement. 2014-01-29 Ed Schonberg <schonberg@adacore.com> * sem_ch4.adb (Find_Equality_Types, Try_One_Interp): within an instance, null is compatible with any access type. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207269 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-01-29 Hristian Kirtchev <kirtchev@adacore.com>charlet2014-01-291-1/+1
| | | | | | | | | | | | | | | * sem_util.adb (Has_Enabled_Property): Compare the character field of the sole property. 2014-01-29 Robert Dewar <dewar@adacore.com> * sem_intr.adb, a-ztexio.ads, sinfo.ads, sem_res.adb, gnatlink.adb, vms_conv.adb, a-except.ads, a-except-2005.ads, a-teioed.adb, sem_warn.ads, treepr.ads, erroutc.ads, a-excach.adb: Minor reformatting. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207267 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-01-29 Robert Dewar <dewar@adacore.com>charlet2014-01-291-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * a-except-2005.adb, a-except.adb, a-excpol-abort.adb, a-exstat.adb, ali.adb, a-numaux.ads, a-numaux-darwin.ads, a-numaux-libc-x86.ads, a-numaux-vms.ads, a-numaux-vxworks.ads, a-numaux-x86.ads, aspects.ads, a-taside.adb, a-teioed.adb, a-textio.adb, a-textio.ads, atree.adb, atree.ads, a-witeio.adb, a-witeio.ads, a-wtedit.adb, a-ztedit.adb, a-ztexio.adb, bcheck.adb, binde.adb, checks.adb, comperr.adb, cstand.adb, debug_a.adb, einfo.ads, errout.adb, erroutc.adb, eval_fat.adb, exp_aggr.adb, exp_attr.adb, exp_ch11.adb, exp_ch3.adb, exp_ch4.adb, exp_ch5.adb, exp_ch6.adb, exp_ch9.adb, exp_dbug.adb, exp_disp.adb, exp_fixd.adb, exp_imgv.adb, exp_intr.adb, exp_util.adb, freeze.adb, frontend.adb, g-comlin.ads, g-mbdira.adb, gnat1drv.adb, gprep.adb, g-spipat.adb, i-cpp.ads, i-vxwork.ads, i-vxwork-x86.ads, krunch.ads, layout.adb, lib-load.adb, lib-writ.adb, lib-writ.ads, live.adb, namet.ads, osint.adb, osint-c.adb, output.ads, par.adb, par-ch10.adb, par-ch13.adb, par-ch3.adb, par-ch4.adb, par-ch5.adb, par-ch6.adb, par-ch9.adb, par-endh.adb, par-labl.adb, par-prag.adb, par-sync.adb, par-tchk.adb, par-util.adb, prj.adb, repinfo.adb, rtsfind.adb, s-arit64.adb, s-asthan-vms-alpha.adb, s-asthan-vms-ia64.adb, s-bignum.adb, scans.adb, scng.adb, s-dimmks.ads, sem_aggr.adb, sem_attr.adb, sem_aux.adb, sem_cat.adb, sem_ch10.adb, sem_ch12.adb, sem_ch13.adb, sem_ch13.ads, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb, sem_ch8.adb, sem_disp.adb, sem_elab.adb, sem_elim.adb, sem_eval.adb, sem_intr.adb, sem_prag.adb, sem_res.adb, sem_type.adb, sem_util.adb, sem_warn.adb, set_targ.adb, s-fatgen.adb, s-fatgen.ads, s-fileio.adb, s-imgcha.adb, s-imgrea.adb, sinfo.ads, sinput-c.adb, snames.ads-tmpl, s-os_lib.adb, sprint.adb, s-regpat.adb, s-secsta.adb, s-stalib.ads, s-stchop.adb, s-stoele.ads, stand.ads, s-taprop-solaris.adb, s-tasdeb-vms.adb, s-tasini.adb, s-tassta.adb, s-valdec.adb, s-valuti.adb, s-wchjis.adb, s-wchwts.adb, system.ads, system-vms_64.ads, system-vms-ia64.ads, treepr.adb, types.ads, uintp.adb, uname.adb, urealp.adb, usage.adb, vxaddr2line.adb: Minor reformatting. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207260 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-01-29 Hristian Kirtchev <kirtchev@adacore.com>charlet2014-01-291-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * aspects.adb Add an entry for aspect Part_Of in table Canonical_Aspect. * aspects.ads Add an entry for aspect Part_Of in tables Aspect_Id, Aspect_Argument, Aspect_Names and Aspect_Delay. * atree.h Define Elist9. * atree.adb (Elist9): New routine. (Set_Elist9): New routine. * atree.ads (Elist9): New routine. (Set_Elist9): New routine. * einfo.adb Add Part_Of_Constituents and Encapsulating_State to the list of node usage. Remove Refined_State from the list of node usage. (Encapsulating_State): New routine. (Get_Pragma): Handle pragma Part_Of; (Part_Of_Constituents): New routine. (Refined_State): Removed. (Set_Encapsulating_State): New routine. (Set_Part_Of_Constituents): New routine. (Set_Refined_State): Removed. (Write_Field9_Name): Add an entry for Part_Of_Constituents (Write_Field10_Name): Add an entry for Encapsulating_State. Remove the entry for Refined_State. * einfo.ads Add new attributes Encapsulating_State and Part_Of_Constituents alond with their usage in entities. Remove attribute Refined_State along with its usage in entities. (Encapsulating_State): New routine and pragma Inline. (Get_Pragma): Update the comment on usage. (Part_Of_Constituents): New routine and pragma Inline. (Refined_State): Removed along with pragma Inline. (Set_Encapsulating_State): New routine and pragma Inline. (Set_Part_Of_Constituents): New routine and pragma Inline. (Set_Refined_State): Removed along with pragma Inline. * par-prag.adb Pragma Part_Of does not need any special processing by the parser. * sem_ch3.adb (Analyze_Declarations): Remove local variables Body_Id and Prag. Call separate routines to analyze the contract of a package [body]. (Analyze_Object_Contract): Update the comment on usage. Remove local variables Items and Nam. Use Get_Pragma rather than traversing the classification list. Verify whether the lack of indicator Part_Of agrees with the placement of the variable in state space. (Analyze_Object_Declaration): Initialize the encapsulating state of a variable. (Requires_State_Refinement): Moved to sem_util. * sem_ch7.adb (Analyze_Package_Body_Contract): New routine. (Analyze_Package_Contract): New routine. * sem_ch7.ads (Analyze_Package_Body_Contract): New routine. (Analyze_Package_Contract): New routine. * sem_ch10.adb (Decorate_State): Initialize the encapsulating state and Part_Of constituents. * sem_ch13.adb (Analyze_Aspect_Specifications): Add processing for aspect Part_Of. Update all calls to Decorate_Delayed_Aspect_And_Pragma. (Check_Aspect_At_Freeze_Point): Aspect Part_Of does not need any special processing at freeze time. (Decorate_Delayed_Aspect_And_Pragma): Renamed to Decorate_Aspect_And_Pragma. Add formal parameter Delayed and update the associated comment. * sem_prag.adb Add an entry for pragma Part_Of in table Sig_Flags. (Analyze_Abstract_State): Add new global variable State_Id. Remove local constants Errors and Loc. Remove local variables Is_Null and State_Nam. Create the entity of the abstract state on the spot, before all remaining checks are performed. Verify that a missing Part_Of option agrees with the placement of the abstract state within the state space. (Analyze_Depends_In_Decl_Part): Add new global variables Constits_Seen and States_Seen. Check that a state and a corresponding constituent do not appear in pragma [Refined_]Depends. (Analyze_Global_In_Decl_Part): Add new global variables Constits_Seen and States_Seen. Check that a state and a corresponding constituent do not appear in pragma [Refined_]Global. (Analyze_Global_Item): Remove the now obsolete code that deals with Part_Of. Add the entity of the global item to the list of processed items. (Analyze_Initializes_In_Decl_Part): Add new global variables Constits_Seen and States_Seen. Check that a state and a corresponding constituent do not appear in pragma Initializes. (Analyze_Initialization_Item): Add the entity of the initialization item to the list of processed items. (Analyze_Input_Item): Add the entity of the initialization item to the list of processed items. (Analyze_Input_Output): Remove the now obsolete code that deals with Part_Of. Add the entity of the input/output to the list of processed items. (Analyze_Part_Of): New routine. (Analyze_Part_Of_Option): Remove local constant Par_State. Add local constant Encaps and local variables Encaps_Id and Legal. Use Analyze_Part of to analyze the option. Turn the related state into a Part_Of constituent if the option is legal. (Analyze_Pragma): Add processing for pragma Part_Of. (Analyze_Refined_State_In_Decl_Part): Remove global constants Pack_Body and Spec_Id. Remove global variables Abstr_States and Hidden_States. Add new global variables Available_States, Body_Id, Body_States and Spec_Id. Add new local constant Body_Decl. Reimplement the logic that extracts the states available for refinement from the related package and the body hidden states of the said package. (Analyze_Refinement_Clause): Add local variable Part_Of_Constits. (Check_Applicable_Policy): Alphabetize body. (Check_Dependency_Clause): Replace Refined_State with Encapsulating_State. (Check_Matching_Constituent): Reimplement the logic that determines whether an item is a valid / invalid constituent of the current refined state. Return when a construct does not denote a valid abstract state. Extract the list of Part_Of constituents for further analysis. Check that all Part_Of constituents of a state have been used in its refinement. (Check_Matching_State): Update the comment on usage. Operate on the list of available states. (Check_Missing_Part_Of): New routine. (Check_Refined_Global_Item): Replace Refined_State with Encapsulating_State. (Check_State_And_Constituent_Use): New routine. (Create_Abstract_State): New routine. (Is_Matching_Input): Replace Refined_State with Encapsulating_State. (Is_Part_Of): Removed. (Collect_Body_States): New routine. (Collect_Constituent): Replace Refined_State with Encapsulating_State. (Collect_Hidden_States): Removed. (Report_Unrefined_States): Change the profile of the procedure along with the comment on usage. (Report_Unused_Constituents): New routine. (Report_Unused_Hidden_States): Removed. (Report_Unused_States): New routine. * sem_prag.ads (Check_Missing_Part_Of): New routine. * sem_util.adb (Add_Contract_Item): Pragma Part_Of can now appear in the classification pragmas of a package instantiation or a variable. (Find_Placement_In_State_Space): New routine. (Is_Child): Removed. (Is_Child_Or_Sibling): Remove formal parameter Private_Child. Remove the private child checks. (Requires_State_Refinement): Moved from sem_ch3. * sem_util.ads Add new type State_Space_Kind along with comment on its usage and values. (Add_Contract_Item): Update the comment on usage. (Find_Body_Discriminal): Alphabetize spec. (Find_Placement_In_State_Space): New routine. (Is_Child_Or_Sibling): Remove formal parameter Private_Child and update the comment on usage. (Requires_State_Refinement): Moved from sem_ch3. * sinfo.ads: Update the documentation of N_Contract. * snames.ads-tmpl The predefined name for Part_Of is now used to denote a pragma. Add Pragma_Id for Part_Of. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207251 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-01-24 Robert Dewar <dewar@adacore.com>charlet2014-01-241-12/+12
| | | | | | | | | | | | | | | | | | | | | | | | * sinfo.ads, make.adb, prj-env.adb: Minor reformatting. 2014-01-24 Vincent Celier <celier@adacore.com> * prj.adb (Add_Aggregated_Project): Do not add a project in the list if it is already there. 2014-01-24 Yannick Moy <moy@adacore.com> * lib-xref-spark_specific.adb (Enclosing_Subprogram_Or_Package): Correct the search for a subrogram declaration to which a pragma is attached. 2014-01-24 Bob Duff <duff@adacore.com> * gnat_ugn.texi: Document --decimal-grouping and --based-grouping switches in gnatpp. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207042 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-01-24 Ed Schonberg <schonberg@adacore.com>charlet2014-01-241-12/+47
| | | | | | | | | | | | | | | | | | | | * sinfo.ads: Documentation update. 2014-01-24 Ed Schonberg <schonberg@adacore.com> * sem_ch3.adb (Constant_Redeclaration): New declaration is illegal if previous one has an initial expression that is an aggregate expanded into assignments. 2014-01-24 Ed Schonberg <schonberg@adacore.com> * sem_ch5.adb (Analyze_Loop_Parameter_Specification): Small code reorganization to remove spurious warning on a loop with an array element iterator that has a null range. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@207041 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-01-23 Robert Dewar <dewar@adacore.com>charlet2014-01-231-25/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * exp_util.adb, sinfo.adb, sinfo.ads, sem.adb, sem_res.adb, expander.adb, exp_ch11.adb, exp_ch11.ads, sem_ch11.adb, sem_ch11.ads, sprint.adb, sprint.ads: Remove unused node N_Subprogram_Info. 2014-01-23 Emmanuel Briot <briot@adacore.com> * prj-conf.adb (Get_Or_Create_Configuration_File): call On_Load_Config later. 2014-01-23 Hristian Kirtchev <kirtchev@adacore.com> * sem_ch3.adb (Analyze_Declarations): Do not generate the spec of the late primitive in ASIS mode. Add two comments to explain the special cases when the expansion is not performed. 2014-01-23 Robert Dewar <dewar@adacore.com> * sem_util.adb (Note_Possible_Modification): Fix error of misbehaving for implicit dereference cases in -gnatc mode. 2014-01-23 Emmanuel Briot <briot@adacore.com> * prj-pars.adb: Minor reformatting. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@206980 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-01-21 Hristian Kirtchev <kirtchev@adacore.com>charlet2014-01-211-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * aspects.adb Add entries for Async_Readers, Async_Writers, Effective_Reads and Effective_Writes in table Canonical_Aspect. * aspects.ads Add entries for Async_Readers, Async_Writers, Effective_Reads and Effective_Writes in tables Aspect_Id, Aspect_Names, Aspect_Delay and Implementation_Defined_Aspect. * atree.adb (Ekind_In): New version with 8 parameters. (Node34): New routine. (Set_Node34): New routine. * atree.ads (Ekind_In): New version with 8 parameters. (Node34): New routine. (Set_Node34): New routine. * einfo.adb Contract is now Node34. (Contract): Update the assertion and node usage. (Get_Pragma): Include pragmas Async_Readers, Async_Writers, Effective_Reads and Effective_Writes. (Set_Contract): Update the assertion and node usage. (Write_Field24_Name): Remove the output for a contract. (Write_Field34_Name): Add output for a contract. * einfo.ads Contract is now Node34. Update the comment on attribute usage and related node structures. (Get_Pragma): Update the comment on usage. * par-prag.adb (Prag): Pragmas Async_Readers, Async_Writers, Effective_Reads and Effective_Writes do not require special processing by the parser. * sem_ch3.adb (Analyze_Variable_Contract): New routine. (Analyze_Declarations): Analyze the contract of a variable at the end of the declarative region. (Analyze_Object_Declaration): Create a contract for a variable. * sem_ch6.adb (Analyze_Subprogram_Contract): Update the retrieval of classification pragmas. (Process_Formals): Detect an illegal use of a volatile object as a formal in a function. * sem_ch12.adb (Instantiate_Object): Detect an illegal use of a volatile object as an actual in generic instantiation. * sem_prag.adb Add entries for Async_Readers, Async_Writers, Effective_Reads and Effective_Writes in table Sig_Flags. (Analyze_External_State_In_Decl_Part): New routine. (Analyze_Global_Item): Detect an illegal use of a volatile object as a global item of a function. (Analyze_Pragma): Reimplement pragma Abstract_State. Add support for pragmas Async_Readers, Async_Writers, Effective_Reads and Effective_Writes. (Check_External_Properties): New routine. * sem_prag.ads (Analyze_External_State_In_Decl_Part): New routine. (Check_External_Properties): New routine. * sem_res.adb (Resolve_Actuals): Detect an illegal use of a volatile object as an actual in a call. (Resolve_Entity_Name): Add local variables Par, Prev and Usage_OK. Detect illegal contexts of volatile objects. * sem_util.adb (Add_Contract_Item): Add support for pragmas associated with the contract of a variable. (Async_Readers_Enabled): New routine. (Async_Writers_Enabled): New routine. (Effective_Reads_Enabled): New routine. (Effective_Writes_Enabled): New routine. (Has_Enabled_Property): New routine. (Is_Unchecked_Conversion_Instance): New routine. (Is_Volatile_Object): Add support for entities that may denote a volatile object. * sem_util.ads (Add_Contract_Item): Update the comment on usage. (Async_Readers_Enabled): New routine. (Async_Writers_Enabled): New routine. (Effective_Reads_Enabled): New routine. (Effective_Writes_Enabled): New routine. (Is_Unchecked_Conversion_Instance): New routine. * sinfo.ads Update the comment on the structure of N_Contract. * snames.ads-tmpl Add predefined names for Async_Readers, Async_Writers, Effective_Reads and Effective_Writes. Add pragma ids for Async_Readers, Async_Writers, Effective_Reads and Effective_Writes. 2014-01-21 Robert Dewar <dewar@adacore.com> * exp_ch4.adb (Eval_Op_Expon): Use CRT_Safe_Compile_Time_Known_Value * sem_eval.adb (Compile_Time_Known_Value): Remove special handling of CRT mode (CRT_Safe_Compile_Time_Known_Value): New function (Eval_Op_Expon): Add CRT_Safe in call to Test_Foldable (Test_Foldable): Add CRT_Safe parameter * sem_eval.ads (Compile_Time_Known_Value): Remove special handling of CRT mode. (CRT_Safe_Compile_Time_Known_Value): New function. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@206886 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-01-21 Thomas Quinot <quinot@adacore.com>charlet2014-01-211-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * exp_ch5.adb: Fix comment. * switch-c.adb: Minor comment update. * exp_ch3.adb: Minor reformatting. 2014-01-21 Arnaud Charlet <charlet@adacore.com> * back_end.adb (Scan_Compiler_Arguments): Do not store object filename in gnatprove mode. 2014-01-21 Thomas Quinot <quinot@adacore.com> * sinfo.ads (No_Ctrl_Actions): Clarify documentation (flag also suppresses usage of primitive _assign for tagged types). * exp_aggr.adb (Build_Array_Aggr_Code.Gen_Assign): Set No_Ctrl_Actions for a tagged type that does not require finalization, as we want to disable usage of _assign (which may cause undesirable discriminant checks on an uninitialized, invalid target). 2014-01-21 Ed Schonberg <schonberg@adacore.com> * sem_prag.adb: Reject invariant'class on completion. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@206878 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-01-21 Javier Miranda <miranda@adacore.com>charlet2014-01-211-15/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * exp_ch3.adb (Build_Init_Procedure): For derivations of interfaces, do not move the the initialization of the _parent field since such assignment is not generated. 2014-01-21 Ed Schonberg <schonberg@adacore.com> * sem_res.adb (Rewrite_Renamed_Operator): Do not replace entity with the operator it renames if we are within an expression of a pre/postcondition, because the expression will be reanalyzed at a later point, and the analysis of the renaming may affect the visibility of the operator when in an instance. 2014-01-21 Robert Dewar <dewar@adacore.com> * sinfo.ads, sinfo.adb: Change Do_Discriminant_Check to use new Flag1. Add this flag to type conversion nodes and assignment nodes. * treepr.adb: Deal properly with Flag 1,2,3. * treeprs.adt: Minor comment update. 2014-01-21 Robert Dewar <dewar@adacore.com> * sem_eval.adb (Compile_Time_Known_Value): Add Ignore_CRT parameter. * sem_eval.ads (Compile_Time_Known_Value): Add Ignore_CRT parameter, completely rewrite spec. 2014-01-21 Ed Schonberg <schonberg@adacore.com> * sem_ch10.adb (Install_Withed_Unit): If the unit is a subprogram instance that is inlined, it may have been rewritten as a wrapper package. In that case the unit that must be made visible is the related instance of the package. 2014-01-21 Arnaud Charlet <charlet@adacore.com> * exp_ch9.adb (Expand_N_Selective_Accept.Add_Accept): Refine previous change in codepeer mode. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@206874 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-01-20 Robert Dewar <dewar@adacore.com>charlet2014-01-201-5/+5
| | | | | | | | | | | * sem_aggr.adb, exp_prag.adb, sem_aux.adb, sinfo.ads, sem_ch10.adb, checks.adb, sem_prag.adb, sem_ch12.adb, freeze.adb, g-arrspl.adb, expander.adb, gnat1drv.adb, exp_ch4.adb, sem_ch6.adb, sem_ch8.adb, exp_dist.adb: Minor reformatting. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@206813 138bc75d-0d04-0410-961f-82ee72b054a4
* 2014-01-20 Yannick Moy <moy@adacore.com>charlet2014-01-201-22/+21
| | | | | | | | | | | | | | | | | * exp_spark.adb (Expand_SPARK_Call): Remove procedure. * opt.adb, opt.ads (Full_Expander_Active): Remove function. * checks.adb, exp_ch6.adb, exp_ch9.adb, exp_disp.adb, sem_aggr.adb, * sem_ch10.adb, sem_ch5.adb, sem_ch6.adb, sem_ch8.adb, sem_ch9.adb, * sem_disp.adb, sem_res.adb Replace Full_Expander_Active by Expander_Active. 2014-01-20 Yannick Moy <moy@adacore.com> * sinfo.ads Update documentation of GNATprove mode. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@206806 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-10-17 Yannick Moy <moy@adacore.com>charlet2013-10-171-0/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * sem_ch8.adb (Find_Direct_Name): Keep track of assignments for renamings in SPARK mode. 2013-10-17 Yannick Moy <moy@adacore.com> * exp_spark.adb (Expand_SPARK): Remove special case for NOT IN operation. * sinfo.ads: Add special comment section to describe SPARK mode effect on tree. * exp_spark.ads: Remove comments, moved to sinfo.ads. 2013-10-17 Yannick Moy <moy@adacore.com> * exp_ch3.adb (Expand_Freeze_Class_Wide_Type, Expand_Freeze_Class_Wide_Type, Expand_Freeze_Class_Wide_Type): Remove useless special cases. * exp_ch4.adb (Expand_Allocator_Expression, Expand_N_Allocator, Expand_N_Op_Expon): Remove useless special cases. * exp_ch6.adb (Is_Build_In_Place_Function_Call): Disable build-in-place in SPARK mode by testing Full_Expander_Active instead of Expander_Active. (Make_Build_In_Place_Call_In_Allocator): Remove useless special case. * exp_util.adb (Build_Allocate_Deallocate_Proc): Remove useless special case. * sem_eval.adb (Compile_Time_Known_Value): Remove special handling of deferred constant. 2013-10-17 Yannick Moy <moy@adacore.com> * gnat_ugn.texi: Document -gnateT and target file format. 2013-10-17 Vincent Celier <celier@adacore.com> * prep.adb (Check_Command_Line_Symbol_Definition): Is_A_String is always False, even when the value starts and ends with double quotes. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203747 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-10-14 Hristian Kirtchev <kirtchev@adacore.com>charlet2013-10-141-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * aspects.adb: Add an entry in table Canonical_Aspect for Initial_Condition. * aspects.ads: Add entries in tables Aspect_Id, Aspect_Argument, Aspect_Names and Aspect_Delay for Initial_Condition. * einfo.adb (Get_Pragma): Include pragma Initial_Condition to categorization pragmas. * einfo.ads (Get_Pragma): Update comment on usage. * exp_ch7.adb (Expand_N_Package_Body): Add a runtime check to verify the assertion introduced by pragma Initial_Condition. (Expand_N_Package_Declaration): Add a runtime check to verify the assertion introduced by pragma Initial_Condition. (Expand_Pragma_Initial_Condition): New routine. * par-prag: Include pragma Initial_Condition to the list of pragmas that do not require special processing by the parser. * sem_ch3.adb (Analyze_Declarations): Analyze pragma Initial_Condition at the end of the visible declarations. * sem_ch13.adb (Analyze_Aspect_Specifications): Add processing for aspect Initial_Condition. (Check_Aspect_At_Freeze_Point): Aspect Initial_Condition does not need inspection at freezing. * sem_prag.adb (Analyze_Initial_Condition_In_Decl_Part): New routine. (Analyze_Pragma): Update all calls to Check_Declaration_Order. Add processing for pragma Initial_Condition. Initial_Condition is now a valid assertion kind. Add an entry in table Sig_Flags for Initial_Condition. (Check_Declaration_Order): Reimplemented to handle arbitrary pragmas. (Is_Valid_Assertion_Kind): Add an entry for Initial_Condition. * sem_pag.ads (Analyze_Initial_Condition_In_Decl_Part): New routine. * sem_util.adb (Add_Contract_Item): Pragma Initial_Condition can now be associated with a package spec. * sem_util.ads (Add_Contract_Item): Update comment on usage. * sinfo.ads: Update the documentation of node N_Contract * snames.ads-tmpl: Add new predefined name Initial_Condition. Add new pragma id for Initial_Condition. 2013-10-14 Thomas Quinot <quinot@adacore.com> * exp_pakd.adb: Minor reformatting. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203551 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-10-14 Robert Dewar <dewar@adacore.com>charlet2013-10-141-1/+1
| | | | | | | | | | | | | | | | | | | | | * exp_attr.adb (Expand_N_Attribute_Reference): Add error entry for Library_Level attribute (which should not survive to expansion) * gnat_rm.texi: Document attribute Library_Level * sem_attr.adb (Analyze_Attribute, case Library_Level): Implement this new attribute (Set_Boolean_Result): Replaces Set_Result (Check_Standard_Prefix): Document that Check_E0 is called (Check_System_Prefix): New procedure * snames.ads-tmpl: Add entry for Library_Level attribute 2013-10-14 Robert Dewar <dewar@adacore.com> * exp_ch6.adb, sinfo.ads: Minor reformatting. * checks.adb (Overlap_Check): Use identifier casing in messages. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203528 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-10-14 Robert Dewar <dewar@adacore.com>charlet2013-10-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * einfo.ads, einfo.adb (Default_Aspect_Component_Value): Is on base type only. * exp_aggr.adb (Expand_Array_Aggregate): Handle proper initialization of <> component. * exp_ch3.adb, exp_tss.adb: Minor reformatting * sem_ch13.adb (Default_Aspect_Component_Value, Default_Aspect_Value): Is on base type only. * sinfo.ads: Minor comment revision. 2013-10-14 Robert Dewar <dewar@adacore.com> * g-decstr.adb (Decode_Wide_Wide_Character): Fix failure to detect invalid sequences where longer than necessary sequences are used for encoding. (Validate_Wide_Character): Call Decode_Wide_Character to get the above validations. (Validate_Wide_Wide_Character): Same fix * g-decstr.ads: Add documentation making it clear that the UTF-8 implementation here recognizes all valid UTF-8 sequences, rather than the well-formed subset corresponding to characters defined in Unicode. (Next_Wide_Character): Remove comment about this being more efficient than Decode_Wide_Character (because this no longer the case). (Prev_Wide_Character): Add note that valid encoding is assumed. 2013-10-14 Robert Dewar <dewar@adacore.com> * a-wichha.adb (Character_Set_Version): New function. * a-wichha.ads: Remove comments for pragma Pure (final RM has this). (Character_Set_Version): New function. * gnat_rm.texi: Update doc. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203527 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-10-14 Hristian Kirtchev <kirtchev@adacore.com>charlet2013-10-141-9/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * aspects.adb: Add an entry in table Canonical_Aspect for Initializes. * aspects.ads: Add entries in tables Aspect_Id, Aspect_Argument, Aspect_Names and Aspect_Delay for Initializes. * atree.ads, atree.adb (Ekind_In): New seven argument versions of the routines. * einfo.adb: Remove Refined_State_Pragma from the list of node usage. Finalizer is now at position 28. (Contract): Package and package bodies now have a contract. (Finalizer): Update the assertion and node usage. (Get_Pragma): Update the Is_CDG flag to include Abstract_State, Initializes and Refined_State. (Refined_State_Pragma): Removed. (Set_Contract): Package and package bodies now have a contract. (Set_Finalizer): Update the assertion and node usage. (Set_Refined_State_Pragma): Removed. (Write_Field8_Name): Remove the output for Refined_State_Pragma. (Write_Field24_Name): Remove the output for Finalizer. Package and package bodies now have a contract. (Write_Field28_Name): Add output for Finalizer. * einfo.ads: Update the documentation and usage in entities of attribute Contract. Update the node position and usage in entities of attribute Finalizer. Remove the documentation and usage in entities for attribute Refined_State_Pragma. (Refined_State_Pragma): Removed along with pragma Inline. (Set_Refined_State_Pragma): Removed along with pragma Inline. * par-prag.adb: Add Initializes to the pragmas that do not require special processing by the parser. * sem_ch3.adb (Analyze_Declarations): Add local variable Prag. Update the retrieval of pragma Refined_State. Analyze aspect/pragma Initializes at the end of the visible declarations of the related package. * sem_ch6.adb (Analyze_Subprogram_Body_Contract): Add local variables Ref_Depends and Ref_Global. Analyze pragmas Refined_Global and Refined_Depends in that order. (Analyze_Subprogram_Contract): Add local variables Depends and Global. Analyze pragmas Global and Depends in that order. * sem_ch7.adb (Analyze_Package_Body_Helper): Package bodies now have a contract. Move the analysis of the aspect specifications after the defining entity has been decorated. (Analyze_Package_Declaration): Packages now have a contract. Move the analysis of the aspect specifications after the defining entity has been decorated. * sem_ch12.adb (Analyze_Generic_Package_Declaration): Packages now have contracts. * sem_ch13.adb (Analyze_Pragma): Code cleanup for aspect Abstract_State. Add processing for aspect Initializes. (Check_Aspect_At_Freeze_Point): Add an entry for Initializes. * sem_prag.adb: Use Get_Pragma_Arg to extract the expression of a pragma argument. Add an entry in table Sig_Flags for Initializes. (Analyze_Initializes_In_Decl_Part): New routine. (Analyze_Pragma): Check the declaration order of pragmas Abstract_State and Initializes. Abstract_State is now part of the package contract. Analyze pragma Initializes. Check for duplicate Refined_State pragma. Refined_State is now part of the package contract. (Check_Declaration_Order): New routine. (Check_Test_Case): Alphabetized. * sem_prag.ads (Analyze_Initializes_In_Decl_Part): New routine. * sem_util.adb (Add_Contract_Item): Rename formal Subp_Id to Id. This routine can now support contracts on packages and package bodies. * sem_util.ads (Add_Contract_Item): Rename formal Subp_Id to Id. Update comment on usage. * sinfo.ads: Update the usage of N_Contract nodes. * snames.ads-tmpl: Add predefined name Initializes. Add new pragma id for Initializes. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203522 138bc75d-0d04-0410-961f-82ee72b054a4
* Minor reformatting.charlet2013-10-101-5/+6
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203375 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-10-10 Thomas Quinot <quinot@adacore.com>charlet2013-10-101-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * exp_ch4.adb (Process_Transient_Object): For any context other than a simple return statement, insert the finalization action after the context, not as an action on the context (which will get evaluated before it). 2013-10-10 Hristian Kirtchev <kirtchev@adacore.com> * einfo.adb (Write_Field19_Name): Correct the string name of attribute Default_Aspect_Value. 2013-10-10 Ed Schonberg <schonberg@adacore.com> * sem_type.adb (Interface_Present_In_Ancestor): The progenitor in a type declaration may be an interface subtype. 2013-10-10 Robert Dewar <dewar@adacore.com> * sinfo.ads (Do_Range_Check): Add special note on handling of range checks for Succ and Pred. 2013-10-10 Robert Dewar <dewar@adacore.com> * erroutc.adb (Output_Msg_Text): Remove VMS special handling. 2013-10-10 Robert Dewar <dewar@adacore.com> * a-chahan.ads, a-chahan.adb (Is_Line_Terminator): New function (Is_Mark): New function. (Is_Other_Format): New function. (Is_Punctuation_Connector): New function. (Is_Space): New function. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203370 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-10-10 Robert Dewar <dewar@adacore.com>charlet2013-10-101-0/+2
| | | | | | | | | | | | | | | | | * freeze.adb: Minor reformatting. * sem_ch13.adb (Freeze_Entity_Checks): New procedure (Analyze_Freeze_Entity): Call Freeze_Entity_Checks (Analyze_Freeze_Generic_Entity): Call Freeze_Entity_Checks. * sinfo.ads: Add syntax for sprint for Freeze_Generic_Entity. * sprint.ads: Add syntax for freeze generic entity node. 2013-10-10 Robert Dewar <dewar@adacore.com> * einfo.adb, einfo.ads: Minor comment updates. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203368 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-10-10 Robert Dewar <dewar@adacore.com>charlet2013-10-101-2/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lib-writ.adb (Write_Unit_Information): Fatal error if linker options are detected in a predefined generic unit. 2013-10-10 Thomas Quinot <quinot@adacore.com> * s-oscons-tmplt.c (CLOCK_REALTIME): Always define, possibly using a dummy placeholder value. (NEED_PTHREAD_CONDATTR_SETCLOCK): Remove, not needed anymore. * thread.c: Adjust #if test accordingly. 2013-10-10 Hristian Kirtchev <kirtchev@adacore.com> * exp_ch6.adb (Consequence_Error): Generate an implicit if statement. (Expand_Contract_Cases): Generate an implicit if statement. (Process_Contract_Cases): Do not expand Contract_Cases when no code is being generated. 2013-10-10 Robert Dewar <dewar@adacore.com> * sem_attr.adb (Address_Checks): New procedure. 2013-10-10 Ed Schonberg <schonberg@adacore.com> * sinfo.ads, sinfo.adb: New Node Freeze_Generic_Entity, to trigger semantic actions at the proper point for entities that previously had no explicit freeze point. * freeze.adb (Freeze_Generic_Entities): generate new nodes to indicate the point at which semantic checks can be performed on entities declared in generic packages. * sem_ch13.ads, sem_ch13.adb: New procedure Analyze_Freeze_Generic_Entity. * exp_util.adb (Insert_Actions): Treat new node like Freeze_Entity. * sem.adb (Analyze): Call Analyze_Freeze_Generic_Entity. * sprint.adb (Sprint_Node): display Analyze_Freeze_Generic_Entity. * gcc-interface/trans.c: Ignore Analyze_Freeze_Generic_Entity. * gcc-interface/Make-lang.in: Update dependencies. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203367 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-10-10 Hristian Kirtchev <kirtchev@adacore.com>charlet2013-10-101-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * aspects.adb: Add entries in table Canonical_Aspects for aspects Refined_Depends and Refined_Global. * aspects.ads: Add entries in tables Aspect_Id, Aspect_Argument, Aspect_Names, Aspect_Declay, Aspect_On_Body_Or_Stub_OK for aspects Refined_Depends and Refined_Global. * einfo.adb (Contract): Subprogram bodies are now valid owners of contracts. (Set_Contract): Subprogram bodies are now valid owners of contracts. (Write_Field24_Name): Output the contract attribute for subprogram bodies. * exp_ch6.adb (Expand_Subprogram_Contract): New routine. * exp_ch6.ads (Expand_Subprogram_Contract): New routine. * par-prag.adb: Pragmas Refined_Depends and Refined_Global do not require any special processing by the parser. * sem_ch3.adb (Adjust_D): Renamed to Adjust_Decl. (Analyze_Declarations): Code reformatting. Analyze the contract of a subprogram body at the end of the declarative region. * sem_ch6.adb (Analyze_Generic_Subprogram_Body): Subprogram bodies can now have contracts. Use Expand_Subprogram_Contract to handle the various contract assertions. (Analyze_Subprogram_Body_Contract): New null routine. (Analyze_Subprogram_Body_Helper): Subprogram bodies can now have contracts. Use Expand_Subprogram_Contract to handle the various contract assertions. (Analyze_Subprogram_Contract): Add local variable Nam. Update the call to Analyze_PPC_In_Decl_Part. Capture the pragma name in Nam. (Process_PPCs): Removed. * sem_ch6.ads (Analyze_Subprogram_Body_Contract): New routine. (Analyze_Subprogram_Contract): Update the comment on usage. * sem_ch13.adb (Analyze_Aspect_Specifications): Add null implementations for aspects Refined_Depends and Refined_Global. (Check_Aspect_At_Freeze_Point): Aspects Refined_Depends and Refined_Global do not need to be checked at the freeze point. * sem_prag.adb: Add entries in table Sig_Flags for pragmas Refined_Depends and Refined_Global. (Analyze_Contract_Cases_In_Decl_Part): Add local variable Restore. Use Restore to pop the scope. (Analyze_Depends_In_Decl_Part): Add local variable Restore. Use Restore to pop the scope. (Analyze_Global_In_Decl_List): Add local variable Restore. Use Restore to pop the scope. (Analyze_PPC_In_Decl_Part): Renamed to Analyze_Pre_Post_Condition_In_Decl_Part. (Analyze_Pragma): Add null implementations for pragmas Refined_Depends and Refined_Global. Refined_Pre and Refined_Post are now handled by routine Analyze_Refined_Pre_Post_Condition exclusively. (Analyze_Refined_Depends_In_Decl_Part): New null routine. (Analyze_Refined_Global_In_Decl_Part): New null routine. (Analyze_Refined_Pre_Post): Renamed to Analyze_Refined_Pre_Post_Condition. (Analyze_Refined_Pre_Post_Condition): Analyze the boolean expression. (Check_Precondition_Postcondition): Update the call to Analyze_PPC_In_Decl_Part. * sem_prag.ads: Add entries in table Pragma_On_Body_Or_Stub_OK for pragmas Refined_Depends and Refined_Global. (Analyze_PPC_In_Decl_Part): Renamed to Analyze_Pre_Post_Condition_In_Decl_Part. Update the comment on usage. (Analyze_Refined_Depends_In_Decl_Part): New routine. (Analyze_Refined_Global_In_Decl_Part): New routine. (Analyze_Test_Case_In_Decl_Part): Update the comment on usage. * sem_util.adb (Add_Contract_Item): Rename formal Item to Prag and update all occurrences. Subprogram body contracts can now contain pragmas Refined_Depends and Refined_Global. * sem_util.ads (Add_Contract_Item): Rename formal Item to Prag. Update the comment on usage. * sinfo.ads: Update the comment on structure and usage of N_Contract. * snames.ads-tmpl: Add new predefined names for Refined_Depends and Refined_Global. Add entries in table Pragma_Id for Refined_Depends and Refined_Global. 2013-10-10 Robert Dewar <dewar@adacore.com> * types.ads: Minor reformatting. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203365 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-10-10 Robert Dewar <dewar@adacore.com>charlet2013-10-101-3/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lib-xref-spark_specific.adb, par-ch13.adb, sem_prag.adb, sem_prag.ads, sem_ch12.adb, sem_attr.adb, sem_ch6.adb, sem_ch13.adb, a-sequio.adb, s-atocou-builtin.adb: Minor reformatting. 2013-10-10 Thomas Quinot <quinot@adacore.com> * s-oscons-tmplt.c (NEED_PTHREAD_CONDATTR_SETCLOCK): This constant needs to be output to s-oscons.h, as it is tested by init.c. 2013-10-10 Robert Dewar <dewar@adacore.com> * exp_ch3.adb (Expand_N_Variant_Part): Don't expand choices, too early * exp_ch5.adb (Expand_N_Case_Statement): Use new Has_SP_Choice flag to avoid expanding choices when not necessary. * exp_util.adb: Minor reformatting * freeze.adb (Freeze_Record_Type): Redo expansion of variants * sem_aggr.adb: Minor reformatting * sem_case.ads, sem_case.adb: Major rewrite, separating Analysis and Checking of choices. * sem_ch3.adb (Analyze_Variant_Part): Rewrite to call new Analyze_Choices. * sem_ch4.adb (Analyze_Case_Expression): Call Analyze_Choices and Check_Choices * sem_ch5.adb (Analyze_Case_Statement): Call Analyze_Choices and Check_Choices * sem_util.adb: Minor reformatting * sinfo.ads, sinfo.adb (Has_SP_Choice): New flag. 2013-10-10 Vincent Celier <celier@adacore.com> * mlib-prj.adb (Build_Library): Do not issue link dynamic libraries with an Rpath, if switch -R was used. 2013-10-10 Tristan Gingold <gingold@adacore.com> * s-stalib.ads (Image_Index_Table_8, Image_Index_Table_16, Image_Index_Table_32): Remove as not used. * s-imgint.adb (Image_Integer): Call Set_Image_Integer and remove duplicated code. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203358 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-10-10 Ed Schonberg <schonberg@adacore.com>charlet2013-10-101-4/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * par-ch13.adb (Aspect_Specifications_Present)): In earlier than Ada2012 mode, assume that a legal aspect name following "with" keyword is an older gnat switch and not a misplaced with_clause. 2013-10-10 Hristian Kirtchev <kirtchev@adacore.com> * aspects.adb: Add an entry for Aspect_Refined_Pre in table Canonical_Aspect. (Aspects_On_Body_OK): Renamed to Aspects_On_Body_Or_Stub_OK. (Aspects_On_Body_Or_Stub_OK): Update the query in table Aspect_On_Body_OK. * aspects.ads: Add an entry for Aspect_Refined_Pre in tables Aspect_Id, Aspect_Argument, Aspect_Names, Aspect_Delay, Aspect_On_Body_Or_Stub_OK. Table Aspect_On_Body_OK is now known as Aspect_On_Body_Or_Stub_OK. Add a section of aspect specifications that apply to body stubs. (Aspects_On_Body_OK): Renamed to Aspects_On_Body_Or_Stub_OK. (Aspects_On_Body_Or_Stub_OK): Update the comment on usage. * par-prag.adb: Add pragma Refined_Pre to the list of pragmas that do not require special processing by the parser. * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Delay the analysis of aspect specifications that apply to a body stub until the proper body is analyzed. * sem_ch10.adb: Add with and use clause for Sem_Ch13. (Analyze_Package_Body_Stub): Set the corresponding spec of the stub. (Analyze_Proper_Body): Relocate all pragmas that apply to a subprogram body stub to the declarations of the proper body. Analyze the aspect specifications of the stub when the proper body is not present. (Analyze_Protected_Body_Stub): Set the corresponding spec of the stub. (Analyze_Task_Body_Stub): Set the corresponding spec of the stub. (Move_Stub_Pragmas_To_Body): New routine. * sem_ch13.adb (Analyze_Aspect_Specifications): Add processing for aspect Refined_Pre. (Check_Aspect_At_Freeze_Point): Aspect Refined_Pre does not need delayed processing at the freeze point. * sem_prag.adb: Remove with and use clause for Snames. Add an entry for Pragma_Refined_Pre in table Sig_Flags. (Analyze_Pragma): Add processing for pragma Refined_Pre. * sem_prag.ads: Add with and use clause for Snames. Add table Pragma_On_Stub_OK. * sinfo.adb (Corresponding_Spec_Of_Stub): New routine. (Set_Corresponding_Spec_Of_Stub): New routine. * sinfo.ads: Add new attribute Corresponding_Spec_Of_Stub along with comment on usage and occurrences in nodes. (Corresponding_Spec_Of_Stub): New routine along with pragma Inline. (Set_Corresponding_Spec_Of_Stub): New routine along with pragma Inline. * snames.ads-tmpl: Add new predefined name for Refined_Pre. Add new Pragma_Id for Refined_Pre. 2013-10-10 Ed Schonberg <schonberg@adacore.com> * sem_ch12.adb (Analyze_Package_Instantiation, Analyze_Subprogram_Instantiation): Improve error message when name in instantiation does not designate a generic unit of the right kind. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203355 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-10-10 Robert Dewar <dewar@adacore.com>charlet2013-10-101-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * exp_ch3.adb (Expand_N_Variant_Part): Expand statically predicated subtype which appears in Discrete_Choices list. * exp_ch5.adb (Expand_N_Case_Statement): Expand statically predicated subtype which appears in Discrete_Choices list of case statement alternative. * exp_util.ads, exp_util.adb (Expand_Static_Predicates_In_Choices): New procedure. * sem_case.adb: Minor reformatting (Analyze_Choices): Don't expand out Discrete_Choices that are names of subtypes with static predicates. This is now done in the analyzer so that the -gnatct tree is properly formed for ASIS. * sem_case.ads (Generic_Choices_Processing): Does not apply to aggregates any more, so change doc accordingly, and remove unneeded Get_Choices argument. * sem_ch3.adb (Analyze_Variant_Part): Remove no longer used Get_Choices argument in instantiation of Generic_Choices_Processing. * sem_ch4.adb (Analyze_Case_Expression): Remove no longer used Get_Choices argument in instantiation of Generic_Choices_Processing. * sem_ch5.adb (Analyze_Case_Statement): Remove no longer used Get_Choices argument in instantiation of Generic_Choices_Processing. * sinfo.ads: For N_Variant_Part, and N_Case_Statement_Alternative, document that choices that are names of statically predicated subtypes are expanded in the code generation tree passed to the back end, but not in the ASIS tree generated for -gnatct. 2013-10-10 Ed Schonberg <schonberg@adacore.com> * sem_ch7.adb: Revert previous change. 2013-10-10 Gary Dismukes <dismukes@adacore.com> * sem_ch13.adb (Analyze_Attribute_Definition_Clause): In the case where the Storage_Pool aspect is specified by an aspect clause and a renaming is used to capture the evaluation of the pool name, insert the renaming in front of the aspect's associated entity declaration rather than in front of the corresponding attribute definition (which hasn't been appended to the declaration list yet). 2013-10-10 Ed Schonberg <schonberg@adacore.com> * sem_ch6.adb (Is_Interface_Conformant): The controlling type of the interface operation is obtained from the ultimate alias of the interface primitive parameter, because that may be in fact an implicit inherited operation whose signature involves the type extension and not the desired interface. 2013-10-10 Ed Schonberg <schonberg@adacore.com> * par-ch13.adb (Aspect_Specifications_Present): In Ada 2012, recognize an aspect specification with a misspelled name if it is followed by a a comma or semicolon. 2013-10-10 Vadim Godunko <godunko@adacore.com> * s-atocou.adb, s-atocou.ads, s-atocou-x86.adb, s-atocou-builtin.adb: Fix copyright notice. 2013-10-10 Yannick Moy <moy@adacore.com> * lib-xref-spark_specific.adb (Enclosing_Subprogram_Or_Package): Get enclosing subprogram for precondition/postcondition/contract cases. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203350 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-10-10 Robert Dewar <dewar@adacore.com>charlet2013-10-101-3/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * gnat_rm.texi: Minor fix. 2013-10-10 Robert Dewar <dewar@adacore.com> * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case Address): Remove the Comes_From_Source test for the overlap warning. 2013-10-10 Robert Dewar <dewar@adacore.com> * sem_util.adb: Minor code reorganization (use Nkind_In). * sem_warn.adb: Minor code reorganization (optimization in Check_Unset_Reference). * exp_ch9.adb, exp_ch4.adb, sinfo.ads: Minor reformatting. 2013-10-10 Ed Schonberg <schonberg@adacore.com> * sem_ch7.adb (Install_Parent_Private_Declarations): When instantiating a child unit, do not install private declaration of a non-generic ancestor of the generic that is also an ancestor of the current unit: its private part will be installed when private part of ancestor itself is analyzed. 2013-10-10 Thomas Quinot <quinot@adacore.com> * freeze.adb (Check_Component_Storage_Order): Retrieve component aliased status from type entities directly instead of going back to original component definition. * sem_ch7.adb: Minor reformatting. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203349 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-09-10 Robert Dewar <dewar@adacore.com>charlet2013-09-101-0/+53
| | | | | | | | | | * switch-c.adb: Minor reformatting. * atree.ads (Original_Nodes): Add documentation on ASIS usage. * sinfo.ads: Add section on ASIS mode (documentation only). git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@202464 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-09-10 Robert Dewar <dewar@adacore.com>charlet2013-09-101-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * switch-c.adb: Diagnose -gnatc given after -gnatRm. * gnat_ugn.texi: Add documentation for -gnatRm. * usage.adb: Minor reorganization (put style entries in proper order) Document -gnatRm switch. * sinfo.ads: Minor comment fix. 2013-09-10 Sergey Rybin <rybin@adacore.com frybin> * tree_io.ads: Update ASIS_Version_Number. 2013-09-10 Ed Schonberg <schonberg@adacore.com> * sem_ch3.adb (Access_Subprogram_Declaration): Check whether the designated type can appear in a parameterless call. * sem_ch4.adb (Analyze_Call): Do not insert an explicit dereference in the case of an indirect call through an access function that returns an array type. (Analyze_One_Call): Handle properly legal parameterless calls whose result is indexed, in constructs of the for F.all (I) * sem_ch6.ads (May_Need_Actuals): Make public, for use on access to subprogram types. * sem_res.adb (Resolve_Call): If the call is indirect, there is no entity to set on the name in the call. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@202461 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-09-10 Hristian Kirtchev <kirtchev@adacore.com>charlet2013-09-101-14/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * aspects.adb: Add entries in the Has_Aspect_Specifications_Flag table for package body and body stubs. (Move_Or_Merge_Aspects): New routine. (Remove_Aspects): New routine. * aspects.ads (Move_Aspects): Update comment on usage. (Move_Or_Merge_Aspects): New routine. (Remove_Aspects): New routine. * par-ch3.adb: Update the grammar of private_type_declaration, private_extension_declaration, object_renaming_declaration, and exception_renaming_declaration. (P_Subprogram): Parse the aspect specifications that apply to a body stub. * par-ch6.adb: Update the grammar of subprogram_body_stub and generic_instantiation. * par-ch7.adb: Update the grammar of package_declaration, package_specification, package_body, package_renaming_declaration, package_body_stub. (P_Package): Parse the aspect specifications that apply to a body, a body stub and package renaming. * par-ch9.adb: Update the grammar of entry_declaration, protected_body, protected_body_stub, task_body, and task_body_stub. (P_Protected): Add local variable Aspect_Sloc. Add local constant Dummy_Node. Parse the aspect specifications that apply to a protected body and a protected body stub. (P_Task): Add local variable Aspect_Sloc. Add local constant Dummy_Node. Parse the aspect specifications that apply to a task body and a task body stub. * par-ch12.adb: Update the grammar of generic_renaming_declaration. (P_Generic): Parse the aspect specifications that apply to a generic renaming. * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Do not emit an error when analyzing aspects that apply to a body stub. Such aspects are relocated to the proper body. * sem_ch7.adb (Analyze_Package_Body_Helper): Analyze the aspect specifications that apply to a body. * sem_ch9.adb (Analyze_Protected_Body): Warn about user-defined aspects not being supported on protected bodies. Remove the aspect specifications. (Analyze_Single_Protected_Declaration): Analyze the aspects that apply to a single protected declaration. (Analyze_Task_Body): Warn about user-defined aspects not being supported on task bodies. Remove the aspect specifications. * sem_ch10.adb: Add with and use clause for Aspects. (Analyze_Package_Body_Stub): Propagate the aspect specifications from the stub to the proper body. * sem_ch13.adb (Analyze_Aspect_Specifications): Insert the corresponding pragma of an aspect that applies to a body in the declarations of the body. * sinfo.ads: Update the gramma of expression_function, private_type_declaration, private_extension_declaration, object_renaming_declaration, exception_renaming_declaration, package_renaming_declaration, subprogram_renaming_declaration, generic_renaming_declaration, entry_declaration, subprogram_body_stub, package_body_stub, task_body_stub, generic_subprogram_declaration. 2013-09-10 Hristian Kirtchev <kirtchev@adacore.com> * sem_prag.adb (Analyze_Pragma): Add processing for aspect/pragma SPARK_Mode when it applies to a [library-level] subprogram or package [body]. 2013-09-10 Robert Dewar <dewar@adacore.com> * gnat_ugn.texi: Document that -gnatc and -gnatR cannot be given together. * switch-c.adb (Scan_Front_End_Switches): Give error if both -gnatR and -gnatc given. 2013-09-10 Robert Dewar <dewar@adacore.com> * g-table.ads, g-table.adb (For_Each): New generic procedure (Sort_Table): New generic procedure. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@202460 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-09-10 Thomas Quinot <quinot@adacore.com>charlet2013-09-101-1/+1
| | | | | | | | | | | | | | | | | | | * adaint.c (__gnat_is_executable_file_attr): Should be true for an executable regular file only only (not for a directory that has the executable permission). 2013-09-10 Ed Schonberg <schonberg@adacore.com> * sem_res.adb: Further work on operator calls in ASIS. 2013-09-10 Yannick Moy <moy@adacore.com> * sinfo.ads, sem_prag.ads, sem_ch13.adb: Minor correction and comment update. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@202459 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-09-10 Robert Dewar <dewar@adacore.com>charlet2013-09-101-0/+19
| | | | | | | | | | | | | | | | * exp_prag.adb (Expand_Pragma_Check): Ignore pragma if Is_Ignored set. * sem_ch13.adb (Make_Aitem_Pragma): Set Is_Checked if needed. * sem_prag.adb (Check_Kind): Moved from spec (Analyze_Pragma): Make sure Is_Ignored/Is_Checked are set right (Analyze_Pragma, case Check): Ditto (Check_Applicable_Policy): Handle Statement_Assertion case Throughout, set and check the Is_Checked flag as appropriate. * sem_prag.ads (Check_Kind): Moved to body. * sinfo.ads, sinfo.adb (Is_Checked): New flag. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@202457 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-09-10 Robert Dewar <dewar@adacore.com>charlet2013-09-101-5/+4
| | | | | | | | | * sem_ch3.adb, sinfo.ads, exp_ch9.adb, sem_prag.adb, sem_ch12.adb, exp_ch4.adb, sprint.adb: Minor reformatting. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@202455 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-09-10 Yannick Moy <moy@adacore.com>charlet2013-09-101-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * sinfo.ads: Document splitting of pre/post in N_Contract description. 2013-09-10 Ed Schonberg <schonberg@adacore.com> * exp_ch4.adb (Expand_N_Op_Multiply): If the operation is of the form X * 2 ** N and it has been marked Is_Power_Of_2_For_Shift, add a mod operation if the result type is a binary modular type. 2013-09-10 Hristian Kirtchev <kirtchev@adacore.com> * sem_prag.adb (Check_Mode_Restriction_In_Enclosing_Context): Add local variable Context. Remove local variable Subp_Id. Start the context traversal from the current subprogram rather than the current scope. Update the scope traversal and error reporting. 2013-09-10 Ed Schonberg <schonberg@adacore.com> * exp_ch9.adb (Expand_N_Timed_Entry_Call): New procedure Rewrite_Triggering_Statements, to encapsulate the statements that follow the trigger of the entry call. This procedure is needed when the trigger is a dispatching call, because the expansion requires several copies of those statements. The procedure is more efficient, and preserves non-local references when the construct is within an instance. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@202454 138bc75d-0d04-0410-961f-82ee72b054a4
* 2013-07-08 Robert Dewar <dewar@adacore.com>charlet2013-07-081-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * sem.ads: Minor comment updates. * s-restri.ads, exp_ch6.adb, lib-load.ads, exp_ch3.adb, sem_ch10.adb: Minor reformatting. 2013-07-08 Robert Dewar <dewar@adacore.com> * exp_attr.adb (Expand_N_Attribute_Reference): Add dummy entry for Restriction_Set. * gnat_rm.texi: Add missing menu entry for Attribute Ref Add documentation for attribute Restriction_Set. * lib-writ.adb (Write_With_Lines): Generate special W lines for Restriction_Set. * lib-writ.ads: Document special use of W lines for Restriction_Set. * lib.ads (Restriction_Set_Dependences): New table. * par-ch4.adb (Is_Parameterless_Attribute): Add Loop_Entry to list (Scan_Name_Extension_Apostrophe): Remove kludge test for Loop_Entry (Scan_Name_Extension_Apostrophe): Handle No_Dependence for Restricton_Set. * restrict.adb (Check_SPARK_Restriction): Put in Alfa order (OK_No_Dependence_Unit_Name): New function. * restrict.ads (OK_No_Dependence_Unit_Name): New function. * rtsfind.adb: Minor reformatting Minor code reorganization. * sem_attr.adb (Analyze_Attribute): Add processing for Restriction_Set. * sem_prag.adb (Process_Restrictions_Or_Restriction_Warnings): Remove Check_Unit_Name and use new function OK_No_Dependence_Unit_Name instead. * sinfo.ads: Minor comment updates. * snames.ads-tmpl: Add entry for Restriction_Set attribute. 2013-07-08 Hristian Kirtchev <kirtchev@adacore.com> * exp_ch4.adb (Apply_Accessibility_Check): Remove local constant Pool_Id and local variable Free_Stmt. Do not deallocate the faulty object as "free" is not available on all targets/profiles. 2013-07-08 Robert Dewar <dewar@adacore.com> * sem_ch13.adb (Analyze_Aspect_Specifications): Handle Storage_Size aspect for task type in case discriminant is referenced. (Analyze_Attribute_Definition_Clause): Do not flag Storage_Size attribute definition clause as obsolescent if from aspect. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@200771 138bc75d-0d04-0410-961f-82ee72b054a4