]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/ada/ChangeLog
[multiple changes]
[thirdparty/gcc.git] / gcc / ada / ChangeLog
CommitLineData
0db16b1e
AC
12011-08-29 Robert Dewar <dewar@adacore.com>
2
3 * a-synbar.ads, a-synbar.adb, a-synbar-posix.adb,
4 a-synbar-posix.ads: Minor reformatting.
5
62011-08-29 Yannick Moy <moy@adacore.com>
7
8 * snames.ads-tmpl: Add name Force.
9
978ffe02
AC
102011-08-29 Pascal Obry <obry@adacore.com>
11
12 * prj-nmsc.adb: Minor reformatting.
13
142011-08-29 Jose Ruiz <ruiz@adacore.com>
15
16 * a-exetim.ads (Interrupt_Clocks_Supported,
17 Separate_Interrupt_Clocks_Supported, Clock_For_Interrupts): Add these
18 definitions to be compliant with AI-0171.
19
202011-08-29 Robert Dewar <dewar@adacore.com>
21
22 * a-ngelfu.adb: Add comments.
23
718f39dc
AC
242011-08-29 Geert Bosch <bosch@adacore.com>
25
26 * a-ngelfu.adb (Tan): Do not raise Constraint_Error if the argument is
27 the closest machine number to Pi / 2.0.
28
292011-08-29 Jose Ruiz <ruiz@adacore.com>
30
31 * impunit.adb (Non_Imp_File_Names_12): Add a-synbar for new Ada 2012
32 package Ada.Synchronous_Barriers.
33 * a-synbar.ads, a-synbar.adb, a-synbar-posix.ads, a-synbar-posix.adb:
34 Add new specs and bodies for Ada.Synchronous_Barriers. There is a
35 default implementation using protected objects and another one
36 a-synbar-posix using POSIX barriers as the underlying support.
37 * gcc-interface/Makefile.in (LIBGNAT_TARGET_PAIRS for Linux (x86,
38 x86_64, ia64) and MIPS IRIX): Use the a-synbar-posix implementation of
39 Ada.Synchronous_Barriers which uses POSIX barriers (more efficient).
40 Clean up dependencies.
41 * Makefile.rtl (GNATRTL_TASKING_OBJS): Add a-synbar.o
42
ee2e3f6b
AC
432011-08-29 Robert Dewar <dewar@adacore.com>
44
45 * sem_ch7.adb, make.adb, sem_res.adb, exp_intr.adb,
46 exp_dist.adb: Minor code reorganization.
47 Minor reformatting.
48
492011-08-29 Thomas Quinot <quinot@adacore.com>
50
51 * sem_cat.adb (Validate_RACW_Primitive): The return type of an RACW
52 primitive operation must support external streaming if it is not a
53 controlling access result.
54
646e2823
AC
552011-08-29 Thomas Quinot <quinot@adacore.com>
56
57 * sinfo.ads, sem_ch7.adb: Minor reformatting.
58
592011-08-29 Bob Duff <duff@adacore.com>
60
61 * sem_ch4.adb (Analyze_Allocator): Check No_Nested_Finalization
62 restriction on allocators, as required by AI05-0013-1.
63 * restrict.ads: Minor comment fix.
64
5d59eef2
AC
652011-08-29 Tristan Gingold <gingold@adacore.com>
66
67 * a-exexpr.adb, a-except-2005.ads (Jmpbuf_Address): Move to a-exexpr.adb
68 (To_Jmpbuf_Address): Ditto
69 (builtin_longjmp): Ditto
70
712011-08-29 Thomas Quinot <quinot@adacore.com>
72
73 * sem_res.adb: Minor reformatting.
74
752011-08-29 Vincent Celier <celier@adacore.com>
76
77 * make.adb (Gnatmake): Move special processing for VM targets after the
78 call to Get_Target_Parameters.
79
802011-08-29 Thomas Quinot <quinot@adacore.com>
81
82 * sem_ch12.adb, par-ch12.adb: Minor reformatting.
83
949a18cc
AC
842011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
85
86 * sem_res.adb (Resolve_Allocator): Implement Ada2012-B052. Detect cases
87 where an anonymous access discriminant of a limited designated type
88 appears in a non-immutably limited discriminated type and issue an
89 error message. Add local variable Desig_T and replace all occurrences
90 of Designated_Type.
91
922011-08-29 Jose Ruiz <ruiz@adacore.com>
93
94 * a-rttiev.adb (Set_Handler): Update comment to indicate that our
95 implementation is compliant to RM D.15(15/2) after the modification
96 imposed by AI05-0094-1 (binding interpretation).
97
cb25faf8
AC
982011-08-29 Robert Dewar <dewar@adacore.com>
99
100 * exp_ch9.adb, s-tasren.adb, exp_sel.adb, exp_sel.ads, exp_ch11.adb,
101 s-interr-hwint.adb, s-tpobop.adb, sem_ch13.adb: Minor reformatting.
102
1032011-08-29 Thomas Quinot <quinot@adacore.com>
104
105 * par-endh.adb (Check_End): For an END where it is mandatory to repeat
106 the scope name, do not report a missing label as a style violation (it
107 will be diagnosed as an illegality).
108 * exp_dist.adb (Add_Params_For_Variant_Components): Fix handling of
109 variant records: Get_Enum_Lit_From_Pos already returns a usage
110 occurrence of the literal, no need to use New_Occurrence_Of. Set Etype
111 on Expr in Integer_Literal case so that it can be used by
112 Build_To_Any_Call.
113
1d10f669
AC
1142011-08-29 Tristan Gingold <gingold@adacore.com>
115
116 * exp_sel.ads (Build_Abort_BLock_Handler): New function spec.
117 Adjust comment.
118 * exp_sel.adb (Build_Abort_Block): Use Build_Abort_Block_Handler.
119 (Build_Abort_Block_Handler): New function to build an Abort_Signal
120 exception handler.
121 * exp_ch9.adb (Expand_N_Asynchronous_Select): Call
122 Build_Abort_Block_Handler to build the exception handler. Do not
123 undefer aborts for the Abort_Signal exception handler if back-end
124 exception mechanism.
125 * exp_ch11.adb (Expand_Exception_Handlers): Do not undefer aborts if
126 back_end exceptions for all others and abort_signal.
127 * s-except.ads (ZCX_By_Default): New constant.
128 * a-except-2005.adb (Raise_Exception): Do not defer abort if ZCX.
129 (Raise_Exception_Always): Ditto.
130 (Raise_From_Signal_Handler): Ditto.
131 (Raise_With_Location_And_Msg): Ditto.
132 (Raise_With_Msg): Ditto.
133 (Reraise): Ditto.
134 (Reraise_Occurence): Ditto.
135 (Reraise_Occurrence_Always): Ditto.
136 * s-tasren.adb (Exceptional_Complete_Rendezvous): Defer aborts if ZCX.
137 * s-tpobop.adb: (Exceptional_Complete_Body): Undefer abort if ZCX.
1d10f669
AC
138
1392011-08-29 Thomas Quinot <quinot@adacore.com>
140
141 * sem_util.ads (Get_Enum_Lit_From_Pos): Clarify documentation.
142
d986066d
AC
1432011-08-29 Robert Dewar <dewar@adacore.com>
144
145 * snames.adb-tmpl, sem_ch13.adb: Minor reformatting
146 Minor code reorganization.
147
1482011-08-29 Bob Duff <duff@adacore.com>
149
150 * usage.adb (-gnatwy): Fix documentation: this switch applies to Ada
151 2012, not just Ada 2005.
152
1532011-08-29 Vincent Celier <celier@adacore.com>
154
155 * gnat_ugn.texi: Indicate that when the compiler is called by gnatmake
156 with a project file or with gprbuid, if -gnatep= is specified, the
157 builder may need to be invoked with -x.
158
1592011-08-29 Tristan Gingold <gingold@adacore.com>
160
161 * a-exexpr-gcc.adb: Minor comment fix.
162
ff4f0ed0
AC
1632011-08-29 Robert Dewar <dewar@adacore.com>
164
165 * sem_ch8.adb: Minor reformatting.
166
1672011-08-29 Bob Duff <duff@adacore.com>
168
169 * par-ch2.adb (P_Identifier): Warn that "some" is reserved in Ada 2012.
170 * par-ch4.adb (P_Quantified_Expression): Remove unnecessary code for
171 treating "some" as unreserved in earlier Ada versions. This is now
172 handled in Snames.Is_Keyword_Name. Parse "for some" using Tok_Some,
173 rather than Name_Some, since Tok_Some is now recognized as reserved.
174 * scans.adb (Initialize_Ada_Keywords): Handle Tok_Some like any other
175 reserved word.
176 * scans.ads: Minor comment fixes.
177 * snames.adb-tmpl (Is_Keyword_Name): Handle Ada 2012 reserved words as
178 for other language versions.
179 * scn.adb (Scan_Reserved_Identifier): Remove unnecessary code for
180 treating "some" as unreserved in earlier Ada versions. This is now
181 handled in Snames.Is_Keyword_Name.
182 * par-ch3.adb (P_Defining_Identifier): Warn that "some" is reserved in
183 Ada 2012.
184 (P_Subtype_Mark_Resync): Remove unnecessary code for treating "some" as
185 unreserved in earlier Ada versions. This is now handled in
186 Snames.Is_Keyword_Name.
187 * snames.ads-tmpl (Ada_2012_Reserved_Words): Handle Ada 2012 reserved
188 words as for other language versions.
189 * gnat_ugn.texi (-gnatwy): Fix documentation: this switch applies to
190 Ada 2012, not just Ada 2005.
191
d941cee6
AC
1922011-08-29 Ed Schonberg <schonberg@adacore.com>
193
194 * sem_ch13.adb: Additional semantic checks for aspects involved in
195 iterators.
196
1972011-08-29 Matthew Heaney <heaney@adacore.com>
198
199 * a-comutr.ads, a-comutr.adb, a-cimutr.ads, a-cimutr.adb,
200 a-cbmutr.ads, a-cbmutr.adb (Find_In_Subtree): Remove superfluous
201 Container parameter.
202 (Ancestor_Find): ditto.
203
b970af39
TQ
2042011-08-29 Thomas Quinot <quinot@adacore.com>
205
206 * par-endh.adb: Minor reformatting.
d941cee6 207
92db5dee
AC
2082011-08-29 Tristan Gingold <gingold@adacore.com>
209
210 * a-exexpr-gcc.adb (Unwind_Action) Rewrite as an integer with constants.
211 (GNAT_GCC_Exception): Remove N_Cleanups_To_Trigger component.
212 (Adjust_N_CLeanups_For): Remove.
213 (CleanupUnwind_Handler): Call Unhandled_Exception_Terminate when end of
214 stack is reached.
215 (Propgate_Exception): Adjust.
216 * raise-gcc.c: Add a few static/const.
217 (Adjust_N_Cleanups_For): Remove declaration.
218 (PERSONALITY_FUNCTION): Remove code dealing with N_Cleanups_To_Trigger.
219
2202011-08-29 Ed Schonberg <schonberg@adacore.com>
221
222 * sem_ch8.adb: Use type of function return when rewriting as object
223 declaration.
224
1378bf10
AC
2252011-08-29 Gary Dismukes <dismukes@adacore.com>
226
227 * sem_type.adb: Minor reformatting.
228
2292011-08-29 Robert Dewar <dewar@adacore.com>
230
231 * makeutl.adb: Minor reformatting.
232
2332011-08-29 Ed Schonberg <schonberg@adacore.com>
234
235 * sem_ch8.adb (Analyze_Object_Renaming): If the renamed object is a
236 function call of a limited type, the expansion of the renaming is
237 complicated by the presence of various temporaries and subtypes that
238 capture constraints of the renamed object.
239 Rewrite node as an object declaration, whose expansion is simpler.
240 Given that the object is limited there is no copy involved and no
241 performance hit.
242
164e06c6
AC
2432011-08-29 Robert Dewar <dewar@adacore.com>
244
245 * exp_ch5.adb, sinfo.ads, make.adb, s-pooglo.adb, sem_ch12.adb,
246 freeze.adb, sem_ch6.adb, par-ch12.adb: Minor reformatting.
247
2482011-08-29 Tristan Gingold <gingold@adacore.com>
249
250 * system-darwin-x86.ads, system-linux-s390x.ads, system-linux-alpha.ads,
251 system-tru64.ads, system-irix-n32.ads, system-vxworks-arm.ads,
252 system-linux-hppa.ads, system-linux-s390.ads,
253 system-solaris-sparcv9.ads, system-mingw.ads, system-linux-ia64.ads,
254 system-vms_64.ads, system-vxworks-sparcv9.ads, system-linux-ppc.ads,
255 system-aix64.ads, system-lynxos-ppc.ads, system-linux-sh4.ads,
256 system-solaris-x86.ads, system-linux-x86_64.ads, system-linux-x86.ads,
257 system-vxworks-ppc.ads, system-hpux.ads, system-darwin-ppc.ads,
258 system-solaris-sparc.ads, system-lynxos-x86.ads,
259 system-vxworks-m68k.ads, system-hpux-ia64.ads, system-irix-o32.ads,
260 system-solaris-x86_64.ads, system-mingw-x86_64.ads,
261 system-vxworks-mips.ads, system-linux-sparc.ads, system-vms-ia64.ads,
262 system-freebsd-x86.ads, system-aix.ads, system-darwin-x86_64.ads,
263 system-vxworks-x86.ads: Remove GCC_ZCX_Support
264 * s-taprop-posix.adb, s-taprop-irix.adb, s-taprop-vxworks.adb,
265 s-taprop-tru64.adb, s-taprop-linux.adb, s-taprop-solaris.adb: Ditto.
266 * opt.ads: Adjust comment.
267 * targparm.ads, targparm.adb: Remove GCC_ZCX_Support_On_Target.
268 * gnat1drv.adb: Do not check for GCC_ZCX_Support_On_Target.
269 * system.ads: Move GCC_ZCX_Support to obsolete entries.
270
2712011-08-29 Emmanuel Briot <briot@adacore.com>
272
273 * makeutl.adb (Do_Complete): Resolve symbolic links when a relative
274 file name is specified on the gnatmake or gprbuild command line, and
275 before we search for that file in the project.
276
2772011-08-29 Ed Schonberg <schonberg@adacore.com>
278
279 * sem_type.adb (Within_Instance): New predicate in Collect_Interps,
280 used to determine whether a possible interpretation for an overloadable
281 entity is declared within the current instantiation and should be
282 included in the candidate set.
283
2842011-08-29 Vasiliy Fofanov <fofanov@adacore.com>
285
286 * gnat_rm.texi, gnat_ugn.texi: Clean ups.
287
97216ca8
ES
2882011-08-29 Ed Schonberg <schonberg@adacore.com>
289
290 * sem_res.adb (Resolve_Actuals): Use base type to determine whether an
291 access subtype is access_to_subprogram, when applying checks for
292 RM 3.10.2 (27).
293
d3cb4cc0
AC
2942011-08-29 Matthew Heaney <heaney@adacore.com>
295
296 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Splice_Subtree): Only check
297 for sibling when common parent.
298
2992011-08-29 Thomas Quinot <quinot@adacore.com>
300
301 * get_scos.adb: Literals of Pragma_Id are pragma names prefixed with
302 "pragma_".
303
3042011-08-29 Ed Schonberg <schonberg@adacore.com>
305
306 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Enable freeze actions
307 for the return type when in ASIS mode.
308
3092011-08-29 Vincent Celier <celier@adacore.com>
310
311 * make.adb (Gnatmake): Get the default search dirs, then the target
312 parameters after getting the Builder switches, as the Builder switches
313 may include --RTS= and that could change the default search dirs.
314
3152011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
316
317 * exp_ch7.adb (Make_Adjust_Call): Rewrite to mimic the structure of
318 Make_Final_Call. Move the processing for class-wide types before the
319 processing for derivations from [Limited_]Controlled.
320 (Make_Final_Call): Move the processing for class-wide types before the
321 processing for derivations from [Limited_]Controlled.
322 * s-stposu.adb (Allocate_Any_Controlled): Correct the membership check.
323 Add code to account for alignments larger than the list header. Add a
324 comment illustrating the structure of the allocated object + padding +
325 header.
326 (Deallocate_Any_Controlled): Add code to account for alignments larger
327 than the list header.
328
3292011-08-29 Ed Schonberg <schonberg@adacore.com>
330
331 * sinfo.ads, sinfo.adb: New node kind
332 N_Formal_Incomplete_Type_Definition, related flags.
333 par-ch12.adb (P_Formal_Type_Declaration, G_Formal_Type_Definition):
334 Parse formal incomplete types.
335 * sem.adb (Analyze): Formal_Incomplete_Type_Definitions are handled in
336 sem_ch12.
337 * sem_ch7.adb (Analyze_Package_Specification, Unit_Requires_Body):
338 Formal incomplete types do not need completion.
339 * sem_ch12.adb (Analyze_Formal_Incomplete_Type,
340 Validate_Incomplete_Type_Instance): New procedures to handle formal
341 incomplete types.
342 * freeze.adb (Freeze_Entity): Do not freeze the subtype of an actual
343 that corresponds to a formal incomplete type.
344 * sprint.adb: Handle formal incomplete type declarations.
345 * exp_util.adb (Insert_Actions): An incomplete_type_definition is not
346 an insertion point.
347
d3f70b35
AC
3482011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
349
350 * a-fihema.ads, a-fihema.adb: Unit removed.
351 * a-undesu.ads, a-undesu.adb: New unit implementing
352 Ada.Unchecked_Deallocate_Subpool.
353 * einfo.adb: Remove Associated_Collection from the node usage.
354 Add Finalization_Master to the node usage.
355 (Associated_Collection): Removed.
356 (Finalization_Master): New routine.
357 (Set_Associated_Collection): Removed.
358 (Set_Finalization_Master): New routine.
359 (Write_Field23_Name): Remove Associated_Collection from the output. Add
360 Finalization_Master to the output.
361 * einfo.ads: Remove attribute Associated_Collection and its uses in
362 entities.
363 Add new attribute Finalization_Master along with its uses in entitites.
364 (Associated_Collection): Removed along with its pragma import.
365 (Finalization_Master): New routine along with a pragma import.
366 (Set_Associated_Collection): Removed along with its pragma import.
367 (Set_Finalization_Master): New routine along with a pragma import.
368 * exp_ch3.adb (Expand_Freeze_Array_Type): Replace call to
369 Build_Finalization_Collection with Build_Finalization_Master.
370 (Expand_Freeze_Record_Type): Move the generation of Finalize_Address
371 before the bodies of the predefined routines. Add comment explaining
372 this. Replace call to Build_Finalization_Collection with
373 Build_Finalization_Master.
374 (Freeze_Type): Replace call to Build_Finalization_Collection with
375 Build_Finalization_Master.
376 (Make_Finalize_Address_Body): Comment reformatting.
377 (Make_Predefined_Primitive_Specs): Code reformatting.
378 (Stream_Operation_OK): Update comment mentioning finalization
379 collections. Replace RE_Finalization_Collection with
380 RE_Finalization_Master.
381 * exp_ch4.adb (Complete_Controlled_Allocation): Replace call to
382 Associated_Collection with Finalization_Master. Replace call to
383 Build_Finalization_Collection with Build_Finalization_Master.
384 (Expand_Allocator_Expression): Replace call to Associated_Collection
385 with Finalization_Master. Replace call to Set_Associated_Collection with
386 Set_Finalization_Master. Remove the generation of
387 Set_Finalize_Address_Ptr.
388 (Expand_N_Allocator): Replace call to Associated_Collection with
389 Finalization_Master. Remove the generation of Set_Finalize_Address_Ptr.
390 * exp_ch6.adb (Add_Collection_Actual_To_Build_In_Place_Call): Renamed to
391 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Update the
392 comment on usage. Replace call to Needs_BIP_Collection with
393 Needs_BIP_Finalization_Master Remplace BIP_Collection with
394 BIP_Finalization_Master. Update all comments which mention finalization
395 collections. Replace Associated_Collection with
396 Finalization_Master. Replace Build_Finalization_Collection with
397 Build_Finalization_Master.
398 (BIP_Formal_Suffix): Update BIP_Collection's case.
399 (Build_Heap_Allocator): Update the related comment. Rename local
400 variable Collect to Fin_Mas_Id and update its occurrences. Update
401 comments which mention finalization collections. Replace
402 Set_Associated_Collection with Set_Finalization_Master.
403 (Expand_Call): Update the code which detects a special piece of library
404 code for .NET/JVM.
405 (Make_Build_In_Place_Call_In_Allocator): Replace the call to
406 Add_Collection_Actual_To_Build_In_Place_Call with
407 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Remove the code
408 which generates a call to Make_Set_Finalize_Address_Ptr_Call.
409 (Make_Build_In_Place_Call_In_Anonymous_Context): Replace call to
410 Add_Collection_Actual_To_Build_In_Place_Call with
411 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
412 (Make_Build_In_Place_Call_In_Assignment): Replace call to
413 Add_Collection_Actual_To_Build_In_Place_Call with
414 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
415 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
416 * exp_ch6.ads: Rename BIP_Collection to BIP_Finalization_Master.
417 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
418 * exp_ch7.adb (Build_BIP_Cleanup_Stmts): Update comment on usage.
419 Rename local variable Collect to Fin_Mas_Id and update its occurrences.
420 Replace call to Set_Associated_Collection with Set_Finalization_Master.
421 (Build_Finalization_Collection): Renamed to Build_Finalization_Master.
422 Replace the call to Associated_Collection with Finalization_Master.
423 Rename local variable Coll_Id to Fin_Mas_Id and update its occurrences.
424 Update the way finalization master names are generated. Update the
425 retrieval of the correct access type which will carry the pool and
426 master attributes.
427 (Make_Final_Call): Reimplement the way [Deep_]Finalize is retrieved.
428 (Make_Finalize_Address_Body): Abstract types do not need
429 Finalize_Address. Code reformatting.
430 (Make_Finalize_Address_Stmts): Update comment on usage.
431 (Make_Set_Finalize_Address_Ptr_Call): Removed.
432 (Process_Declarations): Update comments.
433 * exp_ch7.ads (Build_Finalization_Collection): Renamed to
434 Build_Finalization_Master. Update associated comment.
435 (Make_Set_Finalize_Address_Ptr_Call): Removed.
436 * exp_ch13.adb: Update comments which mention finalization collections.
437 (Expand_N_Free_Statement): Replace the call to Associated_Collection
438 with Finalization_Master.
439 * exp_util.adb (Build_Allocate_Deallocate_Proc): Reimplemented to
440 create calls to routines Allocate_Any_Controlled and
441 Deallocate_Any_Controlled.
442 (Find_Finalize_Address): New routine.
443 (Is_Allocate_Deallocate_Proc): Update the RTE entities used in the
444 comparison.
445 (Requires_Cleanup_Actions): Update the comment on freeze node
446 inspection.
447 * exp_util.ads: Remove comment on generated code for
448 Build_Allocate_Deallocate_Proc. The code is now quite complex and it
449 is better to simply look in the body.
450 * freeze.adb (Freeze_All): Update the comment of finalization
451 collections. Replace the call to Associated_Collection with
452 Finalization_Master. Replace the call to Build_Finalization_Collection
453 with Build_Finalization_Master.
454 * impunit.adb: Add a-undesu and s-stposu to the list of units.
455 * Makefile.rtl: Add files a-undesu, s-finmas and s-stposu. Remove file
456 a-fihema.
457 * rtsfind.adb (Get_Unit_Name): Remove the processing for children of
458 Ada.Finalization. Add processing for children of System.Storage_Pools.
459 * rtsfind.ads: Remove the naming of second level children of
460 Ada.Finalization.
461 Remove Ada_Finalization_Heap_Management from the list of units.
462 Remove subtype Ada_Finalization_Child.
463 Remove the following subprogram entities:
464
465 RE_Allocate
466 RE_Deallocate
467 RE_Finalization_Collection
468 RE_Finalization_Collection_Ptr
469 RE_Set_Finalize_Address_Ptr
470
471 Add the naming of second level children of System.Storage_Pools.
472 Add System_Finalization_Masters and System_Storage_Pools_Subpools to
473 the list of units.
474 Add subtype System_Storage_Pools_Child.
475 Add the following subprogram entities to System.Finalization_Masters:
476
477 RE_Finalization_Master
478 RE_Finalization_Master_Ptr
479
480 Add the following subprogram entities to System.Storage_Pools.Subpools:
481
482 RE_Allocate_Any_Controlled
483 RE_Deallocate_Any_Controlled
484 RE_Root_Storage_Pool_With_Subpools
485 RE_Root_Subpool
486 RE_Subpool_Handle
487
488 Move the following subprogram entities from
489 Ada.Finalization.Heap_Management to System.Finalization_Masters:
490
491 RE_Add_Offset_To_Address
492 RE_Attach
493 RE_Base_Pool
494 RE_Detach
495
496 * sem_ch3.adb (Access_Type_Declaration): Replace the call to
497 Set_Associated_Collection with Set_Finalization_Master.
498 * sem_ch6.adb (Create_Extra_Formals): Update the way extra formal
499 BIP_Finalization_Master is created.
500 * s-finmas.adb: New unit System.Finalization_Masters.
501 * s-finmas.ads: New unit System.Finalization_Masters.
502 * s-stopoo.ads, s-stopoo.adb: Minor code reformatting.
503 * s-stposu.ads, s-stposu.adb: New unit implementing
504 System.Storage_Pools.Subpools.
505
5062011-08-29 Bob Duff <duff@adacore.com>
507
508 * tbuild.adb: Add assertion.
509
8c889ae4
AC
5102011-08-29 Thomas Quinot <quinot@adacore.com>
511
512 * s-pooglo.adb: Minor reformatting.
513
5142011-08-29 Ed Schonberg <schonberg@adacore.com>
515
516 * exp_ch5.adb (Expand_N_Assignment_Statement): if the left-hand side is
517 an indexed component of a packed array whose element type is a record
518 with a representation clause different from that of the right-hand
519 side, generate a temporary to minimuze the number of bit-field
520 operations generated.
521
5222011-08-29 Ed Schonberg <schonberg@adacore.com>
523
524 * exp_util.adb (Insert_Actions): Use clauses can be part of lists of
525 declarations, and thus are likely insertion points for actions.
526
5272011-08-29 Bob Duff <duff@adacore.com>
528
529 * einfo.ads: Minor comment fix.
530
1a07a71a
AC
5312011-08-29 Robert Dewar <dewar@adacore.com>
532
533 * frontend.adb, gnat1drv.adb: Minor reformatting.
534
5352011-08-29 Tristan Gingold <gingold@adacore.com>
536
537 * s-pooglo.adb (Allocate, Deallocate): Take into account the alignment.
538 * a-fihema.adb (Allocate, Deallocate): Ditto. Possibly add padding
539 space in front of the header.
540
4bcd6411
JK
5412011-08-29 Johannes Kanig <kanig@adacore.com>
542
543 * frontend.adb (Frontend): Exit after creating Standard package when
544 -gnatd.H is present.
545 * gnat1drv.adb (Gnat1drv): Call Backend right away when -gnatd.H is
546 present.
547
f0f88eb6
RD
5482011-08-29 Robert Dewar <dewar@adacore.com>
549
550 * exp_ch9.adb, mlib-prj.adb, prj.adb, prj.ads, ttypes.ads, sem_ch4.adb,
551 makeutl.adb, makeutl.ads, atree.ads, snames.adb-tmpl,
552 snames.ads-tmpl: Minor reformatting.
553
3e37be71
PG
5542011-08-29 Philippe Gil <gil@adacore.com>
555
556 * prj.adb (Reset_Units_In_Table): New procedure.
557 Reset units to avoid access to freed memory.
558
94fb7608
AC
5592011-08-29 Thomas Quinot <quinot@adacore.com>
560
561 * get_scos.adb: When reading a P statement SCO without a pragma name
562 (from an older ALI file), ensure that the Pragma_Name component is set
563 to Unknown_Pragma (not left uninitialized).
564
5652011-08-29 Vincent Celier <celier@adacore.com>
566
567 * makeutl.adb (Get_Directories): New procedure moved from Buildgpr and
568 modified to compute correctly the object path of a SAL project that is
569 extending another library project.
570 (Write_Path_File): New procedure.
571 * makeutl.ads (Directories): New table moved from Buildgpr
572 (Get_Directories): New procedure moved from Buildgpr
573 (Write_Path_File): New procedure
574 * mlib-prj.adb (Build_Library): Use Makeutl.Get_Directories to set the
575 paths before binding SALs, instead of Set_Ada_Paths.
576 * prj-env.adb (Set_Path_File_Var): Procedure has been moved to package
577 Prj.
578 * prj.adb (Set_Path_File_Var): New procedure moved from Prj.Env
579 (Current_Source_Path_File_Of): New function
580 (Set_Current_Object_Path_File_Of): New procedure
581 (Current_Source_Object_File_Of): New function
582 (Set_Current_Object_Path_File_Of): New procedure
583 * prj.ads (Set_Path_File_Var): New procedure moved from Prj.Env
584 (Current_Source_Path_File_Of): New function
585 (Set_Current_Object_Path_File_Of): New procedure
586 (Current_Source_Object_File_Of): New function
587 (Set_Current_Object_Path_File_Of): New procedure
588
5892011-08-29 Ed Schonberg <schonberg@adacore.com>
590
591 * exp_ch5.adb (Expand_N_Assignment_Statement): For an assignment to a
592 packed entity, use a bit-field assignment only if there is no change of
593 representation.
594
c5ecd6b7
AC
5952011-08-29 Thomas Quinot <quinot@adacore.com>
596
597 * rtsfind.ads, exp_ch3.adb (In_Runtime): Minor code improvement, use
598 Is_RTU instead of using Chars comparisons.
599
6002011-08-29 Thomas Quinot <quinot@adacore.com>
601
602 * exp_strm.adb (Build_Mutable_Record_Read_Procedure): Do not create a
603 temporary object if the actual is constrained, and the discriminants
604 read from the stream don't match.
605
6062011-08-29 Tristan Gingold <gingold@adacore.com>
607
608 * sem_attr.adb, exp_attr.adb: Add handling of
609 Attribute_System_Allocator_Alignment
610 * snames.ads-tmpl: Add Name_System_Allocator_Alignment and
611 Attribute_System_Allocator_Alignment.
612 * ttypes.ads, get_targ.ads: Add Get_System_Allocator_Alignment.
613 * gcc-interface/targtyps.c, gcc-interface/utils2.c,
614 gcc-interface/gigi.h: Renames get_target_default_allocator_alignment to
615 get_target_system_allocator_alignment.
616
6172011-08-29 Arnaud Charlet <charlet@adacore.com>
618
619 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
620 dependencies.
621
8abdac29
AC
6222011-08-29 Arnaud Charlet <charlet@adacore.com>
623
624 * exp_ch3.adb (In_Runtime): Fix typo.
625
df170605
AC
6262011-08-29 Bob Duff <duff@adacore.com>
627
628 * sem_ch4.adb (Analyze_Allocator): Analyze the subpool specification.
629
6302011-08-29 Ed Schonberg <schonberg@adacore.com>
631
632 * exp_ch3.adb (Expand_N_Object_Declaration): If the entity is tagged
633 and a separate tag assignment is generated, ensure that the tag
634 assignment is analyzed.
635
864a4236
ES
6362011-08-29 Ed Schonberg <schonberg@adacore.com>
637
638 * atree.ads, atree.adb (Copy_Separate_List): New function that applies
639 Copy_Separate_Tree to a list of nodes. Used to create disjoint copies
640 of statement lists that may contain local declarations.
df170605
AC
641 * exp_ch9.adb (Expand_N_Timed_Entry_Call): Use Copy_Separate_List to
642 duplicate the triggering statements needed for the expansion of this
643 construct, when the trigger is a dispatching call to a synchronized
644 primitive.
864a4236 645
7f394c1d
AC
6462011-08-29 Arnaud Charlet <charlet@adacore.com>
647
648 * gnat_rm.texi: Add doc for 'Elab_Subp_Body.
649 * bindgen.adb: Add comments.
650 * snames.adb-tmpl (Is_Attribute_Name): Only recognize 'Elab_Subp_Body
651 in CodePeer mode.
652
2c1a2cf3
RD
6532011-08-29 Robert Dewar <dewar@adacore.com>
654
655 * exp_attr.adb: Minor reformatting.
656 Minor code reorganization and commenting.
657 * par_sco.adb, checks.adb, sem_attr.adb, get_scos.adb: Minor
658 reformatting.
659
0bfc9a64
AC
6602011-08-29 Thomas Quinot <quinot@adacore.com>
661
662 * get_scos.adb: Ignore chaining indicators not currently supported
663 by Ada.
664
6652011-08-29 Arnaud Charlet <charlet@adacore.com>
666
667 * system.ads: Minor editing.
668
6692011-08-29 Arnaud Charlet <charlet@adacore.com>
670
671 * bindgen.adb (Gen_Elab_Calls): Generate calls to subp'Elab_Subp_Body in
672 CodePeer mode.
673 * sem_attr.ads, sem_attr.adb, exp_Attr.adb, sem_ch6.adb: Add handling of
674 Attribute_Elab_Subp_Body.
675 * snames.ads-tmpl (Attribute_Elab_Subp_Body, Name_Elab_Subp_Body): New.
676 * sem_util.adb: Update comments.
677
828d4cf0
TQ
6782011-08-29 Thomas Quinot <quinot@adacore.com>
679
680 * par_sco.adb, scos.adb, scos.ads, put_scos.adb, get_scos.adb: Record
681 pragma name for each SCO statement corresponding to a pragma.
682
5cd7bb15
AC
6832011-08-29 Arnaud Charlet <charlet@adacore.com>
684
685 * opt.ads: Minor editing.
686
6872011-08-29 Yannick Moy <moy@adacore.com>
688
689 * gnat1drv.adb (Adjust_Global_Switches): Remove options for ALFA mode
690 that only made sense for CodePeer mode.
691
6922011-08-29 Jose Ruiz <ruiz@adacore.com>
693
694 * targparm.ads (Support_64_Bit_Divides_On_Target): Remove this flag
695 which is no longer used.
696 * targparm.adb (S64, S64_Str, Get_Target_Parameters): Remove the
697 handling of the 64-bit division check.
698 * exp_ch4.adb (Expand_N_Op_Divide): Remove the check for 64-bit
699 division available.
700 * system*.ads (Support_64_Bit_Divides): Remove this flag which is no
701 longer used.
702
7032011-08-29 Thomas Quinot <quinot@adacore.com>
704
705 * get_scos.adb: Minor reformatting.
706
25b589cb
AC
7072011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
708
709 * exp_util.adb (Process_Statements_For_Controlled_Objects): Whenever a
710 statement list is wrapped in a block, the block is explicitly analyzed
711 in order to properly redecorate the entities and create a servicing
712 finalizer.
713
7142011-08-29 Tristan Gingold <gingold@adacore.com>
715
716 * sinfo.ads, sinfo.adb (Zero_Cost_Handling): Remove.
717 (Set_Zero_Cost_Handling): Remove.
718
7192011-08-29 Thomas Quinot <quinot@adacore.com>
720
721 * par_sco.adb, scos.ads, put_scos.adb, get_scos.adb: Minor reformatting
722
1197ddb1
AC
7232011-08-29 Geert Bosch <bosch@adacore.com>
724
725 * s-vaflop-vms-alpha.adb (Neg_F): Use subtraction instead of negation
726 instruction, as the latter may produce -0.0, which is not a valid VAX
727 F float number.
728 (Neg_G): Likewise for VAX F float.
729
7302011-08-29 Robert Dewar <dewar@adacore.com>
731
732 * exp_util.adb: Minor reformatting.
733
7342011-08-29 Yannick Moy <moy@adacore.com>
735
736 * sem_ch3.adb: Minor comment update.
737
7382011-08-29 Thomas Quinot <quinot@adacore.com>
739
740 * checks.adb (Apply_Type_Conversion_Checks): Use the Underlying_Type of
741 the operand type.
742
7432011-08-29 Thomas Quinot <quinot@adacore.com>
744
745 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not flush
746 current statement sequence on a generic instantiation or a subprogram
747 declaration.
748
8f66cda7
AC
7492011-08-29 Robert Dewar <dewar@adacore.com>
750
751 * sem_type.adb, einfo.ads, freeze.adb, exp_ch4.adb, sem_ch13.adb:
752 Minor reformatting.
753
7542011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
755
756 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
757 Correct the check which involves the freeze node of a controlled or
758 access-to-controlled type.
759
7602011-08-29 Geert Bosch <bosch@adacore.com>
761
762 * sem_warn.adb (Check_Code_Statement): Remove check for consecutive Asm
763 statements.
764 * s-vaflop-vms-alpha.adb: Remove bogus Volatile => True arguments from
765 Asm statements.
766
cf161d66
AC
7672011-08-29 Yannick Moy <moy@adacore.com>
768
769 * sem_ch3.adb (Array_Type_Declaration): Insert a subtype declaration
770 for every index type and component type that is not a subtype_mark.
771 (Process_Subtype): Set Etype of subtype.
772
7732011-08-29 Robert Dewar <dewar@adacore.com>
774
775 * a-cbmutr.adb, a-cimutr.adb, a-comutr.adb, prj-nmsc.adb: Minor code
776 reorganization. Minor reformatting.
777
7cc83cd8
AC
7782011-08-29 Steve Baird <baird@adacore.com>
779
780 * exp_ch4.adb (Expand_N_Op_Expon): Suppress N_Op_Expon node expansion
781 for CodePeer and ALFA modes.
782
7832011-08-29 Ed Schonberg <schonberg@adacore.com>
784
785 * sem_type.adb (Collect_Interps): Within an instance, collect a homonym
786 that comes from an enclosing scope if it is not the renaming of an
787 actual, to handle properly a spurious ambiguity in an instance.
788
76af4137
AC
7892011-08-29 Eric Botcazou <ebotcazou@adacore.com>
790
791 * sem_ch13.adb (Alignment_Check_For_Esize_Change): Rename to...
792 (Alignment_Check_For_Size_Change): ...this. Add SIZE parameter and
793 use it instead of the Esize of the first parameter.
794 (Analyze_Attribute_Definition_Clause) <Object_Size>: Adjust call to
795 above change.
796 <Size>: Likewise. Call it for composite types on the RM size.
797
7982011-08-29 Yannick Moy <moy@adacore.com>
799
800 * exp_ch4.adb (Expand_N_Op_Not): Do not expand not on array.
801 * sem_util.adb (Unique_Name): Correct behaviour for names of
802 compilation units.
803
9b20e59b
AC
8042011-08-29 Yannick Moy <moy@adacore.com>
805
806 * sem_prag.adb (Check_Precondition_Postcondition): In formal
807 verification mode, analyze pragma expression for correctness, for
808 pre/post on library-level subprogram, as it is not expanded later.
809
8102011-08-29 Yannick Moy <moy@adacore.com>
811
812 * exp_aggr.adb (Expand_Array_Aggregate): Do not expand array aggregates
813 in formal verification.
814
8152011-08-29 Thomas Quinot <quinot@adacore.com>
816
817 * sem_util.adb: Minor reformatting.
818 * freeze.adb, sem_ch13.adb: Fix comment: Bit_Order is an attribute,
819 there's no pragma.
820 * par_sco.ads, par_sco.adb: Update comments.
821
8222011-08-29 Yannick Moy <moy@adacore.com>
823
824 * einfo.adb, einfo.ads: Remove flag Is_Postcondition_Proc and
825 associated getter/setter.
826 * sem_ch6.adb: Remove reference to Is_Postcondition_Proc.
827
8282011-08-29 Vincent Celier <celier@adacore.com>
829
830 * prj-attr.adb: New Compiler attribute Dependency_Kind and Language_Kind
831 * prj-conf.adb: Add_Default_GNAT_Naming_Scheme: Add a package Compiler
832 with declarations for Language_Kind and Dependency_Kind for Ada.
833 * prj-nmsc.adb (Check_Unit_Name): New name of procedure Check_Ada_Name
834 (Process_Compiler): Take into account the new attributes Dependency_Kind
835 and Language_Kind.
836 (Check_Configuration): Check if language kind is unit based, not if the
837 language name is Ada.
838 (Process_Exceptions_Unit_Based): Ditto
839 (Add_Language): Remove default additions of language and dependency kind
840 * prj.ads: Minor comment change
841 * snames.ads-tmpl: New standard names Dependency_Kind and Language_Kind
842
8432011-08-29 Johannes Kanig <kanig@adacore.com>
844
845 * debug.adb: Update comments.
846
c5bc3df6
JM
8472011-08-24 Joseph Myers <joseph@codesourcery.com>
848
849 * gcc-interface/Make-lang.in (CFLAGS-ada/tracebak.o)
850 (CFLAGS-ada/targext.o, CFLAGS-ada/cio.o, CFLAGS-ada/init.o)
851 (CFLAGS-ada/initialize.o, CFLAGS-ada/raise.o): New.
852 (ada/tracebak.o, ada/targext.o, ada/cio.o, ada/init.o)
853 (ada/initialize.o, ada/raise.o): Remove explicit compilation rules.
854
e3aa9eba
RO
8552011-08-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
856
857 * gcc-interface/Makefile.in (PICFLAG_FOR_TARGET): New.
858 (GNATLIBCFLAGS_FOR_C): Replace
859 TARGET_LIBGCC2_CFLAGS by PICFLAG_FOR_TARGET.
860 (gnatlib-shared-default, gnatlib-shared-dual-win32)
861 (gnatlib-shared-win32, gnatlib-shared-darwin, gnatlib-shared)
862 (gnatlib-sjlj, gnatlib-zcx): Likewise.
863
f446d60e
EB
8642011-08-07 Eric Botcazou <ebotcazou@adacore.com>
865
866 * gcc-interface/Makefile.in (raise-gcc.o): Fix previous change.
867
588c8f48
EB
868 * gcc-interface/gigi.h (enumerate_modes): Fix formatting.
869
870 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Revert latest change.
871
28d711bf
NR
8722011-08-05 Nicolas Roche <roche@adacore.com>
873
874 * gcc-interface/Makefile.in: Don't use directly ../xgcc to build shared
875 libgnat. Use rather the value of GCC_FOR_TARGET. Fix issue with
876 canadian cross.
877 * gcc-interface/Make-lang.in: Add support for canadian cross setting.
878
993f8920
AC
8792011-08-05 Matthew Heaney <heaney@adacore.com>
880
881 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Child_Count, Child_Depth):
882 subprogram bodies declared out-of-order.
883
8842011-08-05 Yannick Moy <moy@adacore.com>
885
886 * sem_util.adb (Unique_Name): only prefix with "standard" the names of
887 entities directly in package Standard, otherwise skip the standard
888 prefix.
889
9b3956dd
RD
8902011-08-05 Robert Dewar <dewar@adacore.com>
891
892 * a-cbmutr.adb: Minor reformatting
893 (Allocate_Node): refactor node allocation algorithm
894
8952011-08-05 Robert Dewar <dewar@adacore.com>
896
897 * opt.ads, opt.adb (Debug_Pragmas_Disabled): New switch.
898 * sem_prag.adb (Analyze_Pragma, case Debug_Policy): Implement Disable
899 mode.
900 (Analyze_Pragma, case Check_Policy): Ditto.
901 * sem_prag.ads (Check_Disabled): New function
902 * snames.ads-tmpl: Add Name_Disable.
903
9042011-08-05 Robert Dewar <dewar@adacore.com>
905
906 * gnat_rm.texi: Document implementation-defined policy DISABLE for
907 pragmas Assertion_Policy, Check_Policy, Debug_Policy.
908
79e705d6
AC
9092011-08-05 Ed Schonberg <schonberg@adacore.com>
910
911 * sem_prag.adb (Analyze_Pragma, case Inline): reject an Inline pragma
912 that appears in a generic formal part and applies to a formal
913 subprogram.
914
9152011-08-05 Robert Dewar <dewar@adacore.com>
916
917 * a-cbmutr.ads: Minor reformatting.
918
23b6deca
AC
9192011-08-05 Matthew Heaney <heaney@adacore.com>
920
921 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Read): do not use T'Valid
922 to check count, check sign of value instead.
923 * a-comutr.adb, a-cimutr.adb (Write): return immediately if tree empty
924 (Copy_Subtree): allocate copy of source element
925 (Equal_Subtree): compare elements, not access objects
926
9272011-08-05 Vincent Celier <celier@adacore.com>
928
929 * gnat_ugn.texi: Fix VMS alternative.
930
a2773bd3
AC
9312011-08-05 Thomas Quinot <quinot@adacore.com>
932
933 * sem_ch11.adb: Add comment.
934
9352011-08-05 Robert Dewar <dewar@adacore.com>
936
937 * exp_util.adb: Minor comment fix.
938
9392011-08-05 Robert Dewar <dewar@adacore.com>
940
941 * scng.adb (Error_Unterminated_String): Improve flag position when
942 comma present.
943
9442011-08-05 Matthew Heaney <heaney@adacore.com>
945
946 * Makefile.rtl, impunit.adb: Added a-cbmutr.ad[sb] (bounded multiway
947 tree containers).
948 * a-cbmutr.ads, a-cbmutr.adb: This is the new Ada 2012 unit for bounded
949 multiway tree containers.
950
9512011-08-05 Robert Dewar <dewar@adacore.com>
952
953 * styleg.adb (Check_Comment): Implement comment spacing of 1 or 2
954 * stylesw.adb: Implement -gnatyC to control comment spacing
955 * stylesw.ads (Style_Check_Comments_Spacing): New switch (set by
956 -gnatyc/C).
957 * usage.adb: Add line for -gnatyC.
958
9592011-08-05 Robert Dewar <dewar@adacore.com>
960
f446d60e 961 * gnat_ugn.texi: Document -gnatyC.
a2773bd3
AC
962 * vms_data.ads: Implement COMMENTS1/COMMENTS2 (retaining COMMENTS as a
963 synonym for COMMENTS2).
964
dedac3eb
RD
9652011-08-05 Robert Dewar <dewar@adacore.com>
966
967 * par_sco.adb, sem_ch3.adb, scos.ads, a-iteint.ads, sem_ch12.adb,
968 a-cimutr.adb, a-cimutr.ads, sem_util.ads, sem_res.adb, a-fihema.adb,
969 sem_ch4.adb, lib-xref-alfa.adb, exp_disp.adb, a-comutr.adb,
970 a-comutr.ads, lib-xref.adb: Minor reformatting.
971
9722011-08-05 Robert Dewar <dewar@adacore.com>
973
974 * sem_ch11.adb (Analyze_Raise_Statement): Kill assignment to formal
975 warning if there is an exception handler present.
976
7c62a85a
AC
9772011-08-05 Pascal Obry <obry@adacore.com>
978
979 * a-iteint.ads: Fix copyright year.
980
9812011-08-05 Thomas Quinot <quinot@adacore.com>
982
983 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not generate a
984 statement SCO for a USE clause or a representation clause.
985
9862011-08-05 Yannick Moy <moy@adacore.com>
987
988 * lib-xref-alfa.adb (Collect_ALFA): generate the proper relation
989 between body and spec for stub.
990 (Detect_And_Add_ALFA_Scope): take into account subprogram stub
991 * lib-xref.adb (Enclosing_Subprogram_Or_Package): in the case of a
992 pragma precondition or postcondition, for which the enclosing
993 subprogram or package in the AST is not the desired one, return empty.
994
e49208a9
AC
9952011-08-05 Thomas Quinot <quinot@adacore.com>
996
997 * g-expect.adb: Minor reformatting.
998
9992011-08-05 Bob Duff <duff@adacore.com>
1000
1001 * a-fihema.adb: Comment out OS_Lib.
1002
10032011-08-05 Matthew Heaney <heaney@adacore.com>
1004
1005 * Makefile.rtl, impunit.adb: Added a-c[oi]mutr.ad[sb]
1006 (unbounded multiway tree containers) and a-iteint.ads.
1007 * a-comutr.ads, a-comutr.adb:
1008 This is the new Ada 2012 unit for unbounded multiway tree containers
1009 * a-cimutr.ads, a-cimutr.adb
1010 This is the new Ada 2012 unit for indefinite multiway tree containers
1011 * a-iteint.ads: New file.
1012
201cdb74
RO
10132011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1014
f446d60e 1015 * gcc-interface/Makefile.in (raise-gcc.o): Search $(srcdir)/../libgcc.
201cdb74 1016
d50f4827
AC
10172011-08-05 Bob Duff <duff@adacore.com>
1018
1019 * sinfo.ads, sinfo.adb (Subpool_Handle_Name): New attribute for
1020 subpools.
1021 * par-ch4.adb (P_Allocator): Parse new subpool specification syntax.
1022
10232011-08-05 Ed Schonberg <schonberg@adacore.com>
1024
1025 * sem_ch4.adb (Try_Container_Indexing): New procedure to implement the
1026 general indexing aspects of Ada2012. Called when analyzing indexed
1027 components when other interpretations fail.
1028 * sem_ch8.adb (Find_Direct_Name): check for implicit dereference only
1029 in an expression context where overloading is meaningful. This excludes
1030 the occurrence in an aspect specification (efficiency only).
1031 * sem_attr.adb (Analyze_Attribute): indicate that the attributes
1032 related to iterators can be set by an attribute specification, but
1033 cannot be queried.
1034 * sem_ch13.adb (Analyze_Aspect_Specifications): handle
1035 Constant_Indexing and Variable_Indexing.
1036 (Check_Indexing_Functions): New procedure to perform legality checks.
1037 Additional semantic checks at end of declarations.
1038
efe05dfc
AC
10392011-08-05 Sergey Rybin <rybin@adacore.com>
1040
1041 * tree_io.ads: Update ASIS_Version_Number because of the change of the
1042 order of calling Tree_Write/Tree_Read routines made for aspects.
1043
10442011-08-05 Bob Duff <duff@adacore.com>
1045
1046 * a-fihema.adb (Finalize): Fix race condition.
1047
5f9cdefe
AC
10482011-08-05 Yannick Moy <moy@adacore.com>
1049
1050 * sem_ch12.adb (Analyze_Package_Instantiation,
1051 Need_Subprogram_Instance_Body): do not generate instance bodies in ALFA
1052 mode.
1053
10542011-08-05 Ed Schonberg <schonberg@adacore.com>
1055
1056 * sem_type.adb (Specific_Type): in an instance, the type-specific
1057 operand of an equality check that involves null may have a private
1058 type. Use full view to determine legality of construct.
1059
822868aa
AC
10602011-08-05 Vincent Celier <celier@adacore.com>
1061
1062 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
1063 delete or close the file when the call to gnatmake was successful.
1064
10652011-08-05 Yannick Moy <moy@adacore.com>
1066
1067 * gnat1drv.adb (Adjust_Global_Switches): in ALFA mode, set
1068 Global_Discard_Names.
1069
10702011-08-05 Ed Schonberg <schonberg@adacore.com>
1071
1072 * sinfo.ads: comments on use of entity field for aspect specifications.
1073
10742011-08-05 Ed Schonberg <schonberg@adacore.com>
1075
1076 * sem_ch12.adb (Reset_Entity): If the entity field of the associated
1077 node is not itself an entity but a selected component, it is a
1078 rewritten parameterless call to an en enclosing synchronized operation,
1079 and this expansion will be performed again in the instance, so there is
1080 no global information to preserve.
1081
44a10091
AC
10822011-08-05 Javier Miranda <miranda@adacore.com>
1083
1084 * exp_disp.adb (Set_All_DT_Position): Cleanup code and improve support
1085 for renamings of predefined primitives.
1086 (In_Predef_Prims_DT): New subprogram.
1087
10882011-08-05 Ed Schonberg <schonberg@adacore.com>
1089
1090 * sem_util.adb, sem_util.ads (Check_Implicit_Dereference): If a
1091 possible interpretation of name is a reference type, add an
1092 interpretation that is the designated type of the reference
1093 discriminant of that type.
1094 * sem_res.adb (resolve): If the interpretation imposed by context is an
1095 implicit dereference, rewrite the node as the deference of the
1096 reference discriminant.
1097 * sem_ch3.adb (Analyze_Subtype_Declaration, Build_Derived_Record_Type,
1098 Build_Discriminated_Subtype): Inherit Has_Implicit_Dereference from
1099 parent type or base type.
1100 * sem_ch4.adb (Process_Indexed_Component,
1101 Process_Overloaded_Indexed_Component, Indicate_Name_And_Type,
1102 Analyze_Overloaded_Selected_Component, Analyze_Selected_Component):
1103 Check for implicit dereference.
1104 (List_Operand_Interps): Indicate when an implicit dereference is
1105 ambiguous.
1106 * sem_ch8.adb (Find_Direct_Name): Check for implicit dereference.
1107
11082011-08-05 Thomas Quinot <quinot@adacore.com>
1109
1110 * scos.ads: Update documentation of SCO table. Pragma statements can now
1111 be marked as disabled (using 'p' instead of 'P' as the statement kind).
1112 * par_sco.ads, par_sco.adb: Implement the above change.
1113 (Process_Decisions_Defer): Generate a P decision for the first parameter
1114 of a dyadic pragma Debug.
1115 * sem_prag.adb (Analyze_Pragma, case Debug): Mark pragma as enabled if
1116 necessary.
1117 * put_scos.adb: Code simplification based on above change.
1118
bb3c784c
AC
11192011-08-05 Robert Dewar <dewar@adacore.com>
1120
1121 * sem_ch3.adb, gnatcmd.adb, switch-c.adb, exp_attr.adb, make.adb,
1122 bindgen.adb, einfo.adb, sem_ch12.adb, sem_attr.adb, a-fihema.adb,
1123 a-fihema.ads, sem_elab.adb, sem_elab.ads, aspects.adb, opt.ads,
1124 prj-conf.adb, sem_ch13.adb, s-ficobl.ads: Minor reformatting
1125
11262011-08-05 Bob Duff <duff@adacore.com>
1127
1128 * a-stunau.ads, g-spipat.adb: Update comments.
1129
36f686f9
BD
11302011-08-05 Bob Duff <duff@adacore.com>
1131
1132 * a-fihema.ads: Minor comment fix.
1133 * a-fihema.adb (Allocate, Deallocate): Assert that the alignment is
1134 correct.
1135 (Attach, Detach): Remove some unnecessary code.
1136 (Finalize): Remove Node_Ptr_To_Address, replace with a constant.
1137
7882673f
BD
11382011-08-05 Bob Duff <duff@adacore.com>
1139
1140 * a-fihema.ads, a-fihema.adb (Finalization_Collection): Avoid heap
1141 allocation for Objects component. This simplifies the code somewhat. It
1142 is also a little more efficient in the not-so-unusual case where there
1143 are no controlled objects allocated.
1144 Make Finalization_Started flag atomic.
1145 (Finalize): Avoid unnecessary detachment of items from the list.
1146 (pcol): Minor cleanup.
1147
d34cd274
AC
11482011-08-05 Ed Schonberg <schonberg@adacore.com>
1149
1150 * sem_ch12.adb (Analyze_Formal_Package_Declaration): reject a formal
1151 package whose name is the same as that of the generic unit, or its
1152 ultimate prefix.
1153
11542011-08-05 Bob Duff <duff@adacore.com>
1155
1156 * a-fihema.adb, a-fihema.ads: Minor comment improvements.
1157 * sem_ch3.adb, exp_ch5.adb, exp_ch7.adb, exp_ch7.ads, exp_util.adb:
1158 Minor comment fixes.
1159
00332244
AC
11602011-08-05 Arnaud Charlet <charlet@adacore.com>
1161
1162 * make.adb (Linking_Phase): No longer need to set source search path
1163 before calling gnatlink in CodePeer mode.
1164 * gnatlink.adb (Gnatlink): No longer pass -gnat83/95/05/12 switch to
1165 gcc in CodePeer mode, since the binder generated file no longer has a
1166 'with Main'.
1167 * switch.ads, switch.adb (Is_Language_Switch): Removed.
1168 * switch-c.adb: Update comment.
1169
11702011-08-05 Thomas Quinot <quinot@adacore.com>
1171
1172 * exp_strm.adb, bindgen.adb, s-ficobl.ads: Minor reformatting.
1173
11742011-08-05 Nicolas Roche <roche@adacore.com>
1175
1176 * gnat_ugn.texi: Fix minor syntax error issue.
1177
11782011-08-05 Vincent Celier <celier@adacore.com>
1179
1180 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
1181 delete or close the file when the call to gnatmake returns a non
1182 successful return code.
1183
11842011-08-05 Ed Schonberg <schonberg@adacore.com>
1185
1186 * exp_ch4.adb (Expand_N_Type_Conversion): When expanding a predicate
1187 check, indicate that the copy of the original node does not come from
1188 source, to prevent an infinite recursion of the expansion.
1189
11902011-08-05 Johannes Kanig <kanig@adacore.com>
1191
1192 * debug.adb: document switch -gnatd.G for gnat2why, which deactivates
1193 VC generation for subprogram bodies.
1194
11952011-08-05 Yannick Moy <moy@adacore.com>
1196
1197 * einfo.ads: Typo.
1198 * sem_ch3.adb (Signed_Integer_Type_Declaration): in ALFA mode, define
1199 the base type with the smallest allowed base type.
1200
12012011-08-05 Sergey Rybin <rybin@adacore.com>
1202
1203 * tree_gen.adb, tree_in.adb, aspects.adb: Fix tree read-write for
1204 aspects.
1205
12062011-08-05 Ed Schonberg <schonberg@adacore.com>
1207
1208 * sem_ch12.ads: minor comment updates.
1209
12102011-08-05 Ed Schonberg <schonberg@adacore.com>
1211
1212 * sem_ch12.adb (Analyze_Formal_Package_Declaration): in an
1213 instantiation and a formal package the compiler generates a package
1214 renaming declaration so that the generic name within the declaration
1215 is interpreted as a renaming of the instance. At the end of a formal
1216 package declaration, this renaming must become invisible.
1217
0da80d7d
AC
12182011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
1219
1220 * exp_ch7.adb (Is_Init_Call): Reimplemented to avoid character
1221 comparison and rely on concrete entities instead.
1222
12232011-08-05 Ed Schonberg <schonberg@adacore.com>
1224
1225 * einfo.ads, einfo.adb (Has_Implicit_Dereference): new flag on types
1226 and discriminants, to indicate that the type has an access discriminant
1227 that supports implicit dereference.
1228 * snames.ads-tmpl: Add names of aspects and attributes related to
1229 Ada2012 iterators: constant_indexing, default_iterator,
1230 iterator_element, implicit_dereference, variable_indexing.
1231 * aspects.ads, aspects.adb: entries for iterator-related aspects.
1232 * sem_ch13.adb (Analyze_aspect_specifications): dummy entries for
1233 iterator-related aspects.
1234 * sem_attr.adb, exp_attr.adb Dummy entries for iterator-related aspects.
1235
12362011-08-05 Sergey Rybin <rybin@adacore.com>
1237
1238 * gnat_ugn.texi, vms_data.ads: Extend the subsection about coupling
1239 metrics in gnatmetric to cover new kinds of coupling mentrics.
1240
12412011-08-05 Steve Baird <baird@adacore.com>
1242
1243 * bindgen.adb (Gen_CodePeer_Wrapper): Call Ada_Main_Program instead
2c7f9cc0 1244 of calling the user-defined main subprogram.
0da80d7d
AC
1245 (Gen_Main): Declare Ada_Main_Program and (if CodePeer_Mode
1246 is set) Call_Main_Subprogram ahead of, as opposed to
1247 inside of, Main.
1248 (Gen_Output_File_Ada): Remove CodePeer_Mode-conditional
1249 generation of a "with" of the user-defined main subprogram.
1250 Remove CodePeer_Mode-conditional call to Gen_CodePeer_Wrapper
1251 (which is now called from Gen_Main instead).
1252
73242473
AC
12532011-08-05 Emmanuel Briot <briot@adacore.com>
1254
1255 * projects.texi: Added reference to the Makefile package.
1256
12572011-08-05 Thomas Quinot <quinot@adacore.com>
1258
1259 * exp_ch7.adb: Minor comment rewording.
1260
12612011-08-05 Ed Falis <falis@adacore.com>
1262
1263 * env.c: Fix comment.
1264
12652011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
1266
1267 * sem_elab.adb (Is_Finalization_Procedure): Reimplemented to avoid
1268 character comparison and rely on concrete entities instead.
1269
97ed5872
AC
12702011-08-05 Ed Schonberg <schonberg@adacore.com>
1271
1272 * sem_ch3.adb: (Check_Private_Overriding): better error message,
1273 suggested by AI95-0068.
1274
12752011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
1276
1277 * exp_ch7.adb (Find_Last_Init): Use Next_Suitable_Statement to retrieve
1278 the two potential initialization calls. This accounts for any
1279 access-before-elaboration checks which may precede the initialization
1280 calls.
1281 (Next_Suitable_Statement): New routine. Returns the next real statement
1282 after the input node while skipping generated checks.
1283 * sem_elab.adb (Check_A_Call): New formal parameter In_Init_Proc along
1284 with comment on usage.
1285 Do not generate Elaborate_All when the trigger is a finalization call
1286 coming from a type init proc.
1287 (Check_Elab_Call): Propagate the initialization procedure context to
1288 subsequent calls to Check_A_Call.
1289 (Check_Internal_Call_Continue): Propagate the initialization procedure
1290 context to subsequent calls to Check_Elab_Call.
1291 (Is_Finalization_Procedure): New routine. Returns True if the input
1292 entity denotes a [Deep_]Finalize routine.
1293 * sem_elab.ads (Check_Elab_Call): New formal parameter In_Init_Proc
1294 along with comment on usage.
1295
12962011-08-05 Vadim Godunko <godunko@adacore.com>
1297
1298 * s-atocou.ads: Add list of supported platforms.
1299
13002011-08-05 Yannick Moy <moy@adacore.com>
1301
1302 * sem_prag.adb, restrict.adb: Correct style for or'ing Boolean variables
1303
1304 * opt.ads (Disable_ALI_File): new Boolean flag
1305 * lib-writ.adb (Write_ALI): when Disable_ALI_File is set, do nothing
1306
13072011-08-05 Ed Falis <falis@adacore.com>
1308
1309 * env.c (__gnat_environ): Fix includes for RTPs and VTHREADS so that
1310 environ is properly defined.
1311
13122011-08-05 Vincent Celier <celier@adacore.com>
1313
1314 * make.adb (Compilation_Phase): Exit immediately when all objects have
1315 been found up to date, to avoid multiple exit messages.
1316 * prj-nmsc.adb (Add_Source): Allow duplicate source file names in the
1317 same project for languages with no compiler.
1318 * gnat_ugn.texi: Document compiler switch -gnateI and gnatmake switch
1319 -eI.
9aff36e9
RD
13202011-08-05 Robert Dewar <dewar@adacore.com>
1321
1322 * exp_ch7.ads, sem_type.adb, make.adb, sem_prag.adb, sem_util.adb,
1323 sem_util.ads, sem_attr.adb, restrict.ads, sem_ch6.adb, prj-conf.adb,
1324 prj-conf.ads, s-atocou.ads, s-atocou.adb, s-atocou-x86.adb,
1325 s-atocou-builtin.adb: Minor reformatting.
1326
406935b6
AC
13272011-08-05 Yannick Moy <moy@adacore.com>
1328
1329 * exp_ch7.adb (Establish_Transient_Scope): in formal verification mode,
1330 if the node to wrap is a pragma check, this node and enclosed
1331 expression are not expanded, so do not apply any transformations here.
1332 * exp_prag.adb (Expand_Pragma_Check): document the need to avoid
1333 introducing transient scopes.
1334
13352011-08-05 Jose Ruiz <ruiz@adacore.com>
1336
1337 * adaint.c (__gnat_set_writable, __gnat_set_readable,
1338 __gnat_set_executable, __gnat_set_non_writable, __gnat_set_non_readable,
1339 __gnat_copy_attribs): On VxWorks 6.x and later, the required chmod
1340 routine is available, so we use the default implementation of these
1341 functions.
1342 * s-os_lib.ads (Copy_File, Copy_Time_Stamps): Document that there is
1343 support for copying attributes on VxWorks 6.
1344
13452011-08-05 Yannick Moy <moy@adacore.com>
1346
1347 * debug.adb: Remove use of -gnatd.D.
1348 * gnat1drv.adb (Adjust_Global_Switches): adjust switches for ALFA mode
1349 * opt.ads: Simplify variables for ALFA mode, to keep one only
1350 * restrict.adb, sem_prag.adb: Adapt treatment done for CodePeer mode
1351 to ALFA mode.
1352
13532011-08-05 Vincent Celier <celier@adacore.com>
1354
1355 * prj-conf.adb (Do_Autoconf): Look also for --RTS in
1356 Builder'Default_Switches.
1357
13582011-08-05 Vincent Celier <celier@adacore.com>
1359
1360 * makeusg.adb: Add lines for --create-map-file switches.
1361
13622011-08-05 Ed Schonberg <schonberg@adacore.com>
1363
1364 * freeze.adb (Freeze_Entity): For a subprogram, if a type in the
1365 profile is incomplete and the full view is available, replace it with
1366 the full view.
1367 * sem_ch6.adb (Possible_Freeze): if a type in the profile is
1368 incomplete, freezing the subprogram is delayed until the full view is
1369 frozen.
1370 * sem_type.adb (Disambiguate): an ambiguity between a user-defined
1371 fixed-point multiplication operator and the predefined operator is
1372 resolved in favor of the user-defined one.
1373
96c891b3
RO
13742011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1375
1376 * init.c [__alpha__ && __osf__] (__gnat_error_handler): Use
1377 CONST_CAST.
1378
276e7ed0
AC
13792011-08-04 Ed Schonberg <schonberg@adacore.com>
1380
1381 * sem_util.ads, sem_unit.adb (Type_Without_Stream_Operation): determine
1382 whether a type lacks user-defined Read or Write operations, or has a
1383 component that lacks them.
1384 * sem_attr.adb (Check_Stream_Attribute): if restriction
1385 No_Default_Stream_Attributes is active, verify that all subcomponent
1386 types of the target have user-defined stream operations, and report
1387 error otherwise.
1388 * exp_ch3.adb (Stream_Operqtion_OK): use Type_Without_Stream_Operation.
1389 * exp_strm.adb: Build_Elementary_Input_Call,
1390 Build_Elementary_Write_Call): remove checks for restriction
1391 No_Default_Stream_Attributes, now checked in semantics.
1392
13932011-08-04 Vincent Celier <celier@adacore.com>
1394
1395 * prj-conf.ads, prj-conf.adb (Do_Autoconf): If there is no --RTS
1396 switches on the command line, look for all valid --RTS switches in the
1397 Builder switches and for each language use the first runtime name found
1398 to invoke gprconfig.
1399 (Get_Or_Create_Configuration_File): Warn if --RTS is specified on the
1400 command line and there is no auto-configuration.
1401 (Runtime_Name_Set_For): New function.
1402
14032011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
1404
1405 * exp_ch7.adb (Build_Object_Declarations): Do not generate the
1406 elaborate initialization expression for variable Abort when processing
1407 a package body or a declaration.
1408 (Create_Finalizer): Propagate the package context when creating the
1409 exception-related variables.
1410 * exp_ch7.ads (Build_Object_Declarations): New formal parameter
1411 For_Package along with usage comment.
1412
19172ae9
AC
14132011-08-04 Arnaud Charlet <charlet@adacore.com>
1414
1415 * gcc-interface/Makefile.in: Clean up targets.
1416 Enable new package for atomic counters and copy-on-write implementation
1417 of unbounded strings on x86 platforms.
1418 * gcc-interface/Make-lang.in: Update dependencies.
1419
0319cacc
AC
14202011-08-04 Robert Dewar <dewar@adacore.com>
1421
1422 * exp_ch7.adb: Minor reformatting.
1423
14242011-08-04 Robert Dewar <dewar@adacore.com>
1425
1426 * exp_strm.adb: Minor reformatting.
1427
14282011-08-04 Vadim Godunko <godunko@adacore.com>
1429
1430 * s-atocou.adb: Replace by dummy version and use on targets where atomic
1431 operations are not supported.
1432 * s-atocou-builtin.adb: Renamed from s-atocou.adb.
1433 * s-atocou-x86.adb: New file.
1434 * Makefile.rtl: Add s-atocou.o file
1435
14362011-08-04 Arnaud Charlet <charlet@adacore.com>
1437
1438 * make.adb (Compile): Move setting of CodePeer_Mode to ...
1439 (Compilation_Phase): ... here.
1440 (Scan_Make_Arg): Now bind and link by default in CodePeer mode.
1441
14422011-08-04 Thomas Quinot <quinot@adacore.com>
1443
1444 * Make-generated.in: Fix minor typo in comment.
1445
26e7e1a0
AC
14462011-08-04 Thomas Quinot <quinot@adacore.com>
1447
1448 * gnatls.adb: Use Prj.Env.Initialize_Default_Project_Path to retrieve
1449 the project path.
1450
14512011-08-04 Robert Dewar <dewar@adacore.com>
1452
1453 * a-coinho.adb: Minor reformatting.
1454
14552011-08-04 Robert Dewar <dewar@adacore.com>
1456
1457 * a-coinho.ads: Minor reformatting.
1458
14592011-08-04 Vadim Godunko <godunko@adacore.com>
1460
1461 * s-atocou.ads, s-atocou.adb: New files.
1462 * a-strunb-shared.ads, a-strunb-shared.adb, a-stwiun-shared.ads,
1463 a-stwiun-shared.adb, a-stzunb-shared.ads, a-stzunb-shared.adb: Remove
1464 direct use of GCC's atomic builtins and replace them by use of new
1465 atomic counter package.
1466
14672011-08-04 Ed Schonberg <schonberg@adacore.com>
1468
1469 * exp_strm.adb: better error message for No_Default_Stream_Attributes.
1470
14712011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
1472
1473 * a-tags.adb (Unregister_Tag): Replace the complex address arithmetic
1474 with a call to Get_External_Tag.
1475 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on
1476 subprogram usage. Remove the guard against package declarations and
1477 bodies since Build_Cleanup_Statements is no longer invoked in that
1478 context.
1479 (Build_Components): Initialize Tagged_Type_Stmts when the context
1480 contains at least one library-level tagged type.
1481 (Build_Finalizer): New local variables Has_Tagged_Types and
1482 Tagged_Type_Stmts along with associated comments on usage. Update the
1483 logic to include tagged type processing.
1484 (Create_Finalizer): Insert all library-level tagged type unregistration
1485 code before the jump block circuitry.
1486 (Expand_N_Package_Body): Remove the call to Build_Cleanup_Statements.
1487 (Expand_N_Package_Declaration): Remove the call to
1488 Build_Cleanup_Statements.
1489 (Process_Tagged_Type_Declaration): New routine. Generate a call to
1490 unregister the external tag of a tagged type.
1491 (Processing_Actions): Reimplemented to handle tagged types.
1492 (Process_Declarations): Detect the declaration of a library-level
1493 tagged type and carry out the appropriate actions.
1494 (Unregister_Tagged_Types): Removed. The machinery has been directly
1495 merged with Build_Finalizer.
1496
7483c888
AC
14972011-08-04 Robert Dewar <dewar@adacore.com>
1498
1499 * bindgen.ads, gnatlink.adb, sem_ch4.adb, gnatbind.adb, put_alfa.adb,
1500 gnatls.adb, exp_ch3.adb: Minor reformatting.
1501
15022011-08-04 Marc Sango <sango@adacore.com>
1503
1504 * sem_attr.adb (Analyze_Attribute): Replace the message
1505 "invisible attribute of}" of the spark restriction violation in
1506 attribute reference by the simple message "invisible attribute of type".
1507 Indeed, the node value Error_Msg_Node_1 used is in conflit with the
1508 two insertion characters: '&' and '}'.
1509
15102011-08-04 Vadim Godunko <godunko@adacore.com>
1511
1512 * impunit.adb (Non_Imp_File_Names_12): Add "a-coinho".
1513 * a-coinho.ads, a-coinho.adb: New file.
1514 * Makefile.rtl: Add Ada.Containers.Indefinite_Holders.
1515
5207696c
AC
15162011-08-04 Nicolas Roche <roche@adacore.com>
1517
1518 * alfa_test.adb: Not all ali files are containing alfa information even
1519 if compiled with -gnatd.F. So suppress warning about missing ALFA
1520 information.
1521
15222011-08-04 Yannick Moy <moy@adacore.com>
1523
1524 * lib-xref-alfa.adb (Add_ALFA_Scope): use non-empty unique name for
1525 scope.
1526 * put_alfa.adb: Check that scope name is not empty.
1527
15282011-08-04 Ed Schonberg <schonberg@adacore.com>
1529
1530 * exp_ch3.adb (Stream_Operation_Ok): new predicate
1531 Needs_Elementary_Stream_Operation, to determine whether user-defined
1532 Read and Write attributes are available for the elementary components
1533 of the given type. If only the predefined attributes are available,
1534 then when restriction No_Default_Stream_Attributes is active the
1535 predefined stream attributes for the composite type cannot be created.
1536
15372011-08-04 Robert Dewar <dewar@adacore.com>
1538
1539 * bindgen.adb: Fix obsolete comments and names from Ada/C days.
1540 Put routines in alpha order
1541
2bd2d858
JR
15422011-08-04 Jose Ruiz <ruiz@adacore.com>
1543
1544 * gcc-interface/Makefile.in: Remove xenomai specific versions of system.
1545 * gcc-interface/Make-lang.in: Update dependencies.
1546
8fae6016
AC
15472011-08-04 Arnaud Charlet <charlet@adacore.com>
1548
1549 * gcc-interface/lang.opt: Add AdaWhy language, simimlar to Ada.
1550 * gcc-interface/lang-specs.h: Add handling of AdaWhy specs (calls
1551 gnat1why).
1552
a54d0eb4
AC
15532011-08-04 Robert Dewar <dewar@adacore.com>
1554
1555 * sem_ch3.adb, make.adb, a-cohata.ads, sem_prag.adb, makeutl.adb,
1556 lib-xref-alfa.adb: Minor reformatting.
1557
15582011-08-04 Marc Sango <sango@adacore.com>
1559
1560 * sem_ch12.adb (Analyze_Generic_Package_Declaration,
1561 Analyze_Generic_Subprogram_Declaration, Analyze_Package_Instantiation,
1562 Analyze_Subprogram_Instantiation): Check absence of generic in SPARK
1563 mode.
1564
15652011-08-04 Tristan Gingold <gingold@adacore.com>
1566
1567 * bindgen.adb (Gen_Adainit_C): Remove.
1568 (Gen_Adafinal_C): Ditto.
1569 (Gen_Elab_Externals_C): Ditto.
1570 (Gen_Elab_Calls_C): Ditto.
1571 (Gen_Elab_Order_C): Ditto.
1572 (Gen_Elab_Defs_C): Ditto.
1573 (Gen_Finalize_Library_C): Ditto.
1574 (Gen_Finalize_Library_Defs_C): Ditto.
1575 (Gen_Main_C): Ditto.
1576 (Gen_Output_File_C): Ditto.
1577 (Gen_Restrictions_C): Ditto.
1578 (Gen_Versions_C): Ditto.
1579 (Write_Info_Ada_C): Ditto.
1580 (Gen_Object_Files_Options): Call WBI instead of Write_Info_Ada_C
1581 (Gen_Output_File): Do not force Ada_Bind_File anymore.
1582 Always call Gen_Output_File_Ada.
1583 * gnatlink.adb (Begin_Info): Now a constant.
1584 (End_Info): Ditto.
1585 (Ada_Bind_File): Remove
1586 (Process_Args): Do not handle -A/-C. Remove not Ada_Bind_File cases.
1587 * switch-b.adb (Scan_Binder_Switches): Do not handle -C.
1588 * gnatbind.adb (Gnatbind): Remove not Ada_Bind_File cases.
1589 * opt.ads (Ada_Bind_File): Remove.
1590
15912011-08-04 Thomas Quinot <quinot@adacore.com>
1592
1593 * projects.texi: Document target-specific directory in default project
1594 path for gnatmake.
1595
15962011-08-04 Thomas Quinot <quinot@adacore.com>
1597
1598 * gnatls.adb, prj-env.adb: Add $prefix/share/gpr to default project
1599 path in all cases .
1600
24558db8
AC
16012011-08-04 Yannick Moy <moy@adacore.com>
1602
1603 * sem_ch3.adb, sem_ch5.adb, sem_util.adb, sem_ch4.adb, sem_ch8.adb,
1604 opt.ads, lib-xref.ads: Code clean up.
1605
16062011-08-04 Yannick Moy <moy@adacore.com>
1607
1608 * gnat_rm.texi: Update description of Test_Case
1609 * gnat_ugn.texi: Typo.
1610
16112011-08-04 Ed Falis <falis@adacore.com>
1612
1613 * adaint.c (__gnat_get_number_of_cpus): fix typo in last checkin.
1614
16152011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
1616
1617 * exp_ch4.adb (Suitable_Element): Skip field _parent on .NET/JVM when
1618 it is of type Root_Controlled. This action eliminates fields Prev and
1619 Next from type equality.
1620
16212011-08-04 Yannick Moy <moy@adacore.com>
1622
1623 * lib-xref-alfa.adb: Correct typo.
1624
16252011-08-04 Matthew Heaney <heaney@adacore.com>
1626
1627 * a-cohata.ads (Hash_Table_Type): default-initialize the Nodes
1628 component.
1629
1f9939b5
AC
16302011-08-04 Yannick Moy <moy@adacore.com>
1631
1632 * sem_prag.adb (Check_Arg_Is_String_Literal): remove useless procedure
1633 (Analyze_Pragma): allow static string expression for name of Test_Case,
1634 instead of simply string literals.
1635 * sem_util.adb (Get_Name_From_Test_Case_Pragma): adapt to static string
1636 expressions.
1637
16382011-08-04 Vincent Celier <celier@adacore.com>
1639
1640 * makeutl.adb (Complete_Mains.Find_File_Add_Extension): Use canonical
1641 case suffixes to find truncated main sources.
1642
16432011-08-04 Tristan Gingold <gingold@adacore.com>
1644
1645 * impunit.adb (Non_Imp_File_Names_95): Add g-tastus.
1646 s-stusta.adb (Compute_All_Task): Use Put_Line instead of Put.
1647 (Compute_Current_Task): Ditto.
1648
16492011-08-04 Tristan Gingold <gingold@adacore.com>
1650
1651 * gnat_ugn.texi: Mention GNAT.Task_Stack_Usage.
1652
16532011-08-04 Yannick Moy <moy@adacore.com>
1654
1655 * lib-xref-alfa.adb (Is_Global_Constant): new function that detects
1656 library-level constant.
1657 (Add_ALFA_Xrefs): ignore global constants in ALFA xref.
1658 * sem_res.adb (Resolve_Actuals): do not add cross-reference to Formal
1659 used as selector of parameter association, in ALFA mode.
1660
15d8a51d
AC
16612011-08-04 Robert Dewar <dewar@adacore.com>
1662
1663 * exp_ch5.adb, exp_ch7.adb, exp_util.adb, bindgen.adb, sem_prag.adb,
1664 s-tassta.adb, exp_ch4.adb, exp_disp.adb, s-stausa.adb: Minor
1665 reformatting.
1666
16672011-08-04 Arnaud Charlet <charlet@adacore.com>
1668
1669 * make.adb (Linking_Phase): Set source search path before calling
1670 gnatlink in CodePeer mode.
1671
f46faa08
AC
16722011-08-04 Javier Miranda <miranda@adacore.com>
1673
1674 * exp_ch7.adb (Expand_N_Package_Body, Expand_N_Package_Declaration):
1675 Remove code which takes care of building TSDs.
1676 * rtsfind.ads (RE_Check_Interface_Conversion): New entity.
1677 * exp_ch4.adb (Apply_Accessibility_Check): Add support for generating
1678 the accessibility check in VM targets.
1679 * exp_disp.adb (Make_VM_TSD): Spec moved to exp_disp.ads
1680 (Building_Static_DT): Now returns false for VM targets.
1681 (Build_VM_TSDs): Removed.
1682 (Expand_Interface_Conversion): Generate missing runtime check for
1683 conversions to interface types whose target type is unknown at compile
1684 time.
1685 (Make_VM_TSD): Add missing code to disable the generation of calls to
1686 Check_TSD if the tagged type is not defined at library level, or not
1687 has a representation clause specifying its external tag, or -gnatdQ is
1688 active.
1689 * exp_disp.ads (Build_VM_TSDs): Removed.
1690 (Make_VM_TSDs): Spec relocated from exp_disp.adb
1691 * sem_disp.adb (Check_Dispatching_Operation): No code required to
1692 register primitives in the dispatch tables in VM targets.
1693 * exp_ch3.adb (Expand_N_Object_Declaration): Remove wrong expansion of
1694 initialization of class-wide interface objects in VM targets.
1695 (Expand_Freeze_Record_Type): For VM targets call Make_VM_TSD (instead
1696 of Make_DT).
1697
16982011-08-04 Jerome Lambourg <lambourg@adacore.com>
1699
1700 * gnatlink.adb (Gnatlink): Correct missleading error message displayed
1701 when dotnet-ld cannot be found.
1702
17032011-08-04 Arnaud Charlet <charlet@adacore.com>
1704
1705 * bindgen.adb: Simplify significantly generation of binder body file in
1706 CodePeer mode.
1707 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Prevent assert failure
1708 when compiling binder generated file in CodePeer mode (xxx'Elab_Spec
1709 not expanded).
1710
2ba7e31e
AC
17112011-08-04 Yannick Moy <moy@adacore.com>
1712
1713 * sem_prag.adb, sem.ads: Code cleanup.
1714
17152011-08-04 Tristan Gingold <gingold@adacore.com>
1716
1717 * s-tassta.adb (Task_Wrapper): Rewrite the dynamic stack usage part.
1718 * s-stausa.adb, s-stausa.ads: Major rewrite. Now provides accurate
1719 results if possible.
1720 * s-stusta.adb (Print): Adjust after changes in s-stausa.
1721 * gnat_ugn.texi: Update dynamic stack usage section.
1722
17232011-08-04 Steve Baird <baird@adacore.com>
1724
1725 * bindgen.adb (Gen_CodePeer_Wrapper): new procedure.
1726 Generate (if CodePeer_Mode is set) a "wrapper" subprogram which
1727 contains only a call to the user-defined main subprogram.
1728 (Gen_Main_Ada) - If CodePeer_Mode is set, then
1729 call the "wrapper" subprogram instead of directly
1730 calling the user-defined main subprogram.
1731
17322011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
1733
1734 * exp_ch5.adb (Expand_N_Case_Statement): Check the statements of all
1735 alternatives of a case statement for controlled objects. Rename local
1736 variable A to Dead_Alt.
1737 (Expand_N_If_Statement): Check the then and else statements of an if
1738 statement for controlled objects. Check the then statements of all
1739 elsif parts of an if statement for controlled objects.
1740 (Expand_N_Loop_Statement): Check the statements of a loop for controlled
1741 objects.
1742 * exp_ch7.adb (Process_Transient_Objects): Rewrite the condition which
1743 detects a loop associated with the expansion of an array object.
1744 Augment the processing of the loop statements to account for a possible
1745 wrap done by Process_Statements_For_Controlled_Objects.
1746 * exp_ch9.adb (Expand_N_Asynchronous_Select): Check the triggering
1747 statements and abortable part of an asynchronous select for controlled
1748 objects.
1749 (Expand_N_Conditional_Entry_Call): Check the else statements of a
1750 conditional entry call for controlled objects.
1751 (Expand_N_Selective_Accept): Check the alternatives of a selective
1752 accept for controlled objects.
1753 (Expand_N_Timed_Entry_Call): Check the entry call and delay
1754 alternatives of a timed entry call for controlled objects.
1755 * exp_ch11.adb (Expand_Exception_Handlers): Check the statements of an
1756 exception handler for controlled objects.
1757 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
1758 Add formal parameter Nested_Constructs along with its associated
1759 comment.
1760 (Requires_Cleanup_Actions (Node_Id)): Update all calls to
1761 Requires_Cleanup_Actions.
1762 (Process_Statements_For_Controlled_Objects): New routine.
1763 * exp_util.ads (Process_Statements_For_Controlled_Objects): New
1764 routine. Inspect a node which contains a non-handled sequence of
1765 statements for controlled objects. If such an object is found, the
1766 statements are wrapped in a block.
1767
1bf773bb
AC
17682011-08-04 Bob Duff <duff@adacore.com>
1769
1770 * sem_type.adb (Covers): If T2 is a subtype of a class-wide type, we
1771 need to compare with Class_Wide_Type (T2), in order to get at the
1772 original class-wide type node.
1773 * sem_type.ads (Covers): Improve the comment.
1774 * einfo.ads (Class_Wide_Type): Improve the comment.
1775 * exp_intr.adb (Expand_Unc_Deallocation): Remove unnecessary setting of
1776 the type of the Deref.
1777
17782011-08-04 Yannick Moy <moy@adacore.com>
1779
1780 * gnat_rm.texi: Document that Test_Case pragma can only appear on
1781 separate declarations.
1782 * sem_prag.adb (procedure Check_Identifier_Is_One_Of): new procedure to
1783 check identifier of pragma argument.
1784 (Chain_TC): check that no other test case associated to the same entity
1785 share the same name.
1786 (Check_Test_Case): disallow test case inside subprogram body
1787 (Analyze_Pragma): correct call to check identifier and not argument
1788 * sem_util.adb, sem_util.ads (Get_Name_From_Test_Case_Pragma): new
1789 function gets name from test case pragma.
1790
dac3bede
YM
17912011-08-04 Yannick Moy <moy@adacore.com>
1792
1793 * gnat_rm.texi: Document new pragma and aspect.
1794 * aspects.adb, aspects.ads (Aspect_Id): new value Aspect_Test_Case
1795 (No_Duplicates_Allowed): new constant array defining whether duplicates
1796 aspects of each kind can appear on the same declaration.
1797 * einfo.adb, einfo.ads (Spec_PPC_List): replace field with Contract
1798 field, which points to a node holding the previous Spec_PPC_List.
1799 * exp_ch9.adb, sem_ch6.adb, sem_prag.adb: Reach to Spec_PPC_List
1800 through the indirection with Contract.
1801 * exp_util.adb (Insert_Actions): raise Program_Error on N_Contract node
1802 * par-prag.adb (Prag): do nothing on Test_Case pragma
1803 * sem.adb (Analyze): abort on N_Contract, on which Analyze should not
1804 be called directly.
1805 * sem_attr.adb (Analyze_Attribute): allow attribute 'Result in
1806 component Ensures of Test_Case.
1807 * sem_ch12.adb, sem_ch6.adb, sem_ch9.adb
1808 (Analyze_Generic_Subprogram_Declaration,
1809 Analyze_Subprogram_Instantiation,
1810 Analyze_Abstract_Subprogram_Declaration,
1811 Analyze_Subprogram_Body_Helper,
1812 Analyze_Subprogram_Specification, Analyze_Entry_Declaration):
1813 insert contract in subprogram node at point of definition
1814 * sem_ch13.adb
1815 (Aspect_Loop): do not raise error on duplicate Test_Case aspect
1816 (Analyze_Aspect_Specifications): analyze Test_Case aspect and create
1817 corresponding pragma
1818 (Check_Aspect_At_Freeze_Point): raise Program_Error on Test_Case aspect
1819 * sem_ch3.adb (Analyze_Declarations): insert analysis of test-cases,
1820 similar to the analysis of pre/post
1821 (Derive_Subprogram): insert contract in subprogram node at point of
1822 derivation.
1823 * sem_prag.adb, sem_prag.ads
1824 (Check_Arg_Is_String_Literal, Check_Identifier):
1825 new checking procedures to be called in treatment of pragmas
1826 (Check_Test_Case): new procedure to check that a Test_Case aspect or
1827 pragma is well-formed. This does not check currently that 'Result is
1828 used only in the Ensures component of a Test_Case.
1829 (Analyze_Pragma): add case for Test_Case
1830 (Analyze_TC_In_Decl_Part): pre-analyze the Requires and Ensures
1831 components of a Test_Case.
1832 (Preanalyze_TC_Args): new procedure to preanalyze the boolean
1833 expressions in the 3rd (and 4th if present) arguments of a Test_Case
1834 pragma, treated as spec expressions.
1835 (Sig_Flags): add value -1 for Test_Case.
1836 * sem_util.adb, sem_util.ads (Get_Ensures_From_Test_Case_Pragma,
1837 Get_Requires_From_Test_Case_Pragma): getters for both expression
1838 components of a Test_Case.
1839 * sinfo.adb, sinfo.ads (N_Contract): new kind of node used as
1840 indirection between an entry or [generic] subprogram entity and its
1841 pre/post + test-cases.
1842 (Spec_PPC_List, Spec_TC_List, Set_Spec_PPC_List, Set_Spec_TC_List):
1843 get/set for fields of an N_Contract node.
1844 * snames.ads-tmpl (Name_Test_Case, Name_Ensures, Name_Mode,
1845 Name_Normal, Name_Requires, Name_Robustness, Pragma_Test_Case): new
1846 names and pragma for Test_Case.
1847 * sprint.adb (Sprint_Node): raise Program_Error on N_Contract node
1848
6a2e5d0f
AC
18492011-08-04 Vincent Celier <celier@adacore.com>
1850
1851 * gnat_ugn.texi: Improve documentation of gnatmake switch
1852 --source-info-file=.
1853
18542011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
1855
1856 * exp_ch7.adb (Make_Final_Call): Add local variable Atyp (assertion
1857 type). Initialize Atyp to the appropriate type which is later checked
1858 for completion. Rewrite the assertion associated with private type
1859 completion.
1860
18612011-08-04 Ed Falis <falis@adacore.com>
1862
1863 * adaint.c: Add call to vxCpuConfiguredGet for VxWorks SMP to
1864 initialize the number of CPUs.
1865
18662011-08-04 Ed Schonberg <schonberg@adacore.com>
1867
1868 * sem_type.adb (Disambiguate): New subsidiary routine
1869 In_Same_Declaration_List, to implement AI05-0020: a user-defined
1870 equality on an anonymous access type whose designated type is private
1871 does not lead to an ambiguity with the universal access equality
1872 operator in the body or child units of the defining package. The same
1873 is true for a multiplication operator on a private type completed with
1874 a fixed-point-type.
1875
18762011-08-04 Javier Miranda <miranda@adacore.com>
1877
1878 * opt.ads (Init_Or_Norm_Scalars_Config): Removed.
1879 (Normalize_Scalars_Config): Removed.
1880 * opt.adb
1881 (Register_Opt_Config_Switches): Remove registering config values of
1882 Init_Or_Norm_Scalars_Config and Normalize_Scalars_Config.
1883 (Restore_Opt_Config_Switches): Remove code which restores the values of
1884 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
1885 Init_Or_Norm_Scalars.
1886 (Save_Opt_Config_Switches): Remove code which saves values of
1887 Init_Or_Norm_Scalars and Normalize_Scalars.
1888 (Set_Opt_Config_Switches): Remove code which restores config values of
1889 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
1890 Init_Or_Norm_Scalars.
1891
18922011-08-04 Yannick Moy <moy@adacore.com>
1893
1894 * frontend.adb (Frontend): remove previous patch to avoid full
1895 qualification in ALFA mode.
1896 * lib-xref-alfa.adb (Add_ALFA_Xrefs): use unique name for variables.
1897 * sem_util.adb, sem_util.ads (Unique_Name): new function to define a
1898 unique name for an entity, which could be used to identify the entity
1899 across compilation units.
1900
19012011-08-04 Thomas Quinot <quinot@adacore.com>
1902
1903 * prj-env.adb
1904 (Initialize_Default_Project_Path): Add target specific directory
1905 ($prefix/$target/lib/gnat) in front of project path in all cases
1906 (making gnatmake's behaviour consistent with gprbuild).
1907 * gnatcmd.adb, make.adb, prj-makr.adb, clean.adb:
1908 Pass target name from Sdefault to project subsystem.
1909 * gnatls.adb: Show new target specific default project directory.
1910
19112011-08-04 Johannes Kanig <kanig@adacore.com>
1912
1913 * cstand.adb: Add Information to Identifier in Standard
1914 (Identifer_For): Set Entity to the corresponding entity
1915
483361a6
AC
19162011-08-04 Sergey Rybin <rybin@adacore.com>
1917
1918 * gnat_ugn.texi: Update doc on gnatcheck.
1919
19202011-08-04 Yannick Moy <moy@adacore.com>
1921
1922 * lib-xref-alfa.adb (Add_ALFA_Xrefs): correct definition of ranges of
1923 xrefs in a scope.
1924
19252011-08-04 Yannick Moy <moy@adacore.com>
1926
1927 * exp_prag.adb (Expand_Pragma_Check): in ALFA mode, return without
1928 performing expansion.
1929 * sem_ch6.adb (Analyze_Subprogram_Body_Helper,
1930 Analyze_Generic_Subprogram_Body): protect call to Process_PCCs so that
1931 it is not called in ALFA mode.
1932
ef5569c6
AC
19332011-08-04 Emmanuel Briot <briot@adacore.com>
1934
1935 * make.adb, osint.adb, osint.ads (Reset_Command_Line_Files): not used
1936 after all, so removed.
1937
19382011-08-04 Sergey Rybin <rybin@adacore.com>
1939
1940 * vms_data.ads: Add missing VMS qualifiers.
1941
1ab4a286
EB
19422011-08-04 Emmanuel Briot <briot@adacore.com>
1943
1944 * make.adb, makeutl.adb, osint.adb, osint.ads (Check_Mains): rebuild
1945 the list of files on the command line after processing it through
1946 Complete_Mains.
1947
7ae0d98c
AC
19482011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
1949
1950 * exp_ch7.adb (Build_Raise_Statement): Remove the specialized
1951 processing for .NET/JVM. These targets can now benefit from
1952 Raise_From_Controlled_Operation and they share the same processing with
1953 standard targets.
1954 (Establish_Transient_Scope): Remove the restriction for .NET/JVM.
1955 These targets need transient scopes in order to properly finalize short
1956 lived controlled objects.
1957 (Make_Handler_For_Ctrl_Operation): Remove the specialized processing for
1958 NET/JVM. These targets can now benefit from
1959 Raise_From_Controlled_Operation and they share the same processing with
1960 standard targets.
1961
19622011-08-04 Geert Bosch <bosch@adacore.com>
1963
1964 * tracebak.c (STOP_FRAME): Stop at any next pointer outside the stack
1965
19662011-08-04 Ed Schonberg <schonberg@adacore.com>
1967
1968 * exp_aggr.adb (Has_Visible_Private_Ancestor): subsidiary routine to
1969 Expand_Record_Aggregate, to determine whether aggregate must be
1970 expanded into assignments. This is the case if the ancestor part is
1971 private, regarless of the setting of the flag Has_Private_Ancestor.
1972
19732011-08-04 Ed Falis <falis@adacore.com>
1974
1975 * vxaddr2line.adb: Add support for e500v2 and for Linux hosts
1976
19772011-08-04 Bob Duff <duff@adacore.com>
1978
1979 * sinfo.ads: Fix comment.
1980
19812011-08-04 Steve Baird <baird@adacore.com>
1982
1983 * bindgen.adb (Get_Ada_Main_Name): If CodePeer_Mode is set, then
1984 choose a package name in much the same way as is
1985 done for JGNAT when VM_Target /= No_VM, except that
1986 a slightly more distinctive prefix string is used.
1987
19882011-08-04 Emmanuel Briot <briot@adacore.com>
1989
1990 * makeutl.adb (Complete_Mains): no longer accept unit names on the
1991 gnatmake command line.
1992 This behavior was never documented (and was supported only because of
1993 an early bug in the code). This case might lead to ambiguous cases
1994 (between unit names and truncated base names without suffixes).
1995
87729e5a
AC
19962011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
1997
1998 * a-tags.ads, a-tags.adb (Unregister_Tag): New routine.
1999 Remove the external tag of a tagged type from the internal hash table.
2000 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on the
2001 expanded usage of the routine. Strenghten the check for Is_Master. Add
2002 processing for tagged types.
2003 (Build_Finalizer): Create all the necessary lists used in finalizer
2004 creation when the processed context is a package that may contain
2005 tagged types.
2006 (Expand_Cleanup_Actions): Rename the call to Has_Controlled_Objects to
2007 Requires_Cleanup_Actions.
2008 (Expand_N_Package_Body): Package bodies may need clean up code
2009 depending on whether they contain tagged types.
2010 (Expand_N_Package_Declaration): Package declarations may need clean up
2011 code depending on whether they contain tagged types.
2012 (Unregister_Tagged_Types): New routine. Search through a list of
2013 declarations or statements, looking for non-abstract Ada tagged types.
2014 For each such type, generate code to unregister the external tag.
2015 * exp_util.adb (Has_Controlled_Objects (Node_Id)): Renamed to
2016 Requires_Cleanup_Actions.
2017 (Requires_Cleanup_Actions (List_Id, Boolean)): New routine. Search
2018 through a list of declarations or statements looking for non-abstract
2019 Ada tagged types or controlled objects.
2020 * exp_util.ads (Has_Controlled_Objects (Node_Id)): Renamed to
2021 Requires_Cleanup_Actions.
2022 (Has_Controlled_Objects (List_Id, Boolean)): Removed.
2023 * rtsfind.ads: Add entry RE_Unregister_Tag to tables RE_Id and
2024 RE_Unit_Table.
2025
20262011-08-04 Vincent Celier <celier@adacore.com>
2027
2028 * prj-env.adb (For_All_Source_Dirs.For_Project): Check if project Prj
2029 has Ada sources, not project Project, because if the root project
2030 Project has no sources of its own, all projects will be deemed without
2031 sources.
2032
20332011-08-04 Gary Dismukes <dismukes@adacore.com>
2034
2035 * bindgen.adb (Gen_Adainit_Ada): Move the generation of the declaration
2036 of the No_Param_Proc acc-to-subp type used for initialization of
2037 __gnat_finalize_library_objects so that it's declared at library level
2038 rather than nested inside of the adainit routine.
2039
20402011-08-04 Javier Miranda <miranda@adacore.com>
2041
2042 * exp_disp.adb (Make_DT): Generate code to check the external tag ONLY
2043 if the tagged type has a representation clause which specifies its
2044 external tag.
2045
20462011-08-04 Ed Schonberg <schonberg@adacore.com>
2047
2048 * einfo.ads, einfo.adb (Has_Private_Ancestor): now a flag on types.
2049 Remove previous procedure with that name.
2050 * sem_ch3.adb (Build_Derived_Record_Type): set Has_Private_Ancestor
2051 when appropriate.
2052 * sem_aggr.adb (Resolve_Extension_Aggregate): if the ancestor part is a
2053 subtype mark, the ancestor cannot have unknown discriminants.
2054 (Resolve_Record_Aggregate): if the type has invisible components
2055 because of a private ancestor, the aggregate is illegal.
2056
20572011-08-04 Vincent Celier <celier@adacore.com>
2058
2059 * switch-m.adb (Normalize_Compiler_Switches): Recognize and take into
2060 account switches -gnat2005, -gnat12 and -gnat2012.
2061
20622011-08-04 Bob Duff <duff@adacore.com>
2063
2064 * s-tasdeb.ads: Minor comment fix.
2065
20662011-08-04 Arnaud Charlet <charlet@adacore.com>
2067
2068 * gnatlink.adb (Gnatlink): Pass -gnat83/95/05/12 switch to gcc in
2069 CodePeer mode.
2070 * switch.ads, switch.adb (Is_Language_Switch): New function.
2071
20722011-08-04 Vincent Celier <celier@adacore.com>
2073
2074 * switch-c.adb: Minor comment addition.
2075
20762011-08-04 Vincent Celier <celier@adacore.com>
2077
2078 * vms_conv.adb (Process_Argument): Fail graciously when qualifier
2079 ending with '=' is followed by a space (missing file name).
2080
20812011-08-04 Pascal Obry <obry@adacore.com>
2082
2083 * g-regist.ads: Fix size of HKEY on x86_64-windows.
2084
20852011-08-04 Ed Schonberg <schonberg@adacore.com>
2086
2087 * sem_ch12.adb (Analyze_Associations): New routine
2088 Check_Overloaded_Formal_Subprogram to reject a formal package when
2089 there is a named association or a box initialisation for an overloaded
2090 formal subprogram of the corresponding generic.
2091
20922011-08-04 Yannick Moy <moy@adacore.com>
2093
2094 * alfa.ads (ALFA_Xref_Record): add component for type of entity
2095 * get_alfa.adb, put_alfa.adb: Read and write new component of
2096 cross-reference.
2097 * lib-xref-alfa.adb (Collect_ALFA): generate new component.
2098
88f47280
AC
20992011-08-04 Pascal Obry <obry@adacore.com>
2100
2101 * urealp.adb: Minor reformatting.
2102
21032011-08-04 Tristan Gingold <gingold@adacore.com>
2104
2105 * exp_ch7.adb (build_finalizer.process_declarations.processing_actions):
2106 Handle the case when Cleanup_Protected_Object returns Empty.
2107
21082011-08-04 Yannick Moy <moy@adacore.com>
2109
2110 * frontend.adb (Frontend): only qualify names in non-ALFA mode
2111
21122011-08-04 Ed Schonberg <schonberg@adacore.com>
2113
2114 * sem_ch4.adb (Try_Class_Wide_Operation): if the context is a procedure
2115 call, ignore functions.
2116
05c53a69
GB
21172011-08-04 Geert Bosch <bosch@adacore.com>
2118
2119 * urealp.adb (Equivalent_Decimal_Exponent): Avoid the use of floating
2120 point.
2121
23cc1ace
EB
21222011-08-04 Emmanuel Briot <briot@adacore.com>
2123
2124 * makeutl.adb (Compute_Builder_Switches): no longer accept a unit name
2125 as an index for Builder'Switches. This conforms to the documentation.
2126 * make.adb (Insert_Project_Sources): avoid duplicate code
2127
cef14201
AC
21282011-08-04 Emmanuel Briot <briot@adacore.com>
2129
2130 * makeutl.adb (Complete_Mains): if the user has passed a relative file
2131 name on the command line (for instance "../dummy"), never assume it can
2132 be a unit name.
2133
21342011-08-04 Tristan Gingold <gingold@adacore.com>
2135
2136 * bindgen.adb: Remove code the reference or create the
2137 Break_Start/__gnat_break_start procedure.
2138 * s-stalib.adb (Break_Start): Removed.
2139
e2fee30d
EB
21402011-08-04 Emmanuel Briot <briot@adacore.com>
2141
2142 * make.adb, makeutl.adb, makeutl.ads (Compute_Builder_Switches): now
2143 shared with gprbuild.
2144
2d395256
AC
21452011-08-04 Yannick Moy <moy@adacore.com>
2146
2147 * par-ch4.adb (P_Primary): preferentially issue an error message about
2148 a missing parenthesis arount a conditional or case expression in Ada
2149 2012 mode, if we detect that the alignment is not correct for a
2150 statement.
2151
21522011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2153
2154 * exp_ch7.adb (Process_Declarations): Do not consider the result of a
2155 tag-to-class-wide conversion as needing finalization actions.
2156 * exp_util.adb (Has_Controlled_Objects): Do not consider the result of
2157 a tag-to-class-wide conversion as needing finalization actions.
2158 (Is_Finalizable_Transient): The result of a tag-to-class-wide
2159 conversion does not need finalization actions.
2160 (Is_Tag_To_CW_Conversion): New routine.
2161 * exp_util.ads (Is_Tag_To_CW_Conversion): New routine. Determines
2162 whether an object is the result of a tag-to-class-wide conversion.
2163
21642011-08-04 Yannick Moy <moy@adacore.com>
2165
2166 * sem_ch13.adb (Analyze_Aspect_Specifications): correct order in which
2167 the left-hand-side and right-hand-side of a conjunct are inserted when
2168 translating a pre- or postcondition
2169 * sem_ch6.adb: Correct typo in comment
2170
21712011-08-04 Ed Schonberg <schonberg@adacore.com>
2172
2173 * gnat_rm.texi: Ravenscar does not prohibit dependence on
2174 Unchecked_Conversion and Unchecked_Deallocation.
2175
21762011-08-04 Thomas Quinot <quinot@adacore.com>
2177
2178 * make.adb: Minor reformatting.
2179
767ab2fd
EB
21802011-08-04 Emmanuel Briot <briot@adacore.com>
2181
2182 * prj.adb, prj.ads, makeutl.adb (Complete_Mains): search for the
2183 sources in the project and its imported projects, but not in the whole
2184 tree.
2185
8fb3f5df
AC
21862011-08-04 Emmanuel Briot <briot@adacore.com>
2187
2188 * make.adb: Remove debug trace.
2189
21902011-08-04 Vincent Celier <celier@adacore.com>
2191
2192 * makeutl.adb (Do_Complete): Get the absolute path name of a relative
2193 path in canonical form, to be able to compare path names on platforms
2194 such as Windows or Darwin.
2195
21962011-08-04 Thomas Quinot <quinot@adacore.com>
2197
2198 * par_sco.adb (Traverse_Declarations_Or_Statements.Set_Statement_Entry):
2199 For a pragma (statement with C1 = 'P'), record the sloc of the pragma.
2200 * scos.ads: Update documentation accordingly.
2201 * put_scos.adb (Output_SCO_Line): Omit statement SCOs for disabled
2202 pragmas.
2203
9515740f
AC
22042011-08-04 Ed Schonberg <schonberg@adacore.com>
2205
2206 * sem_attr.adb (Bad_Attribute_For_Predicate): flag illegal use of
2207 attribute only if prefix type is scalar.
2208
22092011-08-04 Emmanuel Briot <briot@adacore.com>
2210
2211 * make.adb, makeutl.adb, prj-env.adb (Check_Mains): put back support
2212 in gnatmake for specifying mains on the command line that do not belong
2213 to the main project. These mains must currently all belong to the same
2214 project, though.
2215 (Ultimate_Extension_Of): removed, since duplicated
2216 Ultimate_Extending_Project.
2217
92966893
AC
22182011-08-04 Arnaud Charlet <charlet@adacore.com>
2219
2220 * make.adb (Do_Codepeer_Globalize_Step): Removed. Use CodePeer_Mode
2221 instead.
2222 (CodePeer_Mode_String): New.
2223 (Linking_Phase, Binding_Phase): Call gnatlink with -P switch in
2224 CodePeer mode.
2225 (Scan_Make_Arg): Do not disable binding/linking phase in CodePeer mode.
2226 * bindgen.adb (Gen_Elab_Calls_Ada): Ignore subprograms in CodePeer
2227 mode, since no useful elaboration subprogram is needed by CodePeer.
2228 * gnatlink.adb (Gnatlink): Add support for -P switch (CodePeer mode).
2229 In this mode, compile binder file with -gnatC and do stop after this
2230 step.
2231
22322011-08-04 Vincent Celier <celier@adacore.com>
2233
2234 * exp_ch7.adb: Minor comment fix.
2235
5969611f
RD
22362011-08-04 Robert Dewar <dewar@adacore.com>
2237
2238 * exp_ch7.adb, make.adb, sem_ch10.adb, bindgen.adb, sem_res.adb,
2239 exp_ch4.adb, makeutl.adb: Minor reformatting.
2240
6367dd30
AC
22412011-08-04 Emmanuel Briot <briot@adacore.com>
2242
2243 * make.adb, makeutl.adb, makeutl.ads (Make): major refactoring.
2244 Create several new subprograms to move code out of Make. This makes the
2245 code more readable, removes code duplication, and is a preparation work
2246 for adding support for aggregate projects.
2247
22482011-08-04 Tristan Gingold <gingold@adacore.com>
2249
2250 * s-po32gl.ads, s-po32gl.adb: New files.
2251 * exp_ch7.ads (Get_Global_Pool_For_Access_Type): New function.
2252 * exp_ch7.adb (Get_Global_Pool_For_Access_Type): New function.
2253 (Build_Finalization_Collection): Use it.
2254 * exp_ch4.adb (Complete_Controlled_Allocation): Ditto.
2255 * rtsfind.ads: System_Pool_32_Global, Re_Global_Pool_32_Object: New
2256 literals.
2257 * gcc-interface/Makefile.in: Use s-po32gl.o on VMS.
2258 * gcc-interface/Make-lang.in: Update dependencies.
2259
cd8bfe35
EB
22602011-08-04 Emmanuel Briot <briot@adacore.com>
2261
2262 * makeutl.adb (Complete_Mains): add support for specs with no suffix on
2263 the command line.
2264
7db29ea7
EB
22652011-08-04 Emmanuel Briot <briot@adacore.com>
2266
2267 * make.adb, makeutl.adb (Complete_Mains): if a main specified on the
2268 command line is not a file name, also check whether it could be a unit
2269 name.
2270
d9b056ea
AC
22712011-08-04 Eric Botcazou <ebotcazou@adacore.com>
2272
2273 * bindgen.adb (Gen_Finalize_Library_Ada): Factor out code to generate
2274 the header of the finalization routine.
2275 If the unit has no finalizer but is a body whose spec has one, then
2276 generate the decrement of the elaboration entity only.
2277 If the unit has a finalizer and is a spec, then do not generate the
2278 decrement of the elaboration entity.
2279 (Gen_Finalize_Library_C): Likewise.
2280
22812011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2282
2283 * exp_ch7.adb (Alignment_Of): New subsidiary routine.
2284 (Bounds_Size_Expression): Removed.
2285 (Double_Alignment_Of): New subsidiary routine.
2286 (Make_Finalize_Address_Stmts): New local variable Index_Typ. Account
2287 for a hole in the dope vector of unconstrained arrays due to different
2288 index and element alignments.
2289
22902011-08-04 Ed Schonberg <schonberg@adacore.com>
2291
2292 * sem_res.adb (Resolve_Allocator): diagnose task allocator that will
2293 raise program_error because body has not been seen yet.
2294
22952011-08-04 Ed Schonberg <schonberg@adacore.com>
2296
2297 * sem_ch10.adb (Analyze_With_Clause): Protect against child unit with
2298 an unresolved name.
2299
23002011-08-04 Vincent Celier <celier@adacore.com>
2301
2302 * makeutl.adb (Do_Complete): Check absolute paths in canonical forms
2303
23042011-08-04 Yannick Moy <moy@adacore.com>
2305
2306 * alfa.adb, alfa.ads (Unique_Defining_Entity): move function from here
2307 * sem_util.adb, sem_util.ads (Unique_Defining_Entity): ...to here
2308
23092011-08-04 Thomas Quinot <quinot@adacore.com>
2310
2311 * sem_ch12.adb (Analyze_Package_Instantiation): Do not omit body for
2312 instantiation in RCI.
2313
23142011-08-04 Emmanuel Briot <briot@adacore.com>
2315
2316 * make.adb: Share more code with gprbuild
2317
f5fc5b9d
AC
23182011-08-04 Emmanuel Briot <briot@adacore.com>
2319
2320 * projects.texi: Added documentation for the IDE'Gnat project file
2321 attribute.
2322
23232011-08-04 Nicolas Roche <roche@adacore.com>
2324
2325 * gnat_rm.texi: Minor editing.
2326
23272011-08-04 Javier Miranda <miranda@adacore.com>
2328
2329 * bindgen.adb (Gen_Adafinal_Ada): Do not differentiate the main case
2330 and the library case for VM targets.
2331 (Gen_Adainit_Ada): Likewise.
2332
23332011-08-04 Robert Dewar <dewar@adacore.com>
2334
2335 * g-altive.ads: Minor comment updates.
2336 * prj-nmsc.adb: Minor reformatting.
2337
23382011-08-04 Javier Miranda <miranda@adacore.com>
2339
2340 * opt.ads
2341 (Normalize_Scalars_Config): Value of the configuration switch set by
2342 pragma Normalize_Scalars when it appears in the gnat.adc file.
2343 (Normalize_Scalars): New field for record Config_Switches_Type. Used
2344 to save and restore settings of this pragma.
2345 * opt.adb
2346 (Register_Opt_Config_Switches, Save_Opt_Config_Switches,
2347 Restore_Opt_Config_Switches): Add missing support for Normalize_Scalars.
2348
23492011-08-04 Vincent Celier <celier@adacore.com>
2350
2351 * gnat_ugn.texi: Document gnatlink options -M and -M=mapfile
2352
0c4683cf
AC
23532011-08-04 Arnaud Charlet <charlet@adacore.com>
2354
2355 * makeutl.adb: Minor reformatting.
2356
23572011-08-04 Olivier Hainque <hainque@adacore.com>
2358
2359 * g-altive.ads: Update comments to reflect that only the soft
2360 binding is available today.
2361
2598ee6d
RD
23622011-08-04 Robert Dewar <dewar@adacore.com>
2363
2364 * bindgen.adb, einfo.adb, sem_ch12.adb, s-tasren.adb, sem_res.adb,
2365 makeutl.adb, prj-nmsc.adb, opt.ads, prj-env.adb: Minor reformatting
2366 * gcc-interface/Make-lang.in: Update dependencies.
2367
c2db4b32
AC
23682011-08-04 Arnaud Charlet <charlet@adacore.com>
2369
2370 * prj-env.adb: Remove local debug traces.
2371
23722011-08-04 Yannick Moy <moy@adacore.com>
2373
2374 * checks.adb (Apply_Float_Conversion_Check): correct a typo where Lo_OK
2375 was used instead of Hi_OK, which could cause a read of an uninitialized
2376 value later on. Detected while working on the new warning.
2377 * exp_ch9.adb (Expand_N_Entry_Declaration): remove useless assignment
2378 to local variable.
2379 * sem_ch5.adb (Analyze_Assignment): set the last assignment component
2380 in more cases, in order to detect more unreferenced values.
2381 * sem_util.adb, sem_util.ads (Get_Enclosing_Object): return enclosing
2382 object for expression, if any.
2383
23842011-08-04 Eric Botcazou <ebotcazou@adacore.com>
2385
2386 * exp_intr.adb (Expand_Binary_Operator_Call): Look at the RM size of
2387 the operand types instead of the Esize.
2388
23892011-08-04 Steve Baird <baird@adacore.com>
2390
2391 * switch-b.adb (Scan_Binder_Switches): Add -P binder switch, used to
2392 enable CodePeer_Mode.
2393 * bindusg.adb (Display): Add help message describing -P binder switch.
2394 * gnat_ugn.texi: Document -P binder switch.
2395 * bindgen.adb (Gen_Main_Ada): If CodePeer_Mode is set, then call the
2396 user-defined main program directly.
2397 (Gen_Output_File_Ada): If CodePeer_Mode is set, generate a with of the
2398 user-defined main program in the context clause of the package body.
2399
ad05f2e9
AC
24002011-08-04 Yannick Moy <moy@adacore.com>
2401
2402 * alfa.adb, alfa.ads (Get_Entity_For_Decl): remove function, partial
2403 duplicate of Defining_Entity
2404 (Get_Unique_Entity_For_Decl): rename function into
2405 Unique_Defining_Entity
2406 * einfo.adb, einfo.ads (Is_In_ALFA, Body_Is_In_ALFA): remove flags
2407 (Formal_Proof_On): remove synthesized flag
2408 * cstand.adb, sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
2409 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_res.adb, sem_util.adb,
2410 sem_util.ads, stand.ads: Remove treatment associated to entities in ALFA
2411 * sem_prag.adb (Analyze_Pragma): remove special treatment for pragma
2412 Annotate (Formal_Proof)
2413
24142011-08-04 Emmanuel Briot <briot@adacore.com>
2415
2416 * prj-env.adb (Create_Config_Pragmas_File): fix handling of multi-unit
2417 source files with non-standard naming schemes, in imported projects
2418
756ef2a0
AC
24192011-08-04 Emmanuel Briot <briot@adacore.com>
2420
2421 * makeutl.adb (Complete_Mains): when a multi-unit source file is
2422 specified on the gprbuild command line, we need to compile all units
2423 within that file, not just the first one we find
2424 Fix error message for mains that are not found.
2425
24262011-08-04 Thomas Quinot <quinot@adacore.com>
2427
2428 * sem_ch6.adb: Update comment.
2429 * sem_ch12.adb: Minor reformatting.
2430
24312011-08-04 Bob Duff <duff@adacore.com>
2432
2433 * s-tasren.adb (Task_Do_Or_Queue): Previous code was reading
2434 Acceptor.Terminate_Alternative without locking Acceptor, which causes a
2435 race condition whose symptom is to fail to lock Parent. That, in turn,
2436 causes Parent.Awake_Count to be accessed without locking Parent, which
2437 causes another race condition whose symptom is that Parent.Awake_Count
2438 can be off by 1 (either too high or too low). The solution is to lock
2439 Parent unconditionally, and then lock Acceptor, before reading
2440 Acceptor.Terminate_Alternative.
2441
4fdebd93
AC
24422011-08-04 Arnaud Charlet <charlet@adacore.com>
2443
2444 * debug.adb: Update comment.
2445
24462011-08-04 Robert Dewar <dewar@adacore.com>
2447
2448 * par_sco.adb, exp_util.adb, make.adb, a-tags.adb, sem_prag.adb,
2449 sem_util.adb, sem_attr.adb, exp_ch4.adb, g-comlin.adb, g-comlin.ads,
2450 exp_ch6.adb: Minor reformatting.
2451
24522011-08-04 Gary Dismukes <dismukes@adacore.com>
2453
2454 * gnat_ugn.texi: Add sentence about the case of compile-time-detected
2455 checks for -gnateE.
2456
24572011-08-04 Ed Schonberg <schonberg@adacore.com>
2458
2459 * gnat_rm.texi: update Ravenscar desription to reflect Ada2012 RM.
2460
24612011-08-04 Thomas Quinot <quinot@adacore.com>
2462
2463 * sinfo.ads: Minor reformatting.
2464
24652011-08-04 Emmanuel Briot <briot@adacore.com>
2466
2467 * makeutl.adb, makeutl.ads, prj-nmsc.adb (Complete_Mains): report error
2468 even if there is no location.
2469
6aaa0587
ES
24702011-08-04 Ed Schonberg <schonberg@adacore.com>
2471
2472 * sem_res.adb, sem_ch4.adb: move check for restriction
2473 No_Task_Hierarchy to resolve_allocator.
2474
35a1c212
AC
24752011-08-04 Thomas Quinot <quinot@adacore.com>
2476
2477 * sinfo.adb, sinfo.ads, sem_prag.adb, sem_ch12.adb (Pragma_Enabled):
2478 This flag of N_Pragma nodes is not used, remove it as well as all of
2479 the associated circuitry.
2480
24812011-08-04 Javier Miranda <miranda@adacore.com>
2482
2483 * exp_disp.adb (Make_DT): Switch -gnatdQ disables the generation of the
2484 runtime check on duplicated externa tags
2485 * debug.adb Document switch -gnatdQ.
2486
24872011-08-04 Gary Dismukes <dismukes@adacore.com>
2488
2489 * a-fihema.ads: Minor typo fix.
2490
24912011-08-04 Yannick Moy <moy@adacore.com>
2492
2493 * sem_ch10.adb: Minor comment update.
2494
24952011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2496
2497 * einfo.adb: Update the node field usage to reflect the renaming of
2498 Return_Flag to Return_ Flag_Or_Transient_Decl.
2499 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl.
2500 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl.
2501 (Write_Field15_Name): Change Return_Flag to
2502 Return_Flag_Or_Transient_Decl.
2503 * einfo.ads: Rename node field Return_Flag to
2504 Return_Flag_Or_Transient_Decl. Update the associated comment and all
2505 occurrences in entities.
2506 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl. Update
2507 associated Inline pragma.
2508 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl. Update
2509 associated Inline pragma.
2510 * exp_ch4.ads, exp_ch4.adb (Expand_N_Expression_With_Actions): New
2511 routine.
2512 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Update the calls to
2513 Return_Flag and Set_Return_Flag.
2514 * exp_ch7.adb (Process_Declarations): Add code to recognize hook
2515 objects generated for controlled transients declared inside an
2516 Exception_With_Actions. Update the calls to Return_Flag.
2517 (Process_Object_Declaration): Add code to add a null guard for hook
2518 objects generated for controlled transients declared inside an
2519 Exception_With_Actions. Update related comment.
2520 * exp_util.adb (Has_Controlled_Objects): Add code to recognize hook
2521 objects generated for controlled transients declared inside an
2522 Exception_With_Actions. Update the calls to Return_Flag.
2523 * expander.adb (Expand): Add new case for N_Expression_With_Actions.
2524
25252011-08-04 Ed Schonberg <schonberg@adacore.com>
2526
2527 * sem_util.adb:(Wrong_Type): Improve error message on a one-element
2528 positional aggregate.
2529
25302011-08-04 Vincent Celier <celier@adacore.com>
2531
2532 * par_sco.adb (Process_Decisions.Output_Header): Check and record pragma
2533 SLOC only for pragmas.
2534
25352011-08-04 Emmanuel Briot <briot@adacore.com>
2536
2537 * projects.texi: Minor typo fix.
2538
25392011-08-04 Emmanuel Briot <briot@adacore.com>
2540
2541 * prj-nmsc.adb (Check_File): Minor change to traces, to help debugging
2542 on case-sensitive file systems.
2543
c2873f74
TQ
25442011-08-04 Thomas Quinot <quinot@adacore.com>
2545
2546 * put_scos.adb (Put_SCOs): Do not emit decision SCO for an X decision
2547 nested in a disabled pragma.
2548 * scos.ads, scos.adb, par_sco.ads, par_sco.adb: Record sloc of
2549 enclosing pragma, if any, for X decisions.
2550
25512011-08-04 Thomas Quinot <quinot@adacore.com>
2552
2553 * sem_prag.adb: Minor reformatting.
2554
46414266
VC
25552011-08-04 Vincent Celier <celier@adacore.com>
2556
2557 * a-tags.adb (Check_TSD): Avoid concatenation of strings, as it is not
2558 allowed in no run time mode.
2559
25602011-08-04 Vincent Celier <celier@adacore.com>
2561
2562 * make.adb (Check): When -gnatc is used, check for the source file
2563 inside the ALI file with a canonical case file name.
2564
afab164f
EB
25652011-08-04 Emmanuel Briot <briot@adacore.com>
2566
2567 * g-comlin.adb, g-comlin.ads (Add_Switch): Put back support for
2568 overriding the separator.
2569
fe0ec02f
AC
25702011-08-04 Robert Dewar <dewar@adacore.com>
2571
2572 * sem_aggr.adb, par_sco.adb, sem_type.adb, exp_util.adb, exp_ch9.adb,
2573 prj-nmsc.adb, sem_ch13.adb, exp_strm.adb: Minor reformatting.
2574
25752011-08-04 Robert Dewar <dewar@adacore.com>
2576
2577 * gnat_rm.texi: Minor documentation fix for pragma Annotate.
2578
25792011-08-04 Yannick Moy <moy@adacore.com>
2580
2581 * sem_attr.adb (Analyze_Attribute): add check during pre-analysis that
2582 'Result only appears in postcondition of function.
2583
25842011-08-04 Thomas Quinot <quinot@adacore.com>
2585
2586 * a-tags.adb (Check_TSD): When raising PROGRAM_ERROR for a duplicated
2587 external tag, include the value of the external tag in the exception
2588 message.
2589
0180fd26
AC
25902011-08-04 Yannick Moy <moy@adacore.com>
2591
2592 * sem_attr.adb (Result): modify error message for misplaced 'Result
2593
25942011-08-04 Sergey Rybin <rybin@adacore.com>
2595
2596 * gnat_rm.texi (pragma Annotate): Fix syntax description to make it
2597 clear that the second argument must be an identifier.
2598
25992011-08-04 Thomas Quinot <quinot@adacore.com>
2600
2601 * exp_ch9.adb (Build_Barrier_Function): When compiling with
2602 -fpreserve-control-flow, insert an IF statement on the barrier
2603 condition to ensure that a conditional branch instruction is generated.
2604
26052011-08-04 Emmanuel Briot <briot@adacore.com>
2606
2607 * prj-part.adb, prj.adb, prj.ads, prj-tree.ads
2608 (Processing_Flags.Ignore_Missing_With): new flag.
2609
26102011-08-04 Emmanuel Briot <briot@adacore.com>
2611
2612 * prj-nmsc.adb (Find_Sources, Path_Name_Of): Fix handling of
2613 Source_List_File on case-insensitive systems where the file is actually
2614 on a case-sensitive file system (NFS,...).
2615
26162011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2617
2618 * sem_ch6.adb (Analyze_Function_Return): In a rare case where a
2619 function return contains a controlled [extension] aggregate and the
2620 return statement is not part of a handled sequence of statements, wrap
2621 the return in a block. This ensures that all controlled temporaries
2622 generated during aggregate resolution will be picked up by the
2623 finalization machinery.
2624
26252011-08-04 Ed Schonberg <schonberg@adacore.com>
2626
2627 * sem_aggr.adb (Resolve_Aggregate): If aggregate has box-initialized
2628 components, freeze type before resolution, to ensure that default
2629 initializations are present for all components.
2630 * sem_res.adb (Resolve_Actuals): the designated object of an
2631 accces-to-constant type is a legal actual in a call to an
2632 initialization procedure.
2633
26342011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2635
2636 * exp_util.adb (Extract_Renamed_Object): Add N_Type_Conversion and
2637 N_Unchecked_Type_Conversion to the possible containers of a renamed
2638 transient variable.
2639
78efd712
AC
26402011-08-04 Yannick Moy <moy@adacore.com>
2641
2642 * par-ch13.adb (Aspect_Specifications_Present): recognize
2643 "with Identifier'Class =>" as an aspect, so that a meaningful warning
2644 is issued in Strict mode.
2645 * par.adb: Fix typos in comments.
2646
26472011-08-04 Yannick Moy <moy@adacore.com>
2648
2649 * sem_attr.adb (Result): modify error message to take into account Post
2650 aspect when compiling Ada 2012 (or newer) code.
2651
26522011-08-04 Nicolas Roche <roche@adacore.com>
2653
2654 * env.c (__gnat_clearenv): Avoid use of dynamic size array in order to
2c7f9cc0 2655 remove need for GCC exceptions.
78efd712
AC
2656
26572011-08-04 Vincent Celier <celier@adacore.com>
2658
2659 * makeutl.adb (Do_Complete): Call Debug_Output with the name of the
2660 project, not the source file name.
2661 * prj.adb (Find_Sources.Look_For_Sources): If the source has been
2662 excluded, continue looking. This excluded source will only be returned
2663 if there is no other source with the same base name that is not locally
2664 removed.
2665
26662011-08-04 Ed Schonberg <schonberg@adacore.com>
2667
2668 * sem_res.adb (Resolve_Intrinsic_Operator): if the result type is
2669 private and one of the operands is a real literal, use a qualified
2670 expression rather than a conversion which is not meaningful to the
2671 back-end.
2672
0170a691
AC
26732011-08-04 Yannick Moy <moy@adacore.com>
2674
2675 * sem_ch13.adb (Aspect_Loop): when an aspect X and its classwise
2676 corresponding aspect X'Class are allowed, proceed with analysis of the
2677 aspect instead of skipping it.
2678
26792011-08-04 Tristan Gingold <gingold@adacore.com>
2680
2681 * s-flocon.adb, s-flocon.ads: Add a body for s-flocon.ads
2682 This will allow to have an Ada implementation for the subprogram.
2683
deb4f5ba
ES
26842011-08-04 Ed Schonberg <schonberg@adacore.com>
2685
2686 * sem_ch3.adb (Analyze_Full_Type_Declaration): If the declaration is a
2687 completion and aspects are present, apply them to the entity for the
2688 type which is currently the partial view, but which is the one that
2689 will be frozen.
2690 * sem_ch13.adb (Analyze_Aspect_Specifications): if the predicate
2691 applies to a partial view, indicate that the full view has predicates
2692 and delayed aspects.
2693 (Replace_Type_Reference): Handle properly predicates that apply to the
2694 full view of a private completion.
2695
fc893455
AC
26962011-08-04 Eric Botcazou <ebotcazou@adacore.com>
2697
2698 * layout.adb (Layout_Type): For composite types, do not set Esize.
2699 * freeze.adb (Set_Small_Size): Remove test on alignment and do not
2700 set Esize.
2701 (Size_Known): Look at the RM size of components instead of the Esize.
2702 (Freeze_Record_Type): Look at the RM size instead of the Esize to
2703 issue warning and activate Implicit_Packing.
2704 (Freeze_Entity): Likewise. Do not issue a warning for alias/atomic
2705 if the Esize is not known.
2706 * sem_ch13.adb (Analyze_Attribute_Definition_Clause) <Size>: Set Esize
2707 for elementary types only.
2708 (Analyze_Record_Representation_Clause): Look at the RM size instead
2709 of the Esize to issue errors.
2710 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not set Esize if it
2711 is not known.
2712 <E_Record_Type>: Look at the RM size instead of the Esize. Remove
2c7f9cc0 2713 obsolete block.
fc893455
AC
2714 Look at the RM size instead of the Esize for types if the latter is
2715 not known.
2716 (gnat_to_gnu_field): Use Known_Esize instead of Known_Static_Esize.
2717
27182011-08-04 Ed Schonberg <schonberg@adacore.com>
2719
2720 * sem_type.adb: proper handling of equality not involving anonymous
2721 access types.
2722
b37d5bc6
AC
27232011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2724
2725 * exp_ch7.adb (Create_Finalizer): Remove local variables Spec_Nod and
2726 Vis_Decls. When creating a library-level finalizer for a package spec,
2727 both the declaration and body of the finalizer are inserted either in
2728 the visible or private declarations of the package spec.
2729
27302011-08-04 Javier Miranda <miranda@adacore.com>
2731
2732 * sem_ch3.adb (Derive_Subprograms): Complete assertion to request the
2733 use of the full-view of a type when invoking Is_Ancestor.
2734 * sem_type.adb (Is_Ancestor): For consistency, when the traversal of
2735 the full-view of private parents is requested, then use also the
2736 full-view of the parent of the first derivation.
2737
7ab4d95a
AC
27382011-08-04 Tristan Gingold <gingold@adacore.com>
2739
2740 * s-taprop-vxworks.adb (Enter_Task): Use System.Float_Control.Reset
2741 instead of the locally imported procedure.
2742 * s-taprop-mingw.adb (Enter_Task): Ditto.
2743 * s-valrea.adb (Scan_Real): Ditto.
2744 * s-imgrea.adb (Set_Image_Real): Ditto.
2745 * s-flocon.ads: Make the package pure.
2746
27472011-08-04 Thomas Quinot <quinot@adacore.com>
2748
2749 * sinfo.ads, sinfo.adb (Debug_Statement, Set_Debug_Statement): Remove.
2750 * tbuild.ads, tbuild.adb (Make_Pragma): Adjust accordingly.
2751 * sinfo-cn.ads, sinfo-cn.adb (Change_Name_To_Procedure_Call_Statement):
2752 New subprogram, moved here from...
2753 * par.adb, par-ch5.adb (P_Statement_Name): ... here.
2754 * par-prag.adb (Par.Prag, case Pragma_Debug): Do not perform any
2755 rewriting of the last argument into a procedure call statement here...
2756 * sem_prag.adb (Analyze_Pragma, case Pragma_Debug): ...do it there
2757 instead.
2758
27592011-08-04 Thomas Quinot <quinot@adacore.com>
2760
2761 * par_sco.adb: Minor reformatting.
2762
51c400f5
AC
27632011-08-04 Robert Dewar <dewar@adacore.com>
2764
2765 * erroutc.adb: Minor reformatting.
2766
27672011-08-04 Thomas Quinot <quinot@adacore.com>
2768
2769 * par_sco.adb: Comment update.
2770
27712011-08-04 Tristan Gingold <gingold@adacore.com>
2772
2773 * s-flocon.ads: New file.
2774 * g-flocon.ads: Now a renaming of s-flocon.
2775 * Makefile.rtl: Add s-flocon.o
2776
6a49f110
AC
27772011-08-04 Javier Miranda <miranda@adacore.com>
2778
2779 * exp_strm.adb (Build_Array_Input_Function): if the array type is
2780 constrained, do not attempt to build a subtype of it.
2781
27822011-08-04 Yannick Moy <moy@adacore.com>
2783
2784 * errout.ads Change comments: remove 'R'M as an example where quotes
2785 are needed; add ALFA as another case where quotes are not needed
2786 * erroutc.adb (Set_Msg_Insertion_Reserved_Word): add ALFA as another
2787 case where quotes are not needed.
2788 * sem_ch11.adb, sem_ch13.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
2789 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_prag.adb, sem_res.adb:
2790 Remove all occurrences of 'A'L'F'A
2791
27922011-08-04 Ed Schonberg <schonberg@adacore.com>
2793
2794 * sem_ch13.adb: check legality of invariant pragma.
2795
a4640a39
AC
27962011-08-04 Eric Botcazou <ebotcazou@adacore.com>
2797
2798 * bindgen.adb: Add comments.
2799
28002011-08-04 Yannick Moy <moy@adacore.com>
2801
2802 * einfo.adb, einfo.ads: Free Flag254 and make Formal_Proof_On a
2803 synthesized flag.
2804 * sem_prag.adb (Analyze_Pragma): record the pragma Annotate
2805 (Formal_Proof, On/Off) in the Rep_Item list of the current subprogram.
2806
28072011-08-04 Robert Dewar <dewar@adacore.com>
2808
2809 * exp_ch7.adb, exp_ch6.adb, sem_ch3.adb, layout.adb, sem_ch5.adb,
2810 osint-c.ads, sem_util.ads, gnat1drv.adb, targparm.ads, sem_ch6.adb,
2811 sem_ch13.adb, s-pooloc.adb: Minor reformatting.
2812
39ade2f9
AC
28132011-08-04 Thomas Quinot <quinot@adacore.com>
2814
2815 * s-pooloc.ads, s-pooglo.ads: Minor reformatting
2816
28172011-08-04 Thomas Quinot <quinot@adacore.com>
2818
2819 PR ada/47880
2820 * s-pooloc.adb (Deallocate): Fix the case of deallocating the only
2821 allocated object.
2822
28232011-08-04 Robert Dewar <dewar@adacore.com>
2824
2825 * einfo.ads, exp_ch4.adb: Minor reformatting.
2826
28272011-08-04 Jerome Lambourg <lambourg@adacore.com>
2828
2829 * back_end.ads (Gen_Or_Update_Object_File): Add more comments.
2830
7efc3f2d
AC
28312011-08-04 Ed Schonberg <schonberg@adacore.com>
2832
2833 * exp_ch4.adb (Expand_Composite_Equality): code cleanup: use component
2834 type in all cases to compute list of primitive operations, because full
2835 view may be an itype that is not attached to the list of declarations.
2836
28372011-08-04 Eric Botcazou <ebotcazou@adacore.com>
2838
2839 * bindgen.adb (Gen_Adafinal_Ada): Generate an early return if the
2840 library has already been finalized.
2841 (Gen_Adafinal_C): Likewise.
2842 (Gen_Adainit_Ada): Generate an early return if the library has
2843 already been elaborated.
2844 (Gen_Adainit_C): Likewise.
2845 (Gen_Output_File_Ada): Generate an elaboration flag.
2846 (Gen_Output_File_C): Likewise.
2847
f65df609
HK
28482011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2849
2850 * exp_ch4.adb (Expand_Allocator_Expression): Disable the generation of
2851 Set_Finalize_Address_Ptr for CodePeer because Finalize_Address was not
2852 built in the first place.
2853 (Expand_N_Allocator): Disable the generation of Set_Finalize_Address_Ptr
2854 for CodePeer because Finalize_Address was not built to begin with.
2855 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Ditto.
2856
a0fb8fe8
AC
28572011-08-04 Pascal Obry <obry@adacore.com>
2858
2859 * adaint.c (__gnat_tmp_name): Use current process id to create temp
2860 filenames, this ensures unicity of filenames across processes.
2861
28622011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2863
2864 * bindgen.adb (Gen_Finalize_Library_Ada): Rename generated routine
2865 Raise_Controlled to Raise_From_Controlled_Operation. Update the
2866 signature of Raise_From_Controlled_Operation by adding flag From_Abort.
2867 Add False as the actual to From_Abort in the generated call to
2868 Raise_From_Controlled_Operation.
2869
28702011-08-04 Jerome Lambourg <lambourg@adacore.com>
2871
2872 * osint-c.ads, osint-c.adb (Set_Library_Info_Name): Move to declaration
2873 so that the ali file name can be retrieved from outside of this package.
2874 * back_end.ads, back_end.adb (Gen_Or_Update_Object_File): New method
2875 doing nothing in the general case, but used to update the object file
2876 timestamp if directly generated by the backend.
2877 * gnat1drv.adb (Gnat1drv): Make sure the object file's timestamp is set
2878 to a later time than the ali file one.
2879
9534ab17
AC
28802011-08-04 Yannick Moy <moy@adacore.com>
2881
2882 * einfo.adb, einfo.ads (Formal_Proof_On): new flag set on subprogram
2883 entities whose body contains an Annotate pragma which forces formal
2884 proof on this body.
2885 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
2886 sem_ch6.adb, sem_ch9.adb, sem_res.adb: Adapt call to
2887 Mark_Non_ALFA_Subprogram to pass in a message and node.
2888 * sem_prag.adb (Analyze_Pragma): add treatment of pragma Annotate
2889 (Forma_Proof, On) which sets the flag Formal_Proof_On in the
2890 surrounding subprogram.
2891 * sem_util.adb, sem_util.ads (Mark_Non_ALFA_Subprogram,
2892 Mark_Non_ALFA_Subprogram_Unconditional): if the subprogram being marked
2893 as not in ALFA is annotated with Formal_Proof being On, then an error
2894 is issued based on the additional parameters for message and node.
2895 * snames.ads-tmpl (Name_Formal_Proof): new name for annotation.
2896 * gcc-interface/Make-lang.in: Update dependencies.
2897
28982011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2899
2900 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Do not generate
2901 Finalize_Address when CodePeer is enabled.
2902
29032011-08-04 Pascal Obry <obry@adacore.com>
2904
2905 * adaint.c (__gnat_tmp_name): Use _tempnam() instead of tempnam() as
2906 the latter returns a pointer to a static buffer which is deallocated
2907 at the end of the routine.
2908
5c0e97dd
AC
29092011-08-04 Yannick Moy <moy@adacore.com>
2910
2911 * sem_ch3.adb (Array_Type_Declaration): move test for type in ALFA
2912 after index creation; mark unconstrained base array type generated as
2913 being in/not in ALFA as well
2914 (Make_Index): mark subtype created as in/not in ALFA
2915 * sem_ch5.adb (Analyze_Iteration_Scheme): mark entity for iterating
2916 over a loop as in/not in ALFA, depending on its type and form of loop
2917 iteration.
2918
29192011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2920
2921 * exp_ch7.adb (Build_Object_Declarations): Initialize flag Abort
2922 directly to False on .NET and JVM.
2923
7a93c64b
YM
29242011-08-04 Yannick Moy <moy@adacore.com>
2925
2926 * sem_ch3.adb (Constrain_Enumeration, Constrain_Integer): remove
2927 constraint that subtype must come from source code to be in ALFA, so
2928 that anonymous subtypes can be in ALFA too.
2929
e9a1ed9b
YM
29302011-08-04 Yannick Moy <moy@adacore.com>
2931
2932 * sem_ch3.adb (Analyze_Object_Declaration): remove obsolete addition of
2933 reference for ALFA mode.
2934 * lib-xref-alfa.adb, lib-xref.ads (Traverse_Compilation_Unit): make
2935 procedure public so as to use it from formal verification back-end.
2936
8e293fbd
AC
29372011-08-04 Jerome Lambourg <lambourg@adacore.com>
2938
2939 * g-comlin.adb (For_Each_Simple_Switch.Is_In_Config): Remove the
2940 invalid checks of the Parameter, making Remove_Switch not working
2941 correctly.
2942
29432011-08-04 Arnaud Charlet <charlet@adacore.com>
2944
2945 * targparm.ads: Update header: no run-time exception is needed on this
2946 file.
2947
29482011-08-04 Vincent Celier <celier@adacore.com>
2949
2950 * a-fihema.adb: Use System.IO instead of GNAT.IO
2951
29522011-08-04 Thomas Quinot <quinot@adacore.com>
2953
2954 * sem_ch3.adb (Access_Definition): Anonymous access to subprogram types
2955 are forbidden in Compiler_Unit mode.
2956
cfae2bed
AC
29572011-08-04 Robert Dewar <dewar@adacore.com>
2958
2959 * sem_util.adb: Minor reformatting.
2960
29612011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2962
2963 * bindgen.adb (Gen_Finalize_Library_Ada): Update the import string for
2964 library-level finalizers.
2965 (Gen_Finalize_Library_C): Update the import string for library-level
2966 finalizers.
2967 (Gen_Finalize_Library_Defs_C): Update the definition name of a
2968 library-level finalizer.
2969 * exp_ch7.adb: Remove with and use clauses for Stringt.
2970 (Create_Finalizer): Remove local variables Conv_Name, Prag_Decl,
2971 Spec_Decl. Add local variable Body_Id. The names of library-level
2972 finalizers are now manually fully qualified and are no longer external.
2973 A single name is now capable of servicing .NET, JVM and non-VM targets.
2974 Pragma Export is no longer required to provide visibility for the name.
2975 (Create_Finalizer_String): Removed.
2976 (New_Finalizer_Name): New routine which mimics New_..._Name.
2977
01f0729a
AC
29782011-08-04 Eric Botcazou <ebotcazou@adacore.com>
2979
2980 * sem_elab.adb (Check_Internal_Call_Continue): Change the type of the
2981 elaboration counter to Standard_Short_Integer.
2982 * sem_util.adb (Build_Elaboration_Entity): Likewise.
2983 * bindgen.adb (Gen_Elab_Externals_Ada): Adjust to above change.
2984 (Gen_Elab_Externals_C): Likewise.
2985
29862011-08-04 Ed Falis <falis@adacore.com>
2987
2988 * system-vxworks-arm.ads, system-vxworks-sparcv9.ads,
2989 system-vxworks-ppc.ads, system-vxworks-m68k.ads,
2990 system-vxworks-mips.ads, system-vxworks-x86.ads
2991 (Always_Compatible_Rep): set to False for all VxWorks targets.
2992
2c1b72d7
AC
29932011-08-04 Robert Dewar <dewar@adacore.com>
2994
2995 * par_sco.adb, prj-proc.adb, make.adb, bindgen.adb, prj.adb, prj.ads,
2996 makeutl.adb, makeutl.ads, prj-nmsc.adb, exp_ch5.adb, exp_ch12.adb,
2997 exp_ch7.ads, exp_util.ads, sem_util.ads, g-comlin.ads, exp_ch6.adb,
2998 exp_ch6.ads, lib-xref.ads, exp_ch7.adb, exp_util.adb, exp_dist.adb,
2999 exp_strm.adb, gnatcmd.adb, freeze.adb, g-comlin.adb, lib-xref-alfa.adb,
3000 sem_attr.adb, sem_prag.adb, sem_util.adb, sem_elab.adb, sem_ch8.adb,
3001 sem_ch11.adb, sem_eval.adb, sem_ch13.adb, sem_disp.adb, a-fihema.adb:
3002 Minor reformatting and code reorganization.
3003
30042011-08-04 Emmanuel Briot <briot@adacore.com>
3005
3006 * projects.texi: Added doc for aggregate projects.
3007
824e9320
AC
30082011-08-04 Emmanuel Briot <briot@adacore.com>
3009
3010 * prj-proc.adb, prj-nmsc.adb, prj-env.adb (Process_Declarative_Items):
3011 Add support for overriding the Project_Path in aggregate projects.
3012
30132011-08-04 Robert Dewar <dewar@adacore.com>
3014
3015 * a-cofove.ads: Minor reformatting.
3016
30172011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
3018
3019 * exp_ch7.adb (Build_Adjust_Or_Finalize_Statements): Update the comment
3020 on the generated code.
3021 (Build_Finalize_Statements): Update the comment on the generated code.
3022 (Build_Initialize_Statements): Update the comment on the generated code.
3023 (Build_Object_Declarations): Add local variable Result. The object
3024 declarations are now built in sequence.
3025 * rtsfind.ads: Add RE_Exception_Occurrence_Access to tables RE_Id and
3026 RE_Unit_Table.
3027
30282011-08-04 Robert Dewar <dewar@adacore.com>
3029
3030 * checks.adb, alfa.adb, alfa.ads: Minor reformatting.
3031
30322011-08-04 Eric Botcazou <ebotcazou@adacore.com>
3033
3034 * einfo.ads (Elaboration_Entity): Document new definition and use.
3035 (Elaboration_Entity_Required): Adjust to above change.
3036 * exp_attr.adb (Expand_N_Attribute_Reference): Likewise.
3037 * exp_ch12.adb: And with and use for Snames.
3038 (Expand_N_Generic_Instantiation): Test 'Elaborated attribute.
3039 * exp_util.adb (Set_Elaboration_Flag): Likewise.
3040 * sem_attr.adb (Analyze_Attribute) <Check_Library_Unit>: Delete.
3041 <Check_Unit_Name>: Deal with N_Expanded_Name.
3042 <Attribute_Elaborated>: Extend to all unit names.
3043 * sem_elab.adb: And with and use for Uintp.
3044 (Check_Internal_Call_Continue): Adjust to Elaboration_Entity change.
3045 * sem_util.ads (Build_Elaboration_Entity): Adjust comment.
3046 * sem_util.adb (Build_Elaboration_Entity): Change type to Integer.
3047 * bindgen.adb (Gen_Elab_Externals_Ada): New local subprogram taken
3048 from Gen_Adainit_Ada.
3049 (Gen_Elab_Externals_C): Likewise, but taken from Gen_Adainit_C.
3050 (Gen_Adafinal_Ada): Remove redundant test. In the non-main program
3051 case, do not call System.Standard_Library.Adafinal; instead call
3052 finalize_library if needed.
3053 (Gen_Adafinal_C): Likewise.
3054 (Gen_Adainit_Ada): Do not set SSL.Finalize_Library_Objects in the
3055 non-main program case.
3056 (Gen_Adainit_C): Generate a couple of external declarations here.
3057 In the main program case, set SSL.Finalize_Library_Objects.
3058 (Gen_Elab_Calls_Ada): Adjust to Elaboration_Entity change.
3059 (Gen_Elab_Calls_C): Likewise.
3060 (Gen_Finalize_Library_Ada): Likewise. Skip SAL interface units.
3061 (Gen_Finalize_Library_C): Likewise. Generate a full function.
3062 (Gen_Main_C): Put back call to Ada_Final and don't finalize library
3063 objects here.
3064 (Gen_Output_File_Ada): Generate pragma Linker_Destructor for Ada_Final
3065 if -a is specified. Call Gen_Elab_Externals_Ada. Move around call to
3066 Gen_Adafinal_Ada.
3067 (Gen_Output_File_C): Generate __attribute__((destructor)) for Ada_Final
3068 if -a is specified. Call Gen_Elab_Externals_C. Remove useless couple
2c7f9cc0 3069 of external declarations. Call Gen_Finalize_Library_C.
824e9320 3070
316d9d4f
EB
30712011-08-04 Emmanuel Briot <briot@adacore.com>
3072
3073 * prj.adb, prj.ads, makeutl.adb, makeutl.ads (Complete_Mains,
3074 Compute_Compilation_Phases): new subprogram.
3075 (Builder_Data, Builder_Project_Tree_Data): new subprogram and type
3076 The number of mains as well as the various compilation phases that
3077 need to be run are now project tree specific, since various
3078 aggregated trees might have different requirements. In particular,
3079 they do not all require bind or link phases.
3080
9434c32e
EB
30812011-08-04 Emmanuel Briot <briot@adacore.com>
3082
3083 * prj.adb, prj.ads, makeutl.adb, makeutl.ads, prj-env.adb
3084 (Project_Tree_Appdata): New type.
3085 It is now possible to associate application-specific data to a project
3086 tree. In particular, this is used in the gprbuild builder to avoid a
3087 number of global tables and htables, especially now that there can be
3088 several project trees loaded at once because of aggregate projects.
3089 (Debug_Name): new procedure.
3090 * projects.texi: Clarify syntax of "**" for Source_Dirs
3091
41ba34db
EB
30922011-08-03 Emmanuel Briot <briot@adacore.com>
3093
3094 * prj.ads, makeutl.adb, makeutl.ads (Queue.Insert): now also inserts
3095 the "roots" for a main.
3096 (Fill_From_Project): add support for aggregate projects. Main units
3097 in aggregated projects are now automatically added in the list of
3098 files to build (although this fails later on in gprbuild, because
3099 these files are not using the root proejct tree, so this needs
3100 further cleanup)
3101 * gcc-interface/Make-lang.in: Update dependencies.
3102
fccd42a9
AC
31032011-08-03 Yannick Moy <moy@adacore.com>
3104
3105 * sem_ch4.adb (Analyze_Conditional_Expression): only allow boolean
3106 conditional expression in ALFA.
3107 * sem_res.adb (Resolve_Conditional_Expression): mark non-boolean
3108 expressions as not in ALFA.
3109
31102011-08-03 Robert Dewar <dewar@adacore.com>
3111
3112 * a-cofove.adb: Minor reformatting.
3113
31142011-08-03 Emmanuel Briot <briot@adacore.com>
3115
3116 * make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads
3117 (Insert_Project_Sources, Insert_withed_Sources_For): moved from the
3118 gprbuild sources.
3119 These packages are more logically placed in the Queue package, since
3120 they manipulate the queue. It is also likely that they can be adapted
3121 for gnatmake, thus sharing more code.
3122 (Finish_Program, Fail_Program): moved from the gprbuild sources, so
3123 that we could move the above.
3124
31252011-08-03 Emmanuel Briot <briot@adacore.com>
3126
3127 * errutil.adb (Finalize): clean up the list of error messages on exit.
3128 Calling this subprogram multiple times will no longer show duplicate
3129 error messages on stderr.
3130
31312011-08-03 Emmanuel Briot <briot@adacore.com>
3132
3133 * g-comlin.adb, g-comlin.ads (Set_Command_Line): ignore the parameter
3134 Getopt_Switches when we have already define a command line
3135 configuration.
3136
5e8c8e44
YM
31372011-08-03 Yannick Moy <moy@adacore.com>
3138
3139 * sem_ch11.adb (Analyze_Raise_xxx_Error): do not mark such nodes as not
3140 in ALFA. Instead, they are considered as assertions to prove.
3141 * sem_ch4.adb (Analyze_Conditional_Expression): do not always mark such
3142 nodes as not in ALFA. Instead, include conditional expressions in ALFA
3143 if they have no ELSE part, or if they occur in pre- and postconditions,
3144 where the Condition cannot have side-effects in ALFA
3145 (Analyze_Membership_Op): do not mark such nodes as not in ALFA
3146 (Analyze_Type_Conversion): do not always mark such nodes as not in ALFA.
3147 Instead, include type conversion between scalar types in ALFA.
3148 * sem_ch6.adb (Process_Formals): correctly mark a parameter in ALFA
3149 if-and-only-if its type is in ALFA.
3150
5ffe0bab
AC
31512011-08-03 Thomas Quinot <quinot@adacore.com>
3152
3153 * scos.adb, get_scos.adb, put_scos.adb
3154 New code letter for decisions: G (entry guard)
3155 * par_sco.adb
3156 (Traverse_Subprogram_Body): Rename to...
3157 (Traverse_Subprogram_Or_Task_Body): New subrpogram.
3158 (Traverse_Protected_Body): New subprogram
3159 (Traverse_Declarations_Or_Statements): Add traversal of task bodies,
3160 protected bodies and entry bodies.
3161
31622011-08-03 Yannick Moy <moy@adacore.com>
3163
3164 * einfo.adb, einfo.ads (Is_Postcondition_Proc): new flag for procedure
3165 entities with get/set subprograms, which is set on procedure entities
3166 generated by the compiler for a postcondition.
3167 * sem_ch6.adb (Process_PPCs): set new flag on postcondition procedures
3168 * alfa.adb, alfa.ads (Get_Entity_For_Decl): new function returning the
3169 entity for a declaration
3170 (Get_Unique_Entity_For_Decl): new function returning an entity which
3171 represents a declaration, so that matching spec and body have the same
3172 entity.
3173
31742011-08-03 Robert Dewar <dewar@adacore.com>
3175
3176 * a-except-2005.adb, a-cfhama.adb, a-cfhase.adb, a-cfhase.ads,
3177 a-cforma.adb, a-cforse.ads, a-cforse.adb: Minor reformatting
3178
31792011-08-03 Yannick Moy <moy@adacore.com>
3180
3181 * lib-xref-alfa.adb (Detect_And_Add_ALFA_Scope): make the subprogram
3182 library-level because retriction No_Implicit_Dynamic_Code in the
3183 front-end prevents its definition as a local subprogram
3184 (Traverse_Compilation_Unit): extract new procedure from Add_ALFA_File,
3185 for reuse in other contexts
3186 (Traverse_Declarations_Or_Statements,
3187 Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
3188 Traverse_Package_Declaration, Traverse_Subprogram_Body): make all these
3189 procedures take a callback parameter to be called on all declarations
3190 * lib-xref.ads
3191 (Traverse_All_Compilation_Units): new generic function to traverse a
3192 compilation unit and call a callback parameter on all declarations
3193
f9ad6b62
AC
31942011-08-03 Javier Miranda <miranda@adacore.com>
3195
3196 * sem_prag.adb (Process_Interface_Name): Allow duplicated export names
3197 in Java since they are always enclosed in a namespace that
3198 differentiates them, and overloaded entities are supported by the VM.
3199
32002011-08-03 Ed Schonberg <schonberg@adacore.com>
3201
3202 * checks.adb (Determine_Range): If a computed bound of an operation is
3203 outside the range of the base type of the expression, and overflow
3204 checks are enabled, the result is unknown and cannot be used for any
3205 subsequent constant folding.
3206 * sem_eval.adb (Compile_Time_Compare): if the bounds of one operand are
3207 unknown, so is the result of the comparison.
3208
32092011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3210
3211 * a-except-2005.adb (Raise_From_Controlled_Operation): Add new formal
3212 From_Abort. When finalization was triggered by an abort, propagate
3213 Standard'Abort_Signal rather than Program_Error.
3214 * a-except-2005.ads (Raise_From_Controlled_Operation): Add new formal
3215 From_Abort.
3216 * a-except.adb (Raise_From_Controlled_Operation): Add new formal
3217 From_Abort. When finalization was triggered by an abort, propagate
3218 Standard'Abort_Signal rather than Program_Error.
3219 * a-except.ads:(Raise_From_Controlled_Operation): Add new formal
3220 From_Abort.
3221 * exp_ch7.adb:(Build_Adjust_Or_Finalize_Statements): New local variable
3222 Abort_Id. Update the calls to Build_Object_Declarations and
3223 Build_Raise_Statement to include Abort_Id.
3224 (Build_Adjust_Statements): New local variable Abort_Id. Update the
3225 calls to Build_Object_Declarations and Build_Raise_Statement to include
3226 Abort_Id.
3227 (Build_Finalize_Statements): New local variable Abort_Id. Update the
3228 calls to Build_Object_Declarations and Build_Raise_Statement to include
3229 Abort_Id.
3230 (Build_Components): Create an entity for Abort_Id when exceptions are
3231 allowed on the target.
3232 (Build_Finalizer): New local variable Abort_Id.
3233 (Build_Initialize_Statements): New local variable Abort_Id. Update the
3234 calls to Build_Object_Declarations and Build_Raise_Statement to include
3235 Abort_Id.
3236 (Build_Object_Declarations): Add new formal Abort_Id. Create the
3237 declaration of flag Abort_Id to preserve the original abort status
3238 before finalization code is executed.
3239 (Build_Raise_Statement): Add new formal Abort_Id. Pass Abort_Id to
3240 runtime routine Raise_From_Controlled_Operation.
3241 (Create_Finalizer): Update the call to Build_Raise_Statement to include
3242 Abort_Id. Update the call to Build_Object_Declarations to include
3243 Abort_Id. Update the layout of the finalizer body.
3244 (Make_Handler_For_Ctrl_Operation): Add an actual for From_Abort.
3245 (Process_Transient_Objects): New local variable Abort_Id. Remove the
3246 clunky code to create all flags and objects related to
3247 exception propagation and replace it with a call to
3248 Build_Object_Declarations. Update the call to Build_Raise_Statement to
3249 include Abort_Id.
3250 * exp_ch7.ads (Build_Object_Declarations): Moved from body to spec.
3251 Add new formal Abort_Id and associated comment on its use.
3252 (Build_Raise_Statement): Add new formal Abort_Id and associated comment
3253 on its use.
3254 * exp_intr.adb (Expand_Unc_Deallocation): New local variable Abort_Id.
3255 Remove the clunky code to create all flags and objects related to
3256 exception propagation and replace it with a call to
3257 Build_Object_Declarations. Update the call to Build_Raise_Statement.
3258
32592011-08-03 Eric Botcazou <ebotcazou@adacore.com>
3260
3261 * s-tassta.adb: Fix minor typos.
3262
32632011-08-03 Robert Dewar <dewar@adacore.com>
3264
3265 * rtsfind.ads, makeutl.ads, prj.ads, prj.adb, make.adb,
3266 lib-writ.adb, makeutl.adb, s-soflin.ads, clean.adb: Minor reformatting.
3267
1cdfa9be
AC
32682011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3269
3270 * exp_ch7.adb (Create_Finalizer): Treat freeze nodes in similar fashion
3271 to packages. This ensures that the finalizer body will not end up
3272 inside the freeze node.
3273 (Process_Declarations): Add code to detect whether a freeze node has a
3274 nested finalization collection.
3275
32762011-08-03 Pascal Obry <obry@adacore.com>
3277
3278 * g-awk.adb, g-awk.ads: Make GNAT.AWK API compatible with Ada 2005.
3279 (Current_Session): Return a not null access to Session_Type.
3280 (Default_Session): Likewise.
3281
243cae0a
AC
32822011-08-03 Robert Dewar <dewar@adacore.com>
3283
3284 * a-cfdlli.adb, bindgen.adb, exp_ch4.adb, exp_ch13.adb, sem_warn.adb,
3285 exp_ch3.adb, exp_ch3.ads: Minor reformatting.
3286
32872011-08-03 Pascal Obry <obry@adacore.com>
3288
3289 * g-awk.ads: Minor comment fix.
3290
32912011-08-03 Sergey Rybin <rybin@adacore.com>
3292
3293 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
3294 the tree structure related to discriminant constraints.
3295 Original_Discriminant cannot be used any more for computing the
3296 defining name for the reference to a discriminant.
3297
32982011-08-03 Ed Schonberg <schonberg@adacore.com>
3299
3300 * sem_disp.adb (Is_Tag_Indeterminate): If the return type of the
3301 function is not visibly tagged, this is not a dispatching call and
3302 therfore is not Tag_Indeterminate, even if the function is marked as
3303 dispatching on result.
3304
f553e7bc
AC
33052011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3306
3307 * exp_ch13.adb: Add with and use clauses for Restrict and Rident.
3308 (Expand_N_Free_Statement): Add a guard to protect against run-times
3309 which do not support controlled types.
3310 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Add a guard to protect
3311 against run-times which do not support controlled types.
3312 * exp_ch4.adb (Complete_Controlled_Allocation): Add a guard to protect
3313 against run-times which do not support controlled types.
3314 * exp_ch7.adb (Build_Finalization_Collection): Add a guard to protect
3315 against run-times which do not support controlled types.
3316 * exp_util.adb (Needs_Finalization): Code reformatting. Add a guard to
3317 protect against run-times which do not support controlled types.
3318
33192011-08-03 Eric Botcazou <ebotcazou@adacore.com>
3320
3321 * exp_intr.adb: Put back with and use clauses for Exp_Ch11.
3322 (Expand_Unc_Deallocation): Expand the AT_END handler at the very end.
3323
e4982b64
AC
33242011-08-03 Ed Schonberg <schonberg@adacore.com>
3325
3326 * exp_ch5.adb (Expand_Iterator_Loop): indicate that the cursor is
3327 modified in the source, to prevent spurious warnings when compiling
3328 with -gnatg.
3329
33302011-08-03 Thomas Quinot <quinot@adacore.com>
3331
3332 * a-except-2005.adb: Minor reformatting.
3333
33342011-08-03 Ed Schonberg <schonberg@adacore.com>
3335
3336 * sem_warn.adb (Check_One_Unit): if the only mention of a withed unit
3337 is a renaming declaration in the private part of a package, do not emit
3338 a warning that the with_clause could be moved because the renaming may
3339 be used in the body or in a child unit.
3340
33412011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3342
3343 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
3344 Propagate the Comes_From_Source attribute from the original return
3345 object to the renaming.
3346
33472011-08-03 Jose Ruiz <ruiz@adacore.com>
3348
3349 * exp_ch7.adb (Build_Raise_Statement): Do not call
3350 Raise_From_Controlled_Operation when this routine is not present in
3351 the run-time library.
3352 (Cleanup_Protected_Object, Cleanup_Task): For restricted run-time
3353 libraries (Ravenscar), tasks are non-terminating, and protected objects
3354 and tasks can only appear at library level, so we do not want
3355 finalization of protected objects nor tasks.
3356 * exp_intr.adb: Minor clarification in comment.
3357 bindgen.adb (Gen_Adainit_Ada, Gen_Main_C, Gen_Output_File_Ada,
3358 Gen_Output_File_C): Remove references to finalization of library-level
3359 objects when using restricted run-time libraries.
3360
33612011-08-03 Ed Schonberg <schonberg@adacore.com>
3362
3363 * sem_ch3.adb (Build_Discriminant_Constraints): Set
3364 Original_Discriminant only if the parent type is a generic formal.
3365
deb8dacc
HK
33662011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3367
3368 * exp_ch13.adb: Add with and use clause for Targparm;
3369 (Expand_N_Free_Statement): Prevent the generation of a custom
3370 Deallocate on .NET/JVM targets since this requires pools and address
3371 arithmetic.
3372 * exp_ch4.adb (Expand_Allocator_Expression): When compiling for
3373 .NET/JVM targets, attach the newly allocated object to the access
3374 type's finalization collection. Do not generate a call to
3375 Set_Finalize_Address_Ptr on .NET/JVM because this routine does not
3376 exist in the runtime.
3377 (Expand_N_Allocator): When compiling for .NET/JVM targets, do not
3378 create a custom Allocate for object that do not require initialization.
3379 Attach a newly allocated object to the access type's finalization
3380 collection on .NET/JVM.
3381 * exp_ch5.adb (Make_Tag_Ctrl_Assignment): Add special processing for
3382 assignment of controlled types on .NET/JVM. The two hidden pointers
3383 Prev and Next and stored and later restored after the assignment takes
3384 place.
3385 * exp_ch6.adb (Expand_Call): Add local constant Curr_S. Add specialized
3386 kludge for .NET/JVM to recognize a particular piece of code coming from
3387 Heap_Management and change the call to Finalize into Deep_Finalize.
3388 * exp_ch7.adb (Build_Finalization_Collection): Allow the creation of
3389 finalization collections on .NET/JVM only for types derived from
3390 Controlled. Separate the association of storage pools with a collection
3391 and only allow it on non-.NET/JVM targets.
3392 (Make_Attach_Call): New routine.
3393 (Make_Detach_Call): New routine.
3394 (Process_Object_Declarations): Suppress the generation of
3395 build-in-place return object clean up code on .NET/JVM since it uses
3396 pools.
3397 * exp_ch7.ads (Make_Attach_Call): New routine.
3398 (Make_Detach_Call): New routine.
3399 * exp_intr.adb Add with and use clause for Targparm.
3400 (Expand_Unc_Deallocation): Detach a controlled object from a collection
3401 on .NET/JVM targets.
3402 * rtsfind.ads: Add entries RE_Attach, RE_Detach and
3403 RE_Root_Controlled_Ptr to tables RE_Id and RE_Unit_Table.
3404 * snames.ads-tmpl: Add name Name_Prev. Move Name_Prev to the special
3405 names used in finalization.
3406
34072011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3408
3409 * a-fihema.adb: Add with and use clauses for System.Soft_Links.
3410 (Attach, Detach): Lock the current task when chaining an object onto a
3411 collection.
3412
df3e68b1
HK
34132011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3414
3415 * a-except.adb, a-except-2005.adb (Raise_From_Controlled_Operation):
3416 Rewritten to create the message strings when the exception is not
3417 raised by an abort during finalization.
3418 * a-except.ads, a-except-2005.ads: Add pragma Export for procedure
3419 Raise_From_Controlled_Operation and update its associated comment.
3420 * a-fihema.ads, a-fihema.adb: New GNAT unit.
3421 Ada.Finalization.Heap_Management provides key functionality
3422 associated with controlled objects on the heap, their creation,
3423 finalization and reclamation. Type Finalization_Collection is
3424 effectively a wrapper which sits ontop of a storage pool and performs
3425 all necessary bookkeeping for all the objects it contains. Each
3426 access-to-controlled or access-to-class-wide type receives a collection
3427 as part of its expansion. The compiler generates buffer code and
3428 invokes Allocate / Deallocate to create and destroy allocated
3429 controlled objects.
3430 * a-finali.adb ("="): Removed.
3431 * a-finali.ads ("="): Removed. Controlled types no longer carry hidden
3432 fields Prev and Next.
3433 * ali.adb (Scan_ALI): Add parsing code to process PF / Has_Finalizer.
3434 A library unit with at least one controlled object on the library level
3435 has a special finalizer which is invoked by the binder. To signal this,
3436 ali files carry field PF.
3437 * ali.ads: New field in type Unit_Record called Has_Finalizer. Add
3438 associated comment on field usage.
3439 * a-tags.adb (Get_RC_Offset): Removed.
3440 (Needs_Finalization): New routine.
3441 * a-tags.ads: Update the structure of the GNAT dispatch tables.
3442 Dispatch tables now carry field Needs_Finalization which provides
3443 runtime indication whether a type is controlled or has controlled
3444 components or both. Remove field RC_Offset.
3445 (Get_RC_Offset): Removed along with its associated pragma Export.
3446 Since tagged types with controlled components no longer carry hidden
3447 field _controller, the special mechanism to retrieve its location is no
3448 longer needed.
3449 (Needs_Finalization): New routine.
3450 * atree.ads, atree.adb (Elist24): New routine.
3451 (Set_Elist24): New routine.
3452 * atree.h: Add a define clause for Elist24.
3453 * bindgen.adb New library-level variable Lib_Final_Built.
3454 (Gen_Adafinal_Ada): Reimplemented. Depending on the restrictions or the
3455 presence of a VM target, the routine generates calls to the proper
3456 library finalization routine.
3457 (Gen_Adainit_Ada): Import Finalize_Library_Objects only on non-VM
3458 targets. Set the correct library finalization routine depending on
3459 whether the library has controlled objects or this is a VM compilation.
3460 (Gen_Finalize_Library_Ada): New routine. This procedure generates calls
3461 to library-level finalizers of compiled units in reverse order of
3462 elaboration. It also produces exception management code and reraises a
3463 potential exception after all units have been finalized.
3464 (Gen_Finalize_Library_C): New routine. This procedure generates calls to
3465 library-level finalizers of compiled units in reverse order of
3466 elaboration.
3467 (Gen_Finalize_Library_Defs_C): New routine. This procedure generates the
3468 definitions of all library-level finalizers available to the compilation
3469 (Gen_Main_Ada): Directly call Adafinal which now contails all target
3470 dependent code.
3471 (Gen_Main_C): Add new local constant Needs_Library_Finalization. Call
3472 System.Standard_Library.Adafinal directly. If the library needs
3473 finalization actions, create the sequence of finalization calls.
3474 (Gen_Output_File_Ada): Alphabetize local variables and constants.
3475 Generate a with clause for System.Soft_Links when compiling for a VM.
3476 Remove the code which imports System.Standard_Library.Adafinal as
3477 Do_Finalize. Generate the library finalization routine.
3478 (Gen_Output_File_C): Add new local constant Needs_Library_Finalization.
3479 If the library needs finalization actions, create all the definitions
3480 of library- level finalizers.
3481 (Has_Finalizer): New routine. Determines whether at least one compiled
3482 unit has a library-level finalizer.
3483 Add type Qualification_Mode.
3484 (Set_Unit_Name): Add a formal which controls the replacement of a dot.
3485 * einfo.adb: New usage of field 15 as Return_Flag.
3486 Remove Finalization_Chain_Entity from the usages of field 19.
3487 Remove Associated_Final_Chain from the usages of field 23.
3488 New usage of field 23 as Associated_Collection.
3489 New usage of field 24 as Finalizer.
3490 New usage of flag 252 as Is_Processed_Transient.
3491 (Associated_Final_Chain): Removed.
3492 (Associated_Collection): New routine.
3493 (Finalization_Chain_Entity): Removed.
3494 (Finalizer): New routine.
3495 (Is_Finalizer): New routine.
3496 (Is_Processed_Transient): New routine.
3497 (Return_Flag): New routine.
3498 (Set_Associated_Final_Chain): Removed.
3499 (Set_Associated_Collection): New routine.
3500 (Set_Finalization_Chain_Entity): Removed.
3501 (Set_Finalizer): New routine.
3502 (Set_Is_Processed_Transient): New routine.
3503 (Set_Return_Flag): New routine.
3504 (Write_Entity_Flags): Include Is_Processed_Transient to the list of
3505 displayed flags.
3506 (Write_Field8_Name): Alphabetize the output.
3507 (Write_Field11_Name): Alphabetize the output.
3508 (Write_Field12_Name): Alphabetize the output.
3509 (Write_Field13_Name): Alphabetize the output.
3510 (Write_Field14_Name): Alphabetize the output.
3511 (Write_Field15_Name): Alphabetize the output.
3512 (Write_Field16_Name): Alphabetize the output.
3513 (Write_Field17_Name): Alphabetize the output.
3514 (Write_Field18_Name): Alphabetize the output.
3515 (Write_Field19_Name): Alphabetize the output. Remove the output of
3516 Finalization_Chain_Entity.
3517 (Write_Field20_Name): Alphabetize the output.
3518 (Write_Field21_Name): Alphabetize the output.
3519 (Write_Field22_Name): Alphabetize the output.
3520 (Write_Field23_Name): Alphabetize the output. Remove the output of
3521 Associated_Final_Chain. Add output for Associated_Collection.
3522 (Write_Field24_Name): Alphabetize the output.
3523 (Write_Field25_Name): Add output for Finalizer.
3524 (Write_Field26_Name): Alphabetize the output.
3525 (Write_Field27_Name): Alphabetize the output.
3526 (Write_Field28_Name): Alphabetize the output.
3527 * einfo.ads: Add new field description for Associated_Collection and
3528 its uses in nodes.
3529 Remove Associated_Final_Chain and its uses in nodes.
3530 Remove Finalization_Chain_Entity and its uses in nodes.
3531 Add new field description for Finalizer and its uses in nodes.
3532 Add new synthesized attribute Is_Finalizer.
3533 Add new flag description for Is_Processed_Transient and its uses in
3534 nodes.
3535 Add new field description for Return_Flag and its uses in nodes.
3536 (Associated_Final_Chain): Removed along with its pragma Inline.
3537 (Associated_Collection): New routine and pragma Inline.
3538 (Finalization_Chain_Entity): Removed along with its pragma Inline.
3539 (Finalizer): New routine and pragma Inline.
3540 (Is_Finalizer): New routine and pragma Inline.
3541 (Is_Processed_Transient): New routine and pragma Inline.
3542 (Return_Flag): New routine and pragma Inline.
3543 (Set_Associated_Final_Chain): Removed along with its pragma Inline.
3544 (Set_Associated_Collection): New routine and pragma Inline.
3545 (Set_Finalization_Chain_Entity): Removed along with its pragma Inline.
3546 (Set_Finalizer): New routine and pragma Inline.
3547 (Set_Is_Processed_Transient): New routine and pragma Inline.
3548 (Set_Return_Flag): New routine and pragma Inline.
3549 * exp_aggr.adb: Alphabetize subprograms.
3550 (Build_Array_Aggr_Code): Remove formal Flist and its associated comment.
3551 (Build_Record_Aggr_Code): Remove formals Flist and Obj along with their
3552 associated comments. Remove local variables External_Final_List and
3553 Attach.
3554 Rename Ctrl_Stuff_Done to Finalization_Done. Rename local variable A to
3555 Ancestor. Remove the retrieval of finalization lists. Update the call to
3556 Make_Adjust_Call.
3557 (Convert_Aggr_In_Allocator): Remove the retrieval of finalization
3558 lists. Update the call to Late_Expansion.
3559 (Convert_Aggr_In_Assignment): Update the call to Late_Expansion.
3560 (Convert_Aggr_In_Object_Decl): Update the call to Late_Expansion.
3561 (Gen_Assign): Remove the retrieval of the finalization list used to
3562 build the assignment. Update the calls to Make_Init_Call and
3563 Make_Adjust_Call.
3564 (Gen_Ctrl_Actions_For_Aggr): Renamed to Generate_Finalization_Actions.
3565 Remove the mechanism to determine attachment levels and finalization
3566 list retrieval. Remove the processing for coextensions.
3567 (Init_Controller): Removed. Controllers no longer exist.
3568 (Late_Expansion): Remove formals Flist and Obj along with their
3569 associated comments. Update the calls to Build_Record_Aggr_Code and
3570 Build_Array_Aggr_Code.
3571 * exp_ch13.adb (Expand_N_Free_Statement): New routine.
3572 (Expand_N_Freeze_Entity): Add special processing for finalizers which
3573 appear in entry bodies, protected subprograms and task bodies.
3574 * exp_ch13.ads (Expand_N_Free_Statement): New routine.
3575 * exp_ch3.adb (Add_Final_Chain): Removed.
3576 (Build_Array_Init_Proc): Alphabetize local variables.
3577 (Build_Assignment): Alphabetize local variables. Update the call to
3578 Maked_Adjust_Call.
3579 (Build_Class_Wide_Master): Rename local variables to better reflect
3580 their role.
3581 (Build_Discriminant_Assignments): Code reformatting.
3582 (Build_Init_Call_Thru): Code reformatting.
3583 (Build_Init_Procedure): Code reformatting. Generate a special version
3584 of Deep_Finalize which is capable of finalizing all initialized
3585 components and ignore the rest.
3586 (Build_Init_Statements): Rename local variables to better reflect their
3587 role.
3588 Reimplement the mechanism to include the creation and update of an index
3589 variable called a "counter". It is used as a bookmark for tracing
3590 initialized and non-initialized components.
3591 (Build_Initialization_Call): Remove local variable Controller_Typ.
3592 Alphabetize all local variables. Remove the initialization of the
3593 record controller and update the call to Make_Init_Call.
3594 (Build_Record_Init_Proc): Rename formal Pe to Rec_Ent.
3595 New local variable Counter.
3596 (Constrain_Array): Alphabetize.
3597 (Expand_Freeze_Array_Type): Create a collection instead of a
3598 finalization list.
3599 (Expand_Freeze_Class_Wide_Type): New routine. Creates TSS primitive
3600 Finalize_Address which is used in conjunction with allocated controlled
3601 objects.
3602 (Expand_N_Object_Declaration): Remove the creation of a finalization
3603 list for anonymous access types. Update the calls to Make_Init_Call and
3604 Make_Adjust_Call.
3605 (Expand_Freeze_Record_Type): Remove local variable Flist. Remove the
3606 retrieval of finalization lists. Remove the expansion of the record
3607 controller. Create TSS primitive Finalize_Address used in conjunction
3608 with controlled objects on the heap. Create finalization collections
3609 for access-to-controlled record components.
3610 (Expand_Record_Controller): Removed.
3611 (Freeze_Type): Remove the freezing of record controllers. Freezing of
3612 class-wide types now requires additional processing. Create
3613 finalization collections for access-to-controlled types.
3614 (Increment_Counter): New routine.
3615 (Make_Counter): New routine.
3616 (Make_Eq_If): Remove the mention of Name_uController.
3617 (Make_Predefined_Primitive_Specs): There is no longer need to skip
3618 types coming from System.Finalization_Root.
3619 (Predef_Deep_Spec): Reimplemented to reflect the new parameter profiles.
3620 (Predefined_Primitive_Bodies): There is no longer need to skip types
3621 coming from System.Finalization_Root.
3622 (Stream_Operation_OK): Do not generate stream routines for
3623 type Ada.Finalization.Heap_Management.Finalization_Collection.
3624 * exp_ch3.ads: Alphabetize subprograms.
3625 * exp_ch4.adb: Remove with and use clause for Sem_Ch8.
3626 Add with and use clause for Lib.
3627 (Complete_Coextension_Finalization): Removed.
3628 (Complete_Controlled_Allocation): New routine. Create a finalization
3629 collection for anonymous access-to-controlled types. Create a custom
3630 Allocate which interfaces with the back end and the machinery in
3631 Heap_Management.
3632 (Expand_Allocator_Expression): Add necessary calls to
3633 Complete_Controlled_Allocation. Remove the retrieval of finalization
3634 lists. Update the calls to Make_Adjust_Call. Generate a call to
3635 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
3636 the associated collection.
3637 (Expand_N_Allocator): Remove the processing for dynamic coextensions.
3638 Code clean up. Remove the retrieval of finalization lists and
3639 attachment levels.
3640 Update the call to Make_Init_Call. Generate a call to
3641 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
3642 the associated collection.
3643 (Get_Allocator_Final_List): Removed. Finalization lists are not
3644 available.
3645 (Suitable_Element): Remove the mention of Name_uController.
3646 * exp_ch5.adb: Remove with and use clauses for Ttypes and Uintp.
3647 (Make_Tag_Ctrl_Assignment): Rewritten to simply do a finalization of
3648 the left hand side, carry out the assignment and adjust the left hand
3649 side.
3650 * exp_ch6.adb (Add_Final_List_Actual_To_Build_In_Place_Call): Removed.
3651 (Add_Collection_Actual_To_Build_In_Place_Call): New routine.
3652 (BIP_Formal_Suffix): Rename BIP_Final_List and BIPfinallist to
3653 BIP_Collection and BIPcollection.
3654 (Build_Heap_Allocator): New routine used to allocate the return object
3655 of a build-in-place function onto a collection.
3656 (Expand_Ctrl_Function_Call): Moved from Exp_Ch7.
3657 (Expand_Call): Do not replace direct calls to Deep routines with their
3658 aliases.
3659 (Expand_N_Extended_Return_Statement): Give all variables shorter names
3660 and update their occurrences. Add a special return flag to monitor the
3661 [ab]normal execution of the function. The flag is set right before the
3662 return statement.
3663 Rewrite the mechanism used to allocate a build-in-place return object
3664 on the heap or on a storage pool.
3665 (Is_Direct_Deep_Call): New routine.
3666 (Make_Build_In_Place_Call_In_Allocator): Add a collection to a
3667 build-in-place function call instead of a final list. Build a call to
3668 Set_Finalize_Address_Ptr to decorate the associated collection.
3669 (Make_Build_In_Place_Call_In_Anonymous_Context): Create a temporary in
3670 order to name the build-in-place function call's result for later
3671 finalization. Add a collection to a build-in-place function call
3672 instead of a final list.
3673 (Make_Build_In_Place_Call_In_Assignment): Add a collection to a
3674 build-in-place function call instead of a final list. Remove the code
3675 which moves one final list and transforms it into the actual in a
3676 nested build-in-place call.
3677 (Make_Build_In_Place_Call_In_Object_Declaration): Add a collection to a
3678 build-in-place function call instead of a final list.
3679 (Move_Final_List): Removed.
3680 (Needs_BIP_Collection): New routine.
3681 (Needs_BIP_Final_List): Removed.
3682 * exp_ch6.ads: Replace BIP_Final_List with BIP_Collection in
3683 enumeration type BIP_Formal_Kind.
3684 Update the related comment.
3685 (Needs_BIP_Collection): New routine.
3686 (Needs_BIP_Final_List): Removed.
3687 * exp_ch7.adb: Add with and use clauses for Elists, Exp_Ch6, Stringt
3688 and Ttypes. Remove with and use clauses for Sem_Type. Alphabetize the
3689 majority of subprograms in this unit. Add Name_Finalize_Address to
3690 array Name_Of and TSS_Finalize_Address to array Deep_Name_Of.
3691 (Build_Adjust_Or_Finalize_Statements): Create the adjust or finalization
3692 statements for an array type.
3693 (Build_Adjust_Statements): Create the adjust statements for a record
3694 type.
3695 (Build_Cleanup_Statements): New routine. A procedure which given any
3696 construct containing asynchronous calls, references to _master, or is a
3697 task body, a task allocation or a protected body produces the necessary
3698 runtime calls to clean up these constructs.
3699 (Build_Exception_Handler): New routine.
3700 (Build_Final_List): Removed.
3701 (Build_Finalization_Collection): New routine. A core procedure which
3702 creates a collection to service heap allocated controlled objects
3703 associated with an access-to-controlled type.
3704 (Build_Finalize_Statements): Create the finalization statements for a
3705 record types.
3706 (Build_Finalizer): New routine. A core procedure which given any
3707 construct with declarations and/or statements detects all objects which
3708 need any type of clean up (controlled objects, protected objects) and
3709 generates all necessary code to clean up the said objects in the proper
3710 order.
3711 (Build_Finalizer_Call): New routine.
3712 (Build_Initialize_Statements): Create the initialization statements for
3713 an array type. The generated routine contains code to finalize partially
3714 initialized arrays.
3715 (Build_Object_Declarations): New routine.
3716 (Build_Raise_Statement): New routine.
3717 (Clean_Simple_Protected_Objects): Removed.
3718 (Controller_Component): Removed.
3719 (Enclosing_Function): New routine.
3720 (Expand_Cleanup_Actions): Create a finalizer for a construct which has
3721 either declarations or statements or both.
3722 (Expand_N_Package_Body): Create a finalizer for a non-generic package.
3723 (Expand_N_Package_Declaration): Create a finalizer for a non-generic
3724 package.
3725 (Find_Final_List): Removed.
3726 (Global_Flist_Ref): Removed.
3727 (In_Finalization_Root): Removed.
3728 (Insert_Actions_In_Scope_Around): Determine the range of the transient
3729 scope in terms of tree nodes. Process all transient variables within
3730 that range.
3731 (Make_Adjust_Call): Rewritten. There is no longer an attach call
3732 generated after the adjust.
3733 (Make_Attach_Call): Removed.
3734 (Make_Call): New routine.
3735 (Make_Clean): Removed.
3736 (Make_Deep_Array_Body): Rewritten to simply invoke the appropriate
3737 build routines.
3738 (Make_Deep_Proc): Rewritten to generate the new profile signature used
3739 in Deep routines.
3740 (Make_Deep_Record_Body): Rewritten to simply invoke the appropriate
3741 build routines.
3742 (Make_Final_Call): Modified to simply create a call to either
3743 Deep_Finalize or Finalize.
3744 (Make_Finalize_Address_Body): New routine.
3745 (Make_Finalize_Address_Stmts): New routine. A function which produces
3746 TSS primitive Finalize_Address used in conjunction with heap allocated
3747 controlled objects.
3748 (Make_Handler_For_Ctrl_Operation): Add specialized code for .NET/JVM.
3749 (Make_Init_Call): Rewritten. There is no longer an attach call
3750 generated after initialization.
3751 (Make_Local_Deep_Finalize): New routine.
3752 (Make_Set_Finalize_Address_Ptr_Call): New routine.
3753 (Make_Transient_Block): Remove the finalization list retrieval and
3754 manipulation.
3755 (Needs_Finalization): Moved to Exp_Util.
3756 (Parent_Field_Type): New routine.
3757 (Preprocess_Components): New routine.
3758 (Process_Transient_Objects): New routine.
3759 (Wrap_HSS_In_Block): New routine.
3760 (Wrap_Transient_Declaration): Remove finalization list management and
3761 controller insertion.
3762 (Wrap_Transient_Expression): Code reformatting.
3763 (Wrap_Transient_Statement): Code reformatting.
3764 * exp_ch7.ads (Build_Final_List): Removed.
3765 (Build_Finalization_Collection): New routine.
3766 (Build_Raise_Statement): New routine.
3767 (Controller_Component): Removed.
3768 (Expand_Ctrl_Function_Call): Moved to Exp_Ch6.
3769 (Find_Final_List): Removed.
3770 (In_Finalization_Root): Removed.
3771 (Is_Simple_Protected_Type): Update related comment.
3772 (Make_Adjust_Call): New parameter profile and associated comments.
3773 (Make_Attach_Call): Removed.
3774 (Make_Final_Call): New parameter profile and associated comments.
3775 (Make_Finalize_Address_Body): New routine.
3776 (Make_Init_Call): New parameter profile and associated comments.
3777 (Make_Local_Deep_Finalize): New routine.
3778 (Make_Set_Finalize_Address_Ptr_Call): New routine.
3779 (Needs_Finalization): Moved to Exp_Util.
3780 * exp_ch9.adb (Add_Object_Pointer): Code reformatting.
3781 (Expand_N_Protected_Body): Remove the handling of finalization lists.
3782 (Find_Protection_Type): Moved to Exp_Util.
3783 * exp_disp.adb: Remove with and use clauses for Exp_Ch7.
3784 (Make_DT): Update sequence of dispatch table initialization. Remove the
3785 initialization of field RC_Offset. Add initialization of field Needs_
3786 Finalization.
3787 * exp_intr.adb (Expand_Unc_Deallocation): Code reformatting.
3788 Reimplement how an object is first finalized, then deallocated.
3789 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
3790 Code reformatting.
3791 * exp_tss.ads: Add special suffix for TSS primitive Finalize_Address.
3792 Register TSS_Finalize_Address with type TSS_Names.
3793 * exp_util.adb (Build_Allocate_Deallocate_Proc): New routine. This core
3794 procedure provides the interface between an allocation / deallocation
3795 and the support machinery in Ada.Finalization.Heap_Management.
3796 (Find_Init_Call): Code reformatting.
3797 (Find_Init_Call_In_List): Code reformatting.
3798 (Find_Protection_Type): Moved from Exp_Ch9.
3799 (Find_Prim_Op): Reimplement to add preference of recovered primitive.
3800 (Has_Controlled_Coextensions): Removed.
3801 (Has_Controlled_Objects): New routine.
3802 (In_Library_Level_Package_Body): New routine.
3803 (Insert_Action_After): New routine.
3804 (Is_Finalizable_Transient): New routine. This predicate determines
3805 whether an object declaration is one of the many variants of controlled
3806 transients.
3807 (Is_Null_Access_BIP_Func_Call): New routine.
3808 (Is_Non_BIP_Func_Call): New routine.
3809 (Is_Related_To_Func_Return): New routine.
3810 (Needs_Finalization): Moved from Exp_Ch7.
3811 * exp_util.ads (Build_Allocate_Deallocate_Proc): New routine.
3812 (Find_Protection_Type): Moved from Exp_Ch9.
3813 (Has_Controlled_Coextensions): Removed.
3814 (Has_Controlled_Objects): New routine.
3815 (In_Library_Level_Package_Body): New routine.
3816 (Insert_Action_After): New routine.
3817 (Is_Finalizable_Transient): New routine.
3818 (Is_Null_Access_BIP_Func_Call): New routine.
3819 (Is_Non_BIP_Func_Call): New routine.
3820 (Is_Related_To_Func_Return): New routine.
3821 (Needs_Finalization): Moved from Exp_ch7.
3822 * expander.adb (Expand): Add a case for N_Free_Statement.
3823 * freeze.adb (Freeze_All): Replace the generation of a finalization
3824 list with a collection for access-to-controlled types.
3825 (Freeze_Entity): Code reformatting.
3826 (Freeze_Record_Type): Remove the freezing of a record controller
3827 component.
3828 (Freeze_Subprogram): Code reformatting.
3829 * inline.adb (Cleanup_Scopes): Remove the reset of the scope
3830 finalization list.
3831 * lib-writ.adb (Write_Unit_Information): Output "PF" when a package
3832 has a library-level finalizer.
3833 * lib-writ.ads: Add "PF" to the sequence of unit attributes.
3834 * a-filico.ads, a-filico.adb, s-finimp.ads, s-finimp.adb: Removed.
3835 * Makefile.rtl: Remove a-filico and s-finimp from the list of object
3836 files. Add a-fihema to the list of object files.
3837 * par-ch4.adb:
3838 Alphabetize the associations in type Is_Parameterless_Attribute.
3839 * rtsfind.ads: Ada.Finalization_List.Controller and
3840 System.Finalization_Implementation are no longer a GNAT unit.
3841 Update the range of type Ada_Finalization_Child. Remove the following
3842 recoverable entities:
2c7f9cc0 3843
df3e68b1
HK
3844 RE_Attach_To_Final_List
3845 RE_Deep_Tag_Attach
3846 RE_Finalize_List
3847 RE_Finalize_One
3848 RE_Finalizable_Ptr_Ptr
3849 RE_Global_Final_List
3850 RE_Limited_Record_Controller
3851 RE_List_Controller
3852 RE_Move_Final_List
3853 RE_Record_Controller
3854 RE_Simple_List_Controller
2c7f9cc0 3855
df3e68b1 3856 Add the following recoverable entities:
2c7f9cc0 3857
df3e68b1
HK
3858 RE_Add_Offset_To_Address
3859 RE_Allocate
3860 RE_Base_Pool
3861 RE_Deallocate
3862 RE_Exception_Identity
3863 RE_Finalization_Collection
3864 RE_Finalization_Collection_Ptr
3865 RE_Needs_Finalization
3866 RE_Save_Library_Occurrence
3867 RE_Set_Finalize_Address_Ptr
3868 RE_Set_Storage_Pool_Ptr
3869 RE_Storage_Count
3870 * sem_aggr.adb (Resolve_Record_Aggregate): Remove mention of
3871 Name_uController.
3872 * sem_aux.adb (First_Discriminant): Remove mention of Name_uController.
3873 (First_Stored_Discriminant): Remove the mention of Name_uController.
3874 * sem_aux.ads: Comment reformatting.
3875 * sem_ch10.adb (Build_Chain): Signal the class-wide creation machinery
3876 to redecorate an already existing class-wide type.
3877 (Decorate_Tagged_Type): New parameter profile and associated comment.
3878 Create a "shadow class-wide type" for a shadow entity.
3879 * sem_ch11.adb (Analyze_Exception_Handlers): Remove the dubious setting
3880 of the final chain along with the associated comment.
3881 * sem_ch3.adb (Access_Type_Declaration): Add new local variable
3882 Full_Desig and set it to the full view of the designated type.
3883 Initialize the finalization collection to empty.
3884 (Build_Derived_Record_Type): Alphabetize local variables. Code
3885 reformatting.
3886 (Collect_Fixed_Components): Remove the mention of Name_uController.
3887 (Create_Constrained_Components): Remove the mention of Name_uController.
3888 (Make_Class_Wide_Type): Add specialized code to redecorate an existing
3889 class-wide type of a shadow entity.
3890 (Process_Full_View): Update the machinery which marks type
3891 Limited_Controlled's entity as limited.
3892 * sem_ch4.adb (Analyze_One_Call): Code reformatting.
3893 * sem_ch6.adb (Create_Extra_Formals): Do not generate a finalization
3894 list, instead make a collection build-in-place formal.
3895 * sem_ch8.adb (Analyze_Object_Renaming): Look at the available view of
3896 a designated type in order to establish a match between the renaming
3897 and the renamed entity.
3898 (Find_Selected_Component): Add guard to prevent spurious exceptions
3899 from being raised on .NET/JVM.
3900 * sem_disp.adb (Check_Dispatching_Operation): Include Finalize_Address
3901 to the list of primitive that need special processing. Update arrays
3902 C_Names and D_Names.
3903 (Replace_Types): Handle class-wide types.
3904 * sem_elab.adb (Check_A_Call): Since Deep_Initialize now has a
3905 different parameter profile, look at the first formal.
3906 * sem_prag.adb: Remove with and use clauses for Exp_Ch7. Add with and
3907 use clauses for Exp_Util.
3908 * sem_res.adb: Remove with and use clauses for Elists.
3909 (Propagate_Coextensions): Removed.
3910 (Resolve_Allocator): Do not propagate the list of coextensions from one
3911 allocator to another.
3912 * sem_util.adb (Build_Actual_Subtype_Of_Component): Rename variable
3913 Deaccessed_T to Desig_Typ.
3914 (Enter_Name): Remove the mention of Name_uController.
3915 (Gather_Components): Remove the mention of Name_uController.
3916 (Incomplete_Or_Private_View): New routine.
3917 (Is_Coextension_Root): Removed.
3918 (Is_Fully_Initialized_Type): Remove the mention of Name_uController.
3919 * sem_util.ads (Incomplete_Or_Private_View): New routine.
3920 (Is_Coextension_Root): Removed.
3921 * s-finroo.ads: Remove with clause for Ada.Unchecked_Conversion.
3922 Controlled types are now derived from a null tagged record. Remove
3923 types Finalizable_Ptr, Finalizable and Empty_Root_Controlled.
3924 * sinfo.adb (Coextensions): Removed.
3925 (Set_Coextensions): Removed.
3926 * sinfo.ads: Remove Coextensions from the explanation of node fields
3927 and its uses in nodes.
3928 Update the field usage of N_Allocator.
3929 (Coextensions): Removed along with its pragma Inline.
3930 (Set_Coextensions): Removed along with its pragma Inline.
3931 * snames.ads-tmpl: Remove names
2c7f9cc0 3932
df3e68b1
HK
3933 Name_uClean
3934 Name_uController
3935 Name_uFinal_List
3936 Name_uLocal_Final_List
3937 Name_Finalization_Root
3938 Name_Next
3939 Name_Prev
2c7f9cc0 3940
df3e68b1 3941 Add names
2c7f9cc0 3942
df3e68b1
HK
3943 Name_uFinalizer
3944 Name_Finalize_Address
3945 * s-pooglo.adb (Allocate): Add overriding indicator.
3946 (Deallocate): Add overriding indicator.
3947 (Storage_Size): Add overriding indicator.
3948 * s-soflin.adb (Adafinal_NT): Invoke Finalize_Library_Objects rather
3949 than Finalize_Global_List.
3950 (Null_Finalize_Global_List): Removed.
3951 (Save_Library_Occurrence): New routine.
3952 * s-soflin.ads: Remove variable Finalize_Global_List along with its
3953 initialization. Add variable Finalize_Library_Objects along with its
3954 pragma Export. Add variables Library_Exception and
3955 Library_Exception_Set along with their pragma Export.
3956 (Null_Finalize_Global_List): Removed.
3957 (Save_Library_Occurrence): New routine.
3958 * s-tassta.adb (Finalize_Global_Tasks): Call Finalize_Library_Objects
3959 rather than Finalize_Global_List.
3960 * tbuild.adb (Unchecked_Convert_To): Capture and set the parent field
3961 of the constructed node.
3962
2ee06322
RO
39632011-08-03 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3964
3965 * link.c: Include "auto-host.h" before system headers.
3966
f77b022b
VC
39672011-08-03 Vincent Celier <celier@adacore.com>
3968
3969 * make.adb (Gnatmake): Add to table Library_Projs only library projects
3970 that are not extended. Do not check if a library project that is
3971 extended should be regenerated. Do not add to table Library_Paths the
3972 libraries that are in extended projects. Link only with libraries that
3973 are in libray projects that are not extended.
3974 * prj-nmsc.adb (Check_Library_Attributes): Do not reset flag Library
3975 for a library project that is extended.
3976
0187b60e
AC
39772011-08-03 Gary Dismukes <dismukes@adacore.com>
3978
3979 * sem_ch6.adb (Find_Corresponding_Spec): When in an instance, skip
3980 conforming subprogram renamings that appear to be completions if they
3981 are not fully conformant.
3982 Such renamings are homographs but not completions.
3983 * sem_type.adb (Disambiguate): Handle disambiguation of overloaded
3984 names in a subprogram renaming that appears in an instance.
3985
39862011-08-03 Ed Schonberg <schonberg@adacore.com>
3987
3988 * exp_util.adb (Expand_Subtype_From_Expr): if the type is limited but
3989 not immutably limited, build actual subtype from expression to provide
3990 proper bounds to caller.
3991
39922011-08-03 Gary Dismukes <dismukes@adacore.com>
3993
3994 * sem_ch8.adb: Minor comment correction.
3995
39962011-08-03 Thomas Quinot <quinot@adacore.com>
3997
3998 * exp_strm.adb (Build_Array_Input_Function): In Ada 2005 mode, when
3999 returning a limited array, use an extended return statement.
4000
40012011-08-03 Vincent Celier <celier@adacore.com>
4002
4003 * make.adb (Initialize): If --subdirs= is used, but no project file is
4004 specified, attempt to create the specify subdir if it does not already
4005 exist and use it as the object directory as if -D had been specified.
4006
40072011-08-03 Arnaud Charlet <charlet@adacore.com>
4008
4009 * s-tpopsp-vms.adb: New file.
4010 * s-taprop-vms.adb: Put back ATCB_Key, since needed by this file on VMS.
4011 * gcc-interfaces/Makefile.in: Use s-taprop-vms.adb on VMS.
4012
e280f981
AC
40132011-08-03 Emmanuel Briot <briot@adacore.com>
4014
4015 * make.adb, makeutl.adb, makeutl.ads, clean.adb (Makeutl.Queue): new
4016 package.
4017
40182011-08-03 Yannick Moy <moy@adacore.com>
4019
4020 * cstand.adb (Create_Standard): select Universal_Integer as an ALFA type
4021 * sem_ch3.adb (Array_Type_Declaration): detect array types in ALFA
4022 * sem_util.adb, sem_util.ads (Has_Static_Array_Bounds): new function to
4023 detect that an array has static bounds.
4024
98c99a5a
AC
40252011-08-03 Thomas Quinot <quinot@adacore.com>
4026
4027 * exp_dist.adb: Minor reformatting.
4028
40292011-08-03 Arnaud Charlet <charlet@adacore.com>
4030
4031 * s-taprop-irix.adb, s-taprop-hpux-dce.adb, s-taprop-vms.adb
4032 (ATCB_Key): Removed, not always used.
4033
40342011-08-03 Emmanuel Briot <briot@adacore.com>
4035
4036 * gnatcmd.adb, make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads,
4037 clean.adb, prj-conf.adb, prj-env.adb, prj-env.ads (Makeutl): remove
4038 most remaining global variables.
4039
686d0984
AC
40402011-08-03 Robert Dewar <dewar@adacore.com>
4041
4042 * gnatcmd.adb, prj-proc.adb, mlib-prj.adb, prj.adb, makeutl.ads,
4043 prj-util.adb, prj-util.ads, prj-conf.adb, prj-env.adb: Minor
4044 reformatting.
4045
40462011-08-03 Javier Miranda <miranda@adacore.com>
4047
4048 * exp_util.adb (Is_VM_By_Copy_Actual): Include N_Slide nodes as actuals
4049 that must be passed by copy in VM targets.
4050
40512011-08-03 Emmanuel Briot <briot@adacore.com>
4052
4053 * prj.ads, prj-nmsc.adb (Files_Htable): removed this htable, which
4054 duplicates a similar htable now in the project tree.
4055
40562011-08-03 Claire Dross <dross@adacore.com>
4057
4058 * a-cfdlli.adb, a-cfhama.adb, a-cfhase.adb, a-cforma.adb, a-cforse.adb,
4059 a-cofove.adb ("=", Length, Is_Empty, Clear, Assign, Copy, Element,
4060 Replace_Element, Query_Element, Update_Element, Move, Insert, Prepend,
4061 Append, Delete, Delete_First, Delete_Last, Reverse_Element, Swap,
4062 Splice, First, First_Element, Last, Last_Element, Next, Previous, Find,
4063 Reverse_Find, Contains, Has_Element, Iterate, Reverse_Iterate, Capacity,
4064 Reserve_Length, Length, Strict_Equal, Left, Right): Data-structure
4065 update.
4066
40672011-08-03 Arnaud Charlet <charlet@adacore.com>
4068
4069 * s-taprop-posix.adb, s-taprop-linux.adb, s-taprop-tru64.adb
4070 (ATCB_Key): Removed, not always used.
4071 * s-tpopsp-posix.adb, s-tpopsp-posix-foreign.adb (ATCB_Key): Moved from
4072 s-taprop-posix.adb.
4073 * s-tpopsp-tls.adb: New file.
4074 * gcc-interface/Makefile.in: Use TLS implementation of s-tpopsp.adb on
4075 x86/x64/ia64/powerpc/sparc Linux.
4076
40772011-08-03 Arnaud Charlet <charlet@adacore.com>
4078
4079 * system-aix.ads, system-aix64.ads: Set ZCX_By_Default to True.
4080 * gcc-interface/Makefile.in: Switch to ZCX by default on AIX ports.
4081
40822011-08-03 Thomas Quinot <quinot@adacore.com>
4083
4084 * rtsfind.ads, exp_dist.adb, exp_dist.ads
4085 (Build_From_Any_Call, Build_To_Any_Call, Build_TypeCode_Call):
4086 Fix type selection for mapping integer types to PolyORB types.
4087
40882011-08-03 Bob Duff <duff@adacore.com>
4089
4090 * sem_ch7.adb: Minor comment clarification.
4091
40922011-08-03 Bob Duff <duff@adacore.com>
4093
4094 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): If we get
4095 an error analyzing a choice, skip further processing. Further
4096 processing could cause a crash or cascade errors.
4097
40ecf2f5
EB
40982011-08-03 Emmanuel Briot <briot@adacore.com>
4099
4100 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, mlib-prj.adb,
4101 prj.adb, prj.ads, makeutl.adb, makeutl.ads, clean.adb, prj-nmsc.adb,
4102 prj-util.adb, prj-util.ads, prj-conf.adb, prj-conf.ads, prj-env.adb,
4103 prj-env.ads (Shared_Project_Tree_Data): new type
4104 An aggregate project and its aggregated trees need to share the common
4105 data structures used for lists of strings, packages,... This makes the
4106 code simpler since otherwise we have to pass the root tree (also used
4107 for the configuration file data) in addition to the current project
4108 tree. This also avoids ambiguities as to which tree should be used.
4109 And finally this saves a bit of memory.
4110 (For_Every_Project_Imported): new parameter Tree.
4111 Since aggregated projects are using a different tree, we need to let
4112 the caller know which tree to use to manipulate the returned project.
4113
9fde638d
RD
41142011-08-03 Robert Dewar <dewar@adacore.com>
4115
4116 * prj-proc.adb, exp_util.ads, exp_ch9.adb, make.adb, prj-ext.adb,
4117 prj-ext.ads, alfa.ads, sem_ch4.adb, makeutl.adb, makeutl.ads,
4118 lib-xref-alfa.adb, sem_cat.adb, exp_dist.adb, get_alfa.adb,
4119 prj-env.adb, prj-env.ads, prj-tree.adb, alfa.ads: Minor reformatting.
4120
95eb8b69
AC
41212011-08-03 Javier Miranda <miranda@adacore.com>
4122
4123 * exp_util.adb, sem_aux.adb, exp_util.ads, sem_aux.ads:
4124 Move routine Is_VM_By_Copy_Actual from sem_aux to exp_util.
4125
41262011-08-03 Bob Duff <duff@adacore.com>
4127
4128 * sem_ch8.adb (Is_Primitive_Operator_In_Use): Always check In_Use on
4129 the Base_Type.
4130
41312011-08-03 Joel Brobecker <brobecker@adacore.com brobecker>
4132
4133 * g-sha256.ads, g-sha512.ads, g-sha1.ads, g-sha224.ads, g-sha384.ads,
4134 g-sehash.ads: Fix typo. Update header.
4135
41362011-08-03 Thomas Quinot <quinot@adacore.com>
4137
4138 * exp_ch6.adb (Expand_Actuals): Remove Ada_2005 guard on build-in-place
4139 expansion.
4140
41412011-08-03 Gary Dismukes <dismukes@adacore.com>
4142
4143 * sem_ch4.adb (Analyze_Overloaded_Selected_Component): Consider
4144 prefixes of private types along with records, since the selector may be
4145 a discriminant.
4146 * sem_res.adb (Resolve_Selected_Component): Consider prefixes of
4147 private types along with records, since the selector may be a
4148 discriminant.
4149
92e77027
AC
41502011-08-03 Emmanuel Briot <briot@adacore.com>
4151
b2f7ebc1 4152 * prj-pp.adb (Pretty_Print): Remove trailing blank line.
92e77027
AC
4153
41542011-08-03 Javier Miranda <miranda@adacore.com>
4155
4156 * sem_aux.adb (Is_VM_By_Copy_Actual): Fix wrong use of
4157 Tagged_Type_Expansion.
4158
41592011-08-03 Yannick Moy <moy@adacore.com>
4160
b2f7ebc1
GP
4161 * sem_res.adb (Resolve_Op_Concat_Arg): Do not issue a SPARK
4162 violation when the argument of concatenation is the name of a
4163 constant.
92e77027 4164
ab29a348
EB
41652011-08-03 Emmanuel Briot <briot@adacore.com>
4166
4167 * prj-proc.adb, prj-ext.adb, prj-ext.ads, prj-env.adb, prj-env.ads,
4168 prj-tree.adb, prj-tree.ads (Initialize_And_Copy, Copy): new subprograms
4169 (Process_Declarative_Items): new parameter Child_Env.
4170
9466892f
AC
41712011-08-03 Yannick Moy <moy@adacore.com>
4172
589ef536
GP
4173 * alfa.ads: Update format of ALFA section in ALI file in order to
4174 add a mapping from bodies to specs when both are present.
4175 (ALFA_Scope_Record): Add components for spec file/scope.
4176 * get_alfa.adb (Get_ALFA): Read the new file/scope for spec when
4177 present.
4178 * lib-xref-alfa.adb (Collect_ALFA): After all scopes have been
4179 collected, fill in the spec information when relevant.
4180 * put_alfa.adb (Put_ALFA): Write the new file/scope for spec when
9466892f
AC
4181 present.
4182
41832011-08-03 Eric Botcazou <ebotcazou@adacore.com>
4184
4185 * inline.adb (Add_Inlined_Subprogram): Do not consider the enclosing
4186 code unit to decide whether to add internally generated subprograms.
2c7f9cc0 4187
9466892f
AC
41882011-08-03 Javier Miranda <miranda@adacore.com>
4189
4190 * sem_aux.ads, sem_aux.adb (Is_VM_By_Copy_Actual): New subprogram.
589ef536
GP
4191 * exp_ch9.adb (Build_Simple_Entry_Call): Handle actuals that must
4192 be handled by copy in VM targets.
9466892f
AC
4193
41942011-08-03 Emmanuel Briot <briot@adacore.com>
4195
589ef536 4196 * make.adb, makeutl.adb, makeutl.ads (Make.Switches_Of): Share
9466892f
AC
4197 code with Makeutl.Get_Switches.
4198 * prj-tree.adb: Update comment.
4199
b5ea9143
AC
42002011-08-03 Thomas Quinot <quinot@adacore.com>
4201
4202 * sem_cat.adb (Validate_RCI_Subprogram_Declaration): Reject a remote
4203 subprogram with a limited formal that does not support external
4204 streaming.
4205
42062011-08-03 Yannick Moy <moy@adacore.com>
4207
4208 * get_alfa.adb (Get_ALFA): add missing Skip_Spaces at start of
4209 continuation line
4210 * lib-xref-alfa.adb (Add_ALFA_File): split removal of scopes that are
4211 not from current unit in two phases, because it is not possible to
4212 change the table while iterating over its content.
4213 * put_alfa.adb (Put_ALFA): reset current file/scope at each new entity
4214
42152011-08-03 Sergey Rybin <rybin@adacore.com>
4216
4217 * vms_data.ads: Add qualifier for gnatmetric --no-static-loop option
4218 * gnat_ugn.texi: Update description of complexity metrics (gnatmetric)
4219
668a19bc
ES
42202011-08-03 Ed Schonberg <schonberg@adacore.com>
4221
4222 * sem_res.adb (Resolve_Op_Concat_Arg): if the argument is an aggregate
4223 and the component type is composite, this is ambiguous for predefined
4224 concatenation, but if the node is not overloaded and the entity is a use
4225 -defined function its profile can be used to resolve that aggregate.
4226
170b2989
AC
42272011-08-03 Robert Dewar <dewar@adacore.com>
4228
4229 * exp_ch4.adb: Minor code cleanup.
4230
42312011-08-03 Thomas Quinot <quinot@adacore.com>
4232
4233 * exp_dist.adb: Do not generate distribution stubs if serious errors
4234 have been diagnosed.
4235
42362011-08-03 Ed Schonberg <schonberg@adacore.com>
4237
4238 * sem_ch4.adb (Try_Primitive_Operation): when checking the validity of
4239 the first formal of a primitive operation, go to the base type to
4240 handle properly an access to a derived type with constrained
4241 discriminants.
4242 * sem_type.adb (Disambiguate): an immediately visible operator hides a
4243 user-defined function that is only use-visible.
170b2989 4244
e917aec2
RD
42452011-08-03 Robert Dewar <dewar@adacore.com>
4246
4247 * sem_aggr.adb, sem_ch3.adb, lib.ads, gnatcmd.adb, prj-proc.adb,
4248 make.adb, lib-writ.adb, prj-part.adb, prj-part.ads, prj-ext.adb,
4249 fname-uf.adb, prj-ext.ads, prj.adb, prj.ads, sem_attr.adb, alfa.adb,
4250 prj-makr.adb, errout.adb, makeutl.adb, makeutl.ads, restrict.ads,
4251 sem_ch6.adb, g-pehage.adb, clean.adb, put_alfa.adb, lib-xref-alfa.adb,
4252 prj-nmsc.adb, prj-nmsc.ads, sem_ch8.adb, prj-pars.ads, exp_aggr.adb,
4253 prj-attr.ads, sem_ch13.adb, get_alfa.adb, prj-env.adb, prj-env.ads,
4254 alfa_test.adb, prj-tree.adb, prj-tree.ads, einfo.ads: Minor reformatting
4255
42562011-08-03 Robert Dewar <dewar@adacore.com>
4257
4258 * repinfo.adb (List_Mechanism): Add handling of
4259 Convention_Ada_Pass_By_XXX.
4260 * sem_mech.adb (Set_Mechanism): Ditto.
4261 * sem_prag.adb (Process_Convention): Add entries for
4262 Convention_Ada_Pass_By_XXX.
4263 * snames.adb-tmpl, snames.ads-tmpl: Ditto.
4264
49bfcf43
AC
42652011-08-03 Pascal Obry <obry@adacore.com>
4266
4267 * makeutl.adb: Minor reformatting.
4268
42692011-08-03 Vincent Celier <celier@adacore.com>
4270
4271 * fname-uf.adb
4272 (Get_File_Name) If the file cannot be found when there are no config
4273 pragmas file and May_Fail is True, return No_File instead of the file
4274 name, to be consistent.
4275
42762011-08-03 Pascal Obry <obry@adacore.com>
4277
4278 * adaint.c (__gnat_is_executable_file_attr): Avoid access
4279 to null pointer.
4280
42812011-08-03 Javier Miranda <miranda@adacore.com>
4282
4283 * sem_ch13.adb
4284 (Same_Representation): In VM targets the representation of arrays with
4285 aliased components differs from arrays with non-aliased components.
4286
34798441
EB
42872011-08-03 Emmanuel Briot <briot@adacore.com>
4288
4289 * prj-proc.adb, prj-attr.adb, prj-attr.ads (Get_Attribute_Index): do
4290 not systematically lower case attribute indexes that contain no "."
4291 Fix definition of several Naming attributes, which take
4292 a unit name as index and therefore should be case insensitive.
4293 Minor refactoring (reduce length of variable names).
4294
42952011-08-03 Emmanuel Briot <briot@adacore.com>
4296
4297 * makeutl.adb, makeutl.ads (Get_Switches): new subprogram.
4298
4437a530
EB
42992011-08-03 Emmanuel Briot <briot@adacore.com>
4300
4301 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, prj-part.adb,
4302 prj-part.ads, switch-m.adb, switch-m.ads, prj-makr.adb, clean.adb,
4303 prj-pars.adb, prj-pars.ads, prj-conf.adb, prj-conf.ads, prj-tree.adb,
4304 prj-tree.ads (Prj.Tree.Environment): new type.
4305
804fe3c4
EB
43062011-08-03 Emmanuel Briot <briot@adacore.com>
4307
4308 * prj-proc.adb, prj.ads, makeutl.adb, makeutl.ads, prj-conf.adb,
4309 prj-tree.adb, prj-tree.ads (Environment): new type.
4310
c565bc66
AC
43112011-08-03 Emmanuel Briot <briot@adacore.com>
4312
4313 * prj-tree.ads: Remove unused variable.
4314
43152011-08-03 Yannick Moy <moy@adacore.com>
4316
4317 * restrict.adb (Restriction_Msg): set "SPARK" all in upper case for
4318 issuing messages related to SPARK restriction violation.
4319
4ee646da
AC
43202011-08-03 Ed Schonberg <schonberg@adacore.com>
4321
4322 * sem_ch6.adb: guard against error nodes in return statements.
4323
43242011-08-03 Arnaud Charlet <charlet@adacore.com>
4325
4326 * errout.adb (Error_Msg_Internal): the main unit has not been read yet,
4327 a warning can only appear on a configuration file, so emit warning
4328 without further checks.
4329
43302011-08-03 Arnaud Charlet <charlet@adacore.com>
4331
4332 * s-interr.ads: add overriding keyword.
4333
43342011-08-03 Geert Bosch <bosch@adacore.com>
4335
4336 * exp_attr.adb: Fix minor typo.
4337
43382011-08-03 Ed Schonberg <schonberg@adacore.com>
4339
4340 * par-ch4.adb: improve error recovery.
4341
c0e538ad
AC
43422011-08-03 Emmanuel Briot <briot@adacore.com>
4343
4344 * prj-part.adb, prj-part.ads, prj-makr.adb, prj-pars.adb, prj-conf.adb,
4345 prj-env.adb (Prj.Part.Parse): change parameter Always_Errout_Finalize
4346 to Errout_Handling.
4347
43482011-08-03 Emmanuel Briot <briot@adacore.com>
4349
4350 * prj-dect.adb (Parse_Attribute_Declaration): make sure we can use
4351 "external" as an attribute name in aggregate projects.
4352
43532011-08-03 Jose Ruiz <ruiz@adacore.com>
4354
4355 * s-taprop-vxworks.adb: (Create_Task, Initialize): Ada 2012 pragma CPU
4356 uses CPU numbers starting 1, while VxWorks uses CPU numbers starting
4357 from 0, so we need to adjust.
4358
43592011-08-03 Emmanuel Briot <briot@adacore.com>
4360
4361 * prj-proc.adb, prj-ext.adb, prj-ext.ads, makeutl.adb, prj-tree.adb,
4362 prj-tree.ads, gnatcmd.adb, clean.adb (External_References): new type.
4363
c4d67e2d
AC
43642011-08-03 Yannick Moy <moy@adacore.com>
4365
4366 * sem_ch6.adb (New_Overloaded_Entity): only issue error for SPARK
4367 restriction on overloaded entity if the entity is not an operator.
4368
43692011-08-03 Yannick Moy <moy@adacore.com>
4370
4371 * sem_ch7.adb, sem_res.adb, sem_attr.adb, restrict.adb,
4372 restrict.ads: Rename remaining Check_Formal_Restriction* into
4373 Check_SPARK_Restriction*.
4374
43752011-08-03 Emmanuel Briot <briot@adacore.com>
4376
4377 * prj-proc.adb, prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb,
4378 prj-nmsc.ads, prj-err.adb (Project_Data): now discriminated on its
4379 qualifier.
4380 (Project_Empty): removed
4381 (Empty_Project): new parameter Qualifier
4382 This is used to have fields specific to aggregate projects, cleaner
4383 New field to store the list of aggregated projects.
4384 (Check_Aggregate_Project): removed
4385 (Process_Aggregated_Projects, Free): new subprograms.
4386
3f5a8fee
AC
43872011-08-03 Olivier Hainque <hainque@adacore.com>
4388
4389 * tracebak.c (STOP_FRAME ppc AIX): Stop at null return address as well.
4390
43912011-08-03 Ed Schonberg <schonberg@adacore.com>
4392
4393 * sem_ch8.adb (Analyze_Object_Renaming): if the renamed object is an
4394 explicit dereference of an unconstrained type, create a constrained
4395 subtype for it, as is done for function calls that return an
4396 unconstrained type.
4397
43982011-08-03 Thomas Quinot <quinot@adacore.com>
4399
4400 * g-pehage.adb (Finalize): Avoid possible double-free.
4401
44022011-08-03 Steve Baird <baird@adacore.com>
4403
4404 * exp_attr.adb (Expand_N_Attribute_Reference): Don't expand
4405 Elab_Spec/Body attrs in CodePeer_Mode.
4406
44072011-08-03 Javier Miranda <miranda@adacore.com>
4408
4409 * exp_aggr.adb (Flatten): Convert to positional form aggregates whose
4410 low bound is not known at compile time but they have no others choice.
4411 Done because in this case the bounds can be obtained directly from the
4412 aggregate.
4413
44142011-08-03 Ed Falis <falis@adacore.com>
4415
4416 * s-tasinf-vxworks.ads: Update comment to reflect 0 indexing of CPUs
4417 on VxWorks SMP. Remove unusable constant ANY_CPU.
4418
a96ca600
EB
44192011-08-03 Emmanuel Briot <briot@adacore.com>
4420
4421 * gnatcmd.adb, make.adb, prj-part.adb, prj-part.ads, prj-makr.adb,
4422 clean.adb, prj-nmsc.adb, prj-pars.adb, prj-conf.adb, prj-env.adb,
4423 prj-env.ads (Prj.Env.Initialize_Default_Project_Path,
4424 Prj.Env.Initialize_Empty): new subprograms
4425 (Get_Env, Find_Project): remove parameter Target_Name.
4426
3e582869
AC
44272011-08-03 Gary Dismukes <dismukes@adacore.com>
4428
4429 * sem_ch3.adb (Build_Derived_Record_Type): Test the Derive_Subps formal
4430 as a condition for the delayed call to Derived_Subprograms done for the
4431 case of the rewriting of a derived type that constrains the
4432 discriminants of its parent type.
4433 Avoids redundant subprogram derivations for private subtype derivations.
4434
44352011-08-03 Javier Miranda <miranda@adacore.com>
4436
4437 * exp_aggr.adb (Init_Hidden_Discriminants): New subprogram of
4438 Build_Record_Aggr_Code.
4439 (Build_Record_Aggr_Code): Add missing support to initialize hidden
4440 discriminants in extension aggregates.
4441
44422011-08-03 Emmanuel Briot <briot@adacore.com>
4443
4444 * prj-pp.adb (Print): also output project qualifiers, since in
4445 particular "aggregate" is mandatory in an aggregate project.
4446
44472011-08-03 Emmanuel Briot <briot@adacore.com>
4448
4449 * prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb, prj-env.adb:
4450 (Debug_Output): new function.
4451
56e94186
AC
44522011-08-03 Eric Botcazou <ebotcazou@adacore.com>
4453
4454 * gnat_ugn.texi: Document -Wstack-usage.
4455 * gcc-interface/misc.c (enumerate_modes): Add guard for ghost FP modes.
4456
44572011-08-03 Thomas Quinot <quinot@adacore.com>
4458
4459 * sem_prag.adb Issue an error (not a warning) when a C++ type does not
4460 have keyword LIMITED.
4461
44622011-08-03 Yannick Moy <moy@adacore.com>
4463
4464 * alfa.adb, alfa.ads, alfa_test.adb: New files.
4465 * ali.adb (Known_ALI_Lines): add 'C' lines (SCO) and 'F' lines (ALFA)
4466 (Scan_ALI): do not issue a fatal error if parsing known lines after Xref
4467 section (does not happen in compiler, only if code directly calls
4468 Scan_ALI).
4469 * get_alfa.adb, get_alfa.ads: New files.
4470 * lib-writ.adb, lib-writ.ads (Write_ALI): output ALFA information if
4471 needed.
4472 * lib-xref-alfa.adb: New file.
4473 * lib-xref.adb, lib-xref.ads
4474 (Xref_Entry): redefine information needed in cross-references for ALFA.
4475 Push ALFA treatments in separated local package.
4476 (Enclosing_Subpragram_Or_Package): treat specially subprogram
4477 identifiers. Return entity of package body instead of spec. Return
4478 Empty for a scope with no location.
4479 (Generate_Reference): adapt to new components for ALFA information.
4480 Remove the need for D references on definitions.
4481 (Is_Local_Reference): moved to ALFA local package
4482 (Output_References): extract subfunction as Extract_Source_Name
4483 (Output_Local_References): remove procedure, replaced by filtering of
4484 cross-references in package ALFA and printing in Put_ALFA.
4485 (Write_Entity_Name): remove procedure
4486 * lib.adb, lib.ads (Extract_Source_Name): extract here function to
4487 print exact name of entity as it appears in source file
4488 (Unit_Ref_Table): make type public for use in Lib.Xref.ALFA
4489 * put_alfa.adb, put_alfa.ads: New files.
4490 * xref_lib.adb (Search_Xref): protect read of cross-references against
4491 reading other sections of the ALI file, in gnatxref
4492 (Search): protect read of cross-references against reading other
4493 sections of the ALI file, in gnatfind.
4494 * gcc-interface/Make-lang.in: Update dependencies.
4495
44962011-08-03 Thomas Quinot <quinot@adacore.com>
4497
4498 * sem_ch3.adb: Minor reformatting.
4499
45002011-08-03 Jose Ruiz <ruiz@adacore.com>
4501
4502 * s-inmaop-vxworks.adb (Setup_Interrupt_Mask): Do nothing instead of
4503 raising an exception.
4504
45052011-08-03 Ed Schonberg <schonberg@adacore.com>
4506
4507 * sem_res.adb (Set_String_Literal_Subtype): if index type is an integer
4508 type, always use 1 as the lower bound or string, even if lower bound of
4509 context is not static, to handle properly null strings in a non-static
4510 context.
4511
45122011-08-03 Bob Duff <duff@adacore.com>
4513
4514 * sem_prag.adb (Resolve_Aggregate): An array aggregate with 'others' is
4515 always legal on the right-hand side of an assignment statement; there
4516 is always an applicable index constraint in this case. Therefore, the
4517 check for Pkind = N_Assignment_Statement is now unconditional -- it
4518 doesn't depend on whether Is_Constrained (Typ).
4519
4317e442
AC
45202011-08-03 Robert Dewar <dewar@adacore.com>
4521
4522 * exp_ch5.adb, sem_prag.adb, exp_ch4.adb: Minor reformatting.
4523
45242011-08-03 Ed Schonberg <schonberg@adacore.com>
4525
4526 * sem_ch3.adb (Build_Itype_Reference): do not create an itype reference
4527 for an itype created within a generic unit.
4528
45292011-08-03 Eric Botcazou <ebotcazou@adacore.com>
4530
4531 * gnat_ugn.texi (Switches for gcc): Make it clearer that -fno-inline
4532 suppresses all inlining.
4533
53f29d4f
AC
45342011-08-03 Robert Dewar <dewar@adacore.com>
4535
4536 * sem_ch3.adb, sem_res.adb, exp_ch13.adb, exp_disp.adb,
4537 exp_aggr.adb: Minor reformatting.
4538
45392011-08-03 Thomas Quinot <quinot@adacore.com>
4540
4541 * exp_ch5.adb (Expand_N_Assignment_Statement): Do not force inlining of
4542 tagged assignment when discriminant checks are suppressed. This is
4543 useless and extremely costly in terms of static stack usage.
4544
45452011-08-03 Bob Duff <duff@adacore.com>
4546
4547 * sem_prag.adb (Get_Base_Subprogram): Do not follow Alias for instances
4548 of generics, because this leads to the wrong entity in the wrong scope,
4549 causing (e.g.) pragma Export_Procedure to get an error if the entity is
4550 an instance.
4551 (Process_Interface_Name): Follow Alias for instances of generics, to
4552 correct for the above change.
4553
45542011-08-03 Ed Schonberg <schonberg@adacore.com>
4555
4556 * exp_ch4.adb (Expand_N_Selected_Component): If the discriminant value
4557 is an integer literal it is always safe to replace the reference. In
4558 addition, if the reference appears in the generated code for an object
4559 declaration it is necessary to copy because otherwise the reference
4560 might be to the uninitilized value of the discriminant of the object
4561 itself.
4562
45632011-08-03 Pascal Obry <obry@adacore.com>
4564
4565 * adaint.c (__gnat_is_executable_file_attr): Fix Win32 circuitry when no
4566 ACL used, in this case we want to check for ending .exe, not .exe
4567 anywhere in the path.
4568
45692011-08-03 Sergey Rybin <rybin@adacore.com>
4570
4571 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
4572 the tree structure (semantic decoration of references to record
4573 discriminants).
4574
c0b11850
AC
45752011-08-03 Gary Dismukes <dismukes@adacore.com>
4576
4577 * sem_aggr.adb (Analyze_Array_Aggregate): When checking the discrete
4578 choices of a named array aggregate, bail out when any choices are
4579 marked as Errors_Posted.
4580
45812011-08-03 Ed Schonberg <schonberg@adacore.com>
4582
4583 * exp_ch13.adb (Expand_N_Freeze_Entity): cleanup determination of scope
4584 in which entity is frozen, to handle properly loop variables in
4585 iterators.
4586
45872011-08-03 Ed Schonberg <schonberg@adacore.com>
4588
4589 * sem_res.adb (Set_String_Literal_Subtype): if the lower bound of the
4590 subtype is not static, compute the upper bound using attributes, to
4591 handle properly index types that are not integer types.
4592
45932011-08-03 Bob Duff <duff@adacore.com>
4594
4595 * gnat_rm.texi, gnat_ugn.texi: Fix some dangling URLs.
4596 Update copyright notice.
4597
45982011-08-03 Ed Schonberg <schonberg@adacore.com>
4599
4600 * sem_ch3.adb (Build_Discriminant_Constraints): Only use
4601 Original_Discriminant if within an instance.
4602 * sem_ch4.adb (Analyze_Selected_Component): Ditto.
4603
46042011-08-03 Thomas Quinot <quinot@adacore.com>
4605
4606 * einfo.ads: Minor reformatting.
4607
46082011-08-03 Ed Schonberg <schonberg@adacore.com>
4609
4610 * exp_disp.adb (Check_Premature_Freezing): diagnose the presence of a
4611 composite type with an unfrozen subcomponent, in the profile of a
4612 primitive operation.
4613
5c34e9cd
AC
46142011-08-03 Robert Dewar <dewar@adacore.com>
4615
4616 * sem_util.ads, exp_aggr.adb, exp_ch3.adb: Minor reformatting.
4617
46182011-08-03 Ed Schonberg <schonberg@adacore.com>
4619
4620 * sem_ch3.adb (Analyze_Object_Declaration): if a constant object of an
4621 unconstrained type with discriminants is initialized with an aggregate,
4622 use the constrained subtype of the aggregate as the type of the object,
4623 because it is immutable, and this allows the back-end to generate no
4624 code for the object declaration.
4625
abcd9db2
AC
46262011-08-03 Robert Dewar <dewar@adacore.com>
4627
4628 * exp_ch4.adb (Optimize_Length_Check): Fix bad handling of case where
4629 comparison operand is variable, and turns out to be zero or negative.
4630
46312011-08-03 Javier Miranda <miranda@adacore.com>
4632
4633 * exp_intr.adb
4634 (Expand_Dispatching_Constructor_Call): Disable expansion of
4635 code required for native targets. Done to avoid generating
4636 references to unavailable runtime entities in VM targets.
4637 * exp_ch3.adb
4638 (Expand_N_Object_Declaration): Add missing support to handle
4639 the explicit initialization of class-wide interface objects.
4640 Fix documentation.
4641
46422011-08-03 Matthew Heaney <heaney@adacore.com>
4643
4644 * a-cobove.adb (Merge): Move source onto target, instead of using Assign
4645
46462011-08-03 Matthew Heaney <heaney@adacore.com>
4647
4648 * a-cbdlli.adb (Splice): move source items from first to last
4649
46502011-08-03 Yannick Moy <moy@adacore.com>
4651
4652 * sem_util.ads: comment added.
4653
46542011-08-03 Javier Miranda <miranda@adacore.com>
4655
4656 * exp_aggr.adb
4657 (Expand_Record_Aggregate): In VM targets disable the expansion into
4658 assignments of aggregates whose type is not known at compile time.
4659
b474d6c3
ES
46602011-08-03 Ed Schonberg <schonberg@adacore.com>
4661
4662 * exp_ch9.adb (Build_Renamed_Formal_Declaration): common procedure for
4663 protected entries and task entries, to build the proper renaming
4664 declaration for entry formals, used in debugging.
4665 * exp_ch2.adb (Expand_Entry_Parameter): handle task and entry
4666 parameters in the same way.
4667
0580d807
AC
46682011-08-02 Robert Dewar <dewar@adacore.com>
4669
4670 * a-direct.adb, sinfo.ads, exp_ch9.adb, scng.adb, sem_util.adb,
4671 sem_util.ads, restrict.ads, par-prag.adb: Minor reformatting and/or
4672 code reorganization.
4673
46742011-08-02 Robert Dewar <dewar@adacore.com>
4675
4676 * debug.adb: Debug flag d.P to suppress length comparison optimization
4677 * exp_ch4.adb (Optimize_Length_Comparison): New routine to optimize
4678 comparison of Length by comparing First/Last instead.
4679
46802011-08-02 Matthew Heaney <heaney@adacore.com>
4681
4682 * a-cobove.ads: Code clean up.
4683
b191a125
AC
46842011-08-02 Vincent Celier <celier@adacore.com>
4685
4686 * adaint.c (file_names_case_sensitive_cache): New static int.
4687 (__gnat_get_file_names_case_sensitive): Cache the return value in
4688 file_names_case_sensitive_cache at the first invocation, to avoid
4689 multiple calls to getenv.
4690
46912011-08-02 Bob Duff <duff@adacore.com>
4692
4693 * sem_ch12.adb (Validate_Derived_Type_Instance): Implement AI05-0218-1.
4694
316a0661
AC
46952011-08-02 Yannick Moy <moy@adacore.com>
4696
4697 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_prag.adb, sem.ads,
4698 sem_util.adb, sem_util.ads, sem_res.adb, sem_ch2.adb, sem_ch4.adb,
4699 sem_ch6.adb, sem_ch11.adb: Add semantic flag In_Pre_Post_Expression to
4700 indicate that we are in a precondition or postcondition. This is used in
4701 Mark_Non_ALFA_Subprogram (renaming of Mark_Non_ALFA_Subprogram_Body) to
4702 decide whether to flag the spec or body of the current subprogram as
4703 not in ALFA.
4704
47052011-08-02 Fabien Chouteau <chouteau@adacore.com>
4706
4707 * impunit.adb: Add Ada.Execution_Time.Interrupts in the Ada2012 package
4708 list.
4709 * a-extiin.ads: New file.
4710
47112011-08-02 Bob Duff <duff@adacore.com>
4712
4713 * a-direct.adb (Rename): Implement AI05-0231-1. In particular, Rename
4714 now raises Name_Error instead of Use_Error in certain cases. The other
4715 parts of this AI were already implemented properly.
4716
f9adb9d4
AC
47172011-08-02 Vincent Celier <celier@adacore.com>
4718
4719 * link.c: Only import "auto-host.h" when building the gnattools.
4720
47212011-08-02 Yannick Moy <moy@adacore.com>
4722
4723 * sem_util.adb: Inter-unit inlining does not work for a subprogram
4724 which calls a local subprogram, so extract subprogram
4725 from Mark_Non_ALFA_Subprogram_Body.
4726
47272011-08-02 Javier Miranda <miranda@adacore.com>
4728
4729 * exp_ch9.adb
4730 (Extract_Dispatching_Call): If the type of the dispatching object is an
4731 access type then return an explicit dereference in the Object out-mode
4732 parameter.
4733
47342011-08-02 Gary Dismukes <dismukes@adacore.com>
4735
4736 * sem_ch3.adb (Analyze_Subtype_Declaration): Generate range
4737 compatibility checks for all indexes of an array subtype, not just the
4738 first. Reset Has_Dynamic_Range_Check on the subtype before each
4739 potential check to ensure that Insert_Range_Checks will not elide any
4740 of the dynamic checks.
4741
47422011-08-02 Yannick Moy <moy@adacore.com>
4743
4744 * par-prag.ad (Process_Restrictions_Or_Restriction_Warnings): recognize
4745 SPARK restriction at parsing time.
4746 * scng.adb (Scan): Generate a token Tok_SPARK_Hide for a SPARK HIDE
4747 directive only if the SPARK restriction is set for this unit.
4748
83f33150
YM
47492011-08-02 Yannick Moy <moy@adacore.com>
4750
4751 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb, sem_util.ads,
4752 sem_res.adb, sem_ch2.adb, sem_ch4.adb, sem_ch6.adb,
4753 sem_ch11.adb: Protect call to Current_Subprogram which might be costly
4754 when repeated. Rename Current_Subprogram_Is_Not_In_ALFA into
4755 Mark_Non_ALFA_Subprogram_Body.
4756 Split body of Mark_Non_ALFA_Subprogram_Body to get body small and
4757 inlined.
4758
7b98672f
YM
47592011-08-02 Yannick Moy <moy@adacore.com>
4760
4761 * sem_res.adb: Protect calls to Matching_Static_Array_Bounds which
4762 might be costly.
4763
052e0603
AC
47642011-08-02 Robert Dewar <dewar@adacore.com>
4765
4766 * exp_ch9.adb, exp_sel.adb, restrict.ads, exp_disp.adb, erroutc.ads,
4767 exp_ch3.adb: Minor reformatting.
4768
47692011-08-02 Emmanuel Briot <briot@adacore.com>
4770
4771 * adaint.c (__gnat_locate_exec_on_path): only returns executable
4772 files, not any regular file.
4773 (__gnat_locate_file_with_predicate): new subprogram.
4774
47752011-08-02 Yannick Moy <moy@adacore.com>
4776
4777 * sinfo.adb, sinfo.ads: Restrict the use of flags
4778 Has_Dynamic_Length_Check and Has_Dynamic_Range_Check to expression
4779 nodes, plus N_Subtype_Declaration for the 2nd one.
4780
4fbad0ba
AC
47812011-08-02 Sergey Rybin <rybin@adacore.com>
4782
4783 * gnat_rm.texi: Ramification of pragma Eliminate documentation
4784 - fix bugs in the description of Source_Trace;
4785 - get rid of UNIT_NAME;
4786
052e0603
AC
47872011-08-02 Javier Miranda <miranda@adacore.com>
4788
4789 * exp_ch9.adb
4790 (Build_Dispatching_Requeue): Adding support for VM targets
4791 since we cannot directly reference the Tag entity.
4792 * exp_sel.adb (Build_K): Adding support for VM targets.
4793 (Build_S_Assignment): Adding support for VM targets.
4794 * exp_disp.adb
4795 (Default_Prim_Op_Position): In VM targets do not restrict availability
4796 of predefined interface primitives to compiling in Ada 2005 mode.
4797 (Is_Predefined_Interface_Primitive): In VM targets this service is not
4798 restricted to compiling in Ada 2005 mode.
4799 (Make_VM_TSD): Generate code that declares and initializes the OSD
4800 record. Needed to support dispatching calls through synchronized
4801 interfaces.
4802 * exp_ch3.adb
4803 (Make_Predefined_Primitive_Specs): Enable generation of predefined
4804 primitives associated with synchronized interfaces.
4805 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
4806 primitives associated with synchronized interfaces.
4807
48082011-08-02 Yannick Moy <moy@adacore.com>
4809
4810 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
4811 statements hidden in SPARK if preceded by the HIDE directive
4812 (Parse_Exception_Handlers): mark each exception handler in a sequence of
4813 exception handlers as hidden in SPARK if preceded by the HIDE directive
4814 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
4815 if starting with the HIDE directive
4816 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
4817 starting with the HIDE directive; mark the declarations in a private
4818 part as hidden in SPARK if the private part starts with the HIDE
4819 directive
4820 * restrict.adb, restrict.ads
4821 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
4822 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
4823 argument node belongs to a part which is hidden in SPARK
4824 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
4825 parts in SPARK; protect the possibly costly call to
4826 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
4827 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
4828 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
4829 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
4830 Tok_SPARK_Hide.
4831 (Scan): recognize special comment starting with '#' and followed by
4832 SPARK keyword "hide" as a HIDE directive.
4833
48342011-08-02 Yannick Moy <moy@adacore.com>
4835
4836 * types.ads, erroutc.ads: Minor reformatting.
4837
48382011-08-02 Vincent Celier <celier@adacore.com>
4839
4840 * link.c: Add response file support for cross platforms.
4841
48422011-08-02 Ed Schonberg <schonberg@adacore.com>
4843
4844 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
4845 in an association, set parent field of copy before partial analysis.
4846 * sem_res.adb (Resolve_Slice): create reference to itype only when
4847 expansion is enabled.
4848
48492011-08-02 Yannick Moy <moy@adacore.com>
4850
4851 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
4852 for new flag denoting which subprogram bodies are in ALFA
4853 * restrict.adb, sem_ch7.adb: Update comment
4854 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
4855 sem_ch9.adb, sem_res.adb: Add calls to
4856 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
4857 * sem_ch6.adb (Analyze_Function_Return): add calls to
4858 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
4859 middle of the body, and extended return.
4860 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
4861 False when missing return.
4862 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
4863 to True for subprograms whose spec is in ALFA. Remove later on the flag
4864 on the entity used for a subprogram body when there exists a separate
4865 declaration.
4866 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
4867 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
4868 False, otherwise do nothing.
4869
48702011-08-02 Robert Dewar <dewar@adacore.com>
4871
4872 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
4873
48742011-08-02 Yannick Moy <moy@adacore.com>
4875
4876 * sem_ch4.ads: minor formatting.
4877
48782011-08-02 Yannick Moy <moy@adacore.com>
4879
4880 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
4881 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
4882 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
4883 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
4884 opt.ads: cleanup of SPARK mode
4885
48862011-08-02 Yannick Moy <moy@adacore.com>
4887
4888 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
4889 types.
4890 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
4891 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
4892 * sem_ch3.adb
4893 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
4894 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
4895 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
4896 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
4897 types.
4898 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
4899 non-static range.
4900 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
4901 functions whose return type is not in ALFA.
4902 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
4903 specifications.
4904 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
4905 parameter's type is not in ALFA.
4906 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
4907 types are in ALFA.
4908
49092011-08-02 Ed Schonberg <schonberg@adacore.com>
4910
4911 * sem_ch6 (Analyze_Expression_Function): treat the function as
4912 Inline_Always, and introduce a subprogram declaration for it when it is
4913 not a completion.
4914 * inline.adb (Add_Inlined_Body): recognize bodies that come from
4915 expression functions, so that the back-end can determine whether they
4916 can in fact be inlined.
4917 * sem_util.adb (Is_Expression_Function): predicate to determine whether
4918 a function body comes from an expression function.
4919
49202011-08-02 Gary Dismukes <dismukes@adacore.com>
4921
4922 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
4923 null exclusions to test Can_Never_Be_Null on the anonymous access types
4924 of the formals rather than testing the formals themselves. Exclude this
4925 check in cases where the Old_Formal is marked as a controlling formal,
4926 to avoid issuing spurious errors for bodies completing dispatching
4927 operations (due to the flag not getting set on controlling access
4928 formals in body specs).
4929 (Find_Corresponding_Spec): When checking full and subtype conformance of
4930 subprogram bodies in instances, pass Designated and E in that order, for
4931 consistency with the expected order of the formals (New_Id followed by
4932 Old_Id).
4933
49342011-08-02 Robert Dewar <dewar@adacore.com>
4935
4936 * sem_ch8.adb: Minor reformatting.
4937
49382011-08-02 Ed Schonberg <schonberg@adacore.com>
4939
4940 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
4941 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
4942 primitive operations of class-wide actuals.
4943
49442011-08-02 Javier Miranda <miranda@adacore.com>
4945
4946 * exp_atag.ads, exp_atag.adb
4947 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
4948 since its value is implicitly passed in argument Typ.
4949 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
4950 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
4951 Build_Common_Dispatching_Select_Statements.
4952
49532011-08-02 Robert Dewar <dewar@adacore.com>
4954
4955 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
4956 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
4957 Minor reformatting.
4958
49592011-08-02 Robert Dewar <dewar@adacore.com>
4960
4961 * sem_res.adb: Minor reformatting.
4962 * sem_prag.adb: Minor reformatting.
4963
49642011-08-02 Javier Miranda <miranda@adacore.com>
4965
4966 * exp_atag.adb, exp_atags.ads
4967 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
4968 by the tagged type Entity. Required to use this routine in the VM
4969 targets since we do not have available the Tag entity in the VM
4970 platforms.
4971 * exp_ch6.adb
4972 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
4973 Ada.Tags has not been previously loaded.
4974 * exp_ch7.adb
4975 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
4976 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
4977 * sem_aux.adb
4978 (Enclosing_Dynamic_Scope): Add missing support to handle the full
4979 view of enclosing scopes. Required to handle enclosing scopes that
4980 are synchronized types whose full view is a task type.
4981 * exp_disp.adb
4982 (Build_VM_TSDs): Minor code improvement to avoid generating and
4983 analyzing lists with empty nodes.
4984 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
4985 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
4986 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
4987 (Make_Disp_Timed_Select_Body): Add support for VM targets.
4988 (Make_Select_Specific_Data_Table): Add support for VM targets.
4989 (Make_VM_TSD): Generate code to initialize the SSD structure of
4990 the TSD.
4991
49922011-08-02 Yannick Moy <moy@adacore.com>
4993
4994 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
4995 cross-references section in ALI.
4996 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
4997 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
4998 Sub).
4999 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
5000 subprogram or package entity of a node
5001 (Is_Local_Reference_Type): new function returns True for references
5002 selected in local cross-references.
5003 (Lt): function extracted from Lt in Output_References
5004 (Write_Entity_Name): function extracted from Output_References
5005 (Generate_Definition): generate reference with type 'D' for definition
5006 of objects (object declaration and parameter specification), with
5007 appropriate locations and units, for use in local cross-references.
5008 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
5009 references of type 'I' for initialization in object definition.
5010 (Output_References): move part of function Lt and procedure
5011 Write_Entity_Name outside of the body. Ignore references of types 'D'
5012 and 'I' introduced for local cross-references.
5013 (Output_Local_References): new procedure to output the local
5014 cross-references sections.
5015 (Lref_Entity_Status): new array defining whether an entity is a local
5016 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
5017 with 'I' type when initialization expression is present.
5018 * get_scos.adb, get_scos.ads: Correct comments and typos
5019
50202011-08-02 Javier Miranda <miranda@adacore.com>
5021
5022 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
5023 the JVM target.
5024 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
5025 the JVM target.
5026 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
5027 TSD support.
5028
50292011-08-02 Vincent Celier <celier@adacore.com>
5030
5031 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
5032 (No_Space_Img): New function
5033 (Find_Excluded_Sources): When reading from a file, record the file name
5034 and the line number for each excluded source.
5035 (Mark_Excluded_Sources): When reporting an error, if the excluded
5036 sources were read from a file, include file name and line number in
5037 the error message.
5038
50392011-08-02 Ed Schonberg <schonberg@adacore.com>
5040
5041 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
5042
50432011-08-02 Robert Dewar <dewar@adacore.com>
5044
5045 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
5046
50472011-08-02 Javier Miranda <miranda@adacore.com>
5048
5049 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
5050 generation of TSDs to the DOTNET compiler.
5051 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
5052 generation of TSDs to the DOTNET compiler.
5053
50542011-08-02 Javier Miranda <miranda@adacore.com>
5055
5056 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
5057 record of all the tagged types declared inside library level package
5058 declarations, library level package bodies or library level subprograms.
5059 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
5060 associated with a given tagged type.
5061 (Build_VM_TSDs): New subprogram.
5062 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
5063 compilation units that are subprograms.
5064 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
5065 compilation units that are package bodies.
5066 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
5067 units that are a package declaration or a package instantiation.
5068 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
5069 reorganization to improve the error generated by the frontend when the
5070 function Ada.Tags.Secondary_Tag is not available.
5071 * rtsfind.ads (RE_Register_TSD): New runtime entity.
5072 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
5073
50742011-08-02 Javier Miranda <miranda@adacore.com>
5075
5076 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
5077
50782011-08-02 Robert Dewar <dewar@adacore.com>
5079
5080 * s-imenne.ads: Minor reformatting.
5081
50822011-08-02 Robert Dewar <dewar@adacore.com>
5083
5084 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
5085 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
5086 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
5087
50882011-08-02 Robert Dewar <dewar@adacore.com>
5089
5090 * einfo.ads (Materialize_Entity): Document this is only for renamings
5091 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
5092 required debug information in the case where we transform the object
5093 declaration into a renaming declaration.
5094 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
5095 object
5096 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
5097 Materialize_Entity.
5098
50992011-08-02 Robert Dewar <dewar@adacore.com>
5100
5101 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
5102 Suppress_Init_Procs.
5103 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
5104 Suppress_Initialization/Initialization_Suppressed.
5105 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
5106 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
5107 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
5108 * sem_prag.adb: New processing for pragma Suppress_Initialization.
5109
51102011-08-02 Robert Dewar <dewar@adacore.com>
5111
5112 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
5113 Minor reformatting.
5114
51152011-08-02 Ed Schonberg <schonberg@adacore.com>
5116
5117 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
5118 only have inheritable classwide pre/postconditions.
5119
51202011-08-02 Javier Miranda <miranda@adacore.com>
5121
5122 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
5123 * rtsfind.ads (RE_Check_TSD): New runtime entity.
5124 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
5125 checks if the external tag of a type is the same as the external tag
5126 of some other declaration.
5127
51282011-08-02 Thomas Quinot <quinot@adacore.com>
5129
5130 * s-taskin.ads: Minor reformatting.
5131
51322011-08-02 Emmanuel Briot <briot@adacore.com>
5133
5134 * g-comlin.adb (Display_Help): swap the order in which it prints the
5135 short help and the general usage.
5136
51372011-08-02 Ed Schonberg <schonberg@adacore.com>
5138
5139 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
5140 the aspect declarations and attach them to the generic copy for
5141 subsequent analysis.
5142 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
5143 declarations of the generic tree to the new subprogram declarations.
5144 * sem_attr.adb (Check_Precondition_Postcondition): recognize
5145 conditions that apply to a subprogram instance.
5146
51472011-08-02 Robert Dewar <dewar@adacore.com>
5148
5149 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
5150
51512011-08-02 Ed Schonberg <schonberg@adacore.com>
5152
5153 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
5154 private type with a tagged full view is not derived in the immediate
5155 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
5156
51572011-08-02 Robert Dewar <dewar@adacore.com>
5158
5159 * exp_ch4.adb: Minor reformatting.
5160
51612011-08-02 Ed Schonberg <schonberg@adacore.com>
5162
5163 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
5164 Ada2012 iterator, the loop will be rewritten during expansion into a
5165 while loop with a cursor and an element declaration. Do not analyze the
5166 body in this case, because if the container is for indefinite types the
5167 actual subtype of the elements will only be determined when the cursor
5168 declaration is analyzed.
5169
51702011-08-02 Arnaud Charlet <charlet@adacore.com>
5171
5172 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
5173 size/alignment related attributes in CodePeer_Mode.
5174
51752011-08-02 Gary Dismukes <dismukes@adacore.com>
5176
5177 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
5178 Prepend_Element, since this can result in the operation getting the
5179 wrong slot in the full type's dispatch table if the full type has
5180 inherited operations. The incomplete type's operation will get added
5181 to the proper position in the full type's primitives
5182 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
5183 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
5184 dispatching operations, since there are cases where nonprimitive
5185 subprograms can get added to the list of incomplete dependents (such
5186 as subprograms in nested packages).
5187 * sem_ch6.adb (Process_Formals): First, remove test for being in a
5188 private part when determining whether to add a primitive with a
5189 parameter of a tagged incomplete type to the Private_Dependents list.
5190 Such primitives can also occur in the visible part, and should not have
5191 been excluded from being private dependents.
5192 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
5193 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
5194 list of a Taft-amendment incomplete type is a primitive before issuing
5195 an error that the full type must appear in the same unit. There are
5196 cases where nonprimitives can be in the list (such as subprograms in
5197 nested packages).
5198 * sem_disp.adb (Derives_From): Use correct condition for checking that
5199 a formal's type is derived from the type of the corresponding formal in
5200 the parent subprogram (the condition was completely wrong). Add
5201 checking that was missing for controlling result types being derived
5202 from the result type of the parent operation.
5203
52042011-08-02 Yannick Moy <moy@adacore.com>
5205
5206 * errout.adb (First_Node): minor renaming
5207 * restrict.adb (Check_Formal_Restriction): put restriction warning on
5208 first node.
5209
52102011-08-02 Yannick Moy <moy@adacore.com>
5211
5212 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
5213 before accessing operands.
5214 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
5215 decide whether an initialization expression respects SPARK rules, as
5216 the plain node is the expanded one. This allows for more valid warnings
5217 to be issued.
5218 * gnat_rm.texi: Minor update.
5219
52202011-08-02 Arnaud Charlet <charlet@adacore.com>
5221
5222 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
5223 previous change.
5224
52252011-08-02 Robert Dewar <dewar@adacore.com>
5226
5227 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
5228
52292011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
5230
5231 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
5232 loop statements and the element renaming declaration with a block when
5233 the element type is controlled.
5234
52352011-08-02 Yannick Moy <moy@adacore.com>
5236
5237 * sinfo.ads: Minor formatting.
5238
52392011-08-02 Ed Schonberg <schonberg@adacore.com>
5240
5241 * sem_aggr.adb (Add_Association): if the association has a box and no
5242 expression, use the Sloc of the aggregate itself for the new
5243 association.
5244 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
5245 the Original_Node.
5246
52472011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
5248
5249 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
5250 When a container is provided via a function call, generate a renaming
5251 of the function result. This avoids the creation of a transient scope
5252 and the premature finalization of the container.
5253 * exp_ch7.adb (Is_Container_Cursor): Removed.
5254 (Wrap_Transient_Declaration): Remove the supression of the finalization
5255 of the list controller when the declaration denotes a container cursor,
5256 it is not needed.
5257
52582011-08-02 Yannick Moy <moy@adacore.com>
5259
5260 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
5261 node is from source, instead of the original node being from source.
5262 * sem_aggr.adb
5263 (Resolve_Array_Aggregate): refine the check for a static expression, to
5264 recognize also static ranges
5265 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
5266 Array_Type_Declaration): postpone the test for the type being a subtype
5267 mark after the type has been resolved, so that component-selection and
5268 expanded-name are discriminated.
5269 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
5270 to distinguish the case of an iteration scheme, so that an error is
5271 issed on a non-static range in SPARK except in an iteration scheme.
5272 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
5273 In_Iter_Schm = True.
5274 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
5275 user-defined operators so that they are allowed in renaming
5276 * sem_ch8.adb
5277 (Find_Selected_Component): refine the check for prefixing of operators
5278 so that they are allowed in renaming. Move the checks for restrictions
5279 on selector name after analysis discriminated between
5280 component-selection and expanded-name.
5281 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
5282 concatenation argument of string type if it is static.
5283 * sem_util.adb, sem_util.ads
5284 (Check_Later_Vs_Basic_Declarations): add a new function
5285 Is_Later_Declarative_Item to decice which declarations are allowed as
5286 later items, in the two different modes Ada 83 and SPARK. In the SPARK
5287 mode, add that renamings are considered as later items.
5288 (Enclosing_Package): new function to return the enclosing package
5289 (Enter_Name): correct the rule for homonyms in SPARK
5290 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
5291 from source (result of expansion) to avoid issuing wrong warnings.
5292
52932011-08-02 Ed Schonberg <schonberg@adacore.com>
5294
5295 * errout.adb: On anything but an expression First_Node returns its
5296 argument.
5297
52982011-08-02 Pascal Obry <obry@adacore.com>
5299
5300 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
5301
53022011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
5303
5304 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
5305 Set the associated loop as the related expression of internally
5306 generated cursors.
5307 * exp_ch7.adb (Is_Container_Cursor): New routine.
5308 (Wrap_Transient_Declaration): Supress the finalization of the list
5309 controller when the declaration denotes a container cursor.
5310
53112011-08-02 Yannick Moy <moy@adacore.com>
5312
5313 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
5314 command line now.
5315 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
5316 expression is a simple expression. This check cannot be performed in
5317 the semantics, so just drop it.
5318 (P_Index_Or_Discriminant_Constraint): move check that the index or
5319 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
5320 semantics. Other cases were previously checked in the semantics.
5321 * par-ch4.adb (P_Name): move checks that a selector name is not
5322 character literal or an operator symbol to Find_Selected_Component in
5323 the semantics
5324 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
5325 declarations are not placed after later declarations in a separate
5326 procedure in Sem_Util (possibly not the best choice?), to be used both
5327 during parsing, for Ada 83 mode, and during semantic analysis, for
5328 SPARK mode.
5329 * par-endh.adb (Check_End): move check that end label is not missing
5330 to Process_End_Label in the semantics
5331 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
5332 the special case for SPARK restriction
5333 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
5334 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
5335 parameter Force to issue the error message even on internal node (used
5336 for generated end label). Call Check_Restriction to check when an error
5337 must be issued. In SPARK mode, issue an error message even if the
5338 restriction is not set.
5339 (Check_Restriction): new procedure with an additional out parameter to
5340 inform the caller that a message has been issued
5341 * sem_aggr.adb: Minor modification of message
5342 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
5343 instead of issuing an error message directly
5344 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
5345 declarations are not placed after later declarations, by calling
5346 Check_Later_Vs_Basic_Declarations
5347 (Analyze_Subtype_Declaration): move here the check that an index or
5348 discriminant constraint must be a subtype mark. Change the check that
5349 a subtype of String must start at one so that it works on subtype marks.
5350 * sem_ch4.adb (Analyze_Call): move here the check that a named
5351 association cannot follow a positional one in a call
5352 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
5353 instead of issuing an error message directly
5354 * sem_ch8.adb (Find_Selected_Component): move here the check that a
5355 selector name is not a character literal or an operator symbol. Move
5356 here the check that the prefix of an expanded name cannot be a
5357 subprogram or a loop statement.
5358 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
5359 procedure called from parsing and semantics to check that basic
5360 declarations are not placed after later declarations
5361 (Process_End_Label): move here the check that end label is not missing
5362
53632011-08-02 Arnaud Charlet <charlet@adacore.com>
5364
5365 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
5366 representation clause in codepeer mode, since it confuses CodePeer and
5367 does not bring useful info.
5368
53692011-08-02 Ed Falis <falis@adacore.com>
5370
5371 * init.c: initialize fp hw on MILS.
5372
53732011-08-02 Ed Schonberg <schonberg@adacore.com>
5374
5375 * errout.adb (First_Node): for bodies, return the node itself (small
5376 optimization). For other nodes, do not check source_unit if the node
5377 comes from Standard.
5378
53792011-08-02 Robert Dewar <dewar@adacore.com>
5380
5381 * exp_ch3.adb: Minor comment additions.
5382 * sem_ch13.adb: Minor reformatting.
5383
53842011-08-02 Pascal Obry <obry@adacore.com>
5385
5386 * make.adb, makeutl.adb: Removes some superfluous directory separator.
5387
53882011-08-02 Robert Dewar <dewar@adacore.com>
5389
5390 * sem_attr.adb: Minor reformatting.
5391
53922011-08-02 Robert Dewar <dewar@adacore.com>
5393
5394 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
5395 (Has_Default_Component_Value): Removed
5396 * einfo.ads Comment updates
5397 (Has_Default_Aspect): Replaces Has_Default_Value
5398 (Has_Default_Component_Value): Removed
5399 * exp_ch13.adb
5400 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
5401 * exp_ch3.adb
5402 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
5403 (Get_Simple_Init_Val): Handle Default_Value aspect
5404 (Needs_Simple_Initialization): Handle Default_Value aspect
5405 * exp_ch3.ads: Needs_Simple_Initialization
5406 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
5407 * par-prag.adb (Pragma_Default[_Component]Value) Removed
5408 * sem_ch13.adb
5409 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
5410 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
5411 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
5412
54132011-08-02 Ed Schonberg <schonberg@adacore.com>
5414
5415 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
5416 package containing iteration primitives.
5417 exp_ch5.adb (Expand_Iterator_Loop): ditto.
5418
54192011-08-02 Ed Schonberg <schonberg@adacore.com>
5420
5421 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
5422 "of", pre-analyze expression in case it is a function call with
5423 finalization actions that must be placed ahead of the loop.
5424 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
5425 on an Ada2012 iterator, insert them ahead of the rewritten loop.
5426
54272011-08-02 Geert Bosch <bosch@adacore.com>
5428
5429 * cstand.adb (Create_Float_Types): Only consider C's long double for
5430 Long_Long_Float, in addition to double.
5431
54322011-08-02 Robert Dewar <dewar@adacore.com>
5433
5434 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
5435 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
5436 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
5437 Minor reformatting.
5438
54392011-08-02 Ed Schonberg <schonberg@adacore.com>
5440
5441 * sem_attr.adb: handle properly 'Result when it is a prefix of an
5442 indexed component.
5443
54442011-08-02 Javier Miranda <miranda@adacore.com>
5445
5446 * einfo.ads, einfo.adb
5447 (Original_Access_Type): Move this attribute to Node26 since there was
5448 an undocumented use of Node21 in E_Access_Subprogram_Type entities
5449 which causes conflicts and breaks the generation of the .NET compiler.
5450 (Interface_Name): Add missing documentation on JGNAT only uses of
5451 this attribute.
5452
54532011-08-02 Geert Bosch <bosch@adacore.com>
5454
5455 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
5456 (Find_Back_End_Float_Type): Likewise
5457 (Create_Back_End_Float_Types): Likewise
5458 (Create_Float_Types): Likewise
5459 (Register_Float_Type): Likewise
5460 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
5461 Nlist and split out type selection in new local Find_Base_Type function.
5462 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
5463 Nlist
5464 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
5465
54662011-08-02 Robert Dewar <dewar@adacore.com>
5467
5468 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
5469 alpha order).
5470 * opt.ads: Minor comment change.
5471 * sem_ch12.adb: Minor code reorganization.
5472
54732011-08-02 Gary Dismukes <dismukes@adacore.com>
5474
5475 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
5476 subtype's list of rep items to the list on the full subtype in the case
5477 where the lists are the same.
5478
54792011-08-02 Geert Bosch <bosch@adacore.com>
5480
5481 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
5482 using the one from System.Strings, which also deallocates all strings.
5483
54842011-08-02 Geert Bosch <bosch@adacore.com>
5485
5486 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
5487 function.
5488 * gcc-interface/Make-lang.in: Update dependencies.
5489
54902011-08-02 Olivier Hainque <hainque@adacore.com>
5491
5492 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
5493 end_locus.
5494
54952011-08-02 Javier Miranda <miranda@adacore.com>
5496
5497 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
5498 associated with anonymous access to subprograms.
5499
55002011-08-02 Geert Bosch <bosch@adacore.com>
5501
5502 * opt.ads
5503 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
5504 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
5505 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
5506 (Add_Symbol_Definition): Move to switch-c.adb
5507 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
5508 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
5509 (Add_Symbol_Definition): Move to switch-c.adb.
5510 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
5511 * sem_warn.adb
5512 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
5513 Move to warnsw.adb.
5514 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
5515 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
5516 Move to warnsw.adb.
5517 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
5518 (Add_Symbol_Definition): Moved from Prepcomp.
5519 * switch-c.ads: Update copyright notice. Use String_List instead of
5520 Argument_List, removing dependency on System.OS_Lib.
5521
55222011-08-02 Yannick Moy <moy@adacore.com>
5523
5524 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
5525 mode on initialization expression which does not respect SPARK
5526 restrictions.
5527 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
5528 if the tree referenced by its argument represents an initialization
5529 expression in SPARK, suitable for initializing an object in an object
5530 declaration.
5531
55322011-08-02 Javier Miranda <miranda@adacore.com>
5533
5534 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
5535 internally generated access to subprogram with its associated protected
5536 subprogram type.
5537 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
5538
55392011-08-02 Geert Bosch <bosch@adacore.com>
5540
5541 * cstand.adb (Register_Float_Type): Print information about type to
5542 register, if the Debug_Flag_Dot_B is set.
5543 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
5544 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
5545 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
5546 with a requested precision of more than Max_Digits digits and no more
5547 than Max_Base_Digits digits, if a range specification is present and the
5548 Predefined_Float_Types list has a suitable type to derive from.
5549 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
5550 case of type completion with pragma Import
5551 * sem_prag.adb
5552 (Process_Import_Predefined_Type): Processing to complete a type
5553 with pragma Import. Currently supports floating point types only.
5554 (Set_Convention_From_Pragma): Do nothing without underlying type.
5555 (Process_Convention): Guard against absence of underlying type,
5556 which may happen when importing incomplete types.
5557 (Process_Import_Or_Interface): Handle case of importing predefined
5558 types. Tweak error message.
5559
55602011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5561
5562 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
5563 functions to previous change. Reorganize code slightly.
5564
55652011-08-02 Geert Bosch <bosch@adacore.com>
5566
5567 * back_end.ads (Register_Type_Proc): New call back procedure type for
5568 allowing the back end to provide information about available types.
5569 (Register_Back_End_Types): New procedure to register back end types.
5570 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
5571 available types.
5572 * cstand.adb (Back_End_Float_Types): New list for floating point types
5573 supported by the back end.
5574 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
5575 (Copy_Float_Type): New procedure to make new copies of predefined types.
5576 (Register_Float_Type): New call back procedure to populate the BEFT list
5577 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
5578 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
5579 (Create_Float_Types): New procedure to create entities for floating
5580 point types predefined in Standard, and put these and any remaining
5581 BEFTs on the Predefined_Float_Types list.
5582 * stand.ads (Predefined_Float_Types): New list for predefined floating
5583 point types that do not have declarations in package Standard.
5584
55852011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5586
5587 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
5588 entity node for the unit containing the parameter.
5589 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
5590 (Add_Inlined_Subprogram): Likewise.
5591 * gcc-interface/Make-lang.in: Update dependencies.
5592
55932011-08-02 Thomas Quinot <quinot@adacore.com>
5594
5595 * s-stusta.adb (Print): Make sure Pos is always initialized to a
5596 suitable value.
5597
55982011-08-02 Geert Bosch <bosch@adacore.com>
5599
5600 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
5601
56022011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5603
5604 * sem_type.adb (Covers): Move trivial case to the top and reuse the
5605 computed value of Base_Type.
5606
56072011-08-02 Yannick Moy <moy@adacore.com>
5608
5609 * restrict.adb (Check_Restriction): issue an error for any use of
5610 class-wide, even if the No_Dispatch restriction is not set.
5611 * sem_aggr.adb: Correct typos in comments and messages in formal mode
5612 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
5613 when completing a private extension, the type named in the private part
5614 is not the same as that named in the visible part.
5615 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
5616 of an inherited primitive operations of a tagged type or type extension
5617 that returns the tagged type.
5618 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
5619 function which returns True for an implicit operation inherited by the
5620 derived type declaration for the argument type.
5621 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
5622 order.
5623
56242011-08-02 Ed Schonberg <schonberg@adacore.com>
5625
5626 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
5627 Process_Bounds, to perform analysis with expansion of a range or an
5628 expression that is the iteration scheme for a loop.
5629 (Analyze_Iterator_Specification): If domain of iteration is given by a
5630 function call with a controlled result, as is the case if call returns
5631 a predefined container, ensure that finalization actions are properly
5632 generated.
5633 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
5634
56352011-08-02 Javier Miranda <miranda@adacore.com>
5636
5637 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
5638 * gcc-interface/Make-lang.in: Update dependencies.
5639
56402011-08-02 Javier Miranda <miranda@adacore.com>
5641
5642 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
5643 determine if the analysis is performed using N or Original_Node (N).
5644 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
5645 functionality of routine Is_Variable avoids code duplication.
5646 * checks.adb (Determine_Range): Handle temporaries generated by
5647 Remove_Side_Effects.
5648
56492011-08-02 Javier Miranda <miranda@adacore.com>
5650
5651 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
5652 expansion of the condition. Required since the previous analysis was
5653 done with expansion disabled (see Resolve_Quantified_Expression) and
5654 hence checks were not inserted and record comparisons have not been
5655 expanded.
5656
56572011-08-02 Ed Falis <falis@adacore.com>
5658
5659 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
5660 Update header.
5661
56622011-08-02 Bob Duff <duff@adacore.com>
5663
5664 * opt.ads: Minor comment fix.
5665
56662011-08-02 Bob Duff <duff@adacore.com>
5667
5668 * sem_ch12.adb (Analyze_Package_Instantiation,
5669 Analyze_Subprogram_Instantiation): Turn off style checking while
5670 analyzing an instance. Whatever style checks that apply to the generic
5671 unit should apply, so it makes no sense to apply them in an instance.
5672 This was causing trouble when compiling an instance of a runtime
5673 unit that violates the -gnatyO switch.
5674 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
5675 one of the two case statements, causing spurious errors.
5676
56772011-08-02 Robert Dewar <dewar@adacore.com>
5678
5679 * uname.adb: Minor reformatting.
5680 * gnatcmd.adb: Minor reformatting.
5681 * exp_attr.adb: Minor reformatting.
5682
56832011-08-02 Ed Schonberg <schonberg@adacore.com>
5684
5685 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
5686 No_Dispatching_Calls, do not look for the Assign primitive, because
5687 predefined primitives are not created in this case.
5688
56892011-08-02 Bob Duff <duff@adacore.com>
5690
5691 * stylesw.ads: Minor comment fixes.
5692
56932011-08-02 Robert Dewar <dewar@adacore.com>
5694
5695 * freeze.adb (Add_To_Result): New procedure.
5696
56972011-08-02 Jose Ruiz <ruiz@adacore.com>
5698
5699 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
5700 time, if the specific run-time routines for handling streams of strings
5701 are not available, use the default mechanism.
5702
57032011-08-02 Arnaud Charlet <charlet@adacore.com>
5704
5705 * s-regpat.ads: Fix typo.
5706
57072011-08-02 Vincent Celier <celier@adacore.com>
5708
5709 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
5710 not null, call it to create the in memory config project file without
5711 parsing an existing default config project file.
5712
57132011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5714
5715 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
5716
57172011-08-02 Ed Schonberg <schonberg@adacore.com>
5718
5719 * sem_elim.adb: an abstract subprogram does not need an eliminate
5720 pragma for its descendant to be eliminable.
5721
57222011-08-02 Ed Falis <falis@adacore.com>
5723
5724 * init.c: revert to handling before previous checkin for VxWorks
5725 * s-intman-vxworks.adb: delete unnecessary declarations related to
5726 using Ada interrupt facilities for handling signals.
5727 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
5728 * s-intman-vxworks.ads: Import __gnat_install_handler as
5729 Initialize_Interrupts.
5730 * s-taprop-vxworks.adb: Delete Signal_Mask.
5731 (Abort_Handler): change construction of mask to unblock exception
5732 signals.
5733
57342011-08-02 Jerome Guitton <guitton@adacore.com>
5735
5736 * a-except-2005.adb (Raise_From_Signal_Handler): Call
5737 Debug_Raise_Exception before propagation starts.
5738
57392011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5740
5741 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
5742 to Restriction_Check_Required.
5743 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
5744 * sem_res.adb (Resolve_Call): Likewise.
5745 * sem_attr.adb (Check_Stream_Attribute): Likewise.
5746
57472011-08-02 Bob Duff <duff@adacore.com>
5748
5749 * stylesw.ads: Update comment.
5750 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
5751 * errout.ads: Remove obsolete comment.
5752
57532011-08-02 Javier Miranda <miranda@adacore.com>
5754
5755 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
5756 (Set_Is_Safe_To_Reevaluate): new procedure.
5757 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
5758 assignment is allowed on safe-to-reevaluate variables.
5759 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
5760 temporary created to remove side effects in expressions that use
5761 the secondary stack as safe-to-reevaluate.
5762 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
5763 variables that are not true constants.
5764
57652011-08-02 Robert Dewar <dewar@adacore.com>
5766
5767 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
5768 sem_res.adb, sem_ch6.adb: Minor reformatting.
5769
57702011-08-02 Jerome Guitton <guitton@adacore.com>
5771
5772 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
5773
57742011-08-02 Ed Schonberg <schonberg@adacore.com>
5775
5776 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
5777 not set Overridden_Operation if subprogram is an initialization
5778 procedure.
5779
57802011-08-02 Yannick Moy <moy@adacore.com>
5781
5782 * par-ch6.adb: Correct obsolete name in comments
5783 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
5784 which takes two message arguments (existing function takes one), with
5785 second message used for continuation.
5786 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
5787 block statements that originate from a source block statement, not
5788 generated block statements
5789 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
5790 symmetry with procedure case
5791 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
5792 function to issue an error in formal mode if a package specification
5793 contains more than one tagged type or type extension.
5794 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
5795 parameters matching formals of tagged types are objects (or ancestor
5796 type conversions of objects), not general expressions. Issue an error
5797 on view conversions that are not involving ancestor conversion of an
5798 extended type.
5799 (Resolve_Type_Conversion): in formal mode, issue an error on the
5800 operand of an ancestor type conversion which is not an object
5801 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
5802 procedure so that it works also for actuals of function calls
5803 (Is_Actual_Tagged_Parameter): new function which determines if its
5804 argument is an actual parameter of a formal of tagged type in a
5805 subprogram call
5806 (Is_SPARK_Object_Reference): new function which determines if the tree
5807 referenced by its argument represents an object in SPARK
5808
58092011-08-02 Robert Dewar <dewar@adacore.com>
5810
5811 * sem_ch3.adb: Minor reformatting
5812 Minor comment addition
5813 Minor error msg text change
5814
58152011-08-02 Javier Miranda <miranda@adacore.com>
5816
5817 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
5818 function. Used to be more precise when we generate a variable plus one
5819 assignment to remove side effects in the evaluation of the Bound
5820 expressions.
5821 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
5822 of the bound expression to force its re-analysis and thus expand the
5823 associated transient scope (if required). Code cleanup replacing the
5824 previous code that declared the constant entity by an invocation to
5825 routine Force_Evaluation which centralizes this work in the frontend.
5826
58272011-08-02 Robert Dewar <dewar@adacore.com>
5828
5829 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
5830 (Base_Type): Now uses improved Is_Base_Type function
5831 * einfo.ads (Base_Type): Inline this function
5832
58332011-08-02 Robert Dewar <dewar@adacore.com>
5834
5835 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
5836 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
5837
58382011-08-02 Arnaud Charlet <charlet@adacore.com>
5839
5840 * gcc-interface/Make-lang.in: Update dependencies.
5841 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
5842 targets.
5843
58442011-08-02 Yannick Moy <moy@adacore.com>
5845
5846 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
5847 non-simple expression used in delta constraint
5848 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
5849 index constraint which is not a subtype mark
5850 * par.adb: With and use Restrict
5851 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
5852 mode on component type which is not a subtype mark and default
5853 expression on component
5854 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
5855 of string which does not have a lower index bound equal to 1
5856 (Array_Type_Declaration): issue an error in formal mode on index or
5857 component type which is not a subtype mark, and on aliased keyword on
5858 component
5859 (Derived_Type_Declaration): issue an error in formal mode on interface,
5860 limited or abstract type
5861 (Record_Type_Declaration): issue an error in formal mode on interface
5862 (Record_Type_Definition): issue an error in formal mode on tagged types
5863 and type extensions not declared in the specification of a library unit
5864 package; on null non-tagged record; on variant part
5865
58662011-08-02 Vincent Celier <celier@adacore.com>
5867
5868 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
5869 not declared for qualified library project when Library_Name is not
5870 declared, but Library_Dir is.
5871
58722011-08-02 Robert Dewar <dewar@adacore.com>
5873
5874 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
5875 pragmas (affects aspects [Component_]Default_Value
5876 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
5877 component type for the resolution
5878
58792011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5880
5881 * einfo.adb (Base_Type): Tune implementation for speed.
5882
58832011-08-02 Robert Dewar <dewar@adacore.com>
5884
5885 * freeze.adb: Minor reformatting.
5886
58872011-08-02 Thomas Quinot <quinot@adacore.com>
5888
5889 * scos.ads: Update comments.
5890
58912011-08-02 Ed Schonberg <schonberg@adacore.com>
5892
5893 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
5894 base type, because the parent may be a subtype of a private type whose
5895 convention is established in a private part.
5896
58972011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
5898
5899 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
5900 statement in a block when the expansion of the return expression has
5901 created a finalization chain.
5902 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
5903 with the parent node.
5904 Add N_Extended_Return_Statement to handle the case where a transient
5905 object declaration appears in the Return_Object_Declarations list of
5906 an extended return statement.
5907
59082011-08-02 Matthew Gingell <gingell@adacore.com>
5909
5910 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
5911 unused parameter 'name'.
5912
59132011-08-02 Ed Schonberg <schonberg@adacore.com>
5914
5915 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
5916 inherited operation, check whether its alias, which is the source
5917 operastion that it renames, has been marked eliminated.
5918
59192011-08-02 Javier Miranda <miranda@adacore.com>
5920
5921 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
5922 in-mode parameter whose type is an access type since it can be used to
5923 modify its designated object. Enforce code that handles as safe an
5924 access type that is not access-to-constant but it is the result of a
5925 previous removal of side-effects.
5926 (Remove_Side_Effects): Minor code reorganization of cases which require
5927 no action. Done to incorporate documentation on new cases uncovered
5928 working in this ticket: no action needed if this routine was invoked
5929 too early and the nodes are not yet decorated.
5930 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
5931 to routine Remove_Side_Effects by calls to Force_Evaluation since they
5932 were issued with actuals that are implicitly provided by
5933 Force_Evaluation.
5934
59352011-08-02 Robert Dewar <dewar@adacore.com>
5936
5937 * sem_ch3.adb, sem_res.adb: Minor reformatting.
5938
59392011-08-02 Yannick Moy <moy@adacore.com>
5940
5941 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
5942 to issue an error in formal mode on attribute not supported in this mode
5943 (Analyze_Attribute): issue errors on standard attributes not supported
5944 in formal mode.
5945 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
5946 comment, and issue error in formal mode on modulus which is not a power
5947 of 2.
5948 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
5949 range.
5950 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
5951 subtype mark.
5952 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
5953 operator on modular type (except 'not').
5954
59552011-08-02 Robert Dewar <dewar@adacore.com>
5956
5957 * gnat_rm.texi: Minor reformatting.
5958
59592011-08-02 Arnaud Charlet <charlet@adacore.com>
5960
5961 * s-osinte-linux.ads: Minor comment update and reformatting.
5962 * i-cexten.ads: Make this unit pure, as for its parent.
5963 Will allow its usage in more contexts if needed.
5964
59652011-08-02 Robert Dewar <dewar@adacore.com>
5966
5967 * s-utf_32.ads: Minor comment fix.
5968
59692011-08-02 Ed Schonberg <schonberg@adacore.com>
5970
5971 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
5972 operation of a tagged synchronized type, handle the case where the
5973 controlling argument is overloaded.
5974
59752011-08-02 Yannick Moy <moy@adacore.com>
5976
5977 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
5978 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
5979 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
5980 SPARK mode and formal verification mode on processing SPARK restriction
5981 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
5982 requiring consistency checking.
5983
59842011-08-02 Robert Dewar <dewar@adacore.com>
5985
5986 * sem_res.adb: Minor reformatting.
5987
59882011-08-02 Robert Dewar <dewar@adacore.com>
5989
5990 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
5991 a-cforse.ads: Remove unneeded with of Ada.Containers
5992 Remove commented out pragma Inline's
5993 Move specifications of new subprograms to the actual specs
5994
59952011-08-02 Yannick Moy <moy@adacore.com>
5996
5997 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
5998 a-cforse.ads: Update comments.
5999
60002011-08-02 Ed Schonberg <schonberg@adacore.com>
6001
6002 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
6003
60042011-08-02 Robert Dewar <dewar@adacore.com>
6005
6006 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
6007 a-cforse.ads, a-cofove.ads: Minor reformatting.
6008
60092011-08-02 Claire Dross <dross@adacore.com>
6010
6011 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
6012 a-cofove.ads: Add comments.
6013
60142011-08-02 Yannick Moy <moy@adacore.com>
6015
6016 * gnat_rm.texi: Document formal containers.
6017
60182011-08-02 Emmanuel Briot <briot@adacore.com>
6019
6020 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
6021 are empty sections.
6022
60232011-08-02 Robert Dewar <dewar@adacore.com>
6024
6025 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
6026 reformatting.
6027
60282011-08-02 Robert Dewar <dewar@adacore.com>
6029
6030 * aspects.adb: New aspects Default_Value and Default_Component_Value
6031 New format of Aspect_Names table checks for omitted entries
6032 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
6033 handling of boolean aspects for derived types.
6034 New aspects Default_Value and Default_Component_Value
6035 New format of Aspect_Names table checks for omitted entries
6036 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
6037 (Has_Default_Value): New flag
6038 (Has_Default_Component_Value): New flag
6039 (Has_Default_Value): New flag
6040 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
6041 table.
6042 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
6043 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
6044 Default_Value and Default_Component_Value
6045 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
6046 New aspects Default_Value and Default_Component_Value
6047 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
6048 * sprint.adb: Print N_Aspect_Specification node when called from gdb
6049
60502011-08-02 Vincent Celier <celier@adacore.com>
6051
6052 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
6053 inherit library kind.
6054
60552011-08-02 Ed Schonberg <schonberg@adacore.com>
6056
6057 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
6058 Minor reformatting.
6059
60602011-08-02 Robert Dewar <dewar@adacore.com>
6061
6062 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
6063
60642011-08-02 Yannick Moy <moy@adacore.com>
6065
6066 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
6067
60682011-08-02 Robert Dewar <dewar@adacore.com>
6069
6070 * impunit.adb: Add comment.
6071
60722011-08-02 Yannick Moy <moy@adacore.com>
6073
6074 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
6075 qualification of aggregates in formal mode
6076 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
6077 another aggregate
6078 (Resolve_Aggregate): complete the test that an aggregate is adequately
6079 qualified in formal mode
6080
60812011-08-02 Pascal Obry <obry@adacore.com>
6082
6083 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
6084 * mlib-prj.adb: Supress warning when compiling binder generated file.
6085 (Build_Library): Supress all warnings when compiling the binder
6086 generated file.
6087
60882011-08-02 Yannick Moy <moy@adacore.com>
6089
6090 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
6091 from here...
6092 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
6093 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
6094 Add with/use clauses to make Check_Formal_Restriction visible
6095
60962011-08-02 Ed Schonberg <schonberg@adacore.com>
6097
6098 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
6099 in-parameters when type of the generic formal is private in the generic
6100 spec and non-private in the body.
6101
61022011-08-02 Claire Dross <dross@adacore.com>
6103
6104 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
6105 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
6106 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
6107 * impunit.adb, Makefile.rtl: Take new files into account.
6108
61092011-08-02 Robert Dewar <dewar@adacore.com>
6110
6111 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
6112 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
6113
61142011-08-02 Yannick Moy <moy@adacore.com>
6115
6116 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
6117 formal mode
6118 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
6119 matching static array bounds, taking into account the special case of
6120 string literals
6121 * sem_ch3.adb: Typo in comment.
6122
61232011-08-02 Yannick Moy <moy@adacore.com>
6124
6125 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
6126 which issues an error in formal mode if its argument node is originally
6127 from source
6128 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
6129 has a discriminant specification so that it does not include the case
6130 of derived types
6131 (Derived_Type_Declaration): move here the test that a derived type has a
6132 discriminant specification
6133 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
6134 first element of a component association before accessing its choices
6135 (presence of component association is not enough)
6136 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
6137 declaration is a library item before accessing the next element in a
6138 list, as library items are not member of lists
6139 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
6140 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
6141 Check_Formal_Restriction whenever possible.
6142
61432011-08-02 Ed Schonberg <schonberg@adacore.com>
6144
6145 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
6146 reference when needed.
6147
61482011-08-02 Bob Duff <duff@adacore.com>
6149
6150 * gnat_ugn.texi: Fix typo.
6151
61522011-08-02 Vincent Celier <celier@adacore.com>
6153
6154 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
6155 archive file name. Do not use the full path name of archives for Open
6156 VMS.
6157
61582011-08-02 Robert Dewar <dewar@adacore.com>
6159
6160 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
6161 Analyze_Aspect_Specifications
6162 * sem_ch13.adb
6163 (Analyze_Aspect_Specifications): New handling for boolean aspects
6164 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
6165 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
6166 sequence for Analyze_Aspect_Specifications
6167 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
6168 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
6169
61702011-08-02 Robert Dewar <dewar@adacore.com>
6171
6172 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
6173 aspects, since these no longer exist.
6174
61752011-08-02 Robert Dewar <dewar@adacore.com>
6176
6177 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
6178 semicolon, do not try to see if there are aspects following it.
6179 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
6180 aspect spec.
6181
61822011-08-02 Robert Dewar <dewar@adacore.com>
6183
6184 * sem_ch8.adb, aspects.ads: Minor reformatting.
6185
61862011-08-02 Eric Botcazou <ebotcazou@adacore.com>
6187
6188 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
6189 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
6190 extracted from...
6191 (Analyze_Aspect_Specifications): ...here. Call above procedure.
6192
61932011-08-02 Yannick Moy <moy@adacore.com>
6194
6195 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
6196 mode on subprogram declaration outside of package specification, unless
6197 it is followed by a pragma Import
6198 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
6199 Access_Type_Declaration): issue error in formal mode on access type
6200 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
6201 incomplete type
6202 (Analyze_Object_Declaration): issue error in formal mode on object
6203 declaration which does not respect SPARK restrictions
6204 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
6205 declaration which does not respect SPARK restrictions
6206 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
6207 error in formal mode on digits or delta constraint
6208 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
6209 decimal fixed point type
6210 (Derived_Type_Declaration): issue error in formal mode on derived type
6211 other than type extensions of tagged record types
6212 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
6213 with check on access definition
6214 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
6215 mode on protected definition.
6216 (Analyze_Task_Definition): issue error in formal mode on task definition
6217
62182011-08-02 Robert Dewar <dewar@adacore.com>
6219
6220 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
6221
62222011-08-02 Javier Miranda <miranda@adacore.com>
6223
6224 * sem_ch6.adb (Can_Override_Operator): New function.
6225 (Verify_Overriding_Indicator): Add missing code to check overriding
6226 indicator in operators. Fixes regression.
6227 (Check_Overriding_Indicator): Minor reformating after replacing the
6228 code that evaluates if the subprogram can override an operator by
6229 invocations to the above new function.
6230 * einfo.adb
6231 (Write_Field26_Name): Add missing code to ensure that, following
6232 the documentation in einfo.ads, this field is not shown as attribute
6233 "Static_Initialization" on non-dispatching functions.
6234
62352011-08-02 Jose Ruiz <ruiz@adacore.com>
6236
6237 * sem_res.adb (Resolve_Call): A call to
6238 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
6239 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
6240 i.e., when the second parameter is of type Time_Span.
6241
62422011-08-02 Vincent Celier <celier@adacore.com>
6243
6244 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
6245 with an archive instead of -L<library dir> -l<library name>.
6246
62472011-08-02 Ed Schonberg <schonberg@adacore.com>
6248
6249 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
6250 mark the base types In_Use in addition to making the operations
6251 use_visible.
6252
62532011-08-02 Ed Falis <falis@adacore.com>
6254
6255 * init.c: add and setup __gnat_signal_mask for the exception signals
6256 * s-inmaop-vxworks.adb: new file.
6257 * s-intman-vxworks.adb: remove unnecessary initializations and
6258 simplify remaining
6259 * s-intman-vxworks.ads: remove unnecessary variable
6260 * s-taprop-vxworks.adb: simplify signal initialization
6261
62622011-08-02 Robert Dewar <dewar@adacore.com>
6263
6264 * sem_ch8.adb: Minor code reorganization, comment updates.
6265
62662011-08-02 Robert Dewar <dewar@adacore.com>
6267
6268 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
6269 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
6270 here from Sem_Res.
6271 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
6272 (Matching_Static_Array_Bounds): Moved here from Sem_Res
6273
62742011-08-02 Ed Schonberg <schonberg@adacore.com>
6275
6276 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
6277 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
6278 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
6279 use_type_clauses, to handle more efficiently use_type and use_all_type
6280 constructs.
6281 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
6282 Ada2012 Use_All_Type clause.
6283 (Use_Class_Wide_Operations): new procedure.
6284
62852011-08-02 Robert Dewar <dewar@adacore.com>
6286
6287 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
6288 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
6289 expression to expression function.
6290
62912011-08-02 Ed Schonberg <schonberg@adacore.com>
6292
6293 * sem_ch4.adb: transform simple Ada2012 membership into equality only
6294 if types are compatible.
6295
62962011-08-02 Yannick Moy <moy@adacore.com>
6297
6298 * sem_res.adb (Matching_Static_Array_Bounds): new function which
6299 returns True if its argument array types have same dimension and same
6300 static bounds at each index.
6301 (Resolve_Actuals): issue an error in formal mode on actuals passed as
6302 OUT or IN OUT paramaters which are not view conversions in SPARK.
6303 (Resolve_Arithmetic_Op): issue an error in formal mode on
6304 multiplication or division with operands of fixed point types which are
6305 not qualified or explicitly converted.
6306 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
6307 Boolean or array type (except String) operands.
6308 (Resolve_Equality_Op): issue an error in formal mode on equality
6309 operators for array types other than String with non-matching static
6310 bounds.
6311 (Resolve_Logical_Op): issue an error in formal mode on logical operators
6312 for array types with non-matching static bounds. Factorize the code in
6313 Matching_Static_Array_Bounds.
6314 (Resolve_Qualified_Expression): issue an error in formal mode on
6315 qualified expressions for array types with non-matching static bounds.
6316 (Resolve_Type_Conversion): issue an error in formal mode on type
6317 conversion for array types with non-matching static bounds
6318
63192011-08-02 Robert Dewar <dewar@adacore.com>
6320
6321 * par-ch10.adb: Minor code reorganization (use Nkind_In).
6322
63232011-08-02 Ed Schonberg <schonberg@adacore.com>
6324
6325 * par-ch9.adb: save location of entry for proper error message.
6326
63272011-08-02 Javier Miranda <miranda@adacore.com>
6328
6329 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
6330 (Use_Full_View) which permits this routine to climb through the
6331 ancestors using the full-view of private parents.
6332 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
6333 Use_Full_View to true in calls to Is_Ancestor.
6334 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
6335 true in call to Is_Ancestor.
6336 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
6337 Use_Full_View to true in call to Is_Ancestor.
6338 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
6339 call to Is_Ancestor.
6340 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
6341 Use_Full_View to true in calls to Is_Ancestor.
6342 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
6343 Make_Select_Specific_Data_Table, Register_Primitive,
6344 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
6345 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
6346 to true in call to Is_Ancestor.
6347 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
6348 Use_Full_View to true in calls to Is_Ancestor.
6349 * exp_cg.adb
6350 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
6351 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
6352
63532011-08-02 Robert Dewar <dewar@adacore.com>
6354
6355 * gnat_rm.texi: Minor reformatting.
6356 * sem_prag.adb: Minor reformatting.
6357
63582011-08-02 Tristan Gingold <gingold@adacore.com>
6359
6360 * vms_data.ads: Add VMS qualifier for -gnateP.
6361
63622011-08-02 Robert Dewar <dewar@adacore.com>
6363
6364 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
6365 * par-ch7.adb (P_Package): Proper placement of aspects for package
6366 decl/instantiation.
6367 * par-endh.adb (Check_End): Ad Is_Sloc parameter
6368 (End_Statements): Add Is_Sloc parameterr
6369 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
6370 (Check_End): Ad Is_Sloc parameter
6371 (End_Statements): Add Is_Sloc parameterr
6372
63732011-08-02 Vincent Celier <celier@adacore.com>
6374
6375 * ug_words: Add VMS qualifier equivalent to -gnateP:
6376 /SYMBOL_PREPROCESSING.
6377
63782011-08-02 Jose Ruiz <ruiz@adacore.com>
6379
6380 * gnat-style.texi: For hexadecimal numeric literals the typical
6381 grouping of digits is 4 to represent 2 bytes.
6382 A procedure spec which is split into several lines is indented two
6383 characters.
6384
63852011-08-02 Yannick Moy <moy@adacore.com>
6386
6387 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
6388 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
6389 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
6390 properly qualified
6391 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
6392 choice in array aggregate
6393 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
6394 mark as ancestor
6395 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
6396 positional and named aggregate for record, or others in record
6397 aggregate, or multiple choice in record aggregate
6398 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
6399 array operands to logical operations AND, OR and XOR do not have the
6400 same static lower and higher bounds
6401 * sem_ch5.adb, sinfo.ads: Correct typos in comments
6402
64032011-08-01 Robert Dewar <dewar@adacore.com>
6404
6405 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
6406 Replaces Last_Source_Node_In_Sequence.
6407 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
6408 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
6409 parens and blank in string (this was inconsistently implemented).
6410 * errout.ads
6411 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
6412 blank in string (this was inconsistently implemented).
6413 * gnat1drv.adb
6414 (Set_Global_Switches): Set formal mode switches appropriately
6415 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
6416 * par-prag.adb
6417 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
6418 call Set_Error_Msg_Lang to set "spark" as language name.
6419 * par.adb: Remove unnecessary call to set formal language for errout
6420 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
6421 appropriately and call Set_Error_Msg_Lang to set "spark" as language
6422 name.
6423 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
6424 calls to it, moved after resolution so that types are known
6425 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
6426 result of concatenation is not of type String
6427 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
6428 concatenation is not properly restricted
6429 * gnat_rm.texi: Add doc on pragma Spark_95.
6430 * gcc-interface/Makefile.in: Remove obsolete target pairs for
6431 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
6432 * gcc-interface/Make-lang.in: Update dependencies.
6433
64342011-08-01 Javier Miranda <miranda@adacore.com>
6435
6436 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
6437 condition that detects if the overridden operation must replace an
6438 existing entity.
6439
64402011-08-01 Javier Miranda <miranda@adacore.com>
6441
6442 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
6443 code declarations inserted by Insert_Actions in each alternative of the
6444 N_Case_Expression node.
6445
64462011-08-01 Robert Dewar <dewar@adacore.com>
6447
6448 * sem_ch6.adb: Minor code reorganization.
6449 * sem_util.adb: Minor reformatting.
6450
64512011-08-01 Pascal Obry <obry@adacore.com>
6452
6453 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
6454 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
6455
64562011-08-01 Yannick Moy <moy@adacore.com>
6457
6458 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
6459 literal or operator symbol which is prefixed
6460 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
6461 mode on access attributes.
6462 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
6463 that concatenation operands are properly restricted in formal mode
6464 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
6465 Analyze_Concatenation_Operand. Issue an error in formal mode if the
6466 result of the concatenation has a type different from String.
6467 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
6468 Analyze_Quantified_Expression, Analyze_Slice,
6469 Analyze_Null): issue an error in formal mode on unsupported constructs
6470 * sem_ch5.adb
6471 (Analyze_Block_Statement): only issue error on source block statement
6472 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
6473 function which returns the last node in a list of nodes for which
6474 Comes_From_Source returns True, if any
6475 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
6476 Last_Source_Node_In_Sequence
6477 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
6478 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
6479 mode on unsupported constructs
6480 * sem_ch9.adb Do not return after issuing error in formal mode, as the
6481 rest of the actions may be needed later on since the error is marked as
6482 not serious.
6483 * sinfo.ads: Typos in comments.
6484
64852011-08-01 Pascal Obry <obry@adacore.com>
6486
6487 * projects.texi: Minor editing.
6488
64892011-08-01 Yannick Moy <moy@adacore.com>
6490
6491 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
6492 insertion character ~~
6493 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
6494 (Set_Error_Msg_Lang): new procedure which fixes the language for use
6495 with insertion character ~~
6496 (Set_Msg_Text): treat insertion character ~~
6497 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
6498 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
6499 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
6500 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
6501 errors related to the formal language restriction not serious
6502 (insertion character |).
6503 * par.adb (Par): set formal language for error messages if needed
6504 * sem_ch6.adb (Check_Missing_Return): take into account possible
6505 generated statements at the end of the function
6506 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
6507 enumeration value to define a new pragma SPARK_95
6508 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
6509 SPARK_Version): new type and variables to store the SPARK version
6510 (none by default).
6511 (SPARK_Mode): return True when SPARK_Version is set
6512 * par-prag.adb: Correct indentation
6513 (Prag): take Pragma_SPARK_95 into account
6514 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
6515 into account.
6516
65172011-08-01 Robert Dewar <dewar@adacore.com>
6518
6519 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
6520 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
6521 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
6522
65232011-08-01 Pascal Obry <obry@adacore.com>
6524
6525 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
6526 Target_Name to Get_Path call.
6527 (Parse_Single_Project): Likewise.
6528 (Post_Parse_Context_Clause): Likewise.
6529 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
6530 Call Initialise_Project_Path with the proper Target_Name.
6531 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
6532 search path.
6533 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
6534 with the proper Target_Name.
6535 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
6536 Part.Parse routine.
6537 (Parse_Project_And_Apply_Config): Likewise.
6538 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
6539 This is fine as this part of the code is supporting only native
6540 compilation.
6541 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
6542 is fine as this part of the code is supporting only native compilation.
6543
65442011-08-01 Yannick Moy <moy@adacore.com>
6545
6546 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
6547 of homonym, unless the homonym is one of the cases allowed in SPARK
6548 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
6549 package declaration occurring after a body.
6550
65512011-08-01 Robert Dewar <dewar@adacore.com>
6552
6553 * checks.adb, exp_ch4.adb: Minor reformatting.
6554
65552011-08-01 Javier Miranda <miranda@adacore.com>
6556
6557 * einfo.ads (Access_Disp_Table): Fix documentation.
6558 (Dispatch_Table_Wrappers): Fix documentation.
6559
65602011-08-01 Pascal Obry <obry@adacore.com>
6561
6562 * prj-env.adb, prj-env.ads: Minor reformatting.
6563
65642011-08-01 Yannick Moy <moy@adacore.com>
6565
6566 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
6567 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
6568 procedures out of these packages.
2c7f9cc0 6569 * errout.ads, errout.adb
052e0603
AC
6570 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
6571 procedures in of this package
6572 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
6573 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
6574 on misplaced later vs initial declarations, like in Ada 83
6575 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
6576 formal mode on attribute of private type whose full type declaration
6577 is not visible
6578 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
6579 package declaration inside a package specification
6580 (Analyze_Full_Type_Declaration): issue error in formal mode on
6581 controlled type or discriminant type
6582 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
6583 user-defined operator means that it should come from the source
6584 (New_Overloaded_Entity): issue error in formal mode on overloaded
6585 entity.
6586 * sem_ch6.ads, sem_ch13.ads: typos in comments.
6587
65882011-08-01 Thomas Quinot <quinot@adacore.com>
6589
6590 * atree.adb: Minor reformatting.
6591 * checks.adb: Minor reformatting.
6592
65932011-08-01 Vincent Celier <celier@adacore.com>
6594
6595 * s-parame-vms-ia64.ads: Fix typo in comment
6596 Minor reformatting
6597 * s-parame-vms-restrict.ads: Removed, unused.
6598
65992011-08-01 Javier Miranda <miranda@adacore.com>
6600
6601 * exp_ch3.adb
6602 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
6603 * sem_ch3.adb
6604 (Constrain_Index): Remove side effects in the evaluation of the bounds.
6605 * sem_ch3.ads, sem_ch3.adb
6606 (Is_Constant_Bound): New extended version of the subprogram that was
6607 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
6608 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
6609 * sem_aux.ads (Constant_Value): Fix typo in comment.
6610 * checks.adb (Generate_Index_Checks): New implementation which, for
6611 array objects with constant bounds, generates the runtime check
6612 referencing the bounds of the array type. For other cases this routine
6613 provides its previous behavior obtaining such values from the array
6614 object.
6615 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
6616 parent type.
6617 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
6618 we cannot have semantic interpretations of the new node.
6619
66202011-08-01 Ed Schonberg <schonberg@adacore.com>
6621
6622 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
6623 expressions.
6624
66252011-08-01 Arnaud Charlet <charlet@adacore.com>
6626
6627 * sem_ch8.adb: Minor code editing.
6628 * s-vxwext.adb: Remove trailing space.
6629 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
6630 consistency with other files.
6631
66322011-08-01 Thomas Quinot <quinot@adacore.com>
6633
6634 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
6635
66362011-08-01 Ed Schonberg <schonberg@adacore.com>
6637
6638 * par-ch10.adb: reject parameterized expressions as compilation unit.
6639 * sem_ch4.adb: handle properly conditional expression with overloaded
6640 then_clause and no else_clause.
6641
66422011-08-01 Tristan Gingold <gingold@adacore.com>
6643
6644 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
6645 like done by System.Aux_DEC.
6646 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
6647
66482011-08-01 Yannick Moy <moy@adacore.com>
6649
6650 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
6651 missing label at end of declaration (subprogram or package)
6652 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
6653 of positional and named parameter association
6654 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
6655 Error_Msg_SP which adds a prefix to the error message giving the name
6656 of the formal language analyzed
6657 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
6658 access result type in subprogram, unconstrained array as result type,.
6659 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
6660 procedure
6661 * sem_ch8.adb: Code clean up.
6662
66632011-08-01 Javier Miranda <miranda@adacore.com>
6664
6665 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
6666 * einfo.ads (Access_Disp_Table): Fix documentation.
6667 (Dispatch_Table_Wrappers): Fix documentation.
6668 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
6669 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
6670 to enforce the documentation of this attribute.
6671 (Set_Is_Interface): Cleanup the assertion.
6672 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
6673 the Underlying_Type entity before reading attribute Access_Disp_Table.
6674 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
6675 Locate the Underlying_Type before reading attribute Access_Disp_Table.
6676 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
6677 the Underlying_Type entity before reading attribute Access_Disp_Table.
6678 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
6679 Locate the Underlying_Type entity before reading attribute
6680 Access_Disp_Table.
6681
66822011-08-01 Ed Schonberg <schonberg@adacore.com>
6683
6684 * s-poosiz.ads: Additional overriding indicators.
6685
66862011-08-01 Yannick Moy <moy@adacore.com>
6687
6688 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
6689 formal mode.
6690 (Analyze_Iteration_Scheme): issue error in formal mode when loop
6691 parameter specification does not include a subtype mark.
6692 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
6693 formal mode on abstract subprogram.
6694 (Analyze_Subprogram_Specification): issue error in formal mode on
6695 user-defined operator.
6696 (Process_Formals): issue error in formal mode on access parameter and
6697 default expression.
6698 * sem_ch9.adb (Analyze_Abort_Statement,
6699 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
6700 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
6701 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
6702 Analyze_Requeue, Analyze_Selective_Accept,
6703 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
6704 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
6705 issue error in formal mode on user-defined raise statement.
6706
67072011-08-01 Thomas Quinot <quinot@adacore.com>
6708
6709 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
6710 declaration being hidden when overriding an implicit inherited
6711 subprogram.
6712 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
6713 (-gnats), do not complain about a source file that contains only a
6714 pragma No_Body.
6715
67162011-08-01 Ed Schonberg <schonberg@adacore.com>
6717
6718 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
6719 variable if already set.
6720
67212011-08-01 Arnaud Charlet <charlet@adacore.com>
6722
6723 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
6724 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
6725 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
6726 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
6727 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
6728 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
6729 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
6730 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
6731 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
6732 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
6733 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
6734 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
6735 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
6736 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
6737 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
6738 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
6739 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
6740 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
6741 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
6742 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
6743 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
6744 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
6745 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
6746 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
6747 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
6748 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
6749 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
6750 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
6751 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
6752 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
6753 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
6754 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
6755 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
6756 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
6757 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
6758 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
6759 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
6760 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
6761 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
6762 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
6763 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
6764 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
6765 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
6766 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
6767 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
6768 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
6769 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
6770 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
6771 s-osinte-mingw.ads: Update to GPLv3 run-time license.
6772 Use GNAT instead of GNARL.
6773
67742011-08-01 Bob Duff <duff@adacore.com>
6775
6776 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
6777 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
6778 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
6779 reformatting.
6780
67812011-08-01 Yannick Moy <moy@adacore.com>
6782
6783 * debug.adb (d.D) reverve flag for the SPARK mode
6784 (d.E) reverve flag for SPARK generation mode
6785 (d.F) reverve flag for Why generation mode
2c7f9cc0 6786 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
052e0603
AC
6787 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
6788 functions which return True when the corresponding modes are set
6789 (Formal_Language): return "spark" or "alfa" when in formal verification
6790 mode.
6791 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
6792 Error_Msg to prefix the error message with a tag giving the formal
6793 language
6794 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
6795 message with a tag giving the formal language
6796 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
6797 block statement
6798 (Analyze_Case_Statement): issue error in formal mode on case statement
6799 with a single "others" case alternative
6800 (Analyze_Exit_Statement): issue errors in formal mode on exit
6801 statements which do not respect SPARK restrictions
6802 (Analyze_Goto_Statement): issue error in formal mode on goto statement
6803 (Check_Unreachable_Code): always issue an error (not a warning) in
6804 formal mode on unreachable code (concerns both code after an infinite
6805 loop and after an unconditional jump, both not allowed in SPARK)
6806 * sem_ch6.adb (Analyze_Return_Statement): add call to
6807 Set_Return_Present for a procedure containing a return statement
6808 (already done for functions in Analyze_Function_Return)
6809 (Analyze_Function_Return): issue error in formal mode on extended
6810 return or if return is not last statement in function
6811 (Check_Missing_Return): issue error in formal mode if function does
6812 not end with return or if procedure contains a return
6813 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
6814 function to detect if there is an inner scope of its parameter S which
6815 is a loop.
6816
68172011-08-01 Thomas Quinot <quinot@adacore.com>
6818
6819 * sem_ch6.ads: Minor reformatting.
6820
68212011-08-01 Javier Miranda <miranda@adacore.com>
6822
6823 * sem_util.adb (Abstract_Interface_List): Complete condition when
6824 processing private type declarations to avoid reading unavailable
6825 attribute.
6826 (Is_Synchronized_Tagged_Type): Complete condition when processing
6827 private extension declaration nodes to avoid reading unavailable
6828 attribute.
6829
68302011-08-01 Thomas Quinot <quinot@adacore.com>
6831
6832 * sem_ch3.adb: Minor reformatting.
6833
68342011-08-01 Thomas Quinot <quinot@adacore.com>
6835
6836 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
6837 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
6838 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
6839 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
6840 for VMS, instead parametrize the common implementation with
6841 System.Parameters declarations.
6842
68432011-08-01 Eric Botcazou <ebotcazou@adacore.com>
6844
6845 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
6846
68472011-08-01 Tristan Gingold <gingold@adacore.com>
6848
6849 * seh_init.c: Fix SEH handler installation on win64.
6850
68512011-08-01 Ed Schonberg <schonberg@adacore.com>
6852
6853 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
6854 double analysis of an anonymous access to subprogram, because it can
6855 lead to improper sharing of profiles and a back-end crash.
6856
68572011-08-01 Robert Dewar <dewar@adacore.com>
6858
6859 * make.adb, sem_ch4.adb: Minor reformatting.
6860 * gcc-interface/Make-lang.in: Update dependencies.
6861 * sem_util.adb, exp_ch5.adb: Minor reformatting.
6862
68632011-08-01 Arnaud Charlet <charlet@adacore.com>
6864
6865 * gnat_rm.texi: Fix definition of Long_Integer.
6866
68672011-08-01 Ed Schonberg <schonberg@adacore.com>
6868
6869 * exp_aggr.adb: check limit size of static aggregate unconditionally,
6870 to prevent storage exhaustion.
6871 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
6872 finalized is a function body, insert the cleanup code before the final
6873 return statement, to prevent spurious warnings.
6874 * s-pooglo.ads: add overriding indicator.
6875
68762011-08-01 Ed Schonberg <schonberg@adacore.com>
6877
6878 * sem_ch4.adb (Operator_Check): improve error message when both a
6879 with_clause and a use_clause are needed to make operator usage legal.
6880 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
6881 determine whether a compilation unit is visible within an other,
6882 either through a with_clause in the current unit, or a with_clause in
6883 its library unit or one one of its parents.
6884
68852011-08-01 Ed Schonberg <schonberg@adacore.com>
6886
6887 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
6888 over an arbitrary expression of an array or container type.
6889 * lib-xref.adb: clarify comment.
6890
68912011-08-01 Bob Duff <duff@adacore.com>
6892
6893 * einfo.ads: Minor reformatting.
6894 * debug.adb: Minor comment improvement.
6895
68962011-08-01 Javier Miranda <miranda@adacore.com>
6897
6898 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
6899 consider hidden subprograms as valid candidates.
6900
69012011-08-01 Arnaud Charlet <charlet@adacore.com>
6902
6903 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
6904
69052011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
6906
6907 * gnat_ugn.texi: Fix typo.
6908
69092011-08-01 Robert Dewar <dewar@adacore.com>
6910
6911 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
6912 lib-xref.adb: Minor reformatting
6913
69142011-08-01 Gary Dismukes <dismukes@adacore.com>
6915
6916 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
6917 when to generate a call to Move_Final_List.
6918 (Has_Controlled_Parts): Remove this function.
6919
69202011-08-01 Geert Bosch <bosch@adacore.com>
6921
6922 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
6923 "," in choice list.
6924
69252011-08-01 Thomas Quinot <quinot@adacore.com>
6926
6927 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
6928 explicit raise of a predefined exception as Comes_From_Source if the
6929 original N_Raise_Statement comes from source.
6930
69312011-08-01 Robert Dewar <dewar@adacore.com>
6932
6933 * sinfo.ads: Add comment.
6934 * sem_ch6.adb: Minor reformatting.
6935
69362011-08-01 Robert Dewar <dewar@adacore.com>
6937
6938 * freeze.adb (Freeze_Entity): Refine check for bad component size
6939 clause to avoid rejecting confirming clause when atomic/aliased present.
6940
69412011-08-01 Ed Schonberg <schonberg@adacore.com>
6942
6943 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
6944 better determine whether an entity reference is a write.
6945 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
6946 subcomponent.
6947 * lib-xref.adb (Output_References): Do no suppress a read reference at
6948 the same location as an immediately preceeding modify-reference, to
6949 handle properly in-out actuals.
6950
69512011-08-01 Tristan Gingold <gingold@adacore.com>
6952
6953 * env.c (__gnat_setenv) [VMS]: Refine previous change.
6954
69552011-08-01 Quentin Ochem <ochem@adacore.com>
6956
6957 * i-cstrin.adb (New_String): Changed implementation, now uses only the
6958 heap to compute the result.
6959
69602011-08-01 Robert Dewar <dewar@adacore.com>
6961
6962 * atree.ads: Minor reformatting.
6963
69642011-08-01 Emmanuel Briot <briot@adacore.com>
6965
6966 * g-expect.adb (Get_Command_Output): Fix memory leak.
6967
69682011-08-01 Geert Bosch <bosch@adacore.com>
6969
6970 * cstand.adb (P_Float_Type): New procedure to print the definition of
6971 predefined fpt types.
6972 (P_Mixed_Name): New procedure to print a name using mixed case
6973 (Print_Standard): Use P_Float_Type for printing floating point types
6974 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
6975 precision IEEE float.
6976
69772011-08-01 Thomas Quinot <quinot@adacore.com>
6978
6979 * sem_ch3.adb: Minor reformatting.
6980
69812011-08-01 Ed Schonberg <schonberg@adacore.com>
6982
6983 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
6984 the completion of a generic function, insert the new body rather than
6985 rewriting the original.
6986
69872011-08-01 Yannick Moy <moy@adacore.com>
6988
6989 * sinfo.ads, errout.ads: Typos in comments.
6990
69912011-08-01 Robert Dewar <dewar@adacore.com>
6992
6993 * par-endh.adb: Minor reformatting.
6994
69952011-08-01 Robert Dewar <dewar@adacore.com>
6996
6997 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
6998 (Pre_Post_Aspects): New subtype.
6999 * par-ch12.adb (P_Generic): New syntax for aspects in packages
7000 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
7001 * par-ch7.adb (P_Package): Remove Decl parameter
7002 (P_Package): Handle new syntax for aspects (before IS)
7003 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
7004 new aspect syntax
7005 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
7006 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
7007 (P_Package): Remove Decl parameter
7008 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
7009 aspects
7010 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
7011 specs
7012 * sem_util.ads, sem_util.adb (Static_Boolean): New function
7013 * sinfo.ads: Document new syntax for aspects in packages etc.
7014 * sprint.adb: Handle new syntax of aspects before IS in package
7015
70162011-08-01 Thomas Quinot <quinot@adacore.com>
7017
7018 * atree.ads: Minor reformatting.
7019 * sem_prag.adb: Minor reformatting.
7020
70212011-08-01 Robert Dewar <dewar@adacore.com>
7022
7023 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
7024 case expr alternative.
7025
70262011-08-01 Ed Schonberg <schonberg@adacore.com>
7027
7028 * sem_ch12.adb: Fix typo.
7029
70302011-08-01 Geert Bosch <bosch@adacore.com>
7031
7032 * sem_prag.adb (Check_No_Link_Name): New procedure.
7033 (Process_Import_Or_Interface): Use Check_No_Link_Name.
7034 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
7035 instead of Standard_Long_Long_Float_Size global. Preparation for
7036 eventual removal of per type constants.
7037 * exp_util.ads (Get_Stream_Size): New function returning the stream
7038 size value of subtype E.
7039 * exp_util.adb (Get_Stream_Size): Implement new function.
7040 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
7041 function.
7042 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
7043 * einfo.adb:
7044 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
7045
70462011-08-01 Geert Bosch <bosch@adacore.com>
7047
7048 * cstand.adb: Fix comments.
7049 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
7050 count of arguments.
7051
70522011-08-01 Robert Dewar <dewar@adacore.com>
7053
7054 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
7055
70562011-08-01 Geert Bosch <bosch@adacore.com>
7057
7058 * atree.ads: Fix comment.
7059
70602011-08-01 Robert Dewar <dewar@adacore.com>
7061
7062 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
7063 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
7064 * par.adb: Add with for Namet.Sp.
7065 * par-tchk.adb: Minor reformatting.
7066
70672011-08-01 Vincent Celier <celier@adacore.com>
7068
7069 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
7070 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
7071 of the init procedure of a SAL.
7072 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
7073 New procedure.
7074
70752011-08-01 Thomas Quinot <quinot@adacore.com>
7076
7077 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
7078 reformatting.
7079
70802011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
7081
7082 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
7083
70842011-08-01 Thomas Quinot <quinot@adacore.com>
7085
7086 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
7087 conformant with its spec (return True only for types that have
7088 an overriding Initialize primitive operation that prevents them from
7089 having preelaborable initialization).
7090 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
7091 initialization for controlled types in Ada 2005 or later mode.
7092
70932011-08-01 Robert Dewar <dewar@adacore.com>
7094
7095 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
7096 Postcondition.
7097 (Same_Aspect): New function.
7098 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
7099 Type_Invariant, Precondition, Postcondition.
7100 * snames.ads-tmpl: Add Name_Type_Invariant.
7101
71022011-08-01 Robert Dewar <dewar@adacore.com>
7103
7104 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
7105 here.
7106 (Freeze_All_Ent): Fix error in handling inherited aspects.
7107 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
7108 already analyzed, but don't skip entire processing of a declaration,
7109 that's wrong in some cases of declarations being rewritten.
7110 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
7111 Don't delay for integer, string literals
7112 Treat predicates in usual manner for delay, remove special case code,
7113 not needed.
7114 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
7115 (Build_Predicate_Function): Update saved expression in aspect
7116 (Build_Invariant_Procedure): Update saved expression in aspect
7117 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
7118 of replacement of discriminant references if the reference is simple.
7119
71202011-08-01 Robert Dewar <dewar@adacore.com>
7121
7122 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
7123 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
7124 Static_Predicate and Dynamic_Predicate.
7125 (Build_Predicate_Function): Add processing for Static_Predicate
7126 and Dynamic_Predicate.
7127 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
7128 (From_Static_Predicate): New flag
7129 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
7130
71312011-08-01 Robert Dewar <dewar@adacore.com>
7132
7133 * usage.adb: Documentation cleanup for Ada version modes in usage.
7134 * expander.adb: Minor reformatting.
7135
71362011-08-01 Robert Dewar <dewar@adacore.com>
7137
7138 * atree.ads: Minor comment fix.
7139 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
7140 a-witeio.ads, sem_prag.adb: Minor reformatting.
7141
71422011-08-01 Doug Rupp <rupp@adacore.com>
7143
7144 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
7145 pointers. Use descrip.h header file for convenience. Add some
7146 comments.
7147
71482011-08-01 Robert Dewar <dewar@adacore.com>
7149
7150 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
7151 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
7152 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
7153 New procedure.
7154 (Check_Aspect_At_End_Of_Declarations): New procedure
7155 (Analye_Aspect_Specification): Minor changes for above procedures
7156 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
7157 specification node as well.
7158
71592011-08-01 Pascal Obry <obry@adacore.com>
7160
7161 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
7162 Windows files. Use GetFilesAttributes() in this case to check for file
7163 existence instead of returning with an error code.
7164
71652011-08-01 Vincent Celier <celier@adacore.com>
7166
7167 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
7168 High is above Source length.
7169
71702011-08-01 Robert Dewar <dewar@adacore.com>
7171
7172 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
7173
71742011-08-01 Robert Dewar <dewar@adacore.com>
7175
7176 * aspects.ads (Boolean_Aspects): New subtype.
7177 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
7178 for derived types in cases where the parent type and derived type have
7179 aspects.
7180 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
7181 with aspects when parent type also has aspects.
7182 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
7183 boolean expression at this point).
7184 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
7185 accordance with final decision on the Ada 2012 feature.
7186 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
7187
71882011-08-01 Matthew Heaney <heaney@adacore.com>
7189
7190 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
7191
71922011-08-01 Pascal Obry <obry@adacore.com>
7193
7194 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
7195 Fix Replace_Slice when High is above current string size.
7196 (Replace_Slice): Fix DL computation when High is above current
7197 string length.
7198
71992011-08-01 Gary Dismukes <dismukes@adacore.com>
7200
7201 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
7202
72032011-08-01 Matthew Heaney <heaney@adacore.com>
7204
7205 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
7206 of node.
7207
72082011-08-01 Pascal Obry <obry@adacore.com>
7209
7210 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
7211 reformatting.
7212
72132011-08-01 Ed Schonberg <schonberg@adacore.com>
7214
7215 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
7216 access to protected subprograms in generic bodies.
7217 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
7218 protected type, indicate that the convention of the subprogram is
7219 Convention_Protected, because it may be used in subsequent declarations
7220 within the protected declaration.
7221
72222011-08-01 Vincent Celier <celier@adacore.com>
7223
7224 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
7225 and "final" procedures when the name of the library is "ada", to avoid
7226 duplicate symbols "adainit" and "adafinal" in executables.
7227
72282011-08-01 Ed Schonberg <schonberg@adacore.com>
7229
7230 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
7231 quantified expression that appears within a postcondition and uses the
7232 Ada2012 'Result attribute.
7233
72342011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7235
7236 * init.c (__gnat_error_handler): Cast reason to int.
7237 (__gnat_install_handler): Explain sa_sigaction use.
7238
72392011-07-24 Eric Botcazou <ebotcazou@adacore.com>
7240
7241 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
7242 subprogram has copy-in copy-out parameters, try to promote the mode of
7243 the return type if it is passed in registers.
7244
72452011-07-24 Eric Botcazou <ebotcazou@adacore.com>
7246
7247 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
7248 left operand as addressable.
7249
72502011-07-24 Eric Botcazou <ebotcazou@adacore.com>
7251
7252 * gcc-interface/gigi.h (build_function_stub): Remove.
7253 (build_return_expr): Likewise.
7254 (convert_vms_descriptor): Declare.
7255 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
7256 (build_function_stub): Move to...
7257 * gcc-interface/utils2.c (build_return_expr): Move to...
7258 * gcc-interface/trans.c (build_function_stub): ...here.
7259 (build_return_expr): ...here.
7260 (Subprogram_Body_to_gnu): Add local variable for language_function.
7261 Disconnect the parameter attributes cache, if any, once done with it.
7262 Call end_subprog_body only after setting the end_locus.
7263 Build the stub associated with the function, if any, at the very end.
7264 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
7265 variables and streamline control flow.
7266
72672011-07-23 Arnaud Charlet <charlet@adacore.com>
7268
7269 PR ada/49819
7270 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
7271 g-trasym-dwarf.adb.
7272
72732011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7274
7275 PR bootstrap/49794
7276 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
7277 Assign to act.sa_sigaction.
7278 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
7279 current->return_address to char * before arithmetic.
7280
72812011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7282
7283 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
7284 Correct argument types.
7285 Extract code from reason.
7286 (__gnat_install_handler): Assign to act.sa_sigaction.
7287
72882011-07-21 Eric Botcazou <ebotcazou@adacore.com>
7289
7290 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
7291 (GNAT1_OBJS): ...here.
7292
72932011-07-15 Eric Botcazou <ebotcazou@adacore.com>
7294
7295 PR ada/48711
7296 * g-socthi-mingw.adb (Fill): Fix formatting.
7297
7298 * gcc-interface/gigi.h: Move around comment.
7299
73002011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
7301
7302 PR ada/46350
7303 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
7304
73052011-07-14 Florian Weimer <fw@deneb.enyo.de>
7306
7307 PR ada/48711
7308 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
7309
73102011-07-13 Eric Botcazou <ebotcazou@adacore.com>
7311
7312 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
7313 range comparison if Pmode is SImode.
7314
73152011-07-12 Laurent GUERBY <laurent@guerby.net>
7316 Eric Botcazou <ebotcazou@adacore.com>
7317
7318 * adadecode.c: Wrap up in extern "C" block.
7319 * adadecode.h: Likewise.
7320 * adaint.c: Likewise. Remove 'const' keyword.
7321 * adaint.h: Likewise.
7322 * argv.c: Likewise.
7323 * atree.h: Likewise.
7324 * cio.c: Likewise.
7325 * cstreams.c: Likewise.
7326 * env.c: Likewise.
7327 * exit.c: Likewise.
7328 * fe.h: Likewise.
7329 * final.c: Likewise.
7330 * init.c: Likewise.
7331 * initialize.c: Likewise.
7332 * link.c: Likewise.
7333 * namet.h: Likewise.
7334 * nlists.h: Likewise.
7335 * raise.c: Likewise.
7336 * raise.h: Likewise.
7337 * repinfo.h: Likewise.
7338 * seh_init.c: Likewise.
7339 * targext.c: Likewise.
7340 * tracebak.c: Likewise.
7341 * uintp.h: Likewise.
7342 * urealp.h: Likewise.
7343 * xeinfo.adb: Wrap up generated C code in extern "C" block.
7344 * xsinfo.adb: Likewise.
7345 * xsnamest.adb: Likewise.
7346 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
7347 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
7348 * gcc-interface/misc.c: Likewise.
7349 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
7350 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
7351 ada/targext.o here...
7352 (GNAT_ADA_OBJS): ...and not here.
7353 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
7354 (GNATBIND_OBJS): Reorder.
7355
73562011-07-07 Richard Henderson <rth@redhat.com>
7357
7358 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
7359 dwarf2out_frame_init.
7360
73612011-07-07 Eric Botcazou <ebotcazou@adacore.com>
7362
7363 * gcc-interface/misc.c (gnat_init): Tweak previous change.
7364
73652011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7366
7367 PR target/39150
7368 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
7369
73702011-07-06 Richard Guenther <rguenther@suse.de>
7371
7372 * gcc-interface/misc.c (gnat_init): Merge calls to
7373 build_common_tree_nodes and build_common_tree_nodes_2.
7374 Re-initialize boolean_false_node.
7375
73762011-07-02 Eric Botcazou <ebotcazou@adacore.com>
7377 Olivier Hainque <hainque@adacore.com>
7378 Nicolas Setton <setton@adacore.com>
7379
7380 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
7381 the type according to the ARTIFICIAL_P parameter.
7382 (create_type_decl): Likewise.
7383 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
7384
73852011-07-01 Eric Botcazou <ebotcazou@adacore.com>
7386
7387 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
7388 (gnatbind): Likewise.
7389
73902011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7391
7392 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
7393
73942011-06-18 Eric Botcazou <ebotcazou@adacore.com>
7395
7396 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
7397 local variable throughout. Remove useless call to Base_Type.
7398 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
7399 Take it also into account for the volatileness of the field. Set the
7400 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
7401
74022011-06-18 Eric Botcazou <ebotcazou@adacore.com>
7403
7404 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
7405 on a dereference built for a by-ref object if it has an address clause.
7406
74072011-06-18 Eric Botcazou <ebotcazou@adacore.com>
7408
7409 * einfo.ads (Address_Taken): Document use for the second argument of
7410 Asm_Input and Asm_Output attributes.
7411 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
7412 argument is an entity name, then set Address_Taken on it.
7413 <Attribute_Asm_Output>: Likewise.
7414 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
7415 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
7416 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
7417 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
7418
74192011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
7420
7421 PR middle-end/46500
7422 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
7423
74242011-06-14 Joseph Myers <joseph@codesourcery.com>
7425
7426 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
7427 (ada/utils.o): Update dependencies.
7428 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
7429 ../../../libcpp/libcpp.a.
7430 * gcc-interface/utils.c: Include common/common-target.h.
7431 (process_attributes): Use targetm_common.have_named_sections.
7432
74332011-06-07 Richard Guenther <rguenther@suse.de>
7434
7435 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
7436 set_sizetype.
7437
74382011-06-06 Eric Botcazou <ebotcazou@adacore.com>
7439
7440 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
7441 TREE_THIS_NOTRAP flag.
7442
74432011-06-06 Eric Botcazou <ebotcazou@adacore.com>
7444
7445 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
7446 Fix thinko.
7447
74482011-06-06 Eric Botcazou <ebotcazou@adacore.com>
7449
7450 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
7451 constants whose full view has discriminants specially.
7452
74532011-06-06 Eric Botcazou <ebotcazou@adacore.com>
7454
7455 * gcc-interface/utils.c: Include diagnostic.h.
7456 (gnat_write_global_declarations): Output debug information for all
7457 global type declarations before finalizing the compilation unit.
7458 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
7459
74602011-05-25 Jakub Jelinek <jakub@redhat.com>
7461
7462 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
7463
74642011-05-25 Kai Tietz <ktietz@redhat.com>
7465
7466 * adaint.c (__gnat_to_canonical_file_list_next): Use array
7467 initialization instead of const/none-const pointer assignment.
7468
74692011-05-24 Joseph Myers <joseph@codesourcery.com>
7470
7471 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
7472 $(EXTRA_GNAT1_OBJS).
7473 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
7474 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
7475 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
7476 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
7477 libcommon-target.a instead of prefix.o.
7478
74792011-05-21 Joseph Myers <joseph@codesourcery.com>
7480
7481 PR ada/49097
7482 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
7483
74842011-05-20 Joseph Myers <joseph@codesourcery.com>
7485
7486 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
7487 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
7488 instead of version.o.
7489
74902011-05-18 Kai Tietz <ktietz@redhat.com>
7491
7492 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
7493 boolean_false_node instead of integer_zero_node.
7494 (convert_with_check): Likewise.
7495 * gcc-interface/decl.c (choices_to_gnu): Likewise.
7496
74972011-05-12 Eric Botcazou <ebotcazou@adacore.com>
7498
7499 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
7500 type of the parameter is an unconstrained array, convert the actual to
7501 the type of the formal in the In Out and Out cases as well.
7502
75032011-05-11 Nathan Froyd <froydnj@codesourcery.com>
7504
7505 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
7506 call build_function_type_array or build_varargs_function_type_array
7507 instead.
7508 (create_subprog_type): Don't call build_function_type; call
7509 build_function_type_vec instead.
7510
75112011-05-11 Nathan Froyd <froydnj@codesourcery.com>
7512
7513 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
7514 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
7515 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
7516
75172011-05-07 Eric Botcazou <ebotcazou@adacore.com>
7518
7519 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
7520
7521 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
7522 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
7523
75242011-05-05 Nathan Froyd <froydnj@codesourcery.com>
7525
7526 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
7527
75282011-05-05 Nathan Froyd <froydnj@codesourcery.com>
7529
7530 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
7531 instead of accessing TYPE_ARG_TYPES directly.
7532 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
7533
75342011-05-05 Eric Botcazou <ebotcazou@adacore.com>
7535
7536 PR ada/48844
7537 * gcc-interface/gigi.h (get_variant_part): Declare.
7538 * gcc-interface/decl.c (get_variant_part): Make global.
7539 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
7540 types have the same constant size, are record types and T1 has a
7541 variant part while T2 doesn't.
7542
75432011-05-05 Eric Botcazou <ebotcazou@adacore.com>
7544
7545 * gcc-interface/utils.c (begin_subprog_body): Do not call
7546 get_pending_sizes.
7547 (end_subprog_body): Likewise.
7548
75492011-05-04 Richard Guenther <rguenther@suse.de>
7550
7551 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
7552 int_const_binop.
7553 (pos_to_constructor): Likewise.
7554
75552011-05-03 Nathan Froyd <froydnj@codesourcery.com>
2c7f9cc0 7556 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
7557
7558 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
7559 of build_function_type. Adjust calls to...
7560 (build_raise_check): ...this. Do not take a void_tree parameter.
7561 Call build_function_type_list instead of build_function_type.
7562 Fix head comment and swap couple of conditional blocks.
7563
75642011-04-30 Eric Botcazou <ebotcazou@adacore.com>
7565
7566 * gnatvsn.ads (Library_Version): Bump to 4.7.
7567 (Current_Year): Bump to 2011.
7568
75692011-04-29 Michael Matz <matz@suse.de>
7570
7571 * gcc-interface/misc.c (gnat_handle_option): Set
7572 warn_maybe_uninitialized.
7573
75742011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
7575
7576 * gnat_ugn.texi (Complexity Metrics Control): Update link to
7577 the Watson/McCabe paper.
7578
75792011-04-23 Jim Meyering <meyering@redhat.com>
7580
7581 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
7582
75832011-04-22 Eric Botcazou <ebotcazou@adacore.com>
7584
7585 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
7586 onto the new type.
7587
75882011-04-22 Eric Botcazou <ebotcazou@adacore.com>
7589
7590 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
7591 parameter.
7592 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
7593 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
7594 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
7595 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
7596 <all>: Do not set flags on the reused DECL node coming from an alias.
7597 Set DECL_IGNORED_P on the DECL node built for subprograms if they
7598 don't need debug info here...
7599 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
7600 (gigi): Adjust calls to create_subprog_decl.
7601 (build_raise_check): Likewise.
7602 (establish_gnat_vms_condition_handler): Likewise.
7603 (Compilation_Unit_to_gnu): Likewise.
7604 (gnat_to_gnu): Likewise.
7605
76062011-04-21 Eric Botcazou <ebotcazou@adacore.com>
7607
7608 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
7609 (NO_REORDER_ADAFLAGS): New variable.
7610 (EXTRA_GNATTOOLS): Always define.
7611 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
7612 Clean up and adjust list of files compiled with special options.
7613 * gcc-interface/Make-lang.in: Likewise.
7614 (ada/decl.o): Cosmetical change.
7615 (ada/misc.o): Remove dependency on $(PLUGIN_H).
7616
76172011-04-20 Jim Meyering <meyering@redhat.com>
7618
7619 * initialize.c (__gnat_initialize): Remove useless if-before-free.
7620
76212011-04-17 Eric Botcazou <ebotcazou@adacore.com>
7622
7623 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
7624 $(CFLAGS) on the link line.
7625
76262011-04-17 Eric Botcazou <ebotcazou@adacore.com>
7627
7628 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
7629 padded type built for the return type if it is unconstrained.
7630
76312011-04-14 Nathan Froyd <froydnj@codesourcery.com>
7632
7633 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
7634
76352011-04-12 Nathan Froyd <froydnj@codesourcery.com>
7636
7637 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
7638 before calling TREE_CHAIN.
7639 * gcc-interface/misc.c (gnat_init_ts): New function.
7640 (LANG_HOOKS_INIT_TS): Define.
7641
76422011-04-12 Martin Jambor <mjambor@suse.cz>
7643
7644 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
7645 instead of cgraph_node.
7646
76472011-04-08 Eric Botcazou <ebotcazou@adacore.com>
7648
7649 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
7650 alignment on fields of the RETURN type built for the Copy-In Copy-Out
7651 mechanism.
7652
76532011-04-08 Eric Botcazou <ebotcazou@adacore.com>
7654
7655 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
7656 of aggregate types that contain a placeholder.
7657
76582011-04-08 Nathan Froyd <froydnj@codesourcery.com>
7659
7660 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
7661 TYPE_ARG_TYPES.
7662 (handle_type_generic_attribute): Likewise.
7663
76642011-04-04 Eric Botcazou <ebotcazou@adacore.com>
7665
7666 PR ada/47163
7667 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
7668
76692011-04-04 Kai Tietz <ktietz@redhat.com>
7670
7671 PR ada/47163
7672 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
7673 to flag value.
7674
76752011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7676
7677 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
7678 type case, do not strip a padding type around the array type.
7679
76802011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7681
7682 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
7683 types.
7684
76852011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7686
7687 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
7688 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
7689 code for -feliminate-unused-debug-types.
7690 (gnat_post_options): Likewise.
7691
76922011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7693
7694 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
7695 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
7696 distinct copy.
7697
76982011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7699
7700 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
7701 DECL_ARTIFICIAL flag on enumeration types.
7702
77032011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7704
7705 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
7706 fat pointer types artificial unconditionally.
7707 <E_Array_Subtype>: Attach the base array type as a parallel type if it
7708 isn't artificial.
7709
77102011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7711
7712 * gcc-interface/gigi.h (get_dummy_type): Declare.
7713 (build_dummy_unc_pointer_types): Likewise.
7714 (finish_fat_pointer_type): Likewise.
7715 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
7716 fat pointer type has been built, complete it in place.
7717 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
7718 and thin pointers. Remove useless variable.
7719 (finish_fat_pointer_type): Make global and move to...
7720 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
7721 (get_dummy_type): New function.
7722 (build_dummy_unc_pointer_types): Likewise.
7723 (gnat_pushdecl): Propage the name to the anonymous variants only.
7724 (update_pointer_to): Only adjust the pointer types in the unconstrained
7725 array case.
7726
77272011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7728
7729 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
7730 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
7731 if this is a Taft amendment type and the full declaration is available.
7732 * gcc-interface/trans.c (process_type): Likewise.
7733 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
7734 (process_freeze_entity): Likewise.
7735 * gcc-interface/utils.c (dummy_global): New static variable.
7736 (gnat_write_global_declarations): If there are types declared as used
7737 at the global level, insert them in the global hash table.
7738
77392011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7740
7741 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
7742 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
7743 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
7744 copy.
7745 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
7746 flag of the type accordingly.
7747 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
7748
77492011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7750
7751 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
7752 finalizing types when updating the pointers to the designated type.
7753 <all>: Finalize the deferred types even if we didn't defer processing
7754 of incomplete types in this invocation.
7755
77562011-04-01 Olivier Hainque <hainque@adacore.com>
2c7f9cc0
AS
7757 Nicolas Setton <setton@adacore.com>
7758 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
7759
7760 * gcc-interface/misc.c (gnat_descriptive_type): New function.
7761 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
7762
77632011-03-28 Kai Tietz <ktietz@redhat.com>
7764
7765 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
7766 Windows targets.
7767 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
7768 * system-mingw.ads (System): Change ZCX_By_Default default to True.
7769
7770 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
7771
77722011-03-28 Tristan Gingold <gingold@adacore.com>
7773
7774 PR ada/44431
7775 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
7776 Use ada output of gnatbind.
7777 (ada/b_gnatb.adb): Ditto.
7778 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
7779 (ada.mostlyclean, ada.stage1)
7780 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
7781 (ada.stagefeedback): Adjust.
7782 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
7783 Use ada output of gnatbind.
7784 (b_gnatm.adb): Ditto.
7785 (b_gnatl.o, b_gnatm.o): New rules.
7786
77872011-03-26 Eric Botcazou <ebotcazou@adacore.com>
7788
7789 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
7790 for the padded type built to support a specified size or alignment.
7791
77922011-03-26 Eric Botcazou <ebotcazou@adacore.com>
7793
7794 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
7795 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
7796 unconditionally to the end of the unit when the designated type is
7797 limited_with'ed.
7798 <all>: Rename local variable. Attempt to un-defer types only and do it
7799 for limited_with'ed types as well.
7800 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
7801 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
7802 consistently and remove redundant call to finalize_from_with_types.
7803
78042011-03-26 Eric Botcazou <ebotcazou@adacore.com>
7805
7806 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
7807 subprograms without a previous spec declared in the same unit.
7808 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
7809 subprograms at the end of the unit instead of at the beginning.
7810 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
7811 isn't public for the special handling of non-inline functions nested
7812 inside inline external functions.
7813
78142011-03-25 Jeff Law <law@redhat.com>
7815
7816 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
7817
78182011-03-24 Eric Botcazou <ebotcazou@adacore.com>
7819
7820 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
7821 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
7822 to compute Set_Size_Depends_On_Discriminant.
7823 (Layout_Type): Call it on array types in back-end layout mode.
7824 * sem_util.adb (Requires_Transient_Scope): Return true for array
7825 types only if the size depends on the value of discriminants.
7826 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
7827 type if the RHS is a call to a function that returns an unconstrained
7828 type with default discriminant.
7829
78302011-03-24 Eric Botcazou <ebotcazou@adacore.com>
7831
7832 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
7833 non-conversion to the nominal result type at the end.
7834
78352011-03-23 Eric Botcazou <ebotcazou@adacore.com>
7836
7837 * gcc-interface/trans.c (create_temporary): New function taken from...
7838 (create_init_temporary): ...here. Call it.
7839 (call_to_gnu): Create the temporary for the return value early, if any.
7840 Create it for a function with copy-in/copy-out parameters if there is
7841 no target; in other cases of copy-in/copy-out, use another temporary.
7842 Push the new binding level lazily. Add and rename local variables.
7843
78442011-03-23 Eric Botcazou <ebotcazou@adacore.com>
7845
7846 * gcc-interface/decl.c (validate_size): Improve comments and tweak
7847 error message.
7848 (set_rm_size): Likewise.
7849
78502011-03-23 Eric Botcazou <ebotcazou@adacore.com>
7851
7852 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
7853 for the padded type built in order to support a specified alignment.
7854 Fix incorrect formatting.
7855
78562011-03-21 Eric Botcazou <ebotcazou@adacore.com>
7857
7858 PR bootstrap/48216
7859 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
7860
78612011-03-21 Eric Botcazou <ebotcazou@adacore.com>
7862
7863 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
7864 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
7865 to the end of the list. Adjust recursive call. Rename local variable.
7866 If REORDER is true, reorder components of the record type.
7867 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
7868 components_to_record and adjust the parameter list.
7869
78702011-03-21 Eric Botcazou <ebotcazou@adacore.com>
7871
7872 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
7873 disabled, use the variable for bounds of loop iteration scheme.
7874
78752011-03-21 Kai Tietz <ktietz@redhat.com>
7876
7877 PR target/12171
7878 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
7879
78802011-03-17 Eric Botcazou <ebotcazou@adacore.com>
7881
7882 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
7883 out whether the expression is read-only. Short-circuit placeholder
7884 case and rename a couple of local variables.
7885
78862011-03-17 Eric Botcazou <ebotcazou@adacore.com>
7887
7888 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
7889 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
7890 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
7891 (convert): Deal with conversions from a smaller form type specially.
7892
78932011-02-14 Eric Botcazou <ebotcazou@adacore.com>
7894
7895 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
7896 its argument, except for the special -I- switch.
7897
78982011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
7899
7900 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
7901 "Ada Issues".
7902
79032011-02-08 Eric Botcazou <ebotcazou@adacore.com>
7904
7905 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
7906
79072011-02-03 Eric Botcazou <ebotcazou@adacore.com>
7908
7909 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
7910 GNAT_FORMAL.
7911 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
7912 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
7913 instead of GNAT_FORMAL. Protect the expression against multiple uses.
7914 Do not generate the check directly, instead instantiate the template
7915 check present in the descriptor.
7916 (make_descriptor_field): Move around.
7917 (build_vms_descriptor32): Build a template check in the POINTER field.
7918 (build_vms_descriptor): Remove useless suffixes.
7919 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
7920
79212011-01-26 Eric Botcazou <ebotcazou@adacore.com>
7922
7923 PR bootstrap/47467
7924 * targext.c: Include target files if IN_RTS is defined.
7925
79262011-01-26 Richard Guenther <rguenther@suse.de>
7927
7928 PR bootstrap/47467
7929 * targext.c: Include config.h.
7930 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
7931 dependency.
7932
79332011-01-04 Pascal Obry <obry@adacore.com>
2c7f9cc0 7934 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
7935
7936 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
7937
79382011-01-04 Eric Botcazou <ebotcazou@adacore.com>
7939
7940 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
7941 end-of-case on the end label and its associated gotos, if any.
7942
79432011-01-04 Eric Botcazou <ebotcazou@adacore.com>
7944
7945 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
7946 expressions of the parameter cache within the statement group of
7947 the CICO mechanism.
7948
79492011-01-04 Olivier Hainque <hainque@adacore.com>
2c7f9cc0 7950 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
7951
7952 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
7953 (set_end_locus_from_node): New function.
7954 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
7955 make and the function end_locus.
7956 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
7957 for the elaboration subprogram.
7958 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
7959 set the end_locus of the expression as well.
7960
79612011-01-04 Eric Botcazou <ebotcazou@adacore.com>
7962
7963 PR ada/47131
7964 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
7965 variables that are referenced in exception handlers volatile.
7966
7967
7968\f
7969Copyright (C) 2011 Free Software Foundation, Inc.
7970
7971Copying and distribution of this file, with or without modification,
7972are permitted in any medium without royalty provided the copyright
7973notice and this notice are preserved.
7974
7975 * gnat_rm.texi: Ramification of pragma Eliminate documentation
7976 - fix bugs in the description of Source_Trace;
7977 - get rid of UNIT_NAME;
7978
4fbad0ba
AC
79792011-08-02 Javier Miranda <miranda@adacore.com>
7980
7981 * exp_ch9.adb
7982 (Build_Dispatching_Requeue): Adding support for VM targets
7983 since we cannot directly reference the Tag entity.
7984 * exp_sel.adb (Build_K): Adding support for VM targets.
7985 (Build_S_Assignment): Adding support for VM targets.
7986 * exp_disp.adb
7987 (Default_Prim_Op_Position): In VM targets do not restrict availability
7988 of predefined interface primitives to compiling in Ada 2005 mode.
7989 (Is_Predefined_Interface_Primitive): In VM targets this service is not
7990 restricted to compiling in Ada 2005 mode.
7991 (Make_VM_TSD): Generate code that declares and initializes the OSD
7992 record. Needed to support dispatching calls through synchronized
7993 interfaces.
7994 * exp_ch3.adb
7995 (Make_Predefined_Primitive_Specs): Enable generation of predefined
7996 primitives associated with synchronized interfaces.
7997 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
7998 primitives associated with synchronized interfaces.
7999
80002011-08-02 Yannick Moy <moy@adacore.com>
8001
8002 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
8003 statements hidden in SPARK if preceded by the HIDE directive
8004 (Parse_Exception_Handlers): mark each exception handler in a sequence of
8005 exception handlers as hidden in SPARK if preceded by the HIDE directive
8006 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
8007 if starting with the HIDE directive
8008 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
8009 starting with the HIDE directive; mark the declarations in a private
8010 part as hidden in SPARK if the private part starts with the HIDE
8011 directive
8012 * restrict.adb, restrict.ads
8013 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
8014 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
8015 argument node belongs to a part which is hidden in SPARK
8016 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
8017 parts in SPARK; protect the possibly costly call to
8018 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
8019 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
8020 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
8021 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
8022 Tok_SPARK_Hide.
8023 (Scan): recognize special comment starting with '#' and followed by
8024 SPARK keyword "hide" as a HIDE directive.
8025
80262011-08-02 Yannick Moy <moy@adacore.com>
8027
8028 * types.ads, erroutc.ads: Minor reformatting.
8029
80302011-08-02 Vincent Celier <celier@adacore.com>
8031
8032 * link.c: Add response file support for cross platforms.
8033
6ff6152d
ES
80342011-08-02 Ed Schonberg <schonberg@adacore.com>
8035
8036 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
8037 in an association, set parent field of copy before partial analysis.
8038 * sem_res.adb (Resolve_Slice): create reference to itype only when
8039 expansion is enabled.
8040
975c6896
YM
80412011-08-02 Yannick Moy <moy@adacore.com>
8042
8043 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
8044 for new flag denoting which subprogram bodies are in ALFA
8045 * restrict.adb, sem_ch7.adb: Update comment
8046 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
8047 sem_ch9.adb, sem_res.adb: Add calls to
8048 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
8049 * sem_ch6.adb (Analyze_Function_Return): add calls to
8050 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
8051 middle of the body, and extended return.
8052 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
8053 False when missing return.
8054 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
8055 to True for subprograms whose spec is in ALFA. Remove later on the flag
8056 on the entity used for a subprogram body when there exists a separate
8057 declaration.
8058 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
8059 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
8060 False, otherwise do nothing.
8061
afc8324d
AC
80622011-08-02 Robert Dewar <dewar@adacore.com>
8063
8064 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
8065
80662011-08-02 Yannick Moy <moy@adacore.com>
8067
8068 * sem_ch4.ads: minor formatting.
8069
2ba431e5
YM
80702011-08-02 Yannick Moy <moy@adacore.com>
8071
8072 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
8073 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
8074 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
8075 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
8076 opt.ads: cleanup of SPARK mode
8077
0f853035
YM
80782011-08-02 Yannick Moy <moy@adacore.com>
8079
8080 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
8081 types.
8082 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
8083 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
8084 * sem_ch3.adb
8085 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
8086 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
8087 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
8088 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
8089 types.
8090 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
8091 non-static range.
8092 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
8093 functions whose return type is not in ALFA.
8094 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
8095 specifications.
8096 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
8097 parameter's type is not in ALFA.
8098 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
8099 types are in ALFA.
8100
d2b10647
ES
81012011-08-02 Ed Schonberg <schonberg@adacore.com>
8102
8103 * sem_ch6 (Analyze_Expression_Function): treat the function as
8104 Inline_Always, and introduce a subprogram declaration for it when it is
8105 not a completion.
8106 * inline.adb (Add_Inlined_Body): recognize bodies that come from
8107 expression functions, so that the back-end can determine whether they
8108 can in fact be inlined.
8109 * sem_util.adb (Is_Expression_Function): predicate to determine whether
8110 a function body comes from an expression function.
8111
c7b9d548
AC
81122011-08-02 Gary Dismukes <dismukes@adacore.com>
8113
8114 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
8115 null exclusions to test Can_Never_Be_Null on the anonymous access types
8116 of the formals rather than testing the formals themselves. Exclude this
8117 check in cases where the Old_Formal is marked as a controlling formal,
8118 to avoid issuing spurious errors for bodies completing dispatching
8119 operations (due to the flag not getting set on controlling access
8120 formals in body specs).
8121 (Find_Corresponding_Spec): When checking full and subtype conformance of
8122 subprogram bodies in instances, pass Designated and E in that order, for
8123 consistency with the expected order of the formals (New_Id followed by
8124 Old_Id).
8125
81262011-08-02 Robert Dewar <dewar@adacore.com>
8127
8128 * sem_ch8.adb: Minor reformatting.
8129
1138cf59
AC
81302011-08-02 Ed Schonberg <schonberg@adacore.com>
8131
8132 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
8133 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
8134 primitive operations of class-wide actuals.
8135
81362011-08-02 Javier Miranda <miranda@adacore.com>
8137
8138 * exp_atag.ads, exp_atag.adb
8139 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
8140 since its value is implicitly passed in argument Typ.
8141 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
8142 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
8143 Build_Common_Dispatching_Select_Statements.
8144
7b9db926
RD
81452011-08-02 Robert Dewar <dewar@adacore.com>
8146
8147 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
8148 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
8149 Minor reformatting.
8150
e8374e7a
AC
81512011-08-02 Robert Dewar <dewar@adacore.com>
8152
8153 * sem_res.adb: Minor reformatting.
8154 * sem_prag.adb: Minor reformatting.
8155
81562011-08-02 Javier Miranda <miranda@adacore.com>
8157
8158 * exp_atag.adb, exp_atags.ads
8159 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
8160 by the tagged type Entity. Required to use this routine in the VM
8161 targets since we do not have available the Tag entity in the VM
8162 platforms.
8163 * exp_ch6.adb
8164 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
8165 Ada.Tags has not been previously loaded.
8166 * exp_ch7.adb
8167 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
8168 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
8169 * sem_aux.adb
8170 (Enclosing_Dynamic_Scope): Add missing support to handle the full
8171 view of enclosing scopes. Required to handle enclosing scopes that
8172 are synchronized types whose full view is a task type.
8173 * exp_disp.adb
8174 (Build_VM_TSDs): Minor code improvement to avoid generating and
8175 analyzing lists with empty nodes.
8176 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
8177 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
8178 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
8179 (Make_Disp_Timed_Select_Body): Add support for VM targets.
8180 (Make_Select_Specific_Data_Table): Add support for VM targets.
8181 (Make_VM_TSD): Generate code to initialize the SSD structure of
8182 the TSD.
8183
81842011-08-02 Yannick Moy <moy@adacore.com>
8185
8186 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
8187 cross-references section in ALI.
8188 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
8189 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
8190 Sub).
8191 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
8192 subprogram or package entity of a node
8193 (Is_Local_Reference_Type): new function returns True for references
8194 selected in local cross-references.
8195 (Lt): function extracted from Lt in Output_References
8196 (Write_Entity_Name): function extracted from Output_References
8197 (Generate_Definition): generate reference with type 'D' for definition
8198 of objects (object declaration and parameter specification), with
8199 appropriate locations and units, for use in local cross-references.
8200 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
8201 references of type 'I' for initialization in object definition.
8202 (Output_References): move part of function Lt and procedure
8203 Write_Entity_Name outside of the body. Ignore references of types 'D'
8204 and 'I' introduced for local cross-references.
8205 (Output_Local_References): new procedure to output the local
8206 cross-references sections.
8207 (Lref_Entity_Status): new array defining whether an entity is a local
8208 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
8209 with 'I' type when initialization expression is present.
8210 * get_scos.adb, get_scos.ads: Correct comments and typos
8211
1f6439e3
AC
82122011-08-02 Javier Miranda <miranda@adacore.com>
8213
8214 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
8215 the JVM target.
8216 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
8217 the JVM target.
8218 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
8219 TSD support.
8220
82212011-08-02 Vincent Celier <celier@adacore.com>
8222
8223 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
8224 (No_Space_Img): New function
8225 (Find_Excluded_Sources): When reading from a file, record the file name
8226 and the line number for each excluded source.
8227 (Mark_Excluded_Sources): When reporting an error, if the excluded
8228 sources were read from a file, include file name and line number in
8229 the error message.
8230
82312011-08-02 Ed Schonberg <schonberg@adacore.com>
8232
8233 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
8234
ab027d28
RD
82352011-08-02 Robert Dewar <dewar@adacore.com>
8236
8237 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
8238
b3b28b0c
JM
82392011-08-02 Javier Miranda <miranda@adacore.com>
8240
8241 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
8242 generation of TSDs to the DOTNET compiler.
8243 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
8244 generation of TSDs to the DOTNET compiler.
8245
9732e886
JM
82462011-08-02 Javier Miranda <miranda@adacore.com>
8247
8248 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
8249 record of all the tagged types declared inside library level package
8250 declarations, library level package bodies or library level subprograms.
8251 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
8252 associated with a given tagged type.
8253 (Build_VM_TSDs): New subprogram.
8254 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
8255 compilation units that are subprograms.
8256 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
8257 compilation units that are package bodies.
8258 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
8259 units that are a package declaration or a package instantiation.
8260 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
8261 reorganization to improve the error generated by the frontend when the
8262 function Ada.Tags.Secondary_Tag is not available.
8263 * rtsfind.ads (RE_Register_TSD): New runtime entity.
8264 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
8265
e526d0c7
AC
82662011-08-02 Javier Miranda <miranda@adacore.com>
8267
8268 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
8269
82702011-08-02 Robert Dewar <dewar@adacore.com>
8271
8272 * s-imenne.ads: Minor reformatting.
8273
82742011-08-02 Robert Dewar <dewar@adacore.com>
8275
8276 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
8277 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
8278 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
8279
82802011-08-02 Robert Dewar <dewar@adacore.com>
8281
8282 * einfo.ads (Materialize_Entity): Document this is only for renamings
8283 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
8284 required debug information in the case where we transform the object
8285 declaration into a renaming declaration.
8286 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
8287 object
8288 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
8289 Materialize_Entity.
8290
5b1e6aca
RD
82912011-08-02 Robert Dewar <dewar@adacore.com>
8292
8293 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
8294 Suppress_Init_Procs.
8295 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
8296 Suppress_Initialization/Initialization_Suppressed.
8297 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
8298 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
8299 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
8300 * sem_prag.adb: New processing for pragma Suppress_Initialization.
8301
5ad4969d
RD
83022011-08-02 Robert Dewar <dewar@adacore.com>
8303
8304 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
8305 Minor reformatting.
8306
8c4ee6f5
AC
83072011-08-02 Ed Schonberg <schonberg@adacore.com>
8308
8309 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
8310 only have inheritable classwide pre/postconditions.
8311
83122011-08-02 Javier Miranda <miranda@adacore.com>
8313
8314 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
8315 * rtsfind.ads (RE_Check_TSD): New runtime entity.
8316 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
8317 checks if the external tag of a type is the same as the external tag
8318 of some other declaration.
8319
0b3d16c0
AC
83202011-08-02 Thomas Quinot <quinot@adacore.com>
8321
8322 * s-taskin.ads: Minor reformatting.
8323
83242011-08-02 Emmanuel Briot <briot@adacore.com>
8325
8326 * g-comlin.adb (Display_Help): swap the order in which it prints the
8327 short help and the general usage.
8328
83292011-08-02 Ed Schonberg <schonberg@adacore.com>
8330
8331 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
8332 the aspect declarations and attach them to the generic copy for
8333 subsequent analysis.
8334 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
8335 declarations of the generic tree to the new subprogram declarations.
8336 * sem_attr.adb (Check_Precondition_Postcondition): recognize
8337 conditions that apply to a subprogram instance.
8338
83392011-08-02 Robert Dewar <dewar@adacore.com>
8340
8341 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
8342
83432011-08-02 Ed Schonberg <schonberg@adacore.com>
8344
8345 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
8346 private type with a tagged full view is not derived in the immediate
8347 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
8348
4637729f
AC
83492011-08-02 Robert Dewar <dewar@adacore.com>
8350
8351 * exp_ch4.adb: Minor reformatting.
8352
83532011-08-02 Ed Schonberg <schonberg@adacore.com>
8354
8355 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
8356 Ada2012 iterator, the loop will be rewritten during expansion into a
8357 while loop with a cursor and an element declaration. Do not analyze the
8358 body in this case, because if the container is for indefinite types the
8359 actual subtype of the elements will only be determined when the cursor
8360 declaration is analyzed.
8361
83622011-08-02 Arnaud Charlet <charlet@adacore.com>
8363
8364 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
8365 size/alignment related attributes in CodePeer_Mode.
8366
83672011-08-02 Gary Dismukes <dismukes@adacore.com>
8368
8369 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
8370 Prepend_Element, since this can result in the operation getting the
8371 wrong slot in the full type's dispatch table if the full type has
8372 inherited operations. The incomplete type's operation will get added
8373 to the proper position in the full type's primitives
8374 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
8375 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
8376 dispatching operations, since there are cases where nonprimitive
8377 subprograms can get added to the list of incomplete dependents (such
8378 as subprograms in nested packages).
8379 * sem_ch6.adb (Process_Formals): First, remove test for being in a
8380 private part when determining whether to add a primitive with a
8381 parameter of a tagged incomplete type to the Private_Dependents list.
8382 Such primitives can also occur in the visible part, and should not have
8383 been excluded from being private dependents.
8384 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
8385 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
8386 list of a Taft-amendment incomplete type is a primitive before issuing
8387 an error that the full type must appear in the same unit. There are
8388 cases where nonprimitives can be in the list (such as subprograms in
8389 nested packages).
8390 * sem_disp.adb (Derives_From): Use correct condition for checking that
8391 a formal's type is derived from the type of the corresponding formal in
8392 the parent subprogram (the condition was completely wrong). Add
8393 checking that was missing for controlling result types being derived
8394 from the result type of the parent operation.
8395
4c60de0c
YM
83962011-08-02 Yannick Moy <moy@adacore.com>
8397
8398 * errout.adb (First_Node): minor renaming
8399 * restrict.adb (Check_Formal_Restriction): put restriction warning on
8400 first node.
8401
f5afb270
AC
84022011-08-02 Yannick Moy <moy@adacore.com>
8403
8404 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
8405 before accessing operands.
8406 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
8407 decide whether an initialization expression respects SPARK rules, as
8408 the plain node is the expanded one. This allows for more valid warnings
8409 to be issued.
8410 * gnat_rm.texi: Minor update.
8411
84122011-08-02 Arnaud Charlet <charlet@adacore.com>
8413
8414 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
8415 previous change.
8416
84172011-08-02 Robert Dewar <dewar@adacore.com>
8418
8419 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
8420
84212011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
8422
8423 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
8424 loop statements and the element renaming declaration with a block when
8425 the element type is controlled.
8426
84272011-08-02 Yannick Moy <moy@adacore.com>
8428
8429 * sinfo.ads: Minor formatting.
8430
84312011-08-02 Ed Schonberg <schonberg@adacore.com>
8432
8433 * sem_aggr.adb (Add_Association): if the association has a box and no
8434 expression, use the Sloc of the aggregate itself for the new
8435 association.
8436 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
8437 the Original_Node.
8438
db72f10a
AC
84392011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
8440
8441 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
8442 When a container is provided via a function call, generate a renaming
8443 of the function result. This avoids the creation of a transient scope
8444 and the premature finalization of the container.
8445 * exp_ch7.adb (Is_Container_Cursor): Removed.
8446 (Wrap_Transient_Declaration): Remove the supression of the finalization
8447 of the list controller when the declaration denotes a container cursor,
8448 it is not needed.
8449
84502011-08-02 Yannick Moy <moy@adacore.com>
8451
8452 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
8453 node is from source, instead of the original node being from source.
8454 * sem_aggr.adb
8455 (Resolve_Array_Aggregate): refine the check for a static expression, to
8456 recognize also static ranges
8457 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
8458 Array_Type_Declaration): postpone the test for the type being a subtype
8459 mark after the type has been resolved, so that component-selection and
8460 expanded-name are discriminated.
8461 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
8462 to distinguish the case of an iteration scheme, so that an error is
8463 issed on a non-static range in SPARK except in an iteration scheme.
8464 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
8465 In_Iter_Schm = True.
8466 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
8467 user-defined operators so that they are allowed in renaming
8468 * sem_ch8.adb
8469 (Find_Selected_Component): refine the check for prefixing of operators
8470 so that they are allowed in renaming. Move the checks for restrictions
8471 on selector name after analysis discriminated between
8472 component-selection and expanded-name.
8473 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
8474 concatenation argument of string type if it is static.
8475 * sem_util.adb, sem_util.ads
8476 (Check_Later_Vs_Basic_Declarations): add a new function
8477 Is_Later_Declarative_Item to decice which declarations are allowed as
8478 later items, in the two different modes Ada 83 and SPARK. In the SPARK
8479 mode, add that renamings are considered as later items.
8480 (Enclosing_Package): new function to return the enclosing package
8481 (Enter_Name): correct the rule for homonyms in SPARK
8482 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
8483 from source (result of expansion) to avoid issuing wrong warnings.
8484
84852011-08-02 Ed Schonberg <schonberg@adacore.com>
8486
8487 * errout.adb: On anything but an expression First_Node returns its
8488 argument.
8489
23685ae6
AC
84902011-08-02 Pascal Obry <obry@adacore.com>
8491
8492 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
8493
84942011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
8495
8496 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
8497 Set the associated loop as the related expression of internally
8498 generated cursors.
8499 * exp_ch7.adb (Is_Container_Cursor): New routine.
8500 (Wrap_Transient_Declaration): Supress the finalization of the list
8501 controller when the declaration denotes a container cursor.
8502
85032011-08-02 Yannick Moy <moy@adacore.com>
8504
8505 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
8506 command line now.
8507 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
8508 expression is a simple expression. This check cannot be performed in
8509 the semantics, so just drop it.
8510 (P_Index_Or_Discriminant_Constraint): move check that the index or
8511 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
8512 semantics. Other cases were previously checked in the semantics.
8513 * par-ch4.adb (P_Name): move checks that a selector name is not
8514 character literal or an operator symbol to Find_Selected_Component in
8515 the semantics
8516 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
8517 declarations are not placed after later declarations in a separate
8518 procedure in Sem_Util (possibly not the best choice?), to be used both
8519 during parsing, for Ada 83 mode, and during semantic analysis, for
8520 SPARK mode.
8521 * par-endh.adb (Check_End): move check that end label is not missing
8522 to Process_End_Label in the semantics
8523 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
8524 the special case for SPARK restriction
8525 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
8526 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
8527 parameter Force to issue the error message even on internal node (used
8528 for generated end label). Call Check_Restriction to check when an error
8529 must be issued. In SPARK mode, issue an error message even if the
8530 restriction is not set.
8531 (Check_Restriction): new procedure with an additional out parameter to
8532 inform the caller that a message has been issued
8533 * sem_aggr.adb: Minor modification of message
8534 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
8535 instead of issuing an error message directly
8536 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
8537 declarations are not placed after later declarations, by calling
8538 Check_Later_Vs_Basic_Declarations
8539 (Analyze_Subtype_Declaration): move here the check that an index or
8540 discriminant constraint must be a subtype mark. Change the check that
8541 a subtype of String must start at one so that it works on subtype marks.
8542 * sem_ch4.adb (Analyze_Call): move here the check that a named
8543 association cannot follow a positional one in a call
8544 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
8545 instead of issuing an error message directly
8546 * sem_ch8.adb (Find_Selected_Component): move here the check that a
8547 selector name is not a character literal or an operator symbol. Move
8548 here the check that the prefix of an expanded name cannot be a
8549 subprogram or a loop statement.
8550 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
8551 procedure called from parsing and semantics to check that basic
8552 declarations are not placed after later declarations
8553 (Process_End_Label): move here the check that end label is not missing
8554
85552011-08-02 Arnaud Charlet <charlet@adacore.com>
8556
8557 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
8558 representation clause in codepeer mode, since it confuses CodePeer and
8559 does not bring useful info.
8560
85612011-08-02 Ed Falis <falis@adacore.com>
8562
8563 * init.c: initialize fp hw on MILS.
8564
85652011-08-02 Ed Schonberg <schonberg@adacore.com>
8566
8567 * errout.adb (First_Node): for bodies, return the node itself (small
8568 optimization). For other nodes, do not check source_unit if the node
8569 comes from Standard.
8570
d2d9cc22
AC
85712011-08-02 Robert Dewar <dewar@adacore.com>
8572
8573 * exp_ch3.adb: Minor comment additions.
8574 * sem_ch13.adb: Minor reformatting.
8575
85762011-08-02 Pascal Obry <obry@adacore.com>
8577
8578 * make.adb, makeutl.adb: Removes some superfluous directory separator.
8579
a01b9df6
AC
85802011-08-02 Robert Dewar <dewar@adacore.com>
8581
8582 * sem_attr.adb: Minor reformatting.
8583
85842011-08-02 Robert Dewar <dewar@adacore.com>
8585
8586 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
8587 (Has_Default_Component_Value): Removed
8588 * einfo.ads Comment updates
8589 (Has_Default_Aspect): Replaces Has_Default_Value
8590 (Has_Default_Component_Value): Removed
8591 * exp_ch13.adb
8592 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
8593 * exp_ch3.adb
8594 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
8595 (Get_Simple_Init_Val): Handle Default_Value aspect
8596 (Needs_Simple_Initialization): Handle Default_Value aspect
8597 * exp_ch3.ads: Needs_Simple_Initialization
8598 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
8599 * par-prag.adb (Pragma_Default[_Component]Value) Removed
8600 * sem_ch13.adb
8601 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
8602 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
8603 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
8604
86052011-08-02 Ed Schonberg <schonberg@adacore.com>
8606
8607 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
8608 package containing iteration primitives.
8609 exp_ch5.adb (Expand_Iterator_Loop): ditto.
8610
75c90775
AC
86112011-08-02 Ed Schonberg <schonberg@adacore.com>
8612
8613 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
8614 "of", pre-analyze expression in case it is a function call with
8615 finalization actions that must be placed ahead of the loop.
8616 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
8617 on an Ada2012 iterator, insert them ahead of the rewritten loop.
8618
86192011-08-02 Geert Bosch <bosch@adacore.com>
8620
8621 * cstand.adb (Create_Float_Types): Only consider C's long double for
8622 Long_Long_Float, in addition to double.
8623
ded8909b
AC
86242011-08-02 Robert Dewar <dewar@adacore.com>
8625
8626 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
8627 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
8628 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
8629 Minor reformatting.
8630
86312011-08-02 Ed Schonberg <schonberg@adacore.com>
8632
8633 * sem_attr.adb: handle properly 'Result when it is a prefix of an
8634 indexed component.
8635
86362011-08-02 Javier Miranda <miranda@adacore.com>
8637
8638 * einfo.ads, einfo.adb
8639 (Original_Access_Type): Move this attribute to Node26 since there was
8640 an undocumented use of Node21 in E_Access_Subprogram_Type entities
8641 which causes conflicts and breaks the generation of the .NET compiler.
8642 (Interface_Name): Add missing documentation on JGNAT only uses of
8643 this attribute.
8644
70c34e1c
AC
86452011-08-02 Geert Bosch <bosch@adacore.com>
8646
8647 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
8648 (Find_Back_End_Float_Type): Likewise
8649 (Create_Back_End_Float_Types): Likewise
8650 (Create_Float_Types): Likewise
8651 (Register_Float_Type): Likewise
8652 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
8653 Nlist and split out type selection in new local Find_Base_Type function.
8654 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
8655 Nlist
8656 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
8657
86582011-08-02 Robert Dewar <dewar@adacore.com>
8659
8660 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
8661 alpha order).
8662 * opt.ads: Minor comment change.
8663 * sem_ch12.adb: Minor code reorganization.
8664
b715bc59
AC
86652011-08-02 Gary Dismukes <dismukes@adacore.com>
8666
8667 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
8668 subtype's list of rep items to the list on the full subtype in the case
8669 where the lists are the same.
8670
86712011-08-02 Geert Bosch <bosch@adacore.com>
8672
8673 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
8674 using the one from System.Strings, which also deallocates all strings.
8675
002bdd68
AC
86762011-08-02 Geert Bosch <bosch@adacore.com>
8677
8678 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
8679 function.
8680 * gcc-interface/Make-lang.in: Update dependencies.
8681
86822011-08-02 Olivier Hainque <hainque@adacore.com>
8683
8684 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
8685 end_locus.
8686
499769ec
AC
86872011-08-02 Javier Miranda <miranda@adacore.com>
8688
8689 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
8690 associated with anonymous access to subprograms.
8691
86922011-08-02 Geert Bosch <bosch@adacore.com>
8693
8694 * opt.ads
8695 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
8696 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
8697 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
8698 (Add_Symbol_Definition): Move to switch-c.adb
8699 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
8700 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
8701 (Add_Symbol_Definition): Move to switch-c.adb.
8702 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
8703 * sem_warn.adb
8704 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
8705 Move to warnsw.adb.
8706 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
8707 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
8708 Move to warnsw.adb.
8709 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
8710 (Add_Symbol_Definition): Moved from Prepcomp.
8711 * switch-c.ads: Update copyright notice. Use String_List instead of
8712 Argument_List, removing dependency on System.OS_Lib.
8713
aa1e353a
AC
87142011-08-02 Yannick Moy <moy@adacore.com>
8715
8716 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
8717 mode on initialization expression which does not respect SPARK
8718 restrictions.
8719 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
8720 if the tree referenced by its argument represents an initialization
8721 expression in SPARK, suitable for initializing an object in an object
8722 declaration.
8723
87242011-08-02 Javier Miranda <miranda@adacore.com>
8725
8726 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
8727 internally generated access to subprogram with its associated protected
8728 subprogram type.
8729 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
8730
15b682ca
GB
87312011-08-02 Geert Bosch <bosch@adacore.com>
8732
8733 * cstand.adb (Register_Float_Type): Print information about type to
8734 register, if the Debug_Flag_Dot_B is set.
8735 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
8736 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
8737 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
8738 with a requested precision of more than Max_Digits digits and no more
8739 than Max_Base_Digits digits, if a range specification is present and the
8740 Predefined_Float_Types list has a suitable type to derive from.
8741 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
8742 case of type completion with pragma Import
8743 * sem_prag.adb
8744 (Process_Import_Predefined_Type): Processing to complete a type
8745 with pragma Import. Currently supports floating point types only.
8746 (Set_Convention_From_Pragma): Do nothing without underlying type.
8747 (Process_Convention): Guard against absence of underlying type,
8748 which may happen when importing incomplete types.
8749 (Process_Import_Or_Interface): Handle case of importing predefined
8750 types. Tweak error message.
8751
f8726f2b
AC
87522011-08-02 Eric Botcazou <ebotcazou@adacore.com>
8753
8754 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
8755 functions to previous change. Reorganize code slightly.
8756
87572011-08-02 Geert Bosch <bosch@adacore.com>
8758
8759 * back_end.ads (Register_Type_Proc): New call back procedure type for
8760 allowing the back end to provide information about available types.
8761 (Register_Back_End_Types): New procedure to register back end types.
8762 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
8763 available types.
8764 * cstand.adb (Back_End_Float_Types): New list for floating point types
8765 supported by the back end.
8766 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
8767 (Copy_Float_Type): New procedure to make new copies of predefined types.
8768 (Register_Float_Type): New call back procedure to populate the BEFT list
8769 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
8770 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
8771 (Create_Float_Types): New procedure to create entities for floating
8772 point types predefined in Standard, and put these and any remaining
8773 BEFTs on the Predefined_Float_Types list.
8774 * stand.ads (Predefined_Float_Types): New list for predefined floating
8775 point types that do not have declarations in package Standard.
8776
feecad68
AC
87772011-08-02 Eric Botcazou <ebotcazou@adacore.com>
8778
8779 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
8780 entity node for the unit containing the parameter.
8781 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
8782 (Add_Inlined_Subprogram): Likewise.
8783 * gcc-interface/Make-lang.in: Update dependencies.
8784
87852011-08-02 Thomas Quinot <quinot@adacore.com>
8786
8787 * s-stusta.adb (Print): Make sure Pos is always initialized to a
8788 suitable value.
8789
12f0c50c
AC
87902011-08-02 Geert Bosch <bosch@adacore.com>
8791
8792 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
8793
87942011-08-02 Eric Botcazou <ebotcazou@adacore.com>
8795
8796 * sem_type.adb (Covers): Move trivial case to the top and reuse the
8797 computed value of Base_Type.
8798
87992011-08-02 Yannick Moy <moy@adacore.com>
8800
8801 * restrict.adb (Check_Restriction): issue an error for any use of
8802 class-wide, even if the No_Dispatch restriction is not set.
8803 * sem_aggr.adb: Correct typos in comments and messages in formal mode
8804 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
8805 when completing a private extension, the type named in the private part
8806 is not the same as that named in the visible part.
8807 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
8808 of an inherited primitive operations of a tagged type or type extension
8809 that returns the tagged type.
8810 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
8811 function which returns True for an implicit operation inherited by the
8812 derived type declaration for the argument type.
8813 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
8814 order.
8815
fb86fe11
ES
88162011-08-02 Ed Schonberg <schonberg@adacore.com>
8817
8818 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
8819 Process_Bounds, to perform analysis with expansion of a range or an
8820 expression that is the iteration scheme for a loop.
8821 (Analyze_Iterator_Specification): If domain of iteration is given by a
8822 function call with a controlled result, as is the case if call returns
8823 a predefined container, ensure that finalization actions are properly
8824 generated.
8825 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
8826
62be5d0a
JM
88272011-08-02 Javier Miranda <miranda@adacore.com>
8828
8829 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
8830 * gcc-interface/Make-lang.in: Update dependencies.
8831
88322011-08-02 Javier Miranda <miranda@adacore.com>
8833
8834 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
8835 determine if the analysis is performed using N or Original_Node (N).
8836 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
8837 functionality of routine Is_Variable avoids code duplication.
8838 * checks.adb (Determine_Range): Handle temporaries generated by
8839 Remove_Side_Effects.
8840
88412011-08-02 Javier Miranda <miranda@adacore.com>
8842
8843 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
8844 expansion of the condition. Required since the previous analysis was
8845 done with expansion disabled (see Resolve_Quantified_Expression) and
8846 hence checks were not inserted and record comparisons have not been
8847 expanded.
8848
a20f4389
AC
88492011-08-02 Ed Falis <falis@adacore.com>
8850
8851 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
8852 Update header.
8853
88542011-08-02 Bob Duff <duff@adacore.com>
8855
8856 * opt.ads: Minor comment fix.
8857
88582011-08-02 Bob Duff <duff@adacore.com>
8859
8860 * sem_ch12.adb (Analyze_Package_Instantiation,
8861 Analyze_Subprogram_Instantiation): Turn off style checking while
8862 analyzing an instance. Whatever style checks that apply to the generic
8863 unit should apply, so it makes no sense to apply them in an instance.
8864 This was causing trouble when compiling an instance of a runtime
8865 unit that violates the -gnatyO switch.
8866 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
8867 one of the two case statements, causing spurious errors.
8868
88692011-08-02 Robert Dewar <dewar@adacore.com>
8870
8871 * uname.adb: Minor reformatting.
8872 * gnatcmd.adb: Minor reformatting.
8873 * exp_attr.adb: Minor reformatting.
8874
90878b12
AC
88752011-08-02 Ed Schonberg <schonberg@adacore.com>
8876
8877 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
8878 No_Dispatching_Calls, do not look for the Assign primitive, because
8879 predefined primitives are not created in this case.
8880
88812011-08-02 Bob Duff <duff@adacore.com>
8882
8883 * stylesw.ads: Minor comment fixes.
8884
88852011-08-02 Robert Dewar <dewar@adacore.com>
8886
8887 * freeze.adb (Add_To_Result): New procedure.
8888
88892011-08-02 Jose Ruiz <ruiz@adacore.com>
8890
8891 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
8892 time, if the specific run-time routines for handling streams of strings
8893 are not available, use the default mechanism.
8894
88952011-08-02 Arnaud Charlet <charlet@adacore.com>
8896
8897 * s-regpat.ads: Fix typo.
8898
88992011-08-02 Vincent Celier <celier@adacore.com>
8900
8901 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
8902 not null, call it to create the in memory config project file without
8903 parsing an existing default config project file.
8904
89052011-08-02 Eric Botcazou <ebotcazou@adacore.com>
8906
8907 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
8908
89092011-08-02 Ed Schonberg <schonberg@adacore.com>
8910
8911 * sem_elim.adb: an abstract subprogram does not need an eliminate
8912 pragma for its descendant to be eliminable.
8913
89142011-08-02 Ed Falis <falis@adacore.com>
8915
8916 * init.c: revert to handling before previous checkin for VxWorks
8917 * s-intman-vxworks.adb: delete unnecessary declarations related to
8918 using Ada interrupt facilities for handling signals.
8919 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
8920 * s-intman-vxworks.ads: Import __gnat_install_handler as
8921 Initialize_Interrupts.
8922 * s-taprop-vxworks.adb: Delete Signal_Mask.
8923 (Abort_Handler): change construction of mask to unblock exception
8924 signals.
8925
273adcdf
AC
89262011-08-02 Jerome Guitton <guitton@adacore.com>
8927
8928 * a-except-2005.adb (Raise_From_Signal_Handler): Call
8929 Debug_Raise_Exception before propagation starts.
8930
89312011-08-02 Eric Botcazou <ebotcazou@adacore.com>
8932
8933 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
8934 to Restriction_Check_Required.
8935 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
8936 * sem_res.adb (Resolve_Call): Likewise.
8937 * sem_attr.adb (Check_Stream_Attribute): Likewise.
8938
89392011-08-02 Bob Duff <duff@adacore.com>
8940
8941 * stylesw.ads: Update comment.
8942 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
8943 * errout.ads: Remove obsolete comment.
8944
89452011-08-02 Javier Miranda <miranda@adacore.com>
8946
8947 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
8948 (Set_Is_Safe_To_Reevaluate): new procedure.
8949 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
8950 assignment is allowed on safe-to-reevaluate variables.
8951 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
8952 temporary created to remove side effects in expressions that use
8953 the secondary stack as safe-to-reevaluate.
8954 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
8955 variables that are not true constants.
8956
6320f5e1
AC
89572011-08-02 Robert Dewar <dewar@adacore.com>
8958
8959 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
8960 sem_res.adb, sem_ch6.adb: Minor reformatting.
8961
89622011-08-02 Jerome Guitton <guitton@adacore.com>
8963
8964 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
8965
2fe829ae
ES
89662011-08-02 Ed Schonberg <schonberg@adacore.com>
8967
8968 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
8969 not set Overridden_Operation if subprogram is an initialization
8970 procedure.
8971
e24329cd
YM
89722011-08-02 Yannick Moy <moy@adacore.com>
8973
8974 * par-ch6.adb: Correct obsolete name in comments
8975 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
8976 which takes two message arguments (existing function takes one), with
8977 second message used for continuation.
8978 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
8979 block statements that originate from a source block statement, not
8980 generated block statements
8981 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
8982 symmetry with procedure case
8983 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
8984 function to issue an error in formal mode if a package specification
8985 contains more than one tagged type or type extension.
8986 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
8987 parameters matching formals of tagged types are objects (or ancestor
8988 type conversions of objects), not general expressions. Issue an error
8989 on view conversions that are not involving ancestor conversion of an
8990 extended type.
8991 (Resolve_Type_Conversion): in formal mode, issue an error on the
8992 operand of an ancestor type conversion which is not an object
8993 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
8994 procedure so that it works also for actuals of function calls
8995 (Is_Actual_Tagged_Parameter): new function which determines if its
8996 argument is an actual parameter of a formal of tagged type in a
8997 subprogram call
8998 (Is_SPARK_Object_Reference): new function which determines if the tree
8999 referenced by its argument represents an object in SPARK
9000
176dadf6
AC
90012011-08-02 Robert Dewar <dewar@adacore.com>
9002
9003 * sem_ch3.adb: Minor reformatting
9004 Minor comment addition
9005 Minor error msg text change
9006
90072011-08-02 Javier Miranda <miranda@adacore.com>
9008
9009 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
9010 function. Used to be more precise when we generate a variable plus one
9011 assignment to remove side effects in the evaluation of the Bound
9012 expressions.
9013 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
9014 of the bound expression to force its re-analysis and thus expand the
9015 associated transient scope (if required). Code cleanup replacing the
9016 previous code that declared the constant entity by an invocation to
9017 routine Force_Evaluation which centralizes this work in the frontend.
9018
d8b962d8
AC
90192011-08-02 Robert Dewar <dewar@adacore.com>
9020
9021 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
9022 (Base_Type): Now uses improved Is_Base_Type function
9023 * einfo.ads (Base_Type): Inline this function
9024
90252011-08-02 Robert Dewar <dewar@adacore.com>
9026
9027 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
9028 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
9029
90302011-08-02 Arnaud Charlet <charlet@adacore.com>
9031
9032 * gcc-interface/Make-lang.in: Update dependencies.
9033 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
9034 targets.
9035
90362011-08-02 Yannick Moy <moy@adacore.com>
9037
9038 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
9039 non-simple expression used in delta constraint
9040 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
9041 index constraint which is not a subtype mark
9042 * par.adb: With and use Restrict
9043 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
9044 mode on component type which is not a subtype mark and default
9045 expression on component
9046 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
9047 of string which does not have a lower index bound equal to 1
9048 (Array_Type_Declaration): issue an error in formal mode on index or
9049 component type which is not a subtype mark, and on aliased keyword on
9050 component
9051 (Derived_Type_Declaration): issue an error in formal mode on interface,
9052 limited or abstract type
9053 (Record_Type_Declaration): issue an error in formal mode on interface
9054 (Record_Type_Definition): issue an error in formal mode on tagged types
9055 and type extensions not declared in the specification of a library unit
9056 package; on null non-tagged record; on variant part
9057
90582011-08-02 Vincent Celier <celier@adacore.com>
9059
9060 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
9061 not declared for qualified library project when Library_Name is not
9062 declared, but Library_Dir is.
9063
90642011-08-02 Robert Dewar <dewar@adacore.com>
9065
9066 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
9067 pragmas (affects aspects [Component_]Default_Value
9068 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
9069 component type for the resolution
9070
f96b2d85
AC
90712011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9072
9073 * einfo.adb (Base_Type): Tune implementation for speed.
9074
90752011-08-02 Robert Dewar <dewar@adacore.com>
9076
9077 * freeze.adb: Minor reformatting.
9078
8b3c6430
AC
90792011-08-02 Thomas Quinot <quinot@adacore.com>
9080
9081 * scos.ads: Update comments.
9082
90832011-08-02 Ed Schonberg <schonberg@adacore.com>
9084
9085 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
9086 base type, because the parent may be a subtype of a private type whose
9087 convention is established in a private part.
9088
90892011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
9090
9091 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
9092 statement in a block when the expansion of the return expression has
9093 created a finalization chain.
9094 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
9095 with the parent node.
9096 Add N_Extended_Return_Statement to handle the case where a transient
9097 object declaration appears in the Return_Object_Declarations list of
9098 an extended return statement.
9099
91002011-08-02 Matthew Gingell <gingell@adacore.com>
9101
9102 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
9103 unused parameter 'name'.
9104
91052011-08-02 Ed Schonberg <schonberg@adacore.com>
9106
9107 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
9108 inherited operation, check whether its alias, which is the source
9109 operastion that it renames, has been marked eliminated.
9110
cae81f17
JM
91112011-08-02 Javier Miranda <miranda@adacore.com>
9112
9113 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
9114 in-mode parameter whose type is an access type since it can be used to
9115 modify its designated object. Enforce code that handles as safe an
9116 access type that is not access-to-constant but it is the result of a
9117 previous removal of side-effects.
9118 (Remove_Side_Effects): Minor code reorganization of cases which require
9119 no action. Done to incorporate documentation on new cases uncovered
9120 working in this ticket: no action needed if this routine was invoked
9121 too early and the nodes are not yet decorated.
9122 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
9123 to routine Remove_Side_Effects by calls to Force_Evaluation since they
9124 were issued with actuals that are implicitly provided by
9125 Force_Evaluation.
9126
218e6dee
RD
91272011-08-02 Robert Dewar <dewar@adacore.com>
9128
9129 * sem_ch3.adb, sem_res.adb: Minor reformatting.
9130
7a489a2b
AC
91312011-08-02 Yannick Moy <moy@adacore.com>
9132
9133 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
9134 to issue an error in formal mode on attribute not supported in this mode
9135 (Analyze_Attribute): issue errors on standard attributes not supported
9136 in formal mode.
9137 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
9138 comment, and issue error in formal mode on modulus which is not a power
9139 of 2.
9140 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
9141 range.
9142 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
9143 subtype mark.
9144 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
9145 operator on modular type (except 'not').
9146
91472011-08-02 Robert Dewar <dewar@adacore.com>
9148
9149 * gnat_rm.texi: Minor reformatting.
9150
cb7fa356
AC
91512011-08-02 Arnaud Charlet <charlet@adacore.com>
9152
9153 * s-osinte-linux.ads: Minor comment update and reformatting.
9154 * i-cexten.ads: Make this unit pure, as for its parent.
9155 Will allow its usage in more contexts if needed.
9156
91572011-08-02 Robert Dewar <dewar@adacore.com>
9158
9159 * s-utf_32.ads: Minor comment fix.
9160
91612011-08-02 Ed Schonberg <schonberg@adacore.com>
9162
9163 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
9164 operation of a tagged synchronized type, handle the case where the
9165 controlling argument is overloaded.
9166
91672011-08-02 Yannick Moy <moy@adacore.com>
9168
9169 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
9170 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
9171 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
9172 SPARK mode and formal verification mode on processing SPARK restriction
9173 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
9174 requiring consistency checking.
9175
5cc9353d
RD
91762011-08-02 Robert Dewar <dewar@adacore.com>
9177
9178 * sem_res.adb: Minor reformatting.
9179
e51537ff
RD
91802011-08-02 Robert Dewar <dewar@adacore.com>
9181
9182 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
9183 a-cforse.ads: Remove unneeded with of Ada.Containers
9184 Remove commented out pragma Inline's
9185 Move specifications of new subprograms to the actual specs
9186
83fa09c5
AC
91872011-08-02 Yannick Moy <moy@adacore.com>
9188
9189 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
9190 a-cforse.ads: Update comments.
9191
91922011-08-02 Ed Schonberg <schonberg@adacore.com>
9193
9194 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
9195
d11cfaf8
RD
91962011-08-02 Robert Dewar <dewar@adacore.com>
9197
9198 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
9199 a-cforse.ads, a-cofove.ads: Minor reformatting.
9200
300b98bb
AC
92012011-08-02 Claire Dross <dross@adacore.com>
9202
9203 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
9204 a-cofove.ads: Add comments.
9205
92062011-08-02 Yannick Moy <moy@adacore.com>
9207
9208 * gnat_rm.texi: Document formal containers.
9209
92102011-08-02 Emmanuel Briot <briot@adacore.com>
9211
9212 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
9213 are empty sections.
9214
19fb051c
AC
92152011-08-02 Robert Dewar <dewar@adacore.com>
9216
9217 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
9218 reformatting.
9219
92202011-08-02 Robert Dewar <dewar@adacore.com>
9221
9222 * aspects.adb: New aspects Default_Value and Default_Component_Value
9223 New format of Aspect_Names table checks for omitted entries
9224 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
9225 handling of boolean aspects for derived types.
9226 New aspects Default_Value and Default_Component_Value
9227 New format of Aspect_Names table checks for omitted entries
9228 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
9229 (Has_Default_Value): New flag
9230 (Has_Default_Component_Value): New flag
9231 (Has_Default_Value): New flag
9232 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
9233 table.
9234 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
9235 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
9236 Default_Value and Default_Component_Value
9237 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
9238 New aspects Default_Value and Default_Component_Value
9239 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
9240 * sprint.adb: Print N_Aspect_Specification node when called from gdb
9241
92422011-08-02 Vincent Celier <celier@adacore.com>
9243
9244 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
9245 inherit library kind.
9246
92472011-08-02 Ed Schonberg <schonberg@adacore.com>
9248
9249 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
9250 Minor reformatting.
9251
92522011-08-02 Robert Dewar <dewar@adacore.com>
9253
9254 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
9255
5f7747af
AC
92562011-08-02 Yannick Moy <moy@adacore.com>
9257
9258 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
9259
92602011-08-02 Robert Dewar <dewar@adacore.com>
9261
9262 * impunit.adb: Add comment.
9263
a5fe697b
AC
92642011-08-02 Yannick Moy <moy@adacore.com>
9265
9266 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
9267 qualification of aggregates in formal mode
9268 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
9269 another aggregate
9270 (Resolve_Aggregate): complete the test that an aggregate is adequately
9271 qualified in formal mode
9272
92732011-08-02 Pascal Obry <obry@adacore.com>
9274
9275 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
9276 * mlib-prj.adb: Supress warning when compiling binder generated file.
9277 (Build_Library): Supress all warnings when compiling the binder
9278 generated file.
9279
bd65a2d7 92802011-08-02 Yannick Moy <moy@adacore.com>
d4487611 9281
bd65a2d7
AC
9282 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
9283 from here...
9284 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
9285 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
9286 Add with/use clauses to make Check_Formal_Restriction visible
9287
92882011-08-02 Ed Schonberg <schonberg@adacore.com>
9289
9290 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
9291 in-parameters when type of the generic formal is private in the generic
9292 spec and non-private in the body.
9293
92942011-08-02 Claire Dross <dross@adacore.com>
9295
9296 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
9297 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
9298 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
9299 * impunit.adb, Makefile.rtl: Take new files into account.
d4487611
AC
9300
93012011-08-02 Robert Dewar <dewar@adacore.com>
9302
9303 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
9304 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
9305
bd434b3f
YM
93062011-08-02 Yannick Moy <moy@adacore.com>
9307
9308 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
9309 formal mode
9310 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
9311 matching static array bounds, taking into account the special case of
9312 string literals
9313 * sem_ch3.adb: Typo in comment.
9314
fe5d3068
YM
93152011-08-02 Yannick Moy <moy@adacore.com>
9316
9317 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
9318 which issues an error in formal mode if its argument node is originally
9319 from source
9320 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
9321 has a discriminant specification so that it does not include the case
9322 of derived types
9323 (Derived_Type_Declaration): move here the test that a derived type has a
9324 discriminant specification
9325 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
9326 first element of a component association before accessing its choices
9327 (presence of component association is not enough)
9328 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
9329 declaration is a library item before accessing the next element in a
9330 list, as library items are not member of lists
9331 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
9332 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
9333 Check_Formal_Restriction whenever possible.
9334
b60a3f26
AC
93352011-08-02 Ed Schonberg <schonberg@adacore.com>
9336
9337 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
9338 reference when needed.
9339
93402011-08-02 Bob Duff <duff@adacore.com>
9341
9342 * gnat_ugn.texi: Fix typo.
9343
93442011-08-02 Vincent Celier <celier@adacore.com>
9345
9346 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
9347 archive file name. Do not use the full path name of archives for Open
9348 VMS.
9349
eaba57fb
RD
93502011-08-02 Robert Dewar <dewar@adacore.com>
9351
9352 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
9353 Analyze_Aspect_Specifications
9354 * sem_ch13.adb
9355 (Analyze_Aspect_Specifications): New handling for boolean aspects
9356 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
9357 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
9358 sequence for Analyze_Aspect_Specifications
9359 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
9360 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
9361
93622011-08-02 Robert Dewar <dewar@adacore.com>
9363
9364 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
9365 aspects, since these no longer exist.
9366
93672011-08-02 Robert Dewar <dewar@adacore.com>
9368
9369 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
9370 semicolon, do not try to see if there are aspects following it.
9371 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
9372 aspect spec.
9373
8830d1d2
AC
93742011-08-02 Robert Dewar <dewar@adacore.com>
9375
9376 * sem_ch8.adb, aspects.ads: Minor reformatting.
9377
93782011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9379
9380 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
9381 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
9382 extracted from...
9383 (Analyze_Aspect_Specifications): ...here. Call above procedure.
9384
7ff2d234
AC
93852011-08-02 Yannick Moy <moy@adacore.com>
9386
9387 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
9388 mode on subprogram declaration outside of package specification, unless
9389 it is followed by a pragma Import
9390 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
9391 Access_Type_Declaration): issue error in formal mode on access type
9392 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
9393 incomplete type
9394 (Analyze_Object_Declaration): issue error in formal mode on object
9395 declaration which does not respect SPARK restrictions
9396 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
9397 declaration which does not respect SPARK restrictions
9398 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
9399 error in formal mode on digits or delta constraint
9400 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
9401 decimal fixed point type
9402 (Derived_Type_Declaration): issue error in formal mode on derived type
9403 other than type extensions of tagged record types
9404 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
9405 with check on access definition
9406 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
9407 mode on protected definition.
9408 (Analyze_Task_Definition): issue error in formal mode on task definition
9409
94102011-08-02 Robert Dewar <dewar@adacore.com>
9411
9412 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
9413
806f6d37
AC
94142011-08-02 Javier Miranda <miranda@adacore.com>
9415
9416 * sem_ch6.adb (Can_Override_Operator): New function.
9417 (Verify_Overriding_Indicator): Add missing code to check overriding
9418 indicator in operators. Fixes regression.
9419 (Check_Overriding_Indicator): Minor reformating after replacing the
9420 code that evaluates if the subprogram can override an operator by
9421 invocations to the above new function.
9422 * einfo.adb
9423 (Write_Field26_Name): Add missing code to ensure that, following
9424 the documentation in einfo.ads, this field is not shown as attribute
9425 "Static_Initialization" on non-dispatching functions.
9426
94272011-08-02 Jose Ruiz <ruiz@adacore.com>
9428
9429 * sem_res.adb (Resolve_Call): A call to
9430 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
9431 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
9432 i.e., when the second parameter is of type Time_Span.
9433
94342011-08-02 Vincent Celier <celier@adacore.com>
9435
9436 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
9437 with an archive instead of -L<library dir> -l<library name>.
9438
94392011-08-02 Ed Schonberg <schonberg@adacore.com>
9440
9441 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
9442 mark the base types In_Use in addition to making the operations
9443 use_visible.
9444
94452011-08-02 Ed Falis <falis@adacore.com>
9446
9447 * init.c: add and setup __gnat_signal_mask for the exception signals
9448 * s-inmaop-vxworks.adb: new file.
9449 * s-intman-vxworks.adb: remove unnecessary initializations and
9450 simplify remaining
9451 * s-intman-vxworks.ads: remove unnecessary variable
9452 * s-taprop-vxworks.adb: simplify signal initialization
9453
780d052e
RD
94542011-08-02 Robert Dewar <dewar@adacore.com>
9455
9456 * sem_ch8.adb: Minor code reorganization, comment updates.
9457
94582011-08-02 Robert Dewar <dewar@adacore.com>
9459
9460 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
9461 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
9462 here from Sem_Res.
9463 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
9464 (Matching_Static_Array_Bounds): Moved here from Sem_Res
9465
29efbb8c
ES
94662011-08-02 Ed Schonberg <schonberg@adacore.com>
9467
9468 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
9469 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
9470 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
9471 use_type_clauses, to handle more efficiently use_type and use_all_type
9472 constructs.
9473 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
9474 Ada2012 Use_All_Type clause.
9475 (Use_Class_Wide_Operations): new procedure.
9476
b0186f71
AC
94772011-08-02 Robert Dewar <dewar@adacore.com>
9478
9479 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
9480 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
9481 expression to expression function.
9482
94832011-08-02 Ed Schonberg <schonberg@adacore.com>
9484
9485 * sem_ch4.adb: transform simple Ada2012 membership into equality only
9486 if types are compatible.
9487
94882011-08-02 Yannick Moy <moy@adacore.com>
9489
9490 * sem_res.adb (Matching_Static_Array_Bounds): new function which
9491 returns True if its argument array types have same dimension and same
9492 static bounds at each index.
9493 (Resolve_Actuals): issue an error in formal mode on actuals passed as
9494 OUT or IN OUT paramaters which are not view conversions in SPARK.
9495 (Resolve_Arithmetic_Op): issue an error in formal mode on
9496 multiplication or division with operands of fixed point types which are
9497 not qualified or explicitly converted.
9498 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
9499 Boolean or array type (except String) operands.
9500 (Resolve_Equality_Op): issue an error in formal mode on equality
9501 operators for array types other than String with non-matching static
9502 bounds.
9503 (Resolve_Logical_Op): issue an error in formal mode on logical operators
9504 for array types with non-matching static bounds. Factorize the code in
9505 Matching_Static_Array_Bounds.
9506 (Resolve_Qualified_Expression): issue an error in formal mode on
9507 qualified expressions for array types with non-matching static bounds.
9508 (Resolve_Type_Conversion): issue an error in formal mode on type
9509 conversion for array types with non-matching static bounds
9510
767bb4e8
AC
95112011-08-02 Robert Dewar <dewar@adacore.com>
9512
9513 * par-ch10.adb: Minor code reorganization (use Nkind_In).
9514
95152011-08-02 Ed Schonberg <schonberg@adacore.com>
9516
9517 * par-ch9.adb: save location of entry for proper error message.
9518
4ac2477e
JM
95192011-08-02 Javier Miranda <miranda@adacore.com>
9520
9521 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
9522 (Use_Full_View) which permits this routine to climb through the
9523 ancestors using the full-view of private parents.
9524 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
9525 Use_Full_View to true in calls to Is_Ancestor.
9526 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
9527 true in call to Is_Ancestor.
9528 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
9529 Use_Full_View to true in call to Is_Ancestor.
9530 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
9531 call to Is_Ancestor.
9532 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
9533 Use_Full_View to true in calls to Is_Ancestor.
9534 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
9535 Make_Select_Specific_Data_Table, Register_Primitive,
9536 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
9537 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
9538 to true in call to Is_Ancestor.
9539 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
9540 Use_Full_View to true in calls to Is_Ancestor.
9541 * exp_cg.adb
9542 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
9543 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
9544
9f90d123
AC
95452011-08-02 Robert Dewar <dewar@adacore.com>
9546
9547 * gnat_rm.texi: Minor reformatting.
9548 * sem_prag.adb: Minor reformatting.
9549
95502011-08-02 Tristan Gingold <gingold@adacore.com>
9551
9552 * vms_data.ads: Add VMS qualifier for -gnateP.
9553
95542011-08-02 Robert Dewar <dewar@adacore.com>
9555
9556 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
9557 * par-ch7.adb (P_Package): Proper placement of aspects for package
9558 decl/instantiation.
9559 * par-endh.adb (Check_End): Ad Is_Sloc parameter
9560 (End_Statements): Add Is_Sloc parameterr
9561 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
9562 (Check_End): Ad Is_Sloc parameter
9563 (End_Statements): Add Is_Sloc parameterr
9564
95652011-08-02 Vincent Celier <celier@adacore.com>
9566
9567 * ug_words: Add VMS qualifier equivalent to -gnateP:
9568 /SYMBOL_PREPROCESSING.
9569
95702011-08-02 Jose Ruiz <ruiz@adacore.com>
9571
9572 * gnat-style.texi: For hexadecimal numeric literals the typical
9573 grouping of digits is 4 to represent 2 bytes.
9574 A procedure spec which is split into several lines is indented two
9575 characters.
9576
95772011-08-02 Yannick Moy <moy@adacore.com>
9578
9579 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
9580 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
9581 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
9582 properly qualified
9583 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
9584 choice in array aggregate
9585 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
9586 mark as ancestor
9587 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
9588 positional and named aggregate for record, or others in record
9589 aggregate, or multiple choice in record aggregate
9590 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
9591 array operands to logical operations AND, OR and XOR do not have the
9592 same static lower and higher bounds
9593 * sem_ch5.adb, sinfo.ads: Correct typos in comments
9594
2933b16c
RD
95952011-08-01 Robert Dewar <dewar@adacore.com>
9596
9597 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
9598 Replaces Last_Source_Node_In_Sequence.
9599 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
9600 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
9601 parens and blank in string (this was inconsistently implemented).
9602 * errout.ads
9603 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
9604 blank in string (this was inconsistently implemented).
9605 * gnat1drv.adb
9606 (Set_Global_Switches): Set formal mode switches appropriately
9607 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
9608 * par-prag.adb
9609 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
9610 call Set_Error_Msg_Lang to set "spark" as language name.
9611 * par.adb: Remove unnecessary call to set formal language for errout
9612 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
9613 appropriately and call Set_Error_Msg_Lang to set "spark" as language
9614 name.
9615 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
9616 calls to it, moved after resolution so that types are known
9617 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
9618 result of concatenation is not of type String
9619 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
9620 concatenation is not properly restricted
9621 * gnat_rm.texi: Add doc on pragma Spark_95.
9622 * gcc-interface/Makefile.in: Remove obsolete target pairs for
9623 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
9624 * gcc-interface/Make-lang.in: Update dependencies.
9625
05dbd302
AC
96262011-08-01 Javier Miranda <miranda@adacore.com>
9627
9628 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
9629 condition that detects if the overridden operation must replace an
9630 existing entity.
9631
96322011-08-01 Javier Miranda <miranda@adacore.com>
9633
9634 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
9635 code declarations inserted by Insert_Actions in each alternative of the
9636 N_Case_Expression node.
9637
96382011-08-01 Robert Dewar <dewar@adacore.com>
9639
9640 * sem_ch6.adb: Minor code reorganization.
9641 * sem_util.adb: Minor reformatting.
9642
af9e051f
PO
96432011-08-01 Pascal Obry <obry@adacore.com>
9644
9645 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
9646 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
9647
1d801f21
AC
96482011-08-01 Yannick Moy <moy@adacore.com>
9649
9650 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
9651 literal or operator symbol which is prefixed
9652 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
9653 mode on access attributes.
9654 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
9655 that concatenation operands are properly restricted in formal mode
9656 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
9657 Analyze_Concatenation_Operand. Issue an error in formal mode if the
9658 result of the concatenation has a type different from String.
9659 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
9660 Analyze_Quantified_Expression, Analyze_Slice,
9661 Analyze_Null): issue an error in formal mode on unsupported constructs
9662 * sem_ch5.adb
9663 (Analyze_Block_Statement): only issue error on source block statement
9664 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
9665 function which returns the last node in a list of nodes for which
9666 Comes_From_Source returns True, if any
9667 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
9668 Last_Source_Node_In_Sequence
9669 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
9670 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
9671 mode on unsupported constructs
9672 * sem_ch9.adb Do not return after issuing error in formal mode, as the
9673 rest of the actions may be needed later on since the error is marked as
9674 not serious.
9675 * sinfo.ads: Typos in comments.
9676
96772011-08-01 Pascal Obry <obry@adacore.com>
9678
9679 * projects.texi: Minor editing.
9680
53beff22
YM
96812011-08-01 Yannick Moy <moy@adacore.com>
9682
9683 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
9684 insertion character ~~
9685 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
9686 (Set_Error_Msg_Lang): new procedure which fixes the language for use
9687 with insertion character ~~
9688 (Set_Msg_Text): treat insertion character ~~
9689 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
9690 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
9691 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
9692 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
9693 errors related to the formal language restriction not serious
9694 (insertion character |).
9695 * par.adb (Par): set formal language for error messages if needed
9696 * sem_ch6.adb (Check_Missing_Return): take into account possible
9697 generated statements at the end of the function
9698 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
9699 enumeration value to define a new pragma SPARK_95
9700 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
9701 SPARK_Version): new type and variables to store the SPARK version
9702 (none by default).
9703 (SPARK_Mode): return True when SPARK_Version is set
9704 * par-prag.adb: Correct indentation
9705 (Prag): take Pragma_SPARK_95 into account
9706 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
9707 into account.
9708
8d606a78
RD
97092011-08-01 Robert Dewar <dewar@adacore.com>
9710
9711 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
9712 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
9713 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
9714
1982d5a8
PO
97152011-08-01 Pascal Obry <obry@adacore.com>
9716
9717 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
9718 Target_Name to Get_Path call.
9719 (Parse_Single_Project): Likewise.
9720 (Post_Parse_Context_Clause): Likewise.
9721 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
9722 Call Initialise_Project_Path with the proper Target_Name.
9723 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
9724 search path.
9725 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
9726 with the proper Target_Name.
9727 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
9728 Part.Parse routine.
9729 (Parse_Project_And_Apply_Config): Likewise.
9730 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
9731 This is fine as this part of the code is supporting only native
9732 compilation.
9733 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
9734 is fine as this part of the code is supporting only native compilation.
9735
0d53d36b
AC
97362011-08-01 Yannick Moy <moy@adacore.com>
9737
9738 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
9739 of homonym, unless the homonym is one of the cases allowed in SPARK
9740 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
9741 package declaration occurring after a body.
9742
97432011-08-01 Robert Dewar <dewar@adacore.com>
9744
9745 * checks.adb, exp_ch4.adb: Minor reformatting.
9746
97472011-08-01 Javier Miranda <miranda@adacore.com>
9748
9749 * einfo.ads (Access_Disp_Table): Fix documentation.
9750 (Dispatch_Table_Wrappers): Fix documentation.
9751
97522011-08-01 Pascal Obry <obry@adacore.com>
9753
9754 * prj-env.adb, prj-env.ads: Minor reformatting.
9755
8ed68165
AC
97562011-08-01 Yannick Moy <moy@adacore.com>
9757
9758 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
9759 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
9760 procedures out of these packages.
2c7f9cc0 9761 * errout.ads, errout.adb
8ed68165
AC
9762 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
9763 procedures in of this package
9764 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
9765 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
9766 on misplaced later vs initial declarations, like in Ada 83
9767 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
9768 formal mode on attribute of private type whose full type declaration
9769 is not visible
9770 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
9771 package declaration inside a package specification
9772 (Analyze_Full_Type_Declaration): issue error in formal mode on
9773 controlled type or discriminant type
9774 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
9775 user-defined operator means that it should come from the source
9776 (New_Overloaded_Entity): issue error in formal mode on overloaded
9777 entity.
9778 * sem_ch6.ads, sem_ch13.ads: typos in comments.
9779
97802011-08-01 Thomas Quinot <quinot@adacore.com>
9781
9782 * atree.adb: Minor reformatting.
9783 * checks.adb: Minor reformatting.
9784
4230bdb7
AC
97852011-08-01 Vincent Celier <celier@adacore.com>
9786
9787 * s-parame-vms-ia64.ads: Fix typo in comment
9788 Minor reformatting
9789 * s-parame-vms-restrict.ads: Removed, unused.
9790
97912011-08-01 Javier Miranda <miranda@adacore.com>
9792
9793 * exp_ch3.adb
9794 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
9795 * sem_ch3.adb
9796 (Constrain_Index): Remove side effects in the evaluation of the bounds.
9797 * sem_ch3.ads, sem_ch3.adb
9798 (Is_Constant_Bound): New extended version of the subprogram that was
9799 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
9800 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
9801 * sem_aux.ads (Constant_Value): Fix typo in comment.
9802 * checks.adb (Generate_Index_Checks): New implementation which, for
9803 array objects with constant bounds, generates the runtime check
9804 referencing the bounds of the array type. For other cases this routine
9805 provides its previous behavior obtaining such values from the array
9806 object.
9807 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
9808 parent type.
9809 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
9810 we cannot have semantic interpretations of the new node.
9811
2010d078
AC
98122011-08-01 Ed Schonberg <schonberg@adacore.com>
9813
9814 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
9815 expressions.
9816
98172011-08-01 Arnaud Charlet <charlet@adacore.com>
9818
9819 * sem_ch8.adb: Minor code editing.
9820 * s-vxwext.adb: Remove trailing space.
9821 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
9822 consistency with other files.
9823
98242011-08-01 Thomas Quinot <quinot@adacore.com>
9825
9826 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
9827
98282011-08-01 Ed Schonberg <schonberg@adacore.com>
9829
9830 * par-ch10.adb: reject parameterized expressions as compilation unit.
9831 * sem_ch4.adb: handle properly conditional expression with overloaded
9832 then_clause and no else_clause.
9833
98342011-08-01 Tristan Gingold <gingold@adacore.com>
9835
9836 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
9837 like done by System.Aux_DEC.
9838 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
9839
daec8eeb
YM
98402011-08-01 Yannick Moy <moy@adacore.com>
9841
9842 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
9843 missing label at end of declaration (subprogram or package)
9844 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
9845 of positional and named parameter association
9846 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
9847 Error_Msg_SP which adds a prefix to the error message giving the name
9848 of the formal language analyzed
9849 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
9850 access result type in subprogram, unconstrained array as result type,.
9851 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
9852 procedure
9853 * sem_ch8.adb: Code clean up.
9854
38171f43
AC
98552011-08-01 Javier Miranda <miranda@adacore.com>
9856
9857 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
9858 * einfo.ads (Access_Disp_Table): Fix documentation.
9859 (Dispatch_Table_Wrappers): Fix documentation.
9860 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
9861 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
9862 to enforce the documentation of this attribute.
9863 (Set_Is_Interface): Cleanup the assertion.
9864 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
9865 the Underlying_Type entity before reading attribute Access_Disp_Table.
9866 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
9867 Locate the Underlying_Type before reading attribute Access_Disp_Table.
9868 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
9869 the Underlying_Type entity before reading attribute Access_Disp_Table.
9870 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
9871 Locate the Underlying_Type entity before reading attribute
9872 Access_Disp_Table.
9873
98742011-08-01 Ed Schonberg <schonberg@adacore.com>
9875
9876 * s-poosiz.ads: Additional overriding indicators.
9877
98782011-08-01 Yannick Moy <moy@adacore.com>
9879
9880 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
9881 formal mode.
9882 (Analyze_Iteration_Scheme): issue error in formal mode when loop
9883 parameter specification does not include a subtype mark.
9884 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
9885 formal mode on abstract subprogram.
9886 (Analyze_Subprogram_Specification): issue error in formal mode on
9887 user-defined operator.
9888 (Process_Formals): issue error in formal mode on access parameter and
9889 default expression.
9890 * sem_ch9.adb (Analyze_Abort_Statement,
9891 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
9892 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
9893 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
9894 Analyze_Requeue, Analyze_Selective_Accept,
9895 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
9896 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
9897 issue error in formal mode on user-defined raise statement.
9898
1f250383
AC
98992011-08-01 Thomas Quinot <quinot@adacore.com>
9900
9901 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
9902 declaration being hidden when overriding an implicit inherited
9903 subprogram.
9904 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
9905 (-gnats), do not complain about a source file that contains only a
9906 pragma No_Body.
9907
99082011-08-01 Ed Schonberg <schonberg@adacore.com>
9909
9910 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
9911 variable if already set.
9912
607d0635
AC
99132011-08-01 Arnaud Charlet <charlet@adacore.com>
9914
9915 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
9916 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
9917 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
9918 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
9919 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
9920 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
9921 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
9922 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
9923 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
9924 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
9925 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
9926 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
9927 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
9928 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
9929 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
9930 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
9931 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
9932 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
9933 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
9934 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
9935 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
9936 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
9937 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
9938 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
9939 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
9940 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
9941 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
9942 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
9943 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
9944 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
9945 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
9946 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
9947 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
9948 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
9949 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
9950 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
9951 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
9952 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
9953 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
9954 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
9955 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
9956 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
9957 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
9958 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
9959 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
9960 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
9961 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
9962 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
9963 s-osinte-mingw.ads: Update to GPLv3 run-time license.
9964 Use GNAT instead of GNARL.
9965
99662011-08-01 Bob Duff <duff@adacore.com>
9967
9968 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
9969 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
9970 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
9971 reformatting.
9972
99732011-08-01 Yannick Moy <moy@adacore.com>
9974
9975 * debug.adb (d.D) reverve flag for the SPARK mode
9976 (d.E) reverve flag for SPARK generation mode
9977 (d.F) reverve flag for Why generation mode
2c7f9cc0 9978 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
607d0635
AC
9979 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
9980 functions which return True when the corresponding modes are set
9981 (Formal_Language): return "spark" or "alfa" when in formal verification
9982 mode.
9983 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
9984 Error_Msg to prefix the error message with a tag giving the formal
9985 language
9986 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
9987 message with a tag giving the formal language
9988 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
9989 block statement
9990 (Analyze_Case_Statement): issue error in formal mode on case statement
9991 with a single "others" case alternative
9992 (Analyze_Exit_Statement): issue errors in formal mode on exit
9993 statements which do not respect SPARK restrictions
9994 (Analyze_Goto_Statement): issue error in formal mode on goto statement
9995 (Check_Unreachable_Code): always issue an error (not a warning) in
9996 formal mode on unreachable code (concerns both code after an infinite
9997 loop and after an unconditional jump, both not allowed in SPARK)
9998 * sem_ch6.adb (Analyze_Return_Statement): add call to
9999 Set_Return_Present for a procedure containing a return statement
10000 (already done for functions in Analyze_Function_Return)
10001 (Analyze_Function_Return): issue error in formal mode on extended
10002 return or if return is not last statement in function
10003 (Check_Missing_Return): issue error in formal mode if function does
10004 not end with return or if procedure contains a return
10005 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
10006 function to detect if there is an inner scope of its parameter S which
10007 is a loop.
10008
100092011-08-01 Thomas Quinot <quinot@adacore.com>
10010
10011 * sem_ch6.ads: Minor reformatting.
10012
d8b3ccb9
AC
100132011-08-01 Javier Miranda <miranda@adacore.com>
10014
10015 * sem_util.adb (Abstract_Interface_List): Complete condition when
10016 processing private type declarations to avoid reading unavailable
10017 attribute.
10018 (Is_Synchronized_Tagged_Type): Complete condition when processing
10019 private extension declaration nodes to avoid reading unavailable
10020 attribute.
10021
100222011-08-01 Thomas Quinot <quinot@adacore.com>
10023
10024 * sem_ch3.adb: Minor reformatting.
10025
100262011-08-01 Thomas Quinot <quinot@adacore.com>
10027
10028 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
10029 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
10030 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
10031 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
10032 for VMS, instead parametrize the common implementation with
10033 System.Parameters declarations.
10034
0bb9276c
AC
100352011-08-01 Eric Botcazou <ebotcazou@adacore.com>
10036
10037 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
10038
100392011-08-01 Tristan Gingold <gingold@adacore.com>
10040
10041 * seh_init.c: Fix SEH handler installation on win64.
10042
100432011-08-01 Ed Schonberg <schonberg@adacore.com>
10044
10045 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
10046 double analysis of an anonymous access to subprogram, because it can
10047 lead to improper sharing of profiles and a back-end crash.
10048
6a2e4f0b
AC
100492011-08-01 Robert Dewar <dewar@adacore.com>
10050
10051 * make.adb, sem_ch4.adb: Minor reformatting.
10052 * gcc-interface/Make-lang.in: Update dependencies.
10053 * sem_util.adb, exp_ch5.adb: Minor reformatting.
10054
100552011-08-01 Arnaud Charlet <charlet@adacore.com>
10056
10057 * gnat_rm.texi: Fix definition of Long_Integer.
10058
100592011-08-01 Ed Schonberg <schonberg@adacore.com>
10060
10061 * exp_aggr.adb: check limit size of static aggregate unconditionally,
10062 to prevent storage exhaustion.
10063 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
10064 finalized is a function body, insert the cleanup code before the final
10065 return statement, to prevent spurious warnings.
10066 * s-pooglo.ads: add overriding indicator.
10067
4561baf7
ES
100682011-08-01 Ed Schonberg <schonberg@adacore.com>
10069
10070 * sem_ch4.adb (Operator_Check): improve error message when both a
10071 with_clause and a use_clause are needed to make operator usage legal.
10072 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
10073 determine whether a compilation unit is visible within an other,
10074 either through a with_clause in the current unit, or a with_clause in
10075 its library unit or one one of its parents.
10076
383e179e
AC
100772011-08-01 Ed Schonberg <schonberg@adacore.com>
10078
10079 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
10080 over an arbitrary expression of an array or container type.
10081 * lib-xref.adb: clarify comment.
10082
100832011-08-01 Bob Duff <duff@adacore.com>
10084
10085 * einfo.ads: Minor reformatting.
10086 * debug.adb: Minor comment improvement.
10087
100882011-08-01 Javier Miranda <miranda@adacore.com>
10089
10090 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
10091 consider hidden subprograms as valid candidates.
10092
100932011-08-01 Arnaud Charlet <charlet@adacore.com>
10094
10095 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
10096
100972011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
10098
10099 * gnat_ugn.texi: Fix typo.
10100
61c161b2
AC
101012011-08-01 Robert Dewar <dewar@adacore.com>
10102
10103 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
10104 lib-xref.adb: Minor reformatting
10105
101062011-08-01 Gary Dismukes <dismukes@adacore.com>
10107
10108 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
10109 when to generate a call to Move_Final_List.
10110 (Has_Controlled_Parts): Remove this function.
10111
84df40f7
AC
101122011-08-01 Geert Bosch <bosch@adacore.com>
10113
10114 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
10115 "," in choice list.
10116
101172011-08-01 Thomas Quinot <quinot@adacore.com>
10118
10119 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
10120 explicit raise of a predefined exception as Comes_From_Source if the
10121 original N_Raise_Statement comes from source.
10122
101232011-08-01 Robert Dewar <dewar@adacore.com>
10124
10125 * sinfo.ads: Add comment.
10126 * sem_ch6.adb: Minor reformatting.
10127
101282011-08-01 Robert Dewar <dewar@adacore.com>
10129
10130 * freeze.adb (Freeze_Entity): Refine check for bad component size
10131 clause to avoid rejecting confirming clause when atomic/aliased present.
10132
101332011-08-01 Ed Schonberg <schonberg@adacore.com>
10134
10135 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
10136 better determine whether an entity reference is a write.
10137 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
10138 subcomponent.
10139 * lib-xref.adb (Output_References): Do no suppress a read reference at
10140 the same location as an immediately preceeding modify-reference, to
10141 handle properly in-out actuals.
10142
101432011-08-01 Tristan Gingold <gingold@adacore.com>
10144
10145 * env.c (__gnat_setenv) [VMS]: Refine previous change.
10146
101472011-08-01 Quentin Ochem <ochem@adacore.com>
10148
10149 * i-cstrin.adb (New_String): Changed implementation, now uses only the
10150 heap to compute the result.
10151
c7f0d2c0
AC
101522011-08-01 Robert Dewar <dewar@adacore.com>
10153
10154 * atree.ads: Minor reformatting.
10155
101562011-08-01 Emmanuel Briot <briot@adacore.com>
10157
10158 * g-expect.adb (Get_Command_Output): Fix memory leak.
10159
101602011-08-01 Geert Bosch <bosch@adacore.com>
10161
10162 * cstand.adb (P_Float_Type): New procedure to print the definition of
10163 predefined fpt types.
10164 (P_Mixed_Name): New procedure to print a name using mixed case
10165 (Print_Standard): Use P_Float_Type for printing floating point types
10166 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
10167 precision IEEE float.
10168
101692011-08-01 Thomas Quinot <quinot@adacore.com>
10170
10171 * sem_ch3.adb: Minor reformatting.
10172
101732011-08-01 Ed Schonberg <schonberg@adacore.com>
10174
10175 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
10176 the completion of a generic function, insert the new body rather than
10177 rewriting the original.
10178
101792011-08-01 Yannick Moy <moy@adacore.com>
10180
10181 * sinfo.ads, errout.ads: Typos in comments.
10182
1c54829e
AC
101832011-08-01 Robert Dewar <dewar@adacore.com>
10184
10185 * par-endh.adb: Minor reformatting.
10186
101872011-08-01 Robert Dewar <dewar@adacore.com>
10188
10189 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
10190 (Pre_Post_Aspects): New subtype.
10191 * par-ch12.adb (P_Generic): New syntax for aspects in packages
10192 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
10193 * par-ch7.adb (P_Package): Remove Decl parameter
10194 (P_Package): Handle new syntax for aspects (before IS)
10195 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
10196 new aspect syntax
10197 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
10198 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
10199 (P_Package): Remove Decl parameter
10200 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
10201 aspects
10202 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
10203 specs
10204 * sem_util.ads, sem_util.adb (Static_Boolean): New function
10205 * sinfo.ads: Document new syntax for aspects in packages etc.
10206 * sprint.adb: Handle new syntax of aspects before IS in package
10207
102082011-08-01 Thomas Quinot <quinot@adacore.com>
10209
10210 * atree.ads: Minor reformatting.
10211 * sem_prag.adb: Minor reformatting.
10212
102132011-08-01 Robert Dewar <dewar@adacore.com>
10214
10215 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
10216 case expr alternative.
10217
102182011-08-01 Ed Schonberg <schonberg@adacore.com>
10219
10220 * sem_ch12.adb: Fix typo.
10221
9eea4346
GB
102222011-08-01 Geert Bosch <bosch@adacore.com>
10223
10224 * sem_prag.adb (Check_No_Link_Name): New procedure.
10225 (Process_Import_Or_Interface): Use Check_No_Link_Name.
10226 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
10227 instead of Standard_Long_Long_Float_Size global. Preparation for
10228 eventual removal of per type constants.
10229 * exp_util.ads (Get_Stream_Size): New function returning the stream
10230 size value of subtype E.
10231 * exp_util.adb (Get_Stream_Size): Implement new function.
10232 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
10233 function.
10234 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
10235 * einfo.adb:
10236 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
10237
3d6c3bd7
GB
102382011-08-01 Geert Bosch <bosch@adacore.com>
10239
10240 * cstand.adb: Fix comments.
10241 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
10242 count of arguments.
10243
e7d897b8
AC
102442011-08-01 Robert Dewar <dewar@adacore.com>
10245
10246 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
10247
102482011-08-01 Geert Bosch <bosch@adacore.com>
10249
10250 * atree.ads: Fix comment.
10251
c228a069
AC
102522011-08-01 Robert Dewar <dewar@adacore.com>
10253
10254 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
10255 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
10256 * par.adb: Add with for Namet.Sp.
10257 * par-tchk.adb: Minor reformatting.
10258
102592011-08-01 Vincent Celier <celier@adacore.com>
10260
10261 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
10262 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
10263 of the init procedure of a SAL.
10264 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
10265 New procedure.
10266
102672011-08-01 Thomas Quinot <quinot@adacore.com>
10268
10269 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
10270 reformatting.
10271
102722011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
10273
10274 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
10275
102762011-08-01 Thomas Quinot <quinot@adacore.com>
10277
10278 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
10279 conformant with its spec (return True only for types that have
10280 an overriding Initialize primitive operation that prevents them from
10281 having preelaborable initialization).
10282 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
10283 initialization for controlled types in Ada 2005 or later mode.
10284
857ade1b
RD
102852011-08-01 Robert Dewar <dewar@adacore.com>
10286
10287 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
10288 Postcondition.
10289 (Same_Aspect): New function.
10290 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
10291 Type_Invariant, Precondition, Postcondition.
10292 * snames.ads-tmpl: Add Name_Type_Invariant.
10293
bd949ee2
RD
102942011-08-01 Robert Dewar <dewar@adacore.com>
10295
10296 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
10297 here.
10298 (Freeze_All_Ent): Fix error in handling inherited aspects.
10299 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
10300 already analyzed, but don't skip entire processing of a declaration,
10301 that's wrong in some cases of declarations being rewritten.
10302 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
10303 Don't delay for integer, string literals
10304 Treat predicates in usual manner for delay, remove special case code,
10305 not needed.
10306 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
10307 (Build_Predicate_Function): Update saved expression in aspect
10308 (Build_Invariant_Procedure): Update saved expression in aspect
10309 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
10310 of replacement of discriminant references if the reference is simple.
10311
f1c952af
RD
103122011-08-01 Robert Dewar <dewar@adacore.com>
10313
10314 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
10315 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
10316 Static_Predicate and Dynamic_Predicate.
10317 (Build_Predicate_Function): Add processing for Static_Predicate
10318 and Dynamic_Predicate.
10319 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
10320 (From_Static_Predicate): New flag
10321 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
10322
103232011-08-01 Robert Dewar <dewar@adacore.com>
10324
10325 * usage.adb: Documentation cleanup for Ada version modes in usage.
10326 * expander.adb: Minor reformatting.
10327
47e11d08
AC
103282011-08-01 Robert Dewar <dewar@adacore.com>
10329
10330 * atree.ads: Minor comment fix.
10331 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
10332 a-witeio.ads, sem_prag.adb: Minor reformatting.
10333
103342011-08-01 Doug Rupp <rupp@adacore.com>
10335
10336 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
10337 pointers. Use descrip.h header file for convenience. Add some
10338 comments.
10339
103402011-08-01 Robert Dewar <dewar@adacore.com>
10341
10342 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
10343 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
10344 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
10345 New procedure.
10346 (Check_Aspect_At_End_Of_Declarations): New procedure
10347 (Analye_Aspect_Specification): Minor changes for above procedures
10348 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
10349 specification node as well.
10350
103512011-08-01 Pascal Obry <obry@adacore.com>
10352
10353 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
10354 Windows files. Use GetFilesAttributes() in this case to check for file
10355 existence instead of returning with an error code.
10356
a3a16b21
VC
103572011-08-01 Vincent Celier <celier@adacore.com>
10358
10359 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
10360 High is above Source length.
10361
ff58cc69
RD
103622011-08-01 Robert Dewar <dewar@adacore.com>
10363
10364 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
10365
6bb88533
AC
103662011-08-01 Robert Dewar <dewar@adacore.com>
10367
10368 * aspects.ads (Boolean_Aspects): New subtype.
10369 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
10370 for derived types in cases where the parent type and derived type have
10371 aspects.
10372 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
10373 with aspects when parent type also has aspects.
10374 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
10375 boolean expression at this point).
10376 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
10377 accordance with final decision on the Ada 2012 feature.
10378 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
10379
103802011-08-01 Matthew Heaney <heaney@adacore.com>
10381
10382 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
10383
060a3f28
AC
103842011-08-01 Pascal Obry <obry@adacore.com>
10385
10386 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
10387 Fix Replace_Slice when High is above current string size.
10388 (Replace_Slice): Fix DL computation when High is above current
10389 string length.
10390
103912011-08-01 Gary Dismukes <dismukes@adacore.com>
10392
10393 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
10394
e7f567a3
AC
103952011-08-01 Matthew Heaney <heaney@adacore.com>
10396
10397 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
10398 of node.
10399
104002011-08-01 Pascal Obry <obry@adacore.com>
10401
10402 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
10403 reformatting.
10404
1a265e78
AC
104052011-08-01 Ed Schonberg <schonberg@adacore.com>
10406
10407 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
10408 access to protected subprograms in generic bodies.
10409 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
10410 protected type, indicate that the convention of the subprogram is
10411 Convention_Protected, because it may be used in subsequent declarations
10412 within the protected declaration.
10413
104142011-08-01 Vincent Celier <celier@adacore.com>
10415
10416 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
10417 and "final" procedures when the name of the library is "ada", to avoid
10418 duplicate symbols "adainit" and "adafinal" in executables.
10419
67e28ef8
ES
104202011-08-01 Ed Schonberg <schonberg@adacore.com>
10421
10422 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
10423 quantified expression that appears within a postcondition and uses the
10424 Ada2012 'Result attribute.
10425
6da2ca7d
RO
104262011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10427
10428 * init.c (__gnat_error_handler): Cast reason to int.
10429 (__gnat_install_handler): Explain sa_sigaction use.
10430
7d5997c6
EB
104312011-07-24 Eric Botcazou <ebotcazou@adacore.com>
10432
10433 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
10434 subprogram has copy-in copy-out parameters, try to promote the mode of
10435 the return type if it is passed in registers.
10436
4b4cfdd5
EB
104372011-07-24 Eric Botcazou <ebotcazou@adacore.com>
10438
10439 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
10440 left operand as addressable.
10441
f3d34576
EB
104422011-07-24 Eric Botcazou <ebotcazou@adacore.com>
10443
10444 * gcc-interface/gigi.h (build_function_stub): Remove.
10445 (build_return_expr): Likewise.
10446 (convert_vms_descriptor): Declare.
10447 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
10448 (build_function_stub): Move to...
10449 * gcc-interface/utils2.c (build_return_expr): Move to...
10450 * gcc-interface/trans.c (build_function_stub): ...here.
10451 (build_return_expr): ...here.
10452 (Subprogram_Body_to_gnu): Add local variable for language_function.
10453 Disconnect the parameter attributes cache, if any, once done with it.
10454 Call end_subprog_body only after setting the end_locus.
10455 Build the stub associated with the function, if any, at the very end.
10456 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
10457 variables and streamline control flow.
10458
0a6ecc08
AC
104592011-07-23 Arnaud Charlet <charlet@adacore.com>
10460
10461 PR ada/49819
10462 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
10463 g-trasym-dwarf.adb.
10464
5b6d595b
RO
104652011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10466
10467 PR bootstrap/49794
10468 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
10469 Assign to act.sa_sigaction.
10470 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
10471 current->return_address to char * before arithmetic.
10472
94017021
RO
104732011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10474
10475 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
10476 Correct argument types.
10477 Extract code from reason.
10478 (__gnat_install_handler): Assign to act.sa_sigaction.
10479
52fd02bb
EB
104802011-07-21 Eric Botcazou <ebotcazou@adacore.com>
10481
10482 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
10483 (GNAT1_OBJS): ...here.
10484
f39a9ca2
EB
104852011-07-15 Eric Botcazou <ebotcazou@adacore.com>
10486
10487 PR ada/48711
10488 * g-socthi-mingw.adb (Fill): Fix formatting.
10489
9e36aa23
EB
10490 * gcc-interface/gigi.h: Move around comment.
10491
e3aca522
JDA
104922011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
10493
10494 PR ada/46350
10495 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
10496
696b1960
FW
104972011-07-14 Florian Weimer <fw@deneb.enyo.de>
10498
10499 PR ada/48711
10500 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
10501
f542c405
EB
105022011-07-13 Eric Botcazou <ebotcazou@adacore.com>
10503
10504 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
10505 range comparison if Pmode is SImode.
10506
9e9bd455
LG
105072011-07-12 Laurent GUERBY <laurent@guerby.net>
10508 Eric Botcazou <ebotcazou@adacore.com>
10509
10510 * adadecode.c: Wrap up in extern "C" block.
10511 * adadecode.h: Likewise.
10512 * adaint.c: Likewise. Remove 'const' keyword.
10513 * adaint.h: Likewise.
10514 * argv.c: Likewise.
10515 * atree.h: Likewise.
10516 * cio.c: Likewise.
10517 * cstreams.c: Likewise.
10518 * env.c: Likewise.
10519 * exit.c: Likewise.
10520 * fe.h: Likewise.
10521 * final.c: Likewise.
10522 * init.c: Likewise.
10523 * initialize.c: Likewise.
10524 * link.c: Likewise.
10525 * namet.h: Likewise.
10526 * nlists.h: Likewise.
10527 * raise.c: Likewise.
10528 * raise.h: Likewise.
10529 * repinfo.h: Likewise.
10530 * seh_init.c: Likewise.
10531 * targext.c: Likewise.
10532 * tracebak.c: Likewise.
10533 * uintp.h: Likewise.
10534 * urealp.h: Likewise.
10535 * xeinfo.adb: Wrap up generated C code in extern "C" block.
10536 * xsinfo.adb: Likewise.
10537 * xsnamest.adb: Likewise.
10538 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
10539 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
10540 * gcc-interface/misc.c: Likewise.
10541 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
10542 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
10543 ada/targext.o here...
10544 (GNAT_ADA_OBJS): ...and not here.
10545 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
10546 (GNATBIND_OBJS): Reorder.
10547
7644b3c7
RH
105482011-07-07 Richard Henderson <rth@redhat.com>
10549
10550 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
10551 dwarf2out_frame_init.
10552
8384ac41
EB
105532011-07-07 Eric Botcazou <ebotcazou@adacore.com>
10554
10555 * gcc-interface/misc.c (gnat_init): Tweak previous change.
10556
fbdd5d87
RO
105572011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10558
10559 PR target/39150
10560 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
10561
1a072294
RG
105622011-07-06 Richard Guenther <rguenther@suse.de>
10563
8384ac41
EB
10564 * gcc-interface/misc.c (gnat_init): Merge calls to
10565 build_common_tree_nodes and build_common_tree_nodes_2.
1a072294
RG
10566 Re-initialize boolean_false_node.
10567
bc712852
EB
105682011-07-02 Eric Botcazou <ebotcazou@adacore.com>
10569 Olivier Hainque <hainque@adacore.com>
10570 Nicolas Setton <setton@adacore.com>
10571
10572 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
10573 the type according to the ARTIFICIAL_P parameter.
10574 (create_type_decl): Likewise.
10575 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
10576
2eb22389
EB
105772011-07-01 Eric Botcazou <ebotcazou@adacore.com>
10578
10579 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
10580 (gnatbind): Likewise.
10581
4bdaaf2f
RO
105822011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10583
10584 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
10585
c020c92b
EB
105862011-06-18 Eric Botcazou <ebotcazou@adacore.com>
10587
10588 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
10589 local variable throughout. Remove useless call to Base_Type.
10590 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
10591 Take it also into account for the volatileness of the field. Set the
10592 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
10593
96769d32
EB
105942011-06-18 Eric Botcazou <ebotcazou@adacore.com>
10595
10596 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
10597 on a dereference built for a by-ref object if it has an address clause.
10598
7e4680c1
EB
105992011-06-18 Eric Botcazou <ebotcazou@adacore.com>
10600
10601 * einfo.ads (Address_Taken): Document use for the second argument of
10602 Asm_Input and Asm_Output attributes.
10603 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
10604 argument is an entity name, then set Address_Taken on it.
10605 <Attribute_Asm_Output>: Likewise.
10606 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
10607 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
10608 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
10609 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
10610
106112011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
d5cc9181
JR
10612
10613 PR middle-end/46500
10614 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
10615
677f3fa8
JM
106162011-06-14 Joseph Myers <joseph@codesourcery.com>
10617
10618 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
10619 (ada/utils.o): Update dependencies.
10620 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
10621 ../../../libcpp/libcpp.a.
10622 * gcc-interface/utils.c: Include common/common-target.h.
10623 (process_attributes): Use targetm_common.have_named_sections.
10624
009db074
RG
106252011-06-07 Richard Guenther <rguenther@suse.de>
10626
0bad0e23
EB
10627 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
10628 set_sizetype.
009db074 10629
3bfc61cf
EB
106302011-06-06 Eric Botcazou <ebotcazou@adacore.com>
10631
0bad0e23 10632 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
3bfc61cf
EB
10633 TREE_THIS_NOTRAP flag.
10634
5c4a1c7b
EB
106352011-06-06 Eric Botcazou <ebotcazou@adacore.com>
10636
10637 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
10638 Fix thinko.
10639
e9f57686
EB
106402011-06-06 Eric Botcazou <ebotcazou@adacore.com>
10641
10642 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
10643 constants whose full view has discriminants specially.
10644
10e4d056
EB
106452011-06-06 Eric Botcazou <ebotcazou@adacore.com>
10646
10647 * gcc-interface/utils.c: Include diagnostic.h.
10648 (gnat_write_global_declarations): Output debug information for all
10649 global type declarations before finalizing the compilation unit.
10650 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
10651
0957c029
JJ
106522011-05-25 Jakub Jelinek <jakub@redhat.com>
10653
10654 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
10655
52d0a7ac
KT
106562011-05-25 Kai Tietz <ktietz@redhat.com>
10657
10658 * adaint.c (__gnat_to_canonical_file_list_next): Use array
10659 initialization instead of const/none-const pointer assignment.
10660
1ed1641d
JM
106612011-05-24 Joseph Myers <joseph@codesourcery.com>
10662
10663 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
10664 $(EXTRA_GNAT1_OBJS).
10665 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
10666 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
10667 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
10668 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
10669 libcommon-target.a instead of prefix.o.
10670
9fe72ebd
JM
106712011-05-21 Joseph Myers <joseph@codesourcery.com>
10672
10673 PR ada/49097
0bad0e23 10674 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
9fe72ebd 10675
2691e6d7
JM
106762011-05-20 Joseph Myers <joseph@codesourcery.com>
10677
0bad0e23
EB
10678 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
10679 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
10680 instead of version.o.
2691e6d7 10681
bf6490b5
KT
106822011-05-18 Kai Tietz <ktietz@redhat.com>
10683
10684 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
10685 boolean_false_node instead of integer_zero_node.
10686 (convert_with_check): Likewise.
10687 * gcc-interface/decl.c (choices_to_gnu): Likewise.
10688
7bf9a5ac
EB
106892011-05-12 Eric Botcazou <ebotcazou@adacore.com>
10690
10691 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
10692 type of the parameter is an unconstrained array, convert the actual to
10693 the type of the formal in the In Out and Out cases as well.
10694
e5b00edf
NF
106952011-05-11 Nathan Froyd <froydnj@codesourcery.com>
10696
10697 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
10698 call build_function_type_array or build_varargs_function_type_array
10699 instead.
10700 (create_subprog_type): Don't call build_function_type; call
10701 build_function_type_vec instead.
10702
51545682
NF
107032011-05-11 Nathan Froyd <froydnj@codesourcery.com>
10704
10705 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
10706 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
10707 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
10708
c99c0026
EB
107092011-05-07 Eric Botcazou <ebotcazou@adacore.com>
10710
f620bd21
EB
10711 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
10712
c99c0026
EB
10713 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
10714 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
10715
3d528853
NF
107162011-05-05 Nathan Froyd <froydnj@codesourcery.com>
10717
c99c0026 10718 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
3d528853 10719
d7d058c5
NF
107202011-05-05 Nathan Froyd <froydnj@codesourcery.com>
10721
10722 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
10723 instead of accessing TYPE_ARG_TYPES directly.
10724 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
10725
805e60a0
EB
107262011-05-05 Eric Botcazou <ebotcazou@adacore.com>
10727
10728 PR ada/48844
10729 * gcc-interface/gigi.h (get_variant_part): Declare.
10730 * gcc-interface/decl.c (get_variant_part): Make global.
10731 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
10732 types have the same constant size, are record types and T1 has a
10733 variant part while T2 doesn't.
10734
907a08d9
EB
107352011-05-05 Eric Botcazou <ebotcazou@adacore.com>
10736
10737 * gcc-interface/utils.c (begin_subprog_body): Do not call
10738 get_pending_sizes.
10739 (end_subprog_body): Likewise.
10740
d35936ab
RG
107412011-05-04 Richard Guenther <rguenther@suse.de>
10742
10743 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
10744 int_const_binop.
10745 (pos_to_constructor): Likewise.
10746
c1fd8753 107472011-05-03 Nathan Froyd <froydnj@codesourcery.com>
2c7f9cc0 10748 Eric Botcazou <ebotcazou@adacore.com>
c1fd8753
NF
10749
10750 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
10751 of build_function_type. Adjust calls to...
10752 (build_raise_check): ...this. Do not take a void_tree parameter.
10753 Call build_function_type_list instead of build_function_type.
10754 Fix head comment and swap couple of conditional blocks.
10755
4fb87d2b
EB
107562011-04-30 Eric Botcazou <ebotcazou@adacore.com>
10757
10758 * gnatvsn.ads (Library_Version): Bump to 4.7.
10759 (Current_Year): Bump to 2011.
10760
fa5e5a76
MM
107612011-04-29 Michael Matz <matz@suse.de>
10762
10763 * gcc-interface/misc.c (gnat_handle_option): Set
10764 warn_maybe_uninitialized.
10765
8d6a2f69
GP
107662011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
10767
10768 * gnat_ugn.texi (Complexity Metrics Control): Update link to
10769 the Watson/McCabe paper.
10770
770937fd
JM
107712011-04-23 Jim Meyering <meyering@redhat.com>
10772
10773 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
10774
eb601ae1
EB
107752011-04-22 Eric Botcazou <ebotcazou@adacore.com>
10776
10777 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
10778 onto the new type.
10779
7d7fcb08
EB
107802011-04-22 Eric Botcazou <ebotcazou@adacore.com>
10781
10782 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
10783 parameter.
10784 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
10785 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
10786 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
10787 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
10788 <all>: Do not set flags on the reused DECL node coming from an alias.
10789 Set DECL_IGNORED_P on the DECL node built for subprograms if they
10790 don't need debug info here...
10791 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
10792 (gigi): Adjust calls to create_subprog_decl.
10793 (build_raise_check): Likewise.
10794 (establish_gnat_vms_condition_handler): Likewise.
10795 (Compilation_Unit_to_gnu): Likewise.
10796 (gnat_to_gnu): Likewise.
10797
e1876cac
EB
107982011-04-21 Eric Botcazou <ebotcazou@adacore.com>
10799
10800 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
10801 (NO_REORDER_ADAFLAGS): New variable.
10802 (EXTRA_GNATTOOLS): Always define.
10803 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
10804 Clean up and adjust list of files compiled with special options.
10805 * gcc-interface/Make-lang.in: Likewise.
10806 (ada/decl.o): Cosmetical change.
10807 (ada/misc.o): Remove dependency on $(PLUGIN_H).
10808
04695783
JM
108092011-04-20 Jim Meyering <meyering@redhat.com>
10810
10811 * initialize.c (__gnat_initialize): Remove useless if-before-free.
10812
23399579
EB
108132011-04-17 Eric Botcazou <ebotcazou@adacore.com>
10814
10815 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
10816 $(CFLAGS) on the link line.
10817
51c5169c
EB
108182011-04-17 Eric Botcazou <ebotcazou@adacore.com>
10819
10820 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
10821 padded type built for the return type if it is unconstrained.
10822
61e46a7d
NF
108232011-04-14 Nathan Froyd <froydnj@codesourcery.com>
10824
10825 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
10826
81f653d6
NF
108272011-04-12 Nathan Froyd <froydnj@codesourcery.com>
10828
b4867846
EB
10829 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
10830 before calling TREE_CHAIN.
81f653d6
NF
10831 * gcc-interface/misc.c (gnat_init_ts): New function.
10832 (LANG_HOOKS_INIT_TS): Define.
10833
a358e188
MJ
108342011-04-12 Martin Jambor <mjambor@suse.cz>
10835
b4867846
EB
10836 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
10837 instead of cgraph_node.
a358e188 10838
29b1c5a4
EB
108392011-04-08 Eric Botcazou <ebotcazou@adacore.com>
10840
10841 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
10842 alignment on fields of the RETURN type built for the Copy-In Copy-Out
10843 mechanism.
10844
88872b00
EB
108452011-04-08 Eric Botcazou <ebotcazou@adacore.com>
10846
10847 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
10848 of aggregate types that contain a placeholder.
10849
dcf0c47e
NF
108502011-04-08 Nathan Froyd <froydnj@codesourcery.com>
10851
10852 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
b4867846 10853 TYPE_ARG_TYPES.
dcf0c47e
NF
10854 (handle_type_generic_attribute): Likewise.
10855
53e3000c
EB
108562011-04-04 Eric Botcazou <ebotcazou@adacore.com>
10857
10858 PR ada/47163
10859 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
10860
ab380bb4
KT
108612011-04-04 Kai Tietz <ktietz@redhat.com>
10862
10863 PR ada/47163
0bad0e23
EB
10864 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
10865 to flag value.
ab380bb4 10866
8ffac116
EB
108672011-04-02 Eric Botcazou <ebotcazou@adacore.com>
10868
10869 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
10870 type case, do not strip a padding type around the array type.
10871
de9528f0
EB
108722011-04-02 Eric Botcazou <ebotcazou@adacore.com>
10873
10874 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
10875 types.
10876
d9d7a26c
EB
108772011-04-02 Eric Botcazou <ebotcazou@adacore.com>
10878
10879 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
10880 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
de9528f0 10881 code for -feliminate-unused-debug-types.
d9d7a26c
EB
10882 (gnat_post_options): Likewise.
10883
4cb12a90
EB
108842011-04-02 Eric Botcazou <ebotcazou@adacore.com>
10885
10886 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
10887 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
10888 distinct copy.
10889
acccc61c
EB
108902011-04-02 Eric Botcazou <ebotcazou@adacore.com>
10891
10892 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
10893 DECL_ARTIFICIAL flag on enumeration types.
10894
583eb0c9
EB
108952011-04-02 Eric Botcazou <ebotcazou@adacore.com>
10896
10897 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
10898 fat pointer types artificial unconditionally.
10899 <E_Array_Subtype>: Attach the base array type as a parallel type if it
10900 isn't artificial.
10901
e3edbd56
EB
109022011-04-02 Eric Botcazou <ebotcazou@adacore.com>
10903
10904 * gcc-interface/gigi.h (get_dummy_type): Declare.
10905 (build_dummy_unc_pointer_types): Likewise.
10906 (finish_fat_pointer_type): Likewise.
10907 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
10908 fat pointer type has been built, complete it in place.
10909 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
10910 and thin pointers. Remove useless variable.
10911 (finish_fat_pointer_type): Make global and move to...
10912 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
10913 (get_dummy_type): New function.
10914 (build_dummy_unc_pointer_types): Likewise.
10915 (gnat_pushdecl): Propage the name to the anonymous variants only.
10916 (update_pointer_to): Only adjust the pointer types in the unconstrained
10917 array case.
10918
65444786
EB
109192011-04-02 Eric Botcazou <ebotcazou@adacore.com>
10920
10921 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
10922 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
10923 if this is a Taft amendment type and the full declaration is available.
10924 * gcc-interface/trans.c (process_type): Likewise.
10925 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
10926 (process_freeze_entity): Likewise.
10927 * gcc-interface/utils.c (dummy_global): New static variable.
10928 (gnat_write_global_declarations): If there are types declared as used
10929 at the global level, insert them in the global hash table.
10930
1aeb40dd
EB
109312011-04-02 Eric Botcazou <ebotcazou@adacore.com>
10932
10933 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
10934 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
10935 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
10936 copy.
10937 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
10938 flag of the type accordingly.
10939 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
10940
80ec8b4c
EB
109412011-04-02 Eric Botcazou <ebotcazou@adacore.com>
10942
10943 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
10944 finalizing types when updating the pointers to the designated type.
10945 <all>: Finalize the deferred types even if we didn't defer processing
10946 of incomplete types in this invocation.
10947
2a9d769a 109482011-04-01 Olivier Hainque <hainque@adacore.com>
2c7f9cc0
AS
10949 Nicolas Setton <setton@adacore.com>
10950 Eric Botcazou <ebotcazou@adacore.com>
2a9d769a
OH
10951
10952 * gcc-interface/misc.c (gnat_descriptive_type): New function.
10953 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
10954
2438d7a6
KT
109552011-03-28 Kai Tietz <ktietz@redhat.com>
10956
333d8aff 10957 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
80ec8b4c
EB
10958 Windows targets.
10959 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
10960 * system-mingw.ads (System): Change ZCX_By_Default default to True.
333d8aff 10961
80ec8b4c 10962 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
2438d7a6 10963
8ad150f6
TG
109642011-03-28 Tristan Gingold <gingold@adacore.com>
10965
10966 PR ada/44431
80ec8b4c
EB
10967 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
10968 Use ada output of gnatbind.
8ad150f6
TG
10969 (ada/b_gnatb.adb): Ditto.
10970 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
10971 (ada.mostlyclean, ada.stage1)
10972 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
10973 (ada.stagefeedback): Adjust.
80ec8b4c 10974 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
8ad150f6
TG
10975 Use ada output of gnatbind.
10976 (b_gnatm.adb): Ditto.
10977 (b_gnatl.o, b_gnatm.o): New rules.
10978
51c7954d
EB
109792011-03-26 Eric Botcazou <ebotcazou@adacore.com>
10980
10981 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
10982 for the padded type built to support a specified size or alignment.
10983
6ddf9843
EB
109842011-03-26 Eric Botcazou <ebotcazou@adacore.com>
10985
10986 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
10987 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
10988 unconditionally to the end of the unit when the designated type is
10989 limited_with'ed.
10990 <all>: Rename local variable. Attempt to un-defer types only and do it
10991 for limited_with'ed types as well.
10992 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
10993 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
10994 consistently and remove redundant call to finalize_from_with_types.
10995
5daed84a
EB
109962011-03-26 Eric Botcazou <ebotcazou@adacore.com>
10997
10998 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
10999 subprograms without a previous spec declared in the same unit.
11000 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
11001 subprograms at the end of the unit instead of at the beginning.
11002 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
11003 isn't public for the special handling of non-inline functions nested
11004 inside inline external functions.
11005
0edf1bb2
JL
110062011-03-25 Jeff Law <law@redhat.com>
11007
5daed84a 11008 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
0edf1bb2 11009
e3c4580e
EB
110102011-03-24 Eric Botcazou <ebotcazou@adacore.com>
11011
11012 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
11013 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
11014 to compute Set_Size_Depends_On_Discriminant.
11015 (Layout_Type): Call it on array types in back-end layout mode.
11016 * sem_util.adb (Requires_Transient_Scope): Return true for array
11017 types only if the size depends on the value of discriminants.
11018 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
11019 type if the RHS is a call to a function that returns an unconstrained
11020 type with default discriminant.
11021
abbc8c7b
EB
110222011-03-24 Eric Botcazou <ebotcazou@adacore.com>
11023
11024 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
11025 non-conversion to the nominal result type at the end.
11026
ddb5a105
EB
110272011-03-23 Eric Botcazou <ebotcazou@adacore.com>
11028
11029 * gcc-interface/trans.c (create_temporary): New function taken from...
11030 (create_init_temporary): ...here. Call it.
11031 (call_to_gnu): Create the temporary for the return value early, if any.
11032 Create it for a function with copy-in/copy-out parameters if there is
11033 no target; in other cases of copy-in/copy-out, use another temporary.
11034 Push the new binding level lazily. Add and rename local variables.
11035
0d853156
EB
110362011-03-23 Eric Botcazou <ebotcazou@adacore.com>
11037
11038 * gcc-interface/decl.c (validate_size): Improve comments and tweak
11039 error message.
11040 (set_rm_size): Likewise.
11041
4184ef1b
EB
110422011-03-23 Eric Botcazou <ebotcazou@adacore.com>
11043
11044 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
11045 for the padded type built in order to support a specified alignment.
11046 Fix incorrect formatting.
11047
bf7eefab
EB
110482011-03-21 Eric Botcazou <ebotcazou@adacore.com>
11049
11050 PR bootstrap/48216
11051 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
11052
ef0feeb2
EB
110532011-03-21 Eric Botcazou <ebotcazou@adacore.com>
11054
11055 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
11056 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
11057 to the end of the list. Adjust recursive call. Rename local variable.
11058 If REORDER is true, reorder components of the record type.
11059 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
11060 components_to_record and adjust the parameter list.
11061
646f9414
EB
110622011-03-21 Eric Botcazou <ebotcazou@adacore.com>
11063
11064 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
11065 disabled, use the variable for bounds of loop iteration scheme.
11066
62d784f7
KT
110672011-03-21 Kai Tietz <ktietz@redhat.com>
11068
11069 PR target/12171
0bad0e23 11070 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
62d784f7 11071
f230d759
EB
110722011-03-17 Eric Botcazou <ebotcazou@adacore.com>
11073
11074 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
11075 out whether the expression is read-only. Short-circuit placeholder
11076 case and rename a couple of local variables.
11077
bb1f7929
EB
110782011-03-17 Eric Botcazou <ebotcazou@adacore.com>
11079
11080 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
11081 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
11082 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
11083 (convert): Deal with conversions from a smaller form type specially.
11084
400a2d24
EB
110852011-02-14 Eric Botcazou <ebotcazou@adacore.com>
11086
11087 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
11088 its argument, except for the special -I- switch.
11089
c26bc3ad
GP
110902011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
11091
0bad0e23
EB
11092 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
11093 "Ada Issues".
c26bc3ad 11094
07b8e910
EB
110952011-02-08 Eric Botcazou <ebotcazou@adacore.com>
11096
11097 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
11098
31a5a547
EB
110992011-02-03 Eric Botcazou <ebotcazou@adacore.com>
11100
11101 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
11102 GNAT_FORMAL.
11103 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
11104 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
11105 instead of GNAT_FORMAL. Protect the expression against multiple uses.
11106 Do not generate the check directly, instead instantiate the template
11107 check present in the descriptor.
11108 (make_descriptor_field): Move around.
11109 (build_vms_descriptor32): Build a template check in the POINTER field.
11110 (build_vms_descriptor): Remove useless suffixes.
11111 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
11112
dcf25f59
EB
111132011-01-26 Eric Botcazou <ebotcazou@adacore.com>
11114
11115 PR bootstrap/47467
11116 * targext.c: Include target files if IN_RTS is defined.
11117
0418e131
RG
111182011-01-26 Richard Guenther <rguenther@suse.de>
11119
11120 PR bootstrap/47467
11121 * targext.c: Include config.h.
11122 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
11123 dependency.
11124
c6eecbd8 111252011-01-04 Pascal Obry <obry@adacore.com>
2c7f9cc0 11126 Eric Botcazou <ebotcazou@adacore.com>
c6eecbd8
PO
11127
11128 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
11129
2d3c7e4f
EB
111302011-01-04 Eric Botcazou <ebotcazou@adacore.com>
11131
11132 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
11133 end-of-case on the end label and its associated gotos, if any.
11134
0394741f
EB
111352011-01-04 Eric Botcazou <ebotcazou@adacore.com>
11136
11137 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
11138 expressions of the parameter cache within the statement group of
11139 the CICO mechanism.
11140
2a02d090 111412011-01-04 Olivier Hainque <hainque@adacore.com>
2c7f9cc0 11142 Eric Botcazou <ebotcazou@adacore.com>
2a02d090
OH
11143
11144 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
11145 (set_end_locus_from_node): New function.
11146 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
11147 make and the function end_locus.
11148 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
11149 for the elaboration subprogram.
11150 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
11151 set the end_locus of the expression as well.
11152
89f5e978
EB
111532011-01-04 Eric Botcazou <ebotcazou@adacore.com>
11154
11155 PR ada/47131
11156 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
11157 variables that are referenced in exception handlers volatile.
11158
11159
ad41bd84 11160\f
797103eb 11161Copyright (C) 2011 Free Software Foundation, Inc.
ad41bd84
JM
11162
11163Copying and distribution of this file, with or without modification,
11164are permitted in any medium without royalty provided the copyright
11165notice and this notice are preserved.