OSDN Git Service

2010-06-17 Thomas Quinot <quinot@adacore.com>
[pf3gnuchains/gcc-fork.git] / gcc / ada / ChangeLog
1 2010-06-17  Thomas Quinot  <quinot@adacore.com>
2
3         * exp_imgv.adb, exp_ch7.ads: Minor reformatting.
4
5 2010-06-17  Robert Dewar  <dewar@adacore.com>
6
7         * exp_ch9.adb, exp_disp.adb, exp_dist.adb: Use Make_Temporary.
8
9 2010-06-17  Thomas Quinot  <quinot@adacore.com>
10
11         * sprint.adb (pg): Set Dump_Freeze_Null, to be consistent with -gnatdg.
12
13 2010-06-17  Robert Dewar  <dewar@adacore.com>
14
15         * exp_ch6.adb, exp_ch7.adb, exp_ch5.adb: Use Make_Temporary
16         * tbuild.ads (Make_Temporary): More comment updates
17         * tbuild.adb: Minor reformatting
18
19 2010-06-17  Robert Dewar  <dewar@adacore.com>
20
21         * checks.adb, exp_aggr.adb, exp_atag.adb, exp_attr.adb, exp_ch11.adb,
22         exp_ch3.adb, exp_ch4.adb: Minor code reorganization.
23         Use Make_Temporary.
24         * tbuild.ads, tbuild.adb (Make_Temporary): Clean up, use Entity_Id
25         instead of Node_Id.
26         (Make_Temporary): Add more extensive documentation
27
28 2010-06-17  Robert Dewar  <dewar@adacore.com>
29
30         * sem_intr.adb, sem_prag.adb, sem_res.adb, sem_type.adb, sem_util.adb,
31         sem_warn.adb, sem_eval.adb: Minor reformatting.  Use Ekind_In.
32         (Set_Slice_Subtype): Explicitly freeze the slice's itype at the point
33         where the slice's actions are inserted.
34         (Decompose_Expr): Account for possible rewriting of slice bounds
35         resulting from side effects suppression caused by the above freezing,
36         so that folding of bounds is preserved by such rewriting.
37
38 2010-06-17  Robert Dewar  <dewar@adacore.com>
39
40         * einfo.ads, einfo.adb (Get_Record_Representation_Clause): New function.
41         * freeze.adb (Freeze_Record_Type): Add call to
42         Check_Record_Representation_Clause.
43         * sem_ch13.adb (Check_Record_Representation_Clause): New function
44         (Analyze_Record_Representation_Clause): Split out overlap code into this
45         new function.
46         (Check_Component_Overlap): Moved inside
47         Check_Record_Representation_Clause.
48         * sem_ch13.ads (Check_Record_Representation_Clause): New function.
49
50 2010-06-17  Robert Dewar  <dewar@adacore.com>
51
52         * back_end.adb, sem_res.adb, switch-c.adb, sem_scil.adb: Minor
53         reformatting.
54         * sem_attr.adb, sem_cat.adb, sem_disp.adb, sem_elab.adb, sem_elim.adb,
55         sem_eval.adb: Use Ekind_In
56
57 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
58
59         * sem_ch8.adb: better error message for illegal inherited discriminant
60
61 2010-06-17  Vincent Celier  <celier@adacore.com>
62
63         * bindusg.adb: Remove lines for -A and -C
64         * gnat_ugn.texi: Remove all documentation and examples of switches -A
65         and -C for gnatbind and gnatlink.
66         * gnatlink.adb (Usage): Remove lines for -A and -C
67         * switch-b.adb (Scan_Binder_Switches): Issue warning when switch -C is
68         specified.
69         * gcc-interface/Make-lang.in: Update dependencies.
70
71 2010-06-17  Vincent Celier  <celier@adacore.com>
72
73         * back_end.adb (Scan_Compiler_Arguments): Put all arguments in new
74         local Argument_List variable Args.
75         * switch-c.adb (Scan_Front_End_Switches): New Argument_List argument
76         Args.
77         (Switch_Subsequently_Cancelled): New Argument_List argument Args. Look
78         for subsequent switches in Args.
79         * switch-c.ads (Scan_Front_End_Switches): New Argument_List argument
80         Args.
81         * gcc-interface/Make-lang.in: Update dependencies.
82
83 2010-06-17  Robert Dewar  <dewar@adacore.com>
84
85         * einfo.adb: Minor code fix, allow E_Class_Wide_Type for
86         Equivalent_Type to match documentation.
87
88 2010-06-17  Robert Dewar  <dewar@adacore.com>
89
90         * sem_ch6.adb, sem_ch7.adb: Minor reformatting.
91         * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_ch10.adb, sem_ch12.adb,
92         sem_ch4.adb, sem_ch8.adb, sem_ch13.adb: Make use of Ekind_In.
93
94 2010-06-17  Thomas Quinot  <quinot@adacore.com>
95
96         * sem_res.adb (Set_Slice_Subtype): Always freeze the slice's itype.
97
98 2010-06-17  Thomas Quinot  <quinot@adacore.com>
99
100         * freeze.adb (Freeze_Expression): Short circuit operators are valid
101         freeze node insertion points.
102
103 2010-06-17  Robert Dewar  <dewar@adacore.com>
104
105         * switch-c.ads, switch-c.adb, sem_ch13.adb: Minor reformatting.
106         * sem_ch12.adb: Add pragmas Assert and Check to previous change.
107
108 2010-06-17  Gary Dismukes  <dismukes@adacore.com>
109
110         * layout.adb (Layout_Type): Broaden test for setting an array type's
111         Component_Size to include all scalar types, not just discrete types
112         (components of real types were missed).
113         * sem_ch3.adb (Constrain_Index): Add missing setting of First_Literal
114         on the itype created for an index (consistent with Make_Index and
115         avoids possible Assert_Failures).
116
117 2010-06-17  Robert Dewar  <dewar@adacore.com>
118
119         * atree.ads, atree.adb: Add 6-parameter version of Ekind_In
120         * einfo.adb: Minor code reformatting (use Ekind_In)
121
122 2010-06-17  Robert Dewar  <dewar@adacore.com>
123
124         * sem_warn.adb (Test_Ref): Abandon scan if access subprogram parameter
125         found.
126
127 2010-06-17  Vincent Celier  <celier@adacore.com>
128
129         * back_end.adb: Minor comment updates
130         * switch-c.adb: Remove dependencies on gcc C sources
131         * gcc-interface/Make-lang.in: Add a-comlin.o to the object file list
132         for the compiler.
133
134 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
135
136         * sem_ch12.adb: propagate Pragma_Enabled flag to generic.
137         * get_scos.adb: Set C2 flag in decision entry of pragma to 'e' (enabled)
138         * par_sco.ads, par_sco.adb (Set_SCO_Pragma_Enabled): New procedure
139         Remove use of Node field in SCOs table
140         (Output_Header): Set 'd' to initially disable pragma entry
141         * put_scos.adb (Put_SCOs): New flag indicating if pragma is enabled
142         * scos.ads, scos.adb: Remove Node field from internal SCOs table.
143         Use C2 field of pragma decision header to indicate enabled.
144         * sem_prag.adb: Add calls to Set_SCO_Pragma_Enabled.
145         * gcc-interface/Make-lang.in: Update dependencies.
146
147 2010-06-17  Vincent Celier  <celier@adacore.com>
148
149         * back_end.adb (Next_Arg): Moved to procedure Scan_Compiler_Arguments
150         (Scan_Compiler_Arguments): Call Scan_Front_End_Switches with Next_Arg
151         (Switch_Subsequently_Cancelled): Function moved to the body of Switch.C
152         * back_end.ads (Scan_Front_End_Switches): Function moved to the body of
153         Switch.C.
154         * switch-c.adb: Copied a number of global declarations from back_end.adb
155         (Len_Arg): New function copied from back_end.adb
156         (Switch_Subsequently_Cancelled): New function moved from back_end.adb
157         (Scan_Front_End_Switches): New parameter Arg_Rank used to call
158         Switch_Subsequently_Cancelled.
159         * switch-c.ads (Scan_Front_End_Switches): New parameter Arg_Rank.
160         * gcc-interface/Makefile.in: Add line so that shared libgnat is linked
161         with -lexc on Tru64.
162
163 2010-06-17  Robert Dewar  <dewar@adacore.com>
164
165         * prj.ads, prj.adb: Minor reformatting
166
167 2010-06-17  Thomas Quinot  <quinot@adacore.com>
168
169         * put_scos.adb: Do not generate a blank line in SCOs when omitting the
170         CP line for a disabled pragma.
171
172 2010-06-17  Emmanuel Briot  <briot@adacore.com>
173
174         * prj-proc.adb, prj.adb, prj.ads (Check_Or_Set_Typed_Variable): New
175         subprogram.
176         (Process_Declarative_Item): An invalid value in an typed variable
177         declaration is no longer always fatal.
178
179 2010-06-16  Arnaud Charlet  <charlet@adacore.com>
180
181         * get_scos.adb, par_sco.adb, par_sco.ads, put_scos.adb, scos.adb,
182         scos.ads, exp_ch4.adb, sem_warn.adb: Code clean up, update
183         documentation.
184
185 2010-06-16  Javier Miranda  <miranda@adacore.com>
186
187         * exp_disp.adb (Expand_Dispatching_Call): Adjust the decoration of the
188         node referenced by the SCIL node of dispatching "=" to skip the tags
189         comparison.
190
191 2010-06-16  Ed Schonberg  <schonberg@adacore.com>
192
193         * sem_ch5.adb (Analyze_Exit_Statement): Return if no enclosing loop,
194         to prevent cascaded errors and compilation aborts.
195
196 2010-06-16  Robert Dewar  <dewar@adacore.com>
197
198         * back_end.adb (Switch_Subsequently_Cancelled): New function
199         Move declarations to package body level to support this change
200         * back_end.ads (Switch_Subsequently_Cancelled): New function
201         * gnat_ugn.texi: Document -gnat-p switch
202         * switch-c.adb (Scan_Front_End_Switches): Implement -gnat-p switch
203         * ug_words: Add entry for -gnat-p (UNSUPPRESS_ALL)
204         * usage.adb: Add line for -gnat-p switch
205         * vms_data.ads: Add entry for UNSUPPRESS_ALL (-gnat-p)
206
207 2010-06-16  Robert Dewar  <dewar@adacore.com>
208
209         * sem_warn.adb (Check_Infinite_Loop_Warning): Declaration counts as
210         modification.
211
212 2010-06-16  Robert Dewar  <dewar@adacore.com>
213
214         * exp_disp.adb: Minor reformatting
215
216 2010-06-16  Ed Schonberg  <schonberg@adacore.com>
217
218         * sem_ch3.adb (Complete_Private_Subtype): Inherit class_wide type from
219         base type only if it was not previously created for the partial view.
220
221 2010-06-16  Thomas Quinot  <quinot@adacore.com>
222
223         * tbuild.ads: Minor comment fix
224
225 2010-06-15  Nathan Froyd  <froydnj@codesourcery.com>
226
227         * gcc-interface/trans.c (gnu_stack_free_list): Delete.
228         (gnu_except_ptr_stack): Change type to VEC.  Update comment.
229         (gnu_elab_proc_stack): Likewise.
230         (gnu_return_label_stack): Likewise.
231         (gnu_loop_label_stack): Likewise.
232         (gnu_switch_label_stack): Likewise.
233         (gnu_constraint_label_stack): Likewise.
234         (gnu_storage_error_label_stack): Likewise.
235         (gnu_program_error_label_stack): Likewise.
236         (push_exception_label_stack): Take a VEC ** instead of a tree *.
237         (push_stack): Likewise.  Remove unused second parameter.  Update
238         callers.
239         (pop_stack): Take a VEC * instead of a tree *.  Update callers.
240         (gigi): Initialize stacks as VECs.
241         (Identifier_to_gnu): Use VEC_last instead of TREE_VALUE.
242         (Case_Statement_to_gnu): Likewise.
243         (Subprogram_Body_to_gnu): Likewise.
244         (call_to_gnu): Likewise.
245         (Exception_Handler_to_gnu_sjlj): Likewise.
246         (gnat_to_gnu): Likewise.
247         (get_exception_label): Likewise.
248
249 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
250
251         * sem_ch3.adb (Build_Derived_Record_Type): if derived type is an
252         anonymous base generated when the parent is a constrained discriminated
253         type, propagate interface list to first subtype because it may appear
254         in a current instance within the extension part of the derived type
255         declaration, and its own subtype declaration has not been elaborated
256         yet.
257         * exp_disp.adb (Build_Interface_Thunk): Use base type of formal to
258         determine whether it has the controlling type.
259
260 2010-06-14  Jerome Lambourg  <lambourg@adacore.com>
261
262         * exp_ch11.adb (Expand_N_Raise_Statement): Make sure that the explicit
263         raise of CE, SE and PE have the reason correctly set and are properly
264         expanded before stopping the expansions of .NET/JVM exceptions.
265
266 2010-06-14  Robert Dewar  <dewar@adacore.com>
267
268         * opt.ads (Check_Policy_List): Add some clarifying comments
269         * sem_prag.adb (Analyze_Pragma, case Check): Set Pragma_Enabled flag
270         on rewritten Assert pragma.
271
272 2010-06-14  Gary Dismukes  <dismukes@adacore.com>
273
274         * sem_ch6.adb (Check_Overriding_Indicator): Add a special check for
275         controlled operations, so that they will be treated as overriding even
276         if the overridden subprogram is marked Is_Hidden, as long as the
277         overridden subprogram's parent subprogram is not hidden.
278
279 2010-06-14  Robert Dewar  <dewar@adacore.com>
280
281         * debug.adb: Entry for gnatw.d no longer specific for while loops
282         * einfo.adb (First_Exit_Statement): New attribute for E_Loop
283         * einfo.ads (First_Exit_Statement): New attribute for E_Loop
284         * sem_ch5.adb (Analyze_Loop_Statement): Check_Infinite_Loop_Warning has
285         new calling sequence to include test for EXIT WHEN.
286         (Analyze_Exit_Statement): Chain EXIT statement into exit statement chain
287         * sem_warn.ads, sem_warn.adb (Check_Infinite_Loop_Warning): Now handles
288         EXIT WHEN case.
289         * sinfo.adb (Next_Exit_Statement): New attribute of N_Exit_Statement
290         node.
291         * sinfo.ads (N_Pragma): Correct comment on Sloc field (points to
292         PRAGMA, not to pragma identifier).
293         (Next_Exit_Statement): New attribute of N_Exit_Statement node
294
295 2010-06-14  Robert Dewar  <dewar@adacore.com>
296
297         * sem_res.adb (Resolve_Short_Circuit): Fix sloc of "assertion/check
298         would fail" msg.
299
300 2010-06-14  Robert Dewar  <dewar@adacore.com>
301
302         * par-ch2.adb (Scan_Pragma_Argument_Association): Clarify message for
303         missing pragma argument identifier.
304
305 2010-06-14  Robert Dewar  <dewar@adacore.com>
306
307         * atree.ads, atree.adb (Ekind_In): New functions.
308
309 2010-06-14  Robert Dewar  <dewar@adacore.com>
310
311         * exp_ch4.adb (Expand_N_Op_Expon): Optimize 2**N in stand alone context
312
313 2010-06-14  Robert Dewar  <dewar@adacore.com>
314
315         * usage.adb (Usage): Redo documentation of -gnatwa.
316
317 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
318
319         * sem_ch8.adb (Find_Type): The attribute 'class cannot be applied to
320         an untagged incomplete type that is a limited view.
321
322 2010-06-14  Sergey Rybin  <rybin@adacore.com>
323
324         * gnat_ugn.texi: Add description of '-cargs gcc_switches' to gnatstub
325         and gnatppa.
326
327 2010-06-14  Thomas Quinot  <quinot@adacore.com>
328
329         * exp_ch4.adb (Expand_Short_Circuit_Operator): New subprogram,
330         factoring duplicated code between...
331         (Expand_N_And_Than, Expand_N_Or_Else): Remove duplicated code.
332         * a-envvar.ads: Minor reformatting
333
334 2010-06-14  Arnaud Charlet  <charlet@adacore.com>
335
336         * ali.adb, ali.ads, lib-xref.ads: Document new '+' letter for C/C++
337         static entities.
338         (Scan_ALI): Take into account new Visibility field.
339         (Visibility_Kind): New type.
340         (Xref_Entity_Record): Replace Lib field by Visibility.
341
342         * gcc-interface/Make-lang.in: Update dependencies.
343
344 2010-06-14  Pascal Obry  <obry@adacore.com>
345
346         * raise.h: Remove unused defintions.
347
348 2010-06-14  Bob Duff  <duff@adacore.com>
349
350         * par-ch10.adb (P_Subunit): If the next token after "separate(X)" is
351         Tok_Not or Tok_Overriding, call P_Subprogram. We had previously given
352         the incorrect error "proper body expected".
353         * par-ch6.adb (P_Subprogram): Suppress "overriding indicator not
354         allowed here" error in case of subunits, which was triggered by the
355         above change to P_Subunit.
356
357 2010-06-14  Sergey Rybin  <rybin@adacore.com>
358
359         * gnat_ugn.texi, vms_data.ads: Update gnatelim doc.
360
361 2010-06-14  Thomas Quinot  <quinot@adacore.com>
362
363         * lib-util.adb: Minor code reorganization.
364
365 2010-06-14  Robert Dewar  <dewar@adacore.com>
366
367         * ali.adb (Scan_ALI): Implement reading and storing of N lines
368         (Known_ALI_Lines): Add entry for 'N' (notes)
369         * ali.ads (Notes): New table to store Notes information
370         * alloc.ads: Add entries for Notes table
371         * lib-util.adb (Write_Info_Int): New procedure
372         (Write_Info_Slit): New procedure
373         (Write_Info_Uint): New procedure
374         * lib-util.ads (Write_Info_Int): New procedure
375         (Write_Info_Slit): New procedure
376         (Write_Info_Uint): New procedure
377         * lib-writ.adb (Write_Unit_Information): Output N (notes) lines
378         * lib-writ.ads: Update documentation for N (Notes) lines
379         * lib.adb (Store_Note): New procedure
380         * lib.ads (Notes): New table
381         (Store_Note): New procedure
382         * sem_prag.adb: Call Store_Note for affected pragmas
383
384 2010-06-14  Thomas Quinot  <quinot@adacore.com>
385
386         * socket.c: Fix wrong condition in #ifdef
387         * g-socket.adb, g-sothco.ads: Functions imported from socket.c that
388         take or return char* values can't use Interfaces.C.Strings.chars_ptr,
389         because on VMS this type is a 32-bit pointer which is not compatible
390         with the default for C pointers for code compiled with gcc on that
391         platform.
392
393 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
394
395         * sem_util (Is_VMS_Operator): New predicate to determine whether an
396         operator is an intrinsic operator declared in the DEC system extension.
397         * sem_res.adb (Resolve_Logical_Op): operation is legal on signed types
398         if the operator is a VMS intrinsic.
399         * sem_eval.adb (Eval_Logical_Op): Operation is legal and be
400         constant-folded if the operands are signed and the operator is a VMS
401         intrinsic.
402
403 2010-06-14  Robert Dewar  <dewar@adacore.com>
404
405         * g-socket.adb, gnatcmd.adb: Minor reformatting.
406
407 2010-06-14  Pascal Obry  <obry@adacore.com>
408
409         * s-finimp.adb: Fix typo.
410         * raise.h: Remove duplicate blank line.
411
412 2010-06-14  Vincent Celier  <celier@adacore.com>
413
414         * prj-nmsc.adb (Add_Sources): Always set the object file and the
415         switches file names, as the configuration of the language may change
416         in an extending project.
417         (Process_Naming_Scheme): For sources of projects that are extended, set
418         the configuration of the language from the highest extending project
419         where the language is declared.
420
421 2010-06-14  Gary Dismukes  <dismukes@adacore.com>
422
423         * sem_res.adb (Resolve_Call): For infinite recursion check, test
424         whether the called subprogram is inherited from a containing subprogram.
425         (Same_Or_Aliased_Subprograms): New function
426
427 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
428
429         * sem_ch8.adb (End_Use_Type): Before indicating that an operator is not
430         use-visible, check whether it is a primitive for more than one type.
431
432 2010-06-14  Robert Dewar  <dewar@adacore.com>
433
434         * sem_ch3.adb (Copy_And_Swap): Copy Has_Pragma_Unmodified flag.
435
436         * sem_ch7.adb (Preserve_Full_Attributes): Preserve
437         Has_Pragma_Unmodified flag.
438
439 2010-06-14  Thomas Quinot  <quinot@adacore.com>
440
441         * g-sttsne-locking.adb, g-sttsne-locking.ads, g-sttsne.ads,
442         g-sttsne-vxworks.adb, g-sttsne-dummy.ads: Removed. Mutual exclusion is
443         now done in GNAT.Sockets if necessary.
444         * gsocket.h, g-socket.adb, g-sothco.ads (GNAT.Sockets.Get_XXX_By_YYY):
445         Ensure mutual exclusion for netdb operations if the target platform
446         requires it.
447         (GNAT.Sockets.Thin_Common): New binding for getXXXbyYYY, treating struct
448         hostent as an opaque type to improve portability.
449         * s-oscons-tmplt.c, socket.c: For the case of Vxworks, emulate
450         gethostbyYYY using proprietary VxWorks API so that a uniform interface
451         is available for the Ada side.
452         * gcc-interface/Makefile.in: Remove g-sttsne-*
453         * gcc-interface/Make-lang.in: Update dependencies.
454
455 2010-06-14  Vincent Celier  <celier@adacore.com>
456
457         * gnatcmd.adb (Mapping_File): New function.
458
459 2010-06-14  Javier Miranda  <miranda@adacore.com>
460
461         * sem_ch3.adb (Derive_Subprograms): Remove over-restrictive assertion.
462
463 2010-06-14  Arnaud Charlet  <charlet@adacore.com>
464
465         * ali.adb: Fix typo.
466         * s-auxdec-vms-alpha.adb, scng.ads: Minor reformatting.
467
468 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
469
470         * sem_ch12.adb: Make Mark_Context transitive, and apply to subprogram
471         instances.
472
473         * sem_ch8.adb (Find_Expanded_Name): If a candidate compilation unit in
474         the context does not have a homonym of the selector, emit default
475         error message.
476
477 2010-06-14  Robert Dewar  <dewar@adacore.com>
478
479         * sem.adb, sem_ch12.adb, sem_util.adb: Minor reformatting and
480         comment addition.
481
482 2010-06-14  Arnaud Charlet  <charlet@adacore.com>
483
484         * lib-xref.ads: Doc updates:
485          - Allocate 'Q' for #include entity kind
486          - Free 'Z'
487          - Allocate 'g' for regular macros
488          - Allocate 'G' for function-like macros
489
490 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
491
492         * sinfo.ads, sinfo.adb (Withed_Body): New attribute of a with_clause.
493         Indicates that there is an instantiation in the current unit that
494         loaded the body of the unit denoted by the with_clause.
495         * sem_ch12.adb (Mark_Context): When instanting a generic body, check
496         whether a with_clause in the current context denotes the unit that
497         holds the generic declaration, and mark the with_clause accordingly.
498         (Instantiate_Package_Body): call Mark_Context.
499         * sem.adb (Process_Bodies_In_Context): Use Withed_Body to determine
500         whether a given body should be traversed before the spec of the main
501         unit.
502
503 2010-06-14  Ed Falis  <falis@adacore.com>
504
505         * sysdep.c: Fix 653 build against vThreads headers.
506
507 2010-06-14  Robert Dewar  <dewar@adacore.com>
508
509         * sinfo.ads: Minor reformatting.
510
511 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
512
513         * sem_ch6.adb (Analyze_Subprogram_Body): Do not check conformance when
514         the spec has been generated for a body without spec that carries an
515         Inline_Always pragma.
516
517 2010-06-14  Arnaud Charlet  <charlet@adacore.com>
518
519         * lib-xref.ads: Documentation change: allocate 'Z' letter to C/C++
520         macro.
521
522 2010-06-14  Jerome Lambourg  <lambourg@adacore.com>
523
524         * exp_dbug.adb (Debug_Renaming_Declaration): Do not output any debug
525         declaration for VMs, as those are useless and might lead to duplicated
526         local variable names in the generated code.
527         * gcc-interface/Make-lang.in: Update dependencies.
528
529 2010-06-14  Robert Dewar  <dewar@adacore.com>
530
531         * opt.ads, sem.adb, sem_elab.adb: Minor reformatting
532
533 2010-06-14  Robert Dewar  <dewar@adacore.com>
534
535         * exp_aggr.adb (Has_Address_Clause): Moved to Exp_Util, and there it
536         is renamed as Has_Following_Address_Clause.
537         * exp_ch3.adb (Needs_Simple_Initialization): Add Consider_IS argument
538         to allow the caller to avoid Initialize_Scalars having an effect.
539         (Expand_N_Object_Declaration): Do not do Initialize_Scalars stuff for
540         scalars with an address clause specified.
541         * exp_ch3.ads (Needs_Simple_Initialization): Add Consider_IS argument
542         to allow the caller to avoid Initialize_Scalars having an effect.
543         * exp_util.adb (Has_Following_Address_Clause): Moved here from Exp_Aggr
544         (where it was called Has_Address_Clause).
545         * exp_util.ads (Has_Following_Address_Clause): Moved here from Exp_Aggr
546         (where it was called Has_Address_Clause).
547         * freeze.adb (Warn_Overlay): Suppress message about overlaying causing
548         problems for Initialize_Scalars (since we no longer initialize objects
549         with an address clause.
550
551 2010-06-14  Robert Dewar  <dewar@adacore.com>
552
553         * exp_prag.adb (Expand_Pragma_Check): Set Loc of generated code from
554         condition.
555
556 2010-06-14  Gary Dismukes  <dismukes@adacore.com>
557
558         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Set Debug_Info_Needed
559         on the entity of an implicitly generated postcondition procedure.
560
561 2010-06-14  Thomas Quinot  <quinot@adacore.com>
562
563         * sem_ch7.adb (Preserve_Full_Attributes): Propagate
564         Discriminant_Constraint elist from full view to private view.
565
566 2010-06-14  Robert Dewar  <dewar@adacore.com>
567
568         * sem_res.adb: Minor reformatting.
569
570 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
571
572         * sem.adb: New version of unit traversal.
573
574         * sem_elab.adb (Check_Internal_Call): Do not place a call appearing
575         within a generic unit in the table of delayed calls.
576
577 2010-06-14  Robert Dewar  <dewar@adacore.com>
578
579         * gnatcmd.adb, sem_util.adb, exp_ch3.adb: Minor reformatting
580
581 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
582
583         * sem_ch12.adb (Save_References): If an identifier has been rewritten
584         during analysis as an explicit dereference, keep the reference implicit
585         in the generic, but preserve the entity if global. This prevents
586         malformed generic trees in the presence of some nested generics.
587
588 2010-06-14  Sergey Rybin  <rybin@adacore.com>
589
590         * gnat_ugn.texi: For the GNAT driver, clarify the effect of calling the
591         tool with '-files=' option. Also fix some small errors (wrong brackets)
592
593 2010-06-14  Vincent Celier  <celier@adacore.com>
594
595         * gnatbind.adb: Call Scan_ALI with Directly_Scanned set to True for all
596         the ALI files on the command line.
597
598         * ali.adb (Scan_ALI): Set component Directly_Scanned of the unit(s) to
599         the same value as the parameter of the same name.
600         * ali.ads (Scan_ALI): New Boolean parameter Directly_Scanned, defaulted
601         to False.
602         * bindgen.adb (Gen_Versions_Ada): Never emit version symbols for
603         Stand-Alone Library interfaces. When binding Stand-Alone Libraries,
604         emit version symbols only for the units of the library.
605         (Gen_Versions_C): Ditto.
606
607 2010-06-14  Gary Dismukes  <dismukes@adacore.com>
608
609         * sem_ch4.adb: Fix typo.
610
611 2010-06-14  Vasiliy Fofanov  <fofanov@adacore.com>
612
613         * s-oscons-tmplt.c (IOV_MAX): redefine on Tru64 and VMS since the
614         vector IO doesn't work at default value properly.
615
616 2010-06-14  Doug Rupp  <rupp@adacore.com>
617
618         * s-stoele.adb: Remove unnecessary qualification of To_Address for VMS.
619
620 2010-06-14  Vincent Celier  <celier@adacore.com>
621
622         * gnatcmd.adb (Check_Files): Do not invoke the tool with all the
623         sources of the project if a switch -files= is used.
624
625 2010-06-14  Thomas Quinot  <quinot@adacore.com>
626
627         * exp_attr.adb: Minor reformatting.
628
629 2010-06-14  Gary Dismukes  <dismukes@adacore.com>
630
631         * gnat_ugn.texi: Minor typo fixes and wording changes.
632
633 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
634
635         * sem_ch4.adb (Analyze_One_Call): If the call has been rewritten from a
636         prefixed form, do not re-analyze first actual, which may need an
637         implicit dereference.
638         * sem_ch6.adb (Analyze_Procedure_Call): If the call is given in
639         prefixed notation, the analysis will rewrite the node, and possible
640         errors appear in the rewritten name of the node.
641         * sem_res.adb: If a call is ambiguous because its first parameter is
642         an overloaded call, report list of candidates, to clarify ambiguity of
643         enclosing call.
644
645 2010-06-14  Doug Rupp  <rupp@adacore.com>
646
647         * s-auxdec-vms-alpha.adb: New package body implementing legacy
648         VAX instructions with Asm insertions.
649         * s-auxdec-vms_64.ads: Inline VAX queue functions
650         * s-stoele.adb: Resolve some ambiguities in To_Addresss with s-suxdec
651         that show up only on VMS.
652         * gcc-interface/Makefile.in: Provide translation for
653         s-auxdec-vms-alpha.adb.
654
655 2010-06-14  Olivier Hainque  <hainque@adacore.com>
656
657         * initialize.c (VxWorks section): Update comments.
658
659 2010-06-14  Robert Dewar  <dewar@adacore.com>
660
661         * a-convec.adb, sem_prag.adb, checks.adb: Minor reformatting.
662
663 2010-06-14  Eric Botcazou  <ebotcazou@adacore.com>
664
665         * init.c: Code clean up.
666
667 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
668
669         * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case Address): Do
670         not insert address clause in table for later validation if type of
671         entity is generic, to prevent possible spurious errors. 
672
673         * sem_ch8.adb: Code clean up.
674
675 2010-06-14  Ben Brosgol  <brosgol@adacore.com>
676
677         * gnat_ugn.texi: Expanded @ovar macro inline to solve problem with
678         texi2pdf and texi2html.
679         Document how to change scheduling properties on HP-UX.
680
681 2010-06-14  Thomas Quinot  <quinot@adacore.com>
682
683         * g-socket.ads: Remove misleading comments.
684
685 2010-06-14  Jerome Lambourg  <lambourg@adacore.com>
686
687         * sem_prag.adb (Check_Duplicated_Export_Name): Remove check for
688         CLI_Target as this prevents proper detection of exported names
689         duplicates when the exported language is different to CIL.
690         (Process_Interface_Name): Add check for CIL convention exports,
691         replacing the old one from Check_Duplicated_Export_Name.
692
693 2010-06-14  Matthew Heaney  <heaney@adacore.com>
694
695         * a-coinve.adb, a-convec.adb (operator "&"): Check both that new length
696         and new last satisfy constraints.
697         (Delete_Last): prevent overflow for subtraction of index values
698         (To_Vector): prevent overflow for addition of index values
699
700 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
701
702         * sem_ch4.adb (Complete_Object_Operation): After analyzing the
703         rewritten call, preserve the resulting type to prevent spurious errors,
704         when the call is implicitly dereferenced in the context of an in-out
705         actual.
706
707         * checks.adb (Apply_Discriminant_Check): If the target of the
708         assignment is a renaming of a heap object, create constrained type for
709         it to apply check.
710
711 2010-06-14  Pascal Obry  <obry@adacore.com>
712
713         * prj-proc.adb: Fix copy of object directory for extending projects.
714
715 2010-06-14  Jose Ruiz  <ruiz@adacore.com>
716
717         * init.c (__gnat_alternate_stack): Define this space for PowerPC linux
718         (__gnat_install_handler, PowerPC linux): Activate the alternative
719         signal stack.
720
721 2010-06-13  Gerald Pfeifer  <gerald@pfeifer.com>
722
723         * gnat_rm.texi: Move to GFDL version 1.3.
724         * gnat-style.texi: Ditto.
725         * gnat_ugn.texi: Ditto.
726
727 2010-06-12  Kai Tietz
728
729         PR ada/43731
730         * gcc-interface/Makefile.in: Add rules for multilib x86/x64
731         mingw targets.
732
733 2010-06-11  Alexandre Oliva  <aoliva@redhat.com>
734
735         * gcc-interface/utils.c (update_pointer_to): Initialize last.
736
737 2010-06-09  Eric Botcazou  <ebotcazou@adacore.com>
738
739         * gcc-interface/ada-tree.h: Fix formatting nits.
740
741 2010-06-08  Laurynas Biveinis  <laurynas.biveinis@gmail.com>
742
743         * gcc-interface/utils.c (init_gnat_to_gnu): Use typed GC
744         allocation.
745         (init_dummy_type): Likewise.
746         (gnat_pushlevel): Likewise.
747
748         * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
749         (Subprogram_Body_to_gnu): Likewise.
750         (Compilation_Unit_to_gnu): Likewise.
751         (start_stmt_group): Likewise.
752         (extract_encoding): Likewise.
753         (decode_name): Likewise.
754
755         * gcc-interface/misc.c (gnat_printable_name): Likewise.
756
757         * gcc-interface/decl.c (annotate_value): Likewise.
758
759         * gcc-interface/ada-tree.h (struct lang_type): Add variable_size
760         GTY option.
761         (struct lang_decl): Likewise.
762         (SET_TYPE_LANG_SPECIFIC): Use typed GC allocation.
763         (SET_DECL_LANG_SPECIFIC): Likewise.
764
765 2010-06-04  Eric Botcazou  <ebotcazou@adacore.com>
766
767         * gnatlink.adb (gnatlink): Remove support for -fsjlj switch.
768         * gcc-interface/lang-specs.h: Likewise.
769
770 2010-06-03  H.J. Lu  <hongjiu.lu@intel.com>
771
772         PR c++/44294
773         * gcc-interface/decl.c (MAX_FIXED_MODE_SIZE): Removed.
774
775 2010-06-01  Arnaud Charlet  <charlet@adacore.com>
776
777         * gnat_ugn.texi: Improve doc on -fdump-ada-spec, mention limitations.
778
779 2010-05-30  Eric Botcazou  <ebotcazou@adacore.com>
780
781         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Task_Type>: Reuse the
782         TYPE_DECL of the equivalent type instead of building a new one.
783
784 2010-05-30  Eric Botcazou  <ebotcazou@adacore.com>
785
786         * gcc-interface/decl.c (gnat_to_gnu_entity): Adjust warning message.
787         Fix nits in comments.
788         * gcc-interface/misc.c (gnat_init_gcc_eh): Likewise.
789         * gcc-interface/trans.c (gigi): Likewise.
790         (Attribute_to_gnu): Likewise.
791         (Case_Statement_to_gnu): Likewise.
792         (gnat_to_gnu): Adjust warning message.
793         * gcc-interface/utils.c (create_var_decl_1): Fix nits in comments.
794         (build_vms_descriptor32): Likewise.
795
796 2010-05-27  Steven Bosscher  <steven@gcc.gnu.org>
797
798         * gcc-interface/decl.c: Pretend to be a backend file by undefining
799         IN_GCC_FRONTEND (still need rtl.h here).
800
801 2010-05-26  Steven Bosscher  <steven@gcc.gnu.org>
802
803         * gcc-interface/trans.c: Do not include rtl.h, insclude libfuncs.h.
804         (gigi): Adjust call to set_stack_check_libfunc.
805
806 2010-05-26  Steven Bosscher  <steven@gcc.gnu.org>
807
808         * gcc-interface/utils.c: Do not include rtl.h.
809
810 2010-05-25  Steven Bosscher  <steven@gcc.gnu.org>
811
812         * gcc-interface/utils.c: Do not include function.h, pointer-set.h,
813         and gimple.h.  Explain why rtl.h has to be included.
814         (handle_vector_size_attribute): Call reconstruct_complex_type directly.
815         * gcc-interface/targtyps.c: Do not include tm_p.h
816         * gcc-interface/utils2.c: Do not include flags.h.
817         * gcc-interface/trans.c: Do not include expr.h.  Include rtl.h instead,
818         and explain why it has to be included.
819         * gcc-interface/misc.c: Do not include expr.h, libfuncs.h, cgraph.h,
820         and optabs.h.
821         Include function.h and explain why.  Explain why except.h is included.
822         (enumerate_modes): Remove unused function. 
823         * gcc-interface/gigi.h (enumerate_modes): Remove prototype.
824         * gcc-interface/Make-lang.in: Update dependencies.
825
826 2010-05-25  Joseph Myers  <joseph@codesourcery.com>
827
828         * gcc-interface/misc.c (internal_error_function): Add context
829         parameter.  Use it to access show_column flag and instead of using
830         global_dc.  Call warn_if_plugins.
831         * gcc-interface/Make-lang.in (ada/misc.o): Update dependencies.
832
833 2010-05-19  Eric Botcazou  <ebotcazou@adacore.com>
834
835         * gcc-interface/misc.c (LANG_HOOKS_DEEP_UNSHARING): Redefine.
836         * gcc-interface/trans.c (unshare_save_expr): Delete.
837         (gigi): Do not unshare trees under SAVE_EXPRs here.
838
839 2010-05-18  Nathan Froyd  <froydnj@codesourcery.com>
840
841         * gcc-interface/trans.c (call_to_gnu): Use build_call_vec instead of
842         build_call_list.
843         * gcc-interface/utils.c (build_function_stub): Likewise.
844
845 2010-05-16  Manuel López-Ibáñez  <manu@gcc.gnu.org>
846
847         * gcc-interface/misc.c (gnat_handle_option): Remove special logic
848         for Wuninitialized without -O.
849         
850 2010-05-16  Eric Botcazou  <ebotcazou@adacore.com>
851
852         * gcc-interface/gigi.h (enum standard_datatypes): Add new value
853         ADT_exception_data_name_id.
854         (exception_data_name_id): New define.
855         * gcc-interface/trans.c (gigi): Initialize it.
856         * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Use the standard
857         exception type for standard exception definitions.  Do not make them
858         volatile.
859         <E_Record_Type>: Equate fields of types associated with an exception
860         definition to those of the standard exception type.
861
862 2010-05-13  Andreas Schwab  <schwab@linux-m68k.org>
863
864         * tracebak.c (__gnat_backtrace): Mark top_stack with ATTRIBUTE_UNUSED.
865
866 2010-05-12  Eric Botcazou  <ebotcazou@adacore.com>
867
868         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Tidy up
869         code, improve comments and fix formatting nits.
870
871 2010-05-12  Eric Botcazou  <ebotcazou@adacore.com>
872
873         * gcc-interface/utils.c (update_pointer_to): Return early if the old
874         pointer already points to the new type.  Chain the old pointer and its
875         variants at the end of new pointer's chain after updating them.
876
877 2010-05-10  Eric Botcazou  <ebotcazou@adacore.com>
878
879         * exp_disp.adb (Make_Tags): Mark the imported view of dispatch tables
880         built for interfaces.
881         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Variable>: Use
882         imported_p instead of Is_Imported when considering constants.
883         Do not promote alignment of exported objects.
884         <E_Record_Subtype>: Strip all suffixes for dispatch table entities.
885
886 2010-05-08  Eric Botcazou  <ebotcazou@adacore.com>
887
888         * exp_disp.adb (Make_Tags): Mark the imported view of dispatch tables.
889         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Variable>: Make imported
890         constants really constant.
891         <E_Record_Subtype>: Strip the suffix for dispatch table entities.
892
893 2010-05-08  Eric Botcazou  <ebotcazou@adacore.com>
894
895         * gcc-interface/decl.c (make_aligning_type): Declare the type.
896
897 2010-05-08  Eric Botcazou  <ebotcazou@adacore.com>
898
899         * gcc-interface/decl.c (gnat_to_gnu_entity): Create variables for size
900         expressions of variant part of record types declared at library level.
901
902 2010-05-08  Eric Botcazou  <ebotcazou@adacore.com>
903
904         * gcc-interface/gigi.h (create_field_decl): Move PACKED parameter.
905         * gcc-interface/utils.c (create_field_decl): Move PACKED parameter.
906         (rest_of_record_type_compilation): Adjust call to create_field_decl.
907         (make_descriptor_field): Likewise and pass correctly typed constants.
908         (build_unc_object_type): Likewise.
909         (unchecked_convert): Likewise.
910         * gcc-interface/decl.c (elaborate_expression_2): New static function.
911         (gnat_to_gnu_entity): Use it to make alignment factors explicit.
912         Adjust call to create_field_decl.
913         (make_aligning_type): Likewise.
914         (make_packable_type): Likewise.
915         (maybe_pad_type): Likewise.
916         (gnat_to_gnu_field): Likewise.
917         (components_to_record): Likewise.
918         (create_field_decl_from): Likewise.
919         (create_variant_part_from): Remove superfluous test.
920         * gcc-interface/trans.c (gigi): Adjust call to create_field_decl.
921
922 2010-05-08  Eric Botcazou  <ebotcazou@adacore.com>
923
924         * gcc-interface/gigi.h (build_unc_object_type): Add DEBUG_INFO_P param.
925         (build_unc_object_type_from_ptr): Likewise.
926         * gcc-interface/utils.c (build_unc_object_type): Add DEBUG_INFO_P param
927         and pass it to create_type_decl.  Declare the type.  Simplify.
928         (build_unc_object_type_from_ptr): Add DEBUG_INFO_P parameter and pass
929         it to build_unc_object_type.
930         * gcc-interface/decl.c (gnat_to_gnu_entity): Adjust to above change.
931         * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
932         (gnat_to_gnu): Likewise.
933         * gcc-interface/utils2.c (build_allocator): Likewise.
934
935 2010-05-07 Eric Botcazou  <ebotcazou@adacore.com>
936
937         PR 40989
938         * gcc-interface/misc.c (gnat_handle_option): Fix long line.
939
940 2010-05-06  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
941
942         * gcc-interface/Makefile.in: Removed mips-sgi-irix5* support.
943
944 2010-05-06  Manuel López-Ibáñez  <manu@gcc.gnu.org>
945
946         PR 40989
947         * gcc-interface/misc.c (gnat_handle_option): Add argument kind.
948
949 2010-05-02  Giuseppe Scrivano  <gscrivano@gnu.org>
950
951         * gnathtml.pl: Use 755 as mask for new directories.
952
953 2010-04-28  Eric Botcazou  <ebotcazou@adacore.com>
954
955         * gcc-interface/trans.c (gnat_gimplify_expr) <ADDR_EXPR>: Uniquize
956         constant constructors before taking their address.
957
958 2010-04-25  Eric Botcazou  <ebotcazou@adacore.com>
959
960         * exp_dbug.ads: Fix outdated description.  Mention link between XVS
961         and XVZ objects.
962         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Subtype>: Set
963         XVZ variable as unit size of XVS type.
964         (maybe_pad_type): Likewise.
965
966 2010-04-25  Eric Botcazou  <ebotcazou@adacore.com>
967
968         * gcc-interface/trans.c (gnat_to_gnu) <N_Assignment_Statement>: Do not
969         use memmove if the array type is bit-packed.
970
971 2010-04-18  Eric Botcazou  <ebotcazou@adacore.com>
972
973         * gcc-interface/misc.c (gnat_init): Remove second argument in call to
974         build_common_tree_nodes.
975
976 2010-04-18  Ozkan Sezer  <sezeroz@gmail.com>
977
978         * gsocket.h: Make sure that winsock2.h is included before windows.h.
979
980 2010-04-17  Eric Botcazou  <ebotcazou@adacore.com>
981
982         * gcc-interface/utils2.c (build_unary_op) <ATTR_ADDR_EXPR>: Do not
983         issue warning.
984
985 2010-04-17  Eric Botcazou  <ebotcazou@adacore.com>
986
987         * uintp.h (UI_Lt): Declare.
988         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do the size
989         computation in sizetype.
990         <E_Array_Subtype>: Use unified handling for all index types.  Do not
991         generate MAX_EXPR-based expressions, only COND_EXPR-based ones.  Add
992         bypass for PATs.
993         (annotate_value): Change test for negative values.
994         (validate_size): Apply test for negative values on GNAT nodes.
995         (set_rm_size): Likewise.
996         * gcc-interface/misc.c (gnat_init): Set unsigned types for sizetypes.
997         * gcc-interface/utils.c (rest_of_record_type_compilation): Change test
998         for negative values.
999         (max_size) <MINUS_EXPR>: Do not reassociate a COND_EXPR on the LHS.
1000         (builtin_type_for_size): Adjust definition of signed_size_type_node.
1001         * gcc-interface/utils2.c (compare_arrays): Optimize comparison of
1002         lengths against zero.
1003
1004 2010-04-17  Eric Botcazou  <ebotcazou@adacore.com>
1005
1006         * back-end.adb (Call_Back_End): Pass Standard_Character to gigi.
1007         * gcc-interface/gigi.h (gigi): Add standard_character parameter.
1008         (CHAR_TYPE_SIZE, SHORT_TYPE_SIZE, INT_TYPE_SIZE, LONG_TYPE_SIZE, 
1009         LONG_LONG_TYPE_SIZE, FLOAT_TYPE_SIZE, DOUBLE_TYPE_SIZE,
1010         LONG_DOUBLE_TYPE_SIZE, SIZE_TYPE): Delete.
1011         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Subtype>: Call
1012         rm_size.
1013         * gcc-interface/misc.c (gnat_init): Set signedness of char as per
1014         flag_signed_char.  Tag sizetype with "size_type" moniker.
1015         * gcc-interface/trans.c (gigi): Add standard_character parameter.
1016         Remove useless built-in types.  Equate unsigned_char_type_node to
1017         Standard.Character.  Use it instead of char_type_node throughout.
1018         (Attribute_to_gnu): Likewise.
1019         (gnat_to_gnu): Likewise.
1020         * gcc-interface/utils2.c (build_call_raise): Likewise.
1021
1022 2010-04-17  Eric Botcazou  <ebotcazou@adacore.com>
1023
1024         * gcc-interface/gigi.h (enum standard_datatypes): Add new values
1025         ADT_sbitsize_one_node and ADT_sbitsize_unit_node.
1026         (sbitsize_one_node): New macro.
1027         (sbitsize_unit_node): Likewise.
1028         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Subtype>: Fix
1029         latent bug in the computation of subrange_p.  Fold wider_p predicate.
1030         (cannot_be_superflat_p): Use an explicitly signed 64-bit type to do
1031         the final comparison.
1032         (make_aligning_type): Build real negation and use sizetype throughout
1033         the offset computation.
1034         (maybe_pad_type): Do not issue the warning when the new size expression
1035         is too complex.
1036         (annotate_value) <INTEGER_CST>: Simplify code handling negative values.
1037         * gcc-interface/misc.c (gnat_init): Initialize sbitsize_one_node and
1038         sbitsize_unit_node.
1039         * gcc-interface/trans.c (Attribute_to_gnu) <Attr_Pool_Address>: Fold
1040         double negation.
1041         (gnat_to_gnu) <N_Free_Statement>: Likewise.
1042         * gcc-interface/utils.c (convert): Use sbitsize_unit_node.
1043         * gcc-interface/utils2.c (compare_arrays): Compute real lengths and use
1044         constants in sizetype.  Remove dead code and tweak comments.  Generate
1045         equality instead of inequality comparisons for zero length tests.
1046
1047 2010-04-16  Eric Botcazou  <ebotcazou@adacore.com>
1048
1049         * gcc-interface/gigi.h (gnat_init_decl_processing): Delete.
1050         * gcc-interface/decl.c (gnat_to_gnu_entity): Constify a few variables.
1051         <object>: Do not create the fake PARM_DECL if no debug info is needed.
1052         Do not create the corresponding VAR_DECL of a CONST_DECL for debugging
1053         purposes if no debug info is needed.
1054         Fix formatting.  Reorder and add comments.
1055         * gcc-interface/trans.c (gnat_to_gnu) <N_Attribute_Reference>: Constify
1056         variable and remove obsolete comment.
1057         * gcc-interface/utils.c (convert_vms_descriptor64): Tweak comment.
1058         (convert_vms_descriptor32): Likewise.
1059         (convert): Remove dead code.
1060         <UNCONSTRAINED_ARRAY_REF>: Pass the field instead of its name to build
1061         the reference to the P_ARRAY pointer.
1062         <POINTER_TYPE>: Likewise.
1063         (maybe_unconstrained_array) <UNCONSTRAINED_ARRAY_TYPE>: Likewise.
1064         (gnat_init_decl_processing): Delete, move contents to...
1065         * gcc-interface/misc.c (gnat_init): ...here.
1066
1067 2010-04-16  Eric Botcazou  <ebotcazou@adacore.com>
1068
1069         * gcc-interface/trans.c (unchecked_conversion_nop): Handle function
1070         calls.  Return true for conversion from a record subtype to its type.
1071
1072 2010-04-16  Eric Botcazou  <ebotcazou@adacore.com>
1073
1074         * gcc-interface/decl.c (gnat_to_gnu_entity): Use boolean_type_node in
1075         lieu of integer_type_node for boolean operations.
1076         (choices_to_gnu): Likewise.
1077         * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
1078         (Loop_Statement_to_gnu): Likewise.
1079         (establish_gnat_vms_condition_handler): Likewise.
1080         (Exception_Handler_to_gnu_sjlj): Likewise.
1081         (gnat_to_gnu): Likewise.
1082         (build_unary_op_trapv): Likewise.
1083         (build_binary_op_trapv): Likewise.
1084         (emit_range_check): Likewise.
1085         (emit_index_check): Likewise.
1086         (convert_with_check): Likewise.
1087         * gcc-interface/utils.c (convert_vms_descriptor64): Likewise.
1088         (convert_vms_descriptor32): Likewise.
1089         (convert_vms_descriptor): Likewise.
1090         * gcc-interface/utils2.c (nonbinary_modular_operation): Likewise.
1091         (compare_arrays): Use boolean instead of integer constants.
1092         (build_binary_op) <TRUTH_ANDIF_EXPR, TRUTH_ORIF_EXPR, TRUTH_AND_EXPR,
1093         TRUTH_OR_EXPR, TRUTH_XOR_EXPR>: New case.  Check that the result type
1094         is a boolean type.
1095         <GE_EXPR, LE_EXPR, GT_EXPR, LT_EXPR>: Remove obsolete assertion.
1096         <EQ_EXPR, NE_EXPR>: Check that the result type is a boolean type.
1097         <PREINC/PREDECREMENT_EXPR, POSTINC/POSTDECREMENT_EXPR>: Delete.
1098         <TRUTH_NOT_EXPR>: Check that the result type is a boolean type.
1099         (build_unary_op): Use boolean_type_node in lieu of integer_type_node
1100         for boolean operations.
1101         (fill_vms_descriptor): Likewise.  Fix formatting nits.
1102
1103 2010-04-16  Eric Botcazou  <ebotcazou@adacore.com>
1104
1105         * gcc-interface/ada-tree.def (LOOP_STMT): Change to 4-operand nodes.
1106         * gcc-interface/ada-tree.h (LOOP_STMT_TOP_COND, LOOP_STMT_BOT_COND):
1107         Merge into...
1108         (LOOP_STMT_COND): ...this.
1109         (LOOP_STMT_BOTTOM_COND_P): New flag.
1110         (LOOP_STMT_TOP_UPDATE_P): Likewise.
1111         * gcc-interface/trans.c (can_equal_min_or_max_val_p): New function.
1112         (can_equal_min_val_p): New static inline function.
1113         (can_equal_max_val_p): Likewise.
1114         (Loop_Statement_to_gnu): Use build4 in lieu of build5 and adjust to
1115         new LOOP_STMT semantics.  Use two different strategies depending on
1116         whether optimization is enabled to translate the loop.
1117         (gnat_gimplify_stmt) <LOOP_STMT>: Adjust to new LOOP_STMT semantics.
1118
1119 2010-04-16  Eric Botcazou  <ebotcazou@adacore.com>
1120
1121         * uintp.adb (UI_From_Dint): Remove useless code.
1122         (UI_From_Int): Likewise.
1123         * uintp.h: Reorder declarations.
1124         (UI_From_gnu): Declare.
1125         (UI_Base): Likewise.
1126         (Vector_Template): Likewise.
1127         (Vector_To_Uint): Likewise.
1128         (Uint_0): Remove.
1129         (Uint_1): Likewise.
1130         * gcc-interface/gigi.h: Tweak comments.
1131         * gcc-interface/cuintp.c (UI_From_gnu): New global function.
1132         * gcc-interface/decl.c (maybe_pad_type): Do not warn if either size
1133         overflows.
1134         (annotate_value) <INTEGER_CST>: Call UI_From_gnu.
1135         * gcc-interface/trans.c (post_error_ne_num): Call post_error_ne.
1136         (post_error_ne_tree): Call UI_From_gnu and post_error_ne.
1137         * gcc-interface/utils.c (max_size) <tcc_binary>: Do not special-case
1138         TYPE_MAX_VALUE.
1139
1140 2010-04-16  Eric Botcazou  <ebotcazou@adacore.com>
1141
1142         * gcc-interface/decl.c (make_type_from_size) <INTEGER_TYPE>: Just copy
1143         TYPE_NAME.
1144         * gcc-interface/trans.c (smaller_packable_type_p): Rename into...
1145         (smaller_form_type_p): ...this.  Change parameter and variable names.
1146         (call_to_gnu): Use the nominal type of the parameter to create the
1147         temporary if it's a smaller form of the actual type.
1148         (addressable_p): Return false if the actual type is integral and its
1149         size is greater than that of the expected type.
1150
1151 2010-04-15  Eric Botcazou  <ebotcazou@adacore.com>
1152
1153         * gcc-interface/cuintp.c (UI_To_gnu): Fix long line.
1154         * gcc-interface/gigi.h (MARK_VISITED): Skip objects of constant class.
1155         (process_attributes): Delete.
1156         (post_error_ne_num): Change parameter name.
1157         * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force debug info
1158         with -g3.  Remove a couple of obsolete lines.  Minor tweaks.
1159         If type annotating mode, operate on trees to compute the adjustment to
1160         the sizes of tagged types.  Fix long line.
1161         (cannot_be_superflat_p): Tweak head comment.
1162         (annotate_value): Fold local constant.
1163         (set_rm_size): Fix long line.
1164         * gcc-interface/trans.c (Identifier_to_gnu): Rework comments.
1165         (Attribute_to_gnu): Fix long line.
1166         <Attr_Size>: Remove useless assertion.
1167         Reorder statements.  Use size_binop routine.
1168         (Loop_Statement_to_gnu): Use build5 in lieu of build_nt.
1169         Create local variables for the label and the test.  Tweak comments.
1170         (Subprogram_Body_to_gnu): Reset cfun to NULL.
1171         (Compilation_Unit_to_gnu): Use the Sloc of the Unit node.
1172         (process_inlined_subprograms): Integrate into...
1173         (Compilation_Unit_to_gnu): ...this.
1174         (gnat_to_gnu): Fix long line.
1175         (post_error_ne_num): Change parameter name.
1176         * gcc-interface/utils.c (process_attributes): Static-ify.
1177         <ATTR_MACHINE_ATTRIBUTE>: Set input_location before proceeding.
1178         (create_type_decl): Add comment.
1179         (create_var_decl_1): Process the attributes after adding the VAR_DECL
1180         to the current binding level.
1181         (create_subprog_decl): Likewise for the FUNCTION_DECL.
1182         (end_subprog_body): Do not reset cfun to NULL.
1183         (build_vms_descriptor32): Fix long line.
1184         (build_vms_descriptor): Likewise.
1185         (handle_nonnull_attribute): Likewise.
1186         (convert_vms_descriptor64): Likewise.
1187         * gcc-interface/utils2.c (fill_vms_descriptor): Fix long line.
1188         (gnat_protect_expr): Fix thinko.
1189
1190 2010-04-15  Eric Botcazou  <ebotcazou@adacore.com>
1191
1192         * gcc-interface/trans.c (gigi): Set DECL_IGNORED_P on EH functions.
1193         (gnat_to_gnu) <N_Op_Eq>: Restore the value of input_location
1194         before translating the top-level node.
1195         (lvalue_required_p) <N_Function_Call>: Return 1 if !constant.
1196         <N_Object_Declaration>: Likewise.
1197         <N_Assignment_Statement>: Likewise.
1198         <N_Unchecked_Type_Conversion>: Likewise.
1199         (call_to_gnu): Remove kludge.
1200         (gnat_to_gnu) <N_Return_Statement>: When not optimizing, force labels
1201         associated with user returns to be preserved.
1202         (gnat_to_gnu): Add special code to deal with boolean rvalues.
1203         * gcc-interface/utils2.c (compare_arrays): Set input_location on all
1204         comparisons.
1205         (build_unary_op) <ADDR_EXPR>: Call build_fold_addr_expr.
1206         <INDIRECT_REF>: Call build_fold_indirect_ref.
1207
1208 2010-04-15  Joel Sherrill  <joel.sherrill@oarcorp.com>
1209
1210         * g-socket.adb: A target can have multiple missing errno's.  This
1211         will result in multiple errno's being defined as -1.  Because of this
1212         we can not use a case but must use a series of if's to avoid 
1213         a duplicate case error in GNAT.Sockets.Resolve_Error.
1214
1215 2010-04-15  Eric Botcazou  <ebotcazou@adacore.com>
1216
1217         * gcc-interface/trans.c (call_to_gnu): Open a nesting level if this is
1218         a statement.  Otherwise, if at top-level, push the processing of the
1219         elaboration routine.  In the misaligned case, issue the error messages
1220         again on entry and create the temporary explicitly.  Do not issue them
1221         for CONSTRUCTORs.
1222         For a function call, emit the range check if necessary.
1223         In the copy-in copy-out case, create the temporary for the return
1224         value explicitly.
1225         Do not unnecessarily convert by-ref parameters to the formal's type.
1226         Remove obsolete guards in conditions.
1227         (gnat_to_gnu) <N_Assignment_Statement>: For a function call, pass the
1228         target to call_to_gnu in all cases.
1229         (gnat_gimplify_expr) <ADDR_EXPR>: Remove handling of SAVE_EXPR.
1230         (addressable_p) <CONSTRUCTOR>: Return false if not static.
1231         <COMPOUND_EXPR>: New case.
1232         * gcc-interface/utils2.c (build_unary_op) <ADDR_EXPR>: Fold a compound
1233         expression if it has unconstrained array type.
1234         (gnat_mark_addressable) <COMPOUND_EXPR>: New case.
1235         (gnat_stabilize_reference) <COMPOUND_EXPR>: Stabilize operands on an
1236         individual basis.
1237
1238 2010-04-15  Eric Botcazou  <ebotcazou@adacore.com>
1239
1240         * gcc-interface/trans.c (gigi): Do not start statement group.
1241         (Compilation_Unit_to_gnu): Set current_function_decl to NULL.
1242         Start statement group and push binding level here...
1243         (gnat_to_gnu) <N_Compilation_Unit>: ...and not here.
1244         Do not push fake contexts at top level.  Remove redundant code.
1245         (call_to_gnu): Rename a local variable and constify another.
1246         * gcc-interface/utils.c (gnat_pushlevel): Fix formatting nits.
1247         (set_current_block_context): Set it as the group's block.
1248         (gnat_init_decl_processing): Delete unrelated init code.
1249         (end_subprog_body): Use NULL_TREE.
1250
1251 2010-04-15  Eric Botcazou  <ebotcazou@adacore.com>
1252
1253         * gcc-interface/trans.c (call_to_gnu): Do not unnecessarily force
1254         side-effects of actual parameters before the call.
1255
1256 2010-04-15  Eric Botcazou  <ebotcazou@adacore.com>
1257
1258         * gcc-interface/decl.c (validate_size): Reorder, remove obsolete test
1259         and warning.
1260         (set_rm_size): Reorder and remove obsolete test.
1261
1262 2010-04-14  Eric Botcazou  <ebotcazou@adacore.com>
1263
1264         * gcc-interface/gigi.h: Reorder declarations and tweak comments.
1265         (gigi): Adjust ATTRIBUTE_UNUSED markers.
1266         * gcc-interface/gadaint.h: New file.
1267         * gcc-interface/trans.c: Include it in lieu of adaint.h.  Reorder.
1268         (__gnat_to_canonical_file_spec): Remove declaration.
1269         (number_names): Delete.
1270         (number_files): Likewise.
1271         (gigi): Adjust.
1272         * gcc-interface/Make-lang.in (ada/trans.o): Adjust dependencies to
1273         above change.
1274
1275 2010-04-14  Eric Botcazou  <ebotcazou@adacore.com>
1276
1277         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Class_Wide_Type>: Fix
1278         comment.
1279         * gcc-interface/trans.c (process_freeze_entity): Use local copy of
1280         Ekind.  Return early for class-wide types.  Do not compute initializer
1281         unless necessary.  Reuse the tree for an associated class-wide type
1282         only if processing its root type.
1283
1284 2010-04-13  Joel Sherrill  <joel.sherrill@oarcorp.com>
1285
1286         * gsocket.h: Run-time can no longer be built without network
1287         OS headers available.  Changing RTEMS GNAT build procedure to
1288         reflect this and letting run-time build use network .h files.
1289
1290 2010-04-13  Duncan Sands  <baldrick@free.fr>
1291
1292         * gcc-interface/misc.c (gnat_eh_type_covers): Remove.
1293         * gcc-interface/trans.c (Exception_Handler_to_gnu_zcx): Update comment.
1294
1295 2010-04-13  Eric Botcazou  <ebotcazou@adacore.com>
1296
1297         * gcc-interface/gigi.h (standard_datatypes): Add ADT_parent_name_id.
1298         (parent_name_id): New macro.
1299         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Type>: Use it.
1300         * gcc-interface/trans.c (gigi): Initialize it.
1301         (lvalue_required_p) <N_Type_Conversion>: New case.
1302         <N_Qualified_Expression>: Likewise.
1303         <N_Allocator>: Likewise.
1304         * gcc-interface/utils.c (convert): Try to properly upcast tagged types.
1305
1306 2010-04-13  Eric Botcazou  <ebotcazou@adacore.com>
1307
1308         * gcc-interface/ada-tree.h (TYPE_BY_REFERENCE_P): Delete.
1309         (DECL_CONST_ADDRESS_P): New macro.
1310         (SET_DECL_ORIGINAL_FIELD_TO_FIELD): Likewise.
1311         (SAME_FIELD_P): Likewise.
1312         * gcc-interface/decl.c (constructor_address_p): New static function.
1313         (gnat_to_gnu_entity) <object>: Set DECL_CONST_ADDRESS_P according to
1314         the return value of above function.
1315         (gnat_to_gnu_entity) <E_Record_Type>: Force BLKmode for all types
1316         passed by reference.
1317         <E_Record_Subtype>: Likewise.
1318         Set TREE_ADDRESSABLE on the type if it passed by reference.
1319         (make_packable_type): Use SET_DECL_ORIGINAL_FIELD_TO_FIELD.
1320         (create_field_decl_from): Likewise.
1321         (substitute_in_type): Likewise.
1322         (purpose_member_field): Use SAME_FIELD_P.
1323         * gcc-interface/misc.c (must_pass_by_ref): Test TREE_ADDRESSABLE.
1324         * gcc-interface/trans.c (lvalue_required_p): Add ADDRESS_OF_CONSTANT
1325         parameter and adjust recursive calls.
1326         <N_Explicit_Dereference>: New case.
1327         <N_Object_Declaration>: Return 1 if the object is of a class-wide type.
1328         Adjust calls to lvalue_required_p.  Do not return the initializer of a
1329         DECL_CONST_ADDRESS_P constant if an lvalue is required for it.
1330         (call_to_gnu): Delay issuing error message for a misaligned actual and
1331         avoid the associated back-end assertion.  Test TREE_ADDRESSABLE.
1332         (gnat_gimplify_expr) <ADDR_EXPR>: Handle non-static constructors.
1333         * gcc-interface/utils.c (make_dummy_type): Set TREE_ADDRESSABLE if the
1334         type is passed by reference.
1335         (convert) <CONSTRUCTOR>: Convert in-place in more cases.
1336         * gcc-interface/utils2.c (build_cond_expr): Drop TYPE_BY_REFERENCE_P.
1337         (build_simple_component_ref): Use SAME_FIELD_P.
1338
1339 2010-04-12  Eric Botcazou  <ebotcazou@adacore.com>
1340
1341         * gcc-interface/trans.c (Identifier_to_gnu): Use boolean variable.
1342         (call_to_gnu): Test gigi's flag TYPE_BY_REFERENCE_P instead of calling
1343         front-end's predicate Is_By_Reference_Type.  Use consistent order and
1344         remove ??? comment.  Use original conversion in all cases, if any.
1345         * gcc-interface/utils.c (make_dummy_type): Minor tweak.
1346         (convert): Use local copy in more cases.
1347         <INDIRECT_REF>: Remove deactivated code.
1348         (unchecked_convert): Use a couple of local copies.
1349
1350 2010-04-11  Eric Botcazou  <ebotcazou@adacore.com>
1351
1352         * gcc-interface/trans.c (lvalue_required_for_attribute_p): New static
1353         function.
1354         (lvalue_required_p) <N_Attribute_Reference>: Call it.
1355         (gnat_to_gnu) <N_Selected_Component>: Prevent build_component_ref from
1356         folding the result only if lvalue_required_for_attribute_p is true.
1357         * gcc-interface/utils.c (maybe_unconstrained_array): Pass correctly
1358         typed constant to build_component_ref.
1359         (unchecked_convert): Likewise.
1360         * gcc-interface/utils2.c (maybe_wrap_malloc): Likewise.
1361         (build_allocator): Likewise.
1362
1363 2010-04-11  Eric Botcazou  <ebotcazou@adacore.com>
1364
1365         * gcc-interface/utils2.c (build_cond_expr): Take the address and
1366         dereference if the result type is passed by reference.
1367
1368 2010-04-11  Eric Botcazou  <ebotcazou@adacore.com>
1369
1370         * gcc-interface/trans.c (Case_Statement_to_gnu): Bool-ify variable.
1371         (gnat_to_gnu) <N_Null_Statement>: When not optimizing, generate a
1372         goto to the next statement.
1373
1374 2010-04-09  Eric Botcazou  <ebotcazou@adacore.com>
1375
1376         * gcc-interface/gigi.h (maybe_variable): Delete.
1377         (protect_multiple_eval): Likewise.
1378         (maybe_stabilize_reference): Likewise.
1379         (gnat_save_expr): Declare.
1380         (gnat_protect_expr): Likewise.
1381         (gnat_stabilize_reference): Likewise.
1382         * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Use
1383         gnat_stabilize_reference.
1384         (maybe_variable): Delete.
1385         (elaborate_expression_1): Use gnat_save_expr.
1386         * gcc-interface/trans.c (Attribute_to_gnu): Use gnat_protect_expr.
1387         (call_to_gnu): Pass NULL to gnat_stabilize_reference.
1388         (gnat_to_gnu) <N_Object_Declaration>: Use gnat_save_expr.
1389         <N_Slice>: Use gnat_protect_exp.
1390         <N_Selected_Component>: Pass NULL to gnat_stabilize_reference.
1391         <N_In>: Use gnat_protect_expr.
1392         Pass NULL to gnat_stabilize_reference.
1393         (build_unary_op_trapv): Use gnat_protect_expr.
1394         (build_binary_op_trapv): Likewise.
1395         (emit_range_check): Likewise.
1396         (emit_index_check): Likewise.
1397         (convert_with_check): Likewise.
1398         (protect_multiple_eval): Move to utils2.c file.
1399         (maybe_stabilize_reference): Merge into...
1400         (gnat_stabilize_reference): ...this.  Move to utils2.c file.
1401         (gnat_stabilize_reference_1): Likewise.
1402         * gcc-interface/utils.c (convert_to_fat_pointer): Use gnat_protect_expr
1403         instead of protect_multiple_eval.
1404         * gcc-interface/utils2.c (compare_arrays): Likewise.
1405         (nonbinary_modular_operation): Likewise.
1406         (maybe_wrap_malloc): Likewise.
1407         (build_allocator): Likewise.
1408         (gnat_save_expr): New function.
1409         (gnat_protect_expr): Rename from protect_multiple_eval.  Early return
1410         in common cases.  Propagate TREE_READONLY onto dereferences.
1411         (gnat_stabilize_reference_1): Move from trans.c file.
1412         (gnat_stabilize_reference): Likewise.
1413
1414 2010-04-09  Eric Botcazou  <ebotcazou@adacore.com>
1415
1416         * gcc-interface/gigi.h (gnat_mark_addressable): Rename parameter.
1417         * gcc-interface/decl.c (maybe_variable): Do not set TREE_STATIC on _REF
1418         node.  Use the type of the operand to set TREE_READONLY.
1419         * gcc-interface/trans.c (Identifier_to_gnu): Do not set TREE_STATIC on
1420         _REF node.  Do not overwrite TREE_READONLY.
1421         (call_to_gnu): Rename local variable and fix various nits.  In the
1422         copy-in/copy-out case, build the SAVE_EXPR manually.
1423         (convert_with_check): Call protect_multiple_eval in lieu of save_expr
1424         and fold the computations.
1425         (protect_multiple_eval): Always save entire fat pointers.
1426         (maybe_stabilize_reference): Minor tweaks.
1427         (gnat_stabilize_reference_1): Likewise.  Do not deal with tcc_constant,
1428         tcc_type and tcc_statement.
1429         * gcc-interface/utils.c (convert_to_fat_pointer): Call
1430         protect_multiple_eval in lieu of save_expr.
1431         (convert): Minor tweaks.
1432         (maybe_unconstrained_array): Do not set TREE_STATIC on _REF node.
1433         (builtin_type_for_size): Call gnat_type_for_size directly.
1434         * gcc-interface/utils2.c (contains_save_expr_p): Delete.
1435         (contains_null_expr): Likewise
1436         (gnat_build_constructor): Do not call it.
1437         (compare_arrays): Deal with all side-effects, use protect_multiple_eval
1438         instead of gnat_stabilize_reference to protect the operands.
1439         (nonbinary_modular_operation): Call protect_multiple_eval in lieu of
1440         save_expr.
1441         (maybe_wrap_malloc): Likewise.
1442         (build_allocator): Likewise.
1443         (build_unary_op) <INDIRECT_REF>: Do not set TREE_STATIC on _REF node.
1444         (gnat_mark_addressable): Rename parameter.
1445
1446 2010-04-08  Eric Botcazou  <ebotcazou@adacore.com>
1447
1448         * gcc-interface/ada-tree.h (TYPE_RETURNS_UNCONSTRAINED_P): Rename into.
1449         (TYPE_RETURN_UNCONSTRAINED_P): ...this.
1450         (TYPE_RETURNS_BY_REF_P): Rename into.
1451         (TYPE_RETURN_BY_DIRECT_REF_P): ...this.
1452         (TYPE_RETURNS_BY_TARGET_PTR_P): Delete.
1453         * gcc-interface/gigi.h (create_subprog_type): Adjust parameter names.
1454         (build_return_expr): Likewise.
1455         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>:
1456         Rename local variables.  If the return Mechanism is By_Reference, pass
1457         return_by_invisible_ref_p to create_subprog_type instead of toggling
1458         TREE_ADDRESSABLE.  Test return_by_invisible_ref_p in order to annotate
1459         the mechanism.  Use regular return for contrained types with non-static
1460         size and return by invisible reference for unconstrained return types
1461         with default discriminants.  Update comment.
1462         * gcc-interface/trans.c (Subprogram_Body_to_gnu): If the function
1463         returns by invisible reference, turn the RESULT_DECL into a pointer.
1464         Do not handle DECL_BY_REF_P in the CICO case here.
1465         (call_to_gnu): Remove code handling return by target pointer.  For a
1466         function call, if the return type has non-constant size, generate the
1467         assignment with an INIT_EXPR.
1468         (gnat_to_gnu) <N_Return_Statement>: Remove dead code in the CICO case.
1469         If the function returns by invisible reference, build the copy return
1470         operation manually.
1471         (add_decl_expr): Initialize the variable with an INIT_EXPR.
1472         * gcc-interface/utils.c (create_subprog_type): Adjust parameter names.
1473         Adjust for renaming of macros.  Copy the node only when necessary.
1474         (create_subprog_decl): Do not toggle TREE_ADDRESSABLE on the return
1475         type, only change DECL_BY_REFERENCE on the RETURN_DECL.
1476         (convert_from_reference): Delete.
1477         (is_byref_result): Likewise.
1478         (gnat_genericize_r): Likewise.
1479         (gnat_genericize): Likewise.
1480         (end_subprog_body): Do not call gnat_genericize.
1481         * gcc-interface/utils2.c (build_binary_op) <INIT_EXPR>: New case.
1482         (build_return_expr): Adjust parameter names, logic and comment.
1483
1484 2010-04-07  Eric Botcazou  <ebotcazou@adacore.com>
1485
1486         * exp_pakd.adb (Create_Packed_Array_Type): Always use a modular type
1487         if the size is small enough.  Propagate the alignment if there is an
1488         alignment clause on the original array type.
1489         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Modular_Integer_Subtype>
1490         Deal with under-aligned packed array types.  Copy the size onto the
1491         justified modular type and don't lay it out again.  Likewise for the
1492         padding type built for other under-aligned subtypes.
1493         * gcc-interface/utils.c (finish_record_type): Do not set a default mode
1494         on the type.
1495
1496 2010-04-07  Eric Botcazou  <ebotcazou@adacore.com>
1497
1498         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set default
1499         alignment on the RETURN type built for the Copy-In Copy-Out mechanism.
1500
1501 2010-04-07  Eric Botcazou  <ebotcazou@adacore.com>
1502
1503         * gcc-interface/trans.c (call_to_gnu): In the return-by-target-ptr case
1504         do not set the result type if there is a specified target and do not
1505         convert the result in any cases.
1506         (protect_multiple_eval): Make direct SAVE_EXPR for CALL_EXPR.
1507         (maybe_stabilize_reference) <COMPOUND_EXPR>: Merge with CALL_EXPR.
1508
1509 2010-03-10  Eric Botcazou  <ebotcazou@adacore.com>
1510
1511         * gcc-interface/Makefile.in (SPARC/Solaris): Use sparcv8plus.
1512
1513 2010-02-27  Eric Botcazou  <ebotcazou@adacore.com>
1514
1515         PR ada/42253
1516         * gcc-interface/utils2.c (build_binary_op) <EQ_EXPR>: Assert that fat
1517         pointer base types are variant of each other.  Apply special treatment
1518         for null to fat pointer types in all cases.
1519
1520 2010-01-28  Pascal Obry  <obry@adacore.com>
1521
1522         * s-win32.ads: Add some missing constants.
1523
1524 2010-01-28  Vincent Celier  <celier@adacore.com>
1525
1526         * prj-attr-pm.adb (Add_Attribute): Do nothing if To_Package is
1527         Unknown_Package.
1528
1529 2010-01-28  Robert Dewar  <dewar@adacore.com>
1530
1531         * gnat_rm.texi: Minor correction
1532
1533 2010-01-27  Pascal Obry  <obry@adacore.com>
1534
1535         * g-awk.adb: ensure that an AWK session is reusable.
1536
1537 2010-01-27  Vasiliy Fofanov  <fofanov@adacore.com>
1538
1539         * g-regist.adb (For_Every_Key): Fix previous change.
1540         Minor reformatting.
1541
1542 2010-01-27  Thomas Quinot  <quinot@adacore.com>
1543
1544         * lib-writ.ads: Current version of spec for new N (note) ALI lines
1545
1546 2010-01-27  Yannick Moy  <moy@adacore.com>
1547
1548         * a-cdlili.adb (Insert): Correct exception message when cursor
1549         designates wrong list.
1550
1551 2010-01-27  Vincent Celier  <celier@adacore.com>
1552
1553         * gnatcmd.adb: When there is only one main specified, the package
1554         support Switches (<main>) and attribute Switches is specified for the
1555         main, use these switches, instead of Default_Switches ("Ada").
1556
1557 2010-01-27  Robert Dewar  <dewar@adacore.com>
1558
1559         * sem_prag.adb, par-prag.adb, snames.ads-tmpl: pragma Dimension initial
1560         implementation.
1561         * exp_disp.adb: Minor reformatting
1562
1563 2010-01-27  Tristan Gingold  <gingold@adacore.com>
1564
1565         * seh_init.c: Use __ImageBase instead of _ImageBase.
1566
1567 2010-01-27  Javier Miranda  <miranda@adacore.com>
1568
1569         * exp_disp.ads, exp_disp.adb (Expand_Interface_Thunk): Modify the
1570         profile of interface thunks. The type of the controlling formal is now
1571         the covered interface type (instead of the target tagged type).
1572
1573 2010-01-27  Sergey Rybin  <rybin@adacore.com>
1574
1575         * gnat_rm.texi, gnat_ugn.texi: Update gnatcheck doc.
1576
1577 2010-01-27  Robert Dewar  <dewar@adacore.com>
1578
1579         * sinput.ads, sinput.adb (Sloc_Range): Applies to all nodes, formal
1580         changed from Expr to N.
1581
1582 2010-01-26  Thomas Quinot  <quinot@adacore.com>
1583
1584         * gnat_ugn.texi: Adjust documentation of -gnatz switches.
1585         * usage.adb: Replace line for -gnatz with two lines for -gnatzc and
1586         -gnatzr.
1587
1588 2010-01-26  Vincent Celier  <celier@adacore.com>
1589
1590         * prj-attr.adb: Add new attribute Library_Install_Name_Option
1591         Replace attribute Run_Path_Origin_Supported with Run_Path_Origin
1592         * prj-nmsc.adb (Process_Project_Level_Simple_Attributes): Process
1593         attributes Run_Path_Option and Library_Install_Name_Option.
1594         * prj.ads (Project_Configuration): Replace component
1595         Run_Path_Origin_Supported with component Run_Path_Origin. Add new
1596         component Library_Install_Name_Option.
1597         * snames.ads-tmpl: Add new standard name Library_Install_Name_Option
1598         Replace Run_Path_Origin_Supported with Run_Path_Origin
1599
1600 2010-01-26  Ed Schonberg  <schonberg@adacore.com>
1601
1602         * sem_ch8.adb (Use_One_Package): Within an instance, an actual package
1603         is not hidden by a homograph declared in another actual package.
1604
1605 2010-01-26  Robert Dewar  <dewar@adacore.com>
1606
1607         * par_sco.adb (Traverse_Declarations_Or_Statements): Only generate
1608         decisions for pragmas Assert, Check, Precondition, Postcondition if
1609         -gnata set.
1610         * scos.ads: Update comments.
1611         * get_scos.adb, put_scos.adb: Minor fix to code reading statement SCOs.
1612         Also remove obsolete code for CT (exit point) SCOs.
1613
1614 2010-01-26  Thomas Quinot  <quinot@adacore.com>
1615
1616         * switch-c.adb: Fix handling of -gnatz*
1617
1618 2010-01-26  Robert Dewar  <dewar@adacore.com>
1619
1620         * par_sco.adb (Traverse_Declarations_Or_Statements): Separate F/W
1621         qualifiers for FOR/WHILE loops
1622         * scos.ads: Use separate type letters F/W for for/while loops
1623
1624 2010-01-26  Robert Dewar  <dewar@adacore.com>
1625
1626         * get_scos.adb (Get_SCOs): Implement new form of CS entries (multiple
1627         entries per line, one for each statement in the sequence).
1628         * par_sco.adb (Traverse_Declarations_Or_Statements): Increase array
1629         size from 100 to 10_000 for SC_Array to avoid any real possibility of
1630         overflow. Output decisions in for loops.
1631         Exclude labels from CS lines.
1632         * scos.ads: Clarify that label is not included in the entry point
1633
1634 2010-01-26  Robert Dewar  <dewar@adacore.com>
1635
1636         * par_sco.adb (Traverse_Declarations_Or_Statments): Implement new
1637         format of statement sequence SCO entries (one location/statement).
1638         * put_scos.adb (Put_SCOs): Implement new format of CS lines
1639         * scos.ads: Update comments.
1640         * sem_eval.adb: Minor reformatting.
1641
1642 2010-01-26  Robert Dewar  <dewar@adacore.com>
1643
1644         * par_sco.ads, par_sco.adb (Set_Statement_Entry): New handling of exits
1645         (Extend_Statement_Sequence): New procedures
1646         (Traverse_Declarations_Or_Statements): New handling for exits.
1647
1648 2010-01-26  Robert Dewar  <dewar@adacore.com>
1649
1650         * par_sco.adb (Traverse_Declarations_Or_Statements): Add processing for
1651         Case.
1652
1653 2010-01-26  Robert Dewar  <dewar@adacore.com>
1654
1655         * par_sco.adb (Is_Logical_Operator): Exclude AND/OR/XOR
1656         * scos.ads: Clarify handling of logical operators
1657
1658 2010-01-26  Arnaud Charlet  <charlet@adacore.com>
1659
1660         * s-tpoben.adb: Update comments.
1661
1662 2010-01-26  Robert Dewar  <dewar@adacore.com>
1663
1664         * freeze.adb (Set_Small_Size): Don't set size if alignment clause
1665         present.
1666
1667 2010-01-26  Robert Dewar  <dewar@adacore.com>
1668
1669         * scos.ads: Clean up documentation, remove obsolete XOR references
1670 2010-01-26  Vincent Celier  <celier@adacore.com>
1671
1672         * gnat_ugn.texi: Complete documentation on the restrictions for
1673         combined options in -gnatxxx switches.
1674         Fix typo.
1675
1676 2010-01-26  Arnaud Charlet  <charlet@adacore.com>
1677
1678         * s-tpoben.adb (Initialize_Protection_Entries): If a PO is created from
1679         a controlled operation, abort is already deferred at this point, so we
1680         need to use Defer_Abort_Nestable.
1681
1682 2010-01-26  Vincent Celier  <celier@adacore.com>
1683
1684         * prj-conf.adb (Get_Config_Switches): Check for a default language for
1685         a project extending a project with no languages.
1686
1687 2010-01-26  Vincent Celier  <celier@adacore.com>
1688
1689         * switch-c.adb (Scan_Front_End_Switches): Take into account options
1690         that follow -gnatef.
1691         Allow -gnateG to be followed by other options.
1692
1693 2010-01-26  Robert Dewar  <dewar@adacore.com>
1694
1695         * s-commun.ads, s-osprim-mingw.adb, s-stchop-vxworks.adb, sem_aggr.adb,
1696         s-vxwext.adb, sem_ch10.adb, sem_eval.adb, sem_prag.adb: Minor
1697         reformatting.
1698
1699 2010-01-26  Vasiliy Fofanov  <fofanov@adacore.com>
1700
1701         * g-regist.adb, g-regist.ads (For_Every_Key): New generic procedure
1702         that allows to iterate over all subkeys of a key.
1703
1704 2010-01-26  Ed Falis  <falis@adacore.com>
1705
1706         * sysdep.c: enable NFS for VxWorks MILS
1707         * env.c: enable __gnat_environ for VxWorks MILS
1708         * gcc-interface/Makefile.in: Add VxWorks MILS target pairs.
1709
1710 2010-01-25  Bob Duff  <duff@adacore.com>
1711
1712         * sem_aggr.adb (Resolve_Array_Aggregate): Check for the case where this
1713         is an internally-generated positional aggregate, and the bounds are
1714         already correctly set. We don't want to overwrite those bounds with
1715         bounds determined by context.
1716
1717 2010-01-25  Robert Dewar  <dewar@adacore.com>
1718
1719         * g-sercom.ads, gnatcmd.adb, gnatlink.adb, a-ststio.adb, exp_ch6.adb,
1720         exp_ch9.adb, g-sechas.ads: Minor reformatting.
1721
1722 2010-01-25  Thomas Quinot  <quinot@adacore.com>
1723
1724         * s-commun.adb (Last_Index): Count must be converted to SEO (a signed
1725         integer type) before subtracting 1, otherwise the computation may wrap
1726         (because size_t is modular) and cause the conversion to fail.
1727
1728 2010-01-25  Ed Falis  <falis@adacore.com>
1729
1730         * sysdep.c, init.c: Adapt to support full run-time on VxWorks MILS.
1731
1732 2010-01-25  Vincent Celier  <celier@adacore.com>
1733
1734         * prj-attr.adb: New attribute Run_Path_Origin_Required
1735         * prj-nmsc.adb (Process_Project_Level_Simple_Attributes): Process new
1736         attribute Run_Path_Origin_Required.
1737         * prj.ads (Project_Configuration): New component
1738         Run_Path_Origin_Supported.
1739         * snames.ads-tmpl: New standard name Run_Path_Origin_Required
1740
1741 2010-01-25  Ed Schonberg  <schonberg@adacore.com>
1742
1743         * sem_aggr.adb (Resolve_Array_Aggregate): If the bounds in a choice
1744         have errors, do not continue resolution of the aggregate.
1745         * sem_eval.adb (Eval_Indexed_Component): Do not attempt to evaluate if
1746         the array type indicates an error.
1747
1748 2010-01-25  Bob Duff  <duff@adacore.com>
1749
1750         * sinfo.ads: Minor comment fixes.
1751
1752 2010-01-25  Bob Duff  <duff@adacore.com>
1753
1754         * exp_ch4.adb, exp_aggr.adb: Minor comment fixes and code clean up.
1755
1756 2010-01-25  Arnaud Charlet  <charlet@adacore.com>
1757
1758         * gnatvsn.ads (Current_Year): Update.
1759
1760 2010-01-25  Florian Villoing  <villoing@adacore.com>
1761
1762         * gnat_ugn.texi: Fix typo.
1763
1764 2010-01-25  Thomas Quinot  <quinot@adacore.com>
1765
1766         * scos.ads: Update specification.
1767
1768 2010-01-25  Ed Schonberg  <schonberg@adacore.com>
1769
1770         * sem_ch6.adb (Process_PPCs): If a postcondition is present and the
1771         enclosing subprogram has no previous spec, attach postcondition
1772         procedure to the defining entity for the body.
1773
1774 2010-01-25  Ed Schonberg  <schonberg@adacore.com>
1775
1776         * exp_aggr.adb (Build_Record_Aggr_Code); Do not generate call to
1777         initialization procedure of the ancestor part of an extension aggregate
1778         if it is an interface type.
1779
1780 2010-01-25  Vincent Celier  <celier@adacore.com>
1781
1782         * gnatlink.adb (Process_Binder_File): The directory for the shared
1783         version of libgcc in the run path options is found in the subdirectory
1784         indicated by __gnat_default_libgcc_subdir.
1785         * link.c: Declare new const char * __gnat_default_libgcc_subdir for
1786         each platform.
1787
1788 2010-01-25  Ed Schonberg  <schonberg@adacore.com>
1789
1790         * sem_prag.adb: More flexible pragma Annotate.
1791
1792 2010-01-22  Eric Botcazou  <ebotcazou@adacore.com>
1793
1794         * system-linux-armel.ads (Stack_Check_Probes): Set to True.
1795         * system-linux-armeb.ads (Stack_Check_Probes): Likewise.
1796
1797 2010-01-18  Eric Botcazou  <ebotcazou@adacore.com>
1798
1799         * gcc-interface/utils.c (create_var_decl_1): Fix formatting nits.
1800
1801 2010-01-18  Jan Hubicka  <jh@suse.cz>
1802
1803         PR middle-end/42068
1804         * gcc-interface/utils.c (create_var_decl_1): Do not set COMMON flag for
1805         unit local variables.
1806
1807 2010-01-17  Laurent GUERBY  <laurent@guerby.net>
1808
1809         * gcc-interface/Makefile.in: Fix typo in arm*-*-linux-gnueabi.
1810
1811 2010-01-11  Mikael Pettersson  <mikpe@it.uu.se>
1812
1813         * gcc-interface/Makefile.in: Add arm*-*-linux-gnueabi.
1814         * system-linux-armeb.ads, system-linux-armel.ads: New files.
1815
1816 2010-01-09  Simon Wright  <simon@pushface.org>
1817
1818         PR ada/42626
1819         * gcc-interface/Makefile.in (gnatlib-shared-darwin): Add missing
1820         end-quote.
1821
1822
1823 \f
1824 Copyright (C) 2010 Free Software Foundation, Inc.
1825
1826 Copying and distribution of this file, with or without modification,
1827 are permitted in any medium without royalty provided the copyright
1828 notice and this notice are preserved.