]> gcc.gnu.org Git - gcc.git/blame - gcc/ada/ChangeLog
utils2.c (gnat_build_constructor): Test the TREE_STATIC flag of elements to compute...
[gcc.git] / gcc / ada / ChangeLog
CommitLineData
cce30ea8
EB
12011-12-11 Eric Botcazou <ebotcazou@adacore.com>
2
3 * gcc-interface/utils2.c (gnat_build_constructor): Test the TREE_STATIC
4 flag of elements to compute that of the constructor.
5
4f96985d
EB
62011-12-11 Eric Botcazou <ebotcazou@adacore.com>
7
8 * gcc-interface/decl.c (gnat_to_gnu_param): Set the restrict qualifier
9 on references built for parameters which aren't specifically by-ref.
10
50751f49
EB
112011-12-11 Eric Botcazou <ebotcazou@adacore.com>
12
13 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: If there is an
14 alignment set on a renaming, assert that the renamed object is aligned
15 enough as to make it possible to honor it.
16
52e04e56
EB
172011-12-11 Eric Botcazou <ebotcazou@adacore.com>
18
19 * gcc-interface/trans.c (gigi): Initialize the linemap earlier.
20
5fa3ea21
DK
212011-12-06 Dave Korn <dave.korn.cygwin@gmail.com>
22
23 * gcc-interface/Makefile.in (LIBGNAT_TARGET_PAIRS [windows targets]):
24 Correctly detect cygwin, which no longer has the '32' suffix, and use
25 appropriate implementations of the sockets and memory packages.
26 * sysdep.c (WIN_SETMODE): New define to choose the correct spelling of
27 setmode/_setmode for MinGW and Cygwin, respectively.
28 (__gnat_set_binary_mode [windows targets]): Use the above, and enable
29 the windows version for Cygwin as well as MinGW.
30 (__gnat_set_text_mode [windows targets]): Likewise.
31 (__gnat_ttyname [windows targets]): Provide a Cygwin implementation
32 in addition to the MinGW version.
33 (__gnat_is_windows_xp): Make available to Cygwin as well as MinGW.
34 (__gnat_get_stack_bounds): Likewise.
35
76264f60
AC
362011-12-05 Bob Duff <duff@adacore.com>
37
38 * sem_ch4.adb: Minor comment fix.
39
402011-12-05 Robert Dewar <dewar@adacore.com>
41
42 * gnat_ugn.texi: Add documentation for -gnatw.e.
43
442011-12-05 Bob Duff <duff@adacore.com>
45
46 * treepr.adb (pn): Print something useful for
47 Elmt_Ids. Add Write_Eol to 'when others' case, so the output
48 will be seen immediately in gdb.
49
502011-12-05 Ed Schonberg <schonberg@adacore.com>
51
52 * lib-writ.adb (Output_Main_Program_Line): A generic subprogram
53 is never a main program.
54
552011-12-05 Thomas Quinot <quinot@adacore.com>
56
57 * par_sco.adb: Various minor adjustments to dominance markers
58 generation.
59
602011-12-05 Ed Schonberg <schonberg@adacore.com>
61
62 * sem_ch6.adb (Analyze_Expression_Function): If the function is
63 a completion, generate a body reference for its defining entity,
64 before rewriting the node as a body.
65 * sem_util.adb (Defining_Entity): Add entry for expression
66 function.
67
3128f955
AC
682011-12-05 Bob Duff <duff@adacore.com>
69
70 * sem_ch3.adb (Derive_Progenitor_Subprograms): Add Ultimate_Alias
71 to the Comes_From_Source check, to deal properly with the case
72 of indirect inheritance of "=".
73
742011-12-05 Thomas Quinot <quinot@adacore.com>
75
76 PR ada/51307
77 * s-oscons-tmplt.c: On HP-UX, CLOCK_REALTIME is an enum literal,
78 not a macro.
79
802011-12-05 Thomas Quinot <quinot@adacore.com>
81
82 * par_sco.adb, scos.ads, put_scos.adb, get_scos.adb: Generate dominance
83 information in SCOs.
84
ce8d58a2
EB
852011-12-02 Eric Botcazou <ebotcazou@adacore.com>
86 Thomas Quinot <quinot@adacore.com>
87
88 * gcc-interface/Makefile.in (INCLUDES): Remove $(srcdir)/config.
89 (INCLUDES_FOR_SUBDIR): Add $(fsrcdir) except for VxWorks.
90 Add thread.c to LIBGNAT_SRCS so that a symlink is created in ada/rts,
91 which allows the file to be installed in adainclude.
92 * gcc-interface/Make-lang.in: Update dependencies.
93
a46cde68
AC
942011-12-02 Javier Miranda <miranda@adacore.com>
95
96 * sem_ch3.adb (Constrain_Access): Undo previous
97 patch for this routine. Required since the RM rule 3.7.1(7/3)
98 applies to all access types.
99
1002011-12-02 Bob Duff <duff@adacore.com>
101
102 * sem_ch6.adb: Minor comment fix.
103
d0234c7e
JS
1042011-12-02 Joel Sherrill <joel.sherrill@oarcorp.com>
105
106 * s-tpopsp-rtems.adb: Use ATCB_Key rather than RTEMS_Ada_Self variable
107 for consistency with other ports.
108 * s-osinte-rtems.adb: Add body for dummy implementation of
109 pthread_rwlockattr_setkind_np().
110 * s-osinte-rtems.ads: Add missing clock and rwlock bindings.
111 * terminals.c: Add __rtems__ conditionals to account for differences
112 in termios implementation.
113
d600ef16
RD
1142011-12-02 Robert Dewar <dewar@adacore.com>
115
116 * sem_ch3.adb, sem_attr.adb, a-comutr.adb, a-cbmutr.adb,
117 a-cbmutr.ads: Minor reformatting.
118
0add5a95
AC
1192011-12-02 Hristian Kirtchev <kirtchev@adacore.com>
120
121 * exp_dbug.adb: Comment reformatting.
122 (Get_External_Name): Use Reset_Buffers to reset the contents of
123 Name_Buffer and Homonym_Numbers.
124 (Qualify_All_Entity_Names): Reset the contents of Name_Buffer and
125 Homonym_Numbers before creating a new qualified name for a particular
126 entity.
127 (Reset_Buffers): New routine.
128
1292011-12-02 Matthew Heaney <heaney@adacore.com>
130
131 * a-cbmutr.ads (No_Node): Moved declaration from body to spec
132 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Iterator): Derives
133 from Root_Iterator.
134 (Child_Iterator): Derives from Root_Iterator.
135 (Finalize): Implemented as an override operation for Root_Iterator.
136 (First): Return value depends on Subtree component.
137 (Last): Component was renamed from Parent to Subtree.
138 (Next): Checks parameter value, and uses simplified loop.
139 (Iterate): Forwards to Iterate_Subtree.
140 (Iterate_Children): Component was renamed from Parent to Subtree.
141 (Iterate_Subtree): Checks parameter value
142
1432011-12-02 Robert Dewar <dewar@adacore.com>
144
145 * usage.adb: Add lines for -gnatw.n and -gnatw.N
146 (atomic sync info msgs).
147
1482011-12-02 Steve Baird <baird@adacore.com>
149
150 * sem_ch3.adb (Check_Completion): An Ada 2012
151 generic formal type doesn't require a completion.
152
1532011-12-02 Eric Botcazou <ebotcazou@adacore.com>
154
155 * sem_util.adb (Set_Debug_Info_Needed): Also set the flag on the
156 packed array type if it is to be set on the array type used to
157 represent it.
158
1592011-12-02 Robert Dewar <dewar@adacore.com>
160
161 * gnat_rm.texi: Eliminate confusing use of type name.
162
81435e80
TQ
1632011-12-02 Thomas Quinot <quinot@adacore.com>
164
165 * sem_ch10.adb (Analyze_Compilation_Unit): For a library subprogram
166 body that acts as spec, do not create a shallow copy of the context
167 clause for the synthetized spec (instead, use the same list as
168 in the body).
169
414b312e
AC
1702011-12-02 Bob Duff <duff@adacore.com>
171
172 * gnat_ugn.texi: Clarify usage of -p binder switch.
173
1742011-12-02 Javier Miranda <miranda@adacore.com>
175
176 * sem_util.ads, sem_util.adb, sem_aux.ads, sem_aux.adb
177 (Effectively_Has_Constrained_Partial_View): Moved to sem_aux
178 (In_Generic_Body): Moved to sem_aux.
179 (Unit_Declaration_Node): Moved to sem_aux.
180 * einfo.ads (Effectively_Has_Constrained_Partial_View): Complete
181 documentation.
182 * exp_attr.adb, live.adb, sem_ch10.adb, checks.adb, sem.adb,
183 rtsfind.adb, sem_attr.adb, sem_elab.adb, exp_ch4.adb, sem_ch4.adb,
184 exp_ch13.adb: Add with-clause on Sem_Aux.
185
151c42b0
YM
1862011-12-02 Yannick Moy <moy@adacore.com>
187
188 * sem_util.adb (Unique_Name): Reach through Unique_Entity to
189 get the name of the entity.
190 (Unique_Entity): Correct case for subprogram stubs.
191
1922011-12-02 Yannick Moy <moy@adacore.com>
193
194 * sem_ch3.adb (Check_Initialization): Do not emit warning on
195 initialization of limited type object in Alfa mode.
196
7a6c40a6
RD
1972011-12-02 Robert Dewar <dewar@adacore.com>
198
199 * sinfo.ads: Minor reformatting.
200 * gnat_ugn.texi: Fix confusion in use of term "type name".
201
cc96a1b8
AC
2022011-12-02 Robert Dewar <dewar@adacore.com>
203
204 * sem_ch6.adb: Minor change in error message.
205
2062011-12-02 Robert Dewar <dewar@adacore.com>
207
208 * sem_ch9.adb, prj-part.adb, vms_data.ads, sem_ch8.adb: Minor
209 reformatting.
210
2112011-12-02 Javier Miranda <miranda@adacore.com>
212
213 * sem_ch3.adb (Constrain_Access): Enable on Ada 2005 mode the
214 static check of the rule of general access types whose designated
215 type has discriminants.
216 * sem_util.ads, sem_util.adb
217 (Effectively_Has_Constrained_Partial_View): New subprogram.
218 (In_Generic_Body): New subprogram.
219 * einfo.ads (Has_Constrained_Partial_View): Adding documentation.
220 * sem_prag.adb (Inside_Generic_Body): Removed. Replaced by new
221 subprogram In_Generic_Body.
222 * exp_attr.adb, checks.adb, sem_attr.adb, exp_ch4.adb,
223 sem_ch4.adb: In addition, this patch replaces the occurrences of
224 Has_Constrained_Partial_View by
225 Effectively_Has_Constrained_Partial_View.
226
2272011-12-02 Matthew Heaney <heaney@adacore.com>
228
229 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Iterator): Rename
230 Position component.
231 (Finalize): Remove unnecessary access check.
232 (First): Forward to First_Child.
233 (Last): Forward to Last_Child.
234 (Iterate): Check preconditions for parent node parameter.
235 (Next): Forward to Next_Sibling.
236 (Previous): Forward to Previous_Sibling.
237
35fae080
RD
2382011-12-02 Robert Dewar <dewar@adacore.com>
239
240 * a-coinve.adb, a-coorma.adb, freeze.adb, a-coorse.adb, a-comutr.adb,
241 a-coormu.adb, a-convec.adb: Minor reformatting.
242
e47e21c1
AC
2432011-12-02 Matthew Heaney <heaney@adacore.com>
244
245 * a-coormu.ads, a-ciormu.ads: Declare iterator factory function.
246 * a-ciormu.adb, a-ciormu.adb (Iterator): Declare concrete
247 Iterator type.
248 (Finalize): Decrement busy counter.
249 (First, Last): Cursor return value depends on iterator node value.
250 (Iterate): Use start position as iterator node value.
251 (Next, Previous): Forward to corresponding cursor-based operation.
252
2532011-12-02 Robert Dewar <dewar@adacore.com>
254
255 * a-cborma.adb, a-cbhama.adb, a-cbdlli.adb, a-cbmutr.adb,
256 a-cbhase.adb, a-cdlili.adb, a-cihama.adb, a-ciorse.adb, a-cidlli.adb,
257 a-cimutr.adb, a-cihase.adb, a-cohama.adb, a-cborse.adb,
258 a-ciorma.adb, a-cobove.adb: Minor reformatting.
259
c136d696
JJ
2602011-12-01 Jakub Jelinek <jakub@redhat.com>
261
262 PR bootstrap/51201
263 * gcc-interface/Make-lang.in: Initialize RTS_DIR with = instead of :=.
264
bf75cdbe
RO
2652011-11-24 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
266
267 * s-taprop-tru64.adb (Create_Task): Use Unrestricted_Access.
268
d0dcb2b1
AC
2692011-11-23 Thomas Quinot <quinot@adacore.com>
270
271 * thread.c, s-oscons-tmplt.c: Generate __gnat_pthread_condattr_setup
272 only on platforms where this is required, as determined by
273 s-oscons.h.
274
2752011-11-23 Ed Schonberg <schonberg@adacore.com>
276
277 * sem_ch9.adb: No check on entry index if error on index.
278
2792011-11-23 Gary Dismukes <dismukes@adacore.com>
280
281 * sem_ch6.adb (Analyze_Return_Statement): Improve error messages for
282 return statements nested inside an extended_return_statement.
283 * gcc-interface/Make-lang.in: Update dependencies.
284 * gcc-interface/Makefile.in (MISCLIB): Add -lutil for BSD targets.
285
ef992452
AC
2862011-11-23 Ed Schonberg <schonberg@adacore.com>
287
288 * freeze.adb (Freeze_All_Ent): An incomplete type is not
289 frozen by a subprogram body that does not come from source.
290
2912011-11-23 Pascal Obry <obry@adacore.com>
292
293 * s-oscons-tmplt.c: Add PTY_Library constant. It contains
294 the library for pseudo terminal support.
295 * g-exptty.ads: Add pseudo-terminal library into a Linker_Options
296 pragma.
297
2982011-11-23 Ed Schonberg <schonberg@adacore.com>
299
300 * sem_ch9.adb: No check on entry family index if generic.
301
3022011-11-23 Thomas Quinot <quinot@adacore.com>
303
304 * sem_ch9.adb, s-taprop.ads, s-taprop-hpux-dce.adb, s-taprop-irix.adb,
305 s-taprop-posix.adb, s-taprop-rtx.adb, s-taprop-solaris.adb,
306 s-taprop-tru64.adb, s-taprop-vxworks.adb: Move dependency on
307 System.OS_Constants from shared spec of
308 System.Tasking.Primitive_Operations to the specific body variants
309 that really require this dependency.
310
3112011-11-23 Ed Schonberg <schonberg@adacore.com>
312
313 * sem_ch8.adb (Analyze_Subprogram_Renaming_Declaration):
314 If the declaration has aspects, analyze them so they can be
315 properly rejected.
316
3172011-11-23 Hristian Kirtchev <kirtchev@adacore.com>
318
319 * a-comutr.adb, a-coorma.adb, a-coorse.adb, a-convec.adb, a-cihase.adb,
320 a-cimutr.adb, a-coinve.adb, a-ciorma.adb, a-ciorse.adb, a-cobove.adb,
321 a-cohama.adb, a-cihama.adb, a-cidlli.adb, a-cdlili.adb, a-cbhama.adb,
322 a-cbhase.adb, a-cbmutr.adb, a-cborma.adb, a-cborse.adb, a-cbdlli.adb:
323 Add with and use clause for Ada.Finalization. Type
324 Iterator and Child_Iterator are now derived from Limited_Controlled.
325 (Finalize): New routine.
326 (Iterate): Add a renaming of counter Busy and
327 increment it. Update the return aggregate.
328 (Iterate_Children): Add a renaming of
329 counter Busy and increment it. Update the return aggregate.
330 (Iterate_Subtree): Add a renaming of counter Busy and increment
331 it. Update the return aggregate.
332 * a-cdlili.ads, a-cidlli.ads: Type List_Access is now a general access
333 type.
334 * a-cihama.ads: Type Map_Access is now a general access type.
335 * a-comutr.ads, a-cimutr.ads: Use type Natural for the two locks
336 associated with the tree.
337 * a-cohama.ads: Type Map_Access is now a general access type.
338 * a-coinve.ads, a-convec.ads: Type Vector_Access is now a general
339 access type.
340 * exp_ch5.adb (Expand_Iterator_Loop): Do not create a block
341 to wrap the loop as this is done at an earlier step, during
342 analysis. The declarations of the iterator and the cursor use
343 the usual Insert_Action mechanism when added into the tree.
344 * sem_ch5.adb (Analyze_Loop_Statement): Remove local constant
345 Loop_Statement and replace all respective uses by N. Add local
346 constant Loc. Preanalyze the loop iterator to discover whether
347 it is a container iterator and if it is, wrap the loop in a
348 block. This ensures that any controlled temporaries produced
349 by the iteration scheme share the same lifetime of the loop.
350 (Is_Container_Iterator): New routine.
351 (Is_Wrapped_In_Block): New routine.
352 (Pre_Analyze_Range): Move spec and body to the library level.
353
3542011-11-23 Sergey Rybin <rybin@adacore.com frybin>
355
356 * gnat_ugn.texi, vms_data.ads: Add documentation for new gnatpp option
357 that controls casing of type and subtype names.
358
3592011-11-23 Yannick Moy <moy@adacore.com>
360
361 * sem_ch3.adb: Minor addition of comments.
362
3632011-11-23 Thomas Quinot <quinot@adacore.com>
364
365 * prj-part.adb (Extension_Withs): New global variable,
366 contains the head of the list of WITH clauses from the EXTENDS
367 ALL projects for which virtual packages are being created.
368 (Look_For_Virtual_Projects_For): When recursing through
369 an EXTENDS ALL, add the WITH clauses of the extending
370 project to Extension_Withs. When adding a project to the
371 Virtual_Hash, record the associated Extension_Withs list.
372 (Create_Virtual_Extending_Project): Add a copy of the appropriate
373 Extension_Withs to the virtual project.
374
3752011-11-23 Thomas Quinot <quinot@adacore.com>
376
377 * mlib-tgt-specific-vxworks.adb: Minor reformatting.
378
3792011-11-23 Thomas Quinot <quinot@adacore.com>
380
381 * Make-generated.in (Sdefault.Target_Name): Set to
382 $(target_noncanonical) instead of $(target) for consistency.
383
595a055f
MH
3842011-11-23 Matthew Heaney <heaney@adacore.com>
385
386 * a-cdlili.adb, a-cidlli.adb, a-cbdlli.adb (Iterator): Declared
387 Iterator type as limited (First, Last): Cursor return value
388 depends on iterator node value (Iterate): Use start position as
389 iterator node value (Next, Previous): Forward to corresponding
390 cursor-based operation.
391
b38c20a6
AC
3922011-11-23 Matthew Heaney <heaney@adacore.com>
393
394 * a-coorse.ads, a-ciorse.ads, a-cborse.ads (Set_Iterator_Interfaces):
395 Renamed from Ordered_Set_Iterator_Interfaces.
396 * a-coorse.adb, a-ciorse.adb, a-cborse.adb (Iterator): Declared
397 Iterator type as limited (First, Last): Cursor return value
398 depends on iterator node value (Iterate): Use start position as
399 iterator node value (Next, Previous): Forward to corresponding
400 cursor-based operation.
401 * a-cohase.ads, a-cohase.adb: Implemented forward iterator.
402 * a-cihase.adb, a-cbhase.adb (Iterator): Removed unnecessary
403 node component (First, Next): Forward call to corresponding
404 cursor-based operation (Iterate): Representation of iterator no
405 longer has node component
406
4072011-11-23 Hristian Kirtchev <kirtchev@adacore.com>
408
409 * exp_intr.adb (Expand_Unc_Deallocation): Ensure that the
410 dereference has a proper type before the side effect removal
411 mechanism kicks in.
412 * sem_ch3.adb (Analyze_Subtype_Declaration): Handle a rare case
413 where the base type of the subtype is a private itype created
414 to act as the partial view of a constrained record type. This
415 scenario manifests with equivalent class-wide types for records
416 with unknown discriminants.
417
4182011-11-23 Jerome Guitton <guitton@adacore.com>
419
420 * s-osprim-vxworks.adb (Clock): Use Clock_RT_Ada.
421
4222011-11-23 Thomas Quinot <quinot@adacore.com>
423
424 * s-oscons-tmplt.c: Fix unbalanced preprocessor directives Minor
425 reformatting/reorganization.
426
24fee494
TQ
4272011-11-23 Thomas Quinot <quinot@adacore.com>
428
429 * g-htable.ads: Remove old comments.
430
bc6e33a3
TQ
4312011-11-23 Thomas Quinot <quinot@adacore.com>
432
433 * exp_imgv.adb: Minor reformatting.
434
c269a1f5
AC
4352011-11-23 Robert Dewar <dewar@adacore.com>
436
437 * sem_ch9.adb (Analyze_Entry_Declaration): Check for entry
438 family bounds out of range.
439
4402011-11-23 Matthew Heaney <heaney@adacore.com>
441
442 * a-cohama.adb, a-cihama.adb, a-cbhama.adb (Iterator): Declare
443 type as limited, and remove node component.
444 (First, Next): Forward call to corresponding cursor-based operation.
445 (Iterate): Representation of iterator no longer has node component.
446
4472011-11-23 Yannick Moy <moy@adacore.com>
448
449 * exp_util.adb: Revert previous change to remove side-effects in Alfa
450 mode, which is not the correct thing to do for renamings.
451
4522011-11-23 Thomas Quinot <quinot@adacore.com>
453
454 * s-osinte-hpux.ads, s-taprop-vxworks.adb, s-taprop-tru64.adb,
455 s-osinte-vxworks.ads, s-osinte-aix.ads, s-osinte-lynxos.ads,
456 s-osinte-solaris-posix.ads, s-taprop-solaris.adb, a-exetim-posix.adb,
457 s-osinte-irix.ads, s-osinte-solaris.ads, s-oscons-tmplt.c,
458 s-taprop-irix.adb, s-osinte-hpux-dce.ads, Makefile.rtl,
459 s-osinte-tru64.ads, s-osinte-darwin.ads, s-taprop.ads,
460 s-osinte-freebsd.ads, s-osinte-lynxos-3.ads, s-taprop-hpux-dce.adb,
461 s-taprop-posix.adb: Remove hard-coded clock ids;
462 instead, generate them in System.OS_Constants.
463 (System.OS_Constants.CLOCK_RT_Ada): New constant denoting the
464 id of the clock providing Ada.Real_Time.Monotonic_Clock.
465 * thread.c: New file.
466 (__gnat_pthread_condattr_setup): New function. For platforms where
467 CLOCK_RT_Ada is not CLOCK_REALTIME, set appropriate condition
468 variable attribute.
469
4702011-11-23 Yannick Moy <moy@adacore.com>
471
472 * sem_ch3.adb: Restore the use of Expander_Active instead of
473 Full_Expander_Active, so that the evaluation is forced in Alfa
474 mode too. Otherwise, we end up with an unexpected insertion in a
475 place where it is not supposed to happen, on default parameters
476 of a call.
477
4782011-11-23 Thomas Quinot <quinot@adacore.com>
479
480 * prj-pp.adb, prj-pp.ads: Minor new addition: wrapper procedure "wpr"
481 for Pretty_Print, for use from within gdb.
482
f947ee34
AC
4832011-11-23 Ed Schonberg <schonberg@adacore.com>
484
485 * exp_ch5.adb (Expand_Iterator_Loop): Wrap the expanded loop
486 and the cursor declarations in a block, so that the loop variable
487 is local to the construct.
488
4892011-11-23 Matthew Heaney <heaney@adacore.com>
490
491 * a-coorma.ads, a-ciorma.ads, a-cborma.ads (Iterate): Returns
492 type Reversible_Iterator'Class.
493 * a-coorma.adb, a-ciorma.adb, a-cborma.adb (Iterator):
494 Declare type as limited.
495 (First, Last): Return value depends on iterator's start node value.
496 (Next, Previous): Call corresponding Cursor-based operation.
497 (Iterate): Indicate whether complete or partial iteration
498
fb2bd3a7
RD
4992011-11-23 Robert Dewar <dewar@adacore.com>
500
501 * errout.adb: Minor reformattin (Finalize): Take templates into
502 account for warning suppression.
503 * errout.ads (Set_Specific_Warning_Off): Add Used parameter.
504 * erroutc.adb: Minor reformatting (Finalize): Take generic
505 templates into account for warning suppress.
506 * erroutc.ads (Set_Specific_Warning_Off): Add Used parameter.
507 * sem_prag.adb: Minor reformatting (Analyze_Pragma,
508 case Warnings): Provide Used parameter in call to
509 Set_Specific_Warnings_Off (to deal with generic template case).
510
a1092b48
AC
5112011-11-23 Pascal Obry <obry@adacore.com>
512
513 * sem_prag.adb (Process_Convention): Better error message for
514 stdcall convention on dispatching calls.
515
5162011-11-23 Gary Dismukes <dismukes@adacore.com>
517
518 * sem_ch4.adb, sem_ch13.adb: Minor reformatting.
519
5202011-11-23 Javier Miranda <miranda@adacore.com>
521
522 * exp_ch6.adb (Expand_Simple_Function_Return): Add missing
523 implicit type conversion when the returned object is allocated
524 in the secondary stack and the type of the returned object is
525 an interface. Done to force generation of displacement of the
526 "this" pointer.
527
3d0c15cf
AC
5282011-11-23 Pascal Obry <obry@adacore.com>
529
530 * impunit.adb: Add g-exptty and g-tty units.
531
5322011-11-23 Robert Dewar <dewar@adacore.com>
533
534 * exp_imgv.adb: Minor code reorganization (use Make_Temporary).
535
95160516
AC
5362011-11-23 Robert Dewar <dewar@adacore.com>
537
538 * exp_util.adb, par-ch6.adb, sem_res.adb, par-util.adb: Minor
539 reformatting.
540
5412011-11-23 Yannick Moy <moy@adacore.com>
542
543 * sem_ch13.adb (Analyze_Aspect_Specifications): Place error on
544 line of precondition/ postcondition/invariant.
3d0c15cf 545
95160516
AC
5462011-11-23 Pascal Obry <obry@adacore.com>
547
548 * g-exptty.ads, g-exptty.adb, g-tty.ads, g-tty.adb,
549 terminals.c: New files.
550 Makefile.rtl: Add these new files.
551 * gnat_rm.texi: Add documentation for GNAT.Expect.TTY.
552 * gcc-interface/Makefile.in: Add g-exptty, g-tty, terminals.o
553 * gcc-interface/Make-lang.in: Update dependencies.
554
5328a91d
AC
5552011-11-21 Robert Dewar <dewar@adacore.com>
556
95160516 557 * exp_imgv.adb (Expand_Width_Attribute): Handle case of Discard_Names.
5328a91d
AC
558 * sem_attr.adb (Eval_Attribute, case Width): Ditto.
559
5602011-11-21 Thomas Quinot <quinot@adacore.com>
561
562 * sinfo.ads: Minor reformatting.
563
5642011-11-21 Yannick Moy <moy@adacore.com>
565
566 * exp_util.adb: Minor reformatting. Update comments.
567
8a06151a
RD
5682011-11-21 Robert Dewar <dewar@adacore.com>
569
570 * exp_prag.adb, exp_util.adb, sinfo.ads, sem_res.adb, s-stposu.adb,
571 sem_attr.adb, s-stposu.ads, s-taprop-solaris.adb, s-taprop-irix.adb,
572 sem_ch6.adb: Minor reformatting.
573
ca20a08e
AC
5742011-11-21 Arnaud Charlet <charlet@adacore.com>
575
576 * s-taprop-irix.adb, s-taprop-solaris.adb (Create_Task): Use
577 Unrestricted_Access to deal with fact that we properly detect the
578 error if Access is used.
579 * gcc-interface/Make-lang.in: Update dependencies.
580
5812011-11-21 Yannick Moy <moy@adacore.com>
582
583 * exp_prag.adb (Expand_Pragma_Check): Place error on first character
584 of expression.
585 * sem_res.adb (Resolve_Short_Circuit): Place error on first
586 character of expression.
587
5882011-11-21 Yannick Moy <moy@adacore.com>
589
590 * exp_util.adb (Remove_Side_Effects): Do nothing in Alfa mode.
591
5922011-11-21 Hristian Kirtchev <kirtchev@adacore.com>
593
594 * exp_attr.adb (Expand_N_Attribute_Reference, case
595 Max_Size_In_Storage_Elements): Account for the size of the
596 hidden list header which precedes controlled objects allocated
597 on the heap.
598 * rtsfind.ads: Add RE_Header_Size_With_Padding to the runtime
599 tables.
600 * sinfo.adb (Header_Size_Added): New routine.
601 (Set_Header_Size_Added): New routine.
602 * sinfo.ads: Add flag Controlled_Header_Added along with
603 associated comment.
604 (Header_Size_Added): New inlined routine.
605 (Set_Header_Size_Added): New inlined routine.
606 * s-stposu.adb (Allocate_Any_Controlled): Use
607 Header_Size_With_Padding to calculate the proper
608 size of the header.
609 (Deallocate_Any_Controlled): Use
610 Header_Size_With_Padding to calculate the proper size
611 of the header. (Header_Size_With_Padding): New routine.
612 (Nearest_Multiple_Rounded_Up): Removed along with its uses.
613 * s-stposu.ads (Header_Size_With_Padding): New routine.
614
6152011-11-21 Ed Schonberg <schonberg@adacore.com>
616
617 * aspects.adb: Aspect specifications are allowed on renaming
618 declarations
619 * par-ch6.adb (P_Subprogram): Parse aspect specifications in a
620 subprogram renaming declaration
621
d2d4b355
AC
6222011-11-21 Tristan Gingold <gingold@adacore.com>
623
624 * env.c: Remove unused declaration.
625
6262011-11-21 Pascal Obry <obry@adacore.com>
627
628 * s-os_lib.ads: Minor style fix.
629
6302011-11-21 Pascal Obry <obry@adacore.com>
631
632 * adaint.c (__gnat_dup2): When fd are stdout, stdin or stderr and
633 identical, do nothing on Windows XP.
634
6352011-11-21 Yannick Moy <moy@adacore.com>
636
637 * sem_ch3.adb (Constrain_Index, Process_Range_Expr_In_Decl):
638 Use Full_Expander_Active instead of Expander_Active to control
639 the forced evaluation of expressions for the sake of generating
640 checks.
641
6422011-11-21 Thomas Quinot <quinot@adacore.com>
643
644 * init.c: On FreeBSD, stack checking failures may raise SIGBUS.
645
6462011-11-21 Tristan Gingold <gingold@adacore.com>
647
648 * sysdep.c (mode_read_text, mode_write_text, mode_append_text,
649 mode_read_binary, mode_write_binary, mode_append_binary,
650 mode_read_text_plus, mode_write_text_plus, mode_append_text_plus,
651 mode_read_binary_plus, mode_write_binary_plus,
652 mode_append_binary_plus): Remove unused declarations.
653
6542011-11-21 Yannick Moy <moy@adacore.com>
655
656 * gnat_rm.texi: Minor rewording.
657
6582011-11-21 Hristian Kirtchev <kirtchev@adacore.com>
659
660 * exp_imgv.adb (Expand_Width_Attribute): Emit
661 an error message rather than a warning when pragma Discard_Names
662 prevents the computation of 'Width. Do not emit an error through
663 the use of RE_Null.
664
6652011-11-21 Javier Miranda <miranda@adacore.com>
666
667 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Add
668 implicit type conversion when the type of the allocator is an
669 interface. Done to force generation of displacement of the "this"
670 pointer when required.
671
6722011-11-21 Ed Schonberg <schonberg@adacore.com>
673
674 * sinfo.ads, sinfo.adb: Corresponding_Spec applies to expression
675 functions, and is set when the expression is a completion of a
676 previous declaration.
677 * sem_ch6.adb (Analyze_Expression_Function): To determine properly
678 whether an expression function completes a previous declaration,
679 use Find_Corresponding_Spec, as when analyzing a subprogram body.
680
6812011-11-21 Steve Baird <baird@adacore.com>
682
683 * sem_util.adb (Deepest_Type_Access_Level): Improve comment.
684 (Type_Access_Level): Improve comment.
685
08ef33f5
EB
6862011-11-21 Eric Botcazou <ebotcazou@adacore.com>
687
688 * gcc-interface/Makefile.in (INCLUDES_FOR_SUBDIR): Add $(fsrcdir) by
689 means of -iquote unconditionally.
690
83e5da69
AC
6912011-11-21 Robert Dewar <dewar@adacore.com>
692
693 * sem_ch3.adb, sem_util.adb, sem_res.adb, sem_attr.adb: Minor
694 reformatting.
695
6962011-11-21 Arnaud Charlet <charlet@adacore.com>
697
698 * s-taprop-posix.adb (Create_Task): Use Unrestricted_Access
699 to deal with fact that we properly detect the error if Access
700 is used.
701
f460d8f3
SB
7022011-11-21 Steve Baird <baird@adacore.com>
703
704 * sem_util.ads: Update comment describing function
705 Deepest_Access_Level.
706 * sem_util.adb (Deepest_Type_Access_Level): Return Int'Last for a
707 generic formal type.
708 (Type_Access_Level): Return library level
709 for a generic formal type.
710 * sem_attr.adb (Resolve_Attribute): Replace two Type_Access_Level
711 calls with calls to Deepest_Type_Access_Level.
712 * sem_ch3.adb (Analyze_Component_Declaration): replace a
713 Type_Access_Level call with a call to Deepest_Type_Access_Level.
714 * sem_res.adb (Resolve_Allocator.Check_Allocator_Discrim_Accessibility):
715 Replace three Type_Access_Level calls with calls to
716 Deepest_Type_Access_Level.
717 (Resolve_Allocator): Replace a Type_Access_Level call with a call to
718 Deepest_Type_Access_Level.
719 (Valid_Conversion.Valid_Array_Conversion): Replace a
720 Type_Access_Level call with a call to Deepest_Type_Access_Level.
721
d673c5c5
RD
7222011-11-21 Robert Dewar <dewar@adacore.com>
723
724 * sem_ch3.adb, s-taprop-vms.adb, opt.ads: Minor reformatting.
725
be482a8c
AC
7262011-11-21 Robert Dewar <dewar@adacore.com>
727
728 * sinput.ads: Minor comment fix.
729
7302011-11-21 Robert Dewar <dewar@adacore.com>
731
732 * exp_attr.adb (Expand_N_Attribute_Reference, case First_Bit,
733 Last_Bit, Position): Handle 2005 case.
734
7352011-11-21 Robert Dewar <dewar@adacore.com>
736
737 * s-atocou-builtin.adb (Decrement): Use Unrestricted_Access
738 to deal with fact that we properly detect the error if Access
739 is used.
740 (Increment): Same fix.
741 * s-taprop-linux.adb (Create_Task): Use Unrestricted_Access
742 to deal with fact that we properly detect the error if Access
743 is used.
744 * sem_util.adb (Is_Volatile_Object): Properly record that A.B is
745 volatile if the B component is volatile. This affects the check
746 for passing such a by reference volatile actual to a non-volatile
747 formal (which should be illegal)
748
7492011-11-21 Robert Dewar <dewar@adacore.com>
750
751 * freeze.adb (Freeze_Enumeration_Type): Make sure to set both
752 size and alignment for foreign convention enumeration types.
753 * layout.adb (Set_Elem_Alignment): Redo setting of alignment
754 when size is set.
755
7562011-11-21 Yannick Moy <moy@adacore.com>
757
758 * checks.adb (Apply_Access_Check, Apply_Arithmetic_Overflow_Check,
759 Apply_Discriminant_Check, Apply_Divide_Check,
760 Apply_Selected_Length_Checks, Apply_Selected_Range_Checks,
761 Build_Discriminant_Checks, Insert_Range_Checks, Selected_Length_Checks,
762 Selected_Range_Checks): Replace reference to Expander_Active
763 with reference to Full_Expander_Active, so that expansion of
764 checks is not performed in Alfa mode
765
7662011-11-21 Tristan Gingold <gingold@adacore.com>
767
768 * s-taprop-vms.adb (Create_Task): Use Unrestricted_Access to deal with
769 fact that we properly detect the error if Access is used.
770
7712011-11-21 Hristian Kirtchev <kirtchev@adacore.com>
772
773 * par-ch4.adb (P_Quantified_Expression): Add an Ada 2012 check.
774
7752011-11-21 Hristian Kirtchev <kirtchev@adacore.com>
776
777 * exp_imgv.adb: Add with and use clause for Errout.
778 (Expand_Width_Attribute): Emit a warning when in
779 configurable run-time mode to provide a better diagnostic message.
780
7812011-11-21 Hristian Kirtchev <kirtchev@adacore.com>
782
783 * s-finmas.adb (Finalize): Add comment concerning double finalization.
784
7852011-11-21 Ed Schonberg <schonberg@adacore.com>
786
787 * sem_ch3.adb (Access_Definition): If the access definition
788 is itself the return type of an access to function definition
789 which is ultimately the return type of an access to subprogram
790 declaration, its scope is the enclosing scope of the ultimate
791 access to subprogram.
792
7932011-11-21 Steve Baird <baird@adacore.com>
794
795 * sem_res.adb (Valid_Conversion): If a conversion was legal
796 in the body of a generic, then the corresponding conversion is
797 legal in the expanded body of an instance of the generic.
798
8e0aa19b
RD
7992011-11-21 Robert Dewar <dewar@adacore.com>
800
801 * sem_ch3.adb: Minor reformatting.
802
8032011-11-21 Robert Dewar <dewar@adacore.com>
804
805 * s-utf_32.adb (Is_UTF_32_Line_Terminator): Recognize NEL as
806 line terminator.
807 * sinput.ads: Add section on Handling of Source Line Terminators.
808 * types.ads (Line_Terminator): Adjust comments.
809
51fb9b73
RD
8102011-11-21 Robert Dewar <dewar@adacore.com>
811
812 * frontend.adb (Frontend): Capture restrictions from config files
813 * lib-load.adb (Load_Unit): Save/set/restore restriction pragma
814 information
815 * lib-xref.adb (Generate_Reference): Fix handling of obsolescent
816 references. This was noticed during debugging, but it is not
817 known if it causes real bugs.
818 * restrict.ads, restrict.adb: New routines to save/set/restore
819 non-partition-wide restrictions.
820 * s-rident.ads: Comment changes for new handling of
821 No_Elaboration_Code
822 * sem.adb (Sem): Save/Set/Restore non-partition-wide restrictions
823 * sem_ch10.adb (Analyze_Compilation_Unit): Remove incomplete
824 attempt to save/restore non-partition-wide restrictions (now
825 this work is all done in Sem).
826 * sem_prag.adb (Process_Restrictions_Or_Restriction_Warnings):
827 Special handling for restriction No_Elaboration_Code.
828
8292011-11-21 Robert Dewar <dewar@adacore.com>
830
831 * gnat_ugn.texi: Document new handling of restrictions pragmas.
832
56272abe
AC
8332011-11-21 Pascal Obry <obry@adacore.com>
834
835 * s-taprop-linux.adb (Initialize_Lock): Do not allocate a cond
836 attribute as not needed.
837
8382011-11-21 Robert Dewar <dewar@adacore.com>
839
840 * sem_prag.adb: Minor reformatting.
841
8422011-11-21 Pascal Obry <obry@adacore.com>
843
844 * gnat_rm.texi: Document restriction for stdcall convention on
845 dispatching calls.
846
a5dd23a7
PO
8472011-11-21 Pascal Obry <obry@adacore.com>
848
849 * sem_prag.adb (Process_Convention): A dispatching call cannot
850 have a stdcall calling convention.
851
8522011-11-21 Pascal Obry <obry@adacore.com>
853
854 * s-taprop-linux.adb (Initialize_Lock): Do not allocate a
855 mutex attribute as not needed.
856 (Initialize_TCB): Likewise.
857 (Initialize): Likewise.
858
a4901c08
AC
8592011-11-21 Robert Dewar <dewar@adacore.com>
860
861 * sem_ch6.adb (Is_Public_Subprogram_For): New procedure
862 (Process_PPCs): Invariants only apply to public subprograms.
863
8642011-11-21 Robert Dewar <dewar@adacore.com>
865
866 * sem_util.adb, sem_util.ads, sem_attr.adb, restrict.adb,
867 restrict.ads: Fix for No_Implicit_Aliasing in the renames case.
868
8692011-11-21 Robert Dewar <dewar@adacore.com>
870
871 * a-finali.ads: Use pragma Pure_12 for this unit
872 * aspects.adb: Add aspect Pure_12
873 * aspects.ads: Add aspect Pure_12
874 * opt.ads: Add note on Pure_12
875 * par-prag.adb: Add dummy entry for Pure_12
876 * sem_prag.adb: Implement Pure_12 pragma
877 * snames.ads-tmpl: Add Entry for Pure_12
878
8792011-11-21 Sergey Rybin <rybin@adacore.com frybin>
880
881 * vms_data.ads: Add qualifiers for new gnatpp options
882 '--call_threshold' and '--par_threshold".
883 * gnat_ugn.texi: Add description for new gnatpp options
884 '--call_threshold' and '--par_threshold".
885
8862011-11-21 Robert Dewar <dewar@adacore.com>
887
888 * lib.ads: Minor reformatting.
889
8902011-11-21 Robert Dewar <dewar@adacore.com>
891
892 * lib-load.ads: Add comment.
893
4bf201ed
AC
8942011-11-21 Gary Dismukes <dismukes@adacore.com>
895
896 * sem_elab.adb: Minor reformatting
897
8982011-11-21 Robert Dewar <dewar@adacore.com>
899
900 * exp_ch6.adb: Minor reformatting.
901
9022011-11-21 Ed Schonberg <schonberg@adacore.com>
903
904 * sem_ch12.adb (Check_Formal_Package_Instance): If a formal
905 subprogram of the formal package is covered by an others
906 association with a box initialization, no check is needed
907 against the actual in the instantiation of the formal package.
908
9092011-11-21 Robert Dewar <dewar@adacore.com>
910
911 * sem_elab.adb (Check_Internal_Call_Continue): Suppress junk
912 elab warning from within precondition/postcondition etc.
913
bdf69d33
AC
9142011-11-21 Ed Schonberg <schonberg@adacore.com>
915
916 * exp_ch6.adb (Expand_Actuals): In Ada 2012, a function call
917 with out parameters may generate assignments to force constraint
918 checks. These checks must be properly placed in the code after the
919 declaration or statement that contains the call.
920
9212011-11-21 Fedor Rybin <frybin@adacore.com>
922
923 * gnat_ugn.texi: Adding info on current gnattest limitations an
924 support of -X option.
925
9262011-11-21 Robert Dewar <dewar@adacore.com>
927
928 * a-cfdlli.adb, a-cbdlli.adb: Minor reformatting.
929
03e1048e
AC
9302011-11-20 Robert Dewar <dewar@adacore.com>
931
932 * exp_ch6.adb, exp_util.adb: Minor reformatting
933
9342011-11-20 Eric Botcazou <ebotcazou@adacore.com>
935
936 * sinfo.ads (Reference): Document that it is OK to set
937 Is_Known_Non_Null on a temporary initialized to a N_Reference
938 node.
939
9402011-11-20 Matthew Heaney <heaney@adacore.com>
941
942 * a-cbdlli.adb, a-cfdlli.adb (Move): Set Last component to 0
943 for Source list.
944
74cab21a
EB
9452011-11-20 Eric Botcazou <ebotcazou@adacore.com>
946
947 * exp_ch6.adb (Make_Build_In_Place_Call_In_Assignment):
948 Declare NEW_EXPR local variable and attach the
949 temporary to it. Set Is_Known_Non_Null on the temporary.
950 (Make_Build_In_Place_Call_In_Object_Declaration): Likewise.
951 * exp_util.adb (Remove_Side_Effects): Set Is_Known_Non_Null on
952 the temporary created to hold the 'Reference of the expression,
953 if any.
954 * checks.adb (Install_Null_Excluding_Check): Bail out for the
955 Get_Current_Excep.all.all idiom generated by the expander.
956
088b91c7
EB
9572011-11-20 Eric Botcazou <ebotcazou@adacore.com>
958
959 * gcc-interface/trans.c (struct language_function): Add GNAT_RET.
960 (f_gnat_ret): New macro.
961 (struct nrv_data): Add GNAT_RET.
962 (finalize_nrv_unc_r): New helper function.
963 (finalize_nrv): Add GNAT_RET parameter. Copy it into DATA. If the
964 function returns unconstrained, use finalize_nrv_unc_r as callback.
965 (return_value_ok_for_nrv_p): Test the alignment of RET_OBJ only if
966 RET_OBJ is non-null.
967 (Subprogram_Body_to_gnu): Pass GNAT_RET to finalize_nrv.
968 (gnat_to_gnu) <N_Return_Statement>: In the return-unconstrained case,
969 if optimization is enabled, record candidates for the Named Return
970 Value optimization.
971
9722011-11-20 Eric Botcazou <ebotcazou@adacore.com>
0d24bf76
EB
973
974 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Add comment.
975 (gnat_to_gnu) <N_Return_Statement>: Add 'else' to avoid doing a useless
976 test. Tweak default case.
977 <N_Goto_Statement>: Use better formatting.
978 * gcc-interface/utils2.c (maybe_wrap_malloc): Use INIT_EXPR instead of
979 MODIFY_EXPR to initialize the storage.
980 (build_allocator): Likewise.
981
b1a785fb
EB
9822011-11-20 Eric Botcazou <ebotcazou@adacore.com>
983
984 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Type>: Adjust
985 call to components_to_record.
986 (components_to_record): Add FIRST_FREE_POS parameter. For the variant
987 part, reuse enclosing union even if there is a representation clause
988 on the Unchecked_Union. If there is a variant part, compute the new
989 first free position, if any. Adjust call to self. Use a single field
990 directly only if it hasn't got a representation clause or is placed at
991 offset zero. Create the variant part at offset 0 if all the fields
992 down to this level have a rep clause. Do not chain the variant part
993 immediately and adjust downstream.
994 Do not test ALL_REP before moving the fields without rep clause to the
995 previous level. Call create_rep_part to create the REP part and force
996 a minimum size on it if necessary. Do not chain it immediately.
997 Create a fake REP part if there are fields without rep clause that need
998 to be laid out starting from FIRST_FREE_POS.
999 At the end, chain the REP part and then the variant part.
1000 (create_rep_part): New function.
1001 (get_rep_part): Minor tweak.
1002 * gcc-interface/utils.c (tree_code_for_record_type): Minor tweak.
1003
590175d2
IS
10042011-11-18 Iain Sandoe <iains@gcc.gnu.org>
1005
1006 PR target/50678
a6b7e723
EB
1007 * init.c (__gnat_error_handler) [Darwin]: Move workaround to the
1008 bug filed as radar #10302855 from __gnat_error_handler to...
1009 (__gnat_adjust_context_for_raise) [Darwin]: ...here. New function.
590175d2 1010 (HAVE_GNAT_ADJUST_CONTEXT_FOR_RAISE) [Darwin]: Define.
590175d2 1011
1e1ae0af
TG
10122011-11-18 Tristan Gingold <gingold@adacore.com>
1013 Iain Sandoe <iains@gcc.gnu.org>
1014
1015 PR target/49992
1016 * mlib-tgt-specific-darwin.adb (Archive_Indexer_Options): Remove.
a6b7e723 1017 * gcc-interface/Makefile.in (darwin): Remove ranlib special-casing.
1e1ae0af 1018
5f41422f
IS
10192011-11-12 Iain Sandoe <iains@gcc.gnu.org>
1020
1021 * gcc-interface/Makefile.in (stamp-gnatlib-$(RTSDIR)): Don't link
1022 s-oscons.ads.
1023 (OSCONS_CPP, OSCONS_EXTRACT): New.
a6b7e723
EB
1024 (./bldtools/oscons/xoscons): New target.
1025 ($(RTSDIR)/s-oscons.ads): Likewise.
1026 (gnatlib): Depend on $(RTSDIR)/s-oscons.ads.
5f41422f
IS
1027 * gcc-interface/Make-lang.in (ada/s-oscons.ads) Remove as dependency.
1028 * Make-generated.in: Remove machinery to generate xoscons and
1029 ada/s-oscons.ads.
1030
033ba5bf
EB
10312011-11-10 Eric Botcazou <ebotcazou@adacore.com>
1032
1033 * fe.h (Serious_Errors_Detected): New macro.
1034 * gcc-interface/gigi.h (build_atomic_load): Declare.
1035 (build_atomic_store): Likewise.
1036 * gcc-interface/trans.c (atomic_sync_required_p): New predicate.
1037 (call_to_gnu): Add ATOMIC_SYNC parameter. Use local variable.
1038 Build an atomic load for an In or In Out parameter if needed.
1039 Build an atomic store for the assignment of an Out parameter if needed.
1040 Build an atomic store to the target if ATOMIC_SYNC is true.
1041 (present_in_lhs_or_actual_p): New predicate.
1042 (gnat_to_gnu) <N_Identifier>: Build an atomic load if needed.
1043 <N_Explicit_Dereference>: Likewise.
1044 <N_Indexed_Component>: Likewise.
1045 <N_Selected_Component>: Likewise.
1046 <N_Assignment_Statement>: Adjust call to call_to_gnu.
1047 Build an atomic store to the LHS if needed.
1048 <N_Function_Call>: Adjust call to call_to_gnu.
1049 * gcc-interface/utils2.c: Include toplev.h.
1050 (resolve_atomic_size): New static function.
1051 (build_atomic_load): New function.
1052 (build_atomic_store): Likewise.
1053 * gcc-interface/Make-lang.in (ada/utils2.o): Add toplev.h.
1054
b5bf3335
AC
10552011-11-07 Olivier Hainque <hainque@adacore.com>
1056
1057 * sigtramp-ppcvxw.c: Add general comments.
1058 (CFI_COMMON_REGS): Remove rule for r1, as in other unwinders. Add
1059 rules for r2 to r13, plus CTR and XER.
1060 (CFA_REG): New, register number used to hold the local CFA.
1061 (CFI_DEF_CFA, SIGTRAMP_BODY): Use it.
1062 Make that 15, not 14, with documentation.
1063 (TCR): Undef before definition, preventing conflict with reg number in
1064 VxWorks headers.
1065
10662011-11-07 Robert Dewar <dewar@adacore.com>
1067
1068 * exp_util.ads, exp_alfa.adb, a-cohama.adb, a-cohama.ads, sem_ch4.adb,
1069 aspects.ads, exp_ch8.adb, exp_ch8.ads, atree.ads: Minor reformatting.
1070 * gcc-interface/Make-lang.in: Update dependencies.
1071
10722011-11-07 Ed Schonberg <schonberg@adacore.com>
1073
1074 * exp_ch6.adb: A tagged type is a legal actual for an aliased
1075 formal.
1076
10772011-11-07 Pascal Obry <obry@adacore.com>
1078
1079 * g-socket.adb, g-socket.ads: Minor reformatting.
1080
10812011-11-07 Robert Dewar <dewar@adacore.com>
1082
1083 * sem_res.adb (Resolve_Actuals): Minor error message improvement.
1084
10852011-11-07 Robert Dewar <dewar@adacore.com>
1086
1087 * gnat_ugn.texi: Add discussion of default mode handling of
1088 source representation with no -gnatW option given, in particular
1089 noting that NEL (next line) is not recognized in this context.
1090
9ee76313
AC
10912011-11-07 Yannick Moy <moy@adacore.com>
1092
1093 * sem_util.adb (Note_Possible_Modification): In Alfa mode,
1094 generate a reference for a modification even when the modification
1095 does not come from source.
1096
10972011-11-07 Ed Schonberg <schonberg@adacore.com>
1098
1099 * exp_ch5.adb (Expand_Iterator_Loop): For the "of" iterator form,
1100 use the indexing attributes rather than the Element function,
1101 to obtain variable references.
1102 * sem_ch4.adb (Try_Container_Indexing): Code cleanup. Use
1103 Find_Aspect rather than iterating over representation
1104 items. Improve error message.
1105 * a-cohama.adb, a-cohama.ads Update to latest RM, with two versions
1106 of Reference functions.
1107
7b7a0c2b
AC
11082011-11-07 Yannick Moy <moy@adacore.com>
1109
1110 * sem_util.adb (Unique_Entity): For a parameter on a subprogram
1111 body that has a corresponding parameter on the subprogram
1112 declaration, define the unique entity as being the declaration
1113 one.
1114
11152011-11-07 Ed Schonberg <schonberg@adacore.com>
1116
1117 * sem_ch6.adb (Analyze_Return_Type): In Ada 2012 mode, if the
1118 return type of a function is the class-wide type of an incomplete
1119 type T, T can be a Taft-amendment type and does not have to be
1120 completed in the current private part.
1121
11222011-11-07 Ed Schonberg <schonberg@adacore.com>
1123
1124 * aspects.ads (Inherited_Aspect): Map that indicates type aspects
1125 that are inherited by default, and apply to the class-wide type
1126 as well.
1127 * aspects.adb (Find_Aspect): If the entity is class-wide and the
1128 aspect is inherited, use the aspect of the specific type.
1129
cc570be6
AC
11302011-11-07 Hristian Kirtchev <kirtchev@adacore.com>
1131
1132 * exp_alfa.adb: Remove with and use clause for
1133 Exp_Ch8. Add with and use clause for Exp_Util.
1134 Remove local constant Disable_Processing_Of_Renamings.
1135 (Expand_Alfa_N_Object_Renaming_Declaration): The expansion of
1136 object renamings has been reenabled.
1137 (Expand_Possible_Renaming):
1138 The expansion of identifier and expanded names has been
1139 reenabled. Perform the substitutions only for entities that
1140 denote an object.
1141 * exp_ch8.ads, exp_ch8.adb (Evaluate_Name): Moved to Exp_Util.
1142 * exp_util.adb (Evaluate_Name): Moved from Exp_Ch8.
1143 (Remove_Side_Effects): Alphabetize local variables. Add a guard
1144 to avoid the infinite expansion of an expression in Alfa mode. Add
1145 processing for function calls in Alfa mode.
1146 * exp_util.ads (Evaliate_Name): Moved from Exp_Ch8.
1147
11482011-11-07 Ed Schonberg <schonberg@adacore.com>
1149
1150 * freeze.adb (Freeze_Entity): If the entity is an access to
1151 subprogram whose designated type is itself a subprogram type,
1152 its own return type must be decorated with size information.
1153
b6d185a5
AC
11542011-11-04 Arnaud Charlet <charlet@adacore.com>
1155
1156 * gcc-interface/Make-lang.in: Update dependencies.
1157
1adaea16
AC
11582011-11-04 Robert Dewar <dewar@adacore.com>
1159
1160 * sprint.adb (Sprint_Node_Actual, case Qualified_Expression):
1161 Avoid junk semicolon after argument of machine code Asm operand.
1162
11632011-11-04 Robert Dewar <dewar@adacore.com>
1164
1165 * exp_ch11.adb (Generate_Push_Pop): Inhibit push/pop nodes in
1166 CodePeer mode or if restriction No_Exception_Handlers is present.
1167 * exp_ch6.adb (Expand_N_Subprogram_Body): (Inhibit push/pop
1168 nodes in CodePeer mode or if restriction No_Exception_Handlers
1169 is present.
1170
11712011-11-04 Robert Dewar <dewar@adacore.com>
1172
1173 * s-tassta.adb, atree.ads, errout.adb, sinput.adb: Minor reformatting.
1174
11752011-11-04 Ed Schonberg <schonberg@adacore.com>
1176
1177 * sem_ch6.adb (Analyze_Subprogram_Specification): The
1178 specification is legal if it is a function that returns an
1179 abstract type, if it comes from an attribute renaming of a stream
1180 attribute of an abstract type.
1181
11822011-11-04 Gary Dismukes <dismukes@adacore.com>
1183
1184 * exp_util.adb (Is_Possibly_Unaligned_Object): In case of indexed
1185 components, check whether recursively check whether the prefix
1186 denotes an unaligned object.
1187
11882011-11-04 Ed Schonberg <schonberg@adacore.com>
1189
1190 * sem_prag.adb (Analyze_Pragma, case Debug): The argument of
1191 the pragma is legal if it is an expanded name that denotes a
1192 procedure that be can called without parameters.
1193
11942011-11-04 Eric Botcazou <ebotcazou@adacore.com>
1195
1196 * gnat_ugn.texi (Performance Considerations) <Vectorization
1197 of loops>: New sub-section. <Other Optimization Switches>:
1198 Minor tweak.
1199
4c9fe6c7
AC
12002011-11-04 Robert Dewar <dewar@adacore.com>
1201
1202 * gnat_rm.texi: Minor reformatting.
1203
12042011-11-04 Matthew Heaney <heaney@adacore.com>
1205
1206 * a-convec.adb, a-coinve.adb, a-cobove.adb (Merge): Raise PE
1207 when Target and Source denote same non-empty object
1208 * a-cdlili.adb, a-cidlli.adb, a-cbdlli.adb (Merge): Ditto
1209
12102011-11-04 Robert Dewar <dewar@adacore.com>
1211
1212 * exp_attr.adb: Minor reformatting.
1213
12142011-11-04 Ed Schonberg <schonberg@adacore.com>
1215
1216 * exp_ch5.adb (Expand_Assign_Record): Do not generate a
1217 discriminant assignment within an initialization proc if the
1218 record is an unchecked union, as it can only come from the
1219 initialization of an unchecked union component.
1220
12212011-11-04 Robert Dewar <dewar@adacore.com>
1222
1223 * gnat_ugn.texi: Minor reformatting.
1224
12252011-11-04 Robert Dewar <dewar@adacore.com>
1226
1227 * par-labl.adb (Rewrite_As_Loop): Generate info msg rather than
1228 warning message.
1229
12302011-11-04 Robert Dewar <dewar@adacore.com>
1231
1232 * exp_ch4.adb: Minor code reorganization (remove junk obsolete
1233 var Save_Space).
1234
6ec084f3
HK
12352011-11-04 Hristian Kirtchev <kirtchev@adacore.com>
1236
1237 * exp_alfa.adb: Add local constant
1238 Disable_Processing_Of_Renamings;
1239 (Expand_Alfa_N_Object_Renaming_Declaration): Disable
1240 the name evaluation of object renamings for now.
1241 (Expand_Potential_Renaming): Do not perform the substitution
1242 for now.
1243 * exp_util.adb (Remove_Side_Effects): Remove processing for
1244 functions with side effects in Alfa mode.
1245
73fe1679
AC
12462011-11-04 Gary Dismukes <dismukes@adacore.com>
1247
1248 * bindgen.adb (Gen_Elab_Calls): In the case
1249 of the AAMP target, set elaboration entities to 1 rather than
1250 incrementing.
1251
12522011-11-04 Ed Schonberg <schonberg@adacore.com>
1253
1254 * sem_ch10.adb (Install_Limited_With_Unit): To establish the
1255 proper entities on the ancestors of a child unit that appear
1256 in a limited_with clause, follow the unit links because the
1257 units are not analyzed and scope information is incomplete.
1258
12592011-11-04 Eric Botcazou <ebotcazou@adacore.com>
1260
1261 * exp_ch4.adb (Expand_N_Selected_Component): Refine code
1262 setting the Atomic_Sync_Required flag to detect one more case.
1263 * exp_util.adb (Activate_Atomic_Synchronization): Refine code
1264 setting the Atomic_Sync_Required flag to exclude more cases,
1265 depending on the parent of the node to be examined.
1266
12672011-11-04 Bob Duff <duff@adacore.com>
1268
1269 * g-excact.adb: Minor: use named notation.
1270
12712011-11-04 Ed Schonberg <schonberg@adacore.com>
1272
1273 * sem_ch5.adb: Improve error messages for illegal iterators.
1274
b2ab8c33
AC
12752011-11-04 Hristian Kirtchev <kirtchev@adacore.com>
1276
1277 * exp_alfa.adb: Add with and use clauses for Exp_Ch8 and
1278 Sem_Util.
1279 (Expand_Alfa): Alphabetize cases on first choice. Add
1280 processing for object renaming declarations, identifiers and
1281 expanded names.
1282 (Expand_Alfa_N_In): Remove useless return.
1283 (Expand_Alfa_N_Object_Renaming_Declaration): New routine.
1284 (Expand_Potential_Renaming): New routine.
1285 * exp_ch8.adb (Evaluate_Name): Moved to the top level.
1286 (Expand_N_Object_Declaration): Alphabetize local variables. Move
1287 Evaluate_Name out to the top level.
1288 * exp_ch8.ads (Evaluate_Name): Moved from body to package spec.
1289 * exp_util.adb (Remove_Side_Effects): Add processing for
1290 functions with side effects in Alfa mode.
1291
12922011-11-04 Hristian Kirtchev <kirtchev@adacore.com>
1293
1294 * gnat_rm.texi: Add entries for
1295 restrictions No_Relative_Delay, No_Requeue_Statements and
1296 No_Stream_Optimizations.
1297
12982011-11-04 Ed Schonberg <schonberg@adacore.com>
1299
1300 * sem_ch4.adb: Set type of entity in prefixed call, for
1301 completeness in a generic context.
1302
4c318253
AC
13032011-11-04 Yannick Moy <moy@adacore.com>
1304
1305 * sem_prag.adb: Minor refactoring (renaming of a parameter).
1306
13072011-11-04 Robert Dewar <dewar@adacore.com>
1308
1309 * atree.ads: Minor reformatting.
1310
13112011-11-04 Robert Dewar <dewar@adacore.com>
1312
1313 * checks.adb (Atomic_Synchronization_Disabled): Check -gnatd.d
1314 and -gnatd.e here
1315 * exp_ch2.adb (Expand_Entity_Reference): Use
1316 Activate_Atomic_Synchronization
1317 * exp_ch4.adb (Expand_N_Explicit_Dereference): Use
1318 Activate_Atomic_Synchronization (Expand_N_Indexed_Compoonent):
1319 Activate_Atomic_Synchronization (Expand_N_Selected_Component):
1320 Use Activate_Atomic_Synchronization
1321 * exp_util.ads, exp_util.adb (Activate_Atomic_Synchronization): New
1322 procedure.
1323 * sinfo.ads, sinfo.adb (Atomic_Sync_Required): Can now apply to
1324 N_Selected_Component node
1325
37765e95
RD
13262011-11-04 Robert Dewar <dewar@adacore.com>
1327
1328 * sem_prag.adb, atree.ads, prj-env.adb, prj-env.ads: Minor reformatting.
1329
8c18a165
AC
13302011-11-04 Yannick Moy <moy@adacore.com>
1331
1332 * atree.adb, atree.ads (Set_Original_Node): New set procedure.
1333 * sem_ch13.adb (Analyze_Aspect_Specifications/Pre_Post_Aspects):
1334 In ASIS mode, no splitting of aspects between conjuncts.
1335 (Analyze_Aspect_Specifications/Aspect_Test_Case): Make pragma
1336 expressions refer to the original aspect expressions through
1337 the Original_Node link. This is used in semantic analysis for
1338 ASIS mode, so that the original expression also gets analyzed.
1339 * sem_prag.adb (Preanalyze_TC_Args,
1340 Check_Precondition_Postcondition,
1341 Analyze_Pragma/Pragma_Test_Case): In ASIS mode, for a pragma
1342 generated from a source aspect, also analyze the original aspect
1343 expression.
1344 (Check_Expr_Is_Static_Expression): New procedure
1345 similar to existing procedure Check_Arg_Is_Static_Expression,
1346 except called on expression inside pragma.
1347
13482011-11-04 Tristan Gingold <gingold@adacore.com>
1349
1350 * prj-env.adb, prj-env.ads (Find_Name_In_Path): New function, from
1351 Find_Project.Try_Path_Name.
1352 (Find_Project): Use Find_Name_In_Path to implement Try_Path_Name.
1353
13542011-11-04 Eric Botcazou <ebotcazou@adacore.com>
1355
1356 * s-atocou.ads (Atomic_Counter): Remove redundant pragma Volatile.
1357
13582011-11-04 Pascal Obry <obry@adacore.com>
1359
1360 * projects.texi: Add short description for qualifiers aggregate
1361 and aggregate library.
1362
13632011-11-04 Matthew Heaney <heaney@adacore.com>
1364
1365 * Makefile.rtl, impunit.adb: Added a-cogeso.ad[sb]
1366 * a-cgaaso.adb: Replaced implementation with instantiation
1367 of Generic_Sort.
1368 * a-cogeso.ad[sb] This is the new Ada 2012 unit
1369 Ada.Containers.Generic_Sort
1370
5972791c
AC
13712011-11-04 Robert Dewar <dewar@adacore.com>
1372
1373 * exp_ch2.adb (Expand_Entity_Reference): Do not set
1374 Atomic_Sync_Required for the case of a prefix of an attribute.
1375 * exp_ch4.adb (Expand_N_Explicit_Dereference): May require
1376 atomic synchronization
1377 (Expand_N_Indexed_Component): Ditto.
1378 (Expand_B_Selected_Component): Ditto.
1379 * sem_prag.adb (Process_Suppress_Unsuppress):
1380 Disable/Enable_Atomic_Synchronization can now occur for array
1381 types with pragma Atomic_Components.
1382 * sinfo.ads, sinfo.adb (Atomic_Sync_Required): Can now occur on
1383 N_Explicit_Dereference nodes and on N_Indexed_Component nodes.
1384
13852011-11-04 Gary Dismukes <dismukes@adacore.com>
1386
1387 * gnat_ugn.texi: Editorial corrections for gnattest section.
1388
8751a35c
RD
13892011-11-04 Robert Dewar <dewar@adacore.com>
1390
1391 * sem_prag.adb: Minor reformatting.
1392 * gnat_rm.texi: Update documentation for pragma Warnings (Off,
1393 "***") usage.
1394 * exp_ch2.adb (Expand_Entity_Reference): Only set
1395 Atomic_Sync_Required on entities that are variables. Doesn't
1396 make any sense on anything else.
1397
fb5d63c6
RD
13982011-11-04 Robert Dewar <dewar@adacore.com>
1399
1400 * exp_ch2.adb (Expand_Entity_Reference): Extend handling of
1401 atomic sync to type case.
1402 * sem_prag.adb (Process_Suppress_Unsuppress): Atomic Sync can
1403 apply to types.
1404
a51cd0ec 14052011-11-04 Robert Dewar <dewar@adacore.com>
25ec1790 1406
a51cd0ec
AC
1407 * sem_warn.adb (Warn_On_Useless_Assignment): More accurate test
1408 for call vs assign.
1409 * gcc-interface/Make-lang.in: Update dependencies.
1410
14112011-11-04 Robert Dewar <dewar@adacore.com>
1412
1413 * sem_prag.adb: Detect more cases of Long_Float inconsistencies at
1414 compile time.
1415
14162011-11-04 Matthew Heaney <heaney@adacore.com>
1417
1418 * Makefile.rtl, impunit.adb: Added a-sfecin.ads,
1419 * a-sfhcin.ads, a-sflcin.ads, a-sbecin.ad[sb], a-sbhcin.ad[sb],
1420 a-sblcin.ad[sb], a-suecin.ad[sb], a-suhcin.ad[sb], a-sulcin.ad[sb]
1421 * a-sfecin.ads, a-sfhcin.ads, a-sflcin.ads, a-sbecin.ad[sb],
1422 a-sbhcin.ad[sb], a-sblcin.ad[sb], a-suecin.ad[sb], a-suhcin.ad[sb],
1423 a-sulcin.ad[sb]: New files.
1424
14252011-11-04 Geert Bosch <bosch@adacore.com>
1426
1427 * i-forbla-unimplemented.ads, s-gecola.adb, s-gecola.ads,
1428 s-gerebl.adb, s-gerebl.ads, i-forbla.adb, i-forbla.ads,
1429 i-forlap.ads, i-forbla-darwin.adb, s-gecobl.adb, s-gecobl.ads,
1430 s-gerela.adb, s-gerela.ads: Remove partial interface to BLAS/LAPACK.
1431 * gcc-interface/Makefile.in: Remove libgnala and related objects.
25ec1790 1432
a31945d7
AC
14332011-11-04 Matthew Heaney <heaney@adacore.com>
1434
1435 * a-cdlili.ad[sb], a-cidlli.ad[sb], a-coorse.ad[sb], a-ciorse.ad[sb],
1436 a-coorma.ad[sb], a-ciorma.ad[sb], a-coormu.ad[sb], a-ciormu.ad[sb],
1437 a-cohama.ad[sb], a-cihama.ad[sb], a-cohase.ad[sb], a-cihase.ad[sb],
1438 a-convec.ad[sb], a-coinve.ad[sb] (Assign, Copy): New operations
1439 added to package.
1440
a51cd0ec
AC
14412011-11-04 Eric Botcazou <ebotcazou@adacore.com>
1442
1443 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Do not assert
1444 that the type of the parameters isn't dummy in type_annotate_only mode.
1445
a31945d7
AC
14462011-11-04 Robert Dewar <dewar@adacore.com>
1447
1448 * sem_ch12.adb: Minor reformatting
1449
14502011-11-04 Gary Dismukes <dismukes@adacore.com>
1451
1452 * bindgen.adb (Gen_Elab_Calls): In the case of the AAMP target,
1453 initialize elaboration entities to zero when specs are processed.
1454
a53f3523
IS
14552011-10-28 Iain Sandoe <iains@gcc.gnu.org>
1456 Eric Botcazou <ebotcazou@adacore.com>
1457
1458 PR target/50678
be7552fc
EB
1459 * init.c (__gnat_error_handler) [Darwin]: Apply a work-around to the
1460 bug filed as radar #10302855 (inconsistent unwind data for sigtramp).
a53f3523 1461
0de82be5
EB
14622011-10-28 Eric Botcazou <ebotcazou@adacore.com>
1463
1464 PR ada/50842
1465 * gcc-interface/Makefile.in (SYMDEPS): Delete.
1466 (LIBICONV): New variable.
1467 (LIBICONV_DEP): Likewise.
1468 (LIBS): Add $(LIBICONV).
1469 (LIBDEPS): Add $(LIBICONV_DEP).
1470 (EXTRA_GNATTOOLS_OBJS): Merge into...
1471 (TOOLS_LIBS): ...this. Add $(LIBICONV).
e1e5852c 1472
1586f8a3
EB
14732011-10-26 Eric Botcazou <ebotcazou@adacore.com>
1474
1475 * gcc-interface/decl.c (elaborate_expression_1): Add EXPR_PUBLIC_P local
1476 variable. Always create the elaboration variable, if any, as constant.
1477
e1e5852c
EB
14782011-10-26 Eric Botcazou <ebotcazou@adacore.com>
1479
1480 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Subtype>: Try to
1481 make a packable type for fields of union types as well.
1482 <is_type>: Use RECORD_OR_UNION_TYPE_P predicate.
1483 (gnat_to_gnu_component_type): Try to make a packable type for fields
1484 of union types as well.
1485 (make_packable_type): Use RECORD_OR_UNION_TYPE_P predicate.
1486 (maybe_pad_type): Try to make a packable type for fields of union types
1487 as well.
1488 (gnat_to_gnu_field): Likewise.
1489 (is_variable_size): Use RECORD_OR_UNION_TYPE_P predicate.
1490 (set_rm_size): Likewise.
1491 (rm_size): Likewise.
1492 * gcc-interface/misc.c (gnat_type_max_size): Likewise.
1493 * gcc-interface/trans.c (add_decl_expr): Likewise.
1494 * gcc-interface/utils.c (finish_record_type): Likewise.
1495 * gcc-interface/utils2.c (build_simple_component_ref): Likewise.
1496
0025cb63
EB
14972011-10-26 Eric Botcazou <ebotcazou@adacore.com>
1498
1499 * gcc-interface/decl.c (gnat_to_gnu_field): Always check components
1500 declared as atomic. Move around conditionally executed code.
1501
b3c33641
AC
15022011-10-24 Robert Dewar <dewar@adacore.com>
1503
be7552fc 1504 * sem.adb (Initialize): Fix bug that blew up if called a second time.
b3c33641
AC
1505
15062011-10-24 Robert Dewar <dewar@adacore.com>
1507
1508 * tb-alvxw.c, tracebak.c, expect.c, initflt.c, tb-alvms.c,
1509 tb-ivms.c, tb-gcc.c: Update headers to GPL 3.
1510
15112011-10-24 Robert Dewar <dewar@adacore.com>
1512
1513 * sem_prag.adb (Analyze_Pragma, case Debug): Give proper pragma
1514 name in error msg.
1515
15162011-10-24 Hristian Kirtchev <kirtchev@adacore.com>
1517
be7552fc 1518 * gnat_rm.texi: Add an entry for restriction No_Finalization.
b3c33641
AC
1519
15202011-10-24 Ed Schonberg <schonberg@adacore.com>
1521
1522 * sem_ch12.adb (Insert_Freeze_Node_For_Instance): If the
1523 current instance is within the one that contains the generic,
1524 the freeze node for the current one must appear in the current
1525 declarative part. Ditto if the current instance is within another
1526 package instance. In both of these cases the freeze node of the
1527 previous instance is not relevant.
1528
15292011-10-24 Gary Dismukes <dismukes@adacore.com>
1530
1531 * switch-m.adb (Normalize_Compiler_Switches): Add recognition
1532 of AAMP-specific switches -univ and -aamp_target.
1533
15342011-10-24 Robert Dewar <dewar@adacore.com>
1535
1536 * a-tienau.adb (Put): Deal properly with limited line length.
1537
15382011-10-24 Robert Dewar <dewar@adacore.com>
1539
1540 * sem_warn.adb, sem_ch12.adb: Minor reformatting.
1541
30e1709c 15422011-10-24 Tristan Gingold <gingold@adacore.com>
8263e17a
TG
1543
1544 * gcc-interface/Makefile.in: Use GNU ld switches to generate map files
1545 on AIX.
1546
12b4d338
AC
15472011-10-24 Ed Schonberg <schonberg@adacore.com>
1548
1549 * sem_ch12.adb (Earlier): make available globally. If both
1550 nodes have the same sloc, the freeze node that does not come
1551 from source is the later one.
1552 (True_Parent): Make available globally.
1553 (Previous_Instance): Subsidiary of
1554 Insert_Freeze_Node_For_Instance, to check whether the generic
1555 parent of the current instance is declared within a previous
1556 instance in the same unit or declarative part, in which case the
1557 freeze nodes of both instances must appear in order to prevent
1558 elaboration problems in gigi.
1559 * sem_ch12.adb (Insert_Freeze_Node_For_Instance): A stub is a
1560 freeze point, and the freeze node of a preceding instantiation
1561 must be inserted before it.
1562
15632011-10-24 Robert Dewar <dewar@adacore.com>
1564
1565 * checks.ads, checks.adb: Add handling of Synchronization_Check
1566 * debug.adb: Add doc for -gnatd.d and -gnatd.e (disable/enable
1567 atomic sync).
1568 * exp_ch2.adb (Expand_Entity_Reference): Set Atomic_Sync_Required
1569 flag Minor code reorganization.
1570 * opt.ads (Warn_On_Atomic_Synchronization): New switch.
1571 * par-prag.adb: Add dummy entries for pragma
1572 Disable/Enable_Atomic_Synchronization.
1573 * sem_prag.adb (Process_Suppress_Unsuppress): Handle
1574 case of Atomic_Synchronization specially (not suppressed
1575 by All_Checks, cannot be set from Source).
1576 (Pragma Disable/Enable_Atomic_Synchronization): Add processing.
1577 * sinfo.ads, sinfo.adb: Add Atomic_Sync_Required flag
1578 * snames.ads-tmpl: Add entry for Atomic_Synchronization Add
1579 entry for pragma Disable/Enable_Atomic_Synchronization
1580 * switch-c.adb: The -gnatp switch does not disable
1581 Atomic_Synchronization Add -gnatep switch to disable
1582 Atomic_Synchronization.
1583 * types.ads: Add entry for Synchronization_Check
1584 * usage.adb: Add line for -gnated switch
1585 * warnsw.adb: Settings for Warn_On_Atomic_Synchronization
1586
08ce7bb8
AC
15872011-10-24 Geert Bosch <bosch@adacore.com>
1588
be7552fc
EB
1589 * s-gearop.adb (Back_Substitute): Avoid overflow if matrix bounds start
1590 at Integer'First.
08ce7bb8
AC
1591
15922011-10-24 Robert Dewar <dewar@adacore.com>
1593
be7552fc 1594 * sem_ch12.adb, s-gearop.adb: Minor reformatting.
08ce7bb8
AC
1595
15962011-10-24 Robert Dewar <dewar@adacore.com>
1597
be7552fc
EB
1598 * warnsw.adb: Add some missing warnings to Set_GNAT_Mode_Warnings.
1599 * warnsw.ads: Add comments to Set_GNAT_Mode_Warnings.
08ce7bb8 1600
292689c2
AC
16012011-10-24 Emmanuel Briot <briot@adacore.com>
1602
1603 * prj-proc.adb (Process_Expression_Variable_Decl): No special
1604 handling for Project_Path unless it is an attribute.
1605
16062011-10-24 Javier Miranda <miranda@adacore.com>
1607
1608 * sem_ch12.adb (Check_Hidden_Primitives): New subprogram.
1609 (Install_Hidden_Primitives): New subprogram.
1610 (Restore_Hidden_Primitives): New subprogram.
1611 (Analyze_Formal_Package_Declaration,
1612 Analyze_Package_Instantiation, Analyze_Subprogram_Instantiation):
1613 Invoke Check_Hidden_Primitives after every call to
1614 Analyze_Associations, and invoke Restore_Hidden_Primitives to
1615 restore their visibility after processing the instantiation.
1616 (Instantiate_Package_Body): Install visible primitives before
1617 analyzing the instantiation and uninstall them to restore their
1618 visibility when the instantiation has been analyzed.
1619 * sem_util.ads, sem_util.adb (Add_Suffix): New subprogram
1620 (Remove_Suffix): New subprogram
1621 * sem_ch3.adb (Derive_Subprogram): When handling
1622 a derived subprogram for the instantiation of a formal derived
1623 tagged type, inherit the dispatching attributes from the actual
1624 subprogram (not from the parent type).
1625
db4b3c49
AC
16262011-10-24 Vasiliy Fofanov <fofanov@adacore.com>
1627
1628 * gnat_ugn.texi: Document explicit use of XDECGNAT library.
1629
16302011-10-24 Hristian Kirtchev <kirtchev@adacore.com>
1631
1632 * exp_ch3.adb (Build_Assignment): Add local constant N_Loc and
1633 update its uses.
1634 (Build_Discriminant_Assignments): Add local variable D_Loc and update
1635 its uses.
1636 (Build_Init_Statements): Add local variables Comp_Loc, Decl_Loc and
1637 Var_Loc and update their uses.
1638 (Build_Record_Init_Proc): Code reformatting.
1639 (Increment_Counter): Add formal parameter Loc.
1640 (Make_Counter): Add formal parameter Loc.
1641
16422011-10-24 Eric Botcazou <ebotcazou@adacore.com>
1643
1644 * sem_disp.adb (Covers_Some_Interface): Fix typo.
1645
16462011-10-24 Matthew Heaney <heaney@adacore.com>
1647
be7552fc
EB
1648 * a-cuprqu.adb, a-cbprqu.adb (Dequeue_Only_High_Priority): Fix sense
1649 of predicate.
db4b3c49
AC
1650
16512011-10-24 Yannick Moy <moy@adacore.com>
1652
1653 * sem_ch13.adb (Analyze_Aspect_Specifications/Aspect_Test_Case):
1654 Translate arguments in positional notation into pragma argument
1655 association arguments for the generated pragma.
1656
16572011-10-24 Arnaud Charlet <charlet@adacore.com>
1658
1659 * exp_ch5.adb: Fix minor typo.
1660
16612011-10-24 Ed Schonberg <schonberg@adacore.com>
1662
1663 * sem_ch3.adb (Is_Visible_Component): Refine predicate for
1664 the case of a component reference in an instance body, when the
1665 enclosing type is private.
1666
86f0e17a
AC
16672011-10-24 Sergey Rybin <rybin@adacore.com frybin>
1668
1669 * gnat_ugn.texi: For gnatelim, move the note about using the GNAT
1670 driver for getting the project support into gnatelim section.
1671
16722011-10-24 Robert Dewar <dewar@adacore.com>
1673
be7552fc 1674 * gnat_rm.texi: Minor correction to documentation on address clause.
86f0e17a
AC
1675
16762011-10-24 Hristian Kirtchev <kirtchev@adacore.com>
1677
1678 * s-finmas.adb (Attach): Synchronize and call the unprotected version.
1679 (Attach_Unprotected): New routine.
1680 (Delete_Finalize_Address): Removed.
1681 (Delete_Finalize_Address_Unprotected): New routine.
1682 (Detach): Synchronize and call the unprotected version.
1683 (Detach_Unprotected): Remove locking.
1684 (Finalize): Add various comment on synchronization. Lock the critical
1685 region and call the unprotected versions of routines.
1686 (Finalize_Address): Removed.
1687 (Finalize_Address_Unprotected): New routine.
1688 (Set_Finalize_Address): Synchronize and call
1689 the unprotected version.
1690 (Set_Finalize_Address_Unprotected): New routine.
1691 (Set_Heterogeneous_Finalize_Address): Removed.
1692 (Set_Heterogeneous_Finalize_Address_Unprotected): New routine.
1693 (Set_Is_Heterogeneous): Add comment on synchronization and
1694 locking.
1695 * s-finmas.ads: Flag Finalization_Started is no longer atomic
1696 because synchronization uses task locking / unlocking.
1697 (Attach): Add comment on usage.
1698 (Attach_Unprotected): New routine.
1699 (Delete_Finalize_Address): Renamed to
1700 Delete_Finalize_Address_Unprotected.
1701 (Detach): Add comment on usage.
1702 (Detach_Unprotected): New routine.
1703 (Finalize_Address): Renamed to Finalize_Address_Unprotected.
1704 (Set_Finalize_Address): Add comment on usage.
1705 (Set_Finalize_Address_Unprotected): New routine.
1706 (Set_Heterogeneous_Finalize_Address): Renamed to
1707 Set_Heterogeneous_Finalize_Address_Unprotected.
1708 * s-stposu.adb (Allocate_Any_Controlled): Add local variable
1709 Allocation_Locked. Add various comments on synchronization. Lock
1710 the critical region and call the unprotected version of
1711 routines.
1712 (Deallocate_Any_Controlled): Add various comments on
1713 synchronization. Lock the critical region and call the unprotected
1714 version of routines.
1715
17162011-10-24 Ed Schonberg <schonberg@adacore.com>
1717
1718 * sem_ch3.adb (Set_Fixed_Range): The bounds of a fixed point type
1719 are universal and must carry the corresponding type.
1720 * sem_eval.adb (Check_Non_Static_Context): If the type of the
1721 expression is universal real, as may be the case for a fixed point
1722 expression with constant operands in the context of a conversion,
1723 there is nothing to check.
1724 * s-finmas.adb: Minor reformatting
1725
be98aaf0
EB
17262011-10-23 Eric Botcazou <ebotcazou@adacore.com>
1727
1728 * gcc-interface/decl.c (create_concat_name): Add explicit cast.
1729
e45c0886
EB
17302011-10-20 Eric Botcazou <ebotcazou@adacore.com>
1731
1732 * gcc-interface/Make-lang.in (GNATLIBFLAGS, GNATLIBCFLAGS, THREAD_KIND,
1733 TRACE): Reintroduce.
1734 (ada/tracebak.o, ada/targext.o, ada/cio.o, ada/init.o,
1735 ada/initialize.o, ada/raise.o): Reintroduce explicit compilation rules.
1736
27ab5bd8
EB
17372011-10-20 Eric Botcazou <ebotcazou@adacore.com>
1738
1739 * gcc-interface/trans.c (lhs_or_actual_p): New predicate.
1740 (unchecked_conversion_nop): Use it.
1741 (gnat_to_gnu): Likewise.
1742
b7562769
EB
17432011-10-20 Eric Botcazou <ebotcazou@adacore.com>
1744
1745 * back_end.adb (Call_Back_End): Pass the maximum logical line number
1746 instead of the maximum physical line number to gigi.
1747 * gcc-interface/trans.c (Sloc_to_locus): Cope with line zero.
1748
53e7c794 17492011-10-16 Tom Tromey <tromey@redhat.com>
46427374
TT
1750 Dodji Seketeli <dodji@redhat.com>
1751
be7552fc
EB
1752 * gcc-interface/trans.c (gigi, Sloc_to_locus): Adjust to use the new
1753 public ordinary map interface.
46427374 1754
ea10ca9c
AC
17552011-10-16 Tristan Gingold <gingold@adacore.com>
1756
53e7c794 1757 * link.c (_AIX): Add support for GNU ld.
ea10ca9c
AC
1758
17592011-10-16 Fedor Rybin <frybin@adacore.com>
1760
1761 * gnat_ugn.texi: Fixing gnattest example names in the doc.
1762 Adding explanation to additional tests usage.
1763
17642011-10-16 Robert Dewar <dewar@adacore.com>
1765
1766 * exp_ch6.adb, sem_ch6.adb: Minor reformatting.
1767
17682011-10-16 Eric Botcazou <ebotcazou@adacore.com>
1769
1770 * a-convec.adb: Fix minor inconsistencies.
1771
17722011-10-16 Matthew Heaney <heaney@adacore.com>
1773
1774 * a-cusyqu.ads, a-cbsyqu.ads, a-cuprqu.ads, a-cbprqu.ads (package
1775 Implementation): Specify pragma Implementation_Defined.
1776
c225ba50
NR
17772011-10-15 Nicolas Roche <roche@adacore.com>
1778
1779 * gcc-interface/lang-specs.h: Ensure -mrtp switch is passed when using
1780 either rtp-smp or ravenscar-cert-rtp runtimes.
1781
3e452820
AC
17822011-10-15 Bob Duff <duff@adacore.com>
1783
1784 * exp_ch6.adb (Add_Unconstrained_Actuals_To_Build_In_Place_Call):
1785 Do not create a pool formal on unless RE_Root_Storage_Pool_Ptr
1786 is available.
1787 (Expand_N_Extended_Return_Statement): Do not create a renaming of the
1788 build-in-place pool parameter unless RE_Root_Storage_Pool_Ptr is
1789 available.
1790 (Make_Build_In_Place_Call_In_Allocator): Add the user-defined
1791 pool only if RE_Root_Storage_Pool_Ptr is available.
1792 (Make_Build_In_Place_Call_In_Object_Declaration): Do not add a
1793 pool actual unless RE_Root_Storage_Pool_Ptr is available.
1794 * sem_ch6.adb (Create_Extra_Formals): Add build-in-place pool
1795 formal only if RE_Root_Storage_Pool_Ptr is available.
1796
17972011-10-15 Matthew Heaney <heaney@adacore.com>
1798
1799 * a-cusyqu.ads, a-cbsyqu.ads, a-cuprqu.ads, a-cbprqu.ads (Queue
1800 type): Specify Priority aspect for protected type.
1801
b7539c3b
AC
18022011-10-14 Ed Schonberg <schonberg@adacore.com>
1803
1804 * exp_disp.adb (Check_Premature_Freezing): If an untagged type
1805 is a generic actual, it is a subtype of a type that was frozen
1806 by the instantiation, and even if not marked frozen it does not
1807 affect the construction of the dispatch table.
1808
18092011-10-14 Robert Dewar <dewar@adacore.com>
1810
1811 * make.adb, mlib-utl.adb, sem_util.adb, sem_ch4.adb: Minor code
1812 reformatting.
1813 * s-rident.ads: Add missing Compiler_Unit pragma.
1814
af89615f
AC
18152011-10-14 Gary Dismukes <dismukes@adacore.com>
1816
1817 * sem_res.adb: Minor reformatting.
1818
18192011-10-14 Hristian Kirtchev <kirtchev@adacore.com>
1820
1821 * exp_ch6.adb (Add_Task_Actuals_To_Build_In_Place_Call):
1822 Code and comment reformatting. Use BIP_Task_Master
1823 when creating a _master.
1824 (BIP_Formal_Suffix): Code reformatting. Correct the case for
1825 BIP_Task_Master.
1826 (Make_Build_In_Place_Call_In_Object_Declaration): Use
1827 BIP_Task_Master when creating a reference to the enclosing
1828 function's _master formal.
1829 (Move_Activation_Chain): Use BIP_Task_Master when creating a reference
1830 to the _master.
1831 * exp_ch6.ads: Change BIP_Master to BIP_Task_Master.
1832 (Needs_BIP_Finalization_Master): Alphabetized.
1833 * sem_ch6.adb (Create_Extra_Formals): Update the usage of
1834 BIP_Task_Master.
1835
18362011-10-14 Ed Schonberg <schonberg@adacore.com>
1837
1838 * par-ch6.adb (P_Return_Object_Declaration): In Ada 2012 mode,
1839 reject an aliased keyword on the object declaration of an extended
1840 return statement. In older versions of the language indicate
1841 that this is illegal in the standard.
1842
18432011-10-14 Pascal Obry <obry@adacore.com>
1844
1845 * sem_util.adb, sem_ch4.adb: Minor reformatting.
1846
18472011-10-14 Ed Schonberg <schonberg@adacore.com>
1848
1849 * sem_ch13.adb: Recognize properly procedure calls that are
1850 transformed into code statements.
1851
18522011-10-14 Vincent Celier <celier@adacore.com>
1853
1854 * projects.texi: Minor fix in project example.
1855
f2d10a02
AC
18562011-10-14 Ed Schonberg <schonberg@adacore.com>
1857
1858 * sem_util.adb: Return objects are aliased if their type is
1859 immutably limited as per AI05-0053.
1860
18612011-10-14 Gary Dismukes <dismukes@adacore.com>
1862
1863 * exp_ch4.adb (Expand_N_Op_And): Remove Short_Circuit_And_Or
1864 expansion code (moved to sem_res) (Expand_N_Op_Or): Remove
1865 Short_Circuit_And_Or expansion code (moved to sem_res).
1866 * sem_res.adb (Resolve_Logical_Op): Add code to rewrite Boolean
1867 "and" and "or" operators as short-circuit "and then" and "or
1868 else", when pragma Short_Circuit_And_Or is active.
1869
2fcc44fa
AC
18702011-10-13 Robert Dewar <dewar@adacore.com>
1871
1872 * sem_ch9.adb, sem_util.adb, sem_util.ads, exp_ch6.adb, sem_ch4.adb,
1873 sem_ch6.adb, exp_ch3.adb: Minor reformatting.
1874
18752011-10-13 Arnaud Charlet <charlet@adacore.com>
1876
1877 * Makefile.rtl (GNATRTL_NONTASKING_OBJS): Add a-ngcoar.o.
1878
18792011-10-13 Jerome Guitton <guitton@adacore.com>
1880
1881 * sysdep.c (__gnat_get_task_options): Re-enable VX_SPE_TASK on vThreads
1882
18832011-10-13 Eric Botcazou <ebotcazou@adacore.com>
1884
1885 * a-convec.ads (Cursor): Minor reformatting.
1886 * a-convec.adb (Next): Fix minor inconsistencies.
1887 (Previous): Likewise.
1888
9b62eb32
AC
18892011-10-13 Ed Schonberg <schonberg@adacore.com>
1890
1891 * sem_util.ads, sem_util.adb (Available_Full_View_Of_Component):
1892 New predicate to determine whether some operations on an array
1893 type are available when the full view of its component may differ
1894 from the view of the point of the array declaration.
1895 * sem_ch4.adb (Find_Equality_Types): Use
1896 Available_Full_View_Of_Component.
1897 * sem_type.adb (Valid_Boolean_Arg, Valid_Comparison_Arg): Ditto
1898
18992011-10-13 Ed Schonberg <schonberg@adacore.com>
1900
1901 * sem_ch9.adb: Analyze aspects while discriminants of protected
1902 type are visible.
1903
19042011-10-13 Geert Bosch <bosch@adacore.com>
1905
1906 * Makefile.rtl (GNATRTL_TASKING_OBJECTS): Add
1907 a-nlcoar.o, a-nllcar.o, a-nucoar.o and s-gearop.o, as these no
1908 longer depend on an external library.
1909 * gcc-interface/Makefile.in (GNATRTL_LINEARALGEBRA_OBJS): Remove
1910 a-nlcoar.o, a-nllcar.o, a-nucoar.o and s-gearop.o.
1911 Update dependencies.
1912 * gcc-interface/Make-lang.in: Update dependencies.
1913
1a36a0cd
AC
19142011-10-13 Cyrille Comar <comar@adacore.com>
1915
1916 * gnat_ugn.texi: Minor editing.
1917
19182011-10-13 Vincent Celier <celier@adacore.com>
1919
1920 * projects.texi: Add documentation on packages and attributes
1921 that are inherited from a project being extended into the
1922 extended project.
1923
19242011-10-13 Hristian Kirtchev <kirtchev@adacore.com>
1925
1926 * exp_ch3.adb (Build_Master): Rewritten.
1927 (Expand_N_Full_Type_Declaration): Reformat the declarative
1928 region. Update the call to Build_Master_Renaming.
1929 (Expand_Previous_Access_Type): Rewritten.
1930 * exp_ch6.adb (Add_Task_Actuals_To_Build_In_Place_Call):
1931 Add local constant Result_Subt and update related usage.
1932 (Expand_N_Extended_Return_Statement): Add local constant
1933 Result_Subt and update related usage.
1934 * exp_ch9.adb (Build_Activation_Chain): Rewritten to use the
1935 new context detection mechanism.
1936 (Build_Class_Wide_Master):
1937 Use Insert_Action to add the renaming into the tree.
1938 (Build_Master_Entity): Rewritten to use the new context detection
1939 mechanism.
1940 (Build_Master_Renaming): Add formal parameter Ins_Nod
1941 and related usage. Use Insert_Action to add the renaming into the
1942 tree.
1943 (Find_Enclosing_Context): New subsidiary routine. Rather
1944 than relying on enclosing scopes, this routine looks at the
1945 tree structure to figure out the proper context for a _master
1946 or a _chain. This approach eliminates the issues with transient
1947 scopes which have not been converted into blocks.
1948 * exp_ch9.ads (Build_Master_Entity): Change parameter profile
1949 to better reflect the new usage. Update the related comment.
1950 (Build_Master_Renaming): Add formal parameter Ins_Nod. Update
1951 the comment on usage.
1952 * sem_ch3.adb (Access_Definition): Update the calls to
1953 Build_Master_Entity and Build_Master_Renaming.
1954 * sem_ch6.adb (Create_Extra_Formals): Add local variable
1955 Full_Subt. Code reformatting.
1956 * sem_util.adb (Is_Iterator): Alphabetized.
1957 (Is_LHS): Alphabetized.
1958 (Is_Limited_Class_Wide_Type): New routine.
1959 * sem_util.ads (Is_Limited_Class_Wide_Type): New routine.
1960
a5917ffb
GB
19612011-10-13 Geert Bosch <bosch@adacore.com>
1962
1963 * a-ngrear.adb (Solve): Make generic and move to
1964 System.Generic_Array_Operations.
1965 * s-gearop.ads (Matrix_Vector_Solution, Matrix_Matrix_Solution):
1966 New generic solvers to compute a vector resp. matrix Y such
1967 that A * Y = X, approximately.
1968 * s-gearop.adb (Matrix_Vector_Solution, Matrix_Matrix_Solution):
1969 Implement using Forward_Eliminate and Back_Substitute
1970 * a-ngcoar.adb: Reimplement in pure Ada to remove dependencies
1971 on BLAS and LAPACK.
1972 * a-ngcoar.ads ("abs"): Fix return type to be real.
1973
574ec945
EB
19742011-10-13 Eric Botcazou <ebotcazou@adacore.com>
1975
1976 PR ada/50589
1977 * s-linux-alpha.ads: Do not "with" Interfaces.C.
1978 * s-linux-sparc.ads: Likewise.
1979
8668ea36
GB
19802011-10-13 Geert Bosch <bosch@adacore.com>
1981
1982 * s-gearop.ads (Forward_Eliminate): Add "abs" formal function
1983 returning a Real.
1984 * s-gearop.adb (Forward_Eliminate): Remove local "abs" function
1985 and use formal.
1986 * a-ngrear.adb (Forward_Eliminate): Adjust instantiation for
1987 new profile.
1988
edcf5983
GB
19892011-10-13 Geert Bosch <bosch@adacore.com>
1990
1991 * a-ngrear.adb, s-gearop.adb, s-gearop.ads (Sqrt): Make generic and
1992 move to System.Generic_Array_Operations.
1993
a4935dea
GB
19942011-10-13 Geert Bosch <bosch@adacore.com>
1995
1996 * a-ngrear.adb ("abs"): Adjust for modified L2_Norm generic
1997 * s-gearop.ads (L2_Norm): Change profile to be suitable for
1998 Complex_Vector
1999 * s-gearop.adb (L2_Norm): Reimplement using direct definition,
2000 not inner product
2001
3e7302c3
AC
20022011-10-13 Robert Dewar <dewar@adacore.com>
2003
2004 * exp_ch5.adb, sem_ch3.adb, impunit.adb, impunit.ads, sem_type.adb,
2005 prj-proc.adb, exp_ch9.adb, s-regpat.adb, sem_ch10.adb, sem_prag.adb,
2006 sem_ch12.adb, freeze.adb, sem_attr.adb, sem_attr.ads, gnatlink.adb,
2007 par-ch6.adb, exp_ch6.adb, sem_ch4.adb, sem_ch6.adb, sem_ch8.adb,
2008 par-util.adb, sem_ch13.adb, lib-xref.adb, g-trasym.adb, g-trasym.ads,
2009 exp_aggr.adb, s-taprop-posix.adb: Minor reformatting.
2010
20112011-10-13 Geert Bosch <bosch@adacore.com>
2012
2013 * s-gearop.adb: Minor comment additions.
2014
8417f4b2
AC
20152011-10-13 Fedor Rybin <frybin@adacore.com>
2016
2017 * gnat_ugn.texi: Add gnattest section.
2018
20192011-10-13 Ed Schonberg <schonberg@adacore.com>
2020
2021 * freeze.adb: Do not create body of renaming if declaration has
2022 errors.
2023
20242011-10-13 Olivier Hainque <hainque@adacore.com>
2025
2026 * init.c (__gnat_error_handler - vxworks case): Restrict sigtramp calls
2027 further, to the ppc+kernel case only.
2028
20292011-10-13 Hristian Kirtchev <kirtchev@adacore.com>
2030
2031 * exp_ch4.adb (Expand_N_Allocator): Comment reformatting.
2032 * exp_ch6.adb (Add_Unconstrained_Actuals_To_Build_In_Place_Call):
2033 Do not create a pool formal on .NET/JVM.
2034 (Expand_N_Extended_Return_Statement): Alphabetize local
2035 variables. Do not create a renaming of the build-in-place pool
2036 parameter on .NET/JVM. (Make_Build_In_Place_Call_In_Allocator):
2037 Add the user-defined pool only on non-VM targets.
2038 (Make_Build_In_Place_Call_In_Object_Declaration): Alphabetize
2039 local variables. Do not add a pool actual on .NET/JVM.
2040 * sem_ch6.adb: Add with and use clause for Targparm.
2041 (Create_Extra_Formals): Add build-in-place pool formal only on
2042 non-VM targets.
2043 * rtsfind.ads: Alphabetize entries.
2044
4674dd21
AC
20452011-10-13 Sergey Rybin <rybin@adacore.com>
2046
2047 * gnat_ugn.texi: Minor correction.
2048
20492011-10-13 Ed Schonberg <schonberg@adacore.com>
2050
2051 * sem_ch8.adb: Minor error message improvement.
2052
20532011-10-13 Robert Dewar <dewar@adacore.com>
2054
2055 * a-cbprqu.adb, a-ciorma.adb, exp_ch3.adb: Minor reformatting.
2056
95aeda79
GD
20572011-10-13 Gary Dismukes <dismukes@adacore.com>
2058
2059 * exp_ch5.adb (Expand_N_Loop_Statement): For the transformation
2060 of a for loop for an enumeration type with an enumeration rep
2061 clause, which involves moving the original loop parameter into
2062 a nested block, the loop parameter's entity must be removed from
2063 the entity list of the loop scope.
2064
200b7162
BD
20652011-10-13 Bob Duff <duff@adacore.com>
2066
2067 * exp_ch6.ads (BIP_Storage_Pool): New "extra implicit parameter"
2068 that gets passed in the same cases where BIP_Alloc_Form is passed
2069 (caller-unknown-size results). BIP_Storage_Pool is used when
2070 BIP_Alloc_Form = User_Storage_Pool. In that case, a pointer
2071 to the user-defined storage pool is passed at the call site,
2072 and this pool is used in callee to allocate the result.
2073 * exp_ch6.adb (Add_Unconstrained_Actuals_To_Build_In_Place_Call): New
2074 version of Add_Alloc_Form_Actual_To_Build_In_Place_Call. Passes
2075 the additional BIP_Storage_Pool actual.
2076 (Expand_N_Extended_Return_Statement): Allocate the function
2077 result using the user-defined storage pool, if BIP_Alloc_Form =
2078 User_Storage_Pool.
2079 * sem_ch6.adb: Add the "extra formal" for BIP_Storage_Pool.
2080 * exp_ch4.adb: Don't overwrite storage pool set by
2081 Expand_N_Extended_Return_Statement.
2082 * s-stopoo.ads, rtsfind.ads (Root_Storage_Pool_Ptr): New type,
2083 for use in build-in-place function calls within allocators
2084 where the access type has a user-defined storage pool.
2085
9f8d1e5c
AC
20862011-10-13 Sergey Rybin <rybin@adacore.com>
2087
2088 * gnat_ugn.texi, vms_data.ads: Add an option to control enumeration
2089 literal casing.
2090
20912011-10-13 Nicolas Roche <roche@adacore.com>
2092
be7552fc
EB
2093 * gnatlink.adb: Ensure that -mrtp is passed when runtime name ends
2094 with 'rtp'.
9f8d1e5c
AC
2095
20962011-10-13 Ed Schonberg <schonberg@adacore.com>
2097
be7552fc
EB
2098 * sem_prag.adb (Analyze_Pragma, case Unchecked_Union): Take into
2099 account that an unchecked union type can be limited.
9f8d1e5c
AC
2100
21012011-10-13 Olivier Hainque <hainque@adacore.com>
2102
2103 * init.c (__gnat_error_handler) <VxWorks version>: Add comments on
2104 the use of the signal trampoline for PPC in the sjlj case as well.
2105 Add legitimate casts, preventing compile time warnings on the
2106 (sighandler *) profile.
2107
21082011-10-13 Yannick Moy <moy@adacore.com>
2109
be7552fc
EB
2110 * sem_aggr.adb (Resolve_Aggr_Expr): Always perform semantic analysis
2111 in Alfa mode.
9f8d1e5c
AC
2112
21132011-10-13 Ed Schonberg <schonberg@adacore.com>
2114
2115 * sem_ch3.adb (OK_For_Limited_Init_In_05): Conditional and case
2116 expressions are legal limited return values if each one of their
2117 dependent expressions are legal.
2118
21192011-10-13 Ed Schonberg <schonberg@adacore.com>
2120
2121 * sem_ch6.adb (Analyze_Procedure_Call_Statement): In Ada 2012 mode,
2122 if the prefix of the call is a qualified expression, rewrite as
2123 a code statement.
2124 * sem_ch13.adb (Analyze_Code_Statement): In Ada 2012 mode, the
2125 code statement is legal if it is a rewriting of a procedure call.
2126
21272011-10-13 Ed Schonberg <schonberg@adacore.com>
2128
2129 * exp_aggr.adb (Flatten): If a component association has a box,
2130 assume that aggregate is not static.
2131 (Safe_Aggregate): If a component association in a non-limited
2132 aggregate has a box, assume that it cannot be expanded in place.
2133
21342011-10-13 Vincent Celier <celier@adacore.com>
2135
2136 * prj-conf.adb (Get_Or_Create_Configuration_File): Call
2137 Process_Project_Tree_Phase_1 with Packages_To_Check.
2138 (Process_Project_And_Apply_Config): Ditto
2139 * prj-part.ads, prj-part.adb, prj-pars.ads, prj-pars.adb (Parse):
2140 Remove default for argument Packages_To_Check.
2141 * prj-proc.adb (Recursive_Process): New argument
2142 Packages_To_Check.
2143 (Process): Ditto.
2144 (Process_Project_Tree_Phase_1): Ditto.
2145 (Recursive_Project.Process_Aggregated_Projects): Call
2146 Prj.Part.Parse and Process_Project_Tree_Phase_1 with
2147 Packages_To_Check.
2148 * prj-proc.ads (Process): New argument Packages_To_Check
2149 (Process_Project_Tree_Phase_1): Ditto
2150
46f8e1ac
AC
21512011-10-13 Arnaud Charlet <charlet@adacore.com>
2152
2153 * gcc-interface/Makefile.in: Fix typo.
2154
8097203f
AC
21552011-10-13 Ed Schonberg <schonberg@adacore.com>
2156
2157 * sem_ch12.adb (Analyze_Formal_{Floating_Type,
2158 Signed_Integer_Type, Decimal_Fixed_Point_Type, Discrete_Type}):
2159 Use sloc of defining identifier of farmal type declaration,
2160 as sloc of generated internal entity, to prevent misplaced
2161 references in ali.
2162
21632011-10-13 Ed Schonberg <schonberg@adacore.com>
2164
2165 * sem_intr.adb (Check_Intrinsic_Operator): Check that type
2166 is fully defined before checking that it is a numeric type.
2167
21682011-10-13 Ed Schonberg <schonberg@adacore.com>
2169
2170 * sem_aggr.adb (Resolve_Record_Aggregate): If a component
2171 association for component X has a box, then X is covered in the
2172 aggregate even if there is not default value for X in the type
2173 declaration, and X has to be default-initialized.
2174
21752011-10-13 Ed Schonberg <schonberg@adacore.com>
2176
be7552fc
EB
2177 * sem_attr.adb (Check_Enum_Image, Analyze_Attribute case 'Value): Mark
2178 literals as referenced only if reference is in current source unit.
8097203f
AC
2179
21802011-10-13 Matthew Heaney <heaney@adacore.com>
2181
2182 * a-csquin.ads (Enque, Dequeue): Mark interface operations as entries.
2183
21842011-10-13 Olivier Hainque <hainque@adacore.com>
2185
2186 * sigtramp.h: New file. Prototype and spec of the signal
2187 trampoline to be called by an established handler to provide
2188 dwarf call frame info before the real signal processing code.
2189 * sigtramp-ppcvxw.c: New file. Implementation of the signal
2190 trampoline for ppc-vxworks.
2191 * init.c (vxworks section): Use it for ppc.
2192
e192a2cd
AC
21932011-10-13 Thomas Quinot <quinot@adacore.com>
2194
2195 * par-ch2.adb, par.adb, par-util.adb, par-ch3.adb
2196 (Check_Future_Identifier): New subprogram,
2197 factors duplicated code from Par.Ch2.P_Identifier and
2198 Par.Ch3.P_Defining_Identifier.
2199
22002011-10-13 Thomas Quinot <quinot@adacore.com>
2201
2202 * s-taprop-posix.adb (Initialize): Always raise Storage_Error
2203 if we fail to initialize CV attributes or CV.
2204
22052011-10-13 Thomas Quinot <quinot@adacore.com>
2206
2207 * s-tasren.adb (Timed_Selective_Wait, case
2208 Accept_Alternative_Selected): Use Defer_Abort_Nestable, since
2209 we know abortion is already deferred.
2210
22112011-10-13 Hristian Kirtchev <kirtchev@adacore.com>
2212
2213 * exp_ch3.adb (Build_Class_Wide_Master): Moved to exp_ch9.
2214 (Build_Master_Renaming (function)): Removed.
2215 (Build_Master_Renaming (procedure)): Moved to exp_ch9.
2216 (Expand_Full_Type_Declaration): Alphabetize
2217 variables. Reformatting of code and comments. Rewrite the
2218 section on processing of anonymous access-to-task types in
2219 record components.
2220 * exp_ch3.ads (Build_Class_Wide_Master): Moved to exp_ch9.
2221 (Build_Master_Renaming): Moved to exp_ch9.
2222 * exp_ch9.adb (Build_Class_Wide_Master): Moved from exp_ch3.
2223 (Build_Master_Entity): Add formal parameter
2224 Use_Current. Reformatting of code and comments.
2225 (Build_Master_Renaming): Moved from exp_ch3.
2226 * exp_ch9.ads (Build_Class_Wide_Master): Moved from
2227 exp_ch3. Update comment on usage.
2228 (Build_Master_Entity):
2229 Add formal parameter Use_Current. Update comment on usage.
2230 (Build_Master_Renaming): Moved from exp_ch3.
2231 * sem_ch3.adb (Access_Definition): Remove redundant code to
2232 create a _master and a renaming.
2233
22342011-10-13 Ed Schonberg <schonberg@adacore.com>
2235
2236 * lib-xref.adb: Do no emit reference to overridden operation,
2237 if it is internally generated.
2238
22392011-10-13 Vincent Celier <celier@adacore.com>
2240
2241 * bindgen.adb: Remove any processing related to g-trasym
2242 * Makefile.rtl: Add g-trasym.o to GNATRTL_NONTASKING_OBJS
2243 * mlib-prj.adb: Remove any processing related to g-trasym.
2244
0cfaf83f
EB
22452011-10-12 Eric Botcazou <ebotcazou@adacore.com>
2246
2247 * sem_util.adb (Denotes_Same_Prefix): Fix fatal warning.
2248 * gcc-interface/Make-lang.in (WARN_ADAFLAGS): New.
2249 (ALL_ADAFLAGS): Include WARN_ADAFLAGS.
2250 (ADA_FLAGS_TO_PASS): Likewise.
2251 (COMMON_FLAGS_TO_PASS): New.
2252 (ADA_TOOLS_FLAGS_TO_PASS): Use COMMON_FLAGS_TO_PASS. In the regular
2253 native case, also use FLAGS_TO_PASS and ADA_FLAGS_TO_PASS.
2254 (gnatlib): Use COMMON_FLAGS_TO_PASS.
2255 (ada.install-common): Likewise.
2256 (install-gnatlib): Likewise.
2257 (install-gnatlib-obj): Likewise.
2258 (gnattools): Use ADA_TOOLS_FLAGS_TO_PASS for gnattools1 as well.
2259 (gnat-cross): Delete.
2260 (gnatboot): Likewise.
2261 (gnatboot2): Likewise.
2262 (gnatboot3): Likewise.
2263 (gnatstage1): Likewise.
2264 (gnatstage2): Likewise.
2265 * gcc-interface/Makefile.in (SOME_ADAFLAGS): Likewise.
2266 (MOST_ADAFLAGS): Likewise.
2267 (LOOSE_CFLAGS): Likewise.
2268 (gnat-cross): Likewise.
2269 (GNATLIBFLAGS): Add -W -Wall.
2270 (GNATLIBCFLAGS_FOR_C): Likewise.
2271 * gcc-interface/lang.opt: Remove C-specific warnings. Add doc lines.
2272 * gcc-interface/misc.c (gnat_handle_option): Remove obsolete cases.
2273
722356ce
EB
22742011-10-12 Eric Botcazou <ebotcazou@adacore.com>
2275
2276 * gcc-interface/trans.c (Attribute_to_gnu): Use remove_conversions.
2277 (push_range_check_info): Likewise.
2278 (gnat_to_gnu) <N_Code_Statement>: Likewise.
2279 * gcc-interface/utils2.c (build_unary_op) <INDIRECT_REF>: Likewise.
2280 (gnat_invariant_expr): Likewise.
2281 * gcc-interface/utils.c (compute_related_constant): Likewise.
2282 (max_size): Fix handling of SAVE_EXPR.
2283 (remove_conversions): Fix formatting.
2284
15bf7d19
EB
22852011-10-12 Eric Botcazou <ebotcazou@adacore.com>
2286
2287 * gcc-interface/ada-tree.h (DECL_LOOP_PARM_P): New flag.
2288 (DECL_INDUCTION_VAR): New macro.
2289 (SET_DECL_INDUCTION_VAR): Likewise.
2290 * gcc-interface/gigi.h (convert_to_index_type): Declare.
2291 (gnat_invariant_expr): Likewise.
2292 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: If this is a loop
2293 parameter, set DECL_LOOP_PARM_P on it.
2294 * gcc-interface/misc.c (gnat_print_decl) <VAR_DECL>: If DECL_LOOP_PARM_P
2295 is set, print DECL_INDUCTION_VAR instead of DECL_RENAMED_OBJECT.
2296 * gcc-interface/trans.c (gnu_loop_label_stack): Delete.
2297 (struct range_check_info_d): New type.
2298 (struct loop_info_d): Likewise.
2299 (gnu_loop_stack): New stack.
2300 (Identifier_to_gnu): Set TREE_READONLY flag on the first dereference
2301 built for a by-double-ref read-only parameter. If DECL_LOOP_PARM_P
2302 is set, do not test DECL_RENAMED_OBJECT.
2303 (push_range_check_info): New function.
2304 (Loop_Statement_to_gnu): Push a new struct loop_info_d instead of just
2305 the label. Reference the label and the iteration variable from it.
2306 Build the special induction variable in the unsigned version of the
2307 size type, if it is larger than the base type. And attach it to the
2308 iteration variable if the latter isn't by-ref. In the iteration scheme
2309 case, initialize the invariant conditions in front of the loop if
2310 deemed profitable. Use gnu_loop_stack.
2311 (gnat_to_gnu) <N_Exit_Statement>: Use gnu_loop_stack.
2312 <N_Raise_Constraint_Error>: Always process the reason. In the range
2313 check and related cases, and if loop unswitching is enabled, compute
2314 invariant conditions and push this information onto the stack.
2315 Do not translate again the condition if it has been already translated.
2316 * gcc-interface/utils.c (record_global_renaming_pointer): Assert that
2317 DECL_LOOP_PARM_P isn't set.
2318 (convert_to_index_type): New function.
2319 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Use it in order
2320 to convert the index from the base index type to sizetype.
2321 (gnat_invariant_expr): New function.
2322
e79983f4
MM
23232011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
2324
2325 * gcc-interface/utils.c (def_builtin_1): Delete old interface with
2326 two parallel arrays to hold standard builtin declarations, and
2327 replace it with a function based interface that can support
15bf7d19 2328 creating builtins on the fly in the future.
e79983f4
MM
2329 * gcc-interface/trans.c (Exception_Handler_to_gnu_zcx): Ditto.
2330 (gnat_to_gnu): Ditto.
2331
228ee426
EB
23322011-10-07 Eric Botcazou <ebotcazou@adacore.com>
2333
2334 PR lto/50492
2335 * gcc-interface/gigi.h (gnat_pushdecl): Adjust comment.
2336 * gcc-interface/utils.c (global_context): New variable.
2337 (gnat_pushdecl): Initialize it and set it as the DECL_CONTEXT of DECLs
2338 that are either public external or at top level. Use "No" macro.
2339 (end_subprog_body): Call decl_function_context.
2340 (rest_of_subprog_body_compilation): Likewise.
2341
71196d4e
EB
23422011-10-07 Eric Botcazou <ebotcazou@adacore.com>
2343
2344 * gcc-interface/gigi.h (gnat_useless_type_conversion): Declare.
2345 (rest_of_subprog_body_compilation): Likewise.
2346 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Variable>: For renaming,
2347 test for useless conversions by means of gnat_useless_type_conversion.
2348 * gcc-interface/trans.c: Include bitmap.h and cgraph.h.
2349 (language_function): Add named_ret_val and other_ret_val.
2350 (f_named_ret_val): New macro.
2351 (f_other_ret_val): Likewise.
2352 (gigi): Call rest_of_subprog_body_compilation.
2353 (struct nrv_data): New structure.
2354 (is_nrv_p): New predicate.
2355 (prune_nrv_r): New helper function.
2356 (prune_nrv_in_block): New function.
2357 (finalize_nrv_r): New helper function.
2358 (finalize_nrv): New function.
2359 (return_value_ok_for_nrv_p): New predicate.
2360 (build_return_expr): If optimization is enabled, record candidates for
2361 the Named Return Value optimization.
2362 (build_function_stub): Call rest_of_subprog_body_compilation.
2363 (Subprogram_Body_to_gnu): If optimization is enabled and there are
2364 candidates, finalize the Named Return Value optimization.
2365 Call rest_of_subprog_body_compilation.
2366 (call_to_gnu): At the end, if a return value is needed, simplify the
2367 result before wrapping it up in a COMPOUND_EXPR.
2368 * gcc-interface/utils.c (end_subprog_body): Split into...
2369 (rest_of_subprog_body_compilation): ...this. New function.
2370 (gnat_useless_type_conversion): Likewise.
2371
885c4871
AC
23722011-10-06 Thomas Quinot <quinot@adacore.com>
2373
2374 * einfo.ads, exp_attr.adb, exp_ch3.adb, exp_ch4.adb, exp_ch7.adb,
2375 exp_ch9.adb, exp_ch9.ads, exp_strm.adb, exp_util.adb, freeze.adb,
2376 g-debpoo.ads, opt.ads, par-ch12.adb, par-ch2.adb, par-ch3.adb,
2377 par-ch5.adb, par-ch6.adb, sem_aggr.adb, sem_attr.adb, sem_cat.adb,
2378 sem_ch10.adb, sem_ch12.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
2379 sem_ch6.adb, sem_intr.adb, sem_res.ads, sem_type.adb, sem_util.adb,
2380 s-regpat.adb, s-tpopde-vms.ads: Minor reformatting.
2381 * s-osinte-freebsd.ads: Fix for tasking failures on FreeBSD.
2382
23832011-10-06 Ed Schonberg <schonberg@adacore.com>
2384
2385 * a-cihase.adb, a-ciorma.adb: Avoid accessibility checks in container
2386 references.
2387
23882011-10-06 Matthew Heaney <heaney@adacore.com>
2389
2390 * a-cuprqu.ads, a-cuprqu.adb, a-cbprqu.ads, a-cbprqu.adb
2391 (Dequeue_Only_High_Priority): Protected procedure now implemented.
2392
23932011-10-06 Vincent Celier <celier@adacore.com>
2394
2395 * g-trasym.adb: Replace old implementation with the default
2396 implementation that returns list of addresses as "0x...".
2397 * g-trasym.ads: Update the list of platforms with the full
2398 capability. Indicate that there is a default implementation
2399 for other platforms.
2400 * g-trasym-unimplemented.ads, g-trasym-unimplemented.adb: Remove.
2401 * gcc-interface/Makefile.in: Remove g-trasym-unimplemented, as there
2402 is now a default implementation for all platforms without the full
2403 capability.
2404
ce72a9a3
AC
24052011-10-06 Robert Dewar <dewar@adacore.com>
2406
2407 * a-ciorse.adb, a-cihase.adb, a-cihase.ads, a-coorse.adb,
2408 a-cborse.adb, a-comutr.adb, a-ciorma.adb, a-cbmutr.adb,
2409 a-cbmutr.ads, a-cbhase.adb, a-cbhase.ads: Minor reformatting and code
2410 reorganization (use conditional expressions).
2411
24122011-10-06 Robert Dewar <dewar@adacore.com>
2413
2414 * sem_res.adb (Resolve_Arithmetic_Op): Fix bad warning for
2415 floating divide by zero.
2416
24172011-10-06 Ed Schonberg <schonberg@adacore.com>
2418
2419 * sem_ch6.adb: Limited interfaces that are not immutably limited
2420 are OK in return statements.
2421
a912d7d9
IS
24222011-09-30 Iain Sandoe <iains@gcc.gnu.org>
2423
2424 * gcc-interface/Makefile.in (Darwin): Partial reversion of previous
2425 change to powerpc section.
2426
39ffb1f9
IS
24272011-09-29 Iain Sandoe <iains@gcc.gnu.org>
2428
2429 * gcc-interface/Makefile.in (Darwin): Factor LIBGNAT_TARGET_PAIRS
2430 across the port.
2431
ffb35bbf
ES
24322011-09-27 Ed Schonberg <schonberg@adacore.com>
2433
2434 * a-cbhase.adb, a-cbhase.ads, a-cborse.adb, a-cborse.ads,
2435 a-cihase.adb, a-cihase.ads, a-ciorse.adb, a-ciorse.ads,
2436 a-coorse.adb, a-coorse.ads: Add iterator machinery to bounded sets and
2437 indefinite sets.
2438 * a-coorma.ads: Minor reformmating.
2439 * einfo.ads: Improve the comment describing the
2440 Directly_Designated_Type function.
2441 * a-ciorma.adb, a-ciorma.ads: Add iterator machinery to indefinite
2442 ordered maps.
2443 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
2444 dependencies.
2445
da124b6a
AC
24462011-09-27 Robert Dewar <dewar@adacore.com>
2447
2448 * a-comutr.ads: Minor reformatting.
2449
24502011-09-27 Ed Schonberg <schonberg@adacore.com>
2451
2452 * a-cimutr.adb, a-cimutr.ads, a-cbmutr.adb, a-cbmutr.ads: Add children
2453 iterators to multiway trees.
2454
24552011-09-27 Yannick Moy <moy@adacore.com>
2456
2457 * debug.adb (d.D): New option for strict Alfa mode.
2458 * opt.ads (Strict_Alfa_Mode): New flag to interpret compiler
2459 permissions as strictly as possible.
2460 * sem_ch3.adb (Signed_Integer_Type_Declaration): In non-strict
2461 Alfa mode, now, interpret ranges of base types like GNAT does; in
2462 strict mode, simply change the range of the implicit base Itype.
2463 * gnat1drv.adb: Update comments. Set Strict_Alfa_Mode.
2464
706a4067
AC
24652011-09-27 Robert Dewar <dewar@adacore.com>
2466
2467 * exp_ch9.adb: Minor comment fixes.
2468
24692011-09-27 Ed Schonberg <schonberg@adacore.com>
2470
2471 * a-comutr.adb, a-comutr.ads: Add children iterators on multiway
2472 trees.
2473
05c1e7d2
AC
24742011-09-27 Eric Botcazou <ebotcazou@adacore.com>
2475
2476 * checks.adb (Apply_Scalar_Range_Check): Use Designated_Type
2477 instead of Directly_Designated_Type in the indirect array case.
2478
24792011-09-27 Robert Dewar <dewar@adacore.com>
2480
2481 * exp_util.adb, exp_aggr.adb: Minor reformatting.
2482
65e78a74
AC
24832011-09-27 Ed Schonberg <schonberg@adacore.com>
2484
2485 * sinfo.ads, par-ch3.adb: Minor comment update: aspect specification
2486 on subtype declarations.
2487 * exp_aggr.adb: Minor comment update.
2488
24892011-09-27 Eric Botcazou <ebotcazou@adacore.com>
2490
2491 * exp_util.adb (Safe_Prefixed_Reference): Remove always-false
2492 test in the N_Explicit_Dereference case. Fold double logical
2493 negation in the special loop case and conditionalize it on
2494 Variable_Ref being true.
2495
24962011-09-27 Ed Schonberg <schonberg@adacore.com>
2497
2498 * sem_ch4.adb (Analyze_Selected_Component): If the prefix is a
2499 single protected object and the selector is a discriminant or an
2500 entry family, this is a non-overloaded candidate interpretation,
2501 and possible primitive operations of the type must not be
2502 examined.
2503
25042011-09-27 Arnaud Charlet <charlet@adacore.com>
2505
2506 * s-taspri-posix-noaltstack.ads (Lock): Mark fields aliased.
2507
6f5add73
AC
25082011-09-27 Pascal Obry <obry@adacore.com>
2509
2510 * s-osinte-hpux.ads, s-osinte-aix.ads, s-osinte-solaris-posix.ads,
2511 s-osinte-irix.ads, s-osinte-darwin.ads, s-osinte-freebsd.ads:
2512 Add dummy definitions for pthread_rwlock_t
2513 and pthread_rwlockattr_t on all POSIX platforms.
2514 * s-taprop-irix.adb, s-taprop-posix.adb (Initialize_Lock): Fix lock
2515 reference.
2516 (Finalize_Lock): Likewise.
2517 (Write_Lock): Likewise.
2518 (Unlock): Likewise.
2519
25202011-09-27 Tristan Gingold <gingold@adacore.com>
2521
2522 * s-tassta.adb (Task_Wrapper): Increase Guard_Page_Size value for
2523 windows 64.
2524
64a63cd5
PO
25252011-09-27 Pascal Obry <obry@adacore.com>
2526
2527 * s-osinte-hpux.ads, s-taprop-vxworks.adb, s-taspri-vxworks.ads,
2528 s-taprop-tru64.adb, s-osinte-aix.ads, s-taspri-posix-noaltstack.ads,
2529 s-taspri-mingw.ads, s-taprop-vms.adb, s-tpoben.adb, s-tpoben.ads,
2530 s-taprop-mingw.adb, s-taprob.adb, s-taprob.ads,
2531 s-osinte-solaris-posix.ads, s-taprop-solaris.adb, s-taspri-solaris.ads,
2532 s-osinte-irix.ads, s-taprop-irix.adb, s-osinte-darwin.ads,
2533 s-taspri-dummy.ads, s-taspri-posix.ads, s-taprop.ads,
2534 s-taspri-vms.ads, s-osinte-freebsd.ads, s-taprop-hpux-dce.adb,
2535 s-taspri-hpux-dce.ads, s-taspri-tru64.ads, s-taprop-dummy.adb,
2536 s-taprop-posix.adb: Revert previous changes.
2537 (Lock): Now a record containing the two possible lock
2538 (mutex and read/write) defined in OS_Interface.
2539 * s-taprop-linux.adb (Finalize_Protection): Use r/w lock for
2540 'R' locking policy.
2541 (Initialize_Protection): Likewise.
2542 (Lock): Likewise.
2543 (Lock_Read_Only): Likewise.
2544 (Unlock): Likewise.
2545
f672a756
AC
25462011-09-27 Pascal Obry <obry@adacore.com>
2547
2548 * s-taspri-posix-noaltstack.ads (RW_Lock): This type is now defined as
2549 OS_Interface.pthread_rwlock_t.
2550
25512011-09-27 Robert Dewar <dewar@adacore.com>
2552
2553 * exp_ch9.adb, a-cimutr.adb, a-cimutr.ads, gnat1drv.adb, a-comutr.adb,
2554 a-comutr.ads, exp_dist.adb, a-cbmutr.adb, a-cbmutr.ads,
2555 sem_ch5.adb, sem_util.adb: Minor reformatting.
2556
7a44cb69
PO
25572011-09-27 Pascal Obry <obry@adacore.com>
2558
2559 * s-taprop.ads (Initialize_Lock)[RW_Lock]: New spec for r/w lock.
2560 (Finalize_Lock)[RW_Lock]: Likewise.
2561 (Write_Lock)[RW_Lock]: Likewise.
2562 (Unlock)[RW_Lock]: Likewise.
2563 (Read_Lock): Define L as RW_Lock (instead of Lock).
2564 * s-taprop-linux.adb (Initialize_Lock)[RW_Lock]: New
2565 routine for r/w lock.
2566 (Finalize_Lock)[RW_Lock]: Likewise.
2567 (Write_Lock)[RW_Lock]: Likewise.
2568 (Unlock)[RW_Lock]: Likewise.
2569 (Read_Lock): Define L as RW_Lock (instead of Lock).
2570
2571 * s-taprop-vxworks.adb, s-taprop-tru64.adb, s-taprop-vms.adb,
2572 s-taprop-mingw.adb, s-taprop-solaris.adb, s-taprop-irix.adb,
2573 s-taprop-hpux-dce.adb, s-taprop-dummy.adb, s-taprop-posix.adb
2574 (Initialize_Lock)[RW_Lock]: Same implementation as corresponding
2575 routine for standard lock.
2576 (Finalize_Lock)[RW_Lock]: Likewise.
2577 (Write_Lock)[RW_Lock]: Likewise.
2578 (Unlock)[RW_Lock]: Likewise.
2579 (Read_Lock): Define L as RW_Lock (instead of Lock).
2580 * s-taprob.ads, s-tpoben.ads (Protection): Add RWL (RW_Lock)
2581 in the record definition.
2582 * s-taprob.adb, s-taproben.adb (Finalize_Protection): Use r/w
2583 lock for 'R' locking policy.
2584 (Initialize_Protection): Likewise.
2585 (Lock): Likewise.
2586 (Lock_Read_Only): Likewise.
2587 (Unlock): Likewise.
2588 * s-taspri-posix.ads (RW_Lock): New type defined as
2589 OS_Interface.pthread_rwlock_t.
2590
2591 * s-taspri-vxworks.ads, s-taspri-posix-noaltstack.ads,
2592 s-taspri-mingw.ads, s-taspri-solaris.ads, s-taspri-dummy.ads,
2593 s-taspri-posix.ads, s-taspri-vms.ads, s-taspri-hpux-dce.ads,
2594 s-taspri-tru64.ads (RW_Lock): New type defined as alias to Lock.
2595
4c173b50
PO
25962011-09-27 Pascal Obry <obry@adacore.com>
2597
2598 * exp_ch9.adb, s-taspri-posix.ads: Minor reformatting.
2599
26002011-09-27 Pascal Obry <obry@adacore.com>
2601
2602 * s-osinte-aix.ads, s-osinte-darwin.ads, s-osinte-freebsd.ads,
2603 s-osinte-hpux.ads, s-osinte-irix.ads,
2604 s-osinte-solaris-posix.ads (pthread_rwlock_t): New definition alias of
2605 pthread_mutex_t.
2606 (pthread_rwlockattr_t): New definition alias of pthread_mutexattr_t.
2607 * s-osinte-linux.ads (pthread_rwlock_t, pthread_rwlockattr_t,
2608 pthread_rwlockattr_init, pthread_rwlockattr_destroy,
2609 pthread_rwlockattr_setkind_np, pthread_rwlock_init,
2610 pthread_rwlock_destroy, pthread_rwlock_rdlock,
2611 pthread_rwlock_wrlock, pthread_rwlock_unlock): New.
2612
343250a6
PO
26132011-09-27 Pascal Obry <obry@adacore.com>
2614
2615 * rtsfind.ads: Add RE_Lock_Read_Only into rtsfind circuitry.
2616 (RE_Id): Add RE_Lock_Read_Only.
2617 (RE_Unit_Table): Likewise.
2618 * sem_prag.adb (Process_Convention): Change Pragma_Locking_Policy
2619 to lift restriction on first character. Handle now the
2620 Name_Concurrent_Readers_Locking where policy character is set to
2621 'R'.
2622 * snames.ads-tmpl (Name_Concurrent_Readers_Locking): New
2623 constant.
2624 * exp_ch9.adb (Build_Protected_Subprogram_Body): Generate a
2625 read only lock for function in protected object.
2626 * s-taprob.ads (Lock_Read_Only): Remove obsolete comment as
2627 this routine is now used.
2628
2d0dd51a
EB
26292011-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2630
2631 * s-atocou-x86.adb (Decrement): Use %;.
2632 (Increment): Likewise.
2633
bdbebf66
EB
26342011-09-26 Eric Botcazou <ebotcazou@adacore.com>
2635
2636 * gcc-interface/utils2.c (build_allocator): Set TREE_THIS_NOTRAP on the
2637 dereference of the pointer to the storage area. Remove useless type
2638 conversions and factor out common code.
2639
1aa291f7
EB
26402011-09-26 Eric Botcazou <ebotcazou@adacore.com>
2641
2642 * gcc-interface/utils.c (maybe_unconstrained_array): Declare TYPE local
2643 variable and use it throughout.
2644 <UNCONSTRAINED_ARRAY_TYPE>: Add 'break' at the end.
2645 <RECORD_TYPE>: Do not unconditionally convert to the unpadded type as a
2646 first step. Also convert to the unpadded type as a last step.
2647
7d76717d
EB
26482011-09-26 Eric Botcazou <ebotcazou@adacore.com>
2649
2650 * gcc-interface/gigi.h (create_subprog_decl): Replace TREE_CHAIN with
2651 DECL_CHAIN in comment.
2652 * gcc-interface/trans.c (gigi): Likewise.
2653 (Attribute_to_gnu): Likewise.
2654 (build_function_stub): Likewise.
2655 (gnat_to_gnu): Likewise.
2656 * gcc-interface/utils.c (create_subprog_decl): Likewise.
2657 (convert_vms_descriptor64): Likewise.
2658 (convert_vms_descriptor32): Likewise.
2659
42acad07
EB
26602011-09-26 Eric Botcazou <ebotcazou@adacore.com>
2661
2662 * gcc-interface/trans.c (assoc_to_constructor): Minor tweaks.
2663 * gcc-interface/utils2.c (build_simple_component_ref): Fix formatting
2664 issues. Use COMPLETE_TYPE_P in assertion. Also set TREE_READONLY if
2665 the type of the record is TYPE_READONLY.
2666
a1d72281
EB
26672011-09-26 Eric Botcazou <ebotcazou@adacore.com>
2668 Robert Dewar <dewar@adacore.com>
2669
2670 * sem_ch6.adb (Set_Formal_Mode): Set Can_Never_Be_Null on an IN or IN
2671 OUT formal parameter which is of an null-exclusion access subtype.
2672
a1c7d797
EB
26732011-09-26 Eric Botcazou <ebotcazou@adacore.com>
2674
2675 * gcc-interface/ada-tree.h (DECL_CAN_NEVER_BE_NULL_P): New macro.
2676 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Set the flag.
2677 (gnat_to_gnu_param): Likewise.
2678 * gcc-interface/utils.c (convert) <UNCONSTRAINED_ARRAY_REF>: Invoke
2679 maybe_unconstrained_array instead of doing the work manually.
2680 (maybe_unconstrained_array): Propagate the TREE_THIS_NOTRAP flag.
2681 * gcc-interface/utils2.c (build_unary_op) <INDIRECT_REF>: If operand
2682 is a DECL with the flag, set TREE_THIS_NOTRAP on the reference.
2683 (gnat_stabilize_reference_1): Propagate the TREE_THIS_NOTRAP flag.
2684 (gnat_stabilize_reference): Likewise.
2685
50179d58
EB
26862011-09-26 Eric Botcazou <ebotcazou@adacore.com>
2687
2688 * gcc-interface/ada-tree.h (TYPE_NULL_BOUNDS): New macro.
2689 (SET_TYPE_NULL_BOUNDS): Likewise.
2690 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Set again
2691 TREE_THIS_NOTRAP on the INDIRECT_REF node built for the template.
2692 * gcc-interface/trans.c (Identifier_to_gnu): Return initializers of fat
2693 pointer types.
2694 * gcc-interface/utils.c (create_var_decl_1): If the object is external,
2695 check that the initializer is a valid constant expression for use in
2696 initializing a static variable. Add missing guard.
2697 (update_pointer_to): Adjust TYPE_NULL_BOUNDS if set.
2698 (convert_to_fat_pointer): In the null fat pointer case, build a valid
2699 pointer for the bounds.
2700 * gcc-interface/utils2.c (compare_fat_pointers): New function.
2701 (build_binary_op) <EQ_EXPR>: Call it to compare fat pointers.
2702
ad1d36ba
EB
27032011-09-25 Eric Botcazou <ebotcazou@adacore.com>
2704
2705 * gcc-interface/ada-tree.h (TREE_THIS_NOTRAP): Redefine.
2706 * gcc-interface/trans.c (Identifier_to_gnu): Factor out common code in
2707 the by-ref case. Do not set TREE_READONLY on a renamed object. Set
2708 TREE_THIS_NOTRAP on UNCONSTRAINED_ARRAY_REF nodes.
2709 (Attribute_to_gnu) <Attr_Length>: Expand the use of the parameter cache
2710 to the indirect case.
2711 * gcc-interface/utils.c (convert) <UNCONSTRAINED_ARRAY_REF>: Preserve
2712 the TREE_THIS_NOTRAP flag.
2713
6162cec0
EB
27142011-09-25 Eric Botcazou <ebotcazou@adacore.com>
2715
2716 * gcc-interface/trans.c (Loop_Statement_to_gnu): In the case of an
2717 iteration scheme, always generate the do-while form if optimization
2718 is enabled. Use more straightforward test at the end.
2719
dee12fcd
EB
27202011-09-25 Eric Botcazou <ebotcazou@adacore.com>
2721
2722 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Subtype>: Use
2723 XNEW instead of xmalloc. Do not build useless pointer type.
2724 <E_Anonymous_Access_Subprogram_Type>: Use XNEW instead of xmalloc.
2725 * gcc-interface/trans.c (gnat_to_gnu) <N_Raise_Constraint_Error>: Tidy.
2726 * gcc-interface/utils2.c (build_unary_op): Remove local variable.
2727
dea976c4
EB
27282011-09-25 Eric Botcazou <ebotcazou@adacore.com>
2729
2730 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Do not promote
2731 the alignment if this doesn't prevent BLKmode access to the object.
2732
655ae828
IS
27332011-09-24 Iain Sandoe <iains@gcc.gnu.org>
2734
2735 * gcc-interface/Makefile.in (darwin): Do not issue the
2736 '-flat_namespace' linker flag during Ada build.
2737 * mlib-tgt-specific-darwin.adb: Remove '-flat_namespace' flag from the
2738 default shared library options.
2739
0e871c15
AO
27402011-09-19 Alexandre Oliva <aoliva@redhat.com>
2741
2742 * gcc-interface/decl.c (annotate_value): Look up expression for
2743 insertion in the cache at the end.
2744
1e6a52b4
AC
27452011-09-19 Arnaud Charlet <charlet@adacore.com>
2746
2747 * gcc-interface/Make-lang.in: Update dependencies.
2748
a3068ca6
AC
27492011-09-19 Steve Baird <baird@adacore.com>
2750
2751 * snames.ads-tmpl: Move declaration of Name_Annotate into range of
2752 configuration pragma names so that Is_Configuration_Pragma_Name
2753 will return True for Name_Annotate. Make corresponding change in
2754 Pragma_Id enumeration type. This is needed to allow an Annotate
2755 pragma to occur in a configuration pragma file (typically,
2756 a gnat.adc file).
2757 * gnat_ugn.texi: Add Annotate to the list of configuration pragmas.
2758 * gnat_rm.texi: Note that pragma Annotate may be used as a
2759 configuration pragma.
2760
27612011-09-19 Ed Schonberg <schonberg@adacore.com>
2762
2763 * a-cbmutr.adb, a-cbmutr.ads, a-cimutr.adb, a-cimutr.ads,
2764 a-comutr.adb, a-comutr.ads: Add iterator machinery for multiway trees.
2765
27662011-09-19 Yannick Moy <moy@adacore.com>
2767
2768 * exp_alfa.adb, exp_alfa.ads (Expand_Alfa_N_In): New function
2769 for expansion of set membership.
2770 (Expand_Alfa): Call expansion for N_In and N_Not_In nodes.
2771 * exp_ch4.adb, exp_ch4.ads (Expand_Set_Membership): Make procedure
2772 visible for use in Alfa expansion.
2773 * sem_ch5.adb (Analyze_Iterator_Specification): Introduce loop
2774 variable in Alfa mode.
2775
27762011-09-19 Thomas Quinot <quinot@adacore.com>
2777
2778 * s-osinte-darwin.ads: Change SIGADAABRT on Darwin to SIGABRT.
2779
27802011-09-19 Thomas Quinot <quinot@adacore.com>
2781
2782 * exp_ch9.adb: Minor reformatting.
2783
27842011-09-19 Hristian Kirtchev <kirtchev@adacore.com>
2785
2786 * freeze.adb (Build_Renamed_Body): Generic subprograms
2787 instantiations cannot be poperly inlined by the compiler, do
2788 not set the Body_To_Inline attribute in such cases.
2789 * sem_ch12.adb (Analyze_Subprogram_Instantiation): Inherit all
2790 inlining-related flags from the generic subprogram declaration.
2791
27922011-09-19 Thomas Quinot <quinot@adacore.com>
2793
2794 * exp_dist.adb, rtsfind.ads, sem_util.adb, sem_util.ads
2795 (Build_Stub_Type): Remove, instead copy components from
2796 System.Partition_Interface.RACW_Stub_Type.
2797 (RPC_Receiver_Decl): Remainder of code from old Build_Stub_Type routine.
2798 (Copy_Component_List): New subprogram.
2799
28002011-09-19 Yannick Moy <moy@adacore.com>
2801
2802 * lib-xref.adb (Generate_Reference): Ignore references to
2803 constants in Standard.
2804
e7fceebc
AC
28052011-09-19 Robert Dewar <dewar@adacore.com>
2806
2807 * err_vars.ads, errout.ads: Minor reformatting.
2808
28092011-09-19 Robert Dewar <dewar@adacore.com>
2810
2811 * aspects.ads (Impl_Defined_Aspects): New array
2812 * lib-writ.adb (No_Dependences): New name for No_Dependence
2813 * restrict.adb (No_Dependences): New name for No_Dependence
2814 (Check_Restriction_No_Specification_Of_Aspect): New
2815 procedure.
2816 (Set_Restriction_No_Specification_Of_Aspect): New procedure
2817 (Restricted_Profile_Result): New variable
2818 (No_Specification_Of_Aspects): New variable
2819 (No_Specification_Of_Aspect_Warning): New variable
2820 * restrict.ads (No_Dependences): New name for No_Dependence
2821 (Check_Restriction_No_Specification_Of_Aspect): New procedure
2822 (Set_Restriction_No_Specification_Of_Aspect): New procedure
2823 * s-rident.ads: Add restriction
2824 No_Implementation_Aspect_Specifications, this is also added to
2825 the No_Implementation_Extensions profile.
2826 * sem_ch13.adb (Analyze_Aspect_Specifications): Check
2827 No_Implementation_Defined_Aspects
2828 (Analyze_Aspect_Specifications): Check No_Specification_Of_Aspect
2829 * sem_prag.adb (Analyze_Aspect_Specifications): Check
2830 No_Implementation_Aspects
2831 (Analyze_Aspect_Specifications): Check No_Specification_Of_Aspect
2832 * snames.ads-tmpl (Name_No_Specification_Of_Aspect): New name
2833
28342011-09-19 Yannick Moy <moy@adacore.com>
2835
2836 * lib-xref.adb (Generate_Reference): Take into account multiple
2837 renamings for Alfa refs.
2838
28392011-09-19 Thomas Quinot <quinot@adacore.com>
2840
2841 * g-socthi-mingw.adb: Minor reformatting.
2842
28432011-09-19 Yannick Moy <moy@adacore.com>
2844
2845 * gnat1drv.adb (Adjust_Global_Switches): Set tagged type
2846 expansion to False in mode Alfa
2847
28482011-09-19 Pascal Obry <obry@adacore.com>
2849
2850 * mingw32.h: Remove obsolete code needed for old versions
2851 of MingW.
2852
e5a163fc
RD
28532011-09-19 Robert Dewar <dewar@adacore.com>
2854
2855 * errout.ads: Minor reformatting.
2856
6d7e5c54
AC
28572011-09-19 Ed Schonberg <schonberg@adacore.com>
2858
2859 * sem_ch6.adb (Analyze_Expression_Function): When the expression
2860 function is transformed into a declaration and a body, insert
2861 body at the end of the declarative part, to prevent premature
2862 freeze actions, and preserve original specification in the
2863 subprogram declaration.
2864
28652011-09-19 Vincent Celier <celier@adacore.com>
2866
2867 * projects.texi: Minor editing.
2868
99ba07a3
AC
28692011-09-19 Robert Dewar <dewar@adacore.com>
2870
2871 * sem_aggr.adb, lib-writ.ads, s-restri.ads, sem_ch6.adb,
2872 exp_aggr.adb: Minor reformatting.
2873
28742011-09-19 Yannick Moy <moy@adacore.com>
2875
2876 * lib-xref.adb (Generate_Reference): Change entity referenced
2877 to underlying object if any, or else reference to the HEAP.
2878
41781043
AC
28792011-09-15 Arnaud Charlet <charlet@adacore.com>
2880
2881 * gcc-interface/Make-lang.in: Update dependencies.
2882
804ff4c3
AC
28832011-09-15 Robert Dewar <dewar@adacore.com>
2884
2885 * tree_io.ads: Minor reformatting.
2886 * a-intnam.ads: Fix bad header.
2887
28882011-09-15 Thomas Quinot <quinot@adacore.com>
2889
2890 * a-exexpr-gcc.adb: Minor reformatting.
2891
28922011-09-15 Yannick Moy <moy@adacore.com>
2893
2894 * sem_ch6.adb: Propagate information that an expression function comes
2895 from source (otherwise references to this entity are not stored).
2896
0b5b2bbc
AC
28972011-09-15 Robert Dewar <dewar@adacore.com>
2898
2899 * a-cdlili.adb, a-coinve.adb, a-stzunb-shared.ads, a-suezst.adb,
2900 a-suenco.adb, a-stwiun-shared.ads, a-cobove.adb, a-convec.adb,
2901 a-btgbso.adb, a-cbdlli.adb, a-suewst.adb: Minor reformatting.
2902
29032011-09-15 Ed Schonberg <schonberg@adacore.com>
2904
2905 * sem_ch6.adb (Analyze_Expression_Function): Code cleanup:
2906 if the expression function is not a completion, create a
2907 new specification for the generated declaration, and keep the
2908 original specification in the generated body. Shorter code also
2909 ensures that proper warnings are generated for unused formals
2910 in all cases.
2911
29122011-09-15 Sergey Rybin <rybin@adacore.com>
2913
2914 * tree_io.ads: Update ASIS_Version_Number because of the changes
2915 in the tree structures for expression functions.
2916
29172011-09-15 Arnaud Charlet <charlet@adacore.com>
2918
2919 * s-osinte-aix.ads, s-osinte-darwin.ads, s-osinte-freebsd.ads,
2920 s-osinte-hpux.ads, s-osinte-lynxos.ads, s-osinte-solaris-posix.ads,
2921 s-taprop-posix.adb (CLOCK_MONOTONIC): New constant.
2922 (CLOCK_REALTIME): Fix wrong value on some OSes.
2923 * s-taprop-posix.adb (Monotonic_Clock): Use CLOCK_MONOTONIC.
2924
7e169899
EB
29252011-09-11 Eric Botcazou <ebotcazou@adacore.com>
2926
2927 * gcc-interface/utils.c (maybe_unconstrained_array): In the reference
2928 to unconstrained array case, deal with each branch of a COND_EXPR.
2929 * gcc-interface/utils2.c (build_allocator): Deal with each branch of
2930 a COND_EXPR in the initializer, if present.
2931
819a653e
EB
29322011-09-11 Eric Botcazou <ebotcazou@adacore.com>
2933
2934 * gcc-interface/decl.c (maybe_pad_type): Do not try to change the form
2935 of an addressable type.
2936 * gcc-interface/trans.c (gnat_gimplify_expr) <VIEW_CONVERT_EXPR>: New.
2937 Deal with those cases for which creating a temporary is mandatory.
2938
c946adde
EB
29392011-09-11 Eric Botcazou <ebotcazou@adacore.com>
2940
2941 * gcc-interface/trans.c (call_to_gnu): Use local variable. Make sure
2942 this is a real formal parameter before testing whether it is by ref.
2943
dddf8120
EB
29442011-09-11 Eric Botcazou <ebotcazou@adacore.com>
2945
2946 * gcc-interface/gigi.h (build_call_0_expr): Delete.
2947 (build_call_1_expr): Likewise.
2948 (build_call_2_expr): Likewise.
2949 (build_call_n_expr): New prototype.
2950 * gcc-interface/decl.c (gnat_to_gnu_entity): Use build_call_n_expr.
2951 * gcc-interface/trans.c (establish_gnat_vms_condition_handler): Ditto.
2952 (Handled_Sequence_Of_Statements_to_gnu): Likewise.
2953 (Exception_Handler_to_gnu_zcx): Likewise.
2954 (gnat_to_gnu): Likewise.
2955 (build_binary_op_trapv): Likewise.
2956 * gcc-interface/utils2.c (build_call_0_expr): Delete.
2957 (build_call_1_expr): Likewise.
2958 (build_call_2_expr): Likewise.
2959 (build_call_n_expr): New function.
2960 (build_call_raise): Use build_call_n_expr.
2961 (build_call_raise_range): Likewise.
2962 (build_call_raise_column): Likewise.
2963 (build_call_alloc_dealloc_proc): Likewise.
2964 (maybe_wrap_malloc): Likewise.
2965 (maybe_wrap_free): Likewise.
2966
d8e38554
EB
29672011-09-11 Eric Botcazou <ebotcazou@adacore.com>
2968
2969 * gcc-interface/trans.c (build_return_expr): Use void_type_node for
2970 MODIFY_EXPR.
2971 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Assert that
2972 the result type is null if ENABLE_CHECKING. Set operation_type at the
2973 end unconditionally if not set in the previous cases.
2974 Use build2 and void_type_node for MODIFY_EXPR.
2975 (build_allocator): Use NULL_TREE for MODIFY_EXPR.
2976
416de7d5
EB
29772011-09-08 Eric Botcazou <ebotcazou@adacore.com>
2978
2979 * gcc-interface/utils.c (unchecked_convert): Use a field of the right
2980 precision when converting to or from an integral type whose precision
2981 is not equal to its size.
2982
88b76013
IS
29832011-09-08 Iain Sandoe <iains@gcc.gnu.org>
2984
416de7d5 2985 * traceback.c (Darwin) USE_GCC_UNWINDER for Darwin versions >= 8.
88b76013 2986
1aeee5ad
IS
29872011-09-07 Iain Sandoe <iains@gcc.gnu.org>
2988
416de7d5 2989 * gcc-interface/Makefile.in (darwin): Provide powerpc64 system
1aeee5ad
IS
2990 implementation.
2991 * system-darwin-ppc64.ads: New file.
2992
f61fc398
IS
29932011-09-06 Iain Sandoe <iains@gcc.gnu.org>
2994
2995 * gcc-interface/Makefile.in (gnatlib-shared-darwin): Remove
2996 reference to "-lm".
2997
84ef27d3
IS
29982011-09-06 Iain Sandoe <iains@gcc.gnu.org>
2999
3000 * gcc-interface/Makefile.in (darwin, SO_OPTS): Provide architecture
3001 size switches to the link phase for shared libs.
3002
a1bf1ec7
IS
30032011-09-06 Iain Sandoe <iains@gcc.gnu.org>
3004
416de7d5 3005 * gcc-interface/Makefile.in (x86_64 darwin arch): Adjust
a1bf1ec7
IS
3006 LIBGNAT_TARGET_PAIRS for x86 and x86_64 variants.
3007
e972fd52
AC
30082011-09-06 Arnaud Charlet <charlet@adacore.com>
3009
3010 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in
3011 (gnattools, regnattools, cross-gnattools, canadian-gnattools,
3012 gnatlib, gnatlib-sjlj, gnatlib-zcx, gnatlib-shared, gnatlib_and_tools):
3013 New targets.
3014 (TOOLS_FLAGS_TO_PASS): New.
3015 (../stamp-tools): Reintroduce, to avoid merge conflicts.
3016
ef417be1
RD
30172011-09-06 Robert Dewar <dewar@adacore.com>
3018
3019 * sem_ch10.adb, impunit.ads, impunit.adb (Not_Impl_Defined_Unit): New
3020 name for Is_RM_Defined_Unit. Also several fixes to this unit.
3021
0a034606
RD
30222011-09-06 Robert Dewar <dewar@adacore.com>
3023
3024 * impunit.ads, impunit.adb (Is_RM_Defined_Unit): New function.
3025 * s-rident.ads: New restriction No_Implementation_Units
3026 (this restriction is also part of the profile
3027 No_Implementation_Extensions)
3028 * sem_ch10.adb (Analyze_With_Clause): Add check for
3029 No_Implementation_Units restriction.
3030
ebb6faaa
AC
30312011-09-06 Jerome Guitton <guitton@adacore.com>
3032
3033 * sysdep.c (__gnat_get_task_options): Disable VX_SPE_TASK
3034 on vThreads.
3035
30362011-09-06 Thomas Quinot <quinot@adacore.com>
3037
3038 * s-solita.adb: Minor reformatting.
3039
30402011-09-06 Ed Schonberg <schonberg@adacore.com>
3041
3042 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): The body that
3043 is a rewriting of an expression function does not freeze previous
3044 entities.
3045
30462011-09-06 Robert Dewar <dewar@adacore.com>
3047
3048 * impunit.adb (Is_Known_Unit): Fix bad handling of Ada 2012 case
3049
60435286
TG
30502011-09-06 Tristan Gingold <gingold@adacore.com>
3051
3052 * gcc-interface/Makefile.in: Handle e500v2-wrs-vxworksae like
3053 powerpc-wrs-vxworksae.
3054
08f8a983
AC
30552011-09-06 Thomas Quinot <quinot@adacore.com>
3056
3057 * s-os_lib.ads (Spawn): Minor documentation clarification,
3058 Success is True for a zero exit status.
3059
30602011-09-06 Ed Schonberg <schonberg@adacore.com>
3061
3062 * sem_ch5.adb: Add message for common iterator error.
3063
30642011-09-06 Ed Schonberg <schonberg@adacore.com>
3065
3066 * exp_ch3.adb (Build_Initialization_Call): If the target is a
3067 selected component discriminated by a current instance, replace
3068 the constraint with a reference to the target object, regardless
3069 of whether the context is an init_proc.
3070
30712011-09-06 Robert Dewar <dewar@adacore.com>
3072
3073 * exp_attr.adb: Descriptor_Size is never static.
3074
30752011-09-06 Robert Dewar <dewar@adacore.com>
3076
3077 * gnat_ugn.texi: Add documentation for LSLOC metric in gnatmetric
3078
30792011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
3080
3081 * gnat_rm.texi: Clarify that attribute Descriptor_Size is
3082 non-static.
3083
30842011-09-06 Ed Schonberg <schonberg@adacore.com>
3085
3086 * sem_res.adb (Resolve): An expression that is the body of an
3087 expression function does not freeze.
3088
30892011-09-06 Matthew Heaney <heaney@adacore.com>
3090
3091 * a-csquin.ads, a-cusyqu.adb, a-cbprqu.adb, a-cbsyqu.adb,
3092 a-cuprqu.adb: Changed copyright notice to indicate current
3093 year only.
3094
30952011-09-06 Vincent Celier <celier@adacore.com>
3096
3097 * prj.adb: Minor spelling error fix in comment
3098 * sem_res.adb: Minor reformatting
3099
31002011-09-06 Pascal Obry <obry@adacore.com>
3101
3102 * sysdep.c (winflush_nt): Removed as not needed anymore.
3103 (winflush_95): Likewise.
3104 (winflush_init): Likewise.
3105 (winflush_function): Likewise.
3106 (getc_immediate_common): Remove call to winflush_function.
3107
cb3d8731
HK
31082011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
3109
3110 * exp_attr.adb (Expand_N_Attribute_Reference): Rewrite the
3111 processing for Descriptor_Size.
3112 * gnat_rm.texi: Rephrase the wording for attribute Descriptor_Size
3113 to account for its broader usage.
3114 * sem_attr.adb (Analyze_Attribute): Change the error detection
3115 circuitry for Descriptor_Size as the attribute is now applicable
3116 to all types.
3117
f7e6fc47
RD
31182011-09-06 Robert Dewar <dewar@adacore.com>
3119
3120 * sem_attr.adb, prj-nmsc.adb, exp_aggr.adb: Minor reformatting.
3121
f8e9fc30
AC
31222011-09-06 Ed Schonberg <schonberg@adacore.com>
3123
3124 * lib-xref.adb (OK_To_Set_Referenced): A reference to a formal
3125 in a parameter association must not set the Referenced flag on
3126 the formal.
3127 * prj-nmsc.adb (Check_File_Naming_Schemes): Remove useless formal
3128
31292011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
3130
3131 * gnat_rm.texi: Add a section on attribute Descriptor_Size
3132
e8e38f35
AC
31332011-09-06 Arnaud Charlet <charlet@adacore.com>
3134
3135 * gcc-interface/Makefile.in (common-tools, gnatmake-re,
3136 gnatlink-re): Speed up by using -j0.
3137
ba759acd
AC
31382011-09-06 Yannick Moy <moy@adacore.com>
3139
3140 * sem_ch13.adb (Analyze_Aspect_Specifications): Call
3141 Set_Corresponding_Aspect when creating pragma from aspect.
3142 (Add_Predicates): Use new field Corresponding_Aspect.
3143 * sem_prag.adb (Analyze_Pragma): Make Pname hold source aspect
3144 name when present, for the purpose of issuing error messages;
3145 remove local procedure Error_Pragma_Arg_Alternate_Name.
3146 * sinfo.adb, sinfo.ads (Corresponding_Aspect): New field in
3147 N_Pragma node.
3148 (From_Dynamic_Predicate, From_Static_Predicate): Remove fields from
3149 N_Pragma node.
3150
31512011-09-06 Robert Dewar <dewar@adacore.com>
3152
3153 * checks.adb, s-except.ads, g-socket.adb: Minor reformatting.
3154
31552011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
3156
3157 * exp_ch6.adb (Build_Heap_Allocator): Add new
3158 local variable Desig_Typ. Code and comment reformatting. Add
3159 machinery to ensure that the allocation uses a fat pointer when
3160 the type of the return object is a constrained array and the
3161 function return type is an unconstrained array.
3162
31632011-09-06 Vincent Celier <celier@adacore.com>
3164
3165 * make.adb, prj-part.adb, prj-nmsc.adb: Remove unused formal
3166 parameters in subprograms.
3167
31682011-09-06 Arnaud Charlet <charlet@adacore.com>
3169
3170 * s-taprop-mingw.adb (Finalize_TCB): Fix typo.
3171
31722011-09-06 Thomas Quinot <quinot@adacore.com>
3173
3174 * s-taprop-vxworks.adb, s-tpoaal.adb, s-tpopsp-vxworks.adb
3175 (System.Tasking.Primitive_Operations.Specific.Delete): Remove
3176 subprogram.
3177 (System.Tasking.Primitive_Operations.Specific.Set): If argument
3178 is null, destroy task specific data, to make API consistent with
3179 other platforms, and thus compatible with the shared version
3180 of s-tpoaal.adb.
3181 (System.Tasking.Primitive_Operations.ATCB_Allocation.Free_ATCB):
3182 Document the above assumption.
3183
f4f92d9d
AC
31842011-09-06 Ed Schonberg <schonberg@adacore.com>
3185
3186 * exp_ch6.adb (Expand_Inlined_Call): Fix use of uninitialized
3187 variable for type of return value when return type is
3188 unconstrained and context is an assignment.
3189
31902011-09-06 Ed Schonberg <schonberg@adacore.com>
3191
3192 * sem_ch8.adb (Check_Class_Wide_Actual): Do not generate body of
3193 class-wide operation if expansion is not enabled.
3194
31952011-09-06 Eric Botcazou <ebotcazou@adacore.com>
3196
3197 * checks.adb (Apply_Scalar_Range_Check): Deal with access
3198 type prefix.
3199
32002011-09-06 Yannick Moy <moy@adacore.com>
3201
3202 * sem_ch13.adb (Analyze_Aspect_Specifications, case
3203 Aspect_Invariant): Do not issue error at this point on illegal
3204 pragma placement, as this is checked later on when analyzing
3205 the corresponding pragma.
3206 * sem_prag.adb (Error_Pragma_Arg_Alternate_Name): New procedure
3207 similar to Error_Pragma_Arg, except the source name of the
3208 aspect/pragma to use in warnings may be equal to parameter
3209 Alt_Name (Analyze_Pragma, case Pragma_Invariant): refine error
3210 message to distinguish source name of pragma/aspect, and whether
3211 the illegality resides in the type being public, or being private
3212 without a public declaration
3213
32142011-09-06 Thomas Quinot <quinot@adacore.com>
3215
3216 * g-socket.adb (Check_For_Fd_Set): On Windows, no need for bitmap
3217 size check (fd_set is implemented differently on that platform).
3218
32192011-09-06 Thomas Quinot <quinot@adacore.com>
3220
3221 * s-taprop-vxworks.adb, s-taprop-tru64.adb, s-taprop-vms.adb,
3222 s-tpoaal.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
3223 s-taprop-solaris.adb, s-taprop-irix.adb, s-taprop.ads,
3224 s-taprop-hpux-dce.adb, s-taprop-dummy.adb, s-taprop-posix.adb
3225 (ATCB_Allocation): New subpackage of
3226 System.Tasking.Primitive_Operations, shared across all targets
3227 with full tasking runtime.
3228 (ATCB_Allocation.New_ATCB): Moved there (from target specific
3229 s-taprop bodies).
3230 (ATCB_Allocation.Free_ATCB): New subprogram. Deallocate an ATCB,
3231 taking care of establishing a local temporary ATCB if the one
3232 being deallocated is Self, to avoid a reference to the freed
3233 ATCB in Abort_Undefer.
3234
32352011-09-06 Thomas Quinot <quinot@adacore.com>
3236
3237 * s-tassta.adb, s-taskin.ads (Free_Task): If the task is not
3238 terminated, mark it for deallocation upon termination.
3239 (Terminate_Task): Call Free_Task again if the task is marked
3240 for automatic deallocation upon termination.
3241
df177175
RD
32422011-09-06 Robert Dewar <dewar@adacore.com>
3243
3244 * a-cbprqu.ads, a-cbsyqu.ads, a-cuprqu.ads, a-cusyqu.ads,
3245 a-intnam-aix.ads, a-intnam-darwin.ads, a-intnam-dummy.ads,
3246 a-intnam-freebsd.ads, a-intnam-hpux.ads, a-intnam-irix.ads,
3247 a-intnam-linux.ads, a-intnam-lynxos.ads, a-intnam-mingw.ads,
3248 a-intnam-solaris.ads, a-intnam-tru64.ads,
3249 a-intnam-vms.ads, a-intnam-vxworks.ads, a-intnam.ads, interfac.ads,
3250 cstand.adb, s-maccod.ads: Mark all entities as Implementation_Defined
3251 * einfo.ads, einfo.adb (Is_Implementation_Defined): New flag
3252 * par-prag.adb: Add dummy entry for pragma Implementation_Defined
3253 * s-rident.ads: Add new restriction No_Implementation_Identifiers
3254 Add new profile No_Implementation_Extensions
3255 * sem_prag.adb: Implement pragma Implementation_Defined Implement
3256 profile No_Implementation_Extensions
3257 * sem_util.adb: Minor reformatting (Set_Entity_With_Style_Check):
3258 Check violation of restriction No_Implementation_Identifiers
3259 * snames.ads-tmpl: Add entries for pragma Implementation_Defined
3260 Add entry for Name_No_Implementation_Extensions
3261
32622011-09-06 Robert Dewar <dewar@adacore.com>
3263
3264 * impunit.ads: Minor reformatting.
3265
b991dd43
AC
32662011-09-06 Robert Dewar <dewar@adacore.com>
3267
3268 * ali.adb, sem_ch13.adb, lib-xref.adb: Minor reformatting.
3269
32702011-09-06 Pascal Obry <obry@adacore.com>
3271
3272 * s-osinte-linux.ads, s-oscons-tmplt.c: Use oscons to define sigset_t
3273 types.
3274
516785cc
AC
32752011-09-06 Robert Dewar <dewar@adacore.com>
3276
3277 * g-socket.adb: Minor reformatting
3278
32792011-09-06 Javier Miranda <miranda@adacore.com>
3280
3281 * ali.adb (Scan_ALI): Add missing support to load references of
3282 entities imported from other languages.
3283 * ali.ads (Xref_Record): Adding new fields to store the language and
3284 name of an imported entity.
3285 * lib-xref.adb (Output_Import_Export_Info): Fix typo
3286 in comment.
3287
32882011-09-06 Ed Schonberg <schonberg@adacore.com>
3289
3290 * sem_prag.adb (Analyze_Pragma, case Type_Invariant): A type invariant
3291 is allowed on a full type declaration if it is the completion of
3292 a private declarations.
3293 * sem_ch13.adb (Analyze_Aspect_Specifications): An invariant
3294 aspect is allowed on a full type declaration in the private part
3295 of a package.
3296
96691943
AC
32972011-09-06 Robert Dewar <dewar@adacore.com>
3298
3299 * sem_ch8.ads: Minor reformatting
3300
33012011-09-06 Thomas Quinot <quinot@adacore.com>
3302
3303 * s-oscons-tmplt.c, g-socket.adb (GNAT.Sockets.Clear,Set,Is_Set):
3304 Guard against socket values that are not in [0;FD_SETSIZE[
3305
54bf19e4
AC
33062011-09-06 Robert Dewar <dewar@adacore.com>
3307
3308 * s-osinte-linux.ads, a-iteint.ads, exp_ch6.adb, s-solita.adb: Minor
3309 reformatting.
3310
33112011-09-06 Arnaud Charlet <charlet@adacore.com>
3312
3313 * s-linux-alpha.ads: Minor reformatting
3314 * s-oscons-tmplt.c: Fix generated comments in s-oscons template.
3315 Use sizeof instead of corresponding C defines in s-oscons template.
3316
5d42cba1
VG
33172011-09-06 Vadim Godunko <godunko@adacore.com>
3318
3319 * a-convec.ads, a-iteint.ads: Minor reformatting.
3320
77aa62e7
AC
33212011-09-06 Vincent Celier <celier@adacore.com>
3322
3323 * projects.texi: Add menus and @node lines.
3324
33252011-09-06 Ed Schonberg <schonberg@adacore.com>
3326
3327 * exp_ch6.adb (Expand_Inlined_Call): Handle properly the case
3328 where the return type is an unconstrained array and the context
3329 is an assignment. Optimize the case when the target of the
3330 assignment is a selected component.
3331
33322011-09-06 Arnaud Charlet <charlet@adacore.com>
3333
3334 * s-solita.adb: Update comments.
3335
33362011-09-06 Pascal Obry <obry@adacore.com>
3337
3338 * s-linux.ads, s-linux-alpha.ads, s-linux-hppa.ads, s-linux-mipsel.ads,
3339 s-linux-sparc.ads: Remove hard coded and now wrong definitions.
3340 * s-oscons-tmplt.c: Add support for generating pthread related
3341 types size on GNU/Linux as done for Darwin.
3342 * s-osinte-linux.ads: Use s-oscons to define the pthread types.
3343
886b5a18
AC
33442011-09-06 Robert Dewar <dewar@adacore.com>
3345
3346 * exp_ch6.adb: Fix minor typo.
3347
33482011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
3349
3350 * exp_ch7.adb: Remove with and use clauses for Get_Targ.
3351 (Alignment_Of): Moved to the body of Nearest_Multiple_Rounded_Up.
3352 (Double_Size_Of): Alphabetized. Update the comment on usage.
3353 (Make_Finalize_Address_Stmts): Update comments and reformat code.
3354 (Nearest_Multiple_Rounded_Up): New routine.
3355 (Size_Of): Update comment on usage. The generated expression now
3356 accounts for alignment gaps by rounding the size of the type to the
3357 nearest multiple rounded up of the type's alignment.
3358
57a3fca9
AC
33592011-09-06 Robert Dewar <dewar@adacore.com>
3360
3361 * exp_ch7.adb, g-comlin.adb: Minor reformatting.
3362
33632011-09-06 Steve Baird <baird@adacore.com>
3364
3365 * exp_ch4.adb (Expand_Allocator_Expression): Look through
3366 derived subprograms in checking for presence of an
3367 Extra_Accessibility_Of_Result formal parameter.
3368 * exp_ch6.adb (Expand_Call): Look through derived subprograms in
3369 checking for presence of an Extra_Accessibility_Of_Result formal
3370 parameter.
3371 (Expand_Call.Add_Actual_Parameter): Fix a bug in the
3372 case where the Parameter_Associatiations attribute is already set,
3373 but set to an empty list.
3374 (Needs_Result_Accessibility_Level):
3375 Unconditionally return False. This is a temporary
3376 change, disabling the Extra_Accessibility_Of_Result
3377 mechanism.
3378 (Expand_Simple_Function_Return): Check for
3379 Extra_Accessibility_Of_Result parameter's presence instead of
3380 testing Ada_Version when generating a runtime accessibility
3381 check which makes use of the parameter.
3382
eaed0c37
AC
33832011-09-06 Ed Schonberg <schonberg@adacore.com>
3384
3385 * exp_ch4.adb (Expand_N_Case_Expression): Actions created for the
3386 expression in a given case alternative must be attached to the
3387 statement list of the ccrresponding case statement alternative
3388 They cannot be propagated ahead of the case statement, because
3389 the validity of the expression that generated the action may
3390 hold only for that alternative.
3391
33922011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
3393
3394 * exp_ch7.adb: Remove with and use clauses for Get_Targ.
3395 (Alignment_Of): Remove the code for strict alignment targets.
3396 (Double_Alignment_Of): Removed.
3397 (Double_Size_Of): New routine.
3398 (Make_Finalize_Address_Stmts): Change the
3399 calculation of the dope's size. Update relevant comments.
3400 (Size_Of): New routine.
3401
b8a93198
AC
34022011-09-06 Steve Baird <baird@adacore.com>
3403
3404 * einfo.ads (Extra_Accessibility): Update associated comment to use
3405 the term "present" correctly ("present" just means that it is not
3406 an error to query the value of the attribute - it does not imply
3407 that the value must be non-null).
3408 (Extra_Constrained): Ditto.
3409 (Is_Visible_Formal): Ditto.
3410 (Extra_Accessibility_Of_Result) Ditto; also add Inline pragma.
3411 (Set_Extra_Accessibility_Of_Result): Add Inline pragma.
3412 * exp_ch4.adb (Expand_Allocator_Expression): Improve a comment.
3413 * exp_ch6.adb (Expand_Call): The callee may require an
3414 Extra_Accessibility_Of_Result actual parameter even if Ada_Version
3415 < Ada_2012. This can occur if the callee is exported from a Gnat
3416 runtimes unit. Also improve a comment.
3417
34182011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
3419
3420 * exp_ch7.adb: Add with and use clauses for Get_Targ.
3421 (Alignment_Of): Rename formal parameter Some_Typ
3422 to Typ, update related comment. Use the allocator alignment on
3423 strict alignment targets such as SPARC.
3424 (Double_Alignment_Of): Rename formal parameter Some_Typ to Typ, update
3425 related comment.
3426
34272011-09-06 Gary Dismukes <dismukes@adacore.com>
3428
3429 * sem_ch9.adb (Check_Interfaces): Test
3430 Is_Limited_Type rather than Is_Limited_Record when checking that
3431 the partial view of a synchronized full view must be limited.
3432
34332011-09-06 Emmanuel Briot <briot@adacore.com>
3434
3435 * g-comlin.adb (Free): Fix memory leak.
3436
ebf494ec
RD
34372011-09-06 Robert Dewar <dewar@adacore.com>
3438
3439 * sem_util.adb, exp_ch6.adb: Minor reformatting and code reorganization.
3440
63585f75
SB
34412011-09-06 Steve Baird <baird@adacore.com>
3442
3443 * einfo.ads (Extra_Accessibility_Of_Result): New function; in the
3444 (Ada2012) cases described in AI05-0234 where the accessibility
3445 level of a function result is "determined by the point of
3446 call", an implicit parameter representing that accessibility
3447 level is passed in. Extra_Accessibilty_Of_Result yields this
3448 additional formal parameter. Extra_Accessibility_Of_Result
3449 is analogous to the existing Extra_Accessibility
3450 function used in the implementation of access parameters.
3451 (Set_Extra_Accessibility_Of_Result): New procedure; sets
3452 Extra_Accessibility_Of_Result attribute.
3453 * einfo.adb (Extra_Accessibility_Of_Result): New function.
3454 (Set_Extra_Accessibility_Of_Result): New procedure.
3455 (Write_Field19_Name): Display Extra_Accessibilty_Of_Result attribute.
3456 * sem_util.adb (Dynamic_Accessibility_Level): Set Etype of
3457 an accessibility level literal to Natural; introduce a nested
3458 function, Make_Level_Literal, to do this.
3459 * exp_ch6.ads (Needs_Result_Accessibility_Level): New function;
3460 determines whether a given function (or access-to-function
3461 type) needs to have an implicitly-declared accessibility-level
3462 parameter added to its profile.
3463 (Add_Extra_Actual_To_Call): Export an existing procedure which was
3464 previously declared in the body of Exp_Ch6.
3465 * exp_ch6.adb (Add_Extra_Actual_To_Call): Export declaration by moving
3466 it to exp_ch6.ads.
3467 (Has_Unconstrained_Access_Discriminants): New Function; a
3468 predicate on subtype entities which returns True if the given
3469 subtype is unconstrained and has one or more access discriminants.
3470 (Expand_Call): When expanding a call to a function which takes an
3471 Extra_Accessibility_Of_Result parameter, pass in the appropriate
3472 actual parameter value. In the case of a function call which is
3473 used to initialize an allocator, this may not be possible because
3474 the Etype of the allocator may not have been set yet. In this
3475 case, we defer passing in the parameter and handle it later in
3476 Expand_Allocator_Expression.
3477 (Expand_Simple_Function_Return): When returning from a function which
3478 returns an unconstrained subtype having at least one access
3479 discriminant, generate the accessibility check needed to ensure that
3480 the function result will not outlive any objects designated by its
3481 discriminants.
3482 (Needs_Result_Accessibility_Level): New function; see exp_ch6.ads
3483 description.
3484 * exp_ch4.adb (Expand_Allocator_Expression): When a function call
3485 is used to initialize an allocator, we may need to pass in "the
3486 accessibility level determined by the point of call" (AI05-0234)
3487 to the function. Expand_Call, where such actual parameters are
3488 usually generated, is too early in this case because the Etype of
3489 the allocator (which is used in determining the level to be passed
3490 in) may not have been set yet when Expand_Call executes. Instead,
3491 we generate code to pass in the appropriate actual parameter
3492 in Expand_Allocator_Expression.
3493 * sem_ch6.adb (Create_Extra_Formals): Create
3494 the new Extra_Accessibility_Of_Result formal if
3495 Needs_Result_Accessibility_Level returns True. This includes the
3496 introduction of a nested procedure, Check_Against_Result_Level.
3497
1a982c6e
AC
34982011-09-06 Arnaud Charlet <charlet@adacore.com>
3499
3500 * gcc-interface/Makefile.in (X86_TARGET_PAIRS): Remove duplicate
3501 declaration.
3502
e42bcfa3
AC
35032011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
3504
3505 * s-finmas.adb (Set_Finalize_Address): Explain the reason
3506 for the synchronization. Move the test for null from
3507 s-stposu.Allocate_Any_Controlled to this routine since the check
3508 needs to be protected too.
3509 (Set_Heterogeneous_Finalize_Address): Explain the reason for the
3510 synchronization code.
3511 * s-finmas.ads (Set_Heterogeneous_Finalize_Address): Add comment
3512 explaining the context in which this routine is used.
3513 * s-stposu.adb (Allocate_Any_Controlled): Move the test for null
3514 to s-finmas.Set_Finalize_Address.
3515
35162011-09-05 Ed Schonberg <schonberg@adacore.com>
3517
3518 * einfo.ads: Document that itypes have no parent field.
3519
35202011-09-05 Robert Dewar <dewar@adacore.com>
3521
3522 * rtsfind.adb (Check_CRT): Check for overloaded entity
3523 * rtsfind.ads: Document that entities to be found by rtsfind
3524 cannot be overloaded
3525 * s-taenca.adb, s-tasren.adb, s-tpobop.adb, s-tpoben.ads, s-tpoben.adb
3526 (Lock_Entries_With_Status): New name for Lock_Entries with two
3527 arguments (changed to meet rtsfind no overloading rule).
3528
544e7c17
AC
35292011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
3530
3531 * s-finmas.adb (Set_Finalize_Address (Address,
3532 Finalize_Address_Ptr)): Renamed to Set_Heterogeneous_Finalize_Address.
3533 (Set_Finalize_Address (in out Finalization_Master,
3534 Finalize_Address_Ptr): Add synchronization code.
3535 * s-finmas.ads (Set_Finalize_Address (Address,
3536 Finalize_Address_Ptr)): Renamed to Set_Heterogeneous_Finalize_Address.
3537 * s-stposu.adb (Allocate_Any_Controlled): Update the call to
3538 Set_Finalize_Address for the heterogeneous case.
3539
35402011-09-05 Ed Schonberg <schonberg@adacore.com>
3541
3542 * sem_ch3.adb: Undo previous change, not suitable after all.
3543
35442011-09-05 Robert Dewar <dewar@adacore.com>
3545
3546 * einfo.ads: Minor comment clarification.
3547
0613fb33
AC
35482011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
3549
3550 * exp_ch6.adb (Move_Activation_Chain): Rewritten. The routine
3551 no longer needs to search through the entities of the return
3552 statement scope to find the _chain.
3553 * sem_ch5.adb: Add with and use clauses for Exp_Ch6 and Sem_Ch6.
3554 (Analyze_Block_Statement): Add local variable
3555 Is_BIP_Return_Statement. Add machinery to install all entities
3556 produced by the expansion of the return object declaration.
3557 (Install_Return_Entities): New routine.
3558 * sem_ch6.ads, sem_ch6.adb (Install_Entity): Moved from body to spec.
3559
35602011-09-05 Ed Schonberg <schonberg@adacore.com>
3561
3562 * sem_ch10.adb (Analyze_Context): Apply simple fixup if context
3563 of subunit is incomplete.
3564 (Analyze_Proper_Body): If parent spec is not available, do not
3565 attempt analysis.
3566
5dcab3ca
AC
35672011-09-05 Ed Schonberg <schonberg@adacore.com>
3568
3569 * sem_disp.adb (Find_Controlling_Arg): Add checks for
3570 interface type conversions, that are expanded into dereferences.
3571
35722011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
3573
3574 * sem_ch6.adb (Analyze_Subprogram_Body_Helper):
3575 Examine the parameter and return profile of a subprogram and swap
3576 any incomplete types coming from a limited context with their
3577 corresponding non-limited views.
3578 (Exchange_Limited_Views): New routine.
3579
35802011-09-05 Ed Schonberg <schonberg@adacore.com>
3581
3582 * sem_ch3.adb (Prepare_Private_Subtype_Completion): Set parent
3583 of internal entity to the subtype declaration, so that when
3584 entities are subsequently exchanged in a package body, the tree
3585 remains properly formatted for ASIS.
3586
8da1a312
AC
35872011-09-05 Johannes Kanig <kanig@adacore.com>
3588
3589 * g-comlin.adb (Set_Usage): Additional optional argument to set help
3590 message.
3591 (Display_Help): display the user given help message, if available.
3592
35932011-09-05 Ed Schonberg <schonberg@adacore.com>
3594
3595 * sem_ch3.adb (OK_For_Limited_Init_In_05): The expression
3596 is legal if the original node is an identifier that is a
3597 parameterless function call.
3598
69b73847
PO
35992011-09-05 Pascal Obry <obry@adacore.com>
3600
3601 * prj-nmsc.adb: Minor reformatting.
3602 Add support for standalone aggregate library.
3603 (Check_Stand_Alone_Library): Handle standalone aggregate library.
3604 * projects.texi: Fix documentation for aggregate library projects.
3605
81bf2382
AC
36062011-09-05 Robert Dewar <dewar@adacore.com>
3607
3608 * sem_ch6.adb: Minor reformatting.
3609
36102011-09-05 Matthew Gingell <gingell@adacore.com>
3611
3612 * s-tassta.adb (Task_Wrapper): Ensure that we don't try to write the
3613 stack guard page on PPC Linux. This patch ensures the 64K guard page at
3614 the bottom of the stack is not overwritten.
3615
13a0b1e8
AC
36162011-09-05 Thomas Quinot <quinot@adacore.com>
3617
3618 * exp_intr.adb, s-tasini.adb: Minor reformatting.
3619
36202011-09-05 Ed Schonberg <schonberg@adacore.com>
3621
3622 * sem_ch3.adb (Access_Definition): If an access type declaration
3623 appears in a child unit, the scope of whatever anonymous type
3624 may be generated is the child unit itself.
3625
36262011-09-05 Ed Schonberg <schonberg@adacore.com>
3627
3628 * sem_ch6.adb (Analyze_Expression_Function): Do not set
3629 Comes_From_Source on rewritten body.
3630 (Analyze_Subprogram_Body_Helper): Check that the original node for
3631 the body comes from source, when determining whether expansion
3632 of a protected operation is needed.
3633
20428725
AC
36342011-09-05 Ed Schonberg <schonberg@adacore.com>
3635
3636 * exp_aggr.adb (Replace_Type): If the target of the assignment is
3637 a selected component and the right-hand side is a self-referential
3638 access, the proper prefix of the rewritten attribute is a copy
3639 of the left-hand side, not of its prefix.
3640
36412011-09-05 Robert Dewar <dewar@adacore.com>
3642
3643 * sem_ch5.adb: Minor reformatting.
3644 * sem_ch3.adb: Minor code clean up.
3645
36462011-09-05 Jose Ruiz <ruiz@adacore.com>
3647
3648 * exp_ch9.adb (Make_Initialize_Protection): The fact that
3649 restriction No_Dynamic_Attachment is in effect or not should
3650 not influence the default priority associated to a protected
3651 object. With this change, when the restriction is in effect (as
3652 is the case for the Ravenscar profile) the default priority of
3653 a protected object with an interrupt handler is in the range of
3654 interrupt priorities (Default_Interrupt_Priority) as required
3655 by D.3(10).
3656
36572011-09-05 Arnaud Charlet <charlet@adacore.com>
3658
3659 * a-iteint.ads: Fix header.
3660
36612011-09-05 Vincent Celier <celier@adacore.com>
3662
3663 * prj-conf.adb (Do_Autoconf): Make sure Obj_Dir always ends
3664 with a directory separator to avoid output such as:
3665 "/path/to/objauto.cgpr" has been deleted.
3666
4a1bfefb
AC
36672011-09-05 Robert Dewar <dewar@adacore.com>
3668
3669 * sem_ch3.adb: Minor reformatting.
3670
36712011-09-05 Ed Schonberg <schonberg@adacore.com>
3672
3673 * sem_ch5.adb: Better error message.
3674
36752011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
3676
3677 * exp_aggr.adb: Add with and use clause for Exp_Ch6.
3678 (Expand_Array_Aggregate): Detect a special case of an aggregate
3679 which contains tasks in the context of an unexpanded return
3680 statement of a build-in-place function.
3681 * exp_ch6.adb: Add with and use clause for Exp_Aggr.
3682 (Expand_N_Extended_Return_Statement): Detect a delayed aggregate
3683 which contains tasks and expand it now that the original simple
3684 return statement has been rewritten.
3685 * exp_ch9.adb (Build_Activation_Chain_Entity): Code
3686 reformatting. Do not create a chain for an extended return
3687 statement if one is already available.
3688 (Has_Activation_Chain): New routine.
3689
9ec080cb
AC
36902011-09-05 Marc Sango <sango@adacore.com>
3691
3692 * sem_ch3.adb (Analyze_Object_Declaration): Remove
3693 the wrong test and add the correct test to detect the violation
3694 of illegal use of unconstrained string type in SPARK mode.
3695
36962011-09-05 Ed Schonberg <schonberg@adacore.com>
3697
3698 * sem_ch5.adb (Analyze_Iteration_Specification): Improve error
3699 message on an iterator over an array.
3700
37012011-09-05 Robert Dewar <dewar@adacore.com>
3702
3703 * lib-xref-alfa.adb: Minor reformatting.
3704
aeae67ed
RD
37052011-09-05 Robert Dewar <dewar@adacore.com>
3706
3707 * sem_ch3.adb, sem_res.adb, par.adb, par-ch6.adb, g-comlin.adb,
3708 exp_ch6.adb, lib-xref-alfa.adb: Minor reformatting.
3709
d72e7628
AC
37102011-09-05 Gary Dismukes <dismukes@adacore.com>
3711
3712 * exp_ch7.adb, exp_ch6.adb: Minor reformatting.
3713
37142011-09-05 Johannes Kanig <kanig@adacore.com>
3715
3716 * lib-xref-alfa.adb: Update comments.
3717
37182011-09-05 Thomas Quinot <quinot@adacore.com>
3719
3720 * sem_res.adb: Minor reformatting
3721
0d566e01
ES
37222011-09-05 Ed Schonberg <schonberg@adacore.com>
3723
3724 * exp_ch6.adb (Build_In_Place_Formal): If extra formals are not
3725 present, create them now. Needed in case the return type was
3726 a limited view in the function declaration.
3727 (Make_Build_In_Place_Call_In_Allocator): If return type contains
3728 tasks, build the activation chain for it. Pass a reference to
3729 the Master_Id in call to Add_Task_Actuals_To_Build_In_Place call.
3730 * exp_ch7.adb (Make_Set_Finalize_Address_Call): Clean up interface
3731 with build_in_place calls.
3732 * sem_ch9.adb (Analyze_Task_Type_Declaration): If partial view was
3733 incomplete, inatialize its Corresponding_Record_Type component.
3734 * sem_ch10.adb (Build_Chain): Initialize Private_Dependents field
3735 of limited views.
3736
ec09f261
AC
37372011-09-05 Johannes Kanig <kanig@adacore.com>
3738
3739 * lib-xref-alfa.adb (Is_Alfa_Reference): Filter constants from effect
3740 information.
3741
37422011-09-05 Ed Schonberg <schonberg@adacore.com>
3743
3744 * par-ch6.adb (P_Subprogram): In Ada2012 mode, if the subprogram
3745 appears within a package specification and the token after "IS"
3746 is not a parenthesis, assume that this is an unparenthesized
3747 expression function, even if the token appears in a line by
3748 itself.
3749 * par.adb: Clarify use of Labl field of scope stack in error
3750 recovery.
3751
7109f4f5
AC
37522011-09-05 Bob Duff <duff@adacore.com>
3753
3754 * sem_res.adb (Resolve_Intrinsic_Operator): Use unchecked
3755 conversions instead of normal type conversions in all cases where a
3756 type conversion would be illegal. In particular, use unchecked
3757 conversions when the operand types are private.
3758
37592011-09-05 Johannes Kanig <kanig@adacore.com>
3760
3761 * lib-xref-alfa.adb (Is_Alfa_Reference): Never declare effects on
3762 objects of task type or protected type.
3763
66dc8075
AC
37642011-09-05 Ed Schonberg <schonberg@adacore.com>
3765
3766 * sem_ch6.adb (Analyze_Expression_Function): If the expression
3767 function comes from source, indicate that so does its rewriting,
3768 so it is compatible with any subsequent expansion of the
3769 subprogram body (e.g. when it is a protected operation).
3770 * sem_ch4.adb: minor reformatting
3771
37722011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
3773
3774 * lib.adb (Check_Same_Extended_Unit): Comment rewriting. Use
3775 Get_Source_Unit rather than Get_Code_Unit as instantiation unfolding
3776 may lead to wrong ancestor package in the case of instantiated subunit
3777 bodies. If a subunit is instantiated, follow the chain of instantiations
3778 rather than the stub structure.
3779
bd38b431
AC
37802011-09-02 Robert Dewar <dewar@adacore.com>
3781
3782 * sem_ch4.adb, sem_ch6.adb: Minor reformatting.
3783 * gcc-interface/Make-lang.in: Update dependencies.
3784
37852011-09-02 Marc Sango <sango@adacore.com>
3786
3787 * sem_ch3.adb (Analyze_Object_Declaration): Change
3788 comment and add additional check to differentiate constant of
3789 type string from others unconstrained type.
3790
99d520ad
ES
37912011-09-02 Ed Schonberg <schonberg@adacore.com>
3792
3793 * sinfo.ads, sinfo.adb: New semantic attribute Premature_Use,
3794 present in incomplete type declarations to refine the error
3795 message the full declaration is in the same unit.
3796 * sem_ch4.adb (Analyze_Selected_Component): If the prefix is of
3797 an incomplete type, set the Premature_Use for additional message.
3798 * sem_ch3.adb (Find_Type_Name): If partial view is incomplete
3799 and Premature_Use is set, place additional information at the
3800 point of premature use.
3801
5b5588dd
AC
38022011-09-02 Bob Duff <duff@adacore.com>
3803
3804 * sem_ch6.adb: (Check_Post_State): Suppress warning
3805 "postcondition refers only to pre-state" when the expression has not
3806 yet been analyzed, because it causes false alarms. This can happen when
3807 the postcondition contains a quantified expression, because those are
3808 analyzed later. This is a temporary/partial fix.
3809 (Process_Post_Conditions): Minor: change wording of warning.
3810
38112011-09-02 Marc Sango <sango@adacore.com>
3812
3813 * sem_ch3.adb (Analyze_Object_Declaration): Detect the violation of
3814 illegal use of unconstrained string type in SPARK mode.
3815 * sem_res.adb (Analyze_Operator_Symbol): Set the
3816 right place where the string operand of concatenation should be
3817 violate in SPARK mode.
3818
bd603506
RD
38192011-09-02 Robert Dewar <dewar@adacore.com>
3820
3821 * sem_prag.adb, sem_util.adb, sem_ch6.adb, prj-nmsc.adb,
3822 exp_ch3.adb: Minor reformatting.
3823
24a120ac
AC
38242011-09-02 Vincent Celier <celier@adacore.com>
3825
3826 * prj-conf.adb (Add_Default_GNAT_Naming_Scheme): Declare "gcc"
3827 as the compiler driver so Is_Compilable returns True for sources.
3828 * prj-nmsc.adb (Override_Kind): When Kind is Sep, set the source
3829 for the body.
3830
38312011-09-02 Ed Schonberg <schonberg@adacore.com>
3832
3833 * sem_prag.adb (Analyze_PPC_In_Decl_Part): for a class-wide
3834 condition, a reference to a controlling formal must be interpreted
3835 as having the class-wide type (or an access to such) so that the
3836 inherited condition can be properly applied to any overriding
3837 operation (see ARM12 6.6.1 (7)).
3838
38392011-09-02 Tristan Gingold <gingold@adacore.com>
3840
3841 * init.c (__gnat_is_vms_v7): Fix case and add prototype
3842 for LIB$GETSYI.
3843
38442011-09-02 Javier Miranda <miranda@adacore.com>
3845
3846 * exp_ch3.adb (Expand_N_Object_Declaration): Do not copy the
3847 initializing expression of a class-wide interface object declaration
3848 if its type is limited.
3849
38502011-09-02 Johannes Kanig <kanig@adacore.com>
3851
3852 * sem_util.adb (Unique_Name): To obtain a unique name for enumeration
3853 literals, take into account the type name; the type is *not*
3854 the scope for an enumeration literal.
3855
38562011-09-02 Ed Schonberg <schonberg@adacore.com>
3857
3858 * sem_ch6.adb (Check_Overriding_Indicator): add special check
3859 to reject an overriding indicator on a user-defined Adjust
3860 subprogram for a limited controlled type.
3861
38622011-09-02 Ed Schonberg <schonberg@adacore.com>
3863
3864 * sem_res.adb (Resolve_Actuals): add missing call to Resolve
3865 for an actual that is a function call returning an unconstrained
3866 limited controlled type.
3867
38682011-09-02 Tristan Gingold <gingold@adacore.com>
3869
3870 * g-socthi-vms.adb (c_sendmsg, c_recvmsg): Use unpacked msg if on vms 7
3871
38722011-09-02 Johannes Kanig <kanig@adacore.com>
3873
3874 * alfa.ads (Name_Of_Heap_Variable): Change value of the HEAP variable
3875 from "HEAP" to __HEAP Change comment that refers to that variable
3876 * put_alfa.adb: Change comment that refers to that variable
3877
c5f5123f
AC
38782011-09-02 Robert Dewar <dewar@adacore.com>
3879
3880 * exp_ch4.adb, exp_ch6.adb, prj-nmsc.adb: Minor reformatting.
3881
38822011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
3883
3884 * exp_util.adb (Extract_Renamed_Object): Renamed to
3885 Find_Renamed_Object. This routine has been reimplemented and now uses
3886 tree traversal to locate a renamed object.
3887 (Is_Aliased): Replace call to Extract_Renamed_Object with
3888 Find_Renamed_Object.
3889
38902011-09-02 Tristan Gingold <gingold@adacore.com>
3891
3892 * init.c: (__gnat_is_vms_v7): New function.
3893
38942011-09-02 Olivier Hainque <hainque@adacore.com>
3895
3896 * tracebak.c (STOP_FRAME, ppc elf/vxworks case): Stop on frames
3897 that have a misaligned backchain, necessarily bogus.
3898
2bfa5484
HK
38992011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
3900
3901 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Do not create
3902 TSS routine Finalize_Address when compiling in Alfa mode.
3903 (Expand_Freeze_Record_Type): Do not create TSS routine
3904 Finalize_Address when compiling in Alfa mode.
3905 * exp_ch4.adb (Expand_Allocator_Expression): Do not produce a
3906 call to Set_Finalize_Address in Alfa mode because Finalize_Address is
3907 not built.
3908 (Expand_N_Allocator): Do not produce a call to
3909 Set_Finalize_Address in Alfa mode because Finalize_Address is not built.
3910 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Do not
3911 produce a call to primitive Set_Finalize_Address in Alfa mode because
3912 Finalize_Address is not built.
3913 * exp_ch7.adb (Build_Finalization_Master): Do not create
3914 finalization masters in Afa mode since they are not needed.
3915 (Build_Finalizer): Do not create scope and library-level
3916 finalizers in Alfa mode since they are not needed.
3917 * exp_util.adb (Build_Allocate_Deallocate_Proc): Do not expand
3918 "new" and "free" when applied to controlled objects in Alfa mode since
3919 this is not needed.
3920
7a0ddd20
AC
39212011-09-02 Vincent Celier <celier@adacore.com>
3922
3923 * prj-nmsc.db: (Check_Stand_Alone_Library): For SALs, allow
3924 only library names with the syntax of Ada identifiers, to avoid errors
3925 when compiling the binder generated files.
3926 * projects.texi: Document restriction on SAL library names
3927
39282011-09-02 Thomas Quinot <quinot@adacore.com>
3929
3930 * a-chtgbo.adb: Minor comment fix.
3931
439b6dfa
AC
39322011-09-02 Robert Dewar <dewar@adacore.com>
3933
3934 * lib-xref.adb: Minor reformatting
3935
39362011-09-02 Vincent Celier <celier@adacore.com>
3937
3938 * bindusg.adb, clean.adb, gnatchop.adb, gnatfind.adb, gnatlink.adb,
3939 gnatls.adb, gnatname.adb, gnatxref.adb, gprep.adb, makeusg.adb: Add
3940 --version and --help in usage.
3941 * switch.ads, switch.adb (Display_Usage_Version_And_Help): New procedure
3942
f2404867
AC
39432011-09-02 Bob Duff <duff@adacore.com>
3944
3945 * lib-xref.adb: (Hash): Avoid use of 'Mod attribute, because old
3946 compilers don't understand it.
3947
39482011-09-02 Gary Dismukes <dismukes@adacore.com>
3949
3950 * exp_attr.adb (Expand_N_Attribute_Reference): Pass the
3951 underlying subtype rather than its base type on the call to
3952 Build_Record_Or_Elementary_Input_Function, so that any
3953 constraints on a discriminated subtype will be available for
3954 doing the check required by AI05-0192.
3955 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
3956 If the prefix subtype of the 'Input attribute is a constrained
3957 discriminated subtype, then check each constrained discriminant value
3958 against the corresponding value read from the stream.
3959
029b67ba
YM
39602011-09-02 Yannick Moy <moy@adacore.com>
3961
3962 * usage.adb, warnsw.adb, sem_ch6.adb, opt.ads: Disable by default
3963 warnings on suspicious contracts, and enable them with -gnatwa.
3964
dc36a7e3
RD
39652011-09-02 Robert Dewar <dewar@adacore.com>
3966
3967 * exp_util.adb, exp_ch9.adb, sem_attr.adb, sem_ch6.adb: Minor
3968 reformatting.
3969
d5aa443c
AC
39702011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
3971
3972 * exp_ch9.adb (Install_Private_Data_Declarations): Add guards
3973 which ensure that restriction No_Dynamic_Attachment has not been
3974 violated.
3975 (Make_Initialize_Protection): Protected types with attach or
3976 interrupt handlers must not violate restriction No_Dynamic_Attachment.
3977 * exp_util.adb (Corresponding_Runtime_Package): Add a guard
3978 which ensures that restriction No_Dynamic_Attachment has not been
3979 violated.
3980 * sem_attr.adb: (Eval_Attribute): Transform
3981 VAX_Float_Type'First and 'Last into references to
3982 the temporaries which store the corresponding bounds. The
3983 transformation is needed since the back end cannot evaluate
3984 'First and 'Last on VAX.
3985 (Is_VAX_Float): New routine.
3986
39872011-09-02 Ed Schonberg <schonberg@adacore.com>
3988
3989 * sem_ch12.adb (Analyze_Subprogram_Instantiation): If the
3990 generic unit is not intrinsic and has an explicit convention,
3991 the instance inherits it.
3992
67c86178
AC
39932011-09-02 Robert Dewar <dewar@adacore.com>
3994
3995 * prj-dect.adb, prj-env.adb, prj-nmsc.adb, prj-proc.adb, prj-tree.adb,
3996 prj.adb, prj.ads, sem_ch5.adb: Minor reformatting.
3997
39982011-09-02 Thomas Quinot <quinot@adacore.com>
3999
4000 * sem_attr.adb (Analyze_Attribute, case Unrestriced_Access):
4001 Guard against a prefix that is an N_Has_Entity but has no
4002 associated entity.
4003
40042011-09-02 Yannick Moy <moy@adacore.com>
4005
4006 * lib-xref-alfa.adb (Is_Alfa_Reference): Ignore IN parameters in Alfa
4007 references.
4008
40092011-09-02 Yannick Moy <moy@adacore.com>
4010
4011 * opt.ads (Warn_On_Suspicious_Contract): New warning flag.
4012 * sem_ch3.adb (Analyze_Declarations): Call checker for suspicious
4013 contracts.
4014 * sem_ch6.adb, sem_ch6.ads (Check_Subprogram_Contract): New
4015 procedure looking for suspicious postconditions.
4016 * usage.adb (Usage): New options -gnatw.t and -gnatw.T.
4017 * warnsw.adb (Set_Dot_Warning_Switch): Take into account new
4018 options -gnatw.t and -gnatw.T.
4019
735ca1b9
PO
40202011-09-02 Pascal Obry <obry@adacore.com>
4021
4022 * prj.adb: Minor code refactoring. Move check for null project in
4023 Project_Changed.
4024 * projects.texi: Fix minor typos.
4025
86828d40
AC
40262011-09-02 Ed Schonberg <schonberg@adacore.com>
4027
4028 * sem_ch5.adb (Analyze_Iterator_Specification): If the domain
4029 of iteration is an expression, its value must be captured in a
4030 renaming declaration, so that modification of the elements is
4031 propagated to the original container.
4032
40332011-09-02 Pascal Obry <obry@adacore.com>
4034
4035 * prj-proc.adb, prj.adb, makeutl.adb, makeutl.ads, prj-dect.adb,
4036 prj-nmsc.adb, prj-util.adb, prj-conf.adb, prj-env.adb,
4037 prj-tree.adb: Minor reformatting and style fixes.
4038
83de674b
AC
40392011-09-02 Robert Dewar <dewar@adacore.com>
4040
4041 * s-rident.ads: Add new restriction No_Implicit_Aliasing
4042 * sem_attr.adb: (Analyze_Access_Attribute): Deal with
4043 No_Implicit_Aliasing
4044 (Analyze_Attribute, case Address): ditto
4045 (Analyze_Attribute, case Unrestricted_Access): ditto
4046 * sem_util.ads, sem_util.adb: (Is_Aliased_View): Handle
4047 No_Implicit_Aliasing restriction.
4048 * gnat_rm.texi: Add documentation for No_Implicit_Aliasing
4049
40502011-09-02 Ed Schonberg <schonberg@adacore.com>
4051
4052 * exp_util.adb: (Possible_Bit_Aligned_Object): If the object
4053 is an unchecked conversion, apply test to its expression.
4054
40552011-09-02 Javier Miranda <miranda@adacore.com>
4056
4057 * sem_ch3.adb (Check_Abstract_Overriding): When
4058 traversing the chain of aliased subprograms avoid reporting a
4059 redundant error on the current entity.
4060
40612011-09-02 Sergey Rybin <rybin@adacore.com>
4062
4063 * gnat_ugn.texi: Minor clean up.
4064
40652011-09-02 Bob Duff <duff@adacore.com>
4066
4067 * s-htable.adb (Set_If_Not_Present): Use renaming
4068 instead of ":=", because the type Key is limited in the generic (even
4069 if not in the instances).
4070
2c17ca0a
AC
40712011-09-02 Robert Dewar <dewar@adacore.com>
4072
4073 * exp_util.adb, sem_ch10.adb, sem_attr.adb, s-htable.adb,
4074 g-comlin.adb, g-comlin.ads, lib-xref-alfa.adb, lib-xref.adb: Minor
4075 reformatting.
4076
40772011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
4078
4079 * sem_ch3.adb: (Set_Anonymous_Type): Associate the itype of an
4080 inherited component with the enclosing derived type. Code reformatting.
4081
40822011-09-02 Gary Dismukes <dismukes@adacore.com>
4083
4084 * checks.adb: (Determine_Range): Add test of OK1 to prevent the early
4085 return done when overflow checks are enabled, since comparisons against
4086 Lor and Hir should not be done when OK1 is False.
4087
40882011-09-02 Gary Dismukes <dismukes@adacore.com>
4089
4090 * exp_ch6.adb (Add_Finalization_Master_Actual_To_Build_In_Place_Call):
4091 Add new formal Master_Exp. When present, add that expression to the
4092 call as an extra actual.
4093 (Make_Build_In_Place_Call_In_Object_Declaration): Add variable
4094 Fmaster_Actual and in the case of a BIP call initializing a return
4095 object of an enclosing BIP function set it to a
4096 new reference to the implicit finalization master
4097 formal of the enclosing function. Fmaster_Actual is
4098 then passed to the new formal Master_Exp on the call to
4099 Add_Finalization_Master_Actual_To_Build_ In_Place_Call. Move
4100 initializations of Enclosing_Func to its declaration.
4101
41022011-09-02 Thomas Quinot <quinot@adacore.com>
4103
4104 * csets.ads: Minor reformatting
4105
41062011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
4107
4108 * exp_aggr.adb: (Get_Constraint_Association): Add code to retrieve
4109 the full view of a private type coming from an instantiation.
4110 * exp_ch4.adb: (Current_Anonymous_Master): Reimplement the search
4111 loop to iterate over the declarations rather than use the
4112 First_Entity / Next_Entity scheme.
4113
ed32b82e
ES
41142011-09-02 Ed Schonberg <schonberg@adacore.com>
4115
4116 * sem_attr.adb: (Analyze_Attribute, case 'Range): when expanding
4117 X'range (N) into X'First (N) .. X'Last (N), do not share the
4118 dimension indicator N, if present. Even though it is a static
4119 constant, its source location may be modified when printing
4120 expanded code under -gnatDL, and node sharing will lead to chaos
4121 in Sprint on large files, by generating a sloc value that does
4122 not correspond to any source file.
4123
f7bb41af
AC
41242011-09-02 Bob Duff <duff@adacore.com>
4125
4126 * einfo.adb: (Has_Xref_Entry): Do not call
4127 Implementation_Base_Type. Lib.Xref has been
4128 rewritten to avoid the need for it, and it was costly.
4129 * s-htable.ads,s-htable.adb: (Present,Set_If_Not_Present): New
4130 functions in support of efficient xref.
4131 * lib-xref-alfa.adb: Misc changes related to Key component of
4132 type Xref_Entry.
4133 * lib-xref.adb: (Add_Entry,etc): Speed improvement.
4134 (New_Entry): Call Implementation_Base_Type, because Has_Xref_Entry
4135 no longer does. This is the one place where it is needed.
4136
41372011-09-02 Johannes Kanig <kanig@adacore.com>
4138
4139 * g-comlin.adb (Getopt): New optional argument Concatenate to have
4140 similar interface as the other Getopt function.
4141
41422011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
4143
4144 * exp_ch4.adb: (Expand_Allocator_Expression): Do not generate
4145 a call to Set_Finalize_Address if there is no allocator available.
4146 * exp_util.adb: (Build_Allocate_Deallocate_Proc): Account for
4147 a case of allocator expansion where the allocator is not expanded but
4148 needs a custom allocate routine. Code reformatting.
4149 (Is_Finalizable_Transient): Remove local variables Has_Rens and
4150 Ren_Obj. Code reformatting.
4151 (Is_Renamed): Renamed to Is_Aliased. Add code to detect aliasing
4152 through the use of 'reference.
4153 * sem_ch4.adb: (Analyze_Allocator): Detect allocators generated
4154 as part of build-in-place expansion. They are intentionally marked as
4155 coming from source, but their parents are not.
4156
bd0bc43e
AC
41572011-09-02 Ed Schonberg <schonberg@adacore.com>
4158
4159 * sem_ch10.adb (Analyze_With_Clause): If the library unit
4160 is the generated subprogram declaration for a child unit body
4161 that acts as spec, use the original body in the with_clause,
4162 to prevent binding errors.
4163
41642011-09-02 Vincent Celier <celier@adacore.com>
4165
4166 * gnat_ugn.texi: Adapt documentation of -gnateInnn to new VMS
4167 qualifier /MULTI_UNIT_INDEX=
4168
41692011-09-02 Johannes Kanig <kanig@adacore.com>
4170
4171 * g-comlin.adb (Getopt): Return when switch is dealt with automatically,
4172 instead of calling the callback function
4173
9fdb5d21
RD
41742011-09-02 Robert Dewar <dewar@adacore.com>
4175
4176 * prj-proc.adb, prj.ads, sem_util.adb, s-taprop-linux.adb,
4177 prj-nmsc.adb, prj-util.ads, prj-env.adb: Minor reformatting.
4178
c6d5d1ac
AC
41792011-09-02 Vincent Celier <celier@adacore.com>
4180
4181 * prj-nmsc.adb: (Find_Sources): When the list of sources is
4182 explicitly declared in an extending project, do not warn if a source
4183 for an inherited naming exception is not found.
4184
41852011-09-02 Gary Dismukes <dismukes@adacore.com>
4186
4187 * exp_ch6.adb: (Is_Build_In_Place_Function_Call): Return False if
4188 expansion is inactive.
4189
41902011-09-02 Ed Schonberg <schonberg@adacore.com>
4191
4192 * sem_util.adb (Note_Possible_Modification): If the entity
4193 being modified is the renaming generated for an Ada2012 iterator
4194 element, the enclosing container or array is modified as well.
4195
2ba1a7c7
AC
41962011-09-02 Jose Ruiz <ruiz@adacore.com>
4197
4198 * s-taprop-linux.adb (Initialize_Lock, Initialize_TCB,
4199 Initialize): Define and initialize the
4200 mutex attributes and condition variable attributes locally.
4201
42022011-09-02 Vincent Celier <celier@adacore.com>
4203
4204 * prj-nmsc.adb (Check_File): Mark as Locally_Removed a naming
4205 exception replaced in an extending project.
4206 (Check_Object): No error when the other source is locally removed.
4207
42082011-09-02 Yannick Moy <moy@adacore.com>
4209
4210 * exp_ch6.adb (Is_Build_In_Place_Function_Call): in Alfa mode, allow
4211 unresolved calls.
4212
d51813db
AC
42132011-08-31 Arnaud Charlet <charlet@adacore.com>
4214
4215 * gcc-interface/Makefile.in: Clean up handling of x86 and x86-64
4216 run-time files.
4217 * gcc-interface/Make-lang.in: Update dependencies.
4218
9f55bc62
AC
42192011-09-01 Robert Dewar <dewar@adacore.com>
4220
4221 * sem_ch3.adb, s-taprop-linux.adb, gnatls.adb: Minor reformatting.
4222
42232011-09-01 Jose Ruiz <ruiz@adacore.com>
4224
4225 * adaint.h (__gnat_cpu_free): Fix the name of this profile.
4226 * adaint.c (__gnat_cpu_alloc, __gnat_cpu_alloc_size, __gnat_cpu_free,
4227 __gnat_cpu_zero, __gnat_cpu_set): Create version of these subprograms
4228 specific for systems where their glibc version does not define the
4229 routines to handle dynamically allocated CPU sets.
4230
42312011-09-01 Vincent Celier <celier@adacore.com>
4232
4233 * prj-proc.adb, prj.ads, prj-nmsc.adb, prj-util.adb, prj-util.ads,
4234 prj-env.adb: Implement inheritance of naming exceptions in extending
4235 projects.
4236
d7386a7a
AC
42372011-09-01 Romain Berrendonner <berrendo@adacore.com>
4238
4239 * gnatls.adb: Display simple message instead of content of
4240 gnatlic.adl.
4241
42422011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
4243
4244 * sem_ch3.adb: (Build_Derived_Record_Type) Remove the kludgy update of
4245 access discriminant and anonymous access component scopes.
4246 (Inherit_Component): Reuse the itype of an access discriminant
4247 or anonymous access component by copying it in order to set the proper
4248 scope. This is done only when the parent and the derived type
4249 are in different scopes.
4250 (Set_Anonymous_Etype): New routine.
4251
42522011-09-01 Robert Dewar <dewar@adacore.com>
4253
4254 * a-convec.adb: Minor reformatting throughout.
4255
9d1e0e72
JR
42562011-09-01 Jose Ruiz <ruiz@adacore.com>
4257
4258 * adaint.c, adaint.h (__gnat_cpu_alloc, __gnat_cpu_alloc_size,
4259 __gnat_cpu_set_free): Create these wrappers around the CPU_ALLOC,
4260 CPU_ALLOC_SIZE and CPU_FREE linux macros.
4261 (__gnat_cpu_zero, __gnat_cpu_set): Use the CPU_ZERO_S and
4262 CPU_SET_S respectively because we are now using dynamically allocated
4263 CPU sets which are more portable across different glibc versions.
4264 * s-osinte-linux.ads (cpu_set_t_ptr, CPU_ALLOC, CPU_ALLOC_SIZE,
4265 CPU_FREE): Add this type and subprograms to be able to create cpu_set_t
4266 masks dynamically according to the number of processors in the target
4267 platform.
4268 (CPU_ZERO, CPU_SET): They are now mapped to the CPU_ZERO_S and CPU_SET_S
4269 respectively, so we need to pass the size of the masks as
4270 parameters.
4271 * s-taprop-linux.adb (Create_Task, Set_Task_Affinity): Use dynamically
4272 created cpu_set_t masks
4273 with the number of processors available in the target platform,
4274 instead of static bit arrays. It enhances portability because
4275 it uses the information from the target platform.
4276 * sem_ch8.adb: (Attribute_Renaming): When checking whether we
4277 are using a restricted run-time library, use the flag
4278 Configurable_Run_Time_Mode instead of Restricted_Profile.
4279
a95be2d4
AC
42802011-09-01 Vincent Celier <celier@adacore.com>
4281
4282 * ug_words: Add /MULTI_UNIT_INDEX= -> -gnateI
4283 * vms_data.ads: Add new VMS qualifier equivalent for -gnateInnn
4284
42852011-09-01 Nicolas Roche <roche@adacore.com>
4286
4287 * adaint.c (__gnat_tmp_name): Don't use tmpnam function from the system
4288 on VxWorks in kernel mode.
4289
6b81741c
AC
42902011-09-01 Jose Ruiz <ruiz@adacore.com>
4291
4292 * s-taprop-linux.adb (Create_Task, Set_Task_Affinity): Use the linux
4293 macros for handling CPU sets (CPU_ZERO, CPU_SET) instead of modifying
4294 directly the bit array.
4295 * s-osinte-linux.ads (CPU_ZERO, CPU_SET): Import these wrappers around
4296 the linux macros with the same name.
4297 * adaint.h, adaint.c (__gnat_cpu_zero, __gnat_cpu_set): Create these
4298 wrappers around the CPU_ZERO and CPU_SET linux macros.
4299
43002011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
4301
4302 * exp_ch7.adb (Find_Insertion_List): Removed.
4303 (Process_Transient_Objects): Insert the declarations of the hook
4304 access type and the hook object before the associated transient object.
4305
43062011-09-01 Jose Ruiz <ruiz@adacore.com>
4307
4308 * sem_ch8.adb (Attribute_Renaming): Add missing check to avoid loading
4309 package System.Aux_Dec when using restricted run-time libraries which
4310 do not have this package.
4311
43122011-09-01 Tristan Gingold <gingold@adacore.com>
4313
4314 * s-vaflop-vms-alpha.adb: Remove pragma optimize, useless.
4315
43162011-09-01 Bob Duff <duff@adacore.com>
4317
4318 * sem_attr.adb (Analyze_Access_Attribute): Do not call
4319 Kill_Current_Values for P'Unrestricted_Access, where P is library level
4320
43212011-09-01 Thomas Quinot <quinot@adacore.com>
4322
4323 * exp_ch5.adb: Minor reformatting
4324 * gnat_ugn.texi: Fix minor typos.
4325 * gcc-interface/Make-lang.in: Update dependencies.
4326
8256c1bf
AC
43272011-09-01 Robert Dewar <dewar@adacore.com>
4328
4329 * inline.adb, sem_aggr.adb: Minor reformatting.
4330
43312011-09-01 Ed Schonberg <schonberg@adacore.com>
4332
4333 * a-convec.adb: Proper handling of cursors for Ada2012 iterators.
4334
d1c5f424
AC
43352011-09-01 Robert Dewar <dewar@adacore.com>
4336
4337 * prj-proc.adb, exp_ch6.adb, prj-env.adb: Minor reformatting.
4338
43392011-09-01 Bob Duff <duff@adacore.com>
4340
4341 * sem_aggr.adb (Resolve_Aggregate): Need to treat "in instance
4342 body" the same as "in inlined body", because visibility shouldn't
4343 apply there.
4344
43452011-09-01 Eric Botcazou <ebotcazou@adacore.com>
4346
4347 * inline.adb (Add_Inlined_Body): Refine previous change.
4348
1bb6e262
AC
43492011-09-01 Gary Dismukes <dismukes@adacore.com>
4350
4351 * exp_ch6.ads (Needs_BIP_Alloc_Form): New utility function.
4352 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
4353 Test for case where call
4354 initializes an object of a return statement before testing for
4355 a constrained call, to ensure that all such cases get handled
4356 by simply passing on the caller's parameters. Also, in that
4357 case call Needs_BIP_Alloc_Form to determine whether to pass on
4358 the BIP_Alloc_Form parameter of the enclosing function rather
4359 than testing Is_Constrained. Add similar tests for the return
4360 of a BIP call to later processing to ensure consistent handling.
4361 (Needs_BIP_Alloc_Form): New utility function.
4362 * sem_ch6.adb: (Create_Extra_Formals): Replace test for adding
4363 a BIP_Alloc_Form formal with call to new utility function
4364 Needs_BIP_Alloc_Form.
4365
43662011-09-01 Pascal Obry <obry@adacore.com>
4367
4368 * prj-part.adb: Minor reformatting.
4369
43702011-09-01 Vincent Celier <celier@adacore.com>
4371
4372 * prj-env.adb (Create_Mapping_File.Process): Encode the upper
4373 half character in the unit name.
4374
db15225a
AC
43752011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
4376
4377 * exp_ch4.adb: Minor code and comment reformatting.
4378
43792011-09-01 Thomas Quinot <quinot@adacore.com>
4380
4381 * exp_ch6.adb (Expand_Inlined_Call): Remove redundant tests
4382 for Is_Limited_Type and Is_Tagged_Type in condition checking
4383 for by-reference type.
4384 * inline.adb (Add_Inlined_Body): Only exclude init_procs. Other
4385 subprograms may have a completion because of a previous
4386 Inline_Always clause, but the enclosing package must be marked
4387 inlined for the subprogram body to become visible to the backend.
4388
9d641fc0
TQ
43892011-09-01 Thomas Quinot <quinot@adacore.com>
4390
4391 * sem_aux.adb, exp_ch4.adb: Minor reformatting
4392
dbe36d67
AC
43932011-09-01 Pascal Obry <obry@adacore.com>
4394
4395 * prj-proc.adb, prj.ads, sinput-p.adb: Minor reformatting.
4396
43972011-09-01 Ed Schonberg <schonberg@adacore.com>
4398
4399 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Generate references to
4400 the formals of a subprogram stub that acts as a spec.
4401
44022011-09-01 Ed Schonberg <schonberg@adacore.com>
4403
4404 * exp_ch6.adb (Expand_Inlined_Call): If an actual is a by_reference
4405 type, declare a renaming for it, not an object declaration.
4406
f5037886
AC
44072011-09-01 Yannick Moy <moy@adacore.com>
4408
4409 * ali-util.adb, ali-util.ads (Read_Withed_ALIs): Add parameter
4410 Ignore_Errors to ignore failures to read ALI files when True.
4411
44122011-09-01 Javier Miranda <miranda@adacore.com>
4413
4414 * exp_ch3.adb (Expand_N_Object_Declaration): Handle non-default
4415 constructor calls associated with non-tagged record types.
4416
44172011-09-01 Robert Dewar <dewar@adacore.com>
4418
4419 * g-socthi-vms.adb: Minor reformatting.
4420
44212011-09-01 Nicolas Roche <roche@adacore.com>
4422
4423 * sysdep.c: Don't use macro functions for stdio functions on VxWorks
4424 in order to avoid impact of imcompatible changes.
4425 * cstreams.c: Likewise
4426 * cio.c: Likewise
4427 * aux-io.c: Likewise
4428
44292011-09-01 Yannick Moy <moy@adacore.com>
4430
4431 * lib-writ.adb (Write_With_Lines): Always output complete information
4432 on "with" line in Alfa mode, as this is required by formal verification
4433 back-end.
4434
549e4558
AC
44352011-09-01 Tristan Gingold <gingold@adacore.com>
4436
4437 * g-socthi-vms.adb: Add comments.
4438
44392011-09-01 Pascal Obry <obry@adacore.com>
4440
4441 * prj.ads: Minor reformatting.
4442
70c0422d
AC
44432011-09-01 Vincent Celier <celier@adacore.com>
4444
4445 * prj-env.adb (Create_Config_Pragmas_File.Check): Put all naming
4446 exceptions in the config pragmas file.
4447
44482011-09-01 Tristan Gingold <gingold@adacore.com>
4449
4450 * gnat_ugn.texi: Document GNAT_STACK_SIZE on IVMS.
4451
8c5b03a0
AC
44522011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
4453
4454 * exp_ch7.adb (Find_Insertion_List): New routine.
4455 (Process_Transient_Objects): Add code to handle the abnormal
4456 finalization of a controlled transient associated with a subprogram
4457 call. Since transients are cleaned up right after the associated
4458 context, an exception raised during a subprogram call may bypass the
4459 finalization code.
4460
44612011-09-01 Robert Dewar <dewar@adacore.com>
4462
4463 * exp_ch6.adb (Expand_Call): Check actual for aliased parameter is
4464 aliased.
4465
3040dbd4
RD
44662011-09-01 Robert Dewar <dewar@adacore.com>
4467
4468 * exp_ch4.adb, a-exexda.adb: Minor reformatting.
4469
fecbd779
AC
44702011-09-01 Robert Dewar <dewar@adacore.com>
4471
4472 * s-taskin.ads, s-tassta.adb, sem_ch13.adb: Minor reformatting.
4473
44742011-09-01 Thomas Quinot <quinot@adacore.com>
4475
4476 * Makefile.rtl: Move s-oscons.o from GNATRTL_TASKING_OBJS to
4477 GNATRTL_NONTASKING_OBJS.
4478
44792011-09-01 Robert Dewar <dewar@adacore.com>
4480
4481 * einfo.ads (Is_Aliased): Fix existing documentation and add note on
4482 possibility of this flag being set for formals in Ada 2012 mode.
4483 * par-ch6.adb (P_Formal_Part): Handle aliased for parameters for Ada
4484 2012.
4485 * sem_ch6.adb (Process_Formals): Handle aliased parameters in Ada 2012
4486 mode.
4487 * sinfo.adb (Aliased_Present): Allowed in N_Parameter_Specification for
4488 Ada 2012.
4489 * sinfo.ads (Aliased_Present): Allowed in N_Parameter_Specification for
4490 Ada 2012.
4491
44922011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
4493
4494 * exp_ch4.adb (Find_Insertion_Node): New routine. Determines the proper
4495 insertion node in a tree of nested Expression_With_Actions nodes.
4496 (Process_Transient_Object): In the case where a complex if statement
4497 has been converted into nested Expression_With_Actions nodes, the
4498 "hook" object and the associated access type must be inserted before
4499 the top most Expression_With_Actions.
4500
516f608f
AC
45012011-09-01 Robert Dewar <dewar@adacore.com>
4502
4503 * a-cbprqu.adb, a-cbprqu.ads, a-cuprqu.adb, a-cuprqu.ads,
4504 a-cbsyqu.adb, a-cbsyqu.ads: Minor reformatting.
4505
45062011-09-01 Ed Schonberg <schonberg@adacore.com>
4507
4508 * sem_attr.adb: Conditionalize aliasing predicates to Ada2012.
4509
45102011-09-01 Jose Ruiz <ruiz@adacore.com>
4511
4512 * aspects.ads (Aspect_Id, Aspect_Argument, Aspect_Names): Add the CPU
4513 aspect.
4514 * aspects.adb (Canonical_Aspect): Add entry for the CPU aspect.
4515 * sem_ch13.adb (Analyze_Aspect_Specifications): Analyze the CPU aspect
4516 in a similar way as we do for the Priority or Dispatching_Domain aspect.
4517 * s-mudido-affinity.adb (Dispatching_Domain_Tasks,
4518 Dispatching_Domains_Frozen): Move this local data to package
4519 System.Tasking because with the CPU aspect we need to have access
4520 to this data when creating the task in System.Tasking.Stages.Create_Task
4521 * s-taskin.ads (Dispatching_Domain_Tasks, Dispatching_Domains_Frozen):
4522 Move these variables from the body of
4523 System.Multiprocessors.Dispatching_Domains because with the CPU aspect
4524 we need to have access to this data when creating the task in
4525 System.Tasking.Stages.Create_Task.
4526 * s-taskin.adb (Initialize): Signal the allocation of the environment
4527 task to a CPU, if any, so that we know whether the CPU can be
4528 transferred to a different dispatching domain.
4529 * s-tassta.adb (Create_Task): Check whether the CPU to which this task
4530 is being allocated belongs to the dispatching domain where the task
4531 lives. Signal the allocation of the task to a CPU, if any, so that we
4532 know whether the CPU can be transferred to a different dispatching
4533 domain.
4534
2d42e881
ES
45352011-09-01 Ed Schonberg <schonberg@adacore.com>
4536
4537 * exp_attr.adb, sem_attr.adb, snames.ads-tmpl: Implementation of
4538 attributes Same_Storage and Overlaps_Storage.
4539
579fda56
AC
45402011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
4541
4542 * exp_strm.adb: Remove with and use clause for Opt.
4543 (Build_Array_Input_Function): Remove the version-dependent generation
4544 of the return statement. The Ada 2005 tree is now the default.
4545
45462011-09-01 Yannick Moy <moy@adacore.com>
4547
4548 * put_alfa.adb: Unconditionnally write files in Alfa section, so that
4549 it is never empty when compiling in Alfa mode.
4550
45512011-09-01 Robert Dewar <dewar@adacore.com>
4552
4553 * sem_aggr.adb, sem_ch3.adb, a-direct.adb, s-taprop-vxworks.adb,
4554 comperr.adb, exp_ch9.adb, exp_pakd.adb, sem_ch12.adb, freeze.adb,
4555 s-taprop-mingw.adb, s-taprop-linux.adb, s-taprop-solaris.adb,
4556 gnat1drv.adb, a-rbtgbo.adb, exp_dist.adb: Minor reformatting
4557
45582011-09-01 Matthew Heaney <heaney@adacore.com>
4559
4560 * Makefile.rtl, impunit.adb: Add a-csquin.ads, a-cusyqu.ad[sb],
4561 a-cuprqu.ad[sb], a-cbsyqu.ad[sb], a-cbprqu.ad[sb]
4562 * a-csquin.ads: New Ada 2012 unit that specifies the queue interface
4563 * a-cusyqu.ads, a-cusyqu.adb: New Ada 2012 unit that specifies the
4564 unbounded queue container.
4565 * a-cbsyqu.ads, a-cbsyqu.adb: New Ada 2012 unit that specifies the
4566 bounded queue container.
4567 * a-cuprqu.ads, a-cuprqu.adb: New Ada 2012 unit that specifies the
4568 unbounded priority queue container.
4569 * a-cbprqu.ads, a-cbprqu.adb: New Ada 2012 unit that specifies the
4570 bounded priority queue container.
4571
24c34107
AC
45722011-08-31 Pascal Obry <obry@adacore.com>
4573
4574 * a-direct.adb: Do not try to create an UNC path on Windows.
4575 (Create_Path): Skip leading computer name in UNC path if any.
4576
45772011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
4578
4579 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function): Remove the
4580 version-dependent generation of the return statement. The Ada 2005 tree
4581 is now the default.
4582
45832011-08-31 Thomas Quinot <quinot@adacore.com>
4584
4585 * rtsfind.ads, exp_dist.adb (Find_Numeric_Representation): Predefined
4586 types Stream_Element_Offset and Storage_Offset have a different native
4587 type depending on whether the platform is 32 or 64 bits. When
4588 exchanging them, always convert to 64 bits.
4589
45902011-08-31 Yannick Moy <moy@adacore.com>
4591
4592 * debug.adb: Reserve debug option -gnatd.E for passing gnatprove option
4593 --force-alfa to gnat2why.
4594
45952011-08-31 Ed Schonberg <schonberg@adacore.com>
4596
4597 * sem_ch12.adb (Save_References): If the node has aspects, save
4598 references within the corresponding expressions in a separate step,
4599 because the aspects are not directly in the tree for the declaration
4600 to which they belong.
4601
46022011-08-31 Arnaud Charlet <charlet@adacore.com>
4603
4604 * freeze.adb (Freeze_Record_Type): Omit test on variable size component
4605 in CodePeer mode, since representation clauses are partially ignored.
4606 * gcc-interface/Make-lang.in: Update dependencies.
4607
702d2020
AC
46082011-08-31 Jose Ruiz <ruiz@adacore.com>
4609
4610 * s-taprop-vxworks.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
4611 s-taprop-solaris.adb (Create_Task): Not_A_Specific_CPU can be assigned
4612 to any dispatching domain.
4613
46142011-08-31 Thomas Quinot <quinot@adacore.com>
4615
4616 * exp_ch4.adb: Minor reformatting.
4617
46182011-08-31 Bob Duff <duff@adacore.com>
4619
4620 * sem_ch6.adb (Get_Generic_Parent_Type): Don't query Subtype_Indication
4621 on nodes for which it is not defined.
4622 (Is_Non_Overriding_Operation): Exit the loop when we find a generic
4623 parent type.
4624
46252011-08-31 Bob Duff <duff@adacore.com>
4626
4627 * sem_ch3.adb (Process_Full_View): Disable legality check if
4628 In_Instance, to avoid spurious errors.
4629 * sem_ch12.adb (Validate_Derived_Type_Instance): Disable legality check
4630 if In_Instance, to avoid spurious errors.
4631
46322011-08-31 Pascal Obry <obry@adacore.com>
4633
4634 * a-direct.adb: Use Dir_Seps everywhere to properly handle all
4635 directory speparators.
4636 (Compose): Use Dir_Seps to handle both forms.
4637 (Create_Path): Use Dir_Seps instead of explicit check, no semantic
4638 changes.
4639 (Extension): Use Dir_Seps to handle both forms.
4640
46412011-08-31 Pascal Obry <obry@adacore.com>
4642
4643 * prj-conf.adb: Minor reformatting.
4644
67645bde
AC
46452011-08-31 Jose Ruiz <ruiz@adacore.com>
4646
4647 * aspects.ads (Aspect_Id, Aspect_Argument, Aspect_Names): Add the
4648 dispatching domain aspect.
4649 * aspects.adb (Canonical_Aspect): Add entry for the dispatching domain
4650 aspect.
4651 * sem_ch13.adb (Analyze_Aspect_Specifications): Analyze the
4652 Dispatching_Domain aspect in a similar way as we do for the Priority
4653 aspect.
4654 * exp_ch9.adb (Expand_N_Task_Type_Declaration): Add the
4655 Dispatching_Domain component if a Dispatching_Domain pragma or aspect
4656 is present.
4657 (Make_Task_Create_Call): Add the Dispatching_Domain when creating a task
4658 * par-prag.adb (Prag): Add Pragma_Dispatching_Domain as a known pragma.
4659 * sem_prag.adb (Analyze_Pragma): Check the correctness of a pragma
4660 Dispatching_Domain and add it to the task definition.
4661 (Sig_Flags): Add Pragma_Dispatching_Domain.
4662 * rtsfind.ads, rtsfind.adb (RTU_Id, RE_Id, Get_Unit_Name): Add the
4663 support to find the types Dispatching_Domain and
4664 Dispatching_Domain_Access.
4665 * sinfo.ads, sinfo.adb (Has_Pragma_Dispatching_Domain,
4666 Set_Has_Pragma_Dispatching_Domain): Add these subprograms to set and
4667 query the availability of a pragma Dispatching_Domain.
4668 * snames.ads-tmpl (Name_uDispatching_Domain): Add this name required by
4669 the expander to pass the Dispatching_Domain when creating a task.
4670 (Name_Dispatching_Domain): Add this new name for a pragma.
4671 (Pragma_Id): Add the new Pragma_Dispatching_Domain.
4672 * s-tassta.ads, s-tassta.adb (Create_Task): Set the domain to which the
4673 task has been allocated at creation time.
4674 * s-tarest.adb (Create_Restricted_Task): The dispatching domain using
4675 Ravenscar is always null.
4676 * s-taskin.ads, s-taskin.adb (Initialize_ATCB): Set the domain to which
4677 the task has been allocated at creation time.
4678 * s-tporft.adb (Register_Foreign_Thread): A foreign task will not have
4679 a specific dispatching domain.
4680 * s-taprop-linux.adb, s-taprop-solaris.adb, s-taprop-vxworks.adb,
4681 s-taprop-mingw.adb (Create_Task): Check whether both Dispatching_Domain
4682 and CPU are specified for the task, and the CPU value is not contained
4683 within the range of processors for the domain.
4684
46852011-08-31 Vincent Celier <celier@adacore.com>
4686
4687 * make.adb (Original_Gcc) : New constant String_Access.
4688 (Gnatmake): For VM targets, do not use VM version of the compiler if
4689 --GCC= has been specified.
4690
46912011-08-31 Thomas Quinot <quinot@adacore.com>
4692
4693 * sem_ch5.adb: Minor reformatting.
4694
46952011-08-31 Ed Schonberg <schonberg@adacore.com>
4696
4697 * exp_pakd.adb (Convert_To_PAT_Type): If prefix is a function call, do
4698 not reanalyze it.
4699
47002011-08-31 Bob Duff <duff@adacore.com>
4701
4702 * exp_ch4.adb (Expand_N_Selected_Component): Use the full type, in case
4703 the access type is private; we don't care about privacy in expansion.
4704
47052011-08-31 Ed Schonberg <schonberg@adacore.com>
4706
4707 * sem_aggr.adb (Resolve_Aggregate): In an instance, ignore aggregate
4708 subcomponents tnat may be limited, because they originate in view
4709 conflicts. If the original aggregate is legal and the actuals are
4710 legal, the aggregate itself is legal.
4711
b8789727
AC
47122011-08-31 Matthew Heaney <heaney@adacore.com>
4713
4714 * a-rbtgbo.adb (Clear_Tree): Assert representation invariant for lock
4715 status.
4716
47172011-08-31 Ed Schonberg <schonberg@adacore.com>
4718
4719 * sem_ch5.adb: Set kind of loop parameter properly, to preserve all
4720 errors in B tests.
4721
47222011-08-31 Jose Ruiz <ruiz@adacore.com>
4723
4724 * sem_ch13.adb (Analyze_Aspect_Specifications): For the Priority and
4725 Interrupt_Priority aspects, force the analysis of the aspect expression
4726 (when building the equivalent pragma). Otherwise, its analysis is done
4727 too late, after the task or protected object has been created.
4728 * sem_ch9.adb (Analyze_Single_Protected_Declaration,
4729 Analyze_Single_Task_Declaration): Remove the code to move the aspects
4730 to the object declaration because they are needed in the type
4731 declaration.
4732
e0c32166
AC
47332011-08-31 Robert Dewar <dewar@adacore.com>
4734
4735 * exp_ch5.adb, exp_ch7.ads, sem_ch5.adb, put_scos.adb, s-rannum.adb,
4736 a-rbtgbo.adb, exp_intr.adb, a-cbdlli.adb, a-cbdlli.ads: Minor
4737 reformatting.
4738
47392011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
4740
4741 * exp_util.adb (Find_Protection_Type): Do not look for fields _object
4742 if the corresponding type is malformed due to restriction violations.
4743
47442011-08-31 Robert Dewar <dewar@adacore.com>
4745
4746 * s-ransee.ads, s-ransee.adb: Minor reformatting.
4747
47482011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
4749
4750 * exp_ch4.adb (Expand_N_Allocator): Correct faulty condition which
4751 would cause the generation of Set_Finalize_Address if the target is a
4752 VM and the designated type is not derived from [Limited_]Controlled.
4753
47542011-08-31 Arnaud Charlet <charlet@adacore.com>
4755
4756 * comperr.adb, comperr.ads, gnat1drv.adb (Delete_SCIL_Files): New
4757 subprogram.
4758 (Compiler_Abort, Gnat1drv): Call Delete_SCIL_Files in codepeer mode in
4759 case of a compilation error.
4760
47612011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
4762
4763 * init.c (__gnat_error_handler): Standardize the stack overflow or
4764 erroneous memory access message.
4765 * seh_init.c (__gnat_SEH_error_handler): Standardize the stack overflow
4766 or erroneous memory access message.
4767
11bc76df
AC
47682011-08-31 Robert Dewar <dewar@adacore.com>
4769
4770 * sem_ch4.adb: Minor reformatting.
4771 * sem_ch6.adb: Minor code reorganization (use Ekind_In).
4772
47732011-08-31 Thomas Quinot <quinot@adacore.com>
4774
4775 * scos.ads: Minor documentation clarification.
4776 * put_scos.adb: Do not generate SCO unit header line for a unit that
4777 has no SCO lines.
4778
876d4394
RD
47792011-08-31 Robert Dewar <dewar@adacore.com>
4780
4781 * a-rbtgbo.adb, alfa_test.adb: Minor reformatting.
4782
36b8f95f
AC
47832011-08-31 Tristan Gingold <gingold@adacore.com>
4784
4785 * exp_ch7.ads, exp_ch7.adb (Finalization_Exception_Data): New type to
4786 hold variables between these following subprograms.
4787 (Build_Exception_Handler, Build_Object_Declarations,
4788 Build_Raise_Statement): Use the above type as parameter.
4789 Make the above adjustments.
4790 * exp_intr.adb (Expand_Unc_Deallocation): Adjust.
4791
47922011-08-31 Pascal Obry <obry@adacore.com>
4793
4794 * projects.texi: Minor reformatting.
4795
47962011-08-31 Tristan Gingold <gingold@adacore.com>
4797
4798 * s-ransee.ads, s-ransee.adb: Add system.random_seed unit.
4799 * s-rannum.adb (Reset): Use Get_Seed from s-ransee.
4800
48012011-08-31 Ed Schonberg <schonberg@adacore.com>
4802
4803 * exp_ch5.adb: Minor code cleanup.
4804 * sem_ch5.adb (Analyze_Iteration_Scheme): Set ekind of loop variable to
4805 prevent cascaded errors.
4806 (Analyze_Loop_Statement): In semantics-only mode, introduce loop
4807 variable of an iterator specification in current scope.
4808 * sem_ch6.adb (Analyze_Return_Statement, Find_what_It_Apples_To): Skip
4809 postconditions on the stack, as they contain no return statements.
4810
48112011-08-31 Yannick Moy <moy@adacore.com>
4812
4813 * exp_alfa.adb (Expand_Alfa_N_Package_Declaration,
4814 Expand_Alfa_N_Subprogram_Body): Remove useless procedures which simply
4815 call Qualify_Entity_Names.
4816 (Expand_Alfa): call Qualify_Entity_Names in more cases
4817 * lib-xref-alfa.adb: Take into account system package.
4818 * sem_prag.adb Take into account restrictions in Alfa mode, contrary to
4819 CodePeer mode in which we are interested in finding bugs even if
4820 compiler cannot compile source.
4821 * sem_util.adb, sem_util.ads (Unique_Entity): Take into account case of
4822 deferred constant.
4823
48242011-08-31 Gary Dismukes <dismukes@adacore.com>
4825
4826 * sem_ch3.adb (Constrain_Concurrent): Retrieve Base_Type of the subtype
4827 denoted by the subtype mark to ensure getting the concurrent type in
4828 the case where the subtype mark denotes a private subtype of a
4829 concurrent type (needed when using -gnatc).
4830 (Process_Subtype): For the processing specific to type kinds, case on
4831 the Base_Type kind of the Subtype_Mark_Id, to handle cases where the
4832 subtype denotes a private subtype whose base type is nonprivate (needed
4833 for subtypes of private fulfilled by task types when compiling with
4834 -gnatc).
4835
48362011-08-31 Gary Dismukes <dismukes@adacore.com>
4837
4838 * sem_disp.adb (Check_Dispatching_Operation): Bypass registration of
4839 late primitives that override interface operations when the full
4840 expander is not active, to avoid blowups in Register_Primitive when
4841 types don't have associated secondary dispatch tables.
4842
48432011-08-31 Yannick Moy <moy@adacore.com>
4844
4845 * alfa_test.adb: Code clean up.
4846
48472011-08-31 Marc Sango <sango@adacore.com>
4848
4849 * restrict.adb (Check_SPARK_Restriction): Change Comes_From_Source (N)
4850 by Comes_From_Source (Original_Node (N)) in order to treat also the
4851 nodes which have been rewritten.
4852 * sem_ch4.adb (Analyze_Explicit_Dereference, Analyze_Slice): Guard the
4853 explicit dereference and slice violation in spark mode on the nodes
4854 coming only from the source code.
4855
8cf23b91
AC
48562011-08-31 Robert Dewar <dewar@adacore.com>
4857
4858 * exp_ch5.adb, exp_alfa.ads, prj.ads, sem_attr.adb,
4859 lib-xref-alfa.adb: Minor reformatting.
4860
48612011-08-31 Matthew Heaney <heaney@adacore.com>
4862
4863 * a-crbltr.ads (Tree_Type): Default-initialize the Nodes component.
4864
48652011-08-31 Javier Miranda <miranda@adacore.com>
4866
4867 * sem_ch4.adb (Try_Object_Operation): Addition of one formal to search
4868 only for class-wide subprograms conflicting with entities of concurrent
4869 tagged types.
4870
48712011-08-31 Matthew Heaney <heaney@adacore.com>
4872
4873 * a-rbtgbo.adb (Generic_Allocate): Initialize pointer components of
4874 node to null value.
4875
48762011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
4877
4878 * sem_ch12.adb (Insert_Freeze_Node_For_Instance): Provide a more
4879 general description of the routine.
4880
48812011-08-31 Ed Schonberg <schonberg@adacore.com>
4882
4883 * a-cbdlli.adb, a-cbdlli.ads: Add iterator machinery to bounded
4884 doubly-linked lists.
4885
0bb3bfb8
GD
48862011-08-31 Gary Dismukes <dismukes@adacore.com>
4887
4888 * exp_ch5.adb (Expand_N_Assignment_Statement): When a discriminant
4889 check is needed for a left-hand side that is a dereference, and the
4890 base type is private without discriminants (whereas the full type does
4891 have discriminants), an extra retrieval of the underlying type may be
4892 needed in the case where the subtype is a record subtype whose base
4893 type is private. Update comments.
4894
11fa950b
AC
48952011-08-31 Javier Miranda <miranda@adacore.com>
4896
4897 * sem_ch4.adb (Try_Object_Operation): When a dispatching primitive is
4898 found check if there is a class-wide subprogram covering the primitive.
4899
49002011-08-31 Yannick Moy <moy@adacore.com>
4901
4902 * sem_res.adb: Further cases where full expansion test is needed,
4903 rather than expansion test.
4904
49052011-08-31 Pascal Obry <obry@adacore.com>
4906
4907 * prj-attr.adb: Fix Source_File_Switches attribute kind (must be a list)
4908
49092011-08-31 Ed Schonberg <schonberg@adacore.com>
4910
4911 * exp_ch5.adb: Handle iterators over derived container types.
4912
49132011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
4914
4915 * einfo.ads, einfo.adb: Add new flag Has_Anonymous_Master.
4916 (Has_Anonymous_Master): New routine.
4917 (Set_Has_Anonymous_Master): New routine.
4918 (Write_Entity_Flags): Add an entry for Has_Anonymous_Master.
4919 * exp_ch4.adb: Add with and use clause for Sem_Ch8.
4920 (Current_Anonymous_Master): New routine.
4921 (Current_Unit_First_Declaration): Removed.
4922 (Current_Unit_Scope): Removed.
4923 (Expand_N_Allocator): Anonymous access-to-controlled types now chain
4924 their objects on a per-unit heterogeneous finalization master.
4925
49262011-08-31 Matthew Heaney <heaney@adacore.com>
4927
4928 * a-cbhama.adb, a-cbhase.adb (Insert): Check for zero-length buckets
4929 array.
4930
49312011-08-31 Jose Ruiz <ruiz@adacore.com>
4932
4933 * s-taprop-linux.adb (Create_Task): Avoid changing the affinity mask
4934 when not needed.
4935
49362011-08-31 Gary Dismukes <dismukes@adacore.com>
4937
4938 * sem_disp.adb (Propagate_Tag): Return without propagating in the case
4939 where the actual is an unexpanded call to 'Input.
4940
d2b4b3da
AC
49412011-08-31 Yannick Moy <moy@adacore.com>
4942
4943 * sem_ch4.adb: Code clean up.
4944
49452011-08-31 Yannick Moy <moy@adacore.com>
4946
4947 * exp_alfa.adb, exp_alfa.ads: Minor correction of copyright notice.
4948
49492011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
4950
4951 * exp_ch7.adb (Build_Array_Deep_Procs): Do not generate Deep_Finalize
4952 and TSS primitive Finalize_Address if finalization is suppressed.
4953 (Build_Record_Deep_Procs): Do not generate Deep_Finalize and TSS
4954 primitive Finalize_Address if finalization is suppressed.
4955
49562011-08-31 Jose Ruiz <ruiz@adacore.com>
4957
4958 * s-mudido-affinity.adb, s-taprop-linux.adb, s-taprop-mingw.adb,
4959 s-taprop-solaris.adb, s-taprop-vxworks.adb (Set_Task_Affinity): Make
4960 sure that the underlying task has already been created before trying
4961 to change its affinity.
4962 (Set_CPU): Use the term processor instead of CPU, as we do in
4963 Assign_Task.
4964
49652011-08-31 Vincent Celier <celier@adacore.com>
4966
4967 * prj-attr.adb: New Compiler attribute Source_File_Switches.
4968 * prj-nmsc.adb (Process_Compiler): Process attribute
4969 Source_File_Switches.
4970 * prj.ads (Language_Config): New name list component
4971 Name_Source_File_Switches.
4972 * snames.ads-tmpl (Name_Source_File_Switches): New standard name.
4973
49742011-08-31 Ed Schonberg <schonberg@adacore.com>
4975
4976 * sem_attr.adb (Analyze_Attribute, case 'Old): If prefix may be a
4977 discriminated component of an actual, expand at once to prevent
4978 ouf-of-order references with generated subtypes.
4979
49802011-08-31 Yannick Moy <moy@adacore.com>
4981
4982 * lib-xref-alfa.adb (Add_Alfa_Xrefs): Do not take into account read
4983 reference to operator in Alfa xrefs.
4984
49852011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
4986
4987 * sem_ch12.adb (Freeze_Subprogram_Body): Add code to handle the case
4988 where the parent instance was frozen before the current instance due to
4989 the presence of a source body. Update calls to Insert_After_Last_Decl.
4990 (Insert_After_Last_Decl): Renamed to Insert_Freeze_Node_For_Instance.
4991 Update the comment which illustrates the purpose of the routine.
4992 Package instances are now frozen by source bodies which appear after
4993 the instance. This ensures that entities coming from within the
4994 instance are available for use in the said bodies.
4995 (Install_Body): Add code to handle the case where the parent instance
4996 was frozen before the current instance due to the presence of a source
4997 body. Update calls to Insert_After_Last_Decl.
4998
56812278
AC
49992011-08-31 Jose Ruiz <ruiz@adacore.com>
5000
5001 * s-taprop-linux.adb (Set_Task_Affinity): Avoid the use of anonymous
5002 access types.
5003 * affinity.c (__gnat_set_affinity_mask): Declare index variable.
5004
50052011-08-31 Yannick Moy <moy@adacore.com>
5006
5007 * sem_ch8.adb (Analyze_Subprogram_Renaming): Refine expander test in
5008 full-expander test.
16c3301a
AC
5009 * alfa.adb, alfa.ads, alfa_test.adb, ali.adb, debug.adb, errout.adb,
5010 errout.ads, erroutc.adb, expander.adb, exp_ch4.adb, exp_ch7.adb,
5011 freeze.adb, get_alfa.adb, get_alfa.ads, gnat1drv.adb, lib-writ.adb,
5012 lib-writ.ads, lib-xref.adb, lib-xref.ads, lib-xref-alfa.adb, opt.adb,
5013 opt.ads, put_alfa.adb, put_alfa.ads, restrict.adb, sem_ch12.adb,
5014 sem_ch13.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
5015 sem_prag.adb, sem_res.adb, sem_util.adb: Minor reformatting, renaming
5016 ALFA in Alfa (we dropped acronym).
56812278
AC
5017 * einfo.adb (Primitive_Operations): Correctly return list of primitive
5018 operations in a case where it returned previously No_Elist.
5019
7cda9727
RD
50202011-08-31 Robert Dewar <dewar@adacore.com>
5021
5022 * s-taprop-vxworks.adb, sem_ch5.adb, s-taprop-tru64.adb, exp_alfa.adb,
5023 s-taprop-vms.adb, bindgen.adb, s-mudido.adb, s-mudido.ads,
5024 sem_res.adb, expander.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
5025 s-taprop-solaris.adb, s-mudido-affinity.adb, vms_conv.adb,
5026 s-taprop-irix.adb, s-taprop.ads, s-taskin.adb, s-taskin.ads,
5027 s-taprop-hpux-dce.adb, a-chtgbo.adb, s-taprop-posix.adb: Minor
5028 reformatting.
5029
0a190dfd
AC
50302011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
5031
5032 * sem_ch12 (Check_Private_View): Revert previous change.
5033 * sem_res.adb (Conversion_Check): Do not emit the error message if the
5034 conversion is in a generic instance.
5035
50362011-08-31 Matthew Heaney <heaney@adacore.com>
5037
5038 * a-cbhase.adb (Symmetric_Difference): Dereference correct node array.
5039 * a-chtgbo.adb (Free): Allow 0 as index value.
5040
50412011-08-31 Matthew Heaney <heaney@adacore.com>
5042
5043 * a-cborma.adb (Insert): Add comment to explain why no element
5044 assignment.
5045
50462011-08-31 Gary Dismukes <dismukes@adacore.com>
5047
5048 * sem_util.adb (Find_Body_Discriminal): Test whether the scope of the
5049 spec discriminant is already a concurrent type, in which case just use
5050 it, otherwise fetch the Corresponding_Concurrent_Type as before.
5051
7d266442
EB
50522011-08-30 Eric Botcazou <ebotcazou@adacore.com>
5053
5054 * system-irix-n64.ads, system-linux-armeb.ads, system-linux-armel.ads,
5055 system-linux-mips.ads, system-linux-mipsel.ads,
5056 system-linux-mips64el.ads, system-linux-ppc64.ads,
5057 system-linux-sparcv9.ads, system-rtems.ads: Remove GCC_ZCX_Support.
5058
4f1a975c
EB
50592011-08-30 Eric Botcazou <ebotcazou@adacore.com>
5060
5061 * gcc-interface/ada-tree.h (TYPE_EXTRA_SUBTYPE_P): Add internal check.
5062 * gcc-interface/utils2.c (build_binary_op): Tighten condition.
5063 (build_unary_op): Likewise.
5064
f2991b48
EB
50652011-08-30 Eric Botcazou <ebotcazou@adacore.com>
5066
5067 * raise-gcc.c: Do not include coretypes.h and tm.h.
5068 (setup_to_install): Remove test for compiler macro.
5069 * targext.c: Document use for the library.
5070 * gcc-interface/Makefile.in: Fix comment on the use of IN_GCC.
5071
10a22f43
EB
50722011-08-30 Eric Botcazou <ebotcazou@adacore.com>
5073
5074 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Do not convert
5075 the expression to the nominal type if the latter is a record type with
5076 a variant part and the type of the former is a record type without one.
5077
bfa2e39d
AC
50782011-08-30 Yannick Moy <moy@adacore.com>
5079
5080 * exp_aggr.adb, exp_ch11.adb, exp_prag.adb: Remove early exit during
5081 expansion in Alfa mode.
5082 * exp_ch6.adb, exp_ch6.ads (Expand_Actuals): Make subprogram public
5083 * exp_alfa.adb, exp_alfa.ads: New package defining light expansion for
5084 Alfa mode.
5085 * gnat1drv.adb (Adjust_Global_Switches): Update Comment.
5086 * sem_res.adb: Ditto.
bd34109a 5087 * gcc-interface/Make-lang.in: Update dependencies.
bfa2e39d
AC
5088
50892011-08-30 Thomas Quinot <quinot@adacore.com>
5090
5091 * g-socket.ads: Minor documentation adjustment.
5092
a0347839
AC
50932011-08-30 Robert Dewar <dewar@adacore.com>
5094
5095 * exp_ch9.adb, s-tassta.adb, s-secsta.adb: Minor reformatting.
5096
50972011-08-30 Yannick Moy <moy@adacore.com>
5098
5099 * exp_ch6_light.adb, exp_ch6_light.ads, exp_attr_light.adb,
5100 exp_attr_light.ads, exp_ch7_light.adb, exp_ch7_light.ads,
5101 exp_light.adb, exp_light.ads, exp_prag.adb, expander.adb,
5102 gnat1drv.adb, exp_ch11.adb, exp_ch6.adb, exp_ch6.ads, exp_aggr.adb:
5103 Revert change which introduced files for "light"
5104 expansion, to be replaced by a single file for Alfa expansion.
5105
3597c0e9
RD
51062011-08-30 Robert Dewar <dewar@adacore.com>
5107
5108 * opt.ads, s-soflin.adb, exp_ch9.adb, sem_res.adb: Update comment.
5109 Minor code reorg/reformatting.
5110
da94696d
AC
51112011-08-30 Yannick Moy <moy@adacore.com>
5112
5113 * opt.adb, opt.ads (Full_Expander_Active): New function defines a
5114 common shorthand for (Expander_Active and not ALFA_Mode) that can be
5115 used for testing full expansion, that is active expansion not in the
5116 reduced mode for Alfa
5117 * exp_ch4.adb, exp_ch9.adb, exp_disp.adb, sem_ch10.adb, sem_ch12.adb,
5118 sem_ch6.adb, sem_ch9.adb, sem_res.adb: Use newly defined "flag" instead
5119 of the verbose (Expander_Active and not ALFA_Mode)
5120
51212011-08-30 Tristan Gingold <gingold@adacore.com>
5122
5123 * s-parame-vms-alpha.ads, s-parame-hpux.ads, s-tassta.adb,
5124 s-tarest.adb, s-parame-vms-ia64.ads, s-soflin.adb, s-secsta.adb,
5b8ca141
TG
5125 s-secsta.ads, s-parame.ads, s-parame-vxworks.ads, s-parame-ae653.ads:
5126 Renames Ratio to Percentage, and Sec_Stack_Ratio to Sec_Stack_Percentage
da94696d 5127
c199ccf7
AC
51282011-08-30 Gary Dismukes <dismukes@adacore.com>
5129
5130 * sem_res.adb (Valid_Conversion): Revise test for implicit anonymous
5131 access conversions to check that the conversion is a rewritten node,
5132 rather than just having Comes_From_Source set to False, which wasn't
5133 sufficient.
5134
51352011-08-30 Robert Dewar <dewar@adacore.com>
5136
5137 * exp_ch9.adb, sem_ch9.adb, sem_ch6.adb, exp_disp.adb,
5138 g-socket.ads: Minor reformatting.
5139
51402011-08-30 Thomas Quinot <quinot@adacore.com>
5141
5142 * sem_util.adb: Minor reformatting.
5143
51442011-08-30 Tristan Gingold <gingold@adacore.com>
5145
5146 * raise-gcc.c: Never catch exception if _UA_FORCE_UNWIND flag is set,
5147 to be compliant with the ABI.
5148
dff99e1a
AC
51492011-08-30 Hristian Kirtchev <kirtchev@adacore.com>
5150
5151 * sem_ch12.adb (Check_Private_View): Exchange the private and full view
5152 of a designated type when the related access type is an actual in an
5153 instance. This ensures that the full view of designated type is
5154 available when inside the body of the instance.
5155
51562011-08-30 Ed Schonberg <schonberg@adacore.com>
5157
5158 * sem_util.adb (May_Be_Lvalue): To determine whether a reference may be
5159 in a position to be modified, a slice is treated like an indexed
5160 component.
5161
63be2a5a
AC
51622011-08-30 Thomas Quinot <quinot@adacore.com>
5163
5164 * s-oscons-tmplt.c, g-socket.ads: Adjust maximum allowed value for
5165 field tv_sec in struct timeval.
5166
51672011-08-30 Yannick Moy <moy@adacore.com>
5168
5169 * exp_ch9.adb, exp_disp.adb, sem_ch9.adb, sem_res.adb: Protect several
5170 blocks of code doing full expansion, previously only guarded by
5171 Expander_Active, by anding the test that ALFA_Mode is not set
5172
51732011-08-30 Ed Schonberg <schonberg@adacore.com>
5174
5175 * sem_ch6.adb (Analyze_Return_Type): If the return type is incomplete,
5176 add the function to the list of private dependents, for subsequent
5177 legality check on Taft amendment types.
5178 * sem_ch12.adb (Analyze_Formal_Incomplete_Type): Initialize
5179 Private_Dependents, as for other incomplete types.
5180 * sem_util.adb (Wrong_Type): Avoid cascaded errors when a
5181 Taft-amendment type is used as the return type of a function.
5182
dd54644b
JM
51832011-08-30 Javier Miranda <miranda@adacore.com>
5184
5185 * sem_ch3.adb (Check_Abstract_Overriding): Code cleanup: replace code
5186 which emits an error by a call to a new routine which report the error.
5187 * exp_ch9.adb (Build_Wrapper_Spec): Build the wrapper even if the
5188 entity does not cover an existing interface.
5189 * errout.ads, errout.adb (Error_Msg_PT): New routine. Used to factorize
5190 code.
5191 * sem_ch6.adb (Check_Conformance): Add specific error for wrappers of
5192 protected procedures or entries whose mode is not conformant.
5193 (Check_Synchronized_Overriding): Code cleanup: replace code which emits
5194 an error by a call to a new routine which report the error.
5195
d3ba478e
AC
51962011-08-30 Robert Dewar <dewar@adacore.com>
5197
5198 * gnat_rm.texi: Minor change.
5199 * exp_attr_light.adb: Minor reformatting.
5200
52012011-08-30 Ed Schonberg <schonberg@adacore.com>
5202
5203 * sem_ch3.adb: Patch inheritance of aspects in
5204 Complete_Private_Subtype, to avoid infinite loop.
5205
c01817d2
AC
52062011-08-30 Javier Miranda <miranda@adacore.com>
5207
5208 * sem_ch3.adb (Add_Internal_Interface_Entities): If serious errors have
5209 been reported and a subprogram covering an interface primitive is not
5210 found then skip generating the internal entity. Done to avoid crashing
5211 the frontend.
5212 (Check_Abstract_Overriding): Change text of error of wrong formal of
5213 protected subprogram or entry. Done for consistency to emit exactly the
5214 same error reported by Check_Synchronized_Overriding. In addition, the
5215 error is restricted to protected types (bug found working on AI05-0090)
5216
52172011-08-30 Yannick Moy <moy@adacore.com>
5218
5219 * exp_aggr.adb, exp_ch11.adb, exp_prag.adb: Remove early exit during
5220 expansion in Alfa mode.
5221 * exp_ch6.adb, exp_ch6.ads (Expand_Actuals): Make subprogram public.
5222 * exp_light.adb, exp_light.ads: New package defining light expansion.
5223 * expander.adb (Expand): Call light expansion in Alfa mode
5224 * exp_ch6_light.adb, exp_ch6_light.ads: Light expansion of chapter 6
5225 constructs.
5226 * exp_ch7_light.adb, exp_ch7_light.ads: Light expansion of chapter 7
5227 constructs.
5228 * exp_attr_light.adb, exp_attr_light.ads: Light expansion of attributes
5229 * gnat1drv.adb (Adjust_Global_Switches): Comment
5230
52312011-08-30 Yannick Moy <moy@adacore.com>
5232
5233 * lib-xref-alfa.adb: Minor refactoring.
5234
52352011-08-30 Yannick Moy <moy@adacore.com>
5236
5237 * exp_ch9.adb (Expand_Entry_Barrier): Do not perform expansion in Alfa
5238 mode.
5239 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Do not perform
5240 expansion in Alfa mode.
5241 * sem_ch9.adb (Analyze_Entry_Body): Do not perform expansion in Alfa
5242 mode.
5243
52442011-08-30 Robert Dewar <dewar@adacore.com>
5245
5246 * debug_a.adb: Update comment.
5247
996c8821
RD
52482011-08-30 Robert Dewar <dewar@adacore.com>
5249
5250 * exp_ch5.adb, sem_ch3.adb, sem_ch5.adb, einfo.adb, checks.adb,
5251 sem_util.adb, sem_util.ads, sem_res.adb, s-stposu.adb, sem_attr.adb,
5252 exp_ch4.adb, exp_ch6.adb, lib-xref-alfa.adb,
5253 sem_ch8.adb, sem_disp.adb, exp_ch3.adb: Minor reformatting
5254
52552011-08-30 Robert Dewar <dewar@adacore.com>
5256
5257 * gnat_rm.texi: Add section on C.6(16) implementation advice for pragma
5258 volatile.
5259
3647ca26
HK
52602011-08-30 Hristian Kirtchev <kirtchev@adacore.com>
5261
5262 * exp_ch3.adb (Expand_Freeze_Array_Type): Correct the call to
5263 Build_Finalization_Master by supplying an insertion node and enclosing
5264 scope. In its old version, the call did not generate a finalization
5265 master.
5266 (Expand_Freeze_Record_Type): Add local variable Has_AACC. Add code to
5267 recognize anonymous access-to-controlled components. Rewrite the
5268 machinery which creates finalization masters to service anonymous
5269 access-to-controlled components of a record type. In its current state,
5270 only one heterogeneous master is necessary to handle multiple anonymous
5271 components.
5272 (Freeze_Type): Comment reformatting.
5273 * rtsfind.ads: Add RE_Set_Is_Heterogeneous to tables RE_Id and
5274 RE_Unit_Table.
5275 * s-stposu.adb (Allocate_Any_Controlled): Rewrite the machinery which
5276 associates TSS primitive Finalize_Address with either the master itself
5277 or with the internal hash table depending on the mode of operation of
5278 the master.
5279
6d4e4fbc
JM
52802011-08-30 Javier Miranda <miranda@adacore.com>
5281
5282 * exp_ch3.adb (Make_Eq_If): If the etype of the _parent component is an
5283 interface type then do not generate code to compare this component.
5284 Required since they have no components and their equality operator is
5285 abstract.
5286
d15f9422
AC
52872011-08-30 Steve Baird <baird@adacore.com>
5288
5289 * sem_util.ads (Deepest_Type_Access_Level): New function; for the type
5290 of a saooaaat (i.e, a stand-alone object of an anonymous access type),
5291 returns the (static) accessibility level of the object. Otherwise, the
5292 same as Type_Access_Level.
5293 (Dynamic_Accessibility_Level): New function; given an expression which
5294 could occur as the rhs of an assignment to a saooaaat (i.e., an
5295 expression of an access-to-object type), return the new value for the
5296 saooaaat's associated Extra_Accessibility object.
5297 (Effective_Extra_Accessibility): New function; same as
5298 Einfo.Extra_Accessibility except that object renames are looked through.
5299 * sem_util.adb
5300 (Deepest_Type_Access_Level): New function; see sem_util.ads description.
5301 (Dynamic_Accessibility_Level): New function; see sem_util.ads
5302 description.
5303 (Effective_Extra_Accessibility): New function; see sem_util.ads
5304 description.
5305 * einfo.ads (Is_Local_Anonymous_Access): Update comments.
5306 (Extra_Accessibility): Update comments.
5307 (Init_Object_Size_Align): New procedure; same as Init_Size_Align
5308 except RM_Size field (which is only for types) is unaffected.
5309 * einfo.adb
5310 (Extra_Accessibility): Expand domain to allow objects, not just formals.
5311 (Set_Extra_Accessibility): Expand domain to allow objects, not just
5312 formals.
5313 (Init_Size): Add assertion that we are not trashing the
5314 Extra_Accessibility attribute of an object.
5315 (Init_Size_Align): Add assertion that we are not trashing the
5316 Extra_Accessibility attribute of an object.
5317 (Init_Object_Size_Align): New procedure; see einfo.ads description.
5318 * sem_ch3.adb (Find_Type_Of_Object): Set Is_Local_Anonymous_Access
5319 differently for the type of a (non-library-level) saooaaat depending
5320 whether Ada_Version < Ada_2012. This is the only point where Ada_Version
5321 is queried in this set of changes - everything else (in particular,
5322 setting of the Extra_Accessibility attribute in exp_ch3.adb) is
5323 driven off of the setting of the Is_Local_Anonymous_Access attribute.
5324 The special treatment of library-level saooaaats is an optimization,
5325 not required for correctnesss. This is based on the observation that the
5326 Ada2012 rules (static and dynamic) for saooaaats turn out to be
5327 equivalent to the Ada2005 rules in the case of a library-level saooaaat.
5328 * exp_ch3.adb
5329 (Expand_N_Object_Declaration): If Is_Local_Anonymous_Access is
5330 false for the type of a saooaaat, declare and initialize its
5331 accessibility level object and set the Extra_Accessibility attribute
5332 of the saooaaat to refer to this object.
5333 * checks.adb (Apply_Accessibility_Check): Add Ada 2012 saooaaat support.
5334 * exp_ch4.adb (Expand_N_In): Replace some Extra_Accessibility calls with
5335 calls to Effective_Extra_Accessibility in order to support
5336 renames of saooaaats.
5337 (Expand_N_Type_Conversion): Add new local function,
5338 Has_Extra_Accessibility, and call it when determining whether an
5339 accessibility check is needed.
5340 It returns True iff Present (Effective_Extra_Accessibility (Id)) would
5341 evaluate to True (without raising an exception).
5342 * exp_ch5.adb
5343 (Expand_N_Assignment_Statement): When assigning to an Ada2012
5344 saooaaat, update its associated Extra_Accessibility object (if
5345 it has one). This includes an accessibility check.
5346 * exp_ch6.adb (Add_Call_By_Copy_Code): When parameter copy-back updates
5347 a saooaaat, update its Extra_Accessibility object too (if it
5348 has one).
5349 (Expand_Call): Replace a couple of calls to Type_Access_Level
5350 with calls to Dynamic_Access_Level to handle cases where
5351 passing a literal (any literal) is incorrect.
5352 * sem_attr.adb (Resolve_Attribute): Handle the static accessibility
5353 checks associated with "Saooaat := Some_Object'Access;"; this must
5354 be rejected if Some_Object is declared in a more nested scope
5355 than Saooaat.
5356 * sem_ch5.adb (Analyze_Assignment): Force accessibility checking for an
5357 assignment to a saooaaat even if Is_Local_Anonymous_Access
5358 returns False for its type (indicating a 2012-style saooaaat).
5359 * sem_ch8.adb
5360 (Analyze_Object_Renaming): Replace a call to Init_Size_Align
5361 (which is only appropriate for objects, not types) with a call
5362 of Init_Object_Size_Align in order to avoid trashing the
5363 Extra_Accessibility attribute of a rename (the two attributes
5364 share storage).
5365 * sem_res.adb
5366 (Valid_Conversion) Replace six calls to Type_Access_Level with
5367 calls to Deepest_Type_Access_Level. This is a bit tricky. For an
5368 Ada2012 non-library-level saooaaat, the former returns library level
5369 while the latter returns the (static) accessibility level of the
5370 saooaaat. A type conversion to the anonymous type of a saooaaat
5371 can only occur as part of an assignment to the saooaaat, so we
5372 know that such a conversion must be in a lhs context, so Deepest
5373 yields the result that we need. If such a conversion could occur,
5374 say, as the operand of an equality operator, then this might not
5375 be right. Also add a test so that static accessibilty checks are
5376 performed for converting to a saooaaat's type even if
5377 Is_Local_Anonymous_Access yields False for the type.
5378
53792011-08-30 Javier Miranda <miranda@adacore.com>
5380
5381 * sem_disp.adb (Check_Dispatching_Operation): Complete condition that
5382 controls generation of a warning associated with late declaration of
5383 dispatching functions. Required to avoid generating spurious
5384 warnings.
5385
6cce2156
GD
53862011-08-30 Gary Dismukes <dismukes@adacore.com>
5387
5388 * sem_ch6.adb (Check_Return_Subtype_Indication): Issue error if the
5389 return object has an anonymous access type and the function's type is
5390 a named access type.
5391 * sem_ch8.adb (Analyze_Object_Renaming): Suppress error about renaming
5392 conversions on implicit conversions, since such conversions can occur
5393 for anonymous access cases due to expansion. Issue error for attempt
5394 to rename an anonymous expression as an object of a named access type.
5395 * sem_res.ads (Valid_Conversion): Add defaulted parameter Report_Errs,
5396 to indicate whether this function should report errors on invalid
5397 conversions.
5398 * sem_res.adb (Resolve): For Ada 2012, in the case where the type of
5399 the expression is of an anonymous access type and the expected type is
5400 a named general access type, rewrite the expression as a type
5401 conversion, unless this is an expression of a membership test.
5402 (Valid_Conversion.Error_Msg_N): New procedure that conditions the
5403 calling of Error_Msg_N on new formal Report_Errs.
5404 (Valid_Conversion.Error_Msg_NE): New procedure that conditions the
5405 calling of Error_Msg_NE on new formal Report_Errs.
5406 (Valid_Conversion): Move declaration of this function to the package
5407 spec, to allow calls from membership test processing. For Ada 2012,
5408 enforce legality restrictions on implicit conversions of anonymous
5409 access values to general access types, disallowing such conversions in
5410 cases where the expression has a dynamic accessibility level (access
5411 parameters, stand-alone anonymous access objects, or a component of a
5412 dereference of one of the first two cases).
5413 * sem_type.adb (Covers): For Ada 2012, allow an anonymous access type
5414 in the context of a named general access expected type.
5415 * exp_ch4.adb Add with and use of Exp_Ch2.
5416 (Expand_N_In): Add processing for membership tests applied to
5417 expressions of an anonymous access type. First, Valid_Conversion is
5418 called to check whether the test is statically False, and then the
5419 conversion is expanded to test that the expression's accessibility
5420 level is no deeper than that of the tested type. In the case of
5421 anonymous access-to-tagged types, a tagged membership test is applied
5422 as well.
5423 (Tagged_Membership): Extend to handle access type cases, applying the
5424 test to the designated types.
5425 * exp_ch6.adb (Expand_Call): When creating an extra actual for an
5426 accessibility level, and the actual is a 'Access applied to a current
5427 instance, pass the accessibility level of the type of the current
5428 instance rather than applying Object_Access_Level to the prefix. Add a
5429 ??? comment, since this level isn't quite right either (will eventually
5430 need to pass an implicit level parameter to init procs).
5431
747de90b
AC
54322011-08-30 Bob Duff <duff@adacore.com>
5433
5434 * s-taskin.ads: Minor comment fix.
5435
54362011-08-30 Ed Schonberg <schonberg@adacore.com>
5437
5438 * sem_res.adb (Check_Parameterless_Call): If the node is a selected
5439 component and the selector is a dispatching operation, check if it is
5440 a prefixed call before rewriting as a parameterless function call.
5441
cdc4cc65
JJ
54422011-08-29 Jakub Jelinek <jakub@redhat.com>
5443
5444 * gcc-interface/Makefile.in (../stamp-gnatlib1-$(RTSDIR)): Copy
5445 tsystem.h into $(RTSDIR) instead of rts.
5446
226a7fa4
AC
54472011-08-29 Robert Dewar <dewar@adacore.com>
5448
5449 * sem_ch10.adb, a-coorse.adb, exp_dist.adb, exp_ch3.adb: Minor
5450 reformatting.
5451 * gcc-interface/Make-lang.in: Update dependencies.
5452
54532011-08-29 Yannick Moy <moy@adacore.com>
5454
5455 * alfa.ads (Name_Of_Heap_Variable): New constant name.
5456 * lib-xref-alfa.adb, lib-xref.adb, lib-xref.ads (Drefs): New global
5457 table to hold dereferences.
5458 (Add_ALFA_Xrefs): Take into account dereferences as special
5459 reads/writes to the variable "HEAP".
5460 (Enclosing_Subprogram_Or_Package): Move subprogram here.
5461 (Generate_Dereference): New procedure to store a read/write dereferencew
5462 in the table Drefs.
5463 * put_alfa.adb (Put_ALFA): Use different default than (0,0) used for
5464 the special "HEAP" var.
5465 * sem_ch4.adb (Analyze_Explicit_Dereference): Store read dereference
5466 in ALFA mode.
5467 * sem_util.adb (Note_Possible_Modification): Store write dereference
5468 in ALFA mode.
5469
dfbcb149
HK
54702011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5471
5472 * exp_ch3.adb (Freeze_Type): Generate an accessibility check which
5473 ensures that the level of the subpool access type is not deeper than
5474 that of the pool object.
5475 * sem_util.adb (Object_Access_Level): Expand to handle defining
5476 identifiers.
5477 * sem_res.adb (Resolve_Allocator): Add a guard to avoid examining the
5478 subpool handle name of a rewritten allocator.
5479
1df4f514
AC
54802011-08-29 Robert Dewar <dewar@adacore.com>
5481
5482 * impunit.adb, exp_ch4.adb, s-finmas.adb: Minor reformatting.
5483
54842011-08-29 Thomas Quinot <quinot@adacore.com>
5485
5486 * exp_dist.adb (TC_Rec_Add_Process_Element): For a choice with multiple
5487 values, we generate multiple triples of parameters in the TypeCode.
5488 Bump Choice_Index for each such triple so that a subsequent default
5489 choice is associated with the correct index in the typecode.
5490
54912011-08-29 Ed Schonberg <schonberg@adacore.com>
5492
5493 * a-cdlili.adb (Iterate): Initialize properly an iterator over a null
5494 container.
5495 (First, Last): Handle properly an iterator over a null container.
5496
54972011-08-29 Bob Duff <duff@adacore.com>
5498
5499 * sem_ch10.adb (Analyze_With_Clause,Install_Withed_Unit): Abandon
5500 processing if we run across a node with no Scope. This can happen if
5501 we're with-ing an library-level instance, and that instance got errors
5502 that caused "instantiation abandoned".
5503 * sem_util.adb (Unit_Declaration_Node): Make it more robust, by raising
5504 an exception instead of using Assert, so it won't go into an infinite
5505 loop, even when assertions are turned off.
5506
55072011-08-29 Ed Schonberg <schonberg@adacore.com>
5508
5509 * a-coorse.adb: Proper handling of empty ordered sets.
5510
14f0f659
AC
55112011-08-29 Johannes Kanig <kanig@adacore.com>
5512
5513 * debug.adb: Add comments.
5514
8027b455
AC
55152011-08-29 Thomas Quinot <quinot@adacore.com>
5516
5517 * a-except.adb, a-except-2005.adb: Minor comment rewording and
5518 reformatting.
5519
55202011-08-29 Yannick Moy <moy@adacore.com>
5521
5522 * sem_ch3.adb (Array_Type_Declaration): Remove insertion of
5523 declaration for Itypes in Alfa mode.
5524
d85fd922
AC
55252011-08-29 Robert Dewar <dewar@adacore.com>
5526
5527 * a-cdlili.ads, a-coinve.ads, a-coorma.adb, a-coorma.ads, s-tassta.adb,
5528 a-cborma.adb, a-cborma.ads, a-cohama.ads, a-coorse.ads, a-cbhama.ads,
5529 a-cborse.ads, a-cobove.adb, a-cobove.ads, a-cbhase.ads: Minor
5530 reformatting.
5531
55322011-08-29 Tristan Gingold <gingold@adacore.com>
5533
5534 * exp_ch7.adb, exp_ch7.ads (Build_Exception_Handler): Move its spec to
5535 package spec.
5536 * exp_intr.adb (Expand_Unc_Deallocation): Use Build_Exception_Handler.
5537 * a-except.adb, a-except-2005.adb (Rcheck_22): Do not defer aborts
5538 while raising PE.
5539
fd3d2680
AC
55402011-08-29 Robert Dewar <dewar@adacore.com>
5541
5542 * a-cbhama.adb, a-cbhama.ads: Minor reformatting.
5543
55442011-08-29 Javier Miranda <miranda@adacore.com>
5545
5546 * sem_ch8.adb (Analyze_Subprogram_Renaming): Complete support for
5547 renamings of formal subprograms when the actual for a formal type is
5548 class-wide.
5549
dfbf013f
MH
55502011-08-29 Matthew Heaney <heaney@adacore.com>
5551
5552 * a-cbhama.ads, a-cbhase.ads (Move): Clear Source following assignment
5553 to Target.
5554
55552011-08-29 Matthew Heaney <heaney@adacore.com>
5556
5557 * a-cborma.ads, a-cborse.ads (Cursor): Default-initialize all
5558 components of record type.
5559 * a-cborma.adb, a-cborse.adb (Move): Clear Source following assignmentw
5560 to Target.
5561
a6dd3a54
ES
55622011-08-29 Ed Schonberg <schonberg@adacore.com>
5563
5564 * a-cbhama.adb, a-cbhama.ads, a-cborma.adb, a-cborma.ads, a-cobove.adb,
5565 a-cobove.ads, a-coorma.adb, a-coorma.ads: Add iterator machinery to
5566 container packages.
5567
c54796e0
AC
55682011-08-29 Robert Dewar <dewar@adacore.com>
5569
5570 * sem_ch3.adb, sem_util.adb, gnat1drv.adb, s-parint.ads: Minor
5571 reformatting.
5572
55732011-08-29 Matthew Heaney <heaney@adacore.com>
5574
5575 * a-cbhama.ads, a-cbhase.ads (Cursor): Default-initialize all
5576 components of record type.
5577
55782011-08-29 Bob Duff <duff@adacore.com>
5579
5580 * s-tassta.adb (Task_Wrapper): Handle and ignore exceptions propagated
5581 by the termination handler.
5582
9fd9d2be
AC
55832011-08-29 Yannick Moy <moy@adacore.com>
5584
5585 * sem_ch3.adb (Array_Type_Declaration): Create declarations for Itypes
5586 created in Alfa mode, instead of inserting artificial declarations of
5587 non-Itypes in the tree.
5588 * sem_util.adb, sem_util.ads (Itype_Has_Declaration): New function to
5589 know if an Itype has a corresponding declaration, as defined in
5590 itypes.ads.
5591
55922011-08-29 Yannick Moy <moy@adacore.com>
5593
5594 * gnat1drv.adb: Minor rewrite.
5595
55962011-08-29 Bob Duff <duff@adacore.com>
5597
5598 * s-tasuti.adb (Make_Passive): Work around race condition in
5599 Make_Independent, which can cause Wait_Count to be zero. So instead of
5600 asserting that Wait_Count > 0, and then decrementing it, decrement it
5601 only if Wait_Count > 0.
5602 * s-taskin.ads (Wait_Count, Alive_Count, Awake_Count): All of these
5603 should be nonnegative, so declare them Natural instead of Integer.
5604
833eaa8a
AC
56052011-08-29 Robert Dewar <dewar@adacore.com>
5606
5607 * exp_ch5.adb, sem_ch3.adb, a-cihama.adb, a-cihama.ads, exp_ch7.adb,
5608 sem_ch5.adb, a-ciorse.adb, a-ciorse.ads, sem_ch12.adb, a-cidlli.adb,
5609 a-cidlli.ads, sem_util.adb, sem_res.adb, gnat1drv.adb, a-except.adb,
5610 a-except.ads, a-except-2005.ads, sem_ch4.adb, exp_disp.adb,
5611 exp_aggr.adb, sem_ch13.adb, par-ch3.adb: Minor reformatting.
5612
56132011-08-29 Tristan Gingold <gingold@adacore.com>
5614
5615 * s-auxdec-vms-alpha.adb: Add comments, remove some HT before labels.
5616
56172011-08-29 Vadim Godunko <godunko@adacore.com>
5618
5619 * s-parint.ads: Minor comment clarification.
5620
56212011-08-29 Vincent Celier <celier@adacore.com>
5622
5623 * prj.adb (Initialize): Make sure that new reserved words after Ada 95
5624 may be used as identifiers.
5625
56262011-08-29 Ed Schonberg <schonberg@adacore.com>
5627
5628 * a-coinho.ads: Minor reformating.
5629
3a613a36
AC
56302011-08-29 Ed Schonberg <schonberg@adacore.com>
5631
5632 * exp_ch5.adb (Expand_Iterator_Loop): Handle properly a loop over a
5633 container of a derived type.
5634
3a613a36
AC
56352011-08-29 Ed Schonberg <schonberg@adacore.com>
5636
5637 * a-cidlli.adb, a-cidlli.ads, a-cihama.adb, a-cihama.ads,
5638 a-ciorse.adb, a-ciorse.ads: Add iterator machinery to containers.
5639
14848f57
AC
56402011-08-29 Pascal Obry <obry@adacore.com>
5641
5642 * exp_disp.adb: Minor comment fix.
5643 (Make_Disp_Asynchronous_Select_Body): Properly initialize out parameters
5644 to avoid warnings when compiling with -Wall.
5645 (Make_Disp_Conditional_Select_Body): Likewise.
5646 (Make_Disp_Timed_Select_Body): Likewise.
5647
56482011-08-29 Ed Schonberg <schonberg@adacore.com>
5649
5650 * sem_ch12.adb (Analyze_Formal_Subprogram_Declaration): If default is
5651 an entity name, generate reference for it.
5652
56532011-08-29 Ed Schonberg <schonberg@adacore.com>
5654
5655 * exp_ch5.adb (Expand_Iterator_Loop): Uniform handling of "X of S"
5656 iterator form.
5657 * sem_util.adb (Is_Iterator, Is_Reversible_Iterator): Yield True for
5658 the class-wide type.
5659 * sem_ch5.adb: Move some rewriting to the expander, where it belongs.
5660
56612011-08-29 Ed Schonberg <schonberg@adacore.com>
5662
5663 * sem_ch8.adb (Check_Constrained_Object): Do not create an actual
5664 subtype for an object whose type is an unconstrained union.
5665
56662011-08-29 Ed Schonberg <schonberg@adacore.com>
5667
5668 * par-ch3.adb (P_Array_Type_Definiation, P_Component_Items): "aliased"
5669 is allowed in a component definition, by AI95-406.
5670
56712011-08-29 Matthew Heaney <heaney@adacore.com>
5672
5673 * a-chtgbo.adb (Generic_Iteration): Use correct overloading of Next.
5674
56752011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5676
5677 * a-except-2005.adb: Alphabetize all routines.
5678 (Triggered_By_Abort): New routine.
5679 * a-except-2005.ads (Triggered_By_Abort): New routine.
5680 * a-except.adb Alphabetize all routines.
5681 (Triggered_By_Abort): New routine.
5682 * a-except.ads (Triggered_By_Abort): New routine.
5683 * exp_ch7.adb: Update all comments involving the detection of aborts in
5684 finalization code.
5685 (Build_Object_Declarations): Do not generate code to detect the
5686 presence of an abort at the start of finalization code, use a runtime
5687 routine istead.
5688 * rtsfind.ads: Add RE_Triggered_By_Abort to tables RE_Id and
5689 RE_Unit_Table.
5690 * sem_res.adb (Resolve_Allocator): Emit a warning when attempting to
5691 allocate a task on a subpool.
5692 * s-stposu.adb: Add library-level flag Finalize_Address_Table_In_Use.
5693 The flag disables all actions related to the maintenance of
5694 Finalize_Address_Table when subpools are not in use.
5695 (Allocate_Any_Controlled): Signal the machinery that subpools are in
5696 use.
5697 (Deallocate_Any_Controlled): Do not call Delete_Finalize_Address which
5698 performs costly task locking when subpools are not in use.
5699
57a8057a
AC
57002011-08-29 Yannick Moy <moy@adacore.com>
5701
5702 * gnat1drv.adb (Adjust_Global_Switches): Restore expansion of tagged
5703 types and dispatching calls in Alfa mode.
5704 * lib-xref-alfa.adb (Collect_ALFA): Rewrite computation of
5705 correspondance between body and spec scopes, to reuse utility functions
5706 (Traverse_Declarations_Or_Statements): Protect access to body for stub
5707 by testing the presence of the library unit for the body
5708 * sem_ch6.adb (Set_Actual_Subtypes): take into account that in Alfa
5709 mode the expansion of accept statements is skipped
5710 * sem_util.adb, sem_util.ads (Unique_Entity): New function returning
5711 the unique entity corresponding to the one returned by
5712 Unique_Defining_Entity applied to the enclosing declaration of the
5713 argument.
5714
57152011-08-29 Bob Duff <duff@adacore.com>
5716
5717 * treepr.ads: Improve debugging facilities. pn(x) no longer crashes in
5718 gdb when x is not a node (it can be a node list, name_id, etc). pp is
5719 an alias for pn. ppp is an alias for pt.
5720
57212011-08-29 Javier Miranda <miranda@adacore.com>
5722
5723 * exp_aggr.adb (Expand_Record_Aggregate): Use the top-level enclosing
5724 aggregate to take a consistent decision on the need to convert into
5725 assignments aggregates that initialize constant objects.
5726
57272011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5728
5729 * exp_ch4.adb (Expand_Allocator_Expression): Add a call to
5730 Build_Allocate_Deallocate_Proc in order to handle allocation of
5731 non-controlled objects on subpools.
5732 * impunit.adb: Remove s-finmas and s-spsufi since they were never meant
5733 to be end-user visible.
5734 * s-finmas.adb: Add with and use clause for System.HTable.
5735 Add an instantiation of Simple_HTable which provides a mapping between
5736 the address of a controlled object and the corresponding
5737 Finalize_Address used to clean up the object. The table is used when a
5738 master is operating in heterogeneous mode.
5739 (Attach): Explain why the input node is not verified on being already
5740 attached.
5741 (Delete_Finalize_Address): New routine.
5742 (Detach): Add pragma Assert which ensures that a node is already
5743 attached.
5744 (Finalize): Add local variable Cleanup. Rewrite the iteration scheme
5745 since nodes are no longer removed on traversal. Explain why node
5746 detachment is undesirable in this case.
5747 (Get_Finalize_Address): New routine.
5748 (Hash): New routine.
5749 (Is_Empty_List): Removed.
5750 (pm): Renamed to Print_Master. Add output for discriminant
5751 Is_Homogeneous.
5752 Comment reformatting.
5753 (Set_Finalize_Address (Address, Finalize_Address_Ptr)): New routine.
5754 * s-finmas.ads: Various comments additions / improvements.
5755 Type Finalization_Master has a discriminant which determines the mode of
5756 operation.
5757 (Delete_Finalize_Address): New routine.
5758 (Get_Finalize_Address): New routine.
5759 (pm): Renamed to Print_Master.
5760 (Set_Finalize_Address (Address, Finalize_Address_Ptr)): New routine.
5761 * s-stposu.adb: Add with clause for System.Address_Image; Add with and
5762 use clause for System.IO.
5763 (Allocate_Any_Controlled): Add machinery to set TSS primitive
5764 Finalize_Address depending on the mode of allocation and the mode of
5765 the master.
5766 (Deallocate_Any_Controlled): Remove the relation pair object -
5767 Finalize_Address regardless of the master mode. Add comment explaining
5768 the reason.
5769 (Detach): Ensure that fields Prev and Next are null after detachment.
5770 (Finalize_Pool): Remove local variable Next_Ptr. Rewrite the iteration
5771 scheme to check whether the list of subpools is empty. There is no
5772 longer need to store the next subpool or advance the current pointer.
5773 (Is_Empty_List): New routine.
5774 (Print_Pool): New routine.
5775 (Print_Subpool): New routine.
5776 * s-stposu.ads: Various comments additions / improvements.
5777 Field Master of type Root_Subpool is now a heterogeneous collection.
5778 (Print_Pool): New routine.
5779 (Print_Subpool): New routine.
5780
57812011-08-29 Ed Schonberg <schonberg@adacore.com>
5782
5783 * exp_ch5.adb (Expand_N_Iterator_Loop): Implement Ada2012 loop iterator
5784 forms, using aspects of container types.
5785 * sem_ch3.adb (Find_Type_Name): Preserve Has_Delayed_Aspects and
5786 Has_Implicit_Dereference flags, that may be set on the partial view.
5787 * sem_ch4.adb (Process_Overloaded_Indexed_Component): Prefix may be a
5788 container type with an indexing aspect.
5789 (Analyze_Quantified_Expression): Analyze construct with expansion
5790 disabled, because it will be rewritten as a loop during expansion.
5791 (Try_Container_Indexing): The prefix itself may be a container type
5792 with an indexing aspect, as with a vector of vectors.
5793 * sem_ch5.adb (Analyze_Iteration_Scheme): In a generic context, analyze
5794 the original doamin of iteration, for name capture.
5795 (Analyze_Iterator_Specification): If the domain is an expression that
5796 needs finalization, create a separate declaration for it.
5797 For an iterator with "of" retrieve default iterator info from aspect of
5798 container type. For "in" iterator, retrieve type of Iterate function.
5799 * sem_ch13.adb (Check_Iterator_Function): Fix typo.
5800 (Check_Aspect_At_End_Of_Declaration): Make type unfrozen before
5801 analysis, to prevent spurious errors about late attributes.
5802 * sprint.adb: Handle quantified expression with either loop or iterator
5803 specification.
5804 * a-convec.ads, a-convec.adb: Iterate function returns a reversible
5805 iterator.
5806
ddf67a1d
AC
58072011-08-29 Vincent Celier <celier@adacore.com>
5808
5809 * make.adb (Scan_Make_Arg): Take any option as is in packages Compiler,
5810 Binder or Linker of the main project file.
5811
58122011-08-29 Ed Schonberg <schonberg@adacore.com>
5813
5814 * inline.adb (Add_Scopes_To_Clean): Exclude any entity within a generic
5815 unit.
5816
58172011-08-29 Yannick Moy <moy@adacore.com>
5818
5819 * exp_ch9.adb: Partial revert of previous change for Alfa mode
5820
58212011-08-29 Yannick Moy <moy@adacore.com>
5822
5823 * exp_ch11.adb: Minor expansion of comment.
5824
58252011-08-29 Yannick Moy <moy@adacore.com>
5826
5827 * lib-xref-alfa.adb (Add_ALFA_Scope): Treat generic entities.
5828
58292011-08-29 Ed Schonberg <schonberg@adacore.com>
5830
5831 * sem_res.adb (Resolve_Arithmetic_Op): If the node has a universal
5832 interpretation, set the type before resolving the operands, because
5833 legality checks on an exponention operand need to know the type of the
5834 context.
5835
58362011-08-29 Ed Schonberg <schonberg@adacore.com>
5837
5838 * sem_ch12.adb (Analyze_Package_Instantiation): Do not set delayed
5839 cleanups on a master if the instance is within a generic unit.
5840 Complement to the corresponding fix to inline.adb for K520-030.
5841
58422011-08-29 Tristan Gingold <gingold@adacore.com>
5843
5844 * exp_ch7.adb (Build_Raise_Statement): Raise PE instead of the current
5845 occurrence.
5846 * exp_intr.adb: Minor comment fix.
5847
58482011-08-29 Bob Duff <duff@adacore.com>
5849
5850 * sem_ch13.adb (Analyze_Aspect_Specifications): Fix cases where
5851 Delay_Required was used as an uninitialized variable.
5852
690943fc
RD
58532011-08-29 Robert Dewar <dewar@adacore.com>
5854
5855 * a-cdlili.adb, a-cdlili.ads, a-coinve.adb, a-coinve.ads,
5856 sem_util.adb, sem_util.ads, a-cohama.adb, a-cohama.ads, a-coorse.adb,
5857 a-coorse.ads, aspects.ads, sem_ch8.adb: Minor reformatting.
5858
9f0ee988
TQ
58592011-08-29 Thomas Quinot <quinot@adacore.com>
5860
5861 * system-freebsd-x86_64.ads (Backend_Overflow_Checks): Set true True.
5862 Remove unused variables.
5863
3e24afaa
AC
58642011-08-29 Ed Schonberg <schonberg@adacore.com>
5865
5866 * sem_res.adb: Remove Build_Explicit_Dereference.
5867 * sem_util.adb, sem_util.ads (Build_Explicit_Dereference): Moved here
5868 from sem_res.adb, used in analysis of additional constructs.
5869 (Is_Iterator, Is_Reversible_Iterator): New predicates for Ada2012
5870 expansion of iterators.
5871 (Is_Object_Reference): Recognize variables rewritten as explicit
5872 dereferences in Ada2012.
5873 * snames.ads-tmpl: Add Has_Element, Forward_Iterator,
5874 Reversible_Iterator names, for expansion of Ada2012 iterators.
5875 * aspects.ads, aspects.adb (Find_Aspect): Utility.
5876 * a-cdlili.ads, a-cdlili.adb: Add new iterator machinery to doubly
5877 linked list container.
5878 * a-coinve.ads, a-coinve.adb: Ditto for indefinite vector containers.
5879 * a-coorse.ads, a-coorse.adb: Ditto for ordered sets.
5880
58812011-08-29 Ed Schonberg <schonberg@adacore.com>
5882
5883 * a-cohama.adb, a-cohama.ads: Add iterator primitives to hashed map
5884 containers.
5885
58862011-08-29 Vincent Celier <celier@adacore.com>
5887
5888 * make.adb (Gnatmake): Get the maximum number of simultaneous
5889 compilation processes after the Builder switches has been scanned, as
5890 there may include -jnn.
5891
58922011-08-29 Matthew Heaney <heaney@adacore.com>
5893
5894 * a-chtgbo.adb (Generic_Equal): Use correct overloading of Next.
5895
58962011-08-29 Tristan Gingold <gingold@adacore.com>
5897
5898 * gnatcmd.adb (GNATCmd): On OpenVMS, truncate the length of
5899 GNAT_DRIVER_COMMAND_LINE to 255.
5900
59012011-08-29 Pascal Obry <obry@adacore.com>
5902
5903 * freeze.adb, sem_ch8.adb, a-convec.adb, a-convec.ads: Minor
5904 reformatting and style fix (class attribute casing).
5905
59062011-08-29 Yannick Moy <moy@adacore.com>
5907
5908 * exp_ch11.adb: Yet another case where expansion should be common
5909 between CodePeer and Alfa.
5910
59112011-08-29 Yannick Moy <moy@adacore.com>
5912
5913 * exp_ch9.adb: Partial revert of previous change for Alfa mode.
5914
59152011-08-29 Ed Schonberg <schonberg@adacore.com>
5916
5917 * sem_ch6.adb (Matches_Limited_With_View): The limited views of an
5918 incomplete type and its completion match.
5919
3ddd922e
AC
59202011-08-29 Yannick Moy <moy@adacore.com>
5921
5922 * exp_ch13.adb: Adjust previous change.
5923
59242011-08-29 Robert Dewar <dewar@adacore.com>
5925
5926 * sem_prag.adb, prj.adb, sem_util.adb, sem_res.adb, gnat1drv.adb,
5927 exp_ch4.adb, sem_ch8.adb: Minor code reorganization
5928 Minor reformatting.
5929
444acbdd
AC
59302011-08-29 Emmanuel Briot <briot@adacore.com>
5931
5932 * make.adb, prj.adb, prj.ads (Compute_All_Imported_Projects): Also
5933 initialize aggregated projects.
5934
59352011-08-29 Ed Schonberg <schonberg@adacore.com>
5936
5937 * sem_ch8.adb (Find_Renamed_Entity): Within an instance, use scope
5938 depth of candidates to resolve a potentially spurious ambiguity between
5939 two visible subprograms.
5940
e0296583
AC
59412011-08-29 Yannick Moy <moy@adacore.com>
5942
5943 * sem_prag.adb (Analyze_Pragma): Allow Test_Case pragma without
5944 Requires/Ensures.
5945 * sem_util.adb (Get_Ensures_From_Test_Case_Pragma,
5946 Get_Requires_From_Test_Case_Pragma): Allow Test_Case pragma without
5947 Requires/Ensures.
5948
59492011-08-29 Arnaud Charlet <charlet@adacore.com>
5950
5951 * gnat1drv.adb (Adjust_Global_Switches): Improve previous change.
5952 Add comment.
5953
59542011-08-29 Thomas Quinot <quinot@adacore.com>
5955
5956 * sem_res.adb: Minor reformatting.
5957
69794413
JK
59582011-08-29 Johannes Kanig <kanig@adacore.com>
5959
5960 * exp_ch4.adb (Expand_Quantified_Expression): Do not expand in ALFA
5961 mode.
5962 * gnat1drv.adb (Adjust_Global_Switches): Set
5963 Use_Expressions_With_Actions to False in ALFA mode.
5964 * sem_res.adb (Resolve_Quantified_Expression): Simpler treatment in
5965 ALFA mode.
5966
59e6b23c
AC
59672011-08-29 Yannick Moy <moy@adacore.com>
5968
5969 * exp_ch13.adb (Expand_N_Freeze_Entity): Do nothing in Alfa mode.
5970 * exp_ch9.adb: Do not expand tasking constructs in Alfa mode.
5971 * gnat1drv.adb (Adjust_Global_Switches): Suppress the expansion of
5972 tagged types and dispatching calls in Alfa mode.
5973
59742011-08-29 Javier Miranda <miranda@adacore.com>
5975
5976 * sem_ch3.adb (Process_Discriminants): Add missing check to ensure that
5977 we do not report an error on an Empty node.
5978
59792011-08-29 Geert Bosch <bosch@adacore.com>
5980
5981 * Makefile.rtl (GNATRTL_NONTASKING_OBJECTS): Add a-nllrar.o,
5982 a-nlrear.o and a-nurear.o.
5983
59842011-08-29 Robert Dewar <dewar@adacore.com>
5985
5986 * freeze.adb: Minor code reorganization.
5987 Minor reformatting.
5988 * sem_util.adb, errout.adb, exp_ch11.adb, a-ngrear.adb, s-gearop.adb,
5989 sem_ch6.adb: Minor reformatting
5990
59912011-08-29 Tristan Gingold <gingold@adacore.com>
5992
5993 * s-except.ads, s-except.adb: Provide dummy body.
5994
59952011-08-29 Yannick Moy <moy@adacore.com>
5996
5997 * sem_warn.adb (Within_Postcondition): Take into account the case of
5998 an Ensures component in a Test_Case.
5999
4d792549
AC
60002011-08-29 Tristan Gingold <gingold@adacore.com>
6001
6002 * s-excdeb.ads, s-excdeb.adb: New files, created from s-except.
6003 * rtsfind.ads (RTU_Id): Replaces System_Exceptions by
6004 System_Exceptions_Debug
6005 (RE_Unit_Table): Search RE_Local_Raise in System_Exceptions_Debug
6006 * a-except.adb: With and use System.Exceptions_Debug instead of
6007 System.Exceptions.
6008 * a-except-2005.adb: Likewise.
6009 * s-assert.adb: Likewise.
6010 * s-except.adb, s-except.ads: Move debugging hooks to s-excdeb.
6011 * Makefile.rtl: Add s-excdeb. Adjust compilation rule.
6012 * gcc-interfaces/Makefile.in, gcc-interface/Make-lang.in: Add
6013 s-excdeb. Update dependencies.
6014 (GNATRTL_LINEARALGEBRA_OBJS): Remove a-nlrear.o a-nurear.o a-nllrar.o
6015 as these no longer need external libraries.
6016
60172011-08-29 Ed Schonberg <schonberg@adacore.com>
6018
6019 * sem_res.adb (Resolve_Op_Expon): Additional check to reject an
6020 exponentiation operator on universal values in a context that requires
6021 a fixed-point type.
6022
60232011-08-29 Tristan Gingold <gingold@adacore.com>
6024
6025 * raise-gcc.c (personnality_routine): Fix thinko. Set Ada occurrence
6026 before calling notify_handled_exception.
6027 * a-exextr.adb: Fix comment.
6028
b254da66
AC
60292011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
6030
6031 * exp_ch4.adb (Expand_Allocator_Expression): Add code to set attribute
6032 Finalize_Address of the access type's finalization master.
6033 (Expand_N_Allocator): Add code to set attribute Finalize_Address of the
6034 access type's finalization master. Add a guard to prevent
6035 Associated_Storage_Pool from being set on .NET/JVM.
6036 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Add code to set
6037 attribute Finalize_Address of the access type's finalization master.
6038 * exp_ch7.adb (Make_Finalize_Address_Call): New routine.
6039 * exp_ch7.ads (Make_Finalize_Address_Call): New routine.
6040 * rtsfind.ads: Add RE_Set_Finalize_Address to tables RE_Id and
6041 RE_Unit_Table.
6042 * s-finmas.adb: Add with clause for System.Address_Image. Add with and
6043 use clause for System.IO
6044 (Detach): Relax the assertion, to be reinstated later.
6045 (Finalize): Rewrite the iteration loop to avoid pointer comparison.
6046 Relax the assertion on Finalize_Address, to be reinstated later.
6047 (Is_Empty_List): New routine.
6048 (pm): New debug routine.
6049 (Set_Finalize_Address): New routine.
6050 * s-finmas.ads (pm): New debug routine.
6051 (Set_Finalize_Address): New routine.
6052 * s-stposu.adb (Allocate_Any_Controlled): Code reformatting.
6053
60542011-08-29 Tristan Gingold <gingold@adacore.com>
6055
6056 * a-exexpr-gcc.adb (GCC_Exception_Access, GNAT_GCC_Exception_Access):
6057 Remove convention C.
6058
60592011-08-29 Tristan Gingold <gingold@adacore.com>
6060
6061 * s-taprop-vms.adb (Get_Exc_Stack_Addr): Remove.
6062 (Initialize_TCB): Remove Exc_Stack_Ptr initialization.
6063 (Finalize_TCB): Remove its finalization.
6064 (Initialize): Remove assignment of GET_Exc_Stack_Addr
6065 * s-soflin.adb (NT_Exc_Stack): Remove
6066 (Get_Exc_Stack_Addr_NT): Likewise.
6067 (Get_Exc_Stack_Addr_Soft): Likewise.
6068 * s-soflin.ads (Get_Exc_Stack_Addr_NT): Remove.
6069 (Get_Exc_Stack_Addr): Likewise.
6070 (Get_Exc_Stack_Addr_Soft): Likewise
6071 * s-taspri-vms.ads (Exc_Stack_T): Remove.
6072 (Exc_Stack_Ptr_T): Likewise.
6073 (Private_Data): Remove Exc_Stack_Ptr component.
6074
60752011-08-29 Tristan Gingold <gingold@adacore.com>
6076
6077 * raise-gcc.c (get_ip_from_context): New function. Factorize code.
6078
60792011-08-29 Tristan Gingold <gingold@adacore.com>
6080
6081 * gnat_ugn.texi: Fix aix and x86-solaris info for run-time.
6082
60832011-08-29 Geert Bosch <bosch@adacore.com>
6084
6085 * s-gearop.ads (Back_Substitute, Diagonal, Forward_Eliminate,
6086 L2_Norm, Swap_Column): New generic subprograms
6087 * s-gearop.adb (Back_Substitute, Diagonal, Forward_Eliminate,
6088 L2_Norm, Swap_Column): Implement new subprograms in order to
6089 eliminate dependency on BLAS and LAPACK libraries in
6090 Ada.Numerics.Generic_Real_Arrays and eventually also the complex
6091 version. Forward_Eliminate/Back_Substitute can be used to put a
6092 matrix in row echelon or reduced row echelon form using partial
6093 pivoting.
6094 * a-ngrear.adb: (Back_Substitute, Diagonal, Forward_Eleminate,
6095 Swap_Column): Instantiate from System.Generic_Array_Operations.
6096 ("*", "abs"): Implement by instantiation from Generic_Array_Operations.
6097 (Sqrt): Local function for simple computation of square root without
6098 adding dependencies on Generic_Elementary_Functions.
6099 (Swap): New subprogram to exchange floating point numbers.
6100 (Inverse): Reimplement using Jordan-Gauss elimination.
6101 (Jacobi): New procedure implementing Jacobi's method for computation
6102 of eigensystems, based on Rutishauser's implementation.
6103 (L2_Norm): Implement directly using the inner product.
6104 (Sort_Eigensystem): Sort eigenvalue/eigenvector pairs in order of
6105 decreasing eigenvalue as required by the Ada RM.
6106 (Swap_Column): New helper procedure for Sort_Eigensystem.
6107 Remove with of System.Generic_Real_BLAS and System.Generic_Real_LAPACK.
6108 Add with of Ada.Containers.Generic_Anonymous_Array_Sort, for
6109 Sort_Eigensystems.
6110
61112011-08-29 Thomas Quinot <quinot@adacore.com>
6112
6113 * put_scos.adb (Put_SCOs): Do not emit a newline for an empty
6114 statements line.
6115
60370fb1
AC
61162011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
6117
6118 * s-finmas.adb (Finalize): Check Finalize_Address of the master rather
6119 than the current node.
6120 * s-finmas.ads: Move field Finalize_Address from type FM_Node to
6121 Finalization_Master. The list headers have two fields instead of three.
6122 This should fix alignment issue but subpool allocations are now
6123 unusable. Alphabetize subprograms.
6124 * s-stposu.adb (Allocate_Any_Controlled): Use the offset rather than
6125 the size of the header when converting the beginning of the object to
6126 a FM_Node. Set the master's Finalize_Address attribute if not already
6127 set.
6128 (Deallocate_Any_Controlled): Use the offset rather than the size of the
6129 header when converting the beginning of the object to a FM_Node.
6130
61312011-08-29 Gary Dismukes <dismukes@adacore.com>
6132
6133 * exp_ch11.adb (Expand_N_Raise_Statement): Don't suppress expansion of
6134 reraise when compiling for CodePeer.
6135
61362011-08-29 Arnaud Charlet <charlet@adacore.com>
6137
6138 * a-iteint.ads, Makefile.rtl: Add missing compilation of a-iteint.ads,
6139 now needed by a-convec.adb. Fix warning.
6140
61412011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
6142
6143 * exp_util.adb (Build_Allocate_Deallocate_Proc): Add a guard for the
6144 processing of TSS routine Finalize_Address when compiling in
6145 CodePeer_Mode.
6146
61472011-08-29 Thomas Quinot <quinot@adacore.com>
6148
6149 * a-strunb.ads, einfo.ads, g-comlin.ads, sem_ch6.adb,
6150 sem_warn.adb: Minor reformatting.
6151
61522011-08-29 Emmanuel Briot <briot@adacore.com>
6153
6154 * prj-conf.adb (Get_Config_Switches): Also collect the list of
6155 languages from aggregated projects.
6156
61572011-08-29 Yannick Moy <moy@adacore.com>
6158
6159 * lib-xref-alfa.adb, lib-xref.ads (Traverse_Declarations_Or_Statements,
6160 Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
6161 Traverse_Package_Declaration, Traverse_Subprogram_Body,
6162 Traverse_Compilation_Unit): Add a parameter Inside_Stubs so that bodies
6163 for stubs are traversed too when parameter is set
6164 (Traverse_All_Compilation_Units): Traverse without going inside stubs
6165 (Traverse_Declarations_Or_Statements): Do the special traversing for
6166 stubs when required.
6167 * sem_util.adb, sem_util.ads (Get_Body_From_Stub): New function to
6168 return subprogram or package body from stub.
6169 (Is_Subprogram_Stub_Without_Prior_Declaration): New function to detect
6170 stubs without prior subprogram decl.
6171
61722011-08-29 Vasiliy Fofanov <fofanov@adacore.com>
6173
6174 * gnat_ugn.texi: Fix typo.
6175
e9c9d122
HK
61762011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
6177
6178 * s-stposu.adb (Allocate_Any_Controlled): Reimplement the mechanism
6179 which accounts for size vs alignment issues and calculates the size of
6180 the list header.
6181 (Deallocate_Any_Controlled): Ditto.
6182 (Nearest_Multiple_Rounded_Up): New routine.
6183
25ebc085
AC
61842011-08-29 Tristan Gingold <gingold@adacore.com>
6185
6186 * a-exstat.adb (String_To_EO): Do no set Cleanup_Flag.
6187 * a-exexda.adb (Set_Exception_C_Msg): Ditto.
6188 (Set_Exception_Msg): Ditto.
6189 * a-exexpr-gcc.adb (Setup_Current_Excep): Ditto. Do not set
6190 Private_Data.
6191 * a-except.adb, a-except-2005.adb (Save_Occurrence_No_Private): Remove.
6192 Use Save_Occurrence instead of Save_Occurrence_No_Private.
6193 (Raise_With_Msg): Remove Cleanup_Flag.
6194 * a-except.ads, a-except-2005.ads (Exception_Occurrence): Remove
6195 Clean_Flag and Private_Data components.
6196
61972011-08-29 Yannick Moy <moy@adacore.com>
6198
6199 * freeze.adb (Freeze_Record_Type): Ignore packing in Alfa mode, like
6200 in CodePeer mode.
6201 * sem_ch3.adb (Signed_Integer_Type_Declaration): Correct the generation
6202 of an explicitly declared type, so that the base types of the original
6203 type and this generated type are the same, and a "type" (not a subtype
6204 like previously).
6205 * errout.adb (Special_Msg_Delete): Do not issue messages "Size too
6206 small" in Alfa mode, like in CodePeer mode.
6207 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore rep
6208 clauses in Alfa mode.
6209
62102011-08-29 Javier Miranda <miranda@adacore.com>
6211
6212 * exp_ch6.ads, exp_ch6.adb (Is_Null_Procedure): Move the spec of this
6213 function to the package spec.
6214 * sem_ch6.adb (Find_Corresponding_Spec, New_Overloaded_Entity): For
6215 internally generated bodies of null procedures locate the internally
6216 generated spec enforcing mode conformance.
6217 (Is_Interface_Conformant): Ensure that the controlling formal of the
6218 primitives match.
6219
62202011-08-29 Ed Schonberg <schonberg@adacore.com>
6221
6222 * sem_prag.adb (Analyze_Pragma, case Inline): In an instance, do not
6223 reject the pragma if it appears to apply to a formal subprogram.
6224
62252011-08-29 Ed Schonberg <schonberg@adacore.com>
6226
6227 * exp_ch4.adb (Expand_Allocator_Expression): Use consistent name for
6228 inner expression, to prevent double evaluation.
6229
590549fb
AC
62302011-08-29 Tristan Gingold <gingold@adacore.com>
6231
6232 * a-exexpr.adb (Propagate_Exception): Remove all the parameters as
6233 they were unused.
6234 * a-exexpr-gcc.adb (Propagate_Exception): Ditto.
6235 * a-except-2005.adb (Propagate_Exception): Adjust spec.
6236 (Raise_Current_Excep): Adjust call.
6237 (Raise_From_Signal_Handler): Call now simply call Raise_Current_Excep.
6238
62392011-08-29 Thomas Quinot <quinot@adacore.com>
6240
6241 * exp_disp.adb: Minor reformatting.
6242
62380e66
TG
62432011-08-29 Tristan Gingold <gingold@adacore.com>
6244
6245 * a-exexpr.adb (Setup_Exception): Removed.
6246 * a-exexpr-gcc.adb (Setup_Exception): Removed.
6247 * a-except.adb (Exception_Propagation): Removed.
6248 * a-except-2005.adb (Setup_Exception): Removed.
6249 (Reraise): Remove call to Setup_Exception.
6250 (Reraise_Occurrence): Ditto.
6251 (Reraise_Occurrence_Always): Ditto.
6252 (Reraise_Occurrence_No_Defer): Ditto.
6253 (Transfer_Occurrence): Ditto.
6254 * a-exexda.adb (Set_Exception_C_Msg): Remove call to Setup_Exception.
6255 (Set_Exception_Msg): Ditto.
6256
c95aa61c
AC
62572011-08-29 Robert Dewar <dewar@adacore.com>
6258
6259 * a-convec.adb, exp_disp.adb: Minor reformatting.
6260
62612011-08-29 Tristan Gingold <gingold@adacore.com>
6262
6263 * a-exexpr-gcc.adb (GNAT_GCC_Exception_Access): Set to convention C.
6264
624e1688
AC
62652011-08-29 Gary Dismukes <dismukes@adacore.com>
6266
6267 * exp_ch3.adb (Build_Record_Init_Proc.Build_Init_Procedure): Set
6268 Exception_Handlers to No_List instead of Empty_List in the case where
6269 there are no handlers.
6270
62712011-08-29 Tristan Gingold <gingold@adacore.com>
6272
6273 * gcc-interface/gigi.h (enum standard_datatypes): Add
6274 ADT_reraise_zcx_decl
6275 (reraise_zcx_decl): New macro.
6276 * gcc-interface/trans.c (gnu_incoming_exc_ptr): New variable.
6277 (gigi): Set reraise_zcx_decl.
6278 (Exception_Handler_to_gnu_zcx): Save and restore gnu_incoming_exc_ptr.
6279 (gnat_to_gnu): Handle N_Raise_Statement.
6280
7134062a
AC
62812011-08-29 Robert Dewar <dewar@adacore.com>
6282
6283 * sem_ch6.adb, exp_ch3.adb, s-stposu.adb, a-undesu.ads,
6284 a-undesu.adb: Minor reformatting.
6285
62862011-08-29 Ed Schonberg <schonberg@adacore.com>
6287
6288 * exp_disp.adb (Check_Premature_Freezing): When building a dispatch
6289 table, accept an unfrozen untagged component if it is an actual for a
6290 formal incomplete type.
6291 * a-convec.ads, a-convec.adb: Instantiate Ada.Iterator_Interfaces to
6292 provide new iterator forms over vectors.
6293 Introduce type Iterator in package body to implement operations of
6294 Reversible_Iterator interface.
6295 * a-iteint.ads: Make package pure so it is usable with new container
6296 packages, that are categorized Remote_Types.
6297
ca5af305
AC
62982011-08-29 Robert Dewar <dewar@adacore.com>
6299
6300 * a-exexpr-gcc.adb, a-synbar.adb, sem_ch13.adb: Minor reformatting.
6301
63022011-08-29 Bob Duff <duff@adacore.com>
6303
6304 * sem_aggr.adb (Resolve_Aggr_Expr): Call this routine even in the case
6305 of <>, because this is the routine that checks for dimensionality
6306 errors (for example, for a two-dimensional array, (others => <>) should
6307 be (others => (others => <>)).
6308
63092011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
6310
6311 * impunit.adb: Add new run-time units.
6312 * freeze.adb, exp_ch7.ads, exp_ch7.adb, exp_util.ads, exp_util.adb,
6313 s-stposu.ads, s-stposu.adb: Code clean up.
6314 Handle protected class-wide or task class-wide types
6315 Handle C/C++/CIL/Java types.
6316 * s-spsufi.adb, s-spsufi.ads: New files.
6317
5accd7b6
AC
63182011-08-29 Yannick Moy <moy@adacore.com>
6319
6320 * sem_ch13.adb (Analyze_Aspect_Specifications): Reject test-case on
6321 library-level subprogram.
6322 * sem_prag.adb (Check_Test_Case): Stricter rules for test-case
6323 placement.
6324 (Analyze_Pragma): Change name "Normal" for "Nominal" in test-case
6325 component.
6326 * snames.ads-tmpl: Change name "Normal" for "Nominal" in test-case
6327 component.
6328 * gnat_rm.texi: Update doc for Test_Case pragma.
6329
63302011-08-29 Tristan Gingold <gingold@adacore.com>
6331
6332 * a-exexpr-gcc.adb (Unwind_Exception): Remove default value, made it
6333 convention C.
6334 (GCC_Exception_Access): New type.
6335 (Unwind_DeleteException): New imported procedure
6336 (Foreign_Exception): Import it.
6337 (GNAT_GCC_Exception): Simply have the occurrence inside.
6338 (To_GCC_Exception): New function.
6339 (To_GNAT_GCC_Exception): New function.
6340 (GNAT_GCC_Exception_Cleanup): New procedure..
6341 (Propagate_GCC_Exception): New procedure.
6342 (Reraise_GCC_Exception): New procedure.
6343 (Setup_Current_Excep): New procedure.
6344 (CleanupUnwind_Handler): Change type of UW_Exception parameter.
6345 (Unwind_RaiseException): Ditto.
6346 (Unwind_ForcedUnwind): Ditto.
6347 (Remove): Removed.
6348 (Begin_Handler): Change type of parameter.
6349 (End_Handler): Ditto. Now delete the exception if still present.
6350 (Setup_Key): Removed.
6351 (Is_Setup_And_Not_Propagated): Removed.
6352 (Set_Setup_And_Not_Propagated): Ditto.
6353 (Clear_Setup_And_Not_Propagated): Ditto.
6354 (Save_Occurrence_And_Private): Ditto.
6355 (EID_For): Add 'not null' constraint on parameter.
6356 (Setup_Exception): Does nothing.
6357 (Propagate_Exception): Simplified.
6358 * exp_ch11.adb (Expand_N_Raise_Statement): In back-end exception model,
6359 re-raise is not expanded anymore.
6360 * s-except.ads (Foreign_Exception): New exception - placeholder for
6361 non Ada exceptions.
6362 * raise-gcc.c (__gnat_setup_current_excep): Declare
6363 (CXX_EXCEPTION_CLASS): Define (not yet used)
6364 (GNAT_EXCEPTION_CLASS): Define.
6365 (is_handled_by): Handle foreign exceptions.
6366 (PERSONALITY_FUNCTION): Call __gnat_setup_current_excep.
6367
63682011-08-29 Jose Ruiz <ruiz@adacore.com>
6369
6370 * a-synbar.adb (Synchronous_Barrier): Some additional clarification.
6371
2ef48385
AC
63722011-08-29 Thomas Quinot <quinot@adacore.com>
6373
6374 * a-synbar-posix.adb: Minor reformatting.
6375
63762011-08-29 Jose Ruiz <ruiz@adacore.com>
6377
6378 * a-exetim-posix.adb, a-exetim-mingw.adb, a-exetim-mingw.ads,
6379 a-exetim-default.ads (Interrupt_Clocks_Supported,
6380 Separate_Interrupt_Clocks_Supported, Clock_For_Interrupts): Add these
6381 definitions to be compliant with AI-0171. The target systems do not
6382 support separate account for the execution time of interrupt handlers.
6383
63842011-08-29 Jose Ruiz <ruiz@adacore.com>
6385
6386 * a-synbar.adb (Wait): Change the order of evaluation of the conditions
6387 in the barrier to put first the easiest to evaluate (and the one which
6388 will be True more often). More efficient.
6389
63902011-08-29 Eric Botcazou <ebotcazou@adacore.com>
6391
6392 * s-atocou-x86.adb: Fix constraint in machine code insertion.
6393
63942011-08-29 Bob Duff <duff@adacore.com>
6395
6396 * aspects.ads, aspects.adb: Add new aspects for various pragmas and
6397 attributes that are now aspects, as specified by AI05-0229-1.
6398 * sem_ch13.adb (Analyze_Aspect_Specifications,
6399 Check_Aspect_At_Freeze_Point): Analyze the new aspects. Turn them into
6400 pragmas or attribute references, as appropriate.
6401
0db16b1e
AC
64022011-08-29 Robert Dewar <dewar@adacore.com>
6403
6404 * a-synbar.ads, a-synbar.adb, a-synbar-posix.adb,
6405 a-synbar-posix.ads: Minor reformatting.
6406
64072011-08-29 Yannick Moy <moy@adacore.com>
6408
6409 * snames.ads-tmpl: Add name Force.
6410
978ffe02
AC
64112011-08-29 Pascal Obry <obry@adacore.com>
6412
6413 * prj-nmsc.adb: Minor reformatting.
6414
64152011-08-29 Jose Ruiz <ruiz@adacore.com>
6416
6417 * a-exetim.ads (Interrupt_Clocks_Supported,
6418 Separate_Interrupt_Clocks_Supported, Clock_For_Interrupts): Add these
6419 definitions to be compliant with AI-0171.
6420
64212011-08-29 Robert Dewar <dewar@adacore.com>
6422
6423 * a-ngelfu.adb: Add comments.
6424
718f39dc
AC
64252011-08-29 Geert Bosch <bosch@adacore.com>
6426
6427 * a-ngelfu.adb (Tan): Do not raise Constraint_Error if the argument is
6428 the closest machine number to Pi / 2.0.
6429
64302011-08-29 Jose Ruiz <ruiz@adacore.com>
6431
6432 * impunit.adb (Non_Imp_File_Names_12): Add a-synbar for new Ada 2012
6433 package Ada.Synchronous_Barriers.
6434 * a-synbar.ads, a-synbar.adb, a-synbar-posix.ads, a-synbar-posix.adb:
6435 Add new specs and bodies for Ada.Synchronous_Barriers. There is a
6436 default implementation using protected objects and another one
6437 a-synbar-posix using POSIX barriers as the underlying support.
6438 * gcc-interface/Makefile.in (LIBGNAT_TARGET_PAIRS for Linux (x86,
6439 x86_64, ia64) and MIPS IRIX): Use the a-synbar-posix implementation of
6440 Ada.Synchronous_Barriers which uses POSIX barriers (more efficient).
6441 Clean up dependencies.
6442 * Makefile.rtl (GNATRTL_TASKING_OBJS): Add a-synbar.o
6443
ee2e3f6b
AC
64442011-08-29 Robert Dewar <dewar@adacore.com>
6445
6446 * sem_ch7.adb, make.adb, sem_res.adb, exp_intr.adb,
6447 exp_dist.adb: Minor code reorganization.
6448 Minor reformatting.
6449
64502011-08-29 Thomas Quinot <quinot@adacore.com>
6451
6452 * sem_cat.adb (Validate_RACW_Primitive): The return type of an RACW
6453 primitive operation must support external streaming if it is not a
6454 controlling access result.
6455
646e2823
AC
64562011-08-29 Thomas Quinot <quinot@adacore.com>
6457
6458 * sinfo.ads, sem_ch7.adb: Minor reformatting.
6459
64602011-08-29 Bob Duff <duff@adacore.com>
6461
6462 * sem_ch4.adb (Analyze_Allocator): Check No_Nested_Finalization
6463 restriction on allocators, as required by AI05-0013-1.
6464 * restrict.ads: Minor comment fix.
6465
5d59eef2
AC
64662011-08-29 Tristan Gingold <gingold@adacore.com>
6467
6468 * a-exexpr.adb, a-except-2005.ads (Jmpbuf_Address): Move to a-exexpr.adb
6469 (To_Jmpbuf_Address): Ditto
6470 (builtin_longjmp): Ditto
6471
64722011-08-29 Thomas Quinot <quinot@adacore.com>
6473
6474 * sem_res.adb: Minor reformatting.
6475
64762011-08-29 Vincent Celier <celier@adacore.com>
6477
6478 * make.adb (Gnatmake): Move special processing for VM targets after the
6479 call to Get_Target_Parameters.
6480
64812011-08-29 Thomas Quinot <quinot@adacore.com>
6482
6483 * sem_ch12.adb, par-ch12.adb: Minor reformatting.
6484
949a18cc
AC
64852011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
6486
6487 * sem_res.adb (Resolve_Allocator): Implement Ada2012-B052. Detect cases
6488 where an anonymous access discriminant of a limited designated type
6489 appears in a non-immutably limited discriminated type and issue an
6490 error message. Add local variable Desig_T and replace all occurrences
6491 of Designated_Type.
6492
64932011-08-29 Jose Ruiz <ruiz@adacore.com>
6494
6495 * a-rttiev.adb (Set_Handler): Update comment to indicate that our
6496 implementation is compliant to RM D.15(15/2) after the modification
6497 imposed by AI05-0094-1 (binding interpretation).
6498
cb25faf8
AC
64992011-08-29 Robert Dewar <dewar@adacore.com>
6500
6501 * exp_ch9.adb, s-tasren.adb, exp_sel.adb, exp_sel.ads, exp_ch11.adb,
6502 s-interr-hwint.adb, s-tpobop.adb, sem_ch13.adb: Minor reformatting.
6503
65042011-08-29 Thomas Quinot <quinot@adacore.com>
6505
6506 * par-endh.adb (Check_End): For an END where it is mandatory to repeat
6507 the scope name, do not report a missing label as a style violation (it
6508 will be diagnosed as an illegality).
6509 * exp_dist.adb (Add_Params_For_Variant_Components): Fix handling of
6510 variant records: Get_Enum_Lit_From_Pos already returns a usage
6511 occurrence of the literal, no need to use New_Occurrence_Of. Set Etype
6512 on Expr in Integer_Literal case so that it can be used by
6513 Build_To_Any_Call.
6514
1d10f669
AC
65152011-08-29 Tristan Gingold <gingold@adacore.com>
6516
6517 * exp_sel.ads (Build_Abort_BLock_Handler): New function spec.
6518 Adjust comment.
6519 * exp_sel.adb (Build_Abort_Block): Use Build_Abort_Block_Handler.
6520 (Build_Abort_Block_Handler): New function to build an Abort_Signal
6521 exception handler.
6522 * exp_ch9.adb (Expand_N_Asynchronous_Select): Call
6523 Build_Abort_Block_Handler to build the exception handler. Do not
6524 undefer aborts for the Abort_Signal exception handler if back-end
6525 exception mechanism.
6526 * exp_ch11.adb (Expand_Exception_Handlers): Do not undefer aborts if
6527 back_end exceptions for all others and abort_signal.
6528 * s-except.ads (ZCX_By_Default): New constant.
6529 * a-except-2005.adb (Raise_Exception): Do not defer abort if ZCX.
6530 (Raise_Exception_Always): Ditto.
6531 (Raise_From_Signal_Handler): Ditto.
6532 (Raise_With_Location_And_Msg): Ditto.
6533 (Raise_With_Msg): Ditto.
6534 (Reraise): Ditto.
6535 (Reraise_Occurence): Ditto.
6536 (Reraise_Occurrence_Always): Ditto.
6537 * s-tasren.adb (Exceptional_Complete_Rendezvous): Defer aborts if ZCX.
6538 * s-tpobop.adb: (Exceptional_Complete_Body): Undefer abort if ZCX.
1d10f669
AC
6539
65402011-08-29 Thomas Quinot <quinot@adacore.com>
6541
6542 * sem_util.ads (Get_Enum_Lit_From_Pos): Clarify documentation.
6543
d986066d
AC
65442011-08-29 Robert Dewar <dewar@adacore.com>
6545
6546 * snames.adb-tmpl, sem_ch13.adb: Minor reformatting
6547 Minor code reorganization.
6548
65492011-08-29 Bob Duff <duff@adacore.com>
6550
6551 * usage.adb (-gnatwy): Fix documentation: this switch applies to Ada
6552 2012, not just Ada 2005.
6553
65542011-08-29 Vincent Celier <celier@adacore.com>
6555
6556 * gnat_ugn.texi: Indicate that when the compiler is called by gnatmake
6557 with a project file or with gprbuid, if -gnatep= is specified, the
6558 builder may need to be invoked with -x.
6559
65602011-08-29 Tristan Gingold <gingold@adacore.com>
6561
6562 * a-exexpr-gcc.adb: Minor comment fix.
6563
ff4f0ed0
AC
65642011-08-29 Robert Dewar <dewar@adacore.com>
6565
6566 * sem_ch8.adb: Minor reformatting.
6567
65682011-08-29 Bob Duff <duff@adacore.com>
6569
6570 * par-ch2.adb (P_Identifier): Warn that "some" is reserved in Ada 2012.
6571 * par-ch4.adb (P_Quantified_Expression): Remove unnecessary code for
6572 treating "some" as unreserved in earlier Ada versions. This is now
6573 handled in Snames.Is_Keyword_Name. Parse "for some" using Tok_Some,
6574 rather than Name_Some, since Tok_Some is now recognized as reserved.
6575 * scans.adb (Initialize_Ada_Keywords): Handle Tok_Some like any other
6576 reserved word.
6577 * scans.ads: Minor comment fixes.
6578 * snames.adb-tmpl (Is_Keyword_Name): Handle Ada 2012 reserved words as
6579 for other language versions.
6580 * scn.adb (Scan_Reserved_Identifier): Remove unnecessary code for
6581 treating "some" as unreserved in earlier Ada versions. This is now
6582 handled in Snames.Is_Keyword_Name.
6583 * par-ch3.adb (P_Defining_Identifier): Warn that "some" is reserved in
6584 Ada 2012.
6585 (P_Subtype_Mark_Resync): Remove unnecessary code for treating "some" as
6586 unreserved in earlier Ada versions. This is now handled in
6587 Snames.Is_Keyword_Name.
6588 * snames.ads-tmpl (Ada_2012_Reserved_Words): Handle Ada 2012 reserved
6589 words as for other language versions.
6590 * gnat_ugn.texi (-gnatwy): Fix documentation: this switch applies to
6591 Ada 2012, not just Ada 2005.
6592
d941cee6
AC
65932011-08-29 Ed Schonberg <schonberg@adacore.com>
6594
6595 * sem_ch13.adb: Additional semantic checks for aspects involved in
6596 iterators.
6597
65982011-08-29 Matthew Heaney <heaney@adacore.com>
6599
6600 * a-comutr.ads, a-comutr.adb, a-cimutr.ads, a-cimutr.adb,
6601 a-cbmutr.ads, a-cbmutr.adb (Find_In_Subtree): Remove superfluous
6602 Container parameter.
6603 (Ancestor_Find): ditto.
6604
b970af39
TQ
66052011-08-29 Thomas Quinot <quinot@adacore.com>
6606
6607 * par-endh.adb: Minor reformatting.
d941cee6 6608
92db5dee
AC
66092011-08-29 Tristan Gingold <gingold@adacore.com>
6610
6611 * a-exexpr-gcc.adb (Unwind_Action) Rewrite as an integer with constants.
6612 (GNAT_GCC_Exception): Remove N_Cleanups_To_Trigger component.
6613 (Adjust_N_CLeanups_For): Remove.
6614 (CleanupUnwind_Handler): Call Unhandled_Exception_Terminate when end of
6615 stack is reached.
6616 (Propgate_Exception): Adjust.
6617 * raise-gcc.c: Add a few static/const.
6618 (Adjust_N_Cleanups_For): Remove declaration.
6619 (PERSONALITY_FUNCTION): Remove code dealing with N_Cleanups_To_Trigger.
6620
66212011-08-29 Ed Schonberg <schonberg@adacore.com>
6622
6623 * sem_ch8.adb: Use type of function return when rewriting as object
6624 declaration.
6625
1378bf10
AC
66262011-08-29 Gary Dismukes <dismukes@adacore.com>
6627
6628 * sem_type.adb: Minor reformatting.
6629
66302011-08-29 Robert Dewar <dewar@adacore.com>
6631
6632 * makeutl.adb: Minor reformatting.
6633
66342011-08-29 Ed Schonberg <schonberg@adacore.com>
6635
6636 * sem_ch8.adb (Analyze_Object_Renaming): If the renamed object is a
6637 function call of a limited type, the expansion of the renaming is
6638 complicated by the presence of various temporaries and subtypes that
6639 capture constraints of the renamed object.
6640 Rewrite node as an object declaration, whose expansion is simpler.
6641 Given that the object is limited there is no copy involved and no
6642 performance hit.
6643
164e06c6
AC
66442011-08-29 Robert Dewar <dewar@adacore.com>
6645
6646 * exp_ch5.adb, sinfo.ads, make.adb, s-pooglo.adb, sem_ch12.adb,
6647 freeze.adb, sem_ch6.adb, par-ch12.adb: Minor reformatting.
6648
66492011-08-29 Tristan Gingold <gingold@adacore.com>
6650
6651 * system-darwin-x86.ads, system-linux-s390x.ads, system-linux-alpha.ads,
6652 system-tru64.ads, system-irix-n32.ads, system-vxworks-arm.ads,
6653 system-linux-hppa.ads, system-linux-s390.ads,
6654 system-solaris-sparcv9.ads, system-mingw.ads, system-linux-ia64.ads,
6655 system-vms_64.ads, system-vxworks-sparcv9.ads, system-linux-ppc.ads,
6656 system-aix64.ads, system-lynxos-ppc.ads, system-linux-sh4.ads,
6657 system-solaris-x86.ads, system-linux-x86_64.ads, system-linux-x86.ads,
6658 system-vxworks-ppc.ads, system-hpux.ads, system-darwin-ppc.ads,
6659 system-solaris-sparc.ads, system-lynxos-x86.ads,
6660 system-vxworks-m68k.ads, system-hpux-ia64.ads, system-irix-o32.ads,
6661 system-solaris-x86_64.ads, system-mingw-x86_64.ads,
6662 system-vxworks-mips.ads, system-linux-sparc.ads, system-vms-ia64.ads,
6663 system-freebsd-x86.ads, system-aix.ads, system-darwin-x86_64.ads,
7d266442 6664 system-vxworks-x86.ads: Remove GCC_ZCX_Support.
164e06c6
AC
6665 * s-taprop-posix.adb, s-taprop-irix.adb, s-taprop-vxworks.adb,
6666 s-taprop-tru64.adb, s-taprop-linux.adb, s-taprop-solaris.adb: Ditto.
6667 * opt.ads: Adjust comment.
6668 * targparm.ads, targparm.adb: Remove GCC_ZCX_Support_On_Target.
6669 * gnat1drv.adb: Do not check for GCC_ZCX_Support_On_Target.
6670 * system.ads: Move GCC_ZCX_Support to obsolete entries.
6671
66722011-08-29 Emmanuel Briot <briot@adacore.com>
6673
6674 * makeutl.adb (Do_Complete): Resolve symbolic links when a relative
6675 file name is specified on the gnatmake or gprbuild command line, and
6676 before we search for that file in the project.
6677
66782011-08-29 Ed Schonberg <schonberg@adacore.com>
6679
6680 * sem_type.adb (Within_Instance): New predicate in Collect_Interps,
6681 used to determine whether a possible interpretation for an overloadable
6682 entity is declared within the current instantiation and should be
6683 included in the candidate set.
6684
66852011-08-29 Vasiliy Fofanov <fofanov@adacore.com>
6686
6687 * gnat_rm.texi, gnat_ugn.texi: Clean ups.
6688
97216ca8
ES
66892011-08-29 Ed Schonberg <schonberg@adacore.com>
6690
6691 * sem_res.adb (Resolve_Actuals): Use base type to determine whether an
6692 access subtype is access_to_subprogram, when applying checks for
6693 RM 3.10.2 (27).
6694
d3cb4cc0
AC
66952011-08-29 Matthew Heaney <heaney@adacore.com>
6696
6697 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Splice_Subtree): Only check
6698 for sibling when common parent.
6699
67002011-08-29 Thomas Quinot <quinot@adacore.com>
6701
6702 * get_scos.adb: Literals of Pragma_Id are pragma names prefixed with
6703 "pragma_".
6704
67052011-08-29 Ed Schonberg <schonberg@adacore.com>
6706
6707 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Enable freeze actions
6708 for the return type when in ASIS mode.
6709
67102011-08-29 Vincent Celier <celier@adacore.com>
6711
6712 * make.adb (Gnatmake): Get the default search dirs, then the target
6713 parameters after getting the Builder switches, as the Builder switches
6714 may include --RTS= and that could change the default search dirs.
6715
67162011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
6717
6718 * exp_ch7.adb (Make_Adjust_Call): Rewrite to mimic the structure of
6719 Make_Final_Call. Move the processing for class-wide types before the
6720 processing for derivations from [Limited_]Controlled.
6721 (Make_Final_Call): Move the processing for class-wide types before the
6722 processing for derivations from [Limited_]Controlled.
6723 * s-stposu.adb (Allocate_Any_Controlled): Correct the membership check.
6724 Add code to account for alignments larger than the list header. Add a
6725 comment illustrating the structure of the allocated object + padding +
6726 header.
6727 (Deallocate_Any_Controlled): Add code to account for alignments larger
6728 than the list header.
6729
67302011-08-29 Ed Schonberg <schonberg@adacore.com>
6731
6732 * sinfo.ads, sinfo.adb: New node kind
6733 N_Formal_Incomplete_Type_Definition, related flags.
6734 par-ch12.adb (P_Formal_Type_Declaration, G_Formal_Type_Definition):
6735 Parse formal incomplete types.
6736 * sem.adb (Analyze): Formal_Incomplete_Type_Definitions are handled in
6737 sem_ch12.
6738 * sem_ch7.adb (Analyze_Package_Specification, Unit_Requires_Body):
6739 Formal incomplete types do not need completion.
6740 * sem_ch12.adb (Analyze_Formal_Incomplete_Type,
6741 Validate_Incomplete_Type_Instance): New procedures to handle formal
6742 incomplete types.
6743 * freeze.adb (Freeze_Entity): Do not freeze the subtype of an actual
6744 that corresponds to a formal incomplete type.
6745 * sprint.adb: Handle formal incomplete type declarations.
6746 * exp_util.adb (Insert_Actions): An incomplete_type_definition is not
6747 an insertion point.
6748
d3f70b35
AC
67492011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
6750
6751 * a-fihema.ads, a-fihema.adb: Unit removed.
6752 * a-undesu.ads, a-undesu.adb: New unit implementing
6753 Ada.Unchecked_Deallocate_Subpool.
6754 * einfo.adb: Remove Associated_Collection from the node usage.
6755 Add Finalization_Master to the node usage.
6756 (Associated_Collection): Removed.
6757 (Finalization_Master): New routine.
6758 (Set_Associated_Collection): Removed.
6759 (Set_Finalization_Master): New routine.
6760 (Write_Field23_Name): Remove Associated_Collection from the output. Add
6761 Finalization_Master to the output.
6762 * einfo.ads: Remove attribute Associated_Collection and its uses in
6763 entities.
6764 Add new attribute Finalization_Master along with its uses in entitites.
6765 (Associated_Collection): Removed along with its pragma import.
6766 (Finalization_Master): New routine along with a pragma import.
6767 (Set_Associated_Collection): Removed along with its pragma import.
6768 (Set_Finalization_Master): New routine along with a pragma import.
6769 * exp_ch3.adb (Expand_Freeze_Array_Type): Replace call to
6770 Build_Finalization_Collection with Build_Finalization_Master.
6771 (Expand_Freeze_Record_Type): Move the generation of Finalize_Address
6772 before the bodies of the predefined routines. Add comment explaining
6773 this. Replace call to Build_Finalization_Collection with
6774 Build_Finalization_Master.
6775 (Freeze_Type): Replace call to Build_Finalization_Collection with
6776 Build_Finalization_Master.
6777 (Make_Finalize_Address_Body): Comment reformatting.
6778 (Make_Predefined_Primitive_Specs): Code reformatting.
6779 (Stream_Operation_OK): Update comment mentioning finalization
6780 collections. Replace RE_Finalization_Collection with
6781 RE_Finalization_Master.
6782 * exp_ch4.adb (Complete_Controlled_Allocation): Replace call to
6783 Associated_Collection with Finalization_Master. Replace call to
6784 Build_Finalization_Collection with Build_Finalization_Master.
6785 (Expand_Allocator_Expression): Replace call to Associated_Collection
6786 with Finalization_Master. Replace call to Set_Associated_Collection with
6787 Set_Finalization_Master. Remove the generation of
6788 Set_Finalize_Address_Ptr.
6789 (Expand_N_Allocator): Replace call to Associated_Collection with
6790 Finalization_Master. Remove the generation of Set_Finalize_Address_Ptr.
6791 * exp_ch6.adb (Add_Collection_Actual_To_Build_In_Place_Call): Renamed to
6792 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Update the
6793 comment on usage. Replace call to Needs_BIP_Collection with
6794 Needs_BIP_Finalization_Master Remplace BIP_Collection with
6795 BIP_Finalization_Master. Update all comments which mention finalization
6796 collections. Replace Associated_Collection with
6797 Finalization_Master. Replace Build_Finalization_Collection with
6798 Build_Finalization_Master.
6799 (BIP_Formal_Suffix): Update BIP_Collection's case.
6800 (Build_Heap_Allocator): Update the related comment. Rename local
6801 variable Collect to Fin_Mas_Id and update its occurrences. Update
6802 comments which mention finalization collections. Replace
6803 Set_Associated_Collection with Set_Finalization_Master.
6804 (Expand_Call): Update the code which detects a special piece of library
6805 code for .NET/JVM.
6806 (Make_Build_In_Place_Call_In_Allocator): Replace the call to
6807 Add_Collection_Actual_To_Build_In_Place_Call with
6808 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Remove the code
6809 which generates a call to Make_Set_Finalize_Address_Ptr_Call.
6810 (Make_Build_In_Place_Call_In_Anonymous_Context): Replace call to
6811 Add_Collection_Actual_To_Build_In_Place_Call with
6812 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
6813 (Make_Build_In_Place_Call_In_Assignment): Replace call to
6814 Add_Collection_Actual_To_Build_In_Place_Call with
6815 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
6816 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
6817 * exp_ch6.ads: Rename BIP_Collection to BIP_Finalization_Master.
6818 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
6819 * exp_ch7.adb (Build_BIP_Cleanup_Stmts): Update comment on usage.
6820 Rename local variable Collect to Fin_Mas_Id and update its occurrences.
6821 Replace call to Set_Associated_Collection with Set_Finalization_Master.
6822 (Build_Finalization_Collection): Renamed to Build_Finalization_Master.
6823 Replace the call to Associated_Collection with Finalization_Master.
6824 Rename local variable Coll_Id to Fin_Mas_Id and update its occurrences.
6825 Update the way finalization master names are generated. Update the
6826 retrieval of the correct access type which will carry the pool and
6827 master attributes.
6828 (Make_Final_Call): Reimplement the way [Deep_]Finalize is retrieved.
6829 (Make_Finalize_Address_Body): Abstract types do not need
6830 Finalize_Address. Code reformatting.
6831 (Make_Finalize_Address_Stmts): Update comment on usage.
6832 (Make_Set_Finalize_Address_Ptr_Call): Removed.
6833 (Process_Declarations): Update comments.
6834 * exp_ch7.ads (Build_Finalization_Collection): Renamed to
6835 Build_Finalization_Master. Update associated comment.
6836 (Make_Set_Finalize_Address_Ptr_Call): Removed.
6837 * exp_ch13.adb: Update comments which mention finalization collections.
6838 (Expand_N_Free_Statement): Replace the call to Associated_Collection
6839 with Finalization_Master.
6840 * exp_util.adb (Build_Allocate_Deallocate_Proc): Reimplemented to
6841 create calls to routines Allocate_Any_Controlled and
6842 Deallocate_Any_Controlled.
6843 (Find_Finalize_Address): New routine.
6844 (Is_Allocate_Deallocate_Proc): Update the RTE entities used in the
6845 comparison.
6846 (Requires_Cleanup_Actions): Update the comment on freeze node
6847 inspection.
6848 * exp_util.ads: Remove comment on generated code for
6849 Build_Allocate_Deallocate_Proc. The code is now quite complex and it
6850 is better to simply look in the body.
6851 * freeze.adb (Freeze_All): Update the comment of finalization
6852 collections. Replace the call to Associated_Collection with
6853 Finalization_Master. Replace the call to Build_Finalization_Collection
6854 with Build_Finalization_Master.
6855 * impunit.adb: Add a-undesu and s-stposu to the list of units.
6856 * Makefile.rtl: Add files a-undesu, s-finmas and s-stposu. Remove file
6857 a-fihema.
6858 * rtsfind.adb (Get_Unit_Name): Remove the processing for children of
6859 Ada.Finalization. Add processing for children of System.Storage_Pools.
6860 * rtsfind.ads: Remove the naming of second level children of
6861 Ada.Finalization.
6862 Remove Ada_Finalization_Heap_Management from the list of units.
6863 Remove subtype Ada_Finalization_Child.
6864 Remove the following subprogram entities:
6865
6866 RE_Allocate
6867 RE_Deallocate
6868 RE_Finalization_Collection
6869 RE_Finalization_Collection_Ptr
6870 RE_Set_Finalize_Address_Ptr
6871
6872 Add the naming of second level children of System.Storage_Pools.
6873 Add System_Finalization_Masters and System_Storage_Pools_Subpools to
6874 the list of units.
6875 Add subtype System_Storage_Pools_Child.
6876 Add the following subprogram entities to System.Finalization_Masters:
6877
6878 RE_Finalization_Master
6879 RE_Finalization_Master_Ptr
6880
6881 Add the following subprogram entities to System.Storage_Pools.Subpools:
6882
6883 RE_Allocate_Any_Controlled
6884 RE_Deallocate_Any_Controlled
6885 RE_Root_Storage_Pool_With_Subpools
6886 RE_Root_Subpool
6887 RE_Subpool_Handle
6888
6889 Move the following subprogram entities from
6890 Ada.Finalization.Heap_Management to System.Finalization_Masters:
6891
6892 RE_Add_Offset_To_Address
6893 RE_Attach
6894 RE_Base_Pool
6895 RE_Detach
6896
6897 * sem_ch3.adb (Access_Type_Declaration): Replace the call to
6898 Set_Associated_Collection with Set_Finalization_Master.
6899 * sem_ch6.adb (Create_Extra_Formals): Update the way extra formal
6900 BIP_Finalization_Master is created.
6901 * s-finmas.adb: New unit System.Finalization_Masters.
6902 * s-finmas.ads: New unit System.Finalization_Masters.
6903 * s-stopoo.ads, s-stopoo.adb: Minor code reformatting.
6904 * s-stposu.ads, s-stposu.adb: New unit implementing
6905 System.Storage_Pools.Subpools.
6906
69072011-08-29 Bob Duff <duff@adacore.com>
6908
6909 * tbuild.adb: Add assertion.
6910
8c889ae4
AC
69112011-08-29 Thomas Quinot <quinot@adacore.com>
6912
6913 * s-pooglo.adb: Minor reformatting.
6914
69152011-08-29 Ed Schonberg <schonberg@adacore.com>
6916
6917 * exp_ch5.adb (Expand_N_Assignment_Statement): if the left-hand side is
6918 an indexed component of a packed array whose element type is a record
6919 with a representation clause different from that of the right-hand
6920 side, generate a temporary to minimuze the number of bit-field
6921 operations generated.
6922
69232011-08-29 Ed Schonberg <schonberg@adacore.com>
6924
6925 * exp_util.adb (Insert_Actions): Use clauses can be part of lists of
6926 declarations, and thus are likely insertion points for actions.
6927
69282011-08-29 Bob Duff <duff@adacore.com>
6929
6930 * einfo.ads: Minor comment fix.
6931
1a07a71a
AC
69322011-08-29 Robert Dewar <dewar@adacore.com>
6933
6934 * frontend.adb, gnat1drv.adb: Minor reformatting.
6935
69362011-08-29 Tristan Gingold <gingold@adacore.com>
6937
6938 * s-pooglo.adb (Allocate, Deallocate): Take into account the alignment.
6939 * a-fihema.adb (Allocate, Deallocate): Ditto. Possibly add padding
6940 space in front of the header.
6941
4bcd6411
JK
69422011-08-29 Johannes Kanig <kanig@adacore.com>
6943
6944 * frontend.adb (Frontend): Exit after creating Standard package when
6945 -gnatd.H is present.
6946 * gnat1drv.adb (Gnat1drv): Call Backend right away when -gnatd.H is
6947 present.
6948
f0f88eb6
RD
69492011-08-29 Robert Dewar <dewar@adacore.com>
6950
6951 * exp_ch9.adb, mlib-prj.adb, prj.adb, prj.ads, ttypes.ads, sem_ch4.adb,
6952 makeutl.adb, makeutl.ads, atree.ads, snames.adb-tmpl,
6953 snames.ads-tmpl: Minor reformatting.
6954
3e37be71
PG
69552011-08-29 Philippe Gil <gil@adacore.com>
6956
6957 * prj.adb (Reset_Units_In_Table): New procedure.
6958 Reset units to avoid access to freed memory.
6959
94fb7608
AC
69602011-08-29 Thomas Quinot <quinot@adacore.com>
6961
6962 * get_scos.adb: When reading a P statement SCO without a pragma name
6963 (from an older ALI file), ensure that the Pragma_Name component is set
6964 to Unknown_Pragma (not left uninitialized).
6965
69662011-08-29 Vincent Celier <celier@adacore.com>
6967
6968 * makeutl.adb (Get_Directories): New procedure moved from Buildgpr and
6969 modified to compute correctly the object path of a SAL project that is
6970 extending another library project.
6971 (Write_Path_File): New procedure.
6972 * makeutl.ads (Directories): New table moved from Buildgpr
6973 (Get_Directories): New procedure moved from Buildgpr
6974 (Write_Path_File): New procedure
6975 * mlib-prj.adb (Build_Library): Use Makeutl.Get_Directories to set the
6976 paths before binding SALs, instead of Set_Ada_Paths.
6977 * prj-env.adb (Set_Path_File_Var): Procedure has been moved to package
6978 Prj.
6979 * prj.adb (Set_Path_File_Var): New procedure moved from Prj.Env
6980 (Current_Source_Path_File_Of): New function
6981 (Set_Current_Object_Path_File_Of): New procedure
6982 (Current_Source_Object_File_Of): New function
6983 (Set_Current_Object_Path_File_Of): New procedure
6984 * prj.ads (Set_Path_File_Var): New procedure moved from Prj.Env
6985 (Current_Source_Path_File_Of): New function
6986 (Set_Current_Object_Path_File_Of): New procedure
6987 (Current_Source_Object_File_Of): New function
6988 (Set_Current_Object_Path_File_Of): New procedure
6989
69902011-08-29 Ed Schonberg <schonberg@adacore.com>
6991
6992 * exp_ch5.adb (Expand_N_Assignment_Statement): For an assignment to a
6993 packed entity, use a bit-field assignment only if there is no change of
6994 representation.
6995
c5ecd6b7
AC
69962011-08-29 Thomas Quinot <quinot@adacore.com>
6997
6998 * rtsfind.ads, exp_ch3.adb (In_Runtime): Minor code improvement, use
6999 Is_RTU instead of using Chars comparisons.
7000
70012011-08-29 Thomas Quinot <quinot@adacore.com>
7002
7003 * exp_strm.adb (Build_Mutable_Record_Read_Procedure): Do not create a
7004 temporary object if the actual is constrained, and the discriminants
7005 read from the stream don't match.
7006
70072011-08-29 Tristan Gingold <gingold@adacore.com>
7008
7009 * sem_attr.adb, exp_attr.adb: Add handling of
7010 Attribute_System_Allocator_Alignment
7011 * snames.ads-tmpl: Add Name_System_Allocator_Alignment and
7012 Attribute_System_Allocator_Alignment.
7013 * ttypes.ads, get_targ.ads: Add Get_System_Allocator_Alignment.
7014 * gcc-interface/targtyps.c, gcc-interface/utils2.c,
7015 gcc-interface/gigi.h: Renames get_target_default_allocator_alignment to
7016 get_target_system_allocator_alignment.
7017
70182011-08-29 Arnaud Charlet <charlet@adacore.com>
7019
7020 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
7021 dependencies.
7022
8abdac29
AC
70232011-08-29 Arnaud Charlet <charlet@adacore.com>
7024
7025 * exp_ch3.adb (In_Runtime): Fix typo.
7026
df170605
AC
70272011-08-29 Bob Duff <duff@adacore.com>
7028
7029 * sem_ch4.adb (Analyze_Allocator): Analyze the subpool specification.
7030
70312011-08-29 Ed Schonberg <schonberg@adacore.com>
7032
7033 * exp_ch3.adb (Expand_N_Object_Declaration): If the entity is tagged
7034 and a separate tag assignment is generated, ensure that the tag
7035 assignment is analyzed.
7036
864a4236
ES
70372011-08-29 Ed Schonberg <schonberg@adacore.com>
7038
7039 * atree.ads, atree.adb (Copy_Separate_List): New function that applies
7040 Copy_Separate_Tree to a list of nodes. Used to create disjoint copies
7041 of statement lists that may contain local declarations.
df170605
AC
7042 * exp_ch9.adb (Expand_N_Timed_Entry_Call): Use Copy_Separate_List to
7043 duplicate the triggering statements needed for the expansion of this
7044 construct, when the trigger is a dispatching call to a synchronized
7045 primitive.
864a4236 7046
7f394c1d
AC
70472011-08-29 Arnaud Charlet <charlet@adacore.com>
7048
7049 * gnat_rm.texi: Add doc for 'Elab_Subp_Body.
7050 * bindgen.adb: Add comments.
7051 * snames.adb-tmpl (Is_Attribute_Name): Only recognize 'Elab_Subp_Body
7052 in CodePeer mode.
7053
2c1a2cf3
RD
70542011-08-29 Robert Dewar <dewar@adacore.com>
7055
7056 * exp_attr.adb: Minor reformatting.
7057 Minor code reorganization and commenting.
7058 * par_sco.adb, checks.adb, sem_attr.adb, get_scos.adb: Minor
7059 reformatting.
7060
0bfc9a64
AC
70612011-08-29 Thomas Quinot <quinot@adacore.com>
7062
7063 * get_scos.adb: Ignore chaining indicators not currently supported
7064 by Ada.
7065
70662011-08-29 Arnaud Charlet <charlet@adacore.com>
7067
7068 * system.ads: Minor editing.
7069
70702011-08-29 Arnaud Charlet <charlet@adacore.com>
7071
7072 * bindgen.adb (Gen_Elab_Calls): Generate calls to subp'Elab_Subp_Body in
7073 CodePeer mode.
7074 * sem_attr.ads, sem_attr.adb, exp_Attr.adb, sem_ch6.adb: Add handling of
7075 Attribute_Elab_Subp_Body.
7076 * snames.ads-tmpl (Attribute_Elab_Subp_Body, Name_Elab_Subp_Body): New.
7077 * sem_util.adb: Update comments.
7078
828d4cf0
TQ
70792011-08-29 Thomas Quinot <quinot@adacore.com>
7080
7081 * par_sco.adb, scos.adb, scos.ads, put_scos.adb, get_scos.adb: Record
7082 pragma name for each SCO statement corresponding to a pragma.
7083
5cd7bb15
AC
70842011-08-29 Arnaud Charlet <charlet@adacore.com>
7085
7086 * opt.ads: Minor editing.
7087
70882011-08-29 Yannick Moy <moy@adacore.com>
7089
7090 * gnat1drv.adb (Adjust_Global_Switches): Remove options for ALFA mode
7091 that only made sense for CodePeer mode.
7092
70932011-08-29 Jose Ruiz <ruiz@adacore.com>
7094
7095 * targparm.ads (Support_64_Bit_Divides_On_Target): Remove this flag
7096 which is no longer used.
7097 * targparm.adb (S64, S64_Str, Get_Target_Parameters): Remove the
7098 handling of the 64-bit division check.
7099 * exp_ch4.adb (Expand_N_Op_Divide): Remove the check for 64-bit
7100 division available.
7101 * system*.ads (Support_64_Bit_Divides): Remove this flag which is no
7102 longer used.
7103
71042011-08-29 Thomas Quinot <quinot@adacore.com>
7105
7106 * get_scos.adb: Minor reformatting.
7107
25b589cb
AC
71082011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
7109
7110 * exp_util.adb (Process_Statements_For_Controlled_Objects): Whenever a
7111 statement list is wrapped in a block, the block is explicitly analyzed
7112 in order to properly redecorate the entities and create a servicing
7113 finalizer.
7114
71152011-08-29 Tristan Gingold <gingold@adacore.com>
7116
7117 * sinfo.ads, sinfo.adb (Zero_Cost_Handling): Remove.
7118 (Set_Zero_Cost_Handling): Remove.
7119
71202011-08-29 Thomas Quinot <quinot@adacore.com>
7121
7122 * par_sco.adb, scos.ads, put_scos.adb, get_scos.adb: Minor reformatting
7123
1197ddb1
AC
71242011-08-29 Geert Bosch <bosch@adacore.com>
7125
7126 * s-vaflop-vms-alpha.adb (Neg_F): Use subtraction instead of negation
7127 instruction, as the latter may produce -0.0, which is not a valid VAX
7128 F float number.
7129 (Neg_G): Likewise for VAX F float.
7130
71312011-08-29 Robert Dewar <dewar@adacore.com>
7132
7133 * exp_util.adb: Minor reformatting.
7134
71352011-08-29 Yannick Moy <moy@adacore.com>
7136
7137 * sem_ch3.adb: Minor comment update.
7138
71392011-08-29 Thomas Quinot <quinot@adacore.com>
7140
7141 * checks.adb (Apply_Type_Conversion_Checks): Use the Underlying_Type of
7142 the operand type.
7143
71442011-08-29 Thomas Quinot <quinot@adacore.com>
7145
7146 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not flush
7147 current statement sequence on a generic instantiation or a subprogram
7148 declaration.
7149
8f66cda7
AC
71502011-08-29 Robert Dewar <dewar@adacore.com>
7151
7152 * sem_type.adb, einfo.ads, freeze.adb, exp_ch4.adb, sem_ch13.adb:
7153 Minor reformatting.
7154
71552011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
7156
7157 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
7158 Correct the check which involves the freeze node of a controlled or
7159 access-to-controlled type.
7160
71612011-08-29 Geert Bosch <bosch@adacore.com>
7162
7163 * sem_warn.adb (Check_Code_Statement): Remove check for consecutive Asm
7164 statements.
7165 * s-vaflop-vms-alpha.adb: Remove bogus Volatile => True arguments from
7166 Asm statements.
7167
cf161d66
AC
71682011-08-29 Yannick Moy <moy@adacore.com>
7169
7170 * sem_ch3.adb (Array_Type_Declaration): Insert a subtype declaration
7171 for every index type and component type that is not a subtype_mark.
7172 (Process_Subtype): Set Etype of subtype.
7173
71742011-08-29 Robert Dewar <dewar@adacore.com>
7175
7176 * a-cbmutr.adb, a-cimutr.adb, a-comutr.adb, prj-nmsc.adb: Minor code
7177 reorganization. Minor reformatting.
7178
7cc83cd8
AC
71792011-08-29 Steve Baird <baird@adacore.com>
7180
7181 * exp_ch4.adb (Expand_N_Op_Expon): Suppress N_Op_Expon node expansion
7182 for CodePeer and ALFA modes.
7183
71842011-08-29 Ed Schonberg <schonberg@adacore.com>
7185
7186 * sem_type.adb (Collect_Interps): Within an instance, collect a homonym
7187 that comes from an enclosing scope if it is not the renaming of an
7188 actual, to handle properly a spurious ambiguity in an instance.
7189
76af4137
AC
71902011-08-29 Eric Botcazou <ebotcazou@adacore.com>
7191
7192 * sem_ch13.adb (Alignment_Check_For_Esize_Change): Rename to...
7193 (Alignment_Check_For_Size_Change): ...this. Add SIZE parameter and
7194 use it instead of the Esize of the first parameter.
7195 (Analyze_Attribute_Definition_Clause) <Object_Size>: Adjust call to
7196 above change.
7197 <Size>: Likewise. Call it for composite types on the RM size.
7198
71992011-08-29 Yannick Moy <moy@adacore.com>
7200
7201 * exp_ch4.adb (Expand_N_Op_Not): Do not expand not on array.
7202 * sem_util.adb (Unique_Name): Correct behaviour for names of
7203 compilation units.
7204
9b20e59b
AC
72052011-08-29 Yannick Moy <moy@adacore.com>
7206
7207 * sem_prag.adb (Check_Precondition_Postcondition): In formal
7208 verification mode, analyze pragma expression for correctness, for
7209 pre/post on library-level subprogram, as it is not expanded later.
7210
72112011-08-29 Yannick Moy <moy@adacore.com>
7212
7213 * exp_aggr.adb (Expand_Array_Aggregate): Do not expand array aggregates
7214 in formal verification.
7215
72162011-08-29 Thomas Quinot <quinot@adacore.com>
7217
7218 * sem_util.adb: Minor reformatting.
7219 * freeze.adb, sem_ch13.adb: Fix comment: Bit_Order is an attribute,
7220 there's no pragma.
7221 * par_sco.ads, par_sco.adb: Update comments.
7222
72232011-08-29 Yannick Moy <moy@adacore.com>
7224
7225 * einfo.adb, einfo.ads: Remove flag Is_Postcondition_Proc and
7226 associated getter/setter.
7227 * sem_ch6.adb: Remove reference to Is_Postcondition_Proc.
7228
72292011-08-29 Vincent Celier <celier@adacore.com>
7230
7231 * prj-attr.adb: New Compiler attribute Dependency_Kind and Language_Kind
7232 * prj-conf.adb: Add_Default_GNAT_Naming_Scheme: Add a package Compiler
7233 with declarations for Language_Kind and Dependency_Kind for Ada.
7234 * prj-nmsc.adb (Check_Unit_Name): New name of procedure Check_Ada_Name
7235 (Process_Compiler): Take into account the new attributes Dependency_Kind
7236 and Language_Kind.
7237 (Check_Configuration): Check if language kind is unit based, not if the
7238 language name is Ada.
7239 (Process_Exceptions_Unit_Based): Ditto
7240 (Add_Language): Remove default additions of language and dependency kind
7241 * prj.ads: Minor comment change
7242 * snames.ads-tmpl: New standard names Dependency_Kind and Language_Kind
7243
72442011-08-29 Johannes Kanig <kanig@adacore.com>
7245
7246 * debug.adb: Update comments.
7247
c5bc3df6
JM
72482011-08-24 Joseph Myers <joseph@codesourcery.com>
7249
7250 * gcc-interface/Make-lang.in (CFLAGS-ada/tracebak.o)
7251 (CFLAGS-ada/targext.o, CFLAGS-ada/cio.o, CFLAGS-ada/init.o)
7252 (CFLAGS-ada/initialize.o, CFLAGS-ada/raise.o): New.
7253 (ada/tracebak.o, ada/targext.o, ada/cio.o, ada/init.o)
7254 (ada/initialize.o, ada/raise.o): Remove explicit compilation rules.
7255
e3aa9eba
RO
72562011-08-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7257
7258 * gcc-interface/Makefile.in (PICFLAG_FOR_TARGET): New.
7259 (GNATLIBCFLAGS_FOR_C): Replace
7260 TARGET_LIBGCC2_CFLAGS by PICFLAG_FOR_TARGET.
7261 (gnatlib-shared-default, gnatlib-shared-dual-win32)
7262 (gnatlib-shared-win32, gnatlib-shared-darwin, gnatlib-shared)
7263 (gnatlib-sjlj, gnatlib-zcx): Likewise.
7264
f446d60e
EB
72652011-08-07 Eric Botcazou <ebotcazou@adacore.com>
7266
7267 * gcc-interface/Makefile.in (raise-gcc.o): Fix previous change.
7268
588c8f48
EB
7269 * gcc-interface/gigi.h (enumerate_modes): Fix formatting.
7270
7271 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Revert latest change.
7272
28d711bf
NR
72732011-08-05 Nicolas Roche <roche@adacore.com>
7274
7275 * gcc-interface/Makefile.in: Don't use directly ../xgcc to build shared
7276 libgnat. Use rather the value of GCC_FOR_TARGET. Fix issue with
7277 canadian cross.
7278 * gcc-interface/Make-lang.in: Add support for canadian cross setting.
7279
993f8920
AC
72802011-08-05 Matthew Heaney <heaney@adacore.com>
7281
7282 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Child_Count, Child_Depth):
7283 subprogram bodies declared out-of-order.
7284
72852011-08-05 Yannick Moy <moy@adacore.com>
7286
7287 * sem_util.adb (Unique_Name): only prefix with "standard" the names of
7288 entities directly in package Standard, otherwise skip the standard
7289 prefix.
7290
9b3956dd
RD
72912011-08-05 Robert Dewar <dewar@adacore.com>
7292
7293 * a-cbmutr.adb: Minor reformatting
7294 (Allocate_Node): refactor node allocation algorithm
7295
72962011-08-05 Robert Dewar <dewar@adacore.com>
7297
7298 * opt.ads, opt.adb (Debug_Pragmas_Disabled): New switch.
7299 * sem_prag.adb (Analyze_Pragma, case Debug_Policy): Implement Disable
7300 mode.
7301 (Analyze_Pragma, case Check_Policy): Ditto.
7302 * sem_prag.ads (Check_Disabled): New function
7303 * snames.ads-tmpl: Add Name_Disable.
7304
73052011-08-05 Robert Dewar <dewar@adacore.com>
7306
7307 * gnat_rm.texi: Document implementation-defined policy DISABLE for
7308 pragmas Assertion_Policy, Check_Policy, Debug_Policy.
7309
79e705d6
AC
73102011-08-05 Ed Schonberg <schonberg@adacore.com>
7311
7312 * sem_prag.adb (Analyze_Pragma, case Inline): reject an Inline pragma
7313 that appears in a generic formal part and applies to a formal
7314 subprogram.
7315
73162011-08-05 Robert Dewar <dewar@adacore.com>
7317
7318 * a-cbmutr.ads: Minor reformatting.
7319
23b6deca
AC
73202011-08-05 Matthew Heaney <heaney@adacore.com>
7321
7322 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Read): do not use T'Valid
7323 to check count, check sign of value instead.
7324 * a-comutr.adb, a-cimutr.adb (Write): return immediately if tree empty
7325 (Copy_Subtree): allocate copy of source element
7326 (Equal_Subtree): compare elements, not access objects
7327
73282011-08-05 Vincent Celier <celier@adacore.com>
7329
7330 * gnat_ugn.texi: Fix VMS alternative.
7331
a2773bd3
AC
73322011-08-05 Thomas Quinot <quinot@adacore.com>
7333
7334 * sem_ch11.adb: Add comment.
7335
73362011-08-05 Robert Dewar <dewar@adacore.com>
7337
7338 * exp_util.adb: Minor comment fix.
7339
73402011-08-05 Robert Dewar <dewar@adacore.com>
7341
7342 * scng.adb (Error_Unterminated_String): Improve flag position when
7343 comma present.
7344
73452011-08-05 Matthew Heaney <heaney@adacore.com>
7346
7347 * Makefile.rtl, impunit.adb: Added a-cbmutr.ad[sb] (bounded multiway
7348 tree containers).
7349 * a-cbmutr.ads, a-cbmutr.adb: This is the new Ada 2012 unit for bounded
7350 multiway tree containers.
7351
73522011-08-05 Robert Dewar <dewar@adacore.com>
7353
7354 * styleg.adb (Check_Comment): Implement comment spacing of 1 or 2
7355 * stylesw.adb: Implement -gnatyC to control comment spacing
7356 * stylesw.ads (Style_Check_Comments_Spacing): New switch (set by
7357 -gnatyc/C).
7358 * usage.adb: Add line for -gnatyC.
7359
73602011-08-05 Robert Dewar <dewar@adacore.com>
7361
f446d60e 7362 * gnat_ugn.texi: Document -gnatyC.
a2773bd3
AC
7363 * vms_data.ads: Implement COMMENTS1/COMMENTS2 (retaining COMMENTS as a
7364 synonym for COMMENTS2).
7365
dedac3eb
RD
73662011-08-05 Robert Dewar <dewar@adacore.com>
7367
7368 * par_sco.adb, sem_ch3.adb, scos.ads, a-iteint.ads, sem_ch12.adb,
7369 a-cimutr.adb, a-cimutr.ads, sem_util.ads, sem_res.adb, a-fihema.adb,
7370 sem_ch4.adb, lib-xref-alfa.adb, exp_disp.adb, a-comutr.adb,
7371 a-comutr.ads, lib-xref.adb: Minor reformatting.
7372
73732011-08-05 Robert Dewar <dewar@adacore.com>
7374
7375 * sem_ch11.adb (Analyze_Raise_Statement): Kill assignment to formal
7376 warning if there is an exception handler present.
7377
7c62a85a
AC
73782011-08-05 Pascal Obry <obry@adacore.com>
7379
7380 * a-iteint.ads: Fix copyright year.
7381
73822011-08-05 Thomas Quinot <quinot@adacore.com>
7383
7384 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not generate a
7385 statement SCO for a USE clause or a representation clause.
7386
73872011-08-05 Yannick Moy <moy@adacore.com>
7388
7389 * lib-xref-alfa.adb (Collect_ALFA): generate the proper relation
7390 between body and spec for stub.
7391 (Detect_And_Add_ALFA_Scope): take into account subprogram stub
7392 * lib-xref.adb (Enclosing_Subprogram_Or_Package): in the case of a
7393 pragma precondition or postcondition, for which the enclosing
7394 subprogram or package in the AST is not the desired one, return empty.
7395
e49208a9
AC
73962011-08-05 Thomas Quinot <quinot@adacore.com>
7397
7398 * g-expect.adb: Minor reformatting.
7399
74002011-08-05 Bob Duff <duff@adacore.com>
7401
7402 * a-fihema.adb: Comment out OS_Lib.
7403
74042011-08-05 Matthew Heaney <heaney@adacore.com>
7405
7406 * Makefile.rtl, impunit.adb: Added a-c[oi]mutr.ad[sb]
7407 (unbounded multiway tree containers) and a-iteint.ads.
7408 * a-comutr.ads, a-comutr.adb:
7409 This is the new Ada 2012 unit for unbounded multiway tree containers
7410 * a-cimutr.ads, a-cimutr.adb
7411 This is the new Ada 2012 unit for indefinite multiway tree containers
7412 * a-iteint.ads: New file.
7413
201cdb74
RO
74142011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7415
f446d60e 7416 * gcc-interface/Makefile.in (raise-gcc.o): Search $(srcdir)/../libgcc.
201cdb74 7417
d50f4827
AC
74182011-08-05 Bob Duff <duff@adacore.com>
7419
7420 * sinfo.ads, sinfo.adb (Subpool_Handle_Name): New attribute for
7421 subpools.
7422 * par-ch4.adb (P_Allocator): Parse new subpool specification syntax.
7423
74242011-08-05 Ed Schonberg <schonberg@adacore.com>
7425
7426 * sem_ch4.adb (Try_Container_Indexing): New procedure to implement the
7427 general indexing aspects of Ada2012. Called when analyzing indexed
7428 components when other interpretations fail.
7429 * sem_ch8.adb (Find_Direct_Name): check for implicit dereference only
7430 in an expression context where overloading is meaningful. This excludes
7431 the occurrence in an aspect specification (efficiency only).
7432 * sem_attr.adb (Analyze_Attribute): indicate that the attributes
7433 related to iterators can be set by an attribute specification, but
7434 cannot be queried.
7435 * sem_ch13.adb (Analyze_Aspect_Specifications): handle
7436 Constant_Indexing and Variable_Indexing.
7437 (Check_Indexing_Functions): New procedure to perform legality checks.
7438 Additional semantic checks at end of declarations.
7439
efe05dfc
AC
74402011-08-05 Sergey Rybin <rybin@adacore.com>
7441
7442 * tree_io.ads: Update ASIS_Version_Number because of the change of the
7443 order of calling Tree_Write/Tree_Read routines made for aspects.
7444
74452011-08-05 Bob Duff <duff@adacore.com>
7446
7447 * a-fihema.adb (Finalize): Fix race condition.
7448
5f9cdefe
AC
74492011-08-05 Yannick Moy <moy@adacore.com>
7450
7451 * sem_ch12.adb (Analyze_Package_Instantiation,
7452 Need_Subprogram_Instance_Body): do not generate instance bodies in ALFA
7453 mode.
7454
74552011-08-05 Ed Schonberg <schonberg@adacore.com>
7456
7457 * sem_type.adb (Specific_Type): in an instance, the type-specific
7458 operand of an equality check that involves null may have a private
7459 type. Use full view to determine legality of construct.
7460
822868aa
AC
74612011-08-05 Vincent Celier <celier@adacore.com>
7462
7463 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
7464 delete or close the file when the call to gnatmake was successful.
7465
74662011-08-05 Yannick Moy <moy@adacore.com>
7467
7468 * gnat1drv.adb (Adjust_Global_Switches): in ALFA mode, set
7469 Global_Discard_Names.
7470
74712011-08-05 Ed Schonberg <schonberg@adacore.com>
7472
7473 * sinfo.ads: comments on use of entity field for aspect specifications.
7474
74752011-08-05 Ed Schonberg <schonberg@adacore.com>
7476
7477 * sem_ch12.adb (Reset_Entity): If the entity field of the associated
7478 node is not itself an entity but a selected component, it is a
7479 rewritten parameterless call to an en enclosing synchronized operation,
7480 and this expansion will be performed again in the instance, so there is
7481 no global information to preserve.
7482
44a10091
AC
74832011-08-05 Javier Miranda <miranda@adacore.com>
7484
7485 * exp_disp.adb (Set_All_DT_Position): Cleanup code and improve support
7486 for renamings of predefined primitives.
7487 (In_Predef_Prims_DT): New subprogram.
7488
74892011-08-05 Ed Schonberg <schonberg@adacore.com>
7490
7491 * sem_util.adb, sem_util.ads (Check_Implicit_Dereference): If a
7492 possible interpretation of name is a reference type, add an
7493 interpretation that is the designated type of the reference
7494 discriminant of that type.
7495 * sem_res.adb (resolve): If the interpretation imposed by context is an
7496 implicit dereference, rewrite the node as the deference of the
7497 reference discriminant.
7498 * sem_ch3.adb (Analyze_Subtype_Declaration, Build_Derived_Record_Type,
7499 Build_Discriminated_Subtype): Inherit Has_Implicit_Dereference from
7500 parent type or base type.
7501 * sem_ch4.adb (Process_Indexed_Component,
7502 Process_Overloaded_Indexed_Component, Indicate_Name_And_Type,
7503 Analyze_Overloaded_Selected_Component, Analyze_Selected_Component):
7504 Check for implicit dereference.
7505 (List_Operand_Interps): Indicate when an implicit dereference is
7506 ambiguous.
7507 * sem_ch8.adb (Find_Direct_Name): Check for implicit dereference.
7508
75092011-08-05 Thomas Quinot <quinot@adacore.com>
7510
7511 * scos.ads: Update documentation of SCO table. Pragma statements can now
7512 be marked as disabled (using 'p' instead of 'P' as the statement kind).
7513 * par_sco.ads, par_sco.adb: Implement the above change.
7514 (Process_Decisions_Defer): Generate a P decision for the first parameter
7515 of a dyadic pragma Debug.
7516 * sem_prag.adb (Analyze_Pragma, case Debug): Mark pragma as enabled if
7517 necessary.
7518 * put_scos.adb: Code simplification based on above change.
7519
bb3c784c
AC
75202011-08-05 Robert Dewar <dewar@adacore.com>
7521
7522 * sem_ch3.adb, gnatcmd.adb, switch-c.adb, exp_attr.adb, make.adb,
7523 bindgen.adb, einfo.adb, sem_ch12.adb, sem_attr.adb, a-fihema.adb,
7524 a-fihema.ads, sem_elab.adb, sem_elab.ads, aspects.adb, opt.ads,
7525 prj-conf.adb, sem_ch13.adb, s-ficobl.ads: Minor reformatting
7526
75272011-08-05 Bob Duff <duff@adacore.com>
7528
7529 * a-stunau.ads, g-spipat.adb: Update comments.
7530
36f686f9
BD
75312011-08-05 Bob Duff <duff@adacore.com>
7532
7533 * a-fihema.ads: Minor comment fix.
7534 * a-fihema.adb (Allocate, Deallocate): Assert that the alignment is
7535 correct.
7536 (Attach, Detach): Remove some unnecessary code.
7537 (Finalize): Remove Node_Ptr_To_Address, replace with a constant.
7538
7882673f
BD
75392011-08-05 Bob Duff <duff@adacore.com>
7540
7541 * a-fihema.ads, a-fihema.adb (Finalization_Collection): Avoid heap
7542 allocation for Objects component. This simplifies the code somewhat. It
7543 is also a little more efficient in the not-so-unusual case where there
7544 are no controlled objects allocated.
7545 Make Finalization_Started flag atomic.
7546 (Finalize): Avoid unnecessary detachment of items from the list.
7547 (pcol): Minor cleanup.
7548
d34cd274
AC
75492011-08-05 Ed Schonberg <schonberg@adacore.com>
7550
7551 * sem_ch12.adb (Analyze_Formal_Package_Declaration): reject a formal
7552 package whose name is the same as that of the generic unit, or its
7553 ultimate prefix.
7554
75552011-08-05 Bob Duff <duff@adacore.com>
7556
7557 * a-fihema.adb, a-fihema.ads: Minor comment improvements.
7558 * sem_ch3.adb, exp_ch5.adb, exp_ch7.adb, exp_ch7.ads, exp_util.adb:
7559 Minor comment fixes.
7560
00332244
AC
75612011-08-05 Arnaud Charlet <charlet@adacore.com>
7562
7563 * make.adb (Linking_Phase): No longer need to set source search path
7564 before calling gnatlink in CodePeer mode.
7565 * gnatlink.adb (Gnatlink): No longer pass -gnat83/95/05/12 switch to
7566 gcc in CodePeer mode, since the binder generated file no longer has a
7567 'with Main'.
7568 * switch.ads, switch.adb (Is_Language_Switch): Removed.
7569 * switch-c.adb: Update comment.
7570
75712011-08-05 Thomas Quinot <quinot@adacore.com>
7572
7573 * exp_strm.adb, bindgen.adb, s-ficobl.ads: Minor reformatting.
7574
75752011-08-05 Nicolas Roche <roche@adacore.com>
7576
7577 * gnat_ugn.texi: Fix minor syntax error issue.
7578
75792011-08-05 Vincent Celier <celier@adacore.com>
7580
7581 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
7582 delete or close the file when the call to gnatmake returns a non
7583 successful return code.
7584
75852011-08-05 Ed Schonberg <schonberg@adacore.com>
7586
7587 * exp_ch4.adb (Expand_N_Type_Conversion): When expanding a predicate
7588 check, indicate that the copy of the original node does not come from
7589 source, to prevent an infinite recursion of the expansion.
7590
75912011-08-05 Johannes Kanig <kanig@adacore.com>
7592
7593 * debug.adb: document switch -gnatd.G for gnat2why, which deactivates
7594 VC generation for subprogram bodies.
7595
75962011-08-05 Yannick Moy <moy@adacore.com>
7597
7598 * einfo.ads: Typo.
7599 * sem_ch3.adb (Signed_Integer_Type_Declaration): in ALFA mode, define
7600 the base type with the smallest allowed base type.
7601
76022011-08-05 Sergey Rybin <rybin@adacore.com>
7603
7604 * tree_gen.adb, tree_in.adb, aspects.adb: Fix tree read-write for
7605 aspects.
7606
76072011-08-05 Ed Schonberg <schonberg@adacore.com>
7608
7609 * sem_ch12.ads: minor comment updates.
7610
76112011-08-05 Ed Schonberg <schonberg@adacore.com>
7612
7613 * sem_ch12.adb (Analyze_Formal_Package_Declaration): in an
7614 instantiation and a formal package the compiler generates a package
7615 renaming declaration so that the generic name within the declaration
7616 is interpreted as a renaming of the instance. At the end of a formal
7617 package declaration, this renaming must become invisible.
7618
0da80d7d
AC
76192011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
7620
7621 * exp_ch7.adb (Is_Init_Call): Reimplemented to avoid character
7622 comparison and rely on concrete entities instead.
7623
76242011-08-05 Ed Schonberg <schonberg@adacore.com>
7625
7626 * einfo.ads, einfo.adb (Has_Implicit_Dereference): new flag on types
7627 and discriminants, to indicate that the type has an access discriminant
7628 that supports implicit dereference.
7629 * snames.ads-tmpl: Add names of aspects and attributes related to
7630 Ada2012 iterators: constant_indexing, default_iterator,
7631 iterator_element, implicit_dereference, variable_indexing.
7632 * aspects.ads, aspects.adb: entries for iterator-related aspects.
7633 * sem_ch13.adb (Analyze_aspect_specifications): dummy entries for
7634 iterator-related aspects.
7635 * sem_attr.adb, exp_attr.adb Dummy entries for iterator-related aspects.
7636
76372011-08-05 Sergey Rybin <rybin@adacore.com>
7638
7639 * gnat_ugn.texi, vms_data.ads: Extend the subsection about coupling
7640 metrics in gnatmetric to cover new kinds of coupling mentrics.
7641
76422011-08-05 Steve Baird <baird@adacore.com>
7643
7644 * bindgen.adb (Gen_CodePeer_Wrapper): Call Ada_Main_Program instead
2c7f9cc0 7645 of calling the user-defined main subprogram.
0da80d7d
AC
7646 (Gen_Main): Declare Ada_Main_Program and (if CodePeer_Mode
7647 is set) Call_Main_Subprogram ahead of, as opposed to
7648 inside of, Main.
7649 (Gen_Output_File_Ada): Remove CodePeer_Mode-conditional
7650 generation of a "with" of the user-defined main subprogram.
7651 Remove CodePeer_Mode-conditional call to Gen_CodePeer_Wrapper
7652 (which is now called from Gen_Main instead).
7653
73242473
AC
76542011-08-05 Emmanuel Briot <briot@adacore.com>
7655
7656 * projects.texi: Added reference to the Makefile package.
7657
76582011-08-05 Thomas Quinot <quinot@adacore.com>
7659
7660 * exp_ch7.adb: Minor comment rewording.
7661
76622011-08-05 Ed Falis <falis@adacore.com>
7663
7664 * env.c: Fix comment.
7665
76662011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
7667
7668 * sem_elab.adb (Is_Finalization_Procedure): Reimplemented to avoid
7669 character comparison and rely on concrete entities instead.
7670
97ed5872
AC
76712011-08-05 Ed Schonberg <schonberg@adacore.com>
7672
7673 * sem_ch3.adb: (Check_Private_Overriding): better error message,
7674 suggested by AI95-0068.
7675
76762011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
7677
7678 * exp_ch7.adb (Find_Last_Init): Use Next_Suitable_Statement to retrieve
7679 the two potential initialization calls. This accounts for any
7680 access-before-elaboration checks which may precede the initialization
7681 calls.
7682 (Next_Suitable_Statement): New routine. Returns the next real statement
7683 after the input node while skipping generated checks.
7684 * sem_elab.adb (Check_A_Call): New formal parameter In_Init_Proc along
7685 with comment on usage.
7686 Do not generate Elaborate_All when the trigger is a finalization call
7687 coming from a type init proc.
7688 (Check_Elab_Call): Propagate the initialization procedure context to
7689 subsequent calls to Check_A_Call.
7690 (Check_Internal_Call_Continue): Propagate the initialization procedure
7691 context to subsequent calls to Check_Elab_Call.
7692 (Is_Finalization_Procedure): New routine. Returns True if the input
7693 entity denotes a [Deep_]Finalize routine.
7694 * sem_elab.ads (Check_Elab_Call): New formal parameter In_Init_Proc
7695 along with comment on usage.
7696
76972011-08-05 Vadim Godunko <godunko@adacore.com>
7698
7699 * s-atocou.ads: Add list of supported platforms.
7700
77012011-08-05 Yannick Moy <moy@adacore.com>
7702
7703 * sem_prag.adb, restrict.adb: Correct style for or'ing Boolean variables
7704
7705 * opt.ads (Disable_ALI_File): new Boolean flag
7706 * lib-writ.adb (Write_ALI): when Disable_ALI_File is set, do nothing
7707
77082011-08-05 Ed Falis <falis@adacore.com>
7709
7710 * env.c (__gnat_environ): Fix includes for RTPs and VTHREADS so that
7711 environ is properly defined.
7712
77132011-08-05 Vincent Celier <celier@adacore.com>
7714
7715 * make.adb (Compilation_Phase): Exit immediately when all objects have
7716 been found up to date, to avoid multiple exit messages.
7717 * prj-nmsc.adb (Add_Source): Allow duplicate source file names in the
7718 same project for languages with no compiler.
7719 * gnat_ugn.texi: Document compiler switch -gnateI and gnatmake switch
7720 -eI.
9aff36e9
RD
77212011-08-05 Robert Dewar <dewar@adacore.com>
7722
7723 * exp_ch7.ads, sem_type.adb, make.adb, sem_prag.adb, sem_util.adb,
7724 sem_util.ads, sem_attr.adb, restrict.ads, sem_ch6.adb, prj-conf.adb,
7725 prj-conf.ads, s-atocou.ads, s-atocou.adb, s-atocou-x86.adb,
7726 s-atocou-builtin.adb: Minor reformatting.
7727
406935b6
AC
77282011-08-05 Yannick Moy <moy@adacore.com>
7729
7730 * exp_ch7.adb (Establish_Transient_Scope): in formal verification mode,
7731 if the node to wrap is a pragma check, this node and enclosed
7732 expression are not expanded, so do not apply any transformations here.
7733 * exp_prag.adb (Expand_Pragma_Check): document the need to avoid
7734 introducing transient scopes.
7735
77362011-08-05 Jose Ruiz <ruiz@adacore.com>
7737
7738 * adaint.c (__gnat_set_writable, __gnat_set_readable,
7739 __gnat_set_executable, __gnat_set_non_writable, __gnat_set_non_readable,
7740 __gnat_copy_attribs): On VxWorks 6.x and later, the required chmod
7741 routine is available, so we use the default implementation of these
7742 functions.
7743 * s-os_lib.ads (Copy_File, Copy_Time_Stamps): Document that there is
7744 support for copying attributes on VxWorks 6.
7745
77462011-08-05 Yannick Moy <moy@adacore.com>
7747
7748 * debug.adb: Remove use of -gnatd.D.
7749 * gnat1drv.adb (Adjust_Global_Switches): adjust switches for ALFA mode
7750 * opt.ads: Simplify variables for ALFA mode, to keep one only
7751 * restrict.adb, sem_prag.adb: Adapt treatment done for CodePeer mode
7752 to ALFA mode.
7753
77542011-08-05 Vincent Celier <celier@adacore.com>
7755
7756 * prj-conf.adb (Do_Autoconf): Look also for --RTS in
7757 Builder'Default_Switches.
7758
77592011-08-05 Vincent Celier <celier@adacore.com>
7760
7761 * makeusg.adb: Add lines for --create-map-file switches.
7762
77632011-08-05 Ed Schonberg <schonberg@adacore.com>
7764
7765 * freeze.adb (Freeze_Entity): For a subprogram, if a type in the
7766 profile is incomplete and the full view is available, replace it with
7767 the full view.
7768 * sem_ch6.adb (Possible_Freeze): if a type in the profile is
7769 incomplete, freezing the subprogram is delayed until the full view is
7770 frozen.
7771 * sem_type.adb (Disambiguate): an ambiguity between a user-defined
7772 fixed-point multiplication operator and the predefined operator is
7773 resolved in favor of the user-defined one.
7774
96c891b3
RO
77752011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7776
7777 * init.c [__alpha__ && __osf__] (__gnat_error_handler): Use
7778 CONST_CAST.
7779
276e7ed0
AC
77802011-08-04 Ed Schonberg <schonberg@adacore.com>
7781
7782 * sem_util.ads, sem_unit.adb (Type_Without_Stream_Operation): determine
7783 whether a type lacks user-defined Read or Write operations, or has a
7784 component that lacks them.
7785 * sem_attr.adb (Check_Stream_Attribute): if restriction
7786 No_Default_Stream_Attributes is active, verify that all subcomponent
7787 types of the target have user-defined stream operations, and report
7788 error otherwise.
7789 * exp_ch3.adb (Stream_Operqtion_OK): use Type_Without_Stream_Operation.
7790 * exp_strm.adb: Build_Elementary_Input_Call,
7791 Build_Elementary_Write_Call): remove checks for restriction
7792 No_Default_Stream_Attributes, now checked in semantics.
7793
77942011-08-04 Vincent Celier <celier@adacore.com>
7795
7796 * prj-conf.ads, prj-conf.adb (Do_Autoconf): If there is no --RTS
7797 switches on the command line, look for all valid --RTS switches in the
7798 Builder switches and for each language use the first runtime name found
7799 to invoke gprconfig.
7800 (Get_Or_Create_Configuration_File): Warn if --RTS is specified on the
7801 command line and there is no auto-configuration.
7802 (Runtime_Name_Set_For): New function.
7803
78042011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7805
7806 * exp_ch7.adb (Build_Object_Declarations): Do not generate the
7807 elaborate initialization expression for variable Abort when processing
7808 a package body or a declaration.
7809 (Create_Finalizer): Propagate the package context when creating the
7810 exception-related variables.
7811 * exp_ch7.ads (Build_Object_Declarations): New formal parameter
7812 For_Package along with usage comment.
7813
19172ae9
AC
78142011-08-04 Arnaud Charlet <charlet@adacore.com>
7815
7816 * gcc-interface/Makefile.in: Clean up targets.
7817 Enable new package for atomic counters and copy-on-write implementation
7818 of unbounded strings on x86 platforms.
7819 * gcc-interface/Make-lang.in: Update dependencies.
7820
0319cacc
AC
78212011-08-04 Robert Dewar <dewar@adacore.com>
7822
7823 * exp_ch7.adb: Minor reformatting.
7824
78252011-08-04 Robert Dewar <dewar@adacore.com>
7826
7827 * exp_strm.adb: Minor reformatting.
7828
78292011-08-04 Vadim Godunko <godunko@adacore.com>
7830
7831 * s-atocou.adb: Replace by dummy version and use on targets where atomic
7832 operations are not supported.
7833 * s-atocou-builtin.adb: Renamed from s-atocou.adb.
7834 * s-atocou-x86.adb: New file.
7835 * Makefile.rtl: Add s-atocou.o file
7836
78372011-08-04 Arnaud Charlet <charlet@adacore.com>
7838
7839 * make.adb (Compile): Move setting of CodePeer_Mode to ...
7840 (Compilation_Phase): ... here.
7841 (Scan_Make_Arg): Now bind and link by default in CodePeer mode.
7842
78432011-08-04 Thomas Quinot <quinot@adacore.com>
7844
7845 * Make-generated.in: Fix minor typo in comment.
7846
26e7e1a0
AC
78472011-08-04 Thomas Quinot <quinot@adacore.com>
7848
7849 * gnatls.adb: Use Prj.Env.Initialize_Default_Project_Path to retrieve
7850 the project path.
7851
78522011-08-04 Robert Dewar <dewar@adacore.com>
7853
7854 * a-coinho.adb: Minor reformatting.
7855
78562011-08-04 Robert Dewar <dewar@adacore.com>
7857
7858 * a-coinho.ads: Minor reformatting.
7859
78602011-08-04 Vadim Godunko <godunko@adacore.com>
7861
7862 * s-atocou.ads, s-atocou.adb: New files.
7863 * a-strunb-shared.ads, a-strunb-shared.adb, a-stwiun-shared.ads,
7864 a-stwiun-shared.adb, a-stzunb-shared.ads, a-stzunb-shared.adb: Remove
7865 direct use of GCC's atomic builtins and replace them by use of new
7866 atomic counter package.
7867
78682011-08-04 Ed Schonberg <schonberg@adacore.com>
7869
7870 * exp_strm.adb: better error message for No_Default_Stream_Attributes.
7871
78722011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7873
7874 * a-tags.adb (Unregister_Tag): Replace the complex address arithmetic
7875 with a call to Get_External_Tag.
7876 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on
7877 subprogram usage. Remove the guard against package declarations and
7878 bodies since Build_Cleanup_Statements is no longer invoked in that
7879 context.
7880 (Build_Components): Initialize Tagged_Type_Stmts when the context
7881 contains at least one library-level tagged type.
7882 (Build_Finalizer): New local variables Has_Tagged_Types and
7883 Tagged_Type_Stmts along with associated comments on usage. Update the
7884 logic to include tagged type processing.
7885 (Create_Finalizer): Insert all library-level tagged type unregistration
7886 code before the jump block circuitry.
7887 (Expand_N_Package_Body): Remove the call to Build_Cleanup_Statements.
7888 (Expand_N_Package_Declaration): Remove the call to
7889 Build_Cleanup_Statements.
7890 (Process_Tagged_Type_Declaration): New routine. Generate a call to
7891 unregister the external tag of a tagged type.
7892 (Processing_Actions): Reimplemented to handle tagged types.
7893 (Process_Declarations): Detect the declaration of a library-level
7894 tagged type and carry out the appropriate actions.
7895 (Unregister_Tagged_Types): Removed. The machinery has been directly
7896 merged with Build_Finalizer.
7897
7483c888
AC
78982011-08-04 Robert Dewar <dewar@adacore.com>
7899
7900 * bindgen.ads, gnatlink.adb, sem_ch4.adb, gnatbind.adb, put_alfa.adb,
7901 gnatls.adb, exp_ch3.adb: Minor reformatting.
7902
79032011-08-04 Marc Sango <sango@adacore.com>
7904
7905 * sem_attr.adb (Analyze_Attribute): Replace the message
7906 "invisible attribute of}" of the spark restriction violation in
7907 attribute reference by the simple message "invisible attribute of type".
7908 Indeed, the node value Error_Msg_Node_1 used is in conflit with the
7909 two insertion characters: '&' and '}'.
7910
79112011-08-04 Vadim Godunko <godunko@adacore.com>
7912
7913 * impunit.adb (Non_Imp_File_Names_12): Add "a-coinho".
7914 * a-coinho.ads, a-coinho.adb: New file.
7915 * Makefile.rtl: Add Ada.Containers.Indefinite_Holders.
7916
5207696c
AC
79172011-08-04 Nicolas Roche <roche@adacore.com>
7918
7919 * alfa_test.adb: Not all ali files are containing alfa information even
7920 if compiled with -gnatd.F. So suppress warning about missing ALFA
7921 information.
7922
79232011-08-04 Yannick Moy <moy@adacore.com>
7924
7925 * lib-xref-alfa.adb (Add_ALFA_Scope): use non-empty unique name for
7926 scope.
7927 * put_alfa.adb: Check that scope name is not empty.
7928
79292011-08-04 Ed Schonberg <schonberg@adacore.com>
7930
7931 * exp_ch3.adb (Stream_Operation_Ok): new predicate
7932 Needs_Elementary_Stream_Operation, to determine whether user-defined
7933 Read and Write attributes are available for the elementary components
7934 of the given type. If only the predefined attributes are available,
7935 then when restriction No_Default_Stream_Attributes is active the
7936 predefined stream attributes for the composite type cannot be created.
7937
79382011-08-04 Robert Dewar <dewar@adacore.com>
7939
7940 * bindgen.adb: Fix obsolete comments and names from Ada/C days.
7941 Put routines in alpha order
7942
2bd2d858
JR
79432011-08-04 Jose Ruiz <ruiz@adacore.com>
7944
7945 * gcc-interface/Makefile.in: Remove xenomai specific versions of system.
7946 * gcc-interface/Make-lang.in: Update dependencies.
7947
8fae6016
AC
79482011-08-04 Arnaud Charlet <charlet@adacore.com>
7949
7950 * gcc-interface/lang.opt: Add AdaWhy language, simimlar to Ada.
7951 * gcc-interface/lang-specs.h: Add handling of AdaWhy specs (calls
7952 gnat1why).
7953
a54d0eb4
AC
79542011-08-04 Robert Dewar <dewar@adacore.com>
7955
7956 * sem_ch3.adb, make.adb, a-cohata.ads, sem_prag.adb, makeutl.adb,
7957 lib-xref-alfa.adb: Minor reformatting.
7958
79592011-08-04 Marc Sango <sango@adacore.com>
7960
7961 * sem_ch12.adb (Analyze_Generic_Package_Declaration,
7962 Analyze_Generic_Subprogram_Declaration, Analyze_Package_Instantiation,
7963 Analyze_Subprogram_Instantiation): Check absence of generic in SPARK
7964 mode.
7965
79662011-08-04 Tristan Gingold <gingold@adacore.com>
7967
7968 * bindgen.adb (Gen_Adainit_C): Remove.
7969 (Gen_Adafinal_C): Ditto.
7970 (Gen_Elab_Externals_C): Ditto.
7971 (Gen_Elab_Calls_C): Ditto.
7972 (Gen_Elab_Order_C): Ditto.
7973 (Gen_Elab_Defs_C): Ditto.
7974 (Gen_Finalize_Library_C): Ditto.
7975 (Gen_Finalize_Library_Defs_C): Ditto.
7976 (Gen_Main_C): Ditto.
7977 (Gen_Output_File_C): Ditto.
7978 (Gen_Restrictions_C): Ditto.
7979 (Gen_Versions_C): Ditto.
7980 (Write_Info_Ada_C): Ditto.
7981 (Gen_Object_Files_Options): Call WBI instead of Write_Info_Ada_C
7982 (Gen_Output_File): Do not force Ada_Bind_File anymore.
7983 Always call Gen_Output_File_Ada.
7984 * gnatlink.adb (Begin_Info): Now a constant.
7985 (End_Info): Ditto.
7986 (Ada_Bind_File): Remove
7987 (Process_Args): Do not handle -A/-C. Remove not Ada_Bind_File cases.
7988 * switch-b.adb (Scan_Binder_Switches): Do not handle -C.
7989 * gnatbind.adb (Gnatbind): Remove not Ada_Bind_File cases.
7990 * opt.ads (Ada_Bind_File): Remove.
7991
79922011-08-04 Thomas Quinot <quinot@adacore.com>
7993
7994 * projects.texi: Document target-specific directory in default project
7995 path for gnatmake.
7996
79972011-08-04 Thomas Quinot <quinot@adacore.com>
7998
7999 * gnatls.adb, prj-env.adb: Add $prefix/share/gpr to default project
8000 path in all cases .
8001
24558db8
AC
80022011-08-04 Yannick Moy <moy@adacore.com>
8003
8004 * sem_ch3.adb, sem_ch5.adb, sem_util.adb, sem_ch4.adb, sem_ch8.adb,
8005 opt.ads, lib-xref.ads: Code clean up.
8006
80072011-08-04 Yannick Moy <moy@adacore.com>
8008
8009 * gnat_rm.texi: Update description of Test_Case
8010 * gnat_ugn.texi: Typo.
8011
80122011-08-04 Ed Falis <falis@adacore.com>
8013
8014 * adaint.c (__gnat_get_number_of_cpus): fix typo in last checkin.
8015
80162011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8017
8018 * exp_ch4.adb (Suitable_Element): Skip field _parent on .NET/JVM when
8019 it is of type Root_Controlled. This action eliminates fields Prev and
8020 Next from type equality.
8021
80222011-08-04 Yannick Moy <moy@adacore.com>
8023
8024 * lib-xref-alfa.adb: Correct typo.
8025
80262011-08-04 Matthew Heaney <heaney@adacore.com>
8027
8028 * a-cohata.ads (Hash_Table_Type): default-initialize the Nodes
8029 component.
8030
1f9939b5
AC
80312011-08-04 Yannick Moy <moy@adacore.com>
8032
8033 * sem_prag.adb (Check_Arg_Is_String_Literal): remove useless procedure
8034 (Analyze_Pragma): allow static string expression for name of Test_Case,
8035 instead of simply string literals.
8036 * sem_util.adb (Get_Name_From_Test_Case_Pragma): adapt to static string
8037 expressions.
8038
80392011-08-04 Vincent Celier <celier@adacore.com>
8040
8041 * makeutl.adb (Complete_Mains.Find_File_Add_Extension): Use canonical
8042 case suffixes to find truncated main sources.
8043
80442011-08-04 Tristan Gingold <gingold@adacore.com>
8045
8046 * impunit.adb (Non_Imp_File_Names_95): Add g-tastus.
8047 s-stusta.adb (Compute_All_Task): Use Put_Line instead of Put.
8048 (Compute_Current_Task): Ditto.
8049
80502011-08-04 Tristan Gingold <gingold@adacore.com>
8051
8052 * gnat_ugn.texi: Mention GNAT.Task_Stack_Usage.
8053
80542011-08-04 Yannick Moy <moy@adacore.com>
8055
8056 * lib-xref-alfa.adb (Is_Global_Constant): new function that detects
8057 library-level constant.
8058 (Add_ALFA_Xrefs): ignore global constants in ALFA xref.
8059 * sem_res.adb (Resolve_Actuals): do not add cross-reference to Formal
8060 used as selector of parameter association, in ALFA mode.
8061
15d8a51d
AC
80622011-08-04 Robert Dewar <dewar@adacore.com>
8063
8064 * exp_ch5.adb, exp_ch7.adb, exp_util.adb, bindgen.adb, sem_prag.adb,
8065 s-tassta.adb, exp_ch4.adb, exp_disp.adb, s-stausa.adb: Minor
8066 reformatting.
8067
80682011-08-04 Arnaud Charlet <charlet@adacore.com>
8069
8070 * make.adb (Linking_Phase): Set source search path before calling
8071 gnatlink in CodePeer mode.
8072
f46faa08
AC
80732011-08-04 Javier Miranda <miranda@adacore.com>
8074
8075 * exp_ch7.adb (Expand_N_Package_Body, Expand_N_Package_Declaration):
8076 Remove code which takes care of building TSDs.
8077 * rtsfind.ads (RE_Check_Interface_Conversion): New entity.
8078 * exp_ch4.adb (Apply_Accessibility_Check): Add support for generating
8079 the accessibility check in VM targets.
8080 * exp_disp.adb (Make_VM_TSD): Spec moved to exp_disp.ads
8081 (Building_Static_DT): Now returns false for VM targets.
8082 (Build_VM_TSDs): Removed.
8083 (Expand_Interface_Conversion): Generate missing runtime check for
8084 conversions to interface types whose target type is unknown at compile
8085 time.
8086 (Make_VM_TSD): Add missing code to disable the generation of calls to
8087 Check_TSD if the tagged type is not defined at library level, or not
8088 has a representation clause specifying its external tag, or -gnatdQ is
8089 active.
8090 * exp_disp.ads (Build_VM_TSDs): Removed.
8091 (Make_VM_TSDs): Spec relocated from exp_disp.adb
8092 * sem_disp.adb (Check_Dispatching_Operation): No code required to
8093 register primitives in the dispatch tables in VM targets.
8094 * exp_ch3.adb (Expand_N_Object_Declaration): Remove wrong expansion of
8095 initialization of class-wide interface objects in VM targets.
8096 (Expand_Freeze_Record_Type): For VM targets call Make_VM_TSD (instead
8097 of Make_DT).
8098
80992011-08-04 Jerome Lambourg <lambourg@adacore.com>
8100
8101 * gnatlink.adb (Gnatlink): Correct missleading error message displayed
8102 when dotnet-ld cannot be found.
8103
81042011-08-04 Arnaud Charlet <charlet@adacore.com>
8105
8106 * bindgen.adb: Simplify significantly generation of binder body file in
8107 CodePeer mode.
8108 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Prevent assert failure
8109 when compiling binder generated file in CodePeer mode (xxx'Elab_Spec
8110 not expanded).
8111
2ba7e31e
AC
81122011-08-04 Yannick Moy <moy@adacore.com>
8113
8114 * sem_prag.adb, sem.ads: Code cleanup.
8115
81162011-08-04 Tristan Gingold <gingold@adacore.com>
8117
8118 * s-tassta.adb (Task_Wrapper): Rewrite the dynamic stack usage part.
8119 * s-stausa.adb, s-stausa.ads: Major rewrite. Now provides accurate
8120 results if possible.
8121 * s-stusta.adb (Print): Adjust after changes in s-stausa.
8122 * gnat_ugn.texi: Update dynamic stack usage section.
8123
81242011-08-04 Steve Baird <baird@adacore.com>
8125
8126 * bindgen.adb (Gen_CodePeer_Wrapper): new procedure.
8127 Generate (if CodePeer_Mode is set) a "wrapper" subprogram which
8128 contains only a call to the user-defined main subprogram.
8129 (Gen_Main_Ada) - If CodePeer_Mode is set, then
8130 call the "wrapper" subprogram instead of directly
8131 calling the user-defined main subprogram.
8132
81332011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8134
8135 * exp_ch5.adb (Expand_N_Case_Statement): Check the statements of all
8136 alternatives of a case statement for controlled objects. Rename local
8137 variable A to Dead_Alt.
8138 (Expand_N_If_Statement): Check the then and else statements of an if
8139 statement for controlled objects. Check the then statements of all
8140 elsif parts of an if statement for controlled objects.
8141 (Expand_N_Loop_Statement): Check the statements of a loop for controlled
8142 objects.
8143 * exp_ch7.adb (Process_Transient_Objects): Rewrite the condition which
8144 detects a loop associated with the expansion of an array object.
8145 Augment the processing of the loop statements to account for a possible
8146 wrap done by Process_Statements_For_Controlled_Objects.
8147 * exp_ch9.adb (Expand_N_Asynchronous_Select): Check the triggering
8148 statements and abortable part of an asynchronous select for controlled
8149 objects.
8150 (Expand_N_Conditional_Entry_Call): Check the else statements of a
8151 conditional entry call for controlled objects.
8152 (Expand_N_Selective_Accept): Check the alternatives of a selective
8153 accept for controlled objects.
8154 (Expand_N_Timed_Entry_Call): Check the entry call and delay
8155 alternatives of a timed entry call for controlled objects.
8156 * exp_ch11.adb (Expand_Exception_Handlers): Check the statements of an
8157 exception handler for controlled objects.
8158 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
8159 Add formal parameter Nested_Constructs along with its associated
8160 comment.
8161 (Requires_Cleanup_Actions (Node_Id)): Update all calls to
8162 Requires_Cleanup_Actions.
8163 (Process_Statements_For_Controlled_Objects): New routine.
8164 * exp_util.ads (Process_Statements_For_Controlled_Objects): New
8165 routine. Inspect a node which contains a non-handled sequence of
8166 statements for controlled objects. If such an object is found, the
8167 statements are wrapped in a block.
8168
1bf773bb
AC
81692011-08-04 Bob Duff <duff@adacore.com>
8170
8171 * sem_type.adb (Covers): If T2 is a subtype of a class-wide type, we
8172 need to compare with Class_Wide_Type (T2), in order to get at the
8173 original class-wide type node.
8174 * sem_type.ads (Covers): Improve the comment.
8175 * einfo.ads (Class_Wide_Type): Improve the comment.
8176 * exp_intr.adb (Expand_Unc_Deallocation): Remove unnecessary setting of
8177 the type of the Deref.
8178
81792011-08-04 Yannick Moy <moy@adacore.com>
8180
8181 * gnat_rm.texi: Document that Test_Case pragma can only appear on
8182 separate declarations.
8183 * sem_prag.adb (procedure Check_Identifier_Is_One_Of): new procedure to
8184 check identifier of pragma argument.
8185 (Chain_TC): check that no other test case associated to the same entity
8186 share the same name.
8187 (Check_Test_Case): disallow test case inside subprogram body
8188 (Analyze_Pragma): correct call to check identifier and not argument
8189 * sem_util.adb, sem_util.ads (Get_Name_From_Test_Case_Pragma): new
8190 function gets name from test case pragma.
8191
dac3bede
YM
81922011-08-04 Yannick Moy <moy@adacore.com>
8193
8194 * gnat_rm.texi: Document new pragma and aspect.
8195 * aspects.adb, aspects.ads (Aspect_Id): new value Aspect_Test_Case
8196 (No_Duplicates_Allowed): new constant array defining whether duplicates
8197 aspects of each kind can appear on the same declaration.
8198 * einfo.adb, einfo.ads (Spec_PPC_List): replace field with Contract
8199 field, which points to a node holding the previous Spec_PPC_List.
8200 * exp_ch9.adb, sem_ch6.adb, sem_prag.adb: Reach to Spec_PPC_List
8201 through the indirection with Contract.
8202 * exp_util.adb (Insert_Actions): raise Program_Error on N_Contract node
8203 * par-prag.adb (Prag): do nothing on Test_Case pragma
8204 * sem.adb (Analyze): abort on N_Contract, on which Analyze should not
8205 be called directly.
8206 * sem_attr.adb (Analyze_Attribute): allow attribute 'Result in
8207 component Ensures of Test_Case.
8208 * sem_ch12.adb, sem_ch6.adb, sem_ch9.adb
8209 (Analyze_Generic_Subprogram_Declaration,
8210 Analyze_Subprogram_Instantiation,
8211 Analyze_Abstract_Subprogram_Declaration,
8212 Analyze_Subprogram_Body_Helper,
8213 Analyze_Subprogram_Specification, Analyze_Entry_Declaration):
8214 insert contract in subprogram node at point of definition
8215 * sem_ch13.adb
8216 (Aspect_Loop): do not raise error on duplicate Test_Case aspect
8217 (Analyze_Aspect_Specifications): analyze Test_Case aspect and create
8218 corresponding pragma
8219 (Check_Aspect_At_Freeze_Point): raise Program_Error on Test_Case aspect
8220 * sem_ch3.adb (Analyze_Declarations): insert analysis of test-cases,
8221 similar to the analysis of pre/post
8222 (Derive_Subprogram): insert contract in subprogram node at point of
8223 derivation.
8224 * sem_prag.adb, sem_prag.ads
8225 (Check_Arg_Is_String_Literal, Check_Identifier):
8226 new checking procedures to be called in treatment of pragmas
8227 (Check_Test_Case): new procedure to check that a Test_Case aspect or
8228 pragma is well-formed. This does not check currently that 'Result is
8229 used only in the Ensures component of a Test_Case.
8230 (Analyze_Pragma): add case for Test_Case
8231 (Analyze_TC_In_Decl_Part): pre-analyze the Requires and Ensures
8232 components of a Test_Case.
8233 (Preanalyze_TC_Args): new procedure to preanalyze the boolean
8234 expressions in the 3rd (and 4th if present) arguments of a Test_Case
8235 pragma, treated as spec expressions.
8236 (Sig_Flags): add value -1 for Test_Case.
8237 * sem_util.adb, sem_util.ads (Get_Ensures_From_Test_Case_Pragma,
8238 Get_Requires_From_Test_Case_Pragma): getters for both expression
8239 components of a Test_Case.
8240 * sinfo.adb, sinfo.ads (N_Contract): new kind of node used as
8241 indirection between an entry or [generic] subprogram entity and its
8242 pre/post + test-cases.
8243 (Spec_PPC_List, Spec_TC_List, Set_Spec_PPC_List, Set_Spec_TC_List):
8244 get/set for fields of an N_Contract node.
8245 * snames.ads-tmpl (Name_Test_Case, Name_Ensures, Name_Mode,
8246 Name_Normal, Name_Requires, Name_Robustness, Pragma_Test_Case): new
8247 names and pragma for Test_Case.
8248 * sprint.adb (Sprint_Node): raise Program_Error on N_Contract node
8249
6a2e5d0f
AC
82502011-08-04 Vincent Celier <celier@adacore.com>
8251
8252 * gnat_ugn.texi: Improve documentation of gnatmake switch
8253 --source-info-file=.
8254
82552011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8256
8257 * exp_ch7.adb (Make_Final_Call): Add local variable Atyp (assertion
8258 type). Initialize Atyp to the appropriate type which is later checked
8259 for completion. Rewrite the assertion associated with private type
8260 completion.
8261
82622011-08-04 Ed Falis <falis@adacore.com>
8263
8264 * adaint.c: Add call to vxCpuConfiguredGet for VxWorks SMP to
8265 initialize the number of CPUs.
8266
82672011-08-04 Ed Schonberg <schonberg@adacore.com>
8268
8269 * sem_type.adb (Disambiguate): New subsidiary routine
8270 In_Same_Declaration_List, to implement AI05-0020: a user-defined
8271 equality on an anonymous access type whose designated type is private
8272 does not lead to an ambiguity with the universal access equality
8273 operator in the body or child units of the defining package. The same
8274 is true for a multiplication operator on a private type completed with
8275 a fixed-point-type.
8276
82772011-08-04 Javier Miranda <miranda@adacore.com>
8278
8279 * opt.ads (Init_Or_Norm_Scalars_Config): Removed.
8280 (Normalize_Scalars_Config): Removed.
8281 * opt.adb
8282 (Register_Opt_Config_Switches): Remove registering config values of
8283 Init_Or_Norm_Scalars_Config and Normalize_Scalars_Config.
8284 (Restore_Opt_Config_Switches): Remove code which restores the values of
8285 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
8286 Init_Or_Norm_Scalars.
8287 (Save_Opt_Config_Switches): Remove code which saves values of
8288 Init_Or_Norm_Scalars and Normalize_Scalars.
8289 (Set_Opt_Config_Switches): Remove code which restores config values of
8290 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
8291 Init_Or_Norm_Scalars.
8292
82932011-08-04 Yannick Moy <moy@adacore.com>
8294
8295 * frontend.adb (Frontend): remove previous patch to avoid full
8296 qualification in ALFA mode.
8297 * lib-xref-alfa.adb (Add_ALFA_Xrefs): use unique name for variables.
8298 * sem_util.adb, sem_util.ads (Unique_Name): new function to define a
8299 unique name for an entity, which could be used to identify the entity
8300 across compilation units.
8301
83022011-08-04 Thomas Quinot <quinot@adacore.com>
8303
8304 * prj-env.adb
8305 (Initialize_Default_Project_Path): Add target specific directory
8306 ($prefix/$target/lib/gnat) in front of project path in all cases
8307 (making gnatmake's behaviour consistent with gprbuild).
8308 * gnatcmd.adb, make.adb, prj-makr.adb, clean.adb:
8309 Pass target name from Sdefault to project subsystem.
8310 * gnatls.adb: Show new target specific default project directory.
8311
83122011-08-04 Johannes Kanig <kanig@adacore.com>
8313
8314 * cstand.adb: Add Information to Identifier in Standard
8315 (Identifer_For): Set Entity to the corresponding entity
8316
483361a6
AC
83172011-08-04 Sergey Rybin <rybin@adacore.com>
8318
8319 * gnat_ugn.texi: Update doc on gnatcheck.
8320
83212011-08-04 Yannick Moy <moy@adacore.com>
8322
8323 * lib-xref-alfa.adb (Add_ALFA_Xrefs): correct definition of ranges of
8324 xrefs in a scope.
8325
83262011-08-04 Yannick Moy <moy@adacore.com>
8327
8328 * exp_prag.adb (Expand_Pragma_Check): in ALFA mode, return without
8329 performing expansion.
8330 * sem_ch6.adb (Analyze_Subprogram_Body_Helper,
8331 Analyze_Generic_Subprogram_Body): protect call to Process_PCCs so that
8332 it is not called in ALFA mode.
8333
ef5569c6
AC
83342011-08-04 Emmanuel Briot <briot@adacore.com>
8335
8336 * make.adb, osint.adb, osint.ads (Reset_Command_Line_Files): not used
8337 after all, so removed.
8338
83392011-08-04 Sergey Rybin <rybin@adacore.com>
8340
8341 * vms_data.ads: Add missing VMS qualifiers.
8342
1ab4a286
EB
83432011-08-04 Emmanuel Briot <briot@adacore.com>
8344
8345 * make.adb, makeutl.adb, osint.adb, osint.ads (Check_Mains): rebuild
8346 the list of files on the command line after processing it through
8347 Complete_Mains.
8348
7ae0d98c
AC
83492011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8350
8351 * exp_ch7.adb (Build_Raise_Statement): Remove the specialized
8352 processing for .NET/JVM. These targets can now benefit from
8353 Raise_From_Controlled_Operation and they share the same processing with
8354 standard targets.
8355 (Establish_Transient_Scope): Remove the restriction for .NET/JVM.
8356 These targets need transient scopes in order to properly finalize short
8357 lived controlled objects.
8358 (Make_Handler_For_Ctrl_Operation): Remove the specialized processing for
8359 NET/JVM. These targets can now benefit from
8360 Raise_From_Controlled_Operation and they share the same processing with
8361 standard targets.
8362
83632011-08-04 Geert Bosch <bosch@adacore.com>
8364
8365 * tracebak.c (STOP_FRAME): Stop at any next pointer outside the stack
8366
83672011-08-04 Ed Schonberg <schonberg@adacore.com>
8368
8369 * exp_aggr.adb (Has_Visible_Private_Ancestor): subsidiary routine to
8370 Expand_Record_Aggregate, to determine whether aggregate must be
8371 expanded into assignments. This is the case if the ancestor part is
8372 private, regarless of the setting of the flag Has_Private_Ancestor.
8373
83742011-08-04 Ed Falis <falis@adacore.com>
8375
8376 * vxaddr2line.adb: Add support for e500v2 and for Linux hosts
8377
83782011-08-04 Bob Duff <duff@adacore.com>
8379
8380 * sinfo.ads: Fix comment.
8381
83822011-08-04 Steve Baird <baird@adacore.com>
8383
8384 * bindgen.adb (Get_Ada_Main_Name): If CodePeer_Mode is set, then
8385 choose a package name in much the same way as is
8386 done for JGNAT when VM_Target /= No_VM, except that
8387 a slightly more distinctive prefix string is used.
8388
83892011-08-04 Emmanuel Briot <briot@adacore.com>
8390
8391 * makeutl.adb (Complete_Mains): no longer accept unit names on the
8392 gnatmake command line.
8393 This behavior was never documented (and was supported only because of
8394 an early bug in the code). This case might lead to ambiguous cases
8395 (between unit names and truncated base names without suffixes).
8396
87729e5a
AC
83972011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8398
8399 * a-tags.ads, a-tags.adb (Unregister_Tag): New routine.
8400 Remove the external tag of a tagged type from the internal hash table.
8401 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on the
8402 expanded usage of the routine. Strenghten the check for Is_Master. Add
8403 processing for tagged types.
8404 (Build_Finalizer): Create all the necessary lists used in finalizer
8405 creation when the processed context is a package that may contain
8406 tagged types.
8407 (Expand_Cleanup_Actions): Rename the call to Has_Controlled_Objects to
8408 Requires_Cleanup_Actions.
8409 (Expand_N_Package_Body): Package bodies may need clean up code
8410 depending on whether they contain tagged types.
8411 (Expand_N_Package_Declaration): Package declarations may need clean up
8412 code depending on whether they contain tagged types.
8413 (Unregister_Tagged_Types): New routine. Search through a list of
8414 declarations or statements, looking for non-abstract Ada tagged types.
8415 For each such type, generate code to unregister the external tag.
8416 * exp_util.adb (Has_Controlled_Objects (Node_Id)): Renamed to
8417 Requires_Cleanup_Actions.
8418 (Requires_Cleanup_Actions (List_Id, Boolean)): New routine. Search
8419 through a list of declarations or statements looking for non-abstract
8420 Ada tagged types or controlled objects.
8421 * exp_util.ads (Has_Controlled_Objects (Node_Id)): Renamed to
8422 Requires_Cleanup_Actions.
8423 (Has_Controlled_Objects (List_Id, Boolean)): Removed.
8424 * rtsfind.ads: Add entry RE_Unregister_Tag to tables RE_Id and
8425 RE_Unit_Table.
8426
84272011-08-04 Vincent Celier <celier@adacore.com>
8428
8429 * prj-env.adb (For_All_Source_Dirs.For_Project): Check if project Prj
8430 has Ada sources, not project Project, because if the root project
8431 Project has no sources of its own, all projects will be deemed without
8432 sources.
8433
84342011-08-04 Gary Dismukes <dismukes@adacore.com>
8435
8436 * bindgen.adb (Gen_Adainit_Ada): Move the generation of the declaration
8437 of the No_Param_Proc acc-to-subp type used for initialization of
8438 __gnat_finalize_library_objects so that it's declared at library level
8439 rather than nested inside of the adainit routine.
8440
84412011-08-04 Javier Miranda <miranda@adacore.com>
8442
8443 * exp_disp.adb (Make_DT): Generate code to check the external tag ONLY
8444 if the tagged type has a representation clause which specifies its
8445 external tag.
8446
84472011-08-04 Ed Schonberg <schonberg@adacore.com>
8448
8449 * einfo.ads, einfo.adb (Has_Private_Ancestor): now a flag on types.
8450 Remove previous procedure with that name.
8451 * sem_ch3.adb (Build_Derived_Record_Type): set Has_Private_Ancestor
8452 when appropriate.
8453 * sem_aggr.adb (Resolve_Extension_Aggregate): if the ancestor part is a
8454 subtype mark, the ancestor cannot have unknown discriminants.
8455 (Resolve_Record_Aggregate): if the type has invisible components
8456 because of a private ancestor, the aggregate is illegal.
8457
84582011-08-04 Vincent Celier <celier@adacore.com>
8459
8460 * switch-m.adb (Normalize_Compiler_Switches): Recognize and take into
8461 account switches -gnat2005, -gnat12 and -gnat2012.
8462
84632011-08-04 Bob Duff <duff@adacore.com>
8464
8465 * s-tasdeb.ads: Minor comment fix.
8466
84672011-08-04 Arnaud Charlet <charlet@adacore.com>
8468
8469 * gnatlink.adb (Gnatlink): Pass -gnat83/95/05/12 switch to gcc in
8470 CodePeer mode.
8471 * switch.ads, switch.adb (Is_Language_Switch): New function.
8472
84732011-08-04 Vincent Celier <celier@adacore.com>
8474
8475 * switch-c.adb: Minor comment addition.
8476
84772011-08-04 Vincent Celier <celier@adacore.com>
8478
8479 * vms_conv.adb (Process_Argument): Fail graciously when qualifier
8480 ending with '=' is followed by a space (missing file name).
8481
84822011-08-04 Pascal Obry <obry@adacore.com>
8483
8484 * g-regist.ads: Fix size of HKEY on x86_64-windows.
8485
84862011-08-04 Ed Schonberg <schonberg@adacore.com>
8487
8488 * sem_ch12.adb (Analyze_Associations): New routine
8489 Check_Overloaded_Formal_Subprogram to reject a formal package when
8490 there is a named association or a box initialisation for an overloaded
8491 formal subprogram of the corresponding generic.
8492
84932011-08-04 Yannick Moy <moy@adacore.com>
8494
8495 * alfa.ads (ALFA_Xref_Record): add component for type of entity
8496 * get_alfa.adb, put_alfa.adb: Read and write new component of
8497 cross-reference.
8498 * lib-xref-alfa.adb (Collect_ALFA): generate new component.
8499
88f47280
AC
85002011-08-04 Pascal Obry <obry@adacore.com>
8501
8502 * urealp.adb: Minor reformatting.
8503
85042011-08-04 Tristan Gingold <gingold@adacore.com>
8505
8506 * exp_ch7.adb (build_finalizer.process_declarations.processing_actions):
8507 Handle the case when Cleanup_Protected_Object returns Empty.
8508
85092011-08-04 Yannick Moy <moy@adacore.com>
8510
8511 * frontend.adb (Frontend): only qualify names in non-ALFA mode
8512
85132011-08-04 Ed Schonberg <schonberg@adacore.com>
8514
8515 * sem_ch4.adb (Try_Class_Wide_Operation): if the context is a procedure
8516 call, ignore functions.
8517
05c53a69
GB
85182011-08-04 Geert Bosch <bosch@adacore.com>
8519
8520 * urealp.adb (Equivalent_Decimal_Exponent): Avoid the use of floating
8521 point.
8522
23cc1ace
EB
85232011-08-04 Emmanuel Briot <briot@adacore.com>
8524
8525 * makeutl.adb (Compute_Builder_Switches): no longer accept a unit name
8526 as an index for Builder'Switches. This conforms to the documentation.
8527 * make.adb (Insert_Project_Sources): avoid duplicate code
8528
cef14201
AC
85292011-08-04 Emmanuel Briot <briot@adacore.com>
8530
8531 * makeutl.adb (Complete_Mains): if the user has passed a relative file
8532 name on the command line (for instance "../dummy"), never assume it can
8533 be a unit name.
8534
85352011-08-04 Tristan Gingold <gingold@adacore.com>
8536
8537 * bindgen.adb: Remove code the reference or create the
8538 Break_Start/__gnat_break_start procedure.
8539 * s-stalib.adb (Break_Start): Removed.
8540
e2fee30d
EB
85412011-08-04 Emmanuel Briot <briot@adacore.com>
8542
8543 * make.adb, makeutl.adb, makeutl.ads (Compute_Builder_Switches): now
8544 shared with gprbuild.
8545
2d395256
AC
85462011-08-04 Yannick Moy <moy@adacore.com>
8547
8548 * par-ch4.adb (P_Primary): preferentially issue an error message about
8549 a missing parenthesis arount a conditional or case expression in Ada
8550 2012 mode, if we detect that the alignment is not correct for a
8551 statement.
8552
85532011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8554
8555 * exp_ch7.adb (Process_Declarations): Do not consider the result of a
8556 tag-to-class-wide conversion as needing finalization actions.
8557 * exp_util.adb (Has_Controlled_Objects): Do not consider the result of
8558 a tag-to-class-wide conversion as needing finalization actions.
8559 (Is_Finalizable_Transient): The result of a tag-to-class-wide
8560 conversion does not need finalization actions.
8561 (Is_Tag_To_CW_Conversion): New routine.
8562 * exp_util.ads (Is_Tag_To_CW_Conversion): New routine. Determines
8563 whether an object is the result of a tag-to-class-wide conversion.
8564
85652011-08-04 Yannick Moy <moy@adacore.com>
8566
8567 * sem_ch13.adb (Analyze_Aspect_Specifications): correct order in which
8568 the left-hand-side and right-hand-side of a conjunct are inserted when
8569 translating a pre- or postcondition
8570 * sem_ch6.adb: Correct typo in comment
8571
85722011-08-04 Ed Schonberg <schonberg@adacore.com>
8573
8574 * gnat_rm.texi: Ravenscar does not prohibit dependence on
8575 Unchecked_Conversion and Unchecked_Deallocation.
8576
85772011-08-04 Thomas Quinot <quinot@adacore.com>
8578
8579 * make.adb: Minor reformatting.
8580
767ab2fd
EB
85812011-08-04 Emmanuel Briot <briot@adacore.com>
8582
8583 * prj.adb, prj.ads, makeutl.adb (Complete_Mains): search for the
8584 sources in the project and its imported projects, but not in the whole
8585 tree.
8586
8fb3f5df
AC
85872011-08-04 Emmanuel Briot <briot@adacore.com>
8588
8589 * make.adb: Remove debug trace.
8590
85912011-08-04 Vincent Celier <celier@adacore.com>
8592
8593 * makeutl.adb (Do_Complete): Get the absolute path name of a relative
8594 path in canonical form, to be able to compare path names on platforms
8595 such as Windows or Darwin.
8596
85972011-08-04 Thomas Quinot <quinot@adacore.com>
8598
8599 * par_sco.adb (Traverse_Declarations_Or_Statements.Set_Statement_Entry):
8600 For a pragma (statement with C1 = 'P'), record the sloc of the pragma.
8601 * scos.ads: Update documentation accordingly.
8602 * put_scos.adb (Output_SCO_Line): Omit statement SCOs for disabled
8603 pragmas.
8604
9515740f
AC
86052011-08-04 Ed Schonberg <schonberg@adacore.com>
8606
8607 * sem_attr.adb (Bad_Attribute_For_Predicate): flag illegal use of
8608 attribute only if prefix type is scalar.
8609
86102011-08-04 Emmanuel Briot <briot@adacore.com>
8611
8612 * make.adb, makeutl.adb, prj-env.adb (Check_Mains): put back support
8613 in gnatmake for specifying mains on the command line that do not belong
8614 to the main project. These mains must currently all belong to the same
8615 project, though.
8616 (Ultimate_Extension_Of): removed, since duplicated
8617 Ultimate_Extending_Project.
8618
92966893
AC
86192011-08-04 Arnaud Charlet <charlet@adacore.com>
8620
8621 * make.adb (Do_Codepeer_Globalize_Step): Removed. Use CodePeer_Mode
8622 instead.
8623 (CodePeer_Mode_String): New.
8624 (Linking_Phase, Binding_Phase): Call gnatlink with -P switch in
8625 CodePeer mode.
8626 (Scan_Make_Arg): Do not disable binding/linking phase in CodePeer mode.
8627 * bindgen.adb (Gen_Elab_Calls_Ada): Ignore subprograms in CodePeer
8628 mode, since no useful elaboration subprogram is needed by CodePeer.
8629 * gnatlink.adb (Gnatlink): Add support for -P switch (CodePeer mode).
8630 In this mode, compile binder file with -gnatC and do stop after this
8631 step.
8632
86332011-08-04 Vincent Celier <celier@adacore.com>
8634
8635 * exp_ch7.adb: Minor comment fix.
8636
5969611f
RD
86372011-08-04 Robert Dewar <dewar@adacore.com>
8638
8639 * exp_ch7.adb, make.adb, sem_ch10.adb, bindgen.adb, sem_res.adb,
8640 exp_ch4.adb, makeutl.adb: Minor reformatting.
8641
6367dd30
AC
86422011-08-04 Emmanuel Briot <briot@adacore.com>
8643
8644 * make.adb, makeutl.adb, makeutl.ads (Make): major refactoring.
8645 Create several new subprograms to move code out of Make. This makes the
8646 code more readable, removes code duplication, and is a preparation work
8647 for adding support for aggregate projects.
8648
86492011-08-04 Tristan Gingold <gingold@adacore.com>
8650
8651 * s-po32gl.ads, s-po32gl.adb: New files.
8652 * exp_ch7.ads (Get_Global_Pool_For_Access_Type): New function.
8653 * exp_ch7.adb (Get_Global_Pool_For_Access_Type): New function.
8654 (Build_Finalization_Collection): Use it.
8655 * exp_ch4.adb (Complete_Controlled_Allocation): Ditto.
8656 * rtsfind.ads: System_Pool_32_Global, Re_Global_Pool_32_Object: New
8657 literals.
8658 * gcc-interface/Makefile.in: Use s-po32gl.o on VMS.
8659 * gcc-interface/Make-lang.in: Update dependencies.
8660
cd8bfe35
EB
86612011-08-04 Emmanuel Briot <briot@adacore.com>
8662
8663 * makeutl.adb (Complete_Mains): add support for specs with no suffix on
8664 the command line.
8665
7db29ea7
EB
86662011-08-04 Emmanuel Briot <briot@adacore.com>
8667
8668 * make.adb, makeutl.adb (Complete_Mains): if a main specified on the
8669 command line is not a file name, also check whether it could be a unit
8670 name.
8671
d9b056ea
AC
86722011-08-04 Eric Botcazou <ebotcazou@adacore.com>
8673
8674 * bindgen.adb (Gen_Finalize_Library_Ada): Factor out code to generate
8675 the header of the finalization routine.
8676 If the unit has no finalizer but is a body whose spec has one, then
8677 generate the decrement of the elaboration entity only.
8678 If the unit has a finalizer and is a spec, then do not generate the
8679 decrement of the elaboration entity.
8680 (Gen_Finalize_Library_C): Likewise.
8681
86822011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8683
8684 * exp_ch7.adb (Alignment_Of): New subsidiary routine.
8685 (Bounds_Size_Expression): Removed.
8686 (Double_Alignment_Of): New subsidiary routine.
8687 (Make_Finalize_Address_Stmts): New local variable Index_Typ. Account
8688 for a hole in the dope vector of unconstrained arrays due to different
8689 index and element alignments.
8690
86912011-08-04 Ed Schonberg <schonberg@adacore.com>
8692
8693 * sem_res.adb (Resolve_Allocator): diagnose task allocator that will
8694 raise program_error because body has not been seen yet.
8695
86962011-08-04 Ed Schonberg <schonberg@adacore.com>
8697
8698 * sem_ch10.adb (Analyze_With_Clause): Protect against child unit with
8699 an unresolved name.
8700
87012011-08-04 Vincent Celier <celier@adacore.com>
8702
8703 * makeutl.adb (Do_Complete): Check absolute paths in canonical forms
8704
87052011-08-04 Yannick Moy <moy@adacore.com>
8706
8707 * alfa.adb, alfa.ads (Unique_Defining_Entity): move function from here
8708 * sem_util.adb, sem_util.ads (Unique_Defining_Entity): ...to here
8709
87102011-08-04 Thomas Quinot <quinot@adacore.com>
8711
8712 * sem_ch12.adb (Analyze_Package_Instantiation): Do not omit body for
8713 instantiation in RCI.
8714
87152011-08-04 Emmanuel Briot <briot@adacore.com>
8716
8717 * make.adb: Share more code with gprbuild
8718
f5fc5b9d
AC
87192011-08-04 Emmanuel Briot <briot@adacore.com>
8720
8721 * projects.texi: Added documentation for the IDE'Gnat project file
8722 attribute.
8723
87242011-08-04 Nicolas Roche <roche@adacore.com>
8725
8726 * gnat_rm.texi: Minor editing.
8727
87282011-08-04 Javier Miranda <miranda@adacore.com>
8729
8730 * bindgen.adb (Gen_Adafinal_Ada): Do not differentiate the main case
8731 and the library case for VM targets.
8732 (Gen_Adainit_Ada): Likewise.
8733
87342011-08-04 Robert Dewar <dewar@adacore.com>
8735
8736 * g-altive.ads: Minor comment updates.
8737 * prj-nmsc.adb: Minor reformatting.
8738
87392011-08-04 Javier Miranda <miranda@adacore.com>
8740
8741 * opt.ads
8742 (Normalize_Scalars_Config): Value of the configuration switch set by
8743 pragma Normalize_Scalars when it appears in the gnat.adc file.
8744 (Normalize_Scalars): New field for record Config_Switches_Type. Used
8745 to save and restore settings of this pragma.
8746 * opt.adb
8747 (Register_Opt_Config_Switches, Save_Opt_Config_Switches,
8748 Restore_Opt_Config_Switches): Add missing support for Normalize_Scalars.
8749
87502011-08-04 Vincent Celier <celier@adacore.com>
8751
8752 * gnat_ugn.texi: Document gnatlink options -M and -M=mapfile
8753
0c4683cf
AC
87542011-08-04 Arnaud Charlet <charlet@adacore.com>
8755
8756 * makeutl.adb: Minor reformatting.
8757
87582011-08-04 Olivier Hainque <hainque@adacore.com>
8759
8760 * g-altive.ads: Update comments to reflect that only the soft
8761 binding is available today.
8762
2598ee6d
RD
87632011-08-04 Robert Dewar <dewar@adacore.com>
8764
8765 * bindgen.adb, einfo.adb, sem_ch12.adb, s-tasren.adb, sem_res.adb,
8766 makeutl.adb, prj-nmsc.adb, opt.ads, prj-env.adb: Minor reformatting
8767 * gcc-interface/Make-lang.in: Update dependencies.
8768
c2db4b32
AC
87692011-08-04 Arnaud Charlet <charlet@adacore.com>
8770
8771 * prj-env.adb: Remove local debug traces.
8772
87732011-08-04 Yannick Moy <moy@adacore.com>
8774
8775 * checks.adb (Apply_Float_Conversion_Check): correct a typo where Lo_OK
8776 was used instead of Hi_OK, which could cause a read of an uninitialized
8777 value later on. Detected while working on the new warning.
8778 * exp_ch9.adb (Expand_N_Entry_Declaration): remove useless assignment
8779 to local variable.
8780 * sem_ch5.adb (Analyze_Assignment): set the last assignment component
8781 in more cases, in order to detect more unreferenced values.
8782 * sem_util.adb, sem_util.ads (Get_Enclosing_Object): return enclosing
8783 object for expression, if any.
8784
87852011-08-04 Eric Botcazou <ebotcazou@adacore.com>
8786
8787 * exp_intr.adb (Expand_Binary_Operator_Call): Look at the RM size of
8788 the operand types instead of the Esize.
8789
87902011-08-04 Steve Baird <baird@adacore.com>
8791
8792 * switch-b.adb (Scan_Binder_Switches): Add -P binder switch, used to
8793 enable CodePeer_Mode.
8794 * bindusg.adb (Display): Add help message describing -P binder switch.
8795 * gnat_ugn.texi: Document -P binder switch.
8796 * bindgen.adb (Gen_Main_Ada): If CodePeer_Mode is set, then call the
8797 user-defined main program directly.
8798 (Gen_Output_File_Ada): If CodePeer_Mode is set, generate a with of the
8799 user-defined main program in the context clause of the package body.
8800
ad05f2e9
AC
88012011-08-04 Yannick Moy <moy@adacore.com>
8802
8803 * alfa.adb, alfa.ads (Get_Entity_For_Decl): remove function, partial
8804 duplicate of Defining_Entity
8805 (Get_Unique_Entity_For_Decl): rename function into
8806 Unique_Defining_Entity
8807 * einfo.adb, einfo.ads (Is_In_ALFA, Body_Is_In_ALFA): remove flags
8808 (Formal_Proof_On): remove synthesized flag
8809 * cstand.adb, sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
8810 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_res.adb, sem_util.adb,
8811 sem_util.ads, stand.ads: Remove treatment associated to entities in ALFA
8812 * sem_prag.adb (Analyze_Pragma): remove special treatment for pragma
8813 Annotate (Formal_Proof)
8814
88152011-08-04 Emmanuel Briot <briot@adacore.com>
8816
8817 * prj-env.adb (Create_Config_Pragmas_File): fix handling of multi-unit
8818 source files with non-standard naming schemes, in imported projects
8819
756ef2a0
AC
88202011-08-04 Emmanuel Briot <briot@adacore.com>
8821
8822 * makeutl.adb (Complete_Mains): when a multi-unit source file is
8823 specified on the gprbuild command line, we need to compile all units
8824 within that file, not just the first one we find
8825 Fix error message for mains that are not found.
8826
88272011-08-04 Thomas Quinot <quinot@adacore.com>
8828
8829 * sem_ch6.adb: Update comment.
8830 * sem_ch12.adb: Minor reformatting.
8831
88322011-08-04 Bob Duff <duff@adacore.com>
8833
8834 * s-tasren.adb (Task_Do_Or_Queue): Previous code was reading
8835 Acceptor.Terminate_Alternative without locking Acceptor, which causes a
8836 race condition whose symptom is to fail to lock Parent. That, in turn,
8837 causes Parent.Awake_Count to be accessed without locking Parent, which
8838 causes another race condition whose symptom is that Parent.Awake_Count
8839 can be off by 1 (either too high or too low). The solution is to lock
8840 Parent unconditionally, and then lock Acceptor, before reading
8841 Acceptor.Terminate_Alternative.
8842
4fdebd93
AC
88432011-08-04 Arnaud Charlet <charlet@adacore.com>
8844
8845 * debug.adb: Update comment.
8846
88472011-08-04 Robert Dewar <dewar@adacore.com>
8848
8849 * par_sco.adb, exp_util.adb, make.adb, a-tags.adb, sem_prag.adb,
8850 sem_util.adb, sem_attr.adb, exp_ch4.adb, g-comlin.adb, g-comlin.ads,
8851 exp_ch6.adb: Minor reformatting.
8852
88532011-08-04 Gary Dismukes <dismukes@adacore.com>
8854
8855 * gnat_ugn.texi: Add sentence about the case of compile-time-detected
8856 checks for -gnateE.
8857
88582011-08-04 Ed Schonberg <schonberg@adacore.com>
8859
8860 * gnat_rm.texi: update Ravenscar desription to reflect Ada2012 RM.
8861
88622011-08-04 Thomas Quinot <quinot@adacore.com>
8863
8864 * sinfo.ads: Minor reformatting.
8865
88662011-08-04 Emmanuel Briot <briot@adacore.com>
8867
8868 * makeutl.adb, makeutl.ads, prj-nmsc.adb (Complete_Mains): report error
8869 even if there is no location.
8870
6aaa0587
ES
88712011-08-04 Ed Schonberg <schonberg@adacore.com>
8872
8873 * sem_res.adb, sem_ch4.adb: move check for restriction
8874 No_Task_Hierarchy to resolve_allocator.
8875
35a1c212
AC
88762011-08-04 Thomas Quinot <quinot@adacore.com>
8877
8878 * sinfo.adb, sinfo.ads, sem_prag.adb, sem_ch12.adb (Pragma_Enabled):
8879 This flag of N_Pragma nodes is not used, remove it as well as all of
8880 the associated circuitry.
8881
88822011-08-04 Javier Miranda <miranda@adacore.com>
8883
8884 * exp_disp.adb (Make_DT): Switch -gnatdQ disables the generation of the
8885 runtime check on duplicated externa tags
8886 * debug.adb Document switch -gnatdQ.
8887
88882011-08-04 Gary Dismukes <dismukes@adacore.com>
8889
8890 * a-fihema.ads: Minor typo fix.
8891
88922011-08-04 Yannick Moy <moy@adacore.com>
8893
8894 * sem_ch10.adb: Minor comment update.
8895
88962011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8897
8898 * einfo.adb: Update the node field usage to reflect the renaming of
8899 Return_Flag to Return_ Flag_Or_Transient_Decl.
8900 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl.
8901 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl.
8902 (Write_Field15_Name): Change Return_Flag to
8903 Return_Flag_Or_Transient_Decl.
8904 * einfo.ads: Rename node field Return_Flag to
8905 Return_Flag_Or_Transient_Decl. Update the associated comment and all
8906 occurrences in entities.
8907 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl. Update
8908 associated Inline pragma.
8909 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl. Update
8910 associated Inline pragma.
8911 * exp_ch4.ads, exp_ch4.adb (Expand_N_Expression_With_Actions): New
8912 routine.
8913 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Update the calls to
8914 Return_Flag and Set_Return_Flag.
8915 * exp_ch7.adb (Process_Declarations): Add code to recognize hook
8916 objects generated for controlled transients declared inside an
8917 Exception_With_Actions. Update the calls to Return_Flag.
8918 (Process_Object_Declaration): Add code to add a null guard for hook
8919 objects generated for controlled transients declared inside an
8920 Exception_With_Actions. Update related comment.
8921 * exp_util.adb (Has_Controlled_Objects): Add code to recognize hook
8922 objects generated for controlled transients declared inside an
8923 Exception_With_Actions. Update the calls to Return_Flag.
8924 * expander.adb (Expand): Add new case for N_Expression_With_Actions.
8925
89262011-08-04 Ed Schonberg <schonberg@adacore.com>
8927
8928 * sem_util.adb:(Wrong_Type): Improve error message on a one-element
8929 positional aggregate.
8930
89312011-08-04 Vincent Celier <celier@adacore.com>
8932
8933 * par_sco.adb (Process_Decisions.Output_Header): Check and record pragma
8934 SLOC only for pragmas.
8935
89362011-08-04 Emmanuel Briot <briot@adacore.com>
8937
8938 * projects.texi: Minor typo fix.
8939
89402011-08-04 Emmanuel Briot <briot@adacore.com>
8941
8942 * prj-nmsc.adb (Check_File): Minor change to traces, to help debugging
8943 on case-sensitive file systems.
8944
c2873f74
TQ
89452011-08-04 Thomas Quinot <quinot@adacore.com>
8946
8947 * put_scos.adb (Put_SCOs): Do not emit decision SCO for an X decision
8948 nested in a disabled pragma.
8949 * scos.ads, scos.adb, par_sco.ads, par_sco.adb: Record sloc of
8950 enclosing pragma, if any, for X decisions.
8951
89522011-08-04 Thomas Quinot <quinot@adacore.com>
8953
8954 * sem_prag.adb: Minor reformatting.
8955
46414266
VC
89562011-08-04 Vincent Celier <celier@adacore.com>
8957
8958 * a-tags.adb (Check_TSD): Avoid concatenation of strings, as it is not
8959 allowed in no run time mode.
8960
89612011-08-04 Vincent Celier <celier@adacore.com>
8962
8963 * make.adb (Check): When -gnatc is used, check for the source file
8964 inside the ALI file with a canonical case file name.
8965
afab164f
EB
89662011-08-04 Emmanuel Briot <briot@adacore.com>
8967
8968 * g-comlin.adb, g-comlin.ads (Add_Switch): Put back support for
8969 overriding the separator.
8970
fe0ec02f
AC
89712011-08-04 Robert Dewar <dewar@adacore.com>
8972
8973 * sem_aggr.adb, par_sco.adb, sem_type.adb, exp_util.adb, exp_ch9.adb,
8974 prj-nmsc.adb, sem_ch13.adb, exp_strm.adb: Minor reformatting.
8975
89762011-08-04 Robert Dewar <dewar@adacore.com>
8977
8978 * gnat_rm.texi: Minor documentation fix for pragma Annotate.
8979
89802011-08-04 Yannick Moy <moy@adacore.com>
8981
8982 * sem_attr.adb (Analyze_Attribute): add check during pre-analysis that
8983 'Result only appears in postcondition of function.
8984
89852011-08-04 Thomas Quinot <quinot@adacore.com>
8986
8987 * a-tags.adb (Check_TSD): When raising PROGRAM_ERROR for a duplicated
8988 external tag, include the value of the external tag in the exception
8989 message.
8990
0180fd26
AC
89912011-08-04 Yannick Moy <moy@adacore.com>
8992
8993 * sem_attr.adb (Result): modify error message for misplaced 'Result
8994
89952011-08-04 Sergey Rybin <rybin@adacore.com>
8996
8997 * gnat_rm.texi (pragma Annotate): Fix syntax description to make it
8998 clear that the second argument must be an identifier.
8999
90002011-08-04 Thomas Quinot <quinot@adacore.com>
9001
9002 * exp_ch9.adb (Build_Barrier_Function): When compiling with
9003 -fpreserve-control-flow, insert an IF statement on the barrier
9004 condition to ensure that a conditional branch instruction is generated.
9005
90062011-08-04 Emmanuel Briot <briot@adacore.com>
9007
9008 * prj-part.adb, prj.adb, prj.ads, prj-tree.ads
9009 (Processing_Flags.Ignore_Missing_With): new flag.
9010
90112011-08-04 Emmanuel Briot <briot@adacore.com>
9012
9013 * prj-nmsc.adb (Find_Sources, Path_Name_Of): Fix handling of
9014 Source_List_File on case-insensitive systems where the file is actually
9015 on a case-sensitive file system (NFS,...).
9016
90172011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
9018
9019 * sem_ch6.adb (Analyze_Function_Return): In a rare case where a
9020 function return contains a controlled [extension] aggregate and the
9021 return statement is not part of a handled sequence of statements, wrap
9022 the return in a block. This ensures that all controlled temporaries
9023 generated during aggregate resolution will be picked up by the
9024 finalization machinery.
9025
90262011-08-04 Ed Schonberg <schonberg@adacore.com>
9027
9028 * sem_aggr.adb (Resolve_Aggregate): If aggregate has box-initialized
9029 components, freeze type before resolution, to ensure that default
9030 initializations are present for all components.
9031 * sem_res.adb (Resolve_Actuals): the designated object of an
9032 accces-to-constant type is a legal actual in a call to an
9033 initialization procedure.
9034
90352011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
9036
9037 * exp_util.adb (Extract_Renamed_Object): Add N_Type_Conversion and
9038 N_Unchecked_Type_Conversion to the possible containers of a renamed
9039 transient variable.
9040
78efd712
AC
90412011-08-04 Yannick Moy <moy@adacore.com>
9042
9043 * par-ch13.adb (Aspect_Specifications_Present): recognize
9044 "with Identifier'Class =>" as an aspect, so that a meaningful warning
9045 is issued in Strict mode.
9046 * par.adb: Fix typos in comments.
9047
90482011-08-04 Yannick Moy <moy@adacore.com>
9049
9050 * sem_attr.adb (Result): modify error message to take into account Post
9051 aspect when compiling Ada 2012 (or newer) code.
9052
90532011-08-04 Nicolas Roche <roche@adacore.com>
9054
9055 * env.c (__gnat_clearenv): Avoid use of dynamic size array in order to
2c7f9cc0 9056 remove need for GCC exceptions.
78efd712
AC
9057
90582011-08-04 Vincent Celier <celier@adacore.com>
9059
9060 * makeutl.adb (Do_Complete): Call Debug_Output with the name of the
9061 project, not the source file name.
9062 * prj.adb (Find_Sources.Look_For_Sources): If the source has been
9063 excluded, continue looking. This excluded source will only be returned
9064 if there is no other source with the same base name that is not locally
9065 removed.
9066
90672011-08-04 Ed Schonberg <schonberg@adacore.com>
9068
9069 * sem_res.adb (Resolve_Intrinsic_Operator): if the result type is
9070 private and one of the operands is a real literal, use a qualified
9071 expression rather than a conversion which is not meaningful to the
9072 back-end.
9073
0170a691
AC
90742011-08-04 Yannick Moy <moy@adacore.com>
9075
9076 * sem_ch13.adb (Aspect_Loop): when an aspect X and its classwise
9077 corresponding aspect X'Class are allowed, proceed with analysis of the
9078 aspect instead of skipping it.
9079
90802011-08-04 Tristan Gingold <gingold@adacore.com>
9081
9082 * s-flocon.adb, s-flocon.ads: Add a body for s-flocon.ads
9083 This will allow to have an Ada implementation for the subprogram.
9084
deb4f5ba
ES
90852011-08-04 Ed Schonberg <schonberg@adacore.com>
9086
9087 * sem_ch3.adb (Analyze_Full_Type_Declaration): If the declaration is a
9088 completion and aspects are present, apply them to the entity for the
9089 type which is currently the partial view, but which is the one that
9090 will be frozen.
9091 * sem_ch13.adb (Analyze_Aspect_Specifications): if the predicate
9092 applies to a partial view, indicate that the full view has predicates
9093 and delayed aspects.
9094 (Replace_Type_Reference): Handle properly predicates that apply to the
9095 full view of a private completion.
9096
fc893455
AC
90972011-08-04 Eric Botcazou <ebotcazou@adacore.com>
9098
9099 * layout.adb (Layout_Type): For composite types, do not set Esize.
9100 * freeze.adb (Set_Small_Size): Remove test on alignment and do not
9101 set Esize.
9102 (Size_Known): Look at the RM size of components instead of the Esize.
9103 (Freeze_Record_Type): Look at the RM size instead of the Esize to
9104 issue warning and activate Implicit_Packing.
9105 (Freeze_Entity): Likewise. Do not issue a warning for alias/atomic
9106 if the Esize is not known.
9107 * sem_ch13.adb (Analyze_Attribute_Definition_Clause) <Size>: Set Esize
9108 for elementary types only.
9109 (Analyze_Record_Representation_Clause): Look at the RM size instead
9110 of the Esize to issue errors.
9111 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not set Esize if it
9112 is not known.
9113 <E_Record_Type>: Look at the RM size instead of the Esize. Remove
2c7f9cc0 9114 obsolete block.
fc893455
AC
9115 Look at the RM size instead of the Esize for types if the latter is
9116 not known.
9117 (gnat_to_gnu_field): Use Known_Esize instead of Known_Static_Esize.
9118
91192011-08-04 Ed Schonberg <schonberg@adacore.com>
9120
9121 * sem_type.adb: proper handling of equality not involving anonymous
9122 access types.
9123
b37d5bc6
AC
91242011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
9125
9126 * exp_ch7.adb (Create_Finalizer): Remove local variables Spec_Nod and
9127 Vis_Decls. When creating a library-level finalizer for a package spec,
9128 both the declaration and body of the finalizer are inserted either in
9129 the visible or private declarations of the package spec.
9130
91312011-08-04 Javier Miranda <miranda@adacore.com>
9132
9133 * sem_ch3.adb (Derive_Subprograms): Complete assertion to request the
9134 use of the full-view of a type when invoking Is_Ancestor.
9135 * sem_type.adb (Is_Ancestor): For consistency, when the traversal of
9136 the full-view of private parents is requested, then use also the
9137 full-view of the parent of the first derivation.
9138
7ab4d95a
AC
91392011-08-04 Tristan Gingold <gingold@adacore.com>
9140
9141 * s-taprop-vxworks.adb (Enter_Task): Use System.Float_Control.Reset
9142 instead of the locally imported procedure.
9143 * s-taprop-mingw.adb (Enter_Task): Ditto.
9144 * s-valrea.adb (Scan_Real): Ditto.
9145 * s-imgrea.adb (Set_Image_Real): Ditto.
9146 * s-flocon.ads: Make the package pure.
9147
91482011-08-04 Thomas Quinot <quinot@adacore.com>
9149
9150 * sinfo.ads, sinfo.adb (Debug_Statement, Set_Debug_Statement): Remove.
9151 * tbuild.ads, tbuild.adb (Make_Pragma): Adjust accordingly.
9152 * sinfo-cn.ads, sinfo-cn.adb (Change_Name_To_Procedure_Call_Statement):
9153 New subprogram, moved here from...
9154 * par.adb, par-ch5.adb (P_Statement_Name): ... here.
9155 * par-prag.adb (Par.Prag, case Pragma_Debug): Do not perform any
9156 rewriting of the last argument into a procedure call statement here...
9157 * sem_prag.adb (Analyze_Pragma, case Pragma_Debug): ...do it there
9158 instead.
9159
91602011-08-04 Thomas Quinot <quinot@adacore.com>
9161
9162 * par_sco.adb: Minor reformatting.
9163
51c400f5
AC
91642011-08-04 Robert Dewar <dewar@adacore.com>
9165
9166 * erroutc.adb: Minor reformatting.
9167
91682011-08-04 Thomas Quinot <quinot@adacore.com>
9169
9170 * par_sco.adb: Comment update.
9171
91722011-08-04 Tristan Gingold <gingold@adacore.com>
9173
9174 * s-flocon.ads: New file.
9175 * g-flocon.ads: Now a renaming of s-flocon.
9176 * Makefile.rtl: Add s-flocon.o
9177
6a49f110
AC
91782011-08-04 Javier Miranda <miranda@adacore.com>
9179
9180 * exp_strm.adb (Build_Array_Input_Function): if the array type is
9181 constrained, do not attempt to build a subtype of it.
9182
91832011-08-04 Yannick Moy <moy@adacore.com>
9184
9185 * errout.ads Change comments: remove 'R'M as an example where quotes
9186 are needed; add ALFA as another case where quotes are not needed
9187 * erroutc.adb (Set_Msg_Insertion_Reserved_Word): add ALFA as another
9188 case where quotes are not needed.
9189 * sem_ch11.adb, sem_ch13.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
9190 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_prag.adb, sem_res.adb:
9191 Remove all occurrences of 'A'L'F'A
9192
91932011-08-04 Ed Schonberg <schonberg@adacore.com>
9194
9195 * sem_ch13.adb: check legality of invariant pragma.
9196
a4640a39
AC
91972011-08-04 Eric Botcazou <ebotcazou@adacore.com>
9198
9199 * bindgen.adb: Add comments.
9200
92012011-08-04 Yannick Moy <moy@adacore.com>
9202
9203 * einfo.adb, einfo.ads: Free Flag254 and make Formal_Proof_On a
9204 synthesized flag.
9205 * sem_prag.adb (Analyze_Pragma): record the pragma Annotate
9206 (Formal_Proof, On/Off) in the Rep_Item list of the current subprogram.
9207
92082011-08-04 Robert Dewar <dewar@adacore.com>
9209
9210 * exp_ch7.adb, exp_ch6.adb, sem_ch3.adb, layout.adb, sem_ch5.adb,
9211 osint-c.ads, sem_util.ads, gnat1drv.adb, targparm.ads, sem_ch6.adb,
9212 sem_ch13.adb, s-pooloc.adb: Minor reformatting.
9213
39ade2f9
AC
92142011-08-04 Thomas Quinot <quinot@adacore.com>
9215
9216 * s-pooloc.ads, s-pooglo.ads: Minor reformatting
9217
92182011-08-04 Thomas Quinot <quinot@adacore.com>
9219
9220 PR ada/47880
9221 * s-pooloc.adb (Deallocate): Fix the case of deallocating the only
9222 allocated object.
9223
92242011-08-04 Robert Dewar <dewar@adacore.com>
9225
9226 * einfo.ads, exp_ch4.adb: Minor reformatting.
9227
92282011-08-04 Jerome Lambourg <lambourg@adacore.com>
9229
9230 * back_end.ads (Gen_Or_Update_Object_File): Add more comments.
9231
7efc3f2d
AC
92322011-08-04 Ed Schonberg <schonberg@adacore.com>
9233
9234 * exp_ch4.adb (Expand_Composite_Equality): code cleanup: use component
9235 type in all cases to compute list of primitive operations, because full
9236 view may be an itype that is not attached to the list of declarations.
9237
92382011-08-04 Eric Botcazou <ebotcazou@adacore.com>
9239
9240 * bindgen.adb (Gen_Adafinal_Ada): Generate an early return if the
9241 library has already been finalized.
9242 (Gen_Adafinal_C): Likewise.
9243 (Gen_Adainit_Ada): Generate an early return if the library has
9244 already been elaborated.
9245 (Gen_Adainit_C): Likewise.
9246 (Gen_Output_File_Ada): Generate an elaboration flag.
9247 (Gen_Output_File_C): Likewise.
9248
f65df609
HK
92492011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
9250
9251 * exp_ch4.adb (Expand_Allocator_Expression): Disable the generation of
9252 Set_Finalize_Address_Ptr for CodePeer because Finalize_Address was not
9253 built in the first place.
9254 (Expand_N_Allocator): Disable the generation of Set_Finalize_Address_Ptr
9255 for CodePeer because Finalize_Address was not built to begin with.
9256 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Ditto.
9257
a0fb8fe8
AC
92582011-08-04 Pascal Obry <obry@adacore.com>
9259
9260 * adaint.c (__gnat_tmp_name): Use current process id to create temp
9261 filenames, this ensures unicity of filenames across processes.
9262
92632011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
9264
9265 * bindgen.adb (Gen_Finalize_Library_Ada): Rename generated routine
9266 Raise_Controlled to Raise_From_Controlled_Operation. Update the
9267 signature of Raise_From_Controlled_Operation by adding flag From_Abort.
9268 Add False as the actual to From_Abort in the generated call to
9269 Raise_From_Controlled_Operation.
9270
92712011-08-04 Jerome Lambourg <lambourg@adacore.com>
9272
9273 * osint-c.ads, osint-c.adb (Set_Library_Info_Name): Move to declaration
9274 so that the ali file name can be retrieved from outside of this package.
9275 * back_end.ads, back_end.adb (Gen_Or_Update_Object_File): New method
9276 doing nothing in the general case, but used to update the object file
9277 timestamp if directly generated by the backend.
9278 * gnat1drv.adb (Gnat1drv): Make sure the object file's timestamp is set
9279 to a later time than the ali file one.
9280
9534ab17
AC
92812011-08-04 Yannick Moy <moy@adacore.com>
9282
9283 * einfo.adb, einfo.ads (Formal_Proof_On): new flag set on subprogram
9284 entities whose body contains an Annotate pragma which forces formal
9285 proof on this body.
9286 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
9287 sem_ch6.adb, sem_ch9.adb, sem_res.adb: Adapt call to
9288 Mark_Non_ALFA_Subprogram to pass in a message and node.
9289 * sem_prag.adb (Analyze_Pragma): add treatment of pragma Annotate
9290 (Forma_Proof, On) which sets the flag Formal_Proof_On in the
9291 surrounding subprogram.
9292 * sem_util.adb, sem_util.ads (Mark_Non_ALFA_Subprogram,
9293 Mark_Non_ALFA_Subprogram_Unconditional): if the subprogram being marked
9294 as not in ALFA is annotated with Formal_Proof being On, then an error
9295 is issued based on the additional parameters for message and node.
9296 * snames.ads-tmpl (Name_Formal_Proof): new name for annotation.
9297 * gcc-interface/Make-lang.in: Update dependencies.
9298
92992011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
9300
9301 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Do not generate
9302 Finalize_Address when CodePeer is enabled.
9303
93042011-08-04 Pascal Obry <obry@adacore.com>
9305
9306 * adaint.c (__gnat_tmp_name): Use _tempnam() instead of tempnam() as
9307 the latter returns a pointer to a static buffer which is deallocated
9308 at the end of the routine.
9309
5c0e97dd
AC
93102011-08-04 Yannick Moy <moy@adacore.com>
9311
9312 * sem_ch3.adb (Array_Type_Declaration): move test for type in ALFA
9313 after index creation; mark unconstrained base array type generated as
9314 being in/not in ALFA as well
9315 (Make_Index): mark subtype created as in/not in ALFA
9316 * sem_ch5.adb (Analyze_Iteration_Scheme): mark entity for iterating
9317 over a loop as in/not in ALFA, depending on its type and form of loop
9318 iteration.
9319
93202011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
9321
9322 * exp_ch7.adb (Build_Object_Declarations): Initialize flag Abort
9323 directly to False on .NET and JVM.
9324
7a93c64b
YM
93252011-08-04 Yannick Moy <moy@adacore.com>
9326
9327 * sem_ch3.adb (Constrain_Enumeration, Constrain_Integer): remove
9328 constraint that subtype must come from source code to be in ALFA, so
9329 that anonymous subtypes can be in ALFA too.
9330
e9a1ed9b
YM
93312011-08-04 Yannick Moy <moy@adacore.com>
9332
9333 * sem_ch3.adb (Analyze_Object_Declaration): remove obsolete addition of
9334 reference for ALFA mode.
9335 * lib-xref-alfa.adb, lib-xref.ads (Traverse_Compilation_Unit): make
9336 procedure public so as to use it from formal verification back-end.
9337
8e293fbd
AC
93382011-08-04 Jerome Lambourg <lambourg@adacore.com>
9339
9340 * g-comlin.adb (For_Each_Simple_Switch.Is_In_Config): Remove the
9341 invalid checks of the Parameter, making Remove_Switch not working
9342 correctly.
9343
93442011-08-04 Arnaud Charlet <charlet@adacore.com>
9345
9346 * targparm.ads: Update header: no run-time exception is needed on this
9347 file.
9348
93492011-08-04 Vincent Celier <celier@adacore.com>
9350
9351 * a-fihema.adb: Use System.IO instead of GNAT.IO
9352
93532011-08-04 Thomas Quinot <quinot@adacore.com>
9354
9355 * sem_ch3.adb (Access_Definition): Anonymous access to subprogram types
9356 are forbidden in Compiler_Unit mode.
9357
cfae2bed
AC
93582011-08-04 Robert Dewar <dewar@adacore.com>
9359
9360 * sem_util.adb: Minor reformatting.
9361
93622011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
9363
9364 * bindgen.adb (Gen_Finalize_Library_Ada): Update the import string for
9365 library-level finalizers.
9366 (Gen_Finalize_Library_C): Update the import string for library-level
9367 finalizers.
9368 (Gen_Finalize_Library_Defs_C): Update the definition name of a
9369 library-level finalizer.
9370 * exp_ch7.adb: Remove with and use clauses for Stringt.
9371 (Create_Finalizer): Remove local variables Conv_Name, Prag_Decl,
9372 Spec_Decl. Add local variable Body_Id. The names of library-level
9373 finalizers are now manually fully qualified and are no longer external.
9374 A single name is now capable of servicing .NET, JVM and non-VM targets.
9375 Pragma Export is no longer required to provide visibility for the name.
9376 (Create_Finalizer_String): Removed.
9377 (New_Finalizer_Name): New routine which mimics New_..._Name.
9378
01f0729a
AC
93792011-08-04 Eric Botcazou <ebotcazou@adacore.com>
9380
9381 * sem_elab.adb (Check_Internal_Call_Continue): Change the type of the
9382 elaboration counter to Standard_Short_Integer.
9383 * sem_util.adb (Build_Elaboration_Entity): Likewise.
9384 * bindgen.adb (Gen_Elab_Externals_Ada): Adjust to above change.
9385 (Gen_Elab_Externals_C): Likewise.
9386
93872011-08-04 Ed Falis <falis@adacore.com>
9388
9389 * system-vxworks-arm.ads, system-vxworks-sparcv9.ads,
9390 system-vxworks-ppc.ads, system-vxworks-m68k.ads,
9391 system-vxworks-mips.ads, system-vxworks-x86.ads
9392 (Always_Compatible_Rep): set to False for all VxWorks targets.
9393
2c1b72d7
AC
93942011-08-04 Robert Dewar <dewar@adacore.com>
9395
9396 * par_sco.adb, prj-proc.adb, make.adb, bindgen.adb, prj.adb, prj.ads,
9397 makeutl.adb, makeutl.ads, prj-nmsc.adb, exp_ch5.adb, exp_ch12.adb,
9398 exp_ch7.ads, exp_util.ads, sem_util.ads, g-comlin.ads, exp_ch6.adb,
9399 exp_ch6.ads, lib-xref.ads, exp_ch7.adb, exp_util.adb, exp_dist.adb,
9400 exp_strm.adb, gnatcmd.adb, freeze.adb, g-comlin.adb, lib-xref-alfa.adb,
9401 sem_attr.adb, sem_prag.adb, sem_util.adb, sem_elab.adb, sem_ch8.adb,
9402 sem_ch11.adb, sem_eval.adb, sem_ch13.adb, sem_disp.adb, a-fihema.adb:
9403 Minor reformatting and code reorganization.
9404
94052011-08-04 Emmanuel Briot <briot@adacore.com>
9406
9407 * projects.texi: Added doc for aggregate projects.
9408
824e9320
AC
94092011-08-04 Emmanuel Briot <briot@adacore.com>
9410
9411 * prj-proc.adb, prj-nmsc.adb, prj-env.adb (Process_Declarative_Items):
9412 Add support for overriding the Project_Path in aggregate projects.
9413
94142011-08-04 Robert Dewar <dewar@adacore.com>
9415
9416 * a-cofove.ads: Minor reformatting.
9417
94182011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
9419
9420 * exp_ch7.adb (Build_Adjust_Or_Finalize_Statements): Update the comment
9421 on the generated code.
9422 (Build_Finalize_Statements): Update the comment on the generated code.
9423 (Build_Initialize_Statements): Update the comment on the generated code.
9424 (Build_Object_Declarations): Add local variable Result. The object
9425 declarations are now built in sequence.
9426 * rtsfind.ads: Add RE_Exception_Occurrence_Access to tables RE_Id and
9427 RE_Unit_Table.
9428
94292011-08-04 Robert Dewar <dewar@adacore.com>
9430
9431 * checks.adb, alfa.adb, alfa.ads: Minor reformatting.
9432
94332011-08-04 Eric Botcazou <ebotcazou@adacore.com>
9434
9435 * einfo.ads (Elaboration_Entity): Document new definition and use.
9436 (Elaboration_Entity_Required): Adjust to above change.
9437 * exp_attr.adb (Expand_N_Attribute_Reference): Likewise.
9438 * exp_ch12.adb: And with and use for Snames.
9439 (Expand_N_Generic_Instantiation): Test 'Elaborated attribute.
9440 * exp_util.adb (Set_Elaboration_Flag): Likewise.
9441 * sem_attr.adb (Analyze_Attribute) <Check_Library_Unit>: Delete.
9442 <Check_Unit_Name>: Deal with N_Expanded_Name.
9443 <Attribute_Elaborated>: Extend to all unit names.
9444 * sem_elab.adb: And with and use for Uintp.
9445 (Check_Internal_Call_Continue): Adjust to Elaboration_Entity change.
9446 * sem_util.ads (Build_Elaboration_Entity): Adjust comment.
9447 * sem_util.adb (Build_Elaboration_Entity): Change type to Integer.
9448 * bindgen.adb (Gen_Elab_Externals_Ada): New local subprogram taken
9449 from Gen_Adainit_Ada.
9450 (Gen_Elab_Externals_C): Likewise, but taken from Gen_Adainit_C.
9451 (Gen_Adafinal_Ada): Remove redundant test. In the non-main program
9452 case, do not call System.Standard_Library.Adafinal; instead call
9453 finalize_library if needed.
9454 (Gen_Adafinal_C): Likewise.
9455 (Gen_Adainit_Ada): Do not set SSL.Finalize_Library_Objects in the
9456 non-main program case.
9457 (Gen_Adainit_C): Generate a couple of external declarations here.
9458 In the main program case, set SSL.Finalize_Library_Objects.
9459 (Gen_Elab_Calls_Ada): Adjust to Elaboration_Entity change.
9460 (Gen_Elab_Calls_C): Likewise.
9461 (Gen_Finalize_Library_Ada): Likewise. Skip SAL interface units.
9462 (Gen_Finalize_Library_C): Likewise. Generate a full function.
9463 (Gen_Main_C): Put back call to Ada_Final and don't finalize library
9464 objects here.
9465 (Gen_Output_File_Ada): Generate pragma Linker_Destructor for Ada_Final
9466 if -a is specified. Call Gen_Elab_Externals_Ada. Move around call to
9467 Gen_Adafinal_Ada.
9468 (Gen_Output_File_C): Generate __attribute__((destructor)) for Ada_Final
9469 if -a is specified. Call Gen_Elab_Externals_C. Remove useless couple
2c7f9cc0 9470 of external declarations. Call Gen_Finalize_Library_C.
824e9320 9471
316d9d4f
EB
94722011-08-04 Emmanuel Briot <briot@adacore.com>
9473
9474 * prj.adb, prj.ads, makeutl.adb, makeutl.ads (Complete_Mains,
9475 Compute_Compilation_Phases): new subprogram.
9476 (Builder_Data, Builder_Project_Tree_Data): new subprogram and type
9477 The number of mains as well as the various compilation phases that
9478 need to be run are now project tree specific, since various
9479 aggregated trees might have different requirements. In particular,
9480 they do not all require bind or link phases.
9481
9434c32e
EB
94822011-08-04 Emmanuel Briot <briot@adacore.com>
9483
9484 * prj.adb, prj.ads, makeutl.adb, makeutl.ads, prj-env.adb
9485 (Project_Tree_Appdata): New type.
9486 It is now possible to associate application-specific data to a project
9487 tree. In particular, this is used in the gprbuild builder to avoid a
9488 number of global tables and htables, especially now that there can be
9489 several project trees loaded at once because of aggregate projects.
9490 (Debug_Name): new procedure.
9491 * projects.texi: Clarify syntax of "**" for Source_Dirs
9492
41ba34db
EB
94932011-08-03 Emmanuel Briot <briot@adacore.com>
9494
9495 * prj.ads, makeutl.adb, makeutl.ads (Queue.Insert): now also inserts
9496 the "roots" for a main.
9497 (Fill_From_Project): add support for aggregate projects. Main units
9498 in aggregated projects are now automatically added in the list of
9499 files to build (although this fails later on in gprbuild, because
9500 these files are not using the root proejct tree, so this needs
9501 further cleanup)
9502 * gcc-interface/Make-lang.in: Update dependencies.
9503
fccd42a9
AC
95042011-08-03 Yannick Moy <moy@adacore.com>
9505
9506 * sem_ch4.adb (Analyze_Conditional_Expression): only allow boolean
9507 conditional expression in ALFA.
9508 * sem_res.adb (Resolve_Conditional_Expression): mark non-boolean
9509 expressions as not in ALFA.
9510
95112011-08-03 Robert Dewar <dewar@adacore.com>
9512
9513 * a-cofove.adb: Minor reformatting.
9514
95152011-08-03 Emmanuel Briot <briot@adacore.com>
9516
9517 * make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads
9518 (Insert_Project_Sources, Insert_withed_Sources_For): moved from the
9519 gprbuild sources.
9520 These packages are more logically placed in the Queue package, since
9521 they manipulate the queue. It is also likely that they can be adapted
9522 for gnatmake, thus sharing more code.
9523 (Finish_Program, Fail_Program): moved from the gprbuild sources, so
9524 that we could move the above.
9525
95262011-08-03 Emmanuel Briot <briot@adacore.com>
9527
9528 * errutil.adb (Finalize): clean up the list of error messages on exit.
9529 Calling this subprogram multiple times will no longer show duplicate
9530 error messages on stderr.
9531
95322011-08-03 Emmanuel Briot <briot@adacore.com>
9533
9534 * g-comlin.adb, g-comlin.ads (Set_Command_Line): ignore the parameter
9535 Getopt_Switches when we have already define a command line
9536 configuration.
9537
5e8c8e44
YM
95382011-08-03 Yannick Moy <moy@adacore.com>
9539
9540 * sem_ch11.adb (Analyze_Raise_xxx_Error): do not mark such nodes as not
9541 in ALFA. Instead, they are considered as assertions to prove.
9542 * sem_ch4.adb (Analyze_Conditional_Expression): do not always mark such
9543 nodes as not in ALFA. Instead, include conditional expressions in ALFA
9544 if they have no ELSE part, or if they occur in pre- and postconditions,
9545 where the Condition cannot have side-effects in ALFA
9546 (Analyze_Membership_Op): do not mark such nodes as not in ALFA
9547 (Analyze_Type_Conversion): do not always mark such nodes as not in ALFA.
9548 Instead, include type conversion between scalar types in ALFA.
9549 * sem_ch6.adb (Process_Formals): correctly mark a parameter in ALFA
9550 if-and-only-if its type is in ALFA.
9551
5ffe0bab
AC
95522011-08-03 Thomas Quinot <quinot@adacore.com>
9553
9554 * scos.adb, get_scos.adb, put_scos.adb
9555 New code letter for decisions: G (entry guard)
9556 * par_sco.adb
9557 (Traverse_Subprogram_Body): Rename to...
9558 (Traverse_Subprogram_Or_Task_Body): New subrpogram.
9559 (Traverse_Protected_Body): New subprogram
9560 (Traverse_Declarations_Or_Statements): Add traversal of task bodies,
9561 protected bodies and entry bodies.
9562
95632011-08-03 Yannick Moy <moy@adacore.com>
9564
9565 * einfo.adb, einfo.ads (Is_Postcondition_Proc): new flag for procedure
9566 entities with get/set subprograms, which is set on procedure entities
9567 generated by the compiler for a postcondition.
9568 * sem_ch6.adb (Process_PPCs): set new flag on postcondition procedures
9569 * alfa.adb, alfa.ads (Get_Entity_For_Decl): new function returning the
9570 entity for a declaration
9571 (Get_Unique_Entity_For_Decl): new function returning an entity which
9572 represents a declaration, so that matching spec and body have the same
9573 entity.
9574
95752011-08-03 Robert Dewar <dewar@adacore.com>
9576
9577 * a-except-2005.adb, a-cfhama.adb, a-cfhase.adb, a-cfhase.ads,
9578 a-cforma.adb, a-cforse.ads, a-cforse.adb: Minor reformatting
9579
95802011-08-03 Yannick Moy <moy@adacore.com>
9581
9582 * lib-xref-alfa.adb (Detect_And_Add_ALFA_Scope): make the subprogram
9583 library-level because retriction No_Implicit_Dynamic_Code in the
9584 front-end prevents its definition as a local subprogram
9585 (Traverse_Compilation_Unit): extract new procedure from Add_ALFA_File,
9586 for reuse in other contexts
9587 (Traverse_Declarations_Or_Statements,
9588 Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
9589 Traverse_Package_Declaration, Traverse_Subprogram_Body): make all these
9590 procedures take a callback parameter to be called on all declarations
9591 * lib-xref.ads
9592 (Traverse_All_Compilation_Units): new generic function to traverse a
9593 compilation unit and call a callback parameter on all declarations
9594
f9ad6b62
AC
95952011-08-03 Javier Miranda <miranda@adacore.com>
9596
9597 * sem_prag.adb (Process_Interface_Name): Allow duplicated export names
9598 in Java since they are always enclosed in a namespace that
9599 differentiates them, and overloaded entities are supported by the VM.
9600
96012011-08-03 Ed Schonberg <schonberg@adacore.com>
9602
9603 * checks.adb (Determine_Range): If a computed bound of an operation is
9604 outside the range of the base type of the expression, and overflow
9605 checks are enabled, the result is unknown and cannot be used for any
9606 subsequent constant folding.
9607 * sem_eval.adb (Compile_Time_Compare): if the bounds of one operand are
9608 unknown, so is the result of the comparison.
9609
96102011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
9611
9612 * a-except-2005.adb (Raise_From_Controlled_Operation): Add new formal
9613 From_Abort. When finalization was triggered by an abort, propagate
9614 Standard'Abort_Signal rather than Program_Error.
9615 * a-except-2005.ads (Raise_From_Controlled_Operation): Add new formal
9616 From_Abort.
9617 * a-except.adb (Raise_From_Controlled_Operation): Add new formal
9618 From_Abort. When finalization was triggered by an abort, propagate
9619 Standard'Abort_Signal rather than Program_Error.
9620 * a-except.ads:(Raise_From_Controlled_Operation): Add new formal
9621 From_Abort.
9622 * exp_ch7.adb:(Build_Adjust_Or_Finalize_Statements): New local variable
9623 Abort_Id. Update the calls to Build_Object_Declarations and
9624 Build_Raise_Statement to include Abort_Id.
9625 (Build_Adjust_Statements): New local variable Abort_Id. Update the
9626 calls to Build_Object_Declarations and Build_Raise_Statement to include
9627 Abort_Id.
9628 (Build_Finalize_Statements): New local variable Abort_Id. Update the
9629 calls to Build_Object_Declarations and Build_Raise_Statement to include
9630 Abort_Id.
9631 (Build_Components): Create an entity for Abort_Id when exceptions are
9632 allowed on the target.
9633 (Build_Finalizer): New local variable Abort_Id.
9634 (Build_Initialize_Statements): New local variable Abort_Id. Update the
9635 calls to Build_Object_Declarations and Build_Raise_Statement to include
9636 Abort_Id.
9637 (Build_Object_Declarations): Add new formal Abort_Id. Create the
9638 declaration of flag Abort_Id to preserve the original abort status
9639 before finalization code is executed.
9640 (Build_Raise_Statement): Add new formal Abort_Id. Pass Abort_Id to
9641 runtime routine Raise_From_Controlled_Operation.
9642 (Create_Finalizer): Update the call to Build_Raise_Statement to include
9643 Abort_Id. Update the call to Build_Object_Declarations to include
9644 Abort_Id. Update the layout of the finalizer body.
9645 (Make_Handler_For_Ctrl_Operation): Add an actual for From_Abort.
9646 (Process_Transient_Objects): New local variable Abort_Id. Remove the
9647 clunky code to create all flags and objects related to
9648 exception propagation and replace it with a call to
9649 Build_Object_Declarations. Update the call to Build_Raise_Statement to
9650 include Abort_Id.
9651 * exp_ch7.ads (Build_Object_Declarations): Moved from body to spec.
9652 Add new formal Abort_Id and associated comment on its use.
9653 (Build_Raise_Statement): Add new formal Abort_Id and associated comment
9654 on its use.
9655 * exp_intr.adb (Expand_Unc_Deallocation): New local variable Abort_Id.
9656 Remove the clunky code to create all flags and objects related to
9657 exception propagation and replace it with a call to
9658 Build_Object_Declarations. Update the call to Build_Raise_Statement.
9659
96602011-08-03 Eric Botcazou <ebotcazou@adacore.com>
9661
9662 * s-tassta.adb: Fix minor typos.
9663
96642011-08-03 Robert Dewar <dewar@adacore.com>
9665
9666 * rtsfind.ads, makeutl.ads, prj.ads, prj.adb, make.adb,
9667 lib-writ.adb, makeutl.adb, s-soflin.ads, clean.adb: Minor reformatting.
9668
1cdfa9be
AC
96692011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
9670
9671 * exp_ch7.adb (Create_Finalizer): Treat freeze nodes in similar fashion
9672 to packages. This ensures that the finalizer body will not end up
9673 inside the freeze node.
9674 (Process_Declarations): Add code to detect whether a freeze node has a
9675 nested finalization collection.
9676
96772011-08-03 Pascal Obry <obry@adacore.com>
9678
9679 * g-awk.adb, g-awk.ads: Make GNAT.AWK API compatible with Ada 2005.
9680 (Current_Session): Return a not null access to Session_Type.
9681 (Default_Session): Likewise.
9682
243cae0a
AC
96832011-08-03 Robert Dewar <dewar@adacore.com>
9684
9685 * a-cfdlli.adb, bindgen.adb, exp_ch4.adb, exp_ch13.adb, sem_warn.adb,
9686 exp_ch3.adb, exp_ch3.ads: Minor reformatting.
9687
96882011-08-03 Pascal Obry <obry@adacore.com>
9689
9690 * g-awk.ads: Minor comment fix.
9691
96922011-08-03 Sergey Rybin <rybin@adacore.com>
9693
9694 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
9695 the tree structure related to discriminant constraints.
9696 Original_Discriminant cannot be used any more for computing the
9697 defining name for the reference to a discriminant.
9698
96992011-08-03 Ed Schonberg <schonberg@adacore.com>
9700
9701 * sem_disp.adb (Is_Tag_Indeterminate): If the return type of the
9702 function is not visibly tagged, this is not a dispatching call and
9703 therfore is not Tag_Indeterminate, even if the function is marked as
9704 dispatching on result.
9705
f553e7bc
AC
97062011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
9707
9708 * exp_ch13.adb: Add with and use clauses for Restrict and Rident.
9709 (Expand_N_Free_Statement): Add a guard to protect against run-times
9710 which do not support controlled types.
9711 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Add a guard to protect
9712 against run-times which do not support controlled types.
9713 * exp_ch4.adb (Complete_Controlled_Allocation): Add a guard to protect
9714 against run-times which do not support controlled types.
9715 * exp_ch7.adb (Build_Finalization_Collection): Add a guard to protect
9716 against run-times which do not support controlled types.
9717 * exp_util.adb (Needs_Finalization): Code reformatting. Add a guard to
9718 protect against run-times which do not support controlled types.
9719
97202011-08-03 Eric Botcazou <ebotcazou@adacore.com>
9721
9722 * exp_intr.adb: Put back with and use clauses for Exp_Ch11.
9723 (Expand_Unc_Deallocation): Expand the AT_END handler at the very end.
9724
e4982b64
AC
97252011-08-03 Ed Schonberg <schonberg@adacore.com>
9726
9727 * exp_ch5.adb (Expand_Iterator_Loop): indicate that the cursor is
9728 modified in the source, to prevent spurious warnings when compiling
9729 with -gnatg.
9730
97312011-08-03 Thomas Quinot <quinot@adacore.com>
9732
9733 * a-except-2005.adb: Minor reformatting.
9734
97352011-08-03 Ed Schonberg <schonberg@adacore.com>
9736
9737 * sem_warn.adb (Check_One_Unit): if the only mention of a withed unit
9738 is a renaming declaration in the private part of a package, do not emit
9739 a warning that the with_clause could be moved because the renaming may
9740 be used in the body or in a child unit.
9741
97422011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
9743
9744 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
9745 Propagate the Comes_From_Source attribute from the original return
9746 object to the renaming.
9747
97482011-08-03 Jose Ruiz <ruiz@adacore.com>
9749
9750 * exp_ch7.adb (Build_Raise_Statement): Do not call
9751 Raise_From_Controlled_Operation when this routine is not present in
9752 the run-time library.
9753 (Cleanup_Protected_Object, Cleanup_Task): For restricted run-time
9754 libraries (Ravenscar), tasks are non-terminating, and protected objects
9755 and tasks can only appear at library level, so we do not want
9756 finalization of protected objects nor tasks.
9757 * exp_intr.adb: Minor clarification in comment.
9758 bindgen.adb (Gen_Adainit_Ada, Gen_Main_C, Gen_Output_File_Ada,
9759 Gen_Output_File_C): Remove references to finalization of library-level
9760 objects when using restricted run-time libraries.
9761
97622011-08-03 Ed Schonberg <schonberg@adacore.com>
9763
9764 * sem_ch3.adb (Build_Discriminant_Constraints): Set
9765 Original_Discriminant only if the parent type is a generic formal.
9766
deb8dacc
HK
97672011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
9768
9769 * exp_ch13.adb: Add with and use clause for Targparm;
9770 (Expand_N_Free_Statement): Prevent the generation of a custom
9771 Deallocate on .NET/JVM targets since this requires pools and address
9772 arithmetic.
9773 * exp_ch4.adb (Expand_Allocator_Expression): When compiling for
9774 .NET/JVM targets, attach the newly allocated object to the access
9775 type's finalization collection. Do not generate a call to
9776 Set_Finalize_Address_Ptr on .NET/JVM because this routine does not
9777 exist in the runtime.
9778 (Expand_N_Allocator): When compiling for .NET/JVM targets, do not
9779 create a custom Allocate for object that do not require initialization.
9780 Attach a newly allocated object to the access type's finalization
9781 collection on .NET/JVM.
9782 * exp_ch5.adb (Make_Tag_Ctrl_Assignment): Add special processing for
9783 assignment of controlled types on .NET/JVM. The two hidden pointers
9784 Prev and Next and stored and later restored after the assignment takes
9785 place.
9786 * exp_ch6.adb (Expand_Call): Add local constant Curr_S. Add specialized
9787 kludge for .NET/JVM to recognize a particular piece of code coming from
9788 Heap_Management and change the call to Finalize into Deep_Finalize.
9789 * exp_ch7.adb (Build_Finalization_Collection): Allow the creation of
9790 finalization collections on .NET/JVM only for types derived from
9791 Controlled. Separate the association of storage pools with a collection
9792 and only allow it on non-.NET/JVM targets.
9793 (Make_Attach_Call): New routine.
9794 (Make_Detach_Call): New routine.
9795 (Process_Object_Declarations): Suppress the generation of
9796 build-in-place return object clean up code on .NET/JVM since it uses
9797 pools.
9798 * exp_ch7.ads (Make_Attach_Call): New routine.
9799 (Make_Detach_Call): New routine.
9800 * exp_intr.adb Add with and use clause for Targparm.
9801 (Expand_Unc_Deallocation): Detach a controlled object from a collection
9802 on .NET/JVM targets.
9803 * rtsfind.ads: Add entries RE_Attach, RE_Detach and
9804 RE_Root_Controlled_Ptr to tables RE_Id and RE_Unit_Table.
9805 * snames.ads-tmpl: Add name Name_Prev. Move Name_Prev to the special
9806 names used in finalization.
9807
98082011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
9809
9810 * a-fihema.adb: Add with and use clauses for System.Soft_Links.
9811 (Attach, Detach): Lock the current task when chaining an object onto a
9812 collection.
9813
df3e68b1
HK
98142011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
9815
9816 * a-except.adb, a-except-2005.adb (Raise_From_Controlled_Operation):
9817 Rewritten to create the message strings when the exception is not
9818 raised by an abort during finalization.
9819 * a-except.ads, a-except-2005.ads: Add pragma Export for procedure
9820 Raise_From_Controlled_Operation and update its associated comment.
9821 * a-fihema.ads, a-fihema.adb: New GNAT unit.
9822 Ada.Finalization.Heap_Management provides key functionality
9823 associated with controlled objects on the heap, their creation,
9824 finalization and reclamation. Type Finalization_Collection is
9825 effectively a wrapper which sits ontop of a storage pool and performs
9826 all necessary bookkeeping for all the objects it contains. Each
9827 access-to-controlled or access-to-class-wide type receives a collection
9828 as part of its expansion. The compiler generates buffer code and
9829 invokes Allocate / Deallocate to create and destroy allocated
9830 controlled objects.
9831 * a-finali.adb ("="): Removed.
9832 * a-finali.ads ("="): Removed. Controlled types no longer carry hidden
9833 fields Prev and Next.
9834 * ali.adb (Scan_ALI): Add parsing code to process PF / Has_Finalizer.
9835 A library unit with at least one controlled object on the library level
9836 has a special finalizer which is invoked by the binder. To signal this,
9837 ali files carry field PF.
9838 * ali.ads: New field in type Unit_Record called Has_Finalizer. Add
9839 associated comment on field usage.
9840 * a-tags.adb (Get_RC_Offset): Removed.
9841 (Needs_Finalization): New routine.
9842 * a-tags.ads: Update the structure of the GNAT dispatch tables.
9843 Dispatch tables now carry field Needs_Finalization which provides
9844 runtime indication whether a type is controlled or has controlled
9845 components or both. Remove field RC_Offset.
9846 (Get_RC_Offset): Removed along with its associated pragma Export.
9847 Since tagged types with controlled components no longer carry hidden
9848 field _controller, the special mechanism to retrieve its location is no
9849 longer needed.
9850 (Needs_Finalization): New routine.
9851 * atree.ads, atree.adb (Elist24): New routine.
9852 (Set_Elist24): New routine.
9853 * atree.h: Add a define clause for Elist24.
9854 * bindgen.adb New library-level variable Lib_Final_Built.
9855 (Gen_Adafinal_Ada): Reimplemented. Depending on the restrictions or the
9856 presence of a VM target, the routine generates calls to the proper
9857 library finalization routine.
9858 (Gen_Adainit_Ada): Import Finalize_Library_Objects only on non-VM
9859 targets. Set the correct library finalization routine depending on
9860 whether the library has controlled objects or this is a VM compilation.
9861 (Gen_Finalize_Library_Ada): New routine. This procedure generates calls
9862 to library-level finalizers of compiled units in reverse order of
9863 elaboration. It also produces exception management code and reraises a
9864 potential exception after all units have been finalized.
9865 (Gen_Finalize_Library_C): New routine. This procedure generates calls to
9866 library-level finalizers of compiled units in reverse order of
9867 elaboration.
9868 (Gen_Finalize_Library_Defs_C): New routine. This procedure generates the
9869 definitions of all library-level finalizers available to the compilation
9870 (Gen_Main_Ada): Directly call Adafinal which now contails all target
9871 dependent code.
9872 (Gen_Main_C): Add new local constant Needs_Library_Finalization. Call
9873 System.Standard_Library.Adafinal directly. If the library needs
9874 finalization actions, create the sequence of finalization calls.
9875 (Gen_Output_File_Ada): Alphabetize local variables and constants.
9876 Generate a with clause for System.Soft_Links when compiling for a VM.
9877 Remove the code which imports System.Standard_Library.Adafinal as
9878 Do_Finalize. Generate the library finalization routine.
9879 (Gen_Output_File_C): Add new local constant Needs_Library_Finalization.
9880 If the library needs finalization actions, create all the definitions
9881 of library- level finalizers.
9882 (Has_Finalizer): New routine. Determines whether at least one compiled
9883 unit has a library-level finalizer.
9884 Add type Qualification_Mode.
9885 (Set_Unit_Name): Add a formal which controls the replacement of a dot.
9886 * einfo.adb: New usage of field 15 as Return_Flag.
9887 Remove Finalization_Chain_Entity from the usages of field 19.
9888 Remove Associated_Final_Chain from the usages of field 23.
9889 New usage of field 23 as Associated_Collection.
9890 New usage of field 24 as Finalizer.
9891 New usage of flag 252 as Is_Processed_Transient.
9892 (Associated_Final_Chain): Removed.
9893 (Associated_Collection): New routine.
9894 (Finalization_Chain_Entity): Removed.
9895 (Finalizer): New routine.
9896 (Is_Finalizer): New routine.
9897 (Is_Processed_Transient): New routine.
9898 (Return_Flag): New routine.
9899 (Set_Associated_Final_Chain): Removed.
9900 (Set_Associated_Collection): New routine.
9901 (Set_Finalization_Chain_Entity): Removed.
9902 (Set_Finalizer): New routine.
9903 (Set_Is_Processed_Transient): New routine.
9904 (Set_Return_Flag): New routine.
9905 (Write_Entity_Flags): Include Is_Processed_Transient to the list of
9906 displayed flags.
9907 (Write_Field8_Name): Alphabetize the output.
9908 (Write_Field11_Name): Alphabetize the output.
9909 (Write_Field12_Name): Alphabetize the output.
9910 (Write_Field13_Name): Alphabetize the output.
9911 (Write_Field14_Name): Alphabetize the output.
9912 (Write_Field15_Name): Alphabetize the output.
9913 (Write_Field16_Name): Alphabetize the output.
9914 (Write_Field17_Name): Alphabetize the output.
9915 (Write_Field18_Name): Alphabetize the output.
9916 (Write_Field19_Name): Alphabetize the output. Remove the output of
9917 Finalization_Chain_Entity.
9918 (Write_Field20_Name): Alphabetize the output.
9919 (Write_Field21_Name): Alphabetize the output.
9920 (Write_Field22_Name): Alphabetize the output.
9921 (Write_Field23_Name): Alphabetize the output. Remove the output of
9922 Associated_Final_Chain. Add output for Associated_Collection.
9923 (Write_Field24_Name): Alphabetize the output.
9924 (Write_Field25_Name): Add output for Finalizer.
9925 (Write_Field26_Name): Alphabetize the output.
9926 (Write_Field27_Name): Alphabetize the output.
9927 (Write_Field28_Name): Alphabetize the output.
9928 * einfo.ads: Add new field description for Associated_Collection and
9929 its uses in nodes.
9930 Remove Associated_Final_Chain and its uses in nodes.
9931 Remove Finalization_Chain_Entity and its uses in nodes.
9932 Add new field description for Finalizer and its uses in nodes.
9933 Add new synthesized attribute Is_Finalizer.
9934 Add new flag description for Is_Processed_Transient and its uses in
9935 nodes.
9936 Add new field description for Return_Flag and its uses in nodes.
9937 (Associated_Final_Chain): Removed along with its pragma Inline.
9938 (Associated_Collection): New routine and pragma Inline.
9939 (Finalization_Chain_Entity): Removed along with its pragma Inline.
9940 (Finalizer): New routine and pragma Inline.
9941 (Is_Finalizer): New routine and pragma Inline.
9942 (Is_Processed_Transient): New routine and pragma Inline.
9943 (Return_Flag): New routine and pragma Inline.
9944 (Set_Associated_Final_Chain): Removed along with its pragma Inline.
9945 (Set_Associated_Collection): New routine and pragma Inline.
9946 (Set_Finalization_Chain_Entity): Removed along with its pragma Inline.
9947 (Set_Finalizer): New routine and pragma Inline.
9948 (Set_Is_Processed_Transient): New routine and pragma Inline.
9949 (Set_Return_Flag): New routine and pragma Inline.
9950 * exp_aggr.adb: Alphabetize subprograms.
9951 (Build_Array_Aggr_Code): Remove formal Flist and its associated comment.
9952 (Build_Record_Aggr_Code): Remove formals Flist and Obj along with their
9953 associated comments. Remove local variables External_Final_List and
9954 Attach.
9955 Rename Ctrl_Stuff_Done to Finalization_Done. Rename local variable A to
9956 Ancestor. Remove the retrieval of finalization lists. Update the call to
9957 Make_Adjust_Call.
9958 (Convert_Aggr_In_Allocator): Remove the retrieval of finalization
9959 lists. Update the call to Late_Expansion.
9960 (Convert_Aggr_In_Assignment): Update the call to Late_Expansion.
9961 (Convert_Aggr_In_Object_Decl): Update the call to Late_Expansion.
9962 (Gen_Assign): Remove the retrieval of the finalization list used to
9963 build the assignment. Update the calls to Make_Init_Call and
9964 Make_Adjust_Call.
9965 (Gen_Ctrl_Actions_For_Aggr): Renamed to Generate_Finalization_Actions.
9966 Remove the mechanism to determine attachment levels and finalization
9967 list retrieval. Remove the processing for coextensions.
9968 (Init_Controller): Removed. Controllers no longer exist.
9969 (Late_Expansion): Remove formals Flist and Obj along with their
9970 associated comments. Update the calls to Build_Record_Aggr_Code and
9971 Build_Array_Aggr_Code.
9972 * exp_ch13.adb (Expand_N_Free_Statement): New routine.
9973 (Expand_N_Freeze_Entity): Add special processing for finalizers which
9974 appear in entry bodies, protected subprograms and task bodies.
9975 * exp_ch13.ads (Expand_N_Free_Statement): New routine.
9976 * exp_ch3.adb (Add_Final_Chain): Removed.
9977 (Build_Array_Init_Proc): Alphabetize local variables.
9978 (Build_Assignment): Alphabetize local variables. Update the call to
9979 Maked_Adjust_Call.
9980 (Build_Class_Wide_Master): Rename local variables to better reflect
9981 their role.
9982 (Build_Discriminant_Assignments): Code reformatting.
9983 (Build_Init_Call_Thru): Code reformatting.
9984 (Build_Init_Procedure): Code reformatting. Generate a special version
9985 of Deep_Finalize which is capable of finalizing all initialized
9986 components and ignore the rest.
9987 (Build_Init_Statements): Rename local variables to better reflect their
9988 role.
9989 Reimplement the mechanism to include the creation and update of an index
9990 variable called a "counter". It is used as a bookmark for tracing
9991 initialized and non-initialized components.
9992 (Build_Initialization_Call): Remove local variable Controller_Typ.
9993 Alphabetize all local variables. Remove the initialization of the
9994 record controller and update the call to Make_Init_Call.
9995 (Build_Record_Init_Proc): Rename formal Pe to Rec_Ent.
9996 New local variable Counter.
9997 (Constrain_Array): Alphabetize.
9998 (Expand_Freeze_Array_Type): Create a collection instead of a
9999 finalization list.
10000 (Expand_Freeze_Class_Wide_Type): New routine. Creates TSS primitive
10001 Finalize_Address which is used in conjunction with allocated controlled
10002 objects.
10003 (Expand_N_Object_Declaration): Remove the creation of a finalization
10004 list for anonymous access types. Update the calls to Make_Init_Call and
10005 Make_Adjust_Call.
10006 (Expand_Freeze_Record_Type): Remove local variable Flist. Remove the
10007 retrieval of finalization lists. Remove the expansion of the record
10008 controller. Create TSS primitive Finalize_Address used in conjunction
10009 with controlled objects on the heap. Create finalization collections
10010 for access-to-controlled record components.
10011 (Expand_Record_Controller): Removed.
10012 (Freeze_Type): Remove the freezing of record controllers. Freezing of
10013 class-wide types now requires additional processing. Create
10014 finalization collections for access-to-controlled types.
10015 (Increment_Counter): New routine.
10016 (Make_Counter): New routine.
10017 (Make_Eq_If): Remove the mention of Name_uController.
10018 (Make_Predefined_Primitive_Specs): There is no longer need to skip
10019 types coming from System.Finalization_Root.
10020 (Predef_Deep_Spec): Reimplemented to reflect the new parameter profiles.
10021 (Predefined_Primitive_Bodies): There is no longer need to skip types
10022 coming from System.Finalization_Root.
10023 (Stream_Operation_OK): Do not generate stream routines for
10024 type Ada.Finalization.Heap_Management.Finalization_Collection.
10025 * exp_ch3.ads: Alphabetize subprograms.
10026 * exp_ch4.adb: Remove with and use clause for Sem_Ch8.
10027 Add with and use clause for Lib.
10028 (Complete_Coextension_Finalization): Removed.
10029 (Complete_Controlled_Allocation): New routine. Create a finalization
10030 collection for anonymous access-to-controlled types. Create a custom
10031 Allocate which interfaces with the back end and the machinery in
10032 Heap_Management.
10033 (Expand_Allocator_Expression): Add necessary calls to
10034 Complete_Controlled_Allocation. Remove the retrieval of finalization
10035 lists. Update the calls to Make_Adjust_Call. Generate a call to
10036 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
10037 the associated collection.
10038 (Expand_N_Allocator): Remove the processing for dynamic coextensions.
10039 Code clean up. Remove the retrieval of finalization lists and
10040 attachment levels.
10041 Update the call to Make_Init_Call. Generate a call to
10042 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
10043 the associated collection.
10044 (Get_Allocator_Final_List): Removed. Finalization lists are not
10045 available.
10046 (Suitable_Element): Remove the mention of Name_uController.
10047 * exp_ch5.adb: Remove with and use clauses for Ttypes and Uintp.
10048 (Make_Tag_Ctrl_Assignment): Rewritten to simply do a finalization of
10049 the left hand side, carry out the assignment and adjust the left hand
10050 side.
10051 * exp_ch6.adb (Add_Final_List_Actual_To_Build_In_Place_Call): Removed.
10052 (Add_Collection_Actual_To_Build_In_Place_Call): New routine.
10053 (BIP_Formal_Suffix): Rename BIP_Final_List and BIPfinallist to
10054 BIP_Collection and BIPcollection.
10055 (Build_Heap_Allocator): New routine used to allocate the return object
10056 of a build-in-place function onto a collection.
10057 (Expand_Ctrl_Function_Call): Moved from Exp_Ch7.
10058 (Expand_Call): Do not replace direct calls to Deep routines with their
10059 aliases.
10060 (Expand_N_Extended_Return_Statement): Give all variables shorter names
10061 and update their occurrences. Add a special return flag to monitor the
10062 [ab]normal execution of the function. The flag is set right before the
10063 return statement.
10064 Rewrite the mechanism used to allocate a build-in-place return object
10065 on the heap or on a storage pool.
10066 (Is_Direct_Deep_Call): New routine.
10067 (Make_Build_In_Place_Call_In_Allocator): Add a collection to a
10068 build-in-place function call instead of a final list. Build a call to
10069 Set_Finalize_Address_Ptr to decorate the associated collection.
10070 (Make_Build_In_Place_Call_In_Anonymous_Context): Create a temporary in
10071 order to name the build-in-place function call's result for later
10072 finalization. Add a collection to a build-in-place function call
10073 instead of a final list.
10074 (Make_Build_In_Place_Call_In_Assignment): Add a collection to a
10075 build-in-place function call instead of a final list. Remove the code
10076 which moves one final list and transforms it into the actual in a
10077 nested build-in-place call.
10078 (Make_Build_In_Place_Call_In_Object_Declaration): Add a collection to a
10079 build-in-place function call instead of a final list.
10080 (Move_Final_List): Removed.
10081 (Needs_BIP_Collection): New routine.
10082 (Needs_BIP_Final_List): Removed.
10083 * exp_ch6.ads: Replace BIP_Final_List with BIP_Collection in
10084 enumeration type BIP_Formal_Kind.
10085 Update the related comment.
10086 (Needs_BIP_Collection): New routine.
10087 (Needs_BIP_Final_List): Removed.
10088 * exp_ch7.adb: Add with and use clauses for Elists, Exp_Ch6, Stringt
10089 and Ttypes. Remove with and use clauses for Sem_Type. Alphabetize the
10090 majority of subprograms in this unit. Add Name_Finalize_Address to
10091 array Name_Of and TSS_Finalize_Address to array Deep_Name_Of.
10092 (Build_Adjust_Or_Finalize_Statements): Create the adjust or finalization
10093 statements for an array type.
10094 (Build_Adjust_Statements): Create the adjust statements for a record
10095 type.
10096 (Build_Cleanup_Statements): New routine. A procedure which given any
10097 construct containing asynchronous calls, references to _master, or is a
10098 task body, a task allocation or a protected body produces the necessary
10099 runtime calls to clean up these constructs.
10100 (Build_Exception_Handler): New routine.
10101 (Build_Final_List): Removed.
10102 (Build_Finalization_Collection): New routine. A core procedure which
10103 creates a collection to service heap allocated controlled objects
10104 associated with an access-to-controlled type.
10105 (Build_Finalize_Statements): Create the finalization statements for a
10106 record types.
10107 (Build_Finalizer): New routine. A core procedure which given any
10108 construct with declarations and/or statements detects all objects which
10109 need any type of clean up (controlled objects, protected objects) and
10110 generates all necessary code to clean up the said objects in the proper
10111 order.
10112 (Build_Finalizer_Call): New routine.
10113 (Build_Initialize_Statements): Create the initialization statements for
10114 an array type. The generated routine contains code to finalize partially
10115 initialized arrays.
10116 (Build_Object_Declarations): New routine.
10117 (Build_Raise_Statement): New routine.
10118 (Clean_Simple_Protected_Objects): Removed.
10119 (Controller_Component): Removed.
10120 (Enclosing_Function): New routine.
10121 (Expand_Cleanup_Actions): Create a finalizer for a construct which has
10122 either declarations or statements or both.
10123 (Expand_N_Package_Body): Create a finalizer for a non-generic package.
10124 (Expand_N_Package_Declaration): Create a finalizer for a non-generic
10125 package.
10126 (Find_Final_List): Removed.
10127 (Global_Flist_Ref): Removed.
10128 (In_Finalization_Root): Removed.
10129 (Insert_Actions_In_Scope_Around): Determine the range of the transient
10130 scope in terms of tree nodes. Process all transient variables within
10131 that range.
10132 (Make_Adjust_Call): Rewritten. There is no longer an attach call
10133 generated after the adjust.
10134 (Make_Attach_Call): Removed.
10135 (Make_Call): New routine.
10136 (Make_Clean): Removed.
10137 (Make_Deep_Array_Body): Rewritten to simply invoke the appropriate
10138 build routines.
10139 (Make_Deep_Proc): Rewritten to generate the new profile signature used
10140 in Deep routines.
10141 (Make_Deep_Record_Body): Rewritten to simply invoke the appropriate
10142 build routines.
10143 (Make_Final_Call): Modified to simply create a call to either
10144 Deep_Finalize or Finalize.
10145 (Make_Finalize_Address_Body): New routine.
10146 (Make_Finalize_Address_Stmts): New routine. A function which produces
10147 TSS primitive Finalize_Address used in conjunction with heap allocated
10148 controlled objects.
10149 (Make_Handler_For_Ctrl_Operation): Add specialized code for .NET/JVM.
10150 (Make_Init_Call): Rewritten. There is no longer an attach call
10151 generated after initialization.
10152 (Make_Local_Deep_Finalize): New routine.
10153 (Make_Set_Finalize_Address_Ptr_Call): New routine.
10154 (Make_Transient_Block): Remove the finalization list retrieval and
10155 manipulation.
10156 (Needs_Finalization): Moved to Exp_Util.
10157 (Parent_Field_Type): New routine.
10158 (Preprocess_Components): New routine.
10159 (Process_Transient_Objects): New routine.
10160 (Wrap_HSS_In_Block): New routine.
10161 (Wrap_Transient_Declaration): Remove finalization list management and
10162 controller insertion.
10163 (Wrap_Transient_Expression): Code reformatting.
10164 (Wrap_Transient_Statement): Code reformatting.
10165 * exp_ch7.ads (Build_Final_List): Removed.
10166 (Build_Finalization_Collection): New routine.
10167 (Build_Raise_Statement): New routine.
10168 (Controller_Component): Removed.
10169 (Expand_Ctrl_Function_Call): Moved to Exp_Ch6.
10170 (Find_Final_List): Removed.
10171 (In_Finalization_Root): Removed.
10172 (Is_Simple_Protected_Type): Update related comment.
10173 (Make_Adjust_Call): New parameter profile and associated comments.
10174 (Make_Attach_Call): Removed.
10175 (Make_Final_Call): New parameter profile and associated comments.
10176 (Make_Finalize_Address_Body): New routine.
10177 (Make_Init_Call): New parameter profile and associated comments.
10178 (Make_Local_Deep_Finalize): New routine.
10179 (Make_Set_Finalize_Address_Ptr_Call): New routine.
10180 (Needs_Finalization): Moved to Exp_Util.
10181 * exp_ch9.adb (Add_Object_Pointer): Code reformatting.
10182 (Expand_N_Protected_Body): Remove the handling of finalization lists.
10183 (Find_Protection_Type): Moved to Exp_Util.
10184 * exp_disp.adb: Remove with and use clauses for Exp_Ch7.
10185 (Make_DT): Update sequence of dispatch table initialization. Remove the
10186 initialization of field RC_Offset. Add initialization of field Needs_
10187 Finalization.
10188 * exp_intr.adb (Expand_Unc_Deallocation): Code reformatting.
10189 Reimplement how an object is first finalized, then deallocated.
10190 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
10191 Code reformatting.
10192 * exp_tss.ads: Add special suffix for TSS primitive Finalize_Address.
10193 Register TSS_Finalize_Address with type TSS_Names.
10194 * exp_util.adb (Build_Allocate_Deallocate_Proc): New routine. This core
10195 procedure provides the interface between an allocation / deallocation
10196 and the support machinery in Ada.Finalization.Heap_Management.
10197 (Find_Init_Call): Code reformatting.
10198 (Find_Init_Call_In_List): Code reformatting.
10199 (Find_Protection_Type): Moved from Exp_Ch9.
10200 (Find_Prim_Op): Reimplement to add preference of recovered primitive.
10201 (Has_Controlled_Coextensions): Removed.
10202 (Has_Controlled_Objects): New routine.
10203 (In_Library_Level_Package_Body): New routine.
10204 (Insert_Action_After): New routine.
10205 (Is_Finalizable_Transient): New routine. This predicate determines
10206 whether an object declaration is one of the many variants of controlled
10207 transients.
10208 (Is_Null_Access_BIP_Func_Call): New routine.
10209 (Is_Non_BIP_Func_Call): New routine.
10210 (Is_Related_To_Func_Return): New routine.
10211 (Needs_Finalization): Moved from Exp_Ch7.
10212 * exp_util.ads (Build_Allocate_Deallocate_Proc): New routine.
10213 (Find_Protection_Type): Moved from Exp_Ch9.
10214 (Has_Controlled_Coextensions): Removed.
10215 (Has_Controlled_Objects): New routine.
10216 (In_Library_Level_Package_Body): New routine.
10217 (Insert_Action_After): New routine.
10218 (Is_Finalizable_Transient): New routine.
10219 (Is_Null_Access_BIP_Func_Call): New routine.
10220 (Is_Non_BIP_Func_Call): New routine.
10221 (Is_Related_To_Func_Return): New routine.
10222 (Needs_Finalization): Moved from Exp_ch7.
10223 * expander.adb (Expand): Add a case for N_Free_Statement.
10224 * freeze.adb (Freeze_All): Replace the generation of a finalization
10225 list with a collection for access-to-controlled types.
10226 (Freeze_Entity): Code reformatting.
10227 (Freeze_Record_Type): Remove the freezing of a record controller
10228 component.
10229 (Freeze_Subprogram): Code reformatting.
10230 * inline.adb (Cleanup_Scopes): Remove the reset of the scope
10231 finalization list.
10232 * lib-writ.adb (Write_Unit_Information): Output "PF" when a package
10233 has a library-level finalizer.
10234 * lib-writ.ads: Add "PF" to the sequence of unit attributes.
10235 * a-filico.ads, a-filico.adb, s-finimp.ads, s-finimp.adb: Removed.
10236 * Makefile.rtl: Remove a-filico and s-finimp from the list of object
10237 files. Add a-fihema to the list of object files.
10238 * par-ch4.adb:
10239 Alphabetize the associations in type Is_Parameterless_Attribute.
10240 * rtsfind.ads: Ada.Finalization_List.Controller and
10241 System.Finalization_Implementation are no longer a GNAT unit.
10242 Update the range of type Ada_Finalization_Child. Remove the following
10243 recoverable entities:
2c7f9cc0 10244
df3e68b1
HK
10245 RE_Attach_To_Final_List
10246 RE_Deep_Tag_Attach
10247 RE_Finalize_List
10248 RE_Finalize_One
10249 RE_Finalizable_Ptr_Ptr
10250 RE_Global_Final_List
10251 RE_Limited_Record_Controller
10252 RE_List_Controller
10253 RE_Move_Final_List
10254 RE_Record_Controller
10255 RE_Simple_List_Controller
2c7f9cc0 10256
df3e68b1 10257 Add the following recoverable entities:
2c7f9cc0 10258
df3e68b1
HK
10259 RE_Add_Offset_To_Address
10260 RE_Allocate
10261 RE_Base_Pool
10262 RE_Deallocate
10263 RE_Exception_Identity
10264 RE_Finalization_Collection
10265 RE_Finalization_Collection_Ptr
10266 RE_Needs_Finalization
10267 RE_Save_Library_Occurrence
10268 RE_Set_Finalize_Address_Ptr
10269 RE_Set_Storage_Pool_Ptr
10270 RE_Storage_Count
10271 * sem_aggr.adb (Resolve_Record_Aggregate): Remove mention of
10272 Name_uController.
10273 * sem_aux.adb (First_Discriminant): Remove mention of Name_uController.
10274 (First_Stored_Discriminant): Remove the mention of Name_uController.
10275 * sem_aux.ads: Comment reformatting.
10276 * sem_ch10.adb (Build_Chain): Signal the class-wide creation machinery
10277 to redecorate an already existing class-wide type.
10278 (Decorate_Tagged_Type): New parameter profile and associated comment.
10279 Create a "shadow class-wide type" for a shadow entity.
10280 * sem_ch11.adb (Analyze_Exception_Handlers): Remove the dubious setting
10281 of the final chain along with the associated comment.
10282 * sem_ch3.adb (Access_Type_Declaration): Add new local variable
10283 Full_Desig and set it to the full view of the designated type.
10284 Initialize the finalization collection to empty.
10285 (Build_Derived_Record_Type): Alphabetize local variables. Code
10286 reformatting.
10287 (Collect_Fixed_Components): Remove the mention of Name_uController.
10288 (Create_Constrained_Components): Remove the mention of Name_uController.
10289 (Make_Class_Wide_Type): Add specialized code to redecorate an existing
10290 class-wide type of a shadow entity.
10291 (Process_Full_View): Update the machinery which marks type
10292 Limited_Controlled's entity as limited.
10293 * sem_ch4.adb (Analyze_One_Call): Code reformatting.
10294 * sem_ch6.adb (Create_Extra_Formals): Do not generate a finalization
10295 list, instead make a collection build-in-place formal.
10296 * sem_ch8.adb (Analyze_Object_Renaming): Look at the available view of
10297 a designated type in order to establish a match between the renaming
10298 and the renamed entity.
10299 (Find_Selected_Component): Add guard to prevent spurious exceptions
10300 from being raised on .NET/JVM.
10301 * sem_disp.adb (Check_Dispatching_Operation): Include Finalize_Address
10302 to the list of primitive that need special processing. Update arrays
10303 C_Names and D_Names.
10304 (Replace_Types): Handle class-wide types.
10305 * sem_elab.adb (Check_A_Call): Since Deep_Initialize now has a
10306 different parameter profile, look at the first formal.
10307 * sem_prag.adb: Remove with and use clauses for Exp_Ch7. Add with and
10308 use clauses for Exp_Util.
10309 * sem_res.adb: Remove with and use clauses for Elists.
10310 (Propagate_Coextensions): Removed.
10311 (Resolve_Allocator): Do not propagate the list of coextensions from one
10312 allocator to another.
10313 * sem_util.adb (Build_Actual_Subtype_Of_Component): Rename variable
10314 Deaccessed_T to Desig_Typ.
10315 (Enter_Name): Remove the mention of Name_uController.
10316 (Gather_Components): Remove the mention of Name_uController.
10317 (Incomplete_Or_Private_View): New routine.
10318 (Is_Coextension_Root): Removed.
10319 (Is_Fully_Initialized_Type): Remove the mention of Name_uController.
10320 * sem_util.ads (Incomplete_Or_Private_View): New routine.
10321 (Is_Coextension_Root): Removed.
10322 * s-finroo.ads: Remove with clause for Ada.Unchecked_Conversion.
10323 Controlled types are now derived from a null tagged record. Remove
10324 types Finalizable_Ptr, Finalizable and Empty_Root_Controlled.
10325 * sinfo.adb (Coextensions): Removed.
10326 (Set_Coextensions): Removed.
10327 * sinfo.ads: Remove Coextensions from the explanation of node fields
10328 and its uses in nodes.
10329 Update the field usage of N_Allocator.
10330 (Coextensions): Removed along with its pragma Inline.
10331 (Set_Coextensions): Removed along with its pragma Inline.
10332 * snames.ads-tmpl: Remove names
2c7f9cc0 10333
df3e68b1
HK
10334 Name_uClean
10335 Name_uController
10336 Name_uFinal_List
10337 Name_uLocal_Final_List
10338 Name_Finalization_Root
10339 Name_Next
10340 Name_Prev
2c7f9cc0 10341
df3e68b1 10342 Add names
2c7f9cc0 10343
df3e68b1
HK
10344 Name_uFinalizer
10345 Name_Finalize_Address
10346 * s-pooglo.adb (Allocate): Add overriding indicator.
10347 (Deallocate): Add overriding indicator.
10348 (Storage_Size): Add overriding indicator.
10349 * s-soflin.adb (Adafinal_NT): Invoke Finalize_Library_Objects rather
10350 than Finalize_Global_List.
10351 (Null_Finalize_Global_List): Removed.
10352 (Save_Library_Occurrence): New routine.
10353 * s-soflin.ads: Remove variable Finalize_Global_List along with its
10354 initialization. Add variable Finalize_Library_Objects along with its
10355 pragma Export. Add variables Library_Exception and
10356 Library_Exception_Set along with their pragma Export.
10357 (Null_Finalize_Global_List): Removed.
10358 (Save_Library_Occurrence): New routine.
10359 * s-tassta.adb (Finalize_Global_Tasks): Call Finalize_Library_Objects
10360 rather than Finalize_Global_List.
10361 * tbuild.adb (Unchecked_Convert_To): Capture and set the parent field
10362 of the constructed node.
10363
2ee06322
RO
103642011-08-03 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10365
10366 * link.c: Include "auto-host.h" before system headers.
10367
f77b022b
VC
103682011-08-03 Vincent Celier <celier@adacore.com>
10369
10370 * make.adb (Gnatmake): Add to table Library_Projs only library projects
10371 that are not extended. Do not check if a library project that is
10372 extended should be regenerated. Do not add to table Library_Paths the
10373 libraries that are in extended projects. Link only with libraries that
10374 are in libray projects that are not extended.
10375 * prj-nmsc.adb (Check_Library_Attributes): Do not reset flag Library
10376 for a library project that is extended.
10377
0187b60e
AC
103782011-08-03 Gary Dismukes <dismukes@adacore.com>
10379
10380 * sem_ch6.adb (Find_Corresponding_Spec): When in an instance, skip
10381 conforming subprogram renamings that appear to be completions if they
10382 are not fully conformant.
10383 Such renamings are homographs but not completions.
10384 * sem_type.adb (Disambiguate): Handle disambiguation of overloaded
10385 names in a subprogram renaming that appears in an instance.
10386
103872011-08-03 Ed Schonberg <schonberg@adacore.com>
10388
10389 * exp_util.adb (Expand_Subtype_From_Expr): if the type is limited but
10390 not immutably limited, build actual subtype from expression to provide
10391 proper bounds to caller.
10392
103932011-08-03 Gary Dismukes <dismukes@adacore.com>
10394
10395 * sem_ch8.adb: Minor comment correction.
10396
103972011-08-03 Thomas Quinot <quinot@adacore.com>
10398
10399 * exp_strm.adb (Build_Array_Input_Function): In Ada 2005 mode, when
10400 returning a limited array, use an extended return statement.
10401
104022011-08-03 Vincent Celier <celier@adacore.com>
10403
10404 * make.adb (Initialize): If --subdirs= is used, but no project file is
10405 specified, attempt to create the specify subdir if it does not already
10406 exist and use it as the object directory as if -D had been specified.
10407
104082011-08-03 Arnaud Charlet <charlet@adacore.com>
10409
10410 * s-tpopsp-vms.adb: New file.
10411 * s-taprop-vms.adb: Put back ATCB_Key, since needed by this file on VMS.
10412 * gcc-interfaces/Makefile.in: Use s-taprop-vms.adb on VMS.
10413
e280f981
AC
104142011-08-03 Emmanuel Briot <briot@adacore.com>
10415
10416 * make.adb, makeutl.adb, makeutl.ads, clean.adb (Makeutl.Queue): new
10417 package.
10418
104192011-08-03 Yannick Moy <moy@adacore.com>
10420
10421 * cstand.adb (Create_Standard): select Universal_Integer as an ALFA type
10422 * sem_ch3.adb (Array_Type_Declaration): detect array types in ALFA
10423 * sem_util.adb, sem_util.ads (Has_Static_Array_Bounds): new function to
10424 detect that an array has static bounds.
10425
98c99a5a
AC
104262011-08-03 Thomas Quinot <quinot@adacore.com>
10427
10428 * exp_dist.adb: Minor reformatting.
10429
104302011-08-03 Arnaud Charlet <charlet@adacore.com>
10431
10432 * s-taprop-irix.adb, s-taprop-hpux-dce.adb, s-taprop-vms.adb
10433 (ATCB_Key): Removed, not always used.
10434
104352011-08-03 Emmanuel Briot <briot@adacore.com>
10436
10437 * gnatcmd.adb, make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads,
10438 clean.adb, prj-conf.adb, prj-env.adb, prj-env.ads (Makeutl): remove
10439 most remaining global variables.
10440
686d0984
AC
104412011-08-03 Robert Dewar <dewar@adacore.com>
10442
10443 * gnatcmd.adb, prj-proc.adb, mlib-prj.adb, prj.adb, makeutl.ads,
10444 prj-util.adb, prj-util.ads, prj-conf.adb, prj-env.adb: Minor
10445 reformatting.
10446
104472011-08-03 Javier Miranda <miranda@adacore.com>
10448
10449 * exp_util.adb (Is_VM_By_Copy_Actual): Include N_Slide nodes as actuals
10450 that must be passed by copy in VM targets.
10451
104522011-08-03 Emmanuel Briot <briot@adacore.com>
10453
10454 * prj.ads, prj-nmsc.adb (Files_Htable): removed this htable, which
10455 duplicates a similar htable now in the project tree.
10456
104572011-08-03 Claire Dross <dross@adacore.com>
10458
10459 * a-cfdlli.adb, a-cfhama.adb, a-cfhase.adb, a-cforma.adb, a-cforse.adb,
10460 a-cofove.adb ("=", Length, Is_Empty, Clear, Assign, Copy, Element,
10461 Replace_Element, Query_Element, Update_Element, Move, Insert, Prepend,
10462 Append, Delete, Delete_First, Delete_Last, Reverse_Element, Swap,
10463 Splice, First, First_Element, Last, Last_Element, Next, Previous, Find,
10464 Reverse_Find, Contains, Has_Element, Iterate, Reverse_Iterate, Capacity,
10465 Reserve_Length, Length, Strict_Equal, Left, Right): Data-structure
10466 update.
10467
104682011-08-03 Arnaud Charlet <charlet@adacore.com>
10469
10470 * s-taprop-posix.adb, s-taprop-linux.adb, s-taprop-tru64.adb
10471 (ATCB_Key): Removed, not always used.
10472 * s-tpopsp-posix.adb, s-tpopsp-posix-foreign.adb (ATCB_Key): Moved from
10473 s-taprop-posix.adb.
10474 * s-tpopsp-tls.adb: New file.
10475 * gcc-interface/Makefile.in: Use TLS implementation of s-tpopsp.adb on
10476 x86/x64/ia64/powerpc/sparc Linux.
10477
104782011-08-03 Arnaud Charlet <charlet@adacore.com>
10479
10480 * system-aix.ads, system-aix64.ads: Set ZCX_By_Default to True.
10481 * gcc-interface/Makefile.in: Switch to ZCX by default on AIX ports.
10482
104832011-08-03 Thomas Quinot <quinot@adacore.com>
10484
10485 * rtsfind.ads, exp_dist.adb, exp_dist.ads
10486 (Build_From_Any_Call, Build_To_Any_Call, Build_TypeCode_Call):
10487 Fix type selection for mapping integer types to PolyORB types.
10488
104892011-08-03 Bob Duff <duff@adacore.com>
10490
10491 * sem_ch7.adb: Minor comment clarification.
10492
104932011-08-03 Bob Duff <duff@adacore.com>
10494
10495 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): If we get
10496 an error analyzing a choice, skip further processing. Further
10497 processing could cause a crash or cascade errors.
10498
40ecf2f5
EB
104992011-08-03 Emmanuel Briot <briot@adacore.com>
10500
10501 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, mlib-prj.adb,
10502 prj.adb, prj.ads, makeutl.adb, makeutl.ads, clean.adb, prj-nmsc.adb,
10503 prj-util.adb, prj-util.ads, prj-conf.adb, prj-conf.ads, prj-env.adb,
10504 prj-env.ads (Shared_Project_Tree_Data): new type
10505 An aggregate project and its aggregated trees need to share the common
10506 data structures used for lists of strings, packages,... This makes the
10507 code simpler since otherwise we have to pass the root tree (also used
10508 for the configuration file data) in addition to the current project
10509 tree. This also avoids ambiguities as to which tree should be used.
10510 And finally this saves a bit of memory.
10511 (For_Every_Project_Imported): new parameter Tree.
10512 Since aggregated projects are using a different tree, we need to let
10513 the caller know which tree to use to manipulate the returned project.
10514
9fde638d
RD
105152011-08-03 Robert Dewar <dewar@adacore.com>
10516
10517 * prj-proc.adb, exp_util.ads, exp_ch9.adb, make.adb, prj-ext.adb,
10518 prj-ext.ads, alfa.ads, sem_ch4.adb, makeutl.adb, makeutl.ads,
10519 lib-xref-alfa.adb, sem_cat.adb, exp_dist.adb, get_alfa.adb,
10520 prj-env.adb, prj-env.ads, prj-tree.adb, alfa.ads: Minor reformatting.
10521
95eb8b69
AC
105222011-08-03 Javier Miranda <miranda@adacore.com>
10523
10524 * exp_util.adb, sem_aux.adb, exp_util.ads, sem_aux.ads:
10525 Move routine Is_VM_By_Copy_Actual from sem_aux to exp_util.
10526
105272011-08-03 Bob Duff <duff@adacore.com>
10528
10529 * sem_ch8.adb (Is_Primitive_Operator_In_Use): Always check In_Use on
10530 the Base_Type.
10531
105322011-08-03 Joel Brobecker <brobecker@adacore.com brobecker>
10533
10534 * g-sha256.ads, g-sha512.ads, g-sha1.ads, g-sha224.ads, g-sha384.ads,
10535 g-sehash.ads: Fix typo. Update header.
10536
105372011-08-03 Thomas Quinot <quinot@adacore.com>
10538
10539 * exp_ch6.adb (Expand_Actuals): Remove Ada_2005 guard on build-in-place
10540 expansion.
10541
105422011-08-03 Gary Dismukes <dismukes@adacore.com>
10543
10544 * sem_ch4.adb (Analyze_Overloaded_Selected_Component): Consider
10545 prefixes of private types along with records, since the selector may be
10546 a discriminant.
10547 * sem_res.adb (Resolve_Selected_Component): Consider prefixes of
10548 private types along with records, since the selector may be a
10549 discriminant.
10550
92e77027
AC
105512011-08-03 Emmanuel Briot <briot@adacore.com>
10552
b2f7ebc1 10553 * prj-pp.adb (Pretty_Print): Remove trailing blank line.
92e77027
AC
10554
105552011-08-03 Javier Miranda <miranda@adacore.com>
10556
10557 * sem_aux.adb (Is_VM_By_Copy_Actual): Fix wrong use of
10558 Tagged_Type_Expansion.
10559
105602011-08-03 Yannick Moy <moy@adacore.com>
10561
b2f7ebc1
GP
10562 * sem_res.adb (Resolve_Op_Concat_Arg): Do not issue a SPARK
10563 violation when the argument of concatenation is the name of a
10564 constant.
92e77027 10565
ab29a348
EB
105662011-08-03 Emmanuel Briot <briot@adacore.com>
10567
10568 * prj-proc.adb, prj-ext.adb, prj-ext.ads, prj-env.adb, prj-env.ads,
10569 prj-tree.adb, prj-tree.ads (Initialize_And_Copy, Copy): new subprograms
10570 (Process_Declarative_Items): new parameter Child_Env.
10571
9466892f
AC
105722011-08-03 Yannick Moy <moy@adacore.com>
10573
589ef536
GP
10574 * alfa.ads: Update format of ALFA section in ALI file in order to
10575 add a mapping from bodies to specs when both are present.
10576 (ALFA_Scope_Record): Add components for spec file/scope.
10577 * get_alfa.adb (Get_ALFA): Read the new file/scope for spec when
10578 present.
10579 * lib-xref-alfa.adb (Collect_ALFA): After all scopes have been
10580 collected, fill in the spec information when relevant.
10581 * put_alfa.adb (Put_ALFA): Write the new file/scope for spec when
9466892f
AC
10582 present.
10583
105842011-08-03 Eric Botcazou <ebotcazou@adacore.com>
10585
10586 * inline.adb (Add_Inlined_Subprogram): Do not consider the enclosing
10587 code unit to decide whether to add internally generated subprograms.
2c7f9cc0 10588
9466892f
AC
105892011-08-03 Javier Miranda <miranda@adacore.com>
10590
10591 * sem_aux.ads, sem_aux.adb (Is_VM_By_Copy_Actual): New subprogram.
589ef536
GP
10592 * exp_ch9.adb (Build_Simple_Entry_Call): Handle actuals that must
10593 be handled by copy in VM targets.
9466892f
AC
10594
105952011-08-03 Emmanuel Briot <briot@adacore.com>
10596
589ef536 10597 * make.adb, makeutl.adb, makeutl.ads (Make.Switches_Of): Share
9466892f
AC
10598 code with Makeutl.Get_Switches.
10599 * prj-tree.adb: Update comment.
10600
b5ea9143
AC
106012011-08-03 Thomas Quinot <quinot@adacore.com>
10602
10603 * sem_cat.adb (Validate_RCI_Subprogram_Declaration): Reject a remote
10604 subprogram with a limited formal that does not support external
10605 streaming.
10606
106072011-08-03 Yannick Moy <moy@adacore.com>
10608
10609 * get_alfa.adb (Get_ALFA): add missing Skip_Spaces at start of
10610 continuation line
10611 * lib-xref-alfa.adb (Add_ALFA_File): split removal of scopes that are
10612 not from current unit in two phases, because it is not possible to
10613 change the table while iterating over its content.
10614 * put_alfa.adb (Put_ALFA): reset current file/scope at each new entity
10615
106162011-08-03 Sergey Rybin <rybin@adacore.com>
10617
10618 * vms_data.ads: Add qualifier for gnatmetric --no-static-loop option
10619 * gnat_ugn.texi: Update description of complexity metrics (gnatmetric)
10620
668a19bc
ES
106212011-08-03 Ed Schonberg <schonberg@adacore.com>
10622
10623 * sem_res.adb (Resolve_Op_Concat_Arg): if the argument is an aggregate
10624 and the component type is composite, this is ambiguous for predefined
10625 concatenation, but if the node is not overloaded and the entity is a use
10626 -defined function its profile can be used to resolve that aggregate.
10627
170b2989
AC
106282011-08-03 Robert Dewar <dewar@adacore.com>
10629
10630 * exp_ch4.adb: Minor code cleanup.
10631
106322011-08-03 Thomas Quinot <quinot@adacore.com>
10633
10634 * exp_dist.adb: Do not generate distribution stubs if serious errors
10635 have been diagnosed.
10636
106372011-08-03 Ed Schonberg <schonberg@adacore.com>
10638
10639 * sem_ch4.adb (Try_Primitive_Operation): when checking the validity of
10640 the first formal of a primitive operation, go to the base type to
10641 handle properly an access to a derived type with constrained
10642 discriminants.
10643 * sem_type.adb (Disambiguate): an immediately visible operator hides a
10644 user-defined function that is only use-visible.
170b2989 10645
e917aec2
RD
106462011-08-03 Robert Dewar <dewar@adacore.com>
10647
10648 * sem_aggr.adb, sem_ch3.adb, lib.ads, gnatcmd.adb, prj-proc.adb,
10649 make.adb, lib-writ.adb, prj-part.adb, prj-part.ads, prj-ext.adb,
10650 fname-uf.adb, prj-ext.ads, prj.adb, prj.ads, sem_attr.adb, alfa.adb,
10651 prj-makr.adb, errout.adb, makeutl.adb, makeutl.ads, restrict.ads,
10652 sem_ch6.adb, g-pehage.adb, clean.adb, put_alfa.adb, lib-xref-alfa.adb,
10653 prj-nmsc.adb, prj-nmsc.ads, sem_ch8.adb, prj-pars.ads, exp_aggr.adb,
10654 prj-attr.ads, sem_ch13.adb, get_alfa.adb, prj-env.adb, prj-env.ads,
10655 alfa_test.adb, prj-tree.adb, prj-tree.ads, einfo.ads: Minor reformatting
10656
106572011-08-03 Robert Dewar <dewar@adacore.com>
10658
10659 * repinfo.adb (List_Mechanism): Add handling of
10660 Convention_Ada_Pass_By_XXX.
10661 * sem_mech.adb (Set_Mechanism): Ditto.
10662 * sem_prag.adb (Process_Convention): Add entries for
10663 Convention_Ada_Pass_By_XXX.
10664 * snames.adb-tmpl, snames.ads-tmpl: Ditto.
10665
49bfcf43
AC
106662011-08-03 Pascal Obry <obry@adacore.com>
10667
10668 * makeutl.adb: Minor reformatting.
10669
106702011-08-03 Vincent Celier <celier@adacore.com>
10671
10672 * fname-uf.adb
10673 (Get_File_Name) If the file cannot be found when there are no config
10674 pragmas file and May_Fail is True, return No_File instead of the file
10675 name, to be consistent.
10676
106772011-08-03 Pascal Obry <obry@adacore.com>
10678
10679 * adaint.c (__gnat_is_executable_file_attr): Avoid access
10680 to null pointer.
10681
106822011-08-03 Javier Miranda <miranda@adacore.com>
10683
10684 * sem_ch13.adb
10685 (Same_Representation): In VM targets the representation of arrays with
10686 aliased components differs from arrays with non-aliased components.
10687
34798441
EB
106882011-08-03 Emmanuel Briot <briot@adacore.com>
10689
10690 * prj-proc.adb, prj-attr.adb, prj-attr.ads (Get_Attribute_Index): do
10691 not systematically lower case attribute indexes that contain no "."
10692 Fix definition of several Naming attributes, which take
10693 a unit name as index and therefore should be case insensitive.
10694 Minor refactoring (reduce length of variable names).
10695
106962011-08-03 Emmanuel Briot <briot@adacore.com>
10697
10698 * makeutl.adb, makeutl.ads (Get_Switches): new subprogram.
10699
4437a530
EB
107002011-08-03 Emmanuel Briot <briot@adacore.com>
10701
10702 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, prj-part.adb,
10703 prj-part.ads, switch-m.adb, switch-m.ads, prj-makr.adb, clean.adb,
10704 prj-pars.adb, prj-pars.ads, prj-conf.adb, prj-conf.ads, prj-tree.adb,
10705 prj-tree.ads (Prj.Tree.Environment): new type.
10706
804fe3c4
EB
107072011-08-03 Emmanuel Briot <briot@adacore.com>
10708
10709 * prj-proc.adb, prj.ads, makeutl.adb, makeutl.ads, prj-conf.adb,
10710 prj-tree.adb, prj-tree.ads (Environment): new type.
10711
c565bc66
AC
107122011-08-03 Emmanuel Briot <briot@adacore.com>
10713
10714 * prj-tree.ads: Remove unused variable.
10715
107162011-08-03 Yannick Moy <moy@adacore.com>
10717
10718 * restrict.adb (Restriction_Msg): set "SPARK" all in upper case for
10719 issuing messages related to SPARK restriction violation.
10720
4ee646da
AC
107212011-08-03 Ed Schonberg <schonberg@adacore.com>
10722
10723 * sem_ch6.adb: guard against error nodes in return statements.
10724
107252011-08-03 Arnaud Charlet <charlet@adacore.com>
10726
10727 * errout.adb (Error_Msg_Internal): the main unit has not been read yet,
10728 a warning can only appear on a configuration file, so emit warning
10729 without further checks.
10730
107312011-08-03 Arnaud Charlet <charlet@adacore.com>
10732
10733 * s-interr.ads: add overriding keyword.
10734
107352011-08-03 Geert Bosch <bosch@adacore.com>
10736
10737 * exp_attr.adb: Fix minor typo.
10738
107392011-08-03 Ed Schonberg <schonberg@adacore.com>
10740
10741 * par-ch4.adb: improve error recovery.
10742
c0e538ad
AC
107432011-08-03 Emmanuel Briot <briot@adacore.com>
10744
10745 * prj-part.adb, prj-part.ads, prj-makr.adb, prj-pars.adb, prj-conf.adb,
10746 prj-env.adb (Prj.Part.Parse): change parameter Always_Errout_Finalize
10747 to Errout_Handling.
10748
107492011-08-03 Emmanuel Briot <briot@adacore.com>
10750
10751 * prj-dect.adb (Parse_Attribute_Declaration): make sure we can use
10752 "external" as an attribute name in aggregate projects.
10753
107542011-08-03 Jose Ruiz <ruiz@adacore.com>
10755
10756 * s-taprop-vxworks.adb: (Create_Task, Initialize): Ada 2012 pragma CPU
10757 uses CPU numbers starting 1, while VxWorks uses CPU numbers starting
10758 from 0, so we need to adjust.
10759
107602011-08-03 Emmanuel Briot <briot@adacore.com>
10761
10762 * prj-proc.adb, prj-ext.adb, prj-ext.ads, makeutl.adb, prj-tree.adb,
10763 prj-tree.ads, gnatcmd.adb, clean.adb (External_References): new type.
10764
c4d67e2d
AC
107652011-08-03 Yannick Moy <moy@adacore.com>
10766
10767 * sem_ch6.adb (New_Overloaded_Entity): only issue error for SPARK
10768 restriction on overloaded entity if the entity is not an operator.
10769
107702011-08-03 Yannick Moy <moy@adacore.com>
10771
10772 * sem_ch7.adb, sem_res.adb, sem_attr.adb, restrict.adb,
10773 restrict.ads: Rename remaining Check_Formal_Restriction* into
10774 Check_SPARK_Restriction*.
10775
107762011-08-03 Emmanuel Briot <briot@adacore.com>
10777
10778 * prj-proc.adb, prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb,
10779 prj-nmsc.ads, prj-err.adb (Project_Data): now discriminated on its
10780 qualifier.
10781 (Project_Empty): removed
10782 (Empty_Project): new parameter Qualifier
10783 This is used to have fields specific to aggregate projects, cleaner
10784 New field to store the list of aggregated projects.
10785 (Check_Aggregate_Project): removed
10786 (Process_Aggregated_Projects, Free): new subprograms.
10787
3f5a8fee
AC
107882011-08-03 Olivier Hainque <hainque@adacore.com>
10789
10790 * tracebak.c (STOP_FRAME ppc AIX): Stop at null return address as well.
10791
107922011-08-03 Ed Schonberg <schonberg@adacore.com>
10793
10794 * sem_ch8.adb (Analyze_Object_Renaming): if the renamed object is an
10795 explicit dereference of an unconstrained type, create a constrained
10796 subtype for it, as is done for function calls that return an
10797 unconstrained type.
10798
107992011-08-03 Thomas Quinot <quinot@adacore.com>
10800
10801 * g-pehage.adb (Finalize): Avoid possible double-free.
10802
108032011-08-03 Steve Baird <baird@adacore.com>
10804
10805 * exp_attr.adb (Expand_N_Attribute_Reference): Don't expand
10806 Elab_Spec/Body attrs in CodePeer_Mode.
10807
108082011-08-03 Javier Miranda <miranda@adacore.com>
10809
10810 * exp_aggr.adb (Flatten): Convert to positional form aggregates whose
10811 low bound is not known at compile time but they have no others choice.
10812 Done because in this case the bounds can be obtained directly from the
10813 aggregate.
10814
108152011-08-03 Ed Falis <falis@adacore.com>
10816
10817 * s-tasinf-vxworks.ads: Update comment to reflect 0 indexing of CPUs
10818 on VxWorks SMP. Remove unusable constant ANY_CPU.
10819
a96ca600
EB
108202011-08-03 Emmanuel Briot <briot@adacore.com>
10821
10822 * gnatcmd.adb, make.adb, prj-part.adb, prj-part.ads, prj-makr.adb,
10823 clean.adb, prj-nmsc.adb, prj-pars.adb, prj-conf.adb, prj-env.adb,
10824 prj-env.ads (Prj.Env.Initialize_Default_Project_Path,
10825 Prj.Env.Initialize_Empty): new subprograms
10826 (Get_Env, Find_Project): remove parameter Target_Name.
10827
3e582869
AC
108282011-08-03 Gary Dismukes <dismukes@adacore.com>
10829
10830 * sem_ch3.adb (Build_Derived_Record_Type): Test the Derive_Subps formal
10831 as a condition for the delayed call to Derived_Subprograms done for the
10832 case of the rewriting of a derived type that constrains the
10833 discriminants of its parent type.
10834 Avoids redundant subprogram derivations for private subtype derivations.
10835
108362011-08-03 Javier Miranda <miranda@adacore.com>
10837
10838 * exp_aggr.adb (Init_Hidden_Discriminants): New subprogram of
10839 Build_Record_Aggr_Code.
10840 (Build_Record_Aggr_Code): Add missing support to initialize hidden
10841 discriminants in extension aggregates.
10842
108432011-08-03 Emmanuel Briot <briot@adacore.com>
10844
10845 * prj-pp.adb (Print): also output project qualifiers, since in
10846 particular "aggregate" is mandatory in an aggregate project.
10847
108482011-08-03 Emmanuel Briot <briot@adacore.com>
10849
10850 * prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb, prj-env.adb:
10851 (Debug_Output): new function.
10852
56e94186
AC
108532011-08-03 Eric Botcazou <ebotcazou@adacore.com>
10854
10855 * gnat_ugn.texi: Document -Wstack-usage.
10856 * gcc-interface/misc.c (enumerate_modes): Add guard for ghost FP modes.
10857
108582011-08-03 Thomas Quinot <quinot@adacore.com>
10859
10860 * sem_prag.adb Issue an error (not a warning) when a C++ type does not
10861 have keyword LIMITED.
10862
108632011-08-03 Yannick Moy <moy@adacore.com>
10864
10865 * alfa.adb, alfa.ads, alfa_test.adb: New files.
10866 * ali.adb (Known_ALI_Lines): add 'C' lines (SCO) and 'F' lines (ALFA)
10867 (Scan_ALI): do not issue a fatal error if parsing known lines after Xref
10868 section (does not happen in compiler, only if code directly calls
10869 Scan_ALI).
10870 * get_alfa.adb, get_alfa.ads: New files.
10871 * lib-writ.adb, lib-writ.ads (Write_ALI): output ALFA information if
10872 needed.
10873 * lib-xref-alfa.adb: New file.
10874 * lib-xref.adb, lib-xref.ads
10875 (Xref_Entry): redefine information needed in cross-references for ALFA.
10876 Push ALFA treatments in separated local package.
10877 (Enclosing_Subpragram_Or_Package): treat specially subprogram
10878 identifiers. Return entity of package body instead of spec. Return
10879 Empty for a scope with no location.
10880 (Generate_Reference): adapt to new components for ALFA information.
10881 Remove the need for D references on definitions.
10882 (Is_Local_Reference): moved to ALFA local package
10883 (Output_References): extract subfunction as Extract_Source_Name
10884 (Output_Local_References): remove procedure, replaced by filtering of
10885 cross-references in package ALFA and printing in Put_ALFA.
10886 (Write_Entity_Name): remove procedure
10887 * lib.adb, lib.ads (Extract_Source_Name): extract here function to
10888 print exact name of entity as it appears in source file
10889 (Unit_Ref_Table): make type public for use in Lib.Xref.ALFA
10890 * put_alfa.adb, put_alfa.ads: New files.
10891 * xref_lib.adb (Search_Xref): protect read of cross-references against
10892 reading other sections of the ALI file, in gnatxref
10893 (Search): protect read of cross-references against reading other
10894 sections of the ALI file, in gnatfind.
10895 * gcc-interface/Make-lang.in: Update dependencies.
10896
108972011-08-03 Thomas Quinot <quinot@adacore.com>
10898
10899 * sem_ch3.adb: Minor reformatting.
10900
109012011-08-03 Jose Ruiz <ruiz@adacore.com>
10902
10903 * s-inmaop-vxworks.adb (Setup_Interrupt_Mask): Do nothing instead of
10904 raising an exception.
10905
109062011-08-03 Ed Schonberg <schonberg@adacore.com>
10907
10908 * sem_res.adb (Set_String_Literal_Subtype): if index type is an integer
10909 type, always use 1 as the lower bound or string, even if lower bound of
10910 context is not static, to handle properly null strings in a non-static
10911 context.
10912
109132011-08-03 Bob Duff <duff@adacore.com>
10914
10915 * sem_prag.adb (Resolve_Aggregate): An array aggregate with 'others' is
10916 always legal on the right-hand side of an assignment statement; there
10917 is always an applicable index constraint in this case. Therefore, the
10918 check for Pkind = N_Assignment_Statement is now unconditional -- it
10919 doesn't depend on whether Is_Constrained (Typ).
10920
4317e442
AC
109212011-08-03 Robert Dewar <dewar@adacore.com>
10922
10923 * exp_ch5.adb, sem_prag.adb, exp_ch4.adb: Minor reformatting.
10924
109252011-08-03 Ed Schonberg <schonberg@adacore.com>
10926
10927 * sem_ch3.adb (Build_Itype_Reference): do not create an itype reference
10928 for an itype created within a generic unit.
10929
109302011-08-03 Eric Botcazou <ebotcazou@adacore.com>
10931
10932 * gnat_ugn.texi (Switches for gcc): Make it clearer that -fno-inline
10933 suppresses all inlining.
10934
53f29d4f
AC
109352011-08-03 Robert Dewar <dewar@adacore.com>
10936
10937 * sem_ch3.adb, sem_res.adb, exp_ch13.adb, exp_disp.adb,
10938 exp_aggr.adb: Minor reformatting.
10939
109402011-08-03 Thomas Quinot <quinot@adacore.com>
10941
10942 * exp_ch5.adb (Expand_N_Assignment_Statement): Do not force inlining of
10943 tagged assignment when discriminant checks are suppressed. This is
10944 useless and extremely costly in terms of static stack usage.
10945
109462011-08-03 Bob Duff <duff@adacore.com>
10947
10948 * sem_prag.adb (Get_Base_Subprogram): Do not follow Alias for instances
10949 of generics, because this leads to the wrong entity in the wrong scope,
10950 causing (e.g.) pragma Export_Procedure to get an error if the entity is
10951 an instance.
10952 (Process_Interface_Name): Follow Alias for instances of generics, to
10953 correct for the above change.
10954
109552011-08-03 Ed Schonberg <schonberg@adacore.com>
10956
10957 * exp_ch4.adb (Expand_N_Selected_Component): If the discriminant value
10958 is an integer literal it is always safe to replace the reference. In
10959 addition, if the reference appears in the generated code for an object
10960 declaration it is necessary to copy because otherwise the reference
10961 might be to the uninitilized value of the discriminant of the object
10962 itself.
10963
109642011-08-03 Pascal Obry <obry@adacore.com>
10965
10966 * adaint.c (__gnat_is_executable_file_attr): Fix Win32 circuitry when no
10967 ACL used, in this case we want to check for ending .exe, not .exe
10968 anywhere in the path.
10969
109702011-08-03 Sergey Rybin <rybin@adacore.com>
10971
10972 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
10973 the tree structure (semantic decoration of references to record
10974 discriminants).
10975
c0b11850
AC
109762011-08-03 Gary Dismukes <dismukes@adacore.com>
10977
10978 * sem_aggr.adb (Analyze_Array_Aggregate): When checking the discrete
10979 choices of a named array aggregate, bail out when any choices are
10980 marked as Errors_Posted.
10981
109822011-08-03 Ed Schonberg <schonberg@adacore.com>
10983
10984 * exp_ch13.adb (Expand_N_Freeze_Entity): cleanup determination of scope
10985 in which entity is frozen, to handle properly loop variables in
10986 iterators.
10987
109882011-08-03 Ed Schonberg <schonberg@adacore.com>
10989
10990 * sem_res.adb (Set_String_Literal_Subtype): if the lower bound of the
10991 subtype is not static, compute the upper bound using attributes, to
10992 handle properly index types that are not integer types.
10993
109942011-08-03 Bob Duff <duff@adacore.com>
10995
10996 * gnat_rm.texi, gnat_ugn.texi: Fix some dangling URLs.
10997 Update copyright notice.
10998
109992011-08-03 Ed Schonberg <schonberg@adacore.com>
11000
11001 * sem_ch3.adb (Build_Discriminant_Constraints): Only use
11002 Original_Discriminant if within an instance.
11003 * sem_ch4.adb (Analyze_Selected_Component): Ditto.
11004
110052011-08-03 Thomas Quinot <quinot@adacore.com>
11006
11007 * einfo.ads: Minor reformatting.
11008
110092011-08-03 Ed Schonberg <schonberg@adacore.com>
11010
11011 * exp_disp.adb (Check_Premature_Freezing): diagnose the presence of a
11012 composite type with an unfrozen subcomponent, in the profile of a
11013 primitive operation.
11014
5c34e9cd
AC
110152011-08-03 Robert Dewar <dewar@adacore.com>
11016
11017 * sem_util.ads, exp_aggr.adb, exp_ch3.adb: Minor reformatting.
11018
110192011-08-03 Ed Schonberg <schonberg@adacore.com>
11020
11021 * sem_ch3.adb (Analyze_Object_Declaration): if a constant object of an
11022 unconstrained type with discriminants is initialized with an aggregate,
11023 use the constrained subtype of the aggregate as the type of the object,
11024 because it is immutable, and this allows the back-end to generate no
11025 code for the object declaration.
11026
abcd9db2
AC
110272011-08-03 Robert Dewar <dewar@adacore.com>
11028
11029 * exp_ch4.adb (Optimize_Length_Check): Fix bad handling of case where
11030 comparison operand is variable, and turns out to be zero or negative.
11031
110322011-08-03 Javier Miranda <miranda@adacore.com>
11033
11034 * exp_intr.adb
11035 (Expand_Dispatching_Constructor_Call): Disable expansion of
11036 code required for native targets. Done to avoid generating
11037 references to unavailable runtime entities in VM targets.
11038 * exp_ch3.adb
11039 (Expand_N_Object_Declaration): Add missing support to handle
11040 the explicit initialization of class-wide interface objects.
11041 Fix documentation.
11042
110432011-08-03 Matthew Heaney <heaney@adacore.com>
11044
7089ef0f
GP
11045 * a-cobove.adb (Merge): Move source onto target, instead of using
11046 Assign.
abcd9db2
AC
11047
110482011-08-03 Matthew Heaney <heaney@adacore.com>
11049
7089ef0f 11050 * a-cbdlli.adb (Splice): Move source items from first to last.
abcd9db2
AC
11051
110522011-08-03 Yannick Moy <moy@adacore.com>
11053
7089ef0f 11054 * sem_util.ads: Add comment.
abcd9db2
AC
11055
110562011-08-03 Javier Miranda <miranda@adacore.com>
11057
11058 * exp_aggr.adb
11059 (Expand_Record_Aggregate): In VM targets disable the expansion into
11060 assignments of aggregates whose type is not known at compile time.
11061
b474d6c3
ES
110622011-08-03 Ed Schonberg <schonberg@adacore.com>
11063
11064 * exp_ch9.adb (Build_Renamed_Formal_Declaration): common procedure for
11065 protected entries and task entries, to build the proper renaming
11066 declaration for entry formals, used in debugging.
11067 * exp_ch2.adb (Expand_Entry_Parameter): handle task and entry
11068 parameters in the same way.
11069
0580d807
AC
110702011-08-02 Robert Dewar <dewar@adacore.com>
11071
11072 * a-direct.adb, sinfo.ads, exp_ch9.adb, scng.adb, sem_util.adb,
11073 sem_util.ads, restrict.ads, par-prag.adb: Minor reformatting and/or
11074 code reorganization.
11075
110762011-08-02 Robert Dewar <dewar@adacore.com>
11077
11078 * debug.adb: Debug flag d.P to suppress length comparison optimization
11079 * exp_ch4.adb (Optimize_Length_Comparison): New routine to optimize
11080 comparison of Length by comparing First/Last instead.
11081
110822011-08-02 Matthew Heaney <heaney@adacore.com>
11083
11084 * a-cobove.ads: Code clean up.
11085
b191a125
AC
110862011-08-02 Vincent Celier <celier@adacore.com>
11087
11088 * adaint.c (file_names_case_sensitive_cache): New static int.
11089 (__gnat_get_file_names_case_sensitive): Cache the return value in
11090 file_names_case_sensitive_cache at the first invocation, to avoid
11091 multiple calls to getenv.
11092
110932011-08-02 Bob Duff <duff@adacore.com>
11094
11095 * sem_ch12.adb (Validate_Derived_Type_Instance): Implement AI05-0218-1.
11096
316a0661
AC
110972011-08-02 Yannick Moy <moy@adacore.com>
11098
11099 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_prag.adb, sem.ads,
11100 sem_util.adb, sem_util.ads, sem_res.adb, sem_ch2.adb, sem_ch4.adb,
11101 sem_ch6.adb, sem_ch11.adb: Add semantic flag In_Pre_Post_Expression to
11102 indicate that we are in a precondition or postcondition. This is used in
11103 Mark_Non_ALFA_Subprogram (renaming of Mark_Non_ALFA_Subprogram_Body) to
11104 decide whether to flag the spec or body of the current subprogram as
11105 not in ALFA.
11106
111072011-08-02 Fabien Chouteau <chouteau@adacore.com>
11108
11109 * impunit.adb: Add Ada.Execution_Time.Interrupts in the Ada2012 package
11110 list.
11111 * a-extiin.ads: New file.
11112
111132011-08-02 Bob Duff <duff@adacore.com>
11114
11115 * a-direct.adb (Rename): Implement AI05-0231-1. In particular, Rename
11116 now raises Name_Error instead of Use_Error in certain cases. The other
11117 parts of this AI were already implemented properly.
11118
f9adb9d4
AC
111192011-08-02 Vincent Celier <celier@adacore.com>
11120
11121 * link.c: Only import "auto-host.h" when building the gnattools.
11122
111232011-08-02 Yannick Moy <moy@adacore.com>
11124
11125 * sem_util.adb: Inter-unit inlining does not work for a subprogram
11126 which calls a local subprogram, so extract subprogram
11127 from Mark_Non_ALFA_Subprogram_Body.
11128
111292011-08-02 Javier Miranda <miranda@adacore.com>
11130
11131 * exp_ch9.adb
11132 (Extract_Dispatching_Call): If the type of the dispatching object is an
11133 access type then return an explicit dereference in the Object out-mode
11134 parameter.
11135
111362011-08-02 Gary Dismukes <dismukes@adacore.com>
11137
11138 * sem_ch3.adb (Analyze_Subtype_Declaration): Generate range
11139 compatibility checks for all indexes of an array subtype, not just the
11140 first. Reset Has_Dynamic_Range_Check on the subtype before each
11141 potential check to ensure that Insert_Range_Checks will not elide any
11142 of the dynamic checks.
11143
111442011-08-02 Yannick Moy <moy@adacore.com>
11145
11146 * par-prag.ad (Process_Restrictions_Or_Restriction_Warnings): recognize
11147 SPARK restriction at parsing time.
11148 * scng.adb (Scan): Generate a token Tok_SPARK_Hide for a SPARK HIDE
11149 directive only if the SPARK restriction is set for this unit.
11150
83f33150
YM
111512011-08-02 Yannick Moy <moy@adacore.com>
11152
11153 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb, sem_util.ads,
11154 sem_res.adb, sem_ch2.adb, sem_ch4.adb, sem_ch6.adb,
11155 sem_ch11.adb: Protect call to Current_Subprogram which might be costly
11156 when repeated. Rename Current_Subprogram_Is_Not_In_ALFA into
11157 Mark_Non_ALFA_Subprogram_Body.
11158 Split body of Mark_Non_ALFA_Subprogram_Body to get body small and
11159 inlined.
11160
7b98672f
YM
111612011-08-02 Yannick Moy <moy@adacore.com>
11162
11163 * sem_res.adb: Protect calls to Matching_Static_Array_Bounds which
11164 might be costly.
11165
052e0603
AC
111662011-08-02 Robert Dewar <dewar@adacore.com>
11167
11168 * exp_ch9.adb, exp_sel.adb, restrict.ads, exp_disp.adb, erroutc.ads,
11169 exp_ch3.adb: Minor reformatting.
11170
111712011-08-02 Emmanuel Briot <briot@adacore.com>
11172
11173 * adaint.c (__gnat_locate_exec_on_path): only returns executable
11174 files, not any regular file.
11175 (__gnat_locate_file_with_predicate): new subprogram.
11176
111772011-08-02 Yannick Moy <moy@adacore.com>
11178
11179 * sinfo.adb, sinfo.ads: Restrict the use of flags
11180 Has_Dynamic_Length_Check and Has_Dynamic_Range_Check to expression
11181 nodes, plus N_Subtype_Declaration for the 2nd one.
11182
4fbad0ba
AC
111832011-08-02 Sergey Rybin <rybin@adacore.com>
11184
11185 * gnat_rm.texi: Ramification of pragma Eliminate documentation
11186 - fix bugs in the description of Source_Trace;
11187 - get rid of UNIT_NAME;
11188
052e0603
AC
111892011-08-02 Javier Miranda <miranda@adacore.com>
11190
11191 * exp_ch9.adb
11192 (Build_Dispatching_Requeue): Adding support for VM targets
11193 since we cannot directly reference the Tag entity.
11194 * exp_sel.adb (Build_K): Adding support for VM targets.
11195 (Build_S_Assignment): Adding support for VM targets.
11196 * exp_disp.adb
11197 (Default_Prim_Op_Position): In VM targets do not restrict availability
11198 of predefined interface primitives to compiling in Ada 2005 mode.
11199 (Is_Predefined_Interface_Primitive): In VM targets this service is not
11200 restricted to compiling in Ada 2005 mode.
11201 (Make_VM_TSD): Generate code that declares and initializes the OSD
11202 record. Needed to support dispatching calls through synchronized
11203 interfaces.
11204 * exp_ch3.adb
11205 (Make_Predefined_Primitive_Specs): Enable generation of predefined
11206 primitives associated with synchronized interfaces.
11207 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
11208 primitives associated with synchronized interfaces.
11209
112102011-08-02 Yannick Moy <moy@adacore.com>
11211
11212 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
11213 statements hidden in SPARK if preceded by the HIDE directive
11214 (Parse_Exception_Handlers): mark each exception handler in a sequence of
11215 exception handlers as hidden in SPARK if preceded by the HIDE directive
11216 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
11217 if starting with the HIDE directive
11218 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
11219 starting with the HIDE directive; mark the declarations in a private
11220 part as hidden in SPARK if the private part starts with the HIDE
11221 directive
11222 * restrict.adb, restrict.ads
11223 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
11224 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
11225 argument node belongs to a part which is hidden in SPARK
11226 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
11227 parts in SPARK; protect the possibly costly call to
11228 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
11229 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
11230 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
11231 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
11232 Tok_SPARK_Hide.
11233 (Scan): recognize special comment starting with '#' and followed by
11234 SPARK keyword "hide" as a HIDE directive.
11235
112362011-08-02 Yannick Moy <moy@adacore.com>
11237
11238 * types.ads, erroutc.ads: Minor reformatting.
11239
112402011-08-02 Vincent Celier <celier@adacore.com>
11241
11242 * link.c: Add response file support for cross platforms.
11243
112442011-08-02 Ed Schonberg <schonberg@adacore.com>
11245
11246 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
11247 in an association, set parent field of copy before partial analysis.
11248 * sem_res.adb (Resolve_Slice): create reference to itype only when
11249 expansion is enabled.
11250
112512011-08-02 Yannick Moy <moy@adacore.com>
11252
11253 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
11254 for new flag denoting which subprogram bodies are in ALFA
11255 * restrict.adb, sem_ch7.adb: Update comment
11256 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
11257 sem_ch9.adb, sem_res.adb: Add calls to
11258 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
11259 * sem_ch6.adb (Analyze_Function_Return): add calls to
11260 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
11261 middle of the body, and extended return.
11262 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
11263 False when missing return.
11264 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
11265 to True for subprograms whose spec is in ALFA. Remove later on the flag
11266 on the entity used for a subprogram body when there exists a separate
11267 declaration.
11268 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
11269 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
11270 False, otherwise do nothing.
11271
112722011-08-02 Robert Dewar <dewar@adacore.com>
11273
11274 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
11275
112762011-08-02 Yannick Moy <moy@adacore.com>
11277
11278 * sem_ch4.ads: minor formatting.
11279
112802011-08-02 Yannick Moy <moy@adacore.com>
11281
11282 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
11283 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
11284 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
11285 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
11286 opt.ads: cleanup of SPARK mode
11287
112882011-08-02 Yannick Moy <moy@adacore.com>
11289
11290 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
11291 types.
11292 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
11293 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
11294 * sem_ch3.adb
11295 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
11296 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
11297 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
11298 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
11299 types.
11300 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
11301 non-static range.
11302 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
11303 functions whose return type is not in ALFA.
11304 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
11305 specifications.
11306 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
11307 parameter's type is not in ALFA.
11308 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
11309 types are in ALFA.
11310
113112011-08-02 Ed Schonberg <schonberg@adacore.com>
11312
11313 * sem_ch6 (Analyze_Expression_Function): treat the function as
11314 Inline_Always, and introduce a subprogram declaration for it when it is
11315 not a completion.
11316 * inline.adb (Add_Inlined_Body): recognize bodies that come from
11317 expression functions, so that the back-end can determine whether they
11318 can in fact be inlined.
11319 * sem_util.adb (Is_Expression_Function): predicate to determine whether
11320 a function body comes from an expression function.
11321
113222011-08-02 Gary Dismukes <dismukes@adacore.com>
11323
11324 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
11325 null exclusions to test Can_Never_Be_Null on the anonymous access types
11326 of the formals rather than testing the formals themselves. Exclude this
11327 check in cases where the Old_Formal is marked as a controlling formal,
11328 to avoid issuing spurious errors for bodies completing dispatching
11329 operations (due to the flag not getting set on controlling access
11330 formals in body specs).
11331 (Find_Corresponding_Spec): When checking full and subtype conformance of
11332 subprogram bodies in instances, pass Designated and E in that order, for
11333 consistency with the expected order of the formals (New_Id followed by
11334 Old_Id).
11335
113362011-08-02 Robert Dewar <dewar@adacore.com>
11337
11338 * sem_ch8.adb: Minor reformatting.
11339
113402011-08-02 Ed Schonberg <schonberg@adacore.com>
11341
11342 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
11343 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
11344 primitive operations of class-wide actuals.
11345
113462011-08-02 Javier Miranda <miranda@adacore.com>
11347
11348 * exp_atag.ads, exp_atag.adb
11349 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
11350 since its value is implicitly passed in argument Typ.
11351 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
11352 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
11353 Build_Common_Dispatching_Select_Statements.
11354
113552011-08-02 Robert Dewar <dewar@adacore.com>
11356
11357 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
11358 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
11359 Minor reformatting.
11360
113612011-08-02 Robert Dewar <dewar@adacore.com>
11362
11363 * sem_res.adb: Minor reformatting.
11364 * sem_prag.adb: Minor reformatting.
11365
113662011-08-02 Javier Miranda <miranda@adacore.com>
11367
11368 * exp_atag.adb, exp_atags.ads
11369 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
11370 by the tagged type Entity. Required to use this routine in the VM
11371 targets since we do not have available the Tag entity in the VM
11372 platforms.
11373 * exp_ch6.adb
11374 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
11375 Ada.Tags has not been previously loaded.
11376 * exp_ch7.adb
11377 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
11378 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
11379 * sem_aux.adb
11380 (Enclosing_Dynamic_Scope): Add missing support to handle the full
11381 view of enclosing scopes. Required to handle enclosing scopes that
11382 are synchronized types whose full view is a task type.
11383 * exp_disp.adb
11384 (Build_VM_TSDs): Minor code improvement to avoid generating and
11385 analyzing lists with empty nodes.
11386 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
11387 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
11388 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
11389 (Make_Disp_Timed_Select_Body): Add support for VM targets.
11390 (Make_Select_Specific_Data_Table): Add support for VM targets.
11391 (Make_VM_TSD): Generate code to initialize the SSD structure of
11392 the TSD.
11393
113942011-08-02 Yannick Moy <moy@adacore.com>
11395
11396 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
11397 cross-references section in ALI.
11398 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
11399 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
11400 Sub).
11401 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
11402 subprogram or package entity of a node
11403 (Is_Local_Reference_Type): new function returns True for references
11404 selected in local cross-references.
11405 (Lt): function extracted from Lt in Output_References
11406 (Write_Entity_Name): function extracted from Output_References
11407 (Generate_Definition): generate reference with type 'D' for definition
11408 of objects (object declaration and parameter specification), with
11409 appropriate locations and units, for use in local cross-references.
11410 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
11411 references of type 'I' for initialization in object definition.
11412 (Output_References): move part of function Lt and procedure
11413 Write_Entity_Name outside of the body. Ignore references of types 'D'
11414 and 'I' introduced for local cross-references.
11415 (Output_Local_References): new procedure to output the local
11416 cross-references sections.
11417 (Lref_Entity_Status): new array defining whether an entity is a local
11418 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
11419 with 'I' type when initialization expression is present.
11420 * get_scos.adb, get_scos.ads: Correct comments and typos
11421
114222011-08-02 Javier Miranda <miranda@adacore.com>
11423
11424 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
11425 the JVM target.
11426 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
11427 the JVM target.
11428 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
11429 TSD support.
11430
114312011-08-02 Vincent Celier <celier@adacore.com>
11432
11433 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
11434 (No_Space_Img): New function
11435 (Find_Excluded_Sources): When reading from a file, record the file name
11436 and the line number for each excluded source.
11437 (Mark_Excluded_Sources): When reporting an error, if the excluded
11438 sources were read from a file, include file name and line number in
11439 the error message.
11440
114412011-08-02 Ed Schonberg <schonberg@adacore.com>
11442
11443 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
11444
114452011-08-02 Robert Dewar <dewar@adacore.com>
11446
11447 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
11448
114492011-08-02 Javier Miranda <miranda@adacore.com>
11450
11451 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
11452 generation of TSDs to the DOTNET compiler.
11453 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
11454 generation of TSDs to the DOTNET compiler.
11455
114562011-08-02 Javier Miranda <miranda@adacore.com>
11457
11458 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
11459 record of all the tagged types declared inside library level package
11460 declarations, library level package bodies or library level subprograms.
11461 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
11462 associated with a given tagged type.
11463 (Build_VM_TSDs): New subprogram.
11464 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
11465 compilation units that are subprograms.
11466 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
11467 compilation units that are package bodies.
11468 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
11469 units that are a package declaration or a package instantiation.
11470 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
11471 reorganization to improve the error generated by the frontend when the
11472 function Ada.Tags.Secondary_Tag is not available.
11473 * rtsfind.ads (RE_Register_TSD): New runtime entity.
11474 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
11475
114762011-08-02 Javier Miranda <miranda@adacore.com>
11477
11478 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
11479
114802011-08-02 Robert Dewar <dewar@adacore.com>
11481
11482 * s-imenne.ads: Minor reformatting.
11483
114842011-08-02 Robert Dewar <dewar@adacore.com>
11485
11486 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
11487 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
11488 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
11489
114902011-08-02 Robert Dewar <dewar@adacore.com>
11491
11492 * einfo.ads (Materialize_Entity): Document this is only for renamings
11493 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
11494 required debug information in the case where we transform the object
11495 declaration into a renaming declaration.
11496 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
11497 object
11498 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
11499 Materialize_Entity.
11500
115012011-08-02 Robert Dewar <dewar@adacore.com>
11502
11503 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
11504 Suppress_Init_Procs.
11505 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
11506 Suppress_Initialization/Initialization_Suppressed.
11507 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
11508 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
11509 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
11510 * sem_prag.adb: New processing for pragma Suppress_Initialization.
11511
115122011-08-02 Robert Dewar <dewar@adacore.com>
11513
11514 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
11515 Minor reformatting.
11516
115172011-08-02 Ed Schonberg <schonberg@adacore.com>
11518
11519 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
11520 only have inheritable classwide pre/postconditions.
11521
115222011-08-02 Javier Miranda <miranda@adacore.com>
11523
11524 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
11525 * rtsfind.ads (RE_Check_TSD): New runtime entity.
11526 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
11527 checks if the external tag of a type is the same as the external tag
11528 of some other declaration.
11529
115302011-08-02 Thomas Quinot <quinot@adacore.com>
11531
11532 * s-taskin.ads: Minor reformatting.
11533
115342011-08-02 Emmanuel Briot <briot@adacore.com>
11535
11536 * g-comlin.adb (Display_Help): swap the order in which it prints the
11537 short help and the general usage.
11538
115392011-08-02 Ed Schonberg <schonberg@adacore.com>
11540
11541 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
11542 the aspect declarations and attach them to the generic copy for
11543 subsequent analysis.
11544 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
11545 declarations of the generic tree to the new subprogram declarations.
11546 * sem_attr.adb (Check_Precondition_Postcondition): recognize
11547 conditions that apply to a subprogram instance.
11548
115492011-08-02 Robert Dewar <dewar@adacore.com>
11550
11551 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
11552
115532011-08-02 Ed Schonberg <schonberg@adacore.com>
11554
11555 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
11556 private type with a tagged full view is not derived in the immediate
11557 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
11558
115592011-08-02 Robert Dewar <dewar@adacore.com>
11560
11561 * exp_ch4.adb: Minor reformatting.
11562
115632011-08-02 Ed Schonberg <schonberg@adacore.com>
11564
11565 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
11566 Ada2012 iterator, the loop will be rewritten during expansion into a
11567 while loop with a cursor and an element declaration. Do not analyze the
11568 body in this case, because if the container is for indefinite types the
11569 actual subtype of the elements will only be determined when the cursor
11570 declaration is analyzed.
11571
115722011-08-02 Arnaud Charlet <charlet@adacore.com>
11573
11574 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
11575 size/alignment related attributes in CodePeer_Mode.
11576
115772011-08-02 Gary Dismukes <dismukes@adacore.com>
11578
11579 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
11580 Prepend_Element, since this can result in the operation getting the
11581 wrong slot in the full type's dispatch table if the full type has
11582 inherited operations. The incomplete type's operation will get added
11583 to the proper position in the full type's primitives
11584 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
11585 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
11586 dispatching operations, since there are cases where nonprimitive
11587 subprograms can get added to the list of incomplete dependents (such
11588 as subprograms in nested packages).
11589 * sem_ch6.adb (Process_Formals): First, remove test for being in a
11590 private part when determining whether to add a primitive with a
11591 parameter of a tagged incomplete type to the Private_Dependents list.
11592 Such primitives can also occur in the visible part, and should not have
11593 been excluded from being private dependents.
11594 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
11595 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
11596 list of a Taft-amendment incomplete type is a primitive before issuing
11597 an error that the full type must appear in the same unit. There are
11598 cases where nonprimitives can be in the list (such as subprograms in
11599 nested packages).
11600 * sem_disp.adb (Derives_From): Use correct condition for checking that
11601 a formal's type is derived from the type of the corresponding formal in
11602 the parent subprogram (the condition was completely wrong). Add
11603 checking that was missing for controlling result types being derived
11604 from the result type of the parent operation.
11605
116062011-08-02 Yannick Moy <moy@adacore.com>
11607
11608 * errout.adb (First_Node): minor renaming
11609 * restrict.adb (Check_Formal_Restriction): put restriction warning on
11610 first node.
11611
116122011-08-02 Yannick Moy <moy@adacore.com>
11613
11614 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
11615 before accessing operands.
11616 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
11617 decide whether an initialization expression respects SPARK rules, as
11618 the plain node is the expanded one. This allows for more valid warnings
11619 to be issued.
11620 * gnat_rm.texi: Minor update.
11621
116222011-08-02 Arnaud Charlet <charlet@adacore.com>
11623
11624 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
11625 previous change.
11626
116272011-08-02 Robert Dewar <dewar@adacore.com>
11628
11629 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
11630
116312011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
11632
11633 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
11634 loop statements and the element renaming declaration with a block when
11635 the element type is controlled.
11636
116372011-08-02 Yannick Moy <moy@adacore.com>
11638
11639 * sinfo.ads: Minor formatting.
11640
116412011-08-02 Ed Schonberg <schonberg@adacore.com>
11642
11643 * sem_aggr.adb (Add_Association): if the association has a box and no
11644 expression, use the Sloc of the aggregate itself for the new
11645 association.
11646 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
11647 the Original_Node.
11648
116492011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
11650
11651 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
11652 When a container is provided via a function call, generate a renaming
11653 of the function result. This avoids the creation of a transient scope
11654 and the premature finalization of the container.
11655 * exp_ch7.adb (Is_Container_Cursor): Removed.
11656 (Wrap_Transient_Declaration): Remove the supression of the finalization
11657 of the list controller when the declaration denotes a container cursor,
11658 it is not needed.
11659
116602011-08-02 Yannick Moy <moy@adacore.com>
11661
11662 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
11663 node is from source, instead of the original node being from source.
11664 * sem_aggr.adb
11665 (Resolve_Array_Aggregate): refine the check for a static expression, to
11666 recognize also static ranges
11667 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
11668 Array_Type_Declaration): postpone the test for the type being a subtype
11669 mark after the type has been resolved, so that component-selection and
11670 expanded-name are discriminated.
11671 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
11672 to distinguish the case of an iteration scheme, so that an error is
11673 issed on a non-static range in SPARK except in an iteration scheme.
11674 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
11675 In_Iter_Schm = True.
11676 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
11677 user-defined operators so that they are allowed in renaming
11678 * sem_ch8.adb
11679 (Find_Selected_Component): refine the check for prefixing of operators
11680 so that they are allowed in renaming. Move the checks for restrictions
11681 on selector name after analysis discriminated between
11682 component-selection and expanded-name.
11683 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
11684 concatenation argument of string type if it is static.
11685 * sem_util.adb, sem_util.ads
11686 (Check_Later_Vs_Basic_Declarations): add a new function
11687 Is_Later_Declarative_Item to decice which declarations are allowed as
11688 later items, in the two different modes Ada 83 and SPARK. In the SPARK
11689 mode, add that renamings are considered as later items.
11690 (Enclosing_Package): new function to return the enclosing package
11691 (Enter_Name): correct the rule for homonyms in SPARK
11692 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
11693 from source (result of expansion) to avoid issuing wrong warnings.
11694
116952011-08-02 Ed Schonberg <schonberg@adacore.com>
11696
11697 * errout.adb: On anything but an expression First_Node returns its
11698 argument.
11699
117002011-08-02 Pascal Obry <obry@adacore.com>
11701
11702 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
11703
117042011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
11705
11706 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
11707 Set the associated loop as the related expression of internally
11708 generated cursors.
11709 * exp_ch7.adb (Is_Container_Cursor): New routine.
11710 (Wrap_Transient_Declaration): Supress the finalization of the list
11711 controller when the declaration denotes a container cursor.
11712
117132011-08-02 Yannick Moy <moy@adacore.com>
11714
11715 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
11716 command line now.
11717 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
11718 expression is a simple expression. This check cannot be performed in
11719 the semantics, so just drop it.
11720 (P_Index_Or_Discriminant_Constraint): move check that the index or
11721 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
11722 semantics. Other cases were previously checked in the semantics.
11723 * par-ch4.adb (P_Name): move checks that a selector name is not
11724 character literal or an operator symbol to Find_Selected_Component in
11725 the semantics
11726 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
11727 declarations are not placed after later declarations in a separate
11728 procedure in Sem_Util (possibly not the best choice?), to be used both
11729 during parsing, for Ada 83 mode, and during semantic analysis, for
11730 SPARK mode.
11731 * par-endh.adb (Check_End): move check that end label is not missing
11732 to Process_End_Label in the semantics
11733 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
11734 the special case for SPARK restriction
11735 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
11736 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
11737 parameter Force to issue the error message even on internal node (used
11738 for generated end label). Call Check_Restriction to check when an error
11739 must be issued. In SPARK mode, issue an error message even if the
11740 restriction is not set.
11741 (Check_Restriction): new procedure with an additional out parameter to
11742 inform the caller that a message has been issued
11743 * sem_aggr.adb: Minor modification of message
11744 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
11745 instead of issuing an error message directly
11746 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
11747 declarations are not placed after later declarations, by calling
11748 Check_Later_Vs_Basic_Declarations
11749 (Analyze_Subtype_Declaration): move here the check that an index or
11750 discriminant constraint must be a subtype mark. Change the check that
11751 a subtype of String must start at one so that it works on subtype marks.
11752 * sem_ch4.adb (Analyze_Call): move here the check that a named
11753 association cannot follow a positional one in a call
11754 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
11755 instead of issuing an error message directly
11756 * sem_ch8.adb (Find_Selected_Component): move here the check that a
11757 selector name is not a character literal or an operator symbol. Move
11758 here the check that the prefix of an expanded name cannot be a
11759 subprogram or a loop statement.
11760 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
11761 procedure called from parsing and semantics to check that basic
11762 declarations are not placed after later declarations
11763 (Process_End_Label): move here the check that end label is not missing
11764
117652011-08-02 Arnaud Charlet <charlet@adacore.com>
11766
11767 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
11768 representation clause in codepeer mode, since it confuses CodePeer and
11769 does not bring useful info.
11770
117712011-08-02 Ed Falis <falis@adacore.com>
11772
11773 * init.c: initialize fp hw on MILS.
11774
117752011-08-02 Ed Schonberg <schonberg@adacore.com>
11776
11777 * errout.adb (First_Node): for bodies, return the node itself (small
11778 optimization). For other nodes, do not check source_unit if the node
11779 comes from Standard.
11780
117812011-08-02 Robert Dewar <dewar@adacore.com>
11782
11783 * exp_ch3.adb: Minor comment additions.
11784 * sem_ch13.adb: Minor reformatting.
11785
117862011-08-02 Pascal Obry <obry@adacore.com>
11787
11788 * make.adb, makeutl.adb: Removes some superfluous directory separator.
11789
117902011-08-02 Robert Dewar <dewar@adacore.com>
11791
11792 * sem_attr.adb: Minor reformatting.
11793
117942011-08-02 Robert Dewar <dewar@adacore.com>
11795
11796 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
11797 (Has_Default_Component_Value): Removed
11798 * einfo.ads Comment updates
11799 (Has_Default_Aspect): Replaces Has_Default_Value
11800 (Has_Default_Component_Value): Removed
11801 * exp_ch13.adb
11802 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
11803 * exp_ch3.adb
11804 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
11805 (Get_Simple_Init_Val): Handle Default_Value aspect
11806 (Needs_Simple_Initialization): Handle Default_Value aspect
11807 * exp_ch3.ads: Needs_Simple_Initialization
11808 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
11809 * par-prag.adb (Pragma_Default[_Component]Value) Removed
11810 * sem_ch13.adb
11811 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
11812 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
11813 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
11814
118152011-08-02 Ed Schonberg <schonberg@adacore.com>
11816
11817 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
11818 package containing iteration primitives.
11819 exp_ch5.adb (Expand_Iterator_Loop): ditto.
11820
118212011-08-02 Ed Schonberg <schonberg@adacore.com>
11822
11823 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
11824 "of", pre-analyze expression in case it is a function call with
11825 finalization actions that must be placed ahead of the loop.
11826 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
11827 on an Ada2012 iterator, insert them ahead of the rewritten loop.
11828
118292011-08-02 Geert Bosch <bosch@adacore.com>
11830
11831 * cstand.adb (Create_Float_Types): Only consider C's long double for
11832 Long_Long_Float, in addition to double.
11833
118342011-08-02 Robert Dewar <dewar@adacore.com>
11835
11836 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
11837 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
11838 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
11839 Minor reformatting.
11840
118412011-08-02 Ed Schonberg <schonberg@adacore.com>
11842
11843 * sem_attr.adb: handle properly 'Result when it is a prefix of an
11844 indexed component.
11845
118462011-08-02 Javier Miranda <miranda@adacore.com>
11847
11848 * einfo.ads, einfo.adb
11849 (Original_Access_Type): Move this attribute to Node26 since there was
11850 an undocumented use of Node21 in E_Access_Subprogram_Type entities
11851 which causes conflicts and breaks the generation of the .NET compiler.
11852 (Interface_Name): Add missing documentation on JGNAT only uses of
11853 this attribute.
11854
118552011-08-02 Geert Bosch <bosch@adacore.com>
11856
11857 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
11858 (Find_Back_End_Float_Type): Likewise
11859 (Create_Back_End_Float_Types): Likewise
11860 (Create_Float_Types): Likewise
11861 (Register_Float_Type): Likewise
11862 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
11863 Nlist and split out type selection in new local Find_Base_Type function.
11864 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
11865 Nlist
11866 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
11867
118682011-08-02 Robert Dewar <dewar@adacore.com>
11869
11870 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
11871 alpha order).
11872 * opt.ads: Minor comment change.
11873 * sem_ch12.adb: Minor code reorganization.
11874
118752011-08-02 Gary Dismukes <dismukes@adacore.com>
11876
11877 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
11878 subtype's list of rep items to the list on the full subtype in the case
11879 where the lists are the same.
11880
118812011-08-02 Geert Bosch <bosch@adacore.com>
11882
11883 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
11884 using the one from System.Strings, which also deallocates all strings.
11885
118862011-08-02 Geert Bosch <bosch@adacore.com>
11887
11888 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
11889 function.
11890 * gcc-interface/Make-lang.in: Update dependencies.
11891
118922011-08-02 Olivier Hainque <hainque@adacore.com>
11893
11894 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
11895 end_locus.
11896
118972011-08-02 Javier Miranda <miranda@adacore.com>
11898
11899 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
11900 associated with anonymous access to subprograms.
11901
119022011-08-02 Geert Bosch <bosch@adacore.com>
11903
11904 * opt.ads
11905 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
11906 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
11907 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
11908 (Add_Symbol_Definition): Move to switch-c.adb
11909 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
11910 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
11911 (Add_Symbol_Definition): Move to switch-c.adb.
11912 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
11913 * sem_warn.adb
11914 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
11915 Move to warnsw.adb.
11916 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
11917 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
11918 Move to warnsw.adb.
11919 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
11920 (Add_Symbol_Definition): Moved from Prepcomp.
11921 * switch-c.ads: Update copyright notice. Use String_List instead of
11922 Argument_List, removing dependency on System.OS_Lib.
11923
119242011-08-02 Yannick Moy <moy@adacore.com>
11925
11926 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
11927 mode on initialization expression which does not respect SPARK
11928 restrictions.
11929 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
11930 if the tree referenced by its argument represents an initialization
11931 expression in SPARK, suitable for initializing an object in an object
11932 declaration.
11933
119342011-08-02 Javier Miranda <miranda@adacore.com>
11935
11936 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
11937 internally generated access to subprogram with its associated protected
11938 subprogram type.
11939 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
11940
119412011-08-02 Geert Bosch <bosch@adacore.com>
11942
11943 * cstand.adb (Register_Float_Type): Print information about type to
11944 register, if the Debug_Flag_Dot_B is set.
11945 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
11946 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
11947 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
11948 with a requested precision of more than Max_Digits digits and no more
11949 than Max_Base_Digits digits, if a range specification is present and the
11950 Predefined_Float_Types list has a suitable type to derive from.
11951 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
11952 case of type completion with pragma Import
11953 * sem_prag.adb
11954 (Process_Import_Predefined_Type): Processing to complete a type
11955 with pragma Import. Currently supports floating point types only.
11956 (Set_Convention_From_Pragma): Do nothing without underlying type.
11957 (Process_Convention): Guard against absence of underlying type,
11958 which may happen when importing incomplete types.
11959 (Process_Import_Or_Interface): Handle case of importing predefined
11960 types. Tweak error message.
11961
119622011-08-02 Eric Botcazou <ebotcazou@adacore.com>
11963
11964 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
11965 functions to previous change. Reorganize code slightly.
11966
119672011-08-02 Geert Bosch <bosch@adacore.com>
11968
11969 * back_end.ads (Register_Type_Proc): New call back procedure type for
11970 allowing the back end to provide information about available types.
11971 (Register_Back_End_Types): New procedure to register back end types.
11972 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
11973 available types.
11974 * cstand.adb (Back_End_Float_Types): New list for floating point types
11975 supported by the back end.
11976 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
11977 (Copy_Float_Type): New procedure to make new copies of predefined types.
11978 (Register_Float_Type): New call back procedure to populate the BEFT list
11979 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
11980 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
11981 (Create_Float_Types): New procedure to create entities for floating
11982 point types predefined in Standard, and put these and any remaining
11983 BEFTs on the Predefined_Float_Types list.
11984 * stand.ads (Predefined_Float_Types): New list for predefined floating
11985 point types that do not have declarations in package Standard.
11986
119872011-08-02 Eric Botcazou <ebotcazou@adacore.com>
11988
11989 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
11990 entity node for the unit containing the parameter.
11991 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
11992 (Add_Inlined_Subprogram): Likewise.
11993 * gcc-interface/Make-lang.in: Update dependencies.
11994
119952011-08-02 Thomas Quinot <quinot@adacore.com>
11996
11997 * s-stusta.adb (Print): Make sure Pos is always initialized to a
11998 suitable value.
11999
120002011-08-02 Geert Bosch <bosch@adacore.com>
12001
12002 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
12003
120042011-08-02 Eric Botcazou <ebotcazou@adacore.com>
12005
12006 * sem_type.adb (Covers): Move trivial case to the top and reuse the
12007 computed value of Base_Type.
12008
120092011-08-02 Yannick Moy <moy@adacore.com>
12010
12011 * restrict.adb (Check_Restriction): issue an error for any use of
12012 class-wide, even if the No_Dispatch restriction is not set.
12013 * sem_aggr.adb: Correct typos in comments and messages in formal mode
12014 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
12015 when completing a private extension, the type named in the private part
12016 is not the same as that named in the visible part.
12017 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
12018 of an inherited primitive operations of a tagged type or type extension
12019 that returns the tagged type.
12020 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
12021 function which returns True for an implicit operation inherited by the
12022 derived type declaration for the argument type.
12023 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
12024 order.
12025
120262011-08-02 Ed Schonberg <schonberg@adacore.com>
12027
12028 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
12029 Process_Bounds, to perform analysis with expansion of a range or an
12030 expression that is the iteration scheme for a loop.
12031 (Analyze_Iterator_Specification): If domain of iteration is given by a
12032 function call with a controlled result, as is the case if call returns
12033 a predefined container, ensure that finalization actions are properly
12034 generated.
12035 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
12036
120372011-08-02 Javier Miranda <miranda@adacore.com>
12038
12039 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
12040 * gcc-interface/Make-lang.in: Update dependencies.
12041
120422011-08-02 Javier Miranda <miranda@adacore.com>
12043
12044 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
12045 determine if the analysis is performed using N or Original_Node (N).
12046 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
12047 functionality of routine Is_Variable avoids code duplication.
12048 * checks.adb (Determine_Range): Handle temporaries generated by
12049 Remove_Side_Effects.
12050
120512011-08-02 Javier Miranda <miranda@adacore.com>
12052
12053 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
12054 expansion of the condition. Required since the previous analysis was
12055 done with expansion disabled (see Resolve_Quantified_Expression) and
12056 hence checks were not inserted and record comparisons have not been
12057 expanded.
12058
120592011-08-02 Ed Falis <falis@adacore.com>
12060
12061 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
12062 Update header.
12063
120642011-08-02 Bob Duff <duff@adacore.com>
12065
12066 * opt.ads: Minor comment fix.
12067
120682011-08-02 Bob Duff <duff@adacore.com>
12069
12070 * sem_ch12.adb (Analyze_Package_Instantiation,
12071 Analyze_Subprogram_Instantiation): Turn off style checking while
12072 analyzing an instance. Whatever style checks that apply to the generic
12073 unit should apply, so it makes no sense to apply them in an instance.
12074 This was causing trouble when compiling an instance of a runtime
12075 unit that violates the -gnatyO switch.
12076 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
12077 one of the two case statements, causing spurious errors.
12078
120792011-08-02 Robert Dewar <dewar@adacore.com>
12080
12081 * uname.adb: Minor reformatting.
12082 * gnatcmd.adb: Minor reformatting.
12083 * exp_attr.adb: Minor reformatting.
12084
120852011-08-02 Ed Schonberg <schonberg@adacore.com>
12086
12087 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
12088 No_Dispatching_Calls, do not look for the Assign primitive, because
12089 predefined primitives are not created in this case.
12090
120912011-08-02 Bob Duff <duff@adacore.com>
12092
12093 * stylesw.ads: Minor comment fixes.
12094
120952011-08-02 Robert Dewar <dewar@adacore.com>
12096
12097 * freeze.adb (Add_To_Result): New procedure.
12098
120992011-08-02 Jose Ruiz <ruiz@adacore.com>
12100
12101 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
12102 time, if the specific run-time routines for handling streams of strings
12103 are not available, use the default mechanism.
12104
121052011-08-02 Arnaud Charlet <charlet@adacore.com>
12106
12107 * s-regpat.ads: Fix typo.
12108
121092011-08-02 Vincent Celier <celier@adacore.com>
12110
12111 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
12112 not null, call it to create the in memory config project file without
12113 parsing an existing default config project file.
12114
121152011-08-02 Eric Botcazou <ebotcazou@adacore.com>
12116
12117 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
12118
121192011-08-02 Ed Schonberg <schonberg@adacore.com>
12120
12121 * sem_elim.adb: an abstract subprogram does not need an eliminate
12122 pragma for its descendant to be eliminable.
12123
121242011-08-02 Ed Falis <falis@adacore.com>
12125
12126 * init.c: revert to handling before previous checkin for VxWorks
12127 * s-intman-vxworks.adb: delete unnecessary declarations related to
12128 using Ada interrupt facilities for handling signals.
12129 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
12130 * s-intman-vxworks.ads: Import __gnat_install_handler as
12131 Initialize_Interrupts.
12132 * s-taprop-vxworks.adb: Delete Signal_Mask.
12133 (Abort_Handler): change construction of mask to unblock exception
12134 signals.
12135
121362011-08-02 Jerome Guitton <guitton@adacore.com>
12137
12138 * a-except-2005.adb (Raise_From_Signal_Handler): Call
12139 Debug_Raise_Exception before propagation starts.
12140
121412011-08-02 Eric Botcazou <ebotcazou@adacore.com>
12142
12143 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
12144 to Restriction_Check_Required.
12145 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
12146 * sem_res.adb (Resolve_Call): Likewise.
12147 * sem_attr.adb (Check_Stream_Attribute): Likewise.
12148
121492011-08-02 Bob Duff <duff@adacore.com>
12150
12151 * stylesw.ads: Update comment.
12152 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
12153 * errout.ads: Remove obsolete comment.
12154
121552011-08-02 Javier Miranda <miranda@adacore.com>
12156
12157 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
12158 (Set_Is_Safe_To_Reevaluate): new procedure.
12159 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
12160 assignment is allowed on safe-to-reevaluate variables.
12161 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
12162 temporary created to remove side effects in expressions that use
12163 the secondary stack as safe-to-reevaluate.
12164 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
12165 variables that are not true constants.
12166
121672011-08-02 Robert Dewar <dewar@adacore.com>
12168
12169 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
12170 sem_res.adb, sem_ch6.adb: Minor reformatting.
12171
121722011-08-02 Jerome Guitton <guitton@adacore.com>
12173
12174 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
12175
121762011-08-02 Ed Schonberg <schonberg@adacore.com>
12177
12178 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
12179 not set Overridden_Operation if subprogram is an initialization
12180 procedure.
12181
121822011-08-02 Yannick Moy <moy@adacore.com>
12183
12184 * par-ch6.adb: Correct obsolete name in comments
12185 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
12186 which takes two message arguments (existing function takes one), with
12187 second message used for continuation.
12188 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
12189 block statements that originate from a source block statement, not
12190 generated block statements
12191 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
12192 symmetry with procedure case
12193 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
12194 function to issue an error in formal mode if a package specification
12195 contains more than one tagged type or type extension.
12196 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
12197 parameters matching formals of tagged types are objects (or ancestor
12198 type conversions of objects), not general expressions. Issue an error
12199 on view conversions that are not involving ancestor conversion of an
12200 extended type.
12201 (Resolve_Type_Conversion): in formal mode, issue an error on the
12202 operand of an ancestor type conversion which is not an object
12203 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
12204 procedure so that it works also for actuals of function calls
12205 (Is_Actual_Tagged_Parameter): new function which determines if its
12206 argument is an actual parameter of a formal of tagged type in a
12207 subprogram call
12208 (Is_SPARK_Object_Reference): new function which determines if the tree
12209 referenced by its argument represents an object in SPARK
12210
122112011-08-02 Robert Dewar <dewar@adacore.com>
12212
12213 * sem_ch3.adb: Minor reformatting
12214 Minor comment addition
12215 Minor error msg text change
12216
122172011-08-02 Javier Miranda <miranda@adacore.com>
12218
12219 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
12220 function. Used to be more precise when we generate a variable plus one
12221 assignment to remove side effects in the evaluation of the Bound
12222 expressions.
12223 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
12224 of the bound expression to force its re-analysis and thus expand the
12225 associated transient scope (if required). Code cleanup replacing the
12226 previous code that declared the constant entity by an invocation to
12227 routine Force_Evaluation which centralizes this work in the frontend.
12228
122292011-08-02 Robert Dewar <dewar@adacore.com>
12230
12231 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
12232 (Base_Type): Now uses improved Is_Base_Type function
12233 * einfo.ads (Base_Type): Inline this function
12234
122352011-08-02 Robert Dewar <dewar@adacore.com>
12236
12237 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
12238 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
12239
122402011-08-02 Arnaud Charlet <charlet@adacore.com>
12241
12242 * gcc-interface/Make-lang.in: Update dependencies.
12243 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
12244 targets.
12245
122462011-08-02 Yannick Moy <moy@adacore.com>
12247
12248 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
12249 non-simple expression used in delta constraint
12250 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
12251 index constraint which is not a subtype mark
12252 * par.adb: With and use Restrict
12253 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
12254 mode on component type which is not a subtype mark and default
12255 expression on component
12256 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
12257 of string which does not have a lower index bound equal to 1
12258 (Array_Type_Declaration): issue an error in formal mode on index or
12259 component type which is not a subtype mark, and on aliased keyword on
12260 component
12261 (Derived_Type_Declaration): issue an error in formal mode on interface,
12262 limited or abstract type
12263 (Record_Type_Declaration): issue an error in formal mode on interface
12264 (Record_Type_Definition): issue an error in formal mode on tagged types
12265 and type extensions not declared in the specification of a library unit
12266 package; on null non-tagged record; on variant part
12267
122682011-08-02 Vincent Celier <celier@adacore.com>
12269
12270 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
12271 not declared for qualified library project when Library_Name is not
12272 declared, but Library_Dir is.
12273
122742011-08-02 Robert Dewar <dewar@adacore.com>
12275
12276 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
12277 pragmas (affects aspects [Component_]Default_Value
12278 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
12279 component type for the resolution
12280
122812011-08-02 Eric Botcazou <ebotcazou@adacore.com>
12282
12283 * einfo.adb (Base_Type): Tune implementation for speed.
12284
122852011-08-02 Robert Dewar <dewar@adacore.com>
12286
12287 * freeze.adb: Minor reformatting.
12288
122892011-08-02 Thomas Quinot <quinot@adacore.com>
12290
12291 * scos.ads: Update comments.
12292
122932011-08-02 Ed Schonberg <schonberg@adacore.com>
12294
12295 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
12296 base type, because the parent may be a subtype of a private type whose
12297 convention is established in a private part.
12298
122992011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
12300
12301 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
12302 statement in a block when the expansion of the return expression has
12303 created a finalization chain.
12304 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
12305 with the parent node.
12306 Add N_Extended_Return_Statement to handle the case where a transient
12307 object declaration appears in the Return_Object_Declarations list of
12308 an extended return statement.
12309
123102011-08-02 Matthew Gingell <gingell@adacore.com>
12311
12312 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
12313 unused parameter 'name'.
12314
123152011-08-02 Ed Schonberg <schonberg@adacore.com>
12316
12317 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
12318 inherited operation, check whether its alias, which is the source
12319 operastion that it renames, has been marked eliminated.
12320
123212011-08-02 Javier Miranda <miranda@adacore.com>
12322
12323 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
12324 in-mode parameter whose type is an access type since it can be used to
12325 modify its designated object. Enforce code that handles as safe an
12326 access type that is not access-to-constant but it is the result of a
12327 previous removal of side-effects.
12328 (Remove_Side_Effects): Minor code reorganization of cases which require
12329 no action. Done to incorporate documentation on new cases uncovered
12330 working in this ticket: no action needed if this routine was invoked
12331 too early and the nodes are not yet decorated.
12332 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
12333 to routine Remove_Side_Effects by calls to Force_Evaluation since they
12334 were issued with actuals that are implicitly provided by
12335 Force_Evaluation.
12336
123372011-08-02 Robert Dewar <dewar@adacore.com>
12338
12339 * sem_ch3.adb, sem_res.adb: Minor reformatting.
12340
123412011-08-02 Yannick Moy <moy@adacore.com>
12342
12343 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
12344 to issue an error in formal mode on attribute not supported in this mode
12345 (Analyze_Attribute): issue errors on standard attributes not supported
12346 in formal mode.
12347 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
12348 comment, and issue error in formal mode on modulus which is not a power
12349 of 2.
12350 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
12351 range.
12352 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
12353 subtype mark.
12354 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
12355 operator on modular type (except 'not').
12356
123572011-08-02 Robert Dewar <dewar@adacore.com>
12358
12359 * gnat_rm.texi: Minor reformatting.
12360
123612011-08-02 Arnaud Charlet <charlet@adacore.com>
12362
12363 * s-osinte-linux.ads: Minor comment update and reformatting.
12364 * i-cexten.ads: Make this unit pure, as for its parent.
12365 Will allow its usage in more contexts if needed.
12366
123672011-08-02 Robert Dewar <dewar@adacore.com>
12368
12369 * s-utf_32.ads: Minor comment fix.
12370
123712011-08-02 Ed Schonberg <schonberg@adacore.com>
12372
12373 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
12374 operation of a tagged synchronized type, handle the case where the
12375 controlling argument is overloaded.
12376
123772011-08-02 Yannick Moy <moy@adacore.com>
12378
12379 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
12380 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
12381 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
12382 SPARK mode and formal verification mode on processing SPARK restriction
12383 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
12384 requiring consistency checking.
12385
123862011-08-02 Robert Dewar <dewar@adacore.com>
12387
12388 * sem_res.adb: Minor reformatting.
12389
123902011-08-02 Robert Dewar <dewar@adacore.com>
12391
12392 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
12393 a-cforse.ads: Remove unneeded with of Ada.Containers
12394 Remove commented out pragma Inline's
12395 Move specifications of new subprograms to the actual specs
12396
123972011-08-02 Yannick Moy <moy@adacore.com>
12398
12399 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
12400 a-cforse.ads: Update comments.
12401
124022011-08-02 Ed Schonberg <schonberg@adacore.com>
12403
12404 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
12405
124062011-08-02 Robert Dewar <dewar@adacore.com>
12407
12408 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
12409 a-cforse.ads, a-cofove.ads: Minor reformatting.
12410
124112011-08-02 Claire Dross <dross@adacore.com>
12412
12413 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
12414 a-cofove.ads: Add comments.
12415
124162011-08-02 Yannick Moy <moy@adacore.com>
12417
12418 * gnat_rm.texi: Document formal containers.
12419
124202011-08-02 Emmanuel Briot <briot@adacore.com>
12421
12422 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
12423 are empty sections.
12424
124252011-08-02 Robert Dewar <dewar@adacore.com>
12426
12427 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
12428 reformatting.
12429
124302011-08-02 Robert Dewar <dewar@adacore.com>
12431
12432 * aspects.adb: New aspects Default_Value and Default_Component_Value
12433 New format of Aspect_Names table checks for omitted entries
12434 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
12435 handling of boolean aspects for derived types.
12436 New aspects Default_Value and Default_Component_Value
12437 New format of Aspect_Names table checks for omitted entries
12438 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
12439 (Has_Default_Value): New flag
12440 (Has_Default_Component_Value): New flag
12441 (Has_Default_Value): New flag
12442 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
12443 table.
12444 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
12445 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
12446 Default_Value and Default_Component_Value
12447 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
12448 New aspects Default_Value and Default_Component_Value
12449 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
12450 * sprint.adb: Print N_Aspect_Specification node when called from gdb
12451
124522011-08-02 Vincent Celier <celier@adacore.com>
12453
12454 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
12455 inherit library kind.
12456
124572011-08-02 Ed Schonberg <schonberg@adacore.com>
12458
12459 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
12460 Minor reformatting.
12461
124622011-08-02 Robert Dewar <dewar@adacore.com>
12463
12464 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
12465
124662011-08-02 Yannick Moy <moy@adacore.com>
12467
12468 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
12469
124702011-08-02 Robert Dewar <dewar@adacore.com>
12471
12472 * impunit.adb: Add comment.
12473
124742011-08-02 Yannick Moy <moy@adacore.com>
12475
12476 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
12477 qualification of aggregates in formal mode
12478 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
12479 another aggregate
12480 (Resolve_Aggregate): complete the test that an aggregate is adequately
12481 qualified in formal mode
12482
124832011-08-02 Pascal Obry <obry@adacore.com>
12484
12485 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
12486 * mlib-prj.adb: Supress warning when compiling binder generated file.
12487 (Build_Library): Supress all warnings when compiling the binder
12488 generated file.
12489
124902011-08-02 Yannick Moy <moy@adacore.com>
12491
12492 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
12493 from here...
12494 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
12495 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
12496 Add with/use clauses to make Check_Formal_Restriction visible
12497
124982011-08-02 Ed Schonberg <schonberg@adacore.com>
12499
12500 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
12501 in-parameters when type of the generic formal is private in the generic
12502 spec and non-private in the body.
12503
125042011-08-02 Claire Dross <dross@adacore.com>
12505
12506 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
12507 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
12508 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
12509 * impunit.adb, Makefile.rtl: Take new files into account.
12510
125112011-08-02 Robert Dewar <dewar@adacore.com>
12512
12513 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
12514 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
12515
125162011-08-02 Yannick Moy <moy@adacore.com>
12517
12518 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
12519 formal mode
12520 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
12521 matching static array bounds, taking into account the special case of
12522 string literals
12523 * sem_ch3.adb: Typo in comment.
12524
125252011-08-02 Yannick Moy <moy@adacore.com>
12526
12527 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
12528 which issues an error in formal mode if its argument node is originally
12529 from source
12530 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
12531 has a discriminant specification so that it does not include the case
12532 of derived types
12533 (Derived_Type_Declaration): move here the test that a derived type has a
12534 discriminant specification
12535 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
12536 first element of a component association before accessing its choices
12537 (presence of component association is not enough)
12538 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
12539 declaration is a library item before accessing the next element in a
12540 list, as library items are not member of lists
12541 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
12542 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
12543 Check_Formal_Restriction whenever possible.
12544
125452011-08-02 Ed Schonberg <schonberg@adacore.com>
12546
12547 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
12548 reference when needed.
12549
125502011-08-02 Bob Duff <duff@adacore.com>
12551
12552 * gnat_ugn.texi: Fix typo.
12553
125542011-08-02 Vincent Celier <celier@adacore.com>
12555
12556 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
12557 archive file name. Do not use the full path name of archives for Open
12558 VMS.
12559
125602011-08-02 Robert Dewar <dewar@adacore.com>
12561
12562 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
12563 Analyze_Aspect_Specifications
12564 * sem_ch13.adb
12565 (Analyze_Aspect_Specifications): New handling for boolean aspects
12566 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
12567 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
12568 sequence for Analyze_Aspect_Specifications
12569 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
12570 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
12571
125722011-08-02 Robert Dewar <dewar@adacore.com>
12573
12574 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
12575 aspects, since these no longer exist.
12576
125772011-08-02 Robert Dewar <dewar@adacore.com>
12578
12579 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
12580 semicolon, do not try to see if there are aspects following it.
12581 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
12582 aspect spec.
12583
125842011-08-02 Robert Dewar <dewar@adacore.com>
12585
12586 * sem_ch8.adb, aspects.ads: Minor reformatting.
12587
125882011-08-02 Eric Botcazou <ebotcazou@adacore.com>
12589
12590 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
12591 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
12592 extracted from...
12593 (Analyze_Aspect_Specifications): ...here. Call above procedure.
12594
125952011-08-02 Yannick Moy <moy@adacore.com>
12596
12597 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
12598 mode on subprogram declaration outside of package specification, unless
12599 it is followed by a pragma Import
12600 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
12601 Access_Type_Declaration): issue error in formal mode on access type
12602 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
12603 incomplete type
12604 (Analyze_Object_Declaration): issue error in formal mode on object
12605 declaration which does not respect SPARK restrictions
12606 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
12607 declaration which does not respect SPARK restrictions
12608 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
12609 error in formal mode on digits or delta constraint
12610 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
12611 decimal fixed point type
12612 (Derived_Type_Declaration): issue error in formal mode on derived type
12613 other than type extensions of tagged record types
12614 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
12615 with check on access definition
12616 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
12617 mode on protected definition.
12618 (Analyze_Task_Definition): issue error in formal mode on task definition
12619
126202011-08-02 Robert Dewar <dewar@adacore.com>
12621
12622 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
12623
126242011-08-02 Javier Miranda <miranda@adacore.com>
12625
12626 * sem_ch6.adb (Can_Override_Operator): New function.
12627 (Verify_Overriding_Indicator): Add missing code to check overriding
12628 indicator in operators. Fixes regression.
12629 (Check_Overriding_Indicator): Minor reformating after replacing the
12630 code that evaluates if the subprogram can override an operator by
12631 invocations to the above new function.
12632 * einfo.adb
12633 (Write_Field26_Name): Add missing code to ensure that, following
12634 the documentation in einfo.ads, this field is not shown as attribute
12635 "Static_Initialization" on non-dispatching functions.
12636
126372011-08-02 Jose Ruiz <ruiz@adacore.com>
12638
12639 * sem_res.adb (Resolve_Call): A call to
12640 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
12641 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
12642 i.e., when the second parameter is of type Time_Span.
12643
126442011-08-02 Vincent Celier <celier@adacore.com>
12645
12646 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
12647 with an archive instead of -L<library dir> -l<library name>.
12648
126492011-08-02 Ed Schonberg <schonberg@adacore.com>
12650
12651 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
12652 mark the base types In_Use in addition to making the operations
12653 use_visible.
12654
126552011-08-02 Ed Falis <falis@adacore.com>
12656
12657 * init.c: add and setup __gnat_signal_mask for the exception signals
12658 * s-inmaop-vxworks.adb: new file.
12659 * s-intman-vxworks.adb: remove unnecessary initializations and
12660 simplify remaining
12661 * s-intman-vxworks.ads: remove unnecessary variable
12662 * s-taprop-vxworks.adb: simplify signal initialization
12663
126642011-08-02 Robert Dewar <dewar@adacore.com>
12665
12666 * sem_ch8.adb: Minor code reorganization, comment updates.
12667
126682011-08-02 Robert Dewar <dewar@adacore.com>
12669
12670 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
12671 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
12672 here from Sem_Res.
12673 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
12674 (Matching_Static_Array_Bounds): Moved here from Sem_Res
12675
126762011-08-02 Ed Schonberg <schonberg@adacore.com>
12677
12678 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
12679 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
12680 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
12681 use_type_clauses, to handle more efficiently use_type and use_all_type
12682 constructs.
12683 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
12684 Ada2012 Use_All_Type clause.
12685 (Use_Class_Wide_Operations): new procedure.
12686
126872011-08-02 Robert Dewar <dewar@adacore.com>
12688
12689 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
12690 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
12691 expression to expression function.
12692
126932011-08-02 Ed Schonberg <schonberg@adacore.com>
12694
12695 * sem_ch4.adb: transform simple Ada2012 membership into equality only
12696 if types are compatible.
12697
126982011-08-02 Yannick Moy <moy@adacore.com>
12699
12700 * sem_res.adb (Matching_Static_Array_Bounds): new function which
12701 returns True if its argument array types have same dimension and same
12702 static bounds at each index.
12703 (Resolve_Actuals): issue an error in formal mode on actuals passed as
12704 OUT or IN OUT paramaters which are not view conversions in SPARK.
12705 (Resolve_Arithmetic_Op): issue an error in formal mode on
12706 multiplication or division with operands of fixed point types which are
12707 not qualified or explicitly converted.
12708 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
12709 Boolean or array type (except String) operands.
12710 (Resolve_Equality_Op): issue an error in formal mode on equality
12711 operators for array types other than String with non-matching static
12712 bounds.
12713 (Resolve_Logical_Op): issue an error in formal mode on logical operators
12714 for array types with non-matching static bounds. Factorize the code in
12715 Matching_Static_Array_Bounds.
12716 (Resolve_Qualified_Expression): issue an error in formal mode on
12717 qualified expressions for array types with non-matching static bounds.
12718 (Resolve_Type_Conversion): issue an error in formal mode on type
12719 conversion for array types with non-matching static bounds
12720
127212011-08-02 Robert Dewar <dewar@adacore.com>
12722
12723 * par-ch10.adb: Minor code reorganization (use Nkind_In).
12724
127252011-08-02 Ed Schonberg <schonberg@adacore.com>
12726
12727 * par-ch9.adb: save location of entry for proper error message.
12728
127292011-08-02 Javier Miranda <miranda@adacore.com>
12730
12731 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
12732 (Use_Full_View) which permits this routine to climb through the
12733 ancestors using the full-view of private parents.
12734 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
12735 Use_Full_View to true in calls to Is_Ancestor.
12736 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
12737 true in call to Is_Ancestor.
12738 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
12739 Use_Full_View to true in call to Is_Ancestor.
12740 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
12741 call to Is_Ancestor.
12742 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
12743 Use_Full_View to true in calls to Is_Ancestor.
12744 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
12745 Make_Select_Specific_Data_Table, Register_Primitive,
12746 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
12747 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
12748 to true in call to Is_Ancestor.
12749 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
12750 Use_Full_View to true in calls to Is_Ancestor.
12751 * exp_cg.adb
12752 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
12753 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
12754
127552011-08-02 Robert Dewar <dewar@adacore.com>
12756
12757 * gnat_rm.texi: Minor reformatting.
12758 * sem_prag.adb: Minor reformatting.
12759
127602011-08-02 Tristan Gingold <gingold@adacore.com>
12761
12762 * vms_data.ads: Add VMS qualifier for -gnateP.
12763
127642011-08-02 Robert Dewar <dewar@adacore.com>
12765
12766 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
12767 * par-ch7.adb (P_Package): Proper placement of aspects for package
12768 decl/instantiation.
12769 * par-endh.adb (Check_End): Ad Is_Sloc parameter
12770 (End_Statements): Add Is_Sloc parameterr
12771 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
12772 (Check_End): Ad Is_Sloc parameter
12773 (End_Statements): Add Is_Sloc parameterr
12774
127752011-08-02 Vincent Celier <celier@adacore.com>
12776
12777 * ug_words: Add VMS qualifier equivalent to -gnateP:
12778 /SYMBOL_PREPROCESSING.
12779
127802011-08-02 Jose Ruiz <ruiz@adacore.com>
12781
12782 * gnat-style.texi: For hexadecimal numeric literals the typical
12783 grouping of digits is 4 to represent 2 bytes.
12784 A procedure spec which is split into several lines is indented two
12785 characters.
12786
127872011-08-02 Yannick Moy <moy@adacore.com>
12788
12789 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
12790 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
12791 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
12792 properly qualified
12793 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
12794 choice in array aggregate
12795 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
12796 mark as ancestor
12797 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
12798 positional and named aggregate for record, or others in record
12799 aggregate, or multiple choice in record aggregate
12800 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
12801 array operands to logical operations AND, OR and XOR do not have the
12802 same static lower and higher bounds
12803 * sem_ch5.adb, sinfo.ads: Correct typos in comments
12804
128052011-08-01 Robert Dewar <dewar@adacore.com>
12806
12807 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
12808 Replaces Last_Source_Node_In_Sequence.
12809 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
12810 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
12811 parens and blank in string (this was inconsistently implemented).
12812 * errout.ads
12813 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
12814 blank in string (this was inconsistently implemented).
12815 * gnat1drv.adb
12816 (Set_Global_Switches): Set formal mode switches appropriately
12817 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
12818 * par-prag.adb
12819 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
12820 call Set_Error_Msg_Lang to set "spark" as language name.
12821 * par.adb: Remove unnecessary call to set formal language for errout
12822 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
12823 appropriately and call Set_Error_Msg_Lang to set "spark" as language
12824 name.
12825 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
12826 calls to it, moved after resolution so that types are known
12827 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
12828 result of concatenation is not of type String
12829 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
12830 concatenation is not properly restricted
12831 * gnat_rm.texi: Add doc on pragma Spark_95.
12832 * gcc-interface/Makefile.in: Remove obsolete target pairs for
12833 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
12834 * gcc-interface/Make-lang.in: Update dependencies.
12835
128362011-08-01 Javier Miranda <miranda@adacore.com>
12837
12838 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
12839 condition that detects if the overridden operation must replace an
12840 existing entity.
12841
128422011-08-01 Javier Miranda <miranda@adacore.com>
12843
12844 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
12845 code declarations inserted by Insert_Actions in each alternative of the
12846 N_Case_Expression node.
12847
128482011-08-01 Robert Dewar <dewar@adacore.com>
12849
12850 * sem_ch6.adb: Minor code reorganization.
12851 * sem_util.adb: Minor reformatting.
12852
128532011-08-01 Pascal Obry <obry@adacore.com>
12854
12855 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
12856 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
12857
128582011-08-01 Yannick Moy <moy@adacore.com>
12859
12860 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
12861 literal or operator symbol which is prefixed
12862 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
12863 mode on access attributes.
12864 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
12865 that concatenation operands are properly restricted in formal mode
12866 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
12867 Analyze_Concatenation_Operand. Issue an error in formal mode if the
12868 result of the concatenation has a type different from String.
12869 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
12870 Analyze_Quantified_Expression, Analyze_Slice,
12871 Analyze_Null): issue an error in formal mode on unsupported constructs
12872 * sem_ch5.adb
12873 (Analyze_Block_Statement): only issue error on source block statement
12874 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
12875 function which returns the last node in a list of nodes for which
12876 Comes_From_Source returns True, if any
12877 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
12878 Last_Source_Node_In_Sequence
12879 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
12880 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
12881 mode on unsupported constructs
12882 * sem_ch9.adb Do not return after issuing error in formal mode, as the
12883 rest of the actions may be needed later on since the error is marked as
12884 not serious.
12885 * sinfo.ads: Typos in comments.
12886
128872011-08-01 Pascal Obry <obry@adacore.com>
12888
12889 * projects.texi: Minor editing.
12890
128912011-08-01 Yannick Moy <moy@adacore.com>
12892
12893 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
12894 insertion character ~~
12895 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
12896 (Set_Error_Msg_Lang): new procedure which fixes the language for use
12897 with insertion character ~~
12898 (Set_Msg_Text): treat insertion character ~~
12899 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
12900 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
12901 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
12902 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
12903 errors related to the formal language restriction not serious
12904 (insertion character |).
12905 * par.adb (Par): set formal language for error messages if needed
12906 * sem_ch6.adb (Check_Missing_Return): take into account possible
12907 generated statements at the end of the function
12908 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
12909 enumeration value to define a new pragma SPARK_95
12910 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
12911 SPARK_Version): new type and variables to store the SPARK version
12912 (none by default).
12913 (SPARK_Mode): return True when SPARK_Version is set
12914 * par-prag.adb: Correct indentation
12915 (Prag): take Pragma_SPARK_95 into account
12916 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
12917 into account.
12918
129192011-08-01 Robert Dewar <dewar@adacore.com>
12920
12921 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
12922 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
12923 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
12924
129252011-08-01 Pascal Obry <obry@adacore.com>
12926
12927 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
12928 Target_Name to Get_Path call.
12929 (Parse_Single_Project): Likewise.
12930 (Post_Parse_Context_Clause): Likewise.
12931 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
12932 Call Initialise_Project_Path with the proper Target_Name.
12933 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
12934 search path.
12935 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
12936 with the proper Target_Name.
12937 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
12938 Part.Parse routine.
12939 (Parse_Project_And_Apply_Config): Likewise.
12940 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
12941 This is fine as this part of the code is supporting only native
12942 compilation.
12943 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
12944 is fine as this part of the code is supporting only native compilation.
12945
129462011-08-01 Yannick Moy <moy@adacore.com>
12947
12948 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
12949 of homonym, unless the homonym is one of the cases allowed in SPARK
12950 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
12951 package declaration occurring after a body.
12952
129532011-08-01 Robert Dewar <dewar@adacore.com>
12954
12955 * checks.adb, exp_ch4.adb: Minor reformatting.
12956
129572011-08-01 Javier Miranda <miranda@adacore.com>
12958
12959 * einfo.ads (Access_Disp_Table): Fix documentation.
12960 (Dispatch_Table_Wrappers): Fix documentation.
12961
129622011-08-01 Pascal Obry <obry@adacore.com>
12963
12964 * prj-env.adb, prj-env.ads: Minor reformatting.
12965
129662011-08-01 Yannick Moy <moy@adacore.com>
12967
12968 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
12969 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
12970 procedures out of these packages.
2c7f9cc0 12971 * errout.ads, errout.adb
052e0603
AC
12972 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
12973 procedures in of this package
12974 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
12975 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
12976 on misplaced later vs initial declarations, like in Ada 83
12977 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
12978 formal mode on attribute of private type whose full type declaration
12979 is not visible
12980 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
12981 package declaration inside a package specification
12982 (Analyze_Full_Type_Declaration): issue error in formal mode on
12983 controlled type or discriminant type
12984 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
12985 user-defined operator means that it should come from the source
12986 (New_Overloaded_Entity): issue error in formal mode on overloaded
12987 entity.
12988 * sem_ch6.ads, sem_ch13.ads: typos in comments.
12989
129902011-08-01 Thomas Quinot <quinot@adacore.com>
12991
12992 * atree.adb: Minor reformatting.
12993 * checks.adb: Minor reformatting.
12994
129952011-08-01 Vincent Celier <celier@adacore.com>
12996
12997 * s-parame-vms-ia64.ads: Fix typo in comment
12998 Minor reformatting
12999 * s-parame-vms-restrict.ads: Removed, unused.
13000
130012011-08-01 Javier Miranda <miranda@adacore.com>
13002
13003 * exp_ch3.adb
13004 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
13005 * sem_ch3.adb
13006 (Constrain_Index): Remove side effects in the evaluation of the bounds.
13007 * sem_ch3.ads, sem_ch3.adb
13008 (Is_Constant_Bound): New extended version of the subprogram that was
13009 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
13010 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
13011 * sem_aux.ads (Constant_Value): Fix typo in comment.
13012 * checks.adb (Generate_Index_Checks): New implementation which, for
13013 array objects with constant bounds, generates the runtime check
13014 referencing the bounds of the array type. For other cases this routine
13015 provides its previous behavior obtaining such values from the array
13016 object.
13017 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
13018 parent type.
13019 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
13020 we cannot have semantic interpretations of the new node.
13021
130222011-08-01 Ed Schonberg <schonberg@adacore.com>
13023
13024 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
13025 expressions.
13026
130272011-08-01 Arnaud Charlet <charlet@adacore.com>
13028
13029 * sem_ch8.adb: Minor code editing.
13030 * s-vxwext.adb: Remove trailing space.
13031 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
13032 consistency with other files.
13033
130342011-08-01 Thomas Quinot <quinot@adacore.com>
13035
13036 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
13037
130382011-08-01 Ed Schonberg <schonberg@adacore.com>
13039
13040 * par-ch10.adb: reject parameterized expressions as compilation unit.
13041 * sem_ch4.adb: handle properly conditional expression with overloaded
13042 then_clause and no else_clause.
13043
130442011-08-01 Tristan Gingold <gingold@adacore.com>
13045
13046 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
13047 like done by System.Aux_DEC.
13048 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
13049
130502011-08-01 Yannick Moy <moy@adacore.com>
13051
13052 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
13053 missing label at end of declaration (subprogram or package)
13054 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
13055 of positional and named parameter association
13056 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
13057 Error_Msg_SP which adds a prefix to the error message giving the name
13058 of the formal language analyzed
13059 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
13060 access result type in subprogram, unconstrained array as result type,.
13061 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
13062 procedure
13063 * sem_ch8.adb: Code clean up.
13064
130652011-08-01 Javier Miranda <miranda@adacore.com>
13066
13067 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
13068 * einfo.ads (Access_Disp_Table): Fix documentation.
13069 (Dispatch_Table_Wrappers): Fix documentation.
13070 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
13071 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
13072 to enforce the documentation of this attribute.
13073 (Set_Is_Interface): Cleanup the assertion.
13074 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
13075 the Underlying_Type entity before reading attribute Access_Disp_Table.
13076 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
13077 Locate the Underlying_Type before reading attribute Access_Disp_Table.
13078 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
13079 the Underlying_Type entity before reading attribute Access_Disp_Table.
13080 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
13081 Locate the Underlying_Type entity before reading attribute
13082 Access_Disp_Table.
13083
130842011-08-01 Ed Schonberg <schonberg@adacore.com>
13085
13086 * s-poosiz.ads: Additional overriding indicators.
13087
130882011-08-01 Yannick Moy <moy@adacore.com>
13089
13090 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
13091 formal mode.
13092 (Analyze_Iteration_Scheme): issue error in formal mode when loop
13093 parameter specification does not include a subtype mark.
13094 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
13095 formal mode on abstract subprogram.
13096 (Analyze_Subprogram_Specification): issue error in formal mode on
13097 user-defined operator.
13098 (Process_Formals): issue error in formal mode on access parameter and
13099 default expression.
13100 * sem_ch9.adb (Analyze_Abort_Statement,
13101 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
13102 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
13103 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
13104 Analyze_Requeue, Analyze_Selective_Accept,
13105 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
13106 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
13107 issue error in formal mode on user-defined raise statement.
13108
131092011-08-01 Thomas Quinot <quinot@adacore.com>
13110
13111 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
13112 declaration being hidden when overriding an implicit inherited
13113 subprogram.
13114 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
13115 (-gnats), do not complain about a source file that contains only a
13116 pragma No_Body.
13117
131182011-08-01 Ed Schonberg <schonberg@adacore.com>
13119
13120 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
13121 variable if already set.
13122
131232011-08-01 Arnaud Charlet <charlet@adacore.com>
13124
13125 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
13126 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
13127 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
13128 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
13129 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
13130 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
13131 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
13132 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
13133 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
13134 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
13135 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
13136 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
13137 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
13138 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
13139 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
13140 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
13141 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
13142 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
13143 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
13144 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
13145 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
13146 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
13147 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
13148 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
13149 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
13150 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
13151 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
13152 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
13153 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
13154 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
13155 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
13156 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
13157 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
13158 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
13159 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
13160 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
13161 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
13162 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
13163 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
13164 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
13165 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
13166 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
13167 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
13168 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
13169 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
13170 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
13171 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
13172 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
13173 s-osinte-mingw.ads: Update to GPLv3 run-time license.
13174 Use GNAT instead of GNARL.
13175
131762011-08-01 Bob Duff <duff@adacore.com>
13177
13178 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
13179 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
13180 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
13181 reformatting.
13182
131832011-08-01 Yannick Moy <moy@adacore.com>
13184
13185 * debug.adb (d.D) reverve flag for the SPARK mode
13186 (d.E) reverve flag for SPARK generation mode
13187 (d.F) reverve flag for Why generation mode
2c7f9cc0 13188 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
052e0603
AC
13189 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
13190 functions which return True when the corresponding modes are set
13191 (Formal_Language): return "spark" or "alfa" when in formal verification
13192 mode.
13193 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
13194 Error_Msg to prefix the error message with a tag giving the formal
13195 language
13196 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
13197 message with a tag giving the formal language
13198 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
13199 block statement
13200 (Analyze_Case_Statement): issue error in formal mode on case statement
13201 with a single "others" case alternative
13202 (Analyze_Exit_Statement): issue errors in formal mode on exit
13203 statements which do not respect SPARK restrictions
13204 (Analyze_Goto_Statement): issue error in formal mode on goto statement
13205 (Check_Unreachable_Code): always issue an error (not a warning) in
13206 formal mode on unreachable code (concerns both code after an infinite
13207 loop and after an unconditional jump, both not allowed in SPARK)
13208 * sem_ch6.adb (Analyze_Return_Statement): add call to
13209 Set_Return_Present for a procedure containing a return statement
13210 (already done for functions in Analyze_Function_Return)
13211 (Analyze_Function_Return): issue error in formal mode on extended
13212 return or if return is not last statement in function
13213 (Check_Missing_Return): issue error in formal mode if function does
13214 not end with return or if procedure contains a return
13215 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
13216 function to detect if there is an inner scope of its parameter S which
13217 is a loop.
13218
132192011-08-01 Thomas Quinot <quinot@adacore.com>
13220
13221 * sem_ch6.ads: Minor reformatting.
13222
132232011-08-01 Javier Miranda <miranda@adacore.com>
13224
13225 * sem_util.adb (Abstract_Interface_List): Complete condition when
13226 processing private type declarations to avoid reading unavailable
13227 attribute.
13228 (Is_Synchronized_Tagged_Type): Complete condition when processing
13229 private extension declaration nodes to avoid reading unavailable
13230 attribute.
13231
132322011-08-01 Thomas Quinot <quinot@adacore.com>
13233
13234 * sem_ch3.adb: Minor reformatting.
13235
132362011-08-01 Thomas Quinot <quinot@adacore.com>
13237
13238 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
13239 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
13240 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
13241 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
13242 for VMS, instead parametrize the common implementation with
13243 System.Parameters declarations.
13244
132452011-08-01 Eric Botcazou <ebotcazou@adacore.com>
13246
13247 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
13248
132492011-08-01 Tristan Gingold <gingold@adacore.com>
13250
13251 * seh_init.c: Fix SEH handler installation on win64.
13252
132532011-08-01 Ed Schonberg <schonberg@adacore.com>
13254
13255 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
13256 double analysis of an anonymous access to subprogram, because it can
13257 lead to improper sharing of profiles and a back-end crash.
13258
132592011-08-01 Robert Dewar <dewar@adacore.com>
13260
13261 * make.adb, sem_ch4.adb: Minor reformatting.
13262 * gcc-interface/Make-lang.in: Update dependencies.
13263 * sem_util.adb, exp_ch5.adb: Minor reformatting.
13264
132652011-08-01 Arnaud Charlet <charlet@adacore.com>
13266
13267 * gnat_rm.texi: Fix definition of Long_Integer.
13268
132692011-08-01 Ed Schonberg <schonberg@adacore.com>
13270
13271 * exp_aggr.adb: check limit size of static aggregate unconditionally,
13272 to prevent storage exhaustion.
13273 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
13274 finalized is a function body, insert the cleanup code before the final
13275 return statement, to prevent spurious warnings.
13276 * s-pooglo.ads: add overriding indicator.
13277
132782011-08-01 Ed Schonberg <schonberg@adacore.com>
13279
13280 * sem_ch4.adb (Operator_Check): improve error message when both a
13281 with_clause and a use_clause are needed to make operator usage legal.
13282 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
13283 determine whether a compilation unit is visible within an other,
13284 either through a with_clause in the current unit, or a with_clause in
13285 its library unit or one one of its parents.
13286
132872011-08-01 Ed Schonberg <schonberg@adacore.com>
13288
13289 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
13290 over an arbitrary expression of an array or container type.
13291 * lib-xref.adb: clarify comment.
13292
132932011-08-01 Bob Duff <duff@adacore.com>
13294
13295 * einfo.ads: Minor reformatting.
13296 * debug.adb: Minor comment improvement.
13297
132982011-08-01 Javier Miranda <miranda@adacore.com>
13299
13300 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
13301 consider hidden subprograms as valid candidates.
13302
133032011-08-01 Arnaud Charlet <charlet@adacore.com>
13304
13305 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
13306
133072011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
13308
13309 * gnat_ugn.texi: Fix typo.
13310
133112011-08-01 Robert Dewar <dewar@adacore.com>
13312
13313 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
13314 lib-xref.adb: Minor reformatting
13315
133162011-08-01 Gary Dismukes <dismukes@adacore.com>
13317
13318 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
13319 when to generate a call to Move_Final_List.
13320 (Has_Controlled_Parts): Remove this function.
13321
133222011-08-01 Geert Bosch <bosch@adacore.com>
13323
13324 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
13325 "," in choice list.
13326
133272011-08-01 Thomas Quinot <quinot@adacore.com>
13328
13329 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
13330 explicit raise of a predefined exception as Comes_From_Source if the
13331 original N_Raise_Statement comes from source.
13332
133332011-08-01 Robert Dewar <dewar@adacore.com>
13334
13335 * sinfo.ads: Add comment.
13336 * sem_ch6.adb: Minor reformatting.
13337
133382011-08-01 Robert Dewar <dewar@adacore.com>
13339
13340 * freeze.adb (Freeze_Entity): Refine check for bad component size
13341 clause to avoid rejecting confirming clause when atomic/aliased present.
13342
133432011-08-01 Ed Schonberg <schonberg@adacore.com>
13344
13345 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
13346 better determine whether an entity reference is a write.
13347 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
13348 subcomponent.
13349 * lib-xref.adb (Output_References): Do no suppress a read reference at
13350 the same location as an immediately preceeding modify-reference, to
13351 handle properly in-out actuals.
13352
133532011-08-01 Tristan Gingold <gingold@adacore.com>
13354
13355 * env.c (__gnat_setenv) [VMS]: Refine previous change.
13356
133572011-08-01 Quentin Ochem <ochem@adacore.com>
13358
13359 * i-cstrin.adb (New_String): Changed implementation, now uses only the
13360 heap to compute the result.
13361
133622011-08-01 Robert Dewar <dewar@adacore.com>
13363
13364 * atree.ads: Minor reformatting.
13365
133662011-08-01 Emmanuel Briot <briot@adacore.com>
13367
13368 * g-expect.adb (Get_Command_Output): Fix memory leak.
13369
133702011-08-01 Geert Bosch <bosch@adacore.com>
13371
13372 * cstand.adb (P_Float_Type): New procedure to print the definition of
13373 predefined fpt types.
13374 (P_Mixed_Name): New procedure to print a name using mixed case
13375 (Print_Standard): Use P_Float_Type for printing floating point types
13376 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
13377 precision IEEE float.
13378
133792011-08-01 Thomas Quinot <quinot@adacore.com>
13380
13381 * sem_ch3.adb: Minor reformatting.
13382
133832011-08-01 Ed Schonberg <schonberg@adacore.com>
13384
13385 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
13386 the completion of a generic function, insert the new body rather than
13387 rewriting the original.
13388
133892011-08-01 Yannick Moy <moy@adacore.com>
13390
13391 * sinfo.ads, errout.ads: Typos in comments.
13392
133932011-08-01 Robert Dewar <dewar@adacore.com>
13394
13395 * par-endh.adb: Minor reformatting.
13396
133972011-08-01 Robert Dewar <dewar@adacore.com>
13398
13399 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
13400 (Pre_Post_Aspects): New subtype.
13401 * par-ch12.adb (P_Generic): New syntax for aspects in packages
13402 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
13403 * par-ch7.adb (P_Package): Remove Decl parameter
13404 (P_Package): Handle new syntax for aspects (before IS)
13405 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
13406 new aspect syntax
13407 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
13408 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
13409 (P_Package): Remove Decl parameter
13410 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
13411 aspects
13412 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
13413 specs
13414 * sem_util.ads, sem_util.adb (Static_Boolean): New function
13415 * sinfo.ads: Document new syntax for aspects in packages etc.
13416 * sprint.adb: Handle new syntax of aspects before IS in package
13417
134182011-08-01 Thomas Quinot <quinot@adacore.com>
13419
13420 * atree.ads: Minor reformatting.
13421 * sem_prag.adb: Minor reformatting.
13422
134232011-08-01 Robert Dewar <dewar@adacore.com>
13424
13425 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
13426 case expr alternative.
13427
134282011-08-01 Ed Schonberg <schonberg@adacore.com>
13429
13430 * sem_ch12.adb: Fix typo.
13431
134322011-08-01 Geert Bosch <bosch@adacore.com>
13433
13434 * sem_prag.adb (Check_No_Link_Name): New procedure.
13435 (Process_Import_Or_Interface): Use Check_No_Link_Name.
13436 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
13437 instead of Standard_Long_Long_Float_Size global. Preparation for
13438 eventual removal of per type constants.
13439 * exp_util.ads (Get_Stream_Size): New function returning the stream
13440 size value of subtype E.
13441 * exp_util.adb (Get_Stream_Size): Implement new function.
13442 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
13443 function.
13444 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
13445 * einfo.adb:
13446 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
13447
134482011-08-01 Geert Bosch <bosch@adacore.com>
13449
13450 * cstand.adb: Fix comments.
13451 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
13452 count of arguments.
13453
134542011-08-01 Robert Dewar <dewar@adacore.com>
13455
13456 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
13457
134582011-08-01 Geert Bosch <bosch@adacore.com>
13459
13460 * atree.ads: Fix comment.
13461
134622011-08-01 Robert Dewar <dewar@adacore.com>
13463
13464 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
13465 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
13466 * par.adb: Add with for Namet.Sp.
13467 * par-tchk.adb: Minor reformatting.
13468
134692011-08-01 Vincent Celier <celier@adacore.com>
13470
13471 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
13472 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
13473 of the init procedure of a SAL.
13474 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
13475 New procedure.
13476
134772011-08-01 Thomas Quinot <quinot@adacore.com>
13478
13479 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
13480 reformatting.
13481
134822011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
13483
13484 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
13485
134862011-08-01 Thomas Quinot <quinot@adacore.com>
13487
13488 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
13489 conformant with its spec (return True only for types that have
13490 an overriding Initialize primitive operation that prevents them from
13491 having preelaborable initialization).
13492 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
13493 initialization for controlled types in Ada 2005 or later mode.
13494
134952011-08-01 Robert Dewar <dewar@adacore.com>
13496
13497 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
13498 Postcondition.
13499 (Same_Aspect): New function.
13500 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
13501 Type_Invariant, Precondition, Postcondition.
13502 * snames.ads-tmpl: Add Name_Type_Invariant.
13503
135042011-08-01 Robert Dewar <dewar@adacore.com>
13505
13506 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
13507 here.
13508 (Freeze_All_Ent): Fix error in handling inherited aspects.
13509 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
13510 already analyzed, but don't skip entire processing of a declaration,
13511 that's wrong in some cases of declarations being rewritten.
13512 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
13513 Don't delay for integer, string literals
13514 Treat predicates in usual manner for delay, remove special case code,
13515 not needed.
13516 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
13517 (Build_Predicate_Function): Update saved expression in aspect
13518 (Build_Invariant_Procedure): Update saved expression in aspect
13519 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
13520 of replacement of discriminant references if the reference is simple.
13521
135222011-08-01 Robert Dewar <dewar@adacore.com>
13523
13524 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
13525 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
13526 Static_Predicate and Dynamic_Predicate.
13527 (Build_Predicate_Function): Add processing for Static_Predicate
13528 and Dynamic_Predicate.
13529 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
13530 (From_Static_Predicate): New flag
13531 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
13532
135332011-08-01 Robert Dewar <dewar@adacore.com>
13534
13535 * usage.adb: Documentation cleanup for Ada version modes in usage.
13536 * expander.adb: Minor reformatting.
13537
135382011-08-01 Robert Dewar <dewar@adacore.com>
13539
13540 * atree.ads: Minor comment fix.
13541 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
13542 a-witeio.ads, sem_prag.adb: Minor reformatting.
13543
135442011-08-01 Doug Rupp <rupp@adacore.com>
13545
13546 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
13547 pointers. Use descrip.h header file for convenience. Add some
13548 comments.
13549
135502011-08-01 Robert Dewar <dewar@adacore.com>
13551
13552 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
13553 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
13554 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
13555 New procedure.
13556 (Check_Aspect_At_End_Of_Declarations): New procedure
13557 (Analye_Aspect_Specification): Minor changes for above procedures
13558 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
13559 specification node as well.
13560
135612011-08-01 Pascal Obry <obry@adacore.com>
13562
13563 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
13564 Windows files. Use GetFilesAttributes() in this case to check for file
13565 existence instead of returning with an error code.
13566
135672011-08-01 Vincent Celier <celier@adacore.com>
13568
13569 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
13570 High is above Source length.
13571
135722011-08-01 Robert Dewar <dewar@adacore.com>
13573
13574 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
13575
135762011-08-01 Robert Dewar <dewar@adacore.com>
13577
13578 * aspects.ads (Boolean_Aspects): New subtype.
13579 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
13580 for derived types in cases where the parent type and derived type have
13581 aspects.
13582 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
13583 with aspects when parent type also has aspects.
13584 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
13585 boolean expression at this point).
13586 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
13587 accordance with final decision on the Ada 2012 feature.
13588 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
13589
135902011-08-01 Matthew Heaney <heaney@adacore.com>
13591
13592 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
13593
135942011-08-01 Pascal Obry <obry@adacore.com>
13595
13596 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
13597 Fix Replace_Slice when High is above current string size.
13598 (Replace_Slice): Fix DL computation when High is above current
13599 string length.
13600
136012011-08-01 Gary Dismukes <dismukes@adacore.com>
13602
13603 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
13604
136052011-08-01 Matthew Heaney <heaney@adacore.com>
13606
13607 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
13608 of node.
13609
136102011-08-01 Pascal Obry <obry@adacore.com>
13611
13612 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
13613 reformatting.
13614
136152011-08-01 Ed Schonberg <schonberg@adacore.com>
13616
13617 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
13618 access to protected subprograms in generic bodies.
13619 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
13620 protected type, indicate that the convention of the subprogram is
13621 Convention_Protected, because it may be used in subsequent declarations
13622 within the protected declaration.
13623
136242011-08-01 Vincent Celier <celier@adacore.com>
13625
13626 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
13627 and "final" procedures when the name of the library is "ada", to avoid
13628 duplicate symbols "adainit" and "adafinal" in executables.
13629
136302011-08-01 Ed Schonberg <schonberg@adacore.com>
13631
13632 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
13633 quantified expression that appears within a postcondition and uses the
13634 Ada2012 'Result attribute.
13635
136362011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
13637
13638 * init.c (__gnat_error_handler): Cast reason to int.
13639 (__gnat_install_handler): Explain sa_sigaction use.
13640
136412011-07-24 Eric Botcazou <ebotcazou@adacore.com>
13642
13643 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
13644 subprogram has copy-in copy-out parameters, try to promote the mode of
13645 the return type if it is passed in registers.
13646
136472011-07-24 Eric Botcazou <ebotcazou@adacore.com>
13648
13649 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
13650 left operand as addressable.
13651
136522011-07-24 Eric Botcazou <ebotcazou@adacore.com>
13653
13654 * gcc-interface/gigi.h (build_function_stub): Remove.
13655 (build_return_expr): Likewise.
13656 (convert_vms_descriptor): Declare.
13657 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
13658 (build_function_stub): Move to...
13659 * gcc-interface/utils2.c (build_return_expr): Move to...
13660 * gcc-interface/trans.c (build_function_stub): ...here.
13661 (build_return_expr): ...here.
13662 (Subprogram_Body_to_gnu): Add local variable for language_function.
13663 Disconnect the parameter attributes cache, if any, once done with it.
13664 Call end_subprog_body only after setting the end_locus.
13665 Build the stub associated with the function, if any, at the very end.
13666 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
13667 variables and streamline control flow.
13668
136692011-07-23 Arnaud Charlet <charlet@adacore.com>
13670
13671 PR ada/49819
13672 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
13673 g-trasym-dwarf.adb.
13674
136752011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
13676
13677 PR bootstrap/49794
13678 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
13679 Assign to act.sa_sigaction.
13680 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
13681 current->return_address to char * before arithmetic.
13682
136832011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
13684
13685 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
13686 Correct argument types.
13687 Extract code from reason.
13688 (__gnat_install_handler): Assign to act.sa_sigaction.
13689
136902011-07-21 Eric Botcazou <ebotcazou@adacore.com>
13691
13692 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
13693 (GNAT1_OBJS): ...here.
13694
136952011-07-15 Eric Botcazou <ebotcazou@adacore.com>
13696
13697 PR ada/48711
13698 * g-socthi-mingw.adb (Fill): Fix formatting.
13699
13700 * gcc-interface/gigi.h: Move around comment.
13701
137022011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
13703
13704 PR ada/46350
13705 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
13706
137072011-07-14 Florian Weimer <fw@deneb.enyo.de>
13708
13709 PR ada/48711
13710 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
13711
137122011-07-13 Eric Botcazou <ebotcazou@adacore.com>
13713
13714 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
13715 range comparison if Pmode is SImode.
13716
137172011-07-12 Laurent GUERBY <laurent@guerby.net>
13718 Eric Botcazou <ebotcazou@adacore.com>
13719
13720 * adadecode.c: Wrap up in extern "C" block.
13721 * adadecode.h: Likewise.
13722 * adaint.c: Likewise. Remove 'const' keyword.
13723 * adaint.h: Likewise.
13724 * argv.c: Likewise.
13725 * atree.h: Likewise.
13726 * cio.c: Likewise.
13727 * cstreams.c: Likewise.
13728 * env.c: Likewise.
13729 * exit.c: Likewise.
13730 * fe.h: Likewise.
13731 * final.c: Likewise.
13732 * init.c: Likewise.
13733 * initialize.c: Likewise.
13734 * link.c: Likewise.
13735 * namet.h: Likewise.
13736 * nlists.h: Likewise.
13737 * raise.c: Likewise.
13738 * raise.h: Likewise.
13739 * repinfo.h: Likewise.
13740 * seh_init.c: Likewise.
13741 * targext.c: Likewise.
13742 * tracebak.c: Likewise.
13743 * uintp.h: Likewise.
13744 * urealp.h: Likewise.
13745 * xeinfo.adb: Wrap up generated C code in extern "C" block.
13746 * xsinfo.adb: Likewise.
13747 * xsnamest.adb: Likewise.
13748 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
13749 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
13750 * gcc-interface/misc.c: Likewise.
13751 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
13752 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
13753 ada/targext.o here...
13754 (GNAT_ADA_OBJS): ...and not here.
13755 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
13756 (GNATBIND_OBJS): Reorder.
13757
137582011-07-07 Richard Henderson <rth@redhat.com>
13759
13760 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
13761 dwarf2out_frame_init.
13762
137632011-07-07 Eric Botcazou <ebotcazou@adacore.com>
13764
13765 * gcc-interface/misc.c (gnat_init): Tweak previous change.
13766
137672011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
13768
13769 PR target/39150
13770 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
13771
137722011-07-06 Richard Guenther <rguenther@suse.de>
13773
13774 * gcc-interface/misc.c (gnat_init): Merge calls to
13775 build_common_tree_nodes and build_common_tree_nodes_2.
13776 Re-initialize boolean_false_node.
13777
137782011-07-02 Eric Botcazou <ebotcazou@adacore.com>
13779 Olivier Hainque <hainque@adacore.com>
13780 Nicolas Setton <setton@adacore.com>
13781
13782 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
13783 the type according to the ARTIFICIAL_P parameter.
13784 (create_type_decl): Likewise.
13785 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
13786
137872011-07-01 Eric Botcazou <ebotcazou@adacore.com>
13788
13789 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
13790 (gnatbind): Likewise.
13791
137922011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
13793
13794 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
13795
137962011-06-18 Eric Botcazou <ebotcazou@adacore.com>
13797
13798 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
13799 local variable throughout. Remove useless call to Base_Type.
13800 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
13801 Take it also into account for the volatileness of the field. Set the
13802 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
13803
138042011-06-18 Eric Botcazou <ebotcazou@adacore.com>
13805
13806 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
13807 on a dereference built for a by-ref object if it has an address clause.
13808
138092011-06-18 Eric Botcazou <ebotcazou@adacore.com>
13810
13811 * einfo.ads (Address_Taken): Document use for the second argument of
13812 Asm_Input and Asm_Output attributes.
13813 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
13814 argument is an entity name, then set Address_Taken on it.
13815 <Attribute_Asm_Output>: Likewise.
13816 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
13817 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
13818 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
13819 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
13820
138212011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
13822
13823 PR middle-end/46500
13824 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
13825
138262011-06-14 Joseph Myers <joseph@codesourcery.com>
13827
13828 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
13829 (ada/utils.o): Update dependencies.
13830 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
13831 ../../../libcpp/libcpp.a.
13832 * gcc-interface/utils.c: Include common/common-target.h.
13833 (process_attributes): Use targetm_common.have_named_sections.
13834
138352011-06-07 Richard Guenther <rguenther@suse.de>
13836
13837 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
13838 set_sizetype.
13839
138402011-06-06 Eric Botcazou <ebotcazou@adacore.com>
13841
13842 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
13843 TREE_THIS_NOTRAP flag.
13844
138452011-06-06 Eric Botcazou <ebotcazou@adacore.com>
13846
13847 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
13848 Fix thinko.
13849
138502011-06-06 Eric Botcazou <ebotcazou@adacore.com>
13851
13852 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
13853 constants whose full view has discriminants specially.
13854
138552011-06-06 Eric Botcazou <ebotcazou@adacore.com>
13856
13857 * gcc-interface/utils.c: Include diagnostic.h.
13858 (gnat_write_global_declarations): Output debug information for all
13859 global type declarations before finalizing the compilation unit.
13860 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
13861
138622011-05-25 Jakub Jelinek <jakub@redhat.com>
13863
13864 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
13865
138662011-05-25 Kai Tietz <ktietz@redhat.com>
13867
13868 * adaint.c (__gnat_to_canonical_file_list_next): Use array
13869 initialization instead of const/none-const pointer assignment.
13870
138712011-05-24 Joseph Myers <joseph@codesourcery.com>
13872
13873 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
13874 $(EXTRA_GNAT1_OBJS).
13875 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
13876 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
13877 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
13878 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
13879 libcommon-target.a instead of prefix.o.
13880
138812011-05-21 Joseph Myers <joseph@codesourcery.com>
13882
13883 PR ada/49097
13884 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
13885
138862011-05-20 Joseph Myers <joseph@codesourcery.com>
13887
13888 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
13889 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
13890 instead of version.o.
13891
2d0dd51a 138922011-05-18 Kai Tietz <ktietz@redhat.com>
052e0603
AC
13893
13894 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
13895 boolean_false_node instead of integer_zero_node.
13896 (convert_with_check): Likewise.
13897 * gcc-interface/decl.c (choices_to_gnu): Likewise.
13898
138992011-05-12 Eric Botcazou <ebotcazou@adacore.com>
13900
13901 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
13902 type of the parameter is an unconstrained array, convert the actual to
13903 the type of the formal in the In Out and Out cases as well.
13904
139052011-05-11 Nathan Froyd <froydnj@codesourcery.com>
13906
13907 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
13908 call build_function_type_array or build_varargs_function_type_array
13909 instead.
13910 (create_subprog_type): Don't call build_function_type; call
13911 build_function_type_vec instead.
13912
139132011-05-11 Nathan Froyd <froydnj@codesourcery.com>
13914
13915 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
13916 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
13917 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
13918
139192011-05-07 Eric Botcazou <ebotcazou@adacore.com>
13920
13921 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
13922
13923 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
13924 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
13925
139262011-05-05 Nathan Froyd <froydnj@codesourcery.com>
13927
13928 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
13929
139302011-05-05 Nathan Froyd <froydnj@codesourcery.com>
13931
13932 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
13933 instead of accessing TYPE_ARG_TYPES directly.
13934 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
13935
139362011-05-05 Eric Botcazou <ebotcazou@adacore.com>
13937
13938 PR ada/48844
13939 * gcc-interface/gigi.h (get_variant_part): Declare.
13940 * gcc-interface/decl.c (get_variant_part): Make global.
13941 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
13942 types have the same constant size, are record types and T1 has a
13943 variant part while T2 doesn't.
13944
139452011-05-05 Eric Botcazou <ebotcazou@adacore.com>
13946
13947 * gcc-interface/utils.c (begin_subprog_body): Do not call
13948 get_pending_sizes.
13949 (end_subprog_body): Likewise.
13950
139512011-05-04 Richard Guenther <rguenther@suse.de>
13952
13953 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
13954 int_const_binop.
13955 (pos_to_constructor): Likewise.
13956
139572011-05-03 Nathan Froyd <froydnj@codesourcery.com>
2c7f9cc0 13958 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
13959
13960 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
13961 of build_function_type. Adjust calls to...
13962 (build_raise_check): ...this. Do not take a void_tree parameter.
13963 Call build_function_type_list instead of build_function_type.
13964 Fix head comment and swap couple of conditional blocks.
13965
139662011-04-30 Eric Botcazou <ebotcazou@adacore.com>
13967
13968 * gnatvsn.ads (Library_Version): Bump to 4.7.
13969 (Current_Year): Bump to 2011.
13970
139712011-04-29 Michael Matz <matz@suse.de>
13972
13973 * gcc-interface/misc.c (gnat_handle_option): Set
13974 warn_maybe_uninitialized.
13975
139762011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
13977
13978 * gnat_ugn.texi (Complexity Metrics Control): Update link to
13979 the Watson/McCabe paper.
13980
139812011-04-23 Jim Meyering <meyering@redhat.com>
13982
13983 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
13984
139852011-04-22 Eric Botcazou <ebotcazou@adacore.com>
13986
13987 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
13988 onto the new type.
13989
139902011-04-22 Eric Botcazou <ebotcazou@adacore.com>
13991
13992 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
13993 parameter.
13994 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
13995 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
13996 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
13997 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
13998 <all>: Do not set flags on the reused DECL node coming from an alias.
13999 Set DECL_IGNORED_P on the DECL node built for subprograms if they
14000 don't need debug info here...
14001 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
14002 (gigi): Adjust calls to create_subprog_decl.
14003 (build_raise_check): Likewise.
14004 (establish_gnat_vms_condition_handler): Likewise.
14005 (Compilation_Unit_to_gnu): Likewise.
14006 (gnat_to_gnu): Likewise.
14007
140082011-04-21 Eric Botcazou <ebotcazou@adacore.com>
14009
14010 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
14011 (NO_REORDER_ADAFLAGS): New variable.
14012 (EXTRA_GNATTOOLS): Always define.
14013 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
14014 Clean up and adjust list of files compiled with special options.
14015 * gcc-interface/Make-lang.in: Likewise.
14016 (ada/decl.o): Cosmetical change.
14017 (ada/misc.o): Remove dependency on $(PLUGIN_H).
14018
140192011-04-20 Jim Meyering <meyering@redhat.com>
14020
14021 * initialize.c (__gnat_initialize): Remove useless if-before-free.
14022
140232011-04-17 Eric Botcazou <ebotcazou@adacore.com>
14024
14025 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
14026 $(CFLAGS) on the link line.
14027
140282011-04-17 Eric Botcazou <ebotcazou@adacore.com>
14029
14030 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
14031 padded type built for the return type if it is unconstrained.
14032
140332011-04-14 Nathan Froyd <froydnj@codesourcery.com>
14034
14035 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
14036
140372011-04-12 Nathan Froyd <froydnj@codesourcery.com>
14038
14039 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
14040 before calling TREE_CHAIN.
14041 * gcc-interface/misc.c (gnat_init_ts): New function.
14042 (LANG_HOOKS_INIT_TS): Define.
14043
140442011-04-12 Martin Jambor <mjambor@suse.cz>
14045
14046 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
14047 instead of cgraph_node.
14048
140492011-04-08 Eric Botcazou <ebotcazou@adacore.com>
14050
14051 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
14052 alignment on fields of the RETURN type built for the Copy-In Copy-Out
14053 mechanism.
14054
140552011-04-08 Eric Botcazou <ebotcazou@adacore.com>
14056
14057 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
14058 of aggregate types that contain a placeholder.
14059
140602011-04-08 Nathan Froyd <froydnj@codesourcery.com>
14061
14062 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
14063 TYPE_ARG_TYPES.
14064 (handle_type_generic_attribute): Likewise.
14065
140662011-04-04 Eric Botcazou <ebotcazou@adacore.com>
14067
14068 PR ada/47163
14069 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
14070
140712011-04-04 Kai Tietz <ktietz@redhat.com>
14072
14073 PR ada/47163
14074 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
14075 to flag value.
14076
140772011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14078
14079 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
14080 type case, do not strip a padding type around the array type.
14081
140822011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14083
14084 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
14085 types.
14086
140872011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14088
14089 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
14090 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
14091 code for -feliminate-unused-debug-types.
14092 (gnat_post_options): Likewise.
14093
140942011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14095
14096 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
14097 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
14098 distinct copy.
14099
141002011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14101
14102 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
14103 DECL_ARTIFICIAL flag on enumeration types.
14104
141052011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14106
14107 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
14108 fat pointer types artificial unconditionally.
14109 <E_Array_Subtype>: Attach the base array type as a parallel type if it
14110 isn't artificial.
14111
141122011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14113
14114 * gcc-interface/gigi.h (get_dummy_type): Declare.
14115 (build_dummy_unc_pointer_types): Likewise.
14116 (finish_fat_pointer_type): Likewise.
14117 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
14118 fat pointer type has been built, complete it in place.
14119 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
14120 and thin pointers. Remove useless variable.
14121 (finish_fat_pointer_type): Make global and move to...
14122 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
14123 (get_dummy_type): New function.
14124 (build_dummy_unc_pointer_types): Likewise.
14125 (gnat_pushdecl): Propage the name to the anonymous variants only.
14126 (update_pointer_to): Only adjust the pointer types in the unconstrained
14127 array case.
14128
141292011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14130
14131 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
14132 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
14133 if this is a Taft amendment type and the full declaration is available.
14134 * gcc-interface/trans.c (process_type): Likewise.
14135 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
14136 (process_freeze_entity): Likewise.
14137 * gcc-interface/utils.c (dummy_global): New static variable.
14138 (gnat_write_global_declarations): If there are types declared as used
14139 at the global level, insert them in the global hash table.
14140
141412011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14142
14143 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
14144 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
14145 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
14146 copy.
14147 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
14148 flag of the type accordingly.
14149 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
14150
141512011-04-02 Eric Botcazou <ebotcazou@adacore.com>
14152
14153 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
14154 finalizing types when updating the pointers to the designated type.
14155 <all>: Finalize the deferred types even if we didn't defer processing
14156 of incomplete types in this invocation.
14157
141582011-04-01 Olivier Hainque <hainque@adacore.com>
2c7f9cc0
AS
14159 Nicolas Setton <setton@adacore.com>
14160 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
14161
14162 * gcc-interface/misc.c (gnat_descriptive_type): New function.
14163 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
14164
141652011-03-28 Kai Tietz <ktietz@redhat.com>
14166
14167 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
14168 Windows targets.
14169 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
14170 * system-mingw.ads (System): Change ZCX_By_Default default to True.
14171
14172 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
14173
141742011-03-28 Tristan Gingold <gingold@adacore.com>
14175
14176 PR ada/44431
14177 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
14178 Use ada output of gnatbind.
14179 (ada/b_gnatb.adb): Ditto.
14180 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
14181 (ada.mostlyclean, ada.stage1)
14182 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
14183 (ada.stagefeedback): Adjust.
14184 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
14185 Use ada output of gnatbind.
14186 (b_gnatm.adb): Ditto.
14187 (b_gnatl.o, b_gnatm.o): New rules.
14188
141892011-03-26 Eric Botcazou <ebotcazou@adacore.com>
14190
14191 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
14192 for the padded type built to support a specified size or alignment.
14193
141942011-03-26 Eric Botcazou <ebotcazou@adacore.com>
14195
14196 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
14197 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
14198 unconditionally to the end of the unit when the designated type is
14199 limited_with'ed.
14200 <all>: Rename local variable. Attempt to un-defer types only and do it
14201 for limited_with'ed types as well.
14202 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
14203 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
14204 consistently and remove redundant call to finalize_from_with_types.
14205
142062011-03-26 Eric Botcazou <ebotcazou@adacore.com>
14207
14208 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
14209 subprograms without a previous spec declared in the same unit.
14210 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
14211 subprograms at the end of the unit instead of at the beginning.
14212 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
14213 isn't public for the special handling of non-inline functions nested
14214 inside inline external functions.
14215
142162011-03-25 Jeff Law <law@redhat.com>
14217
14218 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
14219
142202011-03-24 Eric Botcazou <ebotcazou@adacore.com>
14221
14222 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
14223 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
14224 to compute Set_Size_Depends_On_Discriminant.
14225 (Layout_Type): Call it on array types in back-end layout mode.
14226 * sem_util.adb (Requires_Transient_Scope): Return true for array
14227 types only if the size depends on the value of discriminants.
14228 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
14229 type if the RHS is a call to a function that returns an unconstrained
14230 type with default discriminant.
14231
142322011-03-24 Eric Botcazou <ebotcazou@adacore.com>
14233
14234 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
14235 non-conversion to the nominal result type at the end.
14236
142372011-03-23 Eric Botcazou <ebotcazou@adacore.com>
14238
14239 * gcc-interface/trans.c (create_temporary): New function taken from...
14240 (create_init_temporary): ...here. Call it.
14241 (call_to_gnu): Create the temporary for the return value early, if any.
14242 Create it for a function with copy-in/copy-out parameters if there is
14243 no target; in other cases of copy-in/copy-out, use another temporary.
14244 Push the new binding level lazily. Add and rename local variables.
14245
142462011-03-23 Eric Botcazou <ebotcazou@adacore.com>
14247
14248 * gcc-interface/decl.c (validate_size): Improve comments and tweak
14249 error message.
14250 (set_rm_size): Likewise.
14251
142522011-03-23 Eric Botcazou <ebotcazou@adacore.com>
14253
14254 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
14255 for the padded type built in order to support a specified alignment.
14256 Fix incorrect formatting.
14257
142582011-03-21 Eric Botcazou <ebotcazou@adacore.com>
14259
14260 PR bootstrap/48216
14261 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
14262
142632011-03-21 Eric Botcazou <ebotcazou@adacore.com>
14264
14265 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
14266 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
14267 to the end of the list. Adjust recursive call. Rename local variable.
14268 If REORDER is true, reorder components of the record type.
14269 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
14270 components_to_record and adjust the parameter list.
14271
142722011-03-21 Eric Botcazou <ebotcazou@adacore.com>
14273
14274 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
14275 disabled, use the variable for bounds of loop iteration scheme.
14276
142772011-03-21 Kai Tietz <ktietz@redhat.com>
14278
14279 PR target/12171
14280 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
14281
142822011-03-17 Eric Botcazou <ebotcazou@adacore.com>
14283
14284 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
14285 out whether the expression is read-only. Short-circuit placeholder
14286 case and rename a couple of local variables.
14287
142882011-03-17 Eric Botcazou <ebotcazou@adacore.com>
14289
14290 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
14291 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
14292 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
14293 (convert): Deal with conversions from a smaller form type specially.
14294
142952011-02-14 Eric Botcazou <ebotcazou@adacore.com>
14296
14297 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
14298 its argument, except for the special -I- switch.
14299
143002011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
14301
14302 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
14303 "Ada Issues".
14304
143052011-02-08 Eric Botcazou <ebotcazou@adacore.com>
14306
14307 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
14308
143092011-02-03 Eric Botcazou <ebotcazou@adacore.com>
14310
14311 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
14312 GNAT_FORMAL.
14313 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
14314 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
14315 instead of GNAT_FORMAL. Protect the expression against multiple uses.
14316 Do not generate the check directly, instead instantiate the template
14317 check present in the descriptor.
14318 (make_descriptor_field): Move around.
14319 (build_vms_descriptor32): Build a template check in the POINTER field.
14320 (build_vms_descriptor): Remove useless suffixes.
14321 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
14322
143232011-01-26 Eric Botcazou <ebotcazou@adacore.com>
14324
14325 PR bootstrap/47467
14326 * targext.c: Include target files if IN_RTS is defined.
14327
143282011-01-26 Richard Guenther <rguenther@suse.de>
14329
14330 PR bootstrap/47467
14331 * targext.c: Include config.h.
14332 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
14333 dependency.
14334
143352011-01-04 Pascal Obry <obry@adacore.com>
2c7f9cc0 14336 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
14337
14338 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
14339
143402011-01-04 Eric Botcazou <ebotcazou@adacore.com>
14341
14342 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
14343 end-of-case on the end label and its associated gotos, if any.
14344
143452011-01-04 Eric Botcazou <ebotcazou@adacore.com>
14346
14347 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
14348 expressions of the parameter cache within the statement group of
14349 the CICO mechanism.
14350
143512011-01-04 Olivier Hainque <hainque@adacore.com>
2c7f9cc0 14352 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
14353
14354 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
14355 (set_end_locus_from_node): New function.
14356 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
14357 make and the function end_locus.
14358 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
14359 for the elaboration subprogram.
14360 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
14361 set the end_locus of the expression as well.
14362
143632011-01-04 Eric Botcazou <ebotcazou@adacore.com>
14364
14365 PR ada/47131
14366 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
14367 variables that are referenced in exception handlers volatile.
14368
14369
14370\f
14371Copyright (C) 2011 Free Software Foundation, Inc.
14372
14373Copying and distribution of this file, with or without modification,
14374are permitted in any medium without royalty provided the copyright
14375notice and this notice are preserved.
14376
14377 * gnat_rm.texi: Ramification of pragma Eliminate documentation
14378 - fix bugs in the description of Source_Trace;
14379 - get rid of UNIT_NAME;
14380
4fbad0ba
AC
143812011-08-02 Javier Miranda <miranda@adacore.com>
14382
14383 * exp_ch9.adb
14384 (Build_Dispatching_Requeue): Adding support for VM targets
14385 since we cannot directly reference the Tag entity.
14386 * exp_sel.adb (Build_K): Adding support for VM targets.
14387 (Build_S_Assignment): Adding support for VM targets.
14388 * exp_disp.adb
14389 (Default_Prim_Op_Position): In VM targets do not restrict availability
14390 of predefined interface primitives to compiling in Ada 2005 mode.
14391 (Is_Predefined_Interface_Primitive): In VM targets this service is not
14392 restricted to compiling in Ada 2005 mode.
14393 (Make_VM_TSD): Generate code that declares and initializes the OSD
14394 record. Needed to support dispatching calls through synchronized
14395 interfaces.
14396 * exp_ch3.adb
14397 (Make_Predefined_Primitive_Specs): Enable generation of predefined
14398 primitives associated with synchronized interfaces.
14399 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
14400 primitives associated with synchronized interfaces.
14401
144022011-08-02 Yannick Moy <moy@adacore.com>
14403
14404 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
14405 statements hidden in SPARK if preceded by the HIDE directive
14406 (Parse_Exception_Handlers): mark each exception handler in a sequence of
14407 exception handlers as hidden in SPARK if preceded by the HIDE directive
14408 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
14409 if starting with the HIDE directive
14410 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
14411 starting with the HIDE directive; mark the declarations in a private
14412 part as hidden in SPARK if the private part starts with the HIDE
14413 directive
14414 * restrict.adb, restrict.ads
14415 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
14416 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
14417 argument node belongs to a part which is hidden in SPARK
14418 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
14419 parts in SPARK; protect the possibly costly call to
14420 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
14421 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
14422 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
14423 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
14424 Tok_SPARK_Hide.
14425 (Scan): recognize special comment starting with '#' and followed by
14426 SPARK keyword "hide" as a HIDE directive.
14427
144282011-08-02 Yannick Moy <moy@adacore.com>
14429
14430 * types.ads, erroutc.ads: Minor reformatting.
14431
144322011-08-02 Vincent Celier <celier@adacore.com>
14433
14434 * link.c: Add response file support for cross platforms.
14435
6ff6152d
ES
144362011-08-02 Ed Schonberg <schonberg@adacore.com>
14437
14438 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
14439 in an association, set parent field of copy before partial analysis.
14440 * sem_res.adb (Resolve_Slice): create reference to itype only when
14441 expansion is enabled.
14442
975c6896
YM
144432011-08-02 Yannick Moy <moy@adacore.com>
14444
14445 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
14446 for new flag denoting which subprogram bodies are in ALFA
14447 * restrict.adb, sem_ch7.adb: Update comment
14448 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
14449 sem_ch9.adb, sem_res.adb: Add calls to
14450 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
14451 * sem_ch6.adb (Analyze_Function_Return): add calls to
14452 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
14453 middle of the body, and extended return.
14454 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
14455 False when missing return.
14456 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
14457 to True for subprograms whose spec is in ALFA. Remove later on the flag
14458 on the entity used for a subprogram body when there exists a separate
14459 declaration.
14460 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
14461 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
14462 False, otherwise do nothing.
14463
afc8324d
AC
144642011-08-02 Robert Dewar <dewar@adacore.com>
14465
14466 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
14467
144682011-08-02 Yannick Moy <moy@adacore.com>
14469
14470 * sem_ch4.ads: minor formatting.
14471
2ba431e5
YM
144722011-08-02 Yannick Moy <moy@adacore.com>
14473
14474 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
14475 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
14476 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
14477 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
14478 opt.ads: cleanup of SPARK mode
14479
0f853035
YM
144802011-08-02 Yannick Moy <moy@adacore.com>
14481
14482 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
14483 types.
14484 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
14485 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
14486 * sem_ch3.adb
14487 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
14488 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
14489 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
14490 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
14491 types.
14492 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
14493 non-static range.
14494 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
14495 functions whose return type is not in ALFA.
14496 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
14497 specifications.
14498 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
14499 parameter's type is not in ALFA.
14500 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
14501 types are in ALFA.
14502
d2b10647
ES
145032011-08-02 Ed Schonberg <schonberg@adacore.com>
14504
14505 * sem_ch6 (Analyze_Expression_Function): treat the function as
14506 Inline_Always, and introduce a subprogram declaration for it when it is
14507 not a completion.
14508 * inline.adb (Add_Inlined_Body): recognize bodies that come from
14509 expression functions, so that the back-end can determine whether they
14510 can in fact be inlined.
14511 * sem_util.adb (Is_Expression_Function): predicate to determine whether
14512 a function body comes from an expression function.
14513
c7b9d548
AC
145142011-08-02 Gary Dismukes <dismukes@adacore.com>
14515
14516 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
14517 null exclusions to test Can_Never_Be_Null on the anonymous access types
14518 of the formals rather than testing the formals themselves. Exclude this
14519 check in cases where the Old_Formal is marked as a controlling formal,
14520 to avoid issuing spurious errors for bodies completing dispatching
14521 operations (due to the flag not getting set on controlling access
14522 formals in body specs).
14523 (Find_Corresponding_Spec): When checking full and subtype conformance of
14524 subprogram bodies in instances, pass Designated and E in that order, for
14525 consistency with the expected order of the formals (New_Id followed by
14526 Old_Id).
14527
145282011-08-02 Robert Dewar <dewar@adacore.com>
14529
14530 * sem_ch8.adb: Minor reformatting.
14531
1138cf59
AC
145322011-08-02 Ed Schonberg <schonberg@adacore.com>
14533
14534 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
14535 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
14536 primitive operations of class-wide actuals.
14537
145382011-08-02 Javier Miranda <miranda@adacore.com>
14539
14540 * exp_atag.ads, exp_atag.adb
14541 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
14542 since its value is implicitly passed in argument Typ.
14543 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
14544 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
14545 Build_Common_Dispatching_Select_Statements.
14546
7b9db926
RD
145472011-08-02 Robert Dewar <dewar@adacore.com>
14548
14549 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
14550 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
14551 Minor reformatting.
14552
e8374e7a
AC
145532011-08-02 Robert Dewar <dewar@adacore.com>
14554
14555 * sem_res.adb: Minor reformatting.
14556 * sem_prag.adb: Minor reformatting.
14557
145582011-08-02 Javier Miranda <miranda@adacore.com>
14559
14560 * exp_atag.adb, exp_atags.ads
14561 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
14562 by the tagged type Entity. Required to use this routine in the VM
14563 targets since we do not have available the Tag entity in the VM
14564 platforms.
14565 * exp_ch6.adb
14566 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
14567 Ada.Tags has not been previously loaded.
14568 * exp_ch7.adb
14569 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
14570 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
14571 * sem_aux.adb
14572 (Enclosing_Dynamic_Scope): Add missing support to handle the full
14573 view of enclosing scopes. Required to handle enclosing scopes that
14574 are synchronized types whose full view is a task type.
14575 * exp_disp.adb
14576 (Build_VM_TSDs): Minor code improvement to avoid generating and
14577 analyzing lists with empty nodes.
14578 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
14579 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
14580 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
14581 (Make_Disp_Timed_Select_Body): Add support for VM targets.
14582 (Make_Select_Specific_Data_Table): Add support for VM targets.
14583 (Make_VM_TSD): Generate code to initialize the SSD structure of
14584 the TSD.
14585
145862011-08-02 Yannick Moy <moy@adacore.com>
14587
14588 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
14589 cross-references section in ALI.
14590 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
14591 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
14592 Sub).
14593 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
14594 subprogram or package entity of a node
14595 (Is_Local_Reference_Type): new function returns True for references
14596 selected in local cross-references.
14597 (Lt): function extracted from Lt in Output_References
14598 (Write_Entity_Name): function extracted from Output_References
14599 (Generate_Definition): generate reference with type 'D' for definition
14600 of objects (object declaration and parameter specification), with
14601 appropriate locations and units, for use in local cross-references.
14602 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
14603 references of type 'I' for initialization in object definition.
14604 (Output_References): move part of function Lt and procedure
14605 Write_Entity_Name outside of the body. Ignore references of types 'D'
14606 and 'I' introduced for local cross-references.
14607 (Output_Local_References): new procedure to output the local
14608 cross-references sections.
14609 (Lref_Entity_Status): new array defining whether an entity is a local
14610 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
14611 with 'I' type when initialization expression is present.
14612 * get_scos.adb, get_scos.ads: Correct comments and typos
14613
1f6439e3
AC
146142011-08-02 Javier Miranda <miranda@adacore.com>
14615
14616 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
14617 the JVM target.
14618 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
14619 the JVM target.
14620 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
14621 TSD support.
14622
146232011-08-02 Vincent Celier <celier@adacore.com>
14624
14625 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
14626 (No_Space_Img): New function
14627 (Find_Excluded_Sources): When reading from a file, record the file name
14628 and the line number for each excluded source.
14629 (Mark_Excluded_Sources): When reporting an error, if the excluded
14630 sources were read from a file, include file name and line number in
14631 the error message.
14632
146332011-08-02 Ed Schonberg <schonberg@adacore.com>
14634
14635 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
14636
ab027d28
RD
146372011-08-02 Robert Dewar <dewar@adacore.com>
14638
14639 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
14640
b3b28b0c
JM
146412011-08-02 Javier Miranda <miranda@adacore.com>
14642
14643 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
14644 generation of TSDs to the DOTNET compiler.
14645 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
14646 generation of TSDs to the DOTNET compiler.
14647
9732e886
JM
146482011-08-02 Javier Miranda <miranda@adacore.com>
14649
14650 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
14651 record of all the tagged types declared inside library level package
14652 declarations, library level package bodies or library level subprograms.
14653 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
14654 associated with a given tagged type.
14655 (Build_VM_TSDs): New subprogram.
14656 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
14657 compilation units that are subprograms.
14658 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
14659 compilation units that are package bodies.
14660 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
14661 units that are a package declaration or a package instantiation.
14662 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
14663 reorganization to improve the error generated by the frontend when the
14664 function Ada.Tags.Secondary_Tag is not available.
14665 * rtsfind.ads (RE_Register_TSD): New runtime entity.
14666 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
14667
e526d0c7
AC
146682011-08-02 Javier Miranda <miranda@adacore.com>
14669
14670 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
14671
146722011-08-02 Robert Dewar <dewar@adacore.com>
14673
14674 * s-imenne.ads: Minor reformatting.
14675
146762011-08-02 Robert Dewar <dewar@adacore.com>
14677
14678 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
14679 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
14680 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
14681
146822011-08-02 Robert Dewar <dewar@adacore.com>
14683
14684 * einfo.ads (Materialize_Entity): Document this is only for renamings
14685 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
14686 required debug information in the case where we transform the object
14687 declaration into a renaming declaration.
14688 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
14689 object
14690 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
14691 Materialize_Entity.
14692
5b1e6aca
RD
146932011-08-02 Robert Dewar <dewar@adacore.com>
14694
14695 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
14696 Suppress_Init_Procs.
14697 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
14698 Suppress_Initialization/Initialization_Suppressed.
14699 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
14700 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
14701 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
14702 * sem_prag.adb: New processing for pragma Suppress_Initialization.
14703
5ad4969d
RD
147042011-08-02 Robert Dewar <dewar@adacore.com>
14705
14706 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
14707 Minor reformatting.
14708
8c4ee6f5
AC
147092011-08-02 Ed Schonberg <schonberg@adacore.com>
14710
14711 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
14712 only have inheritable classwide pre/postconditions.
14713
147142011-08-02 Javier Miranda <miranda@adacore.com>
14715
14716 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
14717 * rtsfind.ads (RE_Check_TSD): New runtime entity.
14718 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
14719 checks if the external tag of a type is the same as the external tag
14720 of some other declaration.
14721
0b3d16c0
AC
147222011-08-02 Thomas Quinot <quinot@adacore.com>
14723
14724 * s-taskin.ads: Minor reformatting.
14725
147262011-08-02 Emmanuel Briot <briot@adacore.com>
14727
14728 * g-comlin.adb (Display_Help): swap the order in which it prints the
14729 short help and the general usage.
14730
147312011-08-02 Ed Schonberg <schonberg@adacore.com>
14732
14733 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
14734 the aspect declarations and attach them to the generic copy for
14735 subsequent analysis.
14736 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
14737 declarations of the generic tree to the new subprogram declarations.
14738 * sem_attr.adb (Check_Precondition_Postcondition): recognize
14739 conditions that apply to a subprogram instance.
14740
147412011-08-02 Robert Dewar <dewar@adacore.com>
14742
14743 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
14744
147452011-08-02 Ed Schonberg <schonberg@adacore.com>
14746
14747 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
14748 private type with a tagged full view is not derived in the immediate
14749 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
14750
4637729f
AC
147512011-08-02 Robert Dewar <dewar@adacore.com>
14752
14753 * exp_ch4.adb: Minor reformatting.
14754
147552011-08-02 Ed Schonberg <schonberg@adacore.com>
14756
14757 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
14758 Ada2012 iterator, the loop will be rewritten during expansion into a
14759 while loop with a cursor and an element declaration. Do not analyze the
14760 body in this case, because if the container is for indefinite types the
14761 actual subtype of the elements will only be determined when the cursor
14762 declaration is analyzed.
14763
147642011-08-02 Arnaud Charlet <charlet@adacore.com>
14765
14766 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
14767 size/alignment related attributes in CodePeer_Mode.
14768
147692011-08-02 Gary Dismukes <dismukes@adacore.com>
14770
14771 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
14772 Prepend_Element, since this can result in the operation getting the
14773 wrong slot in the full type's dispatch table if the full type has
14774 inherited operations. The incomplete type's operation will get added
14775 to the proper position in the full type's primitives
14776 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
14777 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
14778 dispatching operations, since there are cases where nonprimitive
14779 subprograms can get added to the list of incomplete dependents (such
14780 as subprograms in nested packages).
14781 * sem_ch6.adb (Process_Formals): First, remove test for being in a
14782 private part when determining whether to add a primitive with a
14783 parameter of a tagged incomplete type to the Private_Dependents list.
14784 Such primitives can also occur in the visible part, and should not have
14785 been excluded from being private dependents.
14786 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
14787 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
14788 list of a Taft-amendment incomplete type is a primitive before issuing
14789 an error that the full type must appear in the same unit. There are
14790 cases where nonprimitives can be in the list (such as subprograms in
14791 nested packages).
14792 * sem_disp.adb (Derives_From): Use correct condition for checking that
14793 a formal's type is derived from the type of the corresponding formal in
14794 the parent subprogram (the condition was completely wrong). Add
14795 checking that was missing for controlling result types being derived
14796 from the result type of the parent operation.
14797
4c60de0c
YM
147982011-08-02 Yannick Moy <moy@adacore.com>
14799
14800 * errout.adb (First_Node): minor renaming
14801 * restrict.adb (Check_Formal_Restriction): put restriction warning on
14802 first node.
14803
f5afb270
AC
148042011-08-02 Yannick Moy <moy@adacore.com>
14805
14806 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
14807 before accessing operands.
14808 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
14809 decide whether an initialization expression respects SPARK rules, as
14810 the plain node is the expanded one. This allows for more valid warnings
14811 to be issued.
14812 * gnat_rm.texi: Minor update.
14813
148142011-08-02 Arnaud Charlet <charlet@adacore.com>
14815
14816 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
14817 previous change.
14818
148192011-08-02 Robert Dewar <dewar@adacore.com>
14820
14821 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
14822
148232011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
14824
14825 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
14826 loop statements and the element renaming declaration with a block when
14827 the element type is controlled.
14828
148292011-08-02 Yannick Moy <moy@adacore.com>
14830
14831 * sinfo.ads: Minor formatting.
14832
148332011-08-02 Ed Schonberg <schonberg@adacore.com>
14834
14835 * sem_aggr.adb (Add_Association): if the association has a box and no
14836 expression, use the Sloc of the aggregate itself for the new
14837 association.
14838 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
14839 the Original_Node.
14840
db72f10a
AC
148412011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
14842
14843 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
14844 When a container is provided via a function call, generate a renaming
14845 of the function result. This avoids the creation of a transient scope
14846 and the premature finalization of the container.
14847 * exp_ch7.adb (Is_Container_Cursor): Removed.
14848 (Wrap_Transient_Declaration): Remove the supression of the finalization
14849 of the list controller when the declaration denotes a container cursor,
14850 it is not needed.
14851
148522011-08-02 Yannick Moy <moy@adacore.com>
14853
14854 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
14855 node is from source, instead of the original node being from source.
14856 * sem_aggr.adb
14857 (Resolve_Array_Aggregate): refine the check for a static expression, to
14858 recognize also static ranges
14859 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
14860 Array_Type_Declaration): postpone the test for the type being a subtype
14861 mark after the type has been resolved, so that component-selection and
14862 expanded-name are discriminated.
14863 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
14864 to distinguish the case of an iteration scheme, so that an error is
14865 issed on a non-static range in SPARK except in an iteration scheme.
14866 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
14867 In_Iter_Schm = True.
14868 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
14869 user-defined operators so that they are allowed in renaming
14870 * sem_ch8.adb
14871 (Find_Selected_Component): refine the check for prefixing of operators
14872 so that they are allowed in renaming. Move the checks for restrictions
14873 on selector name after analysis discriminated between
14874 component-selection and expanded-name.
14875 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
14876 concatenation argument of string type if it is static.
14877 * sem_util.adb, sem_util.ads
14878 (Check_Later_Vs_Basic_Declarations): add a new function
14879 Is_Later_Declarative_Item to decice which declarations are allowed as
14880 later items, in the two different modes Ada 83 and SPARK. In the SPARK
14881 mode, add that renamings are considered as later items.
14882 (Enclosing_Package): new function to return the enclosing package
14883 (Enter_Name): correct the rule for homonyms in SPARK
14884 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
14885 from source (result of expansion) to avoid issuing wrong warnings.
14886
148872011-08-02 Ed Schonberg <schonberg@adacore.com>
14888
14889 * errout.adb: On anything but an expression First_Node returns its
14890 argument.
14891
23685ae6
AC
148922011-08-02 Pascal Obry <obry@adacore.com>
14893
14894 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
14895
148962011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
14897
14898 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
14899 Set the associated loop as the related expression of internally
14900 generated cursors.
14901 * exp_ch7.adb (Is_Container_Cursor): New routine.
14902 (Wrap_Transient_Declaration): Supress the finalization of the list
14903 controller when the declaration denotes a container cursor.
14904
149052011-08-02 Yannick Moy <moy@adacore.com>
14906
14907 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
14908 command line now.
14909 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
14910 expression is a simple expression. This check cannot be performed in
14911 the semantics, so just drop it.
14912 (P_Index_Or_Discriminant_Constraint): move check that the index or
14913 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
14914 semantics. Other cases were previously checked in the semantics.
14915 * par-ch4.adb (P_Name): move checks that a selector name is not
14916 character literal or an operator symbol to Find_Selected_Component in
14917 the semantics
14918 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
14919 declarations are not placed after later declarations in a separate
14920 procedure in Sem_Util (possibly not the best choice?), to be used both
14921 during parsing, for Ada 83 mode, and during semantic analysis, for
14922 SPARK mode.
14923 * par-endh.adb (Check_End): move check that end label is not missing
14924 to Process_End_Label in the semantics
14925 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
14926 the special case for SPARK restriction
14927 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
14928 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
14929 parameter Force to issue the error message even on internal node (used
14930 for generated end label). Call Check_Restriction to check when an error
14931 must be issued. In SPARK mode, issue an error message even if the
14932 restriction is not set.
14933 (Check_Restriction): new procedure with an additional out parameter to
14934 inform the caller that a message has been issued
14935 * sem_aggr.adb: Minor modification of message
14936 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
14937 instead of issuing an error message directly
14938 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
14939 declarations are not placed after later declarations, by calling
14940 Check_Later_Vs_Basic_Declarations
14941 (Analyze_Subtype_Declaration): move here the check that an index or
14942 discriminant constraint must be a subtype mark. Change the check that
14943 a subtype of String must start at one so that it works on subtype marks.
14944 * sem_ch4.adb (Analyze_Call): move here the check that a named
14945 association cannot follow a positional one in a call
14946 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
14947 instead of issuing an error message directly
14948 * sem_ch8.adb (Find_Selected_Component): move here the check that a
14949 selector name is not a character literal or an operator symbol. Move
14950 here the check that the prefix of an expanded name cannot be a
14951 subprogram or a loop statement.
14952 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
14953 procedure called from parsing and semantics to check that basic
14954 declarations are not placed after later declarations
14955 (Process_End_Label): move here the check that end label is not missing
14956
149572011-08-02 Arnaud Charlet <charlet@adacore.com>
14958
14959 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
14960 representation clause in codepeer mode, since it confuses CodePeer and
14961 does not bring useful info.
14962
149632011-08-02 Ed Falis <falis@adacore.com>
14964
14965 * init.c: initialize fp hw on MILS.
14966
149672011-08-02 Ed Schonberg <schonberg@adacore.com>
14968
14969 * errout.adb (First_Node): for bodies, return the node itself (small
14970 optimization). For other nodes, do not check source_unit if the node
14971 comes from Standard.
14972
d2d9cc22
AC
149732011-08-02 Robert Dewar <dewar@adacore.com>
14974
14975 * exp_ch3.adb: Minor comment additions.
14976 * sem_ch13.adb: Minor reformatting.
14977
149782011-08-02 Pascal Obry <obry@adacore.com>
14979
14980 * make.adb, makeutl.adb: Removes some superfluous directory separator.
14981
a01b9df6
AC
149822011-08-02 Robert Dewar <dewar@adacore.com>
14983
14984 * sem_attr.adb: Minor reformatting.
14985
149862011-08-02 Robert Dewar <dewar@adacore.com>
14987
14988 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
14989 (Has_Default_Component_Value): Removed
14990 * einfo.ads Comment updates
14991 (Has_Default_Aspect): Replaces Has_Default_Value
14992 (Has_Default_Component_Value): Removed
14993 * exp_ch13.adb
14994 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
14995 * exp_ch3.adb
14996 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
14997 (Get_Simple_Init_Val): Handle Default_Value aspect
14998 (Needs_Simple_Initialization): Handle Default_Value aspect
14999 * exp_ch3.ads: Needs_Simple_Initialization
15000 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
15001 * par-prag.adb (Pragma_Default[_Component]Value) Removed
15002 * sem_ch13.adb
15003 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
15004 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
15005 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
15006
150072011-08-02 Ed Schonberg <schonberg@adacore.com>
15008
15009 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
15010 package containing iteration primitives.
15011 exp_ch5.adb (Expand_Iterator_Loop): ditto.
15012
75c90775
AC
150132011-08-02 Ed Schonberg <schonberg@adacore.com>
15014
15015 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
15016 "of", pre-analyze expression in case it is a function call with
15017 finalization actions that must be placed ahead of the loop.
15018 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
15019 on an Ada2012 iterator, insert them ahead of the rewritten loop.
15020
150212011-08-02 Geert Bosch <bosch@adacore.com>
15022
15023 * cstand.adb (Create_Float_Types): Only consider C's long double for
15024 Long_Long_Float, in addition to double.
15025
ded8909b
AC
150262011-08-02 Robert Dewar <dewar@adacore.com>
15027
15028 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
15029 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
15030 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
15031 Minor reformatting.
15032
150332011-08-02 Ed Schonberg <schonberg@adacore.com>
15034
15035 * sem_attr.adb: handle properly 'Result when it is a prefix of an
15036 indexed component.
15037
150382011-08-02 Javier Miranda <miranda@adacore.com>
15039
15040 * einfo.ads, einfo.adb
15041 (Original_Access_Type): Move this attribute to Node26 since there was
15042 an undocumented use of Node21 in E_Access_Subprogram_Type entities
15043 which causes conflicts and breaks the generation of the .NET compiler.
15044 (Interface_Name): Add missing documentation on JGNAT only uses of
15045 this attribute.
15046
70c34e1c
AC
150472011-08-02 Geert Bosch <bosch@adacore.com>
15048
15049 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
15050 (Find_Back_End_Float_Type): Likewise
15051 (Create_Back_End_Float_Types): Likewise
15052 (Create_Float_Types): Likewise
15053 (Register_Float_Type): Likewise
15054 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
15055 Nlist and split out type selection in new local Find_Base_Type function.
15056 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
15057 Nlist
15058 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
15059
150602011-08-02 Robert Dewar <dewar@adacore.com>
15061
15062 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
15063 alpha order).
15064 * opt.ads: Minor comment change.
15065 * sem_ch12.adb: Minor code reorganization.
15066
b715bc59
AC
150672011-08-02 Gary Dismukes <dismukes@adacore.com>
15068
15069 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
15070 subtype's list of rep items to the list on the full subtype in the case
15071 where the lists are the same.
15072
150732011-08-02 Geert Bosch <bosch@adacore.com>
15074
15075 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
15076 using the one from System.Strings, which also deallocates all strings.
15077
002bdd68
AC
150782011-08-02 Geert Bosch <bosch@adacore.com>
15079
15080 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
15081 function.
15082 * gcc-interface/Make-lang.in: Update dependencies.
15083
150842011-08-02 Olivier Hainque <hainque@adacore.com>
15085
15086 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
15087 end_locus.
15088
499769ec
AC
150892011-08-02 Javier Miranda <miranda@adacore.com>
15090
15091 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
15092 associated with anonymous access to subprograms.
15093
150942011-08-02 Geert Bosch <bosch@adacore.com>
15095
15096 * opt.ads
15097 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
15098 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
15099 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
15100 (Add_Symbol_Definition): Move to switch-c.adb
15101 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
15102 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
15103 (Add_Symbol_Definition): Move to switch-c.adb.
15104 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
15105 * sem_warn.adb
15106 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
15107 Move to warnsw.adb.
15108 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
15109 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
15110 Move to warnsw.adb.
15111 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
15112 (Add_Symbol_Definition): Moved from Prepcomp.
15113 * switch-c.ads: Update copyright notice. Use String_List instead of
15114 Argument_List, removing dependency on System.OS_Lib.
15115
aa1e353a
AC
151162011-08-02 Yannick Moy <moy@adacore.com>
15117
15118 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
15119 mode on initialization expression which does not respect SPARK
15120 restrictions.
15121 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
15122 if the tree referenced by its argument represents an initialization
15123 expression in SPARK, suitable for initializing an object in an object
15124 declaration.
15125
151262011-08-02 Javier Miranda <miranda@adacore.com>
15127
15128 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
15129 internally generated access to subprogram with its associated protected
15130 subprogram type.
15131 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
15132
15b682ca
GB
151332011-08-02 Geert Bosch <bosch@adacore.com>
15134
15135 * cstand.adb (Register_Float_Type): Print information about type to
15136 register, if the Debug_Flag_Dot_B is set.
15137 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
15138 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
15139 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
15140 with a requested precision of more than Max_Digits digits and no more
15141 than Max_Base_Digits digits, if a range specification is present and the
15142 Predefined_Float_Types list has a suitable type to derive from.
15143 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
15144 case of type completion with pragma Import
15145 * sem_prag.adb
15146 (Process_Import_Predefined_Type): Processing to complete a type
15147 with pragma Import. Currently supports floating point types only.
15148 (Set_Convention_From_Pragma): Do nothing without underlying type.
15149 (Process_Convention): Guard against absence of underlying type,
15150 which may happen when importing incomplete types.
15151 (Process_Import_Or_Interface): Handle case of importing predefined
15152 types. Tweak error message.
15153
f8726f2b
AC
151542011-08-02 Eric Botcazou <ebotcazou@adacore.com>
15155
15156 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
15157 functions to previous change. Reorganize code slightly.
15158
151592011-08-02 Geert Bosch <bosch@adacore.com>
15160
15161 * back_end.ads (Register_Type_Proc): New call back procedure type for
15162 allowing the back end to provide information about available types.
15163 (Register_Back_End_Types): New procedure to register back end types.
15164 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
15165 available types.
15166 * cstand.adb (Back_End_Float_Types): New list for floating point types
15167 supported by the back end.
15168 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
15169 (Copy_Float_Type): New procedure to make new copies of predefined types.
15170 (Register_Float_Type): New call back procedure to populate the BEFT list
15171 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
15172 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
15173 (Create_Float_Types): New procedure to create entities for floating
15174 point types predefined in Standard, and put these and any remaining
15175 BEFTs on the Predefined_Float_Types list.
15176 * stand.ads (Predefined_Float_Types): New list for predefined floating
15177 point types that do not have declarations in package Standard.
15178
feecad68
AC
151792011-08-02 Eric Botcazou <ebotcazou@adacore.com>
15180
15181 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
15182 entity node for the unit containing the parameter.
15183 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
15184 (Add_Inlined_Subprogram): Likewise.
15185 * gcc-interface/Make-lang.in: Update dependencies.
15186
151872011-08-02 Thomas Quinot <quinot@adacore.com>
15188
15189 * s-stusta.adb (Print): Make sure Pos is always initialized to a
15190 suitable value.
15191
12f0c50c
AC
151922011-08-02 Geert Bosch <bosch@adacore.com>
15193
15194 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
15195
151962011-08-02 Eric Botcazou <ebotcazou@adacore.com>
15197
15198 * sem_type.adb (Covers): Move trivial case to the top and reuse the
15199 computed value of Base_Type.
15200
152012011-08-02 Yannick Moy <moy@adacore.com>
15202
15203 * restrict.adb (Check_Restriction): issue an error for any use of
15204 class-wide, even if the No_Dispatch restriction is not set.
15205 * sem_aggr.adb: Correct typos in comments and messages in formal mode
15206 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
15207 when completing a private extension, the type named in the private part
15208 is not the same as that named in the visible part.
15209 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
15210 of an inherited primitive operations of a tagged type or type extension
15211 that returns the tagged type.
15212 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
15213 function which returns True for an implicit operation inherited by the
15214 derived type declaration for the argument type.
15215 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
15216 order.
15217
fb86fe11
ES
152182011-08-02 Ed Schonberg <schonberg@adacore.com>
15219
15220 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
15221 Process_Bounds, to perform analysis with expansion of a range or an
15222 expression that is the iteration scheme for a loop.
15223 (Analyze_Iterator_Specification): If domain of iteration is given by a
15224 function call with a controlled result, as is the case if call returns
15225 a predefined container, ensure that finalization actions are properly
15226 generated.
15227 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
15228
62be5d0a
JM
152292011-08-02 Javier Miranda <miranda@adacore.com>
15230
15231 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
15232 * gcc-interface/Make-lang.in: Update dependencies.
15233
152342011-08-02 Javier Miranda <miranda@adacore.com>
15235
15236 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
15237 determine if the analysis is performed using N or Original_Node (N).
15238 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
15239 functionality of routine Is_Variable avoids code duplication.
15240 * checks.adb (Determine_Range): Handle temporaries generated by
15241 Remove_Side_Effects.
15242
152432011-08-02 Javier Miranda <miranda@adacore.com>
15244
15245 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
15246 expansion of the condition. Required since the previous analysis was
15247 done with expansion disabled (see Resolve_Quantified_Expression) and
15248 hence checks were not inserted and record comparisons have not been
15249 expanded.
15250
a20f4389
AC
152512011-08-02 Ed Falis <falis@adacore.com>
15252
15253 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
15254 Update header.
15255
152562011-08-02 Bob Duff <duff@adacore.com>
15257
15258 * opt.ads: Minor comment fix.
15259
152602011-08-02 Bob Duff <duff@adacore.com>
15261
15262 * sem_ch12.adb (Analyze_Package_Instantiation,
15263 Analyze_Subprogram_Instantiation): Turn off style checking while
15264 analyzing an instance. Whatever style checks that apply to the generic
15265 unit should apply, so it makes no sense to apply them in an instance.
15266 This was causing trouble when compiling an instance of a runtime
15267 unit that violates the -gnatyO switch.
15268 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
15269 one of the two case statements, causing spurious errors.
15270
152712011-08-02 Robert Dewar <dewar@adacore.com>
15272
15273 * uname.adb: Minor reformatting.
15274 * gnatcmd.adb: Minor reformatting.
15275 * exp_attr.adb: Minor reformatting.
15276
90878b12
AC
152772011-08-02 Ed Schonberg <schonberg@adacore.com>
15278
15279 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
15280 No_Dispatching_Calls, do not look for the Assign primitive, because
15281 predefined primitives are not created in this case.
15282
152832011-08-02 Bob Duff <duff@adacore.com>
15284
15285 * stylesw.ads: Minor comment fixes.
15286
152872011-08-02 Robert Dewar <dewar@adacore.com>
15288
15289 * freeze.adb (Add_To_Result): New procedure.
15290
152912011-08-02 Jose Ruiz <ruiz@adacore.com>
15292
15293 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
15294 time, if the specific run-time routines for handling streams of strings
15295 are not available, use the default mechanism.
15296
152972011-08-02 Arnaud Charlet <charlet@adacore.com>
15298
15299 * s-regpat.ads: Fix typo.
15300
153012011-08-02 Vincent Celier <celier@adacore.com>
15302
15303 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
15304 not null, call it to create the in memory config project file without
15305 parsing an existing default config project file.
15306
153072011-08-02 Eric Botcazou <ebotcazou@adacore.com>
15308
15309 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
15310
153112011-08-02 Ed Schonberg <schonberg@adacore.com>
15312
15313 * sem_elim.adb: an abstract subprogram does not need an eliminate
15314 pragma for its descendant to be eliminable.
15315
153162011-08-02 Ed Falis <falis@adacore.com>
15317
15318 * init.c: revert to handling before previous checkin for VxWorks
15319 * s-intman-vxworks.adb: delete unnecessary declarations related to
15320 using Ada interrupt facilities for handling signals.
15321 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
15322 * s-intman-vxworks.ads: Import __gnat_install_handler as
15323 Initialize_Interrupts.
15324 * s-taprop-vxworks.adb: Delete Signal_Mask.
15325 (Abort_Handler): change construction of mask to unblock exception
15326 signals.
15327
273adcdf
AC
153282011-08-02 Jerome Guitton <guitton@adacore.com>
15329
15330 * a-except-2005.adb (Raise_From_Signal_Handler): Call
15331 Debug_Raise_Exception before propagation starts.
15332
153332011-08-02 Eric Botcazou <ebotcazou@adacore.com>
15334
15335 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
15336 to Restriction_Check_Required.
15337 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
15338 * sem_res.adb (Resolve_Call): Likewise.
15339 * sem_attr.adb (Check_Stream_Attribute): Likewise.
15340
153412011-08-02 Bob Duff <duff@adacore.com>
15342
15343 * stylesw.ads: Update comment.
15344 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
15345 * errout.ads: Remove obsolete comment.
15346
153472011-08-02 Javier Miranda <miranda@adacore.com>
15348
15349 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
15350 (Set_Is_Safe_To_Reevaluate): new procedure.
15351 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
15352 assignment is allowed on safe-to-reevaluate variables.
15353 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
15354 temporary created to remove side effects in expressions that use
15355 the secondary stack as safe-to-reevaluate.
15356 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
15357 variables that are not true constants.
15358
6320f5e1
AC
153592011-08-02 Robert Dewar <dewar@adacore.com>
15360
15361 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
15362 sem_res.adb, sem_ch6.adb: Minor reformatting.
15363
153642011-08-02 Jerome Guitton <guitton@adacore.com>
15365
15366 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
15367
2fe829ae
ES
153682011-08-02 Ed Schonberg <schonberg@adacore.com>
15369
15370 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
15371 not set Overridden_Operation if subprogram is an initialization
15372 procedure.
15373
e24329cd
YM
153742011-08-02 Yannick Moy <moy@adacore.com>
15375
15376 * par-ch6.adb: Correct obsolete name in comments
15377 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
15378 which takes two message arguments (existing function takes one), with
15379 second message used for continuation.
15380 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
15381 block statements that originate from a source block statement, not
15382 generated block statements
15383 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
15384 symmetry with procedure case
15385 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
15386 function to issue an error in formal mode if a package specification
15387 contains more than one tagged type or type extension.
15388 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
15389 parameters matching formals of tagged types are objects (or ancestor
15390 type conversions of objects), not general expressions. Issue an error
15391 on view conversions that are not involving ancestor conversion of an
15392 extended type.
15393 (Resolve_Type_Conversion): in formal mode, issue an error on the
15394 operand of an ancestor type conversion which is not an object
15395 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
15396 procedure so that it works also for actuals of function calls
15397 (Is_Actual_Tagged_Parameter): new function which determines if its
15398 argument is an actual parameter of a formal of tagged type in a
15399 subprogram call
15400 (Is_SPARK_Object_Reference): new function which determines if the tree
15401 referenced by its argument represents an object in SPARK
15402
176dadf6
AC
154032011-08-02 Robert Dewar <dewar@adacore.com>
15404
15405 * sem_ch3.adb: Minor reformatting
15406 Minor comment addition
15407 Minor error msg text change
15408
154092011-08-02 Javier Miranda <miranda@adacore.com>
15410
15411 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
15412 function. Used to be more precise when we generate a variable plus one
15413 assignment to remove side effects in the evaluation of the Bound
15414 expressions.
15415 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
15416 of the bound expression to force its re-analysis and thus expand the
15417 associated transient scope (if required). Code cleanup replacing the
15418 previous code that declared the constant entity by an invocation to
15419 routine Force_Evaluation which centralizes this work in the frontend.
15420
d8b962d8
AC
154212011-08-02 Robert Dewar <dewar@adacore.com>
15422
15423 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
15424 (Base_Type): Now uses improved Is_Base_Type function
15425 * einfo.ads (Base_Type): Inline this function
15426
154272011-08-02 Robert Dewar <dewar@adacore.com>
15428
15429 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
15430 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
15431
154322011-08-02 Arnaud Charlet <charlet@adacore.com>
15433
15434 * gcc-interface/Make-lang.in: Update dependencies.
15435 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
15436 targets.
15437
154382011-08-02 Yannick Moy <moy@adacore.com>
15439
15440 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
15441 non-simple expression used in delta constraint
15442 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
15443 index constraint which is not a subtype mark
15444 * par.adb: With and use Restrict
15445 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
15446 mode on component type which is not a subtype mark and default
15447 expression on component
15448 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
15449 of string which does not have a lower index bound equal to 1
15450 (Array_Type_Declaration): issue an error in formal mode on index or
15451 component type which is not a subtype mark, and on aliased keyword on
15452 component
15453 (Derived_Type_Declaration): issue an error in formal mode on interface,
15454 limited or abstract type
15455 (Record_Type_Declaration): issue an error in formal mode on interface
15456 (Record_Type_Definition): issue an error in formal mode on tagged types
15457 and type extensions not declared in the specification of a library unit
15458 package; on null non-tagged record; on variant part
15459
154602011-08-02 Vincent Celier <celier@adacore.com>
15461
15462 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
15463 not declared for qualified library project when Library_Name is not
15464 declared, but Library_Dir is.
15465
154662011-08-02 Robert Dewar <dewar@adacore.com>
15467
15468 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
15469 pragmas (affects aspects [Component_]Default_Value
15470 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
15471 component type for the resolution
15472
f96b2d85
AC
154732011-08-02 Eric Botcazou <ebotcazou@adacore.com>
15474
15475 * einfo.adb (Base_Type): Tune implementation for speed.
15476
154772011-08-02 Robert Dewar <dewar@adacore.com>
15478
15479 * freeze.adb: Minor reformatting.
15480
8b3c6430
AC
154812011-08-02 Thomas Quinot <quinot@adacore.com>
15482
15483 * scos.ads: Update comments.
15484
154852011-08-02 Ed Schonberg <schonberg@adacore.com>
15486
15487 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
15488 base type, because the parent may be a subtype of a private type whose
15489 convention is established in a private part.
15490
154912011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
15492
15493 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
15494 statement in a block when the expansion of the return expression has
15495 created a finalization chain.
15496 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
15497 with the parent node.
15498 Add N_Extended_Return_Statement to handle the case where a transient
15499 object declaration appears in the Return_Object_Declarations list of
15500 an extended return statement.
15501
155022011-08-02 Matthew Gingell <gingell@adacore.com>
15503
15504 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
15505 unused parameter 'name'.
15506
155072011-08-02 Ed Schonberg <schonberg@adacore.com>
15508
15509 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
15510 inherited operation, check whether its alias, which is the source
15511 operastion that it renames, has been marked eliminated.
15512
cae81f17
JM
155132011-08-02 Javier Miranda <miranda@adacore.com>
15514
15515 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
15516 in-mode parameter whose type is an access type since it can be used to
15517 modify its designated object. Enforce code that handles as safe an
15518 access type that is not access-to-constant but it is the result of a
15519 previous removal of side-effects.
15520 (Remove_Side_Effects): Minor code reorganization of cases which require
15521 no action. Done to incorporate documentation on new cases uncovered
15522 working in this ticket: no action needed if this routine was invoked
15523 too early and the nodes are not yet decorated.
15524 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
15525 to routine Remove_Side_Effects by calls to Force_Evaluation since they
15526 were issued with actuals that are implicitly provided by
15527 Force_Evaluation.
15528
218e6dee
RD
155292011-08-02 Robert Dewar <dewar@adacore.com>
15530
15531 * sem_ch3.adb, sem_res.adb: Minor reformatting.
15532
7a489a2b
AC
155332011-08-02 Yannick Moy <moy@adacore.com>
15534
15535 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
15536 to issue an error in formal mode on attribute not supported in this mode
15537 (Analyze_Attribute): issue errors on standard attributes not supported
15538 in formal mode.
15539 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
15540 comment, and issue error in formal mode on modulus which is not a power
15541 of 2.
15542 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
15543 range.
15544 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
15545 subtype mark.
15546 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
15547 operator on modular type (except 'not').
15548
155492011-08-02 Robert Dewar <dewar@adacore.com>
15550
15551 * gnat_rm.texi: Minor reformatting.
15552
cb7fa356
AC
155532011-08-02 Arnaud Charlet <charlet@adacore.com>
15554
15555 * s-osinte-linux.ads: Minor comment update and reformatting.
15556 * i-cexten.ads: Make this unit pure, as for its parent.
15557 Will allow its usage in more contexts if needed.
15558
155592011-08-02 Robert Dewar <dewar@adacore.com>
15560
15561 * s-utf_32.ads: Minor comment fix.
15562
155632011-08-02 Ed Schonberg <schonberg@adacore.com>
15564
15565 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
15566 operation of a tagged synchronized type, handle the case where the
15567 controlling argument is overloaded.
15568
155692011-08-02 Yannick Moy <moy@adacore.com>
15570
15571 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
15572 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
15573 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
15574 SPARK mode and formal verification mode on processing SPARK restriction
15575 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
15576 requiring consistency checking.
15577
5cc9353d
RD
155782011-08-02 Robert Dewar <dewar@adacore.com>
15579
15580 * sem_res.adb: Minor reformatting.
15581
e51537ff
RD
155822011-08-02 Robert Dewar <dewar@adacore.com>
15583
15584 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
15585 a-cforse.ads: Remove unneeded with of Ada.Containers
15586 Remove commented out pragma Inline's
15587 Move specifications of new subprograms to the actual specs
15588
83fa09c5
AC
155892011-08-02 Yannick Moy <moy@adacore.com>
15590
15591 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
15592 a-cforse.ads: Update comments.
15593
155942011-08-02 Ed Schonberg <schonberg@adacore.com>
15595
15596 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
15597
d11cfaf8
RD
155982011-08-02 Robert Dewar <dewar@adacore.com>
15599
15600 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
15601 a-cforse.ads, a-cofove.ads: Minor reformatting.
15602
300b98bb
AC
156032011-08-02 Claire Dross <dross@adacore.com>
15604
15605 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
15606 a-cofove.ads: Add comments.
15607
156082011-08-02 Yannick Moy <moy@adacore.com>
15609
15610 * gnat_rm.texi: Document formal containers.
15611
156122011-08-02 Emmanuel Briot <briot@adacore.com>
15613
15614 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
15615 are empty sections.
15616
19fb051c
AC
156172011-08-02 Robert Dewar <dewar@adacore.com>
15618
15619 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
15620 reformatting.
15621
156222011-08-02 Robert Dewar <dewar@adacore.com>
15623
15624 * aspects.adb: New aspects Default_Value and Default_Component_Value
15625 New format of Aspect_Names table checks for omitted entries
15626 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
15627 handling of boolean aspects for derived types.
15628 New aspects Default_Value and Default_Component_Value
15629 New format of Aspect_Names table checks for omitted entries
15630 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
15631 (Has_Default_Value): New flag
15632 (Has_Default_Component_Value): New flag
15633 (Has_Default_Value): New flag
15634 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
15635 table.
15636 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
15637 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
15638 Default_Value and Default_Component_Value
15639 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
15640 New aspects Default_Value and Default_Component_Value
15641 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
15642 * sprint.adb: Print N_Aspect_Specification node when called from gdb
15643
156442011-08-02 Vincent Celier <celier@adacore.com>
15645
15646 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
15647 inherit library kind.
15648
156492011-08-02 Ed Schonberg <schonberg@adacore.com>
15650
15651 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
15652 Minor reformatting.
15653
156542011-08-02 Robert Dewar <dewar@adacore.com>
15655
15656 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
15657
5f7747af
AC
156582011-08-02 Yannick Moy <moy@adacore.com>
15659
15660 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
15661
156622011-08-02 Robert Dewar <dewar@adacore.com>
15663
15664 * impunit.adb: Add comment.
15665
a5fe697b
AC
156662011-08-02 Yannick Moy <moy@adacore.com>
15667
15668 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
15669 qualification of aggregates in formal mode
15670 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
15671 another aggregate
15672 (Resolve_Aggregate): complete the test that an aggregate is adequately
15673 qualified in formal mode
15674
156752011-08-02 Pascal Obry <obry@adacore.com>
15676
15677 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
15678 * mlib-prj.adb: Supress warning when compiling binder generated file.
15679 (Build_Library): Supress all warnings when compiling the binder
15680 generated file.
15681
bd65a2d7 156822011-08-02 Yannick Moy <moy@adacore.com>
d4487611 15683
bd65a2d7
AC
15684 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
15685 from here...
15686 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
15687 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
15688 Add with/use clauses to make Check_Formal_Restriction visible
15689
156902011-08-02 Ed Schonberg <schonberg@adacore.com>
15691
15692 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
15693 in-parameters when type of the generic formal is private in the generic
15694 spec and non-private in the body.
15695
156962011-08-02 Claire Dross <dross@adacore.com>
15697
15698 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
15699 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
15700 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
15701 * impunit.adb, Makefile.rtl: Take new files into account.
d4487611
AC
15702
157032011-08-02 Robert Dewar <dewar@adacore.com>
15704
15705 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
15706 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
15707
bd434b3f
YM
157082011-08-02 Yannick Moy <moy@adacore.com>
15709
15710 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
15711 formal mode
15712 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
15713 matching static array bounds, taking into account the special case of
15714 string literals
15715 * sem_ch3.adb: Typo in comment.
15716
fe5d3068
YM
157172011-08-02 Yannick Moy <moy@adacore.com>
15718
15719 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
15720 which issues an error in formal mode if its argument node is originally
15721 from source
15722 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
15723 has a discriminant specification so that it does not include the case
15724 of derived types
15725 (Derived_Type_Declaration): move here the test that a derived type has a
15726 discriminant specification
15727 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
15728 first element of a component association before accessing its choices
15729 (presence of component association is not enough)
15730 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
15731 declaration is a library item before accessing the next element in a
15732 list, as library items are not member of lists
15733 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
15734 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
15735 Check_Formal_Restriction whenever possible.
15736
b60a3f26
AC
157372011-08-02 Ed Schonberg <schonberg@adacore.com>
15738
15739 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
15740 reference when needed.
15741
157422011-08-02 Bob Duff <duff@adacore.com>
15743
15744 * gnat_ugn.texi: Fix typo.
15745
157462011-08-02 Vincent Celier <celier@adacore.com>
15747
15748 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
15749 archive file name. Do not use the full path name of archives for Open
15750 VMS.
15751
eaba57fb
RD
157522011-08-02 Robert Dewar <dewar@adacore.com>
15753
15754 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
15755 Analyze_Aspect_Specifications
15756 * sem_ch13.adb
15757 (Analyze_Aspect_Specifications): New handling for boolean aspects
15758 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
15759 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
15760 sequence for Analyze_Aspect_Specifications
15761 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
15762 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
15763
157642011-08-02 Robert Dewar <dewar@adacore.com>
15765
15766 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
15767 aspects, since these no longer exist.
15768
157692011-08-02 Robert Dewar <dewar@adacore.com>
15770
15771 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
15772 semicolon, do not try to see if there are aspects following it.
15773 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
15774 aspect spec.
15775
8830d1d2
AC
157762011-08-02 Robert Dewar <dewar@adacore.com>
15777
15778 * sem_ch8.adb, aspects.ads: Minor reformatting.
15779
157802011-08-02 Eric Botcazou <ebotcazou@adacore.com>
15781
15782 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
15783 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
15784 extracted from...
15785 (Analyze_Aspect_Specifications): ...here. Call above procedure.
15786
7ff2d234
AC
157872011-08-02 Yannick Moy <moy@adacore.com>
15788
15789 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
15790 mode on subprogram declaration outside of package specification, unless
15791 it is followed by a pragma Import
15792 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
15793 Access_Type_Declaration): issue error in formal mode on access type
15794 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
15795 incomplete type
15796 (Analyze_Object_Declaration): issue error in formal mode on object
15797 declaration which does not respect SPARK restrictions
15798 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
15799 declaration which does not respect SPARK restrictions
15800 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
15801 error in formal mode on digits or delta constraint
15802 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
15803 decimal fixed point type
15804 (Derived_Type_Declaration): issue error in formal mode on derived type
15805 other than type extensions of tagged record types
15806 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
15807 with check on access definition
15808 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
15809 mode on protected definition.
15810 (Analyze_Task_Definition): issue error in formal mode on task definition
15811
158122011-08-02 Robert Dewar <dewar@adacore.com>
15813
15814 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
15815
806f6d37
AC
158162011-08-02 Javier Miranda <miranda@adacore.com>
15817
15818 * sem_ch6.adb (Can_Override_Operator): New function.
15819 (Verify_Overriding_Indicator): Add missing code to check overriding
15820 indicator in operators. Fixes regression.
15821 (Check_Overriding_Indicator): Minor reformating after replacing the
15822 code that evaluates if the subprogram can override an operator by
15823 invocations to the above new function.
15824 * einfo.adb
15825 (Write_Field26_Name): Add missing code to ensure that, following
15826 the documentation in einfo.ads, this field is not shown as attribute
15827 "Static_Initialization" on non-dispatching functions.
15828
158292011-08-02 Jose Ruiz <ruiz@adacore.com>
15830
15831 * sem_res.adb (Resolve_Call): A call to
15832 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
15833 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
15834 i.e., when the second parameter is of type Time_Span.
15835
158362011-08-02 Vincent Celier <celier@adacore.com>
15837
15838 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
15839 with an archive instead of -L<library dir> -l<library name>.
15840
158412011-08-02 Ed Schonberg <schonberg@adacore.com>
15842
15843 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
15844 mark the base types In_Use in addition to making the operations
15845 use_visible.
15846
158472011-08-02 Ed Falis <falis@adacore.com>
15848
15849 * init.c: add and setup __gnat_signal_mask for the exception signals
15850 * s-inmaop-vxworks.adb: new file.
15851 * s-intman-vxworks.adb: remove unnecessary initializations and
15852 simplify remaining
15853 * s-intman-vxworks.ads: remove unnecessary variable
15854 * s-taprop-vxworks.adb: simplify signal initialization
15855
780d052e
RD
158562011-08-02 Robert Dewar <dewar@adacore.com>
15857
15858 * sem_ch8.adb: Minor code reorganization, comment updates.
15859
158602011-08-02 Robert Dewar <dewar@adacore.com>
15861
15862 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
15863 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
15864 here from Sem_Res.
15865 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
15866 (Matching_Static_Array_Bounds): Moved here from Sem_Res
15867
29efbb8c
ES
158682011-08-02 Ed Schonberg <schonberg@adacore.com>
15869
15870 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
15871 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
15872 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
15873 use_type_clauses, to handle more efficiently use_type and use_all_type
15874 constructs.
15875 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
15876 Ada2012 Use_All_Type clause.
15877 (Use_Class_Wide_Operations): new procedure.
15878
b0186f71
AC
158792011-08-02 Robert Dewar <dewar@adacore.com>
15880
15881 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
15882 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
15883 expression to expression function.
15884
158852011-08-02 Ed Schonberg <schonberg@adacore.com>
15886
15887 * sem_ch4.adb: transform simple Ada2012 membership into equality only
15888 if types are compatible.
15889
158902011-08-02 Yannick Moy <moy@adacore.com>
15891
15892 * sem_res.adb (Matching_Static_Array_Bounds): new function which
15893 returns True if its argument array types have same dimension and same
15894 static bounds at each index.
15895 (Resolve_Actuals): issue an error in formal mode on actuals passed as
15896 OUT or IN OUT paramaters which are not view conversions in SPARK.
15897 (Resolve_Arithmetic_Op): issue an error in formal mode on
15898 multiplication or division with operands of fixed point types which are
15899 not qualified or explicitly converted.
15900 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
15901 Boolean or array type (except String) operands.
15902 (Resolve_Equality_Op): issue an error in formal mode on equality
15903 operators for array types other than String with non-matching static
15904 bounds.
15905 (Resolve_Logical_Op): issue an error in formal mode on logical operators
15906 for array types with non-matching static bounds. Factorize the code in
15907 Matching_Static_Array_Bounds.
15908 (Resolve_Qualified_Expression): issue an error in formal mode on
15909 qualified expressions for array types with non-matching static bounds.
15910 (Resolve_Type_Conversion): issue an error in formal mode on type
15911 conversion for array types with non-matching static bounds
15912
767bb4e8
AC
159132011-08-02 Robert Dewar <dewar@adacore.com>
15914
15915 * par-ch10.adb: Minor code reorganization (use Nkind_In).
15916
159172011-08-02 Ed Schonberg <schonberg@adacore.com>
15918
15919 * par-ch9.adb: save location of entry for proper error message.
15920
4ac2477e
JM
159212011-08-02 Javier Miranda <miranda@adacore.com>
15922
15923 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
15924 (Use_Full_View) which permits this routine to climb through the
15925 ancestors using the full-view of private parents.
15926 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
15927 Use_Full_View to true in calls to Is_Ancestor.
15928 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
15929 true in call to Is_Ancestor.
15930 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
15931 Use_Full_View to true in call to Is_Ancestor.
15932 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
15933 call to Is_Ancestor.
15934 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
15935 Use_Full_View to true in calls to Is_Ancestor.
15936 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
15937 Make_Select_Specific_Data_Table, Register_Primitive,
15938 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
15939 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
15940 to true in call to Is_Ancestor.
15941 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
15942 Use_Full_View to true in calls to Is_Ancestor.
15943 * exp_cg.adb
15944 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
15945 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
15946
9f90d123
AC
159472011-08-02 Robert Dewar <dewar@adacore.com>
15948
15949 * gnat_rm.texi: Minor reformatting.
15950 * sem_prag.adb: Minor reformatting.
15951
159522011-08-02 Tristan Gingold <gingold@adacore.com>
15953
15954 * vms_data.ads: Add VMS qualifier for -gnateP.
15955
159562011-08-02 Robert Dewar <dewar@adacore.com>
15957
15958 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
15959 * par-ch7.adb (P_Package): Proper placement of aspects for package
15960 decl/instantiation.
15961 * par-endh.adb (Check_End): Ad Is_Sloc parameter
15962 (End_Statements): Add Is_Sloc parameterr
15963 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
15964 (Check_End): Ad Is_Sloc parameter
15965 (End_Statements): Add Is_Sloc parameterr
15966
159672011-08-02 Vincent Celier <celier@adacore.com>
15968
15969 * ug_words: Add VMS qualifier equivalent to -gnateP:
15970 /SYMBOL_PREPROCESSING.
15971
159722011-08-02 Jose Ruiz <ruiz@adacore.com>
15973
15974 * gnat-style.texi: For hexadecimal numeric literals the typical
15975 grouping of digits is 4 to represent 2 bytes.
15976 A procedure spec which is split into several lines is indented two
15977 characters.
15978
159792011-08-02 Yannick Moy <moy@adacore.com>
15980
15981 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
15982 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
15983 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
15984 properly qualified
15985 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
15986 choice in array aggregate
15987 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
15988 mark as ancestor
15989 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
15990 positional and named aggregate for record, or others in record
15991 aggregate, or multiple choice in record aggregate
15992 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
15993 array operands to logical operations AND, OR and XOR do not have the
15994 same static lower and higher bounds
15995 * sem_ch5.adb, sinfo.ads: Correct typos in comments
15996
2933b16c
RD
159972011-08-01 Robert Dewar <dewar@adacore.com>
15998
15999 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
16000 Replaces Last_Source_Node_In_Sequence.
16001 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
16002 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
16003 parens and blank in string (this was inconsistently implemented).
16004 * errout.ads
16005 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
16006 blank in string (this was inconsistently implemented).
16007 * gnat1drv.adb
16008 (Set_Global_Switches): Set formal mode switches appropriately
16009 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
16010 * par-prag.adb
16011 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
16012 call Set_Error_Msg_Lang to set "spark" as language name.
16013 * par.adb: Remove unnecessary call to set formal language for errout
16014 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
16015 appropriately and call Set_Error_Msg_Lang to set "spark" as language
16016 name.
16017 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
16018 calls to it, moved after resolution so that types are known
16019 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
16020 result of concatenation is not of type String
16021 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
16022 concatenation is not properly restricted
16023 * gnat_rm.texi: Add doc on pragma Spark_95.
16024 * gcc-interface/Makefile.in: Remove obsolete target pairs for
16025 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
16026 * gcc-interface/Make-lang.in: Update dependencies.
16027
05dbd302
AC
160282011-08-01 Javier Miranda <miranda@adacore.com>
16029
16030 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
16031 condition that detects if the overridden operation must replace an
16032 existing entity.
16033
160342011-08-01 Javier Miranda <miranda@adacore.com>
16035
16036 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
16037 code declarations inserted by Insert_Actions in each alternative of the
16038 N_Case_Expression node.
16039
160402011-08-01 Robert Dewar <dewar@adacore.com>
16041
16042 * sem_ch6.adb: Minor code reorganization.
16043 * sem_util.adb: Minor reformatting.
16044
af9e051f
PO
160452011-08-01 Pascal Obry <obry@adacore.com>
16046
16047 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
16048 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
16049
1d801f21
AC
160502011-08-01 Yannick Moy <moy@adacore.com>
16051
16052 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
16053 literal or operator symbol which is prefixed
16054 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
16055 mode on access attributes.
16056 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
16057 that concatenation operands are properly restricted in formal mode
16058 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
16059 Analyze_Concatenation_Operand. Issue an error in formal mode if the
16060 result of the concatenation has a type different from String.
16061 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
16062 Analyze_Quantified_Expression, Analyze_Slice,
16063 Analyze_Null): issue an error in formal mode on unsupported constructs
16064 * sem_ch5.adb
16065 (Analyze_Block_Statement): only issue error on source block statement
16066 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
16067 function which returns the last node in a list of nodes for which
16068 Comes_From_Source returns True, if any
16069 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
16070 Last_Source_Node_In_Sequence
16071 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
16072 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
16073 mode on unsupported constructs
16074 * sem_ch9.adb Do not return after issuing error in formal mode, as the
16075 rest of the actions may be needed later on since the error is marked as
16076 not serious.
16077 * sinfo.ads: Typos in comments.
16078
160792011-08-01 Pascal Obry <obry@adacore.com>
16080
16081 * projects.texi: Minor editing.
16082
53beff22
YM
160832011-08-01 Yannick Moy <moy@adacore.com>
16084
16085 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
16086 insertion character ~~
16087 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
16088 (Set_Error_Msg_Lang): new procedure which fixes the language for use
16089 with insertion character ~~
16090 (Set_Msg_Text): treat insertion character ~~
16091 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
16092 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
16093 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
16094 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
16095 errors related to the formal language restriction not serious
16096 (insertion character |).
16097 * par.adb (Par): set formal language for error messages if needed
16098 * sem_ch6.adb (Check_Missing_Return): take into account possible
16099 generated statements at the end of the function
16100 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
16101 enumeration value to define a new pragma SPARK_95
16102 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
16103 SPARK_Version): new type and variables to store the SPARK version
16104 (none by default).
16105 (SPARK_Mode): return True when SPARK_Version is set
16106 * par-prag.adb: Correct indentation
16107 (Prag): take Pragma_SPARK_95 into account
16108 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
16109 into account.
16110
8d606a78
RD
161112011-08-01 Robert Dewar <dewar@adacore.com>
16112
16113 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
16114 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
16115 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
16116
1982d5a8
PO
161172011-08-01 Pascal Obry <obry@adacore.com>
16118
16119 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
16120 Target_Name to Get_Path call.
16121 (Parse_Single_Project): Likewise.
16122 (Post_Parse_Context_Clause): Likewise.
16123 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
16124 Call Initialise_Project_Path with the proper Target_Name.
16125 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
16126 search path.
16127 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
16128 with the proper Target_Name.
16129 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
16130 Part.Parse routine.
16131 (Parse_Project_And_Apply_Config): Likewise.
16132 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
16133 This is fine as this part of the code is supporting only native
16134 compilation.
16135 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
16136 is fine as this part of the code is supporting only native compilation.
16137
0d53d36b
AC
161382011-08-01 Yannick Moy <moy@adacore.com>
16139
16140 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
16141 of homonym, unless the homonym is one of the cases allowed in SPARK
16142 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
16143 package declaration occurring after a body.
16144
161452011-08-01 Robert Dewar <dewar@adacore.com>
16146
16147 * checks.adb, exp_ch4.adb: Minor reformatting.
16148
161492011-08-01 Javier Miranda <miranda@adacore.com>
16150
16151 * einfo.ads (Access_Disp_Table): Fix documentation.
16152 (Dispatch_Table_Wrappers): Fix documentation.
16153
161542011-08-01 Pascal Obry <obry@adacore.com>
16155
16156 * prj-env.adb, prj-env.ads: Minor reformatting.
16157
8ed68165
AC
161582011-08-01 Yannick Moy <moy@adacore.com>
16159
16160 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
16161 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
16162 procedures out of these packages.
2c7f9cc0 16163 * errout.ads, errout.adb
8ed68165
AC
16164 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
16165 procedures in of this package
16166 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
16167 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
16168 on misplaced later vs initial declarations, like in Ada 83
16169 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
16170 formal mode on attribute of private type whose full type declaration
16171 is not visible
16172 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
16173 package declaration inside a package specification
16174 (Analyze_Full_Type_Declaration): issue error in formal mode on
16175 controlled type or discriminant type
16176 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
16177 user-defined operator means that it should come from the source
16178 (New_Overloaded_Entity): issue error in formal mode on overloaded
16179 entity.
16180 * sem_ch6.ads, sem_ch13.ads: typos in comments.
16181
161822011-08-01 Thomas Quinot <quinot@adacore.com>
16183
16184 * atree.adb: Minor reformatting.
16185 * checks.adb: Minor reformatting.
16186
4230bdb7
AC
161872011-08-01 Vincent Celier <celier@adacore.com>
16188
16189 * s-parame-vms-ia64.ads: Fix typo in comment
16190 Minor reformatting
16191 * s-parame-vms-restrict.ads: Removed, unused.
16192
161932011-08-01 Javier Miranda <miranda@adacore.com>
16194
16195 * exp_ch3.adb
16196 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
16197 * sem_ch3.adb
16198 (Constrain_Index): Remove side effects in the evaluation of the bounds.
16199 * sem_ch3.ads, sem_ch3.adb
16200 (Is_Constant_Bound): New extended version of the subprogram that was
16201 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
16202 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
16203 * sem_aux.ads (Constant_Value): Fix typo in comment.
16204 * checks.adb (Generate_Index_Checks): New implementation which, for
16205 array objects with constant bounds, generates the runtime check
16206 referencing the bounds of the array type. For other cases this routine
16207 provides its previous behavior obtaining such values from the array
16208 object.
16209 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
16210 parent type.
16211 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
16212 we cannot have semantic interpretations of the new node.
16213
2010d078
AC
162142011-08-01 Ed Schonberg <schonberg@adacore.com>
16215
16216 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
16217 expressions.
16218
162192011-08-01 Arnaud Charlet <charlet@adacore.com>
16220
16221 * sem_ch8.adb: Minor code editing.
16222 * s-vxwext.adb: Remove trailing space.
16223 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
16224 consistency with other files.
16225
162262011-08-01 Thomas Quinot <quinot@adacore.com>
16227
16228 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
16229
162302011-08-01 Ed Schonberg <schonberg@adacore.com>
16231
16232 * par-ch10.adb: reject parameterized expressions as compilation unit.
16233 * sem_ch4.adb: handle properly conditional expression with overloaded
16234 then_clause and no else_clause.
16235
162362011-08-01 Tristan Gingold <gingold@adacore.com>
16237
16238 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
16239 like done by System.Aux_DEC.
16240 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
16241
daec8eeb
YM
162422011-08-01 Yannick Moy <moy@adacore.com>
16243
16244 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
16245 missing label at end of declaration (subprogram or package)
16246 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
16247 of positional and named parameter association
16248 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
16249 Error_Msg_SP which adds a prefix to the error message giving the name
16250 of the formal language analyzed
16251 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
16252 access result type in subprogram, unconstrained array as result type,.
16253 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
16254 procedure
16255 * sem_ch8.adb: Code clean up.
16256
38171f43
AC
162572011-08-01 Javier Miranda <miranda@adacore.com>
16258
16259 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
16260 * einfo.ads (Access_Disp_Table): Fix documentation.
16261 (Dispatch_Table_Wrappers): Fix documentation.
16262 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
16263 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
16264 to enforce the documentation of this attribute.
16265 (Set_Is_Interface): Cleanup the assertion.
16266 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
16267 the Underlying_Type entity before reading attribute Access_Disp_Table.
16268 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
16269 Locate the Underlying_Type before reading attribute Access_Disp_Table.
16270 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
16271 the Underlying_Type entity before reading attribute Access_Disp_Table.
16272 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
16273 Locate the Underlying_Type entity before reading attribute
16274 Access_Disp_Table.
16275
162762011-08-01 Ed Schonberg <schonberg@adacore.com>
16277
16278 * s-poosiz.ads: Additional overriding indicators.
16279
162802011-08-01 Yannick Moy <moy@adacore.com>
16281
16282 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
16283 formal mode.
16284 (Analyze_Iteration_Scheme): issue error in formal mode when loop
16285 parameter specification does not include a subtype mark.
16286 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
16287 formal mode on abstract subprogram.
16288 (Analyze_Subprogram_Specification): issue error in formal mode on
16289 user-defined operator.
16290 (Process_Formals): issue error in formal mode on access parameter and
16291 default expression.
16292 * sem_ch9.adb (Analyze_Abort_Statement,
16293 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
16294 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
16295 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
16296 Analyze_Requeue, Analyze_Selective_Accept,
16297 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
16298 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
16299 issue error in formal mode on user-defined raise statement.
16300
1f250383
AC
163012011-08-01 Thomas Quinot <quinot@adacore.com>
16302
16303 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
16304 declaration being hidden when overriding an implicit inherited
16305 subprogram.
16306 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
16307 (-gnats), do not complain about a source file that contains only a
16308 pragma No_Body.
16309
163102011-08-01 Ed Schonberg <schonberg@adacore.com>
16311
16312 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
16313 variable if already set.
16314
607d0635
AC
163152011-08-01 Arnaud Charlet <charlet@adacore.com>
16316
16317 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
16318 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
16319 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
16320 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
16321 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
16322 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
16323 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
16324 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
16325 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
16326 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
16327 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
16328 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
16329 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
16330 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
16331 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
16332 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
16333 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
16334 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
16335 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
16336 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
16337 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
16338 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
16339 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
16340 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
16341 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
16342 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
16343 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
16344 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
16345 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
16346 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
16347 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
16348 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
16349 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
16350 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
16351 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
16352 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
16353 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
16354 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
16355 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
16356 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
16357 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
16358 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
16359 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
16360 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
16361 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
16362 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
16363 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
16364 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
16365 s-osinte-mingw.ads: Update to GPLv3 run-time license.
16366 Use GNAT instead of GNARL.
16367
163682011-08-01 Bob Duff <duff@adacore.com>
16369
16370 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
16371 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
16372 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
16373 reformatting.
16374
163752011-08-01 Yannick Moy <moy@adacore.com>
16376
16377 * debug.adb (d.D) reverve flag for the SPARK mode
16378 (d.E) reverve flag for SPARK generation mode
16379 (d.F) reverve flag for Why generation mode
2c7f9cc0 16380 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
607d0635
AC
16381 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
16382 functions which return True when the corresponding modes are set
16383 (Formal_Language): return "spark" or "alfa" when in formal verification
16384 mode.
16385 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
16386 Error_Msg to prefix the error message with a tag giving the formal
16387 language
16388 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
16389 message with a tag giving the formal language
16390 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
16391 block statement
16392 (Analyze_Case_Statement): issue error in formal mode on case statement
16393 with a single "others" case alternative
16394 (Analyze_Exit_Statement): issue errors in formal mode on exit
16395 statements which do not respect SPARK restrictions
16396 (Analyze_Goto_Statement): issue error in formal mode on goto statement
16397 (Check_Unreachable_Code): always issue an error (not a warning) in
16398 formal mode on unreachable code (concerns both code after an infinite
16399 loop and after an unconditional jump, both not allowed in SPARK)
16400 * sem_ch6.adb (Analyze_Return_Statement): add call to
16401 Set_Return_Present for a procedure containing a return statement
16402 (already done for functions in Analyze_Function_Return)
16403 (Analyze_Function_Return): issue error in formal mode on extended
16404 return or if return is not last statement in function
16405 (Check_Missing_Return): issue error in formal mode if function does
16406 not end with return or if procedure contains a return
16407 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
16408 function to detect if there is an inner scope of its parameter S which
16409 is a loop.
16410
164112011-08-01 Thomas Quinot <quinot@adacore.com>
16412
16413 * sem_ch6.ads: Minor reformatting.
16414
d8b3ccb9
AC
164152011-08-01 Javier Miranda <miranda@adacore.com>
16416
16417 * sem_util.adb (Abstract_Interface_List): Complete condition when
16418 processing private type declarations to avoid reading unavailable
16419 attribute.
16420 (Is_Synchronized_Tagged_Type): Complete condition when processing
16421 private extension declaration nodes to avoid reading unavailable
16422 attribute.
16423
164242011-08-01 Thomas Quinot <quinot@adacore.com>
16425
16426 * sem_ch3.adb: Minor reformatting.
16427
164282011-08-01 Thomas Quinot <quinot@adacore.com>
16429
16430 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
16431 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
16432 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
16433 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
16434 for VMS, instead parametrize the common implementation with
16435 System.Parameters declarations.
16436
0bb9276c
AC
164372011-08-01 Eric Botcazou <ebotcazou@adacore.com>
16438
16439 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
16440
164412011-08-01 Tristan Gingold <gingold@adacore.com>
16442
16443 * seh_init.c: Fix SEH handler installation on win64.
16444
164452011-08-01 Ed Schonberg <schonberg@adacore.com>
16446
16447 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
16448 double analysis of an anonymous access to subprogram, because it can
16449 lead to improper sharing of profiles and a back-end crash.
16450
6a2e4f0b
AC
164512011-08-01 Robert Dewar <dewar@adacore.com>
16452
16453 * make.adb, sem_ch4.adb: Minor reformatting.
16454 * gcc-interface/Make-lang.in: Update dependencies.
16455 * sem_util.adb, exp_ch5.adb: Minor reformatting.
16456
164572011-08-01 Arnaud Charlet <charlet@adacore.com>
16458
16459 * gnat_rm.texi: Fix definition of Long_Integer.
16460
164612011-08-01 Ed Schonberg <schonberg@adacore.com>
16462
16463 * exp_aggr.adb: check limit size of static aggregate unconditionally,
16464 to prevent storage exhaustion.
16465 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
16466 finalized is a function body, insert the cleanup code before the final
16467 return statement, to prevent spurious warnings.
16468 * s-pooglo.ads: add overriding indicator.
16469
4561baf7
ES
164702011-08-01 Ed Schonberg <schonberg@adacore.com>
16471
16472 * sem_ch4.adb (Operator_Check): improve error message when both a
16473 with_clause and a use_clause are needed to make operator usage legal.
16474 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
16475 determine whether a compilation unit is visible within an other,
16476 either through a with_clause in the current unit, or a with_clause in
16477 its library unit or one one of its parents.
16478
383e179e
AC
164792011-08-01 Ed Schonberg <schonberg@adacore.com>
16480
16481 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
16482 over an arbitrary expression of an array or container type.
16483 * lib-xref.adb: clarify comment.
16484
164852011-08-01 Bob Duff <duff@adacore.com>
16486
16487 * einfo.ads: Minor reformatting.
16488 * debug.adb: Minor comment improvement.
16489
164902011-08-01 Javier Miranda <miranda@adacore.com>
16491
16492 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
16493 consider hidden subprograms as valid candidates.
16494
164952011-08-01 Arnaud Charlet <charlet@adacore.com>
16496
16497 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
16498
164992011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
16500
16501 * gnat_ugn.texi: Fix typo.
16502
61c161b2
AC
165032011-08-01 Robert Dewar <dewar@adacore.com>
16504
16505 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
16506 lib-xref.adb: Minor reformatting
16507
165082011-08-01 Gary Dismukes <dismukes@adacore.com>
16509
16510 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
16511 when to generate a call to Move_Final_List.
16512 (Has_Controlled_Parts): Remove this function.
16513
84df40f7
AC
165142011-08-01 Geert Bosch <bosch@adacore.com>
16515
16516 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
16517 "," in choice list.
16518
165192011-08-01 Thomas Quinot <quinot@adacore.com>
16520
16521 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
16522 explicit raise of a predefined exception as Comes_From_Source if the
16523 original N_Raise_Statement comes from source.
16524
165252011-08-01 Robert Dewar <dewar@adacore.com>
16526
16527 * sinfo.ads: Add comment.
16528 * sem_ch6.adb: Minor reformatting.
16529
165302011-08-01 Robert Dewar <dewar@adacore.com>
16531
16532 * freeze.adb (Freeze_Entity): Refine check for bad component size
16533 clause to avoid rejecting confirming clause when atomic/aliased present.
16534
165352011-08-01 Ed Schonberg <schonberg@adacore.com>
16536
16537 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
16538 better determine whether an entity reference is a write.
16539 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
16540 subcomponent.
16541 * lib-xref.adb (Output_References): Do no suppress a read reference at
16542 the same location as an immediately preceeding modify-reference, to
16543 handle properly in-out actuals.
16544
165452011-08-01 Tristan Gingold <gingold@adacore.com>
16546
16547 * env.c (__gnat_setenv) [VMS]: Refine previous change.
16548
165492011-08-01 Quentin Ochem <ochem@adacore.com>
16550
16551 * i-cstrin.adb (New_String): Changed implementation, now uses only the
16552 heap to compute the result.
16553
c7f0d2c0
AC
165542011-08-01 Robert Dewar <dewar@adacore.com>
16555
16556 * atree.ads: Minor reformatting.
16557
165582011-08-01 Emmanuel Briot <briot@adacore.com>
16559
16560 * g-expect.adb (Get_Command_Output): Fix memory leak.
16561
165622011-08-01 Geert Bosch <bosch@adacore.com>
16563
16564 * cstand.adb (P_Float_Type): New procedure to print the definition of
16565 predefined fpt types.
16566 (P_Mixed_Name): New procedure to print a name using mixed case
16567 (Print_Standard): Use P_Float_Type for printing floating point types
16568 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
16569 precision IEEE float.
16570
165712011-08-01 Thomas Quinot <quinot@adacore.com>
16572
16573 * sem_ch3.adb: Minor reformatting.
16574
165752011-08-01 Ed Schonberg <schonberg@adacore.com>
16576
16577 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
16578 the completion of a generic function, insert the new body rather than
16579 rewriting the original.
16580
165812011-08-01 Yannick Moy <moy@adacore.com>
16582
16583 * sinfo.ads, errout.ads: Typos in comments.
16584
1c54829e
AC
165852011-08-01 Robert Dewar <dewar@adacore.com>
16586
16587 * par-endh.adb: Minor reformatting.
16588
165892011-08-01 Robert Dewar <dewar@adacore.com>
16590
16591 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
16592 (Pre_Post_Aspects): New subtype.
16593 * par-ch12.adb (P_Generic): New syntax for aspects in packages
16594 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
16595 * par-ch7.adb (P_Package): Remove Decl parameter
16596 (P_Package): Handle new syntax for aspects (before IS)
16597 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
16598 new aspect syntax
16599 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
16600 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
16601 (P_Package): Remove Decl parameter
16602 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
16603 aspects
16604 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
16605 specs
16606 * sem_util.ads, sem_util.adb (Static_Boolean): New function
16607 * sinfo.ads: Document new syntax for aspects in packages etc.
16608 * sprint.adb: Handle new syntax of aspects before IS in package
16609
166102011-08-01 Thomas Quinot <quinot@adacore.com>
16611
16612 * atree.ads: Minor reformatting.
16613 * sem_prag.adb: Minor reformatting.
16614
166152011-08-01 Robert Dewar <dewar@adacore.com>
16616
16617 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
16618 case expr alternative.
16619
166202011-08-01 Ed Schonberg <schonberg@adacore.com>
16621
16622 * sem_ch12.adb: Fix typo.
16623
9eea4346
GB
166242011-08-01 Geert Bosch <bosch@adacore.com>
16625
16626 * sem_prag.adb (Check_No_Link_Name): New procedure.
16627 (Process_Import_Or_Interface): Use Check_No_Link_Name.
16628 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
16629 instead of Standard_Long_Long_Float_Size global. Preparation for
16630 eventual removal of per type constants.
16631 * exp_util.ads (Get_Stream_Size): New function returning the stream
16632 size value of subtype E.
16633 * exp_util.adb (Get_Stream_Size): Implement new function.
16634 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
16635 function.
16636 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
16637 * einfo.adb:
16638 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
16639
3d6c3bd7
GB
166402011-08-01 Geert Bosch <bosch@adacore.com>
16641
16642 * cstand.adb: Fix comments.
16643 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
16644 count of arguments.
16645
e7d897b8
AC
166462011-08-01 Robert Dewar <dewar@adacore.com>
16647
16648 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
16649
166502011-08-01 Geert Bosch <bosch@adacore.com>
16651
16652 * atree.ads: Fix comment.
16653
c228a069
AC
166542011-08-01 Robert Dewar <dewar@adacore.com>
16655
16656 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
16657 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
16658 * par.adb: Add with for Namet.Sp.
16659 * par-tchk.adb: Minor reformatting.
16660
166612011-08-01 Vincent Celier <celier@adacore.com>
16662
16663 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
16664 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
16665 of the init procedure of a SAL.
16666 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
16667 New procedure.
16668
166692011-08-01 Thomas Quinot <quinot@adacore.com>
16670
16671 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
16672 reformatting.
16673
166742011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
16675
16676 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
16677
166782011-08-01 Thomas Quinot <quinot@adacore.com>
16679
16680 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
16681 conformant with its spec (return True only for types that have
16682 an overriding Initialize primitive operation that prevents them from
16683 having preelaborable initialization).
16684 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
16685 initialization for controlled types in Ada 2005 or later mode.
16686
857ade1b
RD
166872011-08-01 Robert Dewar <dewar@adacore.com>
16688
16689 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
16690 Postcondition.
16691 (Same_Aspect): New function.
16692 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
16693 Type_Invariant, Precondition, Postcondition.
16694 * snames.ads-tmpl: Add Name_Type_Invariant.
16695
bd949ee2
RD
166962011-08-01 Robert Dewar <dewar@adacore.com>
16697
16698 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
16699 here.
16700 (Freeze_All_Ent): Fix error in handling inherited aspects.
16701 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
16702 already analyzed, but don't skip entire processing of a declaration,
16703 that's wrong in some cases of declarations being rewritten.
16704 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
16705 Don't delay for integer, string literals
16706 Treat predicates in usual manner for delay, remove special case code,
16707 not needed.
16708 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
16709 (Build_Predicate_Function): Update saved expression in aspect
16710 (Build_Invariant_Procedure): Update saved expression in aspect
16711 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
16712 of replacement of discriminant references if the reference is simple.
16713
f1c952af
RD
167142011-08-01 Robert Dewar <dewar@adacore.com>
16715
16716 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
16717 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
16718 Static_Predicate and Dynamic_Predicate.
16719 (Build_Predicate_Function): Add processing for Static_Predicate
16720 and Dynamic_Predicate.
16721 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
16722 (From_Static_Predicate): New flag
16723 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
16724
167252011-08-01 Robert Dewar <dewar@adacore.com>
16726
16727 * usage.adb: Documentation cleanup for Ada version modes in usage.
16728 * expander.adb: Minor reformatting.
16729
47e11d08
AC
167302011-08-01 Robert Dewar <dewar@adacore.com>
16731
16732 * atree.ads: Minor comment fix.
16733 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
16734 a-witeio.ads, sem_prag.adb: Minor reformatting.
16735
167362011-08-01 Doug Rupp <rupp@adacore.com>
16737
16738 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
16739 pointers. Use descrip.h header file for convenience. Add some
16740 comments.
16741
167422011-08-01 Robert Dewar <dewar@adacore.com>
16743
16744 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
16745 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
16746 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
16747 New procedure.
16748 (Check_Aspect_At_End_Of_Declarations): New procedure
16749 (Analye_Aspect_Specification): Minor changes for above procedures
16750 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
16751 specification node as well.
16752
167532011-08-01 Pascal Obry <obry@adacore.com>
16754
16755 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
16756 Windows files. Use GetFilesAttributes() in this case to check for file
16757 existence instead of returning with an error code.
16758
a3a16b21
VC
167592011-08-01 Vincent Celier <celier@adacore.com>
16760
16761 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
16762 High is above Source length.
16763
ff58cc69
RD
167642011-08-01 Robert Dewar <dewar@adacore.com>
16765
16766 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
16767
6bb88533
AC
167682011-08-01 Robert Dewar <dewar@adacore.com>
16769
16770 * aspects.ads (Boolean_Aspects): New subtype.
16771 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
16772 for derived types in cases where the parent type and derived type have
16773 aspects.
16774 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
16775 with aspects when parent type also has aspects.
16776 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
16777 boolean expression at this point).
16778 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
16779 accordance with final decision on the Ada 2012 feature.
16780 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
16781
167822011-08-01 Matthew Heaney <heaney@adacore.com>
16783
16784 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
16785
060a3f28
AC
167862011-08-01 Pascal Obry <obry@adacore.com>
16787
16788 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
16789 Fix Replace_Slice when High is above current string size.
16790 (Replace_Slice): Fix DL computation when High is above current
16791 string length.
16792
167932011-08-01 Gary Dismukes <dismukes@adacore.com>
16794
16795 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
16796
e7f567a3
AC
167972011-08-01 Matthew Heaney <heaney@adacore.com>
16798
16799 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
16800 of node.
16801
168022011-08-01 Pascal Obry <obry@adacore.com>
16803
16804 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
16805 reformatting.
16806
1a265e78
AC
168072011-08-01 Ed Schonberg <schonberg@adacore.com>
16808
16809 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
16810 access to protected subprograms in generic bodies.
16811 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
16812 protected type, indicate that the convention of the subprogram is
16813 Convention_Protected, because it may be used in subsequent declarations
16814 within the protected declaration.
16815
168162011-08-01 Vincent Celier <celier@adacore.com>
16817
16818 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
16819 and "final" procedures when the name of the library is "ada", to avoid
16820 duplicate symbols "adainit" and "adafinal" in executables.
16821
67e28ef8
ES
168222011-08-01 Ed Schonberg <schonberg@adacore.com>
16823
16824 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
16825 quantified expression that appears within a postcondition and uses the
16826 Ada2012 'Result attribute.
16827
6da2ca7d
RO
168282011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
16829
16830 * init.c (__gnat_error_handler): Cast reason to int.
16831 (__gnat_install_handler): Explain sa_sigaction use.
16832
7d5997c6
EB
168332011-07-24 Eric Botcazou <ebotcazou@adacore.com>
16834
16835 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
16836 subprogram has copy-in copy-out parameters, try to promote the mode of
16837 the return type if it is passed in registers.
16838
4b4cfdd5
EB
168392011-07-24 Eric Botcazou <ebotcazou@adacore.com>
16840
16841 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
16842 left operand as addressable.
16843
f3d34576
EB
168442011-07-24 Eric Botcazou <ebotcazou@adacore.com>
16845
16846 * gcc-interface/gigi.h (build_function_stub): Remove.
16847 (build_return_expr): Likewise.
16848 (convert_vms_descriptor): Declare.
16849 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
16850 (build_function_stub): Move to...
16851 * gcc-interface/utils2.c (build_return_expr): Move to...
16852 * gcc-interface/trans.c (build_function_stub): ...here.
16853 (build_return_expr): ...here.
16854 (Subprogram_Body_to_gnu): Add local variable for language_function.
16855 Disconnect the parameter attributes cache, if any, once done with it.
16856 Call end_subprog_body only after setting the end_locus.
16857 Build the stub associated with the function, if any, at the very end.
16858 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
16859 variables and streamline control flow.
16860
0a6ecc08
AC
168612011-07-23 Arnaud Charlet <charlet@adacore.com>
16862
16863 PR ada/49819
16864 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
16865 g-trasym-dwarf.adb.
16866
5b6d595b
RO
168672011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
16868
16869 PR bootstrap/49794
16870 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
16871 Assign to act.sa_sigaction.
16872 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
16873 current->return_address to char * before arithmetic.
16874
94017021
RO
168752011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
16876
16877 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
16878 Correct argument types.
16879 Extract code from reason.
16880 (__gnat_install_handler): Assign to act.sa_sigaction.
16881
52fd02bb
EB
168822011-07-21 Eric Botcazou <ebotcazou@adacore.com>
16883
16884 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
16885 (GNAT1_OBJS): ...here.
16886
f39a9ca2
EB
168872011-07-15 Eric Botcazou <ebotcazou@adacore.com>
16888
16889 PR ada/48711
16890 * g-socthi-mingw.adb (Fill): Fix formatting.
16891
9e36aa23
EB
16892 * gcc-interface/gigi.h: Move around comment.
16893
e3aca522
JDA
168942011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
16895
16896 PR ada/46350
16897 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
16898
696b1960
FW
168992011-07-14 Florian Weimer <fw@deneb.enyo.de>
16900
16901 PR ada/48711
16902 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
16903
f542c405
EB
169042011-07-13 Eric Botcazou <ebotcazou@adacore.com>
16905
16906 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
16907 range comparison if Pmode is SImode.
16908
9e9bd455
LG
169092011-07-12 Laurent GUERBY <laurent@guerby.net>
16910 Eric Botcazou <ebotcazou@adacore.com>
16911
16912 * adadecode.c: Wrap up in extern "C" block.
16913 * adadecode.h: Likewise.
16914 * adaint.c: Likewise. Remove 'const' keyword.
16915 * adaint.h: Likewise.
16916 * argv.c: Likewise.
16917 * atree.h: Likewise.
16918 * cio.c: Likewise.
16919 * cstreams.c: Likewise.
16920 * env.c: Likewise.
16921 * exit.c: Likewise.
16922 * fe.h: Likewise.
16923 * final.c: Likewise.
16924 * init.c: Likewise.
16925 * initialize.c: Likewise.
16926 * link.c: Likewise.
16927 * namet.h: Likewise.
16928 * nlists.h: Likewise.
16929 * raise.c: Likewise.
16930 * raise.h: Likewise.
16931 * repinfo.h: Likewise.
16932 * seh_init.c: Likewise.
16933 * targext.c: Likewise.
16934 * tracebak.c: Likewise.
16935 * uintp.h: Likewise.
16936 * urealp.h: Likewise.
16937 * xeinfo.adb: Wrap up generated C code in extern "C" block.
16938 * xsinfo.adb: Likewise.
16939 * xsnamest.adb: Likewise.
16940 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
16941 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
16942 * gcc-interface/misc.c: Likewise.
16943 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
16944 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
16945 ada/targext.o here...
16946 (GNAT_ADA_OBJS): ...and not here.
16947 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
16948 (GNATBIND_OBJS): Reorder.
16949
7644b3c7
RH
169502011-07-07 Richard Henderson <rth@redhat.com>
16951
16952 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
16953 dwarf2out_frame_init.
16954
8384ac41
EB
169552011-07-07 Eric Botcazou <ebotcazou@adacore.com>
16956
16957 * gcc-interface/misc.c (gnat_init): Tweak previous change.
16958
fbdd5d87
RO
169592011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
16960
16961 PR target/39150
16962 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
16963
1a072294
RG
169642011-07-06 Richard Guenther <rguenther@suse.de>
16965
8384ac41
EB
16966 * gcc-interface/misc.c (gnat_init): Merge calls to
16967 build_common_tree_nodes and build_common_tree_nodes_2.
1a072294
RG
16968 Re-initialize boolean_false_node.
16969
bc712852
EB
169702011-07-02 Eric Botcazou <ebotcazou@adacore.com>
16971 Olivier Hainque <hainque@adacore.com>
16972 Nicolas Setton <setton@adacore.com>
16973
16974 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
16975 the type according to the ARTIFICIAL_P parameter.
16976 (create_type_decl): Likewise.
16977 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
16978
2eb22389
EB
169792011-07-01 Eric Botcazou <ebotcazou@adacore.com>
16980
16981 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
16982 (gnatbind): Likewise.
16983
4bdaaf2f
RO
169842011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
16985
16986 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
16987
c020c92b
EB
169882011-06-18 Eric Botcazou <ebotcazou@adacore.com>
16989
16990 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
16991 local variable throughout. Remove useless call to Base_Type.
16992 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
16993 Take it also into account for the volatileness of the field. Set the
16994 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
16995
96769d32
EB
169962011-06-18 Eric Botcazou <ebotcazou@adacore.com>
16997
16998 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
16999 on a dereference built for a by-ref object if it has an address clause.
17000
7e4680c1
EB
170012011-06-18 Eric Botcazou <ebotcazou@adacore.com>
17002
17003 * einfo.ads (Address_Taken): Document use for the second argument of
17004 Asm_Input and Asm_Output attributes.
17005 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
17006 argument is an entity name, then set Address_Taken on it.
17007 <Attribute_Asm_Output>: Likewise.
17008 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
17009 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
17010 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
17011 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
17012
170132011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
d5cc9181
JR
17014
17015 PR middle-end/46500
17016 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
17017
677f3fa8
JM
170182011-06-14 Joseph Myers <joseph@codesourcery.com>
17019
17020 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
17021 (ada/utils.o): Update dependencies.
17022 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
17023 ../../../libcpp/libcpp.a.
17024 * gcc-interface/utils.c: Include common/common-target.h.
17025 (process_attributes): Use targetm_common.have_named_sections.
17026
009db074
RG
170272011-06-07 Richard Guenther <rguenther@suse.de>
17028
0bad0e23
EB
17029 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
17030 set_sizetype.
009db074 17031
3bfc61cf
EB
170322011-06-06 Eric Botcazou <ebotcazou@adacore.com>
17033
0bad0e23 17034 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
3bfc61cf
EB
17035 TREE_THIS_NOTRAP flag.
17036
5c4a1c7b
EB
170372011-06-06 Eric Botcazou <ebotcazou@adacore.com>
17038
17039 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
17040 Fix thinko.
17041
e9f57686
EB
170422011-06-06 Eric Botcazou <ebotcazou@adacore.com>
17043
17044 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
17045 constants whose full view has discriminants specially.
17046
10e4d056
EB
170472011-06-06 Eric Botcazou <ebotcazou@adacore.com>
17048
17049 * gcc-interface/utils.c: Include diagnostic.h.
17050 (gnat_write_global_declarations): Output debug information for all
17051 global type declarations before finalizing the compilation unit.
17052 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
17053
0957c029
JJ
170542011-05-25 Jakub Jelinek <jakub@redhat.com>
17055
17056 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
17057
52d0a7ac
KT
170582011-05-25 Kai Tietz <ktietz@redhat.com>
17059
17060 * adaint.c (__gnat_to_canonical_file_list_next): Use array
17061 initialization instead of const/none-const pointer assignment.
17062
1ed1641d
JM
170632011-05-24 Joseph Myers <joseph@codesourcery.com>
17064
17065 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
17066 $(EXTRA_GNAT1_OBJS).
17067 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
17068 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
17069 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
17070 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
17071 libcommon-target.a instead of prefix.o.
17072
9fe72ebd
JM
170732011-05-21 Joseph Myers <joseph@codesourcery.com>
17074
17075 PR ada/49097
0bad0e23 17076 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
9fe72ebd 17077
2691e6d7
JM
170782011-05-20 Joseph Myers <joseph@codesourcery.com>
17079
0bad0e23
EB
17080 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
17081 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
17082 instead of version.o.
2691e6d7 17083
2d0dd51a 170842011-05-18 Kai Tietz <ktietz@redhat.com>
bf6490b5
KT
17085
17086 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
17087 boolean_false_node instead of integer_zero_node.
17088 (convert_with_check): Likewise.
17089 * gcc-interface/decl.c (choices_to_gnu): Likewise.
17090
7bf9a5ac
EB
170912011-05-12 Eric Botcazou <ebotcazou@adacore.com>
17092
17093 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
17094 type of the parameter is an unconstrained array, convert the actual to
17095 the type of the formal in the In Out and Out cases as well.
17096
e5b00edf
NF
170972011-05-11 Nathan Froyd <froydnj@codesourcery.com>
17098
17099 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
17100 call build_function_type_array or build_varargs_function_type_array
17101 instead.
17102 (create_subprog_type): Don't call build_function_type; call
17103 build_function_type_vec instead.
17104
51545682
NF
171052011-05-11 Nathan Froyd <froydnj@codesourcery.com>
17106
17107 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
17108 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
17109 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
17110
c99c0026
EB
171112011-05-07 Eric Botcazou <ebotcazou@adacore.com>
17112
f620bd21
EB
17113 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
17114
c99c0026
EB
17115 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
17116 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
17117
3d528853
NF
171182011-05-05 Nathan Froyd <froydnj@codesourcery.com>
17119
c99c0026 17120 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
3d528853 17121
d7d058c5
NF
171222011-05-05 Nathan Froyd <froydnj@codesourcery.com>
17123
17124 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
17125 instead of accessing TYPE_ARG_TYPES directly.
17126 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
17127
805e60a0
EB
171282011-05-05 Eric Botcazou <ebotcazou@adacore.com>
17129
17130 PR ada/48844
17131 * gcc-interface/gigi.h (get_variant_part): Declare.
17132 * gcc-interface/decl.c (get_variant_part): Make global.
17133 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
17134 types have the same constant size, are record types and T1 has a
17135 variant part while T2 doesn't.
17136
907a08d9
EB
171372011-05-05 Eric Botcazou <ebotcazou@adacore.com>
17138
17139 * gcc-interface/utils.c (begin_subprog_body): Do not call
17140 get_pending_sizes.
17141 (end_subprog_body): Likewise.
17142
d35936ab
RG
171432011-05-04 Richard Guenther <rguenther@suse.de>
17144
17145 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
17146 int_const_binop.
17147 (pos_to_constructor): Likewise.
17148
c1fd8753 171492011-05-03 Nathan Froyd <froydnj@codesourcery.com>
2c7f9cc0 17150 Eric Botcazou <ebotcazou@adacore.com>
c1fd8753
NF
17151
17152 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
17153 of build_function_type. Adjust calls to...
17154 (build_raise_check): ...this. Do not take a void_tree parameter.
17155 Call build_function_type_list instead of build_function_type.
17156 Fix head comment and swap couple of conditional blocks.
17157
4fb87d2b
EB
171582011-04-30 Eric Botcazou <ebotcazou@adacore.com>
17159
17160 * gnatvsn.ads (Library_Version): Bump to 4.7.
17161 (Current_Year): Bump to 2011.
17162
fa5e5a76
MM
171632011-04-29 Michael Matz <matz@suse.de>
17164
17165 * gcc-interface/misc.c (gnat_handle_option): Set
17166 warn_maybe_uninitialized.
17167
8d6a2f69
GP
171682011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
17169
17170 * gnat_ugn.texi (Complexity Metrics Control): Update link to
17171 the Watson/McCabe paper.
17172
770937fd
JM
171732011-04-23 Jim Meyering <meyering@redhat.com>
17174
17175 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
17176
eb601ae1
EB
171772011-04-22 Eric Botcazou <ebotcazou@adacore.com>
17178
17179 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
17180 onto the new type.
17181
7d7fcb08
EB
171822011-04-22 Eric Botcazou <ebotcazou@adacore.com>
17183
17184 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
17185 parameter.
17186 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
17187 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
17188 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
17189 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
17190 <all>: Do not set flags on the reused DECL node coming from an alias.
17191 Set DECL_IGNORED_P on the DECL node built for subprograms if they
17192 don't need debug info here...
17193 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
17194 (gigi): Adjust calls to create_subprog_decl.
17195 (build_raise_check): Likewise.
17196 (establish_gnat_vms_condition_handler): Likewise.
17197 (Compilation_Unit_to_gnu): Likewise.
17198 (gnat_to_gnu): Likewise.
17199
e1876cac
EB
172002011-04-21 Eric Botcazou <ebotcazou@adacore.com>
17201
17202 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
17203 (NO_REORDER_ADAFLAGS): New variable.
17204 (EXTRA_GNATTOOLS): Always define.
17205 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
17206 Clean up and adjust list of files compiled with special options.
17207 * gcc-interface/Make-lang.in: Likewise.
17208 (ada/decl.o): Cosmetical change.
17209 (ada/misc.o): Remove dependency on $(PLUGIN_H).
17210
04695783
JM
172112011-04-20 Jim Meyering <meyering@redhat.com>
17212
17213 * initialize.c (__gnat_initialize): Remove useless if-before-free.
17214
23399579
EB
172152011-04-17 Eric Botcazou <ebotcazou@adacore.com>
17216
17217 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
17218 $(CFLAGS) on the link line.
17219
51c5169c
EB
172202011-04-17 Eric Botcazou <ebotcazou@adacore.com>
17221
17222 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
17223 padded type built for the return type if it is unconstrained.
17224
61e46a7d
NF
172252011-04-14 Nathan Froyd <froydnj@codesourcery.com>
17226
17227 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
17228
81f653d6
NF
172292011-04-12 Nathan Froyd <froydnj@codesourcery.com>
17230
b4867846
EB
17231 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
17232 before calling TREE_CHAIN.
81f653d6
NF
17233 * gcc-interface/misc.c (gnat_init_ts): New function.
17234 (LANG_HOOKS_INIT_TS): Define.
17235
a358e188
MJ
172362011-04-12 Martin Jambor <mjambor@suse.cz>
17237
b4867846
EB
17238 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
17239 instead of cgraph_node.
a358e188 17240
29b1c5a4
EB
172412011-04-08 Eric Botcazou <ebotcazou@adacore.com>
17242
17243 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
17244 alignment on fields of the RETURN type built for the Copy-In Copy-Out
17245 mechanism.
17246
88872b00
EB
172472011-04-08 Eric Botcazou <ebotcazou@adacore.com>
17248
17249 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
17250 of aggregate types that contain a placeholder.
17251
dcf0c47e
NF
172522011-04-08 Nathan Froyd <froydnj@codesourcery.com>
17253
17254 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
b4867846 17255 TYPE_ARG_TYPES.
dcf0c47e
NF
17256 (handle_type_generic_attribute): Likewise.
17257
53e3000c
EB
172582011-04-04 Eric Botcazou <ebotcazou@adacore.com>
17259
17260 PR ada/47163
17261 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
17262
ab380bb4
KT
172632011-04-04 Kai Tietz <ktietz@redhat.com>
17264
17265 PR ada/47163
0bad0e23
EB
17266 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
17267 to flag value.
ab380bb4 17268
8ffac116
EB
172692011-04-02 Eric Botcazou <ebotcazou@adacore.com>
17270
17271 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
17272 type case, do not strip a padding type around the array type.
17273
de9528f0
EB
172742011-04-02 Eric Botcazou <ebotcazou@adacore.com>
17275
17276 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
17277 types.
17278
d9d7a26c
EB
172792011-04-02 Eric Botcazou <ebotcazou@adacore.com>
17280
17281 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
17282 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
de9528f0 17283 code for -feliminate-unused-debug-types.
d9d7a26c
EB
17284 (gnat_post_options): Likewise.
17285
4cb12a90
EB
172862011-04-02 Eric Botcazou <ebotcazou@adacore.com>
17287
17288 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
17289 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
17290 distinct copy.
17291
acccc61c
EB
172922011-04-02 Eric Botcazou <ebotcazou@adacore.com>
17293
17294 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
17295 DECL_ARTIFICIAL flag on enumeration types.
17296
583eb0c9
EB
172972011-04-02 Eric Botcazou <ebotcazou@adacore.com>
17298
17299 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
17300 fat pointer types artificial unconditionally.
17301 <E_Array_Subtype>: Attach the base array type as a parallel type if it
17302 isn't artificial.
17303
e3edbd56
EB
173042011-04-02 Eric Botcazou <ebotcazou@adacore.com>
17305
17306 * gcc-interface/gigi.h (get_dummy_type): Declare.
17307 (build_dummy_unc_pointer_types): Likewise.
17308 (finish_fat_pointer_type): Likewise.
17309 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
17310 fat pointer type has been built, complete it in place.
17311 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
17312 and thin pointers. Remove useless variable.
17313 (finish_fat_pointer_type): Make global and move to...
17314 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
17315 (get_dummy_type): New function.
17316 (build_dummy_unc_pointer_types): Likewise.
17317 (gnat_pushdecl): Propage the name to the anonymous variants only.
17318 (update_pointer_to): Only adjust the pointer types in the unconstrained
17319 array case.
17320
65444786
EB
173212011-04-02 Eric Botcazou <ebotcazou@adacore.com>
17322
17323 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
17324 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
17325 if this is a Taft amendment type and the full declaration is available.
17326 * gcc-interface/trans.c (process_type): Likewise.
17327 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
17328 (process_freeze_entity): Likewise.
17329 * gcc-interface/utils.c (dummy_global): New static variable.
17330 (gnat_write_global_declarations): If there are types declared as used
17331 at the global level, insert them in the global hash table.
17332
1aeb40dd
EB
173332011-04-02 Eric Botcazou <ebotcazou@adacore.com>
17334
17335 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
17336 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
17337 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
17338 copy.
17339 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
17340 flag of the type accordingly.
17341 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
17342
80ec8b4c
EB
173432011-04-02 Eric Botcazou <ebotcazou@adacore.com>
17344
17345 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
17346 finalizing types when updating the pointers to the designated type.
17347 <all>: Finalize the deferred types even if we didn't defer processing
17348 of incomplete types in this invocation.
17349
2a9d769a 173502011-04-01 Olivier Hainque <hainque@adacore.com>
2c7f9cc0
AS
17351 Nicolas Setton <setton@adacore.com>
17352 Eric Botcazou <ebotcazou@adacore.com>
2a9d769a
OH
17353
17354 * gcc-interface/misc.c (gnat_descriptive_type): New function.
17355 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
17356
2438d7a6
KT
173572011-03-28 Kai Tietz <ktietz@redhat.com>
17358
333d8aff 17359 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
80ec8b4c
EB
17360 Windows targets.
17361 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
17362 * system-mingw.ads (System): Change ZCX_By_Default default to True.
333d8aff 17363
80ec8b4c 17364 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
2438d7a6 17365
8ad150f6
TG
173662011-03-28 Tristan Gingold <gingold@adacore.com>
17367
17368 PR ada/44431
80ec8b4c
EB
17369 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
17370 Use ada output of gnatbind.
8ad150f6
TG
17371 (ada/b_gnatb.adb): Ditto.
17372 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
17373 (ada.mostlyclean, ada.stage1)
17374 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
17375 (ada.stagefeedback): Adjust.
80ec8b4c 17376 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
8ad150f6
TG
17377 Use ada output of gnatbind.
17378 (b_gnatm.adb): Ditto.
17379 (b_gnatl.o, b_gnatm.o): New rules.
17380
51c7954d
EB
173812011-03-26 Eric Botcazou <ebotcazou@adacore.com>
17382
17383 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
17384 for the padded type built to support a specified size or alignment.
17385
6ddf9843
EB
173862011-03-26 Eric Botcazou <ebotcazou@adacore.com>
17387
17388 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
17389 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
17390 unconditionally to the end of the unit when the designated type is
17391 limited_with'ed.
17392 <all>: Rename local variable. Attempt to un-defer types only and do it
17393 for limited_with'ed types as well.
17394 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
17395 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
17396 consistently and remove redundant call to finalize_from_with_types.
17397
5daed84a
EB
173982011-03-26 Eric Botcazou <ebotcazou@adacore.com>
17399
17400 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
17401 subprograms without a previous spec declared in the same unit.
17402 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
17403 subprograms at the end of the unit instead of at the beginning.
17404 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
17405 isn't public for the special handling of non-inline functions nested
17406 inside inline external functions.
17407
0edf1bb2
JL
174082011-03-25 Jeff Law <law@redhat.com>
17409
5daed84a 17410 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
0edf1bb2 17411
e3c4580e
EB
174122011-03-24 Eric Botcazou <ebotcazou@adacore.com>
17413
17414 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
17415 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
17416 to compute Set_Size_Depends_On_Discriminant.
17417 (Layout_Type): Call it on array types in back-end layout mode.
17418 * sem_util.adb (Requires_Transient_Scope): Return true for array
17419 types only if the size depends on the value of discriminants.
17420 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
17421 type if the RHS is a call to a function that returns an unconstrained
17422 type with default discriminant.
17423
abbc8c7b
EB
174242011-03-24 Eric Botcazou <ebotcazou@adacore.com>
17425
17426 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
17427 non-conversion to the nominal result type at the end.
17428
ddb5a105
EB
174292011-03-23 Eric Botcazou <ebotcazou@adacore.com>
17430
17431 * gcc-interface/trans.c (create_temporary): New function taken from...
17432 (create_init_temporary): ...here. Call it.
17433 (call_to_gnu): Create the temporary for the return value early, if any.
17434 Create it for a function with copy-in/copy-out parameters if there is
17435 no target; in other cases of copy-in/copy-out, use another temporary.
17436 Push the new binding level lazily. Add and rename local variables.
17437
0d853156
EB
174382011-03-23 Eric Botcazou <ebotcazou@adacore.com>
17439
17440 * gcc-interface/decl.c (validate_size): Improve comments and tweak
17441 error message.
17442 (set_rm_size): Likewise.
17443
4184ef1b
EB
174442011-03-23 Eric Botcazou <ebotcazou@adacore.com>
17445
17446 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
17447 for the padded type built in order to support a specified alignment.
17448 Fix incorrect formatting.
17449
bf7eefab
EB
174502011-03-21 Eric Botcazou <ebotcazou@adacore.com>
17451
17452 PR bootstrap/48216
17453 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
17454
ef0feeb2
EB
174552011-03-21 Eric Botcazou <ebotcazou@adacore.com>
17456
17457 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
17458 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
17459 to the end of the list. Adjust recursive call. Rename local variable.
17460 If REORDER is true, reorder components of the record type.
17461 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
17462 components_to_record and adjust the parameter list.
17463
646f9414
EB
174642011-03-21 Eric Botcazou <ebotcazou@adacore.com>
17465
17466 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
17467 disabled, use the variable for bounds of loop iteration scheme.
17468
62d784f7
KT
174692011-03-21 Kai Tietz <ktietz@redhat.com>
17470
17471 PR target/12171
0bad0e23 17472 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
62d784f7 17473
f230d759
EB
174742011-03-17 Eric Botcazou <ebotcazou@adacore.com>
17475
17476 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
17477 out whether the expression is read-only. Short-circuit placeholder
17478 case and rename a couple of local variables.
17479
bb1f7929
EB
174802011-03-17 Eric Botcazou <ebotcazou@adacore.com>
17481
17482 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
17483 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
17484 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
17485 (convert): Deal with conversions from a smaller form type specially.
17486
400a2d24
EB
174872011-02-14 Eric Botcazou <ebotcazou@adacore.com>
17488
17489 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
17490 its argument, except for the special -I- switch.
17491
c26bc3ad
GP
174922011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
17493
0bad0e23
EB
17494 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
17495 "Ada Issues".
c26bc3ad 17496
07b8e910
EB
174972011-02-08 Eric Botcazou <ebotcazou@adacore.com>
17498
17499 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
17500
31a5a547
EB
175012011-02-03 Eric Botcazou <ebotcazou@adacore.com>
17502
17503 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
17504 GNAT_FORMAL.
17505 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
17506 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
17507 instead of GNAT_FORMAL. Protect the expression against multiple uses.
17508 Do not generate the check directly, instead instantiate the template
17509 check present in the descriptor.
17510 (make_descriptor_field): Move around.
17511 (build_vms_descriptor32): Build a template check in the POINTER field.
17512 (build_vms_descriptor): Remove useless suffixes.
17513 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
17514
dcf25f59
EB
175152011-01-26 Eric Botcazou <ebotcazou@adacore.com>
17516
17517 PR bootstrap/47467
17518 * targext.c: Include target files if IN_RTS is defined.
17519
0418e131
RG
175202011-01-26 Richard Guenther <rguenther@suse.de>
17521
17522 PR bootstrap/47467
17523 * targext.c: Include config.h.
17524 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
17525 dependency.
17526
c6eecbd8 175272011-01-04 Pascal Obry <obry@adacore.com>
2c7f9cc0 17528 Eric Botcazou <ebotcazou@adacore.com>
c6eecbd8
PO
17529
17530 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
17531
2d3c7e4f
EB
175322011-01-04 Eric Botcazou <ebotcazou@adacore.com>
17533
17534 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
17535 end-of-case on the end label and its associated gotos, if any.
17536
0394741f
EB
175372011-01-04 Eric Botcazou <ebotcazou@adacore.com>
17538
17539 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
17540 expressions of the parameter cache within the statement group of
17541 the CICO mechanism.
17542
2a02d090 175432011-01-04 Olivier Hainque <hainque@adacore.com>
2c7f9cc0 17544 Eric Botcazou <ebotcazou@adacore.com>
2a02d090
OH
17545
17546 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
17547 (set_end_locus_from_node): New function.
17548 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
17549 make and the function end_locus.
17550 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
17551 for the elaboration subprogram.
17552 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
17553 set the end_locus of the expression as well.
17554
89f5e978
EB
175552011-01-04 Eric Botcazou <ebotcazou@adacore.com>
17556
17557 PR ada/47131
17558 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
17559 variables that are referenced in exception handlers volatile.
17560
17561
ad41bd84 17562\f
797103eb 17563Copyright (C) 2011 Free Software Foundation, Inc.
ad41bd84
JM
17564
17565Copying and distribution of this file, with or without modification,
17566are permitted in any medium without royalty provided the copyright
17567notice and this notice are preserved.
This page took 2.707011 seconds and 5 git commands to generate.