]> gcc.gnu.org Git - gcc.git/blame - gcc/ada/ChangeLog
[multiple changes]
[gcc.git] / gcc / ada / ChangeLog
CommitLineData
bdf69d33
AC
12011-11-21 Ed Schonberg <schonberg@adacore.com>
2
3 * exp_ch6.adb (Expand_Actuals): In Ada 2012, a function call
4 with out parameters may generate assignments to force constraint
5 checks. These checks must be properly placed in the code after the
6 declaration or statement that contains the call.
7
82011-11-21 Fedor Rybin <frybin@adacore.com>
9
10 * gnat_ugn.texi: Adding info on current gnattest limitations an
11 support of -X option.
12
132011-11-21 Robert Dewar <dewar@adacore.com>
14
15 * a-cfdlli.adb, a-cbdlli.adb: Minor reformatting.
16
03e1048e
AC
172011-11-20 Robert Dewar <dewar@adacore.com>
18
19 * exp_ch6.adb, exp_util.adb: Minor reformatting
20
212011-11-20 Eric Botcazou <ebotcazou@adacore.com>
22
23 * sinfo.ads (Reference): Document that it is OK to set
24 Is_Known_Non_Null on a temporary initialized to a N_Reference
25 node.
26
272011-11-20 Matthew Heaney <heaney@adacore.com>
28
29 * a-cbdlli.adb, a-cfdlli.adb (Move): Set Last component to 0
30 for Source list.
31
74cab21a
EB
322011-11-20 Eric Botcazou <ebotcazou@adacore.com>
33
34 * exp_ch6.adb (Make_Build_In_Place_Call_In_Assignment):
35 Declare NEW_EXPR local variable and attach the
36 temporary to it. Set Is_Known_Non_Null on the temporary.
37 (Make_Build_In_Place_Call_In_Object_Declaration): Likewise.
38 * exp_util.adb (Remove_Side_Effects): Set Is_Known_Non_Null on
39 the temporary created to hold the 'Reference of the expression,
40 if any.
41 * checks.adb (Install_Null_Excluding_Check): Bail out for the
42 Get_Current_Excep.all.all idiom generated by the expander.
43
088b91c7
EB
442011-11-20 Eric Botcazou <ebotcazou@adacore.com>
45
46 * gcc-interface/trans.c (struct language_function): Add GNAT_RET.
47 (f_gnat_ret): New macro.
48 (struct nrv_data): Add GNAT_RET.
49 (finalize_nrv_unc_r): New helper function.
50 (finalize_nrv): Add GNAT_RET parameter. Copy it into DATA. If the
51 function returns unconstrained, use finalize_nrv_unc_r as callback.
52 (return_value_ok_for_nrv_p): Test the alignment of RET_OBJ only if
53 RET_OBJ is non-null.
54 (Subprogram_Body_to_gnu): Pass GNAT_RET to finalize_nrv.
55 (gnat_to_gnu) <N_Return_Statement>: In the return-unconstrained case,
56 if optimization is enabled, record candidates for the Named Return
57 Value optimization.
58
592011-11-20 Eric Botcazou <ebotcazou@adacore.com>
0d24bf76
EB
60
61 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Add comment.
62 (gnat_to_gnu) <N_Return_Statement>: Add 'else' to avoid doing a useless
63 test. Tweak default case.
64 <N_Goto_Statement>: Use better formatting.
65 * gcc-interface/utils2.c (maybe_wrap_malloc): Use INIT_EXPR instead of
66 MODIFY_EXPR to initialize the storage.
67 (build_allocator): Likewise.
68
b1a785fb
EB
692011-11-20 Eric Botcazou <ebotcazou@adacore.com>
70
71 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Type>: Adjust
72 call to components_to_record.
73 (components_to_record): Add FIRST_FREE_POS parameter. For the variant
74 part, reuse enclosing union even if there is a representation clause
75 on the Unchecked_Union. If there is a variant part, compute the new
76 first free position, if any. Adjust call to self. Use a single field
77 directly only if it hasn't got a representation clause or is placed at
78 offset zero. Create the variant part at offset 0 if all the fields
79 down to this level have a rep clause. Do not chain the variant part
80 immediately and adjust downstream.
81 Do not test ALL_REP before moving the fields without rep clause to the
82 previous level. Call create_rep_part to create the REP part and force
83 a minimum size on it if necessary. Do not chain it immediately.
84 Create a fake REP part if there are fields without rep clause that need
85 to be laid out starting from FIRST_FREE_POS.
86 At the end, chain the REP part and then the variant part.
87 (create_rep_part): New function.
88 (get_rep_part): Minor tweak.
89 * gcc-interface/utils.c (tree_code_for_record_type): Minor tweak.
90
590175d2
IS
912011-11-18 Iain Sandoe <iains@gcc.gnu.org>
92
93 PR target/50678
a6b7e723
EB
94 * init.c (__gnat_error_handler) [Darwin]: Move workaround to the
95 bug filed as radar #10302855 from __gnat_error_handler to...
96 (__gnat_adjust_context_for_raise) [Darwin]: ...here. New function.
590175d2 97 (HAVE_GNAT_ADJUST_CONTEXT_FOR_RAISE) [Darwin]: Define.
590175d2 98
1e1ae0af
TG
992011-11-18 Tristan Gingold <gingold@adacore.com>
100 Iain Sandoe <iains@gcc.gnu.org>
101
102 PR target/49992
103 * mlib-tgt-specific-darwin.adb (Archive_Indexer_Options): Remove.
a6b7e723 104 * gcc-interface/Makefile.in (darwin): Remove ranlib special-casing.
1e1ae0af 105
5f41422f
IS
1062011-11-12 Iain Sandoe <iains@gcc.gnu.org>
107
108 * gcc-interface/Makefile.in (stamp-gnatlib-$(RTSDIR)): Don't link
109 s-oscons.ads.
110 (OSCONS_CPP, OSCONS_EXTRACT): New.
a6b7e723
EB
111 (./bldtools/oscons/xoscons): New target.
112 ($(RTSDIR)/s-oscons.ads): Likewise.
113 (gnatlib): Depend on $(RTSDIR)/s-oscons.ads.
5f41422f
IS
114 * gcc-interface/Make-lang.in (ada/s-oscons.ads) Remove as dependency.
115 * Make-generated.in: Remove machinery to generate xoscons and
116 ada/s-oscons.ads.
117
033ba5bf
EB
1182011-11-10 Eric Botcazou <ebotcazou@adacore.com>
119
120 * fe.h (Serious_Errors_Detected): New macro.
121 * gcc-interface/gigi.h (build_atomic_load): Declare.
122 (build_atomic_store): Likewise.
123 * gcc-interface/trans.c (atomic_sync_required_p): New predicate.
124 (call_to_gnu): Add ATOMIC_SYNC parameter. Use local variable.
125 Build an atomic load for an In or In Out parameter if needed.
126 Build an atomic store for the assignment of an Out parameter if needed.
127 Build an atomic store to the target if ATOMIC_SYNC is true.
128 (present_in_lhs_or_actual_p): New predicate.
129 (gnat_to_gnu) <N_Identifier>: Build an atomic load if needed.
130 <N_Explicit_Dereference>: Likewise.
131 <N_Indexed_Component>: Likewise.
132 <N_Selected_Component>: Likewise.
133 <N_Assignment_Statement>: Adjust call to call_to_gnu.
134 Build an atomic store to the LHS if needed.
135 <N_Function_Call>: Adjust call to call_to_gnu.
136 * gcc-interface/utils2.c: Include toplev.h.
137 (resolve_atomic_size): New static function.
138 (build_atomic_load): New function.
139 (build_atomic_store): Likewise.
140 * gcc-interface/Make-lang.in (ada/utils2.o): Add toplev.h.
141
b5bf3335
AC
1422011-11-07 Olivier Hainque <hainque@adacore.com>
143
144 * sigtramp-ppcvxw.c: Add general comments.
145 (CFI_COMMON_REGS): Remove rule for r1, as in other unwinders. Add
146 rules for r2 to r13, plus CTR and XER.
147 (CFA_REG): New, register number used to hold the local CFA.
148 (CFI_DEF_CFA, SIGTRAMP_BODY): Use it.
149 Make that 15, not 14, with documentation.
150 (TCR): Undef before definition, preventing conflict with reg number in
151 VxWorks headers.
152
1532011-11-07 Robert Dewar <dewar@adacore.com>
154
155 * exp_util.ads, exp_alfa.adb, a-cohama.adb, a-cohama.ads, sem_ch4.adb,
156 aspects.ads, exp_ch8.adb, exp_ch8.ads, atree.ads: Minor reformatting.
157 * gcc-interface/Make-lang.in: Update dependencies.
158
1592011-11-07 Ed Schonberg <schonberg@adacore.com>
160
161 * exp_ch6.adb: A tagged type is a legal actual for an aliased
162 formal.
163
1642011-11-07 Pascal Obry <obry@adacore.com>
165
166 * g-socket.adb, g-socket.ads: Minor reformatting.
167
1682011-11-07 Robert Dewar <dewar@adacore.com>
169
170 * sem_res.adb (Resolve_Actuals): Minor error message improvement.
171
1722011-11-07 Robert Dewar <dewar@adacore.com>
173
174 * gnat_ugn.texi: Add discussion of default mode handling of
175 source representation with no -gnatW option given, in particular
176 noting that NEL (next line) is not recognized in this context.
177
9ee76313
AC
1782011-11-07 Yannick Moy <moy@adacore.com>
179
180 * sem_util.adb (Note_Possible_Modification): In Alfa mode,
181 generate a reference for a modification even when the modification
182 does not come from source.
183
1842011-11-07 Ed Schonberg <schonberg@adacore.com>
185
186 * exp_ch5.adb (Expand_Iterator_Loop): For the "of" iterator form,
187 use the indexing attributes rather than the Element function,
188 to obtain variable references.
189 * sem_ch4.adb (Try_Container_Indexing): Code cleanup. Use
190 Find_Aspect rather than iterating over representation
191 items. Improve error message.
192 * a-cohama.adb, a-cohama.ads Update to latest RM, with two versions
193 of Reference functions.
194
7b7a0c2b
AC
1952011-11-07 Yannick Moy <moy@adacore.com>
196
197 * sem_util.adb (Unique_Entity): For a parameter on a subprogram
198 body that has a corresponding parameter on the subprogram
199 declaration, define the unique entity as being the declaration
200 one.
201
2022011-11-07 Ed Schonberg <schonberg@adacore.com>
203
204 * sem_ch6.adb (Analyze_Return_Type): In Ada 2012 mode, if the
205 return type of a function is the class-wide type of an incomplete
206 type T, T can be a Taft-amendment type and does not have to be
207 completed in the current private part.
208
2092011-11-07 Ed Schonberg <schonberg@adacore.com>
210
211 * aspects.ads (Inherited_Aspect): Map that indicates type aspects
212 that are inherited by default, and apply to the class-wide type
213 as well.
214 * aspects.adb (Find_Aspect): If the entity is class-wide and the
215 aspect is inherited, use the aspect of the specific type.
216
cc570be6
AC
2172011-11-07 Hristian Kirtchev <kirtchev@adacore.com>
218
219 * exp_alfa.adb: Remove with and use clause for
220 Exp_Ch8. Add with and use clause for Exp_Util.
221 Remove local constant Disable_Processing_Of_Renamings.
222 (Expand_Alfa_N_Object_Renaming_Declaration): The expansion of
223 object renamings has been reenabled.
224 (Expand_Possible_Renaming):
225 The expansion of identifier and expanded names has been
226 reenabled. Perform the substitutions only for entities that
227 denote an object.
228 * exp_ch8.ads, exp_ch8.adb (Evaluate_Name): Moved to Exp_Util.
229 * exp_util.adb (Evaluate_Name): Moved from Exp_Ch8.
230 (Remove_Side_Effects): Alphabetize local variables. Add a guard
231 to avoid the infinite expansion of an expression in Alfa mode. Add
232 processing for function calls in Alfa mode.
233 * exp_util.ads (Evaliate_Name): Moved from Exp_Ch8.
234
2352011-11-07 Ed Schonberg <schonberg@adacore.com>
236
237 * freeze.adb (Freeze_Entity): If the entity is an access to
238 subprogram whose designated type is itself a subprogram type,
239 its own return type must be decorated with size information.
240
b6d185a5
AC
2412011-11-04 Arnaud Charlet <charlet@adacore.com>
242
243 * gcc-interface/Make-lang.in: Update dependencies.
244
1adaea16
AC
2452011-11-04 Robert Dewar <dewar@adacore.com>
246
247 * sprint.adb (Sprint_Node_Actual, case Qualified_Expression):
248 Avoid junk semicolon after argument of machine code Asm operand.
249
2502011-11-04 Robert Dewar <dewar@adacore.com>
251
252 * exp_ch11.adb (Generate_Push_Pop): Inhibit push/pop nodes in
253 CodePeer mode or if restriction No_Exception_Handlers is present.
254 * exp_ch6.adb (Expand_N_Subprogram_Body): (Inhibit push/pop
255 nodes in CodePeer mode or if restriction No_Exception_Handlers
256 is present.
257
2582011-11-04 Robert Dewar <dewar@adacore.com>
259
260 * s-tassta.adb, atree.ads, errout.adb, sinput.adb: Minor reformatting.
261
2622011-11-04 Ed Schonberg <schonberg@adacore.com>
263
264 * sem_ch6.adb (Analyze_Subprogram_Specification): The
265 specification is legal if it is a function that returns an
266 abstract type, if it comes from an attribute renaming of a stream
267 attribute of an abstract type.
268
2692011-11-04 Gary Dismukes <dismukes@adacore.com>
270
271 * exp_util.adb (Is_Possibly_Unaligned_Object): In case of indexed
272 components, check whether recursively check whether the prefix
273 denotes an unaligned object.
274
2752011-11-04 Ed Schonberg <schonberg@adacore.com>
276
277 * sem_prag.adb (Analyze_Pragma, case Debug): The argument of
278 the pragma is legal if it is an expanded name that denotes a
279 procedure that be can called without parameters.
280
2812011-11-04 Eric Botcazou <ebotcazou@adacore.com>
282
283 * gnat_ugn.texi (Performance Considerations) <Vectorization
284 of loops>: New sub-section. <Other Optimization Switches>:
285 Minor tweak.
286
4c9fe6c7
AC
2872011-11-04 Robert Dewar <dewar@adacore.com>
288
289 * gnat_rm.texi: Minor reformatting.
290
2912011-11-04 Matthew Heaney <heaney@adacore.com>
292
293 * a-convec.adb, a-coinve.adb, a-cobove.adb (Merge): Raise PE
294 when Target and Source denote same non-empty object
295 * a-cdlili.adb, a-cidlli.adb, a-cbdlli.adb (Merge): Ditto
296
2972011-11-04 Robert Dewar <dewar@adacore.com>
298
299 * exp_attr.adb: Minor reformatting.
300
3012011-11-04 Ed Schonberg <schonberg@adacore.com>
302
303 * exp_ch5.adb (Expand_Assign_Record): Do not generate a
304 discriminant assignment within an initialization proc if the
305 record is an unchecked union, as it can only come from the
306 initialization of an unchecked union component.
307
3082011-11-04 Robert Dewar <dewar@adacore.com>
309
310 * gnat_ugn.texi: Minor reformatting.
311
3122011-11-04 Robert Dewar <dewar@adacore.com>
313
314 * par-labl.adb (Rewrite_As_Loop): Generate info msg rather than
315 warning message.
316
3172011-11-04 Robert Dewar <dewar@adacore.com>
318
319 * exp_ch4.adb: Minor code reorganization (remove junk obsolete
320 var Save_Space).
321
6ec084f3
HK
3222011-11-04 Hristian Kirtchev <kirtchev@adacore.com>
323
324 * exp_alfa.adb: Add local constant
325 Disable_Processing_Of_Renamings;
326 (Expand_Alfa_N_Object_Renaming_Declaration): Disable
327 the name evaluation of object renamings for now.
328 (Expand_Potential_Renaming): Do not perform the substitution
329 for now.
330 * exp_util.adb (Remove_Side_Effects): Remove processing for
331 functions with side effects in Alfa mode.
332
73fe1679
AC
3332011-11-04 Gary Dismukes <dismukes@adacore.com>
334
335 * bindgen.adb (Gen_Elab_Calls): In the case
336 of the AAMP target, set elaboration entities to 1 rather than
337 incrementing.
338
3392011-11-04 Ed Schonberg <schonberg@adacore.com>
340
341 * sem_ch10.adb (Install_Limited_With_Unit): To establish the
342 proper entities on the ancestors of a child unit that appear
343 in a limited_with clause, follow the unit links because the
344 units are not analyzed and scope information is incomplete.
345
3462011-11-04 Eric Botcazou <ebotcazou@adacore.com>
347
348 * exp_ch4.adb (Expand_N_Selected_Component): Refine code
349 setting the Atomic_Sync_Required flag to detect one more case.
350 * exp_util.adb (Activate_Atomic_Synchronization): Refine code
351 setting the Atomic_Sync_Required flag to exclude more cases,
352 depending on the parent of the node to be examined.
353
3542011-11-04 Bob Duff <duff@adacore.com>
355
356 * g-excact.adb: Minor: use named notation.
357
3582011-11-04 Ed Schonberg <schonberg@adacore.com>
359
360 * sem_ch5.adb: Improve error messages for illegal iterators.
361
b2ab8c33
AC
3622011-11-04 Hristian Kirtchev <kirtchev@adacore.com>
363
364 * exp_alfa.adb: Add with and use clauses for Exp_Ch8 and
365 Sem_Util.
366 (Expand_Alfa): Alphabetize cases on first choice. Add
367 processing for object renaming declarations, identifiers and
368 expanded names.
369 (Expand_Alfa_N_In): Remove useless return.
370 (Expand_Alfa_N_Object_Renaming_Declaration): New routine.
371 (Expand_Potential_Renaming): New routine.
372 * exp_ch8.adb (Evaluate_Name): Moved to the top level.
373 (Expand_N_Object_Declaration): Alphabetize local variables. Move
374 Evaluate_Name out to the top level.
375 * exp_ch8.ads (Evaluate_Name): Moved from body to package spec.
376 * exp_util.adb (Remove_Side_Effects): Add processing for
377 functions with side effects in Alfa mode.
378
3792011-11-04 Hristian Kirtchev <kirtchev@adacore.com>
380
381 * gnat_rm.texi: Add entries for
382 restrictions No_Relative_Delay, No_Requeue_Statements and
383 No_Stream_Optimizations.
384
3852011-11-04 Ed Schonberg <schonberg@adacore.com>
386
387 * sem_ch4.adb: Set type of entity in prefixed call, for
388 completeness in a generic context.
389
4c318253
AC
3902011-11-04 Yannick Moy <moy@adacore.com>
391
392 * sem_prag.adb: Minor refactoring (renaming of a parameter).
393
3942011-11-04 Robert Dewar <dewar@adacore.com>
395
396 * atree.ads: Minor reformatting.
397
3982011-11-04 Robert Dewar <dewar@adacore.com>
399
400 * checks.adb (Atomic_Synchronization_Disabled): Check -gnatd.d
401 and -gnatd.e here
402 * exp_ch2.adb (Expand_Entity_Reference): Use
403 Activate_Atomic_Synchronization
404 * exp_ch4.adb (Expand_N_Explicit_Dereference): Use
405 Activate_Atomic_Synchronization (Expand_N_Indexed_Compoonent):
406 Activate_Atomic_Synchronization (Expand_N_Selected_Component):
407 Use Activate_Atomic_Synchronization
408 * exp_util.ads, exp_util.adb (Activate_Atomic_Synchronization): New
409 procedure.
410 * sinfo.ads, sinfo.adb (Atomic_Sync_Required): Can now apply to
411 N_Selected_Component node
412
37765e95
RD
4132011-11-04 Robert Dewar <dewar@adacore.com>
414
415 * sem_prag.adb, atree.ads, prj-env.adb, prj-env.ads: Minor reformatting.
416
8c18a165
AC
4172011-11-04 Yannick Moy <moy@adacore.com>
418
419 * atree.adb, atree.ads (Set_Original_Node): New set procedure.
420 * sem_ch13.adb (Analyze_Aspect_Specifications/Pre_Post_Aspects):
421 In ASIS mode, no splitting of aspects between conjuncts.
422 (Analyze_Aspect_Specifications/Aspect_Test_Case): Make pragma
423 expressions refer to the original aspect expressions through
424 the Original_Node link. This is used in semantic analysis for
425 ASIS mode, so that the original expression also gets analyzed.
426 * sem_prag.adb (Preanalyze_TC_Args,
427 Check_Precondition_Postcondition,
428 Analyze_Pragma/Pragma_Test_Case): In ASIS mode, for a pragma
429 generated from a source aspect, also analyze the original aspect
430 expression.
431 (Check_Expr_Is_Static_Expression): New procedure
432 similar to existing procedure Check_Arg_Is_Static_Expression,
433 except called on expression inside pragma.
434
4352011-11-04 Tristan Gingold <gingold@adacore.com>
436
437 * prj-env.adb, prj-env.ads (Find_Name_In_Path): New function, from
438 Find_Project.Try_Path_Name.
439 (Find_Project): Use Find_Name_In_Path to implement Try_Path_Name.
440
4412011-11-04 Eric Botcazou <ebotcazou@adacore.com>
442
443 * s-atocou.ads (Atomic_Counter): Remove redundant pragma Volatile.
444
4452011-11-04 Pascal Obry <obry@adacore.com>
446
447 * projects.texi: Add short description for qualifiers aggregate
448 and aggregate library.
449
4502011-11-04 Matthew Heaney <heaney@adacore.com>
451
452 * Makefile.rtl, impunit.adb: Added a-cogeso.ad[sb]
453 * a-cgaaso.adb: Replaced implementation with instantiation
454 of Generic_Sort.
455 * a-cogeso.ad[sb] This is the new Ada 2012 unit
456 Ada.Containers.Generic_Sort
457
5972791c
AC
4582011-11-04 Robert Dewar <dewar@adacore.com>
459
460 * exp_ch2.adb (Expand_Entity_Reference): Do not set
461 Atomic_Sync_Required for the case of a prefix of an attribute.
462 * exp_ch4.adb (Expand_N_Explicit_Dereference): May require
463 atomic synchronization
464 (Expand_N_Indexed_Component): Ditto.
465 (Expand_B_Selected_Component): Ditto.
466 * sem_prag.adb (Process_Suppress_Unsuppress):
467 Disable/Enable_Atomic_Synchronization can now occur for array
468 types with pragma Atomic_Components.
469 * sinfo.ads, sinfo.adb (Atomic_Sync_Required): Can now occur on
470 N_Explicit_Dereference nodes and on N_Indexed_Component nodes.
471
4722011-11-04 Gary Dismukes <dismukes@adacore.com>
473
474 * gnat_ugn.texi: Editorial corrections for gnattest section.
475
8751a35c
RD
4762011-11-04 Robert Dewar <dewar@adacore.com>
477
478 * sem_prag.adb: Minor reformatting.
479 * gnat_rm.texi: Update documentation for pragma Warnings (Off,
480 "***") usage.
481 * exp_ch2.adb (Expand_Entity_Reference): Only set
482 Atomic_Sync_Required on entities that are variables. Doesn't
483 make any sense on anything else.
484
fb5d63c6
RD
4852011-11-04 Robert Dewar <dewar@adacore.com>
486
487 * exp_ch2.adb (Expand_Entity_Reference): Extend handling of
488 atomic sync to type case.
489 * sem_prag.adb (Process_Suppress_Unsuppress): Atomic Sync can
490 apply to types.
491
a51cd0ec 4922011-11-04 Robert Dewar <dewar@adacore.com>
25ec1790 493
a51cd0ec
AC
494 * sem_warn.adb (Warn_On_Useless_Assignment): More accurate test
495 for call vs assign.
496 * gcc-interface/Make-lang.in: Update dependencies.
497
4982011-11-04 Robert Dewar <dewar@adacore.com>
499
500 * sem_prag.adb: Detect more cases of Long_Float inconsistencies at
501 compile time.
502
5032011-11-04 Matthew Heaney <heaney@adacore.com>
504
505 * Makefile.rtl, impunit.adb: Added a-sfecin.ads,
506 * a-sfhcin.ads, a-sflcin.ads, a-sbecin.ad[sb], a-sbhcin.ad[sb],
507 a-sblcin.ad[sb], a-suecin.ad[sb], a-suhcin.ad[sb], a-sulcin.ad[sb]
508 * a-sfecin.ads, a-sfhcin.ads, a-sflcin.ads, a-sbecin.ad[sb],
509 a-sbhcin.ad[sb], a-sblcin.ad[sb], a-suecin.ad[sb], a-suhcin.ad[sb],
510 a-sulcin.ad[sb]: New files.
511
5122011-11-04 Geert Bosch <bosch@adacore.com>
513
514 * i-forbla-unimplemented.ads, s-gecola.adb, s-gecola.ads,
515 s-gerebl.adb, s-gerebl.ads, i-forbla.adb, i-forbla.ads,
516 i-forlap.ads, i-forbla-darwin.adb, s-gecobl.adb, s-gecobl.ads,
517 s-gerela.adb, s-gerela.ads: Remove partial interface to BLAS/LAPACK.
518 * gcc-interface/Makefile.in: Remove libgnala and related objects.
25ec1790 519
a31945d7
AC
5202011-11-04 Matthew Heaney <heaney@adacore.com>
521
522 * a-cdlili.ad[sb], a-cidlli.ad[sb], a-coorse.ad[sb], a-ciorse.ad[sb],
523 a-coorma.ad[sb], a-ciorma.ad[sb], a-coormu.ad[sb], a-ciormu.ad[sb],
524 a-cohama.ad[sb], a-cihama.ad[sb], a-cohase.ad[sb], a-cihase.ad[sb],
525 a-convec.ad[sb], a-coinve.ad[sb] (Assign, Copy): New operations
526 added to package.
527
a51cd0ec
AC
5282011-11-04 Eric Botcazou <ebotcazou@adacore.com>
529
530 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Do not assert
531 that the type of the parameters isn't dummy in type_annotate_only mode.
532
a31945d7
AC
5332011-11-04 Robert Dewar <dewar@adacore.com>
534
535 * sem_ch12.adb: Minor reformatting
536
5372011-11-04 Gary Dismukes <dismukes@adacore.com>
538
539 * bindgen.adb (Gen_Elab_Calls): In the case of the AAMP target,
540 initialize elaboration entities to zero when specs are processed.
541
a53f3523
IS
5422011-10-28 Iain Sandoe <iains@gcc.gnu.org>
543 Eric Botcazou <ebotcazou@adacore.com>
544
545 PR target/50678
be7552fc
EB
546 * init.c (__gnat_error_handler) [Darwin]: Apply a work-around to the
547 bug filed as radar #10302855 (inconsistent unwind data for sigtramp).
a53f3523 548
0de82be5
EB
5492011-10-28 Eric Botcazou <ebotcazou@adacore.com>
550
551 PR ada/50842
552 * gcc-interface/Makefile.in (SYMDEPS): Delete.
553 (LIBICONV): New variable.
554 (LIBICONV_DEP): Likewise.
555 (LIBS): Add $(LIBICONV).
556 (LIBDEPS): Add $(LIBICONV_DEP).
557 (EXTRA_GNATTOOLS_OBJS): Merge into...
558 (TOOLS_LIBS): ...this. Add $(LIBICONV).
e1e5852c 559
1586f8a3
EB
5602011-10-26 Eric Botcazou <ebotcazou@adacore.com>
561
562 * gcc-interface/decl.c (elaborate_expression_1): Add EXPR_PUBLIC_P local
563 variable. Always create the elaboration variable, if any, as constant.
564
e1e5852c
EB
5652011-10-26 Eric Botcazou <ebotcazou@adacore.com>
566
567 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Subtype>: Try to
568 make a packable type for fields of union types as well.
569 <is_type>: Use RECORD_OR_UNION_TYPE_P predicate.
570 (gnat_to_gnu_component_type): Try to make a packable type for fields
571 of union types as well.
572 (make_packable_type): Use RECORD_OR_UNION_TYPE_P predicate.
573 (maybe_pad_type): Try to make a packable type for fields of union types
574 as well.
575 (gnat_to_gnu_field): Likewise.
576 (is_variable_size): Use RECORD_OR_UNION_TYPE_P predicate.
577 (set_rm_size): Likewise.
578 (rm_size): Likewise.
579 * gcc-interface/misc.c (gnat_type_max_size): Likewise.
580 * gcc-interface/trans.c (add_decl_expr): Likewise.
581 * gcc-interface/utils.c (finish_record_type): Likewise.
582 * gcc-interface/utils2.c (build_simple_component_ref): Likewise.
583
0025cb63
EB
5842011-10-26 Eric Botcazou <ebotcazou@adacore.com>
585
586 * gcc-interface/decl.c (gnat_to_gnu_field): Always check components
587 declared as atomic. Move around conditionally executed code.
588
b3c33641
AC
5892011-10-24 Robert Dewar <dewar@adacore.com>
590
be7552fc 591 * sem.adb (Initialize): Fix bug that blew up if called a second time.
b3c33641
AC
592
5932011-10-24 Robert Dewar <dewar@adacore.com>
594
595 * tb-alvxw.c, tracebak.c, expect.c, initflt.c, tb-alvms.c,
596 tb-ivms.c, tb-gcc.c: Update headers to GPL 3.
597
5982011-10-24 Robert Dewar <dewar@adacore.com>
599
600 * sem_prag.adb (Analyze_Pragma, case Debug): Give proper pragma
601 name in error msg.
602
6032011-10-24 Hristian Kirtchev <kirtchev@adacore.com>
604
be7552fc 605 * gnat_rm.texi: Add an entry for restriction No_Finalization.
b3c33641
AC
606
6072011-10-24 Ed Schonberg <schonberg@adacore.com>
608
609 * sem_ch12.adb (Insert_Freeze_Node_For_Instance): If the
610 current instance is within the one that contains the generic,
611 the freeze node for the current one must appear in the current
612 declarative part. Ditto if the current instance is within another
613 package instance. In both of these cases the freeze node of the
614 previous instance is not relevant.
615
6162011-10-24 Gary Dismukes <dismukes@adacore.com>
617
618 * switch-m.adb (Normalize_Compiler_Switches): Add recognition
619 of AAMP-specific switches -univ and -aamp_target.
620
6212011-10-24 Robert Dewar <dewar@adacore.com>
622
623 * a-tienau.adb (Put): Deal properly with limited line length.
624
6252011-10-24 Robert Dewar <dewar@adacore.com>
626
627 * sem_warn.adb, sem_ch12.adb: Minor reformatting.
628
30e1709c 6292011-10-24 Tristan Gingold <gingold@adacore.com>
8263e17a
TG
630
631 * gcc-interface/Makefile.in: Use GNU ld switches to generate map files
632 on AIX.
633
12b4d338
AC
6342011-10-24 Ed Schonberg <schonberg@adacore.com>
635
636 * sem_ch12.adb (Earlier): make available globally. If both
637 nodes have the same sloc, the freeze node that does not come
638 from source is the later one.
639 (True_Parent): Make available globally.
640 (Previous_Instance): Subsidiary of
641 Insert_Freeze_Node_For_Instance, to check whether the generic
642 parent of the current instance is declared within a previous
643 instance in the same unit or declarative part, in which case the
644 freeze nodes of both instances must appear in order to prevent
645 elaboration problems in gigi.
646 * sem_ch12.adb (Insert_Freeze_Node_For_Instance): A stub is a
647 freeze point, and the freeze node of a preceding instantiation
648 must be inserted before it.
649
6502011-10-24 Robert Dewar <dewar@adacore.com>
651
652 * checks.ads, checks.adb: Add handling of Synchronization_Check
653 * debug.adb: Add doc for -gnatd.d and -gnatd.e (disable/enable
654 atomic sync).
655 * exp_ch2.adb (Expand_Entity_Reference): Set Atomic_Sync_Required
656 flag Minor code reorganization.
657 * opt.ads (Warn_On_Atomic_Synchronization): New switch.
658 * par-prag.adb: Add dummy entries for pragma
659 Disable/Enable_Atomic_Synchronization.
660 * sem_prag.adb (Process_Suppress_Unsuppress): Handle
661 case of Atomic_Synchronization specially (not suppressed
662 by All_Checks, cannot be set from Source).
663 (Pragma Disable/Enable_Atomic_Synchronization): Add processing.
664 * sinfo.ads, sinfo.adb: Add Atomic_Sync_Required flag
665 * snames.ads-tmpl: Add entry for Atomic_Synchronization Add
666 entry for pragma Disable/Enable_Atomic_Synchronization
667 * switch-c.adb: The -gnatp switch does not disable
668 Atomic_Synchronization Add -gnatep switch to disable
669 Atomic_Synchronization.
670 * types.ads: Add entry for Synchronization_Check
671 * usage.adb: Add line for -gnated switch
672 * warnsw.adb: Settings for Warn_On_Atomic_Synchronization
673
08ce7bb8
AC
6742011-10-24 Geert Bosch <bosch@adacore.com>
675
be7552fc
EB
676 * s-gearop.adb (Back_Substitute): Avoid overflow if matrix bounds start
677 at Integer'First.
08ce7bb8
AC
678
6792011-10-24 Robert Dewar <dewar@adacore.com>
680
be7552fc 681 * sem_ch12.adb, s-gearop.adb: Minor reformatting.
08ce7bb8
AC
682
6832011-10-24 Robert Dewar <dewar@adacore.com>
684
be7552fc
EB
685 * warnsw.adb: Add some missing warnings to Set_GNAT_Mode_Warnings.
686 * warnsw.ads: Add comments to Set_GNAT_Mode_Warnings.
08ce7bb8 687
292689c2
AC
6882011-10-24 Emmanuel Briot <briot@adacore.com>
689
690 * prj-proc.adb (Process_Expression_Variable_Decl): No special
691 handling for Project_Path unless it is an attribute.
692
6932011-10-24 Javier Miranda <miranda@adacore.com>
694
695 * sem_ch12.adb (Check_Hidden_Primitives): New subprogram.
696 (Install_Hidden_Primitives): New subprogram.
697 (Restore_Hidden_Primitives): New subprogram.
698 (Analyze_Formal_Package_Declaration,
699 Analyze_Package_Instantiation, Analyze_Subprogram_Instantiation):
700 Invoke Check_Hidden_Primitives after every call to
701 Analyze_Associations, and invoke Restore_Hidden_Primitives to
702 restore their visibility after processing the instantiation.
703 (Instantiate_Package_Body): Install visible primitives before
704 analyzing the instantiation and uninstall them to restore their
705 visibility when the instantiation has been analyzed.
706 * sem_util.ads, sem_util.adb (Add_Suffix): New subprogram
707 (Remove_Suffix): New subprogram
708 * sem_ch3.adb (Derive_Subprogram): When handling
709 a derived subprogram for the instantiation of a formal derived
710 tagged type, inherit the dispatching attributes from the actual
711 subprogram (not from the parent type).
712
db4b3c49
AC
7132011-10-24 Vasiliy Fofanov <fofanov@adacore.com>
714
715 * gnat_ugn.texi: Document explicit use of XDECGNAT library.
716
7172011-10-24 Hristian Kirtchev <kirtchev@adacore.com>
718
719 * exp_ch3.adb (Build_Assignment): Add local constant N_Loc and
720 update its uses.
721 (Build_Discriminant_Assignments): Add local variable D_Loc and update
722 its uses.
723 (Build_Init_Statements): Add local variables Comp_Loc, Decl_Loc and
724 Var_Loc and update their uses.
725 (Build_Record_Init_Proc): Code reformatting.
726 (Increment_Counter): Add formal parameter Loc.
727 (Make_Counter): Add formal parameter Loc.
728
7292011-10-24 Eric Botcazou <ebotcazou@adacore.com>
730
731 * sem_disp.adb (Covers_Some_Interface): Fix typo.
732
7332011-10-24 Matthew Heaney <heaney@adacore.com>
734
be7552fc
EB
735 * a-cuprqu.adb, a-cbprqu.adb (Dequeue_Only_High_Priority): Fix sense
736 of predicate.
db4b3c49
AC
737
7382011-10-24 Yannick Moy <moy@adacore.com>
739
740 * sem_ch13.adb (Analyze_Aspect_Specifications/Aspect_Test_Case):
741 Translate arguments in positional notation into pragma argument
742 association arguments for the generated pragma.
743
7442011-10-24 Arnaud Charlet <charlet@adacore.com>
745
746 * exp_ch5.adb: Fix minor typo.
747
7482011-10-24 Ed Schonberg <schonberg@adacore.com>
749
750 * sem_ch3.adb (Is_Visible_Component): Refine predicate for
751 the case of a component reference in an instance body, when the
752 enclosing type is private.
753
86f0e17a
AC
7542011-10-24 Sergey Rybin <rybin@adacore.com frybin>
755
756 * gnat_ugn.texi: For gnatelim, move the note about using the GNAT
757 driver for getting the project support into gnatelim section.
758
7592011-10-24 Robert Dewar <dewar@adacore.com>
760
be7552fc 761 * gnat_rm.texi: Minor correction to documentation on address clause.
86f0e17a
AC
762
7632011-10-24 Hristian Kirtchev <kirtchev@adacore.com>
764
765 * s-finmas.adb (Attach): Synchronize and call the unprotected version.
766 (Attach_Unprotected): New routine.
767 (Delete_Finalize_Address): Removed.
768 (Delete_Finalize_Address_Unprotected): New routine.
769 (Detach): Synchronize and call the unprotected version.
770 (Detach_Unprotected): Remove locking.
771 (Finalize): Add various comment on synchronization. Lock the critical
772 region and call the unprotected versions of routines.
773 (Finalize_Address): Removed.
774 (Finalize_Address_Unprotected): New routine.
775 (Set_Finalize_Address): Synchronize and call
776 the unprotected version.
777 (Set_Finalize_Address_Unprotected): New routine.
778 (Set_Heterogeneous_Finalize_Address): Removed.
779 (Set_Heterogeneous_Finalize_Address_Unprotected): New routine.
780 (Set_Is_Heterogeneous): Add comment on synchronization and
781 locking.
782 * s-finmas.ads: Flag Finalization_Started is no longer atomic
783 because synchronization uses task locking / unlocking.
784 (Attach): Add comment on usage.
785 (Attach_Unprotected): New routine.
786 (Delete_Finalize_Address): Renamed to
787 Delete_Finalize_Address_Unprotected.
788 (Detach): Add comment on usage.
789 (Detach_Unprotected): New routine.
790 (Finalize_Address): Renamed to Finalize_Address_Unprotected.
791 (Set_Finalize_Address): Add comment on usage.
792 (Set_Finalize_Address_Unprotected): New routine.
793 (Set_Heterogeneous_Finalize_Address): Renamed to
794 Set_Heterogeneous_Finalize_Address_Unprotected.
795 * s-stposu.adb (Allocate_Any_Controlled): Add local variable
796 Allocation_Locked. Add various comments on synchronization. Lock
797 the critical region and call the unprotected version of
798 routines.
799 (Deallocate_Any_Controlled): Add various comments on
800 synchronization. Lock the critical region and call the unprotected
801 version of routines.
802
8032011-10-24 Ed Schonberg <schonberg@adacore.com>
804
805 * sem_ch3.adb (Set_Fixed_Range): The bounds of a fixed point type
806 are universal and must carry the corresponding type.
807 * sem_eval.adb (Check_Non_Static_Context): If the type of the
808 expression is universal real, as may be the case for a fixed point
809 expression with constant operands in the context of a conversion,
810 there is nothing to check.
811 * s-finmas.adb: Minor reformatting
812
be98aaf0
EB
8132011-10-23 Eric Botcazou <ebotcazou@adacore.com>
814
815 * gcc-interface/decl.c (create_concat_name): Add explicit cast.
816
e45c0886
EB
8172011-10-20 Eric Botcazou <ebotcazou@adacore.com>
818
819 * gcc-interface/Make-lang.in (GNATLIBFLAGS, GNATLIBCFLAGS, THREAD_KIND,
820 TRACE): Reintroduce.
821 (ada/tracebak.o, ada/targext.o, ada/cio.o, ada/init.o,
822 ada/initialize.o, ada/raise.o): Reintroduce explicit compilation rules.
823
27ab5bd8
EB
8242011-10-20 Eric Botcazou <ebotcazou@adacore.com>
825
826 * gcc-interface/trans.c (lhs_or_actual_p): New predicate.
827 (unchecked_conversion_nop): Use it.
828 (gnat_to_gnu): Likewise.
829
b7562769
EB
8302011-10-20 Eric Botcazou <ebotcazou@adacore.com>
831
832 * back_end.adb (Call_Back_End): Pass the maximum logical line number
833 instead of the maximum physical line number to gigi.
834 * gcc-interface/trans.c (Sloc_to_locus): Cope with line zero.
835
53e7c794 8362011-10-16 Tom Tromey <tromey@redhat.com>
46427374
TT
837 Dodji Seketeli <dodji@redhat.com>
838
be7552fc
EB
839 * gcc-interface/trans.c (gigi, Sloc_to_locus): Adjust to use the new
840 public ordinary map interface.
46427374 841
ea10ca9c
AC
8422011-10-16 Tristan Gingold <gingold@adacore.com>
843
53e7c794 844 * link.c (_AIX): Add support for GNU ld.
ea10ca9c
AC
845
8462011-10-16 Fedor Rybin <frybin@adacore.com>
847
848 * gnat_ugn.texi: Fixing gnattest example names in the doc.
849 Adding explanation to additional tests usage.
850
8512011-10-16 Robert Dewar <dewar@adacore.com>
852
853 * exp_ch6.adb, sem_ch6.adb: Minor reformatting.
854
8552011-10-16 Eric Botcazou <ebotcazou@adacore.com>
856
857 * a-convec.adb: Fix minor inconsistencies.
858
8592011-10-16 Matthew Heaney <heaney@adacore.com>
860
861 * a-cusyqu.ads, a-cbsyqu.ads, a-cuprqu.ads, a-cbprqu.ads (package
862 Implementation): Specify pragma Implementation_Defined.
863
c225ba50
NR
8642011-10-15 Nicolas Roche <roche@adacore.com>
865
866 * gcc-interface/lang-specs.h: Ensure -mrtp switch is passed when using
867 either rtp-smp or ravenscar-cert-rtp runtimes.
868
3e452820
AC
8692011-10-15 Bob Duff <duff@adacore.com>
870
871 * exp_ch6.adb (Add_Unconstrained_Actuals_To_Build_In_Place_Call):
872 Do not create a pool formal on unless RE_Root_Storage_Pool_Ptr
873 is available.
874 (Expand_N_Extended_Return_Statement): Do not create a renaming of the
875 build-in-place pool parameter unless RE_Root_Storage_Pool_Ptr is
876 available.
877 (Make_Build_In_Place_Call_In_Allocator): Add the user-defined
878 pool only if RE_Root_Storage_Pool_Ptr is available.
879 (Make_Build_In_Place_Call_In_Object_Declaration): Do not add a
880 pool actual unless RE_Root_Storage_Pool_Ptr is available.
881 * sem_ch6.adb (Create_Extra_Formals): Add build-in-place pool
882 formal only if RE_Root_Storage_Pool_Ptr is available.
883
8842011-10-15 Matthew Heaney <heaney@adacore.com>
885
886 * a-cusyqu.ads, a-cbsyqu.ads, a-cuprqu.ads, a-cbprqu.ads (Queue
887 type): Specify Priority aspect for protected type.
888
b7539c3b
AC
8892011-10-14 Ed Schonberg <schonberg@adacore.com>
890
891 * exp_disp.adb (Check_Premature_Freezing): If an untagged type
892 is a generic actual, it is a subtype of a type that was frozen
893 by the instantiation, and even if not marked frozen it does not
894 affect the construction of the dispatch table.
895
8962011-10-14 Robert Dewar <dewar@adacore.com>
897
898 * make.adb, mlib-utl.adb, sem_util.adb, sem_ch4.adb: Minor code
899 reformatting.
900 * s-rident.ads: Add missing Compiler_Unit pragma.
901
af89615f
AC
9022011-10-14 Gary Dismukes <dismukes@adacore.com>
903
904 * sem_res.adb: Minor reformatting.
905
9062011-10-14 Hristian Kirtchev <kirtchev@adacore.com>
907
908 * exp_ch6.adb (Add_Task_Actuals_To_Build_In_Place_Call):
909 Code and comment reformatting. Use BIP_Task_Master
910 when creating a _master.
911 (BIP_Formal_Suffix): Code reformatting. Correct the case for
912 BIP_Task_Master.
913 (Make_Build_In_Place_Call_In_Object_Declaration): Use
914 BIP_Task_Master when creating a reference to the enclosing
915 function's _master formal.
916 (Move_Activation_Chain): Use BIP_Task_Master when creating a reference
917 to the _master.
918 * exp_ch6.ads: Change BIP_Master to BIP_Task_Master.
919 (Needs_BIP_Finalization_Master): Alphabetized.
920 * sem_ch6.adb (Create_Extra_Formals): Update the usage of
921 BIP_Task_Master.
922
9232011-10-14 Ed Schonberg <schonberg@adacore.com>
924
925 * par-ch6.adb (P_Return_Object_Declaration): In Ada 2012 mode,
926 reject an aliased keyword on the object declaration of an extended
927 return statement. In older versions of the language indicate
928 that this is illegal in the standard.
929
9302011-10-14 Pascal Obry <obry@adacore.com>
931
932 * sem_util.adb, sem_ch4.adb: Minor reformatting.
933
9342011-10-14 Ed Schonberg <schonberg@adacore.com>
935
936 * sem_ch13.adb: Recognize properly procedure calls that are
937 transformed into code statements.
938
9392011-10-14 Vincent Celier <celier@adacore.com>
940
941 * projects.texi: Minor fix in project example.
942
f2d10a02
AC
9432011-10-14 Ed Schonberg <schonberg@adacore.com>
944
945 * sem_util.adb: Return objects are aliased if their type is
946 immutably limited as per AI05-0053.
947
9482011-10-14 Gary Dismukes <dismukes@adacore.com>
949
950 * exp_ch4.adb (Expand_N_Op_And): Remove Short_Circuit_And_Or
951 expansion code (moved to sem_res) (Expand_N_Op_Or): Remove
952 Short_Circuit_And_Or expansion code (moved to sem_res).
953 * sem_res.adb (Resolve_Logical_Op): Add code to rewrite Boolean
954 "and" and "or" operators as short-circuit "and then" and "or
955 else", when pragma Short_Circuit_And_Or is active.
956
2fcc44fa
AC
9572011-10-13 Robert Dewar <dewar@adacore.com>
958
959 * sem_ch9.adb, sem_util.adb, sem_util.ads, exp_ch6.adb, sem_ch4.adb,
960 sem_ch6.adb, exp_ch3.adb: Minor reformatting.
961
9622011-10-13 Arnaud Charlet <charlet@adacore.com>
963
964 * Makefile.rtl (GNATRTL_NONTASKING_OBJS): Add a-ngcoar.o.
965
9662011-10-13 Jerome Guitton <guitton@adacore.com>
967
968 * sysdep.c (__gnat_get_task_options): Re-enable VX_SPE_TASK on vThreads
969
9702011-10-13 Eric Botcazou <ebotcazou@adacore.com>
971
972 * a-convec.ads (Cursor): Minor reformatting.
973 * a-convec.adb (Next): Fix minor inconsistencies.
974 (Previous): Likewise.
975
9b62eb32
AC
9762011-10-13 Ed Schonberg <schonberg@adacore.com>
977
978 * sem_util.ads, sem_util.adb (Available_Full_View_Of_Component):
979 New predicate to determine whether some operations on an array
980 type are available when the full view of its component may differ
981 from the view of the point of the array declaration.
982 * sem_ch4.adb (Find_Equality_Types): Use
983 Available_Full_View_Of_Component.
984 * sem_type.adb (Valid_Boolean_Arg, Valid_Comparison_Arg): Ditto
985
9862011-10-13 Ed Schonberg <schonberg@adacore.com>
987
988 * sem_ch9.adb: Analyze aspects while discriminants of protected
989 type are visible.
990
9912011-10-13 Geert Bosch <bosch@adacore.com>
992
993 * Makefile.rtl (GNATRTL_TASKING_OBJECTS): Add
994 a-nlcoar.o, a-nllcar.o, a-nucoar.o and s-gearop.o, as these no
995 longer depend on an external library.
996 * gcc-interface/Makefile.in (GNATRTL_LINEARALGEBRA_OBJS): Remove
997 a-nlcoar.o, a-nllcar.o, a-nucoar.o and s-gearop.o.
998 Update dependencies.
999 * gcc-interface/Make-lang.in: Update dependencies.
1000
1a36a0cd
AC
10012011-10-13 Cyrille Comar <comar@adacore.com>
1002
1003 * gnat_ugn.texi: Minor editing.
1004
10052011-10-13 Vincent Celier <celier@adacore.com>
1006
1007 * projects.texi: Add documentation on packages and attributes
1008 that are inherited from a project being extended into the
1009 extended project.
1010
10112011-10-13 Hristian Kirtchev <kirtchev@adacore.com>
1012
1013 * exp_ch3.adb (Build_Master): Rewritten.
1014 (Expand_N_Full_Type_Declaration): Reformat the declarative
1015 region. Update the call to Build_Master_Renaming.
1016 (Expand_Previous_Access_Type): Rewritten.
1017 * exp_ch6.adb (Add_Task_Actuals_To_Build_In_Place_Call):
1018 Add local constant Result_Subt and update related usage.
1019 (Expand_N_Extended_Return_Statement): Add local constant
1020 Result_Subt and update related usage.
1021 * exp_ch9.adb (Build_Activation_Chain): Rewritten to use the
1022 new context detection mechanism.
1023 (Build_Class_Wide_Master):
1024 Use Insert_Action to add the renaming into the tree.
1025 (Build_Master_Entity): Rewritten to use the new context detection
1026 mechanism.
1027 (Build_Master_Renaming): Add formal parameter Ins_Nod
1028 and related usage. Use Insert_Action to add the renaming into the
1029 tree.
1030 (Find_Enclosing_Context): New subsidiary routine. Rather
1031 than relying on enclosing scopes, this routine looks at the
1032 tree structure to figure out the proper context for a _master
1033 or a _chain. This approach eliminates the issues with transient
1034 scopes which have not been converted into blocks.
1035 * exp_ch9.ads (Build_Master_Entity): Change parameter profile
1036 to better reflect the new usage. Update the related comment.
1037 (Build_Master_Renaming): Add formal parameter Ins_Nod. Update
1038 the comment on usage.
1039 * sem_ch3.adb (Access_Definition): Update the calls to
1040 Build_Master_Entity and Build_Master_Renaming.
1041 * sem_ch6.adb (Create_Extra_Formals): Add local variable
1042 Full_Subt. Code reformatting.
1043 * sem_util.adb (Is_Iterator): Alphabetized.
1044 (Is_LHS): Alphabetized.
1045 (Is_Limited_Class_Wide_Type): New routine.
1046 * sem_util.ads (Is_Limited_Class_Wide_Type): New routine.
1047
a5917ffb
GB
10482011-10-13 Geert Bosch <bosch@adacore.com>
1049
1050 * a-ngrear.adb (Solve): Make generic and move to
1051 System.Generic_Array_Operations.
1052 * s-gearop.ads (Matrix_Vector_Solution, Matrix_Matrix_Solution):
1053 New generic solvers to compute a vector resp. matrix Y such
1054 that A * Y = X, approximately.
1055 * s-gearop.adb (Matrix_Vector_Solution, Matrix_Matrix_Solution):
1056 Implement using Forward_Eliminate and Back_Substitute
1057 * a-ngcoar.adb: Reimplement in pure Ada to remove dependencies
1058 on BLAS and LAPACK.
1059 * a-ngcoar.ads ("abs"): Fix return type to be real.
1060
574ec945
EB
10612011-10-13 Eric Botcazou <ebotcazou@adacore.com>
1062
1063 PR ada/50589
1064 * s-linux-alpha.ads: Do not "with" Interfaces.C.
1065 * s-linux-sparc.ads: Likewise.
1066
8668ea36
GB
10672011-10-13 Geert Bosch <bosch@adacore.com>
1068
1069 * s-gearop.ads (Forward_Eliminate): Add "abs" formal function
1070 returning a Real.
1071 * s-gearop.adb (Forward_Eliminate): Remove local "abs" function
1072 and use formal.
1073 * a-ngrear.adb (Forward_Eliminate): Adjust instantiation for
1074 new profile.
1075
edcf5983
GB
10762011-10-13 Geert Bosch <bosch@adacore.com>
1077
1078 * a-ngrear.adb, s-gearop.adb, s-gearop.ads (Sqrt): Make generic and
1079 move to System.Generic_Array_Operations.
1080
a4935dea
GB
10812011-10-13 Geert Bosch <bosch@adacore.com>
1082
1083 * a-ngrear.adb ("abs"): Adjust for modified L2_Norm generic
1084 * s-gearop.ads (L2_Norm): Change profile to be suitable for
1085 Complex_Vector
1086 * s-gearop.adb (L2_Norm): Reimplement using direct definition,
1087 not inner product
1088
3e7302c3
AC
10892011-10-13 Robert Dewar <dewar@adacore.com>
1090
1091 * exp_ch5.adb, sem_ch3.adb, impunit.adb, impunit.ads, sem_type.adb,
1092 prj-proc.adb, exp_ch9.adb, s-regpat.adb, sem_ch10.adb, sem_prag.adb,
1093 sem_ch12.adb, freeze.adb, sem_attr.adb, sem_attr.ads, gnatlink.adb,
1094 par-ch6.adb, exp_ch6.adb, sem_ch4.adb, sem_ch6.adb, sem_ch8.adb,
1095 par-util.adb, sem_ch13.adb, lib-xref.adb, g-trasym.adb, g-trasym.ads,
1096 exp_aggr.adb, s-taprop-posix.adb: Minor reformatting.
1097
10982011-10-13 Geert Bosch <bosch@adacore.com>
1099
1100 * s-gearop.adb: Minor comment additions.
1101
8417f4b2
AC
11022011-10-13 Fedor Rybin <frybin@adacore.com>
1103
1104 * gnat_ugn.texi: Add gnattest section.
1105
11062011-10-13 Ed Schonberg <schonberg@adacore.com>
1107
1108 * freeze.adb: Do not create body of renaming if declaration has
1109 errors.
1110
11112011-10-13 Olivier Hainque <hainque@adacore.com>
1112
1113 * init.c (__gnat_error_handler - vxworks case): Restrict sigtramp calls
1114 further, to the ppc+kernel case only.
1115
11162011-10-13 Hristian Kirtchev <kirtchev@adacore.com>
1117
1118 * exp_ch4.adb (Expand_N_Allocator): Comment reformatting.
1119 * exp_ch6.adb (Add_Unconstrained_Actuals_To_Build_In_Place_Call):
1120 Do not create a pool formal on .NET/JVM.
1121 (Expand_N_Extended_Return_Statement): Alphabetize local
1122 variables. Do not create a renaming of the build-in-place pool
1123 parameter on .NET/JVM. (Make_Build_In_Place_Call_In_Allocator):
1124 Add the user-defined pool only on non-VM targets.
1125 (Make_Build_In_Place_Call_In_Object_Declaration): Alphabetize
1126 local variables. Do not add a pool actual on .NET/JVM.
1127 * sem_ch6.adb: Add with and use clause for Targparm.
1128 (Create_Extra_Formals): Add build-in-place pool formal only on
1129 non-VM targets.
1130 * rtsfind.ads: Alphabetize entries.
1131
4674dd21
AC
11322011-10-13 Sergey Rybin <rybin@adacore.com>
1133
1134 * gnat_ugn.texi: Minor correction.
1135
11362011-10-13 Ed Schonberg <schonberg@adacore.com>
1137
1138 * sem_ch8.adb: Minor error message improvement.
1139
11402011-10-13 Robert Dewar <dewar@adacore.com>
1141
1142 * a-cbprqu.adb, a-ciorma.adb, exp_ch3.adb: Minor reformatting.
1143
95aeda79
GD
11442011-10-13 Gary Dismukes <dismukes@adacore.com>
1145
1146 * exp_ch5.adb (Expand_N_Loop_Statement): For the transformation
1147 of a for loop for an enumeration type with an enumeration rep
1148 clause, which involves moving the original loop parameter into
1149 a nested block, the loop parameter's entity must be removed from
1150 the entity list of the loop scope.
1151
200b7162
BD
11522011-10-13 Bob Duff <duff@adacore.com>
1153
1154 * exp_ch6.ads (BIP_Storage_Pool): New "extra implicit parameter"
1155 that gets passed in the same cases where BIP_Alloc_Form is passed
1156 (caller-unknown-size results). BIP_Storage_Pool is used when
1157 BIP_Alloc_Form = User_Storage_Pool. In that case, a pointer
1158 to the user-defined storage pool is passed at the call site,
1159 and this pool is used in callee to allocate the result.
1160 * exp_ch6.adb (Add_Unconstrained_Actuals_To_Build_In_Place_Call): New
1161 version of Add_Alloc_Form_Actual_To_Build_In_Place_Call. Passes
1162 the additional BIP_Storage_Pool actual.
1163 (Expand_N_Extended_Return_Statement): Allocate the function
1164 result using the user-defined storage pool, if BIP_Alloc_Form =
1165 User_Storage_Pool.
1166 * sem_ch6.adb: Add the "extra formal" for BIP_Storage_Pool.
1167 * exp_ch4.adb: Don't overwrite storage pool set by
1168 Expand_N_Extended_Return_Statement.
1169 * s-stopoo.ads, rtsfind.ads (Root_Storage_Pool_Ptr): New type,
1170 for use in build-in-place function calls within allocators
1171 where the access type has a user-defined storage pool.
1172
9f8d1e5c
AC
11732011-10-13 Sergey Rybin <rybin@adacore.com>
1174
1175 * gnat_ugn.texi, vms_data.ads: Add an option to control enumeration
1176 literal casing.
1177
11782011-10-13 Nicolas Roche <roche@adacore.com>
1179
be7552fc
EB
1180 * gnatlink.adb: Ensure that -mrtp is passed when runtime name ends
1181 with 'rtp'.
9f8d1e5c
AC
1182
11832011-10-13 Ed Schonberg <schonberg@adacore.com>
1184
be7552fc
EB
1185 * sem_prag.adb (Analyze_Pragma, case Unchecked_Union): Take into
1186 account that an unchecked union type can be limited.
9f8d1e5c
AC
1187
11882011-10-13 Olivier Hainque <hainque@adacore.com>
1189
1190 * init.c (__gnat_error_handler) <VxWorks version>: Add comments on
1191 the use of the signal trampoline for PPC in the sjlj case as well.
1192 Add legitimate casts, preventing compile time warnings on the
1193 (sighandler *) profile.
1194
11952011-10-13 Yannick Moy <moy@adacore.com>
1196
be7552fc
EB
1197 * sem_aggr.adb (Resolve_Aggr_Expr): Always perform semantic analysis
1198 in Alfa mode.
9f8d1e5c
AC
1199
12002011-10-13 Ed Schonberg <schonberg@adacore.com>
1201
1202 * sem_ch3.adb (OK_For_Limited_Init_In_05): Conditional and case
1203 expressions are legal limited return values if each one of their
1204 dependent expressions are legal.
1205
12062011-10-13 Ed Schonberg <schonberg@adacore.com>
1207
1208 * sem_ch6.adb (Analyze_Procedure_Call_Statement): In Ada 2012 mode,
1209 if the prefix of the call is a qualified expression, rewrite as
1210 a code statement.
1211 * sem_ch13.adb (Analyze_Code_Statement): In Ada 2012 mode, the
1212 code statement is legal if it is a rewriting of a procedure call.
1213
12142011-10-13 Ed Schonberg <schonberg@adacore.com>
1215
1216 * exp_aggr.adb (Flatten): If a component association has a box,
1217 assume that aggregate is not static.
1218 (Safe_Aggregate): If a component association in a non-limited
1219 aggregate has a box, assume that it cannot be expanded in place.
1220
12212011-10-13 Vincent Celier <celier@adacore.com>
1222
1223 * prj-conf.adb (Get_Or_Create_Configuration_File): Call
1224 Process_Project_Tree_Phase_1 with Packages_To_Check.
1225 (Process_Project_And_Apply_Config): Ditto
1226 * prj-part.ads, prj-part.adb, prj-pars.ads, prj-pars.adb (Parse):
1227 Remove default for argument Packages_To_Check.
1228 * prj-proc.adb (Recursive_Process): New argument
1229 Packages_To_Check.
1230 (Process): Ditto.
1231 (Process_Project_Tree_Phase_1): Ditto.
1232 (Recursive_Project.Process_Aggregated_Projects): Call
1233 Prj.Part.Parse and Process_Project_Tree_Phase_1 with
1234 Packages_To_Check.
1235 * prj-proc.ads (Process): New argument Packages_To_Check
1236 (Process_Project_Tree_Phase_1): Ditto
1237
46f8e1ac
AC
12382011-10-13 Arnaud Charlet <charlet@adacore.com>
1239
1240 * gcc-interface/Makefile.in: Fix typo.
1241
8097203f
AC
12422011-10-13 Ed Schonberg <schonberg@adacore.com>
1243
1244 * sem_ch12.adb (Analyze_Formal_{Floating_Type,
1245 Signed_Integer_Type, Decimal_Fixed_Point_Type, Discrete_Type}):
1246 Use sloc of defining identifier of farmal type declaration,
1247 as sloc of generated internal entity, to prevent misplaced
1248 references in ali.
1249
12502011-10-13 Ed Schonberg <schonberg@adacore.com>
1251
1252 * sem_intr.adb (Check_Intrinsic_Operator): Check that type
1253 is fully defined before checking that it is a numeric type.
1254
12552011-10-13 Ed Schonberg <schonberg@adacore.com>
1256
1257 * sem_aggr.adb (Resolve_Record_Aggregate): If a component
1258 association for component X has a box, then X is covered in the
1259 aggregate even if there is not default value for X in the type
1260 declaration, and X has to be default-initialized.
1261
12622011-10-13 Ed Schonberg <schonberg@adacore.com>
1263
be7552fc
EB
1264 * sem_attr.adb (Check_Enum_Image, Analyze_Attribute case 'Value): Mark
1265 literals as referenced only if reference is in current source unit.
8097203f
AC
1266
12672011-10-13 Matthew Heaney <heaney@adacore.com>
1268
1269 * a-csquin.ads (Enque, Dequeue): Mark interface operations as entries.
1270
12712011-10-13 Olivier Hainque <hainque@adacore.com>
1272
1273 * sigtramp.h: New file. Prototype and spec of the signal
1274 trampoline to be called by an established handler to provide
1275 dwarf call frame info before the real signal processing code.
1276 * sigtramp-ppcvxw.c: New file. Implementation of the signal
1277 trampoline for ppc-vxworks.
1278 * init.c (vxworks section): Use it for ppc.
1279
e192a2cd
AC
12802011-10-13 Thomas Quinot <quinot@adacore.com>
1281
1282 * par-ch2.adb, par.adb, par-util.adb, par-ch3.adb
1283 (Check_Future_Identifier): New subprogram,
1284 factors duplicated code from Par.Ch2.P_Identifier and
1285 Par.Ch3.P_Defining_Identifier.
1286
12872011-10-13 Thomas Quinot <quinot@adacore.com>
1288
1289 * s-taprop-posix.adb (Initialize): Always raise Storage_Error
1290 if we fail to initialize CV attributes or CV.
1291
12922011-10-13 Thomas Quinot <quinot@adacore.com>
1293
1294 * s-tasren.adb (Timed_Selective_Wait, case
1295 Accept_Alternative_Selected): Use Defer_Abort_Nestable, since
1296 we know abortion is already deferred.
1297
12982011-10-13 Hristian Kirtchev <kirtchev@adacore.com>
1299
1300 * exp_ch3.adb (Build_Class_Wide_Master): Moved to exp_ch9.
1301 (Build_Master_Renaming (function)): Removed.
1302 (Build_Master_Renaming (procedure)): Moved to exp_ch9.
1303 (Expand_Full_Type_Declaration): Alphabetize
1304 variables. Reformatting of code and comments. Rewrite the
1305 section on processing of anonymous access-to-task types in
1306 record components.
1307 * exp_ch3.ads (Build_Class_Wide_Master): Moved to exp_ch9.
1308 (Build_Master_Renaming): Moved to exp_ch9.
1309 * exp_ch9.adb (Build_Class_Wide_Master): Moved from exp_ch3.
1310 (Build_Master_Entity): Add formal parameter
1311 Use_Current. Reformatting of code and comments.
1312 (Build_Master_Renaming): Moved from exp_ch3.
1313 * exp_ch9.ads (Build_Class_Wide_Master): Moved from
1314 exp_ch3. Update comment on usage.
1315 (Build_Master_Entity):
1316 Add formal parameter Use_Current. Update comment on usage.
1317 (Build_Master_Renaming): Moved from exp_ch3.
1318 * sem_ch3.adb (Access_Definition): Remove redundant code to
1319 create a _master and a renaming.
1320
13212011-10-13 Ed Schonberg <schonberg@adacore.com>
1322
1323 * lib-xref.adb: Do no emit reference to overridden operation,
1324 if it is internally generated.
1325
13262011-10-13 Vincent Celier <celier@adacore.com>
1327
1328 * bindgen.adb: Remove any processing related to g-trasym
1329 * Makefile.rtl: Add g-trasym.o to GNATRTL_NONTASKING_OBJS
1330 * mlib-prj.adb: Remove any processing related to g-trasym.
1331
0cfaf83f
EB
13322011-10-12 Eric Botcazou <ebotcazou@adacore.com>
1333
1334 * sem_util.adb (Denotes_Same_Prefix): Fix fatal warning.
1335 * gcc-interface/Make-lang.in (WARN_ADAFLAGS): New.
1336 (ALL_ADAFLAGS): Include WARN_ADAFLAGS.
1337 (ADA_FLAGS_TO_PASS): Likewise.
1338 (COMMON_FLAGS_TO_PASS): New.
1339 (ADA_TOOLS_FLAGS_TO_PASS): Use COMMON_FLAGS_TO_PASS. In the regular
1340 native case, also use FLAGS_TO_PASS and ADA_FLAGS_TO_PASS.
1341 (gnatlib): Use COMMON_FLAGS_TO_PASS.
1342 (ada.install-common): Likewise.
1343 (install-gnatlib): Likewise.
1344 (install-gnatlib-obj): Likewise.
1345 (gnattools): Use ADA_TOOLS_FLAGS_TO_PASS for gnattools1 as well.
1346 (gnat-cross): Delete.
1347 (gnatboot): Likewise.
1348 (gnatboot2): Likewise.
1349 (gnatboot3): Likewise.
1350 (gnatstage1): Likewise.
1351 (gnatstage2): Likewise.
1352 * gcc-interface/Makefile.in (SOME_ADAFLAGS): Likewise.
1353 (MOST_ADAFLAGS): Likewise.
1354 (LOOSE_CFLAGS): Likewise.
1355 (gnat-cross): Likewise.
1356 (GNATLIBFLAGS): Add -W -Wall.
1357 (GNATLIBCFLAGS_FOR_C): Likewise.
1358 * gcc-interface/lang.opt: Remove C-specific warnings. Add doc lines.
1359 * gcc-interface/misc.c (gnat_handle_option): Remove obsolete cases.
1360
722356ce
EB
13612011-10-12 Eric Botcazou <ebotcazou@adacore.com>
1362
1363 * gcc-interface/trans.c (Attribute_to_gnu): Use remove_conversions.
1364 (push_range_check_info): Likewise.
1365 (gnat_to_gnu) <N_Code_Statement>: Likewise.
1366 * gcc-interface/utils2.c (build_unary_op) <INDIRECT_REF>: Likewise.
1367 (gnat_invariant_expr): Likewise.
1368 * gcc-interface/utils.c (compute_related_constant): Likewise.
1369 (max_size): Fix handling of SAVE_EXPR.
1370 (remove_conversions): Fix formatting.
1371
15bf7d19
EB
13722011-10-12 Eric Botcazou <ebotcazou@adacore.com>
1373
1374 * gcc-interface/ada-tree.h (DECL_LOOP_PARM_P): New flag.
1375 (DECL_INDUCTION_VAR): New macro.
1376 (SET_DECL_INDUCTION_VAR): Likewise.
1377 * gcc-interface/gigi.h (convert_to_index_type): Declare.
1378 (gnat_invariant_expr): Likewise.
1379 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: If this is a loop
1380 parameter, set DECL_LOOP_PARM_P on it.
1381 * gcc-interface/misc.c (gnat_print_decl) <VAR_DECL>: If DECL_LOOP_PARM_P
1382 is set, print DECL_INDUCTION_VAR instead of DECL_RENAMED_OBJECT.
1383 * gcc-interface/trans.c (gnu_loop_label_stack): Delete.
1384 (struct range_check_info_d): New type.
1385 (struct loop_info_d): Likewise.
1386 (gnu_loop_stack): New stack.
1387 (Identifier_to_gnu): Set TREE_READONLY flag on the first dereference
1388 built for a by-double-ref read-only parameter. If DECL_LOOP_PARM_P
1389 is set, do not test DECL_RENAMED_OBJECT.
1390 (push_range_check_info): New function.
1391 (Loop_Statement_to_gnu): Push a new struct loop_info_d instead of just
1392 the label. Reference the label and the iteration variable from it.
1393 Build the special induction variable in the unsigned version of the
1394 size type, if it is larger than the base type. And attach it to the
1395 iteration variable if the latter isn't by-ref. In the iteration scheme
1396 case, initialize the invariant conditions in front of the loop if
1397 deemed profitable. Use gnu_loop_stack.
1398 (gnat_to_gnu) <N_Exit_Statement>: Use gnu_loop_stack.
1399 <N_Raise_Constraint_Error>: Always process the reason. In the range
1400 check and related cases, and if loop unswitching is enabled, compute
1401 invariant conditions and push this information onto the stack.
1402 Do not translate again the condition if it has been already translated.
1403 * gcc-interface/utils.c (record_global_renaming_pointer): Assert that
1404 DECL_LOOP_PARM_P isn't set.
1405 (convert_to_index_type): New function.
1406 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Use it in order
1407 to convert the index from the base index type to sizetype.
1408 (gnat_invariant_expr): New function.
1409
e79983f4
MM
14102011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
1411
1412 * gcc-interface/utils.c (def_builtin_1): Delete old interface with
1413 two parallel arrays to hold standard builtin declarations, and
1414 replace it with a function based interface that can support
15bf7d19 1415 creating builtins on the fly in the future.
e79983f4
MM
1416 * gcc-interface/trans.c (Exception_Handler_to_gnu_zcx): Ditto.
1417 (gnat_to_gnu): Ditto.
1418
228ee426
EB
14192011-10-07 Eric Botcazou <ebotcazou@adacore.com>
1420
1421 PR lto/50492
1422 * gcc-interface/gigi.h (gnat_pushdecl): Adjust comment.
1423 * gcc-interface/utils.c (global_context): New variable.
1424 (gnat_pushdecl): Initialize it and set it as the DECL_CONTEXT of DECLs
1425 that are either public external or at top level. Use "No" macro.
1426 (end_subprog_body): Call decl_function_context.
1427 (rest_of_subprog_body_compilation): Likewise.
1428
71196d4e
EB
14292011-10-07 Eric Botcazou <ebotcazou@adacore.com>
1430
1431 * gcc-interface/gigi.h (gnat_useless_type_conversion): Declare.
1432 (rest_of_subprog_body_compilation): Likewise.
1433 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Variable>: For renaming,
1434 test for useless conversions by means of gnat_useless_type_conversion.
1435 * gcc-interface/trans.c: Include bitmap.h and cgraph.h.
1436 (language_function): Add named_ret_val and other_ret_val.
1437 (f_named_ret_val): New macro.
1438 (f_other_ret_val): Likewise.
1439 (gigi): Call rest_of_subprog_body_compilation.
1440 (struct nrv_data): New structure.
1441 (is_nrv_p): New predicate.
1442 (prune_nrv_r): New helper function.
1443 (prune_nrv_in_block): New function.
1444 (finalize_nrv_r): New helper function.
1445 (finalize_nrv): New function.
1446 (return_value_ok_for_nrv_p): New predicate.
1447 (build_return_expr): If optimization is enabled, record candidates for
1448 the Named Return Value optimization.
1449 (build_function_stub): Call rest_of_subprog_body_compilation.
1450 (Subprogram_Body_to_gnu): If optimization is enabled and there are
1451 candidates, finalize the Named Return Value optimization.
1452 Call rest_of_subprog_body_compilation.
1453 (call_to_gnu): At the end, if a return value is needed, simplify the
1454 result before wrapping it up in a COMPOUND_EXPR.
1455 * gcc-interface/utils.c (end_subprog_body): Split into...
1456 (rest_of_subprog_body_compilation): ...this. New function.
1457 (gnat_useless_type_conversion): Likewise.
1458
885c4871
AC
14592011-10-06 Thomas Quinot <quinot@adacore.com>
1460
1461 * einfo.ads, exp_attr.adb, exp_ch3.adb, exp_ch4.adb, exp_ch7.adb,
1462 exp_ch9.adb, exp_ch9.ads, exp_strm.adb, exp_util.adb, freeze.adb,
1463 g-debpoo.ads, opt.ads, par-ch12.adb, par-ch2.adb, par-ch3.adb,
1464 par-ch5.adb, par-ch6.adb, sem_aggr.adb, sem_attr.adb, sem_cat.adb,
1465 sem_ch10.adb, sem_ch12.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
1466 sem_ch6.adb, sem_intr.adb, sem_res.ads, sem_type.adb, sem_util.adb,
1467 s-regpat.adb, s-tpopde-vms.ads: Minor reformatting.
1468 * s-osinte-freebsd.ads: Fix for tasking failures on FreeBSD.
1469
14702011-10-06 Ed Schonberg <schonberg@adacore.com>
1471
1472 * a-cihase.adb, a-ciorma.adb: Avoid accessibility checks in container
1473 references.
1474
14752011-10-06 Matthew Heaney <heaney@adacore.com>
1476
1477 * a-cuprqu.ads, a-cuprqu.adb, a-cbprqu.ads, a-cbprqu.adb
1478 (Dequeue_Only_High_Priority): Protected procedure now implemented.
1479
14802011-10-06 Vincent Celier <celier@adacore.com>
1481
1482 * g-trasym.adb: Replace old implementation with the default
1483 implementation that returns list of addresses as "0x...".
1484 * g-trasym.ads: Update the list of platforms with the full
1485 capability. Indicate that there is a default implementation
1486 for other platforms.
1487 * g-trasym-unimplemented.ads, g-trasym-unimplemented.adb: Remove.
1488 * gcc-interface/Makefile.in: Remove g-trasym-unimplemented, as there
1489 is now a default implementation for all platforms without the full
1490 capability.
1491
ce72a9a3
AC
14922011-10-06 Robert Dewar <dewar@adacore.com>
1493
1494 * a-ciorse.adb, a-cihase.adb, a-cihase.ads, a-coorse.adb,
1495 a-cborse.adb, a-comutr.adb, a-ciorma.adb, a-cbmutr.adb,
1496 a-cbmutr.ads, a-cbhase.adb, a-cbhase.ads: Minor reformatting and code
1497 reorganization (use conditional expressions).
1498
14992011-10-06 Robert Dewar <dewar@adacore.com>
1500
1501 * sem_res.adb (Resolve_Arithmetic_Op): Fix bad warning for
1502 floating divide by zero.
1503
15042011-10-06 Ed Schonberg <schonberg@adacore.com>
1505
1506 * sem_ch6.adb: Limited interfaces that are not immutably limited
1507 are OK in return statements.
1508
a912d7d9
IS
15092011-09-30 Iain Sandoe <iains@gcc.gnu.org>
1510
1511 * gcc-interface/Makefile.in (Darwin): Partial reversion of previous
1512 change to powerpc section.
1513
39ffb1f9
IS
15142011-09-29 Iain Sandoe <iains@gcc.gnu.org>
1515
1516 * gcc-interface/Makefile.in (Darwin): Factor LIBGNAT_TARGET_PAIRS
1517 across the port.
1518
ffb35bbf
ES
15192011-09-27 Ed Schonberg <schonberg@adacore.com>
1520
1521 * a-cbhase.adb, a-cbhase.ads, a-cborse.adb, a-cborse.ads,
1522 a-cihase.adb, a-cihase.ads, a-ciorse.adb, a-ciorse.ads,
1523 a-coorse.adb, a-coorse.ads: Add iterator machinery to bounded sets and
1524 indefinite sets.
1525 * a-coorma.ads: Minor reformmating.
1526 * einfo.ads: Improve the comment describing the
1527 Directly_Designated_Type function.
1528 * a-ciorma.adb, a-ciorma.ads: Add iterator machinery to indefinite
1529 ordered maps.
1530 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
1531 dependencies.
1532
da124b6a
AC
15332011-09-27 Robert Dewar <dewar@adacore.com>
1534
1535 * a-comutr.ads: Minor reformatting.
1536
15372011-09-27 Ed Schonberg <schonberg@adacore.com>
1538
1539 * a-cimutr.adb, a-cimutr.ads, a-cbmutr.adb, a-cbmutr.ads: Add children
1540 iterators to multiway trees.
1541
15422011-09-27 Yannick Moy <moy@adacore.com>
1543
1544 * debug.adb (d.D): New option for strict Alfa mode.
1545 * opt.ads (Strict_Alfa_Mode): New flag to interpret compiler
1546 permissions as strictly as possible.
1547 * sem_ch3.adb (Signed_Integer_Type_Declaration): In non-strict
1548 Alfa mode, now, interpret ranges of base types like GNAT does; in
1549 strict mode, simply change the range of the implicit base Itype.
1550 * gnat1drv.adb: Update comments. Set Strict_Alfa_Mode.
1551
706a4067
AC
15522011-09-27 Robert Dewar <dewar@adacore.com>
1553
1554 * exp_ch9.adb: Minor comment fixes.
1555
15562011-09-27 Ed Schonberg <schonberg@adacore.com>
1557
1558 * a-comutr.adb, a-comutr.ads: Add children iterators on multiway
1559 trees.
1560
05c1e7d2
AC
15612011-09-27 Eric Botcazou <ebotcazou@adacore.com>
1562
1563 * checks.adb (Apply_Scalar_Range_Check): Use Designated_Type
1564 instead of Directly_Designated_Type in the indirect array case.
1565
15662011-09-27 Robert Dewar <dewar@adacore.com>
1567
1568 * exp_util.adb, exp_aggr.adb: Minor reformatting.
1569
65e78a74
AC
15702011-09-27 Ed Schonberg <schonberg@adacore.com>
1571
1572 * sinfo.ads, par-ch3.adb: Minor comment update: aspect specification
1573 on subtype declarations.
1574 * exp_aggr.adb: Minor comment update.
1575
15762011-09-27 Eric Botcazou <ebotcazou@adacore.com>
1577
1578 * exp_util.adb (Safe_Prefixed_Reference): Remove always-false
1579 test in the N_Explicit_Dereference case. Fold double logical
1580 negation in the special loop case and conditionalize it on
1581 Variable_Ref being true.
1582
15832011-09-27 Ed Schonberg <schonberg@adacore.com>
1584
1585 * sem_ch4.adb (Analyze_Selected_Component): If the prefix is a
1586 single protected object and the selector is a discriminant or an
1587 entry family, this is a non-overloaded candidate interpretation,
1588 and possible primitive operations of the type must not be
1589 examined.
1590
15912011-09-27 Arnaud Charlet <charlet@adacore.com>
1592
1593 * s-taspri-posix-noaltstack.ads (Lock): Mark fields aliased.
1594
6f5add73
AC
15952011-09-27 Pascal Obry <obry@adacore.com>
1596
1597 * s-osinte-hpux.ads, s-osinte-aix.ads, s-osinte-solaris-posix.ads,
1598 s-osinte-irix.ads, s-osinte-darwin.ads, s-osinte-freebsd.ads:
1599 Add dummy definitions for pthread_rwlock_t
1600 and pthread_rwlockattr_t on all POSIX platforms.
1601 * s-taprop-irix.adb, s-taprop-posix.adb (Initialize_Lock): Fix lock
1602 reference.
1603 (Finalize_Lock): Likewise.
1604 (Write_Lock): Likewise.
1605 (Unlock): Likewise.
1606
16072011-09-27 Tristan Gingold <gingold@adacore.com>
1608
1609 * s-tassta.adb (Task_Wrapper): Increase Guard_Page_Size value for
1610 windows 64.
1611
64a63cd5
PO
16122011-09-27 Pascal Obry <obry@adacore.com>
1613
1614 * s-osinte-hpux.ads, s-taprop-vxworks.adb, s-taspri-vxworks.ads,
1615 s-taprop-tru64.adb, s-osinte-aix.ads, s-taspri-posix-noaltstack.ads,
1616 s-taspri-mingw.ads, s-taprop-vms.adb, s-tpoben.adb, s-tpoben.ads,
1617 s-taprop-mingw.adb, s-taprob.adb, s-taprob.ads,
1618 s-osinte-solaris-posix.ads, s-taprop-solaris.adb, s-taspri-solaris.ads,
1619 s-osinte-irix.ads, s-taprop-irix.adb, s-osinte-darwin.ads,
1620 s-taspri-dummy.ads, s-taspri-posix.ads, s-taprop.ads,
1621 s-taspri-vms.ads, s-osinte-freebsd.ads, s-taprop-hpux-dce.adb,
1622 s-taspri-hpux-dce.ads, s-taspri-tru64.ads, s-taprop-dummy.adb,
1623 s-taprop-posix.adb: Revert previous changes.
1624 (Lock): Now a record containing the two possible lock
1625 (mutex and read/write) defined in OS_Interface.
1626 * s-taprop-linux.adb (Finalize_Protection): Use r/w lock for
1627 'R' locking policy.
1628 (Initialize_Protection): Likewise.
1629 (Lock): Likewise.
1630 (Lock_Read_Only): Likewise.
1631 (Unlock): Likewise.
1632
f672a756
AC
16332011-09-27 Pascal Obry <obry@adacore.com>
1634
1635 * s-taspri-posix-noaltstack.ads (RW_Lock): This type is now defined as
1636 OS_Interface.pthread_rwlock_t.
1637
16382011-09-27 Robert Dewar <dewar@adacore.com>
1639
1640 * exp_ch9.adb, a-cimutr.adb, a-cimutr.ads, gnat1drv.adb, a-comutr.adb,
1641 a-comutr.ads, exp_dist.adb, a-cbmutr.adb, a-cbmutr.ads,
1642 sem_ch5.adb, sem_util.adb: Minor reformatting.
1643
7a44cb69
PO
16442011-09-27 Pascal Obry <obry@adacore.com>
1645
1646 * s-taprop.ads (Initialize_Lock)[RW_Lock]: New spec for r/w lock.
1647 (Finalize_Lock)[RW_Lock]: Likewise.
1648 (Write_Lock)[RW_Lock]: Likewise.
1649 (Unlock)[RW_Lock]: Likewise.
1650 (Read_Lock): Define L as RW_Lock (instead of Lock).
1651 * s-taprop-linux.adb (Initialize_Lock)[RW_Lock]: New
1652 routine for r/w lock.
1653 (Finalize_Lock)[RW_Lock]: Likewise.
1654 (Write_Lock)[RW_Lock]: Likewise.
1655 (Unlock)[RW_Lock]: Likewise.
1656 (Read_Lock): Define L as RW_Lock (instead of Lock).
1657
1658 * s-taprop-vxworks.adb, s-taprop-tru64.adb, s-taprop-vms.adb,
1659 s-taprop-mingw.adb, s-taprop-solaris.adb, s-taprop-irix.adb,
1660 s-taprop-hpux-dce.adb, s-taprop-dummy.adb, s-taprop-posix.adb
1661 (Initialize_Lock)[RW_Lock]: Same implementation as corresponding
1662 routine for standard lock.
1663 (Finalize_Lock)[RW_Lock]: Likewise.
1664 (Write_Lock)[RW_Lock]: Likewise.
1665 (Unlock)[RW_Lock]: Likewise.
1666 (Read_Lock): Define L as RW_Lock (instead of Lock).
1667 * s-taprob.ads, s-tpoben.ads (Protection): Add RWL (RW_Lock)
1668 in the record definition.
1669 * s-taprob.adb, s-taproben.adb (Finalize_Protection): Use r/w
1670 lock for 'R' locking policy.
1671 (Initialize_Protection): Likewise.
1672 (Lock): Likewise.
1673 (Lock_Read_Only): Likewise.
1674 (Unlock): Likewise.
1675 * s-taspri-posix.ads (RW_Lock): New type defined as
1676 OS_Interface.pthread_rwlock_t.
1677
1678 * s-taspri-vxworks.ads, s-taspri-posix-noaltstack.ads,
1679 s-taspri-mingw.ads, s-taspri-solaris.ads, s-taspri-dummy.ads,
1680 s-taspri-posix.ads, s-taspri-vms.ads, s-taspri-hpux-dce.ads,
1681 s-taspri-tru64.ads (RW_Lock): New type defined as alias to Lock.
1682
4c173b50
PO
16832011-09-27 Pascal Obry <obry@adacore.com>
1684
1685 * exp_ch9.adb, s-taspri-posix.ads: Minor reformatting.
1686
16872011-09-27 Pascal Obry <obry@adacore.com>
1688
1689 * s-osinte-aix.ads, s-osinte-darwin.ads, s-osinte-freebsd.ads,
1690 s-osinte-hpux.ads, s-osinte-irix.ads,
1691 s-osinte-solaris-posix.ads (pthread_rwlock_t): New definition alias of
1692 pthread_mutex_t.
1693 (pthread_rwlockattr_t): New definition alias of pthread_mutexattr_t.
1694 * s-osinte-linux.ads (pthread_rwlock_t, pthread_rwlockattr_t,
1695 pthread_rwlockattr_init, pthread_rwlockattr_destroy,
1696 pthread_rwlockattr_setkind_np, pthread_rwlock_init,
1697 pthread_rwlock_destroy, pthread_rwlock_rdlock,
1698 pthread_rwlock_wrlock, pthread_rwlock_unlock): New.
1699
343250a6
PO
17002011-09-27 Pascal Obry <obry@adacore.com>
1701
1702 * rtsfind.ads: Add RE_Lock_Read_Only into rtsfind circuitry.
1703 (RE_Id): Add RE_Lock_Read_Only.
1704 (RE_Unit_Table): Likewise.
1705 * sem_prag.adb (Process_Convention): Change Pragma_Locking_Policy
1706 to lift restriction on first character. Handle now the
1707 Name_Concurrent_Readers_Locking where policy character is set to
1708 'R'.
1709 * snames.ads-tmpl (Name_Concurrent_Readers_Locking): New
1710 constant.
1711 * exp_ch9.adb (Build_Protected_Subprogram_Body): Generate a
1712 read only lock for function in protected object.
1713 * s-taprob.ads (Lock_Read_Only): Remove obsolete comment as
1714 this routine is now used.
1715
2d0dd51a
EB
17162011-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1717
1718 * s-atocou-x86.adb (Decrement): Use %;.
1719 (Increment): Likewise.
1720
bdbebf66
EB
17212011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1722
1723 * gcc-interface/utils2.c (build_allocator): Set TREE_THIS_NOTRAP on the
1724 dereference of the pointer to the storage area. Remove useless type
1725 conversions and factor out common code.
1726
1aa291f7
EB
17272011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1728
1729 * gcc-interface/utils.c (maybe_unconstrained_array): Declare TYPE local
1730 variable and use it throughout.
1731 <UNCONSTRAINED_ARRAY_TYPE>: Add 'break' at the end.
1732 <RECORD_TYPE>: Do not unconditionally convert to the unpadded type as a
1733 first step. Also convert to the unpadded type as a last step.
1734
7d76717d
EB
17352011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1736
1737 * gcc-interface/gigi.h (create_subprog_decl): Replace TREE_CHAIN with
1738 DECL_CHAIN in comment.
1739 * gcc-interface/trans.c (gigi): Likewise.
1740 (Attribute_to_gnu): Likewise.
1741 (build_function_stub): Likewise.
1742 (gnat_to_gnu): Likewise.
1743 * gcc-interface/utils.c (create_subprog_decl): Likewise.
1744 (convert_vms_descriptor64): Likewise.
1745 (convert_vms_descriptor32): Likewise.
1746
42acad07
EB
17472011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1748
1749 * gcc-interface/trans.c (assoc_to_constructor): Minor tweaks.
1750 * gcc-interface/utils2.c (build_simple_component_ref): Fix formatting
1751 issues. Use COMPLETE_TYPE_P in assertion. Also set TREE_READONLY if
1752 the type of the record is TYPE_READONLY.
1753
a1d72281
EB
17542011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1755 Robert Dewar <dewar@adacore.com>
1756
1757 * sem_ch6.adb (Set_Formal_Mode): Set Can_Never_Be_Null on an IN or IN
1758 OUT formal parameter which is of an null-exclusion access subtype.
1759
a1c7d797
EB
17602011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1761
1762 * gcc-interface/ada-tree.h (DECL_CAN_NEVER_BE_NULL_P): New macro.
1763 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Set the flag.
1764 (gnat_to_gnu_param): Likewise.
1765 * gcc-interface/utils.c (convert) <UNCONSTRAINED_ARRAY_REF>: Invoke
1766 maybe_unconstrained_array instead of doing the work manually.
1767 (maybe_unconstrained_array): Propagate the TREE_THIS_NOTRAP flag.
1768 * gcc-interface/utils2.c (build_unary_op) <INDIRECT_REF>: If operand
1769 is a DECL with the flag, set TREE_THIS_NOTRAP on the reference.
1770 (gnat_stabilize_reference_1): Propagate the TREE_THIS_NOTRAP flag.
1771 (gnat_stabilize_reference): Likewise.
1772
50179d58
EB
17732011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1774
1775 * gcc-interface/ada-tree.h (TYPE_NULL_BOUNDS): New macro.
1776 (SET_TYPE_NULL_BOUNDS): Likewise.
1777 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Set again
1778 TREE_THIS_NOTRAP on the INDIRECT_REF node built for the template.
1779 * gcc-interface/trans.c (Identifier_to_gnu): Return initializers of fat
1780 pointer types.
1781 * gcc-interface/utils.c (create_var_decl_1): If the object is external,
1782 check that the initializer is a valid constant expression for use in
1783 initializing a static variable. Add missing guard.
1784 (update_pointer_to): Adjust TYPE_NULL_BOUNDS if set.
1785 (convert_to_fat_pointer): In the null fat pointer case, build a valid
1786 pointer for the bounds.
1787 * gcc-interface/utils2.c (compare_fat_pointers): New function.
1788 (build_binary_op) <EQ_EXPR>: Call it to compare fat pointers.
1789
ad1d36ba
EB
17902011-09-25 Eric Botcazou <ebotcazou@adacore.com>
1791
1792 * gcc-interface/ada-tree.h (TREE_THIS_NOTRAP): Redefine.
1793 * gcc-interface/trans.c (Identifier_to_gnu): Factor out common code in
1794 the by-ref case. Do not set TREE_READONLY on a renamed object. Set
1795 TREE_THIS_NOTRAP on UNCONSTRAINED_ARRAY_REF nodes.
1796 (Attribute_to_gnu) <Attr_Length>: Expand the use of the parameter cache
1797 to the indirect case.
1798 * gcc-interface/utils.c (convert) <UNCONSTRAINED_ARRAY_REF>: Preserve
1799 the TREE_THIS_NOTRAP flag.
1800
6162cec0
EB
18012011-09-25 Eric Botcazou <ebotcazou@adacore.com>
1802
1803 * gcc-interface/trans.c (Loop_Statement_to_gnu): In the case of an
1804 iteration scheme, always generate the do-while form if optimization
1805 is enabled. Use more straightforward test at the end.
1806
dee12fcd
EB
18072011-09-25 Eric Botcazou <ebotcazou@adacore.com>
1808
1809 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Subtype>: Use
1810 XNEW instead of xmalloc. Do not build useless pointer type.
1811 <E_Anonymous_Access_Subprogram_Type>: Use XNEW instead of xmalloc.
1812 * gcc-interface/trans.c (gnat_to_gnu) <N_Raise_Constraint_Error>: Tidy.
1813 * gcc-interface/utils2.c (build_unary_op): Remove local variable.
1814
dea976c4
EB
18152011-09-25 Eric Botcazou <ebotcazou@adacore.com>
1816
1817 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Do not promote
1818 the alignment if this doesn't prevent BLKmode access to the object.
1819
655ae828
IS
18202011-09-24 Iain Sandoe <iains@gcc.gnu.org>
1821
1822 * gcc-interface/Makefile.in (darwin): Do not issue the
1823 '-flat_namespace' linker flag during Ada build.
1824 * mlib-tgt-specific-darwin.adb: Remove '-flat_namespace' flag from the
1825 default shared library options.
1826
0e871c15
AO
18272011-09-19 Alexandre Oliva <aoliva@redhat.com>
1828
1829 * gcc-interface/decl.c (annotate_value): Look up expression for
1830 insertion in the cache at the end.
1831
1e6a52b4
AC
18322011-09-19 Arnaud Charlet <charlet@adacore.com>
1833
1834 * gcc-interface/Make-lang.in: Update dependencies.
1835
a3068ca6
AC
18362011-09-19 Steve Baird <baird@adacore.com>
1837
1838 * snames.ads-tmpl: Move declaration of Name_Annotate into range of
1839 configuration pragma names so that Is_Configuration_Pragma_Name
1840 will return True for Name_Annotate. Make corresponding change in
1841 Pragma_Id enumeration type. This is needed to allow an Annotate
1842 pragma to occur in a configuration pragma file (typically,
1843 a gnat.adc file).
1844 * gnat_ugn.texi: Add Annotate to the list of configuration pragmas.
1845 * gnat_rm.texi: Note that pragma Annotate may be used as a
1846 configuration pragma.
1847
18482011-09-19 Ed Schonberg <schonberg@adacore.com>
1849
1850 * a-cbmutr.adb, a-cbmutr.ads, a-cimutr.adb, a-cimutr.ads,
1851 a-comutr.adb, a-comutr.ads: Add iterator machinery for multiway trees.
1852
18532011-09-19 Yannick Moy <moy@adacore.com>
1854
1855 * exp_alfa.adb, exp_alfa.ads (Expand_Alfa_N_In): New function
1856 for expansion of set membership.
1857 (Expand_Alfa): Call expansion for N_In and N_Not_In nodes.
1858 * exp_ch4.adb, exp_ch4.ads (Expand_Set_Membership): Make procedure
1859 visible for use in Alfa expansion.
1860 * sem_ch5.adb (Analyze_Iterator_Specification): Introduce loop
1861 variable in Alfa mode.
1862
18632011-09-19 Thomas Quinot <quinot@adacore.com>
1864
1865 * s-osinte-darwin.ads: Change SIGADAABRT on Darwin to SIGABRT.
1866
18672011-09-19 Thomas Quinot <quinot@adacore.com>
1868
1869 * exp_ch9.adb: Minor reformatting.
1870
18712011-09-19 Hristian Kirtchev <kirtchev@adacore.com>
1872
1873 * freeze.adb (Build_Renamed_Body): Generic subprograms
1874 instantiations cannot be poperly inlined by the compiler, do
1875 not set the Body_To_Inline attribute in such cases.
1876 * sem_ch12.adb (Analyze_Subprogram_Instantiation): Inherit all
1877 inlining-related flags from the generic subprogram declaration.
1878
18792011-09-19 Thomas Quinot <quinot@adacore.com>
1880
1881 * exp_dist.adb, rtsfind.ads, sem_util.adb, sem_util.ads
1882 (Build_Stub_Type): Remove, instead copy components from
1883 System.Partition_Interface.RACW_Stub_Type.
1884 (RPC_Receiver_Decl): Remainder of code from old Build_Stub_Type routine.
1885 (Copy_Component_List): New subprogram.
1886
18872011-09-19 Yannick Moy <moy@adacore.com>
1888
1889 * lib-xref.adb (Generate_Reference): Ignore references to
1890 constants in Standard.
1891
e7fceebc
AC
18922011-09-19 Robert Dewar <dewar@adacore.com>
1893
1894 * err_vars.ads, errout.ads: Minor reformatting.
1895
18962011-09-19 Robert Dewar <dewar@adacore.com>
1897
1898 * aspects.ads (Impl_Defined_Aspects): New array
1899 * lib-writ.adb (No_Dependences): New name for No_Dependence
1900 * restrict.adb (No_Dependences): New name for No_Dependence
1901 (Check_Restriction_No_Specification_Of_Aspect): New
1902 procedure.
1903 (Set_Restriction_No_Specification_Of_Aspect): New procedure
1904 (Restricted_Profile_Result): New variable
1905 (No_Specification_Of_Aspects): New variable
1906 (No_Specification_Of_Aspect_Warning): New variable
1907 * restrict.ads (No_Dependences): New name for No_Dependence
1908 (Check_Restriction_No_Specification_Of_Aspect): New procedure
1909 (Set_Restriction_No_Specification_Of_Aspect): New procedure
1910 * s-rident.ads: Add restriction
1911 No_Implementation_Aspect_Specifications, this is also added to
1912 the No_Implementation_Extensions profile.
1913 * sem_ch13.adb (Analyze_Aspect_Specifications): Check
1914 No_Implementation_Defined_Aspects
1915 (Analyze_Aspect_Specifications): Check No_Specification_Of_Aspect
1916 * sem_prag.adb (Analyze_Aspect_Specifications): Check
1917 No_Implementation_Aspects
1918 (Analyze_Aspect_Specifications): Check No_Specification_Of_Aspect
1919 * snames.ads-tmpl (Name_No_Specification_Of_Aspect): New name
1920
19212011-09-19 Yannick Moy <moy@adacore.com>
1922
1923 * lib-xref.adb (Generate_Reference): Take into account multiple
1924 renamings for Alfa refs.
1925
19262011-09-19 Thomas Quinot <quinot@adacore.com>
1927
1928 * g-socthi-mingw.adb: Minor reformatting.
1929
19302011-09-19 Yannick Moy <moy@adacore.com>
1931
1932 * gnat1drv.adb (Adjust_Global_Switches): Set tagged type
1933 expansion to False in mode Alfa
1934
19352011-09-19 Pascal Obry <obry@adacore.com>
1936
1937 * mingw32.h: Remove obsolete code needed for old versions
1938 of MingW.
1939
e5a163fc
RD
19402011-09-19 Robert Dewar <dewar@adacore.com>
1941
1942 * errout.ads: Minor reformatting.
1943
6d7e5c54
AC
19442011-09-19 Ed Schonberg <schonberg@adacore.com>
1945
1946 * sem_ch6.adb (Analyze_Expression_Function): When the expression
1947 function is transformed into a declaration and a body, insert
1948 body at the end of the declarative part, to prevent premature
1949 freeze actions, and preserve original specification in the
1950 subprogram declaration.
1951
19522011-09-19 Vincent Celier <celier@adacore.com>
1953
1954 * projects.texi: Minor editing.
1955
99ba07a3
AC
19562011-09-19 Robert Dewar <dewar@adacore.com>
1957
1958 * sem_aggr.adb, lib-writ.ads, s-restri.ads, sem_ch6.adb,
1959 exp_aggr.adb: Minor reformatting.
1960
19612011-09-19 Yannick Moy <moy@adacore.com>
1962
1963 * lib-xref.adb (Generate_Reference): Change entity referenced
1964 to underlying object if any, or else reference to the HEAP.
1965
41781043
AC
19662011-09-15 Arnaud Charlet <charlet@adacore.com>
1967
1968 * gcc-interface/Make-lang.in: Update dependencies.
1969
804ff4c3
AC
19702011-09-15 Robert Dewar <dewar@adacore.com>
1971
1972 * tree_io.ads: Minor reformatting.
1973 * a-intnam.ads: Fix bad header.
1974
19752011-09-15 Thomas Quinot <quinot@adacore.com>
1976
1977 * a-exexpr-gcc.adb: Minor reformatting.
1978
19792011-09-15 Yannick Moy <moy@adacore.com>
1980
1981 * sem_ch6.adb: Propagate information that an expression function comes
1982 from source (otherwise references to this entity are not stored).
1983
0b5b2bbc
AC
19842011-09-15 Robert Dewar <dewar@adacore.com>
1985
1986 * a-cdlili.adb, a-coinve.adb, a-stzunb-shared.ads, a-suezst.adb,
1987 a-suenco.adb, a-stwiun-shared.ads, a-cobove.adb, a-convec.adb,
1988 a-btgbso.adb, a-cbdlli.adb, a-suewst.adb: Minor reformatting.
1989
19902011-09-15 Ed Schonberg <schonberg@adacore.com>
1991
1992 * sem_ch6.adb (Analyze_Expression_Function): Code cleanup:
1993 if the expression function is not a completion, create a
1994 new specification for the generated declaration, and keep the
1995 original specification in the generated body. Shorter code also
1996 ensures that proper warnings are generated for unused formals
1997 in all cases.
1998
19992011-09-15 Sergey Rybin <rybin@adacore.com>
2000
2001 * tree_io.ads: Update ASIS_Version_Number because of the changes
2002 in the tree structures for expression functions.
2003
20042011-09-15 Arnaud Charlet <charlet@adacore.com>
2005
2006 * s-osinte-aix.ads, s-osinte-darwin.ads, s-osinte-freebsd.ads,
2007 s-osinte-hpux.ads, s-osinte-lynxos.ads, s-osinte-solaris-posix.ads,
2008 s-taprop-posix.adb (CLOCK_MONOTONIC): New constant.
2009 (CLOCK_REALTIME): Fix wrong value on some OSes.
2010 * s-taprop-posix.adb (Monotonic_Clock): Use CLOCK_MONOTONIC.
2011
7e169899
EB
20122011-09-11 Eric Botcazou <ebotcazou@adacore.com>
2013
2014 * gcc-interface/utils.c (maybe_unconstrained_array): In the reference
2015 to unconstrained array case, deal with each branch of a COND_EXPR.
2016 * gcc-interface/utils2.c (build_allocator): Deal with each branch of
2017 a COND_EXPR in the initializer, if present.
2018
819a653e
EB
20192011-09-11 Eric Botcazou <ebotcazou@adacore.com>
2020
2021 * gcc-interface/decl.c (maybe_pad_type): Do not try to change the form
2022 of an addressable type.
2023 * gcc-interface/trans.c (gnat_gimplify_expr) <VIEW_CONVERT_EXPR>: New.
2024 Deal with those cases for which creating a temporary is mandatory.
2025
c946adde
EB
20262011-09-11 Eric Botcazou <ebotcazou@adacore.com>
2027
2028 * gcc-interface/trans.c (call_to_gnu): Use local variable. Make sure
2029 this is a real formal parameter before testing whether it is by ref.
2030
dddf8120
EB
20312011-09-11 Eric Botcazou <ebotcazou@adacore.com>
2032
2033 * gcc-interface/gigi.h (build_call_0_expr): Delete.
2034 (build_call_1_expr): Likewise.
2035 (build_call_2_expr): Likewise.
2036 (build_call_n_expr): New prototype.
2037 * gcc-interface/decl.c (gnat_to_gnu_entity): Use build_call_n_expr.
2038 * gcc-interface/trans.c (establish_gnat_vms_condition_handler): Ditto.
2039 (Handled_Sequence_Of_Statements_to_gnu): Likewise.
2040 (Exception_Handler_to_gnu_zcx): Likewise.
2041 (gnat_to_gnu): Likewise.
2042 (build_binary_op_trapv): Likewise.
2043 * gcc-interface/utils2.c (build_call_0_expr): Delete.
2044 (build_call_1_expr): Likewise.
2045 (build_call_2_expr): Likewise.
2046 (build_call_n_expr): New function.
2047 (build_call_raise): Use build_call_n_expr.
2048 (build_call_raise_range): Likewise.
2049 (build_call_raise_column): Likewise.
2050 (build_call_alloc_dealloc_proc): Likewise.
2051 (maybe_wrap_malloc): Likewise.
2052 (maybe_wrap_free): Likewise.
2053
d8e38554
EB
20542011-09-11 Eric Botcazou <ebotcazou@adacore.com>
2055
2056 * gcc-interface/trans.c (build_return_expr): Use void_type_node for
2057 MODIFY_EXPR.
2058 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Assert that
2059 the result type is null if ENABLE_CHECKING. Set operation_type at the
2060 end unconditionally if not set in the previous cases.
2061 Use build2 and void_type_node for MODIFY_EXPR.
2062 (build_allocator): Use NULL_TREE for MODIFY_EXPR.
2063
416de7d5
EB
20642011-09-08 Eric Botcazou <ebotcazou@adacore.com>
2065
2066 * gcc-interface/utils.c (unchecked_convert): Use a field of the right
2067 precision when converting to or from an integral type whose precision
2068 is not equal to its size.
2069
88b76013
IS
20702011-09-08 Iain Sandoe <iains@gcc.gnu.org>
2071
416de7d5 2072 * traceback.c (Darwin) USE_GCC_UNWINDER for Darwin versions >= 8.
88b76013 2073
1aeee5ad
IS
20742011-09-07 Iain Sandoe <iains@gcc.gnu.org>
2075
416de7d5 2076 * gcc-interface/Makefile.in (darwin): Provide powerpc64 system
1aeee5ad
IS
2077 implementation.
2078 * system-darwin-ppc64.ads: New file.
2079
f61fc398
IS
20802011-09-06 Iain Sandoe <iains@gcc.gnu.org>
2081
2082 * gcc-interface/Makefile.in (gnatlib-shared-darwin): Remove
2083 reference to "-lm".
2084
84ef27d3
IS
20852011-09-06 Iain Sandoe <iains@gcc.gnu.org>
2086
2087 * gcc-interface/Makefile.in (darwin, SO_OPTS): Provide architecture
2088 size switches to the link phase for shared libs.
2089
a1bf1ec7
IS
20902011-09-06 Iain Sandoe <iains@gcc.gnu.org>
2091
416de7d5 2092 * gcc-interface/Makefile.in (x86_64 darwin arch): Adjust
a1bf1ec7
IS
2093 LIBGNAT_TARGET_PAIRS for x86 and x86_64 variants.
2094
e972fd52
AC
20952011-09-06 Arnaud Charlet <charlet@adacore.com>
2096
2097 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in
2098 (gnattools, regnattools, cross-gnattools, canadian-gnattools,
2099 gnatlib, gnatlib-sjlj, gnatlib-zcx, gnatlib-shared, gnatlib_and_tools):
2100 New targets.
2101 (TOOLS_FLAGS_TO_PASS): New.
2102 (../stamp-tools): Reintroduce, to avoid merge conflicts.
2103
ef417be1
RD
21042011-09-06 Robert Dewar <dewar@adacore.com>
2105
2106 * sem_ch10.adb, impunit.ads, impunit.adb (Not_Impl_Defined_Unit): New
2107 name for Is_RM_Defined_Unit. Also several fixes to this unit.
2108
0a034606
RD
21092011-09-06 Robert Dewar <dewar@adacore.com>
2110
2111 * impunit.ads, impunit.adb (Is_RM_Defined_Unit): New function.
2112 * s-rident.ads: New restriction No_Implementation_Units
2113 (this restriction is also part of the profile
2114 No_Implementation_Extensions)
2115 * sem_ch10.adb (Analyze_With_Clause): Add check for
2116 No_Implementation_Units restriction.
2117
ebb6faaa
AC
21182011-09-06 Jerome Guitton <guitton@adacore.com>
2119
2120 * sysdep.c (__gnat_get_task_options): Disable VX_SPE_TASK
2121 on vThreads.
2122
21232011-09-06 Thomas Quinot <quinot@adacore.com>
2124
2125 * s-solita.adb: Minor reformatting.
2126
21272011-09-06 Ed Schonberg <schonberg@adacore.com>
2128
2129 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): The body that
2130 is a rewriting of an expression function does not freeze previous
2131 entities.
2132
21332011-09-06 Robert Dewar <dewar@adacore.com>
2134
2135 * impunit.adb (Is_Known_Unit): Fix bad handling of Ada 2012 case
2136
60435286
TG
21372011-09-06 Tristan Gingold <gingold@adacore.com>
2138
2139 * gcc-interface/Makefile.in: Handle e500v2-wrs-vxworksae like
2140 powerpc-wrs-vxworksae.
2141
08f8a983
AC
21422011-09-06 Thomas Quinot <quinot@adacore.com>
2143
2144 * s-os_lib.ads (Spawn): Minor documentation clarification,
2145 Success is True for a zero exit status.
2146
21472011-09-06 Ed Schonberg <schonberg@adacore.com>
2148
2149 * sem_ch5.adb: Add message for common iterator error.
2150
21512011-09-06 Ed Schonberg <schonberg@adacore.com>
2152
2153 * exp_ch3.adb (Build_Initialization_Call): If the target is a
2154 selected component discriminated by a current instance, replace
2155 the constraint with a reference to the target object, regardless
2156 of whether the context is an init_proc.
2157
21582011-09-06 Robert Dewar <dewar@adacore.com>
2159
2160 * exp_attr.adb: Descriptor_Size is never static.
2161
21622011-09-06 Robert Dewar <dewar@adacore.com>
2163
2164 * gnat_ugn.texi: Add documentation for LSLOC metric in gnatmetric
2165
21662011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
2167
2168 * gnat_rm.texi: Clarify that attribute Descriptor_Size is
2169 non-static.
2170
21712011-09-06 Ed Schonberg <schonberg@adacore.com>
2172
2173 * sem_res.adb (Resolve): An expression that is the body of an
2174 expression function does not freeze.
2175
21762011-09-06 Matthew Heaney <heaney@adacore.com>
2177
2178 * a-csquin.ads, a-cusyqu.adb, a-cbprqu.adb, a-cbsyqu.adb,
2179 a-cuprqu.adb: Changed copyright notice to indicate current
2180 year only.
2181
21822011-09-06 Vincent Celier <celier@adacore.com>
2183
2184 * prj.adb: Minor spelling error fix in comment
2185 * sem_res.adb: Minor reformatting
2186
21872011-09-06 Pascal Obry <obry@adacore.com>
2188
2189 * sysdep.c (winflush_nt): Removed as not needed anymore.
2190 (winflush_95): Likewise.
2191 (winflush_init): Likewise.
2192 (winflush_function): Likewise.
2193 (getc_immediate_common): Remove call to winflush_function.
2194
cb3d8731
HK
21952011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
2196
2197 * exp_attr.adb (Expand_N_Attribute_Reference): Rewrite the
2198 processing for Descriptor_Size.
2199 * gnat_rm.texi: Rephrase the wording for attribute Descriptor_Size
2200 to account for its broader usage.
2201 * sem_attr.adb (Analyze_Attribute): Change the error detection
2202 circuitry for Descriptor_Size as the attribute is now applicable
2203 to all types.
2204
f7e6fc47
RD
22052011-09-06 Robert Dewar <dewar@adacore.com>
2206
2207 * sem_attr.adb, prj-nmsc.adb, exp_aggr.adb: Minor reformatting.
2208
f8e9fc30
AC
22092011-09-06 Ed Schonberg <schonberg@adacore.com>
2210
2211 * lib-xref.adb (OK_To_Set_Referenced): A reference to a formal
2212 in a parameter association must not set the Referenced flag on
2213 the formal.
2214 * prj-nmsc.adb (Check_File_Naming_Schemes): Remove useless formal
2215
22162011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
2217
2218 * gnat_rm.texi: Add a section on attribute Descriptor_Size
2219
e8e38f35
AC
22202011-09-06 Arnaud Charlet <charlet@adacore.com>
2221
2222 * gcc-interface/Makefile.in (common-tools, gnatmake-re,
2223 gnatlink-re): Speed up by using -j0.
2224
ba759acd
AC
22252011-09-06 Yannick Moy <moy@adacore.com>
2226
2227 * sem_ch13.adb (Analyze_Aspect_Specifications): Call
2228 Set_Corresponding_Aspect when creating pragma from aspect.
2229 (Add_Predicates): Use new field Corresponding_Aspect.
2230 * sem_prag.adb (Analyze_Pragma): Make Pname hold source aspect
2231 name when present, for the purpose of issuing error messages;
2232 remove local procedure Error_Pragma_Arg_Alternate_Name.
2233 * sinfo.adb, sinfo.ads (Corresponding_Aspect): New field in
2234 N_Pragma node.
2235 (From_Dynamic_Predicate, From_Static_Predicate): Remove fields from
2236 N_Pragma node.
2237
22382011-09-06 Robert Dewar <dewar@adacore.com>
2239
2240 * checks.adb, s-except.ads, g-socket.adb: Minor reformatting.
2241
22422011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
2243
2244 * exp_ch6.adb (Build_Heap_Allocator): Add new
2245 local variable Desig_Typ. Code and comment reformatting. Add
2246 machinery to ensure that the allocation uses a fat pointer when
2247 the type of the return object is a constrained array and the
2248 function return type is an unconstrained array.
2249
22502011-09-06 Vincent Celier <celier@adacore.com>
2251
2252 * make.adb, prj-part.adb, prj-nmsc.adb: Remove unused formal
2253 parameters in subprograms.
2254
22552011-09-06 Arnaud Charlet <charlet@adacore.com>
2256
2257 * s-taprop-mingw.adb (Finalize_TCB): Fix typo.
2258
22592011-09-06 Thomas Quinot <quinot@adacore.com>
2260
2261 * s-taprop-vxworks.adb, s-tpoaal.adb, s-tpopsp-vxworks.adb
2262 (System.Tasking.Primitive_Operations.Specific.Delete): Remove
2263 subprogram.
2264 (System.Tasking.Primitive_Operations.Specific.Set): If argument
2265 is null, destroy task specific data, to make API consistent with
2266 other platforms, and thus compatible with the shared version
2267 of s-tpoaal.adb.
2268 (System.Tasking.Primitive_Operations.ATCB_Allocation.Free_ATCB):
2269 Document the above assumption.
2270
f4f92d9d
AC
22712011-09-06 Ed Schonberg <schonberg@adacore.com>
2272
2273 * exp_ch6.adb (Expand_Inlined_Call): Fix use of uninitialized
2274 variable for type of return value when return type is
2275 unconstrained and context is an assignment.
2276
22772011-09-06 Ed Schonberg <schonberg@adacore.com>
2278
2279 * sem_ch8.adb (Check_Class_Wide_Actual): Do not generate body of
2280 class-wide operation if expansion is not enabled.
2281
22822011-09-06 Eric Botcazou <ebotcazou@adacore.com>
2283
2284 * checks.adb (Apply_Scalar_Range_Check): Deal with access
2285 type prefix.
2286
22872011-09-06 Yannick Moy <moy@adacore.com>
2288
2289 * sem_ch13.adb (Analyze_Aspect_Specifications, case
2290 Aspect_Invariant): Do not issue error at this point on illegal
2291 pragma placement, as this is checked later on when analyzing
2292 the corresponding pragma.
2293 * sem_prag.adb (Error_Pragma_Arg_Alternate_Name): New procedure
2294 similar to Error_Pragma_Arg, except the source name of the
2295 aspect/pragma to use in warnings may be equal to parameter
2296 Alt_Name (Analyze_Pragma, case Pragma_Invariant): refine error
2297 message to distinguish source name of pragma/aspect, and whether
2298 the illegality resides in the type being public, or being private
2299 without a public declaration
2300
23012011-09-06 Thomas Quinot <quinot@adacore.com>
2302
2303 * g-socket.adb (Check_For_Fd_Set): On Windows, no need for bitmap
2304 size check (fd_set is implemented differently on that platform).
2305
23062011-09-06 Thomas Quinot <quinot@adacore.com>
2307
2308 * s-taprop-vxworks.adb, s-taprop-tru64.adb, s-taprop-vms.adb,
2309 s-tpoaal.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
2310 s-taprop-solaris.adb, s-taprop-irix.adb, s-taprop.ads,
2311 s-taprop-hpux-dce.adb, s-taprop-dummy.adb, s-taprop-posix.adb
2312 (ATCB_Allocation): New subpackage of
2313 System.Tasking.Primitive_Operations, shared across all targets
2314 with full tasking runtime.
2315 (ATCB_Allocation.New_ATCB): Moved there (from target specific
2316 s-taprop bodies).
2317 (ATCB_Allocation.Free_ATCB): New subprogram. Deallocate an ATCB,
2318 taking care of establishing a local temporary ATCB if the one
2319 being deallocated is Self, to avoid a reference to the freed
2320 ATCB in Abort_Undefer.
2321
23222011-09-06 Thomas Quinot <quinot@adacore.com>
2323
2324 * s-tassta.adb, s-taskin.ads (Free_Task): If the task is not
2325 terminated, mark it for deallocation upon termination.
2326 (Terminate_Task): Call Free_Task again if the task is marked
2327 for automatic deallocation upon termination.
2328
df177175
RD
23292011-09-06 Robert Dewar <dewar@adacore.com>
2330
2331 * a-cbprqu.ads, a-cbsyqu.ads, a-cuprqu.ads, a-cusyqu.ads,
2332 a-intnam-aix.ads, a-intnam-darwin.ads, a-intnam-dummy.ads,
2333 a-intnam-freebsd.ads, a-intnam-hpux.ads, a-intnam-irix.ads,
2334 a-intnam-linux.ads, a-intnam-lynxos.ads, a-intnam-mingw.ads,
2335 a-intnam-solaris.ads, a-intnam-tru64.ads,
2336 a-intnam-vms.ads, a-intnam-vxworks.ads, a-intnam.ads, interfac.ads,
2337 cstand.adb, s-maccod.ads: Mark all entities as Implementation_Defined
2338 * einfo.ads, einfo.adb (Is_Implementation_Defined): New flag
2339 * par-prag.adb: Add dummy entry for pragma Implementation_Defined
2340 * s-rident.ads: Add new restriction No_Implementation_Identifiers
2341 Add new profile No_Implementation_Extensions
2342 * sem_prag.adb: Implement pragma Implementation_Defined Implement
2343 profile No_Implementation_Extensions
2344 * sem_util.adb: Minor reformatting (Set_Entity_With_Style_Check):
2345 Check violation of restriction No_Implementation_Identifiers
2346 * snames.ads-tmpl: Add entries for pragma Implementation_Defined
2347 Add entry for Name_No_Implementation_Extensions
2348
23492011-09-06 Robert Dewar <dewar@adacore.com>
2350
2351 * impunit.ads: Minor reformatting.
2352
b991dd43
AC
23532011-09-06 Robert Dewar <dewar@adacore.com>
2354
2355 * ali.adb, sem_ch13.adb, lib-xref.adb: Minor reformatting.
2356
23572011-09-06 Pascal Obry <obry@adacore.com>
2358
2359 * s-osinte-linux.ads, s-oscons-tmplt.c: Use oscons to define sigset_t
2360 types.
2361
516785cc
AC
23622011-09-06 Robert Dewar <dewar@adacore.com>
2363
2364 * g-socket.adb: Minor reformatting
2365
23662011-09-06 Javier Miranda <miranda@adacore.com>
2367
2368 * ali.adb (Scan_ALI): Add missing support to load references of
2369 entities imported from other languages.
2370 * ali.ads (Xref_Record): Adding new fields to store the language and
2371 name of an imported entity.
2372 * lib-xref.adb (Output_Import_Export_Info): Fix typo
2373 in comment.
2374
23752011-09-06 Ed Schonberg <schonberg@adacore.com>
2376
2377 * sem_prag.adb (Analyze_Pragma, case Type_Invariant): A type invariant
2378 is allowed on a full type declaration if it is the completion of
2379 a private declarations.
2380 * sem_ch13.adb (Analyze_Aspect_Specifications): An invariant
2381 aspect is allowed on a full type declaration in the private part
2382 of a package.
2383
96691943
AC
23842011-09-06 Robert Dewar <dewar@adacore.com>
2385
2386 * sem_ch8.ads: Minor reformatting
2387
23882011-09-06 Thomas Quinot <quinot@adacore.com>
2389
2390 * s-oscons-tmplt.c, g-socket.adb (GNAT.Sockets.Clear,Set,Is_Set):
2391 Guard against socket values that are not in [0;FD_SETSIZE[
2392
54bf19e4
AC
23932011-09-06 Robert Dewar <dewar@adacore.com>
2394
2395 * s-osinte-linux.ads, a-iteint.ads, exp_ch6.adb, s-solita.adb: Minor
2396 reformatting.
2397
23982011-09-06 Arnaud Charlet <charlet@adacore.com>
2399
2400 * s-linux-alpha.ads: Minor reformatting
2401 * s-oscons-tmplt.c: Fix generated comments in s-oscons template.
2402 Use sizeof instead of corresponding C defines in s-oscons template.
2403
5d42cba1
VG
24042011-09-06 Vadim Godunko <godunko@adacore.com>
2405
2406 * a-convec.ads, a-iteint.ads: Minor reformatting.
2407
77aa62e7
AC
24082011-09-06 Vincent Celier <celier@adacore.com>
2409
2410 * projects.texi: Add menus and @node lines.
2411
24122011-09-06 Ed Schonberg <schonberg@adacore.com>
2413
2414 * exp_ch6.adb (Expand_Inlined_Call): Handle properly the case
2415 where the return type is an unconstrained array and the context
2416 is an assignment. Optimize the case when the target of the
2417 assignment is a selected component.
2418
24192011-09-06 Arnaud Charlet <charlet@adacore.com>
2420
2421 * s-solita.adb: Update comments.
2422
24232011-09-06 Pascal Obry <obry@adacore.com>
2424
2425 * s-linux.ads, s-linux-alpha.ads, s-linux-hppa.ads, s-linux-mipsel.ads,
2426 s-linux-sparc.ads: Remove hard coded and now wrong definitions.
2427 * s-oscons-tmplt.c: Add support for generating pthread related
2428 types size on GNU/Linux as done for Darwin.
2429 * s-osinte-linux.ads: Use s-oscons to define the pthread types.
2430
886b5a18
AC
24312011-09-06 Robert Dewar <dewar@adacore.com>
2432
2433 * exp_ch6.adb: Fix minor typo.
2434
24352011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
2436
2437 * exp_ch7.adb: Remove with and use clauses for Get_Targ.
2438 (Alignment_Of): Moved to the body of Nearest_Multiple_Rounded_Up.
2439 (Double_Size_Of): Alphabetized. Update the comment on usage.
2440 (Make_Finalize_Address_Stmts): Update comments and reformat code.
2441 (Nearest_Multiple_Rounded_Up): New routine.
2442 (Size_Of): Update comment on usage. The generated expression now
2443 accounts for alignment gaps by rounding the size of the type to the
2444 nearest multiple rounded up of the type's alignment.
2445
57a3fca9
AC
24462011-09-06 Robert Dewar <dewar@adacore.com>
2447
2448 * exp_ch7.adb, g-comlin.adb: Minor reformatting.
2449
24502011-09-06 Steve Baird <baird@adacore.com>
2451
2452 * exp_ch4.adb (Expand_Allocator_Expression): Look through
2453 derived subprograms in checking for presence of an
2454 Extra_Accessibility_Of_Result formal parameter.
2455 * exp_ch6.adb (Expand_Call): Look through derived subprograms in
2456 checking for presence of an Extra_Accessibility_Of_Result formal
2457 parameter.
2458 (Expand_Call.Add_Actual_Parameter): Fix a bug in the
2459 case where the Parameter_Associatiations attribute is already set,
2460 but set to an empty list.
2461 (Needs_Result_Accessibility_Level):
2462 Unconditionally return False. This is a temporary
2463 change, disabling the Extra_Accessibility_Of_Result
2464 mechanism.
2465 (Expand_Simple_Function_Return): Check for
2466 Extra_Accessibility_Of_Result parameter's presence instead of
2467 testing Ada_Version when generating a runtime accessibility
2468 check which makes use of the parameter.
2469
eaed0c37
AC
24702011-09-06 Ed Schonberg <schonberg@adacore.com>
2471
2472 * exp_ch4.adb (Expand_N_Case_Expression): Actions created for the
2473 expression in a given case alternative must be attached to the
2474 statement list of the ccrresponding case statement alternative
2475 They cannot be propagated ahead of the case statement, because
2476 the validity of the expression that generated the action may
2477 hold only for that alternative.
2478
24792011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
2480
2481 * exp_ch7.adb: Remove with and use clauses for Get_Targ.
2482 (Alignment_Of): Remove the code for strict alignment targets.
2483 (Double_Alignment_Of): Removed.
2484 (Double_Size_Of): New routine.
2485 (Make_Finalize_Address_Stmts): Change the
2486 calculation of the dope's size. Update relevant comments.
2487 (Size_Of): New routine.
2488
b8a93198
AC
24892011-09-06 Steve Baird <baird@adacore.com>
2490
2491 * einfo.ads (Extra_Accessibility): Update associated comment to use
2492 the term "present" correctly ("present" just means that it is not
2493 an error to query the value of the attribute - it does not imply
2494 that the value must be non-null).
2495 (Extra_Constrained): Ditto.
2496 (Is_Visible_Formal): Ditto.
2497 (Extra_Accessibility_Of_Result) Ditto; also add Inline pragma.
2498 (Set_Extra_Accessibility_Of_Result): Add Inline pragma.
2499 * exp_ch4.adb (Expand_Allocator_Expression): Improve a comment.
2500 * exp_ch6.adb (Expand_Call): The callee may require an
2501 Extra_Accessibility_Of_Result actual parameter even if Ada_Version
2502 < Ada_2012. This can occur if the callee is exported from a Gnat
2503 runtimes unit. Also improve a comment.
2504
25052011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
2506
2507 * exp_ch7.adb: Add with and use clauses for Get_Targ.
2508 (Alignment_Of): Rename formal parameter Some_Typ
2509 to Typ, update related comment. Use the allocator alignment on
2510 strict alignment targets such as SPARC.
2511 (Double_Alignment_Of): Rename formal parameter Some_Typ to Typ, update
2512 related comment.
2513
25142011-09-06 Gary Dismukes <dismukes@adacore.com>
2515
2516 * sem_ch9.adb (Check_Interfaces): Test
2517 Is_Limited_Type rather than Is_Limited_Record when checking that
2518 the partial view of a synchronized full view must be limited.
2519
25202011-09-06 Emmanuel Briot <briot@adacore.com>
2521
2522 * g-comlin.adb (Free): Fix memory leak.
2523
ebf494ec
RD
25242011-09-06 Robert Dewar <dewar@adacore.com>
2525
2526 * sem_util.adb, exp_ch6.adb: Minor reformatting and code reorganization.
2527
63585f75
SB
25282011-09-06 Steve Baird <baird@adacore.com>
2529
2530 * einfo.ads (Extra_Accessibility_Of_Result): New function; in the
2531 (Ada2012) cases described in AI05-0234 where the accessibility
2532 level of a function result is "determined by the point of
2533 call", an implicit parameter representing that accessibility
2534 level is passed in. Extra_Accessibilty_Of_Result yields this
2535 additional formal parameter. Extra_Accessibility_Of_Result
2536 is analogous to the existing Extra_Accessibility
2537 function used in the implementation of access parameters.
2538 (Set_Extra_Accessibility_Of_Result): New procedure; sets
2539 Extra_Accessibility_Of_Result attribute.
2540 * einfo.adb (Extra_Accessibility_Of_Result): New function.
2541 (Set_Extra_Accessibility_Of_Result): New procedure.
2542 (Write_Field19_Name): Display Extra_Accessibilty_Of_Result attribute.
2543 * sem_util.adb (Dynamic_Accessibility_Level): Set Etype of
2544 an accessibility level literal to Natural; introduce a nested
2545 function, Make_Level_Literal, to do this.
2546 * exp_ch6.ads (Needs_Result_Accessibility_Level): New function;
2547 determines whether a given function (or access-to-function
2548 type) needs to have an implicitly-declared accessibility-level
2549 parameter added to its profile.
2550 (Add_Extra_Actual_To_Call): Export an existing procedure which was
2551 previously declared in the body of Exp_Ch6.
2552 * exp_ch6.adb (Add_Extra_Actual_To_Call): Export declaration by moving
2553 it to exp_ch6.ads.
2554 (Has_Unconstrained_Access_Discriminants): New Function; a
2555 predicate on subtype entities which returns True if the given
2556 subtype is unconstrained and has one or more access discriminants.
2557 (Expand_Call): When expanding a call to a function which takes an
2558 Extra_Accessibility_Of_Result parameter, pass in the appropriate
2559 actual parameter value. In the case of a function call which is
2560 used to initialize an allocator, this may not be possible because
2561 the Etype of the allocator may not have been set yet. In this
2562 case, we defer passing in the parameter and handle it later in
2563 Expand_Allocator_Expression.
2564 (Expand_Simple_Function_Return): When returning from a function which
2565 returns an unconstrained subtype having at least one access
2566 discriminant, generate the accessibility check needed to ensure that
2567 the function result will not outlive any objects designated by its
2568 discriminants.
2569 (Needs_Result_Accessibility_Level): New function; see exp_ch6.ads
2570 description.
2571 * exp_ch4.adb (Expand_Allocator_Expression): When a function call
2572 is used to initialize an allocator, we may need to pass in "the
2573 accessibility level determined by the point of call" (AI05-0234)
2574 to the function. Expand_Call, where such actual parameters are
2575 usually generated, is too early in this case because the Etype of
2576 the allocator (which is used in determining the level to be passed
2577 in) may not have been set yet when Expand_Call executes. Instead,
2578 we generate code to pass in the appropriate actual parameter
2579 in Expand_Allocator_Expression.
2580 * sem_ch6.adb (Create_Extra_Formals): Create
2581 the new Extra_Accessibility_Of_Result formal if
2582 Needs_Result_Accessibility_Level returns True. This includes the
2583 introduction of a nested procedure, Check_Against_Result_Level.
2584
1a982c6e
AC
25852011-09-06 Arnaud Charlet <charlet@adacore.com>
2586
2587 * gcc-interface/Makefile.in (X86_TARGET_PAIRS): Remove duplicate
2588 declaration.
2589
e42bcfa3
AC
25902011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
2591
2592 * s-finmas.adb (Set_Finalize_Address): Explain the reason
2593 for the synchronization. Move the test for null from
2594 s-stposu.Allocate_Any_Controlled to this routine since the check
2595 needs to be protected too.
2596 (Set_Heterogeneous_Finalize_Address): Explain the reason for the
2597 synchronization code.
2598 * s-finmas.ads (Set_Heterogeneous_Finalize_Address): Add comment
2599 explaining the context in which this routine is used.
2600 * s-stposu.adb (Allocate_Any_Controlled): Move the test for null
2601 to s-finmas.Set_Finalize_Address.
2602
26032011-09-05 Ed Schonberg <schonberg@adacore.com>
2604
2605 * einfo.ads: Document that itypes have no parent field.
2606
26072011-09-05 Robert Dewar <dewar@adacore.com>
2608
2609 * rtsfind.adb (Check_CRT): Check for overloaded entity
2610 * rtsfind.ads: Document that entities to be found by rtsfind
2611 cannot be overloaded
2612 * s-taenca.adb, s-tasren.adb, s-tpobop.adb, s-tpoben.ads, s-tpoben.adb
2613 (Lock_Entries_With_Status): New name for Lock_Entries with two
2614 arguments (changed to meet rtsfind no overloading rule).
2615
544e7c17
AC
26162011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
2617
2618 * s-finmas.adb (Set_Finalize_Address (Address,
2619 Finalize_Address_Ptr)): Renamed to Set_Heterogeneous_Finalize_Address.
2620 (Set_Finalize_Address (in out Finalization_Master,
2621 Finalize_Address_Ptr): Add synchronization code.
2622 * s-finmas.ads (Set_Finalize_Address (Address,
2623 Finalize_Address_Ptr)): Renamed to Set_Heterogeneous_Finalize_Address.
2624 * s-stposu.adb (Allocate_Any_Controlled): Update the call to
2625 Set_Finalize_Address for the heterogeneous case.
2626
26272011-09-05 Ed Schonberg <schonberg@adacore.com>
2628
2629 * sem_ch3.adb: Undo previous change, not suitable after all.
2630
26312011-09-05 Robert Dewar <dewar@adacore.com>
2632
2633 * einfo.ads: Minor comment clarification.
2634
0613fb33
AC
26352011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
2636
2637 * exp_ch6.adb (Move_Activation_Chain): Rewritten. The routine
2638 no longer needs to search through the entities of the return
2639 statement scope to find the _chain.
2640 * sem_ch5.adb: Add with and use clauses for Exp_Ch6 and Sem_Ch6.
2641 (Analyze_Block_Statement): Add local variable
2642 Is_BIP_Return_Statement. Add machinery to install all entities
2643 produced by the expansion of the return object declaration.
2644 (Install_Return_Entities): New routine.
2645 * sem_ch6.ads, sem_ch6.adb (Install_Entity): Moved from body to spec.
2646
26472011-09-05 Ed Schonberg <schonberg@adacore.com>
2648
2649 * sem_ch10.adb (Analyze_Context): Apply simple fixup if context
2650 of subunit is incomplete.
2651 (Analyze_Proper_Body): If parent spec is not available, do not
2652 attempt analysis.
2653
5dcab3ca
AC
26542011-09-05 Ed Schonberg <schonberg@adacore.com>
2655
2656 * sem_disp.adb (Find_Controlling_Arg): Add checks for
2657 interface type conversions, that are expanded into dereferences.
2658
26592011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
2660
2661 * sem_ch6.adb (Analyze_Subprogram_Body_Helper):
2662 Examine the parameter and return profile of a subprogram and swap
2663 any incomplete types coming from a limited context with their
2664 corresponding non-limited views.
2665 (Exchange_Limited_Views): New routine.
2666
26672011-09-05 Ed Schonberg <schonberg@adacore.com>
2668
2669 * sem_ch3.adb (Prepare_Private_Subtype_Completion): Set parent
2670 of internal entity to the subtype declaration, so that when
2671 entities are subsequently exchanged in a package body, the tree
2672 remains properly formatted for ASIS.
2673
8da1a312
AC
26742011-09-05 Johannes Kanig <kanig@adacore.com>
2675
2676 * g-comlin.adb (Set_Usage): Additional optional argument to set help
2677 message.
2678 (Display_Help): display the user given help message, if available.
2679
26802011-09-05 Ed Schonberg <schonberg@adacore.com>
2681
2682 * sem_ch3.adb (OK_For_Limited_Init_In_05): The expression
2683 is legal if the original node is an identifier that is a
2684 parameterless function call.
2685
69b73847
PO
26862011-09-05 Pascal Obry <obry@adacore.com>
2687
2688 * prj-nmsc.adb: Minor reformatting.
2689 Add support for standalone aggregate library.
2690 (Check_Stand_Alone_Library): Handle standalone aggregate library.
2691 * projects.texi: Fix documentation for aggregate library projects.
2692
81bf2382
AC
26932011-09-05 Robert Dewar <dewar@adacore.com>
2694
2695 * sem_ch6.adb: Minor reformatting.
2696
26972011-09-05 Matthew Gingell <gingell@adacore.com>
2698
2699 * s-tassta.adb (Task_Wrapper): Ensure that we don't try to write the
2700 stack guard page on PPC Linux. This patch ensures the 64K guard page at
2701 the bottom of the stack is not overwritten.
2702
13a0b1e8
AC
27032011-09-05 Thomas Quinot <quinot@adacore.com>
2704
2705 * exp_intr.adb, s-tasini.adb: Minor reformatting.
2706
27072011-09-05 Ed Schonberg <schonberg@adacore.com>
2708
2709 * sem_ch3.adb (Access_Definition): If an access type declaration
2710 appears in a child unit, the scope of whatever anonymous type
2711 may be generated is the child unit itself.
2712
27132011-09-05 Ed Schonberg <schonberg@adacore.com>
2714
2715 * sem_ch6.adb (Analyze_Expression_Function): Do not set
2716 Comes_From_Source on rewritten body.
2717 (Analyze_Subprogram_Body_Helper): Check that the original node for
2718 the body comes from source, when determining whether expansion
2719 of a protected operation is needed.
2720
20428725
AC
27212011-09-05 Ed Schonberg <schonberg@adacore.com>
2722
2723 * exp_aggr.adb (Replace_Type): If the target of the assignment is
2724 a selected component and the right-hand side is a self-referential
2725 access, the proper prefix of the rewritten attribute is a copy
2726 of the left-hand side, not of its prefix.
2727
27282011-09-05 Robert Dewar <dewar@adacore.com>
2729
2730 * sem_ch5.adb: Minor reformatting.
2731 * sem_ch3.adb: Minor code clean up.
2732
27332011-09-05 Jose Ruiz <ruiz@adacore.com>
2734
2735 * exp_ch9.adb (Make_Initialize_Protection): The fact that
2736 restriction No_Dynamic_Attachment is in effect or not should
2737 not influence the default priority associated to a protected
2738 object. With this change, when the restriction is in effect (as
2739 is the case for the Ravenscar profile) the default priority of
2740 a protected object with an interrupt handler is in the range of
2741 interrupt priorities (Default_Interrupt_Priority) as required
2742 by D.3(10).
2743
27442011-09-05 Arnaud Charlet <charlet@adacore.com>
2745
2746 * a-iteint.ads: Fix header.
2747
27482011-09-05 Vincent Celier <celier@adacore.com>
2749
2750 * prj-conf.adb (Do_Autoconf): Make sure Obj_Dir always ends
2751 with a directory separator to avoid output such as:
2752 "/path/to/objauto.cgpr" has been deleted.
2753
4a1bfefb
AC
27542011-09-05 Robert Dewar <dewar@adacore.com>
2755
2756 * sem_ch3.adb: Minor reformatting.
2757
27582011-09-05 Ed Schonberg <schonberg@adacore.com>
2759
2760 * sem_ch5.adb: Better error message.
2761
27622011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
2763
2764 * exp_aggr.adb: Add with and use clause for Exp_Ch6.
2765 (Expand_Array_Aggregate): Detect a special case of an aggregate
2766 which contains tasks in the context of an unexpanded return
2767 statement of a build-in-place function.
2768 * exp_ch6.adb: Add with and use clause for Exp_Aggr.
2769 (Expand_N_Extended_Return_Statement): Detect a delayed aggregate
2770 which contains tasks and expand it now that the original simple
2771 return statement has been rewritten.
2772 * exp_ch9.adb (Build_Activation_Chain_Entity): Code
2773 reformatting. Do not create a chain for an extended return
2774 statement if one is already available.
2775 (Has_Activation_Chain): New routine.
2776
9ec080cb
AC
27772011-09-05 Marc Sango <sango@adacore.com>
2778
2779 * sem_ch3.adb (Analyze_Object_Declaration): Remove
2780 the wrong test and add the correct test to detect the violation
2781 of illegal use of unconstrained string type in SPARK mode.
2782
27832011-09-05 Ed Schonberg <schonberg@adacore.com>
2784
2785 * sem_ch5.adb (Analyze_Iteration_Specification): Improve error
2786 message on an iterator over an array.
2787
27882011-09-05 Robert Dewar <dewar@adacore.com>
2789
2790 * lib-xref-alfa.adb: Minor reformatting.
2791
aeae67ed
RD
27922011-09-05 Robert Dewar <dewar@adacore.com>
2793
2794 * sem_ch3.adb, sem_res.adb, par.adb, par-ch6.adb, g-comlin.adb,
2795 exp_ch6.adb, lib-xref-alfa.adb: Minor reformatting.
2796
d72e7628
AC
27972011-09-05 Gary Dismukes <dismukes@adacore.com>
2798
2799 * exp_ch7.adb, exp_ch6.adb: Minor reformatting.
2800
28012011-09-05 Johannes Kanig <kanig@adacore.com>
2802
2803 * lib-xref-alfa.adb: Update comments.
2804
28052011-09-05 Thomas Quinot <quinot@adacore.com>
2806
2807 * sem_res.adb: Minor reformatting
2808
0d566e01
ES
28092011-09-05 Ed Schonberg <schonberg@adacore.com>
2810
2811 * exp_ch6.adb (Build_In_Place_Formal): If extra formals are not
2812 present, create them now. Needed in case the return type was
2813 a limited view in the function declaration.
2814 (Make_Build_In_Place_Call_In_Allocator): If return type contains
2815 tasks, build the activation chain for it. Pass a reference to
2816 the Master_Id in call to Add_Task_Actuals_To_Build_In_Place call.
2817 * exp_ch7.adb (Make_Set_Finalize_Address_Call): Clean up interface
2818 with build_in_place calls.
2819 * sem_ch9.adb (Analyze_Task_Type_Declaration): If partial view was
2820 incomplete, inatialize its Corresponding_Record_Type component.
2821 * sem_ch10.adb (Build_Chain): Initialize Private_Dependents field
2822 of limited views.
2823
ec09f261
AC
28242011-09-05 Johannes Kanig <kanig@adacore.com>
2825
2826 * lib-xref-alfa.adb (Is_Alfa_Reference): Filter constants from effect
2827 information.
2828
28292011-09-05 Ed Schonberg <schonberg@adacore.com>
2830
2831 * par-ch6.adb (P_Subprogram): In Ada2012 mode, if the subprogram
2832 appears within a package specification and the token after "IS"
2833 is not a parenthesis, assume that this is an unparenthesized
2834 expression function, even if the token appears in a line by
2835 itself.
2836 * par.adb: Clarify use of Labl field of scope stack in error
2837 recovery.
2838
7109f4f5
AC
28392011-09-05 Bob Duff <duff@adacore.com>
2840
2841 * sem_res.adb (Resolve_Intrinsic_Operator): Use unchecked
2842 conversions instead of normal type conversions in all cases where a
2843 type conversion would be illegal. In particular, use unchecked
2844 conversions when the operand types are private.
2845
28462011-09-05 Johannes Kanig <kanig@adacore.com>
2847
2848 * lib-xref-alfa.adb (Is_Alfa_Reference): Never declare effects on
2849 objects of task type or protected type.
2850
66dc8075
AC
28512011-09-05 Ed Schonberg <schonberg@adacore.com>
2852
2853 * sem_ch6.adb (Analyze_Expression_Function): If the expression
2854 function comes from source, indicate that so does its rewriting,
2855 so it is compatible with any subsequent expansion of the
2856 subprogram body (e.g. when it is a protected operation).
2857 * sem_ch4.adb: minor reformatting
2858
28592011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
2860
2861 * lib.adb (Check_Same_Extended_Unit): Comment rewriting. Use
2862 Get_Source_Unit rather than Get_Code_Unit as instantiation unfolding
2863 may lead to wrong ancestor package in the case of instantiated subunit
2864 bodies. If a subunit is instantiated, follow the chain of instantiations
2865 rather than the stub structure.
2866
bd38b431
AC
28672011-09-02 Robert Dewar <dewar@adacore.com>
2868
2869 * sem_ch4.adb, sem_ch6.adb: Minor reformatting.
2870 * gcc-interface/Make-lang.in: Update dependencies.
2871
28722011-09-02 Marc Sango <sango@adacore.com>
2873
2874 * sem_ch3.adb (Analyze_Object_Declaration): Change
2875 comment and add additional check to differentiate constant of
2876 type string from others unconstrained type.
2877
99d520ad
ES
28782011-09-02 Ed Schonberg <schonberg@adacore.com>
2879
2880 * sinfo.ads, sinfo.adb: New semantic attribute Premature_Use,
2881 present in incomplete type declarations to refine the error
2882 message the full declaration is in the same unit.
2883 * sem_ch4.adb (Analyze_Selected_Component): If the prefix is of
2884 an incomplete type, set the Premature_Use for additional message.
2885 * sem_ch3.adb (Find_Type_Name): If partial view is incomplete
2886 and Premature_Use is set, place additional information at the
2887 point of premature use.
2888
5b5588dd
AC
28892011-09-02 Bob Duff <duff@adacore.com>
2890
2891 * sem_ch6.adb: (Check_Post_State): Suppress warning
2892 "postcondition refers only to pre-state" when the expression has not
2893 yet been analyzed, because it causes false alarms. This can happen when
2894 the postcondition contains a quantified expression, because those are
2895 analyzed later. This is a temporary/partial fix.
2896 (Process_Post_Conditions): Minor: change wording of warning.
2897
28982011-09-02 Marc Sango <sango@adacore.com>
2899
2900 * sem_ch3.adb (Analyze_Object_Declaration): Detect the violation of
2901 illegal use of unconstrained string type in SPARK mode.
2902 * sem_res.adb (Analyze_Operator_Symbol): Set the
2903 right place where the string operand of concatenation should be
2904 violate in SPARK mode.
2905
bd603506
RD
29062011-09-02 Robert Dewar <dewar@adacore.com>
2907
2908 * sem_prag.adb, sem_util.adb, sem_ch6.adb, prj-nmsc.adb,
2909 exp_ch3.adb: Minor reformatting.
2910
24a120ac
AC
29112011-09-02 Vincent Celier <celier@adacore.com>
2912
2913 * prj-conf.adb (Add_Default_GNAT_Naming_Scheme): Declare "gcc"
2914 as the compiler driver so Is_Compilable returns True for sources.
2915 * prj-nmsc.adb (Override_Kind): When Kind is Sep, set the source
2916 for the body.
2917
29182011-09-02 Ed Schonberg <schonberg@adacore.com>
2919
2920 * sem_prag.adb (Analyze_PPC_In_Decl_Part): for a class-wide
2921 condition, a reference to a controlling formal must be interpreted
2922 as having the class-wide type (or an access to such) so that the
2923 inherited condition can be properly applied to any overriding
2924 operation (see ARM12 6.6.1 (7)).
2925
29262011-09-02 Tristan Gingold <gingold@adacore.com>
2927
2928 * init.c (__gnat_is_vms_v7): Fix case and add prototype
2929 for LIB$GETSYI.
2930
29312011-09-02 Javier Miranda <miranda@adacore.com>
2932
2933 * exp_ch3.adb (Expand_N_Object_Declaration): Do not copy the
2934 initializing expression of a class-wide interface object declaration
2935 if its type is limited.
2936
29372011-09-02 Johannes Kanig <kanig@adacore.com>
2938
2939 * sem_util.adb (Unique_Name): To obtain a unique name for enumeration
2940 literals, take into account the type name; the type is *not*
2941 the scope for an enumeration literal.
2942
29432011-09-02 Ed Schonberg <schonberg@adacore.com>
2944
2945 * sem_ch6.adb (Check_Overriding_Indicator): add special check
2946 to reject an overriding indicator on a user-defined Adjust
2947 subprogram for a limited controlled type.
2948
29492011-09-02 Ed Schonberg <schonberg@adacore.com>
2950
2951 * sem_res.adb (Resolve_Actuals): add missing call to Resolve
2952 for an actual that is a function call returning an unconstrained
2953 limited controlled type.
2954
29552011-09-02 Tristan Gingold <gingold@adacore.com>
2956
2957 * g-socthi-vms.adb (c_sendmsg, c_recvmsg): Use unpacked msg if on vms 7
2958
29592011-09-02 Johannes Kanig <kanig@adacore.com>
2960
2961 * alfa.ads (Name_Of_Heap_Variable): Change value of the HEAP variable
2962 from "HEAP" to __HEAP Change comment that refers to that variable
2963 * put_alfa.adb: Change comment that refers to that variable
2964
c5f5123f
AC
29652011-09-02 Robert Dewar <dewar@adacore.com>
2966
2967 * exp_ch4.adb, exp_ch6.adb, prj-nmsc.adb: Minor reformatting.
2968
29692011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
2970
2971 * exp_util.adb (Extract_Renamed_Object): Renamed to
2972 Find_Renamed_Object. This routine has been reimplemented and now uses
2973 tree traversal to locate a renamed object.
2974 (Is_Aliased): Replace call to Extract_Renamed_Object with
2975 Find_Renamed_Object.
2976
29772011-09-02 Tristan Gingold <gingold@adacore.com>
2978
2979 * init.c: (__gnat_is_vms_v7): New function.
2980
29812011-09-02 Olivier Hainque <hainque@adacore.com>
2982
2983 * tracebak.c (STOP_FRAME, ppc elf/vxworks case): Stop on frames
2984 that have a misaligned backchain, necessarily bogus.
2985
2bfa5484
HK
29862011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
2987
2988 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Do not create
2989 TSS routine Finalize_Address when compiling in Alfa mode.
2990 (Expand_Freeze_Record_Type): Do not create TSS routine
2991 Finalize_Address when compiling in Alfa mode.
2992 * exp_ch4.adb (Expand_Allocator_Expression): Do not produce a
2993 call to Set_Finalize_Address in Alfa mode because Finalize_Address is
2994 not built.
2995 (Expand_N_Allocator): Do not produce a call to
2996 Set_Finalize_Address in Alfa mode because Finalize_Address is not built.
2997 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Do not
2998 produce a call to primitive Set_Finalize_Address in Alfa mode because
2999 Finalize_Address is not built.
3000 * exp_ch7.adb (Build_Finalization_Master): Do not create
3001 finalization masters in Afa mode since they are not needed.
3002 (Build_Finalizer): Do not create scope and library-level
3003 finalizers in Alfa mode since they are not needed.
3004 * exp_util.adb (Build_Allocate_Deallocate_Proc): Do not expand
3005 "new" and "free" when applied to controlled objects in Alfa mode since
3006 this is not needed.
3007
7a0ddd20
AC
30082011-09-02 Vincent Celier <celier@adacore.com>
3009
3010 * prj-nmsc.db: (Check_Stand_Alone_Library): For SALs, allow
3011 only library names with the syntax of Ada identifiers, to avoid errors
3012 when compiling the binder generated files.
3013 * projects.texi: Document restriction on SAL library names
3014
30152011-09-02 Thomas Quinot <quinot@adacore.com>
3016
3017 * a-chtgbo.adb: Minor comment fix.
3018
439b6dfa
AC
30192011-09-02 Robert Dewar <dewar@adacore.com>
3020
3021 * lib-xref.adb: Minor reformatting
3022
30232011-09-02 Vincent Celier <celier@adacore.com>
3024
3025 * bindusg.adb, clean.adb, gnatchop.adb, gnatfind.adb, gnatlink.adb,
3026 gnatls.adb, gnatname.adb, gnatxref.adb, gprep.adb, makeusg.adb: Add
3027 --version and --help in usage.
3028 * switch.ads, switch.adb (Display_Usage_Version_And_Help): New procedure
3029
f2404867
AC
30302011-09-02 Bob Duff <duff@adacore.com>
3031
3032 * lib-xref.adb: (Hash): Avoid use of 'Mod attribute, because old
3033 compilers don't understand it.
3034
30352011-09-02 Gary Dismukes <dismukes@adacore.com>
3036
3037 * exp_attr.adb (Expand_N_Attribute_Reference): Pass the
3038 underlying subtype rather than its base type on the call to
3039 Build_Record_Or_Elementary_Input_Function, so that any
3040 constraints on a discriminated subtype will be available for
3041 doing the check required by AI05-0192.
3042 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
3043 If the prefix subtype of the 'Input attribute is a constrained
3044 discriminated subtype, then check each constrained discriminant value
3045 against the corresponding value read from the stream.
3046
029b67ba
YM
30472011-09-02 Yannick Moy <moy@adacore.com>
3048
3049 * usage.adb, warnsw.adb, sem_ch6.adb, opt.ads: Disable by default
3050 warnings on suspicious contracts, and enable them with -gnatwa.
3051
dc36a7e3
RD
30522011-09-02 Robert Dewar <dewar@adacore.com>
3053
3054 * exp_util.adb, exp_ch9.adb, sem_attr.adb, sem_ch6.adb: Minor
3055 reformatting.
3056
d5aa443c
AC
30572011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
3058
3059 * exp_ch9.adb (Install_Private_Data_Declarations): Add guards
3060 which ensure that restriction No_Dynamic_Attachment has not been
3061 violated.
3062 (Make_Initialize_Protection): Protected types with attach or
3063 interrupt handlers must not violate restriction No_Dynamic_Attachment.
3064 * exp_util.adb (Corresponding_Runtime_Package): Add a guard
3065 which ensures that restriction No_Dynamic_Attachment has not been
3066 violated.
3067 * sem_attr.adb: (Eval_Attribute): Transform
3068 VAX_Float_Type'First and 'Last into references to
3069 the temporaries which store the corresponding bounds. The
3070 transformation is needed since the back end cannot evaluate
3071 'First and 'Last on VAX.
3072 (Is_VAX_Float): New routine.
3073
30742011-09-02 Ed Schonberg <schonberg@adacore.com>
3075
3076 * sem_ch12.adb (Analyze_Subprogram_Instantiation): If the
3077 generic unit is not intrinsic and has an explicit convention,
3078 the instance inherits it.
3079
67c86178
AC
30802011-09-02 Robert Dewar <dewar@adacore.com>
3081
3082 * prj-dect.adb, prj-env.adb, prj-nmsc.adb, prj-proc.adb, prj-tree.adb,
3083 prj.adb, prj.ads, sem_ch5.adb: Minor reformatting.
3084
30852011-09-02 Thomas Quinot <quinot@adacore.com>
3086
3087 * sem_attr.adb (Analyze_Attribute, case Unrestriced_Access):
3088 Guard against a prefix that is an N_Has_Entity but has no
3089 associated entity.
3090
30912011-09-02 Yannick Moy <moy@adacore.com>
3092
3093 * lib-xref-alfa.adb (Is_Alfa_Reference): Ignore IN parameters in Alfa
3094 references.
3095
30962011-09-02 Yannick Moy <moy@adacore.com>
3097
3098 * opt.ads (Warn_On_Suspicious_Contract): New warning flag.
3099 * sem_ch3.adb (Analyze_Declarations): Call checker for suspicious
3100 contracts.
3101 * sem_ch6.adb, sem_ch6.ads (Check_Subprogram_Contract): New
3102 procedure looking for suspicious postconditions.
3103 * usage.adb (Usage): New options -gnatw.t and -gnatw.T.
3104 * warnsw.adb (Set_Dot_Warning_Switch): Take into account new
3105 options -gnatw.t and -gnatw.T.
3106
735ca1b9
PO
31072011-09-02 Pascal Obry <obry@adacore.com>
3108
3109 * prj.adb: Minor code refactoring. Move check for null project in
3110 Project_Changed.
3111 * projects.texi: Fix minor typos.
3112
86828d40
AC
31132011-09-02 Ed Schonberg <schonberg@adacore.com>
3114
3115 * sem_ch5.adb (Analyze_Iterator_Specification): If the domain
3116 of iteration is an expression, its value must be captured in a
3117 renaming declaration, so that modification of the elements is
3118 propagated to the original container.
3119
31202011-09-02 Pascal Obry <obry@adacore.com>
3121
3122 * prj-proc.adb, prj.adb, makeutl.adb, makeutl.ads, prj-dect.adb,
3123 prj-nmsc.adb, prj-util.adb, prj-conf.adb, prj-env.adb,
3124 prj-tree.adb: Minor reformatting and style fixes.
3125
83de674b
AC
31262011-09-02 Robert Dewar <dewar@adacore.com>
3127
3128 * s-rident.ads: Add new restriction No_Implicit_Aliasing
3129 * sem_attr.adb: (Analyze_Access_Attribute): Deal with
3130 No_Implicit_Aliasing
3131 (Analyze_Attribute, case Address): ditto
3132 (Analyze_Attribute, case Unrestricted_Access): ditto
3133 * sem_util.ads, sem_util.adb: (Is_Aliased_View): Handle
3134 No_Implicit_Aliasing restriction.
3135 * gnat_rm.texi: Add documentation for No_Implicit_Aliasing
3136
31372011-09-02 Ed Schonberg <schonberg@adacore.com>
3138
3139 * exp_util.adb: (Possible_Bit_Aligned_Object): If the object
3140 is an unchecked conversion, apply test to its expression.
3141
31422011-09-02 Javier Miranda <miranda@adacore.com>
3143
3144 * sem_ch3.adb (Check_Abstract_Overriding): When
3145 traversing the chain of aliased subprograms avoid reporting a
3146 redundant error on the current entity.
3147
31482011-09-02 Sergey Rybin <rybin@adacore.com>
3149
3150 * gnat_ugn.texi: Minor clean up.
3151
31522011-09-02 Bob Duff <duff@adacore.com>
3153
3154 * s-htable.adb (Set_If_Not_Present): Use renaming
3155 instead of ":=", because the type Key is limited in the generic (even
3156 if not in the instances).
3157
2c17ca0a
AC
31582011-09-02 Robert Dewar <dewar@adacore.com>
3159
3160 * exp_util.adb, sem_ch10.adb, sem_attr.adb, s-htable.adb,
3161 g-comlin.adb, g-comlin.ads, lib-xref-alfa.adb, lib-xref.adb: Minor
3162 reformatting.
3163
31642011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
3165
3166 * sem_ch3.adb: (Set_Anonymous_Type): Associate the itype of an
3167 inherited component with the enclosing derived type. Code reformatting.
3168
31692011-09-02 Gary Dismukes <dismukes@adacore.com>
3170
3171 * checks.adb: (Determine_Range): Add test of OK1 to prevent the early
3172 return done when overflow checks are enabled, since comparisons against
3173 Lor and Hir should not be done when OK1 is False.
3174
31752011-09-02 Gary Dismukes <dismukes@adacore.com>
3176
3177 * exp_ch6.adb (Add_Finalization_Master_Actual_To_Build_In_Place_Call):
3178 Add new formal Master_Exp. When present, add that expression to the
3179 call as an extra actual.
3180 (Make_Build_In_Place_Call_In_Object_Declaration): Add variable
3181 Fmaster_Actual and in the case of a BIP call initializing a return
3182 object of an enclosing BIP function set it to a
3183 new reference to the implicit finalization master
3184 formal of the enclosing function. Fmaster_Actual is
3185 then passed to the new formal Master_Exp on the call to
3186 Add_Finalization_Master_Actual_To_Build_ In_Place_Call. Move
3187 initializations of Enclosing_Func to its declaration.
3188
31892011-09-02 Thomas Quinot <quinot@adacore.com>
3190
3191 * csets.ads: Minor reformatting
3192
31932011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
3194
3195 * exp_aggr.adb: (Get_Constraint_Association): Add code to retrieve
3196 the full view of a private type coming from an instantiation.
3197 * exp_ch4.adb: (Current_Anonymous_Master): Reimplement the search
3198 loop to iterate over the declarations rather than use the
3199 First_Entity / Next_Entity scheme.
3200
ed32b82e
ES
32012011-09-02 Ed Schonberg <schonberg@adacore.com>
3202
3203 * sem_attr.adb: (Analyze_Attribute, case 'Range): when expanding
3204 X'range (N) into X'First (N) .. X'Last (N), do not share the
3205 dimension indicator N, if present. Even though it is a static
3206 constant, its source location may be modified when printing
3207 expanded code under -gnatDL, and node sharing will lead to chaos
3208 in Sprint on large files, by generating a sloc value that does
3209 not correspond to any source file.
3210
f7bb41af
AC
32112011-09-02 Bob Duff <duff@adacore.com>
3212
3213 * einfo.adb: (Has_Xref_Entry): Do not call
3214 Implementation_Base_Type. Lib.Xref has been
3215 rewritten to avoid the need for it, and it was costly.
3216 * s-htable.ads,s-htable.adb: (Present,Set_If_Not_Present): New
3217 functions in support of efficient xref.
3218 * lib-xref-alfa.adb: Misc changes related to Key component of
3219 type Xref_Entry.
3220 * lib-xref.adb: (Add_Entry,etc): Speed improvement.
3221 (New_Entry): Call Implementation_Base_Type, because Has_Xref_Entry
3222 no longer does. This is the one place where it is needed.
3223
32242011-09-02 Johannes Kanig <kanig@adacore.com>
3225
3226 * g-comlin.adb (Getopt): New optional argument Concatenate to have
3227 similar interface as the other Getopt function.
3228
32292011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
3230
3231 * exp_ch4.adb: (Expand_Allocator_Expression): Do not generate
3232 a call to Set_Finalize_Address if there is no allocator available.
3233 * exp_util.adb: (Build_Allocate_Deallocate_Proc): Account for
3234 a case of allocator expansion where the allocator is not expanded but
3235 needs a custom allocate routine. Code reformatting.
3236 (Is_Finalizable_Transient): Remove local variables Has_Rens and
3237 Ren_Obj. Code reformatting.
3238 (Is_Renamed): Renamed to Is_Aliased. Add code to detect aliasing
3239 through the use of 'reference.
3240 * sem_ch4.adb: (Analyze_Allocator): Detect allocators generated
3241 as part of build-in-place expansion. They are intentionally marked as
3242 coming from source, but their parents are not.
3243
bd0bc43e
AC
32442011-09-02 Ed Schonberg <schonberg@adacore.com>
3245
3246 * sem_ch10.adb (Analyze_With_Clause): If the library unit
3247 is the generated subprogram declaration for a child unit body
3248 that acts as spec, use the original body in the with_clause,
3249 to prevent binding errors.
3250
32512011-09-02 Vincent Celier <celier@adacore.com>
3252
3253 * gnat_ugn.texi: Adapt documentation of -gnateInnn to new VMS
3254 qualifier /MULTI_UNIT_INDEX=
3255
32562011-09-02 Johannes Kanig <kanig@adacore.com>
3257
3258 * g-comlin.adb (Getopt): Return when switch is dealt with automatically,
3259 instead of calling the callback function
3260
9fdb5d21
RD
32612011-09-02 Robert Dewar <dewar@adacore.com>
3262
3263 * prj-proc.adb, prj.ads, sem_util.adb, s-taprop-linux.adb,
3264 prj-nmsc.adb, prj-util.ads, prj-env.adb: Minor reformatting.
3265
c6d5d1ac
AC
32662011-09-02 Vincent Celier <celier@adacore.com>
3267
3268 * prj-nmsc.adb: (Find_Sources): When the list of sources is
3269 explicitly declared in an extending project, do not warn if a source
3270 for an inherited naming exception is not found.
3271
32722011-09-02 Gary Dismukes <dismukes@adacore.com>
3273
3274 * exp_ch6.adb: (Is_Build_In_Place_Function_Call): Return False if
3275 expansion is inactive.
3276
32772011-09-02 Ed Schonberg <schonberg@adacore.com>
3278
3279 * sem_util.adb (Note_Possible_Modification): If the entity
3280 being modified is the renaming generated for an Ada2012 iterator
3281 element, the enclosing container or array is modified as well.
3282
2ba1a7c7
AC
32832011-09-02 Jose Ruiz <ruiz@adacore.com>
3284
3285 * s-taprop-linux.adb (Initialize_Lock, Initialize_TCB,
3286 Initialize): Define and initialize the
3287 mutex attributes and condition variable attributes locally.
3288
32892011-09-02 Vincent Celier <celier@adacore.com>
3290
3291 * prj-nmsc.adb (Check_File): Mark as Locally_Removed a naming
3292 exception replaced in an extending project.
3293 (Check_Object): No error when the other source is locally removed.
3294
32952011-09-02 Yannick Moy <moy@adacore.com>
3296
3297 * exp_ch6.adb (Is_Build_In_Place_Function_Call): in Alfa mode, allow
3298 unresolved calls.
3299
d51813db
AC
33002011-08-31 Arnaud Charlet <charlet@adacore.com>
3301
3302 * gcc-interface/Makefile.in: Clean up handling of x86 and x86-64
3303 run-time files.
3304 * gcc-interface/Make-lang.in: Update dependencies.
3305
9f55bc62
AC
33062011-09-01 Robert Dewar <dewar@adacore.com>
3307
3308 * sem_ch3.adb, s-taprop-linux.adb, gnatls.adb: Minor reformatting.
3309
33102011-09-01 Jose Ruiz <ruiz@adacore.com>
3311
3312 * adaint.h (__gnat_cpu_free): Fix the name of this profile.
3313 * adaint.c (__gnat_cpu_alloc, __gnat_cpu_alloc_size, __gnat_cpu_free,
3314 __gnat_cpu_zero, __gnat_cpu_set): Create version of these subprograms
3315 specific for systems where their glibc version does not define the
3316 routines to handle dynamically allocated CPU sets.
3317
33182011-09-01 Vincent Celier <celier@adacore.com>
3319
3320 * prj-proc.adb, prj.ads, prj-nmsc.adb, prj-util.adb, prj-util.ads,
3321 prj-env.adb: Implement inheritance of naming exceptions in extending
3322 projects.
3323
d7386a7a
AC
33242011-09-01 Romain Berrendonner <berrendo@adacore.com>
3325
3326 * gnatls.adb: Display simple message instead of content of
3327 gnatlic.adl.
3328
33292011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
3330
3331 * sem_ch3.adb: (Build_Derived_Record_Type) Remove the kludgy update of
3332 access discriminant and anonymous access component scopes.
3333 (Inherit_Component): Reuse the itype of an access discriminant
3334 or anonymous access component by copying it in order to set the proper
3335 scope. This is done only when the parent and the derived type
3336 are in different scopes.
3337 (Set_Anonymous_Etype): New routine.
3338
33392011-09-01 Robert Dewar <dewar@adacore.com>
3340
3341 * a-convec.adb: Minor reformatting throughout.
3342
9d1e0e72
JR
33432011-09-01 Jose Ruiz <ruiz@adacore.com>
3344
3345 * adaint.c, adaint.h (__gnat_cpu_alloc, __gnat_cpu_alloc_size,
3346 __gnat_cpu_set_free): Create these wrappers around the CPU_ALLOC,
3347 CPU_ALLOC_SIZE and CPU_FREE linux macros.
3348 (__gnat_cpu_zero, __gnat_cpu_set): Use the CPU_ZERO_S and
3349 CPU_SET_S respectively because we are now using dynamically allocated
3350 CPU sets which are more portable across different glibc versions.
3351 * s-osinte-linux.ads (cpu_set_t_ptr, CPU_ALLOC, CPU_ALLOC_SIZE,
3352 CPU_FREE): Add this type and subprograms to be able to create cpu_set_t
3353 masks dynamically according to the number of processors in the target
3354 platform.
3355 (CPU_ZERO, CPU_SET): They are now mapped to the CPU_ZERO_S and CPU_SET_S
3356 respectively, so we need to pass the size of the masks as
3357 parameters.
3358 * s-taprop-linux.adb (Create_Task, Set_Task_Affinity): Use dynamically
3359 created cpu_set_t masks
3360 with the number of processors available in the target platform,
3361 instead of static bit arrays. It enhances portability because
3362 it uses the information from the target platform.
3363 * sem_ch8.adb: (Attribute_Renaming): When checking whether we
3364 are using a restricted run-time library, use the flag
3365 Configurable_Run_Time_Mode instead of Restricted_Profile.
3366
a95be2d4
AC
33672011-09-01 Vincent Celier <celier@adacore.com>
3368
3369 * ug_words: Add /MULTI_UNIT_INDEX= -> -gnateI
3370 * vms_data.ads: Add new VMS qualifier equivalent for -gnateInnn
3371
33722011-09-01 Nicolas Roche <roche@adacore.com>
3373
3374 * adaint.c (__gnat_tmp_name): Don't use tmpnam function from the system
3375 on VxWorks in kernel mode.
3376
6b81741c
AC
33772011-09-01 Jose Ruiz <ruiz@adacore.com>
3378
3379 * s-taprop-linux.adb (Create_Task, Set_Task_Affinity): Use the linux
3380 macros for handling CPU sets (CPU_ZERO, CPU_SET) instead of modifying
3381 directly the bit array.
3382 * s-osinte-linux.ads (CPU_ZERO, CPU_SET): Import these wrappers around
3383 the linux macros with the same name.
3384 * adaint.h, adaint.c (__gnat_cpu_zero, __gnat_cpu_set): Create these
3385 wrappers around the CPU_ZERO and CPU_SET linux macros.
3386
33872011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
3388
3389 * exp_ch7.adb (Find_Insertion_List): Removed.
3390 (Process_Transient_Objects): Insert the declarations of the hook
3391 access type and the hook object before the associated transient object.
3392
33932011-09-01 Jose Ruiz <ruiz@adacore.com>
3394
3395 * sem_ch8.adb (Attribute_Renaming): Add missing check to avoid loading
3396 package System.Aux_Dec when using restricted run-time libraries which
3397 do not have this package.
3398
33992011-09-01 Tristan Gingold <gingold@adacore.com>
3400
3401 * s-vaflop-vms-alpha.adb: Remove pragma optimize, useless.
3402
34032011-09-01 Bob Duff <duff@adacore.com>
3404
3405 * sem_attr.adb (Analyze_Access_Attribute): Do not call
3406 Kill_Current_Values for P'Unrestricted_Access, where P is library level
3407
34082011-09-01 Thomas Quinot <quinot@adacore.com>
3409
3410 * exp_ch5.adb: Minor reformatting
3411 * gnat_ugn.texi: Fix minor typos.
3412 * gcc-interface/Make-lang.in: Update dependencies.
3413
8256c1bf
AC
34142011-09-01 Robert Dewar <dewar@adacore.com>
3415
3416 * inline.adb, sem_aggr.adb: Minor reformatting.
3417
34182011-09-01 Ed Schonberg <schonberg@adacore.com>
3419
3420 * a-convec.adb: Proper handling of cursors for Ada2012 iterators.
3421
d1c5f424
AC
34222011-09-01 Robert Dewar <dewar@adacore.com>
3423
3424 * prj-proc.adb, exp_ch6.adb, prj-env.adb: Minor reformatting.
3425
34262011-09-01 Bob Duff <duff@adacore.com>
3427
3428 * sem_aggr.adb (Resolve_Aggregate): Need to treat "in instance
3429 body" the same as "in inlined body", because visibility shouldn't
3430 apply there.
3431
34322011-09-01 Eric Botcazou <ebotcazou@adacore.com>
3433
3434 * inline.adb (Add_Inlined_Body): Refine previous change.
3435
1bb6e262
AC
34362011-09-01 Gary Dismukes <dismukes@adacore.com>
3437
3438 * exp_ch6.ads (Needs_BIP_Alloc_Form): New utility function.
3439 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
3440 Test for case where call
3441 initializes an object of a return statement before testing for
3442 a constrained call, to ensure that all such cases get handled
3443 by simply passing on the caller's parameters. Also, in that
3444 case call Needs_BIP_Alloc_Form to determine whether to pass on
3445 the BIP_Alloc_Form parameter of the enclosing function rather
3446 than testing Is_Constrained. Add similar tests for the return
3447 of a BIP call to later processing to ensure consistent handling.
3448 (Needs_BIP_Alloc_Form): New utility function.
3449 * sem_ch6.adb: (Create_Extra_Formals): Replace test for adding
3450 a BIP_Alloc_Form formal with call to new utility function
3451 Needs_BIP_Alloc_Form.
3452
34532011-09-01 Pascal Obry <obry@adacore.com>
3454
3455 * prj-part.adb: Minor reformatting.
3456
34572011-09-01 Vincent Celier <celier@adacore.com>
3458
3459 * prj-env.adb (Create_Mapping_File.Process): Encode the upper
3460 half character in the unit name.
3461
db15225a
AC
34622011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
3463
3464 * exp_ch4.adb: Minor code and comment reformatting.
3465
34662011-09-01 Thomas Quinot <quinot@adacore.com>
3467
3468 * exp_ch6.adb (Expand_Inlined_Call): Remove redundant tests
3469 for Is_Limited_Type and Is_Tagged_Type in condition checking
3470 for by-reference type.
3471 * inline.adb (Add_Inlined_Body): Only exclude init_procs. Other
3472 subprograms may have a completion because of a previous
3473 Inline_Always clause, but the enclosing package must be marked
3474 inlined for the subprogram body to become visible to the backend.
3475
9d641fc0
TQ
34762011-09-01 Thomas Quinot <quinot@adacore.com>
3477
3478 * sem_aux.adb, exp_ch4.adb: Minor reformatting
3479
dbe36d67
AC
34802011-09-01 Pascal Obry <obry@adacore.com>
3481
3482 * prj-proc.adb, prj.ads, sinput-p.adb: Minor reformatting.
3483
34842011-09-01 Ed Schonberg <schonberg@adacore.com>
3485
3486 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Generate references to
3487 the formals of a subprogram stub that acts as a spec.
3488
34892011-09-01 Ed Schonberg <schonberg@adacore.com>
3490
3491 * exp_ch6.adb (Expand_Inlined_Call): If an actual is a by_reference
3492 type, declare a renaming for it, not an object declaration.
3493
f5037886
AC
34942011-09-01 Yannick Moy <moy@adacore.com>
3495
3496 * ali-util.adb, ali-util.ads (Read_Withed_ALIs): Add parameter
3497 Ignore_Errors to ignore failures to read ALI files when True.
3498
34992011-09-01 Javier Miranda <miranda@adacore.com>
3500
3501 * exp_ch3.adb (Expand_N_Object_Declaration): Handle non-default
3502 constructor calls associated with non-tagged record types.
3503
35042011-09-01 Robert Dewar <dewar@adacore.com>
3505
3506 * g-socthi-vms.adb: Minor reformatting.
3507
35082011-09-01 Nicolas Roche <roche@adacore.com>
3509
3510 * sysdep.c: Don't use macro functions for stdio functions on VxWorks
3511 in order to avoid impact of imcompatible changes.
3512 * cstreams.c: Likewise
3513 * cio.c: Likewise
3514 * aux-io.c: Likewise
3515
35162011-09-01 Yannick Moy <moy@adacore.com>
3517
3518 * lib-writ.adb (Write_With_Lines): Always output complete information
3519 on "with" line in Alfa mode, as this is required by formal verification
3520 back-end.
3521
549e4558
AC
35222011-09-01 Tristan Gingold <gingold@adacore.com>
3523
3524 * g-socthi-vms.adb: Add comments.
3525
35262011-09-01 Pascal Obry <obry@adacore.com>
3527
3528 * prj.ads: Minor reformatting.
3529
70c0422d
AC
35302011-09-01 Vincent Celier <celier@adacore.com>
3531
3532 * prj-env.adb (Create_Config_Pragmas_File.Check): Put all naming
3533 exceptions in the config pragmas file.
3534
35352011-09-01 Tristan Gingold <gingold@adacore.com>
3536
3537 * gnat_ugn.texi: Document GNAT_STACK_SIZE on IVMS.
3538
8c5b03a0
AC
35392011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
3540
3541 * exp_ch7.adb (Find_Insertion_List): New routine.
3542 (Process_Transient_Objects): Add code to handle the abnormal
3543 finalization of a controlled transient associated with a subprogram
3544 call. Since transients are cleaned up right after the associated
3545 context, an exception raised during a subprogram call may bypass the
3546 finalization code.
3547
35482011-09-01 Robert Dewar <dewar@adacore.com>
3549
3550 * exp_ch6.adb (Expand_Call): Check actual for aliased parameter is
3551 aliased.
3552
3040dbd4
RD
35532011-09-01 Robert Dewar <dewar@adacore.com>
3554
3555 * exp_ch4.adb, a-exexda.adb: Minor reformatting.
3556
fecbd779
AC
35572011-09-01 Robert Dewar <dewar@adacore.com>
3558
3559 * s-taskin.ads, s-tassta.adb, sem_ch13.adb: Minor reformatting.
3560
35612011-09-01 Thomas Quinot <quinot@adacore.com>
3562
3563 * Makefile.rtl: Move s-oscons.o from GNATRTL_TASKING_OBJS to
3564 GNATRTL_NONTASKING_OBJS.
3565
35662011-09-01 Robert Dewar <dewar@adacore.com>
3567
3568 * einfo.ads (Is_Aliased): Fix existing documentation and add note on
3569 possibility of this flag being set for formals in Ada 2012 mode.
3570 * par-ch6.adb (P_Formal_Part): Handle aliased for parameters for Ada
3571 2012.
3572 * sem_ch6.adb (Process_Formals): Handle aliased parameters in Ada 2012
3573 mode.
3574 * sinfo.adb (Aliased_Present): Allowed in N_Parameter_Specification for
3575 Ada 2012.
3576 * sinfo.ads (Aliased_Present): Allowed in N_Parameter_Specification for
3577 Ada 2012.
3578
35792011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
3580
3581 * exp_ch4.adb (Find_Insertion_Node): New routine. Determines the proper
3582 insertion node in a tree of nested Expression_With_Actions nodes.
3583 (Process_Transient_Object): In the case where a complex if statement
3584 has been converted into nested Expression_With_Actions nodes, the
3585 "hook" object and the associated access type must be inserted before
3586 the top most Expression_With_Actions.
3587
516f608f
AC
35882011-09-01 Robert Dewar <dewar@adacore.com>
3589
3590 * a-cbprqu.adb, a-cbprqu.ads, a-cuprqu.adb, a-cuprqu.ads,
3591 a-cbsyqu.adb, a-cbsyqu.ads: Minor reformatting.
3592
35932011-09-01 Ed Schonberg <schonberg@adacore.com>
3594
3595 * sem_attr.adb: Conditionalize aliasing predicates to Ada2012.
3596
35972011-09-01 Jose Ruiz <ruiz@adacore.com>
3598
3599 * aspects.ads (Aspect_Id, Aspect_Argument, Aspect_Names): Add the CPU
3600 aspect.
3601 * aspects.adb (Canonical_Aspect): Add entry for the CPU aspect.
3602 * sem_ch13.adb (Analyze_Aspect_Specifications): Analyze the CPU aspect
3603 in a similar way as we do for the Priority or Dispatching_Domain aspect.
3604 * s-mudido-affinity.adb (Dispatching_Domain_Tasks,
3605 Dispatching_Domains_Frozen): Move this local data to package
3606 System.Tasking because with the CPU aspect we need to have access
3607 to this data when creating the task in System.Tasking.Stages.Create_Task
3608 * s-taskin.ads (Dispatching_Domain_Tasks, Dispatching_Domains_Frozen):
3609 Move these variables from the body of
3610 System.Multiprocessors.Dispatching_Domains because with the CPU aspect
3611 we need to have access to this data when creating the task in
3612 System.Tasking.Stages.Create_Task.
3613 * s-taskin.adb (Initialize): Signal the allocation of the environment
3614 task to a CPU, if any, so that we know whether the CPU can be
3615 transferred to a different dispatching domain.
3616 * s-tassta.adb (Create_Task): Check whether the CPU to which this task
3617 is being allocated belongs to the dispatching domain where the task
3618 lives. Signal the allocation of the task to a CPU, if any, so that we
3619 know whether the CPU can be transferred to a different dispatching
3620 domain.
3621
2d42e881
ES
36222011-09-01 Ed Schonberg <schonberg@adacore.com>
3623
3624 * exp_attr.adb, sem_attr.adb, snames.ads-tmpl: Implementation of
3625 attributes Same_Storage and Overlaps_Storage.
3626
579fda56
AC
36272011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
3628
3629 * exp_strm.adb: Remove with and use clause for Opt.
3630 (Build_Array_Input_Function): Remove the version-dependent generation
3631 of the return statement. The Ada 2005 tree is now the default.
3632
36332011-09-01 Yannick Moy <moy@adacore.com>
3634
3635 * put_alfa.adb: Unconditionnally write files in Alfa section, so that
3636 it is never empty when compiling in Alfa mode.
3637
36382011-09-01 Robert Dewar <dewar@adacore.com>
3639
3640 * sem_aggr.adb, sem_ch3.adb, a-direct.adb, s-taprop-vxworks.adb,
3641 comperr.adb, exp_ch9.adb, exp_pakd.adb, sem_ch12.adb, freeze.adb,
3642 s-taprop-mingw.adb, s-taprop-linux.adb, s-taprop-solaris.adb,
3643 gnat1drv.adb, a-rbtgbo.adb, exp_dist.adb: Minor reformatting
3644
36452011-09-01 Matthew Heaney <heaney@adacore.com>
3646
3647 * Makefile.rtl, impunit.adb: Add a-csquin.ads, a-cusyqu.ad[sb],
3648 a-cuprqu.ad[sb], a-cbsyqu.ad[sb], a-cbprqu.ad[sb]
3649 * a-csquin.ads: New Ada 2012 unit that specifies the queue interface
3650 * a-cusyqu.ads, a-cusyqu.adb: New Ada 2012 unit that specifies the
3651 unbounded queue container.
3652 * a-cbsyqu.ads, a-cbsyqu.adb: New Ada 2012 unit that specifies the
3653 bounded queue container.
3654 * a-cuprqu.ads, a-cuprqu.adb: New Ada 2012 unit that specifies the
3655 unbounded priority queue container.
3656 * a-cbprqu.ads, a-cbprqu.adb: New Ada 2012 unit that specifies the
3657 bounded priority queue container.
3658
24c34107
AC
36592011-08-31 Pascal Obry <obry@adacore.com>
3660
3661 * a-direct.adb: Do not try to create an UNC path on Windows.
3662 (Create_Path): Skip leading computer name in UNC path if any.
3663
36642011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3665
3666 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function): Remove the
3667 version-dependent generation of the return statement. The Ada 2005 tree
3668 is now the default.
3669
36702011-08-31 Thomas Quinot <quinot@adacore.com>
3671
3672 * rtsfind.ads, exp_dist.adb (Find_Numeric_Representation): Predefined
3673 types Stream_Element_Offset and Storage_Offset have a different native
3674 type depending on whether the platform is 32 or 64 bits. When
3675 exchanging them, always convert to 64 bits.
3676
36772011-08-31 Yannick Moy <moy@adacore.com>
3678
3679 * debug.adb: Reserve debug option -gnatd.E for passing gnatprove option
3680 --force-alfa to gnat2why.
3681
36822011-08-31 Ed Schonberg <schonberg@adacore.com>
3683
3684 * sem_ch12.adb (Save_References): If the node has aspects, save
3685 references within the corresponding expressions in a separate step,
3686 because the aspects are not directly in the tree for the declaration
3687 to which they belong.
3688
36892011-08-31 Arnaud Charlet <charlet@adacore.com>
3690
3691 * freeze.adb (Freeze_Record_Type): Omit test on variable size component
3692 in CodePeer mode, since representation clauses are partially ignored.
3693 * gcc-interface/Make-lang.in: Update dependencies.
3694
702d2020
AC
36952011-08-31 Jose Ruiz <ruiz@adacore.com>
3696
3697 * s-taprop-vxworks.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
3698 s-taprop-solaris.adb (Create_Task): Not_A_Specific_CPU can be assigned
3699 to any dispatching domain.
3700
37012011-08-31 Thomas Quinot <quinot@adacore.com>
3702
3703 * exp_ch4.adb: Minor reformatting.
3704
37052011-08-31 Bob Duff <duff@adacore.com>
3706
3707 * sem_ch6.adb (Get_Generic_Parent_Type): Don't query Subtype_Indication
3708 on nodes for which it is not defined.
3709 (Is_Non_Overriding_Operation): Exit the loop when we find a generic
3710 parent type.
3711
37122011-08-31 Bob Duff <duff@adacore.com>
3713
3714 * sem_ch3.adb (Process_Full_View): Disable legality check if
3715 In_Instance, to avoid spurious errors.
3716 * sem_ch12.adb (Validate_Derived_Type_Instance): Disable legality check
3717 if In_Instance, to avoid spurious errors.
3718
37192011-08-31 Pascal Obry <obry@adacore.com>
3720
3721 * a-direct.adb: Use Dir_Seps everywhere to properly handle all
3722 directory speparators.
3723 (Compose): Use Dir_Seps to handle both forms.
3724 (Create_Path): Use Dir_Seps instead of explicit check, no semantic
3725 changes.
3726 (Extension): Use Dir_Seps to handle both forms.
3727
37282011-08-31 Pascal Obry <obry@adacore.com>
3729
3730 * prj-conf.adb: Minor reformatting.
3731
67645bde
AC
37322011-08-31 Jose Ruiz <ruiz@adacore.com>
3733
3734 * aspects.ads (Aspect_Id, Aspect_Argument, Aspect_Names): Add the
3735 dispatching domain aspect.
3736 * aspects.adb (Canonical_Aspect): Add entry for the dispatching domain
3737 aspect.
3738 * sem_ch13.adb (Analyze_Aspect_Specifications): Analyze the
3739 Dispatching_Domain aspect in a similar way as we do for the Priority
3740 aspect.
3741 * exp_ch9.adb (Expand_N_Task_Type_Declaration): Add the
3742 Dispatching_Domain component if a Dispatching_Domain pragma or aspect
3743 is present.
3744 (Make_Task_Create_Call): Add the Dispatching_Domain when creating a task
3745 * par-prag.adb (Prag): Add Pragma_Dispatching_Domain as a known pragma.
3746 * sem_prag.adb (Analyze_Pragma): Check the correctness of a pragma
3747 Dispatching_Domain and add it to the task definition.
3748 (Sig_Flags): Add Pragma_Dispatching_Domain.
3749 * rtsfind.ads, rtsfind.adb (RTU_Id, RE_Id, Get_Unit_Name): Add the
3750 support to find the types Dispatching_Domain and
3751 Dispatching_Domain_Access.
3752 * sinfo.ads, sinfo.adb (Has_Pragma_Dispatching_Domain,
3753 Set_Has_Pragma_Dispatching_Domain): Add these subprograms to set and
3754 query the availability of a pragma Dispatching_Domain.
3755 * snames.ads-tmpl (Name_uDispatching_Domain): Add this name required by
3756 the expander to pass the Dispatching_Domain when creating a task.
3757 (Name_Dispatching_Domain): Add this new name for a pragma.
3758 (Pragma_Id): Add the new Pragma_Dispatching_Domain.
3759 * s-tassta.ads, s-tassta.adb (Create_Task): Set the domain to which the
3760 task has been allocated at creation time.
3761 * s-tarest.adb (Create_Restricted_Task): The dispatching domain using
3762 Ravenscar is always null.
3763 * s-taskin.ads, s-taskin.adb (Initialize_ATCB): Set the domain to which
3764 the task has been allocated at creation time.
3765 * s-tporft.adb (Register_Foreign_Thread): A foreign task will not have
3766 a specific dispatching domain.
3767 * s-taprop-linux.adb, s-taprop-solaris.adb, s-taprop-vxworks.adb,
3768 s-taprop-mingw.adb (Create_Task): Check whether both Dispatching_Domain
3769 and CPU are specified for the task, and the CPU value is not contained
3770 within the range of processors for the domain.
3771
37722011-08-31 Vincent Celier <celier@adacore.com>
3773
3774 * make.adb (Original_Gcc) : New constant String_Access.
3775 (Gnatmake): For VM targets, do not use VM version of the compiler if
3776 --GCC= has been specified.
3777
37782011-08-31 Thomas Quinot <quinot@adacore.com>
3779
3780 * sem_ch5.adb: Minor reformatting.
3781
37822011-08-31 Ed Schonberg <schonberg@adacore.com>
3783
3784 * exp_pakd.adb (Convert_To_PAT_Type): If prefix is a function call, do
3785 not reanalyze it.
3786
37872011-08-31 Bob Duff <duff@adacore.com>
3788
3789 * exp_ch4.adb (Expand_N_Selected_Component): Use the full type, in case
3790 the access type is private; we don't care about privacy in expansion.
3791
37922011-08-31 Ed Schonberg <schonberg@adacore.com>
3793
3794 * sem_aggr.adb (Resolve_Aggregate): In an instance, ignore aggregate
3795 subcomponents tnat may be limited, because they originate in view
3796 conflicts. If the original aggregate is legal and the actuals are
3797 legal, the aggregate itself is legal.
3798
b8789727
AC
37992011-08-31 Matthew Heaney <heaney@adacore.com>
3800
3801 * a-rbtgbo.adb (Clear_Tree): Assert representation invariant for lock
3802 status.
3803
38042011-08-31 Ed Schonberg <schonberg@adacore.com>
3805
3806 * sem_ch5.adb: Set kind of loop parameter properly, to preserve all
3807 errors in B tests.
3808
38092011-08-31 Jose Ruiz <ruiz@adacore.com>
3810
3811 * sem_ch13.adb (Analyze_Aspect_Specifications): For the Priority and
3812 Interrupt_Priority aspects, force the analysis of the aspect expression
3813 (when building the equivalent pragma). Otherwise, its analysis is done
3814 too late, after the task or protected object has been created.
3815 * sem_ch9.adb (Analyze_Single_Protected_Declaration,
3816 Analyze_Single_Task_Declaration): Remove the code to move the aspects
3817 to the object declaration because they are needed in the type
3818 declaration.
3819
e0c32166
AC
38202011-08-31 Robert Dewar <dewar@adacore.com>
3821
3822 * exp_ch5.adb, exp_ch7.ads, sem_ch5.adb, put_scos.adb, s-rannum.adb,
3823 a-rbtgbo.adb, exp_intr.adb, a-cbdlli.adb, a-cbdlli.ads: Minor
3824 reformatting.
3825
38262011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3827
3828 * exp_util.adb (Find_Protection_Type): Do not look for fields _object
3829 if the corresponding type is malformed due to restriction violations.
3830
38312011-08-31 Robert Dewar <dewar@adacore.com>
3832
3833 * s-ransee.ads, s-ransee.adb: Minor reformatting.
3834
38352011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3836
3837 * exp_ch4.adb (Expand_N_Allocator): Correct faulty condition which
3838 would cause the generation of Set_Finalize_Address if the target is a
3839 VM and the designated type is not derived from [Limited_]Controlled.
3840
38412011-08-31 Arnaud Charlet <charlet@adacore.com>
3842
3843 * comperr.adb, comperr.ads, gnat1drv.adb (Delete_SCIL_Files): New
3844 subprogram.
3845 (Compiler_Abort, Gnat1drv): Call Delete_SCIL_Files in codepeer mode in
3846 case of a compilation error.
3847
38482011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3849
3850 * init.c (__gnat_error_handler): Standardize the stack overflow or
3851 erroneous memory access message.
3852 * seh_init.c (__gnat_SEH_error_handler): Standardize the stack overflow
3853 or erroneous memory access message.
3854
11bc76df
AC
38552011-08-31 Robert Dewar <dewar@adacore.com>
3856
3857 * sem_ch4.adb: Minor reformatting.
3858 * sem_ch6.adb: Minor code reorganization (use Ekind_In).
3859
38602011-08-31 Thomas Quinot <quinot@adacore.com>
3861
3862 * scos.ads: Minor documentation clarification.
3863 * put_scos.adb: Do not generate SCO unit header line for a unit that
3864 has no SCO lines.
3865
876d4394
RD
38662011-08-31 Robert Dewar <dewar@adacore.com>
3867
3868 * a-rbtgbo.adb, alfa_test.adb: Minor reformatting.
3869
36b8f95f
AC
38702011-08-31 Tristan Gingold <gingold@adacore.com>
3871
3872 * exp_ch7.ads, exp_ch7.adb (Finalization_Exception_Data): New type to
3873 hold variables between these following subprograms.
3874 (Build_Exception_Handler, Build_Object_Declarations,
3875 Build_Raise_Statement): Use the above type as parameter.
3876 Make the above adjustments.
3877 * exp_intr.adb (Expand_Unc_Deallocation): Adjust.
3878
38792011-08-31 Pascal Obry <obry@adacore.com>
3880
3881 * projects.texi: Minor reformatting.
3882
38832011-08-31 Tristan Gingold <gingold@adacore.com>
3884
3885 * s-ransee.ads, s-ransee.adb: Add system.random_seed unit.
3886 * s-rannum.adb (Reset): Use Get_Seed from s-ransee.
3887
38882011-08-31 Ed Schonberg <schonberg@adacore.com>
3889
3890 * exp_ch5.adb: Minor code cleanup.
3891 * sem_ch5.adb (Analyze_Iteration_Scheme): Set ekind of loop variable to
3892 prevent cascaded errors.
3893 (Analyze_Loop_Statement): In semantics-only mode, introduce loop
3894 variable of an iterator specification in current scope.
3895 * sem_ch6.adb (Analyze_Return_Statement, Find_what_It_Apples_To): Skip
3896 postconditions on the stack, as they contain no return statements.
3897
38982011-08-31 Yannick Moy <moy@adacore.com>
3899
3900 * exp_alfa.adb (Expand_Alfa_N_Package_Declaration,
3901 Expand_Alfa_N_Subprogram_Body): Remove useless procedures which simply
3902 call Qualify_Entity_Names.
3903 (Expand_Alfa): call Qualify_Entity_Names in more cases
3904 * lib-xref-alfa.adb: Take into account system package.
3905 * sem_prag.adb Take into account restrictions in Alfa mode, contrary to
3906 CodePeer mode in which we are interested in finding bugs even if
3907 compiler cannot compile source.
3908 * sem_util.adb, sem_util.ads (Unique_Entity): Take into account case of
3909 deferred constant.
3910
39112011-08-31 Gary Dismukes <dismukes@adacore.com>
3912
3913 * sem_ch3.adb (Constrain_Concurrent): Retrieve Base_Type of the subtype
3914 denoted by the subtype mark to ensure getting the concurrent type in
3915 the case where the subtype mark denotes a private subtype of a
3916 concurrent type (needed when using -gnatc).
3917 (Process_Subtype): For the processing specific to type kinds, case on
3918 the Base_Type kind of the Subtype_Mark_Id, to handle cases where the
3919 subtype denotes a private subtype whose base type is nonprivate (needed
3920 for subtypes of private fulfilled by task types when compiling with
3921 -gnatc).
3922
39232011-08-31 Gary Dismukes <dismukes@adacore.com>
3924
3925 * sem_disp.adb (Check_Dispatching_Operation): Bypass registration of
3926 late primitives that override interface operations when the full
3927 expander is not active, to avoid blowups in Register_Primitive when
3928 types don't have associated secondary dispatch tables.
3929
39302011-08-31 Yannick Moy <moy@adacore.com>
3931
3932 * alfa_test.adb: Code clean up.
3933
39342011-08-31 Marc Sango <sango@adacore.com>
3935
3936 * restrict.adb (Check_SPARK_Restriction): Change Comes_From_Source (N)
3937 by Comes_From_Source (Original_Node (N)) in order to treat also the
3938 nodes which have been rewritten.
3939 * sem_ch4.adb (Analyze_Explicit_Dereference, Analyze_Slice): Guard the
3940 explicit dereference and slice violation in spark mode on the nodes
3941 coming only from the source code.
3942
8cf23b91
AC
39432011-08-31 Robert Dewar <dewar@adacore.com>
3944
3945 * exp_ch5.adb, exp_alfa.ads, prj.ads, sem_attr.adb,
3946 lib-xref-alfa.adb: Minor reformatting.
3947
39482011-08-31 Matthew Heaney <heaney@adacore.com>
3949
3950 * a-crbltr.ads (Tree_Type): Default-initialize the Nodes component.
3951
39522011-08-31 Javier Miranda <miranda@adacore.com>
3953
3954 * sem_ch4.adb (Try_Object_Operation): Addition of one formal to search
3955 only for class-wide subprograms conflicting with entities of concurrent
3956 tagged types.
3957
39582011-08-31 Matthew Heaney <heaney@adacore.com>
3959
3960 * a-rbtgbo.adb (Generic_Allocate): Initialize pointer components of
3961 node to null value.
3962
39632011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3964
3965 * sem_ch12.adb (Insert_Freeze_Node_For_Instance): Provide a more
3966 general description of the routine.
3967
39682011-08-31 Ed Schonberg <schonberg@adacore.com>
3969
3970 * a-cbdlli.adb, a-cbdlli.ads: Add iterator machinery to bounded
3971 doubly-linked lists.
3972
0bb3bfb8
GD
39732011-08-31 Gary Dismukes <dismukes@adacore.com>
3974
3975 * exp_ch5.adb (Expand_N_Assignment_Statement): When a discriminant
3976 check is needed for a left-hand side that is a dereference, and the
3977 base type is private without discriminants (whereas the full type does
3978 have discriminants), an extra retrieval of the underlying type may be
3979 needed in the case where the subtype is a record subtype whose base
3980 type is private. Update comments.
3981
11fa950b
AC
39822011-08-31 Javier Miranda <miranda@adacore.com>
3983
3984 * sem_ch4.adb (Try_Object_Operation): When a dispatching primitive is
3985 found check if there is a class-wide subprogram covering the primitive.
3986
39872011-08-31 Yannick Moy <moy@adacore.com>
3988
3989 * sem_res.adb: Further cases where full expansion test is needed,
3990 rather than expansion test.
3991
39922011-08-31 Pascal Obry <obry@adacore.com>
3993
3994 * prj-attr.adb: Fix Source_File_Switches attribute kind (must be a list)
3995
39962011-08-31 Ed Schonberg <schonberg@adacore.com>
3997
3998 * exp_ch5.adb: Handle iterators over derived container types.
3999
40002011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
4001
4002 * einfo.ads, einfo.adb: Add new flag Has_Anonymous_Master.
4003 (Has_Anonymous_Master): New routine.
4004 (Set_Has_Anonymous_Master): New routine.
4005 (Write_Entity_Flags): Add an entry for Has_Anonymous_Master.
4006 * exp_ch4.adb: Add with and use clause for Sem_Ch8.
4007 (Current_Anonymous_Master): New routine.
4008 (Current_Unit_First_Declaration): Removed.
4009 (Current_Unit_Scope): Removed.
4010 (Expand_N_Allocator): Anonymous access-to-controlled types now chain
4011 their objects on a per-unit heterogeneous finalization master.
4012
40132011-08-31 Matthew Heaney <heaney@adacore.com>
4014
4015 * a-cbhama.adb, a-cbhase.adb (Insert): Check for zero-length buckets
4016 array.
4017
40182011-08-31 Jose Ruiz <ruiz@adacore.com>
4019
4020 * s-taprop-linux.adb (Create_Task): Avoid changing the affinity mask
4021 when not needed.
4022
40232011-08-31 Gary Dismukes <dismukes@adacore.com>
4024
4025 * sem_disp.adb (Propagate_Tag): Return without propagating in the case
4026 where the actual is an unexpanded call to 'Input.
4027
d2b4b3da
AC
40282011-08-31 Yannick Moy <moy@adacore.com>
4029
4030 * sem_ch4.adb: Code clean up.
4031
40322011-08-31 Yannick Moy <moy@adacore.com>
4033
4034 * exp_alfa.adb, exp_alfa.ads: Minor correction of copyright notice.
4035
40362011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
4037
4038 * exp_ch7.adb (Build_Array_Deep_Procs): Do not generate Deep_Finalize
4039 and TSS primitive Finalize_Address if finalization is suppressed.
4040 (Build_Record_Deep_Procs): Do not generate Deep_Finalize and TSS
4041 primitive Finalize_Address if finalization is suppressed.
4042
40432011-08-31 Jose Ruiz <ruiz@adacore.com>
4044
4045 * s-mudido-affinity.adb, s-taprop-linux.adb, s-taprop-mingw.adb,
4046 s-taprop-solaris.adb, s-taprop-vxworks.adb (Set_Task_Affinity): Make
4047 sure that the underlying task has already been created before trying
4048 to change its affinity.
4049 (Set_CPU): Use the term processor instead of CPU, as we do in
4050 Assign_Task.
4051
40522011-08-31 Vincent Celier <celier@adacore.com>
4053
4054 * prj-attr.adb: New Compiler attribute Source_File_Switches.
4055 * prj-nmsc.adb (Process_Compiler): Process attribute
4056 Source_File_Switches.
4057 * prj.ads (Language_Config): New name list component
4058 Name_Source_File_Switches.
4059 * snames.ads-tmpl (Name_Source_File_Switches): New standard name.
4060
40612011-08-31 Ed Schonberg <schonberg@adacore.com>
4062
4063 * sem_attr.adb (Analyze_Attribute, case 'Old): If prefix may be a
4064 discriminated component of an actual, expand at once to prevent
4065 ouf-of-order references with generated subtypes.
4066
40672011-08-31 Yannick Moy <moy@adacore.com>
4068
4069 * lib-xref-alfa.adb (Add_Alfa_Xrefs): Do not take into account read
4070 reference to operator in Alfa xrefs.
4071
40722011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
4073
4074 * sem_ch12.adb (Freeze_Subprogram_Body): Add code to handle the case
4075 where the parent instance was frozen before the current instance due to
4076 the presence of a source body. Update calls to Insert_After_Last_Decl.
4077 (Insert_After_Last_Decl): Renamed to Insert_Freeze_Node_For_Instance.
4078 Update the comment which illustrates the purpose of the routine.
4079 Package instances are now frozen by source bodies which appear after
4080 the instance. This ensures that entities coming from within the
4081 instance are available for use in the said bodies.
4082 (Install_Body): Add code to handle the case where the parent instance
4083 was frozen before the current instance due to the presence of a source
4084 body. Update calls to Insert_After_Last_Decl.
4085
56812278
AC
40862011-08-31 Jose Ruiz <ruiz@adacore.com>
4087
4088 * s-taprop-linux.adb (Set_Task_Affinity): Avoid the use of anonymous
4089 access types.
4090 * affinity.c (__gnat_set_affinity_mask): Declare index variable.
4091
40922011-08-31 Yannick Moy <moy@adacore.com>
4093
4094 * sem_ch8.adb (Analyze_Subprogram_Renaming): Refine expander test in
4095 full-expander test.
16c3301a
AC
4096 * alfa.adb, alfa.ads, alfa_test.adb, ali.adb, debug.adb, errout.adb,
4097 errout.ads, erroutc.adb, expander.adb, exp_ch4.adb, exp_ch7.adb,
4098 freeze.adb, get_alfa.adb, get_alfa.ads, gnat1drv.adb, lib-writ.adb,
4099 lib-writ.ads, lib-xref.adb, lib-xref.ads, lib-xref-alfa.adb, opt.adb,
4100 opt.ads, put_alfa.adb, put_alfa.ads, restrict.adb, sem_ch12.adb,
4101 sem_ch13.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
4102 sem_prag.adb, sem_res.adb, sem_util.adb: Minor reformatting, renaming
4103 ALFA in Alfa (we dropped acronym).
56812278
AC
4104 * einfo.adb (Primitive_Operations): Correctly return list of primitive
4105 operations in a case where it returned previously No_Elist.
4106
7cda9727
RD
41072011-08-31 Robert Dewar <dewar@adacore.com>
4108
4109 * s-taprop-vxworks.adb, sem_ch5.adb, s-taprop-tru64.adb, exp_alfa.adb,
4110 s-taprop-vms.adb, bindgen.adb, s-mudido.adb, s-mudido.ads,
4111 sem_res.adb, expander.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
4112 s-taprop-solaris.adb, s-mudido-affinity.adb, vms_conv.adb,
4113 s-taprop-irix.adb, s-taprop.ads, s-taskin.adb, s-taskin.ads,
4114 s-taprop-hpux-dce.adb, a-chtgbo.adb, s-taprop-posix.adb: Minor
4115 reformatting.
4116
0a190dfd
AC
41172011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
4118
4119 * sem_ch12 (Check_Private_View): Revert previous change.
4120 * sem_res.adb (Conversion_Check): Do not emit the error message if the
4121 conversion is in a generic instance.
4122
41232011-08-31 Matthew Heaney <heaney@adacore.com>
4124
4125 * a-cbhase.adb (Symmetric_Difference): Dereference correct node array.
4126 * a-chtgbo.adb (Free): Allow 0 as index value.
4127
41282011-08-31 Matthew Heaney <heaney@adacore.com>
4129
4130 * a-cborma.adb (Insert): Add comment to explain why no element
4131 assignment.
4132
41332011-08-31 Gary Dismukes <dismukes@adacore.com>
4134
4135 * sem_util.adb (Find_Body_Discriminal): Test whether the scope of the
4136 spec discriminant is already a concurrent type, in which case just use
4137 it, otherwise fetch the Corresponding_Concurrent_Type as before.
4138
7d266442
EB
41392011-08-30 Eric Botcazou <ebotcazou@adacore.com>
4140
4141 * system-irix-n64.ads, system-linux-armeb.ads, system-linux-armel.ads,
4142 system-linux-mips.ads, system-linux-mipsel.ads,
4143 system-linux-mips64el.ads, system-linux-ppc64.ads,
4144 system-linux-sparcv9.ads, system-rtems.ads: Remove GCC_ZCX_Support.
4145
4f1a975c
EB
41462011-08-30 Eric Botcazou <ebotcazou@adacore.com>
4147
4148 * gcc-interface/ada-tree.h (TYPE_EXTRA_SUBTYPE_P): Add internal check.
4149 * gcc-interface/utils2.c (build_binary_op): Tighten condition.
4150 (build_unary_op): Likewise.
4151
f2991b48
EB
41522011-08-30 Eric Botcazou <ebotcazou@adacore.com>
4153
4154 * raise-gcc.c: Do not include coretypes.h and tm.h.
4155 (setup_to_install): Remove test for compiler macro.
4156 * targext.c: Document use for the library.
4157 * gcc-interface/Makefile.in: Fix comment on the use of IN_GCC.
4158
10a22f43
EB
41592011-08-30 Eric Botcazou <ebotcazou@adacore.com>
4160
4161 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Do not convert
4162 the expression to the nominal type if the latter is a record type with
4163 a variant part and the type of the former is a record type without one.
4164
bfa2e39d
AC
41652011-08-30 Yannick Moy <moy@adacore.com>
4166
4167 * exp_aggr.adb, exp_ch11.adb, exp_prag.adb: Remove early exit during
4168 expansion in Alfa mode.
4169 * exp_ch6.adb, exp_ch6.ads (Expand_Actuals): Make subprogram public
4170 * exp_alfa.adb, exp_alfa.ads: New package defining light expansion for
4171 Alfa mode.
4172 * gnat1drv.adb (Adjust_Global_Switches): Update Comment.
4173 * sem_res.adb: Ditto.
bd34109a 4174 * gcc-interface/Make-lang.in: Update dependencies.
bfa2e39d
AC
4175
41762011-08-30 Thomas Quinot <quinot@adacore.com>
4177
4178 * g-socket.ads: Minor documentation adjustment.
4179
a0347839
AC
41802011-08-30 Robert Dewar <dewar@adacore.com>
4181
4182 * exp_ch9.adb, s-tassta.adb, s-secsta.adb: Minor reformatting.
4183
41842011-08-30 Yannick Moy <moy@adacore.com>
4185
4186 * exp_ch6_light.adb, exp_ch6_light.ads, exp_attr_light.adb,
4187 exp_attr_light.ads, exp_ch7_light.adb, exp_ch7_light.ads,
4188 exp_light.adb, exp_light.ads, exp_prag.adb, expander.adb,
4189 gnat1drv.adb, exp_ch11.adb, exp_ch6.adb, exp_ch6.ads, exp_aggr.adb:
4190 Revert change which introduced files for "light"
4191 expansion, to be replaced by a single file for Alfa expansion.
4192
3597c0e9
RD
41932011-08-30 Robert Dewar <dewar@adacore.com>
4194
4195 * opt.ads, s-soflin.adb, exp_ch9.adb, sem_res.adb: Update comment.
4196 Minor code reorg/reformatting.
4197
da94696d
AC
41982011-08-30 Yannick Moy <moy@adacore.com>
4199
4200 * opt.adb, opt.ads (Full_Expander_Active): New function defines a
4201 common shorthand for (Expander_Active and not ALFA_Mode) that can be
4202 used for testing full expansion, that is active expansion not in the
4203 reduced mode for Alfa
4204 * exp_ch4.adb, exp_ch9.adb, exp_disp.adb, sem_ch10.adb, sem_ch12.adb,
4205 sem_ch6.adb, sem_ch9.adb, sem_res.adb: Use newly defined "flag" instead
4206 of the verbose (Expander_Active and not ALFA_Mode)
4207
42082011-08-30 Tristan Gingold <gingold@adacore.com>
4209
4210 * s-parame-vms-alpha.ads, s-parame-hpux.ads, s-tassta.adb,
4211 s-tarest.adb, s-parame-vms-ia64.ads, s-soflin.adb, s-secsta.adb,
5b8ca141
TG
4212 s-secsta.ads, s-parame.ads, s-parame-vxworks.ads, s-parame-ae653.ads:
4213 Renames Ratio to Percentage, and Sec_Stack_Ratio to Sec_Stack_Percentage
da94696d 4214
c199ccf7
AC
42152011-08-30 Gary Dismukes <dismukes@adacore.com>
4216
4217 * sem_res.adb (Valid_Conversion): Revise test for implicit anonymous
4218 access conversions to check that the conversion is a rewritten node,
4219 rather than just having Comes_From_Source set to False, which wasn't
4220 sufficient.
4221
42222011-08-30 Robert Dewar <dewar@adacore.com>
4223
4224 * exp_ch9.adb, sem_ch9.adb, sem_ch6.adb, exp_disp.adb,
4225 g-socket.ads: Minor reformatting.
4226
42272011-08-30 Thomas Quinot <quinot@adacore.com>
4228
4229 * sem_util.adb: Minor reformatting.
4230
42312011-08-30 Tristan Gingold <gingold@adacore.com>
4232
4233 * raise-gcc.c: Never catch exception if _UA_FORCE_UNWIND flag is set,
4234 to be compliant with the ABI.
4235
dff99e1a
AC
42362011-08-30 Hristian Kirtchev <kirtchev@adacore.com>
4237
4238 * sem_ch12.adb (Check_Private_View): Exchange the private and full view
4239 of a designated type when the related access type is an actual in an
4240 instance. This ensures that the full view of designated type is
4241 available when inside the body of the instance.
4242
42432011-08-30 Ed Schonberg <schonberg@adacore.com>
4244
4245 * sem_util.adb (May_Be_Lvalue): To determine whether a reference may be
4246 in a position to be modified, a slice is treated like an indexed
4247 component.
4248
63be2a5a
AC
42492011-08-30 Thomas Quinot <quinot@adacore.com>
4250
4251 * s-oscons-tmplt.c, g-socket.ads: Adjust maximum allowed value for
4252 field tv_sec in struct timeval.
4253
42542011-08-30 Yannick Moy <moy@adacore.com>
4255
4256 * exp_ch9.adb, exp_disp.adb, sem_ch9.adb, sem_res.adb: Protect several
4257 blocks of code doing full expansion, previously only guarded by
4258 Expander_Active, by anding the test that ALFA_Mode is not set
4259
42602011-08-30 Ed Schonberg <schonberg@adacore.com>
4261
4262 * sem_ch6.adb (Analyze_Return_Type): If the return type is incomplete,
4263 add the function to the list of private dependents, for subsequent
4264 legality check on Taft amendment types.
4265 * sem_ch12.adb (Analyze_Formal_Incomplete_Type): Initialize
4266 Private_Dependents, as for other incomplete types.
4267 * sem_util.adb (Wrong_Type): Avoid cascaded errors when a
4268 Taft-amendment type is used as the return type of a function.
4269
dd54644b
JM
42702011-08-30 Javier Miranda <miranda@adacore.com>
4271
4272 * sem_ch3.adb (Check_Abstract_Overriding): Code cleanup: replace code
4273 which emits an error by a call to a new routine which report the error.
4274 * exp_ch9.adb (Build_Wrapper_Spec): Build the wrapper even if the
4275 entity does not cover an existing interface.
4276 * errout.ads, errout.adb (Error_Msg_PT): New routine. Used to factorize
4277 code.
4278 * sem_ch6.adb (Check_Conformance): Add specific error for wrappers of
4279 protected procedures or entries whose mode is not conformant.
4280 (Check_Synchronized_Overriding): Code cleanup: replace code which emits
4281 an error by a call to a new routine which report the error.
4282
d3ba478e
AC
42832011-08-30 Robert Dewar <dewar@adacore.com>
4284
4285 * gnat_rm.texi: Minor change.
4286 * exp_attr_light.adb: Minor reformatting.
4287
42882011-08-30 Ed Schonberg <schonberg@adacore.com>
4289
4290 * sem_ch3.adb: Patch inheritance of aspects in
4291 Complete_Private_Subtype, to avoid infinite loop.
4292
c01817d2
AC
42932011-08-30 Javier Miranda <miranda@adacore.com>
4294
4295 * sem_ch3.adb (Add_Internal_Interface_Entities): If serious errors have
4296 been reported and a subprogram covering an interface primitive is not
4297 found then skip generating the internal entity. Done to avoid crashing
4298 the frontend.
4299 (Check_Abstract_Overriding): Change text of error of wrong formal of
4300 protected subprogram or entry. Done for consistency to emit exactly the
4301 same error reported by Check_Synchronized_Overriding. In addition, the
4302 error is restricted to protected types (bug found working on AI05-0090)
4303
43042011-08-30 Yannick Moy <moy@adacore.com>
4305
4306 * exp_aggr.adb, exp_ch11.adb, exp_prag.adb: Remove early exit during
4307 expansion in Alfa mode.
4308 * exp_ch6.adb, exp_ch6.ads (Expand_Actuals): Make subprogram public.
4309 * exp_light.adb, exp_light.ads: New package defining light expansion.
4310 * expander.adb (Expand): Call light expansion in Alfa mode
4311 * exp_ch6_light.adb, exp_ch6_light.ads: Light expansion of chapter 6
4312 constructs.
4313 * exp_ch7_light.adb, exp_ch7_light.ads: Light expansion of chapter 7
4314 constructs.
4315 * exp_attr_light.adb, exp_attr_light.ads: Light expansion of attributes
4316 * gnat1drv.adb (Adjust_Global_Switches): Comment
4317
43182011-08-30 Yannick Moy <moy@adacore.com>
4319
4320 * lib-xref-alfa.adb: Minor refactoring.
4321
43222011-08-30 Yannick Moy <moy@adacore.com>
4323
4324 * exp_ch9.adb (Expand_Entry_Barrier): Do not perform expansion in Alfa
4325 mode.
4326 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Do not perform
4327 expansion in Alfa mode.
4328 * sem_ch9.adb (Analyze_Entry_Body): Do not perform expansion in Alfa
4329 mode.
4330
43312011-08-30 Robert Dewar <dewar@adacore.com>
4332
4333 * debug_a.adb: Update comment.
4334
996c8821
RD
43352011-08-30 Robert Dewar <dewar@adacore.com>
4336
4337 * exp_ch5.adb, sem_ch3.adb, sem_ch5.adb, einfo.adb, checks.adb,
4338 sem_util.adb, sem_util.ads, sem_res.adb, s-stposu.adb, sem_attr.adb,
4339 exp_ch4.adb, exp_ch6.adb, lib-xref-alfa.adb,
4340 sem_ch8.adb, sem_disp.adb, exp_ch3.adb: Minor reformatting
4341
43422011-08-30 Robert Dewar <dewar@adacore.com>
4343
4344 * gnat_rm.texi: Add section on C.6(16) implementation advice for pragma
4345 volatile.
4346
3647ca26
HK
43472011-08-30 Hristian Kirtchev <kirtchev@adacore.com>
4348
4349 * exp_ch3.adb (Expand_Freeze_Array_Type): Correct the call to
4350 Build_Finalization_Master by supplying an insertion node and enclosing
4351 scope. In its old version, the call did not generate a finalization
4352 master.
4353 (Expand_Freeze_Record_Type): Add local variable Has_AACC. Add code to
4354 recognize anonymous access-to-controlled components. Rewrite the
4355 machinery which creates finalization masters to service anonymous
4356 access-to-controlled components of a record type. In its current state,
4357 only one heterogeneous master is necessary to handle multiple anonymous
4358 components.
4359 (Freeze_Type): Comment reformatting.
4360 * rtsfind.ads: Add RE_Set_Is_Heterogeneous to tables RE_Id and
4361 RE_Unit_Table.
4362 * s-stposu.adb (Allocate_Any_Controlled): Rewrite the machinery which
4363 associates TSS primitive Finalize_Address with either the master itself
4364 or with the internal hash table depending on the mode of operation of
4365 the master.
4366
6d4e4fbc
JM
43672011-08-30 Javier Miranda <miranda@adacore.com>
4368
4369 * exp_ch3.adb (Make_Eq_If): If the etype of the _parent component is an
4370 interface type then do not generate code to compare this component.
4371 Required since they have no components and their equality operator is
4372 abstract.
4373
d15f9422
AC
43742011-08-30 Steve Baird <baird@adacore.com>
4375
4376 * sem_util.ads (Deepest_Type_Access_Level): New function; for the type
4377 of a saooaaat (i.e, a stand-alone object of an anonymous access type),
4378 returns the (static) accessibility level of the object. Otherwise, the
4379 same as Type_Access_Level.
4380 (Dynamic_Accessibility_Level): New function; given an expression which
4381 could occur as the rhs of an assignment to a saooaaat (i.e., an
4382 expression of an access-to-object type), return the new value for the
4383 saooaaat's associated Extra_Accessibility object.
4384 (Effective_Extra_Accessibility): New function; same as
4385 Einfo.Extra_Accessibility except that object renames are looked through.
4386 * sem_util.adb
4387 (Deepest_Type_Access_Level): New function; see sem_util.ads description.
4388 (Dynamic_Accessibility_Level): New function; see sem_util.ads
4389 description.
4390 (Effective_Extra_Accessibility): New function; see sem_util.ads
4391 description.
4392 * einfo.ads (Is_Local_Anonymous_Access): Update comments.
4393 (Extra_Accessibility): Update comments.
4394 (Init_Object_Size_Align): New procedure; same as Init_Size_Align
4395 except RM_Size field (which is only for types) is unaffected.
4396 * einfo.adb
4397 (Extra_Accessibility): Expand domain to allow objects, not just formals.
4398 (Set_Extra_Accessibility): Expand domain to allow objects, not just
4399 formals.
4400 (Init_Size): Add assertion that we are not trashing the
4401 Extra_Accessibility attribute of an object.
4402 (Init_Size_Align): Add assertion that we are not trashing the
4403 Extra_Accessibility attribute of an object.
4404 (Init_Object_Size_Align): New procedure; see einfo.ads description.
4405 * sem_ch3.adb (Find_Type_Of_Object): Set Is_Local_Anonymous_Access
4406 differently for the type of a (non-library-level) saooaaat depending
4407 whether Ada_Version < Ada_2012. This is the only point where Ada_Version
4408 is queried in this set of changes - everything else (in particular,
4409 setting of the Extra_Accessibility attribute in exp_ch3.adb) is
4410 driven off of the setting of the Is_Local_Anonymous_Access attribute.
4411 The special treatment of library-level saooaaats is an optimization,
4412 not required for correctnesss. This is based on the observation that the
4413 Ada2012 rules (static and dynamic) for saooaaats turn out to be
4414 equivalent to the Ada2005 rules in the case of a library-level saooaaat.
4415 * exp_ch3.adb
4416 (Expand_N_Object_Declaration): If Is_Local_Anonymous_Access is
4417 false for the type of a saooaaat, declare and initialize its
4418 accessibility level object and set the Extra_Accessibility attribute
4419 of the saooaaat to refer to this object.
4420 * checks.adb (Apply_Accessibility_Check): Add Ada 2012 saooaaat support.
4421 * exp_ch4.adb (Expand_N_In): Replace some Extra_Accessibility calls with
4422 calls to Effective_Extra_Accessibility in order to support
4423 renames of saooaaats.
4424 (Expand_N_Type_Conversion): Add new local function,
4425 Has_Extra_Accessibility, and call it when determining whether an
4426 accessibility check is needed.
4427 It returns True iff Present (Effective_Extra_Accessibility (Id)) would
4428 evaluate to True (without raising an exception).
4429 * exp_ch5.adb
4430 (Expand_N_Assignment_Statement): When assigning to an Ada2012
4431 saooaaat, update its associated Extra_Accessibility object (if
4432 it has one). This includes an accessibility check.
4433 * exp_ch6.adb (Add_Call_By_Copy_Code): When parameter copy-back updates
4434 a saooaaat, update its Extra_Accessibility object too (if it
4435 has one).
4436 (Expand_Call): Replace a couple of calls to Type_Access_Level
4437 with calls to Dynamic_Access_Level to handle cases where
4438 passing a literal (any literal) is incorrect.
4439 * sem_attr.adb (Resolve_Attribute): Handle the static accessibility
4440 checks associated with "Saooaat := Some_Object'Access;"; this must
4441 be rejected if Some_Object is declared in a more nested scope
4442 than Saooaat.
4443 * sem_ch5.adb (Analyze_Assignment): Force accessibility checking for an
4444 assignment to a saooaaat even if Is_Local_Anonymous_Access
4445 returns False for its type (indicating a 2012-style saooaaat).
4446 * sem_ch8.adb
4447 (Analyze_Object_Renaming): Replace a call to Init_Size_Align
4448 (which is only appropriate for objects, not types) with a call
4449 of Init_Object_Size_Align in order to avoid trashing the
4450 Extra_Accessibility attribute of a rename (the two attributes
4451 share storage).
4452 * sem_res.adb
4453 (Valid_Conversion) Replace six calls to Type_Access_Level with
4454 calls to Deepest_Type_Access_Level. This is a bit tricky. For an
4455 Ada2012 non-library-level saooaaat, the former returns library level
4456 while the latter returns the (static) accessibility level of the
4457 saooaaat. A type conversion to the anonymous type of a saooaaat
4458 can only occur as part of an assignment to the saooaaat, so we
4459 know that such a conversion must be in a lhs context, so Deepest
4460 yields the result that we need. If such a conversion could occur,
4461 say, as the operand of an equality operator, then this might not
4462 be right. Also add a test so that static accessibilty checks are
4463 performed for converting to a saooaaat's type even if
4464 Is_Local_Anonymous_Access yields False for the type.
4465
44662011-08-30 Javier Miranda <miranda@adacore.com>
4467
4468 * sem_disp.adb (Check_Dispatching_Operation): Complete condition that
4469 controls generation of a warning associated with late declaration of
4470 dispatching functions. Required to avoid generating spurious
4471 warnings.
4472
6cce2156
GD
44732011-08-30 Gary Dismukes <dismukes@adacore.com>
4474
4475 * sem_ch6.adb (Check_Return_Subtype_Indication): Issue error if the
4476 return object has an anonymous access type and the function's type is
4477 a named access type.
4478 * sem_ch8.adb (Analyze_Object_Renaming): Suppress error about renaming
4479 conversions on implicit conversions, since such conversions can occur
4480 for anonymous access cases due to expansion. Issue error for attempt
4481 to rename an anonymous expression as an object of a named access type.
4482 * sem_res.ads (Valid_Conversion): Add defaulted parameter Report_Errs,
4483 to indicate whether this function should report errors on invalid
4484 conversions.
4485 * sem_res.adb (Resolve): For Ada 2012, in the case where the type of
4486 the expression is of an anonymous access type and the expected type is
4487 a named general access type, rewrite the expression as a type
4488 conversion, unless this is an expression of a membership test.
4489 (Valid_Conversion.Error_Msg_N): New procedure that conditions the
4490 calling of Error_Msg_N on new formal Report_Errs.
4491 (Valid_Conversion.Error_Msg_NE): New procedure that conditions the
4492 calling of Error_Msg_NE on new formal Report_Errs.
4493 (Valid_Conversion): Move declaration of this function to the package
4494 spec, to allow calls from membership test processing. For Ada 2012,
4495 enforce legality restrictions on implicit conversions of anonymous
4496 access values to general access types, disallowing such conversions in
4497 cases where the expression has a dynamic accessibility level (access
4498 parameters, stand-alone anonymous access objects, or a component of a
4499 dereference of one of the first two cases).
4500 * sem_type.adb (Covers): For Ada 2012, allow an anonymous access type
4501 in the context of a named general access expected type.
4502 * exp_ch4.adb Add with and use of Exp_Ch2.
4503 (Expand_N_In): Add processing for membership tests applied to
4504 expressions of an anonymous access type. First, Valid_Conversion is
4505 called to check whether the test is statically False, and then the
4506 conversion is expanded to test that the expression's accessibility
4507 level is no deeper than that of the tested type. In the case of
4508 anonymous access-to-tagged types, a tagged membership test is applied
4509 as well.
4510 (Tagged_Membership): Extend to handle access type cases, applying the
4511 test to the designated types.
4512 * exp_ch6.adb (Expand_Call): When creating an extra actual for an
4513 accessibility level, and the actual is a 'Access applied to a current
4514 instance, pass the accessibility level of the type of the current
4515 instance rather than applying Object_Access_Level to the prefix. Add a
4516 ??? comment, since this level isn't quite right either (will eventually
4517 need to pass an implicit level parameter to init procs).
4518
747de90b
AC
45192011-08-30 Bob Duff <duff@adacore.com>
4520
4521 * s-taskin.ads: Minor comment fix.
4522
45232011-08-30 Ed Schonberg <schonberg@adacore.com>
4524
4525 * sem_res.adb (Check_Parameterless_Call): If the node is a selected
4526 component and the selector is a dispatching operation, check if it is
4527 a prefixed call before rewriting as a parameterless function call.
4528
cdc4cc65
JJ
45292011-08-29 Jakub Jelinek <jakub@redhat.com>
4530
4531 * gcc-interface/Makefile.in (../stamp-gnatlib1-$(RTSDIR)): Copy
4532 tsystem.h into $(RTSDIR) instead of rts.
4533
226a7fa4
AC
45342011-08-29 Robert Dewar <dewar@adacore.com>
4535
4536 * sem_ch10.adb, a-coorse.adb, exp_dist.adb, exp_ch3.adb: Minor
4537 reformatting.
4538 * gcc-interface/Make-lang.in: Update dependencies.
4539
45402011-08-29 Yannick Moy <moy@adacore.com>
4541
4542 * alfa.ads (Name_Of_Heap_Variable): New constant name.
4543 * lib-xref-alfa.adb, lib-xref.adb, lib-xref.ads (Drefs): New global
4544 table to hold dereferences.
4545 (Add_ALFA_Xrefs): Take into account dereferences as special
4546 reads/writes to the variable "HEAP".
4547 (Enclosing_Subprogram_Or_Package): Move subprogram here.
4548 (Generate_Dereference): New procedure to store a read/write dereferencew
4549 in the table Drefs.
4550 * put_alfa.adb (Put_ALFA): Use different default than (0,0) used for
4551 the special "HEAP" var.
4552 * sem_ch4.adb (Analyze_Explicit_Dereference): Store read dereference
4553 in ALFA mode.
4554 * sem_util.adb (Note_Possible_Modification): Store write dereference
4555 in ALFA mode.
4556
dfbcb149
HK
45572011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4558
4559 * exp_ch3.adb (Freeze_Type): Generate an accessibility check which
4560 ensures that the level of the subpool access type is not deeper than
4561 that of the pool object.
4562 * sem_util.adb (Object_Access_Level): Expand to handle defining
4563 identifiers.
4564 * sem_res.adb (Resolve_Allocator): Add a guard to avoid examining the
4565 subpool handle name of a rewritten allocator.
4566
1df4f514
AC
45672011-08-29 Robert Dewar <dewar@adacore.com>
4568
4569 * impunit.adb, exp_ch4.adb, s-finmas.adb: Minor reformatting.
4570
45712011-08-29 Thomas Quinot <quinot@adacore.com>
4572
4573 * exp_dist.adb (TC_Rec_Add_Process_Element): For a choice with multiple
4574 values, we generate multiple triples of parameters in the TypeCode.
4575 Bump Choice_Index for each such triple so that a subsequent default
4576 choice is associated with the correct index in the typecode.
4577
45782011-08-29 Ed Schonberg <schonberg@adacore.com>
4579
4580 * a-cdlili.adb (Iterate): Initialize properly an iterator over a null
4581 container.
4582 (First, Last): Handle properly an iterator over a null container.
4583
45842011-08-29 Bob Duff <duff@adacore.com>
4585
4586 * sem_ch10.adb (Analyze_With_Clause,Install_Withed_Unit): Abandon
4587 processing if we run across a node with no Scope. This can happen if
4588 we're with-ing an library-level instance, and that instance got errors
4589 that caused "instantiation abandoned".
4590 * sem_util.adb (Unit_Declaration_Node): Make it more robust, by raising
4591 an exception instead of using Assert, so it won't go into an infinite
4592 loop, even when assertions are turned off.
4593
45942011-08-29 Ed Schonberg <schonberg@adacore.com>
4595
4596 * a-coorse.adb: Proper handling of empty ordered sets.
4597
14f0f659
AC
45982011-08-29 Johannes Kanig <kanig@adacore.com>
4599
4600 * debug.adb: Add comments.
4601
8027b455
AC
46022011-08-29 Thomas Quinot <quinot@adacore.com>
4603
4604 * a-except.adb, a-except-2005.adb: Minor comment rewording and
4605 reformatting.
4606
46072011-08-29 Yannick Moy <moy@adacore.com>
4608
4609 * sem_ch3.adb (Array_Type_Declaration): Remove insertion of
4610 declaration for Itypes in Alfa mode.
4611
d85fd922
AC
46122011-08-29 Robert Dewar <dewar@adacore.com>
4613
4614 * a-cdlili.ads, a-coinve.ads, a-coorma.adb, a-coorma.ads, s-tassta.adb,
4615 a-cborma.adb, a-cborma.ads, a-cohama.ads, a-coorse.ads, a-cbhama.ads,
4616 a-cborse.ads, a-cobove.adb, a-cobove.ads, a-cbhase.ads: Minor
4617 reformatting.
4618
46192011-08-29 Tristan Gingold <gingold@adacore.com>
4620
4621 * exp_ch7.adb, exp_ch7.ads (Build_Exception_Handler): Move its spec to
4622 package spec.
4623 * exp_intr.adb (Expand_Unc_Deallocation): Use Build_Exception_Handler.
4624 * a-except.adb, a-except-2005.adb (Rcheck_22): Do not defer aborts
4625 while raising PE.
4626
fd3d2680
AC
46272011-08-29 Robert Dewar <dewar@adacore.com>
4628
4629 * a-cbhama.adb, a-cbhama.ads: Minor reformatting.
4630
46312011-08-29 Javier Miranda <miranda@adacore.com>
4632
4633 * sem_ch8.adb (Analyze_Subprogram_Renaming): Complete support for
4634 renamings of formal subprograms when the actual for a formal type is
4635 class-wide.
4636
dfbf013f
MH
46372011-08-29 Matthew Heaney <heaney@adacore.com>
4638
4639 * a-cbhama.ads, a-cbhase.ads (Move): Clear Source following assignment
4640 to Target.
4641
46422011-08-29 Matthew Heaney <heaney@adacore.com>
4643
4644 * a-cborma.ads, a-cborse.ads (Cursor): Default-initialize all
4645 components of record type.
4646 * a-cborma.adb, a-cborse.adb (Move): Clear Source following assignmentw
4647 to Target.
4648
a6dd3a54
ES
46492011-08-29 Ed Schonberg <schonberg@adacore.com>
4650
4651 * a-cbhama.adb, a-cbhama.ads, a-cborma.adb, a-cborma.ads, a-cobove.adb,
4652 a-cobove.ads, a-coorma.adb, a-coorma.ads: Add iterator machinery to
4653 container packages.
4654
c54796e0
AC
46552011-08-29 Robert Dewar <dewar@adacore.com>
4656
4657 * sem_ch3.adb, sem_util.adb, gnat1drv.adb, s-parint.ads: Minor
4658 reformatting.
4659
46602011-08-29 Matthew Heaney <heaney@adacore.com>
4661
4662 * a-cbhama.ads, a-cbhase.ads (Cursor): Default-initialize all
4663 components of record type.
4664
46652011-08-29 Bob Duff <duff@adacore.com>
4666
4667 * s-tassta.adb (Task_Wrapper): Handle and ignore exceptions propagated
4668 by the termination handler.
4669
9fd9d2be
AC
46702011-08-29 Yannick Moy <moy@adacore.com>
4671
4672 * sem_ch3.adb (Array_Type_Declaration): Create declarations for Itypes
4673 created in Alfa mode, instead of inserting artificial declarations of
4674 non-Itypes in the tree.
4675 * sem_util.adb, sem_util.ads (Itype_Has_Declaration): New function to
4676 know if an Itype has a corresponding declaration, as defined in
4677 itypes.ads.
4678
46792011-08-29 Yannick Moy <moy@adacore.com>
4680
4681 * gnat1drv.adb: Minor rewrite.
4682
46832011-08-29 Bob Duff <duff@adacore.com>
4684
4685 * s-tasuti.adb (Make_Passive): Work around race condition in
4686 Make_Independent, which can cause Wait_Count to be zero. So instead of
4687 asserting that Wait_Count > 0, and then decrementing it, decrement it
4688 only if Wait_Count > 0.
4689 * s-taskin.ads (Wait_Count, Alive_Count, Awake_Count): All of these
4690 should be nonnegative, so declare them Natural instead of Integer.
4691
833eaa8a
AC
46922011-08-29 Robert Dewar <dewar@adacore.com>
4693
4694 * exp_ch5.adb, sem_ch3.adb, a-cihama.adb, a-cihama.ads, exp_ch7.adb,
4695 sem_ch5.adb, a-ciorse.adb, a-ciorse.ads, sem_ch12.adb, a-cidlli.adb,
4696 a-cidlli.ads, sem_util.adb, sem_res.adb, gnat1drv.adb, a-except.adb,
4697 a-except.ads, a-except-2005.ads, sem_ch4.adb, exp_disp.adb,
4698 exp_aggr.adb, sem_ch13.adb, par-ch3.adb: Minor reformatting.
4699
47002011-08-29 Tristan Gingold <gingold@adacore.com>
4701
4702 * s-auxdec-vms-alpha.adb: Add comments, remove some HT before labels.
4703
47042011-08-29 Vadim Godunko <godunko@adacore.com>
4705
4706 * s-parint.ads: Minor comment clarification.
4707
47082011-08-29 Vincent Celier <celier@adacore.com>
4709
4710 * prj.adb (Initialize): Make sure that new reserved words after Ada 95
4711 may be used as identifiers.
4712
47132011-08-29 Ed Schonberg <schonberg@adacore.com>
4714
4715 * a-coinho.ads: Minor reformating.
4716
3a613a36
AC
47172011-08-29 Ed Schonberg <schonberg@adacore.com>
4718
4719 * exp_ch5.adb (Expand_Iterator_Loop): Handle properly a loop over a
4720 container of a derived type.
4721
3a613a36
AC
47222011-08-29 Ed Schonberg <schonberg@adacore.com>
4723
4724 * a-cidlli.adb, a-cidlli.ads, a-cihama.adb, a-cihama.ads,
4725 a-ciorse.adb, a-ciorse.ads: Add iterator machinery to containers.
4726
14848f57
AC
47272011-08-29 Pascal Obry <obry@adacore.com>
4728
4729 * exp_disp.adb: Minor comment fix.
4730 (Make_Disp_Asynchronous_Select_Body): Properly initialize out parameters
4731 to avoid warnings when compiling with -Wall.
4732 (Make_Disp_Conditional_Select_Body): Likewise.
4733 (Make_Disp_Timed_Select_Body): Likewise.
4734
47352011-08-29 Ed Schonberg <schonberg@adacore.com>
4736
4737 * sem_ch12.adb (Analyze_Formal_Subprogram_Declaration): If default is
4738 an entity name, generate reference for it.
4739
47402011-08-29 Ed Schonberg <schonberg@adacore.com>
4741
4742 * exp_ch5.adb (Expand_Iterator_Loop): Uniform handling of "X of S"
4743 iterator form.
4744 * sem_util.adb (Is_Iterator, Is_Reversible_Iterator): Yield True for
4745 the class-wide type.
4746 * sem_ch5.adb: Move some rewriting to the expander, where it belongs.
4747
47482011-08-29 Ed Schonberg <schonberg@adacore.com>
4749
4750 * sem_ch8.adb (Check_Constrained_Object): Do not create an actual
4751 subtype for an object whose type is an unconstrained union.
4752
47532011-08-29 Ed Schonberg <schonberg@adacore.com>
4754
4755 * par-ch3.adb (P_Array_Type_Definiation, P_Component_Items): "aliased"
4756 is allowed in a component definition, by AI95-406.
4757
47582011-08-29 Matthew Heaney <heaney@adacore.com>
4759
4760 * a-chtgbo.adb (Generic_Iteration): Use correct overloading of Next.
4761
47622011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4763
4764 * a-except-2005.adb: Alphabetize all routines.
4765 (Triggered_By_Abort): New routine.
4766 * a-except-2005.ads (Triggered_By_Abort): New routine.
4767 * a-except.adb Alphabetize all routines.
4768 (Triggered_By_Abort): New routine.
4769 * a-except.ads (Triggered_By_Abort): New routine.
4770 * exp_ch7.adb: Update all comments involving the detection of aborts in
4771 finalization code.
4772 (Build_Object_Declarations): Do not generate code to detect the
4773 presence of an abort at the start of finalization code, use a runtime
4774 routine istead.
4775 * rtsfind.ads: Add RE_Triggered_By_Abort to tables RE_Id and
4776 RE_Unit_Table.
4777 * sem_res.adb (Resolve_Allocator): Emit a warning when attempting to
4778 allocate a task on a subpool.
4779 * s-stposu.adb: Add library-level flag Finalize_Address_Table_In_Use.
4780 The flag disables all actions related to the maintenance of
4781 Finalize_Address_Table when subpools are not in use.
4782 (Allocate_Any_Controlled): Signal the machinery that subpools are in
4783 use.
4784 (Deallocate_Any_Controlled): Do not call Delete_Finalize_Address which
4785 performs costly task locking when subpools are not in use.
4786
57a8057a
AC
47872011-08-29 Yannick Moy <moy@adacore.com>
4788
4789 * gnat1drv.adb (Adjust_Global_Switches): Restore expansion of tagged
4790 types and dispatching calls in Alfa mode.
4791 * lib-xref-alfa.adb (Collect_ALFA): Rewrite computation of
4792 correspondance between body and spec scopes, to reuse utility functions
4793 (Traverse_Declarations_Or_Statements): Protect access to body for stub
4794 by testing the presence of the library unit for the body
4795 * sem_ch6.adb (Set_Actual_Subtypes): take into account that in Alfa
4796 mode the expansion of accept statements is skipped
4797 * sem_util.adb, sem_util.ads (Unique_Entity): New function returning
4798 the unique entity corresponding to the one returned by
4799 Unique_Defining_Entity applied to the enclosing declaration of the
4800 argument.
4801
48022011-08-29 Bob Duff <duff@adacore.com>
4803
4804 * treepr.ads: Improve debugging facilities. pn(x) no longer crashes in
4805 gdb when x is not a node (it can be a node list, name_id, etc). pp is
4806 an alias for pn. ppp is an alias for pt.
4807
48082011-08-29 Javier Miranda <miranda@adacore.com>
4809
4810 * exp_aggr.adb (Expand_Record_Aggregate): Use the top-level enclosing
4811 aggregate to take a consistent decision on the need to convert into
4812 assignments aggregates that initialize constant objects.
4813
48142011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4815
4816 * exp_ch4.adb (Expand_Allocator_Expression): Add a call to
4817 Build_Allocate_Deallocate_Proc in order to handle allocation of
4818 non-controlled objects on subpools.
4819 * impunit.adb: Remove s-finmas and s-spsufi since they were never meant
4820 to be end-user visible.
4821 * s-finmas.adb: Add with and use clause for System.HTable.
4822 Add an instantiation of Simple_HTable which provides a mapping between
4823 the address of a controlled object and the corresponding
4824 Finalize_Address used to clean up the object. The table is used when a
4825 master is operating in heterogeneous mode.
4826 (Attach): Explain why the input node is not verified on being already
4827 attached.
4828 (Delete_Finalize_Address): New routine.
4829 (Detach): Add pragma Assert which ensures that a node is already
4830 attached.
4831 (Finalize): Add local variable Cleanup. Rewrite the iteration scheme
4832 since nodes are no longer removed on traversal. Explain why node
4833 detachment is undesirable in this case.
4834 (Get_Finalize_Address): New routine.
4835 (Hash): New routine.
4836 (Is_Empty_List): Removed.
4837 (pm): Renamed to Print_Master. Add output for discriminant
4838 Is_Homogeneous.
4839 Comment reformatting.
4840 (Set_Finalize_Address (Address, Finalize_Address_Ptr)): New routine.
4841 * s-finmas.ads: Various comments additions / improvements.
4842 Type Finalization_Master has a discriminant which determines the mode of
4843 operation.
4844 (Delete_Finalize_Address): New routine.
4845 (Get_Finalize_Address): New routine.
4846 (pm): Renamed to Print_Master.
4847 (Set_Finalize_Address (Address, Finalize_Address_Ptr)): New routine.
4848 * s-stposu.adb: Add with clause for System.Address_Image; Add with and
4849 use clause for System.IO.
4850 (Allocate_Any_Controlled): Add machinery to set TSS primitive
4851 Finalize_Address depending on the mode of allocation and the mode of
4852 the master.
4853 (Deallocate_Any_Controlled): Remove the relation pair object -
4854 Finalize_Address regardless of the master mode. Add comment explaining
4855 the reason.
4856 (Detach): Ensure that fields Prev and Next are null after detachment.
4857 (Finalize_Pool): Remove local variable Next_Ptr. Rewrite the iteration
4858 scheme to check whether the list of subpools is empty. There is no
4859 longer need to store the next subpool or advance the current pointer.
4860 (Is_Empty_List): New routine.
4861 (Print_Pool): New routine.
4862 (Print_Subpool): New routine.
4863 * s-stposu.ads: Various comments additions / improvements.
4864 Field Master of type Root_Subpool is now a heterogeneous collection.
4865 (Print_Pool): New routine.
4866 (Print_Subpool): New routine.
4867
48682011-08-29 Ed Schonberg <schonberg@adacore.com>
4869
4870 * exp_ch5.adb (Expand_N_Iterator_Loop): Implement Ada2012 loop iterator
4871 forms, using aspects of container types.
4872 * sem_ch3.adb (Find_Type_Name): Preserve Has_Delayed_Aspects and
4873 Has_Implicit_Dereference flags, that may be set on the partial view.
4874 * sem_ch4.adb (Process_Overloaded_Indexed_Component): Prefix may be a
4875 container type with an indexing aspect.
4876 (Analyze_Quantified_Expression): Analyze construct with expansion
4877 disabled, because it will be rewritten as a loop during expansion.
4878 (Try_Container_Indexing): The prefix itself may be a container type
4879 with an indexing aspect, as with a vector of vectors.
4880 * sem_ch5.adb (Analyze_Iteration_Scheme): In a generic context, analyze
4881 the original doamin of iteration, for name capture.
4882 (Analyze_Iterator_Specification): If the domain is an expression that
4883 needs finalization, create a separate declaration for it.
4884 For an iterator with "of" retrieve default iterator info from aspect of
4885 container type. For "in" iterator, retrieve type of Iterate function.
4886 * sem_ch13.adb (Check_Iterator_Function): Fix typo.
4887 (Check_Aspect_At_End_Of_Declaration): Make type unfrozen before
4888 analysis, to prevent spurious errors about late attributes.
4889 * sprint.adb: Handle quantified expression with either loop or iterator
4890 specification.
4891 * a-convec.ads, a-convec.adb: Iterate function returns a reversible
4892 iterator.
4893
ddf67a1d
AC
48942011-08-29 Vincent Celier <celier@adacore.com>
4895
4896 * make.adb (Scan_Make_Arg): Take any option as is in packages Compiler,
4897 Binder or Linker of the main project file.
4898
48992011-08-29 Ed Schonberg <schonberg@adacore.com>
4900
4901 * inline.adb (Add_Scopes_To_Clean): Exclude any entity within a generic
4902 unit.
4903
49042011-08-29 Yannick Moy <moy@adacore.com>
4905
4906 * exp_ch9.adb: Partial revert of previous change for Alfa mode
4907
49082011-08-29 Yannick Moy <moy@adacore.com>
4909
4910 * exp_ch11.adb: Minor expansion of comment.
4911
49122011-08-29 Yannick Moy <moy@adacore.com>
4913
4914 * lib-xref-alfa.adb (Add_ALFA_Scope): Treat generic entities.
4915
49162011-08-29 Ed Schonberg <schonberg@adacore.com>
4917
4918 * sem_res.adb (Resolve_Arithmetic_Op): If the node has a universal
4919 interpretation, set the type before resolving the operands, because
4920 legality checks on an exponention operand need to know the type of the
4921 context.
4922
49232011-08-29 Ed Schonberg <schonberg@adacore.com>
4924
4925 * sem_ch12.adb (Analyze_Package_Instantiation): Do not set delayed
4926 cleanups on a master if the instance is within a generic unit.
4927 Complement to the corresponding fix to inline.adb for K520-030.
4928
49292011-08-29 Tristan Gingold <gingold@adacore.com>
4930
4931 * exp_ch7.adb (Build_Raise_Statement): Raise PE instead of the current
4932 occurrence.
4933 * exp_intr.adb: Minor comment fix.
4934
49352011-08-29 Bob Duff <duff@adacore.com>
4936
4937 * sem_ch13.adb (Analyze_Aspect_Specifications): Fix cases where
4938 Delay_Required was used as an uninitialized variable.
4939
690943fc
RD
49402011-08-29 Robert Dewar <dewar@adacore.com>
4941
4942 * a-cdlili.adb, a-cdlili.ads, a-coinve.adb, a-coinve.ads,
4943 sem_util.adb, sem_util.ads, a-cohama.adb, a-cohama.ads, a-coorse.adb,
4944 a-coorse.ads, aspects.ads, sem_ch8.adb: Minor reformatting.
4945
9f0ee988
TQ
49462011-08-29 Thomas Quinot <quinot@adacore.com>
4947
4948 * system-freebsd-x86_64.ads (Backend_Overflow_Checks): Set true True.
4949 Remove unused variables.
4950
3e24afaa
AC
49512011-08-29 Ed Schonberg <schonberg@adacore.com>
4952
4953 * sem_res.adb: Remove Build_Explicit_Dereference.
4954 * sem_util.adb, sem_util.ads (Build_Explicit_Dereference): Moved here
4955 from sem_res.adb, used in analysis of additional constructs.
4956 (Is_Iterator, Is_Reversible_Iterator): New predicates for Ada2012
4957 expansion of iterators.
4958 (Is_Object_Reference): Recognize variables rewritten as explicit
4959 dereferences in Ada2012.
4960 * snames.ads-tmpl: Add Has_Element, Forward_Iterator,
4961 Reversible_Iterator names, for expansion of Ada2012 iterators.
4962 * aspects.ads, aspects.adb (Find_Aspect): Utility.
4963 * a-cdlili.ads, a-cdlili.adb: Add new iterator machinery to doubly
4964 linked list container.
4965 * a-coinve.ads, a-coinve.adb: Ditto for indefinite vector containers.
4966 * a-coorse.ads, a-coorse.adb: Ditto for ordered sets.
4967
49682011-08-29 Ed Schonberg <schonberg@adacore.com>
4969
4970 * a-cohama.adb, a-cohama.ads: Add iterator primitives to hashed map
4971 containers.
4972
49732011-08-29 Vincent Celier <celier@adacore.com>
4974
4975 * make.adb (Gnatmake): Get the maximum number of simultaneous
4976 compilation processes after the Builder switches has been scanned, as
4977 there may include -jnn.
4978
49792011-08-29 Matthew Heaney <heaney@adacore.com>
4980
4981 * a-chtgbo.adb (Generic_Equal): Use correct overloading of Next.
4982
49832011-08-29 Tristan Gingold <gingold@adacore.com>
4984
4985 * gnatcmd.adb (GNATCmd): On OpenVMS, truncate the length of
4986 GNAT_DRIVER_COMMAND_LINE to 255.
4987
49882011-08-29 Pascal Obry <obry@adacore.com>
4989
4990 * freeze.adb, sem_ch8.adb, a-convec.adb, a-convec.ads: Minor
4991 reformatting and style fix (class attribute casing).
4992
49932011-08-29 Yannick Moy <moy@adacore.com>
4994
4995 * exp_ch11.adb: Yet another case where expansion should be common
4996 between CodePeer and Alfa.
4997
49982011-08-29 Yannick Moy <moy@adacore.com>
4999
5000 * exp_ch9.adb: Partial revert of previous change for Alfa mode.
5001
50022011-08-29 Ed Schonberg <schonberg@adacore.com>
5003
5004 * sem_ch6.adb (Matches_Limited_With_View): The limited views of an
5005 incomplete type and its completion match.
5006
3ddd922e
AC
50072011-08-29 Yannick Moy <moy@adacore.com>
5008
5009 * exp_ch13.adb: Adjust previous change.
5010
50112011-08-29 Robert Dewar <dewar@adacore.com>
5012
5013 * sem_prag.adb, prj.adb, sem_util.adb, sem_res.adb, gnat1drv.adb,
5014 exp_ch4.adb, sem_ch8.adb: Minor code reorganization
5015 Minor reformatting.
5016
444acbdd
AC
50172011-08-29 Emmanuel Briot <briot@adacore.com>
5018
5019 * make.adb, prj.adb, prj.ads (Compute_All_Imported_Projects): Also
5020 initialize aggregated projects.
5021
50222011-08-29 Ed Schonberg <schonberg@adacore.com>
5023
5024 * sem_ch8.adb (Find_Renamed_Entity): Within an instance, use scope
5025 depth of candidates to resolve a potentially spurious ambiguity between
5026 two visible subprograms.
5027
e0296583
AC
50282011-08-29 Yannick Moy <moy@adacore.com>
5029
5030 * sem_prag.adb (Analyze_Pragma): Allow Test_Case pragma without
5031 Requires/Ensures.
5032 * sem_util.adb (Get_Ensures_From_Test_Case_Pragma,
5033 Get_Requires_From_Test_Case_Pragma): Allow Test_Case pragma without
5034 Requires/Ensures.
5035
50362011-08-29 Arnaud Charlet <charlet@adacore.com>
5037
5038 * gnat1drv.adb (Adjust_Global_Switches): Improve previous change.
5039 Add comment.
5040
50412011-08-29 Thomas Quinot <quinot@adacore.com>
5042
5043 * sem_res.adb: Minor reformatting.
5044
69794413
JK
50452011-08-29 Johannes Kanig <kanig@adacore.com>
5046
5047 * exp_ch4.adb (Expand_Quantified_Expression): Do not expand in ALFA
5048 mode.
5049 * gnat1drv.adb (Adjust_Global_Switches): Set
5050 Use_Expressions_With_Actions to False in ALFA mode.
5051 * sem_res.adb (Resolve_Quantified_Expression): Simpler treatment in
5052 ALFA mode.
5053
59e6b23c
AC
50542011-08-29 Yannick Moy <moy@adacore.com>
5055
5056 * exp_ch13.adb (Expand_N_Freeze_Entity): Do nothing in Alfa mode.
5057 * exp_ch9.adb: Do not expand tasking constructs in Alfa mode.
5058 * gnat1drv.adb (Adjust_Global_Switches): Suppress the expansion of
5059 tagged types and dispatching calls in Alfa mode.
5060
50612011-08-29 Javier Miranda <miranda@adacore.com>
5062
5063 * sem_ch3.adb (Process_Discriminants): Add missing check to ensure that
5064 we do not report an error on an Empty node.
5065
50662011-08-29 Geert Bosch <bosch@adacore.com>
5067
5068 * Makefile.rtl (GNATRTL_NONTASKING_OBJECTS): Add a-nllrar.o,
5069 a-nlrear.o and a-nurear.o.
5070
50712011-08-29 Robert Dewar <dewar@adacore.com>
5072
5073 * freeze.adb: Minor code reorganization.
5074 Minor reformatting.
5075 * sem_util.adb, errout.adb, exp_ch11.adb, a-ngrear.adb, s-gearop.adb,
5076 sem_ch6.adb: Minor reformatting
5077
50782011-08-29 Tristan Gingold <gingold@adacore.com>
5079
5080 * s-except.ads, s-except.adb: Provide dummy body.
5081
50822011-08-29 Yannick Moy <moy@adacore.com>
5083
5084 * sem_warn.adb (Within_Postcondition): Take into account the case of
5085 an Ensures component in a Test_Case.
5086
4d792549
AC
50872011-08-29 Tristan Gingold <gingold@adacore.com>
5088
5089 * s-excdeb.ads, s-excdeb.adb: New files, created from s-except.
5090 * rtsfind.ads (RTU_Id): Replaces System_Exceptions by
5091 System_Exceptions_Debug
5092 (RE_Unit_Table): Search RE_Local_Raise in System_Exceptions_Debug
5093 * a-except.adb: With and use System.Exceptions_Debug instead of
5094 System.Exceptions.
5095 * a-except-2005.adb: Likewise.
5096 * s-assert.adb: Likewise.
5097 * s-except.adb, s-except.ads: Move debugging hooks to s-excdeb.
5098 * Makefile.rtl: Add s-excdeb. Adjust compilation rule.
5099 * gcc-interfaces/Makefile.in, gcc-interface/Make-lang.in: Add
5100 s-excdeb. Update dependencies.
5101 (GNATRTL_LINEARALGEBRA_OBJS): Remove a-nlrear.o a-nurear.o a-nllrar.o
5102 as these no longer need external libraries.
5103
51042011-08-29 Ed Schonberg <schonberg@adacore.com>
5105
5106 * sem_res.adb (Resolve_Op_Expon): Additional check to reject an
5107 exponentiation operator on universal values in a context that requires
5108 a fixed-point type.
5109
51102011-08-29 Tristan Gingold <gingold@adacore.com>
5111
5112 * raise-gcc.c (personnality_routine): Fix thinko. Set Ada occurrence
5113 before calling notify_handled_exception.
5114 * a-exextr.adb: Fix comment.
5115
b254da66
AC
51162011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5117
5118 * exp_ch4.adb (Expand_Allocator_Expression): Add code to set attribute
5119 Finalize_Address of the access type's finalization master.
5120 (Expand_N_Allocator): Add code to set attribute Finalize_Address of the
5121 access type's finalization master. Add a guard to prevent
5122 Associated_Storage_Pool from being set on .NET/JVM.
5123 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Add code to set
5124 attribute Finalize_Address of the access type's finalization master.
5125 * exp_ch7.adb (Make_Finalize_Address_Call): New routine.
5126 * exp_ch7.ads (Make_Finalize_Address_Call): New routine.
5127 * rtsfind.ads: Add RE_Set_Finalize_Address to tables RE_Id and
5128 RE_Unit_Table.
5129 * s-finmas.adb: Add with clause for System.Address_Image. Add with and
5130 use clause for System.IO
5131 (Detach): Relax the assertion, to be reinstated later.
5132 (Finalize): Rewrite the iteration loop to avoid pointer comparison.
5133 Relax the assertion on Finalize_Address, to be reinstated later.
5134 (Is_Empty_List): New routine.
5135 (pm): New debug routine.
5136 (Set_Finalize_Address): New routine.
5137 * s-finmas.ads (pm): New debug routine.
5138 (Set_Finalize_Address): New routine.
5139 * s-stposu.adb (Allocate_Any_Controlled): Code reformatting.
5140
51412011-08-29 Tristan Gingold <gingold@adacore.com>
5142
5143 * a-exexpr-gcc.adb (GCC_Exception_Access, GNAT_GCC_Exception_Access):
5144 Remove convention C.
5145
51462011-08-29 Tristan Gingold <gingold@adacore.com>
5147
5148 * s-taprop-vms.adb (Get_Exc_Stack_Addr): Remove.
5149 (Initialize_TCB): Remove Exc_Stack_Ptr initialization.
5150 (Finalize_TCB): Remove its finalization.
5151 (Initialize): Remove assignment of GET_Exc_Stack_Addr
5152 * s-soflin.adb (NT_Exc_Stack): Remove
5153 (Get_Exc_Stack_Addr_NT): Likewise.
5154 (Get_Exc_Stack_Addr_Soft): Likewise.
5155 * s-soflin.ads (Get_Exc_Stack_Addr_NT): Remove.
5156 (Get_Exc_Stack_Addr): Likewise.
5157 (Get_Exc_Stack_Addr_Soft): Likewise
5158 * s-taspri-vms.ads (Exc_Stack_T): Remove.
5159 (Exc_Stack_Ptr_T): Likewise.
5160 (Private_Data): Remove Exc_Stack_Ptr component.
5161
51622011-08-29 Tristan Gingold <gingold@adacore.com>
5163
5164 * raise-gcc.c (get_ip_from_context): New function. Factorize code.
5165
51662011-08-29 Tristan Gingold <gingold@adacore.com>
5167
5168 * gnat_ugn.texi: Fix aix and x86-solaris info for run-time.
5169
51702011-08-29 Geert Bosch <bosch@adacore.com>
5171
5172 * s-gearop.ads (Back_Substitute, Diagonal, Forward_Eliminate,
5173 L2_Norm, Swap_Column): New generic subprograms
5174 * s-gearop.adb (Back_Substitute, Diagonal, Forward_Eliminate,
5175 L2_Norm, Swap_Column): Implement new subprograms in order to
5176 eliminate dependency on BLAS and LAPACK libraries in
5177 Ada.Numerics.Generic_Real_Arrays and eventually also the complex
5178 version. Forward_Eliminate/Back_Substitute can be used to put a
5179 matrix in row echelon or reduced row echelon form using partial
5180 pivoting.
5181 * a-ngrear.adb: (Back_Substitute, Diagonal, Forward_Eleminate,
5182 Swap_Column): Instantiate from System.Generic_Array_Operations.
5183 ("*", "abs"): Implement by instantiation from Generic_Array_Operations.
5184 (Sqrt): Local function for simple computation of square root without
5185 adding dependencies on Generic_Elementary_Functions.
5186 (Swap): New subprogram to exchange floating point numbers.
5187 (Inverse): Reimplement using Jordan-Gauss elimination.
5188 (Jacobi): New procedure implementing Jacobi's method for computation
5189 of eigensystems, based on Rutishauser's implementation.
5190 (L2_Norm): Implement directly using the inner product.
5191 (Sort_Eigensystem): Sort eigenvalue/eigenvector pairs in order of
5192 decreasing eigenvalue as required by the Ada RM.
5193 (Swap_Column): New helper procedure for Sort_Eigensystem.
5194 Remove with of System.Generic_Real_BLAS and System.Generic_Real_LAPACK.
5195 Add with of Ada.Containers.Generic_Anonymous_Array_Sort, for
5196 Sort_Eigensystems.
5197
51982011-08-29 Thomas Quinot <quinot@adacore.com>
5199
5200 * put_scos.adb (Put_SCOs): Do not emit a newline for an empty
5201 statements line.
5202
60370fb1
AC
52032011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5204
5205 * s-finmas.adb (Finalize): Check Finalize_Address of the master rather
5206 than the current node.
5207 * s-finmas.ads: Move field Finalize_Address from type FM_Node to
5208 Finalization_Master. The list headers have two fields instead of three.
5209 This should fix alignment issue but subpool allocations are now
5210 unusable. Alphabetize subprograms.
5211 * s-stposu.adb (Allocate_Any_Controlled): Use the offset rather than
5212 the size of the header when converting the beginning of the object to
5213 a FM_Node. Set the master's Finalize_Address attribute if not already
5214 set.
5215 (Deallocate_Any_Controlled): Use the offset rather than the size of the
5216 header when converting the beginning of the object to a FM_Node.
5217
52182011-08-29 Gary Dismukes <dismukes@adacore.com>
5219
5220 * exp_ch11.adb (Expand_N_Raise_Statement): Don't suppress expansion of
5221 reraise when compiling for CodePeer.
5222
52232011-08-29 Arnaud Charlet <charlet@adacore.com>
5224
5225 * a-iteint.ads, Makefile.rtl: Add missing compilation of a-iteint.ads,
5226 now needed by a-convec.adb. Fix warning.
5227
52282011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5229
5230 * exp_util.adb (Build_Allocate_Deallocate_Proc): Add a guard for the
5231 processing of TSS routine Finalize_Address when compiling in
5232 CodePeer_Mode.
5233
52342011-08-29 Thomas Quinot <quinot@adacore.com>
5235
5236 * a-strunb.ads, einfo.ads, g-comlin.ads, sem_ch6.adb,
5237 sem_warn.adb: Minor reformatting.
5238
52392011-08-29 Emmanuel Briot <briot@adacore.com>
5240
5241 * prj-conf.adb (Get_Config_Switches): Also collect the list of
5242 languages from aggregated projects.
5243
52442011-08-29 Yannick Moy <moy@adacore.com>
5245
5246 * lib-xref-alfa.adb, lib-xref.ads (Traverse_Declarations_Or_Statements,
5247 Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
5248 Traverse_Package_Declaration, Traverse_Subprogram_Body,
5249 Traverse_Compilation_Unit): Add a parameter Inside_Stubs so that bodies
5250 for stubs are traversed too when parameter is set
5251 (Traverse_All_Compilation_Units): Traverse without going inside stubs
5252 (Traverse_Declarations_Or_Statements): Do the special traversing for
5253 stubs when required.
5254 * sem_util.adb, sem_util.ads (Get_Body_From_Stub): New function to
5255 return subprogram or package body from stub.
5256 (Is_Subprogram_Stub_Without_Prior_Declaration): New function to detect
5257 stubs without prior subprogram decl.
5258
52592011-08-29 Vasiliy Fofanov <fofanov@adacore.com>
5260
5261 * gnat_ugn.texi: Fix typo.
5262
e9c9d122
HK
52632011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5264
5265 * s-stposu.adb (Allocate_Any_Controlled): Reimplement the mechanism
5266 which accounts for size vs alignment issues and calculates the size of
5267 the list header.
5268 (Deallocate_Any_Controlled): Ditto.
5269 (Nearest_Multiple_Rounded_Up): New routine.
5270
25ebc085
AC
52712011-08-29 Tristan Gingold <gingold@adacore.com>
5272
5273 * a-exstat.adb (String_To_EO): Do no set Cleanup_Flag.
5274 * a-exexda.adb (Set_Exception_C_Msg): Ditto.
5275 (Set_Exception_Msg): Ditto.
5276 * a-exexpr-gcc.adb (Setup_Current_Excep): Ditto. Do not set
5277 Private_Data.
5278 * a-except.adb, a-except-2005.adb (Save_Occurrence_No_Private): Remove.
5279 Use Save_Occurrence instead of Save_Occurrence_No_Private.
5280 (Raise_With_Msg): Remove Cleanup_Flag.
5281 * a-except.ads, a-except-2005.ads (Exception_Occurrence): Remove
5282 Clean_Flag and Private_Data components.
5283
52842011-08-29 Yannick Moy <moy@adacore.com>
5285
5286 * freeze.adb (Freeze_Record_Type): Ignore packing in Alfa mode, like
5287 in CodePeer mode.
5288 * sem_ch3.adb (Signed_Integer_Type_Declaration): Correct the generation
5289 of an explicitly declared type, so that the base types of the original
5290 type and this generated type are the same, and a "type" (not a subtype
5291 like previously).
5292 * errout.adb (Special_Msg_Delete): Do not issue messages "Size too
5293 small" in Alfa mode, like in CodePeer mode.
5294 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore rep
5295 clauses in Alfa mode.
5296
52972011-08-29 Javier Miranda <miranda@adacore.com>
5298
5299 * exp_ch6.ads, exp_ch6.adb (Is_Null_Procedure): Move the spec of this
5300 function to the package spec.
5301 * sem_ch6.adb (Find_Corresponding_Spec, New_Overloaded_Entity): For
5302 internally generated bodies of null procedures locate the internally
5303 generated spec enforcing mode conformance.
5304 (Is_Interface_Conformant): Ensure that the controlling formal of the
5305 primitives match.
5306
53072011-08-29 Ed Schonberg <schonberg@adacore.com>
5308
5309 * sem_prag.adb (Analyze_Pragma, case Inline): In an instance, do not
5310 reject the pragma if it appears to apply to a formal subprogram.
5311
53122011-08-29 Ed Schonberg <schonberg@adacore.com>
5313
5314 * exp_ch4.adb (Expand_Allocator_Expression): Use consistent name for
5315 inner expression, to prevent double evaluation.
5316
590549fb
AC
53172011-08-29 Tristan Gingold <gingold@adacore.com>
5318
5319 * a-exexpr.adb (Propagate_Exception): Remove all the parameters as
5320 they were unused.
5321 * a-exexpr-gcc.adb (Propagate_Exception): Ditto.
5322 * a-except-2005.adb (Propagate_Exception): Adjust spec.
5323 (Raise_Current_Excep): Adjust call.
5324 (Raise_From_Signal_Handler): Call now simply call Raise_Current_Excep.
5325
53262011-08-29 Thomas Quinot <quinot@adacore.com>
5327
5328 * exp_disp.adb: Minor reformatting.
5329
62380e66
TG
53302011-08-29 Tristan Gingold <gingold@adacore.com>
5331
5332 * a-exexpr.adb (Setup_Exception): Removed.
5333 * a-exexpr-gcc.adb (Setup_Exception): Removed.
5334 * a-except.adb (Exception_Propagation): Removed.
5335 * a-except-2005.adb (Setup_Exception): Removed.
5336 (Reraise): Remove call to Setup_Exception.
5337 (Reraise_Occurrence): Ditto.
5338 (Reraise_Occurrence_Always): Ditto.
5339 (Reraise_Occurrence_No_Defer): Ditto.
5340 (Transfer_Occurrence): Ditto.
5341 * a-exexda.adb (Set_Exception_C_Msg): Remove call to Setup_Exception.
5342 (Set_Exception_Msg): Ditto.
5343
c95aa61c
AC
53442011-08-29 Robert Dewar <dewar@adacore.com>
5345
5346 * a-convec.adb, exp_disp.adb: Minor reformatting.
5347
53482011-08-29 Tristan Gingold <gingold@adacore.com>
5349
5350 * a-exexpr-gcc.adb (GNAT_GCC_Exception_Access): Set to convention C.
5351
624e1688
AC
53522011-08-29 Gary Dismukes <dismukes@adacore.com>
5353
5354 * exp_ch3.adb (Build_Record_Init_Proc.Build_Init_Procedure): Set
5355 Exception_Handlers to No_List instead of Empty_List in the case where
5356 there are no handlers.
5357
53582011-08-29 Tristan Gingold <gingold@adacore.com>
5359
5360 * gcc-interface/gigi.h (enum standard_datatypes): Add
5361 ADT_reraise_zcx_decl
5362 (reraise_zcx_decl): New macro.
5363 * gcc-interface/trans.c (gnu_incoming_exc_ptr): New variable.
5364 (gigi): Set reraise_zcx_decl.
5365 (Exception_Handler_to_gnu_zcx): Save and restore gnu_incoming_exc_ptr.
5366 (gnat_to_gnu): Handle N_Raise_Statement.
5367
7134062a
AC
53682011-08-29 Robert Dewar <dewar@adacore.com>
5369
5370 * sem_ch6.adb, exp_ch3.adb, s-stposu.adb, a-undesu.ads,
5371 a-undesu.adb: Minor reformatting.
5372
53732011-08-29 Ed Schonberg <schonberg@adacore.com>
5374
5375 * exp_disp.adb (Check_Premature_Freezing): When building a dispatch
5376 table, accept an unfrozen untagged component if it is an actual for a
5377 formal incomplete type.
5378 * a-convec.ads, a-convec.adb: Instantiate Ada.Iterator_Interfaces to
5379 provide new iterator forms over vectors.
5380 Introduce type Iterator in package body to implement operations of
5381 Reversible_Iterator interface.
5382 * a-iteint.ads: Make package pure so it is usable with new container
5383 packages, that are categorized Remote_Types.
5384
ca5af305
AC
53852011-08-29 Robert Dewar <dewar@adacore.com>
5386
5387 * a-exexpr-gcc.adb, a-synbar.adb, sem_ch13.adb: Minor reformatting.
5388
53892011-08-29 Bob Duff <duff@adacore.com>
5390
5391 * sem_aggr.adb (Resolve_Aggr_Expr): Call this routine even in the case
5392 of <>, because this is the routine that checks for dimensionality
5393 errors (for example, for a two-dimensional array, (others => <>) should
5394 be (others => (others => <>)).
5395
53962011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5397
5398 * impunit.adb: Add new run-time units.
5399 * freeze.adb, exp_ch7.ads, exp_ch7.adb, exp_util.ads, exp_util.adb,
5400 s-stposu.ads, s-stposu.adb: Code clean up.
5401 Handle protected class-wide or task class-wide types
5402 Handle C/C++/CIL/Java types.
5403 * s-spsufi.adb, s-spsufi.ads: New files.
5404
5accd7b6
AC
54052011-08-29 Yannick Moy <moy@adacore.com>
5406
5407 * sem_ch13.adb (Analyze_Aspect_Specifications): Reject test-case on
5408 library-level subprogram.
5409 * sem_prag.adb (Check_Test_Case): Stricter rules for test-case
5410 placement.
5411 (Analyze_Pragma): Change name "Normal" for "Nominal" in test-case
5412 component.
5413 * snames.ads-tmpl: Change name "Normal" for "Nominal" in test-case
5414 component.
5415 * gnat_rm.texi: Update doc for Test_Case pragma.
5416
54172011-08-29 Tristan Gingold <gingold@adacore.com>
5418
5419 * a-exexpr-gcc.adb (Unwind_Exception): Remove default value, made it
5420 convention C.
5421 (GCC_Exception_Access): New type.
5422 (Unwind_DeleteException): New imported procedure
5423 (Foreign_Exception): Import it.
5424 (GNAT_GCC_Exception): Simply have the occurrence inside.
5425 (To_GCC_Exception): New function.
5426 (To_GNAT_GCC_Exception): New function.
5427 (GNAT_GCC_Exception_Cleanup): New procedure..
5428 (Propagate_GCC_Exception): New procedure.
5429 (Reraise_GCC_Exception): New procedure.
5430 (Setup_Current_Excep): New procedure.
5431 (CleanupUnwind_Handler): Change type of UW_Exception parameter.
5432 (Unwind_RaiseException): Ditto.
5433 (Unwind_ForcedUnwind): Ditto.
5434 (Remove): Removed.
5435 (Begin_Handler): Change type of parameter.
5436 (End_Handler): Ditto. Now delete the exception if still present.
5437 (Setup_Key): Removed.
5438 (Is_Setup_And_Not_Propagated): Removed.
5439 (Set_Setup_And_Not_Propagated): Ditto.
5440 (Clear_Setup_And_Not_Propagated): Ditto.
5441 (Save_Occurrence_And_Private): Ditto.
5442 (EID_For): Add 'not null' constraint on parameter.
5443 (Setup_Exception): Does nothing.
5444 (Propagate_Exception): Simplified.
5445 * exp_ch11.adb (Expand_N_Raise_Statement): In back-end exception model,
5446 re-raise is not expanded anymore.
5447 * s-except.ads (Foreign_Exception): New exception - placeholder for
5448 non Ada exceptions.
5449 * raise-gcc.c (__gnat_setup_current_excep): Declare
5450 (CXX_EXCEPTION_CLASS): Define (not yet used)
5451 (GNAT_EXCEPTION_CLASS): Define.
5452 (is_handled_by): Handle foreign exceptions.
5453 (PERSONALITY_FUNCTION): Call __gnat_setup_current_excep.
5454
54552011-08-29 Jose Ruiz <ruiz@adacore.com>
5456
5457 * a-synbar.adb (Synchronous_Barrier): Some additional clarification.
5458
2ef48385
AC
54592011-08-29 Thomas Quinot <quinot@adacore.com>
5460
5461 * a-synbar-posix.adb: Minor reformatting.
5462
54632011-08-29 Jose Ruiz <ruiz@adacore.com>
5464
5465 * a-exetim-posix.adb, a-exetim-mingw.adb, a-exetim-mingw.ads,
5466 a-exetim-default.ads (Interrupt_Clocks_Supported,
5467 Separate_Interrupt_Clocks_Supported, Clock_For_Interrupts): Add these
5468 definitions to be compliant with AI-0171. The target systems do not
5469 support separate account for the execution time of interrupt handlers.
5470
54712011-08-29 Jose Ruiz <ruiz@adacore.com>
5472
5473 * a-synbar.adb (Wait): Change the order of evaluation of the conditions
5474 in the barrier to put first the easiest to evaluate (and the one which
5475 will be True more often). More efficient.
5476
54772011-08-29 Eric Botcazou <ebotcazou@adacore.com>
5478
5479 * s-atocou-x86.adb: Fix constraint in machine code insertion.
5480
54812011-08-29 Bob Duff <duff@adacore.com>
5482
5483 * aspects.ads, aspects.adb: Add new aspects for various pragmas and
5484 attributes that are now aspects, as specified by AI05-0229-1.
5485 * sem_ch13.adb (Analyze_Aspect_Specifications,
5486 Check_Aspect_At_Freeze_Point): Analyze the new aspects. Turn them into
5487 pragmas or attribute references, as appropriate.
5488
0db16b1e
AC
54892011-08-29 Robert Dewar <dewar@adacore.com>
5490
5491 * a-synbar.ads, a-synbar.adb, a-synbar-posix.adb,
5492 a-synbar-posix.ads: Minor reformatting.
5493
54942011-08-29 Yannick Moy <moy@adacore.com>
5495
5496 * snames.ads-tmpl: Add name Force.
5497
978ffe02
AC
54982011-08-29 Pascal Obry <obry@adacore.com>
5499
5500 * prj-nmsc.adb: Minor reformatting.
5501
55022011-08-29 Jose Ruiz <ruiz@adacore.com>
5503
5504 * a-exetim.ads (Interrupt_Clocks_Supported,
5505 Separate_Interrupt_Clocks_Supported, Clock_For_Interrupts): Add these
5506 definitions to be compliant with AI-0171.
5507
55082011-08-29 Robert Dewar <dewar@adacore.com>
5509
5510 * a-ngelfu.adb: Add comments.
5511
718f39dc
AC
55122011-08-29 Geert Bosch <bosch@adacore.com>
5513
5514 * a-ngelfu.adb (Tan): Do not raise Constraint_Error if the argument is
5515 the closest machine number to Pi / 2.0.
5516
55172011-08-29 Jose Ruiz <ruiz@adacore.com>
5518
5519 * impunit.adb (Non_Imp_File_Names_12): Add a-synbar for new Ada 2012
5520 package Ada.Synchronous_Barriers.
5521 * a-synbar.ads, a-synbar.adb, a-synbar-posix.ads, a-synbar-posix.adb:
5522 Add new specs and bodies for Ada.Synchronous_Barriers. There is a
5523 default implementation using protected objects and another one
5524 a-synbar-posix using POSIX barriers as the underlying support.
5525 * gcc-interface/Makefile.in (LIBGNAT_TARGET_PAIRS for Linux (x86,
5526 x86_64, ia64) and MIPS IRIX): Use the a-synbar-posix implementation of
5527 Ada.Synchronous_Barriers which uses POSIX barriers (more efficient).
5528 Clean up dependencies.
5529 * Makefile.rtl (GNATRTL_TASKING_OBJS): Add a-synbar.o
5530
ee2e3f6b
AC
55312011-08-29 Robert Dewar <dewar@adacore.com>
5532
5533 * sem_ch7.adb, make.adb, sem_res.adb, exp_intr.adb,
5534 exp_dist.adb: Minor code reorganization.
5535 Minor reformatting.
5536
55372011-08-29 Thomas Quinot <quinot@adacore.com>
5538
5539 * sem_cat.adb (Validate_RACW_Primitive): The return type of an RACW
5540 primitive operation must support external streaming if it is not a
5541 controlling access result.
5542
646e2823
AC
55432011-08-29 Thomas Quinot <quinot@adacore.com>
5544
5545 * sinfo.ads, sem_ch7.adb: Minor reformatting.
5546
55472011-08-29 Bob Duff <duff@adacore.com>
5548
5549 * sem_ch4.adb (Analyze_Allocator): Check No_Nested_Finalization
5550 restriction on allocators, as required by AI05-0013-1.
5551 * restrict.ads: Minor comment fix.
5552
5d59eef2
AC
55532011-08-29 Tristan Gingold <gingold@adacore.com>
5554
5555 * a-exexpr.adb, a-except-2005.ads (Jmpbuf_Address): Move to a-exexpr.adb
5556 (To_Jmpbuf_Address): Ditto
5557 (builtin_longjmp): Ditto
5558
55592011-08-29 Thomas Quinot <quinot@adacore.com>
5560
5561 * sem_res.adb: Minor reformatting.
5562
55632011-08-29 Vincent Celier <celier@adacore.com>
5564
5565 * make.adb (Gnatmake): Move special processing for VM targets after the
5566 call to Get_Target_Parameters.
5567
55682011-08-29 Thomas Quinot <quinot@adacore.com>
5569
5570 * sem_ch12.adb, par-ch12.adb: Minor reformatting.
5571
949a18cc
AC
55722011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5573
5574 * sem_res.adb (Resolve_Allocator): Implement Ada2012-B052. Detect cases
5575 where an anonymous access discriminant of a limited designated type
5576 appears in a non-immutably limited discriminated type and issue an
5577 error message. Add local variable Desig_T and replace all occurrences
5578 of Designated_Type.
5579
55802011-08-29 Jose Ruiz <ruiz@adacore.com>
5581
5582 * a-rttiev.adb (Set_Handler): Update comment to indicate that our
5583 implementation is compliant to RM D.15(15/2) after the modification
5584 imposed by AI05-0094-1 (binding interpretation).
5585
cb25faf8
AC
55862011-08-29 Robert Dewar <dewar@adacore.com>
5587
5588 * exp_ch9.adb, s-tasren.adb, exp_sel.adb, exp_sel.ads, exp_ch11.adb,
5589 s-interr-hwint.adb, s-tpobop.adb, sem_ch13.adb: Minor reformatting.
5590
55912011-08-29 Thomas Quinot <quinot@adacore.com>
5592
5593 * par-endh.adb (Check_End): For an END where it is mandatory to repeat
5594 the scope name, do not report a missing label as a style violation (it
5595 will be diagnosed as an illegality).
5596 * exp_dist.adb (Add_Params_For_Variant_Components): Fix handling of
5597 variant records: Get_Enum_Lit_From_Pos already returns a usage
5598 occurrence of the literal, no need to use New_Occurrence_Of. Set Etype
5599 on Expr in Integer_Literal case so that it can be used by
5600 Build_To_Any_Call.
5601
1d10f669
AC
56022011-08-29 Tristan Gingold <gingold@adacore.com>
5603
5604 * exp_sel.ads (Build_Abort_BLock_Handler): New function spec.
5605 Adjust comment.
5606 * exp_sel.adb (Build_Abort_Block): Use Build_Abort_Block_Handler.
5607 (Build_Abort_Block_Handler): New function to build an Abort_Signal
5608 exception handler.
5609 * exp_ch9.adb (Expand_N_Asynchronous_Select): Call
5610 Build_Abort_Block_Handler to build the exception handler. Do not
5611 undefer aborts for the Abort_Signal exception handler if back-end
5612 exception mechanism.
5613 * exp_ch11.adb (Expand_Exception_Handlers): Do not undefer aborts if
5614 back_end exceptions for all others and abort_signal.
5615 * s-except.ads (ZCX_By_Default): New constant.
5616 * a-except-2005.adb (Raise_Exception): Do not defer abort if ZCX.
5617 (Raise_Exception_Always): Ditto.
5618 (Raise_From_Signal_Handler): Ditto.
5619 (Raise_With_Location_And_Msg): Ditto.
5620 (Raise_With_Msg): Ditto.
5621 (Reraise): Ditto.
5622 (Reraise_Occurence): Ditto.
5623 (Reraise_Occurrence_Always): Ditto.
5624 * s-tasren.adb (Exceptional_Complete_Rendezvous): Defer aborts if ZCX.
5625 * s-tpobop.adb: (Exceptional_Complete_Body): Undefer abort if ZCX.
1d10f669
AC
5626
56272011-08-29 Thomas Quinot <quinot@adacore.com>
5628
5629 * sem_util.ads (Get_Enum_Lit_From_Pos): Clarify documentation.
5630
d986066d
AC
56312011-08-29 Robert Dewar <dewar@adacore.com>
5632
5633 * snames.adb-tmpl, sem_ch13.adb: Minor reformatting
5634 Minor code reorganization.
5635
56362011-08-29 Bob Duff <duff@adacore.com>
5637
5638 * usage.adb (-gnatwy): Fix documentation: this switch applies to Ada
5639 2012, not just Ada 2005.
5640
56412011-08-29 Vincent Celier <celier@adacore.com>
5642
5643 * gnat_ugn.texi: Indicate that when the compiler is called by gnatmake
5644 with a project file or with gprbuid, if -gnatep= is specified, the
5645 builder may need to be invoked with -x.
5646
56472011-08-29 Tristan Gingold <gingold@adacore.com>
5648
5649 * a-exexpr-gcc.adb: Minor comment fix.
5650
ff4f0ed0
AC
56512011-08-29 Robert Dewar <dewar@adacore.com>
5652
5653 * sem_ch8.adb: Minor reformatting.
5654
56552011-08-29 Bob Duff <duff@adacore.com>
5656
5657 * par-ch2.adb (P_Identifier): Warn that "some" is reserved in Ada 2012.
5658 * par-ch4.adb (P_Quantified_Expression): Remove unnecessary code for
5659 treating "some" as unreserved in earlier Ada versions. This is now
5660 handled in Snames.Is_Keyword_Name. Parse "for some" using Tok_Some,
5661 rather than Name_Some, since Tok_Some is now recognized as reserved.
5662 * scans.adb (Initialize_Ada_Keywords): Handle Tok_Some like any other
5663 reserved word.
5664 * scans.ads: Minor comment fixes.
5665 * snames.adb-tmpl (Is_Keyword_Name): Handle Ada 2012 reserved words as
5666 for other language versions.
5667 * scn.adb (Scan_Reserved_Identifier): Remove unnecessary code for
5668 treating "some" as unreserved in earlier Ada versions. This is now
5669 handled in Snames.Is_Keyword_Name.
5670 * par-ch3.adb (P_Defining_Identifier): Warn that "some" is reserved in
5671 Ada 2012.
5672 (P_Subtype_Mark_Resync): Remove unnecessary code for treating "some" as
5673 unreserved in earlier Ada versions. This is now handled in
5674 Snames.Is_Keyword_Name.
5675 * snames.ads-tmpl (Ada_2012_Reserved_Words): Handle Ada 2012 reserved
5676 words as for other language versions.
5677 * gnat_ugn.texi (-gnatwy): Fix documentation: this switch applies to
5678 Ada 2012, not just Ada 2005.
5679
d941cee6
AC
56802011-08-29 Ed Schonberg <schonberg@adacore.com>
5681
5682 * sem_ch13.adb: Additional semantic checks for aspects involved in
5683 iterators.
5684
56852011-08-29 Matthew Heaney <heaney@adacore.com>
5686
5687 * a-comutr.ads, a-comutr.adb, a-cimutr.ads, a-cimutr.adb,
5688 a-cbmutr.ads, a-cbmutr.adb (Find_In_Subtree): Remove superfluous
5689 Container parameter.
5690 (Ancestor_Find): ditto.
5691
b970af39
TQ
56922011-08-29 Thomas Quinot <quinot@adacore.com>
5693
5694 * par-endh.adb: Minor reformatting.
d941cee6 5695
92db5dee
AC
56962011-08-29 Tristan Gingold <gingold@adacore.com>
5697
5698 * a-exexpr-gcc.adb (Unwind_Action) Rewrite as an integer with constants.
5699 (GNAT_GCC_Exception): Remove N_Cleanups_To_Trigger component.
5700 (Adjust_N_CLeanups_For): Remove.
5701 (CleanupUnwind_Handler): Call Unhandled_Exception_Terminate when end of
5702 stack is reached.
5703 (Propgate_Exception): Adjust.
5704 * raise-gcc.c: Add a few static/const.
5705 (Adjust_N_Cleanups_For): Remove declaration.
5706 (PERSONALITY_FUNCTION): Remove code dealing with N_Cleanups_To_Trigger.
5707
57082011-08-29 Ed Schonberg <schonberg@adacore.com>
5709
5710 * sem_ch8.adb: Use type of function return when rewriting as object
5711 declaration.
5712
1378bf10
AC
57132011-08-29 Gary Dismukes <dismukes@adacore.com>
5714
5715 * sem_type.adb: Minor reformatting.
5716
57172011-08-29 Robert Dewar <dewar@adacore.com>
5718
5719 * makeutl.adb: Minor reformatting.
5720
57212011-08-29 Ed Schonberg <schonberg@adacore.com>
5722
5723 * sem_ch8.adb (Analyze_Object_Renaming): If the renamed object is a
5724 function call of a limited type, the expansion of the renaming is
5725 complicated by the presence of various temporaries and subtypes that
5726 capture constraints of the renamed object.
5727 Rewrite node as an object declaration, whose expansion is simpler.
5728 Given that the object is limited there is no copy involved and no
5729 performance hit.
5730
164e06c6
AC
57312011-08-29 Robert Dewar <dewar@adacore.com>
5732
5733 * exp_ch5.adb, sinfo.ads, make.adb, s-pooglo.adb, sem_ch12.adb,
5734 freeze.adb, sem_ch6.adb, par-ch12.adb: Minor reformatting.
5735
57362011-08-29 Tristan Gingold <gingold@adacore.com>
5737
5738 * system-darwin-x86.ads, system-linux-s390x.ads, system-linux-alpha.ads,
5739 system-tru64.ads, system-irix-n32.ads, system-vxworks-arm.ads,
5740 system-linux-hppa.ads, system-linux-s390.ads,
5741 system-solaris-sparcv9.ads, system-mingw.ads, system-linux-ia64.ads,
5742 system-vms_64.ads, system-vxworks-sparcv9.ads, system-linux-ppc.ads,
5743 system-aix64.ads, system-lynxos-ppc.ads, system-linux-sh4.ads,
5744 system-solaris-x86.ads, system-linux-x86_64.ads, system-linux-x86.ads,
5745 system-vxworks-ppc.ads, system-hpux.ads, system-darwin-ppc.ads,
5746 system-solaris-sparc.ads, system-lynxos-x86.ads,
5747 system-vxworks-m68k.ads, system-hpux-ia64.ads, system-irix-o32.ads,
5748 system-solaris-x86_64.ads, system-mingw-x86_64.ads,
5749 system-vxworks-mips.ads, system-linux-sparc.ads, system-vms-ia64.ads,
5750 system-freebsd-x86.ads, system-aix.ads, system-darwin-x86_64.ads,
7d266442 5751 system-vxworks-x86.ads: Remove GCC_ZCX_Support.
164e06c6
AC
5752 * s-taprop-posix.adb, s-taprop-irix.adb, s-taprop-vxworks.adb,
5753 s-taprop-tru64.adb, s-taprop-linux.adb, s-taprop-solaris.adb: Ditto.
5754 * opt.ads: Adjust comment.
5755 * targparm.ads, targparm.adb: Remove GCC_ZCX_Support_On_Target.
5756 * gnat1drv.adb: Do not check for GCC_ZCX_Support_On_Target.
5757 * system.ads: Move GCC_ZCX_Support to obsolete entries.
5758
57592011-08-29 Emmanuel Briot <briot@adacore.com>
5760
5761 * makeutl.adb (Do_Complete): Resolve symbolic links when a relative
5762 file name is specified on the gnatmake or gprbuild command line, and
5763 before we search for that file in the project.
5764
57652011-08-29 Ed Schonberg <schonberg@adacore.com>
5766
5767 * sem_type.adb (Within_Instance): New predicate in Collect_Interps,
5768 used to determine whether a possible interpretation for an overloadable
5769 entity is declared within the current instantiation and should be
5770 included in the candidate set.
5771
57722011-08-29 Vasiliy Fofanov <fofanov@adacore.com>
5773
5774 * gnat_rm.texi, gnat_ugn.texi: Clean ups.
5775
97216ca8
ES
57762011-08-29 Ed Schonberg <schonberg@adacore.com>
5777
5778 * sem_res.adb (Resolve_Actuals): Use base type to determine whether an
5779 access subtype is access_to_subprogram, when applying checks for
5780 RM 3.10.2 (27).
5781
d3cb4cc0
AC
57822011-08-29 Matthew Heaney <heaney@adacore.com>
5783
5784 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Splice_Subtree): Only check
5785 for sibling when common parent.
5786
57872011-08-29 Thomas Quinot <quinot@adacore.com>
5788
5789 * get_scos.adb: Literals of Pragma_Id are pragma names prefixed with
5790 "pragma_".
5791
57922011-08-29 Ed Schonberg <schonberg@adacore.com>
5793
5794 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Enable freeze actions
5795 for the return type when in ASIS mode.
5796
57972011-08-29 Vincent Celier <celier@adacore.com>
5798
5799 * make.adb (Gnatmake): Get the default search dirs, then the target
5800 parameters after getting the Builder switches, as the Builder switches
5801 may include --RTS= and that could change the default search dirs.
5802
58032011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5804
5805 * exp_ch7.adb (Make_Adjust_Call): Rewrite to mimic the structure of
5806 Make_Final_Call. Move the processing for class-wide types before the
5807 processing for derivations from [Limited_]Controlled.
5808 (Make_Final_Call): Move the processing for class-wide types before the
5809 processing for derivations from [Limited_]Controlled.
5810 * s-stposu.adb (Allocate_Any_Controlled): Correct the membership check.
5811 Add code to account for alignments larger than the list header. Add a
5812 comment illustrating the structure of the allocated object + padding +
5813 header.
5814 (Deallocate_Any_Controlled): Add code to account for alignments larger
5815 than the list header.
5816
58172011-08-29 Ed Schonberg <schonberg@adacore.com>
5818
5819 * sinfo.ads, sinfo.adb: New node kind
5820 N_Formal_Incomplete_Type_Definition, related flags.
5821 par-ch12.adb (P_Formal_Type_Declaration, G_Formal_Type_Definition):
5822 Parse formal incomplete types.
5823 * sem.adb (Analyze): Formal_Incomplete_Type_Definitions are handled in
5824 sem_ch12.
5825 * sem_ch7.adb (Analyze_Package_Specification, Unit_Requires_Body):
5826 Formal incomplete types do not need completion.
5827 * sem_ch12.adb (Analyze_Formal_Incomplete_Type,
5828 Validate_Incomplete_Type_Instance): New procedures to handle formal
5829 incomplete types.
5830 * freeze.adb (Freeze_Entity): Do not freeze the subtype of an actual
5831 that corresponds to a formal incomplete type.
5832 * sprint.adb: Handle formal incomplete type declarations.
5833 * exp_util.adb (Insert_Actions): An incomplete_type_definition is not
5834 an insertion point.
5835
d3f70b35
AC
58362011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5837
5838 * a-fihema.ads, a-fihema.adb: Unit removed.
5839 * a-undesu.ads, a-undesu.adb: New unit implementing
5840 Ada.Unchecked_Deallocate_Subpool.
5841 * einfo.adb: Remove Associated_Collection from the node usage.
5842 Add Finalization_Master to the node usage.
5843 (Associated_Collection): Removed.
5844 (Finalization_Master): New routine.
5845 (Set_Associated_Collection): Removed.
5846 (Set_Finalization_Master): New routine.
5847 (Write_Field23_Name): Remove Associated_Collection from the output. Add
5848 Finalization_Master to the output.
5849 * einfo.ads: Remove attribute Associated_Collection and its uses in
5850 entities.
5851 Add new attribute Finalization_Master along with its uses in entitites.
5852 (Associated_Collection): Removed along with its pragma import.
5853 (Finalization_Master): New routine along with a pragma import.
5854 (Set_Associated_Collection): Removed along with its pragma import.
5855 (Set_Finalization_Master): New routine along with a pragma import.
5856 * exp_ch3.adb (Expand_Freeze_Array_Type): Replace call to
5857 Build_Finalization_Collection with Build_Finalization_Master.
5858 (Expand_Freeze_Record_Type): Move the generation of Finalize_Address
5859 before the bodies of the predefined routines. Add comment explaining
5860 this. Replace call to Build_Finalization_Collection with
5861 Build_Finalization_Master.
5862 (Freeze_Type): Replace call to Build_Finalization_Collection with
5863 Build_Finalization_Master.
5864 (Make_Finalize_Address_Body): Comment reformatting.
5865 (Make_Predefined_Primitive_Specs): Code reformatting.
5866 (Stream_Operation_OK): Update comment mentioning finalization
5867 collections. Replace RE_Finalization_Collection with
5868 RE_Finalization_Master.
5869 * exp_ch4.adb (Complete_Controlled_Allocation): Replace call to
5870 Associated_Collection with Finalization_Master. Replace call to
5871 Build_Finalization_Collection with Build_Finalization_Master.
5872 (Expand_Allocator_Expression): Replace call to Associated_Collection
5873 with Finalization_Master. Replace call to Set_Associated_Collection with
5874 Set_Finalization_Master. Remove the generation of
5875 Set_Finalize_Address_Ptr.
5876 (Expand_N_Allocator): Replace call to Associated_Collection with
5877 Finalization_Master. Remove the generation of Set_Finalize_Address_Ptr.
5878 * exp_ch6.adb (Add_Collection_Actual_To_Build_In_Place_Call): Renamed to
5879 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Update the
5880 comment on usage. Replace call to Needs_BIP_Collection with
5881 Needs_BIP_Finalization_Master Remplace BIP_Collection with
5882 BIP_Finalization_Master. Update all comments which mention finalization
5883 collections. Replace Associated_Collection with
5884 Finalization_Master. Replace Build_Finalization_Collection with
5885 Build_Finalization_Master.
5886 (BIP_Formal_Suffix): Update BIP_Collection's case.
5887 (Build_Heap_Allocator): Update the related comment. Rename local
5888 variable Collect to Fin_Mas_Id and update its occurrences. Update
5889 comments which mention finalization collections. Replace
5890 Set_Associated_Collection with Set_Finalization_Master.
5891 (Expand_Call): Update the code which detects a special piece of library
5892 code for .NET/JVM.
5893 (Make_Build_In_Place_Call_In_Allocator): Replace the call to
5894 Add_Collection_Actual_To_Build_In_Place_Call with
5895 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Remove the code
5896 which generates a call to Make_Set_Finalize_Address_Ptr_Call.
5897 (Make_Build_In_Place_Call_In_Anonymous_Context): Replace call to
5898 Add_Collection_Actual_To_Build_In_Place_Call with
5899 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
5900 (Make_Build_In_Place_Call_In_Assignment): Replace call to
5901 Add_Collection_Actual_To_Build_In_Place_Call with
5902 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
5903 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
5904 * exp_ch6.ads: Rename BIP_Collection to BIP_Finalization_Master.
5905 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
5906 * exp_ch7.adb (Build_BIP_Cleanup_Stmts): Update comment on usage.
5907 Rename local variable Collect to Fin_Mas_Id and update its occurrences.
5908 Replace call to Set_Associated_Collection with Set_Finalization_Master.
5909 (Build_Finalization_Collection): Renamed to Build_Finalization_Master.
5910 Replace the call to Associated_Collection with Finalization_Master.
5911 Rename local variable Coll_Id to Fin_Mas_Id and update its occurrences.
5912 Update the way finalization master names are generated. Update the
5913 retrieval of the correct access type which will carry the pool and
5914 master attributes.
5915 (Make_Final_Call): Reimplement the way [Deep_]Finalize is retrieved.
5916 (Make_Finalize_Address_Body): Abstract types do not need
5917 Finalize_Address. Code reformatting.
5918 (Make_Finalize_Address_Stmts): Update comment on usage.
5919 (Make_Set_Finalize_Address_Ptr_Call): Removed.
5920 (Process_Declarations): Update comments.
5921 * exp_ch7.ads (Build_Finalization_Collection): Renamed to
5922 Build_Finalization_Master. Update associated comment.
5923 (Make_Set_Finalize_Address_Ptr_Call): Removed.
5924 * exp_ch13.adb: Update comments which mention finalization collections.
5925 (Expand_N_Free_Statement): Replace the call to Associated_Collection
5926 with Finalization_Master.
5927 * exp_util.adb (Build_Allocate_Deallocate_Proc): Reimplemented to
5928 create calls to routines Allocate_Any_Controlled and
5929 Deallocate_Any_Controlled.
5930 (Find_Finalize_Address): New routine.
5931 (Is_Allocate_Deallocate_Proc): Update the RTE entities used in the
5932 comparison.
5933 (Requires_Cleanup_Actions): Update the comment on freeze node
5934 inspection.
5935 * exp_util.ads: Remove comment on generated code for
5936 Build_Allocate_Deallocate_Proc. The code is now quite complex and it
5937 is better to simply look in the body.
5938 * freeze.adb (Freeze_All): Update the comment of finalization
5939 collections. Replace the call to Associated_Collection with
5940 Finalization_Master. Replace the call to Build_Finalization_Collection
5941 with Build_Finalization_Master.
5942 * impunit.adb: Add a-undesu and s-stposu to the list of units.
5943 * Makefile.rtl: Add files a-undesu, s-finmas and s-stposu. Remove file
5944 a-fihema.
5945 * rtsfind.adb (Get_Unit_Name): Remove the processing for children of
5946 Ada.Finalization. Add processing for children of System.Storage_Pools.
5947 * rtsfind.ads: Remove the naming of second level children of
5948 Ada.Finalization.
5949 Remove Ada_Finalization_Heap_Management from the list of units.
5950 Remove subtype Ada_Finalization_Child.
5951 Remove the following subprogram entities:
5952
5953 RE_Allocate
5954 RE_Deallocate
5955 RE_Finalization_Collection
5956 RE_Finalization_Collection_Ptr
5957 RE_Set_Finalize_Address_Ptr
5958
5959 Add the naming of second level children of System.Storage_Pools.
5960 Add System_Finalization_Masters and System_Storage_Pools_Subpools to
5961 the list of units.
5962 Add subtype System_Storage_Pools_Child.
5963 Add the following subprogram entities to System.Finalization_Masters:
5964
5965 RE_Finalization_Master
5966 RE_Finalization_Master_Ptr
5967
5968 Add the following subprogram entities to System.Storage_Pools.Subpools:
5969
5970 RE_Allocate_Any_Controlled
5971 RE_Deallocate_Any_Controlled
5972 RE_Root_Storage_Pool_With_Subpools
5973 RE_Root_Subpool
5974 RE_Subpool_Handle
5975
5976 Move the following subprogram entities from
5977 Ada.Finalization.Heap_Management to System.Finalization_Masters:
5978
5979 RE_Add_Offset_To_Address
5980 RE_Attach
5981 RE_Base_Pool
5982 RE_Detach
5983
5984 * sem_ch3.adb (Access_Type_Declaration): Replace the call to
5985 Set_Associated_Collection with Set_Finalization_Master.
5986 * sem_ch6.adb (Create_Extra_Formals): Update the way extra formal
5987 BIP_Finalization_Master is created.
5988 * s-finmas.adb: New unit System.Finalization_Masters.
5989 * s-finmas.ads: New unit System.Finalization_Masters.
5990 * s-stopoo.ads, s-stopoo.adb: Minor code reformatting.
5991 * s-stposu.ads, s-stposu.adb: New unit implementing
5992 System.Storage_Pools.Subpools.
5993
59942011-08-29 Bob Duff <duff@adacore.com>
5995
5996 * tbuild.adb: Add assertion.
5997
8c889ae4
AC
59982011-08-29 Thomas Quinot <quinot@adacore.com>
5999
6000 * s-pooglo.adb: Minor reformatting.
6001
60022011-08-29 Ed Schonberg <schonberg@adacore.com>
6003
6004 * exp_ch5.adb (Expand_N_Assignment_Statement): if the left-hand side is
6005 an indexed component of a packed array whose element type is a record
6006 with a representation clause different from that of the right-hand
6007 side, generate a temporary to minimuze the number of bit-field
6008 operations generated.
6009
60102011-08-29 Ed Schonberg <schonberg@adacore.com>
6011
6012 * exp_util.adb (Insert_Actions): Use clauses can be part of lists of
6013 declarations, and thus are likely insertion points for actions.
6014
60152011-08-29 Bob Duff <duff@adacore.com>
6016
6017 * einfo.ads: Minor comment fix.
6018
1a07a71a
AC
60192011-08-29 Robert Dewar <dewar@adacore.com>
6020
6021 * frontend.adb, gnat1drv.adb: Minor reformatting.
6022
60232011-08-29 Tristan Gingold <gingold@adacore.com>
6024
6025 * s-pooglo.adb (Allocate, Deallocate): Take into account the alignment.
6026 * a-fihema.adb (Allocate, Deallocate): Ditto. Possibly add padding
6027 space in front of the header.
6028
4bcd6411
JK
60292011-08-29 Johannes Kanig <kanig@adacore.com>
6030
6031 * frontend.adb (Frontend): Exit after creating Standard package when
6032 -gnatd.H is present.
6033 * gnat1drv.adb (Gnat1drv): Call Backend right away when -gnatd.H is
6034 present.
6035
f0f88eb6
RD
60362011-08-29 Robert Dewar <dewar@adacore.com>
6037
6038 * exp_ch9.adb, mlib-prj.adb, prj.adb, prj.ads, ttypes.ads, sem_ch4.adb,
6039 makeutl.adb, makeutl.ads, atree.ads, snames.adb-tmpl,
6040 snames.ads-tmpl: Minor reformatting.
6041
3e37be71
PG
60422011-08-29 Philippe Gil <gil@adacore.com>
6043
6044 * prj.adb (Reset_Units_In_Table): New procedure.
6045 Reset units to avoid access to freed memory.
6046
94fb7608
AC
60472011-08-29 Thomas Quinot <quinot@adacore.com>
6048
6049 * get_scos.adb: When reading a P statement SCO without a pragma name
6050 (from an older ALI file), ensure that the Pragma_Name component is set
6051 to Unknown_Pragma (not left uninitialized).
6052
60532011-08-29 Vincent Celier <celier@adacore.com>
6054
6055 * makeutl.adb (Get_Directories): New procedure moved from Buildgpr and
6056 modified to compute correctly the object path of a SAL project that is
6057 extending another library project.
6058 (Write_Path_File): New procedure.
6059 * makeutl.ads (Directories): New table moved from Buildgpr
6060 (Get_Directories): New procedure moved from Buildgpr
6061 (Write_Path_File): New procedure
6062 * mlib-prj.adb (Build_Library): Use Makeutl.Get_Directories to set the
6063 paths before binding SALs, instead of Set_Ada_Paths.
6064 * prj-env.adb (Set_Path_File_Var): Procedure has been moved to package
6065 Prj.
6066 * prj.adb (Set_Path_File_Var): New procedure moved from Prj.Env
6067 (Current_Source_Path_File_Of): New function
6068 (Set_Current_Object_Path_File_Of): New procedure
6069 (Current_Source_Object_File_Of): New function
6070 (Set_Current_Object_Path_File_Of): New procedure
6071 * prj.ads (Set_Path_File_Var): New procedure moved from Prj.Env
6072 (Current_Source_Path_File_Of): New function
6073 (Set_Current_Object_Path_File_Of): New procedure
6074 (Current_Source_Object_File_Of): New function
6075 (Set_Current_Object_Path_File_Of): New procedure
6076
60772011-08-29 Ed Schonberg <schonberg@adacore.com>
6078
6079 * exp_ch5.adb (Expand_N_Assignment_Statement): For an assignment to a
6080 packed entity, use a bit-field assignment only if there is no change of
6081 representation.
6082
c5ecd6b7
AC
60832011-08-29 Thomas Quinot <quinot@adacore.com>
6084
6085 * rtsfind.ads, exp_ch3.adb (In_Runtime): Minor code improvement, use
6086 Is_RTU instead of using Chars comparisons.
6087
60882011-08-29 Thomas Quinot <quinot@adacore.com>
6089
6090 * exp_strm.adb (Build_Mutable_Record_Read_Procedure): Do not create a
6091 temporary object if the actual is constrained, and the discriminants
6092 read from the stream don't match.
6093
60942011-08-29 Tristan Gingold <gingold@adacore.com>
6095
6096 * sem_attr.adb, exp_attr.adb: Add handling of
6097 Attribute_System_Allocator_Alignment
6098 * snames.ads-tmpl: Add Name_System_Allocator_Alignment and
6099 Attribute_System_Allocator_Alignment.
6100 * ttypes.ads, get_targ.ads: Add Get_System_Allocator_Alignment.
6101 * gcc-interface/targtyps.c, gcc-interface/utils2.c,
6102 gcc-interface/gigi.h: Renames get_target_default_allocator_alignment to
6103 get_target_system_allocator_alignment.
6104
61052011-08-29 Arnaud Charlet <charlet@adacore.com>
6106
6107 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
6108 dependencies.
6109
8abdac29
AC
61102011-08-29 Arnaud Charlet <charlet@adacore.com>
6111
6112 * exp_ch3.adb (In_Runtime): Fix typo.
6113
df170605
AC
61142011-08-29 Bob Duff <duff@adacore.com>
6115
6116 * sem_ch4.adb (Analyze_Allocator): Analyze the subpool specification.
6117
61182011-08-29 Ed Schonberg <schonberg@adacore.com>
6119
6120 * exp_ch3.adb (Expand_N_Object_Declaration): If the entity is tagged
6121 and a separate tag assignment is generated, ensure that the tag
6122 assignment is analyzed.
6123
864a4236
ES
61242011-08-29 Ed Schonberg <schonberg@adacore.com>
6125
6126 * atree.ads, atree.adb (Copy_Separate_List): New function that applies
6127 Copy_Separate_Tree to a list of nodes. Used to create disjoint copies
6128 of statement lists that may contain local declarations.
df170605
AC
6129 * exp_ch9.adb (Expand_N_Timed_Entry_Call): Use Copy_Separate_List to
6130 duplicate the triggering statements needed for the expansion of this
6131 construct, when the trigger is a dispatching call to a synchronized
6132 primitive.
864a4236 6133
7f394c1d
AC
61342011-08-29 Arnaud Charlet <charlet@adacore.com>
6135
6136 * gnat_rm.texi: Add doc for 'Elab_Subp_Body.
6137 * bindgen.adb: Add comments.
6138 * snames.adb-tmpl (Is_Attribute_Name): Only recognize 'Elab_Subp_Body
6139 in CodePeer mode.
6140
2c1a2cf3
RD
61412011-08-29 Robert Dewar <dewar@adacore.com>
6142
6143 * exp_attr.adb: Minor reformatting.
6144 Minor code reorganization and commenting.
6145 * par_sco.adb, checks.adb, sem_attr.adb, get_scos.adb: Minor
6146 reformatting.
6147
0bfc9a64
AC
61482011-08-29 Thomas Quinot <quinot@adacore.com>
6149
6150 * get_scos.adb: Ignore chaining indicators not currently supported
6151 by Ada.
6152
61532011-08-29 Arnaud Charlet <charlet@adacore.com>
6154
6155 * system.ads: Minor editing.
6156
61572011-08-29 Arnaud Charlet <charlet@adacore.com>
6158
6159 * bindgen.adb (Gen_Elab_Calls): Generate calls to subp'Elab_Subp_Body in
6160 CodePeer mode.
6161 * sem_attr.ads, sem_attr.adb, exp_Attr.adb, sem_ch6.adb: Add handling of
6162 Attribute_Elab_Subp_Body.
6163 * snames.ads-tmpl (Attribute_Elab_Subp_Body, Name_Elab_Subp_Body): New.
6164 * sem_util.adb: Update comments.
6165
828d4cf0
TQ
61662011-08-29 Thomas Quinot <quinot@adacore.com>
6167
6168 * par_sco.adb, scos.adb, scos.ads, put_scos.adb, get_scos.adb: Record
6169 pragma name for each SCO statement corresponding to a pragma.
6170
5cd7bb15
AC
61712011-08-29 Arnaud Charlet <charlet@adacore.com>
6172
6173 * opt.ads: Minor editing.
6174
61752011-08-29 Yannick Moy <moy@adacore.com>
6176
6177 * gnat1drv.adb (Adjust_Global_Switches): Remove options for ALFA mode
6178 that only made sense for CodePeer mode.
6179
61802011-08-29 Jose Ruiz <ruiz@adacore.com>
6181
6182 * targparm.ads (Support_64_Bit_Divides_On_Target): Remove this flag
6183 which is no longer used.
6184 * targparm.adb (S64, S64_Str, Get_Target_Parameters): Remove the
6185 handling of the 64-bit division check.
6186 * exp_ch4.adb (Expand_N_Op_Divide): Remove the check for 64-bit
6187 division available.
6188 * system*.ads (Support_64_Bit_Divides): Remove this flag which is no
6189 longer used.
6190
61912011-08-29 Thomas Quinot <quinot@adacore.com>
6192
6193 * get_scos.adb: Minor reformatting.
6194
25b589cb
AC
61952011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
6196
6197 * exp_util.adb (Process_Statements_For_Controlled_Objects): Whenever a
6198 statement list is wrapped in a block, the block is explicitly analyzed
6199 in order to properly redecorate the entities and create a servicing
6200 finalizer.
6201
62022011-08-29 Tristan Gingold <gingold@adacore.com>
6203
6204 * sinfo.ads, sinfo.adb (Zero_Cost_Handling): Remove.
6205 (Set_Zero_Cost_Handling): Remove.
6206
62072011-08-29 Thomas Quinot <quinot@adacore.com>
6208
6209 * par_sco.adb, scos.ads, put_scos.adb, get_scos.adb: Minor reformatting
6210
1197ddb1
AC
62112011-08-29 Geert Bosch <bosch@adacore.com>
6212
6213 * s-vaflop-vms-alpha.adb (Neg_F): Use subtraction instead of negation
6214 instruction, as the latter may produce -0.0, which is not a valid VAX
6215 F float number.
6216 (Neg_G): Likewise for VAX F float.
6217
62182011-08-29 Robert Dewar <dewar@adacore.com>
6219
6220 * exp_util.adb: Minor reformatting.
6221
62222011-08-29 Yannick Moy <moy@adacore.com>
6223
6224 * sem_ch3.adb: Minor comment update.
6225
62262011-08-29 Thomas Quinot <quinot@adacore.com>
6227
6228 * checks.adb (Apply_Type_Conversion_Checks): Use the Underlying_Type of
6229 the operand type.
6230
62312011-08-29 Thomas Quinot <quinot@adacore.com>
6232
6233 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not flush
6234 current statement sequence on a generic instantiation or a subprogram
6235 declaration.
6236
8f66cda7
AC
62372011-08-29 Robert Dewar <dewar@adacore.com>
6238
6239 * sem_type.adb, einfo.ads, freeze.adb, exp_ch4.adb, sem_ch13.adb:
6240 Minor reformatting.
6241
62422011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
6243
6244 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
6245 Correct the check which involves the freeze node of a controlled or
6246 access-to-controlled type.
6247
62482011-08-29 Geert Bosch <bosch@adacore.com>
6249
6250 * sem_warn.adb (Check_Code_Statement): Remove check for consecutive Asm
6251 statements.
6252 * s-vaflop-vms-alpha.adb: Remove bogus Volatile => True arguments from
6253 Asm statements.
6254
cf161d66
AC
62552011-08-29 Yannick Moy <moy@adacore.com>
6256
6257 * sem_ch3.adb (Array_Type_Declaration): Insert a subtype declaration
6258 for every index type and component type that is not a subtype_mark.
6259 (Process_Subtype): Set Etype of subtype.
6260
62612011-08-29 Robert Dewar <dewar@adacore.com>
6262
6263 * a-cbmutr.adb, a-cimutr.adb, a-comutr.adb, prj-nmsc.adb: Minor code
6264 reorganization. Minor reformatting.
6265
7cc83cd8
AC
62662011-08-29 Steve Baird <baird@adacore.com>
6267
6268 * exp_ch4.adb (Expand_N_Op_Expon): Suppress N_Op_Expon node expansion
6269 for CodePeer and ALFA modes.
6270
62712011-08-29 Ed Schonberg <schonberg@adacore.com>
6272
6273 * sem_type.adb (Collect_Interps): Within an instance, collect a homonym
6274 that comes from an enclosing scope if it is not the renaming of an
6275 actual, to handle properly a spurious ambiguity in an instance.
6276
76af4137
AC
62772011-08-29 Eric Botcazou <ebotcazou@adacore.com>
6278
6279 * sem_ch13.adb (Alignment_Check_For_Esize_Change): Rename to...
6280 (Alignment_Check_For_Size_Change): ...this. Add SIZE parameter and
6281 use it instead of the Esize of the first parameter.
6282 (Analyze_Attribute_Definition_Clause) <Object_Size>: Adjust call to
6283 above change.
6284 <Size>: Likewise. Call it for composite types on the RM size.
6285
62862011-08-29 Yannick Moy <moy@adacore.com>
6287
6288 * exp_ch4.adb (Expand_N_Op_Not): Do not expand not on array.
6289 * sem_util.adb (Unique_Name): Correct behaviour for names of
6290 compilation units.
6291
9b20e59b
AC
62922011-08-29 Yannick Moy <moy@adacore.com>
6293
6294 * sem_prag.adb (Check_Precondition_Postcondition): In formal
6295 verification mode, analyze pragma expression for correctness, for
6296 pre/post on library-level subprogram, as it is not expanded later.
6297
62982011-08-29 Yannick Moy <moy@adacore.com>
6299
6300 * exp_aggr.adb (Expand_Array_Aggregate): Do not expand array aggregates
6301 in formal verification.
6302
63032011-08-29 Thomas Quinot <quinot@adacore.com>
6304
6305 * sem_util.adb: Minor reformatting.
6306 * freeze.adb, sem_ch13.adb: Fix comment: Bit_Order is an attribute,
6307 there's no pragma.
6308 * par_sco.ads, par_sco.adb: Update comments.
6309
63102011-08-29 Yannick Moy <moy@adacore.com>
6311
6312 * einfo.adb, einfo.ads: Remove flag Is_Postcondition_Proc and
6313 associated getter/setter.
6314 * sem_ch6.adb: Remove reference to Is_Postcondition_Proc.
6315
63162011-08-29 Vincent Celier <celier@adacore.com>
6317
6318 * prj-attr.adb: New Compiler attribute Dependency_Kind and Language_Kind
6319 * prj-conf.adb: Add_Default_GNAT_Naming_Scheme: Add a package Compiler
6320 with declarations for Language_Kind and Dependency_Kind for Ada.
6321 * prj-nmsc.adb (Check_Unit_Name): New name of procedure Check_Ada_Name
6322 (Process_Compiler): Take into account the new attributes Dependency_Kind
6323 and Language_Kind.
6324 (Check_Configuration): Check if language kind is unit based, not if the
6325 language name is Ada.
6326 (Process_Exceptions_Unit_Based): Ditto
6327 (Add_Language): Remove default additions of language and dependency kind
6328 * prj.ads: Minor comment change
6329 * snames.ads-tmpl: New standard names Dependency_Kind and Language_Kind
6330
63312011-08-29 Johannes Kanig <kanig@adacore.com>
6332
6333 * debug.adb: Update comments.
6334
c5bc3df6
JM
63352011-08-24 Joseph Myers <joseph@codesourcery.com>
6336
6337 * gcc-interface/Make-lang.in (CFLAGS-ada/tracebak.o)
6338 (CFLAGS-ada/targext.o, CFLAGS-ada/cio.o, CFLAGS-ada/init.o)
6339 (CFLAGS-ada/initialize.o, CFLAGS-ada/raise.o): New.
6340 (ada/tracebak.o, ada/targext.o, ada/cio.o, ada/init.o)
6341 (ada/initialize.o, ada/raise.o): Remove explicit compilation rules.
6342
e3aa9eba
RO
63432011-08-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6344
6345 * gcc-interface/Makefile.in (PICFLAG_FOR_TARGET): New.
6346 (GNATLIBCFLAGS_FOR_C): Replace
6347 TARGET_LIBGCC2_CFLAGS by PICFLAG_FOR_TARGET.
6348 (gnatlib-shared-default, gnatlib-shared-dual-win32)
6349 (gnatlib-shared-win32, gnatlib-shared-darwin, gnatlib-shared)
6350 (gnatlib-sjlj, gnatlib-zcx): Likewise.
6351
f446d60e
EB
63522011-08-07 Eric Botcazou <ebotcazou@adacore.com>
6353
6354 * gcc-interface/Makefile.in (raise-gcc.o): Fix previous change.
6355
588c8f48
EB
6356 * gcc-interface/gigi.h (enumerate_modes): Fix formatting.
6357
6358 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Revert latest change.
6359
28d711bf
NR
63602011-08-05 Nicolas Roche <roche@adacore.com>
6361
6362 * gcc-interface/Makefile.in: Don't use directly ../xgcc to build shared
6363 libgnat. Use rather the value of GCC_FOR_TARGET. Fix issue with
6364 canadian cross.
6365 * gcc-interface/Make-lang.in: Add support for canadian cross setting.
6366
993f8920
AC
63672011-08-05 Matthew Heaney <heaney@adacore.com>
6368
6369 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Child_Count, Child_Depth):
6370 subprogram bodies declared out-of-order.
6371
63722011-08-05 Yannick Moy <moy@adacore.com>
6373
6374 * sem_util.adb (Unique_Name): only prefix with "standard" the names of
6375 entities directly in package Standard, otherwise skip the standard
6376 prefix.
6377
9b3956dd
RD
63782011-08-05 Robert Dewar <dewar@adacore.com>
6379
6380 * a-cbmutr.adb: Minor reformatting
6381 (Allocate_Node): refactor node allocation algorithm
6382
63832011-08-05 Robert Dewar <dewar@adacore.com>
6384
6385 * opt.ads, opt.adb (Debug_Pragmas_Disabled): New switch.
6386 * sem_prag.adb (Analyze_Pragma, case Debug_Policy): Implement Disable
6387 mode.
6388 (Analyze_Pragma, case Check_Policy): Ditto.
6389 * sem_prag.ads (Check_Disabled): New function
6390 * snames.ads-tmpl: Add Name_Disable.
6391
63922011-08-05 Robert Dewar <dewar@adacore.com>
6393
6394 * gnat_rm.texi: Document implementation-defined policy DISABLE for
6395 pragmas Assertion_Policy, Check_Policy, Debug_Policy.
6396
79e705d6
AC
63972011-08-05 Ed Schonberg <schonberg@adacore.com>
6398
6399 * sem_prag.adb (Analyze_Pragma, case Inline): reject an Inline pragma
6400 that appears in a generic formal part and applies to a formal
6401 subprogram.
6402
64032011-08-05 Robert Dewar <dewar@adacore.com>
6404
6405 * a-cbmutr.ads: Minor reformatting.
6406
23b6deca
AC
64072011-08-05 Matthew Heaney <heaney@adacore.com>
6408
6409 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Read): do not use T'Valid
6410 to check count, check sign of value instead.
6411 * a-comutr.adb, a-cimutr.adb (Write): return immediately if tree empty
6412 (Copy_Subtree): allocate copy of source element
6413 (Equal_Subtree): compare elements, not access objects
6414
64152011-08-05 Vincent Celier <celier@adacore.com>
6416
6417 * gnat_ugn.texi: Fix VMS alternative.
6418
a2773bd3
AC
64192011-08-05 Thomas Quinot <quinot@adacore.com>
6420
6421 * sem_ch11.adb: Add comment.
6422
64232011-08-05 Robert Dewar <dewar@adacore.com>
6424
6425 * exp_util.adb: Minor comment fix.
6426
64272011-08-05 Robert Dewar <dewar@adacore.com>
6428
6429 * scng.adb (Error_Unterminated_String): Improve flag position when
6430 comma present.
6431
64322011-08-05 Matthew Heaney <heaney@adacore.com>
6433
6434 * Makefile.rtl, impunit.adb: Added a-cbmutr.ad[sb] (bounded multiway
6435 tree containers).
6436 * a-cbmutr.ads, a-cbmutr.adb: This is the new Ada 2012 unit for bounded
6437 multiway tree containers.
6438
64392011-08-05 Robert Dewar <dewar@adacore.com>
6440
6441 * styleg.adb (Check_Comment): Implement comment spacing of 1 or 2
6442 * stylesw.adb: Implement -gnatyC to control comment spacing
6443 * stylesw.ads (Style_Check_Comments_Spacing): New switch (set by
6444 -gnatyc/C).
6445 * usage.adb: Add line for -gnatyC.
6446
64472011-08-05 Robert Dewar <dewar@adacore.com>
6448
f446d60e 6449 * gnat_ugn.texi: Document -gnatyC.
a2773bd3
AC
6450 * vms_data.ads: Implement COMMENTS1/COMMENTS2 (retaining COMMENTS as a
6451 synonym for COMMENTS2).
6452
dedac3eb
RD
64532011-08-05 Robert Dewar <dewar@adacore.com>
6454
6455 * par_sco.adb, sem_ch3.adb, scos.ads, a-iteint.ads, sem_ch12.adb,
6456 a-cimutr.adb, a-cimutr.ads, sem_util.ads, sem_res.adb, a-fihema.adb,
6457 sem_ch4.adb, lib-xref-alfa.adb, exp_disp.adb, a-comutr.adb,
6458 a-comutr.ads, lib-xref.adb: Minor reformatting.
6459
64602011-08-05 Robert Dewar <dewar@adacore.com>
6461
6462 * sem_ch11.adb (Analyze_Raise_Statement): Kill assignment to formal
6463 warning if there is an exception handler present.
6464
7c62a85a
AC
64652011-08-05 Pascal Obry <obry@adacore.com>
6466
6467 * a-iteint.ads: Fix copyright year.
6468
64692011-08-05 Thomas Quinot <quinot@adacore.com>
6470
6471 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not generate a
6472 statement SCO for a USE clause or a representation clause.
6473
64742011-08-05 Yannick Moy <moy@adacore.com>
6475
6476 * lib-xref-alfa.adb (Collect_ALFA): generate the proper relation
6477 between body and spec for stub.
6478 (Detect_And_Add_ALFA_Scope): take into account subprogram stub
6479 * lib-xref.adb (Enclosing_Subprogram_Or_Package): in the case of a
6480 pragma precondition or postcondition, for which the enclosing
6481 subprogram or package in the AST is not the desired one, return empty.
6482
e49208a9
AC
64832011-08-05 Thomas Quinot <quinot@adacore.com>
6484
6485 * g-expect.adb: Minor reformatting.
6486
64872011-08-05 Bob Duff <duff@adacore.com>
6488
6489 * a-fihema.adb: Comment out OS_Lib.
6490
64912011-08-05 Matthew Heaney <heaney@adacore.com>
6492
6493 * Makefile.rtl, impunit.adb: Added a-c[oi]mutr.ad[sb]
6494 (unbounded multiway tree containers) and a-iteint.ads.
6495 * a-comutr.ads, a-comutr.adb:
6496 This is the new Ada 2012 unit for unbounded multiway tree containers
6497 * a-cimutr.ads, a-cimutr.adb
6498 This is the new Ada 2012 unit for indefinite multiway tree containers
6499 * a-iteint.ads: New file.
6500
201cdb74
RO
65012011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6502
f446d60e 6503 * gcc-interface/Makefile.in (raise-gcc.o): Search $(srcdir)/../libgcc.
201cdb74 6504
d50f4827
AC
65052011-08-05 Bob Duff <duff@adacore.com>
6506
6507 * sinfo.ads, sinfo.adb (Subpool_Handle_Name): New attribute for
6508 subpools.
6509 * par-ch4.adb (P_Allocator): Parse new subpool specification syntax.
6510
65112011-08-05 Ed Schonberg <schonberg@adacore.com>
6512
6513 * sem_ch4.adb (Try_Container_Indexing): New procedure to implement the
6514 general indexing aspects of Ada2012. Called when analyzing indexed
6515 components when other interpretations fail.
6516 * sem_ch8.adb (Find_Direct_Name): check for implicit dereference only
6517 in an expression context where overloading is meaningful. This excludes
6518 the occurrence in an aspect specification (efficiency only).
6519 * sem_attr.adb (Analyze_Attribute): indicate that the attributes
6520 related to iterators can be set by an attribute specification, but
6521 cannot be queried.
6522 * sem_ch13.adb (Analyze_Aspect_Specifications): handle
6523 Constant_Indexing and Variable_Indexing.
6524 (Check_Indexing_Functions): New procedure to perform legality checks.
6525 Additional semantic checks at end of declarations.
6526
efe05dfc
AC
65272011-08-05 Sergey Rybin <rybin@adacore.com>
6528
6529 * tree_io.ads: Update ASIS_Version_Number because of the change of the
6530 order of calling Tree_Write/Tree_Read routines made for aspects.
6531
65322011-08-05 Bob Duff <duff@adacore.com>
6533
6534 * a-fihema.adb (Finalize): Fix race condition.
6535
5f9cdefe
AC
65362011-08-05 Yannick Moy <moy@adacore.com>
6537
6538 * sem_ch12.adb (Analyze_Package_Instantiation,
6539 Need_Subprogram_Instance_Body): do not generate instance bodies in ALFA
6540 mode.
6541
65422011-08-05 Ed Schonberg <schonberg@adacore.com>
6543
6544 * sem_type.adb (Specific_Type): in an instance, the type-specific
6545 operand of an equality check that involves null may have a private
6546 type. Use full view to determine legality of construct.
6547
822868aa
AC
65482011-08-05 Vincent Celier <celier@adacore.com>
6549
6550 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
6551 delete or close the file when the call to gnatmake was successful.
6552
65532011-08-05 Yannick Moy <moy@adacore.com>
6554
6555 * gnat1drv.adb (Adjust_Global_Switches): in ALFA mode, set
6556 Global_Discard_Names.
6557
65582011-08-05 Ed Schonberg <schonberg@adacore.com>
6559
6560 * sinfo.ads: comments on use of entity field for aspect specifications.
6561
65622011-08-05 Ed Schonberg <schonberg@adacore.com>
6563
6564 * sem_ch12.adb (Reset_Entity): If the entity field of the associated
6565 node is not itself an entity but a selected component, it is a
6566 rewritten parameterless call to an en enclosing synchronized operation,
6567 and this expansion will be performed again in the instance, so there is
6568 no global information to preserve.
6569
44a10091
AC
65702011-08-05 Javier Miranda <miranda@adacore.com>
6571
6572 * exp_disp.adb (Set_All_DT_Position): Cleanup code and improve support
6573 for renamings of predefined primitives.
6574 (In_Predef_Prims_DT): New subprogram.
6575
65762011-08-05 Ed Schonberg <schonberg@adacore.com>
6577
6578 * sem_util.adb, sem_util.ads (Check_Implicit_Dereference): If a
6579 possible interpretation of name is a reference type, add an
6580 interpretation that is the designated type of the reference
6581 discriminant of that type.
6582 * sem_res.adb (resolve): If the interpretation imposed by context is an
6583 implicit dereference, rewrite the node as the deference of the
6584 reference discriminant.
6585 * sem_ch3.adb (Analyze_Subtype_Declaration, Build_Derived_Record_Type,
6586 Build_Discriminated_Subtype): Inherit Has_Implicit_Dereference from
6587 parent type or base type.
6588 * sem_ch4.adb (Process_Indexed_Component,
6589 Process_Overloaded_Indexed_Component, Indicate_Name_And_Type,
6590 Analyze_Overloaded_Selected_Component, Analyze_Selected_Component):
6591 Check for implicit dereference.
6592 (List_Operand_Interps): Indicate when an implicit dereference is
6593 ambiguous.
6594 * sem_ch8.adb (Find_Direct_Name): Check for implicit dereference.
6595
65962011-08-05 Thomas Quinot <quinot@adacore.com>
6597
6598 * scos.ads: Update documentation of SCO table. Pragma statements can now
6599 be marked as disabled (using 'p' instead of 'P' as the statement kind).
6600 * par_sco.ads, par_sco.adb: Implement the above change.
6601 (Process_Decisions_Defer): Generate a P decision for the first parameter
6602 of a dyadic pragma Debug.
6603 * sem_prag.adb (Analyze_Pragma, case Debug): Mark pragma as enabled if
6604 necessary.
6605 * put_scos.adb: Code simplification based on above change.
6606
bb3c784c
AC
66072011-08-05 Robert Dewar <dewar@adacore.com>
6608
6609 * sem_ch3.adb, gnatcmd.adb, switch-c.adb, exp_attr.adb, make.adb,
6610 bindgen.adb, einfo.adb, sem_ch12.adb, sem_attr.adb, a-fihema.adb,
6611 a-fihema.ads, sem_elab.adb, sem_elab.ads, aspects.adb, opt.ads,
6612 prj-conf.adb, sem_ch13.adb, s-ficobl.ads: Minor reformatting
6613
66142011-08-05 Bob Duff <duff@adacore.com>
6615
6616 * a-stunau.ads, g-spipat.adb: Update comments.
6617
36f686f9
BD
66182011-08-05 Bob Duff <duff@adacore.com>
6619
6620 * a-fihema.ads: Minor comment fix.
6621 * a-fihema.adb (Allocate, Deallocate): Assert that the alignment is
6622 correct.
6623 (Attach, Detach): Remove some unnecessary code.
6624 (Finalize): Remove Node_Ptr_To_Address, replace with a constant.
6625
7882673f
BD
66262011-08-05 Bob Duff <duff@adacore.com>
6627
6628 * a-fihema.ads, a-fihema.adb (Finalization_Collection): Avoid heap
6629 allocation for Objects component. This simplifies the code somewhat. It
6630 is also a little more efficient in the not-so-unusual case where there
6631 are no controlled objects allocated.
6632 Make Finalization_Started flag atomic.
6633 (Finalize): Avoid unnecessary detachment of items from the list.
6634 (pcol): Minor cleanup.
6635
d34cd274
AC
66362011-08-05 Ed Schonberg <schonberg@adacore.com>
6637
6638 * sem_ch12.adb (Analyze_Formal_Package_Declaration): reject a formal
6639 package whose name is the same as that of the generic unit, or its
6640 ultimate prefix.
6641
66422011-08-05 Bob Duff <duff@adacore.com>
6643
6644 * a-fihema.adb, a-fihema.ads: Minor comment improvements.
6645 * sem_ch3.adb, exp_ch5.adb, exp_ch7.adb, exp_ch7.ads, exp_util.adb:
6646 Minor comment fixes.
6647
00332244
AC
66482011-08-05 Arnaud Charlet <charlet@adacore.com>
6649
6650 * make.adb (Linking_Phase): No longer need to set source search path
6651 before calling gnatlink in CodePeer mode.
6652 * gnatlink.adb (Gnatlink): No longer pass -gnat83/95/05/12 switch to
6653 gcc in CodePeer mode, since the binder generated file no longer has a
6654 'with Main'.
6655 * switch.ads, switch.adb (Is_Language_Switch): Removed.
6656 * switch-c.adb: Update comment.
6657
66582011-08-05 Thomas Quinot <quinot@adacore.com>
6659
6660 * exp_strm.adb, bindgen.adb, s-ficobl.ads: Minor reformatting.
6661
66622011-08-05 Nicolas Roche <roche@adacore.com>
6663
6664 * gnat_ugn.texi: Fix minor syntax error issue.
6665
66662011-08-05 Vincent Celier <celier@adacore.com>
6667
6668 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
6669 delete or close the file when the call to gnatmake returns a non
6670 successful return code.
6671
66722011-08-05 Ed Schonberg <schonberg@adacore.com>
6673
6674 * exp_ch4.adb (Expand_N_Type_Conversion): When expanding a predicate
6675 check, indicate that the copy of the original node does not come from
6676 source, to prevent an infinite recursion of the expansion.
6677
66782011-08-05 Johannes Kanig <kanig@adacore.com>
6679
6680 * debug.adb: document switch -gnatd.G for gnat2why, which deactivates
6681 VC generation for subprogram bodies.
6682
66832011-08-05 Yannick Moy <moy@adacore.com>
6684
6685 * einfo.ads: Typo.
6686 * sem_ch3.adb (Signed_Integer_Type_Declaration): in ALFA mode, define
6687 the base type with the smallest allowed base type.
6688
66892011-08-05 Sergey Rybin <rybin@adacore.com>
6690
6691 * tree_gen.adb, tree_in.adb, aspects.adb: Fix tree read-write for
6692 aspects.
6693
66942011-08-05 Ed Schonberg <schonberg@adacore.com>
6695
6696 * sem_ch12.ads: minor comment updates.
6697
66982011-08-05 Ed Schonberg <schonberg@adacore.com>
6699
6700 * sem_ch12.adb (Analyze_Formal_Package_Declaration): in an
6701 instantiation and a formal package the compiler generates a package
6702 renaming declaration so that the generic name within the declaration
6703 is interpreted as a renaming of the instance. At the end of a formal
6704 package declaration, this renaming must become invisible.
6705
0da80d7d
AC
67062011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
6707
6708 * exp_ch7.adb (Is_Init_Call): Reimplemented to avoid character
6709 comparison and rely on concrete entities instead.
6710
67112011-08-05 Ed Schonberg <schonberg@adacore.com>
6712
6713 * einfo.ads, einfo.adb (Has_Implicit_Dereference): new flag on types
6714 and discriminants, to indicate that the type has an access discriminant
6715 that supports implicit dereference.
6716 * snames.ads-tmpl: Add names of aspects and attributes related to
6717 Ada2012 iterators: constant_indexing, default_iterator,
6718 iterator_element, implicit_dereference, variable_indexing.
6719 * aspects.ads, aspects.adb: entries for iterator-related aspects.
6720 * sem_ch13.adb (Analyze_aspect_specifications): dummy entries for
6721 iterator-related aspects.
6722 * sem_attr.adb, exp_attr.adb Dummy entries for iterator-related aspects.
6723
67242011-08-05 Sergey Rybin <rybin@adacore.com>
6725
6726 * gnat_ugn.texi, vms_data.ads: Extend the subsection about coupling
6727 metrics in gnatmetric to cover new kinds of coupling mentrics.
6728
67292011-08-05 Steve Baird <baird@adacore.com>
6730
6731 * bindgen.adb (Gen_CodePeer_Wrapper): Call Ada_Main_Program instead
2c7f9cc0 6732 of calling the user-defined main subprogram.
0da80d7d
AC
6733 (Gen_Main): Declare Ada_Main_Program and (if CodePeer_Mode
6734 is set) Call_Main_Subprogram ahead of, as opposed to
6735 inside of, Main.
6736 (Gen_Output_File_Ada): Remove CodePeer_Mode-conditional
6737 generation of a "with" of the user-defined main subprogram.
6738 Remove CodePeer_Mode-conditional call to Gen_CodePeer_Wrapper
6739 (which is now called from Gen_Main instead).
6740
73242473
AC
67412011-08-05 Emmanuel Briot <briot@adacore.com>
6742
6743 * projects.texi: Added reference to the Makefile package.
6744
67452011-08-05 Thomas Quinot <quinot@adacore.com>
6746
6747 * exp_ch7.adb: Minor comment rewording.
6748
67492011-08-05 Ed Falis <falis@adacore.com>
6750
6751 * env.c: Fix comment.
6752
67532011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
6754
6755 * sem_elab.adb (Is_Finalization_Procedure): Reimplemented to avoid
6756 character comparison and rely on concrete entities instead.
6757
97ed5872
AC
67582011-08-05 Ed Schonberg <schonberg@adacore.com>
6759
6760 * sem_ch3.adb: (Check_Private_Overriding): better error message,
6761 suggested by AI95-0068.
6762
67632011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
6764
6765 * exp_ch7.adb (Find_Last_Init): Use Next_Suitable_Statement to retrieve
6766 the two potential initialization calls. This accounts for any
6767 access-before-elaboration checks which may precede the initialization
6768 calls.
6769 (Next_Suitable_Statement): New routine. Returns the next real statement
6770 after the input node while skipping generated checks.
6771 * sem_elab.adb (Check_A_Call): New formal parameter In_Init_Proc along
6772 with comment on usage.
6773 Do not generate Elaborate_All when the trigger is a finalization call
6774 coming from a type init proc.
6775 (Check_Elab_Call): Propagate the initialization procedure context to
6776 subsequent calls to Check_A_Call.
6777 (Check_Internal_Call_Continue): Propagate the initialization procedure
6778 context to subsequent calls to Check_Elab_Call.
6779 (Is_Finalization_Procedure): New routine. Returns True if the input
6780 entity denotes a [Deep_]Finalize routine.
6781 * sem_elab.ads (Check_Elab_Call): New formal parameter In_Init_Proc
6782 along with comment on usage.
6783
67842011-08-05 Vadim Godunko <godunko@adacore.com>
6785
6786 * s-atocou.ads: Add list of supported platforms.
6787
67882011-08-05 Yannick Moy <moy@adacore.com>
6789
6790 * sem_prag.adb, restrict.adb: Correct style for or'ing Boolean variables
6791
6792 * opt.ads (Disable_ALI_File): new Boolean flag
6793 * lib-writ.adb (Write_ALI): when Disable_ALI_File is set, do nothing
6794
67952011-08-05 Ed Falis <falis@adacore.com>
6796
6797 * env.c (__gnat_environ): Fix includes for RTPs and VTHREADS so that
6798 environ is properly defined.
6799
68002011-08-05 Vincent Celier <celier@adacore.com>
6801
6802 * make.adb (Compilation_Phase): Exit immediately when all objects have
6803 been found up to date, to avoid multiple exit messages.
6804 * prj-nmsc.adb (Add_Source): Allow duplicate source file names in the
6805 same project for languages with no compiler.
6806 * gnat_ugn.texi: Document compiler switch -gnateI and gnatmake switch
6807 -eI.
9aff36e9
RD
68082011-08-05 Robert Dewar <dewar@adacore.com>
6809
6810 * exp_ch7.ads, sem_type.adb, make.adb, sem_prag.adb, sem_util.adb,
6811 sem_util.ads, sem_attr.adb, restrict.ads, sem_ch6.adb, prj-conf.adb,
6812 prj-conf.ads, s-atocou.ads, s-atocou.adb, s-atocou-x86.adb,
6813 s-atocou-builtin.adb: Minor reformatting.
6814
406935b6
AC
68152011-08-05 Yannick Moy <moy@adacore.com>
6816
6817 * exp_ch7.adb (Establish_Transient_Scope): in formal verification mode,
6818 if the node to wrap is a pragma check, this node and enclosed
6819 expression are not expanded, so do not apply any transformations here.
6820 * exp_prag.adb (Expand_Pragma_Check): document the need to avoid
6821 introducing transient scopes.
6822
68232011-08-05 Jose Ruiz <ruiz@adacore.com>
6824
6825 * adaint.c (__gnat_set_writable, __gnat_set_readable,
6826 __gnat_set_executable, __gnat_set_non_writable, __gnat_set_non_readable,
6827 __gnat_copy_attribs): On VxWorks 6.x and later, the required chmod
6828 routine is available, so we use the default implementation of these
6829 functions.
6830 * s-os_lib.ads (Copy_File, Copy_Time_Stamps): Document that there is
6831 support for copying attributes on VxWorks 6.
6832
68332011-08-05 Yannick Moy <moy@adacore.com>
6834
6835 * debug.adb: Remove use of -gnatd.D.
6836 * gnat1drv.adb (Adjust_Global_Switches): adjust switches for ALFA mode
6837 * opt.ads: Simplify variables for ALFA mode, to keep one only
6838 * restrict.adb, sem_prag.adb: Adapt treatment done for CodePeer mode
6839 to ALFA mode.
6840
68412011-08-05 Vincent Celier <celier@adacore.com>
6842
6843 * prj-conf.adb (Do_Autoconf): Look also for --RTS in
6844 Builder'Default_Switches.
6845
68462011-08-05 Vincent Celier <celier@adacore.com>
6847
6848 * makeusg.adb: Add lines for --create-map-file switches.
6849
68502011-08-05 Ed Schonberg <schonberg@adacore.com>
6851
6852 * freeze.adb (Freeze_Entity): For a subprogram, if a type in the
6853 profile is incomplete and the full view is available, replace it with
6854 the full view.
6855 * sem_ch6.adb (Possible_Freeze): if a type in the profile is
6856 incomplete, freezing the subprogram is delayed until the full view is
6857 frozen.
6858 * sem_type.adb (Disambiguate): an ambiguity between a user-defined
6859 fixed-point multiplication operator and the predefined operator is
6860 resolved in favor of the user-defined one.
6861
96c891b3
RO
68622011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6863
6864 * init.c [__alpha__ && __osf__] (__gnat_error_handler): Use
6865 CONST_CAST.
6866
276e7ed0
AC
68672011-08-04 Ed Schonberg <schonberg@adacore.com>
6868
6869 * sem_util.ads, sem_unit.adb (Type_Without_Stream_Operation): determine
6870 whether a type lacks user-defined Read or Write operations, or has a
6871 component that lacks them.
6872 * sem_attr.adb (Check_Stream_Attribute): if restriction
6873 No_Default_Stream_Attributes is active, verify that all subcomponent
6874 types of the target have user-defined stream operations, and report
6875 error otherwise.
6876 * exp_ch3.adb (Stream_Operqtion_OK): use Type_Without_Stream_Operation.
6877 * exp_strm.adb: Build_Elementary_Input_Call,
6878 Build_Elementary_Write_Call): remove checks for restriction
6879 No_Default_Stream_Attributes, now checked in semantics.
6880
68812011-08-04 Vincent Celier <celier@adacore.com>
6882
6883 * prj-conf.ads, prj-conf.adb (Do_Autoconf): If there is no --RTS
6884 switches on the command line, look for all valid --RTS switches in the
6885 Builder switches and for each language use the first runtime name found
6886 to invoke gprconfig.
6887 (Get_Or_Create_Configuration_File): Warn if --RTS is specified on the
6888 command line and there is no auto-configuration.
6889 (Runtime_Name_Set_For): New function.
6890
68912011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6892
6893 * exp_ch7.adb (Build_Object_Declarations): Do not generate the
6894 elaborate initialization expression for variable Abort when processing
6895 a package body or a declaration.
6896 (Create_Finalizer): Propagate the package context when creating the
6897 exception-related variables.
6898 * exp_ch7.ads (Build_Object_Declarations): New formal parameter
6899 For_Package along with usage comment.
6900
19172ae9
AC
69012011-08-04 Arnaud Charlet <charlet@adacore.com>
6902
6903 * gcc-interface/Makefile.in: Clean up targets.
6904 Enable new package for atomic counters and copy-on-write implementation
6905 of unbounded strings on x86 platforms.
6906 * gcc-interface/Make-lang.in: Update dependencies.
6907
0319cacc
AC
69082011-08-04 Robert Dewar <dewar@adacore.com>
6909
6910 * exp_ch7.adb: Minor reformatting.
6911
69122011-08-04 Robert Dewar <dewar@adacore.com>
6913
6914 * exp_strm.adb: Minor reformatting.
6915
69162011-08-04 Vadim Godunko <godunko@adacore.com>
6917
6918 * s-atocou.adb: Replace by dummy version and use on targets where atomic
6919 operations are not supported.
6920 * s-atocou-builtin.adb: Renamed from s-atocou.adb.
6921 * s-atocou-x86.adb: New file.
6922 * Makefile.rtl: Add s-atocou.o file
6923
69242011-08-04 Arnaud Charlet <charlet@adacore.com>
6925
6926 * make.adb (Compile): Move setting of CodePeer_Mode to ...
6927 (Compilation_Phase): ... here.
6928 (Scan_Make_Arg): Now bind and link by default in CodePeer mode.
6929
69302011-08-04 Thomas Quinot <quinot@adacore.com>
6931
6932 * Make-generated.in: Fix minor typo in comment.
6933
26e7e1a0
AC
69342011-08-04 Thomas Quinot <quinot@adacore.com>
6935
6936 * gnatls.adb: Use Prj.Env.Initialize_Default_Project_Path to retrieve
6937 the project path.
6938
69392011-08-04 Robert Dewar <dewar@adacore.com>
6940
6941 * a-coinho.adb: Minor reformatting.
6942
69432011-08-04 Robert Dewar <dewar@adacore.com>
6944
6945 * a-coinho.ads: Minor reformatting.
6946
69472011-08-04 Vadim Godunko <godunko@adacore.com>
6948
6949 * s-atocou.ads, s-atocou.adb: New files.
6950 * a-strunb-shared.ads, a-strunb-shared.adb, a-stwiun-shared.ads,
6951 a-stwiun-shared.adb, a-stzunb-shared.ads, a-stzunb-shared.adb: Remove
6952 direct use of GCC's atomic builtins and replace them by use of new
6953 atomic counter package.
6954
69552011-08-04 Ed Schonberg <schonberg@adacore.com>
6956
6957 * exp_strm.adb: better error message for No_Default_Stream_Attributes.
6958
69592011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6960
6961 * a-tags.adb (Unregister_Tag): Replace the complex address arithmetic
6962 with a call to Get_External_Tag.
6963 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on
6964 subprogram usage. Remove the guard against package declarations and
6965 bodies since Build_Cleanup_Statements is no longer invoked in that
6966 context.
6967 (Build_Components): Initialize Tagged_Type_Stmts when the context
6968 contains at least one library-level tagged type.
6969 (Build_Finalizer): New local variables Has_Tagged_Types and
6970 Tagged_Type_Stmts along with associated comments on usage. Update the
6971 logic to include tagged type processing.
6972 (Create_Finalizer): Insert all library-level tagged type unregistration
6973 code before the jump block circuitry.
6974 (Expand_N_Package_Body): Remove the call to Build_Cleanup_Statements.
6975 (Expand_N_Package_Declaration): Remove the call to
6976 Build_Cleanup_Statements.
6977 (Process_Tagged_Type_Declaration): New routine. Generate a call to
6978 unregister the external tag of a tagged type.
6979 (Processing_Actions): Reimplemented to handle tagged types.
6980 (Process_Declarations): Detect the declaration of a library-level
6981 tagged type and carry out the appropriate actions.
6982 (Unregister_Tagged_Types): Removed. The machinery has been directly
6983 merged with Build_Finalizer.
6984
7483c888
AC
69852011-08-04 Robert Dewar <dewar@adacore.com>
6986
6987 * bindgen.ads, gnatlink.adb, sem_ch4.adb, gnatbind.adb, put_alfa.adb,
6988 gnatls.adb, exp_ch3.adb: Minor reformatting.
6989
69902011-08-04 Marc Sango <sango@adacore.com>
6991
6992 * sem_attr.adb (Analyze_Attribute): Replace the message
6993 "invisible attribute of}" of the spark restriction violation in
6994 attribute reference by the simple message "invisible attribute of type".
6995 Indeed, the node value Error_Msg_Node_1 used is in conflit with the
6996 two insertion characters: '&' and '}'.
6997
69982011-08-04 Vadim Godunko <godunko@adacore.com>
6999
7000 * impunit.adb (Non_Imp_File_Names_12): Add "a-coinho".
7001 * a-coinho.ads, a-coinho.adb: New file.
7002 * Makefile.rtl: Add Ada.Containers.Indefinite_Holders.
7003
5207696c
AC
70042011-08-04 Nicolas Roche <roche@adacore.com>
7005
7006 * alfa_test.adb: Not all ali files are containing alfa information even
7007 if compiled with -gnatd.F. So suppress warning about missing ALFA
7008 information.
7009
70102011-08-04 Yannick Moy <moy@adacore.com>
7011
7012 * lib-xref-alfa.adb (Add_ALFA_Scope): use non-empty unique name for
7013 scope.
7014 * put_alfa.adb: Check that scope name is not empty.
7015
70162011-08-04 Ed Schonberg <schonberg@adacore.com>
7017
7018 * exp_ch3.adb (Stream_Operation_Ok): new predicate
7019 Needs_Elementary_Stream_Operation, to determine whether user-defined
7020 Read and Write attributes are available for the elementary components
7021 of the given type. If only the predefined attributes are available,
7022 then when restriction No_Default_Stream_Attributes is active the
7023 predefined stream attributes for the composite type cannot be created.
7024
70252011-08-04 Robert Dewar <dewar@adacore.com>
7026
7027 * bindgen.adb: Fix obsolete comments and names from Ada/C days.
7028 Put routines in alpha order
7029
2bd2d858
JR
70302011-08-04 Jose Ruiz <ruiz@adacore.com>
7031
7032 * gcc-interface/Makefile.in: Remove xenomai specific versions of system.
7033 * gcc-interface/Make-lang.in: Update dependencies.
7034
8fae6016
AC
70352011-08-04 Arnaud Charlet <charlet@adacore.com>
7036
7037 * gcc-interface/lang.opt: Add AdaWhy language, simimlar to Ada.
7038 * gcc-interface/lang-specs.h: Add handling of AdaWhy specs (calls
7039 gnat1why).
7040
a54d0eb4
AC
70412011-08-04 Robert Dewar <dewar@adacore.com>
7042
7043 * sem_ch3.adb, make.adb, a-cohata.ads, sem_prag.adb, makeutl.adb,
7044 lib-xref-alfa.adb: Minor reformatting.
7045
70462011-08-04 Marc Sango <sango@adacore.com>
7047
7048 * sem_ch12.adb (Analyze_Generic_Package_Declaration,
7049 Analyze_Generic_Subprogram_Declaration, Analyze_Package_Instantiation,
7050 Analyze_Subprogram_Instantiation): Check absence of generic in SPARK
7051 mode.
7052
70532011-08-04 Tristan Gingold <gingold@adacore.com>
7054
7055 * bindgen.adb (Gen_Adainit_C): Remove.
7056 (Gen_Adafinal_C): Ditto.
7057 (Gen_Elab_Externals_C): Ditto.
7058 (Gen_Elab_Calls_C): Ditto.
7059 (Gen_Elab_Order_C): Ditto.
7060 (Gen_Elab_Defs_C): Ditto.
7061 (Gen_Finalize_Library_C): Ditto.
7062 (Gen_Finalize_Library_Defs_C): Ditto.
7063 (Gen_Main_C): Ditto.
7064 (Gen_Output_File_C): Ditto.
7065 (Gen_Restrictions_C): Ditto.
7066 (Gen_Versions_C): Ditto.
7067 (Write_Info_Ada_C): Ditto.
7068 (Gen_Object_Files_Options): Call WBI instead of Write_Info_Ada_C
7069 (Gen_Output_File): Do not force Ada_Bind_File anymore.
7070 Always call Gen_Output_File_Ada.
7071 * gnatlink.adb (Begin_Info): Now a constant.
7072 (End_Info): Ditto.
7073 (Ada_Bind_File): Remove
7074 (Process_Args): Do not handle -A/-C. Remove not Ada_Bind_File cases.
7075 * switch-b.adb (Scan_Binder_Switches): Do not handle -C.
7076 * gnatbind.adb (Gnatbind): Remove not Ada_Bind_File cases.
7077 * opt.ads (Ada_Bind_File): Remove.
7078
70792011-08-04 Thomas Quinot <quinot@adacore.com>
7080
7081 * projects.texi: Document target-specific directory in default project
7082 path for gnatmake.
7083
70842011-08-04 Thomas Quinot <quinot@adacore.com>
7085
7086 * gnatls.adb, prj-env.adb: Add $prefix/share/gpr to default project
7087 path in all cases .
7088
24558db8
AC
70892011-08-04 Yannick Moy <moy@adacore.com>
7090
7091 * sem_ch3.adb, sem_ch5.adb, sem_util.adb, sem_ch4.adb, sem_ch8.adb,
7092 opt.ads, lib-xref.ads: Code clean up.
7093
70942011-08-04 Yannick Moy <moy@adacore.com>
7095
7096 * gnat_rm.texi: Update description of Test_Case
7097 * gnat_ugn.texi: Typo.
7098
70992011-08-04 Ed Falis <falis@adacore.com>
7100
7101 * adaint.c (__gnat_get_number_of_cpus): fix typo in last checkin.
7102
71032011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7104
7105 * exp_ch4.adb (Suitable_Element): Skip field _parent on .NET/JVM when
7106 it is of type Root_Controlled. This action eliminates fields Prev and
7107 Next from type equality.
7108
71092011-08-04 Yannick Moy <moy@adacore.com>
7110
7111 * lib-xref-alfa.adb: Correct typo.
7112
71132011-08-04 Matthew Heaney <heaney@adacore.com>
7114
7115 * a-cohata.ads (Hash_Table_Type): default-initialize the Nodes
7116 component.
7117
1f9939b5
AC
71182011-08-04 Yannick Moy <moy@adacore.com>
7119
7120 * sem_prag.adb (Check_Arg_Is_String_Literal): remove useless procedure
7121 (Analyze_Pragma): allow static string expression for name of Test_Case,
7122 instead of simply string literals.
7123 * sem_util.adb (Get_Name_From_Test_Case_Pragma): adapt to static string
7124 expressions.
7125
71262011-08-04 Vincent Celier <celier@adacore.com>
7127
7128 * makeutl.adb (Complete_Mains.Find_File_Add_Extension): Use canonical
7129 case suffixes to find truncated main sources.
7130
71312011-08-04 Tristan Gingold <gingold@adacore.com>
7132
7133 * impunit.adb (Non_Imp_File_Names_95): Add g-tastus.
7134 s-stusta.adb (Compute_All_Task): Use Put_Line instead of Put.
7135 (Compute_Current_Task): Ditto.
7136
71372011-08-04 Tristan Gingold <gingold@adacore.com>
7138
7139 * gnat_ugn.texi: Mention GNAT.Task_Stack_Usage.
7140
71412011-08-04 Yannick Moy <moy@adacore.com>
7142
7143 * lib-xref-alfa.adb (Is_Global_Constant): new function that detects
7144 library-level constant.
7145 (Add_ALFA_Xrefs): ignore global constants in ALFA xref.
7146 * sem_res.adb (Resolve_Actuals): do not add cross-reference to Formal
7147 used as selector of parameter association, in ALFA mode.
7148
15d8a51d
AC
71492011-08-04 Robert Dewar <dewar@adacore.com>
7150
7151 * exp_ch5.adb, exp_ch7.adb, exp_util.adb, bindgen.adb, sem_prag.adb,
7152 s-tassta.adb, exp_ch4.adb, exp_disp.adb, s-stausa.adb: Minor
7153 reformatting.
7154
71552011-08-04 Arnaud Charlet <charlet@adacore.com>
7156
7157 * make.adb (Linking_Phase): Set source search path before calling
7158 gnatlink in CodePeer mode.
7159
f46faa08
AC
71602011-08-04 Javier Miranda <miranda@adacore.com>
7161
7162 * exp_ch7.adb (Expand_N_Package_Body, Expand_N_Package_Declaration):
7163 Remove code which takes care of building TSDs.
7164 * rtsfind.ads (RE_Check_Interface_Conversion): New entity.
7165 * exp_ch4.adb (Apply_Accessibility_Check): Add support for generating
7166 the accessibility check in VM targets.
7167 * exp_disp.adb (Make_VM_TSD): Spec moved to exp_disp.ads
7168 (Building_Static_DT): Now returns false for VM targets.
7169 (Build_VM_TSDs): Removed.
7170 (Expand_Interface_Conversion): Generate missing runtime check for
7171 conversions to interface types whose target type is unknown at compile
7172 time.
7173 (Make_VM_TSD): Add missing code to disable the generation of calls to
7174 Check_TSD if the tagged type is not defined at library level, or not
7175 has a representation clause specifying its external tag, or -gnatdQ is
7176 active.
7177 * exp_disp.ads (Build_VM_TSDs): Removed.
7178 (Make_VM_TSDs): Spec relocated from exp_disp.adb
7179 * sem_disp.adb (Check_Dispatching_Operation): No code required to
7180 register primitives in the dispatch tables in VM targets.
7181 * exp_ch3.adb (Expand_N_Object_Declaration): Remove wrong expansion of
7182 initialization of class-wide interface objects in VM targets.
7183 (Expand_Freeze_Record_Type): For VM targets call Make_VM_TSD (instead
7184 of Make_DT).
7185
71862011-08-04 Jerome Lambourg <lambourg@adacore.com>
7187
7188 * gnatlink.adb (Gnatlink): Correct missleading error message displayed
7189 when dotnet-ld cannot be found.
7190
71912011-08-04 Arnaud Charlet <charlet@adacore.com>
7192
7193 * bindgen.adb: Simplify significantly generation of binder body file in
7194 CodePeer mode.
7195 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Prevent assert failure
7196 when compiling binder generated file in CodePeer mode (xxx'Elab_Spec
7197 not expanded).
7198
2ba7e31e
AC
71992011-08-04 Yannick Moy <moy@adacore.com>
7200
7201 * sem_prag.adb, sem.ads: Code cleanup.
7202
72032011-08-04 Tristan Gingold <gingold@adacore.com>
7204
7205 * s-tassta.adb (Task_Wrapper): Rewrite the dynamic stack usage part.
7206 * s-stausa.adb, s-stausa.ads: Major rewrite. Now provides accurate
7207 results if possible.
7208 * s-stusta.adb (Print): Adjust after changes in s-stausa.
7209 * gnat_ugn.texi: Update dynamic stack usage section.
7210
72112011-08-04 Steve Baird <baird@adacore.com>
7212
7213 * bindgen.adb (Gen_CodePeer_Wrapper): new procedure.
7214 Generate (if CodePeer_Mode is set) a "wrapper" subprogram which
7215 contains only a call to the user-defined main subprogram.
7216 (Gen_Main_Ada) - If CodePeer_Mode is set, then
7217 call the "wrapper" subprogram instead of directly
7218 calling the user-defined main subprogram.
7219
72202011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7221
7222 * exp_ch5.adb (Expand_N_Case_Statement): Check the statements of all
7223 alternatives of a case statement for controlled objects. Rename local
7224 variable A to Dead_Alt.
7225 (Expand_N_If_Statement): Check the then and else statements of an if
7226 statement for controlled objects. Check the then statements of all
7227 elsif parts of an if statement for controlled objects.
7228 (Expand_N_Loop_Statement): Check the statements of a loop for controlled
7229 objects.
7230 * exp_ch7.adb (Process_Transient_Objects): Rewrite the condition which
7231 detects a loop associated with the expansion of an array object.
7232 Augment the processing of the loop statements to account for a possible
7233 wrap done by Process_Statements_For_Controlled_Objects.
7234 * exp_ch9.adb (Expand_N_Asynchronous_Select): Check the triggering
7235 statements and abortable part of an asynchronous select for controlled
7236 objects.
7237 (Expand_N_Conditional_Entry_Call): Check the else statements of a
7238 conditional entry call for controlled objects.
7239 (Expand_N_Selective_Accept): Check the alternatives of a selective
7240 accept for controlled objects.
7241 (Expand_N_Timed_Entry_Call): Check the entry call and delay
7242 alternatives of a timed entry call for controlled objects.
7243 * exp_ch11.adb (Expand_Exception_Handlers): Check the statements of an
7244 exception handler for controlled objects.
7245 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
7246 Add formal parameter Nested_Constructs along with its associated
7247 comment.
7248 (Requires_Cleanup_Actions (Node_Id)): Update all calls to
7249 Requires_Cleanup_Actions.
7250 (Process_Statements_For_Controlled_Objects): New routine.
7251 * exp_util.ads (Process_Statements_For_Controlled_Objects): New
7252 routine. Inspect a node which contains a non-handled sequence of
7253 statements for controlled objects. If such an object is found, the
7254 statements are wrapped in a block.
7255
1bf773bb
AC
72562011-08-04 Bob Duff <duff@adacore.com>
7257
7258 * sem_type.adb (Covers): If T2 is a subtype of a class-wide type, we
7259 need to compare with Class_Wide_Type (T2), in order to get at the
7260 original class-wide type node.
7261 * sem_type.ads (Covers): Improve the comment.
7262 * einfo.ads (Class_Wide_Type): Improve the comment.
7263 * exp_intr.adb (Expand_Unc_Deallocation): Remove unnecessary setting of
7264 the type of the Deref.
7265
72662011-08-04 Yannick Moy <moy@adacore.com>
7267
7268 * gnat_rm.texi: Document that Test_Case pragma can only appear on
7269 separate declarations.
7270 * sem_prag.adb (procedure Check_Identifier_Is_One_Of): new procedure to
7271 check identifier of pragma argument.
7272 (Chain_TC): check that no other test case associated to the same entity
7273 share the same name.
7274 (Check_Test_Case): disallow test case inside subprogram body
7275 (Analyze_Pragma): correct call to check identifier and not argument
7276 * sem_util.adb, sem_util.ads (Get_Name_From_Test_Case_Pragma): new
7277 function gets name from test case pragma.
7278
dac3bede
YM
72792011-08-04 Yannick Moy <moy@adacore.com>
7280
7281 * gnat_rm.texi: Document new pragma and aspect.
7282 * aspects.adb, aspects.ads (Aspect_Id): new value Aspect_Test_Case
7283 (No_Duplicates_Allowed): new constant array defining whether duplicates
7284 aspects of each kind can appear on the same declaration.
7285 * einfo.adb, einfo.ads (Spec_PPC_List): replace field with Contract
7286 field, which points to a node holding the previous Spec_PPC_List.
7287 * exp_ch9.adb, sem_ch6.adb, sem_prag.adb: Reach to Spec_PPC_List
7288 through the indirection with Contract.
7289 * exp_util.adb (Insert_Actions): raise Program_Error on N_Contract node
7290 * par-prag.adb (Prag): do nothing on Test_Case pragma
7291 * sem.adb (Analyze): abort on N_Contract, on which Analyze should not
7292 be called directly.
7293 * sem_attr.adb (Analyze_Attribute): allow attribute 'Result in
7294 component Ensures of Test_Case.
7295 * sem_ch12.adb, sem_ch6.adb, sem_ch9.adb
7296 (Analyze_Generic_Subprogram_Declaration,
7297 Analyze_Subprogram_Instantiation,
7298 Analyze_Abstract_Subprogram_Declaration,
7299 Analyze_Subprogram_Body_Helper,
7300 Analyze_Subprogram_Specification, Analyze_Entry_Declaration):
7301 insert contract in subprogram node at point of definition
7302 * sem_ch13.adb
7303 (Aspect_Loop): do not raise error on duplicate Test_Case aspect
7304 (Analyze_Aspect_Specifications): analyze Test_Case aspect and create
7305 corresponding pragma
7306 (Check_Aspect_At_Freeze_Point): raise Program_Error on Test_Case aspect
7307 * sem_ch3.adb (Analyze_Declarations): insert analysis of test-cases,
7308 similar to the analysis of pre/post
7309 (Derive_Subprogram): insert contract in subprogram node at point of
7310 derivation.
7311 * sem_prag.adb, sem_prag.ads
7312 (Check_Arg_Is_String_Literal, Check_Identifier):
7313 new checking procedures to be called in treatment of pragmas
7314 (Check_Test_Case): new procedure to check that a Test_Case aspect or
7315 pragma is well-formed. This does not check currently that 'Result is
7316 used only in the Ensures component of a Test_Case.
7317 (Analyze_Pragma): add case for Test_Case
7318 (Analyze_TC_In_Decl_Part): pre-analyze the Requires and Ensures
7319 components of a Test_Case.
7320 (Preanalyze_TC_Args): new procedure to preanalyze the boolean
7321 expressions in the 3rd (and 4th if present) arguments of a Test_Case
7322 pragma, treated as spec expressions.
7323 (Sig_Flags): add value -1 for Test_Case.
7324 * sem_util.adb, sem_util.ads (Get_Ensures_From_Test_Case_Pragma,
7325 Get_Requires_From_Test_Case_Pragma): getters for both expression
7326 components of a Test_Case.
7327 * sinfo.adb, sinfo.ads (N_Contract): new kind of node used as
7328 indirection between an entry or [generic] subprogram entity and its
7329 pre/post + test-cases.
7330 (Spec_PPC_List, Spec_TC_List, Set_Spec_PPC_List, Set_Spec_TC_List):
7331 get/set for fields of an N_Contract node.
7332 * snames.ads-tmpl (Name_Test_Case, Name_Ensures, Name_Mode,
7333 Name_Normal, Name_Requires, Name_Robustness, Pragma_Test_Case): new
7334 names and pragma for Test_Case.
7335 * sprint.adb (Sprint_Node): raise Program_Error on N_Contract node
7336
6a2e5d0f
AC
73372011-08-04 Vincent Celier <celier@adacore.com>
7338
7339 * gnat_ugn.texi: Improve documentation of gnatmake switch
7340 --source-info-file=.
7341
73422011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7343
7344 * exp_ch7.adb (Make_Final_Call): Add local variable Atyp (assertion
7345 type). Initialize Atyp to the appropriate type which is later checked
7346 for completion. Rewrite the assertion associated with private type
7347 completion.
7348
73492011-08-04 Ed Falis <falis@adacore.com>
7350
7351 * adaint.c: Add call to vxCpuConfiguredGet for VxWorks SMP to
7352 initialize the number of CPUs.
7353
73542011-08-04 Ed Schonberg <schonberg@adacore.com>
7355
7356 * sem_type.adb (Disambiguate): New subsidiary routine
7357 In_Same_Declaration_List, to implement AI05-0020: a user-defined
7358 equality on an anonymous access type whose designated type is private
7359 does not lead to an ambiguity with the universal access equality
7360 operator in the body or child units of the defining package. The same
7361 is true for a multiplication operator on a private type completed with
7362 a fixed-point-type.
7363
73642011-08-04 Javier Miranda <miranda@adacore.com>
7365
7366 * opt.ads (Init_Or_Norm_Scalars_Config): Removed.
7367 (Normalize_Scalars_Config): Removed.
7368 * opt.adb
7369 (Register_Opt_Config_Switches): Remove registering config values of
7370 Init_Or_Norm_Scalars_Config and Normalize_Scalars_Config.
7371 (Restore_Opt_Config_Switches): Remove code which restores the values of
7372 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
7373 Init_Or_Norm_Scalars.
7374 (Save_Opt_Config_Switches): Remove code which saves values of
7375 Init_Or_Norm_Scalars and Normalize_Scalars.
7376 (Set_Opt_Config_Switches): Remove code which restores config values of
7377 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
7378 Init_Or_Norm_Scalars.
7379
73802011-08-04 Yannick Moy <moy@adacore.com>
7381
7382 * frontend.adb (Frontend): remove previous patch to avoid full
7383 qualification in ALFA mode.
7384 * lib-xref-alfa.adb (Add_ALFA_Xrefs): use unique name for variables.
7385 * sem_util.adb, sem_util.ads (Unique_Name): new function to define a
7386 unique name for an entity, which could be used to identify the entity
7387 across compilation units.
7388
73892011-08-04 Thomas Quinot <quinot@adacore.com>
7390
7391 * prj-env.adb
7392 (Initialize_Default_Project_Path): Add target specific directory
7393 ($prefix/$target/lib/gnat) in front of project path in all cases
7394 (making gnatmake's behaviour consistent with gprbuild).
7395 * gnatcmd.adb, make.adb, prj-makr.adb, clean.adb:
7396 Pass target name from Sdefault to project subsystem.
7397 * gnatls.adb: Show new target specific default project directory.
7398
73992011-08-04 Johannes Kanig <kanig@adacore.com>
7400
7401 * cstand.adb: Add Information to Identifier in Standard
7402 (Identifer_For): Set Entity to the corresponding entity
7403
483361a6
AC
74042011-08-04 Sergey Rybin <rybin@adacore.com>
7405
7406 * gnat_ugn.texi: Update doc on gnatcheck.
7407
74082011-08-04 Yannick Moy <moy@adacore.com>
7409
7410 * lib-xref-alfa.adb (Add_ALFA_Xrefs): correct definition of ranges of
7411 xrefs in a scope.
7412
74132011-08-04 Yannick Moy <moy@adacore.com>
7414
7415 * exp_prag.adb (Expand_Pragma_Check): in ALFA mode, return without
7416 performing expansion.
7417 * sem_ch6.adb (Analyze_Subprogram_Body_Helper,
7418 Analyze_Generic_Subprogram_Body): protect call to Process_PCCs so that
7419 it is not called in ALFA mode.
7420
ef5569c6
AC
74212011-08-04 Emmanuel Briot <briot@adacore.com>
7422
7423 * make.adb, osint.adb, osint.ads (Reset_Command_Line_Files): not used
7424 after all, so removed.
7425
74262011-08-04 Sergey Rybin <rybin@adacore.com>
7427
7428 * vms_data.ads: Add missing VMS qualifiers.
7429
1ab4a286
EB
74302011-08-04 Emmanuel Briot <briot@adacore.com>
7431
7432 * make.adb, makeutl.adb, osint.adb, osint.ads (Check_Mains): rebuild
7433 the list of files on the command line after processing it through
7434 Complete_Mains.
7435
7ae0d98c
AC
74362011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7437
7438 * exp_ch7.adb (Build_Raise_Statement): Remove the specialized
7439 processing for .NET/JVM. These targets can now benefit from
7440 Raise_From_Controlled_Operation and they share the same processing with
7441 standard targets.
7442 (Establish_Transient_Scope): Remove the restriction for .NET/JVM.
7443 These targets need transient scopes in order to properly finalize short
7444 lived controlled objects.
7445 (Make_Handler_For_Ctrl_Operation): Remove the specialized processing for
7446 NET/JVM. These targets can now benefit from
7447 Raise_From_Controlled_Operation and they share the same processing with
7448 standard targets.
7449
74502011-08-04 Geert Bosch <bosch@adacore.com>
7451
7452 * tracebak.c (STOP_FRAME): Stop at any next pointer outside the stack
7453
74542011-08-04 Ed Schonberg <schonberg@adacore.com>
7455
7456 * exp_aggr.adb (Has_Visible_Private_Ancestor): subsidiary routine to
7457 Expand_Record_Aggregate, to determine whether aggregate must be
7458 expanded into assignments. This is the case if the ancestor part is
7459 private, regarless of the setting of the flag Has_Private_Ancestor.
7460
74612011-08-04 Ed Falis <falis@adacore.com>
7462
7463 * vxaddr2line.adb: Add support for e500v2 and for Linux hosts
7464
74652011-08-04 Bob Duff <duff@adacore.com>
7466
7467 * sinfo.ads: Fix comment.
7468
74692011-08-04 Steve Baird <baird@adacore.com>
7470
7471 * bindgen.adb (Get_Ada_Main_Name): If CodePeer_Mode is set, then
7472 choose a package name in much the same way as is
7473 done for JGNAT when VM_Target /= No_VM, except that
7474 a slightly more distinctive prefix string is used.
7475
74762011-08-04 Emmanuel Briot <briot@adacore.com>
7477
7478 * makeutl.adb (Complete_Mains): no longer accept unit names on the
7479 gnatmake command line.
7480 This behavior was never documented (and was supported only because of
7481 an early bug in the code). This case might lead to ambiguous cases
7482 (between unit names and truncated base names without suffixes).
7483
87729e5a
AC
74842011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7485
7486 * a-tags.ads, a-tags.adb (Unregister_Tag): New routine.
7487 Remove the external tag of a tagged type from the internal hash table.
7488 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on the
7489 expanded usage of the routine. Strenghten the check for Is_Master. Add
7490 processing for tagged types.
7491 (Build_Finalizer): Create all the necessary lists used in finalizer
7492 creation when the processed context is a package that may contain
7493 tagged types.
7494 (Expand_Cleanup_Actions): Rename the call to Has_Controlled_Objects to
7495 Requires_Cleanup_Actions.
7496 (Expand_N_Package_Body): Package bodies may need clean up code
7497 depending on whether they contain tagged types.
7498 (Expand_N_Package_Declaration): Package declarations may need clean up
7499 code depending on whether they contain tagged types.
7500 (Unregister_Tagged_Types): New routine. Search through a list of
7501 declarations or statements, looking for non-abstract Ada tagged types.
7502 For each such type, generate code to unregister the external tag.
7503 * exp_util.adb (Has_Controlled_Objects (Node_Id)): Renamed to
7504 Requires_Cleanup_Actions.
7505 (Requires_Cleanup_Actions (List_Id, Boolean)): New routine. Search
7506 through a list of declarations or statements looking for non-abstract
7507 Ada tagged types or controlled objects.
7508 * exp_util.ads (Has_Controlled_Objects (Node_Id)): Renamed to
7509 Requires_Cleanup_Actions.
7510 (Has_Controlled_Objects (List_Id, Boolean)): Removed.
7511 * rtsfind.ads: Add entry RE_Unregister_Tag to tables RE_Id and
7512 RE_Unit_Table.
7513
75142011-08-04 Vincent Celier <celier@adacore.com>
7515
7516 * prj-env.adb (For_All_Source_Dirs.For_Project): Check if project Prj
7517 has Ada sources, not project Project, because if the root project
7518 Project has no sources of its own, all projects will be deemed without
7519 sources.
7520
75212011-08-04 Gary Dismukes <dismukes@adacore.com>
7522
7523 * bindgen.adb (Gen_Adainit_Ada): Move the generation of the declaration
7524 of the No_Param_Proc acc-to-subp type used for initialization of
7525 __gnat_finalize_library_objects so that it's declared at library level
7526 rather than nested inside of the adainit routine.
7527
75282011-08-04 Javier Miranda <miranda@adacore.com>
7529
7530 * exp_disp.adb (Make_DT): Generate code to check the external tag ONLY
7531 if the tagged type has a representation clause which specifies its
7532 external tag.
7533
75342011-08-04 Ed Schonberg <schonberg@adacore.com>
7535
7536 * einfo.ads, einfo.adb (Has_Private_Ancestor): now a flag on types.
7537 Remove previous procedure with that name.
7538 * sem_ch3.adb (Build_Derived_Record_Type): set Has_Private_Ancestor
7539 when appropriate.
7540 * sem_aggr.adb (Resolve_Extension_Aggregate): if the ancestor part is a
7541 subtype mark, the ancestor cannot have unknown discriminants.
7542 (Resolve_Record_Aggregate): if the type has invisible components
7543 because of a private ancestor, the aggregate is illegal.
7544
75452011-08-04 Vincent Celier <celier@adacore.com>
7546
7547 * switch-m.adb (Normalize_Compiler_Switches): Recognize and take into
7548 account switches -gnat2005, -gnat12 and -gnat2012.
7549
75502011-08-04 Bob Duff <duff@adacore.com>
7551
7552 * s-tasdeb.ads: Minor comment fix.
7553
75542011-08-04 Arnaud Charlet <charlet@adacore.com>
7555
7556 * gnatlink.adb (Gnatlink): Pass -gnat83/95/05/12 switch to gcc in
7557 CodePeer mode.
7558 * switch.ads, switch.adb (Is_Language_Switch): New function.
7559
75602011-08-04 Vincent Celier <celier@adacore.com>
7561
7562 * switch-c.adb: Minor comment addition.
7563
75642011-08-04 Vincent Celier <celier@adacore.com>
7565
7566 * vms_conv.adb (Process_Argument): Fail graciously when qualifier
7567 ending with '=' is followed by a space (missing file name).
7568
75692011-08-04 Pascal Obry <obry@adacore.com>
7570
7571 * g-regist.ads: Fix size of HKEY on x86_64-windows.
7572
75732011-08-04 Ed Schonberg <schonberg@adacore.com>
7574
7575 * sem_ch12.adb (Analyze_Associations): New routine
7576 Check_Overloaded_Formal_Subprogram to reject a formal package when
7577 there is a named association or a box initialisation for an overloaded
7578 formal subprogram of the corresponding generic.
7579
75802011-08-04 Yannick Moy <moy@adacore.com>
7581
7582 * alfa.ads (ALFA_Xref_Record): add component for type of entity
7583 * get_alfa.adb, put_alfa.adb: Read and write new component of
7584 cross-reference.
7585 * lib-xref-alfa.adb (Collect_ALFA): generate new component.
7586
88f47280
AC
75872011-08-04 Pascal Obry <obry@adacore.com>
7588
7589 * urealp.adb: Minor reformatting.
7590
75912011-08-04 Tristan Gingold <gingold@adacore.com>
7592
7593 * exp_ch7.adb (build_finalizer.process_declarations.processing_actions):
7594 Handle the case when Cleanup_Protected_Object returns Empty.
7595
75962011-08-04 Yannick Moy <moy@adacore.com>
7597
7598 * frontend.adb (Frontend): only qualify names in non-ALFA mode
7599
76002011-08-04 Ed Schonberg <schonberg@adacore.com>
7601
7602 * sem_ch4.adb (Try_Class_Wide_Operation): if the context is a procedure
7603 call, ignore functions.
7604
05c53a69
GB
76052011-08-04 Geert Bosch <bosch@adacore.com>
7606
7607 * urealp.adb (Equivalent_Decimal_Exponent): Avoid the use of floating
7608 point.
7609
23cc1ace
EB
76102011-08-04 Emmanuel Briot <briot@adacore.com>
7611
7612 * makeutl.adb (Compute_Builder_Switches): no longer accept a unit name
7613 as an index for Builder'Switches. This conforms to the documentation.
7614 * make.adb (Insert_Project_Sources): avoid duplicate code
7615
cef14201
AC
76162011-08-04 Emmanuel Briot <briot@adacore.com>
7617
7618 * makeutl.adb (Complete_Mains): if the user has passed a relative file
7619 name on the command line (for instance "../dummy"), never assume it can
7620 be a unit name.
7621
76222011-08-04 Tristan Gingold <gingold@adacore.com>
7623
7624 * bindgen.adb: Remove code the reference or create the
7625 Break_Start/__gnat_break_start procedure.
7626 * s-stalib.adb (Break_Start): Removed.
7627
e2fee30d
EB
76282011-08-04 Emmanuel Briot <briot@adacore.com>
7629
7630 * make.adb, makeutl.adb, makeutl.ads (Compute_Builder_Switches): now
7631 shared with gprbuild.
7632
2d395256
AC
76332011-08-04 Yannick Moy <moy@adacore.com>
7634
7635 * par-ch4.adb (P_Primary): preferentially issue an error message about
7636 a missing parenthesis arount a conditional or case expression in Ada
7637 2012 mode, if we detect that the alignment is not correct for a
7638 statement.
7639
76402011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7641
7642 * exp_ch7.adb (Process_Declarations): Do not consider the result of a
7643 tag-to-class-wide conversion as needing finalization actions.
7644 * exp_util.adb (Has_Controlled_Objects): Do not consider the result of
7645 a tag-to-class-wide conversion as needing finalization actions.
7646 (Is_Finalizable_Transient): The result of a tag-to-class-wide
7647 conversion does not need finalization actions.
7648 (Is_Tag_To_CW_Conversion): New routine.
7649 * exp_util.ads (Is_Tag_To_CW_Conversion): New routine. Determines
7650 whether an object is the result of a tag-to-class-wide conversion.
7651
76522011-08-04 Yannick Moy <moy@adacore.com>
7653
7654 * sem_ch13.adb (Analyze_Aspect_Specifications): correct order in which
7655 the left-hand-side and right-hand-side of a conjunct are inserted when
7656 translating a pre- or postcondition
7657 * sem_ch6.adb: Correct typo in comment
7658
76592011-08-04 Ed Schonberg <schonberg@adacore.com>
7660
7661 * gnat_rm.texi: Ravenscar does not prohibit dependence on
7662 Unchecked_Conversion and Unchecked_Deallocation.
7663
76642011-08-04 Thomas Quinot <quinot@adacore.com>
7665
7666 * make.adb: Minor reformatting.
7667
767ab2fd
EB
76682011-08-04 Emmanuel Briot <briot@adacore.com>
7669
7670 * prj.adb, prj.ads, makeutl.adb (Complete_Mains): search for the
7671 sources in the project and its imported projects, but not in the whole
7672 tree.
7673
8fb3f5df
AC
76742011-08-04 Emmanuel Briot <briot@adacore.com>
7675
7676 * make.adb: Remove debug trace.
7677
76782011-08-04 Vincent Celier <celier@adacore.com>
7679
7680 * makeutl.adb (Do_Complete): Get the absolute path name of a relative
7681 path in canonical form, to be able to compare path names on platforms
7682 such as Windows or Darwin.
7683
76842011-08-04 Thomas Quinot <quinot@adacore.com>
7685
7686 * par_sco.adb (Traverse_Declarations_Or_Statements.Set_Statement_Entry):
7687 For a pragma (statement with C1 = 'P'), record the sloc of the pragma.
7688 * scos.ads: Update documentation accordingly.
7689 * put_scos.adb (Output_SCO_Line): Omit statement SCOs for disabled
7690 pragmas.
7691
9515740f
AC
76922011-08-04 Ed Schonberg <schonberg@adacore.com>
7693
7694 * sem_attr.adb (Bad_Attribute_For_Predicate): flag illegal use of
7695 attribute only if prefix type is scalar.
7696
76972011-08-04 Emmanuel Briot <briot@adacore.com>
7698
7699 * make.adb, makeutl.adb, prj-env.adb (Check_Mains): put back support
7700 in gnatmake for specifying mains on the command line that do not belong
7701 to the main project. These mains must currently all belong to the same
7702 project, though.
7703 (Ultimate_Extension_Of): removed, since duplicated
7704 Ultimate_Extending_Project.
7705
92966893
AC
77062011-08-04 Arnaud Charlet <charlet@adacore.com>
7707
7708 * make.adb (Do_Codepeer_Globalize_Step): Removed. Use CodePeer_Mode
7709 instead.
7710 (CodePeer_Mode_String): New.
7711 (Linking_Phase, Binding_Phase): Call gnatlink with -P switch in
7712 CodePeer mode.
7713 (Scan_Make_Arg): Do not disable binding/linking phase in CodePeer mode.
7714 * bindgen.adb (Gen_Elab_Calls_Ada): Ignore subprograms in CodePeer
7715 mode, since no useful elaboration subprogram is needed by CodePeer.
7716 * gnatlink.adb (Gnatlink): Add support for -P switch (CodePeer mode).
7717 In this mode, compile binder file with -gnatC and do stop after this
7718 step.
7719
77202011-08-04 Vincent Celier <celier@adacore.com>
7721
7722 * exp_ch7.adb: Minor comment fix.
7723
5969611f
RD
77242011-08-04 Robert Dewar <dewar@adacore.com>
7725
7726 * exp_ch7.adb, make.adb, sem_ch10.adb, bindgen.adb, sem_res.adb,
7727 exp_ch4.adb, makeutl.adb: Minor reformatting.
7728
6367dd30
AC
77292011-08-04 Emmanuel Briot <briot@adacore.com>
7730
7731 * make.adb, makeutl.adb, makeutl.ads (Make): major refactoring.
7732 Create several new subprograms to move code out of Make. This makes the
7733 code more readable, removes code duplication, and is a preparation work
7734 for adding support for aggregate projects.
7735
77362011-08-04 Tristan Gingold <gingold@adacore.com>
7737
7738 * s-po32gl.ads, s-po32gl.adb: New files.
7739 * exp_ch7.ads (Get_Global_Pool_For_Access_Type): New function.
7740 * exp_ch7.adb (Get_Global_Pool_For_Access_Type): New function.
7741 (Build_Finalization_Collection): Use it.
7742 * exp_ch4.adb (Complete_Controlled_Allocation): Ditto.
7743 * rtsfind.ads: System_Pool_32_Global, Re_Global_Pool_32_Object: New
7744 literals.
7745 * gcc-interface/Makefile.in: Use s-po32gl.o on VMS.
7746 * gcc-interface/Make-lang.in: Update dependencies.
7747
cd8bfe35
EB
77482011-08-04 Emmanuel Briot <briot@adacore.com>
7749
7750 * makeutl.adb (Complete_Mains): add support for specs with no suffix on
7751 the command line.
7752
7db29ea7
EB
77532011-08-04 Emmanuel Briot <briot@adacore.com>
7754
7755 * make.adb, makeutl.adb (Complete_Mains): if a main specified on the
7756 command line is not a file name, also check whether it could be a unit
7757 name.
7758
d9b056ea
AC
77592011-08-04 Eric Botcazou <ebotcazou@adacore.com>
7760
7761 * bindgen.adb (Gen_Finalize_Library_Ada): Factor out code to generate
7762 the header of the finalization routine.
7763 If the unit has no finalizer but is a body whose spec has one, then
7764 generate the decrement of the elaboration entity only.
7765 If the unit has a finalizer and is a spec, then do not generate the
7766 decrement of the elaboration entity.
7767 (Gen_Finalize_Library_C): Likewise.
7768
77692011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7770
7771 * exp_ch7.adb (Alignment_Of): New subsidiary routine.
7772 (Bounds_Size_Expression): Removed.
7773 (Double_Alignment_Of): New subsidiary routine.
7774 (Make_Finalize_Address_Stmts): New local variable Index_Typ. Account
7775 for a hole in the dope vector of unconstrained arrays due to different
7776 index and element alignments.
7777
77782011-08-04 Ed Schonberg <schonberg@adacore.com>
7779
7780 * sem_res.adb (Resolve_Allocator): diagnose task allocator that will
7781 raise program_error because body has not been seen yet.
7782
77832011-08-04 Ed Schonberg <schonberg@adacore.com>
7784
7785 * sem_ch10.adb (Analyze_With_Clause): Protect against child unit with
7786 an unresolved name.
7787
77882011-08-04 Vincent Celier <celier@adacore.com>
7789
7790 * makeutl.adb (Do_Complete): Check absolute paths in canonical forms
7791
77922011-08-04 Yannick Moy <moy@adacore.com>
7793
7794 * alfa.adb, alfa.ads (Unique_Defining_Entity): move function from here
7795 * sem_util.adb, sem_util.ads (Unique_Defining_Entity): ...to here
7796
77972011-08-04 Thomas Quinot <quinot@adacore.com>
7798
7799 * sem_ch12.adb (Analyze_Package_Instantiation): Do not omit body for
7800 instantiation in RCI.
7801
78022011-08-04 Emmanuel Briot <briot@adacore.com>
7803
7804 * make.adb: Share more code with gprbuild
7805
f5fc5b9d
AC
78062011-08-04 Emmanuel Briot <briot@adacore.com>
7807
7808 * projects.texi: Added documentation for the IDE'Gnat project file
7809 attribute.
7810
78112011-08-04 Nicolas Roche <roche@adacore.com>
7812
7813 * gnat_rm.texi: Minor editing.
7814
78152011-08-04 Javier Miranda <miranda@adacore.com>
7816
7817 * bindgen.adb (Gen_Adafinal_Ada): Do not differentiate the main case
7818 and the library case for VM targets.
7819 (Gen_Adainit_Ada): Likewise.
7820
78212011-08-04 Robert Dewar <dewar@adacore.com>
7822
7823 * g-altive.ads: Minor comment updates.
7824 * prj-nmsc.adb: Minor reformatting.
7825
78262011-08-04 Javier Miranda <miranda@adacore.com>
7827
7828 * opt.ads
7829 (Normalize_Scalars_Config): Value of the configuration switch set by
7830 pragma Normalize_Scalars when it appears in the gnat.adc file.
7831 (Normalize_Scalars): New field for record Config_Switches_Type. Used
7832 to save and restore settings of this pragma.
7833 * opt.adb
7834 (Register_Opt_Config_Switches, Save_Opt_Config_Switches,
7835 Restore_Opt_Config_Switches): Add missing support for Normalize_Scalars.
7836
78372011-08-04 Vincent Celier <celier@adacore.com>
7838
7839 * gnat_ugn.texi: Document gnatlink options -M and -M=mapfile
7840
0c4683cf
AC
78412011-08-04 Arnaud Charlet <charlet@adacore.com>
7842
7843 * makeutl.adb: Minor reformatting.
7844
78452011-08-04 Olivier Hainque <hainque@adacore.com>
7846
7847 * g-altive.ads: Update comments to reflect that only the soft
7848 binding is available today.
7849
2598ee6d
RD
78502011-08-04 Robert Dewar <dewar@adacore.com>
7851
7852 * bindgen.adb, einfo.adb, sem_ch12.adb, s-tasren.adb, sem_res.adb,
7853 makeutl.adb, prj-nmsc.adb, opt.ads, prj-env.adb: Minor reformatting
7854 * gcc-interface/Make-lang.in: Update dependencies.
7855
c2db4b32
AC
78562011-08-04 Arnaud Charlet <charlet@adacore.com>
7857
7858 * prj-env.adb: Remove local debug traces.
7859
78602011-08-04 Yannick Moy <moy@adacore.com>
7861
7862 * checks.adb (Apply_Float_Conversion_Check): correct a typo where Lo_OK
7863 was used instead of Hi_OK, which could cause a read of an uninitialized
7864 value later on. Detected while working on the new warning.
7865 * exp_ch9.adb (Expand_N_Entry_Declaration): remove useless assignment
7866 to local variable.
7867 * sem_ch5.adb (Analyze_Assignment): set the last assignment component
7868 in more cases, in order to detect more unreferenced values.
7869 * sem_util.adb, sem_util.ads (Get_Enclosing_Object): return enclosing
7870 object for expression, if any.
7871
78722011-08-04 Eric Botcazou <ebotcazou@adacore.com>
7873
7874 * exp_intr.adb (Expand_Binary_Operator_Call): Look at the RM size of
7875 the operand types instead of the Esize.
7876
78772011-08-04 Steve Baird <baird@adacore.com>
7878
7879 * switch-b.adb (Scan_Binder_Switches): Add -P binder switch, used to
7880 enable CodePeer_Mode.
7881 * bindusg.adb (Display): Add help message describing -P binder switch.
7882 * gnat_ugn.texi: Document -P binder switch.
7883 * bindgen.adb (Gen_Main_Ada): If CodePeer_Mode is set, then call the
7884 user-defined main program directly.
7885 (Gen_Output_File_Ada): If CodePeer_Mode is set, generate a with of the
7886 user-defined main program in the context clause of the package body.
7887
ad05f2e9
AC
78882011-08-04 Yannick Moy <moy@adacore.com>
7889
7890 * alfa.adb, alfa.ads (Get_Entity_For_Decl): remove function, partial
7891 duplicate of Defining_Entity
7892 (Get_Unique_Entity_For_Decl): rename function into
7893 Unique_Defining_Entity
7894 * einfo.adb, einfo.ads (Is_In_ALFA, Body_Is_In_ALFA): remove flags
7895 (Formal_Proof_On): remove synthesized flag
7896 * cstand.adb, sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
7897 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_res.adb, sem_util.adb,
7898 sem_util.ads, stand.ads: Remove treatment associated to entities in ALFA
7899 * sem_prag.adb (Analyze_Pragma): remove special treatment for pragma
7900 Annotate (Formal_Proof)
7901
79022011-08-04 Emmanuel Briot <briot@adacore.com>
7903
7904 * prj-env.adb (Create_Config_Pragmas_File): fix handling of multi-unit
7905 source files with non-standard naming schemes, in imported projects
7906
756ef2a0
AC
79072011-08-04 Emmanuel Briot <briot@adacore.com>
7908
7909 * makeutl.adb (Complete_Mains): when a multi-unit source file is
7910 specified on the gprbuild command line, we need to compile all units
7911 within that file, not just the first one we find
7912 Fix error message for mains that are not found.
7913
79142011-08-04 Thomas Quinot <quinot@adacore.com>
7915
7916 * sem_ch6.adb: Update comment.
7917 * sem_ch12.adb: Minor reformatting.
7918
79192011-08-04 Bob Duff <duff@adacore.com>
7920
7921 * s-tasren.adb (Task_Do_Or_Queue): Previous code was reading
7922 Acceptor.Terminate_Alternative without locking Acceptor, which causes a
7923 race condition whose symptom is to fail to lock Parent. That, in turn,
7924 causes Parent.Awake_Count to be accessed without locking Parent, which
7925 causes another race condition whose symptom is that Parent.Awake_Count
7926 can be off by 1 (either too high or too low). The solution is to lock
7927 Parent unconditionally, and then lock Acceptor, before reading
7928 Acceptor.Terminate_Alternative.
7929
4fdebd93
AC
79302011-08-04 Arnaud Charlet <charlet@adacore.com>
7931
7932 * debug.adb: Update comment.
7933
79342011-08-04 Robert Dewar <dewar@adacore.com>
7935
7936 * par_sco.adb, exp_util.adb, make.adb, a-tags.adb, sem_prag.adb,
7937 sem_util.adb, sem_attr.adb, exp_ch4.adb, g-comlin.adb, g-comlin.ads,
7938 exp_ch6.adb: Minor reformatting.
7939
79402011-08-04 Gary Dismukes <dismukes@adacore.com>
7941
7942 * gnat_ugn.texi: Add sentence about the case of compile-time-detected
7943 checks for -gnateE.
7944
79452011-08-04 Ed Schonberg <schonberg@adacore.com>
7946
7947 * gnat_rm.texi: update Ravenscar desription to reflect Ada2012 RM.
7948
79492011-08-04 Thomas Quinot <quinot@adacore.com>
7950
7951 * sinfo.ads: Minor reformatting.
7952
79532011-08-04 Emmanuel Briot <briot@adacore.com>
7954
7955 * makeutl.adb, makeutl.ads, prj-nmsc.adb (Complete_Mains): report error
7956 even if there is no location.
7957
6aaa0587
ES
79582011-08-04 Ed Schonberg <schonberg@adacore.com>
7959
7960 * sem_res.adb, sem_ch4.adb: move check for restriction
7961 No_Task_Hierarchy to resolve_allocator.
7962
35a1c212
AC
79632011-08-04 Thomas Quinot <quinot@adacore.com>
7964
7965 * sinfo.adb, sinfo.ads, sem_prag.adb, sem_ch12.adb (Pragma_Enabled):
7966 This flag of N_Pragma nodes is not used, remove it as well as all of
7967 the associated circuitry.
7968
79692011-08-04 Javier Miranda <miranda@adacore.com>
7970
7971 * exp_disp.adb (Make_DT): Switch -gnatdQ disables the generation of the
7972 runtime check on duplicated externa tags
7973 * debug.adb Document switch -gnatdQ.
7974
79752011-08-04 Gary Dismukes <dismukes@adacore.com>
7976
7977 * a-fihema.ads: Minor typo fix.
7978
79792011-08-04 Yannick Moy <moy@adacore.com>
7980
7981 * sem_ch10.adb: Minor comment update.
7982
79832011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7984
7985 * einfo.adb: Update the node field usage to reflect the renaming of
7986 Return_Flag to Return_ Flag_Or_Transient_Decl.
7987 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl.
7988 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl.
7989 (Write_Field15_Name): Change Return_Flag to
7990 Return_Flag_Or_Transient_Decl.
7991 * einfo.ads: Rename node field Return_Flag to
7992 Return_Flag_Or_Transient_Decl. Update the associated comment and all
7993 occurrences in entities.
7994 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl. Update
7995 associated Inline pragma.
7996 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl. Update
7997 associated Inline pragma.
7998 * exp_ch4.ads, exp_ch4.adb (Expand_N_Expression_With_Actions): New
7999 routine.
8000 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Update the calls to
8001 Return_Flag and Set_Return_Flag.
8002 * exp_ch7.adb (Process_Declarations): Add code to recognize hook
8003 objects generated for controlled transients declared inside an
8004 Exception_With_Actions. Update the calls to Return_Flag.
8005 (Process_Object_Declaration): Add code to add a null guard for hook
8006 objects generated for controlled transients declared inside an
8007 Exception_With_Actions. Update related comment.
8008 * exp_util.adb (Has_Controlled_Objects): Add code to recognize hook
8009 objects generated for controlled transients declared inside an
8010 Exception_With_Actions. Update the calls to Return_Flag.
8011 * expander.adb (Expand): Add new case for N_Expression_With_Actions.
8012
80132011-08-04 Ed Schonberg <schonberg@adacore.com>
8014
8015 * sem_util.adb:(Wrong_Type): Improve error message on a one-element
8016 positional aggregate.
8017
80182011-08-04 Vincent Celier <celier@adacore.com>
8019
8020 * par_sco.adb (Process_Decisions.Output_Header): Check and record pragma
8021 SLOC only for pragmas.
8022
80232011-08-04 Emmanuel Briot <briot@adacore.com>
8024
8025 * projects.texi: Minor typo fix.
8026
80272011-08-04 Emmanuel Briot <briot@adacore.com>
8028
8029 * prj-nmsc.adb (Check_File): Minor change to traces, to help debugging
8030 on case-sensitive file systems.
8031
c2873f74
TQ
80322011-08-04 Thomas Quinot <quinot@adacore.com>
8033
8034 * put_scos.adb (Put_SCOs): Do not emit decision SCO for an X decision
8035 nested in a disabled pragma.
8036 * scos.ads, scos.adb, par_sco.ads, par_sco.adb: Record sloc of
8037 enclosing pragma, if any, for X decisions.
8038
80392011-08-04 Thomas Quinot <quinot@adacore.com>
8040
8041 * sem_prag.adb: Minor reformatting.
8042
46414266
VC
80432011-08-04 Vincent Celier <celier@adacore.com>
8044
8045 * a-tags.adb (Check_TSD): Avoid concatenation of strings, as it is not
8046 allowed in no run time mode.
8047
80482011-08-04 Vincent Celier <celier@adacore.com>
8049
8050 * make.adb (Check): When -gnatc is used, check for the source file
8051 inside the ALI file with a canonical case file name.
8052
afab164f
EB
80532011-08-04 Emmanuel Briot <briot@adacore.com>
8054
8055 * g-comlin.adb, g-comlin.ads (Add_Switch): Put back support for
8056 overriding the separator.
8057
fe0ec02f
AC
80582011-08-04 Robert Dewar <dewar@adacore.com>
8059
8060 * sem_aggr.adb, par_sco.adb, sem_type.adb, exp_util.adb, exp_ch9.adb,
8061 prj-nmsc.adb, sem_ch13.adb, exp_strm.adb: Minor reformatting.
8062
80632011-08-04 Robert Dewar <dewar@adacore.com>
8064
8065 * gnat_rm.texi: Minor documentation fix for pragma Annotate.
8066
80672011-08-04 Yannick Moy <moy@adacore.com>
8068
8069 * sem_attr.adb (Analyze_Attribute): add check during pre-analysis that
8070 'Result only appears in postcondition of function.
8071
80722011-08-04 Thomas Quinot <quinot@adacore.com>
8073
8074 * a-tags.adb (Check_TSD): When raising PROGRAM_ERROR for a duplicated
8075 external tag, include the value of the external tag in the exception
8076 message.
8077
0180fd26
AC
80782011-08-04 Yannick Moy <moy@adacore.com>
8079
8080 * sem_attr.adb (Result): modify error message for misplaced 'Result
8081
80822011-08-04 Sergey Rybin <rybin@adacore.com>
8083
8084 * gnat_rm.texi (pragma Annotate): Fix syntax description to make it
8085 clear that the second argument must be an identifier.
8086
80872011-08-04 Thomas Quinot <quinot@adacore.com>
8088
8089 * exp_ch9.adb (Build_Barrier_Function): When compiling with
8090 -fpreserve-control-flow, insert an IF statement on the barrier
8091 condition to ensure that a conditional branch instruction is generated.
8092
80932011-08-04 Emmanuel Briot <briot@adacore.com>
8094
8095 * prj-part.adb, prj.adb, prj.ads, prj-tree.ads
8096 (Processing_Flags.Ignore_Missing_With): new flag.
8097
80982011-08-04 Emmanuel Briot <briot@adacore.com>
8099
8100 * prj-nmsc.adb (Find_Sources, Path_Name_Of): Fix handling of
8101 Source_List_File on case-insensitive systems where the file is actually
8102 on a case-sensitive file system (NFS,...).
8103
81042011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8105
8106 * sem_ch6.adb (Analyze_Function_Return): In a rare case where a
8107 function return contains a controlled [extension] aggregate and the
8108 return statement is not part of a handled sequence of statements, wrap
8109 the return in a block. This ensures that all controlled temporaries
8110 generated during aggregate resolution will be picked up by the
8111 finalization machinery.
8112
81132011-08-04 Ed Schonberg <schonberg@adacore.com>
8114
8115 * sem_aggr.adb (Resolve_Aggregate): If aggregate has box-initialized
8116 components, freeze type before resolution, to ensure that default
8117 initializations are present for all components.
8118 * sem_res.adb (Resolve_Actuals): the designated object of an
8119 accces-to-constant type is a legal actual in a call to an
8120 initialization procedure.
8121
81222011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8123
8124 * exp_util.adb (Extract_Renamed_Object): Add N_Type_Conversion and
8125 N_Unchecked_Type_Conversion to the possible containers of a renamed
8126 transient variable.
8127
78efd712
AC
81282011-08-04 Yannick Moy <moy@adacore.com>
8129
8130 * par-ch13.adb (Aspect_Specifications_Present): recognize
8131 "with Identifier'Class =>" as an aspect, so that a meaningful warning
8132 is issued in Strict mode.
8133 * par.adb: Fix typos in comments.
8134
81352011-08-04 Yannick Moy <moy@adacore.com>
8136
8137 * sem_attr.adb (Result): modify error message to take into account Post
8138 aspect when compiling Ada 2012 (or newer) code.
8139
81402011-08-04 Nicolas Roche <roche@adacore.com>
8141
8142 * env.c (__gnat_clearenv): Avoid use of dynamic size array in order to
2c7f9cc0 8143 remove need for GCC exceptions.
78efd712
AC
8144
81452011-08-04 Vincent Celier <celier@adacore.com>
8146
8147 * makeutl.adb (Do_Complete): Call Debug_Output with the name of the
8148 project, not the source file name.
8149 * prj.adb (Find_Sources.Look_For_Sources): If the source has been
8150 excluded, continue looking. This excluded source will only be returned
8151 if there is no other source with the same base name that is not locally
8152 removed.
8153
81542011-08-04 Ed Schonberg <schonberg@adacore.com>
8155
8156 * sem_res.adb (Resolve_Intrinsic_Operator): if the result type is
8157 private and one of the operands is a real literal, use a qualified
8158 expression rather than a conversion which is not meaningful to the
8159 back-end.
8160
0170a691
AC
81612011-08-04 Yannick Moy <moy@adacore.com>
8162
8163 * sem_ch13.adb (Aspect_Loop): when an aspect X and its classwise
8164 corresponding aspect X'Class are allowed, proceed with analysis of the
8165 aspect instead of skipping it.
8166
81672011-08-04 Tristan Gingold <gingold@adacore.com>
8168
8169 * s-flocon.adb, s-flocon.ads: Add a body for s-flocon.ads
8170 This will allow to have an Ada implementation for the subprogram.
8171
deb4f5ba
ES
81722011-08-04 Ed Schonberg <schonberg@adacore.com>
8173
8174 * sem_ch3.adb (Analyze_Full_Type_Declaration): If the declaration is a
8175 completion and aspects are present, apply them to the entity for the
8176 type which is currently the partial view, but which is the one that
8177 will be frozen.
8178 * sem_ch13.adb (Analyze_Aspect_Specifications): if the predicate
8179 applies to a partial view, indicate that the full view has predicates
8180 and delayed aspects.
8181 (Replace_Type_Reference): Handle properly predicates that apply to the
8182 full view of a private completion.
8183
fc893455
AC
81842011-08-04 Eric Botcazou <ebotcazou@adacore.com>
8185
8186 * layout.adb (Layout_Type): For composite types, do not set Esize.
8187 * freeze.adb (Set_Small_Size): Remove test on alignment and do not
8188 set Esize.
8189 (Size_Known): Look at the RM size of components instead of the Esize.
8190 (Freeze_Record_Type): Look at the RM size instead of the Esize to
8191 issue warning and activate Implicit_Packing.
8192 (Freeze_Entity): Likewise. Do not issue a warning for alias/atomic
8193 if the Esize is not known.
8194 * sem_ch13.adb (Analyze_Attribute_Definition_Clause) <Size>: Set Esize
8195 for elementary types only.
8196 (Analyze_Record_Representation_Clause): Look at the RM size instead
8197 of the Esize to issue errors.
8198 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not set Esize if it
8199 is not known.
8200 <E_Record_Type>: Look at the RM size instead of the Esize. Remove
2c7f9cc0 8201 obsolete block.
fc893455
AC
8202 Look at the RM size instead of the Esize for types if the latter is
8203 not known.
8204 (gnat_to_gnu_field): Use Known_Esize instead of Known_Static_Esize.
8205
82062011-08-04 Ed Schonberg <schonberg@adacore.com>
8207
8208 * sem_type.adb: proper handling of equality not involving anonymous
8209 access types.
8210
b37d5bc6
AC
82112011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8212
8213 * exp_ch7.adb (Create_Finalizer): Remove local variables Spec_Nod and
8214 Vis_Decls. When creating a library-level finalizer for a package spec,
8215 both the declaration and body of the finalizer are inserted either in
8216 the visible or private declarations of the package spec.
8217
82182011-08-04 Javier Miranda <miranda@adacore.com>
8219
8220 * sem_ch3.adb (Derive_Subprograms): Complete assertion to request the
8221 use of the full-view of a type when invoking Is_Ancestor.
8222 * sem_type.adb (Is_Ancestor): For consistency, when the traversal of
8223 the full-view of private parents is requested, then use also the
8224 full-view of the parent of the first derivation.
8225
7ab4d95a
AC
82262011-08-04 Tristan Gingold <gingold@adacore.com>
8227
8228 * s-taprop-vxworks.adb (Enter_Task): Use System.Float_Control.Reset
8229 instead of the locally imported procedure.
8230 * s-taprop-mingw.adb (Enter_Task): Ditto.
8231 * s-valrea.adb (Scan_Real): Ditto.
8232 * s-imgrea.adb (Set_Image_Real): Ditto.
8233 * s-flocon.ads: Make the package pure.
8234
82352011-08-04 Thomas Quinot <quinot@adacore.com>
8236
8237 * sinfo.ads, sinfo.adb (Debug_Statement, Set_Debug_Statement): Remove.
8238 * tbuild.ads, tbuild.adb (Make_Pragma): Adjust accordingly.
8239 * sinfo-cn.ads, sinfo-cn.adb (Change_Name_To_Procedure_Call_Statement):
8240 New subprogram, moved here from...
8241 * par.adb, par-ch5.adb (P_Statement_Name): ... here.
8242 * par-prag.adb (Par.Prag, case Pragma_Debug): Do not perform any
8243 rewriting of the last argument into a procedure call statement here...
8244 * sem_prag.adb (Analyze_Pragma, case Pragma_Debug): ...do it there
8245 instead.
8246
82472011-08-04 Thomas Quinot <quinot@adacore.com>
8248
8249 * par_sco.adb: Minor reformatting.
8250
51c400f5
AC
82512011-08-04 Robert Dewar <dewar@adacore.com>
8252
8253 * erroutc.adb: Minor reformatting.
8254
82552011-08-04 Thomas Quinot <quinot@adacore.com>
8256
8257 * par_sco.adb: Comment update.
8258
82592011-08-04 Tristan Gingold <gingold@adacore.com>
8260
8261 * s-flocon.ads: New file.
8262 * g-flocon.ads: Now a renaming of s-flocon.
8263 * Makefile.rtl: Add s-flocon.o
8264
6a49f110
AC
82652011-08-04 Javier Miranda <miranda@adacore.com>
8266
8267 * exp_strm.adb (Build_Array_Input_Function): if the array type is
8268 constrained, do not attempt to build a subtype of it.
8269
82702011-08-04 Yannick Moy <moy@adacore.com>
8271
8272 * errout.ads Change comments: remove 'R'M as an example where quotes
8273 are needed; add ALFA as another case where quotes are not needed
8274 * erroutc.adb (Set_Msg_Insertion_Reserved_Word): add ALFA as another
8275 case where quotes are not needed.
8276 * sem_ch11.adb, sem_ch13.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
8277 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_prag.adb, sem_res.adb:
8278 Remove all occurrences of 'A'L'F'A
8279
82802011-08-04 Ed Schonberg <schonberg@adacore.com>
8281
8282 * sem_ch13.adb: check legality of invariant pragma.
8283
a4640a39
AC
82842011-08-04 Eric Botcazou <ebotcazou@adacore.com>
8285
8286 * bindgen.adb: Add comments.
8287
82882011-08-04 Yannick Moy <moy@adacore.com>
8289
8290 * einfo.adb, einfo.ads: Free Flag254 and make Formal_Proof_On a
8291 synthesized flag.
8292 * sem_prag.adb (Analyze_Pragma): record the pragma Annotate
8293 (Formal_Proof, On/Off) in the Rep_Item list of the current subprogram.
8294
82952011-08-04 Robert Dewar <dewar@adacore.com>
8296
8297 * exp_ch7.adb, exp_ch6.adb, sem_ch3.adb, layout.adb, sem_ch5.adb,
8298 osint-c.ads, sem_util.ads, gnat1drv.adb, targparm.ads, sem_ch6.adb,
8299 sem_ch13.adb, s-pooloc.adb: Minor reformatting.
8300
39ade2f9
AC
83012011-08-04 Thomas Quinot <quinot@adacore.com>
8302
8303 * s-pooloc.ads, s-pooglo.ads: Minor reformatting
8304
83052011-08-04 Thomas Quinot <quinot@adacore.com>
8306
8307 PR ada/47880
8308 * s-pooloc.adb (Deallocate): Fix the case of deallocating the only
8309 allocated object.
8310
83112011-08-04 Robert Dewar <dewar@adacore.com>
8312
8313 * einfo.ads, exp_ch4.adb: Minor reformatting.
8314
83152011-08-04 Jerome Lambourg <lambourg@adacore.com>
8316
8317 * back_end.ads (Gen_Or_Update_Object_File): Add more comments.
8318
7efc3f2d
AC
83192011-08-04 Ed Schonberg <schonberg@adacore.com>
8320
8321 * exp_ch4.adb (Expand_Composite_Equality): code cleanup: use component
8322 type in all cases to compute list of primitive operations, because full
8323 view may be an itype that is not attached to the list of declarations.
8324
83252011-08-04 Eric Botcazou <ebotcazou@adacore.com>
8326
8327 * bindgen.adb (Gen_Adafinal_Ada): Generate an early return if the
8328 library has already been finalized.
8329 (Gen_Adafinal_C): Likewise.
8330 (Gen_Adainit_Ada): Generate an early return if the library has
8331 already been elaborated.
8332 (Gen_Adainit_C): Likewise.
8333 (Gen_Output_File_Ada): Generate an elaboration flag.
8334 (Gen_Output_File_C): Likewise.
8335
f65df609
HK
83362011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8337
8338 * exp_ch4.adb (Expand_Allocator_Expression): Disable the generation of
8339 Set_Finalize_Address_Ptr for CodePeer because Finalize_Address was not
8340 built in the first place.
8341 (Expand_N_Allocator): Disable the generation of Set_Finalize_Address_Ptr
8342 for CodePeer because Finalize_Address was not built to begin with.
8343 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Ditto.
8344
a0fb8fe8
AC
83452011-08-04 Pascal Obry <obry@adacore.com>
8346
8347 * adaint.c (__gnat_tmp_name): Use current process id to create temp
8348 filenames, this ensures unicity of filenames across processes.
8349
83502011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8351
8352 * bindgen.adb (Gen_Finalize_Library_Ada): Rename generated routine
8353 Raise_Controlled to Raise_From_Controlled_Operation. Update the
8354 signature of Raise_From_Controlled_Operation by adding flag From_Abort.
8355 Add False as the actual to From_Abort in the generated call to
8356 Raise_From_Controlled_Operation.
8357
83582011-08-04 Jerome Lambourg <lambourg@adacore.com>
8359
8360 * osint-c.ads, osint-c.adb (Set_Library_Info_Name): Move to declaration
8361 so that the ali file name can be retrieved from outside of this package.
8362 * back_end.ads, back_end.adb (Gen_Or_Update_Object_File): New method
8363 doing nothing in the general case, but used to update the object file
8364 timestamp if directly generated by the backend.
8365 * gnat1drv.adb (Gnat1drv): Make sure the object file's timestamp is set
8366 to a later time than the ali file one.
8367
9534ab17
AC
83682011-08-04 Yannick Moy <moy@adacore.com>
8369
8370 * einfo.adb, einfo.ads (Formal_Proof_On): new flag set on subprogram
8371 entities whose body contains an Annotate pragma which forces formal
8372 proof on this body.
8373 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
8374 sem_ch6.adb, sem_ch9.adb, sem_res.adb: Adapt call to
8375 Mark_Non_ALFA_Subprogram to pass in a message and node.
8376 * sem_prag.adb (Analyze_Pragma): add treatment of pragma Annotate
8377 (Forma_Proof, On) which sets the flag Formal_Proof_On in the
8378 surrounding subprogram.
8379 * sem_util.adb, sem_util.ads (Mark_Non_ALFA_Subprogram,
8380 Mark_Non_ALFA_Subprogram_Unconditional): if the subprogram being marked
8381 as not in ALFA is annotated with Formal_Proof being On, then an error
8382 is issued based on the additional parameters for message and node.
8383 * snames.ads-tmpl (Name_Formal_Proof): new name for annotation.
8384 * gcc-interface/Make-lang.in: Update dependencies.
8385
83862011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8387
8388 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Do not generate
8389 Finalize_Address when CodePeer is enabled.
8390
83912011-08-04 Pascal Obry <obry@adacore.com>
8392
8393 * adaint.c (__gnat_tmp_name): Use _tempnam() instead of tempnam() as
8394 the latter returns a pointer to a static buffer which is deallocated
8395 at the end of the routine.
8396
5c0e97dd
AC
83972011-08-04 Yannick Moy <moy@adacore.com>
8398
8399 * sem_ch3.adb (Array_Type_Declaration): move test for type in ALFA
8400 after index creation; mark unconstrained base array type generated as
8401 being in/not in ALFA as well
8402 (Make_Index): mark subtype created as in/not in ALFA
8403 * sem_ch5.adb (Analyze_Iteration_Scheme): mark entity for iterating
8404 over a loop as in/not in ALFA, depending on its type and form of loop
8405 iteration.
8406
84072011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8408
8409 * exp_ch7.adb (Build_Object_Declarations): Initialize flag Abort
8410 directly to False on .NET and JVM.
8411
7a93c64b
YM
84122011-08-04 Yannick Moy <moy@adacore.com>
8413
8414 * sem_ch3.adb (Constrain_Enumeration, Constrain_Integer): remove
8415 constraint that subtype must come from source code to be in ALFA, so
8416 that anonymous subtypes can be in ALFA too.
8417
e9a1ed9b
YM
84182011-08-04 Yannick Moy <moy@adacore.com>
8419
8420 * sem_ch3.adb (Analyze_Object_Declaration): remove obsolete addition of
8421 reference for ALFA mode.
8422 * lib-xref-alfa.adb, lib-xref.ads (Traverse_Compilation_Unit): make
8423 procedure public so as to use it from formal verification back-end.
8424
8e293fbd
AC
84252011-08-04 Jerome Lambourg <lambourg@adacore.com>
8426
8427 * g-comlin.adb (For_Each_Simple_Switch.Is_In_Config): Remove the
8428 invalid checks of the Parameter, making Remove_Switch not working
8429 correctly.
8430
84312011-08-04 Arnaud Charlet <charlet@adacore.com>
8432
8433 * targparm.ads: Update header: no run-time exception is needed on this
8434 file.
8435
84362011-08-04 Vincent Celier <celier@adacore.com>
8437
8438 * a-fihema.adb: Use System.IO instead of GNAT.IO
8439
84402011-08-04 Thomas Quinot <quinot@adacore.com>
8441
8442 * sem_ch3.adb (Access_Definition): Anonymous access to subprogram types
8443 are forbidden in Compiler_Unit mode.
8444
cfae2bed
AC
84452011-08-04 Robert Dewar <dewar@adacore.com>
8446
8447 * sem_util.adb: Minor reformatting.
8448
84492011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8450
8451 * bindgen.adb (Gen_Finalize_Library_Ada): Update the import string for
8452 library-level finalizers.
8453 (Gen_Finalize_Library_C): Update the import string for library-level
8454 finalizers.
8455 (Gen_Finalize_Library_Defs_C): Update the definition name of a
8456 library-level finalizer.
8457 * exp_ch7.adb: Remove with and use clauses for Stringt.
8458 (Create_Finalizer): Remove local variables Conv_Name, Prag_Decl,
8459 Spec_Decl. Add local variable Body_Id. The names of library-level
8460 finalizers are now manually fully qualified and are no longer external.
8461 A single name is now capable of servicing .NET, JVM and non-VM targets.
8462 Pragma Export is no longer required to provide visibility for the name.
8463 (Create_Finalizer_String): Removed.
8464 (New_Finalizer_Name): New routine which mimics New_..._Name.
8465
01f0729a
AC
84662011-08-04 Eric Botcazou <ebotcazou@adacore.com>
8467
8468 * sem_elab.adb (Check_Internal_Call_Continue): Change the type of the
8469 elaboration counter to Standard_Short_Integer.
8470 * sem_util.adb (Build_Elaboration_Entity): Likewise.
8471 * bindgen.adb (Gen_Elab_Externals_Ada): Adjust to above change.
8472 (Gen_Elab_Externals_C): Likewise.
8473
84742011-08-04 Ed Falis <falis@adacore.com>
8475
8476 * system-vxworks-arm.ads, system-vxworks-sparcv9.ads,
8477 system-vxworks-ppc.ads, system-vxworks-m68k.ads,
8478 system-vxworks-mips.ads, system-vxworks-x86.ads
8479 (Always_Compatible_Rep): set to False for all VxWorks targets.
8480
2c1b72d7
AC
84812011-08-04 Robert Dewar <dewar@adacore.com>
8482
8483 * par_sco.adb, prj-proc.adb, make.adb, bindgen.adb, prj.adb, prj.ads,
8484 makeutl.adb, makeutl.ads, prj-nmsc.adb, exp_ch5.adb, exp_ch12.adb,
8485 exp_ch7.ads, exp_util.ads, sem_util.ads, g-comlin.ads, exp_ch6.adb,
8486 exp_ch6.ads, lib-xref.ads, exp_ch7.adb, exp_util.adb, exp_dist.adb,
8487 exp_strm.adb, gnatcmd.adb, freeze.adb, g-comlin.adb, lib-xref-alfa.adb,
8488 sem_attr.adb, sem_prag.adb, sem_util.adb, sem_elab.adb, sem_ch8.adb,
8489 sem_ch11.adb, sem_eval.adb, sem_ch13.adb, sem_disp.adb, a-fihema.adb:
8490 Minor reformatting and code reorganization.
8491
84922011-08-04 Emmanuel Briot <briot@adacore.com>
8493
8494 * projects.texi: Added doc for aggregate projects.
8495
824e9320
AC
84962011-08-04 Emmanuel Briot <briot@adacore.com>
8497
8498 * prj-proc.adb, prj-nmsc.adb, prj-env.adb (Process_Declarative_Items):
8499 Add support for overriding the Project_Path in aggregate projects.
8500
85012011-08-04 Robert Dewar <dewar@adacore.com>
8502
8503 * a-cofove.ads: Minor reformatting.
8504
85052011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8506
8507 * exp_ch7.adb (Build_Adjust_Or_Finalize_Statements): Update the comment
8508 on the generated code.
8509 (Build_Finalize_Statements): Update the comment on the generated code.
8510 (Build_Initialize_Statements): Update the comment on the generated code.
8511 (Build_Object_Declarations): Add local variable Result. The object
8512 declarations are now built in sequence.
8513 * rtsfind.ads: Add RE_Exception_Occurrence_Access to tables RE_Id and
8514 RE_Unit_Table.
8515
85162011-08-04 Robert Dewar <dewar@adacore.com>
8517
8518 * checks.adb, alfa.adb, alfa.ads: Minor reformatting.
8519
85202011-08-04 Eric Botcazou <ebotcazou@adacore.com>
8521
8522 * einfo.ads (Elaboration_Entity): Document new definition and use.
8523 (Elaboration_Entity_Required): Adjust to above change.
8524 * exp_attr.adb (Expand_N_Attribute_Reference): Likewise.
8525 * exp_ch12.adb: And with and use for Snames.
8526 (Expand_N_Generic_Instantiation): Test 'Elaborated attribute.
8527 * exp_util.adb (Set_Elaboration_Flag): Likewise.
8528 * sem_attr.adb (Analyze_Attribute) <Check_Library_Unit>: Delete.
8529 <Check_Unit_Name>: Deal with N_Expanded_Name.
8530 <Attribute_Elaborated>: Extend to all unit names.
8531 * sem_elab.adb: And with and use for Uintp.
8532 (Check_Internal_Call_Continue): Adjust to Elaboration_Entity change.
8533 * sem_util.ads (Build_Elaboration_Entity): Adjust comment.
8534 * sem_util.adb (Build_Elaboration_Entity): Change type to Integer.
8535 * bindgen.adb (Gen_Elab_Externals_Ada): New local subprogram taken
8536 from Gen_Adainit_Ada.
8537 (Gen_Elab_Externals_C): Likewise, but taken from Gen_Adainit_C.
8538 (Gen_Adafinal_Ada): Remove redundant test. In the non-main program
8539 case, do not call System.Standard_Library.Adafinal; instead call
8540 finalize_library if needed.
8541 (Gen_Adafinal_C): Likewise.
8542 (Gen_Adainit_Ada): Do not set SSL.Finalize_Library_Objects in the
8543 non-main program case.
8544 (Gen_Adainit_C): Generate a couple of external declarations here.
8545 In the main program case, set SSL.Finalize_Library_Objects.
8546 (Gen_Elab_Calls_Ada): Adjust to Elaboration_Entity change.
8547 (Gen_Elab_Calls_C): Likewise.
8548 (Gen_Finalize_Library_Ada): Likewise. Skip SAL interface units.
8549 (Gen_Finalize_Library_C): Likewise. Generate a full function.
8550 (Gen_Main_C): Put back call to Ada_Final and don't finalize library
8551 objects here.
8552 (Gen_Output_File_Ada): Generate pragma Linker_Destructor for Ada_Final
8553 if -a is specified. Call Gen_Elab_Externals_Ada. Move around call to
8554 Gen_Adafinal_Ada.
8555 (Gen_Output_File_C): Generate __attribute__((destructor)) for Ada_Final
8556 if -a is specified. Call Gen_Elab_Externals_C. Remove useless couple
2c7f9cc0 8557 of external declarations. Call Gen_Finalize_Library_C.
824e9320 8558
316d9d4f
EB
85592011-08-04 Emmanuel Briot <briot@adacore.com>
8560
8561 * prj.adb, prj.ads, makeutl.adb, makeutl.ads (Complete_Mains,
8562 Compute_Compilation_Phases): new subprogram.
8563 (Builder_Data, Builder_Project_Tree_Data): new subprogram and type
8564 The number of mains as well as the various compilation phases that
8565 need to be run are now project tree specific, since various
8566 aggregated trees might have different requirements. In particular,
8567 they do not all require bind or link phases.
8568
9434c32e
EB
85692011-08-04 Emmanuel Briot <briot@adacore.com>
8570
8571 * prj.adb, prj.ads, makeutl.adb, makeutl.ads, prj-env.adb
8572 (Project_Tree_Appdata): New type.
8573 It is now possible to associate application-specific data to a project
8574 tree. In particular, this is used in the gprbuild builder to avoid a
8575 number of global tables and htables, especially now that there can be
8576 several project trees loaded at once because of aggregate projects.
8577 (Debug_Name): new procedure.
8578 * projects.texi: Clarify syntax of "**" for Source_Dirs
8579
41ba34db
EB
85802011-08-03 Emmanuel Briot <briot@adacore.com>
8581
8582 * prj.ads, makeutl.adb, makeutl.ads (Queue.Insert): now also inserts
8583 the "roots" for a main.
8584 (Fill_From_Project): add support for aggregate projects. Main units
8585 in aggregated projects are now automatically added in the list of
8586 files to build (although this fails later on in gprbuild, because
8587 these files are not using the root proejct tree, so this needs
8588 further cleanup)
8589 * gcc-interface/Make-lang.in: Update dependencies.
8590
fccd42a9
AC
85912011-08-03 Yannick Moy <moy@adacore.com>
8592
8593 * sem_ch4.adb (Analyze_Conditional_Expression): only allow boolean
8594 conditional expression in ALFA.
8595 * sem_res.adb (Resolve_Conditional_Expression): mark non-boolean
8596 expressions as not in ALFA.
8597
85982011-08-03 Robert Dewar <dewar@adacore.com>
8599
8600 * a-cofove.adb: Minor reformatting.
8601
86022011-08-03 Emmanuel Briot <briot@adacore.com>
8603
8604 * make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads
8605 (Insert_Project_Sources, Insert_withed_Sources_For): moved from the
8606 gprbuild sources.
8607 These packages are more logically placed in the Queue package, since
8608 they manipulate the queue. It is also likely that they can be adapted
8609 for gnatmake, thus sharing more code.
8610 (Finish_Program, Fail_Program): moved from the gprbuild sources, so
8611 that we could move the above.
8612
86132011-08-03 Emmanuel Briot <briot@adacore.com>
8614
8615 * errutil.adb (Finalize): clean up the list of error messages on exit.
8616 Calling this subprogram multiple times will no longer show duplicate
8617 error messages on stderr.
8618
86192011-08-03 Emmanuel Briot <briot@adacore.com>
8620
8621 * g-comlin.adb, g-comlin.ads (Set_Command_Line): ignore the parameter
8622 Getopt_Switches when we have already define a command line
8623 configuration.
8624
5e8c8e44
YM
86252011-08-03 Yannick Moy <moy@adacore.com>
8626
8627 * sem_ch11.adb (Analyze_Raise_xxx_Error): do not mark such nodes as not
8628 in ALFA. Instead, they are considered as assertions to prove.
8629 * sem_ch4.adb (Analyze_Conditional_Expression): do not always mark such
8630 nodes as not in ALFA. Instead, include conditional expressions in ALFA
8631 if they have no ELSE part, or if they occur in pre- and postconditions,
8632 where the Condition cannot have side-effects in ALFA
8633 (Analyze_Membership_Op): do not mark such nodes as not in ALFA
8634 (Analyze_Type_Conversion): do not always mark such nodes as not in ALFA.
8635 Instead, include type conversion between scalar types in ALFA.
8636 * sem_ch6.adb (Process_Formals): correctly mark a parameter in ALFA
8637 if-and-only-if its type is in ALFA.
8638
5ffe0bab
AC
86392011-08-03 Thomas Quinot <quinot@adacore.com>
8640
8641 * scos.adb, get_scos.adb, put_scos.adb
8642 New code letter for decisions: G (entry guard)
8643 * par_sco.adb
8644 (Traverse_Subprogram_Body): Rename to...
8645 (Traverse_Subprogram_Or_Task_Body): New subrpogram.
8646 (Traverse_Protected_Body): New subprogram
8647 (Traverse_Declarations_Or_Statements): Add traversal of task bodies,
8648 protected bodies and entry bodies.
8649
86502011-08-03 Yannick Moy <moy@adacore.com>
8651
8652 * einfo.adb, einfo.ads (Is_Postcondition_Proc): new flag for procedure
8653 entities with get/set subprograms, which is set on procedure entities
8654 generated by the compiler for a postcondition.
8655 * sem_ch6.adb (Process_PPCs): set new flag on postcondition procedures
8656 * alfa.adb, alfa.ads (Get_Entity_For_Decl): new function returning the
8657 entity for a declaration
8658 (Get_Unique_Entity_For_Decl): new function returning an entity which
8659 represents a declaration, so that matching spec and body have the same
8660 entity.
8661
86622011-08-03 Robert Dewar <dewar@adacore.com>
8663
8664 * a-except-2005.adb, a-cfhama.adb, a-cfhase.adb, a-cfhase.ads,
8665 a-cforma.adb, a-cforse.ads, a-cforse.adb: Minor reformatting
8666
86672011-08-03 Yannick Moy <moy@adacore.com>
8668
8669 * lib-xref-alfa.adb (Detect_And_Add_ALFA_Scope): make the subprogram
8670 library-level because retriction No_Implicit_Dynamic_Code in the
8671 front-end prevents its definition as a local subprogram
8672 (Traverse_Compilation_Unit): extract new procedure from Add_ALFA_File,
8673 for reuse in other contexts
8674 (Traverse_Declarations_Or_Statements,
8675 Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
8676 Traverse_Package_Declaration, Traverse_Subprogram_Body): make all these
8677 procedures take a callback parameter to be called on all declarations
8678 * lib-xref.ads
8679 (Traverse_All_Compilation_Units): new generic function to traverse a
8680 compilation unit and call a callback parameter on all declarations
8681
f9ad6b62
AC
86822011-08-03 Javier Miranda <miranda@adacore.com>
8683
8684 * sem_prag.adb (Process_Interface_Name): Allow duplicated export names
8685 in Java since they are always enclosed in a namespace that
8686 differentiates them, and overloaded entities are supported by the VM.
8687
86882011-08-03 Ed Schonberg <schonberg@adacore.com>
8689
8690 * checks.adb (Determine_Range): If a computed bound of an operation is
8691 outside the range of the base type of the expression, and overflow
8692 checks are enabled, the result is unknown and cannot be used for any
8693 subsequent constant folding.
8694 * sem_eval.adb (Compile_Time_Compare): if the bounds of one operand are
8695 unknown, so is the result of the comparison.
8696
86972011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8698
8699 * a-except-2005.adb (Raise_From_Controlled_Operation): Add new formal
8700 From_Abort. When finalization was triggered by an abort, propagate
8701 Standard'Abort_Signal rather than Program_Error.
8702 * a-except-2005.ads (Raise_From_Controlled_Operation): Add new formal
8703 From_Abort.
8704 * a-except.adb (Raise_From_Controlled_Operation): Add new formal
8705 From_Abort. When finalization was triggered by an abort, propagate
8706 Standard'Abort_Signal rather than Program_Error.
8707 * a-except.ads:(Raise_From_Controlled_Operation): Add new formal
8708 From_Abort.
8709 * exp_ch7.adb:(Build_Adjust_Or_Finalize_Statements): New local variable
8710 Abort_Id. Update the calls to Build_Object_Declarations and
8711 Build_Raise_Statement to include Abort_Id.
8712 (Build_Adjust_Statements): New local variable Abort_Id. Update the
8713 calls to Build_Object_Declarations and Build_Raise_Statement to include
8714 Abort_Id.
8715 (Build_Finalize_Statements): New local variable Abort_Id. Update the
8716 calls to Build_Object_Declarations and Build_Raise_Statement to include
8717 Abort_Id.
8718 (Build_Components): Create an entity for Abort_Id when exceptions are
8719 allowed on the target.
8720 (Build_Finalizer): New local variable Abort_Id.
8721 (Build_Initialize_Statements): New local variable Abort_Id. Update the
8722 calls to Build_Object_Declarations and Build_Raise_Statement to include
8723 Abort_Id.
8724 (Build_Object_Declarations): Add new formal Abort_Id. Create the
8725 declaration of flag Abort_Id to preserve the original abort status
8726 before finalization code is executed.
8727 (Build_Raise_Statement): Add new formal Abort_Id. Pass Abort_Id to
8728 runtime routine Raise_From_Controlled_Operation.
8729 (Create_Finalizer): Update the call to Build_Raise_Statement to include
8730 Abort_Id. Update the call to Build_Object_Declarations to include
8731 Abort_Id. Update the layout of the finalizer body.
8732 (Make_Handler_For_Ctrl_Operation): Add an actual for From_Abort.
8733 (Process_Transient_Objects): New local variable Abort_Id. Remove the
8734 clunky code to create all flags and objects related to
8735 exception propagation and replace it with a call to
8736 Build_Object_Declarations. Update the call to Build_Raise_Statement to
8737 include Abort_Id.
8738 * exp_ch7.ads (Build_Object_Declarations): Moved from body to spec.
8739 Add new formal Abort_Id and associated comment on its use.
8740 (Build_Raise_Statement): Add new formal Abort_Id and associated comment
8741 on its use.
8742 * exp_intr.adb (Expand_Unc_Deallocation): New local variable Abort_Id.
8743 Remove the clunky code to create all flags and objects related to
8744 exception propagation and replace it with a call to
8745 Build_Object_Declarations. Update the call to Build_Raise_Statement.
8746
87472011-08-03 Eric Botcazou <ebotcazou@adacore.com>
8748
8749 * s-tassta.adb: Fix minor typos.
8750
87512011-08-03 Robert Dewar <dewar@adacore.com>
8752
8753 * rtsfind.ads, makeutl.ads, prj.ads, prj.adb, make.adb,
8754 lib-writ.adb, makeutl.adb, s-soflin.ads, clean.adb: Minor reformatting.
8755
1cdfa9be
AC
87562011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8757
8758 * exp_ch7.adb (Create_Finalizer): Treat freeze nodes in similar fashion
8759 to packages. This ensures that the finalizer body will not end up
8760 inside the freeze node.
8761 (Process_Declarations): Add code to detect whether a freeze node has a
8762 nested finalization collection.
8763
87642011-08-03 Pascal Obry <obry@adacore.com>
8765
8766 * g-awk.adb, g-awk.ads: Make GNAT.AWK API compatible with Ada 2005.
8767 (Current_Session): Return a not null access to Session_Type.
8768 (Default_Session): Likewise.
8769
243cae0a
AC
87702011-08-03 Robert Dewar <dewar@adacore.com>
8771
8772 * a-cfdlli.adb, bindgen.adb, exp_ch4.adb, exp_ch13.adb, sem_warn.adb,
8773 exp_ch3.adb, exp_ch3.ads: Minor reformatting.
8774
87752011-08-03 Pascal Obry <obry@adacore.com>
8776
8777 * g-awk.ads: Minor comment fix.
8778
87792011-08-03 Sergey Rybin <rybin@adacore.com>
8780
8781 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
8782 the tree structure related to discriminant constraints.
8783 Original_Discriminant cannot be used any more for computing the
8784 defining name for the reference to a discriminant.
8785
87862011-08-03 Ed Schonberg <schonberg@adacore.com>
8787
8788 * sem_disp.adb (Is_Tag_Indeterminate): If the return type of the
8789 function is not visibly tagged, this is not a dispatching call and
8790 therfore is not Tag_Indeterminate, even if the function is marked as
8791 dispatching on result.
8792
f553e7bc
AC
87932011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8794
8795 * exp_ch13.adb: Add with and use clauses for Restrict and Rident.
8796 (Expand_N_Free_Statement): Add a guard to protect against run-times
8797 which do not support controlled types.
8798 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Add a guard to protect
8799 against run-times which do not support controlled types.
8800 * exp_ch4.adb (Complete_Controlled_Allocation): Add a guard to protect
8801 against run-times which do not support controlled types.
8802 * exp_ch7.adb (Build_Finalization_Collection): Add a guard to protect
8803 against run-times which do not support controlled types.
8804 * exp_util.adb (Needs_Finalization): Code reformatting. Add a guard to
8805 protect against run-times which do not support controlled types.
8806
88072011-08-03 Eric Botcazou <ebotcazou@adacore.com>
8808
8809 * exp_intr.adb: Put back with and use clauses for Exp_Ch11.
8810 (Expand_Unc_Deallocation): Expand the AT_END handler at the very end.
8811
e4982b64
AC
88122011-08-03 Ed Schonberg <schonberg@adacore.com>
8813
8814 * exp_ch5.adb (Expand_Iterator_Loop): indicate that the cursor is
8815 modified in the source, to prevent spurious warnings when compiling
8816 with -gnatg.
8817
88182011-08-03 Thomas Quinot <quinot@adacore.com>
8819
8820 * a-except-2005.adb: Minor reformatting.
8821
88222011-08-03 Ed Schonberg <schonberg@adacore.com>
8823
8824 * sem_warn.adb (Check_One_Unit): if the only mention of a withed unit
8825 is a renaming declaration in the private part of a package, do not emit
8826 a warning that the with_clause could be moved because the renaming may
8827 be used in the body or in a child unit.
8828
88292011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8830
8831 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
8832 Propagate the Comes_From_Source attribute from the original return
8833 object to the renaming.
8834
88352011-08-03 Jose Ruiz <ruiz@adacore.com>
8836
8837 * exp_ch7.adb (Build_Raise_Statement): Do not call
8838 Raise_From_Controlled_Operation when this routine is not present in
8839 the run-time library.
8840 (Cleanup_Protected_Object, Cleanup_Task): For restricted run-time
8841 libraries (Ravenscar), tasks are non-terminating, and protected objects
8842 and tasks can only appear at library level, so we do not want
8843 finalization of protected objects nor tasks.
8844 * exp_intr.adb: Minor clarification in comment.
8845 bindgen.adb (Gen_Adainit_Ada, Gen_Main_C, Gen_Output_File_Ada,
8846 Gen_Output_File_C): Remove references to finalization of library-level
8847 objects when using restricted run-time libraries.
8848
88492011-08-03 Ed Schonberg <schonberg@adacore.com>
8850
8851 * sem_ch3.adb (Build_Discriminant_Constraints): Set
8852 Original_Discriminant only if the parent type is a generic formal.
8853
deb8dacc
HK
88542011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8855
8856 * exp_ch13.adb: Add with and use clause for Targparm;
8857 (Expand_N_Free_Statement): Prevent the generation of a custom
8858 Deallocate on .NET/JVM targets since this requires pools and address
8859 arithmetic.
8860 * exp_ch4.adb (Expand_Allocator_Expression): When compiling for
8861 .NET/JVM targets, attach the newly allocated object to the access
8862 type's finalization collection. Do not generate a call to
8863 Set_Finalize_Address_Ptr on .NET/JVM because this routine does not
8864 exist in the runtime.
8865 (Expand_N_Allocator): When compiling for .NET/JVM targets, do not
8866 create a custom Allocate for object that do not require initialization.
8867 Attach a newly allocated object to the access type's finalization
8868 collection on .NET/JVM.
8869 * exp_ch5.adb (Make_Tag_Ctrl_Assignment): Add special processing for
8870 assignment of controlled types on .NET/JVM. The two hidden pointers
8871 Prev and Next and stored and later restored after the assignment takes
8872 place.
8873 * exp_ch6.adb (Expand_Call): Add local constant Curr_S. Add specialized
8874 kludge for .NET/JVM to recognize a particular piece of code coming from
8875 Heap_Management and change the call to Finalize into Deep_Finalize.
8876 * exp_ch7.adb (Build_Finalization_Collection): Allow the creation of
8877 finalization collections on .NET/JVM only for types derived from
8878 Controlled. Separate the association of storage pools with a collection
8879 and only allow it on non-.NET/JVM targets.
8880 (Make_Attach_Call): New routine.
8881 (Make_Detach_Call): New routine.
8882 (Process_Object_Declarations): Suppress the generation of
8883 build-in-place return object clean up code on .NET/JVM since it uses
8884 pools.
8885 * exp_ch7.ads (Make_Attach_Call): New routine.
8886 (Make_Detach_Call): New routine.
8887 * exp_intr.adb Add with and use clause for Targparm.
8888 (Expand_Unc_Deallocation): Detach a controlled object from a collection
8889 on .NET/JVM targets.
8890 * rtsfind.ads: Add entries RE_Attach, RE_Detach and
8891 RE_Root_Controlled_Ptr to tables RE_Id and RE_Unit_Table.
8892 * snames.ads-tmpl: Add name Name_Prev. Move Name_Prev to the special
8893 names used in finalization.
8894
88952011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8896
8897 * a-fihema.adb: Add with and use clauses for System.Soft_Links.
8898 (Attach, Detach): Lock the current task when chaining an object onto a
8899 collection.
8900
df3e68b1
HK
89012011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8902
8903 * a-except.adb, a-except-2005.adb (Raise_From_Controlled_Operation):
8904 Rewritten to create the message strings when the exception is not
8905 raised by an abort during finalization.
8906 * a-except.ads, a-except-2005.ads: Add pragma Export for procedure
8907 Raise_From_Controlled_Operation and update its associated comment.
8908 * a-fihema.ads, a-fihema.adb: New GNAT unit.
8909 Ada.Finalization.Heap_Management provides key functionality
8910 associated with controlled objects on the heap, their creation,
8911 finalization and reclamation. Type Finalization_Collection is
8912 effectively a wrapper which sits ontop of a storage pool and performs
8913 all necessary bookkeeping for all the objects it contains. Each
8914 access-to-controlled or access-to-class-wide type receives a collection
8915 as part of its expansion. The compiler generates buffer code and
8916 invokes Allocate / Deallocate to create and destroy allocated
8917 controlled objects.
8918 * a-finali.adb ("="): Removed.
8919 * a-finali.ads ("="): Removed. Controlled types no longer carry hidden
8920 fields Prev and Next.
8921 * ali.adb (Scan_ALI): Add parsing code to process PF / Has_Finalizer.
8922 A library unit with at least one controlled object on the library level
8923 has a special finalizer which is invoked by the binder. To signal this,
8924 ali files carry field PF.
8925 * ali.ads: New field in type Unit_Record called Has_Finalizer. Add
8926 associated comment on field usage.
8927 * a-tags.adb (Get_RC_Offset): Removed.
8928 (Needs_Finalization): New routine.
8929 * a-tags.ads: Update the structure of the GNAT dispatch tables.
8930 Dispatch tables now carry field Needs_Finalization which provides
8931 runtime indication whether a type is controlled or has controlled
8932 components or both. Remove field RC_Offset.
8933 (Get_RC_Offset): Removed along with its associated pragma Export.
8934 Since tagged types with controlled components no longer carry hidden
8935 field _controller, the special mechanism to retrieve its location is no
8936 longer needed.
8937 (Needs_Finalization): New routine.
8938 * atree.ads, atree.adb (Elist24): New routine.
8939 (Set_Elist24): New routine.
8940 * atree.h: Add a define clause for Elist24.
8941 * bindgen.adb New library-level variable Lib_Final_Built.
8942 (Gen_Adafinal_Ada): Reimplemented. Depending on the restrictions or the
8943 presence of a VM target, the routine generates calls to the proper
8944 library finalization routine.
8945 (Gen_Adainit_Ada): Import Finalize_Library_Objects only on non-VM
8946 targets. Set the correct library finalization routine depending on
8947 whether the library has controlled objects or this is a VM compilation.
8948 (Gen_Finalize_Library_Ada): New routine. This procedure generates calls
8949 to library-level finalizers of compiled units in reverse order of
8950 elaboration. It also produces exception management code and reraises a
8951 potential exception after all units have been finalized.
8952 (Gen_Finalize_Library_C): New routine. This procedure generates calls to
8953 library-level finalizers of compiled units in reverse order of
8954 elaboration.
8955 (Gen_Finalize_Library_Defs_C): New routine. This procedure generates the
8956 definitions of all library-level finalizers available to the compilation
8957 (Gen_Main_Ada): Directly call Adafinal which now contails all target
8958 dependent code.
8959 (Gen_Main_C): Add new local constant Needs_Library_Finalization. Call
8960 System.Standard_Library.Adafinal directly. If the library needs
8961 finalization actions, create the sequence of finalization calls.
8962 (Gen_Output_File_Ada): Alphabetize local variables and constants.
8963 Generate a with clause for System.Soft_Links when compiling for a VM.
8964 Remove the code which imports System.Standard_Library.Adafinal as
8965 Do_Finalize. Generate the library finalization routine.
8966 (Gen_Output_File_C): Add new local constant Needs_Library_Finalization.
8967 If the library needs finalization actions, create all the definitions
8968 of library- level finalizers.
8969 (Has_Finalizer): New routine. Determines whether at least one compiled
8970 unit has a library-level finalizer.
8971 Add type Qualification_Mode.
8972 (Set_Unit_Name): Add a formal which controls the replacement of a dot.
8973 * einfo.adb: New usage of field 15 as Return_Flag.
8974 Remove Finalization_Chain_Entity from the usages of field 19.
8975 Remove Associated_Final_Chain from the usages of field 23.
8976 New usage of field 23 as Associated_Collection.
8977 New usage of field 24 as Finalizer.
8978 New usage of flag 252 as Is_Processed_Transient.
8979 (Associated_Final_Chain): Removed.
8980 (Associated_Collection): New routine.
8981 (Finalization_Chain_Entity): Removed.
8982 (Finalizer): New routine.
8983 (Is_Finalizer): New routine.
8984 (Is_Processed_Transient): New routine.
8985 (Return_Flag): New routine.
8986 (Set_Associated_Final_Chain): Removed.
8987 (Set_Associated_Collection): New routine.
8988 (Set_Finalization_Chain_Entity): Removed.
8989 (Set_Finalizer): New routine.
8990 (Set_Is_Processed_Transient): New routine.
8991 (Set_Return_Flag): New routine.
8992 (Write_Entity_Flags): Include Is_Processed_Transient to the list of
8993 displayed flags.
8994 (Write_Field8_Name): Alphabetize the output.
8995 (Write_Field11_Name): Alphabetize the output.
8996 (Write_Field12_Name): Alphabetize the output.
8997 (Write_Field13_Name): Alphabetize the output.
8998 (Write_Field14_Name): Alphabetize the output.
8999 (Write_Field15_Name): Alphabetize the output.
9000 (Write_Field16_Name): Alphabetize the output.
9001 (Write_Field17_Name): Alphabetize the output.
9002 (Write_Field18_Name): Alphabetize the output.
9003 (Write_Field19_Name): Alphabetize the output. Remove the output of
9004 Finalization_Chain_Entity.
9005 (Write_Field20_Name): Alphabetize the output.
9006 (Write_Field21_Name): Alphabetize the output.
9007 (Write_Field22_Name): Alphabetize the output.
9008 (Write_Field23_Name): Alphabetize the output. Remove the output of
9009 Associated_Final_Chain. Add output for Associated_Collection.
9010 (Write_Field24_Name): Alphabetize the output.
9011 (Write_Field25_Name): Add output for Finalizer.
9012 (Write_Field26_Name): Alphabetize the output.
9013 (Write_Field27_Name): Alphabetize the output.
9014 (Write_Field28_Name): Alphabetize the output.
9015 * einfo.ads: Add new field description for Associated_Collection and
9016 its uses in nodes.
9017 Remove Associated_Final_Chain and its uses in nodes.
9018 Remove Finalization_Chain_Entity and its uses in nodes.
9019 Add new field description for Finalizer and its uses in nodes.
9020 Add new synthesized attribute Is_Finalizer.
9021 Add new flag description for Is_Processed_Transient and its uses in
9022 nodes.
9023 Add new field description for Return_Flag and its uses in nodes.
9024 (Associated_Final_Chain): Removed along with its pragma Inline.
9025 (Associated_Collection): New routine and pragma Inline.
9026 (Finalization_Chain_Entity): Removed along with its pragma Inline.
9027 (Finalizer): New routine and pragma Inline.
9028 (Is_Finalizer): New routine and pragma Inline.
9029 (Is_Processed_Transient): New routine and pragma Inline.
9030 (Return_Flag): New routine and pragma Inline.
9031 (Set_Associated_Final_Chain): Removed along with its pragma Inline.
9032 (Set_Associated_Collection): New routine and pragma Inline.
9033 (Set_Finalization_Chain_Entity): Removed along with its pragma Inline.
9034 (Set_Finalizer): New routine and pragma Inline.
9035 (Set_Is_Processed_Transient): New routine and pragma Inline.
9036 (Set_Return_Flag): New routine and pragma Inline.
9037 * exp_aggr.adb: Alphabetize subprograms.
9038 (Build_Array_Aggr_Code): Remove formal Flist and its associated comment.
9039 (Build_Record_Aggr_Code): Remove formals Flist and Obj along with their
9040 associated comments. Remove local variables External_Final_List and
9041 Attach.
9042 Rename Ctrl_Stuff_Done to Finalization_Done. Rename local variable A to
9043 Ancestor. Remove the retrieval of finalization lists. Update the call to
9044 Make_Adjust_Call.
9045 (Convert_Aggr_In_Allocator): Remove the retrieval of finalization
9046 lists. Update the call to Late_Expansion.
9047 (Convert_Aggr_In_Assignment): Update the call to Late_Expansion.
9048 (Convert_Aggr_In_Object_Decl): Update the call to Late_Expansion.
9049 (Gen_Assign): Remove the retrieval of the finalization list used to
9050 build the assignment. Update the calls to Make_Init_Call and
9051 Make_Adjust_Call.
9052 (Gen_Ctrl_Actions_For_Aggr): Renamed to Generate_Finalization_Actions.
9053 Remove the mechanism to determine attachment levels and finalization
9054 list retrieval. Remove the processing for coextensions.
9055 (Init_Controller): Removed. Controllers no longer exist.
9056 (Late_Expansion): Remove formals Flist and Obj along with their
9057 associated comments. Update the calls to Build_Record_Aggr_Code and
9058 Build_Array_Aggr_Code.
9059 * exp_ch13.adb (Expand_N_Free_Statement): New routine.
9060 (Expand_N_Freeze_Entity): Add special processing for finalizers which
9061 appear in entry bodies, protected subprograms and task bodies.
9062 * exp_ch13.ads (Expand_N_Free_Statement): New routine.
9063 * exp_ch3.adb (Add_Final_Chain): Removed.
9064 (Build_Array_Init_Proc): Alphabetize local variables.
9065 (Build_Assignment): Alphabetize local variables. Update the call to
9066 Maked_Adjust_Call.
9067 (Build_Class_Wide_Master): Rename local variables to better reflect
9068 their role.
9069 (Build_Discriminant_Assignments): Code reformatting.
9070 (Build_Init_Call_Thru): Code reformatting.
9071 (Build_Init_Procedure): Code reformatting. Generate a special version
9072 of Deep_Finalize which is capable of finalizing all initialized
9073 components and ignore the rest.
9074 (Build_Init_Statements): Rename local variables to better reflect their
9075 role.
9076 Reimplement the mechanism to include the creation and update of an index
9077 variable called a "counter". It is used as a bookmark for tracing
9078 initialized and non-initialized components.
9079 (Build_Initialization_Call): Remove local variable Controller_Typ.
9080 Alphabetize all local variables. Remove the initialization of the
9081 record controller and update the call to Make_Init_Call.
9082 (Build_Record_Init_Proc): Rename formal Pe to Rec_Ent.
9083 New local variable Counter.
9084 (Constrain_Array): Alphabetize.
9085 (Expand_Freeze_Array_Type): Create a collection instead of a
9086 finalization list.
9087 (Expand_Freeze_Class_Wide_Type): New routine. Creates TSS primitive
9088 Finalize_Address which is used in conjunction with allocated controlled
9089 objects.
9090 (Expand_N_Object_Declaration): Remove the creation of a finalization
9091 list for anonymous access types. Update the calls to Make_Init_Call and
9092 Make_Adjust_Call.
9093 (Expand_Freeze_Record_Type): Remove local variable Flist. Remove the
9094 retrieval of finalization lists. Remove the expansion of the record
9095 controller. Create TSS primitive Finalize_Address used in conjunction
9096 with controlled objects on the heap. Create finalization collections
9097 for access-to-controlled record components.
9098 (Expand_Record_Controller): Removed.
9099 (Freeze_Type): Remove the freezing of record controllers. Freezing of
9100 class-wide types now requires additional processing. Create
9101 finalization collections for access-to-controlled types.
9102 (Increment_Counter): New routine.
9103 (Make_Counter): New routine.
9104 (Make_Eq_If): Remove the mention of Name_uController.
9105 (Make_Predefined_Primitive_Specs): There is no longer need to skip
9106 types coming from System.Finalization_Root.
9107 (Predef_Deep_Spec): Reimplemented to reflect the new parameter profiles.
9108 (Predefined_Primitive_Bodies): There is no longer need to skip types
9109 coming from System.Finalization_Root.
9110 (Stream_Operation_OK): Do not generate stream routines for
9111 type Ada.Finalization.Heap_Management.Finalization_Collection.
9112 * exp_ch3.ads: Alphabetize subprograms.
9113 * exp_ch4.adb: Remove with and use clause for Sem_Ch8.
9114 Add with and use clause for Lib.
9115 (Complete_Coextension_Finalization): Removed.
9116 (Complete_Controlled_Allocation): New routine. Create a finalization
9117 collection for anonymous access-to-controlled types. Create a custom
9118 Allocate which interfaces with the back end and the machinery in
9119 Heap_Management.
9120 (Expand_Allocator_Expression): Add necessary calls to
9121 Complete_Controlled_Allocation. Remove the retrieval of finalization
9122 lists. Update the calls to Make_Adjust_Call. Generate a call to
9123 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
9124 the associated collection.
9125 (Expand_N_Allocator): Remove the processing for dynamic coextensions.
9126 Code clean up. Remove the retrieval of finalization lists and
9127 attachment levels.
9128 Update the call to Make_Init_Call. Generate a call to
9129 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
9130 the associated collection.
9131 (Get_Allocator_Final_List): Removed. Finalization lists are not
9132 available.
9133 (Suitable_Element): Remove the mention of Name_uController.
9134 * exp_ch5.adb: Remove with and use clauses for Ttypes and Uintp.
9135 (Make_Tag_Ctrl_Assignment): Rewritten to simply do a finalization of
9136 the left hand side, carry out the assignment and adjust the left hand
9137 side.
9138 * exp_ch6.adb (Add_Final_List_Actual_To_Build_In_Place_Call): Removed.
9139 (Add_Collection_Actual_To_Build_In_Place_Call): New routine.
9140 (BIP_Formal_Suffix): Rename BIP_Final_List and BIPfinallist to
9141 BIP_Collection and BIPcollection.
9142 (Build_Heap_Allocator): New routine used to allocate the return object
9143 of a build-in-place function onto a collection.
9144 (Expand_Ctrl_Function_Call): Moved from Exp_Ch7.
9145 (Expand_Call): Do not replace direct calls to Deep routines with their
9146 aliases.
9147 (Expand_N_Extended_Return_Statement): Give all variables shorter names
9148 and update their occurrences. Add a special return flag to monitor the
9149 [ab]normal execution of the function. The flag is set right before the
9150 return statement.
9151 Rewrite the mechanism used to allocate a build-in-place return object
9152 on the heap or on a storage pool.
9153 (Is_Direct_Deep_Call): New routine.
9154 (Make_Build_In_Place_Call_In_Allocator): Add a collection to a
9155 build-in-place function call instead of a final list. Build a call to
9156 Set_Finalize_Address_Ptr to decorate the associated collection.
9157 (Make_Build_In_Place_Call_In_Anonymous_Context): Create a temporary in
9158 order to name the build-in-place function call's result for later
9159 finalization. Add a collection to a build-in-place function call
9160 instead of a final list.
9161 (Make_Build_In_Place_Call_In_Assignment): Add a collection to a
9162 build-in-place function call instead of a final list. Remove the code
9163 which moves one final list and transforms it into the actual in a
9164 nested build-in-place call.
9165 (Make_Build_In_Place_Call_In_Object_Declaration): Add a collection to a
9166 build-in-place function call instead of a final list.
9167 (Move_Final_List): Removed.
9168 (Needs_BIP_Collection): New routine.
9169 (Needs_BIP_Final_List): Removed.
9170 * exp_ch6.ads: Replace BIP_Final_List with BIP_Collection in
9171 enumeration type BIP_Formal_Kind.
9172 Update the related comment.
9173 (Needs_BIP_Collection): New routine.
9174 (Needs_BIP_Final_List): Removed.
9175 * exp_ch7.adb: Add with and use clauses for Elists, Exp_Ch6, Stringt
9176 and Ttypes. Remove with and use clauses for Sem_Type. Alphabetize the
9177 majority of subprograms in this unit. Add Name_Finalize_Address to
9178 array Name_Of and TSS_Finalize_Address to array Deep_Name_Of.
9179 (Build_Adjust_Or_Finalize_Statements): Create the adjust or finalization
9180 statements for an array type.
9181 (Build_Adjust_Statements): Create the adjust statements for a record
9182 type.
9183 (Build_Cleanup_Statements): New routine. A procedure which given any
9184 construct containing asynchronous calls, references to _master, or is a
9185 task body, a task allocation or a protected body produces the necessary
9186 runtime calls to clean up these constructs.
9187 (Build_Exception_Handler): New routine.
9188 (Build_Final_List): Removed.
9189 (Build_Finalization_Collection): New routine. A core procedure which
9190 creates a collection to service heap allocated controlled objects
9191 associated with an access-to-controlled type.
9192 (Build_Finalize_Statements): Create the finalization statements for a
9193 record types.
9194 (Build_Finalizer): New routine. A core procedure which given any
9195 construct with declarations and/or statements detects all objects which
9196 need any type of clean up (controlled objects, protected objects) and
9197 generates all necessary code to clean up the said objects in the proper
9198 order.
9199 (Build_Finalizer_Call): New routine.
9200 (Build_Initialize_Statements): Create the initialization statements for
9201 an array type. The generated routine contains code to finalize partially
9202 initialized arrays.
9203 (Build_Object_Declarations): New routine.
9204 (Build_Raise_Statement): New routine.
9205 (Clean_Simple_Protected_Objects): Removed.
9206 (Controller_Component): Removed.
9207 (Enclosing_Function): New routine.
9208 (Expand_Cleanup_Actions): Create a finalizer for a construct which has
9209 either declarations or statements or both.
9210 (Expand_N_Package_Body): Create a finalizer for a non-generic package.
9211 (Expand_N_Package_Declaration): Create a finalizer for a non-generic
9212 package.
9213 (Find_Final_List): Removed.
9214 (Global_Flist_Ref): Removed.
9215 (In_Finalization_Root): Removed.
9216 (Insert_Actions_In_Scope_Around): Determine the range of the transient
9217 scope in terms of tree nodes. Process all transient variables within
9218 that range.
9219 (Make_Adjust_Call): Rewritten. There is no longer an attach call
9220 generated after the adjust.
9221 (Make_Attach_Call): Removed.
9222 (Make_Call): New routine.
9223 (Make_Clean): Removed.
9224 (Make_Deep_Array_Body): Rewritten to simply invoke the appropriate
9225 build routines.
9226 (Make_Deep_Proc): Rewritten to generate the new profile signature used
9227 in Deep routines.
9228 (Make_Deep_Record_Body): Rewritten to simply invoke the appropriate
9229 build routines.
9230 (Make_Final_Call): Modified to simply create a call to either
9231 Deep_Finalize or Finalize.
9232 (Make_Finalize_Address_Body): New routine.
9233 (Make_Finalize_Address_Stmts): New routine. A function which produces
9234 TSS primitive Finalize_Address used in conjunction with heap allocated
9235 controlled objects.
9236 (Make_Handler_For_Ctrl_Operation): Add specialized code for .NET/JVM.
9237 (Make_Init_Call): Rewritten. There is no longer an attach call
9238 generated after initialization.
9239 (Make_Local_Deep_Finalize): New routine.
9240 (Make_Set_Finalize_Address_Ptr_Call): New routine.
9241 (Make_Transient_Block): Remove the finalization list retrieval and
9242 manipulation.
9243 (Needs_Finalization): Moved to Exp_Util.
9244 (Parent_Field_Type): New routine.
9245 (Preprocess_Components): New routine.
9246 (Process_Transient_Objects): New routine.
9247 (Wrap_HSS_In_Block): New routine.
9248 (Wrap_Transient_Declaration): Remove finalization list management and
9249 controller insertion.
9250 (Wrap_Transient_Expression): Code reformatting.
9251 (Wrap_Transient_Statement): Code reformatting.
9252 * exp_ch7.ads (Build_Final_List): Removed.
9253 (Build_Finalization_Collection): New routine.
9254 (Build_Raise_Statement): New routine.
9255 (Controller_Component): Removed.
9256 (Expand_Ctrl_Function_Call): Moved to Exp_Ch6.
9257 (Find_Final_List): Removed.
9258 (In_Finalization_Root): Removed.
9259 (Is_Simple_Protected_Type): Update related comment.
9260 (Make_Adjust_Call): New parameter profile and associated comments.
9261 (Make_Attach_Call): Removed.
9262 (Make_Final_Call): New parameter profile and associated comments.
9263 (Make_Finalize_Address_Body): New routine.
9264 (Make_Init_Call): New parameter profile and associated comments.
9265 (Make_Local_Deep_Finalize): New routine.
9266 (Make_Set_Finalize_Address_Ptr_Call): New routine.
9267 (Needs_Finalization): Moved to Exp_Util.
9268 * exp_ch9.adb (Add_Object_Pointer): Code reformatting.
9269 (Expand_N_Protected_Body): Remove the handling of finalization lists.
9270 (Find_Protection_Type): Moved to Exp_Util.
9271 * exp_disp.adb: Remove with and use clauses for Exp_Ch7.
9272 (Make_DT): Update sequence of dispatch table initialization. Remove the
9273 initialization of field RC_Offset. Add initialization of field Needs_
9274 Finalization.
9275 * exp_intr.adb (Expand_Unc_Deallocation): Code reformatting.
9276 Reimplement how an object is first finalized, then deallocated.
9277 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
9278 Code reformatting.
9279 * exp_tss.ads: Add special suffix for TSS primitive Finalize_Address.
9280 Register TSS_Finalize_Address with type TSS_Names.
9281 * exp_util.adb (Build_Allocate_Deallocate_Proc): New routine. This core
9282 procedure provides the interface between an allocation / deallocation
9283 and the support machinery in Ada.Finalization.Heap_Management.
9284 (Find_Init_Call): Code reformatting.
9285 (Find_Init_Call_In_List): Code reformatting.
9286 (Find_Protection_Type): Moved from Exp_Ch9.
9287 (Find_Prim_Op): Reimplement to add preference of recovered primitive.
9288 (Has_Controlled_Coextensions): Removed.
9289 (Has_Controlled_Objects): New routine.
9290 (In_Library_Level_Package_Body): New routine.
9291 (Insert_Action_After): New routine.
9292 (Is_Finalizable_Transient): New routine. This predicate determines
9293 whether an object declaration is one of the many variants of controlled
9294 transients.
9295 (Is_Null_Access_BIP_Func_Call): New routine.
9296 (Is_Non_BIP_Func_Call): New routine.
9297 (Is_Related_To_Func_Return): New routine.
9298 (Needs_Finalization): Moved from Exp_Ch7.
9299 * exp_util.ads (Build_Allocate_Deallocate_Proc): New routine.
9300 (Find_Protection_Type): Moved from Exp_Ch9.
9301 (Has_Controlled_Coextensions): Removed.
9302 (Has_Controlled_Objects): New routine.
9303 (In_Library_Level_Package_Body): New routine.
9304 (Insert_Action_After): New routine.
9305 (Is_Finalizable_Transient): New routine.
9306 (Is_Null_Access_BIP_Func_Call): New routine.
9307 (Is_Non_BIP_Func_Call): New routine.
9308 (Is_Related_To_Func_Return): New routine.
9309 (Needs_Finalization): Moved from Exp_ch7.
9310 * expander.adb (Expand): Add a case for N_Free_Statement.
9311 * freeze.adb (Freeze_All): Replace the generation of a finalization
9312 list with a collection for access-to-controlled types.
9313 (Freeze_Entity): Code reformatting.
9314 (Freeze_Record_Type): Remove the freezing of a record controller
9315 component.
9316 (Freeze_Subprogram): Code reformatting.
9317 * inline.adb (Cleanup_Scopes): Remove the reset of the scope
9318 finalization list.
9319 * lib-writ.adb (Write_Unit_Information): Output "PF" when a package
9320 has a library-level finalizer.
9321 * lib-writ.ads: Add "PF" to the sequence of unit attributes.
9322 * a-filico.ads, a-filico.adb, s-finimp.ads, s-finimp.adb: Removed.
9323 * Makefile.rtl: Remove a-filico and s-finimp from the list of object
9324 files. Add a-fihema to the list of object files.
9325 * par-ch4.adb:
9326 Alphabetize the associations in type Is_Parameterless_Attribute.
9327 * rtsfind.ads: Ada.Finalization_List.Controller and
9328 System.Finalization_Implementation are no longer a GNAT unit.
9329 Update the range of type Ada_Finalization_Child. Remove the following
9330 recoverable entities:
2c7f9cc0 9331
df3e68b1
HK
9332 RE_Attach_To_Final_List
9333 RE_Deep_Tag_Attach
9334 RE_Finalize_List
9335 RE_Finalize_One
9336 RE_Finalizable_Ptr_Ptr
9337 RE_Global_Final_List
9338 RE_Limited_Record_Controller
9339 RE_List_Controller
9340 RE_Move_Final_List
9341 RE_Record_Controller
9342 RE_Simple_List_Controller
2c7f9cc0 9343
df3e68b1 9344 Add the following recoverable entities:
2c7f9cc0 9345
df3e68b1
HK
9346 RE_Add_Offset_To_Address
9347 RE_Allocate
9348 RE_Base_Pool
9349 RE_Deallocate
9350 RE_Exception_Identity
9351 RE_Finalization_Collection
9352 RE_Finalization_Collection_Ptr
9353 RE_Needs_Finalization
9354 RE_Save_Library_Occurrence
9355 RE_Set_Finalize_Address_Ptr
9356 RE_Set_Storage_Pool_Ptr
9357 RE_Storage_Count
9358 * sem_aggr.adb (Resolve_Record_Aggregate): Remove mention of
9359 Name_uController.
9360 * sem_aux.adb (First_Discriminant): Remove mention of Name_uController.
9361 (First_Stored_Discriminant): Remove the mention of Name_uController.
9362 * sem_aux.ads: Comment reformatting.
9363 * sem_ch10.adb (Build_Chain): Signal the class-wide creation machinery
9364 to redecorate an already existing class-wide type.
9365 (Decorate_Tagged_Type): New parameter profile and associated comment.
9366 Create a "shadow class-wide type" for a shadow entity.
9367 * sem_ch11.adb (Analyze_Exception_Handlers): Remove the dubious setting
9368 of the final chain along with the associated comment.
9369 * sem_ch3.adb (Access_Type_Declaration): Add new local variable
9370 Full_Desig and set it to the full view of the designated type.
9371 Initialize the finalization collection to empty.
9372 (Build_Derived_Record_Type): Alphabetize local variables. Code
9373 reformatting.
9374 (Collect_Fixed_Components): Remove the mention of Name_uController.
9375 (Create_Constrained_Components): Remove the mention of Name_uController.
9376 (Make_Class_Wide_Type): Add specialized code to redecorate an existing
9377 class-wide type of a shadow entity.
9378 (Process_Full_View): Update the machinery which marks type
9379 Limited_Controlled's entity as limited.
9380 * sem_ch4.adb (Analyze_One_Call): Code reformatting.
9381 * sem_ch6.adb (Create_Extra_Formals): Do not generate a finalization
9382 list, instead make a collection build-in-place formal.
9383 * sem_ch8.adb (Analyze_Object_Renaming): Look at the available view of
9384 a designated type in order to establish a match between the renaming
9385 and the renamed entity.
9386 (Find_Selected_Component): Add guard to prevent spurious exceptions
9387 from being raised on .NET/JVM.
9388 * sem_disp.adb (Check_Dispatching_Operation): Include Finalize_Address
9389 to the list of primitive that need special processing. Update arrays
9390 C_Names and D_Names.
9391 (Replace_Types): Handle class-wide types.
9392 * sem_elab.adb (Check_A_Call): Since Deep_Initialize now has a
9393 different parameter profile, look at the first formal.
9394 * sem_prag.adb: Remove with and use clauses for Exp_Ch7. Add with and
9395 use clauses for Exp_Util.
9396 * sem_res.adb: Remove with and use clauses for Elists.
9397 (Propagate_Coextensions): Removed.
9398 (Resolve_Allocator): Do not propagate the list of coextensions from one
9399 allocator to another.
9400 * sem_util.adb (Build_Actual_Subtype_Of_Component): Rename variable
9401 Deaccessed_T to Desig_Typ.
9402 (Enter_Name): Remove the mention of Name_uController.
9403 (Gather_Components): Remove the mention of Name_uController.
9404 (Incomplete_Or_Private_View): New routine.
9405 (Is_Coextension_Root): Removed.
9406 (Is_Fully_Initialized_Type): Remove the mention of Name_uController.
9407 * sem_util.ads (Incomplete_Or_Private_View): New routine.
9408 (Is_Coextension_Root): Removed.
9409 * s-finroo.ads: Remove with clause for Ada.Unchecked_Conversion.
9410 Controlled types are now derived from a null tagged record. Remove
9411 types Finalizable_Ptr, Finalizable and Empty_Root_Controlled.
9412 * sinfo.adb (Coextensions): Removed.
9413 (Set_Coextensions): Removed.
9414 * sinfo.ads: Remove Coextensions from the explanation of node fields
9415 and its uses in nodes.
9416 Update the field usage of N_Allocator.
9417 (Coextensions): Removed along with its pragma Inline.
9418 (Set_Coextensions): Removed along with its pragma Inline.
9419 * snames.ads-tmpl: Remove names
2c7f9cc0 9420
df3e68b1
HK
9421 Name_uClean
9422 Name_uController
9423 Name_uFinal_List
9424 Name_uLocal_Final_List
9425 Name_Finalization_Root
9426 Name_Next
9427 Name_Prev
2c7f9cc0 9428
df3e68b1 9429 Add names
2c7f9cc0 9430
df3e68b1
HK
9431 Name_uFinalizer
9432 Name_Finalize_Address
9433 * s-pooglo.adb (Allocate): Add overriding indicator.
9434 (Deallocate): Add overriding indicator.
9435 (Storage_Size): Add overriding indicator.
9436 * s-soflin.adb (Adafinal_NT): Invoke Finalize_Library_Objects rather
9437 than Finalize_Global_List.
9438 (Null_Finalize_Global_List): Removed.
9439 (Save_Library_Occurrence): New routine.
9440 * s-soflin.ads: Remove variable Finalize_Global_List along with its
9441 initialization. Add variable Finalize_Library_Objects along with its
9442 pragma Export. Add variables Library_Exception and
9443 Library_Exception_Set along with their pragma Export.
9444 (Null_Finalize_Global_List): Removed.
9445 (Save_Library_Occurrence): New routine.
9446 * s-tassta.adb (Finalize_Global_Tasks): Call Finalize_Library_Objects
9447 rather than Finalize_Global_List.
9448 * tbuild.adb (Unchecked_Convert_To): Capture and set the parent field
9449 of the constructed node.
9450
2ee06322
RO
94512011-08-03 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
9452
9453 * link.c: Include "auto-host.h" before system headers.
9454
f77b022b
VC
94552011-08-03 Vincent Celier <celier@adacore.com>
9456
9457 * make.adb (Gnatmake): Add to table Library_Projs only library projects
9458 that are not extended. Do not check if a library project that is
9459 extended should be regenerated. Do not add to table Library_Paths the
9460 libraries that are in extended projects. Link only with libraries that
9461 are in libray projects that are not extended.
9462 * prj-nmsc.adb (Check_Library_Attributes): Do not reset flag Library
9463 for a library project that is extended.
9464
0187b60e
AC
94652011-08-03 Gary Dismukes <dismukes@adacore.com>
9466
9467 * sem_ch6.adb (Find_Corresponding_Spec): When in an instance, skip
9468 conforming subprogram renamings that appear to be completions if they
9469 are not fully conformant.
9470 Such renamings are homographs but not completions.
9471 * sem_type.adb (Disambiguate): Handle disambiguation of overloaded
9472 names in a subprogram renaming that appears in an instance.
9473
94742011-08-03 Ed Schonberg <schonberg@adacore.com>
9475
9476 * exp_util.adb (Expand_Subtype_From_Expr): if the type is limited but
9477 not immutably limited, build actual subtype from expression to provide
9478 proper bounds to caller.
9479
94802011-08-03 Gary Dismukes <dismukes@adacore.com>
9481
9482 * sem_ch8.adb: Minor comment correction.
9483
94842011-08-03 Thomas Quinot <quinot@adacore.com>
9485
9486 * exp_strm.adb (Build_Array_Input_Function): In Ada 2005 mode, when
9487 returning a limited array, use an extended return statement.
9488
94892011-08-03 Vincent Celier <celier@adacore.com>
9490
9491 * make.adb (Initialize): If --subdirs= is used, but no project file is
9492 specified, attempt to create the specify subdir if it does not already
9493 exist and use it as the object directory as if -D had been specified.
9494
94952011-08-03 Arnaud Charlet <charlet@adacore.com>
9496
9497 * s-tpopsp-vms.adb: New file.
9498 * s-taprop-vms.adb: Put back ATCB_Key, since needed by this file on VMS.
9499 * gcc-interfaces/Makefile.in: Use s-taprop-vms.adb on VMS.
9500
e280f981
AC
95012011-08-03 Emmanuel Briot <briot@adacore.com>
9502
9503 * make.adb, makeutl.adb, makeutl.ads, clean.adb (Makeutl.Queue): new
9504 package.
9505
95062011-08-03 Yannick Moy <moy@adacore.com>
9507
9508 * cstand.adb (Create_Standard): select Universal_Integer as an ALFA type
9509 * sem_ch3.adb (Array_Type_Declaration): detect array types in ALFA
9510 * sem_util.adb, sem_util.ads (Has_Static_Array_Bounds): new function to
9511 detect that an array has static bounds.
9512
98c99a5a
AC
95132011-08-03 Thomas Quinot <quinot@adacore.com>
9514
9515 * exp_dist.adb: Minor reformatting.
9516
95172011-08-03 Arnaud Charlet <charlet@adacore.com>
9518
9519 * s-taprop-irix.adb, s-taprop-hpux-dce.adb, s-taprop-vms.adb
9520 (ATCB_Key): Removed, not always used.
9521
95222011-08-03 Emmanuel Briot <briot@adacore.com>
9523
9524 * gnatcmd.adb, make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads,
9525 clean.adb, prj-conf.adb, prj-env.adb, prj-env.ads (Makeutl): remove
9526 most remaining global variables.
9527
686d0984
AC
95282011-08-03 Robert Dewar <dewar@adacore.com>
9529
9530 * gnatcmd.adb, prj-proc.adb, mlib-prj.adb, prj.adb, makeutl.ads,
9531 prj-util.adb, prj-util.ads, prj-conf.adb, prj-env.adb: Minor
9532 reformatting.
9533
95342011-08-03 Javier Miranda <miranda@adacore.com>
9535
9536 * exp_util.adb (Is_VM_By_Copy_Actual): Include N_Slide nodes as actuals
9537 that must be passed by copy in VM targets.
9538
95392011-08-03 Emmanuel Briot <briot@adacore.com>
9540
9541 * prj.ads, prj-nmsc.adb (Files_Htable): removed this htable, which
9542 duplicates a similar htable now in the project tree.
9543
95442011-08-03 Claire Dross <dross@adacore.com>
9545
9546 * a-cfdlli.adb, a-cfhama.adb, a-cfhase.adb, a-cforma.adb, a-cforse.adb,
9547 a-cofove.adb ("=", Length, Is_Empty, Clear, Assign, Copy, Element,
9548 Replace_Element, Query_Element, Update_Element, Move, Insert, Prepend,
9549 Append, Delete, Delete_First, Delete_Last, Reverse_Element, Swap,
9550 Splice, First, First_Element, Last, Last_Element, Next, Previous, Find,
9551 Reverse_Find, Contains, Has_Element, Iterate, Reverse_Iterate, Capacity,
9552 Reserve_Length, Length, Strict_Equal, Left, Right): Data-structure
9553 update.
9554
95552011-08-03 Arnaud Charlet <charlet@adacore.com>
9556
9557 * s-taprop-posix.adb, s-taprop-linux.adb, s-taprop-tru64.adb
9558 (ATCB_Key): Removed, not always used.
9559 * s-tpopsp-posix.adb, s-tpopsp-posix-foreign.adb (ATCB_Key): Moved from
9560 s-taprop-posix.adb.
9561 * s-tpopsp-tls.adb: New file.
9562 * gcc-interface/Makefile.in: Use TLS implementation of s-tpopsp.adb on
9563 x86/x64/ia64/powerpc/sparc Linux.
9564
95652011-08-03 Arnaud Charlet <charlet@adacore.com>
9566
9567 * system-aix.ads, system-aix64.ads: Set ZCX_By_Default to True.
9568 * gcc-interface/Makefile.in: Switch to ZCX by default on AIX ports.
9569
95702011-08-03 Thomas Quinot <quinot@adacore.com>
9571
9572 * rtsfind.ads, exp_dist.adb, exp_dist.ads
9573 (Build_From_Any_Call, Build_To_Any_Call, Build_TypeCode_Call):
9574 Fix type selection for mapping integer types to PolyORB types.
9575
95762011-08-03 Bob Duff <duff@adacore.com>
9577
9578 * sem_ch7.adb: Minor comment clarification.
9579
95802011-08-03 Bob Duff <duff@adacore.com>
9581
9582 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): If we get
9583 an error analyzing a choice, skip further processing. Further
9584 processing could cause a crash or cascade errors.
9585
40ecf2f5
EB
95862011-08-03 Emmanuel Briot <briot@adacore.com>
9587
9588 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, mlib-prj.adb,
9589 prj.adb, prj.ads, makeutl.adb, makeutl.ads, clean.adb, prj-nmsc.adb,
9590 prj-util.adb, prj-util.ads, prj-conf.adb, prj-conf.ads, prj-env.adb,
9591 prj-env.ads (Shared_Project_Tree_Data): new type
9592 An aggregate project and its aggregated trees need to share the common
9593 data structures used for lists of strings, packages,... This makes the
9594 code simpler since otherwise we have to pass the root tree (also used
9595 for the configuration file data) in addition to the current project
9596 tree. This also avoids ambiguities as to which tree should be used.
9597 And finally this saves a bit of memory.
9598 (For_Every_Project_Imported): new parameter Tree.
9599 Since aggregated projects are using a different tree, we need to let
9600 the caller know which tree to use to manipulate the returned project.
9601
9fde638d
RD
96022011-08-03 Robert Dewar <dewar@adacore.com>
9603
9604 * prj-proc.adb, exp_util.ads, exp_ch9.adb, make.adb, prj-ext.adb,
9605 prj-ext.ads, alfa.ads, sem_ch4.adb, makeutl.adb, makeutl.ads,
9606 lib-xref-alfa.adb, sem_cat.adb, exp_dist.adb, get_alfa.adb,
9607 prj-env.adb, prj-env.ads, prj-tree.adb, alfa.ads: Minor reformatting.
9608
95eb8b69
AC
96092011-08-03 Javier Miranda <miranda@adacore.com>
9610
9611 * exp_util.adb, sem_aux.adb, exp_util.ads, sem_aux.ads:
9612 Move routine Is_VM_By_Copy_Actual from sem_aux to exp_util.
9613
96142011-08-03 Bob Duff <duff@adacore.com>
9615
9616 * sem_ch8.adb (Is_Primitive_Operator_In_Use): Always check In_Use on
9617 the Base_Type.
9618
96192011-08-03 Joel Brobecker <brobecker@adacore.com brobecker>
9620
9621 * g-sha256.ads, g-sha512.ads, g-sha1.ads, g-sha224.ads, g-sha384.ads,
9622 g-sehash.ads: Fix typo. Update header.
9623
96242011-08-03 Thomas Quinot <quinot@adacore.com>
9625
9626 * exp_ch6.adb (Expand_Actuals): Remove Ada_2005 guard on build-in-place
9627 expansion.
9628
96292011-08-03 Gary Dismukes <dismukes@adacore.com>
9630
9631 * sem_ch4.adb (Analyze_Overloaded_Selected_Component): Consider
9632 prefixes of private types along with records, since the selector may be
9633 a discriminant.
9634 * sem_res.adb (Resolve_Selected_Component): Consider prefixes of
9635 private types along with records, since the selector may be a
9636 discriminant.
9637
92e77027
AC
96382011-08-03 Emmanuel Briot <briot@adacore.com>
9639
b2f7ebc1 9640 * prj-pp.adb (Pretty_Print): Remove trailing blank line.
92e77027
AC
9641
96422011-08-03 Javier Miranda <miranda@adacore.com>
9643
9644 * sem_aux.adb (Is_VM_By_Copy_Actual): Fix wrong use of
9645 Tagged_Type_Expansion.
9646
96472011-08-03 Yannick Moy <moy@adacore.com>
9648
b2f7ebc1
GP
9649 * sem_res.adb (Resolve_Op_Concat_Arg): Do not issue a SPARK
9650 violation when the argument of concatenation is the name of a
9651 constant.
92e77027 9652
ab29a348
EB
96532011-08-03 Emmanuel Briot <briot@adacore.com>
9654
9655 * prj-proc.adb, prj-ext.adb, prj-ext.ads, prj-env.adb, prj-env.ads,
9656 prj-tree.adb, prj-tree.ads (Initialize_And_Copy, Copy): new subprograms
9657 (Process_Declarative_Items): new parameter Child_Env.
9658
9466892f
AC
96592011-08-03 Yannick Moy <moy@adacore.com>
9660
589ef536
GP
9661 * alfa.ads: Update format of ALFA section in ALI file in order to
9662 add a mapping from bodies to specs when both are present.
9663 (ALFA_Scope_Record): Add components for spec file/scope.
9664 * get_alfa.adb (Get_ALFA): Read the new file/scope for spec when
9665 present.
9666 * lib-xref-alfa.adb (Collect_ALFA): After all scopes have been
9667 collected, fill in the spec information when relevant.
9668 * put_alfa.adb (Put_ALFA): Write the new file/scope for spec when
9466892f
AC
9669 present.
9670
96712011-08-03 Eric Botcazou <ebotcazou@adacore.com>
9672
9673 * inline.adb (Add_Inlined_Subprogram): Do not consider the enclosing
9674 code unit to decide whether to add internally generated subprograms.
2c7f9cc0 9675
9466892f
AC
96762011-08-03 Javier Miranda <miranda@adacore.com>
9677
9678 * sem_aux.ads, sem_aux.adb (Is_VM_By_Copy_Actual): New subprogram.
589ef536
GP
9679 * exp_ch9.adb (Build_Simple_Entry_Call): Handle actuals that must
9680 be handled by copy in VM targets.
9466892f
AC
9681
96822011-08-03 Emmanuel Briot <briot@adacore.com>
9683
589ef536 9684 * make.adb, makeutl.adb, makeutl.ads (Make.Switches_Of): Share
9466892f
AC
9685 code with Makeutl.Get_Switches.
9686 * prj-tree.adb: Update comment.
9687
b5ea9143
AC
96882011-08-03 Thomas Quinot <quinot@adacore.com>
9689
9690 * sem_cat.adb (Validate_RCI_Subprogram_Declaration): Reject a remote
9691 subprogram with a limited formal that does not support external
9692 streaming.
9693
96942011-08-03 Yannick Moy <moy@adacore.com>
9695
9696 * get_alfa.adb (Get_ALFA): add missing Skip_Spaces at start of
9697 continuation line
9698 * lib-xref-alfa.adb (Add_ALFA_File): split removal of scopes that are
9699 not from current unit in two phases, because it is not possible to
9700 change the table while iterating over its content.
9701 * put_alfa.adb (Put_ALFA): reset current file/scope at each new entity
9702
97032011-08-03 Sergey Rybin <rybin@adacore.com>
9704
9705 * vms_data.ads: Add qualifier for gnatmetric --no-static-loop option
9706 * gnat_ugn.texi: Update description of complexity metrics (gnatmetric)
9707
668a19bc
ES
97082011-08-03 Ed Schonberg <schonberg@adacore.com>
9709
9710 * sem_res.adb (Resolve_Op_Concat_Arg): if the argument is an aggregate
9711 and the component type is composite, this is ambiguous for predefined
9712 concatenation, but if the node is not overloaded and the entity is a use
9713 -defined function its profile can be used to resolve that aggregate.
9714
170b2989
AC
97152011-08-03 Robert Dewar <dewar@adacore.com>
9716
9717 * exp_ch4.adb: Minor code cleanup.
9718
97192011-08-03 Thomas Quinot <quinot@adacore.com>
9720
9721 * exp_dist.adb: Do not generate distribution stubs if serious errors
9722 have been diagnosed.
9723
97242011-08-03 Ed Schonberg <schonberg@adacore.com>
9725
9726 * sem_ch4.adb (Try_Primitive_Operation): when checking the validity of
9727 the first formal of a primitive operation, go to the base type to
9728 handle properly an access to a derived type with constrained
9729 discriminants.
9730 * sem_type.adb (Disambiguate): an immediately visible operator hides a
9731 user-defined function that is only use-visible.
170b2989 9732
e917aec2
RD
97332011-08-03 Robert Dewar <dewar@adacore.com>
9734
9735 * sem_aggr.adb, sem_ch3.adb, lib.ads, gnatcmd.adb, prj-proc.adb,
9736 make.adb, lib-writ.adb, prj-part.adb, prj-part.ads, prj-ext.adb,
9737 fname-uf.adb, prj-ext.ads, prj.adb, prj.ads, sem_attr.adb, alfa.adb,
9738 prj-makr.adb, errout.adb, makeutl.adb, makeutl.ads, restrict.ads,
9739 sem_ch6.adb, g-pehage.adb, clean.adb, put_alfa.adb, lib-xref-alfa.adb,
9740 prj-nmsc.adb, prj-nmsc.ads, sem_ch8.adb, prj-pars.ads, exp_aggr.adb,
9741 prj-attr.ads, sem_ch13.adb, get_alfa.adb, prj-env.adb, prj-env.ads,
9742 alfa_test.adb, prj-tree.adb, prj-tree.ads, einfo.ads: Minor reformatting
9743
97442011-08-03 Robert Dewar <dewar@adacore.com>
9745
9746 * repinfo.adb (List_Mechanism): Add handling of
9747 Convention_Ada_Pass_By_XXX.
9748 * sem_mech.adb (Set_Mechanism): Ditto.
9749 * sem_prag.adb (Process_Convention): Add entries for
9750 Convention_Ada_Pass_By_XXX.
9751 * snames.adb-tmpl, snames.ads-tmpl: Ditto.
9752
49bfcf43
AC
97532011-08-03 Pascal Obry <obry@adacore.com>
9754
9755 * makeutl.adb: Minor reformatting.
9756
97572011-08-03 Vincent Celier <celier@adacore.com>
9758
9759 * fname-uf.adb
9760 (Get_File_Name) If the file cannot be found when there are no config
9761 pragmas file and May_Fail is True, return No_File instead of the file
9762 name, to be consistent.
9763
97642011-08-03 Pascal Obry <obry@adacore.com>
9765
9766 * adaint.c (__gnat_is_executable_file_attr): Avoid access
9767 to null pointer.
9768
97692011-08-03 Javier Miranda <miranda@adacore.com>
9770
9771 * sem_ch13.adb
9772 (Same_Representation): In VM targets the representation of arrays with
9773 aliased components differs from arrays with non-aliased components.
9774
34798441
EB
97752011-08-03 Emmanuel Briot <briot@adacore.com>
9776
9777 * prj-proc.adb, prj-attr.adb, prj-attr.ads (Get_Attribute_Index): do
9778 not systematically lower case attribute indexes that contain no "."
9779 Fix definition of several Naming attributes, which take
9780 a unit name as index and therefore should be case insensitive.
9781 Minor refactoring (reduce length of variable names).
9782
97832011-08-03 Emmanuel Briot <briot@adacore.com>
9784
9785 * makeutl.adb, makeutl.ads (Get_Switches): new subprogram.
9786
4437a530
EB
97872011-08-03 Emmanuel Briot <briot@adacore.com>
9788
9789 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, prj-part.adb,
9790 prj-part.ads, switch-m.adb, switch-m.ads, prj-makr.adb, clean.adb,
9791 prj-pars.adb, prj-pars.ads, prj-conf.adb, prj-conf.ads, prj-tree.adb,
9792 prj-tree.ads (Prj.Tree.Environment): new type.
9793
804fe3c4
EB
97942011-08-03 Emmanuel Briot <briot@adacore.com>
9795
9796 * prj-proc.adb, prj.ads, makeutl.adb, makeutl.ads, prj-conf.adb,
9797 prj-tree.adb, prj-tree.ads (Environment): new type.
9798
c565bc66
AC
97992011-08-03 Emmanuel Briot <briot@adacore.com>
9800
9801 * prj-tree.ads: Remove unused variable.
9802
98032011-08-03 Yannick Moy <moy@adacore.com>
9804
9805 * restrict.adb (Restriction_Msg): set "SPARK" all in upper case for
9806 issuing messages related to SPARK restriction violation.
9807
4ee646da
AC
98082011-08-03 Ed Schonberg <schonberg@adacore.com>
9809
9810 * sem_ch6.adb: guard against error nodes in return statements.
9811
98122011-08-03 Arnaud Charlet <charlet@adacore.com>
9813
9814 * errout.adb (Error_Msg_Internal): the main unit has not been read yet,
9815 a warning can only appear on a configuration file, so emit warning
9816 without further checks.
9817
98182011-08-03 Arnaud Charlet <charlet@adacore.com>
9819
9820 * s-interr.ads: add overriding keyword.
9821
98222011-08-03 Geert Bosch <bosch@adacore.com>
9823
9824 * exp_attr.adb: Fix minor typo.
9825
98262011-08-03 Ed Schonberg <schonberg@adacore.com>
9827
9828 * par-ch4.adb: improve error recovery.
9829
c0e538ad
AC
98302011-08-03 Emmanuel Briot <briot@adacore.com>
9831
9832 * prj-part.adb, prj-part.ads, prj-makr.adb, prj-pars.adb, prj-conf.adb,
9833 prj-env.adb (Prj.Part.Parse): change parameter Always_Errout_Finalize
9834 to Errout_Handling.
9835
98362011-08-03 Emmanuel Briot <briot@adacore.com>
9837
9838 * prj-dect.adb (Parse_Attribute_Declaration): make sure we can use
9839 "external" as an attribute name in aggregate projects.
9840
98412011-08-03 Jose Ruiz <ruiz@adacore.com>
9842
9843 * s-taprop-vxworks.adb: (Create_Task, Initialize): Ada 2012 pragma CPU
9844 uses CPU numbers starting 1, while VxWorks uses CPU numbers starting
9845 from 0, so we need to adjust.
9846
98472011-08-03 Emmanuel Briot <briot@adacore.com>
9848
9849 * prj-proc.adb, prj-ext.adb, prj-ext.ads, makeutl.adb, prj-tree.adb,
9850 prj-tree.ads, gnatcmd.adb, clean.adb (External_References): new type.
9851
c4d67e2d
AC
98522011-08-03 Yannick Moy <moy@adacore.com>
9853
9854 * sem_ch6.adb (New_Overloaded_Entity): only issue error for SPARK
9855 restriction on overloaded entity if the entity is not an operator.
9856
98572011-08-03 Yannick Moy <moy@adacore.com>
9858
9859 * sem_ch7.adb, sem_res.adb, sem_attr.adb, restrict.adb,
9860 restrict.ads: Rename remaining Check_Formal_Restriction* into
9861 Check_SPARK_Restriction*.
9862
98632011-08-03 Emmanuel Briot <briot@adacore.com>
9864
9865 * prj-proc.adb, prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb,
9866 prj-nmsc.ads, prj-err.adb (Project_Data): now discriminated on its
9867 qualifier.
9868 (Project_Empty): removed
9869 (Empty_Project): new parameter Qualifier
9870 This is used to have fields specific to aggregate projects, cleaner
9871 New field to store the list of aggregated projects.
9872 (Check_Aggregate_Project): removed
9873 (Process_Aggregated_Projects, Free): new subprograms.
9874
3f5a8fee
AC
98752011-08-03 Olivier Hainque <hainque@adacore.com>
9876
9877 * tracebak.c (STOP_FRAME ppc AIX): Stop at null return address as well.
9878
98792011-08-03 Ed Schonberg <schonberg@adacore.com>
9880
9881 * sem_ch8.adb (Analyze_Object_Renaming): if the renamed object is an
9882 explicit dereference of an unconstrained type, create a constrained
9883 subtype for it, as is done for function calls that return an
9884 unconstrained type.
9885
98862011-08-03 Thomas Quinot <quinot@adacore.com>
9887
9888 * g-pehage.adb (Finalize): Avoid possible double-free.
9889
98902011-08-03 Steve Baird <baird@adacore.com>
9891
9892 * exp_attr.adb (Expand_N_Attribute_Reference): Don't expand
9893 Elab_Spec/Body attrs in CodePeer_Mode.
9894
98952011-08-03 Javier Miranda <miranda@adacore.com>
9896
9897 * exp_aggr.adb (Flatten): Convert to positional form aggregates whose
9898 low bound is not known at compile time but they have no others choice.
9899 Done because in this case the bounds can be obtained directly from the
9900 aggregate.
9901
99022011-08-03 Ed Falis <falis@adacore.com>
9903
9904 * s-tasinf-vxworks.ads: Update comment to reflect 0 indexing of CPUs
9905 on VxWorks SMP. Remove unusable constant ANY_CPU.
9906
a96ca600
EB
99072011-08-03 Emmanuel Briot <briot@adacore.com>
9908
9909 * gnatcmd.adb, make.adb, prj-part.adb, prj-part.ads, prj-makr.adb,
9910 clean.adb, prj-nmsc.adb, prj-pars.adb, prj-conf.adb, prj-env.adb,
9911 prj-env.ads (Prj.Env.Initialize_Default_Project_Path,
9912 Prj.Env.Initialize_Empty): new subprograms
9913 (Get_Env, Find_Project): remove parameter Target_Name.
9914
3e582869
AC
99152011-08-03 Gary Dismukes <dismukes@adacore.com>
9916
9917 * sem_ch3.adb (Build_Derived_Record_Type): Test the Derive_Subps formal
9918 as a condition for the delayed call to Derived_Subprograms done for the
9919 case of the rewriting of a derived type that constrains the
9920 discriminants of its parent type.
9921 Avoids redundant subprogram derivations for private subtype derivations.
9922
99232011-08-03 Javier Miranda <miranda@adacore.com>
9924
9925 * exp_aggr.adb (Init_Hidden_Discriminants): New subprogram of
9926 Build_Record_Aggr_Code.
9927 (Build_Record_Aggr_Code): Add missing support to initialize hidden
9928 discriminants in extension aggregates.
9929
99302011-08-03 Emmanuel Briot <briot@adacore.com>
9931
9932 * prj-pp.adb (Print): also output project qualifiers, since in
9933 particular "aggregate" is mandatory in an aggregate project.
9934
99352011-08-03 Emmanuel Briot <briot@adacore.com>
9936
9937 * prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb, prj-env.adb:
9938 (Debug_Output): new function.
9939
56e94186
AC
99402011-08-03 Eric Botcazou <ebotcazou@adacore.com>
9941
9942 * gnat_ugn.texi: Document -Wstack-usage.
9943 * gcc-interface/misc.c (enumerate_modes): Add guard for ghost FP modes.
9944
99452011-08-03 Thomas Quinot <quinot@adacore.com>
9946
9947 * sem_prag.adb Issue an error (not a warning) when a C++ type does not
9948 have keyword LIMITED.
9949
99502011-08-03 Yannick Moy <moy@adacore.com>
9951
9952 * alfa.adb, alfa.ads, alfa_test.adb: New files.
9953 * ali.adb (Known_ALI_Lines): add 'C' lines (SCO) and 'F' lines (ALFA)
9954 (Scan_ALI): do not issue a fatal error if parsing known lines after Xref
9955 section (does not happen in compiler, only if code directly calls
9956 Scan_ALI).
9957 * get_alfa.adb, get_alfa.ads: New files.
9958 * lib-writ.adb, lib-writ.ads (Write_ALI): output ALFA information if
9959 needed.
9960 * lib-xref-alfa.adb: New file.
9961 * lib-xref.adb, lib-xref.ads
9962 (Xref_Entry): redefine information needed in cross-references for ALFA.
9963 Push ALFA treatments in separated local package.
9964 (Enclosing_Subpragram_Or_Package): treat specially subprogram
9965 identifiers. Return entity of package body instead of spec. Return
9966 Empty for a scope with no location.
9967 (Generate_Reference): adapt to new components for ALFA information.
9968 Remove the need for D references on definitions.
9969 (Is_Local_Reference): moved to ALFA local package
9970 (Output_References): extract subfunction as Extract_Source_Name
9971 (Output_Local_References): remove procedure, replaced by filtering of
9972 cross-references in package ALFA and printing in Put_ALFA.
9973 (Write_Entity_Name): remove procedure
9974 * lib.adb, lib.ads (Extract_Source_Name): extract here function to
9975 print exact name of entity as it appears in source file
9976 (Unit_Ref_Table): make type public for use in Lib.Xref.ALFA
9977 * put_alfa.adb, put_alfa.ads: New files.
9978 * xref_lib.adb (Search_Xref): protect read of cross-references against
9979 reading other sections of the ALI file, in gnatxref
9980 (Search): protect read of cross-references against reading other
9981 sections of the ALI file, in gnatfind.
9982 * gcc-interface/Make-lang.in: Update dependencies.
9983
99842011-08-03 Thomas Quinot <quinot@adacore.com>
9985
9986 * sem_ch3.adb: Minor reformatting.
9987
99882011-08-03 Jose Ruiz <ruiz@adacore.com>
9989
9990 * s-inmaop-vxworks.adb (Setup_Interrupt_Mask): Do nothing instead of
9991 raising an exception.
9992
99932011-08-03 Ed Schonberg <schonberg@adacore.com>
9994
9995 * sem_res.adb (Set_String_Literal_Subtype): if index type is an integer
9996 type, always use 1 as the lower bound or string, even if lower bound of
9997 context is not static, to handle properly null strings in a non-static
9998 context.
9999
100002011-08-03 Bob Duff <duff@adacore.com>
10001
10002 * sem_prag.adb (Resolve_Aggregate): An array aggregate with 'others' is
10003 always legal on the right-hand side of an assignment statement; there
10004 is always an applicable index constraint in this case. Therefore, the
10005 check for Pkind = N_Assignment_Statement is now unconditional -- it
10006 doesn't depend on whether Is_Constrained (Typ).
10007
4317e442
AC
100082011-08-03 Robert Dewar <dewar@adacore.com>
10009
10010 * exp_ch5.adb, sem_prag.adb, exp_ch4.adb: Minor reformatting.
10011
100122011-08-03 Ed Schonberg <schonberg@adacore.com>
10013
10014 * sem_ch3.adb (Build_Itype_Reference): do not create an itype reference
10015 for an itype created within a generic unit.
10016
100172011-08-03 Eric Botcazou <ebotcazou@adacore.com>
10018
10019 * gnat_ugn.texi (Switches for gcc): Make it clearer that -fno-inline
10020 suppresses all inlining.
10021
53f29d4f
AC
100222011-08-03 Robert Dewar <dewar@adacore.com>
10023
10024 * sem_ch3.adb, sem_res.adb, exp_ch13.adb, exp_disp.adb,
10025 exp_aggr.adb: Minor reformatting.
10026
100272011-08-03 Thomas Quinot <quinot@adacore.com>
10028
10029 * exp_ch5.adb (Expand_N_Assignment_Statement): Do not force inlining of
10030 tagged assignment when discriminant checks are suppressed. This is
10031 useless and extremely costly in terms of static stack usage.
10032
100332011-08-03 Bob Duff <duff@adacore.com>
10034
10035 * sem_prag.adb (Get_Base_Subprogram): Do not follow Alias for instances
10036 of generics, because this leads to the wrong entity in the wrong scope,
10037 causing (e.g.) pragma Export_Procedure to get an error if the entity is
10038 an instance.
10039 (Process_Interface_Name): Follow Alias for instances of generics, to
10040 correct for the above change.
10041
100422011-08-03 Ed Schonberg <schonberg@adacore.com>
10043
10044 * exp_ch4.adb (Expand_N_Selected_Component): If the discriminant value
10045 is an integer literal it is always safe to replace the reference. In
10046 addition, if the reference appears in the generated code for an object
10047 declaration it is necessary to copy because otherwise the reference
10048 might be to the uninitilized value of the discriminant of the object
10049 itself.
10050
100512011-08-03 Pascal Obry <obry@adacore.com>
10052
10053 * adaint.c (__gnat_is_executable_file_attr): Fix Win32 circuitry when no
10054 ACL used, in this case we want to check for ending .exe, not .exe
10055 anywhere in the path.
10056
100572011-08-03 Sergey Rybin <rybin@adacore.com>
10058
10059 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
10060 the tree structure (semantic decoration of references to record
10061 discriminants).
10062
c0b11850
AC
100632011-08-03 Gary Dismukes <dismukes@adacore.com>
10064
10065 * sem_aggr.adb (Analyze_Array_Aggregate): When checking the discrete
10066 choices of a named array aggregate, bail out when any choices are
10067 marked as Errors_Posted.
10068
100692011-08-03 Ed Schonberg <schonberg@adacore.com>
10070
10071 * exp_ch13.adb (Expand_N_Freeze_Entity): cleanup determination of scope
10072 in which entity is frozen, to handle properly loop variables in
10073 iterators.
10074
100752011-08-03 Ed Schonberg <schonberg@adacore.com>
10076
10077 * sem_res.adb (Set_String_Literal_Subtype): if the lower bound of the
10078 subtype is not static, compute the upper bound using attributes, to
10079 handle properly index types that are not integer types.
10080
100812011-08-03 Bob Duff <duff@adacore.com>
10082
10083 * gnat_rm.texi, gnat_ugn.texi: Fix some dangling URLs.
10084 Update copyright notice.
10085
100862011-08-03 Ed Schonberg <schonberg@adacore.com>
10087
10088 * sem_ch3.adb (Build_Discriminant_Constraints): Only use
10089 Original_Discriminant if within an instance.
10090 * sem_ch4.adb (Analyze_Selected_Component): Ditto.
10091
100922011-08-03 Thomas Quinot <quinot@adacore.com>
10093
10094 * einfo.ads: Minor reformatting.
10095
100962011-08-03 Ed Schonberg <schonberg@adacore.com>
10097
10098 * exp_disp.adb (Check_Premature_Freezing): diagnose the presence of a
10099 composite type with an unfrozen subcomponent, in the profile of a
10100 primitive operation.
10101
5c34e9cd
AC
101022011-08-03 Robert Dewar <dewar@adacore.com>
10103
10104 * sem_util.ads, exp_aggr.adb, exp_ch3.adb: Minor reformatting.
10105
101062011-08-03 Ed Schonberg <schonberg@adacore.com>
10107
10108 * sem_ch3.adb (Analyze_Object_Declaration): if a constant object of an
10109 unconstrained type with discriminants is initialized with an aggregate,
10110 use the constrained subtype of the aggregate as the type of the object,
10111 because it is immutable, and this allows the back-end to generate no
10112 code for the object declaration.
10113
abcd9db2
AC
101142011-08-03 Robert Dewar <dewar@adacore.com>
10115
10116 * exp_ch4.adb (Optimize_Length_Check): Fix bad handling of case where
10117 comparison operand is variable, and turns out to be zero or negative.
10118
101192011-08-03 Javier Miranda <miranda@adacore.com>
10120
10121 * exp_intr.adb
10122 (Expand_Dispatching_Constructor_Call): Disable expansion of
10123 code required for native targets. Done to avoid generating
10124 references to unavailable runtime entities in VM targets.
10125 * exp_ch3.adb
10126 (Expand_N_Object_Declaration): Add missing support to handle
10127 the explicit initialization of class-wide interface objects.
10128 Fix documentation.
10129
101302011-08-03 Matthew Heaney <heaney@adacore.com>
10131
7089ef0f
GP
10132 * a-cobove.adb (Merge): Move source onto target, instead of using
10133 Assign.
abcd9db2
AC
10134
101352011-08-03 Matthew Heaney <heaney@adacore.com>
10136
7089ef0f 10137 * a-cbdlli.adb (Splice): Move source items from first to last.
abcd9db2
AC
10138
101392011-08-03 Yannick Moy <moy@adacore.com>
10140
7089ef0f 10141 * sem_util.ads: Add comment.
abcd9db2
AC
10142
101432011-08-03 Javier Miranda <miranda@adacore.com>
10144
10145 * exp_aggr.adb
10146 (Expand_Record_Aggregate): In VM targets disable the expansion into
10147 assignments of aggregates whose type is not known at compile time.
10148
b474d6c3
ES
101492011-08-03 Ed Schonberg <schonberg@adacore.com>
10150
10151 * exp_ch9.adb (Build_Renamed_Formal_Declaration): common procedure for
10152 protected entries and task entries, to build the proper renaming
10153 declaration for entry formals, used in debugging.
10154 * exp_ch2.adb (Expand_Entry_Parameter): handle task and entry
10155 parameters in the same way.
10156
0580d807
AC
101572011-08-02 Robert Dewar <dewar@adacore.com>
10158
10159 * a-direct.adb, sinfo.ads, exp_ch9.adb, scng.adb, sem_util.adb,
10160 sem_util.ads, restrict.ads, par-prag.adb: Minor reformatting and/or
10161 code reorganization.
10162
101632011-08-02 Robert Dewar <dewar@adacore.com>
10164
10165 * debug.adb: Debug flag d.P to suppress length comparison optimization
10166 * exp_ch4.adb (Optimize_Length_Comparison): New routine to optimize
10167 comparison of Length by comparing First/Last instead.
10168
101692011-08-02 Matthew Heaney <heaney@adacore.com>
10170
10171 * a-cobove.ads: Code clean up.
10172
b191a125
AC
101732011-08-02 Vincent Celier <celier@adacore.com>
10174
10175 * adaint.c (file_names_case_sensitive_cache): New static int.
10176 (__gnat_get_file_names_case_sensitive): Cache the return value in
10177 file_names_case_sensitive_cache at the first invocation, to avoid
10178 multiple calls to getenv.
10179
101802011-08-02 Bob Duff <duff@adacore.com>
10181
10182 * sem_ch12.adb (Validate_Derived_Type_Instance): Implement AI05-0218-1.
10183
316a0661
AC
101842011-08-02 Yannick Moy <moy@adacore.com>
10185
10186 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_prag.adb, sem.ads,
10187 sem_util.adb, sem_util.ads, sem_res.adb, sem_ch2.adb, sem_ch4.adb,
10188 sem_ch6.adb, sem_ch11.adb: Add semantic flag In_Pre_Post_Expression to
10189 indicate that we are in a precondition or postcondition. This is used in
10190 Mark_Non_ALFA_Subprogram (renaming of Mark_Non_ALFA_Subprogram_Body) to
10191 decide whether to flag the spec or body of the current subprogram as
10192 not in ALFA.
10193
101942011-08-02 Fabien Chouteau <chouteau@adacore.com>
10195
10196 * impunit.adb: Add Ada.Execution_Time.Interrupts in the Ada2012 package
10197 list.
10198 * a-extiin.ads: New file.
10199
102002011-08-02 Bob Duff <duff@adacore.com>
10201
10202 * a-direct.adb (Rename): Implement AI05-0231-1. In particular, Rename
10203 now raises Name_Error instead of Use_Error in certain cases. The other
10204 parts of this AI were already implemented properly.
10205
f9adb9d4
AC
102062011-08-02 Vincent Celier <celier@adacore.com>
10207
10208 * link.c: Only import "auto-host.h" when building the gnattools.
10209
102102011-08-02 Yannick Moy <moy@adacore.com>
10211
10212 * sem_util.adb: Inter-unit inlining does not work for a subprogram
10213 which calls a local subprogram, so extract subprogram
10214 from Mark_Non_ALFA_Subprogram_Body.
10215
102162011-08-02 Javier Miranda <miranda@adacore.com>
10217
10218 * exp_ch9.adb
10219 (Extract_Dispatching_Call): If the type of the dispatching object is an
10220 access type then return an explicit dereference in the Object out-mode
10221 parameter.
10222
102232011-08-02 Gary Dismukes <dismukes@adacore.com>
10224
10225 * sem_ch3.adb (Analyze_Subtype_Declaration): Generate range
10226 compatibility checks for all indexes of an array subtype, not just the
10227 first. Reset Has_Dynamic_Range_Check on the subtype before each
10228 potential check to ensure that Insert_Range_Checks will not elide any
10229 of the dynamic checks.
10230
102312011-08-02 Yannick Moy <moy@adacore.com>
10232
10233 * par-prag.ad (Process_Restrictions_Or_Restriction_Warnings): recognize
10234 SPARK restriction at parsing time.
10235 * scng.adb (Scan): Generate a token Tok_SPARK_Hide for a SPARK HIDE
10236 directive only if the SPARK restriction is set for this unit.
10237
83f33150
YM
102382011-08-02 Yannick Moy <moy@adacore.com>
10239
10240 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb, sem_util.ads,
10241 sem_res.adb, sem_ch2.adb, sem_ch4.adb, sem_ch6.adb,
10242 sem_ch11.adb: Protect call to Current_Subprogram which might be costly
10243 when repeated. Rename Current_Subprogram_Is_Not_In_ALFA into
10244 Mark_Non_ALFA_Subprogram_Body.
10245 Split body of Mark_Non_ALFA_Subprogram_Body to get body small and
10246 inlined.
10247
7b98672f
YM
102482011-08-02 Yannick Moy <moy@adacore.com>
10249
10250 * sem_res.adb: Protect calls to Matching_Static_Array_Bounds which
10251 might be costly.
10252
052e0603
AC
102532011-08-02 Robert Dewar <dewar@adacore.com>
10254
10255 * exp_ch9.adb, exp_sel.adb, restrict.ads, exp_disp.adb, erroutc.ads,
10256 exp_ch3.adb: Minor reformatting.
10257
102582011-08-02 Emmanuel Briot <briot@adacore.com>
10259
10260 * adaint.c (__gnat_locate_exec_on_path): only returns executable
10261 files, not any regular file.
10262 (__gnat_locate_file_with_predicate): new subprogram.
10263
102642011-08-02 Yannick Moy <moy@adacore.com>
10265
10266 * sinfo.adb, sinfo.ads: Restrict the use of flags
10267 Has_Dynamic_Length_Check and Has_Dynamic_Range_Check to expression
10268 nodes, plus N_Subtype_Declaration for the 2nd one.
10269
4fbad0ba
AC
102702011-08-02 Sergey Rybin <rybin@adacore.com>
10271
10272 * gnat_rm.texi: Ramification of pragma Eliminate documentation
10273 - fix bugs in the description of Source_Trace;
10274 - get rid of UNIT_NAME;
10275
052e0603
AC
102762011-08-02 Javier Miranda <miranda@adacore.com>
10277
10278 * exp_ch9.adb
10279 (Build_Dispatching_Requeue): Adding support for VM targets
10280 since we cannot directly reference the Tag entity.
10281 * exp_sel.adb (Build_K): Adding support for VM targets.
10282 (Build_S_Assignment): Adding support for VM targets.
10283 * exp_disp.adb
10284 (Default_Prim_Op_Position): In VM targets do not restrict availability
10285 of predefined interface primitives to compiling in Ada 2005 mode.
10286 (Is_Predefined_Interface_Primitive): In VM targets this service is not
10287 restricted to compiling in Ada 2005 mode.
10288 (Make_VM_TSD): Generate code that declares and initializes the OSD
10289 record. Needed to support dispatching calls through synchronized
10290 interfaces.
10291 * exp_ch3.adb
10292 (Make_Predefined_Primitive_Specs): Enable generation of predefined
10293 primitives associated with synchronized interfaces.
10294 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
10295 primitives associated with synchronized interfaces.
10296
102972011-08-02 Yannick Moy <moy@adacore.com>
10298
10299 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
10300 statements hidden in SPARK if preceded by the HIDE directive
10301 (Parse_Exception_Handlers): mark each exception handler in a sequence of
10302 exception handlers as hidden in SPARK if preceded by the HIDE directive
10303 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
10304 if starting with the HIDE directive
10305 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
10306 starting with the HIDE directive; mark the declarations in a private
10307 part as hidden in SPARK if the private part starts with the HIDE
10308 directive
10309 * restrict.adb, restrict.ads
10310 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
10311 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
10312 argument node belongs to a part which is hidden in SPARK
10313 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
10314 parts in SPARK; protect the possibly costly call to
10315 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
10316 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
10317 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
10318 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
10319 Tok_SPARK_Hide.
10320 (Scan): recognize special comment starting with '#' and followed by
10321 SPARK keyword "hide" as a HIDE directive.
10322
103232011-08-02 Yannick Moy <moy@adacore.com>
10324
10325 * types.ads, erroutc.ads: Minor reformatting.
10326
103272011-08-02 Vincent Celier <celier@adacore.com>
10328
10329 * link.c: Add response file support for cross platforms.
10330
103312011-08-02 Ed Schonberg <schonberg@adacore.com>
10332
10333 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
10334 in an association, set parent field of copy before partial analysis.
10335 * sem_res.adb (Resolve_Slice): create reference to itype only when
10336 expansion is enabled.
10337
103382011-08-02 Yannick Moy <moy@adacore.com>
10339
10340 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
10341 for new flag denoting which subprogram bodies are in ALFA
10342 * restrict.adb, sem_ch7.adb: Update comment
10343 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
10344 sem_ch9.adb, sem_res.adb: Add calls to
10345 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
10346 * sem_ch6.adb (Analyze_Function_Return): add calls to
10347 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
10348 middle of the body, and extended return.
10349 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
10350 False when missing return.
10351 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
10352 to True for subprograms whose spec is in ALFA. Remove later on the flag
10353 on the entity used for a subprogram body when there exists a separate
10354 declaration.
10355 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
10356 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
10357 False, otherwise do nothing.
10358
103592011-08-02 Robert Dewar <dewar@adacore.com>
10360
10361 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
10362
103632011-08-02 Yannick Moy <moy@adacore.com>
10364
10365 * sem_ch4.ads: minor formatting.
10366
103672011-08-02 Yannick Moy <moy@adacore.com>
10368
10369 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
10370 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
10371 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
10372 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
10373 opt.ads: cleanup of SPARK mode
10374
103752011-08-02 Yannick Moy <moy@adacore.com>
10376
10377 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
10378 types.
10379 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
10380 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
10381 * sem_ch3.adb
10382 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
10383 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
10384 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
10385 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
10386 types.
10387 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
10388 non-static range.
10389 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
10390 functions whose return type is not in ALFA.
10391 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
10392 specifications.
10393 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
10394 parameter's type is not in ALFA.
10395 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
10396 types are in ALFA.
10397
103982011-08-02 Ed Schonberg <schonberg@adacore.com>
10399
10400 * sem_ch6 (Analyze_Expression_Function): treat the function as
10401 Inline_Always, and introduce a subprogram declaration for it when it is
10402 not a completion.
10403 * inline.adb (Add_Inlined_Body): recognize bodies that come from
10404 expression functions, so that the back-end can determine whether they
10405 can in fact be inlined.
10406 * sem_util.adb (Is_Expression_Function): predicate to determine whether
10407 a function body comes from an expression function.
10408
104092011-08-02 Gary Dismukes <dismukes@adacore.com>
10410
10411 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
10412 null exclusions to test Can_Never_Be_Null on the anonymous access types
10413 of the formals rather than testing the formals themselves. Exclude this
10414 check in cases where the Old_Formal is marked as a controlling formal,
10415 to avoid issuing spurious errors for bodies completing dispatching
10416 operations (due to the flag not getting set on controlling access
10417 formals in body specs).
10418 (Find_Corresponding_Spec): When checking full and subtype conformance of
10419 subprogram bodies in instances, pass Designated and E in that order, for
10420 consistency with the expected order of the formals (New_Id followed by
10421 Old_Id).
10422
104232011-08-02 Robert Dewar <dewar@adacore.com>
10424
10425 * sem_ch8.adb: Minor reformatting.
10426
104272011-08-02 Ed Schonberg <schonberg@adacore.com>
10428
10429 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
10430 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
10431 primitive operations of class-wide actuals.
10432
104332011-08-02 Javier Miranda <miranda@adacore.com>
10434
10435 * exp_atag.ads, exp_atag.adb
10436 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
10437 since its value is implicitly passed in argument Typ.
10438 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
10439 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
10440 Build_Common_Dispatching_Select_Statements.
10441
104422011-08-02 Robert Dewar <dewar@adacore.com>
10443
10444 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
10445 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
10446 Minor reformatting.
10447
104482011-08-02 Robert Dewar <dewar@adacore.com>
10449
10450 * sem_res.adb: Minor reformatting.
10451 * sem_prag.adb: Minor reformatting.
10452
104532011-08-02 Javier Miranda <miranda@adacore.com>
10454
10455 * exp_atag.adb, exp_atags.ads
10456 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
10457 by the tagged type Entity. Required to use this routine in the VM
10458 targets since we do not have available the Tag entity in the VM
10459 platforms.
10460 * exp_ch6.adb
10461 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
10462 Ada.Tags has not been previously loaded.
10463 * exp_ch7.adb
10464 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
10465 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
10466 * sem_aux.adb
10467 (Enclosing_Dynamic_Scope): Add missing support to handle the full
10468 view of enclosing scopes. Required to handle enclosing scopes that
10469 are synchronized types whose full view is a task type.
10470 * exp_disp.adb
10471 (Build_VM_TSDs): Minor code improvement to avoid generating and
10472 analyzing lists with empty nodes.
10473 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
10474 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
10475 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
10476 (Make_Disp_Timed_Select_Body): Add support for VM targets.
10477 (Make_Select_Specific_Data_Table): Add support for VM targets.
10478 (Make_VM_TSD): Generate code to initialize the SSD structure of
10479 the TSD.
10480
104812011-08-02 Yannick Moy <moy@adacore.com>
10482
10483 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
10484 cross-references section in ALI.
10485 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
10486 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
10487 Sub).
10488 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
10489 subprogram or package entity of a node
10490 (Is_Local_Reference_Type): new function returns True for references
10491 selected in local cross-references.
10492 (Lt): function extracted from Lt in Output_References
10493 (Write_Entity_Name): function extracted from Output_References
10494 (Generate_Definition): generate reference with type 'D' for definition
10495 of objects (object declaration and parameter specification), with
10496 appropriate locations and units, for use in local cross-references.
10497 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
10498 references of type 'I' for initialization in object definition.
10499 (Output_References): move part of function Lt and procedure
10500 Write_Entity_Name outside of the body. Ignore references of types 'D'
10501 and 'I' introduced for local cross-references.
10502 (Output_Local_References): new procedure to output the local
10503 cross-references sections.
10504 (Lref_Entity_Status): new array defining whether an entity is a local
10505 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
10506 with 'I' type when initialization expression is present.
10507 * get_scos.adb, get_scos.ads: Correct comments and typos
10508
105092011-08-02 Javier Miranda <miranda@adacore.com>
10510
10511 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
10512 the JVM target.
10513 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
10514 the JVM target.
10515 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
10516 TSD support.
10517
105182011-08-02 Vincent Celier <celier@adacore.com>
10519
10520 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
10521 (No_Space_Img): New function
10522 (Find_Excluded_Sources): When reading from a file, record the file name
10523 and the line number for each excluded source.
10524 (Mark_Excluded_Sources): When reporting an error, if the excluded
10525 sources were read from a file, include file name and line number in
10526 the error message.
10527
105282011-08-02 Ed Schonberg <schonberg@adacore.com>
10529
10530 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
10531
105322011-08-02 Robert Dewar <dewar@adacore.com>
10533
10534 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
10535
105362011-08-02 Javier Miranda <miranda@adacore.com>
10537
10538 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
10539 generation of TSDs to the DOTNET compiler.
10540 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
10541 generation of TSDs to the DOTNET compiler.
10542
105432011-08-02 Javier Miranda <miranda@adacore.com>
10544
10545 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
10546 record of all the tagged types declared inside library level package
10547 declarations, library level package bodies or library level subprograms.
10548 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
10549 associated with a given tagged type.
10550 (Build_VM_TSDs): New subprogram.
10551 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
10552 compilation units that are subprograms.
10553 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
10554 compilation units that are package bodies.
10555 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
10556 units that are a package declaration or a package instantiation.
10557 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
10558 reorganization to improve the error generated by the frontend when the
10559 function Ada.Tags.Secondary_Tag is not available.
10560 * rtsfind.ads (RE_Register_TSD): New runtime entity.
10561 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
10562
105632011-08-02 Javier Miranda <miranda@adacore.com>
10564
10565 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
10566
105672011-08-02 Robert Dewar <dewar@adacore.com>
10568
10569 * s-imenne.ads: Minor reformatting.
10570
105712011-08-02 Robert Dewar <dewar@adacore.com>
10572
10573 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
10574 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
10575 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
10576
105772011-08-02 Robert Dewar <dewar@adacore.com>
10578
10579 * einfo.ads (Materialize_Entity): Document this is only for renamings
10580 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
10581 required debug information in the case where we transform the object
10582 declaration into a renaming declaration.
10583 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
10584 object
10585 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
10586 Materialize_Entity.
10587
105882011-08-02 Robert Dewar <dewar@adacore.com>
10589
10590 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
10591 Suppress_Init_Procs.
10592 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
10593 Suppress_Initialization/Initialization_Suppressed.
10594 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
10595 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
10596 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
10597 * sem_prag.adb: New processing for pragma Suppress_Initialization.
10598
105992011-08-02 Robert Dewar <dewar@adacore.com>
10600
10601 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
10602 Minor reformatting.
10603
106042011-08-02 Ed Schonberg <schonberg@adacore.com>
10605
10606 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
10607 only have inheritable classwide pre/postconditions.
10608
106092011-08-02 Javier Miranda <miranda@adacore.com>
10610
10611 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
10612 * rtsfind.ads (RE_Check_TSD): New runtime entity.
10613 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
10614 checks if the external tag of a type is the same as the external tag
10615 of some other declaration.
10616
106172011-08-02 Thomas Quinot <quinot@adacore.com>
10618
10619 * s-taskin.ads: Minor reformatting.
10620
106212011-08-02 Emmanuel Briot <briot@adacore.com>
10622
10623 * g-comlin.adb (Display_Help): swap the order in which it prints the
10624 short help and the general usage.
10625
106262011-08-02 Ed Schonberg <schonberg@adacore.com>
10627
10628 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
10629 the aspect declarations and attach them to the generic copy for
10630 subsequent analysis.
10631 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
10632 declarations of the generic tree to the new subprogram declarations.
10633 * sem_attr.adb (Check_Precondition_Postcondition): recognize
10634 conditions that apply to a subprogram instance.
10635
106362011-08-02 Robert Dewar <dewar@adacore.com>
10637
10638 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
10639
106402011-08-02 Ed Schonberg <schonberg@adacore.com>
10641
10642 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
10643 private type with a tagged full view is not derived in the immediate
10644 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
10645
106462011-08-02 Robert Dewar <dewar@adacore.com>
10647
10648 * exp_ch4.adb: Minor reformatting.
10649
106502011-08-02 Ed Schonberg <schonberg@adacore.com>
10651
10652 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
10653 Ada2012 iterator, the loop will be rewritten during expansion into a
10654 while loop with a cursor and an element declaration. Do not analyze the
10655 body in this case, because if the container is for indefinite types the
10656 actual subtype of the elements will only be determined when the cursor
10657 declaration is analyzed.
10658
106592011-08-02 Arnaud Charlet <charlet@adacore.com>
10660
10661 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
10662 size/alignment related attributes in CodePeer_Mode.
10663
106642011-08-02 Gary Dismukes <dismukes@adacore.com>
10665
10666 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
10667 Prepend_Element, since this can result in the operation getting the
10668 wrong slot in the full type's dispatch table if the full type has
10669 inherited operations. The incomplete type's operation will get added
10670 to the proper position in the full type's primitives
10671 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
10672 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
10673 dispatching operations, since there are cases where nonprimitive
10674 subprograms can get added to the list of incomplete dependents (such
10675 as subprograms in nested packages).
10676 * sem_ch6.adb (Process_Formals): First, remove test for being in a
10677 private part when determining whether to add a primitive with a
10678 parameter of a tagged incomplete type to the Private_Dependents list.
10679 Such primitives can also occur in the visible part, and should not have
10680 been excluded from being private dependents.
10681 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
10682 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
10683 list of a Taft-amendment incomplete type is a primitive before issuing
10684 an error that the full type must appear in the same unit. There are
10685 cases where nonprimitives can be in the list (such as subprograms in
10686 nested packages).
10687 * sem_disp.adb (Derives_From): Use correct condition for checking that
10688 a formal's type is derived from the type of the corresponding formal in
10689 the parent subprogram (the condition was completely wrong). Add
10690 checking that was missing for controlling result types being derived
10691 from the result type of the parent operation.
10692
106932011-08-02 Yannick Moy <moy@adacore.com>
10694
10695 * errout.adb (First_Node): minor renaming
10696 * restrict.adb (Check_Formal_Restriction): put restriction warning on
10697 first node.
10698
106992011-08-02 Yannick Moy <moy@adacore.com>
10700
10701 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
10702 before accessing operands.
10703 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
10704 decide whether an initialization expression respects SPARK rules, as
10705 the plain node is the expanded one. This allows for more valid warnings
10706 to be issued.
10707 * gnat_rm.texi: Minor update.
10708
107092011-08-02 Arnaud Charlet <charlet@adacore.com>
10710
10711 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
10712 previous change.
10713
107142011-08-02 Robert Dewar <dewar@adacore.com>
10715
10716 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
10717
107182011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
10719
10720 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
10721 loop statements and the element renaming declaration with a block when
10722 the element type is controlled.
10723
107242011-08-02 Yannick Moy <moy@adacore.com>
10725
10726 * sinfo.ads: Minor formatting.
10727
107282011-08-02 Ed Schonberg <schonberg@adacore.com>
10729
10730 * sem_aggr.adb (Add_Association): if the association has a box and no
10731 expression, use the Sloc of the aggregate itself for the new
10732 association.
10733 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
10734 the Original_Node.
10735
107362011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
10737
10738 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
10739 When a container is provided via a function call, generate a renaming
10740 of the function result. This avoids the creation of a transient scope
10741 and the premature finalization of the container.
10742 * exp_ch7.adb (Is_Container_Cursor): Removed.
10743 (Wrap_Transient_Declaration): Remove the supression of the finalization
10744 of the list controller when the declaration denotes a container cursor,
10745 it is not needed.
10746
107472011-08-02 Yannick Moy <moy@adacore.com>
10748
10749 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
10750 node is from source, instead of the original node being from source.
10751 * sem_aggr.adb
10752 (Resolve_Array_Aggregate): refine the check for a static expression, to
10753 recognize also static ranges
10754 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
10755 Array_Type_Declaration): postpone the test for the type being a subtype
10756 mark after the type has been resolved, so that component-selection and
10757 expanded-name are discriminated.
10758 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
10759 to distinguish the case of an iteration scheme, so that an error is
10760 issed on a non-static range in SPARK except in an iteration scheme.
10761 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
10762 In_Iter_Schm = True.
10763 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
10764 user-defined operators so that they are allowed in renaming
10765 * sem_ch8.adb
10766 (Find_Selected_Component): refine the check for prefixing of operators
10767 so that they are allowed in renaming. Move the checks for restrictions
10768 on selector name after analysis discriminated between
10769 component-selection and expanded-name.
10770 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
10771 concatenation argument of string type if it is static.
10772 * sem_util.adb, sem_util.ads
10773 (Check_Later_Vs_Basic_Declarations): add a new function
10774 Is_Later_Declarative_Item to decice which declarations are allowed as
10775 later items, in the two different modes Ada 83 and SPARK. In the SPARK
10776 mode, add that renamings are considered as later items.
10777 (Enclosing_Package): new function to return the enclosing package
10778 (Enter_Name): correct the rule for homonyms in SPARK
10779 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
10780 from source (result of expansion) to avoid issuing wrong warnings.
10781
107822011-08-02 Ed Schonberg <schonberg@adacore.com>
10783
10784 * errout.adb: On anything but an expression First_Node returns its
10785 argument.
10786
107872011-08-02 Pascal Obry <obry@adacore.com>
10788
10789 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
10790
107912011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
10792
10793 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
10794 Set the associated loop as the related expression of internally
10795 generated cursors.
10796 * exp_ch7.adb (Is_Container_Cursor): New routine.
10797 (Wrap_Transient_Declaration): Supress the finalization of the list
10798 controller when the declaration denotes a container cursor.
10799
108002011-08-02 Yannick Moy <moy@adacore.com>
10801
10802 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
10803 command line now.
10804 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
10805 expression is a simple expression. This check cannot be performed in
10806 the semantics, so just drop it.
10807 (P_Index_Or_Discriminant_Constraint): move check that the index or
10808 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
10809 semantics. Other cases were previously checked in the semantics.
10810 * par-ch4.adb (P_Name): move checks that a selector name is not
10811 character literal or an operator symbol to Find_Selected_Component in
10812 the semantics
10813 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
10814 declarations are not placed after later declarations in a separate
10815 procedure in Sem_Util (possibly not the best choice?), to be used both
10816 during parsing, for Ada 83 mode, and during semantic analysis, for
10817 SPARK mode.
10818 * par-endh.adb (Check_End): move check that end label is not missing
10819 to Process_End_Label in the semantics
10820 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
10821 the special case for SPARK restriction
10822 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
10823 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
10824 parameter Force to issue the error message even on internal node (used
10825 for generated end label). Call Check_Restriction to check when an error
10826 must be issued. In SPARK mode, issue an error message even if the
10827 restriction is not set.
10828 (Check_Restriction): new procedure with an additional out parameter to
10829 inform the caller that a message has been issued
10830 * sem_aggr.adb: Minor modification of message
10831 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
10832 instead of issuing an error message directly
10833 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
10834 declarations are not placed after later declarations, by calling
10835 Check_Later_Vs_Basic_Declarations
10836 (Analyze_Subtype_Declaration): move here the check that an index or
10837 discriminant constraint must be a subtype mark. Change the check that
10838 a subtype of String must start at one so that it works on subtype marks.
10839 * sem_ch4.adb (Analyze_Call): move here the check that a named
10840 association cannot follow a positional one in a call
10841 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
10842 instead of issuing an error message directly
10843 * sem_ch8.adb (Find_Selected_Component): move here the check that a
10844 selector name is not a character literal or an operator symbol. Move
10845 here the check that the prefix of an expanded name cannot be a
10846 subprogram or a loop statement.
10847 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
10848 procedure called from parsing and semantics to check that basic
10849 declarations are not placed after later declarations
10850 (Process_End_Label): move here the check that end label is not missing
10851
108522011-08-02 Arnaud Charlet <charlet@adacore.com>
10853
10854 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
10855 representation clause in codepeer mode, since it confuses CodePeer and
10856 does not bring useful info.
10857
108582011-08-02 Ed Falis <falis@adacore.com>
10859
10860 * init.c: initialize fp hw on MILS.
10861
108622011-08-02 Ed Schonberg <schonberg@adacore.com>
10863
10864 * errout.adb (First_Node): for bodies, return the node itself (small
10865 optimization). For other nodes, do not check source_unit if the node
10866 comes from Standard.
10867
108682011-08-02 Robert Dewar <dewar@adacore.com>
10869
10870 * exp_ch3.adb: Minor comment additions.
10871 * sem_ch13.adb: Minor reformatting.
10872
108732011-08-02 Pascal Obry <obry@adacore.com>
10874
10875 * make.adb, makeutl.adb: Removes some superfluous directory separator.
10876
108772011-08-02 Robert Dewar <dewar@adacore.com>
10878
10879 * sem_attr.adb: Minor reformatting.
10880
108812011-08-02 Robert Dewar <dewar@adacore.com>
10882
10883 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
10884 (Has_Default_Component_Value): Removed
10885 * einfo.ads Comment updates
10886 (Has_Default_Aspect): Replaces Has_Default_Value
10887 (Has_Default_Component_Value): Removed
10888 * exp_ch13.adb
10889 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
10890 * exp_ch3.adb
10891 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
10892 (Get_Simple_Init_Val): Handle Default_Value aspect
10893 (Needs_Simple_Initialization): Handle Default_Value aspect
10894 * exp_ch3.ads: Needs_Simple_Initialization
10895 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
10896 * par-prag.adb (Pragma_Default[_Component]Value) Removed
10897 * sem_ch13.adb
10898 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
10899 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
10900 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
10901
109022011-08-02 Ed Schonberg <schonberg@adacore.com>
10903
10904 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
10905 package containing iteration primitives.
10906 exp_ch5.adb (Expand_Iterator_Loop): ditto.
10907
109082011-08-02 Ed Schonberg <schonberg@adacore.com>
10909
10910 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
10911 "of", pre-analyze expression in case it is a function call with
10912 finalization actions that must be placed ahead of the loop.
10913 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
10914 on an Ada2012 iterator, insert them ahead of the rewritten loop.
10915
109162011-08-02 Geert Bosch <bosch@adacore.com>
10917
10918 * cstand.adb (Create_Float_Types): Only consider C's long double for
10919 Long_Long_Float, in addition to double.
10920
109212011-08-02 Robert Dewar <dewar@adacore.com>
10922
10923 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
10924 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
10925 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
10926 Minor reformatting.
10927
109282011-08-02 Ed Schonberg <schonberg@adacore.com>
10929
10930 * sem_attr.adb: handle properly 'Result when it is a prefix of an
10931 indexed component.
10932
109332011-08-02 Javier Miranda <miranda@adacore.com>
10934
10935 * einfo.ads, einfo.adb
10936 (Original_Access_Type): Move this attribute to Node26 since there was
10937 an undocumented use of Node21 in E_Access_Subprogram_Type entities
10938 which causes conflicts and breaks the generation of the .NET compiler.
10939 (Interface_Name): Add missing documentation on JGNAT only uses of
10940 this attribute.
10941
109422011-08-02 Geert Bosch <bosch@adacore.com>
10943
10944 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
10945 (Find_Back_End_Float_Type): Likewise
10946 (Create_Back_End_Float_Types): Likewise
10947 (Create_Float_Types): Likewise
10948 (Register_Float_Type): Likewise
10949 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
10950 Nlist and split out type selection in new local Find_Base_Type function.
10951 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
10952 Nlist
10953 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
10954
109552011-08-02 Robert Dewar <dewar@adacore.com>
10956
10957 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
10958 alpha order).
10959 * opt.ads: Minor comment change.
10960 * sem_ch12.adb: Minor code reorganization.
10961
109622011-08-02 Gary Dismukes <dismukes@adacore.com>
10963
10964 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
10965 subtype's list of rep items to the list on the full subtype in the case
10966 where the lists are the same.
10967
109682011-08-02 Geert Bosch <bosch@adacore.com>
10969
10970 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
10971 using the one from System.Strings, which also deallocates all strings.
10972
109732011-08-02 Geert Bosch <bosch@adacore.com>
10974
10975 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
10976 function.
10977 * gcc-interface/Make-lang.in: Update dependencies.
10978
109792011-08-02 Olivier Hainque <hainque@adacore.com>
10980
10981 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
10982 end_locus.
10983
109842011-08-02 Javier Miranda <miranda@adacore.com>
10985
10986 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
10987 associated with anonymous access to subprograms.
10988
109892011-08-02 Geert Bosch <bosch@adacore.com>
10990
10991 * opt.ads
10992 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
10993 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
10994 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
10995 (Add_Symbol_Definition): Move to switch-c.adb
10996 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
10997 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
10998 (Add_Symbol_Definition): Move to switch-c.adb.
10999 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
11000 * sem_warn.adb
11001 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
11002 Move to warnsw.adb.
11003 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
11004 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
11005 Move to warnsw.adb.
11006 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
11007 (Add_Symbol_Definition): Moved from Prepcomp.
11008 * switch-c.ads: Update copyright notice. Use String_List instead of
11009 Argument_List, removing dependency on System.OS_Lib.
11010
110112011-08-02 Yannick Moy <moy@adacore.com>
11012
11013 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
11014 mode on initialization expression which does not respect SPARK
11015 restrictions.
11016 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
11017 if the tree referenced by its argument represents an initialization
11018 expression in SPARK, suitable for initializing an object in an object
11019 declaration.
11020
110212011-08-02 Javier Miranda <miranda@adacore.com>
11022
11023 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
11024 internally generated access to subprogram with its associated protected
11025 subprogram type.
11026 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
11027
110282011-08-02 Geert Bosch <bosch@adacore.com>
11029
11030 * cstand.adb (Register_Float_Type): Print information about type to
11031 register, if the Debug_Flag_Dot_B is set.
11032 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
11033 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
11034 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
11035 with a requested precision of more than Max_Digits digits and no more
11036 than Max_Base_Digits digits, if a range specification is present and the
11037 Predefined_Float_Types list has a suitable type to derive from.
11038 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
11039 case of type completion with pragma Import
11040 * sem_prag.adb
11041 (Process_Import_Predefined_Type): Processing to complete a type
11042 with pragma Import. Currently supports floating point types only.
11043 (Set_Convention_From_Pragma): Do nothing without underlying type.
11044 (Process_Convention): Guard against absence of underlying type,
11045 which may happen when importing incomplete types.
11046 (Process_Import_Or_Interface): Handle case of importing predefined
11047 types. Tweak error message.
11048
110492011-08-02 Eric Botcazou <ebotcazou@adacore.com>
11050
11051 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
11052 functions to previous change. Reorganize code slightly.
11053
110542011-08-02 Geert Bosch <bosch@adacore.com>
11055
11056 * back_end.ads (Register_Type_Proc): New call back procedure type for
11057 allowing the back end to provide information about available types.
11058 (Register_Back_End_Types): New procedure to register back end types.
11059 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
11060 available types.
11061 * cstand.adb (Back_End_Float_Types): New list for floating point types
11062 supported by the back end.
11063 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
11064 (Copy_Float_Type): New procedure to make new copies of predefined types.
11065 (Register_Float_Type): New call back procedure to populate the BEFT list
11066 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
11067 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
11068 (Create_Float_Types): New procedure to create entities for floating
11069 point types predefined in Standard, and put these and any remaining
11070 BEFTs on the Predefined_Float_Types list.
11071 * stand.ads (Predefined_Float_Types): New list for predefined floating
11072 point types that do not have declarations in package Standard.
11073
110742011-08-02 Eric Botcazou <ebotcazou@adacore.com>
11075
11076 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
11077 entity node for the unit containing the parameter.
11078 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
11079 (Add_Inlined_Subprogram): Likewise.
11080 * gcc-interface/Make-lang.in: Update dependencies.
11081
110822011-08-02 Thomas Quinot <quinot@adacore.com>
11083
11084 * s-stusta.adb (Print): Make sure Pos is always initialized to a
11085 suitable value.
11086
110872011-08-02 Geert Bosch <bosch@adacore.com>
11088
11089 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
11090
110912011-08-02 Eric Botcazou <ebotcazou@adacore.com>
11092
11093 * sem_type.adb (Covers): Move trivial case to the top and reuse the
11094 computed value of Base_Type.
11095
110962011-08-02 Yannick Moy <moy@adacore.com>
11097
11098 * restrict.adb (Check_Restriction): issue an error for any use of
11099 class-wide, even if the No_Dispatch restriction is not set.
11100 * sem_aggr.adb: Correct typos in comments and messages in formal mode
11101 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
11102 when completing a private extension, the type named in the private part
11103 is not the same as that named in the visible part.
11104 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
11105 of an inherited primitive operations of a tagged type or type extension
11106 that returns the tagged type.
11107 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
11108 function which returns True for an implicit operation inherited by the
11109 derived type declaration for the argument type.
11110 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
11111 order.
11112
111132011-08-02 Ed Schonberg <schonberg@adacore.com>
11114
11115 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
11116 Process_Bounds, to perform analysis with expansion of a range or an
11117 expression that is the iteration scheme for a loop.
11118 (Analyze_Iterator_Specification): If domain of iteration is given by a
11119 function call with a controlled result, as is the case if call returns
11120 a predefined container, ensure that finalization actions are properly
11121 generated.
11122 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
11123
111242011-08-02 Javier Miranda <miranda@adacore.com>
11125
11126 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
11127 * gcc-interface/Make-lang.in: Update dependencies.
11128
111292011-08-02 Javier Miranda <miranda@adacore.com>
11130
11131 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
11132 determine if the analysis is performed using N or Original_Node (N).
11133 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
11134 functionality of routine Is_Variable avoids code duplication.
11135 * checks.adb (Determine_Range): Handle temporaries generated by
11136 Remove_Side_Effects.
11137
111382011-08-02 Javier Miranda <miranda@adacore.com>
11139
11140 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
11141 expansion of the condition. Required since the previous analysis was
11142 done with expansion disabled (see Resolve_Quantified_Expression) and
11143 hence checks were not inserted and record comparisons have not been
11144 expanded.
11145
111462011-08-02 Ed Falis <falis@adacore.com>
11147
11148 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
11149 Update header.
11150
111512011-08-02 Bob Duff <duff@adacore.com>
11152
11153 * opt.ads: Minor comment fix.
11154
111552011-08-02 Bob Duff <duff@adacore.com>
11156
11157 * sem_ch12.adb (Analyze_Package_Instantiation,
11158 Analyze_Subprogram_Instantiation): Turn off style checking while
11159 analyzing an instance. Whatever style checks that apply to the generic
11160 unit should apply, so it makes no sense to apply them in an instance.
11161 This was causing trouble when compiling an instance of a runtime
11162 unit that violates the -gnatyO switch.
11163 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
11164 one of the two case statements, causing spurious errors.
11165
111662011-08-02 Robert Dewar <dewar@adacore.com>
11167
11168 * uname.adb: Minor reformatting.
11169 * gnatcmd.adb: Minor reformatting.
11170 * exp_attr.adb: Minor reformatting.
11171
111722011-08-02 Ed Schonberg <schonberg@adacore.com>
11173
11174 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
11175 No_Dispatching_Calls, do not look for the Assign primitive, because
11176 predefined primitives are not created in this case.
11177
111782011-08-02 Bob Duff <duff@adacore.com>
11179
11180 * stylesw.ads: Minor comment fixes.
11181
111822011-08-02 Robert Dewar <dewar@adacore.com>
11183
11184 * freeze.adb (Add_To_Result): New procedure.
11185
111862011-08-02 Jose Ruiz <ruiz@adacore.com>
11187
11188 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
11189 time, if the specific run-time routines for handling streams of strings
11190 are not available, use the default mechanism.
11191
111922011-08-02 Arnaud Charlet <charlet@adacore.com>
11193
11194 * s-regpat.ads: Fix typo.
11195
111962011-08-02 Vincent Celier <celier@adacore.com>
11197
11198 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
11199 not null, call it to create the in memory config project file without
11200 parsing an existing default config project file.
11201
112022011-08-02 Eric Botcazou <ebotcazou@adacore.com>
11203
11204 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
11205
112062011-08-02 Ed Schonberg <schonberg@adacore.com>
11207
11208 * sem_elim.adb: an abstract subprogram does not need an eliminate
11209 pragma for its descendant to be eliminable.
11210
112112011-08-02 Ed Falis <falis@adacore.com>
11212
11213 * init.c: revert to handling before previous checkin for VxWorks
11214 * s-intman-vxworks.adb: delete unnecessary declarations related to
11215 using Ada interrupt facilities for handling signals.
11216 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
11217 * s-intman-vxworks.ads: Import __gnat_install_handler as
11218 Initialize_Interrupts.
11219 * s-taprop-vxworks.adb: Delete Signal_Mask.
11220 (Abort_Handler): change construction of mask to unblock exception
11221 signals.
11222
112232011-08-02 Jerome Guitton <guitton@adacore.com>
11224
11225 * a-except-2005.adb (Raise_From_Signal_Handler): Call
11226 Debug_Raise_Exception before propagation starts.
11227
112282011-08-02 Eric Botcazou <ebotcazou@adacore.com>
11229
11230 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
11231 to Restriction_Check_Required.
11232 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
11233 * sem_res.adb (Resolve_Call): Likewise.
11234 * sem_attr.adb (Check_Stream_Attribute): Likewise.
11235
112362011-08-02 Bob Duff <duff@adacore.com>
11237
11238 * stylesw.ads: Update comment.
11239 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
11240 * errout.ads: Remove obsolete comment.
11241
112422011-08-02 Javier Miranda <miranda@adacore.com>
11243
11244 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
11245 (Set_Is_Safe_To_Reevaluate): new procedure.
11246 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
11247 assignment is allowed on safe-to-reevaluate variables.
11248 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
11249 temporary created to remove side effects in expressions that use
11250 the secondary stack as safe-to-reevaluate.
11251 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
11252 variables that are not true constants.
11253
112542011-08-02 Robert Dewar <dewar@adacore.com>
11255
11256 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
11257 sem_res.adb, sem_ch6.adb: Minor reformatting.
11258
112592011-08-02 Jerome Guitton <guitton@adacore.com>
11260
11261 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
11262
112632011-08-02 Ed Schonberg <schonberg@adacore.com>
11264
11265 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
11266 not set Overridden_Operation if subprogram is an initialization
11267 procedure.
11268
112692011-08-02 Yannick Moy <moy@adacore.com>
11270
11271 * par-ch6.adb: Correct obsolete name in comments
11272 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
11273 which takes two message arguments (existing function takes one), with
11274 second message used for continuation.
11275 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
11276 block statements that originate from a source block statement, not
11277 generated block statements
11278 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
11279 symmetry with procedure case
11280 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
11281 function to issue an error in formal mode if a package specification
11282 contains more than one tagged type or type extension.
11283 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
11284 parameters matching formals of tagged types are objects (or ancestor
11285 type conversions of objects), not general expressions. Issue an error
11286 on view conversions that are not involving ancestor conversion of an
11287 extended type.
11288 (Resolve_Type_Conversion): in formal mode, issue an error on the
11289 operand of an ancestor type conversion which is not an object
11290 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
11291 procedure so that it works also for actuals of function calls
11292 (Is_Actual_Tagged_Parameter): new function which determines if its
11293 argument is an actual parameter of a formal of tagged type in a
11294 subprogram call
11295 (Is_SPARK_Object_Reference): new function which determines if the tree
11296 referenced by its argument represents an object in SPARK
11297
112982011-08-02 Robert Dewar <dewar@adacore.com>
11299
11300 * sem_ch3.adb: Minor reformatting
11301 Minor comment addition
11302 Minor error msg text change
11303
113042011-08-02 Javier Miranda <miranda@adacore.com>
11305
11306 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
11307 function. Used to be more precise when we generate a variable plus one
11308 assignment to remove side effects in the evaluation of the Bound
11309 expressions.
11310 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
11311 of the bound expression to force its re-analysis and thus expand the
11312 associated transient scope (if required). Code cleanup replacing the
11313 previous code that declared the constant entity by an invocation to
11314 routine Force_Evaluation which centralizes this work in the frontend.
11315
113162011-08-02 Robert Dewar <dewar@adacore.com>
11317
11318 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
11319 (Base_Type): Now uses improved Is_Base_Type function
11320 * einfo.ads (Base_Type): Inline this function
11321
113222011-08-02 Robert Dewar <dewar@adacore.com>
11323
11324 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
11325 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
11326
113272011-08-02 Arnaud Charlet <charlet@adacore.com>
11328
11329 * gcc-interface/Make-lang.in: Update dependencies.
11330 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
11331 targets.
11332
113332011-08-02 Yannick Moy <moy@adacore.com>
11334
11335 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
11336 non-simple expression used in delta constraint
11337 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
11338 index constraint which is not a subtype mark
11339 * par.adb: With and use Restrict
11340 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
11341 mode on component type which is not a subtype mark and default
11342 expression on component
11343 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
11344 of string which does not have a lower index bound equal to 1
11345 (Array_Type_Declaration): issue an error in formal mode on index or
11346 component type which is not a subtype mark, and on aliased keyword on
11347 component
11348 (Derived_Type_Declaration): issue an error in formal mode on interface,
11349 limited or abstract type
11350 (Record_Type_Declaration): issue an error in formal mode on interface
11351 (Record_Type_Definition): issue an error in formal mode on tagged types
11352 and type extensions not declared in the specification of a library unit
11353 package; on null non-tagged record; on variant part
11354
113552011-08-02 Vincent Celier <celier@adacore.com>
11356
11357 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
11358 not declared for qualified library project when Library_Name is not
11359 declared, but Library_Dir is.
11360
113612011-08-02 Robert Dewar <dewar@adacore.com>
11362
11363 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
11364 pragmas (affects aspects [Component_]Default_Value
11365 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
11366 component type for the resolution
11367
113682011-08-02 Eric Botcazou <ebotcazou@adacore.com>
11369
11370 * einfo.adb (Base_Type): Tune implementation for speed.
11371
113722011-08-02 Robert Dewar <dewar@adacore.com>
11373
11374 * freeze.adb: Minor reformatting.
11375
113762011-08-02 Thomas Quinot <quinot@adacore.com>
11377
11378 * scos.ads: Update comments.
11379
113802011-08-02 Ed Schonberg <schonberg@adacore.com>
11381
11382 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
11383 base type, because the parent may be a subtype of a private type whose
11384 convention is established in a private part.
11385
113862011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
11387
11388 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
11389 statement in a block when the expansion of the return expression has
11390 created a finalization chain.
11391 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
11392 with the parent node.
11393 Add N_Extended_Return_Statement to handle the case where a transient
11394 object declaration appears in the Return_Object_Declarations list of
11395 an extended return statement.
11396
113972011-08-02 Matthew Gingell <gingell@adacore.com>
11398
11399 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
11400 unused parameter 'name'.
11401
114022011-08-02 Ed Schonberg <schonberg@adacore.com>
11403
11404 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
11405 inherited operation, check whether its alias, which is the source
11406 operastion that it renames, has been marked eliminated.
11407
114082011-08-02 Javier Miranda <miranda@adacore.com>
11409
11410 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
11411 in-mode parameter whose type is an access type since it can be used to
11412 modify its designated object. Enforce code that handles as safe an
11413 access type that is not access-to-constant but it is the result of a
11414 previous removal of side-effects.
11415 (Remove_Side_Effects): Minor code reorganization of cases which require
11416 no action. Done to incorporate documentation on new cases uncovered
11417 working in this ticket: no action needed if this routine was invoked
11418 too early and the nodes are not yet decorated.
11419 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
11420 to routine Remove_Side_Effects by calls to Force_Evaluation since they
11421 were issued with actuals that are implicitly provided by
11422 Force_Evaluation.
11423
114242011-08-02 Robert Dewar <dewar@adacore.com>
11425
11426 * sem_ch3.adb, sem_res.adb: Minor reformatting.
11427
114282011-08-02 Yannick Moy <moy@adacore.com>
11429
11430 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
11431 to issue an error in formal mode on attribute not supported in this mode
11432 (Analyze_Attribute): issue errors on standard attributes not supported
11433 in formal mode.
11434 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
11435 comment, and issue error in formal mode on modulus which is not a power
11436 of 2.
11437 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
11438 range.
11439 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
11440 subtype mark.
11441 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
11442 operator on modular type (except 'not').
11443
114442011-08-02 Robert Dewar <dewar@adacore.com>
11445
11446 * gnat_rm.texi: Minor reformatting.
11447
114482011-08-02 Arnaud Charlet <charlet@adacore.com>
11449
11450 * s-osinte-linux.ads: Minor comment update and reformatting.
11451 * i-cexten.ads: Make this unit pure, as for its parent.
11452 Will allow its usage in more contexts if needed.
11453
114542011-08-02 Robert Dewar <dewar@adacore.com>
11455
11456 * s-utf_32.ads: Minor comment fix.
11457
114582011-08-02 Ed Schonberg <schonberg@adacore.com>
11459
11460 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
11461 operation of a tagged synchronized type, handle the case where the
11462 controlling argument is overloaded.
11463
114642011-08-02 Yannick Moy <moy@adacore.com>
11465
11466 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
11467 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
11468 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
11469 SPARK mode and formal verification mode on processing SPARK restriction
11470 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
11471 requiring consistency checking.
11472
114732011-08-02 Robert Dewar <dewar@adacore.com>
11474
11475 * sem_res.adb: Minor reformatting.
11476
114772011-08-02 Robert Dewar <dewar@adacore.com>
11478
11479 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
11480 a-cforse.ads: Remove unneeded with of Ada.Containers
11481 Remove commented out pragma Inline's
11482 Move specifications of new subprograms to the actual specs
11483
114842011-08-02 Yannick Moy <moy@adacore.com>
11485
11486 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
11487 a-cforse.ads: Update comments.
11488
114892011-08-02 Ed Schonberg <schonberg@adacore.com>
11490
11491 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
11492
114932011-08-02 Robert Dewar <dewar@adacore.com>
11494
11495 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
11496 a-cforse.ads, a-cofove.ads: Minor reformatting.
11497
114982011-08-02 Claire Dross <dross@adacore.com>
11499
11500 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
11501 a-cofove.ads: Add comments.
11502
115032011-08-02 Yannick Moy <moy@adacore.com>
11504
11505 * gnat_rm.texi: Document formal containers.
11506
115072011-08-02 Emmanuel Briot <briot@adacore.com>
11508
11509 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
11510 are empty sections.
11511
115122011-08-02 Robert Dewar <dewar@adacore.com>
11513
11514 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
11515 reformatting.
11516
115172011-08-02 Robert Dewar <dewar@adacore.com>
11518
11519 * aspects.adb: New aspects Default_Value and Default_Component_Value
11520 New format of Aspect_Names table checks for omitted entries
11521 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
11522 handling of boolean aspects for derived types.
11523 New aspects Default_Value and Default_Component_Value
11524 New format of Aspect_Names table checks for omitted entries
11525 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
11526 (Has_Default_Value): New flag
11527 (Has_Default_Component_Value): New flag
11528 (Has_Default_Value): New flag
11529 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
11530 table.
11531 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
11532 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
11533 Default_Value and Default_Component_Value
11534 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
11535 New aspects Default_Value and Default_Component_Value
11536 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
11537 * sprint.adb: Print N_Aspect_Specification node when called from gdb
11538
115392011-08-02 Vincent Celier <celier@adacore.com>
11540
11541 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
11542 inherit library kind.
11543
115442011-08-02 Ed Schonberg <schonberg@adacore.com>
11545
11546 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
11547 Minor reformatting.
11548
115492011-08-02 Robert Dewar <dewar@adacore.com>
11550
11551 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
11552
115532011-08-02 Yannick Moy <moy@adacore.com>
11554
11555 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
11556
115572011-08-02 Robert Dewar <dewar@adacore.com>
11558
11559 * impunit.adb: Add comment.
11560
115612011-08-02 Yannick Moy <moy@adacore.com>
11562
11563 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
11564 qualification of aggregates in formal mode
11565 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
11566 another aggregate
11567 (Resolve_Aggregate): complete the test that an aggregate is adequately
11568 qualified in formal mode
11569
115702011-08-02 Pascal Obry <obry@adacore.com>
11571
11572 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
11573 * mlib-prj.adb: Supress warning when compiling binder generated file.
11574 (Build_Library): Supress all warnings when compiling the binder
11575 generated file.
11576
115772011-08-02 Yannick Moy <moy@adacore.com>
11578
11579 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
11580 from here...
11581 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
11582 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
11583 Add with/use clauses to make Check_Formal_Restriction visible
11584
115852011-08-02 Ed Schonberg <schonberg@adacore.com>
11586
11587 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
11588 in-parameters when type of the generic formal is private in the generic
11589 spec and non-private in the body.
11590
115912011-08-02 Claire Dross <dross@adacore.com>
11592
11593 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
11594 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
11595 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
11596 * impunit.adb, Makefile.rtl: Take new files into account.
11597
115982011-08-02 Robert Dewar <dewar@adacore.com>
11599
11600 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
11601 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
11602
116032011-08-02 Yannick Moy <moy@adacore.com>
11604
11605 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
11606 formal mode
11607 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
11608 matching static array bounds, taking into account the special case of
11609 string literals
11610 * sem_ch3.adb: Typo in comment.
11611
116122011-08-02 Yannick Moy <moy@adacore.com>
11613
11614 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
11615 which issues an error in formal mode if its argument node is originally
11616 from source
11617 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
11618 has a discriminant specification so that it does not include the case
11619 of derived types
11620 (Derived_Type_Declaration): move here the test that a derived type has a
11621 discriminant specification
11622 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
11623 first element of a component association before accessing its choices
11624 (presence of component association is not enough)
11625 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
11626 declaration is a library item before accessing the next element in a
11627 list, as library items are not member of lists
11628 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
11629 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
11630 Check_Formal_Restriction whenever possible.
11631
116322011-08-02 Ed Schonberg <schonberg@adacore.com>
11633
11634 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
11635 reference when needed.
11636
116372011-08-02 Bob Duff <duff@adacore.com>
11638
11639 * gnat_ugn.texi: Fix typo.
11640
116412011-08-02 Vincent Celier <celier@adacore.com>
11642
11643 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
11644 archive file name. Do not use the full path name of archives for Open
11645 VMS.
11646
116472011-08-02 Robert Dewar <dewar@adacore.com>
11648
11649 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
11650 Analyze_Aspect_Specifications
11651 * sem_ch13.adb
11652 (Analyze_Aspect_Specifications): New handling for boolean aspects
11653 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
11654 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
11655 sequence for Analyze_Aspect_Specifications
11656 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
11657 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
11658
116592011-08-02 Robert Dewar <dewar@adacore.com>
11660
11661 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
11662 aspects, since these no longer exist.
11663
116642011-08-02 Robert Dewar <dewar@adacore.com>
11665
11666 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
11667 semicolon, do not try to see if there are aspects following it.
11668 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
11669 aspect spec.
11670
116712011-08-02 Robert Dewar <dewar@adacore.com>
11672
11673 * sem_ch8.adb, aspects.ads: Minor reformatting.
11674
116752011-08-02 Eric Botcazou <ebotcazou@adacore.com>
11676
11677 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
11678 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
11679 extracted from...
11680 (Analyze_Aspect_Specifications): ...here. Call above procedure.
11681
116822011-08-02 Yannick Moy <moy@adacore.com>
11683
11684 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
11685 mode on subprogram declaration outside of package specification, unless
11686 it is followed by a pragma Import
11687 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
11688 Access_Type_Declaration): issue error in formal mode on access type
11689 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
11690 incomplete type
11691 (Analyze_Object_Declaration): issue error in formal mode on object
11692 declaration which does not respect SPARK restrictions
11693 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
11694 declaration which does not respect SPARK restrictions
11695 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
11696 error in formal mode on digits or delta constraint
11697 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
11698 decimal fixed point type
11699 (Derived_Type_Declaration): issue error in formal mode on derived type
11700 other than type extensions of tagged record types
11701 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
11702 with check on access definition
11703 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
11704 mode on protected definition.
11705 (Analyze_Task_Definition): issue error in formal mode on task definition
11706
117072011-08-02 Robert Dewar <dewar@adacore.com>
11708
11709 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
11710
117112011-08-02 Javier Miranda <miranda@adacore.com>
11712
11713 * sem_ch6.adb (Can_Override_Operator): New function.
11714 (Verify_Overriding_Indicator): Add missing code to check overriding
11715 indicator in operators. Fixes regression.
11716 (Check_Overriding_Indicator): Minor reformating after replacing the
11717 code that evaluates if the subprogram can override an operator by
11718 invocations to the above new function.
11719 * einfo.adb
11720 (Write_Field26_Name): Add missing code to ensure that, following
11721 the documentation in einfo.ads, this field is not shown as attribute
11722 "Static_Initialization" on non-dispatching functions.
11723
117242011-08-02 Jose Ruiz <ruiz@adacore.com>
11725
11726 * sem_res.adb (Resolve_Call): A call to
11727 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
11728 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
11729 i.e., when the second parameter is of type Time_Span.
11730
117312011-08-02 Vincent Celier <celier@adacore.com>
11732
11733 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
11734 with an archive instead of -L<library dir> -l<library name>.
11735
117362011-08-02 Ed Schonberg <schonberg@adacore.com>
11737
11738 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
11739 mark the base types In_Use in addition to making the operations
11740 use_visible.
11741
117422011-08-02 Ed Falis <falis@adacore.com>
11743
11744 * init.c: add and setup __gnat_signal_mask for the exception signals
11745 * s-inmaop-vxworks.adb: new file.
11746 * s-intman-vxworks.adb: remove unnecessary initializations and
11747 simplify remaining
11748 * s-intman-vxworks.ads: remove unnecessary variable
11749 * s-taprop-vxworks.adb: simplify signal initialization
11750
117512011-08-02 Robert Dewar <dewar@adacore.com>
11752
11753 * sem_ch8.adb: Minor code reorganization, comment updates.
11754
117552011-08-02 Robert Dewar <dewar@adacore.com>
11756
11757 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
11758 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
11759 here from Sem_Res.
11760 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
11761 (Matching_Static_Array_Bounds): Moved here from Sem_Res
11762
117632011-08-02 Ed Schonberg <schonberg@adacore.com>
11764
11765 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
11766 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
11767 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
11768 use_type_clauses, to handle more efficiently use_type and use_all_type
11769 constructs.
11770 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
11771 Ada2012 Use_All_Type clause.
11772 (Use_Class_Wide_Operations): new procedure.
11773
117742011-08-02 Robert Dewar <dewar@adacore.com>
11775
11776 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
11777 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
11778 expression to expression function.
11779
117802011-08-02 Ed Schonberg <schonberg@adacore.com>
11781
11782 * sem_ch4.adb: transform simple Ada2012 membership into equality only
11783 if types are compatible.
11784
117852011-08-02 Yannick Moy <moy@adacore.com>
11786
11787 * sem_res.adb (Matching_Static_Array_Bounds): new function which
11788 returns True if its argument array types have same dimension and same
11789 static bounds at each index.
11790 (Resolve_Actuals): issue an error in formal mode on actuals passed as
11791 OUT or IN OUT paramaters which are not view conversions in SPARK.
11792 (Resolve_Arithmetic_Op): issue an error in formal mode on
11793 multiplication or division with operands of fixed point types which are
11794 not qualified or explicitly converted.
11795 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
11796 Boolean or array type (except String) operands.
11797 (Resolve_Equality_Op): issue an error in formal mode on equality
11798 operators for array types other than String with non-matching static
11799 bounds.
11800 (Resolve_Logical_Op): issue an error in formal mode on logical operators
11801 for array types with non-matching static bounds. Factorize the code in
11802 Matching_Static_Array_Bounds.
11803 (Resolve_Qualified_Expression): issue an error in formal mode on
11804 qualified expressions for array types with non-matching static bounds.
11805 (Resolve_Type_Conversion): issue an error in formal mode on type
11806 conversion for array types with non-matching static bounds
11807
118082011-08-02 Robert Dewar <dewar@adacore.com>
11809
11810 * par-ch10.adb: Minor code reorganization (use Nkind_In).
11811
118122011-08-02 Ed Schonberg <schonberg@adacore.com>
11813
11814 * par-ch9.adb: save location of entry for proper error message.
11815
118162011-08-02 Javier Miranda <miranda@adacore.com>
11817
11818 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
11819 (Use_Full_View) which permits this routine to climb through the
11820 ancestors using the full-view of private parents.
11821 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
11822 Use_Full_View to true in calls to Is_Ancestor.
11823 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
11824 true in call to Is_Ancestor.
11825 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
11826 Use_Full_View to true in call to Is_Ancestor.
11827 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
11828 call to Is_Ancestor.
11829 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
11830 Use_Full_View to true in calls to Is_Ancestor.
11831 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
11832 Make_Select_Specific_Data_Table, Register_Primitive,
11833 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
11834 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
11835 to true in call to Is_Ancestor.
11836 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
11837 Use_Full_View to true in calls to Is_Ancestor.
11838 * exp_cg.adb
11839 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
11840 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
11841
118422011-08-02 Robert Dewar <dewar@adacore.com>
11843
11844 * gnat_rm.texi: Minor reformatting.
11845 * sem_prag.adb: Minor reformatting.
11846
118472011-08-02 Tristan Gingold <gingold@adacore.com>
11848
11849 * vms_data.ads: Add VMS qualifier for -gnateP.
11850
118512011-08-02 Robert Dewar <dewar@adacore.com>
11852
11853 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
11854 * par-ch7.adb (P_Package): Proper placement of aspects for package
11855 decl/instantiation.
11856 * par-endh.adb (Check_End): Ad Is_Sloc parameter
11857 (End_Statements): Add Is_Sloc parameterr
11858 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
11859 (Check_End): Ad Is_Sloc parameter
11860 (End_Statements): Add Is_Sloc parameterr
11861
118622011-08-02 Vincent Celier <celier@adacore.com>
11863
11864 * ug_words: Add VMS qualifier equivalent to -gnateP:
11865 /SYMBOL_PREPROCESSING.
11866
118672011-08-02 Jose Ruiz <ruiz@adacore.com>
11868
11869 * gnat-style.texi: For hexadecimal numeric literals the typical
11870 grouping of digits is 4 to represent 2 bytes.
11871 A procedure spec which is split into several lines is indented two
11872 characters.
11873
118742011-08-02 Yannick Moy <moy@adacore.com>
11875
11876 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
11877 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
11878 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
11879 properly qualified
11880 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
11881 choice in array aggregate
11882 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
11883 mark as ancestor
11884 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
11885 positional and named aggregate for record, or others in record
11886 aggregate, or multiple choice in record aggregate
11887 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
11888 array operands to logical operations AND, OR and XOR do not have the
11889 same static lower and higher bounds
11890 * sem_ch5.adb, sinfo.ads: Correct typos in comments
11891
118922011-08-01 Robert Dewar <dewar@adacore.com>
11893
11894 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
11895 Replaces Last_Source_Node_In_Sequence.
11896 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
11897 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
11898 parens and blank in string (this was inconsistently implemented).
11899 * errout.ads
11900 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
11901 blank in string (this was inconsistently implemented).
11902 * gnat1drv.adb
11903 (Set_Global_Switches): Set formal mode switches appropriately
11904 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
11905 * par-prag.adb
11906 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
11907 call Set_Error_Msg_Lang to set "spark" as language name.
11908 * par.adb: Remove unnecessary call to set formal language for errout
11909 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
11910 appropriately and call Set_Error_Msg_Lang to set "spark" as language
11911 name.
11912 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
11913 calls to it, moved after resolution so that types are known
11914 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
11915 result of concatenation is not of type String
11916 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
11917 concatenation is not properly restricted
11918 * gnat_rm.texi: Add doc on pragma Spark_95.
11919 * gcc-interface/Makefile.in: Remove obsolete target pairs for
11920 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
11921 * gcc-interface/Make-lang.in: Update dependencies.
11922
119232011-08-01 Javier Miranda <miranda@adacore.com>
11924
11925 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
11926 condition that detects if the overridden operation must replace an
11927 existing entity.
11928
119292011-08-01 Javier Miranda <miranda@adacore.com>
11930
11931 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
11932 code declarations inserted by Insert_Actions in each alternative of the
11933 N_Case_Expression node.
11934
119352011-08-01 Robert Dewar <dewar@adacore.com>
11936
11937 * sem_ch6.adb: Minor code reorganization.
11938 * sem_util.adb: Minor reformatting.
11939
119402011-08-01 Pascal Obry <obry@adacore.com>
11941
11942 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
11943 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
11944
119452011-08-01 Yannick Moy <moy@adacore.com>
11946
11947 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
11948 literal or operator symbol which is prefixed
11949 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
11950 mode on access attributes.
11951 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
11952 that concatenation operands are properly restricted in formal mode
11953 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
11954 Analyze_Concatenation_Operand. Issue an error in formal mode if the
11955 result of the concatenation has a type different from String.
11956 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
11957 Analyze_Quantified_Expression, Analyze_Slice,
11958 Analyze_Null): issue an error in formal mode on unsupported constructs
11959 * sem_ch5.adb
11960 (Analyze_Block_Statement): only issue error on source block statement
11961 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
11962 function which returns the last node in a list of nodes for which
11963 Comes_From_Source returns True, if any
11964 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
11965 Last_Source_Node_In_Sequence
11966 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
11967 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
11968 mode on unsupported constructs
11969 * sem_ch9.adb Do not return after issuing error in formal mode, as the
11970 rest of the actions may be needed later on since the error is marked as
11971 not serious.
11972 * sinfo.ads: Typos in comments.
11973
119742011-08-01 Pascal Obry <obry@adacore.com>
11975
11976 * projects.texi: Minor editing.
11977
119782011-08-01 Yannick Moy <moy@adacore.com>
11979
11980 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
11981 insertion character ~~
11982 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
11983 (Set_Error_Msg_Lang): new procedure which fixes the language for use
11984 with insertion character ~~
11985 (Set_Msg_Text): treat insertion character ~~
11986 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
11987 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
11988 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
11989 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
11990 errors related to the formal language restriction not serious
11991 (insertion character |).
11992 * par.adb (Par): set formal language for error messages if needed
11993 * sem_ch6.adb (Check_Missing_Return): take into account possible
11994 generated statements at the end of the function
11995 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
11996 enumeration value to define a new pragma SPARK_95
11997 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
11998 SPARK_Version): new type and variables to store the SPARK version
11999 (none by default).
12000 (SPARK_Mode): return True when SPARK_Version is set
12001 * par-prag.adb: Correct indentation
12002 (Prag): take Pragma_SPARK_95 into account
12003 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
12004 into account.
12005
120062011-08-01 Robert Dewar <dewar@adacore.com>
12007
12008 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
12009 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
12010 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
12011
120122011-08-01 Pascal Obry <obry@adacore.com>
12013
12014 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
12015 Target_Name to Get_Path call.
12016 (Parse_Single_Project): Likewise.
12017 (Post_Parse_Context_Clause): Likewise.
12018 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
12019 Call Initialise_Project_Path with the proper Target_Name.
12020 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
12021 search path.
12022 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
12023 with the proper Target_Name.
12024 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
12025 Part.Parse routine.
12026 (Parse_Project_And_Apply_Config): Likewise.
12027 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
12028 This is fine as this part of the code is supporting only native
12029 compilation.
12030 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
12031 is fine as this part of the code is supporting only native compilation.
12032
120332011-08-01 Yannick Moy <moy@adacore.com>
12034
12035 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
12036 of homonym, unless the homonym is one of the cases allowed in SPARK
12037 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
12038 package declaration occurring after a body.
12039
120402011-08-01 Robert Dewar <dewar@adacore.com>
12041
12042 * checks.adb, exp_ch4.adb: Minor reformatting.
12043
120442011-08-01 Javier Miranda <miranda@adacore.com>
12045
12046 * einfo.ads (Access_Disp_Table): Fix documentation.
12047 (Dispatch_Table_Wrappers): Fix documentation.
12048
120492011-08-01 Pascal Obry <obry@adacore.com>
12050
12051 * prj-env.adb, prj-env.ads: Minor reformatting.
12052
120532011-08-01 Yannick Moy <moy@adacore.com>
12054
12055 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
12056 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
12057 procedures out of these packages.
2c7f9cc0 12058 * errout.ads, errout.adb
052e0603
AC
12059 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
12060 procedures in of this package
12061 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
12062 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
12063 on misplaced later vs initial declarations, like in Ada 83
12064 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
12065 formal mode on attribute of private type whose full type declaration
12066 is not visible
12067 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
12068 package declaration inside a package specification
12069 (Analyze_Full_Type_Declaration): issue error in formal mode on
12070 controlled type or discriminant type
12071 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
12072 user-defined operator means that it should come from the source
12073 (New_Overloaded_Entity): issue error in formal mode on overloaded
12074 entity.
12075 * sem_ch6.ads, sem_ch13.ads: typos in comments.
12076
120772011-08-01 Thomas Quinot <quinot@adacore.com>
12078
12079 * atree.adb: Minor reformatting.
12080 * checks.adb: Minor reformatting.
12081
120822011-08-01 Vincent Celier <celier@adacore.com>
12083
12084 * s-parame-vms-ia64.ads: Fix typo in comment
12085 Minor reformatting
12086 * s-parame-vms-restrict.ads: Removed, unused.
12087
120882011-08-01 Javier Miranda <miranda@adacore.com>
12089
12090 * exp_ch3.adb
12091 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
12092 * sem_ch3.adb
12093 (Constrain_Index): Remove side effects in the evaluation of the bounds.
12094 * sem_ch3.ads, sem_ch3.adb
12095 (Is_Constant_Bound): New extended version of the subprogram that was
12096 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
12097 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
12098 * sem_aux.ads (Constant_Value): Fix typo in comment.
12099 * checks.adb (Generate_Index_Checks): New implementation which, for
12100 array objects with constant bounds, generates the runtime check
12101 referencing the bounds of the array type. For other cases this routine
12102 provides its previous behavior obtaining such values from the array
12103 object.
12104 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
12105 parent type.
12106 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
12107 we cannot have semantic interpretations of the new node.
12108
121092011-08-01 Ed Schonberg <schonberg@adacore.com>
12110
12111 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
12112 expressions.
12113
121142011-08-01 Arnaud Charlet <charlet@adacore.com>
12115
12116 * sem_ch8.adb: Minor code editing.
12117 * s-vxwext.adb: Remove trailing space.
12118 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
12119 consistency with other files.
12120
121212011-08-01 Thomas Quinot <quinot@adacore.com>
12122
12123 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
12124
121252011-08-01 Ed Schonberg <schonberg@adacore.com>
12126
12127 * par-ch10.adb: reject parameterized expressions as compilation unit.
12128 * sem_ch4.adb: handle properly conditional expression with overloaded
12129 then_clause and no else_clause.
12130
121312011-08-01 Tristan Gingold <gingold@adacore.com>
12132
12133 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
12134 like done by System.Aux_DEC.
12135 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
12136
121372011-08-01 Yannick Moy <moy@adacore.com>
12138
12139 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
12140 missing label at end of declaration (subprogram or package)
12141 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
12142 of positional and named parameter association
12143 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
12144 Error_Msg_SP which adds a prefix to the error message giving the name
12145 of the formal language analyzed
12146 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
12147 access result type in subprogram, unconstrained array as result type,.
12148 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
12149 procedure
12150 * sem_ch8.adb: Code clean up.
12151
121522011-08-01 Javier Miranda <miranda@adacore.com>
12153
12154 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
12155 * einfo.ads (Access_Disp_Table): Fix documentation.
12156 (Dispatch_Table_Wrappers): Fix documentation.
12157 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
12158 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
12159 to enforce the documentation of this attribute.
12160 (Set_Is_Interface): Cleanup the assertion.
12161 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
12162 the Underlying_Type entity before reading attribute Access_Disp_Table.
12163 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
12164 Locate the Underlying_Type before reading attribute Access_Disp_Table.
12165 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
12166 the Underlying_Type entity before reading attribute Access_Disp_Table.
12167 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
12168 Locate the Underlying_Type entity before reading attribute
12169 Access_Disp_Table.
12170
121712011-08-01 Ed Schonberg <schonberg@adacore.com>
12172
12173 * s-poosiz.ads: Additional overriding indicators.
12174
121752011-08-01 Yannick Moy <moy@adacore.com>
12176
12177 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
12178 formal mode.
12179 (Analyze_Iteration_Scheme): issue error in formal mode when loop
12180 parameter specification does not include a subtype mark.
12181 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
12182 formal mode on abstract subprogram.
12183 (Analyze_Subprogram_Specification): issue error in formal mode on
12184 user-defined operator.
12185 (Process_Formals): issue error in formal mode on access parameter and
12186 default expression.
12187 * sem_ch9.adb (Analyze_Abort_Statement,
12188 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
12189 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
12190 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
12191 Analyze_Requeue, Analyze_Selective_Accept,
12192 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
12193 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
12194 issue error in formal mode on user-defined raise statement.
12195
121962011-08-01 Thomas Quinot <quinot@adacore.com>
12197
12198 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
12199 declaration being hidden when overriding an implicit inherited
12200 subprogram.
12201 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
12202 (-gnats), do not complain about a source file that contains only a
12203 pragma No_Body.
12204
122052011-08-01 Ed Schonberg <schonberg@adacore.com>
12206
12207 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
12208 variable if already set.
12209
122102011-08-01 Arnaud Charlet <charlet@adacore.com>
12211
12212 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
12213 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
12214 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
12215 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
12216 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
12217 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
12218 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
12219 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
12220 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
12221 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
12222 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
12223 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
12224 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
12225 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
12226 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
12227 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
12228 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
12229 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
12230 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
12231 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
12232 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
12233 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
12234 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
12235 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
12236 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
12237 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
12238 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
12239 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
12240 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
12241 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
12242 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
12243 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
12244 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
12245 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
12246 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
12247 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
12248 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
12249 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
12250 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
12251 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
12252 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
12253 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
12254 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
12255 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
12256 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
12257 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
12258 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
12259 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
12260 s-osinte-mingw.ads: Update to GPLv3 run-time license.
12261 Use GNAT instead of GNARL.
12262
122632011-08-01 Bob Duff <duff@adacore.com>
12264
12265 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
12266 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
12267 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
12268 reformatting.
12269
122702011-08-01 Yannick Moy <moy@adacore.com>
12271
12272 * debug.adb (d.D) reverve flag for the SPARK mode
12273 (d.E) reverve flag for SPARK generation mode
12274 (d.F) reverve flag for Why generation mode
2c7f9cc0 12275 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
052e0603
AC
12276 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
12277 functions which return True when the corresponding modes are set
12278 (Formal_Language): return "spark" or "alfa" when in formal verification
12279 mode.
12280 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
12281 Error_Msg to prefix the error message with a tag giving the formal
12282 language
12283 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
12284 message with a tag giving the formal language
12285 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
12286 block statement
12287 (Analyze_Case_Statement): issue error in formal mode on case statement
12288 with a single "others" case alternative
12289 (Analyze_Exit_Statement): issue errors in formal mode on exit
12290 statements which do not respect SPARK restrictions
12291 (Analyze_Goto_Statement): issue error in formal mode on goto statement
12292 (Check_Unreachable_Code): always issue an error (not a warning) in
12293 formal mode on unreachable code (concerns both code after an infinite
12294 loop and after an unconditional jump, both not allowed in SPARK)
12295 * sem_ch6.adb (Analyze_Return_Statement): add call to
12296 Set_Return_Present for a procedure containing a return statement
12297 (already done for functions in Analyze_Function_Return)
12298 (Analyze_Function_Return): issue error in formal mode on extended
12299 return or if return is not last statement in function
12300 (Check_Missing_Return): issue error in formal mode if function does
12301 not end with return or if procedure contains a return
12302 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
12303 function to detect if there is an inner scope of its parameter S which
12304 is a loop.
12305
123062011-08-01 Thomas Quinot <quinot@adacore.com>
12307
12308 * sem_ch6.ads: Minor reformatting.
12309
123102011-08-01 Javier Miranda <miranda@adacore.com>
12311
12312 * sem_util.adb (Abstract_Interface_List): Complete condition when
12313 processing private type declarations to avoid reading unavailable
12314 attribute.
12315 (Is_Synchronized_Tagged_Type): Complete condition when processing
12316 private extension declaration nodes to avoid reading unavailable
12317 attribute.
12318
123192011-08-01 Thomas Quinot <quinot@adacore.com>
12320
12321 * sem_ch3.adb: Minor reformatting.
12322
123232011-08-01 Thomas Quinot <quinot@adacore.com>
12324
12325 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
12326 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
12327 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
12328 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
12329 for VMS, instead parametrize the common implementation with
12330 System.Parameters declarations.
12331
123322011-08-01 Eric Botcazou <ebotcazou@adacore.com>
12333
12334 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
12335
123362011-08-01 Tristan Gingold <gingold@adacore.com>
12337
12338 * seh_init.c: Fix SEH handler installation on win64.
12339
123402011-08-01 Ed Schonberg <schonberg@adacore.com>
12341
12342 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
12343 double analysis of an anonymous access to subprogram, because it can
12344 lead to improper sharing of profiles and a back-end crash.
12345
123462011-08-01 Robert Dewar <dewar@adacore.com>
12347
12348 * make.adb, sem_ch4.adb: Minor reformatting.
12349 * gcc-interface/Make-lang.in: Update dependencies.
12350 * sem_util.adb, exp_ch5.adb: Minor reformatting.
12351
123522011-08-01 Arnaud Charlet <charlet@adacore.com>
12353
12354 * gnat_rm.texi: Fix definition of Long_Integer.
12355
123562011-08-01 Ed Schonberg <schonberg@adacore.com>
12357
12358 * exp_aggr.adb: check limit size of static aggregate unconditionally,
12359 to prevent storage exhaustion.
12360 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
12361 finalized is a function body, insert the cleanup code before the final
12362 return statement, to prevent spurious warnings.
12363 * s-pooglo.ads: add overriding indicator.
12364
123652011-08-01 Ed Schonberg <schonberg@adacore.com>
12366
12367 * sem_ch4.adb (Operator_Check): improve error message when both a
12368 with_clause and a use_clause are needed to make operator usage legal.
12369 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
12370 determine whether a compilation unit is visible within an other,
12371 either through a with_clause in the current unit, or a with_clause in
12372 its library unit or one one of its parents.
12373
123742011-08-01 Ed Schonberg <schonberg@adacore.com>
12375
12376 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
12377 over an arbitrary expression of an array or container type.
12378 * lib-xref.adb: clarify comment.
12379
123802011-08-01 Bob Duff <duff@adacore.com>
12381
12382 * einfo.ads: Minor reformatting.
12383 * debug.adb: Minor comment improvement.
12384
123852011-08-01 Javier Miranda <miranda@adacore.com>
12386
12387 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
12388 consider hidden subprograms as valid candidates.
12389
123902011-08-01 Arnaud Charlet <charlet@adacore.com>
12391
12392 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
12393
123942011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
12395
12396 * gnat_ugn.texi: Fix typo.
12397
123982011-08-01 Robert Dewar <dewar@adacore.com>
12399
12400 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
12401 lib-xref.adb: Minor reformatting
12402
124032011-08-01 Gary Dismukes <dismukes@adacore.com>
12404
12405 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
12406 when to generate a call to Move_Final_List.
12407 (Has_Controlled_Parts): Remove this function.
12408
124092011-08-01 Geert Bosch <bosch@adacore.com>
12410
12411 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
12412 "," in choice list.
12413
124142011-08-01 Thomas Quinot <quinot@adacore.com>
12415
12416 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
12417 explicit raise of a predefined exception as Comes_From_Source if the
12418 original N_Raise_Statement comes from source.
12419
124202011-08-01 Robert Dewar <dewar@adacore.com>
12421
12422 * sinfo.ads: Add comment.
12423 * sem_ch6.adb: Minor reformatting.
12424
124252011-08-01 Robert Dewar <dewar@adacore.com>
12426
12427 * freeze.adb (Freeze_Entity): Refine check for bad component size
12428 clause to avoid rejecting confirming clause when atomic/aliased present.
12429
124302011-08-01 Ed Schonberg <schonberg@adacore.com>
12431
12432 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
12433 better determine whether an entity reference is a write.
12434 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
12435 subcomponent.
12436 * lib-xref.adb (Output_References): Do no suppress a read reference at
12437 the same location as an immediately preceeding modify-reference, to
12438 handle properly in-out actuals.
12439
124402011-08-01 Tristan Gingold <gingold@adacore.com>
12441
12442 * env.c (__gnat_setenv) [VMS]: Refine previous change.
12443
124442011-08-01 Quentin Ochem <ochem@adacore.com>
12445
12446 * i-cstrin.adb (New_String): Changed implementation, now uses only the
12447 heap to compute the result.
12448
124492011-08-01 Robert Dewar <dewar@adacore.com>
12450
12451 * atree.ads: Minor reformatting.
12452
124532011-08-01 Emmanuel Briot <briot@adacore.com>
12454
12455 * g-expect.adb (Get_Command_Output): Fix memory leak.
12456
124572011-08-01 Geert Bosch <bosch@adacore.com>
12458
12459 * cstand.adb (P_Float_Type): New procedure to print the definition of
12460 predefined fpt types.
12461 (P_Mixed_Name): New procedure to print a name using mixed case
12462 (Print_Standard): Use P_Float_Type for printing floating point types
12463 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
12464 precision IEEE float.
12465
124662011-08-01 Thomas Quinot <quinot@adacore.com>
12467
12468 * sem_ch3.adb: Minor reformatting.
12469
124702011-08-01 Ed Schonberg <schonberg@adacore.com>
12471
12472 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
12473 the completion of a generic function, insert the new body rather than
12474 rewriting the original.
12475
124762011-08-01 Yannick Moy <moy@adacore.com>
12477
12478 * sinfo.ads, errout.ads: Typos in comments.
12479
124802011-08-01 Robert Dewar <dewar@adacore.com>
12481
12482 * par-endh.adb: Minor reformatting.
12483
124842011-08-01 Robert Dewar <dewar@adacore.com>
12485
12486 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
12487 (Pre_Post_Aspects): New subtype.
12488 * par-ch12.adb (P_Generic): New syntax for aspects in packages
12489 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
12490 * par-ch7.adb (P_Package): Remove Decl parameter
12491 (P_Package): Handle new syntax for aspects (before IS)
12492 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
12493 new aspect syntax
12494 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
12495 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
12496 (P_Package): Remove Decl parameter
12497 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
12498 aspects
12499 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
12500 specs
12501 * sem_util.ads, sem_util.adb (Static_Boolean): New function
12502 * sinfo.ads: Document new syntax for aspects in packages etc.
12503 * sprint.adb: Handle new syntax of aspects before IS in package
12504
125052011-08-01 Thomas Quinot <quinot@adacore.com>
12506
12507 * atree.ads: Minor reformatting.
12508 * sem_prag.adb: Minor reformatting.
12509
125102011-08-01 Robert Dewar <dewar@adacore.com>
12511
12512 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
12513 case expr alternative.
12514
125152011-08-01 Ed Schonberg <schonberg@adacore.com>
12516
12517 * sem_ch12.adb: Fix typo.
12518
125192011-08-01 Geert Bosch <bosch@adacore.com>
12520
12521 * sem_prag.adb (Check_No_Link_Name): New procedure.
12522 (Process_Import_Or_Interface): Use Check_No_Link_Name.
12523 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
12524 instead of Standard_Long_Long_Float_Size global. Preparation for
12525 eventual removal of per type constants.
12526 * exp_util.ads (Get_Stream_Size): New function returning the stream
12527 size value of subtype E.
12528 * exp_util.adb (Get_Stream_Size): Implement new function.
12529 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
12530 function.
12531 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
12532 * einfo.adb:
12533 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
12534
125352011-08-01 Geert Bosch <bosch@adacore.com>
12536
12537 * cstand.adb: Fix comments.
12538 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
12539 count of arguments.
12540
125412011-08-01 Robert Dewar <dewar@adacore.com>
12542
12543 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
12544
125452011-08-01 Geert Bosch <bosch@adacore.com>
12546
12547 * atree.ads: Fix comment.
12548
125492011-08-01 Robert Dewar <dewar@adacore.com>
12550
12551 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
12552 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
12553 * par.adb: Add with for Namet.Sp.
12554 * par-tchk.adb: Minor reformatting.
12555
125562011-08-01 Vincent Celier <celier@adacore.com>
12557
12558 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
12559 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
12560 of the init procedure of a SAL.
12561 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
12562 New procedure.
12563
125642011-08-01 Thomas Quinot <quinot@adacore.com>
12565
12566 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
12567 reformatting.
12568
125692011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
12570
12571 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
12572
125732011-08-01 Thomas Quinot <quinot@adacore.com>
12574
12575 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
12576 conformant with its spec (return True only for types that have
12577 an overriding Initialize primitive operation that prevents them from
12578 having preelaborable initialization).
12579 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
12580 initialization for controlled types in Ada 2005 or later mode.
12581
125822011-08-01 Robert Dewar <dewar@adacore.com>
12583
12584 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
12585 Postcondition.
12586 (Same_Aspect): New function.
12587 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
12588 Type_Invariant, Precondition, Postcondition.
12589 * snames.ads-tmpl: Add Name_Type_Invariant.
12590
125912011-08-01 Robert Dewar <dewar@adacore.com>
12592
12593 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
12594 here.
12595 (Freeze_All_Ent): Fix error in handling inherited aspects.
12596 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
12597 already analyzed, but don't skip entire processing of a declaration,
12598 that's wrong in some cases of declarations being rewritten.
12599 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
12600 Don't delay for integer, string literals
12601 Treat predicates in usual manner for delay, remove special case code,
12602 not needed.
12603 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
12604 (Build_Predicate_Function): Update saved expression in aspect
12605 (Build_Invariant_Procedure): Update saved expression in aspect
12606 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
12607 of replacement of discriminant references if the reference is simple.
12608
126092011-08-01 Robert Dewar <dewar@adacore.com>
12610
12611 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
12612 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
12613 Static_Predicate and Dynamic_Predicate.
12614 (Build_Predicate_Function): Add processing for Static_Predicate
12615 and Dynamic_Predicate.
12616 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
12617 (From_Static_Predicate): New flag
12618 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
12619
126202011-08-01 Robert Dewar <dewar@adacore.com>
12621
12622 * usage.adb: Documentation cleanup for Ada version modes in usage.
12623 * expander.adb: Minor reformatting.
12624
126252011-08-01 Robert Dewar <dewar@adacore.com>
12626
12627 * atree.ads: Minor comment fix.
12628 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
12629 a-witeio.ads, sem_prag.adb: Minor reformatting.
12630
126312011-08-01 Doug Rupp <rupp@adacore.com>
12632
12633 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
12634 pointers. Use descrip.h header file for convenience. Add some
12635 comments.
12636
126372011-08-01 Robert Dewar <dewar@adacore.com>
12638
12639 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
12640 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
12641 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
12642 New procedure.
12643 (Check_Aspect_At_End_Of_Declarations): New procedure
12644 (Analye_Aspect_Specification): Minor changes for above procedures
12645 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
12646 specification node as well.
12647
126482011-08-01 Pascal Obry <obry@adacore.com>
12649
12650 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
12651 Windows files. Use GetFilesAttributes() in this case to check for file
12652 existence instead of returning with an error code.
12653
126542011-08-01 Vincent Celier <celier@adacore.com>
12655
12656 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
12657 High is above Source length.
12658
126592011-08-01 Robert Dewar <dewar@adacore.com>
12660
12661 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
12662
126632011-08-01 Robert Dewar <dewar@adacore.com>
12664
12665 * aspects.ads (Boolean_Aspects): New subtype.
12666 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
12667 for derived types in cases where the parent type and derived type have
12668 aspects.
12669 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
12670 with aspects when parent type also has aspects.
12671 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
12672 boolean expression at this point).
12673 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
12674 accordance with final decision on the Ada 2012 feature.
12675 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
12676
126772011-08-01 Matthew Heaney <heaney@adacore.com>
12678
12679 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
12680
126812011-08-01 Pascal Obry <obry@adacore.com>
12682
12683 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
12684 Fix Replace_Slice when High is above current string size.
12685 (Replace_Slice): Fix DL computation when High is above current
12686 string length.
12687
126882011-08-01 Gary Dismukes <dismukes@adacore.com>
12689
12690 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
12691
126922011-08-01 Matthew Heaney <heaney@adacore.com>
12693
12694 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
12695 of node.
12696
126972011-08-01 Pascal Obry <obry@adacore.com>
12698
12699 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
12700 reformatting.
12701
127022011-08-01 Ed Schonberg <schonberg@adacore.com>
12703
12704 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
12705 access to protected subprograms in generic bodies.
12706 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
12707 protected type, indicate that the convention of the subprogram is
12708 Convention_Protected, because it may be used in subsequent declarations
12709 within the protected declaration.
12710
127112011-08-01 Vincent Celier <celier@adacore.com>
12712
12713 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
12714 and "final" procedures when the name of the library is "ada", to avoid
12715 duplicate symbols "adainit" and "adafinal" in executables.
12716
127172011-08-01 Ed Schonberg <schonberg@adacore.com>
12718
12719 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
12720 quantified expression that appears within a postcondition and uses the
12721 Ada2012 'Result attribute.
12722
127232011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12724
12725 * init.c (__gnat_error_handler): Cast reason to int.
12726 (__gnat_install_handler): Explain sa_sigaction use.
12727
127282011-07-24 Eric Botcazou <ebotcazou@adacore.com>
12729
12730 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
12731 subprogram has copy-in copy-out parameters, try to promote the mode of
12732 the return type if it is passed in registers.
12733
127342011-07-24 Eric Botcazou <ebotcazou@adacore.com>
12735
12736 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
12737 left operand as addressable.
12738
127392011-07-24 Eric Botcazou <ebotcazou@adacore.com>
12740
12741 * gcc-interface/gigi.h (build_function_stub): Remove.
12742 (build_return_expr): Likewise.
12743 (convert_vms_descriptor): Declare.
12744 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
12745 (build_function_stub): Move to...
12746 * gcc-interface/utils2.c (build_return_expr): Move to...
12747 * gcc-interface/trans.c (build_function_stub): ...here.
12748 (build_return_expr): ...here.
12749 (Subprogram_Body_to_gnu): Add local variable for language_function.
12750 Disconnect the parameter attributes cache, if any, once done with it.
12751 Call end_subprog_body only after setting the end_locus.
12752 Build the stub associated with the function, if any, at the very end.
12753 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
12754 variables and streamline control flow.
12755
127562011-07-23 Arnaud Charlet <charlet@adacore.com>
12757
12758 PR ada/49819
12759 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
12760 g-trasym-dwarf.adb.
12761
127622011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12763
12764 PR bootstrap/49794
12765 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
12766 Assign to act.sa_sigaction.
12767 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
12768 current->return_address to char * before arithmetic.
12769
127702011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12771
12772 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
12773 Correct argument types.
12774 Extract code from reason.
12775 (__gnat_install_handler): Assign to act.sa_sigaction.
12776
127772011-07-21 Eric Botcazou <ebotcazou@adacore.com>
12778
12779 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
12780 (GNAT1_OBJS): ...here.
12781
127822011-07-15 Eric Botcazou <ebotcazou@adacore.com>
12783
12784 PR ada/48711
12785 * g-socthi-mingw.adb (Fill): Fix formatting.
12786
12787 * gcc-interface/gigi.h: Move around comment.
12788
127892011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
12790
12791 PR ada/46350
12792 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
12793
127942011-07-14 Florian Weimer <fw@deneb.enyo.de>
12795
12796 PR ada/48711
12797 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
12798
127992011-07-13 Eric Botcazou <ebotcazou@adacore.com>
12800
12801 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
12802 range comparison if Pmode is SImode.
12803
128042011-07-12 Laurent GUERBY <laurent@guerby.net>
12805 Eric Botcazou <ebotcazou@adacore.com>
12806
12807 * adadecode.c: Wrap up in extern "C" block.
12808 * adadecode.h: Likewise.
12809 * adaint.c: Likewise. Remove 'const' keyword.
12810 * adaint.h: Likewise.
12811 * argv.c: Likewise.
12812 * atree.h: Likewise.
12813 * cio.c: Likewise.
12814 * cstreams.c: Likewise.
12815 * env.c: Likewise.
12816 * exit.c: Likewise.
12817 * fe.h: Likewise.
12818 * final.c: Likewise.
12819 * init.c: Likewise.
12820 * initialize.c: Likewise.
12821 * link.c: Likewise.
12822 * namet.h: Likewise.
12823 * nlists.h: Likewise.
12824 * raise.c: Likewise.
12825 * raise.h: Likewise.
12826 * repinfo.h: Likewise.
12827 * seh_init.c: Likewise.
12828 * targext.c: Likewise.
12829 * tracebak.c: Likewise.
12830 * uintp.h: Likewise.
12831 * urealp.h: Likewise.
12832 * xeinfo.adb: Wrap up generated C code in extern "C" block.
12833 * xsinfo.adb: Likewise.
12834 * xsnamest.adb: Likewise.
12835 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
12836 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
12837 * gcc-interface/misc.c: Likewise.
12838 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
12839 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
12840 ada/targext.o here...
12841 (GNAT_ADA_OBJS): ...and not here.
12842 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
12843 (GNATBIND_OBJS): Reorder.
12844
128452011-07-07 Richard Henderson <rth@redhat.com>
12846
12847 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
12848 dwarf2out_frame_init.
12849
128502011-07-07 Eric Botcazou <ebotcazou@adacore.com>
12851
12852 * gcc-interface/misc.c (gnat_init): Tweak previous change.
12853
128542011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12855
12856 PR target/39150
12857 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
12858
128592011-07-06 Richard Guenther <rguenther@suse.de>
12860
12861 * gcc-interface/misc.c (gnat_init): Merge calls to
12862 build_common_tree_nodes and build_common_tree_nodes_2.
12863 Re-initialize boolean_false_node.
12864
128652011-07-02 Eric Botcazou <ebotcazou@adacore.com>
12866 Olivier Hainque <hainque@adacore.com>
12867 Nicolas Setton <setton@adacore.com>
12868
12869 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
12870 the type according to the ARTIFICIAL_P parameter.
12871 (create_type_decl): Likewise.
12872 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
12873
128742011-07-01 Eric Botcazou <ebotcazou@adacore.com>
12875
12876 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
12877 (gnatbind): Likewise.
12878
128792011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12880
12881 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
12882
128832011-06-18 Eric Botcazou <ebotcazou@adacore.com>
12884
12885 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
12886 local variable throughout. Remove useless call to Base_Type.
12887 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
12888 Take it also into account for the volatileness of the field. Set the
12889 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
12890
128912011-06-18 Eric Botcazou <ebotcazou@adacore.com>
12892
12893 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
12894 on a dereference built for a by-ref object if it has an address clause.
12895
128962011-06-18 Eric Botcazou <ebotcazou@adacore.com>
12897
12898 * einfo.ads (Address_Taken): Document use for the second argument of
12899 Asm_Input and Asm_Output attributes.
12900 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
12901 argument is an entity name, then set Address_Taken on it.
12902 <Attribute_Asm_Output>: Likewise.
12903 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
12904 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
12905 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
12906 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
12907
129082011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
12909
12910 PR middle-end/46500
12911 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
12912
129132011-06-14 Joseph Myers <joseph@codesourcery.com>
12914
12915 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
12916 (ada/utils.o): Update dependencies.
12917 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
12918 ../../../libcpp/libcpp.a.
12919 * gcc-interface/utils.c: Include common/common-target.h.
12920 (process_attributes): Use targetm_common.have_named_sections.
12921
129222011-06-07 Richard Guenther <rguenther@suse.de>
12923
12924 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
12925 set_sizetype.
12926
129272011-06-06 Eric Botcazou <ebotcazou@adacore.com>
12928
12929 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
12930 TREE_THIS_NOTRAP flag.
12931
129322011-06-06 Eric Botcazou <ebotcazou@adacore.com>
12933
12934 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
12935 Fix thinko.
12936
129372011-06-06 Eric Botcazou <ebotcazou@adacore.com>
12938
12939 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
12940 constants whose full view has discriminants specially.
12941
129422011-06-06 Eric Botcazou <ebotcazou@adacore.com>
12943
12944 * gcc-interface/utils.c: Include diagnostic.h.
12945 (gnat_write_global_declarations): Output debug information for all
12946 global type declarations before finalizing the compilation unit.
12947 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
12948
129492011-05-25 Jakub Jelinek <jakub@redhat.com>
12950
12951 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
12952
129532011-05-25 Kai Tietz <ktietz@redhat.com>
12954
12955 * adaint.c (__gnat_to_canonical_file_list_next): Use array
12956 initialization instead of const/none-const pointer assignment.
12957
129582011-05-24 Joseph Myers <joseph@codesourcery.com>
12959
12960 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
12961 $(EXTRA_GNAT1_OBJS).
12962 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
12963 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
12964 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
12965 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
12966 libcommon-target.a instead of prefix.o.
12967
129682011-05-21 Joseph Myers <joseph@codesourcery.com>
12969
12970 PR ada/49097
12971 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
12972
129732011-05-20 Joseph Myers <joseph@codesourcery.com>
12974
12975 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
12976 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
12977 instead of version.o.
12978
2d0dd51a 129792011-05-18 Kai Tietz <ktietz@redhat.com>
052e0603
AC
12980
12981 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
12982 boolean_false_node instead of integer_zero_node.
12983 (convert_with_check): Likewise.
12984 * gcc-interface/decl.c (choices_to_gnu): Likewise.
12985
129862011-05-12 Eric Botcazou <ebotcazou@adacore.com>
12987
12988 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
12989 type of the parameter is an unconstrained array, convert the actual to
12990 the type of the formal in the In Out and Out cases as well.
12991
129922011-05-11 Nathan Froyd <froydnj@codesourcery.com>
12993
12994 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
12995 call build_function_type_array or build_varargs_function_type_array
12996 instead.
12997 (create_subprog_type): Don't call build_function_type; call
12998 build_function_type_vec instead.
12999
130002011-05-11 Nathan Froyd <froydnj@codesourcery.com>
13001
13002 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
13003 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
13004 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
13005
130062011-05-07 Eric Botcazou <ebotcazou@adacore.com>
13007
13008 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
13009
13010 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
13011 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
13012
130132011-05-05 Nathan Froyd <froydnj@codesourcery.com>
13014
13015 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
13016
130172011-05-05 Nathan Froyd <froydnj@codesourcery.com>
13018
13019 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
13020 instead of accessing TYPE_ARG_TYPES directly.
13021 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
13022
130232011-05-05 Eric Botcazou <ebotcazou@adacore.com>
13024
13025 PR ada/48844
13026 * gcc-interface/gigi.h (get_variant_part): Declare.
13027 * gcc-interface/decl.c (get_variant_part): Make global.
13028 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
13029 types have the same constant size, are record types and T1 has a
13030 variant part while T2 doesn't.
13031
130322011-05-05 Eric Botcazou <ebotcazou@adacore.com>
13033
13034 * gcc-interface/utils.c (begin_subprog_body): Do not call
13035 get_pending_sizes.
13036 (end_subprog_body): Likewise.
13037
130382011-05-04 Richard Guenther <rguenther@suse.de>
13039
13040 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
13041 int_const_binop.
13042 (pos_to_constructor): Likewise.
13043
130442011-05-03 Nathan Froyd <froydnj@codesourcery.com>
2c7f9cc0 13045 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
13046
13047 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
13048 of build_function_type. Adjust calls to...
13049 (build_raise_check): ...this. Do not take a void_tree parameter.
13050 Call build_function_type_list instead of build_function_type.
13051 Fix head comment and swap couple of conditional blocks.
13052
130532011-04-30 Eric Botcazou <ebotcazou@adacore.com>
13054
13055 * gnatvsn.ads (Library_Version): Bump to 4.7.
13056 (Current_Year): Bump to 2011.
13057
130582011-04-29 Michael Matz <matz@suse.de>
13059
13060 * gcc-interface/misc.c (gnat_handle_option): Set
13061 warn_maybe_uninitialized.
13062
130632011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
13064
13065 * gnat_ugn.texi (Complexity Metrics Control): Update link to
13066 the Watson/McCabe paper.
13067
130682011-04-23 Jim Meyering <meyering@redhat.com>
13069
13070 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
13071
130722011-04-22 Eric Botcazou <ebotcazou@adacore.com>
13073
13074 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
13075 onto the new type.
13076
130772011-04-22 Eric Botcazou <ebotcazou@adacore.com>
13078
13079 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
13080 parameter.
13081 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
13082 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
13083 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
13084 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
13085 <all>: Do not set flags on the reused DECL node coming from an alias.
13086 Set DECL_IGNORED_P on the DECL node built for subprograms if they
13087 don't need debug info here...
13088 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
13089 (gigi): Adjust calls to create_subprog_decl.
13090 (build_raise_check): Likewise.
13091 (establish_gnat_vms_condition_handler): Likewise.
13092 (Compilation_Unit_to_gnu): Likewise.
13093 (gnat_to_gnu): Likewise.
13094
130952011-04-21 Eric Botcazou <ebotcazou@adacore.com>
13096
13097 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
13098 (NO_REORDER_ADAFLAGS): New variable.
13099 (EXTRA_GNATTOOLS): Always define.
13100 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
13101 Clean up and adjust list of files compiled with special options.
13102 * gcc-interface/Make-lang.in: Likewise.
13103 (ada/decl.o): Cosmetical change.
13104 (ada/misc.o): Remove dependency on $(PLUGIN_H).
13105
131062011-04-20 Jim Meyering <meyering@redhat.com>
13107
13108 * initialize.c (__gnat_initialize): Remove useless if-before-free.
13109
131102011-04-17 Eric Botcazou <ebotcazou@adacore.com>
13111
13112 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
13113 $(CFLAGS) on the link line.
13114
131152011-04-17 Eric Botcazou <ebotcazou@adacore.com>
13116
13117 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
13118 padded type built for the return type if it is unconstrained.
13119
131202011-04-14 Nathan Froyd <froydnj@codesourcery.com>
13121
13122 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
13123
131242011-04-12 Nathan Froyd <froydnj@codesourcery.com>
13125
13126 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
13127 before calling TREE_CHAIN.
13128 * gcc-interface/misc.c (gnat_init_ts): New function.
13129 (LANG_HOOKS_INIT_TS): Define.
13130
131312011-04-12 Martin Jambor <mjambor@suse.cz>
13132
13133 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
13134 instead of cgraph_node.
13135
131362011-04-08 Eric Botcazou <ebotcazou@adacore.com>
13137
13138 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
13139 alignment on fields of the RETURN type built for the Copy-In Copy-Out
13140 mechanism.
13141
131422011-04-08 Eric Botcazou <ebotcazou@adacore.com>
13143
13144 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
13145 of aggregate types that contain a placeholder.
13146
131472011-04-08 Nathan Froyd <froydnj@codesourcery.com>
13148
13149 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
13150 TYPE_ARG_TYPES.
13151 (handle_type_generic_attribute): Likewise.
13152
131532011-04-04 Eric Botcazou <ebotcazou@adacore.com>
13154
13155 PR ada/47163
13156 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
13157
131582011-04-04 Kai Tietz <ktietz@redhat.com>
13159
13160 PR ada/47163
13161 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
13162 to flag value.
13163
131642011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13165
13166 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
13167 type case, do not strip a padding type around the array type.
13168
131692011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13170
13171 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
13172 types.
13173
131742011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13175
13176 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
13177 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
13178 code for -feliminate-unused-debug-types.
13179 (gnat_post_options): Likewise.
13180
131812011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13182
13183 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
13184 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
13185 distinct copy.
13186
131872011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13188
13189 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
13190 DECL_ARTIFICIAL flag on enumeration types.
13191
131922011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13193
13194 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
13195 fat pointer types artificial unconditionally.
13196 <E_Array_Subtype>: Attach the base array type as a parallel type if it
13197 isn't artificial.
13198
131992011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13200
13201 * gcc-interface/gigi.h (get_dummy_type): Declare.
13202 (build_dummy_unc_pointer_types): Likewise.
13203 (finish_fat_pointer_type): Likewise.
13204 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
13205 fat pointer type has been built, complete it in place.
13206 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
13207 and thin pointers. Remove useless variable.
13208 (finish_fat_pointer_type): Make global and move to...
13209 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
13210 (get_dummy_type): New function.
13211 (build_dummy_unc_pointer_types): Likewise.
13212 (gnat_pushdecl): Propage the name to the anonymous variants only.
13213 (update_pointer_to): Only adjust the pointer types in the unconstrained
13214 array case.
13215
132162011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13217
13218 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
13219 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
13220 if this is a Taft amendment type and the full declaration is available.
13221 * gcc-interface/trans.c (process_type): Likewise.
13222 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
13223 (process_freeze_entity): Likewise.
13224 * gcc-interface/utils.c (dummy_global): New static variable.
13225 (gnat_write_global_declarations): If there are types declared as used
13226 at the global level, insert them in the global hash table.
13227
132282011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13229
13230 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
13231 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
13232 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
13233 copy.
13234 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
13235 flag of the type accordingly.
13236 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
13237
132382011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13239
13240 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
13241 finalizing types when updating the pointers to the designated type.
13242 <all>: Finalize the deferred types even if we didn't defer processing
13243 of incomplete types in this invocation.
13244
132452011-04-01 Olivier Hainque <hainque@adacore.com>
2c7f9cc0
AS
13246 Nicolas Setton <setton@adacore.com>
13247 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
13248
13249 * gcc-interface/misc.c (gnat_descriptive_type): New function.
13250 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
13251
132522011-03-28 Kai Tietz <ktietz@redhat.com>
13253
13254 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
13255 Windows targets.
13256 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
13257 * system-mingw.ads (System): Change ZCX_By_Default default to True.
13258
13259 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
13260
132612011-03-28 Tristan Gingold <gingold@adacore.com>
13262
13263 PR ada/44431
13264 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
13265 Use ada output of gnatbind.
13266 (ada/b_gnatb.adb): Ditto.
13267 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
13268 (ada.mostlyclean, ada.stage1)
13269 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
13270 (ada.stagefeedback): Adjust.
13271 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
13272 Use ada output of gnatbind.
13273 (b_gnatm.adb): Ditto.
13274 (b_gnatl.o, b_gnatm.o): New rules.
13275
132762011-03-26 Eric Botcazou <ebotcazou@adacore.com>
13277
13278 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
13279 for the padded type built to support a specified size or alignment.
13280
132812011-03-26 Eric Botcazou <ebotcazou@adacore.com>
13282
13283 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
13284 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
13285 unconditionally to the end of the unit when the designated type is
13286 limited_with'ed.
13287 <all>: Rename local variable. Attempt to un-defer types only and do it
13288 for limited_with'ed types as well.
13289 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
13290 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
13291 consistently and remove redundant call to finalize_from_with_types.
13292
132932011-03-26 Eric Botcazou <ebotcazou@adacore.com>
13294
13295 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
13296 subprograms without a previous spec declared in the same unit.
13297 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
13298 subprograms at the end of the unit instead of at the beginning.
13299 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
13300 isn't public for the special handling of non-inline functions nested
13301 inside inline external functions.
13302
133032011-03-25 Jeff Law <law@redhat.com>
13304
13305 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
13306
133072011-03-24 Eric Botcazou <ebotcazou@adacore.com>
13308
13309 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
13310 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
13311 to compute Set_Size_Depends_On_Discriminant.
13312 (Layout_Type): Call it on array types in back-end layout mode.
13313 * sem_util.adb (Requires_Transient_Scope): Return true for array
13314 types only if the size depends on the value of discriminants.
13315 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
13316 type if the RHS is a call to a function that returns an unconstrained
13317 type with default discriminant.
13318
133192011-03-24 Eric Botcazou <ebotcazou@adacore.com>
13320
13321 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
13322 non-conversion to the nominal result type at the end.
13323
133242011-03-23 Eric Botcazou <ebotcazou@adacore.com>
13325
13326 * gcc-interface/trans.c (create_temporary): New function taken from...
13327 (create_init_temporary): ...here. Call it.
13328 (call_to_gnu): Create the temporary for the return value early, if any.
13329 Create it for a function with copy-in/copy-out parameters if there is
13330 no target; in other cases of copy-in/copy-out, use another temporary.
13331 Push the new binding level lazily. Add and rename local variables.
13332
133332011-03-23 Eric Botcazou <ebotcazou@adacore.com>
13334
13335 * gcc-interface/decl.c (validate_size): Improve comments and tweak
13336 error message.
13337 (set_rm_size): Likewise.
13338
133392011-03-23 Eric Botcazou <ebotcazou@adacore.com>
13340
13341 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
13342 for the padded type built in order to support a specified alignment.
13343 Fix incorrect formatting.
13344
133452011-03-21 Eric Botcazou <ebotcazou@adacore.com>
13346
13347 PR bootstrap/48216
13348 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
13349
133502011-03-21 Eric Botcazou <ebotcazou@adacore.com>
13351
13352 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
13353 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
13354 to the end of the list. Adjust recursive call. Rename local variable.
13355 If REORDER is true, reorder components of the record type.
13356 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
13357 components_to_record and adjust the parameter list.
13358
133592011-03-21 Eric Botcazou <ebotcazou@adacore.com>
13360
13361 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
13362 disabled, use the variable for bounds of loop iteration scheme.
13363
133642011-03-21 Kai Tietz <ktietz@redhat.com>
13365
13366 PR target/12171
13367 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
13368
133692011-03-17 Eric Botcazou <ebotcazou@adacore.com>
13370
13371 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
13372 out whether the expression is read-only. Short-circuit placeholder
13373 case and rename a couple of local variables.
13374
133752011-03-17 Eric Botcazou <ebotcazou@adacore.com>
13376
13377 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
13378 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
13379 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
13380 (convert): Deal with conversions from a smaller form type specially.
13381
133822011-02-14 Eric Botcazou <ebotcazou@adacore.com>
13383
13384 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
13385 its argument, except for the special -I- switch.
13386
133872011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
13388
13389 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
13390 "Ada Issues".
13391
133922011-02-08 Eric Botcazou <ebotcazou@adacore.com>
13393
13394 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
13395
133962011-02-03 Eric Botcazou <ebotcazou@adacore.com>
13397
13398 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
13399 GNAT_FORMAL.
13400 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
13401 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
13402 instead of GNAT_FORMAL. Protect the expression against multiple uses.
13403 Do not generate the check directly, instead instantiate the template
13404 check present in the descriptor.
13405 (make_descriptor_field): Move around.
13406 (build_vms_descriptor32): Build a template check in the POINTER field.
13407 (build_vms_descriptor): Remove useless suffixes.
13408 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
13409
134102011-01-26 Eric Botcazou <ebotcazou@adacore.com>
13411
13412 PR bootstrap/47467
13413 * targext.c: Include target files if IN_RTS is defined.
13414
134152011-01-26 Richard Guenther <rguenther@suse.de>
13416
13417 PR bootstrap/47467
13418 * targext.c: Include config.h.
13419 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
13420 dependency.
13421
134222011-01-04 Pascal Obry <obry@adacore.com>
2c7f9cc0 13423 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
13424
13425 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
13426
134272011-01-04 Eric Botcazou <ebotcazou@adacore.com>
13428
13429 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
13430 end-of-case on the end label and its associated gotos, if any.
13431
134322011-01-04 Eric Botcazou <ebotcazou@adacore.com>
13433
13434 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
13435 expressions of the parameter cache within the statement group of
13436 the CICO mechanism.
13437
134382011-01-04 Olivier Hainque <hainque@adacore.com>
2c7f9cc0 13439 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
13440
13441 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
13442 (set_end_locus_from_node): New function.
13443 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
13444 make and the function end_locus.
13445 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
13446 for the elaboration subprogram.
13447 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
13448 set the end_locus of the expression as well.
13449
134502011-01-04 Eric Botcazou <ebotcazou@adacore.com>
13451
13452 PR ada/47131
13453 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
13454 variables that are referenced in exception handlers volatile.
13455
13456
13457\f
13458Copyright (C) 2011 Free Software Foundation, Inc.
13459
13460Copying and distribution of this file, with or without modification,
13461are permitted in any medium without royalty provided the copyright
13462notice and this notice are preserved.
13463
13464 * gnat_rm.texi: Ramification of pragma Eliminate documentation
13465 - fix bugs in the description of Source_Trace;
13466 - get rid of UNIT_NAME;
13467
4fbad0ba
AC
134682011-08-02 Javier Miranda <miranda@adacore.com>
13469
13470 * exp_ch9.adb
13471 (Build_Dispatching_Requeue): Adding support for VM targets
13472 since we cannot directly reference the Tag entity.
13473 * exp_sel.adb (Build_K): Adding support for VM targets.
13474 (Build_S_Assignment): Adding support for VM targets.
13475 * exp_disp.adb
13476 (Default_Prim_Op_Position): In VM targets do not restrict availability
13477 of predefined interface primitives to compiling in Ada 2005 mode.
13478 (Is_Predefined_Interface_Primitive): In VM targets this service is not
13479 restricted to compiling in Ada 2005 mode.
13480 (Make_VM_TSD): Generate code that declares and initializes the OSD
13481 record. Needed to support dispatching calls through synchronized
13482 interfaces.
13483 * exp_ch3.adb
13484 (Make_Predefined_Primitive_Specs): Enable generation of predefined
13485 primitives associated with synchronized interfaces.
13486 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
13487 primitives associated with synchronized interfaces.
13488
134892011-08-02 Yannick Moy <moy@adacore.com>
13490
13491 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
13492 statements hidden in SPARK if preceded by the HIDE directive
13493 (Parse_Exception_Handlers): mark each exception handler in a sequence of
13494 exception handlers as hidden in SPARK if preceded by the HIDE directive
13495 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
13496 if starting with the HIDE directive
13497 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
13498 starting with the HIDE directive; mark the declarations in a private
13499 part as hidden in SPARK if the private part starts with the HIDE
13500 directive
13501 * restrict.adb, restrict.ads
13502 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
13503 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
13504 argument node belongs to a part which is hidden in SPARK
13505 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
13506 parts in SPARK; protect the possibly costly call to
13507 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
13508 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
13509 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
13510 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
13511 Tok_SPARK_Hide.
13512 (Scan): recognize special comment starting with '#' and followed by
13513 SPARK keyword "hide" as a HIDE directive.
13514
135152011-08-02 Yannick Moy <moy@adacore.com>
13516
13517 * types.ads, erroutc.ads: Minor reformatting.
13518
135192011-08-02 Vincent Celier <celier@adacore.com>
13520
13521 * link.c: Add response file support for cross platforms.
13522
6ff6152d
ES
135232011-08-02 Ed Schonberg <schonberg@adacore.com>
13524
13525 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
13526 in an association, set parent field of copy before partial analysis.
13527 * sem_res.adb (Resolve_Slice): create reference to itype only when
13528 expansion is enabled.
13529
975c6896
YM
135302011-08-02 Yannick Moy <moy@adacore.com>
13531
13532 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
13533 for new flag denoting which subprogram bodies are in ALFA
13534 * restrict.adb, sem_ch7.adb: Update comment
13535 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
13536 sem_ch9.adb, sem_res.adb: Add calls to
13537 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
13538 * sem_ch6.adb (Analyze_Function_Return): add calls to
13539 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
13540 middle of the body, and extended return.
13541 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
13542 False when missing return.
13543 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
13544 to True for subprograms whose spec is in ALFA. Remove later on the flag
13545 on the entity used for a subprogram body when there exists a separate
13546 declaration.
13547 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
13548 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
13549 False, otherwise do nothing.
13550
afc8324d
AC
135512011-08-02 Robert Dewar <dewar@adacore.com>
13552
13553 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
13554
135552011-08-02 Yannick Moy <moy@adacore.com>
13556
13557 * sem_ch4.ads: minor formatting.
13558
2ba431e5
YM
135592011-08-02 Yannick Moy <moy@adacore.com>
13560
13561 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
13562 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
13563 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
13564 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
13565 opt.ads: cleanup of SPARK mode
13566
0f853035
YM
135672011-08-02 Yannick Moy <moy@adacore.com>
13568
13569 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
13570 types.
13571 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
13572 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
13573 * sem_ch3.adb
13574 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
13575 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
13576 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
13577 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
13578 types.
13579 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
13580 non-static range.
13581 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
13582 functions whose return type is not in ALFA.
13583 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
13584 specifications.
13585 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
13586 parameter's type is not in ALFA.
13587 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
13588 types are in ALFA.
13589
d2b10647
ES
135902011-08-02 Ed Schonberg <schonberg@adacore.com>
13591
13592 * sem_ch6 (Analyze_Expression_Function): treat the function as
13593 Inline_Always, and introduce a subprogram declaration for it when it is
13594 not a completion.
13595 * inline.adb (Add_Inlined_Body): recognize bodies that come from
13596 expression functions, so that the back-end can determine whether they
13597 can in fact be inlined.
13598 * sem_util.adb (Is_Expression_Function): predicate to determine whether
13599 a function body comes from an expression function.
13600
c7b9d548
AC
136012011-08-02 Gary Dismukes <dismukes@adacore.com>
13602
13603 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
13604 null exclusions to test Can_Never_Be_Null on the anonymous access types
13605 of the formals rather than testing the formals themselves. Exclude this
13606 check in cases where the Old_Formal is marked as a controlling formal,
13607 to avoid issuing spurious errors for bodies completing dispatching
13608 operations (due to the flag not getting set on controlling access
13609 formals in body specs).
13610 (Find_Corresponding_Spec): When checking full and subtype conformance of
13611 subprogram bodies in instances, pass Designated and E in that order, for
13612 consistency with the expected order of the formals (New_Id followed by
13613 Old_Id).
13614
136152011-08-02 Robert Dewar <dewar@adacore.com>
13616
13617 * sem_ch8.adb: Minor reformatting.
13618
1138cf59
AC
136192011-08-02 Ed Schonberg <schonberg@adacore.com>
13620
13621 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
13622 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
13623 primitive operations of class-wide actuals.
13624
136252011-08-02 Javier Miranda <miranda@adacore.com>
13626
13627 * exp_atag.ads, exp_atag.adb
13628 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
13629 since its value is implicitly passed in argument Typ.
13630 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
13631 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
13632 Build_Common_Dispatching_Select_Statements.
13633
7b9db926
RD
136342011-08-02 Robert Dewar <dewar@adacore.com>
13635
13636 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
13637 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
13638 Minor reformatting.
13639
e8374e7a
AC
136402011-08-02 Robert Dewar <dewar@adacore.com>
13641
13642 * sem_res.adb: Minor reformatting.
13643 * sem_prag.adb: Minor reformatting.
13644
136452011-08-02 Javier Miranda <miranda@adacore.com>
13646
13647 * exp_atag.adb, exp_atags.ads
13648 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
13649 by the tagged type Entity. Required to use this routine in the VM
13650 targets since we do not have available the Tag entity in the VM
13651 platforms.
13652 * exp_ch6.adb
13653 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
13654 Ada.Tags has not been previously loaded.
13655 * exp_ch7.adb
13656 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
13657 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
13658 * sem_aux.adb
13659 (Enclosing_Dynamic_Scope): Add missing support to handle the full
13660 view of enclosing scopes. Required to handle enclosing scopes that
13661 are synchronized types whose full view is a task type.
13662 * exp_disp.adb
13663 (Build_VM_TSDs): Minor code improvement to avoid generating and
13664 analyzing lists with empty nodes.
13665 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
13666 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
13667 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
13668 (Make_Disp_Timed_Select_Body): Add support for VM targets.
13669 (Make_Select_Specific_Data_Table): Add support for VM targets.
13670 (Make_VM_TSD): Generate code to initialize the SSD structure of
13671 the TSD.
13672
136732011-08-02 Yannick Moy <moy@adacore.com>
13674
13675 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
13676 cross-references section in ALI.
13677 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
13678 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
13679 Sub).
13680 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
13681 subprogram or package entity of a node
13682 (Is_Local_Reference_Type): new function returns True for references
13683 selected in local cross-references.
13684 (Lt): function extracted from Lt in Output_References
13685 (Write_Entity_Name): function extracted from Output_References
13686 (Generate_Definition): generate reference with type 'D' for definition
13687 of objects (object declaration and parameter specification), with
13688 appropriate locations and units, for use in local cross-references.
13689 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
13690 references of type 'I' for initialization in object definition.
13691 (Output_References): move part of function Lt and procedure
13692 Write_Entity_Name outside of the body. Ignore references of types 'D'
13693 and 'I' introduced for local cross-references.
13694 (Output_Local_References): new procedure to output the local
13695 cross-references sections.
13696 (Lref_Entity_Status): new array defining whether an entity is a local
13697 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
13698 with 'I' type when initialization expression is present.
13699 * get_scos.adb, get_scos.ads: Correct comments and typos
13700
1f6439e3
AC
137012011-08-02 Javier Miranda <miranda@adacore.com>
13702
13703 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
13704 the JVM target.
13705 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
13706 the JVM target.
13707 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
13708 TSD support.
13709
137102011-08-02 Vincent Celier <celier@adacore.com>
13711
13712 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
13713 (No_Space_Img): New function
13714 (Find_Excluded_Sources): When reading from a file, record the file name
13715 and the line number for each excluded source.
13716 (Mark_Excluded_Sources): When reporting an error, if the excluded
13717 sources were read from a file, include file name and line number in
13718 the error message.
13719
137202011-08-02 Ed Schonberg <schonberg@adacore.com>
13721
13722 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
13723
ab027d28
RD
137242011-08-02 Robert Dewar <dewar@adacore.com>
13725
13726 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
13727
b3b28b0c
JM
137282011-08-02 Javier Miranda <miranda@adacore.com>
13729
13730 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
13731 generation of TSDs to the DOTNET compiler.
13732 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
13733 generation of TSDs to the DOTNET compiler.
13734
9732e886
JM
137352011-08-02 Javier Miranda <miranda@adacore.com>
13736
13737 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
13738 record of all the tagged types declared inside library level package
13739 declarations, library level package bodies or library level subprograms.
13740 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
13741 associated with a given tagged type.
13742 (Build_VM_TSDs): New subprogram.
13743 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
13744 compilation units that are subprograms.
13745 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
13746 compilation units that are package bodies.
13747 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
13748 units that are a package declaration or a package instantiation.
13749 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
13750 reorganization to improve the error generated by the frontend when the
13751 function Ada.Tags.Secondary_Tag is not available.
13752 * rtsfind.ads (RE_Register_TSD): New runtime entity.
13753 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
13754
e526d0c7
AC
137552011-08-02 Javier Miranda <miranda@adacore.com>
13756
13757 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
13758
137592011-08-02 Robert Dewar <dewar@adacore.com>
13760
13761 * s-imenne.ads: Minor reformatting.
13762
137632011-08-02 Robert Dewar <dewar@adacore.com>
13764
13765 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
13766 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
13767 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
13768
137692011-08-02 Robert Dewar <dewar@adacore.com>
13770
13771 * einfo.ads (Materialize_Entity): Document this is only for renamings
13772 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
13773 required debug information in the case where we transform the object
13774 declaration into a renaming declaration.
13775 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
13776 object
13777 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
13778 Materialize_Entity.
13779
5b1e6aca
RD
137802011-08-02 Robert Dewar <dewar@adacore.com>
13781
13782 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
13783 Suppress_Init_Procs.
13784 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
13785 Suppress_Initialization/Initialization_Suppressed.
13786 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
13787 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
13788 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
13789 * sem_prag.adb: New processing for pragma Suppress_Initialization.
13790
5ad4969d
RD
137912011-08-02 Robert Dewar <dewar@adacore.com>
13792
13793 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
13794 Minor reformatting.
13795
8c4ee6f5
AC
137962011-08-02 Ed Schonberg <schonberg@adacore.com>
13797
13798 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
13799 only have inheritable classwide pre/postconditions.
13800
138012011-08-02 Javier Miranda <miranda@adacore.com>
13802
13803 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
13804 * rtsfind.ads (RE_Check_TSD): New runtime entity.
13805 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
13806 checks if the external tag of a type is the same as the external tag
13807 of some other declaration.
13808
0b3d16c0
AC
138092011-08-02 Thomas Quinot <quinot@adacore.com>
13810
13811 * s-taskin.ads: Minor reformatting.
13812
138132011-08-02 Emmanuel Briot <briot@adacore.com>
13814
13815 * g-comlin.adb (Display_Help): swap the order in which it prints the
13816 short help and the general usage.
13817
138182011-08-02 Ed Schonberg <schonberg@adacore.com>
13819
13820 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
13821 the aspect declarations and attach them to the generic copy for
13822 subsequent analysis.
13823 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
13824 declarations of the generic tree to the new subprogram declarations.
13825 * sem_attr.adb (Check_Precondition_Postcondition): recognize
13826 conditions that apply to a subprogram instance.
13827
138282011-08-02 Robert Dewar <dewar@adacore.com>
13829
13830 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
13831
138322011-08-02 Ed Schonberg <schonberg@adacore.com>
13833
13834 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
13835 private type with a tagged full view is not derived in the immediate
13836 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
13837
4637729f
AC
138382011-08-02 Robert Dewar <dewar@adacore.com>
13839
13840 * exp_ch4.adb: Minor reformatting.
13841
138422011-08-02 Ed Schonberg <schonberg@adacore.com>
13843
13844 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
13845 Ada2012 iterator, the loop will be rewritten during expansion into a
13846 while loop with a cursor and an element declaration. Do not analyze the
13847 body in this case, because if the container is for indefinite types the
13848 actual subtype of the elements will only be determined when the cursor
13849 declaration is analyzed.
13850
138512011-08-02 Arnaud Charlet <charlet@adacore.com>
13852
13853 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
13854 size/alignment related attributes in CodePeer_Mode.
13855
138562011-08-02 Gary Dismukes <dismukes@adacore.com>
13857
13858 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
13859 Prepend_Element, since this can result in the operation getting the
13860 wrong slot in the full type's dispatch table if the full type has
13861 inherited operations. The incomplete type's operation will get added
13862 to the proper position in the full type's primitives
13863 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
13864 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
13865 dispatching operations, since there are cases where nonprimitive
13866 subprograms can get added to the list of incomplete dependents (such
13867 as subprograms in nested packages).
13868 * sem_ch6.adb (Process_Formals): First, remove test for being in a
13869 private part when determining whether to add a primitive with a
13870 parameter of a tagged incomplete type to the Private_Dependents list.
13871 Such primitives can also occur in the visible part, and should not have
13872 been excluded from being private dependents.
13873 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
13874 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
13875 list of a Taft-amendment incomplete type is a primitive before issuing
13876 an error that the full type must appear in the same unit. There are
13877 cases where nonprimitives can be in the list (such as subprograms in
13878 nested packages).
13879 * sem_disp.adb (Derives_From): Use correct condition for checking that
13880 a formal's type is derived from the type of the corresponding formal in
13881 the parent subprogram (the condition was completely wrong). Add
13882 checking that was missing for controlling result types being derived
13883 from the result type of the parent operation.
13884
4c60de0c
YM
138852011-08-02 Yannick Moy <moy@adacore.com>
13886
13887 * errout.adb (First_Node): minor renaming
13888 * restrict.adb (Check_Formal_Restriction): put restriction warning on
13889 first node.
13890
f5afb270
AC
138912011-08-02 Yannick Moy <moy@adacore.com>
13892
13893 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
13894 before accessing operands.
13895 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
13896 decide whether an initialization expression respects SPARK rules, as
13897 the plain node is the expanded one. This allows for more valid warnings
13898 to be issued.
13899 * gnat_rm.texi: Minor update.
13900
139012011-08-02 Arnaud Charlet <charlet@adacore.com>
13902
13903 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
13904 previous change.
13905
139062011-08-02 Robert Dewar <dewar@adacore.com>
13907
13908 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
13909
139102011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
13911
13912 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
13913 loop statements and the element renaming declaration with a block when
13914 the element type is controlled.
13915
139162011-08-02 Yannick Moy <moy@adacore.com>
13917
13918 * sinfo.ads: Minor formatting.
13919
139202011-08-02 Ed Schonberg <schonberg@adacore.com>
13921
13922 * sem_aggr.adb (Add_Association): if the association has a box and no
13923 expression, use the Sloc of the aggregate itself for the new
13924 association.
13925 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
13926 the Original_Node.
13927
db72f10a
AC
139282011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
13929
13930 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
13931 When a container is provided via a function call, generate a renaming
13932 of the function result. This avoids the creation of a transient scope
13933 and the premature finalization of the container.
13934 * exp_ch7.adb (Is_Container_Cursor): Removed.
13935 (Wrap_Transient_Declaration): Remove the supression of the finalization
13936 of the list controller when the declaration denotes a container cursor,
13937 it is not needed.
13938
139392011-08-02 Yannick Moy <moy@adacore.com>
13940
13941 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
13942 node is from source, instead of the original node being from source.
13943 * sem_aggr.adb
13944 (Resolve_Array_Aggregate): refine the check for a static expression, to
13945 recognize also static ranges
13946 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
13947 Array_Type_Declaration): postpone the test for the type being a subtype
13948 mark after the type has been resolved, so that component-selection and
13949 expanded-name are discriminated.
13950 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
13951 to distinguish the case of an iteration scheme, so that an error is
13952 issed on a non-static range in SPARK except in an iteration scheme.
13953 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
13954 In_Iter_Schm = True.
13955 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
13956 user-defined operators so that they are allowed in renaming
13957 * sem_ch8.adb
13958 (Find_Selected_Component): refine the check for prefixing of operators
13959 so that they are allowed in renaming. Move the checks for restrictions
13960 on selector name after analysis discriminated between
13961 component-selection and expanded-name.
13962 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
13963 concatenation argument of string type if it is static.
13964 * sem_util.adb, sem_util.ads
13965 (Check_Later_Vs_Basic_Declarations): add a new function
13966 Is_Later_Declarative_Item to decice which declarations are allowed as
13967 later items, in the two different modes Ada 83 and SPARK. In the SPARK
13968 mode, add that renamings are considered as later items.
13969 (Enclosing_Package): new function to return the enclosing package
13970 (Enter_Name): correct the rule for homonyms in SPARK
13971 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
13972 from source (result of expansion) to avoid issuing wrong warnings.
13973
139742011-08-02 Ed Schonberg <schonberg@adacore.com>
13975
13976 * errout.adb: On anything but an expression First_Node returns its
13977 argument.
13978
23685ae6
AC
139792011-08-02 Pascal Obry <obry@adacore.com>
13980
13981 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
13982
139832011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
13984
13985 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
13986 Set the associated loop as the related expression of internally
13987 generated cursors.
13988 * exp_ch7.adb (Is_Container_Cursor): New routine.
13989 (Wrap_Transient_Declaration): Supress the finalization of the list
13990 controller when the declaration denotes a container cursor.
13991
139922011-08-02 Yannick Moy <moy@adacore.com>
13993
13994 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
13995 command line now.
13996 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
13997 expression is a simple expression. This check cannot be performed in
13998 the semantics, so just drop it.
13999 (P_Index_Or_Discriminant_Constraint): move check that the index or
14000 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
14001 semantics. Other cases were previously checked in the semantics.
14002 * par-ch4.adb (P_Name): move checks that a selector name is not
14003 character literal or an operator symbol to Find_Selected_Component in
14004 the semantics
14005 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
14006 declarations are not placed after later declarations in a separate
14007 procedure in Sem_Util (possibly not the best choice?), to be used both
14008 during parsing, for Ada 83 mode, and during semantic analysis, for
14009 SPARK mode.
14010 * par-endh.adb (Check_End): move check that end label is not missing
14011 to Process_End_Label in the semantics
14012 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
14013 the special case for SPARK restriction
14014 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
14015 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
14016 parameter Force to issue the error message even on internal node (used
14017 for generated end label). Call Check_Restriction to check when an error
14018 must be issued. In SPARK mode, issue an error message even if the
14019 restriction is not set.
14020 (Check_Restriction): new procedure with an additional out parameter to
14021 inform the caller that a message has been issued
14022 * sem_aggr.adb: Minor modification of message
14023 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
14024 instead of issuing an error message directly
14025 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
14026 declarations are not placed after later declarations, by calling
14027 Check_Later_Vs_Basic_Declarations
14028 (Analyze_Subtype_Declaration): move here the check that an index or
14029 discriminant constraint must be a subtype mark. Change the check that
14030 a subtype of String must start at one so that it works on subtype marks.
14031 * sem_ch4.adb (Analyze_Call): move here the check that a named
14032 association cannot follow a positional one in a call
14033 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
14034 instead of issuing an error message directly
14035 * sem_ch8.adb (Find_Selected_Component): move here the check that a
14036 selector name is not a character literal or an operator symbol. Move
14037 here the check that the prefix of an expanded name cannot be a
14038 subprogram or a loop statement.
14039 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
14040 procedure called from parsing and semantics to check that basic
14041 declarations are not placed after later declarations
14042 (Process_End_Label): move here the check that end label is not missing
14043
140442011-08-02 Arnaud Charlet <charlet@adacore.com>
14045
14046 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
14047 representation clause in codepeer mode, since it confuses CodePeer and
14048 does not bring useful info.
14049
140502011-08-02 Ed Falis <falis@adacore.com>
14051
14052 * init.c: initialize fp hw on MILS.
14053
140542011-08-02 Ed Schonberg <schonberg@adacore.com>
14055
14056 * errout.adb (First_Node): for bodies, return the node itself (small
14057 optimization). For other nodes, do not check source_unit if the node
14058 comes from Standard.
14059
d2d9cc22
AC
140602011-08-02 Robert Dewar <dewar@adacore.com>
14061
14062 * exp_ch3.adb: Minor comment additions.
14063 * sem_ch13.adb: Minor reformatting.
14064
140652011-08-02 Pascal Obry <obry@adacore.com>
14066
14067 * make.adb, makeutl.adb: Removes some superfluous directory separator.
14068
a01b9df6
AC
140692011-08-02 Robert Dewar <dewar@adacore.com>
14070
14071 * sem_attr.adb: Minor reformatting.
14072
140732011-08-02 Robert Dewar <dewar@adacore.com>
14074
14075 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
14076 (Has_Default_Component_Value): Removed
14077 * einfo.ads Comment updates
14078 (Has_Default_Aspect): Replaces Has_Default_Value
14079 (Has_Default_Component_Value): Removed
14080 * exp_ch13.adb
14081 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
14082 * exp_ch3.adb
14083 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
14084 (Get_Simple_Init_Val): Handle Default_Value aspect
14085 (Needs_Simple_Initialization): Handle Default_Value aspect
14086 * exp_ch3.ads: Needs_Simple_Initialization
14087 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
14088 * par-prag.adb (Pragma_Default[_Component]Value) Removed
14089 * sem_ch13.adb
14090 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
14091 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
14092 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
14093
140942011-08-02 Ed Schonberg <schonberg@adacore.com>
14095
14096 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
14097 package containing iteration primitives.
14098 exp_ch5.adb (Expand_Iterator_Loop): ditto.
14099
75c90775
AC
141002011-08-02 Ed Schonberg <schonberg@adacore.com>
14101
14102 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
14103 "of", pre-analyze expression in case it is a function call with
14104 finalization actions that must be placed ahead of the loop.
14105 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
14106 on an Ada2012 iterator, insert them ahead of the rewritten loop.
14107
141082011-08-02 Geert Bosch <bosch@adacore.com>
14109
14110 * cstand.adb (Create_Float_Types): Only consider C's long double for
14111 Long_Long_Float, in addition to double.
14112
ded8909b
AC
141132011-08-02 Robert Dewar <dewar@adacore.com>
14114
14115 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
14116 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
14117 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
14118 Minor reformatting.
14119
141202011-08-02 Ed Schonberg <schonberg@adacore.com>
14121
14122 * sem_attr.adb: handle properly 'Result when it is a prefix of an
14123 indexed component.
14124
141252011-08-02 Javier Miranda <miranda@adacore.com>
14126
14127 * einfo.ads, einfo.adb
14128 (Original_Access_Type): Move this attribute to Node26 since there was
14129 an undocumented use of Node21 in E_Access_Subprogram_Type entities
14130 which causes conflicts and breaks the generation of the .NET compiler.
14131 (Interface_Name): Add missing documentation on JGNAT only uses of
14132 this attribute.
14133
70c34e1c
AC
141342011-08-02 Geert Bosch <bosch@adacore.com>
14135
14136 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
14137 (Find_Back_End_Float_Type): Likewise
14138 (Create_Back_End_Float_Types): Likewise
14139 (Create_Float_Types): Likewise
14140 (Register_Float_Type): Likewise
14141 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
14142 Nlist and split out type selection in new local Find_Base_Type function.
14143 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
14144 Nlist
14145 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
14146
141472011-08-02 Robert Dewar <dewar@adacore.com>
14148
14149 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
14150 alpha order).
14151 * opt.ads: Minor comment change.
14152 * sem_ch12.adb: Minor code reorganization.
14153
b715bc59
AC
141542011-08-02 Gary Dismukes <dismukes@adacore.com>
14155
14156 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
14157 subtype's list of rep items to the list on the full subtype in the case
14158 where the lists are the same.
14159
141602011-08-02 Geert Bosch <bosch@adacore.com>
14161
14162 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
14163 using the one from System.Strings, which also deallocates all strings.
14164
002bdd68
AC
141652011-08-02 Geert Bosch <bosch@adacore.com>
14166
14167 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
14168 function.
14169 * gcc-interface/Make-lang.in: Update dependencies.
14170
141712011-08-02 Olivier Hainque <hainque@adacore.com>
14172
14173 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
14174 end_locus.
14175
499769ec
AC
141762011-08-02 Javier Miranda <miranda@adacore.com>
14177
14178 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
14179 associated with anonymous access to subprograms.
14180
141812011-08-02 Geert Bosch <bosch@adacore.com>
14182
14183 * opt.ads
14184 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
14185 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
14186 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
14187 (Add_Symbol_Definition): Move to switch-c.adb
14188 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
14189 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
14190 (Add_Symbol_Definition): Move to switch-c.adb.
14191 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
14192 * sem_warn.adb
14193 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
14194 Move to warnsw.adb.
14195 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
14196 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
14197 Move to warnsw.adb.
14198 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
14199 (Add_Symbol_Definition): Moved from Prepcomp.
14200 * switch-c.ads: Update copyright notice. Use String_List instead of
14201 Argument_List, removing dependency on System.OS_Lib.
14202
aa1e353a
AC
142032011-08-02 Yannick Moy <moy@adacore.com>
14204
14205 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
14206 mode on initialization expression which does not respect SPARK
14207 restrictions.
14208 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
14209 if the tree referenced by its argument represents an initialization
14210 expression in SPARK, suitable for initializing an object in an object
14211 declaration.
14212
142132011-08-02 Javier Miranda <miranda@adacore.com>
14214
14215 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
14216 internally generated access to subprogram with its associated protected
14217 subprogram type.
14218 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
14219
15b682ca
GB
142202011-08-02 Geert Bosch <bosch@adacore.com>
14221
14222 * cstand.adb (Register_Float_Type): Print information about type to
14223 register, if the Debug_Flag_Dot_B is set.
14224 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
14225 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
14226 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
14227 with a requested precision of more than Max_Digits digits and no more
14228 than Max_Base_Digits digits, if a range specification is present and the
14229 Predefined_Float_Types list has a suitable type to derive from.
14230 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
14231 case of type completion with pragma Import
14232 * sem_prag.adb
14233 (Process_Import_Predefined_Type): Processing to complete a type
14234 with pragma Import. Currently supports floating point types only.
14235 (Set_Convention_From_Pragma): Do nothing without underlying type.
14236 (Process_Convention): Guard against absence of underlying type,
14237 which may happen when importing incomplete types.
14238 (Process_Import_Or_Interface): Handle case of importing predefined
14239 types. Tweak error message.
14240
f8726f2b
AC
142412011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14242
14243 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
14244 functions to previous change. Reorganize code slightly.
14245
142462011-08-02 Geert Bosch <bosch@adacore.com>
14247
14248 * back_end.ads (Register_Type_Proc): New call back procedure type for
14249 allowing the back end to provide information about available types.
14250 (Register_Back_End_Types): New procedure to register back end types.
14251 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
14252 available types.
14253 * cstand.adb (Back_End_Float_Types): New list for floating point types
14254 supported by the back end.
14255 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
14256 (Copy_Float_Type): New procedure to make new copies of predefined types.
14257 (Register_Float_Type): New call back procedure to populate the BEFT list
14258 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
14259 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
14260 (Create_Float_Types): New procedure to create entities for floating
14261 point types predefined in Standard, and put these and any remaining
14262 BEFTs on the Predefined_Float_Types list.
14263 * stand.ads (Predefined_Float_Types): New list for predefined floating
14264 point types that do not have declarations in package Standard.
14265
feecad68
AC
142662011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14267
14268 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
14269 entity node for the unit containing the parameter.
14270 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
14271 (Add_Inlined_Subprogram): Likewise.
14272 * gcc-interface/Make-lang.in: Update dependencies.
14273
142742011-08-02 Thomas Quinot <quinot@adacore.com>
14275
14276 * s-stusta.adb (Print): Make sure Pos is always initialized to a
14277 suitable value.
14278
12f0c50c
AC
142792011-08-02 Geert Bosch <bosch@adacore.com>
14280
14281 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
14282
142832011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14284
14285 * sem_type.adb (Covers): Move trivial case to the top and reuse the
14286 computed value of Base_Type.
14287
142882011-08-02 Yannick Moy <moy@adacore.com>
14289
14290 * restrict.adb (Check_Restriction): issue an error for any use of
14291 class-wide, even if the No_Dispatch restriction is not set.
14292 * sem_aggr.adb: Correct typos in comments and messages in formal mode
14293 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
14294 when completing a private extension, the type named in the private part
14295 is not the same as that named in the visible part.
14296 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
14297 of an inherited primitive operations of a tagged type or type extension
14298 that returns the tagged type.
14299 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
14300 function which returns True for an implicit operation inherited by the
14301 derived type declaration for the argument type.
14302 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
14303 order.
14304
fb86fe11
ES
143052011-08-02 Ed Schonberg <schonberg@adacore.com>
14306
14307 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
14308 Process_Bounds, to perform analysis with expansion of a range or an
14309 expression that is the iteration scheme for a loop.
14310 (Analyze_Iterator_Specification): If domain of iteration is given by a
14311 function call with a controlled result, as is the case if call returns
14312 a predefined container, ensure that finalization actions are properly
14313 generated.
14314 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
14315
62be5d0a
JM
143162011-08-02 Javier Miranda <miranda@adacore.com>
14317
14318 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
14319 * gcc-interface/Make-lang.in: Update dependencies.
14320
143212011-08-02 Javier Miranda <miranda@adacore.com>
14322
14323 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
14324 determine if the analysis is performed using N or Original_Node (N).
14325 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
14326 functionality of routine Is_Variable avoids code duplication.
14327 * checks.adb (Determine_Range): Handle temporaries generated by
14328 Remove_Side_Effects.
14329
143302011-08-02 Javier Miranda <miranda@adacore.com>
14331
14332 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
14333 expansion of the condition. Required since the previous analysis was
14334 done with expansion disabled (see Resolve_Quantified_Expression) and
14335 hence checks were not inserted and record comparisons have not been
14336 expanded.
14337
a20f4389
AC
143382011-08-02 Ed Falis <falis@adacore.com>
14339
14340 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
14341 Update header.
14342
143432011-08-02 Bob Duff <duff@adacore.com>
14344
14345 * opt.ads: Minor comment fix.
14346
143472011-08-02 Bob Duff <duff@adacore.com>
14348
14349 * sem_ch12.adb (Analyze_Package_Instantiation,
14350 Analyze_Subprogram_Instantiation): Turn off style checking while
14351 analyzing an instance. Whatever style checks that apply to the generic
14352 unit should apply, so it makes no sense to apply them in an instance.
14353 This was causing trouble when compiling an instance of a runtime
14354 unit that violates the -gnatyO switch.
14355 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
14356 one of the two case statements, causing spurious errors.
14357
143582011-08-02 Robert Dewar <dewar@adacore.com>
14359
14360 * uname.adb: Minor reformatting.
14361 * gnatcmd.adb: Minor reformatting.
14362 * exp_attr.adb: Minor reformatting.
14363
90878b12
AC
143642011-08-02 Ed Schonberg <schonberg@adacore.com>
14365
14366 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
14367 No_Dispatching_Calls, do not look for the Assign primitive, because
14368 predefined primitives are not created in this case.
14369
143702011-08-02 Bob Duff <duff@adacore.com>
14371
14372 * stylesw.ads: Minor comment fixes.
14373
143742011-08-02 Robert Dewar <dewar@adacore.com>
14375
14376 * freeze.adb (Add_To_Result): New procedure.
14377
143782011-08-02 Jose Ruiz <ruiz@adacore.com>
14379
14380 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
14381 time, if the specific run-time routines for handling streams of strings
14382 are not available, use the default mechanism.
14383
143842011-08-02 Arnaud Charlet <charlet@adacore.com>
14385
14386 * s-regpat.ads: Fix typo.
14387
143882011-08-02 Vincent Celier <celier@adacore.com>
14389
14390 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
14391 not null, call it to create the in memory config project file without
14392 parsing an existing default config project file.
14393
143942011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14395
14396 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
14397
143982011-08-02 Ed Schonberg <schonberg@adacore.com>
14399
14400 * sem_elim.adb: an abstract subprogram does not need an eliminate
14401 pragma for its descendant to be eliminable.
14402
144032011-08-02 Ed Falis <falis@adacore.com>
14404
14405 * init.c: revert to handling before previous checkin for VxWorks
14406 * s-intman-vxworks.adb: delete unnecessary declarations related to
14407 using Ada interrupt facilities for handling signals.
14408 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
14409 * s-intman-vxworks.ads: Import __gnat_install_handler as
14410 Initialize_Interrupts.
14411 * s-taprop-vxworks.adb: Delete Signal_Mask.
14412 (Abort_Handler): change construction of mask to unblock exception
14413 signals.
14414
273adcdf
AC
144152011-08-02 Jerome Guitton <guitton@adacore.com>
14416
14417 * a-except-2005.adb (Raise_From_Signal_Handler): Call
14418 Debug_Raise_Exception before propagation starts.
14419
144202011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14421
14422 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
14423 to Restriction_Check_Required.
14424 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
14425 * sem_res.adb (Resolve_Call): Likewise.
14426 * sem_attr.adb (Check_Stream_Attribute): Likewise.
14427
144282011-08-02 Bob Duff <duff@adacore.com>
14429
14430 * stylesw.ads: Update comment.
14431 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
14432 * errout.ads: Remove obsolete comment.
14433
144342011-08-02 Javier Miranda <miranda@adacore.com>
14435
14436 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
14437 (Set_Is_Safe_To_Reevaluate): new procedure.
14438 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
14439 assignment is allowed on safe-to-reevaluate variables.
14440 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
14441 temporary created to remove side effects in expressions that use
14442 the secondary stack as safe-to-reevaluate.
14443 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
14444 variables that are not true constants.
14445
6320f5e1
AC
144462011-08-02 Robert Dewar <dewar@adacore.com>
14447
14448 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
14449 sem_res.adb, sem_ch6.adb: Minor reformatting.
14450
144512011-08-02 Jerome Guitton <guitton@adacore.com>
14452
14453 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
14454
2fe829ae
ES
144552011-08-02 Ed Schonberg <schonberg@adacore.com>
14456
14457 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
14458 not set Overridden_Operation if subprogram is an initialization
14459 procedure.
14460
e24329cd
YM
144612011-08-02 Yannick Moy <moy@adacore.com>
14462
14463 * par-ch6.adb: Correct obsolete name in comments
14464 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
14465 which takes two message arguments (existing function takes one), with
14466 second message used for continuation.
14467 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
14468 block statements that originate from a source block statement, not
14469 generated block statements
14470 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
14471 symmetry with procedure case
14472 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
14473 function to issue an error in formal mode if a package specification
14474 contains more than one tagged type or type extension.
14475 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
14476 parameters matching formals of tagged types are objects (or ancestor
14477 type conversions of objects), not general expressions. Issue an error
14478 on view conversions that are not involving ancestor conversion of an
14479 extended type.
14480 (Resolve_Type_Conversion): in formal mode, issue an error on the
14481 operand of an ancestor type conversion which is not an object
14482 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
14483 procedure so that it works also for actuals of function calls
14484 (Is_Actual_Tagged_Parameter): new function which determines if its
14485 argument is an actual parameter of a formal of tagged type in a
14486 subprogram call
14487 (Is_SPARK_Object_Reference): new function which determines if the tree
14488 referenced by its argument represents an object in SPARK
14489
176dadf6
AC
144902011-08-02 Robert Dewar <dewar@adacore.com>
14491
14492 * sem_ch3.adb: Minor reformatting
14493 Minor comment addition
14494 Minor error msg text change
14495
144962011-08-02 Javier Miranda <miranda@adacore.com>
14497
14498 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
14499 function. Used to be more precise when we generate a variable plus one
14500 assignment to remove side effects in the evaluation of the Bound
14501 expressions.
14502 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
14503 of the bound expression to force its re-analysis and thus expand the
14504 associated transient scope (if required). Code cleanup replacing the
14505 previous code that declared the constant entity by an invocation to
14506 routine Force_Evaluation which centralizes this work in the frontend.
14507
d8b962d8
AC
145082011-08-02 Robert Dewar <dewar@adacore.com>
14509
14510 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
14511 (Base_Type): Now uses improved Is_Base_Type function
14512 * einfo.ads (Base_Type): Inline this function
14513
145142011-08-02 Robert Dewar <dewar@adacore.com>
14515
14516 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
14517 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
14518
145192011-08-02 Arnaud Charlet <charlet@adacore.com>
14520
14521 * gcc-interface/Make-lang.in: Update dependencies.
14522 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
14523 targets.
14524
145252011-08-02 Yannick Moy <moy@adacore.com>
14526
14527 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
14528 non-simple expression used in delta constraint
14529 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
14530 index constraint which is not a subtype mark
14531 * par.adb: With and use Restrict
14532 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
14533 mode on component type which is not a subtype mark and default
14534 expression on component
14535 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
14536 of string which does not have a lower index bound equal to 1
14537 (Array_Type_Declaration): issue an error in formal mode on index or
14538 component type which is not a subtype mark, and on aliased keyword on
14539 component
14540 (Derived_Type_Declaration): issue an error in formal mode on interface,
14541 limited or abstract type
14542 (Record_Type_Declaration): issue an error in formal mode on interface
14543 (Record_Type_Definition): issue an error in formal mode on tagged types
14544 and type extensions not declared in the specification of a library unit
14545 package; on null non-tagged record; on variant part
14546
145472011-08-02 Vincent Celier <celier@adacore.com>
14548
14549 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
14550 not declared for qualified library project when Library_Name is not
14551 declared, but Library_Dir is.
14552
145532011-08-02 Robert Dewar <dewar@adacore.com>
14554
14555 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
14556 pragmas (affects aspects [Component_]Default_Value
14557 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
14558 component type for the resolution
14559
f96b2d85
AC
145602011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14561
14562 * einfo.adb (Base_Type): Tune implementation for speed.
14563
145642011-08-02 Robert Dewar <dewar@adacore.com>
14565
14566 * freeze.adb: Minor reformatting.
14567
8b3c6430
AC
145682011-08-02 Thomas Quinot <quinot@adacore.com>
14569
14570 * scos.ads: Update comments.
14571
145722011-08-02 Ed Schonberg <schonberg@adacore.com>
14573
14574 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
14575 base type, because the parent may be a subtype of a private type whose
14576 convention is established in a private part.
14577
145782011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
14579
14580 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
14581 statement in a block when the expansion of the return expression has
14582 created a finalization chain.
14583 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
14584 with the parent node.
14585 Add N_Extended_Return_Statement to handle the case where a transient
14586 object declaration appears in the Return_Object_Declarations list of
14587 an extended return statement.
14588
145892011-08-02 Matthew Gingell <gingell@adacore.com>
14590
14591 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
14592 unused parameter 'name'.
14593
145942011-08-02 Ed Schonberg <schonberg@adacore.com>
14595
14596 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
14597 inherited operation, check whether its alias, which is the source
14598 operastion that it renames, has been marked eliminated.
14599
cae81f17
JM
146002011-08-02 Javier Miranda <miranda@adacore.com>
14601
14602 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
14603 in-mode parameter whose type is an access type since it can be used to
14604 modify its designated object. Enforce code that handles as safe an
14605 access type that is not access-to-constant but it is the result of a
14606 previous removal of side-effects.
14607 (Remove_Side_Effects): Minor code reorganization of cases which require
14608 no action. Done to incorporate documentation on new cases uncovered
14609 working in this ticket: no action needed if this routine was invoked
14610 too early and the nodes are not yet decorated.
14611 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
14612 to routine Remove_Side_Effects by calls to Force_Evaluation since they
14613 were issued with actuals that are implicitly provided by
14614 Force_Evaluation.
14615
218e6dee
RD
146162011-08-02 Robert Dewar <dewar@adacore.com>
14617
14618 * sem_ch3.adb, sem_res.adb: Minor reformatting.
14619
7a489a2b
AC
146202011-08-02 Yannick Moy <moy@adacore.com>
14621
14622 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
14623 to issue an error in formal mode on attribute not supported in this mode
14624 (Analyze_Attribute): issue errors on standard attributes not supported
14625 in formal mode.
14626 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
14627 comment, and issue error in formal mode on modulus which is not a power
14628 of 2.
14629 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
14630 range.
14631 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
14632 subtype mark.
14633 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
14634 operator on modular type (except 'not').
14635
146362011-08-02 Robert Dewar <dewar@adacore.com>
14637
14638 * gnat_rm.texi: Minor reformatting.
14639
cb7fa356
AC
146402011-08-02 Arnaud Charlet <charlet@adacore.com>
14641
14642 * s-osinte-linux.ads: Minor comment update and reformatting.
14643 * i-cexten.ads: Make this unit pure, as for its parent.
14644 Will allow its usage in more contexts if needed.
14645
146462011-08-02 Robert Dewar <dewar@adacore.com>
14647
14648 * s-utf_32.ads: Minor comment fix.
14649
146502011-08-02 Ed Schonberg <schonberg@adacore.com>
14651
14652 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
14653 operation of a tagged synchronized type, handle the case where the
14654 controlling argument is overloaded.
14655
146562011-08-02 Yannick Moy <moy@adacore.com>
14657
14658 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
14659 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
14660 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
14661 SPARK mode and formal verification mode on processing SPARK restriction
14662 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
14663 requiring consistency checking.
14664
5cc9353d
RD
146652011-08-02 Robert Dewar <dewar@adacore.com>
14666
14667 * sem_res.adb: Minor reformatting.
14668
e51537ff
RD
146692011-08-02 Robert Dewar <dewar@adacore.com>
14670
14671 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
14672 a-cforse.ads: Remove unneeded with of Ada.Containers
14673 Remove commented out pragma Inline's
14674 Move specifications of new subprograms to the actual specs
14675
83fa09c5
AC
146762011-08-02 Yannick Moy <moy@adacore.com>
14677
14678 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
14679 a-cforse.ads: Update comments.
14680
146812011-08-02 Ed Schonberg <schonberg@adacore.com>
14682
14683 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
14684
d11cfaf8
RD
146852011-08-02 Robert Dewar <dewar@adacore.com>
14686
14687 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
14688 a-cforse.ads, a-cofove.ads: Minor reformatting.
14689
300b98bb
AC
146902011-08-02 Claire Dross <dross@adacore.com>
14691
14692 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
14693 a-cofove.ads: Add comments.
14694
146952011-08-02 Yannick Moy <moy@adacore.com>
14696
14697 * gnat_rm.texi: Document formal containers.
14698
146992011-08-02 Emmanuel Briot <briot@adacore.com>
14700
14701 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
14702 are empty sections.
14703
19fb051c
AC
147042011-08-02 Robert Dewar <dewar@adacore.com>
14705
14706 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
14707 reformatting.
14708
147092011-08-02 Robert Dewar <dewar@adacore.com>
14710
14711 * aspects.adb: New aspects Default_Value and Default_Component_Value
14712 New format of Aspect_Names table checks for omitted entries
14713 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
14714 handling of boolean aspects for derived types.
14715 New aspects Default_Value and Default_Component_Value
14716 New format of Aspect_Names table checks for omitted entries
14717 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
14718 (Has_Default_Value): New flag
14719 (Has_Default_Component_Value): New flag
14720 (Has_Default_Value): New flag
14721 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
14722 table.
14723 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
14724 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
14725 Default_Value and Default_Component_Value
14726 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
14727 New aspects Default_Value and Default_Component_Value
14728 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
14729 * sprint.adb: Print N_Aspect_Specification node when called from gdb
14730
147312011-08-02 Vincent Celier <celier@adacore.com>
14732
14733 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
14734 inherit library kind.
14735
147362011-08-02 Ed Schonberg <schonberg@adacore.com>
14737
14738 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
14739 Minor reformatting.
14740
147412011-08-02 Robert Dewar <dewar@adacore.com>
14742
14743 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
14744
5f7747af
AC
147452011-08-02 Yannick Moy <moy@adacore.com>
14746
14747 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
14748
147492011-08-02 Robert Dewar <dewar@adacore.com>
14750
14751 * impunit.adb: Add comment.
14752
a5fe697b
AC
147532011-08-02 Yannick Moy <moy@adacore.com>
14754
14755 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
14756 qualification of aggregates in formal mode
14757 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
14758 another aggregate
14759 (Resolve_Aggregate): complete the test that an aggregate is adequately
14760 qualified in formal mode
14761
147622011-08-02 Pascal Obry <obry@adacore.com>
14763
14764 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
14765 * mlib-prj.adb: Supress warning when compiling binder generated file.
14766 (Build_Library): Supress all warnings when compiling the binder
14767 generated file.
14768
bd65a2d7 147692011-08-02 Yannick Moy <moy@adacore.com>
d4487611 14770
bd65a2d7
AC
14771 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
14772 from here...
14773 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
14774 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
14775 Add with/use clauses to make Check_Formal_Restriction visible
14776
147772011-08-02 Ed Schonberg <schonberg@adacore.com>
14778
14779 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
14780 in-parameters when type of the generic formal is private in the generic
14781 spec and non-private in the body.
14782
147832011-08-02 Claire Dross <dross@adacore.com>
14784
14785 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
14786 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
14787 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
14788 * impunit.adb, Makefile.rtl: Take new files into account.
d4487611
AC
14789
147902011-08-02 Robert Dewar <dewar@adacore.com>
14791
14792 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
14793 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
14794
bd434b3f
YM
147952011-08-02 Yannick Moy <moy@adacore.com>
14796
14797 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
14798 formal mode
14799 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
14800 matching static array bounds, taking into account the special case of
14801 string literals
14802 * sem_ch3.adb: Typo in comment.
14803
fe5d3068
YM
148042011-08-02 Yannick Moy <moy@adacore.com>
14805
14806 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
14807 which issues an error in formal mode if its argument node is originally
14808 from source
14809 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
14810 has a discriminant specification so that it does not include the case
14811 of derived types
14812 (Derived_Type_Declaration): move here the test that a derived type has a
14813 discriminant specification
14814 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
14815 first element of a component association before accessing its choices
14816 (presence of component association is not enough)
14817 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
14818 declaration is a library item before accessing the next element in a
14819 list, as library items are not member of lists
14820 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
14821 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
14822 Check_Formal_Restriction whenever possible.
14823
b60a3f26
AC
148242011-08-02 Ed Schonberg <schonberg@adacore.com>
14825
14826 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
14827 reference when needed.
14828
148292011-08-02 Bob Duff <duff@adacore.com>
14830
14831 * gnat_ugn.texi: Fix typo.
14832
148332011-08-02 Vincent Celier <celier@adacore.com>
14834
14835 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
14836 archive file name. Do not use the full path name of archives for Open
14837 VMS.
14838
eaba57fb
RD
148392011-08-02 Robert Dewar <dewar@adacore.com>
14840
14841 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
14842 Analyze_Aspect_Specifications
14843 * sem_ch13.adb
14844 (Analyze_Aspect_Specifications): New handling for boolean aspects
14845 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
14846 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
14847 sequence for Analyze_Aspect_Specifications
14848 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
14849 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
14850
148512011-08-02 Robert Dewar <dewar@adacore.com>
14852
14853 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
14854 aspects, since these no longer exist.
14855
148562011-08-02 Robert Dewar <dewar@adacore.com>
14857
14858 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
14859 semicolon, do not try to see if there are aspects following it.
14860 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
14861 aspect spec.
14862
8830d1d2
AC
148632011-08-02 Robert Dewar <dewar@adacore.com>
14864
14865 * sem_ch8.adb, aspects.ads: Minor reformatting.
14866
148672011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14868
14869 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
14870 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
14871 extracted from...
14872 (Analyze_Aspect_Specifications): ...here. Call above procedure.
14873
7ff2d234
AC
148742011-08-02 Yannick Moy <moy@adacore.com>
14875
14876 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
14877 mode on subprogram declaration outside of package specification, unless
14878 it is followed by a pragma Import
14879 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
14880 Access_Type_Declaration): issue error in formal mode on access type
14881 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
14882 incomplete type
14883 (Analyze_Object_Declaration): issue error in formal mode on object
14884 declaration which does not respect SPARK restrictions
14885 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
14886 declaration which does not respect SPARK restrictions
14887 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
14888 error in formal mode on digits or delta constraint
14889 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
14890 decimal fixed point type
14891 (Derived_Type_Declaration): issue error in formal mode on derived type
14892 other than type extensions of tagged record types
14893 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
14894 with check on access definition
14895 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
14896 mode on protected definition.
14897 (Analyze_Task_Definition): issue error in formal mode on task definition
14898
148992011-08-02 Robert Dewar <dewar@adacore.com>
14900
14901 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
14902
806f6d37
AC
149032011-08-02 Javier Miranda <miranda@adacore.com>
14904
14905 * sem_ch6.adb (Can_Override_Operator): New function.
14906 (Verify_Overriding_Indicator): Add missing code to check overriding
14907 indicator in operators. Fixes regression.
14908 (Check_Overriding_Indicator): Minor reformating after replacing the
14909 code that evaluates if the subprogram can override an operator by
14910 invocations to the above new function.
14911 * einfo.adb
14912 (Write_Field26_Name): Add missing code to ensure that, following
14913 the documentation in einfo.ads, this field is not shown as attribute
14914 "Static_Initialization" on non-dispatching functions.
14915
149162011-08-02 Jose Ruiz <ruiz@adacore.com>
14917
14918 * sem_res.adb (Resolve_Call): A call to
14919 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
14920 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
14921 i.e., when the second parameter is of type Time_Span.
14922
149232011-08-02 Vincent Celier <celier@adacore.com>
14924
14925 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
14926 with an archive instead of -L<library dir> -l<library name>.
14927
149282011-08-02 Ed Schonberg <schonberg@adacore.com>
14929
14930 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
14931 mark the base types In_Use in addition to making the operations
14932 use_visible.
14933
149342011-08-02 Ed Falis <falis@adacore.com>
14935
14936 * init.c: add and setup __gnat_signal_mask for the exception signals
14937 * s-inmaop-vxworks.adb: new file.
14938 * s-intman-vxworks.adb: remove unnecessary initializations and
14939 simplify remaining
14940 * s-intman-vxworks.ads: remove unnecessary variable
14941 * s-taprop-vxworks.adb: simplify signal initialization
14942
780d052e
RD
149432011-08-02 Robert Dewar <dewar@adacore.com>
14944
14945 * sem_ch8.adb: Minor code reorganization, comment updates.
14946
149472011-08-02 Robert Dewar <dewar@adacore.com>
14948
14949 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
14950 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
14951 here from Sem_Res.
14952 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
14953 (Matching_Static_Array_Bounds): Moved here from Sem_Res
14954
29efbb8c
ES
149552011-08-02 Ed Schonberg <schonberg@adacore.com>
14956
14957 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
14958 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
14959 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
14960 use_type_clauses, to handle more efficiently use_type and use_all_type
14961 constructs.
14962 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
14963 Ada2012 Use_All_Type clause.
14964 (Use_Class_Wide_Operations): new procedure.
14965
b0186f71
AC
149662011-08-02 Robert Dewar <dewar@adacore.com>
14967
14968 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
14969 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
14970 expression to expression function.
14971
149722011-08-02 Ed Schonberg <schonberg@adacore.com>
14973
14974 * sem_ch4.adb: transform simple Ada2012 membership into equality only
14975 if types are compatible.
14976
149772011-08-02 Yannick Moy <moy@adacore.com>
14978
14979 * sem_res.adb (Matching_Static_Array_Bounds): new function which
14980 returns True if its argument array types have same dimension and same
14981 static bounds at each index.
14982 (Resolve_Actuals): issue an error in formal mode on actuals passed as
14983 OUT or IN OUT paramaters which are not view conversions in SPARK.
14984 (Resolve_Arithmetic_Op): issue an error in formal mode on
14985 multiplication or division with operands of fixed point types which are
14986 not qualified or explicitly converted.
14987 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
14988 Boolean or array type (except String) operands.
14989 (Resolve_Equality_Op): issue an error in formal mode on equality
14990 operators for array types other than String with non-matching static
14991 bounds.
14992 (Resolve_Logical_Op): issue an error in formal mode on logical operators
14993 for array types with non-matching static bounds. Factorize the code in
14994 Matching_Static_Array_Bounds.
14995 (Resolve_Qualified_Expression): issue an error in formal mode on
14996 qualified expressions for array types with non-matching static bounds.
14997 (Resolve_Type_Conversion): issue an error in formal mode on type
14998 conversion for array types with non-matching static bounds
14999
767bb4e8
AC
150002011-08-02 Robert Dewar <dewar@adacore.com>
15001
15002 * par-ch10.adb: Minor code reorganization (use Nkind_In).
15003
150042011-08-02 Ed Schonberg <schonberg@adacore.com>
15005
15006 * par-ch9.adb: save location of entry for proper error message.
15007
4ac2477e
JM
150082011-08-02 Javier Miranda <miranda@adacore.com>
15009
15010 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
15011 (Use_Full_View) which permits this routine to climb through the
15012 ancestors using the full-view of private parents.
15013 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
15014 Use_Full_View to true in calls to Is_Ancestor.
15015 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
15016 true in call to Is_Ancestor.
15017 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
15018 Use_Full_View to true in call to Is_Ancestor.
15019 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
15020 call to Is_Ancestor.
15021 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
15022 Use_Full_View to true in calls to Is_Ancestor.
15023 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
15024 Make_Select_Specific_Data_Table, Register_Primitive,
15025 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
15026 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
15027 to true in call to Is_Ancestor.
15028 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
15029 Use_Full_View to true in calls to Is_Ancestor.
15030 * exp_cg.adb
15031 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
15032 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
15033
9f90d123
AC
150342011-08-02 Robert Dewar <dewar@adacore.com>
15035
15036 * gnat_rm.texi: Minor reformatting.
15037 * sem_prag.adb: Minor reformatting.
15038
150392011-08-02 Tristan Gingold <gingold@adacore.com>
15040
15041 * vms_data.ads: Add VMS qualifier for -gnateP.
15042
150432011-08-02 Robert Dewar <dewar@adacore.com>
15044
15045 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
15046 * par-ch7.adb (P_Package): Proper placement of aspects for package
15047 decl/instantiation.
15048 * par-endh.adb (Check_End): Ad Is_Sloc parameter
15049 (End_Statements): Add Is_Sloc parameterr
15050 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
15051 (Check_End): Ad Is_Sloc parameter
15052 (End_Statements): Add Is_Sloc parameterr
15053
150542011-08-02 Vincent Celier <celier@adacore.com>
15055
15056 * ug_words: Add VMS qualifier equivalent to -gnateP:
15057 /SYMBOL_PREPROCESSING.
15058
150592011-08-02 Jose Ruiz <ruiz@adacore.com>
15060
15061 * gnat-style.texi: For hexadecimal numeric literals the typical
15062 grouping of digits is 4 to represent 2 bytes.
15063 A procedure spec which is split into several lines is indented two
15064 characters.
15065
150662011-08-02 Yannick Moy <moy@adacore.com>
15067
15068 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
15069 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
15070 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
15071 properly qualified
15072 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
15073 choice in array aggregate
15074 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
15075 mark as ancestor
15076 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
15077 positional and named aggregate for record, or others in record
15078 aggregate, or multiple choice in record aggregate
15079 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
15080 array operands to logical operations AND, OR and XOR do not have the
15081 same static lower and higher bounds
15082 * sem_ch5.adb, sinfo.ads: Correct typos in comments
15083
2933b16c
RD
150842011-08-01 Robert Dewar <dewar@adacore.com>
15085
15086 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
15087 Replaces Last_Source_Node_In_Sequence.
15088 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
15089 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
15090 parens and blank in string (this was inconsistently implemented).
15091 * errout.ads
15092 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
15093 blank in string (this was inconsistently implemented).
15094 * gnat1drv.adb
15095 (Set_Global_Switches): Set formal mode switches appropriately
15096 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
15097 * par-prag.adb
15098 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
15099 call Set_Error_Msg_Lang to set "spark" as language name.
15100 * par.adb: Remove unnecessary call to set formal language for errout
15101 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
15102 appropriately and call Set_Error_Msg_Lang to set "spark" as language
15103 name.
15104 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
15105 calls to it, moved after resolution so that types are known
15106 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
15107 result of concatenation is not of type String
15108 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
15109 concatenation is not properly restricted
15110 * gnat_rm.texi: Add doc on pragma Spark_95.
15111 * gcc-interface/Makefile.in: Remove obsolete target pairs for
15112 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
15113 * gcc-interface/Make-lang.in: Update dependencies.
15114
05dbd302
AC
151152011-08-01 Javier Miranda <miranda@adacore.com>
15116
15117 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
15118 condition that detects if the overridden operation must replace an
15119 existing entity.
15120
151212011-08-01 Javier Miranda <miranda@adacore.com>
15122
15123 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
15124 code declarations inserted by Insert_Actions in each alternative of the
15125 N_Case_Expression node.
15126
151272011-08-01 Robert Dewar <dewar@adacore.com>
15128
15129 * sem_ch6.adb: Minor code reorganization.
15130 * sem_util.adb: Minor reformatting.
15131
af9e051f
PO
151322011-08-01 Pascal Obry <obry@adacore.com>
15133
15134 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
15135 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
15136
1d801f21
AC
151372011-08-01 Yannick Moy <moy@adacore.com>
15138
15139 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
15140 literal or operator symbol which is prefixed
15141 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
15142 mode on access attributes.
15143 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
15144 that concatenation operands are properly restricted in formal mode
15145 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
15146 Analyze_Concatenation_Operand. Issue an error in formal mode if the
15147 result of the concatenation has a type different from String.
15148 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
15149 Analyze_Quantified_Expression, Analyze_Slice,
15150 Analyze_Null): issue an error in formal mode on unsupported constructs
15151 * sem_ch5.adb
15152 (Analyze_Block_Statement): only issue error on source block statement
15153 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
15154 function which returns the last node in a list of nodes for which
15155 Comes_From_Source returns True, if any
15156 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
15157 Last_Source_Node_In_Sequence
15158 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
15159 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
15160 mode on unsupported constructs
15161 * sem_ch9.adb Do not return after issuing error in formal mode, as the
15162 rest of the actions may be needed later on since the error is marked as
15163 not serious.
15164 * sinfo.ads: Typos in comments.
15165
151662011-08-01 Pascal Obry <obry@adacore.com>
15167
15168 * projects.texi: Minor editing.
15169
53beff22
YM
151702011-08-01 Yannick Moy <moy@adacore.com>
15171
15172 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
15173 insertion character ~~
15174 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
15175 (Set_Error_Msg_Lang): new procedure which fixes the language for use
15176 with insertion character ~~
15177 (Set_Msg_Text): treat insertion character ~~
15178 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
15179 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
15180 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
15181 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
15182 errors related to the formal language restriction not serious
15183 (insertion character |).
15184 * par.adb (Par): set formal language for error messages if needed
15185 * sem_ch6.adb (Check_Missing_Return): take into account possible
15186 generated statements at the end of the function
15187 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
15188 enumeration value to define a new pragma SPARK_95
15189 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
15190 SPARK_Version): new type and variables to store the SPARK version
15191 (none by default).
15192 (SPARK_Mode): return True when SPARK_Version is set
15193 * par-prag.adb: Correct indentation
15194 (Prag): take Pragma_SPARK_95 into account
15195 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
15196 into account.
15197
8d606a78
RD
151982011-08-01 Robert Dewar <dewar@adacore.com>
15199
15200 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
15201 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
15202 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
15203
1982d5a8
PO
152042011-08-01 Pascal Obry <obry@adacore.com>
15205
15206 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
15207 Target_Name to Get_Path call.
15208 (Parse_Single_Project): Likewise.
15209 (Post_Parse_Context_Clause): Likewise.
15210 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
15211 Call Initialise_Project_Path with the proper Target_Name.
15212 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
15213 search path.
15214 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
15215 with the proper Target_Name.
15216 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
15217 Part.Parse routine.
15218 (Parse_Project_And_Apply_Config): Likewise.
15219 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
15220 This is fine as this part of the code is supporting only native
15221 compilation.
15222 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
15223 is fine as this part of the code is supporting only native compilation.
15224
0d53d36b
AC
152252011-08-01 Yannick Moy <moy@adacore.com>
15226
15227 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
15228 of homonym, unless the homonym is one of the cases allowed in SPARK
15229 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
15230 package declaration occurring after a body.
15231
152322011-08-01 Robert Dewar <dewar@adacore.com>
15233
15234 * checks.adb, exp_ch4.adb: Minor reformatting.
15235
152362011-08-01 Javier Miranda <miranda@adacore.com>
15237
15238 * einfo.ads (Access_Disp_Table): Fix documentation.
15239 (Dispatch_Table_Wrappers): Fix documentation.
15240
152412011-08-01 Pascal Obry <obry@adacore.com>
15242
15243 * prj-env.adb, prj-env.ads: Minor reformatting.
15244
8ed68165
AC
152452011-08-01 Yannick Moy <moy@adacore.com>
15246
15247 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
15248 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
15249 procedures out of these packages.
2c7f9cc0 15250 * errout.ads, errout.adb
8ed68165
AC
15251 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
15252 procedures in of this package
15253 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
15254 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
15255 on misplaced later vs initial declarations, like in Ada 83
15256 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
15257 formal mode on attribute of private type whose full type declaration
15258 is not visible
15259 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
15260 package declaration inside a package specification
15261 (Analyze_Full_Type_Declaration): issue error in formal mode on
15262 controlled type or discriminant type
15263 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
15264 user-defined operator means that it should come from the source
15265 (New_Overloaded_Entity): issue error in formal mode on overloaded
15266 entity.
15267 * sem_ch6.ads, sem_ch13.ads: typos in comments.
15268
152692011-08-01 Thomas Quinot <quinot@adacore.com>
15270
15271 * atree.adb: Minor reformatting.
15272 * checks.adb: Minor reformatting.
15273
4230bdb7
AC
152742011-08-01 Vincent Celier <celier@adacore.com>
15275
15276 * s-parame-vms-ia64.ads: Fix typo in comment
15277 Minor reformatting
15278 * s-parame-vms-restrict.ads: Removed, unused.
15279
152802011-08-01 Javier Miranda <miranda@adacore.com>
15281
15282 * exp_ch3.adb
15283 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
15284 * sem_ch3.adb
15285 (Constrain_Index): Remove side effects in the evaluation of the bounds.
15286 * sem_ch3.ads, sem_ch3.adb
15287 (Is_Constant_Bound): New extended version of the subprogram that was
15288 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
15289 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
15290 * sem_aux.ads (Constant_Value): Fix typo in comment.
15291 * checks.adb (Generate_Index_Checks): New implementation which, for
15292 array objects with constant bounds, generates the runtime check
15293 referencing the bounds of the array type. For other cases this routine
15294 provides its previous behavior obtaining such values from the array
15295 object.
15296 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
15297 parent type.
15298 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
15299 we cannot have semantic interpretations of the new node.
15300
2010d078
AC
153012011-08-01 Ed Schonberg <schonberg@adacore.com>
15302
15303 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
15304 expressions.
15305
153062011-08-01 Arnaud Charlet <charlet@adacore.com>
15307
15308 * sem_ch8.adb: Minor code editing.
15309 * s-vxwext.adb: Remove trailing space.
15310 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
15311 consistency with other files.
15312
153132011-08-01 Thomas Quinot <quinot@adacore.com>
15314
15315 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
15316
153172011-08-01 Ed Schonberg <schonberg@adacore.com>
15318
15319 * par-ch10.adb: reject parameterized expressions as compilation unit.
15320 * sem_ch4.adb: handle properly conditional expression with overloaded
15321 then_clause and no else_clause.
15322
153232011-08-01 Tristan Gingold <gingold@adacore.com>
15324
15325 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
15326 like done by System.Aux_DEC.
15327 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
15328
daec8eeb
YM
153292011-08-01 Yannick Moy <moy@adacore.com>
15330
15331 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
15332 missing label at end of declaration (subprogram or package)
15333 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
15334 of positional and named parameter association
15335 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
15336 Error_Msg_SP which adds a prefix to the error message giving the name
15337 of the formal language analyzed
15338 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
15339 access result type in subprogram, unconstrained array as result type,.
15340 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
15341 procedure
15342 * sem_ch8.adb: Code clean up.
15343
38171f43
AC
153442011-08-01 Javier Miranda <miranda@adacore.com>
15345
15346 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
15347 * einfo.ads (Access_Disp_Table): Fix documentation.
15348 (Dispatch_Table_Wrappers): Fix documentation.
15349 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
15350 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
15351 to enforce the documentation of this attribute.
15352 (Set_Is_Interface): Cleanup the assertion.
15353 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
15354 the Underlying_Type entity before reading attribute Access_Disp_Table.
15355 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
15356 Locate the Underlying_Type before reading attribute Access_Disp_Table.
15357 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
15358 the Underlying_Type entity before reading attribute Access_Disp_Table.
15359 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
15360 Locate the Underlying_Type entity before reading attribute
15361 Access_Disp_Table.
15362
153632011-08-01 Ed Schonberg <schonberg@adacore.com>
15364
15365 * s-poosiz.ads: Additional overriding indicators.
15366
153672011-08-01 Yannick Moy <moy@adacore.com>
15368
15369 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
15370 formal mode.
15371 (Analyze_Iteration_Scheme): issue error in formal mode when loop
15372 parameter specification does not include a subtype mark.
15373 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
15374 formal mode on abstract subprogram.
15375 (Analyze_Subprogram_Specification): issue error in formal mode on
15376 user-defined operator.
15377 (Process_Formals): issue error in formal mode on access parameter and
15378 default expression.
15379 * sem_ch9.adb (Analyze_Abort_Statement,
15380 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
15381 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
15382 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
15383 Analyze_Requeue, Analyze_Selective_Accept,
15384 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
15385 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
15386 issue error in formal mode on user-defined raise statement.
15387
1f250383
AC
153882011-08-01 Thomas Quinot <quinot@adacore.com>
15389
15390 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
15391 declaration being hidden when overriding an implicit inherited
15392 subprogram.
15393 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
15394 (-gnats), do not complain about a source file that contains only a
15395 pragma No_Body.
15396
153972011-08-01 Ed Schonberg <schonberg@adacore.com>
15398
15399 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
15400 variable if already set.
15401
607d0635
AC
154022011-08-01 Arnaud Charlet <charlet@adacore.com>
15403
15404 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
15405 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
15406 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
15407 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
15408 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
15409 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
15410 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
15411 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
15412 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
15413 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
15414 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
15415 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
15416 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
15417 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
15418 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
15419 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
15420 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
15421 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
15422 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
15423 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
15424 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
15425 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
15426 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
15427 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
15428 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
15429 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
15430 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
15431 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
15432 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
15433 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
15434 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
15435 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
15436 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
15437 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
15438 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
15439 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
15440 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
15441 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
15442 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
15443 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
15444 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
15445 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
15446 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
15447 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
15448 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
15449 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
15450 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
15451 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
15452 s-osinte-mingw.ads: Update to GPLv3 run-time license.
15453 Use GNAT instead of GNARL.
15454
154552011-08-01 Bob Duff <duff@adacore.com>
15456
15457 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
15458 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
15459 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
15460 reformatting.
15461
154622011-08-01 Yannick Moy <moy@adacore.com>
15463
15464 * debug.adb (d.D) reverve flag for the SPARK mode
15465 (d.E) reverve flag for SPARK generation mode
15466 (d.F) reverve flag for Why generation mode
2c7f9cc0 15467 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
607d0635
AC
15468 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
15469 functions which return True when the corresponding modes are set
15470 (Formal_Language): return "spark" or "alfa" when in formal verification
15471 mode.
15472 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
15473 Error_Msg to prefix the error message with a tag giving the formal
15474 language
15475 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
15476 message with a tag giving the formal language
15477 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
15478 block statement
15479 (Analyze_Case_Statement): issue error in formal mode on case statement
15480 with a single "others" case alternative
15481 (Analyze_Exit_Statement): issue errors in formal mode on exit
15482 statements which do not respect SPARK restrictions
15483 (Analyze_Goto_Statement): issue error in formal mode on goto statement
15484 (Check_Unreachable_Code): always issue an error (not a warning) in
15485 formal mode on unreachable code (concerns both code after an infinite
15486 loop and after an unconditional jump, both not allowed in SPARK)
15487 * sem_ch6.adb (Analyze_Return_Statement): add call to
15488 Set_Return_Present for a procedure containing a return statement
15489 (already done for functions in Analyze_Function_Return)
15490 (Analyze_Function_Return): issue error in formal mode on extended
15491 return or if return is not last statement in function
15492 (Check_Missing_Return): issue error in formal mode if function does
15493 not end with return or if procedure contains a return
15494 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
15495 function to detect if there is an inner scope of its parameter S which
15496 is a loop.
15497
154982011-08-01 Thomas Quinot <quinot@adacore.com>
15499
15500 * sem_ch6.ads: Minor reformatting.
15501
d8b3ccb9
AC
155022011-08-01 Javier Miranda <miranda@adacore.com>
15503
15504 * sem_util.adb (Abstract_Interface_List): Complete condition when
15505 processing private type declarations to avoid reading unavailable
15506 attribute.
15507 (Is_Synchronized_Tagged_Type): Complete condition when processing
15508 private extension declaration nodes to avoid reading unavailable
15509 attribute.
15510
155112011-08-01 Thomas Quinot <quinot@adacore.com>
15512
15513 * sem_ch3.adb: Minor reformatting.
15514
155152011-08-01 Thomas Quinot <quinot@adacore.com>
15516
15517 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
15518 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
15519 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
15520 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
15521 for VMS, instead parametrize the common implementation with
15522 System.Parameters declarations.
15523
0bb9276c
AC
155242011-08-01 Eric Botcazou <ebotcazou@adacore.com>
15525
15526 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
15527
155282011-08-01 Tristan Gingold <gingold@adacore.com>
15529
15530 * seh_init.c: Fix SEH handler installation on win64.
15531
155322011-08-01 Ed Schonberg <schonberg@adacore.com>
15533
15534 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
15535 double analysis of an anonymous access to subprogram, because it can
15536 lead to improper sharing of profiles and a back-end crash.
15537
6a2e4f0b
AC
155382011-08-01 Robert Dewar <dewar@adacore.com>
15539
15540 * make.adb, sem_ch4.adb: Minor reformatting.
15541 * gcc-interface/Make-lang.in: Update dependencies.
15542 * sem_util.adb, exp_ch5.adb: Minor reformatting.
15543
155442011-08-01 Arnaud Charlet <charlet@adacore.com>
15545
15546 * gnat_rm.texi: Fix definition of Long_Integer.
15547
155482011-08-01 Ed Schonberg <schonberg@adacore.com>
15549
15550 * exp_aggr.adb: check limit size of static aggregate unconditionally,
15551 to prevent storage exhaustion.
15552 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
15553 finalized is a function body, insert the cleanup code before the final
15554 return statement, to prevent spurious warnings.
15555 * s-pooglo.ads: add overriding indicator.
15556
4561baf7
ES
155572011-08-01 Ed Schonberg <schonberg@adacore.com>
15558
15559 * sem_ch4.adb (Operator_Check): improve error message when both a
15560 with_clause and a use_clause are needed to make operator usage legal.
15561 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
15562 determine whether a compilation unit is visible within an other,
15563 either through a with_clause in the current unit, or a with_clause in
15564 its library unit or one one of its parents.
15565
383e179e
AC
155662011-08-01 Ed Schonberg <schonberg@adacore.com>
15567
15568 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
15569 over an arbitrary expression of an array or container type.
15570 * lib-xref.adb: clarify comment.
15571
155722011-08-01 Bob Duff <duff@adacore.com>
15573
15574 * einfo.ads: Minor reformatting.
15575 * debug.adb: Minor comment improvement.
15576
155772011-08-01 Javier Miranda <miranda@adacore.com>
15578
15579 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
15580 consider hidden subprograms as valid candidates.
15581
155822011-08-01 Arnaud Charlet <charlet@adacore.com>
15583
15584 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
15585
155862011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
15587
15588 * gnat_ugn.texi: Fix typo.
15589
61c161b2
AC
155902011-08-01 Robert Dewar <dewar@adacore.com>
15591
15592 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
15593 lib-xref.adb: Minor reformatting
15594
155952011-08-01 Gary Dismukes <dismukes@adacore.com>
15596
15597 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
15598 when to generate a call to Move_Final_List.
15599 (Has_Controlled_Parts): Remove this function.
15600
84df40f7
AC
156012011-08-01 Geert Bosch <bosch@adacore.com>
15602
15603 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
15604 "," in choice list.
15605
156062011-08-01 Thomas Quinot <quinot@adacore.com>
15607
15608 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
15609 explicit raise of a predefined exception as Comes_From_Source if the
15610 original N_Raise_Statement comes from source.
15611
156122011-08-01 Robert Dewar <dewar@adacore.com>
15613
15614 * sinfo.ads: Add comment.
15615 * sem_ch6.adb: Minor reformatting.
15616
156172011-08-01 Robert Dewar <dewar@adacore.com>
15618
15619 * freeze.adb (Freeze_Entity): Refine check for bad component size
15620 clause to avoid rejecting confirming clause when atomic/aliased present.
15621
156222011-08-01 Ed Schonberg <schonberg@adacore.com>
15623
15624 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
15625 better determine whether an entity reference is a write.
15626 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
15627 subcomponent.
15628 * lib-xref.adb (Output_References): Do no suppress a read reference at
15629 the same location as an immediately preceeding modify-reference, to
15630 handle properly in-out actuals.
15631
156322011-08-01 Tristan Gingold <gingold@adacore.com>
15633
15634 * env.c (__gnat_setenv) [VMS]: Refine previous change.
15635
156362011-08-01 Quentin Ochem <ochem@adacore.com>
15637
15638 * i-cstrin.adb (New_String): Changed implementation, now uses only the
15639 heap to compute the result.
15640
c7f0d2c0
AC
156412011-08-01 Robert Dewar <dewar@adacore.com>
15642
15643 * atree.ads: Minor reformatting.
15644
156452011-08-01 Emmanuel Briot <briot@adacore.com>
15646
15647 * g-expect.adb (Get_Command_Output): Fix memory leak.
15648
156492011-08-01 Geert Bosch <bosch@adacore.com>
15650
15651 * cstand.adb (P_Float_Type): New procedure to print the definition of
15652 predefined fpt types.
15653 (P_Mixed_Name): New procedure to print a name using mixed case
15654 (Print_Standard): Use P_Float_Type for printing floating point types
15655 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
15656 precision IEEE float.
15657
156582011-08-01 Thomas Quinot <quinot@adacore.com>
15659
15660 * sem_ch3.adb: Minor reformatting.
15661
156622011-08-01 Ed Schonberg <schonberg@adacore.com>
15663
15664 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
15665 the completion of a generic function, insert the new body rather than
15666 rewriting the original.
15667
156682011-08-01 Yannick Moy <moy@adacore.com>
15669
15670 * sinfo.ads, errout.ads: Typos in comments.
15671
1c54829e
AC
156722011-08-01 Robert Dewar <dewar@adacore.com>
15673
15674 * par-endh.adb: Minor reformatting.
15675
156762011-08-01 Robert Dewar <dewar@adacore.com>
15677
15678 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
15679 (Pre_Post_Aspects): New subtype.
15680 * par-ch12.adb (P_Generic): New syntax for aspects in packages
15681 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
15682 * par-ch7.adb (P_Package): Remove Decl parameter
15683 (P_Package): Handle new syntax for aspects (before IS)
15684 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
15685 new aspect syntax
15686 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
15687 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
15688 (P_Package): Remove Decl parameter
15689 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
15690 aspects
15691 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
15692 specs
15693 * sem_util.ads, sem_util.adb (Static_Boolean): New function
15694 * sinfo.ads: Document new syntax for aspects in packages etc.
15695 * sprint.adb: Handle new syntax of aspects before IS in package
15696
156972011-08-01 Thomas Quinot <quinot@adacore.com>
15698
15699 * atree.ads: Minor reformatting.
15700 * sem_prag.adb: Minor reformatting.
15701
157022011-08-01 Robert Dewar <dewar@adacore.com>
15703
15704 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
15705 case expr alternative.
15706
157072011-08-01 Ed Schonberg <schonberg@adacore.com>
15708
15709 * sem_ch12.adb: Fix typo.
15710
9eea4346
GB
157112011-08-01 Geert Bosch <bosch@adacore.com>
15712
15713 * sem_prag.adb (Check_No_Link_Name): New procedure.
15714 (Process_Import_Or_Interface): Use Check_No_Link_Name.
15715 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
15716 instead of Standard_Long_Long_Float_Size global. Preparation for
15717 eventual removal of per type constants.
15718 * exp_util.ads (Get_Stream_Size): New function returning the stream
15719 size value of subtype E.
15720 * exp_util.adb (Get_Stream_Size): Implement new function.
15721 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
15722 function.
15723 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
15724 * einfo.adb:
15725 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
15726
3d6c3bd7
GB
157272011-08-01 Geert Bosch <bosch@adacore.com>
15728
15729 * cstand.adb: Fix comments.
15730 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
15731 count of arguments.
15732
e7d897b8
AC
157332011-08-01 Robert Dewar <dewar@adacore.com>
15734
15735 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
15736
157372011-08-01 Geert Bosch <bosch@adacore.com>
15738
15739 * atree.ads: Fix comment.
15740
c228a069
AC
157412011-08-01 Robert Dewar <dewar@adacore.com>
15742
15743 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
15744 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
15745 * par.adb: Add with for Namet.Sp.
15746 * par-tchk.adb: Minor reformatting.
15747
157482011-08-01 Vincent Celier <celier@adacore.com>
15749
15750 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
15751 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
15752 of the init procedure of a SAL.
15753 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
15754 New procedure.
15755
157562011-08-01 Thomas Quinot <quinot@adacore.com>
15757
15758 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
15759 reformatting.
15760
157612011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
15762
15763 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
15764
157652011-08-01 Thomas Quinot <quinot@adacore.com>
15766
15767 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
15768 conformant with its spec (return True only for types that have
15769 an overriding Initialize primitive operation that prevents them from
15770 having preelaborable initialization).
15771 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
15772 initialization for controlled types in Ada 2005 or later mode.
15773
857ade1b
RD
157742011-08-01 Robert Dewar <dewar@adacore.com>
15775
15776 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
15777 Postcondition.
15778 (Same_Aspect): New function.
15779 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
15780 Type_Invariant, Precondition, Postcondition.
15781 * snames.ads-tmpl: Add Name_Type_Invariant.
15782
bd949ee2
RD
157832011-08-01 Robert Dewar <dewar@adacore.com>
15784
15785 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
15786 here.
15787 (Freeze_All_Ent): Fix error in handling inherited aspects.
15788 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
15789 already analyzed, but don't skip entire processing of a declaration,
15790 that's wrong in some cases of declarations being rewritten.
15791 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
15792 Don't delay for integer, string literals
15793 Treat predicates in usual manner for delay, remove special case code,
15794 not needed.
15795 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
15796 (Build_Predicate_Function): Update saved expression in aspect
15797 (Build_Invariant_Procedure): Update saved expression in aspect
15798 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
15799 of replacement of discriminant references if the reference is simple.
15800
f1c952af
RD
158012011-08-01 Robert Dewar <dewar@adacore.com>
15802
15803 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
15804 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
15805 Static_Predicate and Dynamic_Predicate.
15806 (Build_Predicate_Function): Add processing for Static_Predicate
15807 and Dynamic_Predicate.
15808 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
15809 (From_Static_Predicate): New flag
15810 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
15811
158122011-08-01 Robert Dewar <dewar@adacore.com>
15813
15814 * usage.adb: Documentation cleanup for Ada version modes in usage.
15815 * expander.adb: Minor reformatting.
15816
47e11d08
AC
158172011-08-01 Robert Dewar <dewar@adacore.com>
15818
15819 * atree.ads: Minor comment fix.
15820 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
15821 a-witeio.ads, sem_prag.adb: Minor reformatting.
15822
158232011-08-01 Doug Rupp <rupp@adacore.com>
15824
15825 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
15826 pointers. Use descrip.h header file for convenience. Add some
15827 comments.
15828
158292011-08-01 Robert Dewar <dewar@adacore.com>
15830
15831 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
15832 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
15833 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
15834 New procedure.
15835 (Check_Aspect_At_End_Of_Declarations): New procedure
15836 (Analye_Aspect_Specification): Minor changes for above procedures
15837 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
15838 specification node as well.
15839
158402011-08-01 Pascal Obry <obry@adacore.com>
15841
15842 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
15843 Windows files. Use GetFilesAttributes() in this case to check for file
15844 existence instead of returning with an error code.
15845
a3a16b21
VC
158462011-08-01 Vincent Celier <celier@adacore.com>
15847
15848 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
15849 High is above Source length.
15850
ff58cc69
RD
158512011-08-01 Robert Dewar <dewar@adacore.com>
15852
15853 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
15854
6bb88533
AC
158552011-08-01 Robert Dewar <dewar@adacore.com>
15856
15857 * aspects.ads (Boolean_Aspects): New subtype.
15858 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
15859 for derived types in cases where the parent type and derived type have
15860 aspects.
15861 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
15862 with aspects when parent type also has aspects.
15863 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
15864 boolean expression at this point).
15865 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
15866 accordance with final decision on the Ada 2012 feature.
15867 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
15868
158692011-08-01 Matthew Heaney <heaney@adacore.com>
15870
15871 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
15872
060a3f28
AC
158732011-08-01 Pascal Obry <obry@adacore.com>
15874
15875 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
15876 Fix Replace_Slice when High is above current string size.
15877 (Replace_Slice): Fix DL computation when High is above current
15878 string length.
15879
158802011-08-01 Gary Dismukes <dismukes@adacore.com>
15881
15882 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
15883
e7f567a3
AC
158842011-08-01 Matthew Heaney <heaney@adacore.com>
15885
15886 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
15887 of node.
15888
158892011-08-01 Pascal Obry <obry@adacore.com>
15890
15891 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
15892 reformatting.
15893
1a265e78
AC
158942011-08-01 Ed Schonberg <schonberg@adacore.com>
15895
15896 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
15897 access to protected subprograms in generic bodies.
15898 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
15899 protected type, indicate that the convention of the subprogram is
15900 Convention_Protected, because it may be used in subsequent declarations
15901 within the protected declaration.
15902
159032011-08-01 Vincent Celier <celier@adacore.com>
15904
15905 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
15906 and "final" procedures when the name of the library is "ada", to avoid
15907 duplicate symbols "adainit" and "adafinal" in executables.
15908
67e28ef8
ES
159092011-08-01 Ed Schonberg <schonberg@adacore.com>
15910
15911 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
15912 quantified expression that appears within a postcondition and uses the
15913 Ada2012 'Result attribute.
15914
6da2ca7d
RO
159152011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15916
15917 * init.c (__gnat_error_handler): Cast reason to int.
15918 (__gnat_install_handler): Explain sa_sigaction use.
15919
7d5997c6
EB
159202011-07-24 Eric Botcazou <ebotcazou@adacore.com>
15921
15922 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
15923 subprogram has copy-in copy-out parameters, try to promote the mode of
15924 the return type if it is passed in registers.
15925
4b4cfdd5
EB
159262011-07-24 Eric Botcazou <ebotcazou@adacore.com>
15927
15928 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
15929 left operand as addressable.
15930
f3d34576
EB
159312011-07-24 Eric Botcazou <ebotcazou@adacore.com>
15932
15933 * gcc-interface/gigi.h (build_function_stub): Remove.
15934 (build_return_expr): Likewise.
15935 (convert_vms_descriptor): Declare.
15936 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
15937 (build_function_stub): Move to...
15938 * gcc-interface/utils2.c (build_return_expr): Move to...
15939 * gcc-interface/trans.c (build_function_stub): ...here.
15940 (build_return_expr): ...here.
15941 (Subprogram_Body_to_gnu): Add local variable for language_function.
15942 Disconnect the parameter attributes cache, if any, once done with it.
15943 Call end_subprog_body only after setting the end_locus.
15944 Build the stub associated with the function, if any, at the very end.
15945 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
15946 variables and streamline control flow.
15947
0a6ecc08
AC
159482011-07-23 Arnaud Charlet <charlet@adacore.com>
15949
15950 PR ada/49819
15951 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
15952 g-trasym-dwarf.adb.
15953
5b6d595b
RO
159542011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15955
15956 PR bootstrap/49794
15957 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
15958 Assign to act.sa_sigaction.
15959 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
15960 current->return_address to char * before arithmetic.
15961
94017021
RO
159622011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15963
15964 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
15965 Correct argument types.
15966 Extract code from reason.
15967 (__gnat_install_handler): Assign to act.sa_sigaction.
15968
52fd02bb
EB
159692011-07-21 Eric Botcazou <ebotcazou@adacore.com>
15970
15971 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
15972 (GNAT1_OBJS): ...here.
15973
f39a9ca2
EB
159742011-07-15 Eric Botcazou <ebotcazou@adacore.com>
15975
15976 PR ada/48711
15977 * g-socthi-mingw.adb (Fill): Fix formatting.
15978
9e36aa23
EB
15979 * gcc-interface/gigi.h: Move around comment.
15980
e3aca522
JDA
159812011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
15982
15983 PR ada/46350
15984 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
15985
696b1960
FW
159862011-07-14 Florian Weimer <fw@deneb.enyo.de>
15987
15988 PR ada/48711
15989 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
15990
f542c405
EB
159912011-07-13 Eric Botcazou <ebotcazou@adacore.com>
15992
15993 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
15994 range comparison if Pmode is SImode.
15995
9e9bd455
LG
159962011-07-12 Laurent GUERBY <laurent@guerby.net>
15997 Eric Botcazou <ebotcazou@adacore.com>
15998
15999 * adadecode.c: Wrap up in extern "C" block.
16000 * adadecode.h: Likewise.
16001 * adaint.c: Likewise. Remove 'const' keyword.
16002 * adaint.h: Likewise.
16003 * argv.c: Likewise.
16004 * atree.h: Likewise.
16005 * cio.c: Likewise.
16006 * cstreams.c: Likewise.
16007 * env.c: Likewise.
16008 * exit.c: Likewise.
16009 * fe.h: Likewise.
16010 * final.c: Likewise.
16011 * init.c: Likewise.
16012 * initialize.c: Likewise.
16013 * link.c: Likewise.
16014 * namet.h: Likewise.
16015 * nlists.h: Likewise.
16016 * raise.c: Likewise.
16017 * raise.h: Likewise.
16018 * repinfo.h: Likewise.
16019 * seh_init.c: Likewise.
16020 * targext.c: Likewise.
16021 * tracebak.c: Likewise.
16022 * uintp.h: Likewise.
16023 * urealp.h: Likewise.
16024 * xeinfo.adb: Wrap up generated C code in extern "C" block.
16025 * xsinfo.adb: Likewise.
16026 * xsnamest.adb: Likewise.
16027 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
16028 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
16029 * gcc-interface/misc.c: Likewise.
16030 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
16031 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
16032 ada/targext.o here...
16033 (GNAT_ADA_OBJS): ...and not here.
16034 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
16035 (GNATBIND_OBJS): Reorder.
16036
7644b3c7
RH
160372011-07-07 Richard Henderson <rth@redhat.com>
16038
16039 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
16040 dwarf2out_frame_init.
16041
8384ac41
EB
160422011-07-07 Eric Botcazou <ebotcazou@adacore.com>
16043
16044 * gcc-interface/misc.c (gnat_init): Tweak previous change.
16045
fbdd5d87
RO
160462011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
16047
16048 PR target/39150
16049 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
16050
1a072294
RG
160512011-07-06 Richard Guenther <rguenther@suse.de>
16052
8384ac41
EB
16053 * gcc-interface/misc.c (gnat_init): Merge calls to
16054 build_common_tree_nodes and build_common_tree_nodes_2.
1a072294
RG
16055 Re-initialize boolean_false_node.
16056
bc712852
EB
160572011-07-02 Eric Botcazou <ebotcazou@adacore.com>
16058 Olivier Hainque <hainque@adacore.com>
16059 Nicolas Setton <setton@adacore.com>
16060
16061 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
16062 the type according to the ARTIFICIAL_P parameter.
16063 (create_type_decl): Likewise.
16064 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
16065
2eb22389
EB
160662011-07-01 Eric Botcazou <ebotcazou@adacore.com>
16067
16068 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
16069 (gnatbind): Likewise.
16070
4bdaaf2f
RO
160712011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
16072
16073 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
16074
c020c92b
EB
160752011-06-18 Eric Botcazou <ebotcazou@adacore.com>
16076
16077 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
16078 local variable throughout. Remove useless call to Base_Type.
16079 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
16080 Take it also into account for the volatileness of the field. Set the
16081 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
16082
96769d32
EB
160832011-06-18 Eric Botcazou <ebotcazou@adacore.com>
16084
16085 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
16086 on a dereference built for a by-ref object if it has an address clause.
16087
7e4680c1
EB
160882011-06-18 Eric Botcazou <ebotcazou@adacore.com>
16089
16090 * einfo.ads (Address_Taken): Document use for the second argument of
16091 Asm_Input and Asm_Output attributes.
16092 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
16093 argument is an entity name, then set Address_Taken on it.
16094 <Attribute_Asm_Output>: Likewise.
16095 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
16096 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
16097 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
16098 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
16099
161002011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
d5cc9181
JR
16101
16102 PR middle-end/46500
16103 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
16104
677f3fa8
JM
161052011-06-14 Joseph Myers <joseph@codesourcery.com>
16106
16107 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
16108 (ada/utils.o): Update dependencies.
16109 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
16110 ../../../libcpp/libcpp.a.
16111 * gcc-interface/utils.c: Include common/common-target.h.
16112 (process_attributes): Use targetm_common.have_named_sections.
16113
009db074
RG
161142011-06-07 Richard Guenther <rguenther@suse.de>
16115
0bad0e23
EB
16116 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
16117 set_sizetype.
009db074 16118
3bfc61cf
EB
161192011-06-06 Eric Botcazou <ebotcazou@adacore.com>
16120
0bad0e23 16121 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
3bfc61cf
EB
16122 TREE_THIS_NOTRAP flag.
16123
5c4a1c7b
EB
161242011-06-06 Eric Botcazou <ebotcazou@adacore.com>
16125
16126 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
16127 Fix thinko.
16128
e9f57686
EB
161292011-06-06 Eric Botcazou <ebotcazou@adacore.com>
16130
16131 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
16132 constants whose full view has discriminants specially.
16133
10e4d056
EB
161342011-06-06 Eric Botcazou <ebotcazou@adacore.com>
16135
16136 * gcc-interface/utils.c: Include diagnostic.h.
16137 (gnat_write_global_declarations): Output debug information for all
16138 global type declarations before finalizing the compilation unit.
16139 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
16140
0957c029
JJ
161412011-05-25 Jakub Jelinek <jakub@redhat.com>
16142
16143 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
16144
52d0a7ac
KT
161452011-05-25 Kai Tietz <ktietz@redhat.com>
16146
16147 * adaint.c (__gnat_to_canonical_file_list_next): Use array
16148 initialization instead of const/none-const pointer assignment.
16149
1ed1641d
JM
161502011-05-24 Joseph Myers <joseph@codesourcery.com>
16151
16152 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
16153 $(EXTRA_GNAT1_OBJS).
16154 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
16155 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
16156 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
16157 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
16158 libcommon-target.a instead of prefix.o.
16159
9fe72ebd
JM
161602011-05-21 Joseph Myers <joseph@codesourcery.com>
16161
16162 PR ada/49097
0bad0e23 16163 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
9fe72ebd 16164
2691e6d7
JM
161652011-05-20 Joseph Myers <joseph@codesourcery.com>
16166
0bad0e23
EB
16167 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
16168 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
16169 instead of version.o.
2691e6d7 16170
2d0dd51a 161712011-05-18 Kai Tietz <ktietz@redhat.com>
bf6490b5
KT
16172
16173 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
16174 boolean_false_node instead of integer_zero_node.
16175 (convert_with_check): Likewise.
16176 * gcc-interface/decl.c (choices_to_gnu): Likewise.
16177
7bf9a5ac
EB
161782011-05-12 Eric Botcazou <ebotcazou@adacore.com>
16179
16180 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
16181 type of the parameter is an unconstrained array, convert the actual to
16182 the type of the formal in the In Out and Out cases as well.
16183
e5b00edf
NF
161842011-05-11 Nathan Froyd <froydnj@codesourcery.com>
16185
16186 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
16187 call build_function_type_array or build_varargs_function_type_array
16188 instead.
16189 (create_subprog_type): Don't call build_function_type; call
16190 build_function_type_vec instead.
16191
51545682
NF
161922011-05-11 Nathan Froyd <froydnj@codesourcery.com>
16193
16194 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
16195 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
16196 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
16197
c99c0026
EB
161982011-05-07 Eric Botcazou <ebotcazou@adacore.com>
16199
f620bd21
EB
16200 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
16201
c99c0026
EB
16202 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
16203 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
16204
3d528853
NF
162052011-05-05 Nathan Froyd <froydnj@codesourcery.com>
16206
c99c0026 16207 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
3d528853 16208
d7d058c5
NF
162092011-05-05 Nathan Froyd <froydnj@codesourcery.com>
16210
16211 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
16212 instead of accessing TYPE_ARG_TYPES directly.
16213 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
16214
805e60a0
EB
162152011-05-05 Eric Botcazou <ebotcazou@adacore.com>
16216
16217 PR ada/48844
16218 * gcc-interface/gigi.h (get_variant_part): Declare.
16219 * gcc-interface/decl.c (get_variant_part): Make global.
16220 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
16221 types have the same constant size, are record types and T1 has a
16222 variant part while T2 doesn't.
16223
907a08d9
EB
162242011-05-05 Eric Botcazou <ebotcazou@adacore.com>
16225
16226 * gcc-interface/utils.c (begin_subprog_body): Do not call
16227 get_pending_sizes.
16228 (end_subprog_body): Likewise.
16229
d35936ab
RG
162302011-05-04 Richard Guenther <rguenther@suse.de>
16231
16232 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
16233 int_const_binop.
16234 (pos_to_constructor): Likewise.
16235
c1fd8753 162362011-05-03 Nathan Froyd <froydnj@codesourcery.com>
2c7f9cc0 16237 Eric Botcazou <ebotcazou@adacore.com>
c1fd8753
NF
16238
16239 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
16240 of build_function_type. Adjust calls to...
16241 (build_raise_check): ...this. Do not take a void_tree parameter.
16242 Call build_function_type_list instead of build_function_type.
16243 Fix head comment and swap couple of conditional blocks.
16244
4fb87d2b
EB
162452011-04-30 Eric Botcazou <ebotcazou@adacore.com>
16246
16247 * gnatvsn.ads (Library_Version): Bump to 4.7.
16248 (Current_Year): Bump to 2011.
16249
fa5e5a76
MM
162502011-04-29 Michael Matz <matz@suse.de>
16251
16252 * gcc-interface/misc.c (gnat_handle_option): Set
16253 warn_maybe_uninitialized.
16254
8d6a2f69
GP
162552011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
16256
16257 * gnat_ugn.texi (Complexity Metrics Control): Update link to
16258 the Watson/McCabe paper.
16259
770937fd
JM
162602011-04-23 Jim Meyering <meyering@redhat.com>
16261
16262 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
16263
eb601ae1
EB
162642011-04-22 Eric Botcazou <ebotcazou@adacore.com>
16265
16266 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
16267 onto the new type.
16268
7d7fcb08
EB
162692011-04-22 Eric Botcazou <ebotcazou@adacore.com>
16270
16271 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
16272 parameter.
16273 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
16274 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
16275 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
16276 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
16277 <all>: Do not set flags on the reused DECL node coming from an alias.
16278 Set DECL_IGNORED_P on the DECL node built for subprograms if they
16279 don't need debug info here...
16280 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
16281 (gigi): Adjust calls to create_subprog_decl.
16282 (build_raise_check): Likewise.
16283 (establish_gnat_vms_condition_handler): Likewise.
16284 (Compilation_Unit_to_gnu): Likewise.
16285 (gnat_to_gnu): Likewise.
16286
e1876cac
EB
162872011-04-21 Eric Botcazou <ebotcazou@adacore.com>
16288
16289 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
16290 (NO_REORDER_ADAFLAGS): New variable.
16291 (EXTRA_GNATTOOLS): Always define.
16292 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
16293 Clean up and adjust list of files compiled with special options.
16294 * gcc-interface/Make-lang.in: Likewise.
16295 (ada/decl.o): Cosmetical change.
16296 (ada/misc.o): Remove dependency on $(PLUGIN_H).
16297
04695783
JM
162982011-04-20 Jim Meyering <meyering@redhat.com>
16299
16300 * initialize.c (__gnat_initialize): Remove useless if-before-free.
16301
23399579
EB
163022011-04-17 Eric Botcazou <ebotcazou@adacore.com>
16303
16304 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
16305 $(CFLAGS) on the link line.
16306
51c5169c
EB
163072011-04-17 Eric Botcazou <ebotcazou@adacore.com>
16308
16309 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
16310 padded type built for the return type if it is unconstrained.
16311
61e46a7d
NF
163122011-04-14 Nathan Froyd <froydnj@codesourcery.com>
16313
16314 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
16315
81f653d6
NF
163162011-04-12 Nathan Froyd <froydnj@codesourcery.com>
16317
b4867846
EB
16318 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
16319 before calling TREE_CHAIN.
81f653d6
NF
16320 * gcc-interface/misc.c (gnat_init_ts): New function.
16321 (LANG_HOOKS_INIT_TS): Define.
16322
a358e188
MJ
163232011-04-12 Martin Jambor <mjambor@suse.cz>
16324
b4867846
EB
16325 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
16326 instead of cgraph_node.
a358e188 16327
29b1c5a4
EB
163282011-04-08 Eric Botcazou <ebotcazou@adacore.com>
16329
16330 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
16331 alignment on fields of the RETURN type built for the Copy-In Copy-Out
16332 mechanism.
16333
88872b00
EB
163342011-04-08 Eric Botcazou <ebotcazou@adacore.com>
16335
16336 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
16337 of aggregate types that contain a placeholder.
16338
dcf0c47e
NF
163392011-04-08 Nathan Froyd <froydnj@codesourcery.com>
16340
16341 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
b4867846 16342 TYPE_ARG_TYPES.
dcf0c47e
NF
16343 (handle_type_generic_attribute): Likewise.
16344
53e3000c
EB
163452011-04-04 Eric Botcazou <ebotcazou@adacore.com>
16346
16347 PR ada/47163
16348 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
16349
ab380bb4
KT
163502011-04-04 Kai Tietz <ktietz@redhat.com>
16351
16352 PR ada/47163
0bad0e23
EB
16353 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
16354 to flag value.
ab380bb4 16355
8ffac116
EB
163562011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16357
16358 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
16359 type case, do not strip a padding type around the array type.
16360
de9528f0
EB
163612011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16362
16363 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
16364 types.
16365
d9d7a26c
EB
163662011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16367
16368 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
16369 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
de9528f0 16370 code for -feliminate-unused-debug-types.
d9d7a26c
EB
16371 (gnat_post_options): Likewise.
16372
4cb12a90
EB
163732011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16374
16375 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
16376 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
16377 distinct copy.
16378
acccc61c
EB
163792011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16380
16381 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
16382 DECL_ARTIFICIAL flag on enumeration types.
16383
583eb0c9
EB
163842011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16385
16386 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
16387 fat pointer types artificial unconditionally.
16388 <E_Array_Subtype>: Attach the base array type as a parallel type if it
16389 isn't artificial.
16390
e3edbd56
EB
163912011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16392
16393 * gcc-interface/gigi.h (get_dummy_type): Declare.
16394 (build_dummy_unc_pointer_types): Likewise.
16395 (finish_fat_pointer_type): Likewise.
16396 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
16397 fat pointer type has been built, complete it in place.
16398 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
16399 and thin pointers. Remove useless variable.
16400 (finish_fat_pointer_type): Make global and move to...
16401 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
16402 (get_dummy_type): New function.
16403 (build_dummy_unc_pointer_types): Likewise.
16404 (gnat_pushdecl): Propage the name to the anonymous variants only.
16405 (update_pointer_to): Only adjust the pointer types in the unconstrained
16406 array case.
16407
65444786
EB
164082011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16409
16410 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
16411 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
16412 if this is a Taft amendment type and the full declaration is available.
16413 * gcc-interface/trans.c (process_type): Likewise.
16414 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
16415 (process_freeze_entity): Likewise.
16416 * gcc-interface/utils.c (dummy_global): New static variable.
16417 (gnat_write_global_declarations): If there are types declared as used
16418 at the global level, insert them in the global hash table.
16419
1aeb40dd
EB
164202011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16421
16422 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
16423 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
16424 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
16425 copy.
16426 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
16427 flag of the type accordingly.
16428 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
16429
80ec8b4c
EB
164302011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16431
16432 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
16433 finalizing types when updating the pointers to the designated type.
16434 <all>: Finalize the deferred types even if we didn't defer processing
16435 of incomplete types in this invocation.
16436
2a9d769a 164372011-04-01 Olivier Hainque <hainque@adacore.com>
2c7f9cc0
AS
16438 Nicolas Setton <setton@adacore.com>
16439 Eric Botcazou <ebotcazou@adacore.com>
2a9d769a
OH
16440
16441 * gcc-interface/misc.c (gnat_descriptive_type): New function.
16442 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
16443
2438d7a6
KT
164442011-03-28 Kai Tietz <ktietz@redhat.com>
16445
333d8aff 16446 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
80ec8b4c
EB
16447 Windows targets.
16448 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
16449 * system-mingw.ads (System): Change ZCX_By_Default default to True.
333d8aff 16450
80ec8b4c 16451 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
2438d7a6 16452
8ad150f6
TG
164532011-03-28 Tristan Gingold <gingold@adacore.com>
16454
16455 PR ada/44431
80ec8b4c
EB
16456 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
16457 Use ada output of gnatbind.
8ad150f6
TG
16458 (ada/b_gnatb.adb): Ditto.
16459 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
16460 (ada.mostlyclean, ada.stage1)
16461 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
16462 (ada.stagefeedback): Adjust.
80ec8b4c 16463 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
8ad150f6
TG
16464 Use ada output of gnatbind.
16465 (b_gnatm.adb): Ditto.
16466 (b_gnatl.o, b_gnatm.o): New rules.
16467
51c7954d
EB
164682011-03-26 Eric Botcazou <ebotcazou@adacore.com>
16469
16470 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
16471 for the padded type built to support a specified size or alignment.
16472
6ddf9843
EB
164732011-03-26 Eric Botcazou <ebotcazou@adacore.com>
16474
16475 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
16476 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
16477 unconditionally to the end of the unit when the designated type is
16478 limited_with'ed.
16479 <all>: Rename local variable. Attempt to un-defer types only and do it
16480 for limited_with'ed types as well.
16481 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
16482 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
16483 consistently and remove redundant call to finalize_from_with_types.
16484
5daed84a
EB
164852011-03-26 Eric Botcazou <ebotcazou@adacore.com>
16486
16487 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
16488 subprograms without a previous spec declared in the same unit.
16489 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
16490 subprograms at the end of the unit instead of at the beginning.
16491 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
16492 isn't public for the special handling of non-inline functions nested
16493 inside inline external functions.
16494
0edf1bb2
JL
164952011-03-25 Jeff Law <law@redhat.com>
16496
5daed84a 16497 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
0edf1bb2 16498
e3c4580e
EB
164992011-03-24 Eric Botcazou <ebotcazou@adacore.com>
16500
16501 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
16502 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
16503 to compute Set_Size_Depends_On_Discriminant.
16504 (Layout_Type): Call it on array types in back-end layout mode.
16505 * sem_util.adb (Requires_Transient_Scope): Return true for array
16506 types only if the size depends on the value of discriminants.
16507 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
16508 type if the RHS is a call to a function that returns an unconstrained
16509 type with default discriminant.
16510
abbc8c7b
EB
165112011-03-24 Eric Botcazou <ebotcazou@adacore.com>
16512
16513 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
16514 non-conversion to the nominal result type at the end.
16515
ddb5a105
EB
165162011-03-23 Eric Botcazou <ebotcazou@adacore.com>
16517
16518 * gcc-interface/trans.c (create_temporary): New function taken from...
16519 (create_init_temporary): ...here. Call it.
16520 (call_to_gnu): Create the temporary for the return value early, if any.
16521 Create it for a function with copy-in/copy-out parameters if there is
16522 no target; in other cases of copy-in/copy-out, use another temporary.
16523 Push the new binding level lazily. Add and rename local variables.
16524
0d853156
EB
165252011-03-23 Eric Botcazou <ebotcazou@adacore.com>
16526
16527 * gcc-interface/decl.c (validate_size): Improve comments and tweak
16528 error message.
16529 (set_rm_size): Likewise.
16530
4184ef1b
EB
165312011-03-23 Eric Botcazou <ebotcazou@adacore.com>
16532
16533 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
16534 for the padded type built in order to support a specified alignment.
16535 Fix incorrect formatting.
16536
bf7eefab
EB
165372011-03-21 Eric Botcazou <ebotcazou@adacore.com>
16538
16539 PR bootstrap/48216
16540 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
16541
ef0feeb2
EB
165422011-03-21 Eric Botcazou <ebotcazou@adacore.com>
16543
16544 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
16545 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
16546 to the end of the list. Adjust recursive call. Rename local variable.
16547 If REORDER is true, reorder components of the record type.
16548 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
16549 components_to_record and adjust the parameter list.
16550
646f9414
EB
165512011-03-21 Eric Botcazou <ebotcazou@adacore.com>
16552
16553 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
16554 disabled, use the variable for bounds of loop iteration scheme.
16555
62d784f7
KT
165562011-03-21 Kai Tietz <ktietz@redhat.com>
16557
16558 PR target/12171
0bad0e23 16559 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
62d784f7 16560
f230d759
EB
165612011-03-17 Eric Botcazou <ebotcazou@adacore.com>
16562
16563 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
16564 out whether the expression is read-only. Short-circuit placeholder
16565 case and rename a couple of local variables.
16566
bb1f7929
EB
165672011-03-17 Eric Botcazou <ebotcazou@adacore.com>
16568
16569 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
16570 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
16571 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
16572 (convert): Deal with conversions from a smaller form type specially.
16573
400a2d24
EB
165742011-02-14 Eric Botcazou <ebotcazou@adacore.com>
16575
16576 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
16577 its argument, except for the special -I- switch.
16578
c26bc3ad
GP
165792011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
16580
0bad0e23
EB
16581 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
16582 "Ada Issues".
c26bc3ad 16583
07b8e910
EB
165842011-02-08 Eric Botcazou <ebotcazou@adacore.com>
16585
16586 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
16587
31a5a547
EB
165882011-02-03 Eric Botcazou <ebotcazou@adacore.com>
16589
16590 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
16591 GNAT_FORMAL.
16592 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
16593 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
16594 instead of GNAT_FORMAL. Protect the expression against multiple uses.
16595 Do not generate the check directly, instead instantiate the template
16596 check present in the descriptor.
16597 (make_descriptor_field): Move around.
16598 (build_vms_descriptor32): Build a template check in the POINTER field.
16599 (build_vms_descriptor): Remove useless suffixes.
16600 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
16601
dcf25f59
EB
166022011-01-26 Eric Botcazou <ebotcazou@adacore.com>
16603
16604 PR bootstrap/47467
16605 * targext.c: Include target files if IN_RTS is defined.
16606
0418e131
RG
166072011-01-26 Richard Guenther <rguenther@suse.de>
16608
16609 PR bootstrap/47467
16610 * targext.c: Include config.h.
16611 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
16612 dependency.
16613
c6eecbd8 166142011-01-04 Pascal Obry <obry@adacore.com>
2c7f9cc0 16615 Eric Botcazou <ebotcazou@adacore.com>
c6eecbd8
PO
16616
16617 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
16618
2d3c7e4f
EB
166192011-01-04 Eric Botcazou <ebotcazou@adacore.com>
16620
16621 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
16622 end-of-case on the end label and its associated gotos, if any.
16623
0394741f
EB
166242011-01-04 Eric Botcazou <ebotcazou@adacore.com>
16625
16626 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
16627 expressions of the parameter cache within the statement group of
16628 the CICO mechanism.
16629
2a02d090 166302011-01-04 Olivier Hainque <hainque@adacore.com>
2c7f9cc0 16631 Eric Botcazou <ebotcazou@adacore.com>
2a02d090
OH
16632
16633 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
16634 (set_end_locus_from_node): New function.
16635 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
16636 make and the function end_locus.
16637 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
16638 for the elaboration subprogram.
16639 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
16640 set the end_locus of the expression as well.
16641
89f5e978
EB
166422011-01-04 Eric Botcazou <ebotcazou@adacore.com>
16643
16644 PR ada/47131
16645 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
16646 variables that are referenced in exception handlers volatile.
16647
16648
ad41bd84 16649\f
797103eb 16650Copyright (C) 2011 Free Software Foundation, Inc.
ad41bd84
JM
16651
16652Copying and distribution of this file, with or without modification,
16653are permitted in any medium without royalty provided the copyright
16654notice and this notice are preserved.
This page took 2.644237 seconds and 5 git commands to generate.