1 2010-06-18 Javier Miranda <miranda@adacore.com>
3 * exp_cg.adb: Code clean up.
4 * debug.adb: Complete documentation of switch -gnatd.Z.
5 * gcc-interface/misc.c (callgraph_info_file): Declare.
7 2010-06-18 Javier Miranda <miranda@adacore.com>
9 * exp_cg.adb (Homonym_Suffix_Length): Minor code reorganization.
11 2010-06-18 Thomas Quinot <quinot@adacore.com>
13 * sprint.ads: Minor reformatting.
14 * output.ads: Update obsolete comment.
16 2010-06-18 Ed Schonberg <schonberg@adacore.com>
18 * freeze.adb (Build_And_Analyze_Renamed_Body): if the renamed entity is
19 an external intrinsic operation (e.g. a GCC numeric function) indicate
20 that the renaming entity has the same characteristics, so a call to it
23 2010-06-18 Javier Miranda <miranda@adacore.com>
25 * exp_cg.adb, exp_cg.ads, exp_disp.adb, gnat1drv.adb: Add initial
26 support for dispatch table/callgraph info generation.
27 * gcc-interface/Make-lang.in: Update dependencies.
29 2010-06-18 Robert Dewar <dewar@adacore.com>
31 * exp_ch6.adb: Minor reformatting.
32 * gnatname.adb: Add comment.
34 2010-06-18 Vincent Celier <celier@adacore.com>
36 * gnatname.adb (Scan_Args): When --and is used, make sure that the
37 dynamic tables in the newly allocated Argument_Data are properly
40 2010-06-18 Eric Botcazou <ebotcazou@adacore.com>
42 * gnat1drv.adb: Fix comment.
44 2010-06-18 Ed Schonberg <schonberg@adacore.com>
46 * exp_ch6.adb (Expand_Inlined_Call): If the inlined subprogram is a
47 renaming, re-expand the call with the renamed subprogram if that one
48 is marked inlined as well.
50 2010-06-18 Gary Dismukes <dismukes@adacore.com>
52 * gnat1drv.adb (Adjust_Global_Switches): Enable
53 Use_Expression_With_Actions for AAMP and VM targets.
55 2010-06-18 Vincent Celier <celier@adacore.com>
57 * prj-nmsc.adb (Process_Linker): Recognize response file format GCC.
59 2010-06-18 Thomas Quinot <quinot@adacore.com>
61 * exp_ch4.adb: Minor reformatting.
63 2010-06-18 Javier Miranda <miranda@adacore.com>
65 * debug.ads Add documentation on -gnatd.Z.
67 2010-06-18 Ed Schonberg <schonberg@adacore.com>
69 * sem_elim.adb: Proper error message on improperly eliminated instances
71 2010-06-18 Vincent Celier <celier@adacore.com>
73 * prj.ads (Response_File_Format): New value GCC.
75 2010-06-18 Thomas Quinot <quinot@adacore.com>
77 * gnat1drv.adb: Minor reformatting.
79 2010-06-18 Robert Dewar <dewar@adacore.com>
81 * make.adb, sem_cat.adb: Minor reformatting.
82 * sem_eval.adb: Fix typos.
84 2010-06-18 Pascal Obry <obry@adacore.com>
86 * prj-nmsc.adb: Fix source filenames casing in debug output.
88 2010-06-18 Robert Dewar <dewar@adacore.com>
90 * gnatcmd.adb: Minor reformatting.
92 2010-06-18 Robert Dewar <dewar@adacore.com>
94 * sem_eval.adb (Eval_Conditional_Expression): Result is static if
95 condition and both sub-expressions are static (and result is selected
98 2010-06-18 Robert Dewar <dewar@adacore.com>
100 * g-pehage.adb: Minor reformatting
102 2010-06-18 Pascal Obry <obry@adacore.com>
104 * prj-nmsc.adb (Search_Directories): Insert canonical filenames into
107 2010-06-18 Arnaud Charlet <charlet@adacore.com>
109 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
110 dependencies. Fix target pairs on darwin.
111 (gnatlib-sjlj, gnatlib-zcx): Pass THREAD_KIND.
113 2010-06-18 Pascal Obry <obry@adacore.com>
115 * make.adb, prj-nmsc.adb: Fix source filenames casing in debug output.
117 2010-06-18 Vincent Celier <celier@adacore.com>
119 * gnatcmd.adb: For gnatcheck, add -gnatec= switch for a global
120 configuration pragmas file and, if -U is not used, for a local one.
122 2010-06-18 Ed Schonberg <schonberg@adacore.com>
124 * sem_elim.adb (Check_Eliminated): Use full information on entity name
125 when it is given in the pragma by a selected component.
126 (Check_For_Eliminated_Subprogram): Do no emit error if within a
127 instance body that is itself within a generic unit.
128 * sem_ch12.adb (Analyze_Subprogram_Instance): If the subprogram is
129 eliminated, mark as well the anonymous subprogram that is its alias
130 and appears within the wrapper package.
132 2010-06-18 Bob Duff <duff@adacore.com>
134 * g-pehage.ads, g-pehage.adb (Produce): Clean up some of the code.
135 Raise an exception if the output file cannot be opened. Add comments.
137 2010-06-18 Thomas Quinot <quinot@adacore.com>
139 * sem_cat.adb (Validate_Object_Declaration): A variable declaration is
140 not illegal per E.2.2(7) if it occurs in the private part of a
143 2010-06-18 Arnaud Charlet <charlet@adacore.com>
145 * par-ch9.adb, sem_aggr.adb, sem_ch3.adb, layout.adb, sem_ch4.adb,
146 sem_ch5.adb, sem_mech.adb, exp_util.adb, par-ch10.adb, sem_ch6.adb,
147 par-ch11.adb, sem_ch7.adb, par-prag.adb, exp_disp.adb, par-ch12.adb,
148 sem_ch8.adb, style.adb, sem_ch9.adb, sem_ch10.adb, prep.adb,
149 sem_warn.adb, par-util.adb, scng.adb, sem_eval.adb, checks.adb,
150 sem_prag.adb, sem_ch12.adb, styleg.adb, sem_ch13.adb, par-ch3.adb,
151 par-tchk.adb, freeze.adb, sfn_scan.adb, par-ch4.adb, sem_util.adb,
152 sem_res.adb, par-ch5.adb, lib-xref.adb, sem_attr.adb, par-ch6.adb,
153 sem_disp.adb, prepcomp.adb, par-ch7.adb, sem_elab.adb, exp_ch4.adb,
154 errout.ads: Update comments. Minor reformatting.
156 * g-spipat.adb, a-swunau.adb, a-swunau.ads, g-spitbo.adb,
157 a-szunau.adb, a-szunau.ads, a-stunau.adb, a-stunau.ads,
158 a-strunb.adb (Big_String. Big_String_Access): New type.
160 * par-labl.adb, restrict.adb, s-osinte-hpux-dce.ads, sem_ch11.adb,
161 exp_pakd.adb, s-filofl.ads, par-endh.adb, exp_intr.adb, sem_cat.adb,
162 sem_case.adb, exp_ch11.adb, s-osinte-linux.ads: Fix copyright notices.
164 2010-06-18 Geert Bosch <bosch@adacore.com>
166 * i-forbla-darwin.adb: Include -lgnala and -lm in linker options for
169 2010-06-18 Robert Dewar <dewar@adacore.com>
171 * gnat1drv.adb (Adjust_Global_Switches): Set Use_Expression_With_Actions
174 2010-06-18 Robert Dewar <dewar@adacore.com>
176 * sprint.adb: Minor format change for N_Expression_With_Actions.
177 * repinfo.adb: Minor reformatting.
179 2010-06-18 Ed Schonberg <schonberg@adacore.com>
181 * sem_elim.adb (Check_Eliminated): If within a subunit, use
182 Defining_Entity to obtain the name of the entity in the proper body, to
183 properly handle both separate packages and subprograms.
185 2010-06-18 Emmanuel Briot <briot@adacore.com>
187 * prj-nmsc.adb (Check_File): New parameter Display_Path.
189 2010-06-18 Thomas Quinot <quinot@adacore.com>
191 * g-socket.adb, g-socket.ads (Null_Selector): New object.
193 2010-06-18 Pascal Obry <obry@adacore.com>
195 * gnat_ugn.texi: Minor clarification.
197 2010-06-18 Emmanuel Briot <briot@adacore.com>
199 * prj-nmsc.adb (Find_Source_Dirs): Minor refactoring to avoid duplicate
200 code when using the project dir as the source dir.
201 (Search_Directories): use the normalized name for the source directory,
202 where symbolic names have potentially been resolved.
204 2010-06-18 Robert Dewar <dewar@adacore.com>
206 * exp_ch4.adb (Expand_N_Conditional_Expression): Clear Actions field
207 when we create N_Expression_With_Actions node.
208 (Expand_Short_Circuit): Ditto.
210 2010-06-18 Robert Dewar <dewar@adacore.com>
212 * exp_util.adb: Minor reformatting.
214 2010-06-18 Thomas Quinot <quinot@adacore.com>
216 * types.ads: Clean up obsolete comments
217 * tbuild.adb: Minor reformatting.
218 * exp_ch5.adb, sem_intr.adb, sem_ch10.adb, rtsfind.adb, s-shasto.adb,
219 exp_strm.adb, aa_drive.adb: Minor reformatting.
220 * sem_res.adb (Is_Predefined_Operator): An operator that is an imported
221 intrinsic with an Interface_Name denotes an imported back-end builtin,
222 and must be rewritten into a call, not left in the tree as an operator,
223 so return False in that case.
225 2010-06-18 Eric Botcazou <ebotcazou@adacore.com>
227 * exp_util.adb (Remove_Side_Effects): Make a copy for an allocator.
229 2010-06-18 Robert Dewar <dewar@adacore.com>
231 * scos.ads: Add proposed output for case expression
233 2010-06-18 Jose Ruiz <ruiz@adacore.com>
235 * gnat_ugn.texi: Document that, when using the RTX compiler to generate
236 RTSS modules, we need to use the Microsoft linker.
238 2010-06-18 Robert Dewar <dewar@adacore.com>
240 * checks.adb (Safe_To_Capture_In_Parameter_Value): Deal with case
241 expression (cannot count on a particular branch being executed).
242 * exp_ch4.adb (Expand_N_Case_Expression): New procedure.
243 * exp_ch4.ads (Expand_N_Case_Expression): New procedure.
244 * exp_util.adb (Insert_Actions): Deal with proper insertion of actions
245 within case expression.
246 * expander.adb (Expand): Add call to Expand_N_Case_Expression
247 * par-ch4.adb Add calls to P_Case_Expression at appropriate points
248 (P_Case_Expression): New procedure
249 (P_Case_Expression_Alternative): New procedure
250 * par.adb (P_Case_Expression): New procedure
251 * par_sco.adb (Process_Decisions): Add dummy place holder entry for
253 * sem.adb (Analyze): Add call to Analyze_Case_Expression
254 * sem_case.ads (Analyze_Choices): Also used for case expressions now,
255 this is a documentation change only.
256 * sem_ch4.ads, sem_ch4.adb (Analyze_Case_Expression): New procedure.
257 * sem_ch6.adb (Fully_Conformant_Expressions): Add handling of case
259 * sem_eval.ads, sem_eval.adb (Eval_Case_Expression): New procedure.
260 * sem_res.adb (Resolve_Case_Expression): New procedure.
261 * sem_scil.adb (Find_SCIL_Node): Add processing for
262 N_Case_Expression_Alternative.
263 * sinfo.ads, sinfo.adb (N_Case_Expression): New node.
264 (N_Case_Expression_Alternative): New node.
265 * sprint.adb (Sprint_Node_Actual): Add processing for new nodes
266 N_Case_Expression and N_Case_Expression_Alternative.
268 2010-06-18 Robert Dewar <dewar@adacore.com>
270 * par-ch7.adb, sem_warn.adb, types.ads, par-ch3.adb: Minor reformatting.
271 * gnat1drv.adb: Fix typo.
273 2010-06-18 Robert Dewar <dewar@adacore.com>
275 * par-prag.adb (Prag, case Style_Checks): All_Checks sets gnat style
277 * sem_prag.adb (Analyze_Pragma, case Style_Checks): All_Checks sets
278 gnat style for -gnatg.
279 * gnat_rm.texi: Add documentation for ALL_CHECKS in GNAT mode.
281 2010-06-18 Thomas Quinot <quinot@adacore.com>
283 * sem_eval.adb (Test_In_Range): New subprogram, factoring duplicated
285 (Is_In_Range, Is_Out_Of_Range): Reimplement in terms of call to
288 2010-06-18 Robert Dewar <dewar@adacore.com>
290 * sprint.adb: Minor change in output format for expression wi actions.
291 * par-ch3.adb: Minor code reorganization. Minor reformatting.
292 * sem_ch5.adb: Minor comment fix.
294 2010-06-18 Robert Dewar <dewar@adacore.com>
296 * debug.adb: New debug flag -gnatd.L to control
297 Back_End_Handles_Limited_Types.
298 * exp_ch4.adb (Expand_N_Conditional_Expression): Let back end handle
299 limited case if Back_End_Handles_Limited_Types is True.
300 (Expand_N_Conditional_Expression): Use N_Expression_With_Actions to
301 simplify expansion if Use_Expression_With_Actions is True.
302 * gnat1drv.adb (Adjust_Global_Switches): Set
303 Back_End_Handles_Limited_Types.
304 * opt.ads (Back_End_Handles_Limited_Types): New flag.
306 2010-06-18 Ed Schonberg <schonberg@adacore.com>
308 * sem_res.adb (Rewrite_Operator_As_Call): Do not rewrite user-defined
309 intrinsic operator if expansion is not enabled, because in an
310 instantiation the original operator must be present to verify the
311 legality of the operation.
313 2010-06-18 Robert Dewar <dewar@adacore.com>
315 * exp_disp.adb, sem_ch12.adb: Minor reformatting
317 2010-06-18 Ed Schonberg <schonberg@adacore.com>
319 * exp_util.adb (Make_Subtype_From_Expr): If the unconstrained type is
320 the class-wide type for a private extension, and the completion is a
321 subtype, set the type of the class-wide type to the base type of the
324 2010-06-18 Robert Dewar <dewar@adacore.com>
326 * g-socket.ads, sem_aggr.adb, einfo.ads, sem_elim.adb,
327 sem_intr.adb, sem_eval.adb: Minor reformatting
329 2010-06-18 Ed Schonberg <schonberg@adacore.com>
331 * sem_type.adb (Is_Ancestor): If either type is private, examine full
334 2010-06-18 Thomas Quinot <quinot@adacore.com>
336 * g-socket.adb, g-socket.ads (Check_Selector): Make Selector an IN
337 parameter rather than IN OUT.
339 2010-06-18 Ed Schonberg <schonberg@adacore.com>
341 * exp_ch6.adb: Add extra guard.
343 2010-06-18 Gary Dismukes <dismukes@adacore.com>
345 * sem_util.adb (Object_Access_Level): For Ada 2005, determine the
346 accessibility level of a function call from the level of the innermost
347 enclosing dynamic scope.
348 (Innermost_Master_Scope_Depth): New function to find the depth of the
349 nearest dynamic scope enclosing a node.
351 2010-06-18 Tristan Gingold <gingold@adacore.com>
353 * adaint.c: Make ATTR_UNSET static as it is not used outside this file.
355 2010-06-18 Thomas Quinot <quinot@adacore.com>
357 * g-socket.ads: Minor reformatting.
359 2010-06-18 Vincent Celier <celier@adacore.com>
361 * make.adb (Must_Compile): New Boolean global variable
362 (Main_On_Command_Line): New Boolean global variable
363 (Collect_Arguments_And_Compile): Do compile if Must_Compile is True,
364 even when the project is externally built.
365 (Start_Compile_If_Possible): Compile in -aL directories if
366 Check_Readonly_Files is True. Do compile if Must_Compile is True, even
367 when the project is externally built.
368 (Gnatmake): Set Must_Compile and Check_Readonly_Files to True when
369 invoked with -f -u and one or several mains on the command line.
370 (Scan_Make_Arg): Set Main_On_Command_Line to True when at least one main
371 is specified on the command line.
373 2010-06-18 Ed Schonberg <schonberg@adacore.com>
375 * sem_ch6.adb (Build_Body_For_Inline): Handle extended_return_statements
376 * exp_ch6.adb (Expand_Inlined_Call): when possible, inline a body
377 containing extented_return statements.
378 * exp_util.adb (Make_CW_Equivalent_Type): If the root type is already
379 constrained, do not build subtype declaration.
381 2010-06-18 Robert Dewar <dewar@adacore.com>
383 * sem_res.adb (Analyze_Indexed_Component, Analyze_Selected_Component):
384 Warn on assigning to packed atomic component.
386 2010-06-18 Robert Dewar <dewar@adacore.com>
388 * sem_util.ads: Minor reformatting
389 * einfo.ads, einfo.adb: Minor doc clarification (scope of decls in
390 Expression_With_Actions).
391 * snames.ads-tmpl: Minor comment fix
393 2010-06-18 Robert Dewar <dewar@adacore.com>
395 * sem_prag.adb (Diagnose_Multiple_Pragmas): New procedure
396 (Set_Imported): Use Import_Interface_Present to control message output
397 * sinfo.ads, sinfo.adb (Import_Interface_Present): New flag
398 * gnat_rm.texi: Document that we can have pragma Import and pragma
399 Interface for the same subprogram.
401 2010-06-18 Robert Dewar <dewar@adacore.com>
403 * lib-xref.adb (Generate_Reference): Fix bad reference to
404 Has_Pragma_Unreferenced (clients should always use Has_Unreferenced).
406 2010-06-17 Eric Botcazou <ebotcazou@adacore.com>
408 * gcc-interface/trans.c (set_gnu_expr_location_from_node): New static
410 (gnat_to_gnu) <N_Expression_With_Actions>: New case.
411 Use set_gnu_expr_location_from_node to set location information on the
414 2010-06-17 Arnaud Charlet <charlet@adacore.com>
416 * gcc-interface/Make-lang.in: Update dependencies.
418 2010-06-17 Ed Schonberg <schonberg@adacore.com>
420 * sem_util.adb (Is_Atomic_Object): Predicate does not apply to
423 2010-06-17 Robert Dewar <dewar@adacore.com>
425 * gnat_rm.texi, gnat_ugn.texi: Clean up documentation on warning and
426 style check messages.
427 * sem_res.adb (Resolve_Call): Don't call
428 Check_For_Eliminated_Subprogram if we are analyzing within a spec
431 2010-06-17 Robert Dewar <dewar@adacore.com>
433 * debug.adb: Add documentation for debug flags .X and .Y
434 * exp_ch4.adb (Expand_Short_Circuit_Operator): Use
435 Use_Expression_With_Actions.
436 * gnat1drv.adb (Adjust_Global_Switches): Set
437 Use_Expression_With_Actions.
438 * opt.ads (Use_Expression_With_Actions): New switch.
440 2010-06-17 Robert Dewar <dewar@adacore.com>
442 * exp_intr.adb: Minor code reorganization (use UI_Max)
443 * sem_intr.adb: use underlying type to check legality.
444 * einfo.adb (Known_Static_Esize): False for generic types
445 (Known_Static_RM_Size): False for generic types
446 * einfo.ads (Known_Static_Esize): False for generic types
447 (Known_Static_RM_Size): False for generic types
449 2010-06-17 Robert Dewar <dewar@adacore.com>
451 * exp_ch4.ads: Minor code reorganization (specs in alpha order).
453 2010-06-17 Robert Dewar <dewar@adacore.com>
455 * debug.adb: New debug flag -gnatd.X to use Expression_With_Actions
456 node when expanding short circuit form with actions present for right
458 * exp_ch4.adb: Minor reformatting
459 (Expand_Short_Circuit_Operator): Use new Expression_With_Actions node if
460 right opeand has actions present, and debug flag -gnatd.X is set.
461 * exp_util.adb (Insert_Actions): Handle case of Expression_With_Actions
463 * nlists.adb (Prepend_List): New procedure
464 (Prepend_List_To): New procedure
465 * nlists.ads (Prepend_List): New procedure
466 (Prepend_List_To): New procedure
467 * sem.adb: Add processing for Expression_With_Actions
468 * sem_ch4.adb (Analyze_Expression_With_Actions): New procedure
469 * sem_ch4.ads (Analyze_Expression_With_Actions): New procedure
470 * sem_res.adb: Add processing for Expression_With_Actions.
471 * sem_scil.adb: Add processing for Expression_With_Actions
472 * sinfo.ads, sinfo.adb (N_Expression_With_Actions): New node.
473 * sprint.ads, sprint.adb: Add processing for Expression_With_Actions
475 2010-06-17 Doug Rupp <rupp@adacore.com>
477 * sem_intr.adb (Check_Intrinsic_Operator): Check that the types
478 involved both have underlying integer types.
479 * exp_intr.adb (Expand_Binary_Operator) New subprogram to expand a call
480 to an intrinsic operator when the operand types or sizes are not
482 * s-auxdec-vms_64.ads: Revert "+" "-" ops back to Address now that
483 64/32 Address/Integer works.
485 2010-06-17 Ed Schonberg <schonberg@adacore.com>
487 * sem_ch12.adb (Mark_Context): Refine placement of Withed_Body flag, so
488 that it marks a unit as needed by a spec only if the corresponding
489 instantiation appears in that spec (and not in the corresponding body).
490 * sem_elim.adb (Check_Eliminated): If we are within a subunit, the name
491 in the pragma Eliminate has been parsed as a child unit, but the
492 current compilation unit is in fact the parent in which the subunit is
495 2010-06-17 Vincent Celier <celier@adacore.com>
497 * gnat_rm.texi: Fix typo
499 2010-06-17 Robert Dewar <dewar@adacore.com>
501 * sem_util.adb: Minor reformatting
503 2010-06-17 Ed Schonberg <schonberg@adacore.com>
505 * sem.adb (Do_Withed_Unit): if the unit in the with_clause is a generic
506 instance, the clause now denotes the instance body. Traverse the
507 corresponding spec because there may be no other dependence that will
508 force the traversal of its own context.
510 2010-06-17 Ed Schonberg <schonberg@adacore.com>
512 * sem_ch10.adb (Is_Ancestor_Unit): Subsidiary to
513 Install_Limited_Context_Clauses, to determine whether a limited_with in
514 some parent of the current unit designates some other parent, in which
515 case the limited_with clause must not be installed.
516 (In_Context): Refine test.
518 2010-06-17 Gary Dismukes <dismukes@adacore.com>
520 * sem_util.adb (Collect_Primitive_Operations): In the of an untagged
521 type with a dispatching equality operator that is overridden (for a
522 tagged full type), don't include the overridden equality in the list of
523 primitives. The overridden equality is detected by testing for an
524 Aliased field that references the overriding equality.
526 2010-06-17 Robert Dewar <dewar@adacore.com>
528 * freeze.adb: Minor reformatting.
530 2010-06-17 Joel Brobecker <brobecker@adacore.com brobecker>
532 * gnat_ugn.texi: Add a section introducing gdbserver.
534 2010-06-17 Thomas Quinot <quinot@adacore.com>
536 * sem_res.adb, sem_ch4.adb, s-stoele.adb, par-labl.adb: Minor
539 2010-06-17 Ed Schonberg <schonberg@adacore.com>
541 * sem_aggr.adb (Valid_Ancestor_Type): handle properly the case of a
542 constrained discriminated parent that is a private type.
543 (Analyze_Record_Aggregate): when collecting inherited discriminants,
544 handle properly an ancestor type that is a constrained private type.
546 2010-06-17 Ed Schonberg <schonberg@adacore.com>
548 * sem_util.adb (Enclosing_Subprogram): If the called subprogram is
549 protected, use the protected_subprogram_body only if the original
550 subprogram has not been eliminated.
552 2010-06-17 Ed Schonberg <schonberg@adacore.com>
554 * freeze.adb (Freeze_Expression): The designated type of an
555 access_to_suprogram type can only be frozen if all types in its profile
558 2010-06-17 Robert Dewar <dewar@adacore.com>
560 * par.adb: Minor comment fix
561 * sem_aggr.adb, sem_ch3.adb: Minor reformatting
563 2010-06-17 Doug Rupp <rupp@adacore.com>
565 * s-auxdec-vms_64.ads: Revert Integer to Long_Integer change, instead
566 change Address to Short_Address in functions where both must be the
567 same size for intrinsics to work.
569 2010-06-17 Thomas Quinot <quinot@adacore.com>
571 * sem_ch4.adb (Analyze_Selected_Component): A selected component may
572 not denote a (private) component of a protected object.
574 2010-06-17 Bob Duff <duff@adacore.com>
576 * par-labl.adb (Try_Loop): Test whether the label and the goto are in
579 2010-06-17 Joel Brobecker <brobecker@adacore.com brobecker>
581 * gnat_ugn.texi: Update the documentation about GDB re: exception
584 2010-06-17 Arnaud Charlet <charlet@adacore.com>
586 * gnatvsn.ads: Bump to 4.6 version.
588 2010-06-17 Ed Schonberg <schonberg@adacore.com>
590 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration): The
591 designated type of the generated pointer is the type of the original
592 expression, not that of the function call itself, because the return
593 type may be an untagged derived type and the function may be an
596 2010-06-17 Robert Dewar <dewar@adacore.com>
598 * exp_ch4.adb: Minor reformatting.
600 2010-06-17 Ed Schonberg <schonberg@adacore.com>
602 * sinfo.ads, sinfo.adb (Inherited_Discriminant): New flag on
603 N_Component_Association nodes, to indicate that a component association
604 of an extension aggregate denotes the value of a discriminant of an
605 ancestor type that has been constrained by the derivation.
606 * sem_aggr.adb (Discr_Present): use Inherited_Discriminant to prevent a
607 double expansion of the aggregate appearing in a context that delays
608 expansion, to prevent double insertion of discriminant values when the
609 aggregate is reanalyzed.
611 2010-06-17 Arnaud Charlet <charlet@adacore.com>
613 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Do not use
614 Allocator as the Related_Node of Return_Obj_Access in call to
615 Make_Temporary below as this would create a sort of infinite
618 2010-06-17 Ben Brosgol <brosgol@adacore.com>
620 * gnat_ugn.texi: Update gnatcheck doc.
622 2010-06-17 Ed Schonberg <schonberg@adacore.com>
624 * sem_ch3.adb (Build_Incomplete_Type_Declaration): If there is an
625 incomplete view of the type that is not tagged, and the full type is a
626 tagged extension, create class_wide type now, and warn that the
627 incomplete view should be tagged as well.
629 2010-06-17 Vincent Celier <celier@adacore.com>
631 * gnatcmd.adb (Non_VMS_Usage): Do not issue usage for gnat sync.
632 Update the last line of the usage, indicating what commands do not
633 accept project file switches.
634 * vms_conv.adb: Do not issue usage line for GNAT SYNC
635 * vms_data.ads: Fix errors in the qualifiers /LOGFILE and /MAIN of
637 * gnat_ugn.texi: Document the relaxed rules for library directories in
638 externally built library projects.
640 2010-06-17 Doug Rupp <rupp@adacore.com>
642 * s-auxdec-vms_64.ads: Make boolean and arithmetic operations intrinsic
644 * s-auxdec-vms-alpha.adb: Remove kludges for aforemention.
645 * gcc-interface/Makefile.in: Update VMS target pairs.
647 2010-06-17 Vasiliy Fofanov <fofanov@adacore.com>
649 * adaint.c: Reorganized in order to avoid use of GetProcessId to stay
650 compatible with Windows NT 4.0 which doesn't provide this function.
652 2010-06-17 Vincent Celier <celier@adacore.com>
654 * ali-util.adb (Time_Stamp_Mismatch): In Verbose mode, if there is
655 different timestamps but the checksum is the same, issue a short
658 2010-06-17 Arnaud Charlet <charlet@adacore.com>
660 * s-interr.adb (Finalize): If the Abort_Task signal is set to system,
661 it means that we cannot reset interrupt handlers since this would
662 require potentially sending the abort signal to the Server_Task.
664 2010-06-17 Ed Schonberg <schonberg@adacore.com>
666 * exp_ch4.adb: expand NOT for VMS types.
667 * sem_util.adb: Use OpenVMS_On_Target for IS_VMS_Operator.
669 2010-06-17 Sergey Rybin <rybin@adacore.com>
671 * vms_data.ads: Add qualifier for '--no-elim-dispatch' gnatelim option.
672 * gnat_ugn.texi (gnatelim): add description for --no-elim-dispatch
675 2010-06-17 Ed Schonberg <schonberg@adacore.com>
677 * exp_ch6.adb (Expand_Call): Do not expand a call to an internal
678 protected operation if the subprogram has been eliminated.
680 2010-06-17 Vincent Celier <celier@adacore.com>
682 * prj-nmsc.adb (Check_Library_Attributes): Allow the different
683 directories associated with a library to be any directory when the
684 library project is externally built.
686 2010-06-17 Vincent Celier <celier@adacore.com>
688 * make.adb (Check): If switch -m is used, deallocate the memory that
689 may be allocated when computing the checksum.
691 2010-06-17 Eric Botcazou <ebotcazou@adacore.com>
693 * g-socthi-mingw.adb (C_Recvmsg): Add 'use type' clause for C.size_t;
694 (C_Sendmsg): Likewise.
696 2010-06-17 Thomas Quinot <quinot@adacore.com>
698 * sem_res.adb: Update comments.
700 2010-06-17 Vincent Celier <celier@adacore.com>
702 * back_end.adb (Scan_Compiler_Arguments): Process last argument
704 2010-06-17 Robert Dewar <dewar@adacore.com>
706 * exp_ch3.adb, exp_ch6.adb, exp_smem.adb, exp_util.adb: Use Ekind_In.
707 * layout.adb, freeze.adb: Use Make_Temporary.
709 2010-06-17 Jerome Lambourg <lambourg@adacore.com>
711 * exp_ch11.adb (Expand_N_Raise_Statement): Expand raise statements in
712 .NET/JVM normally as this is now perfectly supported by the backend.
714 2010-06-17 Pascal Obry <obry@adacore.com>
716 * gnat_rm.texi: Fix minor typo, remove duplicate blank lines.
718 2010-06-17 Vincent Celier <celier@adacore.com>
720 * make.adb (Collect_Arguments_And_Compile): Create include path file
721 only when -x is specified.
723 * opt.ads (Use_Include_Path_File): New Boolean flag, initialized to
725 * prj-env.adb (Set_Ada_Paths): New Boolean parameters Include_Path and
726 Objects_Path, defaulted to True. Only create include path file if
727 Include_Path is True, only create objects path file if Objects_Path is
729 * prj-env.ads (Set_Ada_Paths): New Boolean parameters Include_Path and
730 Objects_Path, defaulted to True.
731 * switch-m.adb (Scan_Make_Switches): Set Use_Include_Path_File to True
734 2010-06-17 Ed Schonberg <schonberg@adacore.com>
736 * exp_disp.adb (Build_Interface_Thunk): Use base type of formal to
737 determine whether it has the controlling type, when the formal is an
740 2010-06-17 Eric Botcazou <ebotcazou@adacore.com>
742 * s-crtl.ads (ssize_t): New type.
743 (read): Fix signature.
745 * g-socthi.ads: Add 'with System.CRTL' clause. Remove ssize_t and
746 'use type' directive for C.size_t, add one for System.CRTL.ssize_t.
747 (C_Recvmsg): Replace ssize_t with System.CRTL.ssize_t.
748 (C_Sendmsg): Likewise.
749 * g-socthi.adb (Syscall_Recvmsg): Likewise.
750 (Syscall_Sendmsg): Likewise.
751 (C_Recvmsg): Likewise.
752 (C_Sendmsg): Likewise.
753 * g-socthi-mingw.ads: Add 'with System.CRTL' clause. Remove ssize_t
754 and 'use type' directive for C.size_t, add one for System.CRTL.ssize_t.
755 (C_Recvmsg): Replace ssize_t with System.CRTL.ssize_t.
756 (C_Sendmsg): Likewise.
757 * g-socthi-mingw.adb (C_Recvmsg): Likewise.
758 (C_Sendmsg): Likewise.
759 * g-socthi-vms.ads: Add 'with System.CRTL' clause. Remove ssize_t and
760 'use type' directive for C.size_t, add one for System.CRTL.ssize_t.
761 (C_Recvmsg): Replace ssize_t with System.CRTL.ssize_t.
762 (C_Sendmsg): Likewise.
763 * g-socthi-vms.adb (C_Recvmsg): Likewise.
764 (C_Sendmsg): Likewise.
765 * g-socthi-vxworks.ads Add 'with System.CRTL' clause. Remove ssize_t
766 and 'use type' directive for C.size_t, add one for System.CRTL.ssize_t.
767 (C_Recvmsg): Replace ssize_t with System.CRTL.ssize_t.
768 (C_Sendmsg): Likewise.
769 * g-socthi-vxworks.adb (C_Recvmsg): Likewise.
770 (C_Sendmsg): Likewise.
771 * g-sercom-linux.adb (Read): Use correct types to call 'read'.
772 (Write): Likewise to call 'write'.
773 * s-os_lib.adb (Read): Use correct type to call System.CRTL.read.
774 (Write): Use correct type to call System.CRTL.write.
775 * s-tasdeb.adb (Write): Likewise.
777 2010-06-17 Vincent Celier <celier@adacore.com>
779 * prj-proc.adb (Copy_Package_Declarations): Change argument name
780 Naming_Restricted to Restricted. If Restricted is True, do not copy the
781 value of attribute Linker_Options.
783 2010-06-17 Eric Botcazou <ebotcazou@adacore.com>
785 * gcc-interface/trans.c (push_stack, pop_stack): Delete.
786 (Case_Statement_to_gnu): Adjust.
787 (Loop_Statement_to_gnu): Likewise.
788 (Subprogram_Body_to_gnu): Likewise.
789 (Handled_Sequence_Of_Statements_to_gnu): Likewise.
790 (Compilation_Unit_to_gnu): Likewise.
792 2010-06-17 Robert Dewar <dewar@adacore.com>
794 * exp_fixd.adb, exp_imgv.adb, exp_intr.adb, exp_pakd.adb, exp_prag.adb,
795 exp_sel.adb, exp_util.adb, sem_ch10.adb, sem_ch12.adb, sem_ch13.adb,
796 sem_ch3.adb, sem_ch4.adb, sem_ch5.adb, sem_ch8.adb, sem_ch9.adb,
797 sem_dist.adb, sem_util.adb: Use Make_Temporary
798 * itypes.ads, tbuild.ads: Minor comment update
799 * exp_ch9.adb, exp_dist.adb: Minor reformatting
801 2010-06-17 Thomas Quinot <quinot@adacore.com>
803 * exp_imgv.adb, exp_ch7.ads: Minor reformatting.
805 2010-06-17 Robert Dewar <dewar@adacore.com>
807 * exp_ch9.adb, exp_disp.adb, exp_dist.adb: Use Make_Temporary.
809 2010-06-17 Thomas Quinot <quinot@adacore.com>
811 * sprint.adb (pg): Set Dump_Freeze_Null, to be consistent with -gnatdg.
813 2010-06-17 Robert Dewar <dewar@adacore.com>
815 * exp_ch6.adb, exp_ch7.adb, exp_ch5.adb: Use Make_Temporary
816 * tbuild.ads (Make_Temporary): More comment updates
817 * tbuild.adb: Minor reformatting
819 2010-06-17 Robert Dewar <dewar@adacore.com>
821 * checks.adb, exp_aggr.adb, exp_atag.adb, exp_attr.adb, exp_ch11.adb,
822 exp_ch3.adb, exp_ch4.adb: Minor code reorganization.
824 * tbuild.ads, tbuild.adb (Make_Temporary): Clean up, use Entity_Id
826 (Make_Temporary): Add more extensive documentation
828 2010-06-17 Robert Dewar <dewar@adacore.com>
830 * sem_intr.adb, sem_prag.adb, sem_res.adb, sem_type.adb, sem_util.adb,
831 sem_warn.adb, sem_eval.adb: Minor reformatting. Use Ekind_In.
832 (Set_Slice_Subtype): Explicitly freeze the slice's itype at the point
833 where the slice's actions are inserted.
834 (Decompose_Expr): Account for possible rewriting of slice bounds
835 resulting from side effects suppression caused by the above freezing,
836 so that folding of bounds is preserved by such rewriting.
838 2010-06-17 Robert Dewar <dewar@adacore.com>
840 * einfo.ads, einfo.adb (Get_Record_Representation_Clause): New function.
841 * freeze.adb (Freeze_Record_Type): Add call to
842 Check_Record_Representation_Clause.
843 * sem_ch13.adb (Check_Record_Representation_Clause): New function
844 (Analyze_Record_Representation_Clause): Split out overlap code into this
846 (Check_Component_Overlap): Moved inside
847 Check_Record_Representation_Clause.
848 * sem_ch13.ads (Check_Record_Representation_Clause): New function.
850 2010-06-17 Robert Dewar <dewar@adacore.com>
852 * back_end.adb, sem_res.adb, switch-c.adb, sem_scil.adb: Minor
854 * sem_attr.adb, sem_cat.adb, sem_disp.adb, sem_elab.adb, sem_elim.adb,
855 sem_eval.adb: Use Ekind_In
857 2010-06-17 Ed Schonberg <schonberg@adacore.com>
859 * sem_ch8.adb: better error message for illegal inherited discriminant
861 2010-06-17 Vincent Celier <celier@adacore.com>
863 * bindusg.adb: Remove lines for -A and -C
864 * gnat_ugn.texi: Remove all documentation and examples of switches -A
865 and -C for gnatbind and gnatlink.
866 * gnatlink.adb (Usage): Remove lines for -A and -C
867 * switch-b.adb (Scan_Binder_Switches): Issue warning when switch -C is
869 * gcc-interface/Make-lang.in: Update dependencies.
871 2010-06-17 Vincent Celier <celier@adacore.com>
873 * back_end.adb (Scan_Compiler_Arguments): Put all arguments in new
874 local Argument_List variable Args.
875 * switch-c.adb (Scan_Front_End_Switches): New Argument_List argument
877 (Switch_Subsequently_Cancelled): New Argument_List argument Args. Look
878 for subsequent switches in Args.
879 * switch-c.ads (Scan_Front_End_Switches): New Argument_List argument
881 * gcc-interface/Make-lang.in: Update dependencies.
883 2010-06-17 Robert Dewar <dewar@adacore.com>
885 * einfo.adb: Minor code fix, allow E_Class_Wide_Type for
886 Equivalent_Type to match documentation.
888 2010-06-17 Robert Dewar <dewar@adacore.com>
890 * sem_ch6.adb, sem_ch7.adb: Minor reformatting.
891 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_ch10.adb, sem_ch12.adb,
892 sem_ch4.adb, sem_ch8.adb, sem_ch13.adb: Make use of Ekind_In.
894 2010-06-17 Thomas Quinot <quinot@adacore.com>
896 * sem_res.adb (Set_Slice_Subtype): Always freeze the slice's itype.
898 2010-06-17 Thomas Quinot <quinot@adacore.com>
900 * freeze.adb (Freeze_Expression): Short circuit operators are valid
901 freeze node insertion points.
903 2010-06-17 Robert Dewar <dewar@adacore.com>
905 * switch-c.ads, switch-c.adb, sem_ch13.adb: Minor reformatting.
906 * sem_ch12.adb: Add pragmas Assert and Check to previous change.
908 2010-06-17 Gary Dismukes <dismukes@adacore.com>
910 * layout.adb (Layout_Type): Broaden test for setting an array type's
911 Component_Size to include all scalar types, not just discrete types
912 (components of real types were missed).
913 * sem_ch3.adb (Constrain_Index): Add missing setting of First_Literal
914 on the itype created for an index (consistent with Make_Index and
915 avoids possible Assert_Failures).
917 2010-06-17 Robert Dewar <dewar@adacore.com>
919 * atree.ads, atree.adb: Add 6-parameter version of Ekind_In
920 * einfo.adb: Minor code reformatting (use Ekind_In)
922 2010-06-17 Robert Dewar <dewar@adacore.com>
924 * sem_warn.adb (Test_Ref): Abandon scan if access subprogram parameter
927 2010-06-17 Vincent Celier <celier@adacore.com>
929 * back_end.adb: Minor comment updates
930 * switch-c.adb: Remove dependencies on gcc C sources
931 * gcc-interface/Make-lang.in: Add a-comlin.o to the object file list
934 2010-06-17 Ed Schonberg <schonberg@adacore.com>
936 * sem_ch12.adb: propagate Pragma_Enabled flag to generic.
937 * get_scos.adb: Set C2 flag in decision entry of pragma to 'e' (enabled)
938 * par_sco.ads, par_sco.adb (Set_SCO_Pragma_Enabled): New procedure
939 Remove use of Node field in SCOs table
940 (Output_Header): Set 'd' to initially disable pragma entry
941 * put_scos.adb (Put_SCOs): New flag indicating if pragma is enabled
942 * scos.ads, scos.adb: Remove Node field from internal SCOs table.
943 Use C2 field of pragma decision header to indicate enabled.
944 * sem_prag.adb: Add calls to Set_SCO_Pragma_Enabled.
945 * gcc-interface/Make-lang.in: Update dependencies.
947 2010-06-17 Vincent Celier <celier@adacore.com>
949 * back_end.adb (Next_Arg): Moved to procedure Scan_Compiler_Arguments
950 (Scan_Compiler_Arguments): Call Scan_Front_End_Switches with Next_Arg
951 (Switch_Subsequently_Cancelled): Function moved to the body of Switch.C
952 * back_end.ads (Scan_Front_End_Switches): Function moved to the body of
954 * switch-c.adb: Copied a number of global declarations from back_end.adb
955 (Len_Arg): New function copied from back_end.adb
956 (Switch_Subsequently_Cancelled): New function moved from back_end.adb
957 (Scan_Front_End_Switches): New parameter Arg_Rank used to call
958 Switch_Subsequently_Cancelled.
959 * switch-c.ads (Scan_Front_End_Switches): New parameter Arg_Rank.
960 * gcc-interface/Makefile.in: Add line so that shared libgnat is linked
963 2010-06-17 Robert Dewar <dewar@adacore.com>
965 * prj.ads, prj.adb: Minor reformatting
967 2010-06-17 Thomas Quinot <quinot@adacore.com>
969 * put_scos.adb: Do not generate a blank line in SCOs when omitting the
970 CP line for a disabled pragma.
972 2010-06-17 Emmanuel Briot <briot@adacore.com>
974 * prj-proc.adb, prj.adb, prj.ads (Check_Or_Set_Typed_Variable): New
976 (Process_Declarative_Item): An invalid value in an typed variable
977 declaration is no longer always fatal.
979 2010-06-16 Arnaud Charlet <charlet@adacore.com>
981 * get_scos.adb, par_sco.adb, par_sco.ads, put_scos.adb, scos.adb,
982 scos.ads, exp_ch4.adb, sem_warn.adb: Code clean up, update
985 2010-06-16 Javier Miranda <miranda@adacore.com>
987 * exp_disp.adb (Expand_Dispatching_Call): Adjust the decoration of the
988 node referenced by the SCIL node of dispatching "=" to skip the tags
991 2010-06-16 Ed Schonberg <schonberg@adacore.com>
993 * sem_ch5.adb (Analyze_Exit_Statement): Return if no enclosing loop,
994 to prevent cascaded errors and compilation aborts.
996 2010-06-16 Robert Dewar <dewar@adacore.com>
998 * back_end.adb (Switch_Subsequently_Cancelled): New function
999 Move declarations to package body level to support this change
1000 * back_end.ads (Switch_Subsequently_Cancelled): New function
1001 * gnat_ugn.texi: Document -gnat-p switch
1002 * switch-c.adb (Scan_Front_End_Switches): Implement -gnat-p switch
1003 * ug_words: Add entry for -gnat-p (UNSUPPRESS_ALL)
1004 * usage.adb: Add line for -gnat-p switch
1005 * vms_data.ads: Add entry for UNSUPPRESS_ALL (-gnat-p)
1007 2010-06-16 Robert Dewar <dewar@adacore.com>
1009 * sem_warn.adb (Check_Infinite_Loop_Warning): Declaration counts as
1012 2010-06-16 Robert Dewar <dewar@adacore.com>
1014 * exp_disp.adb: Minor reformatting
1016 2010-06-16 Ed Schonberg <schonberg@adacore.com>
1018 * sem_ch3.adb (Complete_Private_Subtype): Inherit class_wide type from
1019 base type only if it was not previously created for the partial view.
1021 2010-06-16 Thomas Quinot <quinot@adacore.com>
1023 * tbuild.ads: Minor comment fix
1025 2010-06-15 Nathan Froyd <froydnj@codesourcery.com>
1027 * gcc-interface/trans.c (gnu_stack_free_list): Delete.
1028 (gnu_except_ptr_stack): Change type to VEC. Update comment.
1029 (gnu_elab_proc_stack): Likewise.
1030 (gnu_return_label_stack): Likewise.
1031 (gnu_loop_label_stack): Likewise.
1032 (gnu_switch_label_stack): Likewise.
1033 (gnu_constraint_label_stack): Likewise.
1034 (gnu_storage_error_label_stack): Likewise.
1035 (gnu_program_error_label_stack): Likewise.
1036 (push_exception_label_stack): Take a VEC ** instead of a tree *.
1037 (push_stack): Likewise. Remove unused second parameter. Update
1039 (pop_stack): Take a VEC * instead of a tree *. Update callers.
1040 (gigi): Initialize stacks as VECs.
1041 (Identifier_to_gnu): Use VEC_last instead of TREE_VALUE.
1042 (Case_Statement_to_gnu): Likewise.
1043 (Subprogram_Body_to_gnu): Likewise.
1044 (call_to_gnu): Likewise.
1045 (Exception_Handler_to_gnu_sjlj): Likewise.
1046 (gnat_to_gnu): Likewise.
1047 (get_exception_label): Likewise.
1049 2010-06-14 Ed Schonberg <schonberg@adacore.com>
1051 * sem_ch3.adb (Build_Derived_Record_Type): if derived type is an
1052 anonymous base generated when the parent is a constrained discriminated
1053 type, propagate interface list to first subtype because it may appear
1054 in a current instance within the extension part of the derived type
1055 declaration, and its own subtype declaration has not been elaborated
1057 * exp_disp.adb (Build_Interface_Thunk): Use base type of formal to
1058 determine whether it has the controlling type.
1060 2010-06-14 Jerome Lambourg <lambourg@adacore.com>
1062 * exp_ch11.adb (Expand_N_Raise_Statement): Make sure that the explicit
1063 raise of CE, SE and PE have the reason correctly set and are properly
1064 expanded before stopping the expansions of .NET/JVM exceptions.
1066 2010-06-14 Robert Dewar <dewar@adacore.com>
1068 * opt.ads (Check_Policy_List): Add some clarifying comments
1069 * sem_prag.adb (Analyze_Pragma, case Check): Set Pragma_Enabled flag
1070 on rewritten Assert pragma.
1072 2010-06-14 Gary Dismukes <dismukes@adacore.com>
1074 * sem_ch6.adb (Check_Overriding_Indicator): Add a special check for
1075 controlled operations, so that they will be treated as overriding even
1076 if the overridden subprogram is marked Is_Hidden, as long as the
1077 overridden subprogram's parent subprogram is not hidden.
1079 2010-06-14 Robert Dewar <dewar@adacore.com>
1081 * debug.adb: Entry for gnatw.d no longer specific for while loops
1082 * einfo.adb (First_Exit_Statement): New attribute for E_Loop
1083 * einfo.ads (First_Exit_Statement): New attribute for E_Loop
1084 * sem_ch5.adb (Analyze_Loop_Statement): Check_Infinite_Loop_Warning has
1085 new calling sequence to include test for EXIT WHEN.
1086 (Analyze_Exit_Statement): Chain EXIT statement into exit statement chain
1087 * sem_warn.ads, sem_warn.adb (Check_Infinite_Loop_Warning): Now handles
1089 * sinfo.adb (Next_Exit_Statement): New attribute of N_Exit_Statement
1091 * sinfo.ads (N_Pragma): Correct comment on Sloc field (points to
1092 PRAGMA, not to pragma identifier).
1093 (Next_Exit_Statement): New attribute of N_Exit_Statement node
1095 2010-06-14 Robert Dewar <dewar@adacore.com>
1097 * sem_res.adb (Resolve_Short_Circuit): Fix sloc of "assertion/check
1100 2010-06-14 Robert Dewar <dewar@adacore.com>
1102 * par-ch2.adb (Scan_Pragma_Argument_Association): Clarify message for
1103 missing pragma argument identifier.
1105 2010-06-14 Robert Dewar <dewar@adacore.com>
1107 * atree.ads, atree.adb (Ekind_In): New functions.
1109 2010-06-14 Robert Dewar <dewar@adacore.com>
1111 * exp_ch4.adb (Expand_N_Op_Expon): Optimize 2**N in stand alone context
1113 2010-06-14 Robert Dewar <dewar@adacore.com>
1115 * usage.adb (Usage): Redo documentation of -gnatwa.
1117 2010-06-14 Ed Schonberg <schonberg@adacore.com>
1119 * sem_ch8.adb (Find_Type): The attribute 'class cannot be applied to
1120 an untagged incomplete type that is a limited view.
1122 2010-06-14 Sergey Rybin <rybin@adacore.com>
1124 * gnat_ugn.texi: Add description of '-cargs gcc_switches' to gnatstub
1127 2010-06-14 Thomas Quinot <quinot@adacore.com>
1129 * exp_ch4.adb (Expand_Short_Circuit_Operator): New subprogram,
1130 factoring duplicated code between...
1131 (Expand_N_And_Than, Expand_N_Or_Else): Remove duplicated code.
1132 * a-envvar.ads: Minor reformatting
1134 2010-06-14 Arnaud Charlet <charlet@adacore.com>
1136 * ali.adb, ali.ads, lib-xref.ads: Document new '+' letter for C/C++
1138 (Scan_ALI): Take into account new Visibility field.
1139 (Visibility_Kind): New type.
1140 (Xref_Entity_Record): Replace Lib field by Visibility.
1142 * gcc-interface/Make-lang.in: Update dependencies.
1144 2010-06-14 Pascal Obry <obry@adacore.com>
1146 * raise.h: Remove unused defintions.
1148 2010-06-14 Bob Duff <duff@adacore.com>
1150 * par-ch10.adb (P_Subunit): If the next token after "separate(X)" is
1151 Tok_Not or Tok_Overriding, call P_Subprogram. We had previously given
1152 the incorrect error "proper body expected".
1153 * par-ch6.adb (P_Subprogram): Suppress "overriding indicator not
1154 allowed here" error in case of subunits, which was triggered by the
1155 above change to P_Subunit.
1157 2010-06-14 Sergey Rybin <rybin@adacore.com>
1159 * gnat_ugn.texi, vms_data.ads: Update gnatelim doc.
1161 2010-06-14 Thomas Quinot <quinot@adacore.com>
1163 * lib-util.adb: Minor code reorganization.
1165 2010-06-14 Robert Dewar <dewar@adacore.com>
1167 * ali.adb (Scan_ALI): Implement reading and storing of N lines
1168 (Known_ALI_Lines): Add entry for 'N' (notes)
1169 * ali.ads (Notes): New table to store Notes information
1170 * alloc.ads: Add entries for Notes table
1171 * lib-util.adb (Write_Info_Int): New procedure
1172 (Write_Info_Slit): New procedure
1173 (Write_Info_Uint): New procedure
1174 * lib-util.ads (Write_Info_Int): New procedure
1175 (Write_Info_Slit): New procedure
1176 (Write_Info_Uint): New procedure
1177 * lib-writ.adb (Write_Unit_Information): Output N (notes) lines
1178 * lib-writ.ads: Update documentation for N (Notes) lines
1179 * lib.adb (Store_Note): New procedure
1180 * lib.ads (Notes): New table
1181 (Store_Note): New procedure
1182 * sem_prag.adb: Call Store_Note for affected pragmas
1184 2010-06-14 Thomas Quinot <quinot@adacore.com>
1186 * socket.c: Fix wrong condition in #ifdef
1187 * g-socket.adb, g-sothco.ads: Functions imported from socket.c that
1188 take or return char* values can't use Interfaces.C.Strings.chars_ptr,
1189 because on VMS this type is a 32-bit pointer which is not compatible
1190 with the default for C pointers for code compiled with gcc on that
1193 2010-06-14 Ed Schonberg <schonberg@adacore.com>
1195 * sem_util (Is_VMS_Operator): New predicate to determine whether an
1196 operator is an intrinsic operator declared in the DEC system extension.
1197 * sem_res.adb (Resolve_Logical_Op): operation is legal on signed types
1198 if the operator is a VMS intrinsic.
1199 * sem_eval.adb (Eval_Logical_Op): Operation is legal and be
1200 constant-folded if the operands are signed and the operator is a VMS
1203 2010-06-14 Robert Dewar <dewar@adacore.com>
1205 * g-socket.adb, gnatcmd.adb: Minor reformatting.
1207 2010-06-14 Pascal Obry <obry@adacore.com>
1209 * s-finimp.adb: Fix typo.
1210 * raise.h: Remove duplicate blank line.
1212 2010-06-14 Vincent Celier <celier@adacore.com>
1214 * prj-nmsc.adb (Add_Sources): Always set the object file and the
1215 switches file names, as the configuration of the language may change
1216 in an extending project.
1217 (Process_Naming_Scheme): For sources of projects that are extended, set
1218 the configuration of the language from the highest extending project
1219 where the language is declared.
1221 2010-06-14 Gary Dismukes <dismukes@adacore.com>
1223 * sem_res.adb (Resolve_Call): For infinite recursion check, test
1224 whether the called subprogram is inherited from a containing subprogram.
1225 (Same_Or_Aliased_Subprograms): New function
1227 2010-06-14 Ed Schonberg <schonberg@adacore.com>
1229 * sem_ch8.adb (End_Use_Type): Before indicating that an operator is not
1230 use-visible, check whether it is a primitive for more than one type.
1232 2010-06-14 Robert Dewar <dewar@adacore.com>
1234 * sem_ch3.adb (Copy_And_Swap): Copy Has_Pragma_Unmodified flag.
1236 * sem_ch7.adb (Preserve_Full_Attributes): Preserve
1237 Has_Pragma_Unmodified flag.
1239 2010-06-14 Thomas Quinot <quinot@adacore.com>
1241 * g-sttsne-locking.adb, g-sttsne-locking.ads, g-sttsne.ads,
1242 g-sttsne-vxworks.adb, g-sttsne-dummy.ads: Removed. Mutual exclusion is
1243 now done in GNAT.Sockets if necessary.
1244 * gsocket.h, g-socket.adb, g-sothco.ads (GNAT.Sockets.Get_XXX_By_YYY):
1245 Ensure mutual exclusion for netdb operations if the target platform
1247 (GNAT.Sockets.Thin_Common): New binding for getXXXbyYYY, treating struct
1248 hostent as an opaque type to improve portability.
1249 * s-oscons-tmplt.c, socket.c: For the case of Vxworks, emulate
1250 gethostbyYYY using proprietary VxWorks API so that a uniform interface
1251 is available for the Ada side.
1252 * gcc-interface/Makefile.in: Remove g-sttsne-*
1253 * gcc-interface/Make-lang.in: Update dependencies.
1255 2010-06-14 Vincent Celier <celier@adacore.com>
1257 * gnatcmd.adb (Mapping_File): New function.
1259 2010-06-14 Javier Miranda <miranda@adacore.com>
1261 * sem_ch3.adb (Derive_Subprograms): Remove over-restrictive assertion.
1263 2010-06-14 Arnaud Charlet <charlet@adacore.com>
1265 * ali.adb: Fix typo.
1266 * s-auxdec-vms-alpha.adb, scng.ads: Minor reformatting.
1268 2010-06-14 Ed Schonberg <schonberg@adacore.com>
1270 * sem_ch12.adb: Make Mark_Context transitive, and apply to subprogram
1273 * sem_ch8.adb (Find_Expanded_Name): If a candidate compilation unit in
1274 the context does not have a homonym of the selector, emit default
1277 2010-06-14 Robert Dewar <dewar@adacore.com>
1279 * sem.adb, sem_ch12.adb, sem_util.adb: Minor reformatting and
1282 2010-06-14 Arnaud Charlet <charlet@adacore.com>
1284 * lib-xref.ads: Doc updates:
1285 - Allocate 'Q' for #include entity kind
1287 - Allocate 'g' for regular macros
1288 - Allocate 'G' for function-like macros
1290 2010-06-14 Ed Schonberg <schonberg@adacore.com>
1292 * sinfo.ads, sinfo.adb (Withed_Body): New attribute of a with_clause.
1293 Indicates that there is an instantiation in the current unit that
1294 loaded the body of the unit denoted by the with_clause.
1295 * sem_ch12.adb (Mark_Context): When instanting a generic body, check
1296 whether a with_clause in the current context denotes the unit that
1297 holds the generic declaration, and mark the with_clause accordingly.
1298 (Instantiate_Package_Body): call Mark_Context.
1299 * sem.adb (Process_Bodies_In_Context): Use Withed_Body to determine
1300 whether a given body should be traversed before the spec of the main
1303 2010-06-14 Ed Falis <falis@adacore.com>
1305 * sysdep.c: Fix 653 build against vThreads headers.
1307 2010-06-14 Robert Dewar <dewar@adacore.com>
1309 * sinfo.ads: Minor reformatting.
1311 2010-06-14 Ed Schonberg <schonberg@adacore.com>
1313 * sem_ch6.adb (Analyze_Subprogram_Body): Do not check conformance when
1314 the spec has been generated for a body without spec that carries an
1315 Inline_Always pragma.
1317 2010-06-14 Arnaud Charlet <charlet@adacore.com>
1319 * lib-xref.ads: Documentation change: allocate 'Z' letter to C/C++
1322 2010-06-14 Jerome Lambourg <lambourg@adacore.com>
1324 * exp_dbug.adb (Debug_Renaming_Declaration): Do not output any debug
1325 declaration for VMs, as those are useless and might lead to duplicated
1326 local variable names in the generated code.
1327 * gcc-interface/Make-lang.in: Update dependencies.
1329 2010-06-14 Robert Dewar <dewar@adacore.com>
1331 * opt.ads, sem.adb, sem_elab.adb: Minor reformatting
1333 2010-06-14 Robert Dewar <dewar@adacore.com>
1335 * exp_aggr.adb (Has_Address_Clause): Moved to Exp_Util, and there it
1336 is renamed as Has_Following_Address_Clause.
1337 * exp_ch3.adb (Needs_Simple_Initialization): Add Consider_IS argument
1338 to allow the caller to avoid Initialize_Scalars having an effect.
1339 (Expand_N_Object_Declaration): Do not do Initialize_Scalars stuff for
1340 scalars with an address clause specified.
1341 * exp_ch3.ads (Needs_Simple_Initialization): Add Consider_IS argument
1342 to allow the caller to avoid Initialize_Scalars having an effect.
1343 * exp_util.adb (Has_Following_Address_Clause): Moved here from Exp_Aggr
1344 (where it was called Has_Address_Clause).
1345 * exp_util.ads (Has_Following_Address_Clause): Moved here from Exp_Aggr
1346 (where it was called Has_Address_Clause).
1347 * freeze.adb (Warn_Overlay): Suppress message about overlaying causing
1348 problems for Initialize_Scalars (since we no longer initialize objects
1349 with an address clause.
1351 2010-06-14 Robert Dewar <dewar@adacore.com>
1353 * exp_prag.adb (Expand_Pragma_Check): Set Loc of generated code from
1356 2010-06-14 Gary Dismukes <dismukes@adacore.com>
1358 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Set Debug_Info_Needed
1359 on the entity of an implicitly generated postcondition procedure.
1361 2010-06-14 Thomas Quinot <quinot@adacore.com>
1363 * sem_ch7.adb (Preserve_Full_Attributes): Propagate
1364 Discriminant_Constraint elist from full view to private view.
1366 2010-06-14 Robert Dewar <dewar@adacore.com>
1368 * sem_res.adb: Minor reformatting.
1370 2010-06-14 Ed Schonberg <schonberg@adacore.com>
1372 * sem.adb: New version of unit traversal.
1374 * sem_elab.adb (Check_Internal_Call): Do not place a call appearing
1375 within a generic unit in the table of delayed calls.
1377 2010-06-14 Robert Dewar <dewar@adacore.com>
1379 * gnatcmd.adb, sem_util.adb, exp_ch3.adb: Minor reformatting
1381 2010-06-14 Ed Schonberg <schonberg@adacore.com>
1383 * sem_ch12.adb (Save_References): If an identifier has been rewritten
1384 during analysis as an explicit dereference, keep the reference implicit
1385 in the generic, but preserve the entity if global. This prevents
1386 malformed generic trees in the presence of some nested generics.
1388 2010-06-14 Sergey Rybin <rybin@adacore.com>
1390 * gnat_ugn.texi: For the GNAT driver, clarify the effect of calling the
1391 tool with '-files=' option. Also fix some small errors (wrong brackets)
1393 2010-06-14 Vincent Celier <celier@adacore.com>
1395 * gnatbind.adb: Call Scan_ALI with Directly_Scanned set to True for all
1396 the ALI files on the command line.
1398 * ali.adb (Scan_ALI): Set component Directly_Scanned of the unit(s) to
1399 the same value as the parameter of the same name.
1400 * ali.ads (Scan_ALI): New Boolean parameter Directly_Scanned, defaulted
1402 * bindgen.adb (Gen_Versions_Ada): Never emit version symbols for
1403 Stand-Alone Library interfaces. When binding Stand-Alone Libraries,
1404 emit version symbols only for the units of the library.
1405 (Gen_Versions_C): Ditto.
1407 2010-06-14 Gary Dismukes <dismukes@adacore.com>
1409 * sem_ch4.adb: Fix typo.
1411 2010-06-14 Vasiliy Fofanov <fofanov@adacore.com>
1413 * s-oscons-tmplt.c (IOV_MAX): redefine on Tru64 and VMS since the
1414 vector IO doesn't work at default value properly.
1416 2010-06-14 Doug Rupp <rupp@adacore.com>
1418 * s-stoele.adb: Remove unnecessary qualification of To_Address for VMS.
1420 2010-06-14 Vincent Celier <celier@adacore.com>
1422 * gnatcmd.adb (Check_Files): Do not invoke the tool with all the
1423 sources of the project if a switch -files= is used.
1425 2010-06-14 Thomas Quinot <quinot@adacore.com>
1427 * exp_attr.adb: Minor reformatting.
1429 2010-06-14 Gary Dismukes <dismukes@adacore.com>
1431 * gnat_ugn.texi: Minor typo fixes and wording changes.
1433 2010-06-14 Ed Schonberg <schonberg@adacore.com>
1435 * sem_ch4.adb (Analyze_One_Call): If the call has been rewritten from a
1436 prefixed form, do not re-analyze first actual, which may need an
1437 implicit dereference.
1438 * sem_ch6.adb (Analyze_Procedure_Call): If the call is given in
1439 prefixed notation, the analysis will rewrite the node, and possible
1440 errors appear in the rewritten name of the node.
1441 * sem_res.adb: If a call is ambiguous because its first parameter is
1442 an overloaded call, report list of candidates, to clarify ambiguity of
1445 2010-06-14 Doug Rupp <rupp@adacore.com>
1447 * s-auxdec-vms-alpha.adb: New package body implementing legacy
1448 VAX instructions with Asm insertions.
1449 * s-auxdec-vms_64.ads: Inline VAX queue functions
1450 * s-stoele.adb: Resolve some ambiguities in To_Addresss with s-suxdec
1451 that show up only on VMS.
1452 * gcc-interface/Makefile.in: Provide translation for
1453 s-auxdec-vms-alpha.adb.
1455 2010-06-14 Olivier Hainque <hainque@adacore.com>
1457 * initialize.c (VxWorks section): Update comments.
1459 2010-06-14 Robert Dewar <dewar@adacore.com>
1461 * a-convec.adb, sem_prag.adb, checks.adb: Minor reformatting.
1463 2010-06-14 Eric Botcazou <ebotcazou@adacore.com>
1465 * init.c: Code clean up.
1467 2010-06-14 Ed Schonberg <schonberg@adacore.com>
1469 * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case Address): Do
1470 not insert address clause in table for later validation if type of
1471 entity is generic, to prevent possible spurious errors.
1473 * sem_ch8.adb: Code clean up.
1475 2010-06-14 Ben Brosgol <brosgol@adacore.com>
1477 * gnat_ugn.texi: Expanded @ovar macro inline to solve problem with
1478 texi2pdf and texi2html.
1479 Document how to change scheduling properties on HP-UX.
1481 2010-06-14 Thomas Quinot <quinot@adacore.com>
1483 * g-socket.ads: Remove misleading comments.
1485 2010-06-14 Jerome Lambourg <lambourg@adacore.com>
1487 * sem_prag.adb (Check_Duplicated_Export_Name): Remove check for
1488 CLI_Target as this prevents proper detection of exported names
1489 duplicates when the exported language is different to CIL.
1490 (Process_Interface_Name): Add check for CIL convention exports,
1491 replacing the old one from Check_Duplicated_Export_Name.
1493 2010-06-14 Matthew Heaney <heaney@adacore.com>
1495 * a-coinve.adb, a-convec.adb (operator "&"): Check both that new length
1496 and new last satisfy constraints.
1497 (Delete_Last): prevent overflow for subtraction of index values
1498 (To_Vector): prevent overflow for addition of index values
1500 2010-06-14 Ed Schonberg <schonberg@adacore.com>
1502 * sem_ch4.adb (Complete_Object_Operation): After analyzing the
1503 rewritten call, preserve the resulting type to prevent spurious errors,
1504 when the call is implicitly dereferenced in the context of an in-out
1507 * checks.adb (Apply_Discriminant_Check): If the target of the
1508 assignment is a renaming of a heap object, create constrained type for
1511 2010-06-14 Pascal Obry <obry@adacore.com>
1513 * prj-proc.adb: Fix copy of object directory for extending projects.
1515 2010-06-14 Jose Ruiz <ruiz@adacore.com>
1517 * init.c (__gnat_alternate_stack): Define this space for PowerPC linux
1518 (__gnat_install_handler, PowerPC linux): Activate the alternative
1521 2010-06-13 Gerald Pfeifer <gerald@pfeifer.com>
1523 * gnat_rm.texi: Move to GFDL version 1.3.
1524 * gnat-style.texi: Ditto.
1525 * gnat_ugn.texi: Ditto.
1527 2010-06-12 Kai Tietz
1530 * gcc-interface/Makefile.in: Add rules for multilib x86/x64
1533 2010-06-11 Alexandre Oliva <aoliva@redhat.com>
1535 * gcc-interface/utils.c (update_pointer_to): Initialize last.
1537 2010-06-09 Eric Botcazou <ebotcazou@adacore.com>
1539 * gcc-interface/ada-tree.h: Fix formatting nits.
1541 2010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
1543 * gcc-interface/utils.c (init_gnat_to_gnu): Use typed GC
1545 (init_dummy_type): Likewise.
1546 (gnat_pushlevel): Likewise.
1548 * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
1549 (Subprogram_Body_to_gnu): Likewise.
1550 (Compilation_Unit_to_gnu): Likewise.
1551 (start_stmt_group): Likewise.
1552 (extract_encoding): Likewise.
1553 (decode_name): Likewise.
1555 * gcc-interface/misc.c (gnat_printable_name): Likewise.
1557 * gcc-interface/decl.c (annotate_value): Likewise.
1559 * gcc-interface/ada-tree.h (struct lang_type): Add variable_size
1561 (struct lang_decl): Likewise.
1562 (SET_TYPE_LANG_SPECIFIC): Use typed GC allocation.
1563 (SET_DECL_LANG_SPECIFIC): Likewise.
1565 2010-06-04 Eric Botcazou <ebotcazou@adacore.com>
1567 * gnatlink.adb (gnatlink): Remove support for -fsjlj switch.
1568 * gcc-interface/lang-specs.h: Likewise.
1570 2010-06-03 H.J. Lu <hongjiu.lu@intel.com>
1573 * gcc-interface/decl.c (MAX_FIXED_MODE_SIZE): Removed.
1575 2010-06-01 Arnaud Charlet <charlet@adacore.com>
1577 * gnat_ugn.texi: Improve doc on -fdump-ada-spec, mention limitations.
1579 2010-05-30 Eric Botcazou <ebotcazou@adacore.com>
1581 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Task_Type>: Reuse the
1582 TYPE_DECL of the equivalent type instead of building a new one.
1584 2010-05-30 Eric Botcazou <ebotcazou@adacore.com>
1586 * gcc-interface/decl.c (gnat_to_gnu_entity): Adjust warning message.
1587 Fix nits in comments.
1588 * gcc-interface/misc.c (gnat_init_gcc_eh): Likewise.
1589 * gcc-interface/trans.c (gigi): Likewise.
1590 (Attribute_to_gnu): Likewise.
1591 (Case_Statement_to_gnu): Likewise.
1592 (gnat_to_gnu): Adjust warning message.
1593 * gcc-interface/utils.c (create_var_decl_1): Fix nits in comments.
1594 (build_vms_descriptor32): Likewise.
1596 2010-05-27 Steven Bosscher <steven@gcc.gnu.org>
1598 * gcc-interface/decl.c: Pretend to be a backend file by undefining
1599 IN_GCC_FRONTEND (still need rtl.h here).
1601 2010-05-26 Steven Bosscher <steven@gcc.gnu.org>
1603 * gcc-interface/trans.c: Do not include rtl.h, insclude libfuncs.h.
1604 (gigi): Adjust call to set_stack_check_libfunc.
1606 2010-05-26 Steven Bosscher <steven@gcc.gnu.org>
1608 * gcc-interface/utils.c: Do not include rtl.h.
1610 2010-05-25 Steven Bosscher <steven@gcc.gnu.org>
1612 * gcc-interface/utils.c: Do not include function.h, pointer-set.h,
1613 and gimple.h. Explain why rtl.h has to be included.
1614 (handle_vector_size_attribute): Call reconstruct_complex_type directly.
1615 * gcc-interface/targtyps.c: Do not include tm_p.h
1616 * gcc-interface/utils2.c: Do not include flags.h.
1617 * gcc-interface/trans.c: Do not include expr.h. Include rtl.h instead,
1618 and explain why it has to be included.
1619 * gcc-interface/misc.c: Do not include expr.h, libfuncs.h, cgraph.h,
1621 Include function.h and explain why. Explain why except.h is included.
1622 (enumerate_modes): Remove unused function.
1623 * gcc-interface/gigi.h (enumerate_modes): Remove prototype.
1624 * gcc-interface/Make-lang.in: Update dependencies.
1626 2010-05-25 Joseph Myers <joseph@codesourcery.com>
1628 * gcc-interface/misc.c (internal_error_function): Add context
1629 parameter. Use it to access show_column flag and instead of using
1630 global_dc. Call warn_if_plugins.
1631 * gcc-interface/Make-lang.in (ada/misc.o): Update dependencies.
1633 2010-05-19 Eric Botcazou <ebotcazou@adacore.com>
1635 * gcc-interface/misc.c (LANG_HOOKS_DEEP_UNSHARING): Redefine.
1636 * gcc-interface/trans.c (unshare_save_expr): Delete.
1637 (gigi): Do not unshare trees under SAVE_EXPRs here.
1639 2010-05-18 Nathan Froyd <froydnj@codesourcery.com>
1641 * gcc-interface/trans.c (call_to_gnu): Use build_call_vec instead of
1643 * gcc-interface/utils.c (build_function_stub): Likewise.
1645 2010-05-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
1647 * gcc-interface/misc.c (gnat_handle_option): Remove special logic
1648 for Wuninitialized without -O.
1650 2010-05-16 Eric Botcazou <ebotcazou@adacore.com>
1652 * gcc-interface/gigi.h (enum standard_datatypes): Add new value
1653 ADT_exception_data_name_id.
1654 (exception_data_name_id): New define.
1655 * gcc-interface/trans.c (gigi): Initialize it.
1656 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Use the standard
1657 exception type for standard exception definitions. Do not make them
1659 <E_Record_Type>: Equate fields of types associated with an exception
1660 definition to those of the standard exception type.
1662 2010-05-13 Andreas Schwab <schwab@linux-m68k.org>
1664 * tracebak.c (__gnat_backtrace): Mark top_stack with ATTRIBUTE_UNUSED.
1666 2010-05-12 Eric Botcazou <ebotcazou@adacore.com>
1668 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Tidy up
1669 code, improve comments and fix formatting nits.
1671 2010-05-12 Eric Botcazou <ebotcazou@adacore.com>
1673 * gcc-interface/utils.c (update_pointer_to): Return early if the old
1674 pointer already points to the new type. Chain the old pointer and its
1675 variants at the end of new pointer's chain after updating them.
1677 2010-05-10 Eric Botcazou <ebotcazou@adacore.com>
1679 * exp_disp.adb (Make_Tags): Mark the imported view of dispatch tables
1680 built for interfaces.
1681 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Variable>: Use
1682 imported_p instead of Is_Imported when considering constants.
1683 Do not promote alignment of exported objects.
1684 <E_Record_Subtype>: Strip all suffixes for dispatch table entities.
1686 2010-05-08 Eric Botcazou <ebotcazou@adacore.com>
1688 * exp_disp.adb (Make_Tags): Mark the imported view of dispatch tables.
1689 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Variable>: Make imported
1690 constants really constant.
1691 <E_Record_Subtype>: Strip the suffix for dispatch table entities.
1693 2010-05-08 Eric Botcazou <ebotcazou@adacore.com>
1695 * gcc-interface/decl.c (make_aligning_type): Declare the type.
1697 2010-05-08 Eric Botcazou <ebotcazou@adacore.com>
1699 * gcc-interface/decl.c (gnat_to_gnu_entity): Create variables for size
1700 expressions of variant part of record types declared at library level.
1702 2010-05-08 Eric Botcazou <ebotcazou@adacore.com>
1704 * gcc-interface/gigi.h (create_field_decl): Move PACKED parameter.
1705 * gcc-interface/utils.c (create_field_decl): Move PACKED parameter.
1706 (rest_of_record_type_compilation): Adjust call to create_field_decl.
1707 (make_descriptor_field): Likewise and pass correctly typed constants.
1708 (build_unc_object_type): Likewise.
1709 (unchecked_convert): Likewise.
1710 * gcc-interface/decl.c (elaborate_expression_2): New static function.
1711 (gnat_to_gnu_entity): Use it to make alignment factors explicit.
1712 Adjust call to create_field_decl.
1713 (make_aligning_type): Likewise.
1714 (make_packable_type): Likewise.
1715 (maybe_pad_type): Likewise.
1716 (gnat_to_gnu_field): Likewise.
1717 (components_to_record): Likewise.
1718 (create_field_decl_from): Likewise.
1719 (create_variant_part_from): Remove superfluous test.
1720 * gcc-interface/trans.c (gigi): Adjust call to create_field_decl.
1722 2010-05-08 Eric Botcazou <ebotcazou@adacore.com>
1724 * gcc-interface/gigi.h (build_unc_object_type): Add DEBUG_INFO_P param.
1725 (build_unc_object_type_from_ptr): Likewise.
1726 * gcc-interface/utils.c (build_unc_object_type): Add DEBUG_INFO_P param
1727 and pass it to create_type_decl. Declare the type. Simplify.
1728 (build_unc_object_type_from_ptr): Add DEBUG_INFO_P parameter and pass
1729 it to build_unc_object_type.
1730 * gcc-interface/decl.c (gnat_to_gnu_entity): Adjust to above change.
1731 * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
1732 (gnat_to_gnu): Likewise.
1733 * gcc-interface/utils2.c (build_allocator): Likewise.
1735 2010-05-07 Eric Botcazou <ebotcazou@adacore.com>
1738 * gcc-interface/misc.c (gnat_handle_option): Fix long line.
1740 2010-05-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1742 * gcc-interface/Makefile.in: Removed mips-sgi-irix5* support.
1744 2010-05-06 Manuel López-Ibáñez <manu@gcc.gnu.org>
1747 * gcc-interface/misc.c (gnat_handle_option): Add argument kind.
1749 2010-05-02 Giuseppe Scrivano <gscrivano@gnu.org>
1751 * gnathtml.pl: Use 755 as mask for new directories.
1753 2010-04-28 Eric Botcazou <ebotcazou@adacore.com>
1755 * gcc-interface/trans.c (gnat_gimplify_expr) <ADDR_EXPR>: Uniquize
1756 constant constructors before taking their address.
1758 2010-04-25 Eric Botcazou <ebotcazou@adacore.com>
1760 * exp_dbug.ads: Fix outdated description. Mention link between XVS
1762 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Subtype>: Set
1763 XVZ variable as unit size of XVS type.
1764 (maybe_pad_type): Likewise.
1766 2010-04-25 Eric Botcazou <ebotcazou@adacore.com>
1768 * gcc-interface/trans.c (gnat_to_gnu) <N_Assignment_Statement>: Do not
1769 use memmove if the array type is bit-packed.
1771 2010-04-18 Eric Botcazou <ebotcazou@adacore.com>
1773 * gcc-interface/misc.c (gnat_init): Remove second argument in call to
1774 build_common_tree_nodes.
1776 2010-04-18 Ozkan Sezer <sezeroz@gmail.com>
1778 * gsocket.h: Make sure that winsock2.h is included before windows.h.
1780 2010-04-17 Eric Botcazou <ebotcazou@adacore.com>
1782 * gcc-interface/utils2.c (build_unary_op) <ATTR_ADDR_EXPR>: Do not
1785 2010-04-17 Eric Botcazou <ebotcazou@adacore.com>
1787 * uintp.h (UI_Lt): Declare.
1788 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do the size
1789 computation in sizetype.
1790 <E_Array_Subtype>: Use unified handling for all index types. Do not
1791 generate MAX_EXPR-based expressions, only COND_EXPR-based ones. Add
1793 (annotate_value): Change test for negative values.
1794 (validate_size): Apply test for negative values on GNAT nodes.
1795 (set_rm_size): Likewise.
1796 * gcc-interface/misc.c (gnat_init): Set unsigned types for sizetypes.
1797 * gcc-interface/utils.c (rest_of_record_type_compilation): Change test
1798 for negative values.
1799 (max_size) <MINUS_EXPR>: Do not reassociate a COND_EXPR on the LHS.
1800 (builtin_type_for_size): Adjust definition of signed_size_type_node.
1801 * gcc-interface/utils2.c (compare_arrays): Optimize comparison of
1802 lengths against zero.
1804 2010-04-17 Eric Botcazou <ebotcazou@adacore.com>
1806 * back-end.adb (Call_Back_End): Pass Standard_Character to gigi.
1807 * gcc-interface/gigi.h (gigi): Add standard_character parameter.
1808 (CHAR_TYPE_SIZE, SHORT_TYPE_SIZE, INT_TYPE_SIZE, LONG_TYPE_SIZE,
1809 LONG_LONG_TYPE_SIZE, FLOAT_TYPE_SIZE, DOUBLE_TYPE_SIZE,
1810 LONG_DOUBLE_TYPE_SIZE, SIZE_TYPE): Delete.
1811 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Subtype>: Call
1813 * gcc-interface/misc.c (gnat_init): Set signedness of char as per
1814 flag_signed_char. Tag sizetype with "size_type" moniker.
1815 * gcc-interface/trans.c (gigi): Add standard_character parameter.
1816 Remove useless built-in types. Equate unsigned_char_type_node to
1817 Standard.Character. Use it instead of char_type_node throughout.
1818 (Attribute_to_gnu): Likewise.
1819 (gnat_to_gnu): Likewise.
1820 * gcc-interface/utils2.c (build_call_raise): Likewise.
1822 2010-04-17 Eric Botcazou <ebotcazou@adacore.com>
1824 * gcc-interface/gigi.h (enum standard_datatypes): Add new values
1825 ADT_sbitsize_one_node and ADT_sbitsize_unit_node.
1826 (sbitsize_one_node): New macro.
1827 (sbitsize_unit_node): Likewise.
1828 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Subtype>: Fix
1829 latent bug in the computation of subrange_p. Fold wider_p predicate.
1830 (cannot_be_superflat_p): Use an explicitly signed 64-bit type to do
1831 the final comparison.
1832 (make_aligning_type): Build real negation and use sizetype throughout
1833 the offset computation.
1834 (maybe_pad_type): Do not issue the warning when the new size expression
1836 (annotate_value) <INTEGER_CST>: Simplify code handling negative values.
1837 * gcc-interface/misc.c (gnat_init): Initialize sbitsize_one_node and
1839 * gcc-interface/trans.c (Attribute_to_gnu) <Attr_Pool_Address>: Fold
1841 (gnat_to_gnu) <N_Free_Statement>: Likewise.
1842 * gcc-interface/utils.c (convert): Use sbitsize_unit_node.
1843 * gcc-interface/utils2.c (compare_arrays): Compute real lengths and use
1844 constants in sizetype. Remove dead code and tweak comments. Generate
1845 equality instead of inequality comparisons for zero length tests.
1847 2010-04-16 Eric Botcazou <ebotcazou@adacore.com>
1849 * gcc-interface/gigi.h (gnat_init_decl_processing): Delete.
1850 * gcc-interface/decl.c (gnat_to_gnu_entity): Constify a few variables.
1851 <object>: Do not create the fake PARM_DECL if no debug info is needed.
1852 Do not create the corresponding VAR_DECL of a CONST_DECL for debugging
1853 purposes if no debug info is needed.
1854 Fix formatting. Reorder and add comments.
1855 * gcc-interface/trans.c (gnat_to_gnu) <N_Attribute_Reference>: Constify
1856 variable and remove obsolete comment.
1857 * gcc-interface/utils.c (convert_vms_descriptor64): Tweak comment.
1858 (convert_vms_descriptor32): Likewise.
1859 (convert): Remove dead code.
1860 <UNCONSTRAINED_ARRAY_REF>: Pass the field instead of its name to build
1861 the reference to the P_ARRAY pointer.
1862 <POINTER_TYPE>: Likewise.
1863 (maybe_unconstrained_array) <UNCONSTRAINED_ARRAY_TYPE>: Likewise.
1864 (gnat_init_decl_processing): Delete, move contents to...
1865 * gcc-interface/misc.c (gnat_init): ...here.
1867 2010-04-16 Eric Botcazou <ebotcazou@adacore.com>
1869 * gcc-interface/trans.c (unchecked_conversion_nop): Handle function
1870 calls. Return true for conversion from a record subtype to its type.
1872 2010-04-16 Eric Botcazou <ebotcazou@adacore.com>
1874 * gcc-interface/decl.c (gnat_to_gnu_entity): Use boolean_type_node in
1875 lieu of integer_type_node for boolean operations.
1876 (choices_to_gnu): Likewise.
1877 * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
1878 (Loop_Statement_to_gnu): Likewise.
1879 (establish_gnat_vms_condition_handler): Likewise.
1880 (Exception_Handler_to_gnu_sjlj): Likewise.
1881 (gnat_to_gnu): Likewise.
1882 (build_unary_op_trapv): Likewise.
1883 (build_binary_op_trapv): Likewise.
1884 (emit_range_check): Likewise.
1885 (emit_index_check): Likewise.
1886 (convert_with_check): Likewise.
1887 * gcc-interface/utils.c (convert_vms_descriptor64): Likewise.
1888 (convert_vms_descriptor32): Likewise.
1889 (convert_vms_descriptor): Likewise.
1890 * gcc-interface/utils2.c (nonbinary_modular_operation): Likewise.
1891 (compare_arrays): Use boolean instead of integer constants.
1892 (build_binary_op) <TRUTH_ANDIF_EXPR, TRUTH_ORIF_EXPR, TRUTH_AND_EXPR,
1893 TRUTH_OR_EXPR, TRUTH_XOR_EXPR>: New case. Check that the result type
1895 <GE_EXPR, LE_EXPR, GT_EXPR, LT_EXPR>: Remove obsolete assertion.
1896 <EQ_EXPR, NE_EXPR>: Check that the result type is a boolean type.
1897 <PREINC/PREDECREMENT_EXPR, POSTINC/POSTDECREMENT_EXPR>: Delete.
1898 <TRUTH_NOT_EXPR>: Check that the result type is a boolean type.
1899 (build_unary_op): Use boolean_type_node in lieu of integer_type_node
1900 for boolean operations.
1901 (fill_vms_descriptor): Likewise. Fix formatting nits.
1903 2010-04-16 Eric Botcazou <ebotcazou@adacore.com>
1905 * gcc-interface/ada-tree.def (LOOP_STMT): Change to 4-operand nodes.
1906 * gcc-interface/ada-tree.h (LOOP_STMT_TOP_COND, LOOP_STMT_BOT_COND):
1908 (LOOP_STMT_COND): ...this.
1909 (LOOP_STMT_BOTTOM_COND_P): New flag.
1910 (LOOP_STMT_TOP_UPDATE_P): Likewise.
1911 * gcc-interface/trans.c (can_equal_min_or_max_val_p): New function.
1912 (can_equal_min_val_p): New static inline function.
1913 (can_equal_max_val_p): Likewise.
1914 (Loop_Statement_to_gnu): Use build4 in lieu of build5 and adjust to
1915 new LOOP_STMT semantics. Use two different strategies depending on
1916 whether optimization is enabled to translate the loop.
1917 (gnat_gimplify_stmt) <LOOP_STMT>: Adjust to new LOOP_STMT semantics.
1919 2010-04-16 Eric Botcazou <ebotcazou@adacore.com>
1921 * uintp.adb (UI_From_Dint): Remove useless code.
1922 (UI_From_Int): Likewise.
1923 * uintp.h: Reorder declarations.
1924 (UI_From_gnu): Declare.
1925 (UI_Base): Likewise.
1926 (Vector_Template): Likewise.
1927 (Vector_To_Uint): Likewise.
1930 * gcc-interface/gigi.h: Tweak comments.
1931 * gcc-interface/cuintp.c (UI_From_gnu): New global function.
1932 * gcc-interface/decl.c (maybe_pad_type): Do not warn if either size
1934 (annotate_value) <INTEGER_CST>: Call UI_From_gnu.
1935 * gcc-interface/trans.c (post_error_ne_num): Call post_error_ne.
1936 (post_error_ne_tree): Call UI_From_gnu and post_error_ne.
1937 * gcc-interface/utils.c (max_size) <tcc_binary>: Do not special-case
1940 2010-04-16 Eric Botcazou <ebotcazou@adacore.com>
1942 * gcc-interface/decl.c (make_type_from_size) <INTEGER_TYPE>: Just copy
1944 * gcc-interface/trans.c (smaller_packable_type_p): Rename into...
1945 (smaller_form_type_p): ...this. Change parameter and variable names.
1946 (call_to_gnu): Use the nominal type of the parameter to create the
1947 temporary if it's a smaller form of the actual type.
1948 (addressable_p): Return false if the actual type is integral and its
1949 size is greater than that of the expected type.
1951 2010-04-15 Eric Botcazou <ebotcazou@adacore.com>
1953 * gcc-interface/cuintp.c (UI_To_gnu): Fix long line.
1954 * gcc-interface/gigi.h (MARK_VISITED): Skip objects of constant class.
1955 (process_attributes): Delete.
1956 (post_error_ne_num): Change parameter name.
1957 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force debug info
1958 with -g3. Remove a couple of obsolete lines. Minor tweaks.
1959 If type annotating mode, operate on trees to compute the adjustment to
1960 the sizes of tagged types. Fix long line.
1961 (cannot_be_superflat_p): Tweak head comment.
1962 (annotate_value): Fold local constant.
1963 (set_rm_size): Fix long line.
1964 * gcc-interface/trans.c (Identifier_to_gnu): Rework comments.
1965 (Attribute_to_gnu): Fix long line.
1966 <Attr_Size>: Remove useless assertion.
1967 Reorder statements. Use size_binop routine.
1968 (Loop_Statement_to_gnu): Use build5 in lieu of build_nt.
1969 Create local variables for the label and the test. Tweak comments.
1970 (Subprogram_Body_to_gnu): Reset cfun to NULL.
1971 (Compilation_Unit_to_gnu): Use the Sloc of the Unit node.
1972 (process_inlined_subprograms): Integrate into...
1973 (Compilation_Unit_to_gnu): ...this.
1974 (gnat_to_gnu): Fix long line.
1975 (post_error_ne_num): Change parameter name.
1976 * gcc-interface/utils.c (process_attributes): Static-ify.
1977 <ATTR_MACHINE_ATTRIBUTE>: Set input_location before proceeding.
1978 (create_type_decl): Add comment.
1979 (create_var_decl_1): Process the attributes after adding the VAR_DECL
1980 to the current binding level.
1981 (create_subprog_decl): Likewise for the FUNCTION_DECL.
1982 (end_subprog_body): Do not reset cfun to NULL.
1983 (build_vms_descriptor32): Fix long line.
1984 (build_vms_descriptor): Likewise.
1985 (handle_nonnull_attribute): Likewise.
1986 (convert_vms_descriptor64): Likewise.
1987 * gcc-interface/utils2.c (fill_vms_descriptor): Fix long line.
1988 (gnat_protect_expr): Fix thinko.
1990 2010-04-15 Eric Botcazou <ebotcazou@adacore.com>
1992 * gcc-interface/trans.c (gigi): Set DECL_IGNORED_P on EH functions.
1993 (gnat_to_gnu) <N_Op_Eq>: Restore the value of input_location
1994 before translating the top-level node.
1995 (lvalue_required_p) <N_Function_Call>: Return 1 if !constant.
1996 <N_Object_Declaration>: Likewise.
1997 <N_Assignment_Statement>: Likewise.
1998 <N_Unchecked_Type_Conversion>: Likewise.
1999 (call_to_gnu): Remove kludge.
2000 (gnat_to_gnu) <N_Return_Statement>: When not optimizing, force labels
2001 associated with user returns to be preserved.
2002 (gnat_to_gnu): Add special code to deal with boolean rvalues.
2003 * gcc-interface/utils2.c (compare_arrays): Set input_location on all
2005 (build_unary_op) <ADDR_EXPR>: Call build_fold_addr_expr.
2006 <INDIRECT_REF>: Call build_fold_indirect_ref.
2008 2010-04-15 Joel Sherrill <joel.sherrill@oarcorp.com>
2010 * g-socket.adb: A target can have multiple missing errno's. This
2011 will result in multiple errno's being defined as -1. Because of this
2012 we can not use a case but must use a series of if's to avoid
2013 a duplicate case error in GNAT.Sockets.Resolve_Error.
2015 2010-04-15 Eric Botcazou <ebotcazou@adacore.com>
2017 * gcc-interface/trans.c (call_to_gnu): Open a nesting level if this is
2018 a statement. Otherwise, if at top-level, push the processing of the
2019 elaboration routine. In the misaligned case, issue the error messages
2020 again on entry and create the temporary explicitly. Do not issue them
2022 For a function call, emit the range check if necessary.
2023 In the copy-in copy-out case, create the temporary for the return
2025 Do not unnecessarily convert by-ref parameters to the formal's type.
2026 Remove obsolete guards in conditions.
2027 (gnat_to_gnu) <N_Assignment_Statement>: For a function call, pass the
2028 target to call_to_gnu in all cases.
2029 (gnat_gimplify_expr) <ADDR_EXPR>: Remove handling of SAVE_EXPR.
2030 (addressable_p) <CONSTRUCTOR>: Return false if not static.
2031 <COMPOUND_EXPR>: New case.
2032 * gcc-interface/utils2.c (build_unary_op) <ADDR_EXPR>: Fold a compound
2033 expression if it has unconstrained array type.
2034 (gnat_mark_addressable) <COMPOUND_EXPR>: New case.
2035 (gnat_stabilize_reference) <COMPOUND_EXPR>: Stabilize operands on an
2038 2010-04-15 Eric Botcazou <ebotcazou@adacore.com>
2040 * gcc-interface/trans.c (gigi): Do not start statement group.
2041 (Compilation_Unit_to_gnu): Set current_function_decl to NULL.
2042 Start statement group and push binding level here...
2043 (gnat_to_gnu) <N_Compilation_Unit>: ...and not here.
2044 Do not push fake contexts at top level. Remove redundant code.
2045 (call_to_gnu): Rename a local variable and constify another.
2046 * gcc-interface/utils.c (gnat_pushlevel): Fix formatting nits.
2047 (set_current_block_context): Set it as the group's block.
2048 (gnat_init_decl_processing): Delete unrelated init code.
2049 (end_subprog_body): Use NULL_TREE.
2051 2010-04-15 Eric Botcazou <ebotcazou@adacore.com>
2053 * gcc-interface/trans.c (call_to_gnu): Do not unnecessarily force
2054 side-effects of actual parameters before the call.
2056 2010-04-15 Eric Botcazou <ebotcazou@adacore.com>
2058 * gcc-interface/decl.c (validate_size): Reorder, remove obsolete test
2060 (set_rm_size): Reorder and remove obsolete test.
2062 2010-04-14 Eric Botcazou <ebotcazou@adacore.com>
2064 * gcc-interface/gigi.h: Reorder declarations and tweak comments.
2065 (gigi): Adjust ATTRIBUTE_UNUSED markers.
2066 * gcc-interface/gadaint.h: New file.
2067 * gcc-interface/trans.c: Include it in lieu of adaint.h. Reorder.
2068 (__gnat_to_canonical_file_spec): Remove declaration.
2069 (number_names): Delete.
2070 (number_files): Likewise.
2072 * gcc-interface/Make-lang.in (ada/trans.o): Adjust dependencies to
2075 2010-04-14 Eric Botcazou <ebotcazou@adacore.com>
2077 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Class_Wide_Type>: Fix
2079 * gcc-interface/trans.c (process_freeze_entity): Use local copy of
2080 Ekind. Return early for class-wide types. Do not compute initializer
2081 unless necessary. Reuse the tree for an associated class-wide type
2082 only if processing its root type.
2084 2010-04-13 Joel Sherrill <joel.sherrill@oarcorp.com>
2086 * gsocket.h: Run-time can no longer be built without network
2087 OS headers available. Changing RTEMS GNAT build procedure to
2088 reflect this and letting run-time build use network .h files.
2090 2010-04-13 Duncan Sands <baldrick@free.fr>
2092 * gcc-interface/misc.c (gnat_eh_type_covers): Remove.
2093 * gcc-interface/trans.c (Exception_Handler_to_gnu_zcx): Update comment.
2095 2010-04-13 Eric Botcazou <ebotcazou@adacore.com>
2097 * gcc-interface/gigi.h (standard_datatypes): Add ADT_parent_name_id.
2098 (parent_name_id): New macro.
2099 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Type>: Use it.
2100 * gcc-interface/trans.c (gigi): Initialize it.
2101 (lvalue_required_p) <N_Type_Conversion>: New case.
2102 <N_Qualified_Expression>: Likewise.
2103 <N_Allocator>: Likewise.
2104 * gcc-interface/utils.c (convert): Try to properly upcast tagged types.
2106 2010-04-13 Eric Botcazou <ebotcazou@adacore.com>
2108 * gcc-interface/ada-tree.h (TYPE_BY_REFERENCE_P): Delete.
2109 (DECL_CONST_ADDRESS_P): New macro.
2110 (SET_DECL_ORIGINAL_FIELD_TO_FIELD): Likewise.
2111 (SAME_FIELD_P): Likewise.
2112 * gcc-interface/decl.c (constructor_address_p): New static function.
2113 (gnat_to_gnu_entity) <object>: Set DECL_CONST_ADDRESS_P according to
2114 the return value of above function.
2115 (gnat_to_gnu_entity) <E_Record_Type>: Force BLKmode for all types
2116 passed by reference.
2117 <E_Record_Subtype>: Likewise.
2118 Set TREE_ADDRESSABLE on the type if it passed by reference.
2119 (make_packable_type): Use SET_DECL_ORIGINAL_FIELD_TO_FIELD.
2120 (create_field_decl_from): Likewise.
2121 (substitute_in_type): Likewise.
2122 (purpose_member_field): Use SAME_FIELD_P.
2123 * gcc-interface/misc.c (must_pass_by_ref): Test TREE_ADDRESSABLE.
2124 * gcc-interface/trans.c (lvalue_required_p): Add ADDRESS_OF_CONSTANT
2125 parameter and adjust recursive calls.
2126 <N_Explicit_Dereference>: New case.
2127 <N_Object_Declaration>: Return 1 if the object is of a class-wide type.
2128 Adjust calls to lvalue_required_p. Do not return the initializer of a
2129 DECL_CONST_ADDRESS_P constant if an lvalue is required for it.
2130 (call_to_gnu): Delay issuing error message for a misaligned actual and
2131 avoid the associated back-end assertion. Test TREE_ADDRESSABLE.
2132 (gnat_gimplify_expr) <ADDR_EXPR>: Handle non-static constructors.
2133 * gcc-interface/utils.c (make_dummy_type): Set TREE_ADDRESSABLE if the
2134 type is passed by reference.
2135 (convert) <CONSTRUCTOR>: Convert in-place in more cases.
2136 * gcc-interface/utils2.c (build_cond_expr): Drop TYPE_BY_REFERENCE_P.
2137 (build_simple_component_ref): Use SAME_FIELD_P.
2139 2010-04-12 Eric Botcazou <ebotcazou@adacore.com>
2141 * gcc-interface/trans.c (Identifier_to_gnu): Use boolean variable.
2142 (call_to_gnu): Test gigi's flag TYPE_BY_REFERENCE_P instead of calling
2143 front-end's predicate Is_By_Reference_Type. Use consistent order and
2144 remove ??? comment. Use original conversion in all cases, if any.
2145 * gcc-interface/utils.c (make_dummy_type): Minor tweak.
2146 (convert): Use local copy in more cases.
2147 <INDIRECT_REF>: Remove deactivated code.
2148 (unchecked_convert): Use a couple of local copies.
2150 2010-04-11 Eric Botcazou <ebotcazou@adacore.com>
2152 * gcc-interface/trans.c (lvalue_required_for_attribute_p): New static
2154 (lvalue_required_p) <N_Attribute_Reference>: Call it.
2155 (gnat_to_gnu) <N_Selected_Component>: Prevent build_component_ref from
2156 folding the result only if lvalue_required_for_attribute_p is true.
2157 * gcc-interface/utils.c (maybe_unconstrained_array): Pass correctly
2158 typed constant to build_component_ref.
2159 (unchecked_convert): Likewise.
2160 * gcc-interface/utils2.c (maybe_wrap_malloc): Likewise.
2161 (build_allocator): Likewise.
2163 2010-04-11 Eric Botcazou <ebotcazou@adacore.com>
2165 * gcc-interface/utils2.c (build_cond_expr): Take the address and
2166 dereference if the result type is passed by reference.
2168 2010-04-11 Eric Botcazou <ebotcazou@adacore.com>
2170 * gcc-interface/trans.c (Case_Statement_to_gnu): Bool-ify variable.
2171 (gnat_to_gnu) <N_Null_Statement>: When not optimizing, generate a
2172 goto to the next statement.
2174 2010-04-09 Eric Botcazou <ebotcazou@adacore.com>
2176 * gcc-interface/gigi.h (maybe_variable): Delete.
2177 (protect_multiple_eval): Likewise.
2178 (maybe_stabilize_reference): Likewise.
2179 (gnat_save_expr): Declare.
2180 (gnat_protect_expr): Likewise.
2181 (gnat_stabilize_reference): Likewise.
2182 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Use
2183 gnat_stabilize_reference.
2184 (maybe_variable): Delete.
2185 (elaborate_expression_1): Use gnat_save_expr.
2186 * gcc-interface/trans.c (Attribute_to_gnu): Use gnat_protect_expr.
2187 (call_to_gnu): Pass NULL to gnat_stabilize_reference.
2188 (gnat_to_gnu) <N_Object_Declaration>: Use gnat_save_expr.
2189 <N_Slice>: Use gnat_protect_exp.
2190 <N_Selected_Component>: Pass NULL to gnat_stabilize_reference.
2191 <N_In>: Use gnat_protect_expr.
2192 Pass NULL to gnat_stabilize_reference.
2193 (build_unary_op_trapv): Use gnat_protect_expr.
2194 (build_binary_op_trapv): Likewise.
2195 (emit_range_check): Likewise.
2196 (emit_index_check): Likewise.
2197 (convert_with_check): Likewise.
2198 (protect_multiple_eval): Move to utils2.c file.
2199 (maybe_stabilize_reference): Merge into...
2200 (gnat_stabilize_reference): ...this. Move to utils2.c file.
2201 (gnat_stabilize_reference_1): Likewise.
2202 * gcc-interface/utils.c (convert_to_fat_pointer): Use gnat_protect_expr
2203 instead of protect_multiple_eval.
2204 * gcc-interface/utils2.c (compare_arrays): Likewise.
2205 (nonbinary_modular_operation): Likewise.
2206 (maybe_wrap_malloc): Likewise.
2207 (build_allocator): Likewise.
2208 (gnat_save_expr): New function.
2209 (gnat_protect_expr): Rename from protect_multiple_eval. Early return
2210 in common cases. Propagate TREE_READONLY onto dereferences.
2211 (gnat_stabilize_reference_1): Move from trans.c file.
2212 (gnat_stabilize_reference): Likewise.
2214 2010-04-09 Eric Botcazou <ebotcazou@adacore.com>
2216 * gcc-interface/gigi.h (gnat_mark_addressable): Rename parameter.
2217 * gcc-interface/decl.c (maybe_variable): Do not set TREE_STATIC on _REF
2218 node. Use the type of the operand to set TREE_READONLY.
2219 * gcc-interface/trans.c (Identifier_to_gnu): Do not set TREE_STATIC on
2220 _REF node. Do not overwrite TREE_READONLY.
2221 (call_to_gnu): Rename local variable and fix various nits. In the
2222 copy-in/copy-out case, build the SAVE_EXPR manually.
2223 (convert_with_check): Call protect_multiple_eval in lieu of save_expr
2224 and fold the computations.
2225 (protect_multiple_eval): Always save entire fat pointers.
2226 (maybe_stabilize_reference): Minor tweaks.
2227 (gnat_stabilize_reference_1): Likewise. Do not deal with tcc_constant,
2228 tcc_type and tcc_statement.
2229 * gcc-interface/utils.c (convert_to_fat_pointer): Call
2230 protect_multiple_eval in lieu of save_expr.
2231 (convert): Minor tweaks.
2232 (maybe_unconstrained_array): Do not set TREE_STATIC on _REF node.
2233 (builtin_type_for_size): Call gnat_type_for_size directly.
2234 * gcc-interface/utils2.c (contains_save_expr_p): Delete.
2235 (contains_null_expr): Likewise
2236 (gnat_build_constructor): Do not call it.
2237 (compare_arrays): Deal with all side-effects, use protect_multiple_eval
2238 instead of gnat_stabilize_reference to protect the operands.
2239 (nonbinary_modular_operation): Call protect_multiple_eval in lieu of
2241 (maybe_wrap_malloc): Likewise.
2242 (build_allocator): Likewise.
2243 (build_unary_op) <INDIRECT_REF>: Do not set TREE_STATIC on _REF node.
2244 (gnat_mark_addressable): Rename parameter.
2246 2010-04-08 Eric Botcazou <ebotcazou@adacore.com>
2248 * gcc-interface/ada-tree.h (TYPE_RETURNS_UNCONSTRAINED_P): Rename into.
2249 (TYPE_RETURN_UNCONSTRAINED_P): ...this.
2250 (TYPE_RETURNS_BY_REF_P): Rename into.
2251 (TYPE_RETURN_BY_DIRECT_REF_P): ...this.
2252 (TYPE_RETURNS_BY_TARGET_PTR_P): Delete.
2253 * gcc-interface/gigi.h (create_subprog_type): Adjust parameter names.
2254 (build_return_expr): Likewise.
2255 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>:
2256 Rename local variables. If the return Mechanism is By_Reference, pass
2257 return_by_invisible_ref_p to create_subprog_type instead of toggling
2258 TREE_ADDRESSABLE. Test return_by_invisible_ref_p in order to annotate
2259 the mechanism. Use regular return for contrained types with non-static
2260 size and return by invisible reference for unconstrained return types
2261 with default discriminants. Update comment.
2262 * gcc-interface/trans.c (Subprogram_Body_to_gnu): If the function
2263 returns by invisible reference, turn the RESULT_DECL into a pointer.
2264 Do not handle DECL_BY_REF_P in the CICO case here.
2265 (call_to_gnu): Remove code handling return by target pointer. For a
2266 function call, if the return type has non-constant size, generate the
2267 assignment with an INIT_EXPR.
2268 (gnat_to_gnu) <N_Return_Statement>: Remove dead code in the CICO case.
2269 If the function returns by invisible reference, build the copy return
2271 (add_decl_expr): Initialize the variable with an INIT_EXPR.
2272 * gcc-interface/utils.c (create_subprog_type): Adjust parameter names.
2273 Adjust for renaming of macros. Copy the node only when necessary.
2274 (create_subprog_decl): Do not toggle TREE_ADDRESSABLE on the return
2275 type, only change DECL_BY_REFERENCE on the RETURN_DECL.
2276 (convert_from_reference): Delete.
2277 (is_byref_result): Likewise.
2278 (gnat_genericize_r): Likewise.
2279 (gnat_genericize): Likewise.
2280 (end_subprog_body): Do not call gnat_genericize.
2281 * gcc-interface/utils2.c (build_binary_op) <INIT_EXPR>: New case.
2282 (build_return_expr): Adjust parameter names, logic and comment.
2284 2010-04-07 Eric Botcazou <ebotcazou@adacore.com>
2286 * exp_pakd.adb (Create_Packed_Array_Type): Always use a modular type
2287 if the size is small enough. Propagate the alignment if there is an
2288 alignment clause on the original array type.
2289 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Modular_Integer_Subtype>
2290 Deal with under-aligned packed array types. Copy the size onto the
2291 justified modular type and don't lay it out again. Likewise for the
2292 padding type built for other under-aligned subtypes.
2293 * gcc-interface/utils.c (finish_record_type): Do not set a default mode
2296 2010-04-07 Eric Botcazou <ebotcazou@adacore.com>
2298 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set default
2299 alignment on the RETURN type built for the Copy-In Copy-Out mechanism.
2301 2010-04-07 Eric Botcazou <ebotcazou@adacore.com>
2303 * gcc-interface/trans.c (call_to_gnu): In the return-by-target-ptr case
2304 do not set the result type if there is a specified target and do not
2305 convert the result in any cases.
2306 (protect_multiple_eval): Make direct SAVE_EXPR for CALL_EXPR.
2307 (maybe_stabilize_reference) <COMPOUND_EXPR>: Merge with CALL_EXPR.
2309 2010-03-10 Eric Botcazou <ebotcazou@adacore.com>
2311 * gcc-interface/Makefile.in (SPARC/Solaris): Use sparcv8plus.
2313 2010-02-27 Eric Botcazou <ebotcazou@adacore.com>
2316 * gcc-interface/utils2.c (build_binary_op) <EQ_EXPR>: Assert that fat
2317 pointer base types are variant of each other. Apply special treatment
2318 for null to fat pointer types in all cases.
2320 2010-01-28 Pascal Obry <obry@adacore.com>
2322 * s-win32.ads: Add some missing constants.
2324 2010-01-28 Vincent Celier <celier@adacore.com>
2326 * prj-attr-pm.adb (Add_Attribute): Do nothing if To_Package is
2329 2010-01-28 Robert Dewar <dewar@adacore.com>
2331 * gnat_rm.texi: Minor correction
2333 2010-01-27 Pascal Obry <obry@adacore.com>
2335 * g-awk.adb: ensure that an AWK session is reusable.
2337 2010-01-27 Vasiliy Fofanov <fofanov@adacore.com>
2339 * g-regist.adb (For_Every_Key): Fix previous change.
2342 2010-01-27 Thomas Quinot <quinot@adacore.com>
2344 * lib-writ.ads: Current version of spec for new N (note) ALI lines
2346 2010-01-27 Yannick Moy <moy@adacore.com>
2348 * a-cdlili.adb (Insert): Correct exception message when cursor
2349 designates wrong list.
2351 2010-01-27 Vincent Celier <celier@adacore.com>
2353 * gnatcmd.adb: When there is only one main specified, the package
2354 support Switches (<main>) and attribute Switches is specified for the
2355 main, use these switches, instead of Default_Switches ("Ada").
2357 2010-01-27 Robert Dewar <dewar@adacore.com>
2359 * sem_prag.adb, par-prag.adb, snames.ads-tmpl: pragma Dimension initial
2361 * exp_disp.adb: Minor reformatting
2363 2010-01-27 Tristan Gingold <gingold@adacore.com>
2365 * seh_init.c: Use __ImageBase instead of _ImageBase.
2367 2010-01-27 Javier Miranda <miranda@adacore.com>
2369 * exp_disp.ads, exp_disp.adb (Expand_Interface_Thunk): Modify the
2370 profile of interface thunks. The type of the controlling formal is now
2371 the covered interface type (instead of the target tagged type).
2373 2010-01-27 Sergey Rybin <rybin@adacore.com>
2375 * gnat_rm.texi, gnat_ugn.texi: Update gnatcheck doc.
2377 2010-01-27 Robert Dewar <dewar@adacore.com>
2379 * sinput.ads, sinput.adb (Sloc_Range): Applies to all nodes, formal
2380 changed from Expr to N.
2382 2010-01-26 Thomas Quinot <quinot@adacore.com>
2384 * gnat_ugn.texi: Adjust documentation of -gnatz switches.
2385 * usage.adb: Replace line for -gnatz with two lines for -gnatzc and
2388 2010-01-26 Vincent Celier <celier@adacore.com>
2390 * prj-attr.adb: Add new attribute Library_Install_Name_Option
2391 Replace attribute Run_Path_Origin_Supported with Run_Path_Origin
2392 * prj-nmsc.adb (Process_Project_Level_Simple_Attributes): Process
2393 attributes Run_Path_Option and Library_Install_Name_Option.
2394 * prj.ads (Project_Configuration): Replace component
2395 Run_Path_Origin_Supported with component Run_Path_Origin. Add new
2396 component Library_Install_Name_Option.
2397 * snames.ads-tmpl: Add new standard name Library_Install_Name_Option
2398 Replace Run_Path_Origin_Supported with Run_Path_Origin
2400 2010-01-26 Ed Schonberg <schonberg@adacore.com>
2402 * sem_ch8.adb (Use_One_Package): Within an instance, an actual package
2403 is not hidden by a homograph declared in another actual package.
2405 2010-01-26 Robert Dewar <dewar@adacore.com>
2407 * par_sco.adb (Traverse_Declarations_Or_Statements): Only generate
2408 decisions for pragmas Assert, Check, Precondition, Postcondition if
2410 * scos.ads: Update comments.
2411 * get_scos.adb, put_scos.adb: Minor fix to code reading statement SCOs.
2412 Also remove obsolete code for CT (exit point) SCOs.
2414 2010-01-26 Thomas Quinot <quinot@adacore.com>
2416 * switch-c.adb: Fix handling of -gnatz*
2418 2010-01-26 Robert Dewar <dewar@adacore.com>
2420 * par_sco.adb (Traverse_Declarations_Or_Statements): Separate F/W
2421 qualifiers for FOR/WHILE loops
2422 * scos.ads: Use separate type letters F/W for for/while loops
2424 2010-01-26 Robert Dewar <dewar@adacore.com>
2426 * get_scos.adb (Get_SCOs): Implement new form of CS entries (multiple
2427 entries per line, one for each statement in the sequence).
2428 * par_sco.adb (Traverse_Declarations_Or_Statements): Increase array
2429 size from 100 to 10_000 for SC_Array to avoid any real possibility of
2430 overflow. Output decisions in for loops.
2431 Exclude labels from CS lines.
2432 * scos.ads: Clarify that label is not included in the entry point
2434 2010-01-26 Robert Dewar <dewar@adacore.com>
2436 * par_sco.adb (Traverse_Declarations_Or_Statments): Implement new
2437 format of statement sequence SCO entries (one location/statement).
2438 * put_scos.adb (Put_SCOs): Implement new format of CS lines
2439 * scos.ads: Update comments.
2440 * sem_eval.adb: Minor reformatting.
2442 2010-01-26 Robert Dewar <dewar@adacore.com>
2444 * par_sco.ads, par_sco.adb (Set_Statement_Entry): New handling of exits
2445 (Extend_Statement_Sequence): New procedures
2446 (Traverse_Declarations_Or_Statements): New handling for exits.
2448 2010-01-26 Robert Dewar <dewar@adacore.com>
2450 * par_sco.adb (Traverse_Declarations_Or_Statements): Add processing for
2453 2010-01-26 Robert Dewar <dewar@adacore.com>
2455 * par_sco.adb (Is_Logical_Operator): Exclude AND/OR/XOR
2456 * scos.ads: Clarify handling of logical operators
2458 2010-01-26 Arnaud Charlet <charlet@adacore.com>
2460 * s-tpoben.adb: Update comments.
2462 2010-01-26 Robert Dewar <dewar@adacore.com>
2464 * freeze.adb (Set_Small_Size): Don't set size if alignment clause
2467 2010-01-26 Robert Dewar <dewar@adacore.com>
2469 * scos.ads: Clean up documentation, remove obsolete XOR references
2470 2010-01-26 Vincent Celier <celier@adacore.com>
2472 * gnat_ugn.texi: Complete documentation on the restrictions for
2473 combined options in -gnatxxx switches.
2476 2010-01-26 Arnaud Charlet <charlet@adacore.com>
2478 * s-tpoben.adb (Initialize_Protection_Entries): If a PO is created from
2479 a controlled operation, abort is already deferred at this point, so we
2480 need to use Defer_Abort_Nestable.
2482 2010-01-26 Vincent Celier <celier@adacore.com>
2484 * prj-conf.adb (Get_Config_Switches): Check for a default language for
2485 a project extending a project with no languages.
2487 2010-01-26 Vincent Celier <celier@adacore.com>
2489 * switch-c.adb (Scan_Front_End_Switches): Take into account options
2490 that follow -gnatef.
2491 Allow -gnateG to be followed by other options.
2493 2010-01-26 Robert Dewar <dewar@adacore.com>
2495 * s-commun.ads, s-osprim-mingw.adb, s-stchop-vxworks.adb, sem_aggr.adb,
2496 s-vxwext.adb, sem_ch10.adb, sem_eval.adb, sem_prag.adb: Minor
2499 2010-01-26 Vasiliy Fofanov <fofanov@adacore.com>
2501 * g-regist.adb, g-regist.ads (For_Every_Key): New generic procedure
2502 that allows to iterate over all subkeys of a key.
2504 2010-01-26 Ed Falis <falis@adacore.com>
2506 * sysdep.c: enable NFS for VxWorks MILS
2507 * env.c: enable __gnat_environ for VxWorks MILS
2508 * gcc-interface/Makefile.in: Add VxWorks MILS target pairs.
2510 2010-01-25 Bob Duff <duff@adacore.com>
2512 * sem_aggr.adb (Resolve_Array_Aggregate): Check for the case where this
2513 is an internally-generated positional aggregate, and the bounds are
2514 already correctly set. We don't want to overwrite those bounds with
2515 bounds determined by context.
2517 2010-01-25 Robert Dewar <dewar@adacore.com>
2519 * g-sercom.ads, gnatcmd.adb, gnatlink.adb, a-ststio.adb, exp_ch6.adb,
2520 exp_ch9.adb, g-sechas.ads: Minor reformatting.
2522 2010-01-25 Thomas Quinot <quinot@adacore.com>
2524 * s-commun.adb (Last_Index): Count must be converted to SEO (a signed
2525 integer type) before subtracting 1, otherwise the computation may wrap
2526 (because size_t is modular) and cause the conversion to fail.
2528 2010-01-25 Ed Falis <falis@adacore.com>
2530 * sysdep.c, init.c: Adapt to support full run-time on VxWorks MILS.
2532 2010-01-25 Vincent Celier <celier@adacore.com>
2534 * prj-attr.adb: New attribute Run_Path_Origin_Required
2535 * prj-nmsc.adb (Process_Project_Level_Simple_Attributes): Process new
2536 attribute Run_Path_Origin_Required.
2537 * prj.ads (Project_Configuration): New component
2538 Run_Path_Origin_Supported.
2539 * snames.ads-tmpl: New standard name Run_Path_Origin_Required
2541 2010-01-25 Ed Schonberg <schonberg@adacore.com>
2543 * sem_aggr.adb (Resolve_Array_Aggregate): If the bounds in a choice
2544 have errors, do not continue resolution of the aggregate.
2545 * sem_eval.adb (Eval_Indexed_Component): Do not attempt to evaluate if
2546 the array type indicates an error.
2548 2010-01-25 Bob Duff <duff@adacore.com>
2550 * sinfo.ads: Minor comment fixes.
2552 2010-01-25 Bob Duff <duff@adacore.com>
2554 * exp_ch4.adb, exp_aggr.adb: Minor comment fixes and code clean up.
2556 2010-01-25 Arnaud Charlet <charlet@adacore.com>
2558 * gnatvsn.ads (Current_Year): Update.
2560 2010-01-25 Florian Villoing <villoing@adacore.com>
2562 * gnat_ugn.texi: Fix typo.
2564 2010-01-25 Thomas Quinot <quinot@adacore.com>
2566 * scos.ads: Update specification.
2568 2010-01-25 Ed Schonberg <schonberg@adacore.com>
2570 * sem_ch6.adb (Process_PPCs): If a postcondition is present and the
2571 enclosing subprogram has no previous spec, attach postcondition
2572 procedure to the defining entity for the body.
2574 2010-01-25 Ed Schonberg <schonberg@adacore.com>
2576 * exp_aggr.adb (Build_Record_Aggr_Code); Do not generate call to
2577 initialization procedure of the ancestor part of an extension aggregate
2578 if it is an interface type.
2580 2010-01-25 Vincent Celier <celier@adacore.com>
2582 * gnatlink.adb (Process_Binder_File): The directory for the shared
2583 version of libgcc in the run path options is found in the subdirectory
2584 indicated by __gnat_default_libgcc_subdir.
2585 * link.c: Declare new const char * __gnat_default_libgcc_subdir for
2588 2010-01-25 Ed Schonberg <schonberg@adacore.com>
2590 * sem_prag.adb: More flexible pragma Annotate.
2592 2010-01-22 Eric Botcazou <ebotcazou@adacore.com>
2594 * system-linux-armel.ads (Stack_Check_Probes): Set to True.
2595 * system-linux-armeb.ads (Stack_Check_Probes): Likewise.
2597 2010-01-18 Eric Botcazou <ebotcazou@adacore.com>
2599 * gcc-interface/utils.c (create_var_decl_1): Fix formatting nits.
2601 2010-01-18 Jan Hubicka <jh@suse.cz>
2604 * gcc-interface/utils.c (create_var_decl_1): Do not set COMMON flag for
2605 unit local variables.
2607 2010-01-17 Laurent GUERBY <laurent@guerby.net>
2609 * gcc-interface/Makefile.in: Fix typo in arm*-*-linux-gnueabi.
2611 2010-01-11 Mikael Pettersson <mikpe@it.uu.se>
2613 * gcc-interface/Makefile.in: Add arm*-*-linux-gnueabi.
2614 * system-linux-armeb.ads, system-linux-armel.ads: New files.
2616 2010-01-09 Simon Wright <simon@pushface.org>
2619 * gcc-interface/Makefile.in (gnatlib-shared-darwin): Add missing
2624 Copyright (C) 2010 Free Software Foundation, Inc.
2626 Copying and distribution of this file, with or without modification,
2627 are permitted in any medium without royalty provided the copyright
2628 notice and this notice are preserved.