OSDN Git Service

334e8838a1544ada7a731980aa69c66ca94d0a2a
[pf3gnuchains/gcc-fork.git] / gcc / ada / ChangeLog
1 2010-09-10  Eric Botcazou  <ebotcazou@adacore.com>
2
3         * exp_dbug.ads: Mention enhanced encoding for array types.
4
5 2010-09-10  Jerome Lambourg  <lambourg@adacore.com>
6
7         * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Size clause are
8         unsupported in VM targets. Display a warning in this case.
9
10 2010-09-10  Ed Schonberg  <schonberg@adacore.com>
11
12         * sprint.adb (Sprint_Node_Actual, case N_Derived_Type_Definition): Do
13         not reset Sloc when printing keyword "new".
14
15 2010-09-10  Vincent Celier  <celier@adacore.com>
16
17         * gnatcmd.adb (GNATCmd): Put the command line in environment variable
18         GNAT_DRIVER_COMMAND_LINE.
19
20 2010-09-10  Ed Schonberg  <schonberg@adacore.com>
21
22         * sem.adb (Do_Unit_And_Dependents): if Withed_Body is set on a context
23         clause, process the body at once.
24
25 2010-09-10  Ed Schonberg  <schonberg@adacore.com>
26
27         * sem_res.adb (Resolve_Type_Conversion): Do not warn on a redundant
28         conversion is the expression is a qualified expression used to
29         disambiguate a function call.
30
31 2010-09-10  Vincent Celier  <celier@adacore.com>
32
33         * prj-nmsc.adb (Add_Source): Allow an Ada source to have the same name
34         as a source of another project and of another language.
35
36 2010-09-10  Robert Dewar  <dewar@adacore.com>
37
38         * prj-util.adb: Minor reformatting.
39
40 2010-09-10  Eric Botcazou  <ebotcazou@adacore.com>
41
42         * exp_disp.adb: Minor reformatting.
43
44 2010-09-10  Arnaud Charlet  <charlet@adacore.com>
45
46         * sem_prag.adb (Analyze_Pragma): Ignore Inline_Always pragma in
47         CodePeer mode.
48
49 2010-09-10  Thomas Quinot  <quinot@adacore.com>
50
51         * sem_res.adb: Minor reformatting.
52         * exp_ch9.adb, rtsfind.ads, exp_ch4.adb, exp_ch3.adb: Do not hardcode
53         magic constants for task master levels (instead, reference
54         named numbers from System.Tasking).
55
56 2010-09-10  Eric Botcazou  <ebotcazou@adacore.com>
57
58         * gnatvsn.ads (Ver_Prefix): New constant string.
59         * bindgen.adb (Gen_Output_File_Ada): Use it in lieu of hardcoded value.
60         (Gen_Output_File_C): Likewise.
61         * g-comver.adb (Ver_Prefix): Add cross-reference to Gnatvsn.Ver_Prefix
62         in comment.
63         
64 2010-09-10  Ed Schonberg  <schonberg@adacore.com>
65
66         * sem.adb (Walk_Library_Items): Do not traverse children of the main
67         unit, to prevent spurious circularities in the walk order.
68         (Depends_On_Main): Use elsewhere to prevent circularities when the body
69         of an ancestor of the main unit depends on a child of the main unit.
70
71 2010-09-10  Robert Dewar  <dewar@adacore.com>
72
73         * gnatlink.adb, prj-ext.adb, prj-util.adb, s-tporft.adb,
74         sem_ch3.adb: Minor reformatting.
75
76 2010-09-10  Ed Schonberg  <schonberg@adacore.com>
77
78         * sem_ch3.adb (Derive_Subprograms): An interface primitive operation
79         that is a renaming must be derived like any other primitive operation,
80         the renamed operation is not relevant to the derivation.
81
82 2010-09-10  Robert Dewar  <dewar@adacore.com>
83
84         * sem_aux.ads: Add comment for Is_Inherently_Limited_Type.
85         * checks.adb: Minor reformatting.
86
87 2010-09-10  Robert Dewar  <dewar@adacore.com>
88
89         * gnat_ugn.texi: Add section on intent of style checking options.
90
91 2010-09-10  Arnaud Charlet  <charlet@adacore.com>
92
93         * xref_lib.adb (Get_Full_Type): Fix handling of 'a' char.
94
95 2010-09-10  Ed Schonberg  <schonberg@adacore.com>
96
97         * sem_ch3.adb: Improve error message on derivation from class-wide type
98
99 2010-09-10  Steve Baird  <baird@adacore.com>
100
101         * gnat1drv.adb (Adjust_Global_Switches): Enable Expression_With_Actions
102         generation when Generate_SCIL is True.
103
104 2010-09-10  Geert Bosch  <bosch@adacore.com>
105
106         * gnatlink.adb (Check_ Existing_Executable): New procedure for checking
107         validity of executable name and removing any existing executable
108         (Gnatlink): Call Check_Existing_Executable.
109
110 2010-09-10  Arnaud Charlet  <charlet@adacore.com>
111
112         * s-tporft.adb, s-taskin.ads (Register_Foreign_Thread): Move
113         initialization of Task_Alternate_Stack here, cleaner since in case of
114         ranvescar, Restricted_Ada_Task_Control_Block is not initialized
115         implicitly.
116
117 2010-09-10  Thomas Quinot  <quinot@adacore.com>
118
119         * s-fileio.adb, a-dirval.adb: Minor reformatting.
120
121 2010-09-10  Emmanuel Briot  <briot@adacore.com>
122
123         * prj-util.adb (Executable_Of): Fix CE when the project does not
124         contain a Builder package.
125
126 2010-09-10  Vincent Celier  <celier@adacore.com>
127
128         * prj-ext.adb (Initialize_Project_Path): Add <prefix>/lib/gpr/<target>
129         to the project path, if Prefix and Target_Name are defined.
130         * prj-tree.ads (Project_Node_Tree_Data): New component Target_Name
131
132 2010-09-10  Ed Schonberg  <schonberg@adacore.com>
133
134         * checks.adb (Ensure_Valid): If the expression is a boolean expression
135         or short-circuit operation, do no emit a validity check: only the
136         elementary operands of the expression need checking.
137
138 2010-09-10  Ben Brosgol  <brosgol@adacore.com>
139
140         * gnat_rm.texi: Document Short_Descriptors.
141
142 2010-09-10  Arnaud Charlet  <charlet@adacore.com>
143
144         * s-taprop-linux.adb, s-taskin.ads (Task_Alternate_Stack): Default
145         initialize to Null_Address.
146         (Enter_Task): Do not set up an alternate stack for foreign threads.
147
148 2010-09-10  Robert Dewar  <dewar@adacore.com>
149
150         * opt.adb (Short_Descriptors): New flag
151         (Short_Descriptors_Config): New flag
152         * opt.ads (Short_Descriptors): New flag
153         (Short_Descriptors_Config): New flag
154         * par-prag.adb: Add dummy entry for Short_Descriptors pragma
155         * sem_prag.adb (Set_Mechanism_Value): Deal with Short_Descriptors pragma
156         (Analyze_Pragma): Implement Short_Descriptors pragma
157         * snames.ads-tmpl: Add entry for Short_Descriptors pragma
158
159 2010-09-10  Emmanuel Briot  <briot@adacore.com>
160
161         * prj-util.adb, prj-util.ads (Executable_Of): Take into account the
162         project's Executable_Suffix.
163
164 2010-09-10  Robert Dewar  <dewar@adacore.com>
165
166         * g-pehage.ads: Minor reformatting
167
168         * gnat_ugn.texi: Clarifying comment on -gnatyc
169         * exp_ch6.adb (Expand_N_Subprogram_Body): Reset Is_Pure if limited
170         arguments.
171
172 2010-09-10  Tristan Gingold  <gingold@adacore.com>
173
174         * Make-generated.in (gnat.hlp): New rule.
175
176 2010-09-10  Emmanuel Briot  <briot@adacore.com>
177
178         * prj-util.adb, prj-util.ads (Executable_Of): New parameter
179         Include_Suffix.
180
181 2010-09-10  Robert Dewar  <dewar@adacore.com>
182
183         * einfo.adb: Minor code cleanup: Add assertion to
184         Set_Corresponding_Protected_Entry.
185
186 2010-09-10  Bob Duff  <duff@adacore.com>
187
188         * g-pehage.ads, g-pehage.adb (Produce): Add a new flag to allow sending
189         the output to standard output.
190
191 2010-09-09  Vincent Celier  <celier@adacore.com>
192
193         * gnat_ugn.texi: Add documentation for new gnatmake switch
194         --create-map-file.
195         * make.adb (Map_File): New global variable to store the value of switch
196         --create-map-file.
197         (Gnatmake): Add switch -M to gnatlink if buider switch --create-map-file
198         has been specified.
199         (Scan_Make_Arg): Recognize switch --create-map-file
200         * makeutl.ads (Create_Map_File_Switch): New constant string for new
201         gnatmake and gprbuild switch --create-map-file.
202
203 2010-09-09  Robert Dewar  <dewar@adacore.com>
204
205         * sinput-p.ads: Minor comment update.
206
207 2010-09-09  Arnaud Charlet  <charlet@adacore.com>
208
209         * s-tpobop.adb, s-taenca.adb (Wait_For_Completion_With_Timeout): Reset
210         Entry_Call.State if needed so that the call is marked as cancelled by
211         Check_Pending_Actions_For_Entry_Call.
212         (Timed_Protected_Entry_Call): Adjust calls to Defer/Under_Abort, since
213         this procedure may be called from a controlled operation
214         (Initialize/Finalize).
215
216 2010-09-09  Vadim Godunko  <godunko@adacore.com>
217
218         * impunit.adb: Correct spelling of package's name in the comment.
219
220 2010-09-09  Robert Dewar  <dewar@adacore.com>
221
222         * gnatcmd.adb, gnatlink.adb, sem_ch12.adb, sem_eval.adb, sinput-p.adb:
223         Minor reformatting
224
225 2010-09-09  Robert Dewar  <dewar@adacore.com>
226
227         * impunit.adb: Add entry for a-izteio.
228         * checks.adb: Add comment.
229         * debug.adb, exp_disp.adb: Minor reformatting.
230         * exp_dbug.ads: Minor reformatting throughout (pack block comments).
231
232 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
233
234         * sem_eval.adb (Is_Same_Value): Two occurrences of the same
235         discriminant cannot be assumed to be the same value because they may
236         refer to bounds of a component of two different instances of a
237         discriminated type.
238
239 2010-09-09  Gary Dismukes  <dismukes@adacore.com>
240
241         * checks.adb (Apply_Arithmetic_Overflow_Check): When converting the
242         operands of an operator to the type of an enclosing conversion, rewrite
243         the operator so the conversion can't be flagged as redundant.
244         Remove useless assignments to Typ and Rtyp.
245
246 2010-09-09  Eric Botcazou  <ebotcazou@adacore.com>
247
248         * gnat_ugn.texi: Fix another long line.
249
250 2010-09-09  Bob Duff  <duff@adacore.com>
251
252         * sem_warn.adb (Output_Reference_Error): Don't warn for renames read
253         but never assigned.
254
255 2010-09-09  Matthew Heaney  <heaney@adacore.com>
256
257         * a-convec.adb, a-coinve.adb (Clear, Delete, Delete_Last, Finalize,
258         Merge, Insert, Insert_Space, Move, Reserve_Capacity, Generic_Sorting,
259         Replace_Element, Reverse_Elements, Swap): Change exception message to
260         correctly indicate kind of tampering (cursor or element).
261         * a-cdlili.adb, a-cidlli.adb (Clear, Delete, Delete_First, Delete_Last,
262         Merge, Generic_Sorting, Insert, Move, Reverse_Elements, Splice,
263         Swap_Links, Replace_Element, Swap): Ditto.
264         * a-coorse.adb, a-ciorse.adb (Include, Replace, Replace_Element): Ditto
265         * a-coorma.adb, a-ciorma.adb (Include, Replace, Replace_Element): Ditto
266         * a-coormu.adb, a-ciormu.adb (Replace_Element): Ditto
267         * a-chtgke.adb (Delete_Key_Sans_Free, Generic_Conditional_Insert,
268         Generic_Replace_Element): Ditto
269         * a-chtgop.adb (Clear, Move, Reserve_Capacity): Ditto
270         * a-cohama.adb, a-cihama.adb (Delete, Include, Replace,
271         Replace_Element): Ditto.
272         * a-cohase.adb, a-cihase.adb (Delete, Difference, Intersection,
273         Symmetric_Difference, Union, Include, Replace): Ditto
274
275 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
276
277         * sprint.adb (Write_Id): If the parent node is an expanded name, check
278         that its entity_or_associated_node is an entity before writing it out.
279         * exp_disp.adb (Make_Tags); if a type is declared in C++ and has no
280         constructors, there is no need for a dispatch table pointer because the
281         table is fully inherited from the C++ code.
282
283 2010-09-09  Thomas Quinot  <quinot@adacore.com>
284
285         * projects.texi: Fix wrong identifiers on package end lines in project
286         files examples.
287         * exp_ch6.adb: Minor reformatting.
288
289 2010-09-09  Tristan Gingold  <gingold@adacore.com>
290
291         * gnatcmd.adb, vms_conv.ads: Extract Command_Type.
292
293 2010-09-09  Eric Botcazou  <ebotcazou@adacore.com>
294
295         * gnat_ugn.texi: Fix description of -O3 optimization level.
296
297 2010-09-09  Yannick Moy  <moy@adacore.com>
298
299         * a-cihama.adb, a-cohama.adb: Fix comments.
300
301 2010-09-09  Arnaud Charlet  <charlet@adacore.com>
302
303         * i-cexten.ads: Add comments.
304         (Signed_128): New type, used by some C bindings.
305         * debug.adb: Update comment.
306
307 2010-09-09  Sergey Rybin  <rybin@adacore.com>
308
309         * gnat_ugn.texi: For ASIS tools (gnatpp, gnatcheck, gnatelim,
310         gnatmetric and gnatstub) add a note that '-gnat05' should be used if
311         the tool should process Ada 2005 sources.
312
313 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
314
315         * sem_ch12.adb (Remove_Parent): If the scope containing the child
316         instance is a block, examine the enclosing scope to determine if it is
317         a parent instance.
318
319 2010-09-09  Doug Rupp  <rupp@adacore.com>
320
321         * sem_prag.adb (pragma Ident): Pass --identification= vice 
322         IDENTIFICATION=
323         * gnatlink.adb (Linker_Options): Look for --identification= vice 
324         IDENTIFICATION=
325
326 2010-09-09  Gary Dismukes  <dismukes@adacore.com>
327
328         * exp_attr.adb (Expand_N_Attribute_Reference, case Attribute_Old): When
329         inserting and analyzing the object declaration for the temporary object
330         created to hold a 'Old value, push the scope for the subprogram where
331         the object is inserted, so that its Scope (and that of related objects)
332         will be set properly.
333
334 2010-09-09  Vincent Celier  <celier@adacore.com>
335
336         * prj.adb (Get_Object_Directory): Return object directory display name
337         * adaint.c (__gnat_get_file_names_case_sensitive): When environment
338         variable GNAT_FILE_NAME_CASE_SENSITIVE has a value of "0" or "1",
339         return this value, otherwise return the default for the platform.
340
341 2010-09-09  Arnaud Charlet  <charlet@adacore.com>
342
343         * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
344         dependencies. Remove handling of gnatlbr.
345         Do not remove s-stratt-xdr for the run-time when installing.
346
347 2010-09-09  Robert Dewar  <dewar@adacore.com>
348
349         * sem_attr.adb: Minor reformatting.
350
351 2010-09-09  Thomas Quinot  <quinot@adacore.com>
352
353         * socket.c (__gnat_socket_ioctl): On Darwin, the req parameter is an
354         unsigned long, not an int.
355
356 2010-09-09  Vincent Celier  <celier@adacore.com>
357
358         * make.adb, mlib-prj.adb, prj.adb, prj-nmsc.adb, mlib-tgt.adb,
359         prj-conf.adb, prj-env.adb: Use Display_Name instead of Name whenever
360         we are not checking for equality of path or file names.
361
362 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
363
364         * exp_util.adb (Remove_Side_Effects): If the expression is a packed
365         array reference, reset the Analyzed flag so that it is properly
366         expanded when the resulting object declaration is analyzed.
367
368 2010-09-09  Vincent Celier  <celier@adacore.com>
369
370         * sinput-p.adb (Source_File_Is_Subunit): Return False if X is
371         No_Source_File.
372
373 2010-09-09  Ramon Fernandez  <fernandez@adacore.com>
374
375         * sysdep.c: The wrSbc8548 BSP in MILS doesn't know anything about the
376         VX_SPE_TASK option, so disable it.
377
378 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
379
380         * sem.adb (Walk_Library_Items): Traverse context of subunits of the
381         main unit.
382         (Is_Subunit_Of_Main): Handle null nodes properly.
383
384 2010-09-09  Robert Dewar  <dewar@adacore.com>
385
386         * par-ch2.adb: Update comments.
387
388 2010-09-09  Ben Brosgol  <brosgol@adacore.com>
389
390         * gnat_rm.texi: Minor wordsmithing of section on pragma Ordered.
391
392 2010-09-09  Arnaud Charlet  <charlet@adacore.com>
393
394         * par-ch2.adb (Scan_Pragma_Argument_Association): In CodePeer mode,
395         do not generate an error for compatibility with legacy code.
396         ignored when generating SCIL.
397         * sem_attr.adb (Resolve_Attribute): Ignore AI-229 in CodePeer mode.
398
399 2010-09-09  Thomas Quinot  <quinot@adacore.com>
400
401         * s-strxdr.adb, gnat_rm.texi, s-stratt-xdr.adb, s-stratt.ads: Rename
402         s-strxdr.adb to s-stratt-xdr.adb
403
404 2010-09-09  Robert Dewar  <dewar@adacore.com>
405
406         * ali-util.adb (Obsolescent_Check): Removed.
407         * gprep.adb (Obsolescent_Check): Removed.
408         Remove Obsolescent_Check parameter in Scng instantiation
409         * prj-err.adb (Obsolescent_Check): Removed.
410         * prj-err.ads (Obsolescent_Check): Removed.
411         Remove Obsolescent_Check parameter in Scng instantiation
412         * scans.ads (Based_Literal_Uses_Colon): New flag
413         * scn.adb (Obsolscent_Check_Flag): Removed
414         (Obsolscent_Check): Removed
415         (Set_Obsolescent_Check): Removed
416         (Post_Scan): Add handling for obsolescent features
417         * scn.ads (Obsolscent_Check): Removed
418         (Set_Obsolescent_Check): Removed
419         (Post_Scan): Can no longer be inlined
420         Remove Obsolescent_Check from instantiation of Scng
421         * scng.adb (Nlit): Set Based_Literal_Uses_Colon
422         (Nlit): Remove handling of obsolescent check
423         (Scan, case '%'): Remove handling of obsolescent check
424         (Scan, case '|'): Call Post_Scan
425         (Scan, case '!'): Remove handling of obsolescent check, call Post_Scan
426         * scng.ads Remove Obsolescent_Check argument from Scng generic
427         (Post_Scan): Now called for Tok_Vertical_Bar
428         * sinput-l.adb: Remove calls to Set_Obsolescent_Check
429
430 2010-09-09  Doug Rupp  <rupp@adacore.com>
431
432         * gnatlbr.adb: Removed.
433         * gnat_rm.texi, ug_words, gnat_ugn.texi: Remove mention of gnatlbr.
434
435 2010-09-09  Robert Dewar  <dewar@adacore.com>
436
437         * sem_res.adb (Resolve_Type_Conversion): Catch more cases of redundant
438         conversions.
439
440 2010-09-09  Vincent Celier  <celier@adacore.com>
441
442         * gnatlbr.adb: Remove redundant conversions.
443
444 2010-09-09  Vincent Celier  <celier@adacore.com>
445
446         * prj-proc.adb: Minor comment spelling error fix.
447         * osint.ads (Env_Vars_Case_Sensitive): Use function
448         Get_Env_Vars_Case_Sensitive, not Get_File_Names_Case_Sensitive to
449         compute value.
450
451 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
452
453         * sem_res.adb (Resolve_Equality_Op): Implement Ada2012 rule for
454         resolution of conditional expressions whose dependent expressions are
455         anonymous access types.
456
457 2010-09-09  Robert Dewar  <dewar@adacore.com>
458
459         * a-ststio.adb: Minor code reorganization.
460         * s-direio.adb, prj.adb, prj-nmsc.adb, sem_type.adb: Remove redundant
461         conversion.
462         * types.ads: Minor reformatting.
463         * binde.adb, vms_conv.adb, gnatls.adb, s-strxdr.adb, uintp.adb: Remove
464         redundant conversions.
465         * output.adb: Minor reformatting.
466         * sem_ch8.adb (Find_Type): Test for redundant base applies to user
467         types.
468         * opt.ads: Add pragma Ordered for Verbosity_Level.
469         * prj.ads: Add pragma Ordered for type Verbosity.
470
471 2010-09-09  Vincent Celier  <celier@adacore.com>
472
473         * osint.adb (Canonical_Case_File_Name): Use procedure To_Lower in
474         System.Case_Util
475         (Canonical_Case_Env_Var_Name): Ditto
476
477 2010-09-09  Bob Duff  <duff@adacore.com>
478
479         * g-pehage.adb (Allocate): Initialize the allocated elements of IT.
480
481 2010-09-09  Robert Dewar  <dewar@adacore.com>
482
483         * cstand.adb: Mark Boolean and Character types as Ordered
484         * einfo.adb (Has_Pragma_Ordered): New flag
485         * einfo.ads (Has_Pragma_Ordered): New flag
486         * g-calend.ads: Mark Day_Name as Ordered
487         * opt.ads: Mark Ada_Version_Type as Ordered
488         (Warn_On_Unordered_Enumeration_Type): New flag
489         * par-prag.adb: Add procdessing for pragma Ordered
490         * s-ficobl.ads (Read_File_Mode): New subtype
491         * s-fileio.adb: Use Read_File_Mode instead of explicit ranges
492         * s-taskin.ads: Mark Entry_Call_State as ordered
493         * sem_ch3.adb (Build_Derived_Enumeration_Type): Inherit
494         Has_Pragma_Ordered.
495         * sem_ch6.ads: Mark Conformance_Type as Ordered
496         * sem_prag.adb: Implement pragma Ordered
497         * sem_res.adb (Bad_Unordered_Enumeration_Reference): New function
498         (Resolve_Comparison_Op): Diagnose unordered comparison
499         (Resolve_Range): Diagnose unordered range
500         * sem_warn.adb (Warn_On_Unordered_Enumeration_Type): New flag (from
501         -gnatw.u/U)
502         * snames.ads-tmpl: Add entry for pragma Ordered
503         * style.ads (Check_Enumeration_Subrange): Removed
504         * styleg.adb (Check_Enumeration_Subrange): Removed
505         * styleg.ads (Check_Enumeration_Subrange): Removed
506         * stylesw.adb: Remove handling of -gnatyE switch
507         * stylesw.ads: (Style_Check_Enumeration_Subranges): Removed
508         * vms_data.ads: Remove -gnatyE entries
509         Add -gnatw.u entries
510         * ug_words: Entries for -gnatw.u and -gnatw.U
511         * gnat_ugn.texi: Document -gnatw.u/-gnatw.U switches
512         * gnat_rm.texi: Document pragma Ordered.
513         * s-tasren.adb: Avoid unnecessary comparison on unordered enumeration.
514         * s-tpobop.adb: Remove comparison on unordered enumeration type.
515
516 2010-09-09  Vincent Celier  <celier@adacore.com>
517
518         * adaint.c: New function __gnat_get_env_vars_case_sensitive, returns 0
519         for VMS and Windows, and 1 for all other platforms.
520         * adaint.h: New function __gnat_get_env_vars_case_sensitive
521         * osint.ads, osint.adb (Canonical_Case_Env_Var_Name): New procedure.
522         * prj-ext.adb (Add): Call Canonical_Case_Env_Var_Name instead of
523         Canonical_Case_File_Name, as we are dealing with environment variables,
524         not files.
525
526 2010-09-09  Robert Dewar  <dewar@adacore.com>
527
528         * sem_util.adb: Minor reformatting
529
530 2010-09-09  Vincent Celier  <celier@adacore.com>
531
532         * vms_data.ads: Add documentation for S_Make_Single.
533
534 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
535
536         * sem_util.adb (Same_Object): include formal parameters.
537
538 2010-09-09  Vincent Celier  <celier@adacore.com>
539
540         * make.adb (Queue): New package implementing a new impementation of the
541         queue, taking into account the new switch --single-compile-per-obj-dir.
542         * makeutl.ads (Single_Compile_Per_Obj_Dir_Switch): New constant String
543         for gnatmake and gprbuild new switch --single-compile-per-obj-dir.
544         * opt.ads (One_Compilation_Per_Obj_Dir): New Boolean flag, defauted to
545         False.
546         * switch-m.adb (Scan_Make_Switches): Take into account new gnatmake
547         switch --single-compile-per-obj-dir.
548         * vms_data.ads: Add qualifier SINGLE_COMPILE_PER_OBJ_DIR for gnatmake
549         switch --single-compile-per-obj-dir.
550         * gnat_ugn.texi: Add documentation for new gnatmake switch
551         --single-compile-per-obj-dir.
552
553 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
554
555         * einfo.adb, einfo.ads: Clarify use of Corresponding_Protected_Entry.
556
557 2010-09-09  Javier Miranda  <miranda@adacore.com>
558
559         * sem_ch3.adb (Is_Progenitor): Relocated to sem_type.
560         (Replace_Type): Code cleanup.
561         * sem_type.ads, sem_type.adb (Is_Progenitor): Relocated from sem_ch3
562
563 2010-09-09  Thomas Quinot  <quinot@adacore.com>
564
565         * exp_ch8.adb: Minor reformatting.
566
567 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
568
569         * exp_ch9.adb, einfo.adb, einfo.ads: New attribute
570         Corresponding_Protected_Entry.
571
572 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
573
574         * exp_ch3.adb (Build_Untagged_Equality): Do not set alias of implicit
575         inequality, it is always rewritten as the negation of the corresponding
576         equality operation.
577         * exp_ch8.adb (Expand_N_Subprogram_Renaming): If the subprogram renames
578         the predefined equality of an untagged record, create a body at the
579         point of the renaming, to capture the current meaning of equality for
580         the type.
581
582 2010-09-09  Robert Dewar  <dewar@adacore.com>
583
584         * sem.adb, sem_warn.adb: Minor reformatting.
585
586 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
587
588         * sem_ch6.adb: Improve error message on untagged equality.
589         * sem.adb (Semantics): Include subprogram bodies that act as spec.
590
591 2010-09-09  Javier Miranda  <miranda@adacore.com>
592
593         * sem_ch13.adb, exp_ch13.adb: Undo previous change, unneeded.
594
595 2010-09-09  Robert Dewar  <dewar@adacore.com>
596
597         * sem_ch13.adb, sem_ch6.adb, exp_ch3.adb: Minor reformatting.
598
599 2010-09-09  Robert Dewar  <dewar@adacore.com>
600
601         * einfo.adb (Is_Aggregate_Type): New function.
602         * einfo.ads (Aggregate_Kind): New enumeration subtype
603         (Is_Aggregate_Type): New function.
604         * sem_type.adb (Is_Array_Class_Record_Type): Removed, replaced by
605         Is_Aggregate_Typea.
606
607 2010-09-09  Robert Dewar  <dewar@adacore.com>
608
609         * exp_ch11.adb, frontend.adb, sem_attr.adb, sem_ch10.adb, sem_ch3.adb,
610         sem_ch4.adb, sem_ch9.adb, sem_res.adb: Use Restriction_Check_Needed
611         where appropriate.
612         * restrict.ads, restrict.adb: Ditto.
613         (Restriction_Check_Needed): New function
614
615 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
616
617         * exp_ch9.ads (Find_Master_Scope): New function, extracted from
618         Build_Master_Entity, to find the proper scope for the master entity of
619         a type that may contain tasks, in the presence of transient scopes.
620         * exp_ch9.adb (Build_Master_Entity) Use new function.
621         * exp_ch3.adb (Build_Class_Wide_Master): ditto.
622
623 2010-09-09  Vincent Celier  <celier@adacore.com>
624
625         * prj-attr.adb: Add new attributes Leading_Library_Options and
626         Linker'Leading_Switches.
627         * snames.ads-tmpl: Add new standard names Leading_Library_Options and
628         Leading_Switches.
629
630 2010-09-09  Javier Miranda  <miranda@adacore.com>
631
632         * sem_ch3.adb (Derive_Subprogram): The code that checks if a
633         dispatching primitive covers some interface primitive is incomplete.
634         Replace such code by the invocation of a new subprogram that provides
635         this functionality.
636         * sem_ch6.ads (Is_Interface_Conformant): Add missing documentation.
637         * sem_ch6.adb (Check_Missing_Return): Minor reformating
638         (Check_Convention): Complete if-statement conditition when reporting
639         errors (to avoid assertion failure).
640         * sem_ch13.adb (Make_Null_Procedure_Specs): This routine was previously
641         located in exp_ch3. Relocated inside Analyze_Freeze_Entity.
642         (Analyze_Freeze_Entity): Invoke routine that adds the spec of non
643         overridden null interface primitives.
644         * sem_type.adb (Is_Ancestor): If the parent of the partial view of a
645         private type is an interface then use the parent of its full view to
646         climb to its ancestor type.
647         * sem_disp.ads, sem_disp.adb (Covers_Some_Interface): New subprogram.
648         (Check_Dispatching_Operation): Extend assertion to handle wrappers of
649         null interface primitives.
650         (Is_Null_Interface_Primitive): New subprogram.
651         * exp_ch3.adb (Make_Null_Procedure_Specs): Removed.
652         (Expand_Freeze_Record_Type): Do not generate specs of null interface
653         subprograms because they are now generated by Analyze_Freeze_Entity.
654
655 2010-09-09  Robert Dewar  <dewar@adacore.com>
656
657         * a-calfor.adb, sem_ch3.adb: Minor reformatting.
658
659 2010-09-09  Robert Dewar  <dewar@adacore.com>
660
661         * bindgen.adb (Gen_Restrictions_Ada): Avoid explicit enumeration ranges
662         (Gen_Restrictions_C): Avoid explicit enumeration ranges
663         (Set_String_Replace): New procedure
664         * casing.ads (Known_Casing): New subtype declaration
665         * prj-attr.ads (All_Case_Insensitive_Associative_Array): New subtype
666         declaration
667         * prj-dect.adb (Parse_Attribute_Declaration): Avoid enumeration range
668         * prj-nmsc.adb (Check_Naming): Avoid unnecessary enumeration range
669         * prj-strt.adb (Attribute_Reference): Avoid enumeration range test
670         * prj.adb (Known_Casing): Moved to Casing spec (avoid enum range)
671         * sem_ch13.adb (Adjust_Record_For_Reverse_Bit_Order): Avoid enumeration
672         ranges
673         * sem_res.adb (Resolve_Range): Check for enumeration subrange style rule
674         * sem_type.adb (Is_Array_Class_Record_Type): New.
675         * style.ads (Check_Enumeration_Subrange): New procedure
676         * styleg.adb (Check_Enumeration_Subrange): New procedure
677         * styleg.ads (Check_Enumeration_Subrange): New procedure
678         * stylesw.adb Add handling for Style_Check_Enumeration_Subranges
679         * stylesw.ads (Style_Check_Enumeration_Subranges): New flag
680         * usage.adb: Add line for -gnatyE
681         * vms_data.ads: Add entries for [NO]ENUMERATION_RANGES
682         Add missing entry for NOBOOLEAN_OPERATORS
683         * gnat_ugn.texi: Add documentation for -gnatyE
684
685 2010-09-09  Robert Dewar  <dewar@adacore.com>
686
687         * namet.adb (Initialize): Is now a dummy procedure
688         (Reinitialize): New procedure
689         Call Reinitialize from package initialization
690         * namet.ads (Initialize): Is now a dummy procedure
691         (Reinitialize): New procedure
692         * clean.adb, gnat1drv.adb, gnatbind.adb, gnatcmd.adb, gnatlink.adb,
693         gnatls.adb, gprep.adb, make.adb, prj-makr.adb: Remove obsolete call to
694         Namet.Initialize.
695
696 2010-09-09  Bob Duff  <duff@adacore.com>
697
698         * sem_elab.adb, s-os_lib.ads: Minor comment fixes.
699
700 2010-09-09  Robert Dewar  <dewar@adacore.com>
701
702         * s-bitops.adb (Raise_Error): Add exception message
703
704 2010-09-09  Robert Dewar  <dewar@adacore.com>
705
706         * par-ch5.adb (Test_Statement_Required): Deal with Ada 2012 allowing no
707         null statement after label.
708         * sinfo.ads: Minor comment updates.
709
710 2010-09-09  Robert Dewar  <dewar@adacore.com>
711
712         * nlists.ads, nlists.adb (In_Same_List): New function.
713         Use Node_Or_Entity_Id where appropriate.
714         * par-labl.adb, sem_ch6.adb, sem_type.adb: Use In_Same_List.
715
716 2010-09-09  Robert Dewar  <dewar@adacore.com>
717
718         * restrict.ads, restrict.adb (Check_Wide_Character_Restriction): New
719         procedure.
720         * sem_ch3.adb: Use Check_Wide_Character_Restriction
721         (Enumeration_Type_Declaration): Check violation of No_Wide_Characters
722         * sem_ch8.adb (Find_Direct_Name): Check violation of No_Wide_Characters
723         (Find_Expanded_Name): Check violation of No_Wide_Characters
724
725 2010-09-09  Robert Dewar  <dewar@adacore.com>
726
727         * par-ch5.adb: Minor reformatting.
728
729 2010-09-09  Robert Dewar  <dewar@adacore.com>
730
731         * prj-env.adb: Minor code reorganization.
732         * par-ch3.adb: Minor reformatting.
733         * gcc-interface/Make-lang.in: Update dependencies.
734
735 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
736
737         * exp_ch9.adb (Build_Activation_Chain_Entity): The construct enclosing
738         a task declaration can be an entry body.
739
740 2010-09-09  Javier Miranda  <miranda@adacore.com>
741
742         * exp_disp.adb (Make_DT): Decorate as "static" variables containing
743         tags of library level tagged types.
744         (Make_Tags): Disable backend optimizations about aliasing for
745         declarations of access to dispatch tables.
746
747 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
748
749         * sem_ch12.adb (Reset_Entity): If the entity is an itype created as a
750         subtype for a null-excluding access type, recover the original
751         subtype_mark to get the proper visibility on the original name.
752
753 2010-09-09  Ed Schonberg  <schonberg@adacore.com>
754
755         * exp_ch3.adb (Build_Untagged_Equality): For Ada2012, new procedure to
756         create the primitive equality operation for an untagged record. The
757         operation is the predefined equality if no record component has a
758         user-defined equality, or if there is a user-defined equality for the
759         type as a whole, or when the type is derived and it has an inherited
760         equality. Otherwise the body of the operations is built as for tagged
761         types.
762         (Expand_Freeze_Record_Type): Call Build_Untagged_Equality when needed.
763         (Make_Eq_Body): New function to create the expanded body of the equality
764         operation for tagged and untagged records.  In both cases the operation
765         composes, and the primitive operation of each record component is used
766         to generate the equality function for the type.
767         * exp_ch4.adb (Expand_Composite_Equality): In Ada2012, if a component
768         has an abstract equality defined, replace its call with a
769         Raise_Program_Error.
770         * sem_ch6.adb (New_Overloaded_Entity): if Ada2012, verify that a
771         user-defined equality operator for an untagged record type does not
772         happen after type is frozen, and appears in the visible part if partial
773         view of type is not limited.
774
775 2010-09-09  Tristan Gingold  <gingold@adacore.com>
776
777         * gnatlbr.adb: Make Create_Directory more portable: use __gnat_mkdir.
778
779 2010-09-09  Bob Duff  <duff@adacore.com>
780
781         * gnat_ugn.texi: Remove incorrect statement about -E being the default.
782
783 2010-09-09  Pascal Obry  <obry@adacore.com>
784
785         * gnat_ugn.texi: Update doc on windows related topics.
786
787 2010-09-09  Geert Bosch  <bosch@adacore.com>
788
789         * s-fatgen.adb: Update comments.
790
791 2010-09-09  Robert Dewar  <dewar@adacore.com>
792
793         * par-ch4.adb (Box_Error): New procedure.
794
795 2010-09-09  Thomas Quinot  <quinot@adacore.com>
796
797         * sem.adb: Minor reformatting.
798
799 2010-09-09  Pascal Obry  <obry@adacore.com>
800
801         * prj-env.adb: Style fix, use /and then/ and /or else/.
802         * gnat_ugn.texi: Fix typos.
803
804 2010-09-03  Joseph Myers  <joseph@codesourcery.com>
805
806         PR ada/45499
807         * gcc-interface/misc.c (gnat_init_options): Allow options with
808         empty canonical form.  Generate a single save_argv element from -I
809         options.
810
811 2010-08-30  Eric Botcazou  <ebotcazou@adacore.com>
812
813         * gcc-interface/utils.c (gnat_pushdecl): Remove test for PARM_DECLs.
814         Attach fake PARM_DECLs to the topmost block of the function.
815
816 2010-08-30  Eric Botcazou  <ebotcazou@adacore.com>
817
818         * gcc-interface/trans.c (call_to_gnu): Also force the return slot opt
819         for the call to a function whose return type was unconstrained.
820
821 2010-08-30  Olivier Hainque  <hainque@adacore.com>
822
823         * gcc-interface/decl.c (FOREIGN_FORCE_REALIGN_STACK): New macro,
824         replacement for FORCE_PREFERRED_STACK_BOUNDARY_IN_MAIN.
825         (gnat_to_gnu_entity) <case ..., E_Procedure>: Use it.
826
827 2010-08-21  Eric Botcazou  <ebotcazou@adacore.com>
828
829         * tracebak.c: Fix typo in comment.
830
831 2010-08-20  Nathan Froyd  <froydnj@codesourcery.com>
832
833         * gcc-interface/decl.c: Use FOR_EACH_VEC_ELT.
834         * gcc-interface/trans.c: Likewise.
835         * gcc-interface/utils.c: Likewise.
836
837 2010-08-18  Eric Botcazou  <ebotcazou@adacore.com>
838
839         * tracebak.c (i386): Use GCC unwinder on Linux with GCC > 4.5.
840
841 2010-08-10  Robert Dewar  <dewar@adacore.com>
842
843         * sem_ch8.adb, sem_ch8.ads: Change name Write_Scopes to ws.
844         * sem_util.adb: Minor reformatting.
845
846 2010-08-10  Javier Miranda  <miranda@adacore.com>
847
848         * sem_aggr.adb (Resolve_Extension_Aggregate): Warn on the use of C++
849         constructors that leave the object partially initialized.
850         * exp_atag.ads, exp_atags.adb (Build_Inherit_CPP_Prims): New subprogram
851         that copies from parent of Typ the dispatch table slots of inherited
852         C++ primitives. It handles primary and secondary dispatch tables.
853         * einfo.adb (Related_Type): Moved from Node26 to Node27. Required to
854         use this attribute with E_Variable entities.
855         (Set_Is_Tag): Relax assertion to allow its use with variables that
856         store tags.
857         (Set_Related_Type): Relax assertion to allow its use with variables
858         that store the tag of a C++ class.
859         (Write_26_Field_Name): Remove Related_Type.
860         (Write_27_Field_Name): Add Related_Type.
861         * einfo.ads (Related_Type): Moved from Node26 to Node27. Available also
862         with E_Variable entities.
863         * sem_prag.adb (CPP_Constructor): Warn on duplicated occurrence of this
864         pragma.
865         * sem_util.adb (Search_Tag): Add missing support for CPP types.
866         (Enclosing_CPP_Parent): New subprogram.
867         (Has_Suffix): New subprogram.
868         * sem_util.ads (Enclosing_CPP_Parent): New subprogram that returns the
869         closest ancestor of a type that is a C++ type.
870         (Has_Suffix): New subprogram. Used in assertions to check the suffix of
871         internal entities.
872         * sem_attr.adb (Analyze_Access_Attribute): Check wrong use of current
873         instance in derivations of C++ types.
874         * exp_tss.adb (CPP_Init_Proc): New subprogram.
875         (Is_CPP_Init_Proc): New subprogram.
876         (Set_TSS): Handle new C++ init routines.
877         * exp_tss.ads (TSS_CPP_Init): New TSS name. For initialization of C++
878         dispatch tables.
879         (CPP_Init_Proc): New subprogram.
880         (Is_CPP_Init_Proc): New subprogram.
881         * exp_disp.adb (CPP_Num_Prims): New subprogram.
882         (Has_CPP_Constructors): New subprogram.
883         (Make_Secondary_DT, Make_DT): For derivations of CPP types, do not
884         initialize slots located in the C++ part of the dispatch table.
885         (Make_Tags): For CPP types declare variables used by the IP routine to
886         store the C++ tag values after the first invocation of the C++
887         constructor.
888         (Build_CPP_Init_DT): New subprogram.
889         (Set_CPP_Constructors): New implementation that builds an IP for each
890         CPP constructor. These IP are wrappers of the C++ constructors that,
891         after the first invocation of the constructor, read the C++ tags from
892         the object and save them locally. These copies of the C++ tags are used
893         by the IC routines to initialize tables of Ada derivations of CPP types.
894         (Write_DT): Indicate what primitives are imported from C++
895         * exp_disp.ads (CPP_Num_Prims): New subprogram.
896         (Has_CPP_Constructors): New subprogram.
897         * exp_aggr.adb (Build_Record_Aggr_Code): For derivations of C++ types
898         invoke the IC routine to inherit the slots of the parents.
899         * sem_ch13.adb (Analyze_Freeze_Entity): Add new warnings on CPP types.
900         * exp_ch3.adb (Is_Variable_Size_Array): New subprogram.
901         (Is_Variable_Size_Record): Factorize code calling
902         Is_Variable_Size_Array.
903         (Build_CPP_Init_Procedure): New subprogram that builds the tree
904         corresponding to the procedure that initializes the C++ part of the
905         dispatch table of an Ada tagged type that is a derivation of a CPP type.
906         (Build_Init_Procedure): Adding documentation plus code reorganization to
907         leave more clear the construction of the IP with C++ types.
908         (Expand_Freeze_Record_Type): Delay call to Set_CPP_Constructors because
909         it cannot be called after Make_Tags has been invoked.
910         (Inherit_CPP_Tag): Removed.
911         (Init_Secondary_Tags): For derivations of CPP types, warn on tags
912         located at variable offset.
913         * freeze.ads: Minor reformating.
914         * sem_ch8.adb (Write_Scopes): Add pragma export. Required to have it
915         available in gdb.
916         * gcc-interface/Make-lang.in: Update dependencies.
917
918 2010-08-10  Robert Dewar  <dewar@adacore.com>
919
920         * a-chahan.ads: Add comments on handling of obsolescent entries.
921         * opt.ads: Add Ada_2005 and Ada_2012 renamings for versions.
922         * restrict.adb (Check_Obsolescent_2005_Entity): New procedure.
923         * restrict.ads (Check_Obsolescent_2005_Entity): New procedure.
924         * sem_attr.adb (Analyze_Access_Attribute): Call
925         Check_Obsolescent_2005_Entity to check for access to obsolescent
926         Ada.Characters.Handling subprogram.
927         (Analyze_Attribute, case Class): Applying Class to untagged incomplete
928         type is obsolescent in Ada 2005.
929         (Analyze_Attribute, case Constrained): Better placement of flag when
930         flagged as obsolescent feature.
931         (Analyze_Attribute, case Storage_Size): Use with tasks is obsolescent
932         * sem_ch10.adb (Analyze_With_Clause): With of renamings such as Text_IO
933         is an obsolescent feature.
934         * sem_ch11.adb (Analyze_Raise_Statement): Numeric_Error is obsolescent
935         feature.
936         * sem_ch8.adb (Analyze_Subprogram_Renaming): Call
937         Check_Obsolescent_2005_Entity to check for renaming obsolete
938         Ada.Characters.Handling subprogram.
939         * sem_prag.adb (Process_Restrictions_Or_Restriction_Warnings): Check
940         for obsolescent restrictions in Ada 2005.
941         (Analyze_Pragma, case Suppress): Entity arg is obsolescent in Ada 2005
942         (Analyze_Pragma, case Interface): Interface is obsolescent in Ada 2005
943         * sem_res.adb (Resolve_Call): Call Check_Obsolescent_2005_Entity to
944         check for obsolescent references to Ada.Characters.Handling subprograms
945
946 2010-08-10  Robert Dewar  <dewar@adacore.com>
947
948         * einfo.adb, einfo.ads: Fix bad -gnatdt output for incomplete type.
949
950 2010-08-10  Robert Dewar  <dewar@adacore.com>
951
952         * errout.ads: Add VMS table entries for 2005, 12, 2012 switches
953         * par-ch4.adb: Change wording of Ada 2012 messages
954         * vms_data.ads: Add VMS entries for /2005, /12, /2012
955
956 2010-08-10  Robert Dewar  <dewar@adacore.com>
957
958         * a-suenco.adb (Convert): Fix bug in UTF-16 to UTF-8 conversion for
959         codes in the range 16#80#..16#7FF#.
960         * sem_ch10.adb: Minor reformatting.
961
962 2010-08-10  Arnaud Charlet  <charlet@adacore.com>
963
964         * gnat1drv.adb (Scan_Front_End_Switches): Always perform semantics and
965         generate ali files in CodePeer mode, so that a gnatmake -c -k will
966         proceed further when possible
967         * freeze.adb (Freeze_Static_Object): Fix thinko. Do not generate error
968         messages when ignoring representation clauses (-gnatI).
969
970 2010-08-10  Ed Schonberg  <schonberg@adacore.com>
971
972         * exp_ch4.adb (Expand_N_Selected_Component): Do not attempt to
973         constant-fold discriminant reference if the constraint is an object
974         with non-static expression. Expression may contain volatile references
975         in the presence of renamings.
976
977 2010-08-10  Vincent Celier  <celier@adacore.com>
978
979         * prj-proc.adb (Get_Attribute_Index): If Index is All_Other_Names,
980         returns Index.
981         * prj-strt.adb (Attribute_Reference): Recognize 'others' as a valid
982         index for an associative array where it is allowed.
983
984 2010-08-10  Thomas Quinot  <quinot@adacore.com>
985
986         * exp_attr.adb: Add comments.
987
988 2010-08-10  Jerome Lambourg  <lambourg@adacore.com>
989
990         * adaint.c (__gnat_get_file_names_case_sensitive): return 0 on darwin.
991
992 2010-08-09  Nathan Froyd  <froydnj@codesourcery.com>
993
994         * gcc-interface/utils.c (gnat_poplevel): Use blocks_nreverse.
995
996 2010-08-09  Eric Botcazou  <ebotcazou@adacore.com>
997
998         * gcc-interface/utils.c (build_vms_descriptor32): Fix formatting.
999         (build_vms_descriptor): Likewise.
1000
1001 2010-08-08  Nathan Froyd  <froydnj@codesourcery.com>
1002
1003         * gcc-interface/utils.c (make_descriptor_field): Add tree parameter.
1004         (build_vms_descriptor32): Adjust calls to it for new parameter.
1005         (build_vms_descriptor): Likewise.
1006
1007 2010-08-08  Nathan Froyd  <froydnj@codesourcery.com>
1008
1009         * gcc-interface/decl.c (rec_variant):  Declare.  Declare a VEC of it.
1010         (build_variant_list): Take and return a VEC instead of a tree.
1011         (create_variant_part_from): Take a VEC instead of a tree for
1012         variant_list.  Adjust accordingly.
1013         (gnat_to_gnu_entity): Adjust for changes to previous functions.
1014
1015 2010-08-07  Nathan Froyd  <froydnj@codesourcery.com>
1016
1017         * gcc-interface/decl.c (gnat_to_gnu_entity): Use XALLOCAVEC instead
1018         of alloca.
1019         (components_to_record): Likewise.
1020         * gcc-interface/trans.c (gnat_to_gnu): Likewise.
1021         * gcc-interface/utils.c (max_size): Likewise.
1022         (build_vms_descriptor32): Likewise.
1023         (build_vms_descriptor): Likewise.
1024
1025 2010-08-07  Nathan Froyd  <froydnj@codesourcery.com>
1026
1027         * gcc-interface/decl.c (subst_pair): Declare.  Declare a VEC of it.
1028         (build_subst_list): Return a VEC instead of a tree.
1029         (build_variant_list): Take a VEC for subst_list.  Adjust
1030         accordingly.
1031         (create_field_decl_from): Likewise.
1032         (create_variant_part_from): Likewise.
1033         (copy_and_substitute_in_size): Likewise.
1034         (gnat_to_gnu_entity): Adjust for new interface to build_subst_list.
1035         Free the built vector.
1036
1037 2010-08-06  Eric Botcazou  <ebotcazou@adacore.com>
1038
1039         * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Do not build an
1040         allocator for large imported objects.
1041
1042 2010-08-05  Robert Dewar  <dewar@adacore.com>
1043
1044         * gnat1drv.adb: Minor reformatting.
1045
1046 2010-08-05  Ed Schonberg  <schonberg@adacore.com>
1047
1048         * sem.adb (Do_Unit_And_Dependents): If some parent unit is an
1049         instantiation, process its body before the spec of the main unit,
1050         because it may contain subprograms invoked in the spec of main.
1051         * einfo.ads: Add documention of delayed freeze.
1052
1053 2010-08-05  Vincent Celier  <celier@adacore.com>
1054
1055         * prj-nmsc.adb (Process_Linker): Take into account new values for
1056         attribute Response_File_Format.
1057         * prj.ads (Response_File_Format): New enumeration values GCC_GNU,
1058         GCC_Object_List and GCC_Option_List.
1059
1060 2010-08-05  Ed Schonberg  <schonberg@adacore.com>
1061
1062         * exp_ch4.adb (Expand_N_Selected_Component): Do not constant-fold a
1063         selected component that denotes a discriminant if it is the
1064         discriminant of a component of an unconstrained record type.
1065
1066 2010-08-05  Ed Schonberg  <schonberg@adacore.com>
1067
1068         * exp_util.adb (Insert_Actions): If the action appears within a
1069         conditional expression that is already analyzed, insert action further
1070         out.
1071
1072 2010-08-05  Robert Dewar  <dewar@adacore.com>
1073
1074         * exp_ch4.adb: Minor reformatting.
1075
1076 2010-08-05  Thomas Quinot  <quinot@adacore.com>
1077
1078         * exp_ch4.adb: Minor reformatting
1079         * gnat1drv.adb: Minor reformatting.
1080         Minor code reorganization (use Nkind_In).
1081
1082 2010-08-05  Ed Schonberg  <schonberg@adacore.com>
1083
1084         * exp_util.ads, exp_util.adb (Needs_Constant_Address): New predicate to
1085         determine whether the expression in an address clause for an
1086         initialized object must be constant. Code moved from freeze.adb.
1087         (Remove_Side_Effects): When the temporary is initialized with a
1088         reference, indicate that the temporary is a constant as done in all
1089         other cases.
1090         * freeze.adb (Check_Address_Clause): use Needs_Constant_Address.
1091         * exp_ch13.adb (Expand_N_Attribute_Definition_Clause, case 'Address):
1092         If object does not need a constant address, remove side effects from
1093         address expression, so it is elaborated at the point of the address
1094         clause and not at the freeze point of the object, so that elaboration
1095         order is respected.
1096
1097 2010-08-05  Vincent Celier  <celier@adacore.com>
1098
1099         * prj.adb (Is_Compilable): Return False for header files of non Ada
1100         languages.
1101
1102 2010-08-05  Emmanuel Briot  <briot@adacore.com>
1103
1104         * prj-nmsc.adb: The Missing_Source_Files flag also considers a missing
1105         exec directory as a warning rather than an error.
1106
1107 2010-08-05  Thomas Quinot  <quinot@adacore.com>
1108
1109         * sem_ch6.adb, gnat1drv.adb, exp_ch6.adb, sem_eval.adb: Minor
1110         reformatting.
1111
1112 2010-08-05  Steve Baird  <baird@adacore.com>
1113
1114         * exp_util.adb (Remove_Side_Effects): An access value which designates
1115         a volatile object of a nonvolatile type is prohibited.
1116         Do not call Make_Reference to construct a reference to such an object.
1117
1118 2010-08-05  Robert Dewar  <dewar@adacore.com>
1119
1120         * a-suezse.adb, a-suezse.ads, a-suezen.adb, a-suezen.ads: Removed.
1121         * a-suewse.adb, a-suewse.ads, a-suesen.adb, a-suesen.ads,
1122         a-suewen.adb, a-suewen.ads: New files.
1123         * Makefile.rtl, impunit.adb: Update implementation of Ada 2012 string
1124         encoding packages.
1125         * sem_elab.adb: Minor reformatting.
1126
1127 2010-08-05  Arnaud Charlet  <charlet@adacore.com>
1128
1129         * sem_ch8.adb (Use_One_Type): Protect against empty scopes.
1130         * exp_util.adb (Component_May_Be_Bit_Aligned): Prevent assert failure
1131         in case of null Comp.
1132
1133 2010-08-05  Robert Dewar  <dewar@adacore.com>
1134
1135         * errout.adb, a-suewen.adb, a-suezen.adb: Minor reformatting.
1136
1137 2010-08-05  Gary Dismukes  <dismukes@adacore.com>
1138
1139         * sem_ch4.adb (Analyze_Allocator): Flag errors on allocators of a
1140         nested access type whose designated type has tasks or is a protected
1141         object when the restrictions No_Task_Hierarchy or
1142         No_Local_Protected_Objects apply. Add ??? comment.
1143         * sem_ch9.adb (Analyze_Protected_Type): Give a warning when a protected
1144         type is not a library-level type and No_Local_Protected_Objects applies.
1145         (Analyze_Task_Type): Give a warning when a task type is not a
1146         library-level type and No_Task_Hierarchy applies.
1147
1148 2010-08-05  Arnaud Charlet  <charlet@adacore.com>
1149
1150         * sem.adb: Minor reformatting
1151         * sem_ch4.adb (Analyze_Reference): Disable error message in CodePeer
1152         mode, not useful.
1153
1154 2010-08-04  Eric Botcazou  <ebotcazou@adacore.com>
1155
1156         * gcc-interface/decl.c: Do not undefine IN_GCC_FRONTEND and do not
1157         include expr.h.
1158         (gnat_to_gnu_entity) <object>: Force address of -1 at the tree level
1159         for the debug-only entity.
1160         * gcc-interface/Make-lang.in (ada/decl.o): Adjust dependencies.
1161
1162 2010-08-03  Joseph Myers  <joseph@codesourcery.com>
1163
1164         * gcc-interface/lang-specs.h: Don't pass -a options.
1165
1166 2010-07-28  Joseph Myers  <joseph@codesourcery.com>
1167
1168         * gcc-interface/misc.c (gnat_init_options): Ignore erroneous
1169         options.  Check canonical_option_num_elements on options copied.
1170
1171 2010-07-27  Joseph Myers  <joseph@codesourcery.com>
1172
1173         * gcc-interface/misc.c (gnat_handle_option): Update prototype and
1174         return value type.  Don't check for missing arguments here.
1175
1176 2010-07-27  Joseph Myers  <joseph@codesourcery.com>
1177
1178         * gcc-interface/misc.c (gnat_option_lang_mask): New.
1179         (gnat_init_options): Update prototype.  Reconstruct argv array
1180         from decoded options.
1181
1182 2010-07-23  Eric Botcazou  <ebotcazou@adacore.com>
1183
1184         * gcc-interface/utils.c (update_pointer_to): In the unconstrained array
1185         case, merge the alias set of the old pointer type.
1186
1187 2010-07-23  Eric Botcazou  <ebotcazou@adacore.com>
1188
1189         * gcc-interface/utils.c (gnat_types_compatible_p): Revert latest change
1190         and recurse only for multidimensional array types instead.
1191
1192 2010-07-22  Eric Botcazou  <ebotcazou@adacore.com>
1193
1194         PR ada/44892
1195         * gcc-interface/utils.c (convert): Fix thinko in test.
1196         (unchecked_convert): When converting from a scalar type to a type with
1197         a different size, pad to have the same size on both sides.
1198
1199 2010-07-22  Eric Botcazou  <ebotcazou@adacore.com>
1200
1201         * gcc-interface/utils.c (gnat_types_compatible_p): Don't require strict
1202         equality for the component type of array types.
1203
1204 2010-07-15  Nathan Froyd  <froydnj@codesourcery.com>
1205
1206         * gcc-interface/decl.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
1207         * gcc-interface/trans.c: Likewise.
1208         * gcc-interface/utils.c: Likewise.
1209         * gcc-interface/utils2.c: Likewise.
1210
1211 2010-07-13  Laurent GUERBY  <laurent@guerby.net>
1212
1213         PR bootstrap/44458
1214         * gcc-interface/targtyps.c: Include tm_p.h.
1215         * gcc-interface/Make-lang.in: Update dependencies.
1216
1217 2010-07-09  Eric Botcazou  <ebotcazou@adacore.com>
1218
1219         * gcc-interface/trans.c (gnat_gimplify_expr) <ADDR_EXPR>: Deal with
1220         CALL_EXPR.
1221
1222 2010-07-08  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1223
1224         * gcc-interface/utils.c: Include diagnostic-core.h in every file
1225         that includes toplev.h.
1226
1227 2010-07-03  Eric Botcazou  <ebotcazou@adacore.com>
1228
1229         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Enumeration_Type>:
1230         Branch to common code handling the alignment of discrete types.
1231         <E_Signed_Integer_Type>: Likewise.
1232         <E_Modular_Integer_Type>: Likewise.
1233
1234 2010-07-02  Eric Botcazou  <ebotcazou@adacore.com>
1235
1236         * gcc-interface/misc.c (gnat_handle_option): Do not populate gnat_argv.
1237         (gnat_handle_option): Allocate only one element for gnat_argv.
1238         (gnat_init): Do not populate gnat_argv.
1239
1240 2010-06-30  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1241
1242         * gcc-interface/trans.c: Do not include tree-flow.h.
1243         * gcc-interface/Make-lang.in: Adjust dependencies.
1244
1245 2010-06-29  Nathan Froyd  <froydnj@codesourcery.com>
1246
1247         * gcc-interface/gigi.h (gnat_build_constructor): Take a VEC instead
1248         of a TREE_LIST.  Update comment.
1249         * gcc-interface/trans.c (gigi): Build a VEC instead of a TREE_LIST.
1250         Adjust call to gnat_build_constructor.
1251         (Attribute_to_gnu): Likewise.
1252         (gnat_to_gnu): Likewise.
1253         (pos_to_constructor): Likewise.
1254         (extract_values): Likewise.
1255         * gcc-interface/utils.c (build_template): Likewise.
1256         (convert_vms_descriptor64): Likewise.
1257         (convert_vms_descriptor32): Likewise.
1258         (convert_to_fat_pointer): Likewise.
1259         (convert): Likewise.
1260         (unchecked_convert): Likewise.
1261         * gcc-interface/decl.c (gnat_to_gnu_entity): Likewise.
1262         * gcc-interface/utils2.c (build_allocator): Likewise.
1263         (fill_vms_descriptor): Likewise.
1264         (gnat_build_constructor): Take a VEC instead of a TREE_LIST.
1265         (compare_elmt_bitpos): Adjust for parameters being constructor_elts
1266         instead of TREE_LISTs.
1267
1268 2010-06-28  Steven Bosscher  <steven@gcc.gnu.org>
1269
1270         * gcc-interface/misc.c: Do not include except.h.
1271         * gcc-interface/Make-lang.in: Update dependencies.
1272
1273 2010-06-27  Eric Botcazou  <ebotcazou@adacore.com>
1274
1275         * gcc-interface/trans.c: Include tree-flow.h.
1276         (gnu_switch_label_stack): Delete.
1277         (Case_Statement_to_gnu): Do not emit the goto at the end of a case if
1278         its associated block cannot fall through.  Do not emit the final label
1279         if no cases branch to it.
1280         * gcc-interface/Make-lang.in (ada/trans.o): Add $(TREE_FLOW_H).
1281
1282 2010-06-23  Thomas Quinot  <quinot@adacore.com>
1283
1284         * exp_attr.adb (Expand_Access_To_Protected_Op): When rewriting a
1285         reference to a protected subprogram outside of the protected's scope,
1286         ensure the corresponding external subprogram is frozen before the
1287         reference.
1288
1289 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1290
1291         * sem_prag.adb: Fix typo in error message.
1292         * sem.adb: Refine previous change.
1293
1294 2010-06-23  Robert Dewar  <dewar@adacore.com>
1295
1296         * impunit.adb, a-suewen.adb, a-suewen.ads, a-suenco.adb, a-suenco.ads,
1297         a-suezen.adb, a-suezen.ads, a-stuten.adb, a-stuten.ads, Makefile.rtl:
1298         Implement Ada 2012 string encoding packages.
1299
1300 2010-06-23  Arnaud Charlet  <charlet@adacore.com>
1301
1302         * a-stwiun-shared.adb, a-stwiun-shared.ads, a-stzunb-shared.adb,
1303         a-stzunb-shared.ads, a-swunau-shared.adb, a-swuwti-shared.adb,
1304         a-szunau-shared.adb, a-szuzti-shared.adb, a-strunb-shared.adb,
1305         a-strunb-shared.ads, a-stunau-shared.adb, a-suteio-shared.adb: New
1306         files.
1307         * gcc-interface/Makefile.in: Enable use of above files.
1308
1309 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1310
1311         * sem_ch13.adb (Check_Constant_Address_Clauses): Do not check legality
1312         of address clauses if if Ignore_Rep_Clauses is active.
1313         * freeze.adb (Check_Address_Clause): If Ignore_Rep_Clauses is active,
1314         remove address clause from tree so that it does not reach the backend.
1315
1316 2010-06-23  Arnaud Charlet  <charlet@adacore.com>
1317
1318         * exp_attr.adb (Expand_N_Attribute_Reference [Attribute_Valid]): Do not
1319         expand 'Valid from user code in CodePeer mode, will be handled by the
1320         back-end directly.
1321
1322 2010-06-23  Bob Duff  <duff@adacore.com>
1323
1324         * g-comlin.ads: Minor comment improvements.
1325
1326 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1327
1328         * sem_res.adb (Uses_SS): The expression that initializes a controlled
1329         component of a record type may be a user-defined operator that is
1330         rewritten as a function call.
1331
1332 2010-06-23  Bob Duff  <duff@adacore.com>
1333
1334         * g-comlin.ads, sem_ch13.adb: Minor comment fix.
1335
1336 2010-06-23  Eric Botcazou  <ebotcazou@adacore.com>
1337
1338         * exp_ch11.adb (Expand_Local_Exception_Handlers): Propagate the end
1339         label to the new sequence of statements.  Set the sloc of the raise
1340         statement onto the new goto statements.
1341
1342 2010-06-23  Robert Dewar  <dewar@adacore.com>
1343
1344         * a-stuten.ads, a-stuten.adb: New files.
1345         * impunit.adb: Add engtry for Ada.Strings.UTF_Encoding (a-stuten.ads)
1346         * Makefile.rtl: Add entry for a-stuten (Ada.Strings.UTF_Encoding)
1347
1348 2010-06-23  Robert Dewar  <dewar@adacore.com>
1349
1350         * gnat_ugn.texi: Add documentation of -gnat12 switch
1351         Add documentation of -gnatX switch.
1352
1353 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1354
1355         * inline.ads: Include the current Ada_Version in the info for pending
1356         instance bodies, so that declaration and body are compiled with the
1357         same Ada_Version.
1358         * inline.adb: Move with_clause for Opt to spec.
1359         * sem_ch12.adb (Analyze_Package_Instantiation,
1360         Analyze_Subprogram_Instantiation): Save current Ada_Version in
1361         Pending_Instantiation information.
1362         (Instantiate_Package_Body, Instantiate_Subprogram_Body,
1363         Inline_Package_Body): Use the Ada_Version present in the body
1364         information.
1365
1366 2010-06-23  Robert Dewar  <dewar@adacore.com>
1367
1368         * usage.adb: Add documentation for -gnat12 switch.
1369         * errout.ads: Add VMS alias entry for -gnat12 switch
1370         * gnat_rm.texi: Add documentation for pragma Ada_12 and Ada_2012
1371         Add documentation for pragma Extensions_Allowed.
1372         * opt.ads: Add entry for Ada 2012 mode.
1373         * sem_ch4.adb, par-ch3.adb, par-ch4.adb: Use new Ada 2012 mode for 2012
1374         features.
1375         * sem_prag.adb, par-prag.adb: Add processing for pragma Ada_12 and
1376         Ada_2012.
1377         * sem_ch13.adb: Add handling for Ada 2012 mode.
1378         * snames.ads-tmpl: Add entries for pragma Ada_2012 and Ada_12.
1379         * switch-c.adb: Add handling for -gnat12 switch.
1380         Implement -gnat2005 and -gnat2012.
1381         * usage.adb: Add documentation for -gnat12 switch.
1382         * vms_data.ads: Add /12 switch for Ada 2012 mode.
1383
1384 2010-06-23  Arnaud Charlet  <charlet@adacore.com>
1385
1386         * exp_ch4.adb (Expand_N_Allocator): Fix potential crash when using
1387         No_Task_Hierarchy restriction. Add comment.
1388         * exp_ch9.adb, exp_ch3.adb: Update comments.
1389
1390 2010-06-23  Robert Dewar  <dewar@adacore.com>
1391
1392         * sem_ch5.adb (Process_Bounds): Remove some junk initializations.
1393         * sem_res.adb: Add comments.
1394         * sem_util.adb: Minor reformatting. Add comments.
1395         Change increment on Actuals_In_Call table.
1396         * opt.ads: Minor: add 'constant'.
1397
1398 2010-06-23  Javier Miranda  <miranda@adacore.com>
1399
1400         * exp_disp.adb (Make_DT): Initialize the Size_Func component of the
1401         TSD to Null_Address if No_Dispatching_Calls is active.
1402
1403 2010-06-23  Vincent Celier  <celier@adacore.com>
1404
1405         * a-comlin.ads: Indicate that use of this package is not supported
1406         during the elaboration of an auto-initialized Stand-Alone Library.
1407
1408 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1409
1410         * exp_util.adb (Is_Possibly_Misaligned_Object): Do not rely on an
1411         alignment clause on a record type to determine if a component may be
1412         misaligned. The decision must be taken in the back-end where target
1413         alignment information is known.
1414
1415 2010-06-23  Arnaud Charlet  <charlet@adacore.com>
1416
1417         * gnat1drv.adb (Adjust_Global_Switches): Enable some restrictions
1418         systematically in CodePeer mode to simplify generated code.
1419         * restrict.adb (Check_Restriction): Do nothing in CodePeer mode.
1420         * exp_ch4.adb (Expand_N_Allocator): Generate proper code when
1421         No_Task_Hierarchy is set instead of crasshing.
1422
1423 2010-06-23  Thomas Quinot  <quinot@adacore.com>
1424
1425         * sem_util.adb: Minor code cleanup: test for proper entity instead of
1426         testing just Chars attribute when checking whether a given scope is
1427         System.
1428         * exp_ch4.adb, einfo.adb: Minor reformatting.
1429
1430 2010-06-23  Vincent Celier  <celier@adacore.com>
1431
1432         PR ada/44633
1433         * switch-m.adb (Normalize_Compiler_Switches): Take into account
1434         switches -gnatB, -gnatD=nn, -gnatG (incuding -gnatG=nn), -gnatI,
1435         -gnatl=file, -gnatS, -gnatjnn, -gnateI=nn and -gnatWx.
1436
1437 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1438
1439         * sem_res.adb (Resolve_Membership_Op): If left operand is a mixed mode
1440         operation with a universal real operand, and the right operand is a
1441         range with universal bounds, find unique fixed point that may be
1442         candidate, and warn appropriately.
1443
1444 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1445
1446         * sem_res.adb (Resolve_Intrinsic_Operator): Add guards to handle
1447         properly the rare cases where VMS operators are visible through
1448         Extend_System, but the default System is being used and Address is a
1449         private type.
1450         * sem_util.adb: Widen predicate Is_VMS_Operator.
1451
1452 2010-06-23  Vincent Celier  <celier@adacore.com>
1453
1454         * switch-m.adb (Normalize_Compiler_Switches): Take into account -gnatC
1455         and -gnateS.
1456
1457 2010-06-23  Olivier Hainque  <hainque@adacore.com>
1458
1459         * einfo.adb (Has_Foreign_Convention): Consider Intrinsic with
1460         Interface_Name as foreign. These are GCC builtin imports for
1461         which Ada specific processing doesn't apply.
1462
1463 2010-06-23  Thomas Quinot  <quinot@adacore.com>
1464
1465         * sem_ch12.adb: Minor reformatting.
1466
1467 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1468
1469         * sem_util.adb (Is_VMS_Operator): Use scope of system extension to
1470         determine whether an intrinsic subprogram is VMS specific.
1471
1472 2010-06-23  Hristian Kirtchev  <kirtchev@adacore.com>
1473
1474         * treepr.adb (Print_Entity_Info): Output the contents of Field28 if it
1475         is present in the entity.
1476
1477 2010-06-23  Arnaud Charlet  <charlet@adacore.com>
1478
1479         * xr_tabls.adb, xref_lib.adb: Update to latest lib-xref.ads
1480         Fix handling of parameters.
1481         Add protection against unexpected cases.
1482         * sem_ch6.adb (Create_Extra_Formals): Use suffix "L" instead of "A" for
1483         access level, since "A" suffix is already used elsewhere. Similarly,
1484         use suffix "O" instead of "C" for 'Constrained since "C" suffix is used
1485         for xxx'Class.
1486
1487 2010-06-23  Thomas Quinot  <quinot@adacore.com>
1488
1489         * sem_util.adb, sem_util.ads: Minor reformatting.
1490
1491 2010-06-23  Vincent Celier  <celier@adacore.com>
1492
1493         * prj.ads (Gprclean_Flags.Missing_Source_Files): Set to Error to keep
1494         the previous behavior of gprclean when there are missing files.
1495
1496 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1497
1498         * sem_ch12.adb (Load_Body_Of_Generic): In CodePeer mode, a missing
1499         generic body is not a fatal error.
1500         (Mark_Context): Handle properly names of child units.
1501         * sem.adb (Walk_Library_Items.Do_Action): Remove assertion on
1502         instantiations.
1503
1504 2010-06-23  Vincent Celier  <celier@adacore.com>
1505
1506         * ali.adb (Scan_ALI): When ignoring R lines, do not skip the next
1507         non-empty line.
1508
1509 2010-06-23  Bob Duff  <duff@adacore.com>
1510
1511         * g-pehage.ads, g-pehage.adb: Switch default optimization mode to
1512         Memory_Space, because CPU_Time doesn't seem to provide any significant
1513         speed advantage in practice. Cleanup: Get rid of constant
1514         Default_Optimization; doesn't seem to add anything. Use case
1515         statements instead of if statements; seems cleaner.
1516
1517 2010-06-23  Olivier Hainque  <hainque@adacore.com>
1518
1519         * gcc-interface/decl.c (gnat_to_gnu_entity) <case E_Procedure>: Use
1520         Wshadow instead of Wextra to guard warning on absence of internal
1521         builtin decl for an import.  Fix use of quote in warning text.
1522         (intrin_arglists_compatible_p): Remove processing of integer trailing
1523         args on the Ada side.  Fix use of literal > in warning text.
1524         (intrin_return_compatible_p): Never warn on "function imported as
1525         procedure".  Defer the void/void case to the common type compatibility
1526         check.
1527         (gnat_to_gnu_param): Use void_ptr GCC type for System.Address argument
1528         of GCC builtin imports.
1529
1530 2010-06-23  Olivier Hainque  <hainque@adacore.com>
1531
1532         * gcc-interface/decl.c (intrin_types_incompatible_p): New function,
1533         helper for ...
1534         (intrin_arglists_compatible_p, intrin_return_compatible_p): New
1535         functions, helpers for ...
1536         (intrin_profiles_compatible_p): New function, replacement for ...
1537         (compatible_signatures_p): Removed.
1538         (gnat_to_gnu_entity) <case E_Procedure>: If -Wextra, warn on
1539         attempt to bind an unregistered builtin function.  When we have
1540         one, use it and warn on profile incompatibilities.
1541
1542 2010-06-23  Arnaud Charlet  <charlet@adacore.com>
1543
1544         * gcc-interface/Make-lang.in: Update dependencies.
1545
1546 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1547
1548         * sem_util.adb (Mark_Coextensions): If the expression in the allocator
1549         for a coextension in an object declaration is a concatenation, treat
1550         coextension as dynamic.
1551
1552 2010-06-23  Javier Miranda  <miranda@adacore.com>
1553
1554         * sem_ch3.adb (Add_Internal_Interface_Entities): Ensure that the
1555         internal entities are added to the scope of the tagged type.
1556         (Derive_Subprograms): Do not stop derivation when we find the first
1557         internal entity that has attribute Interface_Alias. After the change
1558         done to Override_Dispatching_Operations it is no longer true that
1559         these primirives are always located at the end of the list of
1560         primitives.
1561         * einfo.ads (Primitive_Operations): Add documentation.
1562         * exp_disp.adb (Write_DT): Improve output adding to the name of the
1563         primitive a prefix indicating its corresponding tagged type.
1564         * sem_disp.adb (Override_Dispatching_Operations): If the overridden
1565         entity covers the primitive of an interface that is not an ancestor of
1566         this tagged type then the new primitive is added at the end of the list
1567         of primitives.  Required to fulfill the C++ ABI.
1568
1569 2010-06-23  Javier Miranda  <miranda@adacore.com>
1570
1571         * atree.ads (Set_Reporting_Proc): New subprogram.
1572         * atree.adb: Remove dependency on packages Opt and SCIL_LL.
1573         (Allocate_Initialize_Node, Replace, Rewrite): Replace direct calls
1574         to routines of package Scil_ll by indirect call to the registered
1575         subprogram.
1576         (Set_Reporting_Proc): New subprogram. Used to register a subprogram
1577         that is invoked when a node is allocated, replaced or rewritten.
1578         * scil_ll.adb (Copy_SCIL_Node): New routine that takes care of copying
1579         the SCIL node. Used as argument for Set_Reporting_Proc.
1580         (Initialize): Register Copy_SCIL_Node as the reporting routine that
1581         is invoked by atree.
1582
1583 2010-06-23  Thomas Quinot  <quinot@adacore.com>
1584
1585         * sem_ch3.ads: Minor reformatting.
1586
1587 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1588
1589         * sem_ch12.adb (Analyze_Package_Instantiation): In CodePeer mode,
1590         always analyze the generic body and instance, because it may be needed
1591         downstream.
1592         (Mark_Context): Prepend the with clauses for needed generic units, so
1593         they appear in a better order for CodePeer.
1594         * sem_util.adb, sem_util.ads: Prototype code for AI05-0144.
1595
1596 2010-06-23  Emmanuel Briot  <briot@adacore.com>
1597
1598         * prj.ads, prj-nmsc.adb (Error_Or_Warning): New subprogram.
1599
1600 2010-06-23  Robert Dewar  <dewar@adacore.com>
1601
1602         * g-pehage.adb, exp_ch13.adb: Minor reformatting.
1603
1604 2010-06-23  Thomas Quinot  <quinot@adacore.com>
1605
1606         * a-tags.ads: Fix description of TSD structure.
1607
1608 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1609
1610         * sem_ch12.adb (Mark_Context): When indicating that the body of a
1611         generic unit is needed prior to the unit containing an instantiation,
1612         search recursively the context of the generic to add other generic
1613         bodies that may be instantiated indirectly through the current instance.
1614
1615 2010-06-23  Robert Dewar  <dewar@adacore.com>
1616
1617         * freeze.adb: Minor reformatting.
1618
1619 2010-06-23  Bob Duff  <duff@adacore.com>
1620
1621         * g-pehage.adb (Trim_Trailing_Nuls): Fix the code to match the comment.
1622
1623 2010-06-23  Vincent Celier  <celier@adacore.com>
1624
1625         * make.adb (Compile_Sources): Complete previous change.
1626
1627 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1628
1629         * sem_ch6.adb (Add_Extra_Formal): Use suffix "C" in the name of the
1630         Constrained extra formal.
1631
1632 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1633
1634         * exp_ch13.adb (Expand_Freeze_Actions): If validity checks and
1635         Initialize_Scalars are enabled, compile the generated equality function
1636         for a composite type with full checks enabled, so that validity checks
1637         are performed on individual components.
1638
1639 2010-06-23  Emmanuel Briot  <briot@adacore.com>
1640
1641         * prj.adb, prj.ads, prj-nmsc.adb (Processing_Flags): New flag
1642         Missing_Source_Files.
1643
1644 2010-06-23  Robert Dewar  <dewar@adacore.com>
1645
1646         * exp_ch3.adb, exp_util.adb: Minor reformatting.
1647
1648 2010-06-23  Jose Ruiz  <ruiz@adacore.com>
1649
1650         * a-reatim.adb, a-retide.adb: Move the initialization of the tasking
1651         run time from Ada.Real_Time.Delays to Ada.Real_Time. This way, calls to
1652         Clock (without delays) use a run time which is properly initialized.
1653
1654 2010-06-23  Vincent Celier  <celier@adacore.com>
1655
1656         * make.adb: Do not set Check_Readonly_Files when setting Must_Compile,
1657         when -f -u and a main is specified on the command line. However,
1658         attempt to compile even when the ALI file is read-only when
1659         Must_Compile is True.
1660
1661 2010-06-23  Thomas Quinot  <quinot@adacore.com>
1662
1663         * checks.adb, g-pehage.adb, cstand.adb: Minor code factorization.
1664
1665 2010-06-23  Javier Miranda  <miranda@adacore.com>
1666
1667         * sem_ch3.adb (Add_Internal_Interface_Entities): Generate internal
1668         entities for parent types that are interfaces. Needed in generics to
1669         handle formals that implement interfaces.
1670         (Derive_Subprograms): Add assertion for derivation of tagged types that
1671         do not cover interfaces. For generics, complete code that handles
1672         derivation of type that covers interfaces because the previous
1673         condition was weak (it required only name consistency; arguments were
1674         not checked). Add new code to locate primitives covering interfaces
1675         defined in generic units or instantiatons.
1676         * sem_util.adb (Has_Interfaces): Add missing support for derived types.
1677         * sem_ch6.adb (Check_Overriding_Indicator): Minor code cleanups.
1678         * exp_disp.adb (Make_Select_Specific_Data_Table): Skip primitives of
1679         interfaces that are parents of the type because they share the primary
1680         dispatch table.
1681         (Register_Primitive): Do not register primitives of interfaces that
1682         are parents of the type.
1683         * sem_ch13.adb (Analyze_Freeze_Entity): Add documentation.
1684         * exp_cg.adb (Write_Type_Info): When displaying overriding of interface
1685         primitives skip primitives of interfaces that are parents of the type.
1686
1687 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1688
1689         * sem_attr.adb (Eval_Attribute): If the prefix is an array, the
1690         attribute cannot be constant-folded if an index type is a formal type,
1691         or is derived from one.
1692         * checks.adb (Determine_Range): ditto.
1693
1694 2010-06-23  Arnaud Charlet  <charlet@adacore.com>
1695
1696         * gnat_ugn.texi, gnatxref.adb: Add support for --ext switch.
1697
1698 2010-06-23  Bob Duff  <duff@adacore.com>
1699
1700         * g-pehage.ads, g-pehage.adb (Put): Fix off-by-one bug.
1701         (Insert): Disallow nul characters.
1702         (misc output routines): Assert no nul characters.
1703
1704 2010-06-23  Ed Schonberg  <schonberg@adacore.com>
1705
1706         * exp_ch4.adb: Use predefined unsigned type in all cases.
1707
1708 2010-06-23  Bob Duff  <duff@adacore.com>
1709
1710         * s-rannum.adb (Reset): Avoid overflow in calculation of Initiator.
1711         * g-pehage.ads: Minor comment fixes.
1712         * g-pehage.adb: Minor: Add some additional debugging printouts under
1713         Verbose flag.
1714
1715 2010-06-23  Robert Dewar  <dewar@adacore.com>
1716
1717         * binde.adb (Better_Choice): Always prefer Pure/Preelab.
1718         (Worse_Choice): Always prefer Pure/Preelab.
1719
1720 2010-06-23  Vincent Celier  <celier@adacore.com>
1721
1722         * a-reatim.adb: Call System.OS_Primitives.Initialize during elaboration
1723
1724 2010-06-23  Robert Dewar  <dewar@adacore.com>
1725
1726         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Properly handle
1727         checking returns in generic case.
1728         (Check_Missing_Return): New procedure.
1729
1730 2010-06-23  Robert Dewar  <dewar@adacore.com>
1731
1732         * bindgen.adb, switch-b.adb: Minor reformatting.
1733
1734 2010-06-23  Javier Miranda  <miranda@adacore.com>
1735
1736         * frontend.adb (Frontend): Add call to initialize the new package
1737         SCIL_LL.
1738         * exp_ch7.adb (Wrap_Transient_Expression): Remove call to
1739         Adjust_SCIL_Node.
1740         (Wrap_Transient_Statement): Remove call to Adjust_SCIL_Node.
1741         * sem_ch5.adb (Analyze_Iteration_Scheme.Process_Bounds): Remove call to
1742         Adjust_SCIL_Node.
1743         * exp_util.adb (Insert_Actions): Remove code for
1744         N_SCIL_Dispatch_Table_Object_Init and N_SCIL_Tag_Init nodes.
1745         (Remove_Side_Effects): Remove calls to Adjust_SCIL_Node.
1746         * sinfo.adb (SCIL_Entity, SCIL_Tag_Value): Remove checks on
1747         N_SCIL_Tag_Init and N_SCIL_Dispatch_Table_Object_Init in the assertion.
1748         (SCIL_Related_Node, Set_SCIL_Related_Node): Removed.
1749         * sinfo.ads (SCIL_Related_Node): Field removed.
1750         (N_SCIL_Dispatch_Table_Object_Init): Node removed.
1751         (N_SCIL_Tag_Init): Node removed.
1752         * sem_scil.ads, sem_scil.adb (Adjust_SCIL_Node): Removed.
1753         (Check_SCIL_Node): New implementation.
1754         (Find_SCIL_Node): Removed.
1755         * sem.adb (Analyze): Remove management of
1756         N_SCIL_Dispatch_Table_Object_Init and N_SCIL_Tag_Init nodes.
1757         * sem_util.adb (Insert_Explicit_Dereference): Remove call to
1758         Adjust_SCIL_Node.
1759         * exp_ch4.adb (Expand_N_In): Code cleanup: remove call to
1760         Set_SCIL_Related_Node and avoid adding the SCIL node before the
1761         referenced node using Insert_Action because this is not longer required.
1762         (Expand_Short_Circuit_Operator): Remove call to SCIL node.
1763         * exp_ch6.adb (Expand_Call): Remove call to Adjust_SCIL_Node.
1764         * sem_ch4.adb (Analyze_Type_Conversion): Remove call to Adjust_SCIL_Node
1765         * exp_disp.adb (Expand_Dispatching_Call): Minor code reorganization
1766         because we no longer require to generate the SCIL node before the call.
1767         (Make_DT): Remove generation of SCI_Dispatch_Table_Object_Init node.
1768         Remove calls to Set_SCIL_Related_Node and avoid adding the SCIL
1769         nodes before the referenced node using Insert_Action because this
1770         is not longer required.
1771         * atree.adb (Allocate_Initialize_Node, Replace, Rewrite): Add call to
1772         update the SCIL_Node field.
1773         * sprint.adb (Sprint_Node_Actual): Remove code for
1774         N_SCIL_Dispatch_Table_Object_Init and N_SCIL_Tag_Init nodes.
1775         * treepr.adb (Print_Node): Print the SCIL node field (if available).
1776         * exp_ch3.adb (Build_Init_Procedure): Remove generation of
1777         SCIL_Tag_Init nodes.
1778         * scil_ll.ads, scil_ll.adb: New files.
1779         * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
1780         dependencies.
1781
1782 2010-06-23  Robert Dewar  <dewar@adacore.com>
1783
1784         * sem_ch6.adb: Minor reformatting.
1785
1786 2010-06-23  Doug Rupp  <rupp@adacore.com>
1787
1788         * bindusg.adb (Display): Write -Hnn line.
1789         * bindgen.adb (Gen_Adainit_Ada): Write Heap_Size to binder file as 
1790         necessary.
1791         * init.c (__gl_heap_size): Rename from __gl_no_malloc_64 and change
1792         valid values to 32 and 64.
1793         (GNAT$NO_MALLOC_64): Recognize TRUE, 1, FALSE, and 0 in addition to
1794         ENABLE, DISABLE as valid settings.
1795         * switch-b.adb (Scan_Binder_Switches): Process -Hnn switch.
1796         * opt.ads (Heap_Size): New global variable.
1797         * gcc-interface/utils2.c (maybe_wrap_malloc): Remove mostly redundant 
1798         TARGET_MALLOC64 check. Fix comment.
1799
1800 2010-06-23  Robert Dewar  <dewar@adacore.com>
1801
1802         * sem_ch6.adb, exp_ch4.adb, s-rannum.ads, sem.adb, sem_ch12.adb: Minor
1803         reformatting.  Add comments.
1804         * errout.adb (Finalize): Properly adjust warning count when deleting
1805         continuations.
1806
1807 2010-06-22  Robert Dewar  <dewar@adacore.com>
1808
1809         * errout.adb (Finalize): Set Prev pointers.
1810         (Finalize): Delete continuations for deletion by warnings off(str).
1811         * erroutc.ads: Add Prev pointer to error message structure.
1812
1813 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
1814
1815         * sem.adb (Do_Unit_And_Dependents): If the spec of the main unit is a
1816         child unit, examine context of parent units to locate instantiated
1817         generics whose bodies may be needed. 
1818         * sem_ch12.adb: (Mark_Context): if the enclosing unit does not have a
1819         with_clause for the instantiated generic, examine the context of its
1820         parents, to set Withed_Body flag, so that it can be visited earlier.
1821         * exp_ch4.adb (Expand_N_Op_Not): If this is a VMS operator applied to
1822         an unsigned type, use a type of the proper size for the intermediate
1823         value, to prevent alignment problems on unchecked conversion.
1824
1825 2010-06-22  Geert Bosch  <bosch@adacore.com>
1826
1827         * s-rannum.ads Change Generator type to be self-referential to allow
1828         Random to update its argument. Use "in" mode for the generator in the
1829         Reset procedures to allow them to be called from the Ada.Numerics
1830         packages without tricks.
1831         * s-rannum.adb: Use the self-referencing argument to get write access
1832         to the internal state of the random generator.
1833         * a-nudira.ads: Make Generator a derived type of
1834         System.Random_Numbers.Generator.
1835         * a-nudira.adb: Remove use of 'Unrestricted_Access.
1836         Put subprograms in alpha order and add headers.
1837         * g-mbdira.ads: Change Generator type to be self-referential.
1838         * g-mbdira.adb: Remove use of 'Unrestricted_Access.
1839
1840 2010-06-22  Robert Dewar  <dewar@adacore.com>
1841
1842         * freeze.adb: Minor reformatting
1843         Minor code reorganization (use Nkind_In and Ekind_In).
1844
1845 2010-06-22  Bob Duff  <duff@adacore.com>
1846
1847         * gnat1drv.adb (Gnat1drv): Remove the messages that recommend using 
1848         -gnatc when a file is compiled that we cannot generate code for, not
1849         helpful and confusing.
1850
1851 2010-06-22  Vincent Celier  <celier@adacore.com>
1852
1853         * switch-m.adb (Normalize_Compiler_Switches): Process correctly
1854         switches -gnatknn.
1855
1856 2010-06-22  Paul Hilfinger  <hilfinger@adacore.com>
1857
1858         * s-rannum.adb: Replace constants with commented symbols.
1859         * s-rannum.ads: Explain significance of the initial value of the data
1860         structure.
1861
1862 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
1863
1864         * a-ngcoty.adb: Clarify comment.
1865
1866 2010-06-22  Gary Dismukes  <dismukes@adacore.com>
1867
1868         * exp_pakd.adb (Expand_Bit_Packed_Element_Set): Return without
1869         expansion for indexing packed arrays with small power-of-2 component
1870         sizes when the target is AAMP.
1871         (Expand_Packed_Element_Reference): Return without expansion for
1872         indexing packed arrays with small power-of-2 component sizes when the
1873         target is AAMP.
1874
1875 2010-06-22  Geert Bosch  <bosch@adacore.com>
1876
1877         * exp_ch4.adb (Expand_N_In): Do not substitute a valid check for X in
1878         Float'Range.
1879
1880 2010-06-22  Robert Dewar  <dewar@adacore.com>
1881
1882         * g-mbdira.adb, g-mbflra.adb, a-nuflra.adb, a-nudira.adb: Minor comment
1883         updates.
1884
1885 2010-06-22  Doug Rupp  <rupp@adacore.com>
1886
1887         * system-vms.ads, system-vms-zcx.ads: Remove old unused VMS system
1888         packages.
1889         * system-vms_64.ads, system-vms-ia64.ads: Minor reformatting.
1890         (pragma Ident): Add a default ident string in the private part.
1891
1892 2010-06-22  Robert Dewar  <dewar@adacore.com>
1893
1894         * cstand.adb: Minor reformatting.
1895
1896 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
1897
1898         * freeze.adb (Build_And_Analyze_Renamed_Body): For expansion purposes,
1899         recognize the Shift and Rotation intrinsics that are known to the
1900         compiler but have no interface name.
1901
1902 2010-06-22  Geert Bosch  <bosch@adacore.com>
1903
1904         * a-ngcoty.adb ("*"): Rewrite complex multiplication to use proper
1905         scaling in case of overflow or NaN results.
1906
1907 2010-06-22  Robert Dewar  <dewar@adacore.com>
1908
1909         * cstand.adb: Complete previous change.
1910         * g-dirope.ads: Add comment.
1911         * s-stchop.adb, sfn_scan.adb: Minor reformatting.
1912
1913 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
1914
1915         * cstand.adb: Add tree nodes for pragma Pack on string types.
1916
1917 2010-06-22  Javier Miranda  <miranda@adacore.com>
1918
1919         * einfo.ads, einfo.adb (Last_Formal): New synthesized attribute.
1920         * exp_util.adb (Find_Prim_Op): Use new attribute to locate the last
1921         formal of a primitive.
1922         * exp_disp.adb (Is_Predefined_Dispatching_Operation,
1923          Is_Predefined_Dispatching_Alias): Use new attribute to locate the last
1924         formal of a primitive.
1925         * exp_cg.adb (Is_Predefined_Dispatching_Operation): Use new attribute
1926         to obtain the last formal of a primitive.
1927
1928 2010-06-22  Geert Bosch  <bosch@adacore.com>
1929
1930         * sysdep.c, init.c, adaint.c, cstreams.c: Remove conditional code
1931         depending on __EMX__ or MSDOS being defined.
1932         * i-cstrea.ads, gnat_rm.texi: Remove mentions of OS/2, DOS and Xenix.
1933         * a-excpol-abort.adb: Update comment indicating users of the file.
1934         * xref_lib.adb, sfn_scan.adb: Remove mention of OS/2, replace NT by
1935         Windows.
1936         * env.c: Remove empty conditional for MSDOS.
1937         * s-stchop.adb, g-dirope.ads, s-fileio.adb, osint.ads: Remove mention
1938         of OS/2 in comment.
1939
1940 2010-06-22  Robert Dewar  <dewar@adacore.com>
1941
1942         * s-rannum.adb: Minor reformatting.
1943
1944 2010-06-22  Javier Miranda  <miranda@adacore.com>
1945
1946         * sem_aux.adb, sem_aux.ads, sem_util.adb, sem_util.ads, sem_elim.adb,
1947         exp_cg.adb: Minor code reorganization: Move routine Ultimate_Alias from
1948         package Sem_Util to package Sem_Aux.
1949
1950 2010-06-22  Javier Miranda  <miranda@adacore.com>
1951
1952         * exp_disp.adb (Make_Secondary_DT, Make_DT): Minor code cleanup:
1953         remove useless restriction on imported routines when building the
1954         dispatch tables.
1955
1956 2010-06-22  Robert Dewar  <dewar@adacore.com>
1957
1958         * cstand.adb (Create_Standard): Set Has_Pragma_Pack for standard string
1959         types.
1960
1961 2010-06-22  Javier Miranda  <miranda@adacore.com>
1962
1963         * sem_ch4.adb (Collect_Generic_Type_Ops): Protect code that handles
1964         generic subprogram declarations to ensure proper context. Add missing
1965         support for generic actuals.
1966         (Try_Primitive_Operation): Add missing support for concurrent types that
1967         have no Corresponding_Record_Type. Required to diagnose errors compiling
1968         generics or when compiling with no code generation (-gnatc).
1969         * sem_ch9.adb (Analyze_Protected_Type, Analyze_Task_Type): Do not build
1970         the corresponding record type.
1971         * sem_disp.ads, sem_disp.adb (Check_Dispatching_Operation): Complete
1972         documentation. Do minimum decoration when processing a primitive of a
1973         concurrent tagged type that covers interfaces. Required to diagnose
1974         errors in the Object.Operation notation compiling generics or under
1975         -gnatc.
1976         * exp_ch9.ads, exp_ch9.adb (Build_Corresponding_Record): Add missing
1977         propagation of attribute Interface_List to the corresponding record.
1978         (Expand_N_Task_Type_Declaration): Code cleanup.
1979         (Expand_N_Protected_Type_Declaration): Code cleanup.
1980
1981 2010-06-22  Matthew Heaney  <heaney@adacore.com>
1982
1983         * a-convec.adb, a-coinve.adb: Removed 64-bit types Int and UInt.
1984
1985 2010-06-22  Paul Hilfinger  <hilfinger@adacore.com>
1986
1987         * s-rannum.adb (Random_Float_Template): Replace with unbiased version
1988         that is able to produce all representable floating-point numbers in the
1989         unit interval. Remove template parameter Shift_Right, no longer used.
1990         * gnat_rm.texi: Document the period of the pseudo-random number
1991         generator under the description of its algorithm.
1992         * gcc-interface/Make-lang.in: Update dependencies.
1993
1994 2010-06-22  Thomas Quinot  <quinot@adacore.com>
1995
1996         * exp_aggr.adb (Rewrite_Discriminant): Fix predicate used to identify
1997         reference to discriminant (can be an expanded name as well as an
1998         identifier).
1999
2000 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
2001
2002         * exp_ch6.adb: Clarify comment.
2003
2004 2010-06-22  Geert Bosch  <bosch@adacore.com>
2005
2006         * exp_imgv.adb (Expand_Image_Attribute): Treat ordinary fixed point
2007         with decimal small as decimal types, avoiding floating-point arithmetic.
2008         (Has_Decimal_Small): New function.
2009         * einfo.ads, einfo.adb (Aft_Value): New synthesized attributed for
2010         fixed point types.
2011         * sem_attr.adb (Eval_Attribute): Remove Aft_Value function and update
2012         callers to call the new function in Einfo that takes the entity as
2013         parameter.
2014
2015 2010-06-22  Robert Dewar  <dewar@adacore.com>
2016
2017         * sem_ch3.adb, sem_ch8.adb: Minor reformatting.
2018
2019 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2020
2021         * sem_elab.adb: Minor reformatting.
2022
2023 2010-06-22  Vincent Celier  <celier@adacore.com>
2024
2025         * gnatsym.adb: Put the object files in the table in increasing
2026         aphabetical order of base names.
2027
2028 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
2029
2030         * sem_ch8.adb (Set_Entity_Or_Discriminal): New procedure used by
2031         Find_Direct_Name and Find_Expanded_Name, to replace a discriminant with
2032         the corresponding discriminal within a record declaration.
2033
2034 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2035
2036         * exp_aggr.adb (Rewrite_Discriminant): Rewriting must occur only for an
2037         expression referring to a discriminal of the type of the aggregate (not
2038         a discriminal of some other unrelated type), and the prefix in the
2039         generated selected component must come from Lhs, not Obj.
2040
2041 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2042
2043         * sem_ch3.adb (Build_Derived_Record_Type): Fix predicate determining
2044         when to freeze the parent type.
2045
2046 2010-06-22  Robert Dewar  <dewar@adacore.com>
2047
2048         * s-rannum.adb, a-nudira.adb, types.ads, freeze.adb, sem_aggr.adb,
2049         exp_aggr.adb: Minor reformatting.
2050         * gnat_rm.texi: Document GNAT.MBBS_Discrete_Random and
2051         GNAT.MBSS_Float_Random.
2052         * g-mbdira.adb, g-mbflra.adb, g-mbdira.ads, g-mbflra.ads: Fix header.
2053
2054 2010-06-22  Paul Hilfinger  <hilfinger@adacore.com>
2055
2056         * a-nudira.adb, a-nudira.ads, a-nuflra.adb, a-nuflra.ads,
2057         gnat_rm.texi, impunit.adb, Makefile.rtl, s-rannum.adb
2058         (Random_Float_Template, Random): New method of creating
2059         uniform floating-point variables that allow the creation of all machine
2060         values in [0 .. 1).  
2061
2062         * g-mbdira.adb, g-mbflra.adb, g-mbdira.ads, g-mbflra.ads: New file.
2063
2064 2010-06-22  Gary Dismukes  <dismukes@adacore.com>
2065
2066         * sem_ch5.adb (Analyze_Assignment): Revise test for illegal assignment
2067         to abstract targets to check that the type is tagged and comes from
2068         source, rather than only testing for targets of interface types. Remove
2069         premature return.
2070
2071 2010-06-22  Vincent Celier  <celier@adacore.com>
2072
2073         * vms_data.ads: Modify the declarations of qualifiers
2074         /UNCHECKED_SHARED_LIB_IMPORTS to allow the generation of gnat.hlp
2075         without error.
2076
2077 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
2078
2079         * exp_ch6.adb (Is_Build_In_Place_Function): Predicate is false if
2080         expansion is disabled.
2081
2082 2010-06-22  Robert Dewar  <dewar@adacore.com>
2083
2084         * makeusg.adb: Minor reformatting.
2085
2086 2010-06-22  Robert Dewar  <dewar@adacore.com>
2087
2088         * types.ads: (Dint): Removed, no longer used anywhere.
2089         * uintp.adb (UI_From_CC): Use UI_From_Int, range is sufficient.
2090         (UI_Mul): Avoid use of UI_From_Dint.
2091         (UI_From_Dint): Removed, not used.
2092         * uintp.ads (UI_From_Dint): Removed, not used.
2093         (Uint_Min/Max_Simple_Mul): New constants.
2094
2095 2010-06-22  Vincent Celier  <celier@adacore.com>
2096
2097         * clean.adb (Parse_Cmd_Line): Recognize switch
2098         --unchecked-shared-lib-imports.
2099         (Usage): Add line for switch --unchecked-shared-lib-imports
2100         * makeusg.adb: Add line for switch --unchecked-shared-lib-imports
2101         * makeutl.ads: (Unchecked_Shared_Lib_Imports): New constant string
2102         moved from GPR_Util.
2103         * switch-m.adb (Scan_Make_Switches): Recognize switch
2104         --unchecked-shared-lib-imports.
2105         * vms_data.ads: Add VMS qualifiers /UNCHECKED_SHARED_LIB_IMPORTS.
2106         * gnat_ugn.texi: Add documentation for new switch
2107         --unchecked-shared-lib-imports.  Add also documentation for --subdirs.
2108
2109 2010-06-22  Javier Miranda  <miranda@adacore.com>
2110
2111         * sem_prag.adb, sem_util.adb, sem_util.ads, sem_attr.adb, exp_ch6.adb,
2112         exp_disp.adb, sem_eval.adb, exp_dist.adb lib-xref.adb: Code cleanup,
2113         this patch replaces duplication of code that traverses the chain of
2114         aliased primitives by a call to routine Ultimate_Alias that
2115         provides this functionality.
2116
2117 2010-06-22  Arnaud Charlet  <charlet@adacore.com>
2118
2119         * fmap.adb, opt.ads, osint.adb, osint.ads, output.ads, scng.adb,
2120         sinput-c.adb, switch-m.ads, tree_io.ads: Use simpler form of
2121         Warnings Off/On.
2122
2123 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2124
2125         * einfo.ads: Minor reformatting.
2126
2127 2010-06-22  Javier Miranda  <miranda@adacore.com>
2128
2129         * exp_disp.adb (Expand_Interface_Thunk): Do not generate thunk of
2130         eliminated primitives.
2131         (Make_DT): Avoid referencing eliminated primitives.
2132         (Register_Primitive): Do not register eliminated primitives in the
2133         dispatch table. Required to add this functionality when the program is
2134         compiled without static dispatch tables (-gnatd.t)
2135
2136 2010-06-22  Emmanuel Briot  <briot@adacore.com>
2137
2138         * fmap.adb, scng.adb, switch-m.ads, sinput-c.adb, opt.ads, output.ads,
2139         tree_io.ads, osint.adb, osint.ads: Use configuration pragmas to prevent
2140         warnings on use of internal GNAT units.
2141
2142 2010-06-22  Jose Ruiz  <ruiz@adacore.com>
2143
2144         * s-taprop-vxworks.adb (Set_Priority): Update comments.
2145
2146 2010-06-22  Paul Hilfinger  <hilfinger@adacore.com>
2147
2148         * s-rannum.adb: Make stylistic change to remove mystery constant in
2149         Extract_Value.  Image_Numeral_Length: new symbolic constant.
2150
2151 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
2152
2153         * einfo.ads, einfo.adb: Make Is_Protected_Interface,
2154         Is_Synchronized_Interface, Is_Task_Interface into computable
2155         predicates, to free three flags in entity nodes.
2156         * sem_ch3.adb: Remove setting of these flags.
2157
2158 2010-06-22  Robert Dewar  <dewar@adacore.com>
2159
2160         * uintp.adb, osint.adb, prj-conf.adb, prj-part.adb, prj.adb: Minor
2161         reformatting.
2162         * s-taprop-vxworks.adb: Add comment for Set_Priority.
2163         * impunit.adb (Map_Array): Add entries for s-htable.ads and s-crc32.ads
2164         * projects.texi: Move @cindex to the left margin, since otherwise we
2165         are missing entries in the index.
2166
2167 2010-06-22  Emmanuel Briot  <briot@adacore.com>
2168
2169         * prj-part.adb, prj.adb, tempdir.ads, makeutl.adb: Use
2170         packages from the GNAT hierarchy instead of System when possible.
2171         * gcc-interface/Make-lang.in: Update dependencies.
2172
2173 2010-06-22  Jose Ruiz  <ruiz@adacore.com>
2174
2175         * s-taprop-vxworks.adb (Set_Priority): Remove the code that was
2176         previously in place to reorder the ready queue when a task drops its
2177         priority due to the loss of inherited priority.
2178
2179 2010-06-22  Vincent Celier  <celier@adacore.com>
2180
2181         * projects.texi: Minor spelling error fixes.
2182         Minor reformatting.
2183
2184 2010-06-22  Emmanuel Briot  <briot@adacore.com>
2185
2186         * prj-part.adb, prj-ext.adb, prj.adb, makeutl.adb, prj-conf.adb: Remove
2187         warnings for some with clauses.
2188
2189 2010-06-22  Robert Dewar  <dewar@adacore.com>
2190
2191         * errout.adb (Unwind_Internal_Type): Improve handling of First_Subtype
2192         test to catch more cases where first subtype is the results we want.
2193         * sem_res.adb (Make_Call_Into_Operator): Don't go to First_Subtype in
2194         error case, since Errout will now handle this correctly.
2195         * gcc-interface/Make-lang.in: Add Sem_Aux to list of GNATBIND objects.
2196         Update dependencies.
2197
2198 2010-06-22  Arnaud Charlet  <charlet@adacore.com>
2199
2200         * exp_ch4.adb (Expand_Allocator_Expression): Set Related_Node properly
2201         when calling Make_Temporary.
2202
2203 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
2204
2205         * sem_ch3.adb (Access_Subprogram_Declaration): An anonymous access to
2206         subprogram can be associated with an entry body.
2207
2208 2010-06-22  Robert Dewar  <dewar@adacore.com>
2209
2210         * scos.ads: Add note on membership test handling.
2211
2212 2010-06-22  Vincent Celier  <celier@adacore.com>
2213
2214         * projects.texi: Minor spelling fixes.
2215         Minor reformatting.
2216
2217 2010-06-22  Paul Hilfinger  <hilfinger@adacore.com>
2218
2219         * s-rannum.adb: Correct off-by-one error in Extract_Value.
2220
2221 2010-06-22  Vincent Celier  <celier@adacore.com>
2222
2223         * mlib-prj.adb (Display): In non verbose mode, truncate after fourth
2224         argument.
2225         * mlib-utl.adb (Gcc): In non verbose mode, truncate the display of the
2226         gcc command if it is too long.
2227
2228 2010-06-22  Robert Dewar  <dewar@adacore.com>
2229
2230         * errout.adb (Set_Msg_Node): Fix incorrect reference to node.
2231
2232 2010-06-22  Arnaud Charlet  <charlet@adacore.com>
2233
2234         * exp_ch6.adb (Expand_Actuals): Use Actual as the related node when
2235         calling Make_Temporary.
2236
2237 2010-06-22  Robert Dewar  <dewar@adacore.com>
2238
2239         * sem_res.adb, sem_aux.adb, errout.adb: Minor reformatting.
2240
2241 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
2242
2243         * sem_res.adb: Additional special-case for VMS.
2244
2245 2010-06-22  Vincent Celier  <celier@adacore.com>
2246
2247         * gnatsym.adb: Minor comment fix.
2248
2249 2010-06-22  Vincent Celier  <celier@adacore.com>
2250
2251         * prj-nmsc.adb (Process_Naming_Scheme): Initialize table Lib_Data_Table.
2252
2253 2010-06-22  Robert Dewar  <dewar@adacore.com>
2254
2255         * par-ch4.adb (P_Name): Recognize 'Mod attribute in Ada 95 mode
2256         * sem_attr.adb (Attribute_05): Add Name_Mod so that 'Mod recognized in
2257         Ada 95 mode as an implementation defined attribute.
2258
2259 2010-06-22  Vincent Celier  <celier@adacore.com>
2260
2261         * bindusg.adb (Display): Update line for -R
2262         * switch-b.adb (Scan_Binder_Switches): Allow generation of the binder
2263         generated files when -R is used.
2264
2265 2010-06-22  Vincent Celier  <celier@adacore.com>
2266
2267         * prj-nmsc.adb (Lib_Data_Table): New table.
2268         (Check_Library_Attributes): Check if the same library name is used in
2269         two different projects that do not extend each other.
2270
2271 2010-06-22  Robert Dewar  <dewar@adacore.com>
2272
2273         * lib-writ.ads, errout.adb, einfo.adb, einfo.ads: Minor reformatting.
2274
2275 2010-06-22  Vincent Celier  <celier@adacore.com>
2276
2277         * adaint.c (__gnat_locate_regular_file): If a directory in the path is
2278         empty, make it the current working directory.
2279
2280 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2281
2282         * sem_ch3.adb (Build_Derived_Record_Type): When deriving a tagged
2283         private type with discriminants, make sure the parent type is frozen.
2284
2285 2010-06-22  Eric Botcazou  <ebotcazou@adacore.com>
2286
2287         * exp_attr.adb (Expand_N_Attribute_Reference) <Attribute_Bit>: Deal
2288         with packed array references specially.
2289         * exp_ch4.adb (Expand_N_Indexed_Component): Do not convert a reference
2290         to a component of a bit packed array if it is the prefix of 'Bit.
2291         * exp_pakd.ads (Expand_Packed_Bit_Reference): Declare.
2292         * exp_pakd.adb (Expand_Packed_Bit_Reference): New procedure.  Expand a
2293         'Bit reference, where the prefix involves a packed array reference.
2294         (Get_Base_And_Bit_Offset): New helper, extracted from...
2295         (Expand_Packed_Address_Reference): ...here.  Call above procedure to
2296         get the outer object and offset expression.
2297
2298 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2299
2300         * exp_attr.adb, lib-writ.ads, bindgen.adb: Minor reformatting.
2301         * einfo.adb (Related_Expression, Set_Related_Expression): Add
2302         assertions.
2303
2304 2010-06-22  Javier Miranda  <miranda@adacore.com>
2305
2306         * sem_ch3.adb (Add_Internal_Interface_Entities): Minor code
2307         reorganization to properly check if the operation has been inherited as
2308         an abstract operation.
2309
2310 2010-06-22  Ed Falis  <falis@adacore.com>
2311
2312         * s-osinte-vxworks.ads: Complete previous change.
2313
2314 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2315
2316         * sem_res.adb: Add comment.
2317         * projects.texi, gnat_ugn.texi: Remove macro.
2318
2319 2010-06-22  Vincent Celier  <celier@adacore.com>
2320
2321         * prj-attr.adb: Remove project level attribute Main_Language.
2322
2323 2010-06-22  Robert Dewar  <dewar@adacore.com>
2324
2325         * switch-b.adb, osint-b.adb: Minor reformatting.
2326
2327 2010-06-22  Pascal Obry  <obry@adacore.com>
2328
2329         * g-socthi-mingw.adb (C_Sendmsg): Do not attempt to send data from a
2330         vector if previous send was not fully successful. If only part of
2331         the vector data was sent, we exit the loop.
2332
2333 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2334
2335         * sem_res.adb (Make_Call_Into_Operator): Use First_Subtype for better
2336         error reporting with generic types.
2337
2338 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2339
2340         * bindgen.adb, bindusg.adb, gnatbind.adb, gnat_ugn.texi, opt.ads,
2341         osint-b.adb, osint-b.ads, output.adb, output.ads, switch-b.adb,
2342         vms_data.ads: Add a new command line switch -A to gnatbind to output
2343         the list of all ALI files for the partition.
2344
2345 2010-06-22  Arnaud Charlet  <charlet@adacore.com>
2346
2347         * s-osinte-vxworks.ads: Fix casing.
2348         * s-vxwext-kernel.ads, s-vxwext-rtp.ads: Complete previous
2349         change: Interfaces.C does not provide a long_long type.
2350
2351 2010-06-22  Emmanuel Briot  <briot@adacore.com>
2352
2353         * gnat_ugn.texi, projects.texi: Preprocess projects.texi for VMS and
2354         native user's guide, since this document contains the two versions.
2355         * gcc-interface/Make-lang.in: Update doc dependencies.
2356
2357 2010-06-22  Robert Dewar  <dewar@adacore.com>
2358
2359         * sem_ch3.adb: Minor reformatting.  Minor code reorganization.
2360
2361 2010-06-22  Emmanuel Briot  <briot@adacore.com>
2362
2363         * gnat_ugn.texi, projects.texi: Remove toplevel menu, since we should
2364         not build this file on its own (only through gnat_ugn.texi).
2365         Remove macro definitions and insert simpler version in gnat_ugn.texi.
2366
2367 2010-06-22  Robert Dewar  <dewar@adacore.com>
2368
2369         * ali-util.ads: Minor comment update.
2370         * g-socthi-mingw.adb: Minor reformatting.
2371
2372 2010-06-22  Ed Falis  <falis@adacore.com>
2373
2374         * s-osinte-vxworks.ads: take sigset_t definition from System.VxWorks.Ext
2375         * s-vxwext.ads, s-vxwext-kernel.ads, s-vxwext-rtp.ads: Define sigset_t
2376         for specific versions of VxWorks.
2377
2378 2010-06-22  Emmanuel Briot  <briot@adacore.com>
2379
2380         * gnat_rm.texi, gnat_ugn.texi, projects.texi: Remove all project files
2381         related sections from user's guide and reference manual, since they
2382         have now been merged together into a separate document (projects.texi).
2383         This removes a lot of duplication where attributes where described
2384         in several places.
2385         The grammar for the project files is now in each of the sections
2386         (packages,expressions,...) instead of being duplicates in two other
2387         sections (one in the user's guide that contained the full grammar,
2388         and various sections in the rm that contained extracts of the same
2389         grammar).
2390         Added the full list of all supported attributes, since existing lists
2391         were incomplete
2392         Rename "associative array" into "indexed attribute"
2393         Remove sections that were duplicates ("External References in
2394         Project Files" and "External Values", and "Project Extensions"
2395         for instance). The list of valid packages in project files is now in
2396         a single place.
2397
2398 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
2399
2400         * sem_ch3.adb (Add_Internal_Interface_Entities): If
2401         Find_Primitive_Covering_Interface does not find the operation, it may
2402         be because of a name conflict between the inherited operation and a
2403         local non-overloadable name. In that case look for the operation among
2404         the primitive operations of the type. This search must succeed
2405         regardless of visibility.
2406
2407 2010-06-22  Pascal Obry  <obry@adacore.com>
2408
2409         * g-socthi-mingw.adb: Properly honor MSG_WAITALL in recvmsg.
2410         (C_Recvmsg): Propely honor the MSG_WAITALL flag in Windows
2411         recvmsg emulation.
2412
2413 2010-06-22  Robert Dewar  <dewar@adacore.com>
2414
2415         * sem_ch4.adb (Analyze_Conditional_Expression): Defend against
2416         malformed tree.
2417         * sprint.adb (Sprint_Node_Actual, case N_Conditional_Expression): Ditto.
2418
2419 2010-06-22  Arnaud Charlet  <charlet@adacore.com>
2420
2421         * s-intman-vxworks.ads: Code clean up.
2422
2423 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2424
2425         * sem_res.adb (Resolve_Slice): When the prefix is an explicit
2426         dereference, construct actual subtype of designated object to generate
2427         proper bounds checks.
2428
2429 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2430
2431         * ali-util.adb, ali-util.ads, gnatbind.adb (Read_ALI): Rename to
2432         Read_Withed_ALIs, which is more descriptive.
2433
2434 2010-06-22  Pascal Obry  <obry@adacore.com>
2435
2436         * g-sothco.ads: Minor reformatting.
2437         * g-socthi-mingw.adb: Remove part of work on the C_Recvmsg and
2438         C_Sendmsg implementation.
2439         (C_Sendmsg): Do not use lock (not needed).
2440         (C_Recvmsg): Likewise and also do not wait for incoming data.
2441
2442 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
2443
2444         * uintp.adb: Fix scope error in operator call.
2445
2446 2010-06-22  Vincent Celier  <celier@adacore.com>
2447
2448         * makeutl.adb (Executable_Prefix_Path): on VMS, return "/gnu/".
2449         * prj-conf.adb (Get_Or_Create_Configuration_File): On VMS, if
2450         autoconfiguration is needed, fail indicating that no config project
2451         file can be found, as there is no autoconfiguration on VMS.
2452
2453 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
2454
2455         * sem_res.adb (Make_Call_Into_Operator): Diagnose an incorrect scope
2456         for an operator in a functional notation, when operands are universal.
2457
2458 2010-06-22  Arnaud Charlet  <charlet@adacore.com>
2459
2460         * gcc-interface/Make-lang.in: Update dependencies.
2461
2462 2010-06-22  Robert Dewar  <dewar@adacore.com>
2463
2464         * sem_aggr.adb (Resolve_Record_Aggregate): Do style check on component
2465         name.
2466         * sem_ch10.adb (Analyze_Subunit): Do style check on parent unit name.
2467         * sem_ch8.adb (Find_Direct_Name): For non-overloadable entities, do
2468         style check.
2469         * sem_res.adb (Resolve_Entity_Name): Do style check for enumeration
2470         literals.
2471
2472 2010-06-22  Vincent Celier  <celier@adacore.com>
2473
2474         * make.adb (Scan_Make_Arg): No longer pass -nostdlib to the compiler as
2475         it has no effect. Always pass -nostdlib to gnatlink, even on VMS.
2476
2477 2010-06-22  Pascal Obry  <obry@adacore.com>
2478
2479         * g-socthi-mingw.adb: Fix implementation of the vectored sockets on
2480         Windows.
2481         (C_Recvmsg): Make sure the routine is atomic. Also fully
2482         fill vectors in the proper order.
2483         (C_Sendmsg): Make sure the routine is atomic.
2484
2485 2010-06-22  Robert Dewar  <dewar@adacore.com>
2486
2487         * sem_ch8.adb: Update comment.
2488         * sem_res.adb: Minor code reorganization (use Ekind_In).
2489
2490 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
2491
2492         * sem_ch8.adb (Add_Implicit_Operator): If the context of the expanded
2493         name is a call, use the number of actuals to determine whether this is
2494         a binary or unary operator, rather than relying on later information
2495         to resolve the overload.
2496
2497 2010-06-22  Robert Dewar  <dewar@adacore.com>
2498
2499         * sem_ch10.adb, sem_aggr.adb: Minor reformatting.
2500
2501 2010-06-22  Robert Dewar  <dewar@adacore.com>
2502
2503         * sem_ch3.adb, sem_disp.adb: Minor code fixes.
2504         * sem_eval.adb: Minor reformatting.
2505
2506 2010-06-22  Vincent Celier  <celier@adacore.com>
2507
2508         * make.adb (Scan_Make_Arg): When invoked with -nostdlib, pass -nostdlib
2509         to gnatlink, except on Open VMS.
2510         * osint.adb (Add_Default_Search_Dirs): Do not suppress the default
2511         object directories if -nostdlib is used.
2512
2513 2010-06-22  Robert Dewar  <dewar@adacore.com>
2514
2515         * sem_util.adb (Is_Delegate): Put in proper alpha order.
2516         * sem_eval.adb: Minor reformatting.
2517
2518 2010-06-22  Robert Dewar  <dewar@adacore.com>
2519
2520         * g-expect-vms.adb, sem_res.adb: Minor reformatting.
2521         * exp_aggr.adb: Minor comment changes and reformatting.
2522         * sem_eval.adb (Find_Universal_Operator_Type): Put in proper alpha order
2523         * sem_util.ads: Add some missing pragma Inline's (efficiency issue only)
2524
2525 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2526
2527         * sem_util.adb (Build_Actual_Subtype): Record original expression in
2528         Related_Expression attribute of the constructed subtype.
2529         * einfo.adb, einfo.ads (Underlying_View): Move to Node28 to free up
2530         Node24 on types for...
2531         (Related_Expression): Make attribute available on types as well.
2532
2533 2010-06-22  Gary Dismukes  <dismukes@adacore.com>
2534
2535         * exp_util.adb (Find_Interface_ADT): Retrieve Designated_Type instead of
2536         Directly_Designated_Type when the type argument is an access type.
2537         (Find_Interface_Tag): Retrieve Designated_Type instead of
2538         Directly_Designated_Type when the type argument is an access type.
2539         (Has_Controlled_Coextensions): Retrieve Designated_Type instead of
2540         Directly_Designated_Type of each access discriminant.
2541         * sem_res.adb (Resolve_Type_Conversion): Retrieve Designated_Type
2542         instead of Directly_Designated_Type when the operand and target types
2543         are access types.
2544
2545 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2546
2547         * exp_aggr.adb (Flatten): Return False if one choice is statically
2548         known to be out of bounds.
2549
2550 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
2551
2552         * sem_res.adb (Resolve_Call): If the call is rewritten as an indexed of
2553         a parameterless function call, preserve parentheses of original
2554         expression, for proper handling by pretty printer.
2555         * sem_attr.adb (Analyze_Attribute, case 'Old): Add guard to Process
2556         procedure, to handle quietly identifiers that have no entity names.
2557         * exp_util.adb (Get_Current_Value_Condition): If the parent of an
2558         elsif_part is missing, it has been rewritten as a nested if, and there
2559         is no useful information on the current value of the variable.
2560
2561 2010-06-22  Gary Dismukes  <dismukes@adacore.com>
2562
2563         * sem_ch3.adb (Build_Discriminal): Set default scopes for newly created
2564         discriminals to the current scope.
2565         * sem_util.adb (Find_Body_Discriminal): Remove setting of discriminal's
2566         scope, which could overwrite a different already set value.
2567
2568 2010-06-22  Ed Schonberg  <schonberg@adacore.com>
2569
2570         * sem_res.adb (Valid_Conversion): If expression is a predefined
2571         operator, use sloc of type of interpretation to improve error message
2572         when operand is of some derived type.
2573         * sem_eval.adb (Is_Mixed_Mode_Operand): New function, use it.
2574
2575 2010-06-22  Emmanuel Briot  <briot@adacore.com>
2576
2577         * g-expect-vms.adb (Expect_Internal): No longer raises an exception, so
2578         that it can set out parameters as well. When a process has died, reset
2579         its Input_Fd to Invalid_Fd, so that when using multiple processes we
2580         can find out which process has died.
2581
2582 2010-06-22  Thomas Quinot  <quinot@adacore.com>
2583
2584         * sem_eval.adb (Find_Universal_Operator_Type): New
2585         subprogram to identify the operand type of an operator on universal
2586         operands, when an explicit scope indication is present. Diagnose the
2587         case where such a call is ambiguous.
2588         (Eval_Arithmetic_Op, Eval_Relational_Op, Eval_Unary_Op):
2589         Use the above to identify the operand type so it can be properly frozen.
2590         * sem_res.adb (Make_Call_Into_Operator): Remove bogus freeze of operand
2591         type, done in an arbitrary, possibly incorrect type (the presence of
2592         some numeric type in the scope is checked for legality, but when more
2593         than one such type is in the scope, we just pick a random one, not
2594         necessarily the expected one).
2595         * sem_utils.ads, sem_utils.adb (Is_Universal_Numeric_Type): New utility
2596         subprogram.
2597
2598 2010-06-22  Robert Dewar  <dewar@adacore.com>
2599
2600         * sem_eval.adb: Minor reformatting.
2601
2602 2010-06-22  Robert Dewar  <dewar@adacore.com>
2603
2604         * exp_ch4.adb (Expand_N_Conditional_Expression): Use
2605         Expression_With_Actions to clean up the code generated when folding
2606         constant expressions.
2607
2608 2010-06-22  Vincent Celier  <celier@adacore.com>
2609
2610         * g-expect-vms.adb: Add new subprograms Free, First_Dead_Process and
2611         Has_Process.
2612
2613 2010-06-22  Vincent Celier  <celier@adacore.com>
2614
2615         * prj-nmsc.adb (Find_Sources): When a source from a multi-unit file is
2616         found, check if it's path has aready been found, whatever its index.
2617
2618 2010-06-22  Robert Dewar  <dewar@adacore.com>
2619
2620         * atree.adb, gnatbind.adb: Minor reformatting.
2621         Minor code reorganization.
2622
2623 2010-06-21  Robert Dewar  <dewar@adacore.com>
2624
2625         * exp_ch4.adb (Expand_N_Conditional_Expression): Fold if condition
2626         known at compile time.
2627
2628 2010-06-21  Gary Dismukes  <dismukes@adacore.com>
2629
2630         * atree.adb: Fix comment typo.
2631
2632 2010-06-21  Ed Schonberg  <schonberg@adacore.com>
2633
2634         * sem_eval.adb (Test_Ambiguous_Operator): New procedure to check
2635         whether a universal arithmetic expression in a conversion, which is
2636         rewritten from a function call with an expanded name, is ambiguous.
2637
2638 2010-06-21  Vincent Celier  <celier@adacore.com>
2639
2640         * prj-nmsc.adb (Name_Location): New Boolean component Listed, to record
2641         source files in specified list of sources.
2642         (Check_Package_Naming): Remove out parameters Bodies and Specs, as they
2643         are never used.
2644         (Add_Source): Set the Location of the new source
2645         (Process_Exceptions_File_Based): Call Add_Source with the Location
2646         (Get_Sources_From_File): If an exception is found, set its Listed to
2647         True
2648         (Find_Sources): When Source_Files is specified, if an exception is
2649         found, set its Listed to True. Remove any exception that is not in a
2650         specified list of sources.
2651         * prj.ads (Source_Data): New component Location
2652
2653 2010-06-21  Vincent Celier  <celier@adacore.com>
2654
2655         * gnatbind.adb (Closure_Sources): Global table, moved from block.
2656
2657 2010-06-21  Thomas Quinot  <quinot@adacore.com>
2658
2659         * sem_res.adb: Minor reformatting.
2660         * atree.adb: New debugging hook "rr" for node rewrites.
2661
2662 2010-06-21  Robert Dewar  <dewar@adacore.com>
2663
2664         * g-expect.ads, g-expect.adb: Minor reformatting.
2665
2666 2010-06-21  Emmanuel Briot  <briot@adacore.com>
2667
2668         * s-regpat.adb (Next_Pointer_Bytes): New named constant. Code clean up.
2669
2670 2010-06-21  Arnaud Charlet  <charlet@adacore.com>
2671
2672         * gcc-interface/Make-lang.in: Update dependencies.
2673
2674 2010-06-21  Thomas Quinot  <quinot@adacore.com>
2675
2676         * bindgen.ads: Update comments.
2677
2678 2010-06-21  Vincent Celier  <celier@adacore.com>
2679
2680         * gnatbind.adb: Suppress dupicates when listing the sources in the
2681         closure (switch -R).
2682
2683 2010-06-21  Emmanuel Briot  <briot@adacore.com>
2684
2685         * s-regpat.adb (Link_Tail): Fix error when size of the pattern matcher
2686         is too small.
2687
2688 2010-06-21  Emmanuel Briot  <briot@adacore.com>
2689
2690         * g-expect.adb, g-expect.ads (First_Dead_Process, Free, Has_Process):
2691         New subprograms.
2692         (Expect_Internal): No longer raises an exception, so that it can set
2693         out parameters as well. When a process has died, reset its Input_Fd
2694         to Invalid_Fd, so that when using multiple processes we can find out
2695         which process has died.
2696
2697 2010-06-21  Robert Dewar  <dewar@adacore.com>
2698
2699         * s-regpat.adb, s-tpoben.adb, sem_attr.adb, sem_util.adb, sem_util.ads,
2700         checks.adb, sem_res.adb: Minor reformatting. Add comments.
2701
2702 2010-06-21  Ed Schonberg  <schonberg@adacore.com>
2703
2704         * sem_ch6.adb (New_Overloaded_Entity): If the new entity is a
2705         rederivation associated with a full declaration in a private part, and
2706         there is a partial view that derives the same parent subprogram, the
2707         new entity does not become visible. This check must be applied to
2708         interface operations as well.
2709
2710 2010-06-21  Thomas Quinot  <quinot@adacore.com>
2711
2712         * checks.adb: Add comments.
2713         * prj-nmsc.adb: Minor reformatting.
2714
2715 2010-06-21  Thomas Quinot  <quinot@adacore.com>
2716
2717         * sem_ch9.adb, checks.adb, sem_util.adb, sem_util.ads, sem_res.adb,
2718         sem_attr.adb (Get_E_First_Or_Last): Use attribute references on E to
2719         extract bounds, to ensure that we get the proper captured values,
2720         rather than an expression that may have changed value since the point
2721         where the subtype was elaborated.
2722         (Find_Body_Discriminal): New utility subprogram to share code between...
2723         (Eval_Attribute): For the case of a subtype bound that references a
2724         discriminant of the current concurrent type, insert appropriate
2725         discriminal reference.
2726         (Resolve_Entry.Actual_Index_Type.Actual_Discriminant_Ref): For a
2727         requeue to an entry in a family in the current task, use corresponding
2728         body discriminal. 
2729         (Analyze_Accept_Statement): Rely on expansion of attribute references
2730         to insert proper discriminal references in range check for entry in
2731         family.
2732
2733 2010-06-21  Emmanuel Briot  <briot@adacore.com>
2734
2735         * s-regpat.adb (Compile): Fix handling of big patterns.
2736
2737 2010-06-21  Robert Dewar  <dewar@adacore.com>
2738
2739         * a-tifiio.adb: Minor reformatting.
2740
2741 2010-06-21  Pascal Obry  <obry@adacore.com>
2742
2743         * prj-nmsc.adb (Search_Directories): Use the non-translated directory
2744         path to open it.
2745
2746 2010-06-21  Javier Miranda  <miranda@adacore.com>
2747
2748         * exp_cg.adb (Write_Call_Info): Fill the component sourcename using the
2749         external name.
2750
2751 2010-06-21  Ed Schonberg  <schonberg@adacore.com>
2752
2753         * exp_ch4.adb (Expand_Concatenate): If an object declaration is created
2754         to hold the result, indicate that the target of the declaration does
2755         not need an initialization, to prevent spurious errors when
2756         Initialize_Scalars is enabled.
2757
2758 2010-06-21  Ed Schonberg  <schonberg@adacore.com>
2759
2760         * a-tifiio.adb (Put): In the procedure that performs I/O on a String,
2761         Fore is not bound by line length. The Fore parameter of the internal
2762         procedure that performs the operation is an integer.
2763
2764 2010-06-21  Thomas Quinot  <quinot@adacore.com>
2765
2766         * sem_res.adb, checks.adb: Minor reformatting.
2767
2768 2010-06-21  Emmanuel Briot  <briot@adacore.com>
2769
2770         * s-regpat.adb (Next_Instruction, Get_Next_Offset): Removed, merged
2771         into Get_Next.
2772         (Insert_Operator_Before): New subprogram, avoids duplicated code
2773         (Compile): Avoid doing two compilations when the pattern matcher ends
2774         up being small.
2775
2776 2010-06-21  Emmanuel Briot  <briot@adacore.com>
2777
2778         * s-regpat.adb: Improve debug traces
2779         (Dump): Change output format to keep it smaller.
2780
2781 2010-06-21  Javier Miranda  <miranda@adacore.com>
2782
2783         * exp_cg.adb (Generate_CG_Output): Disable redirection of standard
2784         output to the output file when this routine completes its work.
2785
2786 2010-06-20  Eric Botcazou  <ebotcazou@adacore.com>
2787
2788         * gcc-interface/trans.c (Subprogram_Body_to_gnu): Use while instead of
2789         for loop.  Call build_constructor_from_list directly in the CICO case.
2790
2791 2010-06-18  Ed Schonberg  <schonberg@adacore.com>
2792
2793         * freeze.adb (Build_And_Analyze_Renamed_Body): If the renaming
2794         declaration appears in the same unit and ealier than the renamed
2795         entity, retain generated body to prevent order-of-elaboration issues in
2796         gigi.
2797
2798 2010-06-18  Arnaud Charlet  <charlet@adacore.com>
2799
2800         * s-tpoben.adb: Update comments.
2801
2802 2010-06-18  Robert Dewar  <dewar@adacore.com>
2803
2804         * debug.adb: Minor comment change.
2805
2806 2010-06-18  Javier Miranda  <miranda@adacore.com>
2807
2808         * exp_cg.adb: Code clean up.
2809         * debug.adb: Complete documentation of switch -gnatd.Z.
2810         * gcc-interface/misc.c (callgraph_info_file): Declare.
2811
2812 2010-06-18  Javier Miranda  <miranda@adacore.com>
2813
2814         * exp_cg.adb (Homonym_Suffix_Length): Minor code reorganization.
2815
2816 2010-06-18  Thomas Quinot  <quinot@adacore.com>
2817
2818         * sprint.ads: Minor reformatting.
2819         * output.ads: Update obsolete comment.
2820
2821 2010-06-18  Ed Schonberg  <schonberg@adacore.com>
2822
2823         * freeze.adb (Build_And_Analyze_Renamed_Body): if the renamed entity is
2824         an external intrinsic operation (e.g. a GCC numeric function) indicate
2825         that the renaming entity has the same characteristics, so a call to it
2826         is properly expanded.
2827
2828 2010-06-18  Javier Miranda  <miranda@adacore.com>
2829
2830         * exp_cg.adb, exp_cg.ads, exp_disp.adb, gnat1drv.adb: Add initial
2831         support for dispatch table/callgraph info generation.
2832         * gcc-interface/Make-lang.in: Update dependencies.
2833
2834 2010-06-18  Robert Dewar  <dewar@adacore.com>
2835
2836         * exp_ch6.adb: Minor reformatting.
2837         * gnatname.adb: Add comment.
2838
2839 2010-06-18  Vincent Celier  <celier@adacore.com>
2840
2841         * gnatname.adb (Scan_Args): When --and is used, make sure that the
2842         dynamic tables in the newly allocated Argument_Data are properly
2843         initialized.
2844
2845 2010-06-18  Eric Botcazou  <ebotcazou@adacore.com>
2846
2847         * gnat1drv.adb: Fix comment.
2848
2849 2010-06-18  Ed Schonberg  <schonberg@adacore.com>
2850
2851         * exp_ch6.adb (Expand_Inlined_Call): If the inlined subprogram is a
2852         renaming, re-expand the call with the renamed subprogram if that one
2853         is marked inlined as well.
2854
2855 2010-06-18  Gary Dismukes  <dismukes@adacore.com>
2856
2857         * gnat1drv.adb (Adjust_Global_Switches): Enable
2858         Use_Expression_With_Actions for AAMP and VM targets.
2859
2860 2010-06-18  Vincent Celier  <celier@adacore.com>
2861
2862         * prj-nmsc.adb (Process_Linker): Recognize response file format GCC.
2863
2864 2010-06-18  Thomas Quinot  <quinot@adacore.com>
2865
2866         * exp_ch4.adb: Minor reformatting.
2867
2868 2010-06-18  Javier Miranda  <miranda@adacore.com>
2869
2870         * debug.ads Add documentation on -gnatd.Z.
2871
2872 2010-06-18  Ed Schonberg  <schonberg@adacore.com>
2873
2874         * sem_elim.adb: Proper error message on improperly eliminated instances
2875
2876 2010-06-18  Vincent Celier  <celier@adacore.com>
2877
2878         * prj.ads (Response_File_Format): New value GCC.
2879
2880 2010-06-18  Thomas Quinot  <quinot@adacore.com>
2881
2882         * gnat1drv.adb: Minor reformatting.
2883
2884 2010-06-18  Robert Dewar  <dewar@adacore.com>
2885
2886         * make.adb, sem_cat.adb: Minor reformatting.
2887         * sem_eval.adb: Fix typos.
2888
2889 2010-06-18  Pascal Obry  <obry@adacore.com>
2890
2891         * prj-nmsc.adb: Fix source filenames casing in debug output.
2892
2893 2010-06-18  Robert Dewar  <dewar@adacore.com>
2894
2895         * gnatcmd.adb: Minor reformatting.
2896
2897 2010-06-18  Robert Dewar  <dewar@adacore.com>
2898
2899         * sem_eval.adb (Eval_Conditional_Expression): Result is static if
2900         condition and both sub-expressions are static (and result is selected
2901         expression).
2902
2903 2010-06-18  Robert Dewar  <dewar@adacore.com>
2904
2905         * g-pehage.adb: Minor reformatting
2906
2907 2010-06-18  Pascal Obry  <obry@adacore.com>
2908
2909         * prj-nmsc.adb (Search_Directories): Insert canonical filenames into
2910         source hash table.
2911
2912 2010-06-18  Arnaud Charlet  <charlet@adacore.com>
2913
2914         * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
2915         dependencies. Fix target pairs on darwin.
2916         (gnatlib-sjlj, gnatlib-zcx): Pass THREAD_KIND.
2917
2918 2010-06-18  Pascal Obry  <obry@adacore.com>
2919
2920         * make.adb, prj-nmsc.adb: Fix source filenames casing in debug output.
2921
2922 2010-06-18  Vincent Celier  <celier@adacore.com>
2923
2924         * gnatcmd.adb: For gnatcheck, add -gnatec= switch for a global
2925         configuration pragmas file and, if -U is not used, for a local one.
2926
2927 2010-06-18  Ed Schonberg  <schonberg@adacore.com>
2928
2929         * sem_elim.adb (Check_Eliminated): Use full information on entity name
2930         when it is given in the pragma by a selected component.
2931         (Check_For_Eliminated_Subprogram): Do no emit error if within a
2932         instance body that is itself within a generic unit.
2933         * sem_ch12.adb (Analyze_Subprogram_Instance): If the subprogram is
2934         eliminated, mark as well the anonymous subprogram that is its alias
2935         and appears within the wrapper package.
2936
2937 2010-06-18  Bob Duff  <duff@adacore.com>
2938
2939         * g-pehage.ads, g-pehage.adb (Produce): Clean up some of the code.
2940         Raise an exception if the output file cannot be opened. Add comments.
2941
2942 2010-06-18  Thomas Quinot  <quinot@adacore.com>
2943
2944         * sem_cat.adb (Validate_Object_Declaration): A variable declaration is
2945         not illegal per E.2.2(7) if it occurs in the private part of a
2946         Remote_Types unit.
2947
2948 2010-06-18  Arnaud Charlet  <charlet@adacore.com>
2949
2950         * par-ch9.adb, sem_aggr.adb, sem_ch3.adb, layout.adb, sem_ch4.adb,
2951         sem_ch5.adb, sem_mech.adb, exp_util.adb, par-ch10.adb, sem_ch6.adb,
2952         par-ch11.adb, sem_ch7.adb, par-prag.adb, exp_disp.adb, par-ch12.adb,
2953         sem_ch8.adb, style.adb, sem_ch9.adb, sem_ch10.adb, prep.adb,
2954         sem_warn.adb, par-util.adb, scng.adb, sem_eval.adb, checks.adb,
2955         sem_prag.adb, sem_ch12.adb, styleg.adb, sem_ch13.adb, par-ch3.adb,
2956         par-tchk.adb, freeze.adb, sfn_scan.adb, par-ch4.adb, sem_util.adb,
2957         sem_res.adb, par-ch5.adb, lib-xref.adb, sem_attr.adb, par-ch6.adb,
2958         sem_disp.adb, prepcomp.adb, par-ch7.adb, sem_elab.adb, exp_ch4.adb,
2959         errout.ads: Update comments. Minor reformatting.
2960
2961         * g-spipat.adb, a-swunau.adb, a-swunau.ads, g-spitbo.adb,
2962         a-szunau.adb, a-szunau.ads, a-stunau.adb, a-stunau.ads,
2963         a-strunb.adb (Big_String. Big_String_Access): New type.
2964
2965         * par-labl.adb, restrict.adb, s-osinte-hpux-dce.ads, sem_ch11.adb,
2966         exp_pakd.adb, s-filofl.ads, par-endh.adb, exp_intr.adb, sem_cat.adb,
2967         sem_case.adb, exp_ch11.adb, s-osinte-linux.ads: Fix copyright notices.
2968
2969 2010-06-18  Geert Bosch  <bosch@adacore.com>
2970
2971         * i-forbla-darwin.adb: Include -lgnala and -lm in linker options for
2972         Darwin.
2973
2974 2010-06-18  Robert Dewar  <dewar@adacore.com>
2975
2976         * gnat1drv.adb (Adjust_Global_Switches): Set Use_Expression_With_Actions
2977         true for gcc.
2978
2979 2010-06-18  Robert Dewar  <dewar@adacore.com>
2980
2981         * sprint.adb: Minor format change for N_Expression_With_Actions.
2982         * repinfo.adb: Minor reformatting.
2983
2984 2010-06-18  Ed Schonberg  <schonberg@adacore.com>
2985
2986         * sem_elim.adb (Check_Eliminated): If within a subunit, use
2987         Defining_Entity to obtain the name of the entity in the proper body, to
2988         properly handle both separate packages and subprograms.
2989
2990 2010-06-18  Emmanuel Briot  <briot@adacore.com>
2991
2992         * prj-nmsc.adb (Check_File): New parameter Display_Path.
2993
2994 2010-06-18  Thomas Quinot  <quinot@adacore.com>
2995
2996         * g-socket.adb, g-socket.ads (Null_Selector): New object.
2997
2998 2010-06-18  Pascal Obry  <obry@adacore.com>
2999
3000         * gnat_ugn.texi: Minor clarification.
3001
3002 2010-06-18  Emmanuel Briot  <briot@adacore.com>
3003
3004         * prj-nmsc.adb (Find_Source_Dirs): Minor refactoring to avoid duplicate
3005         code when using the project dir as the source dir.
3006         (Search_Directories): use the normalized name for the source directory,
3007         where symbolic names have potentially been resolved.
3008
3009 2010-06-18  Robert Dewar  <dewar@adacore.com>
3010
3011         * exp_ch4.adb (Expand_N_Conditional_Expression): Clear Actions field
3012         when we create N_Expression_With_Actions node.
3013         (Expand_Short_Circuit): Ditto.
3014
3015 2010-06-18  Robert Dewar  <dewar@adacore.com>
3016
3017         * exp_util.adb: Minor reformatting.
3018
3019 2010-06-18  Thomas Quinot  <quinot@adacore.com>
3020
3021         * types.ads: Clean up obsolete comments
3022         * tbuild.adb: Minor reformatting.
3023         * exp_ch5.adb, sem_intr.adb, sem_ch10.adb, rtsfind.adb, s-shasto.adb,
3024         exp_strm.adb, aa_drive.adb: Minor reformatting.
3025         * sem_res.adb (Is_Predefined_Operator): An operator that is an imported
3026         intrinsic with an Interface_Name denotes an imported back-end builtin,
3027         and must be rewritten into a call, not left in the tree as an operator,
3028         so return False in that case.
3029
3030 2010-06-18  Eric Botcazou  <ebotcazou@adacore.com>
3031
3032         * exp_util.adb (Remove_Side_Effects): Make a copy for an allocator.
3033         
3034 2010-06-18  Robert Dewar  <dewar@adacore.com>
3035
3036         * scos.ads: Add proposed output for case expression
3037
3038 2010-06-18  Jose Ruiz  <ruiz@adacore.com>
3039
3040         * gnat_ugn.texi: Document that, when using the RTX compiler to generate
3041         RTSS modules, we need to use the Microsoft linker.
3042
3043 2010-06-18  Robert Dewar  <dewar@adacore.com>
3044
3045         * checks.adb (Safe_To_Capture_In_Parameter_Value): Deal with case
3046         expression (cannot count on a particular branch being executed).
3047         * exp_ch4.adb (Expand_N_Case_Expression): New procedure.
3048         * exp_ch4.ads (Expand_N_Case_Expression): New procedure.
3049         * exp_util.adb (Insert_Actions): Deal with proper insertion of actions
3050         within case expression.
3051         * expander.adb (Expand): Add call to Expand_N_Case_Expression
3052         * par-ch4.adb Add calls to P_Case_Expression at appropriate points
3053         (P_Case_Expression): New procedure
3054         (P_Case_Expression_Alternative): New procedure
3055         * par.adb (P_Case_Expression): New procedure
3056         * par_sco.adb (Process_Decisions): Add dummy place holder entry for
3057         N_Case_Expression.
3058         * sem.adb (Analyze): Add call to Analyze_Case_Expression
3059         * sem_case.ads (Analyze_Choices): Also used for case expressions now,
3060         this is a documentation change only.
3061         * sem_ch4.ads, sem_ch4.adb (Analyze_Case_Expression): New procedure.
3062         * sem_ch6.adb (Fully_Conformant_Expressions): Add handling of case
3063         expressions.
3064         * sem_eval.ads, sem_eval.adb (Eval_Case_Expression): New procedure.
3065         * sem_res.adb (Resolve_Case_Expression): New procedure.
3066         * sem_scil.adb (Find_SCIL_Node): Add processing for
3067         N_Case_Expression_Alternative.
3068         * sinfo.ads, sinfo.adb (N_Case_Expression): New node.
3069         (N_Case_Expression_Alternative): New node.
3070         * sprint.adb (Sprint_Node_Actual): Add processing for new nodes
3071         N_Case_Expression and N_Case_Expression_Alternative.
3072
3073 2010-06-18  Robert Dewar  <dewar@adacore.com>
3074
3075         * par-ch7.adb, sem_warn.adb, types.ads, par-ch3.adb: Minor reformatting.
3076         * gnat1drv.adb: Fix typo.
3077
3078 2010-06-18  Robert Dewar  <dewar@adacore.com>
3079
3080         * par-prag.adb (Prag, case Style_Checks): All_Checks sets gnat style
3081         for -gnatg.
3082         * sem_prag.adb (Analyze_Pragma, case Style_Checks): All_Checks sets
3083         gnat style for -gnatg.
3084         * gnat_rm.texi: Add documentation for ALL_CHECKS in GNAT mode.
3085
3086 2010-06-18  Thomas Quinot  <quinot@adacore.com>
3087
3088         * sem_eval.adb (Test_In_Range): New subprogram, factoring duplicated
3089         code between...
3090         (Is_In_Range, Is_Out_Of_Range): Reimplement in terms of call to
3091         Test_In_Range.
3092
3093 2010-06-18  Robert Dewar  <dewar@adacore.com>
3094
3095         * sprint.adb: Minor change in output format for expression wi actions.
3096         * par-ch3.adb: Minor code reorganization.  Minor reformatting.
3097         * sem_ch5.adb: Minor comment fix.
3098
3099 2010-06-18  Robert Dewar  <dewar@adacore.com>
3100
3101         * debug.adb: New debug flag -gnatd.L to control
3102         Back_End_Handles_Limited_Types.
3103         * exp_ch4.adb (Expand_N_Conditional_Expression): Let back end handle
3104         limited case if Back_End_Handles_Limited_Types is True.
3105         (Expand_N_Conditional_Expression): Use N_Expression_With_Actions to
3106         simplify expansion if Use_Expression_With_Actions is True.
3107         * gnat1drv.adb (Adjust_Global_Switches): Set
3108         Back_End_Handles_Limited_Types.
3109         * opt.ads (Back_End_Handles_Limited_Types): New flag.
3110
3111 2010-06-18  Ed Schonberg  <schonberg@adacore.com>
3112
3113         * sem_res.adb (Rewrite_Operator_As_Call): Do not rewrite user-defined
3114         intrinsic operator if expansion is not enabled, because in an
3115         instantiation the original operator must be present to verify the
3116         legality of the operation.
3117
3118 2010-06-18  Robert Dewar  <dewar@adacore.com>
3119
3120         * exp_disp.adb, sem_ch12.adb: Minor reformatting
3121
3122 2010-06-18  Ed Schonberg  <schonberg@adacore.com>
3123
3124         * exp_util.adb (Make_Subtype_From_Expr): If the unconstrained type is
3125         the class-wide type for a private extension, and the completion is a
3126         subtype, set the type of the class-wide type to the base type of the
3127         full view.
3128
3129 2010-06-18  Robert Dewar  <dewar@adacore.com>
3130
3131         * g-socket.ads, sem_aggr.adb, einfo.ads, sem_elim.adb,
3132         sem_intr.adb, sem_eval.adb: Minor reformatting
3133
3134 2010-06-18  Ed Schonberg  <schonberg@adacore.com>
3135
3136         * sem_type.adb (Is_Ancestor): If either type is private, examine full
3137         view.
3138
3139 2010-06-18  Thomas Quinot  <quinot@adacore.com>
3140
3141         * g-socket.adb, g-socket.ads (Check_Selector): Make Selector an IN
3142         parameter rather than IN OUT.
3143
3144 2010-06-18  Ed Schonberg  <schonberg@adacore.com>
3145
3146         * exp_ch6.adb: Add extra guard.
3147
3148 2010-06-18  Gary Dismukes  <dismukes@adacore.com>
3149
3150         * sem_util.adb (Object_Access_Level): For Ada 2005, determine the
3151         accessibility level of a function call from the level of the innermost
3152         enclosing dynamic scope.
3153         (Innermost_Master_Scope_Depth): New function to find the depth of the
3154         nearest dynamic scope enclosing a node.
3155
3156 2010-06-18  Tristan Gingold  <gingold@adacore.com>
3157
3158         * adaint.c: Make ATTR_UNSET static as it is not used outside this file.
3159
3160 2010-06-18  Thomas Quinot  <quinot@adacore.com>
3161
3162         * g-socket.ads: Minor reformatting.
3163
3164 2010-06-18  Vincent Celier  <celier@adacore.com>
3165
3166         * make.adb (Must_Compile): New Boolean global variable
3167         (Main_On_Command_Line): New Boolean global variable
3168         (Collect_Arguments_And_Compile): Do compile if Must_Compile is True,
3169         even when the project is externally built.
3170         (Start_Compile_If_Possible): Compile in -aL directories if
3171         Check_Readonly_Files is True. Do compile if Must_Compile is True, even
3172         when the project is externally built.
3173         (Gnatmake): Set Must_Compile and Check_Readonly_Files to True when
3174         invoked with -f -u and one or several mains on the command line.
3175         (Scan_Make_Arg): Set Main_On_Command_Line to True when at least one main
3176         is specified on the command line.
3177
3178 2010-06-18  Ed Schonberg  <schonberg@adacore.com>
3179
3180         * sem_ch6.adb (Build_Body_For_Inline): Handle extended_return_statements
3181         * exp_ch6.adb (Expand_Inlined_Call): when possible, inline a body
3182         containing extented_return statements.
3183         * exp_util.adb (Make_CW_Equivalent_Type): If the root type is already
3184         constrained, do not build subtype declaration.
3185
3186 2010-06-18  Robert Dewar  <dewar@adacore.com>
3187
3188         * sem_res.adb (Analyze_Indexed_Component, Analyze_Selected_Component):
3189         Warn on assigning to packed atomic component.
3190
3191 2010-06-18  Robert Dewar  <dewar@adacore.com>
3192
3193         * sem_util.ads: Minor reformatting
3194         * einfo.ads, einfo.adb: Minor doc clarification (scope of decls in
3195         Expression_With_Actions).
3196         * snames.ads-tmpl: Minor comment fix
3197
3198 2010-06-18  Robert Dewar  <dewar@adacore.com>
3199
3200         * sem_prag.adb (Diagnose_Multiple_Pragmas): New procedure
3201         (Set_Imported): Use Import_Interface_Present to control message output
3202         * sinfo.ads, sinfo.adb (Import_Interface_Present): New flag
3203         * gnat_rm.texi: Document that we can have pragma Import and pragma
3204         Interface for the same subprogram.
3205
3206 2010-06-18  Robert Dewar  <dewar@adacore.com>
3207
3208         * lib-xref.adb (Generate_Reference): Fix bad reference to
3209         Has_Pragma_Unreferenced (clients should always use Has_Unreferenced).
3210
3211 2010-06-17  Eric Botcazou  <ebotcazou@adacore.com>
3212
3213         * gcc-interface/trans.c (set_gnu_expr_location_from_node): New static
3214         function.
3215         (gnat_to_gnu) <N_Expression_With_Actions>: New case.
3216         Use set_gnu_expr_location_from_node to set location information on the
3217         result.
3218
3219 2010-06-17  Arnaud Charlet  <charlet@adacore.com>
3220
3221         * gcc-interface/Make-lang.in: Update dependencies.
3222
3223 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3224
3225         * sem_util.adb (Is_Atomic_Object): Predicate does not apply to
3226         subprograms.
3227
3228 2010-06-17  Robert Dewar  <dewar@adacore.com>
3229
3230         * gnat_rm.texi, gnat_ugn.texi: Clean up documentation on warning and
3231         style check messages.
3232         * sem_res.adb (Resolve_Call): Don't call
3233         Check_For_Eliminated_Subprogram if we are analyzing within a spec
3234         expression.
3235
3236 2010-06-17  Robert Dewar  <dewar@adacore.com>
3237
3238         * debug.adb: Add documentation for debug flags .X and .Y
3239         * exp_ch4.adb (Expand_Short_Circuit_Operator): Use
3240         Use_Expression_With_Actions.
3241         * gnat1drv.adb (Adjust_Global_Switches): Set
3242         Use_Expression_With_Actions.
3243         * opt.ads (Use_Expression_With_Actions): New switch.
3244
3245 2010-06-17  Robert Dewar  <dewar@adacore.com>
3246
3247         * exp_intr.adb: Minor code reorganization (use UI_Max)
3248         * sem_intr.adb: use underlying type to check legality.
3249         * einfo.adb (Known_Static_Esize): False for generic types
3250         (Known_Static_RM_Size): False for generic types
3251         * einfo.ads (Known_Static_Esize): False for generic types
3252         (Known_Static_RM_Size): False for generic types
3253
3254 2010-06-17  Robert Dewar  <dewar@adacore.com>
3255
3256         * exp_ch4.ads: Minor code reorganization (specs in alpha order).
3257
3258 2010-06-17  Robert Dewar  <dewar@adacore.com>
3259
3260         * debug.adb: New debug flag -gnatd.X to use Expression_With_Actions
3261         node when expanding short circuit form with actions present for right
3262         opnd.
3263         * exp_ch4.adb: Minor reformatting
3264         (Expand_Short_Circuit_Operator): Use new Expression_With_Actions node if
3265         right opeand has actions present, and debug flag -gnatd.X is set.
3266         * exp_util.adb (Insert_Actions): Handle case of Expression_With_Actions
3267         node.
3268         * nlists.adb (Prepend_List): New procedure
3269         (Prepend_List_To): New procedure
3270         * nlists.ads (Prepend_List): New procedure
3271         (Prepend_List_To): New procedure
3272         * sem.adb: Add processing for Expression_With_Actions
3273         * sem_ch4.adb (Analyze_Expression_With_Actions): New procedure
3274         * sem_ch4.ads (Analyze_Expression_With_Actions): New procedure
3275         * sem_res.adb: Add processing for Expression_With_Actions.
3276         * sem_scil.adb: Add processing for Expression_With_Actions
3277         * sinfo.ads, sinfo.adb (N_Expression_With_Actions): New node.
3278         * sprint.ads, sprint.adb: Add processing for Expression_With_Actions
3279
3280 2010-06-17  Doug Rupp  <rupp@adacore.com>
3281
3282         * sem_intr.adb (Check_Intrinsic_Operator): Check that the types
3283         involved both have underlying integer types.
3284         * exp_intr.adb (Expand_Binary_Operator) New subprogram to expand a call
3285         to an intrinsic operator when the operand types or sizes are not
3286         identical.
3287         * s-auxdec-vms_64.ads: Revert "+" "-" ops back to Address now that
3288         64/32 Address/Integer works.
3289
3290 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3291
3292         * sem_ch12.adb (Mark_Context): Refine placement of Withed_Body flag, so
3293         that it marks a unit as needed by a spec only if the corresponding
3294         instantiation appears in that spec (and not in the corresponding body).
3295         * sem_elim.adb (Check_Eliminated): If we are within a subunit, the name
3296         in the pragma Eliminate has been parsed as a child unit, but the
3297         current compilation unit is in fact the parent in which the subunit is
3298         embedded.
3299
3300 2010-06-17  Vincent Celier  <celier@adacore.com>
3301
3302         * gnat_rm.texi: Fix typo
3303
3304 2010-06-17  Robert Dewar  <dewar@adacore.com>
3305
3306         * sem_util.adb: Minor reformatting
3307
3308 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3309
3310         * sem.adb (Do_Withed_Unit): if the unit in the with_clause is a generic
3311         instance, the clause now denotes the instance body. Traverse the
3312         corresponding spec because there may be no other dependence that will
3313         force the traversal of its own context.
3314
3315 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3316
3317         * sem_ch10.adb (Is_Ancestor_Unit): Subsidiary to
3318         Install_Limited_Context_Clauses, to determine whether a limited_with in
3319         some parent of the current unit designates some other parent, in which
3320         case the limited_with clause must not be installed.
3321         (In_Context): Refine test.
3322
3323 2010-06-17  Gary Dismukes  <dismukes@adacore.com>
3324
3325         * sem_util.adb (Collect_Primitive_Operations): In the of an untagged
3326         type with a dispatching equality operator that is overridden (for a
3327         tagged full type), don't include the overridden equality in the list of
3328         primitives. The overridden equality is detected by testing for an
3329         Aliased field that references the overriding equality.
3330
3331 2010-06-17  Robert Dewar  <dewar@adacore.com>
3332
3333         * freeze.adb: Minor reformatting.
3334
3335 2010-06-17  Joel Brobecker  <brobecker@adacore.com brobecker>
3336
3337         * gnat_ugn.texi: Add a section introducing gdbserver.
3338
3339 2010-06-17  Thomas Quinot  <quinot@adacore.com>
3340
3341         * sem_res.adb, sem_ch4.adb, s-stoele.adb, par-labl.adb: Minor
3342         reformatting.
3343
3344 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3345
3346         * sem_aggr.adb (Valid_Ancestor_Type): handle properly the case of a
3347         constrained discriminated parent that is a private type.
3348         (Analyze_Record_Aggregate): when collecting inherited discriminants,
3349         handle properly an ancestor type that is a constrained private type.
3350
3351 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3352
3353         * sem_util.adb (Enclosing_Subprogram): If the called subprogram is
3354         protected, use the protected_subprogram_body only if the original
3355         subprogram has not been eliminated.
3356
3357 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3358
3359         * freeze.adb (Freeze_Expression): The designated type of an
3360         access_to_suprogram type can only be frozen if all types in its profile
3361         are fully defined.
3362
3363 2010-06-17  Robert Dewar  <dewar@adacore.com>
3364
3365         * par.adb: Minor comment fix
3366         * sem_aggr.adb, sem_ch3.adb: Minor reformatting
3367
3368 2010-06-17  Doug Rupp  <rupp@adacore.com>
3369
3370         * s-auxdec-vms_64.ads: Revert Integer to Long_Integer change, instead
3371         change Address to Short_Address in functions where both must be the
3372         same size for intrinsics to work.
3373
3374 2010-06-17  Thomas Quinot  <quinot@adacore.com>
3375
3376         * sem_ch4.adb (Analyze_Selected_Component): A selected component may
3377         not denote a (private) component of a protected object.
3378
3379 2010-06-17  Bob Duff  <duff@adacore.com>
3380
3381         * par-labl.adb (Try_Loop): Test whether the label and the goto are in
3382         the same list.
3383
3384 2010-06-17  Joel Brobecker  <brobecker@adacore.com brobecker>
3385
3386         * gnat_ugn.texi: Update the documentation about GDB re: exception
3387         catchpoints.
3388
3389 2010-06-17  Arnaud Charlet  <charlet@adacore.com>
3390
3391         * gnatvsn.ads: Bump to 4.6 version.
3392
3393 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3394
3395         * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration): The
3396         designated type of the generated pointer is the type of the original
3397         expression, not that of the function call itself, because the return
3398         type may be an untagged  derived type and the function may be an
3399         inherited operation.
3400
3401 2010-06-17  Robert Dewar  <dewar@adacore.com>
3402
3403         * exp_ch4.adb: Minor reformatting.
3404
3405 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3406
3407         * sinfo.ads, sinfo.adb (Inherited_Discriminant): New flag on
3408         N_Component_Association nodes, to indicate that a component association
3409         of an extension aggregate denotes the value of a discriminant of an
3410         ancestor type that has been constrained by the derivation.
3411         * sem_aggr.adb (Discr_Present): use Inherited_Discriminant to prevent a
3412         double expansion of the aggregate appearing in a context that delays
3413         expansion, to prevent double insertion of discriminant values when the
3414         aggregate is reanalyzed.
3415
3416 2010-06-17  Arnaud Charlet  <charlet@adacore.com>
3417
3418         * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Do not use
3419         Allocator as the Related_Node of Return_Obj_Access in call to
3420         Make_Temporary below as this would create a sort of infinite
3421         "recursion".
3422
3423 2010-06-17  Ben Brosgol  <brosgol@adacore.com>
3424
3425         * gnat_ugn.texi: Update gnatcheck doc.
3426
3427 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3428
3429         * sem_ch3.adb (Build_Incomplete_Type_Declaration): If there is an
3430         incomplete view of the type that is not tagged, and the full type is a
3431         tagged extension, create class_wide type now, and warn that the
3432         incomplete view should be tagged as well.
3433
3434 2010-06-17  Vincent Celier  <celier@adacore.com>
3435
3436         * gnatcmd.adb (Non_VMS_Usage): Do not issue usage for gnat sync.
3437         Update the last line of the usage, indicating what commands do not
3438         accept project file switches.
3439         * vms_conv.adb: Do not issue usage line for GNAT SYNC
3440         * vms_data.ads: Fix errors in the qualifiers /LOGFILE and /MAIN of
3441         GNAT ELIM.
3442         * gnat_ugn.texi: Document the relaxed rules for library directories in
3443         externally built library projects.
3444
3445 2010-06-17  Doug Rupp  <rupp@adacore.com>
3446
3447         * s-auxdec-vms_64.ads: Make boolean and arithmetic operations intrinsic
3448         where possible.
3449         * s-auxdec-vms-alpha.adb: Remove kludges for aforemention.
3450         * gcc-interface/Makefile.in: Update VMS target pairs.
3451
3452 2010-06-17  Vasiliy Fofanov  <fofanov@adacore.com>
3453
3454         * adaint.c: Reorganized in order to avoid use of GetProcessId to stay
3455         compatible with Windows NT 4.0 which doesn't provide this function.
3456
3457 2010-06-17  Vincent Celier  <celier@adacore.com>
3458
3459         * ali-util.adb (Time_Stamp_Mismatch): In Verbose mode, if there is
3460         different timestamps but the checksum is the same, issue a short
3461         message saying so.
3462
3463 2010-06-17  Arnaud Charlet  <charlet@adacore.com>
3464
3465         * s-interr.adb (Finalize): If the Abort_Task signal is set to system,
3466         it means that we cannot reset interrupt handlers since this would
3467         require potentially sending the abort signal to the Server_Task.
3468
3469 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3470
3471         * exp_ch4.adb: expand NOT for VMS types.
3472         * sem_util.adb: Use OpenVMS_On_Target for IS_VMS_Operator.
3473
3474 2010-06-17  Sergey Rybin  <rybin@adacore.com>
3475
3476         * vms_data.ads: Add qualifier for '--no-elim-dispatch' gnatelim option.
3477         * gnat_ugn.texi (gnatelim): add description for --no-elim-dispatch
3478         option.
3479
3480 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3481
3482         * exp_ch6.adb (Expand_Call): Do not expand a call to an internal
3483         protected operation if the subprogram has been eliminated.
3484
3485 2010-06-17  Vincent Celier  <celier@adacore.com>
3486
3487         * prj-nmsc.adb (Check_Library_Attributes): Allow the different
3488         directories associated with a library to be any directory when the
3489         library project is externally built.
3490
3491 2010-06-17  Vincent Celier  <celier@adacore.com>
3492
3493         * make.adb (Check): If switch -m is used, deallocate the memory that
3494         may be allocated when computing the checksum.
3495
3496 2010-06-17  Eric Botcazou  <ebotcazou@adacore.com>
3497
3498         * g-socthi-mingw.adb (C_Recvmsg): Add 'use type' clause for C.size_t;
3499         (C_Sendmsg): Likewise.
3500
3501 2010-06-17  Thomas Quinot  <quinot@adacore.com>
3502
3503         * sem_res.adb: Update comments.
3504
3505 2010-06-17  Vincent Celier  <celier@adacore.com>
3506
3507         * back_end.adb (Scan_Compiler_Arguments): Process last argument
3508
3509 2010-06-17  Robert Dewar  <dewar@adacore.com>
3510
3511         * exp_ch3.adb, exp_ch6.adb, exp_smem.adb, exp_util.adb: Use Ekind_In.
3512         * layout.adb, freeze.adb: Use Make_Temporary.
3513
3514 2010-06-17  Jerome Lambourg  <lambourg@adacore.com>
3515
3516         * exp_ch11.adb (Expand_N_Raise_Statement): Expand raise statements in
3517         .NET/JVM normally as this is now perfectly supported by the backend.
3518
3519 2010-06-17  Pascal Obry  <obry@adacore.com>
3520
3521         * gnat_rm.texi: Fix minor typo, remove duplicate blank lines.
3522
3523 2010-06-17  Vincent Celier  <celier@adacore.com>
3524
3525         * make.adb (Collect_Arguments_And_Compile): Create include path file
3526         only when -x is specified.
3527         (Gnatmake): Ditto
3528         * opt.ads (Use_Include_Path_File): New Boolean flag, initialized to
3529         False.
3530         * prj-env.adb (Set_Ada_Paths): New Boolean parameters Include_Path and
3531         Objects_Path, defaulted to True. Only create include path file if
3532         Include_Path is True, only create objects path file if Objects_Path is
3533         True.
3534         * prj-env.ads (Set_Ada_Paths): New Boolean parameters Include_Path and
3535         Objects_Path, defaulted to True.
3536         * switch-m.adb (Scan_Make_Switches): Set Use_Include_Path_File to True
3537         when -x is used.
3538
3539 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3540
3541         * exp_disp.adb (Build_Interface_Thunk): Use base type of formal to
3542         determine whether it has the controlling type, when the formal is an
3543         access parameter.
3544
3545 2010-06-17  Eric Botcazou  <ebotcazou@adacore.com>
3546
3547         * s-crtl.ads (ssize_t): New type.
3548         (read): Fix signature.
3549         (write): Likewise.
3550         * g-socthi.ads: Add 'with System.CRTL' clause.  Remove ssize_t and
3551         'use type' directive for C.size_t, add one for System.CRTL.ssize_t.
3552         (C_Recvmsg): Replace ssize_t with System.CRTL.ssize_t.
3553         (C_Sendmsg): Likewise.
3554         * g-socthi.adb (Syscall_Recvmsg): Likewise.
3555         (Syscall_Sendmsg): Likewise.
3556         (C_Recvmsg): Likewise.
3557         (C_Sendmsg): Likewise.
3558         * g-socthi-mingw.ads: Add 'with System.CRTL' clause.  Remove ssize_t
3559         and 'use type' directive for C.size_t, add one for System.CRTL.ssize_t.
3560         (C_Recvmsg): Replace ssize_t with System.CRTL.ssize_t.
3561         (C_Sendmsg): Likewise.
3562         * g-socthi-mingw.adb (C_Recvmsg): Likewise.
3563         (C_Sendmsg): Likewise.
3564         * g-socthi-vms.ads: Add 'with System.CRTL' clause.  Remove ssize_t and
3565         'use type' directive for C.size_t, add one for System.CRTL.ssize_t.
3566         (C_Recvmsg): Replace ssize_t with System.CRTL.ssize_t.
3567         (C_Sendmsg): Likewise.
3568         * g-socthi-vms.adb (C_Recvmsg): Likewise.
3569         (C_Sendmsg): Likewise.
3570         * g-socthi-vxworks.ads Add 'with System.CRTL' clause.  Remove ssize_t
3571         and 'use type' directive for C.size_t, add one for System.CRTL.ssize_t.
3572         (C_Recvmsg): Replace ssize_t with System.CRTL.ssize_t.
3573         (C_Sendmsg): Likewise.
3574         * g-socthi-vxworks.adb (C_Recvmsg): Likewise.
3575         (C_Sendmsg): Likewise.
3576         * g-sercom-linux.adb (Read): Use correct types to call 'read'.
3577         (Write): Likewise to call 'write'.
3578         * s-os_lib.adb (Read): Use correct type to call System.CRTL.read.
3579         (Write): Use correct type to call System.CRTL.write.
3580         * s-tasdeb.adb (Write): Likewise.
3581
3582 2010-06-17  Vincent Celier  <celier@adacore.com>
3583
3584         * prj-proc.adb (Copy_Package_Declarations): Change argument name
3585         Naming_Restricted to Restricted. If Restricted is True, do not copy the
3586         value of attribute Linker_Options.
3587
3588 2010-06-17  Eric Botcazou  <ebotcazou@adacore.com>
3589
3590         * gcc-interface/trans.c (push_stack, pop_stack): Delete.
3591         (Case_Statement_to_gnu): Adjust.
3592         (Loop_Statement_to_gnu): Likewise.
3593         (Subprogram_Body_to_gnu): Likewise.
3594         (Handled_Sequence_Of_Statements_to_gnu): Likewise.
3595         (Compilation_Unit_to_gnu): Likewise.
3596
3597 2010-06-17  Robert Dewar  <dewar@adacore.com>
3598
3599         * exp_fixd.adb, exp_imgv.adb, exp_intr.adb, exp_pakd.adb, exp_prag.adb,
3600         exp_sel.adb, exp_util.adb, sem_ch10.adb, sem_ch12.adb, sem_ch13.adb,
3601         sem_ch3.adb, sem_ch4.adb, sem_ch5.adb, sem_ch8.adb, sem_ch9.adb,
3602         sem_dist.adb, sem_util.adb: Use Make_Temporary
3603         * itypes.ads, tbuild.ads: Minor comment update
3604         * exp_ch9.adb, exp_dist.adb: Minor reformatting
3605
3606 2010-06-17  Thomas Quinot  <quinot@adacore.com>
3607
3608         * exp_imgv.adb, exp_ch7.ads: Minor reformatting.
3609
3610 2010-06-17  Robert Dewar  <dewar@adacore.com>
3611
3612         * exp_ch9.adb, exp_disp.adb, exp_dist.adb: Use Make_Temporary.
3613
3614 2010-06-17  Thomas Quinot  <quinot@adacore.com>
3615
3616         * sprint.adb (pg): Set Dump_Freeze_Null, to be consistent with -gnatdg.
3617
3618 2010-06-17  Robert Dewar  <dewar@adacore.com>
3619
3620         * exp_ch6.adb, exp_ch7.adb, exp_ch5.adb: Use Make_Temporary
3621         * tbuild.ads (Make_Temporary): More comment updates
3622         * tbuild.adb: Minor reformatting
3623
3624 2010-06-17  Robert Dewar  <dewar@adacore.com>
3625
3626         * checks.adb, exp_aggr.adb, exp_atag.adb, exp_attr.adb, exp_ch11.adb,
3627         exp_ch3.adb, exp_ch4.adb: Minor code reorganization.
3628         Use Make_Temporary.
3629         * tbuild.ads, tbuild.adb (Make_Temporary): Clean up, use Entity_Id
3630         instead of Node_Id.
3631         (Make_Temporary): Add more extensive documentation
3632
3633 2010-06-17  Robert Dewar  <dewar@adacore.com>
3634
3635         * sem_intr.adb, sem_prag.adb, sem_res.adb, sem_type.adb, sem_util.adb,
3636         sem_warn.adb, sem_eval.adb: Minor reformatting.  Use Ekind_In.
3637         (Set_Slice_Subtype): Explicitly freeze the slice's itype at the point
3638         where the slice's actions are inserted.
3639         (Decompose_Expr): Account for possible rewriting of slice bounds
3640         resulting from side effects suppression caused by the above freezing,
3641         so that folding of bounds is preserved by such rewriting.
3642
3643 2010-06-17  Robert Dewar  <dewar@adacore.com>
3644
3645         * einfo.ads, einfo.adb (Get_Record_Representation_Clause): New function.
3646         * freeze.adb (Freeze_Record_Type): Add call to
3647         Check_Record_Representation_Clause.
3648         * sem_ch13.adb (Check_Record_Representation_Clause): New function
3649         (Analyze_Record_Representation_Clause): Split out overlap code into this
3650         new function.
3651         (Check_Component_Overlap): Moved inside
3652         Check_Record_Representation_Clause.
3653         * sem_ch13.ads (Check_Record_Representation_Clause): New function.
3654
3655 2010-06-17  Robert Dewar  <dewar@adacore.com>
3656
3657         * back_end.adb, sem_res.adb, switch-c.adb, sem_scil.adb: Minor
3658         reformatting.
3659         * sem_attr.adb, sem_cat.adb, sem_disp.adb, sem_elab.adb, sem_elim.adb,
3660         sem_eval.adb: Use Ekind_In
3661
3662 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3663
3664         * sem_ch8.adb: better error message for illegal inherited discriminant
3665
3666 2010-06-17  Vincent Celier  <celier@adacore.com>
3667
3668         * bindusg.adb: Remove lines for -A and -C
3669         * gnat_ugn.texi: Remove all documentation and examples of switches -A
3670         and -C for gnatbind and gnatlink.
3671         * gnatlink.adb (Usage): Remove lines for -A and -C
3672         * switch-b.adb (Scan_Binder_Switches): Issue warning when switch -C is
3673         specified.
3674         * gcc-interface/Make-lang.in: Update dependencies.
3675
3676 2010-06-17  Vincent Celier  <celier@adacore.com>
3677
3678         * back_end.adb (Scan_Compiler_Arguments): Put all arguments in new
3679         local Argument_List variable Args.
3680         * switch-c.adb (Scan_Front_End_Switches): New Argument_List argument
3681         Args.
3682         (Switch_Subsequently_Cancelled): New Argument_List argument Args. Look
3683         for subsequent switches in Args.
3684         * switch-c.ads (Scan_Front_End_Switches): New Argument_List argument
3685         Args.
3686         * gcc-interface/Make-lang.in: Update dependencies.
3687
3688 2010-06-17  Robert Dewar  <dewar@adacore.com>
3689
3690         * einfo.adb: Minor code fix, allow E_Class_Wide_Type for
3691         Equivalent_Type to match documentation.
3692
3693 2010-06-17  Robert Dewar  <dewar@adacore.com>
3694
3695         * sem_ch6.adb, sem_ch7.adb: Minor reformatting.
3696         * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_ch10.adb, sem_ch12.adb,
3697         sem_ch4.adb, sem_ch8.adb, sem_ch13.adb: Make use of Ekind_In.
3698
3699 2010-06-17  Thomas Quinot  <quinot@adacore.com>
3700
3701         * sem_res.adb (Set_Slice_Subtype): Always freeze the slice's itype.
3702
3703 2010-06-17  Thomas Quinot  <quinot@adacore.com>
3704
3705         * freeze.adb (Freeze_Expression): Short circuit operators are valid
3706         freeze node insertion points.
3707
3708 2010-06-17  Robert Dewar  <dewar@adacore.com>
3709
3710         * switch-c.ads, switch-c.adb, sem_ch13.adb: Minor reformatting.
3711         * sem_ch12.adb: Add pragmas Assert and Check to previous change.
3712
3713 2010-06-17  Gary Dismukes  <dismukes@adacore.com>
3714
3715         * layout.adb (Layout_Type): Broaden test for setting an array type's
3716         Component_Size to include all scalar types, not just discrete types
3717         (components of real types were missed).
3718         * sem_ch3.adb (Constrain_Index): Add missing setting of First_Literal
3719         on the itype created for an index (consistent with Make_Index and
3720         avoids possible Assert_Failures).
3721
3722 2010-06-17  Robert Dewar  <dewar@adacore.com>
3723
3724         * atree.ads, atree.adb: Add 6-parameter version of Ekind_In
3725         * einfo.adb: Minor code reformatting (use Ekind_In)
3726
3727 2010-06-17  Robert Dewar  <dewar@adacore.com>
3728
3729         * sem_warn.adb (Test_Ref): Abandon scan if access subprogram parameter
3730         found.
3731
3732 2010-06-17  Vincent Celier  <celier@adacore.com>
3733
3734         * back_end.adb: Minor comment updates
3735         * switch-c.adb: Remove dependencies on gcc C sources
3736         * gcc-interface/Make-lang.in: Add a-comlin.o to the object file list
3737         for the compiler.
3738
3739 2010-06-17  Ed Schonberg  <schonberg@adacore.com>
3740
3741         * sem_ch12.adb: propagate Pragma_Enabled flag to generic.
3742         * get_scos.adb: Set C2 flag in decision entry of pragma to 'e' (enabled)
3743         * par_sco.ads, par_sco.adb (Set_SCO_Pragma_Enabled): New procedure
3744         Remove use of Node field in SCOs table
3745         (Output_Header): Set 'd' to initially disable pragma entry
3746         * put_scos.adb (Put_SCOs): New flag indicating if pragma is enabled
3747         * scos.ads, scos.adb: Remove Node field from internal SCOs table.
3748         Use C2 field of pragma decision header to indicate enabled.
3749         * sem_prag.adb: Add calls to Set_SCO_Pragma_Enabled.
3750         * gcc-interface/Make-lang.in: Update dependencies.
3751
3752 2010-06-17  Vincent Celier  <celier@adacore.com>
3753
3754         * back_end.adb (Next_Arg): Moved to procedure Scan_Compiler_Arguments
3755         (Scan_Compiler_Arguments): Call Scan_Front_End_Switches with Next_Arg
3756         (Switch_Subsequently_Cancelled): Function moved to the body of Switch.C
3757         * back_end.ads (Scan_Front_End_Switches): Function moved to the body of
3758         Switch.C.
3759         * switch-c.adb: Copied a number of global declarations from back_end.adb
3760         (Len_Arg): New function copied from back_end.adb
3761         (Switch_Subsequently_Cancelled): New function moved from back_end.adb
3762         (Scan_Front_End_Switches): New parameter Arg_Rank used to call
3763         Switch_Subsequently_Cancelled.
3764         * switch-c.ads (Scan_Front_End_Switches): New parameter Arg_Rank.
3765         * gcc-interface/Makefile.in: Add line so that shared libgnat is linked
3766         with -lexc on Tru64.
3767
3768 2010-06-17  Robert Dewar  <dewar@adacore.com>
3769
3770         * prj.ads, prj.adb: Minor reformatting
3771
3772 2010-06-17  Thomas Quinot  <quinot@adacore.com>
3773
3774         * put_scos.adb: Do not generate a blank line in SCOs when omitting the
3775         CP line for a disabled pragma.
3776
3777 2010-06-17  Emmanuel Briot  <briot@adacore.com>
3778
3779         * prj-proc.adb, prj.adb, prj.ads (Check_Or_Set_Typed_Variable): New
3780         subprogram.
3781         (Process_Declarative_Item): An invalid value in an typed variable
3782         declaration is no longer always fatal.
3783
3784 2010-06-16  Arnaud Charlet  <charlet@adacore.com>
3785
3786         * get_scos.adb, par_sco.adb, par_sco.ads, put_scos.adb, scos.adb,
3787         scos.ads, exp_ch4.adb, sem_warn.adb: Code clean up, update
3788         documentation.
3789
3790 2010-06-16  Javier Miranda  <miranda@adacore.com>
3791
3792         * exp_disp.adb (Expand_Dispatching_Call): Adjust the decoration of the
3793         node referenced by the SCIL node of dispatching "=" to skip the tags
3794         comparison.
3795
3796 2010-06-16  Ed Schonberg  <schonberg@adacore.com>
3797
3798         * sem_ch5.adb (Analyze_Exit_Statement): Return if no enclosing loop,
3799         to prevent cascaded errors and compilation aborts.
3800
3801 2010-06-16  Robert Dewar  <dewar@adacore.com>
3802
3803         * back_end.adb (Switch_Subsequently_Cancelled): New function
3804         Move declarations to package body level to support this change
3805         * back_end.ads (Switch_Subsequently_Cancelled): New function
3806         * gnat_ugn.texi: Document -gnat-p switch
3807         * switch-c.adb (Scan_Front_End_Switches): Implement -gnat-p switch
3808         * ug_words: Add entry for -gnat-p (UNSUPPRESS_ALL)
3809         * usage.adb: Add line for -gnat-p switch
3810         * vms_data.ads: Add entry for UNSUPPRESS_ALL (-gnat-p)
3811
3812 2010-06-16  Robert Dewar  <dewar@adacore.com>
3813
3814         * sem_warn.adb (Check_Infinite_Loop_Warning): Declaration counts as
3815         modification.
3816
3817 2010-06-16  Robert Dewar  <dewar@adacore.com>
3818
3819         * exp_disp.adb: Minor reformatting
3820
3821 2010-06-16  Ed Schonberg  <schonberg@adacore.com>
3822
3823         * sem_ch3.adb (Complete_Private_Subtype): Inherit class_wide type from
3824         base type only if it was not previously created for the partial view.
3825
3826 2010-06-16  Thomas Quinot  <quinot@adacore.com>
3827
3828         * tbuild.ads: Minor comment fix
3829
3830 2010-06-15  Nathan Froyd  <froydnj@codesourcery.com>
3831
3832         * gcc-interface/trans.c (gnu_stack_free_list): Delete.
3833         (gnu_except_ptr_stack): Change type to VEC.  Update comment.
3834         (gnu_elab_proc_stack): Likewise.
3835         (gnu_return_label_stack): Likewise.
3836         (gnu_loop_label_stack): Likewise.
3837         (gnu_switch_label_stack): Likewise.
3838         (gnu_constraint_label_stack): Likewise.
3839         (gnu_storage_error_label_stack): Likewise.
3840         (gnu_program_error_label_stack): Likewise.
3841         (push_exception_label_stack): Take a VEC ** instead of a tree *.
3842         (push_stack): Likewise.  Remove unused second parameter.  Update
3843         callers.
3844         (pop_stack): Take a VEC * instead of a tree *.  Update callers.
3845         (gigi): Initialize stacks as VECs.
3846         (Identifier_to_gnu): Use VEC_last instead of TREE_VALUE.
3847         (Case_Statement_to_gnu): Likewise.
3848         (Subprogram_Body_to_gnu): Likewise.
3849         (call_to_gnu): Likewise.
3850         (Exception_Handler_to_gnu_sjlj): Likewise.
3851         (gnat_to_gnu): Likewise.
3852         (get_exception_label): Likewise.
3853
3854 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
3855
3856         * sem_ch3.adb (Build_Derived_Record_Type): if derived type is an
3857         anonymous base generated when the parent is a constrained discriminated
3858         type, propagate interface list to first subtype because it may appear
3859         in a current instance within the extension part of the derived type
3860         declaration, and its own subtype declaration has not been elaborated
3861         yet.
3862         * exp_disp.adb (Build_Interface_Thunk): Use base type of formal to
3863         determine whether it has the controlling type.
3864
3865 2010-06-14  Jerome Lambourg  <lambourg@adacore.com>
3866
3867         * exp_ch11.adb (Expand_N_Raise_Statement): Make sure that the explicit
3868         raise of CE, SE and PE have the reason correctly set and are properly
3869         expanded before stopping the expansions of .NET/JVM exceptions.
3870
3871 2010-06-14  Robert Dewar  <dewar@adacore.com>
3872
3873         * opt.ads (Check_Policy_List): Add some clarifying comments
3874         * sem_prag.adb (Analyze_Pragma, case Check): Set Pragma_Enabled flag
3875         on rewritten Assert pragma.
3876
3877 2010-06-14  Gary Dismukes  <dismukes@adacore.com>
3878
3879         * sem_ch6.adb (Check_Overriding_Indicator): Add a special check for
3880         controlled operations, so that they will be treated as overriding even
3881         if the overridden subprogram is marked Is_Hidden, as long as the
3882         overridden subprogram's parent subprogram is not hidden.
3883
3884 2010-06-14  Robert Dewar  <dewar@adacore.com>
3885
3886         * debug.adb: Entry for gnatw.d no longer specific for while loops
3887         * einfo.adb (First_Exit_Statement): New attribute for E_Loop
3888         * einfo.ads (First_Exit_Statement): New attribute for E_Loop
3889         * sem_ch5.adb (Analyze_Loop_Statement): Check_Infinite_Loop_Warning has
3890         new calling sequence to include test for EXIT WHEN.
3891         (Analyze_Exit_Statement): Chain EXIT statement into exit statement chain
3892         * sem_warn.ads, sem_warn.adb (Check_Infinite_Loop_Warning): Now handles
3893         EXIT WHEN case.
3894         * sinfo.adb (Next_Exit_Statement): New attribute of N_Exit_Statement
3895         node.
3896         * sinfo.ads (N_Pragma): Correct comment on Sloc field (points to
3897         PRAGMA, not to pragma identifier).
3898         (Next_Exit_Statement): New attribute of N_Exit_Statement node
3899
3900 2010-06-14  Robert Dewar  <dewar@adacore.com>
3901
3902         * sem_res.adb (Resolve_Short_Circuit): Fix sloc of "assertion/check
3903         would fail" msg.
3904
3905 2010-06-14  Robert Dewar  <dewar@adacore.com>
3906
3907         * par-ch2.adb (Scan_Pragma_Argument_Association): Clarify message for
3908         missing pragma argument identifier.
3909
3910 2010-06-14  Robert Dewar  <dewar@adacore.com>
3911
3912         * atree.ads, atree.adb (Ekind_In): New functions.
3913
3914 2010-06-14  Robert Dewar  <dewar@adacore.com>
3915
3916         * exp_ch4.adb (Expand_N_Op_Expon): Optimize 2**N in stand alone context
3917
3918 2010-06-14  Robert Dewar  <dewar@adacore.com>
3919
3920         * usage.adb (Usage): Redo documentation of -gnatwa.
3921
3922 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
3923
3924         * sem_ch8.adb (Find_Type): The attribute 'class cannot be applied to
3925         an untagged incomplete type that is a limited view.
3926
3927 2010-06-14  Sergey Rybin  <rybin@adacore.com>
3928
3929         * gnat_ugn.texi: Add description of '-cargs gcc_switches' to gnatstub
3930         and gnatppa.
3931
3932 2010-06-14  Thomas Quinot  <quinot@adacore.com>
3933
3934         * exp_ch4.adb (Expand_Short_Circuit_Operator): New subprogram,
3935         factoring duplicated code between...
3936         (Expand_N_And_Than, Expand_N_Or_Else): Remove duplicated code.
3937         * a-envvar.ads: Minor reformatting
3938
3939 2010-06-14  Arnaud Charlet  <charlet@adacore.com>
3940
3941         * ali.adb, ali.ads, lib-xref.ads: Document new '+' letter for C/C++
3942         static entities.
3943         (Scan_ALI): Take into account new Visibility field.
3944         (Visibility_Kind): New type.
3945         (Xref_Entity_Record): Replace Lib field by Visibility.
3946
3947         * gcc-interface/Make-lang.in: Update dependencies.
3948
3949 2010-06-14  Pascal Obry  <obry@adacore.com>
3950
3951         * raise.h: Remove unused defintions.
3952
3953 2010-06-14  Bob Duff  <duff@adacore.com>
3954
3955         * par-ch10.adb (P_Subunit): If the next token after "separate(X)" is
3956         Tok_Not or Tok_Overriding, call P_Subprogram. We had previously given
3957         the incorrect error "proper body expected".
3958         * par-ch6.adb (P_Subprogram): Suppress "overriding indicator not
3959         allowed here" error in case of subunits, which was triggered by the
3960         above change to P_Subunit.
3961
3962 2010-06-14  Sergey Rybin  <rybin@adacore.com>
3963
3964         * gnat_ugn.texi, vms_data.ads: Update gnatelim doc.
3965
3966 2010-06-14  Thomas Quinot  <quinot@adacore.com>
3967
3968         * lib-util.adb: Minor code reorganization.
3969
3970 2010-06-14  Robert Dewar  <dewar@adacore.com>
3971
3972         * ali.adb (Scan_ALI): Implement reading and storing of N lines
3973         (Known_ALI_Lines): Add entry for 'N' (notes)
3974         * ali.ads (Notes): New table to store Notes information
3975         * alloc.ads: Add entries for Notes table
3976         * lib-util.adb (Write_Info_Int): New procedure
3977         (Write_Info_Slit): New procedure
3978         (Write_Info_Uint): New procedure
3979         * lib-util.ads (Write_Info_Int): New procedure
3980         (Write_Info_Slit): New procedure
3981         (Write_Info_Uint): New procedure
3982         * lib-writ.adb (Write_Unit_Information): Output N (notes) lines
3983         * lib-writ.ads: Update documentation for N (Notes) lines
3984         * lib.adb (Store_Note): New procedure
3985         * lib.ads (Notes): New table
3986         (Store_Note): New procedure
3987         * sem_prag.adb: Call Store_Note for affected pragmas
3988
3989 2010-06-14  Thomas Quinot  <quinot@adacore.com>
3990
3991         * socket.c: Fix wrong condition in #ifdef
3992         * g-socket.adb, g-sothco.ads: Functions imported from socket.c that
3993         take or return char* values can't use Interfaces.C.Strings.chars_ptr,
3994         because on VMS this type is a 32-bit pointer which is not compatible
3995         with the default for C pointers for code compiled with gcc on that
3996         platform.
3997
3998 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
3999
4000         * sem_util (Is_VMS_Operator): New predicate to determine whether an
4001         operator is an intrinsic operator declared in the DEC system extension.
4002         * sem_res.adb (Resolve_Logical_Op): operation is legal on signed types
4003         if the operator is a VMS intrinsic.
4004         * sem_eval.adb (Eval_Logical_Op): Operation is legal and be
4005         constant-folded if the operands are signed and the operator is a VMS
4006         intrinsic.
4007
4008 2010-06-14  Robert Dewar  <dewar@adacore.com>
4009
4010         * g-socket.adb, gnatcmd.adb: Minor reformatting.
4011
4012 2010-06-14  Pascal Obry  <obry@adacore.com>
4013
4014         * s-finimp.adb: Fix typo.
4015         * raise.h: Remove duplicate blank line.
4016
4017 2010-06-14  Vincent Celier  <celier@adacore.com>
4018
4019         * prj-nmsc.adb (Add_Sources): Always set the object file and the
4020         switches file names, as the configuration of the language may change
4021         in an extending project.
4022         (Process_Naming_Scheme): For sources of projects that are extended, set
4023         the configuration of the language from the highest extending project
4024         where the language is declared.
4025
4026 2010-06-14  Gary Dismukes  <dismukes@adacore.com>
4027
4028         * sem_res.adb (Resolve_Call): For infinite recursion check, test
4029         whether the called subprogram is inherited from a containing subprogram.
4030         (Same_Or_Aliased_Subprograms): New function
4031
4032 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
4033
4034         * sem_ch8.adb (End_Use_Type): Before indicating that an operator is not
4035         use-visible, check whether it is a primitive for more than one type.
4036
4037 2010-06-14  Robert Dewar  <dewar@adacore.com>
4038
4039         * sem_ch3.adb (Copy_And_Swap): Copy Has_Pragma_Unmodified flag.
4040
4041         * sem_ch7.adb (Preserve_Full_Attributes): Preserve
4042         Has_Pragma_Unmodified flag.
4043
4044 2010-06-14  Thomas Quinot  <quinot@adacore.com>
4045
4046         * g-sttsne-locking.adb, g-sttsne-locking.ads, g-sttsne.ads,
4047         g-sttsne-vxworks.adb, g-sttsne-dummy.ads: Removed. Mutual exclusion is
4048         now done in GNAT.Sockets if necessary.
4049         * gsocket.h, g-socket.adb, g-sothco.ads (GNAT.Sockets.Get_XXX_By_YYY):
4050         Ensure mutual exclusion for netdb operations if the target platform
4051         requires it.
4052         (GNAT.Sockets.Thin_Common): New binding for getXXXbyYYY, treating struct
4053         hostent as an opaque type to improve portability.
4054         * s-oscons-tmplt.c, socket.c: For the case of Vxworks, emulate
4055         gethostbyYYY using proprietary VxWorks API so that a uniform interface
4056         is available for the Ada side.
4057         * gcc-interface/Makefile.in: Remove g-sttsne-*
4058         * gcc-interface/Make-lang.in: Update dependencies.
4059
4060 2010-06-14  Vincent Celier  <celier@adacore.com>
4061
4062         * gnatcmd.adb (Mapping_File): New function.
4063
4064 2010-06-14  Javier Miranda  <miranda@adacore.com>
4065
4066         * sem_ch3.adb (Derive_Subprograms): Remove over-restrictive assertion.
4067
4068 2010-06-14  Arnaud Charlet  <charlet@adacore.com>
4069
4070         * ali.adb: Fix typo.
4071         * s-auxdec-vms-alpha.adb, scng.ads: Minor reformatting.
4072
4073 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
4074
4075         * sem_ch12.adb: Make Mark_Context transitive, and apply to subprogram
4076         instances.
4077
4078         * sem_ch8.adb (Find_Expanded_Name): If a candidate compilation unit in
4079         the context does not have a homonym of the selector, emit default
4080         error message.
4081
4082 2010-06-14  Robert Dewar  <dewar@adacore.com>
4083
4084         * sem.adb, sem_ch12.adb, sem_util.adb: Minor reformatting and
4085         comment addition.
4086
4087 2010-06-14  Arnaud Charlet  <charlet@adacore.com>
4088
4089         * lib-xref.ads: Doc updates:
4090          - Allocate 'Q' for #include entity kind
4091          - Free 'Z'
4092          - Allocate 'g' for regular macros
4093          - Allocate 'G' for function-like macros
4094
4095 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
4096
4097         * sinfo.ads, sinfo.adb (Withed_Body): New attribute of a with_clause.
4098         Indicates that there is an instantiation in the current unit that
4099         loaded the body of the unit denoted by the with_clause.
4100         * sem_ch12.adb (Mark_Context): When instanting a generic body, check
4101         whether a with_clause in the current context denotes the unit that
4102         holds the generic declaration, and mark the with_clause accordingly.
4103         (Instantiate_Package_Body): call Mark_Context.
4104         * sem.adb (Process_Bodies_In_Context): Use Withed_Body to determine
4105         whether a given body should be traversed before the spec of the main
4106         unit.
4107
4108 2010-06-14  Ed Falis  <falis@adacore.com>
4109
4110         * sysdep.c: Fix 653 build against vThreads headers.
4111
4112 2010-06-14  Robert Dewar  <dewar@adacore.com>
4113
4114         * sinfo.ads: Minor reformatting.
4115
4116 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
4117
4118         * sem_ch6.adb (Analyze_Subprogram_Body): Do not check conformance when
4119         the spec has been generated for a body without spec that carries an
4120         Inline_Always pragma.
4121
4122 2010-06-14  Arnaud Charlet  <charlet@adacore.com>
4123
4124         * lib-xref.ads: Documentation change: allocate 'Z' letter to C/C++
4125         macro.
4126
4127 2010-06-14  Jerome Lambourg  <lambourg@adacore.com>
4128
4129         * exp_dbug.adb (Debug_Renaming_Declaration): Do not output any debug
4130         declaration for VMs, as those are useless and might lead to duplicated
4131         local variable names in the generated code.
4132         * gcc-interface/Make-lang.in: Update dependencies.
4133
4134 2010-06-14  Robert Dewar  <dewar@adacore.com>
4135
4136         * opt.ads, sem.adb, sem_elab.adb: Minor reformatting
4137
4138 2010-06-14  Robert Dewar  <dewar@adacore.com>
4139
4140         * exp_aggr.adb (Has_Address_Clause): Moved to Exp_Util, and there it
4141         is renamed as Has_Following_Address_Clause.
4142         * exp_ch3.adb (Needs_Simple_Initialization): Add Consider_IS argument
4143         to allow the caller to avoid Initialize_Scalars having an effect.
4144         (Expand_N_Object_Declaration): Do not do Initialize_Scalars stuff for
4145         scalars with an address clause specified.
4146         * exp_ch3.ads (Needs_Simple_Initialization): Add Consider_IS argument
4147         to allow the caller to avoid Initialize_Scalars having an effect.
4148         * exp_util.adb (Has_Following_Address_Clause): Moved here from Exp_Aggr
4149         (where it was called Has_Address_Clause).
4150         * exp_util.ads (Has_Following_Address_Clause): Moved here from Exp_Aggr
4151         (where it was called Has_Address_Clause).
4152         * freeze.adb (Warn_Overlay): Suppress message about overlaying causing
4153         problems for Initialize_Scalars (since we no longer initialize objects
4154         with an address clause.
4155
4156 2010-06-14  Robert Dewar  <dewar@adacore.com>
4157
4158         * exp_prag.adb (Expand_Pragma_Check): Set Loc of generated code from
4159         condition.
4160
4161 2010-06-14  Gary Dismukes  <dismukes@adacore.com>
4162
4163         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Set Debug_Info_Needed
4164         on the entity of an implicitly generated postcondition procedure.
4165
4166 2010-06-14  Thomas Quinot  <quinot@adacore.com>
4167
4168         * sem_ch7.adb (Preserve_Full_Attributes): Propagate
4169         Discriminant_Constraint elist from full view to private view.
4170
4171 2010-06-14  Robert Dewar  <dewar@adacore.com>
4172
4173         * sem_res.adb: Minor reformatting.
4174
4175 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
4176
4177         * sem.adb: New version of unit traversal.
4178
4179         * sem_elab.adb (Check_Internal_Call): Do not place a call appearing
4180         within a generic unit in the table of delayed calls.
4181
4182 2010-06-14  Robert Dewar  <dewar@adacore.com>
4183
4184         * gnatcmd.adb, sem_util.adb, exp_ch3.adb: Minor reformatting
4185
4186 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
4187
4188         * sem_ch12.adb (Save_References): If an identifier has been rewritten
4189         during analysis as an explicit dereference, keep the reference implicit
4190         in the generic, but preserve the entity if global. This prevents
4191         malformed generic trees in the presence of some nested generics.
4192
4193 2010-06-14  Sergey Rybin  <rybin@adacore.com>
4194
4195         * gnat_ugn.texi: For the GNAT driver, clarify the effect of calling the
4196         tool with '-files=' option. Also fix some small errors (wrong brackets)
4197
4198 2010-06-14  Vincent Celier  <celier@adacore.com>
4199
4200         * gnatbind.adb: Call Scan_ALI with Directly_Scanned set to True for all
4201         the ALI files on the command line.
4202
4203         * ali.adb (Scan_ALI): Set component Directly_Scanned of the unit(s) to
4204         the same value as the parameter of the same name.
4205         * ali.ads (Scan_ALI): New Boolean parameter Directly_Scanned, defaulted
4206         to False.
4207         * bindgen.adb (Gen_Versions_Ada): Never emit version symbols for
4208         Stand-Alone Library interfaces. When binding Stand-Alone Libraries,
4209         emit version symbols only for the units of the library.
4210         (Gen_Versions_C): Ditto.
4211
4212 2010-06-14  Gary Dismukes  <dismukes@adacore.com>
4213
4214         * sem_ch4.adb: Fix typo.
4215
4216 2010-06-14  Vasiliy Fofanov  <fofanov@adacore.com>
4217
4218         * s-oscons-tmplt.c (IOV_MAX): redefine on Tru64 and VMS since the
4219         vector IO doesn't work at default value properly.
4220
4221 2010-06-14  Doug Rupp  <rupp@adacore.com>
4222
4223         * s-stoele.adb: Remove unnecessary qualification of To_Address for VMS.
4224
4225 2010-06-14  Vincent Celier  <celier@adacore.com>
4226
4227         * gnatcmd.adb (Check_Files): Do not invoke the tool with all the
4228         sources of the project if a switch -files= is used.
4229
4230 2010-06-14  Thomas Quinot  <quinot@adacore.com>
4231
4232         * exp_attr.adb: Minor reformatting.
4233
4234 2010-06-14  Gary Dismukes  <dismukes@adacore.com>
4235
4236         * gnat_ugn.texi: Minor typo fixes and wording changes.
4237
4238 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
4239
4240         * sem_ch4.adb (Analyze_One_Call): If the call has been rewritten from a
4241         prefixed form, do not re-analyze first actual, which may need an
4242         implicit dereference.
4243         * sem_ch6.adb (Analyze_Procedure_Call): If the call is given in
4244         prefixed notation, the analysis will rewrite the node, and possible
4245         errors appear in the rewritten name of the node.
4246         * sem_res.adb: If a call is ambiguous because its first parameter is
4247         an overloaded call, report list of candidates, to clarify ambiguity of
4248         enclosing call.
4249
4250 2010-06-14  Doug Rupp  <rupp@adacore.com>
4251
4252         * s-auxdec-vms-alpha.adb: New package body implementing legacy
4253         VAX instructions with Asm insertions.
4254         * s-auxdec-vms_64.ads: Inline VAX queue functions
4255         * s-stoele.adb: Resolve some ambiguities in To_Addresss with s-suxdec
4256         that show up only on VMS.
4257         * gcc-interface/Makefile.in: Provide translation for
4258         s-auxdec-vms-alpha.adb.
4259
4260 2010-06-14  Olivier Hainque  <hainque@adacore.com>
4261
4262         * initialize.c (VxWorks section): Update comments.
4263
4264 2010-06-14  Robert Dewar  <dewar@adacore.com>
4265
4266         * a-convec.adb, sem_prag.adb, checks.adb: Minor reformatting.
4267
4268 2010-06-14  Eric Botcazou  <ebotcazou@adacore.com>
4269
4270         * init.c: Code clean up.
4271
4272 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
4273
4274         * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case Address): Do
4275         not insert address clause in table for later validation if type of
4276         entity is generic, to prevent possible spurious errors. 
4277
4278         * sem_ch8.adb: Code clean up.
4279
4280 2010-06-14  Ben Brosgol  <brosgol@adacore.com>
4281
4282         * gnat_ugn.texi: Expanded @ovar macro inline to solve problem with
4283         texi2pdf and texi2html.
4284         Document how to change scheduling properties on HP-UX.
4285
4286 2010-06-14  Thomas Quinot  <quinot@adacore.com>
4287
4288         * g-socket.ads: Remove misleading comments.
4289
4290 2010-06-14  Jerome Lambourg  <lambourg@adacore.com>
4291
4292         * sem_prag.adb (Check_Duplicated_Export_Name): Remove check for
4293         CLI_Target as this prevents proper detection of exported names
4294         duplicates when the exported language is different to CIL.
4295         (Process_Interface_Name): Add check for CIL convention exports,
4296         replacing the old one from Check_Duplicated_Export_Name.
4297
4298 2010-06-14  Matthew Heaney  <heaney@adacore.com>
4299
4300         * a-coinve.adb, a-convec.adb (operator "&"): Check both that new length
4301         and new last satisfy constraints.
4302         (Delete_Last): prevent overflow for subtraction of index values
4303         (To_Vector): prevent overflow for addition of index values
4304
4305 2010-06-14  Ed Schonberg  <schonberg@adacore.com>
4306
4307         * sem_ch4.adb (Complete_Object_Operation): After analyzing the
4308         rewritten call, preserve the resulting type to prevent spurious errors,
4309         when the call is implicitly dereferenced in the context of an in-out
4310         actual.
4311
4312         * checks.adb (Apply_Discriminant_Check): If the target of the
4313         assignment is a renaming of a heap object, create constrained type for
4314         it to apply check.
4315
4316 2010-06-14  Pascal Obry  <obry@adacore.com>
4317
4318         * prj-proc.adb: Fix copy of object directory for extending projects.
4319
4320 2010-06-14  Jose Ruiz  <ruiz@adacore.com>
4321
4322         * init.c (__gnat_alternate_stack): Define this space for PowerPC linux
4323         (__gnat_install_handler, PowerPC linux): Activate the alternative
4324         signal stack.
4325
4326 2010-06-13  Gerald Pfeifer  <gerald@pfeifer.com>
4327
4328         * gnat_rm.texi: Move to GFDL version 1.3.
4329         * gnat-style.texi: Ditto.
4330         * gnat_ugn.texi: Ditto.
4331
4332 2010-06-12  Kai Tietz  <kai.tietz@onevision.com>
4333
4334         PR ada/43731
4335         * gcc-interface/Makefile.in: Add rules for multilib x86/x64
4336         mingw targets.
4337
4338 2010-06-11  Alexandre Oliva  <aoliva@redhat.com>
4339
4340         * gcc-interface/utils.c (update_pointer_to): Initialize last.
4341
4342 2010-06-09  Eric Botcazou  <ebotcazou@adacore.com>
4343
4344         * gcc-interface/ada-tree.h: Fix formatting nits.
4345
4346 2010-06-08  Laurynas Biveinis  <laurynas.biveinis@gmail.com>
4347
4348         * gcc-interface/utils.c (init_gnat_to_gnu): Use typed GC
4349         allocation.
4350         (init_dummy_type): Likewise.
4351         (gnat_pushlevel): Likewise.
4352
4353         * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
4354         (Subprogram_Body_to_gnu): Likewise.
4355         (Compilation_Unit_to_gnu): Likewise.
4356         (start_stmt_group): Likewise.
4357         (extract_encoding): Likewise.
4358         (decode_name): Likewise.
4359
4360         * gcc-interface/misc.c (gnat_printable_name): Likewise.
4361
4362         * gcc-interface/decl.c (annotate_value): Likewise.
4363
4364         * gcc-interface/ada-tree.h (struct lang_type): Add variable_size
4365         GTY option.
4366         (struct lang_decl): Likewise.
4367         (SET_TYPE_LANG_SPECIFIC): Use typed GC allocation.
4368         (SET_DECL_LANG_SPECIFIC): Likewise.
4369
4370 2010-06-04  Eric Botcazou  <ebotcazou@adacore.com>
4371
4372         * gnatlink.adb (gnatlink): Remove support for -fsjlj switch.
4373         * gcc-interface/lang-specs.h: Likewise.
4374
4375 2010-06-03  H.J. Lu  <hongjiu.lu@intel.com>
4376
4377         PR c++/44294
4378         * gcc-interface/decl.c (MAX_FIXED_MODE_SIZE): Removed.
4379
4380 2010-06-01  Arnaud Charlet  <charlet@adacore.com>
4381
4382         * gnat_ugn.texi: Improve doc on -fdump-ada-spec, mention limitations.
4383
4384 2010-05-30  Eric Botcazou  <ebotcazou@adacore.com>
4385
4386         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Task_Type>: Reuse the
4387         TYPE_DECL of the equivalent type instead of building a new one.
4388
4389 2010-05-30  Eric Botcazou  <ebotcazou@adacore.com>
4390
4391         * gcc-interface/decl.c (gnat_to_gnu_entity): Adjust warning message.
4392         Fix nits in comments.
4393         * gcc-interface/misc.c (gnat_init_gcc_eh): Likewise.
4394         * gcc-interface/trans.c (gigi): Likewise.
4395         (Attribute_to_gnu): Likewise.
4396         (Case_Statement_to_gnu): Likewise.
4397         (gnat_to_gnu): Adjust warning message.
4398         * gcc-interface/utils.c (create_var_decl_1): Fix nits in comments.
4399         (build_vms_descriptor32): Likewise.
4400
4401 2010-05-27  Steven Bosscher  <steven@gcc.gnu.org>
4402
4403         * gcc-interface/decl.c: Pretend to be a backend file by undefining
4404         IN_GCC_FRONTEND (still need rtl.h here).
4405
4406 2010-05-26  Steven Bosscher  <steven@gcc.gnu.org>
4407
4408         * gcc-interface/trans.c: Do not include rtl.h, insclude libfuncs.h.
4409         (gigi): Adjust call to set_stack_check_libfunc.
4410
4411 2010-05-26  Steven Bosscher  <steven@gcc.gnu.org>
4412
4413         * gcc-interface/utils.c: Do not include rtl.h.
4414
4415 2010-05-25  Steven Bosscher  <steven@gcc.gnu.org>
4416
4417         * gcc-interface/utils.c: Do not include function.h, pointer-set.h,
4418         and gimple.h.  Explain why rtl.h has to be included.
4419         (handle_vector_size_attribute): Call reconstruct_complex_type directly.
4420         * gcc-interface/targtyps.c: Do not include tm_p.h
4421         * gcc-interface/utils2.c: Do not include flags.h.
4422         * gcc-interface/trans.c: Do not include expr.h.  Include rtl.h instead,
4423         and explain why it has to be included.
4424         * gcc-interface/misc.c: Do not include expr.h, libfuncs.h, cgraph.h,
4425         and optabs.h.
4426         Include function.h and explain why.  Explain why except.h is included.
4427         (enumerate_modes): Remove unused function. 
4428         * gcc-interface/gigi.h (enumerate_modes): Remove prototype.
4429         * gcc-interface/Make-lang.in: Update dependencies.
4430
4431 2010-05-25  Joseph Myers  <joseph@codesourcery.com>
4432
4433         * gcc-interface/misc.c (internal_error_function): Add context
4434         parameter.  Use it to access show_column flag and instead of using
4435         global_dc.  Call warn_if_plugins.
4436         * gcc-interface/Make-lang.in (ada/misc.o): Update dependencies.
4437
4438 2010-05-19  Eric Botcazou  <ebotcazou@adacore.com>
4439
4440         * gcc-interface/misc.c (LANG_HOOKS_DEEP_UNSHARING): Redefine.
4441         * gcc-interface/trans.c (unshare_save_expr): Delete.
4442         (gigi): Do not unshare trees under SAVE_EXPRs here.
4443
4444 2010-05-18  Nathan Froyd  <froydnj@codesourcery.com>
4445
4446         * gcc-interface/trans.c (call_to_gnu): Use build_call_vec instead of
4447         build_call_list.
4448         * gcc-interface/utils.c (build_function_stub): Likewise.
4449
4450 2010-05-16  Manuel López-Ibáñez  <manu@gcc.gnu.org>
4451
4452         * gcc-interface/misc.c (gnat_handle_option): Remove special logic
4453         for Wuninitialized without -O.
4454         
4455 2010-05-16  Eric Botcazou  <ebotcazou@adacore.com>
4456
4457         * gcc-interface/gigi.h (enum standard_datatypes): Add new value
4458         ADT_exception_data_name_id.
4459         (exception_data_name_id): New define.
4460         * gcc-interface/trans.c (gigi): Initialize it.
4461         * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Use the standard
4462         exception type for standard exception definitions.  Do not make them
4463         volatile.
4464         <E_Record_Type>: Equate fields of types associated with an exception
4465         definition to those of the standard exception type.
4466
4467 2010-05-13  Andreas Schwab  <schwab@linux-m68k.org>
4468
4469         * tracebak.c (__gnat_backtrace): Mark top_stack with ATTRIBUTE_UNUSED.
4470
4471 2010-05-12  Eric Botcazou  <ebotcazou@adacore.com>
4472
4473         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Tidy up
4474         code, improve comments and fix formatting nits.
4475
4476 2010-05-12  Eric Botcazou  <ebotcazou@adacore.com>
4477
4478         * gcc-interface/utils.c (update_pointer_to): Return early if the old
4479         pointer already points to the new type.  Chain the old pointer and its
4480         variants at the end of new pointer's chain after updating them.
4481
4482 2010-05-10  Eric Botcazou  <ebotcazou@adacore.com>
4483
4484         * exp_disp.adb (Make_Tags): Mark the imported view of dispatch tables
4485         built for interfaces.
4486         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Variable>: Use
4487         imported_p instead of Is_Imported when considering constants.
4488         Do not promote alignment of exported objects.
4489         <E_Record_Subtype>: Strip all suffixes for dispatch table entities.
4490
4491 2010-05-08  Eric Botcazou  <ebotcazou@adacore.com>
4492
4493         * exp_disp.adb (Make_Tags): Mark the imported view of dispatch tables.
4494         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Variable>: Make imported
4495         constants really constant.
4496         <E_Record_Subtype>: Strip the suffix for dispatch table entities.
4497
4498 2010-05-08  Eric Botcazou  <ebotcazou@adacore.com>
4499
4500         * gcc-interface/decl.c (make_aligning_type): Declare the type.
4501
4502 2010-05-08  Eric Botcazou  <ebotcazou@adacore.com>
4503
4504         * gcc-interface/decl.c (gnat_to_gnu_entity): Create variables for size
4505         expressions of variant part of record types declared at library level.
4506
4507 2010-05-08  Eric Botcazou  <ebotcazou@adacore.com>
4508
4509         * gcc-interface/gigi.h (create_field_decl): Move PACKED parameter.
4510         * gcc-interface/utils.c (create_field_decl): Move PACKED parameter.
4511         (rest_of_record_type_compilation): Adjust call to create_field_decl.
4512         (make_descriptor_field): Likewise and pass correctly typed constants.
4513         (build_unc_object_type): Likewise.
4514         (unchecked_convert): Likewise.
4515         * gcc-interface/decl.c (elaborate_expression_2): New static function.
4516         (gnat_to_gnu_entity): Use it to make alignment factors explicit.
4517         Adjust call to create_field_decl.
4518         (make_aligning_type): Likewise.
4519         (make_packable_type): Likewise.
4520         (maybe_pad_type): Likewise.
4521         (gnat_to_gnu_field): Likewise.
4522         (components_to_record): Likewise.
4523         (create_field_decl_from): Likewise.
4524         (create_variant_part_from): Remove superfluous test.
4525         * gcc-interface/trans.c (gigi): Adjust call to create_field_decl.
4526
4527 2010-05-08  Eric Botcazou  <ebotcazou@adacore.com>
4528
4529         * gcc-interface/gigi.h (build_unc_object_type): Add DEBUG_INFO_P param.
4530         (build_unc_object_type_from_ptr): Likewise.
4531         * gcc-interface/utils.c (build_unc_object_type): Add DEBUG_INFO_P param
4532         and pass it to create_type_decl.  Declare the type.  Simplify.
4533         (build_unc_object_type_from_ptr): Add DEBUG_INFO_P parameter and pass
4534         it to build_unc_object_type.
4535         * gcc-interface/decl.c (gnat_to_gnu_entity): Adjust to above change.
4536         * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
4537         (gnat_to_gnu): Likewise.
4538         * gcc-interface/utils2.c (build_allocator): Likewise.
4539
4540 2010-05-07  Eric Botcazou  <ebotcazou@adacore.com>
4541
4542         PR 40989
4543         * gcc-interface/misc.c (gnat_handle_option): Fix long line.
4544
4545 2010-05-06  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
4546
4547         * gcc-interface/Makefile.in: Removed mips-sgi-irix5* support.
4548
4549 2010-05-06  Manuel López-Ibáñez  <manu@gcc.gnu.org>
4550
4551         PR 40989
4552         * gcc-interface/misc.c (gnat_handle_option): Add argument kind.
4553
4554 2010-05-02  Giuseppe Scrivano  <gscrivano@gnu.org>
4555
4556         * gnathtml.pl: Use 755 as mask for new directories.
4557
4558 2010-04-28  Eric Botcazou  <ebotcazou@adacore.com>
4559
4560         * gcc-interface/trans.c (gnat_gimplify_expr) <ADDR_EXPR>: Uniquize
4561         constant constructors before taking their address.
4562
4563 2010-04-25  Eric Botcazou  <ebotcazou@adacore.com>
4564
4565         * exp_dbug.ads: Fix outdated description.  Mention link between XVS
4566         and XVZ objects.
4567         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Subtype>: Set
4568         XVZ variable as unit size of XVS type.
4569         (maybe_pad_type): Likewise.
4570
4571 2010-04-25  Eric Botcazou  <ebotcazou@adacore.com>
4572
4573         * gcc-interface/trans.c (gnat_to_gnu) <N_Assignment_Statement>: Do not
4574         use memmove if the array type is bit-packed.
4575
4576 2010-04-18  Eric Botcazou  <ebotcazou@adacore.com>
4577
4578         * gcc-interface/misc.c (gnat_init): Remove second argument in call to
4579         build_common_tree_nodes.
4580
4581 2010-04-18  Ozkan Sezer  <sezeroz@gmail.com>
4582
4583         * gsocket.h: Make sure that winsock2.h is included before windows.h.
4584
4585 2010-04-17  Eric Botcazou  <ebotcazou@adacore.com>
4586
4587         * gcc-interface/utils2.c (build_unary_op) <ATTR_ADDR_EXPR>: Do not
4588         issue warning.
4589
4590 2010-04-17  Eric Botcazou  <ebotcazou@adacore.com>
4591
4592         * uintp.h (UI_Lt): Declare.
4593         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do the size
4594         computation in sizetype.
4595         <E_Array_Subtype>: Use unified handling for all index types.  Do not
4596         generate MAX_EXPR-based expressions, only COND_EXPR-based ones.  Add
4597         bypass for PATs.
4598         (annotate_value): Change test for negative values.
4599         (validate_size): Apply test for negative values on GNAT nodes.
4600         (set_rm_size): Likewise.
4601         * gcc-interface/misc.c (gnat_init): Set unsigned types for sizetypes.
4602         * gcc-interface/utils.c (rest_of_record_type_compilation): Change test
4603         for negative values.
4604         (max_size) <MINUS_EXPR>: Do not reassociate a COND_EXPR on the LHS.
4605         (builtin_type_for_size): Adjust definition of signed_size_type_node.
4606         * gcc-interface/utils2.c (compare_arrays): Optimize comparison of
4607         lengths against zero.
4608
4609 2010-04-17  Eric Botcazou  <ebotcazou@adacore.com>
4610
4611         * back-end.adb (Call_Back_End): Pass Standard_Character to gigi.
4612         * gcc-interface/gigi.h (gigi): Add standard_character parameter.
4613         (CHAR_TYPE_SIZE, SHORT_TYPE_SIZE, INT_TYPE_SIZE, LONG_TYPE_SIZE, 
4614         LONG_LONG_TYPE_SIZE, FLOAT_TYPE_SIZE, DOUBLE_TYPE_SIZE,
4615         LONG_DOUBLE_TYPE_SIZE, SIZE_TYPE): Delete.
4616         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Subtype>: Call
4617         rm_size.
4618         * gcc-interface/misc.c (gnat_init): Set signedness of char as per
4619         flag_signed_char.  Tag sizetype with "size_type" moniker.
4620         * gcc-interface/trans.c (gigi): Add standard_character parameter.
4621         Remove useless built-in types.  Equate unsigned_char_type_node to
4622         Standard.Character.  Use it instead of char_type_node throughout.
4623         (Attribute_to_gnu): Likewise.
4624         (gnat_to_gnu): Likewise.
4625         * gcc-interface/utils2.c (build_call_raise): Likewise.
4626
4627 2010-04-17  Eric Botcazou  <ebotcazou@adacore.com>
4628
4629         * gcc-interface/gigi.h (enum standard_datatypes): Add new values
4630         ADT_sbitsize_one_node and ADT_sbitsize_unit_node.
4631         (sbitsize_one_node): New macro.
4632         (sbitsize_unit_node): Likewise.
4633         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Subtype>: Fix
4634         latent bug in the computation of subrange_p.  Fold wider_p predicate.
4635         (cannot_be_superflat_p): Use an explicitly signed 64-bit type to do
4636         the final comparison.
4637         (make_aligning_type): Build real negation and use sizetype throughout
4638         the offset computation.
4639         (maybe_pad_type): Do not issue the warning when the new size expression
4640         is too complex.
4641         (annotate_value) <INTEGER_CST>: Simplify code handling negative values.
4642         * gcc-interface/misc.c (gnat_init): Initialize sbitsize_one_node and
4643         sbitsize_unit_node.
4644         * gcc-interface/trans.c (Attribute_to_gnu) <Attr_Pool_Address>: Fold
4645         double negation.
4646         (gnat_to_gnu) <N_Free_Statement>: Likewise.
4647         * gcc-interface/utils.c (convert): Use sbitsize_unit_node.
4648         * gcc-interface/utils2.c (compare_arrays): Compute real lengths and use
4649         constants in sizetype.  Remove dead code and tweak comments.  Generate
4650         equality instead of inequality comparisons for zero length tests.
4651
4652 2010-04-16  Eric Botcazou  <ebotcazou@adacore.com>
4653
4654         * gcc-interface/gigi.h (gnat_init_decl_processing): Delete.
4655         * gcc-interface/decl.c (gnat_to_gnu_entity): Constify a few variables.
4656         <object>: Do not create the fake PARM_DECL if no debug info is needed.
4657         Do not create the corresponding VAR_DECL of a CONST_DECL for debugging
4658         purposes if no debug info is needed.
4659         Fix formatting.  Reorder and add comments.
4660         * gcc-interface/trans.c (gnat_to_gnu) <N_Attribute_Reference>: Constify
4661         variable and remove obsolete comment.
4662         * gcc-interface/utils.c (convert_vms_descriptor64): Tweak comment.
4663         (convert_vms_descriptor32): Likewise.
4664         (convert): Remove dead code.
4665         <UNCONSTRAINED_ARRAY_REF>: Pass the field instead of its name to build
4666         the reference to the P_ARRAY pointer.
4667         <POINTER_TYPE>: Likewise.
4668         (maybe_unconstrained_array) <UNCONSTRAINED_ARRAY_TYPE>: Likewise.
4669         (gnat_init_decl_processing): Delete, move contents to...
4670         * gcc-interface/misc.c (gnat_init): ...here.
4671
4672 2010-04-16  Eric Botcazou  <ebotcazou@adacore.com>
4673
4674         * gcc-interface/trans.c (unchecked_conversion_nop): Handle function
4675         calls.  Return true for conversion from a record subtype to its type.
4676
4677 2010-04-16  Eric Botcazou  <ebotcazou@adacore.com>
4678
4679         * gcc-interface/decl.c (gnat_to_gnu_entity): Use boolean_type_node in
4680         lieu of integer_type_node for boolean operations.
4681         (choices_to_gnu): Likewise.
4682         * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
4683         (Loop_Statement_to_gnu): Likewise.
4684         (establish_gnat_vms_condition_handler): Likewise.
4685         (Exception_Handler_to_gnu_sjlj): Likewise.
4686         (gnat_to_gnu): Likewise.
4687         (build_unary_op_trapv): Likewise.
4688         (build_binary_op_trapv): Likewise.
4689         (emit_range_check): Likewise.
4690         (emit_index_check): Likewise.
4691         (convert_with_check): Likewise.
4692         * gcc-interface/utils.c (convert_vms_descriptor64): Likewise.
4693         (convert_vms_descriptor32): Likewise.
4694         (convert_vms_descriptor): Likewise.
4695         * gcc-interface/utils2.c (nonbinary_modular_operation): Likewise.
4696         (compare_arrays): Use boolean instead of integer constants.
4697         (build_binary_op) <TRUTH_ANDIF_EXPR, TRUTH_ORIF_EXPR, TRUTH_AND_EXPR,
4698         TRUTH_OR_EXPR, TRUTH_XOR_EXPR>: New case.  Check that the result type
4699         is a boolean type.
4700         <GE_EXPR, LE_EXPR, GT_EXPR, LT_EXPR>: Remove obsolete assertion.
4701         <EQ_EXPR, NE_EXPR>: Check that the result type is a boolean type.
4702         <PREINC/PREDECREMENT_EXPR, POSTINC/POSTDECREMENT_EXPR>: Delete.
4703         <TRUTH_NOT_EXPR>: Check that the result type is a boolean type.
4704         (build_unary_op): Use boolean_type_node in lieu of integer_type_node
4705         for boolean operations.
4706         (fill_vms_descriptor): Likewise.  Fix formatting nits.
4707
4708 2010-04-16  Eric Botcazou  <ebotcazou@adacore.com>
4709
4710         * gcc-interface/ada-tree.def (LOOP_STMT): Change to 4-operand nodes.
4711         * gcc-interface/ada-tree.h (LOOP_STMT_TOP_COND, LOOP_STMT_BOT_COND):
4712         Merge into...
4713         (LOOP_STMT_COND): ...this.
4714         (LOOP_STMT_BOTTOM_COND_P): New flag.
4715         (LOOP_STMT_TOP_UPDATE_P): Likewise.
4716         * gcc-interface/trans.c (can_equal_min_or_max_val_p): New function.
4717         (can_equal_min_val_p): New static inline function.
4718         (can_equal_max_val_p): Likewise.
4719         (Loop_Statement_to_gnu): Use build4 in lieu of build5 and adjust to
4720         new LOOP_STMT semantics.  Use two different strategies depending on
4721         whether optimization is enabled to translate the loop.
4722         (gnat_gimplify_stmt) <LOOP_STMT>: Adjust to new LOOP_STMT semantics.
4723
4724 2010-04-16  Eric Botcazou  <ebotcazou@adacore.com>
4725
4726         * uintp.adb (UI_From_Dint): Remove useless code.
4727         (UI_From_Int): Likewise.
4728         * uintp.h: Reorder declarations.
4729         (UI_From_gnu): Declare.
4730         (UI_Base): Likewise.
4731         (Vector_Template): Likewise.
4732         (Vector_To_Uint): Likewise.
4733         (Uint_0): Remove.
4734         (Uint_1): Likewise.
4735         * gcc-interface/gigi.h: Tweak comments.
4736         * gcc-interface/cuintp.c (UI_From_gnu): New global function.
4737         * gcc-interface/decl.c (maybe_pad_type): Do not warn if either size
4738         overflows.
4739         (annotate_value) <INTEGER_CST>: Call UI_From_gnu.
4740         * gcc-interface/trans.c (post_error_ne_num): Call post_error_ne.
4741         (post_error_ne_tree): Call UI_From_gnu and post_error_ne.
4742         * gcc-interface/utils.c (max_size) <tcc_binary>: Do not special-case
4743         TYPE_MAX_VALUE.
4744
4745 2010-04-16  Eric Botcazou  <ebotcazou@adacore.com>
4746
4747         * gcc-interface/decl.c (make_type_from_size) <INTEGER_TYPE>: Just copy
4748         TYPE_NAME.
4749         * gcc-interface/trans.c (smaller_packable_type_p): Rename into...
4750         (smaller_form_type_p): ...this.  Change parameter and variable names.
4751         (call_to_gnu): Use the nominal type of the parameter to create the
4752         temporary if it's a smaller form of the actual type.
4753         (addressable_p): Return false if the actual type is integral and its
4754         size is greater than that of the expected type.
4755
4756 2010-04-15  Eric Botcazou  <ebotcazou@adacore.com>
4757
4758         * gcc-interface/cuintp.c (UI_To_gnu): Fix long line.
4759         * gcc-interface/gigi.h (MARK_VISITED): Skip objects of constant class.
4760         (process_attributes): Delete.
4761         (post_error_ne_num): Change parameter name.
4762         * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force debug info
4763         with -g3.  Remove a couple of obsolete lines.  Minor tweaks.
4764         If type annotating mode, operate on trees to compute the adjustment to
4765         the sizes of tagged types.  Fix long line.
4766         (cannot_be_superflat_p): Tweak head comment.
4767         (annotate_value): Fold local constant.
4768         (set_rm_size): Fix long line.
4769         * gcc-interface/trans.c (Identifier_to_gnu): Rework comments.
4770         (Attribute_to_gnu): Fix long line.
4771         <Attr_Size>: Remove useless assertion.
4772         Reorder statements.  Use size_binop routine.
4773         (Loop_Statement_to_gnu): Use build5 in lieu of build_nt.
4774         Create local variables for the label and the test.  Tweak comments.
4775         (Subprogram_Body_to_gnu): Reset cfun to NULL.
4776         (Compilation_Unit_to_gnu): Use the Sloc of the Unit node.
4777         (process_inlined_subprograms): Integrate into...
4778         (Compilation_Unit_to_gnu): ...this.
4779         (gnat_to_gnu): Fix long line.
4780         (post_error_ne_num): Change parameter name.
4781         * gcc-interface/utils.c (process_attributes): Static-ify.
4782         <ATTR_MACHINE_ATTRIBUTE>: Set input_location before proceeding.
4783         (create_type_decl): Add comment.
4784         (create_var_decl_1): Process the attributes after adding the VAR_DECL
4785         to the current binding level.
4786         (create_subprog_decl): Likewise for the FUNCTION_DECL.
4787         (end_subprog_body): Do not reset cfun to NULL.
4788         (build_vms_descriptor32): Fix long line.
4789         (build_vms_descriptor): Likewise.
4790         (handle_nonnull_attribute): Likewise.
4791         (convert_vms_descriptor64): Likewise.
4792         * gcc-interface/utils2.c (fill_vms_descriptor): Fix long line.
4793         (gnat_protect_expr): Fix thinko.
4794
4795 2010-04-15  Eric Botcazou  <ebotcazou@adacore.com>
4796
4797         * gcc-interface/trans.c (gigi): Set DECL_IGNORED_P on EH functions.
4798         (gnat_to_gnu) <N_Op_Eq>: Restore the value of input_location
4799         before translating the top-level node.
4800         (lvalue_required_p) <N_Function_Call>: Return 1 if !constant.
4801         <N_Object_Declaration>: Likewise.
4802         <N_Assignment_Statement>: Likewise.
4803         <N_Unchecked_Type_Conversion>: Likewise.
4804         (call_to_gnu): Remove kludge.
4805         (gnat_to_gnu) <N_Return_Statement>: When not optimizing, force labels
4806         associated with user returns to be preserved.
4807         (gnat_to_gnu): Add special code to deal with boolean rvalues.
4808         * gcc-interface/utils2.c (compare_arrays): Set input_location on all
4809         comparisons.
4810         (build_unary_op) <ADDR_EXPR>: Call build_fold_addr_expr.
4811         <INDIRECT_REF>: Call build_fold_indirect_ref.
4812
4813 2010-04-15  Joel Sherrill  <joel.sherrill@oarcorp.com>
4814
4815         * g-socket.adb: A target can have multiple missing errno's.  This
4816         will result in multiple errno's being defined as -1.  Because of this
4817         we can not use a case but must use a series of if's to avoid 
4818         a duplicate case error in GNAT.Sockets.Resolve_Error.
4819
4820 2010-04-15  Eric Botcazou  <ebotcazou@adacore.com>
4821
4822         * gcc-interface/trans.c (call_to_gnu): Open a nesting level if this is
4823         a statement.  Otherwise, if at top-level, push the processing of the
4824         elaboration routine.  In the misaligned case, issue the error messages
4825         again on entry and create the temporary explicitly.  Do not issue them
4826         for CONSTRUCTORs.
4827         For a function call, emit the range check if necessary.
4828         In the copy-in copy-out case, create the temporary for the return
4829         value explicitly.
4830         Do not unnecessarily convert by-ref parameters to the formal's type.
4831         Remove obsolete guards in conditions.
4832         (gnat_to_gnu) <N_Assignment_Statement>: For a function call, pass the
4833         target to call_to_gnu in all cases.
4834         (gnat_gimplify_expr) <ADDR_EXPR>: Remove handling of SAVE_EXPR.
4835         (addressable_p) <CONSTRUCTOR>: Return false if not static.
4836         <COMPOUND_EXPR>: New case.
4837         * gcc-interface/utils2.c (build_unary_op) <ADDR_EXPR>: Fold a compound
4838         expression if it has unconstrained array type.
4839         (gnat_mark_addressable) <COMPOUND_EXPR>: New case.
4840         (gnat_stabilize_reference) <COMPOUND_EXPR>: Stabilize operands on an
4841         individual basis.
4842
4843 2010-04-15  Eric Botcazou  <ebotcazou@adacore.com>
4844
4845         * gcc-interface/trans.c (gigi): Do not start statement group.
4846         (Compilation_Unit_to_gnu): Set current_function_decl to NULL.
4847         Start statement group and push binding level here...
4848         (gnat_to_gnu) <N_Compilation_Unit>: ...and not here.
4849         Do not push fake contexts at top level.  Remove redundant code.
4850         (call_to_gnu): Rename a local variable and constify another.
4851         * gcc-interface/utils.c (gnat_pushlevel): Fix formatting nits.
4852         (set_current_block_context): Set it as the group's block.
4853         (gnat_init_decl_processing): Delete unrelated init code.
4854         (end_subprog_body): Use NULL_TREE.
4855
4856 2010-04-15  Eric Botcazou  <ebotcazou@adacore.com>
4857
4858         * gcc-interface/trans.c (call_to_gnu): Do not unnecessarily force
4859         side-effects of actual parameters before the call.
4860
4861 2010-04-15  Eric Botcazou  <ebotcazou@adacore.com>
4862
4863         * gcc-interface/decl.c (validate_size): Reorder, remove obsolete test
4864         and warning.
4865         (set_rm_size): Reorder and remove obsolete test.
4866
4867 2010-04-14  Eric Botcazou  <ebotcazou@adacore.com>
4868
4869         * gcc-interface/gigi.h: Reorder declarations and tweak comments.
4870         (gigi): Adjust ATTRIBUTE_UNUSED markers.
4871         * gcc-interface/gadaint.h: New file.
4872         * gcc-interface/trans.c: Include it in lieu of adaint.h.  Reorder.
4873         (__gnat_to_canonical_file_spec): Remove declaration.
4874         (number_names): Delete.
4875         (number_files): Likewise.
4876         (gigi): Adjust.
4877         * gcc-interface/Make-lang.in (ada/trans.o): Adjust dependencies to
4878         above change.
4879
4880 2010-04-14  Eric Botcazou  <ebotcazou@adacore.com>
4881
4882         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Class_Wide_Type>: Fix
4883         comment.
4884         * gcc-interface/trans.c (process_freeze_entity): Use local copy of
4885         Ekind.  Return early for class-wide types.  Do not compute initializer
4886         unless necessary.  Reuse the tree for an associated class-wide type
4887         only if processing its root type.
4888
4889 2010-04-13  Joel Sherrill  <joel.sherrill@oarcorp.com>
4890
4891         * gsocket.h: Run-time can no longer be built without network
4892         OS headers available.  Changing RTEMS GNAT build procedure to
4893         reflect this and letting run-time build use network .h files.
4894
4895 2010-04-13  Duncan Sands  <baldrick@free.fr>
4896
4897         * gcc-interface/misc.c (gnat_eh_type_covers): Remove.
4898         * gcc-interface/trans.c (Exception_Handler_to_gnu_zcx): Update comment.
4899
4900 2010-04-13  Eric Botcazou  <ebotcazou@adacore.com>
4901
4902         * gcc-interface/gigi.h (standard_datatypes): Add ADT_parent_name_id.
4903         (parent_name_id): New macro.
4904         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Type>: Use it.
4905         * gcc-interface/trans.c (gigi): Initialize it.
4906         (lvalue_required_p) <N_Type_Conversion>: New case.
4907         <N_Qualified_Expression>: Likewise.
4908         <N_Allocator>: Likewise.
4909         * gcc-interface/utils.c (convert): Try to properly upcast tagged types.
4910
4911 2010-04-13  Eric Botcazou  <ebotcazou@adacore.com>
4912
4913         * gcc-interface/ada-tree.h (TYPE_BY_REFERENCE_P): Delete.
4914         (DECL_CONST_ADDRESS_P): New macro.
4915         (SET_DECL_ORIGINAL_FIELD_TO_FIELD): Likewise.
4916         (SAME_FIELD_P): Likewise.
4917         * gcc-interface/decl.c (constructor_address_p): New static function.
4918         (gnat_to_gnu_entity) <object>: Set DECL_CONST_ADDRESS_P according to
4919         the return value of above function.
4920         (gnat_to_gnu_entity) <E_Record_Type>: Force BLKmode for all types
4921         passed by reference.
4922         <E_Record_Subtype>: Likewise.
4923         Set TREE_ADDRESSABLE on the type if it passed by reference.
4924         (make_packable_type): Use SET_DECL_ORIGINAL_FIELD_TO_FIELD.
4925         (create_field_decl_from): Likewise.
4926         (substitute_in_type): Likewise.
4927         (purpose_member_field): Use SAME_FIELD_P.
4928         * gcc-interface/misc.c (must_pass_by_ref): Test TREE_ADDRESSABLE.
4929         * gcc-interface/trans.c (lvalue_required_p): Add ADDRESS_OF_CONSTANT
4930         parameter and adjust recursive calls.
4931         <N_Explicit_Dereference>: New case.
4932         <N_Object_Declaration>: Return 1 if the object is of a class-wide type.
4933         Adjust calls to lvalue_required_p.  Do not return the initializer of a
4934         DECL_CONST_ADDRESS_P constant if an lvalue is required for it.
4935         (call_to_gnu): Delay issuing error message for a misaligned actual and
4936         avoid the associated back-end assertion.  Test TREE_ADDRESSABLE.
4937         (gnat_gimplify_expr) <ADDR_EXPR>: Handle non-static constructors.
4938         * gcc-interface/utils.c (make_dummy_type): Set TREE_ADDRESSABLE if the
4939         type is passed by reference.
4940         (convert) <CONSTRUCTOR>: Convert in-place in more cases.
4941         * gcc-interface/utils2.c (build_cond_expr): Drop TYPE_BY_REFERENCE_P.
4942         (build_simple_component_ref): Use SAME_FIELD_P.
4943
4944 2010-04-12  Eric Botcazou  <ebotcazou@adacore.com>
4945
4946         * gcc-interface/trans.c (Identifier_to_gnu): Use boolean variable.
4947         (call_to_gnu): Test gigi's flag TYPE_BY_REFERENCE_P instead of calling
4948         front-end's predicate Is_By_Reference_Type.  Use consistent order and
4949         remove ??? comment.  Use original conversion in all cases, if any.
4950         * gcc-interface/utils.c (make_dummy_type): Minor tweak.
4951         (convert): Use local copy in more cases.
4952         <INDIRECT_REF>: Remove deactivated code.
4953         (unchecked_convert): Use a couple of local copies.
4954
4955 2010-04-11  Eric Botcazou  <ebotcazou@adacore.com>
4956
4957         * gcc-interface/trans.c (lvalue_required_for_attribute_p): New static
4958         function.
4959         (lvalue_required_p) <N_Attribute_Reference>: Call it.
4960         (gnat_to_gnu) <N_Selected_Component>: Prevent build_component_ref from
4961         folding the result only if lvalue_required_for_attribute_p is true.
4962         * gcc-interface/utils.c (maybe_unconstrained_array): Pass correctly
4963         typed constant to build_component_ref.
4964         (unchecked_convert): Likewise.
4965         * gcc-interface/utils2.c (maybe_wrap_malloc): Likewise.
4966         (build_allocator): Likewise.
4967
4968 2010-04-11  Eric Botcazou  <ebotcazou@adacore.com>
4969
4970         * gcc-interface/utils2.c (build_cond_expr): Take the address and
4971         dereference if the result type is passed by reference.
4972
4973 2010-04-11  Eric Botcazou  <ebotcazou@adacore.com>
4974
4975         * gcc-interface/trans.c (Case_Statement_to_gnu): Bool-ify variable.
4976         (gnat_to_gnu) <N_Null_Statement>: When not optimizing, generate a
4977         goto to the next statement.
4978
4979 2010-04-09  Eric Botcazou  <ebotcazou@adacore.com>
4980
4981         * gcc-interface/gigi.h (maybe_variable): Delete.
4982         (protect_multiple_eval): Likewise.
4983         (maybe_stabilize_reference): Likewise.
4984         (gnat_save_expr): Declare.
4985         (gnat_protect_expr): Likewise.
4986         (gnat_stabilize_reference): Likewise.
4987         * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Use
4988         gnat_stabilize_reference.
4989         (maybe_variable): Delete.
4990         (elaborate_expression_1): Use gnat_save_expr.
4991         * gcc-interface/trans.c (Attribute_to_gnu): Use gnat_protect_expr.
4992         (call_to_gnu): Pass NULL to gnat_stabilize_reference.
4993         (gnat_to_gnu) <N_Object_Declaration>: Use gnat_save_expr.
4994         <N_Slice>: Use gnat_protect_exp.
4995         <N_Selected_Component>: Pass NULL to gnat_stabilize_reference.
4996         <N_In>: Use gnat_protect_expr.
4997         Pass NULL to gnat_stabilize_reference.
4998         (build_unary_op_trapv): Use gnat_protect_expr.
4999         (build_binary_op_trapv): Likewise.
5000         (emit_range_check): Likewise.
5001         (emit_index_check): Likewise.
5002         (convert_with_check): Likewise.
5003         (protect_multiple_eval): Move to utils2.c file.
5004         (maybe_stabilize_reference): Merge into...
5005         (gnat_stabilize_reference): ...this.  Move to utils2.c file.
5006         (gnat_stabilize_reference_1): Likewise.
5007         * gcc-interface/utils.c (convert_to_fat_pointer): Use gnat_protect_expr
5008         instead of protect_multiple_eval.
5009         * gcc-interface/utils2.c (compare_arrays): Likewise.
5010         (nonbinary_modular_operation): Likewise.
5011         (maybe_wrap_malloc): Likewise.
5012         (build_allocator): Likewise.
5013         (gnat_save_expr): New function.
5014         (gnat_protect_expr): Rename from protect_multiple_eval.  Early return
5015         in common cases.  Propagate TREE_READONLY onto dereferences.
5016         (gnat_stabilize_reference_1): Move from trans.c file.
5017         (gnat_stabilize_reference): Likewise.
5018
5019 2010-04-09  Eric Botcazou  <ebotcazou@adacore.com>
5020
5021         * gcc-interface/gigi.h (gnat_mark_addressable): Rename parameter.
5022         * gcc-interface/decl.c (maybe_variable): Do not set TREE_STATIC on _REF
5023         node.  Use the type of the operand to set TREE_READONLY.
5024         * gcc-interface/trans.c (Identifier_to_gnu): Do not set TREE_STATIC on
5025         _REF node.  Do not overwrite TREE_READONLY.
5026         (call_to_gnu): Rename local variable and fix various nits.  In the
5027         copy-in/copy-out case, build the SAVE_EXPR manually.
5028         (convert_with_check): Call protect_multiple_eval in lieu of save_expr
5029         and fold the computations.
5030         (protect_multiple_eval): Always save entire fat pointers.
5031         (maybe_stabilize_reference): Minor tweaks.
5032         (gnat_stabilize_reference_1): Likewise.  Do not deal with tcc_constant,
5033         tcc_type and tcc_statement.
5034         * gcc-interface/utils.c (convert_to_fat_pointer): Call
5035         protect_multiple_eval in lieu of save_expr.
5036         (convert): Minor tweaks.
5037         (maybe_unconstrained_array): Do not set TREE_STATIC on _REF node.
5038         (builtin_type_for_size): Call gnat_type_for_size directly.
5039         * gcc-interface/utils2.c (contains_save_expr_p): Delete.
5040         (contains_null_expr): Likewise
5041         (gnat_build_constructor): Do not call it.
5042         (compare_arrays): Deal with all side-effects, use protect_multiple_eval
5043         instead of gnat_stabilize_reference to protect the operands.
5044         (nonbinary_modular_operation): Call protect_multiple_eval in lieu of
5045         save_expr.
5046         (maybe_wrap_malloc): Likewise.
5047         (build_allocator): Likewise.
5048         (build_unary_op) <INDIRECT_REF>: Do not set TREE_STATIC on _REF node.
5049         (gnat_mark_addressable): Rename parameter.
5050
5051 2010-04-08  Eric Botcazou  <ebotcazou@adacore.com>
5052
5053         * gcc-interface/ada-tree.h (TYPE_RETURNS_UNCONSTRAINED_P): Rename into.
5054         (TYPE_RETURN_UNCONSTRAINED_P): ...this.
5055         (TYPE_RETURNS_BY_REF_P): Rename into.
5056         (TYPE_RETURN_BY_DIRECT_REF_P): ...this.
5057         (TYPE_RETURNS_BY_TARGET_PTR_P): Delete.
5058         * gcc-interface/gigi.h (create_subprog_type): Adjust parameter names.
5059         (build_return_expr): Likewise.
5060         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>:
5061         Rename local variables.  If the return Mechanism is By_Reference, pass
5062         return_by_invisible_ref_p to create_subprog_type instead of toggling
5063         TREE_ADDRESSABLE.  Test return_by_invisible_ref_p in order to annotate
5064         the mechanism.  Use regular return for contrained types with non-static
5065         size and return by invisible reference for unconstrained return types
5066         with default discriminants.  Update comment.
5067         * gcc-interface/trans.c (Subprogram_Body_to_gnu): If the function
5068         returns by invisible reference, turn the RESULT_DECL into a pointer.
5069         Do not handle DECL_BY_REF_P in the CICO case here.
5070         (call_to_gnu): Remove code handling return by target pointer.  For a
5071         function call, if the return type has non-constant size, generate the
5072         assignment with an INIT_EXPR.
5073         (gnat_to_gnu) <N_Return_Statement>: Remove dead code in the CICO case.
5074         If the function returns by invisible reference, build the copy return
5075         operation manually.
5076         (add_decl_expr): Initialize the variable with an INIT_EXPR.
5077         * gcc-interface/utils.c (create_subprog_type): Adjust parameter names.
5078         Adjust for renaming of macros.  Copy the node only when necessary.
5079         (create_subprog_decl): Do not toggle TREE_ADDRESSABLE on the return
5080         type, only change DECL_BY_REFERENCE on the RETURN_DECL.
5081         (convert_from_reference): Delete.
5082         (is_byref_result): Likewise.
5083         (gnat_genericize_r): Likewise.
5084         (gnat_genericize): Likewise.
5085         (end_subprog_body): Do not call gnat_genericize.
5086         * gcc-interface/utils2.c (build_binary_op) <INIT_EXPR>: New case.
5087         (build_return_expr): Adjust parameter names, logic and comment.
5088
5089 2010-04-07  Eric Botcazou  <ebotcazou@adacore.com>
5090
5091         * exp_pakd.adb (Create_Packed_Array_Type): Always use a modular type
5092         if the size is small enough.  Propagate the alignment if there is an
5093         alignment clause on the original array type.
5094         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Modular_Integer_Subtype>
5095         Deal with under-aligned packed array types.  Copy the size onto the
5096         justified modular type and don't lay it out again.  Likewise for the
5097         padding type built for other under-aligned subtypes.
5098         * gcc-interface/utils.c (finish_record_type): Do not set a default mode
5099         on the type.
5100
5101 2010-04-07  Eric Botcazou  <ebotcazou@adacore.com>
5102
5103         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set default
5104         alignment on the RETURN type built for the Copy-In Copy-Out mechanism.
5105
5106 2010-04-07  Eric Botcazou  <ebotcazou@adacore.com>
5107
5108         * gcc-interface/trans.c (call_to_gnu): In the return-by-target-ptr case
5109         do not set the result type if there is a specified target and do not
5110         convert the result in any cases.
5111         (protect_multiple_eval): Make direct SAVE_EXPR for CALL_EXPR.
5112         (maybe_stabilize_reference) <COMPOUND_EXPR>: Merge with CALL_EXPR.
5113
5114 2010-03-10  Eric Botcazou  <ebotcazou@adacore.com>
5115
5116         * gcc-interface/Makefile.in (SPARC/Solaris): Use sparcv8plus.
5117
5118 2010-02-27  Eric Botcazou  <ebotcazou@adacore.com>
5119
5120         PR ada/42253
5121         * gcc-interface/utils2.c (build_binary_op) <EQ_EXPR>: Assert that fat
5122         pointer base types are variant of each other.  Apply special treatment
5123         for null to fat pointer types in all cases.
5124
5125 2010-01-28  Pascal Obry  <obry@adacore.com>
5126
5127         * s-win32.ads: Add some missing constants.
5128
5129 2010-01-28  Vincent Celier  <celier@adacore.com>
5130
5131         * prj-attr-pm.adb (Add_Attribute): Do nothing if To_Package is
5132         Unknown_Package.
5133
5134 2010-01-28  Robert Dewar  <dewar@adacore.com>
5135
5136         * gnat_rm.texi: Minor correction
5137
5138 2010-01-27  Pascal Obry  <obry@adacore.com>
5139
5140         * g-awk.adb: ensure that an AWK session is reusable.
5141
5142 2010-01-27  Vasiliy Fofanov  <fofanov@adacore.com>
5143
5144         * g-regist.adb (For_Every_Key): Fix previous change.
5145         Minor reformatting.
5146
5147 2010-01-27  Thomas Quinot  <quinot@adacore.com>
5148
5149         * lib-writ.ads: Current version of spec for new N (note) ALI lines
5150
5151 2010-01-27  Yannick Moy  <moy@adacore.com>
5152
5153         * a-cdlili.adb (Insert): Correct exception message when cursor
5154         designates wrong list.
5155
5156 2010-01-27  Vincent Celier  <celier@adacore.com>
5157
5158         * gnatcmd.adb: When there is only one main specified, the package
5159         support Switches (<main>) and attribute Switches is specified for the
5160         main, use these switches, instead of Default_Switches ("Ada").
5161
5162 2010-01-27  Robert Dewar  <dewar@adacore.com>
5163
5164         * sem_prag.adb, par-prag.adb, snames.ads-tmpl: pragma Dimension initial
5165         implementation.
5166         * exp_disp.adb: Minor reformatting
5167
5168 2010-01-27  Tristan Gingold  <gingold@adacore.com>
5169
5170         * seh_init.c: Use __ImageBase instead of _ImageBase.
5171
5172 2010-01-27  Javier Miranda  <miranda@adacore.com>
5173
5174         * exp_disp.ads, exp_disp.adb (Expand_Interface_Thunk): Modify the
5175         profile of interface thunks. The type of the controlling formal is now
5176         the covered interface type (instead of the target tagged type).
5177
5178 2010-01-27  Sergey Rybin  <rybin@adacore.com>
5179
5180         * gnat_rm.texi, gnat_ugn.texi: Update gnatcheck doc.
5181
5182 2010-01-27  Robert Dewar  <dewar@adacore.com>
5183
5184         * sinput.ads, sinput.adb (Sloc_Range): Applies to all nodes, formal
5185         changed from Expr to N.
5186
5187 2010-01-26  Thomas Quinot  <quinot@adacore.com>
5188
5189         * gnat_ugn.texi: Adjust documentation of -gnatz switches.
5190         * usage.adb: Replace line for -gnatz with two lines for -gnatzc and
5191         -gnatzr.
5192
5193 2010-01-26  Vincent Celier  <celier@adacore.com>
5194
5195         * prj-attr.adb: Add new attribute Library_Install_Name_Option
5196         Replace attribute Run_Path_Origin_Supported with Run_Path_Origin
5197         * prj-nmsc.adb (Process_Project_Level_Simple_Attributes): Process
5198         attributes Run_Path_Option and Library_Install_Name_Option.
5199         * prj.ads (Project_Configuration): Replace component
5200         Run_Path_Origin_Supported with component Run_Path_Origin. Add new
5201         component Library_Install_Name_Option.
5202         * snames.ads-tmpl: Add new standard name Library_Install_Name_Option
5203         Replace Run_Path_Origin_Supported with Run_Path_Origin
5204
5205 2010-01-26  Ed Schonberg  <schonberg@adacore.com>
5206
5207         * sem_ch8.adb (Use_One_Package): Within an instance, an actual package
5208         is not hidden by a homograph declared in another actual package.
5209
5210 2010-01-26  Robert Dewar  <dewar@adacore.com>
5211
5212         * par_sco.adb (Traverse_Declarations_Or_Statements): Only generate
5213         decisions for pragmas Assert, Check, Precondition, Postcondition if
5214         -gnata set.
5215         * scos.ads: Update comments.
5216         * get_scos.adb, put_scos.adb: Minor fix to code reading statement SCOs.
5217         Also remove obsolete code for CT (exit point) SCOs.
5218
5219 2010-01-26  Thomas Quinot  <quinot@adacore.com>
5220
5221         * switch-c.adb: Fix handling of -gnatz*
5222
5223 2010-01-26  Robert Dewar  <dewar@adacore.com>
5224
5225         * par_sco.adb (Traverse_Declarations_Or_Statements): Separate F/W
5226         qualifiers for FOR/WHILE loops
5227         * scos.ads: Use separate type letters F/W for for/while loops
5228
5229 2010-01-26  Robert Dewar  <dewar@adacore.com>
5230
5231         * get_scos.adb (Get_SCOs): Implement new form of CS entries (multiple
5232         entries per line, one for each statement in the sequence).
5233         * par_sco.adb (Traverse_Declarations_Or_Statements): Increase array
5234         size from 100 to 10_000 for SC_Array to avoid any real possibility of
5235         overflow. Output decisions in for loops.
5236         Exclude labels from CS lines.
5237         * scos.ads: Clarify that label is not included in the entry point
5238
5239 2010-01-26  Robert Dewar  <dewar@adacore.com>
5240
5241         * par_sco.adb (Traverse_Declarations_Or_Statments): Implement new
5242         format of statement sequence SCO entries (one location/statement).
5243         * put_scos.adb (Put_SCOs): Implement new format of CS lines
5244         * scos.ads: Update comments.
5245         * sem_eval.adb: Minor reformatting.
5246
5247 2010-01-26  Robert Dewar  <dewar@adacore.com>
5248
5249         * par_sco.ads, par_sco.adb (Set_Statement_Entry): New handling of exits
5250         (Extend_Statement_Sequence): New procedures
5251         (Traverse_Declarations_Or_Statements): New handling for exits.
5252
5253 2010-01-26  Robert Dewar  <dewar@adacore.com>
5254
5255         * par_sco.adb (Traverse_Declarations_Or_Statements): Add processing for
5256         Case.
5257
5258 2010-01-26  Robert Dewar  <dewar@adacore.com>
5259
5260         * par_sco.adb (Is_Logical_Operator): Exclude AND/OR/XOR
5261         * scos.ads: Clarify handling of logical operators
5262
5263 2010-01-26  Arnaud Charlet  <charlet@adacore.com>
5264
5265         * s-tpoben.adb: Update comments.
5266
5267 2010-01-26  Robert Dewar  <dewar@adacore.com>
5268
5269         * freeze.adb (Set_Small_Size): Don't set size if alignment clause
5270         present.
5271
5272 2010-01-26  Robert Dewar  <dewar@adacore.com>
5273
5274         * scos.ads: Clean up documentation, remove obsolete XOR references
5275 2010-01-26  Vincent Celier  <celier@adacore.com>
5276
5277         * gnat_ugn.texi: Complete documentation on the restrictions for
5278         combined options in -gnatxxx switches.
5279         Fix typo.
5280
5281 2010-01-26  Arnaud Charlet  <charlet@adacore.com>
5282
5283         * s-tpoben.adb (Initialize_Protection_Entries): If a PO is created from
5284         a controlled operation, abort is already deferred at this point, so we
5285         need to use Defer_Abort_Nestable.
5286
5287 2010-01-26  Vincent Celier  <celier@adacore.com>
5288
5289         * prj-conf.adb (Get_Config_Switches): Check for a default language for
5290         a project extending a project with no languages.
5291
5292 2010-01-26  Vincent Celier  <celier@adacore.com>
5293
5294         * switch-c.adb (Scan_Front_End_Switches): Take into account options
5295         that follow -gnatef.
5296         Allow -gnateG to be followed by other options.
5297
5298 2010-01-26  Robert Dewar  <dewar@adacore.com>
5299
5300         * s-commun.ads, s-osprim-mingw.adb, s-stchop-vxworks.adb, sem_aggr.adb,
5301         s-vxwext.adb, sem_ch10.adb, sem_eval.adb, sem_prag.adb: Minor
5302         reformatting.
5303
5304 2010-01-26  Vasiliy Fofanov  <fofanov@adacore.com>
5305
5306         * g-regist.adb, g-regist.ads (For_Every_Key): New generic procedure
5307         that allows to iterate over all subkeys of a key.
5308
5309 2010-01-26  Ed Falis  <falis@adacore.com>
5310
5311         * sysdep.c: enable NFS for VxWorks MILS
5312         * env.c: enable __gnat_environ for VxWorks MILS
5313         * gcc-interface/Makefile.in: Add VxWorks MILS target pairs.
5314
5315 2010-01-25  Bob Duff  <duff@adacore.com>
5316
5317         * sem_aggr.adb (Resolve_Array_Aggregate): Check for the case where this
5318         is an internally-generated positional aggregate, and the bounds are
5319         already correctly set. We don't want to overwrite those bounds with
5320         bounds determined by context.
5321
5322 2010-01-25  Robert Dewar  <dewar@adacore.com>
5323
5324         * g-sercom.ads, gnatcmd.adb, gnatlink.adb, a-ststio.adb, exp_ch6.adb,
5325         exp_ch9.adb, g-sechas.ads: Minor reformatting.
5326
5327 2010-01-25  Thomas Quinot  <quinot@adacore.com>
5328
5329         * s-commun.adb (Last_Index): Count must be converted to SEO (a signed
5330         integer type) before subtracting 1, otherwise the computation may wrap
5331         (because size_t is modular) and cause the conversion to fail.
5332
5333 2010-01-25  Ed Falis  <falis@adacore.com>
5334
5335         * sysdep.c, init.c: Adapt to support full run-time on VxWorks MILS.
5336
5337 2010-01-25  Vincent Celier  <celier@adacore.com>
5338
5339         * prj-attr.adb: New attribute Run_Path_Origin_Required
5340         * prj-nmsc.adb (Process_Project_Level_Simple_Attributes): Process new
5341         attribute Run_Path_Origin_Required.
5342         * prj.ads (Project_Configuration): New component
5343         Run_Path_Origin_Supported.
5344         * snames.ads-tmpl: New standard name Run_Path_Origin_Required
5345
5346 2010-01-25  Ed Schonberg  <schonberg@adacore.com>
5347
5348         * sem_aggr.adb (Resolve_Array_Aggregate): If the bounds in a choice
5349         have errors, do not continue resolution of the aggregate.
5350         * sem_eval.adb (Eval_Indexed_Component): Do not attempt to evaluate if
5351         the array type indicates an error.
5352
5353 2010-01-25  Bob Duff  <duff@adacore.com>
5354
5355         * sinfo.ads: Minor comment fixes.
5356
5357 2010-01-25  Bob Duff  <duff@adacore.com>
5358
5359         * exp_ch4.adb, exp_aggr.adb: Minor comment fixes and code clean up.
5360
5361 2010-01-25  Arnaud Charlet  <charlet@adacore.com>
5362
5363         * gnatvsn.ads (Current_Year): Update.
5364
5365 2010-01-25  Florian Villoing  <villoing@adacore.com>
5366
5367         * gnat_ugn.texi: Fix typo.
5368
5369 2010-01-25  Thomas Quinot  <quinot@adacore.com>
5370
5371         * scos.ads: Update specification.
5372
5373 2010-01-25  Ed Schonberg  <schonberg@adacore.com>
5374
5375         * sem_ch6.adb (Process_PPCs): If a postcondition is present and the
5376         enclosing subprogram has no previous spec, attach postcondition
5377         procedure to the defining entity for the body.
5378
5379 2010-01-25  Ed Schonberg  <schonberg@adacore.com>
5380
5381         * exp_aggr.adb (Build_Record_Aggr_Code); Do not generate call to
5382         initialization procedure of the ancestor part of an extension aggregate
5383         if it is an interface type.
5384
5385 2010-01-25  Vincent Celier  <celier@adacore.com>
5386
5387         * gnatlink.adb (Process_Binder_File): The directory for the shared
5388         version of libgcc in the run path options is found in the subdirectory
5389         indicated by __gnat_default_libgcc_subdir.
5390         * link.c: Declare new const char * __gnat_default_libgcc_subdir for
5391         each platform.
5392
5393 2010-01-25  Ed Schonberg  <schonberg@adacore.com>
5394
5395         * sem_prag.adb: More flexible pragma Annotate.
5396
5397 2010-01-22  Eric Botcazou  <ebotcazou@adacore.com>
5398
5399         * system-linux-armel.ads (Stack_Check_Probes): Set to True.
5400         * system-linux-armeb.ads (Stack_Check_Probes): Likewise.
5401
5402 2010-01-18  Eric Botcazou  <ebotcazou@adacore.com>
5403
5404         * gcc-interface/utils.c (create_var_decl_1): Fix formatting nits.
5405
5406 2010-01-18  Jan Hubicka  <jh@suse.cz>
5407
5408         PR middle-end/42068
5409         * gcc-interface/utils.c (create_var_decl_1): Do not set COMMON flag for
5410         unit local variables.
5411
5412 2010-01-17  Laurent GUERBY  <laurent@guerby.net>
5413
5414         * gcc-interface/Makefile.in: Fix typo in arm*-*-linux-gnueabi.
5415
5416 2010-01-11  Mikael Pettersson  <mikpe@it.uu.se>
5417
5418         * gcc-interface/Makefile.in: Add arm*-*-linux-gnueabi.
5419         * system-linux-armeb.ads, system-linux-armel.ads: New files.
5420
5421 2010-01-09  Simon Wright  <simon@pushface.org>
5422
5423         PR ada/42626
5424         * gcc-interface/Makefile.in (gnatlib-shared-darwin): Add missing
5425         end-quote.
5426
5427
5428 \f
5429 Copyright (C) 2010 Free Software Foundation, Inc.
5430
5431 Copying and distribution of this file, with or without modification,
5432 are permitted in any medium without royalty provided the copyright
5433 notice and this notice are preserved.