1 2010-10-08 Robert Dewar <dewar@adacore.com>
3 * sem_ch3.adb: Minor reformatting.
5 2010-10-08 Vincent Celier <celier@adacore.com>
7 * ali-util.adb (Get_File_Checksum): Make sure that external_as_list is
9 * prj-proc.adb (Expression): Process string list external references.
10 * prj-strt.adb (External_Reference): Parse external_as_list external
12 * prj-tree.ads (Expression_Kind_Of): Allowed for N_External_Value nodes
13 (Set_Expression_Kind_Of): Ditto
14 * prj.adb (Initialize): Set external_as_list as a reserved word
15 * projects.texi: Document new string external reference external_as_list
16 * scans.ads (Token_Type): New token Tok_External_As_List
17 * snames.ads-tmpl: New standard name Name_External_As_List
19 2010-10-08 Thomas Quinot <quinot@adacore.com>
21 * sem_prag.adb: Minor reformatting.
23 2010-10-08 Ed Schonberg <schonberg@adacore.com>
25 * sem_ch3.adb (Derived_Type_Declaration): In the private part of an
26 instance, it is legal to derive from a non-limited actual when the
27 formal type is untagged limited.
28 * sem_ch12.adb (Instantiate_Type): For a formal private type, use
29 analyzed formal as Generic_Parent_Type, to simplify later checks.
31 2010-10-08 Ed Schonberg <schonberg@adacore.com>
33 * sem_res.adb (Insert_Default): If default value is already a
34 raise_constraint_error do not rewrite it as new raise node, to prevent
35 infinite loops in the warning removal machinery.
37 2010-10-08 Robert Dewar <dewar@adacore.com>
39 * sem_util.adb, sem_prag.adb: Minor reformatting
41 2010-10-08 Hristian Kirtchev <kirtchev@adacore.com>
43 * gnat_rm.texi: Remove the section on pragma Implemented_By_Entry.
44 Add section on pragma Implemented.
46 2010-10-08 Ed Schonberg <schonberg@adacore.com>
48 * sem_ch3.adb (Derive_Subprogram): If an abstract extension has a
49 concrete parent with a concrete constructor, the inherited constructor
50 is abstract even if the derived type is a null extension.
52 2010-10-08 Thomas Quinot <quinot@adacore.com>
54 * sem_ch4.adb: Minor reformatting.
56 2010-10-08 Hristian Kirtchev <kirtchev@adacore.com>
58 * einfo.adb: Flag 232 (formerly Implemented_By_Entry) is now unused.
59 (Implemented_By_Entry): Removed.
60 (Set_Implemented_By_Entry): Removed.
61 (Write_Entity_Flags): Remove the output for Implemented_By_Entry.
62 * einfo.ads: Remove flag Implemented_By_Entry and its usage in entities.
63 (Implemented_By_Entry): Removed along with its associated pragma Inline.
64 (Set_Implemented_By_Entry): Removed along with its associated pragma
66 * exp_ch9.adb: Alphabetize with and use clauses of Exp_Ch9.
67 (Build_Dispatching_Call_Equivalent): New routine.
68 (Build_Dispatching_Requeue): New routine.
69 (Build_Dispatching_Requeue_To_Any): New routine.
70 (Build_Normal_Requeue): New routine.
71 (Build_Skip_Statement): New routine.
72 (Expand_N_Requeue_Statement): Rewritten. The logic has been split into
74 * par-prag.adb: Replace Pragma_Implemented_By_Entry by
76 * sem_ch3.adb (Check_Abstract_Overriding): Perform checks concerning
78 (Check_Pragma_Implemented): New routines.
79 (Inherit_Pragma_Implemented): New routine.
80 * sem_ch9.adb (Analyze_Requeue): Update the predicate which detects a
82 * sem_prag.adb: Update array Sig_Flags by removing Implemented_By_Entry
83 and adding Implemented.
84 (Ada_2012_Pragma): New routine.
85 (Analyze_Pragma, case Implemented): Perform all necessary checks
86 concerning pragma Implemented and register the pragma as a
87 representation item with the procedure_LOCAL_NAME.
88 (Analyze_Pragma, case Implemented_By_Entry): Removed.
89 * sem_util.adb (Implementation_Kind): New routine.
90 * sem_util.ads (Implementation_Kind): New routine.
91 * snames.ads-tmpl: Remove Name_Implemented_By_Entry and add
92 Name_Implemented. Remove pragma name Pragma_Implemented_By_Entry and
93 add Pragma_Implemented. Add special names By_Any, By_Entry and
94 By_Protected_Procedure.
96 2010-10-08 Javier Miranda <miranda@adacore.com>
98 * exp_ch3.adb (Expand_Freeeze_Record_Type): Code cleanup: remove local
99 variable Has_Static_DT by invocation of function Building_Static_DT.
101 2010-10-08 Vincent Celier <celier@adacore.com>
103 * g-dirope.adb (Remove_Dir): Do not change the current directory when
104 doing a recursive remove of a subdirectory.
106 2010-10-08 Javier Miranda <miranda@adacore.com>
108 * exp_ch6.ad (Freeze_Subprogram): Factorize code.
109 * exp_disp.adb (Make_Secondary_DT): Factorize code.
110 (Make_DT): Factorize code.
112 2010-10-08 Robert Dewar <dewar@adacore.com>
114 * sem_ch4.adb: Minor reformatting.
116 2010-10-08 Robert Dewar <dewar@adacore.com>
118 * sem_ch6.adb (Check_Conformance): Check null exclusion match for full
121 2010-10-08 Thomas Quinot <quinot@adacore.com>
123 * sem_ch12.adb (Instantiate_Object): Rename Formal_Id to Gen_Obj, for
124 consistency with Gen_T in Instantiate_Type.
125 Introduce constant A_Gen_Obj to avoid repeated queries for
126 Defining_Identifier (Analyzed_Formal).
128 2010-10-08 Vincent Celier <celier@adacore.com>
130 * prj-nmsc.adb: Minor comment fix.
132 2010-10-07 Robert Dewar <dewar@adacore.com>
134 * sem_prag.adb, sem_ch13.adb: Implement AI05-0012-1/02.
135 * gcc-interface/Make-lang.in: Update dependencies.
137 2010-10-07 Ed Schonberg <schonberg@adacore.com>
139 * sem_ch12.ad: (Instantiate_Object): For an in-out formal of a child
140 unit, if the type of the formal is declared in a parent unit and is not
141 a formal itself, the actual must be located from an enclosing parent
142 instance by normal visibility.
144 2010-10-07 Ed Schonberg <schonberg@adacore.com>
146 * sem_ch4.adb (Analyze_Allocator): In Ada 2012, a null_exclusion
147 indicator is illegal for an uninitialized allocator.
149 2010-10-07 Robert Dewar <dewar@adacore.com>
151 * sem_prag.adb (Analyze_Attribute_Definition_Clause, case
152 Component_Size): Complete previous change.
154 2010-10-07 Vincent Celier <celier@adacore.com>
156 * scng.adb (Scan): Call Accumulate_Token_Checksum for Tok_Identifier,
157 even for keywords, to avoid having the checksum to depend on the Ada
160 2010-10-07 Gary Dismukes <dismukes@adacore.com>
162 * sem_aggr.adb, sem_ch12.adb, sem_ch6.adb, par-ch5.adb,
163 exp_ch3.adb: Minor reformatting.
165 2010-10-07 Robert Dewar <dewar@adacore.com>
167 * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case
168 Component_Size): It is now illegal to give an incorrect component size
169 clause in the case of aliased or atomic components.
170 * sem_prag.adb (Analyze_Pragma, case Pack): It is now illegal to give
171 an effective pragma Pack in the case of aliased or atomic components.
173 2010-10-07 Steve Baird <baird@adacore.com>
175 * exp_ch4.adb (Expand_N_Allocator): Do not bypass expansion
176 in the case of a violation of an active No_Task_Hierarchy restriction.
178 2010-10-07 Ed Schonberg <schonberg@adacore.com>
180 * sem_ch12.adb (Validate_Derived_Type_Instance): If a formal derived
181 type is non-limited, an actual for it cannot be limited.
183 2010-10-07 Robert Dewar <dewar@adacore.com>
185 * einfo.ads (No_Pool_Assigned): Update documentation.
186 * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case
187 Storage_Size): We only set No_Pool_Assigned if the expression is a
188 static constant and zero.
189 * sem_res.adb (Resolve_Allocator): Allocation from empty storage pool
190 should be an error not a warning.
192 2010-10-07 Ed Schonberg <schonberg@adacore.com>
194 * exp_aggr.adb (Expand_Array_Aggregate): Recognize additional cases
195 where an aggregate in an assignment can be built directly into the
196 target, and does not require the creation of a temporary that may
199 2010-10-07 Ed Schonberg <schonberg@adacore.com>
201 * sem_aggr.adb (Analyze_Record_Aggregate): In Ada2012, a choice list
202 in a record aggregate can correspond to several components of
203 anonymous access types, as long as the designated subtypes match.
205 2010-10-07 Robert Dewar <dewar@adacore.com>
207 * gnat_rm.texi, exp_util.adb, sinfo.adb, sinfo.ads, sem_ch12.adb,
208 sem.adb, gnat_ugn.texi, sem_util.ads, par-ch6.adb, targparm.ads,
209 restrict.adb, sem_ch6.adb, sem_ch6.ads, sprint.adb, i-c.ads: Change
210 spelling parametrize(d) => parameterize(d).
212 2010-10-07 Robert Dewar <dewar@adacore.com>
214 * sem_ch12.adb: Add comment.
215 * sem_ch6.adb: Minor reformatting.
217 2010-10-07 Robert Dewar <dewar@adacore.com>
219 * par-ch3.adb, par-ch6.adb, par-ch7.adb, par-ch9.adb, par-ch10.adb: Add
220 Pexp to Pf_Rec constants
221 (P_Subprogram): Expression is always enclosed in parentheses
222 * par.adb (Pf_Rec): add Pexp flag for parametrized expression
223 * sinfo.ads (N_Parametrized_Expression): Expression must be in parens
225 2010-10-07 Ed Schonberg <schonberg@adacore.com>
227 * sem_ch6.adb (Analyze_Subprogram_Specification): Implement Ada2012
228 checks on functions that return an abstract type or have a controlling
229 result whose designated type is an abstract type.
230 (Check_Private_Overriding): Implement Ada2012 checks on functions
231 declared in the private part, if an abstract type is involved.
232 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): In Ada2012,
233 reject a generic function that returns an abstract type.
234 * exp_ch5.adb (Expand_Simple_Function_Return): in Ada2012, if a
235 function has a controlling access result, check that the tag of the
236 return value matches the designated type of the return expression.
238 2010-10-07 Robert Dewar <dewar@adacore.com>
240 * par-ch6.adb: Fix error in handling of parametrized expressions.
241 * par-ch4.adb (P_Name): Allow qualified expression as name in Ada 2012
243 (P_Simple_Expression): Better message for qualified expression prefix
244 * s-crc32.adb: Minor reformatting.
245 * exp_intr.adb (Expand_Unc_Deallocation): Remove test for empty
246 storage pool (this test is moved to Sem_Intr).
247 * sem_intr.adb (Check_Intrinsic_Call): Add check for deallocation from
248 empty storage pool, moved here from Exp_Intr and made into error.
249 (Check_Intrinsic_Call): Remove assumption in generating not-null free
250 warning that the name of the instantiation is Free.
251 * sinput.adb (Tree_Read): Document use of illegal free call allowed in
253 * types.ads: Remove storage size clauses from big types (since we may
254 need to do deallocations, which are now illegal for empty pools).
256 2010-10-07 Sergey Rybin <rybin@adacore.com>
258 * gnat_ugn.texi: Add missing word.
260 2010-10-07 Robert Dewar <dewar@adacore.com>
262 * exp_util.adb (Insert_Actions): Add handling of
263 N_Parametrized_Expression.
264 * par-ch6.adb (P_Subprogram): Add parsing of parametrized expression
265 * sem.adb: Add entry for N_Parametrized_Expression
266 * sem_ch6.adb (Analyze_Parametrized_Expression): New procedure
267 * sem_ch6.ads (Analyze_Parametrized_Expression): New procedure
268 * sinfo.ads, sinfo.adb: Add N_Parametrized_Expression
269 * sprint.adb (Sprint_Node): Add handling for N_Parametrized_Expression
270 * par-ch4.adb: Minor reformatting.
272 2010-10-07 Robert Dewar <dewar@adacore.com>
274 * scng.adb (Skip_Other_Format_Characters): New procedure
275 (Start_Of_Wide_Character): New procedure
276 (Scan): Use Start_Of_Wide_Character where appropriate
277 (Scan): Improve error message for other_format chars in identifier
278 (Scan): Allow other_format chars between tokens
280 2010-10-07 Javier Miranda <miranda@adacore.com>
282 * exp_util.adb (Safe_Prefixed_Reference): When removing side effects,
283 Add missing support for explicit dereferences.
285 2010-10-07 Robert Dewar <dewar@adacore.com>
287 * par-ch10.adb, par-ch3.adb, par.adb: Minor reformatting.
289 2010-10-07 Robert Dewar <dewar@adacore.com>
291 * exp_disp.adb, exp_dist.adb, exp_util.ads, exp_util.adb,
292 exp_ch11.adb: Rename Full_Qualified_Name to Fully_Qualified_Name_String
293 * sem_util.adb, sem_util.ads (Full_Qualified_Name): Moved to
294 Exp_Util.Fully_Qualified_Name_String.
296 2010-10-07 Robert Dewar <dewar@adacore.com>
298 * rtsfind.ads: Add entry for Ada.Real_Time.Timing_Events.Set_Handler
299 * sem_res.adb (Resolve_Call): A call to
300 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
301 No_Relative_Delay (AI-0211).
303 2010-10-07 Ed Schonberg <schonberg@adacore.com>
305 * sem_ch10.adb: Small change in error message.
307 2010-10-07 Robert Dewar <dewar@adacore.com>
309 * tbuild.ads: Minor reformatting.
311 2010-10-07 Robert Dewar <dewar@adacore.com>
313 * gnatcmd.adb, make.adb, prj-nmsc.adb, sem_elab.adb: Minor reformatting
315 2010-10-07 Arnaud Charlet <charlet@adacore.com>
317 * exp_ch11.adb (Expand_N_Exception_Declaration): Update comments.
319 2010-10-07 Robert Dewar <dewar@adacore.com>
321 * sem_res.adb: Minor reformatting
323 2010-10-07 Olivier Ramonat <ramonat@adacore.com>
325 * gnat_ugn.texi: Minor editing.
326 * opt.ads: Document that scripts rely on specific formats in opt.ads
328 2010-10-07 Robert Dewar <dewar@adacore.com>
330 * a-wichun.ads, a-wichun.adb (To_Lower_Case): New function
331 (To_Upper_Case): Fix to be inverse of To_Lower_Case
332 * a-zchuni.ads, a-zchuni.adb (To_Lower_Case): New function
333 (To_Upper_Case): Fix to be inverse of To_Lower_Case
335 2010-10-07 Robert Dewar <dewar@adacore.com>
337 * a-wichha.adb, a-wichha.ads, a-zchhan.adb, a-zchhan.ads: New file.
338 * impunit.adb: Add entries for a-wichha/a-zchhan
339 * Makefile.rtl: Add entries for a-wichha/a-zchhan
341 2010-10-07 Vincent Celier <celier@adacore.com>
343 * make.adb (Check): Call Check_Source_Info_In_ALI with Project_Tree
344 * makeutl.adb (Check_Source_Info_In_ALI): If there is at least one
345 replaced source, check that none of the replaced sources are in the
347 * makeutl.ads (Check_Source_Info_In_ALI): New parameter Tree
348 * prj-nmsc.adb (Remove_Source): New parameter Tree. If the source is
349 replaced with a source with a different file name, put it in the hash
350 table Replaced_Sources.
351 (Add_Source): Call Remove_Source with Data.Tree. If there is at least
352 one replaced source, check if it has the same file name as the current
353 source; if it has, remove it from the hash table Replaced_Sources.
354 * prj.adb (Reset): Reset hash table Tree.Replaced_Sources
355 * prj.ads (Replaced_Source_HTable): New hash table
356 (Project_Tree_Data): New components Replaced_Sources and
357 Replaced_Source_Number.
359 2010-10-07 Ed Schonberg <schonberg@adacore.com>
361 * sem_elab.adb (Check_A_Call): After inserting elaboration check, set
362 proper flag to prevent a double elaboration check on the same call.
363 * exp_util.adb (Insert_Actions): If the enclosing node is an
364 Expression_With_Actions and it has been analyzed already, find
365 insertion point further up in the tree.
367 2010-10-07 Hristian Kirtchev <kirtchev@adacore.com>
369 * sem_ch13.adb (Analyze_Record_Representation_Clause): Alphabetize all
370 local variables. Remove the general restriction which prohibits the
371 application of record rep clauses to Unchecked_Union types. Add Ada
372 2012 check to detect improper naming of an Unchecked_Union
373 discriminant in record rep clause.
374 * sem_prag.adb: Add with and use clause for Exp_Ch7.
375 (Analyze_Pragma): Unchecked_Union case: Propagate the Unchecked_Union
376 type to all invocations of Check_Component and Check_Variant.
377 (Check_Component): Add formal parameters UU_Typ and In_Variant_Part.
378 Rewritten. Add Ada 2012 check to detect improper use of formal
379 private types and private extensions as component types of an
380 Unchecked_Union declared inside a generic body.
381 (Check_Variant): Add formal parameter UU_Typ. Propagate the
382 Unchecked_Union type to all calls of Check_Component. Signal that the
383 current component comes from the variant part of an Unchecked_Union
385 (Inside_Generic_Body): New routine.
387 2010-10-07 Ed Schonberg <schonberg@adacore.com>
389 * exp_ch4.adb (Expand_Composite_Equality): When looking for a primitive
390 equality operation for a record component, verify that both formals
391 have the same type, and the result type is boolean.
393 2010-10-07 Vincent Celier <celier@adacore.com>
395 * gnatcmd.adb (Check_Files): When looking for the .ci file for a
396 binder generated file, look for both b~xxx and b__xxx as gprbuild
397 always uses b__ as the prefix of such files.
399 2010-10-07 Thomas Quinot <quinot@adacore.com>
401 * sem_res.adb: Minor reformatting.
403 2010-10-07 Arnaud Charlet <charlet@adacore.com>
405 * debug.adb: Update -gnatd.J documentation.
407 2010-10-07 Robert Dewar <dewar@adacore.com>
409 * gnat_rm.texi: Document handling of invalid values
410 * s-utf_32.ads, s-utf_32.adb (UTF_To_Lower_Case): Fix implementation
412 (UTF_To_Upper_Case): New function.
414 2010-10-07 Robert Dewar <dewar@adacore.com>
416 * sem_attr.adb: Minor reformatting.
417 * einfo.ads, einfo.adb (Is_Ada_2012_Only): New flag
418 * itypes.adb (Create_Null_Excluding_Itype): Set Is_Ada_2012_Only flag
420 * lib-xref.adb (Generate_Reference): Warn on use of Ada 2012 entity in
422 * opt.ads (Warn_On_Ada_2012_Compatibility): New flag
423 * sem_ch3.adb (Analye_Subtype_Declaration): Inherit Is_Ada_2012_Only
424 * sem_ch7.adb (Preserve_Full_Attributes): Preserve Is_Ada_2012_Only
426 * sem_prag.adb (Analyze_Pragma, case Ada_12/Ada_2012): Allow form with
428 * sem_type.adb (Disambiguate): Deal with Is_Ada_2012_Only.
429 * sem_warn.adb (Warn_On_Ada_2012_Compatibility): New flag, treated
432 2010-10-07 Javier Miranda <miranda@adacore.com>
434 * a-tags.ads: Use new support for pragma Ada_2012 with function
437 2010-10-07 Ed Schonberg <schonberg@adacore.com>
439 * par-ch5.adb (P_Sequence_Of_Statements): In Ada2012 a label can end a
440 sequence of statements.
442 2010-10-07 Vincent Celier <celier@adacore.com>
444 * gnatcmd.adb (Check_Files): Only add a .ci files if it exists
446 2010-10-07 Javier Miranda <miranda@adacore.com>
448 * a-tags.ads, a-tags.adb (Type_Is_Abstract): New subprogram.
449 * rtsfind.ads (RE_Type_Is_Abstract): New entity.
450 * exp_disp.adb (Make_DT): Initialize TSD component Type_Is_Abstract.
452 2010-10-07 Arnaud Charlet <charlet@adacore.com>
454 * sem_ch12.adb (Mark_Context): Removed, no longer needed.
455 (Analyze_Package_Instantiation): No longer analyze systematically a
456 generic body in CodePeer mode.
457 * freeze.adb, sem_attr.adb: Update comments.
459 2010-10-05 Robert Dewar <dewar@adacore.com>
461 * par-ch5.adb (Test_Statement_Required): Allow all pragmas in Ada 2012
464 2010-10-05 Pascal Obry <obry@adacore.com>
466 * gnat_rm.texi: Fix typo.
468 2010-10-05 Arnaud Charlet <charlet@adacore.com>
470 * gnat_ugn.texi: Add note about identifiers with same name and
473 2010-10-05 Robert Dewar <dewar@adacore.com>
475 * sem_ch4.adb: Minor reformatting.
476 * a-direct.ads: Minor comment update.
478 2010-10-05 Javier Miranda <miranda@adacore.com>
480 * sem_ch3.adb (Add_Internal_Interface_Entities): Removing code that is
481 no longer required after change in New_Overloaded_Entity.
482 * sem_ch6.adb (New_Overloaded_Entity): Code reorganization to isolate
483 the fragment of code that handles derivations of interface primitives.
484 Add missing dependence on global variable Inside_Freezing_Actions to
485 ensure the correct management of internal interface entities.
486 * sem_ch13.adb (Analyze_Freeze_Entity): Add missing increase/decrease
487 of the global variable Inside_Freezing_Actions to ensure that internal
488 interface entities are well handled by New_Overloaded_Entity.
489 * sem_disp.adb (Find_Primitive_Covering_Interface): Add documentation
490 and complete the algorithm to catch hidden primitives derived of
491 private type that covers the interface.
492 * sem_disp.ads (Find_Primitive_Covering_Interface): Add missing
495 2010-10-05 Robert Dewar <dewar@adacore.com>
497 * prj-util.adb, prj-util.ads, prj.ads, s-vxwext-rtp.adb, sem_ch4.adb,
498 sem_ch7.adb, sem_res.adb, sem_type.adb: Minor reformatting.
499 Minor code reorganization (use Nkind_In).
501 2010-10-05 Ed Schonberg <schonberg@adacore.com>
503 * sem_ch10.adb (Analyze_Task_Body_Stub): Diagnose duplicate stub for
506 2010-10-05 Vincent Celier <celier@adacore.com>
508 * gnatbind.adb: If the main library file is not for a suitable main
509 program, change the error message.
511 2010-10-05 Vincent Celier <celier@adacore.com>
513 * a-direct.ads: Minor spelling error fixes in comments.
514 * gnat_rm.texi: Add three entries in "Implementation Defined
515 Characteristics" for the interpretations of the Form parameters in
518 2010-10-05 Robert Dewar <dewar@adacore.com>
520 * exp_ch3.adb, exp_ch5.adb, exp_disp.adb, exp_dist.adb, gnatlink.adb,
521 makeutl.adb, par-ch6.adb, prj-dect.adb, prj-env.adb, prj-env.ads,
522 prj-ext.adb, prj-nmsc.adb, prj-part.adb, prj-pp.ads: Minor code
526 2010-10-05 Ed Schonberg <schonberg@adacore.com>
528 * sem_res.adb (Check_Parameterless_Call): If the prefix of 'Address is
529 an explicit dereference of an access to function, the prefix is not
530 interpreted as a parameterless call.
532 2010-10-05 Ed Schonberg <schonberg@adacore.com>
534 * exp_attr.adb: For 'Read and 'Write, use full view of base type if
537 2010-10-05 Vincent Celier <celier@adacore.com>
539 * make.adb (Switches_Of): Allow wild cards in index of attributes
541 * prj-util.adb (Value_Of): When Allow_Wildcards is True, use the index
542 of the associative array as a glob regular expression.
543 * prj-util.ads (Value_Of (Index, In_Array)): New Boolean parameter
544 Allow_Wildcards, defaulted to False.
545 (Value_Of (Name, Attribute_Or_Array_Name)): Ditto
546 * projects.texi: Document that attribute Switches (<file name>) may
547 use wild cards in the index.
549 2010-10-05 Robert Dewar <dewar@adacore.com>
551 * a-direct.adb, a-direct.ads, back_end.adb, checks.adb,
552 einfo.adb: Minor reformatting.
553 * debug.adb: Remove obsolete documentation for d.Z flag.
555 2010-10-05 Vincent Celier <celier@adacore.com>
557 * vms_data.ads: Add VMS qualifier /SRC_INFO= corresponding to gnatmake
558 switch --create-info-file=.
559 * gnat_ugn.texi: Add documentation for new gnatmake switch
562 2010-10-05 Ed Schonberg <schonberg@adacore.com>
564 * sem_ch3.adb: Do not elaborate type definition if syntax error.
566 2010-10-05 Javier Miranda <miranda@adacore.com>
568 * sprint.adb (Sprint_Node_Actual): Improve output of subprogram bodies
569 to generate the full-qualified names of its corresponding spec.
570 This facilitates locating the corresponing body when reading
573 2010-10-05 Thomas Quinot <quinot@adacore.com>
575 * exp_dist.adb (Make_Helper_Function_Name): For a tagged type, use
576 canonical name without serial number only if the helper is becoming a
577 primitive of the type.
579 2010-10-05 Javier Miranda <miranda@adacore.com>
581 * exp_disp.adb (Make_DT): Minor code reorganization.
583 2010-10-05 Ed Schonberg <schonberg@adacore.com>
585 * par-ch6.adb: improve recovery with extra paren in function spec.
587 2010-10-05 Quentin Ochem <ochem@adacore.com>
589 * prj-tree.ads: Project_Path is now aliased.
591 2010-10-05 Thomas Quinot <quinot@adacore.com>
593 * checks.adb: Minor reformatting.
595 2010-10-05 Eric Botcazou <ebotcazou@adacore.com>
597 * mlib-tgt-specific-mingw.adb (No_Argument_List): Delete.
598 (Shared_Libgcc): New aliased variable.
599 (Shared_Libgcc_Switch): New constant.
600 (Build_Dynamic_Library): Pass Shared_Libgcc_Switch to the compiler
601 * gcc-interface/Makefile.in (gnatlib-shared-win32): Pass -shared-libgcc
603 * gcc-interface/Make-lang.in: Update dependencies.
605 2010-10-05 Vincent Celier <celier@adacore.com>
607 * prj-part.adb (Parse_Simple_Project): When checking if a child project
608 imports its parent project, also look in projects being extended by
611 2010-10-05 Eric Botcazou <ebotcazou@adacore.com>
613 * gnat_ugn.texi: Adjust instructions in G.10 Building DLLs with GNAT.
615 2010-10-05 Javier Miranda <miranda@adacore.com>
617 * exp_cg.adb (Slot_Number): Add support to handle aliased entities.
618 (Generate_CG_Output): Switch -gnatd.Z is no longer needed to
619 activate this output.
621 2010-10-05 Arnaud Charlet <charlet@adacore.com>
623 * back_end.adb (Call_Back_End): Generate an error message when scil
624 generation is enabled, and no scil back-end (by default) is available.
626 2010-10-05 Javier Miranda <miranda@adacore.com>
628 * debug.adb: Update documentation because -gnatd.Z is no longer required
629 to generate the call-graph information.
631 2010-10-05 Javier Miranda <miranda@adacore.com>
633 * exp_ch5.adb (Expand_Simple_Function_Return): Rewrite expansion of a
634 runtime access check by an equivalent expansion that causes
635 no problems in the VM backend. The original expansion was
636 not good for the VM backends because when Tagged_Type_Expansion
637 is disabled the attribute Access_Disp_Table is not available.
639 2010-10-05 Ed Schonberg <schonberg@adacore.com>
641 * sem_type.adb (Covers): In a dispatching context, T1 covers T2 if T2
642 is class-wide and T1 is its specific type.
644 2010-10-05 Ed Schonberg <schonberg@adacore.com>
646 * einfo.adb: Add guard to Is_String_Type to prevent cascaded errors.
648 2010-10-05 Vincent Celier <celier@adacore.com>
650 * back_end.ads: Minor spelling error correction.
652 2010-10-05 Arnaud Charlet <charlet@adacore.com>
654 * switch-c.adb, gnat1drv.adb (Scan_Front_End_Switches): Disable
655 warnings when -gnatC is specified here so that warnings can be
656 re-enabled explicitly.
657 (Adjust_Global_Switches): No longer suppress warnings.
659 2010-10-05 Vincent Celier <celier@adacore.com>
661 * makeutl.adb: Minor reformatting.
663 2010-10-05 Ed Schonberg <schonberg@adacore.com>
665 * sem_ch4.adb: add guard in Analyze_One_Call to prevent crash when a
666 non-discrete type appears as an actual in a call.
668 2010-10-05 Vincent Celier <celier@adacore.com>
670 * make.adb (Scan_Make_Arg): Take into account new switch
672 * makeusg.adb: Add line for new switch --source-info=file.
673 * makeutl.ads (Source_Info_Option): New constant String for new builder
675 * prj-conf.adb: Put subprograms in alphabetical order
676 (Process_Project_And_Apply_Config): Read/write an eventual source info
678 * prj-nmsc.adb (Look_For_Sources.Get_Sources_From_Source_Info): New
680 (Look_For_Sources): If a source info file was successfully read, get the
681 source data from the data read from the source info file.
682 * prj-util.adb (Source_Info_Table): New table
683 (Source_Info_Project_HTable): New hash table
684 (Create): New procedure
685 (Put (File), Put_Line): New procedures
686 (Write_Source_Info_File): New procedure
687 (Read_Source_Info_File): New procedure
688 (Initialize): New procedure
689 (Source_Info_Of): New procedure
690 (Next): New procedure
691 (Close): When file is an out file, fail if the buffer cannot be written
692 or if the file cannot be close successfully.
693 (Get_Line): Fail if file is an out file
694 * prj-util.ads (Create): New procedure
695 (Put (File), Put_Line): New procedures
696 (Write_Source_Info_File): New procedure
697 (Read_Source_Info_File): New procedure
698 (Source_Info_Data): New record type
699 (Source_Info_Iterator): New private type
700 (Initialize): New procedure
701 (Source_Info_Of): New procedure
702 (Next): New procedure
703 * prj.ads (Project_Tree_Data): New components Source_Info_File_Name and
704 Source_Info_File_Exists.
706 2010-10-05 Ed Schonberg <schonberg@adacore.com>
708 * exp_ch4.adb: Fix typo.
710 2010-10-05 Thomas Quinot <quinot@adacore.com>
712 * lib-writ.adb: Minor reformatting.
714 2010-10-05 Javier Miranda <miranda@adacore.com>
716 * sem_ch3.adb (Access_Definition): Remove useless code.
718 2010-10-05 Emmanuel Briot <briot@adacore.com>
720 * prj-env.adb, prj-env.ads (Set_Path): New subprogram.
721 (Deep_Copy): Removed, not used.
723 2010-10-05 Javier Miranda <miranda@adacore.com>
725 * sem_ch3.adb (Add_Internal_Interface_Entities): Code reorganization:
726 move code that searches in the list of primitives of a tagged type for
727 the entity that will be overridden by user-defined routines.
728 * sem_disp.adb (Find_Primitive_Covering_Interface): Move here code
729 previously located in routine Add_Internal_Interface_Entities.
730 * sem_disp.ads (Find_Primitive_Covering_Interface): Update documentation
731 * sem_ch6.adb (New_Overloaded_Entity): Add missing check on
732 availability of attribute Alias.
734 2010-10-05 Ed Falis <falis@adacore.com>
736 * s-taprop-vxworks.adb, s-osinte-vxworks.adb, s-osinte-vxworks.ads,
737 s-vxwext.ads, s-vxwext-kernel.ads, s-vxwext-rtp.adb, s-vxwext-rtp.ads:
738 Move definition of intContext to System.OS_Interface.
739 Add necessary variants in System.VxWorks.Extensions.
741 2010-10-05 Doug Rupp <rupp@adacore.com>
743 * s-asthan-vms-alpha.adb: On VMS, a task using
744 pragma AST_Entry exhibits a memory leak when the task terminates
745 because the vector allocated for the AST interface is not freed. Fixed
746 by making the vector a controlled type.
748 2010-10-05 Emmanuel Briot <briot@adacore.com>
750 * prj-nmsc.adb (Expand_Subdirectory_Pattern): Check that the prefix in
751 a "**" pattern properly exists, and report an error otherwise.
753 2010-10-05 Emmanuel Briot <briot@adacore.com>
755 * prj-env.ads: Use GNAT.OS_Lib rather than System.OS_Lib.
757 2010-10-05 Emmanuel Briot <briot@adacore.com>
759 * prj-nmsc.adb, prj-err.adb (Expand_Subdirectory_Pattern): New
761 Extract some code from Get_Directories, to share with the handling
762 of aggregate projects (for the Project_Files attributes)
764 2010-10-05 Emmanuel Briot <briot@adacore.com>
766 * gnatcmd.adb, prj-proc.adb, prj-part.adb, prj-ext.adb, prj-ext.ads,
767 switch-m.adb, clean.adb, prj-nmsc.adb, prj-nmsc.ads, prj-env.adb,
768 prj-env.ads, prj-tree.adb, prj-tree.ads (Project_Search_Path): New type.
770 2010-10-05 Eric Botcazou <ebotcazou@adacore.com>
772 * exp_ch5.adb (Make_Field_Expr): Revert previous change (removed).
774 2010-10-05 Emmanuel Briot <briot@adacore.com>
776 * prj-dect.adb, prj-nmsc.adb, prj-attr.adb, snames.ads-tmpl
777 (Aggregate projects): added support for parsing aggregate projects.
778 In particular, check the presence and value of the new attributes
779 related to aggregate projects, ie Project_Files, Project_Path
781 (Check_Attribute_Allowed, Check_Package_Allowed,
782 Rename_Obsolescent_Attributes): new subprogram, extracting code
783 from existing subprogram to keep their sizes smaller.
784 (Check_Aggregate_Project, Check_Abstract_Project,
785 Check_Missing_Sources): new subprograms
786 (Check): remove comments that duplicated either the name of the
787 following subprogram call, or the comment on that subprogram.
788 * prj-part.adb (Check_Extending_All_Imports): New subprogram, extracted
789 from Parse_Single_Project.
790 (Check_Aggregate_Imports): new subprogram.
792 2010-10-05 Vincent Celier <celier@adacore.com>
794 * make.adb (Check): When compiling with -gnatc, recompile if the ALI
795 file has not been generated for the current source, for example if it
796 has been generated for the spec, but we are compiling the body.
798 2010-10-05 Bob Duff <duff@adacore.com>
800 * xgnatugn.adb: Remove unused procedure.
802 2010-10-04 Vincent Celier <celier@adacore.com>
804 * a-direct.adb (Copy_File): Interpret the Form parameter and call
805 System.OS_Lib.Copy_File to do the work accordingly. Raise Use_Error if
806 the Form parameter contains an incorrect value for field preserve= or
808 * a-direct.ads (Create_Directory, Create_Path): Indicate that the Form
809 parameter is ignored.
810 (Copy_File): Indicate the interpretation of the Form parameter.
812 2010-10-04 Vincent Celier <celier@adacore.com>
814 * make.adb (Gnatmake): When there are no foreign languages declared and
815 a main in attribute Main of the main project does not exist or is a
816 source of another project, fail immediately before attempting
819 2010-10-04 Javier Miranda <miranda@adacore.com>
821 * exp_disp.ads (Convert_Tag_To_Interface): New function which must be
822 used to convert a node referencing a tag to a class-wide interface type.
823 * exp_disp.adb (Convert_Tag_To_Interface): New function.
824 (Expand_Interface_Conversion): Replace invocation of
825 Unchecked_Conversion by new function Convert_Tag_To_Interface.
826 (Write_DT): Add support for null primitives.
827 * exp_ch3.adb (Expand_N_Object_Declaration): For tagged type objects,
828 cleanup code that handles interface conversions and avoid unchecked
829 conversion of referenced tag components.
830 * exp_ch5.adb (Expand_N_Assignment_Statement): Code cleanup. Avoid
831 unrequired conversions when generating a dispatching call to _assign.
832 * sprint.adb (Write_Itype): Fix wrong output of not null access itypes.
834 2010-10-04 Ed Schonberg <schonberg@adacore.com>
836 * exp_ch4.adb (Expand_N_Op_Not): Handle properly both operands when the
837 parent is a binary boolean operation and the operand is an unpacked
839 (Build_Boolean_Array_Proc_Call): If the operands are both negations, the
840 operands of the rewritten node are the operands of the negations, not
841 the negations themselves.
843 2010-10-04 Robert Dewar <dewar@adacore.com>
845 * sem_ch13.adb (Set_Biased): New procedure, now used throughout, adds
846 name of entity to biased warning msg.
847 (Analyze_Enumeration_Representation_Clause): Remove attempt to use
848 biased rep (wrong and never worked anyway).
850 2010-10-04 Arnaud Charlet <charlet@adacore.com>
852 * sem_elab.adb: Minor reformatting.
854 2010-10-04 Ed Schonberg <schonberg@adacore.com>
856 * exp_ch4.adb (Expand_N_Null): Handle properly the case of a subtype of
857 an access_to_protected subprogram type, and convert null value into
858 corresponding aggregate.
860 2010-10-04 Eric Botcazou <ebotcazou@adacore.com>
862 * gnat_ugn.texi: Clarify first point of 7.1.5 about pragma Inline.
864 2010-10-04 Eric Botcazou <ebotcazou@adacore.com>
866 * make.adb (Scan_Make_Arg): Pass -Oxxx switches to the linker as well.
867 * gnatlink.adb (Gnatlink): Filter out -Oxxx switches for CLI, RTX and
870 2010-10-04 Eric Botcazou <ebotcazou@adacore.com>
872 * sem_ch4.adb (Analyze_Indexed_Component_Form): Remove redundant test
873 for N_Operator_Symbol.
874 (Indicate_Name_And_Type): Likewise.
875 * sem_ch8.adb (Analyze_Subprogram_Renaming): Likewise.
876 * sem_res.adb (Resolve): Likewise.
877 * sem_type.adb (Add_One_Interp): Likewise.
878 (Disambiguate): Likewise.
880 2010-10-04 Vincent Celier <celier@adacore.com>
882 * osint.adb (Read_Library_Info_From_Full): If object timestamp is less
883 than ALI file timestamp, return null.
885 2010-10-04 Vincent Celier <celier@adacore.com>
887 * prj-makr.adb (Finalize): Invoke Pretty_Print with Max_Length set to 79
888 * prj-pp.adb (Pretty_Print): New parameter Max_Line_Length, that
889 replaces global constant with the same name. When a line is too long,
890 indent properly the next continuation line.
891 * prj-pp.ads (Pretty_Print): New parameter Max_Line_Length with a range
892 from 50 to 255, defaulted to 255, to indicate the maximum length of
893 lines in the project file.
895 2010-10-04 Eric Botcazou <ebotcazou@adacore.com>
897 * sem_ch7.adb (Analyze_Package_Body_Helper) <Has_Referencer>: New
898 Check_Subprogram_Ref function and Check_Subprogram_Refs instantiation
899 of Traverse_Func on it to look for subprogram references in a body.
900 Call Check_Subprogram_Refs on the body of inlined subprograms at the
901 outer level and keep clearing the Is_Public flag of subprograms as long
902 as it returns OK. Do not look at anything else than subprograms once
903 an inlined subprogram has been seen.
905 2010-10-04 Javier Miranda <miranda@adacore.com>
907 * exp_cg.adb (Expand_N_Assignment_Statement): Restore tag check when
908 the target object is an interface.
909 * sem_disp.adb (Propagate_Tag): If the controlling argument is an
910 interface type then we generate an implicit conversion to force
911 displacement of the pointer to the object to reference the secondary
912 dispatch table associated with the interface.
914 2010-10-04 Robert Dewar <dewar@adacore.com>
916 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Set
917 Enumeration_Rep_Expr to point to the literal, not the identifier.
918 (Analyze_Enumeration_Representation_Clause): Improve error message for
919 size too small for enum rep value
920 (Analyze_Enumeration_Representation_Clause): Fix size test to use proper
921 size (RM_Size, not Esize).
923 2010-10-04 Robert Dewar <dewar@adacore.com>
925 * s-taprop-vxworks.adb, sem_res.adb: Minor reformatting.
927 2010-10-04 Javier Miranda <miranda@adacore.com>
929 * exp_cg.adb (Write_Call_Info): Code clean up.
931 2010-10-04 Arnaud Charlet <charlet@adacore.com>
933 * s-taprop-mingw.adb (Create_Task): Initialize Thread_Id field to 0.
935 2010-10-04 Robert Dewar <dewar@adacore.com>
937 * exp_cg.adb: Minor code reorganization
939 * exp_ch5.adb, prj-nmsc.adb: Minor reformatting.
941 2010-10-04 Bob Duff <duff@adacore.com>
943 * sem_res.adb (Resolve_Type_Conversion): If a type conversion is needed
944 to make a qualified expression into a name (syntax-wise), then do not
945 consider it redundant.
947 2010-10-04 Thomas Quinot <quinot@adacore.com>
949 * sem_warn.ads: Fix typo.
951 2010-10-04 Javier Miranda <miranda@adacore.com>
953 * exp_cg.adb (Is_Predefined_Dispatching_Operation): Handle suffix in
955 (Write_Call_Info): Add missing support for renamed primitives.
957 2010-10-04 Thomas Quinot <quinot@adacore.com>
959 * exp_ch5.adb (Make_Field_Expr): New subprogram, to factor duplicated
960 code between Make_Component_List_Assign and Make_Field_Assign.
962 2010-10-04 Vincent Celier <celier@adacore.com>
964 * prj-nmsc.adb (Get_Directories): For non extending projects that
965 declare that they have no sources, do not create a non existing object
966 or exec directory if builder switch -p is used.
968 2010-10-04 Sergey Rybin <rybin@adacore.com>
970 * gnat_ugn.texi (gnatcheck): Change the description of the report file
973 2010-10-04 Ed Falis <falis@adacore.com>
975 * s-taprop-vxworks.adb (Is_Task_Context): Import VxWorks intContext to
976 determine whether Set_True is called from a task or an ISR.
977 (Set_True): test for being in a task context before trying to
978 dereference Defer_Abort or Undefer_Abort.
980 2010-10-04 Robert Dewar <dewar@adacore.com>
982 * sem_res.adb, sinput-l.adb: Minor reformatting.
984 2010-10-04 Hristian Kirtchev <kirtchev@adacore.com>
986 * exp_ch5.adb (Expand_N_Assignment_Statement): Do not generate a tag
987 check when the target object is an interface since the expression of
988 the right hand side must only cover the interface.
990 2010-10-04 Vincent Celier <celier@adacore.com>
992 * frontend.adb: Set Lib.Parsing_Main_Extended_Source to True before
993 loading the main source, so that if it is preprocessed and -gnateG is
994 used, the preprocessed file is written.
995 * lib.ads (Analysing_Subunit_Of_Main): New global variable to indicate
996 if a subunit is from the main unit when it is loaded.
997 * sem_ch10.adb (Analyze_Proper_Body): Set Lib.Analysing_Subunit_Of_Main
998 to True before loading a subunit.
999 * sem_ch12.adb (Copy_Generic_Node): Set Lib.Analysing_Subunit_Of_Main
1000 to True when the main is a generic unit before loading one of its
1002 * sinput-l.adb (Load_File): If -gnateG is used, write the preprocessed
1003 file only for the main unit (spec, body and subunits).
1005 2010-10-04 Vincent Celier <celier@adacore.com>
1007 * sinput-l.adb (Load_File): Do not fail when switch -gnateG is
1008 specified and the processed file cannot be written. Just issue a
1009 warning and continue.
1011 2010-10-04 Thomas Quinot <quinot@adacore.com>
1013 * sem_res.adb: Minor reformatting.
1015 2010-10-04 Ed Schonberg <schonberg@adacore.com>
1017 * sem_ch8.adb (Analyze_Subprogram_Renaming): If the renamed operation
1018 is an overridden inherited operation, the desired operation is the
1019 overriding one, which is the alias of the visible one.
1021 2010-10-04 Ed Schonberg <schonberg@adacore.com>
1023 * sem_ch6.adb (Find_Corresponding_Spec): Check that the wrapper body is
1024 present before deleting from the tree, when an inherited function with
1025 a controlling result that returns a null extension is overridden by a
1026 later declaration or body.
1028 2010-10-04 Gary Dismukes <dismukes@adacore.com>
1030 * checks.adb: Update comment.
1032 2010-09-30 Joseph Myers <joseph@codesourcery.com>
1034 * gcc-interface/misc.c (optimize, optimize_size): Undefine as macros
1035 and define as variables.
1036 (gnat_post_options): Set optimize and optimize_size variables.
1038 2010-09-29 Joel Sherrill <joel.sherrill@oarcorp.com>
1040 * g-socket.adb: Move pragma to disable warnings in case multiple errnos
1041 are not defined by target.
1043 2010-09-29 Eric Botcazou <ebotcazou@adacore.com>
1045 * gcc-interface/utils.c (handle_leaf_attribute): Fix long line.
1047 2010-09-28 Richard Henderson <rth@redhat.com>
1049 * gcc-interface/misc.c (gnat_eh_personality): Use
1050 targetm.except_unwind_info.
1052 2010-09-28 Jan Hubicka <jh@suse.cz>
1054 * gcc-interface/utils.c (handle_leaf_attribute): New function.
1055 (gnat_internal_attribute_tables): Add leaf.
1057 2010-09-22 Joseph Myers <joseph@codesourcery.com>
1059 * gcc-interface/lang.opt (-all-warnings, -include-barrier,
1060 -include-directory, -include-directory=, -no-standard-includes,
1061 -no-standard-libraries): New.
1063 2010-09-20 Eric Botcazou <ebotcazou@adacore.com>
1065 * gcc-interface/decl.c (gnat_to_gnu_entity): Replace calls to
1066 build_array_type with calls to build_nonshared_array_type.
1067 (substitute_in_type): Likewise.
1068 * gcc-interface/misc.c (LANG_HOOKS_HASH_TYPES): Delete.
1069 (LANG_HOOKS_TYPE_HASH_EQ): Define.
1070 (gnat_post_options): Add 'static' keyword.
1071 (gnat_type_hash_eq): New static function.
1072 * gcc-interface/utils.c (fntype_same_flags_p): New function.
1073 (create_subprog_type): Call it.
1074 (create_index_type): Call build_nonshared_range_type and tidy up.
1075 (create_range_type): Likewise.
1076 * gcc-interface/gigi.h (fntype_same_flags_p): Declare.
1078 2010-09-19 Eric Botcazou <ebotcazou@adacore.com>
1080 * gcc-interface/trans.c (gnat_pushdecl): Do not do anything special
1082 (end_subprog_body): If the body is a BIND_EXPR, make its associated
1083 block the top-level one.
1084 (build_function_stub): Build a statement group for the whole function.
1085 * gcc-interface/utils.c (Subprogram_Body_to_gnu): If copy-in/copy-out
1086 is used, create the enclosing block early and process first the OUT
1089 2010-09-19 Eric Botcazou <ebotcazou@adacore.com>
1091 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Enumeration_Type>: Do
1092 not generate debug info for individual enumerators.
1094 2010-09-19 Eric Botcazou <ebotcazou@adacore.com>
1096 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Use record
1097 type instead of enumeral type as the dummy type built for the template
1098 type of fat pointers.
1100 2010-09-19 Eric Botcazou <ebotcazou@adacore.com>
1102 * gcc-interface/gigi.h (get_elaboration_procedure): Declare.
1103 (gnat_zaplevel): Likewise.
1104 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force global
1105 binding level for an external constant.
1106 <E_Constant>: Force the local context and create a fake scope before
1107 translating the defining expression of an external constant.
1108 <object>: Treat external constants at the global level explicitly for
1109 renaming declarations.
1110 (elaborate_expression_1): Force the variable to be static if the
1111 expression is global.
1112 * gcc-interface/trans.c (get_elaboration_procedure): New function.
1113 (call_to_gnu): Use it.
1114 (gnat_to_gnu): Likewise.
1115 <N_Object_Declaration>: Do not test Is_Public to force the creation of
1116 an initialization variable.
1117 (add_decl_expr): Discard the statement if the declaration is external.
1118 * gcc-interface/utils.c (gnat_pushdecl): Do not put the declaration in
1119 the current block if it is external.
1120 (create_var_decl_1): Do not test Is_Public to set TREE_STATIC.
1121 (gnat_zaplevel): New global function.
1123 2010-09-19 Eric Botcazou <ebotcazou@adacore.com>
1125 * gcc-interface/decl.c (gnat_to_gnu_entity): Explicitly test _LEVEL
1126 variables against zero in all cases.
1127 (rest_of_type_decl_compilation): Likewise.
1128 * gcc-interface/trans.c (gigi): Pass properly typed constants to
1130 (call_to_gnu): Fix formatting.
1131 (Handled_Sequence_Of_Statements_to_gnu): Likewise.
1132 (Exception_Handler_to_gnu_zcx): Likewise.
1133 (gnat_to_gnu) <N_Object_Declaration>: Short-circuit handling of
1135 expressions in presence of a freeze node.
1137 2010-09-19 Eric Botcazou <ebotcazou@adacore.com>
1139 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Constant>: Look into
1140 expressions for external constants that are aggregates.
1141 * gcc-interface/utils2.c (build_simple_component_ref): If the field
1142 is an inherited component in an extension, look through the extension.
1144 2010-09-10 Vincent Celier <celier@adacore.com>
1146 * projects.texi: Add documentation for package extensions
1147 Add some documentation for attributes Leading_Library_Options and
1148 Linker'Leading_Switches.
1150 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1152 * exp_util.adb (Expand_Subtype_From_Expression): When expansion is
1153 disabled, compute subtype for all string types.
1155 2010-09-10 Robert Dewar <dewar@adacore.com>
1157 * gnat_ugn.texi: Add documentation for -gnatw.s/S
1158 * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case
1159 Component_Size): Implement warning on overriden size clause.
1160 (Analyze_Record_Representation_Clause): Implement warning on overriden
1162 * sem_warn.ads, sem_warn.adb (Warn_On_Overridden_Size): New flag
1164 * ug_words: Add entries for -gnatw.s/S.
1165 * vms_data.ads, usage.adb: Add line for -gnatw.s/-gnatw.S.
1166 * gcc-interface/Make-lang.in: Update dependencies.
1168 2010-09-10 Vincent Celier <celier@adacore.com>
1170 * prj-dect.adb (Parse_Package_Declaration): Allow a package to extend
1171 a package with the same name from an imported or extended project.
1172 * prj-proc.adb (Process_Declarative_Items): Process package extensions
1174 2010-09-10 Bob Duff <duff@adacore.com>
1176 * exp_ch6.adb (Expand_Call): Do not perform a null_exclusion check on
1179 2010-09-10 Robert Dewar <dewar@adacore.com>
1181 * sem.adb: Minor reformatting.
1183 2010-09-10 Bob Duff <duff@adacore.com>
1185 * s-os_lib.ads, g-expect.ads: Add comments.
1187 2010-09-10 Robert Dewar <dewar@adacore.com>
1189 * exp_ch5.adb: Minor reformatting.
1191 2010-09-10 Thomas Quinot <quinot@adacore.com>
1193 * scos.ads: Add comments.
1195 2010-09-10 Vincent Celier <celier@adacore.com>
1197 * gnatcmd.adb (Get_Closure): Remove useless invocation of Close.
1199 2010-09-10 Hristian Kirtchev <kirtchev@adacore.com>
1201 * exp_ch7.adb, exp_ch6.adb (Expand_Call): Establish a transient scope
1202 for a controlled build-in-place function call which appears in an
1203 anonymous context. The transient scope ensures that the intermediate
1204 function result is cleaned up after the master is left.
1205 (Make_Build_In_Place_Call_In_Anonymous_Context): Remove the creation
1206 of the transient scope. This is now done in Exand_Call which covers
1207 additional cases other than secondary stack release.
1209 2010-09-10 Arnaud Charlet <charlet@adacore.com>
1211 * sem.adb (Do_Unit_And_Dependents): Add guard.
1213 2010-09-10 Robert Dewar <dewar@adacore.com>
1215 * exp_ch5.adb: Update comments.
1216 * exp_dist.adb: Minor reformatting.
1218 2010-09-10 Robert Dewar <dewar@adacore.com>
1220 * sem_ch13.adb (Check_Record_Representation_Clause): Implement record
1222 * sem_warn.ads, sem_warn.adb (Warn_On_Record_Holes): New warning flag.
1223 * usage.adb: Add lines for -gnatw.h/H
1224 * gnat_ugn.texi: Add documentation for J519-010
1225 Warn on record holes/gaps
1226 * ug_words: Add entries for -gnatw.h/-gnatw.H
1227 * vms_data.ads: Add entries for [NO]AVOIDGAPS
1229 2010-09-10 Gary Dismukes <dismukes@adacore.com>
1231 * sem_ch6.adb: Update comment.
1233 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1235 * sem_ch3.adb (Build_Derived_Private_Type): Mark generated declaration
1236 of full view analyzed after analyzing the corresponding record
1237 declaration, to prevent spurious name conflicts with original
1240 2010-09-10 Jerome Lambourg <lambourg@adacore.com>
1242 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): In the VM case,
1243 just issue a warning, but continue with the normal processing.
1245 2010-09-10 Robert Dewar <dewar@adacore.com>
1247 * exp_attr.adb, prj-nmsc.adb, sem_ch4.adb, sem_res.adb: Minor
1250 2010-09-10 Thomas Quinot <quinot@adacore.com>
1252 * exp_dist.adb (Build_From_Any_Call, Build_To_Any_Call,
1253 Build_TypeCode_Call): For a subtype inserted for the expansion of a
1254 generic actual type, go to the underlying type of the original actual
1257 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1259 * exp_ch5.adb (Expand_Assign_Array_Loop): In CodePeer mode, place a
1260 guard around the increment statement, to prevent an off-by-one-value
1261 on the last iteration.
1263 2010-09-10 Vincent Celier <celier@adacore.com>
1265 * sem_aggr.adb, exp_prag.adb, sem_ch3.adb, exp_attr.adb,
1266 sem_res.adb, sem_attr.adb, sem_elab.adb, sem_ch4.adb, exp_disp.adb,
1267 exp_aggr.adb, exp_dist.adb: Change all mentions of "at run-time" to
1268 "at run time" in comments and error/warning messages.
1270 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1272 * exp_cg.adb: Handle properly bodies without specs.
1274 2010-09-10 Emmanuel Briot <briot@adacore.com>
1276 * prj-nmsc.adb (Find_Source_Dirs): When a source directory is not
1277 present, and the user requested to either ignore this or display a
1278 warning (as opposed to an error), we still need to register the
1281 2010-09-10 Robert Dewar <dewar@adacore.com>
1283 * errout.adb: Remove tests of Parsing_Main_Subunit, since this test is
1284 now done in In_Extended_Main_Source_Unit.
1285 * errout.ads (Compiler_State[_Type]): Moved from Errout to Lib
1286 (Parsing_Main_Subunit): Moved from Errout to Lib and renamed
1287 as Parsing_Main_Extended_Source.
1288 * frontend.adb: Set Parsing_Main_Extended_Source True for parsing main
1290 * lib-load.adb (Load_Unit): Add PMES parameter
1291 Set PMES appropriately in all calls to Load_Unit
1292 * lib-load.ads (Load_Unit): Add PMES parameter
1293 * lib.adb (In_Extended_Main_Source_Unit): When called with
1294 Compiler_State set to Parsing, test new flag
1295 Compiling_Main_Extended_Source.
1296 * lib.ads (Compiler_State[_Type]): Moved from Errout to Lib
1297 (Parsing_Main_Subunit): Moved from Errout to Lib and renamed
1298 as Parsing_Main_Extended_Source
1299 * par-load.adb (Load): Set PMES properly in call to Load_Unit
1301 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1303 * exp_cg.adb: Use proper entity to handle overloads.
1304 * sem_res.adb (Check_Parameterless_Call): An operator node without
1305 actuals cannot be a call, and must be treated as a string.
1307 2010-09-10 Robert Dewar <dewar@adacore.com>
1309 * frontend.adb: Minor reformatting.
1311 2010-09-10 Robert Dewar <dewar@adacore.com>
1313 * par-ch4.adb (P_Conditional_Expression): Use P_Condition for condition
1314 * par-ch5.adb (P_Condition): Move from body to spec
1315 * par.adb (Ch5.P_Condition): Move from body to spec
1317 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1319 * exp_cg.adb (Write_Call_Info): If a type that has been registered in
1320 the call table is private, use its full view to generate information
1323 2010-09-10 Jose Ruiz <ruiz@adacore.com>
1325 * exp_cg.adb (Is_Predefined_Dispatching_Operation): When trying the
1326 pattern matching to detect predefined primitive operations take into
1327 account that there can be an extra suffix related to body-nested
1330 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1332 * s-pooglo.ads: Add overriding indicators.
1334 2010-09-10 Vincent Celier <celier@adacore.com>
1336 * vms_data.ads: Add new GNAT BIND qualifiers /32_MALLOC (for -H32) and
1337 /64_MALLOC (for -H64).
1339 2010-09-10 Robert Dewar <dewar@adacore.com>
1341 * errout.adb (Error_Msg_Internal): Test Parsing_Main_Subunit flag
1342 (Error_Msg_NW): Test Parsing_Main_Subunit flag
1343 * errout.ads (Parsing_Main_Subunit): New flag
1344 * lib-load.adb (Load_Unit): Set Parsing_Main_Subunit flag
1345 * par-ch6.adb: Minor style fix (remove redandant parentheses)
1346 * par-ch9.adb: Minor style fix (remove redundant parens)
1347 * par-load.adb: (Load): Deal with setting Parsing_Main_Subunit
1349 2010-09-10 Vincent Celier <celier@adacore.com>
1351 * make.adb (Create_Binder_Mapping_File): Remove procedure. Replaced by
1352 function of the same name in Makeutl.
1353 (Gnatmake): Call function Create_Binder_Mapping_File in Makeutl, instead
1354 of removed procedure when creating a binder mapping file.
1355 * makeutl.adb (Create_Binder_Mapping_File): New function. Was a
1357 * makeutl.ads (Create_Binder_Mapping_File): New function
1359 2010-09-10 Jose Ruiz <ruiz@adacore.com>
1361 * exp_cg.adb (Is_Predefined_Dispatching_Operation): Add the "__" scope
1362 separator when trying the pattern matching to detect predefined
1363 primitive operations.
1365 2010-09-10 Robert Dewar <dewar@adacore.com>
1367 * bindgen.adb, atree.adb: Minor reformatting.
1369 2010-09-10 Ben Brosgol <brosgol@adacore.com>
1371 * ug_words, gnat_ugn.texi: Revised "Transitioning to 64-Bit GNAT for
1374 2010-09-10 Doug Rupp <rupp@adacore.com>
1376 * bindgen.adb: Minor comment fix for -H switch.
1378 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1380 * exp_cg.adb (Register_CG_Node): Determine enclosing subprogram or
1381 library unit now, by traversing tree before context is expanded.
1382 (Write_Call_Info): Use enclosing unit name directly.
1383 * exp_ch9.adb (Expand_N_Accept_Statement): Attach generated block to
1384 tree earlier, to ensure that subsequent declarations are analyzed in a
1385 connected structure.
1386 * exp_intr.adb (Expand_Unc_Deallocation): Ditto for generated statement
1389 2010-09-10 Robert Dewar <dewar@adacore.com>
1391 * symbols-processing-vms-alpha.adb: Minor reformatting.
1393 2010-09-10 Jerome Lambourg <lambourg@adacore.com>
1395 * bindgen.adb (Gen_Adainit_Ada): In .NET, don't call
1396 __gnat_install_handler in case the binder is called with -n.
1398 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1400 * exp_ch6.adb (Make_Build_In_Place_In_Object_Declaration): Use proper
1401 sloc for renaming declaration and set Comes_From_Source properly to
1402 ensure that references are properly generated for an object declaration
1403 that is built in place.
1405 2010-09-10 Tristan Gingold <gingold@adacore.com>
1407 * symbols-processing-vms-alpha.adb: Allow gnatsym to work as a cross
1409 * gcc-interface/Make-lang.in: Install gnatsym when cross compiling.
1410 * gcc-interface/Makefile.in: gnat.hlp is now generated by
1413 2010-09-10 Bob Duff <duff@adacore.com>
1415 * exp_pakd.adb (Expand_Bit_Packed_Element_Set): For things like ""X(J)
1416 := ...;", remove side effects from the right-hand side, because they
1417 might affect the value of the left-hand side, but the left-hand side is
1418 first READ (so we can do shifting and masking) and then written back,
1419 which would cause the side effects to be incorrectly overwritten.
1421 2010-09-10 Robert Dewar <dewar@adacore.com>
1423 * sem_ch4.adb: Minor reformatting.
1424 * exp_ch6.adb: Add comment on testing limited on full type
1425 * gnat_rm.texi: Add documentation on Pure_Function.
1427 2010-09-10 Vincent Celier <celier@adacore.com>
1429 * prj-nmsc.adb (Add_Source): Allow an Ada source to have the same name
1430 as a source of another project and of another language.
1432 2010-09-10 Robert Dewar <dewar@adacore.com>
1434 * exp_ch3.adb (Expand_N_Object_Declaration): Defend against previous
1436 * freeze.adb (Check_Unsigned_Type): Ditto.
1437 * sem_aggr.adb (Resolve_Aggr_Expr): Ditto.
1438 * sem_ch3.adb (Convert_Scalar_Bounds): Ditto.
1439 (Set_Scalar_Range_For_Subtype): Ditto.
1440 * sem_eval.adb (Subtypes_Statically_Match): Ditto.
1442 2010-09-10 Robert Dewar <dewar@adacore.com>
1444 * repinfo.adb (List_Type_Info): List Small and Range for fixed-point
1446 * sprint.adb (Write_Ureal_With_Col_Check_Sloc): Use square brackets
1447 rather than parens for fixed constants.
1448 * sprint.ads: Use square brackets rather than parens for fixed constants
1449 * urealp.adb (UR_Write): Use square brackets rather than parens
1450 (UR_Write): Add Brackets argument
1451 (UR_Write): Add many more special cases to output literals
1452 * urealp.ads (UR_Write): Use square brackets rather than parens
1453 (UR_Write): Add Brackets argument
1455 2010-09-10 Robert Dewar <dewar@adacore.com>
1457 * sem_ch4.adb: Minor reformatting.
1459 2010-09-10 Richard Guenther <rguenther@suse.de>
1461 * gcc-interface/utils.c (create_index_type): Use build_range_type.
1463 2010-09-10 Arnaud Charlet <charlet@adacore.com>
1465 * vms_cmds.ads: New.
1467 2010-09-10 Eric Botcazou <ebotcazou@adacore.com>
1469 * exp_dbug.ads: Mention enhanced encoding for array types.
1471 2010-09-10 Jerome Lambourg <lambourg@adacore.com>
1473 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Size clause are
1474 unsupported in VM targets. Display a warning in this case.
1476 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1478 * sprint.adb (Sprint_Node_Actual, case N_Derived_Type_Definition): Do
1479 not reset Sloc when printing keyword "new".
1481 2010-09-10 Vincent Celier <celier@adacore.com>
1483 * gnatcmd.adb (GNATCmd): Put the command line in environment variable
1484 GNAT_DRIVER_COMMAND_LINE.
1486 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1488 * sem.adb (Do_Unit_And_Dependents): if Withed_Body is set on a context
1489 clause, process the body at once.
1491 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1493 * sem_res.adb (Resolve_Type_Conversion): Do not warn on a redundant
1494 conversion is the expression is a qualified expression used to
1495 disambiguate a function call.
1497 2010-09-10 Vincent Celier <celier@adacore.com>
1499 * prj-nmsc.adb (Add_Source): Allow an Ada source to have the same name
1500 as a source of another project and of another language.
1502 2010-09-10 Robert Dewar <dewar@adacore.com>
1504 * prj-util.adb: Minor reformatting.
1506 2010-09-10 Eric Botcazou <ebotcazou@adacore.com>
1508 * exp_disp.adb: Minor reformatting.
1510 2010-09-10 Arnaud Charlet <charlet@adacore.com>
1512 * sem_prag.adb (Analyze_Pragma): Ignore Inline_Always pragma in
1515 2010-09-10 Thomas Quinot <quinot@adacore.com>
1517 * sem_res.adb: Minor reformatting.
1518 * exp_ch9.adb, rtsfind.ads, exp_ch4.adb, exp_ch3.adb: Do not hardcode
1519 magic constants for task master levels (instead, reference
1520 named numbers from System.Tasking).
1522 2010-09-10 Eric Botcazou <ebotcazou@adacore.com>
1524 * gnatvsn.ads (Ver_Prefix): New constant string.
1525 * bindgen.adb (Gen_Output_File_Ada): Use it in lieu of hardcoded value.
1526 (Gen_Output_File_C): Likewise.
1527 * g-comver.adb (Ver_Prefix): Add cross-reference to Gnatvsn.Ver_Prefix
1530 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1532 * sem.adb (Walk_Library_Items): Do not traverse children of the main
1533 unit, to prevent spurious circularities in the walk order.
1534 (Depends_On_Main): Use elsewhere to prevent circularities when the body
1535 of an ancestor of the main unit depends on a child of the main unit.
1537 2010-09-10 Robert Dewar <dewar@adacore.com>
1539 * gnatlink.adb, prj-ext.adb, prj-util.adb, s-tporft.adb,
1540 sem_ch3.adb: Minor reformatting.
1542 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1544 * sem_ch3.adb (Derive_Subprograms): An interface primitive operation
1545 that is a renaming must be derived like any other primitive operation,
1546 the renamed operation is not relevant to the derivation.
1548 2010-09-10 Robert Dewar <dewar@adacore.com>
1550 * sem_aux.ads: Add comment for Is_Inherently_Limited_Type.
1551 * checks.adb: Minor reformatting.
1553 2010-09-10 Robert Dewar <dewar@adacore.com>
1555 * gnat_ugn.texi: Add section on intent of style checking options.
1557 2010-09-10 Arnaud Charlet <charlet@adacore.com>
1559 * xref_lib.adb (Get_Full_Type): Fix handling of 'a' char.
1561 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1563 * sem_ch3.adb: Improve error message on derivation from class-wide type
1565 2010-09-10 Steve Baird <baird@adacore.com>
1567 * gnat1drv.adb (Adjust_Global_Switches): Enable Expression_With_Actions
1568 generation when Generate_SCIL is True.
1570 2010-09-10 Geert Bosch <bosch@adacore.com>
1572 * gnatlink.adb (Check_ Existing_Executable): New procedure for checking
1573 validity of executable name and removing any existing executable
1574 (Gnatlink): Call Check_Existing_Executable.
1576 2010-09-10 Arnaud Charlet <charlet@adacore.com>
1578 * s-tporft.adb, s-taskin.ads (Register_Foreign_Thread): Move
1579 initialization of Task_Alternate_Stack here, cleaner since in case of
1580 ranvescar, Restricted_Ada_Task_Control_Block is not initialized
1583 2010-09-10 Thomas Quinot <quinot@adacore.com>
1585 * s-fileio.adb, a-dirval.adb: Minor reformatting.
1587 2010-09-10 Emmanuel Briot <briot@adacore.com>
1589 * prj-util.adb (Executable_Of): Fix CE when the project does not
1590 contain a Builder package.
1592 2010-09-10 Vincent Celier <celier@adacore.com>
1594 * prj-ext.adb (Initialize_Project_Path): Add <prefix>/lib/gpr/<target>
1595 to the project path, if Prefix and Target_Name are defined.
1596 * prj-tree.ads (Project_Node_Tree_Data): New component Target_Name
1598 2010-09-10 Ed Schonberg <schonberg@adacore.com>
1600 * checks.adb (Ensure_Valid): If the expression is a boolean expression
1601 or short-circuit operation, do no emit a validity check: only the
1602 elementary operands of the expression need checking.
1604 2010-09-10 Ben Brosgol <brosgol@adacore.com>
1606 * gnat_rm.texi: Document Short_Descriptors.
1608 2010-09-10 Arnaud Charlet <charlet@adacore.com>
1610 * s-taprop-linux.adb, s-taskin.ads (Task_Alternate_Stack): Default
1611 initialize to Null_Address.
1612 (Enter_Task): Do not set up an alternate stack for foreign threads.
1614 2010-09-10 Robert Dewar <dewar@adacore.com>
1616 * opt.adb (Short_Descriptors): New flag
1617 (Short_Descriptors_Config): New flag
1618 * opt.ads (Short_Descriptors): New flag
1619 (Short_Descriptors_Config): New flag
1620 * par-prag.adb: Add dummy entry for Short_Descriptors pragma
1621 * sem_prag.adb (Set_Mechanism_Value): Deal with Short_Descriptors pragma
1622 (Analyze_Pragma): Implement Short_Descriptors pragma
1623 * snames.ads-tmpl: Add entry for Short_Descriptors pragma
1625 2010-09-10 Emmanuel Briot <briot@adacore.com>
1627 * prj-util.adb, prj-util.ads (Executable_Of): Take into account the
1628 project's Executable_Suffix.
1630 2010-09-10 Robert Dewar <dewar@adacore.com>
1632 * g-pehage.ads: Minor reformatting
1634 * gnat_ugn.texi: Clarifying comment on -gnatyc
1635 * exp_ch6.adb (Expand_N_Subprogram_Body): Reset Is_Pure if limited
1638 2010-09-10 Tristan Gingold <gingold@adacore.com>
1640 * Make-generated.in (gnat.hlp): New rule.
1642 2010-09-10 Emmanuel Briot <briot@adacore.com>
1644 * prj-util.adb, prj-util.ads (Executable_Of): New parameter
1647 2010-09-10 Robert Dewar <dewar@adacore.com>
1649 * einfo.adb: Minor code cleanup: Add assertion to
1650 Set_Corresponding_Protected_Entry.
1652 2010-09-10 Bob Duff <duff@adacore.com>
1654 * g-pehage.ads, g-pehage.adb (Produce): Add a new flag to allow sending
1655 the output to standard output.
1657 2010-09-09 Vincent Celier <celier@adacore.com>
1659 * gnat_ugn.texi: Add documentation for new gnatmake switch
1661 * make.adb (Map_File): New global variable to store the value of switch
1663 (Gnatmake): Add switch -M to gnatlink if buider switch --create-map-file
1665 (Scan_Make_Arg): Recognize switch --create-map-file
1666 * makeutl.ads (Create_Map_File_Switch): New constant string for new
1667 gnatmake and gprbuild switch --create-map-file.
1669 2010-09-09 Robert Dewar <dewar@adacore.com>
1671 * sinput-p.ads: Minor comment update.
1673 2010-09-09 Arnaud Charlet <charlet@adacore.com>
1675 * s-tpobop.adb, s-taenca.adb (Wait_For_Completion_With_Timeout): Reset
1676 Entry_Call.State if needed so that the call is marked as cancelled by
1677 Check_Pending_Actions_For_Entry_Call.
1678 (Timed_Protected_Entry_Call): Adjust calls to Defer/Under_Abort, since
1679 this procedure may be called from a controlled operation
1680 (Initialize/Finalize).
1682 2010-09-09 Vadim Godunko <godunko@adacore.com>
1684 * impunit.adb: Correct spelling of package's name in the comment.
1686 2010-09-09 Robert Dewar <dewar@adacore.com>
1688 * gnatcmd.adb, gnatlink.adb, sem_ch12.adb, sem_eval.adb, sinput-p.adb:
1691 2010-09-09 Robert Dewar <dewar@adacore.com>
1693 * impunit.adb: Add entry for a-izteio.
1694 * checks.adb: Add comment.
1695 * debug.adb, exp_disp.adb: Minor reformatting.
1696 * exp_dbug.ads: Minor reformatting throughout (pack block comments).
1698 2010-09-09 Ed Schonberg <schonberg@adacore.com>
1700 * sem_eval.adb (Is_Same_Value): Two occurrences of the same
1701 discriminant cannot be assumed to be the same value because they may
1702 refer to bounds of a component of two different instances of a
1705 2010-09-09 Gary Dismukes <dismukes@adacore.com>
1707 * checks.adb (Apply_Arithmetic_Overflow_Check): When converting the
1708 operands of an operator to the type of an enclosing conversion, rewrite
1709 the operator so the conversion can't be flagged as redundant.
1710 Remove useless assignments to Typ and Rtyp.
1712 2010-09-09 Eric Botcazou <ebotcazou@adacore.com>
1714 * gnat_ugn.texi: Fix another long line.
1716 2010-09-09 Bob Duff <duff@adacore.com>
1718 * sem_warn.adb (Output_Reference_Error): Don't warn for renames read
1721 2010-09-09 Matthew Heaney <heaney@adacore.com>
1723 * a-convec.adb, a-coinve.adb (Clear, Delete, Delete_Last, Finalize,
1724 Merge, Insert, Insert_Space, Move, Reserve_Capacity, Generic_Sorting,
1725 Replace_Element, Reverse_Elements, Swap): Change exception message to
1726 correctly indicate kind of tampering (cursor or element).
1727 * a-cdlili.adb, a-cidlli.adb (Clear, Delete, Delete_First, Delete_Last,
1728 Merge, Generic_Sorting, Insert, Move, Reverse_Elements, Splice,
1729 Swap_Links, Replace_Element, Swap): Ditto.
1730 * a-coorse.adb, a-ciorse.adb (Include, Replace, Replace_Element): Ditto
1731 * a-coorma.adb, a-ciorma.adb (Include, Replace, Replace_Element): Ditto
1732 * a-coormu.adb, a-ciormu.adb (Replace_Element): Ditto
1733 * a-chtgke.adb (Delete_Key_Sans_Free, Generic_Conditional_Insert,
1734 Generic_Replace_Element): Ditto
1735 * a-chtgop.adb (Clear, Move, Reserve_Capacity): Ditto
1736 * a-cohama.adb, a-cihama.adb (Delete, Include, Replace,
1737 Replace_Element): Ditto.
1738 * a-cohase.adb, a-cihase.adb (Delete, Difference, Intersection,
1739 Symmetric_Difference, Union, Include, Replace): Ditto
1741 2010-09-09 Ed Schonberg <schonberg@adacore.com>
1743 * sprint.adb (Write_Id): If the parent node is an expanded name, check
1744 that its entity_or_associated_node is an entity before writing it out.
1745 * exp_disp.adb (Make_Tags); if a type is declared in C++ and has no
1746 constructors, there is no need for a dispatch table pointer because the
1747 table is fully inherited from the C++ code.
1749 2010-09-09 Thomas Quinot <quinot@adacore.com>
1751 * projects.texi: Fix wrong identifiers on package end lines in project
1753 * exp_ch6.adb: Minor reformatting.
1755 2010-09-09 Tristan Gingold <gingold@adacore.com>
1757 * gnatcmd.adb, vms_conv.ads: Extract Command_Type.
1759 2010-09-09 Eric Botcazou <ebotcazou@adacore.com>
1761 * gnat_ugn.texi: Fix description of -O3 optimization level.
1763 2010-09-09 Yannick Moy <moy@adacore.com>
1765 * a-cihama.adb, a-cohama.adb: Fix comments.
1767 2010-09-09 Arnaud Charlet <charlet@adacore.com>
1769 * i-cexten.ads: Add comments.
1770 (Signed_128): New type, used by some C bindings.
1771 * debug.adb: Update comment.
1773 2010-09-09 Sergey Rybin <rybin@adacore.com>
1775 * gnat_ugn.texi: For ASIS tools (gnatpp, gnatcheck, gnatelim,
1776 gnatmetric and gnatstub) add a note that '-gnat05' should be used if
1777 the tool should process Ada 2005 sources.
1779 2010-09-09 Ed Schonberg <schonberg@adacore.com>
1781 * sem_ch12.adb (Remove_Parent): If the scope containing the child
1782 instance is a block, examine the enclosing scope to determine if it is
1785 2010-09-09 Doug Rupp <rupp@adacore.com>
1787 * sem_prag.adb (pragma Ident): Pass --identification= vice
1789 * gnatlink.adb (Linker_Options): Look for --identification= vice
1792 2010-09-09 Gary Dismukes <dismukes@adacore.com>
1794 * exp_attr.adb (Expand_N_Attribute_Reference, case Attribute_Old): When
1795 inserting and analyzing the object declaration for the temporary object
1796 created to hold a 'Old value, push the scope for the subprogram where
1797 the object is inserted, so that its Scope (and that of related objects)
1798 will be set properly.
1800 2010-09-09 Vincent Celier <celier@adacore.com>
1802 * prj.adb (Get_Object_Directory): Return object directory display name
1803 * adaint.c (__gnat_get_file_names_case_sensitive): When environment
1804 variable GNAT_FILE_NAME_CASE_SENSITIVE has a value of "0" or "1",
1805 return this value, otherwise return the default for the platform.
1807 2010-09-09 Arnaud Charlet <charlet@adacore.com>
1809 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
1810 dependencies. Remove handling of gnatlbr.
1811 Do not remove s-stratt-xdr for the run-time when installing.
1813 2010-09-09 Robert Dewar <dewar@adacore.com>
1815 * sem_attr.adb: Minor reformatting.
1817 2010-09-09 Thomas Quinot <quinot@adacore.com>
1819 * socket.c (__gnat_socket_ioctl): On Darwin, the req parameter is an
1820 unsigned long, not an int.
1822 2010-09-09 Vincent Celier <celier@adacore.com>
1824 * make.adb, mlib-prj.adb, prj.adb, prj-nmsc.adb, mlib-tgt.adb,
1825 prj-conf.adb, prj-env.adb: Use Display_Name instead of Name whenever
1826 we are not checking for equality of path or file names.
1828 2010-09-09 Ed Schonberg <schonberg@adacore.com>
1830 * exp_util.adb (Remove_Side_Effects): If the expression is a packed
1831 array reference, reset the Analyzed flag so that it is properly
1832 expanded when the resulting object declaration is analyzed.
1834 2010-09-09 Vincent Celier <celier@adacore.com>
1836 * sinput-p.adb (Source_File_Is_Subunit): Return False if X is
1839 2010-09-09 Ramon Fernandez <fernandez@adacore.com>
1841 * sysdep.c: The wrSbc8548 BSP in MILS doesn't know anything about the
1842 VX_SPE_TASK option, so disable it.
1844 2010-09-09 Ed Schonberg <schonberg@adacore.com>
1846 * sem.adb (Walk_Library_Items): Traverse context of subunits of the
1848 (Is_Subunit_Of_Main): Handle null nodes properly.
1850 2010-09-09 Robert Dewar <dewar@adacore.com>
1852 * par-ch2.adb: Update comments.
1854 2010-09-09 Ben Brosgol <brosgol@adacore.com>
1856 * gnat_rm.texi: Minor wordsmithing of section on pragma Ordered.
1858 2010-09-09 Arnaud Charlet <charlet@adacore.com>
1860 * par-ch2.adb (Scan_Pragma_Argument_Association): In CodePeer mode,
1861 do not generate an error for compatibility with legacy code.
1862 ignored when generating SCIL.
1863 * sem_attr.adb (Resolve_Attribute): Ignore AI-229 in CodePeer mode.
1865 2010-09-09 Thomas Quinot <quinot@adacore.com>
1867 * s-strxdr.adb, gnat_rm.texi, s-stratt-xdr.adb, s-stratt.ads: Rename
1868 s-strxdr.adb to s-stratt-xdr.adb
1870 2010-09-09 Robert Dewar <dewar@adacore.com>
1872 * ali-util.adb (Obsolescent_Check): Removed.
1873 * gprep.adb (Obsolescent_Check): Removed.
1874 Remove Obsolescent_Check parameter in Scng instantiation
1875 * prj-err.adb (Obsolescent_Check): Removed.
1876 * prj-err.ads (Obsolescent_Check): Removed.
1877 Remove Obsolescent_Check parameter in Scng instantiation
1878 * scans.ads (Based_Literal_Uses_Colon): New flag
1879 * scn.adb (Obsolscent_Check_Flag): Removed
1880 (Obsolscent_Check): Removed
1881 (Set_Obsolescent_Check): Removed
1882 (Post_Scan): Add handling for obsolescent features
1883 * scn.ads (Obsolscent_Check): Removed
1884 (Set_Obsolescent_Check): Removed
1885 (Post_Scan): Can no longer be inlined
1886 Remove Obsolescent_Check from instantiation of Scng
1887 * scng.adb (Nlit): Set Based_Literal_Uses_Colon
1888 (Nlit): Remove handling of obsolescent check
1889 (Scan, case '%'): Remove handling of obsolescent check
1890 (Scan, case '|'): Call Post_Scan
1891 (Scan, case '!'): Remove handling of obsolescent check, call Post_Scan
1892 * scng.ads Remove Obsolescent_Check argument from Scng generic
1893 (Post_Scan): Now called for Tok_Vertical_Bar
1894 * sinput-l.adb: Remove calls to Set_Obsolescent_Check
1896 2010-09-09 Doug Rupp <rupp@adacore.com>
1898 * gnatlbr.adb: Removed.
1899 * gnat_rm.texi, ug_words, gnat_ugn.texi: Remove mention of gnatlbr.
1901 2010-09-09 Robert Dewar <dewar@adacore.com>
1903 * sem_res.adb (Resolve_Type_Conversion): Catch more cases of redundant
1906 2010-09-09 Vincent Celier <celier@adacore.com>
1908 * gnatlbr.adb: Remove redundant conversions.
1910 2010-09-09 Vincent Celier <celier@adacore.com>
1912 * prj-proc.adb: Minor comment spelling error fix.
1913 * osint.ads (Env_Vars_Case_Sensitive): Use function
1914 Get_Env_Vars_Case_Sensitive, not Get_File_Names_Case_Sensitive to
1917 2010-09-09 Ed Schonberg <schonberg@adacore.com>
1919 * sem_res.adb (Resolve_Equality_Op): Implement Ada2012 rule for
1920 resolution of conditional expressions whose dependent expressions are
1921 anonymous access types.
1923 2010-09-09 Robert Dewar <dewar@adacore.com>
1925 * a-ststio.adb: Minor code reorganization.
1926 * s-direio.adb, prj.adb, prj-nmsc.adb, sem_type.adb: Remove redundant
1928 * types.ads: Minor reformatting.
1929 * binde.adb, vms_conv.adb, gnatls.adb, s-strxdr.adb, uintp.adb: Remove
1930 redundant conversions.
1931 * output.adb: Minor reformatting.
1932 * sem_ch8.adb (Find_Type): Test for redundant base applies to user
1934 * opt.ads: Add pragma Ordered for Verbosity_Level.
1935 * prj.ads: Add pragma Ordered for type Verbosity.
1937 2010-09-09 Vincent Celier <celier@adacore.com>
1939 * osint.adb (Canonical_Case_File_Name): Use procedure To_Lower in
1941 (Canonical_Case_Env_Var_Name): Ditto
1943 2010-09-09 Bob Duff <duff@adacore.com>
1945 * g-pehage.adb (Allocate): Initialize the allocated elements of IT.
1947 2010-09-09 Robert Dewar <dewar@adacore.com>
1949 * cstand.adb: Mark Boolean and Character types as Ordered
1950 * einfo.adb (Has_Pragma_Ordered): New flag
1951 * einfo.ads (Has_Pragma_Ordered): New flag
1952 * g-calend.ads: Mark Day_Name as Ordered
1953 * opt.ads: Mark Ada_Version_Type as Ordered
1954 (Warn_On_Unordered_Enumeration_Type): New flag
1955 * par-prag.adb: Add procdessing for pragma Ordered
1956 * s-ficobl.ads (Read_File_Mode): New subtype
1957 * s-fileio.adb: Use Read_File_Mode instead of explicit ranges
1958 * s-taskin.ads: Mark Entry_Call_State as ordered
1959 * sem_ch3.adb (Build_Derived_Enumeration_Type): Inherit
1961 * sem_ch6.ads: Mark Conformance_Type as Ordered
1962 * sem_prag.adb: Implement pragma Ordered
1963 * sem_res.adb (Bad_Unordered_Enumeration_Reference): New function
1964 (Resolve_Comparison_Op): Diagnose unordered comparison
1965 (Resolve_Range): Diagnose unordered range
1966 * sem_warn.adb (Warn_On_Unordered_Enumeration_Type): New flag (from
1968 * snames.ads-tmpl: Add entry for pragma Ordered
1969 * style.ads (Check_Enumeration_Subrange): Removed
1970 * styleg.adb (Check_Enumeration_Subrange): Removed
1971 * styleg.ads (Check_Enumeration_Subrange): Removed
1972 * stylesw.adb: Remove handling of -gnatyE switch
1973 * stylesw.ads: (Style_Check_Enumeration_Subranges): Removed
1974 * vms_data.ads: Remove -gnatyE entries
1975 Add -gnatw.u entries
1976 * ug_words: Entries for -gnatw.u and -gnatw.U
1977 * gnat_ugn.texi: Document -gnatw.u/-gnatw.U switches
1978 * gnat_rm.texi: Document pragma Ordered.
1979 * s-tasren.adb: Avoid unnecessary comparison on unordered enumeration.
1980 * s-tpobop.adb: Remove comparison on unordered enumeration type.
1982 2010-09-09 Vincent Celier <celier@adacore.com>
1984 * adaint.c: New function __gnat_get_env_vars_case_sensitive, returns 0
1985 for VMS and Windows, and 1 for all other platforms.
1986 * adaint.h: New function __gnat_get_env_vars_case_sensitive
1987 * osint.ads, osint.adb (Canonical_Case_Env_Var_Name): New procedure.
1988 * prj-ext.adb (Add): Call Canonical_Case_Env_Var_Name instead of
1989 Canonical_Case_File_Name, as we are dealing with environment variables,
1992 2010-09-09 Robert Dewar <dewar@adacore.com>
1994 * sem_util.adb: Minor reformatting
1996 2010-09-09 Vincent Celier <celier@adacore.com>
1998 * vms_data.ads: Add documentation for S_Make_Single.
2000 2010-09-09 Ed Schonberg <schonberg@adacore.com>
2002 * sem_util.adb (Same_Object): include formal parameters.
2004 2010-09-09 Vincent Celier <celier@adacore.com>
2006 * make.adb (Queue): New package implementing a new impementation of the
2007 queue, taking into account the new switch --single-compile-per-obj-dir.
2008 * makeutl.ads (Single_Compile_Per_Obj_Dir_Switch): New constant String
2009 for gnatmake and gprbuild new switch --single-compile-per-obj-dir.
2010 * opt.ads (One_Compilation_Per_Obj_Dir): New Boolean flag, defauted to
2012 * switch-m.adb (Scan_Make_Switches): Take into account new gnatmake
2013 switch --single-compile-per-obj-dir.
2014 * vms_data.ads: Add qualifier SINGLE_COMPILE_PER_OBJ_DIR for gnatmake
2015 switch --single-compile-per-obj-dir.
2016 * gnat_ugn.texi: Add documentation for new gnatmake switch
2017 --single-compile-per-obj-dir.
2019 2010-09-09 Ed Schonberg <schonberg@adacore.com>
2021 * einfo.adb, einfo.ads: Clarify use of Corresponding_Protected_Entry.
2023 2010-09-09 Javier Miranda <miranda@adacore.com>
2025 * sem_ch3.adb (Is_Progenitor): Relocated to sem_type.
2026 (Replace_Type): Code cleanup.
2027 * sem_type.ads, sem_type.adb (Is_Progenitor): Relocated from sem_ch3
2029 2010-09-09 Thomas Quinot <quinot@adacore.com>
2031 * exp_ch8.adb: Minor reformatting.
2033 2010-09-09 Ed Schonberg <schonberg@adacore.com>
2035 * exp_ch9.adb, einfo.adb, einfo.ads: New attribute
2036 Corresponding_Protected_Entry.
2038 2010-09-09 Ed Schonberg <schonberg@adacore.com>
2040 * exp_ch3.adb (Build_Untagged_Equality): Do not set alias of implicit
2041 inequality, it is always rewritten as the negation of the corresponding
2043 * exp_ch8.adb (Expand_N_Subprogram_Renaming): If the subprogram renames
2044 the predefined equality of an untagged record, create a body at the
2045 point of the renaming, to capture the current meaning of equality for
2048 2010-09-09 Robert Dewar <dewar@adacore.com>
2050 * sem.adb, sem_warn.adb: Minor reformatting.
2052 2010-09-09 Ed Schonberg <schonberg@adacore.com>
2054 * sem_ch6.adb: Improve error message on untagged equality.
2055 * sem.adb (Semantics): Include subprogram bodies that act as spec.
2057 2010-09-09 Javier Miranda <miranda@adacore.com>
2059 * sem_ch13.adb, exp_ch13.adb: Undo previous change, unneeded.
2061 2010-09-09 Robert Dewar <dewar@adacore.com>
2063 * sem_ch13.adb, sem_ch6.adb, exp_ch3.adb: Minor reformatting.
2065 2010-09-09 Robert Dewar <dewar@adacore.com>
2067 * einfo.adb (Is_Aggregate_Type): New function.
2068 * einfo.ads (Aggregate_Kind): New enumeration subtype
2069 (Is_Aggregate_Type): New function.
2070 * sem_type.adb (Is_Array_Class_Record_Type): Removed, replaced by
2073 2010-09-09 Robert Dewar <dewar@adacore.com>
2075 * exp_ch11.adb, frontend.adb, sem_attr.adb, sem_ch10.adb, sem_ch3.adb,
2076 sem_ch4.adb, sem_ch9.adb, sem_res.adb: Use Restriction_Check_Needed
2078 * restrict.ads, restrict.adb: Ditto.
2079 (Restriction_Check_Needed): New function
2081 2010-09-09 Ed Schonberg <schonberg@adacore.com>
2083 * exp_ch9.ads (Find_Master_Scope): New function, extracted from
2084 Build_Master_Entity, to find the proper scope for the master entity of
2085 a type that may contain tasks, in the presence of transient scopes.
2086 * exp_ch9.adb (Build_Master_Entity) Use new function.
2087 * exp_ch3.adb (Build_Class_Wide_Master): ditto.
2089 2010-09-09 Vincent Celier <celier@adacore.com>
2091 * prj-attr.adb: Add new attributes Leading_Library_Options and
2092 Linker'Leading_Switches.
2093 * snames.ads-tmpl: Add new standard names Leading_Library_Options and
2096 2010-09-09 Javier Miranda <miranda@adacore.com>
2098 * sem_ch3.adb (Derive_Subprogram): The code that checks if a
2099 dispatching primitive covers some interface primitive is incomplete.
2100 Replace such code by the invocation of a new subprogram that provides
2102 * sem_ch6.ads (Is_Interface_Conformant): Add missing documentation.
2103 * sem_ch6.adb (Check_Missing_Return): Minor reformating
2104 (Check_Convention): Complete if-statement conditition when reporting
2105 errors (to avoid assertion failure).
2106 * sem_ch13.adb (Make_Null_Procedure_Specs): This routine was previously
2107 located in exp_ch3. Relocated inside Analyze_Freeze_Entity.
2108 (Analyze_Freeze_Entity): Invoke routine that adds the spec of non
2109 overridden null interface primitives.
2110 * sem_type.adb (Is_Ancestor): If the parent of the partial view of a
2111 private type is an interface then use the parent of its full view to
2112 climb to its ancestor type.
2113 * sem_disp.ads, sem_disp.adb (Covers_Some_Interface): New subprogram.
2114 (Check_Dispatching_Operation): Extend assertion to handle wrappers of
2115 null interface primitives.
2116 (Is_Null_Interface_Primitive): New subprogram.
2117 * exp_ch3.adb (Make_Null_Procedure_Specs): Removed.
2118 (Expand_Freeze_Record_Type): Do not generate specs of null interface
2119 subprograms because they are now generated by Analyze_Freeze_Entity.
2121 2010-09-09 Robert Dewar <dewar@adacore.com>
2123 * a-calfor.adb, sem_ch3.adb: Minor reformatting.
2125 2010-09-09 Robert Dewar <dewar@adacore.com>
2127 * bindgen.adb (Gen_Restrictions_Ada): Avoid explicit enumeration ranges
2128 (Gen_Restrictions_C): Avoid explicit enumeration ranges
2129 (Set_String_Replace): New procedure
2130 * casing.ads (Known_Casing): New subtype declaration
2131 * prj-attr.ads (All_Case_Insensitive_Associative_Array): New subtype
2133 * prj-dect.adb (Parse_Attribute_Declaration): Avoid enumeration range
2134 * prj-nmsc.adb (Check_Naming): Avoid unnecessary enumeration range
2135 * prj-strt.adb (Attribute_Reference): Avoid enumeration range test
2136 * prj.adb (Known_Casing): Moved to Casing spec (avoid enum range)
2137 * sem_ch13.adb (Adjust_Record_For_Reverse_Bit_Order): Avoid enumeration
2139 * sem_res.adb (Resolve_Range): Check for enumeration subrange style rule
2140 * sem_type.adb (Is_Array_Class_Record_Type): New.
2141 * style.ads (Check_Enumeration_Subrange): New procedure
2142 * styleg.adb (Check_Enumeration_Subrange): New procedure
2143 * styleg.ads (Check_Enumeration_Subrange): New procedure
2144 * stylesw.adb Add handling for Style_Check_Enumeration_Subranges
2145 * stylesw.ads (Style_Check_Enumeration_Subranges): New flag
2146 * usage.adb: Add line for -gnatyE
2147 * vms_data.ads: Add entries for [NO]ENUMERATION_RANGES
2148 Add missing entry for NOBOOLEAN_OPERATORS
2149 * gnat_ugn.texi: Add documentation for -gnatyE
2151 2010-09-09 Robert Dewar <dewar@adacore.com>
2153 * namet.adb (Initialize): Is now a dummy procedure
2154 (Reinitialize): New procedure
2155 Call Reinitialize from package initialization
2156 * namet.ads (Initialize): Is now a dummy procedure
2157 (Reinitialize): New procedure
2158 * clean.adb, gnat1drv.adb, gnatbind.adb, gnatcmd.adb, gnatlink.adb,
2159 gnatls.adb, gprep.adb, make.adb, prj-makr.adb: Remove obsolete call to
2162 2010-09-09 Bob Duff <duff@adacore.com>
2164 * sem_elab.adb, s-os_lib.ads: Minor comment fixes.
2166 2010-09-09 Robert Dewar <dewar@adacore.com>
2168 * s-bitops.adb (Raise_Error): Add exception message
2170 2010-09-09 Robert Dewar <dewar@adacore.com>
2172 * par-ch5.adb (Test_Statement_Required): Deal with Ada 2012 allowing no
2173 null statement after label.
2174 * sinfo.ads: Minor comment updates.
2176 2010-09-09 Robert Dewar <dewar@adacore.com>
2178 * nlists.ads, nlists.adb (In_Same_List): New function.
2179 Use Node_Or_Entity_Id where appropriate.
2180 * par-labl.adb, sem_ch6.adb, sem_type.adb: Use In_Same_List.
2182 2010-09-09 Robert Dewar <dewar@adacore.com>
2184 * restrict.ads, restrict.adb (Check_Wide_Character_Restriction): New
2186 * sem_ch3.adb: Use Check_Wide_Character_Restriction
2187 (Enumeration_Type_Declaration): Check violation of No_Wide_Characters
2188 * sem_ch8.adb (Find_Direct_Name): Check violation of No_Wide_Characters
2189 (Find_Expanded_Name): Check violation of No_Wide_Characters
2191 2010-09-09 Robert Dewar <dewar@adacore.com>
2193 * par-ch5.adb: Minor reformatting.
2195 2010-09-09 Robert Dewar <dewar@adacore.com>
2197 * prj-env.adb: Minor code reorganization.
2198 * par-ch3.adb: Minor reformatting.
2199 * gcc-interface/Make-lang.in: Update dependencies.
2201 2010-09-09 Ed Schonberg <schonberg@adacore.com>
2203 * exp_ch9.adb (Build_Activation_Chain_Entity): The construct enclosing
2204 a task declaration can be an entry body.
2206 2010-09-09 Javier Miranda <miranda@adacore.com>
2208 * exp_disp.adb (Make_DT): Decorate as "static" variables containing
2209 tags of library level tagged types.
2210 (Make_Tags): Disable backend optimizations about aliasing for
2211 declarations of access to dispatch tables.
2213 2010-09-09 Ed Schonberg <schonberg@adacore.com>
2215 * sem_ch12.adb (Reset_Entity): If the entity is an itype created as a
2216 subtype for a null-excluding access type, recover the original
2217 subtype_mark to get the proper visibility on the original name.
2219 2010-09-09 Ed Schonberg <schonberg@adacore.com>
2221 * exp_ch3.adb (Build_Untagged_Equality): For Ada2012, new procedure to
2222 create the primitive equality operation for an untagged record. The
2223 operation is the predefined equality if no record component has a
2224 user-defined equality, or if there is a user-defined equality for the
2225 type as a whole, or when the type is derived and it has an inherited
2226 equality. Otherwise the body of the operations is built as for tagged
2228 (Expand_Freeze_Record_Type): Call Build_Untagged_Equality when needed.
2229 (Make_Eq_Body): New function to create the expanded body of the equality
2230 operation for tagged and untagged records. In both cases the operation
2231 composes, and the primitive operation of each record component is used
2232 to generate the equality function for the type.
2233 * exp_ch4.adb (Expand_Composite_Equality): In Ada2012, if a component
2234 has an abstract equality defined, replace its call with a
2235 Raise_Program_Error.
2236 * sem_ch6.adb (New_Overloaded_Entity): if Ada2012, verify that a
2237 user-defined equality operator for an untagged record type does not
2238 happen after type is frozen, and appears in the visible part if partial
2239 view of type is not limited.
2241 2010-09-09 Tristan Gingold <gingold@adacore.com>
2243 * gnatlbr.adb: Make Create_Directory more portable: use __gnat_mkdir.
2245 2010-09-09 Bob Duff <duff@adacore.com>
2247 * gnat_ugn.texi: Remove incorrect statement about -E being the default.
2249 2010-09-09 Pascal Obry <obry@adacore.com>
2251 * gnat_ugn.texi: Update doc on windows related topics.
2253 2010-09-09 Geert Bosch <bosch@adacore.com>
2255 * s-fatgen.adb: Update comments.
2257 2010-09-09 Robert Dewar <dewar@adacore.com>
2259 * par-ch4.adb (Box_Error): New procedure.
2261 2010-09-09 Thomas Quinot <quinot@adacore.com>
2263 * sem.adb: Minor reformatting.
2265 2010-09-09 Pascal Obry <obry@adacore.com>
2267 * prj-env.adb: Style fix, use /and then/ and /or else/.
2268 * gnat_ugn.texi: Fix typos.
2270 2010-09-03 Joseph Myers <joseph@codesourcery.com>
2273 * gcc-interface/misc.c (gnat_init_options): Allow options with
2274 empty canonical form. Generate a single save_argv element from -I
2277 2010-08-30 Eric Botcazou <ebotcazou@adacore.com>
2279 * gcc-interface/utils.c (gnat_pushdecl): Remove test for PARM_DECLs.
2280 Attach fake PARM_DECLs to the topmost block of the function.
2282 2010-08-30 Eric Botcazou <ebotcazou@adacore.com>
2284 * gcc-interface/trans.c (call_to_gnu): Also force the return slot opt
2285 for the call to a function whose return type was unconstrained.
2287 2010-08-30 Olivier Hainque <hainque@adacore.com>
2289 * gcc-interface/decl.c (FOREIGN_FORCE_REALIGN_STACK): New macro,
2290 replacement for FORCE_PREFERRED_STACK_BOUNDARY_IN_MAIN.
2291 (gnat_to_gnu_entity) <case ..., E_Procedure>: Use it.
2293 2010-08-21 Eric Botcazou <ebotcazou@adacore.com>
2295 * tracebak.c: Fix typo in comment.
2297 2010-08-20 Nathan Froyd <froydnj@codesourcery.com>
2299 * gcc-interface/decl.c: Use FOR_EACH_VEC_ELT.
2300 * gcc-interface/trans.c: Likewise.
2301 * gcc-interface/utils.c: Likewise.
2303 2010-08-18 Eric Botcazou <ebotcazou@adacore.com>
2305 * tracebak.c (i386): Use GCC unwinder on Linux with GCC > 4.5.
2307 2010-08-10 Robert Dewar <dewar@adacore.com>
2309 * sem_ch8.adb, sem_ch8.ads: Change name Write_Scopes to ws.
2310 * sem_util.adb: Minor reformatting.
2312 2010-08-10 Javier Miranda <miranda@adacore.com>
2314 * sem_aggr.adb (Resolve_Extension_Aggregate): Warn on the use of C++
2315 constructors that leave the object partially initialized.
2316 * exp_atag.ads, exp_atags.adb (Build_Inherit_CPP_Prims): New subprogram
2317 that copies from parent of Typ the dispatch table slots of inherited
2318 C++ primitives. It handles primary and secondary dispatch tables.
2319 * einfo.adb (Related_Type): Moved from Node26 to Node27. Required to
2320 use this attribute with E_Variable entities.
2321 (Set_Is_Tag): Relax assertion to allow its use with variables that
2323 (Set_Related_Type): Relax assertion to allow its use with variables
2324 that store the tag of a C++ class.
2325 (Write_26_Field_Name): Remove Related_Type.
2326 (Write_27_Field_Name): Add Related_Type.
2327 * einfo.ads (Related_Type): Moved from Node26 to Node27. Available also
2328 with E_Variable entities.
2329 * sem_prag.adb (CPP_Constructor): Warn on duplicated occurrence of this
2331 * sem_util.adb (Search_Tag): Add missing support for CPP types.
2332 (Enclosing_CPP_Parent): New subprogram.
2333 (Has_Suffix): New subprogram.
2334 * sem_util.ads (Enclosing_CPP_Parent): New subprogram that returns the
2335 closest ancestor of a type that is a C++ type.
2336 (Has_Suffix): New subprogram. Used in assertions to check the suffix of
2338 * sem_attr.adb (Analyze_Access_Attribute): Check wrong use of current
2339 instance in derivations of C++ types.
2340 * exp_tss.adb (CPP_Init_Proc): New subprogram.
2341 (Is_CPP_Init_Proc): New subprogram.
2342 (Set_TSS): Handle new C++ init routines.
2343 * exp_tss.ads (TSS_CPP_Init): New TSS name. For initialization of C++
2345 (CPP_Init_Proc): New subprogram.
2346 (Is_CPP_Init_Proc): New subprogram.
2347 * exp_disp.adb (CPP_Num_Prims): New subprogram.
2348 (Has_CPP_Constructors): New subprogram.
2349 (Make_Secondary_DT, Make_DT): For derivations of CPP types, do not
2350 initialize slots located in the C++ part of the dispatch table.
2351 (Make_Tags): For CPP types declare variables used by the IP routine to
2352 store the C++ tag values after the first invocation of the C++
2354 (Build_CPP_Init_DT): New subprogram.
2355 (Set_CPP_Constructors): New implementation that builds an IP for each
2356 CPP constructor. These IP are wrappers of the C++ constructors that,
2357 after the first invocation of the constructor, read the C++ tags from
2358 the object and save them locally. These copies of the C++ tags are used
2359 by the IC routines to initialize tables of Ada derivations of CPP types.
2360 (Write_DT): Indicate what primitives are imported from C++
2361 * exp_disp.ads (CPP_Num_Prims): New subprogram.
2362 (Has_CPP_Constructors): New subprogram.
2363 * exp_aggr.adb (Build_Record_Aggr_Code): For derivations of C++ types
2364 invoke the IC routine to inherit the slots of the parents.
2365 * sem_ch13.adb (Analyze_Freeze_Entity): Add new warnings on CPP types.
2366 * exp_ch3.adb (Is_Variable_Size_Array): New subprogram.
2367 (Is_Variable_Size_Record): Factorize code calling
2368 Is_Variable_Size_Array.
2369 (Build_CPP_Init_Procedure): New subprogram that builds the tree
2370 corresponding to the procedure that initializes the C++ part of the
2371 dispatch table of an Ada tagged type that is a derivation of a CPP type.
2372 (Build_Init_Procedure): Adding documentation plus code reorganization to
2373 leave more clear the construction of the IP with C++ types.
2374 (Expand_Freeze_Record_Type): Delay call to Set_CPP_Constructors because
2375 it cannot be called after Make_Tags has been invoked.
2376 (Inherit_CPP_Tag): Removed.
2377 (Init_Secondary_Tags): For derivations of CPP types, warn on tags
2378 located at variable offset.
2379 * freeze.ads: Minor reformating.
2380 * sem_ch8.adb (Write_Scopes): Add pragma export. Required to have it
2382 * gcc-interface/Make-lang.in: Update dependencies.
2384 2010-08-10 Robert Dewar <dewar@adacore.com>
2386 * a-chahan.ads: Add comments on handling of obsolescent entries.
2387 * opt.ads: Add Ada_2005 and Ada_2012 renamings for versions.
2388 * restrict.adb (Check_Obsolescent_2005_Entity): New procedure.
2389 * restrict.ads (Check_Obsolescent_2005_Entity): New procedure.
2390 * sem_attr.adb (Analyze_Access_Attribute): Call
2391 Check_Obsolescent_2005_Entity to check for access to obsolescent
2392 Ada.Characters.Handling subprogram.
2393 (Analyze_Attribute, case Class): Applying Class to untagged incomplete
2394 type is obsolescent in Ada 2005.
2395 (Analyze_Attribute, case Constrained): Better placement of flag when
2396 flagged as obsolescent feature.
2397 (Analyze_Attribute, case Storage_Size): Use with tasks is obsolescent
2398 * sem_ch10.adb (Analyze_With_Clause): With of renamings such as Text_IO
2399 is an obsolescent feature.
2400 * sem_ch11.adb (Analyze_Raise_Statement): Numeric_Error is obsolescent
2402 * sem_ch8.adb (Analyze_Subprogram_Renaming): Call
2403 Check_Obsolescent_2005_Entity to check for renaming obsolete
2404 Ada.Characters.Handling subprogram.
2405 * sem_prag.adb (Process_Restrictions_Or_Restriction_Warnings): Check
2406 for obsolescent restrictions in Ada 2005.
2407 (Analyze_Pragma, case Suppress): Entity arg is obsolescent in Ada 2005
2408 (Analyze_Pragma, case Interface): Interface is obsolescent in Ada 2005
2409 * sem_res.adb (Resolve_Call): Call Check_Obsolescent_2005_Entity to
2410 check for obsolescent references to Ada.Characters.Handling subprograms
2412 2010-08-10 Robert Dewar <dewar@adacore.com>
2414 * einfo.adb, einfo.ads: Fix bad -gnatdt output for incomplete type.
2416 2010-08-10 Robert Dewar <dewar@adacore.com>
2418 * errout.ads: Add VMS table entries for 2005, 12, 2012 switches
2419 * par-ch4.adb: Change wording of Ada 2012 messages
2420 * vms_data.ads: Add VMS entries for /2005, /12, /2012
2422 2010-08-10 Robert Dewar <dewar@adacore.com>
2424 * a-suenco.adb (Convert): Fix bug in UTF-16 to UTF-8 conversion for
2425 codes in the range 16#80#..16#7FF#.
2426 * sem_ch10.adb: Minor reformatting.
2428 2010-08-10 Arnaud Charlet <charlet@adacore.com>
2430 * gnat1drv.adb (Scan_Front_End_Switches): Always perform semantics and
2431 generate ali files in CodePeer mode, so that a gnatmake -c -k will
2432 proceed further when possible
2433 * freeze.adb (Freeze_Static_Object): Fix thinko. Do not generate error
2434 messages when ignoring representation clauses (-gnatI).
2436 2010-08-10 Ed Schonberg <schonberg@adacore.com>
2438 * exp_ch4.adb (Expand_N_Selected_Component): Do not attempt to
2439 constant-fold discriminant reference if the constraint is an object
2440 with non-static expression. Expression may contain volatile references
2441 in the presence of renamings.
2443 2010-08-10 Vincent Celier <celier@adacore.com>
2445 * prj-proc.adb (Get_Attribute_Index): If Index is All_Other_Names,
2447 * prj-strt.adb (Attribute_Reference): Recognize 'others' as a valid
2448 index for an associative array where it is allowed.
2450 2010-08-10 Thomas Quinot <quinot@adacore.com>
2452 * exp_attr.adb: Add comments.
2454 2010-08-10 Jerome Lambourg <lambourg@adacore.com>
2456 * adaint.c (__gnat_get_file_names_case_sensitive): return 0 on darwin.
2458 2010-08-09 Nathan Froyd <froydnj@codesourcery.com>
2460 * gcc-interface/utils.c (gnat_poplevel): Use blocks_nreverse.
2462 2010-08-09 Eric Botcazou <ebotcazou@adacore.com>
2464 * gcc-interface/utils.c (build_vms_descriptor32): Fix formatting.
2465 (build_vms_descriptor): Likewise.
2467 2010-08-08 Nathan Froyd <froydnj@codesourcery.com>
2469 * gcc-interface/utils.c (make_descriptor_field): Add tree parameter.
2470 (build_vms_descriptor32): Adjust calls to it for new parameter.
2471 (build_vms_descriptor): Likewise.
2473 2010-08-08 Nathan Froyd <froydnj@codesourcery.com>
2475 * gcc-interface/decl.c (rec_variant): Declare. Declare a VEC of it.
2476 (build_variant_list): Take and return a VEC instead of a tree.
2477 (create_variant_part_from): Take a VEC instead of a tree for
2478 variant_list. Adjust accordingly.
2479 (gnat_to_gnu_entity): Adjust for changes to previous functions.
2481 2010-08-07 Nathan Froyd <froydnj@codesourcery.com>
2483 * gcc-interface/decl.c (gnat_to_gnu_entity): Use XALLOCAVEC instead
2485 (components_to_record): Likewise.
2486 * gcc-interface/trans.c (gnat_to_gnu): Likewise.
2487 * gcc-interface/utils.c (max_size): Likewise.
2488 (build_vms_descriptor32): Likewise.
2489 (build_vms_descriptor): Likewise.
2491 2010-08-07 Nathan Froyd <froydnj@codesourcery.com>
2493 * gcc-interface/decl.c (subst_pair): Declare. Declare a VEC of it.
2494 (build_subst_list): Return a VEC instead of a tree.
2495 (build_variant_list): Take a VEC for subst_list. Adjust
2497 (create_field_decl_from): Likewise.
2498 (create_variant_part_from): Likewise.
2499 (copy_and_substitute_in_size): Likewise.
2500 (gnat_to_gnu_entity): Adjust for new interface to build_subst_list.
2501 Free the built vector.
2503 2010-08-06 Eric Botcazou <ebotcazou@adacore.com>
2505 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Do not build an
2506 allocator for large imported objects.
2508 2010-08-05 Robert Dewar <dewar@adacore.com>
2510 * gnat1drv.adb: Minor reformatting.
2512 2010-08-05 Ed Schonberg <schonberg@adacore.com>
2514 * sem.adb (Do_Unit_And_Dependents): If some parent unit is an
2515 instantiation, process its body before the spec of the main unit,
2516 because it may contain subprograms invoked in the spec of main.
2517 * einfo.ads: Add documention of delayed freeze.
2519 2010-08-05 Vincent Celier <celier@adacore.com>
2521 * prj-nmsc.adb (Process_Linker): Take into account new values for
2522 attribute Response_File_Format.
2523 * prj.ads (Response_File_Format): New enumeration values GCC_GNU,
2524 GCC_Object_List and GCC_Option_List.
2526 2010-08-05 Ed Schonberg <schonberg@adacore.com>
2528 * exp_ch4.adb (Expand_N_Selected_Component): Do not constant-fold a
2529 selected component that denotes a discriminant if it is the
2530 discriminant of a component of an unconstrained record type.
2532 2010-08-05 Ed Schonberg <schonberg@adacore.com>
2534 * exp_util.adb (Insert_Actions): If the action appears within a
2535 conditional expression that is already analyzed, insert action further
2538 2010-08-05 Robert Dewar <dewar@adacore.com>
2540 * exp_ch4.adb: Minor reformatting.
2542 2010-08-05 Thomas Quinot <quinot@adacore.com>
2544 * exp_ch4.adb: Minor reformatting
2545 * gnat1drv.adb: Minor reformatting.
2546 Minor code reorganization (use Nkind_In).
2548 2010-08-05 Ed Schonberg <schonberg@adacore.com>
2550 * exp_util.ads, exp_util.adb (Needs_Constant_Address): New predicate to
2551 determine whether the expression in an address clause for an
2552 initialized object must be constant. Code moved from freeze.adb.
2553 (Remove_Side_Effects): When the temporary is initialized with a
2554 reference, indicate that the temporary is a constant as done in all
2556 * freeze.adb (Check_Address_Clause): use Needs_Constant_Address.
2557 * exp_ch13.adb (Expand_N_Attribute_Definition_Clause, case 'Address):
2558 If object does not need a constant address, remove side effects from
2559 address expression, so it is elaborated at the point of the address
2560 clause and not at the freeze point of the object, so that elaboration
2563 2010-08-05 Vincent Celier <celier@adacore.com>
2565 * prj.adb (Is_Compilable): Return False for header files of non Ada
2568 2010-08-05 Emmanuel Briot <briot@adacore.com>
2570 * prj-nmsc.adb: The Missing_Source_Files flag also considers a missing
2571 exec directory as a warning rather than an error.
2573 2010-08-05 Thomas Quinot <quinot@adacore.com>
2575 * sem_ch6.adb, gnat1drv.adb, exp_ch6.adb, sem_eval.adb: Minor
2578 2010-08-05 Steve Baird <baird@adacore.com>
2580 * exp_util.adb (Remove_Side_Effects): An access value which designates
2581 a volatile object of a nonvolatile type is prohibited.
2582 Do not call Make_Reference to construct a reference to such an object.
2584 2010-08-05 Robert Dewar <dewar@adacore.com>
2586 * a-suezse.adb, a-suezse.ads, a-suezen.adb, a-suezen.ads: Removed.
2587 * a-suewse.adb, a-suewse.ads, a-suesen.adb, a-suesen.ads,
2588 a-suewen.adb, a-suewen.ads: New files.
2589 * Makefile.rtl, impunit.adb: Update implementation of Ada 2012 string
2591 * sem_elab.adb: Minor reformatting.
2593 2010-08-05 Arnaud Charlet <charlet@adacore.com>
2595 * sem_ch8.adb (Use_One_Type): Protect against empty scopes.
2596 * exp_util.adb (Component_May_Be_Bit_Aligned): Prevent assert failure
2597 in case of null Comp.
2599 2010-08-05 Robert Dewar <dewar@adacore.com>
2601 * errout.adb, a-suewen.adb, a-suezen.adb: Minor reformatting.
2603 2010-08-05 Gary Dismukes <dismukes@adacore.com>
2605 * sem_ch4.adb (Analyze_Allocator): Flag errors on allocators of a
2606 nested access type whose designated type has tasks or is a protected
2607 object when the restrictions No_Task_Hierarchy or
2608 No_Local_Protected_Objects apply. Add ??? comment.
2609 * sem_ch9.adb (Analyze_Protected_Type): Give a warning when a protected
2610 type is not a library-level type and No_Local_Protected_Objects applies.
2611 (Analyze_Task_Type): Give a warning when a task type is not a
2612 library-level type and No_Task_Hierarchy applies.
2614 2010-08-05 Arnaud Charlet <charlet@adacore.com>
2616 * sem.adb: Minor reformatting
2617 * sem_ch4.adb (Analyze_Reference): Disable error message in CodePeer
2620 2010-08-04 Eric Botcazou <ebotcazou@adacore.com>
2622 * gcc-interface/decl.c: Do not undefine IN_GCC_FRONTEND and do not
2624 (gnat_to_gnu_entity) <object>: Force address of -1 at the tree level
2625 for the debug-only entity.
2626 * gcc-interface/Make-lang.in (ada/decl.o): Adjust dependencies.
2628 2010-08-03 Joseph Myers <joseph@codesourcery.com>
2630 * gcc-interface/lang-specs.h: Don't pass -a options.
2632 2010-07-28 Joseph Myers <joseph@codesourcery.com>
2634 * gcc-interface/misc.c (gnat_init_options): Ignore erroneous
2635 options. Check canonical_option_num_elements on options copied.
2637 2010-07-27 Joseph Myers <joseph@codesourcery.com>
2639 * gcc-interface/misc.c (gnat_handle_option): Update prototype and
2640 return value type. Don't check for missing arguments here.
2642 2010-07-27 Joseph Myers <joseph@codesourcery.com>
2644 * gcc-interface/misc.c (gnat_option_lang_mask): New.
2645 (gnat_init_options): Update prototype. Reconstruct argv array
2646 from decoded options.
2648 2010-07-23 Eric Botcazou <ebotcazou@adacore.com>
2650 * gcc-interface/utils.c (update_pointer_to): In the unconstrained array
2651 case, merge the alias set of the old pointer type.
2653 2010-07-23 Eric Botcazou <ebotcazou@adacore.com>
2655 * gcc-interface/utils.c (gnat_types_compatible_p): Revert latest change
2656 and recurse only for multidimensional array types instead.
2658 2010-07-22 Eric Botcazou <ebotcazou@adacore.com>
2661 * gcc-interface/utils.c (convert): Fix thinko in test.
2662 (unchecked_convert): When converting from a scalar type to a type with
2663 a different size, pad to have the same size on both sides.
2665 2010-07-22 Eric Botcazou <ebotcazou@adacore.com>
2667 * gcc-interface/utils.c (gnat_types_compatible_p): Don't require strict
2668 equality for the component type of array types.
2670 2010-07-15 Nathan Froyd <froydnj@codesourcery.com>
2672 * gcc-interface/decl.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
2673 * gcc-interface/trans.c: Likewise.
2674 * gcc-interface/utils.c: Likewise.
2675 * gcc-interface/utils2.c: Likewise.
2677 2010-07-13 Laurent GUERBY <laurent@guerby.net>
2680 * gcc-interface/targtyps.c: Include tm_p.h.
2681 * gcc-interface/Make-lang.in: Update dependencies.
2683 2010-07-09 Eric Botcazou <ebotcazou@adacore.com>
2685 * gcc-interface/trans.c (gnat_gimplify_expr) <ADDR_EXPR>: Deal with
2688 2010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
2690 * gcc-interface/utils.c: Include diagnostic-core.h in every file
2691 that includes toplev.h.
2693 2010-07-03 Eric Botcazou <ebotcazou@adacore.com>
2695 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Enumeration_Type>:
2696 Branch to common code handling the alignment of discrete types.
2697 <E_Signed_Integer_Type>: Likewise.
2698 <E_Modular_Integer_Type>: Likewise.
2700 2010-07-02 Eric Botcazou <ebotcazou@adacore.com>
2702 * gcc-interface/misc.c (gnat_handle_option): Do not populate gnat_argv.
2703 (gnat_handle_option): Allocate only one element for gnat_argv.
2704 (gnat_init): Do not populate gnat_argv.
2706 2010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
2708 * gcc-interface/trans.c: Do not include tree-flow.h.
2709 * gcc-interface/Make-lang.in: Adjust dependencies.
2711 2010-06-29 Nathan Froyd <froydnj@codesourcery.com>
2713 * gcc-interface/gigi.h (gnat_build_constructor): Take a VEC instead
2714 of a TREE_LIST. Update comment.
2715 * gcc-interface/trans.c (gigi): Build a VEC instead of a TREE_LIST.
2716 Adjust call to gnat_build_constructor.
2717 (Attribute_to_gnu): Likewise.
2718 (gnat_to_gnu): Likewise.
2719 (pos_to_constructor): Likewise.
2720 (extract_values): Likewise.
2721 * gcc-interface/utils.c (build_template): Likewise.
2722 (convert_vms_descriptor64): Likewise.
2723 (convert_vms_descriptor32): Likewise.
2724 (convert_to_fat_pointer): Likewise.
2725 (convert): Likewise.
2726 (unchecked_convert): Likewise.
2727 * gcc-interface/decl.c (gnat_to_gnu_entity): Likewise.
2728 * gcc-interface/utils2.c (build_allocator): Likewise.
2729 (fill_vms_descriptor): Likewise.
2730 (gnat_build_constructor): Take a VEC instead of a TREE_LIST.
2731 (compare_elmt_bitpos): Adjust for parameters being constructor_elts
2732 instead of TREE_LISTs.
2734 2010-06-28 Steven Bosscher <steven@gcc.gnu.org>
2736 * gcc-interface/misc.c: Do not include except.h.
2737 * gcc-interface/Make-lang.in: Update dependencies.
2739 2010-06-27 Eric Botcazou <ebotcazou@adacore.com>
2741 * gcc-interface/trans.c: Include tree-flow.h.
2742 (gnu_switch_label_stack): Delete.
2743 (Case_Statement_to_gnu): Do not emit the goto at the end of a case if
2744 its associated block cannot fall through. Do not emit the final label
2745 if no cases branch to it.
2746 * gcc-interface/Make-lang.in (ada/trans.o): Add $(TREE_FLOW_H).
2748 2010-06-23 Thomas Quinot <quinot@adacore.com>
2750 * exp_attr.adb (Expand_Access_To_Protected_Op): When rewriting a
2751 reference to a protected subprogram outside of the protected's scope,
2752 ensure the corresponding external subprogram is frozen before the
2755 2010-06-23 Ed Schonberg <schonberg@adacore.com>
2757 * sem_prag.adb: Fix typo in error message.
2758 * sem.adb: Refine previous change.
2760 2010-06-23 Robert Dewar <dewar@adacore.com>
2762 * impunit.adb, a-suewen.adb, a-suewen.ads, a-suenco.adb, a-suenco.ads,
2763 a-suezen.adb, a-suezen.ads, a-stuten.adb, a-stuten.ads, Makefile.rtl:
2764 Implement Ada 2012 string encoding packages.
2766 2010-06-23 Arnaud Charlet <charlet@adacore.com>
2768 * a-stwiun-shared.adb, a-stwiun-shared.ads, a-stzunb-shared.adb,
2769 a-stzunb-shared.ads, a-swunau-shared.adb, a-swuwti-shared.adb,
2770 a-szunau-shared.adb, a-szuzti-shared.adb, a-strunb-shared.adb,
2771 a-strunb-shared.ads, a-stunau-shared.adb, a-suteio-shared.adb: New
2773 * gcc-interface/Makefile.in: Enable use of above files.
2775 2010-06-23 Ed Schonberg <schonberg@adacore.com>
2777 * sem_ch13.adb (Check_Constant_Address_Clauses): Do not check legality
2778 of address clauses if if Ignore_Rep_Clauses is active.
2779 * freeze.adb (Check_Address_Clause): If Ignore_Rep_Clauses is active,
2780 remove address clause from tree so that it does not reach the backend.
2782 2010-06-23 Arnaud Charlet <charlet@adacore.com>
2784 * exp_attr.adb (Expand_N_Attribute_Reference [Attribute_Valid]): Do not
2785 expand 'Valid from user code in CodePeer mode, will be handled by the
2788 2010-06-23 Bob Duff <duff@adacore.com>
2790 * g-comlin.ads: Minor comment improvements.
2792 2010-06-23 Ed Schonberg <schonberg@adacore.com>
2794 * sem_res.adb (Uses_SS): The expression that initializes a controlled
2795 component of a record type may be a user-defined operator that is
2796 rewritten as a function call.
2798 2010-06-23 Bob Duff <duff@adacore.com>
2800 * g-comlin.ads, sem_ch13.adb: Minor comment fix.
2802 2010-06-23 Eric Botcazou <ebotcazou@adacore.com>
2804 * exp_ch11.adb (Expand_Local_Exception_Handlers): Propagate the end
2805 label to the new sequence of statements. Set the sloc of the raise
2806 statement onto the new goto statements.
2808 2010-06-23 Robert Dewar <dewar@adacore.com>
2810 * a-stuten.ads, a-stuten.adb: New files.
2811 * impunit.adb: Add engtry for Ada.Strings.UTF_Encoding (a-stuten.ads)
2812 * Makefile.rtl: Add entry for a-stuten (Ada.Strings.UTF_Encoding)
2814 2010-06-23 Robert Dewar <dewar@adacore.com>
2816 * gnat_ugn.texi: Add documentation of -gnat12 switch
2817 Add documentation of -gnatX switch.
2819 2010-06-23 Ed Schonberg <schonberg@adacore.com>
2821 * inline.ads: Include the current Ada_Version in the info for pending
2822 instance bodies, so that declaration and body are compiled with the
2824 * inline.adb: Move with_clause for Opt to spec.
2825 * sem_ch12.adb (Analyze_Package_Instantiation,
2826 Analyze_Subprogram_Instantiation): Save current Ada_Version in
2827 Pending_Instantiation information.
2828 (Instantiate_Package_Body, Instantiate_Subprogram_Body,
2829 Inline_Package_Body): Use the Ada_Version present in the body
2832 2010-06-23 Robert Dewar <dewar@adacore.com>
2834 * usage.adb: Add documentation for -gnat12 switch.
2835 * errout.ads: Add VMS alias entry for -gnat12 switch
2836 * gnat_rm.texi: Add documentation for pragma Ada_12 and Ada_2012
2837 Add documentation for pragma Extensions_Allowed.
2838 * opt.ads: Add entry for Ada 2012 mode.
2839 * sem_ch4.adb, par-ch3.adb, par-ch4.adb: Use new Ada 2012 mode for 2012
2841 * sem_prag.adb, par-prag.adb: Add processing for pragma Ada_12 and
2843 * sem_ch13.adb: Add handling for Ada 2012 mode.
2844 * snames.ads-tmpl: Add entries for pragma Ada_2012 and Ada_12.
2845 * switch-c.adb: Add handling for -gnat12 switch.
2846 Implement -gnat2005 and -gnat2012.
2847 * usage.adb: Add documentation for -gnat12 switch.
2848 * vms_data.ads: Add /12 switch for Ada 2012 mode.
2850 2010-06-23 Arnaud Charlet <charlet@adacore.com>
2852 * exp_ch4.adb (Expand_N_Allocator): Fix potential crash when using
2853 No_Task_Hierarchy restriction. Add comment.
2854 * exp_ch9.adb, exp_ch3.adb: Update comments.
2856 2010-06-23 Robert Dewar <dewar@adacore.com>
2858 * sem_ch5.adb (Process_Bounds): Remove some junk initializations.
2859 * sem_res.adb: Add comments.
2860 * sem_util.adb: Minor reformatting. Add comments.
2861 Change increment on Actuals_In_Call table.
2862 * opt.ads: Minor: add 'constant'.
2864 2010-06-23 Javier Miranda <miranda@adacore.com>
2866 * exp_disp.adb (Make_DT): Initialize the Size_Func component of the
2867 TSD to Null_Address if No_Dispatching_Calls is active.
2869 2010-06-23 Vincent Celier <celier@adacore.com>
2871 * a-comlin.ads: Indicate that use of this package is not supported
2872 during the elaboration of an auto-initialized Stand-Alone Library.
2874 2010-06-23 Ed Schonberg <schonberg@adacore.com>
2876 * exp_util.adb (Is_Possibly_Misaligned_Object): Do not rely on an
2877 alignment clause on a record type to determine if a component may be
2878 misaligned. The decision must be taken in the back-end where target
2879 alignment information is known.
2881 2010-06-23 Arnaud Charlet <charlet@adacore.com>
2883 * gnat1drv.adb (Adjust_Global_Switches): Enable some restrictions
2884 systematically in CodePeer mode to simplify generated code.
2885 * restrict.adb (Check_Restriction): Do nothing in CodePeer mode.
2886 * exp_ch4.adb (Expand_N_Allocator): Generate proper code when
2887 No_Task_Hierarchy is set instead of crasshing.
2889 2010-06-23 Thomas Quinot <quinot@adacore.com>
2891 * sem_util.adb: Minor code cleanup: test for proper entity instead of
2892 testing just Chars attribute when checking whether a given scope is
2894 * exp_ch4.adb, einfo.adb: Minor reformatting.
2896 2010-06-23 Vincent Celier <celier@adacore.com>
2899 * switch-m.adb (Normalize_Compiler_Switches): Take into account
2900 switches -gnatB, -gnatD=nn, -gnatG (incuding -gnatG=nn), -gnatI,
2901 -gnatl=file, -gnatS, -gnatjnn, -gnateI=nn and -gnatWx.
2903 2010-06-23 Ed Schonberg <schonberg@adacore.com>
2905 * sem_res.adb (Resolve_Membership_Op): If left operand is a mixed mode
2906 operation with a universal real operand, and the right operand is a
2907 range with universal bounds, find unique fixed point that may be
2908 candidate, and warn appropriately.
2910 2010-06-23 Ed Schonberg <schonberg@adacore.com>
2912 * sem_res.adb (Resolve_Intrinsic_Operator): Add guards to handle
2913 properly the rare cases where VMS operators are visible through
2914 Extend_System, but the default System is being used and Address is a
2916 * sem_util.adb: Widen predicate Is_VMS_Operator.
2918 2010-06-23 Vincent Celier <celier@adacore.com>
2920 * switch-m.adb (Normalize_Compiler_Switches): Take into account -gnatC
2923 2010-06-23 Olivier Hainque <hainque@adacore.com>
2925 * einfo.adb (Has_Foreign_Convention): Consider Intrinsic with
2926 Interface_Name as foreign. These are GCC builtin imports for
2927 which Ada specific processing doesn't apply.
2929 2010-06-23 Thomas Quinot <quinot@adacore.com>
2931 * sem_ch12.adb: Minor reformatting.
2933 2010-06-23 Ed Schonberg <schonberg@adacore.com>
2935 * sem_util.adb (Is_VMS_Operator): Use scope of system extension to
2936 determine whether an intrinsic subprogram is VMS specific.
2938 2010-06-23 Hristian Kirtchev <kirtchev@adacore.com>
2940 * treepr.adb (Print_Entity_Info): Output the contents of Field28 if it
2941 is present in the entity.
2943 2010-06-23 Arnaud Charlet <charlet@adacore.com>
2945 * xr_tabls.adb, xref_lib.adb: Update to latest lib-xref.ads
2946 Fix handling of parameters.
2947 Add protection against unexpected cases.
2948 * sem_ch6.adb (Create_Extra_Formals): Use suffix "L" instead of "A" for
2949 access level, since "A" suffix is already used elsewhere. Similarly,
2950 use suffix "O" instead of "C" for 'Constrained since "C" suffix is used
2953 2010-06-23 Thomas Quinot <quinot@adacore.com>
2955 * sem_util.adb, sem_util.ads: Minor reformatting.
2957 2010-06-23 Vincent Celier <celier@adacore.com>
2959 * prj.ads (Gprclean_Flags.Missing_Source_Files): Set to Error to keep
2960 the previous behavior of gprclean when there are missing files.
2962 2010-06-23 Ed Schonberg <schonberg@adacore.com>
2964 * sem_ch12.adb (Load_Body_Of_Generic): In CodePeer mode, a missing
2965 generic body is not a fatal error.
2966 (Mark_Context): Handle properly names of child units.
2967 * sem.adb (Walk_Library_Items.Do_Action): Remove assertion on
2970 2010-06-23 Vincent Celier <celier@adacore.com>
2972 * ali.adb (Scan_ALI): When ignoring R lines, do not skip the next
2975 2010-06-23 Bob Duff <duff@adacore.com>
2977 * g-pehage.ads, g-pehage.adb: Switch default optimization mode to
2978 Memory_Space, because CPU_Time doesn't seem to provide any significant
2979 speed advantage in practice. Cleanup: Get rid of constant
2980 Default_Optimization; doesn't seem to add anything. Use case
2981 statements instead of if statements; seems cleaner.
2983 2010-06-23 Olivier Hainque <hainque@adacore.com>
2985 * gcc-interface/decl.c (gnat_to_gnu_entity) <case E_Procedure>: Use
2986 Wshadow instead of Wextra to guard warning on absence of internal
2987 builtin decl for an import. Fix use of quote in warning text.
2988 (intrin_arglists_compatible_p): Remove processing of integer trailing
2989 args on the Ada side. Fix use of literal > in warning text.
2990 (intrin_return_compatible_p): Never warn on "function imported as
2991 procedure". Defer the void/void case to the common type compatibility
2993 (gnat_to_gnu_param): Use void_ptr GCC type for System.Address argument
2994 of GCC builtin imports.
2996 2010-06-23 Olivier Hainque <hainque@adacore.com>
2998 * gcc-interface/decl.c (intrin_types_incompatible_p): New function,
3000 (intrin_arglists_compatible_p, intrin_return_compatible_p): New
3001 functions, helpers for ...
3002 (intrin_profiles_compatible_p): New function, replacement for ...
3003 (compatible_signatures_p): Removed.
3004 (gnat_to_gnu_entity) <case E_Procedure>: If -Wextra, warn on
3005 attempt to bind an unregistered builtin function. When we have
3006 one, use it and warn on profile incompatibilities.
3008 2010-06-23 Arnaud Charlet <charlet@adacore.com>
3010 * gcc-interface/Make-lang.in: Update dependencies.
3012 2010-06-23 Ed Schonberg <schonberg@adacore.com>
3014 * sem_util.adb (Mark_Coextensions): If the expression in the allocator
3015 for a coextension in an object declaration is a concatenation, treat
3016 coextension as dynamic.
3018 2010-06-23 Javier Miranda <miranda@adacore.com>
3020 * sem_ch3.adb (Add_Internal_Interface_Entities): Ensure that the
3021 internal entities are added to the scope of the tagged type.
3022 (Derive_Subprograms): Do not stop derivation when we find the first
3023 internal entity that has attribute Interface_Alias. After the change
3024 done to Override_Dispatching_Operations it is no longer true that
3025 these primirives are always located at the end of the list of
3027 * einfo.ads (Primitive_Operations): Add documentation.
3028 * exp_disp.adb (Write_DT): Improve output adding to the name of the
3029 primitive a prefix indicating its corresponding tagged type.
3030 * sem_disp.adb (Override_Dispatching_Operations): If the overridden
3031 entity covers the primitive of an interface that is not an ancestor of
3032 this tagged type then the new primitive is added at the end of the list
3033 of primitives. Required to fulfill the C++ ABI.
3035 2010-06-23 Javier Miranda <miranda@adacore.com>
3037 * atree.ads (Set_Reporting_Proc): New subprogram.
3038 * atree.adb: Remove dependency on packages Opt and SCIL_LL.
3039 (Allocate_Initialize_Node, Replace, Rewrite): Replace direct calls
3040 to routines of package Scil_ll by indirect call to the registered
3042 (Set_Reporting_Proc): New subprogram. Used to register a subprogram
3043 that is invoked when a node is allocated, replaced or rewritten.
3044 * scil_ll.adb (Copy_SCIL_Node): New routine that takes care of copying
3045 the SCIL node. Used as argument for Set_Reporting_Proc.
3046 (Initialize): Register Copy_SCIL_Node as the reporting routine that
3047 is invoked by atree.
3049 2010-06-23 Thomas Quinot <quinot@adacore.com>
3051 * sem_ch3.ads: Minor reformatting.
3053 2010-06-23 Ed Schonberg <schonberg@adacore.com>
3055 * sem_ch12.adb (Analyze_Package_Instantiation): In CodePeer mode,
3056 always analyze the generic body and instance, because it may be needed
3058 (Mark_Context): Prepend the with clauses for needed generic units, so
3059 they appear in a better order for CodePeer.
3060 * sem_util.adb, sem_util.ads: Prototype code for AI05-0144.
3062 2010-06-23 Emmanuel Briot <briot@adacore.com>
3064 * prj.ads, prj-nmsc.adb (Error_Or_Warning): New subprogram.
3066 2010-06-23 Robert Dewar <dewar@adacore.com>
3068 * g-pehage.adb, exp_ch13.adb: Minor reformatting.
3070 2010-06-23 Thomas Quinot <quinot@adacore.com>
3072 * a-tags.ads: Fix description of TSD structure.
3074 2010-06-23 Ed Schonberg <schonberg@adacore.com>
3076 * sem_ch12.adb (Mark_Context): When indicating that the body of a
3077 generic unit is needed prior to the unit containing an instantiation,
3078 search recursively the context of the generic to add other generic
3079 bodies that may be instantiated indirectly through the current instance.
3081 2010-06-23 Robert Dewar <dewar@adacore.com>
3083 * freeze.adb: Minor reformatting.
3085 2010-06-23 Bob Duff <duff@adacore.com>
3087 * g-pehage.adb (Trim_Trailing_Nuls): Fix the code to match the comment.
3089 2010-06-23 Vincent Celier <celier@adacore.com>
3091 * make.adb (Compile_Sources): Complete previous change.
3093 2010-06-23 Ed Schonberg <schonberg@adacore.com>
3095 * sem_ch6.adb (Add_Extra_Formal): Use suffix "C" in the name of the
3096 Constrained extra formal.
3098 2010-06-23 Ed Schonberg <schonberg@adacore.com>
3100 * exp_ch13.adb (Expand_Freeze_Actions): If validity checks and
3101 Initialize_Scalars are enabled, compile the generated equality function
3102 for a composite type with full checks enabled, so that validity checks
3103 are performed on individual components.
3105 2010-06-23 Emmanuel Briot <briot@adacore.com>
3107 * prj.adb, prj.ads, prj-nmsc.adb (Processing_Flags): New flag
3108 Missing_Source_Files.
3110 2010-06-23 Robert Dewar <dewar@adacore.com>
3112 * exp_ch3.adb, exp_util.adb: Minor reformatting.
3114 2010-06-23 Jose Ruiz <ruiz@adacore.com>
3116 * a-reatim.adb, a-retide.adb: Move the initialization of the tasking
3117 run time from Ada.Real_Time.Delays to Ada.Real_Time. This way, calls to
3118 Clock (without delays) use a run time which is properly initialized.
3120 2010-06-23 Vincent Celier <celier@adacore.com>
3122 * make.adb: Do not set Check_Readonly_Files when setting Must_Compile,
3123 when -f -u and a main is specified on the command line. However,
3124 attempt to compile even when the ALI file is read-only when
3125 Must_Compile is True.
3127 2010-06-23 Thomas Quinot <quinot@adacore.com>
3129 * checks.adb, g-pehage.adb, cstand.adb: Minor code factorization.
3131 2010-06-23 Javier Miranda <miranda@adacore.com>
3133 * sem_ch3.adb (Add_Internal_Interface_Entities): Generate internal
3134 entities for parent types that are interfaces. Needed in generics to
3135 handle formals that implement interfaces.
3136 (Derive_Subprograms): Add assertion for derivation of tagged types that
3137 do not cover interfaces. For generics, complete code that handles
3138 derivation of type that covers interfaces because the previous
3139 condition was weak (it required only name consistency; arguments were
3140 not checked). Add new code to locate primitives covering interfaces
3141 defined in generic units or instantiatons.
3142 * sem_util.adb (Has_Interfaces): Add missing support for derived types.
3143 * sem_ch6.adb (Check_Overriding_Indicator): Minor code cleanups.
3144 * exp_disp.adb (Make_Select_Specific_Data_Table): Skip primitives of
3145 interfaces that are parents of the type because they share the primary
3147 (Register_Primitive): Do not register primitives of interfaces that
3148 are parents of the type.
3149 * sem_ch13.adb (Analyze_Freeze_Entity): Add documentation.
3150 * exp_cg.adb (Write_Type_Info): When displaying overriding of interface
3151 primitives skip primitives of interfaces that are parents of the type.
3153 2010-06-23 Ed Schonberg <schonberg@adacore.com>
3155 * sem_attr.adb (Eval_Attribute): If the prefix is an array, the
3156 attribute cannot be constant-folded if an index type is a formal type,
3157 or is derived from one.
3158 * checks.adb (Determine_Range): ditto.
3160 2010-06-23 Arnaud Charlet <charlet@adacore.com>
3162 * gnat_ugn.texi, gnatxref.adb: Add support for --ext switch.
3164 2010-06-23 Bob Duff <duff@adacore.com>
3166 * g-pehage.ads, g-pehage.adb (Put): Fix off-by-one bug.
3167 (Insert): Disallow nul characters.
3168 (misc output routines): Assert no nul characters.
3170 2010-06-23 Ed Schonberg <schonberg@adacore.com>
3172 * exp_ch4.adb: Use predefined unsigned type in all cases.
3174 2010-06-23 Bob Duff <duff@adacore.com>
3176 * s-rannum.adb (Reset): Avoid overflow in calculation of Initiator.
3177 * g-pehage.ads: Minor comment fixes.
3178 * g-pehage.adb: Minor: Add some additional debugging printouts under
3181 2010-06-23 Robert Dewar <dewar@adacore.com>
3183 * binde.adb (Better_Choice): Always prefer Pure/Preelab.
3184 (Worse_Choice): Always prefer Pure/Preelab.
3186 2010-06-23 Vincent Celier <celier@adacore.com>
3188 * a-reatim.adb: Call System.OS_Primitives.Initialize during elaboration
3190 2010-06-23 Robert Dewar <dewar@adacore.com>
3192 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Properly handle
3193 checking returns in generic case.
3194 (Check_Missing_Return): New procedure.
3196 2010-06-23 Robert Dewar <dewar@adacore.com>
3198 * bindgen.adb, switch-b.adb: Minor reformatting.
3200 2010-06-23 Javier Miranda <miranda@adacore.com>
3202 * frontend.adb (Frontend): Add call to initialize the new package
3204 * exp_ch7.adb (Wrap_Transient_Expression): Remove call to
3206 (Wrap_Transient_Statement): Remove call to Adjust_SCIL_Node.
3207 * sem_ch5.adb (Analyze_Iteration_Scheme.Process_Bounds): Remove call to
3209 * exp_util.adb (Insert_Actions): Remove code for
3210 N_SCIL_Dispatch_Table_Object_Init and N_SCIL_Tag_Init nodes.
3211 (Remove_Side_Effects): Remove calls to Adjust_SCIL_Node.
3212 * sinfo.adb (SCIL_Entity, SCIL_Tag_Value): Remove checks on
3213 N_SCIL_Tag_Init and N_SCIL_Dispatch_Table_Object_Init in the assertion.
3214 (SCIL_Related_Node, Set_SCIL_Related_Node): Removed.
3215 * sinfo.ads (SCIL_Related_Node): Field removed.
3216 (N_SCIL_Dispatch_Table_Object_Init): Node removed.
3217 (N_SCIL_Tag_Init): Node removed.
3218 * sem_scil.ads, sem_scil.adb (Adjust_SCIL_Node): Removed.
3219 (Check_SCIL_Node): New implementation.
3220 (Find_SCIL_Node): Removed.
3221 * sem.adb (Analyze): Remove management of
3222 N_SCIL_Dispatch_Table_Object_Init and N_SCIL_Tag_Init nodes.
3223 * sem_util.adb (Insert_Explicit_Dereference): Remove call to
3225 * exp_ch4.adb (Expand_N_In): Code cleanup: remove call to
3226 Set_SCIL_Related_Node and avoid adding the SCIL node before the
3227 referenced node using Insert_Action because this is not longer required.
3228 (Expand_Short_Circuit_Operator): Remove call to SCIL node.
3229 * exp_ch6.adb (Expand_Call): Remove call to Adjust_SCIL_Node.
3230 * sem_ch4.adb (Analyze_Type_Conversion): Remove call to Adjust_SCIL_Node
3231 * exp_disp.adb (Expand_Dispatching_Call): Minor code reorganization
3232 because we no longer require to generate the SCIL node before the call.
3233 (Make_DT): Remove generation of SCI_Dispatch_Table_Object_Init node.
3234 Remove calls to Set_SCIL_Related_Node and avoid adding the SCIL
3235 nodes before the referenced node using Insert_Action because this
3236 is not longer required.
3237 * atree.adb (Allocate_Initialize_Node, Replace, Rewrite): Add call to
3238 update the SCIL_Node field.
3239 * sprint.adb (Sprint_Node_Actual): Remove code for
3240 N_SCIL_Dispatch_Table_Object_Init and N_SCIL_Tag_Init nodes.
3241 * treepr.adb (Print_Node): Print the SCIL node field (if available).
3242 * exp_ch3.adb (Build_Init_Procedure): Remove generation of
3243 SCIL_Tag_Init nodes.
3244 * scil_ll.ads, scil_ll.adb: New files.
3245 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
3248 2010-06-23 Robert Dewar <dewar@adacore.com>
3250 * sem_ch6.adb: Minor reformatting.
3252 2010-06-23 Doug Rupp <rupp@adacore.com>
3254 * bindusg.adb (Display): Write -Hnn line.
3255 * bindgen.adb (Gen_Adainit_Ada): Write Heap_Size to binder file as
3257 * init.c (__gl_heap_size): Rename from __gl_no_malloc_64 and change
3258 valid values to 32 and 64.
3259 (GNAT$NO_MALLOC_64): Recognize TRUE, 1, FALSE, and 0 in addition to
3260 ENABLE, DISABLE as valid settings.
3261 * switch-b.adb (Scan_Binder_Switches): Process -Hnn switch.
3262 * opt.ads (Heap_Size): New global variable.
3263 * gcc-interface/utils2.c (maybe_wrap_malloc): Remove mostly redundant
3264 TARGET_MALLOC64 check. Fix comment.
3266 2010-06-23 Robert Dewar <dewar@adacore.com>
3268 * sem_ch6.adb, exp_ch4.adb, s-rannum.ads, sem.adb, sem_ch12.adb: Minor
3269 reformatting. Add comments.
3270 * errout.adb (Finalize): Properly adjust warning count when deleting
3273 2010-06-22 Robert Dewar <dewar@adacore.com>
3275 * errout.adb (Finalize): Set Prev pointers.
3276 (Finalize): Delete continuations for deletion by warnings off(str).
3277 * erroutc.ads: Add Prev pointer to error message structure.
3279 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3281 * sem.adb (Do_Unit_And_Dependents): If the spec of the main unit is a
3282 child unit, examine context of parent units to locate instantiated
3283 generics whose bodies may be needed.
3284 * sem_ch12.adb: (Mark_Context): if the enclosing unit does not have a
3285 with_clause for the instantiated generic, examine the context of its
3286 parents, to set Withed_Body flag, so that it can be visited earlier.
3287 * exp_ch4.adb (Expand_N_Op_Not): If this is a VMS operator applied to
3288 an unsigned type, use a type of the proper size for the intermediate
3289 value, to prevent alignment problems on unchecked conversion.
3291 2010-06-22 Geert Bosch <bosch@adacore.com>
3293 * s-rannum.ads Change Generator type to be self-referential to allow
3294 Random to update its argument. Use "in" mode for the generator in the
3295 Reset procedures to allow them to be called from the Ada.Numerics
3296 packages without tricks.
3297 * s-rannum.adb: Use the self-referencing argument to get write access
3298 to the internal state of the random generator.
3299 * a-nudira.ads: Make Generator a derived type of
3300 System.Random_Numbers.Generator.
3301 * a-nudira.adb: Remove use of 'Unrestricted_Access.
3302 Put subprograms in alpha order and add headers.
3303 * g-mbdira.ads: Change Generator type to be self-referential.
3304 * g-mbdira.adb: Remove use of 'Unrestricted_Access.
3306 2010-06-22 Robert Dewar <dewar@adacore.com>
3308 * freeze.adb: Minor reformatting
3309 Minor code reorganization (use Nkind_In and Ekind_In).
3311 2010-06-22 Bob Duff <duff@adacore.com>
3313 * gnat1drv.adb (Gnat1drv): Remove the messages that recommend using
3314 -gnatc when a file is compiled that we cannot generate code for, not
3315 helpful and confusing.
3317 2010-06-22 Vincent Celier <celier@adacore.com>
3319 * switch-m.adb (Normalize_Compiler_Switches): Process correctly
3322 2010-06-22 Paul Hilfinger <hilfinger@adacore.com>
3324 * s-rannum.adb: Replace constants with commented symbols.
3325 * s-rannum.ads: Explain significance of the initial value of the data
3328 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3330 * a-ngcoty.adb: Clarify comment.
3332 2010-06-22 Gary Dismukes <dismukes@adacore.com>
3334 * exp_pakd.adb (Expand_Bit_Packed_Element_Set): Return without
3335 expansion for indexing packed arrays with small power-of-2 component
3336 sizes when the target is AAMP.
3337 (Expand_Packed_Element_Reference): Return without expansion for
3338 indexing packed arrays with small power-of-2 component sizes when the
3341 2010-06-22 Geert Bosch <bosch@adacore.com>
3343 * exp_ch4.adb (Expand_N_In): Do not substitute a valid check for X in
3346 2010-06-22 Robert Dewar <dewar@adacore.com>
3348 * g-mbdira.adb, g-mbflra.adb, a-nuflra.adb, a-nudira.adb: Minor comment
3351 2010-06-22 Doug Rupp <rupp@adacore.com>
3353 * system-vms.ads, system-vms-zcx.ads: Remove old unused VMS system
3355 * system-vms_64.ads, system-vms-ia64.ads: Minor reformatting.
3356 (pragma Ident): Add a default ident string in the private part.
3358 2010-06-22 Robert Dewar <dewar@adacore.com>
3360 * cstand.adb: Minor reformatting.
3362 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3364 * freeze.adb (Build_And_Analyze_Renamed_Body): For expansion purposes,
3365 recognize the Shift and Rotation intrinsics that are known to the
3366 compiler but have no interface name.
3368 2010-06-22 Geert Bosch <bosch@adacore.com>
3370 * a-ngcoty.adb ("*"): Rewrite complex multiplication to use proper
3371 scaling in case of overflow or NaN results.
3373 2010-06-22 Robert Dewar <dewar@adacore.com>
3375 * cstand.adb: Complete previous change.
3376 * g-dirope.ads: Add comment.
3377 * s-stchop.adb, sfn_scan.adb: Minor reformatting.
3379 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3381 * cstand.adb: Add tree nodes for pragma Pack on string types.
3383 2010-06-22 Javier Miranda <miranda@adacore.com>
3385 * einfo.ads, einfo.adb (Last_Formal): New synthesized attribute.
3386 * exp_util.adb (Find_Prim_Op): Use new attribute to locate the last
3387 formal of a primitive.
3388 * exp_disp.adb (Is_Predefined_Dispatching_Operation,
3389 Is_Predefined_Dispatching_Alias): Use new attribute to locate the last
3390 formal of a primitive.
3391 * exp_cg.adb (Is_Predefined_Dispatching_Operation): Use new attribute
3392 to obtain the last formal of a primitive.
3394 2010-06-22 Geert Bosch <bosch@adacore.com>
3396 * sysdep.c, init.c, adaint.c, cstreams.c: Remove conditional code
3397 depending on __EMX__ or MSDOS being defined.
3398 * i-cstrea.ads, gnat_rm.texi: Remove mentions of OS/2, DOS and Xenix.
3399 * a-excpol-abort.adb: Update comment indicating users of the file.
3400 * xref_lib.adb, sfn_scan.adb: Remove mention of OS/2, replace NT by
3402 * env.c: Remove empty conditional for MSDOS.
3403 * s-stchop.adb, g-dirope.ads, s-fileio.adb, osint.ads: Remove mention
3406 2010-06-22 Robert Dewar <dewar@adacore.com>
3408 * s-rannum.adb: Minor reformatting.
3410 2010-06-22 Javier Miranda <miranda@adacore.com>
3412 * sem_aux.adb, sem_aux.ads, sem_util.adb, sem_util.ads, sem_elim.adb,
3413 exp_cg.adb: Minor code reorganization: Move routine Ultimate_Alias from
3414 package Sem_Util to package Sem_Aux.
3416 2010-06-22 Javier Miranda <miranda@adacore.com>
3418 * exp_disp.adb (Make_Secondary_DT, Make_DT): Minor code cleanup:
3419 remove useless restriction on imported routines when building the
3422 2010-06-22 Robert Dewar <dewar@adacore.com>
3424 * cstand.adb (Create_Standard): Set Has_Pragma_Pack for standard string
3427 2010-06-22 Javier Miranda <miranda@adacore.com>
3429 * sem_ch4.adb (Collect_Generic_Type_Ops): Protect code that handles
3430 generic subprogram declarations to ensure proper context. Add missing
3431 support for generic actuals.
3432 (Try_Primitive_Operation): Add missing support for concurrent types that
3433 have no Corresponding_Record_Type. Required to diagnose errors compiling
3434 generics or when compiling with no code generation (-gnatc).
3435 * sem_ch9.adb (Analyze_Protected_Type, Analyze_Task_Type): Do not build
3436 the corresponding record type.
3437 * sem_disp.ads, sem_disp.adb (Check_Dispatching_Operation): Complete
3438 documentation. Do minimum decoration when processing a primitive of a
3439 concurrent tagged type that covers interfaces. Required to diagnose
3440 errors in the Object.Operation notation compiling generics or under
3442 * exp_ch9.ads, exp_ch9.adb (Build_Corresponding_Record): Add missing
3443 propagation of attribute Interface_List to the corresponding record.
3444 (Expand_N_Task_Type_Declaration): Code cleanup.
3445 (Expand_N_Protected_Type_Declaration): Code cleanup.
3447 2010-06-22 Matthew Heaney <heaney@adacore.com>
3449 * a-convec.adb, a-coinve.adb: Removed 64-bit types Int and UInt.
3451 2010-06-22 Paul Hilfinger <hilfinger@adacore.com>
3453 * s-rannum.adb (Random_Float_Template): Replace with unbiased version
3454 that is able to produce all representable floating-point numbers in the
3455 unit interval. Remove template parameter Shift_Right, no longer used.
3456 * gnat_rm.texi: Document the period of the pseudo-random number
3457 generator under the description of its algorithm.
3458 * gcc-interface/Make-lang.in: Update dependencies.
3460 2010-06-22 Thomas Quinot <quinot@adacore.com>
3462 * exp_aggr.adb (Rewrite_Discriminant): Fix predicate used to identify
3463 reference to discriminant (can be an expanded name as well as an
3466 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3468 * exp_ch6.adb: Clarify comment.
3470 2010-06-22 Geert Bosch <bosch@adacore.com>
3472 * exp_imgv.adb (Expand_Image_Attribute): Treat ordinary fixed point
3473 with decimal small as decimal types, avoiding floating-point arithmetic.
3474 (Has_Decimal_Small): New function.
3475 * einfo.ads, einfo.adb (Aft_Value): New synthesized attributed for
3477 * sem_attr.adb (Eval_Attribute): Remove Aft_Value function and update
3478 callers to call the new function in Einfo that takes the entity as
3481 2010-06-22 Robert Dewar <dewar@adacore.com>
3483 * sem_ch3.adb, sem_ch8.adb: Minor reformatting.
3485 2010-06-22 Thomas Quinot <quinot@adacore.com>
3487 * sem_elab.adb: Minor reformatting.
3489 2010-06-22 Vincent Celier <celier@adacore.com>
3491 * gnatsym.adb: Put the object files in the table in increasing
3492 aphabetical order of base names.
3494 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3496 * sem_ch8.adb (Set_Entity_Or_Discriminal): New procedure used by
3497 Find_Direct_Name and Find_Expanded_Name, to replace a discriminant with
3498 the corresponding discriminal within a record declaration.
3500 2010-06-22 Thomas Quinot <quinot@adacore.com>
3502 * exp_aggr.adb (Rewrite_Discriminant): Rewriting must occur only for an
3503 expression referring to a discriminal of the type of the aggregate (not
3504 a discriminal of some other unrelated type), and the prefix in the
3505 generated selected component must come from Lhs, not Obj.
3507 2010-06-22 Thomas Quinot <quinot@adacore.com>
3509 * sem_ch3.adb (Build_Derived_Record_Type): Fix predicate determining
3510 when to freeze the parent type.
3512 2010-06-22 Robert Dewar <dewar@adacore.com>
3514 * s-rannum.adb, a-nudira.adb, types.ads, freeze.adb, sem_aggr.adb,
3515 exp_aggr.adb: Minor reformatting.
3516 * gnat_rm.texi: Document GNAT.MBBS_Discrete_Random and
3517 GNAT.MBSS_Float_Random.
3518 * g-mbdira.adb, g-mbflra.adb, g-mbdira.ads, g-mbflra.ads: Fix header.
3520 2010-06-22 Paul Hilfinger <hilfinger@adacore.com>
3522 * a-nudira.adb, a-nudira.ads, a-nuflra.adb, a-nuflra.ads,
3523 gnat_rm.texi, impunit.adb, Makefile.rtl, s-rannum.adb
3524 (Random_Float_Template, Random): New method of creating
3525 uniform floating-point variables that allow the creation of all machine
3528 * g-mbdira.adb, g-mbflra.adb, g-mbdira.ads, g-mbflra.ads: New file.
3530 2010-06-22 Gary Dismukes <dismukes@adacore.com>
3532 * sem_ch5.adb (Analyze_Assignment): Revise test for illegal assignment
3533 to abstract targets to check that the type is tagged and comes from
3534 source, rather than only testing for targets of interface types. Remove
3537 2010-06-22 Vincent Celier <celier@adacore.com>
3539 * vms_data.ads: Modify the declarations of qualifiers
3540 /UNCHECKED_SHARED_LIB_IMPORTS to allow the generation of gnat.hlp
3543 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3545 * exp_ch6.adb (Is_Build_In_Place_Function): Predicate is false if
3546 expansion is disabled.
3548 2010-06-22 Robert Dewar <dewar@adacore.com>
3550 * makeusg.adb: Minor reformatting.
3552 2010-06-22 Robert Dewar <dewar@adacore.com>
3554 * types.ads: (Dint): Removed, no longer used anywhere.
3555 * uintp.adb (UI_From_CC): Use UI_From_Int, range is sufficient.
3556 (UI_Mul): Avoid use of UI_From_Dint.
3557 (UI_From_Dint): Removed, not used.
3558 * uintp.ads (UI_From_Dint): Removed, not used.
3559 (Uint_Min/Max_Simple_Mul): New constants.
3561 2010-06-22 Vincent Celier <celier@adacore.com>
3563 * clean.adb (Parse_Cmd_Line): Recognize switch
3564 --unchecked-shared-lib-imports.
3565 (Usage): Add line for switch --unchecked-shared-lib-imports
3566 * makeusg.adb: Add line for switch --unchecked-shared-lib-imports
3567 * makeutl.ads: (Unchecked_Shared_Lib_Imports): New constant string
3568 moved from GPR_Util.
3569 * switch-m.adb (Scan_Make_Switches): Recognize switch
3570 --unchecked-shared-lib-imports.
3571 * vms_data.ads: Add VMS qualifiers /UNCHECKED_SHARED_LIB_IMPORTS.
3572 * gnat_ugn.texi: Add documentation for new switch
3573 --unchecked-shared-lib-imports. Add also documentation for --subdirs.
3575 2010-06-22 Javier Miranda <miranda@adacore.com>
3577 * sem_prag.adb, sem_util.adb, sem_util.ads, sem_attr.adb, exp_ch6.adb,
3578 exp_disp.adb, sem_eval.adb, exp_dist.adb lib-xref.adb: Code cleanup,
3579 this patch replaces duplication of code that traverses the chain of
3580 aliased primitives by a call to routine Ultimate_Alias that
3581 provides this functionality.
3583 2010-06-22 Arnaud Charlet <charlet@adacore.com>
3585 * fmap.adb, opt.ads, osint.adb, osint.ads, output.ads, scng.adb,
3586 sinput-c.adb, switch-m.ads, tree_io.ads: Use simpler form of
3589 2010-06-22 Thomas Quinot <quinot@adacore.com>
3591 * einfo.ads: Minor reformatting.
3593 2010-06-22 Javier Miranda <miranda@adacore.com>
3595 * exp_disp.adb (Expand_Interface_Thunk): Do not generate thunk of
3596 eliminated primitives.
3597 (Make_DT): Avoid referencing eliminated primitives.
3598 (Register_Primitive): Do not register eliminated primitives in the
3599 dispatch table. Required to add this functionality when the program is
3600 compiled without static dispatch tables (-gnatd.t)
3602 2010-06-22 Emmanuel Briot <briot@adacore.com>
3604 * fmap.adb, scng.adb, switch-m.ads, sinput-c.adb, opt.ads, output.ads,
3605 tree_io.ads, osint.adb, osint.ads: Use configuration pragmas to prevent
3606 warnings on use of internal GNAT units.
3608 2010-06-22 Jose Ruiz <ruiz@adacore.com>
3610 * s-taprop-vxworks.adb (Set_Priority): Update comments.
3612 2010-06-22 Paul Hilfinger <hilfinger@adacore.com>
3614 * s-rannum.adb: Make stylistic change to remove mystery constant in
3615 Extract_Value. Image_Numeral_Length: new symbolic constant.
3617 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3619 * einfo.ads, einfo.adb: Make Is_Protected_Interface,
3620 Is_Synchronized_Interface, Is_Task_Interface into computable
3621 predicates, to free three flags in entity nodes.
3622 * sem_ch3.adb: Remove setting of these flags.
3624 2010-06-22 Robert Dewar <dewar@adacore.com>
3626 * uintp.adb, osint.adb, prj-conf.adb, prj-part.adb, prj.adb: Minor
3628 * s-taprop-vxworks.adb: Add comment for Set_Priority.
3629 * impunit.adb (Map_Array): Add entries for s-htable.ads and s-crc32.ads
3630 * projects.texi: Move @cindex to the left margin, since otherwise we
3631 are missing entries in the index.
3633 2010-06-22 Emmanuel Briot <briot@adacore.com>
3635 * prj-part.adb, prj.adb, tempdir.ads, makeutl.adb: Use
3636 packages from the GNAT hierarchy instead of System when possible.
3637 * gcc-interface/Make-lang.in: Update dependencies.
3639 2010-06-22 Jose Ruiz <ruiz@adacore.com>
3641 * s-taprop-vxworks.adb (Set_Priority): Remove the code that was
3642 previously in place to reorder the ready queue when a task drops its
3643 priority due to the loss of inherited priority.
3645 2010-06-22 Vincent Celier <celier@adacore.com>
3647 * projects.texi: Minor spelling error fixes.
3650 2010-06-22 Emmanuel Briot <briot@adacore.com>
3652 * prj-part.adb, prj-ext.adb, prj.adb, makeutl.adb, prj-conf.adb: Remove
3653 warnings for some with clauses.
3655 2010-06-22 Robert Dewar <dewar@adacore.com>
3657 * errout.adb (Unwind_Internal_Type): Improve handling of First_Subtype
3658 test to catch more cases where first subtype is the results we want.
3659 * sem_res.adb (Make_Call_Into_Operator): Don't go to First_Subtype in
3660 error case, since Errout will now handle this correctly.
3661 * gcc-interface/Make-lang.in: Add Sem_Aux to list of GNATBIND objects.
3662 Update dependencies.
3664 2010-06-22 Arnaud Charlet <charlet@adacore.com>
3666 * exp_ch4.adb (Expand_Allocator_Expression): Set Related_Node properly
3667 when calling Make_Temporary.
3669 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3671 * sem_ch3.adb (Access_Subprogram_Declaration): An anonymous access to
3672 subprogram can be associated with an entry body.
3674 2010-06-22 Robert Dewar <dewar@adacore.com>
3676 * scos.ads: Add note on membership test handling.
3678 2010-06-22 Vincent Celier <celier@adacore.com>
3680 * projects.texi: Minor spelling fixes.
3683 2010-06-22 Paul Hilfinger <hilfinger@adacore.com>
3685 * s-rannum.adb: Correct off-by-one error in Extract_Value.
3687 2010-06-22 Vincent Celier <celier@adacore.com>
3689 * mlib-prj.adb (Display): In non verbose mode, truncate after fourth
3691 * mlib-utl.adb (Gcc): In non verbose mode, truncate the display of the
3692 gcc command if it is too long.
3694 2010-06-22 Robert Dewar <dewar@adacore.com>
3696 * errout.adb (Set_Msg_Node): Fix incorrect reference to node.
3698 2010-06-22 Arnaud Charlet <charlet@adacore.com>
3700 * exp_ch6.adb (Expand_Actuals): Use Actual as the related node when
3701 calling Make_Temporary.
3703 2010-06-22 Robert Dewar <dewar@adacore.com>
3705 * sem_res.adb, sem_aux.adb, errout.adb: Minor reformatting.
3707 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3709 * sem_res.adb: Additional special-case for VMS.
3711 2010-06-22 Vincent Celier <celier@adacore.com>
3713 * gnatsym.adb: Minor comment fix.
3715 2010-06-22 Vincent Celier <celier@adacore.com>
3717 * prj-nmsc.adb (Process_Naming_Scheme): Initialize table Lib_Data_Table.
3719 2010-06-22 Robert Dewar <dewar@adacore.com>
3721 * par-ch4.adb (P_Name): Recognize 'Mod attribute in Ada 95 mode
3722 * sem_attr.adb (Attribute_05): Add Name_Mod so that 'Mod recognized in
3723 Ada 95 mode as an implementation defined attribute.
3725 2010-06-22 Vincent Celier <celier@adacore.com>
3727 * bindusg.adb (Display): Update line for -R
3728 * switch-b.adb (Scan_Binder_Switches): Allow generation of the binder
3729 generated files when -R is used.
3731 2010-06-22 Vincent Celier <celier@adacore.com>
3733 * prj-nmsc.adb (Lib_Data_Table): New table.
3734 (Check_Library_Attributes): Check if the same library name is used in
3735 two different projects that do not extend each other.
3737 2010-06-22 Robert Dewar <dewar@adacore.com>
3739 * lib-writ.ads, errout.adb, einfo.adb, einfo.ads: Minor reformatting.
3741 2010-06-22 Vincent Celier <celier@adacore.com>
3743 * adaint.c (__gnat_locate_regular_file): If a directory in the path is
3744 empty, make it the current working directory.
3746 2010-06-22 Thomas Quinot <quinot@adacore.com>
3748 * sem_ch3.adb (Build_Derived_Record_Type): When deriving a tagged
3749 private type with discriminants, make sure the parent type is frozen.
3751 2010-06-22 Eric Botcazou <ebotcazou@adacore.com>
3753 * exp_attr.adb (Expand_N_Attribute_Reference) <Attribute_Bit>: Deal
3754 with packed array references specially.
3755 * exp_ch4.adb (Expand_N_Indexed_Component): Do not convert a reference
3756 to a component of a bit packed array if it is the prefix of 'Bit.
3757 * exp_pakd.ads (Expand_Packed_Bit_Reference): Declare.
3758 * exp_pakd.adb (Expand_Packed_Bit_Reference): New procedure. Expand a
3759 'Bit reference, where the prefix involves a packed array reference.
3760 (Get_Base_And_Bit_Offset): New helper, extracted from...
3761 (Expand_Packed_Address_Reference): ...here. Call above procedure to
3762 get the outer object and offset expression.
3764 2010-06-22 Thomas Quinot <quinot@adacore.com>
3766 * exp_attr.adb, lib-writ.ads, bindgen.adb: Minor reformatting.
3767 * einfo.adb (Related_Expression, Set_Related_Expression): Add
3770 2010-06-22 Javier Miranda <miranda@adacore.com>
3772 * sem_ch3.adb (Add_Internal_Interface_Entities): Minor code
3773 reorganization to properly check if the operation has been inherited as
3774 an abstract operation.
3776 2010-06-22 Ed Falis <falis@adacore.com>
3778 * s-osinte-vxworks.ads: Complete previous change.
3780 2010-06-22 Thomas Quinot <quinot@adacore.com>
3782 * sem_res.adb: Add comment.
3783 * projects.texi, gnat_ugn.texi: Remove macro.
3785 2010-06-22 Vincent Celier <celier@adacore.com>
3787 * prj-attr.adb: Remove project level attribute Main_Language.
3789 2010-06-22 Robert Dewar <dewar@adacore.com>
3791 * switch-b.adb, osint-b.adb: Minor reformatting.
3793 2010-06-22 Pascal Obry <obry@adacore.com>
3795 * g-socthi-mingw.adb (C_Sendmsg): Do not attempt to send data from a
3796 vector if previous send was not fully successful. If only part of
3797 the vector data was sent, we exit the loop.
3799 2010-06-22 Thomas Quinot <quinot@adacore.com>
3801 * sem_res.adb (Make_Call_Into_Operator): Use First_Subtype for better
3802 error reporting with generic types.
3804 2010-06-22 Thomas Quinot <quinot@adacore.com>
3806 * bindgen.adb, bindusg.adb, gnatbind.adb, gnat_ugn.texi, opt.ads,
3807 osint-b.adb, osint-b.ads, output.adb, output.ads, switch-b.adb,
3808 vms_data.ads: Add a new command line switch -A to gnatbind to output
3809 the list of all ALI files for the partition.
3811 2010-06-22 Arnaud Charlet <charlet@adacore.com>
3813 * s-osinte-vxworks.ads: Fix casing.
3814 * s-vxwext-kernel.ads, s-vxwext-rtp.ads: Complete previous
3815 change: Interfaces.C does not provide a long_long type.
3817 2010-06-22 Emmanuel Briot <briot@adacore.com>
3819 * gnat_ugn.texi, projects.texi: Preprocess projects.texi for VMS and
3820 native user's guide, since this document contains the two versions.
3821 * gcc-interface/Make-lang.in: Update doc dependencies.
3823 2010-06-22 Robert Dewar <dewar@adacore.com>
3825 * sem_ch3.adb: Minor reformatting. Minor code reorganization.
3827 2010-06-22 Emmanuel Briot <briot@adacore.com>
3829 * gnat_ugn.texi, projects.texi: Remove toplevel menu, since we should
3830 not build this file on its own (only through gnat_ugn.texi).
3831 Remove macro definitions and insert simpler version in gnat_ugn.texi.
3833 2010-06-22 Robert Dewar <dewar@adacore.com>
3835 * ali-util.ads: Minor comment update.
3836 * g-socthi-mingw.adb: Minor reformatting.
3838 2010-06-22 Ed Falis <falis@adacore.com>
3840 * s-osinte-vxworks.ads: take sigset_t definition from System.VxWorks.Ext
3841 * s-vxwext.ads, s-vxwext-kernel.ads, s-vxwext-rtp.ads: Define sigset_t
3842 for specific versions of VxWorks.
3844 2010-06-22 Emmanuel Briot <briot@adacore.com>
3846 * gnat_rm.texi, gnat_ugn.texi, projects.texi: Remove all project files
3847 related sections from user's guide and reference manual, since they
3848 have now been merged together into a separate document (projects.texi).
3849 This removes a lot of duplication where attributes where described
3851 The grammar for the project files is now in each of the sections
3852 (packages,expressions,...) instead of being duplicates in two other
3853 sections (one in the user's guide that contained the full grammar,
3854 and various sections in the rm that contained extracts of the same
3856 Added the full list of all supported attributes, since existing lists
3858 Rename "associative array" into "indexed attribute"
3859 Remove sections that were duplicates ("External References in
3860 Project Files" and "External Values", and "Project Extensions"
3861 for instance). The list of valid packages in project files is now in
3864 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3866 * sem_ch3.adb (Add_Internal_Interface_Entities): If
3867 Find_Primitive_Covering_Interface does not find the operation, it may
3868 be because of a name conflict between the inherited operation and a
3869 local non-overloadable name. In that case look for the operation among
3870 the primitive operations of the type. This search must succeed
3871 regardless of visibility.
3873 2010-06-22 Pascal Obry <obry@adacore.com>
3875 * g-socthi-mingw.adb: Properly honor MSG_WAITALL in recvmsg.
3876 (C_Recvmsg): Propely honor the MSG_WAITALL flag in Windows
3879 2010-06-22 Robert Dewar <dewar@adacore.com>
3881 * sem_ch4.adb (Analyze_Conditional_Expression): Defend against
3883 * sprint.adb (Sprint_Node_Actual, case N_Conditional_Expression): Ditto.
3885 2010-06-22 Arnaud Charlet <charlet@adacore.com>
3887 * s-intman-vxworks.ads: Code clean up.
3889 2010-06-22 Thomas Quinot <quinot@adacore.com>
3891 * sem_res.adb (Resolve_Slice): When the prefix is an explicit
3892 dereference, construct actual subtype of designated object to generate
3893 proper bounds checks.
3895 2010-06-22 Thomas Quinot <quinot@adacore.com>
3897 * ali-util.adb, ali-util.ads, gnatbind.adb (Read_ALI): Rename to
3898 Read_Withed_ALIs, which is more descriptive.
3900 2010-06-22 Pascal Obry <obry@adacore.com>
3902 * g-sothco.ads: Minor reformatting.
3903 * g-socthi-mingw.adb: Remove part of work on the C_Recvmsg and
3904 C_Sendmsg implementation.
3905 (C_Sendmsg): Do not use lock (not needed).
3906 (C_Recvmsg): Likewise and also do not wait for incoming data.
3908 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3910 * uintp.adb: Fix scope error in operator call.
3912 2010-06-22 Vincent Celier <celier@adacore.com>
3914 * makeutl.adb (Executable_Prefix_Path): on VMS, return "/gnu/".
3915 * prj-conf.adb (Get_Or_Create_Configuration_File): On VMS, if
3916 autoconfiguration is needed, fail indicating that no config project
3917 file can be found, as there is no autoconfiguration on VMS.
3919 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3921 * sem_res.adb (Make_Call_Into_Operator): Diagnose an incorrect scope
3922 for an operator in a functional notation, when operands are universal.
3924 2010-06-22 Arnaud Charlet <charlet@adacore.com>
3926 * gcc-interface/Make-lang.in: Update dependencies.
3928 2010-06-22 Robert Dewar <dewar@adacore.com>
3930 * sem_aggr.adb (Resolve_Record_Aggregate): Do style check on component
3932 * sem_ch10.adb (Analyze_Subunit): Do style check on parent unit name.
3933 * sem_ch8.adb (Find_Direct_Name): For non-overloadable entities, do
3935 * sem_res.adb (Resolve_Entity_Name): Do style check for enumeration
3938 2010-06-22 Vincent Celier <celier@adacore.com>
3940 * make.adb (Scan_Make_Arg): No longer pass -nostdlib to the compiler as
3941 it has no effect. Always pass -nostdlib to gnatlink, even on VMS.
3943 2010-06-22 Pascal Obry <obry@adacore.com>
3945 * g-socthi-mingw.adb: Fix implementation of the vectored sockets on
3947 (C_Recvmsg): Make sure the routine is atomic. Also fully
3948 fill vectors in the proper order.
3949 (C_Sendmsg): Make sure the routine is atomic.
3951 2010-06-22 Robert Dewar <dewar@adacore.com>
3953 * sem_ch8.adb: Update comment.
3954 * sem_res.adb: Minor code reorganization (use Ekind_In).
3956 2010-06-22 Ed Schonberg <schonberg@adacore.com>
3958 * sem_ch8.adb (Add_Implicit_Operator): If the context of the expanded
3959 name is a call, use the number of actuals to determine whether this is
3960 a binary or unary operator, rather than relying on later information
3961 to resolve the overload.
3963 2010-06-22 Robert Dewar <dewar@adacore.com>
3965 * sem_ch10.adb, sem_aggr.adb: Minor reformatting.
3967 2010-06-22 Robert Dewar <dewar@adacore.com>
3969 * sem_ch3.adb, sem_disp.adb: Minor code fixes.
3970 * sem_eval.adb: Minor reformatting.
3972 2010-06-22 Vincent Celier <celier@adacore.com>
3974 * make.adb (Scan_Make_Arg): When invoked with -nostdlib, pass -nostdlib
3975 to gnatlink, except on Open VMS.
3976 * osint.adb (Add_Default_Search_Dirs): Do not suppress the default
3977 object directories if -nostdlib is used.
3979 2010-06-22 Robert Dewar <dewar@adacore.com>
3981 * sem_util.adb (Is_Delegate): Put in proper alpha order.
3982 * sem_eval.adb: Minor reformatting.
3984 2010-06-22 Robert Dewar <dewar@adacore.com>
3986 * g-expect-vms.adb, sem_res.adb: Minor reformatting.
3987 * exp_aggr.adb: Minor comment changes and reformatting.
3988 * sem_eval.adb (Find_Universal_Operator_Type): Put in proper alpha order
3989 * sem_util.ads: Add some missing pragma Inline's (efficiency issue only)
3991 2010-06-22 Thomas Quinot <quinot@adacore.com>
3993 * sem_util.adb (Build_Actual_Subtype): Record original expression in
3994 Related_Expression attribute of the constructed subtype.
3995 * einfo.adb, einfo.ads (Underlying_View): Move to Node28 to free up
3996 Node24 on types for...
3997 (Related_Expression): Make attribute available on types as well.
3999 2010-06-22 Gary Dismukes <dismukes@adacore.com>
4001 * exp_util.adb (Find_Interface_ADT): Retrieve Designated_Type instead of
4002 Directly_Designated_Type when the type argument is an access type.
4003 (Find_Interface_Tag): Retrieve Designated_Type instead of
4004 Directly_Designated_Type when the type argument is an access type.
4005 (Has_Controlled_Coextensions): Retrieve Designated_Type instead of
4006 Directly_Designated_Type of each access discriminant.
4007 * sem_res.adb (Resolve_Type_Conversion): Retrieve Designated_Type
4008 instead of Directly_Designated_Type when the operand and target types
4011 2010-06-22 Thomas Quinot <quinot@adacore.com>
4013 * exp_aggr.adb (Flatten): Return False if one choice is statically
4014 known to be out of bounds.
4016 2010-06-22 Ed Schonberg <schonberg@adacore.com>
4018 * sem_res.adb (Resolve_Call): If the call is rewritten as an indexed of
4019 a parameterless function call, preserve parentheses of original
4020 expression, for proper handling by pretty printer.
4021 * sem_attr.adb (Analyze_Attribute, case 'Old): Add guard to Process
4022 procedure, to handle quietly identifiers that have no entity names.
4023 * exp_util.adb (Get_Current_Value_Condition): If the parent of an
4024 elsif_part is missing, it has been rewritten as a nested if, and there
4025 is no useful information on the current value of the variable.
4027 2010-06-22 Gary Dismukes <dismukes@adacore.com>
4029 * sem_ch3.adb (Build_Discriminal): Set default scopes for newly created
4030 discriminals to the current scope.
4031 * sem_util.adb (Find_Body_Discriminal): Remove setting of discriminal's
4032 scope, which could overwrite a different already set value.
4034 2010-06-22 Ed Schonberg <schonberg@adacore.com>
4036 * sem_res.adb (Valid_Conversion): If expression is a predefined
4037 operator, use sloc of type of interpretation to improve error message
4038 when operand is of some derived type.
4039 * sem_eval.adb (Is_Mixed_Mode_Operand): New function, use it.
4041 2010-06-22 Emmanuel Briot <briot@adacore.com>
4043 * g-expect-vms.adb (Expect_Internal): No longer raises an exception, so
4044 that it can set out parameters as well. When a process has died, reset
4045 its Input_Fd to Invalid_Fd, so that when using multiple processes we
4046 can find out which process has died.
4048 2010-06-22 Thomas Quinot <quinot@adacore.com>
4050 * sem_eval.adb (Find_Universal_Operator_Type): New
4051 subprogram to identify the operand type of an operator on universal
4052 operands, when an explicit scope indication is present. Diagnose the
4053 case where such a call is ambiguous.
4054 (Eval_Arithmetic_Op, Eval_Relational_Op, Eval_Unary_Op):
4055 Use the above to identify the operand type so it can be properly frozen.
4056 * sem_res.adb (Make_Call_Into_Operator): Remove bogus freeze of operand
4057 type, done in an arbitrary, possibly incorrect type (the presence of
4058 some numeric type in the scope is checked for legality, but when more
4059 than one such type is in the scope, we just pick a random one, not
4060 necessarily the expected one).
4061 * sem_utils.ads, sem_utils.adb (Is_Universal_Numeric_Type): New utility
4064 2010-06-22 Robert Dewar <dewar@adacore.com>
4066 * sem_eval.adb: Minor reformatting.
4068 2010-06-22 Robert Dewar <dewar@adacore.com>
4070 * exp_ch4.adb (Expand_N_Conditional_Expression): Use
4071 Expression_With_Actions to clean up the code generated when folding
4072 constant expressions.
4074 2010-06-22 Vincent Celier <celier@adacore.com>
4076 * g-expect-vms.adb: Add new subprograms Free, First_Dead_Process and
4079 2010-06-22 Vincent Celier <celier@adacore.com>
4081 * prj-nmsc.adb (Find_Sources): When a source from a multi-unit file is
4082 found, check if it's path has aready been found, whatever its index.
4084 2010-06-22 Robert Dewar <dewar@adacore.com>
4086 * atree.adb, gnatbind.adb: Minor reformatting.
4087 Minor code reorganization.
4089 2010-06-21 Robert Dewar <dewar@adacore.com>
4091 * exp_ch4.adb (Expand_N_Conditional_Expression): Fold if condition
4092 known at compile time.
4094 2010-06-21 Gary Dismukes <dismukes@adacore.com>
4096 * atree.adb: Fix comment typo.
4098 2010-06-21 Ed Schonberg <schonberg@adacore.com>
4100 * sem_eval.adb (Test_Ambiguous_Operator): New procedure to check
4101 whether a universal arithmetic expression in a conversion, which is
4102 rewritten from a function call with an expanded name, is ambiguous.
4104 2010-06-21 Vincent Celier <celier@adacore.com>
4106 * prj-nmsc.adb (Name_Location): New Boolean component Listed, to record
4107 source files in specified list of sources.
4108 (Check_Package_Naming): Remove out parameters Bodies and Specs, as they
4110 (Add_Source): Set the Location of the new source
4111 (Process_Exceptions_File_Based): Call Add_Source with the Location
4112 (Get_Sources_From_File): If an exception is found, set its Listed to
4114 (Find_Sources): When Source_Files is specified, if an exception is
4115 found, set its Listed to True. Remove any exception that is not in a
4116 specified list of sources.
4117 * prj.ads (Source_Data): New component Location
4119 2010-06-21 Vincent Celier <celier@adacore.com>
4121 * gnatbind.adb (Closure_Sources): Global table, moved from block.
4123 2010-06-21 Thomas Quinot <quinot@adacore.com>
4125 * sem_res.adb: Minor reformatting.
4126 * atree.adb: New debugging hook "rr" for node rewrites.
4128 2010-06-21 Robert Dewar <dewar@adacore.com>
4130 * g-expect.ads, g-expect.adb: Minor reformatting.
4132 2010-06-21 Emmanuel Briot <briot@adacore.com>
4134 * s-regpat.adb (Next_Pointer_Bytes): New named constant. Code clean up.
4136 2010-06-21 Arnaud Charlet <charlet@adacore.com>
4138 * gcc-interface/Make-lang.in: Update dependencies.
4140 2010-06-21 Thomas Quinot <quinot@adacore.com>
4142 * bindgen.ads: Update comments.
4144 2010-06-21 Vincent Celier <celier@adacore.com>
4146 * gnatbind.adb: Suppress dupicates when listing the sources in the
4147 closure (switch -R).
4149 2010-06-21 Emmanuel Briot <briot@adacore.com>
4151 * s-regpat.adb (Link_Tail): Fix error when size of the pattern matcher
4154 2010-06-21 Emmanuel Briot <briot@adacore.com>
4156 * g-expect.adb, g-expect.ads (First_Dead_Process, Free, Has_Process):
4158 (Expect_Internal): No longer raises an exception, so that it can set
4159 out parameters as well. When a process has died, reset its Input_Fd
4160 to Invalid_Fd, so that when using multiple processes we can find out
4161 which process has died.
4163 2010-06-21 Robert Dewar <dewar@adacore.com>
4165 * s-regpat.adb, s-tpoben.adb, sem_attr.adb, sem_util.adb, sem_util.ads,
4166 checks.adb, sem_res.adb: Minor reformatting. Add comments.
4168 2010-06-21 Ed Schonberg <schonberg@adacore.com>
4170 * sem_ch6.adb (New_Overloaded_Entity): If the new entity is a
4171 rederivation associated with a full declaration in a private part, and
4172 there is a partial view that derives the same parent subprogram, the
4173 new entity does not become visible. This check must be applied to
4174 interface operations as well.
4176 2010-06-21 Thomas Quinot <quinot@adacore.com>
4178 * checks.adb: Add comments.
4179 * prj-nmsc.adb: Minor reformatting.
4181 2010-06-21 Thomas Quinot <quinot@adacore.com>
4183 * sem_ch9.adb, checks.adb, sem_util.adb, sem_util.ads, sem_res.adb,
4184 sem_attr.adb (Get_E_First_Or_Last): Use attribute references on E to
4185 extract bounds, to ensure that we get the proper captured values,
4186 rather than an expression that may have changed value since the point
4187 where the subtype was elaborated.
4188 (Find_Body_Discriminal): New utility subprogram to share code between...
4189 (Eval_Attribute): For the case of a subtype bound that references a
4190 discriminant of the current concurrent type, insert appropriate
4191 discriminal reference.
4192 (Resolve_Entry.Actual_Index_Type.Actual_Discriminant_Ref): For a
4193 requeue to an entry in a family in the current task, use corresponding
4195 (Analyze_Accept_Statement): Rely on expansion of attribute references
4196 to insert proper discriminal references in range check for entry in
4199 2010-06-21 Emmanuel Briot <briot@adacore.com>
4201 * s-regpat.adb (Compile): Fix handling of big patterns.
4203 2010-06-21 Robert Dewar <dewar@adacore.com>
4205 * a-tifiio.adb: Minor reformatting.
4207 2010-06-21 Pascal Obry <obry@adacore.com>
4209 * prj-nmsc.adb (Search_Directories): Use the non-translated directory
4212 2010-06-21 Javier Miranda <miranda@adacore.com>
4214 * exp_cg.adb (Write_Call_Info): Fill the component sourcename using the
4217 2010-06-21 Ed Schonberg <schonberg@adacore.com>
4219 * exp_ch4.adb (Expand_Concatenate): If an object declaration is created
4220 to hold the result, indicate that the target of the declaration does
4221 not need an initialization, to prevent spurious errors when
4222 Initialize_Scalars is enabled.
4224 2010-06-21 Ed Schonberg <schonberg@adacore.com>
4226 * a-tifiio.adb (Put): In the procedure that performs I/O on a String,
4227 Fore is not bound by line length. The Fore parameter of the internal
4228 procedure that performs the operation is an integer.
4230 2010-06-21 Thomas Quinot <quinot@adacore.com>
4232 * sem_res.adb, checks.adb: Minor reformatting.
4234 2010-06-21 Emmanuel Briot <briot@adacore.com>
4236 * s-regpat.adb (Next_Instruction, Get_Next_Offset): Removed, merged
4238 (Insert_Operator_Before): New subprogram, avoids duplicated code
4239 (Compile): Avoid doing two compilations when the pattern matcher ends
4242 2010-06-21 Emmanuel Briot <briot@adacore.com>
4244 * s-regpat.adb: Improve debug traces
4245 (Dump): Change output format to keep it smaller.
4247 2010-06-21 Javier Miranda <miranda@adacore.com>
4249 * exp_cg.adb (Generate_CG_Output): Disable redirection of standard
4250 output to the output file when this routine completes its work.
4252 2010-06-20 Eric Botcazou <ebotcazou@adacore.com>
4254 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Use while instead of
4255 for loop. Call build_constructor_from_list directly in the CICO case.
4257 2010-06-18 Ed Schonberg <schonberg@adacore.com>
4259 * freeze.adb (Build_And_Analyze_Renamed_Body): If the renaming
4260 declaration appears in the same unit and ealier than the renamed
4261 entity, retain generated body to prevent order-of-elaboration issues in
4264 2010-06-18 Arnaud Charlet <charlet@adacore.com>
4266 * s-tpoben.adb: Update comments.
4268 2010-06-18 Robert Dewar <dewar@adacore.com>
4270 * debug.adb: Minor comment change.
4272 2010-06-18 Javier Miranda <miranda@adacore.com>
4274 * exp_cg.adb: Code clean up.
4275 * debug.adb: Complete documentation of switch -gnatd.Z.
4276 * gcc-interface/misc.c (callgraph_info_file): Declare.
4278 2010-06-18 Javier Miranda <miranda@adacore.com>
4280 * exp_cg.adb (Homonym_Suffix_Length): Minor code reorganization.
4282 2010-06-18 Thomas Quinot <quinot@adacore.com>
4284 * sprint.ads: Minor reformatting.
4285 * output.ads: Update obsolete comment.
4287 2010-06-18 Ed Schonberg <schonberg@adacore.com>
4289 * freeze.adb (Build_And_Analyze_Renamed_Body): if the renamed entity is
4290 an external intrinsic operation (e.g. a GCC numeric function) indicate
4291 that the renaming entity has the same characteristics, so a call to it
4292 is properly expanded.
4294 2010-06-18 Javier Miranda <miranda@adacore.com>
4296 * exp_cg.adb, exp_cg.ads, exp_disp.adb, gnat1drv.adb: Add initial
4297 support for dispatch table/callgraph info generation.
4298 * gcc-interface/Make-lang.in: Update dependencies.
4300 2010-06-18 Robert Dewar <dewar@adacore.com>
4302 * exp_ch6.adb: Minor reformatting.
4303 * gnatname.adb: Add comment.
4305 2010-06-18 Vincent Celier <celier@adacore.com>
4307 * gnatname.adb (Scan_Args): When --and is used, make sure that the
4308 dynamic tables in the newly allocated Argument_Data are properly
4311 2010-06-18 Eric Botcazou <ebotcazou@adacore.com>
4313 * gnat1drv.adb: Fix comment.
4315 2010-06-18 Ed Schonberg <schonberg@adacore.com>
4317 * exp_ch6.adb (Expand_Inlined_Call): If the inlined subprogram is a
4318 renaming, re-expand the call with the renamed subprogram if that one
4319 is marked inlined as well.
4321 2010-06-18 Gary Dismukes <dismukes@adacore.com>
4323 * gnat1drv.adb (Adjust_Global_Switches): Enable
4324 Use_Expression_With_Actions for AAMP and VM targets.
4326 2010-06-18 Vincent Celier <celier@adacore.com>
4328 * prj-nmsc.adb (Process_Linker): Recognize response file format GCC.
4330 2010-06-18 Thomas Quinot <quinot@adacore.com>
4332 * exp_ch4.adb: Minor reformatting.
4334 2010-06-18 Javier Miranda <miranda@adacore.com>
4336 * debug.ads Add documentation on -gnatd.Z.
4338 2010-06-18 Ed Schonberg <schonberg@adacore.com>
4340 * sem_elim.adb: Proper error message on improperly eliminated instances
4342 2010-06-18 Vincent Celier <celier@adacore.com>
4344 * prj.ads (Response_File_Format): New value GCC.
4346 2010-06-18 Thomas Quinot <quinot@adacore.com>
4348 * gnat1drv.adb: Minor reformatting.
4350 2010-06-18 Robert Dewar <dewar@adacore.com>
4352 * make.adb, sem_cat.adb: Minor reformatting.
4353 * sem_eval.adb: Fix typos.
4355 2010-06-18 Pascal Obry <obry@adacore.com>
4357 * prj-nmsc.adb: Fix source filenames casing in debug output.
4359 2010-06-18 Robert Dewar <dewar@adacore.com>
4361 * gnatcmd.adb: Minor reformatting.
4363 2010-06-18 Robert Dewar <dewar@adacore.com>
4365 * sem_eval.adb (Eval_Conditional_Expression): Result is static if
4366 condition and both sub-expressions are static (and result is selected
4369 2010-06-18 Robert Dewar <dewar@adacore.com>
4371 * g-pehage.adb: Minor reformatting
4373 2010-06-18 Pascal Obry <obry@adacore.com>
4375 * prj-nmsc.adb (Search_Directories): Insert canonical filenames into
4378 2010-06-18 Arnaud Charlet <charlet@adacore.com>
4380 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
4381 dependencies. Fix target pairs on darwin.
4382 (gnatlib-sjlj, gnatlib-zcx): Pass THREAD_KIND.
4384 2010-06-18 Pascal Obry <obry@adacore.com>
4386 * make.adb, prj-nmsc.adb: Fix source filenames casing in debug output.
4388 2010-06-18 Vincent Celier <celier@adacore.com>
4390 * gnatcmd.adb: For gnatcheck, add -gnatec= switch for a global
4391 configuration pragmas file and, if -U is not used, for a local one.
4393 2010-06-18 Ed Schonberg <schonberg@adacore.com>
4395 * sem_elim.adb (Check_Eliminated): Use full information on entity name
4396 when it is given in the pragma by a selected component.
4397 (Check_For_Eliminated_Subprogram): Do no emit error if within a
4398 instance body that is itself within a generic unit.
4399 * sem_ch12.adb (Analyze_Subprogram_Instance): If the subprogram is
4400 eliminated, mark as well the anonymous subprogram that is its alias
4401 and appears within the wrapper package.
4403 2010-06-18 Bob Duff <duff@adacore.com>
4405 * g-pehage.ads, g-pehage.adb (Produce): Clean up some of the code.
4406 Raise an exception if the output file cannot be opened. Add comments.
4408 2010-06-18 Thomas Quinot <quinot@adacore.com>
4410 * sem_cat.adb (Validate_Object_Declaration): A variable declaration is
4411 not illegal per E.2.2(7) if it occurs in the private part of a
4414 2010-06-18 Arnaud Charlet <charlet@adacore.com>
4416 * par-ch9.adb, sem_aggr.adb, sem_ch3.adb, layout.adb, sem_ch4.adb,
4417 sem_ch5.adb, sem_mech.adb, exp_util.adb, par-ch10.adb, sem_ch6.adb,
4418 par-ch11.adb, sem_ch7.adb, par-prag.adb, exp_disp.adb, par-ch12.adb,
4419 sem_ch8.adb, style.adb, sem_ch9.adb, sem_ch10.adb, prep.adb,
4420 sem_warn.adb, par-util.adb, scng.adb, sem_eval.adb, checks.adb,
4421 sem_prag.adb, sem_ch12.adb, styleg.adb, sem_ch13.adb, par-ch3.adb,
4422 par-tchk.adb, freeze.adb, sfn_scan.adb, par-ch4.adb, sem_util.adb,
4423 sem_res.adb, par-ch5.adb, lib-xref.adb, sem_attr.adb, par-ch6.adb,
4424 sem_disp.adb, prepcomp.adb, par-ch7.adb, sem_elab.adb, exp_ch4.adb,
4425 errout.ads: Update comments. Minor reformatting.
4427 * g-spipat.adb, a-swunau.adb, a-swunau.ads, g-spitbo.adb,
4428 a-szunau.adb, a-szunau.ads, a-stunau.adb, a-stunau.ads,
4429 a-strunb.adb (Big_String. Big_String_Access): New type.
4431 * par-labl.adb, restrict.adb, s-osinte-hpux-dce.ads, sem_ch11.adb,
4432 exp_pakd.adb, s-filofl.ads, par-endh.adb, exp_intr.adb, sem_cat.adb,
4433 sem_case.adb, exp_ch11.adb, s-osinte-linux.ads: Fix copyright notices.
4435 2010-06-18 Geert Bosch <bosch@adacore.com>
4437 * i-forbla-darwin.adb: Include -lgnala and -lm in linker options for
4440 2010-06-18 Robert Dewar <dewar@adacore.com>
4442 * gnat1drv.adb (Adjust_Global_Switches): Set Use_Expression_With_Actions
4445 2010-06-18 Robert Dewar <dewar@adacore.com>
4447 * sprint.adb: Minor format change for N_Expression_With_Actions.
4448 * repinfo.adb: Minor reformatting.
4450 2010-06-18 Ed Schonberg <schonberg@adacore.com>
4452 * sem_elim.adb (Check_Eliminated): If within a subunit, use
4453 Defining_Entity to obtain the name of the entity in the proper body, to
4454 properly handle both separate packages and subprograms.
4456 2010-06-18 Emmanuel Briot <briot@adacore.com>
4458 * prj-nmsc.adb (Check_File): New parameter Display_Path.
4460 2010-06-18 Thomas Quinot <quinot@adacore.com>
4462 * g-socket.adb, g-socket.ads (Null_Selector): New object.
4464 2010-06-18 Pascal Obry <obry@adacore.com>
4466 * gnat_ugn.texi: Minor clarification.
4468 2010-06-18 Emmanuel Briot <briot@adacore.com>
4470 * prj-nmsc.adb (Find_Source_Dirs): Minor refactoring to avoid duplicate
4471 code when using the project dir as the source dir.
4472 (Search_Directories): use the normalized name for the source directory,
4473 where symbolic names have potentially been resolved.
4475 2010-06-18 Robert Dewar <dewar@adacore.com>
4477 * exp_ch4.adb (Expand_N_Conditional_Expression): Clear Actions field
4478 when we create N_Expression_With_Actions node.
4479 (Expand_Short_Circuit): Ditto.
4481 2010-06-18 Robert Dewar <dewar@adacore.com>
4483 * exp_util.adb: Minor reformatting.
4485 2010-06-18 Thomas Quinot <quinot@adacore.com>
4487 * types.ads: Clean up obsolete comments
4488 * tbuild.adb: Minor reformatting.
4489 * exp_ch5.adb, sem_intr.adb, sem_ch10.adb, rtsfind.adb, s-shasto.adb,
4490 exp_strm.adb, aa_drive.adb: Minor reformatting.
4491 * sem_res.adb (Is_Predefined_Operator): An operator that is an imported
4492 intrinsic with an Interface_Name denotes an imported back-end builtin,
4493 and must be rewritten into a call, not left in the tree as an operator,
4494 so return False in that case.
4496 2010-06-18 Eric Botcazou <ebotcazou@adacore.com>
4498 * exp_util.adb (Remove_Side_Effects): Make a copy for an allocator.
4500 2010-06-18 Robert Dewar <dewar@adacore.com>
4502 * scos.ads: Add proposed output for case expression
4504 2010-06-18 Jose Ruiz <ruiz@adacore.com>
4506 * gnat_ugn.texi: Document that, when using the RTX compiler to generate
4507 RTSS modules, we need to use the Microsoft linker.
4509 2010-06-18 Robert Dewar <dewar@adacore.com>
4511 * checks.adb (Safe_To_Capture_In_Parameter_Value): Deal with case
4512 expression (cannot count on a particular branch being executed).
4513 * exp_ch4.adb (Expand_N_Case_Expression): New procedure.
4514 * exp_ch4.ads (Expand_N_Case_Expression): New procedure.
4515 * exp_util.adb (Insert_Actions): Deal with proper insertion of actions
4516 within case expression.
4517 * expander.adb (Expand): Add call to Expand_N_Case_Expression
4518 * par-ch4.adb Add calls to P_Case_Expression at appropriate points
4519 (P_Case_Expression): New procedure
4520 (P_Case_Expression_Alternative): New procedure
4521 * par.adb (P_Case_Expression): New procedure
4522 * par_sco.adb (Process_Decisions): Add dummy place holder entry for
4524 * sem.adb (Analyze): Add call to Analyze_Case_Expression
4525 * sem_case.ads (Analyze_Choices): Also used for case expressions now,
4526 this is a documentation change only.
4527 * sem_ch4.ads, sem_ch4.adb (Analyze_Case_Expression): New procedure.
4528 * sem_ch6.adb (Fully_Conformant_Expressions): Add handling of case
4530 * sem_eval.ads, sem_eval.adb (Eval_Case_Expression): New procedure.
4531 * sem_res.adb (Resolve_Case_Expression): New procedure.
4532 * sem_scil.adb (Find_SCIL_Node): Add processing for
4533 N_Case_Expression_Alternative.
4534 * sinfo.ads, sinfo.adb (N_Case_Expression): New node.
4535 (N_Case_Expression_Alternative): New node.
4536 * sprint.adb (Sprint_Node_Actual): Add processing for new nodes
4537 N_Case_Expression and N_Case_Expression_Alternative.
4539 2010-06-18 Robert Dewar <dewar@adacore.com>
4541 * par-ch7.adb, sem_warn.adb, types.ads, par-ch3.adb: Minor reformatting.
4542 * gnat1drv.adb: Fix typo.
4544 2010-06-18 Robert Dewar <dewar@adacore.com>
4546 * par-prag.adb (Prag, case Style_Checks): All_Checks sets gnat style
4548 * sem_prag.adb (Analyze_Pragma, case Style_Checks): All_Checks sets
4549 gnat style for -gnatg.
4550 * gnat_rm.texi: Add documentation for ALL_CHECKS in GNAT mode.
4552 2010-06-18 Thomas Quinot <quinot@adacore.com>
4554 * sem_eval.adb (Test_In_Range): New subprogram, factoring duplicated
4556 (Is_In_Range, Is_Out_Of_Range): Reimplement in terms of call to
4559 2010-06-18 Robert Dewar <dewar@adacore.com>
4561 * sprint.adb: Minor change in output format for expression wi actions.
4562 * par-ch3.adb: Minor code reorganization. Minor reformatting.
4563 * sem_ch5.adb: Minor comment fix.
4565 2010-06-18 Robert Dewar <dewar@adacore.com>
4567 * debug.adb: New debug flag -gnatd.L to control
4568 Back_End_Handles_Limited_Types.
4569 * exp_ch4.adb (Expand_N_Conditional_Expression): Let back end handle
4570 limited case if Back_End_Handles_Limited_Types is True.
4571 (Expand_N_Conditional_Expression): Use N_Expression_With_Actions to
4572 simplify expansion if Use_Expression_With_Actions is True.
4573 * gnat1drv.adb (Adjust_Global_Switches): Set
4574 Back_End_Handles_Limited_Types.
4575 * opt.ads (Back_End_Handles_Limited_Types): New flag.
4577 2010-06-18 Ed Schonberg <schonberg@adacore.com>
4579 * sem_res.adb (Rewrite_Operator_As_Call): Do not rewrite user-defined
4580 intrinsic operator if expansion is not enabled, because in an
4581 instantiation the original operator must be present to verify the
4582 legality of the operation.
4584 2010-06-18 Robert Dewar <dewar@adacore.com>
4586 * exp_disp.adb, sem_ch12.adb: Minor reformatting
4588 2010-06-18 Ed Schonberg <schonberg@adacore.com>
4590 * exp_util.adb (Make_Subtype_From_Expr): If the unconstrained type is
4591 the class-wide type for a private extension, and the completion is a
4592 subtype, set the type of the class-wide type to the base type of the
4595 2010-06-18 Robert Dewar <dewar@adacore.com>
4597 * g-socket.ads, sem_aggr.adb, einfo.ads, sem_elim.adb,
4598 sem_intr.adb, sem_eval.adb: Minor reformatting
4600 2010-06-18 Ed Schonberg <schonberg@adacore.com>
4602 * sem_type.adb (Is_Ancestor): If either type is private, examine full
4605 2010-06-18 Thomas Quinot <quinot@adacore.com>
4607 * g-socket.adb, g-socket.ads (Check_Selector): Make Selector an IN
4608 parameter rather than IN OUT.
4610 2010-06-18 Ed Schonberg <schonberg@adacore.com>
4612 * exp_ch6.adb: Add extra guard.
4614 2010-06-18 Gary Dismukes <dismukes@adacore.com>
4616 * sem_util.adb (Object_Access_Level): For Ada 2005, determine the
4617 accessibility level of a function call from the level of the innermost
4618 enclosing dynamic scope.
4619 (Innermost_Master_Scope_Depth): New function to find the depth of the
4620 nearest dynamic scope enclosing a node.
4622 2010-06-18 Tristan Gingold <gingold@adacore.com>
4624 * adaint.c: Make ATTR_UNSET static as it is not used outside this file.
4626 2010-06-18 Thomas Quinot <quinot@adacore.com>
4628 * g-socket.ads: Minor reformatting.
4630 2010-06-18 Vincent Celier <celier@adacore.com>
4632 * make.adb (Must_Compile): New Boolean global variable
4633 (Main_On_Command_Line): New Boolean global variable
4634 (Collect_Arguments_And_Compile): Do compile if Must_Compile is True,
4635 even when the project is externally built.
4636 (Start_Compile_If_Possible): Compile in -aL directories if
4637 Check_Readonly_Files is True. Do compile if Must_Compile is True, even
4638 when the project is externally built.
4639 (Gnatmake): Set Must_Compile and Check_Readonly_Files to True when
4640 invoked with -f -u and one or several mains on the command line.
4641 (Scan_Make_Arg): Set Main_On_Command_Line to True when at least one main
4642 is specified on the command line.
4644 2010-06-18 Ed Schonberg <schonberg@adacore.com>
4646 * sem_ch6.adb (Build_Body_For_Inline): Handle extended_return_statements
4647 * exp_ch6.adb (Expand_Inlined_Call): when possible, inline a body
4648 containing extented_return statements.
4649 * exp_util.adb (Make_CW_Equivalent_Type): If the root type is already
4650 constrained, do not build subtype declaration.
4652 2010-06-18 Robert Dewar <dewar@adacore.com>
4654 * sem_res.adb (Analyze_Indexed_Component, Analyze_Selected_Component):
4655 Warn on assigning to packed atomic component.
4657 2010-06-18 Robert Dewar <dewar@adacore.com>
4659 * sem_util.ads: Minor reformatting
4660 * einfo.ads, einfo.adb: Minor doc clarification (scope of decls in
4661 Expression_With_Actions).
4662 * snames.ads-tmpl: Minor comment fix
4664 2010-06-18 Robert Dewar <dewar@adacore.com>
4666 * sem_prag.adb (Diagnose_Multiple_Pragmas): New procedure
4667 (Set_Imported): Use Import_Interface_Present to control message output
4668 * sinfo.ads, sinfo.adb (Import_Interface_Present): New flag
4669 * gnat_rm.texi: Document that we can have pragma Import and pragma
4670 Interface for the same subprogram.
4672 2010-06-18 Robert Dewar <dewar@adacore.com>
4674 * lib-xref.adb (Generate_Reference): Fix bad reference to
4675 Has_Pragma_Unreferenced (clients should always use Has_Unreferenced).
4677 2010-06-17 Eric Botcazou <ebotcazou@adacore.com>
4679 * gcc-interface/trans.c (set_gnu_expr_location_from_node): New static
4681 (gnat_to_gnu) <N_Expression_With_Actions>: New case.
4682 Use set_gnu_expr_location_from_node to set location information on the
4685 2010-06-17 Arnaud Charlet <charlet@adacore.com>
4687 * gcc-interface/Make-lang.in: Update dependencies.
4689 2010-06-17 Ed Schonberg <schonberg@adacore.com>
4691 * sem_util.adb (Is_Atomic_Object): Predicate does not apply to
4694 2010-06-17 Robert Dewar <dewar@adacore.com>
4696 * gnat_rm.texi, gnat_ugn.texi: Clean up documentation on warning and
4697 style check messages.
4698 * sem_res.adb (Resolve_Call): Don't call
4699 Check_For_Eliminated_Subprogram if we are analyzing within a spec
4702 2010-06-17 Robert Dewar <dewar@adacore.com>
4704 * debug.adb: Add documentation for debug flags .X and .Y
4705 * exp_ch4.adb (Expand_Short_Circuit_Operator): Use
4706 Use_Expression_With_Actions.
4707 * gnat1drv.adb (Adjust_Global_Switches): Set
4708 Use_Expression_With_Actions.
4709 * opt.ads (Use_Expression_With_Actions): New switch.
4711 2010-06-17 Robert Dewar <dewar@adacore.com>
4713 * exp_intr.adb: Minor code reorganization (use UI_Max)
4714 * sem_intr.adb: use underlying type to check legality.
4715 * einfo.adb (Known_Static_Esize): False for generic types
4716 (Known_Static_RM_Size): False for generic types
4717 * einfo.ads (Known_Static_Esize): False for generic types
4718 (Known_Static_RM_Size): False for generic types
4720 2010-06-17 Robert Dewar <dewar@adacore.com>
4722 * exp_ch4.ads: Minor code reorganization (specs in alpha order).
4724 2010-06-17 Robert Dewar <dewar@adacore.com>
4726 * debug.adb: New debug flag -gnatd.X to use Expression_With_Actions
4727 node when expanding short circuit form with actions present for right
4729 * exp_ch4.adb: Minor reformatting
4730 (Expand_Short_Circuit_Operator): Use new Expression_With_Actions node if
4731 right opeand has actions present, and debug flag -gnatd.X is set.
4732 * exp_util.adb (Insert_Actions): Handle case of Expression_With_Actions
4734 * nlists.adb (Prepend_List): New procedure
4735 (Prepend_List_To): New procedure
4736 * nlists.ads (Prepend_List): New procedure
4737 (Prepend_List_To): New procedure
4738 * sem.adb: Add processing for Expression_With_Actions
4739 * sem_ch4.adb (Analyze_Expression_With_Actions): New procedure
4740 * sem_ch4.ads (Analyze_Expression_With_Actions): New procedure
4741 * sem_res.adb: Add processing for Expression_With_Actions.
4742 * sem_scil.adb: Add processing for Expression_With_Actions
4743 * sinfo.ads, sinfo.adb (N_Expression_With_Actions): New node.
4744 * sprint.ads, sprint.adb: Add processing for Expression_With_Actions
4746 2010-06-17 Doug Rupp <rupp@adacore.com>
4748 * sem_intr.adb (Check_Intrinsic_Operator): Check that the types
4749 involved both have underlying integer types.
4750 * exp_intr.adb (Expand_Binary_Operator) New subprogram to expand a call
4751 to an intrinsic operator when the operand types or sizes are not
4753 * s-auxdec-vms_64.ads: Revert "+" "-" ops back to Address now that
4754 64/32 Address/Integer works.
4756 2010-06-17 Ed Schonberg <schonberg@adacore.com>
4758 * sem_ch12.adb (Mark_Context): Refine placement of Withed_Body flag, so
4759 that it marks a unit as needed by a spec only if the corresponding
4760 instantiation appears in that spec (and not in the corresponding body).
4761 * sem_elim.adb (Check_Eliminated): If we are within a subunit, the name
4762 in the pragma Eliminate has been parsed as a child unit, but the
4763 current compilation unit is in fact the parent in which the subunit is
4766 2010-06-17 Vincent Celier <celier@adacore.com>
4768 * gnat_rm.texi: Fix typo
4770 2010-06-17 Robert Dewar <dewar@adacore.com>
4772 * sem_util.adb: Minor reformatting
4774 2010-06-17 Ed Schonberg <schonberg@adacore.com>
4776 * sem.adb (Do_Withed_Unit): if the unit in the with_clause is a generic
4777 instance, the clause now denotes the instance body. Traverse the
4778 corresponding spec because there may be no other dependence that will
4779 force the traversal of its own context.
4781 2010-06-17 Ed Schonberg <schonberg@adacore.com>
4783 * sem_ch10.adb (Is_Ancestor_Unit): Subsidiary to
4784 Install_Limited_Context_Clauses, to determine whether a limited_with in
4785 some parent of the current unit designates some other parent, in which
4786 case the limited_with clause must not be installed.
4787 (In_Context): Refine test.
4789 2010-06-17 Gary Dismukes <dismukes@adacore.com>
4791 * sem_util.adb (Collect_Primitive_Operations): In the of an untagged
4792 type with a dispatching equality operator that is overridden (for a
4793 tagged full type), don't include the overridden equality in the list of
4794 primitives. The overridden equality is detected by testing for an
4795 Aliased field that references the overriding equality.
4797 2010-06-17 Robert Dewar <dewar@adacore.com>
4799 * freeze.adb: Minor reformatting.
4801 2010-06-17 Joel Brobecker <brobecker@adacore.com brobecker>
4803 * gnat_ugn.texi: Add a section introducing gdbserver.
4805 2010-06-17 Thomas Quinot <quinot@adacore.com>
4807 * sem_res.adb, sem_ch4.adb, s-stoele.adb, par-labl.adb: Minor
4810 2010-06-17 Ed Schonberg <schonberg@adacore.com>
4812 * sem_aggr.adb (Valid_Ancestor_Type): handle properly the case of a
4813 constrained discriminated parent that is a private type.
4814 (Analyze_Record_Aggregate): when collecting inherited discriminants,
4815 handle properly an ancestor type that is a constrained private type.
4817 2010-06-17 Ed Schonberg <schonberg@adacore.com>
4819 * sem_util.adb (Enclosing_Subprogram): If the called subprogram is
4820 protected, use the protected_subprogram_body only if the original
4821 subprogram has not been eliminated.
4823 2010-06-17 Ed Schonberg <schonberg@adacore.com>
4825 * freeze.adb (Freeze_Expression): The designated type of an
4826 access_to_suprogram type can only be frozen if all types in its profile
4829 2010-06-17 Robert Dewar <dewar@adacore.com>
4831 * par.adb: Minor comment fix
4832 * sem_aggr.adb, sem_ch3.adb: Minor reformatting
4834 2010-06-17 Doug Rupp <rupp@adacore.com>
4836 * s-auxdec-vms_64.ads: Revert Integer to Long_Integer change, instead
4837 change Address to Short_Address in functions where both must be the
4838 same size for intrinsics to work.
4840 2010-06-17 Thomas Quinot <quinot@adacore.com>
4842 * sem_ch4.adb (Analyze_Selected_Component): A selected component may
4843 not denote a (private) component of a protected object.
4845 2010-06-17 Bob Duff <duff@adacore.com>
4847 * par-labl.adb (Try_Loop): Test whether the label and the goto are in
4850 2010-06-17 Joel Brobecker <brobecker@adacore.com brobecker>
4852 * gnat_ugn.texi: Update the documentation about GDB re: exception
4855 2010-06-17 Arnaud Charlet <charlet@adacore.com>
4857 * gnatvsn.ads: Bump to 4.6 version.
4859 2010-06-17 Ed Schonberg <schonberg@adacore.com>
4861 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration): The
4862 designated type of the generated pointer is the type of the original
4863 expression, not that of the function call itself, because the return
4864 type may be an untagged derived type and the function may be an
4865 inherited operation.
4867 2010-06-17 Robert Dewar <dewar@adacore.com>
4869 * exp_ch4.adb: Minor reformatting.
4871 2010-06-17 Ed Schonberg <schonberg@adacore.com>
4873 * sinfo.ads, sinfo.adb (Inherited_Discriminant): New flag on
4874 N_Component_Association nodes, to indicate that a component association
4875 of an extension aggregate denotes the value of a discriminant of an
4876 ancestor type that has been constrained by the derivation.
4877 * sem_aggr.adb (Discr_Present): use Inherited_Discriminant to prevent a
4878 double expansion of the aggregate appearing in a context that delays
4879 expansion, to prevent double insertion of discriminant values when the
4880 aggregate is reanalyzed.
4882 2010-06-17 Arnaud Charlet <charlet@adacore.com>
4884 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Do not use
4885 Allocator as the Related_Node of Return_Obj_Access in call to
4886 Make_Temporary below as this would create a sort of infinite
4889 2010-06-17 Ben Brosgol <brosgol@adacore.com>
4891 * gnat_ugn.texi: Update gnatcheck doc.
4893 2010-06-17 Ed Schonberg <schonberg@adacore.com>
4895 * sem_ch3.adb (Build_Incomplete_Type_Declaration): If there is an
4896 incomplete view of the type that is not tagged, and the full type is a
4897 tagged extension, create class_wide type now, and warn that the
4898 incomplete view should be tagged as well.
4900 2010-06-17 Vincent Celier <celier@adacore.com>
4902 * gnatcmd.adb (Non_VMS_Usage): Do not issue usage for gnat sync.
4903 Update the last line of the usage, indicating what commands do not
4904 accept project file switches.
4905 * vms_conv.adb: Do not issue usage line for GNAT SYNC
4906 * vms_data.ads: Fix errors in the qualifiers /LOGFILE and /MAIN of
4908 * gnat_ugn.texi: Document the relaxed rules for library directories in
4909 externally built library projects.
4911 2010-06-17 Doug Rupp <rupp@adacore.com>
4913 * s-auxdec-vms_64.ads: Make boolean and arithmetic operations intrinsic
4915 * s-auxdec-vms-alpha.adb: Remove kludges for aforemention.
4916 * gcc-interface/Makefile.in: Update VMS target pairs.
4918 2010-06-17 Vasiliy Fofanov <fofanov@adacore.com>
4920 * adaint.c: Reorganized in order to avoid use of GetProcessId to stay
4921 compatible with Windows NT 4.0 which doesn't provide this function.
4923 2010-06-17 Vincent Celier <celier@adacore.com>
4925 * ali-util.adb (Time_Stamp_Mismatch): In Verbose mode, if there is
4926 different timestamps but the checksum is the same, issue a short
4929 2010-06-17 Arnaud Charlet <charlet@adacore.com>
4931 * s-interr.adb (Finalize): If the Abort_Task signal is set to system,
4932 it means that we cannot reset interrupt handlers since this would
4933 require potentially sending the abort signal to the Server_Task.
4935 2010-06-17 Ed Schonberg <schonberg@adacore.com>
4937 * exp_ch4.adb: expand NOT for VMS types.
4938 * sem_util.adb: Use OpenVMS_On_Target for IS_VMS_Operator.
4940 2010-06-17 Sergey Rybin <rybin@adacore.com>
4942 * vms_data.ads: Add qualifier for '--no-elim-dispatch' gnatelim option.
4943 * gnat_ugn.texi (gnatelim): add description for --no-elim-dispatch
4946 2010-06-17 Ed Schonberg <schonberg@adacore.com>
4948 * exp_ch6.adb (Expand_Call): Do not expand a call to an internal
4949 protected operation if the subprogram has been eliminated.
4951 2010-06-17 Vincent Celier <celier@adacore.com>
4953 * prj-nmsc.adb (Check_Library_Attributes): Allow the different
4954 directories associated with a library to be any directory when the
4955 library project is externally built.
4957 2010-06-17 Vincent Celier <celier@adacore.com>
4959 * make.adb (Check): If switch -m is used, deallocate the memory that
4960 may be allocated when computing the checksum.
4962 2010-06-17 Eric Botcazou <ebotcazou@adacore.com>
4964 * g-socthi-mingw.adb (C_Recvmsg): Add 'use type' clause for C.size_t;
4965 (C_Sendmsg): Likewise.
4967 2010-06-17 Thomas Quinot <quinot@adacore.com>
4969 * sem_res.adb: Update comments.
4971 2010-06-17 Vincent Celier <celier@adacore.com>
4973 * back_end.adb (Scan_Compiler_Arguments): Process last argument
4975 2010-06-17 Robert Dewar <dewar@adacore.com>
4977 * exp_ch3.adb, exp_ch6.adb, exp_smem.adb, exp_util.adb: Use Ekind_In.
4978 * layout.adb, freeze.adb: Use Make_Temporary.
4980 2010-06-17 Jerome Lambourg <lambourg@adacore.com>
4982 * exp_ch11.adb (Expand_N_Raise_Statement): Expand raise statements in
4983 .NET/JVM normally as this is now perfectly supported by the backend.
4985 2010-06-17 Pascal Obry <obry@adacore.com>
4987 * gnat_rm.texi: Fix minor typo, remove duplicate blank lines.
4989 2010-06-17 Vincent Celier <celier@adacore.com>
4991 * make.adb (Collect_Arguments_And_Compile): Create include path file
4992 only when -x is specified.
4994 * opt.ads (Use_Include_Path_File): New Boolean flag, initialized to
4996 * prj-env.adb (Set_Ada_Paths): New Boolean parameters Include_Path and
4997 Objects_Path, defaulted to True. Only create include path file if
4998 Include_Path is True, only create objects path file if Objects_Path is
5000 * prj-env.ads (Set_Ada_Paths): New Boolean parameters Include_Path and
5001 Objects_Path, defaulted to True.
5002 * switch-m.adb (Scan_Make_Switches): Set Use_Include_Path_File to True
5005 2010-06-17 Ed Schonberg <schonberg@adacore.com>
5007 * exp_disp.adb (Build_Interface_Thunk): Use base type of formal to
5008 determine whether it has the controlling type, when the formal is an
5011 2010-06-17 Eric Botcazou <ebotcazou@adacore.com>
5013 * s-crtl.ads (ssize_t): New type.
5014 (read): Fix signature.
5016 * g-socthi.ads: Add 'with System.CRTL' clause. Remove ssize_t and
5017 'use type' directive for C.size_t, add one for System.CRTL.ssize_t.
5018 (C_Recvmsg): Replace ssize_t with System.CRTL.ssize_t.
5019 (C_Sendmsg): Likewise.
5020 * g-socthi.adb (Syscall_Recvmsg): Likewise.
5021 (Syscall_Sendmsg): Likewise.
5022 (C_Recvmsg): Likewise.
5023 (C_Sendmsg): Likewise.
5024 * g-socthi-mingw.ads: Add 'with System.CRTL' clause. Remove ssize_t
5025 and 'use type' directive for C.size_t, add one for System.CRTL.ssize_t.
5026 (C_Recvmsg): Replace ssize_t with System.CRTL.ssize_t.
5027 (C_Sendmsg): Likewise.
5028 * g-socthi-mingw.adb (C_Recvmsg): Likewise.
5029 (C_Sendmsg): Likewise.
5030 * g-socthi-vms.ads: Add 'with System.CRTL' clause. Remove ssize_t and
5031 'use type' directive for C.size_t, add one for System.CRTL.ssize_t.
5032 (C_Recvmsg): Replace ssize_t with System.CRTL.ssize_t.
5033 (C_Sendmsg): Likewise.
5034 * g-socthi-vms.adb (C_Recvmsg): Likewise.
5035 (C_Sendmsg): Likewise.
5036 * g-socthi-vxworks.ads Add 'with System.CRTL' clause. Remove ssize_t
5037 and 'use type' directive for C.size_t, add one for System.CRTL.ssize_t.
5038 (C_Recvmsg): Replace ssize_t with System.CRTL.ssize_t.
5039 (C_Sendmsg): Likewise.
5040 * g-socthi-vxworks.adb (C_Recvmsg): Likewise.
5041 (C_Sendmsg): Likewise.
5042 * g-sercom-linux.adb (Read): Use correct types to call 'read'.
5043 (Write): Likewise to call 'write'.
5044 * s-os_lib.adb (Read): Use correct type to call System.CRTL.read.
5045 (Write): Use correct type to call System.CRTL.write.
5046 * s-tasdeb.adb (Write): Likewise.
5048 2010-06-17 Vincent Celier <celier@adacore.com>
5050 * prj-proc.adb (Copy_Package_Declarations): Change argument name
5051 Naming_Restricted to Restricted. If Restricted is True, do not copy the
5052 value of attribute Linker_Options.
5054 2010-06-17 Eric Botcazou <ebotcazou@adacore.com>
5056 * gcc-interface/trans.c (push_stack, pop_stack): Delete.
5057 (Case_Statement_to_gnu): Adjust.
5058 (Loop_Statement_to_gnu): Likewise.
5059 (Subprogram_Body_to_gnu): Likewise.
5060 (Handled_Sequence_Of_Statements_to_gnu): Likewise.
5061 (Compilation_Unit_to_gnu): Likewise.
5063 2010-06-17 Robert Dewar <dewar@adacore.com>
5065 * exp_fixd.adb, exp_imgv.adb, exp_intr.adb, exp_pakd.adb, exp_prag.adb,
5066 exp_sel.adb, exp_util.adb, sem_ch10.adb, sem_ch12.adb, sem_ch13.adb,
5067 sem_ch3.adb, sem_ch4.adb, sem_ch5.adb, sem_ch8.adb, sem_ch9.adb,
5068 sem_dist.adb, sem_util.adb: Use Make_Temporary
5069 * itypes.ads, tbuild.ads: Minor comment update
5070 * exp_ch9.adb, exp_dist.adb: Minor reformatting
5072 2010-06-17 Thomas Quinot <quinot@adacore.com>
5074 * exp_imgv.adb, exp_ch7.ads: Minor reformatting.
5076 2010-06-17 Robert Dewar <dewar@adacore.com>
5078 * exp_ch9.adb, exp_disp.adb, exp_dist.adb: Use Make_Temporary.
5080 2010-06-17 Thomas Quinot <quinot@adacore.com>
5082 * sprint.adb (pg): Set Dump_Freeze_Null, to be consistent with -gnatdg.
5084 2010-06-17 Robert Dewar <dewar@adacore.com>
5086 * exp_ch6.adb, exp_ch7.adb, exp_ch5.adb: Use Make_Temporary
5087 * tbuild.ads (Make_Temporary): More comment updates
5088 * tbuild.adb: Minor reformatting
5090 2010-06-17 Robert Dewar <dewar@adacore.com>
5092 * checks.adb, exp_aggr.adb, exp_atag.adb, exp_attr.adb, exp_ch11.adb,
5093 exp_ch3.adb, exp_ch4.adb: Minor code reorganization.
5095 * tbuild.ads, tbuild.adb (Make_Temporary): Clean up, use Entity_Id
5097 (Make_Temporary): Add more extensive documentation
5099 2010-06-17 Robert Dewar <dewar@adacore.com>
5101 * sem_intr.adb, sem_prag.adb, sem_res.adb, sem_type.adb, sem_util.adb,
5102 sem_warn.adb, sem_eval.adb: Minor reformatting. Use Ekind_In.
5103 (Set_Slice_Subtype): Explicitly freeze the slice's itype at the point
5104 where the slice's actions are inserted.
5105 (Decompose_Expr): Account for possible rewriting of slice bounds
5106 resulting from side effects suppression caused by the above freezing,
5107 so that folding of bounds is preserved by such rewriting.
5109 2010-06-17 Robert Dewar <dewar@adacore.com>
5111 * einfo.ads, einfo.adb (Get_Record_Representation_Clause): New function.
5112 * freeze.adb (Freeze_Record_Type): Add call to
5113 Check_Record_Representation_Clause.
5114 * sem_ch13.adb (Check_Record_Representation_Clause): New function
5115 (Analyze_Record_Representation_Clause): Split out overlap code into this
5117 (Check_Component_Overlap): Moved inside
5118 Check_Record_Representation_Clause.
5119 * sem_ch13.ads (Check_Record_Representation_Clause): New function.
5121 2010-06-17 Robert Dewar <dewar@adacore.com>
5123 * back_end.adb, sem_res.adb, switch-c.adb, sem_scil.adb: Minor
5125 * sem_attr.adb, sem_cat.adb, sem_disp.adb, sem_elab.adb, sem_elim.adb,
5126 sem_eval.adb: Use Ekind_In
5128 2010-06-17 Ed Schonberg <schonberg@adacore.com>
5130 * sem_ch8.adb: better error message for illegal inherited discriminant
5132 2010-06-17 Vincent Celier <celier@adacore.com>
5134 * bindusg.adb: Remove lines for -A and -C
5135 * gnat_ugn.texi: Remove all documentation and examples of switches -A
5136 and -C for gnatbind and gnatlink.
5137 * gnatlink.adb (Usage): Remove lines for -A and -C
5138 * switch-b.adb (Scan_Binder_Switches): Issue warning when switch -C is
5140 * gcc-interface/Make-lang.in: Update dependencies.
5142 2010-06-17 Vincent Celier <celier@adacore.com>
5144 * back_end.adb (Scan_Compiler_Arguments): Put all arguments in new
5145 local Argument_List variable Args.
5146 * switch-c.adb (Scan_Front_End_Switches): New Argument_List argument
5148 (Switch_Subsequently_Cancelled): New Argument_List argument Args. Look
5149 for subsequent switches in Args.
5150 * switch-c.ads (Scan_Front_End_Switches): New Argument_List argument
5152 * gcc-interface/Make-lang.in: Update dependencies.
5154 2010-06-17 Robert Dewar <dewar@adacore.com>
5156 * einfo.adb: Minor code fix, allow E_Class_Wide_Type for
5157 Equivalent_Type to match documentation.
5159 2010-06-17 Robert Dewar <dewar@adacore.com>
5161 * sem_ch6.adb, sem_ch7.adb: Minor reformatting.
5162 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_ch10.adb, sem_ch12.adb,
5163 sem_ch4.adb, sem_ch8.adb, sem_ch13.adb: Make use of Ekind_In.
5165 2010-06-17 Thomas Quinot <quinot@adacore.com>
5167 * sem_res.adb (Set_Slice_Subtype): Always freeze the slice's itype.
5169 2010-06-17 Thomas Quinot <quinot@adacore.com>
5171 * freeze.adb (Freeze_Expression): Short circuit operators are valid
5172 freeze node insertion points.
5174 2010-06-17 Robert Dewar <dewar@adacore.com>
5176 * switch-c.ads, switch-c.adb, sem_ch13.adb: Minor reformatting.
5177 * sem_ch12.adb: Add pragmas Assert and Check to previous change.
5179 2010-06-17 Gary Dismukes <dismukes@adacore.com>
5181 * layout.adb (Layout_Type): Broaden test for setting an array type's
5182 Component_Size to include all scalar types, not just discrete types
5183 (components of real types were missed).
5184 * sem_ch3.adb (Constrain_Index): Add missing setting of First_Literal
5185 on the itype created for an index (consistent with Make_Index and
5186 avoids possible Assert_Failures).
5188 2010-06-17 Robert Dewar <dewar@adacore.com>
5190 * atree.ads, atree.adb: Add 6-parameter version of Ekind_In
5191 * einfo.adb: Minor code reformatting (use Ekind_In)
5193 2010-06-17 Robert Dewar <dewar@adacore.com>
5195 * sem_warn.adb (Test_Ref): Abandon scan if access subprogram parameter
5198 2010-06-17 Vincent Celier <celier@adacore.com>
5200 * back_end.adb: Minor comment updates
5201 * switch-c.adb: Remove dependencies on gcc C sources
5202 * gcc-interface/Make-lang.in: Add a-comlin.o to the object file list
5205 2010-06-17 Ed Schonberg <schonberg@adacore.com>
5207 * sem_ch12.adb: propagate Pragma_Enabled flag to generic.
5208 * get_scos.adb: Set C2 flag in decision entry of pragma to 'e' (enabled)
5209 * par_sco.ads, par_sco.adb (Set_SCO_Pragma_Enabled): New procedure
5210 Remove use of Node field in SCOs table
5211 (Output_Header): Set 'd' to initially disable pragma entry
5212 * put_scos.adb (Put_SCOs): New flag indicating if pragma is enabled
5213 * scos.ads, scos.adb: Remove Node field from internal SCOs table.
5214 Use C2 field of pragma decision header to indicate enabled.
5215 * sem_prag.adb: Add calls to Set_SCO_Pragma_Enabled.
5216 * gcc-interface/Make-lang.in: Update dependencies.
5218 2010-06-17 Vincent Celier <celier@adacore.com>
5220 * back_end.adb (Next_Arg): Moved to procedure Scan_Compiler_Arguments
5221 (Scan_Compiler_Arguments): Call Scan_Front_End_Switches with Next_Arg
5222 (Switch_Subsequently_Cancelled): Function moved to the body of Switch.C
5223 * back_end.ads (Scan_Front_End_Switches): Function moved to the body of
5225 * switch-c.adb: Copied a number of global declarations from back_end.adb
5226 (Len_Arg): New function copied from back_end.adb
5227 (Switch_Subsequently_Cancelled): New function moved from back_end.adb
5228 (Scan_Front_End_Switches): New parameter Arg_Rank used to call
5229 Switch_Subsequently_Cancelled.
5230 * switch-c.ads (Scan_Front_End_Switches): New parameter Arg_Rank.
5231 * gcc-interface/Makefile.in: Add line so that shared libgnat is linked
5232 with -lexc on Tru64.
5234 2010-06-17 Robert Dewar <dewar@adacore.com>
5236 * prj.ads, prj.adb: Minor reformatting
5238 2010-06-17 Thomas Quinot <quinot@adacore.com>
5240 * put_scos.adb: Do not generate a blank line in SCOs when omitting the
5241 CP line for a disabled pragma.
5243 2010-06-17 Emmanuel Briot <briot@adacore.com>
5245 * prj-proc.adb, prj.adb, prj.ads (Check_Or_Set_Typed_Variable): New
5247 (Process_Declarative_Item): An invalid value in an typed variable
5248 declaration is no longer always fatal.
5250 2010-06-16 Arnaud Charlet <charlet@adacore.com>
5252 * get_scos.adb, par_sco.adb, par_sco.ads, put_scos.adb, scos.adb,
5253 scos.ads, exp_ch4.adb, sem_warn.adb: Code clean up, update
5256 2010-06-16 Javier Miranda <miranda@adacore.com>
5258 * exp_disp.adb (Expand_Dispatching_Call): Adjust the decoration of the
5259 node referenced by the SCIL node of dispatching "=" to skip the tags
5262 2010-06-16 Ed Schonberg <schonberg@adacore.com>
5264 * sem_ch5.adb (Analyze_Exit_Statement): Return if no enclosing loop,
5265 to prevent cascaded errors and compilation aborts.
5267 2010-06-16 Robert Dewar <dewar@adacore.com>
5269 * back_end.adb (Switch_Subsequently_Cancelled): New function
5270 Move declarations to package body level to support this change
5271 * back_end.ads (Switch_Subsequently_Cancelled): New function
5272 * gnat_ugn.texi: Document -gnat-p switch
5273 * switch-c.adb (Scan_Front_End_Switches): Implement -gnat-p switch
5274 * ug_words: Add entry for -gnat-p (UNSUPPRESS_ALL)
5275 * usage.adb: Add line for -gnat-p switch
5276 * vms_data.ads: Add entry for UNSUPPRESS_ALL (-gnat-p)
5278 2010-06-16 Robert Dewar <dewar@adacore.com>
5280 * sem_warn.adb (Check_Infinite_Loop_Warning): Declaration counts as
5283 2010-06-16 Robert Dewar <dewar@adacore.com>
5285 * exp_disp.adb: Minor reformatting
5287 2010-06-16 Ed Schonberg <schonberg@adacore.com>
5289 * sem_ch3.adb (Complete_Private_Subtype): Inherit class_wide type from
5290 base type only if it was not previously created for the partial view.
5292 2010-06-16 Thomas Quinot <quinot@adacore.com>
5294 * tbuild.ads: Minor comment fix
5296 2010-06-15 Nathan Froyd <froydnj@codesourcery.com>
5298 * gcc-interface/trans.c (gnu_stack_free_list): Delete.
5299 (gnu_except_ptr_stack): Change type to VEC. Update comment.
5300 (gnu_elab_proc_stack): Likewise.
5301 (gnu_return_label_stack): Likewise.
5302 (gnu_loop_label_stack): Likewise.
5303 (gnu_switch_label_stack): Likewise.
5304 (gnu_constraint_label_stack): Likewise.
5305 (gnu_storage_error_label_stack): Likewise.
5306 (gnu_program_error_label_stack): Likewise.
5307 (push_exception_label_stack): Take a VEC ** instead of a tree *.
5308 (push_stack): Likewise. Remove unused second parameter. Update
5310 (pop_stack): Take a VEC * instead of a tree *. Update callers.
5311 (gigi): Initialize stacks as VECs.
5312 (Identifier_to_gnu): Use VEC_last instead of TREE_VALUE.
5313 (Case_Statement_to_gnu): Likewise.
5314 (Subprogram_Body_to_gnu): Likewise.
5315 (call_to_gnu): Likewise.
5316 (Exception_Handler_to_gnu_sjlj): Likewise.
5317 (gnat_to_gnu): Likewise.
5318 (get_exception_label): Likewise.
5320 2010-06-14 Ed Schonberg <schonberg@adacore.com>
5322 * sem_ch3.adb (Build_Derived_Record_Type): if derived type is an
5323 anonymous base generated when the parent is a constrained discriminated
5324 type, propagate interface list to first subtype because it may appear
5325 in a current instance within the extension part of the derived type
5326 declaration, and its own subtype declaration has not been elaborated
5328 * exp_disp.adb (Build_Interface_Thunk): Use base type of formal to
5329 determine whether it has the controlling type.
5331 2010-06-14 Jerome Lambourg <lambourg@adacore.com>
5333 * exp_ch11.adb (Expand_N_Raise_Statement): Make sure that the explicit
5334 raise of CE, SE and PE have the reason correctly set and are properly
5335 expanded before stopping the expansions of .NET/JVM exceptions.
5337 2010-06-14 Robert Dewar <dewar@adacore.com>
5339 * opt.ads (Check_Policy_List): Add some clarifying comments
5340 * sem_prag.adb (Analyze_Pragma, case Check): Set Pragma_Enabled flag
5341 on rewritten Assert pragma.
5343 2010-06-14 Gary Dismukes <dismukes@adacore.com>
5345 * sem_ch6.adb (Check_Overriding_Indicator): Add a special check for
5346 controlled operations, so that they will be treated as overriding even
5347 if the overridden subprogram is marked Is_Hidden, as long as the
5348 overridden subprogram's parent subprogram is not hidden.
5350 2010-06-14 Robert Dewar <dewar@adacore.com>
5352 * debug.adb: Entry for gnatw.d no longer specific for while loops
5353 * einfo.adb (First_Exit_Statement): New attribute for E_Loop
5354 * einfo.ads (First_Exit_Statement): New attribute for E_Loop
5355 * sem_ch5.adb (Analyze_Loop_Statement): Check_Infinite_Loop_Warning has
5356 new calling sequence to include test for EXIT WHEN.
5357 (Analyze_Exit_Statement): Chain EXIT statement into exit statement chain
5358 * sem_warn.ads, sem_warn.adb (Check_Infinite_Loop_Warning): Now handles
5360 * sinfo.adb (Next_Exit_Statement): New attribute of N_Exit_Statement
5362 * sinfo.ads (N_Pragma): Correct comment on Sloc field (points to
5363 PRAGMA, not to pragma identifier).
5364 (Next_Exit_Statement): New attribute of N_Exit_Statement node
5366 2010-06-14 Robert Dewar <dewar@adacore.com>
5368 * sem_res.adb (Resolve_Short_Circuit): Fix sloc of "assertion/check
5371 2010-06-14 Robert Dewar <dewar@adacore.com>
5373 * par-ch2.adb (Scan_Pragma_Argument_Association): Clarify message for
5374 missing pragma argument identifier.
5376 2010-06-14 Robert Dewar <dewar@adacore.com>
5378 * atree.ads, atree.adb (Ekind_In): New functions.
5380 2010-06-14 Robert Dewar <dewar@adacore.com>
5382 * exp_ch4.adb (Expand_N_Op_Expon): Optimize 2**N in stand alone context
5384 2010-06-14 Robert Dewar <dewar@adacore.com>
5386 * usage.adb (Usage): Redo documentation of -gnatwa.
5388 2010-06-14 Ed Schonberg <schonberg@adacore.com>
5390 * sem_ch8.adb (Find_Type): The attribute 'class cannot be applied to
5391 an untagged incomplete type that is a limited view.
5393 2010-06-14 Sergey Rybin <rybin@adacore.com>
5395 * gnat_ugn.texi: Add description of '-cargs gcc_switches' to gnatstub
5398 2010-06-14 Thomas Quinot <quinot@adacore.com>
5400 * exp_ch4.adb (Expand_Short_Circuit_Operator): New subprogram,
5401 factoring duplicated code between...
5402 (Expand_N_And_Than, Expand_N_Or_Else): Remove duplicated code.
5403 * a-envvar.ads: Minor reformatting
5405 2010-06-14 Arnaud Charlet <charlet@adacore.com>
5407 * ali.adb, ali.ads, lib-xref.ads: Document new '+' letter for C/C++
5409 (Scan_ALI): Take into account new Visibility field.
5410 (Visibility_Kind): New type.
5411 (Xref_Entity_Record): Replace Lib field by Visibility.
5413 * gcc-interface/Make-lang.in: Update dependencies.
5415 2010-06-14 Pascal Obry <obry@adacore.com>
5417 * raise.h: Remove unused defintions.
5419 2010-06-14 Bob Duff <duff@adacore.com>
5421 * par-ch10.adb (P_Subunit): If the next token after "separate(X)" is
5422 Tok_Not or Tok_Overriding, call P_Subprogram. We had previously given
5423 the incorrect error "proper body expected".
5424 * par-ch6.adb (P_Subprogram): Suppress "overriding indicator not
5425 allowed here" error in case of subunits, which was triggered by the
5426 above change to P_Subunit.
5428 2010-06-14 Sergey Rybin <rybin@adacore.com>
5430 * gnat_ugn.texi, vms_data.ads: Update gnatelim doc.
5432 2010-06-14 Thomas Quinot <quinot@adacore.com>
5434 * lib-util.adb: Minor code reorganization.
5436 2010-06-14 Robert Dewar <dewar@adacore.com>
5438 * ali.adb (Scan_ALI): Implement reading and storing of N lines
5439 (Known_ALI_Lines): Add entry for 'N' (notes)
5440 * ali.ads (Notes): New table to store Notes information
5441 * alloc.ads: Add entries for Notes table
5442 * lib-util.adb (Write_Info_Int): New procedure
5443 (Write_Info_Slit): New procedure
5444 (Write_Info_Uint): New procedure
5445 * lib-util.ads (Write_Info_Int): New procedure
5446 (Write_Info_Slit): New procedure
5447 (Write_Info_Uint): New procedure
5448 * lib-writ.adb (Write_Unit_Information): Output N (notes) lines
5449 * lib-writ.ads: Update documentation for N (Notes) lines
5450 * lib.adb (Store_Note): New procedure
5451 * lib.ads (Notes): New table
5452 (Store_Note): New procedure
5453 * sem_prag.adb: Call Store_Note for affected pragmas
5455 2010-06-14 Thomas Quinot <quinot@adacore.com>
5457 * socket.c: Fix wrong condition in #ifdef
5458 * g-socket.adb, g-sothco.ads: Functions imported from socket.c that
5459 take or return char* values can't use Interfaces.C.Strings.chars_ptr,
5460 because on VMS this type is a 32-bit pointer which is not compatible
5461 with the default for C pointers for code compiled with gcc on that
5464 2010-06-14 Ed Schonberg <schonberg@adacore.com>
5466 * sem_util (Is_VMS_Operator): New predicate to determine whether an
5467 operator is an intrinsic operator declared in the DEC system extension.
5468 * sem_res.adb (Resolve_Logical_Op): operation is legal on signed types
5469 if the operator is a VMS intrinsic.
5470 * sem_eval.adb (Eval_Logical_Op): Operation is legal and be
5471 constant-folded if the operands are signed and the operator is a VMS
5474 2010-06-14 Robert Dewar <dewar@adacore.com>
5476 * g-socket.adb, gnatcmd.adb: Minor reformatting.
5478 2010-06-14 Pascal Obry <obry@adacore.com>
5480 * s-finimp.adb: Fix typo.
5481 * raise.h: Remove duplicate blank line.
5483 2010-06-14 Vincent Celier <celier@adacore.com>
5485 * prj-nmsc.adb (Add_Sources): Always set the object file and the
5486 switches file names, as the configuration of the language may change
5487 in an extending project.
5488 (Process_Naming_Scheme): For sources of projects that are extended, set
5489 the configuration of the language from the highest extending project
5490 where the language is declared.
5492 2010-06-14 Gary Dismukes <dismukes@adacore.com>
5494 * sem_res.adb (Resolve_Call): For infinite recursion check, test
5495 whether the called subprogram is inherited from a containing subprogram.
5496 (Same_Or_Aliased_Subprograms): New function
5498 2010-06-14 Ed Schonberg <schonberg@adacore.com>
5500 * sem_ch8.adb (End_Use_Type): Before indicating that an operator is not
5501 use-visible, check whether it is a primitive for more than one type.
5503 2010-06-14 Robert Dewar <dewar@adacore.com>
5505 * sem_ch3.adb (Copy_And_Swap): Copy Has_Pragma_Unmodified flag.
5507 * sem_ch7.adb (Preserve_Full_Attributes): Preserve
5508 Has_Pragma_Unmodified flag.
5510 2010-06-14 Thomas Quinot <quinot@adacore.com>
5512 * g-sttsne-locking.adb, g-sttsne-locking.ads, g-sttsne.ads,
5513 g-sttsne-vxworks.adb, g-sttsne-dummy.ads: Removed. Mutual exclusion is
5514 now done in GNAT.Sockets if necessary.
5515 * gsocket.h, g-socket.adb, g-sothco.ads (GNAT.Sockets.Get_XXX_By_YYY):
5516 Ensure mutual exclusion for netdb operations if the target platform
5518 (GNAT.Sockets.Thin_Common): New binding for getXXXbyYYY, treating struct
5519 hostent as an opaque type to improve portability.
5520 * s-oscons-tmplt.c, socket.c: For the case of Vxworks, emulate
5521 gethostbyYYY using proprietary VxWorks API so that a uniform interface
5522 is available for the Ada side.
5523 * gcc-interface/Makefile.in: Remove g-sttsne-*
5524 * gcc-interface/Make-lang.in: Update dependencies.
5526 2010-06-14 Vincent Celier <celier@adacore.com>
5528 * gnatcmd.adb (Mapping_File): New function.
5530 2010-06-14 Javier Miranda <miranda@adacore.com>
5532 * sem_ch3.adb (Derive_Subprograms): Remove over-restrictive assertion.
5534 2010-06-14 Arnaud Charlet <charlet@adacore.com>
5536 * ali.adb: Fix typo.
5537 * s-auxdec-vms-alpha.adb, scng.ads: Minor reformatting.
5539 2010-06-14 Ed Schonberg <schonberg@adacore.com>
5541 * sem_ch12.adb: Make Mark_Context transitive, and apply to subprogram
5544 * sem_ch8.adb (Find_Expanded_Name): If a candidate compilation unit in
5545 the context does not have a homonym of the selector, emit default
5548 2010-06-14 Robert Dewar <dewar@adacore.com>
5550 * sem.adb, sem_ch12.adb, sem_util.adb: Minor reformatting and
5553 2010-06-14 Arnaud Charlet <charlet@adacore.com>
5555 * lib-xref.ads: Doc updates:
5556 - Allocate 'Q' for #include entity kind
5558 - Allocate 'g' for regular macros
5559 - Allocate 'G' for function-like macros
5561 2010-06-14 Ed Schonberg <schonberg@adacore.com>
5563 * sinfo.ads, sinfo.adb (Withed_Body): New attribute of a with_clause.
5564 Indicates that there is an instantiation in the current unit that
5565 loaded the body of the unit denoted by the with_clause.
5566 * sem_ch12.adb (Mark_Context): When instanting a generic body, check
5567 whether a with_clause in the current context denotes the unit that
5568 holds the generic declaration, and mark the with_clause accordingly.
5569 (Instantiate_Package_Body): call Mark_Context.
5570 * sem.adb (Process_Bodies_In_Context): Use Withed_Body to determine
5571 whether a given body should be traversed before the spec of the main
5574 2010-06-14 Ed Falis <falis@adacore.com>
5576 * sysdep.c: Fix 653 build against vThreads headers.
5578 2010-06-14 Robert Dewar <dewar@adacore.com>
5580 * sinfo.ads: Minor reformatting.
5582 2010-06-14 Ed Schonberg <schonberg@adacore.com>
5584 * sem_ch6.adb (Analyze_Subprogram_Body): Do not check conformance when
5585 the spec has been generated for a body without spec that carries an
5586 Inline_Always pragma.
5588 2010-06-14 Arnaud Charlet <charlet@adacore.com>
5590 * lib-xref.ads: Documentation change: allocate 'Z' letter to C/C++
5593 2010-06-14 Jerome Lambourg <lambourg@adacore.com>
5595 * exp_dbug.adb (Debug_Renaming_Declaration): Do not output any debug
5596 declaration for VMs, as those are useless and might lead to duplicated
5597 local variable names in the generated code.
5598 * gcc-interface/Make-lang.in: Update dependencies.
5600 2010-06-14 Robert Dewar <dewar@adacore.com>
5602 * opt.ads, sem.adb, sem_elab.adb: Minor reformatting
5604 2010-06-14 Robert Dewar <dewar@adacore.com>
5606 * exp_aggr.adb (Has_Address_Clause): Moved to Exp_Util, and there it
5607 is renamed as Has_Following_Address_Clause.
5608 * exp_ch3.adb (Needs_Simple_Initialization): Add Consider_IS argument
5609 to allow the caller to avoid Initialize_Scalars having an effect.
5610 (Expand_N_Object_Declaration): Do not do Initialize_Scalars stuff for
5611 scalars with an address clause specified.
5612 * exp_ch3.ads (Needs_Simple_Initialization): Add Consider_IS argument
5613 to allow the caller to avoid Initialize_Scalars having an effect.
5614 * exp_util.adb (Has_Following_Address_Clause): Moved here from Exp_Aggr
5615 (where it was called Has_Address_Clause).
5616 * exp_util.ads (Has_Following_Address_Clause): Moved here from Exp_Aggr
5617 (where it was called Has_Address_Clause).
5618 * freeze.adb (Warn_Overlay): Suppress message about overlaying causing
5619 problems for Initialize_Scalars (since we no longer initialize objects
5620 with an address clause.
5622 2010-06-14 Robert Dewar <dewar@adacore.com>
5624 * exp_prag.adb (Expand_Pragma_Check): Set Loc of generated code from
5627 2010-06-14 Gary Dismukes <dismukes@adacore.com>
5629 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Set Debug_Info_Needed
5630 on the entity of an implicitly generated postcondition procedure.
5632 2010-06-14 Thomas Quinot <quinot@adacore.com>
5634 * sem_ch7.adb (Preserve_Full_Attributes): Propagate
5635 Discriminant_Constraint elist from full view to private view.
5637 2010-06-14 Robert Dewar <dewar@adacore.com>
5639 * sem_res.adb: Minor reformatting.
5641 2010-06-14 Ed Schonberg <schonberg@adacore.com>
5643 * sem.adb: New version of unit traversal.
5645 * sem_elab.adb (Check_Internal_Call): Do not place a call appearing
5646 within a generic unit in the table of delayed calls.
5648 2010-06-14 Robert Dewar <dewar@adacore.com>
5650 * gnatcmd.adb, sem_util.adb, exp_ch3.adb: Minor reformatting
5652 2010-06-14 Ed Schonberg <schonberg@adacore.com>
5654 * sem_ch12.adb (Save_References): If an identifier has been rewritten
5655 during analysis as an explicit dereference, keep the reference implicit
5656 in the generic, but preserve the entity if global. This prevents
5657 malformed generic trees in the presence of some nested generics.
5659 2010-06-14 Sergey Rybin <rybin@adacore.com>
5661 * gnat_ugn.texi: For the GNAT driver, clarify the effect of calling the
5662 tool with '-files=' option. Also fix some small errors (wrong brackets)
5664 2010-06-14 Vincent Celier <celier@adacore.com>
5666 * gnatbind.adb: Call Scan_ALI with Directly_Scanned set to True for all
5667 the ALI files on the command line.
5669 * ali.adb (Scan_ALI): Set component Directly_Scanned of the unit(s) to
5670 the same value as the parameter of the same name.
5671 * ali.ads (Scan_ALI): New Boolean parameter Directly_Scanned, defaulted
5673 * bindgen.adb (Gen_Versions_Ada): Never emit version symbols for
5674 Stand-Alone Library interfaces. When binding Stand-Alone Libraries,
5675 emit version symbols only for the units of the library.
5676 (Gen_Versions_C): Ditto.
5678 2010-06-14 Gary Dismukes <dismukes@adacore.com>
5680 * sem_ch4.adb: Fix typo.
5682 2010-06-14 Vasiliy Fofanov <fofanov@adacore.com>
5684 * s-oscons-tmplt.c (IOV_MAX): redefine on Tru64 and VMS since the
5685 vector IO doesn't work at default value properly.
5687 2010-06-14 Doug Rupp <rupp@adacore.com>
5689 * s-stoele.adb: Remove unnecessary qualification of To_Address for VMS.
5691 2010-06-14 Vincent Celier <celier@adacore.com>
5693 * gnatcmd.adb (Check_Files): Do not invoke the tool with all the
5694 sources of the project if a switch -files= is used.
5696 2010-06-14 Thomas Quinot <quinot@adacore.com>
5698 * exp_attr.adb: Minor reformatting.
5700 2010-06-14 Gary Dismukes <dismukes@adacore.com>
5702 * gnat_ugn.texi: Minor typo fixes and wording changes.
5704 2010-06-14 Ed Schonberg <schonberg@adacore.com>
5706 * sem_ch4.adb (Analyze_One_Call): If the call has been rewritten from a
5707 prefixed form, do not re-analyze first actual, which may need an
5708 implicit dereference.
5709 * sem_ch6.adb (Analyze_Procedure_Call): If the call is given in
5710 prefixed notation, the analysis will rewrite the node, and possible
5711 errors appear in the rewritten name of the node.
5712 * sem_res.adb: If a call is ambiguous because its first parameter is
5713 an overloaded call, report list of candidates, to clarify ambiguity of
5716 2010-06-14 Doug Rupp <rupp@adacore.com>
5718 * s-auxdec-vms-alpha.adb: New package body implementing legacy
5719 VAX instructions with Asm insertions.
5720 * s-auxdec-vms_64.ads: Inline VAX queue functions
5721 * s-stoele.adb: Resolve some ambiguities in To_Addresss with s-suxdec
5722 that show up only on VMS.
5723 * gcc-interface/Makefile.in: Provide translation for
5724 s-auxdec-vms-alpha.adb.
5726 2010-06-14 Olivier Hainque <hainque@adacore.com>
5728 * initialize.c (VxWorks section): Update comments.
5730 2010-06-14 Robert Dewar <dewar@adacore.com>
5732 * a-convec.adb, sem_prag.adb, checks.adb: Minor reformatting.
5734 2010-06-14 Eric Botcazou <ebotcazou@adacore.com>
5736 * init.c: Code clean up.
5738 2010-06-14 Ed Schonberg <schonberg@adacore.com>
5740 * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case Address): Do
5741 not insert address clause in table for later validation if type of
5742 entity is generic, to prevent possible spurious errors.
5744 * sem_ch8.adb: Code clean up.
5746 2010-06-14 Ben Brosgol <brosgol@adacore.com>
5748 * gnat_ugn.texi: Expanded @ovar macro inline to solve problem with
5749 texi2pdf and texi2html.
5750 Document how to change scheduling properties on HP-UX.
5752 2010-06-14 Thomas Quinot <quinot@adacore.com>
5754 * g-socket.ads: Remove misleading comments.
5756 2010-06-14 Jerome Lambourg <lambourg@adacore.com>
5758 * sem_prag.adb (Check_Duplicated_Export_Name): Remove check for
5759 CLI_Target as this prevents proper detection of exported names
5760 duplicates when the exported language is different to CIL.
5761 (Process_Interface_Name): Add check for CIL convention exports,
5762 replacing the old one from Check_Duplicated_Export_Name.
5764 2010-06-14 Matthew Heaney <heaney@adacore.com>
5766 * a-coinve.adb, a-convec.adb (operator "&"): Check both that new length
5767 and new last satisfy constraints.
5768 (Delete_Last): prevent overflow for subtraction of index values
5769 (To_Vector): prevent overflow for addition of index values
5771 2010-06-14 Ed Schonberg <schonberg@adacore.com>
5773 * sem_ch4.adb (Complete_Object_Operation): After analyzing the
5774 rewritten call, preserve the resulting type to prevent spurious errors,
5775 when the call is implicitly dereferenced in the context of an in-out
5778 * checks.adb (Apply_Discriminant_Check): If the target of the
5779 assignment is a renaming of a heap object, create constrained type for
5782 2010-06-14 Pascal Obry <obry@adacore.com>
5784 * prj-proc.adb: Fix copy of object directory for extending projects.
5786 2010-06-14 Jose Ruiz <ruiz@adacore.com>
5788 * init.c (__gnat_alternate_stack): Define this space for PowerPC linux
5789 (__gnat_install_handler, PowerPC linux): Activate the alternative
5792 2010-06-13 Gerald Pfeifer <gerald@pfeifer.com>
5794 * gnat_rm.texi: Move to GFDL version 1.3.
5795 * gnat-style.texi: Ditto.
5796 * gnat_ugn.texi: Ditto.
5798 2010-06-12 Kai Tietz <kai.tietz@onevision.com>
5801 * gcc-interface/Makefile.in: Add rules for multilib x86/x64
5804 2010-06-11 Alexandre Oliva <aoliva@redhat.com>
5806 * gcc-interface/utils.c (update_pointer_to): Initialize last.
5808 2010-06-09 Eric Botcazou <ebotcazou@adacore.com>
5810 * gcc-interface/ada-tree.h: Fix formatting nits.
5812 2010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
5814 * gcc-interface/utils.c (init_gnat_to_gnu): Use typed GC
5816 (init_dummy_type): Likewise.
5817 (gnat_pushlevel): Likewise.
5819 * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
5820 (Subprogram_Body_to_gnu): Likewise.
5821 (Compilation_Unit_to_gnu): Likewise.
5822 (start_stmt_group): Likewise.
5823 (extract_encoding): Likewise.
5824 (decode_name): Likewise.
5826 * gcc-interface/misc.c (gnat_printable_name): Likewise.
5828 * gcc-interface/decl.c (annotate_value): Likewise.
5830 * gcc-interface/ada-tree.h (struct lang_type): Add variable_size
5832 (struct lang_decl): Likewise.
5833 (SET_TYPE_LANG_SPECIFIC): Use typed GC allocation.
5834 (SET_DECL_LANG_SPECIFIC): Likewise.
5836 2010-06-04 Eric Botcazou <ebotcazou@adacore.com>
5838 * gnatlink.adb (gnatlink): Remove support for -fsjlj switch.
5839 * gcc-interface/lang-specs.h: Likewise.
5841 2010-06-03 H.J. Lu <hongjiu.lu@intel.com>
5844 * gcc-interface/decl.c (MAX_FIXED_MODE_SIZE): Removed.
5846 2010-06-01 Arnaud Charlet <charlet@adacore.com>
5848 * gnat_ugn.texi: Improve doc on -fdump-ada-spec, mention limitations.
5850 2010-05-30 Eric Botcazou <ebotcazou@adacore.com>
5852 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Task_Type>: Reuse the
5853 TYPE_DECL of the equivalent type instead of building a new one.
5855 2010-05-30 Eric Botcazou <ebotcazou@adacore.com>
5857 * gcc-interface/decl.c (gnat_to_gnu_entity): Adjust warning message.
5858 Fix nits in comments.
5859 * gcc-interface/misc.c (gnat_init_gcc_eh): Likewise.
5860 * gcc-interface/trans.c (gigi): Likewise.
5861 (Attribute_to_gnu): Likewise.
5862 (Case_Statement_to_gnu): Likewise.
5863 (gnat_to_gnu): Adjust warning message.
5864 * gcc-interface/utils.c (create_var_decl_1): Fix nits in comments.
5865 (build_vms_descriptor32): Likewise.
5867 2010-05-27 Steven Bosscher <steven@gcc.gnu.org>
5869 * gcc-interface/decl.c: Pretend to be a backend file by undefining
5870 IN_GCC_FRONTEND (still need rtl.h here).
5872 2010-05-26 Steven Bosscher <steven@gcc.gnu.org>
5874 * gcc-interface/trans.c: Do not include rtl.h, insclude libfuncs.h.
5875 (gigi): Adjust call to set_stack_check_libfunc.
5877 2010-05-26 Steven Bosscher <steven@gcc.gnu.org>
5879 * gcc-interface/utils.c: Do not include rtl.h.
5881 2010-05-25 Steven Bosscher <steven@gcc.gnu.org>
5883 * gcc-interface/utils.c: Do not include function.h, pointer-set.h,
5884 and gimple.h. Explain why rtl.h has to be included.
5885 (handle_vector_size_attribute): Call reconstruct_complex_type directly.
5886 * gcc-interface/targtyps.c: Do not include tm_p.h
5887 * gcc-interface/utils2.c: Do not include flags.h.
5888 * gcc-interface/trans.c: Do not include expr.h. Include rtl.h instead,
5889 and explain why it has to be included.
5890 * gcc-interface/misc.c: Do not include expr.h, libfuncs.h, cgraph.h,
5892 Include function.h and explain why. Explain why except.h is included.
5893 (enumerate_modes): Remove unused function.
5894 * gcc-interface/gigi.h (enumerate_modes): Remove prototype.
5895 * gcc-interface/Make-lang.in: Update dependencies.
5897 2010-05-25 Joseph Myers <joseph@codesourcery.com>
5899 * gcc-interface/misc.c (internal_error_function): Add context
5900 parameter. Use it to access show_column flag and instead of using
5901 global_dc. Call warn_if_plugins.
5902 * gcc-interface/Make-lang.in (ada/misc.o): Update dependencies.
5904 2010-05-19 Eric Botcazou <ebotcazou@adacore.com>
5906 * gcc-interface/misc.c (LANG_HOOKS_DEEP_UNSHARING): Redefine.
5907 * gcc-interface/trans.c (unshare_save_expr): Delete.
5908 (gigi): Do not unshare trees under SAVE_EXPRs here.
5910 2010-05-18 Nathan Froyd <froydnj@codesourcery.com>
5912 * gcc-interface/trans.c (call_to_gnu): Use build_call_vec instead of
5914 * gcc-interface/utils.c (build_function_stub): Likewise.
5916 2010-05-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
5918 * gcc-interface/misc.c (gnat_handle_option): Remove special logic
5919 for Wuninitialized without -O.
5921 2010-05-16 Eric Botcazou <ebotcazou@adacore.com>
5923 * gcc-interface/gigi.h (enum standard_datatypes): Add new value
5924 ADT_exception_data_name_id.
5925 (exception_data_name_id): New define.
5926 * gcc-interface/trans.c (gigi): Initialize it.
5927 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Use the standard
5928 exception type for standard exception definitions. Do not make them
5930 <E_Record_Type>: Equate fields of types associated with an exception
5931 definition to those of the standard exception type.
5933 2010-05-13 Andreas Schwab <schwab@linux-m68k.org>
5935 * tracebak.c (__gnat_backtrace): Mark top_stack with ATTRIBUTE_UNUSED.
5937 2010-05-12 Eric Botcazou <ebotcazou@adacore.com>
5939 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Tidy up
5940 code, improve comments and fix formatting nits.
5942 2010-05-12 Eric Botcazou <ebotcazou@adacore.com>
5944 * gcc-interface/utils.c (update_pointer_to): Return early if the old
5945 pointer already points to the new type. Chain the old pointer and its
5946 variants at the end of new pointer's chain after updating them.
5948 2010-05-10 Eric Botcazou <ebotcazou@adacore.com>
5950 * exp_disp.adb (Make_Tags): Mark the imported view of dispatch tables
5951 built for interfaces.
5952 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Variable>: Use
5953 imported_p instead of Is_Imported when considering constants.
5954 Do not promote alignment of exported objects.
5955 <E_Record_Subtype>: Strip all suffixes for dispatch table entities.
5957 2010-05-08 Eric Botcazou <ebotcazou@adacore.com>
5959 * exp_disp.adb (Make_Tags): Mark the imported view of dispatch tables.
5960 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Variable>: Make imported
5961 constants really constant.
5962 <E_Record_Subtype>: Strip the suffix for dispatch table entities.
5964 2010-05-08 Eric Botcazou <ebotcazou@adacore.com>
5966 * gcc-interface/decl.c (make_aligning_type): Declare the type.
5968 2010-05-08 Eric Botcazou <ebotcazou@adacore.com>
5970 * gcc-interface/decl.c (gnat_to_gnu_entity): Create variables for size
5971 expressions of variant part of record types declared at library level.
5973 2010-05-08 Eric Botcazou <ebotcazou@adacore.com>
5975 * gcc-interface/gigi.h (create_field_decl): Move PACKED parameter.
5976 * gcc-interface/utils.c (create_field_decl): Move PACKED parameter.
5977 (rest_of_record_type_compilation): Adjust call to create_field_decl.
5978 (make_descriptor_field): Likewise and pass correctly typed constants.
5979 (build_unc_object_type): Likewise.
5980 (unchecked_convert): Likewise.
5981 * gcc-interface/decl.c (elaborate_expression_2): New static function.
5982 (gnat_to_gnu_entity): Use it to make alignment factors explicit.
5983 Adjust call to create_field_decl.
5984 (make_aligning_type): Likewise.
5985 (make_packable_type): Likewise.
5986 (maybe_pad_type): Likewise.
5987 (gnat_to_gnu_field): Likewise.
5988 (components_to_record): Likewise.
5989 (create_field_decl_from): Likewise.
5990 (create_variant_part_from): Remove superfluous test.
5991 * gcc-interface/trans.c (gigi): Adjust call to create_field_decl.
5993 2010-05-08 Eric Botcazou <ebotcazou@adacore.com>
5995 * gcc-interface/gigi.h (build_unc_object_type): Add DEBUG_INFO_P param.
5996 (build_unc_object_type_from_ptr): Likewise.
5997 * gcc-interface/utils.c (build_unc_object_type): Add DEBUG_INFO_P param
5998 and pass it to create_type_decl. Declare the type. Simplify.
5999 (build_unc_object_type_from_ptr): Add DEBUG_INFO_P parameter and pass
6000 it to build_unc_object_type.
6001 * gcc-interface/decl.c (gnat_to_gnu_entity): Adjust to above change.
6002 * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
6003 (gnat_to_gnu): Likewise.
6004 * gcc-interface/utils2.c (build_allocator): Likewise.
6006 2010-05-07 Eric Botcazou <ebotcazou@adacore.com>
6009 * gcc-interface/misc.c (gnat_handle_option): Fix long line.
6011 2010-05-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6013 * gcc-interface/Makefile.in: Removed mips-sgi-irix5* support.
6015 2010-05-06 Manuel López-Ibáñez <manu@gcc.gnu.org>
6018 * gcc-interface/misc.c (gnat_handle_option): Add argument kind.
6020 2010-05-02 Giuseppe Scrivano <gscrivano@gnu.org>
6022 * gnathtml.pl: Use 755 as mask for new directories.
6024 2010-04-28 Eric Botcazou <ebotcazou@adacore.com>
6026 * gcc-interface/trans.c (gnat_gimplify_expr) <ADDR_EXPR>: Uniquize
6027 constant constructors before taking their address.
6029 2010-04-25 Eric Botcazou <ebotcazou@adacore.com>
6031 * exp_dbug.ads: Fix outdated description. Mention link between XVS
6033 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Subtype>: Set
6034 XVZ variable as unit size of XVS type.
6035 (maybe_pad_type): Likewise.
6037 2010-04-25 Eric Botcazou <ebotcazou@adacore.com>
6039 * gcc-interface/trans.c (gnat_to_gnu) <N_Assignment_Statement>: Do not
6040 use memmove if the array type is bit-packed.
6042 2010-04-18 Eric Botcazou <ebotcazou@adacore.com>
6044 * gcc-interface/misc.c (gnat_init): Remove second argument in call to
6045 build_common_tree_nodes.
6047 2010-04-18 Ozkan Sezer <sezeroz@gmail.com>
6049 * gsocket.h: Make sure that winsock2.h is included before windows.h.
6051 2010-04-17 Eric Botcazou <ebotcazou@adacore.com>
6053 * gcc-interface/utils2.c (build_unary_op) <ATTR_ADDR_EXPR>: Do not
6056 2010-04-17 Eric Botcazou <ebotcazou@adacore.com>
6058 * uintp.h (UI_Lt): Declare.
6059 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do the size
6060 computation in sizetype.
6061 <E_Array_Subtype>: Use unified handling for all index types. Do not
6062 generate MAX_EXPR-based expressions, only COND_EXPR-based ones. Add
6064 (annotate_value): Change test for negative values.
6065 (validate_size): Apply test for negative values on GNAT nodes.
6066 (set_rm_size): Likewise.
6067 * gcc-interface/misc.c (gnat_init): Set unsigned types for sizetypes.
6068 * gcc-interface/utils.c (rest_of_record_type_compilation): Change test
6069 for negative values.
6070 (max_size) <MINUS_EXPR>: Do not reassociate a COND_EXPR on the LHS.
6071 (builtin_type_for_size): Adjust definition of signed_size_type_node.
6072 * gcc-interface/utils2.c (compare_arrays): Optimize comparison of
6073 lengths against zero.
6075 2010-04-17 Eric Botcazou <ebotcazou@adacore.com>
6077 * back-end.adb (Call_Back_End): Pass Standard_Character to gigi.
6078 * gcc-interface/gigi.h (gigi): Add standard_character parameter.
6079 (CHAR_TYPE_SIZE, SHORT_TYPE_SIZE, INT_TYPE_SIZE, LONG_TYPE_SIZE,
6080 LONG_LONG_TYPE_SIZE, FLOAT_TYPE_SIZE, DOUBLE_TYPE_SIZE,
6081 LONG_DOUBLE_TYPE_SIZE, SIZE_TYPE): Delete.
6082 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Subtype>: Call
6084 * gcc-interface/misc.c (gnat_init): Set signedness of char as per
6085 flag_signed_char. Tag sizetype with "size_type" moniker.
6086 * gcc-interface/trans.c (gigi): Add standard_character parameter.
6087 Remove useless built-in types. Equate unsigned_char_type_node to
6088 Standard.Character. Use it instead of char_type_node throughout.
6089 (Attribute_to_gnu): Likewise.
6090 (gnat_to_gnu): Likewise.
6091 * gcc-interface/utils2.c (build_call_raise): Likewise.
6093 2010-04-17 Eric Botcazou <ebotcazou@adacore.com>
6095 * gcc-interface/gigi.h (enum standard_datatypes): Add new values
6096 ADT_sbitsize_one_node and ADT_sbitsize_unit_node.
6097 (sbitsize_one_node): New macro.
6098 (sbitsize_unit_node): Likewise.
6099 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Subtype>: Fix
6100 latent bug in the computation of subrange_p. Fold wider_p predicate.
6101 (cannot_be_superflat_p): Use an explicitly signed 64-bit type to do
6102 the final comparison.
6103 (make_aligning_type): Build real negation and use sizetype throughout
6104 the offset computation.
6105 (maybe_pad_type): Do not issue the warning when the new size expression
6107 (annotate_value) <INTEGER_CST>: Simplify code handling negative values.
6108 * gcc-interface/misc.c (gnat_init): Initialize sbitsize_one_node and
6110 * gcc-interface/trans.c (Attribute_to_gnu) <Attr_Pool_Address>: Fold
6112 (gnat_to_gnu) <N_Free_Statement>: Likewise.
6113 * gcc-interface/utils.c (convert): Use sbitsize_unit_node.
6114 * gcc-interface/utils2.c (compare_arrays): Compute real lengths and use
6115 constants in sizetype. Remove dead code and tweak comments. Generate
6116 equality instead of inequality comparisons for zero length tests.
6118 2010-04-16 Eric Botcazou <ebotcazou@adacore.com>
6120 * gcc-interface/gigi.h (gnat_init_decl_processing): Delete.
6121 * gcc-interface/decl.c (gnat_to_gnu_entity): Constify a few variables.
6122 <object>: Do not create the fake PARM_DECL if no debug info is needed.
6123 Do not create the corresponding VAR_DECL of a CONST_DECL for debugging
6124 purposes if no debug info is needed.
6125 Fix formatting. Reorder and add comments.
6126 * gcc-interface/trans.c (gnat_to_gnu) <N_Attribute_Reference>: Constify
6127 variable and remove obsolete comment.
6128 * gcc-interface/utils.c (convert_vms_descriptor64): Tweak comment.
6129 (convert_vms_descriptor32): Likewise.
6130 (convert): Remove dead code.
6131 <UNCONSTRAINED_ARRAY_REF>: Pass the field instead of its name to build
6132 the reference to the P_ARRAY pointer.
6133 <POINTER_TYPE>: Likewise.
6134 (maybe_unconstrained_array) <UNCONSTRAINED_ARRAY_TYPE>: Likewise.
6135 (gnat_init_decl_processing): Delete, move contents to...
6136 * gcc-interface/misc.c (gnat_init): ...here.
6138 2010-04-16 Eric Botcazou <ebotcazou@adacore.com>
6140 * gcc-interface/trans.c (unchecked_conversion_nop): Handle function
6141 calls. Return true for conversion from a record subtype to its type.
6143 2010-04-16 Eric Botcazou <ebotcazou@adacore.com>
6145 * gcc-interface/decl.c (gnat_to_gnu_entity): Use boolean_type_node in
6146 lieu of integer_type_node for boolean operations.
6147 (choices_to_gnu): Likewise.
6148 * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
6149 (Loop_Statement_to_gnu): Likewise.
6150 (establish_gnat_vms_condition_handler): Likewise.
6151 (Exception_Handler_to_gnu_sjlj): Likewise.
6152 (gnat_to_gnu): Likewise.
6153 (build_unary_op_trapv): Likewise.
6154 (build_binary_op_trapv): Likewise.
6155 (emit_range_check): Likewise.
6156 (emit_index_check): Likewise.
6157 (convert_with_check): Likewise.
6158 * gcc-interface/utils.c (convert_vms_descriptor64): Likewise.
6159 (convert_vms_descriptor32): Likewise.
6160 (convert_vms_descriptor): Likewise.
6161 * gcc-interface/utils2.c (nonbinary_modular_operation): Likewise.
6162 (compare_arrays): Use boolean instead of integer constants.
6163 (build_binary_op) <TRUTH_ANDIF_EXPR, TRUTH_ORIF_EXPR, TRUTH_AND_EXPR,
6164 TRUTH_OR_EXPR, TRUTH_XOR_EXPR>: New case. Check that the result type
6166 <GE_EXPR, LE_EXPR, GT_EXPR, LT_EXPR>: Remove obsolete assertion.
6167 <EQ_EXPR, NE_EXPR>: Check that the result type is a boolean type.
6168 <PREINC/PREDECREMENT_EXPR, POSTINC/POSTDECREMENT_EXPR>: Delete.
6169 <TRUTH_NOT_EXPR>: Check that the result type is a boolean type.
6170 (build_unary_op): Use boolean_type_node in lieu of integer_type_node
6171 for boolean operations.
6172 (fill_vms_descriptor): Likewise. Fix formatting nits.
6174 2010-04-16 Eric Botcazou <ebotcazou@adacore.com>
6176 * gcc-interface/ada-tree.def (LOOP_STMT): Change to 4-operand nodes.
6177 * gcc-interface/ada-tree.h (LOOP_STMT_TOP_COND, LOOP_STMT_BOT_COND):
6179 (LOOP_STMT_COND): ...this.
6180 (LOOP_STMT_BOTTOM_COND_P): New flag.
6181 (LOOP_STMT_TOP_UPDATE_P): Likewise.
6182 * gcc-interface/trans.c (can_equal_min_or_max_val_p): New function.
6183 (can_equal_min_val_p): New static inline function.
6184 (can_equal_max_val_p): Likewise.
6185 (Loop_Statement_to_gnu): Use build4 in lieu of build5 and adjust to
6186 new LOOP_STMT semantics. Use two different strategies depending on
6187 whether optimization is enabled to translate the loop.
6188 (gnat_gimplify_stmt) <LOOP_STMT>: Adjust to new LOOP_STMT semantics.
6190 2010-04-16 Eric Botcazou <ebotcazou@adacore.com>
6192 * uintp.adb (UI_From_Dint): Remove useless code.
6193 (UI_From_Int): Likewise.
6194 * uintp.h: Reorder declarations.
6195 (UI_From_gnu): Declare.
6196 (UI_Base): Likewise.
6197 (Vector_Template): Likewise.
6198 (Vector_To_Uint): Likewise.
6201 * gcc-interface/gigi.h: Tweak comments.
6202 * gcc-interface/cuintp.c (UI_From_gnu): New global function.
6203 * gcc-interface/decl.c (maybe_pad_type): Do not warn if either size
6205 (annotate_value) <INTEGER_CST>: Call UI_From_gnu.
6206 * gcc-interface/trans.c (post_error_ne_num): Call post_error_ne.
6207 (post_error_ne_tree): Call UI_From_gnu and post_error_ne.
6208 * gcc-interface/utils.c (max_size) <tcc_binary>: Do not special-case
6211 2010-04-16 Eric Botcazou <ebotcazou@adacore.com>
6213 * gcc-interface/decl.c (make_type_from_size) <INTEGER_TYPE>: Just copy
6215 * gcc-interface/trans.c (smaller_packable_type_p): Rename into...
6216 (smaller_form_type_p): ...this. Change parameter and variable names.
6217 (call_to_gnu): Use the nominal type of the parameter to create the
6218 temporary if it's a smaller form of the actual type.
6219 (addressable_p): Return false if the actual type is integral and its
6220 size is greater than that of the expected type.
6222 2010-04-15 Eric Botcazou <ebotcazou@adacore.com>
6224 * gcc-interface/cuintp.c (UI_To_gnu): Fix long line.
6225 * gcc-interface/gigi.h (MARK_VISITED): Skip objects of constant class.
6226 (process_attributes): Delete.
6227 (post_error_ne_num): Change parameter name.
6228 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force debug info
6229 with -g3. Remove a couple of obsolete lines. Minor tweaks.
6230 If type annotating mode, operate on trees to compute the adjustment to
6231 the sizes of tagged types. Fix long line.
6232 (cannot_be_superflat_p): Tweak head comment.
6233 (annotate_value): Fold local constant.
6234 (set_rm_size): Fix long line.
6235 * gcc-interface/trans.c (Identifier_to_gnu): Rework comments.
6236 (Attribute_to_gnu): Fix long line.
6237 <Attr_Size>: Remove useless assertion.
6238 Reorder statements. Use size_binop routine.
6239 (Loop_Statement_to_gnu): Use build5 in lieu of build_nt.
6240 Create local variables for the label and the test. Tweak comments.
6241 (Subprogram_Body_to_gnu): Reset cfun to NULL.
6242 (Compilation_Unit_to_gnu): Use the Sloc of the Unit node.
6243 (process_inlined_subprograms): Integrate into...
6244 (Compilation_Unit_to_gnu): ...this.
6245 (gnat_to_gnu): Fix long line.
6246 (post_error_ne_num): Change parameter name.
6247 * gcc-interface/utils.c (process_attributes): Static-ify.
6248 <ATTR_MACHINE_ATTRIBUTE>: Set input_location before proceeding.
6249 (create_type_decl): Add comment.
6250 (create_var_decl_1): Process the attributes after adding the VAR_DECL
6251 to the current binding level.
6252 (create_subprog_decl): Likewise for the FUNCTION_DECL.
6253 (end_subprog_body): Do not reset cfun to NULL.
6254 (build_vms_descriptor32): Fix long line.
6255 (build_vms_descriptor): Likewise.
6256 (handle_nonnull_attribute): Likewise.
6257 (convert_vms_descriptor64): Likewise.
6258 * gcc-interface/utils2.c (fill_vms_descriptor): Fix long line.
6259 (gnat_protect_expr): Fix thinko.
6261 2010-04-15 Eric Botcazou <ebotcazou@adacore.com>
6263 * gcc-interface/trans.c (gigi): Set DECL_IGNORED_P on EH functions.
6264 (gnat_to_gnu) <N_Op_Eq>: Restore the value of input_location
6265 before translating the top-level node.
6266 (lvalue_required_p) <N_Function_Call>: Return 1 if !constant.
6267 <N_Object_Declaration>: Likewise.
6268 <N_Assignment_Statement>: Likewise.
6269 <N_Unchecked_Type_Conversion>: Likewise.
6270 (call_to_gnu): Remove kludge.
6271 (gnat_to_gnu) <N_Return_Statement>: When not optimizing, force labels
6272 associated with user returns to be preserved.
6273 (gnat_to_gnu): Add special code to deal with boolean rvalues.
6274 * gcc-interface/utils2.c (compare_arrays): Set input_location on all
6276 (build_unary_op) <ADDR_EXPR>: Call build_fold_addr_expr.
6277 <INDIRECT_REF>: Call build_fold_indirect_ref.
6279 2010-04-15 Joel Sherrill <joel.sherrill@oarcorp.com>
6281 * g-socket.adb: A target can have multiple missing errno's. This
6282 will result in multiple errno's being defined as -1. Because of this
6283 we can not use a case but must use a series of if's to avoid
6284 a duplicate case error in GNAT.Sockets.Resolve_Error.
6286 2010-04-15 Eric Botcazou <ebotcazou@adacore.com>
6288 * gcc-interface/trans.c (call_to_gnu): Open a nesting level if this is
6289 a statement. Otherwise, if at top-level, push the processing of the
6290 elaboration routine. In the misaligned case, issue the error messages
6291 again on entry and create the temporary explicitly. Do not issue them
6293 For a function call, emit the range check if necessary.
6294 In the copy-in copy-out case, create the temporary for the return
6296 Do not unnecessarily convert by-ref parameters to the formal's type.
6297 Remove obsolete guards in conditions.
6298 (gnat_to_gnu) <N_Assignment_Statement>: For a function call, pass the
6299 target to call_to_gnu in all cases.
6300 (gnat_gimplify_expr) <ADDR_EXPR>: Remove handling of SAVE_EXPR.
6301 (addressable_p) <CONSTRUCTOR>: Return false if not static.
6302 <COMPOUND_EXPR>: New case.
6303 * gcc-interface/utils2.c (build_unary_op) <ADDR_EXPR>: Fold a compound
6304 expression if it has unconstrained array type.
6305 (gnat_mark_addressable) <COMPOUND_EXPR>: New case.
6306 (gnat_stabilize_reference) <COMPOUND_EXPR>: Stabilize operands on an
6309 2010-04-15 Eric Botcazou <ebotcazou@adacore.com>
6311 * gcc-interface/trans.c (gigi): Do not start statement group.
6312 (Compilation_Unit_to_gnu): Set current_function_decl to NULL.
6313 Start statement group and push binding level here...
6314 (gnat_to_gnu) <N_Compilation_Unit>: ...and not here.
6315 Do not push fake contexts at top level. Remove redundant code.
6316 (call_to_gnu): Rename a local variable and constify another.
6317 * gcc-interface/utils.c (gnat_pushlevel): Fix formatting nits.
6318 (set_current_block_context): Set it as the group's block.
6319 (gnat_init_decl_processing): Delete unrelated init code.
6320 (end_subprog_body): Use NULL_TREE.
6322 2010-04-15 Eric Botcazou <ebotcazou@adacore.com>
6324 * gcc-interface/trans.c (call_to_gnu): Do not unnecessarily force
6325 side-effects of actual parameters before the call.
6327 2010-04-15 Eric Botcazou <ebotcazou@adacore.com>
6329 * gcc-interface/decl.c (validate_size): Reorder, remove obsolete test
6331 (set_rm_size): Reorder and remove obsolete test.
6333 2010-04-14 Eric Botcazou <ebotcazou@adacore.com>
6335 * gcc-interface/gigi.h: Reorder declarations and tweak comments.
6336 (gigi): Adjust ATTRIBUTE_UNUSED markers.
6337 * gcc-interface/gadaint.h: New file.
6338 * gcc-interface/trans.c: Include it in lieu of adaint.h. Reorder.
6339 (__gnat_to_canonical_file_spec): Remove declaration.
6340 (number_names): Delete.
6341 (number_files): Likewise.
6343 * gcc-interface/Make-lang.in (ada/trans.o): Adjust dependencies to
6346 2010-04-14 Eric Botcazou <ebotcazou@adacore.com>
6348 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Class_Wide_Type>: Fix
6350 * gcc-interface/trans.c (process_freeze_entity): Use local copy of
6351 Ekind. Return early for class-wide types. Do not compute initializer
6352 unless necessary. Reuse the tree for an associated class-wide type
6353 only if processing its root type.
6355 2010-04-13 Joel Sherrill <joel.sherrill@oarcorp.com>
6357 * gsocket.h: Run-time can no longer be built without network
6358 OS headers available. Changing RTEMS GNAT build procedure to
6359 reflect this and letting run-time build use network .h files.
6361 2010-04-13 Duncan Sands <baldrick@free.fr>
6363 * gcc-interface/misc.c (gnat_eh_type_covers): Remove.
6364 * gcc-interface/trans.c (Exception_Handler_to_gnu_zcx): Update comment.
6366 2010-04-13 Eric Botcazou <ebotcazou@adacore.com>
6368 * gcc-interface/gigi.h (standard_datatypes): Add ADT_parent_name_id.
6369 (parent_name_id): New macro.
6370 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Type>: Use it.
6371 * gcc-interface/trans.c (gigi): Initialize it.
6372 (lvalue_required_p) <N_Type_Conversion>: New case.
6373 <N_Qualified_Expression>: Likewise.
6374 <N_Allocator>: Likewise.
6375 * gcc-interface/utils.c (convert): Try to properly upcast tagged types.
6377 2010-04-13 Eric Botcazou <ebotcazou@adacore.com>
6379 * gcc-interface/ada-tree.h (TYPE_BY_REFERENCE_P): Delete.
6380 (DECL_CONST_ADDRESS_P): New macro.
6381 (SET_DECL_ORIGINAL_FIELD_TO_FIELD): Likewise.
6382 (SAME_FIELD_P): Likewise.
6383 * gcc-interface/decl.c (constructor_address_p): New static function.
6384 (gnat_to_gnu_entity) <object>: Set DECL_CONST_ADDRESS_P according to
6385 the return value of above function.
6386 (gnat_to_gnu_entity) <E_Record_Type>: Force BLKmode for all types
6387 passed by reference.
6388 <E_Record_Subtype>: Likewise.
6389 Set TREE_ADDRESSABLE on the type if it passed by reference.
6390 (make_packable_type): Use SET_DECL_ORIGINAL_FIELD_TO_FIELD.
6391 (create_field_decl_from): Likewise.
6392 (substitute_in_type): Likewise.
6393 (purpose_member_field): Use SAME_FIELD_P.
6394 * gcc-interface/misc.c (must_pass_by_ref): Test TREE_ADDRESSABLE.
6395 * gcc-interface/trans.c (lvalue_required_p): Add ADDRESS_OF_CONSTANT
6396 parameter and adjust recursive calls.
6397 <N_Explicit_Dereference>: New case.
6398 <N_Object_Declaration>: Return 1 if the object is of a class-wide type.
6399 Adjust calls to lvalue_required_p. Do not return the initializer of a
6400 DECL_CONST_ADDRESS_P constant if an lvalue is required for it.
6401 (call_to_gnu): Delay issuing error message for a misaligned actual and
6402 avoid the associated back-end assertion. Test TREE_ADDRESSABLE.
6403 (gnat_gimplify_expr) <ADDR_EXPR>: Handle non-static constructors.
6404 * gcc-interface/utils.c (make_dummy_type): Set TREE_ADDRESSABLE if the
6405 type is passed by reference.
6406 (convert) <CONSTRUCTOR>: Convert in-place in more cases.
6407 * gcc-interface/utils2.c (build_cond_expr): Drop TYPE_BY_REFERENCE_P.
6408 (build_simple_component_ref): Use SAME_FIELD_P.
6410 2010-04-12 Eric Botcazou <ebotcazou@adacore.com>
6412 * gcc-interface/trans.c (Identifier_to_gnu): Use boolean variable.
6413 (call_to_gnu): Test gigi's flag TYPE_BY_REFERENCE_P instead of calling
6414 front-end's predicate Is_By_Reference_Type. Use consistent order and
6415 remove ??? comment. Use original conversion in all cases, if any.
6416 * gcc-interface/utils.c (make_dummy_type): Minor tweak.
6417 (convert): Use local copy in more cases.
6418 <INDIRECT_REF>: Remove deactivated code.
6419 (unchecked_convert): Use a couple of local copies.
6421 2010-04-11 Eric Botcazou <ebotcazou@adacore.com>
6423 * gcc-interface/trans.c (lvalue_required_for_attribute_p): New static
6425 (lvalue_required_p) <N_Attribute_Reference>: Call it.
6426 (gnat_to_gnu) <N_Selected_Component>: Prevent build_component_ref from
6427 folding the result only if lvalue_required_for_attribute_p is true.
6428 * gcc-interface/utils.c (maybe_unconstrained_array): Pass correctly
6429 typed constant to build_component_ref.
6430 (unchecked_convert): Likewise.
6431 * gcc-interface/utils2.c (maybe_wrap_malloc): Likewise.
6432 (build_allocator): Likewise.
6434 2010-04-11 Eric Botcazou <ebotcazou@adacore.com>
6436 * gcc-interface/utils2.c (build_cond_expr): Take the address and
6437 dereference if the result type is passed by reference.
6439 2010-04-11 Eric Botcazou <ebotcazou@adacore.com>
6441 * gcc-interface/trans.c (Case_Statement_to_gnu): Bool-ify variable.
6442 (gnat_to_gnu) <N_Null_Statement>: When not optimizing, generate a
6443 goto to the next statement.
6445 2010-04-09 Eric Botcazou <ebotcazou@adacore.com>
6447 * gcc-interface/gigi.h (maybe_variable): Delete.
6448 (protect_multiple_eval): Likewise.
6449 (maybe_stabilize_reference): Likewise.
6450 (gnat_save_expr): Declare.
6451 (gnat_protect_expr): Likewise.
6452 (gnat_stabilize_reference): Likewise.
6453 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Use
6454 gnat_stabilize_reference.
6455 (maybe_variable): Delete.
6456 (elaborate_expression_1): Use gnat_save_expr.
6457 * gcc-interface/trans.c (Attribute_to_gnu): Use gnat_protect_expr.
6458 (call_to_gnu): Pass NULL to gnat_stabilize_reference.
6459 (gnat_to_gnu) <N_Object_Declaration>: Use gnat_save_expr.
6460 <N_Slice>: Use gnat_protect_exp.
6461 <N_Selected_Component>: Pass NULL to gnat_stabilize_reference.
6462 <N_In>: Use gnat_protect_expr.
6463 Pass NULL to gnat_stabilize_reference.
6464 (build_unary_op_trapv): Use gnat_protect_expr.
6465 (build_binary_op_trapv): Likewise.
6466 (emit_range_check): Likewise.
6467 (emit_index_check): Likewise.
6468 (convert_with_check): Likewise.
6469 (protect_multiple_eval): Move to utils2.c file.
6470 (maybe_stabilize_reference): Merge into...
6471 (gnat_stabilize_reference): ...this. Move to utils2.c file.
6472 (gnat_stabilize_reference_1): Likewise.
6473 * gcc-interface/utils.c (convert_to_fat_pointer): Use gnat_protect_expr
6474 instead of protect_multiple_eval.
6475 * gcc-interface/utils2.c (compare_arrays): Likewise.
6476 (nonbinary_modular_operation): Likewise.
6477 (maybe_wrap_malloc): Likewise.
6478 (build_allocator): Likewise.
6479 (gnat_save_expr): New function.
6480 (gnat_protect_expr): Rename from protect_multiple_eval. Early return
6481 in common cases. Propagate TREE_READONLY onto dereferences.
6482 (gnat_stabilize_reference_1): Move from trans.c file.
6483 (gnat_stabilize_reference): Likewise.
6485 2010-04-09 Eric Botcazou <ebotcazou@adacore.com>
6487 * gcc-interface/gigi.h (gnat_mark_addressable): Rename parameter.
6488 * gcc-interface/decl.c (maybe_variable): Do not set TREE_STATIC on _REF
6489 node. Use the type of the operand to set TREE_READONLY.
6490 * gcc-interface/trans.c (Identifier_to_gnu): Do not set TREE_STATIC on
6491 _REF node. Do not overwrite TREE_READONLY.
6492 (call_to_gnu): Rename local variable and fix various nits. In the
6493 copy-in/copy-out case, build the SAVE_EXPR manually.
6494 (convert_with_check): Call protect_multiple_eval in lieu of save_expr
6495 and fold the computations.
6496 (protect_multiple_eval): Always save entire fat pointers.
6497 (maybe_stabilize_reference): Minor tweaks.
6498 (gnat_stabilize_reference_1): Likewise. Do not deal with tcc_constant,
6499 tcc_type and tcc_statement.
6500 * gcc-interface/utils.c (convert_to_fat_pointer): Call
6501 protect_multiple_eval in lieu of save_expr.
6502 (convert): Minor tweaks.
6503 (maybe_unconstrained_array): Do not set TREE_STATIC on _REF node.
6504 (builtin_type_for_size): Call gnat_type_for_size directly.
6505 * gcc-interface/utils2.c (contains_save_expr_p): Delete.
6506 (contains_null_expr): Likewise
6507 (gnat_build_constructor): Do not call it.
6508 (compare_arrays): Deal with all side-effects, use protect_multiple_eval
6509 instead of gnat_stabilize_reference to protect the operands.
6510 (nonbinary_modular_operation): Call protect_multiple_eval in lieu of
6512 (maybe_wrap_malloc): Likewise.
6513 (build_allocator): Likewise.
6514 (build_unary_op) <INDIRECT_REF>: Do not set TREE_STATIC on _REF node.
6515 (gnat_mark_addressable): Rename parameter.
6517 2010-04-08 Eric Botcazou <ebotcazou@adacore.com>
6519 * gcc-interface/ada-tree.h (TYPE_RETURNS_UNCONSTRAINED_P): Rename into.
6520 (TYPE_RETURN_UNCONSTRAINED_P): ...this.
6521 (TYPE_RETURNS_BY_REF_P): Rename into.
6522 (TYPE_RETURN_BY_DIRECT_REF_P): ...this.
6523 (TYPE_RETURNS_BY_TARGET_PTR_P): Delete.
6524 * gcc-interface/gigi.h (create_subprog_type): Adjust parameter names.
6525 (build_return_expr): Likewise.
6526 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>:
6527 Rename local variables. If the return Mechanism is By_Reference, pass
6528 return_by_invisible_ref_p to create_subprog_type instead of toggling
6529 TREE_ADDRESSABLE. Test return_by_invisible_ref_p in order to annotate
6530 the mechanism. Use regular return for contrained types with non-static
6531 size and return by invisible reference for unconstrained return types
6532 with default discriminants. Update comment.
6533 * gcc-interface/trans.c (Subprogram_Body_to_gnu): If the function
6534 returns by invisible reference, turn the RESULT_DECL into a pointer.
6535 Do not handle DECL_BY_REF_P in the CICO case here.
6536 (call_to_gnu): Remove code handling return by target pointer. For a
6537 function call, if the return type has non-constant size, generate the
6538 assignment with an INIT_EXPR.
6539 (gnat_to_gnu) <N_Return_Statement>: Remove dead code in the CICO case.
6540 If the function returns by invisible reference, build the copy return
6542 (add_decl_expr): Initialize the variable with an INIT_EXPR.
6543 * gcc-interface/utils.c (create_subprog_type): Adjust parameter names.
6544 Adjust for renaming of macros. Copy the node only when necessary.
6545 (create_subprog_decl): Do not toggle TREE_ADDRESSABLE on the return
6546 type, only change DECL_BY_REFERENCE on the RETURN_DECL.
6547 (convert_from_reference): Delete.
6548 (is_byref_result): Likewise.
6549 (gnat_genericize_r): Likewise.
6550 (gnat_genericize): Likewise.
6551 (end_subprog_body): Do not call gnat_genericize.
6552 * gcc-interface/utils2.c (build_binary_op) <INIT_EXPR>: New case.
6553 (build_return_expr): Adjust parameter names, logic and comment.
6555 2010-04-07 Eric Botcazou <ebotcazou@adacore.com>
6557 * exp_pakd.adb (Create_Packed_Array_Type): Always use a modular type
6558 if the size is small enough. Propagate the alignment if there is an
6559 alignment clause on the original array type.
6560 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Modular_Integer_Subtype>
6561 Deal with under-aligned packed array types. Copy the size onto the
6562 justified modular type and don't lay it out again. Likewise for the
6563 padding type built for other under-aligned subtypes.
6564 * gcc-interface/utils.c (finish_record_type): Do not set a default mode
6567 2010-04-07 Eric Botcazou <ebotcazou@adacore.com>
6569 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set default
6570 alignment on the RETURN type built for the Copy-In Copy-Out mechanism.
6572 2010-04-07 Eric Botcazou <ebotcazou@adacore.com>
6574 * gcc-interface/trans.c (call_to_gnu): In the return-by-target-ptr case
6575 do not set the result type if there is a specified target and do not
6576 convert the result in any cases.
6577 (protect_multiple_eval): Make direct SAVE_EXPR for CALL_EXPR.
6578 (maybe_stabilize_reference) <COMPOUND_EXPR>: Merge with CALL_EXPR.
6580 2010-03-10 Eric Botcazou <ebotcazou@adacore.com>
6582 * gcc-interface/Makefile.in (SPARC/Solaris): Use sparcv8plus.
6584 2010-02-27 Eric Botcazou <ebotcazou@adacore.com>
6587 * gcc-interface/utils2.c (build_binary_op) <EQ_EXPR>: Assert that fat
6588 pointer base types are variant of each other. Apply special treatment
6589 for null to fat pointer types in all cases.
6591 2010-01-28 Pascal Obry <obry@adacore.com>
6593 * s-win32.ads: Add some missing constants.
6595 2010-01-28 Vincent Celier <celier@adacore.com>
6597 * prj-attr-pm.adb (Add_Attribute): Do nothing if To_Package is
6600 2010-01-28 Robert Dewar <dewar@adacore.com>
6602 * gnat_rm.texi: Minor correction
6604 2010-01-27 Pascal Obry <obry@adacore.com>
6606 * g-awk.adb: ensure that an AWK session is reusable.
6608 2010-01-27 Vasiliy Fofanov <fofanov@adacore.com>
6610 * g-regist.adb (For_Every_Key): Fix previous change.
6613 2010-01-27 Thomas Quinot <quinot@adacore.com>
6615 * lib-writ.ads: Current version of spec for new N (note) ALI lines
6617 2010-01-27 Yannick Moy <moy@adacore.com>
6619 * a-cdlili.adb (Insert): Correct exception message when cursor
6620 designates wrong list.
6622 2010-01-27 Vincent Celier <celier@adacore.com>
6624 * gnatcmd.adb: When there is only one main specified, the package
6625 support Switches (<main>) and attribute Switches is specified for the
6626 main, use these switches, instead of Default_Switches ("Ada").
6628 2010-01-27 Robert Dewar <dewar@adacore.com>
6630 * sem_prag.adb, par-prag.adb, snames.ads-tmpl: pragma Dimension initial
6632 * exp_disp.adb: Minor reformatting
6634 2010-01-27 Tristan Gingold <gingold@adacore.com>
6636 * seh_init.c: Use __ImageBase instead of _ImageBase.
6638 2010-01-27 Javier Miranda <miranda@adacore.com>
6640 * exp_disp.ads, exp_disp.adb (Expand_Interface_Thunk): Modify the
6641 profile of interface thunks. The type of the controlling formal is now
6642 the covered interface type (instead of the target tagged type).
6644 2010-01-27 Sergey Rybin <rybin@adacore.com>
6646 * gnat_rm.texi, gnat_ugn.texi: Update gnatcheck doc.
6648 2010-01-27 Robert Dewar <dewar@adacore.com>
6650 * sinput.ads, sinput.adb (Sloc_Range): Applies to all nodes, formal
6651 changed from Expr to N.
6653 2010-01-26 Thomas Quinot <quinot@adacore.com>
6655 * gnat_ugn.texi: Adjust documentation of -gnatz switches.
6656 * usage.adb: Replace line for -gnatz with two lines for -gnatzc and
6659 2010-01-26 Vincent Celier <celier@adacore.com>
6661 * prj-attr.adb: Add new attribute Library_Install_Name_Option
6662 Replace attribute Run_Path_Origin_Supported with Run_Path_Origin
6663 * prj-nmsc.adb (Process_Project_Level_Simple_Attributes): Process
6664 attributes Run_Path_Option and Library_Install_Name_Option.
6665 * prj.ads (Project_Configuration): Replace component
6666 Run_Path_Origin_Supported with component Run_Path_Origin. Add new
6667 component Library_Install_Name_Option.
6668 * snames.ads-tmpl: Add new standard name Library_Install_Name_Option
6669 Replace Run_Path_Origin_Supported with Run_Path_Origin
6671 2010-01-26 Ed Schonberg <schonberg@adacore.com>
6673 * sem_ch8.adb (Use_One_Package): Within an instance, an actual package
6674 is not hidden by a homograph declared in another actual package.
6676 2010-01-26 Robert Dewar <dewar@adacore.com>
6678 * par_sco.adb (Traverse_Declarations_Or_Statements): Only generate
6679 decisions for pragmas Assert, Check, Precondition, Postcondition if
6681 * scos.ads: Update comments.
6682 * get_scos.adb, put_scos.adb: Minor fix to code reading statement SCOs.
6683 Also remove obsolete code for CT (exit point) SCOs.
6685 2010-01-26 Thomas Quinot <quinot@adacore.com>
6687 * switch-c.adb: Fix handling of -gnatz*
6689 2010-01-26 Robert Dewar <dewar@adacore.com>
6691 * par_sco.adb (Traverse_Declarations_Or_Statements): Separate F/W
6692 qualifiers for FOR/WHILE loops
6693 * scos.ads: Use separate type letters F/W for for/while loops
6695 2010-01-26 Robert Dewar <dewar@adacore.com>
6697 * get_scos.adb (Get_SCOs): Implement new form of CS entries (multiple
6698 entries per line, one for each statement in the sequence).
6699 * par_sco.adb (Traverse_Declarations_Or_Statements): Increase array
6700 size from 100 to 10_000 for SC_Array to avoid any real possibility of
6701 overflow. Output decisions in for loops.
6702 Exclude labels from CS lines.
6703 * scos.ads: Clarify that label is not included in the entry point
6705 2010-01-26 Robert Dewar <dewar@adacore.com>
6707 * par_sco.adb (Traverse_Declarations_Or_Statments): Implement new
6708 format of statement sequence SCO entries (one location/statement).
6709 * put_scos.adb (Put_SCOs): Implement new format of CS lines
6710 * scos.ads: Update comments.
6711 * sem_eval.adb: Minor reformatting.
6713 2010-01-26 Robert Dewar <dewar@adacore.com>
6715 * par_sco.ads, par_sco.adb (Set_Statement_Entry): New handling of exits
6716 (Extend_Statement_Sequence): New procedures
6717 (Traverse_Declarations_Or_Statements): New handling for exits.
6719 2010-01-26 Robert Dewar <dewar@adacore.com>
6721 * par_sco.adb (Traverse_Declarations_Or_Statements): Add processing for
6724 2010-01-26 Robert Dewar <dewar@adacore.com>
6726 * par_sco.adb (Is_Logical_Operator): Exclude AND/OR/XOR
6727 * scos.ads: Clarify handling of logical operators
6729 2010-01-26 Arnaud Charlet <charlet@adacore.com>
6731 * s-tpoben.adb: Update comments.
6733 2010-01-26 Robert Dewar <dewar@adacore.com>
6735 * freeze.adb (Set_Small_Size): Don't set size if alignment clause
6738 2010-01-26 Robert Dewar <dewar@adacore.com>
6740 * scos.ads: Clean up documentation, remove obsolete XOR references
6741 2010-01-26 Vincent Celier <celier@adacore.com>
6743 * gnat_ugn.texi: Complete documentation on the restrictions for
6744 combined options in -gnatxxx switches.
6747 2010-01-26 Arnaud Charlet <charlet@adacore.com>
6749 * s-tpoben.adb (Initialize_Protection_Entries): If a PO is created from
6750 a controlled operation, abort is already deferred at this point, so we
6751 need to use Defer_Abort_Nestable.
6753 2010-01-26 Vincent Celier <celier@adacore.com>
6755 * prj-conf.adb (Get_Config_Switches): Check for a default language for
6756 a project extending a project with no languages.
6758 2010-01-26 Vincent Celier <celier@adacore.com>
6760 * switch-c.adb (Scan_Front_End_Switches): Take into account options
6761 that follow -gnatef.
6762 Allow -gnateG to be followed by other options.
6764 2010-01-26 Robert Dewar <dewar@adacore.com>
6766 * s-commun.ads, s-osprim-mingw.adb, s-stchop-vxworks.adb, sem_aggr.adb,
6767 s-vxwext.adb, sem_ch10.adb, sem_eval.adb, sem_prag.adb: Minor
6770 2010-01-26 Vasiliy Fofanov <fofanov@adacore.com>
6772 * g-regist.adb, g-regist.ads (For_Every_Key): New generic procedure
6773 that allows to iterate over all subkeys of a key.
6775 2010-01-26 Ed Falis <falis@adacore.com>
6777 * sysdep.c: enable NFS for VxWorks MILS
6778 * env.c: enable __gnat_environ for VxWorks MILS
6779 * gcc-interface/Makefile.in: Add VxWorks MILS target pairs.
6781 2010-01-25 Bob Duff <duff@adacore.com>
6783 * sem_aggr.adb (Resolve_Array_Aggregate): Check for the case where this
6784 is an internally-generated positional aggregate, and the bounds are
6785 already correctly set. We don't want to overwrite those bounds with
6786 bounds determined by context.
6788 2010-01-25 Robert Dewar <dewar@adacore.com>
6790 * g-sercom.ads, gnatcmd.adb, gnatlink.adb, a-ststio.adb, exp_ch6.adb,
6791 exp_ch9.adb, g-sechas.ads: Minor reformatting.
6793 2010-01-25 Thomas Quinot <quinot@adacore.com>
6795 * s-commun.adb (Last_Index): Count must be converted to SEO (a signed
6796 integer type) before subtracting 1, otherwise the computation may wrap
6797 (because size_t is modular) and cause the conversion to fail.
6799 2010-01-25 Ed Falis <falis@adacore.com>
6801 * sysdep.c, init.c: Adapt to support full run-time on VxWorks MILS.
6803 2010-01-25 Vincent Celier <celier@adacore.com>
6805 * prj-attr.adb: New attribute Run_Path_Origin_Required
6806 * prj-nmsc.adb (Process_Project_Level_Simple_Attributes): Process new
6807 attribute Run_Path_Origin_Required.
6808 * prj.ads (Project_Configuration): New component
6809 Run_Path_Origin_Supported.
6810 * snames.ads-tmpl: New standard name Run_Path_Origin_Required
6812 2010-01-25 Ed Schonberg <schonberg@adacore.com>
6814 * sem_aggr.adb (Resolve_Array_Aggregate): If the bounds in a choice
6815 have errors, do not continue resolution of the aggregate.
6816 * sem_eval.adb (Eval_Indexed_Component): Do not attempt to evaluate if
6817 the array type indicates an error.
6819 2010-01-25 Bob Duff <duff@adacore.com>
6821 * sinfo.ads: Minor comment fixes.
6823 2010-01-25 Bob Duff <duff@adacore.com>
6825 * exp_ch4.adb, exp_aggr.adb: Minor comment fixes and code clean up.
6827 2010-01-25 Arnaud Charlet <charlet@adacore.com>
6829 * gnatvsn.ads (Current_Year): Update.
6831 2010-01-25 Florian Villoing <villoing@adacore.com>
6833 * gnat_ugn.texi: Fix typo.
6835 2010-01-25 Thomas Quinot <quinot@adacore.com>
6837 * scos.ads: Update specification.
6839 2010-01-25 Ed Schonberg <schonberg@adacore.com>
6841 * sem_ch6.adb (Process_PPCs): If a postcondition is present and the
6842 enclosing subprogram has no previous spec, attach postcondition
6843 procedure to the defining entity for the body.
6845 2010-01-25 Ed Schonberg <schonberg@adacore.com>
6847 * exp_aggr.adb (Build_Record_Aggr_Code); Do not generate call to
6848 initialization procedure of the ancestor part of an extension aggregate
6849 if it is an interface type.
6851 2010-01-25 Vincent Celier <celier@adacore.com>
6853 * gnatlink.adb (Process_Binder_File): The directory for the shared
6854 version of libgcc in the run path options is found in the subdirectory
6855 indicated by __gnat_default_libgcc_subdir.
6856 * link.c: Declare new const char * __gnat_default_libgcc_subdir for
6859 2010-01-25 Ed Schonberg <schonberg@adacore.com>
6861 * sem_prag.adb: More flexible pragma Annotate.
6863 2010-01-22 Eric Botcazou <ebotcazou@adacore.com>
6865 * system-linux-armel.ads (Stack_Check_Probes): Set to True.
6866 * system-linux-armeb.ads (Stack_Check_Probes): Likewise.
6868 2010-01-18 Eric Botcazou <ebotcazou@adacore.com>
6870 * gcc-interface/utils.c (create_var_decl_1): Fix formatting nits.
6872 2010-01-18 Jan Hubicka <jh@suse.cz>
6875 * gcc-interface/utils.c (create_var_decl_1): Do not set COMMON flag for
6876 unit local variables.
6878 2010-01-17 Laurent GUERBY <laurent@guerby.net>
6880 * gcc-interface/Makefile.in: Fix typo in arm*-*-linux-gnueabi.
6882 2010-01-11 Mikael Pettersson <mikpe@it.uu.se>
6884 * gcc-interface/Makefile.in: Add arm*-*-linux-gnueabi.
6885 * system-linux-armeb.ads, system-linux-armel.ads: New files.
6887 2010-01-09 Simon Wright <simon@pushface.org>
6890 * gcc-interface/Makefile.in (gnatlib-shared-darwin): Add missing
6895 Copyright (C) 2010 Free Software Foundation, Inc.
6897 Copying and distribution of this file, with or without modification,
6898 are permitted in any medium without royalty provided the copyright
6899 notice and this notice are preserved.