Commit Graph

115 Commits

Author SHA1 Message Date
Robert Dewar 19634e40b7 debug.adb: Document debug flag -gnatd.1.
2014-06-13  Robert Dewar  <dewar@adacore.com>

	* debug.adb: Document debug flag -gnatd.1.
	* layout.adb (Layout_Type): Size change for anonymous access
	types under -gnatd.1.
	* sem_ch3.adb (Replace_Type): Size change for anonymous access
	types under -gnatd.1.

From-SVN: r211619
2014-06-13 12:04:27 +02:00
Arnaud Charlet f8c59c0509 [multiple changes]
2014-06-11  Robert Dewar  <dewar@adacore.com>

	* sem_ch13.adb: Minor reformatting.

2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>

	* sem_prag.adb (Check_Clause_Syntax): Add new
	local variable Outputs. Account for the case where multiple
	output items appear as an aggregate.

2014-06-11  Robert Dewar  <dewar@adacore.com>

	* sem_warn.adb (Output_Obsolescent_Entity_Warnings): Tag warning
	with ?j? not ??.

2014-06-11  Ed Schonberg  <schonberg@adacore.com>

	* einfo.ads: Minor reformatting.

2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>

	* a-cbdlli.adb, a-cdlili.adb, a-cidlli.adb, a-crdlli.adb (Insert): Add
	new variable First_Node. Update the position after all insertions have
	taken place to First_Node.

2014-06-11  Robert Dewar  <dewar@adacore.com>

	* debug.adb: Remove debug flag -gnatd.1, no longer needed.
	* layout.adb (Layout_Type): Remove test of -gnatd.1.

From-SVN: r211465
2014-06-11 14:55:03 +02:00
Arnaud Charlet 3e65bfab4a [multiple changes]
2014-06-11  Thomas Quinot  <quinot@adacore.com>

	* freeze.ads: Minor reformatting.
	* checks.adb (Determine_Range): Do not attempt to determine
	the range of a deferred constant whose full view has not been
	seen yet.
	* sem_res.adb (Resolve): Remove undesirable guard against
	resolving expressions from expression functions.

2014-06-11  Robert Dewar  <dewar@adacore.com>

	* debug.adb (Debug_Flag_Dot_1): Set to enable fix for anonymous
	access types.
	* layout.adb (Layout_Type): Make anonymous access types for
	subprogram formal types and return types always thin. For now
	only enabled if -gnatd.1 set.

2014-06-11  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch13.adb (Analyze_Stream_TSS_Definition): Apply legality
	rule for stream attributes of interface types (RM 13.13.2 (38/3)):
	subprogram must be a null procedure.

From-SVN: r211464
2014-06-11 14:50:22 +02:00
Arnaud Charlet 43bebb1069 Code clean ups.
From-SVN: r211461
2014-06-11 14:47:10 +02:00
Arnaud Charlet 810241a5bf 2014-06-11 Sergey Rybin <rybin@adacore.com frybin>
* gnat_ugn.texi, vms_data.ads: add description of gnatstub -W<par>
	option to specify the result file encoding.

2014-06-11  Robert Dewar  <dewar@adacore.com>

	* errout.ads, sem_ch12.adb: Minor reformatting.
	* debug.adb, erroutc.adb: Remove -gnatd.q debug switch.
	* lib-xref.adb: Minor reformatting.
	* restrict.adb: Minor code reorganization (put routines in
	alpha order).

From-SVN: r211455
2014-06-11 14:25:22 +02:00
Arnaud Charlet b785e0b875 [multiple changes]
2014-06-11  Robert Dewar  <dewar@adacore.com>

	* debug.adb: Add debug flag -gnatd.q.
	* erroutc.adb (Prescan_Message): Bomb if untagged warning with
	-gnatd.q set.
	* styleg.adb (Check_Xtra_Parens): Message should be a style
	message.
	* sem_aggr.adb, sem_ch3.adb, exp_ch9.adb, checks.adb, sem_prag.adb,
	par-endh.adb, eval_fat.adb, freeze.adb, sem_util.adb, sem_attr.adb,
	sem_elab.adb, sem_ch6.adb, sem_warn.adb, sem_cat.adb,
	sem_ch13.adb, lib-xref.adb: Add remaining warning tags.

2014-06-11  Ben Brosgol  <brosgol@adacore.com>

	* gnat_rm.texi: Revised chapter on Implementation Defined
	Characteristics.

From-SVN: r211448
2014-06-11 12:55:15 +02:00
Arnaud Charlet ee6208f2d5 [multiple changes]
2014-05-21  Robert Dewar  <dewar@adacore.com>

	* gnatcmd.adb: Minor error msg changes (no upper case letter
	at start).
	* sem_ch12.adb, sem_ch5.adb, sem_res.adb, sem_util.adb: Minor
	reformatting.

2014-05-21  Robert Dewar  <dewar@adacore.com>

	* debug.adb: Debug flag -gnatd.G inhibits static elab tracing
	via generic formals.
	* sem_elab.adb (Is_Call_Of_Generic_Formal): Return False if
	-gnatd.G is set.

2014-05-21  Thomas Quinot  <quinot@adacore.com>

	* exp_pakd.adb (Revert_Storage_Order): Renamed from Byte_Swap to
	more accurately describe that this subprogram needs to come into
	play also in cases where no byte swapping is involved, because
	it also takes care of some required shifts (left-justification
	of values).

2014-05-21  Thomas Quinot  <quinot@adacore.com>

	* freeze.adb (Check_Component_Storage_Order): Indicate whether
	a Scalar_Storage_Order attribute definition is present for the
	component's type.
	(Freeze_Record_Type): Suppress junk warnings
	about purportedly junk Bit_Order / Scalar_Storage_Order attribute
	definitions.

2014-05-21  Robert Dewar  <dewar@adacore.com>

	* sem_ch8.adb (Analyze_Subprogram_Renaming): Put back call
	to Kill_Elaboration_Checks.

2014-05-21  Gary Dismukes  <dismukes@adacore.com>

	* layout.adb (Assoc_Add): Suppress the optimization of the (E
	- C1) + C2 case, when the expression type is unsigned and C1 <
	C2, to avoid creating a negative literal when folding.

From-SVN: r210709
2014-05-21 15:25:03 +02:00
Arnaud Charlet 23e28b4217 [multiple changes]
2014-05-21  Robert Dewar  <dewar@adacore.com>

	* sem_elab.adb, prj-dect.adb: Minor reformatting.

2014-05-21  Robert Dewar  <dewar@adacore.com>

	* erroutc.ads: Minor comment addition.

2014-05-21  Robert Dewar  <dewar@adacore.com>

	* errout.ads: Add documentation for use of >*> tag.
	* restrict.adb: Make sure we use >*> tag for restriction warnings.

2014-05-21  Gary Dismukes  <dismukes@adacore.com>

	* debug.adb: Add case of illegal overriding_indicator for a
	protected subprogram body to description of -gnatd.E switch.
	* sem_ch6.adb (Verify_Overriding_Indicator): Issue error message
	for cases of giving overriding_indicators on protected subprogram
	bodies, but change this to a warning if -gnatd.E is enabled. No
	longer give a style warning about missing indicators on protected
	subprogram bodies.

From-SVN: r210704
2014-05-21 15:08:13 +02:00
Arnaud Charlet 2735b82d09 [multiple changes]
2014-05-21  Robert Dewar  <dewar@adacore.com>

	* einfo.ads: Minor reformatting.
	* ceinfo.adb: Deal with slight format change of einfo.ads.

2014-05-21  Ed Schonberg  <schonberg@adacore.com>

	* sem_prag.adb (Analyze_Part_Of): Further work on the proper
	implementation of the SPARK 2014 rule concerning private child
	units (LRM 7.2.6).

2014-05-21  Vincent Celier  <celier@adacore.com>

	* makeusg.adb: Add switch -d to usage.

2014-05-21  Ed Schonberg  <schonberg@adacore.com>

	* sem_util.adb (Find_Actual): If an actual that is the prefix
	of an enclosing prefixed call has been rewritten, use Nkind
	and Sloc to identify the corresponding formal, when handling
	deferred references.

2014-05-21  Robert Dewar  <dewar@adacore.com>

	* debug.adb: Document -gnatd.z switch.
	* sem_eval.adb (Why_Non_Static): Test -gnatd.z switch.

From-SVN: r210689
2014-05-21 12:48:37 +02:00
Arnaud Charlet f1a3590ee2 [multiple changes]
2014-02-24  Thomas Quinot  <quinot@adacore.com>

	* s-os_lib.adb (Errno_Message): Do not depend on Integer'Image.
	* s-oscons-tmplt.c: On VxWorks, include adaint.h only after
	vxWorks.h has been included.  Also ensure that file attributes
	related definitions are output even in cases where socket support
	is not enabled.
	* a-tags.adb: Code clean up.
	* Make-generated.in (OSCONS_CPP, OSCONS_EXTRACT): Use -iquote
	instead of -I to add the main ada source directory to the header
	search path, in order to avoid conflict between our own "types.h"
	and VxWork's <types.h>.

2014-02-24  Robert Dewar  <dewar@adacore.com>

	* atree.ads, atree.adb (Copy_Separate_Tree): Add Syntax_Only parameter.
	* debug.adb: Remove documentation of -gnatd.X, no longer used.
	* freeze.adb (Wrap_Imported_Subprogram): Fixed and activated.

2014-02-24  Bob Duff  <duff@adacore.com>

	* gnat_ugn.texi: Improve documentation of gnatpp.

From-SVN: r208083
2014-02-24 18:01:19 +01:00
Arnaud Charlet 32bba3c9d8 [multiple changes]
2014-02-24  Robert Dewar  <dewar@adacore.com>

	* 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.

From-SVN: r208076
2014-02-24 17:30:08 +01:00
Arnaud Charlet d7cb47b448 [multiple changes]
2014-02-19  Robert Dewar  <dewar@adacore.com>

	* sem_ch5.adb, sem_prag.adb, sem_attr.adb: Minor reformatting.
	* debug.adb: Remove -gnatd.X switch, no longer used.
	* styleg.adb (Check_Then): Remove check of -gnatd.X, check is
	now always made.

2014-02-19  Bob Duff  <duff@adacore.com>

	* g-socket.ads: Minor: Correct some comments.

From-SVN: r207907
2014-02-19 16:05:43 +01:00
Arnaud Charlet 0b7f0f0e87 [multiple changes]
2014-02-19  Robert Dewar  <dewar@adacore.com>

	* par-ch6.adb (P_Return): For extended return, end column lines
	up with RETURN.
	* par.adb: Minor documentation clarification.

2014-02-19  Yannick Moy  <moy@adacore.com>

	* sem_prag.adb (Check_Loop_Pragma_Placement): Add check
	that Loop_Invariant and Loop_Variant appear consecutively.
	* gnat_rm.texi Update documentation of Loop_Invariant and
	Loop_Variant pragmas.

2014-02-19  Robert Dewar  <dewar@adacore.com>

	* debug.adb: Document -gnatd.X.
	* par-ch5.adb (P_If_Statement): Always check THEN, even if not
	first token
	(Check_Then_Column): Ditto.
	* styleg.adb (Check_Then): Allow THEN on line after IF.
	(Check_Then): Check THEN placement under control of -gnatd.X
	* styleg.ads (Check_Then): Now called even if THEN is not first
	token on line.
	* stylesw.ads (Style_Check_If_Then_Layout): Document new
	relaxed rules.
	* gnat_ugn.texi: For -gnatyi, THEN can now be on line after IF.

2014-02-19  Robert Dewar  <dewar@adacore.com>

	* a-cfhama.adb, a-cfhase.adb, a-cforse.adb, a-cofove.adb, a-ngcefu.adb,
	a-teioed.adb, a-wtedit.adb, a-ztedit.adb, exp_ch5.adb, inline.adb,
	prj-pp.adb, prj-tree.adb, sem_ch12.adb, sem_ch8.adb,
	vms_conv.adb: Fix bad layout of IF statements

From-SVN: r207893
2014-02-19 12:12:05 +01:00
Arnaud Charlet 5216b599a6 [multiple changes]
2014-02-06  Eric Botcazou  <ebotcazou@adacore.com>

	* gnat_rm.texi: Small wording tweak.

2014-02-06  Pascal Obry  <obry@adacore.com>

	* prj-attr.adb, projects.texi, snames.ads-tmpl: Add Included_Patterns
	and Included_Artifact_Patterns attribute definitions.

2014-02-06  Yannick Moy  <moy@adacore.com>

	* sem_ch6.adb (Analyze_Subprogram_Body_Helper): Set
	SPARK_Mode pragma component for all subprograms, including stubs.

2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>

	* sem_ch10.adb (Analyze_Package_Body_Stub): Maintain
	the configuration options of the enclosing context in a
	stack-like fasion.
	(Analyze_Subprogram_Body_Stub): Maintain the
	configuration options of the enclosing context in a stack-like
	fashion.

2014-02-06  Robert Dewar  <dewar@adacore.com>

	* debug.adb: -gnatd.u sets Modify_Tree_For C
	* exp_ch4.adb (Expand_N_Op_Rotate_Left): Expand out
	if Modify_Tree_For_C (Expand_N_Op_Rotate_Right): ditto.
	(Expand_N_Op_Arithmetic_Right_Shift): ditto.
	* exp_intr.adb (Expand_Shift): Call expander so we do
	Modify_Tree_For_C expansions.
	* gnat1drv.adb (Adjust_Global_Switches): Set Modify_Tree_For_C
	if -gnatd.u set.

2014-02-06  Fedor Rybin  <frybin@adacore.com>

	* prj-proc.ads (Tree_Loaded_Callback): new type Callback used
	after the phase 1 of the processing of each aggregated project
	to get access to project trees of aggregated projects.
	(Process_Project_Tree_Phase_1): new parameter On_New_Tree_Loaded
	If specified, On_New_Tree_Loaded is called after each aggregated
	project has been processed succesfully.
	(Process): new parameter On_New_Tree_Loaded.
	* prj-proc.adb (Process_Aggregated_Projects): On_New_Tree_Loaded
	callback added after processing of each aggregated project.
	(Recursive_Process): new parameter On_New_Tree_Loaded.
	(Process): new parameter On_New_Tree_Loaded.
	(Process_Project_Tree_Phase_1): new parameter On_New_Tree_Loaded.
	* prj-conf.ads (Parse_Project_And_Apply_Config): new parameter
	On_New_Tree_Loaded.
	* prj-conf.adb (Parse_Project_And_Apply_Config): new parameter
	On_New_Tree_Loaded.

2014-02-06  Bob Duff  <duff@adacore.com>

	* gnat_ugn.texi: Implement --insert-blank-lines and
	--preserve-blank-lines switches.

From-SVN: r207545
2014-02-06 11:19:06 +01:00
Arnaud Charlet b2834fbd22 [multiple changes]
2014-01-22  Robert Dewar  <dewar@adacore.com>

	* sem_aux.adb, sem_aux.ads, sem_ch3.adb (Has_Unconstrained_Elements):
	Moved to sem_aux.adb.

2014-01-22  Robert Dewar  <dewar@adacore.com>

	* vms_data.ads: Minor reformatting.

2014-01-22  Robert Dewar  <dewar@adacore.com>

	* debug.adb: Document messages affected by -gnatd.E including
	the new ones that relate to late definition of equality.
	* sem_ch6.adb (Check_Untagged_Equality): In Ada 2012 mode, if
	debug flag -gnatd.E is set, then generate warnings rather than
	errors.
	(Check_Untagged_Equality): In earlier versions of Ada,
	generate warnings if Warn_On_Ada_2012_Incompatibility flag is set.

2014-01-22  Robert Dewar  <dewar@adacore.com>

	* sem_prag.adb (Usage_Error): Output additional messages for
	unconstrained OUT parameters lacking an input dependency.

2014-01-22  Robert Dewar  <dewar@adacore.com>

	* sem_ch4.adb: Minor reformatting.

2014-01-22  Robert Dewar  <dewar@adacore.com>

	* restrict.ads: Minor reformatting.
	* sem_res.adb (Resolve_Call): Check for SPARK_05 restriction that
	forbids a call from within a subprogram to the same subprogram.

2014-01-22  Thomas Quinot  <quinot@adacore.com>

	* a-stream.ads (Read_SEA, Write_SEA): New subprograms, optimized
	stream attributes for Stream_Element_Array.
	* a-stream.adb (Read_SEA, Write_SEA): Bodies for the above.
	* rtsfind.adb (Check_CRT): Do not reject a reference to an entity
	defined in the current scope.

From-SVN: r206929
2014-01-22 17:47:20 +01:00
Arnaud Charlet d4129bfa7c [multiple changes]
2014-01-22  Robert Dewar  <dewar@adacore.com>

	* debug.adb, exp_ch4.adb, erroutc.adb: Minor reformatting.

2014-01-22  Thomas Quinot  <quinot@adacore.com>

	* sem_ch7.adb, sem_ch8.adb, exp_ch3.adb: Minor reformatting.

2014-01-22  Thomas Quinot  <quinot@adacore.com>

	* sem_ch3.adb (Analyze_Object_Declaration): For a constant
	declaration initialized with a function call, whose type
	has variable size, need to remove side effects so that the
	initialization expression becomes a dereference of a temporary
	reference to the function result.

From-SVN: r206928
2014-01-22 17:42:55 +01:00
Arnaud Charlet e19fd0bde5 [multiple changes]
2014-01-20  Ed Schonberg  <schonberg@adacore.com>

	* sem_attr.adb: Code and comments cleanup.

2014-01-20  Yannick Moy  <moy@adacore.com>

	* debug.adb Free debug flags -gnatd.D, -gnatd.G and -gnatd.V *
	* errout.adb (Compilation_Errors): Remove special handling in
	GNATprove mode.
	* gnat1drv.adb (Adjust_Global_Switches): Remove handling of the
	removed debug flags.
	* gnat_rm.texi: Initial documentation for Abstract_State, Depends,
	Global, Initial_Condition, Initializes and Refined_State pragmas and
	aspects.
	* opt.ads (Frame_Condition_Mode, Formal_Extensions,
	SPARK_Strict_Mode): Remove global flags.
	* sem_ch3.adb (Analyze_Object_Declaration): Check of no hidden state
	always performed now, on packages declaring a null state.
	(Signed_Integer_Type_Declaration): Remove ill-designed attempt
	at providing pedantic mode for bounds of integer types.
	* sem_ch4.adb (Analyze_Quantified_Expression): Warning on suspicious
	"some" quantified expression now issued under control of -gnatw.t,
	like the other warning on unused bound variable.
	* sem_prag.adb (Check_Precondition_Postcondition): Remove useless test
	on removed flag.
	(Analyze_Pragma): Remove tests for SPARK 2014
	pragmas, not officially allowed by GNAT.

From-SVN: r206837
2014-01-20 16:54:38 +01:00
Arnaud Charlet aca90db9e2 [multiple changes]
2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>

	* einfo.ads: E_Abstract_State is now part of the entities that
	can be overloaded. Update type Overloadable_Kind to reflect the
	inclusion of abstract states.
	* sem_ch6.adb (New_Overloaded_Entity): A function can now
	overload an abstract state.
	* sem_prag.adb (Analyze_Constituent): Handle the overloading
	of states by functions. Use Entity_Of to obtain the entity of
	a constituent.	(Analyze_Global_Item): Handle the overloading of
	states by functions.
	(Analyze_Initialization_Item): Handle the
	overloading of states by functions.  Use Entity_Of to obtain the
	entity of an item.
	(Analyze_Input_Item): Handle the overloading
	of states by functions. Use Entity_Of to obtain the entity of an item.
	(Analyze_Input_Output): Handle the overloading of states by functions.
	(Analyze_Refinement_Clause): Handle the overloading
	of states by functions.  Use Entity_Of to obtain the entity of an item.
	(Appears_In): Use Entity_Of to obtain the entity of an element.
	(Check_Usage): Use Entity_Of to obtain the entity of
	an item. Add a guard to prevent a crash due to a previous error.
	(Resolve_State): New routine.

2014-01-20  Yannick Moy  <moy@adacore.com>

	* spark_xrefs.ads, debug.adb, gnat1drv.adb, errout.adb, errout.ads,
	opt.ads: Minor comments updates.

From-SVN: r206809
2014-01-20 14:52:19 +01:00
Arnaud Charlet a7d08a3844 [multiple changes]
2013-10-17  Yannick Moy  <moy@adacore.com>

	* sem_res.adb (Resolve_Short_Circuit): Only
	generate expression-with-action when full expansion is set.

2013-10-17  Yannick Moy  <moy@adacore.com>

	* debug.adb Remove obsolete comment.

2013-10-17  Thomas Quinot  <quinot@adacore.com>

	* exp_ch4.adb (Process_Transient_Object.Find_Enclosing_Contexts):
	Avoid late insertion when expanding an expression with action
	nested within a transient block; Do not inconditionally generate
	a finalization call if the generated object is from a specific
	branch of a conditional expression.

2013-10-17  Pascal Obry  <obry@adacore.com>

	* g-arrspl.adb: Ensure Finalize call is idempotent.
	* g-arrspl.adb (Finalize): Makes the call idempotent.

From-SVN: r203768
2013-10-17 16:07:57 +02:00
Arnaud Charlet 0247964def [multiple changes]
2013-10-14  Robert Dewar  <dewar@adacore.com>

	* exp_prag.adb, exp_ch11.adb, s-exctab.adb: Minor reformatting.
	* usage.adb: Add line for -gnateu switch.

2013-10-14  Vincent Celier  <celier@adacore.com>

	* lib-writ.ads: Add comments to indicate that a path name in
	D lines may be quoted if the path name includes directories
	with spaces.

2013-10-14  Robert Dewar  <dewar@adacore.com>

	* debug.adb: Document -gnatd.E.
	* gnat1drv.adb (Adjust_Global_Switches): Set Error_To_Warning
	if -gnatd.E set.
	* opt.ads (Error_To_Warning): New switch.
	* osint.adb: Minor reformatting.
	* sem_warn.adb (Warn_On_Overlapping_Actuals): Overlap is error
	in some cases in Ada 2012 mode (unless Error_To_Warning) is set.
	* sem_warn.ads (Warn_On_Overlapping_Actuals): Document error
	in Ada 2012 mode.

2013-10-14  Tristan Gingold  <gingold@adacore.com>

	* cstand.adb: Add a comment for Standard_Exception_Type.

2013-10-14  Ed Schonberg  <schonberg@adacore.com>

	* exp_ch4.adb (Process_Transient_Object): If a transient scope
	has already been created, use the corresponding Node_To_Be_Wrapped
	as the insertion point for the controlled actions.

From-SVN: r203539
2013-10-14 15:10:22 +02:00
Arnaud Charlet 577ee3a966 [multiple changes]
2013-10-14  Robert Dewar  <dewar@adacore.com>

	* exp_prag.adb (Expand_Pragma_Check): Generate proper string
	for invariant
	* gnat_rm.texi: Add documentation for pragmas
	Type_Invariant[_Class]
	* par-prag.adb: Add entries for pragmas Type_Invariant[_Class]
	* sem_ch13.adb: Minor reformatting
	* sem_prag.adb: Implement pragmas Type_Invariant[_Class]
	* snames.ads-tmpl: Add entries for pragmas Type_Invariant[_Class]

2013-10-14  Johannes Kanig  <kanig@adacore.com>

	* debug.adb: Release now unused debug switches that were only
	relevant for gnat2why backend, not the frontend
	* frontend.adb (Frontend) Do not stop when -gnatd.H is present,
	was unused

From-SVN: r203524
2013-10-14 14:37:45 +02:00
Arnaud Charlet 0c5dba7ff5 [multiple changes]
2013-10-10  Robert Dewar  <dewar@adacore.com>

	* gnatlink.adb: Minor reformatting.

2013-10-10  Yannick Moy  <moy@adacore.com>

	* debug.adb: Free flag d.E and change doc for flag d.K.

2013-10-10  Ed Schonberg  <schonberg@adacore.com>

	* sem_prag.adb (Check_Precondition_Postcondition): If the
	pragma comes from an aspect spec, and the subprogram is a
	library unit, treat as a ppc in a declarative part in ASIS mode,
	so that expression in aspect is properly analyzed. In this case
	there is no later point at which the aspect specification would
	be examined.

2013-10-10  Bob Duff  <duff@adacore.com>

	* opt.ads: Minor comment fix.

2013-10-10  Vadim Godunko  <godunko@adacore.com>

	* a-coinho-shared.ads, a-coinho-shared.adb: New file.
	* s-atocou.ads: Add procedure to initialize counter.
	* s-atocou.adb: Likewise.
	* s-atocou-builtin.adb: Likewise.
	* s-atocou-x86.adb: Likewise.
	* gcc-interface/Makefile.in: Select special version of
	Indefinite_Holders package on platforms where atomic built-ins
	are supported. Update tools target pairs for PikeOS.

From-SVN: r203344
2013-10-10 12:47:59 +02:00
Arnaud Charlet 0812b84e77 [multiple changes]
2013-04-25  Robert Dewar  <dewar@adacore.com>

	* debug.adb: Remove d.X and d.Y entries and documentation.
	* exp_ch4.adb (Expand_N_If_Expression): Remove special code used
	if expression with actions not available (now always available).
	(Expand_Short_Circuit_Operator): Same change.
	* gnat1drv.adb (Adjust_Global_Switches) Remove setting
	Use_Expression_With_Actions flag, since this is now obsolete.
	* opt.ads (Use_Expression_Actions): Removed (always True now).
	* sinfo.ads: Minor comment updates.

2013-04-25  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch12.adb (Check_Generic_Actuals): If an actual is an array
	subtype whose base type is currently private, install full view
	when compiling instance body.

2013-04-25  Ed Schonberg  <schonberg@adacore.com>

	* sem_disp.adb (Check_Dispatching_Operation): Refine checks for
	AI05-0125: the check for a hidden primitive that may be overridden
	by the new declaration is only performed if the declaration comes
	from source, and it must carry an explicit overriding indicator.

2013-04-25  Hristian Kirtchev  <kirtchev@adacore.com>

	* einfo.adb (Abstract_States): The attribute now applies to
	generic packages.
	* sem_ch3.adb (Analyze_Object_Declaration): Check whether an
	object declaration introduces an illegal hidden state.
	* sem_prag.adb (Analyze_Abstract_State): Check whether a state
	declaration introduces an illegal hidden state.
	* sem_util.ads, sem_util.adb (Check_No_Hidden_State): New routine.

2013-04-25  Ed Schonberg  <schonberg@adacore.com>

	* exp_ch6.adb (Is_Build_In_Place_Function_Call): The call may
	be to a protected function, in which case the name in the call
	is a selected component.

2013-04-25  Hristian Kirtchev  <kirtchev@adacore.com>

	* sem_ch4.adb (Analyze_Quantified_Expression):
	Warn on a suspicious use of quantifier "some" when "all" was meant.
	(No_Else_Or_Trivial_True): New routine.

From-SVN: r198287
2013-04-25 12:28:45 +02:00
Yannick Moy 06b599fd62 adabkend.adb, [...]: Everything with name 'Alfa' renamed in 'SPARK'.
2013-04-24  Yannick Moy  <moy@adacore.com>

	* adabkend.adb, ali-util.adb, ali.adb, debug.adb,
	errout.adb, errout.ads, erroutc.adb, exp_ch3.adb, exp_ch4.adb,
	exp_ch6.adb, exp_ch7.adb, exp_dbug.adb, exp_util.adb,
	expander.adb, freeze.adb, gnat1drv.adb, lib-writ.adb,
	lib-writ.ads, lib-xref.adb, lib-xref.ads, opt.adb, opt.ads,
	restrict.adb, sem_aggr.adb, sem_attr.adb, sem_ch3.adb,
	sem_ch4.adb, sem_ch5.adb, sem_ch6.adb, sem_eval.adb, sem_prag.adb,
	sem_res.adb, sem_util.adb: Everything with name
	'Alfa' renamed in 'SPARK'. Update comments.
	Renaming of units with name 'Alfa', renamed with 'SPARK' instead.
	* exp_alfa.adb: renamed exp_spark.adb.
	* exp_alfa.ads: renamed exp_spark.ads.
	* get_alfa.adb: renamed get_spark_xrefs.adb.
	* get_alfa.ads: renamed get_spark_xrefs.ads.
	* lib-xref-alfa.adb: renamed lib-xref-spark_specific.adb.
	* put_alfa.adb: renamed put_spark_xrefs.adb.
	* put_alfa.ads: renamed put_spark_xrefs.ads.
	* alfa.adb: renamed spark_xrefs.adb.
	* alfa.ads: renamed spark_xrefs.ads.
	* alfa_test.adb: renamed spark_xrefs_test.adb.

From-SVN: r198234
2013-04-24 16:14:27 +02:00
Arnaud Charlet a96157e6ac [multiple changes]
2013-04-11  Eric Botcazou  <ebotcazou@adacore.com>

	* ttypes.ads, get_targ.ads: More minor rewording of comments.

2013-04-11  Johannes Kanig  <kanig@adacore.com>

	* debug.adb: Document use of switch -gnatd.Z.

2013-04-11  Hristian Kirtchev  <kirtchev@adacore.com>

	* sem_prag.adb (Analyze_Pragma): Both pragma Depends and Global can now
	support renamings of entire objects. Legal renamings are replaced by
	the object they rename.
	(Is_Renaming): New routine.

2013-04-11  Yannick Moy  <moy@adacore.com>

	* set_targ.adb, opt.ads: Minor changes in comments.

From-SVN: r197795
2013-04-11 15:30:34 +02:00
Arnaud Charlet e7f11067a1 [multiple changes]
2013-04-11  Johannes Kanig  <kanig@adacore.com>

	* debug.adb: Document usage of -gnatd.Q switch.

2013-04-11  Matthew Heaney  <heaney@adacore.com>

	* a-crbtgk.adb (Ceiling, Find, Floor): Adjust locks
	before element comparisons.
	(Generic_Conditional_Insert, Generic_Conditional_Insert_With_Hint):
	Ditto.
	* a-crbtgo.adb, a-rbtgbo.adb (Generic_Equal): Adjust locks before
	element comparisons.
	* a-rbtgso.adb (Difference, Intersection): Adjust locks
	before element comparisons.
	(Is_Subset, Overlap): Ditto
	(Symmetric_Difference, Union): Ditto
	* a-btgbso.adb (Set_Difference, Set_Intersection): Adjust locks
	before element comparisons.
	(Set_Subset, Set_Overlap): Ditto
	(Set_Symmetric_Difference, Set_Union): Ditto
	* a-coorse.adb, a-ciorse.adb, a-cborse.adb
	(Update_Element_Preserving_Key): Adjust locks before element
	comparisons (Replace_Element): Ditto

2013-04-11  Pascal Obry  <obry@adacore.com>

	* prj-attr.adb, projects.texi, snames.ads-tmpl: Remove Build_Slaves
	attribute.

2013-04-11  Ed Schonberg  <schonberg@adacore.com>

	* exp_ch3.adb (Build_Equivalent_Aggregate): Subsidiary of
	Expand_N_Object_Declaration, used to construct an aggregate
	with static components whenever possible, so that objects of a
	discriminated type can be initialized without calling the init.
	proc for the type.

2013-04-11  Vincent Celier  <celier@adacore.com>

	* prj-makr.adb (Process_Directory): On VMS, always delete,
	then recreate the temporary file with Create_Output_Text_File,
	otherwise the output redirection does not work properly.

2013-04-11  Eric Botcazou  <ebotcazou@adacore.com>

	* urealp.ads: Fix minor typo.

2013-04-11  Fabien Chouteau  <chouteau@adacore.com>

	* cio.c (mktemp): Don't use tmpnam function from the
	system on VxWorks in kernel mode.

From-SVN: r197784
2013-04-11 14:53:52 +02:00
Arnaud Charlet 8bfbd380f2 [multiple changes]
2013-04-11  Arnaud Charlet  <charlet@adacore.com>

	* gnat1drv.adb: Minor code clean up.

2013-04-11  Arnaud Charlet  <charlet@adacore.com>

	* debug.adb, sem_ch13.adb (Analyze_Enumeration_Representation_Clause):
	Ignore enumeration rep clauses by default in CodePeer mode, unless
	-gnatd.I is specified.

2013-04-11  Ed Schonberg  <schonberg@adacore.com>

	* sem_util.adb (Safe_To_Capture_Value): If the node belongs to
	an expression that has been attached to the else_actions of an
	if-expression, the capture is not safe.

2013-04-11  Yannick Moy  <moy@adacore.com>

	* checks.adb (Apply_Type_Conversion_Checks): Put check mark on type
	conversion for arrays.

2013-04-11  Robert Dewar  <dewar@adacore.com>

	* a-cdlili.adb, a-cidlli.adb, a-cbdlli.adb: Minor reformatting.

2013-04-11  Johannes Kanig  <kanig@adacore.com>

	* adabkend.adb: Minor comment addition.

From-SVN: r197773
2013-04-11 14:25:16 +02:00
Johannes Kanig 0213fb4e3c debug.adb: Reservation and documentation for -gnatd.G switch.
2013-04-11  Johannes Kanig  <kanig@adacore.com>

	* debug.adb: Reservation and documentation for -gnatd.G switch.
	* gnat1drv.adb (Adjust_Global_Switches) Take into account -gnatd.G
	switch, and set ALI file generation accordingly.

From-SVN: r197757
2013-04-11 12:17:18 +02:00
Arnaud Charlet 5b75bf576f [multiple changes]
2013-04-11  Robert Dewar  <dewar@adacore.com>

	* sem_prag.adb, sem_attr.adb, gnat1drv.adb, prj-makr.adb,
	opt.ads, sem_ch13.adb: Minor reformatting.
	* debug.adb: Minor comment fix (remove junk .I doc).

2013-04-11  Thomas Quinot  <quinot@adacore.com>

	* rtsfind.ads, exp_dist.adb, exp_dist.ads (Rtsfind.PCS_Version, case
	PolyORB): Bump to 6.
	(Exp_Dist.PolyORB_Support): Replace TC_Build with
	Build_Complex_TC.

From-SVN: r197752
2013-04-11 11:49:40 +02:00
Arnaud Charlet 303fbb20de [multiple changes]
2013-04-11  Arnaud Charlet  <charlet@adacore.com>

	* debug.adb, sem_prag.adb, par-ch2.adb, sem_attr.adb, gnat1drv.adb,
	exp_disp.adb, opt.ads, sem_ch13.adb (Relaxed_RM_Semantics): New flag.
	Enable this flag in CodePeer mode, and also via -gnatd.M.
	Replace some uses of CodePeer_Mode by Relaxed_RM_Semantics.

2013-04-11  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch8.adb (Check_Constrained_Object): If a subtype is created
	from the renamed object in an object renaming declaration with
	an unconstrained nominal subtype, freeze the created subtype at
	once, to prevent order of elaboration issues in the backend.

2013-04-11  Arnaud Charlet  <charlet@adacore.com>

	* exp_aggr.adb (Aggr_Size_OK): Refine setting of Max_Aggr_Size
	in particular in CodePeer mode.

2013-04-11  Vincent Celier  <celier@adacore.com>

	* gnat_ugn.texi: Add documentation for backup copies of project
	files for gnatname.

From-SVN: r197751
2013-04-11 11:46:54 +02:00
Arnaud Charlet 28270211f0 [multiple changes]
2013-04-11  Thomas Quinot  <quinot@adacore.com>

	* exp_ch4.adb (Find_Enclosing_Context): Add missing case of
	N_Procedure_Call_Statement.

2013-04-11  Robert Dewar  <dewar@adacore.com>

	* debug.adb: Minor comment fix.

From-SVN: r197748
2013-04-11 11:39:15 +02:00
Arnaud Charlet 6b670dcfa7 [multiple changes]
2013-04-11  Johannes Kanig  <kanig@adacore.com>

	* debug.adb: Remove comment for -gnatd.G.

2013-04-11  Thomas Quinot  <quinot@adacore.com>

	* exp_ch4.adb (Expand_Record_Equality.Suitable_Element):
	Remove recursive routine, replace with...
	(Expand_Record_Equality.Element_To_Compare): New subroutine,
	implement iterative search for next element to compare.
	Add explanatory comment in the tagged case.

From-SVN: r197747
2013-04-11 11:38:07 +02:00
Arnaud Charlet 97948f419d [multiple changes]
2012-12-05  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch3.adb (Build_Derived_Private_Type): Handle properly a
	completion in a grand-child unit when the parent type is itself
	a private type in a child unit whose full view is itself a
	derivation from a private type.

2012-12-05  Gary Dismukes  <dismukes@adacore.com>

	* exp_attr.adb (Expand_N_Attribute_Reference, case
	Attribute_Valid): Remove code for issuing warning on Valid within
	a predicate. Moved to Sem_Attr.  Remove with and use of Errout.
	* sem_attr.adb (Analyze_Attribute, case Attribute_Valid):
	Test for prefix's subtype having a predicate and issue warning
	about infinite recursion if Valid occurs within the subtype's
	predicate. Warning moved here from Exp_Attr.

2012-12-05  Yannick Moy  <moy@adacore.com>

	* debug.adb: Minor comment addition.

2012-12-05  Yannick Moy  <moy@adacore.com>

	* gnat1drv.adb (Adjust_Global_Switches): In CodePeer mode, check
	overflows by default, even when the user suppresses overflow checks.

From-SVN: r194190
2012-12-05 11:10:04 +01:00
Arnaud Charlet 5568a7363e [multiple changes]
2012-10-29  Yannick Moy  <moy@adacore.com>

	* debug.adb Associate debug switch -gnatd.V to extensions for
	formal verification.
	* gnat1drv.adb (Adjust_Global_Switches): Set flag S14_Extensions
	when -gnatd.V is set.
	* gnat_rm.texi: Remove doc for Assert_And_Cut.
	* opt.ads Declare new flag S14_Extensions, to be set when new
	aspects/pragmas/attributes for formal verification should be
	accepted.
	* sem_prag.adb (Analyze_Pragma): Check that S14_Extensions is
	set when treating pragma Assert_And_Cut.

2012-10-29  Tristan Gingold  <gingold@adacore.com>

	* s-tarest.ads, s-tassta.adb: Add a pragma Partition_Elaboration_Policy.

From-SVN: r192931
2012-10-29 12:07:12 +01:00
Robert Dewar 9b16cb57de par_sco.adb, [...]: Change name Conditional_Expression to If_Expression.
2012-10-02  Robert Dewar  <dewar@adacore.com>

	* par_sco.adb, sem_ch3.adb, layout.adb, exp_ch7.adb, exp_imgv.adb,
	exp_util.adb, exp_util.ads, exp_attr.adb, sinfo.adb, sinfo.ads,
	exp_ch9.adb, style.ads, scos.ads, debug.adb, einfo.ads, scng.adb,
	checks.adb, checks.ads, sem.adb, par-ch4.adb, sem_util.adb, types.h,
	sem_res.adb, expander.adb, scans.ads, par.adb, exp_ch2.adb,
	gnat1drv.adb, stylesw.ads, sem_elab.adb, exp_ch4.adb, exp_ch4.ads,
	exp_ch6.adb, sem_ch4.adb, sem_ch4.ads, sem_ch6.adb,
	opt.ads, sem_eval.adb, sem_eval.ads, exp_intr.adb, sprint.adb,
	sprint.ads, styleg.ads: Change name Conditional_Expression to
	If_Expression.
	* gcc-interface/trans.c (gnat_to_gnu): Replace
	N_Conditional_Expression by N_If_Expression.
	* gcc-interface/Make-lang.in: Update dependencies.

From-SVN: r191967
2012-10-02 10:48:27 +02:00
Arnaud Charlet 727e7b1a87 [multiple changes]
2012-07-12  Robert Dewar  <dewar@adacore.com>

	* s-atopri.adb, s-atopri.ads: Minor reformatting.

2012-07-12  Robert Dewar  <dewar@adacore.com>

	* ali.adb: Add circuitry to read new named form of restrictions lines.
	* debug.adb: Add doc for new -gnatd.R switch (used positional
	notation for output of restrictions data in ali file).
	* lib-writ.adb: Implement new named format for restrictions lines.
	* lib-writ.ads: Add documentation for new named format for
	restrictions in ali files.
	* restrict.adb, restrict.ads, sem_prag.adb: Update comments.
	* rident.ads: Go back to withing System.Rident
	* s-rident.ads: Add extensive comment on dealing with consistency
	checking.

2012-07-12  Thomas Quinot  <quinot@adacore.com>

	* par_sco.adb, scos.ads: Emit detailed SCOs for SELECT statements.

From-SVN: r189438
2012-07-12 12:49:10 +02:00
Arnaud Charlet 36504e5f46 [multiple changes]
2012-04-02  Yannick Moy  <moy@adacore.com>

	* osint.adb, osint.ads (Add_Default_Search_Dirs): Add library
	search dirs in file specified with option -gnateO.

2012-04-02  Robert Dewar  <dewar@adacore.com>

	* sem_ch5.adb, exp_util.adb, sem_util.adb, exp_ch4.adb: Minor
	reformatting.

2012-04-02  Olivier Hainque  <hainque@adacore.com>

	* g-sse.ads: Add x86-solaris and x86_64-darwin to the set of
	platforms where the use of this spec is supported. Add current
	year to the copyright notice.
	* gcc-interfaces/Makefile.in: Add g-sse.o and g-ssvety.o to
	EXTRA_GNATRTL_NONTASKING_OBJS on x86 32/64 targets that support
	it and where they were missing (x86-solaris, x86-freebsd,
	x86_64-freebsd, and x86-darwin).

2012-04-02  Gary Dismukes  <dismukes@adacore.com>

	* bindgen.adb (Gen_Ada_Init): When compiling for the AAMP small
	library, where we no longer suppress the Standard_Library,
	generate an empty body rather than the usual generation of
	assignments to imported globals, since those aren't present in
	the small library.

2012-04-02  Ed Schonberg  <schonberg@adacore.com>

	* sinfo.ads: Minor documentation fix.

2012-04-02  Hristian Kirtchev  <kirtchev@adacore.com>

	* sem_res.adb (Resolve_Conditional_Expression): Add local variables
	Else_Typ and Then_Typ. Add missing type conversions to the "then" and
	"else" expressions when their respective types are scalar.

2012-04-02  Vincent Pucci  <pucci@adacore.com>

	* exp_ch9.adb: Reordering of the local subprograms. New Table
	for the lock free implementation that maps each protected
	subprograms with the protected component it references.
	(Allow_Lock_Free_Implementation): New routine. Check if
	the protected body enables the lock free implementation.
	(Build_Lock_Free_Protected_Subprogram_Body): New routine.
	(Build_Lock_Free_Unprotected_Subprogram_Body): New routine.
	(Comp_Of): New routine.
	* Makefile.rtl: Add s-atopri.o
	* debug.adb: New compiler debug flag -gnatd9 for lock free
	implementation.
	* rtsfind.ads: RE_Atomic_Compare_Exchange_8,
	RE_Atomic_Compare_Exchange_16, RE_Atomic_Compare_Exchange_32,
	RE_Atomic_Compare_Exchange_64, RE_Atomic_Load_8,
	RE_Atomic_Load_16, RE_Atomic_Load_32, RE_Atomic_Load_64, RE_Uint8,
	RE_Uint16, RE_Uint32, RE_Uint64 added.
	* s-atropi.ads: New file. Defines atomic primitives used
	by the lock free implementation.

From-SVN: r186076
2012-04-02 11:47:18 +02:00
Arnaud Charlet 2a1f6a1f90 [multiple changes]
2012-03-19  Yannick Moy  <moy@adacore.com>

	* sem_ch6.adb: Minor code clean up.

2012-03-19  Vincent Celier  <celier@adacore.com>

	* make.adb (Scan_Make_Arg): Make sure all significant -m switches
	on the command line are counted.

2012-03-19  Robert Dewar  <dewar@adacore.com>

	* sem_elab.adb (Generate_Elab_Warnings): Fix spec, fix attribute
	reference case

2012-03-19  Robert Dewar  <dewar@adacore.com>

	* par-ch4.adb (Check_Bad_Exp): New procedure

2012-03-19  Robert Dewar  <dewar@adacore.com>

	* exp_attr.adb, sem_attr.adb, sem_attr.ads, snames.ads-tmpl: Add
	initial framework for Valid_Scalars attribute.

2012-03-19  Robert Dewar  <dewar@adacore.com>

	* scng.adb (Scan): Recognize incorrect preprocessor directive

2012-03-19  Robert Dewar  <dewar@adacore.com>

	* atree.adb (Allocate_Initialize_Node): Use Num_Extension_Nodes
	* atree.ads (Num_Extension_Nodes): New variable
	* debug.adb: New debug flag -gnatd.N
	* gnat1drv.adb (Adjust_Global_Switches): Adjust
	Num_Extension_Nodes if -gnatd.N set

2012-03-19  Eric Botcazou  <ebotcazou@adacore.com>

	* einfo.ads: Minor update to First_Rep_Item and Has_Gigi_Rep_Item
	descriptions.

2012-03-19  Robert Dewar  <dewar@adacore.com>

	* opt.ads: Remove HLO_Active flag.
	* sem.adb: Remove call of high level optimizer.
	* sem.ads (New_Nodes_OK): Removed.
	* sem_ch10.adb: Remove references to New_Nodes_OK.
	* switch-c.adb: Remove handling of -gnatH switch.

From-SVN: r185528
2012-03-19 17:41:25 +01:00
Arnaud Charlet 78c0f01606 [multiple changes]
2012-03-19  Hristian Kirtchev  <kirtchev@adacore.com>

	* sem_ch3.adb (Get_Discriminant_Value): Instead of looking
	at the immediate correcponsing discriminant, traverse a
	potential chain of discriminants produced by type derivations.
	(Root_Corresponding_Discriminant): Traverse a chain of inherited
	discriminants and return the topmost discriminant.

2012-03-19  Bob Duff  <duff@adacore.com>

	* debug.adb: Minor comment change.
	* gnat_ugn.texi: Update documentation for elaboration regarding
	indirect calls.

2012-03-19  Gary Dismukes  <dismukes@adacore.com>

	* exp_ch3.adb (Expand_N_Object_Declaration): In
	the case of an object of a class-wide interface type, where the
	declaration is rewritten as a renaming, call Set_Debug_Info_Needed
	on the renaming entity so that Materialize_Entity will be
	set. Also, change existing call (for other than interface cases)
	to call Set_Debug_Info_Needed rather than Set_Needs_Debug_Info
	(as specified for that flag).

From-SVN: r185526
2012-03-19 17:29:27 +01:00
Arnaud Charlet 1f163ef7ac [multiple changes]
2012-03-15  Robert Dewar  <dewar@adacore.com>

	* errout.ads: Add entry for translating -gnateinn to
	/MAX_INSTANTIATIONS for VMS.
	* hostparm.ads (Max_Instantiations): Moved to Opt.
	* opt.ads (Maximum_Instantiations): Moved from Hostparm, and renamed.
	* sem_ch12.adb (Maximum_Instantiations): New name of
	Max_Instantiations (Analyze_Package_Instantiation): Change error
	msg for too many instantiations (mention -gnateinn switch).
	* switch-c.adb (Scan_Front_End_Switches): Implement -gnateinn switch.
	* switch.ads: Minor comment update.
	* usage.adb (Usage): Output line for -maxeinn switch.
	* vms_data.ads: Add entry for MAX_INSTANTIATIONS (-gnateinn).

2012-03-15  Yannick Moy  <moy@adacore.com>

	* alfa.ads Update the decription of ALI sections.
	(Alfa_File_Record): Add a component Unit_File_Name to store the
	unit file name for subunits.
	* get_alfa.adb, put_alfa.adb Adapt to the possible presence of
	a unit file name.
	* lib-xref-alfa.adb (Add_Alfa_File): For subunits, retrieve the
	file name of the unit.

2012-03-15  Yannick Moy  <moy@adacore.com>

	* sem_ch6.adb (Check_Subprogram_Contract): Do
	not issue warning on missing 'Result in postcondition if all
	postconditions and contract-cases already get a warning for only
	referring to pre-state.

2012-03-15  Bob Duff  <duff@adacore.com>

	* debug.adb: Add new debug switch -gnatd.U, which disables the
	support added below, in case someone trips over a cycle, and needs
	to disable this.
	* sem_attr.adb (Analyze_Access_Attribute):
	Treat Subp'Access as a call for elaboration purposes.
	* sem_elab.ads, sem_elab.adb (Check_Elab_Call): Add support
	for Subp'Access.

From-SVN: r185422
2012-03-15 10:15:49 +01:00
Javier Miranda 84f4072a8e sem_ch3.adb (Analyze_Object_Declaration): If the object declaration has an init expression then stop the analysis of the...
2012-03-07  Javier Miranda  <miranda@adacore.com>

	* sem_ch3.adb (Analyze_Object_Declaration): If the object
	declaration has an init expression then stop the analysis of the
	object declaration if the expression which initializes the object
	is a call to an inlined function which returns an unconstrained
	and has been expanded into a procedure call.
	* sem_ch5.adb (Has_Call_Using_Secondary_Stack): Add missing
	support to handle selected components.
	* sem_ch6.ads (Cannot_Inline): Adding parameter Is_Serious plus
	documentation.
	* sem_ch6.adb (Check_And_Build_Body_To_Inline): New
	subprogram which implements the checks required by the
	new rules for frontend inlining and builds the body to inline.
	(Analyze_Subprogram_Body_Helper): Move code that
	checks inlining of subprogram that has nested subprogram
	to Check_And_Build_Body_To_Inline.  Replace call to
	Build_Body_To_Inline by call to the new subprogram
	Check_And_Build_Body_To_Inline.
	(Cannot_Inline): New implementation.
	* sem_ch12.adb (Analyze_Package_Instantiation.Must_Inline_Subp):
	New subprogram.
	* sem_util.ad[sb] (Must_Inline): New subprogram.
	(Returns_Unconstrained_Type): New subprogram.
	* sem_res.adb (Resolve_Call): Do not create a transient scope
	for inlined calls.
	* inline.ads (Analyzing_Inlined_Bodies): Remove unreferenced variable.
	* inline.adb (Analyze_Inlined_Bodies, Initialize): Remove setting
	to false the variable Analyzing_Inlined_Bodies.  Fix comments.
	* exp_ch4.adb (Expand_N_Allocator): Fix handling of finalization master.
	* exp_ch6.ads (List_Inlining_Info): New subprogram.
	* exp_ch6.adb (Expand_Call.Do_Inline): New subprogram.
	(Expand_Call.Do_Inline_Always): New subprogram.
	(In_Unfrozen_Instance): Move the declaration of this subprogram.
	(Expand_Inlined_Call.Reset_Dispatching_Calls): New subprogram.
	(Expand_Inlined_Call): Adding new support for inlining functions
	that return unconstrained types.
	(List_Inlining_Info): New subprogram.
	* debug.adb Document flags -gnatd.j and -gnatd.k
	* gnat1drv.adb Add call to generate the new listing of inlined
	calls and calls passed to the backend.

From-SVN: r185055
2012-03-07 15:56:40 +01:00
Arnaud Charlet 12b4d33822 [multiple changes]
2011-10-24  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch12.adb (Earlier): make available globally. If both
	nodes have the same sloc, the freeze node that does not come
	from source is the later one.
	(True_Parent): Make available globally.
	(Previous_Instance): Subsidiary of
	Insert_Freeze_Node_For_Instance, to check whether the generic
	parent of the current instance is declared within a previous
	instance in the same unit or declarative  part, in which case the
	freeze nodes of both instances must appear in order to prevent
	elaboration problems in gigi.
	* sem_ch12.adb (Insert_Freeze_Node_For_Instance): A stub is a
	freeze point, and the freeze node of a preceding instantiation
	must be inserted before it.

2011-10-24  Robert Dewar  <dewar@adacore.com>

	* checks.ads, checks.adb: Add handling of Synchronization_Check
	* debug.adb: Add doc for -gnatd.d and -gnatd.e (disable/enable
	atomic sync).
	* exp_ch2.adb (Expand_Entity_Reference): Set Atomic_Sync_Required
	flag Minor code reorganization.
	* opt.ads (Warn_On_Atomic_Synchronization): New switch.
	* par-prag.adb: Add dummy entries for pragma
	Disable/Enable_Atomic_Synchronization.
	* sem_prag.adb (Process_Suppress_Unsuppress): Handle
	case of Atomic_Synchronization specially (not suppressed
	by All_Checks, cannot be set from Source).
	(Pragma Disable/Enable_Atomic_Synchronization): Add processing.
	* sinfo.ads, sinfo.adb: Add Atomic_Sync_Required flag
	* snames.ads-tmpl: Add entry for Atomic_Synchronization Add
	entry for pragma Disable/Enable_Atomic_Synchronization
	* switch-c.adb: The -gnatp switch does not disable
	Atomic_Synchronization Add -gnatep switch to disable
	Atomic_Synchronization.
	* types.ads: Add entry for Synchronization_Check
	* usage.adb: Add line for -gnated switch
	* warnsw.adb: Settings for Warn_On_Atomic_Synchronization

From-SVN: r180373
2011-10-24 11:51:42 +02:00
Arnaud Charlet da124b6afd [multiple changes]
2011-09-27  Robert Dewar  <dewar@adacore.com>

	* a-comutr.ads: Minor reformatting.

2011-09-27  Ed Schonberg  <schonberg@adacore.com>

	* a-cimutr.adb, a-cimutr.ads, a-cbmutr.adb, a-cbmutr.ads: Add children
	iterators to multiway trees.

2011-09-27  Yannick Moy  <moy@adacore.com>

	* debug.adb (d.D): New option for strict Alfa mode.
	* opt.ads (Strict_Alfa_Mode): New flag to interpret compiler
	permissions as strictly as possible.
	* sem_ch3.adb (Signed_Integer_Type_Declaration): In non-strict
	Alfa mode, now, interpret ranges of base types like GNAT does; in
	strict mode, simply change the range of the implicit base Itype.
	* gnat1drv.adb: Update comments. Set Strict_Alfa_Mode.

From-SVN: r179258
2011-09-27 12:03:09 +02:00
Arnaud Charlet 24c3410793 [multiple changes]
2011-08-31  Pascal Obry  <obry@adacore.com>

	* a-direct.adb: Do not try to create an UNC path on Windows.
	(Create_Path): Skip leading computer name in UNC path if any.

2011-08-31  Hristian Kirtchev  <kirtchev@adacore.com>

	* exp_strm.adb (Build_Record_Or_Elementary_Input_Function): Remove the
	version-dependent generation of the return statement. The Ada 2005 tree
	is now the default.

2011-08-31  Thomas Quinot  <quinot@adacore.com>

	* rtsfind.ads, exp_dist.adb (Find_Numeric_Representation): Predefined
	types Stream_Element_Offset and Storage_Offset have a different native
	type depending on whether the platform is 32 or 64 bits. When
	exchanging them, always convert to 64 bits.

2011-08-31  Yannick Moy  <moy@adacore.com>

	* debug.adb: Reserve debug option -gnatd.E for passing gnatprove option
	--force-alfa to gnat2why.

2011-08-31  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch12.adb (Save_References): If the node has aspects, save
	references within the corresponding expressions in a separate step,
	because the aspects are not directly in the tree for the declaration
	to which they belong.

2011-08-31  Arnaud Charlet  <charlet@adacore.com>

	* freeze.adb (Freeze_Record_Type): Omit test on variable size component
	in CodePeer mode, since representation clauses are partially ignored.
	* gcc-interface/Make-lang.in: Update dependencies.

From-SVN: r178373
2011-08-31 11:42:50 +02:00
Arnaud Charlet 56812278e8 [multiple changes]
2011-08-31  Jose Ruiz  <ruiz@adacore.com>

	* s-taprop-linux.adb (Set_Task_Affinity): Avoid the use of anonymous
	access types.
	* affinity.c (__gnat_set_affinity_mask): Declare index variable.

2011-08-31  Yannick Moy  <moy@adacore.com>

	* sem_ch8.adb (Analyze_Subprogram_Renaming): Refine expander test in
	full-expander test.
	Minor reformatting, renaming ALFA in Alfa (we dropped acronym)
	* einfo.adb (Primitive_Operations): Correctly return list of primitive
	operations in a case where it returned previously No_Elist.

From-SVN: r178358
2011-08-31 10:43:42 +02:00
Arnaud Charlet 14f0f659ac [multiple changes]
2011-08-29  Johannes Kanig  <kanig@adacore.com>

	* debug.adb: Add comments.

2011-08-29  Hristian Kirtchev  <kirtchev@adacore.com>

	* impunit.adb, s-stposu.adb, s-stposu.ads, exp_ch4.adb,
	s-finmas.adb, s-finmas.ads: Redo previous change.

From-SVN: r178247
2011-08-29 16:29:25 +02:00
Arnaud Charlet 9b20e59bb3 [multiple changes]
2011-08-29  Yannick Moy  <moy@adacore.com>

	* sem_prag.adb (Check_Precondition_Postcondition): In formal
	verification mode, analyze pragma expression for correctness, for
	pre/post on library-level subprogram, as it is not expanded later.

2011-08-29  Yannick Moy  <moy@adacore.com>

	* exp_aggr.adb (Expand_Array_Aggregate): Do not expand array aggregates
	in formal verification.

2011-08-29  Thomas Quinot  <quinot@adacore.com>

	* sem_util.adb: Minor reformatting.
	* freeze.adb, sem_ch13.adb: Fix comment: Bit_Order is an attribute,
	there's no pragma.
	* par_sco.ads, par_sco.adb: Update comments.

2011-08-29  Yannick Moy  <moy@adacore.com>

	* einfo.adb, einfo.ads: Remove flag Is_Postcondition_Proc and
	associated getter/setter.
	* sem_ch6.adb: Remove reference to Is_Postcondition_Proc.

2011-08-29  Vincent Celier  <celier@adacore.com>

	* prj-attr.adb: New Compiler attribute Dependency_Kind and Language_Kind
	* prj-conf.adb: Add_Default_GNAT_Naming_Scheme: Add a package Compiler
	with declarations for Language_Kind and Dependency_Kind for Ada.
	* prj-nmsc.adb (Check_Unit_Name): New name of procedure Check_Ada_Name
	(Process_Compiler): Take into account the new attributes Dependency_Kind
	and Language_Kind.
	(Check_Configuration): Check if language kind is unit based, not if the
	language name is Ada.
	(Process_Exceptions_Unit_Based): Ditto
	(Add_Language): Remove default additions of language and dependency kind
	* prj.ads: Minor comment change
	* snames.ads-tmpl: New standard names Dependency_Kind and Language_Kind

2011-08-29  Johannes Kanig  <kanig@adacore.com>

	* debug.adb: Update comments.

From-SVN: r178156
2011-08-29 10:21:24 +02:00
Arnaud Charlet 00332244ee [multiple changes]
2011-08-05  Arnaud Charlet  <charlet@adacore.com>

	* make.adb (Linking_Phase): No longer need to set source search path
	before calling gnatlink in CodePeer mode.
	* gnatlink.adb (Gnatlink): No longer pass -gnat83/95/05/12 switch to
	gcc in CodePeer mode, since the binder generated file no longer has a
	'with Main'.
	* switch.ads, switch.adb (Is_Language_Switch): Removed.
	* switch-c.adb: Update comment.

2011-08-05  Thomas Quinot  <quinot@adacore.com>

	* exp_strm.adb, bindgen.adb, s-ficobl.ads: Minor reformatting.

2011-08-05  Nicolas Roche  <roche@adacore.com>

	* gnat_ugn.texi: Fix minor syntax error issue.

2011-08-05  Vincent Celier  <celier@adacore.com>

	* gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
	delete or close the file when the call to gnatmake returns a non
	successful return code.

2011-08-05  Ed Schonberg  <schonberg@adacore.com>

	* exp_ch4.adb (Expand_N_Type_Conversion): When expanding a predicate
	check, indicate that the copy of the original node does not come from
	source, to prevent an infinite recursion of the expansion.

2011-08-05  Johannes Kanig  <kanig@adacore.com>

	* debug.adb: document switch -gnatd.G for gnat2why, which deactivates
	VC generation for subprogram bodies.

2011-08-05  Yannick Moy  <moy@adacore.com>

	* einfo.ads: Typo.
	* sem_ch3.adb (Signed_Integer_Type_Declaration): in ALFA mode, define
	the base type with the smallest allowed base type.

2011-08-05  Sergey Rybin  <rybin@adacore.com>

	* tree_gen.adb, tree_in.adb, aspects.adb: Fix tree read-write for
	aspects.

2011-08-05  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch12.ads: minor comment updates.

2011-08-05  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch12.adb (Analyze_Formal_Package_Declaration): in an
	instantiation and a formal package the compiler generates a package
	renaming declaration so that the generic name within the declaration
	is interpreted as a renaming of the instance. At the end of a formal
	package declaration, this renaming must become invisible.

From-SVN: r177437
2011-08-05 15:56:17 +02:00
Arnaud Charlet 406935b64c [multiple changes]
2011-08-05  Yannick Moy  <moy@adacore.com>

	* exp_ch7.adb (Establish_Transient_Scope): in formal verification mode,
	if the node to wrap is a pragma check, this node and enclosed
	expression are not expanded, so do not apply any transformations here.
	* exp_prag.adb (Expand_Pragma_Check): document the need to avoid
	introducing transient scopes.

2011-08-05  Jose Ruiz  <ruiz@adacore.com>

	* adaint.c (__gnat_set_writable, __gnat_set_readable,
	__gnat_set_executable, __gnat_set_non_writable, __gnat_set_non_readable,
	__gnat_copy_attribs): On VxWorks 6.x and later, the required chmod
	routine is available, so we use the default implementation of these
	functions.
	* s-os_lib.ads (Copy_File, Copy_Time_Stamps): Document that there is
	support for copying attributes on VxWorks 6.

2011-08-05  Yannick Moy  <moy@adacore.com>

	* debug.adb: Remove use of -gnatd.D.
	* gnat1drv.adb (Adjust_Global_Switches): adjust switches for ALFA mode
	* opt.ads: Simplify variables for ALFA mode, to keep one only
	* restrict.adb, sem_prag.adb: Adapt treatment done for CodePeer mode
	to ALFA mode.

2011-08-05  Vincent Celier  <celier@adacore.com>

	* prj-conf.adb (Do_Autoconf): Look also for --RTS in
	Builder'Default_Switches.

2011-08-05  Vincent Celier  <celier@adacore.com>

	* makeusg.adb: Add lines for --create-map-file switches.

2011-08-05  Ed Schonberg  <schonberg@adacore.com>

	* freeze.adb (Freeze_Entity): For a subprogram, if a type in the
	profile is incomplete and the full view is available, replace it with
	the full view.
	* sem_ch6.adb (Possible_Freeze): if a type in the profile is
	incomplete, freezing the subprogram is delayed until the full view is
	frozen.
	* sem_type.adb (Disambiguate): an ambiguity between a user-defined
	fixed-point multiplication operator and the predefined operator is
	resolved in favor of the user-defined one.

From-SVN: r177432
2011-08-05 15:32:13 +02:00
Arnaud Charlet 4fdebd93e0 [multiple changes]
2011-08-04  Arnaud Charlet  <charlet@adacore.com>

	* debug.adb: Update comment.

2011-08-04  Robert Dewar  <dewar@adacore.com>

	* par_sco.adb, exp_util.adb, make.adb, a-tags.adb, sem_prag.adb,
	sem_util.adb, sem_attr.adb, exp_ch4.adb, g-comlin.adb, g-comlin.ads,
	exp_ch6.adb: Minor reformatting.

2011-08-04  Gary Dismukes  <dismukes@adacore.com>

	* gnat_ugn.texi: Add sentence about the case of compile-time-detected
	checks for -gnateE.

2011-08-04  Ed Schonberg  <schonberg@adacore.com>

	* gnat_rm.texi: update Ravenscar desription to reflect Ada2012 RM.

2011-08-04  Thomas Quinot  <quinot@adacore.com>

	* sinfo.ads: Minor reformatting.

2011-08-04  Emmanuel Briot  <briot@adacore.com>

	* makeutl.adb, makeutl.ads, prj-nmsc.adb (Complete_Mains): report error
	even if there is no location.

From-SVN: r177351
2011-08-04 11:57:02 +02:00