Commit Graph

82 Commits

Author SHA1 Message Date
Arnaud Charlet
ee2e3f6bb4 [multiple changes]
2011-08-29  Robert Dewar  <dewar@adacore.com>

	* sem_ch7.adb, make.adb, sem_res.adb, exp_intr.adb,
	exp_dist.adb: Minor code reorganization.
	Minor reformatting.

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

	* sem_cat.adb (Validate_RACW_Primitive): The return type of an RACW
	primitive operation must support external streaming if it is not a
	controlling access result.

From-SVN: r178199
2011-08-29 12:46:57 +02:00
Arnaud Charlet
646e282313 [multiple changes]
2011-08-29  Thomas Quinot  <quinot@adacore.com>

	* sinfo.ads, sem_ch7.adb: Minor reformatting.

2011-08-29  Bob Duff  <duff@adacore.com>

	* sem_ch4.adb (Analyze_Allocator): Check No_Nested_Finalization
	restriction on allocators, as required by AI05-0013-1.
	* restrict.ads: Minor comment fix.

From-SVN: r178198
2011-08-29 12:44:14 +02:00
Arnaud Charlet
d3cb4cc0df [multiple changes]
2011-08-29  Matthew Heaney  <heaney@adacore.com>

	* a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Splice_Subtree): Only check
	for sibling when common parent.

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

	* get_scos.adb: Literals of Pragma_Id are pragma names prefixed with
	"pragma_".

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

	* sem_ch6.adb (Analyze_Subprogram_Body_Helper): Enable freeze actions
	for the return type when in ASIS mode.

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

	* make.adb (Gnatmake): Get the default search dirs, then the target
	parameters after getting the Builder switches, as the Builder switches
	may include --RTS= and that could change the default search dirs.

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

	* exp_ch7.adb (Make_Adjust_Call): Rewrite to mimic the structure of
	Make_Final_Call. Move the processing for class-wide types before the
	processing for derivations from [Limited_]Controlled.
	(Make_Final_Call): Move the processing for class-wide types before the
	processing for derivations from [Limited_]Controlled.
	* s-stposu.adb (Allocate_Any_Controlled): Correct the membership check.
	Add code to account for alignments larger than the list header. Add a
	comment illustrating the structure of the allocated object + padding +
	header.
	(Deallocate_Any_Controlled): Add code to account for alignments larger
	than the list header.

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

	* sinfo.ads, sinfo.adb: New node kind
	N_Formal_Incomplete_Type_Definition, related flags.
	par-ch12.adb (P_Formal_Type_Declaration, G_Formal_Type_Definition):
	Parse formal incomplete types.
	* sem.adb (Analyze): Formal_Incomplete_Type_Definitions are handled in
	sem_ch12.
	* sem_ch7.adb (Analyze_Package_Specification, Unit_Requires_Body):
	Formal incomplete types do not need completion.
	* sem_ch12.adb (Analyze_Formal_Incomplete_Type,
	Validate_Incomplete_Type_Instance): New procedures to handle formal
	incomplete types.
	* freeze.adb (Freeze_Entity): Do not freeze the subtype of an actual
	that corresponds to a formal incomplete type.
	* sprint.adb: Handle formal incomplete type declarations.
	* exp_util.adb (Insert_Actions): An incomplete_type_definition is not
	an insertion point.

From-SVN: r178184
2011-08-29 12:02:08 +02:00
Arnaud Charlet
686d09844f [multiple changes]
2011-08-03  Robert Dewar  <dewar@adacore.com>

	* gnatcmd.adb, prj-proc.adb, mlib-prj.adb, prj.adb, makeutl.ads,
	prj-util.adb, prj-util.ads, prj-conf.adb, prj-env.adb: Minor
	reformatting.

2011-08-03  Javier Miranda  <miranda@adacore.com>

	* exp_util.adb (Is_VM_By_Copy_Actual): Include N_Slide nodes as actuals
	that must be passed by copy in VM targets.

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

	* prj.ads, prj-nmsc.adb (Files_Htable): removed this htable, which
	duplicates a similar htable now in the project tree.

2011-08-03  Claire Dross  <dross@adacore.com>

	* a-cfdlli.adb, a-cfhama.adb, a-cfhase.adb, a-cforma.adb, a-cforse.adb,
	a-cofove.adb ("=", Length, Is_Empty, Clear, Assign, Copy, Element,
	Replace_Element, Query_Element, Update_Element, Move, Insert, Prepend,
	Append, Delete, Delete_First, Delete_Last, Reverse_Element, Swap,
	Splice, First, First_Element, Last, Last_Element, Next, Previous, Find,
	Reverse_Find, Contains, Has_Element, Iterate, Reverse_Iterate, Capacity,
	Reserve_Length, Length, Strict_Equal, Left, Right): Data-structure
	update.

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

	* s-taprop-posix.adb, s-taprop-linux.adb, s-taprop-tru64.adb
	(ATCB_Key): Removed, not always used.
	* s-tpopsp-posix.adb, s-tpopsp-posix-foreign.adb (ATCB_Key): Moved from
	s-taprop-posix.adb.
	* s-tpopsp-tls.adb: New file.
	* gcc-interface/Makefile.in: Use TLS implementation of s-tpopsp.adb on
	x86/x64/ia64/powerpc/sparc Linux.

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

	* system-aix.ads, system-aix64.ads: Set ZCX_By_Default to True.
	* gcc-interface/Makefile.in: Switch to ZCX by default on AIX ports.

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

	* rtsfind.ads, exp_dist.adb, exp_dist.ads
	(Build_From_Any_Call, Build_To_Any_Call, Build_TypeCode_Call):
	Fix type selection for mapping integer types to PolyORB types.

2011-08-03  Bob Duff  <duff@adacore.com>

	* sem_ch7.adb: Minor comment clarification.

2011-08-03  Bob Duff  <duff@adacore.com>

	* sem_ch13.adb (Analyze_Enumeration_Representation_Clause): If we get
	an error analyzing a choice, skip further processing. Further
	processing could cause a crash or cascade errors.

From-SVN: r177262
2011-08-03 12:38:26 +02:00
Arnaud Charlet
c4d67e2d73 [multiple changes]
2011-08-03  Yannick Moy  <moy@adacore.com>

	* sem_ch6.adb (New_Overloaded_Entity): only issue error for SPARK
	restriction on overloaded entity if the entity is not an operator.

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

	* sem_ch7.adb, sem_res.adb, sem_attr.adb, restrict.adb,
	restrict.ads: Rename remaining Check_Formal_Restriction* into
	Check_SPARK_Restriction*.

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

	* prj-proc.adb, prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb,
	prj-nmsc.ads, prj-err.adb (Project_Data): now discriminated on its
	qualifier.
	(Project_Empty): removed
	(Empty_Project): new parameter Qualifier
	This is used to have fields specific to aggregate projects, cleaner
	New field to store the list of aggregated projects.
	(Check_Aggregate_Project): removed
	(Process_Aggregated_Projects, Free): new subprograms.

From-SVN: r177243
2011-08-03 11:17:28 +02:00
Yannick Moy
975c689678 einfo.adb, einfo.ads (Body_Is_In_ALFA, [...]): get/set for new flag denoting which subprogram bodies are in ALFA
2011-08-02  Yannick Moy  <moy@adacore.com>

	* einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
	for new flag denoting which subprogram bodies are in ALFA
	* restrict.adb, sem_ch7.adb: Update comment
	* sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
	sem_ch9.adb, sem_res.adb: Add calls to
	Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
	* sem_ch6.adb (Analyze_Function_Return): add calls to
	Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
	middle of the body, and extended return.
	(Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
	False when missing return.
	(Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
	to True for subprograms whose spec is in ALFA. Remove later on the flag
	on the entity used for a subprogram body when there exists a separate
	declaration.
	* sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
	if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
	False, otherwise do nothing.

From-SVN: r177177
2011-08-02 17:15:07 +02:00
Arnaud Charlet
4637729f3e [multiple changes]
2011-08-02  Robert Dewar  <dewar@adacore.com>

	* exp_ch4.adb: Minor reformatting.

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

	* sem_ch5.adb (Analyze_Loop_Statement):  If the iteration scheme is an
	Ada2012 iterator, the loop will be rewritten during expansion into a
	while loop with a cursor and an element declaration. Do not analyze the
	body in this case, because if the container is for indefinite types the
	actual subtype of the elements will only be determined when the cursor
	declaration is analyzed.

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

	* sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
	size/alignment related attributes in CodePeer_Mode.

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

	* sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
	Prepend_Element, since this can result in the operation getting the
	wrong slot in the full type's dispatch table if the full type has
	inherited operations. The incomplete type's operation will get added
	to the proper position in the full type's primitives
	list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
	(Process_Incomplete_Dependents): Add Is_Primitive test when checking for
	dispatching operations, since there are cases where nonprimitive
	subprograms can get added to the list of incomplete dependents (such
	as subprograms in nested packages).
	* sem_ch6.adb (Process_Formals): First, remove test for being in a
	private part when determining whether to add a primitive with a
	parameter of a tagged incomplete type to the Private_Dependents list.
	Such primitives can also occur in the visible part, and should not have
	been excluded from being private dependents.
	* sem_ch7.adb (Uninstall_Declarations): When checking the rule of
	RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
	list of a Taft-amendment incomplete type is a primitive before issuing
	an error that the full type must appear in the same unit. There are
	cases where nonprimitives can be in the list (such as subprograms in
	nested packages).
	* sem_disp.adb (Derives_From): Use correct condition for checking that
	a formal's type is derived from the type of the corresponding formal in
	the parent subprogram (the condition was completely wrong). Add
	checking that was missing for controlling result types being derived
	from the result type of the parent operation.

From-SVN: r177156
2011-08-02 15:51:43 +02:00
Arnaud Charlet
6320f5e18e [multiple changes]
2011-08-02  Robert Dewar  <dewar@adacore.com>

	* sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
	sem_res.adb, sem_ch6.adb: Minor reformatting.

2011-08-02  Jerome Guitton  <guitton@adacore.com>

	* a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.

From-SVN: r177127
2011-08-02 12:27:16 +02:00
Yannick Moy
e24329cdf0 par-ch6.adb: Correct obsolete name in comments
2011-08-02  Yannick Moy  <moy@adacore.com>

	* par-ch6.adb: Correct obsolete name in comments
	* restrict.adb, restrict.ads (Check_Formal_Restriction): new function
	which takes two message arguments (existing function takes one), with
	second message used for continuation.
	* sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
	block statements that originate from a source block statement, not
	generated block statements
	* sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
	symmetry with procedure case
	* sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
	function to issue an error in formal mode if a package specification
	contains more than one tagged type or type extension.
	* sem_res.adb (Resolve_Actuals): in formal mode, check that actual
	parameters matching formals of tagged types are objects (or ancestor
	type conversions of objects), not general expressions. Issue an error
	on view conversions that are not involving ancestor conversion of an
	extended type.
	(Resolve_Type_Conversion): in formal mode, issue an error on the
	operand of an ancestor type conversion which is not an object
	* sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
	procedure so that it works also for actuals of function calls
	(Is_Actual_Tagged_Parameter): new function which determines if its
	argument is an actual parameter of a formal of tagged type in a
	subprogram call
	(Is_SPARK_Object_Reference): new function which determines if the tree
	referenced by its argument represents an object in SPARK

From-SVN: r177125
2011-08-02 12:21:47 +02:00
Robert Dewar
eaba57fb0a sem_ch12.adb, [...]: New calling sequence for Analyze_Aspect_Specifications
2011-08-02  Robert Dewar  <dewar@adacore.com>

	* sem_ch12.adb, sem_ch11.adb: New calling sequence for
	Analyze_Aspect_Specifications
	* sem_ch13.adb
	(Analyze_Aspect_Specifications): New handling for boolean aspects
	* sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
	* sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
	sequence for Analyze_Aspect_Specifications
	* sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
	* sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used

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

	* freeze.adb (Freeze_Entity): Remove handling of delayed boolean
	aspects, since these no longer exist.

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

	* par-ch13.adb (Aspect_Specifications_Present): Always return false on
	semicolon, do not try to see if there are aspects following it.
	* par-ch3.adb (P_Declarative_Items): Better message for unexpected
	aspect spec.

From-SVN: r177095
2011-08-02 10:58:37 +02:00
Arnaud Charlet
38171f43f1 [multiple changes]
2011-08-01  Javier Miranda  <miranda@adacore.com>

	* sem_ch7.adb (Uninstall_Declarations): Remove useless code.
	* einfo.ads (Access_Disp_Table): Fix documentation.
	(Dispatch_Table_Wrappers): Fix documentation.
	* einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
	Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
	to enforce the documentation of this attribute.
	(Set_Is_Interface): Cleanup the assertion.
	* exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
	the Underlying_Type entity before reading attribute Access_Disp_Table.
	* exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
	Locate the Underlying_Type before reading attribute Access_Disp_Table.
	* exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
	the Underlying_Type entity before reading attribute Access_Disp_Table.
	* exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
	Locate the Underlying_Type entity before reading attribute
	Access_Disp_Table.

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

	* s-poosiz.ads: Additional overriding indicators.

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

	* sem_ch5.adb (Analyze_Exit_Statement): add return after error in
	formal mode.
	(Analyze_Iteration_Scheme): issue error in formal mode when loop
	parameter specification does not include a subtype mark.
	* sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
	formal mode on abstract subprogram.
	(Analyze_Subprogram_Specification): issue error in formal mode on
	user-defined operator.
	(Process_Formals): issue error in formal mode on access parameter and
	default expression.
	* sem_ch9.adb (Analyze_Abort_Statement,
	Analyze_Accept_Statement, Analyze_Asynchronous_Select,
	Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
	Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
	Analyze_Requeue, Analyze_Selective_Accept,
	Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
	* sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
	issue error in formal mode on user-defined raise statement.

From-SVN: r177047
2011-08-01 17:17:35 +02:00
Arnaud Charlet
1c54829e23 [multiple changes]
2011-08-01  Robert Dewar  <dewar@adacore.com>

	* par-endh.adb: Minor reformatting.

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

	* aspects.ads, aspects.adb: Add aspects for library unit pragmas
	(Pre_Post_Aspects): New subtype.
	* par-ch12.adb (P_Generic): New syntax for aspects in packages
	* par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
	* par-ch7.adb (P_Package): Remove Decl parameter
	(P_Package): Handle new syntax for aspects (before IS)
	* par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
	new aspect syntax
	(P_Task_Definition): Remove Decl parameter, handle new aspect syntax
	* par.adb (P_Aspect_Specifications): Add Semicolon parameter
	(P_Package): Remove Decl parameter
	* sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
	aspects
	* sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
	specs
	* sem_util.ads, sem_util.adb (Static_Boolean): New function
	* sinfo.ads: Document new syntax for aspects in packages etc.
	* sprint.adb: Handle new syntax of aspects before IS in package

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

	* atree.ads: Minor reformatting.
	* sem_prag.adb: Minor reformatting.

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

	* exp_util.adb (Insert_Actions): Fix error in handling Actions for
	case expr alternative.

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

	* sem_ch12.adb: Fix typo.

From-SVN: r177027
2011-08-01 14:50:07 +02:00
Ralf Wildenhues
308e6f3a18 Fix typos in gcc/ada.
gcc/ada/:
	* projects.texi: Fix typos.
	* gnat_rm.texi: Likewise.
	* gnat_ugn.texi: Likewise.
	* sem_util.adb: Fix typo in variable, typos in comments.
	* a-btgbso.adb: Fix typos in comments.
	* a-cbdlli.adb, a-cbhase.ads, a-cdlili.adb, a-cobove.adb,
	a-coinve.adb, a-convec.adb, a-direct.ads, a-strunb-shared.adb,
	a-strunb-shared.ads, a-stuten.ads, a-stwiun-shared.adb,
	a-stwiun-shared.ads, a-stzunb-shared.adb, a-stzunb-shared.ads,
	a-suenco.adb, a-suenst.adb, a-suewst.adb, a-suezst.adb, ali.ads,
	aspects.ads, atree.ads, binde.adb, bindgen.adb, checks.adb,
	checks.ads, einfo.ads, err_vars.ads, errout.adb, errout.ads,
	exp_aggr.adb, exp_attr.adb, exp_cg.adb, exp_ch3.adb,
	exp_ch4.adb, exp_ch5.adb, exp_ch6.adb, exp_ch7.adb,
	exp_dbug.ads, exp_disp.adb, exp_fixd.ads, freeze.adb,
	g-altive.ads, g-comlin.ads, g-excact.ads, g-mbdira.adb,
	g-sechas.ads, g-sehash.ads, g-sha1.ads, g-sha224.ads,
	g-sha256.ads, g-sha384.ads, g-sha512.ads, g-shsh32.ads,
	g-shsh64.ads, g-socket.adb, g-socket.ads, g-sothco.ads,
	gcc-interface/decl.c, gcc-interface/trans.c,
	gcc-interface/utils2.c, gnat1drv.adb, init.c, inline.adb,
	link.c, locales.c, make.adb, mingw32.h, namet.ads, osint.adb,
	par-ch12.adb, par-ch13.adb, par-ch3.adb, par-ch4.adb,
	par-prag.adb, par.adb, par_sco.adb, prepcomp.adb,
	prj-conf.ads, prj-dect.adb, prj-env.adb, prj-env.ads,
	prj-nmsc.adb, prj-tree.ads, prj-util.ads, prj.adb, prj.ads,
	s-auxdec-vms-alpha.adb, s-auxdec-vms_64.ads, s-oscons-tmplt.c,
	s-osinte-vxworks.ads, s-osprim-mingw.adb, s-regexp.adb,
	s-stusta.adb, s-taprop-mingw.adb, s-taprop-solaris.adb,
	scn.adb, scos.ads, sem.adb, sem_aggr.adb, sem_attr.adb,
	sem_aux.adb, sem_aux.ads, sem_ch12.adb, sem_ch12.ads,
	sem_ch13.adb, sem_ch13.ads, sem_ch3.adb, sem_ch4.adb,
	sem_ch6.adb, sem_ch7.adb, sem_ch8.adb, sem_disp.adb,
	sem_disp.ads, sem_eval.adb, sem_intr.adb, sem_prag.adb,
	sem_res.adb, sem_scil.adb, sem_util.ads, sem_warn.adb,
	sem_warn.ads, sinfo.ads, socket.c, styleg.adb, switch.ads,
	sysdep.c, tb-alvxw.c, xoscons.adb: Likewise.

From-SVN: r168082
2010-12-20 07:26:57 +00:00
Robert Dewar
f2264ac2cd sem_ch13.adb (Build_Invariant_Procedure): New calling sequence.
2010-10-26  Robert Dewar  <dewar@adacore.com>

	* sem_ch13.adb (Build_Invariant_Procedure): New calling sequence.
	(Build_Invariant_Procedure): Properly handle analysis of invariant
	expression with proper end-of-visible-decls visibility.
	* sem_ch13.ads (Build_Invariant_Procedure): Changed calling sequence.
	* sem_ch3.adb (Process_Full_View): Don't build invariant procedure
	(too late).
	(Analyze_Private_Extension_Declaration): Propagate invariant flags.
	* sem_ch7.adb (Analyze_Package_Specification): Build invariant
	procedures.

From-SVN: r165960
2010-10-26 15:12:34 +02:00
Arnaud Charlet
ce09f8b3f2 [multiple changes]
2010-10-26  Robert Dewar  <dewar@adacore.com>

	* opt.ads (Treat_Categorization_Errors_As_Warnings): New flag
	* sem_cat.adb (Check_Categorization_Dependencies):
	Use Check_Categorization_Dependencies
	* switch-c.adb: GNAT Mode sets Treat_Categorization_Errors_As_Warnings
	-gnateP sets Treat_Categorization_Errors_As_Warnings
	* usage.adb: Add line for -gnateP switch

2010-10-26  Javier Miranda  <miranda@adacore.com>

	* sem_ch3.adb (Add_Internal_Interface_Entities): Handle primitives
	inherited from the parent that cover interface primitives.
	(Derive_Progenitor_Subprograms): Handle primitives inherited from
	the parent that cover interface primitives.
	* sem_disp.adb (Find_Primitive_Covering_Interface): When searching in
	the list of primitives of the type extend the test to include inherited
	private primitives.
	* sem_ch6.ads (Is_Interface_Conformant): Add missing documentation.
	* sem_ch7.adb (Declare_Inherited_Private_Subprograms): Add missing
	barrier to the loop searching for explicit overriding primitives.
	* sem_ch4.adb (Analyze_Indexed_Component_Form): Add missing barrier
	before accessing attribute Entity.

2010-10-26  Bob Duff  <duff@adacore.com>

	* make.adb: Call Namet.Finalize, so we can get statistics.

From-SVN: r165952
2010-10-26 14:45:45 +02:00
Arnaud Charlet
d347f5722f [multiple changes]
2010-10-26  Robert Dewar  <dewar@adacore.com>

	* einfo.ads, einfo.adb (Is_Base_Type): New function, use it where
	appropriate.
	* exp_ch6.adb, exp_dbug.adb, exp_disp.adb, freeze.adb, lib-xref.adb,
	sem_aux.adb, sem_ch3.adb, sem_ch7.adb, sem_ch8.adb (Is_Base_Type): Use
	this new abstraction where appropriate.

2010-10-26  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch12.adb: Code clean up.

2010-10-26  Paul Hilfinger  <hilfinger@adacore.com>

	* exp_dbug.ads: Document effect of 'pragma Unchecked_Union' on
	debugging data.

2010-10-26  Ed Schonberg  <schonberg@adacore.com>

	* sem_util.adb (Note_Possible_Modification): If the target of an
	assignment is the bound variable in an iterator, the domain of
	iteration, i.e. array or container, is modified as well.

2010-10-26  Bob Duff  <duff@adacore.com>

	* Make-generated.in: Make the relevant make targets depend on
	ceinfo.adb and csinfo.adb.
	* csinfo.adb, ceinfo.adb: Make sure it raises an exception on failure,
	so when called from xeinfo, the failure will be noticed.
	* sinfo.ads: Update comments to reflect the fact that xsinfo runs csinfo
	* xsinfo.adb, xeinfo.adb: Run ceinfo to check for errors. Close files.

2010-10-26  Ed Schonberg  <schonberg@adacore.com>

	* exp_ch4.adb: Set properly parent field of operands of concatenation.

2010-10-26  Ed Schonberg  <schonberg@adacore.com>

	* sem_res.adb (Check_Infinite_Recursion): A recursive call within a
	conditional expression or a case expression should not generate an
	infinite recursion warning.

From-SVN: r165946
2010-10-26 14:19:56 +02:00
Arnaud Charlet
038140ede0 [multiple changes]
2010-10-26  Javier Miranda  <miranda@adacore.com>

	* einfo.ads, einfo.adb (Is_Overriding_Operation): Removed.
	(Set_Is_Overriding_Operation): Removed.
	* sem_ch3.adb (Check_Abstract_Overriding): Remove redundant call to
	Is_Overriding_Operation.
	* exp_ch7.adb (Check_Visibly_Controlled): Remove redundant call to
	Is_Overriding_Operation.
	* sem_ch7.adb (Declare_Inherited_Private_Subprograms): Remove redundant
	call to Set_Is_Overriding_Operation.
	* sem_util.adb (Collect_Primitive_Operations): Replace test on
	Is_Overriding_Operation by test on the presence of attribute
	Overridden_Operation.
	(Original_Corresponding_Operation): Remove redundant call to attribute
	Is_Overriding_Operation.
	* sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): Remove
	redundant call to Is_Overriding_Operation.
	(Verify_Overriding_Indicator): Replace several occurrences of test on
	Is_Overriding_Operation by test on the presence of attribute
	Overridden_Operation.
	(Check_Convention): Replace test on Is_Overriding_Operation by test on
	the presence of Overridden_Operation.
	(Check_Overriding_Indicator): Add missing decoration of attribute
	Overridden_Operation. Minor code cleanup.
	(New_Overloaded_Entity): Replace occurrence of test on
	Is_Overriding_Operation by test on the presence of attribute
	Overridden_Operation. Remove redundant setting of attribute
	Is_Overriding_Operation plus minor code reorganization.
	Add missing decoration of attribute Overridden_Operation.
	* sem_elim.adb (Set_Eliminated): Replace test on
	Is_Overriding_Operation by test on the presence of Overridden_Operation.
	* sem_ch8.adb (Analyze_Subprogram_Renaming): Replace test on
	Is_Overriding_Operation by test on the presence of
	Overridden_Operation. Remove a redundant test on attribute
	Is_Overriding_Operation. 
	* lib-xref.adb (Generate_Reference): Replace test on
	Is_Overriding_Operation by test on the presence of Overridden_Operation.
	(Output_References): Replace test on Is_Overriding_Operation by test on
	the presence of Overridden_Operation.
	* sem_disp.adb (Override_Dispatching_Operation): Replace test on
	Is_Overriding_Operation by test on the presence of Overridden_Operation.
	Add missing decoration of attribute Overridden_Operation.

2010-10-26  Robert Dewar  <dewar@adacore.com>

	* sem_ch13.adb (Adjust_Record_For_Reverse_Bit_Order): Properly check
	RM 13.4.1(10).

2010-10-26  Bob Duff  <duff@adacore.com>

	* sem_res.adb (Resolve_Actuals): In case of certain
	internally-generated type conversions (created by OK_Convert_To, so the
	Conversion_OK flag is set), avoid fetching the component type when it's
	not really an array type, but a private type completed by an array type.

From-SVN: r165945
2010-10-26 13:02:31 +02:00
Arnaud Charlet
e606088aa9 [multiple changes]
2010-10-19  Geert Bosch  <bosch@adacore.com>

	* ttypef.ads: Change VAXDF_Last to be -VAXDF_First, as type is
	symmetric.

2010-10-19  Robert Dewar  <dewar@adacore.com>

	* atree.h (Field29): Fix incorrect definition.
	* einfo.adb (Invariant_Procedure): New attribute
	(Has_Invariants): New flag
	(Has_Inheritable_Invariants): New flag
	(OK_To_Reference): New flag
	Minor code reorganization (use Next_Rep_Item function)
	* einfo.ads (Invariant_Procedure): New attribute
	(Has_Invariants): New flag
	(Has_Inheritable_Invariants): New flag
	(OK_To_Reference): New flag
	* exp_ch3.adb (Expand_N_Object_Declaration): Add check for invariant
	* exp_ch4.adb (Expand_N_Type_Conversion): Check invariant on type
	conversion.  Minor reformatting.
	* exp_util.ads, exp_util.adb (Make_Invariant_Call): New procedure.
	* opt.ads (List_Inherited_Aspects): New name for List_Inherited_Pre_Post
	* par-prag.adb: Add dummy entry for pragma Invariant.
	* sem_ch13.adb (Build_Invariant_Procedure): New procedure
	(Analyze_Aspect_Specification): Add support for Invariant aspect
	* sem_ch13.ads (Build_Invariant_Procedure): New procedure
	* sem_ch3.adb (Build_Derived_Type): Propagate invariant information
	(Process_Full_View): Deal with invariants, building invariant procedure
	Minor reformatting
	* sem_ch6.adb (Process_PPCs): Add processing of invariants
	* sem_ch7.adb (Analyze_Package_Specification): Build invariant
	procedures.
	* sem_prag.adb: Implement pragma Invariant.
	* sem_res.adb (Resolve_Entity_Name): Allow type reference if
	OK_To_Reference set.
	* sem_warn.adb (List_Inherited_Aspects): New name for
	List_Inherited_Pre_Post.
	* snames.ads-tmpl: Add entries for pragma Invariant.
	* treepr.adb (Print_Entity_Information): Add handling of Field29.
	* usage.adb: Warning .l/.L applies to invariant as well as pre/post.

From-SVN: r165694
2010-10-19 12:37:41 +02:00
Arnaud Charlet
6191e21252 [multiple changes]
2010-10-18  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch13.adb (Analyze_Aspect_Specifications): If subprogram is at the
	library level, the pre/postconditions must be treated as global
	declarations, i.e. placed on the Aux_Decl nodes of the compilation unit.
	* freeze.adb (Freeze_Expression): If the expression is at library level
	there is no enclosing record to check.

2010-10-18  Javier Miranda  <miranda@adacore.com>

	* sem_ch3.ads (Find_Type_Name): Add documentation.
	* sem_ch3.adb (Analyze_Full_Type_Declaration): Code cleanup because the
	propagation of the class-wide entity is now done by routine
	Find_Type_Name to factorize this code.
	(Analyze_Private_Extension_Declaration): Handle private type that
	completes an incomplete type.
	(Tag_Mismatch): Add error message for tag mismatch in a private type
	declaration that completes an incomplete type.
	(Find_Type_Name): Handle completion of incomplete type by means of
	a private declaration. Generate an error if a tagged incomplete type
	is completed by an untagged private type.
	* sem_ch7.adb (New_Private_Type): Handle private type that completes an
	incomplete type.
	* einfo.ads (Full_View): Add documentation.

2010-10-18  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch12.adb (Analyze_Formal_Package_Declaration): If the package is
	a renaming, generate a reference for it before analyzing the renamed
	entity, to prevent spurious warnings.

From-SVN: r165636
2010-10-18 15:58:25 +02:00
Javier Miranda
ef2a63ba18 einfo.ads, einfo.adb (Primitive_Operations): New synthesized attribute.
2010-10-18  Javier Miranda  <miranda@adacore.com>

	* einfo.ads, einfo.adb (Primitive_Operations): New synthesized
	attribute.
	(Direct_Primitive_Operations): Renaming of old Primitive_Operations.
	(Set_Direct_Primitive_Operations): Renaming of old
	Set_Primitive_Operations. Update documentation
	* sem_ch3.adb, exp_util.adb, sem_ch7.adb, sem_ch8.adb, exp_ch3.adb:
	Replace occurrences of Set_Primitive_Operations by
	Set_Direct_Primitive_Operations.
	* sem_cat.adb (Validate_RACW_Primitives): No action needed for tagged
	concurrent types.
	* exp_dist.adb (Add_RACW_Primitive_Declarations_And_Bodies): Do not
	process primitives of concurrent types.
	* lib-xref.adb (Generate_Prim_Op_References): Minor code cleanup.

From-SVN: r165618
2010-10-18 11:59:45 +02:00
Arnaud Charlet
0877856b4e [multiple changes]
2010-10-18  Arnaud Charlet  <charlet@adacore.com>

	* g-comlin.adb (Get_Switches): Prevent dereferencing null Config.

2010-10-18  Robert Dewar  <dewar@adacore.com>

	* aspects.ads, aspects.adb: Add entries for aspects
	Read/Write/Input/Output.
	* sem_ch13.adb (Analyze_Aspect_Specifications): Add processing for
	handling aspects Read/Write/Input/Output.

2010-10-18  Robert Dewar  <dewar@adacore.com>

	* sem_util.adb (Note_Possible_Modification): Do not give warning for
	use of pragma Unmodified unless we are sure this is a modification.

2010-10-18  Tristan Gingold  <gingold@adacore.com>

	* sysdep.c: Add __gnat_get_stack_bounds.
	* s-taprop-mingw.adb Call __gnat_get_stack_bounds to set Pri_Stack_Info.

2010-10-18  Robert Dewar  <dewar@adacore.com>

	* a-assert.ads: Fix bad name in header.
	* sem_ch4.adb, sem_ch6.adb, sem_ch7.adb, sem_ch10.adb: Minor
	reformatting.
	* exp_aggr.adb: Fix typo in comment.

From-SVN: r165615
2010-10-18 11:53:00 +02:00
Arnaud Charlet
1fb0006411 [multiple changes]
2010-10-18  Robert Dewar  <dewar@adacore.com>

	* g-trasym-vms-ia64.adb: Minor reformatting.

2010-10-18  Thomas Quinot  <quinot@adacore.com>

	* sem_type.adb (Covers): If either argument is Standard_Void_Type and
	the other isn't, return False early.

2010-10-18  Ed Falis  <falis@adacore.com>

	* s-vxwext-rtp.ads, s-vxext-rtp.adb: Adapt for missing APIs for RTPs in
	VxWorks Cert.

2010-10-18  Robert Dewar  <dewar@adacore.com>

	* sem_disp.ads: Minor comment update.

2010-10-18  Robert Dewar  <dewar@adacore.com>

	* einfo.ads, einfo.adb (Spec_PPC_List): Is now present in Entries
	* sem_ch3.adb (Analyze_Declarations): Add processing for delaying
	visibility analysis of precondition and postcondition pragmas (and
	Pre/Post aspects).
	* sem_ch6.adb (Process_PPCs): Add handling of inherited Pre'Class
	aspects.
	* sem_ch7.adb (Analyze_Package_Specification): Remove special handling
	of pre/post conditions (no longer needed).
	* sem_disp.adb (Inherit_Subprograms): Deal with interface case.
	* sem_prag.adb (Analyze_PPC_In_Decl_Part): Remove analysis of message
	argument, since this is now done in the main processing for
	pre/postcondition pragmas when they are first seen.
	(Chain_PPC): Pre'Class and Post'Class now handled properly
	(Chain_PPC): Handle Pre/Post aspects for entries
	(Check_Precondition_Postcondition): Handle entry declaration case
	(Check_Precondition_Postcondition): Handle delay of visibility analysis
	(Check_Precondition_Postcondition): Preanalyze message argument if
	present.

From-SVN: r165612
2010-10-18 11:37:14 +02:00
Arnaud Charlet
c159409f3a [multiple changes]
2010-10-11  Robert Dewar  <dewar@adacore.com>

	* g-htable.ads (Get_First): New procedural version for Simple_HTable
	(Get_Next): New procedural version for Simple_HTable
	* s-htable.adb (Get_First): New procedural version for Simple_HTable
	(Get_Next): New procedural version for Simple_HTable
	* s-htable.ads (Get_First): New procedural version for Simple_HTable
	(Get_Next): New procedural version for Simple_HTable

2010-10-11  Ed Schonberg  <schonberg@adacore.com>

	* sem_aggr.adb (Propagate_Discriminants): To gather the components of a
	variant part, use the association list of the subaggregate, which
	already includes the values of the needed discriminants.

2010-10-11  Robert Dewar  <dewar@adacore.com>

	* aspects.ads, aspects.adb: Changes to accomodate aspect delay
	(Tree_Write): New procedure.
	* atree.ads, atree.adb: Flag3 is now Has_Aspects and applies to all
	nodes.
	* atree.h: Flag3 is now Has_Aspects and applies to all nodes
	* debug.adb: Add debug flag gnatd.A
	* einfo.adb (Has_Delayed_Aspects): New flag
	(Get_Rep_Item_For_Entity): New function
	* einfo.ads (Has_Delayed_Aspects): New flag
	(Get_Rep_Item_For_Entity): New function
	* exp_ch13.adb (Expand_N_Freeze_Entity): Insert delayed aspects into
	tree.
	* exp_ch3.adb, exp_ch6.adb, exp_ch9.adb, exp_disp.adb: New calling
	sequence for Freeze_Entity.
	* freeze.ads, freeze.adb (Freeze_Entity): Takes node rather than source
	ptr. All calls are changed to this new interface.
	(Freeze_And_Append): Same change
	(Freeze_Entity): Evaluate deferred aspects
	* sem_attr.adb: New calling sequence for Freeze_Entity
	(Eval_Attribute): Don't try to evaluate attributes of unfrozen types
	when we are in spec expression preanalysis mode.
	* sem_ch10.adb: New calling sequence for Freeze_Entity
	* sem_ch11.adb: Simplify analysis of aspect specifications now that the
	flag Has_Aspects applies to all nodes (no need to save aspects).
	* sem_ch12.adb: Simplify analysis of aspect specifications now that the
	flag Has_Aspects applies to all nodes (no need to save aspects).
	* sem_ch13.adb (Analyze_Aspect_Specifications): Major rewrite to
	accomodate delaying aspect evaluation to the freeze point.
	(Duplicate_Clause): Simplify using Get_Rep_Item_For_Entity, and also
	accomodate delayed aspects.
	(Rep_Item_Too_Late): Deal with delayed aspects case
	* sem_ch13.ads (Rep_Item_Too_Late): Document handling of delayed aspects
	* sem_ch3.adb (Analyze_Subtype_Declaration): Make sure that generic
	actual types are properly frozen (this is needed because of the new
	check in Eval_Attribute that declines to evaluate attributes
	for unfrozen types).
	Simplify analysis of aspect specifications now that the flag
	Has_Aspects applies to all nodes (no need to save aspects).
	* sem_ch3.ads (Preanalyze_Spec_Expression): Note use for delayed aspects
	* sem_ch5.adb: Simplify analysis of aspect specifications now that the
	flag Has_Aspects applies to all nodes (no need to save aspects).
	New calling sequence for Freeze_Entity.
	* sem_ch9.adb, sem_ch7.adb, sem_ch6.adb: Simplify analysis of aspect
	specifications now that the flag Has_Aspects applies to all nodes
	(no need to save aspects).
	New calling sequence for Freeze_Entity
	* sem_prag.adb (Check_Duplicate_Pragma): Simplify using
	Get_Rep_Item_For_Entity
	(Get_Pragma_Arg): Moved to Sinfo
	* sinfo.ads, sinfo.adb (Aspect_Rep_Item_: New field
	(Is_Delayed_Aspect): New flag
	(Next_Rep_Item): Document use for aspects
	(Get_Pragma_Arg): Moved here from Sem_Prag
	* sprint.adb (Sprint_Aspect_Specifications): Now called after semicolon
	is output and removes semicolon (simplifies interface).
	(Sprint_Node_Actual): Simplify handling of aspects now that Has_Aspects
	applies to any node.
	* tree_gen.adb: Write contents of Aspect_Specifications hash table
	* tree_in.adb: Read and initialize Aspect_Specifications hash table
	* treepr.adb (Print_Node): Print Has_Aspects flag
	(Print_Node): Print Aspect_Specifications in Has_Aspects set
	* xtreeprs.adb: Remove obsolete references to Flag1,2,3

From-SVN: r165300
2010-10-11 12:43:04 +02:00
Arnaud Charlet
0f1a6a0b83 [multiple changes]
2010-10-11  Robert Dewar  <dewar@adacore.com>

	* aspects.ads, aspects.adb: Major revision of this package for 2nd
	stage of aspects implementation.
	* gcc-interface/Make-lang.in: Add entry for aspects.o
	* gcc-interface/Makefile.in: Add aspects.o to GNATMAKE_OBJS
	* par-ch13.adb (Aspect_Specifications_Present): New function
	(P_Aspect_Specifications): New procedure
	* par-ch3.adb (P_Type_Declaration): Handle aspect specifications
	(P_Derived_Type_Def_Or_Private_Ext_Decl): Handle aspect specifications
	(P_Identifier_Declarations): Handle aspect specifications
	(P_Component_Items): Handle aspect specifications
	(P_Subtype_Declaration): Handle aspect specifications
	* par-ch6.adb (P_Subprogram): Handle aspect specifications
	* par-ch9.adb (P_Entry_Declaration): Handle aspect specifications
	* par.adb (Aspect_Specifications_Present): New function
	(P_Aspect_Specifications): New procedure
	* sem.adb (Analyze_Full_Type_Declaration): New name for
	Analyze_Type_Declaration.
	(Analyze_Formal_Package_Declaration): New name (add _Declaration)
	(Analyze_Formal_Subprogram_Declaration): New name (add _Declaration)
	(Analyze_Protected_Type_Declaration): New name (add _Declaration)
	(Analyze_Single_Protected_Declaration): New name (add _Declaration)
	(Analyze_Single_Task_Declaration): New name (add _Declaration)
	(Analyze_Task_Type_Declaration): New name (add _Declaration)
	* sem_cat.adb (Analyze_Full_Type_Declaration): New name for
	Analyze_Type_Declaration.
	* sem_ch11.adb (Analyze_Exception_Declaration): Analyze aspect
	specifications.
	* sem_ch12.adb (Analyze_Formal_Object_Declaration): Handle aspect
	specifications.
	(Analyze_Formal_Package_Declaration): New name (add _Declaration)
	(Analyze_Formal_Package_Declaration): Handle aspect specifications
	(Analyze_Formal_Subprogram_Declaration): New name (add _Declaration)
	(Analyze_Formal_Subprogram_Declaration): Handle aspect specifications
	(Analyze_Formal_Type_Declaration): Handle aspect specifications
	(Analyze_Generic_Package_Declaration): Handle aspect specifications
	(Analyze_Generic_Subprogram_Declaration): Handle aspect specifications
	(Analyze_Package_Instantiation): Handle aspect specifications
	(Analyze_Subprogram_Instantiation): Handle aspect specifications
	* sem_ch12.ads (Analyze_Formal_Package_Declaration): New name (add
	_Declaration).
	(Analyze_Formal_Subprogram_Declaration): New name (add _Declaration)
	* sem_ch13.adb (Analyze_Aspect_Specifications): New procedure
	(Duplicate_Clause): New function, calls to this function are added to
	processing for all aspects.
	* sem_ch13.ads (Analyze_Aspect_Specifications): New procedure
	* sem_ch3.adb (Analyze_Full_Type_Declaration): New name for
	Analyze_Type_Declaration.
	* sem_ch3.ads (Analyze_Full_Type_Declaration): New name for
	Analyze_Type_Declaration.
	* sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): Analyze aspect
	specifications.
	(Analyze_Subprogram_Declaration): Analyze aspect specifications
	* sem_ch7.adb (Analyze_Package_Declaration): Analyze aspect
	specifications.
	(Analyze_Private_Type_Declaration): Analyze aspect specifications
	* sem_ch9.adb (Analyze_Protected_Type_Declaration): Analyze aspect
	specifications.
	(Analyze_Protected_Type_Declaration): New name (add _Declaration)
	(Analyze_Single_Protected_Declaration): Analyze aspect specifications
	(Analyze_Single_Protected_Declaration): New name (add _Declaration)
	(Analyze_Single_Task_Declaration): Analyze aspect specifications
	(Analyze_Single_Task_Declaration): New name (add _Declaration)
	(Analyze_Task_Type_Declaration): Analyze aspect specifications
	(Analyze_Task_Type_Declaration): New name (add _Declaration)
	* sem_ch9.ads (Analyze_Protected_Type_Declaration): New name (add
	_Declaration).
	(Analyze_Single_Protected_Declaration): New name (add _Declaration)
	(Analyze_Single_Task_Declaration): New name (add _Declaration)
	(Analyze_Task_Type_Declaration): New name (add _Declaration)
	* sem_prag.adb: Use Get_Pragma_Arg systematically so that we do not
	have to generate unnecessary pragma argument associations (this matches
	the doc).
	Throughout do changes to accomodate aspect specifications, including
	specializing messages, handling the case of not going through all
	homonyms, and allowing for cancellation.
	* sinfo.ads, sinfo.adb: Clean up obsolete documentation for Flag1,2,3
	(Aspect_Cancel): New flag
	(From_Aspect_Specification): New flag
	(First_Aspect): Removed flag
	(Last_Aspect): Removed flag
	* sprint.adb (Sprint_Aspect_Specifications): New procedure
	(Sprint_Node_Actual): Add calls to Sprint_Aspect_Specifications

2010-10-11  Bob Duff  <duff@adacore.com>

	* sem_res.adb (Resolve_Actuals): Minor change to warning messages so
	they match in Ada 95, 2005, and 2012 modes, in the case where the
	language didn't change. Same thing for the run-time exception message.

2010-10-11  Javier Miranda  <miranda@adacore.com>

	* debug.adb Document that switch -gnatd.p enables the CIL verifier.

2010-10-11  Robert Dewar  <dewar@adacore.com>

	* s-htable.adb: Minor reformatting.

From-SVN: r165299
2010-10-11 12:34:53 +02:00
Arnaud Charlet
599a741170 [multiple changes]
2010-10-07  Robert Dewar  <dewar@adacore.com>

	* sem_attr.adb: Minor reformatting.
	* einfo.ads, einfo.adb (Is_Ada_2012_Only): New flag
	* itypes.adb (Create_Null_Excluding_Itype): Set Is_Ada_2012_Only flag
	properly.
	* lib-xref.adb (Generate_Reference): Warn on use of Ada 2012 entity in
	non-Ada 2012 mode.
	* opt.ads (Warn_On_Ada_2012_Compatibility): New flag
	* sem_ch3.adb (Analye_Subtype_Declaration): Inherit Is_Ada_2012_Only
	* sem_ch7.adb (Preserve_Full_Attributes): Preserve Is_Ada_2012_Only
	flag.
	* sem_prag.adb (Analyze_Pragma, case Ada_12/Ada_2012): Allow form with
	argument.
	* sem_type.adb (Disambiguate): Deal with Is_Ada_2012_Only.
	* sem_warn.adb (Warn_On_Ada_2012_Compatibility): New flag, treated
	same as 2005 flag.

2010-10-07  Javier Miranda  <miranda@adacore.com>

	* a-tags.ads: Use new support for pragma Ada_2012 with function
	Type_Is_Abstract.

From-SVN: r165082
2010-10-07 11:12:36 +02:00
Robert Dewar
22b77f6852 prj-util.adb, [...]: Minor reformatting.
2010-10-05  Robert Dewar  <dewar@adacore.com>

	* prj-util.adb, prj-util.ads, prj.ads, s-vxwext-rtp.adb, sem_ch4.adb,
	sem_ch7.adb, sem_res.adb, sem_type.adb: Minor reformatting.
	Minor code reorganization (use Nkind_In).

From-SVN: r164981
2010-10-05 12:22:52 +02:00
Arnaud Charlet
a3f2babd42 [multiple changes]
2010-10-04  Robert Dewar  <dewar@adacore.com>

	* sem_ch13.adb (Set_Biased): New procedure, now used throughout, adds
	name of entity to biased warning msg.
	(Analyze_Enumeration_Representation_Clause): Remove attempt to use
	biased rep (wrong and never worked anyway).

2010-10-04  Arnaud Charlet  <charlet@adacore.com>

	* sem_elab.adb: Minor reformatting.

2010-10-04  Ed Schonberg  <schonberg@adacore.com>

	* exp_ch4.adb (Expand_N_Null): Handle properly the case of a subtype of
	an access_to_protected subprogram type, and convert null value into
	corresponding aggregate.

2010-10-04  Eric Botcazou  <ebotcazou@adacore.com>

	* gnat_ugn.texi: Clarify first point of 7.1.5 about pragma Inline.

2010-10-04  Eric Botcazou  <ebotcazou@adacore.com>

	* make.adb (Scan_Make_Arg): Pass -Oxxx switches to the linker as well.
	* gnatlink.adb (Gnatlink): Filter out -Oxxx switches for CLI, RTX and
	AAMP.

2010-10-04  Eric Botcazou  <ebotcazou@adacore.com>

	* sem_ch4.adb (Analyze_Indexed_Component_Form): Remove redundant test
	for N_Operator_Symbol.
	(Indicate_Name_And_Type): Likewise.
	* sem_ch8.adb (Analyze_Subprogram_Renaming): Likewise.
	* sem_res.adb (Resolve): Likewise.
	* sem_type.adb (Add_One_Interp): Likewise.
	(Disambiguate): Likewise.
	
2010-10-04  Vincent Celier  <celier@adacore.com>

	* osint.adb (Read_Library_Info_From_Full): If object timestamp is less
	than ALI file timestamp, return null.

2010-10-04  Vincent Celier  <celier@adacore.com>

	* prj-makr.adb (Finalize): Invoke Pretty_Print with Max_Length set to 79
	* prj-pp.adb (Pretty_Print): New parameter Max_Line_Length, that
	replaces global constant with the same name. When a line is too long,
	indent properly the next continuation line.
	* prj-pp.ads (Pretty_Print): New parameter Max_Line_Length with a range
	from 50 to 255, defaulted to 255, to indicate the maximum length of
	lines in the project file.

2010-10-04  Eric Botcazou  <ebotcazou@adacore.com>

	* sem_ch7.adb (Analyze_Package_Body_Helper) <Has_Referencer>: New
	Check_Subprogram_Ref function and Check_Subprogram_Refs instantiation
	of Traverse_Func on it to look for subprogram references in a body.
	Call Check_Subprogram_Refs on the body of inlined subprograms at the
	outer level and keep clearing the Is_Public flag of subprograms as long
	as it returns OK.  Do not look at anything else than subprograms once
	an inlined subprogram has been seen.

From-SVN: r164940
2010-10-04 16:09:52 +02:00
Arnaud Charlet
ed2233dc6d par-ch9.adb, [...]: Update comments.
* par-ch9.adb, sem_aggr.adb, sem_ch3.adb, layout.adb, sem_ch4.adb,
	sem_ch5.adb, sem_mech.adb, exp_util.adb, par-ch10.adb, sem_ch6.adb,
	par-ch11.adb, sem_ch7.adb, par-prag.adb, exp_disp.adb, par-ch12.adb,
	sem_ch8.adb, style.adb, sem_ch9.adb, sem_ch10.adb, prep.adb,
	sem_warn.adb, par-util.adb, scng.adb, sem_eval.adb, checks.adb,
	sem_prag.adb, sem_ch12.adb, styleg.adb, sem_ch13.adb, par-ch3.adb,
	par-tchk.adb, freeze.adb, sfn_scan.adb, par-ch4.adb, sem_util.adb,
	sem_res.adb, par-ch5.adb, lib-xref.adb, sem_attr.adb, par-ch6.adb,
	sem_disp.adb, prepcomp.adb, par-ch7.adb, sem_elab.adb, exp_ch4.adb,
	errout.ads: Update comments. Minor reformatting.

From-SVN: r160979
2010-06-18 14:14:52 +02:00
Arnaud Charlet
bce79204fb [multiple changes]
2010-06-17  Robert Dewar  <dewar@adacore.com>

	* einfo.adb: Minor code fix, allow E_Class_Wide_Type for
	Equivalent_Type to match documentation.

2010-06-17  Robert Dewar  <dewar@adacore.com>

	* sem_ch6.adb, sem_ch7.adb: Minor reformatting.
	* sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_ch10.adb, sem_ch12.adb,
	sem_ch4.adb, sem_ch8.adb, sem_ch13.adb: Make use of Ekind_In.

2010-06-17  Thomas Quinot  <quinot@adacore.com>

	* sem_res.adb (Set_Slice_Subtype): Always freeze the slice's itype.

2010-06-17  Thomas Quinot  <quinot@adacore.com>

	* freeze.adb (Freeze_Expression): Short circuit operators are valid
	freeze node insertion points.

From-SVN: r160889
2010-06-17 10:56:40 +02:00
Arnaud Charlet
4a214958d1 [multiple changes]
2010-06-14  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch8.adb (End_Use_Type): Before indicating that an operator is not
	use-visible, check whether it is a primitive for more than one type.

2010-06-14  Robert Dewar  <dewar@adacore.com>

	* sem_ch3.adb (Copy_And_Swap): Copy Has_Pragma_Unmodified flag.

	* sem_ch7.adb (Preserve_Full_Attributes): Preserve
	Has_Pragma_Unmodified flag.

2010-06-14  Thomas Quinot  <quinot@adacore.com>

	* g-sttsne-locking.adb, g-sttsne-locking.ads, g-sttsne.ads,
	g-sttsne-vxworks.adb, g-sttsne-dummy.ads: Removed. Mutual exclusion is
	now done in GNAT.Sockets if necessary.
	* gsocket.h, g-socket.adb, g-sothco.ads (GNAT.Sockets.Get_XXX_By_YYY):
	Ensure mutual exclusion for netdb operations if the target platform
	requires it.
	(GNAT.Sockets.Thin_Common): New binding for getXXXbyYYY, treating struct
	hostent as an opaque type to improve portability.
	* s-oscons-tmplt.c, socket.c: For the case of Vxworks, emulate
	gethostbyYYY using proprietary VxWorks API so that a uniform interface
	is available for the Ada side.
	* gcc-interface/Makefile.in: Remove g-sttsne-*
	* gcc-interface/Make-lang.in: Update dependencies.

2010-06-14  Vincent Celier  <celier@adacore.com>

	* gnatcmd.adb (Mapping_File): New function.

From-SVN: r160731
2010-06-14 14:39:55 +02:00
Arnaud Charlet
a5d83d6141 [multiple changes]
2010-06-14  Robert Dewar  <dewar@adacore.com>

	* opt.ads, sem.adb, sem_elab.adb: Minor reformatting

2010-06-14  Robert Dewar  <dewar@adacore.com>

	* exp_aggr.adb (Has_Address_Clause): Moved to Exp_Util, and there it
	is renamed as Has_Following_Address_Clause.
	* exp_ch3.adb (Needs_Simple_Initialization): Add Consider_IS argument
	to allow the caller to avoid Initialize_Scalars having an effect.
	(Expand_N_Object_Declaration): Do not do Initialize_Scalars stuff for
	scalars with an address clause specified.
	* exp_ch3.ads (Needs_Simple_Initialization): Add Consider_IS argument
	to allow the caller to avoid Initialize_Scalars having an effect.
	* exp_util.adb (Has_Following_Address_Clause): Moved here from Exp_Aggr
	(where it was called Has_Address_Clause).
	* exp_util.ads (Has_Following_Address_Clause): Moved here from Exp_Aggr
	(where it was called Has_Address_Clause).
	* freeze.adb (Warn_Overlay): Suppress message about overlaying causing
	problems for Initialize_Scalars (since we no longer initialize objects
	with an address clause.

2010-06-14  Robert Dewar  <dewar@adacore.com>

	* exp_prag.adb (Expand_Pragma_Check): Set Loc of generated code from
	condition.

2010-06-14  Gary Dismukes  <dismukes@adacore.com>

	* sem_ch6.adb (Analyze_Subprogram_Body_Helper): Set Debug_Info_Needed
	on the entity of an implicitly generated postcondition procedure.

2010-06-14  Thomas Quinot  <quinot@adacore.com>

	* sem_ch7.adb (Preserve_Full_Attributes): Propagate
	Discriminant_Constraint elist from full view to private view.

From-SVN: r160720
2010-06-14 12:09:30 +02:00
Robert Dewar
16c5f1c624 a-teioed.adb, [...]: Minor reformatting
2009-07-30  Robert Dewar  <dewar@adacore.com>

	* a-teioed.adb, exp_disp.adb, s-linux-hppa.ads, s-linux.ads,
	s-tasini.adb, sem_ch13.adb, sem_ch3.adb, sem_ch3.ads, sem_ch6.adb,
	sem_ch7.adb: Minor reformatting

From-SVN: r150251
2009-07-30 11:23:06 +02:00
Arnaud Charlet
a73734f5f5 [multiple changes]
2009-07-29  Robert Dewar  <dewar@adacore.com>

	* exp_atag.ads, exp_atag.adb, s-tasini.adb, s-soflin.ads,
	exp_disp.adb, g-socket.adb: Minor reformatting

2009-07-29  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch7.adb (New_Private_Type): Create class-wide type after other
	attributes have been established, so that they are all inherited by the
	class-wide type.
	* sem_cat.adb (Validate_Remote_Access_Object_Type_Declaration): Handle
	properly named subtypes of class-wide types.

From-SVN: r150201
2009-07-29 10:51:53 +02:00
Robert Dewar
d1f453b764 einfo.adb (OK_To_Rename): New flag
2009-04-24  Robert Dewar  <dewar@adacore.com>

	* einfo.adb (OK_To_Rename): New flag

	* einfo.ads (OK_To_Rename): New flag

	* exp_ch3.adb (Expand_N_Object_Declaration): Rewrite as renames if
	OK_To_Rename set.

	* exp_ch4.adb (Expand_Concatenate): Mark temp variable OK_To_Rename

	* sem_ch7.adb (Uninstall_Declarations): Allow for renames from
	OK_To_Rename.

From-SVN: r146714
2009-04-24 15:14:22 +02:00
Arnaud Charlet
c54ab0b5d1 [multiple changes]
2009-04-24  Vincent Celier  <celier@adacore.com>

	* opt.ads (Unchecked_Shared_Lib_Imports): New Boolean flag.

	* prj-nmsc.adb (Check_Library): No error for imports by shared library
	projects, when --unchecked-shared-lib-imports is used.

2009-04-24  Robert Dewar  <dewar@adacore.com>

	* sem_ch7.adb: Minor reformatting

From-SVN: r146693
2009-04-24 12:25:20 +02:00
Thomas Quinot
5e39baa64c 2009-04-20 Thomas Quinot <quinot@adacore.com>
* g-socket.adb, g-socket.ads, g-socthi-mingw.ads, g-socthi-vms.adb,
	g-socthi-vms.ads, g-socthi-vxworks.ads, g-socthi.ads
	(GNAT.Sockets.Thin.C_Inet_Addr): Remove.
	(GNAT.Sockets.Thin.Inet_Aton): New function, imported from C library
	except for VMS where it is reimplemented in Ada using DECC$INET_ADDR.
	(GNAT.Sockets.Inet_Addr): Use inet_aton(3) instead of inet_addr(3).

	* debug.adb: Fix typo

	* gnat_rm.texi: Minor doc fix.

	* sem_ch7.adb, freeze.adb: Minor reformatting

From-SVN: r146387
2009-04-20 11:42:48 +02:00
Bob Duff
b1b543d2c0 output.ads (Indent,Outdent): New procedures for indenting the output.
2009-04-17  Bob Duff  <duff@adacore.com>

	* output.ads (Indent,Outdent): New procedures for indenting the output.
	(Write_Char): Correct comment -- LF _is_ allowed.

	* output.adb (Indent,Outdent): New procedures for indenting the output.
	Keep track of the indentation level, and make sure it doesn't get too
	high.
	(Flush_Buffer): Insert spaces at the beginning of each line, if
	indentation level is nonzero.
	(Save_Output_Buffer,Restore_Output_Buffer): Save and restore the current
	indentation level.
	(Set_Standard_Error,Set_Standard_Output): Remove superfluous
	"Next_Col := 1;".  Flush_Buffer does that.

	* sem_ch6.adb, sem_ch7.adb (Debug_Flag_C): Reorganize the output
	controlled by the -gnatdc switch. It now occurs on entry/exit to the
	relevant analysis routines, and calls Indent/Outdent to make the
	indentation reflect the nesting level.  Add "helper" routines, since
	otherwise lots of "return;" statements would skip the debugging output.

From-SVN: r146253
2009-04-17 14:11:04 +02:00
Ed Schonberg
cec2913559 sem_ch3.adb (Access_Subprogram_Definition): Additional checks on illegal uses of incomplete types in formal parts and...
2009-04-17  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch3.adb (Access_Subprogram_Definition): Additional checks on
	illegal uses of incomplete types in formal parts and return types.

	* sem_ch6.adb (Process_Formals): Taft-amendment types are legal in
	access to subprograms.

	* sem_ch7.adb (Uninstall_Declarations): diagnose attempts to use
	Taft-amendment types as the return type of an access_to_function type.

	* freeze.adb (Freeze_Entity): Remove tests on formals of an incomplete
	type for access_to_subprograms. The check is performed on package exit.

From-SVN: r146229
2009-04-17 11:36:05 +02:00
Arnaud Charlet
93bcda233f [multiple changes]
2009-04-17  Robert Dewar  <dewar@adacore.com>

	* gnat_rm.texi: Add documentation about No_Streams restriction

	* sem_attr.adb (Check_Stream_Attribute): Exclude implicit stream
	attributes when checking No_Streams restriction.

2009-04-17  Thomas Quinot  <quinot@adacore.com>

	* rtsfind.ads (RE_Request_Destroy): New PolyORB s-parint entity.

	* exp_dist.adb (PolyORB_Support.Build_General_Calling_Stubs): Add
	missing calls to RE_Request_Destroy to deallocate request objects after
	use.

2009-04-17  Nicolas Setton  <setton@adacore.com>

	* link.c: Fix support for passing a response file under Darwin.

2009-04-17  Emmanuel Briot  <briot@adacore.com>

	* prj.adb (Free): new subprogram.

2009-04-17  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch3.adb: additional initialization on incomplete subtypes.
	
	* sem_ch6.adb (Process_Formals): if the subprogram is in the private
	part and one of the formals is an incomplete tagged type, attach to
	list of private dependends of the type for later validation.

	* sem_ch7.adb (Uninstall_Declarations): diagnose attempts to declare
	primitive operations of a Taft-amendmment type.

	* freeze.adb (Freeze_Entity): Remove tests on formals of an incomplete
	type. The check is performed on package exit, possibly after the
	subprogram is frozen.

2009-04-17  Vincent Celier  <celier@adacore.com>

	* prj-nmsc.adb (Get_Directories): Get the object and exec directory
	before looking for source directories, but make sure that there are nil
	if they are not explicitely declared and there is explicitely no
	sources in the project.

From-SVN: r146227
2009-04-17 11:24:31 +02:00
Robert Dewar
a4100e5582 sem_aggr.adb, [...]: Reorganize einfo/sem_aux, moving routines from einfo to sem_aux
2009-04-09  Robert Dewar  <dewar@adacore.com>

	* sem_aggr.adb, exp_ch5.adb, sem_ch3.adb, exp_atag.adb, layout.adb,
	sem_dist.adb, exp_ch7.adb, sem_ch5.adb, sem_type.adb, exp_imgv.adb,
	exp_util.adb, sem_aux.adb, sem_aux.ads, exp_attr.adb, exp_ch9.adb,
	sem_ch7.adb, inline.adb, fe.h, sem_ch9.adb, exp_code.adb, einfo.adb,
	einfo.ads, exp_pakd.adb, checks.adb, sem_ch12.adb, exp_smem.adb,
	tbuild.adb, freeze.adb, sem_util.adb, sem_res.adb, sem_attr.adb,
	exp_dbug.adb, sem_case.adb, exp_tss.adb, exp_ch4.adb, exp_ch6.adb,
	sem_smem.adb, sem_ch4.adb, sem_mech.adb, sem_ch6.adb, exp_disp.adb,
	sem_ch8.adb, exp_aggr.adb, sem_eval.adb, sem_cat.adb, exp_dist.adb,
	sem_ch13.adb, exp_strm.adb, lib-xref.adb, sem_disp.adb, exp_ch3.adb:
	Reorganize einfo/sem_aux, moving routines from einfo to sem_aux

From-SVN: r145820
2009-04-09 12:27:10 +02:00
Ralf Wildenhues
16b0521384 a-crbtgk.adb, [...]: Fix typos in comments.
gcc/ada/
	* a-crbtgk.adb, a-direct.ads, a-tasatt.adb, ali.ads,
	bindgen.adb, checks.adb, einfo.ads, exp_aggr.adb, exp_ch11.adb,
	exp_ch3.adb, exp_ch4.adb, exp_ch6.adb, exp_ch7.adb, exp_ch9.adb,
	exp_dbug.ads, exp_disp.adb, exp_dist.adb, exp_pakd.adb,
	exp_util.adb, g-alveop.ads, g-comlin.adb, g-comlin.ads,
	g-diopit.adb, g-socket.ads, gcc-interface/decl.c,
	gcc-interface/gigi.h, gcc-interface/trans.c,
	lib-load.adb, lib-xref.ads, make.adb, mlib-prj.adb, nlists.ads,
	opt.ads, par-ch10.adb, par-ch5.adb, par.adb, s-os_lib.ads,
	s-oscons-tmplt.c, s-parint.ads, s-regpat.ads, s-shasto.ads,
	s-stausa.ads, s-taprop-vms.adb, sem.adb, sem_ch10.adb,
	sem_ch11.adb, sem_ch12.adb, sem_ch13.adb, sem_ch3.adb,
	sem_ch3.ads, sem_ch4.adb, sem_ch6.adb, sem_ch7.adb, sem_ch8.adb,
	sem_elim.adb, sem_prag.adb, sem_util.adb, sem_util.ads,
	sem_warn.adb, sinfo.ads, styleg.adb, vms_data.ads: Fix typos in
	comments.
	* gnathtml.pl: Fix typos.

From-SVN: r140356
2008-09-14 06:21:12 +00:00
Samuel Tardieu
b9b2405ff3 gcc/ada/
* exp_ch13.adb, exp_disp.adb, sem_cat.adb, sem_ch10.adb,
	* sem_ch12.adb, sem_ch6.adb, sem_ch7.adb, sem_ch8.adb,
	* sem_prag.adb, sem_util.adb, sem_warn.adb: Use
	Is_Package_Or_Generic_Package instead of hand-crafted tests.

From-SVN: r139191
2008-08-18 08:59:47 +00:00
Javier Miranda
3393111257 2008-05-20 Javier Miranda <miranda@adacore.com>
Ed Schonberg  <schonberg@adacore.com>
	    Hristian Kirtchev  <kirtchev@adacore.com>

	* sem_ch3.adb
	(Analyze_Object_Declaration): Fix over-conservative condition
	restricting use of predefined assignment with tagged types that have
	convention CPP.
	(Analyze_Object_Declaration): Relax the check regarding deferred
	constants declared in scopes other than packages since they can be
	completed with pragma Import.
	Add missing escaping of all-caps word 'CPP' in error messages.
	(Build_Discriminated_Subtype): Do not inherit representation clauses
	from parent type if subtype already carries them, because they are
	inherited earlier during derivation and already include those that may
	come from a partial view.

	* sem_ch9.adb, sem_ch5.adb, sem_ch6.adb (Analyze_Subprogram_Body):
	Check the declarations of a subprogram body for proper deferred
	constant completion.

	* sem_ch7.ads, sem_ch7.adb
	(Inspect_Deferred_Constant_Completion): Moved to sem_util.

From-SVN: r135638
2008-05-20 14:50:03 +02:00
Ralf Wildenhues
f3d0f304ff vms_data.ads: Fix typo in constant.
gcc/ada/

	* vms_data.ads: Fix typo in constant.
	* gen-soccon.c: Fix typo in error string.
	* gnat_rm.texi (Pragma Optimize_Alignment, Pragma Postcondition):
	Fix typos.
	* a-calcon.ads, a-calend-vms.adb, a-calend.adb, a-crdlli.ads,
	bcheck.adb, checks.adb, einfo.ads, errout.adb, erroutc.adb,
	erroutc.ads, exp_attr.adb, exp_ch11.adb, exp_ch2.adb,
	exp_ch5.adb, exp_ch9.adb, exp_ch9.ads, exp_pakd.adb,
	exp_util.adb, fmap.adb, g-soccon-linux-mips.ads,
	g-soccon-rtems.ads, g-timsta.adb, g-timsta.ads, lib-writ.ads,
	mlib-tgt-specific-linux.adb, mlib-tgt-specific-tru64.adb,
	s-interr-vxworks.adb, s-interr.adb, s-osinte-lynxos.ads,
	s-rident.ads, s-taprop-solaris.adb, s-tassta.adb, s-win32.ads,
	sem_aggr.adb, sem_attr.ads, sem_ch10.adb, sem_ch13.ads,
	sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch8.adb, sem_ch9.adb,
	sem_prag.ads, sem_res.adb, sem_util.adb, sem_util.ads,
	sinfo.ads: Fix typos in comments.

From-SVN: r134291
2008-04-14 21:07:59 +00:00
Ed Schonberg
f7d5442e99 lib-xref.adb (Is_On_LHS): Remove dead code
2008-04-08  Ed Schonberg  <schonberg@adacore.com>
	    Robert Dewar  <dewar@adacore.com>
	    Gary Dismukes  <dismukes@adacore.com>

	* lib-xref.adb (Is_On_LHS): Remove dead code
	(Output_Overriden_Op): If the overridden operation is itself inherited,
	list the ancestor operation, which is the one whose body or absstract
	specification is actually being overridden.

	* sem_ch7.adb (Is_Primitive_Of): use base type to determine whether
	operation is primitive for the type.
	(Declare_Inherited_Private_Subprograms): If the new operation overrides
	an inherited private subprogram, set properly the Overridden_Operation
	attribute, for better cross-reference information.
	(Analyze_Package_Specification): Do late analysis of spec PPCs
	(Install_Private_Declaration, Uninstall_Declarations): Save/restore
	properly the full view and underlying full views of a private type in a
	child unit, whose full view is derived from a private type in a parent
	unit, and whose own full view becomes visible in the child body.

	* sem_disp.adb (Check_Dispatching_Operation): When a body declares a
	primitive operation after the type has been frozen, add an explicit
	reference to the type and the operation, because other primitive
	references have been emitted already.
	(Expand_Call, Propagate_Tag): Call Kill_Current_Values when processing a
	dispatching call on VM targets.

From-SVN: r134038
2008-04-08 08:52:41 +02:00
Ed Schonberg
7d823354f4 sem_ch7.adb (Install_Parent_Private_Declarations): If the private declarations of a parent unit are made visible when...
2008-03-26  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch7.adb (Install_Parent_Private_Declarations): If the private
	declarations of a parent unit are made visible when compiling a child
	instance, the parent is not a hidden open scope, even though it may
	contain other pending instance.
	
	* sem_ch8.adb (Restore_Scope_Stack): If an entry on the stack is a
	hidden open scope for some child instance, it does affect the
	visibility status of other stach entries.
	(Analyze_Object_Renaming): Check that a class-wide object cannot be
	renamed as an object of a specific type.

From-SVN: r133578
2008-03-26 08:42:25 +01:00
Robert Dewar
ac4d640744 atree.adb (Flag231..Flag247): New functions
2007-12-06  Robert Dewar  <dewar@adacore.com>

	* atree.adb (Flag231..Flag247): New functions
	(Set_Flag231..Set_Flag247): New procedures
	(Basic_Set_Convention): Rename Set_Convention to be
	Basic_Set_Convention
	(Nkind_In): New functions
	Remove Atree.Delete_Tree/Delete_Node and Nlist.Delete_List

	* exp_ch6.adb (Expand_Call): Use new flag Has_Pragma_Inline_Always
	instead
	 of obsolete function Is_Always_Inlined
	(Register_Predefined_DT_Entry): Initialize slots of the second
	secondary dispatch table.
	Remove Atree.Delete_Tree/Delete_Node and Nlist.Delete_List
	(Expand_N_Function_Call): Remove special provision for stack checking.

	* exp_util.ads, exp_util.adb (Is_Predefined_Dispatching_Operation):
	Include _Disp_Requeue in the list of predefined operations.
	(Find_Interface_ADT): Modified to fulfill the new specification.
	Remove Atree.Delete_Tree/Delete_Node and Nlist.Delete_List

	* par-ch4.adb, nlists.ads, nlists.adb: 
	Remove Atree.Delete_Tree/Delete_Node and Nlist.Delete_List

	* sinfo.ads, sinfo.adb: (Nkind_In): New functions
	Fix location of flag for unrecognized pragma message

	* sem_ch7.adb: Use Nkind_In

From-SVN: r130820
2007-12-13 11:22:06 +01:00
Robert Dewar
67ce0d7e96 s-taprop-solaris.adb, [...]: Minor reformatting.
2007-10-15  Robert Dewar  <dewar@adacore.com>

	* s-taprop-solaris.adb, s-taprop-vms.adb, s-taprop-mingw.adb, 
	s-taprop-vxworks.adb, s-taprop-posix.adb, a-calend-vms.adb,
	a-calend.adb, a-nuflra.adb, a-tigeau.adb, a-wtgeau.adb, 
	checks.adb, bindgen.adb, eval_fat.adb, exp_fixd.adb, fmap.adb, 
	freeze.adb, g-awk.adb, g-calend.adb, g-diopit.adb, g-expect.adb, 
	gnatchop.adb, gnatlink.adb, g-spipat.adb, g-thread.adb, make.adb, 
	mdll.adb, mlib.adb, mlib-prj.adb, osint.adb, par-ch3.adb, prj.adb, 
	prj-makr.adb, sem_prag.adb, sem_type.adb, s-fatgen.adb, s-fileio.adb, 
	sinfo.ads, sinput-d.adb, s-taasde.adb, s-tasdeb.ads, s-tasren.adb, 
	s-tassta.adb, s-tpobop.adb, s-tposen.adb, stylesw.adb, types.ads,
	uintp.adb, validsw.adb, makegpr.adb, a-rbtgso.adb, a-crbtgo.adb, 
	a-coorse.adb, a-convec.adb, a-coinve.adb, a-cohama.adb, a-ciorse.adb, 
	a-cihama.adb, a-cidlli.adb, a-chtgop.adb, a-cdlili.adb, a-cdlili.adb, 
	a-coormu.adb, a-ciormu.adb, a-cihase.adb, a-cohase.adb, a-ciorma.adb, 
	a-coorma.adb, a-ztgeau.adb, symbols-vms.adb, a-crdlli.adb, 
	a-calari.adb, a-calfor.adb, s-os_lib.adb, s-regpat.adb, a-ngrear.adb:
	Minor reformatting.
	Add Unreferenced and Warnings (Off) pragmas for cases of
	variables modified calls where they are IN OUT or OUT parameters and
	the resulting values are not subsequently referenced. In a few cases,
	we also remove redundant code found by the new warnings.

	* ug_words, vms_data.ads, usage.adb, sem_util.adb, sem_util.ads, 
	sem_warn.adb, sem_warn.ads, sem_res.adb, sem_ch7.adb, sem_ch8.adb,
	sem_ch5.adb, opt.ads, lib-xref.adb, lib-xref.ads, exp_smem.adb,
	sem_ch11.adb, exp_ch6.adb, einfo.ads, einfo.adb: implement a new
	warning controlled by -gnatw.o that warns on cases of out parameter
	values being ignored.

From-SVN: r129318
2007-10-15 15:53:48 +02:00
Gary Dismukes
31b5873d01 freeze.adb (Freeze_Entity): Remove check for preelaborable initialization of a full view.
2007-09-26  Gary Dismukes  <dismukes@adacore.com>

	* freeze.adb (Freeze_Entity): Remove check for preelaborable
	initialization of a full view. This is moved to
	Analyze_Package_Specification.

	* sem_ch7.adb (Analyze_Package_Specification): Add check for
	preelaborable initialization of a full view in entity loop.
	(Uninstall_Declarations): If entity is a use-visible compilation unit,
	its child units are use-visible only if they are visible child units.

	* sem_util.adb (Is_Preelaborable_Expression): New function to determine
	whether an expression can be used within a type declaration that
	requires preelaborable init.
	(Check_Components): Replace inline code that does partial checking for
	preelaborable default expressions with call to
	Is_Preelaborable_Expression.
	(Has_Preelaborable_Initialization): In the case of a generic actual
	subtype, (that is, Is_Generic_Actual is True), return the result of
	applying Has_Preelaborable_Initialization to the generic actual's base
	type.

From-SVN: r128789
2007-09-26 12:43:34 +02:00
Robert Dewar
b5c84c3ccf exp_atag.ads, [...]: Replace headers with GPL v3 headers.
2007-09-10  Robert Dewar  <dewar@adacore.com>

	* exp_atag.ads, exp_atag.adb, mlib-tgt-tru64.adb, mlib-tgt-aix.adb,
	mlib-tgt-irix.adb, mlib-tgt-hpux.adb, mlib-tgt-linux.adb,
	mlib-tgt-solaris.adb, mlib-tgt-vms-alpha.adb, mlib-tgt-vms-ia64.adb,
	mlib-tgt-mingw.adb, mlib-tgt-vxworks.adb, ali.adb, ali.ads,
	ali-util.adb, ali-util.ads, atree.h, back_end.adb, back_end.ads,
	bcheck.adb, bcheck.ads, binde.adb, binde.ads, binderr.adb, binderr.ads,
	bindgen.adb, bindgen.ads, bindusg.adb, bindusg.ads, butil.adb,
	butil.ads, checks.adb, checks.ads, clean.adb, clean.ads, comperr.adb,
	comperr.ads, cstand.adb, cstand.ads, debug_a.adb, debug_a.ads,
	elists.h, errout.adb, erroutc.ads, errutil.adb, errutil.ads,
	err_vars.ads, eval_fat.adb, eval_fat.ads, exp_sel.ads, exp_sel.adb,
	exp_aggr.adb, exp_aggr.ads, expander.adb, expander.ads, exp_attr.ads,
	exp_ch10.ads, exp_ch11.adb, exp_ch12.adb, exp_ch12.ads, exp_ch13.adb,
	exp_ch13.ads, exp_ch2.adb, exp_ch2.ads, exp_ch3.ads, exp_ch4.adb,
	exp_ch4.ads, exp_ch5.adb, exp_ch5.ads, exp_ch6.adb, exp_ch6.ads,
	exp_ch7.adb, exp_ch7.ads, exp_ch8.adb, exp_ch8.ads, exp_ch9.adb,
	exp_ch9.ads, exp_code.adb, exp_code.ads, exp_dbug.adb, exp_dbug.ads,
	exp_disp.ads, exp_dist.adb, exp_dist.ads, exp_fixd.adb, exp_fixd.ads,
	exp_imgv.adb, exp_imgv.ads, exp_intr.adb, exp_intr.ads, exp_pakd.adb,
	exp_pakd.ads, exp_prag.adb, exp_prag.ads, exp_smem.adb, exp_strm.adb,
	exp_strm.ads, exp_tss.adb, exp_tss.ads, exp_util.adb, exp_util.ads,
	exp_vfpt.adb, exp_vfpt.ads, fmap.adb, fmap.ads, fname-sf.adb,
	fname-sf.ads, fname-uf.adb, fname-uf.ads, frontend.adb, frontend.ads,
	get_targ.adb, get_targ.ads, gnat1drv.adb, gnat1drv.ads, gnatbind.adb,
	gnatbind.ads, gnatbl.c, gnatchop.adb, gnatclean.adb, gnatcmd.adb,
	gnatcmd.ads, gnatdll.adb, gnatfind.adb, gnatkr.adb, gnatkr.ads,
	gnatlbr.adb, gnatlink.adb, gnatlink.ads, gnatls.adb, gnatls.ads,
	gnatmake.adb, gnatmake.ads, gnatmem.adb, gnatname.adb, gnatname.ads,
	gnatprep.adb, gnatprep.ads, gnatsym.adb, gnatxref.adb,
	gprep.adb, gprep.ads, hlo.adb, hlo.ads, impunit.adb, impunit.ads,
	inline.adb, inline.ads, itypes.adb, itypes.ads, layout.adb, layout.ads,
	lib-load.adb, lib-load.ads, lib-util.adb, lib-util.ads, lib-writ.adb,
	lib-writ.ads, lib-xref.adb, lib-xref.ads, live.adb, live.ads,
	make.adb, make.ads, makeutl.ads, makeutl.adb, makeusg.adb, makeusg.ads,
	mdll.adb, mdll.ads, mdll-fil.adb, mdll-fil.ads, mdll-utl.adb,
	mdll-utl.ads, memroot.adb, memroot.ads, mlib.adb, mlib.ads,
	mlib-fil.adb, mlib-fil.ads, mlib-prj.adb, mlib-prj.ads, mlib-tgt.adb,
	mlib-tgt.ads, mlib-utl.adb, mlib-utl.ads, namet.h, nmake.adt,
	osint.adb, osint.ads, osint-b.adb, osint-b.ads, osint-c.adb,
	osint-c.ads, osint-l.adb, osint-l.ads, osint-m.adb, osint-m.ads,
	par.adb, par.ads, par-ch10.adb, par-ch11.adb, par-ch12.adb,
	par-ch13.adb, par-ch2.adb, par-ch3.adb, par-ch4.adb, par-ch5.adb,
	par-ch6.adb, par-ch7.adb, par-ch8.adb, par-ch9.adb, par-endh.adb,
	par-labl.adb, par-load.adb, par-prag.adb, par-sync.adb, par-tchk.adb,
	par-util.adb, prep.adb, prep.ads, prepcomp.adb, prepcomp.ads,
	prj.adb, prj.ads, prj-attr.adb, prj-attr.ads, prj-com.ads,
	prj-dect.adb, prj-dect.ads, prj-err.adb, prj-err.ads, prj-ext.adb,
	prj-ext.ads, prj-makr.adb, prj-makr.ads, prj-nmsc.adb, prj-nmsc.ads,
	prj-pars.adb, prj-pars.ads, prj-part.adb, prj-part.ads,
	prj-pp.adb, prj-pp.ads, prj-proc.adb, prj-proc.ads,
	prj-strt.adb, prj-strt.ads, prj-tree.adb, prj-tree.ads,
	prj-util.adb, prj-util.ads, restrict.adb, restrict.ads,
	rtsfind.adb, rtsfind.ads, scn.adb, scn.ads,
	scng.adb, scng.ads, sdefault.ads, sem.ads, sem_aggr.ads, sem_attr.adb,
	sem_case.adb, sem_case.ads, sem_cat.adb, sem_cat.ads, sem_ch10.adb,
	sem_ch10.ads, sem_ch11.adb, sem_ch11.ads, sem_ch12.ads, sem_ch13.adb,
	sem_ch13.ads, sem_ch2.adb, sem_ch2.ads, sem_ch3.adb, sem_ch3.ads,
	sem_ch4.ads, sem_ch5.adb, sem_ch5.ads, sem_ch6.adb, sem_ch6.ads,
	sem_ch7.adb, sem_ch7.ads, sem_ch8.adb, sem_ch8.ads, sem_ch9.adb,
	sem_ch9.ads, sem_disp.adb, sem_disp.ads, sem_dist.adb, sem_dist.ads,
	sem_elab.adb, sem_elab.ads, sem_elim.adb, sem_elim.ads, sem_eval.adb,
	sem_eval.ads, sem_intr.adb, sem_intr.ads, sem_maps.adb, sem_maps.ads,
	sem_mech.adb, sem_mech.ads, sem_prag.adb, sem_prag.ads, sem_res.adb,
	sem_res.ads, sem_smem.adb, sem_smem.ads, sem_type.adb, sem_type.ads,
	sem_util.adb, sem_util.ads, sem_vfpt.adb, sem_vfpt.ads, sem_warn.adb,
	sem_warn.ads, sfn_scan.ads, sinfo-cn.adb, sinfo-cn.ads, sinput-c.adb,
	sinput-c.ads, sinput-d.adb, sinput-d.ads, sinput-l.adb, sinput-l.ads,
	sinput-p.adb, sinput-p.ads, snames.h, sprint.adb, sprint.ads,
	stringt.h, style.ads, styleg.adb, styleg.ads, styleg-c.adb,
	styleg-c.ads, stylesw.adb, stylesw.ads, switch.adb, switch.ads,
	switch-b.adb, switch-b.ads, switch-c.adb, switch-c.ads, switch-m.adb,
	switch-m.ads, symbols.adb, symbols.ads, targparm.adb, tbuild.adb,
	tbuild.ads, tempdir.adb, tempdir.ads, tree_gen.adb, tree_gen.ads,
	treepr.adb, treepr.ads, treeprs.adt, ttypef.ads, ttypes.ads,
	types.h, uintp.h, urealp.h, usage.adb, usage.ads,
	validsw.adb, validsw.ads, vxaddr2line.adb, xeinfo.adb, xnmake.adb,
	xref_lib.adb, xref_lib.ads, xr_tabls.adb, xr_tabls.ads, xsinfo.adb,
	xtreeprs.adb, xsnames.adb, vms_conv.ads, vms_conv.adb, xgnatugn.adb,
	gprmake.adb, makegpr.ads, makegpr.adb, prj-attr-pm.ads, prj-attr-pm.adb,
	mlib-tgt-lynxos.adb, mlib-tgt-darwin.adb, symbols-vms.adb,
	symbols-processing-vms-alpha.adb, symbols-processing-vms-ia64.adb,
	mlib-tgt-specific.adb, mlib-tgt-specific.ads, mlib-tgt-vms.adb,
	mlib-tgt-vms.ads: Replace headers with GPL v3 headers.

From-SVN: r128332
2007-09-10 14:47:10 +02:00