]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/ada/ChangeLog
[multiple changes]
[thirdparty/gcc.git] / gcc / ada / ChangeLog
1 2011-08-04 Arnaud Charlet <charlet@adacore.com>
2
3 * prj-env.adb: Remove local debug traces.
4
5 2011-08-04 Yannick Moy <moy@adacore.com>
6
7 * checks.adb (Apply_Float_Conversion_Check): correct a typo where Lo_OK
8 was used instead of Hi_OK, which could cause a read of an uninitialized
9 value later on. Detected while working on the new warning.
10 * exp_ch9.adb (Expand_N_Entry_Declaration): remove useless assignment
11 to local variable.
12 * sem_ch5.adb (Analyze_Assignment): set the last assignment component
13 in more cases, in order to detect more unreferenced values.
14 * sem_util.adb, sem_util.ads (Get_Enclosing_Object): return enclosing
15 object for expression, if any.
16
17 2011-08-04 Eric Botcazou <ebotcazou@adacore.com>
18
19 * exp_intr.adb (Expand_Binary_Operator_Call): Look at the RM size of
20 the operand types instead of the Esize.
21
22 2011-08-04 Steve Baird <baird@adacore.com>
23
24 * switch-b.adb (Scan_Binder_Switches): Add -P binder switch, used to
25 enable CodePeer_Mode.
26 * bindusg.adb (Display): Add help message describing -P binder switch.
27 * gnat_ugn.texi: Document -P binder switch.
28 * bindgen.adb (Gen_Main_Ada): If CodePeer_Mode is set, then call the
29 user-defined main program directly.
30 (Gen_Output_File_Ada): If CodePeer_Mode is set, generate a with of the
31 user-defined main program in the context clause of the package body.
32
33 2011-08-04 Yannick Moy <moy@adacore.com>
34
35 * alfa.adb, alfa.ads (Get_Entity_For_Decl): remove function, partial
36 duplicate of Defining_Entity
37 (Get_Unique_Entity_For_Decl): rename function into
38 Unique_Defining_Entity
39 * einfo.adb, einfo.ads (Is_In_ALFA, Body_Is_In_ALFA): remove flags
40 (Formal_Proof_On): remove synthesized flag
41 * cstand.adb, sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
42 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_res.adb, sem_util.adb,
43 sem_util.ads, stand.ads: Remove treatment associated to entities in ALFA
44 * sem_prag.adb (Analyze_Pragma): remove special treatment for pragma
45 Annotate (Formal_Proof)
46
47 2011-08-04 Emmanuel Briot <briot@adacore.com>
48
49 * prj-env.adb (Create_Config_Pragmas_File): fix handling of multi-unit
50 source files with non-standard naming schemes, in imported projects
51
52 2011-08-04 Emmanuel Briot <briot@adacore.com>
53
54 * makeutl.adb (Complete_Mains): when a multi-unit source file is
55 specified on the gprbuild command line, we need to compile all units
56 within that file, not just the first one we find
57 Fix error message for mains that are not found.
58
59 2011-08-04 Thomas Quinot <quinot@adacore.com>
60
61 * sem_ch6.adb: Update comment.
62 * sem_ch12.adb: Minor reformatting.
63
64 2011-08-04 Bob Duff <duff@adacore.com>
65
66 * s-tasren.adb (Task_Do_Or_Queue): Previous code was reading
67 Acceptor.Terminate_Alternative without locking Acceptor, which causes a
68 race condition whose symptom is to fail to lock Parent. That, in turn,
69 causes Parent.Awake_Count to be accessed without locking Parent, which
70 causes another race condition whose symptom is that Parent.Awake_Count
71 can be off by 1 (either too high or too low). The solution is to lock
72 Parent unconditionally, and then lock Acceptor, before reading
73 Acceptor.Terminate_Alternative.
74
75 2011-08-04 Arnaud Charlet <charlet@adacore.com>
76
77 * debug.adb: Update comment.
78
79 2011-08-04 Robert Dewar <dewar@adacore.com>
80
81 * par_sco.adb, exp_util.adb, make.adb, a-tags.adb, sem_prag.adb,
82 sem_util.adb, sem_attr.adb, exp_ch4.adb, g-comlin.adb, g-comlin.ads,
83 exp_ch6.adb: Minor reformatting.
84
85 2011-08-04 Gary Dismukes <dismukes@adacore.com>
86
87 * gnat_ugn.texi: Add sentence about the case of compile-time-detected
88 checks for -gnateE.
89
90 2011-08-04 Ed Schonberg <schonberg@adacore.com>
91
92 * gnat_rm.texi: update Ravenscar desription to reflect Ada2012 RM.
93
94 2011-08-04 Thomas Quinot <quinot@adacore.com>
95
96 * sinfo.ads: Minor reformatting.
97
98 2011-08-04 Emmanuel Briot <briot@adacore.com>
99
100 * makeutl.adb, makeutl.ads, prj-nmsc.adb (Complete_Mains): report error
101 even if there is no location.
102
103 2011-08-04 Ed Schonberg <schonberg@adacore.com>
104
105 * sem_res.adb, sem_ch4.adb: move check for restriction
106 No_Task_Hierarchy to resolve_allocator.
107
108 2011-08-04 Thomas Quinot <quinot@adacore.com>
109
110 * sinfo.adb, sinfo.ads, sem_prag.adb, sem_ch12.adb (Pragma_Enabled):
111 This flag of N_Pragma nodes is not used, remove it as well as all of
112 the associated circuitry.
113
114 2011-08-04 Javier Miranda <miranda@adacore.com>
115
116 * exp_disp.adb (Make_DT): Switch -gnatdQ disables the generation of the
117 runtime check on duplicated externa tags
118 * debug.adb Document switch -gnatdQ.
119
120 2011-08-04 Gary Dismukes <dismukes@adacore.com>
121
122 * a-fihema.ads: Minor typo fix.
123
124 2011-08-04 Yannick Moy <moy@adacore.com>
125
126 * sem_ch10.adb: Minor comment update.
127
128 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
129
130 * einfo.adb: Update the node field usage to reflect the renaming of
131 Return_Flag to Return_ Flag_Or_Transient_Decl.
132 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl.
133 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl.
134 (Write_Field15_Name): Change Return_Flag to
135 Return_Flag_Or_Transient_Decl.
136 * einfo.ads: Rename node field Return_Flag to
137 Return_Flag_Or_Transient_Decl. Update the associated comment and all
138 occurrences in entities.
139 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl. Update
140 associated Inline pragma.
141 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl. Update
142 associated Inline pragma.
143 * exp_ch4.ads, exp_ch4.adb (Expand_N_Expression_With_Actions): New
144 routine.
145 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Update the calls to
146 Return_Flag and Set_Return_Flag.
147 * exp_ch7.adb (Process_Declarations): Add code to recognize hook
148 objects generated for controlled transients declared inside an
149 Exception_With_Actions. Update the calls to Return_Flag.
150 (Process_Object_Declaration): Add code to add a null guard for hook
151 objects generated for controlled transients declared inside an
152 Exception_With_Actions. Update related comment.
153 * exp_util.adb (Has_Controlled_Objects): Add code to recognize hook
154 objects generated for controlled transients declared inside an
155 Exception_With_Actions. Update the calls to Return_Flag.
156 * expander.adb (Expand): Add new case for N_Expression_With_Actions.
157
158 2011-08-04 Ed Schonberg <schonberg@adacore.com>
159
160 * sem_util.adb:(Wrong_Type): Improve error message on a one-element
161 positional aggregate.
162
163 2011-08-04 Vincent Celier <celier@adacore.com>
164
165 * par_sco.adb (Process_Decisions.Output_Header): Check and record pragma
166 SLOC only for pragmas.
167
168 2011-08-04 Emmanuel Briot <briot@adacore.com>
169
170 * projects.texi: Minor typo fix.
171
172 2011-08-04 Emmanuel Briot <briot@adacore.com>
173
174 * prj-nmsc.adb (Check_File): Minor change to traces, to help debugging
175 on case-sensitive file systems.
176
177 2011-08-04 Thomas Quinot <quinot@adacore.com>
178
179 * put_scos.adb (Put_SCOs): Do not emit decision SCO for an X decision
180 nested in a disabled pragma.
181 * scos.ads, scos.adb, par_sco.ads, par_sco.adb: Record sloc of
182 enclosing pragma, if any, for X decisions.
183
184 2011-08-04 Thomas Quinot <quinot@adacore.com>
185
186 * sem_prag.adb: Minor reformatting.
187
188 2011-08-04 Vincent Celier <celier@adacore.com>
189
190 * a-tags.adb (Check_TSD): Avoid concatenation of strings, as it is not
191 allowed in no run time mode.
192
193 2011-08-04 Vincent Celier <celier@adacore.com>
194
195 * make.adb (Check): When -gnatc is used, check for the source file
196 inside the ALI file with a canonical case file name.
197
198 2011-08-04 Emmanuel Briot <briot@adacore.com>
199
200 * g-comlin.adb, g-comlin.ads (Add_Switch): Put back support for
201 overriding the separator.
202
203 2011-08-04 Robert Dewar <dewar@adacore.com>
204
205 * sem_aggr.adb, par_sco.adb, sem_type.adb, exp_util.adb, exp_ch9.adb,
206 prj-nmsc.adb, sem_ch13.adb, exp_strm.adb: Minor reformatting.
207
208 2011-08-04 Robert Dewar <dewar@adacore.com>
209
210 * gnat_rm.texi: Minor documentation fix for pragma Annotate.
211
212 2011-08-04 Yannick Moy <moy@adacore.com>
213
214 * sem_attr.adb (Analyze_Attribute): add check during pre-analysis that
215 'Result only appears in postcondition of function.
216
217 2011-08-04 Thomas Quinot <quinot@adacore.com>
218
219 * a-tags.adb (Check_TSD): When raising PROGRAM_ERROR for a duplicated
220 external tag, include the value of the external tag in the exception
221 message.
222
223 2011-08-04 Yannick Moy <moy@adacore.com>
224
225 * sem_attr.adb (Result): modify error message for misplaced 'Result
226
227 2011-08-04 Sergey Rybin <rybin@adacore.com>
228
229 * gnat_rm.texi (pragma Annotate): Fix syntax description to make it
230 clear that the second argument must be an identifier.
231
232 2011-08-04 Thomas Quinot <quinot@adacore.com>
233
234 * exp_ch9.adb (Build_Barrier_Function): When compiling with
235 -fpreserve-control-flow, insert an IF statement on the barrier
236 condition to ensure that a conditional branch instruction is generated.
237
238 2011-08-04 Emmanuel Briot <briot@adacore.com>
239
240 * prj-part.adb, prj.adb, prj.ads, prj-tree.ads
241 (Processing_Flags.Ignore_Missing_With): new flag.
242
243 2011-08-04 Emmanuel Briot <briot@adacore.com>
244
245 * prj-nmsc.adb (Find_Sources, Path_Name_Of): Fix handling of
246 Source_List_File on case-insensitive systems where the file is actually
247 on a case-sensitive file system (NFS,...).
248
249 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
250
251 * sem_ch6.adb (Analyze_Function_Return): In a rare case where a
252 function return contains a controlled [extension] aggregate and the
253 return statement is not part of a handled sequence of statements, wrap
254 the return in a block. This ensures that all controlled temporaries
255 generated during aggregate resolution will be picked up by the
256 finalization machinery.
257
258 2011-08-04 Ed Schonberg <schonberg@adacore.com>
259
260 * sem_aggr.adb (Resolve_Aggregate): If aggregate has box-initialized
261 components, freeze type before resolution, to ensure that default
262 initializations are present for all components.
263 * sem_res.adb (Resolve_Actuals): the designated object of an
264 accces-to-constant type is a legal actual in a call to an
265 initialization procedure.
266
267 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
268
269 * exp_util.adb (Extract_Renamed_Object): Add N_Type_Conversion and
270 N_Unchecked_Type_Conversion to the possible containers of a renamed
271 transient variable.
272
273 2011-08-04 Yannick Moy <moy@adacore.com>
274
275 * par-ch13.adb (Aspect_Specifications_Present): recognize
276 "with Identifier'Class =>" as an aspect, so that a meaningful warning
277 is issued in Strict mode.
278 * par.adb: Fix typos in comments.
279
280 2011-08-04 Yannick Moy <moy@adacore.com>
281
282 * sem_attr.adb (Result): modify error message to take into account Post
283 aspect when compiling Ada 2012 (or newer) code.
284
285 2011-08-04 Nicolas Roche <roche@adacore.com>
286
287 * env.c (__gnat_clearenv): Avoid use of dynamic size array in order to
288 remove need for GCC exceptions.
289
290 2011-08-04 Vincent Celier <celier@adacore.com>
291
292 * makeutl.adb (Do_Complete): Call Debug_Output with the name of the
293 project, not the source file name.
294 * prj.adb (Find_Sources.Look_For_Sources): If the source has been
295 excluded, continue looking. This excluded source will only be returned
296 if there is no other source with the same base name that is not locally
297 removed.
298
299 2011-08-04 Ed Schonberg <schonberg@adacore.com>
300
301 * sem_res.adb (Resolve_Intrinsic_Operator): if the result type is
302 private and one of the operands is a real literal, use a qualified
303 expression rather than a conversion which is not meaningful to the
304 back-end.
305
306 2011-08-04 Yannick Moy <moy@adacore.com>
307
308 * sem_ch13.adb (Aspect_Loop): when an aspect X and its classwise
309 corresponding aspect X'Class are allowed, proceed with analysis of the
310 aspect instead of skipping it.
311
312 2011-08-04 Tristan Gingold <gingold@adacore.com>
313
314 * s-flocon.adb, s-flocon.ads: Add a body for s-flocon.ads
315 This will allow to have an Ada implementation for the subprogram.
316
317 2011-08-04 Ed Schonberg <schonberg@adacore.com>
318
319 * sem_ch3.adb (Analyze_Full_Type_Declaration): If the declaration is a
320 completion and aspects are present, apply them to the entity for the
321 type which is currently the partial view, but which is the one that
322 will be frozen.
323 * sem_ch13.adb (Analyze_Aspect_Specifications): if the predicate
324 applies to a partial view, indicate that the full view has predicates
325 and delayed aspects.
326 (Replace_Type_Reference): Handle properly predicates that apply to the
327 full view of a private completion.
328
329 2011-08-04 Eric Botcazou <ebotcazou@adacore.com>
330
331 * layout.adb (Layout_Type): For composite types, do not set Esize.
332 * freeze.adb (Set_Small_Size): Remove test on alignment and do not
333 set Esize.
334 (Size_Known): Look at the RM size of components instead of the Esize.
335 (Freeze_Record_Type): Look at the RM size instead of the Esize to
336 issue warning and activate Implicit_Packing.
337 (Freeze_Entity): Likewise. Do not issue a warning for alias/atomic
338 if the Esize is not known.
339 * sem_ch13.adb (Analyze_Attribute_Definition_Clause) <Size>: Set Esize
340 for elementary types only.
341 (Analyze_Record_Representation_Clause): Look at the RM size instead
342 of the Esize to issue errors.
343 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not set Esize if it
344 is not known.
345 <E_Record_Type>: Look at the RM size instead of the Esize. Remove
346 obsolete block.
347 Look at the RM size instead of the Esize for types if the latter is
348 not known.
349 (gnat_to_gnu_field): Use Known_Esize instead of Known_Static_Esize.
350
351 2011-08-04 Ed Schonberg <schonberg@adacore.com>
352
353 * sem_type.adb: proper handling of equality not involving anonymous
354 access types.
355
356 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
357
358 * exp_ch7.adb (Create_Finalizer): Remove local variables Spec_Nod and
359 Vis_Decls. When creating a library-level finalizer for a package spec,
360 both the declaration and body of the finalizer are inserted either in
361 the visible or private declarations of the package spec.
362
363 2011-08-04 Javier Miranda <miranda@adacore.com>
364
365 * sem_ch3.adb (Derive_Subprograms): Complete assertion to request the
366 use of the full-view of a type when invoking Is_Ancestor.
367 * sem_type.adb (Is_Ancestor): For consistency, when the traversal of
368 the full-view of private parents is requested, then use also the
369 full-view of the parent of the first derivation.
370
371 2011-08-04 Tristan Gingold <gingold@adacore.com>
372
373 * s-taprop-vxworks.adb (Enter_Task): Use System.Float_Control.Reset
374 instead of the locally imported procedure.
375 * s-taprop-mingw.adb (Enter_Task): Ditto.
376 * s-valrea.adb (Scan_Real): Ditto.
377 * s-imgrea.adb (Set_Image_Real): Ditto.
378 * s-flocon.ads: Make the package pure.
379
380 2011-08-04 Thomas Quinot <quinot@adacore.com>
381
382 * sinfo.ads, sinfo.adb (Debug_Statement, Set_Debug_Statement): Remove.
383 * tbuild.ads, tbuild.adb (Make_Pragma): Adjust accordingly.
384 * sinfo-cn.ads, sinfo-cn.adb (Change_Name_To_Procedure_Call_Statement):
385 New subprogram, moved here from...
386 * par.adb, par-ch5.adb (P_Statement_Name): ... here.
387 * par-prag.adb (Par.Prag, case Pragma_Debug): Do not perform any
388 rewriting of the last argument into a procedure call statement here...
389 * sem_prag.adb (Analyze_Pragma, case Pragma_Debug): ...do it there
390 instead.
391
392 2011-08-04 Thomas Quinot <quinot@adacore.com>
393
394 * par_sco.adb: Minor reformatting.
395
396 2011-08-04 Robert Dewar <dewar@adacore.com>
397
398 * erroutc.adb: Minor reformatting.
399
400 2011-08-04 Thomas Quinot <quinot@adacore.com>
401
402 * par_sco.adb: Comment update.
403
404 2011-08-04 Tristan Gingold <gingold@adacore.com>
405
406 * s-flocon.ads: New file.
407 * g-flocon.ads: Now a renaming of s-flocon.
408 * Makefile.rtl: Add s-flocon.o
409
410 2011-08-04 Javier Miranda <miranda@adacore.com>
411
412 * exp_strm.adb (Build_Array_Input_Function): if the array type is
413 constrained, do not attempt to build a subtype of it.
414
415 2011-08-04 Yannick Moy <moy@adacore.com>
416
417 * errout.ads Change comments: remove 'R'M as an example where quotes
418 are needed; add ALFA as another case where quotes are not needed
419 * erroutc.adb (Set_Msg_Insertion_Reserved_Word): add ALFA as another
420 case where quotes are not needed.
421 * sem_ch11.adb, sem_ch13.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
422 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_prag.adb, sem_res.adb:
423 Remove all occurrences of 'A'L'F'A
424
425 2011-08-04 Ed Schonberg <schonberg@adacore.com>
426
427 * sem_ch13.adb: check legality of invariant pragma.
428
429 2011-08-04 Eric Botcazou <ebotcazou@adacore.com>
430
431 * bindgen.adb: Add comments.
432
433 2011-08-04 Yannick Moy <moy@adacore.com>
434
435 * einfo.adb, einfo.ads: Free Flag254 and make Formal_Proof_On a
436 synthesized flag.
437 * sem_prag.adb (Analyze_Pragma): record the pragma Annotate
438 (Formal_Proof, On/Off) in the Rep_Item list of the current subprogram.
439
440 2011-08-04 Robert Dewar <dewar@adacore.com>
441
442 * exp_ch7.adb, exp_ch6.adb, sem_ch3.adb, layout.adb, sem_ch5.adb,
443 osint-c.ads, sem_util.ads, gnat1drv.adb, targparm.ads, sem_ch6.adb,
444 sem_ch13.adb, s-pooloc.adb: Minor reformatting.
445
446 2011-08-04 Thomas Quinot <quinot@adacore.com>
447
448 * s-pooloc.ads, s-pooglo.ads: Minor reformatting
449
450 2011-08-04 Thomas Quinot <quinot@adacore.com>
451
452 PR ada/47880
453 * s-pooloc.adb (Deallocate): Fix the case of deallocating the only
454 allocated object.
455
456 2011-08-04 Robert Dewar <dewar@adacore.com>
457
458 * einfo.ads, exp_ch4.adb: Minor reformatting.
459
460 2011-08-04 Jerome Lambourg <lambourg@adacore.com>
461
462 * back_end.ads (Gen_Or_Update_Object_File): Add more comments.
463
464 2011-08-04 Ed Schonberg <schonberg@adacore.com>
465
466 * exp_ch4.adb (Expand_Composite_Equality): code cleanup: use component
467 type in all cases to compute list of primitive operations, because full
468 view may be an itype that is not attached to the list of declarations.
469
470 2011-08-04 Eric Botcazou <ebotcazou@adacore.com>
471
472 * bindgen.adb (Gen_Adafinal_Ada): Generate an early return if the
473 library has already been finalized.
474 (Gen_Adafinal_C): Likewise.
475 (Gen_Adainit_Ada): Generate an early return if the library has
476 already been elaborated.
477 (Gen_Adainit_C): Likewise.
478 (Gen_Output_File_Ada): Generate an elaboration flag.
479 (Gen_Output_File_C): Likewise.
480
481 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
482
483 * exp_ch4.adb (Expand_Allocator_Expression): Disable the generation of
484 Set_Finalize_Address_Ptr for CodePeer because Finalize_Address was not
485 built in the first place.
486 (Expand_N_Allocator): Disable the generation of Set_Finalize_Address_Ptr
487 for CodePeer because Finalize_Address was not built to begin with.
488 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Ditto.
489
490 2011-08-04 Pascal Obry <obry@adacore.com>
491
492 * adaint.c (__gnat_tmp_name): Use current process id to create temp
493 filenames, this ensures unicity of filenames across processes.
494
495 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
496
497 * bindgen.adb (Gen_Finalize_Library_Ada): Rename generated routine
498 Raise_Controlled to Raise_From_Controlled_Operation. Update the
499 signature of Raise_From_Controlled_Operation by adding flag From_Abort.
500 Add False as the actual to From_Abort in the generated call to
501 Raise_From_Controlled_Operation.
502
503 2011-08-04 Jerome Lambourg <lambourg@adacore.com>
504
505 * osint-c.ads, osint-c.adb (Set_Library_Info_Name): Move to declaration
506 so that the ali file name can be retrieved from outside of this package.
507 * back_end.ads, back_end.adb (Gen_Or_Update_Object_File): New method
508 doing nothing in the general case, but used to update the object file
509 timestamp if directly generated by the backend.
510 * gnat1drv.adb (Gnat1drv): Make sure the object file's timestamp is set
511 to a later time than the ali file one.
512
513 2011-08-04 Yannick Moy <moy@adacore.com>
514
515 * einfo.adb, einfo.ads (Formal_Proof_On): new flag set on subprogram
516 entities whose body contains an Annotate pragma which forces formal
517 proof on this body.
518 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
519 sem_ch6.adb, sem_ch9.adb, sem_res.adb: Adapt call to
520 Mark_Non_ALFA_Subprogram to pass in a message and node.
521 * sem_prag.adb (Analyze_Pragma): add treatment of pragma Annotate
522 (Forma_Proof, On) which sets the flag Formal_Proof_On in the
523 surrounding subprogram.
524 * sem_util.adb, sem_util.ads (Mark_Non_ALFA_Subprogram,
525 Mark_Non_ALFA_Subprogram_Unconditional): if the subprogram being marked
526 as not in ALFA is annotated with Formal_Proof being On, then an error
527 is issued based on the additional parameters for message and node.
528 * snames.ads-tmpl (Name_Formal_Proof): new name for annotation.
529 * gcc-interface/Make-lang.in: Update dependencies.
530
531 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
532
533 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Do not generate
534 Finalize_Address when CodePeer is enabled.
535
536 2011-08-04 Pascal Obry <obry@adacore.com>
537
538 * adaint.c (__gnat_tmp_name): Use _tempnam() instead of tempnam() as
539 the latter returns a pointer to a static buffer which is deallocated
540 at the end of the routine.
541
542 2011-08-04 Yannick Moy <moy@adacore.com>
543
544 * sem_ch3.adb (Array_Type_Declaration): move test for type in ALFA
545 after index creation; mark unconstrained base array type generated as
546 being in/not in ALFA as well
547 (Make_Index): mark subtype created as in/not in ALFA
548 * sem_ch5.adb (Analyze_Iteration_Scheme): mark entity for iterating
549 over a loop as in/not in ALFA, depending on its type and form of loop
550 iteration.
551
552 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
553
554 * exp_ch7.adb (Build_Object_Declarations): Initialize flag Abort
555 directly to False on .NET and JVM.
556
557 2011-08-04 Yannick Moy <moy@adacore.com>
558
559 * sem_ch3.adb (Constrain_Enumeration, Constrain_Integer): remove
560 constraint that subtype must come from source code to be in ALFA, so
561 that anonymous subtypes can be in ALFA too.
562
563 2011-08-04 Yannick Moy <moy@adacore.com>
564
565 * sem_ch3.adb (Analyze_Object_Declaration): remove obsolete addition of
566 reference for ALFA mode.
567 * lib-xref-alfa.adb, lib-xref.ads (Traverse_Compilation_Unit): make
568 procedure public so as to use it from formal verification back-end.
569
570 2011-08-04 Jerome Lambourg <lambourg@adacore.com>
571
572 * g-comlin.adb (For_Each_Simple_Switch.Is_In_Config): Remove the
573 invalid checks of the Parameter, making Remove_Switch not working
574 correctly.
575
576 2011-08-04 Arnaud Charlet <charlet@adacore.com>
577
578 * targparm.ads: Update header: no run-time exception is needed on this
579 file.
580
581 2011-08-04 Vincent Celier <celier@adacore.com>
582
583 * a-fihema.adb: Use System.IO instead of GNAT.IO
584
585 2011-08-04 Thomas Quinot <quinot@adacore.com>
586
587 * sem_ch3.adb (Access_Definition): Anonymous access to subprogram types
588 are forbidden in Compiler_Unit mode.
589
590 2011-08-04 Robert Dewar <dewar@adacore.com>
591
592 * sem_util.adb: Minor reformatting.
593
594 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
595
596 * bindgen.adb (Gen_Finalize_Library_Ada): Update the import string for
597 library-level finalizers.
598 (Gen_Finalize_Library_C): Update the import string for library-level
599 finalizers.
600 (Gen_Finalize_Library_Defs_C): Update the definition name of a
601 library-level finalizer.
602 * exp_ch7.adb: Remove with and use clauses for Stringt.
603 (Create_Finalizer): Remove local variables Conv_Name, Prag_Decl,
604 Spec_Decl. Add local variable Body_Id. The names of library-level
605 finalizers are now manually fully qualified and are no longer external.
606 A single name is now capable of servicing .NET, JVM and non-VM targets.
607 Pragma Export is no longer required to provide visibility for the name.
608 (Create_Finalizer_String): Removed.
609 (New_Finalizer_Name): New routine which mimics New_..._Name.
610
611 2011-08-04 Eric Botcazou <ebotcazou@adacore.com>
612
613 * sem_elab.adb (Check_Internal_Call_Continue): Change the type of the
614 elaboration counter to Standard_Short_Integer.
615 * sem_util.adb (Build_Elaboration_Entity): Likewise.
616 * bindgen.adb (Gen_Elab_Externals_Ada): Adjust to above change.
617 (Gen_Elab_Externals_C): Likewise.
618
619 2011-08-04 Ed Falis <falis@adacore.com>
620
621 * system-vxworks-arm.ads, system-vxworks-sparcv9.ads,
622 system-vxworks-ppc.ads, system-vxworks-m68k.ads,
623 system-vxworks-mips.ads, system-vxworks-x86.ads
624 (Always_Compatible_Rep): set to False for all VxWorks targets.
625
626 2011-08-04 Robert Dewar <dewar@adacore.com>
627
628 * par_sco.adb, prj-proc.adb, make.adb, bindgen.adb, prj.adb, prj.ads,
629 makeutl.adb, makeutl.ads, prj-nmsc.adb, exp_ch5.adb, exp_ch12.adb,
630 exp_ch7.ads, exp_util.ads, sem_util.ads, g-comlin.ads, exp_ch6.adb,
631 exp_ch6.ads, lib-xref.ads, exp_ch7.adb, exp_util.adb, exp_dist.adb,
632 exp_strm.adb, gnatcmd.adb, freeze.adb, g-comlin.adb, lib-xref-alfa.adb,
633 sem_attr.adb, sem_prag.adb, sem_util.adb, sem_elab.adb, sem_ch8.adb,
634 sem_ch11.adb, sem_eval.adb, sem_ch13.adb, sem_disp.adb, a-fihema.adb:
635 Minor reformatting and code reorganization.
636
637 2011-08-04 Emmanuel Briot <briot@adacore.com>
638
639 * projects.texi: Added doc for aggregate projects.
640
641 2011-08-04 Emmanuel Briot <briot@adacore.com>
642
643 * prj-proc.adb, prj-nmsc.adb, prj-env.adb (Process_Declarative_Items):
644 Add support for overriding the Project_Path in aggregate projects.
645
646 2011-08-04 Robert Dewar <dewar@adacore.com>
647
648 * a-cofove.ads: Minor reformatting.
649
650 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
651
652 * exp_ch7.adb (Build_Adjust_Or_Finalize_Statements): Update the comment
653 on the generated code.
654 (Build_Finalize_Statements): Update the comment on the generated code.
655 (Build_Initialize_Statements): Update the comment on the generated code.
656 (Build_Object_Declarations): Add local variable Result. The object
657 declarations are now built in sequence.
658 * rtsfind.ads: Add RE_Exception_Occurrence_Access to tables RE_Id and
659 RE_Unit_Table.
660
661 2011-08-04 Robert Dewar <dewar@adacore.com>
662
663 * checks.adb, alfa.adb, alfa.ads: Minor reformatting.
664
665 2011-08-04 Eric Botcazou <ebotcazou@adacore.com>
666
667 * einfo.ads (Elaboration_Entity): Document new definition and use.
668 (Elaboration_Entity_Required): Adjust to above change.
669 * exp_attr.adb (Expand_N_Attribute_Reference): Likewise.
670 * exp_ch12.adb: And with and use for Snames.
671 (Expand_N_Generic_Instantiation): Test 'Elaborated attribute.
672 * exp_util.adb (Set_Elaboration_Flag): Likewise.
673 * sem_attr.adb (Analyze_Attribute) <Check_Library_Unit>: Delete.
674 <Check_Unit_Name>: Deal with N_Expanded_Name.
675 <Attribute_Elaborated>: Extend to all unit names.
676 * sem_elab.adb: And with and use for Uintp.
677 (Check_Internal_Call_Continue): Adjust to Elaboration_Entity change.
678 * sem_util.ads (Build_Elaboration_Entity): Adjust comment.
679 * sem_util.adb (Build_Elaboration_Entity): Change type to Integer.
680 * bindgen.adb (Gen_Elab_Externals_Ada): New local subprogram taken
681 from Gen_Adainit_Ada.
682 (Gen_Elab_Externals_C): Likewise, but taken from Gen_Adainit_C.
683 (Gen_Adafinal_Ada): Remove redundant test. In the non-main program
684 case, do not call System.Standard_Library.Adafinal; instead call
685 finalize_library if needed.
686 (Gen_Adafinal_C): Likewise.
687 (Gen_Adainit_Ada): Do not set SSL.Finalize_Library_Objects in the
688 non-main program case.
689 (Gen_Adainit_C): Generate a couple of external declarations here.
690 In the main program case, set SSL.Finalize_Library_Objects.
691 (Gen_Elab_Calls_Ada): Adjust to Elaboration_Entity change.
692 (Gen_Elab_Calls_C): Likewise.
693 (Gen_Finalize_Library_Ada): Likewise. Skip SAL interface units.
694 (Gen_Finalize_Library_C): Likewise. Generate a full function.
695 (Gen_Main_C): Put back call to Ada_Final and don't finalize library
696 objects here.
697 (Gen_Output_File_Ada): Generate pragma Linker_Destructor for Ada_Final
698 if -a is specified. Call Gen_Elab_Externals_Ada. Move around call to
699 Gen_Adafinal_Ada.
700 (Gen_Output_File_C): Generate __attribute__((destructor)) for Ada_Final
701 if -a is specified. Call Gen_Elab_Externals_C. Remove useless couple
702 of external declarations.  Call Gen_Finalize_Library_C.
703
704 2011-08-04 Emmanuel Briot <briot@adacore.com>
705
706 * prj.adb, prj.ads, makeutl.adb, makeutl.ads (Complete_Mains,
707 Compute_Compilation_Phases): new subprogram.
708 (Builder_Data, Builder_Project_Tree_Data): new subprogram and type
709 The number of mains as well as the various compilation phases that
710 need to be run are now project tree specific, since various
711 aggregated trees might have different requirements. In particular,
712 they do not all require bind or link phases.
713
714 2011-08-04 Emmanuel Briot <briot@adacore.com>
715
716 * prj.adb, prj.ads, makeutl.adb, makeutl.ads, prj-env.adb
717 (Project_Tree_Appdata): New type.
718 It is now possible to associate application-specific data to a project
719 tree. In particular, this is used in the gprbuild builder to avoid a
720 number of global tables and htables, especially now that there can be
721 several project trees loaded at once because of aggregate projects.
722 (Debug_Name): new procedure.
723 * projects.texi: Clarify syntax of "**" for Source_Dirs
724
725 2011-08-03 Emmanuel Briot <briot@adacore.com>
726
727 * prj.ads, makeutl.adb, makeutl.ads (Queue.Insert): now also inserts
728 the "roots" for a main.
729 (Fill_From_Project): add support for aggregate projects. Main units
730 in aggregated projects are now automatically added in the list of
731 files to build (although this fails later on in gprbuild, because
732 these files are not using the root proejct tree, so this needs
733 further cleanup)
734 * gcc-interface/Make-lang.in: Update dependencies.
735
736 2011-08-03 Yannick Moy <moy@adacore.com>
737
738 * sem_ch4.adb (Analyze_Conditional_Expression): only allow boolean
739 conditional expression in ALFA.
740 * sem_res.adb (Resolve_Conditional_Expression): mark non-boolean
741 expressions as not in ALFA.
742
743 2011-08-03 Robert Dewar <dewar@adacore.com>
744
745 * a-cofove.adb: Minor reformatting.
746
747 2011-08-03 Emmanuel Briot <briot@adacore.com>
748
749 * make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads
750 (Insert_Project_Sources, Insert_withed_Sources_For): moved from the
751 gprbuild sources.
752 These packages are more logically placed in the Queue package, since
753 they manipulate the queue. It is also likely that they can be adapted
754 for gnatmake, thus sharing more code.
755 (Finish_Program, Fail_Program): moved from the gprbuild sources, so
756 that we could move the above.
757
758 2011-08-03 Emmanuel Briot <briot@adacore.com>
759
760 * errutil.adb (Finalize): clean up the list of error messages on exit.
761 Calling this subprogram multiple times will no longer show duplicate
762 error messages on stderr.
763
764 2011-08-03 Emmanuel Briot <briot@adacore.com>
765
766 * g-comlin.adb, g-comlin.ads (Set_Command_Line): ignore the parameter
767 Getopt_Switches when we have already define a command line
768 configuration.
769
770 2011-08-03 Yannick Moy <moy@adacore.com>
771
772 * sem_ch11.adb (Analyze_Raise_xxx_Error): do not mark such nodes as not
773 in ALFA. Instead, they are considered as assertions to prove.
774 * sem_ch4.adb (Analyze_Conditional_Expression): do not always mark such
775 nodes as not in ALFA. Instead, include conditional expressions in ALFA
776 if they have no ELSE part, or if they occur in pre- and postconditions,
777 where the Condition cannot have side-effects in ALFA
778 (Analyze_Membership_Op): do not mark such nodes as not in ALFA
779 (Analyze_Type_Conversion): do not always mark such nodes as not in ALFA.
780 Instead, include type conversion between scalar types in ALFA.
781 * sem_ch6.adb (Process_Formals): correctly mark a parameter in ALFA
782 if-and-only-if its type is in ALFA.
783
784 2011-08-03 Thomas Quinot <quinot@adacore.com>
785
786 * scos.adb, get_scos.adb, put_scos.adb
787 New code letter for decisions: G (entry guard)
788 * par_sco.adb
789 (Traverse_Subprogram_Body): Rename to...
790 (Traverse_Subprogram_Or_Task_Body): New subrpogram.
791 (Traverse_Protected_Body): New subprogram
792 (Traverse_Declarations_Or_Statements): Add traversal of task bodies,
793 protected bodies and entry bodies.
794
795 2011-08-03 Yannick Moy <moy@adacore.com>
796
797 * einfo.adb, einfo.ads (Is_Postcondition_Proc): new flag for procedure
798 entities with get/set subprograms, which is set on procedure entities
799 generated by the compiler for a postcondition.
800 * sem_ch6.adb (Process_PPCs): set new flag on postcondition procedures
801 * alfa.adb, alfa.ads (Get_Entity_For_Decl): new function returning the
802 entity for a declaration
803 (Get_Unique_Entity_For_Decl): new function returning an entity which
804 represents a declaration, so that matching spec and body have the same
805 entity.
806
807 2011-08-03 Robert Dewar <dewar@adacore.com>
808
809 * a-except-2005.adb, a-cfhama.adb, a-cfhase.adb, a-cfhase.ads,
810 a-cforma.adb, a-cforse.ads, a-cforse.adb: Minor reformatting
811
812 2011-08-03 Yannick Moy <moy@adacore.com>
813
814 * lib-xref-alfa.adb (Detect_And_Add_ALFA_Scope): make the subprogram
815 library-level because retriction No_Implicit_Dynamic_Code in the
816 front-end prevents its definition as a local subprogram
817 (Traverse_Compilation_Unit): extract new procedure from Add_ALFA_File,
818 for reuse in other contexts
819 (Traverse_Declarations_Or_Statements,
820 Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
821 Traverse_Package_Declaration, Traverse_Subprogram_Body): make all these
822 procedures take a callback parameter to be called on all declarations
823 * lib-xref.ads
824 (Traverse_All_Compilation_Units): new generic function to traverse a
825 compilation unit and call a callback parameter on all declarations
826
827 2011-08-03 Javier Miranda <miranda@adacore.com>
828
829 * sem_prag.adb (Process_Interface_Name): Allow duplicated export names
830 in Java since they are always enclosed in a namespace that
831 differentiates them, and overloaded entities are supported by the VM.
832
833 2011-08-03 Ed Schonberg <schonberg@adacore.com>
834
835 * checks.adb (Determine_Range): If a computed bound of an operation is
836 outside the range of the base type of the expression, and overflow
837 checks are enabled, the result is unknown and cannot be used for any
838 subsequent constant folding.
839 * sem_eval.adb (Compile_Time_Compare): if the bounds of one operand are
840 unknown, so is the result of the comparison.
841
842 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
843
844 * a-except-2005.adb (Raise_From_Controlled_Operation): Add new formal
845 From_Abort. When finalization was triggered by an abort, propagate
846 Standard'Abort_Signal rather than Program_Error.
847 * a-except-2005.ads (Raise_From_Controlled_Operation): Add new formal
848 From_Abort.
849 * a-except.adb (Raise_From_Controlled_Operation): Add new formal
850 From_Abort. When finalization was triggered by an abort, propagate
851 Standard'Abort_Signal rather than Program_Error.
852 * a-except.ads:(Raise_From_Controlled_Operation): Add new formal
853 From_Abort.
854 * exp_ch7.adb:(Build_Adjust_Or_Finalize_Statements): New local variable
855 Abort_Id. Update the calls to Build_Object_Declarations and
856 Build_Raise_Statement to include Abort_Id.
857 (Build_Adjust_Statements): New local variable Abort_Id. Update the
858 calls to Build_Object_Declarations and Build_Raise_Statement to include
859 Abort_Id.
860 (Build_Finalize_Statements): New local variable Abort_Id. Update the
861 calls to Build_Object_Declarations and Build_Raise_Statement to include
862 Abort_Id.
863 (Build_Components): Create an entity for Abort_Id when exceptions are
864 allowed on the target.
865 (Build_Finalizer): New local variable Abort_Id.
866 (Build_Initialize_Statements): New local variable Abort_Id. Update the
867 calls to Build_Object_Declarations and Build_Raise_Statement to include
868 Abort_Id.
869 (Build_Object_Declarations): Add new formal Abort_Id. Create the
870 declaration of flag Abort_Id to preserve the original abort status
871 before finalization code is executed.
872 (Build_Raise_Statement): Add new formal Abort_Id. Pass Abort_Id to
873 runtime routine Raise_From_Controlled_Operation.
874 (Create_Finalizer): Update the call to Build_Raise_Statement to include
875 Abort_Id. Update the call to Build_Object_Declarations to include
876 Abort_Id. Update the layout of the finalizer body.
877 (Make_Handler_For_Ctrl_Operation): Add an actual for From_Abort.
878 (Process_Transient_Objects): New local variable Abort_Id. Remove the
879 clunky code to create all flags and objects related to
880 exception propagation and replace it with a call to
881 Build_Object_Declarations. Update the call to Build_Raise_Statement to
882 include Abort_Id.
883 * exp_ch7.ads (Build_Object_Declarations): Moved from body to spec.
884 Add new formal Abort_Id and associated comment on its use.
885 (Build_Raise_Statement): Add new formal Abort_Id and associated comment
886 on its use.
887 * exp_intr.adb (Expand_Unc_Deallocation): New local variable Abort_Id.
888 Remove the clunky code to create all flags and objects related to
889 exception propagation and replace it with a call to
890 Build_Object_Declarations. Update the call to Build_Raise_Statement.
891
892 2011-08-03 Eric Botcazou <ebotcazou@adacore.com>
893
894 * s-tassta.adb: Fix minor typos.
895
896 2011-08-03 Robert Dewar <dewar@adacore.com>
897
898 * rtsfind.ads, makeutl.ads, prj.ads, prj.adb, make.adb,
899 lib-writ.adb, makeutl.adb, s-soflin.ads, clean.adb: Minor reformatting.
900
901 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
902
903 * exp_ch7.adb (Create_Finalizer): Treat freeze nodes in similar fashion
904 to packages. This ensures that the finalizer body will not end up
905 inside the freeze node.
906 (Process_Declarations): Add code to detect whether a freeze node has a
907 nested finalization collection.
908
909 2011-08-03 Pascal Obry <obry@adacore.com>
910
911 * g-awk.adb, g-awk.ads: Make GNAT.AWK API compatible with Ada 2005.
912 (Current_Session): Return a not null access to Session_Type.
913 (Default_Session): Likewise.
914
915 2011-08-03 Robert Dewar <dewar@adacore.com>
916
917 * a-cfdlli.adb, bindgen.adb, exp_ch4.adb, exp_ch13.adb, sem_warn.adb,
918 exp_ch3.adb, exp_ch3.ads: Minor reformatting.
919
920 2011-08-03 Pascal Obry <obry@adacore.com>
921
922 * g-awk.ads: Minor comment fix.
923
924 2011-08-03 Sergey Rybin <rybin@adacore.com>
925
926 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
927 the tree structure related to discriminant constraints.
928 Original_Discriminant cannot be used any more for computing the
929 defining name for the reference to a discriminant.
930
931 2011-08-03 Ed Schonberg <schonberg@adacore.com>
932
933 * sem_disp.adb (Is_Tag_Indeterminate): If the return type of the
934 function is not visibly tagged, this is not a dispatching call and
935 therfore is not Tag_Indeterminate, even if the function is marked as
936 dispatching on result.
937
938 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
939
940 * exp_ch13.adb: Add with and use clauses for Restrict and Rident.
941 (Expand_N_Free_Statement): Add a guard to protect against run-times
942 which do not support controlled types.
943 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Add a guard to protect
944 against run-times which do not support controlled types.
945 * exp_ch4.adb (Complete_Controlled_Allocation): Add a guard to protect
946 against run-times which do not support controlled types.
947 * exp_ch7.adb (Build_Finalization_Collection): Add a guard to protect
948 against run-times which do not support controlled types.
949 * exp_util.adb (Needs_Finalization): Code reformatting. Add a guard to
950 protect against run-times which do not support controlled types.
951
952 2011-08-03 Eric Botcazou <ebotcazou@adacore.com>
953
954 * exp_intr.adb: Put back with and use clauses for Exp_Ch11.
955 (Expand_Unc_Deallocation): Expand the AT_END handler at the very end.
956
957 2011-08-03 Ed Schonberg <schonberg@adacore.com>
958
959 * exp_ch5.adb (Expand_Iterator_Loop): indicate that the cursor is
960 modified in the source, to prevent spurious warnings when compiling
961 with -gnatg.
962
963 2011-08-03 Thomas Quinot <quinot@adacore.com>
964
965 * a-except-2005.adb: Minor reformatting.
966
967 2011-08-03 Ed Schonberg <schonberg@adacore.com>
968
969 * sem_warn.adb (Check_One_Unit): if the only mention of a withed unit
970 is a renaming declaration in the private part of a package, do not emit
971 a warning that the with_clause could be moved because the renaming may
972 be used in the body or in a child unit.
973
974 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
975
976 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
977 Propagate the Comes_From_Source attribute from the original return
978 object to the renaming.
979
980 2011-08-03 Jose Ruiz <ruiz@adacore.com>
981
982 * exp_ch7.adb (Build_Raise_Statement): Do not call
983 Raise_From_Controlled_Operation when this routine is not present in
984 the run-time library.
985 (Cleanup_Protected_Object, Cleanup_Task): For restricted run-time
986 libraries (Ravenscar), tasks are non-terminating, and protected objects
987 and tasks can only appear at library level, so we do not want
988 finalization of protected objects nor tasks.
989 * exp_intr.adb: Minor clarification in comment.
990 bindgen.adb (Gen_Adainit_Ada, Gen_Main_C, Gen_Output_File_Ada,
991 Gen_Output_File_C): Remove references to finalization of library-level
992 objects when using restricted run-time libraries.
993
994 2011-08-03 Ed Schonberg <schonberg@adacore.com>
995
996 * sem_ch3.adb (Build_Discriminant_Constraints): Set
997 Original_Discriminant only if the parent type is a generic formal.
998
999 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
1000
1001 * exp_ch13.adb: Add with and use clause for Targparm;
1002 (Expand_N_Free_Statement): Prevent the generation of a custom
1003 Deallocate on .NET/JVM targets since this requires pools and address
1004 arithmetic.
1005 * exp_ch4.adb (Expand_Allocator_Expression): When compiling for
1006 .NET/JVM targets, attach the newly allocated object to the access
1007 type's finalization collection. Do not generate a call to
1008 Set_Finalize_Address_Ptr on .NET/JVM because this routine does not
1009 exist in the runtime.
1010 (Expand_N_Allocator): When compiling for .NET/JVM targets, do not
1011 create a custom Allocate for object that do not require initialization.
1012 Attach a newly allocated object to the access type's finalization
1013 collection on .NET/JVM.
1014 * exp_ch5.adb (Make_Tag_Ctrl_Assignment): Add special processing for
1015 assignment of controlled types on .NET/JVM. The two hidden pointers
1016 Prev and Next and stored and later restored after the assignment takes
1017 place.
1018 * exp_ch6.adb (Expand_Call): Add local constant Curr_S. Add specialized
1019 kludge for .NET/JVM to recognize a particular piece of code coming from
1020 Heap_Management and change the call to Finalize into Deep_Finalize.
1021 * exp_ch7.adb (Build_Finalization_Collection): Allow the creation of
1022 finalization collections on .NET/JVM only for types derived from
1023 Controlled. Separate the association of storage pools with a collection
1024 and only allow it on non-.NET/JVM targets.
1025 (Make_Attach_Call): New routine.
1026 (Make_Detach_Call): New routine.
1027 (Process_Object_Declarations): Suppress the generation of
1028 build-in-place return object clean up code on .NET/JVM since it uses
1029 pools.
1030 * exp_ch7.ads (Make_Attach_Call): New routine.
1031 (Make_Detach_Call): New routine.
1032 * exp_intr.adb Add with and use clause for Targparm.
1033 (Expand_Unc_Deallocation): Detach a controlled object from a collection
1034 on .NET/JVM targets.
1035 * rtsfind.ads: Add entries RE_Attach, RE_Detach and
1036 RE_Root_Controlled_Ptr to tables RE_Id and RE_Unit_Table.
1037 * snames.ads-tmpl: Add name Name_Prev. Move Name_Prev to the special
1038 names used in finalization.
1039
1040 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
1041
1042 * a-fihema.adb: Add with and use clauses for System.Soft_Links.
1043 (Attach, Detach): Lock the current task when chaining an object onto a
1044 collection.
1045
1046 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
1047
1048 * a-except.adb, a-except-2005.adb (Raise_From_Controlled_Operation):
1049 Rewritten to create the message strings when the exception is not
1050 raised by an abort during finalization.
1051 * a-except.ads, a-except-2005.ads: Add pragma Export for procedure
1052 Raise_From_Controlled_Operation and update its associated comment.
1053 * a-fihema.ads, a-fihema.adb: New GNAT unit.
1054 Ada.Finalization.Heap_Management provides key functionality
1055 associated with controlled objects on the heap, their creation,
1056 finalization and reclamation. Type Finalization_Collection is
1057 effectively a wrapper which sits ontop of a storage pool and performs
1058 all necessary bookkeeping for all the objects it contains. Each
1059 access-to-controlled or access-to-class-wide type receives a collection
1060 as part of its expansion. The compiler generates buffer code and
1061 invokes Allocate / Deallocate to create and destroy allocated
1062 controlled objects.
1063 * a-finali.adb ("="): Removed.
1064 * a-finali.ads ("="): Removed. Controlled types no longer carry hidden
1065 fields Prev and Next.
1066 * ali.adb (Scan_ALI): Add parsing code to process PF / Has_Finalizer.
1067 A library unit with at least one controlled object on the library level
1068 has a special finalizer which is invoked by the binder. To signal this,
1069 ali files carry field PF.
1070 * ali.ads: New field in type Unit_Record called Has_Finalizer. Add
1071 associated comment on field usage.
1072 * a-tags.adb (Get_RC_Offset): Removed.
1073 (Needs_Finalization): New routine.
1074 * a-tags.ads: Update the structure of the GNAT dispatch tables.
1075 Dispatch tables now carry field Needs_Finalization which provides
1076 runtime indication whether a type is controlled or has controlled
1077 components or both. Remove field RC_Offset.
1078 (Get_RC_Offset): Removed along with its associated pragma Export.
1079 Since tagged types with controlled components no longer carry hidden
1080 field _controller, the special mechanism to retrieve its location is no
1081 longer needed.
1082 (Needs_Finalization): New routine.
1083 * atree.ads, atree.adb (Elist24): New routine.
1084 (Set_Elist24): New routine.
1085 * atree.h: Add a define clause for Elist24.
1086 * bindgen.adb New library-level variable Lib_Final_Built.
1087 (Gen_Adafinal_Ada): Reimplemented. Depending on the restrictions or the
1088 presence of a VM target, the routine generates calls to the proper
1089 library finalization routine.
1090 (Gen_Adainit_Ada): Import Finalize_Library_Objects only on non-VM
1091 targets. Set the correct library finalization routine depending on
1092 whether the library has controlled objects or this is a VM compilation.
1093 (Gen_Finalize_Library_Ada): New routine. This procedure generates calls
1094 to library-level finalizers of compiled units in reverse order of
1095 elaboration. It also produces exception management code and reraises a
1096 potential exception after all units have been finalized.
1097 (Gen_Finalize_Library_C): New routine. This procedure generates calls to
1098 library-level finalizers of compiled units in reverse order of
1099 elaboration.
1100 (Gen_Finalize_Library_Defs_C): New routine. This procedure generates the
1101 definitions of all library-level finalizers available to the compilation
1102 (Gen_Main_Ada): Directly call Adafinal which now contails all target
1103 dependent code.
1104 (Gen_Main_C): Add new local constant Needs_Library_Finalization. Call
1105 System.Standard_Library.Adafinal directly. If the library needs
1106 finalization actions, create the sequence of finalization calls.
1107 (Gen_Output_File_Ada): Alphabetize local variables and constants.
1108 Generate a with clause for System.Soft_Links when compiling for a VM.
1109 Remove the code which imports System.Standard_Library.Adafinal as
1110 Do_Finalize. Generate the library finalization routine.
1111 (Gen_Output_File_C): Add new local constant Needs_Library_Finalization.
1112 If the library needs finalization actions, create all the definitions
1113 of library- level finalizers.
1114 (Has_Finalizer): New routine. Determines whether at least one compiled
1115 unit has a library-level finalizer.
1116 Add type Qualification_Mode.
1117 (Set_Unit_Name): Add a formal which controls the replacement of a dot.
1118 * einfo.adb: New usage of field 15 as Return_Flag.
1119 Remove Finalization_Chain_Entity from the usages of field 19.
1120 Remove Associated_Final_Chain from the usages of field 23.
1121 New usage of field 23 as Associated_Collection.
1122 New usage of field 24 as Finalizer.
1123 New usage of flag 252 as Is_Processed_Transient.
1124 (Associated_Final_Chain): Removed.
1125 (Associated_Collection): New routine.
1126 (Finalization_Chain_Entity): Removed.
1127 (Finalizer): New routine.
1128 (Is_Finalizer): New routine.
1129 (Is_Processed_Transient): New routine.
1130 (Return_Flag): New routine.
1131 (Set_Associated_Final_Chain): Removed.
1132 (Set_Associated_Collection): New routine.
1133 (Set_Finalization_Chain_Entity): Removed.
1134 (Set_Finalizer): New routine.
1135 (Set_Is_Processed_Transient): New routine.
1136 (Set_Return_Flag): New routine.
1137 (Write_Entity_Flags): Include Is_Processed_Transient to the list of
1138 displayed flags.
1139 (Write_Field8_Name): Alphabetize the output.
1140 (Write_Field11_Name): Alphabetize the output.
1141 (Write_Field12_Name): Alphabetize the output.
1142 (Write_Field13_Name): Alphabetize the output.
1143 (Write_Field14_Name): Alphabetize the output.
1144 (Write_Field15_Name): Alphabetize the output.
1145 (Write_Field16_Name): Alphabetize the output.
1146 (Write_Field17_Name): Alphabetize the output.
1147 (Write_Field18_Name): Alphabetize the output.
1148 (Write_Field19_Name): Alphabetize the output. Remove the output of
1149 Finalization_Chain_Entity.
1150 (Write_Field20_Name): Alphabetize the output.
1151 (Write_Field21_Name): Alphabetize the output.
1152 (Write_Field22_Name): Alphabetize the output.
1153 (Write_Field23_Name): Alphabetize the output. Remove the output of
1154 Associated_Final_Chain. Add output for Associated_Collection.
1155 (Write_Field24_Name): Alphabetize the output.
1156 (Write_Field25_Name): Add output for Finalizer.
1157 (Write_Field26_Name): Alphabetize the output.
1158 (Write_Field27_Name): Alphabetize the output.
1159 (Write_Field28_Name): Alphabetize the output.
1160 * einfo.ads: Add new field description for Associated_Collection and
1161 its uses in nodes.
1162 Remove Associated_Final_Chain and its uses in nodes.
1163 Remove Finalization_Chain_Entity and its uses in nodes.
1164 Add new field description for Finalizer and its uses in nodes.
1165 Add new synthesized attribute Is_Finalizer.
1166 Add new flag description for Is_Processed_Transient and its uses in
1167 nodes.
1168 Add new field description for Return_Flag and its uses in nodes.
1169 (Associated_Final_Chain): Removed along with its pragma Inline.
1170 (Associated_Collection): New routine and pragma Inline.
1171 (Finalization_Chain_Entity): Removed along with its pragma Inline.
1172 (Finalizer): New routine and pragma Inline.
1173 (Is_Finalizer): New routine and pragma Inline.
1174 (Is_Processed_Transient): New routine and pragma Inline.
1175 (Return_Flag): New routine and pragma Inline.
1176 (Set_Associated_Final_Chain): Removed along with its pragma Inline.
1177 (Set_Associated_Collection): New routine and pragma Inline.
1178 (Set_Finalization_Chain_Entity): Removed along with its pragma Inline.
1179 (Set_Finalizer): New routine and pragma Inline.
1180 (Set_Is_Processed_Transient): New routine and pragma Inline.
1181 (Set_Return_Flag): New routine and pragma Inline.
1182 * exp_aggr.adb: Alphabetize subprograms.
1183 (Build_Array_Aggr_Code): Remove formal Flist and its associated comment.
1184 (Build_Record_Aggr_Code): Remove formals Flist and Obj along with their
1185 associated comments. Remove local variables External_Final_List and
1186 Attach.
1187 Rename Ctrl_Stuff_Done to Finalization_Done. Rename local variable A to
1188 Ancestor. Remove the retrieval of finalization lists. Update the call to
1189 Make_Adjust_Call.
1190 (Convert_Aggr_In_Allocator): Remove the retrieval of finalization
1191 lists. Update the call to Late_Expansion.
1192 (Convert_Aggr_In_Assignment): Update the call to Late_Expansion.
1193 (Convert_Aggr_In_Object_Decl): Update the call to Late_Expansion.
1194 (Gen_Assign): Remove the retrieval of the finalization list used to
1195 build the assignment. Update the calls to Make_Init_Call and
1196 Make_Adjust_Call.
1197 (Gen_Ctrl_Actions_For_Aggr): Renamed to Generate_Finalization_Actions.
1198 Remove the mechanism to determine attachment levels and finalization
1199 list retrieval. Remove the processing for coextensions.
1200 (Init_Controller): Removed. Controllers no longer exist.
1201 (Late_Expansion): Remove formals Flist and Obj along with their
1202 associated comments. Update the calls to Build_Record_Aggr_Code and
1203 Build_Array_Aggr_Code.
1204 * exp_ch13.adb (Expand_N_Free_Statement): New routine.
1205 (Expand_N_Freeze_Entity): Add special processing for finalizers which
1206 appear in entry bodies, protected subprograms and task bodies.
1207 * exp_ch13.ads (Expand_N_Free_Statement): New routine.
1208 * exp_ch3.adb (Add_Final_Chain): Removed.
1209 (Build_Array_Init_Proc): Alphabetize local variables.
1210 (Build_Assignment): Alphabetize local variables. Update the call to
1211 Maked_Adjust_Call.
1212 (Build_Class_Wide_Master): Rename local variables to better reflect
1213 their role.
1214 (Build_Discriminant_Assignments): Code reformatting.
1215 (Build_Init_Call_Thru): Code reformatting.
1216 (Build_Init_Procedure): Code reformatting. Generate a special version
1217 of Deep_Finalize which is capable of finalizing all initialized
1218 components and ignore the rest.
1219 (Build_Init_Statements): Rename local variables to better reflect their
1220 role.
1221 Reimplement the mechanism to include the creation and update of an index
1222 variable called a "counter". It is used as a bookmark for tracing
1223 initialized and non-initialized components.
1224 (Build_Initialization_Call): Remove local variable Controller_Typ.
1225 Alphabetize all local variables. Remove the initialization of the
1226 record controller and update the call to Make_Init_Call.
1227 (Build_Record_Init_Proc): Rename formal Pe to Rec_Ent.
1228 New local variable Counter.
1229 (Constrain_Array): Alphabetize.
1230 (Expand_Freeze_Array_Type): Create a collection instead of a
1231 finalization list.
1232 (Expand_Freeze_Class_Wide_Type): New routine. Creates TSS primitive
1233 Finalize_Address which is used in conjunction with allocated controlled
1234 objects.
1235 (Expand_N_Object_Declaration): Remove the creation of a finalization
1236 list for anonymous access types. Update the calls to Make_Init_Call and
1237 Make_Adjust_Call.
1238 (Expand_Freeze_Record_Type): Remove local variable Flist. Remove the
1239 retrieval of finalization lists. Remove the expansion of the record
1240 controller. Create TSS primitive Finalize_Address used in conjunction
1241 with controlled objects on the heap. Create finalization collections
1242 for access-to-controlled record components.
1243 (Expand_Record_Controller): Removed.
1244 (Freeze_Type): Remove the freezing of record controllers. Freezing of
1245 class-wide types now requires additional processing. Create
1246 finalization collections for access-to-controlled types.
1247 (Increment_Counter): New routine.
1248 (Make_Counter): New routine.
1249 (Make_Eq_If): Remove the mention of Name_uController.
1250 (Make_Predefined_Primitive_Specs): There is no longer need to skip
1251 types coming from System.Finalization_Root.
1252 (Predef_Deep_Spec): Reimplemented to reflect the new parameter profiles.
1253 (Predefined_Primitive_Bodies): There is no longer need to skip types
1254 coming from System.Finalization_Root.
1255 (Stream_Operation_OK): Do not generate stream routines for
1256 type Ada.Finalization.Heap_Management.Finalization_Collection.
1257 * exp_ch3.ads: Alphabetize subprograms.
1258 * exp_ch4.adb: Remove with and use clause for Sem_Ch8.
1259 Add with and use clause for Lib.
1260 (Complete_Coextension_Finalization): Removed.
1261 (Complete_Controlled_Allocation): New routine. Create a finalization
1262 collection for anonymous access-to-controlled types. Create a custom
1263 Allocate which interfaces with the back end and the machinery in
1264 Heap_Management.
1265 (Expand_Allocator_Expression): Add necessary calls to
1266 Complete_Controlled_Allocation. Remove the retrieval of finalization
1267 lists. Update the calls to Make_Adjust_Call. Generate a call to
1268 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
1269 the associated collection.
1270 (Expand_N_Allocator): Remove the processing for dynamic coextensions.
1271 Code clean up. Remove the retrieval of finalization lists and
1272 attachment levels.
1273 Update the call to Make_Init_Call. Generate a call to
1274 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
1275 the associated collection.
1276 (Get_Allocator_Final_List): Removed. Finalization lists are not
1277 available.
1278 (Suitable_Element): Remove the mention of Name_uController.
1279 * exp_ch5.adb: Remove with and use clauses for Ttypes and Uintp.
1280 (Make_Tag_Ctrl_Assignment): Rewritten to simply do a finalization of
1281 the left hand side, carry out the assignment and adjust the left hand
1282 side.
1283 * exp_ch6.adb (Add_Final_List_Actual_To_Build_In_Place_Call): Removed.
1284 (Add_Collection_Actual_To_Build_In_Place_Call): New routine.
1285 (BIP_Formal_Suffix): Rename BIP_Final_List and BIPfinallist to
1286 BIP_Collection and BIPcollection.
1287 (Build_Heap_Allocator): New routine used to allocate the return object
1288 of a build-in-place function onto a collection.
1289 (Expand_Ctrl_Function_Call): Moved from Exp_Ch7.
1290 (Expand_Call): Do not replace direct calls to Deep routines with their
1291 aliases.
1292 (Expand_N_Extended_Return_Statement): Give all variables shorter names
1293 and update their occurrences. Add a special return flag to monitor the
1294 [ab]normal execution of the function. The flag is set right before the
1295 return statement.
1296 Rewrite the mechanism used to allocate a build-in-place return object
1297 on the heap or on a storage pool.
1298 (Is_Direct_Deep_Call): New routine.
1299 (Make_Build_In_Place_Call_In_Allocator): Add a collection to a
1300 build-in-place function call instead of a final list. Build a call to
1301 Set_Finalize_Address_Ptr to decorate the associated collection.
1302 (Make_Build_In_Place_Call_In_Anonymous_Context): Create a temporary in
1303 order to name the build-in-place function call's result for later
1304 finalization. Add a collection to a build-in-place function call
1305 instead of a final list.
1306 (Make_Build_In_Place_Call_In_Assignment): Add a collection to a
1307 build-in-place function call instead of a final list. Remove the code
1308 which moves one final list and transforms it into the actual in a
1309 nested build-in-place call.
1310 (Make_Build_In_Place_Call_In_Object_Declaration): Add a collection to a
1311 build-in-place function call instead of a final list.
1312 (Move_Final_List): Removed.
1313 (Needs_BIP_Collection): New routine.
1314 (Needs_BIP_Final_List): Removed.
1315 * exp_ch6.ads: Replace BIP_Final_List with BIP_Collection in
1316 enumeration type BIP_Formal_Kind.
1317 Update the related comment.
1318 (Needs_BIP_Collection): New routine.
1319 (Needs_BIP_Final_List): Removed.
1320 * exp_ch7.adb: Add with and use clauses for Elists, Exp_Ch6, Stringt
1321 and Ttypes. Remove with and use clauses for Sem_Type. Alphabetize the
1322 majority of subprograms in this unit. Add Name_Finalize_Address to
1323 array Name_Of and TSS_Finalize_Address to array Deep_Name_Of.
1324 (Build_Adjust_Or_Finalize_Statements): Create the adjust or finalization
1325 statements for an array type.
1326 (Build_Adjust_Statements): Create the adjust statements for a record
1327 type.
1328 (Build_Cleanup_Statements): New routine. A procedure which given any
1329 construct containing asynchronous calls, references to _master, or is a
1330 task body, a task allocation or a protected body produces the necessary
1331 runtime calls to clean up these constructs.
1332 (Build_Exception_Handler): New routine.
1333 (Build_Final_List): Removed.
1334 (Build_Finalization_Collection): New routine. A core procedure which
1335 creates a collection to service heap allocated controlled objects
1336 associated with an access-to-controlled type.
1337 (Build_Finalize_Statements): Create the finalization statements for a
1338 record types.
1339 (Build_Finalizer): New routine. A core procedure which given any
1340 construct with declarations and/or statements detects all objects which
1341 need any type of clean up (controlled objects, protected objects) and
1342 generates all necessary code to clean up the said objects in the proper
1343 order.
1344 (Build_Finalizer_Call): New routine.
1345 (Build_Initialize_Statements): Create the initialization statements for
1346 an array type. The generated routine contains code to finalize partially
1347 initialized arrays.
1348 (Build_Object_Declarations): New routine.
1349 (Build_Raise_Statement): New routine.
1350 (Clean_Simple_Protected_Objects): Removed.
1351 (Controller_Component): Removed.
1352 (Enclosing_Function): New routine.
1353 (Expand_Cleanup_Actions): Create a finalizer for a construct which has
1354 either declarations or statements or both.
1355 (Expand_N_Package_Body): Create a finalizer for a non-generic package.
1356 (Expand_N_Package_Declaration): Create a finalizer for a non-generic
1357 package.
1358 (Find_Final_List): Removed.
1359 (Global_Flist_Ref): Removed.
1360 (In_Finalization_Root): Removed.
1361 (Insert_Actions_In_Scope_Around): Determine the range of the transient
1362 scope in terms of tree nodes. Process all transient variables within
1363 that range.
1364 (Make_Adjust_Call): Rewritten. There is no longer an attach call
1365 generated after the adjust.
1366 (Make_Attach_Call): Removed.
1367 (Make_Call): New routine.
1368 (Make_Clean): Removed.
1369 (Make_Deep_Array_Body): Rewritten to simply invoke the appropriate
1370 build routines.
1371 (Make_Deep_Proc): Rewritten to generate the new profile signature used
1372 in Deep routines.
1373 (Make_Deep_Record_Body): Rewritten to simply invoke the appropriate
1374 build routines.
1375 (Make_Final_Call): Modified to simply create a call to either
1376 Deep_Finalize or Finalize.
1377 (Make_Finalize_Address_Body): New routine.
1378 (Make_Finalize_Address_Stmts): New routine. A function which produces
1379 TSS primitive Finalize_Address used in conjunction with heap allocated
1380 controlled objects.
1381 (Make_Handler_For_Ctrl_Operation): Add specialized code for .NET/JVM.
1382 (Make_Init_Call): Rewritten. There is no longer an attach call
1383 generated after initialization.
1384 (Make_Local_Deep_Finalize): New routine.
1385 (Make_Set_Finalize_Address_Ptr_Call): New routine.
1386 (Make_Transient_Block): Remove the finalization list retrieval and
1387 manipulation.
1388 (Needs_Finalization): Moved to Exp_Util.
1389 (Parent_Field_Type): New routine.
1390 (Preprocess_Components): New routine.
1391 (Process_Transient_Objects): New routine.
1392 (Wrap_HSS_In_Block): New routine.
1393 (Wrap_Transient_Declaration): Remove finalization list management and
1394 controller insertion.
1395 (Wrap_Transient_Expression): Code reformatting.
1396 (Wrap_Transient_Statement): Code reformatting.
1397 * exp_ch7.ads (Build_Final_List): Removed.
1398 (Build_Finalization_Collection): New routine.
1399 (Build_Raise_Statement): New routine.
1400 (Controller_Component): Removed.
1401 (Expand_Ctrl_Function_Call): Moved to Exp_Ch6.
1402 (Find_Final_List): Removed.
1403 (In_Finalization_Root): Removed.
1404 (Is_Simple_Protected_Type): Update related comment.
1405 (Make_Adjust_Call): New parameter profile and associated comments.
1406 (Make_Attach_Call): Removed.
1407 (Make_Final_Call): New parameter profile and associated comments.
1408 (Make_Finalize_Address_Body): New routine.
1409 (Make_Init_Call): New parameter profile and associated comments.
1410 (Make_Local_Deep_Finalize): New routine.
1411 (Make_Set_Finalize_Address_Ptr_Call): New routine.
1412 (Needs_Finalization): Moved to Exp_Util.
1413 * exp_ch9.adb (Add_Object_Pointer): Code reformatting.
1414 (Expand_N_Protected_Body): Remove the handling of finalization lists.
1415 (Find_Protection_Type): Moved to Exp_Util.
1416 * exp_disp.adb: Remove with and use clauses for Exp_Ch7.
1417 (Make_DT): Update sequence of dispatch table initialization. Remove the
1418 initialization of field RC_Offset. Add initialization of field Needs_
1419 Finalization.
1420 * exp_intr.adb (Expand_Unc_Deallocation): Code reformatting.
1421 Reimplement how an object is first finalized, then deallocated.
1422 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
1423 Code reformatting.
1424 * exp_tss.ads: Add special suffix for TSS primitive Finalize_Address.
1425 Register TSS_Finalize_Address with type TSS_Names.
1426 * exp_util.adb (Build_Allocate_Deallocate_Proc): New routine. This core
1427 procedure provides the interface between an allocation / deallocation
1428 and the support machinery in Ada.Finalization.Heap_Management.
1429 (Find_Init_Call): Code reformatting.
1430 (Find_Init_Call_In_List): Code reformatting.
1431 (Find_Protection_Type): Moved from Exp_Ch9.
1432 (Find_Prim_Op): Reimplement to add preference of recovered primitive.
1433 (Has_Controlled_Coextensions): Removed.
1434 (Has_Controlled_Objects): New routine.
1435 (In_Library_Level_Package_Body): New routine.
1436 (Insert_Action_After): New routine.
1437 (Is_Finalizable_Transient): New routine. This predicate determines
1438 whether an object declaration is one of the many variants of controlled
1439 transients.
1440 (Is_Null_Access_BIP_Func_Call): New routine.
1441 (Is_Non_BIP_Func_Call): New routine.
1442 (Is_Related_To_Func_Return): New routine.
1443 (Needs_Finalization): Moved from Exp_Ch7.
1444 * exp_util.ads (Build_Allocate_Deallocate_Proc): New routine.
1445 (Find_Protection_Type): Moved from Exp_Ch9.
1446 (Has_Controlled_Coextensions): Removed.
1447 (Has_Controlled_Objects): New routine.
1448 (In_Library_Level_Package_Body): New routine.
1449 (Insert_Action_After): New routine.
1450 (Is_Finalizable_Transient): New routine.
1451 (Is_Null_Access_BIP_Func_Call): New routine.
1452 (Is_Non_BIP_Func_Call): New routine.
1453 (Is_Related_To_Func_Return): New routine.
1454 (Needs_Finalization): Moved from Exp_ch7.
1455 * expander.adb (Expand): Add a case for N_Free_Statement.
1456 * freeze.adb (Freeze_All): Replace the generation of a finalization
1457 list with a collection for access-to-controlled types.
1458 (Freeze_Entity): Code reformatting.
1459 (Freeze_Record_Type): Remove the freezing of a record controller
1460 component.
1461 (Freeze_Subprogram): Code reformatting.
1462 * inline.adb (Cleanup_Scopes): Remove the reset of the scope
1463 finalization list.
1464 * lib-writ.adb (Write_Unit_Information): Output "PF" when a package
1465 has a library-level finalizer.
1466 * lib-writ.ads: Add "PF" to the sequence of unit attributes.
1467 * a-filico.ads, a-filico.adb, s-finimp.ads, s-finimp.adb: Removed.
1468 * Makefile.rtl: Remove a-filico and s-finimp from the list of object
1469 files. Add a-fihema to the list of object files.
1470 * par-ch4.adb:
1471 Alphabetize the associations in type Is_Parameterless_Attribute.
1472 * rtsfind.ads: Ada.Finalization_List.Controller and
1473 System.Finalization_Implementation are no longer a GNAT unit.
1474 Update the range of type Ada_Finalization_Child. Remove the following
1475 recoverable entities:
1476
1477 RE_Attach_To_Final_List
1478 RE_Deep_Tag_Attach
1479 RE_Finalize_List
1480 RE_Finalize_One
1481 RE_Finalizable_Ptr_Ptr
1482 RE_Global_Final_List
1483 RE_Limited_Record_Controller
1484 RE_List_Controller
1485 RE_Move_Final_List
1486 RE_Record_Controller
1487 RE_Simple_List_Controller
1488
1489 Add the following recoverable entities:
1490
1491 RE_Add_Offset_To_Address
1492 RE_Allocate
1493 RE_Base_Pool
1494 RE_Deallocate
1495 RE_Exception_Identity
1496 RE_Finalization_Collection
1497 RE_Finalization_Collection_Ptr
1498 RE_Needs_Finalization
1499 RE_Save_Library_Occurrence
1500 RE_Set_Finalize_Address_Ptr
1501 RE_Set_Storage_Pool_Ptr
1502 RE_Storage_Count
1503 * sem_aggr.adb (Resolve_Record_Aggregate): Remove mention of
1504 Name_uController.
1505 * sem_aux.adb (First_Discriminant): Remove mention of Name_uController.
1506 (First_Stored_Discriminant): Remove the mention of Name_uController.
1507 * sem_aux.ads: Comment reformatting.
1508 * sem_ch10.adb (Build_Chain): Signal the class-wide creation machinery
1509 to redecorate an already existing class-wide type.
1510 (Decorate_Tagged_Type): New parameter profile and associated comment.
1511 Create a "shadow class-wide type" for a shadow entity.
1512 * sem_ch11.adb (Analyze_Exception_Handlers): Remove the dubious setting
1513 of the final chain along with the associated comment.
1514 * sem_ch3.adb (Access_Type_Declaration): Add new local variable
1515 Full_Desig and set it to the full view of the designated type.
1516 Initialize the finalization collection to empty.
1517 (Build_Derived_Record_Type): Alphabetize local variables. Code
1518 reformatting.
1519 (Collect_Fixed_Components): Remove the mention of Name_uController.
1520 (Create_Constrained_Components): Remove the mention of Name_uController.
1521 (Make_Class_Wide_Type): Add specialized code to redecorate an existing
1522 class-wide type of a shadow entity.
1523 (Process_Full_View): Update the machinery which marks type
1524 Limited_Controlled's entity as limited.
1525 * sem_ch4.adb (Analyze_One_Call): Code reformatting.
1526 * sem_ch6.adb (Create_Extra_Formals): Do not generate a finalization
1527 list, instead make a collection build-in-place formal.
1528 * sem_ch8.adb (Analyze_Object_Renaming): Look at the available view of
1529 a designated type in order to establish a match between the renaming
1530 and the renamed entity.
1531 (Find_Selected_Component): Add guard to prevent spurious exceptions
1532 from being raised on .NET/JVM.
1533 * sem_disp.adb (Check_Dispatching_Operation): Include Finalize_Address
1534 to the list of primitive that need special processing. Update arrays
1535 C_Names and D_Names.
1536 (Replace_Types): Handle class-wide types.
1537 * sem_elab.adb (Check_A_Call): Since Deep_Initialize now has a
1538 different parameter profile, look at the first formal.
1539 * sem_prag.adb: Remove with and use clauses for Exp_Ch7. Add with and
1540 use clauses for Exp_Util.
1541 * sem_res.adb: Remove with and use clauses for Elists.
1542 (Propagate_Coextensions): Removed.
1543 (Resolve_Allocator): Do not propagate the list of coextensions from one
1544 allocator to another.
1545 * sem_util.adb (Build_Actual_Subtype_Of_Component): Rename variable
1546 Deaccessed_T to Desig_Typ.
1547 (Enter_Name): Remove the mention of Name_uController.
1548 (Gather_Components): Remove the mention of Name_uController.
1549 (Incomplete_Or_Private_View): New routine.
1550 (Is_Coextension_Root): Removed.
1551 (Is_Fully_Initialized_Type): Remove the mention of Name_uController.
1552 * sem_util.ads (Incomplete_Or_Private_View): New routine.
1553 (Is_Coextension_Root): Removed.
1554 * s-finroo.ads: Remove with clause for Ada.Unchecked_Conversion.
1555 Controlled types are now derived from a null tagged record. Remove
1556 types Finalizable_Ptr, Finalizable and Empty_Root_Controlled.
1557 * sinfo.adb (Coextensions): Removed.
1558 (Set_Coextensions): Removed.
1559 * sinfo.ads: Remove Coextensions from the explanation of node fields
1560 and its uses in nodes.
1561 Update the field usage of N_Allocator.
1562 (Coextensions): Removed along with its pragma Inline.
1563 (Set_Coextensions): Removed along with its pragma Inline.
1564 * snames.ads-tmpl: Remove names
1565
1566 Name_uClean
1567 Name_uController
1568 Name_uFinal_List
1569 Name_uLocal_Final_List
1570 Name_Finalization_Root
1571 Name_Next
1572 Name_Prev
1573
1574 Add names
1575
1576 Name_uFinalizer
1577 Name_Finalize_Address
1578 * s-pooglo.adb (Allocate): Add overriding indicator.
1579 (Deallocate): Add overriding indicator.
1580 (Storage_Size): Add overriding indicator.
1581 * s-soflin.adb (Adafinal_NT): Invoke Finalize_Library_Objects rather
1582 than Finalize_Global_List.
1583 (Null_Finalize_Global_List): Removed.
1584 (Save_Library_Occurrence): New routine.
1585 * s-soflin.ads: Remove variable Finalize_Global_List along with its
1586 initialization. Add variable Finalize_Library_Objects along with its
1587 pragma Export. Add variables Library_Exception and
1588 Library_Exception_Set along with their pragma Export.
1589 (Null_Finalize_Global_List): Removed.
1590 (Save_Library_Occurrence): New routine.
1591 * s-tassta.adb (Finalize_Global_Tasks): Call Finalize_Library_Objects
1592 rather than Finalize_Global_List.
1593 * tbuild.adb (Unchecked_Convert_To): Capture and set the parent field
1594 of the constructed node.
1595
1596 2011-08-03 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1597
1598 * link.c: Include "auto-host.h" before system headers.
1599
1600 2011-08-03 Vincent Celier <celier@adacore.com>
1601
1602 * make.adb (Gnatmake): Add to table Library_Projs only library projects
1603 that are not extended. Do not check if a library project that is
1604 extended should be regenerated. Do not add to table Library_Paths the
1605 libraries that are in extended projects. Link only with libraries that
1606 are in libray projects that are not extended.
1607 * prj-nmsc.adb (Check_Library_Attributes): Do not reset flag Library
1608 for a library project that is extended.
1609
1610 2011-08-03 Gary Dismukes <dismukes@adacore.com>
1611
1612 * sem_ch6.adb (Find_Corresponding_Spec): When in an instance, skip
1613 conforming subprogram renamings that appear to be completions if they
1614 are not fully conformant.
1615 Such renamings are homographs but not completions.
1616 * sem_type.adb (Disambiguate): Handle disambiguation of overloaded
1617 names in a subprogram renaming that appears in an instance.
1618
1619 2011-08-03 Ed Schonberg <schonberg@adacore.com>
1620
1621 * exp_util.adb (Expand_Subtype_From_Expr): if the type is limited but
1622 not immutably limited, build actual subtype from expression to provide
1623 proper bounds to caller.
1624
1625 2011-08-03 Gary Dismukes <dismukes@adacore.com>
1626
1627 * sem_ch8.adb: Minor comment correction.
1628
1629 2011-08-03 Thomas Quinot <quinot@adacore.com>
1630
1631 * exp_strm.adb (Build_Array_Input_Function): In Ada 2005 mode, when
1632 returning a limited array, use an extended return statement.
1633
1634 2011-08-03 Vincent Celier <celier@adacore.com>
1635
1636 * make.adb (Initialize): If --subdirs= is used, but no project file is
1637 specified, attempt to create the specify subdir if it does not already
1638 exist and use it as the object directory as if -D had been specified.
1639
1640 2011-08-03 Arnaud Charlet <charlet@adacore.com>
1641
1642 * s-tpopsp-vms.adb: New file.
1643 * s-taprop-vms.adb: Put back ATCB_Key, since needed by this file on VMS.
1644 * gcc-interfaces/Makefile.in: Use s-taprop-vms.adb on VMS.
1645
1646 2011-08-03 Emmanuel Briot <briot@adacore.com>
1647
1648 * make.adb, makeutl.adb, makeutl.ads, clean.adb (Makeutl.Queue): new
1649 package.
1650
1651 2011-08-03 Yannick Moy <moy@adacore.com>
1652
1653 * cstand.adb (Create_Standard): select Universal_Integer as an ALFA type
1654 * sem_ch3.adb (Array_Type_Declaration): detect array types in ALFA
1655 * sem_util.adb, sem_util.ads (Has_Static_Array_Bounds): new function to
1656 detect that an array has static bounds.
1657
1658 2011-08-03 Thomas Quinot <quinot@adacore.com>
1659
1660 * exp_dist.adb: Minor reformatting.
1661
1662 2011-08-03 Arnaud Charlet <charlet@adacore.com>
1663
1664 * s-taprop-irix.adb, s-taprop-hpux-dce.adb, s-taprop-vms.adb
1665 (ATCB_Key): Removed, not always used.
1666
1667 2011-08-03 Emmanuel Briot <briot@adacore.com>
1668
1669 * gnatcmd.adb, make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads,
1670 clean.adb, prj-conf.adb, prj-env.adb, prj-env.ads (Makeutl): remove
1671 most remaining global variables.
1672
1673 2011-08-03 Robert Dewar <dewar@adacore.com>
1674
1675 * gnatcmd.adb, prj-proc.adb, mlib-prj.adb, prj.adb, makeutl.ads,
1676 prj-util.adb, prj-util.ads, prj-conf.adb, prj-env.adb: Minor
1677 reformatting.
1678
1679 2011-08-03 Javier Miranda <miranda@adacore.com>
1680
1681 * exp_util.adb (Is_VM_By_Copy_Actual): Include N_Slide nodes as actuals
1682 that must be passed by copy in VM targets.
1683
1684 2011-08-03 Emmanuel Briot <briot@adacore.com>
1685
1686 * prj.ads, prj-nmsc.adb (Files_Htable): removed this htable, which
1687 duplicates a similar htable now in the project tree.
1688
1689 2011-08-03 Claire Dross <dross@adacore.com>
1690
1691 * a-cfdlli.adb, a-cfhama.adb, a-cfhase.adb, a-cforma.adb, a-cforse.adb,
1692 a-cofove.adb ("=", Length, Is_Empty, Clear, Assign, Copy, Element,
1693 Replace_Element, Query_Element, Update_Element, Move, Insert, Prepend,
1694 Append, Delete, Delete_First, Delete_Last, Reverse_Element, Swap,
1695 Splice, First, First_Element, Last, Last_Element, Next, Previous, Find,
1696 Reverse_Find, Contains, Has_Element, Iterate, Reverse_Iterate, Capacity,
1697 Reserve_Length, Length, Strict_Equal, Left, Right): Data-structure
1698 update.
1699
1700 2011-08-03 Arnaud Charlet <charlet@adacore.com>
1701
1702 * s-taprop-posix.adb, s-taprop-linux.adb, s-taprop-tru64.adb
1703 (ATCB_Key): Removed, not always used.
1704 * s-tpopsp-posix.adb, s-tpopsp-posix-foreign.adb (ATCB_Key): Moved from
1705 s-taprop-posix.adb.
1706 * s-tpopsp-tls.adb: New file.
1707 * gcc-interface/Makefile.in: Use TLS implementation of s-tpopsp.adb on
1708 x86/x64/ia64/powerpc/sparc Linux.
1709
1710 2011-08-03 Arnaud Charlet <charlet@adacore.com>
1711
1712 * system-aix.ads, system-aix64.ads: Set ZCX_By_Default to True.
1713 * gcc-interface/Makefile.in: Switch to ZCX by default on AIX ports.
1714
1715 2011-08-03 Thomas Quinot <quinot@adacore.com>
1716
1717 * rtsfind.ads, exp_dist.adb, exp_dist.ads
1718 (Build_From_Any_Call, Build_To_Any_Call, Build_TypeCode_Call):
1719 Fix type selection for mapping integer types to PolyORB types.
1720
1721 2011-08-03 Bob Duff <duff@adacore.com>
1722
1723 * sem_ch7.adb: Minor comment clarification.
1724
1725 2011-08-03 Bob Duff <duff@adacore.com>
1726
1727 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): If we get
1728 an error analyzing a choice, skip further processing. Further
1729 processing could cause a crash or cascade errors.
1730
1731 2011-08-03 Emmanuel Briot <briot@adacore.com>
1732
1733 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, mlib-prj.adb,
1734 prj.adb, prj.ads, makeutl.adb, makeutl.ads, clean.adb, prj-nmsc.adb,
1735 prj-util.adb, prj-util.ads, prj-conf.adb, prj-conf.ads, prj-env.adb,
1736 prj-env.ads (Shared_Project_Tree_Data): new type
1737 An aggregate project and its aggregated trees need to share the common
1738 data structures used for lists of strings, packages,... This makes the
1739 code simpler since otherwise we have to pass the root tree (also used
1740 for the configuration file data) in addition to the current project
1741 tree. This also avoids ambiguities as to which tree should be used.
1742 And finally this saves a bit of memory.
1743 (For_Every_Project_Imported): new parameter Tree.
1744 Since aggregated projects are using a different tree, we need to let
1745 the caller know which tree to use to manipulate the returned project.
1746
1747 2011-08-03 Robert Dewar <dewar@adacore.com>
1748
1749 * prj-proc.adb, exp_util.ads, exp_ch9.adb, make.adb, prj-ext.adb,
1750 prj-ext.ads, alfa.ads, sem_ch4.adb, makeutl.adb, makeutl.ads,
1751 lib-xref-alfa.adb, sem_cat.adb, exp_dist.adb, get_alfa.adb,
1752 prj-env.adb, prj-env.ads, prj-tree.adb, alfa.ads: Minor reformatting.
1753
1754 2011-08-03 Javier Miranda <miranda@adacore.com>
1755
1756 * exp_util.adb, sem_aux.adb, exp_util.ads, sem_aux.ads:
1757 Move routine Is_VM_By_Copy_Actual from sem_aux to exp_util.
1758
1759 2011-08-03 Bob Duff <duff@adacore.com>
1760
1761 * sem_ch8.adb (Is_Primitive_Operator_In_Use): Always check In_Use on
1762 the Base_Type.
1763
1764 2011-08-03 Joel Brobecker <brobecker@adacore.com brobecker>
1765
1766 * g-sha256.ads, g-sha512.ads, g-sha1.ads, g-sha224.ads, g-sha384.ads,
1767 g-sehash.ads: Fix typo. Update header.
1768
1769 2011-08-03 Thomas Quinot <quinot@adacore.com>
1770
1771 * exp_ch6.adb (Expand_Actuals): Remove Ada_2005 guard on build-in-place
1772 expansion.
1773
1774 2011-08-03 Gary Dismukes <dismukes@adacore.com>
1775
1776 * sem_ch4.adb (Analyze_Overloaded_Selected_Component): Consider
1777 prefixes of private types along with records, since the selector may be
1778 a discriminant.
1779 * sem_res.adb (Resolve_Selected_Component): Consider prefixes of
1780 private types along with records, since the selector may be a
1781 discriminant.
1782
1783 2011-08-03 Emmanuel Briot <briot@adacore.com>
1784
1785 * prj-pp.adb (Pretty_Print): remove trailing blank line in the file
1786
1787 2011-08-03 Javier Miranda <miranda@adacore.com>
1788
1789 * sem_aux.adb (Is_VM_By_Copy_Actual): Fix wrong use of
1790 Tagged_Type_Expansion.
1791
1792 2011-08-03 Yannick Moy <moy@adacore.com>
1793
1794 * sem_res.adb
1795 (Resolve_Op_Concat_Arg): do not issue a SPARK violation when argument of
1796 concatenation is the name of a constant
1797
1798 2011-08-03 Emmanuel Briot <briot@adacore.com>
1799
1800 * prj-proc.adb, prj-ext.adb, prj-ext.ads, prj-env.adb, prj-env.ads,
1801 prj-tree.adb, prj-tree.ads (Initialize_And_Copy, Copy): new subprograms
1802 (Process_Declarative_Items): new parameter Child_Env.
1803
1804 2011-08-03 Yannick Moy <moy@adacore.com>
1805
1806 * alfa.ads Update format of ALFA section in ALI file in order to add a
1807 mapping from bodies to specs when both are present
1808 (ALFA_Scope_Record): add components for spec file/scope
1809 * get_alfa.adb (Get_ALFA): read the new file/scope for spec when present
1810 * lib-xref-alfa.adb
1811 (Collect_ALFA): after all scopes have been collected, fill in the spec
1812 information when relevant
1813 * put_alfa.adb (Put_ALFA): write the new file/scope for spec when
1814 present.
1815
1816 2011-08-03 Eric Botcazou <ebotcazou@adacore.com>
1817
1818 * inline.adb (Add_Inlined_Subprogram): Do not consider the enclosing
1819 code unit to decide whether to add internally generated subprograms.
1820
1821 2011-08-03 Javier Miranda <miranda@adacore.com>
1822
1823 * sem_aux.ads, sem_aux.adb (Is_VM_By_Copy_Actual): New subprogram.
1824 * exp_ch9.adb
1825 (Build_Simple_Entry_Call): Handle actuals that must be handled by copy
1826 in VM targets.
1827
1828 2011-08-03 Emmanuel Briot <briot@adacore.com>
1829
1830 * make.adb, makeutl.adb, makeutl.ads (Make.Switches_Of): now shares
1831 code with Makeutl.Get_Switches.
1832 * prj-tree.adb: Update comment.
1833
1834 2011-08-03 Thomas Quinot <quinot@adacore.com>
1835
1836 * sem_cat.adb (Validate_RCI_Subprogram_Declaration): Reject a remote
1837 subprogram with a limited formal that does not support external
1838 streaming.
1839
1840 2011-08-03 Yannick Moy <moy@adacore.com>
1841
1842 * get_alfa.adb (Get_ALFA): add missing Skip_Spaces at start of
1843 continuation line
1844 * lib-xref-alfa.adb (Add_ALFA_File): split removal of scopes that are
1845 not from current unit in two phases, because it is not possible to
1846 change the table while iterating over its content.
1847 * put_alfa.adb (Put_ALFA): reset current file/scope at each new entity
1848
1849 2011-08-03 Sergey Rybin <rybin@adacore.com>
1850
1851 * vms_data.ads: Add qualifier for gnatmetric --no-static-loop option
1852 * gnat_ugn.texi: Update description of complexity metrics (gnatmetric)
1853
1854 2011-08-03 Ed Schonberg <schonberg@adacore.com>
1855
1856 * sem_res.adb (Resolve_Op_Concat_Arg): if the argument is an aggregate
1857 and the component type is composite, this is ambiguous for predefined
1858 concatenation, but if the node is not overloaded and the entity is a use
1859 -defined function its profile can be used to resolve that aggregate.
1860
1861 2011-08-03 Robert Dewar <dewar@adacore.com>
1862
1863 * exp_ch4.adb: Minor code cleanup.
1864
1865 2011-08-03 Thomas Quinot <quinot@adacore.com>
1866
1867 * exp_dist.adb: Do not generate distribution stubs if serious errors
1868 have been diagnosed.
1869
1870 2011-08-03 Ed Schonberg <schonberg@adacore.com>
1871
1872 * sem_ch4.adb (Try_Primitive_Operation): when checking the validity of
1873 the first formal of a primitive operation, go to the base type to
1874 handle properly an access to a derived type with constrained
1875 discriminants.
1876 * sem_type.adb (Disambiguate): an immediately visible operator hides a
1877 user-defined function that is only use-visible.
1878
1879 2011-08-03 Robert Dewar <dewar@adacore.com>
1880
1881 * sem_aggr.adb, sem_ch3.adb, lib.ads, gnatcmd.adb, prj-proc.adb,
1882 make.adb, lib-writ.adb, prj-part.adb, prj-part.ads, prj-ext.adb,
1883 fname-uf.adb, prj-ext.ads, prj.adb, prj.ads, sem_attr.adb, alfa.adb,
1884 prj-makr.adb, errout.adb, makeutl.adb, makeutl.ads, restrict.ads,
1885 sem_ch6.adb, g-pehage.adb, clean.adb, put_alfa.adb, lib-xref-alfa.adb,
1886 prj-nmsc.adb, prj-nmsc.ads, sem_ch8.adb, prj-pars.ads, exp_aggr.adb,
1887 prj-attr.ads, sem_ch13.adb, get_alfa.adb, prj-env.adb, prj-env.ads,
1888 alfa_test.adb, prj-tree.adb, prj-tree.ads, einfo.ads: Minor reformatting
1889
1890 2011-08-03 Robert Dewar <dewar@adacore.com>
1891
1892 * repinfo.adb (List_Mechanism): Add handling of
1893 Convention_Ada_Pass_By_XXX.
1894 * sem_mech.adb (Set_Mechanism): Ditto.
1895 * sem_prag.adb (Process_Convention): Add entries for
1896 Convention_Ada_Pass_By_XXX.
1897 * snames.adb-tmpl, snames.ads-tmpl: Ditto.
1898
1899 2011-08-03 Pascal Obry <obry@adacore.com>
1900
1901 * makeutl.adb: Minor reformatting.
1902
1903 2011-08-03 Vincent Celier <celier@adacore.com>
1904
1905 * fname-uf.adb
1906 (Get_File_Name) If the file cannot be found when there are no config
1907 pragmas file and May_Fail is True, return No_File instead of the file
1908 name, to be consistent.
1909
1910 2011-08-03 Pascal Obry <obry@adacore.com>
1911
1912 * adaint.c (__gnat_is_executable_file_attr): Avoid access
1913 to null pointer.
1914
1915 2011-08-03 Javier Miranda <miranda@adacore.com>
1916
1917 * sem_ch13.adb
1918 (Same_Representation): In VM targets the representation of arrays with
1919 aliased components differs from arrays with non-aliased components.
1920
1921 2011-08-03 Emmanuel Briot <briot@adacore.com>
1922
1923 * prj-proc.adb, prj-attr.adb, prj-attr.ads (Get_Attribute_Index): do
1924 not systematically lower case attribute indexes that contain no "."
1925 Fix definition of several Naming attributes, which take
1926 a unit name as index and therefore should be case insensitive.
1927 Minor refactoring (reduce length of variable names).
1928
1929 2011-08-03 Emmanuel Briot <briot@adacore.com>
1930
1931 * makeutl.adb, makeutl.ads (Get_Switches): new subprogram.
1932
1933 2011-08-03 Emmanuel Briot <briot@adacore.com>
1934
1935 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, prj-part.adb,
1936 prj-part.ads, switch-m.adb, switch-m.ads, prj-makr.adb, clean.adb,
1937 prj-pars.adb, prj-pars.ads, prj-conf.adb, prj-conf.ads, prj-tree.adb,
1938 prj-tree.ads (Prj.Tree.Environment): new type.
1939
1940 2011-08-03 Emmanuel Briot <briot@adacore.com>
1941
1942 * prj-proc.adb, prj.ads, makeutl.adb, makeutl.ads, prj-conf.adb,
1943 prj-tree.adb, prj-tree.ads (Environment): new type.
1944
1945 2011-08-03 Emmanuel Briot <briot@adacore.com>
1946
1947 * prj-tree.ads: Remove unused variable.
1948
1949 2011-08-03 Yannick Moy <moy@adacore.com>
1950
1951 * restrict.adb (Restriction_Msg): set "SPARK" all in upper case for
1952 issuing messages related to SPARK restriction violation.
1953
1954 2011-08-03 Ed Schonberg <schonberg@adacore.com>
1955
1956 * sem_ch6.adb: guard against error nodes in return statements.
1957
1958 2011-08-03 Arnaud Charlet <charlet@adacore.com>
1959
1960 * errout.adb (Error_Msg_Internal): the main unit has not been read yet,
1961 a warning can only appear on a configuration file, so emit warning
1962 without further checks.
1963
1964 2011-08-03 Arnaud Charlet <charlet@adacore.com>
1965
1966 * s-interr.ads: add overriding keyword.
1967
1968 2011-08-03 Geert Bosch <bosch@adacore.com>
1969
1970 * exp_attr.adb: Fix minor typo.
1971
1972 2011-08-03 Ed Schonberg <schonberg@adacore.com>
1973
1974 * par-ch4.adb: improve error recovery.
1975
1976 2011-08-03 Emmanuel Briot <briot@adacore.com>
1977
1978 * prj-part.adb, prj-part.ads, prj-makr.adb, prj-pars.adb, prj-conf.adb,
1979 prj-env.adb (Prj.Part.Parse): change parameter Always_Errout_Finalize
1980 to Errout_Handling.
1981
1982 2011-08-03 Emmanuel Briot <briot@adacore.com>
1983
1984 * prj-dect.adb (Parse_Attribute_Declaration): make sure we can use
1985 "external" as an attribute name in aggregate projects.
1986
1987 2011-08-03 Jose Ruiz <ruiz@adacore.com>
1988
1989 * s-taprop-vxworks.adb: (Create_Task, Initialize): Ada 2012 pragma CPU
1990 uses CPU numbers starting 1, while VxWorks uses CPU numbers starting
1991 from 0, so we need to adjust.
1992
1993 2011-08-03 Emmanuel Briot <briot@adacore.com>
1994
1995 * prj-proc.adb, prj-ext.adb, prj-ext.ads, makeutl.adb, prj-tree.adb,
1996 prj-tree.ads, gnatcmd.adb, clean.adb (External_References): new type.
1997
1998 2011-08-03 Yannick Moy <moy@adacore.com>
1999
2000 * sem_ch6.adb (New_Overloaded_Entity): only issue error for SPARK
2001 restriction on overloaded entity if the entity is not an operator.
2002
2003 2011-08-03 Yannick Moy <moy@adacore.com>
2004
2005 * sem_ch7.adb, sem_res.adb, sem_attr.adb, restrict.adb,
2006 restrict.ads: Rename remaining Check_Formal_Restriction* into
2007 Check_SPARK_Restriction*.
2008
2009 2011-08-03 Emmanuel Briot <briot@adacore.com>
2010
2011 * prj-proc.adb, prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb,
2012 prj-nmsc.ads, prj-err.adb (Project_Data): now discriminated on its
2013 qualifier.
2014 (Project_Empty): removed
2015 (Empty_Project): new parameter Qualifier
2016 This is used to have fields specific to aggregate projects, cleaner
2017 New field to store the list of aggregated projects.
2018 (Check_Aggregate_Project): removed
2019 (Process_Aggregated_Projects, Free): new subprograms.
2020
2021 2011-08-03 Olivier Hainque <hainque@adacore.com>
2022
2023 * tracebak.c (STOP_FRAME ppc AIX): Stop at null return address as well.
2024
2025 2011-08-03 Ed Schonberg <schonberg@adacore.com>
2026
2027 * sem_ch8.adb (Analyze_Object_Renaming): if the renamed object is an
2028 explicit dereference of an unconstrained type, create a constrained
2029 subtype for it, as is done for function calls that return an
2030 unconstrained type.
2031
2032 2011-08-03 Thomas Quinot <quinot@adacore.com>
2033
2034 * g-pehage.adb (Finalize): Avoid possible double-free.
2035
2036 2011-08-03 Steve Baird <baird@adacore.com>
2037
2038 * exp_attr.adb (Expand_N_Attribute_Reference): Don't expand
2039 Elab_Spec/Body attrs in CodePeer_Mode.
2040
2041 2011-08-03 Javier Miranda <miranda@adacore.com>
2042
2043 * exp_aggr.adb (Flatten): Convert to positional form aggregates whose
2044 low bound is not known at compile time but they have no others choice.
2045 Done because in this case the bounds can be obtained directly from the
2046 aggregate.
2047
2048 2011-08-03 Ed Falis <falis@adacore.com>
2049
2050 * s-tasinf-vxworks.ads: Update comment to reflect 0 indexing of CPUs
2051 on VxWorks SMP. Remove unusable constant ANY_CPU.
2052
2053 2011-08-03 Emmanuel Briot <briot@adacore.com>
2054
2055 * gnatcmd.adb, make.adb, prj-part.adb, prj-part.ads, prj-makr.adb,
2056 clean.adb, prj-nmsc.adb, prj-pars.adb, prj-conf.adb, prj-env.adb,
2057 prj-env.ads (Prj.Env.Initialize_Default_Project_Path,
2058 Prj.Env.Initialize_Empty): new subprograms
2059 (Get_Env, Find_Project): remove parameter Target_Name.
2060
2061 2011-08-03 Gary Dismukes <dismukes@adacore.com>
2062
2063 * sem_ch3.adb (Build_Derived_Record_Type): Test the Derive_Subps formal
2064 as a condition for the delayed call to Derived_Subprograms done for the
2065 case of the rewriting of a derived type that constrains the
2066 discriminants of its parent type.
2067 Avoids redundant subprogram derivations for private subtype derivations.
2068
2069 2011-08-03 Javier Miranda <miranda@adacore.com>
2070
2071 * exp_aggr.adb (Init_Hidden_Discriminants): New subprogram of
2072 Build_Record_Aggr_Code.
2073 (Build_Record_Aggr_Code): Add missing support to initialize hidden
2074 discriminants in extension aggregates.
2075
2076 2011-08-03 Emmanuel Briot <briot@adacore.com>
2077
2078 * prj-pp.adb (Print): also output project qualifiers, since in
2079 particular "aggregate" is mandatory in an aggregate project.
2080
2081 2011-08-03 Emmanuel Briot <briot@adacore.com>
2082
2083 * prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb, prj-env.adb:
2084 (Debug_Output): new function.
2085
2086 2011-08-03 Eric Botcazou <ebotcazou@adacore.com>
2087
2088 * gnat_ugn.texi: Document -Wstack-usage.
2089 * gcc-interface/misc.c (enumerate_modes): Add guard for ghost FP modes.
2090
2091 2011-08-03 Thomas Quinot <quinot@adacore.com>
2092
2093 * sem_prag.adb Issue an error (not a warning) when a C++ type does not
2094 have keyword LIMITED.
2095
2096 2011-08-03 Yannick Moy <moy@adacore.com>
2097
2098 * alfa.adb, alfa.ads, alfa_test.adb: New files.
2099 * ali.adb (Known_ALI_Lines): add 'C' lines (SCO) and 'F' lines (ALFA)
2100 (Scan_ALI): do not issue a fatal error if parsing known lines after Xref
2101 section (does not happen in compiler, only if code directly calls
2102 Scan_ALI).
2103 * get_alfa.adb, get_alfa.ads: New files.
2104 * lib-writ.adb, lib-writ.ads (Write_ALI): output ALFA information if
2105 needed.
2106 * lib-xref-alfa.adb: New file.
2107 * lib-xref.adb, lib-xref.ads
2108 (Xref_Entry): redefine information needed in cross-references for ALFA.
2109 Push ALFA treatments in separated local package.
2110 (Enclosing_Subpragram_Or_Package): treat specially subprogram
2111 identifiers. Return entity of package body instead of spec. Return
2112 Empty for a scope with no location.
2113 (Generate_Reference): adapt to new components for ALFA information.
2114 Remove the need for D references on definitions.
2115 (Is_Local_Reference): moved to ALFA local package
2116 (Output_References): extract subfunction as Extract_Source_Name
2117 (Output_Local_References): remove procedure, replaced by filtering of
2118 cross-references in package ALFA and printing in Put_ALFA.
2119 (Write_Entity_Name): remove procedure
2120 * lib.adb, lib.ads (Extract_Source_Name): extract here function to
2121 print exact name of entity as it appears in source file
2122 (Unit_Ref_Table): make type public for use in Lib.Xref.ALFA
2123 * put_alfa.adb, put_alfa.ads: New files.
2124 * xref_lib.adb (Search_Xref): protect read of cross-references against
2125 reading other sections of the ALI file, in gnatxref
2126 (Search): protect read of cross-references against reading other
2127 sections of the ALI file, in gnatfind.
2128 * gcc-interface/Make-lang.in: Update dependencies.
2129
2130 2011-08-03 Thomas Quinot <quinot@adacore.com>
2131
2132 * sem_ch3.adb: Minor reformatting.
2133
2134 2011-08-03 Jose Ruiz <ruiz@adacore.com>
2135
2136 * s-inmaop-vxworks.adb (Setup_Interrupt_Mask): Do nothing instead of
2137 raising an exception.
2138
2139 2011-08-03 Ed Schonberg <schonberg@adacore.com>
2140
2141 * sem_res.adb (Set_String_Literal_Subtype): if index type is an integer
2142 type, always use 1 as the lower bound or string, even if lower bound of
2143 context is not static, to handle properly null strings in a non-static
2144 context.
2145
2146 2011-08-03 Bob Duff <duff@adacore.com>
2147
2148 * sem_prag.adb (Resolve_Aggregate): An array aggregate with 'others' is
2149 always legal on the right-hand side of an assignment statement; there
2150 is always an applicable index constraint in this case. Therefore, the
2151 check for Pkind = N_Assignment_Statement is now unconditional -- it
2152 doesn't depend on whether Is_Constrained (Typ).
2153
2154 2011-08-03 Robert Dewar <dewar@adacore.com>
2155
2156 * exp_ch5.adb, sem_prag.adb, exp_ch4.adb: Minor reformatting.
2157
2158 2011-08-03 Ed Schonberg <schonberg@adacore.com>
2159
2160 * sem_ch3.adb (Build_Itype_Reference): do not create an itype reference
2161 for an itype created within a generic unit.
2162
2163 2011-08-03 Eric Botcazou <ebotcazou@adacore.com>
2164
2165 * gnat_ugn.texi (Switches for gcc): Make it clearer that -fno-inline
2166 suppresses all inlining.
2167
2168 2011-08-03 Robert Dewar <dewar@adacore.com>
2169
2170 * sem_ch3.adb, sem_res.adb, exp_ch13.adb, exp_disp.adb,
2171 exp_aggr.adb: Minor reformatting.
2172
2173 2011-08-03 Thomas Quinot <quinot@adacore.com>
2174
2175 * exp_ch5.adb (Expand_N_Assignment_Statement): Do not force inlining of
2176 tagged assignment when discriminant checks are suppressed. This is
2177 useless and extremely costly in terms of static stack usage.
2178
2179 2011-08-03 Bob Duff <duff@adacore.com>
2180
2181 * sem_prag.adb (Get_Base_Subprogram): Do not follow Alias for instances
2182 of generics, because this leads to the wrong entity in the wrong scope,
2183 causing (e.g.) pragma Export_Procedure to get an error if the entity is
2184 an instance.
2185 (Process_Interface_Name): Follow Alias for instances of generics, to
2186 correct for the above change.
2187
2188 2011-08-03 Ed Schonberg <schonberg@adacore.com>
2189
2190 * exp_ch4.adb (Expand_N_Selected_Component): If the discriminant value
2191 is an integer literal it is always safe to replace the reference. In
2192 addition, if the reference appears in the generated code for an object
2193 declaration it is necessary to copy because otherwise the reference
2194 might be to the uninitilized value of the discriminant of the object
2195 itself.
2196
2197 2011-08-03 Pascal Obry <obry@adacore.com>
2198
2199 * adaint.c (__gnat_is_executable_file_attr): Fix Win32 circuitry when no
2200 ACL used, in this case we want to check for ending .exe, not .exe
2201 anywhere in the path.
2202
2203 2011-08-03 Sergey Rybin <rybin@adacore.com>
2204
2205 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
2206 the tree structure (semantic decoration of references to record
2207 discriminants).
2208
2209 2011-08-03 Gary Dismukes <dismukes@adacore.com>
2210
2211 * sem_aggr.adb (Analyze_Array_Aggregate): When checking the discrete
2212 choices of a named array aggregate, bail out when any choices are
2213 marked as Errors_Posted.
2214
2215 2011-08-03 Ed Schonberg <schonberg@adacore.com>
2216
2217 * exp_ch13.adb (Expand_N_Freeze_Entity): cleanup determination of scope
2218 in which entity is frozen, to handle properly loop variables in
2219 iterators.
2220
2221 2011-08-03 Ed Schonberg <schonberg@adacore.com>
2222
2223 * sem_res.adb (Set_String_Literal_Subtype): if the lower bound of the
2224 subtype is not static, compute the upper bound using attributes, to
2225 handle properly index types that are not integer types.
2226
2227 2011-08-03 Bob Duff <duff@adacore.com>
2228
2229 * gnat_rm.texi, gnat_ugn.texi: Fix some dangling URLs.
2230 Update copyright notice.
2231
2232 2011-08-03 Ed Schonberg <schonberg@adacore.com>
2233
2234 * sem_ch3.adb (Build_Discriminant_Constraints): Only use
2235 Original_Discriminant if within an instance.
2236 * sem_ch4.adb (Analyze_Selected_Component): Ditto.
2237
2238 2011-08-03 Thomas Quinot <quinot@adacore.com>
2239
2240 * einfo.ads: Minor reformatting.
2241
2242 2011-08-03 Ed Schonberg <schonberg@adacore.com>
2243
2244 * exp_disp.adb (Check_Premature_Freezing): diagnose the presence of a
2245 composite type with an unfrozen subcomponent, in the profile of a
2246 primitive operation.
2247
2248 2011-08-03 Robert Dewar <dewar@adacore.com>
2249
2250 * sem_util.ads, exp_aggr.adb, exp_ch3.adb: Minor reformatting.
2251
2252 2011-08-03 Ed Schonberg <schonberg@adacore.com>
2253
2254 * sem_ch3.adb (Analyze_Object_Declaration): if a constant object of an
2255 unconstrained type with discriminants is initialized with an aggregate,
2256 use the constrained subtype of the aggregate as the type of the object,
2257 because it is immutable, and this allows the back-end to generate no
2258 code for the object declaration.
2259
2260 2011-08-03 Robert Dewar <dewar@adacore.com>
2261
2262 * exp_ch4.adb (Optimize_Length_Check): Fix bad handling of case where
2263 comparison operand is variable, and turns out to be zero or negative.
2264
2265 2011-08-03 Javier Miranda <miranda@adacore.com>
2266
2267 * exp_intr.adb
2268 (Expand_Dispatching_Constructor_Call): Disable expansion of
2269 code required for native targets. Done to avoid generating
2270 references to unavailable runtime entities in VM targets.
2271 * exp_ch3.adb
2272 (Expand_N_Object_Declaration): Add missing support to handle
2273 the explicit initialization of class-wide interface objects.
2274 Fix documentation.
2275
2276 2011-08-03 Matthew Heaney <heaney@adacore.com>
2277
2278 * a-cobove.adb (Merge): Move source onto target, instead of using Assign
2279
2280 2011-08-03 Matthew Heaney <heaney@adacore.com>
2281
2282 * a-cbdlli.adb (Splice): move source items from first to last
2283
2284 2011-08-03 Yannick Moy <moy@adacore.com>
2285
2286 * sem_util.ads: comment added.
2287
2288 2011-08-03 Javier Miranda <miranda@adacore.com>
2289
2290 * exp_aggr.adb
2291 (Expand_Record_Aggregate): In VM targets disable the expansion into
2292 assignments of aggregates whose type is not known at compile time.
2293
2294 2011-08-03 Ed Schonberg <schonberg@adacore.com>
2295
2296 * exp_ch9.adb (Build_Renamed_Formal_Declaration): common procedure for
2297 protected entries and task entries, to build the proper renaming
2298 declaration for entry formals, used in debugging.
2299 * exp_ch2.adb (Expand_Entry_Parameter): handle task and entry
2300 parameters in the same way.
2301
2302 2011-08-02 Robert Dewar <dewar@adacore.com>
2303
2304 * a-direct.adb, sinfo.ads, exp_ch9.adb, scng.adb, sem_util.adb,
2305 sem_util.ads, restrict.ads, par-prag.adb: Minor reformatting and/or
2306 code reorganization.
2307
2308 2011-08-02 Robert Dewar <dewar@adacore.com>
2309
2310 * debug.adb: Debug flag d.P to suppress length comparison optimization
2311 * exp_ch4.adb (Optimize_Length_Comparison): New routine to optimize
2312 comparison of Length by comparing First/Last instead.
2313
2314 2011-08-02 Matthew Heaney <heaney@adacore.com>
2315
2316 * a-cobove.ads: Code clean up.
2317
2318 2011-08-02 Vincent Celier <celier@adacore.com>
2319
2320 * adaint.c (file_names_case_sensitive_cache): New static int.
2321 (__gnat_get_file_names_case_sensitive): Cache the return value in
2322 file_names_case_sensitive_cache at the first invocation, to avoid
2323 multiple calls to getenv.
2324
2325 2011-08-02 Bob Duff <duff@adacore.com>
2326
2327 * sem_ch12.adb (Validate_Derived_Type_Instance): Implement AI05-0218-1.
2328
2329 2011-08-02 Yannick Moy <moy@adacore.com>
2330
2331 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_prag.adb, sem.ads,
2332 sem_util.adb, sem_util.ads, sem_res.adb, sem_ch2.adb, sem_ch4.adb,
2333 sem_ch6.adb, sem_ch11.adb: Add semantic flag In_Pre_Post_Expression to
2334 indicate that we are in a precondition or postcondition. This is used in
2335 Mark_Non_ALFA_Subprogram (renaming of Mark_Non_ALFA_Subprogram_Body) to
2336 decide whether to flag the spec or body of the current subprogram as
2337 not in ALFA.
2338
2339 2011-08-02 Fabien Chouteau <chouteau@adacore.com>
2340
2341 * impunit.adb: Add Ada.Execution_Time.Interrupts in the Ada2012 package
2342 list.
2343 * a-extiin.ads: New file.
2344
2345 2011-08-02 Bob Duff <duff@adacore.com>
2346
2347 * a-direct.adb (Rename): Implement AI05-0231-1. In particular, Rename
2348 now raises Name_Error instead of Use_Error in certain cases. The other
2349 parts of this AI were already implemented properly.
2350
2351 2011-08-02 Vincent Celier <celier@adacore.com>
2352
2353 * link.c: Only import "auto-host.h" when building the gnattools.
2354
2355 2011-08-02 Yannick Moy <moy@adacore.com>
2356
2357 * sem_util.adb: Inter-unit inlining does not work for a subprogram
2358 which calls a local subprogram, so extract subprogram
2359 from Mark_Non_ALFA_Subprogram_Body.
2360
2361 2011-08-02 Javier Miranda <miranda@adacore.com>
2362
2363 * exp_ch9.adb
2364 (Extract_Dispatching_Call): If the type of the dispatching object is an
2365 access type then return an explicit dereference in the Object out-mode
2366 parameter.
2367
2368 2011-08-02 Gary Dismukes <dismukes@adacore.com>
2369
2370 * sem_ch3.adb (Analyze_Subtype_Declaration): Generate range
2371 compatibility checks for all indexes of an array subtype, not just the
2372 first. Reset Has_Dynamic_Range_Check on the subtype before each
2373 potential check to ensure that Insert_Range_Checks will not elide any
2374 of the dynamic checks.
2375
2376 2011-08-02 Yannick Moy <moy@adacore.com>
2377
2378 * par-prag.ad (Process_Restrictions_Or_Restriction_Warnings): recognize
2379 SPARK restriction at parsing time.
2380 * scng.adb (Scan): Generate a token Tok_SPARK_Hide for a SPARK HIDE
2381 directive only if the SPARK restriction is set for this unit.
2382
2383 2011-08-02 Yannick Moy <moy@adacore.com>
2384
2385 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb, sem_util.ads,
2386 sem_res.adb, sem_ch2.adb, sem_ch4.adb, sem_ch6.adb,
2387 sem_ch11.adb: Protect call to Current_Subprogram which might be costly
2388 when repeated. Rename Current_Subprogram_Is_Not_In_ALFA into
2389 Mark_Non_ALFA_Subprogram_Body.
2390 Split body of Mark_Non_ALFA_Subprogram_Body to get body small and
2391 inlined.
2392
2393 2011-08-02 Yannick Moy <moy@adacore.com>
2394
2395 * sem_res.adb: Protect calls to Matching_Static_Array_Bounds which
2396 might be costly.
2397
2398 2011-08-02 Robert Dewar <dewar@adacore.com>
2399
2400 * exp_ch9.adb, exp_sel.adb, restrict.ads, exp_disp.adb, erroutc.ads,
2401 exp_ch3.adb: Minor reformatting.
2402
2403 2011-08-02 Emmanuel Briot <briot@adacore.com>
2404
2405 * adaint.c (__gnat_locate_exec_on_path): only returns executable
2406 files, not any regular file.
2407 (__gnat_locate_file_with_predicate): new subprogram.
2408
2409 2011-08-02 Yannick Moy <moy@adacore.com>
2410
2411 * sinfo.adb, sinfo.ads: Restrict the use of flags
2412 Has_Dynamic_Length_Check and Has_Dynamic_Range_Check to expression
2413 nodes, plus N_Subtype_Declaration for the 2nd one.
2414
2415 2011-08-02 Sergey Rybin <rybin@adacore.com>
2416
2417 * gnat_rm.texi: Ramification of pragma Eliminate documentation
2418 - fix bugs in the description of Source_Trace;
2419 - get rid of UNIT_NAME;
2420
2421 2011-08-02 Javier Miranda <miranda@adacore.com>
2422
2423 * exp_ch9.adb
2424 (Build_Dispatching_Requeue): Adding support for VM targets
2425 since we cannot directly reference the Tag entity.
2426 * exp_sel.adb (Build_K): Adding support for VM targets.
2427 (Build_S_Assignment): Adding support for VM targets.
2428 * exp_disp.adb
2429 (Default_Prim_Op_Position): In VM targets do not restrict availability
2430 of predefined interface primitives to compiling in Ada 2005 mode.
2431 (Is_Predefined_Interface_Primitive): In VM targets this service is not
2432 restricted to compiling in Ada 2005 mode.
2433 (Make_VM_TSD): Generate code that declares and initializes the OSD
2434 record. Needed to support dispatching calls through synchronized
2435 interfaces.
2436 * exp_ch3.adb
2437 (Make_Predefined_Primitive_Specs): Enable generation of predefined
2438 primitives associated with synchronized interfaces.
2439 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
2440 primitives associated with synchronized interfaces.
2441
2442 2011-08-02 Yannick Moy <moy@adacore.com>
2443
2444 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
2445 statements hidden in SPARK if preceded by the HIDE directive
2446 (Parse_Exception_Handlers): mark each exception handler in a sequence of
2447 exception handlers as hidden in SPARK if preceded by the HIDE directive
2448 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
2449 if starting with the HIDE directive
2450 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
2451 starting with the HIDE directive; mark the declarations in a private
2452 part as hidden in SPARK if the private part starts with the HIDE
2453 directive
2454 * restrict.adb, restrict.ads
2455 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
2456 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
2457 argument node belongs to a part which is hidden in SPARK
2458 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
2459 parts in SPARK; protect the possibly costly call to
2460 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
2461 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
2462 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
2463 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
2464 Tok_SPARK_Hide.
2465 (Scan): recognize special comment starting with '#' and followed by
2466 SPARK keyword "hide" as a HIDE directive.
2467
2468 2011-08-02 Yannick Moy <moy@adacore.com>
2469
2470 * types.ads, erroutc.ads: Minor reformatting.
2471
2472 2011-08-02 Vincent Celier <celier@adacore.com>
2473
2474 * link.c: Add response file support for cross platforms.
2475
2476 2011-08-02 Ed Schonberg <schonberg@adacore.com>
2477
2478 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
2479 in an association, set parent field of copy before partial analysis.
2480 * sem_res.adb (Resolve_Slice): create reference to itype only when
2481 expansion is enabled.
2482
2483 2011-08-02 Yannick Moy <moy@adacore.com>
2484
2485 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
2486 for new flag denoting which subprogram bodies are in ALFA
2487 * restrict.adb, sem_ch7.adb: Update comment
2488 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
2489 sem_ch9.adb, sem_res.adb: Add calls to
2490 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
2491 * sem_ch6.adb (Analyze_Function_Return): add calls to
2492 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
2493 middle of the body, and extended return.
2494 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
2495 False when missing return.
2496 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
2497 to True for subprograms whose spec is in ALFA. Remove later on the flag
2498 on the entity used for a subprogram body when there exists a separate
2499 declaration.
2500 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
2501 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
2502 False, otherwise do nothing.
2503
2504 2011-08-02 Robert Dewar <dewar@adacore.com>
2505
2506 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
2507
2508 2011-08-02 Yannick Moy <moy@adacore.com>
2509
2510 * sem_ch4.ads: minor formatting.
2511
2512 2011-08-02 Yannick Moy <moy@adacore.com>
2513
2514 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
2515 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
2516 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
2517 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
2518 opt.ads: cleanup of SPARK mode
2519
2520 2011-08-02 Yannick Moy <moy@adacore.com>
2521
2522 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
2523 types.
2524 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
2525 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
2526 * sem_ch3.adb
2527 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
2528 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
2529 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
2530 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
2531 types.
2532 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
2533 non-static range.
2534 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
2535 functions whose return type is not in ALFA.
2536 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
2537 specifications.
2538 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
2539 parameter's type is not in ALFA.
2540 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
2541 types are in ALFA.
2542
2543 2011-08-02 Ed Schonberg <schonberg@adacore.com>
2544
2545 * sem_ch6 (Analyze_Expression_Function): treat the function as
2546 Inline_Always, and introduce a subprogram declaration for it when it is
2547 not a completion.
2548 * inline.adb (Add_Inlined_Body): recognize bodies that come from
2549 expression functions, so that the back-end can determine whether they
2550 can in fact be inlined.
2551 * sem_util.adb (Is_Expression_Function): predicate to determine whether
2552 a function body comes from an expression function.
2553
2554 2011-08-02 Gary Dismukes <dismukes@adacore.com>
2555
2556 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
2557 null exclusions to test Can_Never_Be_Null on the anonymous access types
2558 of the formals rather than testing the formals themselves. Exclude this
2559 check in cases where the Old_Formal is marked as a controlling formal,
2560 to avoid issuing spurious errors for bodies completing dispatching
2561 operations (due to the flag not getting set on controlling access
2562 formals in body specs).
2563 (Find_Corresponding_Spec): When checking full and subtype conformance of
2564 subprogram bodies in instances, pass Designated and E in that order, for
2565 consistency with the expected order of the formals (New_Id followed by
2566 Old_Id).
2567
2568 2011-08-02 Robert Dewar <dewar@adacore.com>
2569
2570 * sem_ch8.adb: Minor reformatting.
2571
2572 2011-08-02 Ed Schonberg <schonberg@adacore.com>
2573
2574 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
2575 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
2576 primitive operations of class-wide actuals.
2577
2578 2011-08-02 Javier Miranda <miranda@adacore.com>
2579
2580 * exp_atag.ads, exp_atag.adb
2581 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
2582 since its value is implicitly passed in argument Typ.
2583 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
2584 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
2585 Build_Common_Dispatching_Select_Statements.
2586
2587 2011-08-02 Robert Dewar <dewar@adacore.com>
2588
2589 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
2590 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
2591 Minor reformatting.
2592
2593 2011-08-02 Robert Dewar <dewar@adacore.com>
2594
2595 * sem_res.adb: Minor reformatting.
2596 * sem_prag.adb: Minor reformatting.
2597
2598 2011-08-02 Javier Miranda <miranda@adacore.com>
2599
2600 * exp_atag.adb, exp_atags.ads
2601 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
2602 by the tagged type Entity. Required to use this routine in the VM
2603 targets since we do not have available the Tag entity in the VM
2604 platforms.
2605 * exp_ch6.adb
2606 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
2607 Ada.Tags has not been previously loaded.
2608 * exp_ch7.adb
2609 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
2610 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
2611 * sem_aux.adb
2612 (Enclosing_Dynamic_Scope): Add missing support to handle the full
2613 view of enclosing scopes. Required to handle enclosing scopes that
2614 are synchronized types whose full view is a task type.
2615 * exp_disp.adb
2616 (Build_VM_TSDs): Minor code improvement to avoid generating and
2617 analyzing lists with empty nodes.
2618 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
2619 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
2620 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
2621 (Make_Disp_Timed_Select_Body): Add support for VM targets.
2622 (Make_Select_Specific_Data_Table): Add support for VM targets.
2623 (Make_VM_TSD): Generate code to initialize the SSD structure of
2624 the TSD.
2625
2626 2011-08-02 Yannick Moy <moy@adacore.com>
2627
2628 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
2629 cross-references section in ALI.
2630 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
2631 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
2632 Sub).
2633 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
2634 subprogram or package entity of a node
2635 (Is_Local_Reference_Type): new function returns True for references
2636 selected in local cross-references.
2637 (Lt): function extracted from Lt in Output_References
2638 (Write_Entity_Name): function extracted from Output_References
2639 (Generate_Definition): generate reference with type 'D' for definition
2640 of objects (object declaration and parameter specification), with
2641 appropriate locations and units, for use in local cross-references.
2642 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
2643 references of type 'I' for initialization in object definition.
2644 (Output_References): move part of function Lt and procedure
2645 Write_Entity_Name outside of the body. Ignore references of types 'D'
2646 and 'I' introduced for local cross-references.
2647 (Output_Local_References): new procedure to output the local
2648 cross-references sections.
2649 (Lref_Entity_Status): new array defining whether an entity is a local
2650 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
2651 with 'I' type when initialization expression is present.
2652 * get_scos.adb, get_scos.ads: Correct comments and typos
2653
2654 2011-08-02 Javier Miranda <miranda@adacore.com>
2655
2656 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
2657 the JVM target.
2658 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
2659 the JVM target.
2660 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
2661 TSD support.
2662
2663 2011-08-02 Vincent Celier <celier@adacore.com>
2664
2665 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
2666 (No_Space_Img): New function
2667 (Find_Excluded_Sources): When reading from a file, record the file name
2668 and the line number for each excluded source.
2669 (Mark_Excluded_Sources): When reporting an error, if the excluded
2670 sources were read from a file, include file name and line number in
2671 the error message.
2672
2673 2011-08-02 Ed Schonberg <schonberg@adacore.com>
2674
2675 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
2676
2677 2011-08-02 Robert Dewar <dewar@adacore.com>
2678
2679 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
2680
2681 2011-08-02 Javier Miranda <miranda@adacore.com>
2682
2683 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
2684 generation of TSDs to the DOTNET compiler.
2685 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
2686 generation of TSDs to the DOTNET compiler.
2687
2688 2011-08-02 Javier Miranda <miranda@adacore.com>
2689
2690 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
2691 record of all the tagged types declared inside library level package
2692 declarations, library level package bodies or library level subprograms.
2693 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
2694 associated with a given tagged type.
2695 (Build_VM_TSDs): New subprogram.
2696 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
2697 compilation units that are subprograms.
2698 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
2699 compilation units that are package bodies.
2700 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
2701 units that are a package declaration or a package instantiation.
2702 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
2703 reorganization to improve the error generated by the frontend when the
2704 function Ada.Tags.Secondary_Tag is not available.
2705 * rtsfind.ads (RE_Register_TSD): New runtime entity.
2706 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
2707
2708 2011-08-02 Javier Miranda <miranda@adacore.com>
2709
2710 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
2711
2712 2011-08-02 Robert Dewar <dewar@adacore.com>
2713
2714 * s-imenne.ads: Minor reformatting.
2715
2716 2011-08-02 Robert Dewar <dewar@adacore.com>
2717
2718 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
2719 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
2720 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
2721
2722 2011-08-02 Robert Dewar <dewar@adacore.com>
2723
2724 * einfo.ads (Materialize_Entity): Document this is only for renamings
2725 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
2726 required debug information in the case where we transform the object
2727 declaration into a renaming declaration.
2728 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
2729 object
2730 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
2731 Materialize_Entity.
2732
2733 2011-08-02 Robert Dewar <dewar@adacore.com>
2734
2735 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
2736 Suppress_Init_Procs.
2737 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
2738 Suppress_Initialization/Initialization_Suppressed.
2739 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
2740 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
2741 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
2742 * sem_prag.adb: New processing for pragma Suppress_Initialization.
2743
2744 2011-08-02 Robert Dewar <dewar@adacore.com>
2745
2746 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
2747 Minor reformatting.
2748
2749 2011-08-02 Ed Schonberg <schonberg@adacore.com>
2750
2751 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
2752 only have inheritable classwide pre/postconditions.
2753
2754 2011-08-02 Javier Miranda <miranda@adacore.com>
2755
2756 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
2757 * rtsfind.ads (RE_Check_TSD): New runtime entity.
2758 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
2759 checks if the external tag of a type is the same as the external tag
2760 of some other declaration.
2761
2762 2011-08-02 Thomas Quinot <quinot@adacore.com>
2763
2764 * s-taskin.ads: Minor reformatting.
2765
2766 2011-08-02 Emmanuel Briot <briot@adacore.com>
2767
2768 * g-comlin.adb (Display_Help): swap the order in which it prints the
2769 short help and the general usage.
2770
2771 2011-08-02 Ed Schonberg <schonberg@adacore.com>
2772
2773 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
2774 the aspect declarations and attach them to the generic copy for
2775 subsequent analysis.
2776 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
2777 declarations of the generic tree to the new subprogram declarations.
2778 * sem_attr.adb (Check_Precondition_Postcondition): recognize
2779 conditions that apply to a subprogram instance.
2780
2781 2011-08-02 Robert Dewar <dewar@adacore.com>
2782
2783 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
2784
2785 2011-08-02 Ed Schonberg <schonberg@adacore.com>
2786
2787 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
2788 private type with a tagged full view is not derived in the immediate
2789 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
2790
2791 2011-08-02 Robert Dewar <dewar@adacore.com>
2792
2793 * exp_ch4.adb: Minor reformatting.
2794
2795 2011-08-02 Ed Schonberg <schonberg@adacore.com>
2796
2797 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
2798 Ada2012 iterator, the loop will be rewritten during expansion into a
2799 while loop with a cursor and an element declaration. Do not analyze the
2800 body in this case, because if the container is for indefinite types the
2801 actual subtype of the elements will only be determined when the cursor
2802 declaration is analyzed.
2803
2804 2011-08-02 Arnaud Charlet <charlet@adacore.com>
2805
2806 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
2807 size/alignment related attributes in CodePeer_Mode.
2808
2809 2011-08-02 Gary Dismukes <dismukes@adacore.com>
2810
2811 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
2812 Prepend_Element, since this can result in the operation getting the
2813 wrong slot in the full type's dispatch table if the full type has
2814 inherited operations. The incomplete type's operation will get added
2815 to the proper position in the full type's primitives
2816 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
2817 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
2818 dispatching operations, since there are cases where nonprimitive
2819 subprograms can get added to the list of incomplete dependents (such
2820 as subprograms in nested packages).
2821 * sem_ch6.adb (Process_Formals): First, remove test for being in a
2822 private part when determining whether to add a primitive with a
2823 parameter of a tagged incomplete type to the Private_Dependents list.
2824 Such primitives can also occur in the visible part, and should not have
2825 been excluded from being private dependents.
2826 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
2827 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
2828 list of a Taft-amendment incomplete type is a primitive before issuing
2829 an error that the full type must appear in the same unit. There are
2830 cases where nonprimitives can be in the list (such as subprograms in
2831 nested packages).
2832 * sem_disp.adb (Derives_From): Use correct condition for checking that
2833 a formal's type is derived from the type of the corresponding formal in
2834 the parent subprogram (the condition was completely wrong). Add
2835 checking that was missing for controlling result types being derived
2836 from the result type of the parent operation.
2837
2838 2011-08-02 Yannick Moy <moy@adacore.com>
2839
2840 * errout.adb (First_Node): minor renaming
2841 * restrict.adb (Check_Formal_Restriction): put restriction warning on
2842 first node.
2843
2844 2011-08-02 Yannick Moy <moy@adacore.com>
2845
2846 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
2847 before accessing operands.
2848 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
2849 decide whether an initialization expression respects SPARK rules, as
2850 the plain node is the expanded one. This allows for more valid warnings
2851 to be issued.
2852 * gnat_rm.texi: Minor update.
2853
2854 2011-08-02 Arnaud Charlet <charlet@adacore.com>
2855
2856 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
2857 previous change.
2858
2859 2011-08-02 Robert Dewar <dewar@adacore.com>
2860
2861 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
2862
2863 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
2864
2865 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
2866 loop statements and the element renaming declaration with a block when
2867 the element type is controlled.
2868
2869 2011-08-02 Yannick Moy <moy@adacore.com>
2870
2871 * sinfo.ads: Minor formatting.
2872
2873 2011-08-02 Ed Schonberg <schonberg@adacore.com>
2874
2875 * sem_aggr.adb (Add_Association): if the association has a box and no
2876 expression, use the Sloc of the aggregate itself for the new
2877 association.
2878 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
2879 the Original_Node.
2880
2881 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
2882
2883 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
2884 When a container is provided via a function call, generate a renaming
2885 of the function result. This avoids the creation of a transient scope
2886 and the premature finalization of the container.
2887 * exp_ch7.adb (Is_Container_Cursor): Removed.
2888 (Wrap_Transient_Declaration): Remove the supression of the finalization
2889 of the list controller when the declaration denotes a container cursor,
2890 it is not needed.
2891
2892 2011-08-02 Yannick Moy <moy@adacore.com>
2893
2894 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
2895 node is from source, instead of the original node being from source.
2896 * sem_aggr.adb
2897 (Resolve_Array_Aggregate): refine the check for a static expression, to
2898 recognize also static ranges
2899 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
2900 Array_Type_Declaration): postpone the test for the type being a subtype
2901 mark after the type has been resolved, so that component-selection and
2902 expanded-name are discriminated.
2903 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
2904 to distinguish the case of an iteration scheme, so that an error is
2905 issed on a non-static range in SPARK except in an iteration scheme.
2906 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
2907 In_Iter_Schm = True.
2908 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
2909 user-defined operators so that they are allowed in renaming
2910 * sem_ch8.adb
2911 (Find_Selected_Component): refine the check for prefixing of operators
2912 so that they are allowed in renaming. Move the checks for restrictions
2913 on selector name after analysis discriminated between
2914 component-selection and expanded-name.
2915 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
2916 concatenation argument of string type if it is static.
2917 * sem_util.adb, sem_util.ads
2918 (Check_Later_Vs_Basic_Declarations): add a new function
2919 Is_Later_Declarative_Item to decice which declarations are allowed as
2920 later items, in the two different modes Ada 83 and SPARK. In the SPARK
2921 mode, add that renamings are considered as later items.
2922 (Enclosing_Package): new function to return the enclosing package
2923 (Enter_Name): correct the rule for homonyms in SPARK
2924 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
2925 from source (result of expansion) to avoid issuing wrong warnings.
2926
2927 2011-08-02 Ed Schonberg <schonberg@adacore.com>
2928
2929 * errout.adb: On anything but an expression First_Node returns its
2930 argument.
2931
2932 2011-08-02 Pascal Obry <obry@adacore.com>
2933
2934 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
2935
2936 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
2937
2938 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
2939 Set the associated loop as the related expression of internally
2940 generated cursors.
2941 * exp_ch7.adb (Is_Container_Cursor): New routine.
2942 (Wrap_Transient_Declaration): Supress the finalization of the list
2943 controller when the declaration denotes a container cursor.
2944
2945 2011-08-02 Yannick Moy <moy@adacore.com>
2946
2947 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
2948 command line now.
2949 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
2950 expression is a simple expression. This check cannot be performed in
2951 the semantics, so just drop it.
2952 (P_Index_Or_Discriminant_Constraint): move check that the index or
2953 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
2954 semantics. Other cases were previously checked in the semantics.
2955 * par-ch4.adb (P_Name): move checks that a selector name is not
2956 character literal or an operator symbol to Find_Selected_Component in
2957 the semantics
2958 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
2959 declarations are not placed after later declarations in a separate
2960 procedure in Sem_Util (possibly not the best choice?), to be used both
2961 during parsing, for Ada 83 mode, and during semantic analysis, for
2962 SPARK mode.
2963 * par-endh.adb (Check_End): move check that end label is not missing
2964 to Process_End_Label in the semantics
2965 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
2966 the special case for SPARK restriction
2967 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
2968 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
2969 parameter Force to issue the error message even on internal node (used
2970 for generated end label). Call Check_Restriction to check when an error
2971 must be issued. In SPARK mode, issue an error message even if the
2972 restriction is not set.
2973 (Check_Restriction): new procedure with an additional out parameter to
2974 inform the caller that a message has been issued
2975 * sem_aggr.adb: Minor modification of message
2976 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
2977 instead of issuing an error message directly
2978 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
2979 declarations are not placed after later declarations, by calling
2980 Check_Later_Vs_Basic_Declarations
2981 (Analyze_Subtype_Declaration): move here the check that an index or
2982 discriminant constraint must be a subtype mark. Change the check that
2983 a subtype of String must start at one so that it works on subtype marks.
2984 * sem_ch4.adb (Analyze_Call): move here the check that a named
2985 association cannot follow a positional one in a call
2986 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
2987 instead of issuing an error message directly
2988 * sem_ch8.adb (Find_Selected_Component): move here the check that a
2989 selector name is not a character literal or an operator symbol. Move
2990 here the check that the prefix of an expanded name cannot be a
2991 subprogram or a loop statement.
2992 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
2993 procedure called from parsing and semantics to check that basic
2994 declarations are not placed after later declarations
2995 (Process_End_Label): move here the check that end label is not missing
2996
2997 2011-08-02 Arnaud Charlet <charlet@adacore.com>
2998
2999 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
3000 representation clause in codepeer mode, since it confuses CodePeer and
3001 does not bring useful info.
3002
3003 2011-08-02 Ed Falis <falis@adacore.com>
3004
3005 * init.c: initialize fp hw on MILS.
3006
3007 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3008
3009 * errout.adb (First_Node): for bodies, return the node itself (small
3010 optimization). For other nodes, do not check source_unit if the node
3011 comes from Standard.
3012
3013 2011-08-02 Robert Dewar <dewar@adacore.com>
3014
3015 * exp_ch3.adb: Minor comment additions.
3016 * sem_ch13.adb: Minor reformatting.
3017
3018 2011-08-02 Pascal Obry <obry@adacore.com>
3019
3020 * make.adb, makeutl.adb: Removes some superfluous directory separator.
3021
3022 2011-08-02 Robert Dewar <dewar@adacore.com>
3023
3024 * sem_attr.adb: Minor reformatting.
3025
3026 2011-08-02 Robert Dewar <dewar@adacore.com>
3027
3028 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
3029 (Has_Default_Component_Value): Removed
3030 * einfo.ads Comment updates
3031 (Has_Default_Aspect): Replaces Has_Default_Value
3032 (Has_Default_Component_Value): Removed
3033 * exp_ch13.adb
3034 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
3035 * exp_ch3.adb
3036 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
3037 (Get_Simple_Init_Val): Handle Default_Value aspect
3038 (Needs_Simple_Initialization): Handle Default_Value aspect
3039 * exp_ch3.ads: Needs_Simple_Initialization
3040 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
3041 * par-prag.adb (Pragma_Default[_Component]Value) Removed
3042 * sem_ch13.adb
3043 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
3044 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
3045 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
3046
3047 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3048
3049 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
3050 package containing iteration primitives.
3051 exp_ch5.adb (Expand_Iterator_Loop): ditto.
3052
3053 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3054
3055 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
3056 "of", pre-analyze expression in case it is a function call with
3057 finalization actions that must be placed ahead of the loop.
3058 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
3059 on an Ada2012 iterator, insert them ahead of the rewritten loop.
3060
3061 2011-08-02 Geert Bosch <bosch@adacore.com>
3062
3063 * cstand.adb (Create_Float_Types): Only consider C's long double for
3064 Long_Long_Float, in addition to double.
3065
3066 2011-08-02 Robert Dewar <dewar@adacore.com>
3067
3068 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
3069 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
3070 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
3071 Minor reformatting.
3072
3073 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3074
3075 * sem_attr.adb: handle properly 'Result when it is a prefix of an
3076 indexed component.
3077
3078 2011-08-02 Javier Miranda <miranda@adacore.com>
3079
3080 * einfo.ads, einfo.adb
3081 (Original_Access_Type): Move this attribute to Node26 since there was
3082 an undocumented use of Node21 in E_Access_Subprogram_Type entities
3083 which causes conflicts and breaks the generation of the .NET compiler.
3084 (Interface_Name): Add missing documentation on JGNAT only uses of
3085 this attribute.
3086
3087 2011-08-02 Geert Bosch <bosch@adacore.com>
3088
3089 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
3090 (Find_Back_End_Float_Type): Likewise
3091 (Create_Back_End_Float_Types): Likewise
3092 (Create_Float_Types): Likewise
3093 (Register_Float_Type): Likewise
3094 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
3095 Nlist and split out type selection in new local Find_Base_Type function.
3096 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
3097 Nlist
3098 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
3099
3100 2011-08-02 Robert Dewar <dewar@adacore.com>
3101
3102 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
3103 alpha order).
3104 * opt.ads: Minor comment change.
3105 * sem_ch12.adb: Minor code reorganization.
3106
3107 2011-08-02 Gary Dismukes <dismukes@adacore.com>
3108
3109 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
3110 subtype's list of rep items to the list on the full subtype in the case
3111 where the lists are the same.
3112
3113 2011-08-02 Geert Bosch <bosch@adacore.com>
3114
3115 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
3116 using the one from System.Strings, which also deallocates all strings.
3117
3118 2011-08-02 Geert Bosch <bosch@adacore.com>
3119
3120 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
3121 function.
3122 * gcc-interface/Make-lang.in: Update dependencies.
3123
3124 2011-08-02 Olivier Hainque <hainque@adacore.com>
3125
3126 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
3127 end_locus.
3128
3129 2011-08-02 Javier Miranda <miranda@adacore.com>
3130
3131 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
3132 associated with anonymous access to subprograms.
3133
3134 2011-08-02 Geert Bosch <bosch@adacore.com>
3135
3136 * opt.ads
3137 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
3138 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
3139 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
3140 (Add_Symbol_Definition): Move to switch-c.adb
3141 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
3142 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
3143 (Add_Symbol_Definition): Move to switch-c.adb.
3144 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
3145 * sem_warn.adb
3146 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
3147 Move to warnsw.adb.
3148 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
3149 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
3150 Move to warnsw.adb.
3151 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
3152 (Add_Symbol_Definition): Moved from Prepcomp.
3153 * switch-c.ads: Update copyright notice. Use String_List instead of
3154 Argument_List, removing dependency on System.OS_Lib.
3155
3156 2011-08-02 Yannick Moy <moy@adacore.com>
3157
3158 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
3159 mode on initialization expression which does not respect SPARK
3160 restrictions.
3161 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
3162 if the tree referenced by its argument represents an initialization
3163 expression in SPARK, suitable for initializing an object in an object
3164 declaration.
3165
3166 2011-08-02 Javier Miranda <miranda@adacore.com>
3167
3168 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
3169 internally generated access to subprogram with its associated protected
3170 subprogram type.
3171 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
3172
3173 2011-08-02 Geert Bosch <bosch@adacore.com>
3174
3175 * cstand.adb (Register_Float_Type): Print information about type to
3176 register, if the Debug_Flag_Dot_B is set.
3177 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
3178 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
3179 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
3180 with a requested precision of more than Max_Digits digits and no more
3181 than Max_Base_Digits digits, if a range specification is present and the
3182 Predefined_Float_Types list has a suitable type to derive from.
3183 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
3184 case of type completion with pragma Import
3185 * sem_prag.adb
3186 (Process_Import_Predefined_Type): Processing to complete a type
3187 with pragma Import. Currently supports floating point types only.
3188 (Set_Convention_From_Pragma): Do nothing without underlying type.
3189 (Process_Convention): Guard against absence of underlying type,
3190 which may happen when importing incomplete types.
3191 (Process_Import_Or_Interface): Handle case of importing predefined
3192 types. Tweak error message.
3193
3194 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
3195
3196 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
3197 functions to previous change. Reorganize code slightly.
3198
3199 2011-08-02 Geert Bosch <bosch@adacore.com>
3200
3201 * back_end.ads (Register_Type_Proc): New call back procedure type for
3202 allowing the back end to provide information about available types.
3203 (Register_Back_End_Types): New procedure to register back end types.
3204 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
3205 available types.
3206 * cstand.adb (Back_End_Float_Types): New list for floating point types
3207 supported by the back end.
3208 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
3209 (Copy_Float_Type): New procedure to make new copies of predefined types.
3210 (Register_Float_Type): New call back procedure to populate the BEFT list
3211 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
3212 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
3213 (Create_Float_Types): New procedure to create entities for floating
3214 point types predefined in Standard, and put these and any remaining
3215 BEFTs on the Predefined_Float_Types list.
3216 * stand.ads (Predefined_Float_Types): New list for predefined floating
3217 point types that do not have declarations in package Standard.
3218
3219 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
3220
3221 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
3222 entity node for the unit containing the parameter.
3223 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
3224 (Add_Inlined_Subprogram): Likewise.
3225 * gcc-interface/Make-lang.in: Update dependencies.
3226
3227 2011-08-02 Thomas Quinot <quinot@adacore.com>
3228
3229 * s-stusta.adb (Print): Make sure Pos is always initialized to a
3230 suitable value.
3231
3232 2011-08-02 Geert Bosch <bosch@adacore.com>
3233
3234 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
3235
3236 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
3237
3238 * sem_type.adb (Covers): Move trivial case to the top and reuse the
3239 computed value of Base_Type.
3240
3241 2011-08-02 Yannick Moy <moy@adacore.com>
3242
3243 * restrict.adb (Check_Restriction): issue an error for any use of
3244 class-wide, even if the No_Dispatch restriction is not set.
3245 * sem_aggr.adb: Correct typos in comments and messages in formal mode
3246 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
3247 when completing a private extension, the type named in the private part
3248 is not the same as that named in the visible part.
3249 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
3250 of an inherited primitive operations of a tagged type or type extension
3251 that returns the tagged type.
3252 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
3253 function which returns True for an implicit operation inherited by the
3254 derived type declaration for the argument type.
3255 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
3256 order.
3257
3258 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3259
3260 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
3261 Process_Bounds, to perform analysis with expansion of a range or an
3262 expression that is the iteration scheme for a loop.
3263 (Analyze_Iterator_Specification): If domain of iteration is given by a
3264 function call with a controlled result, as is the case if call returns
3265 a predefined container, ensure that finalization actions are properly
3266 generated.
3267 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
3268
3269 2011-08-02 Javier Miranda <miranda@adacore.com>
3270
3271 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
3272 * gcc-interface/Make-lang.in: Update dependencies.
3273
3274 2011-08-02 Javier Miranda <miranda@adacore.com>
3275
3276 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
3277 determine if the analysis is performed using N or Original_Node (N).
3278 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
3279 functionality of routine Is_Variable avoids code duplication.
3280 * checks.adb (Determine_Range): Handle temporaries generated by
3281 Remove_Side_Effects.
3282
3283 2011-08-02 Javier Miranda <miranda@adacore.com>
3284
3285 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
3286 expansion of the condition. Required since the previous analysis was
3287 done with expansion disabled (see Resolve_Quantified_Expression) and
3288 hence checks were not inserted and record comparisons have not been
3289 expanded.
3290
3291 2011-08-02 Ed Falis <falis@adacore.com>
3292
3293 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
3294 Update header.
3295
3296 2011-08-02 Bob Duff <duff@adacore.com>
3297
3298 * opt.ads: Minor comment fix.
3299
3300 2011-08-02 Bob Duff <duff@adacore.com>
3301
3302 * sem_ch12.adb (Analyze_Package_Instantiation,
3303 Analyze_Subprogram_Instantiation): Turn off style checking while
3304 analyzing an instance. Whatever style checks that apply to the generic
3305 unit should apply, so it makes no sense to apply them in an instance.
3306 This was causing trouble when compiling an instance of a runtime
3307 unit that violates the -gnatyO switch.
3308 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
3309 one of the two case statements, causing spurious errors.
3310
3311 2011-08-02 Robert Dewar <dewar@adacore.com>
3312
3313 * uname.adb: Minor reformatting.
3314 * gnatcmd.adb: Minor reformatting.
3315 * exp_attr.adb: Minor reformatting.
3316
3317 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3318
3319 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
3320 No_Dispatching_Calls, do not look for the Assign primitive, because
3321 predefined primitives are not created in this case.
3322
3323 2011-08-02 Bob Duff <duff@adacore.com>
3324
3325 * stylesw.ads: Minor comment fixes.
3326
3327 2011-08-02 Robert Dewar <dewar@adacore.com>
3328
3329 * freeze.adb (Add_To_Result): New procedure.
3330
3331 2011-08-02 Jose Ruiz <ruiz@adacore.com>
3332
3333 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
3334 time, if the specific run-time routines for handling streams of strings
3335 are not available, use the default mechanism.
3336
3337 2011-08-02 Arnaud Charlet <charlet@adacore.com>
3338
3339 * s-regpat.ads: Fix typo.
3340
3341 2011-08-02 Vincent Celier <celier@adacore.com>
3342
3343 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
3344 not null, call it to create the in memory config project file without
3345 parsing an existing default config project file.
3346
3347 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
3348
3349 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
3350
3351 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3352
3353 * sem_elim.adb: an abstract subprogram does not need an eliminate
3354 pragma for its descendant to be eliminable.
3355
3356 2011-08-02 Ed Falis <falis@adacore.com>
3357
3358 * init.c: revert to handling before previous checkin for VxWorks
3359 * s-intman-vxworks.adb: delete unnecessary declarations related to
3360 using Ada interrupt facilities for handling signals.
3361 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
3362 * s-intman-vxworks.ads: Import __gnat_install_handler as
3363 Initialize_Interrupts.
3364 * s-taprop-vxworks.adb: Delete Signal_Mask.
3365 (Abort_Handler): change construction of mask to unblock exception
3366 signals.
3367
3368 2011-08-02 Jerome Guitton <guitton@adacore.com>
3369
3370 * a-except-2005.adb (Raise_From_Signal_Handler): Call
3371 Debug_Raise_Exception before propagation starts.
3372
3373 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
3374
3375 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
3376 to Restriction_Check_Required.
3377 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
3378 * sem_res.adb (Resolve_Call): Likewise.
3379 * sem_attr.adb (Check_Stream_Attribute): Likewise.
3380
3381 2011-08-02 Bob Duff <duff@adacore.com>
3382
3383 * stylesw.ads: Update comment.
3384 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
3385 * errout.ads: Remove obsolete comment.
3386
3387 2011-08-02 Javier Miranda <miranda@adacore.com>
3388
3389 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
3390 (Set_Is_Safe_To_Reevaluate): new procedure.
3391 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
3392 assignment is allowed on safe-to-reevaluate variables.
3393 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
3394 temporary created to remove side effects in expressions that use
3395 the secondary stack as safe-to-reevaluate.
3396 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
3397 variables that are not true constants.
3398
3399 2011-08-02 Robert Dewar <dewar@adacore.com>
3400
3401 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
3402 sem_res.adb, sem_ch6.adb: Minor reformatting.
3403
3404 2011-08-02 Jerome Guitton <guitton@adacore.com>
3405
3406 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
3407
3408 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3409
3410 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
3411 not set Overridden_Operation if subprogram is an initialization
3412 procedure.
3413
3414 2011-08-02 Yannick Moy <moy@adacore.com>
3415
3416 * par-ch6.adb: Correct obsolete name in comments
3417 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
3418 which takes two message arguments (existing function takes one), with
3419 second message used for continuation.
3420 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
3421 block statements that originate from a source block statement, not
3422 generated block statements
3423 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
3424 symmetry with procedure case
3425 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
3426 function to issue an error in formal mode if a package specification
3427 contains more than one tagged type or type extension.
3428 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
3429 parameters matching formals of tagged types are objects (or ancestor
3430 type conversions of objects), not general expressions. Issue an error
3431 on view conversions that are not involving ancestor conversion of an
3432 extended type.
3433 (Resolve_Type_Conversion): in formal mode, issue an error on the
3434 operand of an ancestor type conversion which is not an object
3435 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
3436 procedure so that it works also for actuals of function calls
3437 (Is_Actual_Tagged_Parameter): new function which determines if its
3438 argument is an actual parameter of a formal of tagged type in a
3439 subprogram call
3440 (Is_SPARK_Object_Reference): new function which determines if the tree
3441 referenced by its argument represents an object in SPARK
3442
3443 2011-08-02 Robert Dewar <dewar@adacore.com>
3444
3445 * sem_ch3.adb: Minor reformatting
3446 Minor comment addition
3447 Minor error msg text change
3448
3449 2011-08-02 Javier Miranda <miranda@adacore.com>
3450
3451 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
3452 function. Used to be more precise when we generate a variable plus one
3453 assignment to remove side effects in the evaluation of the Bound
3454 expressions.
3455 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
3456 of the bound expression to force its re-analysis and thus expand the
3457 associated transient scope (if required). Code cleanup replacing the
3458 previous code that declared the constant entity by an invocation to
3459 routine Force_Evaluation which centralizes this work in the frontend.
3460
3461 2011-08-02 Robert Dewar <dewar@adacore.com>
3462
3463 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
3464 (Base_Type): Now uses improved Is_Base_Type function
3465 * einfo.ads (Base_Type): Inline this function
3466
3467 2011-08-02 Robert Dewar <dewar@adacore.com>
3468
3469 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
3470 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
3471
3472 2011-08-02 Arnaud Charlet <charlet@adacore.com>
3473
3474 * gcc-interface/Make-lang.in: Update dependencies.
3475 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
3476 targets.
3477
3478 2011-08-02 Yannick Moy <moy@adacore.com>
3479
3480 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
3481 non-simple expression used in delta constraint
3482 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
3483 index constraint which is not a subtype mark
3484 * par.adb: With and use Restrict
3485 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
3486 mode on component type which is not a subtype mark and default
3487 expression on component
3488 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
3489 of string which does not have a lower index bound equal to 1
3490 (Array_Type_Declaration): issue an error in formal mode on index or
3491 component type which is not a subtype mark, and on aliased keyword on
3492 component
3493 (Derived_Type_Declaration): issue an error in formal mode on interface,
3494 limited or abstract type
3495 (Record_Type_Declaration): issue an error in formal mode on interface
3496 (Record_Type_Definition): issue an error in formal mode on tagged types
3497 and type extensions not declared in the specification of a library unit
3498 package; on null non-tagged record; on variant part
3499
3500 2011-08-02 Vincent Celier <celier@adacore.com>
3501
3502 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
3503 not declared for qualified library project when Library_Name is not
3504 declared, but Library_Dir is.
3505
3506 2011-08-02 Robert Dewar <dewar@adacore.com>
3507
3508 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
3509 pragmas (affects aspects [Component_]Default_Value
3510 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
3511 component type for the resolution
3512
3513 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
3514
3515 * einfo.adb (Base_Type): Tune implementation for speed.
3516
3517 2011-08-02 Robert Dewar <dewar@adacore.com>
3518
3519 * freeze.adb: Minor reformatting.
3520
3521 2011-08-02 Thomas Quinot <quinot@adacore.com>
3522
3523 * scos.ads: Update comments.
3524
3525 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3526
3527 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
3528 base type, because the parent may be a subtype of a private type whose
3529 convention is established in a private part.
3530
3531 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
3532
3533 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
3534 statement in a block when the expansion of the return expression has
3535 created a finalization chain.
3536 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
3537 with the parent node.
3538 Add N_Extended_Return_Statement to handle the case where a transient
3539 object declaration appears in the Return_Object_Declarations list of
3540 an extended return statement.
3541
3542 2011-08-02 Matthew Gingell <gingell@adacore.com>
3543
3544 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
3545 unused parameter 'name'.
3546
3547 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3548
3549 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
3550 inherited operation, check whether its alias, which is the source
3551 operastion that it renames, has been marked eliminated.
3552
3553 2011-08-02 Javier Miranda <miranda@adacore.com>
3554
3555 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
3556 in-mode parameter whose type is an access type since it can be used to
3557 modify its designated object. Enforce code that handles as safe an
3558 access type that is not access-to-constant but it is the result of a
3559 previous removal of side-effects.
3560 (Remove_Side_Effects): Minor code reorganization of cases which require
3561 no action. Done to incorporate documentation on new cases uncovered
3562 working in this ticket: no action needed if this routine was invoked
3563 too early and the nodes are not yet decorated.
3564 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
3565 to routine Remove_Side_Effects by calls to Force_Evaluation since they
3566 were issued with actuals that are implicitly provided by
3567 Force_Evaluation.
3568
3569 2011-08-02 Robert Dewar <dewar@adacore.com>
3570
3571 * sem_ch3.adb, sem_res.adb: Minor reformatting.
3572
3573 2011-08-02 Yannick Moy <moy@adacore.com>
3574
3575 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
3576 to issue an error in formal mode on attribute not supported in this mode
3577 (Analyze_Attribute): issue errors on standard attributes not supported
3578 in formal mode.
3579 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
3580 comment, and issue error in formal mode on modulus which is not a power
3581 of 2.
3582 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
3583 range.
3584 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
3585 subtype mark.
3586 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
3587 operator on modular type (except 'not').
3588
3589 2011-08-02 Robert Dewar <dewar@adacore.com>
3590
3591 * gnat_rm.texi: Minor reformatting.
3592
3593 2011-08-02 Arnaud Charlet <charlet@adacore.com>
3594
3595 * s-osinte-linux.ads: Minor comment update and reformatting.
3596 * i-cexten.ads: Make this unit pure, as for its parent.
3597 Will allow its usage in more contexts if needed.
3598
3599 2011-08-02 Robert Dewar <dewar@adacore.com>
3600
3601 * s-utf_32.ads: Minor comment fix.
3602
3603 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3604
3605 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
3606 operation of a tagged synchronized type, handle the case where the
3607 controlling argument is overloaded.
3608
3609 2011-08-02 Yannick Moy <moy@adacore.com>
3610
3611 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
3612 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
3613 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
3614 SPARK mode and formal verification mode on processing SPARK restriction
3615 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
3616 requiring consistency checking.
3617
3618 2011-08-02 Robert Dewar <dewar@adacore.com>
3619
3620 * sem_res.adb: Minor reformatting.
3621
3622 2011-08-02 Robert Dewar <dewar@adacore.com>
3623
3624 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
3625 a-cforse.ads: Remove unneeded with of Ada.Containers
3626 Remove commented out pragma Inline's
3627 Move specifications of new subprograms to the actual specs
3628
3629 2011-08-02 Yannick Moy <moy@adacore.com>
3630
3631 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
3632 a-cforse.ads: Update comments.
3633
3634 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3635
3636 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
3637
3638 2011-08-02 Robert Dewar <dewar@adacore.com>
3639
3640 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
3641 a-cforse.ads, a-cofove.ads: Minor reformatting.
3642
3643 2011-08-02 Claire Dross <dross@adacore.com>
3644
3645 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
3646 a-cofove.ads: Add comments.
3647
3648 2011-08-02 Yannick Moy <moy@adacore.com>
3649
3650 * gnat_rm.texi: Document formal containers.
3651
3652 2011-08-02 Emmanuel Briot <briot@adacore.com>
3653
3654 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
3655 are empty sections.
3656
3657 2011-08-02 Robert Dewar <dewar@adacore.com>
3658
3659 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
3660 reformatting.
3661
3662 2011-08-02 Robert Dewar <dewar@adacore.com>
3663
3664 * aspects.adb: New aspects Default_Value and Default_Component_Value
3665 New format of Aspect_Names table checks for omitted entries
3666 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
3667 handling of boolean aspects for derived types.
3668 New aspects Default_Value and Default_Component_Value
3669 New format of Aspect_Names table checks for omitted entries
3670 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
3671 (Has_Default_Value): New flag
3672 (Has_Default_Component_Value): New flag
3673 (Has_Default_Value): New flag
3674 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
3675 table.
3676 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
3677 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
3678 Default_Value and Default_Component_Value
3679 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
3680 New aspects Default_Value and Default_Component_Value
3681 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
3682 * sprint.adb: Print N_Aspect_Specification node when called from gdb
3683
3684 2011-08-02 Vincent Celier <celier@adacore.com>
3685
3686 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
3687 inherit library kind.
3688
3689 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3690
3691 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
3692 Minor reformatting.
3693
3694 2011-08-02 Robert Dewar <dewar@adacore.com>
3695
3696 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
3697
3698 2011-08-02 Yannick Moy <moy@adacore.com>
3699
3700 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
3701
3702 2011-08-02 Robert Dewar <dewar@adacore.com>
3703
3704 * impunit.adb: Add comment.
3705
3706 2011-08-02 Yannick Moy <moy@adacore.com>
3707
3708 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
3709 qualification of aggregates in formal mode
3710 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
3711 another aggregate
3712 (Resolve_Aggregate): complete the test that an aggregate is adequately
3713 qualified in formal mode
3714
3715 2011-08-02 Pascal Obry <obry@adacore.com>
3716
3717 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
3718 * mlib-prj.adb: Supress warning when compiling binder generated file.
3719 (Build_Library): Supress all warnings when compiling the binder
3720 generated file.
3721
3722 2011-08-02 Yannick Moy <moy@adacore.com>
3723
3724 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
3725 from here...
3726 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
3727 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
3728 Add with/use clauses to make Check_Formal_Restriction visible
3729
3730 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3731
3732 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
3733 in-parameters when type of the generic formal is private in the generic
3734 spec and non-private in the body.
3735
3736 2011-08-02 Claire Dross <dross@adacore.com>
3737
3738 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
3739 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
3740 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
3741 * impunit.adb, Makefile.rtl: Take new files into account.
3742
3743 2011-08-02 Robert Dewar <dewar@adacore.com>
3744
3745 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
3746 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
3747
3748 2011-08-02 Yannick Moy <moy@adacore.com>
3749
3750 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
3751 formal mode
3752 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
3753 matching static array bounds, taking into account the special case of
3754 string literals
3755 * sem_ch3.adb: Typo in comment.
3756
3757 2011-08-02 Yannick Moy <moy@adacore.com>
3758
3759 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
3760 which issues an error in formal mode if its argument node is originally
3761 from source
3762 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
3763 has a discriminant specification so that it does not include the case
3764 of derived types
3765 (Derived_Type_Declaration): move here the test that a derived type has a
3766 discriminant specification
3767 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
3768 first element of a component association before accessing its choices
3769 (presence of component association is not enough)
3770 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
3771 declaration is a library item before accessing the next element in a
3772 list, as library items are not member of lists
3773 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
3774 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
3775 Check_Formal_Restriction whenever possible.
3776
3777 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3778
3779 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
3780 reference when needed.
3781
3782 2011-08-02 Bob Duff <duff@adacore.com>
3783
3784 * gnat_ugn.texi: Fix typo.
3785
3786 2011-08-02 Vincent Celier <celier@adacore.com>
3787
3788 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
3789 archive file name. Do not use the full path name of archives for Open
3790 VMS.
3791
3792 2011-08-02 Robert Dewar <dewar@adacore.com>
3793
3794 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
3795 Analyze_Aspect_Specifications
3796 * sem_ch13.adb
3797 (Analyze_Aspect_Specifications): New handling for boolean aspects
3798 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
3799 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
3800 sequence for Analyze_Aspect_Specifications
3801 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
3802 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
3803
3804 2011-08-02 Robert Dewar <dewar@adacore.com>
3805
3806 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
3807 aspects, since these no longer exist.
3808
3809 2011-08-02 Robert Dewar <dewar@adacore.com>
3810
3811 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
3812 semicolon, do not try to see if there are aspects following it.
3813 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
3814 aspect spec.
3815
3816 2011-08-02 Robert Dewar <dewar@adacore.com>
3817
3818 * sem_ch8.adb, aspects.ads: Minor reformatting.
3819
3820 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
3821
3822 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
3823 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
3824 extracted from...
3825 (Analyze_Aspect_Specifications): ...here. Call above procedure.
3826
3827 2011-08-02 Yannick Moy <moy@adacore.com>
3828
3829 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
3830 mode on subprogram declaration outside of package specification, unless
3831 it is followed by a pragma Import
3832 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
3833 Access_Type_Declaration): issue error in formal mode on access type
3834 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
3835 incomplete type
3836 (Analyze_Object_Declaration): issue error in formal mode on object
3837 declaration which does not respect SPARK restrictions
3838 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
3839 declaration which does not respect SPARK restrictions
3840 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
3841 error in formal mode on digits or delta constraint
3842 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
3843 decimal fixed point type
3844 (Derived_Type_Declaration): issue error in formal mode on derived type
3845 other than type extensions of tagged record types
3846 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
3847 with check on access definition
3848 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
3849 mode on protected definition.
3850 (Analyze_Task_Definition): issue error in formal mode on task definition
3851
3852 2011-08-02 Robert Dewar <dewar@adacore.com>
3853
3854 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
3855
3856 2011-08-02 Javier Miranda <miranda@adacore.com>
3857
3858 * sem_ch6.adb (Can_Override_Operator): New function.
3859 (Verify_Overriding_Indicator): Add missing code to check overriding
3860 indicator in operators. Fixes regression.
3861 (Check_Overriding_Indicator): Minor reformating after replacing the
3862 code that evaluates if the subprogram can override an operator by
3863 invocations to the above new function.
3864 * einfo.adb
3865 (Write_Field26_Name): Add missing code to ensure that, following
3866 the documentation in einfo.ads, this field is not shown as attribute
3867 "Static_Initialization" on non-dispatching functions.
3868
3869 2011-08-02 Jose Ruiz <ruiz@adacore.com>
3870
3871 * sem_res.adb (Resolve_Call): A call to
3872 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
3873 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
3874 i.e., when the second parameter is of type Time_Span.
3875
3876 2011-08-02 Vincent Celier <celier@adacore.com>
3877
3878 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
3879 with an archive instead of -L<library dir> -l<library name>.
3880
3881 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3882
3883 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
3884 mark the base types In_Use in addition to making the operations
3885 use_visible.
3886
3887 2011-08-02 Ed Falis <falis@adacore.com>
3888
3889 * init.c: add and setup __gnat_signal_mask for the exception signals
3890 * s-inmaop-vxworks.adb: new file.
3891 * s-intman-vxworks.adb: remove unnecessary initializations and
3892 simplify remaining
3893 * s-intman-vxworks.ads: remove unnecessary variable
3894 * s-taprop-vxworks.adb: simplify signal initialization
3895
3896 2011-08-02 Robert Dewar <dewar@adacore.com>
3897
3898 * sem_ch8.adb: Minor code reorganization, comment updates.
3899
3900 2011-08-02 Robert Dewar <dewar@adacore.com>
3901
3902 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
3903 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
3904 here from Sem_Res.
3905 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
3906 (Matching_Static_Array_Bounds): Moved here from Sem_Res
3907
3908 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3909
3910 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
3911 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
3912 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
3913 use_type_clauses, to handle more efficiently use_type and use_all_type
3914 constructs.
3915 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
3916 Ada2012 Use_All_Type clause.
3917 (Use_Class_Wide_Operations): new procedure.
3918
3919 2011-08-02 Robert Dewar <dewar@adacore.com>
3920
3921 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
3922 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
3923 expression to expression function.
3924
3925 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3926
3927 * sem_ch4.adb: transform simple Ada2012 membership into equality only
3928 if types are compatible.
3929
3930 2011-08-02 Yannick Moy <moy@adacore.com>
3931
3932 * sem_res.adb (Matching_Static_Array_Bounds): new function which
3933 returns True if its argument array types have same dimension and same
3934 static bounds at each index.
3935 (Resolve_Actuals): issue an error in formal mode on actuals passed as
3936 OUT or IN OUT paramaters which are not view conversions in SPARK.
3937 (Resolve_Arithmetic_Op): issue an error in formal mode on
3938 multiplication or division with operands of fixed point types which are
3939 not qualified or explicitly converted.
3940 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
3941 Boolean or array type (except String) operands.
3942 (Resolve_Equality_Op): issue an error in formal mode on equality
3943 operators for array types other than String with non-matching static
3944 bounds.
3945 (Resolve_Logical_Op): issue an error in formal mode on logical operators
3946 for array types with non-matching static bounds. Factorize the code in
3947 Matching_Static_Array_Bounds.
3948 (Resolve_Qualified_Expression): issue an error in formal mode on
3949 qualified expressions for array types with non-matching static bounds.
3950 (Resolve_Type_Conversion): issue an error in formal mode on type
3951 conversion for array types with non-matching static bounds
3952
3953 2011-08-02 Robert Dewar <dewar@adacore.com>
3954
3955 * par-ch10.adb: Minor code reorganization (use Nkind_In).
3956
3957 2011-08-02 Ed Schonberg <schonberg@adacore.com>
3958
3959 * par-ch9.adb: save location of entry for proper error message.
3960
3961 2011-08-02 Javier Miranda <miranda@adacore.com>
3962
3963 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
3964 (Use_Full_View) which permits this routine to climb through the
3965 ancestors using the full-view of private parents.
3966 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
3967 Use_Full_View to true in calls to Is_Ancestor.
3968 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
3969 true in call to Is_Ancestor.
3970 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
3971 Use_Full_View to true in call to Is_Ancestor.
3972 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
3973 call to Is_Ancestor.
3974 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
3975 Use_Full_View to true in calls to Is_Ancestor.
3976 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
3977 Make_Select_Specific_Data_Table, Register_Primitive,
3978 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
3979 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
3980 to true in call to Is_Ancestor.
3981 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
3982 Use_Full_View to true in calls to Is_Ancestor.
3983 * exp_cg.adb
3984 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
3985 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
3986
3987 2011-08-02 Robert Dewar <dewar@adacore.com>
3988
3989 * gnat_rm.texi: Minor reformatting.
3990 * sem_prag.adb: Minor reformatting.
3991
3992 2011-08-02 Tristan Gingold <gingold@adacore.com>
3993
3994 * vms_data.ads: Add VMS qualifier for -gnateP.
3995
3996 2011-08-02 Robert Dewar <dewar@adacore.com>
3997
3998 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
3999 * par-ch7.adb (P_Package): Proper placement of aspects for package
4000 decl/instantiation.
4001 * par-endh.adb (Check_End): Ad Is_Sloc parameter
4002 (End_Statements): Add Is_Sloc parameterr
4003 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
4004 (Check_End): Ad Is_Sloc parameter
4005 (End_Statements): Add Is_Sloc parameterr
4006
4007 2011-08-02 Vincent Celier <celier@adacore.com>
4008
4009 * ug_words: Add VMS qualifier equivalent to -gnateP:
4010 /SYMBOL_PREPROCESSING.
4011
4012 2011-08-02 Jose Ruiz <ruiz@adacore.com>
4013
4014 * gnat-style.texi: For hexadecimal numeric literals the typical
4015 grouping of digits is 4 to represent 2 bytes.
4016 A procedure spec which is split into several lines is indented two
4017 characters.
4018
4019 2011-08-02 Yannick Moy <moy@adacore.com>
4020
4021 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
4022 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
4023 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
4024 properly qualified
4025 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
4026 choice in array aggregate
4027 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
4028 mark as ancestor
4029 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
4030 positional and named aggregate for record, or others in record
4031 aggregate, or multiple choice in record aggregate
4032 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
4033 array operands to logical operations AND, OR and XOR do not have the
4034 same static lower and higher bounds
4035 * sem_ch5.adb, sinfo.ads: Correct typos in comments
4036
4037 2011-08-01 Robert Dewar <dewar@adacore.com>
4038
4039 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
4040 Replaces Last_Source_Node_In_Sequence.
4041 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
4042 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
4043 parens and blank in string (this was inconsistently implemented).
4044 * errout.ads
4045 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
4046 blank in string (this was inconsistently implemented).
4047 * gnat1drv.adb
4048 (Set_Global_Switches): Set formal mode switches appropriately
4049 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
4050 * par-prag.adb
4051 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
4052 call Set_Error_Msg_Lang to set "spark" as language name.
4053 * par.adb: Remove unnecessary call to set formal language for errout
4054 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
4055 appropriately and call Set_Error_Msg_Lang to set "spark" as language
4056 name.
4057 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
4058 calls to it, moved after resolution so that types are known
4059 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
4060 result of concatenation is not of type String
4061 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
4062 concatenation is not properly restricted
4063 * gnat_rm.texi: Add doc on pragma Spark_95.
4064 * gcc-interface/Makefile.in: Remove obsolete target pairs for
4065 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
4066 * gcc-interface/Make-lang.in: Update dependencies.
4067
4068 2011-08-01 Javier Miranda <miranda@adacore.com>
4069
4070 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
4071 condition that detects if the overridden operation must replace an
4072 existing entity.
4073
4074 2011-08-01 Javier Miranda <miranda@adacore.com>
4075
4076 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
4077 code declarations inserted by Insert_Actions in each alternative of the
4078 N_Case_Expression node.
4079
4080 2011-08-01 Robert Dewar <dewar@adacore.com>
4081
4082 * sem_ch6.adb: Minor code reorganization.
4083 * sem_util.adb: Minor reformatting.
4084
4085 2011-08-01 Pascal Obry <obry@adacore.com>
4086
4087 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
4088 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
4089
4090 2011-08-01 Yannick Moy <moy@adacore.com>
4091
4092 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
4093 literal or operator symbol which is prefixed
4094 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
4095 mode on access attributes.
4096 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
4097 that concatenation operands are properly restricted in formal mode
4098 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
4099 Analyze_Concatenation_Operand. Issue an error in formal mode if the
4100 result of the concatenation has a type different from String.
4101 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
4102 Analyze_Quantified_Expression, Analyze_Slice,
4103 Analyze_Null): issue an error in formal mode on unsupported constructs
4104 * sem_ch5.adb
4105 (Analyze_Block_Statement): only issue error on source block statement
4106 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
4107 function which returns the last node in a list of nodes for which
4108 Comes_From_Source returns True, if any
4109 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
4110 Last_Source_Node_In_Sequence
4111 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
4112 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
4113 mode on unsupported constructs
4114 * sem_ch9.adb Do not return after issuing error in formal mode, as the
4115 rest of the actions may be needed later on since the error is marked as
4116 not serious.
4117 * sinfo.ads: Typos in comments.
4118
4119 2011-08-01 Pascal Obry <obry@adacore.com>
4120
4121 * projects.texi: Minor editing.
4122
4123 2011-08-01 Yannick Moy <moy@adacore.com>
4124
4125 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
4126 insertion character ~~
4127 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
4128 (Set_Error_Msg_Lang): new procedure which fixes the language for use
4129 with insertion character ~~
4130 (Set_Msg_Text): treat insertion character ~~
4131 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
4132 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
4133 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
4134 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
4135 errors related to the formal language restriction not serious
4136 (insertion character |).
4137 * par.adb (Par): set formal language for error messages if needed
4138 * sem_ch6.adb (Check_Missing_Return): take into account possible
4139 generated statements at the end of the function
4140 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
4141 enumeration value to define a new pragma SPARK_95
4142 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
4143 SPARK_Version): new type and variables to store the SPARK version
4144 (none by default).
4145 (SPARK_Mode): return True when SPARK_Version is set
4146 * par-prag.adb: Correct indentation
4147 (Prag): take Pragma_SPARK_95 into account
4148 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
4149 into account.
4150
4151 2011-08-01 Robert Dewar <dewar@adacore.com>
4152
4153 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
4154 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
4155 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
4156
4157 2011-08-01 Pascal Obry <obry@adacore.com>
4158
4159 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
4160 Target_Name to Get_Path call.
4161 (Parse_Single_Project): Likewise.
4162 (Post_Parse_Context_Clause): Likewise.
4163 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
4164 Call Initialise_Project_Path with the proper Target_Name.
4165 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
4166 search path.
4167 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
4168 with the proper Target_Name.
4169 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
4170 Part.Parse routine.
4171 (Parse_Project_And_Apply_Config): Likewise.
4172 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
4173 This is fine as this part of the code is supporting only native
4174 compilation.
4175 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
4176 is fine as this part of the code is supporting only native compilation.
4177
4178 2011-08-01 Yannick Moy <moy@adacore.com>
4179
4180 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
4181 of homonym, unless the homonym is one of the cases allowed in SPARK
4182 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
4183 package declaration occurring after a body.
4184
4185 2011-08-01 Robert Dewar <dewar@adacore.com>
4186
4187 * checks.adb, exp_ch4.adb: Minor reformatting.
4188
4189 2011-08-01 Javier Miranda <miranda@adacore.com>
4190
4191 * einfo.ads (Access_Disp_Table): Fix documentation.
4192 (Dispatch_Table_Wrappers): Fix documentation.
4193
4194 2011-08-01 Pascal Obry <obry@adacore.com>
4195
4196 * prj-env.adb, prj-env.ads: Minor reformatting.
4197
4198 2011-08-01 Yannick Moy <moy@adacore.com>
4199
4200 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
4201 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
4202 procedures out of these packages.
4203 * errout.ads, errout.adb
4204 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
4205 procedures in of this package
4206 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
4207 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
4208 on misplaced later vs initial declarations, like in Ada 83
4209 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
4210 formal mode on attribute of private type whose full type declaration
4211 is not visible
4212 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
4213 package declaration inside a package specification
4214 (Analyze_Full_Type_Declaration): issue error in formal mode on
4215 controlled type or discriminant type
4216 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
4217 user-defined operator means that it should come from the source
4218 (New_Overloaded_Entity): issue error in formal mode on overloaded
4219 entity.
4220 * sem_ch6.ads, sem_ch13.ads: typos in comments.
4221
4222 2011-08-01 Thomas Quinot <quinot@adacore.com>
4223
4224 * atree.adb: Minor reformatting.
4225 * checks.adb: Minor reformatting.
4226
4227 2011-08-01 Vincent Celier <celier@adacore.com>
4228
4229 * s-parame-vms-ia64.ads: Fix typo in comment
4230 Minor reformatting
4231 * s-parame-vms-restrict.ads: Removed, unused.
4232
4233 2011-08-01 Javier Miranda <miranda@adacore.com>
4234
4235 * exp_ch3.adb
4236 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
4237 * sem_ch3.adb
4238 (Constrain_Index): Remove side effects in the evaluation of the bounds.
4239 * sem_ch3.ads, sem_ch3.adb
4240 (Is_Constant_Bound): New extended version of the subprogram that was
4241 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
4242 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
4243 * sem_aux.ads (Constant_Value): Fix typo in comment.
4244 * checks.adb (Generate_Index_Checks): New implementation which, for
4245 array objects with constant bounds, generates the runtime check
4246 referencing the bounds of the array type. For other cases this routine
4247 provides its previous behavior obtaining such values from the array
4248 object.
4249 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
4250 parent type.
4251 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
4252 we cannot have semantic interpretations of the new node.
4253
4254 2011-08-01 Ed Schonberg <schonberg@adacore.com>
4255
4256 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
4257 expressions.
4258
4259 2011-08-01 Arnaud Charlet <charlet@adacore.com>
4260
4261 * sem_ch8.adb: Minor code editing.
4262 * s-vxwext.adb: Remove trailing space.
4263 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
4264 consistency with other files.
4265
4266 2011-08-01 Thomas Quinot <quinot@adacore.com>
4267
4268 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
4269
4270 2011-08-01 Ed Schonberg <schonberg@adacore.com>
4271
4272 * par-ch10.adb: reject parameterized expressions as compilation unit.
4273 * sem_ch4.adb: handle properly conditional expression with overloaded
4274 then_clause and no else_clause.
4275
4276 2011-08-01 Tristan Gingold <gingold@adacore.com>
4277
4278 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
4279 like done by System.Aux_DEC.
4280 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
4281
4282 2011-08-01 Yannick Moy <moy@adacore.com>
4283
4284 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
4285 missing label at end of declaration (subprogram or package)
4286 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
4287 of positional and named parameter association
4288 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
4289 Error_Msg_SP which adds a prefix to the error message giving the name
4290 of the formal language analyzed
4291 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
4292 access result type in subprogram, unconstrained array as result type,.
4293 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
4294 procedure
4295 * sem_ch8.adb: Code clean up.
4296
4297 2011-08-01 Javier Miranda <miranda@adacore.com>
4298
4299 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
4300 * einfo.ads (Access_Disp_Table): Fix documentation.
4301 (Dispatch_Table_Wrappers): Fix documentation.
4302 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
4303 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
4304 to enforce the documentation of this attribute.
4305 (Set_Is_Interface): Cleanup the assertion.
4306 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
4307 the Underlying_Type entity before reading attribute Access_Disp_Table.
4308 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
4309 Locate the Underlying_Type before reading attribute Access_Disp_Table.
4310 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
4311 the Underlying_Type entity before reading attribute Access_Disp_Table.
4312 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
4313 Locate the Underlying_Type entity before reading attribute
4314 Access_Disp_Table.
4315
4316 2011-08-01 Ed Schonberg <schonberg@adacore.com>
4317
4318 * s-poosiz.ads: Additional overriding indicators.
4319
4320 2011-08-01 Yannick Moy <moy@adacore.com>
4321
4322 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
4323 formal mode.
4324 (Analyze_Iteration_Scheme): issue error in formal mode when loop
4325 parameter specification does not include a subtype mark.
4326 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
4327 formal mode on abstract subprogram.
4328 (Analyze_Subprogram_Specification): issue error in formal mode on
4329 user-defined operator.
4330 (Process_Formals): issue error in formal mode on access parameter and
4331 default expression.
4332 * sem_ch9.adb (Analyze_Abort_Statement,
4333 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
4334 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
4335 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
4336 Analyze_Requeue, Analyze_Selective_Accept,
4337 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
4338 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
4339 issue error in formal mode on user-defined raise statement.
4340
4341 2011-08-01 Thomas Quinot <quinot@adacore.com>
4342
4343 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
4344 declaration being hidden when overriding an implicit inherited
4345 subprogram.
4346 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
4347 (-gnats), do not complain about a source file that contains only a
4348 pragma No_Body.
4349
4350 2011-08-01 Ed Schonberg <schonberg@adacore.com>
4351
4352 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
4353 variable if already set.
4354
4355 2011-08-01 Arnaud Charlet <charlet@adacore.com>
4356
4357 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
4358 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
4359 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
4360 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
4361 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
4362 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
4363 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
4364 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
4365 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
4366 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
4367 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
4368 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
4369 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
4370 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
4371 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
4372 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
4373 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
4374 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
4375 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
4376 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
4377 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
4378 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
4379 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
4380 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
4381 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
4382 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
4383 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
4384 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
4385 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
4386 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
4387 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
4388 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
4389 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
4390 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
4391 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
4392 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
4393 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
4394 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
4395 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
4396 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
4397 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
4398 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
4399 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
4400 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
4401 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
4402 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
4403 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
4404 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
4405 s-osinte-mingw.ads: Update to GPLv3 run-time license.
4406 Use GNAT instead of GNARL.
4407
4408 2011-08-01 Bob Duff <duff@adacore.com>
4409
4410 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
4411 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
4412 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
4413 reformatting.
4414
4415 2011-08-01 Yannick Moy <moy@adacore.com>
4416
4417 * debug.adb (d.D) reverve flag for the SPARK mode
4418 (d.E) reverve flag for SPARK generation mode
4419 (d.F) reverve flag for Why generation mode
4420 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
4421 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
4422 functions which return True when the corresponding modes are set
4423 (Formal_Language): return "spark" or "alfa" when in formal verification
4424 mode.
4425 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
4426 Error_Msg to prefix the error message with a tag giving the formal
4427 language
4428 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
4429 message with a tag giving the formal language
4430 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
4431 block statement
4432 (Analyze_Case_Statement): issue error in formal mode on case statement
4433 with a single "others" case alternative
4434 (Analyze_Exit_Statement): issue errors in formal mode on exit
4435 statements which do not respect SPARK restrictions
4436 (Analyze_Goto_Statement): issue error in formal mode on goto statement
4437 (Check_Unreachable_Code): always issue an error (not a warning) in
4438 formal mode on unreachable code (concerns both code after an infinite
4439 loop and after an unconditional jump, both not allowed in SPARK)
4440 * sem_ch6.adb (Analyze_Return_Statement): add call to
4441 Set_Return_Present for a procedure containing a return statement
4442 (already done for functions in Analyze_Function_Return)
4443 (Analyze_Function_Return): issue error in formal mode on extended
4444 return or if return is not last statement in function
4445 (Check_Missing_Return): issue error in formal mode if function does
4446 not end with return or if procedure contains a return
4447 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
4448 function to detect if there is an inner scope of its parameter S which
4449 is a loop.
4450
4451 2011-08-01 Thomas Quinot <quinot@adacore.com>
4452
4453 * sem_ch6.ads: Minor reformatting.
4454
4455 2011-08-01 Javier Miranda <miranda@adacore.com>
4456
4457 * sem_util.adb (Abstract_Interface_List): Complete condition when
4458 processing private type declarations to avoid reading unavailable
4459 attribute.
4460 (Is_Synchronized_Tagged_Type): Complete condition when processing
4461 private extension declaration nodes to avoid reading unavailable
4462 attribute.
4463
4464 2011-08-01 Thomas Quinot <quinot@adacore.com>
4465
4466 * sem_ch3.adb: Minor reformatting.
4467
4468 2011-08-01 Thomas Quinot <quinot@adacore.com>
4469
4470 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
4471 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
4472 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
4473 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
4474 for VMS, instead parametrize the common implementation with
4475 System.Parameters declarations.
4476
4477 2011-08-01 Eric Botcazou <ebotcazou@adacore.com>
4478
4479 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
4480
4481 2011-08-01 Tristan Gingold <gingold@adacore.com>
4482
4483 * seh_init.c: Fix SEH handler installation on win64.
4484
4485 2011-08-01 Ed Schonberg <schonberg@adacore.com>
4486
4487 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
4488 double analysis of an anonymous access to subprogram, because it can
4489 lead to improper sharing of profiles and a back-end crash.
4490
4491 2011-08-01 Robert Dewar <dewar@adacore.com>
4492
4493 * make.adb, sem_ch4.adb: Minor reformatting.
4494 * gcc-interface/Make-lang.in: Update dependencies.
4495 * sem_util.adb, exp_ch5.adb: Minor reformatting.
4496
4497 2011-08-01 Arnaud Charlet <charlet@adacore.com>
4498
4499 * gnat_rm.texi: Fix definition of Long_Integer.
4500
4501 2011-08-01 Ed Schonberg <schonberg@adacore.com>
4502
4503 * exp_aggr.adb: check limit size of static aggregate unconditionally,
4504 to prevent storage exhaustion.
4505 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
4506 finalized is a function body, insert the cleanup code before the final
4507 return statement, to prevent spurious warnings.
4508 * s-pooglo.ads: add overriding indicator.
4509
4510 2011-08-01 Ed Schonberg <schonberg@adacore.com>
4511
4512 * sem_ch4.adb (Operator_Check): improve error message when both a
4513 with_clause and a use_clause are needed to make operator usage legal.
4514 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
4515 determine whether a compilation unit is visible within an other,
4516 either through a with_clause in the current unit, or a with_clause in
4517 its library unit or one one of its parents.
4518
4519 2011-08-01 Ed Schonberg <schonberg@adacore.com>
4520
4521 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
4522 over an arbitrary expression of an array or container type.
4523 * lib-xref.adb: clarify comment.
4524
4525 2011-08-01 Bob Duff <duff@adacore.com>
4526
4527 * einfo.ads: Minor reformatting.
4528 * debug.adb: Minor comment improvement.
4529
4530 2011-08-01 Javier Miranda <miranda@adacore.com>
4531
4532 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
4533 consider hidden subprograms as valid candidates.
4534
4535 2011-08-01 Arnaud Charlet <charlet@adacore.com>
4536
4537 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
4538
4539 2011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
4540
4541 * gnat_ugn.texi: Fix typo.
4542
4543 2011-08-01 Robert Dewar <dewar@adacore.com>
4544
4545 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
4546 lib-xref.adb: Minor reformatting
4547
4548 2011-08-01 Gary Dismukes <dismukes@adacore.com>
4549
4550 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
4551 when to generate a call to Move_Final_List.
4552 (Has_Controlled_Parts): Remove this function.
4553
4554 2011-08-01 Geert Bosch <bosch@adacore.com>
4555
4556 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
4557 "," in choice list.
4558
4559 2011-08-01 Thomas Quinot <quinot@adacore.com>
4560
4561 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
4562 explicit raise of a predefined exception as Comes_From_Source if the
4563 original N_Raise_Statement comes from source.
4564
4565 2011-08-01 Robert Dewar <dewar@adacore.com>
4566
4567 * sinfo.ads: Add comment.
4568 * sem_ch6.adb: Minor reformatting.
4569
4570 2011-08-01 Robert Dewar <dewar@adacore.com>
4571
4572 * freeze.adb (Freeze_Entity): Refine check for bad component size
4573 clause to avoid rejecting confirming clause when atomic/aliased present.
4574
4575 2011-08-01 Ed Schonberg <schonberg@adacore.com>
4576
4577 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
4578 better determine whether an entity reference is a write.
4579 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
4580 subcomponent.
4581 * lib-xref.adb (Output_References): Do no suppress a read reference at
4582 the same location as an immediately preceeding modify-reference, to
4583 handle properly in-out actuals.
4584
4585 2011-08-01 Tristan Gingold <gingold@adacore.com>
4586
4587 * env.c (__gnat_setenv) [VMS]: Refine previous change.
4588
4589 2011-08-01 Quentin Ochem <ochem@adacore.com>
4590
4591 * i-cstrin.adb (New_String): Changed implementation, now uses only the
4592 heap to compute the result.
4593
4594 2011-08-01 Robert Dewar <dewar@adacore.com>
4595
4596 * atree.ads: Minor reformatting.
4597
4598 2011-08-01 Emmanuel Briot <briot@adacore.com>
4599
4600 * g-expect.adb (Get_Command_Output): Fix memory leak.
4601
4602 2011-08-01 Geert Bosch <bosch@adacore.com>
4603
4604 * cstand.adb (P_Float_Type): New procedure to print the definition of
4605 predefined fpt types.
4606 (P_Mixed_Name): New procedure to print a name using mixed case
4607 (Print_Standard): Use P_Float_Type for printing floating point types
4608 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
4609 precision IEEE float.
4610
4611 2011-08-01 Thomas Quinot <quinot@adacore.com>
4612
4613 * sem_ch3.adb: Minor reformatting.
4614
4615 2011-08-01 Ed Schonberg <schonberg@adacore.com>
4616
4617 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
4618 the completion of a generic function, insert the new body rather than
4619 rewriting the original.
4620
4621 2011-08-01 Yannick Moy <moy@adacore.com>
4622
4623 * sinfo.ads, errout.ads: Typos in comments.
4624
4625 2011-08-01 Robert Dewar <dewar@adacore.com>
4626
4627 * par-endh.adb: Minor reformatting.
4628
4629 2011-08-01 Robert Dewar <dewar@adacore.com>
4630
4631 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
4632 (Pre_Post_Aspects): New subtype.
4633 * par-ch12.adb (P_Generic): New syntax for aspects in packages
4634 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
4635 * par-ch7.adb (P_Package): Remove Decl parameter
4636 (P_Package): Handle new syntax for aspects (before IS)
4637 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
4638 new aspect syntax
4639 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
4640 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
4641 (P_Package): Remove Decl parameter
4642 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
4643 aspects
4644 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
4645 specs
4646 * sem_util.ads, sem_util.adb (Static_Boolean): New function
4647 * sinfo.ads: Document new syntax for aspects in packages etc.
4648 * sprint.adb: Handle new syntax of aspects before IS in package
4649
4650 2011-08-01 Thomas Quinot <quinot@adacore.com>
4651
4652 * atree.ads: Minor reformatting.
4653 * sem_prag.adb: Minor reformatting.
4654
4655 2011-08-01 Robert Dewar <dewar@adacore.com>
4656
4657 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
4658 case expr alternative.
4659
4660 2011-08-01 Ed Schonberg <schonberg@adacore.com>
4661
4662 * sem_ch12.adb: Fix typo.
4663
4664 2011-08-01 Geert Bosch <bosch@adacore.com>
4665
4666 * sem_prag.adb (Check_No_Link_Name): New procedure.
4667 (Process_Import_Or_Interface): Use Check_No_Link_Name.
4668 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
4669 instead of Standard_Long_Long_Float_Size global. Preparation for
4670 eventual removal of per type constants.
4671 * exp_util.ads (Get_Stream_Size): New function returning the stream
4672 size value of subtype E.
4673 * exp_util.adb (Get_Stream_Size): Implement new function.
4674 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
4675 function.
4676 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
4677 * einfo.adb:
4678 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
4679
4680 2011-08-01 Geert Bosch <bosch@adacore.com>
4681
4682 * cstand.adb: Fix comments.
4683 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
4684 count of arguments.
4685
4686 2011-08-01 Robert Dewar <dewar@adacore.com>
4687
4688 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
4689
4690 2011-08-01 Geert Bosch <bosch@adacore.com>
4691
4692 * atree.ads: Fix comment.
4693
4694 2011-08-01 Robert Dewar <dewar@adacore.com>
4695
4696 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
4697 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
4698 * par.adb: Add with for Namet.Sp.
4699 * par-tchk.adb: Minor reformatting.
4700
4701 2011-08-01 Vincent Celier <celier@adacore.com>
4702
4703 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
4704 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
4705 of the init procedure of a SAL.
4706 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
4707 New procedure.
4708
4709 2011-08-01 Thomas Quinot <quinot@adacore.com>
4710
4711 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
4712 reformatting.
4713
4714 2011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
4715
4716 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
4717
4718 2011-08-01 Thomas Quinot <quinot@adacore.com>
4719
4720 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
4721 conformant with its spec (return True only for types that have
4722 an overriding Initialize primitive operation that prevents them from
4723 having preelaborable initialization).
4724 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
4725 initialization for controlled types in Ada 2005 or later mode.
4726
4727 2011-08-01 Robert Dewar <dewar@adacore.com>
4728
4729 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
4730 Postcondition.
4731 (Same_Aspect): New function.
4732 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
4733 Type_Invariant, Precondition, Postcondition.
4734 * snames.ads-tmpl: Add Name_Type_Invariant.
4735
4736 2011-08-01 Robert Dewar <dewar@adacore.com>
4737
4738 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
4739 here.
4740 (Freeze_All_Ent): Fix error in handling inherited aspects.
4741 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
4742 already analyzed, but don't skip entire processing of a declaration,
4743 that's wrong in some cases of declarations being rewritten.
4744 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
4745 Don't delay for integer, string literals
4746 Treat predicates in usual manner for delay, remove special case code,
4747 not needed.
4748 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
4749 (Build_Predicate_Function): Update saved expression in aspect
4750 (Build_Invariant_Procedure): Update saved expression in aspect
4751 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
4752 of replacement of discriminant references if the reference is simple.
4753
4754 2011-08-01 Robert Dewar <dewar@adacore.com>
4755
4756 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
4757 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
4758 Static_Predicate and Dynamic_Predicate.
4759 (Build_Predicate_Function): Add processing for Static_Predicate
4760 and Dynamic_Predicate.
4761 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
4762 (From_Static_Predicate): New flag
4763 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
4764
4765 2011-08-01 Robert Dewar <dewar@adacore.com>
4766
4767 * usage.adb: Documentation cleanup for Ada version modes in usage.
4768 * expander.adb: Minor reformatting.
4769
4770 2011-08-01 Robert Dewar <dewar@adacore.com>
4771
4772 * atree.ads: Minor comment fix.
4773 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
4774 a-witeio.ads, sem_prag.adb: Minor reformatting.
4775
4776 2011-08-01 Doug Rupp <rupp@adacore.com>
4777
4778 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
4779 pointers. Use descrip.h header file for convenience. Add some
4780 comments.
4781
4782 2011-08-01 Robert Dewar <dewar@adacore.com>
4783
4784 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
4785 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
4786 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
4787 New procedure.
4788 (Check_Aspect_At_End_Of_Declarations): New procedure
4789 (Analye_Aspect_Specification): Minor changes for above procedures
4790 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
4791 specification node as well.
4792
4793 2011-08-01 Pascal Obry <obry@adacore.com>
4794
4795 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
4796 Windows files. Use GetFilesAttributes() in this case to check for file
4797 existence instead of returning with an error code.
4798
4799 2011-08-01 Vincent Celier <celier@adacore.com>
4800
4801 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
4802 High is above Source length.
4803
4804 2011-08-01 Robert Dewar <dewar@adacore.com>
4805
4806 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
4807
4808 2011-08-01 Robert Dewar <dewar@adacore.com>
4809
4810 * aspects.ads (Boolean_Aspects): New subtype.
4811 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
4812 for derived types in cases where the parent type and derived type have
4813 aspects.
4814 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
4815 with aspects when parent type also has aspects.
4816 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
4817 boolean expression at this point).
4818 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
4819 accordance with final decision on the Ada 2012 feature.
4820 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
4821
4822 2011-08-01 Matthew Heaney <heaney@adacore.com>
4823
4824 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
4825
4826 2011-08-01 Pascal Obry <obry@adacore.com>
4827
4828 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
4829 Fix Replace_Slice when High is above current string size.
4830 (Replace_Slice): Fix DL computation when High is above current
4831 string length.
4832
4833 2011-08-01 Gary Dismukes <dismukes@adacore.com>
4834
4835 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
4836
4837 2011-08-01 Matthew Heaney <heaney@adacore.com>
4838
4839 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
4840 of node.
4841
4842 2011-08-01 Pascal Obry <obry@adacore.com>
4843
4844 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
4845 reformatting.
4846
4847 2011-08-01 Ed Schonberg <schonberg@adacore.com>
4848
4849 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
4850 access to protected subprograms in generic bodies.
4851 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
4852 protected type, indicate that the convention of the subprogram is
4853 Convention_Protected, because it may be used in subsequent declarations
4854 within the protected declaration.
4855
4856 2011-08-01 Vincent Celier <celier@adacore.com>
4857
4858 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
4859 and "final" procedures when the name of the library is "ada", to avoid
4860 duplicate symbols "adainit" and "adafinal" in executables.
4861
4862 2011-08-01 Ed Schonberg <schonberg@adacore.com>
4863
4864 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
4865 quantified expression that appears within a postcondition and uses the
4866 Ada2012 'Result attribute.
4867
4868 2011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4869
4870 * init.c (__gnat_error_handler): Cast reason to int.
4871 (__gnat_install_handler): Explain sa_sigaction use.
4872
4873 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
4874
4875 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
4876 subprogram has copy-in copy-out parameters, try to promote the mode of
4877 the return type if it is passed in registers.
4878
4879 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
4880
4881 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
4882 left operand as addressable.
4883
4884 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
4885
4886 * gcc-interface/gigi.h (build_function_stub): Remove.
4887 (build_return_expr): Likewise.
4888 (convert_vms_descriptor): Declare.
4889 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
4890 (build_function_stub): Move to...
4891 * gcc-interface/utils2.c (build_return_expr): Move to...
4892 * gcc-interface/trans.c (build_function_stub): ...here.
4893 (build_return_expr): ...here.
4894 (Subprogram_Body_to_gnu): Add local variable for language_function.
4895 Disconnect the parameter attributes cache, if any, once done with it.
4896 Call end_subprog_body only after setting the end_locus.
4897 Build the stub associated with the function, if any, at the very end.
4898 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
4899 variables and streamline control flow.
4900
4901 2011-07-23 Arnaud Charlet <charlet@adacore.com>
4902
4903 PR ada/49819
4904 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
4905 g-trasym-dwarf.adb.
4906
4907 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4908
4909 PR bootstrap/49794
4910 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
4911 Assign to act.sa_sigaction.
4912 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
4913 current->return_address to char * before arithmetic.
4914
4915 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4916
4917 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
4918 Correct argument types.
4919 Extract code from reason.
4920 (__gnat_install_handler): Assign to act.sa_sigaction.
4921
4922 2011-07-21 Eric Botcazou <ebotcazou@adacore.com>
4923
4924 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
4925 (GNAT1_OBJS): ...here.
4926
4927 2011-07-15 Eric Botcazou <ebotcazou@adacore.com>
4928
4929 PR ada/48711
4930 * g-socthi-mingw.adb (Fill): Fix formatting.
4931
4932 * gcc-interface/gigi.h: Move around comment.
4933
4934 2011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
4935
4936 PR ada/46350
4937 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
4938
4939 2011-07-14 Florian Weimer <fw@deneb.enyo.de>
4940
4941 PR ada/48711
4942 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
4943
4944 2011-07-13 Eric Botcazou <ebotcazou@adacore.com>
4945
4946 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
4947 range comparison if Pmode is SImode.
4948
4949 2011-07-12 Laurent GUERBY <laurent@guerby.net>
4950 Eric Botcazou <ebotcazou@adacore.com>
4951
4952 * adadecode.c: Wrap up in extern "C" block.
4953 * adadecode.h: Likewise.
4954 * adaint.c: Likewise. Remove 'const' keyword.
4955 * adaint.h: Likewise.
4956 * argv.c: Likewise.
4957 * atree.h: Likewise.
4958 * cio.c: Likewise.
4959 * cstreams.c: Likewise.
4960 * env.c: Likewise.
4961 * exit.c: Likewise.
4962 * fe.h: Likewise.
4963 * final.c: Likewise.
4964 * init.c: Likewise.
4965 * initialize.c: Likewise.
4966 * link.c: Likewise.
4967 * namet.h: Likewise.
4968 * nlists.h: Likewise.
4969 * raise.c: Likewise.
4970 * raise.h: Likewise.
4971 * repinfo.h: Likewise.
4972 * seh_init.c: Likewise.
4973 * targext.c: Likewise.
4974 * tracebak.c: Likewise.
4975 * uintp.h: Likewise.
4976 * urealp.h: Likewise.
4977 * xeinfo.adb: Wrap up generated C code in extern "C" block.
4978 * xsinfo.adb: Likewise.
4979 * xsnamest.adb: Likewise.
4980 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
4981 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
4982 * gcc-interface/misc.c: Likewise.
4983 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
4984 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
4985 ada/targext.o here...
4986 (GNAT_ADA_OBJS): ...and not here.
4987 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
4988 (GNATBIND_OBJS): Reorder.
4989
4990 2011-07-07 Richard Henderson <rth@redhat.com>
4991
4992 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
4993 dwarf2out_frame_init.
4994
4995 2011-07-07 Eric Botcazou <ebotcazou@adacore.com>
4996
4997 * gcc-interface/misc.c (gnat_init): Tweak previous change.
4998
4999 2011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5000
5001 PR target/39150
5002 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
5003
5004 2011-07-06 Richard Guenther <rguenther@suse.de>
5005
5006 * gcc-interface/misc.c (gnat_init): Merge calls to
5007 build_common_tree_nodes and build_common_tree_nodes_2.
5008 Re-initialize boolean_false_node.
5009
5010 2011-07-02 Eric Botcazou <ebotcazou@adacore.com>
5011 Olivier Hainque <hainque@adacore.com>
5012 Nicolas Setton <setton@adacore.com>
5013
5014 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
5015 the type according to the ARTIFICIAL_P parameter.
5016 (create_type_decl): Likewise.
5017 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
5018
5019 2011-07-01 Eric Botcazou <ebotcazou@adacore.com>
5020
5021 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
5022 (gnatbind): Likewise.
5023
5024 2011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5025
5026 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
5027
5028 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
5029
5030 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
5031 local variable throughout. Remove useless call to Base_Type.
5032 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
5033 Take it also into account for the volatileness of the field. Set the
5034 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
5035
5036 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
5037
5038 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
5039 on a dereference built for a by-ref object if it has an address clause.
5040
5041 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
5042
5043 * einfo.ads (Address_Taken): Document use for the second argument of
5044 Asm_Input and Asm_Output attributes.
5045 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
5046 argument is an entity name, then set Address_Taken on it.
5047 <Attribute_Asm_Output>: Likewise.
5048 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
5049 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
5050 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
5051 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
5052
5053 2011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
5054
5055 PR middle-end/46500
5056 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
5057
5058 2011-06-14 Joseph Myers <joseph@codesourcery.com>
5059
5060 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
5061 (ada/utils.o): Update dependencies.
5062 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
5063 ../../../libcpp/libcpp.a.
5064 * gcc-interface/utils.c: Include common/common-target.h.
5065 (process_attributes): Use targetm_common.have_named_sections.
5066
5067 2011-06-07 Richard Guenther <rguenther@suse.de>
5068
5069 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
5070 set_sizetype.
5071
5072 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
5073
5074 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
5075 TREE_THIS_NOTRAP flag.
5076
5077 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
5078
5079 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
5080 Fix thinko.
5081
5082 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
5083
5084 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
5085 constants whose full view has discriminants specially.
5086
5087 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
5088
5089 * gcc-interface/utils.c: Include diagnostic.h.
5090 (gnat_write_global_declarations): Output debug information for all
5091 global type declarations before finalizing the compilation unit.
5092 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
5093
5094 2011-05-25 Jakub Jelinek <jakub@redhat.com>
5095
5096 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
5097
5098 2011-05-25 Kai Tietz <ktietz@redhat.com>
5099
5100 * adaint.c (__gnat_to_canonical_file_list_next): Use array
5101 initialization instead of const/none-const pointer assignment.
5102
5103 2011-05-24 Joseph Myers <joseph@codesourcery.com>
5104
5105 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
5106 $(EXTRA_GNAT1_OBJS).
5107 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
5108 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
5109 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
5110 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
5111 libcommon-target.a instead of prefix.o.
5112
5113 2011-05-21 Joseph Myers <joseph@codesourcery.com>
5114
5115 PR ada/49097
5116 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
5117
5118 2011-05-20 Joseph Myers <joseph@codesourcery.com>
5119
5120 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
5121 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
5122 instead of version.o.
5123
5124 2011-05-18 Kai Tietz <ktietz@redhat.com>
5125
5126 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
5127 boolean_false_node instead of integer_zero_node.
5128 (convert_with_check): Likewise.
5129 * gcc-interface/decl.c (choices_to_gnu): Likewise.
5130
5131 2011-05-12 Eric Botcazou <ebotcazou@adacore.com>
5132
5133 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
5134 type of the parameter is an unconstrained array, convert the actual to
5135 the type of the formal in the In Out and Out cases as well.
5136
5137 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
5138
5139 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
5140 call build_function_type_array or build_varargs_function_type_array
5141 instead.
5142 (create_subprog_type): Don't call build_function_type; call
5143 build_function_type_vec instead.
5144
5145 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
5146
5147 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
5148 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
5149 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
5150
5151 2011-05-07 Eric Botcazou <ebotcazou@adacore.com>
5152
5153 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
5154
5155 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
5156 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
5157
5158 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
5159
5160 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
5161
5162 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
5163
5164 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
5165 instead of accessing TYPE_ARG_TYPES directly.
5166 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
5167
5168 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
5169
5170 PR ada/48844
5171 * gcc-interface/gigi.h (get_variant_part): Declare.
5172 * gcc-interface/decl.c (get_variant_part): Make global.
5173 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
5174 types have the same constant size, are record types and T1 has a
5175 variant part while T2 doesn't.
5176
5177 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
5178
5179 * gcc-interface/utils.c (begin_subprog_body): Do not call
5180 get_pending_sizes.
5181 (end_subprog_body): Likewise.
5182
5183 2011-05-04 Richard Guenther <rguenther@suse.de>
5184
5185 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
5186 int_const_binop.
5187 (pos_to_constructor): Likewise.
5188
5189 2011-05-03 Nathan Froyd <froydnj@codesourcery.com>
5190 Eric Botcazou <ebotcazou@adacore.com>
5191
5192 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
5193 of build_function_type. Adjust calls to...
5194 (build_raise_check): ...this. Do not take a void_tree parameter.
5195 Call build_function_type_list instead of build_function_type.
5196 Fix head comment and swap couple of conditional blocks.
5197
5198 2011-04-30 Eric Botcazou <ebotcazou@adacore.com>
5199
5200 * gnatvsn.ads (Library_Version): Bump to 4.7.
5201 (Current_Year): Bump to 2011.
5202
5203 2011-04-29 Michael Matz <matz@suse.de>
5204
5205 * gcc-interface/misc.c (gnat_handle_option): Set
5206 warn_maybe_uninitialized.
5207
5208 2011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
5209
5210 * gnat_ugn.texi (Complexity Metrics Control): Update link to
5211 the Watson/McCabe paper.
5212
5213 2011-04-23 Jim Meyering <meyering@redhat.com>
5214
5215 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
5216
5217 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
5218
5219 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
5220 onto the new type.
5221
5222 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
5223
5224 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
5225 parameter.
5226 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
5227 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
5228 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
5229 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
5230 <all>: Do not set flags on the reused DECL node coming from an alias.
5231 Set DECL_IGNORED_P on the DECL node built for subprograms if they
5232 don't need debug info here...
5233 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
5234 (gigi): Adjust calls to create_subprog_decl.
5235 (build_raise_check): Likewise.
5236 (establish_gnat_vms_condition_handler): Likewise.
5237 (Compilation_Unit_to_gnu): Likewise.
5238 (gnat_to_gnu): Likewise.
5239
5240 2011-04-21 Eric Botcazou <ebotcazou@adacore.com>
5241
5242 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
5243 (NO_REORDER_ADAFLAGS): New variable.
5244 (EXTRA_GNATTOOLS): Always define.
5245 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
5246 Clean up and adjust list of files compiled with special options.
5247 * gcc-interface/Make-lang.in: Likewise.
5248 (ada/decl.o): Cosmetical change.
5249 (ada/misc.o): Remove dependency on $(PLUGIN_H).
5250
5251 2011-04-20 Jim Meyering <meyering@redhat.com>
5252
5253 * initialize.c (__gnat_initialize): Remove useless if-before-free.
5254
5255 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
5256
5257 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
5258 $(CFLAGS) on the link line.
5259
5260 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
5261
5262 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
5263 padded type built for the return type if it is unconstrained.
5264
5265 2011-04-14 Nathan Froyd <froydnj@codesourcery.com>
5266
5267 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
5268
5269 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
5270
5271 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
5272 before calling TREE_CHAIN.
5273 * gcc-interface/misc.c (gnat_init_ts): New function.
5274 (LANG_HOOKS_INIT_TS): Define.
5275
5276 2011-04-12 Martin Jambor <mjambor@suse.cz>
5277
5278 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
5279 instead of cgraph_node.
5280
5281 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
5282
5283 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
5284 alignment on fields of the RETURN type built for the Copy-In Copy-Out
5285 mechanism.
5286
5287 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
5288
5289 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
5290 of aggregate types that contain a placeholder.
5291
5292 2011-04-08 Nathan Froyd <froydnj@codesourcery.com>
5293
5294 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
5295 TYPE_ARG_TYPES.
5296 (handle_type_generic_attribute): Likewise.
5297
5298 2011-04-04 Eric Botcazou <ebotcazou@adacore.com>
5299
5300 PR ada/47163
5301 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
5302
5303 2011-04-04 Kai Tietz <ktietz@redhat.com>
5304
5305 PR ada/47163
5306 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
5307 to flag value.
5308
5309 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
5310
5311 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
5312 type case, do not strip a padding type around the array type.
5313
5314 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
5315
5316 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
5317 types.
5318
5319 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
5320
5321 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
5322 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
5323 code for -feliminate-unused-debug-types.
5324 (gnat_post_options): Likewise.
5325
5326 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
5327
5328 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
5329 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
5330 distinct copy.
5331
5332 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
5333
5334 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
5335 DECL_ARTIFICIAL flag on enumeration types.
5336
5337 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
5338
5339 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
5340 fat pointer types artificial unconditionally.
5341 <E_Array_Subtype>: Attach the base array type as a parallel type if it
5342 isn't artificial.
5343
5344 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
5345
5346 * gcc-interface/gigi.h (get_dummy_type): Declare.
5347 (build_dummy_unc_pointer_types): Likewise.
5348 (finish_fat_pointer_type): Likewise.
5349 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
5350 fat pointer type has been built, complete it in place.
5351 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
5352 and thin pointers. Remove useless variable.
5353 (finish_fat_pointer_type): Make global and move to...
5354 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
5355 (get_dummy_type): New function.
5356 (build_dummy_unc_pointer_types): Likewise.
5357 (gnat_pushdecl): Propage the name to the anonymous variants only.
5358 (update_pointer_to): Only adjust the pointer types in the unconstrained
5359 array case.
5360
5361 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
5362
5363 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
5364 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
5365 if this is a Taft amendment type and the full declaration is available.
5366 * gcc-interface/trans.c (process_type): Likewise.
5367 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
5368 (process_freeze_entity): Likewise.
5369 * gcc-interface/utils.c (dummy_global): New static variable.
5370 (gnat_write_global_declarations): If there are types declared as used
5371 at the global level, insert them in the global hash table.
5372
5373 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
5374
5375 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
5376 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
5377 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
5378 copy.
5379 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
5380 flag of the type accordingly.
5381 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
5382
5383 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
5384
5385 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
5386 finalizing types when updating the pointers to the designated type.
5387 <all>: Finalize the deferred types even if we didn't defer processing
5388 of incomplete types in this invocation.
5389
5390 2011-04-01 Olivier Hainque <hainque@adacore.com>
5391 Nicolas Setton <setton@adacore.com>
5392 Eric Botcazou <ebotcazou@adacore.com>
5393
5394 * gcc-interface/misc.c (gnat_descriptive_type): New function.
5395 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
5396
5397 2011-03-28 Kai Tietz <ktietz@redhat.com>
5398
5399 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
5400 Windows targets.
5401 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
5402 * system-mingw.ads (System): Change ZCX_By_Default default to True.
5403
5404 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
5405
5406 2011-03-28 Tristan Gingold <gingold@adacore.com>
5407
5408 PR ada/44431
5409 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
5410 Use ada output of gnatbind.
5411 (ada/b_gnatb.adb): Ditto.
5412 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
5413 (ada.mostlyclean, ada.stage1)
5414 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
5415 (ada.stagefeedback): Adjust.
5416 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
5417 Use ada output of gnatbind.
5418 (b_gnatm.adb): Ditto.
5419 (b_gnatl.o, b_gnatm.o): New rules.
5420
5421 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
5422
5423 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
5424 for the padded type built to support a specified size or alignment.
5425
5426 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
5427
5428 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
5429 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
5430 unconditionally to the end of the unit when the designated type is
5431 limited_with'ed.
5432 <all>: Rename local variable. Attempt to un-defer types only and do it
5433 for limited_with'ed types as well.
5434 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
5435 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
5436 consistently and remove redundant call to finalize_from_with_types.
5437
5438 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
5439
5440 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
5441 subprograms without a previous spec declared in the same unit.
5442 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
5443 subprograms at the end of the unit instead of at the beginning.
5444 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
5445 isn't public for the special handling of non-inline functions nested
5446 inside inline external functions.
5447
5448 2011-03-25 Jeff Law <law@redhat.com>
5449
5450 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
5451
5452 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
5453
5454 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
5455 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
5456 to compute Set_Size_Depends_On_Discriminant.
5457 (Layout_Type): Call it on array types in back-end layout mode.
5458 * sem_util.adb (Requires_Transient_Scope): Return true for array
5459 types only if the size depends on the value of discriminants.
5460 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
5461 type if the RHS is a call to a function that returns an unconstrained
5462 type with default discriminant.
5463
5464 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
5465
5466 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
5467 non-conversion to the nominal result type at the end.
5468
5469 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
5470
5471 * gcc-interface/trans.c (create_temporary): New function taken from...
5472 (create_init_temporary): ...here. Call it.
5473 (call_to_gnu): Create the temporary for the return value early, if any.
5474 Create it for a function with copy-in/copy-out parameters if there is
5475 no target; in other cases of copy-in/copy-out, use another temporary.
5476 Push the new binding level lazily. Add and rename local variables.
5477
5478 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
5479
5480 * gcc-interface/decl.c (validate_size): Improve comments and tweak
5481 error message.
5482 (set_rm_size): Likewise.
5483
5484 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
5485
5486 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
5487 for the padded type built in order to support a specified alignment.
5488 Fix incorrect formatting.
5489
5490 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
5491
5492 PR bootstrap/48216
5493 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
5494
5495 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
5496
5497 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
5498 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
5499 to the end of the list. Adjust recursive call. Rename local variable.
5500 If REORDER is true, reorder components of the record type.
5501 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
5502 components_to_record and adjust the parameter list.
5503
5504 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
5505
5506 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
5507 disabled, use the variable for bounds of loop iteration scheme.
5508
5509 2011-03-21 Kai Tietz <ktietz@redhat.com>
5510
5511 PR target/12171
5512 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
5513
5514 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
5515
5516 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
5517 out whether the expression is read-only. Short-circuit placeholder
5518 case and rename a couple of local variables.
5519
5520 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
5521
5522 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
5523 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
5524 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
5525 (convert): Deal with conversions from a smaller form type specially.
5526
5527 2011-02-14 Eric Botcazou <ebotcazou@adacore.com>
5528
5529 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
5530 its argument, except for the special -I- switch.
5531
5532 2011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
5533
5534 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
5535 "Ada Issues".
5536
5537 2011-02-08 Eric Botcazou <ebotcazou@adacore.com>
5538
5539 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
5540
5541 2011-02-03 Eric Botcazou <ebotcazou@adacore.com>
5542
5543 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
5544 GNAT_FORMAL.
5545 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
5546 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
5547 instead of GNAT_FORMAL. Protect the expression against multiple uses.
5548 Do not generate the check directly, instead instantiate the template
5549 check present in the descriptor.
5550 (make_descriptor_field): Move around.
5551 (build_vms_descriptor32): Build a template check in the POINTER field.
5552 (build_vms_descriptor): Remove useless suffixes.
5553 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
5554
5555 2011-01-26 Eric Botcazou <ebotcazou@adacore.com>
5556
5557 PR bootstrap/47467
5558 * targext.c: Include target files if IN_RTS is defined.
5559
5560 2011-01-26 Richard Guenther <rguenther@suse.de>
5561
5562 PR bootstrap/47467
5563 * targext.c: Include config.h.
5564 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
5565 dependency.
5566
5567 2011-01-04 Pascal Obry <obry@adacore.com>
5568 Eric Botcazou <ebotcazou@adacore.com>
5569
5570 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
5571
5572 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
5573
5574 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
5575 end-of-case on the end label and its associated gotos, if any.
5576
5577 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
5578
5579 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
5580 expressions of the parameter cache within the statement group of
5581 the CICO mechanism.
5582
5583 2011-01-04 Olivier Hainque <hainque@adacore.com>
5584 Eric Botcazou <ebotcazou@adacore.com>
5585
5586 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
5587 (set_end_locus_from_node): New function.
5588 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
5589 make and the function end_locus.
5590 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
5591 for the elaboration subprogram.
5592 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
5593 set the end_locus of the expression as well.
5594
5595 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
5596
5597 PR ada/47131
5598 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
5599 variables that are referenced in exception handlers volatile.
5600
5601
5602 \f
5603 Copyright (C) 2011 Free Software Foundation, Inc.
5604
5605 Copying and distribution of this file, with or without modification,
5606 are permitted in any medium without royalty provided the copyright
5607 notice and this notice are preserved.
5608
5609 * gnat_rm.texi: Ramification of pragma Eliminate documentation
5610 - fix bugs in the description of Source_Trace;
5611 - get rid of UNIT_NAME;
5612
5613 2011-08-02 Javier Miranda <miranda@adacore.com>
5614
5615 * exp_ch9.adb
5616 (Build_Dispatching_Requeue): Adding support for VM targets
5617 since we cannot directly reference the Tag entity.
5618 * exp_sel.adb (Build_K): Adding support for VM targets.
5619 (Build_S_Assignment): Adding support for VM targets.
5620 * exp_disp.adb
5621 (Default_Prim_Op_Position): In VM targets do not restrict availability
5622 of predefined interface primitives to compiling in Ada 2005 mode.
5623 (Is_Predefined_Interface_Primitive): In VM targets this service is not
5624 restricted to compiling in Ada 2005 mode.
5625 (Make_VM_TSD): Generate code that declares and initializes the OSD
5626 record. Needed to support dispatching calls through synchronized
5627 interfaces.
5628 * exp_ch3.adb
5629 (Make_Predefined_Primitive_Specs): Enable generation of predefined
5630 primitives associated with synchronized interfaces.
5631 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
5632 primitives associated with synchronized interfaces.
5633
5634 2011-08-02 Yannick Moy <moy@adacore.com>
5635
5636 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
5637 statements hidden in SPARK if preceded by the HIDE directive
5638 (Parse_Exception_Handlers): mark each exception handler in a sequence of
5639 exception handlers as hidden in SPARK if preceded by the HIDE directive
5640 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
5641 if starting with the HIDE directive
5642 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
5643 starting with the HIDE directive; mark the declarations in a private
5644 part as hidden in SPARK if the private part starts with the HIDE
5645 directive
5646 * restrict.adb, restrict.ads
5647 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
5648 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
5649 argument node belongs to a part which is hidden in SPARK
5650 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
5651 parts in SPARK; protect the possibly costly call to
5652 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
5653 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
5654 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
5655 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
5656 Tok_SPARK_Hide.
5657 (Scan): recognize special comment starting with '#' and followed by
5658 SPARK keyword "hide" as a HIDE directive.
5659
5660 2011-08-02 Yannick Moy <moy@adacore.com>
5661
5662 * types.ads, erroutc.ads: Minor reformatting.
5663
5664 2011-08-02 Vincent Celier <celier@adacore.com>
5665
5666 * link.c: Add response file support for cross platforms.
5667
5668 2011-08-02 Ed Schonberg <schonberg@adacore.com>
5669
5670 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
5671 in an association, set parent field of copy before partial analysis.
5672 * sem_res.adb (Resolve_Slice): create reference to itype only when
5673 expansion is enabled.
5674
5675 2011-08-02 Yannick Moy <moy@adacore.com>
5676
5677 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
5678 for new flag denoting which subprogram bodies are in ALFA
5679 * restrict.adb, sem_ch7.adb: Update comment
5680 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
5681 sem_ch9.adb, sem_res.adb: Add calls to
5682 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
5683 * sem_ch6.adb (Analyze_Function_Return): add calls to
5684 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
5685 middle of the body, and extended return.
5686 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
5687 False when missing return.
5688 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
5689 to True for subprograms whose spec is in ALFA. Remove later on the flag
5690 on the entity used for a subprogram body when there exists a separate
5691 declaration.
5692 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
5693 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
5694 False, otherwise do nothing.
5695
5696 2011-08-02 Robert Dewar <dewar@adacore.com>
5697
5698 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
5699
5700 2011-08-02 Yannick Moy <moy@adacore.com>
5701
5702 * sem_ch4.ads: minor formatting.
5703
5704 2011-08-02 Yannick Moy <moy@adacore.com>
5705
5706 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
5707 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
5708 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
5709 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
5710 opt.ads: cleanup of SPARK mode
5711
5712 2011-08-02 Yannick Moy <moy@adacore.com>
5713
5714 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
5715 types.
5716 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
5717 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
5718 * sem_ch3.adb
5719 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
5720 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
5721 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
5722 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
5723 types.
5724 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
5725 non-static range.
5726 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
5727 functions whose return type is not in ALFA.
5728 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
5729 specifications.
5730 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
5731 parameter's type is not in ALFA.
5732 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
5733 types are in ALFA.
5734
5735 2011-08-02 Ed Schonberg <schonberg@adacore.com>
5736
5737 * sem_ch6 (Analyze_Expression_Function): treat the function as
5738 Inline_Always, and introduce a subprogram declaration for it when it is
5739 not a completion.
5740 * inline.adb (Add_Inlined_Body): recognize bodies that come from
5741 expression functions, so that the back-end can determine whether they
5742 can in fact be inlined.
5743 * sem_util.adb (Is_Expression_Function): predicate to determine whether
5744 a function body comes from an expression function.
5745
5746 2011-08-02 Gary Dismukes <dismukes@adacore.com>
5747
5748 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
5749 null exclusions to test Can_Never_Be_Null on the anonymous access types
5750 of the formals rather than testing the formals themselves. Exclude this
5751 check in cases where the Old_Formal is marked as a controlling formal,
5752 to avoid issuing spurious errors for bodies completing dispatching
5753 operations (due to the flag not getting set on controlling access
5754 formals in body specs).
5755 (Find_Corresponding_Spec): When checking full and subtype conformance of
5756 subprogram bodies in instances, pass Designated and E in that order, for
5757 consistency with the expected order of the formals (New_Id followed by
5758 Old_Id).
5759
5760 2011-08-02 Robert Dewar <dewar@adacore.com>
5761
5762 * sem_ch8.adb: Minor reformatting.
5763
5764 2011-08-02 Ed Schonberg <schonberg@adacore.com>
5765
5766 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
5767 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
5768 primitive operations of class-wide actuals.
5769
5770 2011-08-02 Javier Miranda <miranda@adacore.com>
5771
5772 * exp_atag.ads, exp_atag.adb
5773 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
5774 since its value is implicitly passed in argument Typ.
5775 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
5776 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
5777 Build_Common_Dispatching_Select_Statements.
5778
5779 2011-08-02 Robert Dewar <dewar@adacore.com>
5780
5781 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
5782 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
5783 Minor reformatting.
5784
5785 2011-08-02 Robert Dewar <dewar@adacore.com>
5786
5787 * sem_res.adb: Minor reformatting.
5788 * sem_prag.adb: Minor reformatting.
5789
5790 2011-08-02 Javier Miranda <miranda@adacore.com>
5791
5792 * exp_atag.adb, exp_atags.ads
5793 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
5794 by the tagged type Entity. Required to use this routine in the VM
5795 targets since we do not have available the Tag entity in the VM
5796 platforms.
5797 * exp_ch6.adb
5798 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
5799 Ada.Tags has not been previously loaded.
5800 * exp_ch7.adb
5801 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
5802 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
5803 * sem_aux.adb
5804 (Enclosing_Dynamic_Scope): Add missing support to handle the full
5805 view of enclosing scopes. Required to handle enclosing scopes that
5806 are synchronized types whose full view is a task type.
5807 * exp_disp.adb
5808 (Build_VM_TSDs): Minor code improvement to avoid generating and
5809 analyzing lists with empty nodes.
5810 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
5811 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
5812 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
5813 (Make_Disp_Timed_Select_Body): Add support for VM targets.
5814 (Make_Select_Specific_Data_Table): Add support for VM targets.
5815 (Make_VM_TSD): Generate code to initialize the SSD structure of
5816 the TSD.
5817
5818 2011-08-02 Yannick Moy <moy@adacore.com>
5819
5820 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
5821 cross-references section in ALI.
5822 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
5823 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
5824 Sub).
5825 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
5826 subprogram or package entity of a node
5827 (Is_Local_Reference_Type): new function returns True for references
5828 selected in local cross-references.
5829 (Lt): function extracted from Lt in Output_References
5830 (Write_Entity_Name): function extracted from Output_References
5831 (Generate_Definition): generate reference with type 'D' for definition
5832 of objects (object declaration and parameter specification), with
5833 appropriate locations and units, for use in local cross-references.
5834 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
5835 references of type 'I' for initialization in object definition.
5836 (Output_References): move part of function Lt and procedure
5837 Write_Entity_Name outside of the body. Ignore references of types 'D'
5838 and 'I' introduced for local cross-references.
5839 (Output_Local_References): new procedure to output the local
5840 cross-references sections.
5841 (Lref_Entity_Status): new array defining whether an entity is a local
5842 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
5843 with 'I' type when initialization expression is present.
5844 * get_scos.adb, get_scos.ads: Correct comments and typos
5845
5846 2011-08-02 Javier Miranda <miranda@adacore.com>
5847
5848 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
5849 the JVM target.
5850 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
5851 the JVM target.
5852 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
5853 TSD support.
5854
5855 2011-08-02 Vincent Celier <celier@adacore.com>
5856
5857 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
5858 (No_Space_Img): New function
5859 (Find_Excluded_Sources): When reading from a file, record the file name
5860 and the line number for each excluded source.
5861 (Mark_Excluded_Sources): When reporting an error, if the excluded
5862 sources were read from a file, include file name and line number in
5863 the error message.
5864
5865 2011-08-02 Ed Schonberg <schonberg@adacore.com>
5866
5867 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
5868
5869 2011-08-02 Robert Dewar <dewar@adacore.com>
5870
5871 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
5872
5873 2011-08-02 Javier Miranda <miranda@adacore.com>
5874
5875 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
5876 generation of TSDs to the DOTNET compiler.
5877 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
5878 generation of TSDs to the DOTNET compiler.
5879
5880 2011-08-02 Javier Miranda <miranda@adacore.com>
5881
5882 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
5883 record of all the tagged types declared inside library level package
5884 declarations, library level package bodies or library level subprograms.
5885 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
5886 associated with a given tagged type.
5887 (Build_VM_TSDs): New subprogram.
5888 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
5889 compilation units that are subprograms.
5890 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
5891 compilation units that are package bodies.
5892 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
5893 units that are a package declaration or a package instantiation.
5894 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
5895 reorganization to improve the error generated by the frontend when the
5896 function Ada.Tags.Secondary_Tag is not available.
5897 * rtsfind.ads (RE_Register_TSD): New runtime entity.
5898 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
5899
5900 2011-08-02 Javier Miranda <miranda@adacore.com>
5901
5902 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
5903
5904 2011-08-02 Robert Dewar <dewar@adacore.com>
5905
5906 * s-imenne.ads: Minor reformatting.
5907
5908 2011-08-02 Robert Dewar <dewar@adacore.com>
5909
5910 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
5911 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
5912 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
5913
5914 2011-08-02 Robert Dewar <dewar@adacore.com>
5915
5916 * einfo.ads (Materialize_Entity): Document this is only for renamings
5917 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
5918 required debug information in the case where we transform the object
5919 declaration into a renaming declaration.
5920 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
5921 object
5922 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
5923 Materialize_Entity.
5924
5925 2011-08-02 Robert Dewar <dewar@adacore.com>
5926
5927 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
5928 Suppress_Init_Procs.
5929 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
5930 Suppress_Initialization/Initialization_Suppressed.
5931 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
5932 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
5933 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
5934 * sem_prag.adb: New processing for pragma Suppress_Initialization.
5935
5936 2011-08-02 Robert Dewar <dewar@adacore.com>
5937
5938 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
5939 Minor reformatting.
5940
5941 2011-08-02 Ed Schonberg <schonberg@adacore.com>
5942
5943 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
5944 only have inheritable classwide pre/postconditions.
5945
5946 2011-08-02 Javier Miranda <miranda@adacore.com>
5947
5948 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
5949 * rtsfind.ads (RE_Check_TSD): New runtime entity.
5950 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
5951 checks if the external tag of a type is the same as the external tag
5952 of some other declaration.
5953
5954 2011-08-02 Thomas Quinot <quinot@adacore.com>
5955
5956 * s-taskin.ads: Minor reformatting.
5957
5958 2011-08-02 Emmanuel Briot <briot@adacore.com>
5959
5960 * g-comlin.adb (Display_Help): swap the order in which it prints the
5961 short help and the general usage.
5962
5963 2011-08-02 Ed Schonberg <schonberg@adacore.com>
5964
5965 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
5966 the aspect declarations and attach them to the generic copy for
5967 subsequent analysis.
5968 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
5969 declarations of the generic tree to the new subprogram declarations.
5970 * sem_attr.adb (Check_Precondition_Postcondition): recognize
5971 conditions that apply to a subprogram instance.
5972
5973 2011-08-02 Robert Dewar <dewar@adacore.com>
5974
5975 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
5976
5977 2011-08-02 Ed Schonberg <schonberg@adacore.com>
5978
5979 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
5980 private type with a tagged full view is not derived in the immediate
5981 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
5982
5983 2011-08-02 Robert Dewar <dewar@adacore.com>
5984
5985 * exp_ch4.adb: Minor reformatting.
5986
5987 2011-08-02 Ed Schonberg <schonberg@adacore.com>
5988
5989 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
5990 Ada2012 iterator, the loop will be rewritten during expansion into a
5991 while loop with a cursor and an element declaration. Do not analyze the
5992 body in this case, because if the container is for indefinite types the
5993 actual subtype of the elements will only be determined when the cursor
5994 declaration is analyzed.
5995
5996 2011-08-02 Arnaud Charlet <charlet@adacore.com>
5997
5998 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
5999 size/alignment related attributes in CodePeer_Mode.
6000
6001 2011-08-02 Gary Dismukes <dismukes@adacore.com>
6002
6003 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
6004 Prepend_Element, since this can result in the operation getting the
6005 wrong slot in the full type's dispatch table if the full type has
6006 inherited operations. The incomplete type's operation will get added
6007 to the proper position in the full type's primitives
6008 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
6009 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
6010 dispatching operations, since there are cases where nonprimitive
6011 subprograms can get added to the list of incomplete dependents (such
6012 as subprograms in nested packages).
6013 * sem_ch6.adb (Process_Formals): First, remove test for being in a
6014 private part when determining whether to add a primitive with a
6015 parameter of a tagged incomplete type to the Private_Dependents list.
6016 Such primitives can also occur in the visible part, and should not have
6017 been excluded from being private dependents.
6018 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
6019 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
6020 list of a Taft-amendment incomplete type is a primitive before issuing
6021 an error that the full type must appear in the same unit. There are
6022 cases where nonprimitives can be in the list (such as subprograms in
6023 nested packages).
6024 * sem_disp.adb (Derives_From): Use correct condition for checking that
6025 a formal's type is derived from the type of the corresponding formal in
6026 the parent subprogram (the condition was completely wrong). Add
6027 checking that was missing for controlling result types being derived
6028 from the result type of the parent operation.
6029
6030 2011-08-02 Yannick Moy <moy@adacore.com>
6031
6032 * errout.adb (First_Node): minor renaming
6033 * restrict.adb (Check_Formal_Restriction): put restriction warning on
6034 first node.
6035
6036 2011-08-02 Yannick Moy <moy@adacore.com>
6037
6038 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
6039 before accessing operands.
6040 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
6041 decide whether an initialization expression respects SPARK rules, as
6042 the plain node is the expanded one. This allows for more valid warnings
6043 to be issued.
6044 * gnat_rm.texi: Minor update.
6045
6046 2011-08-02 Arnaud Charlet <charlet@adacore.com>
6047
6048 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
6049 previous change.
6050
6051 2011-08-02 Robert Dewar <dewar@adacore.com>
6052
6053 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
6054
6055 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
6056
6057 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
6058 loop statements and the element renaming declaration with a block when
6059 the element type is controlled.
6060
6061 2011-08-02 Yannick Moy <moy@adacore.com>
6062
6063 * sinfo.ads: Minor formatting.
6064
6065 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6066
6067 * sem_aggr.adb (Add_Association): if the association has a box and no
6068 expression, use the Sloc of the aggregate itself for the new
6069 association.
6070 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
6071 the Original_Node.
6072
6073 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
6074
6075 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
6076 When a container is provided via a function call, generate a renaming
6077 of the function result. This avoids the creation of a transient scope
6078 and the premature finalization of the container.
6079 * exp_ch7.adb (Is_Container_Cursor): Removed.
6080 (Wrap_Transient_Declaration): Remove the supression of the finalization
6081 of the list controller when the declaration denotes a container cursor,
6082 it is not needed.
6083
6084 2011-08-02 Yannick Moy <moy@adacore.com>
6085
6086 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
6087 node is from source, instead of the original node being from source.
6088 * sem_aggr.adb
6089 (Resolve_Array_Aggregate): refine the check for a static expression, to
6090 recognize also static ranges
6091 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
6092 Array_Type_Declaration): postpone the test for the type being a subtype
6093 mark after the type has been resolved, so that component-selection and
6094 expanded-name are discriminated.
6095 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
6096 to distinguish the case of an iteration scheme, so that an error is
6097 issed on a non-static range in SPARK except in an iteration scheme.
6098 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
6099 In_Iter_Schm = True.
6100 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
6101 user-defined operators so that they are allowed in renaming
6102 * sem_ch8.adb
6103 (Find_Selected_Component): refine the check for prefixing of operators
6104 so that they are allowed in renaming. Move the checks for restrictions
6105 on selector name after analysis discriminated between
6106 component-selection and expanded-name.
6107 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
6108 concatenation argument of string type if it is static.
6109 * sem_util.adb, sem_util.ads
6110 (Check_Later_Vs_Basic_Declarations): add a new function
6111 Is_Later_Declarative_Item to decice which declarations are allowed as
6112 later items, in the two different modes Ada 83 and SPARK. In the SPARK
6113 mode, add that renamings are considered as later items.
6114 (Enclosing_Package): new function to return the enclosing package
6115 (Enter_Name): correct the rule for homonyms in SPARK
6116 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
6117 from source (result of expansion) to avoid issuing wrong warnings.
6118
6119 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6120
6121 * errout.adb: On anything but an expression First_Node returns its
6122 argument.
6123
6124 2011-08-02 Pascal Obry <obry@adacore.com>
6125
6126 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
6127
6128 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
6129
6130 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
6131 Set the associated loop as the related expression of internally
6132 generated cursors.
6133 * exp_ch7.adb (Is_Container_Cursor): New routine.
6134 (Wrap_Transient_Declaration): Supress the finalization of the list
6135 controller when the declaration denotes a container cursor.
6136
6137 2011-08-02 Yannick Moy <moy@adacore.com>
6138
6139 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
6140 command line now.
6141 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
6142 expression is a simple expression. This check cannot be performed in
6143 the semantics, so just drop it.
6144 (P_Index_Or_Discriminant_Constraint): move check that the index or
6145 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
6146 semantics. Other cases were previously checked in the semantics.
6147 * par-ch4.adb (P_Name): move checks that a selector name is not
6148 character literal or an operator symbol to Find_Selected_Component in
6149 the semantics
6150 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
6151 declarations are not placed after later declarations in a separate
6152 procedure in Sem_Util (possibly not the best choice?), to be used both
6153 during parsing, for Ada 83 mode, and during semantic analysis, for
6154 SPARK mode.
6155 * par-endh.adb (Check_End): move check that end label is not missing
6156 to Process_End_Label in the semantics
6157 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
6158 the special case for SPARK restriction
6159 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
6160 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
6161 parameter Force to issue the error message even on internal node (used
6162 for generated end label). Call Check_Restriction to check when an error
6163 must be issued. In SPARK mode, issue an error message even if the
6164 restriction is not set.
6165 (Check_Restriction): new procedure with an additional out parameter to
6166 inform the caller that a message has been issued
6167 * sem_aggr.adb: Minor modification of message
6168 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
6169 instead of issuing an error message directly
6170 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
6171 declarations are not placed after later declarations, by calling
6172 Check_Later_Vs_Basic_Declarations
6173 (Analyze_Subtype_Declaration): move here the check that an index or
6174 discriminant constraint must be a subtype mark. Change the check that
6175 a subtype of String must start at one so that it works on subtype marks.
6176 * sem_ch4.adb (Analyze_Call): move here the check that a named
6177 association cannot follow a positional one in a call
6178 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
6179 instead of issuing an error message directly
6180 * sem_ch8.adb (Find_Selected_Component): move here the check that a
6181 selector name is not a character literal or an operator symbol. Move
6182 here the check that the prefix of an expanded name cannot be a
6183 subprogram or a loop statement.
6184 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
6185 procedure called from parsing and semantics to check that basic
6186 declarations are not placed after later declarations
6187 (Process_End_Label): move here the check that end label is not missing
6188
6189 2011-08-02 Arnaud Charlet <charlet@adacore.com>
6190
6191 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
6192 representation clause in codepeer mode, since it confuses CodePeer and
6193 does not bring useful info.
6194
6195 2011-08-02 Ed Falis <falis@adacore.com>
6196
6197 * init.c: initialize fp hw on MILS.
6198
6199 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6200
6201 * errout.adb (First_Node): for bodies, return the node itself (small
6202 optimization). For other nodes, do not check source_unit if the node
6203 comes from Standard.
6204
6205 2011-08-02 Robert Dewar <dewar@adacore.com>
6206
6207 * exp_ch3.adb: Minor comment additions.
6208 * sem_ch13.adb: Minor reformatting.
6209
6210 2011-08-02 Pascal Obry <obry@adacore.com>
6211
6212 * make.adb, makeutl.adb: Removes some superfluous directory separator.
6213
6214 2011-08-02 Robert Dewar <dewar@adacore.com>
6215
6216 * sem_attr.adb: Minor reformatting.
6217
6218 2011-08-02 Robert Dewar <dewar@adacore.com>
6219
6220 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
6221 (Has_Default_Component_Value): Removed
6222 * einfo.ads Comment updates
6223 (Has_Default_Aspect): Replaces Has_Default_Value
6224 (Has_Default_Component_Value): Removed
6225 * exp_ch13.adb
6226 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
6227 * exp_ch3.adb
6228 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
6229 (Get_Simple_Init_Val): Handle Default_Value aspect
6230 (Needs_Simple_Initialization): Handle Default_Value aspect
6231 * exp_ch3.ads: Needs_Simple_Initialization
6232 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
6233 * par-prag.adb (Pragma_Default[_Component]Value) Removed
6234 * sem_ch13.adb
6235 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
6236 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
6237 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
6238
6239 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6240
6241 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
6242 package containing iteration primitives.
6243 exp_ch5.adb (Expand_Iterator_Loop): ditto.
6244
6245 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6246
6247 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
6248 "of", pre-analyze expression in case it is a function call with
6249 finalization actions that must be placed ahead of the loop.
6250 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
6251 on an Ada2012 iterator, insert them ahead of the rewritten loop.
6252
6253 2011-08-02 Geert Bosch <bosch@adacore.com>
6254
6255 * cstand.adb (Create_Float_Types): Only consider C's long double for
6256 Long_Long_Float, in addition to double.
6257
6258 2011-08-02 Robert Dewar <dewar@adacore.com>
6259
6260 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
6261 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
6262 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
6263 Minor reformatting.
6264
6265 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6266
6267 * sem_attr.adb: handle properly 'Result when it is a prefix of an
6268 indexed component.
6269
6270 2011-08-02 Javier Miranda <miranda@adacore.com>
6271
6272 * einfo.ads, einfo.adb
6273 (Original_Access_Type): Move this attribute to Node26 since there was
6274 an undocumented use of Node21 in E_Access_Subprogram_Type entities
6275 which causes conflicts and breaks the generation of the .NET compiler.
6276 (Interface_Name): Add missing documentation on JGNAT only uses of
6277 this attribute.
6278
6279 2011-08-02 Geert Bosch <bosch@adacore.com>
6280
6281 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
6282 (Find_Back_End_Float_Type): Likewise
6283 (Create_Back_End_Float_Types): Likewise
6284 (Create_Float_Types): Likewise
6285 (Register_Float_Type): Likewise
6286 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
6287 Nlist and split out type selection in new local Find_Base_Type function.
6288 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
6289 Nlist
6290 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
6291
6292 2011-08-02 Robert Dewar <dewar@adacore.com>
6293
6294 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
6295 alpha order).
6296 * opt.ads: Minor comment change.
6297 * sem_ch12.adb: Minor code reorganization.
6298
6299 2011-08-02 Gary Dismukes <dismukes@adacore.com>
6300
6301 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
6302 subtype's list of rep items to the list on the full subtype in the case
6303 where the lists are the same.
6304
6305 2011-08-02 Geert Bosch <bosch@adacore.com>
6306
6307 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
6308 using the one from System.Strings, which also deallocates all strings.
6309
6310 2011-08-02 Geert Bosch <bosch@adacore.com>
6311
6312 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
6313 function.
6314 * gcc-interface/Make-lang.in: Update dependencies.
6315
6316 2011-08-02 Olivier Hainque <hainque@adacore.com>
6317
6318 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
6319 end_locus.
6320
6321 2011-08-02 Javier Miranda <miranda@adacore.com>
6322
6323 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
6324 associated with anonymous access to subprograms.
6325
6326 2011-08-02 Geert Bosch <bosch@adacore.com>
6327
6328 * opt.ads
6329 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
6330 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
6331 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
6332 (Add_Symbol_Definition): Move to switch-c.adb
6333 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
6334 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
6335 (Add_Symbol_Definition): Move to switch-c.adb.
6336 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
6337 * sem_warn.adb
6338 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
6339 Move to warnsw.adb.
6340 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
6341 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
6342 Move to warnsw.adb.
6343 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
6344 (Add_Symbol_Definition): Moved from Prepcomp.
6345 * switch-c.ads: Update copyright notice. Use String_List instead of
6346 Argument_List, removing dependency on System.OS_Lib.
6347
6348 2011-08-02 Yannick Moy <moy@adacore.com>
6349
6350 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
6351 mode on initialization expression which does not respect SPARK
6352 restrictions.
6353 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
6354 if the tree referenced by its argument represents an initialization
6355 expression in SPARK, suitable for initializing an object in an object
6356 declaration.
6357
6358 2011-08-02 Javier Miranda <miranda@adacore.com>
6359
6360 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
6361 internally generated access to subprogram with its associated protected
6362 subprogram type.
6363 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
6364
6365 2011-08-02 Geert Bosch <bosch@adacore.com>
6366
6367 * cstand.adb (Register_Float_Type): Print information about type to
6368 register, if the Debug_Flag_Dot_B is set.
6369 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
6370 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
6371 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
6372 with a requested precision of more than Max_Digits digits and no more
6373 than Max_Base_Digits digits, if a range specification is present and the
6374 Predefined_Float_Types list has a suitable type to derive from.
6375 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
6376 case of type completion with pragma Import
6377 * sem_prag.adb
6378 (Process_Import_Predefined_Type): Processing to complete a type
6379 with pragma Import. Currently supports floating point types only.
6380 (Set_Convention_From_Pragma): Do nothing without underlying type.
6381 (Process_Convention): Guard against absence of underlying type,
6382 which may happen when importing incomplete types.
6383 (Process_Import_Or_Interface): Handle case of importing predefined
6384 types. Tweak error message.
6385
6386 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
6387
6388 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
6389 functions to previous change. Reorganize code slightly.
6390
6391 2011-08-02 Geert Bosch <bosch@adacore.com>
6392
6393 * back_end.ads (Register_Type_Proc): New call back procedure type for
6394 allowing the back end to provide information about available types.
6395 (Register_Back_End_Types): New procedure to register back end types.
6396 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
6397 available types.
6398 * cstand.adb (Back_End_Float_Types): New list for floating point types
6399 supported by the back end.
6400 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
6401 (Copy_Float_Type): New procedure to make new copies of predefined types.
6402 (Register_Float_Type): New call back procedure to populate the BEFT list
6403 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
6404 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
6405 (Create_Float_Types): New procedure to create entities for floating
6406 point types predefined in Standard, and put these and any remaining
6407 BEFTs on the Predefined_Float_Types list.
6408 * stand.ads (Predefined_Float_Types): New list for predefined floating
6409 point types that do not have declarations in package Standard.
6410
6411 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
6412
6413 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
6414 entity node for the unit containing the parameter.
6415 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
6416 (Add_Inlined_Subprogram): Likewise.
6417 * gcc-interface/Make-lang.in: Update dependencies.
6418
6419 2011-08-02 Thomas Quinot <quinot@adacore.com>
6420
6421 * s-stusta.adb (Print): Make sure Pos is always initialized to a
6422 suitable value.
6423
6424 2011-08-02 Geert Bosch <bosch@adacore.com>
6425
6426 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
6427
6428 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
6429
6430 * sem_type.adb (Covers): Move trivial case to the top and reuse the
6431 computed value of Base_Type.
6432
6433 2011-08-02 Yannick Moy <moy@adacore.com>
6434
6435 * restrict.adb (Check_Restriction): issue an error for any use of
6436 class-wide, even if the No_Dispatch restriction is not set.
6437 * sem_aggr.adb: Correct typos in comments and messages in formal mode
6438 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
6439 when completing a private extension, the type named in the private part
6440 is not the same as that named in the visible part.
6441 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
6442 of an inherited primitive operations of a tagged type or type extension
6443 that returns the tagged type.
6444 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
6445 function which returns True for an implicit operation inherited by the
6446 derived type declaration for the argument type.
6447 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
6448 order.
6449
6450 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6451
6452 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
6453 Process_Bounds, to perform analysis with expansion of a range or an
6454 expression that is the iteration scheme for a loop.
6455 (Analyze_Iterator_Specification): If domain of iteration is given by a
6456 function call with a controlled result, as is the case if call returns
6457 a predefined container, ensure that finalization actions are properly
6458 generated.
6459 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
6460
6461 2011-08-02 Javier Miranda <miranda@adacore.com>
6462
6463 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
6464 * gcc-interface/Make-lang.in: Update dependencies.
6465
6466 2011-08-02 Javier Miranda <miranda@adacore.com>
6467
6468 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
6469 determine if the analysis is performed using N or Original_Node (N).
6470 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
6471 functionality of routine Is_Variable avoids code duplication.
6472 * checks.adb (Determine_Range): Handle temporaries generated by
6473 Remove_Side_Effects.
6474
6475 2011-08-02 Javier Miranda <miranda@adacore.com>
6476
6477 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
6478 expansion of the condition. Required since the previous analysis was
6479 done with expansion disabled (see Resolve_Quantified_Expression) and
6480 hence checks were not inserted and record comparisons have not been
6481 expanded.
6482
6483 2011-08-02 Ed Falis <falis@adacore.com>
6484
6485 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
6486 Update header.
6487
6488 2011-08-02 Bob Duff <duff@adacore.com>
6489
6490 * opt.ads: Minor comment fix.
6491
6492 2011-08-02 Bob Duff <duff@adacore.com>
6493
6494 * sem_ch12.adb (Analyze_Package_Instantiation,
6495 Analyze_Subprogram_Instantiation): Turn off style checking while
6496 analyzing an instance. Whatever style checks that apply to the generic
6497 unit should apply, so it makes no sense to apply them in an instance.
6498 This was causing trouble when compiling an instance of a runtime
6499 unit that violates the -gnatyO switch.
6500 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
6501 one of the two case statements, causing spurious errors.
6502
6503 2011-08-02 Robert Dewar <dewar@adacore.com>
6504
6505 * uname.adb: Minor reformatting.
6506 * gnatcmd.adb: Minor reformatting.
6507 * exp_attr.adb: Minor reformatting.
6508
6509 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6510
6511 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
6512 No_Dispatching_Calls, do not look for the Assign primitive, because
6513 predefined primitives are not created in this case.
6514
6515 2011-08-02 Bob Duff <duff@adacore.com>
6516
6517 * stylesw.ads: Minor comment fixes.
6518
6519 2011-08-02 Robert Dewar <dewar@adacore.com>
6520
6521 * freeze.adb (Add_To_Result): New procedure.
6522
6523 2011-08-02 Jose Ruiz <ruiz@adacore.com>
6524
6525 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
6526 time, if the specific run-time routines for handling streams of strings
6527 are not available, use the default mechanism.
6528
6529 2011-08-02 Arnaud Charlet <charlet@adacore.com>
6530
6531 * s-regpat.ads: Fix typo.
6532
6533 2011-08-02 Vincent Celier <celier@adacore.com>
6534
6535 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
6536 not null, call it to create the in memory config project file without
6537 parsing an existing default config project file.
6538
6539 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
6540
6541 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
6542
6543 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6544
6545 * sem_elim.adb: an abstract subprogram does not need an eliminate
6546 pragma for its descendant to be eliminable.
6547
6548 2011-08-02 Ed Falis <falis@adacore.com>
6549
6550 * init.c: revert to handling before previous checkin for VxWorks
6551 * s-intman-vxworks.adb: delete unnecessary declarations related to
6552 using Ada interrupt facilities for handling signals.
6553 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
6554 * s-intman-vxworks.ads: Import __gnat_install_handler as
6555 Initialize_Interrupts.
6556 * s-taprop-vxworks.adb: Delete Signal_Mask.
6557 (Abort_Handler): change construction of mask to unblock exception
6558 signals.
6559
6560 2011-08-02 Jerome Guitton <guitton@adacore.com>
6561
6562 * a-except-2005.adb (Raise_From_Signal_Handler): Call
6563 Debug_Raise_Exception before propagation starts.
6564
6565 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
6566
6567 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
6568 to Restriction_Check_Required.
6569 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
6570 * sem_res.adb (Resolve_Call): Likewise.
6571 * sem_attr.adb (Check_Stream_Attribute): Likewise.
6572
6573 2011-08-02 Bob Duff <duff@adacore.com>
6574
6575 * stylesw.ads: Update comment.
6576 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
6577 * errout.ads: Remove obsolete comment.
6578
6579 2011-08-02 Javier Miranda <miranda@adacore.com>
6580
6581 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
6582 (Set_Is_Safe_To_Reevaluate): new procedure.
6583 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
6584 assignment is allowed on safe-to-reevaluate variables.
6585 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
6586 temporary created to remove side effects in expressions that use
6587 the secondary stack as safe-to-reevaluate.
6588 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
6589 variables that are not true constants.
6590
6591 2011-08-02 Robert Dewar <dewar@adacore.com>
6592
6593 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
6594 sem_res.adb, sem_ch6.adb: Minor reformatting.
6595
6596 2011-08-02 Jerome Guitton <guitton@adacore.com>
6597
6598 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
6599
6600 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6601
6602 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
6603 not set Overridden_Operation if subprogram is an initialization
6604 procedure.
6605
6606 2011-08-02 Yannick Moy <moy@adacore.com>
6607
6608 * par-ch6.adb: Correct obsolete name in comments
6609 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
6610 which takes two message arguments (existing function takes one), with
6611 second message used for continuation.
6612 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
6613 block statements that originate from a source block statement, not
6614 generated block statements
6615 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
6616 symmetry with procedure case
6617 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
6618 function to issue an error in formal mode if a package specification
6619 contains more than one tagged type or type extension.
6620 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
6621 parameters matching formals of tagged types are objects (or ancestor
6622 type conversions of objects), not general expressions. Issue an error
6623 on view conversions that are not involving ancestor conversion of an
6624 extended type.
6625 (Resolve_Type_Conversion): in formal mode, issue an error on the
6626 operand of an ancestor type conversion which is not an object
6627 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
6628 procedure so that it works also for actuals of function calls
6629 (Is_Actual_Tagged_Parameter): new function which determines if its
6630 argument is an actual parameter of a formal of tagged type in a
6631 subprogram call
6632 (Is_SPARK_Object_Reference): new function which determines if the tree
6633 referenced by its argument represents an object in SPARK
6634
6635 2011-08-02 Robert Dewar <dewar@adacore.com>
6636
6637 * sem_ch3.adb: Minor reformatting
6638 Minor comment addition
6639 Minor error msg text change
6640
6641 2011-08-02 Javier Miranda <miranda@adacore.com>
6642
6643 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
6644 function. Used to be more precise when we generate a variable plus one
6645 assignment to remove side effects in the evaluation of the Bound
6646 expressions.
6647 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
6648 of the bound expression to force its re-analysis and thus expand the
6649 associated transient scope (if required). Code cleanup replacing the
6650 previous code that declared the constant entity by an invocation to
6651 routine Force_Evaluation which centralizes this work in the frontend.
6652
6653 2011-08-02 Robert Dewar <dewar@adacore.com>
6654
6655 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
6656 (Base_Type): Now uses improved Is_Base_Type function
6657 * einfo.ads (Base_Type): Inline this function
6658
6659 2011-08-02 Robert Dewar <dewar@adacore.com>
6660
6661 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
6662 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
6663
6664 2011-08-02 Arnaud Charlet <charlet@adacore.com>
6665
6666 * gcc-interface/Make-lang.in: Update dependencies.
6667 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
6668 targets.
6669
6670 2011-08-02 Yannick Moy <moy@adacore.com>
6671
6672 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
6673 non-simple expression used in delta constraint
6674 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
6675 index constraint which is not a subtype mark
6676 * par.adb: With and use Restrict
6677 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
6678 mode on component type which is not a subtype mark and default
6679 expression on component
6680 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
6681 of string which does not have a lower index bound equal to 1
6682 (Array_Type_Declaration): issue an error in formal mode on index or
6683 component type which is not a subtype mark, and on aliased keyword on
6684 component
6685 (Derived_Type_Declaration): issue an error in formal mode on interface,
6686 limited or abstract type
6687 (Record_Type_Declaration): issue an error in formal mode on interface
6688 (Record_Type_Definition): issue an error in formal mode on tagged types
6689 and type extensions not declared in the specification of a library unit
6690 package; on null non-tagged record; on variant part
6691
6692 2011-08-02 Vincent Celier <celier@adacore.com>
6693
6694 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
6695 not declared for qualified library project when Library_Name is not
6696 declared, but Library_Dir is.
6697
6698 2011-08-02 Robert Dewar <dewar@adacore.com>
6699
6700 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
6701 pragmas (affects aspects [Component_]Default_Value
6702 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
6703 component type for the resolution
6704
6705 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
6706
6707 * einfo.adb (Base_Type): Tune implementation for speed.
6708
6709 2011-08-02 Robert Dewar <dewar@adacore.com>
6710
6711 * freeze.adb: Minor reformatting.
6712
6713 2011-08-02 Thomas Quinot <quinot@adacore.com>
6714
6715 * scos.ads: Update comments.
6716
6717 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6718
6719 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
6720 base type, because the parent may be a subtype of a private type whose
6721 convention is established in a private part.
6722
6723 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
6724
6725 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
6726 statement in a block when the expansion of the return expression has
6727 created a finalization chain.
6728 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
6729 with the parent node.
6730 Add N_Extended_Return_Statement to handle the case where a transient
6731 object declaration appears in the Return_Object_Declarations list of
6732 an extended return statement.
6733
6734 2011-08-02 Matthew Gingell <gingell@adacore.com>
6735
6736 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
6737 unused parameter 'name'.
6738
6739 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6740
6741 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
6742 inherited operation, check whether its alias, which is the source
6743 operastion that it renames, has been marked eliminated.
6744
6745 2011-08-02 Javier Miranda <miranda@adacore.com>
6746
6747 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
6748 in-mode parameter whose type is an access type since it can be used to
6749 modify its designated object. Enforce code that handles as safe an
6750 access type that is not access-to-constant but it is the result of a
6751 previous removal of side-effects.
6752 (Remove_Side_Effects): Minor code reorganization of cases which require
6753 no action. Done to incorporate documentation on new cases uncovered
6754 working in this ticket: no action needed if this routine was invoked
6755 too early and the nodes are not yet decorated.
6756 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
6757 to routine Remove_Side_Effects by calls to Force_Evaluation since they
6758 were issued with actuals that are implicitly provided by
6759 Force_Evaluation.
6760
6761 2011-08-02 Robert Dewar <dewar@adacore.com>
6762
6763 * sem_ch3.adb, sem_res.adb: Minor reformatting.
6764
6765 2011-08-02 Yannick Moy <moy@adacore.com>
6766
6767 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
6768 to issue an error in formal mode on attribute not supported in this mode
6769 (Analyze_Attribute): issue errors on standard attributes not supported
6770 in formal mode.
6771 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
6772 comment, and issue error in formal mode on modulus which is not a power
6773 of 2.
6774 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
6775 range.
6776 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
6777 subtype mark.
6778 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
6779 operator on modular type (except 'not').
6780
6781 2011-08-02 Robert Dewar <dewar@adacore.com>
6782
6783 * gnat_rm.texi: Minor reformatting.
6784
6785 2011-08-02 Arnaud Charlet <charlet@adacore.com>
6786
6787 * s-osinte-linux.ads: Minor comment update and reformatting.
6788 * i-cexten.ads: Make this unit pure, as for its parent.
6789 Will allow its usage in more contexts if needed.
6790
6791 2011-08-02 Robert Dewar <dewar@adacore.com>
6792
6793 * s-utf_32.ads: Minor comment fix.
6794
6795 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6796
6797 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
6798 operation of a tagged synchronized type, handle the case where the
6799 controlling argument is overloaded.
6800
6801 2011-08-02 Yannick Moy <moy@adacore.com>
6802
6803 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
6804 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
6805 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
6806 SPARK mode and formal verification mode on processing SPARK restriction
6807 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
6808 requiring consistency checking.
6809
6810 2011-08-02 Robert Dewar <dewar@adacore.com>
6811
6812 * sem_res.adb: Minor reformatting.
6813
6814 2011-08-02 Robert Dewar <dewar@adacore.com>
6815
6816 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
6817 a-cforse.ads: Remove unneeded with of Ada.Containers
6818 Remove commented out pragma Inline's
6819 Move specifications of new subprograms to the actual specs
6820
6821 2011-08-02 Yannick Moy <moy@adacore.com>
6822
6823 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
6824 a-cforse.ads: Update comments.
6825
6826 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6827
6828 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
6829
6830 2011-08-02 Robert Dewar <dewar@adacore.com>
6831
6832 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
6833 a-cforse.ads, a-cofove.ads: Minor reformatting.
6834
6835 2011-08-02 Claire Dross <dross@adacore.com>
6836
6837 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
6838 a-cofove.ads: Add comments.
6839
6840 2011-08-02 Yannick Moy <moy@adacore.com>
6841
6842 * gnat_rm.texi: Document formal containers.
6843
6844 2011-08-02 Emmanuel Briot <briot@adacore.com>
6845
6846 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
6847 are empty sections.
6848
6849 2011-08-02 Robert Dewar <dewar@adacore.com>
6850
6851 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
6852 reformatting.
6853
6854 2011-08-02 Robert Dewar <dewar@adacore.com>
6855
6856 * aspects.adb: New aspects Default_Value and Default_Component_Value
6857 New format of Aspect_Names table checks for omitted entries
6858 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
6859 handling of boolean aspects for derived types.
6860 New aspects Default_Value and Default_Component_Value
6861 New format of Aspect_Names table checks for omitted entries
6862 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
6863 (Has_Default_Value): New flag
6864 (Has_Default_Component_Value): New flag
6865 (Has_Default_Value): New flag
6866 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
6867 table.
6868 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
6869 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
6870 Default_Value and Default_Component_Value
6871 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
6872 New aspects Default_Value and Default_Component_Value
6873 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
6874 * sprint.adb: Print N_Aspect_Specification node when called from gdb
6875
6876 2011-08-02 Vincent Celier <celier@adacore.com>
6877
6878 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
6879 inherit library kind.
6880
6881 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6882
6883 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
6884 Minor reformatting.
6885
6886 2011-08-02 Robert Dewar <dewar@adacore.com>
6887
6888 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
6889
6890 2011-08-02 Yannick Moy <moy@adacore.com>
6891
6892 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
6893
6894 2011-08-02 Robert Dewar <dewar@adacore.com>
6895
6896 * impunit.adb: Add comment.
6897
6898 2011-08-02 Yannick Moy <moy@adacore.com>
6899
6900 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
6901 qualification of aggregates in formal mode
6902 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
6903 another aggregate
6904 (Resolve_Aggregate): complete the test that an aggregate is adequately
6905 qualified in formal mode
6906
6907 2011-08-02 Pascal Obry <obry@adacore.com>
6908
6909 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
6910 * mlib-prj.adb: Supress warning when compiling binder generated file.
6911 (Build_Library): Supress all warnings when compiling the binder
6912 generated file.
6913
6914 2011-08-02 Yannick Moy <moy@adacore.com>
6915
6916 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
6917 from here...
6918 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
6919 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
6920 Add with/use clauses to make Check_Formal_Restriction visible
6921
6922 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6923
6924 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
6925 in-parameters when type of the generic formal is private in the generic
6926 spec and non-private in the body.
6927
6928 2011-08-02 Claire Dross <dross@adacore.com>
6929
6930 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
6931 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
6932 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
6933 * impunit.adb, Makefile.rtl: Take new files into account.
6934
6935 2011-08-02 Robert Dewar <dewar@adacore.com>
6936
6937 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
6938 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
6939
6940 2011-08-02 Yannick Moy <moy@adacore.com>
6941
6942 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
6943 formal mode
6944 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
6945 matching static array bounds, taking into account the special case of
6946 string literals
6947 * sem_ch3.adb: Typo in comment.
6948
6949 2011-08-02 Yannick Moy <moy@adacore.com>
6950
6951 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
6952 which issues an error in formal mode if its argument node is originally
6953 from source
6954 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
6955 has a discriminant specification so that it does not include the case
6956 of derived types
6957 (Derived_Type_Declaration): move here the test that a derived type has a
6958 discriminant specification
6959 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
6960 first element of a component association before accessing its choices
6961 (presence of component association is not enough)
6962 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
6963 declaration is a library item before accessing the next element in a
6964 list, as library items are not member of lists
6965 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
6966 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
6967 Check_Formal_Restriction whenever possible.
6968
6969 2011-08-02 Ed Schonberg <schonberg@adacore.com>
6970
6971 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
6972 reference when needed.
6973
6974 2011-08-02 Bob Duff <duff@adacore.com>
6975
6976 * gnat_ugn.texi: Fix typo.
6977
6978 2011-08-02 Vincent Celier <celier@adacore.com>
6979
6980 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
6981 archive file name. Do not use the full path name of archives for Open
6982 VMS.
6983
6984 2011-08-02 Robert Dewar <dewar@adacore.com>
6985
6986 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
6987 Analyze_Aspect_Specifications
6988 * sem_ch13.adb
6989 (Analyze_Aspect_Specifications): New handling for boolean aspects
6990 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
6991 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
6992 sequence for Analyze_Aspect_Specifications
6993 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
6994 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
6995
6996 2011-08-02 Robert Dewar <dewar@adacore.com>
6997
6998 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
6999 aspects, since these no longer exist.
7000
7001 2011-08-02 Robert Dewar <dewar@adacore.com>
7002
7003 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
7004 semicolon, do not try to see if there are aspects following it.
7005 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
7006 aspect spec.
7007
7008 2011-08-02 Robert Dewar <dewar@adacore.com>
7009
7010 * sem_ch8.adb, aspects.ads: Minor reformatting.
7011
7012 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
7013
7014 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
7015 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
7016 extracted from...
7017 (Analyze_Aspect_Specifications): ...here. Call above procedure.
7018
7019 2011-08-02 Yannick Moy <moy@adacore.com>
7020
7021 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
7022 mode on subprogram declaration outside of package specification, unless
7023 it is followed by a pragma Import
7024 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
7025 Access_Type_Declaration): issue error in formal mode on access type
7026 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
7027 incomplete type
7028 (Analyze_Object_Declaration): issue error in formal mode on object
7029 declaration which does not respect SPARK restrictions
7030 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
7031 declaration which does not respect SPARK restrictions
7032 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
7033 error in formal mode on digits or delta constraint
7034 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
7035 decimal fixed point type
7036 (Derived_Type_Declaration): issue error in formal mode on derived type
7037 other than type extensions of tagged record types
7038 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
7039 with check on access definition
7040 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
7041 mode on protected definition.
7042 (Analyze_Task_Definition): issue error in formal mode on task definition
7043
7044 2011-08-02 Robert Dewar <dewar@adacore.com>
7045
7046 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
7047
7048 2011-08-02 Javier Miranda <miranda@adacore.com>
7049
7050 * sem_ch6.adb (Can_Override_Operator): New function.
7051 (Verify_Overriding_Indicator): Add missing code to check overriding
7052 indicator in operators. Fixes regression.
7053 (Check_Overriding_Indicator): Minor reformating after replacing the
7054 code that evaluates if the subprogram can override an operator by
7055 invocations to the above new function.
7056 * einfo.adb
7057 (Write_Field26_Name): Add missing code to ensure that, following
7058 the documentation in einfo.ads, this field is not shown as attribute
7059 "Static_Initialization" on non-dispatching functions.
7060
7061 2011-08-02 Jose Ruiz <ruiz@adacore.com>
7062
7063 * sem_res.adb (Resolve_Call): A call to
7064 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
7065 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
7066 i.e., when the second parameter is of type Time_Span.
7067
7068 2011-08-02 Vincent Celier <celier@adacore.com>
7069
7070 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
7071 with an archive instead of -L<library dir> -l<library name>.
7072
7073 2011-08-02 Ed Schonberg <schonberg@adacore.com>
7074
7075 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
7076 mark the base types In_Use in addition to making the operations
7077 use_visible.
7078
7079 2011-08-02 Ed Falis <falis@adacore.com>
7080
7081 * init.c: add and setup __gnat_signal_mask for the exception signals
7082 * s-inmaop-vxworks.adb: new file.
7083 * s-intman-vxworks.adb: remove unnecessary initializations and
7084 simplify remaining
7085 * s-intman-vxworks.ads: remove unnecessary variable
7086 * s-taprop-vxworks.adb: simplify signal initialization
7087
7088 2011-08-02 Robert Dewar <dewar@adacore.com>
7089
7090 * sem_ch8.adb: Minor code reorganization, comment updates.
7091
7092 2011-08-02 Robert Dewar <dewar@adacore.com>
7093
7094 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
7095 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
7096 here from Sem_Res.
7097 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
7098 (Matching_Static_Array_Bounds): Moved here from Sem_Res
7099
7100 2011-08-02 Ed Schonberg <schonberg@adacore.com>
7101
7102 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
7103 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
7104 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
7105 use_type_clauses, to handle more efficiently use_type and use_all_type
7106 constructs.
7107 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
7108 Ada2012 Use_All_Type clause.
7109 (Use_Class_Wide_Operations): new procedure.
7110
7111 2011-08-02 Robert Dewar <dewar@adacore.com>
7112
7113 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
7114 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
7115 expression to expression function.
7116
7117 2011-08-02 Ed Schonberg <schonberg@adacore.com>
7118
7119 * sem_ch4.adb: transform simple Ada2012 membership into equality only
7120 if types are compatible.
7121
7122 2011-08-02 Yannick Moy <moy@adacore.com>
7123
7124 * sem_res.adb (Matching_Static_Array_Bounds): new function which
7125 returns True if its argument array types have same dimension and same
7126 static bounds at each index.
7127 (Resolve_Actuals): issue an error in formal mode on actuals passed as
7128 OUT or IN OUT paramaters which are not view conversions in SPARK.
7129 (Resolve_Arithmetic_Op): issue an error in formal mode on
7130 multiplication or division with operands of fixed point types which are
7131 not qualified or explicitly converted.
7132 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
7133 Boolean or array type (except String) operands.
7134 (Resolve_Equality_Op): issue an error in formal mode on equality
7135 operators for array types other than String with non-matching static
7136 bounds.
7137 (Resolve_Logical_Op): issue an error in formal mode on logical operators
7138 for array types with non-matching static bounds. Factorize the code in
7139 Matching_Static_Array_Bounds.
7140 (Resolve_Qualified_Expression): issue an error in formal mode on
7141 qualified expressions for array types with non-matching static bounds.
7142 (Resolve_Type_Conversion): issue an error in formal mode on type
7143 conversion for array types with non-matching static bounds
7144
7145 2011-08-02 Robert Dewar <dewar@adacore.com>
7146
7147 * par-ch10.adb: Minor code reorganization (use Nkind_In).
7148
7149 2011-08-02 Ed Schonberg <schonberg@adacore.com>
7150
7151 * par-ch9.adb: save location of entry for proper error message.
7152
7153 2011-08-02 Javier Miranda <miranda@adacore.com>
7154
7155 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
7156 (Use_Full_View) which permits this routine to climb through the
7157 ancestors using the full-view of private parents.
7158 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
7159 Use_Full_View to true in calls to Is_Ancestor.
7160 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
7161 true in call to Is_Ancestor.
7162 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
7163 Use_Full_View to true in call to Is_Ancestor.
7164 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
7165 call to Is_Ancestor.
7166 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
7167 Use_Full_View to true in calls to Is_Ancestor.
7168 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
7169 Make_Select_Specific_Data_Table, Register_Primitive,
7170 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
7171 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
7172 to true in call to Is_Ancestor.
7173 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
7174 Use_Full_View to true in calls to Is_Ancestor.
7175 * exp_cg.adb
7176 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
7177 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
7178
7179 2011-08-02 Robert Dewar <dewar@adacore.com>
7180
7181 * gnat_rm.texi: Minor reformatting.
7182 * sem_prag.adb: Minor reformatting.
7183
7184 2011-08-02 Tristan Gingold <gingold@adacore.com>
7185
7186 * vms_data.ads: Add VMS qualifier for -gnateP.
7187
7188 2011-08-02 Robert Dewar <dewar@adacore.com>
7189
7190 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
7191 * par-ch7.adb (P_Package): Proper placement of aspects for package
7192 decl/instantiation.
7193 * par-endh.adb (Check_End): Ad Is_Sloc parameter
7194 (End_Statements): Add Is_Sloc parameterr
7195 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
7196 (Check_End): Ad Is_Sloc parameter
7197 (End_Statements): Add Is_Sloc parameterr
7198
7199 2011-08-02 Vincent Celier <celier@adacore.com>
7200
7201 * ug_words: Add VMS qualifier equivalent to -gnateP:
7202 /SYMBOL_PREPROCESSING.
7203
7204 2011-08-02 Jose Ruiz <ruiz@adacore.com>
7205
7206 * gnat-style.texi: For hexadecimal numeric literals the typical
7207 grouping of digits is 4 to represent 2 bytes.
7208 A procedure spec which is split into several lines is indented two
7209 characters.
7210
7211 2011-08-02 Yannick Moy <moy@adacore.com>
7212
7213 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
7214 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
7215 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
7216 properly qualified
7217 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
7218 choice in array aggregate
7219 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
7220 mark as ancestor
7221 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
7222 positional and named aggregate for record, or others in record
7223 aggregate, or multiple choice in record aggregate
7224 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
7225 array operands to logical operations AND, OR and XOR do not have the
7226 same static lower and higher bounds
7227 * sem_ch5.adb, sinfo.ads: Correct typos in comments
7228
7229 2011-08-01 Robert Dewar <dewar@adacore.com>
7230
7231 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
7232 Replaces Last_Source_Node_In_Sequence.
7233 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
7234 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
7235 parens and blank in string (this was inconsistently implemented).
7236 * errout.ads
7237 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
7238 blank in string (this was inconsistently implemented).
7239 * gnat1drv.adb
7240 (Set_Global_Switches): Set formal mode switches appropriately
7241 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
7242 * par-prag.adb
7243 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
7244 call Set_Error_Msg_Lang to set "spark" as language name.
7245 * par.adb: Remove unnecessary call to set formal language for errout
7246 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
7247 appropriately and call Set_Error_Msg_Lang to set "spark" as language
7248 name.
7249 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
7250 calls to it, moved after resolution so that types are known
7251 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
7252 result of concatenation is not of type String
7253 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
7254 concatenation is not properly restricted
7255 * gnat_rm.texi: Add doc on pragma Spark_95.
7256 * gcc-interface/Makefile.in: Remove obsolete target pairs for
7257 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
7258 * gcc-interface/Make-lang.in: Update dependencies.
7259
7260 2011-08-01 Javier Miranda <miranda@adacore.com>
7261
7262 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
7263 condition that detects if the overridden operation must replace an
7264 existing entity.
7265
7266 2011-08-01 Javier Miranda <miranda@adacore.com>
7267
7268 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
7269 code declarations inserted by Insert_Actions in each alternative of the
7270 N_Case_Expression node.
7271
7272 2011-08-01 Robert Dewar <dewar@adacore.com>
7273
7274 * sem_ch6.adb: Minor code reorganization.
7275 * sem_util.adb: Minor reformatting.
7276
7277 2011-08-01 Pascal Obry <obry@adacore.com>
7278
7279 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
7280 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
7281
7282 2011-08-01 Yannick Moy <moy@adacore.com>
7283
7284 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
7285 literal or operator symbol which is prefixed
7286 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
7287 mode on access attributes.
7288 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
7289 that concatenation operands are properly restricted in formal mode
7290 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
7291 Analyze_Concatenation_Operand. Issue an error in formal mode if the
7292 result of the concatenation has a type different from String.
7293 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
7294 Analyze_Quantified_Expression, Analyze_Slice,
7295 Analyze_Null): issue an error in formal mode on unsupported constructs
7296 * sem_ch5.adb
7297 (Analyze_Block_Statement): only issue error on source block statement
7298 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
7299 function which returns the last node in a list of nodes for which
7300 Comes_From_Source returns True, if any
7301 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
7302 Last_Source_Node_In_Sequence
7303 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
7304 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
7305 mode on unsupported constructs
7306 * sem_ch9.adb Do not return after issuing error in formal mode, as the
7307 rest of the actions may be needed later on since the error is marked as
7308 not serious.
7309 * sinfo.ads: Typos in comments.
7310
7311 2011-08-01 Pascal Obry <obry@adacore.com>
7312
7313 * projects.texi: Minor editing.
7314
7315 2011-08-01 Yannick Moy <moy@adacore.com>
7316
7317 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
7318 insertion character ~~
7319 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
7320 (Set_Error_Msg_Lang): new procedure which fixes the language for use
7321 with insertion character ~~
7322 (Set_Msg_Text): treat insertion character ~~
7323 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
7324 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
7325 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
7326 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
7327 errors related to the formal language restriction not serious
7328 (insertion character |).
7329 * par.adb (Par): set formal language for error messages if needed
7330 * sem_ch6.adb (Check_Missing_Return): take into account possible
7331 generated statements at the end of the function
7332 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
7333 enumeration value to define a new pragma SPARK_95
7334 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
7335 SPARK_Version): new type and variables to store the SPARK version
7336 (none by default).
7337 (SPARK_Mode): return True when SPARK_Version is set
7338 * par-prag.adb: Correct indentation
7339 (Prag): take Pragma_SPARK_95 into account
7340 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
7341 into account.
7342
7343 2011-08-01 Robert Dewar <dewar@adacore.com>
7344
7345 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
7346 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
7347 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
7348
7349 2011-08-01 Pascal Obry <obry@adacore.com>
7350
7351 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
7352 Target_Name to Get_Path call.
7353 (Parse_Single_Project): Likewise.
7354 (Post_Parse_Context_Clause): Likewise.
7355 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
7356 Call Initialise_Project_Path with the proper Target_Name.
7357 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
7358 search path.
7359 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
7360 with the proper Target_Name.
7361 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
7362 Part.Parse routine.
7363 (Parse_Project_And_Apply_Config): Likewise.
7364 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
7365 This is fine as this part of the code is supporting only native
7366 compilation.
7367 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
7368 is fine as this part of the code is supporting only native compilation.
7369
7370 2011-08-01 Yannick Moy <moy@adacore.com>
7371
7372 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
7373 of homonym, unless the homonym is one of the cases allowed in SPARK
7374 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
7375 package declaration occurring after a body.
7376
7377 2011-08-01 Robert Dewar <dewar@adacore.com>
7378
7379 * checks.adb, exp_ch4.adb: Minor reformatting.
7380
7381 2011-08-01 Javier Miranda <miranda@adacore.com>
7382
7383 * einfo.ads (Access_Disp_Table): Fix documentation.
7384 (Dispatch_Table_Wrappers): Fix documentation.
7385
7386 2011-08-01 Pascal Obry <obry@adacore.com>
7387
7388 * prj-env.adb, prj-env.ads: Minor reformatting.
7389
7390 2011-08-01 Yannick Moy <moy@adacore.com>
7391
7392 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
7393 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
7394 procedures out of these packages.
7395 * errout.ads, errout.adb
7396 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
7397 procedures in of this package
7398 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
7399 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
7400 on misplaced later vs initial declarations, like in Ada 83
7401 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
7402 formal mode on attribute of private type whose full type declaration
7403 is not visible
7404 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
7405 package declaration inside a package specification
7406 (Analyze_Full_Type_Declaration): issue error in formal mode on
7407 controlled type or discriminant type
7408 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
7409 user-defined operator means that it should come from the source
7410 (New_Overloaded_Entity): issue error in formal mode on overloaded
7411 entity.
7412 * sem_ch6.ads, sem_ch13.ads: typos in comments.
7413
7414 2011-08-01 Thomas Quinot <quinot@adacore.com>
7415
7416 * atree.adb: Minor reformatting.
7417 * checks.adb: Minor reformatting.
7418
7419 2011-08-01 Vincent Celier <celier@adacore.com>
7420
7421 * s-parame-vms-ia64.ads: Fix typo in comment
7422 Minor reformatting
7423 * s-parame-vms-restrict.ads: Removed, unused.
7424
7425 2011-08-01 Javier Miranda <miranda@adacore.com>
7426
7427 * exp_ch3.adb
7428 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
7429 * sem_ch3.adb
7430 (Constrain_Index): Remove side effects in the evaluation of the bounds.
7431 * sem_ch3.ads, sem_ch3.adb
7432 (Is_Constant_Bound): New extended version of the subprogram that was
7433 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
7434 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
7435 * sem_aux.ads (Constant_Value): Fix typo in comment.
7436 * checks.adb (Generate_Index_Checks): New implementation which, for
7437 array objects with constant bounds, generates the runtime check
7438 referencing the bounds of the array type. For other cases this routine
7439 provides its previous behavior obtaining such values from the array
7440 object.
7441 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
7442 parent type.
7443 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
7444 we cannot have semantic interpretations of the new node.
7445
7446 2011-08-01 Ed Schonberg <schonberg@adacore.com>
7447
7448 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
7449 expressions.
7450
7451 2011-08-01 Arnaud Charlet <charlet@adacore.com>
7452
7453 * sem_ch8.adb: Minor code editing.
7454 * s-vxwext.adb: Remove trailing space.
7455 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
7456 consistency with other files.
7457
7458 2011-08-01 Thomas Quinot <quinot@adacore.com>
7459
7460 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
7461
7462 2011-08-01 Ed Schonberg <schonberg@adacore.com>
7463
7464 * par-ch10.adb: reject parameterized expressions as compilation unit.
7465 * sem_ch4.adb: handle properly conditional expression with overloaded
7466 then_clause and no else_clause.
7467
7468 2011-08-01 Tristan Gingold <gingold@adacore.com>
7469
7470 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
7471 like done by System.Aux_DEC.
7472 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
7473
7474 2011-08-01 Yannick Moy <moy@adacore.com>
7475
7476 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
7477 missing label at end of declaration (subprogram or package)
7478 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
7479 of positional and named parameter association
7480 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
7481 Error_Msg_SP which adds a prefix to the error message giving the name
7482 of the formal language analyzed
7483 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
7484 access result type in subprogram, unconstrained array as result type,.
7485 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
7486 procedure
7487 * sem_ch8.adb: Code clean up.
7488
7489 2011-08-01 Javier Miranda <miranda@adacore.com>
7490
7491 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
7492 * einfo.ads (Access_Disp_Table): Fix documentation.
7493 (Dispatch_Table_Wrappers): Fix documentation.
7494 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
7495 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
7496 to enforce the documentation of this attribute.
7497 (Set_Is_Interface): Cleanup the assertion.
7498 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
7499 the Underlying_Type entity before reading attribute Access_Disp_Table.
7500 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
7501 Locate the Underlying_Type before reading attribute Access_Disp_Table.
7502 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
7503 the Underlying_Type entity before reading attribute Access_Disp_Table.
7504 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
7505 Locate the Underlying_Type entity before reading attribute
7506 Access_Disp_Table.
7507
7508 2011-08-01 Ed Schonberg <schonberg@adacore.com>
7509
7510 * s-poosiz.ads: Additional overriding indicators.
7511
7512 2011-08-01 Yannick Moy <moy@adacore.com>
7513
7514 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
7515 formal mode.
7516 (Analyze_Iteration_Scheme): issue error in formal mode when loop
7517 parameter specification does not include a subtype mark.
7518 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
7519 formal mode on abstract subprogram.
7520 (Analyze_Subprogram_Specification): issue error in formal mode on
7521 user-defined operator.
7522 (Process_Formals): issue error in formal mode on access parameter and
7523 default expression.
7524 * sem_ch9.adb (Analyze_Abort_Statement,
7525 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
7526 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
7527 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
7528 Analyze_Requeue, Analyze_Selective_Accept,
7529 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
7530 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
7531 issue error in formal mode on user-defined raise statement.
7532
7533 2011-08-01 Thomas Quinot <quinot@adacore.com>
7534
7535 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
7536 declaration being hidden when overriding an implicit inherited
7537 subprogram.
7538 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
7539 (-gnats), do not complain about a source file that contains only a
7540 pragma No_Body.
7541
7542 2011-08-01 Ed Schonberg <schonberg@adacore.com>
7543
7544 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
7545 variable if already set.
7546
7547 2011-08-01 Arnaud Charlet <charlet@adacore.com>
7548
7549 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
7550 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
7551 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
7552 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
7553 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
7554 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
7555 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
7556 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
7557 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
7558 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
7559 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
7560 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
7561 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
7562 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
7563 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
7564 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
7565 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
7566 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
7567 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
7568 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
7569 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
7570 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
7571 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
7572 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
7573 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
7574 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
7575 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
7576 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
7577 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
7578 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
7579 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
7580 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
7581 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
7582 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
7583 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
7584 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
7585 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
7586 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
7587 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
7588 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
7589 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
7590 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
7591 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
7592 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
7593 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
7594 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
7595 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
7596 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
7597 s-osinte-mingw.ads: Update to GPLv3 run-time license.
7598 Use GNAT instead of GNARL.
7599
7600 2011-08-01 Bob Duff <duff@adacore.com>
7601
7602 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
7603 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
7604 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
7605 reformatting.
7606
7607 2011-08-01 Yannick Moy <moy@adacore.com>
7608
7609 * debug.adb (d.D) reverve flag for the SPARK mode
7610 (d.E) reverve flag for SPARK generation mode
7611 (d.F) reverve flag for Why generation mode
7612 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
7613 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
7614 functions which return True when the corresponding modes are set
7615 (Formal_Language): return "spark" or "alfa" when in formal verification
7616 mode.
7617 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
7618 Error_Msg to prefix the error message with a tag giving the formal
7619 language
7620 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
7621 message with a tag giving the formal language
7622 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
7623 block statement
7624 (Analyze_Case_Statement): issue error in formal mode on case statement
7625 with a single "others" case alternative
7626 (Analyze_Exit_Statement): issue errors in formal mode on exit
7627 statements which do not respect SPARK restrictions
7628 (Analyze_Goto_Statement): issue error in formal mode on goto statement
7629 (Check_Unreachable_Code): always issue an error (not a warning) in
7630 formal mode on unreachable code (concerns both code after an infinite
7631 loop and after an unconditional jump, both not allowed in SPARK)
7632 * sem_ch6.adb (Analyze_Return_Statement): add call to
7633 Set_Return_Present for a procedure containing a return statement
7634 (already done for functions in Analyze_Function_Return)
7635 (Analyze_Function_Return): issue error in formal mode on extended
7636 return or if return is not last statement in function
7637 (Check_Missing_Return): issue error in formal mode if function does
7638 not end with return or if procedure contains a return
7639 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
7640 function to detect if there is an inner scope of its parameter S which
7641 is a loop.
7642
7643 2011-08-01 Thomas Quinot <quinot@adacore.com>
7644
7645 * sem_ch6.ads: Minor reformatting.
7646
7647 2011-08-01 Javier Miranda <miranda@adacore.com>
7648
7649 * sem_util.adb (Abstract_Interface_List): Complete condition when
7650 processing private type declarations to avoid reading unavailable
7651 attribute.
7652 (Is_Synchronized_Tagged_Type): Complete condition when processing
7653 private extension declaration nodes to avoid reading unavailable
7654 attribute.
7655
7656 2011-08-01 Thomas Quinot <quinot@adacore.com>
7657
7658 * sem_ch3.adb: Minor reformatting.
7659
7660 2011-08-01 Thomas Quinot <quinot@adacore.com>
7661
7662 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
7663 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
7664 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
7665 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
7666 for VMS, instead parametrize the common implementation with
7667 System.Parameters declarations.
7668
7669 2011-08-01 Eric Botcazou <ebotcazou@adacore.com>
7670
7671 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
7672
7673 2011-08-01 Tristan Gingold <gingold@adacore.com>
7674
7675 * seh_init.c: Fix SEH handler installation on win64.
7676
7677 2011-08-01 Ed Schonberg <schonberg@adacore.com>
7678
7679 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
7680 double analysis of an anonymous access to subprogram, because it can
7681 lead to improper sharing of profiles and a back-end crash.
7682
7683 2011-08-01 Robert Dewar <dewar@adacore.com>
7684
7685 * make.adb, sem_ch4.adb: Minor reformatting.
7686 * gcc-interface/Make-lang.in: Update dependencies.
7687 * sem_util.adb, exp_ch5.adb: Minor reformatting.
7688
7689 2011-08-01 Arnaud Charlet <charlet@adacore.com>
7690
7691 * gnat_rm.texi: Fix definition of Long_Integer.
7692
7693 2011-08-01 Ed Schonberg <schonberg@adacore.com>
7694
7695 * exp_aggr.adb: check limit size of static aggregate unconditionally,
7696 to prevent storage exhaustion.
7697 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
7698 finalized is a function body, insert the cleanup code before the final
7699 return statement, to prevent spurious warnings.
7700 * s-pooglo.ads: add overriding indicator.
7701
7702 2011-08-01 Ed Schonberg <schonberg@adacore.com>
7703
7704 * sem_ch4.adb (Operator_Check): improve error message when both a
7705 with_clause and a use_clause are needed to make operator usage legal.
7706 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
7707 determine whether a compilation unit is visible within an other,
7708 either through a with_clause in the current unit, or a with_clause in
7709 its library unit or one one of its parents.
7710
7711 2011-08-01 Ed Schonberg <schonberg@adacore.com>
7712
7713 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
7714 over an arbitrary expression of an array or container type.
7715 * lib-xref.adb: clarify comment.
7716
7717 2011-08-01 Bob Duff <duff@adacore.com>
7718
7719 * einfo.ads: Minor reformatting.
7720 * debug.adb: Minor comment improvement.
7721
7722 2011-08-01 Javier Miranda <miranda@adacore.com>
7723
7724 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
7725 consider hidden subprograms as valid candidates.
7726
7727 2011-08-01 Arnaud Charlet <charlet@adacore.com>
7728
7729 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
7730
7731 2011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
7732
7733 * gnat_ugn.texi: Fix typo.
7734
7735 2011-08-01 Robert Dewar <dewar@adacore.com>
7736
7737 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
7738 lib-xref.adb: Minor reformatting
7739
7740 2011-08-01 Gary Dismukes <dismukes@adacore.com>
7741
7742 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
7743 when to generate a call to Move_Final_List.
7744 (Has_Controlled_Parts): Remove this function.
7745
7746 2011-08-01 Geert Bosch <bosch@adacore.com>
7747
7748 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
7749 "," in choice list.
7750
7751 2011-08-01 Thomas Quinot <quinot@adacore.com>
7752
7753 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
7754 explicit raise of a predefined exception as Comes_From_Source if the
7755 original N_Raise_Statement comes from source.
7756
7757 2011-08-01 Robert Dewar <dewar@adacore.com>
7758
7759 * sinfo.ads: Add comment.
7760 * sem_ch6.adb: Minor reformatting.
7761
7762 2011-08-01 Robert Dewar <dewar@adacore.com>
7763
7764 * freeze.adb (Freeze_Entity): Refine check for bad component size
7765 clause to avoid rejecting confirming clause when atomic/aliased present.
7766
7767 2011-08-01 Ed Schonberg <schonberg@adacore.com>
7768
7769 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
7770 better determine whether an entity reference is a write.
7771 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
7772 subcomponent.
7773 * lib-xref.adb (Output_References): Do no suppress a read reference at
7774 the same location as an immediately preceeding modify-reference, to
7775 handle properly in-out actuals.
7776
7777 2011-08-01 Tristan Gingold <gingold@adacore.com>
7778
7779 * env.c (__gnat_setenv) [VMS]: Refine previous change.
7780
7781 2011-08-01 Quentin Ochem <ochem@adacore.com>
7782
7783 * i-cstrin.adb (New_String): Changed implementation, now uses only the
7784 heap to compute the result.
7785
7786 2011-08-01 Robert Dewar <dewar@adacore.com>
7787
7788 * atree.ads: Minor reformatting.
7789
7790 2011-08-01 Emmanuel Briot <briot@adacore.com>
7791
7792 * g-expect.adb (Get_Command_Output): Fix memory leak.
7793
7794 2011-08-01 Geert Bosch <bosch@adacore.com>
7795
7796 * cstand.adb (P_Float_Type): New procedure to print the definition of
7797 predefined fpt types.
7798 (P_Mixed_Name): New procedure to print a name using mixed case
7799 (Print_Standard): Use P_Float_Type for printing floating point types
7800 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
7801 precision IEEE float.
7802
7803 2011-08-01 Thomas Quinot <quinot@adacore.com>
7804
7805 * sem_ch3.adb: Minor reformatting.
7806
7807 2011-08-01 Ed Schonberg <schonberg@adacore.com>
7808
7809 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
7810 the completion of a generic function, insert the new body rather than
7811 rewriting the original.
7812
7813 2011-08-01 Yannick Moy <moy@adacore.com>
7814
7815 * sinfo.ads, errout.ads: Typos in comments.
7816
7817 2011-08-01 Robert Dewar <dewar@adacore.com>
7818
7819 * par-endh.adb: Minor reformatting.
7820
7821 2011-08-01 Robert Dewar <dewar@adacore.com>
7822
7823 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
7824 (Pre_Post_Aspects): New subtype.
7825 * par-ch12.adb (P_Generic): New syntax for aspects in packages
7826 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
7827 * par-ch7.adb (P_Package): Remove Decl parameter
7828 (P_Package): Handle new syntax for aspects (before IS)
7829 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
7830 new aspect syntax
7831 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
7832 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
7833 (P_Package): Remove Decl parameter
7834 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
7835 aspects
7836 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
7837 specs
7838 * sem_util.ads, sem_util.adb (Static_Boolean): New function
7839 * sinfo.ads: Document new syntax for aspects in packages etc.
7840 * sprint.adb: Handle new syntax of aspects before IS in package
7841
7842 2011-08-01 Thomas Quinot <quinot@adacore.com>
7843
7844 * atree.ads: Minor reformatting.
7845 * sem_prag.adb: Minor reformatting.
7846
7847 2011-08-01 Robert Dewar <dewar@adacore.com>
7848
7849 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
7850 case expr alternative.
7851
7852 2011-08-01 Ed Schonberg <schonberg@adacore.com>
7853
7854 * sem_ch12.adb: Fix typo.
7855
7856 2011-08-01 Geert Bosch <bosch@adacore.com>
7857
7858 * sem_prag.adb (Check_No_Link_Name): New procedure.
7859 (Process_Import_Or_Interface): Use Check_No_Link_Name.
7860 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
7861 instead of Standard_Long_Long_Float_Size global. Preparation for
7862 eventual removal of per type constants.
7863 * exp_util.ads (Get_Stream_Size): New function returning the stream
7864 size value of subtype E.
7865 * exp_util.adb (Get_Stream_Size): Implement new function.
7866 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
7867 function.
7868 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
7869 * einfo.adb:
7870 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
7871
7872 2011-08-01 Geert Bosch <bosch@adacore.com>
7873
7874 * cstand.adb: Fix comments.
7875 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
7876 count of arguments.
7877
7878 2011-08-01 Robert Dewar <dewar@adacore.com>
7879
7880 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
7881
7882 2011-08-01 Geert Bosch <bosch@adacore.com>
7883
7884 * atree.ads: Fix comment.
7885
7886 2011-08-01 Robert Dewar <dewar@adacore.com>
7887
7888 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
7889 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
7890 * par.adb: Add with for Namet.Sp.
7891 * par-tchk.adb: Minor reformatting.
7892
7893 2011-08-01 Vincent Celier <celier@adacore.com>
7894
7895 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
7896 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
7897 of the init procedure of a SAL.
7898 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
7899 New procedure.
7900
7901 2011-08-01 Thomas Quinot <quinot@adacore.com>
7902
7903 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
7904 reformatting.
7905
7906 2011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
7907
7908 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
7909
7910 2011-08-01 Thomas Quinot <quinot@adacore.com>
7911
7912 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
7913 conformant with its spec (return True only for types that have
7914 an overriding Initialize primitive operation that prevents them from
7915 having preelaborable initialization).
7916 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
7917 initialization for controlled types in Ada 2005 or later mode.
7918
7919 2011-08-01 Robert Dewar <dewar@adacore.com>
7920
7921 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
7922 Postcondition.
7923 (Same_Aspect): New function.
7924 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
7925 Type_Invariant, Precondition, Postcondition.
7926 * snames.ads-tmpl: Add Name_Type_Invariant.
7927
7928 2011-08-01 Robert Dewar <dewar@adacore.com>
7929
7930 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
7931 here.
7932 (Freeze_All_Ent): Fix error in handling inherited aspects.
7933 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
7934 already analyzed, but don't skip entire processing of a declaration,
7935 that's wrong in some cases of declarations being rewritten.
7936 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
7937 Don't delay for integer, string literals
7938 Treat predicates in usual manner for delay, remove special case code,
7939 not needed.
7940 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
7941 (Build_Predicate_Function): Update saved expression in aspect
7942 (Build_Invariant_Procedure): Update saved expression in aspect
7943 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
7944 of replacement of discriminant references if the reference is simple.
7945
7946 2011-08-01 Robert Dewar <dewar@adacore.com>
7947
7948 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
7949 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
7950 Static_Predicate and Dynamic_Predicate.
7951 (Build_Predicate_Function): Add processing for Static_Predicate
7952 and Dynamic_Predicate.
7953 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
7954 (From_Static_Predicate): New flag
7955 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
7956
7957 2011-08-01 Robert Dewar <dewar@adacore.com>
7958
7959 * usage.adb: Documentation cleanup for Ada version modes in usage.
7960 * expander.adb: Minor reformatting.
7961
7962 2011-08-01 Robert Dewar <dewar@adacore.com>
7963
7964 * atree.ads: Minor comment fix.
7965 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
7966 a-witeio.ads, sem_prag.adb: Minor reformatting.
7967
7968 2011-08-01 Doug Rupp <rupp@adacore.com>
7969
7970 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
7971 pointers. Use descrip.h header file for convenience. Add some
7972 comments.
7973
7974 2011-08-01 Robert Dewar <dewar@adacore.com>
7975
7976 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
7977 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
7978 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
7979 New procedure.
7980 (Check_Aspect_At_End_Of_Declarations): New procedure
7981 (Analye_Aspect_Specification): Minor changes for above procedures
7982 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
7983 specification node as well.
7984
7985 2011-08-01 Pascal Obry <obry@adacore.com>
7986
7987 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
7988 Windows files. Use GetFilesAttributes() in this case to check for file
7989 existence instead of returning with an error code.
7990
7991 2011-08-01 Vincent Celier <celier@adacore.com>
7992
7993 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
7994 High is above Source length.
7995
7996 2011-08-01 Robert Dewar <dewar@adacore.com>
7997
7998 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
7999
8000 2011-08-01 Robert Dewar <dewar@adacore.com>
8001
8002 * aspects.ads (Boolean_Aspects): New subtype.
8003 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
8004 for derived types in cases where the parent type and derived type have
8005 aspects.
8006 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
8007 with aspects when parent type also has aspects.
8008 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
8009 boolean expression at this point).
8010 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
8011 accordance with final decision on the Ada 2012 feature.
8012 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
8013
8014 2011-08-01 Matthew Heaney <heaney@adacore.com>
8015
8016 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
8017
8018 2011-08-01 Pascal Obry <obry@adacore.com>
8019
8020 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
8021 Fix Replace_Slice when High is above current string size.
8022 (Replace_Slice): Fix DL computation when High is above current
8023 string length.
8024
8025 2011-08-01 Gary Dismukes <dismukes@adacore.com>
8026
8027 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
8028
8029 2011-08-01 Matthew Heaney <heaney@adacore.com>
8030
8031 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
8032 of node.
8033
8034 2011-08-01 Pascal Obry <obry@adacore.com>
8035
8036 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
8037 reformatting.
8038
8039 2011-08-01 Ed Schonberg <schonberg@adacore.com>
8040
8041 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
8042 access to protected subprograms in generic bodies.
8043 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
8044 protected type, indicate that the convention of the subprogram is
8045 Convention_Protected, because it may be used in subsequent declarations
8046 within the protected declaration.
8047
8048 2011-08-01 Vincent Celier <celier@adacore.com>
8049
8050 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
8051 and "final" procedures when the name of the library is "ada", to avoid
8052 duplicate symbols "adainit" and "adafinal" in executables.
8053
8054 2011-08-01 Ed Schonberg <schonberg@adacore.com>
8055
8056 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
8057 quantified expression that appears within a postcondition and uses the
8058 Ada2012 'Result attribute.
8059
8060 2011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8061
8062 * init.c (__gnat_error_handler): Cast reason to int.
8063 (__gnat_install_handler): Explain sa_sigaction use.
8064
8065 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
8066
8067 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
8068 subprogram has copy-in copy-out parameters, try to promote the mode of
8069 the return type if it is passed in registers.
8070
8071 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
8072
8073 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
8074 left operand as addressable.
8075
8076 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
8077
8078 * gcc-interface/gigi.h (build_function_stub): Remove.
8079 (build_return_expr): Likewise.
8080 (convert_vms_descriptor): Declare.
8081 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
8082 (build_function_stub): Move to...
8083 * gcc-interface/utils2.c (build_return_expr): Move to...
8084 * gcc-interface/trans.c (build_function_stub): ...here.
8085 (build_return_expr): ...here.
8086 (Subprogram_Body_to_gnu): Add local variable for language_function.
8087 Disconnect the parameter attributes cache, if any, once done with it.
8088 Call end_subprog_body only after setting the end_locus.
8089 Build the stub associated with the function, if any, at the very end.
8090 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
8091 variables and streamline control flow.
8092
8093 2011-07-23 Arnaud Charlet <charlet@adacore.com>
8094
8095 PR ada/49819
8096 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
8097 g-trasym-dwarf.adb.
8098
8099 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8100
8101 PR bootstrap/49794
8102 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
8103 Assign to act.sa_sigaction.
8104 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
8105 current->return_address to char * before arithmetic.
8106
8107 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8108
8109 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
8110 Correct argument types.
8111 Extract code from reason.
8112 (__gnat_install_handler): Assign to act.sa_sigaction.
8113
8114 2011-07-21 Eric Botcazou <ebotcazou@adacore.com>
8115
8116 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
8117 (GNAT1_OBJS): ...here.
8118
8119 2011-07-15 Eric Botcazou <ebotcazou@adacore.com>
8120
8121 PR ada/48711
8122 * g-socthi-mingw.adb (Fill): Fix formatting.
8123
8124 * gcc-interface/gigi.h: Move around comment.
8125
8126 2011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
8127
8128 PR ada/46350
8129 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
8130
8131 2011-07-14 Florian Weimer <fw@deneb.enyo.de>
8132
8133 PR ada/48711
8134 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
8135
8136 2011-07-13 Eric Botcazou <ebotcazou@adacore.com>
8137
8138 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
8139 range comparison if Pmode is SImode.
8140
8141 2011-07-12 Laurent GUERBY <laurent@guerby.net>
8142 Eric Botcazou <ebotcazou@adacore.com>
8143
8144 * adadecode.c: Wrap up in extern "C" block.
8145 * adadecode.h: Likewise.
8146 * adaint.c: Likewise. Remove 'const' keyword.
8147 * adaint.h: Likewise.
8148 * argv.c: Likewise.
8149 * atree.h: Likewise.
8150 * cio.c: Likewise.
8151 * cstreams.c: Likewise.
8152 * env.c: Likewise.
8153 * exit.c: Likewise.
8154 * fe.h: Likewise.
8155 * final.c: Likewise.
8156 * init.c: Likewise.
8157 * initialize.c: Likewise.
8158 * link.c: Likewise.
8159 * namet.h: Likewise.
8160 * nlists.h: Likewise.
8161 * raise.c: Likewise.
8162 * raise.h: Likewise.
8163 * repinfo.h: Likewise.
8164 * seh_init.c: Likewise.
8165 * targext.c: Likewise.
8166 * tracebak.c: Likewise.
8167 * uintp.h: Likewise.
8168 * urealp.h: Likewise.
8169 * xeinfo.adb: Wrap up generated C code in extern "C" block.
8170 * xsinfo.adb: Likewise.
8171 * xsnamest.adb: Likewise.
8172 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
8173 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
8174 * gcc-interface/misc.c: Likewise.
8175 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
8176 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
8177 ada/targext.o here...
8178 (GNAT_ADA_OBJS): ...and not here.
8179 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
8180 (GNATBIND_OBJS): Reorder.
8181
8182 2011-07-07 Richard Henderson <rth@redhat.com>
8183
8184 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
8185 dwarf2out_frame_init.
8186
8187 2011-07-07 Eric Botcazou <ebotcazou@adacore.com>
8188
8189 * gcc-interface/misc.c (gnat_init): Tweak previous change.
8190
8191 2011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8192
8193 PR target/39150
8194 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
8195
8196 2011-07-06 Richard Guenther <rguenther@suse.de>
8197
8198 * gcc-interface/misc.c (gnat_init): Merge calls to
8199 build_common_tree_nodes and build_common_tree_nodes_2.
8200 Re-initialize boolean_false_node.
8201
8202 2011-07-02 Eric Botcazou <ebotcazou@adacore.com>
8203 Olivier Hainque <hainque@adacore.com>
8204 Nicolas Setton <setton@adacore.com>
8205
8206 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
8207 the type according to the ARTIFICIAL_P parameter.
8208 (create_type_decl): Likewise.
8209 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
8210
8211 2011-07-01 Eric Botcazou <ebotcazou@adacore.com>
8212
8213 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
8214 (gnatbind): Likewise.
8215
8216 2011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8217
8218 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
8219
8220 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
8221
8222 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
8223 local variable throughout. Remove useless call to Base_Type.
8224 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
8225 Take it also into account for the volatileness of the field. Set the
8226 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
8227
8228 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
8229
8230 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
8231 on a dereference built for a by-ref object if it has an address clause.
8232
8233 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
8234
8235 * einfo.ads (Address_Taken): Document use for the second argument of
8236 Asm_Input and Asm_Output attributes.
8237 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
8238 argument is an entity name, then set Address_Taken on it.
8239 <Attribute_Asm_Output>: Likewise.
8240 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
8241 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
8242 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
8243 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
8244
8245 2011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
8246
8247 PR middle-end/46500
8248 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
8249
8250 2011-06-14 Joseph Myers <joseph@codesourcery.com>
8251
8252 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
8253 (ada/utils.o): Update dependencies.
8254 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
8255 ../../../libcpp/libcpp.a.
8256 * gcc-interface/utils.c: Include common/common-target.h.
8257 (process_attributes): Use targetm_common.have_named_sections.
8258
8259 2011-06-07 Richard Guenther <rguenther@suse.de>
8260
8261 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
8262 set_sizetype.
8263
8264 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
8265
8266 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
8267 TREE_THIS_NOTRAP flag.
8268
8269 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
8270
8271 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
8272 Fix thinko.
8273
8274 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
8275
8276 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
8277 constants whose full view has discriminants specially.
8278
8279 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
8280
8281 * gcc-interface/utils.c: Include diagnostic.h.
8282 (gnat_write_global_declarations): Output debug information for all
8283 global type declarations before finalizing the compilation unit.
8284 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
8285
8286 2011-05-25 Jakub Jelinek <jakub@redhat.com>
8287
8288 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
8289
8290 2011-05-25 Kai Tietz <ktietz@redhat.com>
8291
8292 * adaint.c (__gnat_to_canonical_file_list_next): Use array
8293 initialization instead of const/none-const pointer assignment.
8294
8295 2011-05-24 Joseph Myers <joseph@codesourcery.com>
8296
8297 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
8298 $(EXTRA_GNAT1_OBJS).
8299 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
8300 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
8301 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
8302 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
8303 libcommon-target.a instead of prefix.o.
8304
8305 2011-05-21 Joseph Myers <joseph@codesourcery.com>
8306
8307 PR ada/49097
8308 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
8309
8310 2011-05-20 Joseph Myers <joseph@codesourcery.com>
8311
8312 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
8313 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
8314 instead of version.o.
8315
8316 2011-05-18 Kai Tietz <ktietz@redhat.com>
8317
8318 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
8319 boolean_false_node instead of integer_zero_node.
8320 (convert_with_check): Likewise.
8321 * gcc-interface/decl.c (choices_to_gnu): Likewise.
8322
8323 2011-05-12 Eric Botcazou <ebotcazou@adacore.com>
8324
8325 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
8326 type of the parameter is an unconstrained array, convert the actual to
8327 the type of the formal in the In Out and Out cases as well.
8328
8329 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
8330
8331 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
8332 call build_function_type_array or build_varargs_function_type_array
8333 instead.
8334 (create_subprog_type): Don't call build_function_type; call
8335 build_function_type_vec instead.
8336
8337 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
8338
8339 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
8340 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
8341 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
8342
8343 2011-05-07 Eric Botcazou <ebotcazou@adacore.com>
8344
8345 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
8346
8347 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
8348 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
8349
8350 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
8351
8352 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
8353
8354 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
8355
8356 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
8357 instead of accessing TYPE_ARG_TYPES directly.
8358 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
8359
8360 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
8361
8362 PR ada/48844
8363 * gcc-interface/gigi.h (get_variant_part): Declare.
8364 * gcc-interface/decl.c (get_variant_part): Make global.
8365 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
8366 types have the same constant size, are record types and T1 has a
8367 variant part while T2 doesn't.
8368
8369 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
8370
8371 * gcc-interface/utils.c (begin_subprog_body): Do not call
8372 get_pending_sizes.
8373 (end_subprog_body): Likewise.
8374
8375 2011-05-04 Richard Guenther <rguenther@suse.de>
8376
8377 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
8378 int_const_binop.
8379 (pos_to_constructor): Likewise.
8380
8381 2011-05-03 Nathan Froyd <froydnj@codesourcery.com>
8382 Eric Botcazou <ebotcazou@adacore.com>
8383
8384 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
8385 of build_function_type. Adjust calls to...
8386 (build_raise_check): ...this. Do not take a void_tree parameter.
8387 Call build_function_type_list instead of build_function_type.
8388 Fix head comment and swap couple of conditional blocks.
8389
8390 2011-04-30 Eric Botcazou <ebotcazou@adacore.com>
8391
8392 * gnatvsn.ads (Library_Version): Bump to 4.7.
8393 (Current_Year): Bump to 2011.
8394
8395 2011-04-29 Michael Matz <matz@suse.de>
8396
8397 * gcc-interface/misc.c (gnat_handle_option): Set
8398 warn_maybe_uninitialized.
8399
8400 2011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
8401
8402 * gnat_ugn.texi (Complexity Metrics Control): Update link to
8403 the Watson/McCabe paper.
8404
8405 2011-04-23 Jim Meyering <meyering@redhat.com>
8406
8407 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
8408
8409 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
8410
8411 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
8412 onto the new type.
8413
8414 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
8415
8416 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
8417 parameter.
8418 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
8419 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
8420 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
8421 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
8422 <all>: Do not set flags on the reused DECL node coming from an alias.
8423 Set DECL_IGNORED_P on the DECL node built for subprograms if they
8424 don't need debug info here...
8425 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
8426 (gigi): Adjust calls to create_subprog_decl.
8427 (build_raise_check): Likewise.
8428 (establish_gnat_vms_condition_handler): Likewise.
8429 (Compilation_Unit_to_gnu): Likewise.
8430 (gnat_to_gnu): Likewise.
8431
8432 2011-04-21 Eric Botcazou <ebotcazou@adacore.com>
8433
8434 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
8435 (NO_REORDER_ADAFLAGS): New variable.
8436 (EXTRA_GNATTOOLS): Always define.
8437 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
8438 Clean up and adjust list of files compiled with special options.
8439 * gcc-interface/Make-lang.in: Likewise.
8440 (ada/decl.o): Cosmetical change.
8441 (ada/misc.o): Remove dependency on $(PLUGIN_H).
8442
8443 2011-04-20 Jim Meyering <meyering@redhat.com>
8444
8445 * initialize.c (__gnat_initialize): Remove useless if-before-free.
8446
8447 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
8448
8449 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
8450 $(CFLAGS) on the link line.
8451
8452 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
8453
8454 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
8455 padded type built for the return type if it is unconstrained.
8456
8457 2011-04-14 Nathan Froyd <froydnj@codesourcery.com>
8458
8459 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
8460
8461 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
8462
8463 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
8464 before calling TREE_CHAIN.
8465 * gcc-interface/misc.c (gnat_init_ts): New function.
8466 (LANG_HOOKS_INIT_TS): Define.
8467
8468 2011-04-12 Martin Jambor <mjambor@suse.cz>
8469
8470 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
8471 instead of cgraph_node.
8472
8473 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
8474
8475 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
8476 alignment on fields of the RETURN type built for the Copy-In Copy-Out
8477 mechanism.
8478
8479 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
8480
8481 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
8482 of aggregate types that contain a placeholder.
8483
8484 2011-04-08 Nathan Froyd <froydnj@codesourcery.com>
8485
8486 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
8487 TYPE_ARG_TYPES.
8488 (handle_type_generic_attribute): Likewise.
8489
8490 2011-04-04 Eric Botcazou <ebotcazou@adacore.com>
8491
8492 PR ada/47163
8493 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
8494
8495 2011-04-04 Kai Tietz <ktietz@redhat.com>
8496
8497 PR ada/47163
8498 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
8499 to flag value.
8500
8501 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
8502
8503 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
8504 type case, do not strip a padding type around the array type.
8505
8506 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
8507
8508 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
8509 types.
8510
8511 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
8512
8513 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
8514 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
8515 code for -feliminate-unused-debug-types.
8516 (gnat_post_options): Likewise.
8517
8518 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
8519
8520 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
8521 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
8522 distinct copy.
8523
8524 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
8525
8526 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
8527 DECL_ARTIFICIAL flag on enumeration types.
8528
8529 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
8530
8531 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
8532 fat pointer types artificial unconditionally.
8533 <E_Array_Subtype>: Attach the base array type as a parallel type if it
8534 isn't artificial.
8535
8536 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
8537
8538 * gcc-interface/gigi.h (get_dummy_type): Declare.
8539 (build_dummy_unc_pointer_types): Likewise.
8540 (finish_fat_pointer_type): Likewise.
8541 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
8542 fat pointer type has been built, complete it in place.
8543 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
8544 and thin pointers. Remove useless variable.
8545 (finish_fat_pointer_type): Make global and move to...
8546 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
8547 (get_dummy_type): New function.
8548 (build_dummy_unc_pointer_types): Likewise.
8549 (gnat_pushdecl): Propage the name to the anonymous variants only.
8550 (update_pointer_to): Only adjust the pointer types in the unconstrained
8551 array case.
8552
8553 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
8554
8555 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
8556 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
8557 if this is a Taft amendment type and the full declaration is available.
8558 * gcc-interface/trans.c (process_type): Likewise.
8559 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
8560 (process_freeze_entity): Likewise.
8561 * gcc-interface/utils.c (dummy_global): New static variable.
8562 (gnat_write_global_declarations): If there are types declared as used
8563 at the global level, insert them in the global hash table.
8564
8565 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
8566
8567 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
8568 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
8569 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
8570 copy.
8571 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
8572 flag of the type accordingly.
8573 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
8574
8575 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
8576
8577 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
8578 finalizing types when updating the pointers to the designated type.
8579 <all>: Finalize the deferred types even if we didn't defer processing
8580 of incomplete types in this invocation.
8581
8582 2011-04-01 Olivier Hainque <hainque@adacore.com>
8583 Nicolas Setton <setton@adacore.com>
8584 Eric Botcazou <ebotcazou@adacore.com>
8585
8586 * gcc-interface/misc.c (gnat_descriptive_type): New function.
8587 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
8588
8589 2011-03-28 Kai Tietz <ktietz@redhat.com>
8590
8591 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
8592 Windows targets.
8593 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
8594 * system-mingw.ads (System): Change ZCX_By_Default default to True.
8595
8596 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
8597
8598 2011-03-28 Tristan Gingold <gingold@adacore.com>
8599
8600 PR ada/44431
8601 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
8602 Use ada output of gnatbind.
8603 (ada/b_gnatb.adb): Ditto.
8604 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
8605 (ada.mostlyclean, ada.stage1)
8606 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
8607 (ada.stagefeedback): Adjust.
8608 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
8609 Use ada output of gnatbind.
8610 (b_gnatm.adb): Ditto.
8611 (b_gnatl.o, b_gnatm.o): New rules.
8612
8613 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
8614
8615 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
8616 for the padded type built to support a specified size or alignment.
8617
8618 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
8619
8620 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
8621 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
8622 unconditionally to the end of the unit when the designated type is
8623 limited_with'ed.
8624 <all>: Rename local variable. Attempt to un-defer types only and do it
8625 for limited_with'ed types as well.
8626 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
8627 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
8628 consistently and remove redundant call to finalize_from_with_types.
8629
8630 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
8631
8632 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
8633 subprograms without a previous spec declared in the same unit.
8634 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
8635 subprograms at the end of the unit instead of at the beginning.
8636 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
8637 isn't public for the special handling of non-inline functions nested
8638 inside inline external functions.
8639
8640 2011-03-25 Jeff Law <law@redhat.com>
8641
8642 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
8643
8644 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
8645
8646 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
8647 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
8648 to compute Set_Size_Depends_On_Discriminant.
8649 (Layout_Type): Call it on array types in back-end layout mode.
8650 * sem_util.adb (Requires_Transient_Scope): Return true for array
8651 types only if the size depends on the value of discriminants.
8652 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
8653 type if the RHS is a call to a function that returns an unconstrained
8654 type with default discriminant.
8655
8656 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
8657
8658 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
8659 non-conversion to the nominal result type at the end.
8660
8661 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
8662
8663 * gcc-interface/trans.c (create_temporary): New function taken from...
8664 (create_init_temporary): ...here. Call it.
8665 (call_to_gnu): Create the temporary for the return value early, if any.
8666 Create it for a function with copy-in/copy-out parameters if there is
8667 no target; in other cases of copy-in/copy-out, use another temporary.
8668 Push the new binding level lazily. Add and rename local variables.
8669
8670 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
8671
8672 * gcc-interface/decl.c (validate_size): Improve comments and tweak
8673 error message.
8674 (set_rm_size): Likewise.
8675
8676 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
8677
8678 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
8679 for the padded type built in order to support a specified alignment.
8680 Fix incorrect formatting.
8681
8682 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
8683
8684 PR bootstrap/48216
8685 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
8686
8687 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
8688
8689 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
8690 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
8691 to the end of the list. Adjust recursive call. Rename local variable.
8692 If REORDER is true, reorder components of the record type.
8693 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
8694 components_to_record and adjust the parameter list.
8695
8696 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
8697
8698 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
8699 disabled, use the variable for bounds of loop iteration scheme.
8700
8701 2011-03-21 Kai Tietz <ktietz@redhat.com>
8702
8703 PR target/12171
8704 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
8705
8706 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
8707
8708 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
8709 out whether the expression is read-only. Short-circuit placeholder
8710 case and rename a couple of local variables.
8711
8712 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
8713
8714 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
8715 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
8716 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
8717 (convert): Deal with conversions from a smaller form type specially.
8718
8719 2011-02-14 Eric Botcazou <ebotcazou@adacore.com>
8720
8721 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
8722 its argument, except for the special -I- switch.
8723
8724 2011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
8725
8726 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
8727 "Ada Issues".
8728
8729 2011-02-08 Eric Botcazou <ebotcazou@adacore.com>
8730
8731 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
8732
8733 2011-02-03 Eric Botcazou <ebotcazou@adacore.com>
8734
8735 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
8736 GNAT_FORMAL.
8737 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
8738 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
8739 instead of GNAT_FORMAL. Protect the expression against multiple uses.
8740 Do not generate the check directly, instead instantiate the template
8741 check present in the descriptor.
8742 (make_descriptor_field): Move around.
8743 (build_vms_descriptor32): Build a template check in the POINTER field.
8744 (build_vms_descriptor): Remove useless suffixes.
8745 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
8746
8747 2011-01-26 Eric Botcazou <ebotcazou@adacore.com>
8748
8749 PR bootstrap/47467
8750 * targext.c: Include target files if IN_RTS is defined.
8751
8752 2011-01-26 Richard Guenther <rguenther@suse.de>
8753
8754 PR bootstrap/47467
8755 * targext.c: Include config.h.
8756 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
8757 dependency.
8758
8759 2011-01-04 Pascal Obry <obry@adacore.com>
8760 Eric Botcazou <ebotcazou@adacore.com>
8761
8762 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
8763
8764 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
8765
8766 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
8767 end-of-case on the end label and its associated gotos, if any.
8768
8769 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
8770
8771 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
8772 expressions of the parameter cache within the statement group of
8773 the CICO mechanism.
8774
8775 2011-01-04 Olivier Hainque <hainque@adacore.com>
8776 Eric Botcazou <ebotcazou@adacore.com>
8777
8778 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
8779 (set_end_locus_from_node): New function.
8780 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
8781 make and the function end_locus.
8782 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
8783 for the elaboration subprogram.
8784 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
8785 set the end_locus of the expression as well.
8786
8787 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
8788
8789 PR ada/47131
8790 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
8791 variables that are referenced in exception handlers volatile.
8792
8793
8794 \f
8795 Copyright (C) 2011 Free Software Foundation, Inc.
8796
8797 Copying and distribution of this file, with or without modification,
8798 are permitted in any medium without royalty provided the copyright
8799 notice and this notice are preserved.