[multiple changes]
[gcc.git] / gcc / ada / ChangeLog
1 2011-09-15 Robert Dewar <dewar@adacore.com>
2
3 * a-cdlili.adb, a-coinve.adb, a-stzunb-shared.ads, a-suezst.adb,
4 a-suenco.adb, a-stwiun-shared.ads, a-cobove.adb, a-convec.adb,
5 a-btgbso.adb, a-cbdlli.adb, a-suewst.adb: Minor reformatting.
6
7 2011-09-15 Ed Schonberg <schonberg@adacore.com>
8
9 * sem_ch6.adb (Analyze_Expression_Function): Code cleanup:
10 if the expression function is not a completion, create a
11 new specification for the generated declaration, and keep the
12 original specification in the generated body. Shorter code also
13 ensures that proper warnings are generated for unused formals
14 in all cases.
15
16 2011-09-15 Sergey Rybin <rybin@adacore.com>
17
18 * tree_io.ads: Update ASIS_Version_Number because of the changes
19 in the tree structures for expression functions.
20
21 2011-09-15 Arnaud Charlet <charlet@adacore.com>
22
23 * s-osinte-aix.ads, s-osinte-darwin.ads, s-osinte-freebsd.ads,
24 s-osinte-hpux.ads, s-osinte-lynxos.ads, s-osinte-solaris-posix.ads,
25 s-taprop-posix.adb (CLOCK_MONOTONIC): New constant.
26 (CLOCK_REALTIME): Fix wrong value on some OSes.
27 * s-taprop-posix.adb (Monotonic_Clock): Use CLOCK_MONOTONIC.
28
29 2011-09-11 Eric Botcazou <ebotcazou@adacore.com>
30
31 * gcc-interface/utils.c (maybe_unconstrained_array): In the reference
32 to unconstrained array case, deal with each branch of a COND_EXPR.
33 * gcc-interface/utils2.c (build_allocator): Deal with each branch of
34 a COND_EXPR in the initializer, if present.
35
36 2011-09-11 Eric Botcazou <ebotcazou@adacore.com>
37
38 * gcc-interface/decl.c (maybe_pad_type): Do not try to change the form
39 of an addressable type.
40 * gcc-interface/trans.c (gnat_gimplify_expr) <VIEW_CONVERT_EXPR>: New.
41 Deal with those cases for which creating a temporary is mandatory.
42
43 2011-09-11 Eric Botcazou <ebotcazou@adacore.com>
44
45 * gcc-interface/trans.c (call_to_gnu): Use local variable. Make sure
46 this is a real formal parameter before testing whether it is by ref.
47
48 2011-09-11 Eric Botcazou <ebotcazou@adacore.com>
49
50 * gcc-interface/gigi.h (build_call_0_expr): Delete.
51 (build_call_1_expr): Likewise.
52 (build_call_2_expr): Likewise.
53 (build_call_n_expr): New prototype.
54 * gcc-interface/decl.c (gnat_to_gnu_entity): Use build_call_n_expr.
55 * gcc-interface/trans.c (establish_gnat_vms_condition_handler): Ditto.
56 (Handled_Sequence_Of_Statements_to_gnu): Likewise.
57 (Exception_Handler_to_gnu_zcx): Likewise.
58 (gnat_to_gnu): Likewise.
59 (build_binary_op_trapv): Likewise.
60 * gcc-interface/utils2.c (build_call_0_expr): Delete.
61 (build_call_1_expr): Likewise.
62 (build_call_2_expr): Likewise.
63 (build_call_n_expr): New function.
64 (build_call_raise): Use build_call_n_expr.
65 (build_call_raise_range): Likewise.
66 (build_call_raise_column): Likewise.
67 (build_call_alloc_dealloc_proc): Likewise.
68 (maybe_wrap_malloc): Likewise.
69 (maybe_wrap_free): Likewise.
70
71 2011-09-11 Eric Botcazou <ebotcazou@adacore.com>
72
73 * gcc-interface/trans.c (build_return_expr): Use void_type_node for
74 MODIFY_EXPR.
75 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Assert that
76 the result type is null if ENABLE_CHECKING. Set operation_type at the
77 end unconditionally if not set in the previous cases.
78 Use build2 and void_type_node for MODIFY_EXPR.
79 (build_allocator): Use NULL_TREE for MODIFY_EXPR.
80
81 2011-09-08 Eric Botcazou <ebotcazou@adacore.com>
82
83 * gcc-interface/utils.c (unchecked_convert): Use a field of the right
84 precision when converting to or from an integral type whose precision
85 is not equal to its size.
86
87 2011-09-08 Iain Sandoe <iains@gcc.gnu.org>
88
89 * traceback.c (Darwin) USE_GCC_UNWINDER for Darwin versions >= 8.
90
91 2011-09-07 Iain Sandoe <iains@gcc.gnu.org>
92
93 * gcc-interface/Makefile.in (darwin): Provide powerpc64 system
94 implementation.
95 * system-darwin-ppc64.ads: New file.
96
97 2011-09-06 Iain Sandoe <iains@gcc.gnu.org>
98
99 * gcc-interface/Makefile.in (gnatlib-shared-darwin): Remove
100 reference to "-lm".
101
102 2011-09-06 Iain Sandoe <iains@gcc.gnu.org>
103
104 * gcc-interface/Makefile.in (darwin, SO_OPTS): Provide architecture
105 size switches to the link phase for shared libs.
106
107 2011-09-06 Iain Sandoe <iains@gcc.gnu.org>
108
109 * gcc-interface/Makefile.in (x86_64 darwin arch): Adjust
110 LIBGNAT_TARGET_PAIRS for x86 and x86_64 variants.
111
112 2011-09-06 Arnaud Charlet <charlet@adacore.com>
113
114 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in
115 (gnattools, regnattools, cross-gnattools, canadian-gnattools,
116 gnatlib, gnatlib-sjlj, gnatlib-zcx, gnatlib-shared, gnatlib_and_tools):
117 New targets.
118 (TOOLS_FLAGS_TO_PASS): New.
119 (../stamp-tools): Reintroduce, to avoid merge conflicts.
120
121 2011-09-06 Robert Dewar <dewar@adacore.com>
122
123 * sem_ch10.adb, impunit.ads, impunit.adb (Not_Impl_Defined_Unit): New
124 name for Is_RM_Defined_Unit. Also several fixes to this unit.
125
126 2011-09-06 Robert Dewar <dewar@adacore.com>
127
128 * impunit.ads, impunit.adb (Is_RM_Defined_Unit): New function.
129 * s-rident.ads: New restriction No_Implementation_Units
130 (this restriction is also part of the profile
131 No_Implementation_Extensions)
132 * sem_ch10.adb (Analyze_With_Clause): Add check for
133 No_Implementation_Units restriction.
134
135 2011-09-06 Jerome Guitton <guitton@adacore.com>
136
137 * sysdep.c (__gnat_get_task_options): Disable VX_SPE_TASK
138 on vThreads.
139
140 2011-09-06 Thomas Quinot <quinot@adacore.com>
141
142 * s-solita.adb: Minor reformatting.
143
144 2011-09-06 Ed Schonberg <schonberg@adacore.com>
145
146 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): The body that
147 is a rewriting of an expression function does not freeze previous
148 entities.
149
150 2011-09-06 Robert Dewar <dewar@adacore.com>
151
152 * impunit.adb (Is_Known_Unit): Fix bad handling of Ada 2012 case
153
154 2011-09-06 Tristan Gingold <gingold@adacore.com>
155
156 * gcc-interface/Makefile.in: Handle e500v2-wrs-vxworksae like
157 powerpc-wrs-vxworksae.
158
159 2011-09-06 Thomas Quinot <quinot@adacore.com>
160
161 * s-os_lib.ads (Spawn): Minor documentation clarification,
162 Success is True for a zero exit status.
163
164 2011-09-06 Ed Schonberg <schonberg@adacore.com>
165
166 * sem_ch5.adb: Add message for common iterator error.
167
168 2011-09-06 Ed Schonberg <schonberg@adacore.com>
169
170 * exp_ch3.adb (Build_Initialization_Call): If the target is a
171 selected component discriminated by a current instance, replace
172 the constraint with a reference to the target object, regardless
173 of whether the context is an init_proc.
174
175 2011-09-06 Robert Dewar <dewar@adacore.com>
176
177 * exp_attr.adb: Descriptor_Size is never static.
178
179 2011-09-06 Robert Dewar <dewar@adacore.com>
180
181 * gnat_ugn.texi: Add documentation for LSLOC metric in gnatmetric
182
183 2011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
184
185 * gnat_rm.texi: Clarify that attribute Descriptor_Size is
186 non-static.
187
188 2011-09-06 Ed Schonberg <schonberg@adacore.com>
189
190 * sem_res.adb (Resolve): An expression that is the body of an
191 expression function does not freeze.
192
193 2011-09-06 Matthew Heaney <heaney@adacore.com>
194
195 * a-csquin.ads, a-cusyqu.adb, a-cbprqu.adb, a-cbsyqu.adb,
196 a-cuprqu.adb: Changed copyright notice to indicate current
197 year only.
198
199 2011-09-06 Vincent Celier <celier@adacore.com>
200
201 * prj.adb: Minor spelling error fix in comment
202 * sem_res.adb: Minor reformatting
203
204 2011-09-06 Pascal Obry <obry@adacore.com>
205
206 * sysdep.c (winflush_nt): Removed as not needed anymore.
207 (winflush_95): Likewise.
208 (winflush_init): Likewise.
209 (winflush_function): Likewise.
210 (getc_immediate_common): Remove call to winflush_function.
211
212 2011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
213
214 * exp_attr.adb (Expand_N_Attribute_Reference): Rewrite the
215 processing for Descriptor_Size.
216 * gnat_rm.texi: Rephrase the wording for attribute Descriptor_Size
217 to account for its broader usage.
218 * sem_attr.adb (Analyze_Attribute): Change the error detection
219 circuitry for Descriptor_Size as the attribute is now applicable
220 to all types.
221
222 2011-09-06 Robert Dewar <dewar@adacore.com>
223
224 * sem_attr.adb, prj-nmsc.adb, exp_aggr.adb: Minor reformatting.
225
226 2011-09-06 Ed Schonberg <schonberg@adacore.com>
227
228 * lib-xref.adb (OK_To_Set_Referenced): A reference to a formal
229 in a parameter association must not set the Referenced flag on
230 the formal.
231 * prj-nmsc.adb (Check_File_Naming_Schemes): Remove useless formal
232
233 2011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
234
235 * gnat_rm.texi: Add a section on attribute Descriptor_Size
236
237 2011-09-06 Arnaud Charlet <charlet@adacore.com>
238
239 * gcc-interface/Makefile.in (common-tools, gnatmake-re,
240 gnatlink-re): Speed up by using -j0.
241
242 2011-09-06 Yannick Moy <moy@adacore.com>
243
244 * sem_ch13.adb (Analyze_Aspect_Specifications): Call
245 Set_Corresponding_Aspect when creating pragma from aspect.
246 (Add_Predicates): Use new field Corresponding_Aspect.
247 * sem_prag.adb (Analyze_Pragma): Make Pname hold source aspect
248 name when present, for the purpose of issuing error messages;
249 remove local procedure Error_Pragma_Arg_Alternate_Name.
250 * sinfo.adb, sinfo.ads (Corresponding_Aspect): New field in
251 N_Pragma node.
252 (From_Dynamic_Predicate, From_Static_Predicate): Remove fields from
253 N_Pragma node.
254
255 2011-09-06 Robert Dewar <dewar@adacore.com>
256
257 * checks.adb, s-except.ads, g-socket.adb: Minor reformatting.
258
259 2011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
260
261 * exp_ch6.adb (Build_Heap_Allocator): Add new
262 local variable Desig_Typ. Code and comment reformatting. Add
263 machinery to ensure that the allocation uses a fat pointer when
264 the type of the return object is a constrained array and the
265 function return type is an unconstrained array.
266
267 2011-09-06 Vincent Celier <celier@adacore.com>
268
269 * make.adb, prj-part.adb, prj-nmsc.adb: Remove unused formal
270 parameters in subprograms.
271
272 2011-09-06 Arnaud Charlet <charlet@adacore.com>
273
274 * s-taprop-mingw.adb (Finalize_TCB): Fix typo.
275
276 2011-09-06 Thomas Quinot <quinot@adacore.com>
277
278 * s-taprop-vxworks.adb, s-tpoaal.adb, s-tpopsp-vxworks.adb
279 (System.Tasking.Primitive_Operations.Specific.Delete): Remove
280 subprogram.
281 (System.Tasking.Primitive_Operations.Specific.Set): If argument
282 is null, destroy task specific data, to make API consistent with
283 other platforms, and thus compatible with the shared version
284 of s-tpoaal.adb.
285 (System.Tasking.Primitive_Operations.ATCB_Allocation.Free_ATCB):
286 Document the above assumption.
287
288 2011-09-06 Ed Schonberg <schonberg@adacore.com>
289
290 * exp_ch6.adb (Expand_Inlined_Call): Fix use of uninitialized
291 variable for type of return value when return type is
292 unconstrained and context is an assignment.
293
294 2011-09-06 Ed Schonberg <schonberg@adacore.com>
295
296 * sem_ch8.adb (Check_Class_Wide_Actual): Do not generate body of
297 class-wide operation if expansion is not enabled.
298
299 2011-09-06 Eric Botcazou <ebotcazou@adacore.com>
300
301 * checks.adb (Apply_Scalar_Range_Check): Deal with access
302 type prefix.
303
304 2011-09-06 Yannick Moy <moy@adacore.com>
305
306 * sem_ch13.adb (Analyze_Aspect_Specifications, case
307 Aspect_Invariant): Do not issue error at this point on illegal
308 pragma placement, as this is checked later on when analyzing
309 the corresponding pragma.
310 * sem_prag.adb (Error_Pragma_Arg_Alternate_Name): New procedure
311 similar to Error_Pragma_Arg, except the source name of the
312 aspect/pragma to use in warnings may be equal to parameter
313 Alt_Name (Analyze_Pragma, case Pragma_Invariant): refine error
314 message to distinguish source name of pragma/aspect, and whether
315 the illegality resides in the type being public, or being private
316 without a public declaration
317
318 2011-09-06 Thomas Quinot <quinot@adacore.com>
319
320 * g-socket.adb (Check_For_Fd_Set): On Windows, no need for bitmap
321 size check (fd_set is implemented differently on that platform).
322
323 2011-09-06 Thomas Quinot <quinot@adacore.com>
324
325 * s-taprop-vxworks.adb, s-taprop-tru64.adb, s-taprop-vms.adb,
326 s-tpoaal.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
327 s-taprop-solaris.adb, s-taprop-irix.adb, s-taprop.ads,
328 s-taprop-hpux-dce.adb, s-taprop-dummy.adb, s-taprop-posix.adb
329 (ATCB_Allocation): New subpackage of
330 System.Tasking.Primitive_Operations, shared across all targets
331 with full tasking runtime.
332 (ATCB_Allocation.New_ATCB): Moved there (from target specific
333 s-taprop bodies).
334 (ATCB_Allocation.Free_ATCB): New subprogram. Deallocate an ATCB,
335 taking care of establishing a local temporary ATCB if the one
336 being deallocated is Self, to avoid a reference to the freed
337 ATCB in Abort_Undefer.
338
339 2011-09-06 Thomas Quinot <quinot@adacore.com>
340
341 * s-tassta.adb, s-taskin.ads (Free_Task): If the task is not
342 terminated, mark it for deallocation upon termination.
343 (Terminate_Task): Call Free_Task again if the task is marked
344 for automatic deallocation upon termination.
345
346 2011-09-06 Robert Dewar <dewar@adacore.com>
347
348 * a-cbprqu.ads, a-cbsyqu.ads, a-cuprqu.ads, a-cusyqu.ads,
349 a-intnam-aix.ads, a-intnam-darwin.ads, a-intnam-dummy.ads,
350 a-intnam-freebsd.ads, a-intnam-hpux.ads, a-intnam-irix.ads,
351 a-intnam-linux.ads, a-intnam-lynxos.ads, a-intnam-mingw.ads,
352 a-intnam-solaris.ads, a-intnam-tru64.ads,
353 a-intnam-vms.ads, a-intnam-vxworks.ads, a-intnam.ads, interfac.ads,
354 cstand.adb, s-maccod.ads: Mark all entities as Implementation_Defined
355 * einfo.ads, einfo.adb (Is_Implementation_Defined): New flag
356 * par-prag.adb: Add dummy entry for pragma Implementation_Defined
357 * s-rident.ads: Add new restriction No_Implementation_Identifiers
358 Add new profile No_Implementation_Extensions
359 * sem_prag.adb: Implement pragma Implementation_Defined Implement
360 profile No_Implementation_Extensions
361 * sem_util.adb: Minor reformatting (Set_Entity_With_Style_Check):
362 Check violation of restriction No_Implementation_Identifiers
363 * snames.ads-tmpl: Add entries for pragma Implementation_Defined
364 Add entry for Name_No_Implementation_Extensions
365
366 2011-09-06 Robert Dewar <dewar@adacore.com>
367
368 * impunit.ads: Minor reformatting.
369
370 2011-09-06 Robert Dewar <dewar@adacore.com>
371
372 * ali.adb, sem_ch13.adb, lib-xref.adb: Minor reformatting.
373
374 2011-09-06 Pascal Obry <obry@adacore.com>
375
376 * s-osinte-linux.ads, s-oscons-tmplt.c: Use oscons to define sigset_t
377 types.
378
379 2011-09-06 Robert Dewar <dewar@adacore.com>
380
381 * g-socket.adb: Minor reformatting
382
383 2011-09-06 Javier Miranda <miranda@adacore.com>
384
385 * ali.adb (Scan_ALI): Add missing support to load references of
386 entities imported from other languages.
387 * ali.ads (Xref_Record): Adding new fields to store the language and
388 name of an imported entity.
389 * lib-xref.adb (Output_Import_Export_Info): Fix typo
390 in comment.
391
392 2011-09-06 Ed Schonberg <schonberg@adacore.com>
393
394 * sem_prag.adb (Analyze_Pragma, case Type_Invariant): A type invariant
395 is allowed on a full type declaration if it is the completion of
396 a private declarations.
397 * sem_ch13.adb (Analyze_Aspect_Specifications): An invariant
398 aspect is allowed on a full type declaration in the private part
399 of a package.
400
401 2011-09-06 Robert Dewar <dewar@adacore.com>
402
403 * sem_ch8.ads: Minor reformatting
404
405 2011-09-06 Thomas Quinot <quinot@adacore.com>
406
407 * s-oscons-tmplt.c, g-socket.adb (GNAT.Sockets.Clear,Set,Is_Set):
408 Guard against socket values that are not in [0;FD_SETSIZE[
409
410 2011-09-06 Robert Dewar <dewar@adacore.com>
411
412 * s-osinte-linux.ads, a-iteint.ads, exp_ch6.adb, s-solita.adb: Minor
413 reformatting.
414
415 2011-09-06 Arnaud Charlet <charlet@adacore.com>
416
417 * s-linux-alpha.ads: Minor reformatting
418 * s-oscons-tmplt.c: Fix generated comments in s-oscons template.
419 Use sizeof instead of corresponding C defines in s-oscons template.
420
421 2011-09-06 Vadim Godunko <godunko@adacore.com>
422
423 * a-convec.ads, a-iteint.ads: Minor reformatting.
424
425 2011-09-06 Vincent Celier <celier@adacore.com>
426
427 * projects.texi: Add menus and @node lines.
428
429 2011-09-06 Ed Schonberg <schonberg@adacore.com>
430
431 * exp_ch6.adb (Expand_Inlined_Call): Handle properly the case
432 where the return type is an unconstrained array and the context
433 is an assignment. Optimize the case when the target of the
434 assignment is a selected component.
435
436 2011-09-06 Arnaud Charlet <charlet@adacore.com>
437
438 * s-solita.adb: Update comments.
439
440 2011-09-06 Pascal Obry <obry@adacore.com>
441
442 * s-linux.ads, s-linux-alpha.ads, s-linux-hppa.ads, s-linux-mipsel.ads,
443 s-linux-sparc.ads: Remove hard coded and now wrong definitions.
444 * s-oscons-tmplt.c: Add support for generating pthread related
445 types size on GNU/Linux as done for Darwin.
446 * s-osinte-linux.ads: Use s-oscons to define the pthread types.
447
448 2011-09-06 Robert Dewar <dewar@adacore.com>
449
450 * exp_ch6.adb: Fix minor typo.
451
452 2011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
453
454 * exp_ch7.adb: Remove with and use clauses for Get_Targ.
455 (Alignment_Of): Moved to the body of Nearest_Multiple_Rounded_Up.
456 (Double_Size_Of): Alphabetized. Update the comment on usage.
457 (Make_Finalize_Address_Stmts): Update comments and reformat code.
458 (Nearest_Multiple_Rounded_Up): New routine.
459 (Size_Of): Update comment on usage. The generated expression now
460 accounts for alignment gaps by rounding the size of the type to the
461 nearest multiple rounded up of the type's alignment.
462
463 2011-09-06 Robert Dewar <dewar@adacore.com>
464
465 * exp_ch7.adb, g-comlin.adb: Minor reformatting.
466
467 2011-09-06 Steve Baird <baird@adacore.com>
468
469 * exp_ch4.adb (Expand_Allocator_Expression): Look through
470 derived subprograms in checking for presence of an
471 Extra_Accessibility_Of_Result formal parameter.
472 * exp_ch6.adb (Expand_Call): Look through derived subprograms in
473 checking for presence of an Extra_Accessibility_Of_Result formal
474 parameter.
475 (Expand_Call.Add_Actual_Parameter): Fix a bug in the
476 case where the Parameter_Associatiations attribute is already set,
477 but set to an empty list.
478 (Needs_Result_Accessibility_Level):
479 Unconditionally return False. This is a temporary
480 change, disabling the Extra_Accessibility_Of_Result
481 mechanism.
482 (Expand_Simple_Function_Return): Check for
483 Extra_Accessibility_Of_Result parameter's presence instead of
484 testing Ada_Version when generating a runtime accessibility
485 check which makes use of the parameter.
486
487 2011-09-06 Ed Schonberg <schonberg@adacore.com>
488
489 * exp_ch4.adb (Expand_N_Case_Expression): Actions created for the
490 expression in a given case alternative must be attached to the
491 statement list of the ccrresponding case statement alternative
492 They cannot be propagated ahead of the case statement, because
493 the validity of the expression that generated the action may
494 hold only for that alternative.
495
496 2011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
497
498 * exp_ch7.adb: Remove with and use clauses for Get_Targ.
499 (Alignment_Of): Remove the code for strict alignment targets.
500 (Double_Alignment_Of): Removed.
501 (Double_Size_Of): New routine.
502 (Make_Finalize_Address_Stmts): Change the
503 calculation of the dope's size. Update relevant comments.
504 (Size_Of): New routine.
505
506 2011-09-06 Steve Baird <baird@adacore.com>
507
508 * einfo.ads (Extra_Accessibility): Update associated comment to use
509 the term "present" correctly ("present" just means that it is not
510 an error to query the value of the attribute - it does not imply
511 that the value must be non-null).
512 (Extra_Constrained): Ditto.
513 (Is_Visible_Formal): Ditto.
514 (Extra_Accessibility_Of_Result) Ditto; also add Inline pragma.
515 (Set_Extra_Accessibility_Of_Result): Add Inline pragma.
516 * exp_ch4.adb (Expand_Allocator_Expression): Improve a comment.
517 * exp_ch6.adb (Expand_Call): The callee may require an
518 Extra_Accessibility_Of_Result actual parameter even if Ada_Version
519 < Ada_2012. This can occur if the callee is exported from a Gnat
520 runtimes unit. Also improve a comment.
521
522 2011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
523
524 * exp_ch7.adb: Add with and use clauses for Get_Targ.
525 (Alignment_Of): Rename formal parameter Some_Typ
526 to Typ, update related comment. Use the allocator alignment on
527 strict alignment targets such as SPARC.
528 (Double_Alignment_Of): Rename formal parameter Some_Typ to Typ, update
529 related comment.
530
531 2011-09-06 Gary Dismukes <dismukes@adacore.com>
532
533 * sem_ch9.adb (Check_Interfaces): Test
534 Is_Limited_Type rather than Is_Limited_Record when checking that
535 the partial view of a synchronized full view must be limited.
536
537 2011-09-06 Emmanuel Briot <briot@adacore.com>
538
539 * g-comlin.adb (Free): Fix memory leak.
540
541 2011-09-06 Robert Dewar <dewar@adacore.com>
542
543 * sem_util.adb, exp_ch6.adb: Minor reformatting and code reorganization.
544
545 2011-09-06 Steve Baird <baird@adacore.com>
546
547 * einfo.ads (Extra_Accessibility_Of_Result): New function; in the
548 (Ada2012) cases described in AI05-0234 where the accessibility
549 level of a function result is "determined by the point of
550 call", an implicit parameter representing that accessibility
551 level is passed in. Extra_Accessibilty_Of_Result yields this
552 additional formal parameter. Extra_Accessibility_Of_Result
553 is analogous to the existing Extra_Accessibility
554 function used in the implementation of access parameters.
555 (Set_Extra_Accessibility_Of_Result): New procedure; sets
556 Extra_Accessibility_Of_Result attribute.
557 * einfo.adb (Extra_Accessibility_Of_Result): New function.
558 (Set_Extra_Accessibility_Of_Result): New procedure.
559 (Write_Field19_Name): Display Extra_Accessibilty_Of_Result attribute.
560 * sem_util.adb (Dynamic_Accessibility_Level): Set Etype of
561 an accessibility level literal to Natural; introduce a nested
562 function, Make_Level_Literal, to do this.
563 * exp_ch6.ads (Needs_Result_Accessibility_Level): New function;
564 determines whether a given function (or access-to-function
565 type) needs to have an implicitly-declared accessibility-level
566 parameter added to its profile.
567 (Add_Extra_Actual_To_Call): Export an existing procedure which was
568 previously declared in the body of Exp_Ch6.
569 * exp_ch6.adb (Add_Extra_Actual_To_Call): Export declaration by moving
570 it to exp_ch6.ads.
571 (Has_Unconstrained_Access_Discriminants): New Function; a
572 predicate on subtype entities which returns True if the given
573 subtype is unconstrained and has one or more access discriminants.
574 (Expand_Call): When expanding a call to a function which takes an
575 Extra_Accessibility_Of_Result parameter, pass in the appropriate
576 actual parameter value. In the case of a function call which is
577 used to initialize an allocator, this may not be possible because
578 the Etype of the allocator may not have been set yet. In this
579 case, we defer passing in the parameter and handle it later in
580 Expand_Allocator_Expression.
581 (Expand_Simple_Function_Return): When returning from a function which
582 returns an unconstrained subtype having at least one access
583 discriminant, generate the accessibility check needed to ensure that
584 the function result will not outlive any objects designated by its
585 discriminants.
586 (Needs_Result_Accessibility_Level): New function; see exp_ch6.ads
587 description.
588 * exp_ch4.adb (Expand_Allocator_Expression): When a function call
589 is used to initialize an allocator, we may need to pass in "the
590 accessibility level determined by the point of call" (AI05-0234)
591 to the function. Expand_Call, where such actual parameters are
592 usually generated, is too early in this case because the Etype of
593 the allocator (which is used in determining the level to be passed
594 in) may not have been set yet when Expand_Call executes. Instead,
595 we generate code to pass in the appropriate actual parameter
596 in Expand_Allocator_Expression.
597 * sem_ch6.adb (Create_Extra_Formals): Create
598 the new Extra_Accessibility_Of_Result formal if
599 Needs_Result_Accessibility_Level returns True. This includes the
600 introduction of a nested procedure, Check_Against_Result_Level.
601
602 2011-09-06 Arnaud Charlet <charlet@adacore.com>
603
604 * gcc-interface/Makefile.in (X86_TARGET_PAIRS): Remove duplicate
605 declaration.
606
607 2011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
608
609 * s-finmas.adb (Set_Finalize_Address): Explain the reason
610 for the synchronization. Move the test for null from
611 s-stposu.Allocate_Any_Controlled to this routine since the check
612 needs to be protected too.
613 (Set_Heterogeneous_Finalize_Address): Explain the reason for the
614 synchronization code.
615 * s-finmas.ads (Set_Heterogeneous_Finalize_Address): Add comment
616 explaining the context in which this routine is used.
617 * s-stposu.adb (Allocate_Any_Controlled): Move the test for null
618 to s-finmas.Set_Finalize_Address.
619
620 2011-09-05 Ed Schonberg <schonberg@adacore.com>
621
622 * einfo.ads: Document that itypes have no parent field.
623
624 2011-09-05 Robert Dewar <dewar@adacore.com>
625
626 * rtsfind.adb (Check_CRT): Check for overloaded entity
627 * rtsfind.ads: Document that entities to be found by rtsfind
628 cannot be overloaded
629 * s-taenca.adb, s-tasren.adb, s-tpobop.adb, s-tpoben.ads, s-tpoben.adb
630 (Lock_Entries_With_Status): New name for Lock_Entries with two
631 arguments (changed to meet rtsfind no overloading rule).
632
633 2011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
634
635 * s-finmas.adb (Set_Finalize_Address (Address,
636 Finalize_Address_Ptr)): Renamed to Set_Heterogeneous_Finalize_Address.
637 (Set_Finalize_Address (in out Finalization_Master,
638 Finalize_Address_Ptr): Add synchronization code.
639 * s-finmas.ads (Set_Finalize_Address (Address,
640 Finalize_Address_Ptr)): Renamed to Set_Heterogeneous_Finalize_Address.
641 * s-stposu.adb (Allocate_Any_Controlled): Update the call to
642 Set_Finalize_Address for the heterogeneous case.
643
644 2011-09-05 Ed Schonberg <schonberg@adacore.com>
645
646 * sem_ch3.adb: Undo previous change, not suitable after all.
647
648 2011-09-05 Robert Dewar <dewar@adacore.com>
649
650 * einfo.ads: Minor comment clarification.
651
652 2011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
653
654 * exp_ch6.adb (Move_Activation_Chain): Rewritten. The routine
655 no longer needs to search through the entities of the return
656 statement scope to find the _chain.
657 * sem_ch5.adb: Add with and use clauses for Exp_Ch6 and Sem_Ch6.
658 (Analyze_Block_Statement): Add local variable
659 Is_BIP_Return_Statement. Add machinery to install all entities
660 produced by the expansion of the return object declaration.
661 (Install_Return_Entities): New routine.
662 * sem_ch6.ads, sem_ch6.adb (Install_Entity): Moved from body to spec.
663
664 2011-09-05 Ed Schonberg <schonberg@adacore.com>
665
666 * sem_ch10.adb (Analyze_Context): Apply simple fixup if context
667 of subunit is incomplete.
668 (Analyze_Proper_Body): If parent spec is not available, do not
669 attempt analysis.
670
671 2011-09-05 Ed Schonberg <schonberg@adacore.com>
672
673 * sem_disp.adb (Find_Controlling_Arg): Add checks for
674 interface type conversions, that are expanded into dereferences.
675
676 2011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
677
678 * sem_ch6.adb (Analyze_Subprogram_Body_Helper):
679 Examine the parameter and return profile of a subprogram and swap
680 any incomplete types coming from a limited context with their
681 corresponding non-limited views.
682 (Exchange_Limited_Views): New routine.
683
684 2011-09-05 Ed Schonberg <schonberg@adacore.com>
685
686 * sem_ch3.adb (Prepare_Private_Subtype_Completion): Set parent
687 of internal entity to the subtype declaration, so that when
688 entities are subsequently exchanged in a package body, the tree
689 remains properly formatted for ASIS.
690
691 2011-09-05 Johannes Kanig <kanig@adacore.com>
692
693 * g-comlin.adb (Set_Usage): Additional optional argument to set help
694 message.
695 (Display_Help): display the user given help message, if available.
696
697 2011-09-05 Ed Schonberg <schonberg@adacore.com>
698
699 * sem_ch3.adb (OK_For_Limited_Init_In_05): The expression
700 is legal if the original node is an identifier that is a
701 parameterless function call.
702
703 2011-09-05 Pascal Obry <obry@adacore.com>
704
705 * prj-nmsc.adb: Minor reformatting.
706 Add support for standalone aggregate library.
707 (Check_Stand_Alone_Library): Handle standalone aggregate library.
708 * projects.texi: Fix documentation for aggregate library projects.
709
710 2011-09-05 Robert Dewar <dewar@adacore.com>
711
712 * sem_ch6.adb: Minor reformatting.
713
714 2011-09-05 Matthew Gingell <gingell@adacore.com>
715
716 * s-tassta.adb (Task_Wrapper): Ensure that we don't try to write the
717 stack guard page on PPC Linux. This patch ensures the 64K guard page at
718 the bottom of the stack is not overwritten.
719
720 2011-09-05 Thomas Quinot <quinot@adacore.com>
721
722 * exp_intr.adb, s-tasini.adb: Minor reformatting.
723
724 2011-09-05 Ed Schonberg <schonberg@adacore.com>
725
726 * sem_ch3.adb (Access_Definition): If an access type declaration
727 appears in a child unit, the scope of whatever anonymous type
728 may be generated is the child unit itself.
729
730 2011-09-05 Ed Schonberg <schonberg@adacore.com>
731
732 * sem_ch6.adb (Analyze_Expression_Function): Do not set
733 Comes_From_Source on rewritten body.
734 (Analyze_Subprogram_Body_Helper): Check that the original node for
735 the body comes from source, when determining whether expansion
736 of a protected operation is needed.
737
738 2011-09-05 Ed Schonberg <schonberg@adacore.com>
739
740 * exp_aggr.adb (Replace_Type): If the target of the assignment is
741 a selected component and the right-hand side is a self-referential
742 access, the proper prefix of the rewritten attribute is a copy
743 of the left-hand side, not of its prefix.
744
745 2011-09-05 Robert Dewar <dewar@adacore.com>
746
747 * sem_ch5.adb: Minor reformatting.
748 * sem_ch3.adb: Minor code clean up.
749
750 2011-09-05 Jose Ruiz <ruiz@adacore.com>
751
752 * exp_ch9.adb (Make_Initialize_Protection): The fact that
753 restriction No_Dynamic_Attachment is in effect or not should
754 not influence the default priority associated to a protected
755 object. With this change, when the restriction is in effect (as
756 is the case for the Ravenscar profile) the default priority of
757 a protected object with an interrupt handler is in the range of
758 interrupt priorities (Default_Interrupt_Priority) as required
759 by D.3(10).
760
761 2011-09-05 Arnaud Charlet <charlet@adacore.com>
762
763 * a-iteint.ads: Fix header.
764
765 2011-09-05 Vincent Celier <celier@adacore.com>
766
767 * prj-conf.adb (Do_Autoconf): Make sure Obj_Dir always ends
768 with a directory separator to avoid output such as:
769 "/path/to/objauto.cgpr" has been deleted.
770
771 2011-09-05 Robert Dewar <dewar@adacore.com>
772
773 * sem_ch3.adb: Minor reformatting.
774
775 2011-09-05 Ed Schonberg <schonberg@adacore.com>
776
777 * sem_ch5.adb: Better error message.
778
779 2011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
780
781 * exp_aggr.adb: Add with and use clause for Exp_Ch6.
782 (Expand_Array_Aggregate): Detect a special case of an aggregate
783 which contains tasks in the context of an unexpanded return
784 statement of a build-in-place function.
785 * exp_ch6.adb: Add with and use clause for Exp_Aggr.
786 (Expand_N_Extended_Return_Statement): Detect a delayed aggregate
787 which contains tasks and expand it now that the original simple
788 return statement has been rewritten.
789 * exp_ch9.adb (Build_Activation_Chain_Entity): Code
790 reformatting. Do not create a chain for an extended return
791 statement if one is already available.
792 (Has_Activation_Chain): New routine.
793
794 2011-09-05 Marc Sango <sango@adacore.com>
795
796 * sem_ch3.adb (Analyze_Object_Declaration): Remove
797 the wrong test and add the correct test to detect the violation
798 of illegal use of unconstrained string type in SPARK mode.
799
800 2011-09-05 Ed Schonberg <schonberg@adacore.com>
801
802 * sem_ch5.adb (Analyze_Iteration_Specification): Improve error
803 message on an iterator over an array.
804
805 2011-09-05 Robert Dewar <dewar@adacore.com>
806
807 * lib-xref-alfa.adb: Minor reformatting.
808
809 2011-09-05 Robert Dewar <dewar@adacore.com>
810
811 * sem_ch3.adb, sem_res.adb, par.adb, par-ch6.adb, g-comlin.adb,
812 exp_ch6.adb, lib-xref-alfa.adb: Minor reformatting.
813
814 2011-09-05 Gary Dismukes <dismukes@adacore.com>
815
816 * exp_ch7.adb, exp_ch6.adb: Minor reformatting.
817
818 2011-09-05 Johannes Kanig <kanig@adacore.com>
819
820 * lib-xref-alfa.adb: Update comments.
821
822 2011-09-05 Thomas Quinot <quinot@adacore.com>
823
824 * sem_res.adb: Minor reformatting
825
826 2011-09-05 Ed Schonberg <schonberg@adacore.com>
827
828 * exp_ch6.adb (Build_In_Place_Formal): If extra formals are not
829 present, create them now. Needed in case the return type was
830 a limited view in the function declaration.
831 (Make_Build_In_Place_Call_In_Allocator): If return type contains
832 tasks, build the activation chain for it. Pass a reference to
833 the Master_Id in call to Add_Task_Actuals_To_Build_In_Place call.
834 * exp_ch7.adb (Make_Set_Finalize_Address_Call): Clean up interface
835 with build_in_place calls.
836 * sem_ch9.adb (Analyze_Task_Type_Declaration): If partial view was
837 incomplete, inatialize its Corresponding_Record_Type component.
838 * sem_ch10.adb (Build_Chain): Initialize Private_Dependents field
839 of limited views.
840
841 2011-09-05 Johannes Kanig <kanig@adacore.com>
842
843 * lib-xref-alfa.adb (Is_Alfa_Reference): Filter constants from effect
844 information.
845
846 2011-09-05 Ed Schonberg <schonberg@adacore.com>
847
848 * par-ch6.adb (P_Subprogram): In Ada2012 mode, if the subprogram
849 appears within a package specification and the token after "IS"
850 is not a parenthesis, assume that this is an unparenthesized
851 expression function, even if the token appears in a line by
852 itself.
853 * par.adb: Clarify use of Labl field of scope stack in error
854 recovery.
855
856 2011-09-05 Bob Duff <duff@adacore.com>
857
858 * sem_res.adb (Resolve_Intrinsic_Operator): Use unchecked
859 conversions instead of normal type conversions in all cases where a
860 type conversion would be illegal. In particular, use unchecked
861 conversions when the operand types are private.
862
863 2011-09-05 Johannes Kanig <kanig@adacore.com>
864
865 * lib-xref-alfa.adb (Is_Alfa_Reference): Never declare effects on
866 objects of task type or protected type.
867
868 2011-09-05 Ed Schonberg <schonberg@adacore.com>
869
870 * sem_ch6.adb (Analyze_Expression_Function): If the expression
871 function comes from source, indicate that so does its rewriting,
872 so it is compatible with any subsequent expansion of the
873 subprogram body (e.g. when it is a protected operation).
874 * sem_ch4.adb: minor reformatting
875
876 2011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
877
878 * lib.adb (Check_Same_Extended_Unit): Comment rewriting. Use
879 Get_Source_Unit rather than Get_Code_Unit as instantiation unfolding
880 may lead to wrong ancestor package in the case of instantiated subunit
881 bodies. If a subunit is instantiated, follow the chain of instantiations
882 rather than the stub structure.
883
884 2011-09-02 Robert Dewar <dewar@adacore.com>
885
886 * sem_ch4.adb, sem_ch6.adb: Minor reformatting.
887 * gcc-interface/Make-lang.in: Update dependencies.
888
889 2011-09-02 Marc Sango <sango@adacore.com>
890
891 * sem_ch3.adb (Analyze_Object_Declaration): Change
892 comment and add additional check to differentiate constant of
893 type string from others unconstrained type.
894
895 2011-09-02 Ed Schonberg <schonberg@adacore.com>
896
897 * sinfo.ads, sinfo.adb: New semantic attribute Premature_Use,
898 present in incomplete type declarations to refine the error
899 message the full declaration is in the same unit.
900 * sem_ch4.adb (Analyze_Selected_Component): If the prefix is of
901 an incomplete type, set the Premature_Use for additional message.
902 * sem_ch3.adb (Find_Type_Name): If partial view is incomplete
903 and Premature_Use is set, place additional information at the
904 point of premature use.
905
906 2011-09-02 Bob Duff <duff@adacore.com>
907
908 * sem_ch6.adb: (Check_Post_State): Suppress warning
909 "postcondition refers only to pre-state" when the expression has not
910 yet been analyzed, because it causes false alarms. This can happen when
911 the postcondition contains a quantified expression, because those are
912 analyzed later. This is a temporary/partial fix.
913 (Process_Post_Conditions): Minor: change wording of warning.
914
915 2011-09-02 Marc Sango <sango@adacore.com>
916
917 * sem_ch3.adb (Analyze_Object_Declaration): Detect the violation of
918 illegal use of unconstrained string type in SPARK mode.
919 * sem_res.adb (Analyze_Operator_Symbol): Set the
920 right place where the string operand of concatenation should be
921 violate in SPARK mode.
922
923 2011-09-02 Robert Dewar <dewar@adacore.com>
924
925 * sem_prag.adb, sem_util.adb, sem_ch6.adb, prj-nmsc.adb,
926 exp_ch3.adb: Minor reformatting.
927
928 2011-09-02 Vincent Celier <celier@adacore.com>
929
930 * prj-conf.adb (Add_Default_GNAT_Naming_Scheme): Declare "gcc"
931 as the compiler driver so Is_Compilable returns True for sources.
932 * prj-nmsc.adb (Override_Kind): When Kind is Sep, set the source
933 for the body.
934
935 2011-09-02 Ed Schonberg <schonberg@adacore.com>
936
937 * sem_prag.adb (Analyze_PPC_In_Decl_Part): for a class-wide
938 condition, a reference to a controlling formal must be interpreted
939 as having the class-wide type (or an access to such) so that the
940 inherited condition can be properly applied to any overriding
941 operation (see ARM12 6.6.1 (7)).
942
943 2011-09-02 Tristan Gingold <gingold@adacore.com>
944
945 * init.c (__gnat_is_vms_v7): Fix case and add prototype
946 for LIB$GETSYI.
947
948 2011-09-02 Javier Miranda <miranda@adacore.com>
949
950 * exp_ch3.adb (Expand_N_Object_Declaration): Do not copy the
951 initializing expression of a class-wide interface object declaration
952 if its type is limited.
953
954 2011-09-02 Johannes Kanig <kanig@adacore.com>
955
956 * sem_util.adb (Unique_Name): To obtain a unique name for enumeration
957 literals, take into account the type name; the type is *not*
958 the scope for an enumeration literal.
959
960 2011-09-02 Ed Schonberg <schonberg@adacore.com>
961
962 * sem_ch6.adb (Check_Overriding_Indicator): add special check
963 to reject an overriding indicator on a user-defined Adjust
964 subprogram for a limited controlled type.
965
966 2011-09-02 Ed Schonberg <schonberg@adacore.com>
967
968 * sem_res.adb (Resolve_Actuals): add missing call to Resolve
969 for an actual that is a function call returning an unconstrained
970 limited controlled type.
971
972 2011-09-02 Tristan Gingold <gingold@adacore.com>
973
974 * g-socthi-vms.adb (c_sendmsg, c_recvmsg): Use unpacked msg if on vms 7
975
976 2011-09-02 Johannes Kanig <kanig@adacore.com>
977
978 * alfa.ads (Name_Of_Heap_Variable): Change value of the HEAP variable
979 from "HEAP" to __HEAP Change comment that refers to that variable
980 * put_alfa.adb: Change comment that refers to that variable
981
982 2011-09-02 Robert Dewar <dewar@adacore.com>
983
984 * exp_ch4.adb, exp_ch6.adb, prj-nmsc.adb: Minor reformatting.
985
986 2011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
987
988 * exp_util.adb (Extract_Renamed_Object): Renamed to
989 Find_Renamed_Object. This routine has been reimplemented and now uses
990 tree traversal to locate a renamed object.
991 (Is_Aliased): Replace call to Extract_Renamed_Object with
992 Find_Renamed_Object.
993
994 2011-09-02 Tristan Gingold <gingold@adacore.com>
995
996 * init.c: (__gnat_is_vms_v7): New function.
997
998 2011-09-02 Olivier Hainque <hainque@adacore.com>
999
1000 * tracebak.c (STOP_FRAME, ppc elf/vxworks case): Stop on frames
1001 that have a misaligned backchain, necessarily bogus.
1002
1003 2011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
1004
1005 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Do not create
1006 TSS routine Finalize_Address when compiling in Alfa mode.
1007 (Expand_Freeze_Record_Type): Do not create TSS routine
1008 Finalize_Address when compiling in Alfa mode.
1009 * exp_ch4.adb (Expand_Allocator_Expression): Do not produce a
1010 call to Set_Finalize_Address in Alfa mode because Finalize_Address is
1011 not built.
1012 (Expand_N_Allocator): Do not produce a call to
1013 Set_Finalize_Address in Alfa mode because Finalize_Address is not built.
1014 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Do not
1015 produce a call to primitive Set_Finalize_Address in Alfa mode because
1016 Finalize_Address is not built.
1017 * exp_ch7.adb (Build_Finalization_Master): Do not create
1018 finalization masters in Afa mode since they are not needed.
1019 (Build_Finalizer): Do not create scope and library-level
1020 finalizers in Alfa mode since they are not needed.
1021 * exp_util.adb (Build_Allocate_Deallocate_Proc): Do not expand
1022 "new" and "free" when applied to controlled objects in Alfa mode since
1023 this is not needed.
1024
1025 2011-09-02 Vincent Celier <celier@adacore.com>
1026
1027 * prj-nmsc.db: (Check_Stand_Alone_Library): For SALs, allow
1028 only library names with the syntax of Ada identifiers, to avoid errors
1029 when compiling the binder generated files.
1030 * projects.texi: Document restriction on SAL library names
1031
1032 2011-09-02 Thomas Quinot <quinot@adacore.com>
1033
1034 * a-chtgbo.adb: Minor comment fix.
1035
1036 2011-09-02 Robert Dewar <dewar@adacore.com>
1037
1038 * lib-xref.adb: Minor reformatting
1039
1040 2011-09-02 Vincent Celier <celier@adacore.com>
1041
1042 * bindusg.adb, clean.adb, gnatchop.adb, gnatfind.adb, gnatlink.adb,
1043 gnatls.adb, gnatname.adb, gnatxref.adb, gprep.adb, makeusg.adb: Add
1044 --version and --help in usage.
1045 * switch.ads, switch.adb (Display_Usage_Version_And_Help): New procedure
1046
1047 2011-09-02 Bob Duff <duff@adacore.com>
1048
1049 * lib-xref.adb: (Hash): Avoid use of 'Mod attribute, because old
1050 compilers don't understand it.
1051
1052 2011-09-02 Gary Dismukes <dismukes@adacore.com>
1053
1054 * exp_attr.adb (Expand_N_Attribute_Reference): Pass the
1055 underlying subtype rather than its base type on the call to
1056 Build_Record_Or_Elementary_Input_Function, so that any
1057 constraints on a discriminated subtype will be available for
1058 doing the check required by AI05-0192.
1059 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
1060 If the prefix subtype of the 'Input attribute is a constrained
1061 discriminated subtype, then check each constrained discriminant value
1062 against the corresponding value read from the stream.
1063
1064 2011-09-02 Yannick Moy <moy@adacore.com>
1065
1066 * usage.adb, warnsw.adb, sem_ch6.adb, opt.ads: Disable by default
1067 warnings on suspicious contracts, and enable them with -gnatwa.
1068
1069 2011-09-02 Robert Dewar <dewar@adacore.com>
1070
1071 * exp_util.adb, exp_ch9.adb, sem_attr.adb, sem_ch6.adb: Minor
1072 reformatting.
1073
1074 2011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
1075
1076 * exp_ch9.adb (Install_Private_Data_Declarations): Add guards
1077 which ensure that restriction No_Dynamic_Attachment has not been
1078 violated.
1079 (Make_Initialize_Protection): Protected types with attach or
1080 interrupt handlers must not violate restriction No_Dynamic_Attachment.
1081 * exp_util.adb (Corresponding_Runtime_Package): Add a guard
1082 which ensures that restriction No_Dynamic_Attachment has not been
1083 violated.
1084 * sem_attr.adb: (Eval_Attribute): Transform
1085 VAX_Float_Type'First and 'Last into references to
1086 the temporaries which store the corresponding bounds. The
1087 transformation is needed since the back end cannot evaluate
1088 'First and 'Last on VAX.
1089 (Is_VAX_Float): New routine.
1090
1091 2011-09-02 Ed Schonberg <schonberg@adacore.com>
1092
1093 * sem_ch12.adb (Analyze_Subprogram_Instantiation): If the
1094 generic unit is not intrinsic and has an explicit convention,
1095 the instance inherits it.
1096
1097 2011-09-02 Robert Dewar <dewar@adacore.com>
1098
1099 * prj-dect.adb, prj-env.adb, prj-nmsc.adb, prj-proc.adb, prj-tree.adb,
1100 prj.adb, prj.ads, sem_ch5.adb: Minor reformatting.
1101
1102 2011-09-02 Thomas Quinot <quinot@adacore.com>
1103
1104 * sem_attr.adb (Analyze_Attribute, case Unrestriced_Access):
1105 Guard against a prefix that is an N_Has_Entity but has no
1106 associated entity.
1107
1108 2011-09-02 Yannick Moy <moy@adacore.com>
1109
1110 * lib-xref-alfa.adb (Is_Alfa_Reference): Ignore IN parameters in Alfa
1111 references.
1112
1113 2011-09-02 Yannick Moy <moy@adacore.com>
1114
1115 * opt.ads (Warn_On_Suspicious_Contract): New warning flag.
1116 * sem_ch3.adb (Analyze_Declarations): Call checker for suspicious
1117 contracts.
1118 * sem_ch6.adb, sem_ch6.ads (Check_Subprogram_Contract): New
1119 procedure looking for suspicious postconditions.
1120 * usage.adb (Usage): New options -gnatw.t and -gnatw.T.
1121 * warnsw.adb (Set_Dot_Warning_Switch): Take into account new
1122 options -gnatw.t and -gnatw.T.
1123
1124 2011-09-02 Pascal Obry <obry@adacore.com>
1125
1126 * prj.adb: Minor code refactoring. Move check for null project in
1127 Project_Changed.
1128 * projects.texi: Fix minor typos.
1129
1130 2011-09-02 Ed Schonberg <schonberg@adacore.com>
1131
1132 * sem_ch5.adb (Analyze_Iterator_Specification): If the domain
1133 of iteration is an expression, its value must be captured in a
1134 renaming declaration, so that modification of the elements is
1135 propagated to the original container.
1136
1137 2011-09-02 Pascal Obry <obry@adacore.com>
1138
1139 * prj-proc.adb, prj.adb, makeutl.adb, makeutl.ads, prj-dect.adb,
1140 prj-nmsc.adb, prj-util.adb, prj-conf.adb, prj-env.adb,
1141 prj-tree.adb: Minor reformatting and style fixes.
1142
1143 2011-09-02 Robert Dewar <dewar@adacore.com>
1144
1145 * s-rident.ads: Add new restriction No_Implicit_Aliasing
1146 * sem_attr.adb: (Analyze_Access_Attribute): Deal with
1147 No_Implicit_Aliasing
1148 (Analyze_Attribute, case Address): ditto
1149 (Analyze_Attribute, case Unrestricted_Access): ditto
1150 * sem_util.ads, sem_util.adb: (Is_Aliased_View): Handle
1151 No_Implicit_Aliasing restriction.
1152 * gnat_rm.texi: Add documentation for No_Implicit_Aliasing
1153
1154 2011-09-02 Ed Schonberg <schonberg@adacore.com>
1155
1156 * exp_util.adb: (Possible_Bit_Aligned_Object): If the object
1157 is an unchecked conversion, apply test to its expression.
1158
1159 2011-09-02 Javier Miranda <miranda@adacore.com>
1160
1161 * sem_ch3.adb (Check_Abstract_Overriding): When
1162 traversing the chain of aliased subprograms avoid reporting a
1163 redundant error on the current entity.
1164
1165 2011-09-02 Sergey Rybin <rybin@adacore.com>
1166
1167 * gnat_ugn.texi: Minor clean up.
1168
1169 2011-09-02 Bob Duff <duff@adacore.com>
1170
1171 * s-htable.adb (Set_If_Not_Present): Use renaming
1172 instead of ":=", because the type Key is limited in the generic (even
1173 if not in the instances).
1174
1175 2011-09-02 Robert Dewar <dewar@adacore.com>
1176
1177 * exp_util.adb, sem_ch10.adb, sem_attr.adb, s-htable.adb,
1178 g-comlin.adb, g-comlin.ads, lib-xref-alfa.adb, lib-xref.adb: Minor
1179 reformatting.
1180
1181 2011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
1182
1183 * sem_ch3.adb: (Set_Anonymous_Type): Associate the itype of an
1184 inherited component with the enclosing derived type. Code reformatting.
1185
1186 2011-09-02 Gary Dismukes <dismukes@adacore.com>
1187
1188 * checks.adb: (Determine_Range): Add test of OK1 to prevent the early
1189 return done when overflow checks are enabled, since comparisons against
1190 Lor and Hir should not be done when OK1 is False.
1191
1192 2011-09-02 Gary Dismukes <dismukes@adacore.com>
1193
1194 * exp_ch6.adb (Add_Finalization_Master_Actual_To_Build_In_Place_Call):
1195 Add new formal Master_Exp. When present, add that expression to the
1196 call as an extra actual.
1197 (Make_Build_In_Place_Call_In_Object_Declaration): Add variable
1198 Fmaster_Actual and in the case of a BIP call initializing a return
1199 object of an enclosing BIP function set it to a
1200 new reference to the implicit finalization master
1201 formal of the enclosing function. Fmaster_Actual is
1202 then passed to the new formal Master_Exp on the call to
1203 Add_Finalization_Master_Actual_To_Build_ In_Place_Call. Move
1204 initializations of Enclosing_Func to its declaration.
1205
1206 2011-09-02 Thomas Quinot <quinot@adacore.com>
1207
1208 * csets.ads: Minor reformatting
1209
1210 2011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
1211
1212 * exp_aggr.adb: (Get_Constraint_Association): Add code to retrieve
1213 the full view of a private type coming from an instantiation.
1214 * exp_ch4.adb: (Current_Anonymous_Master): Reimplement the search
1215 loop to iterate over the declarations rather than use the
1216 First_Entity / Next_Entity scheme.
1217
1218 2011-09-02 Ed Schonberg <schonberg@adacore.com>
1219
1220 * sem_attr.adb: (Analyze_Attribute, case 'Range): when expanding
1221 X'range (N) into X'First (N) .. X'Last (N), do not share the
1222 dimension indicator N, if present. Even though it is a static
1223 constant, its source location may be modified when printing
1224 expanded code under -gnatDL, and node sharing will lead to chaos
1225 in Sprint on large files, by generating a sloc value that does
1226 not correspond to any source file.
1227
1228 2011-09-02 Bob Duff <duff@adacore.com>
1229
1230 * einfo.adb: (Has_Xref_Entry): Do not call
1231 Implementation_Base_Type. Lib.Xref has been
1232 rewritten to avoid the need for it, and it was costly.
1233 * s-htable.ads,s-htable.adb: (Present,Set_If_Not_Present): New
1234 functions in support of efficient xref.
1235 * lib-xref-alfa.adb: Misc changes related to Key component of
1236 type Xref_Entry.
1237 * lib-xref.adb: (Add_Entry,etc): Speed improvement.
1238 (New_Entry): Call Implementation_Base_Type, because Has_Xref_Entry
1239 no longer does. This is the one place where it is needed.
1240
1241 2011-09-02 Johannes Kanig <kanig@adacore.com>
1242
1243 * g-comlin.adb (Getopt): New optional argument Concatenate to have
1244 similar interface as the other Getopt function.
1245
1246 2011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
1247
1248 * exp_ch4.adb: (Expand_Allocator_Expression): Do not generate
1249 a call to Set_Finalize_Address if there is no allocator available.
1250 * exp_util.adb: (Build_Allocate_Deallocate_Proc): Account for
1251 a case of allocator expansion where the allocator is not expanded but
1252 needs a custom allocate routine. Code reformatting.
1253 (Is_Finalizable_Transient): Remove local variables Has_Rens and
1254 Ren_Obj. Code reformatting.
1255 (Is_Renamed): Renamed to Is_Aliased. Add code to detect aliasing
1256 through the use of 'reference.
1257 * sem_ch4.adb: (Analyze_Allocator): Detect allocators generated
1258 as part of build-in-place expansion. They are intentionally marked as
1259 coming from source, but their parents are not.
1260
1261 2011-09-02 Ed Schonberg <schonberg@adacore.com>
1262
1263 * sem_ch10.adb (Analyze_With_Clause): If the library unit
1264 is the generated subprogram declaration for a child unit body
1265 that acts as spec, use the original body in the with_clause,
1266 to prevent binding errors.
1267
1268 2011-09-02 Vincent Celier <celier@adacore.com>
1269
1270 * gnat_ugn.texi: Adapt documentation of -gnateInnn to new VMS
1271 qualifier /MULTI_UNIT_INDEX=
1272
1273 2011-09-02 Johannes Kanig <kanig@adacore.com>
1274
1275 * g-comlin.adb (Getopt): Return when switch is dealt with automatically,
1276 instead of calling the callback function
1277
1278 2011-09-02 Robert Dewar <dewar@adacore.com>
1279
1280 * prj-proc.adb, prj.ads, sem_util.adb, s-taprop-linux.adb,
1281 prj-nmsc.adb, prj-util.ads, prj-env.adb: Minor reformatting.
1282
1283 2011-09-02 Vincent Celier <celier@adacore.com>
1284
1285 * prj-nmsc.adb: (Find_Sources): When the list of sources is
1286 explicitly declared in an extending project, do not warn if a source
1287 for an inherited naming exception is not found.
1288
1289 2011-09-02 Gary Dismukes <dismukes@adacore.com>
1290
1291 * exp_ch6.adb: (Is_Build_In_Place_Function_Call): Return False if
1292 expansion is inactive.
1293
1294 2011-09-02 Ed Schonberg <schonberg@adacore.com>
1295
1296 * sem_util.adb (Note_Possible_Modification): If the entity
1297 being modified is the renaming generated for an Ada2012 iterator
1298 element, the enclosing container or array is modified as well.
1299
1300 2011-09-02 Jose Ruiz <ruiz@adacore.com>
1301
1302 * s-taprop-linux.adb (Initialize_Lock, Initialize_TCB,
1303 Initialize): Define and initialize the
1304 mutex attributes and condition variable attributes locally.
1305
1306 2011-09-02 Vincent Celier <celier@adacore.com>
1307
1308 * prj-nmsc.adb (Check_File): Mark as Locally_Removed a naming
1309 exception replaced in an extending project.
1310 (Check_Object): No error when the other source is locally removed.
1311
1312 2011-09-02 Yannick Moy <moy@adacore.com>
1313
1314 * exp_ch6.adb (Is_Build_In_Place_Function_Call): in Alfa mode, allow
1315 unresolved calls.
1316
1317 2011-08-31 Arnaud Charlet <charlet@adacore.com>
1318
1319 * gcc-interface/Makefile.in: Clean up handling of x86 and x86-64
1320 run-time files.
1321 * gcc-interface/Make-lang.in: Update dependencies.
1322
1323 2011-09-01 Robert Dewar <dewar@adacore.com>
1324
1325 * sem_ch3.adb, s-taprop-linux.adb, gnatls.adb: Minor reformatting.
1326
1327 2011-09-01 Jose Ruiz <ruiz@adacore.com>
1328
1329 * adaint.h (__gnat_cpu_free): Fix the name of this profile.
1330 * adaint.c (__gnat_cpu_alloc, __gnat_cpu_alloc_size, __gnat_cpu_free,
1331 __gnat_cpu_zero, __gnat_cpu_set): Create version of these subprograms
1332 specific for systems where their glibc version does not define the
1333 routines to handle dynamically allocated CPU sets.
1334
1335 2011-09-01 Vincent Celier <celier@adacore.com>
1336
1337 * prj-proc.adb, prj.ads, prj-nmsc.adb, prj-util.adb, prj-util.ads,
1338 prj-env.adb: Implement inheritance of naming exceptions in extending
1339 projects.
1340
1341 2011-09-01 Romain Berrendonner <berrendo@adacore.com>
1342
1343 * gnatls.adb: Display simple message instead of content of
1344 gnatlic.adl.
1345
1346 2011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
1347
1348 * sem_ch3.adb: (Build_Derived_Record_Type) Remove the kludgy update of
1349 access discriminant and anonymous access component scopes.
1350 (Inherit_Component): Reuse the itype of an access discriminant
1351 or anonymous access component by copying it in order to set the proper
1352 scope. This is done only when the parent and the derived type
1353 are in different scopes.
1354 (Set_Anonymous_Etype): New routine.
1355
1356 2011-09-01 Robert Dewar <dewar@adacore.com>
1357
1358 * a-convec.adb: Minor reformatting throughout.
1359
1360 2011-09-01 Jose Ruiz <ruiz@adacore.com>
1361
1362 * adaint.c, adaint.h (__gnat_cpu_alloc, __gnat_cpu_alloc_size,
1363 __gnat_cpu_set_free): Create these wrappers around the CPU_ALLOC,
1364 CPU_ALLOC_SIZE and CPU_FREE linux macros.
1365 (__gnat_cpu_zero, __gnat_cpu_set): Use the CPU_ZERO_S and
1366 CPU_SET_S respectively because we are now using dynamically allocated
1367 CPU sets which are more portable across different glibc versions.
1368 * s-osinte-linux.ads (cpu_set_t_ptr, CPU_ALLOC, CPU_ALLOC_SIZE,
1369 CPU_FREE): Add this type and subprograms to be able to create cpu_set_t
1370 masks dynamically according to the number of processors in the target
1371 platform.
1372 (CPU_ZERO, CPU_SET): They are now mapped to the CPU_ZERO_S and CPU_SET_S
1373 respectively, so we need to pass the size of the masks as
1374 parameters.
1375 * s-taprop-linux.adb (Create_Task, Set_Task_Affinity): Use dynamically
1376 created cpu_set_t masks
1377 with the number of processors available in the target platform,
1378 instead of static bit arrays. It enhances portability because
1379 it uses the information from the target platform.
1380 * sem_ch8.adb: (Attribute_Renaming): When checking whether we
1381 are using a restricted run-time library, use the flag
1382 Configurable_Run_Time_Mode instead of Restricted_Profile.
1383
1384 2011-09-01 Vincent Celier <celier@adacore.com>
1385
1386 * ug_words: Add /MULTI_UNIT_INDEX= -> -gnateI
1387 * vms_data.ads: Add new VMS qualifier equivalent for -gnateInnn
1388
1389 2011-09-01 Nicolas Roche <roche@adacore.com>
1390
1391 * adaint.c (__gnat_tmp_name): Don't use tmpnam function from the system
1392 on VxWorks in kernel mode.
1393
1394 2011-09-01 Jose Ruiz <ruiz@adacore.com>
1395
1396 * s-taprop-linux.adb (Create_Task, Set_Task_Affinity): Use the linux
1397 macros for handling CPU sets (CPU_ZERO, CPU_SET) instead of modifying
1398 directly the bit array.
1399 * s-osinte-linux.ads (CPU_ZERO, CPU_SET): Import these wrappers around
1400 the linux macros with the same name.
1401 * adaint.h, adaint.c (__gnat_cpu_zero, __gnat_cpu_set): Create these
1402 wrappers around the CPU_ZERO and CPU_SET linux macros.
1403
1404 2011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
1405
1406 * exp_ch7.adb (Find_Insertion_List): Removed.
1407 (Process_Transient_Objects): Insert the declarations of the hook
1408 access type and the hook object before the associated transient object.
1409
1410 2011-09-01 Jose Ruiz <ruiz@adacore.com>
1411
1412 * sem_ch8.adb (Attribute_Renaming): Add missing check to avoid loading
1413 package System.Aux_Dec when using restricted run-time libraries which
1414 do not have this package.
1415
1416 2011-09-01 Tristan Gingold <gingold@adacore.com>
1417
1418 * s-vaflop-vms-alpha.adb: Remove pragma optimize, useless.
1419
1420 2011-09-01 Bob Duff <duff@adacore.com>
1421
1422 * sem_attr.adb (Analyze_Access_Attribute): Do not call
1423 Kill_Current_Values for P'Unrestricted_Access, where P is library level
1424
1425 2011-09-01 Thomas Quinot <quinot@adacore.com>
1426
1427 * exp_ch5.adb: Minor reformatting
1428 * gnat_ugn.texi: Fix minor typos.
1429 * gcc-interface/Make-lang.in: Update dependencies.
1430
1431 2011-09-01 Robert Dewar <dewar@adacore.com>
1432
1433 * inline.adb, sem_aggr.adb: Minor reformatting.
1434
1435 2011-09-01 Ed Schonberg <schonberg@adacore.com>
1436
1437 * a-convec.adb: Proper handling of cursors for Ada2012 iterators.
1438
1439 2011-09-01 Robert Dewar <dewar@adacore.com>
1440
1441 * prj-proc.adb, exp_ch6.adb, prj-env.adb: Minor reformatting.
1442
1443 2011-09-01 Bob Duff <duff@adacore.com>
1444
1445 * sem_aggr.adb (Resolve_Aggregate): Need to treat "in instance
1446 body" the same as "in inlined body", because visibility shouldn't
1447 apply there.
1448
1449 2011-09-01 Eric Botcazou <ebotcazou@adacore.com>
1450
1451 * inline.adb (Add_Inlined_Body): Refine previous change.
1452
1453 2011-09-01 Gary Dismukes <dismukes@adacore.com>
1454
1455 * exp_ch6.ads (Needs_BIP_Alloc_Form): New utility function.
1456 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
1457 Test for case where call
1458 initializes an object of a return statement before testing for
1459 a constrained call, to ensure that all such cases get handled
1460 by simply passing on the caller's parameters. Also, in that
1461 case call Needs_BIP_Alloc_Form to determine whether to pass on
1462 the BIP_Alloc_Form parameter of the enclosing function rather
1463 than testing Is_Constrained. Add similar tests for the return
1464 of a BIP call to later processing to ensure consistent handling.
1465 (Needs_BIP_Alloc_Form): New utility function.
1466 * sem_ch6.adb: (Create_Extra_Formals): Replace test for adding
1467 a BIP_Alloc_Form formal with call to new utility function
1468 Needs_BIP_Alloc_Form.
1469
1470 2011-09-01 Pascal Obry <obry@adacore.com>
1471
1472 * prj-part.adb: Minor reformatting.
1473
1474 2011-09-01 Vincent Celier <celier@adacore.com>
1475
1476 * prj-env.adb (Create_Mapping_File.Process): Encode the upper
1477 half character in the unit name.
1478
1479 2011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
1480
1481 * exp_ch4.adb: Minor code and comment reformatting.
1482
1483 2011-09-01 Thomas Quinot <quinot@adacore.com>
1484
1485 * exp_ch6.adb (Expand_Inlined_Call): Remove redundant tests
1486 for Is_Limited_Type and Is_Tagged_Type in condition checking
1487 for by-reference type.
1488 * inline.adb (Add_Inlined_Body): Only exclude init_procs. Other
1489 subprograms may have a completion because of a previous
1490 Inline_Always clause, but the enclosing package must be marked
1491 inlined for the subprogram body to become visible to the backend.
1492
1493 2011-09-01 Thomas Quinot <quinot@adacore.com>
1494
1495 * sem_aux.adb, exp_ch4.adb: Minor reformatting
1496
1497 2011-09-01 Pascal Obry <obry@adacore.com>
1498
1499 * prj-proc.adb, prj.ads, sinput-p.adb: Minor reformatting.
1500
1501 2011-09-01 Ed Schonberg <schonberg@adacore.com>
1502
1503 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Generate references to
1504 the formals of a subprogram stub that acts as a spec.
1505
1506 2011-09-01 Ed Schonberg <schonberg@adacore.com>
1507
1508 * exp_ch6.adb (Expand_Inlined_Call): If an actual is a by_reference
1509 type, declare a renaming for it, not an object declaration.
1510
1511 2011-09-01 Yannick Moy <moy@adacore.com>
1512
1513 * ali-util.adb, ali-util.ads (Read_Withed_ALIs): Add parameter
1514 Ignore_Errors to ignore failures to read ALI files when True.
1515
1516 2011-09-01 Javier Miranda <miranda@adacore.com>
1517
1518 * exp_ch3.adb (Expand_N_Object_Declaration): Handle non-default
1519 constructor calls associated with non-tagged record types.
1520
1521 2011-09-01 Robert Dewar <dewar@adacore.com>
1522
1523 * g-socthi-vms.adb: Minor reformatting.
1524
1525 2011-09-01 Nicolas Roche <roche@adacore.com>
1526
1527 * sysdep.c: Don't use macro functions for stdio functions on VxWorks
1528 in order to avoid impact of imcompatible changes.
1529 * cstreams.c: Likewise
1530 * cio.c: Likewise
1531 * aux-io.c: Likewise
1532
1533 2011-09-01 Yannick Moy <moy@adacore.com>
1534
1535 * lib-writ.adb (Write_With_Lines): Always output complete information
1536 on "with" line in Alfa mode, as this is required by formal verification
1537 back-end.
1538
1539 2011-09-01 Tristan Gingold <gingold@adacore.com>
1540
1541 * g-socthi-vms.adb: Add comments.
1542
1543 2011-09-01 Pascal Obry <obry@adacore.com>
1544
1545 * prj.ads: Minor reformatting.
1546
1547 2011-09-01 Vincent Celier <celier@adacore.com>
1548
1549 * prj-env.adb (Create_Config_Pragmas_File.Check): Put all naming
1550 exceptions in the config pragmas file.
1551
1552 2011-09-01 Tristan Gingold <gingold@adacore.com>
1553
1554 * gnat_ugn.texi: Document GNAT_STACK_SIZE on IVMS.
1555
1556 2011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
1557
1558 * exp_ch7.adb (Find_Insertion_List): New routine.
1559 (Process_Transient_Objects): Add code to handle the abnormal
1560 finalization of a controlled transient associated with a subprogram
1561 call. Since transients are cleaned up right after the associated
1562 context, an exception raised during a subprogram call may bypass the
1563 finalization code.
1564
1565 2011-09-01 Robert Dewar <dewar@adacore.com>
1566
1567 * exp_ch6.adb (Expand_Call): Check actual for aliased parameter is
1568 aliased.
1569
1570 2011-09-01 Robert Dewar <dewar@adacore.com>
1571
1572 * exp_ch4.adb, a-exexda.adb: Minor reformatting.
1573
1574 2011-09-01 Robert Dewar <dewar@adacore.com>
1575
1576 * s-taskin.ads, s-tassta.adb, sem_ch13.adb: Minor reformatting.
1577
1578 2011-09-01 Thomas Quinot <quinot@adacore.com>
1579
1580 * Makefile.rtl: Move s-oscons.o from GNATRTL_TASKING_OBJS to
1581 GNATRTL_NONTASKING_OBJS.
1582
1583 2011-09-01 Robert Dewar <dewar@adacore.com>
1584
1585 * einfo.ads (Is_Aliased): Fix existing documentation and add note on
1586 possibility of this flag being set for formals in Ada 2012 mode.
1587 * par-ch6.adb (P_Formal_Part): Handle aliased for parameters for Ada
1588 2012.
1589 * sem_ch6.adb (Process_Formals): Handle aliased parameters in Ada 2012
1590 mode.
1591 * sinfo.adb (Aliased_Present): Allowed in N_Parameter_Specification for
1592 Ada 2012.
1593 * sinfo.ads (Aliased_Present): Allowed in N_Parameter_Specification for
1594 Ada 2012.
1595
1596 2011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
1597
1598 * exp_ch4.adb (Find_Insertion_Node): New routine. Determines the proper
1599 insertion node in a tree of nested Expression_With_Actions nodes.
1600 (Process_Transient_Object): In the case where a complex if statement
1601 has been converted into nested Expression_With_Actions nodes, the
1602 "hook" object and the associated access type must be inserted before
1603 the top most Expression_With_Actions.
1604
1605 2011-09-01 Robert Dewar <dewar@adacore.com>
1606
1607 * a-cbprqu.adb, a-cbprqu.ads, a-cuprqu.adb, a-cuprqu.ads,
1608 a-cbsyqu.adb, a-cbsyqu.ads: Minor reformatting.
1609
1610 2011-09-01 Ed Schonberg <schonberg@adacore.com>
1611
1612 * sem_attr.adb: Conditionalize aliasing predicates to Ada2012.
1613
1614 2011-09-01 Jose Ruiz <ruiz@adacore.com>
1615
1616 * aspects.ads (Aspect_Id, Aspect_Argument, Aspect_Names): Add the CPU
1617 aspect.
1618 * aspects.adb (Canonical_Aspect): Add entry for the CPU aspect.
1619 * sem_ch13.adb (Analyze_Aspect_Specifications): Analyze the CPU aspect
1620 in a similar way as we do for the Priority or Dispatching_Domain aspect.
1621 * s-mudido-affinity.adb (Dispatching_Domain_Tasks,
1622 Dispatching_Domains_Frozen): Move this local data to package
1623 System.Tasking because with the CPU aspect we need to have access
1624 to this data when creating the task in System.Tasking.Stages.Create_Task
1625 * s-taskin.ads (Dispatching_Domain_Tasks, Dispatching_Domains_Frozen):
1626 Move these variables from the body of
1627 System.Multiprocessors.Dispatching_Domains because with the CPU aspect
1628 we need to have access to this data when creating the task in
1629 System.Tasking.Stages.Create_Task.
1630 * s-taskin.adb (Initialize): Signal the allocation of the environment
1631 task to a CPU, if any, so that we know whether the CPU can be
1632 transferred to a different dispatching domain.
1633 * s-tassta.adb (Create_Task): Check whether the CPU to which this task
1634 is being allocated belongs to the dispatching domain where the task
1635 lives. Signal the allocation of the task to a CPU, if any, so that we
1636 know whether the CPU can be transferred to a different dispatching
1637 domain.
1638
1639 2011-09-01 Ed Schonberg <schonberg@adacore.com>
1640
1641 * exp_attr.adb, sem_attr.adb, snames.ads-tmpl: Implementation of
1642 attributes Same_Storage and Overlaps_Storage.
1643
1644 2011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
1645
1646 * exp_strm.adb: Remove with and use clause for Opt.
1647 (Build_Array_Input_Function): Remove the version-dependent generation
1648 of the return statement. The Ada 2005 tree is now the default.
1649
1650 2011-09-01 Yannick Moy <moy@adacore.com>
1651
1652 * put_alfa.adb: Unconditionnally write files in Alfa section, so that
1653 it is never empty when compiling in Alfa mode.
1654
1655 2011-09-01 Robert Dewar <dewar@adacore.com>
1656
1657 * sem_aggr.adb, sem_ch3.adb, a-direct.adb, s-taprop-vxworks.adb,
1658 comperr.adb, exp_ch9.adb, exp_pakd.adb, sem_ch12.adb, freeze.adb,
1659 s-taprop-mingw.adb, s-taprop-linux.adb, s-taprop-solaris.adb,
1660 gnat1drv.adb, a-rbtgbo.adb, exp_dist.adb: Minor reformatting
1661
1662 2011-09-01 Matthew Heaney <heaney@adacore.com>
1663
1664 * Makefile.rtl, impunit.adb: Add a-csquin.ads, a-cusyqu.ad[sb],
1665 a-cuprqu.ad[sb], a-cbsyqu.ad[sb], a-cbprqu.ad[sb]
1666 * a-csquin.ads: New Ada 2012 unit that specifies the queue interface
1667 * a-cusyqu.ads, a-cusyqu.adb: New Ada 2012 unit that specifies the
1668 unbounded queue container.
1669 * a-cbsyqu.ads, a-cbsyqu.adb: New Ada 2012 unit that specifies the
1670 bounded queue container.
1671 * a-cuprqu.ads, a-cuprqu.adb: New Ada 2012 unit that specifies the
1672 unbounded priority queue container.
1673 * a-cbprqu.ads, a-cbprqu.adb: New Ada 2012 unit that specifies the
1674 bounded priority queue container.
1675
1676 2011-08-31 Pascal Obry <obry@adacore.com>
1677
1678 * a-direct.adb: Do not try to create an UNC path on Windows.
1679 (Create_Path): Skip leading computer name in UNC path if any.
1680
1681 2011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
1682
1683 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function): Remove the
1684 version-dependent generation of the return statement. The Ada 2005 tree
1685 is now the default.
1686
1687 2011-08-31 Thomas Quinot <quinot@adacore.com>
1688
1689 * rtsfind.ads, exp_dist.adb (Find_Numeric_Representation): Predefined
1690 types Stream_Element_Offset and Storage_Offset have a different native
1691 type depending on whether the platform is 32 or 64 bits. When
1692 exchanging them, always convert to 64 bits.
1693
1694 2011-08-31 Yannick Moy <moy@adacore.com>
1695
1696 * debug.adb: Reserve debug option -gnatd.E for passing gnatprove option
1697 --force-alfa to gnat2why.
1698
1699 2011-08-31 Ed Schonberg <schonberg@adacore.com>
1700
1701 * sem_ch12.adb (Save_References): If the node has aspects, save
1702 references within the corresponding expressions in a separate step,
1703 because the aspects are not directly in the tree for the declaration
1704 to which they belong.
1705
1706 2011-08-31 Arnaud Charlet <charlet@adacore.com>
1707
1708 * freeze.adb (Freeze_Record_Type): Omit test on variable size component
1709 in CodePeer mode, since representation clauses are partially ignored.
1710 * gcc-interface/Make-lang.in: Update dependencies.
1711
1712 2011-08-31 Jose Ruiz <ruiz@adacore.com>
1713
1714 * s-taprop-vxworks.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
1715 s-taprop-solaris.adb (Create_Task): Not_A_Specific_CPU can be assigned
1716 to any dispatching domain.
1717
1718 2011-08-31 Thomas Quinot <quinot@adacore.com>
1719
1720 * exp_ch4.adb: Minor reformatting.
1721
1722 2011-08-31 Bob Duff <duff@adacore.com>
1723
1724 * sem_ch6.adb (Get_Generic_Parent_Type): Don't query Subtype_Indication
1725 on nodes for which it is not defined.
1726 (Is_Non_Overriding_Operation): Exit the loop when we find a generic
1727 parent type.
1728
1729 2011-08-31 Bob Duff <duff@adacore.com>
1730
1731 * sem_ch3.adb (Process_Full_View): Disable legality check if
1732 In_Instance, to avoid spurious errors.
1733 * sem_ch12.adb (Validate_Derived_Type_Instance): Disable legality check
1734 if In_Instance, to avoid spurious errors.
1735
1736 2011-08-31 Pascal Obry <obry@adacore.com>
1737
1738 * a-direct.adb: Use Dir_Seps everywhere to properly handle all
1739 directory speparators.
1740 (Compose): Use Dir_Seps to handle both forms.
1741 (Create_Path): Use Dir_Seps instead of explicit check, no semantic
1742 changes.
1743 (Extension): Use Dir_Seps to handle both forms.
1744
1745 2011-08-31 Pascal Obry <obry@adacore.com>
1746
1747 * prj-conf.adb: Minor reformatting.
1748
1749 2011-08-31 Jose Ruiz <ruiz@adacore.com>
1750
1751 * aspects.ads (Aspect_Id, Aspect_Argument, Aspect_Names): Add the
1752 dispatching domain aspect.
1753 * aspects.adb (Canonical_Aspect): Add entry for the dispatching domain
1754 aspect.
1755 * sem_ch13.adb (Analyze_Aspect_Specifications): Analyze the
1756 Dispatching_Domain aspect in a similar way as we do for the Priority
1757 aspect.
1758 * exp_ch9.adb (Expand_N_Task_Type_Declaration): Add the
1759 Dispatching_Domain component if a Dispatching_Domain pragma or aspect
1760 is present.
1761 (Make_Task_Create_Call): Add the Dispatching_Domain when creating a task
1762 * par-prag.adb (Prag): Add Pragma_Dispatching_Domain as a known pragma.
1763 * sem_prag.adb (Analyze_Pragma): Check the correctness of a pragma
1764 Dispatching_Domain and add it to the task definition.
1765 (Sig_Flags): Add Pragma_Dispatching_Domain.
1766 * rtsfind.ads, rtsfind.adb (RTU_Id, RE_Id, Get_Unit_Name): Add the
1767 support to find the types Dispatching_Domain and
1768 Dispatching_Domain_Access.
1769 * sinfo.ads, sinfo.adb (Has_Pragma_Dispatching_Domain,
1770 Set_Has_Pragma_Dispatching_Domain): Add these subprograms to set and
1771 query the availability of a pragma Dispatching_Domain.
1772 * snames.ads-tmpl (Name_uDispatching_Domain): Add this name required by
1773 the expander to pass the Dispatching_Domain when creating a task.
1774 (Name_Dispatching_Domain): Add this new name for a pragma.
1775 (Pragma_Id): Add the new Pragma_Dispatching_Domain.
1776 * s-tassta.ads, s-tassta.adb (Create_Task): Set the domain to which the
1777 task has been allocated at creation time.
1778 * s-tarest.adb (Create_Restricted_Task): The dispatching domain using
1779 Ravenscar is always null.
1780 * s-taskin.ads, s-taskin.adb (Initialize_ATCB): Set the domain to which
1781 the task has been allocated at creation time.
1782 * s-tporft.adb (Register_Foreign_Thread): A foreign task will not have
1783 a specific dispatching domain.
1784 * s-taprop-linux.adb, s-taprop-solaris.adb, s-taprop-vxworks.adb,
1785 s-taprop-mingw.adb (Create_Task): Check whether both Dispatching_Domain
1786 and CPU are specified for the task, and the CPU value is not contained
1787 within the range of processors for the domain.
1788
1789 2011-08-31 Vincent Celier <celier@adacore.com>
1790
1791 * make.adb (Original_Gcc) : New constant String_Access.
1792 (Gnatmake): For VM targets, do not use VM version of the compiler if
1793 --GCC= has been specified.
1794
1795 2011-08-31 Thomas Quinot <quinot@adacore.com>
1796
1797 * sem_ch5.adb: Minor reformatting.
1798
1799 2011-08-31 Ed Schonberg <schonberg@adacore.com>
1800
1801 * exp_pakd.adb (Convert_To_PAT_Type): If prefix is a function call, do
1802 not reanalyze it.
1803
1804 2011-08-31 Bob Duff <duff@adacore.com>
1805
1806 * exp_ch4.adb (Expand_N_Selected_Component): Use the full type, in case
1807 the access type is private; we don't care about privacy in expansion.
1808
1809 2011-08-31 Ed Schonberg <schonberg@adacore.com>
1810
1811 * sem_aggr.adb (Resolve_Aggregate): In an instance, ignore aggregate
1812 subcomponents tnat may be limited, because they originate in view
1813 conflicts. If the original aggregate is legal and the actuals are
1814 legal, the aggregate itself is legal.
1815
1816 2011-08-31 Matthew Heaney <heaney@adacore.com>
1817
1818 * a-rbtgbo.adb (Clear_Tree): Assert representation invariant for lock
1819 status.
1820
1821 2011-08-31 Ed Schonberg <schonberg@adacore.com>
1822
1823 * sem_ch5.adb: Set kind of loop parameter properly, to preserve all
1824 errors in B tests.
1825
1826 2011-08-31 Jose Ruiz <ruiz@adacore.com>
1827
1828 * sem_ch13.adb (Analyze_Aspect_Specifications): For the Priority and
1829 Interrupt_Priority aspects, force the analysis of the aspect expression
1830 (when building the equivalent pragma). Otherwise, its analysis is done
1831 too late, after the task or protected object has been created.
1832 * sem_ch9.adb (Analyze_Single_Protected_Declaration,
1833 Analyze_Single_Task_Declaration): Remove the code to move the aspects
1834 to the object declaration because they are needed in the type
1835 declaration.
1836
1837 2011-08-31 Robert Dewar <dewar@adacore.com>
1838
1839 * exp_ch5.adb, exp_ch7.ads, sem_ch5.adb, put_scos.adb, s-rannum.adb,
1840 a-rbtgbo.adb, exp_intr.adb, a-cbdlli.adb, a-cbdlli.ads: Minor
1841 reformatting.
1842
1843 2011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
1844
1845 * exp_util.adb (Find_Protection_Type): Do not look for fields _object
1846 if the corresponding type is malformed due to restriction violations.
1847
1848 2011-08-31 Robert Dewar <dewar@adacore.com>
1849
1850 * s-ransee.ads, s-ransee.adb: Minor reformatting.
1851
1852 2011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
1853
1854 * exp_ch4.adb (Expand_N_Allocator): Correct faulty condition which
1855 would cause the generation of Set_Finalize_Address if the target is a
1856 VM and the designated type is not derived from [Limited_]Controlled.
1857
1858 2011-08-31 Arnaud Charlet <charlet@adacore.com>
1859
1860 * comperr.adb, comperr.ads, gnat1drv.adb (Delete_SCIL_Files): New
1861 subprogram.
1862 (Compiler_Abort, Gnat1drv): Call Delete_SCIL_Files in codepeer mode in
1863 case of a compilation error.
1864
1865 2011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
1866
1867 * init.c (__gnat_error_handler): Standardize the stack overflow or
1868 erroneous memory access message.
1869 * seh_init.c (__gnat_SEH_error_handler): Standardize the stack overflow
1870 or erroneous memory access message.
1871
1872 2011-08-31 Robert Dewar <dewar@adacore.com>
1873
1874 * sem_ch4.adb: Minor reformatting.
1875 * sem_ch6.adb: Minor code reorganization (use Ekind_In).
1876
1877 2011-08-31 Thomas Quinot <quinot@adacore.com>
1878
1879 * scos.ads: Minor documentation clarification.
1880 * put_scos.adb: Do not generate SCO unit header line for a unit that
1881 has no SCO lines.
1882
1883 2011-08-31 Robert Dewar <dewar@adacore.com>
1884
1885 * a-rbtgbo.adb, alfa_test.adb: Minor reformatting.
1886
1887 2011-08-31 Tristan Gingold <gingold@adacore.com>
1888
1889 * exp_ch7.ads, exp_ch7.adb (Finalization_Exception_Data): New type to
1890 hold variables between these following subprograms.
1891 (Build_Exception_Handler, Build_Object_Declarations,
1892 Build_Raise_Statement): Use the above type as parameter.
1893 Make the above adjustments.
1894 * exp_intr.adb (Expand_Unc_Deallocation): Adjust.
1895
1896 2011-08-31 Pascal Obry <obry@adacore.com>
1897
1898 * projects.texi: Minor reformatting.
1899
1900 2011-08-31 Tristan Gingold <gingold@adacore.com>
1901
1902 * s-ransee.ads, s-ransee.adb: Add system.random_seed unit.
1903 * s-rannum.adb (Reset): Use Get_Seed from s-ransee.
1904
1905 2011-08-31 Ed Schonberg <schonberg@adacore.com>
1906
1907 * exp_ch5.adb: Minor code cleanup.
1908 * sem_ch5.adb (Analyze_Iteration_Scheme): Set ekind of loop variable to
1909 prevent cascaded errors.
1910 (Analyze_Loop_Statement): In semantics-only mode, introduce loop
1911 variable of an iterator specification in current scope.
1912 * sem_ch6.adb (Analyze_Return_Statement, Find_what_It_Apples_To): Skip
1913 postconditions on the stack, as they contain no return statements.
1914
1915 2011-08-31 Yannick Moy <moy@adacore.com>
1916
1917 * exp_alfa.adb (Expand_Alfa_N_Package_Declaration,
1918 Expand_Alfa_N_Subprogram_Body): Remove useless procedures which simply
1919 call Qualify_Entity_Names.
1920 (Expand_Alfa): call Qualify_Entity_Names in more cases
1921 * lib-xref-alfa.adb: Take into account system package.
1922 * sem_prag.adb Take into account restrictions in Alfa mode, contrary to
1923 CodePeer mode in which we are interested in finding bugs even if
1924 compiler cannot compile source.
1925 * sem_util.adb, sem_util.ads (Unique_Entity): Take into account case of
1926 deferred constant.
1927
1928 2011-08-31 Gary Dismukes <dismukes@adacore.com>
1929
1930 * sem_ch3.adb (Constrain_Concurrent): Retrieve Base_Type of the subtype
1931 denoted by the subtype mark to ensure getting the concurrent type in
1932 the case where the subtype mark denotes a private subtype of a
1933 concurrent type (needed when using -gnatc).
1934 (Process_Subtype): For the processing specific to type kinds, case on
1935 the Base_Type kind of the Subtype_Mark_Id, to handle cases where the
1936 subtype denotes a private subtype whose base type is nonprivate (needed
1937 for subtypes of private fulfilled by task types when compiling with
1938 -gnatc).
1939
1940 2011-08-31 Gary Dismukes <dismukes@adacore.com>
1941
1942 * sem_disp.adb (Check_Dispatching_Operation): Bypass registration of
1943 late primitives that override interface operations when the full
1944 expander is not active, to avoid blowups in Register_Primitive when
1945 types don't have associated secondary dispatch tables.
1946
1947 2011-08-31 Yannick Moy <moy@adacore.com>
1948
1949 * alfa_test.adb: Code clean up.
1950
1951 2011-08-31 Marc Sango <sango@adacore.com>
1952
1953 * restrict.adb (Check_SPARK_Restriction): Change Comes_From_Source (N)
1954 by Comes_From_Source (Original_Node (N)) in order to treat also the
1955 nodes which have been rewritten.
1956 * sem_ch4.adb (Analyze_Explicit_Dereference, Analyze_Slice): Guard the
1957 explicit dereference and slice violation in spark mode on the nodes
1958 coming only from the source code.
1959
1960 2011-08-31 Robert Dewar <dewar@adacore.com>
1961
1962 * exp_ch5.adb, exp_alfa.ads, prj.ads, sem_attr.adb,
1963 lib-xref-alfa.adb: Minor reformatting.
1964
1965 2011-08-31 Matthew Heaney <heaney@adacore.com>
1966
1967 * a-crbltr.ads (Tree_Type): Default-initialize the Nodes component.
1968
1969 2011-08-31 Javier Miranda <miranda@adacore.com>
1970
1971 * sem_ch4.adb (Try_Object_Operation): Addition of one formal to search
1972 only for class-wide subprograms conflicting with entities of concurrent
1973 tagged types.
1974
1975 2011-08-31 Matthew Heaney <heaney@adacore.com>
1976
1977 * a-rbtgbo.adb (Generic_Allocate): Initialize pointer components of
1978 node to null value.
1979
1980 2011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
1981
1982 * sem_ch12.adb (Insert_Freeze_Node_For_Instance): Provide a more
1983 general description of the routine.
1984
1985 2011-08-31 Ed Schonberg <schonberg@adacore.com>
1986
1987 * a-cbdlli.adb, a-cbdlli.ads: Add iterator machinery to bounded
1988 doubly-linked lists.
1989
1990 2011-08-31 Gary Dismukes <dismukes@adacore.com>
1991
1992 * exp_ch5.adb (Expand_N_Assignment_Statement): When a discriminant
1993 check is needed for a left-hand side that is a dereference, and the
1994 base type is private without discriminants (whereas the full type does
1995 have discriminants), an extra retrieval of the underlying type may be
1996 needed in the case where the subtype is a record subtype whose base
1997 type is private. Update comments.
1998
1999 2011-08-31 Javier Miranda <miranda@adacore.com>
2000
2001 * sem_ch4.adb (Try_Object_Operation): When a dispatching primitive is
2002 found check if there is a class-wide subprogram covering the primitive.
2003
2004 2011-08-31 Yannick Moy <moy@adacore.com>
2005
2006 * sem_res.adb: Further cases where full expansion test is needed,
2007 rather than expansion test.
2008
2009 2011-08-31 Pascal Obry <obry@adacore.com>
2010
2011 * prj-attr.adb: Fix Source_File_Switches attribute kind (must be a list)
2012
2013 2011-08-31 Ed Schonberg <schonberg@adacore.com>
2014
2015 * exp_ch5.adb: Handle iterators over derived container types.
2016
2017 2011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
2018
2019 * einfo.ads, einfo.adb: Add new flag Has_Anonymous_Master.
2020 (Has_Anonymous_Master): New routine.
2021 (Set_Has_Anonymous_Master): New routine.
2022 (Write_Entity_Flags): Add an entry for Has_Anonymous_Master.
2023 * exp_ch4.adb: Add with and use clause for Sem_Ch8.
2024 (Current_Anonymous_Master): New routine.
2025 (Current_Unit_First_Declaration): Removed.
2026 (Current_Unit_Scope): Removed.
2027 (Expand_N_Allocator): Anonymous access-to-controlled types now chain
2028 their objects on a per-unit heterogeneous finalization master.
2029
2030 2011-08-31 Matthew Heaney <heaney@adacore.com>
2031
2032 * a-cbhama.adb, a-cbhase.adb (Insert): Check for zero-length buckets
2033 array.
2034
2035 2011-08-31 Jose Ruiz <ruiz@adacore.com>
2036
2037 * s-taprop-linux.adb (Create_Task): Avoid changing the affinity mask
2038 when not needed.
2039
2040 2011-08-31 Gary Dismukes <dismukes@adacore.com>
2041
2042 * sem_disp.adb (Propagate_Tag): Return without propagating in the case
2043 where the actual is an unexpanded call to 'Input.
2044
2045 2011-08-31 Yannick Moy <moy@adacore.com>
2046
2047 * sem_ch4.adb: Code clean up.
2048
2049 2011-08-31 Yannick Moy <moy@adacore.com>
2050
2051 * exp_alfa.adb, exp_alfa.ads: Minor correction of copyright notice.
2052
2053 2011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
2054
2055 * exp_ch7.adb (Build_Array_Deep_Procs): Do not generate Deep_Finalize
2056 and TSS primitive Finalize_Address if finalization is suppressed.
2057 (Build_Record_Deep_Procs): Do not generate Deep_Finalize and TSS
2058 primitive Finalize_Address if finalization is suppressed.
2059
2060 2011-08-31 Jose Ruiz <ruiz@adacore.com>
2061
2062 * s-mudido-affinity.adb, s-taprop-linux.adb, s-taprop-mingw.adb,
2063 s-taprop-solaris.adb, s-taprop-vxworks.adb (Set_Task_Affinity): Make
2064 sure that the underlying task has already been created before trying
2065 to change its affinity.
2066 (Set_CPU): Use the term processor instead of CPU, as we do in
2067 Assign_Task.
2068
2069 2011-08-31 Vincent Celier <celier@adacore.com>
2070
2071 * prj-attr.adb: New Compiler attribute Source_File_Switches.
2072 * prj-nmsc.adb (Process_Compiler): Process attribute
2073 Source_File_Switches.
2074 * prj.ads (Language_Config): New name list component
2075 Name_Source_File_Switches.
2076 * snames.ads-tmpl (Name_Source_File_Switches): New standard name.
2077
2078 2011-08-31 Ed Schonberg <schonberg@adacore.com>
2079
2080 * sem_attr.adb (Analyze_Attribute, case 'Old): If prefix may be a
2081 discriminated component of an actual, expand at once to prevent
2082 ouf-of-order references with generated subtypes.
2083
2084 2011-08-31 Yannick Moy <moy@adacore.com>
2085
2086 * lib-xref-alfa.adb (Add_Alfa_Xrefs): Do not take into account read
2087 reference to operator in Alfa xrefs.
2088
2089 2011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
2090
2091 * sem_ch12.adb (Freeze_Subprogram_Body): Add code to handle the case
2092 where the parent instance was frozen before the current instance due to
2093 the presence of a source body. Update calls to Insert_After_Last_Decl.
2094 (Insert_After_Last_Decl): Renamed to Insert_Freeze_Node_For_Instance.
2095 Update the comment which illustrates the purpose of the routine.
2096 Package instances are now frozen by source bodies which appear after
2097 the instance. This ensures that entities coming from within the
2098 instance are available for use in the said bodies.
2099 (Install_Body): Add code to handle the case where the parent instance
2100 was frozen before the current instance due to the presence of a source
2101 body. Update calls to Insert_After_Last_Decl.
2102
2103 2011-08-31 Jose Ruiz <ruiz@adacore.com>
2104
2105 * s-taprop-linux.adb (Set_Task_Affinity): Avoid the use of anonymous
2106 access types.
2107 * affinity.c (__gnat_set_affinity_mask): Declare index variable.
2108
2109 2011-08-31 Yannick Moy <moy@adacore.com>
2110
2111 * sem_ch8.adb (Analyze_Subprogram_Renaming): Refine expander test in
2112 full-expander test.
2113 * alfa.adb, alfa.ads, alfa_test.adb, ali.adb, debug.adb, errout.adb,
2114 errout.ads, erroutc.adb, expander.adb, exp_ch4.adb, exp_ch7.adb,
2115 freeze.adb, get_alfa.adb, get_alfa.ads, gnat1drv.adb, lib-writ.adb,
2116 lib-writ.ads, lib-xref.adb, lib-xref.ads, lib-xref-alfa.adb, opt.adb,
2117 opt.ads, put_alfa.adb, put_alfa.ads, restrict.adb, sem_ch12.adb,
2118 sem_ch13.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
2119 sem_prag.adb, sem_res.adb, sem_util.adb: Minor reformatting, renaming
2120 ALFA in Alfa (we dropped acronym).
2121 * einfo.adb (Primitive_Operations): Correctly return list of primitive
2122 operations in a case where it returned previously No_Elist.
2123
2124 2011-08-31 Robert Dewar <dewar@adacore.com>
2125
2126 * s-taprop-vxworks.adb, sem_ch5.adb, s-taprop-tru64.adb, exp_alfa.adb,
2127 s-taprop-vms.adb, bindgen.adb, s-mudido.adb, s-mudido.ads,
2128 sem_res.adb, expander.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
2129 s-taprop-solaris.adb, s-mudido-affinity.adb, vms_conv.adb,
2130 s-taprop-irix.adb, s-taprop.ads, s-taskin.adb, s-taskin.ads,
2131 s-taprop-hpux-dce.adb, a-chtgbo.adb, s-taprop-posix.adb: Minor
2132 reformatting.
2133
2134 2011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
2135
2136 * sem_ch12 (Check_Private_View): Revert previous change.
2137 * sem_res.adb (Conversion_Check): Do not emit the error message if the
2138 conversion is in a generic instance.
2139
2140 2011-08-31 Matthew Heaney <heaney@adacore.com>
2141
2142 * a-cbhase.adb (Symmetric_Difference): Dereference correct node array.
2143 * a-chtgbo.adb (Free): Allow 0 as index value.
2144
2145 2011-08-31 Matthew Heaney <heaney@adacore.com>
2146
2147 * a-cborma.adb (Insert): Add comment to explain why no element
2148 assignment.
2149
2150 2011-08-31 Gary Dismukes <dismukes@adacore.com>
2151
2152 * sem_util.adb (Find_Body_Discriminal): Test whether the scope of the
2153 spec discriminant is already a concurrent type, in which case just use
2154 it, otherwise fetch the Corresponding_Concurrent_Type as before.
2155
2156 2011-08-30 Eric Botcazou <ebotcazou@adacore.com>
2157
2158 * system-irix-n64.ads, system-linux-armeb.ads, system-linux-armel.ads,
2159 system-linux-mips.ads, system-linux-mipsel.ads,
2160 system-linux-mips64el.ads, system-linux-ppc64.ads,
2161 system-linux-sparcv9.ads, system-rtems.ads: Remove GCC_ZCX_Support.
2162
2163 2011-08-30 Eric Botcazou <ebotcazou@adacore.com>
2164
2165 * gcc-interface/ada-tree.h (TYPE_EXTRA_SUBTYPE_P): Add internal check.
2166 * gcc-interface/utils2.c (build_binary_op): Tighten condition.
2167 (build_unary_op): Likewise.
2168
2169 2011-08-30 Eric Botcazou <ebotcazou@adacore.com>
2170
2171 * raise-gcc.c: Do not include coretypes.h and tm.h.
2172 (setup_to_install): Remove test for compiler macro.
2173 * targext.c: Document use for the library.
2174 * gcc-interface/Makefile.in: Fix comment on the use of IN_GCC.
2175
2176 2011-08-30 Eric Botcazou <ebotcazou@adacore.com>
2177
2178 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Do not convert
2179 the expression to the nominal type if the latter is a record type with
2180 a variant part and the type of the former is a record type without one.
2181
2182 2011-08-30 Yannick Moy <moy@adacore.com>
2183
2184 * exp_aggr.adb, exp_ch11.adb, exp_prag.adb: Remove early exit during
2185 expansion in Alfa mode.
2186 * exp_ch6.adb, exp_ch6.ads (Expand_Actuals): Make subprogram public
2187 * exp_alfa.adb, exp_alfa.ads: New package defining light expansion for
2188 Alfa mode.
2189 * gnat1drv.adb (Adjust_Global_Switches): Update Comment.
2190 * sem_res.adb: Ditto.
2191 * gcc-interface/Make-lang.in: Update dependencies.
2192
2193 2011-08-30 Thomas Quinot <quinot@adacore.com>
2194
2195 * g-socket.ads: Minor documentation adjustment.
2196
2197 2011-08-30 Robert Dewar <dewar@adacore.com>
2198
2199 * exp_ch9.adb, s-tassta.adb, s-secsta.adb: Minor reformatting.
2200
2201 2011-08-30 Yannick Moy <moy@adacore.com>
2202
2203 * exp_ch6_light.adb, exp_ch6_light.ads, exp_attr_light.adb,
2204 exp_attr_light.ads, exp_ch7_light.adb, exp_ch7_light.ads,
2205 exp_light.adb, exp_light.ads, exp_prag.adb, expander.adb,
2206 gnat1drv.adb, exp_ch11.adb, exp_ch6.adb, exp_ch6.ads, exp_aggr.adb:
2207 Revert change which introduced files for "light"
2208 expansion, to be replaced by a single file for Alfa expansion.
2209
2210 2011-08-30 Robert Dewar <dewar@adacore.com>
2211
2212 * opt.ads, s-soflin.adb, exp_ch9.adb, sem_res.adb: Update comment.
2213 Minor code reorg/reformatting.
2214
2215 2011-08-30 Yannick Moy <moy@adacore.com>
2216
2217 * opt.adb, opt.ads (Full_Expander_Active): New function defines a
2218 common shorthand for (Expander_Active and not ALFA_Mode) that can be
2219 used for testing full expansion, that is active expansion not in the
2220 reduced mode for Alfa
2221 * exp_ch4.adb, exp_ch9.adb, exp_disp.adb, sem_ch10.adb, sem_ch12.adb,
2222 sem_ch6.adb, sem_ch9.adb, sem_res.adb: Use newly defined "flag" instead
2223 of the verbose (Expander_Active and not ALFA_Mode)
2224
2225 2011-08-30 Tristan Gingold <gingold@adacore.com>
2226
2227 * s-parame-vms-alpha.ads, s-parame-hpux.ads, s-tassta.adb,
2228 s-tarest.adb, s-parame-vms-ia64.ads, s-soflin.adb, s-secsta.adb,
2229 s-secsta.ads, s-parame.ads, s-parame-vxworks.ads, s-parame-ae653.ads:
2230 Renames Ratio to Percentage, and Sec_Stack_Ratio to Sec_Stack_Percentage
2231
2232 2011-08-30 Gary Dismukes <dismukes@adacore.com>
2233
2234 * sem_res.adb (Valid_Conversion): Revise test for implicit anonymous
2235 access conversions to check that the conversion is a rewritten node,
2236 rather than just having Comes_From_Source set to False, which wasn't
2237 sufficient.
2238
2239 2011-08-30 Robert Dewar <dewar@adacore.com>
2240
2241 * exp_ch9.adb, sem_ch9.adb, sem_ch6.adb, exp_disp.adb,
2242 g-socket.ads: Minor reformatting.
2243
2244 2011-08-30 Thomas Quinot <quinot@adacore.com>
2245
2246 * sem_util.adb: Minor reformatting.
2247
2248 2011-08-30 Tristan Gingold <gingold@adacore.com>
2249
2250 * raise-gcc.c: Never catch exception if _UA_FORCE_UNWIND flag is set,
2251 to be compliant with the ABI.
2252
2253 2011-08-30 Hristian Kirtchev <kirtchev@adacore.com>
2254
2255 * sem_ch12.adb (Check_Private_View): Exchange the private and full view
2256 of a designated type when the related access type is an actual in an
2257 instance. This ensures that the full view of designated type is
2258 available when inside the body of the instance.
2259
2260 2011-08-30 Ed Schonberg <schonberg@adacore.com>
2261
2262 * sem_util.adb (May_Be_Lvalue): To determine whether a reference may be
2263 in a position to be modified, a slice is treated like an indexed
2264 component.
2265
2266 2011-08-30 Thomas Quinot <quinot@adacore.com>
2267
2268 * s-oscons-tmplt.c, g-socket.ads: Adjust maximum allowed value for
2269 field tv_sec in struct timeval.
2270
2271 2011-08-30 Yannick Moy <moy@adacore.com>
2272
2273 * exp_ch9.adb, exp_disp.adb, sem_ch9.adb, sem_res.adb: Protect several
2274 blocks of code doing full expansion, previously only guarded by
2275 Expander_Active, by anding the test that ALFA_Mode is not set
2276
2277 2011-08-30 Ed Schonberg <schonberg@adacore.com>
2278
2279 * sem_ch6.adb (Analyze_Return_Type): If the return type is incomplete,
2280 add the function to the list of private dependents, for subsequent
2281 legality check on Taft amendment types.
2282 * sem_ch12.adb (Analyze_Formal_Incomplete_Type): Initialize
2283 Private_Dependents, as for other incomplete types.
2284 * sem_util.adb (Wrong_Type): Avoid cascaded errors when a
2285 Taft-amendment type is used as the return type of a function.
2286
2287 2011-08-30 Javier Miranda <miranda@adacore.com>
2288
2289 * sem_ch3.adb (Check_Abstract_Overriding): Code cleanup: replace code
2290 which emits an error by a call to a new routine which report the error.
2291 * exp_ch9.adb (Build_Wrapper_Spec): Build the wrapper even if the
2292 entity does not cover an existing interface.
2293 * errout.ads, errout.adb (Error_Msg_PT): New routine. Used to factorize
2294 code.
2295 * sem_ch6.adb (Check_Conformance): Add specific error for wrappers of
2296 protected procedures or entries whose mode is not conformant.
2297 (Check_Synchronized_Overriding): Code cleanup: replace code which emits
2298 an error by a call to a new routine which report the error.
2299
2300 2011-08-30 Robert Dewar <dewar@adacore.com>
2301
2302 * gnat_rm.texi: Minor change.
2303 * exp_attr_light.adb: Minor reformatting.
2304
2305 2011-08-30 Ed Schonberg <schonberg@adacore.com>
2306
2307 * sem_ch3.adb: Patch inheritance of aspects in
2308 Complete_Private_Subtype, to avoid infinite loop.
2309
2310 2011-08-30 Javier Miranda <miranda@adacore.com>
2311
2312 * sem_ch3.adb (Add_Internal_Interface_Entities): If serious errors have
2313 been reported and a subprogram covering an interface primitive is not
2314 found then skip generating the internal entity. Done to avoid crashing
2315 the frontend.
2316 (Check_Abstract_Overriding): Change text of error of wrong formal of
2317 protected subprogram or entry. Done for consistency to emit exactly the
2318 same error reported by Check_Synchronized_Overriding. In addition, the
2319 error is restricted to protected types (bug found working on AI05-0090)
2320
2321 2011-08-30 Yannick Moy <moy@adacore.com>
2322
2323 * exp_aggr.adb, exp_ch11.adb, exp_prag.adb: Remove early exit during
2324 expansion in Alfa mode.
2325 * exp_ch6.adb, exp_ch6.ads (Expand_Actuals): Make subprogram public.
2326 * exp_light.adb, exp_light.ads: New package defining light expansion.
2327 * expander.adb (Expand): Call light expansion in Alfa mode
2328 * exp_ch6_light.adb, exp_ch6_light.ads: Light expansion of chapter 6
2329 constructs.
2330 * exp_ch7_light.adb, exp_ch7_light.ads: Light expansion of chapter 7
2331 constructs.
2332 * exp_attr_light.adb, exp_attr_light.ads: Light expansion of attributes
2333 * gnat1drv.adb (Adjust_Global_Switches): Comment
2334
2335 2011-08-30 Yannick Moy <moy@adacore.com>
2336
2337 * lib-xref-alfa.adb: Minor refactoring.
2338
2339 2011-08-30 Yannick Moy <moy@adacore.com>
2340
2341 * exp_ch9.adb (Expand_Entry_Barrier): Do not perform expansion in Alfa
2342 mode.
2343 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Do not perform
2344 expansion in Alfa mode.
2345 * sem_ch9.adb (Analyze_Entry_Body): Do not perform expansion in Alfa
2346 mode.
2347
2348 2011-08-30 Robert Dewar <dewar@adacore.com>
2349
2350 * debug_a.adb: Update comment.
2351
2352 2011-08-30 Robert Dewar <dewar@adacore.com>
2353
2354 * exp_ch5.adb, sem_ch3.adb, sem_ch5.adb, einfo.adb, checks.adb,
2355 sem_util.adb, sem_util.ads, sem_res.adb, s-stposu.adb, sem_attr.adb,
2356 exp_ch4.adb, exp_ch6.adb, lib-xref-alfa.adb,
2357 sem_ch8.adb, sem_disp.adb, exp_ch3.adb: Minor reformatting
2358
2359 2011-08-30 Robert Dewar <dewar@adacore.com>
2360
2361 * gnat_rm.texi: Add section on C.6(16) implementation advice for pragma
2362 volatile.
2363
2364 2011-08-30 Hristian Kirtchev <kirtchev@adacore.com>
2365
2366 * exp_ch3.adb (Expand_Freeze_Array_Type): Correct the call to
2367 Build_Finalization_Master by supplying an insertion node and enclosing
2368 scope. In its old version, the call did not generate a finalization
2369 master.
2370 (Expand_Freeze_Record_Type): Add local variable Has_AACC. Add code to
2371 recognize anonymous access-to-controlled components. Rewrite the
2372 machinery which creates finalization masters to service anonymous
2373 access-to-controlled components of a record type. In its current state,
2374 only one heterogeneous master is necessary to handle multiple anonymous
2375 components.
2376 (Freeze_Type): Comment reformatting.
2377 * rtsfind.ads: Add RE_Set_Is_Heterogeneous to tables RE_Id and
2378 RE_Unit_Table.
2379 * s-stposu.adb (Allocate_Any_Controlled): Rewrite the machinery which
2380 associates TSS primitive Finalize_Address with either the master itself
2381 or with the internal hash table depending on the mode of operation of
2382 the master.
2383
2384 2011-08-30 Javier Miranda <miranda@adacore.com>
2385
2386 * exp_ch3.adb (Make_Eq_If): If the etype of the _parent component is an
2387 interface type then do not generate code to compare this component.
2388 Required since they have no components and their equality operator is
2389 abstract.
2390
2391 2011-08-30 Steve Baird <baird@adacore.com>
2392
2393 * sem_util.ads (Deepest_Type_Access_Level): New function; for the type
2394 of a saooaaat (i.e, a stand-alone object of an anonymous access type),
2395 returns the (static) accessibility level of the object. Otherwise, the
2396 same as Type_Access_Level.
2397 (Dynamic_Accessibility_Level): New function; given an expression which
2398 could occur as the rhs of an assignment to a saooaaat (i.e., an
2399 expression of an access-to-object type), return the new value for the
2400 saooaaat's associated Extra_Accessibility object.
2401 (Effective_Extra_Accessibility): New function; same as
2402 Einfo.Extra_Accessibility except that object renames are looked through.
2403 * sem_util.adb
2404 (Deepest_Type_Access_Level): New function; see sem_util.ads description.
2405 (Dynamic_Accessibility_Level): New function; see sem_util.ads
2406 description.
2407 (Effective_Extra_Accessibility): New function; see sem_util.ads
2408 description.
2409 * einfo.ads (Is_Local_Anonymous_Access): Update comments.
2410 (Extra_Accessibility): Update comments.
2411 (Init_Object_Size_Align): New procedure; same as Init_Size_Align
2412 except RM_Size field (which is only for types) is unaffected.
2413 * einfo.adb
2414 (Extra_Accessibility): Expand domain to allow objects, not just formals.
2415 (Set_Extra_Accessibility): Expand domain to allow objects, not just
2416 formals.
2417 (Init_Size): Add assertion that we are not trashing the
2418 Extra_Accessibility attribute of an object.
2419 (Init_Size_Align): Add assertion that we are not trashing the
2420 Extra_Accessibility attribute of an object.
2421 (Init_Object_Size_Align): New procedure; see einfo.ads description.
2422 * sem_ch3.adb (Find_Type_Of_Object): Set Is_Local_Anonymous_Access
2423 differently for the type of a (non-library-level) saooaaat depending
2424 whether Ada_Version < Ada_2012. This is the only point where Ada_Version
2425 is queried in this set of changes - everything else (in particular,
2426 setting of the Extra_Accessibility attribute in exp_ch3.adb) is
2427 driven off of the setting of the Is_Local_Anonymous_Access attribute.
2428 The special treatment of library-level saooaaats is an optimization,
2429 not required for correctnesss. This is based on the observation that the
2430 Ada2012 rules (static and dynamic) for saooaaats turn out to be
2431 equivalent to the Ada2005 rules in the case of a library-level saooaaat.
2432 * exp_ch3.adb
2433 (Expand_N_Object_Declaration): If Is_Local_Anonymous_Access is
2434 false for the type of a saooaaat, declare and initialize its
2435 accessibility level object and set the Extra_Accessibility attribute
2436 of the saooaaat to refer to this object.
2437 * checks.adb (Apply_Accessibility_Check): Add Ada 2012 saooaaat support.
2438 * exp_ch4.adb (Expand_N_In): Replace some Extra_Accessibility calls with
2439 calls to Effective_Extra_Accessibility in order to support
2440 renames of saooaaats.
2441 (Expand_N_Type_Conversion): Add new local function,
2442 Has_Extra_Accessibility, and call it when determining whether an
2443 accessibility check is needed.
2444 It returns True iff Present (Effective_Extra_Accessibility (Id)) would
2445 evaluate to True (without raising an exception).
2446 * exp_ch5.adb
2447 (Expand_N_Assignment_Statement): When assigning to an Ada2012
2448 saooaaat, update its associated Extra_Accessibility object (if
2449 it has one). This includes an accessibility check.
2450 * exp_ch6.adb (Add_Call_By_Copy_Code): When parameter copy-back updates
2451 a saooaaat, update its Extra_Accessibility object too (if it
2452 has one).
2453 (Expand_Call): Replace a couple of calls to Type_Access_Level
2454 with calls to Dynamic_Access_Level to handle cases where
2455 passing a literal (any literal) is incorrect.
2456 * sem_attr.adb (Resolve_Attribute): Handle the static accessibility
2457 checks associated with "Saooaat := Some_Object'Access;"; this must
2458 be rejected if Some_Object is declared in a more nested scope
2459 than Saooaat.
2460 * sem_ch5.adb (Analyze_Assignment): Force accessibility checking for an
2461 assignment to a saooaaat even if Is_Local_Anonymous_Access
2462 returns False for its type (indicating a 2012-style saooaaat).
2463 * sem_ch8.adb
2464 (Analyze_Object_Renaming): Replace a call to Init_Size_Align
2465 (which is only appropriate for objects, not types) with a call
2466 of Init_Object_Size_Align in order to avoid trashing the
2467 Extra_Accessibility attribute of a rename (the two attributes
2468 share storage).
2469 * sem_res.adb
2470 (Valid_Conversion) Replace six calls to Type_Access_Level with
2471 calls to Deepest_Type_Access_Level. This is a bit tricky. For an
2472 Ada2012 non-library-level saooaaat, the former returns library level
2473 while the latter returns the (static) accessibility level of the
2474 saooaaat. A type conversion to the anonymous type of a saooaaat
2475 can only occur as part of an assignment to the saooaaat, so we
2476 know that such a conversion must be in a lhs context, so Deepest
2477 yields the result that we need. If such a conversion could occur,
2478 say, as the operand of an equality operator, then this might not
2479 be right. Also add a test so that static accessibilty checks are
2480 performed for converting to a saooaaat's type even if
2481 Is_Local_Anonymous_Access yields False for the type.
2482
2483 2011-08-30 Javier Miranda <miranda@adacore.com>
2484
2485 * sem_disp.adb (Check_Dispatching_Operation): Complete condition that
2486 controls generation of a warning associated with late declaration of
2487 dispatching functions. Required to avoid generating spurious
2488 warnings.
2489
2490 2011-08-30 Gary Dismukes <dismukes@adacore.com>
2491
2492 * sem_ch6.adb (Check_Return_Subtype_Indication): Issue error if the
2493 return object has an anonymous access type and the function's type is
2494 a named access type.
2495 * sem_ch8.adb (Analyze_Object_Renaming): Suppress error about renaming
2496 conversions on implicit conversions, since such conversions can occur
2497 for anonymous access cases due to expansion. Issue error for attempt
2498 to rename an anonymous expression as an object of a named access type.
2499 * sem_res.ads (Valid_Conversion): Add defaulted parameter Report_Errs,
2500 to indicate whether this function should report errors on invalid
2501 conversions.
2502 * sem_res.adb (Resolve): For Ada 2012, in the case where the type of
2503 the expression is of an anonymous access type and the expected type is
2504 a named general access type, rewrite the expression as a type
2505 conversion, unless this is an expression of a membership test.
2506 (Valid_Conversion.Error_Msg_N): New procedure that conditions the
2507 calling of Error_Msg_N on new formal Report_Errs.
2508 (Valid_Conversion.Error_Msg_NE): New procedure that conditions the
2509 calling of Error_Msg_NE on new formal Report_Errs.
2510 (Valid_Conversion): Move declaration of this function to the package
2511 spec, to allow calls from membership test processing. For Ada 2012,
2512 enforce legality restrictions on implicit conversions of anonymous
2513 access values to general access types, disallowing such conversions in
2514 cases where the expression has a dynamic accessibility level (access
2515 parameters, stand-alone anonymous access objects, or a component of a
2516 dereference of one of the first two cases).
2517 * sem_type.adb (Covers): For Ada 2012, allow an anonymous access type
2518 in the context of a named general access expected type.
2519 * exp_ch4.adb Add with and use of Exp_Ch2.
2520 (Expand_N_In): Add processing for membership tests applied to
2521 expressions of an anonymous access type. First, Valid_Conversion is
2522 called to check whether the test is statically False, and then the
2523 conversion is expanded to test that the expression's accessibility
2524 level is no deeper than that of the tested type. In the case of
2525 anonymous access-to-tagged types, a tagged membership test is applied
2526 as well.
2527 (Tagged_Membership): Extend to handle access type cases, applying the
2528 test to the designated types.
2529 * exp_ch6.adb (Expand_Call): When creating an extra actual for an
2530 accessibility level, and the actual is a 'Access applied to a current
2531 instance, pass the accessibility level of the type of the current
2532 instance rather than applying Object_Access_Level to the prefix. Add a
2533 ??? comment, since this level isn't quite right either (will eventually
2534 need to pass an implicit level parameter to init procs).
2535
2536 2011-08-30 Bob Duff <duff@adacore.com>
2537
2538 * s-taskin.ads: Minor comment fix.
2539
2540 2011-08-30 Ed Schonberg <schonberg@adacore.com>
2541
2542 * sem_res.adb (Check_Parameterless_Call): If the node is a selected
2543 component and the selector is a dispatching operation, check if it is
2544 a prefixed call before rewriting as a parameterless function call.
2545
2546 2011-08-29 Jakub Jelinek <jakub@redhat.com>
2547
2548 * gcc-interface/Makefile.in (../stamp-gnatlib1-$(RTSDIR)): Copy
2549 tsystem.h into $(RTSDIR) instead of rts.
2550
2551 2011-08-29 Robert Dewar <dewar@adacore.com>
2552
2553 * sem_ch10.adb, a-coorse.adb, exp_dist.adb, exp_ch3.adb: Minor
2554 reformatting.
2555 * gcc-interface/Make-lang.in: Update dependencies.
2556
2557 2011-08-29 Yannick Moy <moy@adacore.com>
2558
2559 * alfa.ads (Name_Of_Heap_Variable): New constant name.
2560 * lib-xref-alfa.adb, lib-xref.adb, lib-xref.ads (Drefs): New global
2561 table to hold dereferences.
2562 (Add_ALFA_Xrefs): Take into account dereferences as special
2563 reads/writes to the variable "HEAP".
2564 (Enclosing_Subprogram_Or_Package): Move subprogram here.
2565 (Generate_Dereference): New procedure to store a read/write dereferencew
2566 in the table Drefs.
2567 * put_alfa.adb (Put_ALFA): Use different default than (0,0) used for
2568 the special "HEAP" var.
2569 * sem_ch4.adb (Analyze_Explicit_Dereference): Store read dereference
2570 in ALFA mode.
2571 * sem_util.adb (Note_Possible_Modification): Store write dereference
2572 in ALFA mode.
2573
2574 2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
2575
2576 * exp_ch3.adb (Freeze_Type): Generate an accessibility check which
2577 ensures that the level of the subpool access type is not deeper than
2578 that of the pool object.
2579 * sem_util.adb (Object_Access_Level): Expand to handle defining
2580 identifiers.
2581 * sem_res.adb (Resolve_Allocator): Add a guard to avoid examining the
2582 subpool handle name of a rewritten allocator.
2583
2584 2011-08-29 Robert Dewar <dewar@adacore.com>
2585
2586 * impunit.adb, exp_ch4.adb, s-finmas.adb: Minor reformatting.
2587
2588 2011-08-29 Thomas Quinot <quinot@adacore.com>
2589
2590 * exp_dist.adb (TC_Rec_Add_Process_Element): For a choice with multiple
2591 values, we generate multiple triples of parameters in the TypeCode.
2592 Bump Choice_Index for each such triple so that a subsequent default
2593 choice is associated with the correct index in the typecode.
2594
2595 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2596
2597 * a-cdlili.adb (Iterate): Initialize properly an iterator over a null
2598 container.
2599 (First, Last): Handle properly an iterator over a null container.
2600
2601 2011-08-29 Bob Duff <duff@adacore.com>
2602
2603 * sem_ch10.adb (Analyze_With_Clause,Install_Withed_Unit): Abandon
2604 processing if we run across a node with no Scope. This can happen if
2605 we're with-ing an library-level instance, and that instance got errors
2606 that caused "instantiation abandoned".
2607 * sem_util.adb (Unit_Declaration_Node): Make it more robust, by raising
2608 an exception instead of using Assert, so it won't go into an infinite
2609 loop, even when assertions are turned off.
2610
2611 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2612
2613 * a-coorse.adb: Proper handling of empty ordered sets.
2614
2615 2011-08-29 Johannes Kanig <kanig@adacore.com>
2616
2617 * debug.adb: Add comments.
2618
2619 2011-08-29 Thomas Quinot <quinot@adacore.com>
2620
2621 * a-except.adb, a-except-2005.adb: Minor comment rewording and
2622 reformatting.
2623
2624 2011-08-29 Yannick Moy <moy@adacore.com>
2625
2626 * sem_ch3.adb (Array_Type_Declaration): Remove insertion of
2627 declaration for Itypes in Alfa mode.
2628
2629 2011-08-29 Robert Dewar <dewar@adacore.com>
2630
2631 * a-cdlili.ads, a-coinve.ads, a-coorma.adb, a-coorma.ads, s-tassta.adb,
2632 a-cborma.adb, a-cborma.ads, a-cohama.ads, a-coorse.ads, a-cbhama.ads,
2633 a-cborse.ads, a-cobove.adb, a-cobove.ads, a-cbhase.ads: Minor
2634 reformatting.
2635
2636 2011-08-29 Tristan Gingold <gingold@adacore.com>
2637
2638 * exp_ch7.adb, exp_ch7.ads (Build_Exception_Handler): Move its spec to
2639 package spec.
2640 * exp_intr.adb (Expand_Unc_Deallocation): Use Build_Exception_Handler.
2641 * a-except.adb, a-except-2005.adb (Rcheck_22): Do not defer aborts
2642 while raising PE.
2643
2644 2011-08-29 Robert Dewar <dewar@adacore.com>
2645
2646 * a-cbhama.adb, a-cbhama.ads: Minor reformatting.
2647
2648 2011-08-29 Javier Miranda <miranda@adacore.com>
2649
2650 * sem_ch8.adb (Analyze_Subprogram_Renaming): Complete support for
2651 renamings of formal subprograms when the actual for a formal type is
2652 class-wide.
2653
2654 2011-08-29 Matthew Heaney <heaney@adacore.com>
2655
2656 * a-cbhama.ads, a-cbhase.ads (Move): Clear Source following assignment
2657 to Target.
2658
2659 2011-08-29 Matthew Heaney <heaney@adacore.com>
2660
2661 * a-cborma.ads, a-cborse.ads (Cursor): Default-initialize all
2662 components of record type.
2663 * a-cborma.adb, a-cborse.adb (Move): Clear Source following assignmentw
2664 to Target.
2665
2666 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2667
2668 * a-cbhama.adb, a-cbhama.ads, a-cborma.adb, a-cborma.ads, a-cobove.adb,
2669 a-cobove.ads, a-coorma.adb, a-coorma.ads: Add iterator machinery to
2670 container packages.
2671
2672 2011-08-29 Robert Dewar <dewar@adacore.com>
2673
2674 * sem_ch3.adb, sem_util.adb, gnat1drv.adb, s-parint.ads: Minor
2675 reformatting.
2676
2677 2011-08-29 Matthew Heaney <heaney@adacore.com>
2678
2679 * a-cbhama.ads, a-cbhase.ads (Cursor): Default-initialize all
2680 components of record type.
2681
2682 2011-08-29 Bob Duff <duff@adacore.com>
2683
2684 * s-tassta.adb (Task_Wrapper): Handle and ignore exceptions propagated
2685 by the termination handler.
2686
2687 2011-08-29 Yannick Moy <moy@adacore.com>
2688
2689 * sem_ch3.adb (Array_Type_Declaration): Create declarations for Itypes
2690 created in Alfa mode, instead of inserting artificial declarations of
2691 non-Itypes in the tree.
2692 * sem_util.adb, sem_util.ads (Itype_Has_Declaration): New function to
2693 know if an Itype has a corresponding declaration, as defined in
2694 itypes.ads.
2695
2696 2011-08-29 Yannick Moy <moy@adacore.com>
2697
2698 * gnat1drv.adb: Minor rewrite.
2699
2700 2011-08-29 Bob Duff <duff@adacore.com>
2701
2702 * s-tasuti.adb (Make_Passive): Work around race condition in
2703 Make_Independent, which can cause Wait_Count to be zero. So instead of
2704 asserting that Wait_Count > 0, and then decrementing it, decrement it
2705 only if Wait_Count > 0.
2706 * s-taskin.ads (Wait_Count, Alive_Count, Awake_Count): All of these
2707 should be nonnegative, so declare them Natural instead of Integer.
2708
2709 2011-08-29 Robert Dewar <dewar@adacore.com>
2710
2711 * exp_ch5.adb, sem_ch3.adb, a-cihama.adb, a-cihama.ads, exp_ch7.adb,
2712 sem_ch5.adb, a-ciorse.adb, a-ciorse.ads, sem_ch12.adb, a-cidlli.adb,
2713 a-cidlli.ads, sem_util.adb, sem_res.adb, gnat1drv.adb, a-except.adb,
2714 a-except.ads, a-except-2005.ads, sem_ch4.adb, exp_disp.adb,
2715 exp_aggr.adb, sem_ch13.adb, par-ch3.adb: Minor reformatting.
2716
2717 2011-08-29 Tristan Gingold <gingold@adacore.com>
2718
2719 * s-auxdec-vms-alpha.adb: Add comments, remove some HT before labels.
2720
2721 2011-08-29 Vadim Godunko <godunko@adacore.com>
2722
2723 * s-parint.ads: Minor comment clarification.
2724
2725 2011-08-29 Vincent Celier <celier@adacore.com>
2726
2727 * prj.adb (Initialize): Make sure that new reserved words after Ada 95
2728 may be used as identifiers.
2729
2730 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2731
2732 * a-coinho.ads: Minor reformating.
2733
2734 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2735
2736 * exp_ch5.adb (Expand_Iterator_Loop): Handle properly a loop over a
2737 container of a derived type.
2738
2739 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2740
2741 * a-cidlli.adb, a-cidlli.ads, a-cihama.adb, a-cihama.ads,
2742 a-ciorse.adb, a-ciorse.ads: Add iterator machinery to containers.
2743
2744 2011-08-29 Pascal Obry <obry@adacore.com>
2745
2746 * exp_disp.adb: Minor comment fix.
2747 (Make_Disp_Asynchronous_Select_Body): Properly initialize out parameters
2748 to avoid warnings when compiling with -Wall.
2749 (Make_Disp_Conditional_Select_Body): Likewise.
2750 (Make_Disp_Timed_Select_Body): Likewise.
2751
2752 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2753
2754 * sem_ch12.adb (Analyze_Formal_Subprogram_Declaration): If default is
2755 an entity name, generate reference for it.
2756
2757 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2758
2759 * exp_ch5.adb (Expand_Iterator_Loop): Uniform handling of "X of S"
2760 iterator form.
2761 * sem_util.adb (Is_Iterator, Is_Reversible_Iterator): Yield True for
2762 the class-wide type.
2763 * sem_ch5.adb: Move some rewriting to the expander, where it belongs.
2764
2765 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2766
2767 * sem_ch8.adb (Check_Constrained_Object): Do not create an actual
2768 subtype for an object whose type is an unconstrained union.
2769
2770 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2771
2772 * par-ch3.adb (P_Array_Type_Definiation, P_Component_Items): "aliased"
2773 is allowed in a component definition, by AI95-406.
2774
2775 2011-08-29 Matthew Heaney <heaney@adacore.com>
2776
2777 * a-chtgbo.adb (Generic_Iteration): Use correct overloading of Next.
2778
2779 2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
2780
2781 * a-except-2005.adb: Alphabetize all routines.
2782 (Triggered_By_Abort): New routine.
2783 * a-except-2005.ads (Triggered_By_Abort): New routine.
2784 * a-except.adb Alphabetize all routines.
2785 (Triggered_By_Abort): New routine.
2786 * a-except.ads (Triggered_By_Abort): New routine.
2787 * exp_ch7.adb: Update all comments involving the detection of aborts in
2788 finalization code.
2789 (Build_Object_Declarations): Do not generate code to detect the
2790 presence of an abort at the start of finalization code, use a runtime
2791 routine istead.
2792 * rtsfind.ads: Add RE_Triggered_By_Abort to tables RE_Id and
2793 RE_Unit_Table.
2794 * sem_res.adb (Resolve_Allocator): Emit a warning when attempting to
2795 allocate a task on a subpool.
2796 * s-stposu.adb: Add library-level flag Finalize_Address_Table_In_Use.
2797 The flag disables all actions related to the maintenance of
2798 Finalize_Address_Table when subpools are not in use.
2799 (Allocate_Any_Controlled): Signal the machinery that subpools are in
2800 use.
2801 (Deallocate_Any_Controlled): Do not call Delete_Finalize_Address which
2802 performs costly task locking when subpools are not in use.
2803
2804 2011-08-29 Yannick Moy <moy@adacore.com>
2805
2806 * gnat1drv.adb (Adjust_Global_Switches): Restore expansion of tagged
2807 types and dispatching calls in Alfa mode.
2808 * lib-xref-alfa.adb (Collect_ALFA): Rewrite computation of
2809 correspondance between body and spec scopes, to reuse utility functions
2810 (Traverse_Declarations_Or_Statements): Protect access to body for stub
2811 by testing the presence of the library unit for the body
2812 * sem_ch6.adb (Set_Actual_Subtypes): take into account that in Alfa
2813 mode the expansion of accept statements is skipped
2814 * sem_util.adb, sem_util.ads (Unique_Entity): New function returning
2815 the unique entity corresponding to the one returned by
2816 Unique_Defining_Entity applied to the enclosing declaration of the
2817 argument.
2818
2819 2011-08-29 Bob Duff <duff@adacore.com>
2820
2821 * treepr.ads: Improve debugging facilities. pn(x) no longer crashes in
2822 gdb when x is not a node (it can be a node list, name_id, etc). pp is
2823 an alias for pn. ppp is an alias for pt.
2824
2825 2011-08-29 Javier Miranda <miranda@adacore.com>
2826
2827 * exp_aggr.adb (Expand_Record_Aggregate): Use the top-level enclosing
2828 aggregate to take a consistent decision on the need to convert into
2829 assignments aggregates that initialize constant objects.
2830
2831 2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
2832
2833 * exp_ch4.adb (Expand_Allocator_Expression): Add a call to
2834 Build_Allocate_Deallocate_Proc in order to handle allocation of
2835 non-controlled objects on subpools.
2836 * impunit.adb: Remove s-finmas and s-spsufi since they were never meant
2837 to be end-user visible.
2838 * s-finmas.adb: Add with and use clause for System.HTable.
2839 Add an instantiation of Simple_HTable which provides a mapping between
2840 the address of a controlled object and the corresponding
2841 Finalize_Address used to clean up the object. The table is used when a
2842 master is operating in heterogeneous mode.
2843 (Attach): Explain why the input node is not verified on being already
2844 attached.
2845 (Delete_Finalize_Address): New routine.
2846 (Detach): Add pragma Assert which ensures that a node is already
2847 attached.
2848 (Finalize): Add local variable Cleanup. Rewrite the iteration scheme
2849 since nodes are no longer removed on traversal. Explain why node
2850 detachment is undesirable in this case.
2851 (Get_Finalize_Address): New routine.
2852 (Hash): New routine.
2853 (Is_Empty_List): Removed.
2854 (pm): Renamed to Print_Master. Add output for discriminant
2855 Is_Homogeneous.
2856 Comment reformatting.
2857 (Set_Finalize_Address (Address, Finalize_Address_Ptr)): New routine.
2858 * s-finmas.ads: Various comments additions / improvements.
2859 Type Finalization_Master has a discriminant which determines the mode of
2860 operation.
2861 (Delete_Finalize_Address): New routine.
2862 (Get_Finalize_Address): New routine.
2863 (pm): Renamed to Print_Master.
2864 (Set_Finalize_Address (Address, Finalize_Address_Ptr)): New routine.
2865 * s-stposu.adb: Add with clause for System.Address_Image; Add with and
2866 use clause for System.IO.
2867 (Allocate_Any_Controlled): Add machinery to set TSS primitive
2868 Finalize_Address depending on the mode of allocation and the mode of
2869 the master.
2870 (Deallocate_Any_Controlled): Remove the relation pair object -
2871 Finalize_Address regardless of the master mode. Add comment explaining
2872 the reason.
2873 (Detach): Ensure that fields Prev and Next are null after detachment.
2874 (Finalize_Pool): Remove local variable Next_Ptr. Rewrite the iteration
2875 scheme to check whether the list of subpools is empty. There is no
2876 longer need to store the next subpool or advance the current pointer.
2877 (Is_Empty_List): New routine.
2878 (Print_Pool): New routine.
2879 (Print_Subpool): New routine.
2880 * s-stposu.ads: Various comments additions / improvements.
2881 Field Master of type Root_Subpool is now a heterogeneous collection.
2882 (Print_Pool): New routine.
2883 (Print_Subpool): New routine.
2884
2885 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2886
2887 * exp_ch5.adb (Expand_N_Iterator_Loop): Implement Ada2012 loop iterator
2888 forms, using aspects of container types.
2889 * sem_ch3.adb (Find_Type_Name): Preserve Has_Delayed_Aspects and
2890 Has_Implicit_Dereference flags, that may be set on the partial view.
2891 * sem_ch4.adb (Process_Overloaded_Indexed_Component): Prefix may be a
2892 container type with an indexing aspect.
2893 (Analyze_Quantified_Expression): Analyze construct with expansion
2894 disabled, because it will be rewritten as a loop during expansion.
2895 (Try_Container_Indexing): The prefix itself may be a container type
2896 with an indexing aspect, as with a vector of vectors.
2897 * sem_ch5.adb (Analyze_Iteration_Scheme): In a generic context, analyze
2898 the original doamin of iteration, for name capture.
2899 (Analyze_Iterator_Specification): If the domain is an expression that
2900 needs finalization, create a separate declaration for it.
2901 For an iterator with "of" retrieve default iterator info from aspect of
2902 container type. For "in" iterator, retrieve type of Iterate function.
2903 * sem_ch13.adb (Check_Iterator_Function): Fix typo.
2904 (Check_Aspect_At_End_Of_Declaration): Make type unfrozen before
2905 analysis, to prevent spurious errors about late attributes.
2906 * sprint.adb: Handle quantified expression with either loop or iterator
2907 specification.
2908 * a-convec.ads, a-convec.adb: Iterate function returns a reversible
2909 iterator.
2910
2911 2011-08-29 Vincent Celier <celier@adacore.com>
2912
2913 * make.adb (Scan_Make_Arg): Take any option as is in packages Compiler,
2914 Binder or Linker of the main project file.
2915
2916 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2917
2918 * inline.adb (Add_Scopes_To_Clean): Exclude any entity within a generic
2919 unit.
2920
2921 2011-08-29 Yannick Moy <moy@adacore.com>
2922
2923 * exp_ch9.adb: Partial revert of previous change for Alfa mode
2924
2925 2011-08-29 Yannick Moy <moy@adacore.com>
2926
2927 * exp_ch11.adb: Minor expansion of comment.
2928
2929 2011-08-29 Yannick Moy <moy@adacore.com>
2930
2931 * lib-xref-alfa.adb (Add_ALFA_Scope): Treat generic entities.
2932
2933 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2934
2935 * sem_res.adb (Resolve_Arithmetic_Op): If the node has a universal
2936 interpretation, set the type before resolving the operands, because
2937 legality checks on an exponention operand need to know the type of the
2938 context.
2939
2940 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2941
2942 * sem_ch12.adb (Analyze_Package_Instantiation): Do not set delayed
2943 cleanups on a master if the instance is within a generic unit.
2944 Complement to the corresponding fix to inline.adb for K520-030.
2945
2946 2011-08-29 Tristan Gingold <gingold@adacore.com>
2947
2948 * exp_ch7.adb (Build_Raise_Statement): Raise PE instead of the current
2949 occurrence.
2950 * exp_intr.adb: Minor comment fix.
2951
2952 2011-08-29 Bob Duff <duff@adacore.com>
2953
2954 * sem_ch13.adb (Analyze_Aspect_Specifications): Fix cases where
2955 Delay_Required was used as an uninitialized variable.
2956
2957 2011-08-29 Robert Dewar <dewar@adacore.com>
2958
2959 * a-cdlili.adb, a-cdlili.ads, a-coinve.adb, a-coinve.ads,
2960 sem_util.adb, sem_util.ads, a-cohama.adb, a-cohama.ads, a-coorse.adb,
2961 a-coorse.ads, aspects.ads, sem_ch8.adb: Minor reformatting.
2962
2963 2011-08-29 Thomas Quinot <quinot@adacore.com>
2964
2965 * system-freebsd-x86_64.ads (Backend_Overflow_Checks): Set true True.
2966 Remove unused variables.
2967
2968 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2969
2970 * sem_res.adb: Remove Build_Explicit_Dereference.
2971 * sem_util.adb, sem_util.ads (Build_Explicit_Dereference): Moved here
2972 from sem_res.adb, used in analysis of additional constructs.
2973 (Is_Iterator, Is_Reversible_Iterator): New predicates for Ada2012
2974 expansion of iterators.
2975 (Is_Object_Reference): Recognize variables rewritten as explicit
2976 dereferences in Ada2012.
2977 * snames.ads-tmpl: Add Has_Element, Forward_Iterator,
2978 Reversible_Iterator names, for expansion of Ada2012 iterators.
2979 * aspects.ads, aspects.adb (Find_Aspect): Utility.
2980 * a-cdlili.ads, a-cdlili.adb: Add new iterator machinery to doubly
2981 linked list container.
2982 * a-coinve.ads, a-coinve.adb: Ditto for indefinite vector containers.
2983 * a-coorse.ads, a-coorse.adb: Ditto for ordered sets.
2984
2985 2011-08-29 Ed Schonberg <schonberg@adacore.com>
2986
2987 * a-cohama.adb, a-cohama.ads: Add iterator primitives to hashed map
2988 containers.
2989
2990 2011-08-29 Vincent Celier <celier@adacore.com>
2991
2992 * make.adb (Gnatmake): Get the maximum number of simultaneous
2993 compilation processes after the Builder switches has been scanned, as
2994 there may include -jnn.
2995
2996 2011-08-29 Matthew Heaney <heaney@adacore.com>
2997
2998 * a-chtgbo.adb (Generic_Equal): Use correct overloading of Next.
2999
3000 2011-08-29 Tristan Gingold <gingold@adacore.com>
3001
3002 * gnatcmd.adb (GNATCmd): On OpenVMS, truncate the length of
3003 GNAT_DRIVER_COMMAND_LINE to 255.
3004
3005 2011-08-29 Pascal Obry <obry@adacore.com>
3006
3007 * freeze.adb, sem_ch8.adb, a-convec.adb, a-convec.ads: Minor
3008 reformatting and style fix (class attribute casing).
3009
3010 2011-08-29 Yannick Moy <moy@adacore.com>
3011
3012 * exp_ch11.adb: Yet another case where expansion should be common
3013 between CodePeer and Alfa.
3014
3015 2011-08-29 Yannick Moy <moy@adacore.com>
3016
3017 * exp_ch9.adb: Partial revert of previous change for Alfa mode.
3018
3019 2011-08-29 Ed Schonberg <schonberg@adacore.com>
3020
3021 * sem_ch6.adb (Matches_Limited_With_View): The limited views of an
3022 incomplete type and its completion match.
3023
3024 2011-08-29 Yannick Moy <moy@adacore.com>
3025
3026 * exp_ch13.adb: Adjust previous change.
3027
3028 2011-08-29 Robert Dewar <dewar@adacore.com>
3029
3030 * sem_prag.adb, prj.adb, sem_util.adb, sem_res.adb, gnat1drv.adb,
3031 exp_ch4.adb, sem_ch8.adb: Minor code reorganization
3032 Minor reformatting.
3033
3034 2011-08-29 Emmanuel Briot <briot@adacore.com>
3035
3036 * make.adb, prj.adb, prj.ads (Compute_All_Imported_Projects): Also
3037 initialize aggregated projects.
3038
3039 2011-08-29 Ed Schonberg <schonberg@adacore.com>
3040
3041 * sem_ch8.adb (Find_Renamed_Entity): Within an instance, use scope
3042 depth of candidates to resolve a potentially spurious ambiguity between
3043 two visible subprograms.
3044
3045 2011-08-29 Yannick Moy <moy@adacore.com>
3046
3047 * sem_prag.adb (Analyze_Pragma): Allow Test_Case pragma without
3048 Requires/Ensures.
3049 * sem_util.adb (Get_Ensures_From_Test_Case_Pragma,
3050 Get_Requires_From_Test_Case_Pragma): Allow Test_Case pragma without
3051 Requires/Ensures.
3052
3053 2011-08-29 Arnaud Charlet <charlet@adacore.com>
3054
3055 * gnat1drv.adb (Adjust_Global_Switches): Improve previous change.
3056 Add comment.
3057
3058 2011-08-29 Thomas Quinot <quinot@adacore.com>
3059
3060 * sem_res.adb: Minor reformatting.
3061
3062 2011-08-29 Johannes Kanig <kanig@adacore.com>
3063
3064 * exp_ch4.adb (Expand_Quantified_Expression): Do not expand in ALFA
3065 mode.
3066 * gnat1drv.adb (Adjust_Global_Switches): Set
3067 Use_Expressions_With_Actions to False in ALFA mode.
3068 * sem_res.adb (Resolve_Quantified_Expression): Simpler treatment in
3069 ALFA mode.
3070
3071 2011-08-29 Yannick Moy <moy@adacore.com>
3072
3073 * exp_ch13.adb (Expand_N_Freeze_Entity): Do nothing in Alfa mode.
3074 * exp_ch9.adb: Do not expand tasking constructs in Alfa mode.
3075 * gnat1drv.adb (Adjust_Global_Switches): Suppress the expansion of
3076 tagged types and dispatching calls in Alfa mode.
3077
3078 2011-08-29 Javier Miranda <miranda@adacore.com>
3079
3080 * sem_ch3.adb (Process_Discriminants): Add missing check to ensure that
3081 we do not report an error on an Empty node.
3082
3083 2011-08-29 Geert Bosch <bosch@adacore.com>
3084
3085 * Makefile.rtl (GNATRTL_NONTASKING_OBJECTS): Add a-nllrar.o,
3086 a-nlrear.o and a-nurear.o.
3087
3088 2011-08-29 Robert Dewar <dewar@adacore.com>
3089
3090 * freeze.adb: Minor code reorganization.
3091 Minor reformatting.
3092 * sem_util.adb, errout.adb, exp_ch11.adb, a-ngrear.adb, s-gearop.adb,
3093 sem_ch6.adb: Minor reformatting
3094
3095 2011-08-29 Tristan Gingold <gingold@adacore.com>
3096
3097 * s-except.ads, s-except.adb: Provide dummy body.
3098
3099 2011-08-29 Yannick Moy <moy@adacore.com>
3100
3101 * sem_warn.adb (Within_Postcondition): Take into account the case of
3102 an Ensures component in a Test_Case.
3103
3104 2011-08-29 Tristan Gingold <gingold@adacore.com>
3105
3106 * s-excdeb.ads, s-excdeb.adb: New files, created from s-except.
3107 * rtsfind.ads (RTU_Id): Replaces System_Exceptions by
3108 System_Exceptions_Debug
3109 (RE_Unit_Table): Search RE_Local_Raise in System_Exceptions_Debug
3110 * a-except.adb: With and use System.Exceptions_Debug instead of
3111 System.Exceptions.
3112 * a-except-2005.adb: Likewise.
3113 * s-assert.adb: Likewise.
3114 * s-except.adb, s-except.ads: Move debugging hooks to s-excdeb.
3115 * Makefile.rtl: Add s-excdeb. Adjust compilation rule.
3116 * gcc-interfaces/Makefile.in, gcc-interface/Make-lang.in: Add
3117 s-excdeb. Update dependencies.
3118 (GNATRTL_LINEARALGEBRA_OBJS): Remove a-nlrear.o a-nurear.o a-nllrar.o
3119 as these no longer need external libraries.
3120
3121 2011-08-29 Ed Schonberg <schonberg@adacore.com>
3122
3123 * sem_res.adb (Resolve_Op_Expon): Additional check to reject an
3124 exponentiation operator on universal values in a context that requires
3125 a fixed-point type.
3126
3127 2011-08-29 Tristan Gingold <gingold@adacore.com>
3128
3129 * raise-gcc.c (personnality_routine): Fix thinko. Set Ada occurrence
3130 before calling notify_handled_exception.
3131 * a-exextr.adb: Fix comment.
3132
3133 2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
3134
3135 * exp_ch4.adb (Expand_Allocator_Expression): Add code to set attribute
3136 Finalize_Address of the access type's finalization master.
3137 (Expand_N_Allocator): Add code to set attribute Finalize_Address of the
3138 access type's finalization master. Add a guard to prevent
3139 Associated_Storage_Pool from being set on .NET/JVM.
3140 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Add code to set
3141 attribute Finalize_Address of the access type's finalization master.
3142 * exp_ch7.adb (Make_Finalize_Address_Call): New routine.
3143 * exp_ch7.ads (Make_Finalize_Address_Call): New routine.
3144 * rtsfind.ads: Add RE_Set_Finalize_Address to tables RE_Id and
3145 RE_Unit_Table.
3146 * s-finmas.adb: Add with clause for System.Address_Image. Add with and
3147 use clause for System.IO
3148 (Detach): Relax the assertion, to be reinstated later.
3149 (Finalize): Rewrite the iteration loop to avoid pointer comparison.
3150 Relax the assertion on Finalize_Address, to be reinstated later.
3151 (Is_Empty_List): New routine.
3152 (pm): New debug routine.
3153 (Set_Finalize_Address): New routine.
3154 * s-finmas.ads (pm): New debug routine.
3155 (Set_Finalize_Address): New routine.
3156 * s-stposu.adb (Allocate_Any_Controlled): Code reformatting.
3157
3158 2011-08-29 Tristan Gingold <gingold@adacore.com>
3159
3160 * a-exexpr-gcc.adb (GCC_Exception_Access, GNAT_GCC_Exception_Access):
3161 Remove convention C.
3162
3163 2011-08-29 Tristan Gingold <gingold@adacore.com>
3164
3165 * s-taprop-vms.adb (Get_Exc_Stack_Addr): Remove.
3166 (Initialize_TCB): Remove Exc_Stack_Ptr initialization.
3167 (Finalize_TCB): Remove its finalization.
3168 (Initialize): Remove assignment of GET_Exc_Stack_Addr
3169 * s-soflin.adb (NT_Exc_Stack): Remove
3170 (Get_Exc_Stack_Addr_NT): Likewise.
3171 (Get_Exc_Stack_Addr_Soft): Likewise.
3172 * s-soflin.ads (Get_Exc_Stack_Addr_NT): Remove.
3173 (Get_Exc_Stack_Addr): Likewise.
3174 (Get_Exc_Stack_Addr_Soft): Likewise
3175 * s-taspri-vms.ads (Exc_Stack_T): Remove.
3176 (Exc_Stack_Ptr_T): Likewise.
3177 (Private_Data): Remove Exc_Stack_Ptr component.
3178
3179 2011-08-29 Tristan Gingold <gingold@adacore.com>
3180
3181 * raise-gcc.c (get_ip_from_context): New function. Factorize code.
3182
3183 2011-08-29 Tristan Gingold <gingold@adacore.com>
3184
3185 * gnat_ugn.texi: Fix aix and x86-solaris info for run-time.
3186
3187 2011-08-29 Geert Bosch <bosch@adacore.com>
3188
3189 * s-gearop.ads (Back_Substitute, Diagonal, Forward_Eliminate,
3190 L2_Norm, Swap_Column): New generic subprograms
3191 * s-gearop.adb (Back_Substitute, Diagonal, Forward_Eliminate,
3192 L2_Norm, Swap_Column): Implement new subprograms in order to
3193 eliminate dependency on BLAS and LAPACK libraries in
3194 Ada.Numerics.Generic_Real_Arrays and eventually also the complex
3195 version. Forward_Eliminate/Back_Substitute can be used to put a
3196 matrix in row echelon or reduced row echelon form using partial
3197 pivoting.
3198 * a-ngrear.adb: (Back_Substitute, Diagonal, Forward_Eleminate,
3199 Swap_Column): Instantiate from System.Generic_Array_Operations.
3200 ("*", "abs"): Implement by instantiation from Generic_Array_Operations.
3201 (Sqrt): Local function for simple computation of square root without
3202 adding dependencies on Generic_Elementary_Functions.
3203 (Swap): New subprogram to exchange floating point numbers.
3204 (Inverse): Reimplement using Jordan-Gauss elimination.
3205 (Jacobi): New procedure implementing Jacobi's method for computation
3206 of eigensystems, based on Rutishauser's implementation.
3207 (L2_Norm): Implement directly using the inner product.
3208 (Sort_Eigensystem): Sort eigenvalue/eigenvector pairs in order of
3209 decreasing eigenvalue as required by the Ada RM.
3210 (Swap_Column): New helper procedure for Sort_Eigensystem.
3211 Remove with of System.Generic_Real_BLAS and System.Generic_Real_LAPACK.
3212 Add with of Ada.Containers.Generic_Anonymous_Array_Sort, for
3213 Sort_Eigensystems.
3214
3215 2011-08-29 Thomas Quinot <quinot@adacore.com>
3216
3217 * put_scos.adb (Put_SCOs): Do not emit a newline for an empty
3218 statements line.
3219
3220 2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
3221
3222 * s-finmas.adb (Finalize): Check Finalize_Address of the master rather
3223 than the current node.
3224 * s-finmas.ads: Move field Finalize_Address from type FM_Node to
3225 Finalization_Master. The list headers have two fields instead of three.
3226 This should fix alignment issue but subpool allocations are now
3227 unusable. Alphabetize subprograms.
3228 * s-stposu.adb (Allocate_Any_Controlled): Use the offset rather than
3229 the size of the header when converting the beginning of the object to
3230 a FM_Node. Set the master's Finalize_Address attribute if not already
3231 set.
3232 (Deallocate_Any_Controlled): Use the offset rather than the size of the
3233 header when converting the beginning of the object to a FM_Node.
3234
3235 2011-08-29 Gary Dismukes <dismukes@adacore.com>
3236
3237 * exp_ch11.adb (Expand_N_Raise_Statement): Don't suppress expansion of
3238 reraise when compiling for CodePeer.
3239
3240 2011-08-29 Arnaud Charlet <charlet@adacore.com>
3241
3242 * a-iteint.ads, Makefile.rtl: Add missing compilation of a-iteint.ads,
3243 now needed by a-convec.adb. Fix warning.
3244
3245 2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
3246
3247 * exp_util.adb (Build_Allocate_Deallocate_Proc): Add a guard for the
3248 processing of TSS routine Finalize_Address when compiling in
3249 CodePeer_Mode.
3250
3251 2011-08-29 Thomas Quinot <quinot@adacore.com>
3252
3253 * a-strunb.ads, einfo.ads, g-comlin.ads, sem_ch6.adb,
3254 sem_warn.adb: Minor reformatting.
3255
3256 2011-08-29 Emmanuel Briot <briot@adacore.com>
3257
3258 * prj-conf.adb (Get_Config_Switches): Also collect the list of
3259 languages from aggregated projects.
3260
3261 2011-08-29 Yannick Moy <moy@adacore.com>
3262
3263 * lib-xref-alfa.adb, lib-xref.ads (Traverse_Declarations_Or_Statements,
3264 Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
3265 Traverse_Package_Declaration, Traverse_Subprogram_Body,
3266 Traverse_Compilation_Unit): Add a parameter Inside_Stubs so that bodies
3267 for stubs are traversed too when parameter is set
3268 (Traverse_All_Compilation_Units): Traverse without going inside stubs
3269 (Traverse_Declarations_Or_Statements): Do the special traversing for
3270 stubs when required.
3271 * sem_util.adb, sem_util.ads (Get_Body_From_Stub): New function to
3272 return subprogram or package body from stub.
3273 (Is_Subprogram_Stub_Without_Prior_Declaration): New function to detect
3274 stubs without prior subprogram decl.
3275
3276 2011-08-29 Vasiliy Fofanov <fofanov@adacore.com>
3277
3278 * gnat_ugn.texi: Fix typo.
3279
3280 2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
3281
3282 * s-stposu.adb (Allocate_Any_Controlled): Reimplement the mechanism
3283 which accounts for size vs alignment issues and calculates the size of
3284 the list header.
3285 (Deallocate_Any_Controlled): Ditto.
3286 (Nearest_Multiple_Rounded_Up): New routine.
3287
3288 2011-08-29 Tristan Gingold <gingold@adacore.com>
3289
3290 * a-exstat.adb (String_To_EO): Do no set Cleanup_Flag.
3291 * a-exexda.adb (Set_Exception_C_Msg): Ditto.
3292 (Set_Exception_Msg): Ditto.
3293 * a-exexpr-gcc.adb (Setup_Current_Excep): Ditto. Do not set
3294 Private_Data.
3295 * a-except.adb, a-except-2005.adb (Save_Occurrence_No_Private): Remove.
3296 Use Save_Occurrence instead of Save_Occurrence_No_Private.
3297 (Raise_With_Msg): Remove Cleanup_Flag.
3298 * a-except.ads, a-except-2005.ads (Exception_Occurrence): Remove
3299 Clean_Flag and Private_Data components.
3300
3301 2011-08-29 Yannick Moy <moy@adacore.com>
3302
3303 * freeze.adb (Freeze_Record_Type): Ignore packing in Alfa mode, like
3304 in CodePeer mode.
3305 * sem_ch3.adb (Signed_Integer_Type_Declaration): Correct the generation
3306 of an explicitly declared type, so that the base types of the original
3307 type and this generated type are the same, and a "type" (not a subtype
3308 like previously).
3309 * errout.adb (Special_Msg_Delete): Do not issue messages "Size too
3310 small" in Alfa mode, like in CodePeer mode.
3311 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore rep
3312 clauses in Alfa mode.
3313
3314 2011-08-29 Javier Miranda <miranda@adacore.com>
3315
3316 * exp_ch6.ads, exp_ch6.adb (Is_Null_Procedure): Move the spec of this
3317 function to the package spec.
3318 * sem_ch6.adb (Find_Corresponding_Spec, New_Overloaded_Entity): For
3319 internally generated bodies of null procedures locate the internally
3320 generated spec enforcing mode conformance.
3321 (Is_Interface_Conformant): Ensure that the controlling formal of the
3322 primitives match.
3323
3324 2011-08-29 Ed Schonberg <schonberg@adacore.com>
3325
3326 * sem_prag.adb (Analyze_Pragma, case Inline): In an instance, do not
3327 reject the pragma if it appears to apply to a formal subprogram.
3328
3329 2011-08-29 Ed Schonberg <schonberg@adacore.com>
3330
3331 * exp_ch4.adb (Expand_Allocator_Expression): Use consistent name for
3332 inner expression, to prevent double evaluation.
3333
3334 2011-08-29 Tristan Gingold <gingold@adacore.com>
3335
3336 * a-exexpr.adb (Propagate_Exception): Remove all the parameters as
3337 they were unused.
3338 * a-exexpr-gcc.adb (Propagate_Exception): Ditto.
3339 * a-except-2005.adb (Propagate_Exception): Adjust spec.
3340 (Raise_Current_Excep): Adjust call.
3341 (Raise_From_Signal_Handler): Call now simply call Raise_Current_Excep.
3342
3343 2011-08-29 Thomas Quinot <quinot@adacore.com>
3344
3345 * exp_disp.adb: Minor reformatting.
3346
3347 2011-08-29 Tristan Gingold <gingold@adacore.com>
3348
3349 * a-exexpr.adb (Setup_Exception): Removed.
3350 * a-exexpr-gcc.adb (Setup_Exception): Removed.
3351 * a-except.adb (Exception_Propagation): Removed.
3352 * a-except-2005.adb (Setup_Exception): Removed.
3353 (Reraise): Remove call to Setup_Exception.
3354 (Reraise_Occurrence): Ditto.
3355 (Reraise_Occurrence_Always): Ditto.
3356 (Reraise_Occurrence_No_Defer): Ditto.
3357 (Transfer_Occurrence): Ditto.
3358 * a-exexda.adb (Set_Exception_C_Msg): Remove call to Setup_Exception.
3359 (Set_Exception_Msg): Ditto.
3360
3361 2011-08-29 Robert Dewar <dewar@adacore.com>
3362
3363 * a-convec.adb, exp_disp.adb: Minor reformatting.
3364
3365 2011-08-29 Tristan Gingold <gingold@adacore.com>
3366
3367 * a-exexpr-gcc.adb (GNAT_GCC_Exception_Access): Set to convention C.
3368
3369 2011-08-29 Gary Dismukes <dismukes@adacore.com>
3370
3371 * exp_ch3.adb (Build_Record_Init_Proc.Build_Init_Procedure): Set
3372 Exception_Handlers to No_List instead of Empty_List in the case where
3373 there are no handlers.
3374
3375 2011-08-29 Tristan Gingold <gingold@adacore.com>
3376
3377 * gcc-interface/gigi.h (enum standard_datatypes): Add
3378 ADT_reraise_zcx_decl
3379 (reraise_zcx_decl): New macro.
3380 * gcc-interface/trans.c (gnu_incoming_exc_ptr): New variable.
3381 (gigi): Set reraise_zcx_decl.
3382 (Exception_Handler_to_gnu_zcx): Save and restore gnu_incoming_exc_ptr.
3383 (gnat_to_gnu): Handle N_Raise_Statement.
3384
3385 2011-08-29 Robert Dewar <dewar@adacore.com>
3386
3387 * sem_ch6.adb, exp_ch3.adb, s-stposu.adb, a-undesu.ads,
3388 a-undesu.adb: Minor reformatting.
3389
3390 2011-08-29 Ed Schonberg <schonberg@adacore.com>
3391
3392 * exp_disp.adb (Check_Premature_Freezing): When building a dispatch
3393 table, accept an unfrozen untagged component if it is an actual for a
3394 formal incomplete type.
3395 * a-convec.ads, a-convec.adb: Instantiate Ada.Iterator_Interfaces to
3396 provide new iterator forms over vectors.
3397 Introduce type Iterator in package body to implement operations of
3398 Reversible_Iterator interface.
3399 * a-iteint.ads: Make package pure so it is usable with new container
3400 packages, that are categorized Remote_Types.
3401
3402 2011-08-29 Robert Dewar <dewar@adacore.com>
3403
3404 * a-exexpr-gcc.adb, a-synbar.adb, sem_ch13.adb: Minor reformatting.
3405
3406 2011-08-29 Bob Duff <duff@adacore.com>
3407
3408 * sem_aggr.adb (Resolve_Aggr_Expr): Call this routine even in the case
3409 of <>, because this is the routine that checks for dimensionality
3410 errors (for example, for a two-dimensional array, (others => <>) should
3411 be (others => (others => <>)).
3412
3413 2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
3414
3415 * impunit.adb: Add new run-time units.
3416 * freeze.adb, exp_ch7.ads, exp_ch7.adb, exp_util.ads, exp_util.adb,
3417 s-stposu.ads, s-stposu.adb: Code clean up.
3418 Handle protected class-wide or task class-wide types
3419 Handle C/C++/CIL/Java types.
3420 * s-spsufi.adb, s-spsufi.ads: New files.
3421
3422 2011-08-29 Yannick Moy <moy@adacore.com>
3423
3424 * sem_ch13.adb (Analyze_Aspect_Specifications): Reject test-case on
3425 library-level subprogram.
3426 * sem_prag.adb (Check_Test_Case): Stricter rules for test-case
3427 placement.
3428 (Analyze_Pragma): Change name "Normal" for "Nominal" in test-case
3429 component.
3430 * snames.ads-tmpl: Change name "Normal" for "Nominal" in test-case
3431 component.
3432 * gnat_rm.texi: Update doc for Test_Case pragma.
3433
3434 2011-08-29 Tristan Gingold <gingold@adacore.com>
3435
3436 * a-exexpr-gcc.adb (Unwind_Exception): Remove default value, made it
3437 convention C.
3438 (GCC_Exception_Access): New type.
3439 (Unwind_DeleteException): New imported procedure
3440 (Foreign_Exception): Import it.
3441 (GNAT_GCC_Exception): Simply have the occurrence inside.
3442 (To_GCC_Exception): New function.
3443 (To_GNAT_GCC_Exception): New function.
3444 (GNAT_GCC_Exception_Cleanup): New procedure..
3445 (Propagate_GCC_Exception): New procedure.
3446 (Reraise_GCC_Exception): New procedure.
3447 (Setup_Current_Excep): New procedure.
3448 (CleanupUnwind_Handler): Change type of UW_Exception parameter.
3449 (Unwind_RaiseException): Ditto.
3450 (Unwind_ForcedUnwind): Ditto.
3451 (Remove): Removed.
3452 (Begin_Handler): Change type of parameter.
3453 (End_Handler): Ditto. Now delete the exception if still present.
3454 (Setup_Key): Removed.
3455 (Is_Setup_And_Not_Propagated): Removed.
3456 (Set_Setup_And_Not_Propagated): Ditto.
3457 (Clear_Setup_And_Not_Propagated): Ditto.
3458 (Save_Occurrence_And_Private): Ditto.
3459 (EID_For): Add 'not null' constraint on parameter.
3460 (Setup_Exception): Does nothing.
3461 (Propagate_Exception): Simplified.
3462 * exp_ch11.adb (Expand_N_Raise_Statement): In back-end exception model,
3463 re-raise is not expanded anymore.
3464 * s-except.ads (Foreign_Exception): New exception - placeholder for
3465 non Ada exceptions.
3466 * raise-gcc.c (__gnat_setup_current_excep): Declare
3467 (CXX_EXCEPTION_CLASS): Define (not yet used)
3468 (GNAT_EXCEPTION_CLASS): Define.
3469 (is_handled_by): Handle foreign exceptions.
3470 (PERSONALITY_FUNCTION): Call __gnat_setup_current_excep.
3471
3472 2011-08-29 Jose Ruiz <ruiz@adacore.com>
3473
3474 * a-synbar.adb (Synchronous_Barrier): Some additional clarification.
3475
3476 2011-08-29 Thomas Quinot <quinot@adacore.com>
3477
3478 * a-synbar-posix.adb: Minor reformatting.
3479
3480 2011-08-29 Jose Ruiz <ruiz@adacore.com>
3481
3482 * a-exetim-posix.adb, a-exetim-mingw.adb, a-exetim-mingw.ads,
3483 a-exetim-default.ads (Interrupt_Clocks_Supported,
3484 Separate_Interrupt_Clocks_Supported, Clock_For_Interrupts): Add these
3485 definitions to be compliant with AI-0171. The target systems do not
3486 support separate account for the execution time of interrupt handlers.
3487
3488 2011-08-29 Jose Ruiz <ruiz@adacore.com>
3489
3490 * a-synbar.adb (Wait): Change the order of evaluation of the conditions
3491 in the barrier to put first the easiest to evaluate (and the one which
3492 will be True more often). More efficient.
3493
3494 2011-08-29 Eric Botcazou <ebotcazou@adacore.com>
3495
3496 * s-atocou-x86.adb: Fix constraint in machine code insertion.
3497
3498 2011-08-29 Bob Duff <duff@adacore.com>
3499
3500 * aspects.ads, aspects.adb: Add new aspects for various pragmas and
3501 attributes that are now aspects, as specified by AI05-0229-1.
3502 * sem_ch13.adb (Analyze_Aspect_Specifications,
3503 Check_Aspect_At_Freeze_Point): Analyze the new aspects. Turn them into
3504 pragmas or attribute references, as appropriate.
3505
3506 2011-08-29 Robert Dewar <dewar@adacore.com>
3507
3508 * a-synbar.ads, a-synbar.adb, a-synbar-posix.adb,
3509 a-synbar-posix.ads: Minor reformatting.
3510
3511 2011-08-29 Yannick Moy <moy@adacore.com>
3512
3513 * snames.ads-tmpl: Add name Force.
3514
3515 2011-08-29 Pascal Obry <obry@adacore.com>
3516
3517 * prj-nmsc.adb: Minor reformatting.
3518
3519 2011-08-29 Jose Ruiz <ruiz@adacore.com>
3520
3521 * a-exetim.ads (Interrupt_Clocks_Supported,
3522 Separate_Interrupt_Clocks_Supported, Clock_For_Interrupts): Add these
3523 definitions to be compliant with AI-0171.
3524
3525 2011-08-29 Robert Dewar <dewar@adacore.com>
3526
3527 * a-ngelfu.adb: Add comments.
3528
3529 2011-08-29 Geert Bosch <bosch@adacore.com>
3530
3531 * a-ngelfu.adb (Tan): Do not raise Constraint_Error if the argument is
3532 the closest machine number to Pi / 2.0.
3533
3534 2011-08-29 Jose Ruiz <ruiz@adacore.com>
3535
3536 * impunit.adb (Non_Imp_File_Names_12): Add a-synbar for new Ada 2012
3537 package Ada.Synchronous_Barriers.
3538 * a-synbar.ads, a-synbar.adb, a-synbar-posix.ads, a-synbar-posix.adb:
3539 Add new specs and bodies for Ada.Synchronous_Barriers. There is a
3540 default implementation using protected objects and another one
3541 a-synbar-posix using POSIX barriers as the underlying support.
3542 * gcc-interface/Makefile.in (LIBGNAT_TARGET_PAIRS for Linux (x86,
3543 x86_64, ia64) and MIPS IRIX): Use the a-synbar-posix implementation of
3544 Ada.Synchronous_Barriers which uses POSIX barriers (more efficient).
3545 Clean up dependencies.
3546 * Makefile.rtl (GNATRTL_TASKING_OBJS): Add a-synbar.o
3547
3548 2011-08-29 Robert Dewar <dewar@adacore.com>
3549
3550 * sem_ch7.adb, make.adb, sem_res.adb, exp_intr.adb,
3551 exp_dist.adb: Minor code reorganization.
3552 Minor reformatting.
3553
3554 2011-08-29 Thomas Quinot <quinot@adacore.com>
3555
3556 * sem_cat.adb (Validate_RACW_Primitive): The return type of an RACW
3557 primitive operation must support external streaming if it is not a
3558 controlling access result.
3559
3560 2011-08-29 Thomas Quinot <quinot@adacore.com>
3561
3562 * sinfo.ads, sem_ch7.adb: Minor reformatting.
3563
3564 2011-08-29 Bob Duff <duff@adacore.com>
3565
3566 * sem_ch4.adb (Analyze_Allocator): Check No_Nested_Finalization
3567 restriction on allocators, as required by AI05-0013-1.
3568 * restrict.ads: Minor comment fix.
3569
3570 2011-08-29 Tristan Gingold <gingold@adacore.com>
3571
3572 * a-exexpr.adb, a-except-2005.ads (Jmpbuf_Address): Move to a-exexpr.adb
3573 (To_Jmpbuf_Address): Ditto
3574 (builtin_longjmp): Ditto
3575
3576 2011-08-29 Thomas Quinot <quinot@adacore.com>
3577
3578 * sem_res.adb: Minor reformatting.
3579
3580 2011-08-29 Vincent Celier <celier@adacore.com>
3581
3582 * make.adb (Gnatmake): Move special processing for VM targets after the
3583 call to Get_Target_Parameters.
3584
3585 2011-08-29 Thomas Quinot <quinot@adacore.com>
3586
3587 * sem_ch12.adb, par-ch12.adb: Minor reformatting.
3588
3589 2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
3590
3591 * sem_res.adb (Resolve_Allocator): Implement Ada2012-B052. Detect cases
3592 where an anonymous access discriminant of a limited designated type
3593 appears in a non-immutably limited discriminated type and issue an
3594 error message. Add local variable Desig_T and replace all occurrences
3595 of Designated_Type.
3596
3597 2011-08-29 Jose Ruiz <ruiz@adacore.com>
3598
3599 * a-rttiev.adb (Set_Handler): Update comment to indicate that our
3600 implementation is compliant to RM D.15(15/2) after the modification
3601 imposed by AI05-0094-1 (binding interpretation).
3602
3603 2011-08-29 Robert Dewar <dewar@adacore.com>
3604
3605 * exp_ch9.adb, s-tasren.adb, exp_sel.adb, exp_sel.ads, exp_ch11.adb,
3606 s-interr-hwint.adb, s-tpobop.adb, sem_ch13.adb: Minor reformatting.
3607
3608 2011-08-29 Thomas Quinot <quinot@adacore.com>
3609
3610 * par-endh.adb (Check_End): For an END where it is mandatory to repeat
3611 the scope name, do not report a missing label as a style violation (it
3612 will be diagnosed as an illegality).
3613 * exp_dist.adb (Add_Params_For_Variant_Components): Fix handling of
3614 variant records: Get_Enum_Lit_From_Pos already returns a usage
3615 occurrence of the literal, no need to use New_Occurrence_Of. Set Etype
3616 on Expr in Integer_Literal case so that it can be used by
3617 Build_To_Any_Call.
3618
3619 2011-08-29 Tristan Gingold <gingold@adacore.com>
3620
3621 * exp_sel.ads (Build_Abort_BLock_Handler): New function spec.
3622 Adjust comment.
3623 * exp_sel.adb (Build_Abort_Block): Use Build_Abort_Block_Handler.
3624 (Build_Abort_Block_Handler): New function to build an Abort_Signal
3625 exception handler.
3626 * exp_ch9.adb (Expand_N_Asynchronous_Select): Call
3627 Build_Abort_Block_Handler to build the exception handler. Do not
3628 undefer aborts for the Abort_Signal exception handler if back-end
3629 exception mechanism.
3630 * exp_ch11.adb (Expand_Exception_Handlers): Do not undefer aborts if
3631 back_end exceptions for all others and abort_signal.
3632 * s-except.ads (ZCX_By_Default): New constant.
3633 * a-except-2005.adb (Raise_Exception): Do not defer abort if ZCX.
3634 (Raise_Exception_Always): Ditto.
3635 (Raise_From_Signal_Handler): Ditto.
3636 (Raise_With_Location_And_Msg): Ditto.
3637 (Raise_With_Msg): Ditto.
3638 (Reraise): Ditto.
3639 (Reraise_Occurence): Ditto.
3640 (Reraise_Occurrence_Always): Ditto.
3641 * s-tasren.adb (Exceptional_Complete_Rendezvous): Defer aborts if ZCX.
3642 * s-tpobop.adb: (Exceptional_Complete_Body): Undefer abort if ZCX.
3643
3644 2011-08-29 Thomas Quinot <quinot@adacore.com>
3645
3646 * sem_util.ads (Get_Enum_Lit_From_Pos): Clarify documentation.
3647
3648 2011-08-29 Robert Dewar <dewar@adacore.com>
3649
3650 * snames.adb-tmpl, sem_ch13.adb: Minor reformatting
3651 Minor code reorganization.
3652
3653 2011-08-29 Bob Duff <duff@adacore.com>
3654
3655 * usage.adb (-gnatwy): Fix documentation: this switch applies to Ada
3656 2012, not just Ada 2005.
3657
3658 2011-08-29 Vincent Celier <celier@adacore.com>
3659
3660 * gnat_ugn.texi: Indicate that when the compiler is called by gnatmake
3661 with a project file or with gprbuid, if -gnatep= is specified, the
3662 builder may need to be invoked with -x.
3663
3664 2011-08-29 Tristan Gingold <gingold@adacore.com>
3665
3666 * a-exexpr-gcc.adb: Minor comment fix.
3667
3668 2011-08-29 Robert Dewar <dewar@adacore.com>
3669
3670 * sem_ch8.adb: Minor reformatting.
3671
3672 2011-08-29 Bob Duff <duff@adacore.com>
3673
3674 * par-ch2.adb (P_Identifier): Warn that "some" is reserved in Ada 2012.
3675 * par-ch4.adb (P_Quantified_Expression): Remove unnecessary code for
3676 treating "some" as unreserved in earlier Ada versions. This is now
3677 handled in Snames.Is_Keyword_Name. Parse "for some" using Tok_Some,
3678 rather than Name_Some, since Tok_Some is now recognized as reserved.
3679 * scans.adb (Initialize_Ada_Keywords): Handle Tok_Some like any other
3680 reserved word.
3681 * scans.ads: Minor comment fixes.
3682 * snames.adb-tmpl (Is_Keyword_Name): Handle Ada 2012 reserved words as
3683 for other language versions.
3684 * scn.adb (Scan_Reserved_Identifier): Remove unnecessary code for
3685 treating "some" as unreserved in earlier Ada versions. This is now
3686 handled in Snames.Is_Keyword_Name.
3687 * par-ch3.adb (P_Defining_Identifier): Warn that "some" is reserved in
3688 Ada 2012.
3689 (P_Subtype_Mark_Resync): Remove unnecessary code for treating "some" as
3690 unreserved in earlier Ada versions. This is now handled in
3691 Snames.Is_Keyword_Name.
3692 * snames.ads-tmpl (Ada_2012_Reserved_Words): Handle Ada 2012 reserved
3693 words as for other language versions.
3694 * gnat_ugn.texi (-gnatwy): Fix documentation: this switch applies to
3695 Ada 2012, not just Ada 2005.
3696
3697 2011-08-29 Ed Schonberg <schonberg@adacore.com>
3698
3699 * sem_ch13.adb: Additional semantic checks for aspects involved in
3700 iterators.
3701
3702 2011-08-29 Matthew Heaney <heaney@adacore.com>
3703
3704 * a-comutr.ads, a-comutr.adb, a-cimutr.ads, a-cimutr.adb,
3705 a-cbmutr.ads, a-cbmutr.adb (Find_In_Subtree): Remove superfluous
3706 Container parameter.
3707 (Ancestor_Find): ditto.
3708
3709 2011-08-29 Thomas Quinot <quinot@adacore.com>
3710
3711 * par-endh.adb: Minor reformatting.
3712
3713 2011-08-29 Tristan Gingold <gingold@adacore.com>
3714
3715 * a-exexpr-gcc.adb (Unwind_Action) Rewrite as an integer with constants.
3716 (GNAT_GCC_Exception): Remove N_Cleanups_To_Trigger component.
3717 (Adjust_N_CLeanups_For): Remove.
3718 (CleanupUnwind_Handler): Call Unhandled_Exception_Terminate when end of
3719 stack is reached.
3720 (Propgate_Exception): Adjust.
3721 * raise-gcc.c: Add a few static/const.
3722 (Adjust_N_Cleanups_For): Remove declaration.
3723 (PERSONALITY_FUNCTION): Remove code dealing with N_Cleanups_To_Trigger.
3724
3725 2011-08-29 Ed Schonberg <schonberg@adacore.com>
3726
3727 * sem_ch8.adb: Use type of function return when rewriting as object
3728 declaration.
3729
3730 2011-08-29 Gary Dismukes <dismukes@adacore.com>
3731
3732 * sem_type.adb: Minor reformatting.
3733
3734 2011-08-29 Robert Dewar <dewar@adacore.com>
3735
3736 * makeutl.adb: Minor reformatting.
3737
3738 2011-08-29 Ed Schonberg <schonberg@adacore.com>
3739
3740 * sem_ch8.adb (Analyze_Object_Renaming): If the renamed object is a
3741 function call of a limited type, the expansion of the renaming is
3742 complicated by the presence of various temporaries and subtypes that
3743 capture constraints of the renamed object.
3744 Rewrite node as an object declaration, whose expansion is simpler.
3745 Given that the object is limited there is no copy involved and no
3746 performance hit.
3747
3748 2011-08-29 Robert Dewar <dewar@adacore.com>
3749
3750 * exp_ch5.adb, sinfo.ads, make.adb, s-pooglo.adb, sem_ch12.adb,
3751 freeze.adb, sem_ch6.adb, par-ch12.adb: Minor reformatting.
3752
3753 2011-08-29 Tristan Gingold <gingold@adacore.com>
3754
3755 * system-darwin-x86.ads, system-linux-s390x.ads, system-linux-alpha.ads,
3756 system-tru64.ads, system-irix-n32.ads, system-vxworks-arm.ads,
3757 system-linux-hppa.ads, system-linux-s390.ads,
3758 system-solaris-sparcv9.ads, system-mingw.ads, system-linux-ia64.ads,
3759 system-vms_64.ads, system-vxworks-sparcv9.ads, system-linux-ppc.ads,
3760 system-aix64.ads, system-lynxos-ppc.ads, system-linux-sh4.ads,
3761 system-solaris-x86.ads, system-linux-x86_64.ads, system-linux-x86.ads,
3762 system-vxworks-ppc.ads, system-hpux.ads, system-darwin-ppc.ads,
3763 system-solaris-sparc.ads, system-lynxos-x86.ads,
3764 system-vxworks-m68k.ads, system-hpux-ia64.ads, system-irix-o32.ads,
3765 system-solaris-x86_64.ads, system-mingw-x86_64.ads,
3766 system-vxworks-mips.ads, system-linux-sparc.ads, system-vms-ia64.ads,
3767 system-freebsd-x86.ads, system-aix.ads, system-darwin-x86_64.ads,
3768 system-vxworks-x86.ads: Remove GCC_ZCX_Support.
3769 * s-taprop-posix.adb, s-taprop-irix.adb, s-taprop-vxworks.adb,
3770 s-taprop-tru64.adb, s-taprop-linux.adb, s-taprop-solaris.adb: Ditto.
3771 * opt.ads: Adjust comment.
3772 * targparm.ads, targparm.adb: Remove GCC_ZCX_Support_On_Target.
3773 * gnat1drv.adb: Do not check for GCC_ZCX_Support_On_Target.
3774 * system.ads: Move GCC_ZCX_Support to obsolete entries.
3775
3776 2011-08-29 Emmanuel Briot <briot@adacore.com>
3777
3778 * makeutl.adb (Do_Complete): Resolve symbolic links when a relative
3779 file name is specified on the gnatmake or gprbuild command line, and
3780 before we search for that file in the project.
3781
3782 2011-08-29 Ed Schonberg <schonberg@adacore.com>
3783
3784 * sem_type.adb (Within_Instance): New predicate in Collect_Interps,
3785 used to determine whether a possible interpretation for an overloadable
3786 entity is declared within the current instantiation and should be
3787 included in the candidate set.
3788
3789 2011-08-29 Vasiliy Fofanov <fofanov@adacore.com>
3790
3791 * gnat_rm.texi, gnat_ugn.texi: Clean ups.
3792
3793 2011-08-29 Ed Schonberg <schonberg@adacore.com>
3794
3795 * sem_res.adb (Resolve_Actuals): Use base type to determine whether an
3796 access subtype is access_to_subprogram, when applying checks for
3797 RM 3.10.2 (27).
3798
3799 2011-08-29 Matthew Heaney <heaney@adacore.com>
3800
3801 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Splice_Subtree): Only check
3802 for sibling when common parent.
3803
3804 2011-08-29 Thomas Quinot <quinot@adacore.com>
3805
3806 * get_scos.adb: Literals of Pragma_Id are pragma names prefixed with
3807 "pragma_".
3808
3809 2011-08-29 Ed Schonberg <schonberg@adacore.com>
3810
3811 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Enable freeze actions
3812 for the return type when in ASIS mode.
3813
3814 2011-08-29 Vincent Celier <celier@adacore.com>
3815
3816 * make.adb (Gnatmake): Get the default search dirs, then the target
3817 parameters after getting the Builder switches, as the Builder switches
3818 may include --RTS= and that could change the default search dirs.
3819
3820 2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
3821
3822 * exp_ch7.adb (Make_Adjust_Call): Rewrite to mimic the structure of
3823 Make_Final_Call. Move the processing for class-wide types before the
3824 processing for derivations from [Limited_]Controlled.
3825 (Make_Final_Call): Move the processing for class-wide types before the
3826 processing for derivations from [Limited_]Controlled.
3827 * s-stposu.adb (Allocate_Any_Controlled): Correct the membership check.
3828 Add code to account for alignments larger than the list header. Add a
3829 comment illustrating the structure of the allocated object + padding +
3830 header.
3831 (Deallocate_Any_Controlled): Add code to account for alignments larger
3832 than the list header.
3833
3834 2011-08-29 Ed Schonberg <schonberg@adacore.com>
3835
3836 * sinfo.ads, sinfo.adb: New node kind
3837 N_Formal_Incomplete_Type_Definition, related flags.
3838 par-ch12.adb (P_Formal_Type_Declaration, G_Formal_Type_Definition):
3839 Parse formal incomplete types.
3840 * sem.adb (Analyze): Formal_Incomplete_Type_Definitions are handled in
3841 sem_ch12.
3842 * sem_ch7.adb (Analyze_Package_Specification, Unit_Requires_Body):
3843 Formal incomplete types do not need completion.
3844 * sem_ch12.adb (Analyze_Formal_Incomplete_Type,
3845 Validate_Incomplete_Type_Instance): New procedures to handle formal
3846 incomplete types.
3847 * freeze.adb (Freeze_Entity): Do not freeze the subtype of an actual
3848 that corresponds to a formal incomplete type.
3849 * sprint.adb: Handle formal incomplete type declarations.
3850 * exp_util.adb (Insert_Actions): An incomplete_type_definition is not
3851 an insertion point.
3852
3853 2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
3854
3855 * a-fihema.ads, a-fihema.adb: Unit removed.
3856 * a-undesu.ads, a-undesu.adb: New unit implementing
3857 Ada.Unchecked_Deallocate_Subpool.
3858 * einfo.adb: Remove Associated_Collection from the node usage.
3859 Add Finalization_Master to the node usage.
3860 (Associated_Collection): Removed.
3861 (Finalization_Master): New routine.
3862 (Set_Associated_Collection): Removed.
3863 (Set_Finalization_Master): New routine.
3864 (Write_Field23_Name): Remove Associated_Collection from the output. Add
3865 Finalization_Master to the output.
3866 * einfo.ads: Remove attribute Associated_Collection and its uses in
3867 entities.
3868 Add new attribute Finalization_Master along with its uses in entitites.
3869 (Associated_Collection): Removed along with its pragma import.
3870 (Finalization_Master): New routine along with a pragma import.
3871 (Set_Associated_Collection): Removed along with its pragma import.
3872 (Set_Finalization_Master): New routine along with a pragma import.
3873 * exp_ch3.adb (Expand_Freeze_Array_Type): Replace call to
3874 Build_Finalization_Collection with Build_Finalization_Master.
3875 (Expand_Freeze_Record_Type): Move the generation of Finalize_Address
3876 before the bodies of the predefined routines. Add comment explaining
3877 this. Replace call to Build_Finalization_Collection with
3878 Build_Finalization_Master.
3879 (Freeze_Type): Replace call to Build_Finalization_Collection with
3880 Build_Finalization_Master.
3881 (Make_Finalize_Address_Body): Comment reformatting.
3882 (Make_Predefined_Primitive_Specs): Code reformatting.
3883 (Stream_Operation_OK): Update comment mentioning finalization
3884 collections. Replace RE_Finalization_Collection with
3885 RE_Finalization_Master.
3886 * exp_ch4.adb (Complete_Controlled_Allocation): Replace call to
3887 Associated_Collection with Finalization_Master. Replace call to
3888 Build_Finalization_Collection with Build_Finalization_Master.
3889 (Expand_Allocator_Expression): Replace call to Associated_Collection
3890 with Finalization_Master. Replace call to Set_Associated_Collection with
3891 Set_Finalization_Master. Remove the generation of
3892 Set_Finalize_Address_Ptr.
3893 (Expand_N_Allocator): Replace call to Associated_Collection with
3894 Finalization_Master. Remove the generation of Set_Finalize_Address_Ptr.
3895 * exp_ch6.adb (Add_Collection_Actual_To_Build_In_Place_Call): Renamed to
3896 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Update the
3897 comment on usage. Replace call to Needs_BIP_Collection with
3898 Needs_BIP_Finalization_Master Remplace BIP_Collection with
3899 BIP_Finalization_Master. Update all comments which mention finalization
3900 collections. Replace Associated_Collection with
3901 Finalization_Master. Replace Build_Finalization_Collection with
3902 Build_Finalization_Master.
3903 (BIP_Formal_Suffix): Update BIP_Collection's case.
3904 (Build_Heap_Allocator): Update the related comment. Rename local
3905 variable Collect to Fin_Mas_Id and update its occurrences. Update
3906 comments which mention finalization collections. Replace
3907 Set_Associated_Collection with Set_Finalization_Master.
3908 (Expand_Call): Update the code which detects a special piece of library
3909 code for .NET/JVM.
3910 (Make_Build_In_Place_Call_In_Allocator): Replace the call to
3911 Add_Collection_Actual_To_Build_In_Place_Call with
3912 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Remove the code
3913 which generates a call to Make_Set_Finalize_Address_Ptr_Call.
3914 (Make_Build_In_Place_Call_In_Anonymous_Context): Replace call to
3915 Add_Collection_Actual_To_Build_In_Place_Call with
3916 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
3917 (Make_Build_In_Place_Call_In_Assignment): Replace call to
3918 Add_Collection_Actual_To_Build_In_Place_Call with
3919 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
3920 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
3921 * exp_ch6.ads: Rename BIP_Collection to BIP_Finalization_Master.
3922 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
3923 * exp_ch7.adb (Build_BIP_Cleanup_Stmts): Update comment on usage.
3924 Rename local variable Collect to Fin_Mas_Id and update its occurrences.
3925 Replace call to Set_Associated_Collection with Set_Finalization_Master.
3926 (Build_Finalization_Collection): Renamed to Build_Finalization_Master.
3927 Replace the call to Associated_Collection with Finalization_Master.
3928 Rename local variable Coll_Id to Fin_Mas_Id and update its occurrences.
3929 Update the way finalization master names are generated. Update the
3930 retrieval of the correct access type which will carry the pool and
3931 master attributes.
3932 (Make_Final_Call): Reimplement the way [Deep_]Finalize is retrieved.
3933 (Make_Finalize_Address_Body): Abstract types do not need
3934 Finalize_Address. Code reformatting.
3935 (Make_Finalize_Address_Stmts): Update comment on usage.
3936 (Make_Set_Finalize_Address_Ptr_Call): Removed.
3937 (Process_Declarations): Update comments.
3938 * exp_ch7.ads (Build_Finalization_Collection): Renamed to
3939 Build_Finalization_Master. Update associated comment.
3940 (Make_Set_Finalize_Address_Ptr_Call): Removed.
3941 * exp_ch13.adb: Update comments which mention finalization collections.
3942 (Expand_N_Free_Statement): Replace the call to Associated_Collection
3943 with Finalization_Master.
3944 * exp_util.adb (Build_Allocate_Deallocate_Proc): Reimplemented to
3945 create calls to routines Allocate_Any_Controlled and
3946 Deallocate_Any_Controlled.
3947 (Find_Finalize_Address): New routine.
3948 (Is_Allocate_Deallocate_Proc): Update the RTE entities used in the
3949 comparison.
3950 (Requires_Cleanup_Actions): Update the comment on freeze node
3951 inspection.
3952 * exp_util.ads: Remove comment on generated code for
3953 Build_Allocate_Deallocate_Proc. The code is now quite complex and it
3954 is better to simply look in the body.
3955 * freeze.adb (Freeze_All): Update the comment of finalization
3956 collections. Replace the call to Associated_Collection with
3957 Finalization_Master. Replace the call to Build_Finalization_Collection
3958 with Build_Finalization_Master.
3959 * impunit.adb: Add a-undesu and s-stposu to the list of units.
3960 * Makefile.rtl: Add files a-undesu, s-finmas and s-stposu. Remove file
3961 a-fihema.
3962 * rtsfind.adb (Get_Unit_Name): Remove the processing for children of
3963 Ada.Finalization. Add processing for children of System.Storage_Pools.
3964 * rtsfind.ads: Remove the naming of second level children of
3965 Ada.Finalization.
3966 Remove Ada_Finalization_Heap_Management from the list of units.
3967 Remove subtype Ada_Finalization_Child.
3968 Remove the following subprogram entities:
3969
3970 RE_Allocate
3971 RE_Deallocate
3972 RE_Finalization_Collection
3973 RE_Finalization_Collection_Ptr
3974 RE_Set_Finalize_Address_Ptr
3975
3976 Add the naming of second level children of System.Storage_Pools.
3977 Add System_Finalization_Masters and System_Storage_Pools_Subpools to
3978 the list of units.
3979 Add subtype System_Storage_Pools_Child.
3980 Add the following subprogram entities to System.Finalization_Masters:
3981
3982 RE_Finalization_Master
3983 RE_Finalization_Master_Ptr
3984
3985 Add the following subprogram entities to System.Storage_Pools.Subpools:
3986
3987 RE_Allocate_Any_Controlled
3988 RE_Deallocate_Any_Controlled
3989 RE_Root_Storage_Pool_With_Subpools
3990 RE_Root_Subpool
3991 RE_Subpool_Handle
3992
3993 Move the following subprogram entities from
3994 Ada.Finalization.Heap_Management to System.Finalization_Masters:
3995
3996 RE_Add_Offset_To_Address
3997 RE_Attach
3998 RE_Base_Pool
3999 RE_Detach
4000
4001 * sem_ch3.adb (Access_Type_Declaration): Replace the call to
4002 Set_Associated_Collection with Set_Finalization_Master.
4003 * sem_ch6.adb (Create_Extra_Formals): Update the way extra formal
4004 BIP_Finalization_Master is created.
4005 * s-finmas.adb: New unit System.Finalization_Masters.
4006 * s-finmas.ads: New unit System.Finalization_Masters.
4007 * s-stopoo.ads, s-stopoo.adb: Minor code reformatting.
4008 * s-stposu.ads, s-stposu.adb: New unit implementing
4009 System.Storage_Pools.Subpools.
4010
4011 2011-08-29 Bob Duff <duff@adacore.com>
4012
4013 * tbuild.adb: Add assertion.
4014
4015 2011-08-29 Thomas Quinot <quinot@adacore.com>
4016
4017 * s-pooglo.adb: Minor reformatting.
4018
4019 2011-08-29 Ed Schonberg <schonberg@adacore.com>
4020
4021 * exp_ch5.adb (Expand_N_Assignment_Statement): if the left-hand side is
4022 an indexed component of a packed array whose element type is a record
4023 with a representation clause different from that of the right-hand
4024 side, generate a temporary to minimuze the number of bit-field
4025 operations generated.
4026
4027 2011-08-29 Ed Schonberg <schonberg@adacore.com>
4028
4029 * exp_util.adb (Insert_Actions): Use clauses can be part of lists of
4030 declarations, and thus are likely insertion points for actions.
4031
4032 2011-08-29 Bob Duff <duff@adacore.com>
4033
4034 * einfo.ads: Minor comment fix.
4035
4036 2011-08-29 Robert Dewar <dewar@adacore.com>
4037
4038 * frontend.adb, gnat1drv.adb: Minor reformatting.
4039
4040 2011-08-29 Tristan Gingold <gingold@adacore.com>
4041
4042 * s-pooglo.adb (Allocate, Deallocate): Take into account the alignment.
4043 * a-fihema.adb (Allocate, Deallocate): Ditto. Possibly add padding
4044 space in front of the header.
4045
4046 2011-08-29 Johannes Kanig <kanig@adacore.com>
4047
4048 * frontend.adb (Frontend): Exit after creating Standard package when
4049 -gnatd.H is present.
4050 * gnat1drv.adb (Gnat1drv): Call Backend right away when -gnatd.H is
4051 present.
4052
4053 2011-08-29 Robert Dewar <dewar@adacore.com>
4054
4055 * exp_ch9.adb, mlib-prj.adb, prj.adb, prj.ads, ttypes.ads, sem_ch4.adb,
4056 makeutl.adb, makeutl.ads, atree.ads, snames.adb-tmpl,
4057 snames.ads-tmpl: Minor reformatting.
4058
4059 2011-08-29 Philippe Gil <gil@adacore.com>
4060
4061 * prj.adb (Reset_Units_In_Table): New procedure.
4062 Reset units to avoid access to freed memory.
4063
4064 2011-08-29 Thomas Quinot <quinot@adacore.com>
4065
4066 * get_scos.adb: When reading a P statement SCO without a pragma name
4067 (from an older ALI file), ensure that the Pragma_Name component is set
4068 to Unknown_Pragma (not left uninitialized).
4069
4070 2011-08-29 Vincent Celier <celier@adacore.com>
4071
4072 * makeutl.adb (Get_Directories): New procedure moved from Buildgpr and
4073 modified to compute correctly the object path of a SAL project that is
4074 extending another library project.
4075 (Write_Path_File): New procedure.
4076 * makeutl.ads (Directories): New table moved from Buildgpr
4077 (Get_Directories): New procedure moved from Buildgpr
4078 (Write_Path_File): New procedure
4079 * mlib-prj.adb (Build_Library): Use Makeutl.Get_Directories to set the
4080 paths before binding SALs, instead of Set_Ada_Paths.
4081 * prj-env.adb (Set_Path_File_Var): Procedure has been moved to package
4082 Prj.
4083 * prj.adb (Set_Path_File_Var): New procedure moved from Prj.Env
4084 (Current_Source_Path_File_Of): New function
4085 (Set_Current_Object_Path_File_Of): New procedure
4086 (Current_Source_Object_File_Of): New function
4087 (Set_Current_Object_Path_File_Of): New procedure
4088 * prj.ads (Set_Path_File_Var): New procedure moved from Prj.Env
4089 (Current_Source_Path_File_Of): New function
4090 (Set_Current_Object_Path_File_Of): New procedure
4091 (Current_Source_Object_File_Of): New function
4092 (Set_Current_Object_Path_File_Of): New procedure
4093
4094 2011-08-29 Ed Schonberg <schonberg@adacore.com>
4095
4096 * exp_ch5.adb (Expand_N_Assignment_Statement): For an assignment to a
4097 packed entity, use a bit-field assignment only if there is no change of
4098 representation.
4099
4100 2011-08-29 Thomas Quinot <quinot@adacore.com>
4101
4102 * rtsfind.ads, exp_ch3.adb (In_Runtime): Minor code improvement, use
4103 Is_RTU instead of using Chars comparisons.
4104
4105 2011-08-29 Thomas Quinot <quinot@adacore.com>
4106
4107 * exp_strm.adb (Build_Mutable_Record_Read_Procedure): Do not create a
4108 temporary object if the actual is constrained, and the discriminants
4109 read from the stream don't match.
4110
4111 2011-08-29 Tristan Gingold <gingold@adacore.com>
4112
4113 * sem_attr.adb, exp_attr.adb: Add handling of
4114 Attribute_System_Allocator_Alignment
4115 * snames.ads-tmpl: Add Name_System_Allocator_Alignment and
4116 Attribute_System_Allocator_Alignment.
4117 * ttypes.ads, get_targ.ads: Add Get_System_Allocator_Alignment.
4118 * gcc-interface/targtyps.c, gcc-interface/utils2.c,
4119 gcc-interface/gigi.h: Renames get_target_default_allocator_alignment to
4120 get_target_system_allocator_alignment.
4121
4122 2011-08-29 Arnaud Charlet <charlet@adacore.com>
4123
4124 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
4125 dependencies.
4126
4127 2011-08-29 Arnaud Charlet <charlet@adacore.com>
4128
4129 * exp_ch3.adb (In_Runtime): Fix typo.
4130
4131 2011-08-29 Bob Duff <duff@adacore.com>
4132
4133 * sem_ch4.adb (Analyze_Allocator): Analyze the subpool specification.
4134
4135 2011-08-29 Ed Schonberg <schonberg@adacore.com>
4136
4137 * exp_ch3.adb (Expand_N_Object_Declaration): If the entity is tagged
4138 and a separate tag assignment is generated, ensure that the tag
4139 assignment is analyzed.
4140
4141 2011-08-29 Ed Schonberg <schonberg@adacore.com>
4142
4143 * atree.ads, atree.adb (Copy_Separate_List): New function that applies
4144 Copy_Separate_Tree to a list of nodes. Used to create disjoint copies
4145 of statement lists that may contain local declarations.
4146 * exp_ch9.adb (Expand_N_Timed_Entry_Call): Use Copy_Separate_List to
4147 duplicate the triggering statements needed for the expansion of this
4148 construct, when the trigger is a dispatching call to a synchronized
4149 primitive.
4150
4151 2011-08-29 Arnaud Charlet <charlet@adacore.com>
4152
4153 * gnat_rm.texi: Add doc for 'Elab_Subp_Body.
4154 * bindgen.adb: Add comments.
4155 * snames.adb-tmpl (Is_Attribute_Name): Only recognize 'Elab_Subp_Body
4156 in CodePeer mode.
4157
4158 2011-08-29 Robert Dewar <dewar@adacore.com>
4159
4160 * exp_attr.adb: Minor reformatting.
4161 Minor code reorganization and commenting.
4162 * par_sco.adb, checks.adb, sem_attr.adb, get_scos.adb: Minor
4163 reformatting.
4164
4165 2011-08-29 Thomas Quinot <quinot@adacore.com>
4166
4167 * get_scos.adb: Ignore chaining indicators not currently supported
4168 by Ada.
4169
4170 2011-08-29 Arnaud Charlet <charlet@adacore.com>
4171
4172 * system.ads: Minor editing.
4173
4174 2011-08-29 Arnaud Charlet <charlet@adacore.com>
4175
4176 * bindgen.adb (Gen_Elab_Calls): Generate calls to subp'Elab_Subp_Body in
4177 CodePeer mode.
4178 * sem_attr.ads, sem_attr.adb, exp_Attr.adb, sem_ch6.adb: Add handling of
4179 Attribute_Elab_Subp_Body.
4180 * snames.ads-tmpl (Attribute_Elab_Subp_Body, Name_Elab_Subp_Body): New.
4181 * sem_util.adb: Update comments.
4182
4183 2011-08-29 Thomas Quinot <quinot@adacore.com>
4184
4185 * par_sco.adb, scos.adb, scos.ads, put_scos.adb, get_scos.adb: Record
4186 pragma name for each SCO statement corresponding to a pragma.
4187
4188 2011-08-29 Arnaud Charlet <charlet@adacore.com>
4189
4190 * opt.ads: Minor editing.
4191
4192 2011-08-29 Yannick Moy <moy@adacore.com>
4193
4194 * gnat1drv.adb (Adjust_Global_Switches): Remove options for ALFA mode
4195 that only made sense for CodePeer mode.
4196
4197 2011-08-29 Jose Ruiz <ruiz@adacore.com>
4198
4199 * targparm.ads (Support_64_Bit_Divides_On_Target): Remove this flag
4200 which is no longer used.
4201 * targparm.adb (S64, S64_Str, Get_Target_Parameters): Remove the
4202 handling of the 64-bit division check.
4203 * exp_ch4.adb (Expand_N_Op_Divide): Remove the check for 64-bit
4204 division available.
4205 * system*.ads (Support_64_Bit_Divides): Remove this flag which is no
4206 longer used.
4207
4208 2011-08-29 Thomas Quinot <quinot@adacore.com>
4209
4210 * get_scos.adb: Minor reformatting.
4211
4212 2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4213
4214 * exp_util.adb (Process_Statements_For_Controlled_Objects): Whenever a
4215 statement list is wrapped in a block, the block is explicitly analyzed
4216 in order to properly redecorate the entities and create a servicing
4217 finalizer.
4218
4219 2011-08-29 Tristan Gingold <gingold@adacore.com>
4220
4221 * sinfo.ads, sinfo.adb (Zero_Cost_Handling): Remove.
4222 (Set_Zero_Cost_Handling): Remove.
4223
4224 2011-08-29 Thomas Quinot <quinot@adacore.com>
4225
4226 * par_sco.adb, scos.ads, put_scos.adb, get_scos.adb: Minor reformatting
4227
4228 2011-08-29 Geert Bosch <bosch@adacore.com>
4229
4230 * s-vaflop-vms-alpha.adb (Neg_F): Use subtraction instead of negation
4231 instruction, as the latter may produce -0.0, which is not a valid VAX
4232 F float number.
4233 (Neg_G): Likewise for VAX F float.
4234
4235 2011-08-29 Robert Dewar <dewar@adacore.com>
4236
4237 * exp_util.adb: Minor reformatting.
4238
4239 2011-08-29 Yannick Moy <moy@adacore.com>
4240
4241 * sem_ch3.adb: Minor comment update.
4242
4243 2011-08-29 Thomas Quinot <quinot@adacore.com>
4244
4245 * checks.adb (Apply_Type_Conversion_Checks): Use the Underlying_Type of
4246 the operand type.
4247
4248 2011-08-29 Thomas Quinot <quinot@adacore.com>
4249
4250 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not flush
4251 current statement sequence on a generic instantiation or a subprogram
4252 declaration.
4253
4254 2011-08-29 Robert Dewar <dewar@adacore.com>
4255
4256 * sem_type.adb, einfo.ads, freeze.adb, exp_ch4.adb, sem_ch13.adb:
4257 Minor reformatting.
4258
4259 2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4260
4261 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
4262 Correct the check which involves the freeze node of a controlled or
4263 access-to-controlled type.
4264
4265 2011-08-29 Geert Bosch <bosch@adacore.com>
4266
4267 * sem_warn.adb (Check_Code_Statement): Remove check for consecutive Asm
4268 statements.
4269 * s-vaflop-vms-alpha.adb: Remove bogus Volatile => True arguments from
4270 Asm statements.
4271
4272 2011-08-29 Yannick Moy <moy@adacore.com>
4273
4274 * sem_ch3.adb (Array_Type_Declaration): Insert a subtype declaration
4275 for every index type and component type that is not a subtype_mark.
4276 (Process_Subtype): Set Etype of subtype.
4277
4278 2011-08-29 Robert Dewar <dewar@adacore.com>
4279
4280 * a-cbmutr.adb, a-cimutr.adb, a-comutr.adb, prj-nmsc.adb: Minor code
4281 reorganization. Minor reformatting.
4282
4283 2011-08-29 Steve Baird <baird@adacore.com>
4284
4285 * exp_ch4.adb (Expand_N_Op_Expon): Suppress N_Op_Expon node expansion
4286 for CodePeer and ALFA modes.
4287
4288 2011-08-29 Ed Schonberg <schonberg@adacore.com>
4289
4290 * sem_type.adb (Collect_Interps): Within an instance, collect a homonym
4291 that comes from an enclosing scope if it is not the renaming of an
4292 actual, to handle properly a spurious ambiguity in an instance.
4293
4294 2011-08-29 Eric Botcazou <ebotcazou@adacore.com>
4295
4296 * sem_ch13.adb (Alignment_Check_For_Esize_Change): Rename to...
4297 (Alignment_Check_For_Size_Change): ...this. Add SIZE parameter and
4298 use it instead of the Esize of the first parameter.
4299 (Analyze_Attribute_Definition_Clause) <Object_Size>: Adjust call to
4300 above change.
4301 <Size>: Likewise. Call it for composite types on the RM size.
4302
4303 2011-08-29 Yannick Moy <moy@adacore.com>
4304
4305 * exp_ch4.adb (Expand_N_Op_Not): Do not expand not on array.
4306 * sem_util.adb (Unique_Name): Correct behaviour for names of
4307 compilation units.
4308
4309 2011-08-29 Yannick Moy <moy@adacore.com>
4310
4311 * sem_prag.adb (Check_Precondition_Postcondition): In formal
4312 verification mode, analyze pragma expression for correctness, for
4313 pre/post on library-level subprogram, as it is not expanded later.
4314
4315 2011-08-29 Yannick Moy <moy@adacore.com>
4316
4317 * exp_aggr.adb (Expand_Array_Aggregate): Do not expand array aggregates
4318 in formal verification.
4319
4320 2011-08-29 Thomas Quinot <quinot@adacore.com>
4321
4322 * sem_util.adb: Minor reformatting.
4323 * freeze.adb, sem_ch13.adb: Fix comment: Bit_Order is an attribute,
4324 there's no pragma.
4325 * par_sco.ads, par_sco.adb: Update comments.
4326
4327 2011-08-29 Yannick Moy <moy@adacore.com>
4328
4329 * einfo.adb, einfo.ads: Remove flag Is_Postcondition_Proc and
4330 associated getter/setter.
4331 * sem_ch6.adb: Remove reference to Is_Postcondition_Proc.
4332
4333 2011-08-29 Vincent Celier <celier@adacore.com>
4334
4335 * prj-attr.adb: New Compiler attribute Dependency_Kind and Language_Kind
4336 * prj-conf.adb: Add_Default_GNAT_Naming_Scheme: Add a package Compiler
4337 with declarations for Language_Kind and Dependency_Kind for Ada.
4338 * prj-nmsc.adb (Check_Unit_Name): New name of procedure Check_Ada_Name
4339 (Process_Compiler): Take into account the new attributes Dependency_Kind
4340 and Language_Kind.
4341 (Check_Configuration): Check if language kind is unit based, not if the
4342 language name is Ada.
4343 (Process_Exceptions_Unit_Based): Ditto
4344 (Add_Language): Remove default additions of language and dependency kind
4345 * prj.ads: Minor comment change
4346 * snames.ads-tmpl: New standard names Dependency_Kind and Language_Kind
4347
4348 2011-08-29 Johannes Kanig <kanig@adacore.com>
4349
4350 * debug.adb: Update comments.
4351
4352 2011-08-24 Joseph Myers <joseph@codesourcery.com>
4353
4354 * gcc-interface/Make-lang.in (CFLAGS-ada/tracebak.o)
4355 (CFLAGS-ada/targext.o, CFLAGS-ada/cio.o, CFLAGS-ada/init.o)
4356 (CFLAGS-ada/initialize.o, CFLAGS-ada/raise.o): New.
4357 (ada/tracebak.o, ada/targext.o, ada/cio.o, ada/init.o)
4358 (ada/initialize.o, ada/raise.o): Remove explicit compilation rules.
4359
4360 2011-08-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4361
4362 * gcc-interface/Makefile.in (PICFLAG_FOR_TARGET): New.
4363 (GNATLIBCFLAGS_FOR_C): Replace
4364 TARGET_LIBGCC2_CFLAGS by PICFLAG_FOR_TARGET.
4365 (gnatlib-shared-default, gnatlib-shared-dual-win32)
4366 (gnatlib-shared-win32, gnatlib-shared-darwin, gnatlib-shared)
4367 (gnatlib-sjlj, gnatlib-zcx): Likewise.
4368
4369 2011-08-07 Eric Botcazou <ebotcazou@adacore.com>
4370
4371 * gcc-interface/Makefile.in (raise-gcc.o): Fix previous change.
4372
4373 * gcc-interface/gigi.h (enumerate_modes): Fix formatting.
4374
4375 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Revert latest change.
4376
4377 2011-08-05 Nicolas Roche <roche@adacore.com>
4378
4379 * gcc-interface/Makefile.in: Don't use directly ../xgcc to build shared
4380 libgnat. Use rather the value of GCC_FOR_TARGET. Fix issue with
4381 canadian cross.
4382 * gcc-interface/Make-lang.in: Add support for canadian cross setting.
4383
4384 2011-08-05 Matthew Heaney <heaney@adacore.com>
4385
4386 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Child_Count, Child_Depth):
4387 subprogram bodies declared out-of-order.
4388
4389 2011-08-05 Yannick Moy <moy@adacore.com>
4390
4391 * sem_util.adb (Unique_Name): only prefix with "standard" the names of
4392 entities directly in package Standard, otherwise skip the standard
4393 prefix.
4394
4395 2011-08-05 Robert Dewar <dewar@adacore.com>
4396
4397 * a-cbmutr.adb: Minor reformatting
4398 (Allocate_Node): refactor node allocation algorithm
4399
4400 2011-08-05 Robert Dewar <dewar@adacore.com>
4401
4402 * opt.ads, opt.adb (Debug_Pragmas_Disabled): New switch.
4403 * sem_prag.adb (Analyze_Pragma, case Debug_Policy): Implement Disable
4404 mode.
4405 (Analyze_Pragma, case Check_Policy): Ditto.
4406 * sem_prag.ads (Check_Disabled): New function
4407 * snames.ads-tmpl: Add Name_Disable.
4408
4409 2011-08-05 Robert Dewar <dewar@adacore.com>
4410
4411 * gnat_rm.texi: Document implementation-defined policy DISABLE for
4412 pragmas Assertion_Policy, Check_Policy, Debug_Policy.
4413
4414 2011-08-05 Ed Schonberg <schonberg@adacore.com>
4415
4416 * sem_prag.adb (Analyze_Pragma, case Inline): reject an Inline pragma
4417 that appears in a generic formal part and applies to a formal
4418 subprogram.
4419
4420 2011-08-05 Robert Dewar <dewar@adacore.com>
4421
4422 * a-cbmutr.ads: Minor reformatting.
4423
4424 2011-08-05 Matthew Heaney <heaney@adacore.com>
4425
4426 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Read): do not use T'Valid
4427 to check count, check sign of value instead.
4428 * a-comutr.adb, a-cimutr.adb (Write): return immediately if tree empty
4429 (Copy_Subtree): allocate copy of source element
4430 (Equal_Subtree): compare elements, not access objects
4431
4432 2011-08-05 Vincent Celier <celier@adacore.com>
4433
4434 * gnat_ugn.texi: Fix VMS alternative.
4435
4436 2011-08-05 Thomas Quinot <quinot@adacore.com>
4437
4438 * sem_ch11.adb: Add comment.
4439
4440 2011-08-05 Robert Dewar <dewar@adacore.com>
4441
4442 * exp_util.adb: Minor comment fix.
4443
4444 2011-08-05 Robert Dewar <dewar@adacore.com>
4445
4446 * scng.adb (Error_Unterminated_String): Improve flag position when
4447 comma present.
4448
4449 2011-08-05 Matthew Heaney <heaney@adacore.com>
4450
4451 * Makefile.rtl, impunit.adb: Added a-cbmutr.ad[sb] (bounded multiway
4452 tree containers).
4453 * a-cbmutr.ads, a-cbmutr.adb: This is the new Ada 2012 unit for bounded
4454 multiway tree containers.
4455
4456 2011-08-05 Robert Dewar <dewar@adacore.com>
4457
4458 * styleg.adb (Check_Comment): Implement comment spacing of 1 or 2
4459 * stylesw.adb: Implement -gnatyC to control comment spacing
4460 * stylesw.ads (Style_Check_Comments_Spacing): New switch (set by
4461 -gnatyc/C).
4462 * usage.adb: Add line for -gnatyC.
4463
4464 2011-08-05 Robert Dewar <dewar@adacore.com>
4465
4466 * gnat_ugn.texi: Document -gnatyC.
4467 * vms_data.ads: Implement COMMENTS1/COMMENTS2 (retaining COMMENTS as a
4468 synonym for COMMENTS2).
4469
4470 2011-08-05 Robert Dewar <dewar@adacore.com>
4471
4472 * par_sco.adb, sem_ch3.adb, scos.ads, a-iteint.ads, sem_ch12.adb,
4473 a-cimutr.adb, a-cimutr.ads, sem_util.ads, sem_res.adb, a-fihema.adb,
4474 sem_ch4.adb, lib-xref-alfa.adb, exp_disp.adb, a-comutr.adb,
4475 a-comutr.ads, lib-xref.adb: Minor reformatting.
4476
4477 2011-08-05 Robert Dewar <dewar@adacore.com>
4478
4479 * sem_ch11.adb (Analyze_Raise_Statement): Kill assignment to formal
4480 warning if there is an exception handler present.
4481
4482 2011-08-05 Pascal Obry <obry@adacore.com>
4483
4484 * a-iteint.ads: Fix copyright year.
4485
4486 2011-08-05 Thomas Quinot <quinot@adacore.com>
4487
4488 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not generate a
4489 statement SCO for a USE clause or a representation clause.
4490
4491 2011-08-05 Yannick Moy <moy@adacore.com>
4492
4493 * lib-xref-alfa.adb (Collect_ALFA): generate the proper relation
4494 between body and spec for stub.
4495 (Detect_And_Add_ALFA_Scope): take into account subprogram stub
4496 * lib-xref.adb (Enclosing_Subprogram_Or_Package): in the case of a
4497 pragma precondition or postcondition, for which the enclosing
4498 subprogram or package in the AST is not the desired one, return empty.
4499
4500 2011-08-05 Thomas Quinot <quinot@adacore.com>
4501
4502 * g-expect.adb: Minor reformatting.
4503
4504 2011-08-05 Bob Duff <duff@adacore.com>
4505
4506 * a-fihema.adb: Comment out OS_Lib.
4507
4508 2011-08-05 Matthew Heaney <heaney@adacore.com>
4509
4510 * Makefile.rtl, impunit.adb: Added a-c[oi]mutr.ad[sb]
4511 (unbounded multiway tree containers) and a-iteint.ads.
4512 * a-comutr.ads, a-comutr.adb:
4513 This is the new Ada 2012 unit for unbounded multiway tree containers
4514 * a-cimutr.ads, a-cimutr.adb
4515 This is the new Ada 2012 unit for indefinite multiway tree containers
4516 * a-iteint.ads: New file.
4517
4518 2011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4519
4520 * gcc-interface/Makefile.in (raise-gcc.o): Search $(srcdir)/../libgcc.
4521
4522 2011-08-05 Bob Duff <duff@adacore.com>
4523
4524 * sinfo.ads, sinfo.adb (Subpool_Handle_Name): New attribute for
4525 subpools.
4526 * par-ch4.adb (P_Allocator): Parse new subpool specification syntax.
4527
4528 2011-08-05 Ed Schonberg <schonberg@adacore.com>
4529
4530 * sem_ch4.adb (Try_Container_Indexing): New procedure to implement the
4531 general indexing aspects of Ada2012. Called when analyzing indexed
4532 components when other interpretations fail.
4533 * sem_ch8.adb (Find_Direct_Name): check for implicit dereference only
4534 in an expression context where overloading is meaningful. This excludes
4535 the occurrence in an aspect specification (efficiency only).
4536 * sem_attr.adb (Analyze_Attribute): indicate that the attributes
4537 related to iterators can be set by an attribute specification, but
4538 cannot be queried.
4539 * sem_ch13.adb (Analyze_Aspect_Specifications): handle
4540 Constant_Indexing and Variable_Indexing.
4541 (Check_Indexing_Functions): New procedure to perform legality checks.
4542 Additional semantic checks at end of declarations.
4543
4544 2011-08-05 Sergey Rybin <rybin@adacore.com>
4545
4546 * tree_io.ads: Update ASIS_Version_Number because of the change of the
4547 order of calling Tree_Write/Tree_Read routines made for aspects.
4548
4549 2011-08-05 Bob Duff <duff@adacore.com>
4550
4551 * a-fihema.adb (Finalize): Fix race condition.
4552
4553 2011-08-05 Yannick Moy <moy@adacore.com>
4554
4555 * sem_ch12.adb (Analyze_Package_Instantiation,
4556 Need_Subprogram_Instance_Body): do not generate instance bodies in ALFA
4557 mode.
4558
4559 2011-08-05 Ed Schonberg <schonberg@adacore.com>
4560
4561 * sem_type.adb (Specific_Type): in an instance, the type-specific
4562 operand of an equality check that involves null may have a private
4563 type. Use full view to determine legality of construct.
4564
4565 2011-08-05 Vincent Celier <celier@adacore.com>
4566
4567 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
4568 delete or close the file when the call to gnatmake was successful.
4569
4570 2011-08-05 Yannick Moy <moy@adacore.com>
4571
4572 * gnat1drv.adb (Adjust_Global_Switches): in ALFA mode, set
4573 Global_Discard_Names.
4574
4575 2011-08-05 Ed Schonberg <schonberg@adacore.com>
4576
4577 * sinfo.ads: comments on use of entity field for aspect specifications.
4578
4579 2011-08-05 Ed Schonberg <schonberg@adacore.com>
4580
4581 * sem_ch12.adb (Reset_Entity): If the entity field of the associated
4582 node is not itself an entity but a selected component, it is a
4583 rewritten parameterless call to an en enclosing synchronized operation,
4584 and this expansion will be performed again in the instance, so there is
4585 no global information to preserve.
4586
4587 2011-08-05 Javier Miranda <miranda@adacore.com>
4588
4589 * exp_disp.adb (Set_All_DT_Position): Cleanup code and improve support
4590 for renamings of predefined primitives.
4591 (In_Predef_Prims_DT): New subprogram.
4592
4593 2011-08-05 Ed Schonberg <schonberg@adacore.com>
4594
4595 * sem_util.adb, sem_util.ads (Check_Implicit_Dereference): If a
4596 possible interpretation of name is a reference type, add an
4597 interpretation that is the designated type of the reference
4598 discriminant of that type.
4599 * sem_res.adb (resolve): If the interpretation imposed by context is an
4600 implicit dereference, rewrite the node as the deference of the
4601 reference discriminant.
4602 * sem_ch3.adb (Analyze_Subtype_Declaration, Build_Derived_Record_Type,
4603 Build_Discriminated_Subtype): Inherit Has_Implicit_Dereference from
4604 parent type or base type.
4605 * sem_ch4.adb (Process_Indexed_Component,
4606 Process_Overloaded_Indexed_Component, Indicate_Name_And_Type,
4607 Analyze_Overloaded_Selected_Component, Analyze_Selected_Component):
4608 Check for implicit dereference.
4609 (List_Operand_Interps): Indicate when an implicit dereference is
4610 ambiguous.
4611 * sem_ch8.adb (Find_Direct_Name): Check for implicit dereference.
4612
4613 2011-08-05 Thomas Quinot <quinot@adacore.com>
4614
4615 * scos.ads: Update documentation of SCO table. Pragma statements can now
4616 be marked as disabled (using 'p' instead of 'P' as the statement kind).
4617 * par_sco.ads, par_sco.adb: Implement the above change.
4618 (Process_Decisions_Defer): Generate a P decision for the first parameter
4619 of a dyadic pragma Debug.
4620 * sem_prag.adb (Analyze_Pragma, case Debug): Mark pragma as enabled if
4621 necessary.
4622 * put_scos.adb: Code simplification based on above change.
4623
4624 2011-08-05 Robert Dewar <dewar@adacore.com>
4625
4626 * sem_ch3.adb, gnatcmd.adb, switch-c.adb, exp_attr.adb, make.adb,
4627 bindgen.adb, einfo.adb, sem_ch12.adb, sem_attr.adb, a-fihema.adb,
4628 a-fihema.ads, sem_elab.adb, sem_elab.ads, aspects.adb, opt.ads,
4629 prj-conf.adb, sem_ch13.adb, s-ficobl.ads: Minor reformatting
4630
4631 2011-08-05 Bob Duff <duff@adacore.com>
4632
4633 * a-stunau.ads, g-spipat.adb: Update comments.
4634
4635 2011-08-05 Bob Duff <duff@adacore.com>
4636
4637 * a-fihema.ads: Minor comment fix.
4638 * a-fihema.adb (Allocate, Deallocate): Assert that the alignment is
4639 correct.
4640 (Attach, Detach): Remove some unnecessary code.
4641 (Finalize): Remove Node_Ptr_To_Address, replace with a constant.
4642
4643 2011-08-05 Bob Duff <duff@adacore.com>
4644
4645 * a-fihema.ads, a-fihema.adb (Finalization_Collection): Avoid heap
4646 allocation for Objects component. This simplifies the code somewhat. It
4647 is also a little more efficient in the not-so-unusual case where there
4648 are no controlled objects allocated.
4649 Make Finalization_Started flag atomic.
4650 (Finalize): Avoid unnecessary detachment of items from the list.
4651 (pcol): Minor cleanup.
4652
4653 2011-08-05 Ed Schonberg <schonberg@adacore.com>
4654
4655 * sem_ch12.adb (Analyze_Formal_Package_Declaration): reject a formal
4656 package whose name is the same as that of the generic unit, or its
4657 ultimate prefix.
4658
4659 2011-08-05 Bob Duff <duff@adacore.com>
4660
4661 * a-fihema.adb, a-fihema.ads: Minor comment improvements.
4662 * sem_ch3.adb, exp_ch5.adb, exp_ch7.adb, exp_ch7.ads, exp_util.adb:
4663 Minor comment fixes.
4664
4665 2011-08-05 Arnaud Charlet <charlet@adacore.com>
4666
4667 * make.adb (Linking_Phase): No longer need to set source search path
4668 before calling gnatlink in CodePeer mode.
4669 * gnatlink.adb (Gnatlink): No longer pass -gnat83/95/05/12 switch to
4670 gcc in CodePeer mode, since the binder generated file no longer has a
4671 'with Main'.
4672 * switch.ads, switch.adb (Is_Language_Switch): Removed.
4673 * switch-c.adb: Update comment.
4674
4675 2011-08-05 Thomas Quinot <quinot@adacore.com>
4676
4677 * exp_strm.adb, bindgen.adb, s-ficobl.ads: Minor reformatting.
4678
4679 2011-08-05 Nicolas Roche <roche@adacore.com>
4680
4681 * gnat_ugn.texi: Fix minor syntax error issue.
4682
4683 2011-08-05 Vincent Celier <celier@adacore.com>
4684
4685 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
4686 delete or close the file when the call to gnatmake returns a non
4687 successful return code.
4688
4689 2011-08-05 Ed Schonberg <schonberg@adacore.com>
4690
4691 * exp_ch4.adb (Expand_N_Type_Conversion): When expanding a predicate
4692 check, indicate that the copy of the original node does not come from
4693 source, to prevent an infinite recursion of the expansion.
4694
4695 2011-08-05 Johannes Kanig <kanig@adacore.com>
4696
4697 * debug.adb: document switch -gnatd.G for gnat2why, which deactivates
4698 VC generation for subprogram bodies.
4699
4700 2011-08-05 Yannick Moy <moy@adacore.com>
4701
4702 * einfo.ads: Typo.
4703 * sem_ch3.adb (Signed_Integer_Type_Declaration): in ALFA mode, define
4704 the base type with the smallest allowed base type.
4705
4706 2011-08-05 Sergey Rybin <rybin@adacore.com>
4707
4708 * tree_gen.adb, tree_in.adb, aspects.adb: Fix tree read-write for
4709 aspects.
4710
4711 2011-08-05 Ed Schonberg <schonberg@adacore.com>
4712
4713 * sem_ch12.ads: minor comment updates.
4714
4715 2011-08-05 Ed Schonberg <schonberg@adacore.com>
4716
4717 * sem_ch12.adb (Analyze_Formal_Package_Declaration): in an
4718 instantiation and a formal package the compiler generates a package
4719 renaming declaration so that the generic name within the declaration
4720 is interpreted as a renaming of the instance. At the end of a formal
4721 package declaration, this renaming must become invisible.
4722
4723 2011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
4724
4725 * exp_ch7.adb (Is_Init_Call): Reimplemented to avoid character
4726 comparison and rely on concrete entities instead.
4727
4728 2011-08-05 Ed Schonberg <schonberg@adacore.com>
4729
4730 * einfo.ads, einfo.adb (Has_Implicit_Dereference): new flag on types
4731 and discriminants, to indicate that the type has an access discriminant
4732 that supports implicit dereference.
4733 * snames.ads-tmpl: Add names of aspects and attributes related to
4734 Ada2012 iterators: constant_indexing, default_iterator,
4735 iterator_element, implicit_dereference, variable_indexing.
4736 * aspects.ads, aspects.adb: entries for iterator-related aspects.
4737 * sem_ch13.adb (Analyze_aspect_specifications): dummy entries for
4738 iterator-related aspects.
4739 * sem_attr.adb, exp_attr.adb Dummy entries for iterator-related aspects.
4740
4741 2011-08-05 Sergey Rybin <rybin@adacore.com>
4742
4743 * gnat_ugn.texi, vms_data.ads: Extend the subsection about coupling
4744 metrics in gnatmetric to cover new kinds of coupling mentrics.
4745
4746 2011-08-05 Steve Baird <baird@adacore.com>
4747
4748 * bindgen.adb (Gen_CodePeer_Wrapper): Call Ada_Main_Program instead
4749 of calling the user-defined main subprogram.
4750 (Gen_Main): Declare Ada_Main_Program and (if CodePeer_Mode
4751 is set) Call_Main_Subprogram ahead of, as opposed to
4752 inside of, Main.
4753 (Gen_Output_File_Ada): Remove CodePeer_Mode-conditional
4754 generation of a "with" of the user-defined main subprogram.
4755 Remove CodePeer_Mode-conditional call to Gen_CodePeer_Wrapper
4756 (which is now called from Gen_Main instead).
4757
4758 2011-08-05 Emmanuel Briot <briot@adacore.com>
4759
4760 * projects.texi: Added reference to the Makefile package.
4761
4762 2011-08-05 Thomas Quinot <quinot@adacore.com>
4763
4764 * exp_ch7.adb: Minor comment rewording.
4765
4766 2011-08-05 Ed Falis <falis@adacore.com>
4767
4768 * env.c: Fix comment.
4769
4770 2011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
4771
4772 * sem_elab.adb (Is_Finalization_Procedure): Reimplemented to avoid
4773 character comparison and rely on concrete entities instead.
4774
4775 2011-08-05 Ed Schonberg <schonberg@adacore.com>
4776
4777 * sem_ch3.adb: (Check_Private_Overriding): better error message,
4778 suggested by AI95-0068.
4779
4780 2011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
4781
4782 * exp_ch7.adb (Find_Last_Init): Use Next_Suitable_Statement to retrieve
4783 the two potential initialization calls. This accounts for any
4784 access-before-elaboration checks which may precede the initialization
4785 calls.
4786 (Next_Suitable_Statement): New routine. Returns the next real statement
4787 after the input node while skipping generated checks.
4788 * sem_elab.adb (Check_A_Call): New formal parameter In_Init_Proc along
4789 with comment on usage.
4790 Do not generate Elaborate_All when the trigger is a finalization call
4791 coming from a type init proc.
4792 (Check_Elab_Call): Propagate the initialization procedure context to
4793 subsequent calls to Check_A_Call.
4794 (Check_Internal_Call_Continue): Propagate the initialization procedure
4795 context to subsequent calls to Check_Elab_Call.
4796 (Is_Finalization_Procedure): New routine. Returns True if the input
4797 entity denotes a [Deep_]Finalize routine.
4798 * sem_elab.ads (Check_Elab_Call): New formal parameter In_Init_Proc
4799 along with comment on usage.
4800
4801 2011-08-05 Vadim Godunko <godunko@adacore.com>
4802
4803 * s-atocou.ads: Add list of supported platforms.
4804
4805 2011-08-05 Yannick Moy <moy@adacore.com>
4806
4807 * sem_prag.adb, restrict.adb: Correct style for or'ing Boolean variables
4808
4809 * opt.ads (Disable_ALI_File): new Boolean flag
4810 * lib-writ.adb (Write_ALI): when Disable_ALI_File is set, do nothing
4811
4812 2011-08-05 Ed Falis <falis@adacore.com>
4813
4814 * env.c (__gnat_environ): Fix includes for RTPs and VTHREADS so that
4815 environ is properly defined.
4816
4817 2011-08-05 Vincent Celier <celier@adacore.com>
4818
4819 * make.adb (Compilation_Phase): Exit immediately when all objects have
4820 been found up to date, to avoid multiple exit messages.
4821 * prj-nmsc.adb (Add_Source): Allow duplicate source file names in the
4822 same project for languages with no compiler.
4823 * gnat_ugn.texi: Document compiler switch -gnateI and gnatmake switch
4824 -eI.
4825 2011-08-05 Robert Dewar <dewar@adacore.com>
4826
4827 * exp_ch7.ads, sem_type.adb, make.adb, sem_prag.adb, sem_util.adb,
4828 sem_util.ads, sem_attr.adb, restrict.ads, sem_ch6.adb, prj-conf.adb,
4829 prj-conf.ads, s-atocou.ads, s-atocou.adb, s-atocou-x86.adb,
4830 s-atocou-builtin.adb: Minor reformatting.
4831
4832 2011-08-05 Yannick Moy <moy@adacore.com>
4833
4834 * exp_ch7.adb (Establish_Transient_Scope): in formal verification mode,
4835 if the node to wrap is a pragma check, this node and enclosed
4836 expression are not expanded, so do not apply any transformations here.
4837 * exp_prag.adb (Expand_Pragma_Check): document the need to avoid
4838 introducing transient scopes.
4839
4840 2011-08-05 Jose Ruiz <ruiz@adacore.com>
4841
4842 * adaint.c (__gnat_set_writable, __gnat_set_readable,
4843 __gnat_set_executable, __gnat_set_non_writable, __gnat_set_non_readable,
4844 __gnat_copy_attribs): On VxWorks 6.x and later, the required chmod
4845 routine is available, so we use the default implementation of these
4846 functions.
4847 * s-os_lib.ads (Copy_File, Copy_Time_Stamps): Document that there is
4848 support for copying attributes on VxWorks 6.
4849
4850 2011-08-05 Yannick Moy <moy@adacore.com>
4851
4852 * debug.adb: Remove use of -gnatd.D.
4853 * gnat1drv.adb (Adjust_Global_Switches): adjust switches for ALFA mode
4854 * opt.ads: Simplify variables for ALFA mode, to keep one only
4855 * restrict.adb, sem_prag.adb: Adapt treatment done for CodePeer mode
4856 to ALFA mode.
4857
4858 2011-08-05 Vincent Celier <celier@adacore.com>
4859
4860 * prj-conf.adb (Do_Autoconf): Look also for --RTS in
4861 Builder'Default_Switches.
4862
4863 2011-08-05 Vincent Celier <celier@adacore.com>
4864
4865 * makeusg.adb: Add lines for --create-map-file switches.
4866
4867 2011-08-05 Ed Schonberg <schonberg@adacore.com>
4868
4869 * freeze.adb (Freeze_Entity): For a subprogram, if a type in the
4870 profile is incomplete and the full view is available, replace it with
4871 the full view.
4872 * sem_ch6.adb (Possible_Freeze): if a type in the profile is
4873 incomplete, freezing the subprogram is delayed until the full view is
4874 frozen.
4875 * sem_type.adb (Disambiguate): an ambiguity between a user-defined
4876 fixed-point multiplication operator and the predefined operator is
4877 resolved in favor of the user-defined one.
4878
4879 2011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4880
4881 * init.c [__alpha__ && __osf__] (__gnat_error_handler): Use
4882 CONST_CAST.
4883
4884 2011-08-04 Ed Schonberg <schonberg@adacore.com>
4885
4886 * sem_util.ads, sem_unit.adb (Type_Without_Stream_Operation): determine
4887 whether a type lacks user-defined Read or Write operations, or has a
4888 component that lacks them.
4889 * sem_attr.adb (Check_Stream_Attribute): if restriction
4890 No_Default_Stream_Attributes is active, verify that all subcomponent
4891 types of the target have user-defined stream operations, and report
4892 error otherwise.
4893 * exp_ch3.adb (Stream_Operqtion_OK): use Type_Without_Stream_Operation.
4894 * exp_strm.adb: Build_Elementary_Input_Call,
4895 Build_Elementary_Write_Call): remove checks for restriction
4896 No_Default_Stream_Attributes, now checked in semantics.
4897
4898 2011-08-04 Vincent Celier <celier@adacore.com>
4899
4900 * prj-conf.ads, prj-conf.adb (Do_Autoconf): If there is no --RTS
4901 switches on the command line, look for all valid --RTS switches in the
4902 Builder switches and for each language use the first runtime name found
4903 to invoke gprconfig.
4904 (Get_Or_Create_Configuration_File): Warn if --RTS is specified on the
4905 command line and there is no auto-configuration.
4906 (Runtime_Name_Set_For): New function.
4907
4908 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
4909
4910 * exp_ch7.adb (Build_Object_Declarations): Do not generate the
4911 elaborate initialization expression for variable Abort when processing
4912 a package body or a declaration.
4913 (Create_Finalizer): Propagate the package context when creating the
4914 exception-related variables.
4915 * exp_ch7.ads (Build_Object_Declarations): New formal parameter
4916 For_Package along with usage comment.
4917
4918 2011-08-04 Arnaud Charlet <charlet@adacore.com>
4919
4920 * gcc-interface/Makefile.in: Clean up targets.
4921 Enable new package for atomic counters and copy-on-write implementation
4922 of unbounded strings on x86 platforms.
4923 * gcc-interface/Make-lang.in: Update dependencies.
4924
4925 2011-08-04 Robert Dewar <dewar@adacore.com>
4926
4927 * exp_ch7.adb: Minor reformatting.
4928
4929 2011-08-04 Robert Dewar <dewar@adacore.com>
4930
4931 * exp_strm.adb: Minor reformatting.
4932
4933 2011-08-04 Vadim Godunko <godunko@adacore.com>
4934
4935 * s-atocou.adb: Replace by dummy version and use on targets where atomic
4936 operations are not supported.
4937 * s-atocou-builtin.adb: Renamed from s-atocou.adb.
4938 * s-atocou-x86.adb: New file.
4939 * Makefile.rtl: Add s-atocou.o file
4940
4941 2011-08-04 Arnaud Charlet <charlet@adacore.com>
4942
4943 * make.adb (Compile): Move setting of CodePeer_Mode to ...
4944 (Compilation_Phase): ... here.
4945 (Scan_Make_Arg): Now bind and link by default in CodePeer mode.
4946
4947 2011-08-04 Thomas Quinot <quinot@adacore.com>
4948
4949 * Make-generated.in: Fix minor typo in comment.
4950
4951 2011-08-04 Thomas Quinot <quinot@adacore.com>
4952
4953 * gnatls.adb: Use Prj.Env.Initialize_Default_Project_Path to retrieve
4954 the project path.
4955
4956 2011-08-04 Robert Dewar <dewar@adacore.com>
4957
4958 * a-coinho.adb: Minor reformatting.
4959
4960 2011-08-04 Robert Dewar <dewar@adacore.com>
4961
4962 * a-coinho.ads: Minor reformatting.
4963
4964 2011-08-04 Vadim Godunko <godunko@adacore.com>
4965
4966 * s-atocou.ads, s-atocou.adb: New files.
4967 * a-strunb-shared.ads, a-strunb-shared.adb, a-stwiun-shared.ads,
4968 a-stwiun-shared.adb, a-stzunb-shared.ads, a-stzunb-shared.adb: Remove
4969 direct use of GCC's atomic builtins and replace them by use of new
4970 atomic counter package.
4971
4972 2011-08-04 Ed Schonberg <schonberg@adacore.com>
4973
4974 * exp_strm.adb: better error message for No_Default_Stream_Attributes.
4975
4976 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
4977
4978 * a-tags.adb (Unregister_Tag): Replace the complex address arithmetic
4979 with a call to Get_External_Tag.
4980 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on
4981 subprogram usage. Remove the guard against package declarations and
4982 bodies since Build_Cleanup_Statements is no longer invoked in that
4983 context.
4984 (Build_Components): Initialize Tagged_Type_Stmts when the context
4985 contains at least one library-level tagged type.
4986 (Build_Finalizer): New local variables Has_Tagged_Types and
4987 Tagged_Type_Stmts along with associated comments on usage. Update the
4988 logic to include tagged type processing.
4989 (Create_Finalizer): Insert all library-level tagged type unregistration
4990 code before the jump block circuitry.
4991 (Expand_N_Package_Body): Remove the call to Build_Cleanup_Statements.
4992 (Expand_N_Package_Declaration): Remove the call to
4993 Build_Cleanup_Statements.
4994 (Process_Tagged_Type_Declaration): New routine. Generate a call to
4995 unregister the external tag of a tagged type.
4996 (Processing_Actions): Reimplemented to handle tagged types.
4997 (Process_Declarations): Detect the declaration of a library-level
4998 tagged type and carry out the appropriate actions.
4999 (Unregister_Tagged_Types): Removed. The machinery has been directly
5000 merged with Build_Finalizer.
5001
5002 2011-08-04 Robert Dewar <dewar@adacore.com>
5003
5004 * bindgen.ads, gnatlink.adb, sem_ch4.adb, gnatbind.adb, put_alfa.adb,
5005 gnatls.adb, exp_ch3.adb: Minor reformatting.
5006
5007 2011-08-04 Marc Sango <sango@adacore.com>
5008
5009 * sem_attr.adb (Analyze_Attribute): Replace the message
5010 "invisible attribute of}" of the spark restriction violation in
5011 attribute reference by the simple message "invisible attribute of type".
5012 Indeed, the node value Error_Msg_Node_1 used is in conflit with the
5013 two insertion characters: '&' and '}'.
5014
5015 2011-08-04 Vadim Godunko <godunko@adacore.com>
5016
5017 * impunit.adb (Non_Imp_File_Names_12): Add "a-coinho".
5018 * a-coinho.ads, a-coinho.adb: New file.
5019 * Makefile.rtl: Add Ada.Containers.Indefinite_Holders.
5020
5021 2011-08-04 Nicolas Roche <roche@adacore.com>
5022
5023 * alfa_test.adb: Not all ali files are containing alfa information even
5024 if compiled with -gnatd.F. So suppress warning about missing ALFA
5025 information.
5026
5027 2011-08-04 Yannick Moy <moy@adacore.com>
5028
5029 * lib-xref-alfa.adb (Add_ALFA_Scope): use non-empty unique name for
5030 scope.
5031 * put_alfa.adb: Check that scope name is not empty.
5032
5033 2011-08-04 Ed Schonberg <schonberg@adacore.com>
5034
5035 * exp_ch3.adb (Stream_Operation_Ok): new predicate
5036 Needs_Elementary_Stream_Operation, to determine whether user-defined
5037 Read and Write attributes are available for the elementary components
5038 of the given type. If only the predefined attributes are available,
5039 then when restriction No_Default_Stream_Attributes is active the
5040 predefined stream attributes for the composite type cannot be created.
5041
5042 2011-08-04 Robert Dewar <dewar@adacore.com>
5043
5044 * bindgen.adb: Fix obsolete comments and names from Ada/C days.
5045 Put routines in alpha order
5046
5047 2011-08-04 Jose Ruiz <ruiz@adacore.com>
5048
5049 * gcc-interface/Makefile.in: Remove xenomai specific versions of system.
5050 * gcc-interface/Make-lang.in: Update dependencies.
5051
5052 2011-08-04 Arnaud Charlet <charlet@adacore.com>
5053
5054 * gcc-interface/lang.opt: Add AdaWhy language, simimlar to Ada.
5055 * gcc-interface/lang-specs.h: Add handling of AdaWhy specs (calls
5056 gnat1why).
5057
5058 2011-08-04 Robert Dewar <dewar@adacore.com>
5059
5060 * sem_ch3.adb, make.adb, a-cohata.ads, sem_prag.adb, makeutl.adb,
5061 lib-xref-alfa.adb: Minor reformatting.
5062
5063 2011-08-04 Marc Sango <sango@adacore.com>
5064
5065 * sem_ch12.adb (Analyze_Generic_Package_Declaration,
5066 Analyze_Generic_Subprogram_Declaration, Analyze_Package_Instantiation,
5067 Analyze_Subprogram_Instantiation): Check absence of generic in SPARK
5068 mode.
5069
5070 2011-08-04 Tristan Gingold <gingold@adacore.com>
5071
5072 * bindgen.adb (Gen_Adainit_C): Remove.
5073 (Gen_Adafinal_C): Ditto.
5074 (Gen_Elab_Externals_C): Ditto.
5075 (Gen_Elab_Calls_C): Ditto.
5076 (Gen_Elab_Order_C): Ditto.
5077 (Gen_Elab_Defs_C): Ditto.
5078 (Gen_Finalize_Library_C): Ditto.
5079 (Gen_Finalize_Library_Defs_C): Ditto.
5080 (Gen_Main_C): Ditto.
5081 (Gen_Output_File_C): Ditto.
5082 (Gen_Restrictions_C): Ditto.
5083 (Gen_Versions_C): Ditto.
5084 (Write_Info_Ada_C): Ditto.
5085 (Gen_Object_Files_Options): Call WBI instead of Write_Info_Ada_C
5086 (Gen_Output_File): Do not force Ada_Bind_File anymore.
5087 Always call Gen_Output_File_Ada.
5088 * gnatlink.adb (Begin_Info): Now a constant.
5089 (End_Info): Ditto.
5090 (Ada_Bind_File): Remove
5091 (Process_Args): Do not handle -A/-C. Remove not Ada_Bind_File cases.
5092 * switch-b.adb (Scan_Binder_Switches): Do not handle -C.
5093 * gnatbind.adb (Gnatbind): Remove not Ada_Bind_File cases.
5094 * opt.ads (Ada_Bind_File): Remove.
5095
5096 2011-08-04 Thomas Quinot <quinot@adacore.com>
5097
5098 * projects.texi: Document target-specific directory in default project
5099 path for gnatmake.
5100
5101 2011-08-04 Thomas Quinot <quinot@adacore.com>
5102
5103 * gnatls.adb, prj-env.adb: Add $prefix/share/gpr to default project
5104 path in all cases .
5105
5106 2011-08-04 Yannick Moy <moy@adacore.com>
5107
5108 * sem_ch3.adb, sem_ch5.adb, sem_util.adb, sem_ch4.adb, sem_ch8.adb,
5109 opt.ads, lib-xref.ads: Code clean up.
5110
5111 2011-08-04 Yannick Moy <moy@adacore.com>
5112
5113 * gnat_rm.texi: Update description of Test_Case
5114 * gnat_ugn.texi: Typo.
5115
5116 2011-08-04 Ed Falis <falis@adacore.com>
5117
5118 * adaint.c (__gnat_get_number_of_cpus): fix typo in last checkin.
5119
5120 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
5121
5122 * exp_ch4.adb (Suitable_Element): Skip field _parent on .NET/JVM when
5123 it is of type Root_Controlled. This action eliminates fields Prev and
5124 Next from type equality.
5125
5126 2011-08-04 Yannick Moy <moy@adacore.com>
5127
5128 * lib-xref-alfa.adb: Correct typo.
5129
5130 2011-08-04 Matthew Heaney <heaney@adacore.com>
5131
5132 * a-cohata.ads (Hash_Table_Type): default-initialize the Nodes
5133 component.
5134
5135 2011-08-04 Yannick Moy <moy@adacore.com>
5136
5137 * sem_prag.adb (Check_Arg_Is_String_Literal): remove useless procedure
5138 (Analyze_Pragma): allow static string expression for name of Test_Case,
5139 instead of simply string literals.
5140 * sem_util.adb (Get_Name_From_Test_Case_Pragma): adapt to static string
5141 expressions.
5142
5143 2011-08-04 Vincent Celier <celier@adacore.com>
5144
5145 * makeutl.adb (Complete_Mains.Find_File_Add_Extension): Use canonical
5146 case suffixes to find truncated main sources.
5147
5148 2011-08-04 Tristan Gingold <gingold@adacore.com>
5149
5150 * impunit.adb (Non_Imp_File_Names_95): Add g-tastus.
5151 s-stusta.adb (Compute_All_Task): Use Put_Line instead of Put.
5152 (Compute_Current_Task): Ditto.
5153
5154 2011-08-04 Tristan Gingold <gingold@adacore.com>
5155
5156 * gnat_ugn.texi: Mention GNAT.Task_Stack_Usage.
5157
5158 2011-08-04 Yannick Moy <moy@adacore.com>
5159
5160 * lib-xref-alfa.adb (Is_Global_Constant): new function that detects
5161 library-level constant.
5162 (Add_ALFA_Xrefs): ignore global constants in ALFA xref.
5163 * sem_res.adb (Resolve_Actuals): do not add cross-reference to Formal
5164 used as selector of parameter association, in ALFA mode.
5165
5166 2011-08-04 Robert Dewar <dewar@adacore.com>
5167
5168 * exp_ch5.adb, exp_ch7.adb, exp_util.adb, bindgen.adb, sem_prag.adb,
5169 s-tassta.adb, exp_ch4.adb, exp_disp.adb, s-stausa.adb: Minor
5170 reformatting.
5171
5172 2011-08-04 Arnaud Charlet <charlet@adacore.com>
5173
5174 * make.adb (Linking_Phase): Set source search path before calling
5175 gnatlink in CodePeer mode.
5176
5177 2011-08-04 Javier Miranda <miranda@adacore.com>
5178
5179 * exp_ch7.adb (Expand_N_Package_Body, Expand_N_Package_Declaration):
5180 Remove code which takes care of building TSDs.
5181 * rtsfind.ads (RE_Check_Interface_Conversion): New entity.
5182 * exp_ch4.adb (Apply_Accessibility_Check): Add support for generating
5183 the accessibility check in VM targets.
5184 * exp_disp.adb (Make_VM_TSD): Spec moved to exp_disp.ads
5185 (Building_Static_DT): Now returns false for VM targets.
5186 (Build_VM_TSDs): Removed.
5187 (Expand_Interface_Conversion): Generate missing runtime check for
5188 conversions to interface types whose target type is unknown at compile
5189 time.
5190 (Make_VM_TSD): Add missing code to disable the generation of calls to
5191 Check_TSD if the tagged type is not defined at library level, or not
5192 has a representation clause specifying its external tag, or -gnatdQ is
5193 active.
5194 * exp_disp.ads (Build_VM_TSDs): Removed.
5195 (Make_VM_TSDs): Spec relocated from exp_disp.adb
5196 * sem_disp.adb (Check_Dispatching_Operation): No code required to
5197 register primitives in the dispatch tables in VM targets.
5198 * exp_ch3.adb (Expand_N_Object_Declaration): Remove wrong expansion of
5199 initialization of class-wide interface objects in VM targets.
5200 (Expand_Freeze_Record_Type): For VM targets call Make_VM_TSD (instead
5201 of Make_DT).
5202
5203 2011-08-04 Jerome Lambourg <lambourg@adacore.com>
5204
5205 * gnatlink.adb (Gnatlink): Correct missleading error message displayed
5206 when dotnet-ld cannot be found.
5207
5208 2011-08-04 Arnaud Charlet <charlet@adacore.com>
5209
5210 * bindgen.adb: Simplify significantly generation of binder body file in
5211 CodePeer mode.
5212 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Prevent assert failure
5213 when compiling binder generated file in CodePeer mode (xxx'Elab_Spec
5214 not expanded).
5215
5216 2011-08-04 Yannick Moy <moy@adacore.com>
5217
5218 * sem_prag.adb, sem.ads: Code cleanup.
5219
5220 2011-08-04 Tristan Gingold <gingold@adacore.com>
5221
5222 * s-tassta.adb (Task_Wrapper): Rewrite the dynamic stack usage part.
5223 * s-stausa.adb, s-stausa.ads: Major rewrite. Now provides accurate
5224 results if possible.
5225 * s-stusta.adb (Print): Adjust after changes in s-stausa.
5226 * gnat_ugn.texi: Update dynamic stack usage section.
5227
5228 2011-08-04 Steve Baird <baird@adacore.com>
5229
5230 * bindgen.adb (Gen_CodePeer_Wrapper): new procedure.
5231 Generate (if CodePeer_Mode is set) a "wrapper" subprogram which
5232 contains only a call to the user-defined main subprogram.
5233 (Gen_Main_Ada) - If CodePeer_Mode is set, then
5234 call the "wrapper" subprogram instead of directly
5235 calling the user-defined main subprogram.
5236
5237 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
5238
5239 * exp_ch5.adb (Expand_N_Case_Statement): Check the statements of all
5240 alternatives of a case statement for controlled objects. Rename local
5241 variable A to Dead_Alt.
5242 (Expand_N_If_Statement): Check the then and else statements of an if
5243 statement for controlled objects. Check the then statements of all
5244 elsif parts of an if statement for controlled objects.
5245 (Expand_N_Loop_Statement): Check the statements of a loop for controlled
5246 objects.
5247 * exp_ch7.adb (Process_Transient_Objects): Rewrite the condition which
5248 detects a loop associated with the expansion of an array object.
5249 Augment the processing of the loop statements to account for a possible
5250 wrap done by Process_Statements_For_Controlled_Objects.
5251 * exp_ch9.adb (Expand_N_Asynchronous_Select): Check the triggering
5252 statements and abortable part of an asynchronous select for controlled
5253 objects.
5254 (Expand_N_Conditional_Entry_Call): Check the else statements of a
5255 conditional entry call for controlled objects.
5256 (Expand_N_Selective_Accept): Check the alternatives of a selective
5257 accept for controlled objects.
5258 (Expand_N_Timed_Entry_Call): Check the entry call and delay
5259 alternatives of a timed entry call for controlled objects.
5260 * exp_ch11.adb (Expand_Exception_Handlers): Check the statements of an
5261 exception handler for controlled objects.
5262 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
5263 Add formal parameter Nested_Constructs along with its associated
5264 comment.
5265 (Requires_Cleanup_Actions (Node_Id)): Update all calls to
5266 Requires_Cleanup_Actions.
5267 (Process_Statements_For_Controlled_Objects): New routine.
5268 * exp_util.ads (Process_Statements_For_Controlled_Objects): New
5269 routine. Inspect a node which contains a non-handled sequence of
5270 statements for controlled objects. If such an object is found, the
5271 statements are wrapped in a block.
5272
5273 2011-08-04 Bob Duff <duff@adacore.com>
5274
5275 * sem_type.adb (Covers): If T2 is a subtype of a class-wide type, we
5276 need to compare with Class_Wide_Type (T2), in order to get at the
5277 original class-wide type node.
5278 * sem_type.ads (Covers): Improve the comment.
5279 * einfo.ads (Class_Wide_Type): Improve the comment.
5280 * exp_intr.adb (Expand_Unc_Deallocation): Remove unnecessary setting of
5281 the type of the Deref.
5282
5283 2011-08-04 Yannick Moy <moy@adacore.com>
5284
5285 * gnat_rm.texi: Document that Test_Case pragma can only appear on
5286 separate declarations.
5287 * sem_prag.adb (procedure Check_Identifier_Is_One_Of): new procedure to
5288 check identifier of pragma argument.
5289 (Chain_TC): check that no other test case associated to the same entity
5290 share the same name.
5291 (Check_Test_Case): disallow test case inside subprogram body
5292 (Analyze_Pragma): correct call to check identifier and not argument
5293 * sem_util.adb, sem_util.ads (Get_Name_From_Test_Case_Pragma): new
5294 function gets name from test case pragma.
5295
5296 2011-08-04 Yannick Moy <moy@adacore.com>
5297
5298 * gnat_rm.texi: Document new pragma and aspect.
5299 * aspects.adb, aspects.ads (Aspect_Id): new value Aspect_Test_Case
5300 (No_Duplicates_Allowed): new constant array defining whether duplicates
5301 aspects of each kind can appear on the same declaration.
5302 * einfo.adb, einfo.ads (Spec_PPC_List): replace field with Contract
5303 field, which points to a node holding the previous Spec_PPC_List.
5304 * exp_ch9.adb, sem_ch6.adb, sem_prag.adb: Reach to Spec_PPC_List
5305 through the indirection with Contract.
5306 * exp_util.adb (Insert_Actions): raise Program_Error on N_Contract node
5307 * par-prag.adb (Prag): do nothing on Test_Case pragma
5308 * sem.adb (Analyze): abort on N_Contract, on which Analyze should not
5309 be called directly.
5310 * sem_attr.adb (Analyze_Attribute): allow attribute 'Result in
5311 component Ensures of Test_Case.
5312 * sem_ch12.adb, sem_ch6.adb, sem_ch9.adb
5313 (Analyze_Generic_Subprogram_Declaration,
5314 Analyze_Subprogram_Instantiation,
5315 Analyze_Abstract_Subprogram_Declaration,
5316 Analyze_Subprogram_Body_Helper,
5317 Analyze_Subprogram_Specification, Analyze_Entry_Declaration):
5318 insert contract in subprogram node at point of definition
5319 * sem_ch13.adb
5320 (Aspect_Loop): do not raise error on duplicate Test_Case aspect
5321 (Analyze_Aspect_Specifications): analyze Test_Case aspect and create
5322 corresponding pragma
5323 (Check_Aspect_At_Freeze_Point): raise Program_Error on Test_Case aspect
5324 * sem_ch3.adb (Analyze_Declarations): insert analysis of test-cases,
5325 similar to the analysis of pre/post
5326 (Derive_Subprogram): insert contract in subprogram node at point of
5327 derivation.
5328 * sem_prag.adb, sem_prag.ads
5329 (Check_Arg_Is_String_Literal, Check_Identifier):
5330 new checking procedures to be called in treatment of pragmas
5331 (Check_Test_Case): new procedure to check that a Test_Case aspect or
5332 pragma is well-formed. This does not check currently that 'Result is
5333 used only in the Ensures component of a Test_Case.
5334 (Analyze_Pragma): add case for Test_Case
5335 (Analyze_TC_In_Decl_Part): pre-analyze the Requires and Ensures
5336 components of a Test_Case.
5337 (Preanalyze_TC_Args): new procedure to preanalyze the boolean
5338 expressions in the 3rd (and 4th if present) arguments of a Test_Case
5339 pragma, treated as spec expressions.
5340 (Sig_Flags): add value -1 for Test_Case.
5341 * sem_util.adb, sem_util.ads (Get_Ensures_From_Test_Case_Pragma,
5342 Get_Requires_From_Test_Case_Pragma): getters for both expression
5343 components of a Test_Case.
5344 * sinfo.adb, sinfo.ads (N_Contract): new kind of node used as
5345 indirection between an entry or [generic] subprogram entity and its
5346 pre/post + test-cases.
5347 (Spec_PPC_List, Spec_TC_List, Set_Spec_PPC_List, Set_Spec_TC_List):
5348 get/set for fields of an N_Contract node.
5349 * snames.ads-tmpl (Name_Test_Case, Name_Ensures, Name_Mode,
5350 Name_Normal, Name_Requires, Name_Robustness, Pragma_Test_Case): new
5351 names and pragma for Test_Case.
5352 * sprint.adb (Sprint_Node): raise Program_Error on N_Contract node
5353
5354 2011-08-04 Vincent Celier <celier@adacore.com>
5355
5356 * gnat_ugn.texi: Improve documentation of gnatmake switch
5357 --source-info-file=.
5358
5359 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
5360
5361 * exp_ch7.adb (Make_Final_Call): Add local variable Atyp (assertion
5362 type). Initialize Atyp to the appropriate type which is later checked
5363 for completion. Rewrite the assertion associated with private type
5364 completion.
5365
5366 2011-08-04 Ed Falis <falis@adacore.com>
5367
5368 * adaint.c: Add call to vxCpuConfiguredGet for VxWorks SMP to
5369 initialize the number of CPUs.
5370
5371 2011-08-04 Ed Schonberg <schonberg@adacore.com>
5372
5373 * sem_type.adb (Disambiguate): New subsidiary routine
5374 In_Same_Declaration_List, to implement AI05-0020: a user-defined
5375 equality on an anonymous access type whose designated type is private
5376 does not lead to an ambiguity with the universal access equality
5377 operator in the body or child units of the defining package. The same
5378 is true for a multiplication operator on a private type completed with
5379 a fixed-point-type.
5380
5381 2011-08-04 Javier Miranda <miranda@adacore.com>
5382
5383 * opt.ads (Init_Or_Norm_Scalars_Config): Removed.
5384 (Normalize_Scalars_Config): Removed.
5385 * opt.adb
5386 (Register_Opt_Config_Switches): Remove registering config values of
5387 Init_Or_Norm_Scalars_Config and Normalize_Scalars_Config.
5388 (Restore_Opt_Config_Switches): Remove code which restores the values of
5389 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
5390 Init_Or_Norm_Scalars.
5391 (Save_Opt_Config_Switches): Remove code which saves values of
5392 Init_Or_Norm_Scalars and Normalize_Scalars.
5393 (Set_Opt_Config_Switches): Remove code which restores config values of
5394 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
5395 Init_Or_Norm_Scalars.
5396
5397 2011-08-04 Yannick Moy <moy@adacore.com>
5398
5399 * frontend.adb (Frontend): remove previous patch to avoid full
5400 qualification in ALFA mode.
5401 * lib-xref-alfa.adb (Add_ALFA_Xrefs): use unique name for variables.
5402 * sem_util.adb, sem_util.ads (Unique_Name): new function to define a
5403 unique name for an entity, which could be used to identify the entity
5404 across compilation units.
5405
5406 2011-08-04 Thomas Quinot <quinot@adacore.com>
5407
5408 * prj-env.adb
5409 (Initialize_Default_Project_Path): Add target specific directory
5410 ($prefix/$target/lib/gnat) in front of project path in all cases
5411 (making gnatmake's behaviour consistent with gprbuild).
5412 * gnatcmd.adb, make.adb, prj-makr.adb, clean.adb:
5413 Pass target name from Sdefault to project subsystem.
5414 * gnatls.adb: Show new target specific default project directory.
5415
5416 2011-08-04 Johannes Kanig <kanig@adacore.com>
5417
5418 * cstand.adb: Add Information to Identifier in Standard
5419 (Identifer_For): Set Entity to the corresponding entity
5420
5421 2011-08-04 Sergey Rybin <rybin@adacore.com>
5422
5423 * gnat_ugn.texi: Update doc on gnatcheck.
5424
5425 2011-08-04 Yannick Moy <moy@adacore.com>
5426
5427 * lib-xref-alfa.adb (Add_ALFA_Xrefs): correct definition of ranges of
5428 xrefs in a scope.
5429
5430 2011-08-04 Yannick Moy <moy@adacore.com>
5431
5432 * exp_prag.adb (Expand_Pragma_Check): in ALFA mode, return without
5433 performing expansion.
5434 * sem_ch6.adb (Analyze_Subprogram_Body_Helper,
5435 Analyze_Generic_Subprogram_Body): protect call to Process_PCCs so that
5436 it is not called in ALFA mode.
5437
5438 2011-08-04 Emmanuel Briot <briot@adacore.com>
5439
5440 * make.adb, osint.adb, osint.ads (Reset_Command_Line_Files): not used
5441 after all, so removed.
5442
5443 2011-08-04 Sergey Rybin <rybin@adacore.com>
5444
5445 * vms_data.ads: Add missing VMS qualifiers.
5446
5447 2011-08-04 Emmanuel Briot <briot@adacore.com>
5448
5449 * make.adb, makeutl.adb, osint.adb, osint.ads (Check_Mains): rebuild
5450 the list of files on the command line after processing it through
5451 Complete_Mains.
5452
5453 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
5454
5455 * exp_ch7.adb (Build_Raise_Statement): Remove the specialized
5456 processing for .NET/JVM. These targets can now benefit from
5457 Raise_From_Controlled_Operation and they share the same processing with
5458 standard targets.
5459 (Establish_Transient_Scope): Remove the restriction for .NET/JVM.
5460 These targets need transient scopes in order to properly finalize short
5461 lived controlled objects.
5462 (Make_Handler_For_Ctrl_Operation): Remove the specialized processing for
5463 NET/JVM. These targets can now benefit from
5464 Raise_From_Controlled_Operation and they share the same processing with
5465 standard targets.
5466
5467 2011-08-04 Geert Bosch <bosch@adacore.com>
5468
5469 * tracebak.c (STOP_FRAME): Stop at any next pointer outside the stack
5470
5471 2011-08-04 Ed Schonberg <schonberg@adacore.com>
5472
5473 * exp_aggr.adb (Has_Visible_Private_Ancestor): subsidiary routine to
5474 Expand_Record_Aggregate, to determine whether aggregate must be
5475 expanded into assignments. This is the case if the ancestor part is
5476 private, regarless of the setting of the flag Has_Private_Ancestor.
5477
5478 2011-08-04 Ed Falis <falis@adacore.com>
5479
5480 * vxaddr2line.adb: Add support for e500v2 and for Linux hosts
5481
5482 2011-08-04 Bob Duff <duff@adacore.com>
5483
5484 * sinfo.ads: Fix comment.
5485
5486 2011-08-04 Steve Baird <baird@adacore.com>
5487
5488 * bindgen.adb (Get_Ada_Main_Name): If CodePeer_Mode is set, then
5489 choose a package name in much the same way as is
5490 done for JGNAT when VM_Target /= No_VM, except that
5491 a slightly more distinctive prefix string is used.
5492
5493 2011-08-04 Emmanuel Briot <briot@adacore.com>
5494
5495 * makeutl.adb (Complete_Mains): no longer accept unit names on the
5496 gnatmake command line.
5497 This behavior was never documented (and was supported only because of
5498 an early bug in the code). This case might lead to ambiguous cases
5499 (between unit names and truncated base names without suffixes).
5500
5501 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
5502
5503 * a-tags.ads, a-tags.adb (Unregister_Tag): New routine.
5504 Remove the external tag of a tagged type from the internal hash table.
5505 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on the
5506 expanded usage of the routine. Strenghten the check for Is_Master. Add
5507 processing for tagged types.
5508 (Build_Finalizer): Create all the necessary lists used in finalizer
5509 creation when the processed context is a package that may contain
5510 tagged types.
5511 (Expand_Cleanup_Actions): Rename the call to Has_Controlled_Objects to
5512 Requires_Cleanup_Actions.
5513 (Expand_N_Package_Body): Package bodies may need clean up code
5514 depending on whether they contain tagged types.
5515 (Expand_N_Package_Declaration): Package declarations may need clean up
5516 code depending on whether they contain tagged types.
5517 (Unregister_Tagged_Types): New routine. Search through a list of
5518 declarations or statements, looking for non-abstract Ada tagged types.
5519 For each such type, generate code to unregister the external tag.
5520 * exp_util.adb (Has_Controlled_Objects (Node_Id)): Renamed to
5521 Requires_Cleanup_Actions.
5522 (Requires_Cleanup_Actions (List_Id, Boolean)): New routine. Search
5523 through a list of declarations or statements looking for non-abstract
5524 Ada tagged types or controlled objects.
5525 * exp_util.ads (Has_Controlled_Objects (Node_Id)): Renamed to
5526 Requires_Cleanup_Actions.
5527 (Has_Controlled_Objects (List_Id, Boolean)): Removed.
5528 * rtsfind.ads: Add entry RE_Unregister_Tag to tables RE_Id and
5529 RE_Unit_Table.
5530
5531 2011-08-04 Vincent Celier <celier@adacore.com>
5532
5533 * prj-env.adb (For_All_Source_Dirs.For_Project): Check if project Prj
5534 has Ada sources, not project Project, because if the root project
5535 Project has no sources of its own, all projects will be deemed without
5536 sources.
5537
5538 2011-08-04 Gary Dismukes <dismukes@adacore.com>
5539
5540 * bindgen.adb (Gen_Adainit_Ada): Move the generation of the declaration
5541 of the No_Param_Proc acc-to-subp type used for initialization of
5542 __gnat_finalize_library_objects so that it's declared at library level
5543 rather than nested inside of the adainit routine.
5544
5545 2011-08-04 Javier Miranda <miranda@adacore.com>
5546
5547 * exp_disp.adb (Make_DT): Generate code to check the external tag ONLY
5548 if the tagged type has a representation clause which specifies its
5549 external tag.
5550
5551 2011-08-04 Ed Schonberg <schonberg@adacore.com>
5552
5553 * einfo.ads, einfo.adb (Has_Private_Ancestor): now a flag on types.
5554 Remove previous procedure with that name.
5555 * sem_ch3.adb (Build_Derived_Record_Type): set Has_Private_Ancestor
5556 when appropriate.
5557 * sem_aggr.adb (Resolve_Extension_Aggregate): if the ancestor part is a
5558 subtype mark, the ancestor cannot have unknown discriminants.
5559 (Resolve_Record_Aggregate): if the type has invisible components
5560 because of a private ancestor, the aggregate is illegal.
5561
5562 2011-08-04 Vincent Celier <celier@adacore.com>
5563
5564 * switch-m.adb (Normalize_Compiler_Switches): Recognize and take into
5565 account switches -gnat2005, -gnat12 and -gnat2012.
5566
5567 2011-08-04 Bob Duff <duff@adacore.com>
5568
5569 * s-tasdeb.ads: Minor comment fix.
5570
5571 2011-08-04 Arnaud Charlet <charlet@adacore.com>
5572
5573 * gnatlink.adb (Gnatlink): Pass -gnat83/95/05/12 switch to gcc in
5574 CodePeer mode.
5575 * switch.ads, switch.adb (Is_Language_Switch): New function.
5576
5577 2011-08-04 Vincent Celier <celier@adacore.com>
5578
5579 * switch-c.adb: Minor comment addition.
5580
5581 2011-08-04 Vincent Celier <celier@adacore.com>
5582
5583 * vms_conv.adb (Process_Argument): Fail graciously when qualifier
5584 ending with '=' is followed by a space (missing file name).
5585
5586 2011-08-04 Pascal Obry <obry@adacore.com>
5587
5588 * g-regist.ads: Fix size of HKEY on x86_64-windows.
5589
5590 2011-08-04 Ed Schonberg <schonberg@adacore.com>
5591
5592 * sem_ch12.adb (Analyze_Associations): New routine
5593 Check_Overloaded_Formal_Subprogram to reject a formal package when
5594 there is a named association or a box initialisation for an overloaded
5595 formal subprogram of the corresponding generic.
5596
5597 2011-08-04 Yannick Moy <moy@adacore.com>
5598
5599 * alfa.ads (ALFA_Xref_Record): add component for type of entity
5600 * get_alfa.adb, put_alfa.adb: Read and write new component of
5601 cross-reference.
5602 * lib-xref-alfa.adb (Collect_ALFA): generate new component.
5603
5604 2011-08-04 Pascal Obry <obry@adacore.com>
5605
5606 * urealp.adb: Minor reformatting.
5607
5608 2011-08-04 Tristan Gingold <gingold@adacore.com>
5609
5610 * exp_ch7.adb (build_finalizer.process_declarations.processing_actions):
5611 Handle the case when Cleanup_Protected_Object returns Empty.
5612
5613 2011-08-04 Yannick Moy <moy@adacore.com>
5614
5615 * frontend.adb (Frontend): only qualify names in non-ALFA mode
5616
5617 2011-08-04 Ed Schonberg <schonberg@adacore.com>
5618
5619 * sem_ch4.adb (Try_Class_Wide_Operation): if the context is a procedure
5620 call, ignore functions.
5621
5622 2011-08-04 Geert Bosch <bosch@adacore.com>
5623
5624 * urealp.adb (Equivalent_Decimal_Exponent): Avoid the use of floating
5625 point.
5626
5627 2011-08-04 Emmanuel Briot <briot@adacore.com>
5628
5629 * makeutl.adb (Compute_Builder_Switches): no longer accept a unit name
5630 as an index for Builder'Switches. This conforms to the documentation.
5631 * make.adb (Insert_Project_Sources): avoid duplicate code
5632
5633 2011-08-04 Emmanuel Briot <briot@adacore.com>
5634
5635 * makeutl.adb (Complete_Mains): if the user has passed a relative file
5636 name on the command line (for instance "../dummy"), never assume it can
5637 be a unit name.
5638
5639 2011-08-04 Tristan Gingold <gingold@adacore.com>
5640
5641 * bindgen.adb: Remove code the reference or create the
5642 Break_Start/__gnat_break_start procedure.
5643 * s-stalib.adb (Break_Start): Removed.
5644
5645 2011-08-04 Emmanuel Briot <briot@adacore.com>
5646
5647 * make.adb, makeutl.adb, makeutl.ads (Compute_Builder_Switches): now
5648 shared with gprbuild.
5649
5650 2011-08-04 Yannick Moy <moy@adacore.com>
5651
5652 * par-ch4.adb (P_Primary): preferentially issue an error message about
5653 a missing parenthesis arount a conditional or case expression in Ada
5654 2012 mode, if we detect that the alignment is not correct for a
5655 statement.
5656
5657 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
5658
5659 * exp_ch7.adb (Process_Declarations): Do not consider the result of a
5660 tag-to-class-wide conversion as needing finalization actions.
5661 * exp_util.adb (Has_Controlled_Objects): Do not consider the result of
5662 a tag-to-class-wide conversion as needing finalization actions.
5663 (Is_Finalizable_Transient): The result of a tag-to-class-wide
5664 conversion does not need finalization actions.
5665 (Is_Tag_To_CW_Conversion): New routine.
5666 * exp_util.ads (Is_Tag_To_CW_Conversion): New routine. Determines
5667 whether an object is the result of a tag-to-class-wide conversion.
5668
5669 2011-08-04 Yannick Moy <moy@adacore.com>
5670
5671 * sem_ch13.adb (Analyze_Aspect_Specifications): correct order in which
5672 the left-hand-side and right-hand-side of a conjunct are inserted when
5673 translating a pre- or postcondition
5674 * sem_ch6.adb: Correct typo in comment
5675
5676 2011-08-04 Ed Schonberg <schonberg@adacore.com>
5677
5678 * gnat_rm.texi: Ravenscar does not prohibit dependence on
5679 Unchecked_Conversion and Unchecked_Deallocation.
5680
5681 2011-08-04 Thomas Quinot <quinot@adacore.com>
5682
5683 * make.adb: Minor reformatting.
5684
5685 2011-08-04 Emmanuel Briot <briot@adacore.com>
5686
5687 * prj.adb, prj.ads, makeutl.adb (Complete_Mains): search for the
5688 sources in the project and its imported projects, but not in the whole
5689 tree.
5690
5691 2011-08-04 Emmanuel Briot <briot@adacore.com>
5692
5693 * make.adb: Remove debug trace.
5694
5695 2011-08-04 Vincent Celier <celier@adacore.com>
5696
5697 * makeutl.adb (Do_Complete): Get the absolute path name of a relative
5698 path in canonical form, to be able to compare path names on platforms
5699 such as Windows or Darwin.
5700
5701 2011-08-04 Thomas Quinot <quinot@adacore.com>
5702
5703 * par_sco.adb (Traverse_Declarations_Or_Statements.Set_Statement_Entry):
5704 For a pragma (statement with C1 = 'P'), record the sloc of the pragma.
5705 * scos.ads: Update documentation accordingly.
5706 * put_scos.adb (Output_SCO_Line): Omit statement SCOs for disabled
5707 pragmas.
5708
5709 2011-08-04 Ed Schonberg <schonberg@adacore.com>
5710
5711 * sem_attr.adb (Bad_Attribute_For_Predicate): flag illegal use of
5712 attribute only if prefix type is scalar.
5713
5714 2011-08-04 Emmanuel Briot <briot@adacore.com>
5715
5716 * make.adb, makeutl.adb, prj-env.adb (Check_Mains): put back support
5717 in gnatmake for specifying mains on the command line that do not belong
5718 to the main project. These mains must currently all belong to the same
5719 project, though.
5720 (Ultimate_Extension_Of): removed, since duplicated
5721 Ultimate_Extending_Project.
5722
5723 2011-08-04 Arnaud Charlet <charlet@adacore.com>
5724
5725 * make.adb (Do_Codepeer_Globalize_Step): Removed. Use CodePeer_Mode
5726 instead.
5727 (CodePeer_Mode_String): New.
5728 (Linking_Phase, Binding_Phase): Call gnatlink with -P switch in
5729 CodePeer mode.
5730 (Scan_Make_Arg): Do not disable binding/linking phase in CodePeer mode.
5731 * bindgen.adb (Gen_Elab_Calls_Ada): Ignore subprograms in CodePeer
5732 mode, since no useful elaboration subprogram is needed by CodePeer.
5733 * gnatlink.adb (Gnatlink): Add support for -P switch (CodePeer mode).
5734 In this mode, compile binder file with -gnatC and do stop after this
5735 step.
5736
5737 2011-08-04 Vincent Celier <celier@adacore.com>
5738
5739 * exp_ch7.adb: Minor comment fix.
5740
5741 2011-08-04 Robert Dewar <dewar@adacore.com>
5742
5743 * exp_ch7.adb, make.adb, sem_ch10.adb, bindgen.adb, sem_res.adb,
5744 exp_ch4.adb, makeutl.adb: Minor reformatting.
5745
5746 2011-08-04 Emmanuel Briot <briot@adacore.com>
5747
5748 * make.adb, makeutl.adb, makeutl.ads (Make): major refactoring.
5749 Create several new subprograms to move code out of Make. This makes the
5750 code more readable, removes code duplication, and is a preparation work
5751 for adding support for aggregate projects.
5752
5753 2011-08-04 Tristan Gingold <gingold@adacore.com>
5754
5755 * s-po32gl.ads, s-po32gl.adb: New files.
5756 * exp_ch7.ads (Get_Global_Pool_For_Access_Type): New function.
5757 * exp_ch7.adb (Get_Global_Pool_For_Access_Type): New function.
5758 (Build_Finalization_Collection): Use it.
5759 * exp_ch4.adb (Complete_Controlled_Allocation): Ditto.
5760 * rtsfind.ads: System_Pool_32_Global, Re_Global_Pool_32_Object: New
5761 literals.
5762 * gcc-interface/Makefile.in: Use s-po32gl.o on VMS.
5763 * gcc-interface/Make-lang.in: Update dependencies.
5764
5765 2011-08-04 Emmanuel Briot <briot@adacore.com>
5766
5767 * makeutl.adb (Complete_Mains): add support for specs with no suffix on
5768 the command line.
5769
5770 2011-08-04 Emmanuel Briot <briot@adacore.com>
5771
5772 * make.adb, makeutl.adb (Complete_Mains): if a main specified on the
5773 command line is not a file name, also check whether it could be a unit
5774 name.
5775
5776 2011-08-04 Eric Botcazou <ebotcazou@adacore.com>
5777
5778 * bindgen.adb (Gen_Finalize_Library_Ada): Factor out code to generate
5779 the header of the finalization routine.
5780 If the unit has no finalizer but is a body whose spec has one, then
5781 generate the decrement of the elaboration entity only.
5782 If the unit has a finalizer and is a spec, then do not generate the
5783 decrement of the elaboration entity.
5784 (Gen_Finalize_Library_C): Likewise.
5785
5786 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
5787
5788 * exp_ch7.adb (Alignment_Of): New subsidiary routine.
5789 (Bounds_Size_Expression): Removed.
5790 (Double_Alignment_Of): New subsidiary routine.
5791 (Make_Finalize_Address_Stmts): New local variable Index_Typ. Account
5792 for a hole in the dope vector of unconstrained arrays due to different
5793 index and element alignments.
5794
5795 2011-08-04 Ed Schonberg <schonberg@adacore.com>
5796
5797 * sem_res.adb (Resolve_Allocator): diagnose task allocator that will
5798 raise program_error because body has not been seen yet.
5799
5800 2011-08-04 Ed Schonberg <schonberg@adacore.com>
5801
5802 * sem_ch10.adb (Analyze_With_Clause): Protect against child unit with
5803 an unresolved name.
5804
5805 2011-08-04 Vincent Celier <celier@adacore.com>
5806
5807 * makeutl.adb (Do_Complete): Check absolute paths in canonical forms
5808
5809 2011-08-04 Yannick Moy <moy@adacore.com>
5810
5811 * alfa.adb, alfa.ads (Unique_Defining_Entity): move function from here
5812 * sem_util.adb, sem_util.ads (Unique_Defining_Entity): ...to here
5813
5814 2011-08-04 Thomas Quinot <quinot@adacore.com>
5815
5816 * sem_ch12.adb (Analyze_Package_Instantiation): Do not omit body for
5817 instantiation in RCI.
5818
5819 2011-08-04 Emmanuel Briot <briot@adacore.com>
5820
5821 * make.adb: Share more code with gprbuild
5822
5823 2011-08-04 Emmanuel Briot <briot@adacore.com>
5824
5825 * projects.texi: Added documentation for the IDE'Gnat project file
5826 attribute.
5827
5828 2011-08-04 Nicolas Roche <roche@adacore.com>
5829
5830 * gnat_rm.texi: Minor editing.
5831
5832 2011-08-04 Javier Miranda <miranda@adacore.com>
5833
5834 * bindgen.adb (Gen_Adafinal_Ada): Do not differentiate the main case
5835 and the library case for VM targets.
5836 (Gen_Adainit_Ada): Likewise.
5837
5838 2011-08-04 Robert Dewar <dewar@adacore.com>
5839
5840 * g-altive.ads: Minor comment updates.
5841 * prj-nmsc.adb: Minor reformatting.
5842
5843 2011-08-04 Javier Miranda <miranda@adacore.com>
5844
5845 * opt.ads
5846 (Normalize_Scalars_Config): Value of the configuration switch set by
5847 pragma Normalize_Scalars when it appears in the gnat.adc file.
5848 (Normalize_Scalars): New field for record Config_Switches_Type. Used
5849 to save and restore settings of this pragma.
5850 * opt.adb
5851 (Register_Opt_Config_Switches, Save_Opt_Config_Switches,
5852 Restore_Opt_Config_Switches): Add missing support for Normalize_Scalars.
5853
5854 2011-08-04 Vincent Celier <celier@adacore.com>
5855
5856 * gnat_ugn.texi: Document gnatlink options -M and -M=mapfile
5857
5858 2011-08-04 Arnaud Charlet <charlet@adacore.com>
5859
5860 * makeutl.adb: Minor reformatting.
5861
5862 2011-08-04 Olivier Hainque <hainque@adacore.com>
5863
5864 * g-altive.ads: Update comments to reflect that only the soft
5865 binding is available today.
5866
5867 2011-08-04 Robert Dewar <dewar@adacore.com>
5868
5869 * bindgen.adb, einfo.adb, sem_ch12.adb, s-tasren.adb, sem_res.adb,
5870 makeutl.adb, prj-nmsc.adb, opt.ads, prj-env.adb: Minor reformatting
5871 * gcc-interface/Make-lang.in: Update dependencies.
5872
5873 2011-08-04 Arnaud Charlet <charlet@adacore.com>
5874
5875 * prj-env.adb: Remove local debug traces.
5876
5877 2011-08-04 Yannick Moy <moy@adacore.com>
5878
5879 * checks.adb (Apply_Float_Conversion_Check): correct a typo where Lo_OK
5880 was used instead of Hi_OK, which could cause a read of an uninitialized
5881 value later on. Detected while working on the new warning.
5882 * exp_ch9.adb (Expand_N_Entry_Declaration): remove useless assignment
5883 to local variable.
5884 * sem_ch5.adb (Analyze_Assignment): set the last assignment component
5885 in more cases, in order to detect more unreferenced values.
5886 * sem_util.adb, sem_util.ads (Get_Enclosing_Object): return enclosing
5887 object for expression, if any.
5888
5889 2011-08-04 Eric Botcazou <ebotcazou@adacore.com>
5890
5891 * exp_intr.adb (Expand_Binary_Operator_Call): Look at the RM size of
5892 the operand types instead of the Esize.
5893
5894 2011-08-04 Steve Baird <baird@adacore.com>
5895
5896 * switch-b.adb (Scan_Binder_Switches): Add -P binder switch, used to
5897 enable CodePeer_Mode.
5898 * bindusg.adb (Display): Add help message describing -P binder switch.
5899 * gnat_ugn.texi: Document -P binder switch.
5900 * bindgen.adb (Gen_Main_Ada): If CodePeer_Mode is set, then call the
5901 user-defined main program directly.
5902 (Gen_Output_File_Ada): If CodePeer_Mode is set, generate a with of the
5903 user-defined main program in the context clause of the package body.
5904
5905 2011-08-04 Yannick Moy <moy@adacore.com>
5906
5907 * alfa.adb, alfa.ads (Get_Entity_For_Decl): remove function, partial
5908 duplicate of Defining_Entity
5909 (Get_Unique_Entity_For_Decl): rename function into
5910 Unique_Defining_Entity
5911 * einfo.adb, einfo.ads (Is_In_ALFA, Body_Is_In_ALFA): remove flags
5912 (Formal_Proof_On): remove synthesized flag
5913 * cstand.adb, sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
5914 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_res.adb, sem_util.adb,
5915 sem_util.ads, stand.ads: Remove treatment associated to entities in ALFA
5916 * sem_prag.adb (Analyze_Pragma): remove special treatment for pragma
5917 Annotate (Formal_Proof)
5918
5919 2011-08-04 Emmanuel Briot <briot@adacore.com>
5920
5921 * prj-env.adb (Create_Config_Pragmas_File): fix handling of multi-unit
5922 source files with non-standard naming schemes, in imported projects
5923
5924 2011-08-04 Emmanuel Briot <briot@adacore.com>
5925
5926 * makeutl.adb (Complete_Mains): when a multi-unit source file is
5927 specified on the gprbuild command line, we need to compile all units
5928 within that file, not just the first one we find
5929 Fix error message for mains that are not found.
5930
5931 2011-08-04 Thomas Quinot <quinot@adacore.com>
5932
5933 * sem_ch6.adb: Update comment.
5934 * sem_ch12.adb: Minor reformatting.
5935
5936 2011-08-04 Bob Duff <duff@adacore.com>
5937
5938 * s-tasren.adb (Task_Do_Or_Queue): Previous code was reading
5939 Acceptor.Terminate_Alternative without locking Acceptor, which causes a
5940 race condition whose symptom is to fail to lock Parent. That, in turn,
5941 causes Parent.Awake_Count to be accessed without locking Parent, which
5942 causes another race condition whose symptom is that Parent.Awake_Count
5943 can be off by 1 (either too high or too low). The solution is to lock
5944 Parent unconditionally, and then lock Acceptor, before reading
5945 Acceptor.Terminate_Alternative.
5946
5947 2011-08-04 Arnaud Charlet <charlet@adacore.com>
5948
5949 * debug.adb: Update comment.
5950
5951 2011-08-04 Robert Dewar <dewar@adacore.com>
5952
5953 * par_sco.adb, exp_util.adb, make.adb, a-tags.adb, sem_prag.adb,
5954 sem_util.adb, sem_attr.adb, exp_ch4.adb, g-comlin.adb, g-comlin.ads,
5955 exp_ch6.adb: Minor reformatting.
5956
5957 2011-08-04 Gary Dismukes <dismukes@adacore.com>
5958
5959 * gnat_ugn.texi: Add sentence about the case of compile-time-detected
5960 checks for -gnateE.
5961
5962 2011-08-04 Ed Schonberg <schonberg@adacore.com>
5963
5964 * gnat_rm.texi: update Ravenscar desription to reflect Ada2012 RM.
5965
5966 2011-08-04 Thomas Quinot <quinot@adacore.com>
5967
5968 * sinfo.ads: Minor reformatting.
5969
5970 2011-08-04 Emmanuel Briot <briot@adacore.com>
5971
5972 * makeutl.adb, makeutl.ads, prj-nmsc.adb (Complete_Mains): report error
5973 even if there is no location.
5974
5975 2011-08-04 Ed Schonberg <schonberg@adacore.com>
5976
5977 * sem_res.adb, sem_ch4.adb: move check for restriction
5978 No_Task_Hierarchy to resolve_allocator.
5979
5980 2011-08-04 Thomas Quinot <quinot@adacore.com>
5981
5982 * sinfo.adb, sinfo.ads, sem_prag.adb, sem_ch12.adb (Pragma_Enabled):
5983 This flag of N_Pragma nodes is not used, remove it as well as all of
5984 the associated circuitry.
5985
5986 2011-08-04 Javier Miranda <miranda@adacore.com>
5987
5988 * exp_disp.adb (Make_DT): Switch -gnatdQ disables the generation of the
5989 runtime check on duplicated externa tags
5990 * debug.adb Document switch -gnatdQ.
5991
5992 2011-08-04 Gary Dismukes <dismukes@adacore.com>
5993
5994 * a-fihema.ads: Minor typo fix.
5995
5996 2011-08-04 Yannick Moy <moy@adacore.com>
5997
5998 * sem_ch10.adb: Minor comment update.
5999
6000 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6001
6002 * einfo.adb: Update the node field usage to reflect the renaming of
6003 Return_Flag to Return_ Flag_Or_Transient_Decl.
6004 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl.
6005 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl.
6006 (Write_Field15_Name): Change Return_Flag to
6007 Return_Flag_Or_Transient_Decl.
6008 * einfo.ads: Rename node field Return_Flag to
6009 Return_Flag_Or_Transient_Decl. Update the associated comment and all
6010 occurrences in entities.
6011 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl. Update
6012 associated Inline pragma.
6013 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl. Update
6014 associated Inline pragma.
6015 * exp_ch4.ads, exp_ch4.adb (Expand_N_Expression_With_Actions): New
6016 routine.
6017 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Update the calls to
6018 Return_Flag and Set_Return_Flag.
6019 * exp_ch7.adb (Process_Declarations): Add code to recognize hook
6020 objects generated for controlled transients declared inside an
6021 Exception_With_Actions. Update the calls to Return_Flag.
6022 (Process_Object_Declaration): Add code to add a null guard for hook
6023 objects generated for controlled transients declared inside an
6024 Exception_With_Actions. Update related comment.
6025 * exp_util.adb (Has_Controlled_Objects): Add code to recognize hook
6026 objects generated for controlled transients declared inside an
6027 Exception_With_Actions. Update the calls to Return_Flag.
6028 * expander.adb (Expand): Add new case for N_Expression_With_Actions.
6029
6030 2011-08-04 Ed Schonberg <schonberg@adacore.com>
6031
6032 * sem_util.adb:(Wrong_Type): Improve error message on a one-element
6033 positional aggregate.
6034
6035 2011-08-04 Vincent Celier <celier@adacore.com>
6036
6037 * par_sco.adb (Process_Decisions.Output_Header): Check and record pragma
6038 SLOC only for pragmas.
6039
6040 2011-08-04 Emmanuel Briot <briot@adacore.com>
6041
6042 * projects.texi: Minor typo fix.
6043
6044 2011-08-04 Emmanuel Briot <briot@adacore.com>
6045
6046 * prj-nmsc.adb (Check_File): Minor change to traces, to help debugging
6047 on case-sensitive file systems.
6048
6049 2011-08-04 Thomas Quinot <quinot@adacore.com>
6050
6051 * put_scos.adb (Put_SCOs): Do not emit decision SCO for an X decision
6052 nested in a disabled pragma.
6053 * scos.ads, scos.adb, par_sco.ads, par_sco.adb: Record sloc of
6054 enclosing pragma, if any, for X decisions.
6055
6056 2011-08-04 Thomas Quinot <quinot@adacore.com>
6057
6058 * sem_prag.adb: Minor reformatting.
6059
6060 2011-08-04 Vincent Celier <celier@adacore.com>
6061
6062 * a-tags.adb (Check_TSD): Avoid concatenation of strings, as it is not
6063 allowed in no run time mode.
6064
6065 2011-08-04 Vincent Celier <celier@adacore.com>
6066
6067 * make.adb (Check): When -gnatc is used, check for the source file
6068 inside the ALI file with a canonical case file name.
6069
6070 2011-08-04 Emmanuel Briot <briot@adacore.com>
6071
6072 * g-comlin.adb, g-comlin.ads (Add_Switch): Put back support for
6073 overriding the separator.
6074
6075 2011-08-04 Robert Dewar <dewar@adacore.com>
6076
6077 * sem_aggr.adb, par_sco.adb, sem_type.adb, exp_util.adb, exp_ch9.adb,
6078 prj-nmsc.adb, sem_ch13.adb, exp_strm.adb: Minor reformatting.
6079
6080 2011-08-04 Robert Dewar <dewar@adacore.com>
6081
6082 * gnat_rm.texi: Minor documentation fix for pragma Annotate.
6083
6084 2011-08-04 Yannick Moy <moy@adacore.com>
6085
6086 * sem_attr.adb (Analyze_Attribute): add check during pre-analysis that
6087 'Result only appears in postcondition of function.
6088
6089 2011-08-04 Thomas Quinot <quinot@adacore.com>
6090
6091 * a-tags.adb (Check_TSD): When raising PROGRAM_ERROR for a duplicated
6092 external tag, include the value of the external tag in the exception
6093 message.
6094
6095 2011-08-04 Yannick Moy <moy@adacore.com>
6096
6097 * sem_attr.adb (Result): modify error message for misplaced 'Result
6098
6099 2011-08-04 Sergey Rybin <rybin@adacore.com>
6100
6101 * gnat_rm.texi (pragma Annotate): Fix syntax description to make it
6102 clear that the second argument must be an identifier.
6103
6104 2011-08-04 Thomas Quinot <quinot@adacore.com>
6105
6106 * exp_ch9.adb (Build_Barrier_Function): When compiling with
6107 -fpreserve-control-flow, insert an IF statement on the barrier
6108 condition to ensure that a conditional branch instruction is generated.
6109
6110 2011-08-04 Emmanuel Briot <briot@adacore.com>
6111
6112 * prj-part.adb, prj.adb, prj.ads, prj-tree.ads
6113 (Processing_Flags.Ignore_Missing_With): new flag.
6114
6115 2011-08-04 Emmanuel Briot <briot@adacore.com>
6116
6117 * prj-nmsc.adb (Find_Sources, Path_Name_Of): Fix handling of
6118 Source_List_File on case-insensitive systems where the file is actually
6119 on a case-sensitive file system (NFS,...).
6120
6121 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6122
6123 * sem_ch6.adb (Analyze_Function_Return): In a rare case where a
6124 function return contains a controlled [extension] aggregate and the
6125 return statement is not part of a handled sequence of statements, wrap
6126 the return in a block. This ensures that all controlled temporaries
6127 generated during aggregate resolution will be picked up by the
6128 finalization machinery.
6129
6130 2011-08-04 Ed Schonberg <schonberg@adacore.com>
6131
6132 * sem_aggr.adb (Resolve_Aggregate): If aggregate has box-initialized
6133 components, freeze type before resolution, to ensure that default
6134 initializations are present for all components.
6135 * sem_res.adb (Resolve_Actuals): the designated object of an
6136 accces-to-constant type is a legal actual in a call to an
6137 initialization procedure.
6138
6139 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6140
6141 * exp_util.adb (Extract_Renamed_Object): Add N_Type_Conversion and
6142 N_Unchecked_Type_Conversion to the possible containers of a renamed
6143 transient variable.
6144
6145 2011-08-04 Yannick Moy <moy@adacore.com>
6146
6147 * par-ch13.adb (Aspect_Specifications_Present): recognize
6148 "with Identifier'Class =>" as an aspect, so that a meaningful warning
6149 is issued in Strict mode.
6150 * par.adb: Fix typos in comments.
6151
6152 2011-08-04 Yannick Moy <moy@adacore.com>
6153
6154 * sem_attr.adb (Result): modify error message to take into account Post
6155 aspect when compiling Ada 2012 (or newer) code.
6156
6157 2011-08-04 Nicolas Roche <roche@adacore.com>
6158
6159 * env.c (__gnat_clearenv): Avoid use of dynamic size array in order to
6160 remove need for GCC exceptions.
6161
6162 2011-08-04 Vincent Celier <celier@adacore.com>
6163
6164 * makeutl.adb (Do_Complete): Call Debug_Output with the name of the
6165 project, not the source file name.
6166 * prj.adb (Find_Sources.Look_For_Sources): If the source has been
6167 excluded, continue looking. This excluded source will only be returned
6168 if there is no other source with the same base name that is not locally
6169 removed.
6170
6171 2011-08-04 Ed Schonberg <schonberg@adacore.com>
6172
6173 * sem_res.adb (Resolve_Intrinsic_Operator): if the result type is
6174 private and one of the operands is a real literal, use a qualified
6175 expression rather than a conversion which is not meaningful to the
6176 back-end.
6177
6178 2011-08-04 Yannick Moy <moy@adacore.com>
6179
6180 * sem_ch13.adb (Aspect_Loop): when an aspect X and its classwise
6181 corresponding aspect X'Class are allowed, proceed with analysis of the
6182 aspect instead of skipping it.
6183
6184 2011-08-04 Tristan Gingold <gingold@adacore.com>
6185
6186 * s-flocon.adb, s-flocon.ads: Add a body for s-flocon.ads
6187 This will allow to have an Ada implementation for the subprogram.
6188
6189 2011-08-04 Ed Schonberg <schonberg@adacore.com>
6190
6191 * sem_ch3.adb (Analyze_Full_Type_Declaration): If the declaration is a
6192 completion and aspects are present, apply them to the entity for the
6193 type which is currently the partial view, but which is the one that
6194 will be frozen.
6195 * sem_ch13.adb (Analyze_Aspect_Specifications): if the predicate
6196 applies to a partial view, indicate that the full view has predicates
6197 and delayed aspects.
6198 (Replace_Type_Reference): Handle properly predicates that apply to the
6199 full view of a private completion.
6200
6201 2011-08-04 Eric Botcazou <ebotcazou@adacore.com>
6202
6203 * layout.adb (Layout_Type): For composite types, do not set Esize.
6204 * freeze.adb (Set_Small_Size): Remove test on alignment and do not
6205 set Esize.
6206 (Size_Known): Look at the RM size of components instead of the Esize.
6207 (Freeze_Record_Type): Look at the RM size instead of the Esize to
6208 issue warning and activate Implicit_Packing.
6209 (Freeze_Entity): Likewise. Do not issue a warning for alias/atomic
6210 if the Esize is not known.
6211 * sem_ch13.adb (Analyze_Attribute_Definition_Clause) <Size>: Set Esize
6212 for elementary types only.
6213 (Analyze_Record_Representation_Clause): Look at the RM size instead
6214 of the Esize to issue errors.
6215 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not set Esize if it
6216 is not known.
6217 <E_Record_Type>: Look at the RM size instead of the Esize. Remove
6218 obsolete block.
6219 Look at the RM size instead of the Esize for types if the latter is
6220 not known.
6221 (gnat_to_gnu_field): Use Known_Esize instead of Known_Static_Esize.
6222
6223 2011-08-04 Ed Schonberg <schonberg@adacore.com>
6224
6225 * sem_type.adb: proper handling of equality not involving anonymous
6226 access types.
6227
6228 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6229
6230 * exp_ch7.adb (Create_Finalizer): Remove local variables Spec_Nod and
6231 Vis_Decls. When creating a library-level finalizer for a package spec,
6232 both the declaration and body of the finalizer are inserted either in
6233 the visible or private declarations of the package spec.
6234
6235 2011-08-04 Javier Miranda <miranda@adacore.com>
6236
6237 * sem_ch3.adb (Derive_Subprograms): Complete assertion to request the
6238 use of the full-view of a type when invoking Is_Ancestor.
6239 * sem_type.adb (Is_Ancestor): For consistency, when the traversal of
6240 the full-view of private parents is requested, then use also the
6241 full-view of the parent of the first derivation.
6242
6243 2011-08-04 Tristan Gingold <gingold@adacore.com>
6244
6245 * s-taprop-vxworks.adb (Enter_Task): Use System.Float_Control.Reset
6246 instead of the locally imported procedure.
6247 * s-taprop-mingw.adb (Enter_Task): Ditto.
6248 * s-valrea.adb (Scan_Real): Ditto.
6249 * s-imgrea.adb (Set_Image_Real): Ditto.
6250 * s-flocon.ads: Make the package pure.
6251
6252 2011-08-04 Thomas Quinot <quinot@adacore.com>
6253
6254 * sinfo.ads, sinfo.adb (Debug_Statement, Set_Debug_Statement): Remove.
6255 * tbuild.ads, tbuild.adb (Make_Pragma): Adjust accordingly.
6256 * sinfo-cn.ads, sinfo-cn.adb (Change_Name_To_Procedure_Call_Statement):
6257 New subprogram, moved here from...
6258 * par.adb, par-ch5.adb (P_Statement_Name): ... here.
6259 * par-prag.adb (Par.Prag, case Pragma_Debug): Do not perform any
6260 rewriting of the last argument into a procedure call statement here...
6261 * sem_prag.adb (Analyze_Pragma, case Pragma_Debug): ...do it there
6262 instead.
6263
6264 2011-08-04 Thomas Quinot <quinot@adacore.com>
6265
6266 * par_sco.adb: Minor reformatting.
6267
6268 2011-08-04 Robert Dewar <dewar@adacore.com>
6269
6270 * erroutc.adb: Minor reformatting.
6271
6272 2011-08-04 Thomas Quinot <quinot@adacore.com>
6273
6274 * par_sco.adb: Comment update.
6275
6276 2011-08-04 Tristan Gingold <gingold@adacore.com>
6277
6278 * s-flocon.ads: New file.
6279 * g-flocon.ads: Now a renaming of s-flocon.
6280 * Makefile.rtl: Add s-flocon.o
6281
6282 2011-08-04 Javier Miranda <miranda@adacore.com>
6283
6284 * exp_strm.adb (Build_Array_Input_Function): if the array type is
6285 constrained, do not attempt to build a subtype of it.
6286
6287 2011-08-04 Yannick Moy <moy@adacore.com>
6288
6289 * errout.ads Change comments: remove 'R'M as an example where quotes
6290 are needed; add ALFA as another case where quotes are not needed
6291 * erroutc.adb (Set_Msg_Insertion_Reserved_Word): add ALFA as another
6292 case where quotes are not needed.
6293 * sem_ch11.adb, sem_ch13.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
6294 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_prag.adb, sem_res.adb:
6295 Remove all occurrences of 'A'L'F'A
6296
6297 2011-08-04 Ed Schonberg <schonberg@adacore.com>
6298
6299 * sem_ch13.adb: check legality of invariant pragma.
6300
6301 2011-08-04 Eric Botcazou <ebotcazou@adacore.com>
6302
6303 * bindgen.adb: Add comments.
6304
6305 2011-08-04 Yannick Moy <moy@adacore.com>
6306
6307 * einfo.adb, einfo.ads: Free Flag254 and make Formal_Proof_On a
6308 synthesized flag.
6309 * sem_prag.adb (Analyze_Pragma): record the pragma Annotate
6310 (Formal_Proof, On/Off) in the Rep_Item list of the current subprogram.
6311
6312 2011-08-04 Robert Dewar <dewar@adacore.com>
6313
6314 * exp_ch7.adb, exp_ch6.adb, sem_ch3.adb, layout.adb, sem_ch5.adb,
6315 osint-c.ads, sem_util.ads, gnat1drv.adb, targparm.ads, sem_ch6.adb,
6316 sem_ch13.adb, s-pooloc.adb: Minor reformatting.
6317
6318 2011-08-04 Thomas Quinot <quinot@adacore.com>
6319
6320 * s-pooloc.ads, s-pooglo.ads: Minor reformatting
6321
6322 2011-08-04 Thomas Quinot <quinot@adacore.com>
6323
6324 PR ada/47880
6325 * s-pooloc.adb (Deallocate): Fix the case of deallocating the only
6326 allocated object.
6327
6328 2011-08-04 Robert Dewar <dewar@adacore.com>
6329
6330 * einfo.ads, exp_ch4.adb: Minor reformatting.
6331
6332 2011-08-04 Jerome Lambourg <lambourg@adacore.com>
6333
6334 * back_end.ads (Gen_Or_Update_Object_File): Add more comments.
6335
6336 2011-08-04 Ed Schonberg <schonberg@adacore.com>
6337
6338 * exp_ch4.adb (Expand_Composite_Equality): code cleanup: use component
6339 type in all cases to compute list of primitive operations, because full
6340 view may be an itype that is not attached to the list of declarations.
6341
6342 2011-08-04 Eric Botcazou <ebotcazou@adacore.com>
6343
6344 * bindgen.adb (Gen_Adafinal_Ada): Generate an early return if the
6345 library has already been finalized.
6346 (Gen_Adafinal_C): Likewise.
6347 (Gen_Adainit_Ada): Generate an early return if the library has
6348 already been elaborated.
6349 (Gen_Adainit_C): Likewise.
6350 (Gen_Output_File_Ada): Generate an elaboration flag.
6351 (Gen_Output_File_C): Likewise.
6352
6353 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6354
6355 * exp_ch4.adb (Expand_Allocator_Expression): Disable the generation of
6356 Set_Finalize_Address_Ptr for CodePeer because Finalize_Address was not
6357 built in the first place.
6358 (Expand_N_Allocator): Disable the generation of Set_Finalize_Address_Ptr
6359 for CodePeer because Finalize_Address was not built to begin with.
6360 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Ditto.
6361
6362 2011-08-04 Pascal Obry <obry@adacore.com>
6363
6364 * adaint.c (__gnat_tmp_name): Use current process id to create temp
6365 filenames, this ensures unicity of filenames across processes.
6366
6367 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6368
6369 * bindgen.adb (Gen_Finalize_Library_Ada): Rename generated routine
6370 Raise_Controlled to Raise_From_Controlled_Operation. Update the
6371 signature of Raise_From_Controlled_Operation by adding flag From_Abort.
6372 Add False as the actual to From_Abort in the generated call to
6373 Raise_From_Controlled_Operation.
6374
6375 2011-08-04 Jerome Lambourg <lambourg@adacore.com>
6376
6377 * osint-c.ads, osint-c.adb (Set_Library_Info_Name): Move to declaration
6378 so that the ali file name can be retrieved from outside of this package.
6379 * back_end.ads, back_end.adb (Gen_Or_Update_Object_File): New method
6380 doing nothing in the general case, but used to update the object file
6381 timestamp if directly generated by the backend.
6382 * gnat1drv.adb (Gnat1drv): Make sure the object file's timestamp is set
6383 to a later time than the ali file one.
6384
6385 2011-08-04 Yannick Moy <moy@adacore.com>
6386
6387 * einfo.adb, einfo.ads (Formal_Proof_On): new flag set on subprogram
6388 entities whose body contains an Annotate pragma which forces formal
6389 proof on this body.
6390 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
6391 sem_ch6.adb, sem_ch9.adb, sem_res.adb: Adapt call to
6392 Mark_Non_ALFA_Subprogram to pass in a message and node.
6393 * sem_prag.adb (Analyze_Pragma): add treatment of pragma Annotate
6394 (Forma_Proof, On) which sets the flag Formal_Proof_On in the
6395 surrounding subprogram.
6396 * sem_util.adb, sem_util.ads (Mark_Non_ALFA_Subprogram,
6397 Mark_Non_ALFA_Subprogram_Unconditional): if the subprogram being marked
6398 as not in ALFA is annotated with Formal_Proof being On, then an error
6399 is issued based on the additional parameters for message and node.
6400 * snames.ads-tmpl (Name_Formal_Proof): new name for annotation.
6401 * gcc-interface/Make-lang.in: Update dependencies.
6402
6403 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6404
6405 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Do not generate
6406 Finalize_Address when CodePeer is enabled.
6407
6408 2011-08-04 Pascal Obry <obry@adacore.com>
6409
6410 * adaint.c (__gnat_tmp_name): Use _tempnam() instead of tempnam() as
6411 the latter returns a pointer to a static buffer which is deallocated
6412 at the end of the routine.
6413
6414 2011-08-04 Yannick Moy <moy@adacore.com>
6415
6416 * sem_ch3.adb (Array_Type_Declaration): move test for type in ALFA
6417 after index creation; mark unconstrained base array type generated as
6418 being in/not in ALFA as well
6419 (Make_Index): mark subtype created as in/not in ALFA
6420 * sem_ch5.adb (Analyze_Iteration_Scheme): mark entity for iterating
6421 over a loop as in/not in ALFA, depending on its type and form of loop
6422 iteration.
6423
6424 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6425
6426 * exp_ch7.adb (Build_Object_Declarations): Initialize flag Abort
6427 directly to False on .NET and JVM.
6428
6429 2011-08-04 Yannick Moy <moy@adacore.com>
6430
6431 * sem_ch3.adb (Constrain_Enumeration, Constrain_Integer): remove
6432 constraint that subtype must come from source code to be in ALFA, so
6433 that anonymous subtypes can be in ALFA too.
6434
6435 2011-08-04 Yannick Moy <moy@adacore.com>
6436
6437 * sem_ch3.adb (Analyze_Object_Declaration): remove obsolete addition of
6438 reference for ALFA mode.
6439 * lib-xref-alfa.adb, lib-xref.ads (Traverse_Compilation_Unit): make
6440 procedure public so as to use it from formal verification back-end.
6441
6442 2011-08-04 Jerome Lambourg <lambourg@adacore.com>
6443
6444 * g-comlin.adb (For_Each_Simple_Switch.Is_In_Config): Remove the
6445 invalid checks of the Parameter, making Remove_Switch not working
6446 correctly.
6447
6448 2011-08-04 Arnaud Charlet <charlet@adacore.com>
6449
6450 * targparm.ads: Update header: no run-time exception is needed on this
6451 file.
6452
6453 2011-08-04 Vincent Celier <celier@adacore.com>
6454
6455 * a-fihema.adb: Use System.IO instead of GNAT.IO
6456
6457 2011-08-04 Thomas Quinot <quinot@adacore.com>
6458
6459 * sem_ch3.adb (Access_Definition): Anonymous access to subprogram types
6460 are forbidden in Compiler_Unit mode.
6461
6462 2011-08-04 Robert Dewar <dewar@adacore.com>
6463
6464 * sem_util.adb: Minor reformatting.
6465
6466 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6467
6468 * bindgen.adb (Gen_Finalize_Library_Ada): Update the import string for
6469 library-level finalizers.
6470 (Gen_Finalize_Library_C): Update the import string for library-level
6471 finalizers.
6472 (Gen_Finalize_Library_Defs_C): Update the definition name of a
6473 library-level finalizer.
6474 * exp_ch7.adb: Remove with and use clauses for Stringt.
6475 (Create_Finalizer): Remove local variables Conv_Name, Prag_Decl,
6476 Spec_Decl. Add local variable Body_Id. The names of library-level
6477 finalizers are now manually fully qualified and are no longer external.
6478 A single name is now capable of servicing .NET, JVM and non-VM targets.
6479 Pragma Export is no longer required to provide visibility for the name.
6480 (Create_Finalizer_String): Removed.
6481 (New_Finalizer_Name): New routine which mimics New_..._Name.
6482
6483 2011-08-04 Eric Botcazou <ebotcazou@adacore.com>
6484
6485 * sem_elab.adb (Check_Internal_Call_Continue): Change the type of the
6486 elaboration counter to Standard_Short_Integer.
6487 * sem_util.adb (Build_Elaboration_Entity): Likewise.
6488 * bindgen.adb (Gen_Elab_Externals_Ada): Adjust to above change.
6489 (Gen_Elab_Externals_C): Likewise.
6490
6491 2011-08-04 Ed Falis <falis@adacore.com>
6492
6493 * system-vxworks-arm.ads, system-vxworks-sparcv9.ads,
6494 system-vxworks-ppc.ads, system-vxworks-m68k.ads,
6495 system-vxworks-mips.ads, system-vxworks-x86.ads
6496 (Always_Compatible_Rep): set to False for all VxWorks targets.
6497
6498 2011-08-04 Robert Dewar <dewar@adacore.com>
6499
6500 * par_sco.adb, prj-proc.adb, make.adb, bindgen.adb, prj.adb, prj.ads,
6501 makeutl.adb, makeutl.ads, prj-nmsc.adb, exp_ch5.adb, exp_ch12.adb,
6502 exp_ch7.ads, exp_util.ads, sem_util.ads, g-comlin.ads, exp_ch6.adb,
6503 exp_ch6.ads, lib-xref.ads, exp_ch7.adb, exp_util.adb, exp_dist.adb,
6504 exp_strm.adb, gnatcmd.adb, freeze.adb, g-comlin.adb, lib-xref-alfa.adb,
6505 sem_attr.adb, sem_prag.adb, sem_util.adb, sem_elab.adb, sem_ch8.adb,
6506 sem_ch11.adb, sem_eval.adb, sem_ch13.adb, sem_disp.adb, a-fihema.adb:
6507 Minor reformatting and code reorganization.
6508
6509 2011-08-04 Emmanuel Briot <briot@adacore.com>
6510
6511 * projects.texi: Added doc for aggregate projects.
6512
6513 2011-08-04 Emmanuel Briot <briot@adacore.com>
6514
6515 * prj-proc.adb, prj-nmsc.adb, prj-env.adb (Process_Declarative_Items):
6516 Add support for overriding the Project_Path in aggregate projects.
6517
6518 2011-08-04 Robert Dewar <dewar@adacore.com>
6519
6520 * a-cofove.ads: Minor reformatting.
6521
6522 2011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6523
6524 * exp_ch7.adb (Build_Adjust_Or_Finalize_Statements): Update the comment
6525 on the generated code.
6526 (Build_Finalize_Statements): Update the comment on the generated code.
6527 (Build_Initialize_Statements): Update the comment on the generated code.
6528 (Build_Object_Declarations): Add local variable Result. The object
6529 declarations are now built in sequence.
6530 * rtsfind.ads: Add RE_Exception_Occurrence_Access to tables RE_Id and
6531 RE_Unit_Table.
6532
6533 2011-08-04 Robert Dewar <dewar@adacore.com>
6534
6535 * checks.adb, alfa.adb, alfa.ads: Minor reformatting.
6536
6537 2011-08-04 Eric Botcazou <ebotcazou@adacore.com>
6538
6539 * einfo.ads (Elaboration_Entity): Document new definition and use.
6540 (Elaboration_Entity_Required): Adjust to above change.
6541 * exp_attr.adb (Expand_N_Attribute_Reference): Likewise.
6542 * exp_ch12.adb: And with and use for Snames.
6543 (Expand_N_Generic_Instantiation): Test 'Elaborated attribute.
6544 * exp_util.adb (Set_Elaboration_Flag): Likewise.
6545 * sem_attr.adb (Analyze_Attribute) <Check_Library_Unit>: Delete.
6546 <Check_Unit_Name>: Deal with N_Expanded_Name.
6547 <Attribute_Elaborated>: Extend to all unit names.
6548 * sem_elab.adb: And with and use for Uintp.
6549 (Check_Internal_Call_Continue): Adjust to Elaboration_Entity change.
6550 * sem_util.ads (Build_Elaboration_Entity): Adjust comment.
6551 * sem_util.adb (Build_Elaboration_Entity): Change type to Integer.
6552 * bindgen.adb (Gen_Elab_Externals_Ada): New local subprogram taken
6553 from Gen_Adainit_Ada.
6554 (Gen_Elab_Externals_C): Likewise, but taken from Gen_Adainit_C.
6555 (Gen_Adafinal_Ada): Remove redundant test. In the non-main program
6556 case, do not call System.Standard_Library.Adafinal; instead call
6557 finalize_library if needed.
6558 (Gen_Adafinal_C): Likewise.
6559 (Gen_Adainit_Ada): Do not set SSL.Finalize_Library_Objects in the
6560 non-main program case.
6561 (Gen_Adainit_C): Generate a couple of external declarations here.
6562 In the main program case, set SSL.Finalize_Library_Objects.
6563 (Gen_Elab_Calls_Ada): Adjust to Elaboration_Entity change.
6564 (Gen_Elab_Calls_C): Likewise.
6565 (Gen_Finalize_Library_Ada): Likewise. Skip SAL interface units.
6566 (Gen_Finalize_Library_C): Likewise. Generate a full function.
6567 (Gen_Main_C): Put back call to Ada_Final and don't finalize library
6568 objects here.
6569 (Gen_Output_File_Ada): Generate pragma Linker_Destructor for Ada_Final
6570 if -a is specified. Call Gen_Elab_Externals_Ada. Move around call to
6571 Gen_Adafinal_Ada.
6572 (Gen_Output_File_C): Generate __attribute__((destructor)) for Ada_Final
6573 if -a is specified. Call Gen_Elab_Externals_C. Remove useless couple
6574 of external declarations. Call Gen_Finalize_Library_C.
6575
6576 2011-08-04 Emmanuel Briot <briot@adacore.com>
6577
6578 * prj.adb, prj.ads, makeutl.adb, makeutl.ads (Complete_Mains,
6579 Compute_Compilation_Phases): new subprogram.
6580 (Builder_Data, Builder_Project_Tree_Data): new subprogram and type
6581 The number of mains as well as the various compilation phases that
6582 need to be run are now project tree specific, since various
6583 aggregated trees might have different requirements. In particular,
6584 they do not all require bind or link phases.
6585
6586 2011-08-04 Emmanuel Briot <briot@adacore.com>
6587
6588 * prj.adb, prj.ads, makeutl.adb, makeutl.ads, prj-env.adb
6589 (Project_Tree_Appdata): New type.
6590 It is now possible to associate application-specific data to a project
6591 tree. In particular, this is used in the gprbuild builder to avoid a
6592 number of global tables and htables, especially now that there can be
6593 several project trees loaded at once because of aggregate projects.
6594 (Debug_Name): new procedure.
6595 * projects.texi: Clarify syntax of "**" for Source_Dirs
6596
6597 2011-08-03 Emmanuel Briot <briot@adacore.com>
6598
6599 * prj.ads, makeutl.adb, makeutl.ads (Queue.Insert): now also inserts
6600 the "roots" for a main.
6601 (Fill_From_Project): add support for aggregate projects. Main units
6602 in aggregated projects are now automatically added in the list of
6603 files to build (although this fails later on in gprbuild, because
6604 these files are not using the root proejct tree, so this needs
6605 further cleanup)
6606 * gcc-interface/Make-lang.in: Update dependencies.
6607
6608 2011-08-03 Yannick Moy <moy@adacore.com>
6609
6610 * sem_ch4.adb (Analyze_Conditional_Expression): only allow boolean
6611 conditional expression in ALFA.
6612 * sem_res.adb (Resolve_Conditional_Expression): mark non-boolean
6613 expressions as not in ALFA.
6614
6615 2011-08-03 Robert Dewar <dewar@adacore.com>
6616
6617 * a-cofove.adb: Minor reformatting.
6618
6619 2011-08-03 Emmanuel Briot <briot@adacore.com>
6620
6621 * make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads
6622 (Insert_Project_Sources, Insert_withed_Sources_For): moved from the
6623 gprbuild sources.
6624 These packages are more logically placed in the Queue package, since
6625 they manipulate the queue. It is also likely that they can be adapted
6626 for gnatmake, thus sharing more code.
6627 (Finish_Program, Fail_Program): moved from the gprbuild sources, so
6628 that we could move the above.
6629
6630 2011-08-03 Emmanuel Briot <briot@adacore.com>
6631
6632 * errutil.adb (Finalize): clean up the list of error messages on exit.
6633 Calling this subprogram multiple times will no longer show duplicate
6634 error messages on stderr.
6635
6636 2011-08-03 Emmanuel Briot <briot@adacore.com>
6637
6638 * g-comlin.adb, g-comlin.ads (Set_Command_Line): ignore the parameter
6639 Getopt_Switches when we have already define a command line
6640 configuration.
6641
6642 2011-08-03 Yannick Moy <moy@adacore.com>
6643
6644 * sem_ch11.adb (Analyze_Raise_xxx_Error): do not mark such nodes as not
6645 in ALFA. Instead, they are considered as assertions to prove.
6646 * sem_ch4.adb (Analyze_Conditional_Expression): do not always mark such
6647 nodes as not in ALFA. Instead, include conditional expressions in ALFA
6648 if they have no ELSE part, or if they occur in pre- and postconditions,
6649 where the Condition cannot have side-effects in ALFA
6650 (Analyze_Membership_Op): do not mark such nodes as not in ALFA
6651 (Analyze_Type_Conversion): do not always mark such nodes as not in ALFA.
6652 Instead, include type conversion between scalar types in ALFA.
6653 * sem_ch6.adb (Process_Formals): correctly mark a parameter in ALFA
6654 if-and-only-if its type is in ALFA.
6655
6656 2011-08-03 Thomas Quinot <quinot@adacore.com>
6657
6658 * scos.adb, get_scos.adb, put_scos.adb
6659 New code letter for decisions: G (entry guard)
6660 * par_sco.adb
6661 (Traverse_Subprogram_Body): Rename to...
6662 (Traverse_Subprogram_Or_Task_Body): New subrpogram.
6663 (Traverse_Protected_Body): New subprogram
6664 (Traverse_Declarations_Or_Statements): Add traversal of task bodies,
6665 protected bodies and entry bodies.
6666
6667 2011-08-03 Yannick Moy <moy@adacore.com>
6668
6669 * einfo.adb, einfo.ads (Is_Postcondition_Proc): new flag for procedure
6670 entities with get/set subprograms, which is set on procedure entities
6671 generated by the compiler for a postcondition.
6672 * sem_ch6.adb (Process_PPCs): set new flag on postcondition procedures
6673 * alfa.adb, alfa.ads (Get_Entity_For_Decl): new function returning the
6674 entity for a declaration
6675 (Get_Unique_Entity_For_Decl): new function returning an entity which
6676 represents a declaration, so that matching spec and body have the same
6677 entity.
6678
6679 2011-08-03 Robert Dewar <dewar@adacore.com>
6680
6681 * a-except-2005.adb, a-cfhama.adb, a-cfhase.adb, a-cfhase.ads,
6682 a-cforma.adb, a-cforse.ads, a-cforse.adb: Minor reformatting
6683
6684 2011-08-03 Yannick Moy <moy@adacore.com>
6685
6686 * lib-xref-alfa.adb (Detect_And_Add_ALFA_Scope): make the subprogram
6687 library-level because retriction No_Implicit_Dynamic_Code in the
6688 front-end prevents its definition as a local subprogram
6689 (Traverse_Compilation_Unit): extract new procedure from Add_ALFA_File,
6690 for reuse in other contexts
6691 (Traverse_Declarations_Or_Statements,
6692 Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
6693 Traverse_Package_Declaration, Traverse_Subprogram_Body): make all these
6694 procedures take a callback parameter to be called on all declarations
6695 * lib-xref.ads
6696 (Traverse_All_Compilation_Units): new generic function to traverse a
6697 compilation unit and call a callback parameter on all declarations
6698
6699 2011-08-03 Javier Miranda <miranda@adacore.com>
6700
6701 * sem_prag.adb (Process_Interface_Name): Allow duplicated export names
6702 in Java since they are always enclosed in a namespace that
6703 differentiates them, and overloaded entities are supported by the VM.
6704
6705 2011-08-03 Ed Schonberg <schonberg@adacore.com>
6706
6707 * checks.adb (Determine_Range): If a computed bound of an operation is
6708 outside the range of the base type of the expression, and overflow
6709 checks are enabled, the result is unknown and cannot be used for any
6710 subsequent constant folding.
6711 * sem_eval.adb (Compile_Time_Compare): if the bounds of one operand are
6712 unknown, so is the result of the comparison.
6713
6714 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
6715
6716 * a-except-2005.adb (Raise_From_Controlled_Operation): Add new formal
6717 From_Abort. When finalization was triggered by an abort, propagate
6718 Standard'Abort_Signal rather than Program_Error.
6719 * a-except-2005.ads (Raise_From_Controlled_Operation): Add new formal
6720 From_Abort.
6721 * a-except.adb (Raise_From_Controlled_Operation): Add new formal
6722 From_Abort. When finalization was triggered by an abort, propagate
6723 Standard'Abort_Signal rather than Program_Error.
6724 * a-except.ads:(Raise_From_Controlled_Operation): Add new formal
6725 From_Abort.
6726 * exp_ch7.adb:(Build_Adjust_Or_Finalize_Statements): New local variable
6727 Abort_Id. Update the calls to Build_Object_Declarations and
6728 Build_Raise_Statement to include Abort_Id.
6729 (Build_Adjust_Statements): New local variable Abort_Id. Update the
6730 calls to Build_Object_Declarations and Build_Raise_Statement to include
6731 Abort_Id.
6732 (Build_Finalize_Statements): New local variable Abort_Id. Update the
6733 calls to Build_Object_Declarations and Build_Raise_Statement to include
6734 Abort_Id.
6735 (Build_Components): Create an entity for Abort_Id when exceptions are
6736 allowed on the target.
6737 (Build_Finalizer): New local variable Abort_Id.
6738 (Build_Initialize_Statements): New local variable Abort_Id. Update the
6739 calls to Build_Object_Declarations and Build_Raise_Statement to include
6740 Abort_Id.
6741 (Build_Object_Declarations): Add new formal Abort_Id. Create the
6742 declaration of flag Abort_Id to preserve the original abort status
6743 before finalization code is executed.
6744 (Build_Raise_Statement): Add new formal Abort_Id. Pass Abort_Id to
6745 runtime routine Raise_From_Controlled_Operation.
6746 (Create_Finalizer): Update the call to Build_Raise_Statement to include
6747 Abort_Id. Update the call to Build_Object_Declarations to include
6748 Abort_Id. Update the layout of the finalizer body.
6749 (Make_Handler_For_Ctrl_Operation): Add an actual for From_Abort.
6750 (Process_Transient_Objects): New local variable Abort_Id. Remove the
6751 clunky code to create all flags and objects related to
6752 exception propagation and replace it with a call to
6753 Build_Object_Declarations. Update the call to Build_Raise_Statement to
6754 include Abort_Id.
6755 * exp_ch7.ads (Build_Object_Declarations): Moved from body to spec.
6756 Add new formal Abort_Id and associated comment on its use.
6757 (Build_Raise_Statement): Add new formal Abort_Id and associated comment
6758 on its use.
6759 * exp_intr.adb (Expand_Unc_Deallocation): New local variable Abort_Id.
6760 Remove the clunky code to create all flags and objects related to
6761 exception propagation and replace it with a call to
6762 Build_Object_Declarations. Update the call to Build_Raise_Statement.
6763
6764 2011-08-03 Eric Botcazou <ebotcazou@adacore.com>
6765
6766 * s-tassta.adb: Fix minor typos.
6767
6768 2011-08-03 Robert Dewar <dewar@adacore.com>
6769
6770 * rtsfind.ads, makeutl.ads, prj.ads, prj.adb, make.adb,
6771 lib-writ.adb, makeutl.adb, s-soflin.ads, clean.adb: Minor reformatting.
6772
6773 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
6774
6775 * exp_ch7.adb (Create_Finalizer): Treat freeze nodes in similar fashion
6776 to packages. This ensures that the finalizer body will not end up
6777 inside the freeze node.
6778 (Process_Declarations): Add code to detect whether a freeze node has a
6779 nested finalization collection.
6780
6781 2011-08-03 Pascal Obry <obry@adacore.com>
6782
6783 * g-awk.adb, g-awk.ads: Make GNAT.AWK API compatible with Ada 2005.
6784 (Current_Session): Return a not null access to Session_Type.
6785 (Default_Session): Likewise.
6786
6787 2011-08-03 Robert Dewar <dewar@adacore.com>
6788
6789 * a-cfdlli.adb, bindgen.adb, exp_ch4.adb, exp_ch13.adb, sem_warn.adb,
6790 exp_ch3.adb, exp_ch3.ads: Minor reformatting.
6791
6792 2011-08-03 Pascal Obry <obry@adacore.com>
6793
6794 * g-awk.ads: Minor comment fix.
6795
6796 2011-08-03 Sergey Rybin <rybin@adacore.com>
6797
6798 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
6799 the tree structure related to discriminant constraints.
6800 Original_Discriminant cannot be used any more for computing the
6801 defining name for the reference to a discriminant.
6802
6803 2011-08-03 Ed Schonberg <schonberg@adacore.com>
6804
6805 * sem_disp.adb (Is_Tag_Indeterminate): If the return type of the
6806 function is not visibly tagged, this is not a dispatching call and
6807 therfore is not Tag_Indeterminate, even if the function is marked as
6808 dispatching on result.
6809
6810 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
6811
6812 * exp_ch13.adb: Add with and use clauses for Restrict and Rident.
6813 (Expand_N_Free_Statement): Add a guard to protect against run-times
6814 which do not support controlled types.
6815 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Add a guard to protect
6816 against run-times which do not support controlled types.
6817 * exp_ch4.adb (Complete_Controlled_Allocation): Add a guard to protect
6818 against run-times which do not support controlled types.
6819 * exp_ch7.adb (Build_Finalization_Collection): Add a guard to protect
6820 against run-times which do not support controlled types.
6821 * exp_util.adb (Needs_Finalization): Code reformatting. Add a guard to
6822 protect against run-times which do not support controlled types.
6823
6824 2011-08-03 Eric Botcazou <ebotcazou@adacore.com>
6825
6826 * exp_intr.adb: Put back with and use clauses for Exp_Ch11.
6827 (Expand_Unc_Deallocation): Expand the AT_END handler at the very end.
6828
6829 2011-08-03 Ed Schonberg <schonberg@adacore.com>
6830
6831 * exp_ch5.adb (Expand_Iterator_Loop): indicate that the cursor is
6832 modified in the source, to prevent spurious warnings when compiling
6833 with -gnatg.
6834
6835 2011-08-03 Thomas Quinot <quinot@adacore.com>
6836
6837 * a-except-2005.adb: Minor reformatting.
6838
6839 2011-08-03 Ed Schonberg <schonberg@adacore.com>
6840
6841 * sem_warn.adb (Check_One_Unit): if the only mention of a withed unit
6842 is a renaming declaration in the private part of a package, do not emit
6843 a warning that the with_clause could be moved because the renaming may
6844 be used in the body or in a child unit.
6845
6846 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
6847
6848 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
6849 Propagate the Comes_From_Source attribute from the original return
6850 object to the renaming.
6851
6852 2011-08-03 Jose Ruiz <ruiz@adacore.com>
6853
6854 * exp_ch7.adb (Build_Raise_Statement): Do not call
6855 Raise_From_Controlled_Operation when this routine is not present in
6856 the run-time library.
6857 (Cleanup_Protected_Object, Cleanup_Task): For restricted run-time
6858 libraries (Ravenscar), tasks are non-terminating, and protected objects
6859 and tasks can only appear at library level, so we do not want
6860 finalization of protected objects nor tasks.
6861 * exp_intr.adb: Minor clarification in comment.
6862 bindgen.adb (Gen_Adainit_Ada, Gen_Main_C, Gen_Output_File_Ada,
6863 Gen_Output_File_C): Remove references to finalization of library-level
6864 objects when using restricted run-time libraries.
6865
6866 2011-08-03 Ed Schonberg <schonberg@adacore.com>
6867
6868 * sem_ch3.adb (Build_Discriminant_Constraints): Set
6869 Original_Discriminant only if the parent type is a generic formal.
6870
6871 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
6872
6873 * exp_ch13.adb: Add with and use clause for Targparm;
6874 (Expand_N_Free_Statement): Prevent the generation of a custom
6875 Deallocate on .NET/JVM targets since this requires pools and address
6876 arithmetic.
6877 * exp_ch4.adb (Expand_Allocator_Expression): When compiling for
6878 .NET/JVM targets, attach the newly allocated object to the access
6879 type's finalization collection. Do not generate a call to
6880 Set_Finalize_Address_Ptr on .NET/JVM because this routine does not
6881 exist in the runtime.
6882 (Expand_N_Allocator): When compiling for .NET/JVM targets, do not
6883 create a custom Allocate for object that do not require initialization.
6884 Attach a newly allocated object to the access type's finalization
6885 collection on .NET/JVM.
6886 * exp_ch5.adb (Make_Tag_Ctrl_Assignment): Add special processing for
6887 assignment of controlled types on .NET/JVM. The two hidden pointers
6888 Prev and Next and stored and later restored after the assignment takes
6889 place.
6890 * exp_ch6.adb (Expand_Call): Add local constant Curr_S. Add specialized
6891 kludge for .NET/JVM to recognize a particular piece of code coming from
6892 Heap_Management and change the call to Finalize into Deep_Finalize.
6893 * exp_ch7.adb (Build_Finalization_Collection): Allow the creation of
6894 finalization collections on .NET/JVM only for types derived from
6895 Controlled. Separate the association of storage pools with a collection
6896 and only allow it on non-.NET/JVM targets.
6897 (Make_Attach_Call): New routine.
6898 (Make_Detach_Call): New routine.
6899 (Process_Object_Declarations): Suppress the generation of
6900 build-in-place return object clean up code on .NET/JVM since it uses
6901 pools.
6902 * exp_ch7.ads (Make_Attach_Call): New routine.
6903 (Make_Detach_Call): New routine.
6904 * exp_intr.adb Add with and use clause for Targparm.
6905 (Expand_Unc_Deallocation): Detach a controlled object from a collection
6906 on .NET/JVM targets.
6907 * rtsfind.ads: Add entries RE_Attach, RE_Detach and
6908 RE_Root_Controlled_Ptr to tables RE_Id and RE_Unit_Table.
6909 * snames.ads-tmpl: Add name Name_Prev. Move Name_Prev to the special
6910 names used in finalization.
6911
6912 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
6913
6914 * a-fihema.adb: Add with and use clauses for System.Soft_Links.
6915 (Attach, Detach): Lock the current task when chaining an object onto a
6916 collection.
6917
6918 2011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
6919
6920 * a-except.adb, a-except-2005.adb (Raise_From_Controlled_Operation):
6921 Rewritten to create the message strings when the exception is not
6922 raised by an abort during finalization.
6923 * a-except.ads, a-except-2005.ads: Add pragma Export for procedure
6924 Raise_From_Controlled_Operation and update its associated comment.
6925 * a-fihema.ads, a-fihema.adb: New GNAT unit.
6926 Ada.Finalization.Heap_Management provides key functionality
6927 associated with controlled objects on the heap, their creation,
6928 finalization and reclamation. Type Finalization_Collection is
6929 effectively a wrapper which sits ontop of a storage pool and performs
6930 all necessary bookkeeping for all the objects it contains. Each
6931 access-to-controlled or access-to-class-wide type receives a collection
6932 as part of its expansion. The compiler generates buffer code and
6933 invokes Allocate / Deallocate to create and destroy allocated
6934 controlled objects.
6935 * a-finali.adb ("="): Removed.
6936 * a-finali.ads ("="): Removed. Controlled types no longer carry hidden
6937 fields Prev and Next.
6938 * ali.adb (Scan_ALI): Add parsing code to process PF / Has_Finalizer.
6939 A library unit with at least one controlled object on the library level
6940 has a special finalizer which is invoked by the binder. To signal this,
6941 ali files carry field PF.
6942 * ali.ads: New field in type Unit_Record called Has_Finalizer. Add
6943 associated comment on field usage.
6944 * a-tags.adb (Get_RC_Offset): Removed.
6945 (Needs_Finalization): New routine.
6946 * a-tags.ads: Update the structure of the GNAT dispatch tables.
6947 Dispatch tables now carry field Needs_Finalization which provides
6948 runtime indication whether a type is controlled or has controlled
6949 components or both. Remove field RC_Offset.
6950 (Get_RC_Offset): Removed along with its associated pragma Export.
6951 Since tagged types with controlled components no longer carry hidden
6952 field _controller, the special mechanism to retrieve its location is no
6953 longer needed.
6954 (Needs_Finalization): New routine.
6955 * atree.ads, atree.adb (Elist24): New routine.
6956 (Set_Elist24): New routine.
6957 * atree.h: Add a define clause for Elist24.
6958 * bindgen.adb New library-level variable Lib_Final_Built.
6959 (Gen_Adafinal_Ada): Reimplemented. Depending on the restrictions or the
6960 presence of a VM target, the routine generates calls to the proper
6961 library finalization routine.
6962 (Gen_Adainit_Ada): Import Finalize_Library_Objects only on non-VM
6963 targets. Set the correct library finalization routine depending on
6964 whether the library has controlled objects or this is a VM compilation.
6965 (Gen_Finalize_Library_Ada): New routine. This procedure generates calls
6966 to library-level finalizers of compiled units in reverse order of
6967 elaboration. It also produces exception management code and reraises a
6968 potential exception after all units have been finalized.
6969 (Gen_Finalize_Library_C): New routine. This procedure generates calls to
6970 library-level finalizers of compiled units in reverse order of
6971 elaboration.
6972 (Gen_Finalize_Library_Defs_C): New routine. This procedure generates the
6973 definitions of all library-level finalizers available to the compilation
6974 (Gen_Main_Ada): Directly call Adafinal which now contails all target
6975 dependent code.
6976 (Gen_Main_C): Add new local constant Needs_Library_Finalization. Call
6977 System.Standard_Library.Adafinal directly. If the library needs
6978 finalization actions, create the sequence of finalization calls.
6979 (Gen_Output_File_Ada): Alphabetize local variables and constants.
6980 Generate a with clause for System.Soft_Links when compiling for a VM.
6981 Remove the code which imports System.Standard_Library.Adafinal as
6982 Do_Finalize. Generate the library finalization routine.
6983 (Gen_Output_File_C): Add new local constant Needs_Library_Finalization.
6984 If the library needs finalization actions, create all the definitions
6985 of library- level finalizers.
6986 (Has_Finalizer): New routine. Determines whether at least one compiled
6987 unit has a library-level finalizer.
6988 Add type Qualification_Mode.
6989 (Set_Unit_Name): Add a formal which controls the replacement of a dot.
6990 * einfo.adb: New usage of field 15 as Return_Flag.
6991 Remove Finalization_Chain_Entity from the usages of field 19.
6992 Remove Associated_Final_Chain from the usages of field 23.
6993 New usage of field 23 as Associated_Collection.
6994 New usage of field 24 as Finalizer.
6995 New usage of flag 252 as Is_Processed_Transient.
6996 (Associated_Final_Chain): Removed.
6997 (Associated_Collection): New routine.
6998 (Finalization_Chain_Entity): Removed.
6999 (Finalizer): New routine.
7000 (Is_Finalizer): New routine.
7001 (Is_Processed_Transient): New routine.
7002 (Return_Flag): New routine.
7003 (Set_Associated_Final_Chain): Removed.
7004 (Set_Associated_Collection): New routine.
7005 (Set_Finalization_Chain_Entity): Removed.
7006 (Set_Finalizer): New routine.
7007 (Set_Is_Processed_Transient): New routine.
7008 (Set_Return_Flag): New routine.
7009 (Write_Entity_Flags): Include Is_Processed_Transient to the list of
7010 displayed flags.
7011 (Write_Field8_Name): Alphabetize the output.
7012 (Write_Field11_Name): Alphabetize the output.
7013 (Write_Field12_Name): Alphabetize the output.
7014 (Write_Field13_Name): Alphabetize the output.
7015 (Write_Field14_Name): Alphabetize the output.
7016 (Write_Field15_Name): Alphabetize the output.
7017 (Write_Field16_Name): Alphabetize the output.
7018 (Write_Field17_Name): Alphabetize the output.
7019 (Write_Field18_Name): Alphabetize the output.
7020 (Write_Field19_Name): Alphabetize the output. Remove the output of
7021 Finalization_Chain_Entity.
7022 (Write_Field20_Name): Alphabetize the output.
7023 (Write_Field21_Name): Alphabetize the output.
7024 (Write_Field22_Name): Alphabetize the output.
7025 (Write_Field23_Name): Alphabetize the output. Remove the output of
7026 Associated_Final_Chain. Add output for Associated_Collection.
7027 (Write_Field24_Name): Alphabetize the output.
7028 (Write_Field25_Name): Add output for Finalizer.
7029 (Write_Field26_Name): Alphabetize the output.
7030 (Write_Field27_Name): Alphabetize the output.
7031 (Write_Field28_Name): Alphabetize the output.
7032 * einfo.ads: Add new field description for Associated_Collection and
7033 its uses in nodes.
7034 Remove Associated_Final_Chain and its uses in nodes.
7035 Remove Finalization_Chain_Entity and its uses in nodes.
7036 Add new field description for Finalizer and its uses in nodes.
7037 Add new synthesized attribute Is_Finalizer.
7038 Add new flag description for Is_Processed_Transient and its uses in
7039 nodes.
7040 Add new field description for Return_Flag and its uses in nodes.
7041 (Associated_Final_Chain): Removed along with its pragma Inline.
7042 (Associated_Collection): New routine and pragma Inline.
7043 (Finalization_Chain_Entity): Removed along with its pragma Inline.
7044 (Finalizer): New routine and pragma Inline.
7045 (Is_Finalizer): New routine and pragma Inline.
7046 (Is_Processed_Transient): New routine and pragma Inline.
7047 (Return_Flag): New routine and pragma Inline.
7048 (Set_Associated_Final_Chain): Removed along with its pragma Inline.
7049 (Set_Associated_Collection): New routine and pragma Inline.
7050 (Set_Finalization_Chain_Entity): Removed along with its pragma Inline.
7051 (Set_Finalizer): New routine and pragma Inline.
7052 (Set_Is_Processed_Transient): New routine and pragma Inline.
7053 (Set_Return_Flag): New routine and pragma Inline.
7054 * exp_aggr.adb: Alphabetize subprograms.
7055 (Build_Array_Aggr_Code): Remove formal Flist and its associated comment.
7056 (Build_Record_Aggr_Code): Remove formals Flist and Obj along with their
7057 associated comments. Remove local variables External_Final_List and
7058 Attach.
7059 Rename Ctrl_Stuff_Done to Finalization_Done. Rename local variable A to
7060 Ancestor. Remove the retrieval of finalization lists. Update the call to
7061 Make_Adjust_Call.
7062 (Convert_Aggr_In_Allocator): Remove the retrieval of finalization
7063 lists. Update the call to Late_Expansion.
7064 (Convert_Aggr_In_Assignment): Update the call to Late_Expansion.
7065 (Convert_Aggr_In_Object_Decl): Update the call to Late_Expansion.
7066 (Gen_Assign): Remove the retrieval of the finalization list used to
7067 build the assignment. Update the calls to Make_Init_Call and
7068 Make_Adjust_Call.
7069 (Gen_Ctrl_Actions_For_Aggr): Renamed to Generate_Finalization_Actions.
7070 Remove the mechanism to determine attachment levels and finalization
7071 list retrieval. Remove the processing for coextensions.
7072 (Init_Controller): Removed. Controllers no longer exist.
7073 (Late_Expansion): Remove formals Flist and Obj along with their
7074 associated comments. Update the calls to Build_Record_Aggr_Code and
7075 Build_Array_Aggr_Code.
7076 * exp_ch13.adb (Expand_N_Free_Statement): New routine.
7077 (Expand_N_Freeze_Entity): Add special processing for finalizers which
7078 appear in entry bodies, protected subprograms and task bodies.
7079 * exp_ch13.ads (Expand_N_Free_Statement): New routine.
7080 * exp_ch3.adb (Add_Final_Chain): Removed.
7081 (Build_Array_Init_Proc): Alphabetize local variables.
7082 (Build_Assignment): Alphabetize local variables. Update the call to
7083 Maked_Adjust_Call.
7084 (Build_Class_Wide_Master): Rename local variables to better reflect
7085 their role.
7086 (Build_Discriminant_Assignments): Code reformatting.
7087 (Build_Init_Call_Thru): Code reformatting.
7088 (Build_Init_Procedure): Code reformatting. Generate a special version
7089 of Deep_Finalize which is capable of finalizing all initialized
7090 components and ignore the rest.
7091 (Build_Init_Statements): Rename local variables to better reflect their
7092 role.
7093 Reimplement the mechanism to include the creation and update of an index
7094 variable called a "counter". It is used as a bookmark for tracing
7095 initialized and non-initialized components.
7096 (Build_Initialization_Call): Remove local variable Controller_Typ.
7097 Alphabetize all local variables. Remove the initialization of the
7098 record controller and update the call to Make_Init_Call.
7099 (Build_Record_Init_Proc): Rename formal Pe to Rec_Ent.
7100 New local variable Counter.
7101 (Constrain_Array): Alphabetize.
7102 (Expand_Freeze_Array_Type): Create a collection instead of a
7103 finalization list.
7104 (Expand_Freeze_Class_Wide_Type): New routine. Creates TSS primitive
7105 Finalize_Address which is used in conjunction with allocated controlled
7106 objects.
7107 (Expand_N_Object_Declaration): Remove the creation of a finalization
7108 list for anonymous access types. Update the calls to Make_Init_Call and
7109 Make_Adjust_Call.
7110 (Expand_Freeze_Record_Type): Remove local variable Flist. Remove the
7111 retrieval of finalization lists. Remove the expansion of the record
7112 controller. Create TSS primitive Finalize_Address used in conjunction
7113 with controlled objects on the heap. Create finalization collections
7114 for access-to-controlled record components.
7115 (Expand_Record_Controller): Removed.
7116 (Freeze_Type): Remove the freezing of record controllers. Freezing of
7117 class-wide types now requires additional processing. Create
7118 finalization collections for access-to-controlled types.
7119 (Increment_Counter): New routine.
7120 (Make_Counter): New routine.
7121 (Make_Eq_If): Remove the mention of Name_uController.
7122 (Make_Predefined_Primitive_Specs): There is no longer need to skip
7123 types coming from System.Finalization_Root.
7124 (Predef_Deep_Spec): Reimplemented to reflect the new parameter profiles.
7125 (Predefined_Primitive_Bodies): There is no longer need to skip types
7126 coming from System.Finalization_Root.
7127 (Stream_Operation_OK): Do not generate stream routines for
7128 type Ada.Finalization.Heap_Management.Finalization_Collection.
7129 * exp_ch3.ads: Alphabetize subprograms.
7130 * exp_ch4.adb: Remove with and use clause for Sem_Ch8.
7131 Add with and use clause for Lib.
7132 (Complete_Coextension_Finalization): Removed.
7133 (Complete_Controlled_Allocation): New routine. Create a finalization
7134 collection for anonymous access-to-controlled types. Create a custom
7135 Allocate which interfaces with the back end and the machinery in
7136 Heap_Management.
7137 (Expand_Allocator_Expression): Add necessary calls to
7138 Complete_Controlled_Allocation. Remove the retrieval of finalization
7139 lists. Update the calls to Make_Adjust_Call. Generate a call to
7140 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
7141 the associated collection.
7142 (Expand_N_Allocator): Remove the processing for dynamic coextensions.
7143 Code clean up. Remove the retrieval of finalization lists and
7144 attachment levels.
7145 Update the call to Make_Init_Call. Generate a call to
7146 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
7147 the associated collection.
7148 (Get_Allocator_Final_List): Removed. Finalization lists are not
7149 available.
7150 (Suitable_Element): Remove the mention of Name_uController.
7151 * exp_ch5.adb: Remove with and use clauses for Ttypes and Uintp.
7152 (Make_Tag_Ctrl_Assignment): Rewritten to simply do a finalization of
7153 the left hand side, carry out the assignment and adjust the left hand
7154 side.
7155 * exp_ch6.adb (Add_Final_List_Actual_To_Build_In_Place_Call): Removed.
7156 (Add_Collection_Actual_To_Build_In_Place_Call): New routine.
7157 (BIP_Formal_Suffix): Rename BIP_Final_List and BIPfinallist to
7158 BIP_Collection and BIPcollection.
7159 (Build_Heap_Allocator): New routine used to allocate the return object
7160 of a build-in-place function onto a collection.
7161 (Expand_Ctrl_Function_Call): Moved from Exp_Ch7.
7162 (Expand_Call): Do not replace direct calls to Deep routines with their
7163 aliases.
7164 (Expand_N_Extended_Return_Statement): Give all variables shorter names
7165 and update their occurrences. Add a special return flag to monitor the
7166 [ab]normal execution of the function. The flag is set right before the
7167 return statement.
7168 Rewrite the mechanism used to allocate a build-in-place return object
7169 on the heap or on a storage pool.
7170 (Is_Direct_Deep_Call): New routine.
7171 (Make_Build_In_Place_Call_In_Allocator): Add a collection to a
7172 build-in-place function call instead of a final list. Build a call to
7173 Set_Finalize_Address_Ptr to decorate the associated collection.
7174 (Make_Build_In_Place_Call_In_Anonymous_Context): Create a temporary in
7175 order to name the build-in-place function call's result for later
7176 finalization. Add a collection to a build-in-place function call
7177 instead of a final list.
7178 (Make_Build_In_Place_Call_In_Assignment): Add a collection to a
7179 build-in-place function call instead of a final list. Remove the code
7180 which moves one final list and transforms it into the actual in a
7181 nested build-in-place call.
7182 (Make_Build_In_Place_Call_In_Object_Declaration): Add a collection to a
7183 build-in-place function call instead of a final list.
7184 (Move_Final_List): Removed.
7185 (Needs_BIP_Collection): New routine.
7186 (Needs_BIP_Final_List): Removed.
7187 * exp_ch6.ads: Replace BIP_Final_List with BIP_Collection in
7188 enumeration type BIP_Formal_Kind.
7189 Update the related comment.
7190 (Needs_BIP_Collection): New routine.
7191 (Needs_BIP_Final_List): Removed.
7192 * exp_ch7.adb: Add with and use clauses for Elists, Exp_Ch6, Stringt
7193 and Ttypes. Remove with and use clauses for Sem_Type. Alphabetize the
7194 majority of subprograms in this unit. Add Name_Finalize_Address to
7195 array Name_Of and TSS_Finalize_Address to array Deep_Name_Of.
7196 (Build_Adjust_Or_Finalize_Statements): Create the adjust or finalization
7197 statements for an array type.
7198 (Build_Adjust_Statements): Create the adjust statements for a record
7199 type.
7200 (Build_Cleanup_Statements): New routine. A procedure which given any
7201 construct containing asynchronous calls, references to _master, or is a
7202 task body, a task allocation or a protected body produces the necessary
7203 runtime calls to clean up these constructs.
7204 (Build_Exception_Handler): New routine.
7205 (Build_Final_List): Removed.
7206 (Build_Finalization_Collection): New routine. A core procedure which
7207 creates a collection to service heap allocated controlled objects
7208 associated with an access-to-controlled type.
7209 (Build_Finalize_Statements): Create the finalization statements for a
7210 record types.
7211 (Build_Finalizer): New routine. A core procedure which given any
7212 construct with declarations and/or statements detects all objects which
7213 need any type of clean up (controlled objects, protected objects) and
7214 generates all necessary code to clean up the said objects in the proper
7215 order.
7216 (Build_Finalizer_Call): New routine.
7217 (Build_Initialize_Statements): Create the initialization statements for
7218 an array type. The generated routine contains code to finalize partially
7219 initialized arrays.
7220 (Build_Object_Declarations): New routine.
7221 (Build_Raise_Statement): New routine.
7222 (Clean_Simple_Protected_Objects): Removed.
7223 (Controller_Component): Removed.
7224 (Enclosing_Function): New routine.
7225 (Expand_Cleanup_Actions): Create a finalizer for a construct which has
7226 either declarations or statements or both.
7227 (Expand_N_Package_Body): Create a finalizer for a non-generic package.
7228 (Expand_N_Package_Declaration): Create a finalizer for a non-generic
7229 package.
7230 (Find_Final_List): Removed.
7231 (Global_Flist_Ref): Removed.
7232 (In_Finalization_Root): Removed.
7233 (Insert_Actions_In_Scope_Around): Determine the range of the transient
7234 scope in terms of tree nodes. Process all transient variables within
7235 that range.
7236 (Make_Adjust_Call): Rewritten. There is no longer an attach call
7237 generated after the adjust.
7238 (Make_Attach_Call): Removed.
7239 (Make_Call): New routine.
7240 (Make_Clean): Removed.
7241 (Make_Deep_Array_Body): Rewritten to simply invoke the appropriate
7242 build routines.
7243 (Make_Deep_Proc): Rewritten to generate the new profile signature used
7244 in Deep routines.
7245 (Make_Deep_Record_Body): Rewritten to simply invoke the appropriate
7246 build routines.
7247 (Make_Final_Call): Modified to simply create a call to either
7248 Deep_Finalize or Finalize.
7249 (Make_Finalize_Address_Body): New routine.
7250 (Make_Finalize_Address_Stmts): New routine. A function which produces
7251 TSS primitive Finalize_Address used in conjunction with heap allocated
7252 controlled objects.
7253 (Make_Handler_For_Ctrl_Operation): Add specialized code for .NET/JVM.
7254 (Make_Init_Call): Rewritten. There is no longer an attach call
7255 generated after initialization.
7256 (Make_Local_Deep_Finalize): New routine.
7257 (Make_Set_Finalize_Address_Ptr_Call): New routine.
7258 (Make_Transient_Block): Remove the finalization list retrieval and
7259 manipulation.
7260 (Needs_Finalization): Moved to Exp_Util.
7261 (Parent_Field_Type): New routine.
7262 (Preprocess_Components): New routine.
7263 (Process_Transient_Objects): New routine.
7264 (Wrap_HSS_In_Block): New routine.
7265 (Wrap_Transient_Declaration): Remove finalization list management and
7266 controller insertion.
7267 (Wrap_Transient_Expression): Code reformatting.
7268 (Wrap_Transient_Statement): Code reformatting.
7269 * exp_ch7.ads (Build_Final_List): Removed.
7270 (Build_Finalization_Collection): New routine.
7271 (Build_Raise_Statement): New routine.
7272 (Controller_Component): Removed.
7273 (Expand_Ctrl_Function_Call): Moved to Exp_Ch6.
7274 (Find_Final_List): Removed.
7275 (In_Finalization_Root): Removed.
7276 (Is_Simple_Protected_Type): Update related comment.
7277 (Make_Adjust_Call): New parameter profile and associated comments.
7278 (Make_Attach_Call): Removed.
7279 (Make_Final_Call): New parameter profile and associated comments.
7280 (Make_Finalize_Address_Body): New routine.
7281 (Make_Init_Call): New parameter profile and associated comments.
7282 (Make_Local_Deep_Finalize): New routine.
7283 (Make_Set_Finalize_Address_Ptr_Call): New routine.
7284 (Needs_Finalization): Moved to Exp_Util.
7285 * exp_ch9.adb (Add_Object_Pointer): Code reformatting.
7286 (Expand_N_Protected_Body): Remove the handling of finalization lists.
7287 (Find_Protection_Type): Moved to Exp_Util.
7288 * exp_disp.adb: Remove with and use clauses for Exp_Ch7.
7289 (Make_DT): Update sequence of dispatch table initialization. Remove the
7290 initialization of field RC_Offset. Add initialization of field Needs_
7291 Finalization.
7292 * exp_intr.adb (Expand_Unc_Deallocation): Code reformatting.
7293 Reimplement how an object is first finalized, then deallocated.
7294 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
7295 Code reformatting.
7296 * exp_tss.ads: Add special suffix for TSS primitive Finalize_Address.
7297 Register TSS_Finalize_Address with type TSS_Names.
7298 * exp_util.adb (Build_Allocate_Deallocate_Proc): New routine. This core
7299 procedure provides the interface between an allocation / deallocation
7300 and the support machinery in Ada.Finalization.Heap_Management.
7301 (Find_Init_Call): Code reformatting.
7302 (Find_Init_Call_In_List): Code reformatting.
7303 (Find_Protection_Type): Moved from Exp_Ch9.
7304 (Find_Prim_Op): Reimplement to add preference of recovered primitive.
7305 (Has_Controlled_Coextensions): Removed.
7306 (Has_Controlled_Objects): New routine.
7307 (In_Library_Level_Package_Body): New routine.
7308 (Insert_Action_After): New routine.
7309 (Is_Finalizable_Transient): New routine. This predicate determines
7310 whether an object declaration is one of the many variants of controlled
7311 transients.
7312 (Is_Null_Access_BIP_Func_Call): New routine.
7313 (Is_Non_BIP_Func_Call): New routine.
7314 (Is_Related_To_Func_Return): New routine.
7315 (Needs_Finalization): Moved from Exp_Ch7.
7316 * exp_util.ads (Build_Allocate_Deallocate_Proc): New routine.
7317 (Find_Protection_Type): Moved from Exp_Ch9.
7318 (Has_Controlled_Coextensions): Removed.
7319 (Has_Controlled_Objects): New routine.
7320 (In_Library_Level_Package_Body): New routine.
7321 (Insert_Action_After): New routine.
7322 (Is_Finalizable_Transient): New routine.
7323 (Is_Null_Access_BIP_Func_Call): New routine.
7324 (Is_Non_BIP_Func_Call): New routine.
7325 (Is_Related_To_Func_Return): New routine.
7326 (Needs_Finalization): Moved from Exp_ch7.
7327 * expander.adb (Expand): Add a case for N_Free_Statement.
7328 * freeze.adb (Freeze_All): Replace the generation of a finalization
7329 list with a collection for access-to-controlled types.
7330 (Freeze_Entity): Code reformatting.
7331 (Freeze_Record_Type): Remove the freezing of a record controller
7332 component.
7333 (Freeze_Subprogram): Code reformatting.
7334 * inline.adb (Cleanup_Scopes): Remove the reset of the scope
7335 finalization list.
7336 * lib-writ.adb (Write_Unit_Information): Output "PF" when a package
7337 has a library-level finalizer.
7338 * lib-writ.ads: Add "PF" to the sequence of unit attributes.
7339 * a-filico.ads, a-filico.adb, s-finimp.ads, s-finimp.adb: Removed.
7340 * Makefile.rtl: Remove a-filico and s-finimp from the list of object
7341 files. Add a-fihema to the list of object files.
7342 * par-ch4.adb:
7343 Alphabetize the associations in type Is_Parameterless_Attribute.
7344 * rtsfind.ads: Ada.Finalization_List.Controller and
7345 System.Finalization_Implementation are no longer a GNAT unit.
7346 Update the range of type Ada_Finalization_Child. Remove the following
7347 recoverable entities:
7348
7349 RE_Attach_To_Final_List
7350 RE_Deep_Tag_Attach
7351 RE_Finalize_List
7352 RE_Finalize_One
7353 RE_Finalizable_Ptr_Ptr
7354 RE_Global_Final_List
7355 RE_Limited_Record_Controller
7356 RE_List_Controller
7357 RE_Move_Final_List
7358 RE_Record_Controller
7359 RE_Simple_List_Controller
7360
7361 Add the following recoverable entities:
7362
7363 RE_Add_Offset_To_Address
7364 RE_Allocate
7365 RE_Base_Pool
7366 RE_Deallocate
7367 RE_Exception_Identity
7368 RE_Finalization_Collection
7369 RE_Finalization_Collection_Ptr
7370 RE_Needs_Finalization
7371 RE_Save_Library_Occurrence
7372 RE_Set_Finalize_Address_Ptr
7373 RE_Set_Storage_Pool_Ptr
7374 RE_Storage_Count
7375 * sem_aggr.adb (Resolve_Record_Aggregate): Remove mention of
7376 Name_uController.
7377 * sem_aux.adb (First_Discriminant): Remove mention of Name_uController.
7378 (First_Stored_Discriminant): Remove the mention of Name_uController.
7379 * sem_aux.ads: Comment reformatting.
7380 * sem_ch10.adb (Build_Chain): Signal the class-wide creation machinery
7381 to redecorate an already existing class-wide type.
7382 (Decorate_Tagged_Type): New parameter profile and associated comment.
7383 Create a "shadow class-wide type" for a shadow entity.
7384 * sem_ch11.adb (Analyze_Exception_Handlers): Remove the dubious setting
7385 of the final chain along with the associated comment.
7386 * sem_ch3.adb (Access_Type_Declaration): Add new local variable
7387 Full_Desig and set it to the full view of the designated type.
7388 Initialize the finalization collection to empty.
7389 (Build_Derived_Record_Type): Alphabetize local variables. Code
7390 reformatting.
7391 (Collect_Fixed_Components): Remove the mention of Name_uController.
7392 (Create_Constrained_Components): Remove the mention of Name_uController.
7393 (Make_Class_Wide_Type): Add specialized code to redecorate an existing
7394 class-wide type of a shadow entity.
7395 (Process_Full_View): Update the machinery which marks type
7396 Limited_Controlled's entity as limited.
7397 * sem_ch4.adb (Analyze_One_Call): Code reformatting.
7398 * sem_ch6.adb (Create_Extra_Formals): Do not generate a finalization
7399 list, instead make a collection build-in-place formal.
7400 * sem_ch8.adb (Analyze_Object_Renaming): Look at the available view of
7401 a designated type in order to establish a match between the renaming
7402 and the renamed entity.
7403 (Find_Selected_Component): Add guard to prevent spurious exceptions
7404 from being raised on .NET/JVM.
7405 * sem_disp.adb (Check_Dispatching_Operation): Include Finalize_Address
7406 to the list of primitive that need special processing. Update arrays
7407 C_Names and D_Names.
7408 (Replace_Types): Handle class-wide types.
7409 * sem_elab.adb (Check_A_Call): Since Deep_Initialize now has a
7410 different parameter profile, look at the first formal.
7411 * sem_prag.adb: Remove with and use clauses for Exp_Ch7. Add with and
7412 use clauses for Exp_Util.
7413 * sem_res.adb: Remove with and use clauses for Elists.
7414 (Propagate_Coextensions): Removed.
7415 (Resolve_Allocator): Do not propagate the list of coextensions from one
7416 allocator to another.
7417 * sem_util.adb (Build_Actual_Subtype_Of_Component): Rename variable
7418 Deaccessed_T to Desig_Typ.
7419 (Enter_Name): Remove the mention of Name_uController.
7420 (Gather_Components): Remove the mention of Name_uController.
7421 (Incomplete_Or_Private_View): New routine.
7422 (Is_Coextension_Root): Removed.
7423 (Is_Fully_Initialized_Type): Remove the mention of Name_uController.
7424 * sem_util.ads (Incomplete_Or_Private_View): New routine.
7425 (Is_Coextension_Root): Removed.
7426 * s-finroo.ads: Remove with clause for Ada.Unchecked_Conversion.
7427 Controlled types are now derived from a null tagged record. Remove
7428 types Finalizable_Ptr, Finalizable and Empty_Root_Controlled.
7429 * sinfo.adb (Coextensions): Removed.
7430 (Set_Coextensions): Removed.
7431 * sinfo.ads: Remove Coextensions from the explanation of node fields
7432 and its uses in nodes.
7433 Update the field usage of N_Allocator.
7434 (Coextensions): Removed along with its pragma Inline.
7435 (Set_Coextensions): Removed along with its pragma Inline.
7436 * snames.ads-tmpl: Remove names
7437
7438 Name_uClean
7439 Name_uController
7440 Name_uFinal_List
7441 Name_uLocal_Final_List
7442 Name_Finalization_Root
7443 Name_Next
7444 Name_Prev
7445
7446 Add names
7447
7448 Name_uFinalizer
7449 Name_Finalize_Address
7450 * s-pooglo.adb (Allocate): Add overriding indicator.
7451 (Deallocate): Add overriding indicator.
7452 (Storage_Size): Add overriding indicator.
7453 * s-soflin.adb (Adafinal_NT): Invoke Finalize_Library_Objects rather
7454 than Finalize_Global_List.
7455 (Null_Finalize_Global_List): Removed.
7456 (Save_Library_Occurrence): New routine.
7457 * s-soflin.ads: Remove variable Finalize_Global_List along with its
7458 initialization. Add variable Finalize_Library_Objects along with its
7459 pragma Export. Add variables Library_Exception and
7460 Library_Exception_Set along with their pragma Export.
7461 (Null_Finalize_Global_List): Removed.
7462 (Save_Library_Occurrence): New routine.
7463 * s-tassta.adb (Finalize_Global_Tasks): Call Finalize_Library_Objects
7464 rather than Finalize_Global_List.
7465 * tbuild.adb (Unchecked_Convert_To): Capture and set the parent field
7466 of the constructed node.
7467
7468 2011-08-03 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7469
7470 * link.c: Include "auto-host.h" before system headers.
7471
7472 2011-08-03 Vincent Celier <celier@adacore.com>
7473
7474 * make.adb (Gnatmake): Add to table Library_Projs only library projects
7475 that are not extended. Do not check if a library project that is
7476 extended should be regenerated. Do not add to table Library_Paths the
7477 libraries that are in extended projects. Link only with libraries that
7478 are in libray projects that are not extended.
7479 * prj-nmsc.adb (Check_Library_Attributes): Do not reset flag Library
7480 for a library project that is extended.
7481
7482 2011-08-03 Gary Dismukes <dismukes@adacore.com>
7483
7484 * sem_ch6.adb (Find_Corresponding_Spec): When in an instance, skip
7485 conforming subprogram renamings that appear to be completions if they
7486 are not fully conformant.
7487 Such renamings are homographs but not completions.
7488 * sem_type.adb (Disambiguate): Handle disambiguation of overloaded
7489 names in a subprogram renaming that appears in an instance.
7490
7491 2011-08-03 Ed Schonberg <schonberg@adacore.com>
7492
7493 * exp_util.adb (Expand_Subtype_From_Expr): if the type is limited but
7494 not immutably limited, build actual subtype from expression to provide
7495 proper bounds to caller.
7496
7497 2011-08-03 Gary Dismukes <dismukes@adacore.com>
7498
7499 * sem_ch8.adb: Minor comment correction.
7500
7501 2011-08-03 Thomas Quinot <quinot@adacore.com>
7502
7503 * exp_strm.adb (Build_Array_Input_Function): In Ada 2005 mode, when
7504 returning a limited array, use an extended return statement.
7505
7506 2011-08-03 Vincent Celier <celier@adacore.com>
7507
7508 * make.adb (Initialize): If --subdirs= is used, but no project file is
7509 specified, attempt to create the specify subdir if it does not already
7510 exist and use it as the object directory as if -D had been specified.
7511
7512 2011-08-03 Arnaud Charlet <charlet@adacore.com>
7513
7514 * s-tpopsp-vms.adb: New file.
7515 * s-taprop-vms.adb: Put back ATCB_Key, since needed by this file on VMS.
7516 * gcc-interfaces/Makefile.in: Use s-taprop-vms.adb on VMS.
7517
7518 2011-08-03 Emmanuel Briot <briot@adacore.com>
7519
7520 * make.adb, makeutl.adb, makeutl.ads, clean.adb (Makeutl.Queue): new
7521 package.
7522
7523 2011-08-03 Yannick Moy <moy@adacore.com>
7524
7525 * cstand.adb (Create_Standard): select Universal_Integer as an ALFA type
7526 * sem_ch3.adb (Array_Type_Declaration): detect array types in ALFA
7527 * sem_util.adb, sem_util.ads (Has_Static_Array_Bounds): new function to
7528 detect that an array has static bounds.
7529
7530 2011-08-03 Thomas Quinot <quinot@adacore.com>
7531
7532 * exp_dist.adb: Minor reformatting.
7533
7534 2011-08-03 Arnaud Charlet <charlet@adacore.com>
7535
7536 * s-taprop-irix.adb, s-taprop-hpux-dce.adb, s-taprop-vms.adb
7537 (ATCB_Key): Removed, not always used.
7538
7539 2011-08-03 Emmanuel Briot <briot@adacore.com>
7540
7541 * gnatcmd.adb, make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads,
7542 clean.adb, prj-conf.adb, prj-env.adb, prj-env.ads (Makeutl): remove
7543 most remaining global variables.
7544
7545 2011-08-03 Robert Dewar <dewar@adacore.com>
7546
7547 * gnatcmd.adb, prj-proc.adb, mlib-prj.adb, prj.adb, makeutl.ads,
7548 prj-util.adb, prj-util.ads, prj-conf.adb, prj-env.adb: Minor
7549 reformatting.
7550
7551 2011-08-03 Javier Miranda <miranda@adacore.com>
7552
7553 * exp_util.adb (Is_VM_By_Copy_Actual): Include N_Slide nodes as actuals
7554 that must be passed by copy in VM targets.
7555
7556 2011-08-03 Emmanuel Briot <briot@adacore.com>
7557
7558 * prj.ads, prj-nmsc.adb (Files_Htable): removed this htable, which
7559 duplicates a similar htable now in the project tree.
7560
7561 2011-08-03 Claire Dross <dross@adacore.com>
7562
7563 * a-cfdlli.adb, a-cfhama.adb, a-cfhase.adb, a-cforma.adb, a-cforse.adb,
7564 a-cofove.adb ("=", Length, Is_Empty, Clear, Assign, Copy, Element,
7565 Replace_Element, Query_Element, Update_Element, Move, Insert, Prepend,
7566 Append, Delete, Delete_First, Delete_Last, Reverse_Element, Swap,
7567 Splice, First, First_Element, Last, Last_Element, Next, Previous, Find,
7568 Reverse_Find, Contains, Has_Element, Iterate, Reverse_Iterate, Capacity,
7569 Reserve_Length, Length, Strict_Equal, Left, Right): Data-structure
7570 update.
7571
7572 2011-08-03 Arnaud Charlet <charlet@adacore.com>
7573
7574 * s-taprop-posix.adb, s-taprop-linux.adb, s-taprop-tru64.adb
7575 (ATCB_Key): Removed, not always used.
7576 * s-tpopsp-posix.adb, s-tpopsp-posix-foreign.adb (ATCB_Key): Moved from
7577 s-taprop-posix.adb.
7578 * s-tpopsp-tls.adb: New file.
7579 * gcc-interface/Makefile.in: Use TLS implementation of s-tpopsp.adb on
7580 x86/x64/ia64/powerpc/sparc Linux.
7581
7582 2011-08-03 Arnaud Charlet <charlet@adacore.com>
7583
7584 * system-aix.ads, system-aix64.ads: Set ZCX_By_Default to True.
7585 * gcc-interface/Makefile.in: Switch to ZCX by default on AIX ports.
7586
7587 2011-08-03 Thomas Quinot <quinot@adacore.com>
7588
7589 * rtsfind.ads, exp_dist.adb, exp_dist.ads
7590 (Build_From_Any_Call, Build_To_Any_Call, Build_TypeCode_Call):
7591 Fix type selection for mapping integer types to PolyORB types.
7592
7593 2011-08-03 Bob Duff <duff@adacore.com>
7594
7595 * sem_ch7.adb: Minor comment clarification.
7596
7597 2011-08-03 Bob Duff <duff@adacore.com>
7598
7599 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): If we get
7600 an error analyzing a choice, skip further processing. Further
7601 processing could cause a crash or cascade errors.
7602
7603 2011-08-03 Emmanuel Briot <briot@adacore.com>
7604
7605 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, mlib-prj.adb,
7606 prj.adb, prj.ads, makeutl.adb, makeutl.ads, clean.adb, prj-nmsc.adb,
7607 prj-util.adb, prj-util.ads, prj-conf.adb, prj-conf.ads, prj-env.adb,
7608 prj-env.ads (Shared_Project_Tree_Data): new type
7609 An aggregate project and its aggregated trees need to share the common
7610 data structures used for lists of strings, packages,... This makes the
7611 code simpler since otherwise we have to pass the root tree (also used
7612 for the configuration file data) in addition to the current project
7613 tree. This also avoids ambiguities as to which tree should be used.
7614 And finally this saves a bit of memory.
7615 (For_Every_Project_Imported): new parameter Tree.
7616 Since aggregated projects are using a different tree, we need to let
7617 the caller know which tree to use to manipulate the returned project.
7618
7619 2011-08-03 Robert Dewar <dewar@adacore.com>
7620
7621 * prj-proc.adb, exp_util.ads, exp_ch9.adb, make.adb, prj-ext.adb,
7622 prj-ext.ads, alfa.ads, sem_ch4.adb, makeutl.adb, makeutl.ads,
7623 lib-xref-alfa.adb, sem_cat.adb, exp_dist.adb, get_alfa.adb,
7624 prj-env.adb, prj-env.ads, prj-tree.adb, alfa.ads: Minor reformatting.
7625
7626 2011-08-03 Javier Miranda <miranda@adacore.com>
7627
7628 * exp_util.adb, sem_aux.adb, exp_util.ads, sem_aux.ads:
7629 Move routine Is_VM_By_Copy_Actual from sem_aux to exp_util.
7630
7631 2011-08-03 Bob Duff <duff@adacore.com>
7632
7633 * sem_ch8.adb (Is_Primitive_Operator_In_Use): Always check In_Use on
7634 the Base_Type.
7635
7636 2011-08-03 Joel Brobecker <brobecker@adacore.com brobecker>
7637
7638 * g-sha256.ads, g-sha512.ads, g-sha1.ads, g-sha224.ads, g-sha384.ads,
7639 g-sehash.ads: Fix typo. Update header.
7640
7641 2011-08-03 Thomas Quinot <quinot@adacore.com>
7642
7643 * exp_ch6.adb (Expand_Actuals): Remove Ada_2005 guard on build-in-place
7644 expansion.
7645
7646 2011-08-03 Gary Dismukes <dismukes@adacore.com>
7647
7648 * sem_ch4.adb (Analyze_Overloaded_Selected_Component): Consider
7649 prefixes of private types along with records, since the selector may be
7650 a discriminant.
7651 * sem_res.adb (Resolve_Selected_Component): Consider prefixes of
7652 private types along with records, since the selector may be a
7653 discriminant.
7654
7655 2011-08-03 Emmanuel Briot <briot@adacore.com>
7656
7657 * prj-pp.adb (Pretty_Print): Remove trailing blank line.
7658
7659 2011-08-03 Javier Miranda <miranda@adacore.com>
7660
7661 * sem_aux.adb (Is_VM_By_Copy_Actual): Fix wrong use of
7662 Tagged_Type_Expansion.
7663
7664 2011-08-03 Yannick Moy <moy@adacore.com>
7665
7666 * sem_res.adb (Resolve_Op_Concat_Arg): Do not issue a SPARK
7667 violation when the argument of concatenation is the name of a
7668 constant.
7669
7670 2011-08-03 Emmanuel Briot <briot@adacore.com>
7671
7672 * prj-proc.adb, prj-ext.adb, prj-ext.ads, prj-env.adb, prj-env.ads,
7673 prj-tree.adb, prj-tree.ads (Initialize_And_Copy, Copy): new subprograms
7674 (Process_Declarative_Items): new parameter Child_Env.
7675
7676 2011-08-03 Yannick Moy <moy@adacore.com>
7677
7678 * alfa.ads: Update format of ALFA section in ALI file in order to
7679 add a mapping from bodies to specs when both are present.
7680 (ALFA_Scope_Record): Add components for spec file/scope.
7681 * get_alfa.adb (Get_ALFA): Read the new file/scope for spec when
7682 present.
7683 * lib-xref-alfa.adb (Collect_ALFA): After all scopes have been
7684 collected, fill in the spec information when relevant.
7685 * put_alfa.adb (Put_ALFA): Write the new file/scope for spec when
7686 present.
7687
7688 2011-08-03 Eric Botcazou <ebotcazou@adacore.com>
7689
7690 * inline.adb (Add_Inlined_Subprogram): Do not consider the enclosing
7691 code unit to decide whether to add internally generated subprograms.
7692
7693 2011-08-03 Javier Miranda <miranda@adacore.com>
7694
7695 * sem_aux.ads, sem_aux.adb (Is_VM_By_Copy_Actual): New subprogram.
7696 * exp_ch9.adb (Build_Simple_Entry_Call): Handle actuals that must
7697 be handled by copy in VM targets.
7698
7699 2011-08-03 Emmanuel Briot <briot@adacore.com>
7700
7701 * make.adb, makeutl.adb, makeutl.ads (Make.Switches_Of): Share
7702 code with Makeutl.Get_Switches.
7703 * prj-tree.adb: Update comment.
7704
7705 2011-08-03 Thomas Quinot <quinot@adacore.com>
7706
7707 * sem_cat.adb (Validate_RCI_Subprogram_Declaration): Reject a remote
7708 subprogram with a limited formal that does not support external
7709 streaming.
7710
7711 2011-08-03 Yannick Moy <moy@adacore.com>
7712
7713 * get_alfa.adb (Get_ALFA): add missing Skip_Spaces at start of
7714 continuation line
7715 * lib-xref-alfa.adb (Add_ALFA_File): split removal of scopes that are
7716 not from current unit in two phases, because it is not possible to
7717 change the table while iterating over its content.
7718 * put_alfa.adb (Put_ALFA): reset current file/scope at each new entity
7719
7720 2011-08-03 Sergey Rybin <rybin@adacore.com>
7721
7722 * vms_data.ads: Add qualifier for gnatmetric --no-static-loop option
7723 * gnat_ugn.texi: Update description of complexity metrics (gnatmetric)
7724
7725 2011-08-03 Ed Schonberg <schonberg@adacore.com>
7726
7727 * sem_res.adb (Resolve_Op_Concat_Arg): if the argument is an aggregate
7728 and the component type is composite, this is ambiguous for predefined
7729 concatenation, but if the node is not overloaded and the entity is a use
7730 -defined function its profile can be used to resolve that aggregate.
7731
7732 2011-08-03 Robert Dewar <dewar@adacore.com>
7733
7734 * exp_ch4.adb: Minor code cleanup.
7735
7736 2011-08-03 Thomas Quinot <quinot@adacore.com>
7737
7738 * exp_dist.adb: Do not generate distribution stubs if serious errors
7739 have been diagnosed.
7740
7741 2011-08-03 Ed Schonberg <schonberg@adacore.com>
7742
7743 * sem_ch4.adb (Try_Primitive_Operation): when checking the validity of
7744 the first formal of a primitive operation, go to the base type to
7745 handle properly an access to a derived type with constrained
7746 discriminants.
7747 * sem_type.adb (Disambiguate): an immediately visible operator hides a
7748 user-defined function that is only use-visible.
7749
7750 2011-08-03 Robert Dewar <dewar@adacore.com>
7751
7752 * sem_aggr.adb, sem_ch3.adb, lib.ads, gnatcmd.adb, prj-proc.adb,
7753 make.adb, lib-writ.adb, prj-part.adb, prj-part.ads, prj-ext.adb,
7754 fname-uf.adb, prj-ext.ads, prj.adb, prj.ads, sem_attr.adb, alfa.adb,
7755 prj-makr.adb, errout.adb, makeutl.adb, makeutl.ads, restrict.ads,
7756 sem_ch6.adb, g-pehage.adb, clean.adb, put_alfa.adb, lib-xref-alfa.adb,
7757 prj-nmsc.adb, prj-nmsc.ads, sem_ch8.adb, prj-pars.ads, exp_aggr.adb,
7758 prj-attr.ads, sem_ch13.adb, get_alfa.adb, prj-env.adb, prj-env.ads,
7759 alfa_test.adb, prj-tree.adb, prj-tree.ads, einfo.ads: Minor reformatting
7760
7761 2011-08-03 Robert Dewar <dewar@adacore.com>
7762
7763 * repinfo.adb (List_Mechanism): Add handling of
7764 Convention_Ada_Pass_By_XXX.
7765 * sem_mech.adb (Set_Mechanism): Ditto.
7766 * sem_prag.adb (Process_Convention): Add entries for
7767 Convention_Ada_Pass_By_XXX.
7768 * snames.adb-tmpl, snames.ads-tmpl: Ditto.
7769
7770 2011-08-03 Pascal Obry <obry@adacore.com>
7771
7772 * makeutl.adb: Minor reformatting.
7773
7774 2011-08-03 Vincent Celier <celier@adacore.com>
7775
7776 * fname-uf.adb
7777 (Get_File_Name) If the file cannot be found when there are no config
7778 pragmas file and May_Fail is True, return No_File instead of the file
7779 name, to be consistent.
7780
7781 2011-08-03 Pascal Obry <obry@adacore.com>
7782
7783 * adaint.c (__gnat_is_executable_file_attr): Avoid access
7784 to null pointer.
7785
7786 2011-08-03 Javier Miranda <miranda@adacore.com>
7787
7788 * sem_ch13.adb
7789 (Same_Representation): In VM targets the representation of arrays with
7790 aliased components differs from arrays with non-aliased components.
7791
7792 2011-08-03 Emmanuel Briot <briot@adacore.com>
7793
7794 * prj-proc.adb, prj-attr.adb, prj-attr.ads (Get_Attribute_Index): do
7795 not systematically lower case attribute indexes that contain no "."
7796 Fix definition of several Naming attributes, which take
7797 a unit name as index and therefore should be case insensitive.
7798 Minor refactoring (reduce length of variable names).
7799
7800 2011-08-03 Emmanuel Briot <briot@adacore.com>
7801
7802 * makeutl.adb, makeutl.ads (Get_Switches): new subprogram.
7803
7804 2011-08-03 Emmanuel Briot <briot@adacore.com>
7805
7806 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, prj-part.adb,
7807 prj-part.ads, switch-m.adb, switch-m.ads, prj-makr.adb, clean.adb,
7808 prj-pars.adb, prj-pars.ads, prj-conf.adb, prj-conf.ads, prj-tree.adb,
7809 prj-tree.ads (Prj.Tree.Environment): new type.
7810
7811 2011-08-03 Emmanuel Briot <briot@adacore.com>
7812
7813 * prj-proc.adb, prj.ads, makeutl.adb, makeutl.ads, prj-conf.adb,
7814 prj-tree.adb, prj-tree.ads (Environment): new type.
7815
7816 2011-08-03 Emmanuel Briot <briot@adacore.com>
7817
7818 * prj-tree.ads: Remove unused variable.
7819
7820 2011-08-03 Yannick Moy <moy@adacore.com>
7821
7822 * restrict.adb (Restriction_Msg): set "SPARK" all in upper case for
7823 issuing messages related to SPARK restriction violation.
7824
7825 2011-08-03 Ed Schonberg <schonberg@adacore.com>
7826
7827 * sem_ch6.adb: guard against error nodes in return statements.
7828
7829 2011-08-03 Arnaud Charlet <charlet@adacore.com>
7830
7831 * errout.adb (Error_Msg_Internal): the main unit has not been read yet,
7832 a warning can only appear on a configuration file, so emit warning
7833 without further checks.
7834
7835 2011-08-03 Arnaud Charlet <charlet@adacore.com>
7836
7837 * s-interr.ads: add overriding keyword.
7838
7839 2011-08-03 Geert Bosch <bosch@adacore.com>
7840
7841 * exp_attr.adb: Fix minor typo.
7842
7843 2011-08-03 Ed Schonberg <schonberg@adacore.com>
7844
7845 * par-ch4.adb: improve error recovery.
7846
7847 2011-08-03 Emmanuel Briot <briot@adacore.com>
7848
7849 * prj-part.adb, prj-part.ads, prj-makr.adb, prj-pars.adb, prj-conf.adb,
7850 prj-env.adb (Prj.Part.Parse): change parameter Always_Errout_Finalize
7851 to Errout_Handling.
7852
7853 2011-08-03 Emmanuel Briot <briot@adacore.com>
7854
7855 * prj-dect.adb (Parse_Attribute_Declaration): make sure we can use
7856 "external" as an attribute name in aggregate projects.
7857
7858 2011-08-03 Jose Ruiz <ruiz@adacore.com>
7859
7860 * s-taprop-vxworks.adb: (Create_Task, Initialize): Ada 2012 pragma CPU
7861 uses CPU numbers starting 1, while VxWorks uses CPU numbers starting
7862 from 0, so we need to adjust.
7863
7864 2011-08-03 Emmanuel Briot <briot@adacore.com>
7865
7866 * prj-proc.adb, prj-ext.adb, prj-ext.ads, makeutl.adb, prj-tree.adb,
7867 prj-tree.ads, gnatcmd.adb, clean.adb (External_References): new type.
7868
7869 2011-08-03 Yannick Moy <moy@adacore.com>
7870
7871 * sem_ch6.adb (New_Overloaded_Entity): only issue error for SPARK
7872 restriction on overloaded entity if the entity is not an operator.
7873
7874 2011-08-03 Yannick Moy <moy@adacore.com>
7875
7876 * sem_ch7.adb, sem_res.adb, sem_attr.adb, restrict.adb,
7877 restrict.ads: Rename remaining Check_Formal_Restriction* into
7878 Check_SPARK_Restriction*.
7879
7880 2011-08-03 Emmanuel Briot <briot@adacore.com>
7881
7882 * prj-proc.adb, prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb,
7883 prj-nmsc.ads, prj-err.adb (Project_Data): now discriminated on its
7884 qualifier.
7885 (Project_Empty): removed
7886 (Empty_Project): new parameter Qualifier
7887 This is used to have fields specific to aggregate projects, cleaner
7888 New field to store the list of aggregated projects.
7889 (Check_Aggregate_Project): removed
7890 (Process_Aggregated_Projects, Free): new subprograms.
7891
7892 2011-08-03 Olivier Hainque <hainque@adacore.com>
7893
7894 * tracebak.c (STOP_FRAME ppc AIX): Stop at null return address as well.
7895
7896 2011-08-03 Ed Schonberg <schonberg@adacore.com>
7897
7898 * sem_ch8.adb (Analyze_Object_Renaming): if the renamed object is an
7899 explicit dereference of an unconstrained type, create a constrained
7900 subtype for it, as is done for function calls that return an
7901 unconstrained type.
7902
7903 2011-08-03 Thomas Quinot <quinot@adacore.com>
7904
7905 * g-pehage.adb (Finalize): Avoid possible double-free.
7906
7907 2011-08-03 Steve Baird <baird@adacore.com>
7908
7909 * exp_attr.adb (Expand_N_Attribute_Reference): Don't expand
7910 Elab_Spec/Body attrs in CodePeer_Mode.
7911
7912 2011-08-03 Javier Miranda <miranda@adacore.com>
7913
7914 * exp_aggr.adb (Flatten): Convert to positional form aggregates whose
7915 low bound is not known at compile time but they have no others choice.
7916 Done because in this case the bounds can be obtained directly from the
7917 aggregate.
7918
7919 2011-08-03 Ed Falis <falis@adacore.com>
7920
7921 * s-tasinf-vxworks.ads: Update comment to reflect 0 indexing of CPUs
7922 on VxWorks SMP. Remove unusable constant ANY_CPU.
7923
7924 2011-08-03 Emmanuel Briot <briot@adacore.com>
7925
7926 * gnatcmd.adb, make.adb, prj-part.adb, prj-part.ads, prj-makr.adb,
7927 clean.adb, prj-nmsc.adb, prj-pars.adb, prj-conf.adb, prj-env.adb,
7928 prj-env.ads (Prj.Env.Initialize_Default_Project_Path,
7929 Prj.Env.Initialize_Empty): new subprograms
7930 (Get_Env, Find_Project): remove parameter Target_Name.
7931
7932 2011-08-03 Gary Dismukes <dismukes@adacore.com>
7933
7934 * sem_ch3.adb (Build_Derived_Record_Type): Test the Derive_Subps formal
7935 as a condition for the delayed call to Derived_Subprograms done for the
7936 case of the rewriting of a derived type that constrains the
7937 discriminants of its parent type.
7938 Avoids redundant subprogram derivations for private subtype derivations.
7939
7940 2011-08-03 Javier Miranda <miranda@adacore.com>
7941
7942 * exp_aggr.adb (Init_Hidden_Discriminants): New subprogram of
7943 Build_Record_Aggr_Code.
7944 (Build_Record_Aggr_Code): Add missing support to initialize hidden
7945 discriminants in extension aggregates.
7946
7947 2011-08-03 Emmanuel Briot <briot@adacore.com>
7948
7949 * prj-pp.adb (Print): also output project qualifiers, since in
7950 particular "aggregate" is mandatory in an aggregate project.
7951
7952 2011-08-03 Emmanuel Briot <briot@adacore.com>
7953
7954 * prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb, prj-env.adb:
7955 (Debug_Output): new function.
7956
7957 2011-08-03 Eric Botcazou <ebotcazou@adacore.com>
7958
7959 * gnat_ugn.texi: Document -Wstack-usage.
7960 * gcc-interface/misc.c (enumerate_modes): Add guard for ghost FP modes.
7961
7962 2011-08-03 Thomas Quinot <quinot@adacore.com>
7963
7964 * sem_prag.adb Issue an error (not a warning) when a C++ type does not
7965 have keyword LIMITED.
7966
7967 2011-08-03 Yannick Moy <moy@adacore.com>
7968
7969 * alfa.adb, alfa.ads, alfa_test.adb: New files.
7970 * ali.adb (Known_ALI_Lines): add 'C' lines (SCO) and 'F' lines (ALFA)
7971 (Scan_ALI): do not issue a fatal error if parsing known lines after Xref
7972 section (does not happen in compiler, only if code directly calls
7973 Scan_ALI).
7974 * get_alfa.adb, get_alfa.ads: New files.
7975 * lib-writ.adb, lib-writ.ads (Write_ALI): output ALFA information if
7976 needed.
7977 * lib-xref-alfa.adb: New file.
7978 * lib-xref.adb, lib-xref.ads
7979 (Xref_Entry): redefine information needed in cross-references for ALFA.
7980 Push ALFA treatments in separated local package.
7981 (Enclosing_Subpragram_Or_Package): treat specially subprogram
7982 identifiers. Return entity of package body instead of spec. Return
7983 Empty for a scope with no location.
7984 (Generate_Reference): adapt to new components for ALFA information.
7985 Remove the need for D references on definitions.
7986 (Is_Local_Reference): moved to ALFA local package
7987 (Output_References): extract subfunction as Extract_Source_Name
7988 (Output_Local_References): remove procedure, replaced by filtering of
7989 cross-references in package ALFA and printing in Put_ALFA.
7990 (Write_Entity_Name): remove procedure
7991 * lib.adb, lib.ads (Extract_Source_Name): extract here function to
7992 print exact name of entity as it appears in source file
7993 (Unit_Ref_Table): make type public for use in Lib.Xref.ALFA
7994 * put_alfa.adb, put_alfa.ads: New files.
7995 * xref_lib.adb (Search_Xref): protect read of cross-references against
7996 reading other sections of the ALI file, in gnatxref
7997 (Search): protect read of cross-references against reading other
7998 sections of the ALI file, in gnatfind.
7999 * gcc-interface/Make-lang.in: Update dependencies.
8000
8001 2011-08-03 Thomas Quinot <quinot@adacore.com>
8002
8003 * sem_ch3.adb: Minor reformatting.
8004
8005 2011-08-03 Jose Ruiz <ruiz@adacore.com>
8006
8007 * s-inmaop-vxworks.adb (Setup_Interrupt_Mask): Do nothing instead of
8008 raising an exception.
8009
8010 2011-08-03 Ed Schonberg <schonberg@adacore.com>
8011
8012 * sem_res.adb (Set_String_Literal_Subtype): if index type is an integer
8013 type, always use 1 as the lower bound or string, even if lower bound of
8014 context is not static, to handle properly null strings in a non-static
8015 context.
8016
8017 2011-08-03 Bob Duff <duff@adacore.com>
8018
8019 * sem_prag.adb (Resolve_Aggregate): An array aggregate with 'others' is
8020 always legal on the right-hand side of an assignment statement; there
8021 is always an applicable index constraint in this case. Therefore, the
8022 check for Pkind = N_Assignment_Statement is now unconditional -- it
8023 doesn't depend on whether Is_Constrained (Typ).
8024
8025 2011-08-03 Robert Dewar <dewar@adacore.com>
8026
8027 * exp_ch5.adb, sem_prag.adb, exp_ch4.adb: Minor reformatting.
8028
8029 2011-08-03 Ed Schonberg <schonberg@adacore.com>
8030
8031 * sem_ch3.adb (Build_Itype_Reference): do not create an itype reference
8032 for an itype created within a generic unit.
8033
8034 2011-08-03 Eric Botcazou <ebotcazou@adacore.com>
8035
8036 * gnat_ugn.texi (Switches for gcc): Make it clearer that -fno-inline
8037 suppresses all inlining.
8038
8039 2011-08-03 Robert Dewar <dewar@adacore.com>
8040
8041 * sem_ch3.adb, sem_res.adb, exp_ch13.adb, exp_disp.adb,
8042 exp_aggr.adb: Minor reformatting.
8043
8044 2011-08-03 Thomas Quinot <quinot@adacore.com>
8045
8046 * exp_ch5.adb (Expand_N_Assignment_Statement): Do not force inlining of
8047 tagged assignment when discriminant checks are suppressed. This is
8048 useless and extremely costly in terms of static stack usage.
8049
8050 2011-08-03 Bob Duff <duff@adacore.com>
8051
8052 * sem_prag.adb (Get_Base_Subprogram): Do not follow Alias for instances
8053 of generics, because this leads to the wrong entity in the wrong scope,
8054 causing (e.g.) pragma Export_Procedure to get an error if the entity is
8055 an instance.
8056 (Process_Interface_Name): Follow Alias for instances of generics, to
8057 correct for the above change.
8058
8059 2011-08-03 Ed Schonberg <schonberg@adacore.com>
8060
8061 * exp_ch4.adb (Expand_N_Selected_Component): If the discriminant value
8062 is an integer literal it is always safe to replace the reference. In
8063 addition, if the reference appears in the generated code for an object
8064 declaration it is necessary to copy because otherwise the reference
8065 might be to the uninitilized value of the discriminant of the object
8066 itself.
8067
8068 2011-08-03 Pascal Obry <obry@adacore.com>
8069
8070 * adaint.c (__gnat_is_executable_file_attr): Fix Win32 circuitry when no
8071 ACL used, in this case we want to check for ending .exe, not .exe
8072 anywhere in the path.
8073
8074 2011-08-03 Sergey Rybin <rybin@adacore.com>
8075
8076 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
8077 the tree structure (semantic decoration of references to record
8078 discriminants).
8079
8080 2011-08-03 Gary Dismukes <dismukes@adacore.com>
8081
8082 * sem_aggr.adb (Analyze_Array_Aggregate): When checking the discrete
8083 choices of a named array aggregate, bail out when any choices are
8084 marked as Errors_Posted.
8085
8086 2011-08-03 Ed Schonberg <schonberg@adacore.com>
8087
8088 * exp_ch13.adb (Expand_N_Freeze_Entity): cleanup determination of scope
8089 in which entity is frozen, to handle properly loop variables in
8090 iterators.
8091
8092 2011-08-03 Ed Schonberg <schonberg@adacore.com>
8093
8094 * sem_res.adb (Set_String_Literal_Subtype): if the lower bound of the
8095 subtype is not static, compute the upper bound using attributes, to
8096 handle properly index types that are not integer types.
8097
8098 2011-08-03 Bob Duff <duff@adacore.com>
8099
8100 * gnat_rm.texi, gnat_ugn.texi: Fix some dangling URLs.
8101 Update copyright notice.
8102
8103 2011-08-03 Ed Schonberg <schonberg@adacore.com>
8104
8105 * sem_ch3.adb (Build_Discriminant_Constraints): Only use
8106 Original_Discriminant if within an instance.
8107 * sem_ch4.adb (Analyze_Selected_Component): Ditto.
8108
8109 2011-08-03 Thomas Quinot <quinot@adacore.com>
8110
8111 * einfo.ads: Minor reformatting.
8112
8113 2011-08-03 Ed Schonberg <schonberg@adacore.com>
8114
8115 * exp_disp.adb (Check_Premature_Freezing): diagnose the presence of a
8116 composite type with an unfrozen subcomponent, in the profile of a
8117 primitive operation.
8118
8119 2011-08-03 Robert Dewar <dewar@adacore.com>
8120
8121 * sem_util.ads, exp_aggr.adb, exp_ch3.adb: Minor reformatting.
8122
8123 2011-08-03 Ed Schonberg <schonberg@adacore.com>
8124
8125 * sem_ch3.adb (Analyze_Object_Declaration): if a constant object of an
8126 unconstrained type with discriminants is initialized with an aggregate,
8127 use the constrained subtype of the aggregate as the type of the object,
8128 because it is immutable, and this allows the back-end to generate no
8129 code for the object declaration.
8130
8131 2011-08-03 Robert Dewar <dewar@adacore.com>
8132
8133 * exp_ch4.adb (Optimize_Length_Check): Fix bad handling of case where
8134 comparison operand is variable, and turns out to be zero or negative.
8135
8136 2011-08-03 Javier Miranda <miranda@adacore.com>
8137
8138 * exp_intr.adb
8139 (Expand_Dispatching_Constructor_Call): Disable expansion of
8140 code required for native targets. Done to avoid generating
8141 references to unavailable runtime entities in VM targets.
8142 * exp_ch3.adb
8143 (Expand_N_Object_Declaration): Add missing support to handle
8144 the explicit initialization of class-wide interface objects.
8145 Fix documentation.
8146
8147 2011-08-03 Matthew Heaney <heaney@adacore.com>
8148
8149 * a-cobove.adb (Merge): Move source onto target, instead of using Assign
8150
8151 2011-08-03 Matthew Heaney <heaney@adacore.com>
8152
8153 * a-cbdlli.adb (Splice): move source items from first to last
8154
8155 2011-08-03 Yannick Moy <moy@adacore.com>
8156
8157 * sem_util.ads: comment added.
8158
8159 2011-08-03 Javier Miranda <miranda@adacore.com>
8160
8161 * exp_aggr.adb
8162 (Expand_Record_Aggregate): In VM targets disable the expansion into
8163 assignments of aggregates whose type is not known at compile time.
8164
8165 2011-08-03 Ed Schonberg <schonberg@adacore.com>
8166
8167 * exp_ch9.adb (Build_Renamed_Formal_Declaration): common procedure for
8168 protected entries and task entries, to build the proper renaming
8169 declaration for entry formals, used in debugging.
8170 * exp_ch2.adb (Expand_Entry_Parameter): handle task and entry
8171 parameters in the same way.
8172
8173 2011-08-02 Robert Dewar <dewar@adacore.com>
8174
8175 * a-direct.adb, sinfo.ads, exp_ch9.adb, scng.adb, sem_util.adb,
8176 sem_util.ads, restrict.ads, par-prag.adb: Minor reformatting and/or
8177 code reorganization.
8178
8179 2011-08-02 Robert Dewar <dewar@adacore.com>
8180
8181 * debug.adb: Debug flag d.P to suppress length comparison optimization
8182 * exp_ch4.adb (Optimize_Length_Comparison): New routine to optimize
8183 comparison of Length by comparing First/Last instead.
8184
8185 2011-08-02 Matthew Heaney <heaney@adacore.com>
8186
8187 * a-cobove.ads: Code clean up.
8188
8189 2011-08-02 Vincent Celier <celier@adacore.com>
8190
8191 * adaint.c (file_names_case_sensitive_cache): New static int.
8192 (__gnat_get_file_names_case_sensitive): Cache the return value in
8193 file_names_case_sensitive_cache at the first invocation, to avoid
8194 multiple calls to getenv.
8195
8196 2011-08-02 Bob Duff <duff@adacore.com>
8197
8198 * sem_ch12.adb (Validate_Derived_Type_Instance): Implement AI05-0218-1.
8199
8200 2011-08-02 Yannick Moy <moy@adacore.com>
8201
8202 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_prag.adb, sem.ads,
8203 sem_util.adb, sem_util.ads, sem_res.adb, sem_ch2.adb, sem_ch4.adb,
8204 sem_ch6.adb, sem_ch11.adb: Add semantic flag In_Pre_Post_Expression to
8205 indicate that we are in a precondition or postcondition. This is used in
8206 Mark_Non_ALFA_Subprogram (renaming of Mark_Non_ALFA_Subprogram_Body) to
8207 decide whether to flag the spec or body of the current subprogram as
8208 not in ALFA.
8209
8210 2011-08-02 Fabien Chouteau <chouteau@adacore.com>
8211
8212 * impunit.adb: Add Ada.Execution_Time.Interrupts in the Ada2012 package
8213 list.
8214 * a-extiin.ads: New file.
8215
8216 2011-08-02 Bob Duff <duff@adacore.com>
8217
8218 * a-direct.adb (Rename): Implement AI05-0231-1. In particular, Rename
8219 now raises Name_Error instead of Use_Error in certain cases. The other
8220 parts of this AI were already implemented properly.
8221
8222 2011-08-02 Vincent Celier <celier@adacore.com>
8223
8224 * link.c: Only import "auto-host.h" when building the gnattools.
8225
8226 2011-08-02 Yannick Moy <moy@adacore.com>
8227
8228 * sem_util.adb: Inter-unit inlining does not work for a subprogram
8229 which calls a local subprogram, so extract subprogram
8230 from Mark_Non_ALFA_Subprogram_Body.
8231
8232 2011-08-02 Javier Miranda <miranda@adacore.com>
8233
8234 * exp_ch9.adb
8235 (Extract_Dispatching_Call): If the type of the dispatching object is an
8236 access type then return an explicit dereference in the Object out-mode
8237 parameter.
8238
8239 2011-08-02 Gary Dismukes <dismukes@adacore.com>
8240
8241 * sem_ch3.adb (Analyze_Subtype_Declaration): Generate range
8242 compatibility checks for all indexes of an array subtype, not just the
8243 first. Reset Has_Dynamic_Range_Check on the subtype before each
8244 potential check to ensure that Insert_Range_Checks will not elide any
8245 of the dynamic checks.
8246
8247 2011-08-02 Yannick Moy <moy@adacore.com>
8248
8249 * par-prag.ad (Process_Restrictions_Or_Restriction_Warnings): recognize
8250 SPARK restriction at parsing time.
8251 * scng.adb (Scan): Generate a token Tok_SPARK_Hide for a SPARK HIDE
8252 directive only if the SPARK restriction is set for this unit.
8253
8254 2011-08-02 Yannick Moy <moy@adacore.com>
8255
8256 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb, sem_util.ads,
8257 sem_res.adb, sem_ch2.adb, sem_ch4.adb, sem_ch6.adb,
8258 sem_ch11.adb: Protect call to Current_Subprogram which might be costly
8259 when repeated. Rename Current_Subprogram_Is_Not_In_ALFA into
8260 Mark_Non_ALFA_Subprogram_Body.
8261 Split body of Mark_Non_ALFA_Subprogram_Body to get body small and
8262 inlined.
8263
8264 2011-08-02 Yannick Moy <moy@adacore.com>
8265
8266 * sem_res.adb: Protect calls to Matching_Static_Array_Bounds which
8267 might be costly.
8268
8269 2011-08-02 Robert Dewar <dewar@adacore.com>
8270
8271 * exp_ch9.adb, exp_sel.adb, restrict.ads, exp_disp.adb, erroutc.ads,
8272 exp_ch3.adb: Minor reformatting.
8273
8274 2011-08-02 Emmanuel Briot <briot@adacore.com>
8275
8276 * adaint.c (__gnat_locate_exec_on_path): only returns executable
8277 files, not any regular file.
8278 (__gnat_locate_file_with_predicate): new subprogram.
8279
8280 2011-08-02 Yannick Moy <moy@adacore.com>
8281
8282 * sinfo.adb, sinfo.ads: Restrict the use of flags
8283 Has_Dynamic_Length_Check and Has_Dynamic_Range_Check to expression
8284 nodes, plus N_Subtype_Declaration for the 2nd one.
8285
8286 2011-08-02 Sergey Rybin <rybin@adacore.com>
8287
8288 * gnat_rm.texi: Ramification of pragma Eliminate documentation
8289 - fix bugs in the description of Source_Trace;
8290 - get rid of UNIT_NAME;
8291
8292 2011-08-02 Javier Miranda <miranda@adacore.com>
8293
8294 * exp_ch9.adb
8295 (Build_Dispatching_Requeue): Adding support for VM targets
8296 since we cannot directly reference the Tag entity.
8297 * exp_sel.adb (Build_K): Adding support for VM targets.
8298 (Build_S_Assignment): Adding support for VM targets.
8299 * exp_disp.adb
8300 (Default_Prim_Op_Position): In VM targets do not restrict availability
8301 of predefined interface primitives to compiling in Ada 2005 mode.
8302 (Is_Predefined_Interface_Primitive): In VM targets this service is not
8303 restricted to compiling in Ada 2005 mode.
8304 (Make_VM_TSD): Generate code that declares and initializes the OSD
8305 record. Needed to support dispatching calls through synchronized
8306 interfaces.
8307 * exp_ch3.adb
8308 (Make_Predefined_Primitive_Specs): Enable generation of predefined
8309 primitives associated with synchronized interfaces.
8310 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
8311 primitives associated with synchronized interfaces.
8312
8313 2011-08-02 Yannick Moy <moy@adacore.com>
8314
8315 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
8316 statements hidden in SPARK if preceded by the HIDE directive
8317 (Parse_Exception_Handlers): mark each exception handler in a sequence of
8318 exception handlers as hidden in SPARK if preceded by the HIDE directive
8319 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
8320 if starting with the HIDE directive
8321 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
8322 starting with the HIDE directive; mark the declarations in a private
8323 part as hidden in SPARK if the private part starts with the HIDE
8324 directive
8325 * restrict.adb, restrict.ads
8326 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
8327 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
8328 argument node belongs to a part which is hidden in SPARK
8329 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
8330 parts in SPARK; protect the possibly costly call to
8331 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
8332 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
8333 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
8334 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
8335 Tok_SPARK_Hide.
8336 (Scan): recognize special comment starting with '#' and followed by
8337 SPARK keyword "hide" as a HIDE directive.
8338
8339 2011-08-02 Yannick Moy <moy@adacore.com>
8340
8341 * types.ads, erroutc.ads: Minor reformatting.
8342
8343 2011-08-02 Vincent Celier <celier@adacore.com>
8344
8345 * link.c: Add response file support for cross platforms.
8346
8347 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8348
8349 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
8350 in an association, set parent field of copy before partial analysis.
8351 * sem_res.adb (Resolve_Slice): create reference to itype only when
8352 expansion is enabled.
8353
8354 2011-08-02 Yannick Moy <moy@adacore.com>
8355
8356 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
8357 for new flag denoting which subprogram bodies are in ALFA
8358 * restrict.adb, sem_ch7.adb: Update comment
8359 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
8360 sem_ch9.adb, sem_res.adb: Add calls to
8361 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
8362 * sem_ch6.adb (Analyze_Function_Return): add calls to
8363 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
8364 middle of the body, and extended return.
8365 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
8366 False when missing return.
8367 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
8368 to True for subprograms whose spec is in ALFA. Remove later on the flag
8369 on the entity used for a subprogram body when there exists a separate
8370 declaration.
8371 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
8372 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
8373 False, otherwise do nothing.
8374
8375 2011-08-02 Robert Dewar <dewar@adacore.com>
8376
8377 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
8378
8379 2011-08-02 Yannick Moy <moy@adacore.com>
8380
8381 * sem_ch4.ads: minor formatting.
8382
8383 2011-08-02 Yannick Moy <moy@adacore.com>
8384
8385 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
8386 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
8387 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
8388 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
8389 opt.ads: cleanup of SPARK mode
8390
8391 2011-08-02 Yannick Moy <moy@adacore.com>
8392
8393 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
8394 types.
8395 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
8396 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
8397 * sem_ch3.adb
8398 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
8399 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
8400 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
8401 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
8402 types.
8403 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
8404 non-static range.
8405 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
8406 functions whose return type is not in ALFA.
8407 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
8408 specifications.
8409 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
8410 parameter's type is not in ALFA.
8411 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
8412 types are in ALFA.
8413
8414 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8415
8416 * sem_ch6 (Analyze_Expression_Function): treat the function as
8417 Inline_Always, and introduce a subprogram declaration for it when it is
8418 not a completion.
8419 * inline.adb (Add_Inlined_Body): recognize bodies that come from
8420 expression functions, so that the back-end can determine whether they
8421 can in fact be inlined.
8422 * sem_util.adb (Is_Expression_Function): predicate to determine whether
8423 a function body comes from an expression function.
8424
8425 2011-08-02 Gary Dismukes <dismukes@adacore.com>
8426
8427 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
8428 null exclusions to test Can_Never_Be_Null on the anonymous access types
8429 of the formals rather than testing the formals themselves. Exclude this
8430 check in cases where the Old_Formal is marked as a controlling formal,
8431 to avoid issuing spurious errors for bodies completing dispatching
8432 operations (due to the flag not getting set on controlling access
8433 formals in body specs).
8434 (Find_Corresponding_Spec): When checking full and subtype conformance of
8435 subprogram bodies in instances, pass Designated and E in that order, for
8436 consistency with the expected order of the formals (New_Id followed by
8437 Old_Id).
8438
8439 2011-08-02 Robert Dewar <dewar@adacore.com>
8440
8441 * sem_ch8.adb: Minor reformatting.
8442
8443 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8444
8445 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
8446 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
8447 primitive operations of class-wide actuals.
8448
8449 2011-08-02 Javier Miranda <miranda@adacore.com>
8450
8451 * exp_atag.ads, exp_atag.adb
8452 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
8453 since its value is implicitly passed in argument Typ.
8454 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
8455 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
8456 Build_Common_Dispatching_Select_Statements.
8457
8458 2011-08-02 Robert Dewar <dewar@adacore.com>
8459
8460 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
8461 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
8462 Minor reformatting.
8463
8464 2011-08-02 Robert Dewar <dewar@adacore.com>
8465
8466 * sem_res.adb: Minor reformatting.
8467 * sem_prag.adb: Minor reformatting.
8468
8469 2011-08-02 Javier Miranda <miranda@adacore.com>
8470
8471 * exp_atag.adb, exp_atags.ads
8472 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
8473 by the tagged type Entity. Required to use this routine in the VM
8474 targets since we do not have available the Tag entity in the VM
8475 platforms.
8476 * exp_ch6.adb
8477 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
8478 Ada.Tags has not been previously loaded.
8479 * exp_ch7.adb
8480 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
8481 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
8482 * sem_aux.adb
8483 (Enclosing_Dynamic_Scope): Add missing support to handle the full
8484 view of enclosing scopes. Required to handle enclosing scopes that
8485 are synchronized types whose full view is a task type.
8486 * exp_disp.adb
8487 (Build_VM_TSDs): Minor code improvement to avoid generating and
8488 analyzing lists with empty nodes.
8489 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
8490 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
8491 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
8492 (Make_Disp_Timed_Select_Body): Add support for VM targets.
8493 (Make_Select_Specific_Data_Table): Add support for VM targets.
8494 (Make_VM_TSD): Generate code to initialize the SSD structure of
8495 the TSD.
8496
8497 2011-08-02 Yannick Moy <moy@adacore.com>
8498
8499 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
8500 cross-references section in ALI.
8501 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
8502 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
8503 Sub).
8504 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
8505 subprogram or package entity of a node
8506 (Is_Local_Reference_Type): new function returns True for references
8507 selected in local cross-references.
8508 (Lt): function extracted from Lt in Output_References
8509 (Write_Entity_Name): function extracted from Output_References
8510 (Generate_Definition): generate reference with type 'D' for definition
8511 of objects (object declaration and parameter specification), with
8512 appropriate locations and units, for use in local cross-references.
8513 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
8514 references of type 'I' for initialization in object definition.
8515 (Output_References): move part of function Lt and procedure
8516 Write_Entity_Name outside of the body. Ignore references of types 'D'
8517 and 'I' introduced for local cross-references.
8518 (Output_Local_References): new procedure to output the local
8519 cross-references sections.
8520 (Lref_Entity_Status): new array defining whether an entity is a local
8521 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
8522 with 'I' type when initialization expression is present.
8523 * get_scos.adb, get_scos.ads: Correct comments and typos
8524
8525 2011-08-02 Javier Miranda <miranda@adacore.com>
8526
8527 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
8528 the JVM target.
8529 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
8530 the JVM target.
8531 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
8532 TSD support.
8533
8534 2011-08-02 Vincent Celier <celier@adacore.com>
8535
8536 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
8537 (No_Space_Img): New function
8538 (Find_Excluded_Sources): When reading from a file, record the file name
8539 and the line number for each excluded source.
8540 (Mark_Excluded_Sources): When reporting an error, if the excluded
8541 sources were read from a file, include file name and line number in
8542 the error message.
8543
8544 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8545
8546 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
8547
8548 2011-08-02 Robert Dewar <dewar@adacore.com>
8549
8550 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
8551
8552 2011-08-02 Javier Miranda <miranda@adacore.com>
8553
8554 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
8555 generation of TSDs to the DOTNET compiler.
8556 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
8557 generation of TSDs to the DOTNET compiler.
8558
8559 2011-08-02 Javier Miranda <miranda@adacore.com>
8560
8561 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
8562 record of all the tagged types declared inside library level package
8563 declarations, library level package bodies or library level subprograms.
8564 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
8565 associated with a given tagged type.
8566 (Build_VM_TSDs): New subprogram.
8567 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
8568 compilation units that are subprograms.
8569 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
8570 compilation units that are package bodies.
8571 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
8572 units that are a package declaration or a package instantiation.
8573 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
8574 reorganization to improve the error generated by the frontend when the
8575 function Ada.Tags.Secondary_Tag is not available.
8576 * rtsfind.ads (RE_Register_TSD): New runtime entity.
8577 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
8578
8579 2011-08-02 Javier Miranda <miranda@adacore.com>
8580
8581 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
8582
8583 2011-08-02 Robert Dewar <dewar@adacore.com>
8584
8585 * s-imenne.ads: Minor reformatting.
8586
8587 2011-08-02 Robert Dewar <dewar@adacore.com>
8588
8589 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
8590 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
8591 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
8592
8593 2011-08-02 Robert Dewar <dewar@adacore.com>
8594
8595 * einfo.ads (Materialize_Entity): Document this is only for renamings
8596 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
8597 required debug information in the case where we transform the object
8598 declaration into a renaming declaration.
8599 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
8600 object
8601 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
8602 Materialize_Entity.
8603
8604 2011-08-02 Robert Dewar <dewar@adacore.com>
8605
8606 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
8607 Suppress_Init_Procs.
8608 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
8609 Suppress_Initialization/Initialization_Suppressed.
8610 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
8611 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
8612 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
8613 * sem_prag.adb: New processing for pragma Suppress_Initialization.
8614
8615 2011-08-02 Robert Dewar <dewar@adacore.com>
8616
8617 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
8618 Minor reformatting.
8619
8620 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8621
8622 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
8623 only have inheritable classwide pre/postconditions.
8624
8625 2011-08-02 Javier Miranda <miranda@adacore.com>
8626
8627 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
8628 * rtsfind.ads (RE_Check_TSD): New runtime entity.
8629 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
8630 checks if the external tag of a type is the same as the external tag
8631 of some other declaration.
8632
8633 2011-08-02 Thomas Quinot <quinot@adacore.com>
8634
8635 * s-taskin.ads: Minor reformatting.
8636
8637 2011-08-02 Emmanuel Briot <briot@adacore.com>
8638
8639 * g-comlin.adb (Display_Help): swap the order in which it prints the
8640 short help and the general usage.
8641
8642 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8643
8644 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
8645 the aspect declarations and attach them to the generic copy for
8646 subsequent analysis.
8647 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
8648 declarations of the generic tree to the new subprogram declarations.
8649 * sem_attr.adb (Check_Precondition_Postcondition): recognize
8650 conditions that apply to a subprogram instance.
8651
8652 2011-08-02 Robert Dewar <dewar@adacore.com>
8653
8654 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
8655
8656 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8657
8658 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
8659 private type with a tagged full view is not derived in the immediate
8660 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
8661
8662 2011-08-02 Robert Dewar <dewar@adacore.com>
8663
8664 * exp_ch4.adb: Minor reformatting.
8665
8666 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8667
8668 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
8669 Ada2012 iterator, the loop will be rewritten during expansion into a
8670 while loop with a cursor and an element declaration. Do not analyze the
8671 body in this case, because if the container is for indefinite types the
8672 actual subtype of the elements will only be determined when the cursor
8673 declaration is analyzed.
8674
8675 2011-08-02 Arnaud Charlet <charlet@adacore.com>
8676
8677 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
8678 size/alignment related attributes in CodePeer_Mode.
8679
8680 2011-08-02 Gary Dismukes <dismukes@adacore.com>
8681
8682 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
8683 Prepend_Element, since this can result in the operation getting the
8684 wrong slot in the full type's dispatch table if the full type has
8685 inherited operations. The incomplete type's operation will get added
8686 to the proper position in the full type's primitives
8687 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
8688 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
8689 dispatching operations, since there are cases where nonprimitive
8690 subprograms can get added to the list of incomplete dependents (such
8691 as subprograms in nested packages).
8692 * sem_ch6.adb (Process_Formals): First, remove test for being in a
8693 private part when determining whether to add a primitive with a
8694 parameter of a tagged incomplete type to the Private_Dependents list.
8695 Such primitives can also occur in the visible part, and should not have
8696 been excluded from being private dependents.
8697 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
8698 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
8699 list of a Taft-amendment incomplete type is a primitive before issuing
8700 an error that the full type must appear in the same unit. There are
8701 cases where nonprimitives can be in the list (such as subprograms in
8702 nested packages).
8703 * sem_disp.adb (Derives_From): Use correct condition for checking that
8704 a formal's type is derived from the type of the corresponding formal in
8705 the parent subprogram (the condition was completely wrong). Add
8706 checking that was missing for controlling result types being derived
8707 from the result type of the parent operation.
8708
8709 2011-08-02 Yannick Moy <moy@adacore.com>
8710
8711 * errout.adb (First_Node): minor renaming
8712 * restrict.adb (Check_Formal_Restriction): put restriction warning on
8713 first node.
8714
8715 2011-08-02 Yannick Moy <moy@adacore.com>
8716
8717 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
8718 before accessing operands.
8719 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
8720 decide whether an initialization expression respects SPARK rules, as
8721 the plain node is the expanded one. This allows for more valid warnings
8722 to be issued.
8723 * gnat_rm.texi: Minor update.
8724
8725 2011-08-02 Arnaud Charlet <charlet@adacore.com>
8726
8727 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
8728 previous change.
8729
8730 2011-08-02 Robert Dewar <dewar@adacore.com>
8731
8732 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
8733
8734 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
8735
8736 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
8737 loop statements and the element renaming declaration with a block when
8738 the element type is controlled.
8739
8740 2011-08-02 Yannick Moy <moy@adacore.com>
8741
8742 * sinfo.ads: Minor formatting.
8743
8744 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8745
8746 * sem_aggr.adb (Add_Association): if the association has a box and no
8747 expression, use the Sloc of the aggregate itself for the new
8748 association.
8749 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
8750 the Original_Node.
8751
8752 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
8753
8754 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
8755 When a container is provided via a function call, generate a renaming
8756 of the function result. This avoids the creation of a transient scope
8757 and the premature finalization of the container.
8758 * exp_ch7.adb (Is_Container_Cursor): Removed.
8759 (Wrap_Transient_Declaration): Remove the supression of the finalization
8760 of the list controller when the declaration denotes a container cursor,
8761 it is not needed.
8762
8763 2011-08-02 Yannick Moy <moy@adacore.com>
8764
8765 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
8766 node is from source, instead of the original node being from source.
8767 * sem_aggr.adb
8768 (Resolve_Array_Aggregate): refine the check for a static expression, to
8769 recognize also static ranges
8770 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
8771 Array_Type_Declaration): postpone the test for the type being a subtype
8772 mark after the type has been resolved, so that component-selection and
8773 expanded-name are discriminated.
8774 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
8775 to distinguish the case of an iteration scheme, so that an error is
8776 issed on a non-static range in SPARK except in an iteration scheme.
8777 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
8778 In_Iter_Schm = True.
8779 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
8780 user-defined operators so that they are allowed in renaming
8781 * sem_ch8.adb
8782 (Find_Selected_Component): refine the check for prefixing of operators
8783 so that they are allowed in renaming. Move the checks for restrictions
8784 on selector name after analysis discriminated between
8785 component-selection and expanded-name.
8786 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
8787 concatenation argument of string type if it is static.
8788 * sem_util.adb, sem_util.ads
8789 (Check_Later_Vs_Basic_Declarations): add a new function
8790 Is_Later_Declarative_Item to decice which declarations are allowed as
8791 later items, in the two different modes Ada 83 and SPARK. In the SPARK
8792 mode, add that renamings are considered as later items.
8793 (Enclosing_Package): new function to return the enclosing package
8794 (Enter_Name): correct the rule for homonyms in SPARK
8795 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
8796 from source (result of expansion) to avoid issuing wrong warnings.
8797
8798 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8799
8800 * errout.adb: On anything but an expression First_Node returns its
8801 argument.
8802
8803 2011-08-02 Pascal Obry <obry@adacore.com>
8804
8805 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
8806
8807 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
8808
8809 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
8810 Set the associated loop as the related expression of internally
8811 generated cursors.
8812 * exp_ch7.adb (Is_Container_Cursor): New routine.
8813 (Wrap_Transient_Declaration): Supress the finalization of the list
8814 controller when the declaration denotes a container cursor.
8815
8816 2011-08-02 Yannick Moy <moy@adacore.com>
8817
8818 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
8819 command line now.
8820 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
8821 expression is a simple expression. This check cannot be performed in
8822 the semantics, so just drop it.
8823 (P_Index_Or_Discriminant_Constraint): move check that the index or
8824 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
8825 semantics. Other cases were previously checked in the semantics.
8826 * par-ch4.adb (P_Name): move checks that a selector name is not
8827 character literal or an operator symbol to Find_Selected_Component in
8828 the semantics
8829 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
8830 declarations are not placed after later declarations in a separate
8831 procedure in Sem_Util (possibly not the best choice?), to be used both
8832 during parsing, for Ada 83 mode, and during semantic analysis, for
8833 SPARK mode.
8834 * par-endh.adb (Check_End): move check that end label is not missing
8835 to Process_End_Label in the semantics
8836 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
8837 the special case for SPARK restriction
8838 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
8839 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
8840 parameter Force to issue the error message even on internal node (used
8841 for generated end label). Call Check_Restriction to check when an error
8842 must be issued. In SPARK mode, issue an error message even if the
8843 restriction is not set.
8844 (Check_Restriction): new procedure with an additional out parameter to
8845 inform the caller that a message has been issued
8846 * sem_aggr.adb: Minor modification of message
8847 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
8848 instead of issuing an error message directly
8849 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
8850 declarations are not placed after later declarations, by calling
8851 Check_Later_Vs_Basic_Declarations
8852 (Analyze_Subtype_Declaration): move here the check that an index or
8853 discriminant constraint must be a subtype mark. Change the check that
8854 a subtype of String must start at one so that it works on subtype marks.
8855 * sem_ch4.adb (Analyze_Call): move here the check that a named
8856 association cannot follow a positional one in a call
8857 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
8858 instead of issuing an error message directly
8859 * sem_ch8.adb (Find_Selected_Component): move here the check that a
8860 selector name is not a character literal or an operator symbol. Move
8861 here the check that the prefix of an expanded name cannot be a
8862 subprogram or a loop statement.
8863 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
8864 procedure called from parsing and semantics to check that basic
8865 declarations are not placed after later declarations
8866 (Process_End_Label): move here the check that end label is not missing
8867
8868 2011-08-02 Arnaud Charlet <charlet@adacore.com>
8869
8870 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
8871 representation clause in codepeer mode, since it confuses CodePeer and
8872 does not bring useful info.
8873
8874 2011-08-02 Ed Falis <falis@adacore.com>
8875
8876 * init.c: initialize fp hw on MILS.
8877
8878 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8879
8880 * errout.adb (First_Node): for bodies, return the node itself (small
8881 optimization). For other nodes, do not check source_unit if the node
8882 comes from Standard.
8883
8884 2011-08-02 Robert Dewar <dewar@adacore.com>
8885
8886 * exp_ch3.adb: Minor comment additions.
8887 * sem_ch13.adb: Minor reformatting.
8888
8889 2011-08-02 Pascal Obry <obry@adacore.com>
8890
8891 * make.adb, makeutl.adb: Removes some superfluous directory separator.
8892
8893 2011-08-02 Robert Dewar <dewar@adacore.com>
8894
8895 * sem_attr.adb: Minor reformatting.
8896
8897 2011-08-02 Robert Dewar <dewar@adacore.com>
8898
8899 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
8900 (Has_Default_Component_Value): Removed
8901 * einfo.ads Comment updates
8902 (Has_Default_Aspect): Replaces Has_Default_Value
8903 (Has_Default_Component_Value): Removed
8904 * exp_ch13.adb
8905 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
8906 * exp_ch3.adb
8907 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
8908 (Get_Simple_Init_Val): Handle Default_Value aspect
8909 (Needs_Simple_Initialization): Handle Default_Value aspect
8910 * exp_ch3.ads: Needs_Simple_Initialization
8911 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
8912 * par-prag.adb (Pragma_Default[_Component]Value) Removed
8913 * sem_ch13.adb
8914 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
8915 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
8916 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
8917
8918 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8919
8920 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
8921 package containing iteration primitives.
8922 exp_ch5.adb (Expand_Iterator_Loop): ditto.
8923
8924 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8925
8926 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
8927 "of", pre-analyze expression in case it is a function call with
8928 finalization actions that must be placed ahead of the loop.
8929 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
8930 on an Ada2012 iterator, insert them ahead of the rewritten loop.
8931
8932 2011-08-02 Geert Bosch <bosch@adacore.com>
8933
8934 * cstand.adb (Create_Float_Types): Only consider C's long double for
8935 Long_Long_Float, in addition to double.
8936
8937 2011-08-02 Robert Dewar <dewar@adacore.com>
8938
8939 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
8940 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
8941 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
8942 Minor reformatting.
8943
8944 2011-08-02 Ed Schonberg <schonberg@adacore.com>
8945
8946 * sem_attr.adb: handle properly 'Result when it is a prefix of an
8947 indexed component.
8948
8949 2011-08-02 Javier Miranda <miranda@adacore.com>
8950
8951 * einfo.ads, einfo.adb
8952 (Original_Access_Type): Move this attribute to Node26 since there was
8953 an undocumented use of Node21 in E_Access_Subprogram_Type entities
8954 which causes conflicts and breaks the generation of the .NET compiler.
8955 (Interface_Name): Add missing documentation on JGNAT only uses of
8956 this attribute.
8957
8958 2011-08-02 Geert Bosch <bosch@adacore.com>
8959
8960 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
8961 (Find_Back_End_Float_Type): Likewise
8962 (Create_Back_End_Float_Types): Likewise
8963 (Create_Float_Types): Likewise
8964 (Register_Float_Type): Likewise
8965 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
8966 Nlist and split out type selection in new local Find_Base_Type function.
8967 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
8968 Nlist
8969 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
8970
8971 2011-08-02 Robert Dewar <dewar@adacore.com>
8972
8973 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
8974 alpha order).
8975 * opt.ads: Minor comment change.
8976 * sem_ch12.adb: Minor code reorganization.
8977
8978 2011-08-02 Gary Dismukes <dismukes@adacore.com>
8979
8980 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
8981 subtype's list of rep items to the list on the full subtype in the case
8982 where the lists are the same.
8983
8984 2011-08-02 Geert Bosch <bosch@adacore.com>
8985
8986 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
8987 using the one from System.Strings, which also deallocates all strings.
8988
8989 2011-08-02 Geert Bosch <bosch@adacore.com>
8990
8991 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
8992 function.
8993 * gcc-interface/Make-lang.in: Update dependencies.
8994
8995 2011-08-02 Olivier Hainque <hainque@adacore.com>
8996
8997 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
8998 end_locus.
8999
9000 2011-08-02 Javier Miranda <miranda@adacore.com>
9001
9002 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
9003 associated with anonymous access to subprograms.
9004
9005 2011-08-02 Geert Bosch <bosch@adacore.com>
9006
9007 * opt.ads
9008 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
9009 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
9010 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
9011 (Add_Symbol_Definition): Move to switch-c.adb
9012 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
9013 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
9014 (Add_Symbol_Definition): Move to switch-c.adb.
9015 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
9016 * sem_warn.adb
9017 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
9018 Move to warnsw.adb.
9019 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
9020 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
9021 Move to warnsw.adb.
9022 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
9023 (Add_Symbol_Definition): Moved from Prepcomp.
9024 * switch-c.ads: Update copyright notice. Use String_List instead of
9025 Argument_List, removing dependency on System.OS_Lib.
9026
9027 2011-08-02 Yannick Moy <moy@adacore.com>
9028
9029 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
9030 mode on initialization expression which does not respect SPARK
9031 restrictions.
9032 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
9033 if the tree referenced by its argument represents an initialization
9034 expression in SPARK, suitable for initializing an object in an object
9035 declaration.
9036
9037 2011-08-02 Javier Miranda <miranda@adacore.com>
9038
9039 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
9040 internally generated access to subprogram with its associated protected
9041 subprogram type.
9042 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
9043
9044 2011-08-02 Geert Bosch <bosch@adacore.com>
9045
9046 * cstand.adb (Register_Float_Type): Print information about type to
9047 register, if the Debug_Flag_Dot_B is set.
9048 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
9049 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
9050 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
9051 with a requested precision of more than Max_Digits digits and no more
9052 than Max_Base_Digits digits, if a range specification is present and the
9053 Predefined_Float_Types list has a suitable type to derive from.
9054 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
9055 case of type completion with pragma Import
9056 * sem_prag.adb
9057 (Process_Import_Predefined_Type): Processing to complete a type
9058 with pragma Import. Currently supports floating point types only.
9059 (Set_Convention_From_Pragma): Do nothing without underlying type.
9060 (Process_Convention): Guard against absence of underlying type,
9061 which may happen when importing incomplete types.
9062 (Process_Import_Or_Interface): Handle case of importing predefined
9063 types. Tweak error message.
9064
9065 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9066
9067 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
9068 functions to previous change. Reorganize code slightly.
9069
9070 2011-08-02 Geert Bosch <bosch@adacore.com>
9071
9072 * back_end.ads (Register_Type_Proc): New call back procedure type for
9073 allowing the back end to provide information about available types.
9074 (Register_Back_End_Types): New procedure to register back end types.
9075 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
9076 available types.
9077 * cstand.adb (Back_End_Float_Types): New list for floating point types
9078 supported by the back end.
9079 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
9080 (Copy_Float_Type): New procedure to make new copies of predefined types.
9081 (Register_Float_Type): New call back procedure to populate the BEFT list
9082 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
9083 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
9084 (Create_Float_Types): New procedure to create entities for floating
9085 point types predefined in Standard, and put these and any remaining
9086 BEFTs on the Predefined_Float_Types list.
9087 * stand.ads (Predefined_Float_Types): New list for predefined floating
9088 point types that do not have declarations in package Standard.
9089
9090 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9091
9092 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
9093 entity node for the unit containing the parameter.
9094 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
9095 (Add_Inlined_Subprogram): Likewise.
9096 * gcc-interface/Make-lang.in: Update dependencies.
9097
9098 2011-08-02 Thomas Quinot <quinot@adacore.com>
9099
9100 * s-stusta.adb (Print): Make sure Pos is always initialized to a
9101 suitable value.
9102
9103 2011-08-02 Geert Bosch <bosch@adacore.com>
9104
9105 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
9106
9107 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9108
9109 * sem_type.adb (Covers): Move trivial case to the top and reuse the
9110 computed value of Base_Type.
9111
9112 2011-08-02 Yannick Moy <moy@adacore.com>
9113
9114 * restrict.adb (Check_Restriction): issue an error for any use of
9115 class-wide, even if the No_Dispatch restriction is not set.
9116 * sem_aggr.adb: Correct typos in comments and messages in formal mode
9117 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
9118 when completing a private extension, the type named in the private part
9119 is not the same as that named in the visible part.
9120 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
9121 of an inherited primitive operations of a tagged type or type extension
9122 that returns the tagged type.
9123 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
9124 function which returns True for an implicit operation inherited by the
9125 derived type declaration for the argument type.
9126 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
9127 order.
9128
9129 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9130
9131 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
9132 Process_Bounds, to perform analysis with expansion of a range or an
9133 expression that is the iteration scheme for a loop.
9134 (Analyze_Iterator_Specification): If domain of iteration is given by a
9135 function call with a controlled result, as is the case if call returns
9136 a predefined container, ensure that finalization actions are properly
9137 generated.
9138 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
9139
9140 2011-08-02 Javier Miranda <miranda@adacore.com>
9141
9142 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
9143 * gcc-interface/Make-lang.in: Update dependencies.
9144
9145 2011-08-02 Javier Miranda <miranda@adacore.com>
9146
9147 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
9148 determine if the analysis is performed using N or Original_Node (N).
9149 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
9150 functionality of routine Is_Variable avoids code duplication.
9151 * checks.adb (Determine_Range): Handle temporaries generated by
9152 Remove_Side_Effects.
9153
9154 2011-08-02 Javier Miranda <miranda@adacore.com>
9155
9156 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
9157 expansion of the condition. Required since the previous analysis was
9158 done with expansion disabled (see Resolve_Quantified_Expression) and
9159 hence checks were not inserted and record comparisons have not been
9160 expanded.
9161
9162 2011-08-02 Ed Falis <falis@adacore.com>
9163
9164 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
9165 Update header.
9166
9167 2011-08-02 Bob Duff <duff@adacore.com>
9168
9169 * opt.ads: Minor comment fix.
9170
9171 2011-08-02 Bob Duff <duff@adacore.com>
9172
9173 * sem_ch12.adb (Analyze_Package_Instantiation,
9174 Analyze_Subprogram_Instantiation): Turn off style checking while
9175 analyzing an instance. Whatever style checks that apply to the generic
9176 unit should apply, so it makes no sense to apply them in an instance.
9177 This was causing trouble when compiling an instance of a runtime
9178 unit that violates the -gnatyO switch.
9179 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
9180 one of the two case statements, causing spurious errors.
9181
9182 2011-08-02 Robert Dewar <dewar@adacore.com>
9183
9184 * uname.adb: Minor reformatting.
9185 * gnatcmd.adb: Minor reformatting.
9186 * exp_attr.adb: Minor reformatting.
9187
9188 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9189
9190 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
9191 No_Dispatching_Calls, do not look for the Assign primitive, because
9192 predefined primitives are not created in this case.
9193
9194 2011-08-02 Bob Duff <duff@adacore.com>
9195
9196 * stylesw.ads: Minor comment fixes.
9197
9198 2011-08-02 Robert Dewar <dewar@adacore.com>
9199
9200 * freeze.adb (Add_To_Result): New procedure.
9201
9202 2011-08-02 Jose Ruiz <ruiz@adacore.com>
9203
9204 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
9205 time, if the specific run-time routines for handling streams of strings
9206 are not available, use the default mechanism.
9207
9208 2011-08-02 Arnaud Charlet <charlet@adacore.com>
9209
9210 * s-regpat.ads: Fix typo.
9211
9212 2011-08-02 Vincent Celier <celier@adacore.com>
9213
9214 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
9215 not null, call it to create the in memory config project file without
9216 parsing an existing default config project file.
9217
9218 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9219
9220 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
9221
9222 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9223
9224 * sem_elim.adb: an abstract subprogram does not need an eliminate
9225 pragma for its descendant to be eliminable.
9226
9227 2011-08-02 Ed Falis <falis@adacore.com>
9228
9229 * init.c: revert to handling before previous checkin for VxWorks
9230 * s-intman-vxworks.adb: delete unnecessary declarations related to
9231 using Ada interrupt facilities for handling signals.
9232 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
9233 * s-intman-vxworks.ads: Import __gnat_install_handler as
9234 Initialize_Interrupts.
9235 * s-taprop-vxworks.adb: Delete Signal_Mask.
9236 (Abort_Handler): change construction of mask to unblock exception
9237 signals.
9238
9239 2011-08-02 Jerome Guitton <guitton@adacore.com>
9240
9241 * a-except-2005.adb (Raise_From_Signal_Handler): Call
9242 Debug_Raise_Exception before propagation starts.
9243
9244 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9245
9246 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
9247 to Restriction_Check_Required.
9248 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
9249 * sem_res.adb (Resolve_Call): Likewise.
9250 * sem_attr.adb (Check_Stream_Attribute): Likewise.
9251
9252 2011-08-02 Bob Duff <duff@adacore.com>
9253
9254 * stylesw.ads: Update comment.
9255 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
9256 * errout.ads: Remove obsolete comment.
9257
9258 2011-08-02 Javier Miranda <miranda@adacore.com>
9259
9260 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
9261 (Set_Is_Safe_To_Reevaluate): new procedure.
9262 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
9263 assignment is allowed on safe-to-reevaluate variables.
9264 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
9265 temporary created to remove side effects in expressions that use
9266 the secondary stack as safe-to-reevaluate.
9267 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
9268 variables that are not true constants.
9269
9270 2011-08-02 Robert Dewar <dewar@adacore.com>
9271
9272 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
9273 sem_res.adb, sem_ch6.adb: Minor reformatting.
9274
9275 2011-08-02 Jerome Guitton <guitton@adacore.com>
9276
9277 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
9278
9279 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9280
9281 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
9282 not set Overridden_Operation if subprogram is an initialization
9283 procedure.
9284
9285 2011-08-02 Yannick Moy <moy@adacore.com>
9286
9287 * par-ch6.adb: Correct obsolete name in comments
9288 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
9289 which takes two message arguments (existing function takes one), with
9290 second message used for continuation.
9291 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
9292 block statements that originate from a source block statement, not
9293 generated block statements
9294 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
9295 symmetry with procedure case
9296 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
9297 function to issue an error in formal mode if a package specification
9298 contains more than one tagged type or type extension.
9299 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
9300 parameters matching formals of tagged types are objects (or ancestor
9301 type conversions of objects), not general expressions. Issue an error
9302 on view conversions that are not involving ancestor conversion of an
9303 extended type.
9304 (Resolve_Type_Conversion): in formal mode, issue an error on the
9305 operand of an ancestor type conversion which is not an object
9306 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
9307 procedure so that it works also for actuals of function calls
9308 (Is_Actual_Tagged_Parameter): new function which determines if its
9309 argument is an actual parameter of a formal of tagged type in a
9310 subprogram call
9311 (Is_SPARK_Object_Reference): new function which determines if the tree
9312 referenced by its argument represents an object in SPARK
9313
9314 2011-08-02 Robert Dewar <dewar@adacore.com>
9315
9316 * sem_ch3.adb: Minor reformatting
9317 Minor comment addition
9318 Minor error msg text change
9319
9320 2011-08-02 Javier Miranda <miranda@adacore.com>
9321
9322 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
9323 function. Used to be more precise when we generate a variable plus one
9324 assignment to remove side effects in the evaluation of the Bound
9325 expressions.
9326 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
9327 of the bound expression to force its re-analysis and thus expand the
9328 associated transient scope (if required). Code cleanup replacing the
9329 previous code that declared the constant entity by an invocation to
9330 routine Force_Evaluation which centralizes this work in the frontend.
9331
9332 2011-08-02 Robert Dewar <dewar@adacore.com>
9333
9334 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
9335 (Base_Type): Now uses improved Is_Base_Type function
9336 * einfo.ads (Base_Type): Inline this function
9337
9338 2011-08-02 Robert Dewar <dewar@adacore.com>
9339
9340 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
9341 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
9342
9343 2011-08-02 Arnaud Charlet <charlet@adacore.com>
9344
9345 * gcc-interface/Make-lang.in: Update dependencies.
9346 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
9347 targets.
9348
9349 2011-08-02 Yannick Moy <moy@adacore.com>
9350
9351 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
9352 non-simple expression used in delta constraint
9353 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
9354 index constraint which is not a subtype mark
9355 * par.adb: With and use Restrict
9356 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
9357 mode on component type which is not a subtype mark and default
9358 expression on component
9359 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
9360 of string which does not have a lower index bound equal to 1
9361 (Array_Type_Declaration): issue an error in formal mode on index or
9362 component type which is not a subtype mark, and on aliased keyword on
9363 component
9364 (Derived_Type_Declaration): issue an error in formal mode on interface,
9365 limited or abstract type
9366 (Record_Type_Declaration): issue an error in formal mode on interface
9367 (Record_Type_Definition): issue an error in formal mode on tagged types
9368 and type extensions not declared in the specification of a library unit
9369 package; on null non-tagged record; on variant part
9370
9371 2011-08-02 Vincent Celier <celier@adacore.com>
9372
9373 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
9374 not declared for qualified library project when Library_Name is not
9375 declared, but Library_Dir is.
9376
9377 2011-08-02 Robert Dewar <dewar@adacore.com>
9378
9379 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
9380 pragmas (affects aspects [Component_]Default_Value
9381 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
9382 component type for the resolution
9383
9384 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9385
9386 * einfo.adb (Base_Type): Tune implementation for speed.
9387
9388 2011-08-02 Robert Dewar <dewar@adacore.com>
9389
9390 * freeze.adb: Minor reformatting.
9391
9392 2011-08-02 Thomas Quinot <quinot@adacore.com>
9393
9394 * scos.ads: Update comments.
9395
9396 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9397
9398 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
9399 base type, because the parent may be a subtype of a private type whose
9400 convention is established in a private part.
9401
9402 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
9403
9404 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
9405 statement in a block when the expansion of the return expression has
9406 created a finalization chain.
9407 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
9408 with the parent node.
9409 Add N_Extended_Return_Statement to handle the case where a transient
9410 object declaration appears in the Return_Object_Declarations list of
9411 an extended return statement.
9412
9413 2011-08-02 Matthew Gingell <gingell@adacore.com>
9414
9415 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
9416 unused parameter 'name'.
9417
9418 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9419
9420 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
9421 inherited operation, check whether its alias, which is the source
9422 operastion that it renames, has been marked eliminated.
9423
9424 2011-08-02 Javier Miranda <miranda@adacore.com>
9425
9426 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
9427 in-mode parameter whose type is an access type since it can be used to
9428 modify its designated object. Enforce code that handles as safe an
9429 access type that is not access-to-constant but it is the result of a
9430 previous removal of side-effects.
9431 (Remove_Side_Effects): Minor code reorganization of cases which require
9432 no action. Done to incorporate documentation on new cases uncovered
9433 working in this ticket: no action needed if this routine was invoked
9434 too early and the nodes are not yet decorated.
9435 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
9436 to routine Remove_Side_Effects by calls to Force_Evaluation since they
9437 were issued with actuals that are implicitly provided by
9438 Force_Evaluation.
9439
9440 2011-08-02 Robert Dewar <dewar@adacore.com>
9441
9442 * sem_ch3.adb, sem_res.adb: Minor reformatting.
9443
9444 2011-08-02 Yannick Moy <moy@adacore.com>
9445
9446 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
9447 to issue an error in formal mode on attribute not supported in this mode
9448 (Analyze_Attribute): issue errors on standard attributes not supported
9449 in formal mode.
9450 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
9451 comment, and issue error in formal mode on modulus which is not a power
9452 of 2.
9453 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
9454 range.
9455 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
9456 subtype mark.
9457 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
9458 operator on modular type (except 'not').
9459
9460 2011-08-02 Robert Dewar <dewar@adacore.com>
9461
9462 * gnat_rm.texi: Minor reformatting.
9463
9464 2011-08-02 Arnaud Charlet <charlet@adacore.com>
9465
9466 * s-osinte-linux.ads: Minor comment update and reformatting.
9467 * i-cexten.ads: Make this unit pure, as for its parent.
9468 Will allow its usage in more contexts if needed.
9469
9470 2011-08-02 Robert Dewar <dewar@adacore.com>
9471
9472 * s-utf_32.ads: Minor comment fix.
9473
9474 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9475
9476 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
9477 operation of a tagged synchronized type, handle the case where the
9478 controlling argument is overloaded.
9479
9480 2011-08-02 Yannick Moy <moy@adacore.com>
9481
9482 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
9483 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
9484 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
9485 SPARK mode and formal verification mode on processing SPARK restriction
9486 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
9487 requiring consistency checking.
9488
9489 2011-08-02 Robert Dewar <dewar@adacore.com>
9490
9491 * sem_res.adb: Minor reformatting.
9492
9493 2011-08-02 Robert Dewar <dewar@adacore.com>
9494
9495 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
9496 a-cforse.ads: Remove unneeded with of Ada.Containers
9497 Remove commented out pragma Inline's
9498 Move specifications of new subprograms to the actual specs
9499
9500 2011-08-02 Yannick Moy <moy@adacore.com>
9501
9502 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
9503 a-cforse.ads: Update comments.
9504
9505 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9506
9507 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
9508
9509 2011-08-02 Robert Dewar <dewar@adacore.com>
9510
9511 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
9512 a-cforse.ads, a-cofove.ads: Minor reformatting.
9513
9514 2011-08-02 Claire Dross <dross@adacore.com>
9515
9516 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
9517 a-cofove.ads: Add comments.
9518
9519 2011-08-02 Yannick Moy <moy@adacore.com>
9520
9521 * gnat_rm.texi: Document formal containers.
9522
9523 2011-08-02 Emmanuel Briot <briot@adacore.com>
9524
9525 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
9526 are empty sections.
9527
9528 2011-08-02 Robert Dewar <dewar@adacore.com>
9529
9530 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
9531 reformatting.
9532
9533 2011-08-02 Robert Dewar <dewar@adacore.com>
9534
9535 * aspects.adb: New aspects Default_Value and Default_Component_Value
9536 New format of Aspect_Names table checks for omitted entries
9537 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
9538 handling of boolean aspects for derived types.
9539 New aspects Default_Value and Default_Component_Value
9540 New format of Aspect_Names table checks for omitted entries
9541 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
9542 (Has_Default_Value): New flag
9543 (Has_Default_Component_Value): New flag
9544 (Has_Default_Value): New flag
9545 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
9546 table.
9547 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
9548 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
9549 Default_Value and Default_Component_Value
9550 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
9551 New aspects Default_Value and Default_Component_Value
9552 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
9553 * sprint.adb: Print N_Aspect_Specification node when called from gdb
9554
9555 2011-08-02 Vincent Celier <celier@adacore.com>
9556
9557 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
9558 inherit library kind.
9559
9560 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9561
9562 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
9563 Minor reformatting.
9564
9565 2011-08-02 Robert Dewar <dewar@adacore.com>
9566
9567 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
9568
9569 2011-08-02 Yannick Moy <moy@adacore.com>
9570
9571 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
9572
9573 2011-08-02 Robert Dewar <dewar@adacore.com>
9574
9575 * impunit.adb: Add comment.
9576
9577 2011-08-02 Yannick Moy <moy@adacore.com>
9578
9579 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
9580 qualification of aggregates in formal mode
9581 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
9582 another aggregate
9583 (Resolve_Aggregate): complete the test that an aggregate is adequately
9584 qualified in formal mode
9585
9586 2011-08-02 Pascal Obry <obry@adacore.com>
9587
9588 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
9589 * mlib-prj.adb: Supress warning when compiling binder generated file.
9590 (Build_Library): Supress all warnings when compiling the binder
9591 generated file.
9592
9593 2011-08-02 Yannick Moy <moy@adacore.com>
9594
9595 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
9596 from here...
9597 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
9598 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
9599 Add with/use clauses to make Check_Formal_Restriction visible
9600
9601 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9602
9603 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
9604 in-parameters when type of the generic formal is private in the generic
9605 spec and non-private in the body.
9606
9607 2011-08-02 Claire Dross <dross@adacore.com>
9608
9609 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
9610 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
9611 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
9612 * impunit.adb, Makefile.rtl: Take new files into account.
9613
9614 2011-08-02 Robert Dewar <dewar@adacore.com>
9615
9616 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
9617 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
9618
9619 2011-08-02 Yannick Moy <moy@adacore.com>
9620
9621 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
9622 formal mode
9623 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
9624 matching static array bounds, taking into account the special case of
9625 string literals
9626 * sem_ch3.adb: Typo in comment.
9627
9628 2011-08-02 Yannick Moy <moy@adacore.com>
9629
9630 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
9631 which issues an error in formal mode if its argument node is originally
9632 from source
9633 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
9634 has a discriminant specification so that it does not include the case
9635 of derived types
9636 (Derived_Type_Declaration): move here the test that a derived type has a
9637 discriminant specification
9638 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
9639 first element of a component association before accessing its choices
9640 (presence of component association is not enough)
9641 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
9642 declaration is a library item before accessing the next element in a
9643 list, as library items are not member of lists
9644 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
9645 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
9646 Check_Formal_Restriction whenever possible.
9647
9648 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9649
9650 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
9651 reference when needed.
9652
9653 2011-08-02 Bob Duff <duff@adacore.com>
9654
9655 * gnat_ugn.texi: Fix typo.
9656
9657 2011-08-02 Vincent Celier <celier@adacore.com>
9658
9659 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
9660 archive file name. Do not use the full path name of archives for Open
9661 VMS.
9662
9663 2011-08-02 Robert Dewar <dewar@adacore.com>
9664
9665 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
9666 Analyze_Aspect_Specifications
9667 * sem_ch13.adb
9668 (Analyze_Aspect_Specifications): New handling for boolean aspects
9669 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
9670 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
9671 sequence for Analyze_Aspect_Specifications
9672 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
9673 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
9674
9675 2011-08-02 Robert Dewar <dewar@adacore.com>
9676
9677 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
9678 aspects, since these no longer exist.
9679
9680 2011-08-02 Robert Dewar <dewar@adacore.com>
9681
9682 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
9683 semicolon, do not try to see if there are aspects following it.
9684 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
9685 aspect spec.
9686
9687 2011-08-02 Robert Dewar <dewar@adacore.com>
9688
9689 * sem_ch8.adb, aspects.ads: Minor reformatting.
9690
9691 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9692
9693 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
9694 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
9695 extracted from...
9696 (Analyze_Aspect_Specifications): ...here. Call above procedure.
9697
9698 2011-08-02 Yannick Moy <moy@adacore.com>
9699
9700 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
9701 mode on subprogram declaration outside of package specification, unless
9702 it is followed by a pragma Import
9703 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
9704 Access_Type_Declaration): issue error in formal mode on access type
9705 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
9706 incomplete type
9707 (Analyze_Object_Declaration): issue error in formal mode on object
9708 declaration which does not respect SPARK restrictions
9709 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
9710 declaration which does not respect SPARK restrictions
9711 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
9712 error in formal mode on digits or delta constraint
9713 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
9714 decimal fixed point type
9715 (Derived_Type_Declaration): issue error in formal mode on derived type
9716 other than type extensions of tagged record types
9717 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
9718 with check on access definition
9719 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
9720 mode on protected definition.
9721 (Analyze_Task_Definition): issue error in formal mode on task definition
9722
9723 2011-08-02 Robert Dewar <dewar@adacore.com>
9724
9725 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
9726
9727 2011-08-02 Javier Miranda <miranda@adacore.com>
9728
9729 * sem_ch6.adb (Can_Override_Operator): New function.
9730 (Verify_Overriding_Indicator): Add missing code to check overriding
9731 indicator in operators. Fixes regression.
9732 (Check_Overriding_Indicator): Minor reformating after replacing the
9733 code that evaluates if the subprogram can override an operator by
9734 invocations to the above new function.
9735 * einfo.adb
9736 (Write_Field26_Name): Add missing code to ensure that, following
9737 the documentation in einfo.ads, this field is not shown as attribute
9738 "Static_Initialization" on non-dispatching functions.
9739
9740 2011-08-02 Jose Ruiz <ruiz@adacore.com>
9741
9742 * sem_res.adb (Resolve_Call): A call to
9743 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
9744 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
9745 i.e., when the second parameter is of type Time_Span.
9746
9747 2011-08-02 Vincent Celier <celier@adacore.com>
9748
9749 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
9750 with an archive instead of -L<library dir> -l<library name>.
9751
9752 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9753
9754 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
9755 mark the base types In_Use in addition to making the operations
9756 use_visible.
9757
9758 2011-08-02 Ed Falis <falis@adacore.com>
9759
9760 * init.c: add and setup __gnat_signal_mask for the exception signals
9761 * s-inmaop-vxworks.adb: new file.
9762 * s-intman-vxworks.adb: remove unnecessary initializations and
9763 simplify remaining
9764 * s-intman-vxworks.ads: remove unnecessary variable
9765 * s-taprop-vxworks.adb: simplify signal initialization
9766
9767 2011-08-02 Robert Dewar <dewar@adacore.com>
9768
9769 * sem_ch8.adb: Minor code reorganization, comment updates.
9770
9771 2011-08-02 Robert Dewar <dewar@adacore.com>
9772
9773 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
9774 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
9775 here from Sem_Res.
9776 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
9777 (Matching_Static_Array_Bounds): Moved here from Sem_Res
9778
9779 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9780
9781 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
9782 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
9783 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
9784 use_type_clauses, to handle more efficiently use_type and use_all_type
9785 constructs.
9786 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
9787 Ada2012 Use_All_Type clause.
9788 (Use_Class_Wide_Operations): new procedure.
9789
9790 2011-08-02 Robert Dewar <dewar@adacore.com>
9791
9792 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
9793 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
9794 expression to expression function.
9795
9796 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9797
9798 * sem_ch4.adb: transform simple Ada2012 membership into equality only
9799 if types are compatible.
9800
9801 2011-08-02 Yannick Moy <moy@adacore.com>
9802
9803 * sem_res.adb (Matching_Static_Array_Bounds): new function which
9804 returns True if its argument array types have same dimension and same
9805 static bounds at each index.
9806 (Resolve_Actuals): issue an error in formal mode on actuals passed as
9807 OUT or IN OUT paramaters which are not view conversions in SPARK.
9808 (Resolve_Arithmetic_Op): issue an error in formal mode on
9809 multiplication or division with operands of fixed point types which are
9810 not qualified or explicitly converted.
9811 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
9812 Boolean or array type (except String) operands.
9813 (Resolve_Equality_Op): issue an error in formal mode on equality
9814 operators for array types other than String with non-matching static
9815 bounds.
9816 (Resolve_Logical_Op): issue an error in formal mode on logical operators
9817 for array types with non-matching static bounds. Factorize the code in
9818 Matching_Static_Array_Bounds.
9819 (Resolve_Qualified_Expression): issue an error in formal mode on
9820 qualified expressions for array types with non-matching static bounds.
9821 (Resolve_Type_Conversion): issue an error in formal mode on type
9822 conversion for array types with non-matching static bounds
9823
9824 2011-08-02 Robert Dewar <dewar@adacore.com>
9825
9826 * par-ch10.adb: Minor code reorganization (use Nkind_In).
9827
9828 2011-08-02 Ed Schonberg <schonberg@adacore.com>
9829
9830 * par-ch9.adb: save location of entry for proper error message.
9831
9832 2011-08-02 Javier Miranda <miranda@adacore.com>
9833
9834 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
9835 (Use_Full_View) which permits this routine to climb through the
9836 ancestors using the full-view of private parents.
9837 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
9838 Use_Full_View to true in calls to Is_Ancestor.
9839 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
9840 true in call to Is_Ancestor.
9841 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
9842 Use_Full_View to true in call to Is_Ancestor.
9843 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
9844 call to Is_Ancestor.
9845 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
9846 Use_Full_View to true in calls to Is_Ancestor.
9847 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
9848 Make_Select_Specific_Data_Table, Register_Primitive,
9849 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
9850 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
9851 to true in call to Is_Ancestor.
9852 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
9853 Use_Full_View to true in calls to Is_Ancestor.
9854 * exp_cg.adb
9855 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
9856 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
9857
9858 2011-08-02 Robert Dewar <dewar@adacore.com>
9859
9860 * gnat_rm.texi: Minor reformatting.
9861 * sem_prag.adb: Minor reformatting.
9862
9863 2011-08-02 Tristan Gingold <gingold@adacore.com>
9864
9865 * vms_data.ads: Add VMS qualifier for -gnateP.
9866
9867 2011-08-02 Robert Dewar <dewar@adacore.com>
9868
9869 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
9870 * par-ch7.adb (P_Package): Proper placement of aspects for package
9871 decl/instantiation.
9872 * par-endh.adb (Check_End): Ad Is_Sloc parameter
9873 (End_Statements): Add Is_Sloc parameterr
9874 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
9875 (Check_End): Ad Is_Sloc parameter
9876 (End_Statements): Add Is_Sloc parameterr
9877
9878 2011-08-02 Vincent Celier <celier@adacore.com>
9879
9880 * ug_words: Add VMS qualifier equivalent to -gnateP:
9881 /SYMBOL_PREPROCESSING.
9882
9883 2011-08-02 Jose Ruiz <ruiz@adacore.com>
9884
9885 * gnat-style.texi: For hexadecimal numeric literals the typical
9886 grouping of digits is 4 to represent 2 bytes.
9887 A procedure spec which is split into several lines is indented two
9888 characters.
9889
9890 2011-08-02 Yannick Moy <moy@adacore.com>
9891
9892 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
9893 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
9894 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
9895 properly qualified
9896 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
9897 choice in array aggregate
9898 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
9899 mark as ancestor
9900 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
9901 positional and named aggregate for record, or others in record
9902 aggregate, or multiple choice in record aggregate
9903 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
9904 array operands to logical operations AND, OR and XOR do not have the
9905 same static lower and higher bounds
9906 * sem_ch5.adb, sinfo.ads: Correct typos in comments
9907
9908 2011-08-01 Robert Dewar <dewar@adacore.com>
9909
9910 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
9911 Replaces Last_Source_Node_In_Sequence.
9912 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
9913 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
9914 parens and blank in string (this was inconsistently implemented).
9915 * errout.ads
9916 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
9917 blank in string (this was inconsistently implemented).
9918 * gnat1drv.adb
9919 (Set_Global_Switches): Set formal mode switches appropriately
9920 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
9921 * par-prag.adb
9922 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
9923 call Set_Error_Msg_Lang to set "spark" as language name.
9924 * par.adb: Remove unnecessary call to set formal language for errout
9925 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
9926 appropriately and call Set_Error_Msg_Lang to set "spark" as language
9927 name.
9928 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
9929 calls to it, moved after resolution so that types are known
9930 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
9931 result of concatenation is not of type String
9932 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
9933 concatenation is not properly restricted
9934 * gnat_rm.texi: Add doc on pragma Spark_95.
9935 * gcc-interface/Makefile.in: Remove obsolete target pairs for
9936 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
9937 * gcc-interface/Make-lang.in: Update dependencies.
9938
9939 2011-08-01 Javier Miranda <miranda@adacore.com>
9940
9941 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
9942 condition that detects if the overridden operation must replace an
9943 existing entity.
9944
9945 2011-08-01 Javier Miranda <miranda@adacore.com>
9946
9947 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
9948 code declarations inserted by Insert_Actions in each alternative of the
9949 N_Case_Expression node.
9950
9951 2011-08-01 Robert Dewar <dewar@adacore.com>
9952
9953 * sem_ch6.adb: Minor code reorganization.
9954 * sem_util.adb: Minor reformatting.
9955
9956 2011-08-01 Pascal Obry <obry@adacore.com>
9957
9958 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
9959 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
9960
9961 2011-08-01 Yannick Moy <moy@adacore.com>
9962
9963 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
9964 literal or operator symbol which is prefixed
9965 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
9966 mode on access attributes.
9967 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
9968 that concatenation operands are properly restricted in formal mode
9969 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
9970 Analyze_Concatenation_Operand. Issue an error in formal mode if the
9971 result of the concatenation has a type different from String.
9972 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
9973 Analyze_Quantified_Expression, Analyze_Slice,
9974 Analyze_Null): issue an error in formal mode on unsupported constructs
9975 * sem_ch5.adb
9976 (Analyze_Block_Statement): only issue error on source block statement
9977 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
9978 function which returns the last node in a list of nodes for which
9979 Comes_From_Source returns True, if any
9980 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
9981 Last_Source_Node_In_Sequence
9982 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
9983 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
9984 mode on unsupported constructs
9985 * sem_ch9.adb Do not return after issuing error in formal mode, as the
9986 rest of the actions may be needed later on since the error is marked as
9987 not serious.
9988 * sinfo.ads: Typos in comments.
9989
9990 2011-08-01 Pascal Obry <obry@adacore.com>
9991
9992 * projects.texi: Minor editing.
9993
9994 2011-08-01 Yannick Moy <moy@adacore.com>
9995
9996 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
9997 insertion character ~~
9998 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
9999 (Set_Error_Msg_Lang): new procedure which fixes the language for use
10000 with insertion character ~~
10001 (Set_Msg_Text): treat insertion character ~~
10002 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
10003 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
10004 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
10005 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
10006 errors related to the formal language restriction not serious
10007 (insertion character |).
10008 * par.adb (Par): set formal language for error messages if needed
10009 * sem_ch6.adb (Check_Missing_Return): take into account possible
10010 generated statements at the end of the function
10011 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
10012 enumeration value to define a new pragma SPARK_95
10013 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
10014 SPARK_Version): new type and variables to store the SPARK version
10015 (none by default).
10016 (SPARK_Mode): return True when SPARK_Version is set
10017 * par-prag.adb: Correct indentation
10018 (Prag): take Pragma_SPARK_95 into account
10019 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
10020 into account.
10021
10022 2011-08-01 Robert Dewar <dewar@adacore.com>
10023
10024 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
10025 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
10026 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
10027
10028 2011-08-01 Pascal Obry <obry@adacore.com>
10029
10030 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
10031 Target_Name to Get_Path call.
10032 (Parse_Single_Project): Likewise.
10033 (Post_Parse_Context_Clause): Likewise.
10034 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
10035 Call Initialise_Project_Path with the proper Target_Name.
10036 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
10037 search path.
10038 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
10039 with the proper Target_Name.
10040 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
10041 Part.Parse routine.
10042 (Parse_Project_And_Apply_Config): Likewise.
10043 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
10044 This is fine as this part of the code is supporting only native
10045 compilation.
10046 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
10047 is fine as this part of the code is supporting only native compilation.
10048
10049 2011-08-01 Yannick Moy <moy@adacore.com>
10050
10051 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
10052 of homonym, unless the homonym is one of the cases allowed in SPARK
10053 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
10054 package declaration occurring after a body.
10055
10056 2011-08-01 Robert Dewar <dewar@adacore.com>
10057
10058 * checks.adb, exp_ch4.adb: Minor reformatting.
10059
10060 2011-08-01 Javier Miranda <miranda@adacore.com>
10061
10062 * einfo.ads (Access_Disp_Table): Fix documentation.
10063 (Dispatch_Table_Wrappers): Fix documentation.
10064
10065 2011-08-01 Pascal Obry <obry@adacore.com>
10066
10067 * prj-env.adb, prj-env.ads: Minor reformatting.
10068
10069 2011-08-01 Yannick Moy <moy@adacore.com>
10070
10071 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
10072 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
10073 procedures out of these packages.
10074 * errout.ads, errout.adb
10075 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
10076 procedures in of this package
10077 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
10078 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
10079 on misplaced later vs initial declarations, like in Ada 83
10080 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
10081 formal mode on attribute of private type whose full type declaration
10082 is not visible
10083 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
10084 package declaration inside a package specification
10085 (Analyze_Full_Type_Declaration): issue error in formal mode on
10086 controlled type or discriminant type
10087 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
10088 user-defined operator means that it should come from the source
10089 (New_Overloaded_Entity): issue error in formal mode on overloaded
10090 entity.
10091 * sem_ch6.ads, sem_ch13.ads: typos in comments.
10092
10093 2011-08-01 Thomas Quinot <quinot@adacore.com>
10094
10095 * atree.adb: Minor reformatting.
10096 * checks.adb: Minor reformatting.
10097
10098 2011-08-01 Vincent Celier <celier@adacore.com>
10099
10100 * s-parame-vms-ia64.ads: Fix typo in comment
10101 Minor reformatting
10102 * s-parame-vms-restrict.ads: Removed, unused.
10103
10104 2011-08-01 Javier Miranda <miranda@adacore.com>
10105
10106 * exp_ch3.adb
10107 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
10108 * sem_ch3.adb
10109 (Constrain_Index): Remove side effects in the evaluation of the bounds.
10110 * sem_ch3.ads, sem_ch3.adb
10111 (Is_Constant_Bound): New extended version of the subprogram that was
10112 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
10113 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
10114 * sem_aux.ads (Constant_Value): Fix typo in comment.
10115 * checks.adb (Generate_Index_Checks): New implementation which, for
10116 array objects with constant bounds, generates the runtime check
10117 referencing the bounds of the array type. For other cases this routine
10118 provides its previous behavior obtaining such values from the array
10119 object.
10120 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
10121 parent type.
10122 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
10123 we cannot have semantic interpretations of the new node.
10124
10125 2011-08-01 Ed Schonberg <schonberg@adacore.com>
10126
10127 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
10128 expressions.
10129
10130 2011-08-01 Arnaud Charlet <charlet@adacore.com>
10131
10132 * sem_ch8.adb: Minor code editing.
10133 * s-vxwext.adb: Remove trailing space.
10134 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
10135 consistency with other files.
10136
10137 2011-08-01 Thomas Quinot <quinot@adacore.com>
10138
10139 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
10140
10141 2011-08-01 Ed Schonberg <schonberg@adacore.com>
10142
10143 * par-ch10.adb: reject parameterized expressions as compilation unit.
10144 * sem_ch4.adb: handle properly conditional expression with overloaded
10145 then_clause and no else_clause.
10146
10147 2011-08-01 Tristan Gingold <gingold@adacore.com>
10148
10149 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
10150 like done by System.Aux_DEC.
10151 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
10152
10153 2011-08-01 Yannick Moy <moy@adacore.com>
10154
10155 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
10156 missing label at end of declaration (subprogram or package)
10157 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
10158 of positional and named parameter association
10159 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
10160 Error_Msg_SP which adds a prefix to the error message giving the name
10161 of the formal language analyzed
10162 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
10163 access result type in subprogram, unconstrained array as result type,.
10164 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
10165 procedure
10166 * sem_ch8.adb: Code clean up.
10167
10168 2011-08-01 Javier Miranda <miranda@adacore.com>
10169
10170 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
10171 * einfo.ads (Access_Disp_Table): Fix documentation.
10172 (Dispatch_Table_Wrappers): Fix documentation.
10173 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
10174 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
10175 to enforce the documentation of this attribute.
10176 (Set_Is_Interface): Cleanup the assertion.
10177 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
10178 the Underlying_Type entity before reading attribute Access_Disp_Table.
10179 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
10180 Locate the Underlying_Type before reading attribute Access_Disp_Table.
10181 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
10182 the Underlying_Type entity before reading attribute Access_Disp_Table.
10183 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
10184 Locate the Underlying_Type entity before reading attribute
10185 Access_Disp_Table.
10186
10187 2011-08-01 Ed Schonberg <schonberg@adacore.com>
10188
10189 * s-poosiz.ads: Additional overriding indicators.
10190
10191 2011-08-01 Yannick Moy <moy@adacore.com>
10192
10193 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
10194 formal mode.
10195 (Analyze_Iteration_Scheme): issue error in formal mode when loop
10196 parameter specification does not include a subtype mark.
10197 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
10198 formal mode on abstract subprogram.
10199 (Analyze_Subprogram_Specification): issue error in formal mode on
10200 user-defined operator.
10201 (Process_Formals): issue error in formal mode on access parameter and
10202 default expression.
10203 * sem_ch9.adb (Analyze_Abort_Statement,
10204 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
10205 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
10206 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
10207 Analyze_Requeue, Analyze_Selective_Accept,
10208 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
10209 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
10210 issue error in formal mode on user-defined raise statement.
10211
10212 2011-08-01 Thomas Quinot <quinot@adacore.com>
10213
10214 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
10215 declaration being hidden when overriding an implicit inherited
10216 subprogram.
10217 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
10218 (-gnats), do not complain about a source file that contains only a
10219 pragma No_Body.
10220
10221 2011-08-01 Ed Schonberg <schonberg@adacore.com>
10222
10223 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
10224 variable if already set.
10225
10226 2011-08-01 Arnaud Charlet <charlet@adacore.com>
10227
10228 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
10229 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
10230 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
10231 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
10232 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
10233 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
10234 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
10235 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
10236 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
10237 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
10238 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
10239 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
10240 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
10241 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
10242 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
10243 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
10244 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
10245 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
10246 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
10247 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
10248 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
10249 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
10250 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
10251 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
10252 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
10253 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
10254 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
10255 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
10256 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
10257 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
10258 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
10259 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
10260 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
10261 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
10262 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
10263 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
10264 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
10265 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
10266 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
10267 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
10268 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
10269 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
10270 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
10271 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
10272 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
10273 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
10274 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
10275 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
10276 s-osinte-mingw.ads: Update to GPLv3 run-time license.
10277 Use GNAT instead of GNARL.
10278
10279 2011-08-01 Bob Duff <duff@adacore.com>
10280
10281 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
10282 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
10283 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
10284 reformatting.
10285
10286 2011-08-01 Yannick Moy <moy@adacore.com>
10287
10288 * debug.adb (d.D) reverve flag for the SPARK mode
10289 (d.E) reverve flag for SPARK generation mode
10290 (d.F) reverve flag for Why generation mode
10291 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
10292 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
10293 functions which return True when the corresponding modes are set
10294 (Formal_Language): return "spark" or "alfa" when in formal verification
10295 mode.
10296 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
10297 Error_Msg to prefix the error message with a tag giving the formal
10298 language
10299 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
10300 message with a tag giving the formal language
10301 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
10302 block statement
10303 (Analyze_Case_Statement): issue error in formal mode on case statement
10304 with a single "others" case alternative
10305 (Analyze_Exit_Statement): issue errors in formal mode on exit
10306 statements which do not respect SPARK restrictions
10307 (Analyze_Goto_Statement): issue error in formal mode on goto statement
10308 (Check_Unreachable_Code): always issue an error (not a warning) in
10309 formal mode on unreachable code (concerns both code after an infinite
10310 loop and after an unconditional jump, both not allowed in SPARK)
10311 * sem_ch6.adb (Analyze_Return_Statement): add call to
10312 Set_Return_Present for a procedure containing a return statement
10313 (already done for functions in Analyze_Function_Return)
10314 (Analyze_Function_Return): issue error in formal mode on extended
10315 return or if return is not last statement in function
10316 (Check_Missing_Return): issue error in formal mode if function does
10317 not end with return or if procedure contains a return
10318 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
10319 function to detect if there is an inner scope of its parameter S which
10320 is a loop.
10321
10322 2011-08-01 Thomas Quinot <quinot@adacore.com>
10323
10324 * sem_ch6.ads: Minor reformatting.
10325
10326 2011-08-01 Javier Miranda <miranda@adacore.com>
10327
10328 * sem_util.adb (Abstract_Interface_List): Complete condition when
10329 processing private type declarations to avoid reading unavailable
10330 attribute.
10331 (Is_Synchronized_Tagged_Type): Complete condition when processing
10332 private extension declaration nodes to avoid reading unavailable
10333 attribute.
10334
10335 2011-08-01 Thomas Quinot <quinot@adacore.com>
10336
10337 * sem_ch3.adb: Minor reformatting.
10338
10339 2011-08-01 Thomas Quinot <quinot@adacore.com>
10340
10341 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
10342 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
10343 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
10344 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
10345 for VMS, instead parametrize the common implementation with
10346 System.Parameters declarations.
10347
10348 2011-08-01 Eric Botcazou <ebotcazou@adacore.com>
10349
10350 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
10351
10352 2011-08-01 Tristan Gingold <gingold@adacore.com>
10353
10354 * seh_init.c: Fix SEH handler installation on win64.
10355
10356 2011-08-01 Ed Schonberg <schonberg@adacore.com>
10357
10358 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
10359 double analysis of an anonymous access to subprogram, because it can
10360 lead to improper sharing of profiles and a back-end crash.
10361
10362 2011-08-01 Robert Dewar <dewar@adacore.com>
10363
10364 * make.adb, sem_ch4.adb: Minor reformatting.
10365 * gcc-interface/Make-lang.in: Update dependencies.
10366 * sem_util.adb, exp_ch5.adb: Minor reformatting.
10367
10368 2011-08-01 Arnaud Charlet <charlet@adacore.com>
10369
10370 * gnat_rm.texi: Fix definition of Long_Integer.
10371
10372 2011-08-01 Ed Schonberg <schonberg@adacore.com>
10373
10374 * exp_aggr.adb: check limit size of static aggregate unconditionally,
10375 to prevent storage exhaustion.
10376 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
10377 finalized is a function body, insert the cleanup code before the final
10378 return statement, to prevent spurious warnings.
10379 * s-pooglo.ads: add overriding indicator.
10380
10381 2011-08-01 Ed Schonberg <schonberg@adacore.com>
10382
10383 * sem_ch4.adb (Operator_Check): improve error message when both a
10384 with_clause and a use_clause are needed to make operator usage legal.
10385 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
10386 determine whether a compilation unit is visible within an other,
10387 either through a with_clause in the current unit, or a with_clause in
10388 its library unit or one one of its parents.
10389
10390 2011-08-01 Ed Schonberg <schonberg@adacore.com>
10391
10392 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
10393 over an arbitrary expression of an array or container type.
10394 * lib-xref.adb: clarify comment.
10395
10396 2011-08-01 Bob Duff <duff@adacore.com>
10397
10398 * einfo.ads: Minor reformatting.
10399 * debug.adb: Minor comment improvement.
10400
10401 2011-08-01 Javier Miranda <miranda@adacore.com>
10402
10403 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
10404 consider hidden subprograms as valid candidates.
10405
10406 2011-08-01 Arnaud Charlet <charlet@adacore.com>
10407
10408 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
10409
10410 2011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
10411
10412 * gnat_ugn.texi: Fix typo.
10413
10414 2011-08-01 Robert Dewar <dewar@adacore.com>
10415
10416 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
10417 lib-xref.adb: Minor reformatting
10418
10419 2011-08-01 Gary Dismukes <dismukes@adacore.com>
10420
10421 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
10422 when to generate a call to Move_Final_List.
10423 (Has_Controlled_Parts): Remove this function.
10424
10425 2011-08-01 Geert Bosch <bosch@adacore.com>
10426
10427 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
10428 "," in choice list.
10429
10430 2011-08-01 Thomas Quinot <quinot@adacore.com>
10431
10432 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
10433 explicit raise of a predefined exception as Comes_From_Source if the
10434 original N_Raise_Statement comes from source.
10435
10436 2011-08-01 Robert Dewar <dewar@adacore.com>
10437
10438 * sinfo.ads: Add comment.
10439 * sem_ch6.adb: Minor reformatting.
10440
10441 2011-08-01 Robert Dewar <dewar@adacore.com>
10442
10443 * freeze.adb (Freeze_Entity): Refine check for bad component size
10444 clause to avoid rejecting confirming clause when atomic/aliased present.
10445
10446 2011-08-01 Ed Schonberg <schonberg@adacore.com>
10447
10448 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
10449 better determine whether an entity reference is a write.
10450 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
10451 subcomponent.
10452 * lib-xref.adb (Output_References): Do no suppress a read reference at
10453 the same location as an immediately preceeding modify-reference, to
10454 handle properly in-out actuals.
10455
10456 2011-08-01 Tristan Gingold <gingold@adacore.com>
10457
10458 * env.c (__gnat_setenv) [VMS]: Refine previous change.
10459
10460 2011-08-01 Quentin Ochem <ochem@adacore.com>
10461
10462 * i-cstrin.adb (New_String): Changed implementation, now uses only the
10463 heap to compute the result.
10464
10465 2011-08-01 Robert Dewar <dewar@adacore.com>
10466
10467 * atree.ads: Minor reformatting.
10468
10469 2011-08-01 Emmanuel Briot <briot@adacore.com>
10470
10471 * g-expect.adb (Get_Command_Output): Fix memory leak.
10472
10473 2011-08-01 Geert Bosch <bosch@adacore.com>
10474
10475 * cstand.adb (P_Float_Type): New procedure to print the definition of
10476 predefined fpt types.
10477 (P_Mixed_Name): New procedure to print a name using mixed case
10478 (Print_Standard): Use P_Float_Type for printing floating point types
10479 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
10480 precision IEEE float.
10481
10482 2011-08-01 Thomas Quinot <quinot@adacore.com>
10483
10484 * sem_ch3.adb: Minor reformatting.
10485
10486 2011-08-01 Ed Schonberg <schonberg@adacore.com>
10487
10488 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
10489 the completion of a generic function, insert the new body rather than
10490 rewriting the original.
10491
10492 2011-08-01 Yannick Moy <moy@adacore.com>
10493
10494 * sinfo.ads, errout.ads: Typos in comments.
10495
10496 2011-08-01 Robert Dewar <dewar@adacore.com>
10497
10498 * par-endh.adb: Minor reformatting.
10499
10500 2011-08-01 Robert Dewar <dewar@adacore.com>
10501
10502 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
10503 (Pre_Post_Aspects): New subtype.
10504 * par-ch12.adb (P_Generic): New syntax for aspects in packages
10505 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
10506 * par-ch7.adb (P_Package): Remove Decl parameter
10507 (P_Package): Handle new syntax for aspects (before IS)
10508 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
10509 new aspect syntax
10510 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
10511 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
10512 (P_Package): Remove Decl parameter
10513 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
10514 aspects
10515 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
10516 specs
10517 * sem_util.ads, sem_util.adb (Static_Boolean): New function
10518 * sinfo.ads: Document new syntax for aspects in packages etc.
10519 * sprint.adb: Handle new syntax of aspects before IS in package
10520
10521 2011-08-01 Thomas Quinot <quinot@adacore.com>
10522
10523 * atree.ads: Minor reformatting.
10524 * sem_prag.adb: Minor reformatting.
10525
10526 2011-08-01 Robert Dewar <dewar@adacore.com>
10527
10528 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
10529 case expr alternative.
10530
10531 2011-08-01 Ed Schonberg <schonberg@adacore.com>
10532
10533 * sem_ch12.adb: Fix typo.
10534
10535 2011-08-01 Geert Bosch <bosch@adacore.com>
10536
10537 * sem_prag.adb (Check_No_Link_Name): New procedure.
10538 (Process_Import_Or_Interface): Use Check_No_Link_Name.
10539 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
10540 instead of Standard_Long_Long_Float_Size global. Preparation for
10541 eventual removal of per type constants.
10542 * exp_util.ads (Get_Stream_Size): New function returning the stream
10543 size value of subtype E.
10544 * exp_util.adb (Get_Stream_Size): Implement new function.
10545 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
10546 function.
10547 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
10548 * einfo.adb:
10549 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
10550
10551 2011-08-01 Geert Bosch <bosch@adacore.com>
10552
10553 * cstand.adb: Fix comments.
10554 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
10555 count of arguments.
10556
10557 2011-08-01 Robert Dewar <dewar@adacore.com>
10558
10559 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
10560
10561 2011-08-01 Geert Bosch <bosch@adacore.com>
10562
10563 * atree.ads: Fix comment.
10564
10565 2011-08-01 Robert Dewar <dewar@adacore.com>
10566
10567 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
10568 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
10569 * par.adb: Add with for Namet.Sp.
10570 * par-tchk.adb: Minor reformatting.
10571
10572 2011-08-01 Vincent Celier <celier@adacore.com>
10573
10574 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
10575 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
10576 of the init procedure of a SAL.
10577 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
10578 New procedure.
10579
10580 2011-08-01 Thomas Quinot <quinot@adacore.com>
10581
10582 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
10583 reformatting.
10584
10585 2011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
10586
10587 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
10588
10589 2011-08-01 Thomas Quinot <quinot@adacore.com>
10590
10591 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
10592 conformant with its spec (return True only for types that have
10593 an overriding Initialize primitive operation that prevents them from
10594 having preelaborable initialization).
10595 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
10596 initialization for controlled types in Ada 2005 or later mode.
10597
10598 2011-08-01 Robert Dewar <dewar@adacore.com>
10599
10600 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
10601 Postcondition.
10602 (Same_Aspect): New function.
10603 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
10604 Type_Invariant, Precondition, Postcondition.
10605 * snames.ads-tmpl: Add Name_Type_Invariant.
10606
10607 2011-08-01 Robert Dewar <dewar@adacore.com>
10608
10609 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
10610 here.
10611 (Freeze_All_Ent): Fix error in handling inherited aspects.
10612 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
10613 already analyzed, but don't skip entire processing of a declaration,
10614 that's wrong in some cases of declarations being rewritten.
10615 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
10616 Don't delay for integer, string literals
10617 Treat predicates in usual manner for delay, remove special case code,
10618 not needed.
10619 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
10620 (Build_Predicate_Function): Update saved expression in aspect
10621 (Build_Invariant_Procedure): Update saved expression in aspect
10622 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
10623 of replacement of discriminant references if the reference is simple.
10624
10625 2011-08-01 Robert Dewar <dewar@adacore.com>
10626
10627 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
10628 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
10629 Static_Predicate and Dynamic_Predicate.
10630 (Build_Predicate_Function): Add processing for Static_Predicate
10631 and Dynamic_Predicate.
10632 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
10633 (From_Static_Predicate): New flag
10634 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
10635
10636 2011-08-01 Robert Dewar <dewar@adacore.com>
10637
10638 * usage.adb: Documentation cleanup for Ada version modes in usage.
10639 * expander.adb: Minor reformatting.
10640
10641 2011-08-01 Robert Dewar <dewar@adacore.com>
10642
10643 * atree.ads: Minor comment fix.
10644 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
10645 a-witeio.ads, sem_prag.adb: Minor reformatting.
10646
10647 2011-08-01 Doug Rupp <rupp@adacore.com>
10648
10649 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
10650 pointers. Use descrip.h header file for convenience. Add some
10651 comments.
10652
10653 2011-08-01 Robert Dewar <dewar@adacore.com>
10654
10655 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
10656 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
10657 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
10658 New procedure.
10659 (Check_Aspect_At_End_Of_Declarations): New procedure
10660 (Analye_Aspect_Specification): Minor changes for above procedures
10661 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
10662 specification node as well.
10663
10664 2011-08-01 Pascal Obry <obry@adacore.com>
10665
10666 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
10667 Windows files. Use GetFilesAttributes() in this case to check for file
10668 existence instead of returning with an error code.
10669
10670 2011-08-01 Vincent Celier <celier@adacore.com>
10671
10672 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
10673 High is above Source length.
10674
10675 2011-08-01 Robert Dewar <dewar@adacore.com>
10676
10677 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
10678
10679 2011-08-01 Robert Dewar <dewar@adacore.com>
10680
10681 * aspects.ads (Boolean_Aspects): New subtype.
10682 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
10683 for derived types in cases where the parent type and derived type have
10684 aspects.
10685 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
10686 with aspects when parent type also has aspects.
10687 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
10688 boolean expression at this point).
10689 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
10690 accordance with final decision on the Ada 2012 feature.
10691 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
10692
10693 2011-08-01 Matthew Heaney <heaney@adacore.com>
10694
10695 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
10696
10697 2011-08-01 Pascal Obry <obry@adacore.com>
10698
10699 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
10700 Fix Replace_Slice when High is above current string size.
10701 (Replace_Slice): Fix DL computation when High is above current
10702 string length.
10703
10704 2011-08-01 Gary Dismukes <dismukes@adacore.com>
10705
10706 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
10707
10708 2011-08-01 Matthew Heaney <heaney@adacore.com>
10709
10710 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
10711 of node.
10712
10713 2011-08-01 Pascal Obry <obry@adacore.com>
10714
10715 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
10716 reformatting.
10717
10718 2011-08-01 Ed Schonberg <schonberg@adacore.com>
10719
10720 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
10721 access to protected subprograms in generic bodies.
10722 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
10723 protected type, indicate that the convention of the subprogram is
10724 Convention_Protected, because it may be used in subsequent declarations
10725 within the protected declaration.
10726
10727 2011-08-01 Vincent Celier <celier@adacore.com>
10728
10729 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
10730 and "final" procedures when the name of the library is "ada", to avoid
10731 duplicate symbols "adainit" and "adafinal" in executables.
10732
10733 2011-08-01 Ed Schonberg <schonberg@adacore.com>
10734
10735 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
10736 quantified expression that appears within a postcondition and uses the
10737 Ada2012 'Result attribute.
10738
10739 2011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10740
10741 * init.c (__gnat_error_handler): Cast reason to int.
10742 (__gnat_install_handler): Explain sa_sigaction use.
10743
10744 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
10745
10746 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
10747 subprogram has copy-in copy-out parameters, try to promote the mode of
10748 the return type if it is passed in registers.
10749
10750 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
10751
10752 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
10753 left operand as addressable.
10754
10755 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
10756
10757 * gcc-interface/gigi.h (build_function_stub): Remove.
10758 (build_return_expr): Likewise.
10759 (convert_vms_descriptor): Declare.
10760 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
10761 (build_function_stub): Move to...
10762 * gcc-interface/utils2.c (build_return_expr): Move to...
10763 * gcc-interface/trans.c (build_function_stub): ...here.
10764 (build_return_expr): ...here.
10765 (Subprogram_Body_to_gnu): Add local variable for language_function.
10766 Disconnect the parameter attributes cache, if any, once done with it.
10767 Call end_subprog_body only after setting the end_locus.
10768 Build the stub associated with the function, if any, at the very end.
10769 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
10770 variables and streamline control flow.
10771
10772 2011-07-23 Arnaud Charlet <charlet@adacore.com>
10773
10774 PR ada/49819
10775 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
10776 g-trasym-dwarf.adb.
10777
10778 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10779
10780 PR bootstrap/49794
10781 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
10782 Assign to act.sa_sigaction.
10783 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
10784 current->return_address to char * before arithmetic.
10785
10786 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10787
10788 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
10789 Correct argument types.
10790 Extract code from reason.
10791 (__gnat_install_handler): Assign to act.sa_sigaction.
10792
10793 2011-07-21 Eric Botcazou <ebotcazou@adacore.com>
10794
10795 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
10796 (GNAT1_OBJS): ...here.
10797
10798 2011-07-15 Eric Botcazou <ebotcazou@adacore.com>
10799
10800 PR ada/48711
10801 * g-socthi-mingw.adb (Fill): Fix formatting.
10802
10803 * gcc-interface/gigi.h: Move around comment.
10804
10805 2011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
10806
10807 PR ada/46350
10808 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
10809
10810 2011-07-14 Florian Weimer <fw@deneb.enyo.de>
10811
10812 PR ada/48711
10813 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
10814
10815 2011-07-13 Eric Botcazou <ebotcazou@adacore.com>
10816
10817 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
10818 range comparison if Pmode is SImode.
10819
10820 2011-07-12 Laurent GUERBY <laurent@guerby.net>
10821 Eric Botcazou <ebotcazou@adacore.com>
10822
10823 * adadecode.c: Wrap up in extern "C" block.
10824 * adadecode.h: Likewise.
10825 * adaint.c: Likewise. Remove 'const' keyword.
10826 * adaint.h: Likewise.
10827 * argv.c: Likewise.
10828 * atree.h: Likewise.
10829 * cio.c: Likewise.
10830 * cstreams.c: Likewise.
10831 * env.c: Likewise.
10832 * exit.c: Likewise.
10833 * fe.h: Likewise.
10834 * final.c: Likewise.
10835 * init.c: Likewise.
10836 * initialize.c: Likewise.
10837 * link.c: Likewise.
10838 * namet.h: Likewise.
10839 * nlists.h: Likewise.
10840 * raise.c: Likewise.
10841 * raise.h: Likewise.
10842 * repinfo.h: Likewise.
10843 * seh_init.c: Likewise.
10844 * targext.c: Likewise.
10845 * tracebak.c: Likewise.
10846 * uintp.h: Likewise.
10847 * urealp.h: Likewise.
10848 * xeinfo.adb: Wrap up generated C code in extern "C" block.
10849 * xsinfo.adb: Likewise.
10850 * xsnamest.adb: Likewise.
10851 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
10852 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
10853 * gcc-interface/misc.c: Likewise.
10854 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
10855 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
10856 ada/targext.o here...
10857 (GNAT_ADA_OBJS): ...and not here.
10858 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
10859 (GNATBIND_OBJS): Reorder.
10860
10861 2011-07-07 Richard Henderson <rth@redhat.com>
10862
10863 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
10864 dwarf2out_frame_init.
10865
10866 2011-07-07 Eric Botcazou <ebotcazou@adacore.com>
10867
10868 * gcc-interface/misc.c (gnat_init): Tweak previous change.
10869
10870 2011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10871
10872 PR target/39150
10873 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
10874
10875 2011-07-06 Richard Guenther <rguenther@suse.de>
10876
10877 * gcc-interface/misc.c (gnat_init): Merge calls to
10878 build_common_tree_nodes and build_common_tree_nodes_2.
10879 Re-initialize boolean_false_node.
10880
10881 2011-07-02 Eric Botcazou <ebotcazou@adacore.com>
10882 Olivier Hainque <hainque@adacore.com>
10883 Nicolas Setton <setton@adacore.com>
10884
10885 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
10886 the type according to the ARTIFICIAL_P parameter.
10887 (create_type_decl): Likewise.
10888 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
10889
10890 2011-07-01 Eric Botcazou <ebotcazou@adacore.com>
10891
10892 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
10893 (gnatbind): Likewise.
10894
10895 2011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10896
10897 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
10898
10899 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
10900
10901 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
10902 local variable throughout. Remove useless call to Base_Type.
10903 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
10904 Take it also into account for the volatileness of the field. Set the
10905 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
10906
10907 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
10908
10909 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
10910 on a dereference built for a by-ref object if it has an address clause.
10911
10912 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
10913
10914 * einfo.ads (Address_Taken): Document use for the second argument of
10915 Asm_Input and Asm_Output attributes.
10916 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
10917 argument is an entity name, then set Address_Taken on it.
10918 <Attribute_Asm_Output>: Likewise.
10919 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
10920 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
10921 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
10922 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
10923
10924 2011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
10925
10926 PR middle-end/46500
10927 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
10928
10929 2011-06-14 Joseph Myers <joseph@codesourcery.com>
10930
10931 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
10932 (ada/utils.o): Update dependencies.
10933 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
10934 ../../../libcpp/libcpp.a.
10935 * gcc-interface/utils.c: Include common/common-target.h.
10936 (process_attributes): Use targetm_common.have_named_sections.
10937
10938 2011-06-07 Richard Guenther <rguenther@suse.de>
10939
10940 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
10941 set_sizetype.
10942
10943 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
10944
10945 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
10946 TREE_THIS_NOTRAP flag.
10947
10948 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
10949
10950 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
10951 Fix thinko.
10952
10953 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
10954
10955 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
10956 constants whose full view has discriminants specially.
10957
10958 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
10959
10960 * gcc-interface/utils.c: Include diagnostic.h.
10961 (gnat_write_global_declarations): Output debug information for all
10962 global type declarations before finalizing the compilation unit.
10963 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
10964
10965 2011-05-25 Jakub Jelinek <jakub@redhat.com>
10966
10967 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
10968
10969 2011-05-25 Kai Tietz <ktietz@redhat.com>
10970
10971 * adaint.c (__gnat_to_canonical_file_list_next): Use array
10972 initialization instead of const/none-const pointer assignment.
10973
10974 2011-05-24 Joseph Myers <joseph@codesourcery.com>
10975
10976 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
10977 $(EXTRA_GNAT1_OBJS).
10978 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
10979 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
10980 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
10981 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
10982 libcommon-target.a instead of prefix.o.
10983
10984 2011-05-21 Joseph Myers <joseph@codesourcery.com>
10985
10986 PR ada/49097
10987 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
10988
10989 2011-05-20 Joseph Myers <joseph@codesourcery.com>
10990
10991 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
10992 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
10993 instead of version.o.
10994
10995 2011-05-18 Kai Tietz <ktietz@redhat.com>
10996
10997 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
10998 boolean_false_node instead of integer_zero_node.
10999 (convert_with_check): Likewise.
11000 * gcc-interface/decl.c (choices_to_gnu): Likewise.
11001
11002 2011-05-12 Eric Botcazou <ebotcazou@adacore.com>
11003
11004 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
11005 type of the parameter is an unconstrained array, convert the actual to
11006 the type of the formal in the In Out and Out cases as well.
11007
11008 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
11009
11010 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
11011 call build_function_type_array or build_varargs_function_type_array
11012 instead.
11013 (create_subprog_type): Don't call build_function_type; call
11014 build_function_type_vec instead.
11015
11016 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
11017
11018 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
11019 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
11020 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
11021
11022 2011-05-07 Eric Botcazou <ebotcazou@adacore.com>
11023
11024 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
11025
11026 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
11027 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
11028
11029 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
11030
11031 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
11032
11033 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
11034
11035 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
11036 instead of accessing TYPE_ARG_TYPES directly.
11037 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
11038
11039 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
11040
11041 PR ada/48844
11042 * gcc-interface/gigi.h (get_variant_part): Declare.
11043 * gcc-interface/decl.c (get_variant_part): Make global.
11044 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
11045 types have the same constant size, are record types and T1 has a
11046 variant part while T2 doesn't.
11047
11048 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
11049
11050 * gcc-interface/utils.c (begin_subprog_body): Do not call
11051 get_pending_sizes.
11052 (end_subprog_body): Likewise.
11053
11054 2011-05-04 Richard Guenther <rguenther@suse.de>
11055
11056 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
11057 int_const_binop.
11058 (pos_to_constructor): Likewise.
11059
11060 2011-05-03 Nathan Froyd <froydnj@codesourcery.com>
11061 Eric Botcazou <ebotcazou@adacore.com>
11062
11063 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
11064 of build_function_type. Adjust calls to...
11065 (build_raise_check): ...this. Do not take a void_tree parameter.
11066 Call build_function_type_list instead of build_function_type.
11067 Fix head comment and swap couple of conditional blocks.
11068
11069 2011-04-30 Eric Botcazou <ebotcazou@adacore.com>
11070
11071 * gnatvsn.ads (Library_Version): Bump to 4.7.
11072 (Current_Year): Bump to 2011.
11073
11074 2011-04-29 Michael Matz <matz@suse.de>
11075
11076 * gcc-interface/misc.c (gnat_handle_option): Set
11077 warn_maybe_uninitialized.
11078
11079 2011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
11080
11081 * gnat_ugn.texi (Complexity Metrics Control): Update link to
11082 the Watson/McCabe paper.
11083
11084 2011-04-23 Jim Meyering <meyering@redhat.com>
11085
11086 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
11087
11088 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
11089
11090 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
11091 onto the new type.
11092
11093 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
11094
11095 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
11096 parameter.
11097 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
11098 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
11099 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
11100 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
11101 <all>: Do not set flags on the reused DECL node coming from an alias.
11102 Set DECL_IGNORED_P on the DECL node built for subprograms if they
11103 don't need debug info here...
11104 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
11105 (gigi): Adjust calls to create_subprog_decl.
11106 (build_raise_check): Likewise.
11107 (establish_gnat_vms_condition_handler): Likewise.
11108 (Compilation_Unit_to_gnu): Likewise.
11109 (gnat_to_gnu): Likewise.
11110
11111 2011-04-21 Eric Botcazou <ebotcazou@adacore.com>
11112
11113 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
11114 (NO_REORDER_ADAFLAGS): New variable.
11115 (EXTRA_GNATTOOLS): Always define.
11116 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
11117 Clean up and adjust list of files compiled with special options.
11118 * gcc-interface/Make-lang.in: Likewise.
11119 (ada/decl.o): Cosmetical change.
11120 (ada/misc.o): Remove dependency on $(PLUGIN_H).
11121
11122 2011-04-20 Jim Meyering <meyering@redhat.com>
11123
11124 * initialize.c (__gnat_initialize): Remove useless if-before-free.
11125
11126 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
11127
11128 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
11129 $(CFLAGS) on the link line.
11130
11131 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
11132
11133 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
11134 padded type built for the return type if it is unconstrained.
11135
11136 2011-04-14 Nathan Froyd <froydnj@codesourcery.com>
11137
11138 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
11139
11140 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
11141
11142 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
11143 before calling TREE_CHAIN.
11144 * gcc-interface/misc.c (gnat_init_ts): New function.
11145 (LANG_HOOKS_INIT_TS): Define.
11146
11147 2011-04-12 Martin Jambor <mjambor@suse.cz>
11148
11149 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
11150 instead of cgraph_node.
11151
11152 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
11153
11154 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
11155 alignment on fields of the RETURN type built for the Copy-In Copy-Out
11156 mechanism.
11157
11158 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
11159
11160 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
11161 of aggregate types that contain a placeholder.
11162
11163 2011-04-08 Nathan Froyd <froydnj@codesourcery.com>
11164
11165 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
11166 TYPE_ARG_TYPES.
11167 (handle_type_generic_attribute): Likewise.
11168
11169 2011-04-04 Eric Botcazou <ebotcazou@adacore.com>
11170
11171 PR ada/47163
11172 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
11173
11174 2011-04-04 Kai Tietz <ktietz@redhat.com>
11175
11176 PR ada/47163
11177 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
11178 to flag value.
11179
11180 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11181
11182 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
11183 type case, do not strip a padding type around the array type.
11184
11185 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11186
11187 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
11188 types.
11189
11190 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11191
11192 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
11193 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
11194 code for -feliminate-unused-debug-types.
11195 (gnat_post_options): Likewise.
11196
11197 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11198
11199 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
11200 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
11201 distinct copy.
11202
11203 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11204
11205 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
11206 DECL_ARTIFICIAL flag on enumeration types.
11207
11208 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11209
11210 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
11211 fat pointer types artificial unconditionally.
11212 <E_Array_Subtype>: Attach the base array type as a parallel type if it
11213 isn't artificial.
11214
11215 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11216
11217 * gcc-interface/gigi.h (get_dummy_type): Declare.
11218 (build_dummy_unc_pointer_types): Likewise.
11219 (finish_fat_pointer_type): Likewise.
11220 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
11221 fat pointer type has been built, complete it in place.
11222 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
11223 and thin pointers. Remove useless variable.
11224 (finish_fat_pointer_type): Make global and move to...
11225 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
11226 (get_dummy_type): New function.
11227 (build_dummy_unc_pointer_types): Likewise.
11228 (gnat_pushdecl): Propage the name to the anonymous variants only.
11229 (update_pointer_to): Only adjust the pointer types in the unconstrained
11230 array case.
11231
11232 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11233
11234 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
11235 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
11236 if this is a Taft amendment type and the full declaration is available.
11237 * gcc-interface/trans.c (process_type): Likewise.
11238 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
11239 (process_freeze_entity): Likewise.
11240 * gcc-interface/utils.c (dummy_global): New static variable.
11241 (gnat_write_global_declarations): If there are types declared as used
11242 at the global level, insert them in the global hash table.
11243
11244 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11245
11246 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
11247 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
11248 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
11249 copy.
11250 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
11251 flag of the type accordingly.
11252 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
11253
11254 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11255
11256 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
11257 finalizing types when updating the pointers to the designated type.
11258 <all>: Finalize the deferred types even if we didn't defer processing
11259 of incomplete types in this invocation.
11260
11261 2011-04-01 Olivier Hainque <hainque@adacore.com>
11262 Nicolas Setton <setton@adacore.com>
11263 Eric Botcazou <ebotcazou@adacore.com>
11264
11265 * gcc-interface/misc.c (gnat_descriptive_type): New function.
11266 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
11267
11268 2011-03-28 Kai Tietz <ktietz@redhat.com>
11269
11270 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
11271 Windows targets.
11272 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
11273 * system-mingw.ads (System): Change ZCX_By_Default default to True.
11274
11275 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
11276
11277 2011-03-28 Tristan Gingold <gingold@adacore.com>
11278
11279 PR ada/44431
11280 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
11281 Use ada output of gnatbind.
11282 (ada/b_gnatb.adb): Ditto.
11283 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
11284 (ada.mostlyclean, ada.stage1)
11285 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
11286 (ada.stagefeedback): Adjust.
11287 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
11288 Use ada output of gnatbind.
11289 (b_gnatm.adb): Ditto.
11290 (b_gnatl.o, b_gnatm.o): New rules.
11291
11292 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
11293
11294 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
11295 for the padded type built to support a specified size or alignment.
11296
11297 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
11298
11299 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
11300 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
11301 unconditionally to the end of the unit when the designated type is
11302 limited_with'ed.
11303 <all>: Rename local variable. Attempt to un-defer types only and do it
11304 for limited_with'ed types as well.
11305 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
11306 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
11307 consistently and remove redundant call to finalize_from_with_types.
11308
11309 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
11310
11311 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
11312 subprograms without a previous spec declared in the same unit.
11313 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
11314 subprograms at the end of the unit instead of at the beginning.
11315 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
11316 isn't public for the special handling of non-inline functions nested
11317 inside inline external functions.
11318
11319 2011-03-25 Jeff Law <law@redhat.com>
11320
11321 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
11322
11323 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
11324
11325 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
11326 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
11327 to compute Set_Size_Depends_On_Discriminant.
11328 (Layout_Type): Call it on array types in back-end layout mode.
11329 * sem_util.adb (Requires_Transient_Scope): Return true for array
11330 types only if the size depends on the value of discriminants.
11331 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
11332 type if the RHS is a call to a function that returns an unconstrained
11333 type with default discriminant.
11334
11335 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
11336
11337 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
11338 non-conversion to the nominal result type at the end.
11339
11340 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
11341
11342 * gcc-interface/trans.c (create_temporary): New function taken from...
11343 (create_init_temporary): ...here. Call it.
11344 (call_to_gnu): Create the temporary for the return value early, if any.
11345 Create it for a function with copy-in/copy-out parameters if there is
11346 no target; in other cases of copy-in/copy-out, use another temporary.
11347 Push the new binding level lazily. Add and rename local variables.
11348
11349 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
11350
11351 * gcc-interface/decl.c (validate_size): Improve comments and tweak
11352 error message.
11353 (set_rm_size): Likewise.
11354
11355 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
11356
11357 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
11358 for the padded type built in order to support a specified alignment.
11359 Fix incorrect formatting.
11360
11361 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
11362
11363 PR bootstrap/48216
11364 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
11365
11366 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
11367
11368 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
11369 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
11370 to the end of the list. Adjust recursive call. Rename local variable.
11371 If REORDER is true, reorder components of the record type.
11372 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
11373 components_to_record and adjust the parameter list.
11374
11375 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
11376
11377 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
11378 disabled, use the variable for bounds of loop iteration scheme.
11379
11380 2011-03-21 Kai Tietz <ktietz@redhat.com>
11381
11382 PR target/12171
11383 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
11384
11385 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
11386
11387 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
11388 out whether the expression is read-only. Short-circuit placeholder
11389 case and rename a couple of local variables.
11390
11391 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
11392
11393 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
11394 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
11395 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
11396 (convert): Deal with conversions from a smaller form type specially.
11397
11398 2011-02-14 Eric Botcazou <ebotcazou@adacore.com>
11399
11400 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
11401 its argument, except for the special -I- switch.
11402
11403 2011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
11404
11405 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
11406 "Ada Issues".
11407
11408 2011-02-08 Eric Botcazou <ebotcazou@adacore.com>
11409
11410 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
11411
11412 2011-02-03 Eric Botcazou <ebotcazou@adacore.com>
11413
11414 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
11415 GNAT_FORMAL.
11416 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
11417 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
11418 instead of GNAT_FORMAL. Protect the expression against multiple uses.
11419 Do not generate the check directly, instead instantiate the template
11420 check present in the descriptor.
11421 (make_descriptor_field): Move around.
11422 (build_vms_descriptor32): Build a template check in the POINTER field.
11423 (build_vms_descriptor): Remove useless suffixes.
11424 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
11425
11426 2011-01-26 Eric Botcazou <ebotcazou@adacore.com>
11427
11428 PR bootstrap/47467
11429 * targext.c: Include target files if IN_RTS is defined.
11430
11431 2011-01-26 Richard Guenther <rguenther@suse.de>
11432
11433 PR bootstrap/47467
11434 * targext.c: Include config.h.
11435 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
11436 dependency.
11437
11438 2011-01-04 Pascal Obry <obry@adacore.com>
11439 Eric Botcazou <ebotcazou@adacore.com>
11440
11441 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
11442
11443 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
11444
11445 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
11446 end-of-case on the end label and its associated gotos, if any.
11447
11448 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
11449
11450 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
11451 expressions of the parameter cache within the statement group of
11452 the CICO mechanism.
11453
11454 2011-01-04 Olivier Hainque <hainque@adacore.com>
11455 Eric Botcazou <ebotcazou@adacore.com>
11456
11457 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
11458 (set_end_locus_from_node): New function.
11459 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
11460 make and the function end_locus.
11461 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
11462 for the elaboration subprogram.
11463 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
11464 set the end_locus of the expression as well.
11465
11466 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
11467
11468 PR ada/47131
11469 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
11470 variables that are referenced in exception handlers volatile.
11471
11472
11473 \f
11474 Copyright (C) 2011 Free Software Foundation, Inc.
11475
11476 Copying and distribution of this file, with or without modification,
11477 are permitted in any medium without royalty provided the copyright
11478 notice and this notice are preserved.
11479
11480 * gnat_rm.texi: Ramification of pragma Eliminate documentation
11481 - fix bugs in the description of Source_Trace;
11482 - get rid of UNIT_NAME;
11483
11484 2011-08-02 Javier Miranda <miranda@adacore.com>
11485
11486 * exp_ch9.adb
11487 (Build_Dispatching_Requeue): Adding support for VM targets
11488 since we cannot directly reference the Tag entity.
11489 * exp_sel.adb (Build_K): Adding support for VM targets.
11490 (Build_S_Assignment): Adding support for VM targets.
11491 * exp_disp.adb
11492 (Default_Prim_Op_Position): In VM targets do not restrict availability
11493 of predefined interface primitives to compiling in Ada 2005 mode.
11494 (Is_Predefined_Interface_Primitive): In VM targets this service is not
11495 restricted to compiling in Ada 2005 mode.
11496 (Make_VM_TSD): Generate code that declares and initializes the OSD
11497 record. Needed to support dispatching calls through synchronized
11498 interfaces.
11499 * exp_ch3.adb
11500 (Make_Predefined_Primitive_Specs): Enable generation of predefined
11501 primitives associated with synchronized interfaces.
11502 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
11503 primitives associated with synchronized interfaces.
11504
11505 2011-08-02 Yannick Moy <moy@adacore.com>
11506
11507 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
11508 statements hidden in SPARK if preceded by the HIDE directive
11509 (Parse_Exception_Handlers): mark each exception handler in a sequence of
11510 exception handlers as hidden in SPARK if preceded by the HIDE directive
11511 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
11512 if starting with the HIDE directive
11513 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
11514 starting with the HIDE directive; mark the declarations in a private
11515 part as hidden in SPARK if the private part starts with the HIDE
11516 directive
11517 * restrict.adb, restrict.ads
11518 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
11519 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
11520 argument node belongs to a part which is hidden in SPARK
11521 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
11522 parts in SPARK; protect the possibly costly call to
11523 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
11524 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
11525 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
11526 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
11527 Tok_SPARK_Hide.
11528 (Scan): recognize special comment starting with '#' and followed by
11529 SPARK keyword "hide" as a HIDE directive.
11530
11531 2011-08-02 Yannick Moy <moy@adacore.com>
11532
11533 * types.ads, erroutc.ads: Minor reformatting.
11534
11535 2011-08-02 Vincent Celier <celier@adacore.com>
11536
11537 * link.c: Add response file support for cross platforms.
11538
11539 2011-08-02 Ed Schonberg <schonberg@adacore.com>
11540
11541 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
11542 in an association, set parent field of copy before partial analysis.
11543 * sem_res.adb (Resolve_Slice): create reference to itype only when
11544 expansion is enabled.
11545
11546 2011-08-02 Yannick Moy <moy@adacore.com>
11547
11548 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
11549 for new flag denoting which subprogram bodies are in ALFA
11550 * restrict.adb, sem_ch7.adb: Update comment
11551 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
11552 sem_ch9.adb, sem_res.adb: Add calls to
11553 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
11554 * sem_ch6.adb (Analyze_Function_Return): add calls to
11555 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
11556 middle of the body, and extended return.
11557 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
11558 False when missing return.
11559 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
11560 to True for subprograms whose spec is in ALFA. Remove later on the flag
11561 on the entity used for a subprogram body when there exists a separate
11562 declaration.
11563 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
11564 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
11565 False, otherwise do nothing.
11566
11567 2011-08-02 Robert Dewar <dewar@adacore.com>
11568
11569 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
11570
11571 2011-08-02 Yannick Moy <moy@adacore.com>
11572
11573 * sem_ch4.ads: minor formatting.
11574
11575 2011-08-02 Yannick Moy <moy@adacore.com>
11576
11577 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
11578 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
11579 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
11580 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
11581 opt.ads: cleanup of SPARK mode
11582
11583 2011-08-02 Yannick Moy <moy@adacore.com>
11584
11585 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
11586 types.
11587 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
11588 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
11589 * sem_ch3.adb
11590 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
11591 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
11592 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
11593 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
11594 types.
11595 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
11596 non-static range.
11597 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
11598 functions whose return type is not in ALFA.
11599 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
11600 specifications.
11601 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
11602 parameter's type is not in ALFA.
11603 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
11604 types are in ALFA.
11605
11606 2011-08-02 Ed Schonberg <schonberg@adacore.com>
11607
11608 * sem_ch6 (Analyze_Expression_Function): treat the function as
11609 Inline_Always, and introduce a subprogram declaration for it when it is
11610 not a completion.
11611 * inline.adb (Add_Inlined_Body): recognize bodies that come from
11612 expression functions, so that the back-end can determine whether they
11613 can in fact be inlined.
11614 * sem_util.adb (Is_Expression_Function): predicate to determine whether
11615 a function body comes from an expression function.
11616
11617 2011-08-02 Gary Dismukes <dismukes@adacore.com>
11618
11619 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
11620 null exclusions to test Can_Never_Be_Null on the anonymous access types
11621 of the formals rather than testing the formals themselves. Exclude this
11622 check in cases where the Old_Formal is marked as a controlling formal,
11623 to avoid issuing spurious errors for bodies completing dispatching
11624 operations (due to the flag not getting set on controlling access
11625 formals in body specs).
11626 (Find_Corresponding_Spec): When checking full and subtype conformance of
11627 subprogram bodies in instances, pass Designated and E in that order, for
11628 consistency with the expected order of the formals (New_Id followed by
11629 Old_Id).
11630
11631 2011-08-02 Robert Dewar <dewar@adacore.com>
11632
11633 * sem_ch8.adb: Minor reformatting.
11634
11635 2011-08-02 Ed Schonberg <schonberg@adacore.com>
11636
11637 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
11638 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
11639 primitive operations of class-wide actuals.
11640
11641 2011-08-02 Javier Miranda <miranda@adacore.com>
11642
11643 * exp_atag.ads, exp_atag.adb
11644 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
11645 since its value is implicitly passed in argument Typ.
11646 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
11647 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
11648 Build_Common_Dispatching_Select_Statements.
11649
11650 2011-08-02 Robert Dewar <dewar@adacore.com>
11651
11652 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
11653 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
11654 Minor reformatting.
11655
11656 2011-08-02 Robert Dewar <dewar@adacore.com>
11657
11658 * sem_res.adb: Minor reformatting.
11659 * sem_prag.adb: Minor reformatting.
11660
11661 2011-08-02 Javier Miranda <miranda@adacore.com>
11662
11663 * exp_atag.adb, exp_atags.ads
11664 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
11665 by the tagged type Entity. Required to use this routine in the VM
11666 targets since we do not have available the Tag entity in the VM
11667 platforms.
11668 * exp_ch6.adb
11669 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
11670 Ada.Tags has not been previously loaded.
11671 * exp_ch7.adb
11672 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
11673 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
11674 * sem_aux.adb
11675 (Enclosing_Dynamic_Scope): Add missing support to handle the full
11676 view of enclosing scopes. Required to handle enclosing scopes that
11677 are synchronized types whose full view is a task type.
11678 * exp_disp.adb
11679 (Build_VM_TSDs): Minor code improvement to avoid generating and
11680 analyzing lists with empty nodes.
11681 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
11682 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
11683 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
11684 (Make_Disp_Timed_Select_Body): Add support for VM targets.
11685 (Make_Select_Specific_Data_Table): Add support for VM targets.
11686 (Make_VM_TSD): Generate code to initialize the SSD structure of
11687 the TSD.
11688
11689 2011-08-02 Yannick Moy <moy@adacore.com>
11690
11691 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
11692 cross-references section in ALI.
11693 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
11694 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
11695 Sub).
11696 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
11697 subprogram or package entity of a node
11698 (Is_Local_Reference_Type): new function returns True for references
11699 selected in local cross-references.
11700 (Lt): function extracted from Lt in Output_References
11701 (Write_Entity_Name): function extracted from Output_References
11702 (Generate_Definition): generate reference with type 'D' for definition
11703 of objects (object declaration and parameter specification), with
11704 appropriate locations and units, for use in local cross-references.
11705 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
11706 references of type 'I' for initialization in object definition.
11707 (Output_References): move part of function Lt and procedure
11708 Write_Entity_Name outside of the body. Ignore references of types 'D'
11709 and 'I' introduced for local cross-references.
11710 (Output_Local_References): new procedure to output the local
11711 cross-references sections.
11712 (Lref_Entity_Status): new array defining whether an entity is a local
11713 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
11714 with 'I' type when initialization expression is present.
11715 * get_scos.adb, get_scos.ads: Correct comments and typos
11716
11717 2011-08-02 Javier Miranda <miranda@adacore.com>
11718
11719 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
11720 the JVM target.
11721 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
11722 the JVM target.
11723 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
11724 TSD support.
11725
11726 2011-08-02 Vincent Celier <celier@adacore.com>
11727
11728 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
11729 (No_Space_Img): New function
11730 (Find_Excluded_Sources): When reading from a file, record the file name
11731 and the line number for each excluded source.
11732 (Mark_Excluded_Sources): When reporting an error, if the excluded
11733 sources were read from a file, include file name and line number in
11734 the error message.
11735
11736 2011-08-02 Ed Schonberg <schonberg@adacore.com>
11737
11738 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
11739
11740 2011-08-02 Robert Dewar <dewar@adacore.com>
11741
11742 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
11743
11744 2011-08-02 Javier Miranda <miranda@adacore.com>
11745
11746 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
11747 generation of TSDs to the DOTNET compiler.
11748 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
11749 generation of TSDs to the DOTNET compiler.
11750
11751 2011-08-02 Javier Miranda <miranda@adacore.com>
11752
11753 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
11754 record of all the tagged types declared inside library level package
11755 declarations, library level package bodies or library level subprograms.
11756 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
11757 associated with a given tagged type.
11758 (Build_VM_TSDs): New subprogram.
11759 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
11760 compilation units that are subprograms.
11761 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
11762 compilation units that are package bodies.
11763 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
11764 units that are a package declaration or a package instantiation.
11765 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
11766 reorganization to improve the error generated by the frontend when the
11767 function Ada.Tags.Secondary_Tag is not available.
11768 * rtsfind.ads (RE_Register_TSD): New runtime entity.
11769 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
11770
11771 2011-08-02 Javier Miranda <miranda@adacore.com>
11772
11773 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
11774
11775 2011-08-02 Robert Dewar <dewar@adacore.com>
11776
11777 * s-imenne.ads: Minor reformatting.
11778
11779 2011-08-02 Robert Dewar <dewar@adacore.com>
11780
11781 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
11782 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
11783 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
11784
11785 2011-08-02 Robert Dewar <dewar@adacore.com>
11786
11787 * einfo.ads (Materialize_Entity): Document this is only for renamings
11788 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
11789 required debug information in the case where we transform the object
11790 declaration into a renaming declaration.
11791 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
11792 object
11793 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
11794 Materialize_Entity.
11795
11796 2011-08-02 Robert Dewar <dewar@adacore.com>
11797
11798 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
11799 Suppress_Init_Procs.
11800 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
11801 Suppress_Initialization/Initialization_Suppressed.
11802 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
11803 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
11804 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
11805 * sem_prag.adb: New processing for pragma Suppress_Initialization.
11806
11807 2011-08-02 Robert Dewar <dewar@adacore.com>
11808
11809 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
11810 Minor reformatting.
11811
11812 2011-08-02 Ed Schonberg <schonberg@adacore.com>
11813
11814 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
11815 only have inheritable classwide pre/postconditions.
11816
11817 2011-08-02 Javier Miranda <miranda@adacore.com>
11818
11819 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
11820 * rtsfind.ads (RE_Check_TSD): New runtime entity.
11821 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
11822 checks if the external tag of a type is the same as the external tag
11823 of some other declaration.
11824
11825 2011-08-02 Thomas Quinot <quinot@adacore.com>
11826
11827 * s-taskin.ads: Minor reformatting.
11828
11829 2011-08-02 Emmanuel Briot <briot@adacore.com>
11830
11831 * g-comlin.adb (Display_Help): swap the order in which it prints the
11832 short help and the general usage.
11833
11834 2011-08-02 Ed Schonberg <schonberg@adacore.com>
11835
11836 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
11837 the aspect declarations and attach them to the generic copy for
11838 subsequent analysis.
11839 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
11840 declarations of the generic tree to the new subprogram declarations.
11841 * sem_attr.adb (Check_Precondition_Postcondition): recognize
11842 conditions that apply to a subprogram instance.
11843
11844 2011-08-02 Robert Dewar <dewar@adacore.com>
11845
11846 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
11847
11848 2011-08-02 Ed Schonberg <schonberg@adacore.com>
11849
11850 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
11851 private type with a tagged full view is not derived in the immediate
11852 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
11853
11854 2011-08-02 Robert Dewar <dewar@adacore.com>
11855
11856 * exp_ch4.adb: Minor reformatting.
11857
11858 2011-08-02 Ed Schonberg <schonberg@adacore.com>
11859
11860 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
11861 Ada2012 iterator, the loop will be rewritten during expansion into a
11862 while loop with a cursor and an element declaration. Do not analyze the
11863 body in this case, because if the container is for indefinite types the
11864 actual subtype of the elements will only be determined when the cursor
11865 declaration is analyzed.
11866
11867 2011-08-02 Arnaud Charlet <charlet@adacore.com>
11868
11869 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
11870 size/alignment related attributes in CodePeer_Mode.
11871
11872 2011-08-02 Gary Dismukes <dismukes@adacore.com>
11873
11874 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
11875 Prepend_Element, since this can result in the operation getting the
11876 wrong slot in the full type's dispatch table if the full type has
11877 inherited operations. The incomplete type's operation will get added
11878 to the proper position in the full type's primitives
11879 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
11880 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
11881 dispatching operations, since there are cases where nonprimitive
11882 subprograms can get added to the list of incomplete dependents (such
11883 as subprograms in nested packages).
11884 * sem_ch6.adb (Process_Formals): First, remove test for being in a
11885 private part when determining whether to add a primitive with a
11886 parameter of a tagged incomplete type to the Private_Dependents list.
11887 Such primitives can also occur in the visible part, and should not have
11888 been excluded from being private dependents.
11889 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
11890 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
11891 list of a Taft-amendment incomplete type is a primitive before issuing
11892 an error that the full type must appear in the same unit. There are
11893 cases where nonprimitives can be in the list (such as subprograms in
11894 nested packages).
11895 * sem_disp.adb (Derives_From): Use correct condition for checking that
11896 a formal's type is derived from the type of the corresponding formal in
11897 the parent subprogram (the condition was completely wrong). Add
11898 checking that was missing for controlling result types being derived
11899 from the result type of the parent operation.
11900
11901 2011-08-02 Yannick Moy <moy@adacore.com>
11902
11903 * errout.adb (First_Node): minor renaming
11904 * restrict.adb (Check_Formal_Restriction): put restriction warning on
11905 first node.
11906
11907 2011-08-02 Yannick Moy <moy@adacore.com>
11908
11909 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
11910 before accessing operands.
11911 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
11912 decide whether an initialization expression respects SPARK rules, as
11913 the plain node is the expanded one. This allows for more valid warnings
11914 to be issued.
11915 * gnat_rm.texi: Minor update.
11916
11917 2011-08-02 Arnaud Charlet <charlet@adacore.com>
11918
11919 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
11920 previous change.
11921
11922 2011-08-02 Robert Dewar <dewar@adacore.com>
11923
11924 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
11925
11926 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
11927
11928 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
11929 loop statements and the element renaming declaration with a block when
11930 the element type is controlled.
11931
11932 2011-08-02 Yannick Moy <moy@adacore.com>
11933
11934 * sinfo.ads: Minor formatting.
11935
11936 2011-08-02 Ed Schonberg <schonberg@adacore.com>
11937
11938 * sem_aggr.adb (Add_Association): if the association has a box and no
11939 expression, use the Sloc of the aggregate itself for the new
11940 association.
11941 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
11942 the Original_Node.
11943
11944 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
11945
11946 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
11947 When a container is provided via a function call, generate a renaming
11948 of the function result. This avoids the creation of a transient scope
11949 and the premature finalization of the container.
11950 * exp_ch7.adb (Is_Container_Cursor): Removed.
11951 (Wrap_Transient_Declaration): Remove the supression of the finalization
11952 of the list controller when the declaration denotes a container cursor,
11953 it is not needed.
11954
11955 2011-08-02 Yannick Moy <moy@adacore.com>
11956
11957 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
11958 node is from source, instead of the original node being from source.
11959 * sem_aggr.adb
11960 (Resolve_Array_Aggregate): refine the check for a static expression, to
11961 recognize also static ranges
11962 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
11963 Array_Type_Declaration): postpone the test for the type being a subtype
11964 mark after the type has been resolved, so that component-selection and
11965 expanded-name are discriminated.
11966 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
11967 to distinguish the case of an iteration scheme, so that an error is
11968 issed on a non-static range in SPARK except in an iteration scheme.
11969 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
11970 In_Iter_Schm = True.
11971 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
11972 user-defined operators so that they are allowed in renaming
11973 * sem_ch8.adb
11974 (Find_Selected_Component): refine the check for prefixing of operators
11975 so that they are allowed in renaming. Move the checks for restrictions
11976 on selector name after analysis discriminated between
11977 component-selection and expanded-name.
11978 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
11979 concatenation argument of string type if it is static.
11980 * sem_util.adb, sem_util.ads
11981 (Check_Later_Vs_Basic_Declarations): add a new function
11982 Is_Later_Declarative_Item to decice which declarations are allowed as
11983 later items, in the two different modes Ada 83 and SPARK. In the SPARK
11984 mode, add that renamings are considered as later items.
11985 (Enclosing_Package): new function to return the enclosing package
11986 (Enter_Name): correct the rule for homonyms in SPARK
11987 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
11988 from source (result of expansion) to avoid issuing wrong warnings.
11989
11990 2011-08-02 Ed Schonberg <schonberg@adacore.com>
11991
11992 * errout.adb: On anything but an expression First_Node returns its
11993 argument.
11994
11995 2011-08-02 Pascal Obry <obry@adacore.com>
11996
11997 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
11998
11999 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
12000
12001 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
12002 Set the associated loop as the related expression of internally
12003 generated cursors.
12004 * exp_ch7.adb (Is_Container_Cursor): New routine.
12005 (Wrap_Transient_Declaration): Supress the finalization of the list
12006 controller when the declaration denotes a container cursor.
12007
12008 2011-08-02 Yannick Moy <moy@adacore.com>
12009
12010 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
12011 command line now.
12012 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
12013 expression is a simple expression. This check cannot be performed in
12014 the semantics, so just drop it.
12015 (P_Index_Or_Discriminant_Constraint): move check that the index or
12016 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
12017 semantics. Other cases were previously checked in the semantics.
12018 * par-ch4.adb (P_Name): move checks that a selector name is not
12019 character literal or an operator symbol to Find_Selected_Component in
12020 the semantics
12021 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
12022 declarations are not placed after later declarations in a separate
12023 procedure in Sem_Util (possibly not the best choice?), to be used both
12024 during parsing, for Ada 83 mode, and during semantic analysis, for
12025 SPARK mode.
12026 * par-endh.adb (Check_End): move check that end label is not missing
12027 to Process_End_Label in the semantics
12028 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
12029 the special case for SPARK restriction
12030 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
12031 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
12032 parameter Force to issue the error message even on internal node (used
12033 for generated end label). Call Check_Restriction to check when an error
12034 must be issued. In SPARK mode, issue an error message even if the
12035 restriction is not set.
12036 (Check_Restriction): new procedure with an additional out parameter to
12037 inform the caller that a message has been issued
12038 * sem_aggr.adb: Minor modification of message
12039 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
12040 instead of issuing an error message directly
12041 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
12042 declarations are not placed after later declarations, by calling
12043 Check_Later_Vs_Basic_Declarations
12044 (Analyze_Subtype_Declaration): move here the check that an index or
12045 discriminant constraint must be a subtype mark. Change the check that
12046 a subtype of String must start at one so that it works on subtype marks.
12047 * sem_ch4.adb (Analyze_Call): move here the check that a named
12048 association cannot follow a positional one in a call
12049 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
12050 instead of issuing an error message directly
12051 * sem_ch8.adb (Find_Selected_Component): move here the check that a
12052 selector name is not a character literal or an operator symbol. Move
12053 here the check that the prefix of an expanded name cannot be a
12054 subprogram or a loop statement.
12055 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
12056 procedure called from parsing and semantics to check that basic
12057 declarations are not placed after later declarations
12058 (Process_End_Label): move here the check that end label is not missing
12059
12060 2011-08-02 Arnaud Charlet <charlet@adacore.com>
12061
12062 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
12063 representation clause in codepeer mode, since it confuses CodePeer and
12064 does not bring useful info.
12065
12066 2011-08-02 Ed Falis <falis@adacore.com>
12067
12068 * init.c: initialize fp hw on MILS.
12069
12070 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12071
12072 * errout.adb (First_Node): for bodies, return the node itself (small
12073 optimization). For other nodes, do not check source_unit if the node
12074 comes from Standard.
12075
12076 2011-08-02 Robert Dewar <dewar@adacore.com>
12077
12078 * exp_ch3.adb: Minor comment additions.
12079 * sem_ch13.adb: Minor reformatting.
12080
12081 2011-08-02 Pascal Obry <obry@adacore.com>
12082
12083 * make.adb, makeutl.adb: Removes some superfluous directory separator.
12084
12085 2011-08-02 Robert Dewar <dewar@adacore.com>
12086
12087 * sem_attr.adb: Minor reformatting.
12088
12089 2011-08-02 Robert Dewar <dewar@adacore.com>
12090
12091 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
12092 (Has_Default_Component_Value): Removed
12093 * einfo.ads Comment updates
12094 (Has_Default_Aspect): Replaces Has_Default_Value
12095 (Has_Default_Component_Value): Removed
12096 * exp_ch13.adb
12097 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
12098 * exp_ch3.adb
12099 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
12100 (Get_Simple_Init_Val): Handle Default_Value aspect
12101 (Needs_Simple_Initialization): Handle Default_Value aspect
12102 * exp_ch3.ads: Needs_Simple_Initialization
12103 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
12104 * par-prag.adb (Pragma_Default[_Component]Value) Removed
12105 * sem_ch13.adb
12106 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
12107 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
12108 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
12109
12110 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12111
12112 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
12113 package containing iteration primitives.
12114 exp_ch5.adb (Expand_Iterator_Loop): ditto.
12115
12116 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12117
12118 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
12119 "of", pre-analyze expression in case it is a function call with
12120 finalization actions that must be placed ahead of the loop.
12121 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
12122 on an Ada2012 iterator, insert them ahead of the rewritten loop.
12123
12124 2011-08-02 Geert Bosch <bosch@adacore.com>
12125
12126 * cstand.adb (Create_Float_Types): Only consider C's long double for
12127 Long_Long_Float, in addition to double.
12128
12129 2011-08-02 Robert Dewar <dewar@adacore.com>
12130
12131 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
12132 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
12133 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
12134 Minor reformatting.
12135
12136 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12137
12138 * sem_attr.adb: handle properly 'Result when it is a prefix of an
12139 indexed component.
12140
12141 2011-08-02 Javier Miranda <miranda@adacore.com>
12142
12143 * einfo.ads, einfo.adb
12144 (Original_Access_Type): Move this attribute to Node26 since there was
12145 an undocumented use of Node21 in E_Access_Subprogram_Type entities
12146 which causes conflicts and breaks the generation of the .NET compiler.
12147 (Interface_Name): Add missing documentation on JGNAT only uses of
12148 this attribute.
12149
12150 2011-08-02 Geert Bosch <bosch@adacore.com>
12151
12152 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
12153 (Find_Back_End_Float_Type): Likewise
12154 (Create_Back_End_Float_Types): Likewise
12155 (Create_Float_Types): Likewise
12156 (Register_Float_Type): Likewise
12157 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
12158 Nlist and split out type selection in new local Find_Base_Type function.
12159 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
12160 Nlist
12161 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
12162
12163 2011-08-02 Robert Dewar <dewar@adacore.com>
12164
12165 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
12166 alpha order).
12167 * opt.ads: Minor comment change.
12168 * sem_ch12.adb: Minor code reorganization.
12169
12170 2011-08-02 Gary Dismukes <dismukes@adacore.com>
12171
12172 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
12173 subtype's list of rep items to the list on the full subtype in the case
12174 where the lists are the same.
12175
12176 2011-08-02 Geert Bosch <bosch@adacore.com>
12177
12178 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
12179 using the one from System.Strings, which also deallocates all strings.
12180
12181 2011-08-02 Geert Bosch <bosch@adacore.com>
12182
12183 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
12184 function.
12185 * gcc-interface/Make-lang.in: Update dependencies.
12186
12187 2011-08-02 Olivier Hainque <hainque@adacore.com>
12188
12189 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
12190 end_locus.
12191
12192 2011-08-02 Javier Miranda <miranda@adacore.com>
12193
12194 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
12195 associated with anonymous access to subprograms.
12196
12197 2011-08-02 Geert Bosch <bosch@adacore.com>
12198
12199 * opt.ads
12200 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
12201 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
12202 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
12203 (Add_Symbol_Definition): Move to switch-c.adb
12204 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
12205 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
12206 (Add_Symbol_Definition): Move to switch-c.adb.
12207 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
12208 * sem_warn.adb
12209 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
12210 Move to warnsw.adb.
12211 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
12212 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
12213 Move to warnsw.adb.
12214 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
12215 (Add_Symbol_Definition): Moved from Prepcomp.
12216 * switch-c.ads: Update copyright notice. Use String_List instead of
12217 Argument_List, removing dependency on System.OS_Lib.
12218
12219 2011-08-02 Yannick Moy <moy@adacore.com>
12220
12221 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
12222 mode on initialization expression which does not respect SPARK
12223 restrictions.
12224 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
12225 if the tree referenced by its argument represents an initialization
12226 expression in SPARK, suitable for initializing an object in an object
12227 declaration.
12228
12229 2011-08-02 Javier Miranda <miranda@adacore.com>
12230
12231 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
12232 internally generated access to subprogram with its associated protected
12233 subprogram type.
12234 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
12235
12236 2011-08-02 Geert Bosch <bosch@adacore.com>
12237
12238 * cstand.adb (Register_Float_Type): Print information about type to
12239 register, if the Debug_Flag_Dot_B is set.
12240 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
12241 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
12242 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
12243 with a requested precision of more than Max_Digits digits and no more
12244 than Max_Base_Digits digits, if a range specification is present and the
12245 Predefined_Float_Types list has a suitable type to derive from.
12246 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
12247 case of type completion with pragma Import
12248 * sem_prag.adb
12249 (Process_Import_Predefined_Type): Processing to complete a type
12250 with pragma Import. Currently supports floating point types only.
12251 (Set_Convention_From_Pragma): Do nothing without underlying type.
12252 (Process_Convention): Guard against absence of underlying type,
12253 which may happen when importing incomplete types.
12254 (Process_Import_Or_Interface): Handle case of importing predefined
12255 types. Tweak error message.
12256
12257 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
12258
12259 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
12260 functions to previous change. Reorganize code slightly.
12261
12262 2011-08-02 Geert Bosch <bosch@adacore.com>
12263
12264 * back_end.ads (Register_Type_Proc): New call back procedure type for
12265 allowing the back end to provide information about available types.
12266 (Register_Back_End_Types): New procedure to register back end types.
12267 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
12268 available types.
12269 * cstand.adb (Back_End_Float_Types): New list for floating point types
12270 supported by the back end.
12271 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
12272 (Copy_Float_Type): New procedure to make new copies of predefined types.
12273 (Register_Float_Type): New call back procedure to populate the BEFT list
12274 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
12275 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
12276 (Create_Float_Types): New procedure to create entities for floating
12277 point types predefined in Standard, and put these and any remaining
12278 BEFTs on the Predefined_Float_Types list.
12279 * stand.ads (Predefined_Float_Types): New list for predefined floating
12280 point types that do not have declarations in package Standard.
12281
12282 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
12283
12284 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
12285 entity node for the unit containing the parameter.
12286 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
12287 (Add_Inlined_Subprogram): Likewise.
12288 * gcc-interface/Make-lang.in: Update dependencies.
12289
12290 2011-08-02 Thomas Quinot <quinot@adacore.com>
12291
12292 * s-stusta.adb (Print): Make sure Pos is always initialized to a
12293 suitable value.
12294
12295 2011-08-02 Geert Bosch <bosch@adacore.com>
12296
12297 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
12298
12299 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
12300
12301 * sem_type.adb (Covers): Move trivial case to the top and reuse the
12302 computed value of Base_Type.
12303
12304 2011-08-02 Yannick Moy <moy@adacore.com>
12305
12306 * restrict.adb (Check_Restriction): issue an error for any use of
12307 class-wide, even if the No_Dispatch restriction is not set.
12308 * sem_aggr.adb: Correct typos in comments and messages in formal mode
12309 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
12310 when completing a private extension, the type named in the private part
12311 is not the same as that named in the visible part.
12312 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
12313 of an inherited primitive operations of a tagged type or type extension
12314 that returns the tagged type.
12315 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
12316 function which returns True for an implicit operation inherited by the
12317 derived type declaration for the argument type.
12318 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
12319 order.
12320
12321 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12322
12323 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
12324 Process_Bounds, to perform analysis with expansion of a range or an
12325 expression that is the iteration scheme for a loop.
12326 (Analyze_Iterator_Specification): If domain of iteration is given by a
12327 function call with a controlled result, as is the case if call returns
12328 a predefined container, ensure that finalization actions are properly
12329 generated.
12330 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
12331
12332 2011-08-02 Javier Miranda <miranda@adacore.com>
12333
12334 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
12335 * gcc-interface/Make-lang.in: Update dependencies.
12336
12337 2011-08-02 Javier Miranda <miranda@adacore.com>
12338
12339 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
12340 determine if the analysis is performed using N or Original_Node (N).
12341 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
12342 functionality of routine Is_Variable avoids code duplication.
12343 * checks.adb (Determine_Range): Handle temporaries generated by
12344 Remove_Side_Effects.
12345
12346 2011-08-02 Javier Miranda <miranda@adacore.com>
12347
12348 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
12349 expansion of the condition. Required since the previous analysis was
12350 done with expansion disabled (see Resolve_Quantified_Expression) and
12351 hence checks were not inserted and record comparisons have not been
12352 expanded.
12353
12354 2011-08-02 Ed Falis <falis@adacore.com>
12355
12356 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
12357 Update header.
12358
12359 2011-08-02 Bob Duff <duff@adacore.com>
12360
12361 * opt.ads: Minor comment fix.
12362
12363 2011-08-02 Bob Duff <duff@adacore.com>
12364
12365 * sem_ch12.adb (Analyze_Package_Instantiation,
12366 Analyze_Subprogram_Instantiation): Turn off style checking while
12367 analyzing an instance. Whatever style checks that apply to the generic
12368 unit should apply, so it makes no sense to apply them in an instance.
12369 This was causing trouble when compiling an instance of a runtime
12370 unit that violates the -gnatyO switch.
12371 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
12372 one of the two case statements, causing spurious errors.
12373
12374 2011-08-02 Robert Dewar <dewar@adacore.com>
12375
12376 * uname.adb: Minor reformatting.
12377 * gnatcmd.adb: Minor reformatting.
12378 * exp_attr.adb: Minor reformatting.
12379
12380 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12381
12382 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
12383 No_Dispatching_Calls, do not look for the Assign primitive, because
12384 predefined primitives are not created in this case.
12385
12386 2011-08-02 Bob Duff <duff@adacore.com>
12387
12388 * stylesw.ads: Minor comment fixes.
12389
12390 2011-08-02 Robert Dewar <dewar@adacore.com>
12391
12392 * freeze.adb (Add_To_Result): New procedure.
12393
12394 2011-08-02 Jose Ruiz <ruiz@adacore.com>
12395
12396 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
12397 time, if the specific run-time routines for handling streams of strings
12398 are not available, use the default mechanism.
12399
12400 2011-08-02 Arnaud Charlet <charlet@adacore.com>
12401
12402 * s-regpat.ads: Fix typo.
12403
12404 2011-08-02 Vincent Celier <celier@adacore.com>
12405
12406 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
12407 not null, call it to create the in memory config project file without
12408 parsing an existing default config project file.
12409
12410 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
12411
12412 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
12413
12414 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12415
12416 * sem_elim.adb: an abstract subprogram does not need an eliminate
12417 pragma for its descendant to be eliminable.
12418
12419 2011-08-02 Ed Falis <falis@adacore.com>
12420
12421 * init.c: revert to handling before previous checkin for VxWorks
12422 * s-intman-vxworks.adb: delete unnecessary declarations related to
12423 using Ada interrupt facilities for handling signals.
12424 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
12425 * s-intman-vxworks.ads: Import __gnat_install_handler as
12426 Initialize_Interrupts.
12427 * s-taprop-vxworks.adb: Delete Signal_Mask.
12428 (Abort_Handler): change construction of mask to unblock exception
12429 signals.
12430
12431 2011-08-02 Jerome Guitton <guitton@adacore.com>
12432
12433 * a-except-2005.adb (Raise_From_Signal_Handler): Call
12434 Debug_Raise_Exception before propagation starts.
12435
12436 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
12437
12438 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
12439 to Restriction_Check_Required.
12440 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
12441 * sem_res.adb (Resolve_Call): Likewise.
12442 * sem_attr.adb (Check_Stream_Attribute): Likewise.
12443
12444 2011-08-02 Bob Duff <duff@adacore.com>
12445
12446 * stylesw.ads: Update comment.
12447 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
12448 * errout.ads: Remove obsolete comment.
12449
12450 2011-08-02 Javier Miranda <miranda@adacore.com>
12451
12452 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
12453 (Set_Is_Safe_To_Reevaluate): new procedure.
12454 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
12455 assignment is allowed on safe-to-reevaluate variables.
12456 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
12457 temporary created to remove side effects in expressions that use
12458 the secondary stack as safe-to-reevaluate.
12459 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
12460 variables that are not true constants.
12461
12462 2011-08-02 Robert Dewar <dewar@adacore.com>
12463
12464 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
12465 sem_res.adb, sem_ch6.adb: Minor reformatting.
12466
12467 2011-08-02 Jerome Guitton <guitton@adacore.com>
12468
12469 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
12470
12471 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12472
12473 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
12474 not set Overridden_Operation if subprogram is an initialization
12475 procedure.
12476
12477 2011-08-02 Yannick Moy <moy@adacore.com>
12478
12479 * par-ch6.adb: Correct obsolete name in comments
12480 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
12481 which takes two message arguments (existing function takes one), with
12482 second message used for continuation.
12483 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
12484 block statements that originate from a source block statement, not
12485 generated block statements
12486 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
12487 symmetry with procedure case
12488 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
12489 function to issue an error in formal mode if a package specification
12490 contains more than one tagged type or type extension.
12491 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
12492 parameters matching formals of tagged types are objects (or ancestor
12493 type conversions of objects), not general expressions. Issue an error
12494 on view conversions that are not involving ancestor conversion of an
12495 extended type.
12496 (Resolve_Type_Conversion): in formal mode, issue an error on the
12497 operand of an ancestor type conversion which is not an object
12498 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
12499 procedure so that it works also for actuals of function calls
12500 (Is_Actual_Tagged_Parameter): new function which determines if its
12501 argument is an actual parameter of a formal of tagged type in a
12502 subprogram call
12503 (Is_SPARK_Object_Reference): new function which determines if the tree
12504 referenced by its argument represents an object in SPARK
12505
12506 2011-08-02 Robert Dewar <dewar@adacore.com>
12507
12508 * sem_ch3.adb: Minor reformatting
12509 Minor comment addition
12510 Minor error msg text change
12511
12512 2011-08-02 Javier Miranda <miranda@adacore.com>
12513
12514 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
12515 function. Used to be more precise when we generate a variable plus one
12516 assignment to remove side effects in the evaluation of the Bound
12517 expressions.
12518 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
12519 of the bound expression to force its re-analysis and thus expand the
12520 associated transient scope (if required). Code cleanup replacing the
12521 previous code that declared the constant entity by an invocation to
12522 routine Force_Evaluation which centralizes this work in the frontend.
12523
12524 2011-08-02 Robert Dewar <dewar@adacore.com>
12525
12526 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
12527 (Base_Type): Now uses improved Is_Base_Type function
12528 * einfo.ads (Base_Type): Inline this function
12529
12530 2011-08-02 Robert Dewar <dewar@adacore.com>
12531
12532 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
12533 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
12534
12535 2011-08-02 Arnaud Charlet <charlet@adacore.com>
12536
12537 * gcc-interface/Make-lang.in: Update dependencies.
12538 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
12539 targets.
12540
12541 2011-08-02 Yannick Moy <moy@adacore.com>
12542
12543 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
12544 non-simple expression used in delta constraint
12545 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
12546 index constraint which is not a subtype mark
12547 * par.adb: With and use Restrict
12548 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
12549 mode on component type which is not a subtype mark and default
12550 expression on component
12551 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
12552 of string which does not have a lower index bound equal to 1
12553 (Array_Type_Declaration): issue an error in formal mode on index or
12554 component type which is not a subtype mark, and on aliased keyword on
12555 component
12556 (Derived_Type_Declaration): issue an error in formal mode on interface,
12557 limited or abstract type
12558 (Record_Type_Declaration): issue an error in formal mode on interface
12559 (Record_Type_Definition): issue an error in formal mode on tagged types
12560 and type extensions not declared in the specification of a library unit
12561 package; on null non-tagged record; on variant part
12562
12563 2011-08-02 Vincent Celier <celier@adacore.com>
12564
12565 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
12566 not declared for qualified library project when Library_Name is not
12567 declared, but Library_Dir is.
12568
12569 2011-08-02 Robert Dewar <dewar@adacore.com>
12570
12571 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
12572 pragmas (affects aspects [Component_]Default_Value
12573 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
12574 component type for the resolution
12575
12576 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
12577
12578 * einfo.adb (Base_Type): Tune implementation for speed.
12579
12580 2011-08-02 Robert Dewar <dewar@adacore.com>
12581
12582 * freeze.adb: Minor reformatting.
12583
12584 2011-08-02 Thomas Quinot <quinot@adacore.com>
12585
12586 * scos.ads: Update comments.
12587
12588 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12589
12590 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
12591 base type, because the parent may be a subtype of a private type whose
12592 convention is established in a private part.
12593
12594 2011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
12595
12596 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
12597 statement in a block when the expansion of the return expression has
12598 created a finalization chain.
12599 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
12600 with the parent node.
12601 Add N_Extended_Return_Statement to handle the case where a transient
12602 object declaration appears in the Return_Object_Declarations list of
12603 an extended return statement.
12604
12605 2011-08-02 Matthew Gingell <gingell@adacore.com>
12606
12607 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
12608 unused parameter 'name'.
12609
12610 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12611
12612 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
12613 inherited operation, check whether its alias, which is the source
12614 operastion that it renames, has been marked eliminated.
12615
12616 2011-08-02 Javier Miranda <miranda@adacore.com>
12617
12618 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
12619 in-mode parameter whose type is an access type since it can be used to
12620 modify its designated object. Enforce code that handles as safe an
12621 access type that is not access-to-constant but it is the result of a
12622 previous removal of side-effects.
12623 (Remove_Side_Effects): Minor code reorganization of cases which require
12624 no action. Done to incorporate documentation on new cases uncovered
12625 working in this ticket: no action needed if this routine was invoked
12626 too early and the nodes are not yet decorated.
12627 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
12628 to routine Remove_Side_Effects by calls to Force_Evaluation since they
12629 were issued with actuals that are implicitly provided by
12630 Force_Evaluation.
12631
12632 2011-08-02 Robert Dewar <dewar@adacore.com>
12633
12634 * sem_ch3.adb, sem_res.adb: Minor reformatting.
12635
12636 2011-08-02 Yannick Moy <moy@adacore.com>
12637
12638 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
12639 to issue an error in formal mode on attribute not supported in this mode
12640 (Analyze_Attribute): issue errors on standard attributes not supported
12641 in formal mode.
12642 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
12643 comment, and issue error in formal mode on modulus which is not a power
12644 of 2.
12645 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
12646 range.
12647 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
12648 subtype mark.
12649 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
12650 operator on modular type (except 'not').
12651
12652 2011-08-02 Robert Dewar <dewar@adacore.com>
12653
12654 * gnat_rm.texi: Minor reformatting.
12655
12656 2011-08-02 Arnaud Charlet <charlet@adacore.com>
12657
12658 * s-osinte-linux.ads: Minor comment update and reformatting.
12659 * i-cexten.ads: Make this unit pure, as for its parent.
12660 Will allow its usage in more contexts if needed.
12661
12662 2011-08-02 Robert Dewar <dewar@adacore.com>
12663
12664 * s-utf_32.ads: Minor comment fix.
12665
12666 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12667
12668 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
12669 operation of a tagged synchronized type, handle the case where the
12670 controlling argument is overloaded.
12671
12672 2011-08-02 Yannick Moy <moy@adacore.com>
12673
12674 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
12675 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
12676 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
12677 SPARK mode and formal verification mode on processing SPARK restriction
12678 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
12679 requiring consistency checking.
12680
12681 2011-08-02 Robert Dewar <dewar@adacore.com>
12682
12683 * sem_res.adb: Minor reformatting.
12684
12685 2011-08-02 Robert Dewar <dewar@adacore.com>
12686
12687 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
12688 a-cforse.ads: Remove unneeded with of Ada.Containers
12689 Remove commented out pragma Inline's
12690 Move specifications of new subprograms to the actual specs
12691
12692 2011-08-02 Yannick Moy <moy@adacore.com>
12693
12694 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
12695 a-cforse.ads: Update comments.
12696
12697 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12698
12699 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
12700
12701 2011-08-02 Robert Dewar <dewar@adacore.com>
12702
12703 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
12704 a-cforse.ads, a-cofove.ads: Minor reformatting.
12705
12706 2011-08-02 Claire Dross <dross@adacore.com>
12707
12708 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
12709 a-cofove.ads: Add comments.
12710
12711 2011-08-02 Yannick Moy <moy@adacore.com>
12712
12713 * gnat_rm.texi: Document formal containers.
12714
12715 2011-08-02 Emmanuel Briot <briot@adacore.com>
12716
12717 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
12718 are empty sections.
12719
12720 2011-08-02 Robert Dewar <dewar@adacore.com>
12721
12722 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
12723 reformatting.
12724
12725 2011-08-02 Robert Dewar <dewar@adacore.com>
12726
12727 * aspects.adb: New aspects Default_Value and Default_Component_Value
12728 New format of Aspect_Names table checks for omitted entries
12729 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
12730 handling of boolean aspects for derived types.
12731 New aspects Default_Value and Default_Component_Value
12732 New format of Aspect_Names table checks for omitted entries
12733 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
12734 (Has_Default_Value): New flag
12735 (Has_Default_Component_Value): New flag
12736 (Has_Default_Value): New flag
12737 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
12738 table.
12739 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
12740 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
12741 Default_Value and Default_Component_Value
12742 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
12743 New aspects Default_Value and Default_Component_Value
12744 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
12745 * sprint.adb: Print N_Aspect_Specification node when called from gdb
12746
12747 2011-08-02 Vincent Celier <celier@adacore.com>
12748
12749 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
12750 inherit library kind.
12751
12752 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12753
12754 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
12755 Minor reformatting.
12756
12757 2011-08-02 Robert Dewar <dewar@adacore.com>
12758
12759 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
12760
12761 2011-08-02 Yannick Moy <moy@adacore.com>
12762
12763 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
12764
12765 2011-08-02 Robert Dewar <dewar@adacore.com>
12766
12767 * impunit.adb: Add comment.
12768
12769 2011-08-02 Yannick Moy <moy@adacore.com>
12770
12771 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
12772 qualification of aggregates in formal mode
12773 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
12774 another aggregate
12775 (Resolve_Aggregate): complete the test that an aggregate is adequately
12776 qualified in formal mode
12777
12778 2011-08-02 Pascal Obry <obry@adacore.com>
12779
12780 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
12781 * mlib-prj.adb: Supress warning when compiling binder generated file.
12782 (Build_Library): Supress all warnings when compiling the binder
12783 generated file.
12784
12785 2011-08-02 Yannick Moy <moy@adacore.com>
12786
12787 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
12788 from here...
12789 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
12790 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
12791 Add with/use clauses to make Check_Formal_Restriction visible
12792
12793 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12794
12795 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
12796 in-parameters when type of the generic formal is private in the generic
12797 spec and non-private in the body.
12798
12799 2011-08-02 Claire Dross <dross@adacore.com>
12800
12801 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
12802 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
12803 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
12804 * impunit.adb, Makefile.rtl: Take new files into account.
12805
12806 2011-08-02 Robert Dewar <dewar@adacore.com>
12807
12808 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
12809 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
12810
12811 2011-08-02 Yannick Moy <moy@adacore.com>
12812
12813 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
12814 formal mode
12815 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
12816 matching static array bounds, taking into account the special case of
12817 string literals
12818 * sem_ch3.adb: Typo in comment.
12819
12820 2011-08-02 Yannick Moy <moy@adacore.com>
12821
12822 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
12823 which issues an error in formal mode if its argument node is originally
12824 from source
12825 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
12826 has a discriminant specification so that it does not include the case
12827 of derived types
12828 (Derived_Type_Declaration): move here the test that a derived type has a
12829 discriminant specification
12830 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
12831 first element of a component association before accessing its choices
12832 (presence of component association is not enough)
12833 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
12834 declaration is a library item before accessing the next element in a
12835 list, as library items are not member of lists
12836 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
12837 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
12838 Check_Formal_Restriction whenever possible.
12839
12840 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12841
12842 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
12843 reference when needed.
12844
12845 2011-08-02 Bob Duff <duff@adacore.com>
12846
12847 * gnat_ugn.texi: Fix typo.
12848
12849 2011-08-02 Vincent Celier <celier@adacore.com>
12850
12851 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
12852 archive file name. Do not use the full path name of archives for Open
12853 VMS.
12854
12855 2011-08-02 Robert Dewar <dewar@adacore.com>
12856
12857 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
12858 Analyze_Aspect_Specifications
12859 * sem_ch13.adb
12860 (Analyze_Aspect_Specifications): New handling for boolean aspects
12861 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
12862 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
12863 sequence for Analyze_Aspect_Specifications
12864 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
12865 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
12866
12867 2011-08-02 Robert Dewar <dewar@adacore.com>
12868
12869 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
12870 aspects, since these no longer exist.
12871
12872 2011-08-02 Robert Dewar <dewar@adacore.com>
12873
12874 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
12875 semicolon, do not try to see if there are aspects following it.
12876 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
12877 aspect spec.
12878
12879 2011-08-02 Robert Dewar <dewar@adacore.com>
12880
12881 * sem_ch8.adb, aspects.ads: Minor reformatting.
12882
12883 2011-08-02 Eric Botcazou <ebotcazou@adacore.com>
12884
12885 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
12886 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
12887 extracted from...
12888 (Analyze_Aspect_Specifications): ...here. Call above procedure.
12889
12890 2011-08-02 Yannick Moy <moy@adacore.com>
12891
12892 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
12893 mode on subprogram declaration outside of package specification, unless
12894 it is followed by a pragma Import
12895 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
12896 Access_Type_Declaration): issue error in formal mode on access type
12897 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
12898 incomplete type
12899 (Analyze_Object_Declaration): issue error in formal mode on object
12900 declaration which does not respect SPARK restrictions
12901 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
12902 declaration which does not respect SPARK restrictions
12903 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
12904 error in formal mode on digits or delta constraint
12905 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
12906 decimal fixed point type
12907 (Derived_Type_Declaration): issue error in formal mode on derived type
12908 other than type extensions of tagged record types
12909 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
12910 with check on access definition
12911 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
12912 mode on protected definition.
12913 (Analyze_Task_Definition): issue error in formal mode on task definition
12914
12915 2011-08-02 Robert Dewar <dewar@adacore.com>
12916
12917 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
12918
12919 2011-08-02 Javier Miranda <miranda@adacore.com>
12920
12921 * sem_ch6.adb (Can_Override_Operator): New function.
12922 (Verify_Overriding_Indicator): Add missing code to check overriding
12923 indicator in operators. Fixes regression.
12924 (Check_Overriding_Indicator): Minor reformating after replacing the
12925 code that evaluates if the subprogram can override an operator by
12926 invocations to the above new function.
12927 * einfo.adb
12928 (Write_Field26_Name): Add missing code to ensure that, following
12929 the documentation in einfo.ads, this field is not shown as attribute
12930 "Static_Initialization" on non-dispatching functions.
12931
12932 2011-08-02 Jose Ruiz <ruiz@adacore.com>
12933
12934 * sem_res.adb (Resolve_Call): A call to
12935 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
12936 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
12937 i.e., when the second parameter is of type Time_Span.
12938
12939 2011-08-02 Vincent Celier <celier@adacore.com>
12940
12941 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
12942 with an archive instead of -L<library dir> -l<library name>.
12943
12944 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12945
12946 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
12947 mark the base types In_Use in addition to making the operations
12948 use_visible.
12949
12950 2011-08-02 Ed Falis <falis@adacore.com>
12951
12952 * init.c: add and setup __gnat_signal_mask for the exception signals
12953 * s-inmaop-vxworks.adb: new file.
12954 * s-intman-vxworks.adb: remove unnecessary initializations and
12955 simplify remaining
12956 * s-intman-vxworks.ads: remove unnecessary variable
12957 * s-taprop-vxworks.adb: simplify signal initialization
12958
12959 2011-08-02 Robert Dewar <dewar@adacore.com>
12960
12961 * sem_ch8.adb: Minor code reorganization, comment updates.
12962
12963 2011-08-02 Robert Dewar <dewar@adacore.com>
12964
12965 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
12966 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
12967 here from Sem_Res.
12968 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
12969 (Matching_Static_Array_Bounds): Moved here from Sem_Res
12970
12971 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12972
12973 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
12974 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
12975 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
12976 use_type_clauses, to handle more efficiently use_type and use_all_type
12977 constructs.
12978 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
12979 Ada2012 Use_All_Type clause.
12980 (Use_Class_Wide_Operations): new procedure.
12981
12982 2011-08-02 Robert Dewar <dewar@adacore.com>
12983
12984 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
12985 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
12986 expression to expression function.
12987
12988 2011-08-02 Ed Schonberg <schonberg@adacore.com>
12989
12990 * sem_ch4.adb: transform simple Ada2012 membership into equality only
12991 if types are compatible.
12992
12993 2011-08-02 Yannick Moy <moy@adacore.com>
12994
12995 * sem_res.adb (Matching_Static_Array_Bounds): new function which
12996 returns True if its argument array types have same dimension and same
12997 static bounds at each index.
12998 (Resolve_Actuals): issue an error in formal mode on actuals passed as
12999 OUT or IN OUT paramaters which are not view conversions in SPARK.
13000 (Resolve_Arithmetic_Op): issue an error in formal mode on
13001 multiplication or division with operands of fixed point types which are
13002 not qualified or explicitly converted.
13003 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
13004 Boolean or array type (except String) operands.
13005 (Resolve_Equality_Op): issue an error in formal mode on equality
13006 operators for array types other than String with non-matching static
13007 bounds.
13008 (Resolve_Logical_Op): issue an error in formal mode on logical operators
13009 for array types with non-matching static bounds. Factorize the code in
13010 Matching_Static_Array_Bounds.
13011 (Resolve_Qualified_Expression): issue an error in formal mode on
13012 qualified expressions for array types with non-matching static bounds.
13013 (Resolve_Type_Conversion): issue an error in formal mode on type
13014 conversion for array types with non-matching static bounds
13015
13016 2011-08-02 Robert Dewar <dewar@adacore.com>
13017
13018 * par-ch10.adb: Minor code reorganization (use Nkind_In).
13019
13020 2011-08-02 Ed Schonberg <schonberg@adacore.com>
13021
13022 * par-ch9.adb: save location of entry for proper error message.
13023
13024 2011-08-02 Javier Miranda <miranda@adacore.com>
13025
13026 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
13027 (Use_Full_View) which permits this routine to climb through the
13028 ancestors using the full-view of private parents.
13029 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
13030 Use_Full_View to true in calls to Is_Ancestor.
13031 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
13032 true in call to Is_Ancestor.
13033 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
13034 Use_Full_View to true in call to Is_Ancestor.
13035 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
13036 call to Is_Ancestor.
13037 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
13038 Use_Full_View to true in calls to Is_Ancestor.
13039 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
13040 Make_Select_Specific_Data_Table, Register_Primitive,
13041 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
13042 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
13043 to true in call to Is_Ancestor.
13044 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
13045 Use_Full_View to true in calls to Is_Ancestor.
13046 * exp_cg.adb
13047 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
13048 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
13049
13050 2011-08-02 Robert Dewar <dewar@adacore.com>
13051
13052 * gnat_rm.texi: Minor reformatting.
13053 * sem_prag.adb: Minor reformatting.
13054
13055 2011-08-02 Tristan Gingold <gingold@adacore.com>
13056
13057 * vms_data.ads: Add VMS qualifier for -gnateP.
13058
13059 2011-08-02 Robert Dewar <dewar@adacore.com>
13060
13061 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
13062 * par-ch7.adb (P_Package): Proper placement of aspects for package
13063 decl/instantiation.
13064 * par-endh.adb (Check_End): Ad Is_Sloc parameter
13065 (End_Statements): Add Is_Sloc parameterr
13066 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
13067 (Check_End): Ad Is_Sloc parameter
13068 (End_Statements): Add Is_Sloc parameterr
13069
13070 2011-08-02 Vincent Celier <celier@adacore.com>
13071
13072 * ug_words: Add VMS qualifier equivalent to -gnateP:
13073 /SYMBOL_PREPROCESSING.
13074
13075 2011-08-02 Jose Ruiz <ruiz@adacore.com>
13076
13077 * gnat-style.texi: For hexadecimal numeric literals the typical
13078 grouping of digits is 4 to represent 2 bytes.
13079 A procedure spec which is split into several lines is indented two
13080 characters.
13081
13082 2011-08-02 Yannick Moy <moy@adacore.com>
13083
13084 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
13085 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
13086 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
13087 properly qualified
13088 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
13089 choice in array aggregate
13090 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
13091 mark as ancestor
13092 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
13093 positional and named aggregate for record, or others in record
13094 aggregate, or multiple choice in record aggregate
13095 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
13096 array operands to logical operations AND, OR and XOR do not have the
13097 same static lower and higher bounds
13098 * sem_ch5.adb, sinfo.ads: Correct typos in comments
13099
13100 2011-08-01 Robert Dewar <dewar@adacore.com>
13101
13102 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
13103 Replaces Last_Source_Node_In_Sequence.
13104 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
13105 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
13106 parens and blank in string (this was inconsistently implemented).
13107 * errout.ads
13108 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
13109 blank in string (this was inconsistently implemented).
13110 * gnat1drv.adb
13111 (Set_Global_Switches): Set formal mode switches appropriately
13112 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
13113 * par-prag.adb
13114 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
13115 call Set_Error_Msg_Lang to set "spark" as language name.
13116 * par.adb: Remove unnecessary call to set formal language for errout
13117 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
13118 appropriately and call Set_Error_Msg_Lang to set "spark" as language
13119 name.
13120 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
13121 calls to it, moved after resolution so that types are known
13122 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
13123 result of concatenation is not of type String
13124 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
13125 concatenation is not properly restricted
13126 * gnat_rm.texi: Add doc on pragma Spark_95.
13127 * gcc-interface/Makefile.in: Remove obsolete target pairs for
13128 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
13129 * gcc-interface/Make-lang.in: Update dependencies.
13130
13131 2011-08-01 Javier Miranda <miranda@adacore.com>
13132
13133 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
13134 condition that detects if the overridden operation must replace an
13135 existing entity.
13136
13137 2011-08-01 Javier Miranda <miranda@adacore.com>
13138
13139 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
13140 code declarations inserted by Insert_Actions in each alternative of the
13141 N_Case_Expression node.
13142
13143 2011-08-01 Robert Dewar <dewar@adacore.com>
13144
13145 * sem_ch6.adb: Minor code reorganization.
13146 * sem_util.adb: Minor reformatting.
13147
13148 2011-08-01 Pascal Obry <obry@adacore.com>
13149
13150 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
13151 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
13152
13153 2011-08-01 Yannick Moy <moy@adacore.com>
13154
13155 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
13156 literal or operator symbol which is prefixed
13157 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
13158 mode on access attributes.
13159 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
13160 that concatenation operands are properly restricted in formal mode
13161 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
13162 Analyze_Concatenation_Operand. Issue an error in formal mode if the
13163 result of the concatenation has a type different from String.
13164 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
13165 Analyze_Quantified_Expression, Analyze_Slice,
13166 Analyze_Null): issue an error in formal mode on unsupported constructs
13167 * sem_ch5.adb
13168 (Analyze_Block_Statement): only issue error on source block statement
13169 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
13170 function which returns the last node in a list of nodes for which
13171 Comes_From_Source returns True, if any
13172 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
13173 Last_Source_Node_In_Sequence
13174 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
13175 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
13176 mode on unsupported constructs
13177 * sem_ch9.adb Do not return after issuing error in formal mode, as the
13178 rest of the actions may be needed later on since the error is marked as
13179 not serious.
13180 * sinfo.ads: Typos in comments.
13181
13182 2011-08-01 Pascal Obry <obry@adacore.com>
13183
13184 * projects.texi: Minor editing.
13185
13186 2011-08-01 Yannick Moy <moy@adacore.com>
13187
13188 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
13189 insertion character ~~
13190 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
13191 (Set_Error_Msg_Lang): new procedure which fixes the language for use
13192 with insertion character ~~
13193 (Set_Msg_Text): treat insertion character ~~
13194 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
13195 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
13196 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
13197 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
13198 errors related to the formal language restriction not serious
13199 (insertion character |).
13200 * par.adb (Par): set formal language for error messages if needed
13201 * sem_ch6.adb (Check_Missing_Return): take into account possible
13202 generated statements at the end of the function
13203 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
13204 enumeration value to define a new pragma SPARK_95
13205 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
13206 SPARK_Version): new type and variables to store the SPARK version
13207 (none by default).
13208 (SPARK_Mode): return True when SPARK_Version is set
13209 * par-prag.adb: Correct indentation
13210 (Prag): take Pragma_SPARK_95 into account
13211 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
13212 into account.
13213
13214 2011-08-01 Robert Dewar <dewar@adacore.com>
13215
13216 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
13217 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
13218 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
13219
13220 2011-08-01 Pascal Obry <obry@adacore.com>
13221
13222 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
13223 Target_Name to Get_Path call.
13224 (Parse_Single_Project): Likewise.
13225 (Post_Parse_Context_Clause): Likewise.
13226 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
13227 Call Initialise_Project_Path with the proper Target_Name.
13228 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
13229 search path.
13230 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
13231 with the proper Target_Name.
13232 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
13233 Part.Parse routine.
13234 (Parse_Project_And_Apply_Config): Likewise.
13235 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
13236 This is fine as this part of the code is supporting only native
13237 compilation.
13238 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
13239 is fine as this part of the code is supporting only native compilation.
13240
13241 2011-08-01 Yannick Moy <moy@adacore.com>
13242
13243 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
13244 of homonym, unless the homonym is one of the cases allowed in SPARK
13245 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
13246 package declaration occurring after a body.
13247
13248 2011-08-01 Robert Dewar <dewar@adacore.com>
13249
13250 * checks.adb, exp_ch4.adb: Minor reformatting.
13251
13252 2011-08-01 Javier Miranda <miranda@adacore.com>
13253
13254 * einfo.ads (Access_Disp_Table): Fix documentation.
13255 (Dispatch_Table_Wrappers): Fix documentation.
13256
13257 2011-08-01 Pascal Obry <obry@adacore.com>
13258
13259 * prj-env.adb, prj-env.ads: Minor reformatting.
13260
13261 2011-08-01 Yannick Moy <moy@adacore.com>
13262
13263 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
13264 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
13265 procedures out of these packages.
13266 * errout.ads, errout.adb
13267 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
13268 procedures in of this package
13269 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
13270 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
13271 on misplaced later vs initial declarations, like in Ada 83
13272 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
13273 formal mode on attribute of private type whose full type declaration
13274 is not visible
13275 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
13276 package declaration inside a package specification
13277 (Analyze_Full_Type_Declaration): issue error in formal mode on
13278 controlled type or discriminant type
13279 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
13280 user-defined operator means that it should come from the source
13281 (New_Overloaded_Entity): issue error in formal mode on overloaded
13282 entity.
13283 * sem_ch6.ads, sem_ch13.ads: typos in comments.
13284
13285 2011-08-01 Thomas Quinot <quinot@adacore.com>
13286
13287 * atree.adb: Minor reformatting.
13288 * checks.adb: Minor reformatting.
13289
13290 2011-08-01 Vincent Celier <celier@adacore.com>
13291
13292 * s-parame-vms-ia64.ads: Fix typo in comment
13293 Minor reformatting
13294 * s-parame-vms-restrict.ads: Removed, unused.
13295
13296 2011-08-01 Javier Miranda <miranda@adacore.com>
13297
13298 * exp_ch3.adb
13299 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
13300 * sem_ch3.adb
13301 (Constrain_Index): Remove side effects in the evaluation of the bounds.
13302 * sem_ch3.ads, sem_ch3.adb
13303 (Is_Constant_Bound): New extended version of the subprogram that was
13304 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
13305 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
13306 * sem_aux.ads (Constant_Value): Fix typo in comment.
13307 * checks.adb (Generate_Index_Checks): New implementation which, for
13308 array objects with constant bounds, generates the runtime check
13309 referencing the bounds of the array type. For other cases this routine
13310 provides its previous behavior obtaining such values from the array
13311 object.
13312 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
13313 parent type.
13314 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
13315 we cannot have semantic interpretations of the new node.
13316
13317 2011-08-01 Ed Schonberg <schonberg@adacore.com>
13318
13319 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
13320 expressions.
13321
13322 2011-08-01 Arnaud Charlet <charlet@adacore.com>
13323
13324 * sem_ch8.adb: Minor code editing.
13325 * s-vxwext.adb: Remove trailing space.
13326 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
13327 consistency with other files.
13328
13329 2011-08-01 Thomas Quinot <quinot@adacore.com>
13330
13331 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
13332
13333 2011-08-01 Ed Schonberg <schonberg@adacore.com>
13334
13335 * par-ch10.adb: reject parameterized expressions as compilation unit.
13336 * sem_ch4.adb: handle properly conditional expression with overloaded
13337 then_clause and no else_clause.
13338
13339 2011-08-01 Tristan Gingold <gingold@adacore.com>
13340
13341 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
13342 like done by System.Aux_DEC.
13343 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
13344
13345 2011-08-01 Yannick Moy <moy@adacore.com>
13346
13347 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
13348 missing label at end of declaration (subprogram or package)
13349 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
13350 of positional and named parameter association
13351 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
13352 Error_Msg_SP which adds a prefix to the error message giving the name
13353 of the formal language analyzed
13354 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
13355 access result type in subprogram, unconstrained array as result type,.
13356 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
13357 procedure
13358 * sem_ch8.adb: Code clean up.
13359
13360 2011-08-01 Javier Miranda <miranda@adacore.com>
13361
13362 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
13363 * einfo.ads (Access_Disp_Table): Fix documentation.
13364 (Dispatch_Table_Wrappers): Fix documentation.
13365 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
13366 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
13367 to enforce the documentation of this attribute.
13368 (Set_Is_Interface): Cleanup the assertion.
13369 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
13370 the Underlying_Type entity before reading attribute Access_Disp_Table.
13371 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
13372 Locate the Underlying_Type before reading attribute Access_Disp_Table.
13373 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
13374 the Underlying_Type entity before reading attribute Access_Disp_Table.
13375 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
13376 Locate the Underlying_Type entity before reading attribute
13377 Access_Disp_Table.
13378
13379 2011-08-01 Ed Schonberg <schonberg@adacore.com>
13380
13381 * s-poosiz.ads: Additional overriding indicators.
13382
13383 2011-08-01 Yannick Moy <moy@adacore.com>
13384
13385 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
13386 formal mode.
13387 (Analyze_Iteration_Scheme): issue error in formal mode when loop
13388 parameter specification does not include a subtype mark.
13389 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
13390 formal mode on abstract subprogram.
13391 (Analyze_Subprogram_Specification): issue error in formal mode on
13392 user-defined operator.
13393 (Process_Formals): issue error in formal mode on access parameter and
13394 default expression.
13395 * sem_ch9.adb (Analyze_Abort_Statement,
13396 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
13397 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
13398 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
13399 Analyze_Requeue, Analyze_Selective_Accept,
13400 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
13401 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
13402 issue error in formal mode on user-defined raise statement.
13403
13404 2011-08-01 Thomas Quinot <quinot@adacore.com>
13405
13406 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
13407 declaration being hidden when overriding an implicit inherited
13408 subprogram.
13409 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
13410 (-gnats), do not complain about a source file that contains only a
13411 pragma No_Body.
13412
13413 2011-08-01 Ed Schonberg <schonberg@adacore.com>
13414
13415 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
13416 variable if already set.
13417
13418 2011-08-01 Arnaud Charlet <charlet@adacore.com>
13419
13420 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
13421 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
13422 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
13423 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
13424 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
13425 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
13426 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
13427 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
13428 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
13429 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
13430 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
13431 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
13432 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
13433 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
13434 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
13435 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
13436 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
13437 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
13438 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
13439 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
13440 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
13441 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
13442 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
13443 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
13444 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
13445 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
13446 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
13447 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
13448 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
13449 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
13450 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
13451 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
13452 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
13453 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
13454 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
13455 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
13456 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
13457 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
13458 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
13459 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
13460 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
13461 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
13462 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
13463 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
13464 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
13465 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
13466 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
13467 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
13468 s-osinte-mingw.ads: Update to GPLv3 run-time license.
13469 Use GNAT instead of GNARL.
13470
13471 2011-08-01 Bob Duff <duff@adacore.com>
13472
13473 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
13474 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
13475 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
13476 reformatting.
13477
13478 2011-08-01 Yannick Moy <moy@adacore.com>
13479
13480 * debug.adb (d.D) reverve flag for the SPARK mode
13481 (d.E) reverve flag for SPARK generation mode
13482 (d.F) reverve flag for Why generation mode
13483 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
13484 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
13485 functions which return True when the corresponding modes are set
13486 (Formal_Language): return "spark" or "alfa" when in formal verification
13487 mode.
13488 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
13489 Error_Msg to prefix the error message with a tag giving the formal
13490 language
13491 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
13492 message with a tag giving the formal language
13493 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
13494 block statement
13495 (Analyze_Case_Statement): issue error in formal mode on case statement
13496 with a single "others" case alternative
13497 (Analyze_Exit_Statement): issue errors in formal mode on exit
13498 statements which do not respect SPARK restrictions
13499 (Analyze_Goto_Statement): issue error in formal mode on goto statement
13500 (Check_Unreachable_Code): always issue an error (not a warning) in
13501 formal mode on unreachable code (concerns both code after an infinite
13502 loop and after an unconditional jump, both not allowed in SPARK)
13503 * sem_ch6.adb (Analyze_Return_Statement): add call to
13504 Set_Return_Present for a procedure containing a return statement
13505 (already done for functions in Analyze_Function_Return)
13506 (Analyze_Function_Return): issue error in formal mode on extended
13507 return or if return is not last statement in function
13508 (Check_Missing_Return): issue error in formal mode if function does
13509 not end with return or if procedure contains a return
13510 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
13511 function to detect if there is an inner scope of its parameter S which
13512 is a loop.
13513
13514 2011-08-01 Thomas Quinot <quinot@adacore.com>
13515
13516 * sem_ch6.ads: Minor reformatting.
13517
13518 2011-08-01 Javier Miranda <miranda@adacore.com>
13519
13520 * sem_util.adb (Abstract_Interface_List): Complete condition when
13521 processing private type declarations to avoid reading unavailable
13522 attribute.
13523 (Is_Synchronized_Tagged_Type): Complete condition when processing
13524 private extension declaration nodes to avoid reading unavailable
13525 attribute.
13526
13527 2011-08-01 Thomas Quinot <quinot@adacore.com>
13528
13529 * sem_ch3.adb: Minor reformatting.
13530
13531 2011-08-01 Thomas Quinot <quinot@adacore.com>
13532
13533 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
13534 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
13535 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
13536 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
13537 for VMS, instead parametrize the common implementation with
13538 System.Parameters declarations.
13539
13540 2011-08-01 Eric Botcazou <ebotcazou@adacore.com>
13541
13542 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
13543
13544 2011-08-01 Tristan Gingold <gingold@adacore.com>
13545
13546 * seh_init.c: Fix SEH handler installation on win64.
13547
13548 2011-08-01 Ed Schonberg <schonberg@adacore.com>
13549
13550 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
13551 double analysis of an anonymous access to subprogram, because it can
13552 lead to improper sharing of profiles and a back-end crash.
13553
13554 2011-08-01 Robert Dewar <dewar@adacore.com>
13555
13556 * make.adb, sem_ch4.adb: Minor reformatting.
13557 * gcc-interface/Make-lang.in: Update dependencies.
13558 * sem_util.adb, exp_ch5.adb: Minor reformatting.
13559
13560 2011-08-01 Arnaud Charlet <charlet@adacore.com>
13561
13562 * gnat_rm.texi: Fix definition of Long_Integer.
13563
13564 2011-08-01 Ed Schonberg <schonberg@adacore.com>
13565
13566 * exp_aggr.adb: check limit size of static aggregate unconditionally,
13567 to prevent storage exhaustion.
13568 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
13569 finalized is a function body, insert the cleanup code before the final
13570 return statement, to prevent spurious warnings.
13571 * s-pooglo.ads: add overriding indicator.
13572
13573 2011-08-01 Ed Schonberg <schonberg@adacore.com>
13574
13575 * sem_ch4.adb (Operator_Check): improve error message when both a
13576 with_clause and a use_clause are needed to make operator usage legal.
13577 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
13578 determine whether a compilation unit is visible within an other,
13579 either through a with_clause in the current unit, or a with_clause in
13580 its library unit or one one of its parents.
13581
13582 2011-08-01 Ed Schonberg <schonberg@adacore.com>
13583
13584 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
13585 over an arbitrary expression of an array or container type.
13586 * lib-xref.adb: clarify comment.
13587
13588 2011-08-01 Bob Duff <duff@adacore.com>
13589
13590 * einfo.ads: Minor reformatting.
13591 * debug.adb: Minor comment improvement.
13592
13593 2011-08-01 Javier Miranda <miranda@adacore.com>
13594
13595 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
13596 consider hidden subprograms as valid candidates.
13597
13598 2011-08-01 Arnaud Charlet <charlet@adacore.com>
13599
13600 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
13601
13602 2011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
13603
13604 * gnat_ugn.texi: Fix typo.
13605
13606 2011-08-01 Robert Dewar <dewar@adacore.com>
13607
13608 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
13609 lib-xref.adb: Minor reformatting
13610
13611 2011-08-01 Gary Dismukes <dismukes@adacore.com>
13612
13613 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
13614 when to generate a call to Move_Final_List.
13615 (Has_Controlled_Parts): Remove this function.
13616
13617 2011-08-01 Geert Bosch <bosch@adacore.com>
13618
13619 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
13620 "," in choice list.
13621
13622 2011-08-01 Thomas Quinot <quinot@adacore.com>
13623
13624 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
13625 explicit raise of a predefined exception as Comes_From_Source if the
13626 original N_Raise_Statement comes from source.
13627
13628 2011-08-01 Robert Dewar <dewar@adacore.com>
13629
13630 * sinfo.ads: Add comment.
13631 * sem_ch6.adb: Minor reformatting.
13632
13633 2011-08-01 Robert Dewar <dewar@adacore.com>
13634
13635 * freeze.adb (Freeze_Entity): Refine check for bad component size
13636 clause to avoid rejecting confirming clause when atomic/aliased present.
13637
13638 2011-08-01 Ed Schonberg <schonberg@adacore.com>
13639
13640 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
13641 better determine whether an entity reference is a write.
13642 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
13643 subcomponent.
13644 * lib-xref.adb (Output_References): Do no suppress a read reference at
13645 the same location as an immediately preceeding modify-reference, to
13646 handle properly in-out actuals.
13647
13648 2011-08-01 Tristan Gingold <gingold@adacore.com>
13649
13650 * env.c (__gnat_setenv) [VMS]: Refine previous change.
13651
13652 2011-08-01 Quentin Ochem <ochem@adacore.com>
13653
13654 * i-cstrin.adb (New_String): Changed implementation, now uses only the
13655 heap to compute the result.
13656
13657 2011-08-01 Robert Dewar <dewar@adacore.com>
13658
13659 * atree.ads: Minor reformatting.
13660
13661 2011-08-01 Emmanuel Briot <briot@adacore.com>
13662
13663 * g-expect.adb (Get_Command_Output): Fix memory leak.
13664
13665 2011-08-01 Geert Bosch <bosch@adacore.com>
13666
13667 * cstand.adb (P_Float_Type): New procedure to print the definition of
13668 predefined fpt types.
13669 (P_Mixed_Name): New procedure to print a name using mixed case
13670 (Print_Standard): Use P_Float_Type for printing floating point types
13671 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
13672 precision IEEE float.
13673
13674 2011-08-01 Thomas Quinot <quinot@adacore.com>
13675
13676 * sem_ch3.adb: Minor reformatting.
13677
13678 2011-08-01 Ed Schonberg <schonberg@adacore.com>
13679
13680 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
13681 the completion of a generic function, insert the new body rather than
13682 rewriting the original.
13683
13684 2011-08-01 Yannick Moy <moy@adacore.com>
13685
13686 * sinfo.ads, errout.ads: Typos in comments.
13687
13688 2011-08-01 Robert Dewar <dewar@adacore.com>
13689
13690 * par-endh.adb: Minor reformatting.
13691
13692 2011-08-01 Robert Dewar <dewar@adacore.com>
13693
13694 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
13695 (Pre_Post_Aspects): New subtype.
13696 * par-ch12.adb (P_Generic): New syntax for aspects in packages
13697 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
13698 * par-ch7.adb (P_Package): Remove Decl parameter
13699 (P_Package): Handle new syntax for aspects (before IS)
13700 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
13701 new aspect syntax
13702 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
13703 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
13704 (P_Package): Remove Decl parameter
13705 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
13706 aspects
13707 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
13708 specs
13709 * sem_util.ads, sem_util.adb (Static_Boolean): New function
13710 * sinfo.ads: Document new syntax for aspects in packages etc.
13711 * sprint.adb: Handle new syntax of aspects before IS in package
13712
13713 2011-08-01 Thomas Quinot <quinot@adacore.com>
13714
13715 * atree.ads: Minor reformatting.
13716 * sem_prag.adb: Minor reformatting.
13717
13718 2011-08-01 Robert Dewar <dewar@adacore.com>
13719
13720 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
13721 case expr alternative.
13722
13723 2011-08-01 Ed Schonberg <schonberg@adacore.com>
13724
13725 * sem_ch12.adb: Fix typo.
13726
13727 2011-08-01 Geert Bosch <bosch@adacore.com>
13728
13729 * sem_prag.adb (Check_No_Link_Name): New procedure.
13730 (Process_Import_Or_Interface): Use Check_No_Link_Name.
13731 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
13732 instead of Standard_Long_Long_Float_Size global. Preparation for
13733 eventual removal of per type constants.
13734 * exp_util.ads (Get_Stream_Size): New function returning the stream
13735 size value of subtype E.
13736 * exp_util.adb (Get_Stream_Size): Implement new function.
13737 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
13738 function.
13739 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
13740 * einfo.adb:
13741 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
13742
13743 2011-08-01 Geert Bosch <bosch@adacore.com>
13744
13745 * cstand.adb: Fix comments.
13746 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
13747 count of arguments.
13748
13749 2011-08-01 Robert Dewar <dewar@adacore.com>
13750
13751 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
13752
13753 2011-08-01 Geert Bosch <bosch@adacore.com>
13754
13755 * atree.ads: Fix comment.
13756
13757 2011-08-01 Robert Dewar <dewar@adacore.com>
13758
13759 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
13760 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
13761 * par.adb: Add with for Namet.Sp.
13762 * par-tchk.adb: Minor reformatting.
13763
13764 2011-08-01 Vincent Celier <celier@adacore.com>
13765
13766 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
13767 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
13768 of the init procedure of a SAL.
13769 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
13770 New procedure.
13771
13772 2011-08-01 Thomas Quinot <quinot@adacore.com>
13773
13774 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
13775 reformatting.
13776
13777 2011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
13778
13779 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
13780
13781 2011-08-01 Thomas Quinot <quinot@adacore.com>
13782
13783 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
13784 conformant with its spec (return True only for types that have
13785 an overriding Initialize primitive operation that prevents them from
13786 having preelaborable initialization).
13787 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
13788 initialization for controlled types in Ada 2005 or later mode.
13789
13790 2011-08-01 Robert Dewar <dewar@adacore.com>
13791
13792 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
13793 Postcondition.
13794 (Same_Aspect): New function.
13795 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
13796 Type_Invariant, Precondition, Postcondition.
13797 * snames.ads-tmpl: Add Name_Type_Invariant.
13798
13799 2011-08-01 Robert Dewar <dewar@adacore.com>
13800
13801 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
13802 here.
13803 (Freeze_All_Ent): Fix error in handling inherited aspects.
13804 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
13805 already analyzed, but don't skip entire processing of a declaration,
13806 that's wrong in some cases of declarations being rewritten.
13807 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
13808 Don't delay for integer, string literals
13809 Treat predicates in usual manner for delay, remove special case code,
13810 not needed.
13811 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
13812 (Build_Predicate_Function): Update saved expression in aspect
13813 (Build_Invariant_Procedure): Update saved expression in aspect
13814 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
13815 of replacement of discriminant references if the reference is simple.
13816
13817 2011-08-01 Robert Dewar <dewar@adacore.com>
13818
13819 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
13820 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
13821 Static_Predicate and Dynamic_Predicate.
13822 (Build_Predicate_Function): Add processing for Static_Predicate
13823 and Dynamic_Predicate.
13824 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
13825 (From_Static_Predicate): New flag
13826 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
13827
13828 2011-08-01 Robert Dewar <dewar@adacore.com>
13829
13830 * usage.adb: Documentation cleanup for Ada version modes in usage.
13831 * expander.adb: Minor reformatting.
13832
13833 2011-08-01 Robert Dewar <dewar@adacore.com>
13834
13835 * atree.ads: Minor comment fix.
13836 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
13837 a-witeio.ads, sem_prag.adb: Minor reformatting.
13838
13839 2011-08-01 Doug Rupp <rupp@adacore.com>
13840
13841 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
13842 pointers. Use descrip.h header file for convenience. Add some
13843 comments.
13844
13845 2011-08-01 Robert Dewar <dewar@adacore.com>
13846
13847 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
13848 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
13849 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
13850 New procedure.
13851 (Check_Aspect_At_End_Of_Declarations): New procedure
13852 (Analye_Aspect_Specification): Minor changes for above procedures
13853 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
13854 specification node as well.
13855
13856 2011-08-01 Pascal Obry <obry@adacore.com>
13857
13858 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
13859 Windows files. Use GetFilesAttributes() in this case to check for file
13860 existence instead of returning with an error code.
13861
13862 2011-08-01 Vincent Celier <celier@adacore.com>
13863
13864 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
13865 High is above Source length.
13866
13867 2011-08-01 Robert Dewar <dewar@adacore.com>
13868
13869 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
13870
13871 2011-08-01 Robert Dewar <dewar@adacore.com>
13872
13873 * aspects.ads (Boolean_Aspects): New subtype.
13874 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
13875 for derived types in cases where the parent type and derived type have
13876 aspects.
13877 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
13878 with aspects when parent type also has aspects.
13879 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
13880 boolean expression at this point).
13881 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
13882 accordance with final decision on the Ada 2012 feature.
13883 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
13884
13885 2011-08-01 Matthew Heaney <heaney@adacore.com>
13886
13887 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
13888
13889 2011-08-01 Pascal Obry <obry@adacore.com>
13890
13891 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
13892 Fix Replace_Slice when High is above current string size.
13893 (Replace_Slice): Fix DL computation when High is above current
13894 string length.
13895
13896 2011-08-01 Gary Dismukes <dismukes@adacore.com>
13897
13898 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
13899
13900 2011-08-01 Matthew Heaney <heaney@adacore.com>
13901
13902 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
13903 of node.
13904
13905 2011-08-01 Pascal Obry <obry@adacore.com>
13906
13907 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
13908 reformatting.
13909
13910 2011-08-01 Ed Schonberg <schonberg@adacore.com>
13911
13912 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
13913 access to protected subprograms in generic bodies.
13914 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
13915 protected type, indicate that the convention of the subprogram is
13916 Convention_Protected, because it may be used in subsequent declarations
13917 within the protected declaration.
13918
13919 2011-08-01 Vincent Celier <celier@adacore.com>
13920
13921 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
13922 and "final" procedures when the name of the library is "ada", to avoid
13923 duplicate symbols "adainit" and "adafinal" in executables.
13924
13925 2011-08-01 Ed Schonberg <schonberg@adacore.com>
13926
13927 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
13928 quantified expression that appears within a postcondition and uses the
13929 Ada2012 'Result attribute.
13930
13931 2011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
13932
13933 * init.c (__gnat_error_handler): Cast reason to int.
13934 (__gnat_install_handler): Explain sa_sigaction use.
13935
13936 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
13937
13938 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
13939 subprogram has copy-in copy-out parameters, try to promote the mode of
13940 the return type if it is passed in registers.
13941
13942 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
13943
13944 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
13945 left operand as addressable.
13946
13947 2011-07-24 Eric Botcazou <ebotcazou@adacore.com>
13948
13949 * gcc-interface/gigi.h (build_function_stub): Remove.
13950 (build_return_expr): Likewise.
13951 (convert_vms_descriptor): Declare.
13952 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
13953 (build_function_stub): Move to...
13954 * gcc-interface/utils2.c (build_return_expr): Move to...
13955 * gcc-interface/trans.c (build_function_stub): ...here.
13956 (build_return_expr): ...here.
13957 (Subprogram_Body_to_gnu): Add local variable for language_function.
13958 Disconnect the parameter attributes cache, if any, once done with it.
13959 Call end_subprog_body only after setting the end_locus.
13960 Build the stub associated with the function, if any, at the very end.
13961 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
13962 variables and streamline control flow.
13963
13964 2011-07-23 Arnaud Charlet <charlet@adacore.com>
13965
13966 PR ada/49819
13967 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
13968 g-trasym-dwarf.adb.
13969
13970 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
13971
13972 PR bootstrap/49794
13973 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
13974 Assign to act.sa_sigaction.
13975 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
13976 current->return_address to char * before arithmetic.
13977
13978 2011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
13979
13980 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
13981 Correct argument types.
13982 Extract code from reason.
13983 (__gnat_install_handler): Assign to act.sa_sigaction.
13984
13985 2011-07-21 Eric Botcazou <ebotcazou@adacore.com>
13986
13987 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
13988 (GNAT1_OBJS): ...here.
13989
13990 2011-07-15 Eric Botcazou <ebotcazou@adacore.com>
13991
13992 PR ada/48711
13993 * g-socthi-mingw.adb (Fill): Fix formatting.
13994
13995 * gcc-interface/gigi.h: Move around comment.
13996
13997 2011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
13998
13999 PR ada/46350
14000 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
14001
14002 2011-07-14 Florian Weimer <fw@deneb.enyo.de>
14003
14004 PR ada/48711
14005 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
14006
14007 2011-07-13 Eric Botcazou <ebotcazou@adacore.com>
14008
14009 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
14010 range comparison if Pmode is SImode.
14011
14012 2011-07-12 Laurent GUERBY <laurent@guerby.net>
14013 Eric Botcazou <ebotcazou@adacore.com>
14014
14015 * adadecode.c: Wrap up in extern "C" block.
14016 * adadecode.h: Likewise.
14017 * adaint.c: Likewise. Remove 'const' keyword.
14018 * adaint.h: Likewise.
14019 * argv.c: Likewise.
14020 * atree.h: Likewise.
14021 * cio.c: Likewise.
14022 * cstreams.c: Likewise.
14023 * env.c: Likewise.
14024 * exit.c: Likewise.
14025 * fe.h: Likewise.
14026 * final.c: Likewise.
14027 * init.c: Likewise.
14028 * initialize.c: Likewise.
14029 * link.c: Likewise.
14030 * namet.h: Likewise.
14031 * nlists.h: Likewise.
14032 * raise.c: Likewise.
14033 * raise.h: Likewise.
14034 * repinfo.h: Likewise.
14035 * seh_init.c: Likewise.
14036 * targext.c: Likewise.
14037 * tracebak.c: Likewise.
14038 * uintp.h: Likewise.
14039 * urealp.h: Likewise.
14040 * xeinfo.adb: Wrap up generated C code in extern "C" block.
14041 * xsinfo.adb: Likewise.
14042 * xsnamest.adb: Likewise.
14043 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
14044 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
14045 * gcc-interface/misc.c: Likewise.
14046 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
14047 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
14048 ada/targext.o here...
14049 (GNAT_ADA_OBJS): ...and not here.
14050 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
14051 (GNATBIND_OBJS): Reorder.
14052
14053 2011-07-07 Richard Henderson <rth@redhat.com>
14054
14055 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
14056 dwarf2out_frame_init.
14057
14058 2011-07-07 Eric Botcazou <ebotcazou@adacore.com>
14059
14060 * gcc-interface/misc.c (gnat_init): Tweak previous change.
14061
14062 2011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
14063
14064 PR target/39150
14065 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
14066
14067 2011-07-06 Richard Guenther <rguenther@suse.de>
14068
14069 * gcc-interface/misc.c (gnat_init): Merge calls to
14070 build_common_tree_nodes and build_common_tree_nodes_2.
14071 Re-initialize boolean_false_node.
14072
14073 2011-07-02 Eric Botcazou <ebotcazou@adacore.com>
14074 Olivier Hainque <hainque@adacore.com>
14075 Nicolas Setton <setton@adacore.com>
14076
14077 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
14078 the type according to the ARTIFICIAL_P parameter.
14079 (create_type_decl): Likewise.
14080 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
14081
14082 2011-07-01 Eric Botcazou <ebotcazou@adacore.com>
14083
14084 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
14085 (gnatbind): Likewise.
14086
14087 2011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
14088
14089 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
14090
14091 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
14092
14093 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
14094 local variable throughout. Remove useless call to Base_Type.
14095 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
14096 Take it also into account for the volatileness of the field. Set the
14097 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
14098
14099 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
14100
14101 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
14102 on a dereference built for a by-ref object if it has an address clause.
14103
14104 2011-06-18 Eric Botcazou <ebotcazou@adacore.com>
14105
14106 * einfo.ads (Address_Taken): Document use for the second argument of
14107 Asm_Input and Asm_Output attributes.
14108 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
14109 argument is an entity name, then set Address_Taken on it.
14110 <Attribute_Asm_Output>: Likewise.
14111 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
14112 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
14113 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
14114 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
14115
14116 2011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
14117
14118 PR middle-end/46500
14119 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
14120
14121 2011-06-14 Joseph Myers <joseph@codesourcery.com>
14122
14123 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
14124 (ada/utils.o): Update dependencies.
14125 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
14126 ../../../libcpp/libcpp.a.
14127 * gcc-interface/utils.c: Include common/common-target.h.
14128 (process_attributes): Use targetm_common.have_named_sections.
14129
14130 2011-06-07 Richard Guenther <rguenther@suse.de>
14131
14132 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
14133 set_sizetype.
14134
14135 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
14136
14137 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
14138 TREE_THIS_NOTRAP flag.
14139
14140 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
14141
14142 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
14143 Fix thinko.
14144
14145 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
14146
14147 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
14148 constants whose full view has discriminants specially.
14149
14150 2011-06-06 Eric Botcazou <ebotcazou@adacore.com>
14151
14152 * gcc-interface/utils.c: Include diagnostic.h.
14153 (gnat_write_global_declarations): Output debug information for all
14154 global type declarations before finalizing the compilation unit.
14155 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
14156
14157 2011-05-25 Jakub Jelinek <jakub@redhat.com>
14158
14159 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
14160
14161 2011-05-25 Kai Tietz <ktietz@redhat.com>
14162
14163 * adaint.c (__gnat_to_canonical_file_list_next): Use array
14164 initialization instead of const/none-const pointer assignment.
14165
14166 2011-05-24 Joseph Myers <joseph@codesourcery.com>
14167
14168 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
14169 $(EXTRA_GNAT1_OBJS).
14170 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
14171 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
14172 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
14173 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
14174 libcommon-target.a instead of prefix.o.
14175
14176 2011-05-21 Joseph Myers <joseph@codesourcery.com>
14177
14178 PR ada/49097
14179 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
14180
14181 2011-05-20 Joseph Myers <joseph@codesourcery.com>
14182
14183 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
14184 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
14185 instead of version.o.
14186
14187 2011-05-18 Kai Tietz <ktietz@redhat.com>
14188
14189 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
14190 boolean_false_node instead of integer_zero_node.
14191 (convert_with_check): Likewise.
14192 * gcc-interface/decl.c (choices_to_gnu): Likewise.
14193
14194 2011-05-12 Eric Botcazou <ebotcazou@adacore.com>
14195
14196 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
14197 type of the parameter is an unconstrained array, convert the actual to
14198 the type of the formal in the In Out and Out cases as well.
14199
14200 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
14201
14202 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
14203 call build_function_type_array or build_varargs_function_type_array
14204 instead.
14205 (create_subprog_type): Don't call build_function_type; call
14206 build_function_type_vec instead.
14207
14208 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
14209
14210 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
14211 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
14212 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
14213
14214 2011-05-07 Eric Botcazou <ebotcazou@adacore.com>
14215
14216 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
14217
14218 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
14219 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
14220
14221 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
14222
14223 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
14224
14225 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
14226
14227 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
14228 instead of accessing TYPE_ARG_TYPES directly.
14229 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
14230
14231 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
14232
14233 PR ada/48844
14234 * gcc-interface/gigi.h (get_variant_part): Declare.
14235 * gcc-interface/decl.c (get_variant_part): Make global.
14236 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
14237 types have the same constant size, are record types and T1 has a
14238 variant part while T2 doesn't.
14239
14240 2011-05-05 Eric Botcazou <ebotcazou@adacore.com>
14241
14242 * gcc-interface/utils.c (begin_subprog_body): Do not call
14243 get_pending_sizes.
14244 (end_subprog_body): Likewise.
14245
14246 2011-05-04 Richard Guenther <rguenther@suse.de>
14247
14248 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
14249 int_const_binop.
14250 (pos_to_constructor): Likewise.
14251
14252 2011-05-03 Nathan Froyd <froydnj@codesourcery.com>
14253 Eric Botcazou <ebotcazou@adacore.com>
14254
14255 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
14256 of build_function_type. Adjust calls to...
14257 (build_raise_check): ...this. Do not take a void_tree parameter.
14258 Call build_function_type_list instead of build_function_type.
14259 Fix head comment and swap couple of conditional blocks.
14260
14261 2011-04-30 Eric Botcazou <ebotcazou@adacore.com>
14262
14263 * gnatvsn.ads (Library_Version): Bump to 4.7.
14264 (Current_Year): Bump to 2011.
14265
14266 2011-04-29 Michael Matz <matz@suse.de>
14267
14268 * gcc-interface/misc.c (gnat_handle_option): Set
14269 warn_maybe_uninitialized.
14270
14271 2011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
14272
14273 * gnat_ugn.texi (Complexity Metrics Control): Update link to
14274 the Watson/McCabe paper.
14275
14276 2011-04-23 Jim Meyering <meyering@redhat.com>
14277
14278 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
14279
14280 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
14281
14282 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
14283 onto the new type.
14284
14285 2011-04-22 Eric Botcazou <ebotcazou@adacore.com>
14286
14287 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
14288 parameter.
14289 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
14290 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
14291 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
14292 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
14293 <all>: Do not set flags on the reused DECL node coming from an alias.
14294 Set DECL_IGNORED_P on the DECL node built for subprograms if they
14295 don't need debug info here...
14296 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
14297 (gigi): Adjust calls to create_subprog_decl.
14298 (build_raise_check): Likewise.
14299 (establish_gnat_vms_condition_handler): Likewise.
14300 (Compilation_Unit_to_gnu): Likewise.
14301 (gnat_to_gnu): Likewise.
14302
14303 2011-04-21 Eric Botcazou <ebotcazou@adacore.com>
14304
14305 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
14306 (NO_REORDER_ADAFLAGS): New variable.
14307 (EXTRA_GNATTOOLS): Always define.
14308 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
14309 Clean up and adjust list of files compiled with special options.
14310 * gcc-interface/Make-lang.in: Likewise.
14311 (ada/decl.o): Cosmetical change.
14312 (ada/misc.o): Remove dependency on $(PLUGIN_H).
14313
14314 2011-04-20 Jim Meyering <meyering@redhat.com>
14315
14316 * initialize.c (__gnat_initialize): Remove useless if-before-free.
14317
14318 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
14319
14320 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
14321 $(CFLAGS) on the link line.
14322
14323 2011-04-17 Eric Botcazou <ebotcazou@adacore.com>
14324
14325 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
14326 padded type built for the return type if it is unconstrained.
14327
14328 2011-04-14 Nathan Froyd <froydnj@codesourcery.com>
14329
14330 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
14331
14332 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
14333
14334 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
14335 before calling TREE_CHAIN.
14336 * gcc-interface/misc.c (gnat_init_ts): New function.
14337 (LANG_HOOKS_INIT_TS): Define.
14338
14339 2011-04-12 Martin Jambor <mjambor@suse.cz>
14340
14341 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
14342 instead of cgraph_node.
14343
14344 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
14345
14346 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
14347 alignment on fields of the RETURN type built for the Copy-In Copy-Out
14348 mechanism.
14349
14350 2011-04-08 Eric Botcazou <ebotcazou@adacore.com>
14351
14352 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
14353 of aggregate types that contain a placeholder.
14354
14355 2011-04-08 Nathan Froyd <froydnj@codesourcery.com>
14356
14357 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
14358 TYPE_ARG_TYPES.
14359 (handle_type_generic_attribute): Likewise.
14360
14361 2011-04-04 Eric Botcazou <ebotcazou@adacore.com>
14362
14363 PR ada/47163
14364 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
14365
14366 2011-04-04 Kai Tietz <ktietz@redhat.com>
14367
14368 PR ada/47163
14369 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
14370 to flag value.
14371
14372 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14373
14374 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
14375 type case, do not strip a padding type around the array type.
14376
14377 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14378
14379 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
14380 types.
14381
14382 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14383
14384 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
14385 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
14386 code for -feliminate-unused-debug-types.
14387 (gnat_post_options): Likewise.
14388
14389 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14390
14391 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
14392 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
14393 distinct copy.
14394
14395 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14396
14397 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
14398 DECL_ARTIFICIAL flag on enumeration types.
14399
14400 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14401
14402 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
14403 fat pointer types artificial unconditionally.
14404 <E_Array_Subtype>: Attach the base array type as a parallel type if it
14405 isn't artificial.
14406
14407 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14408
14409 * gcc-interface/gigi.h (get_dummy_type): Declare.
14410 (build_dummy_unc_pointer_types): Likewise.
14411 (finish_fat_pointer_type): Likewise.
14412 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
14413 fat pointer type has been built, complete it in place.
14414 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
14415 and thin pointers. Remove useless variable.
14416 (finish_fat_pointer_type): Make global and move to...
14417 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
14418 (get_dummy_type): New function.
14419 (build_dummy_unc_pointer_types): Likewise.
14420 (gnat_pushdecl): Propage the name to the anonymous variants only.
14421 (update_pointer_to): Only adjust the pointer types in the unconstrained
14422 array case.
14423
14424 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14425
14426 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
14427 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
14428 if this is a Taft amendment type and the full declaration is available.
14429 * gcc-interface/trans.c (process_type): Likewise.
14430 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
14431 (process_freeze_entity): Likewise.
14432 * gcc-interface/utils.c (dummy_global): New static variable.
14433 (gnat_write_global_declarations): If there are types declared as used
14434 at the global level, insert them in the global hash table.
14435
14436 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14437
14438 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
14439 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
14440 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
14441 copy.
14442 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
14443 flag of the type accordingly.
14444 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
14445
14446 2011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14447
14448 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
14449 finalizing types when updating the pointers to the designated type.
14450 <all>: Finalize the deferred types even if we didn't defer processing
14451 of incomplete types in this invocation.
14452
14453 2011-04-01 Olivier Hainque <hainque@adacore.com>
14454 Nicolas Setton <setton@adacore.com>
14455 Eric Botcazou <ebotcazou@adacore.com>
14456
14457 * gcc-interface/misc.c (gnat_descriptive_type): New function.
14458 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
14459
14460 2011-03-28 Kai Tietz <ktietz@redhat.com>
14461
14462 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
14463 Windows targets.
14464 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
14465 * system-mingw.ads (System): Change ZCX_By_Default default to True.
14466
14467 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
14468
14469 2011-03-28 Tristan Gingold <gingold@adacore.com>
14470
14471 PR ada/44431
14472 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
14473 Use ada output of gnatbind.
14474 (ada/b_gnatb.adb): Ditto.
14475 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
14476 (ada.mostlyclean, ada.stage1)
14477 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
14478 (ada.stagefeedback): Adjust.
14479 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
14480 Use ada output of gnatbind.
14481 (b_gnatm.adb): Ditto.
14482 (b_gnatl.o, b_gnatm.o): New rules.
14483
14484 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
14485
14486 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
14487 for the padded type built to support a specified size or alignment.
14488
14489 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
14490
14491 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
14492 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
14493 unconditionally to the end of the unit when the designated type is
14494 limited_with'ed.
14495 <all>: Rename local variable. Attempt to un-defer types only and do it
14496 for limited_with'ed types as well.
14497 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
14498 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
14499 consistently and remove redundant call to finalize_from_with_types.
14500
14501 2011-03-26 Eric Botcazou <ebotcazou@adacore.com>
14502
14503 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
14504 subprograms without a previous spec declared in the same unit.
14505 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
14506 subprograms at the end of the unit instead of at the beginning.
14507 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
14508 isn't public for the special handling of non-inline functions nested
14509 inside inline external functions.
14510
14511 2011-03-25 Jeff Law <law@redhat.com>
14512
14513 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
14514
14515 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
14516
14517 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
14518 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
14519 to compute Set_Size_Depends_On_Discriminant.
14520 (Layout_Type): Call it on array types in back-end layout mode.
14521 * sem_util.adb (Requires_Transient_Scope): Return true for array
14522 types only if the size depends on the value of discriminants.
14523 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
14524 type if the RHS is a call to a function that returns an unconstrained
14525 type with default discriminant.
14526
14527 2011-03-24 Eric Botcazou <ebotcazou@adacore.com>
14528
14529 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
14530 non-conversion to the nominal result type at the end.
14531
14532 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
14533
14534 * gcc-interface/trans.c (create_temporary): New function taken from...
14535 (create_init_temporary): ...here. Call it.
14536 (call_to_gnu): Create the temporary for the return value early, if any.
14537 Create it for a function with copy-in/copy-out parameters if there is
14538 no target; in other cases of copy-in/copy-out, use another temporary.
14539 Push the new binding level lazily. Add and rename local variables.
14540
14541 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
14542
14543 * gcc-interface/decl.c (validate_size): Improve comments and tweak
14544 error message.
14545 (set_rm_size): Likewise.
14546
14547 2011-03-23 Eric Botcazou <ebotcazou@adacore.com>
14548
14549 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
14550 for the padded type built in order to support a specified alignment.
14551 Fix incorrect formatting.
14552
14553 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
14554
14555 PR bootstrap/48216
14556 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
14557
14558 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
14559
14560 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
14561 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
14562 to the end of the list. Adjust recursive call. Rename local variable.
14563 If REORDER is true, reorder components of the record type.
14564 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
14565 components_to_record and adjust the parameter list.
14566
14567 2011-03-21 Eric Botcazou <ebotcazou@adacore.com>
14568
14569 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
14570 disabled, use the variable for bounds of loop iteration scheme.
14571
14572 2011-03-21 Kai Tietz <ktietz@redhat.com>
14573
14574 PR target/12171
14575 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
14576
14577 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
14578
14579 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
14580 out whether the expression is read-only. Short-circuit placeholder
14581 case and rename a couple of local variables.
14582
14583 2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
14584
14585 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
14586 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
14587 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
14588 (convert): Deal with conversions from a smaller form type specially.
14589
14590 2011-02-14 Eric Botcazou <ebotcazou@adacore.com>
14591
14592 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
14593 its argument, except for the special -I- switch.
14594
14595 2011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
14596
14597 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
14598 "Ada Issues".
14599
14600 2011-02-08 Eric Botcazou <ebotcazou@adacore.com>
14601
14602 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
14603
14604 2011-02-03 Eric Botcazou <ebotcazou@adacore.com>
14605
14606 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
14607 GNAT_FORMAL.
14608 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
14609 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
14610 instead of GNAT_FORMAL. Protect the expression against multiple uses.
14611 Do not generate the check directly, instead instantiate the template
14612 check present in the descriptor.
14613 (make_descriptor_field): Move around.
14614 (build_vms_descriptor32): Build a template check in the POINTER field.
14615 (build_vms_descriptor): Remove useless suffixes.
14616 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
14617
14618 2011-01-26 Eric Botcazou <ebotcazou@adacore.com>
14619
14620 PR bootstrap/47467
14621 * targext.c: Include target files if IN_RTS is defined.
14622
14623 2011-01-26 Richard Guenther <rguenther@suse.de>
14624
14625 PR bootstrap/47467
14626 * targext.c: Include config.h.
14627 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
14628 dependency.
14629
14630 2011-01-04 Pascal Obry <obry@adacore.com>
14631 Eric Botcazou <ebotcazou@adacore.com>
14632
14633 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
14634
14635 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
14636
14637 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
14638 end-of-case on the end label and its associated gotos, if any.
14639
14640 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
14641
14642 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
14643 expressions of the parameter cache within the statement group of
14644 the CICO mechanism.
14645
14646 2011-01-04 Olivier Hainque <hainque@adacore.com>
14647 Eric Botcazou <ebotcazou@adacore.com>
14648
14649 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
14650 (set_end_locus_from_node): New function.
14651 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
14652 make and the function end_locus.
14653 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
14654 for the elaboration subprogram.
14655 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
14656 set the end_locus of the expression as well.
14657
14658 2011-01-04 Eric Botcazou <ebotcazou@adacore.com>
14659
14660 PR ada/47131
14661 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
14662 variables that are referenced in exception handlers volatile.
14663
14664
14665 \f
14666 Copyright (C) 2011 Free Software Foundation, Inc.
14667
14668 Copying and distribution of this file, with or without modification,
14669 are permitted in any medium without royalty provided the copyright
14670 notice and this notice are preserved.