]> gcc.gnu.org Git - gcc.git/blame - gcc/ada/ChangeLog
Handle different versions of Solaris 8 <iso/math_iso.h>, <iso/stdlib_iso.h>
[gcc.git] / gcc / ada / ChangeLog
CommitLineData
25ebc085
AC
12011-08-29 Tristan Gingold <gingold@adacore.com>
2
3 * a-exstat.adb (String_To_EO): Do no set Cleanup_Flag.
4 * a-exexda.adb (Set_Exception_C_Msg): Ditto.
5 (Set_Exception_Msg): Ditto.
6 * a-exexpr-gcc.adb (Setup_Current_Excep): Ditto. Do not set
7 Private_Data.
8 * a-except.adb, a-except-2005.adb (Save_Occurrence_No_Private): Remove.
9 Use Save_Occurrence instead of Save_Occurrence_No_Private.
10 (Raise_With_Msg): Remove Cleanup_Flag.
11 * a-except.ads, a-except-2005.ads (Exception_Occurrence): Remove
12 Clean_Flag and Private_Data components.
13
142011-08-29 Yannick Moy <moy@adacore.com>
15
16 * freeze.adb (Freeze_Record_Type): Ignore packing in Alfa mode, like
17 in CodePeer mode.
18 * sem_ch3.adb (Signed_Integer_Type_Declaration): Correct the generation
19 of an explicitly declared type, so that the base types of the original
20 type and this generated type are the same, and a "type" (not a subtype
21 like previously).
22 * errout.adb (Special_Msg_Delete): Do not issue messages "Size too
23 small" in Alfa mode, like in CodePeer mode.
24 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore rep
25 clauses in Alfa mode.
26
272011-08-29 Javier Miranda <miranda@adacore.com>
28
29 * exp_ch6.ads, exp_ch6.adb (Is_Null_Procedure): Move the spec of this
30 function to the package spec.
31 * sem_ch6.adb (Find_Corresponding_Spec, New_Overloaded_Entity): For
32 internally generated bodies of null procedures locate the internally
33 generated spec enforcing mode conformance.
34 (Is_Interface_Conformant): Ensure that the controlling formal of the
35 primitives match.
36
372011-08-29 Ed Schonberg <schonberg@adacore.com>
38
39 * sem_prag.adb (Analyze_Pragma, case Inline): In an instance, do not
40 reject the pragma if it appears to apply to a formal subprogram.
41
422011-08-29 Ed Schonberg <schonberg@adacore.com>
43
44 * exp_ch4.adb (Expand_Allocator_Expression): Use consistent name for
45 inner expression, to prevent double evaluation.
46
590549fb
AC
472011-08-29 Tristan Gingold <gingold@adacore.com>
48
49 * a-exexpr.adb (Propagate_Exception): Remove all the parameters as
50 they were unused.
51 * a-exexpr-gcc.adb (Propagate_Exception): Ditto.
52 * a-except-2005.adb (Propagate_Exception): Adjust spec.
53 (Raise_Current_Excep): Adjust call.
54 (Raise_From_Signal_Handler): Call now simply call Raise_Current_Excep.
55
562011-08-29 Thomas Quinot <quinot@adacore.com>
57
58 * exp_disp.adb: Minor reformatting.
59
62380e66
TG
602011-08-29 Tristan Gingold <gingold@adacore.com>
61
62 * a-exexpr.adb (Setup_Exception): Removed.
63 * a-exexpr-gcc.adb (Setup_Exception): Removed.
64 * a-except.adb (Exception_Propagation): Removed.
65 * a-except-2005.adb (Setup_Exception): Removed.
66 (Reraise): Remove call to Setup_Exception.
67 (Reraise_Occurrence): Ditto.
68 (Reraise_Occurrence_Always): Ditto.
69 (Reraise_Occurrence_No_Defer): Ditto.
70 (Transfer_Occurrence): Ditto.
71 * a-exexda.adb (Set_Exception_C_Msg): Remove call to Setup_Exception.
72 (Set_Exception_Msg): Ditto.
73
c95aa61c
AC
742011-08-29 Robert Dewar <dewar@adacore.com>
75
76 * a-convec.adb, exp_disp.adb: Minor reformatting.
77
782011-08-29 Tristan Gingold <gingold@adacore.com>
79
80 * a-exexpr-gcc.adb (GNAT_GCC_Exception_Access): Set to convention C.
81
624e1688
AC
822011-08-29 Gary Dismukes <dismukes@adacore.com>
83
84 * exp_ch3.adb (Build_Record_Init_Proc.Build_Init_Procedure): Set
85 Exception_Handlers to No_List instead of Empty_List in the case where
86 there are no handlers.
87
882011-08-29 Tristan Gingold <gingold@adacore.com>
89
90 * gcc-interface/gigi.h (enum standard_datatypes): Add
91 ADT_reraise_zcx_decl
92 (reraise_zcx_decl): New macro.
93 * gcc-interface/trans.c (gnu_incoming_exc_ptr): New variable.
94 (gigi): Set reraise_zcx_decl.
95 (Exception_Handler_to_gnu_zcx): Save and restore gnu_incoming_exc_ptr.
96 (gnat_to_gnu): Handle N_Raise_Statement.
97
7134062a
AC
982011-08-29 Robert Dewar <dewar@adacore.com>
99
100 * sem_ch6.adb, exp_ch3.adb, s-stposu.adb, a-undesu.ads,
101 a-undesu.adb: Minor reformatting.
102
1032011-08-29 Ed Schonberg <schonberg@adacore.com>
104
105 * exp_disp.adb (Check_Premature_Freezing): When building a dispatch
106 table, accept an unfrozen untagged component if it is an actual for a
107 formal incomplete type.
108 * a-convec.ads, a-convec.adb: Instantiate Ada.Iterator_Interfaces to
109 provide new iterator forms over vectors.
110 Introduce type Iterator in package body to implement operations of
111 Reversible_Iterator interface.
112 * a-iteint.ads: Make package pure so it is usable with new container
113 packages, that are categorized Remote_Types.
114
ca5af305
AC
1152011-08-29 Robert Dewar <dewar@adacore.com>
116
117 * a-exexpr-gcc.adb, a-synbar.adb, sem_ch13.adb: Minor reformatting.
118
1192011-08-29 Bob Duff <duff@adacore.com>
120
121 * sem_aggr.adb (Resolve_Aggr_Expr): Call this routine even in the case
122 of <>, because this is the routine that checks for dimensionality
123 errors (for example, for a two-dimensional array, (others => <>) should
124 be (others => (others => <>)).
125
1262011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
127
128 * impunit.adb: Add new run-time units.
129 * freeze.adb, exp_ch7.ads, exp_ch7.adb, exp_util.ads, exp_util.adb,
130 s-stposu.ads, s-stposu.adb: Code clean up.
131 Handle protected class-wide or task class-wide types
132 Handle C/C++/CIL/Java types.
133 * s-spsufi.adb, s-spsufi.ads: New files.
134
5accd7b6
AC
1352011-08-29 Yannick Moy <moy@adacore.com>
136
137 * sem_ch13.adb (Analyze_Aspect_Specifications): Reject test-case on
138 library-level subprogram.
139 * sem_prag.adb (Check_Test_Case): Stricter rules for test-case
140 placement.
141 (Analyze_Pragma): Change name "Normal" for "Nominal" in test-case
142 component.
143 * snames.ads-tmpl: Change name "Normal" for "Nominal" in test-case
144 component.
145 * gnat_rm.texi: Update doc for Test_Case pragma.
146
1472011-08-29 Tristan Gingold <gingold@adacore.com>
148
149 * a-exexpr-gcc.adb (Unwind_Exception): Remove default value, made it
150 convention C.
151 (GCC_Exception_Access): New type.
152 (Unwind_DeleteException): New imported procedure
153 (Foreign_Exception): Import it.
154 (GNAT_GCC_Exception): Simply have the occurrence inside.
155 (To_GCC_Exception): New function.
156 (To_GNAT_GCC_Exception): New function.
157 (GNAT_GCC_Exception_Cleanup): New procedure..
158 (Propagate_GCC_Exception): New procedure.
159 (Reraise_GCC_Exception): New procedure.
160 (Setup_Current_Excep): New procedure.
161 (CleanupUnwind_Handler): Change type of UW_Exception parameter.
162 (Unwind_RaiseException): Ditto.
163 (Unwind_ForcedUnwind): Ditto.
164 (Remove): Removed.
165 (Begin_Handler): Change type of parameter.
166 (End_Handler): Ditto. Now delete the exception if still present.
167 (Setup_Key): Removed.
168 (Is_Setup_And_Not_Propagated): Removed.
169 (Set_Setup_And_Not_Propagated): Ditto.
170 (Clear_Setup_And_Not_Propagated): Ditto.
171 (Save_Occurrence_And_Private): Ditto.
172 (EID_For): Add 'not null' constraint on parameter.
173 (Setup_Exception): Does nothing.
174 (Propagate_Exception): Simplified.
175 * exp_ch11.adb (Expand_N_Raise_Statement): In back-end exception model,
176 re-raise is not expanded anymore.
177 * s-except.ads (Foreign_Exception): New exception - placeholder for
178 non Ada exceptions.
179 * raise-gcc.c (__gnat_setup_current_excep): Declare
180 (CXX_EXCEPTION_CLASS): Define (not yet used)
181 (GNAT_EXCEPTION_CLASS): Define.
182 (is_handled_by): Handle foreign exceptions.
183 (PERSONALITY_FUNCTION): Call __gnat_setup_current_excep.
184
1852011-08-29 Jose Ruiz <ruiz@adacore.com>
186
187 * a-synbar.adb (Synchronous_Barrier): Some additional clarification.
188
2ef48385
AC
1892011-08-29 Thomas Quinot <quinot@adacore.com>
190
191 * a-synbar-posix.adb: Minor reformatting.
192
1932011-08-29 Jose Ruiz <ruiz@adacore.com>
194
195 * a-exetim-posix.adb, a-exetim-mingw.adb, a-exetim-mingw.ads,
196 a-exetim-default.ads (Interrupt_Clocks_Supported,
197 Separate_Interrupt_Clocks_Supported, Clock_For_Interrupts): Add these
198 definitions to be compliant with AI-0171. The target systems do not
199 support separate account for the execution time of interrupt handlers.
200
2012011-08-29 Jose Ruiz <ruiz@adacore.com>
202
203 * a-synbar.adb (Wait): Change the order of evaluation of the conditions
204 in the barrier to put first the easiest to evaluate (and the one which
205 will be True more often). More efficient.
206
2072011-08-29 Eric Botcazou <ebotcazou@adacore.com>
208
209 * s-atocou-x86.adb: Fix constraint in machine code insertion.
210
2112011-08-29 Bob Duff <duff@adacore.com>
212
213 * aspects.ads, aspects.adb: Add new aspects for various pragmas and
214 attributes that are now aspects, as specified by AI05-0229-1.
215 * sem_ch13.adb (Analyze_Aspect_Specifications,
216 Check_Aspect_At_Freeze_Point): Analyze the new aspects. Turn them into
217 pragmas or attribute references, as appropriate.
218
0db16b1e
AC
2192011-08-29 Robert Dewar <dewar@adacore.com>
220
221 * a-synbar.ads, a-synbar.adb, a-synbar-posix.adb,
222 a-synbar-posix.ads: Minor reformatting.
223
2242011-08-29 Yannick Moy <moy@adacore.com>
225
226 * snames.ads-tmpl: Add name Force.
227
978ffe02
AC
2282011-08-29 Pascal Obry <obry@adacore.com>
229
230 * prj-nmsc.adb: Minor reformatting.
231
2322011-08-29 Jose Ruiz <ruiz@adacore.com>
233
234 * a-exetim.ads (Interrupt_Clocks_Supported,
235 Separate_Interrupt_Clocks_Supported, Clock_For_Interrupts): Add these
236 definitions to be compliant with AI-0171.
237
2382011-08-29 Robert Dewar <dewar@adacore.com>
239
240 * a-ngelfu.adb: Add comments.
241
718f39dc
AC
2422011-08-29 Geert Bosch <bosch@adacore.com>
243
244 * a-ngelfu.adb (Tan): Do not raise Constraint_Error if the argument is
245 the closest machine number to Pi / 2.0.
246
2472011-08-29 Jose Ruiz <ruiz@adacore.com>
248
249 * impunit.adb (Non_Imp_File_Names_12): Add a-synbar for new Ada 2012
250 package Ada.Synchronous_Barriers.
251 * a-synbar.ads, a-synbar.adb, a-synbar-posix.ads, a-synbar-posix.adb:
252 Add new specs and bodies for Ada.Synchronous_Barriers. There is a
253 default implementation using protected objects and another one
254 a-synbar-posix using POSIX barriers as the underlying support.
255 * gcc-interface/Makefile.in (LIBGNAT_TARGET_PAIRS for Linux (x86,
256 x86_64, ia64) and MIPS IRIX): Use the a-synbar-posix implementation of
257 Ada.Synchronous_Barriers which uses POSIX barriers (more efficient).
258 Clean up dependencies.
259 * Makefile.rtl (GNATRTL_TASKING_OBJS): Add a-synbar.o
260
ee2e3f6b
AC
2612011-08-29 Robert Dewar <dewar@adacore.com>
262
263 * sem_ch7.adb, make.adb, sem_res.adb, exp_intr.adb,
264 exp_dist.adb: Minor code reorganization.
265 Minor reformatting.
266
2672011-08-29 Thomas Quinot <quinot@adacore.com>
268
269 * sem_cat.adb (Validate_RACW_Primitive): The return type of an RACW
270 primitive operation must support external streaming if it is not a
271 controlling access result.
272
646e2823
AC
2732011-08-29 Thomas Quinot <quinot@adacore.com>
274
275 * sinfo.ads, sem_ch7.adb: Minor reformatting.
276
2772011-08-29 Bob Duff <duff@adacore.com>
278
279 * sem_ch4.adb (Analyze_Allocator): Check No_Nested_Finalization
280 restriction on allocators, as required by AI05-0013-1.
281 * restrict.ads: Minor comment fix.
282
5d59eef2
AC
2832011-08-29 Tristan Gingold <gingold@adacore.com>
284
285 * a-exexpr.adb, a-except-2005.ads (Jmpbuf_Address): Move to a-exexpr.adb
286 (To_Jmpbuf_Address): Ditto
287 (builtin_longjmp): Ditto
288
2892011-08-29 Thomas Quinot <quinot@adacore.com>
290
291 * sem_res.adb: Minor reformatting.
292
2932011-08-29 Vincent Celier <celier@adacore.com>
294
295 * make.adb (Gnatmake): Move special processing for VM targets after the
296 call to Get_Target_Parameters.
297
2982011-08-29 Thomas Quinot <quinot@adacore.com>
299
300 * sem_ch12.adb, par-ch12.adb: Minor reformatting.
301
949a18cc
AC
3022011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
303
304 * sem_res.adb (Resolve_Allocator): Implement Ada2012-B052. Detect cases
305 where an anonymous access discriminant of a limited designated type
306 appears in a non-immutably limited discriminated type and issue an
307 error message. Add local variable Desig_T and replace all occurrences
308 of Designated_Type.
309
3102011-08-29 Jose Ruiz <ruiz@adacore.com>
311
312 * a-rttiev.adb (Set_Handler): Update comment to indicate that our
313 implementation is compliant to RM D.15(15/2) after the modification
314 imposed by AI05-0094-1 (binding interpretation).
315
cb25faf8
AC
3162011-08-29 Robert Dewar <dewar@adacore.com>
317
318 * exp_ch9.adb, s-tasren.adb, exp_sel.adb, exp_sel.ads, exp_ch11.adb,
319 s-interr-hwint.adb, s-tpobop.adb, sem_ch13.adb: Minor reformatting.
320
3212011-08-29 Thomas Quinot <quinot@adacore.com>
322
323 * par-endh.adb (Check_End): For an END where it is mandatory to repeat
324 the scope name, do not report a missing label as a style violation (it
325 will be diagnosed as an illegality).
326 * exp_dist.adb (Add_Params_For_Variant_Components): Fix handling of
327 variant records: Get_Enum_Lit_From_Pos already returns a usage
328 occurrence of the literal, no need to use New_Occurrence_Of. Set Etype
329 on Expr in Integer_Literal case so that it can be used by
330 Build_To_Any_Call.
331
1d10f669
AC
3322011-08-29 Tristan Gingold <gingold@adacore.com>
333
334 * exp_sel.ads (Build_Abort_BLock_Handler): New function spec.
335 Adjust comment.
336 * exp_sel.adb (Build_Abort_Block): Use Build_Abort_Block_Handler.
337 (Build_Abort_Block_Handler): New function to build an Abort_Signal
338 exception handler.
339 * exp_ch9.adb (Expand_N_Asynchronous_Select): Call
340 Build_Abort_Block_Handler to build the exception handler. Do not
341 undefer aborts for the Abort_Signal exception handler if back-end
342 exception mechanism.
343 * exp_ch11.adb (Expand_Exception_Handlers): Do not undefer aborts if
344 back_end exceptions for all others and abort_signal.
345 * s-except.ads (ZCX_By_Default): New constant.
346 * a-except-2005.adb (Raise_Exception): Do not defer abort if ZCX.
347 (Raise_Exception_Always): Ditto.
348 (Raise_From_Signal_Handler): Ditto.
349 (Raise_With_Location_And_Msg): Ditto.
350 (Raise_With_Msg): Ditto.
351 (Reraise): Ditto.
352 (Reraise_Occurence): Ditto.
353 (Reraise_Occurrence_Always): Ditto.
354 * s-tasren.adb (Exceptional_Complete_Rendezvous): Defer aborts if ZCX.
355 * s-tpobop.adb: (Exceptional_Complete_Body): Undefer abort if ZCX.
1d10f669
AC
356
3572011-08-29 Thomas Quinot <quinot@adacore.com>
358
359 * sem_util.ads (Get_Enum_Lit_From_Pos): Clarify documentation.
360
d986066d
AC
3612011-08-29 Robert Dewar <dewar@adacore.com>
362
363 * snames.adb-tmpl, sem_ch13.adb: Minor reformatting
364 Minor code reorganization.
365
3662011-08-29 Bob Duff <duff@adacore.com>
367
368 * usage.adb (-gnatwy): Fix documentation: this switch applies to Ada
369 2012, not just Ada 2005.
370
3712011-08-29 Vincent Celier <celier@adacore.com>
372
373 * gnat_ugn.texi: Indicate that when the compiler is called by gnatmake
374 with a project file or with gprbuid, if -gnatep= is specified, the
375 builder may need to be invoked with -x.
376
3772011-08-29 Tristan Gingold <gingold@adacore.com>
378
379 * a-exexpr-gcc.adb: Minor comment fix.
380
ff4f0ed0
AC
3812011-08-29 Robert Dewar <dewar@adacore.com>
382
383 * sem_ch8.adb: Minor reformatting.
384
3852011-08-29 Bob Duff <duff@adacore.com>
386
387 * par-ch2.adb (P_Identifier): Warn that "some" is reserved in Ada 2012.
388 * par-ch4.adb (P_Quantified_Expression): Remove unnecessary code for
389 treating "some" as unreserved in earlier Ada versions. This is now
390 handled in Snames.Is_Keyword_Name. Parse "for some" using Tok_Some,
391 rather than Name_Some, since Tok_Some is now recognized as reserved.
392 * scans.adb (Initialize_Ada_Keywords): Handle Tok_Some like any other
393 reserved word.
394 * scans.ads: Minor comment fixes.
395 * snames.adb-tmpl (Is_Keyword_Name): Handle Ada 2012 reserved words as
396 for other language versions.
397 * scn.adb (Scan_Reserved_Identifier): Remove unnecessary code for
398 treating "some" as unreserved in earlier Ada versions. This is now
399 handled in Snames.Is_Keyword_Name.
400 * par-ch3.adb (P_Defining_Identifier): Warn that "some" is reserved in
401 Ada 2012.
402 (P_Subtype_Mark_Resync): Remove unnecessary code for treating "some" as
403 unreserved in earlier Ada versions. This is now handled in
404 Snames.Is_Keyword_Name.
405 * snames.ads-tmpl (Ada_2012_Reserved_Words): Handle Ada 2012 reserved
406 words as for other language versions.
407 * gnat_ugn.texi (-gnatwy): Fix documentation: this switch applies to
408 Ada 2012, not just Ada 2005.
409
d941cee6
AC
4102011-08-29 Ed Schonberg <schonberg@adacore.com>
411
412 * sem_ch13.adb: Additional semantic checks for aspects involved in
413 iterators.
414
4152011-08-29 Matthew Heaney <heaney@adacore.com>
416
417 * a-comutr.ads, a-comutr.adb, a-cimutr.ads, a-cimutr.adb,
418 a-cbmutr.ads, a-cbmutr.adb (Find_In_Subtree): Remove superfluous
419 Container parameter.
420 (Ancestor_Find): ditto.
421
b970af39
TQ
4222011-08-29 Thomas Quinot <quinot@adacore.com>
423
424 * par-endh.adb: Minor reformatting.
d941cee6 425
92db5dee
AC
4262011-08-29 Tristan Gingold <gingold@adacore.com>
427
428 * a-exexpr-gcc.adb (Unwind_Action) Rewrite as an integer with constants.
429 (GNAT_GCC_Exception): Remove N_Cleanups_To_Trigger component.
430 (Adjust_N_CLeanups_For): Remove.
431 (CleanupUnwind_Handler): Call Unhandled_Exception_Terminate when end of
432 stack is reached.
433 (Propgate_Exception): Adjust.
434 * raise-gcc.c: Add a few static/const.
435 (Adjust_N_Cleanups_For): Remove declaration.
436 (PERSONALITY_FUNCTION): Remove code dealing with N_Cleanups_To_Trigger.
437
4382011-08-29 Ed Schonberg <schonberg@adacore.com>
439
440 * sem_ch8.adb: Use type of function return when rewriting as object
441 declaration.
442
1378bf10
AC
4432011-08-29 Gary Dismukes <dismukes@adacore.com>
444
445 * sem_type.adb: Minor reformatting.
446
4472011-08-29 Robert Dewar <dewar@adacore.com>
448
449 * makeutl.adb: Minor reformatting.
450
4512011-08-29 Ed Schonberg <schonberg@adacore.com>
452
453 * sem_ch8.adb (Analyze_Object_Renaming): If the renamed object is a
454 function call of a limited type, the expansion of the renaming is
455 complicated by the presence of various temporaries and subtypes that
456 capture constraints of the renamed object.
457 Rewrite node as an object declaration, whose expansion is simpler.
458 Given that the object is limited there is no copy involved and no
459 performance hit.
460
164e06c6
AC
4612011-08-29 Robert Dewar <dewar@adacore.com>
462
463 * exp_ch5.adb, sinfo.ads, make.adb, s-pooglo.adb, sem_ch12.adb,
464 freeze.adb, sem_ch6.adb, par-ch12.adb: Minor reformatting.
465
4662011-08-29 Tristan Gingold <gingold@adacore.com>
467
468 * system-darwin-x86.ads, system-linux-s390x.ads, system-linux-alpha.ads,
469 system-tru64.ads, system-irix-n32.ads, system-vxworks-arm.ads,
470 system-linux-hppa.ads, system-linux-s390.ads,
471 system-solaris-sparcv9.ads, system-mingw.ads, system-linux-ia64.ads,
472 system-vms_64.ads, system-vxworks-sparcv9.ads, system-linux-ppc.ads,
473 system-aix64.ads, system-lynxos-ppc.ads, system-linux-sh4.ads,
474 system-solaris-x86.ads, system-linux-x86_64.ads, system-linux-x86.ads,
475 system-vxworks-ppc.ads, system-hpux.ads, system-darwin-ppc.ads,
476 system-solaris-sparc.ads, system-lynxos-x86.ads,
477 system-vxworks-m68k.ads, system-hpux-ia64.ads, system-irix-o32.ads,
478 system-solaris-x86_64.ads, system-mingw-x86_64.ads,
479 system-vxworks-mips.ads, system-linux-sparc.ads, system-vms-ia64.ads,
480 system-freebsd-x86.ads, system-aix.ads, system-darwin-x86_64.ads,
481 system-vxworks-x86.ads: Remove GCC_ZCX_Support
482 * s-taprop-posix.adb, s-taprop-irix.adb, s-taprop-vxworks.adb,
483 s-taprop-tru64.adb, s-taprop-linux.adb, s-taprop-solaris.adb: Ditto.
484 * opt.ads: Adjust comment.
485 * targparm.ads, targparm.adb: Remove GCC_ZCX_Support_On_Target.
486 * gnat1drv.adb: Do not check for GCC_ZCX_Support_On_Target.
487 * system.ads: Move GCC_ZCX_Support to obsolete entries.
488
4892011-08-29 Emmanuel Briot <briot@adacore.com>
490
491 * makeutl.adb (Do_Complete): Resolve symbolic links when a relative
492 file name is specified on the gnatmake or gprbuild command line, and
493 before we search for that file in the project.
494
4952011-08-29 Ed Schonberg <schonberg@adacore.com>
496
497 * sem_type.adb (Within_Instance): New predicate in Collect_Interps,
498 used to determine whether a possible interpretation for an overloadable
499 entity is declared within the current instantiation and should be
500 included in the candidate set.
501
5022011-08-29 Vasiliy Fofanov <fofanov@adacore.com>
503
504 * gnat_rm.texi, gnat_ugn.texi: Clean ups.
505
97216ca8
ES
5062011-08-29 Ed Schonberg <schonberg@adacore.com>
507
508 * sem_res.adb (Resolve_Actuals): Use base type to determine whether an
509 access subtype is access_to_subprogram, when applying checks for
510 RM 3.10.2 (27).
511
d3cb4cc0
AC
5122011-08-29 Matthew Heaney <heaney@adacore.com>
513
514 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Splice_Subtree): Only check
515 for sibling when common parent.
516
5172011-08-29 Thomas Quinot <quinot@adacore.com>
518
519 * get_scos.adb: Literals of Pragma_Id are pragma names prefixed with
520 "pragma_".
521
5222011-08-29 Ed Schonberg <schonberg@adacore.com>
523
524 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Enable freeze actions
525 for the return type when in ASIS mode.
526
5272011-08-29 Vincent Celier <celier@adacore.com>
528
529 * make.adb (Gnatmake): Get the default search dirs, then the target
530 parameters after getting the Builder switches, as the Builder switches
531 may include --RTS= and that could change the default search dirs.
532
5332011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
534
535 * exp_ch7.adb (Make_Adjust_Call): Rewrite to mimic the structure of
536 Make_Final_Call. Move the processing for class-wide types before the
537 processing for derivations from [Limited_]Controlled.
538 (Make_Final_Call): Move the processing for class-wide types before the
539 processing for derivations from [Limited_]Controlled.
540 * s-stposu.adb (Allocate_Any_Controlled): Correct the membership check.
541 Add code to account for alignments larger than the list header. Add a
542 comment illustrating the structure of the allocated object + padding +
543 header.
544 (Deallocate_Any_Controlled): Add code to account for alignments larger
545 than the list header.
546
5472011-08-29 Ed Schonberg <schonberg@adacore.com>
548
549 * sinfo.ads, sinfo.adb: New node kind
550 N_Formal_Incomplete_Type_Definition, related flags.
551 par-ch12.adb (P_Formal_Type_Declaration, G_Formal_Type_Definition):
552 Parse formal incomplete types.
553 * sem.adb (Analyze): Formal_Incomplete_Type_Definitions are handled in
554 sem_ch12.
555 * sem_ch7.adb (Analyze_Package_Specification, Unit_Requires_Body):
556 Formal incomplete types do not need completion.
557 * sem_ch12.adb (Analyze_Formal_Incomplete_Type,
558 Validate_Incomplete_Type_Instance): New procedures to handle formal
559 incomplete types.
560 * freeze.adb (Freeze_Entity): Do not freeze the subtype of an actual
561 that corresponds to a formal incomplete type.
562 * sprint.adb: Handle formal incomplete type declarations.
563 * exp_util.adb (Insert_Actions): An incomplete_type_definition is not
564 an insertion point.
565
d3f70b35
AC
5662011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
567
568 * a-fihema.ads, a-fihema.adb: Unit removed.
569 * a-undesu.ads, a-undesu.adb: New unit implementing
570 Ada.Unchecked_Deallocate_Subpool.
571 * einfo.adb: Remove Associated_Collection from the node usage.
572 Add Finalization_Master to the node usage.
573 (Associated_Collection): Removed.
574 (Finalization_Master): New routine.
575 (Set_Associated_Collection): Removed.
576 (Set_Finalization_Master): New routine.
577 (Write_Field23_Name): Remove Associated_Collection from the output. Add
578 Finalization_Master to the output.
579 * einfo.ads: Remove attribute Associated_Collection and its uses in
580 entities.
581 Add new attribute Finalization_Master along with its uses in entitites.
582 (Associated_Collection): Removed along with its pragma import.
583 (Finalization_Master): New routine along with a pragma import.
584 (Set_Associated_Collection): Removed along with its pragma import.
585 (Set_Finalization_Master): New routine along with a pragma import.
586 * exp_ch3.adb (Expand_Freeze_Array_Type): Replace call to
587 Build_Finalization_Collection with Build_Finalization_Master.
588 (Expand_Freeze_Record_Type): Move the generation of Finalize_Address
589 before the bodies of the predefined routines. Add comment explaining
590 this. Replace call to Build_Finalization_Collection with
591 Build_Finalization_Master.
592 (Freeze_Type): Replace call to Build_Finalization_Collection with
593 Build_Finalization_Master.
594 (Make_Finalize_Address_Body): Comment reformatting.
595 (Make_Predefined_Primitive_Specs): Code reformatting.
596 (Stream_Operation_OK): Update comment mentioning finalization
597 collections. Replace RE_Finalization_Collection with
598 RE_Finalization_Master.
599 * exp_ch4.adb (Complete_Controlled_Allocation): Replace call to
600 Associated_Collection with Finalization_Master. Replace call to
601 Build_Finalization_Collection with Build_Finalization_Master.
602 (Expand_Allocator_Expression): Replace call to Associated_Collection
603 with Finalization_Master. Replace call to Set_Associated_Collection with
604 Set_Finalization_Master. Remove the generation of
605 Set_Finalize_Address_Ptr.
606 (Expand_N_Allocator): Replace call to Associated_Collection with
607 Finalization_Master. Remove the generation of Set_Finalize_Address_Ptr.
608 * exp_ch6.adb (Add_Collection_Actual_To_Build_In_Place_Call): Renamed to
609 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Update the
610 comment on usage. Replace call to Needs_BIP_Collection with
611 Needs_BIP_Finalization_Master Remplace BIP_Collection with
612 BIP_Finalization_Master. Update all comments which mention finalization
613 collections. Replace Associated_Collection with
614 Finalization_Master. Replace Build_Finalization_Collection with
615 Build_Finalization_Master.
616 (BIP_Formal_Suffix): Update BIP_Collection's case.
617 (Build_Heap_Allocator): Update the related comment. Rename local
618 variable Collect to Fin_Mas_Id and update its occurrences. Update
619 comments which mention finalization collections. Replace
620 Set_Associated_Collection with Set_Finalization_Master.
621 (Expand_Call): Update the code which detects a special piece of library
622 code for .NET/JVM.
623 (Make_Build_In_Place_Call_In_Allocator): Replace the call to
624 Add_Collection_Actual_To_Build_In_Place_Call with
625 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Remove the code
626 which generates a call to Make_Set_Finalize_Address_Ptr_Call.
627 (Make_Build_In_Place_Call_In_Anonymous_Context): Replace call to
628 Add_Collection_Actual_To_Build_In_Place_Call with
629 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
630 (Make_Build_In_Place_Call_In_Assignment): Replace call to
631 Add_Collection_Actual_To_Build_In_Place_Call with
632 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
633 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
634 * exp_ch6.ads: Rename BIP_Collection to BIP_Finalization_Master.
635 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
636 * exp_ch7.adb (Build_BIP_Cleanup_Stmts): Update comment on usage.
637 Rename local variable Collect to Fin_Mas_Id and update its occurrences.
638 Replace call to Set_Associated_Collection with Set_Finalization_Master.
639 (Build_Finalization_Collection): Renamed to Build_Finalization_Master.
640 Replace the call to Associated_Collection with Finalization_Master.
641 Rename local variable Coll_Id to Fin_Mas_Id and update its occurrences.
642 Update the way finalization master names are generated. Update the
643 retrieval of the correct access type which will carry the pool and
644 master attributes.
645 (Make_Final_Call): Reimplement the way [Deep_]Finalize is retrieved.
646 (Make_Finalize_Address_Body): Abstract types do not need
647 Finalize_Address. Code reformatting.
648 (Make_Finalize_Address_Stmts): Update comment on usage.
649 (Make_Set_Finalize_Address_Ptr_Call): Removed.
650 (Process_Declarations): Update comments.
651 * exp_ch7.ads (Build_Finalization_Collection): Renamed to
652 Build_Finalization_Master. Update associated comment.
653 (Make_Set_Finalize_Address_Ptr_Call): Removed.
654 * exp_ch13.adb: Update comments which mention finalization collections.
655 (Expand_N_Free_Statement): Replace the call to Associated_Collection
656 with Finalization_Master.
657 * exp_util.adb (Build_Allocate_Deallocate_Proc): Reimplemented to
658 create calls to routines Allocate_Any_Controlled and
659 Deallocate_Any_Controlled.
660 (Find_Finalize_Address): New routine.
661 (Is_Allocate_Deallocate_Proc): Update the RTE entities used in the
662 comparison.
663 (Requires_Cleanup_Actions): Update the comment on freeze node
664 inspection.
665 * exp_util.ads: Remove comment on generated code for
666 Build_Allocate_Deallocate_Proc. The code is now quite complex and it
667 is better to simply look in the body.
668 * freeze.adb (Freeze_All): Update the comment of finalization
669 collections. Replace the call to Associated_Collection with
670 Finalization_Master. Replace the call to Build_Finalization_Collection
671 with Build_Finalization_Master.
672 * impunit.adb: Add a-undesu and s-stposu to the list of units.
673 * Makefile.rtl: Add files a-undesu, s-finmas and s-stposu. Remove file
674 a-fihema.
675 * rtsfind.adb (Get_Unit_Name): Remove the processing for children of
676 Ada.Finalization. Add processing for children of System.Storage_Pools.
677 * rtsfind.ads: Remove the naming of second level children of
678 Ada.Finalization.
679 Remove Ada_Finalization_Heap_Management from the list of units.
680 Remove subtype Ada_Finalization_Child.
681 Remove the following subprogram entities:
682
683 RE_Allocate
684 RE_Deallocate
685 RE_Finalization_Collection
686 RE_Finalization_Collection_Ptr
687 RE_Set_Finalize_Address_Ptr
688
689 Add the naming of second level children of System.Storage_Pools.
690 Add System_Finalization_Masters and System_Storage_Pools_Subpools to
691 the list of units.
692 Add subtype System_Storage_Pools_Child.
693 Add the following subprogram entities to System.Finalization_Masters:
694
695 RE_Finalization_Master
696 RE_Finalization_Master_Ptr
697
698 Add the following subprogram entities to System.Storage_Pools.Subpools:
699
700 RE_Allocate_Any_Controlled
701 RE_Deallocate_Any_Controlled
702 RE_Root_Storage_Pool_With_Subpools
703 RE_Root_Subpool
704 RE_Subpool_Handle
705
706 Move the following subprogram entities from
707 Ada.Finalization.Heap_Management to System.Finalization_Masters:
708
709 RE_Add_Offset_To_Address
710 RE_Attach
711 RE_Base_Pool
712 RE_Detach
713
714 * sem_ch3.adb (Access_Type_Declaration): Replace the call to
715 Set_Associated_Collection with Set_Finalization_Master.
716 * sem_ch6.adb (Create_Extra_Formals): Update the way extra formal
717 BIP_Finalization_Master is created.
718 * s-finmas.adb: New unit System.Finalization_Masters.
719 * s-finmas.ads: New unit System.Finalization_Masters.
720 * s-stopoo.ads, s-stopoo.adb: Minor code reformatting.
721 * s-stposu.ads, s-stposu.adb: New unit implementing
722 System.Storage_Pools.Subpools.
723
7242011-08-29 Bob Duff <duff@adacore.com>
725
726 * tbuild.adb: Add assertion.
727
8c889ae4
AC
7282011-08-29 Thomas Quinot <quinot@adacore.com>
729
730 * s-pooglo.adb: Minor reformatting.
731
7322011-08-29 Ed Schonberg <schonberg@adacore.com>
733
734 * exp_ch5.adb (Expand_N_Assignment_Statement): if the left-hand side is
735 an indexed component of a packed array whose element type is a record
736 with a representation clause different from that of the right-hand
737 side, generate a temporary to minimuze the number of bit-field
738 operations generated.
739
7402011-08-29 Ed Schonberg <schonberg@adacore.com>
741
742 * exp_util.adb (Insert_Actions): Use clauses can be part of lists of
743 declarations, and thus are likely insertion points for actions.
744
7452011-08-29 Bob Duff <duff@adacore.com>
746
747 * einfo.ads: Minor comment fix.
748
1a07a71a
AC
7492011-08-29 Robert Dewar <dewar@adacore.com>
750
751 * frontend.adb, gnat1drv.adb: Minor reformatting.
752
7532011-08-29 Tristan Gingold <gingold@adacore.com>
754
755 * s-pooglo.adb (Allocate, Deallocate): Take into account the alignment.
756 * a-fihema.adb (Allocate, Deallocate): Ditto. Possibly add padding
757 space in front of the header.
758
4bcd6411
JK
7592011-08-29 Johannes Kanig <kanig@adacore.com>
760
761 * frontend.adb (Frontend): Exit after creating Standard package when
762 -gnatd.H is present.
763 * gnat1drv.adb (Gnat1drv): Call Backend right away when -gnatd.H is
764 present.
765
f0f88eb6
RD
7662011-08-29 Robert Dewar <dewar@adacore.com>
767
768 * exp_ch9.adb, mlib-prj.adb, prj.adb, prj.ads, ttypes.ads, sem_ch4.adb,
769 makeutl.adb, makeutl.ads, atree.ads, snames.adb-tmpl,
770 snames.ads-tmpl: Minor reformatting.
771
3e37be71
PG
7722011-08-29 Philippe Gil <gil@adacore.com>
773
774 * prj.adb (Reset_Units_In_Table): New procedure.
775 Reset units to avoid access to freed memory.
776
94fb7608
AC
7772011-08-29 Thomas Quinot <quinot@adacore.com>
778
779 * get_scos.adb: When reading a P statement SCO without a pragma name
780 (from an older ALI file), ensure that the Pragma_Name component is set
781 to Unknown_Pragma (not left uninitialized).
782
7832011-08-29 Vincent Celier <celier@adacore.com>
784
785 * makeutl.adb (Get_Directories): New procedure moved from Buildgpr and
786 modified to compute correctly the object path of a SAL project that is
787 extending another library project.
788 (Write_Path_File): New procedure.
789 * makeutl.ads (Directories): New table moved from Buildgpr
790 (Get_Directories): New procedure moved from Buildgpr
791 (Write_Path_File): New procedure
792 * mlib-prj.adb (Build_Library): Use Makeutl.Get_Directories to set the
793 paths before binding SALs, instead of Set_Ada_Paths.
794 * prj-env.adb (Set_Path_File_Var): Procedure has been moved to package
795 Prj.
796 * prj.adb (Set_Path_File_Var): New procedure moved from Prj.Env
797 (Current_Source_Path_File_Of): New function
798 (Set_Current_Object_Path_File_Of): New procedure
799 (Current_Source_Object_File_Of): New function
800 (Set_Current_Object_Path_File_Of): New procedure
801 * prj.ads (Set_Path_File_Var): New procedure moved from Prj.Env
802 (Current_Source_Path_File_Of): New function
803 (Set_Current_Object_Path_File_Of): New procedure
804 (Current_Source_Object_File_Of): New function
805 (Set_Current_Object_Path_File_Of): New procedure
806
8072011-08-29 Ed Schonberg <schonberg@adacore.com>
808
809 * exp_ch5.adb (Expand_N_Assignment_Statement): For an assignment to a
810 packed entity, use a bit-field assignment only if there is no change of
811 representation.
812
c5ecd6b7
AC
8132011-08-29 Thomas Quinot <quinot@adacore.com>
814
815 * rtsfind.ads, exp_ch3.adb (In_Runtime): Minor code improvement, use
816 Is_RTU instead of using Chars comparisons.
817
8182011-08-29 Thomas Quinot <quinot@adacore.com>
819
820 * exp_strm.adb (Build_Mutable_Record_Read_Procedure): Do not create a
821 temporary object if the actual is constrained, and the discriminants
822 read from the stream don't match.
823
8242011-08-29 Tristan Gingold <gingold@adacore.com>
825
826 * sem_attr.adb, exp_attr.adb: Add handling of
827 Attribute_System_Allocator_Alignment
828 * snames.ads-tmpl: Add Name_System_Allocator_Alignment and
829 Attribute_System_Allocator_Alignment.
830 * ttypes.ads, get_targ.ads: Add Get_System_Allocator_Alignment.
831 * gcc-interface/targtyps.c, gcc-interface/utils2.c,
832 gcc-interface/gigi.h: Renames get_target_default_allocator_alignment to
833 get_target_system_allocator_alignment.
834
8352011-08-29 Arnaud Charlet <charlet@adacore.com>
836
837 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
838 dependencies.
839
8abdac29
AC
8402011-08-29 Arnaud Charlet <charlet@adacore.com>
841
842 * exp_ch3.adb (In_Runtime): Fix typo.
843
df170605
AC
8442011-08-29 Bob Duff <duff@adacore.com>
845
846 * sem_ch4.adb (Analyze_Allocator): Analyze the subpool specification.
847
8482011-08-29 Ed Schonberg <schonberg@adacore.com>
849
850 * exp_ch3.adb (Expand_N_Object_Declaration): If the entity is tagged
851 and a separate tag assignment is generated, ensure that the tag
852 assignment is analyzed.
853
864a4236
ES
8542011-08-29 Ed Schonberg <schonberg@adacore.com>
855
856 * atree.ads, atree.adb (Copy_Separate_List): New function that applies
857 Copy_Separate_Tree to a list of nodes. Used to create disjoint copies
858 of statement lists that may contain local declarations.
df170605
AC
859 * exp_ch9.adb (Expand_N_Timed_Entry_Call): Use Copy_Separate_List to
860 duplicate the triggering statements needed for the expansion of this
861 construct, when the trigger is a dispatching call to a synchronized
862 primitive.
864a4236 863
7f394c1d
AC
8642011-08-29 Arnaud Charlet <charlet@adacore.com>
865
866 * gnat_rm.texi: Add doc for 'Elab_Subp_Body.
867 * bindgen.adb: Add comments.
868 * snames.adb-tmpl (Is_Attribute_Name): Only recognize 'Elab_Subp_Body
869 in CodePeer mode.
870
2c1a2cf3
RD
8712011-08-29 Robert Dewar <dewar@adacore.com>
872
873 * exp_attr.adb: Minor reformatting.
874 Minor code reorganization and commenting.
875 * par_sco.adb, checks.adb, sem_attr.adb, get_scos.adb: Minor
876 reformatting.
877
0bfc9a64
AC
8782011-08-29 Thomas Quinot <quinot@adacore.com>
879
880 * get_scos.adb: Ignore chaining indicators not currently supported
881 by Ada.
882
8832011-08-29 Arnaud Charlet <charlet@adacore.com>
884
885 * system.ads: Minor editing.
886
8872011-08-29 Arnaud Charlet <charlet@adacore.com>
888
889 * bindgen.adb (Gen_Elab_Calls): Generate calls to subp'Elab_Subp_Body in
890 CodePeer mode.
891 * sem_attr.ads, sem_attr.adb, exp_Attr.adb, sem_ch6.adb: Add handling of
892 Attribute_Elab_Subp_Body.
893 * snames.ads-tmpl (Attribute_Elab_Subp_Body, Name_Elab_Subp_Body): New.
894 * sem_util.adb: Update comments.
895
828d4cf0
TQ
8962011-08-29 Thomas Quinot <quinot@adacore.com>
897
898 * par_sco.adb, scos.adb, scos.ads, put_scos.adb, get_scos.adb: Record
899 pragma name for each SCO statement corresponding to a pragma.
900
5cd7bb15
AC
9012011-08-29 Arnaud Charlet <charlet@adacore.com>
902
903 * opt.ads: Minor editing.
904
9052011-08-29 Yannick Moy <moy@adacore.com>
906
907 * gnat1drv.adb (Adjust_Global_Switches): Remove options for ALFA mode
908 that only made sense for CodePeer mode.
909
9102011-08-29 Jose Ruiz <ruiz@adacore.com>
911
912 * targparm.ads (Support_64_Bit_Divides_On_Target): Remove this flag
913 which is no longer used.
914 * targparm.adb (S64, S64_Str, Get_Target_Parameters): Remove the
915 handling of the 64-bit division check.
916 * exp_ch4.adb (Expand_N_Op_Divide): Remove the check for 64-bit
917 division available.
918 * system*.ads (Support_64_Bit_Divides): Remove this flag which is no
919 longer used.
920
9212011-08-29 Thomas Quinot <quinot@adacore.com>
922
923 * get_scos.adb: Minor reformatting.
924
25b589cb
AC
9252011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
926
927 * exp_util.adb (Process_Statements_For_Controlled_Objects): Whenever a
928 statement list is wrapped in a block, the block is explicitly analyzed
929 in order to properly redecorate the entities and create a servicing
930 finalizer.
931
9322011-08-29 Tristan Gingold <gingold@adacore.com>
933
934 * sinfo.ads, sinfo.adb (Zero_Cost_Handling): Remove.
935 (Set_Zero_Cost_Handling): Remove.
936
9372011-08-29 Thomas Quinot <quinot@adacore.com>
938
939 * par_sco.adb, scos.ads, put_scos.adb, get_scos.adb: Minor reformatting
940
1197ddb1
AC
9412011-08-29 Geert Bosch <bosch@adacore.com>
942
943 * s-vaflop-vms-alpha.adb (Neg_F): Use subtraction instead of negation
944 instruction, as the latter may produce -0.0, which is not a valid VAX
945 F float number.
946 (Neg_G): Likewise for VAX F float.
947
9482011-08-29 Robert Dewar <dewar@adacore.com>
949
950 * exp_util.adb: Minor reformatting.
951
9522011-08-29 Yannick Moy <moy@adacore.com>
953
954 * sem_ch3.adb: Minor comment update.
955
9562011-08-29 Thomas Quinot <quinot@adacore.com>
957
958 * checks.adb (Apply_Type_Conversion_Checks): Use the Underlying_Type of
959 the operand type.
960
9612011-08-29 Thomas Quinot <quinot@adacore.com>
962
963 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not flush
964 current statement sequence on a generic instantiation or a subprogram
965 declaration.
966
8f66cda7
AC
9672011-08-29 Robert Dewar <dewar@adacore.com>
968
969 * sem_type.adb, einfo.ads, freeze.adb, exp_ch4.adb, sem_ch13.adb:
970 Minor reformatting.
971
9722011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
973
974 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
975 Correct the check which involves the freeze node of a controlled or
976 access-to-controlled type.
977
9782011-08-29 Geert Bosch <bosch@adacore.com>
979
980 * sem_warn.adb (Check_Code_Statement): Remove check for consecutive Asm
981 statements.
982 * s-vaflop-vms-alpha.adb: Remove bogus Volatile => True arguments from
983 Asm statements.
984
cf161d66
AC
9852011-08-29 Yannick Moy <moy@adacore.com>
986
987 * sem_ch3.adb (Array_Type_Declaration): Insert a subtype declaration
988 for every index type and component type that is not a subtype_mark.
989 (Process_Subtype): Set Etype of subtype.
990
9912011-08-29 Robert Dewar <dewar@adacore.com>
992
993 * a-cbmutr.adb, a-cimutr.adb, a-comutr.adb, prj-nmsc.adb: Minor code
994 reorganization. Minor reformatting.
995
7cc83cd8
AC
9962011-08-29 Steve Baird <baird@adacore.com>
997
998 * exp_ch4.adb (Expand_N_Op_Expon): Suppress N_Op_Expon node expansion
999 for CodePeer and ALFA modes.
1000
10012011-08-29 Ed Schonberg <schonberg@adacore.com>
1002
1003 * sem_type.adb (Collect_Interps): Within an instance, collect a homonym
1004 that comes from an enclosing scope if it is not the renaming of an
1005 actual, to handle properly a spurious ambiguity in an instance.
1006
76af4137
AC
10072011-08-29 Eric Botcazou <ebotcazou@adacore.com>
1008
1009 * sem_ch13.adb (Alignment_Check_For_Esize_Change): Rename to...
1010 (Alignment_Check_For_Size_Change): ...this. Add SIZE parameter and
1011 use it instead of the Esize of the first parameter.
1012 (Analyze_Attribute_Definition_Clause) <Object_Size>: Adjust call to
1013 above change.
1014 <Size>: Likewise. Call it for composite types on the RM size.
1015
10162011-08-29 Yannick Moy <moy@adacore.com>
1017
1018 * exp_ch4.adb (Expand_N_Op_Not): Do not expand not on array.
1019 * sem_util.adb (Unique_Name): Correct behaviour for names of
1020 compilation units.
1021
9b20e59b
AC
10222011-08-29 Yannick Moy <moy@adacore.com>
1023
1024 * sem_prag.adb (Check_Precondition_Postcondition): In formal
1025 verification mode, analyze pragma expression for correctness, for
1026 pre/post on library-level subprogram, as it is not expanded later.
1027
10282011-08-29 Yannick Moy <moy@adacore.com>
1029
1030 * exp_aggr.adb (Expand_Array_Aggregate): Do not expand array aggregates
1031 in formal verification.
1032
10332011-08-29 Thomas Quinot <quinot@adacore.com>
1034
1035 * sem_util.adb: Minor reformatting.
1036 * freeze.adb, sem_ch13.adb: Fix comment: Bit_Order is an attribute,
1037 there's no pragma.
1038 * par_sco.ads, par_sco.adb: Update comments.
1039
10402011-08-29 Yannick Moy <moy@adacore.com>
1041
1042 * einfo.adb, einfo.ads: Remove flag Is_Postcondition_Proc and
1043 associated getter/setter.
1044 * sem_ch6.adb: Remove reference to Is_Postcondition_Proc.
1045
10462011-08-29 Vincent Celier <celier@adacore.com>
1047
1048 * prj-attr.adb: New Compiler attribute Dependency_Kind and Language_Kind
1049 * prj-conf.adb: Add_Default_GNAT_Naming_Scheme: Add a package Compiler
1050 with declarations for Language_Kind and Dependency_Kind for Ada.
1051 * prj-nmsc.adb (Check_Unit_Name): New name of procedure Check_Ada_Name
1052 (Process_Compiler): Take into account the new attributes Dependency_Kind
1053 and Language_Kind.
1054 (Check_Configuration): Check if language kind is unit based, not if the
1055 language name is Ada.
1056 (Process_Exceptions_Unit_Based): Ditto
1057 (Add_Language): Remove default additions of language and dependency kind
1058 * prj.ads: Minor comment change
1059 * snames.ads-tmpl: New standard names Dependency_Kind and Language_Kind
1060
10612011-08-29 Johannes Kanig <kanig@adacore.com>
1062
1063 * debug.adb: Update comments.
1064
c5bc3df6
JM
10652011-08-24 Joseph Myers <joseph@codesourcery.com>
1066
1067 * gcc-interface/Make-lang.in (CFLAGS-ada/tracebak.o)
1068 (CFLAGS-ada/targext.o, CFLAGS-ada/cio.o, CFLAGS-ada/init.o)
1069 (CFLAGS-ada/initialize.o, CFLAGS-ada/raise.o): New.
1070 (ada/tracebak.o, ada/targext.o, ada/cio.o, ada/init.o)
1071 (ada/initialize.o, ada/raise.o): Remove explicit compilation rules.
1072
e3aa9eba
RO
10732011-08-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1074
1075 * gcc-interface/Makefile.in (PICFLAG_FOR_TARGET): New.
1076 (GNATLIBCFLAGS_FOR_C): Replace
1077 TARGET_LIBGCC2_CFLAGS by PICFLAG_FOR_TARGET.
1078 (gnatlib-shared-default, gnatlib-shared-dual-win32)
1079 (gnatlib-shared-win32, gnatlib-shared-darwin, gnatlib-shared)
1080 (gnatlib-sjlj, gnatlib-zcx): Likewise.
1081
f446d60e
EB
10822011-08-07 Eric Botcazou <ebotcazou@adacore.com>
1083
1084 * gcc-interface/Makefile.in (raise-gcc.o): Fix previous change.
1085
588c8f48
EB
1086 * gcc-interface/gigi.h (enumerate_modes): Fix formatting.
1087
1088 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Revert latest change.
1089
28d711bf
NR
10902011-08-05 Nicolas Roche <roche@adacore.com>
1091
1092 * gcc-interface/Makefile.in: Don't use directly ../xgcc to build shared
1093 libgnat. Use rather the value of GCC_FOR_TARGET. Fix issue with
1094 canadian cross.
1095 * gcc-interface/Make-lang.in: Add support for canadian cross setting.
1096
993f8920
AC
10972011-08-05 Matthew Heaney <heaney@adacore.com>
1098
1099 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Child_Count, Child_Depth):
1100 subprogram bodies declared out-of-order.
1101
11022011-08-05 Yannick Moy <moy@adacore.com>
1103
1104 * sem_util.adb (Unique_Name): only prefix with "standard" the names of
1105 entities directly in package Standard, otherwise skip the standard
1106 prefix.
1107
9b3956dd
RD
11082011-08-05 Robert Dewar <dewar@adacore.com>
1109
1110 * a-cbmutr.adb: Minor reformatting
1111 (Allocate_Node): refactor node allocation algorithm
1112
11132011-08-05 Robert Dewar <dewar@adacore.com>
1114
1115 * opt.ads, opt.adb (Debug_Pragmas_Disabled): New switch.
1116 * sem_prag.adb (Analyze_Pragma, case Debug_Policy): Implement Disable
1117 mode.
1118 (Analyze_Pragma, case Check_Policy): Ditto.
1119 * sem_prag.ads (Check_Disabled): New function
1120 * snames.ads-tmpl: Add Name_Disable.
1121
11222011-08-05 Robert Dewar <dewar@adacore.com>
1123
1124 * gnat_rm.texi: Document implementation-defined policy DISABLE for
1125 pragmas Assertion_Policy, Check_Policy, Debug_Policy.
1126
79e705d6
AC
11272011-08-05 Ed Schonberg <schonberg@adacore.com>
1128
1129 * sem_prag.adb (Analyze_Pragma, case Inline): reject an Inline pragma
1130 that appears in a generic formal part and applies to a formal
1131 subprogram.
1132
11332011-08-05 Robert Dewar <dewar@adacore.com>
1134
1135 * a-cbmutr.ads: Minor reformatting.
1136
23b6deca
AC
11372011-08-05 Matthew Heaney <heaney@adacore.com>
1138
1139 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Read): do not use T'Valid
1140 to check count, check sign of value instead.
1141 * a-comutr.adb, a-cimutr.adb (Write): return immediately if tree empty
1142 (Copy_Subtree): allocate copy of source element
1143 (Equal_Subtree): compare elements, not access objects
1144
11452011-08-05 Vincent Celier <celier@adacore.com>
1146
1147 * gnat_ugn.texi: Fix VMS alternative.
1148
a2773bd3
AC
11492011-08-05 Thomas Quinot <quinot@adacore.com>
1150
1151 * sem_ch11.adb: Add comment.
1152
11532011-08-05 Robert Dewar <dewar@adacore.com>
1154
1155 * exp_util.adb: Minor comment fix.
1156
11572011-08-05 Robert Dewar <dewar@adacore.com>
1158
1159 * scng.adb (Error_Unterminated_String): Improve flag position when
1160 comma present.
1161
11622011-08-05 Matthew Heaney <heaney@adacore.com>
1163
1164 * Makefile.rtl, impunit.adb: Added a-cbmutr.ad[sb] (bounded multiway
1165 tree containers).
1166 * a-cbmutr.ads, a-cbmutr.adb: This is the new Ada 2012 unit for bounded
1167 multiway tree containers.
1168
11692011-08-05 Robert Dewar <dewar@adacore.com>
1170
1171 * styleg.adb (Check_Comment): Implement comment spacing of 1 or 2
1172 * stylesw.adb: Implement -gnatyC to control comment spacing
1173 * stylesw.ads (Style_Check_Comments_Spacing): New switch (set by
1174 -gnatyc/C).
1175 * usage.adb: Add line for -gnatyC.
1176
11772011-08-05 Robert Dewar <dewar@adacore.com>
1178
f446d60e 1179 * gnat_ugn.texi: Document -gnatyC.
a2773bd3
AC
1180 * vms_data.ads: Implement COMMENTS1/COMMENTS2 (retaining COMMENTS as a
1181 synonym for COMMENTS2).
1182
dedac3eb
RD
11832011-08-05 Robert Dewar <dewar@adacore.com>
1184
1185 * par_sco.adb, sem_ch3.adb, scos.ads, a-iteint.ads, sem_ch12.adb,
1186 a-cimutr.adb, a-cimutr.ads, sem_util.ads, sem_res.adb, a-fihema.adb,
1187 sem_ch4.adb, lib-xref-alfa.adb, exp_disp.adb, a-comutr.adb,
1188 a-comutr.ads, lib-xref.adb: Minor reformatting.
1189
11902011-08-05 Robert Dewar <dewar@adacore.com>
1191
1192 * sem_ch11.adb (Analyze_Raise_Statement): Kill assignment to formal
1193 warning if there is an exception handler present.
1194
7c62a85a
AC
11952011-08-05 Pascal Obry <obry@adacore.com>
1196
1197 * a-iteint.ads: Fix copyright year.
1198
11992011-08-05 Thomas Quinot <quinot@adacore.com>
1200
1201 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not generate a
1202 statement SCO for a USE clause or a representation clause.
1203
12042011-08-05 Yannick Moy <moy@adacore.com>
1205
1206 * lib-xref-alfa.adb (Collect_ALFA): generate the proper relation
1207 between body and spec for stub.
1208 (Detect_And_Add_ALFA_Scope): take into account subprogram stub
1209 * lib-xref.adb (Enclosing_Subprogram_Or_Package): in the case of a
1210 pragma precondition or postcondition, for which the enclosing
1211 subprogram or package in the AST is not the desired one, return empty.
1212
e49208a9
AC
12132011-08-05 Thomas Quinot <quinot@adacore.com>
1214
1215 * g-expect.adb: Minor reformatting.
1216
12172011-08-05 Bob Duff <duff@adacore.com>
1218
1219 * a-fihema.adb: Comment out OS_Lib.
1220
12212011-08-05 Matthew Heaney <heaney@adacore.com>
1222
1223 * Makefile.rtl, impunit.adb: Added a-c[oi]mutr.ad[sb]
1224 (unbounded multiway tree containers) and a-iteint.ads.
1225 * a-comutr.ads, a-comutr.adb:
1226 This is the new Ada 2012 unit for unbounded multiway tree containers
1227 * a-cimutr.ads, a-cimutr.adb
1228 This is the new Ada 2012 unit for indefinite multiway tree containers
1229 * a-iteint.ads: New file.
1230
201cdb74
RO
12312011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1232
f446d60e 1233 * gcc-interface/Makefile.in (raise-gcc.o): Search $(srcdir)/../libgcc.
201cdb74 1234
d50f4827
AC
12352011-08-05 Bob Duff <duff@adacore.com>
1236
1237 * sinfo.ads, sinfo.adb (Subpool_Handle_Name): New attribute for
1238 subpools.
1239 * par-ch4.adb (P_Allocator): Parse new subpool specification syntax.
1240
12412011-08-05 Ed Schonberg <schonberg@adacore.com>
1242
1243 * sem_ch4.adb (Try_Container_Indexing): New procedure to implement the
1244 general indexing aspects of Ada2012. Called when analyzing indexed
1245 components when other interpretations fail.
1246 * sem_ch8.adb (Find_Direct_Name): check for implicit dereference only
1247 in an expression context where overloading is meaningful. This excludes
1248 the occurrence in an aspect specification (efficiency only).
1249 * sem_attr.adb (Analyze_Attribute): indicate that the attributes
1250 related to iterators can be set by an attribute specification, but
1251 cannot be queried.
1252 * sem_ch13.adb (Analyze_Aspect_Specifications): handle
1253 Constant_Indexing and Variable_Indexing.
1254 (Check_Indexing_Functions): New procedure to perform legality checks.
1255 Additional semantic checks at end of declarations.
1256
efe05dfc
AC
12572011-08-05 Sergey Rybin <rybin@adacore.com>
1258
1259 * tree_io.ads: Update ASIS_Version_Number because of the change of the
1260 order of calling Tree_Write/Tree_Read routines made for aspects.
1261
12622011-08-05 Bob Duff <duff@adacore.com>
1263
1264 * a-fihema.adb (Finalize): Fix race condition.
1265
5f9cdefe
AC
12662011-08-05 Yannick Moy <moy@adacore.com>
1267
1268 * sem_ch12.adb (Analyze_Package_Instantiation,
1269 Need_Subprogram_Instance_Body): do not generate instance bodies in ALFA
1270 mode.
1271
12722011-08-05 Ed Schonberg <schonberg@adacore.com>
1273
1274 * sem_type.adb (Specific_Type): in an instance, the type-specific
1275 operand of an equality check that involves null may have a private
1276 type. Use full view to determine legality of construct.
1277
822868aa
AC
12782011-08-05 Vincent Celier <celier@adacore.com>
1279
1280 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
1281 delete or close the file when the call to gnatmake was successful.
1282
12832011-08-05 Yannick Moy <moy@adacore.com>
1284
1285 * gnat1drv.adb (Adjust_Global_Switches): in ALFA mode, set
1286 Global_Discard_Names.
1287
12882011-08-05 Ed Schonberg <schonberg@adacore.com>
1289
1290 * sinfo.ads: comments on use of entity field for aspect specifications.
1291
12922011-08-05 Ed Schonberg <schonberg@adacore.com>
1293
1294 * sem_ch12.adb (Reset_Entity): If the entity field of the associated
1295 node is not itself an entity but a selected component, it is a
1296 rewritten parameterless call to an en enclosing synchronized operation,
1297 and this expansion will be performed again in the instance, so there is
1298 no global information to preserve.
1299
44a10091
AC
13002011-08-05 Javier Miranda <miranda@adacore.com>
1301
1302 * exp_disp.adb (Set_All_DT_Position): Cleanup code and improve support
1303 for renamings of predefined primitives.
1304 (In_Predef_Prims_DT): New subprogram.
1305
13062011-08-05 Ed Schonberg <schonberg@adacore.com>
1307
1308 * sem_util.adb, sem_util.ads (Check_Implicit_Dereference): If a
1309 possible interpretation of name is a reference type, add an
1310 interpretation that is the designated type of the reference
1311 discriminant of that type.
1312 * sem_res.adb (resolve): If the interpretation imposed by context is an
1313 implicit dereference, rewrite the node as the deference of the
1314 reference discriminant.
1315 * sem_ch3.adb (Analyze_Subtype_Declaration, Build_Derived_Record_Type,
1316 Build_Discriminated_Subtype): Inherit Has_Implicit_Dereference from
1317 parent type or base type.
1318 * sem_ch4.adb (Process_Indexed_Component,
1319 Process_Overloaded_Indexed_Component, Indicate_Name_And_Type,
1320 Analyze_Overloaded_Selected_Component, Analyze_Selected_Component):
1321 Check for implicit dereference.
1322 (List_Operand_Interps): Indicate when an implicit dereference is
1323 ambiguous.
1324 * sem_ch8.adb (Find_Direct_Name): Check for implicit dereference.
1325
13262011-08-05 Thomas Quinot <quinot@adacore.com>
1327
1328 * scos.ads: Update documentation of SCO table. Pragma statements can now
1329 be marked as disabled (using 'p' instead of 'P' as the statement kind).
1330 * par_sco.ads, par_sco.adb: Implement the above change.
1331 (Process_Decisions_Defer): Generate a P decision for the first parameter
1332 of a dyadic pragma Debug.
1333 * sem_prag.adb (Analyze_Pragma, case Debug): Mark pragma as enabled if
1334 necessary.
1335 * put_scos.adb: Code simplification based on above change.
1336
bb3c784c
AC
13372011-08-05 Robert Dewar <dewar@adacore.com>
1338
1339 * sem_ch3.adb, gnatcmd.adb, switch-c.adb, exp_attr.adb, make.adb,
1340 bindgen.adb, einfo.adb, sem_ch12.adb, sem_attr.adb, a-fihema.adb,
1341 a-fihema.ads, sem_elab.adb, sem_elab.ads, aspects.adb, opt.ads,
1342 prj-conf.adb, sem_ch13.adb, s-ficobl.ads: Minor reformatting
1343
13442011-08-05 Bob Duff <duff@adacore.com>
1345
1346 * a-stunau.ads, g-spipat.adb: Update comments.
1347
36f686f9
BD
13482011-08-05 Bob Duff <duff@adacore.com>
1349
1350 * a-fihema.ads: Minor comment fix.
1351 * a-fihema.adb (Allocate, Deallocate): Assert that the alignment is
1352 correct.
1353 (Attach, Detach): Remove some unnecessary code.
1354 (Finalize): Remove Node_Ptr_To_Address, replace with a constant.
1355
7882673f
BD
13562011-08-05 Bob Duff <duff@adacore.com>
1357
1358 * a-fihema.ads, a-fihema.adb (Finalization_Collection): Avoid heap
1359 allocation for Objects component. This simplifies the code somewhat. It
1360 is also a little more efficient in the not-so-unusual case where there
1361 are no controlled objects allocated.
1362 Make Finalization_Started flag atomic.
1363 (Finalize): Avoid unnecessary detachment of items from the list.
1364 (pcol): Minor cleanup.
1365
d34cd274
AC
13662011-08-05 Ed Schonberg <schonberg@adacore.com>
1367
1368 * sem_ch12.adb (Analyze_Formal_Package_Declaration): reject a formal
1369 package whose name is the same as that of the generic unit, or its
1370 ultimate prefix.
1371
13722011-08-05 Bob Duff <duff@adacore.com>
1373
1374 * a-fihema.adb, a-fihema.ads: Minor comment improvements.
1375 * sem_ch3.adb, exp_ch5.adb, exp_ch7.adb, exp_ch7.ads, exp_util.adb:
1376 Minor comment fixes.
1377
00332244
AC
13782011-08-05 Arnaud Charlet <charlet@adacore.com>
1379
1380 * make.adb (Linking_Phase): No longer need to set source search path
1381 before calling gnatlink in CodePeer mode.
1382 * gnatlink.adb (Gnatlink): No longer pass -gnat83/95/05/12 switch to
1383 gcc in CodePeer mode, since the binder generated file no longer has a
1384 'with Main'.
1385 * switch.ads, switch.adb (Is_Language_Switch): Removed.
1386 * switch-c.adb: Update comment.
1387
13882011-08-05 Thomas Quinot <quinot@adacore.com>
1389
1390 * exp_strm.adb, bindgen.adb, s-ficobl.ads: Minor reformatting.
1391
13922011-08-05 Nicolas Roche <roche@adacore.com>
1393
1394 * gnat_ugn.texi: Fix minor syntax error issue.
1395
13962011-08-05 Vincent Celier <celier@adacore.com>
1397
1398 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
1399 delete or close the file when the call to gnatmake returns a non
1400 successful return code.
1401
14022011-08-05 Ed Schonberg <schonberg@adacore.com>
1403
1404 * exp_ch4.adb (Expand_N_Type_Conversion): When expanding a predicate
1405 check, indicate that the copy of the original node does not come from
1406 source, to prevent an infinite recursion of the expansion.
1407
14082011-08-05 Johannes Kanig <kanig@adacore.com>
1409
1410 * debug.adb: document switch -gnatd.G for gnat2why, which deactivates
1411 VC generation for subprogram bodies.
1412
14132011-08-05 Yannick Moy <moy@adacore.com>
1414
1415 * einfo.ads: Typo.
1416 * sem_ch3.adb (Signed_Integer_Type_Declaration): in ALFA mode, define
1417 the base type with the smallest allowed base type.
1418
14192011-08-05 Sergey Rybin <rybin@adacore.com>
1420
1421 * tree_gen.adb, tree_in.adb, aspects.adb: Fix tree read-write for
1422 aspects.
1423
14242011-08-05 Ed Schonberg <schonberg@adacore.com>
1425
1426 * sem_ch12.ads: minor comment updates.
1427
14282011-08-05 Ed Schonberg <schonberg@adacore.com>
1429
1430 * sem_ch12.adb (Analyze_Formal_Package_Declaration): in an
1431 instantiation and a formal package the compiler generates a package
1432 renaming declaration so that the generic name within the declaration
1433 is interpreted as a renaming of the instance. At the end of a formal
1434 package declaration, this renaming must become invisible.
1435
0da80d7d
AC
14362011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
1437
1438 * exp_ch7.adb (Is_Init_Call): Reimplemented to avoid character
1439 comparison and rely on concrete entities instead.
1440
14412011-08-05 Ed Schonberg <schonberg@adacore.com>
1442
1443 * einfo.ads, einfo.adb (Has_Implicit_Dereference): new flag on types
1444 and discriminants, to indicate that the type has an access discriminant
1445 that supports implicit dereference.
1446 * snames.ads-tmpl: Add names of aspects and attributes related to
1447 Ada2012 iterators: constant_indexing, default_iterator,
1448 iterator_element, implicit_dereference, variable_indexing.
1449 * aspects.ads, aspects.adb: entries for iterator-related aspects.
1450 * sem_ch13.adb (Analyze_aspect_specifications): dummy entries for
1451 iterator-related aspects.
1452 * sem_attr.adb, exp_attr.adb Dummy entries for iterator-related aspects.
1453
14542011-08-05 Sergey Rybin <rybin@adacore.com>
1455
1456 * gnat_ugn.texi, vms_data.ads: Extend the subsection about coupling
1457 metrics in gnatmetric to cover new kinds of coupling mentrics.
1458
14592011-08-05 Steve Baird <baird@adacore.com>
1460
1461 * bindgen.adb (Gen_CodePeer_Wrapper): Call Ada_Main_Program instead
2c7f9cc0 1462 of calling the user-defined main subprogram.
0da80d7d
AC
1463 (Gen_Main): Declare Ada_Main_Program and (if CodePeer_Mode
1464 is set) Call_Main_Subprogram ahead of, as opposed to
1465 inside of, Main.
1466 (Gen_Output_File_Ada): Remove CodePeer_Mode-conditional
1467 generation of a "with" of the user-defined main subprogram.
1468 Remove CodePeer_Mode-conditional call to Gen_CodePeer_Wrapper
1469 (which is now called from Gen_Main instead).
1470
73242473
AC
14712011-08-05 Emmanuel Briot <briot@adacore.com>
1472
1473 * projects.texi: Added reference to the Makefile package.
1474
14752011-08-05 Thomas Quinot <quinot@adacore.com>
1476
1477 * exp_ch7.adb: Minor comment rewording.
1478
14792011-08-05 Ed Falis <falis@adacore.com>
1480
1481 * env.c: Fix comment.
1482
14832011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
1484
1485 * sem_elab.adb (Is_Finalization_Procedure): Reimplemented to avoid
1486 character comparison and rely on concrete entities instead.
1487
97ed5872
AC
14882011-08-05 Ed Schonberg <schonberg@adacore.com>
1489
1490 * sem_ch3.adb: (Check_Private_Overriding): better error message,
1491 suggested by AI95-0068.
1492
14932011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
1494
1495 * exp_ch7.adb (Find_Last_Init): Use Next_Suitable_Statement to retrieve
1496 the two potential initialization calls. This accounts for any
1497 access-before-elaboration checks which may precede the initialization
1498 calls.
1499 (Next_Suitable_Statement): New routine. Returns the next real statement
1500 after the input node while skipping generated checks.
1501 * sem_elab.adb (Check_A_Call): New formal parameter In_Init_Proc along
1502 with comment on usage.
1503 Do not generate Elaborate_All when the trigger is a finalization call
1504 coming from a type init proc.
1505 (Check_Elab_Call): Propagate the initialization procedure context to
1506 subsequent calls to Check_A_Call.
1507 (Check_Internal_Call_Continue): Propagate the initialization procedure
1508 context to subsequent calls to Check_Elab_Call.
1509 (Is_Finalization_Procedure): New routine. Returns True if the input
1510 entity denotes a [Deep_]Finalize routine.
1511 * sem_elab.ads (Check_Elab_Call): New formal parameter In_Init_Proc
1512 along with comment on usage.
1513
15142011-08-05 Vadim Godunko <godunko@adacore.com>
1515
1516 * s-atocou.ads: Add list of supported platforms.
1517
15182011-08-05 Yannick Moy <moy@adacore.com>
1519
1520 * sem_prag.adb, restrict.adb: Correct style for or'ing Boolean variables
1521
1522 * opt.ads (Disable_ALI_File): new Boolean flag
1523 * lib-writ.adb (Write_ALI): when Disable_ALI_File is set, do nothing
1524
15252011-08-05 Ed Falis <falis@adacore.com>
1526
1527 * env.c (__gnat_environ): Fix includes for RTPs and VTHREADS so that
1528 environ is properly defined.
1529
15302011-08-05 Vincent Celier <celier@adacore.com>
1531
1532 * make.adb (Compilation_Phase): Exit immediately when all objects have
1533 been found up to date, to avoid multiple exit messages.
1534 * prj-nmsc.adb (Add_Source): Allow duplicate source file names in the
1535 same project for languages with no compiler.
1536 * gnat_ugn.texi: Document compiler switch -gnateI and gnatmake switch
1537 -eI.
9aff36e9
RD
15382011-08-05 Robert Dewar <dewar@adacore.com>
1539
1540 * exp_ch7.ads, sem_type.adb, make.adb, sem_prag.adb, sem_util.adb,
1541 sem_util.ads, sem_attr.adb, restrict.ads, sem_ch6.adb, prj-conf.adb,
1542 prj-conf.ads, s-atocou.ads, s-atocou.adb, s-atocou-x86.adb,
1543 s-atocou-builtin.adb: Minor reformatting.
1544
406935b6
AC
15452011-08-05 Yannick Moy <moy@adacore.com>
1546
1547 * exp_ch7.adb (Establish_Transient_Scope): in formal verification mode,
1548 if the node to wrap is a pragma check, this node and enclosed
1549 expression are not expanded, so do not apply any transformations here.
1550 * exp_prag.adb (Expand_Pragma_Check): document the need to avoid
1551 introducing transient scopes.
1552
15532011-08-05 Jose Ruiz <ruiz@adacore.com>
1554
1555 * adaint.c (__gnat_set_writable, __gnat_set_readable,
1556 __gnat_set_executable, __gnat_set_non_writable, __gnat_set_non_readable,
1557 __gnat_copy_attribs): On VxWorks 6.x and later, the required chmod
1558 routine is available, so we use the default implementation of these
1559 functions.
1560 * s-os_lib.ads (Copy_File, Copy_Time_Stamps): Document that there is
1561 support for copying attributes on VxWorks 6.
1562
15632011-08-05 Yannick Moy <moy@adacore.com>
1564
1565 * debug.adb: Remove use of -gnatd.D.
1566 * gnat1drv.adb (Adjust_Global_Switches): adjust switches for ALFA mode
1567 * opt.ads: Simplify variables for ALFA mode, to keep one only
1568 * restrict.adb, sem_prag.adb: Adapt treatment done for CodePeer mode
1569 to ALFA mode.
1570
15712011-08-05 Vincent Celier <celier@adacore.com>
1572
1573 * prj-conf.adb (Do_Autoconf): Look also for --RTS in
1574 Builder'Default_Switches.
1575
15762011-08-05 Vincent Celier <celier@adacore.com>
1577
1578 * makeusg.adb: Add lines for --create-map-file switches.
1579
15802011-08-05 Ed Schonberg <schonberg@adacore.com>
1581
1582 * freeze.adb (Freeze_Entity): For a subprogram, if a type in the
1583 profile is incomplete and the full view is available, replace it with
1584 the full view.
1585 * sem_ch6.adb (Possible_Freeze): if a type in the profile is
1586 incomplete, freezing the subprogram is delayed until the full view is
1587 frozen.
1588 * sem_type.adb (Disambiguate): an ambiguity between a user-defined
1589 fixed-point multiplication operator and the predefined operator is
1590 resolved in favor of the user-defined one.
1591
96c891b3
RO
15922011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1593
1594 * init.c [__alpha__ && __osf__] (__gnat_error_handler): Use
1595 CONST_CAST.
1596
276e7ed0
AC
15972011-08-04 Ed Schonberg <schonberg@adacore.com>
1598
1599 * sem_util.ads, sem_unit.adb (Type_Without_Stream_Operation): determine
1600 whether a type lacks user-defined Read or Write operations, or has a
1601 component that lacks them.
1602 * sem_attr.adb (Check_Stream_Attribute): if restriction
1603 No_Default_Stream_Attributes is active, verify that all subcomponent
1604 types of the target have user-defined stream operations, and report
1605 error otherwise.
1606 * exp_ch3.adb (Stream_Operqtion_OK): use Type_Without_Stream_Operation.
1607 * exp_strm.adb: Build_Elementary_Input_Call,
1608 Build_Elementary_Write_Call): remove checks for restriction
1609 No_Default_Stream_Attributes, now checked in semantics.
1610
16112011-08-04 Vincent Celier <celier@adacore.com>
1612
1613 * prj-conf.ads, prj-conf.adb (Do_Autoconf): If there is no --RTS
1614 switches on the command line, look for all valid --RTS switches in the
1615 Builder switches and for each language use the first runtime name found
1616 to invoke gprconfig.
1617 (Get_Or_Create_Configuration_File): Warn if --RTS is specified on the
1618 command line and there is no auto-configuration.
1619 (Runtime_Name_Set_For): New function.
1620
16212011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
1622
1623 * exp_ch7.adb (Build_Object_Declarations): Do not generate the
1624 elaborate initialization expression for variable Abort when processing
1625 a package body or a declaration.
1626 (Create_Finalizer): Propagate the package context when creating the
1627 exception-related variables.
1628 * exp_ch7.ads (Build_Object_Declarations): New formal parameter
1629 For_Package along with usage comment.
1630
19172ae9
AC
16312011-08-04 Arnaud Charlet <charlet@adacore.com>
1632
1633 * gcc-interface/Makefile.in: Clean up targets.
1634 Enable new package for atomic counters and copy-on-write implementation
1635 of unbounded strings on x86 platforms.
1636 * gcc-interface/Make-lang.in: Update dependencies.
1637
0319cacc
AC
16382011-08-04 Robert Dewar <dewar@adacore.com>
1639
1640 * exp_ch7.adb: Minor reformatting.
1641
16422011-08-04 Robert Dewar <dewar@adacore.com>
1643
1644 * exp_strm.adb: Minor reformatting.
1645
16462011-08-04 Vadim Godunko <godunko@adacore.com>
1647
1648 * s-atocou.adb: Replace by dummy version and use on targets where atomic
1649 operations are not supported.
1650 * s-atocou-builtin.adb: Renamed from s-atocou.adb.
1651 * s-atocou-x86.adb: New file.
1652 * Makefile.rtl: Add s-atocou.o file
1653
16542011-08-04 Arnaud Charlet <charlet@adacore.com>
1655
1656 * make.adb (Compile): Move setting of CodePeer_Mode to ...
1657 (Compilation_Phase): ... here.
1658 (Scan_Make_Arg): Now bind and link by default in CodePeer mode.
1659
16602011-08-04 Thomas Quinot <quinot@adacore.com>
1661
1662 * Make-generated.in: Fix minor typo in comment.
1663
26e7e1a0
AC
16642011-08-04 Thomas Quinot <quinot@adacore.com>
1665
1666 * gnatls.adb: Use Prj.Env.Initialize_Default_Project_Path to retrieve
1667 the project path.
1668
16692011-08-04 Robert Dewar <dewar@adacore.com>
1670
1671 * a-coinho.adb: Minor reformatting.
1672
16732011-08-04 Robert Dewar <dewar@adacore.com>
1674
1675 * a-coinho.ads: Minor reformatting.
1676
16772011-08-04 Vadim Godunko <godunko@adacore.com>
1678
1679 * s-atocou.ads, s-atocou.adb: New files.
1680 * a-strunb-shared.ads, a-strunb-shared.adb, a-stwiun-shared.ads,
1681 a-stwiun-shared.adb, a-stzunb-shared.ads, a-stzunb-shared.adb: Remove
1682 direct use of GCC's atomic builtins and replace them by use of new
1683 atomic counter package.
1684
16852011-08-04 Ed Schonberg <schonberg@adacore.com>
1686
1687 * exp_strm.adb: better error message for No_Default_Stream_Attributes.
1688
16892011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
1690
1691 * a-tags.adb (Unregister_Tag): Replace the complex address arithmetic
1692 with a call to Get_External_Tag.
1693 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on
1694 subprogram usage. Remove the guard against package declarations and
1695 bodies since Build_Cleanup_Statements is no longer invoked in that
1696 context.
1697 (Build_Components): Initialize Tagged_Type_Stmts when the context
1698 contains at least one library-level tagged type.
1699 (Build_Finalizer): New local variables Has_Tagged_Types and
1700 Tagged_Type_Stmts along with associated comments on usage. Update the
1701 logic to include tagged type processing.
1702 (Create_Finalizer): Insert all library-level tagged type unregistration
1703 code before the jump block circuitry.
1704 (Expand_N_Package_Body): Remove the call to Build_Cleanup_Statements.
1705 (Expand_N_Package_Declaration): Remove the call to
1706 Build_Cleanup_Statements.
1707 (Process_Tagged_Type_Declaration): New routine. Generate a call to
1708 unregister the external tag of a tagged type.
1709 (Processing_Actions): Reimplemented to handle tagged types.
1710 (Process_Declarations): Detect the declaration of a library-level
1711 tagged type and carry out the appropriate actions.
1712 (Unregister_Tagged_Types): Removed. The machinery has been directly
1713 merged with Build_Finalizer.
1714
7483c888
AC
17152011-08-04 Robert Dewar <dewar@adacore.com>
1716
1717 * bindgen.ads, gnatlink.adb, sem_ch4.adb, gnatbind.adb, put_alfa.adb,
1718 gnatls.adb, exp_ch3.adb: Minor reformatting.
1719
17202011-08-04 Marc Sango <sango@adacore.com>
1721
1722 * sem_attr.adb (Analyze_Attribute): Replace the message
1723 "invisible attribute of}" of the spark restriction violation in
1724 attribute reference by the simple message "invisible attribute of type".
1725 Indeed, the node value Error_Msg_Node_1 used is in conflit with the
1726 two insertion characters: '&' and '}'.
1727
17282011-08-04 Vadim Godunko <godunko@adacore.com>
1729
1730 * impunit.adb (Non_Imp_File_Names_12): Add "a-coinho".
1731 * a-coinho.ads, a-coinho.adb: New file.
1732 * Makefile.rtl: Add Ada.Containers.Indefinite_Holders.
1733
5207696c
AC
17342011-08-04 Nicolas Roche <roche@adacore.com>
1735
1736 * alfa_test.adb: Not all ali files are containing alfa information even
1737 if compiled with -gnatd.F. So suppress warning about missing ALFA
1738 information.
1739
17402011-08-04 Yannick Moy <moy@adacore.com>
1741
1742 * lib-xref-alfa.adb (Add_ALFA_Scope): use non-empty unique name for
1743 scope.
1744 * put_alfa.adb: Check that scope name is not empty.
1745
17462011-08-04 Ed Schonberg <schonberg@adacore.com>
1747
1748 * exp_ch3.adb (Stream_Operation_Ok): new predicate
1749 Needs_Elementary_Stream_Operation, to determine whether user-defined
1750 Read and Write attributes are available for the elementary components
1751 of the given type. If only the predefined attributes are available,
1752 then when restriction No_Default_Stream_Attributes is active the
1753 predefined stream attributes for the composite type cannot be created.
1754
17552011-08-04 Robert Dewar <dewar@adacore.com>
1756
1757 * bindgen.adb: Fix obsolete comments and names from Ada/C days.
1758 Put routines in alpha order
1759
2bd2d858
JR
17602011-08-04 Jose Ruiz <ruiz@adacore.com>
1761
1762 * gcc-interface/Makefile.in: Remove xenomai specific versions of system.
1763 * gcc-interface/Make-lang.in: Update dependencies.
1764
8fae6016
AC
17652011-08-04 Arnaud Charlet <charlet@adacore.com>
1766
1767 * gcc-interface/lang.opt: Add AdaWhy language, simimlar to Ada.
1768 * gcc-interface/lang-specs.h: Add handling of AdaWhy specs (calls
1769 gnat1why).
1770
a54d0eb4
AC
17712011-08-04 Robert Dewar <dewar@adacore.com>
1772
1773 * sem_ch3.adb, make.adb, a-cohata.ads, sem_prag.adb, makeutl.adb,
1774 lib-xref-alfa.adb: Minor reformatting.
1775
17762011-08-04 Marc Sango <sango@adacore.com>
1777
1778 * sem_ch12.adb (Analyze_Generic_Package_Declaration,
1779 Analyze_Generic_Subprogram_Declaration, Analyze_Package_Instantiation,
1780 Analyze_Subprogram_Instantiation): Check absence of generic in SPARK
1781 mode.
1782
17832011-08-04 Tristan Gingold <gingold@adacore.com>
1784
1785 * bindgen.adb (Gen_Adainit_C): Remove.
1786 (Gen_Adafinal_C): Ditto.
1787 (Gen_Elab_Externals_C): Ditto.
1788 (Gen_Elab_Calls_C): Ditto.
1789 (Gen_Elab_Order_C): Ditto.
1790 (Gen_Elab_Defs_C): Ditto.
1791 (Gen_Finalize_Library_C): Ditto.
1792 (Gen_Finalize_Library_Defs_C): Ditto.
1793 (Gen_Main_C): Ditto.
1794 (Gen_Output_File_C): Ditto.
1795 (Gen_Restrictions_C): Ditto.
1796 (Gen_Versions_C): Ditto.
1797 (Write_Info_Ada_C): Ditto.
1798 (Gen_Object_Files_Options): Call WBI instead of Write_Info_Ada_C
1799 (Gen_Output_File): Do not force Ada_Bind_File anymore.
1800 Always call Gen_Output_File_Ada.
1801 * gnatlink.adb (Begin_Info): Now a constant.
1802 (End_Info): Ditto.
1803 (Ada_Bind_File): Remove
1804 (Process_Args): Do not handle -A/-C. Remove not Ada_Bind_File cases.
1805 * switch-b.adb (Scan_Binder_Switches): Do not handle -C.
1806 * gnatbind.adb (Gnatbind): Remove not Ada_Bind_File cases.
1807 * opt.ads (Ada_Bind_File): Remove.
1808
18092011-08-04 Thomas Quinot <quinot@adacore.com>
1810
1811 * projects.texi: Document target-specific directory in default project
1812 path for gnatmake.
1813
18142011-08-04 Thomas Quinot <quinot@adacore.com>
1815
1816 * gnatls.adb, prj-env.adb: Add $prefix/share/gpr to default project
1817 path in all cases .
1818
24558db8
AC
18192011-08-04 Yannick Moy <moy@adacore.com>
1820
1821 * sem_ch3.adb, sem_ch5.adb, sem_util.adb, sem_ch4.adb, sem_ch8.adb,
1822 opt.ads, lib-xref.ads: Code clean up.
1823
18242011-08-04 Yannick Moy <moy@adacore.com>
1825
1826 * gnat_rm.texi: Update description of Test_Case
1827 * gnat_ugn.texi: Typo.
1828
18292011-08-04 Ed Falis <falis@adacore.com>
1830
1831 * adaint.c (__gnat_get_number_of_cpus): fix typo in last checkin.
1832
18332011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
1834
1835 * exp_ch4.adb (Suitable_Element): Skip field _parent on .NET/JVM when
1836 it is of type Root_Controlled. This action eliminates fields Prev and
1837 Next from type equality.
1838
18392011-08-04 Yannick Moy <moy@adacore.com>
1840
1841 * lib-xref-alfa.adb: Correct typo.
1842
18432011-08-04 Matthew Heaney <heaney@adacore.com>
1844
1845 * a-cohata.ads (Hash_Table_Type): default-initialize the Nodes
1846 component.
1847
1f9939b5
AC
18482011-08-04 Yannick Moy <moy@adacore.com>
1849
1850 * sem_prag.adb (Check_Arg_Is_String_Literal): remove useless procedure
1851 (Analyze_Pragma): allow static string expression for name of Test_Case,
1852 instead of simply string literals.
1853 * sem_util.adb (Get_Name_From_Test_Case_Pragma): adapt to static string
1854 expressions.
1855
18562011-08-04 Vincent Celier <celier@adacore.com>
1857
1858 * makeutl.adb (Complete_Mains.Find_File_Add_Extension): Use canonical
1859 case suffixes to find truncated main sources.
1860
18612011-08-04 Tristan Gingold <gingold@adacore.com>
1862
1863 * impunit.adb (Non_Imp_File_Names_95): Add g-tastus.
1864 s-stusta.adb (Compute_All_Task): Use Put_Line instead of Put.
1865 (Compute_Current_Task): Ditto.
1866
18672011-08-04 Tristan Gingold <gingold@adacore.com>
1868
1869 * gnat_ugn.texi: Mention GNAT.Task_Stack_Usage.
1870
18712011-08-04 Yannick Moy <moy@adacore.com>
1872
1873 * lib-xref-alfa.adb (Is_Global_Constant): new function that detects
1874 library-level constant.
1875 (Add_ALFA_Xrefs): ignore global constants in ALFA xref.
1876 * sem_res.adb (Resolve_Actuals): do not add cross-reference to Formal
1877 used as selector of parameter association, in ALFA mode.
1878
15d8a51d
AC
18792011-08-04 Robert Dewar <dewar@adacore.com>
1880
1881 * exp_ch5.adb, exp_ch7.adb, exp_util.adb, bindgen.adb, sem_prag.adb,
1882 s-tassta.adb, exp_ch4.adb, exp_disp.adb, s-stausa.adb: Minor
1883 reformatting.
1884
18852011-08-04 Arnaud Charlet <charlet@adacore.com>
1886
1887 * make.adb (Linking_Phase): Set source search path before calling
1888 gnatlink in CodePeer mode.
1889
f46faa08
AC
18902011-08-04 Javier Miranda <miranda@adacore.com>
1891
1892 * exp_ch7.adb (Expand_N_Package_Body, Expand_N_Package_Declaration):
1893 Remove code which takes care of building TSDs.
1894 * rtsfind.ads (RE_Check_Interface_Conversion): New entity.
1895 * exp_ch4.adb (Apply_Accessibility_Check): Add support for generating
1896 the accessibility check in VM targets.
1897 * exp_disp.adb (Make_VM_TSD): Spec moved to exp_disp.ads
1898 (Building_Static_DT): Now returns false for VM targets.
1899 (Build_VM_TSDs): Removed.
1900 (Expand_Interface_Conversion): Generate missing runtime check for
1901 conversions to interface types whose target type is unknown at compile
1902 time.
1903 (Make_VM_TSD): Add missing code to disable the generation of calls to
1904 Check_TSD if the tagged type is not defined at library level, or not
1905 has a representation clause specifying its external tag, or -gnatdQ is
1906 active.
1907 * exp_disp.ads (Build_VM_TSDs): Removed.
1908 (Make_VM_TSDs): Spec relocated from exp_disp.adb
1909 * sem_disp.adb (Check_Dispatching_Operation): No code required to
1910 register primitives in the dispatch tables in VM targets.
1911 * exp_ch3.adb (Expand_N_Object_Declaration): Remove wrong expansion of
1912 initialization of class-wide interface objects in VM targets.
1913 (Expand_Freeze_Record_Type): For VM targets call Make_VM_TSD (instead
1914 of Make_DT).
1915
19162011-08-04 Jerome Lambourg <lambourg@adacore.com>
1917
1918 * gnatlink.adb (Gnatlink): Correct missleading error message displayed
1919 when dotnet-ld cannot be found.
1920
19212011-08-04 Arnaud Charlet <charlet@adacore.com>
1922
1923 * bindgen.adb: Simplify significantly generation of binder body file in
1924 CodePeer mode.
1925 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Prevent assert failure
1926 when compiling binder generated file in CodePeer mode (xxx'Elab_Spec
1927 not expanded).
1928
2ba7e31e
AC
19292011-08-04 Yannick Moy <moy@adacore.com>
1930
1931 * sem_prag.adb, sem.ads: Code cleanup.
1932
19332011-08-04 Tristan Gingold <gingold@adacore.com>
1934
1935 * s-tassta.adb (Task_Wrapper): Rewrite the dynamic stack usage part.
1936 * s-stausa.adb, s-stausa.ads: Major rewrite. Now provides accurate
1937 results if possible.
1938 * s-stusta.adb (Print): Adjust after changes in s-stausa.
1939 * gnat_ugn.texi: Update dynamic stack usage section.
1940
19412011-08-04 Steve Baird <baird@adacore.com>
1942
1943 * bindgen.adb (Gen_CodePeer_Wrapper): new procedure.
1944 Generate (if CodePeer_Mode is set) a "wrapper" subprogram which
1945 contains only a call to the user-defined main subprogram.
1946 (Gen_Main_Ada) - If CodePeer_Mode is set, then
1947 call the "wrapper" subprogram instead of directly
1948 calling the user-defined main subprogram.
1949
19502011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
1951
1952 * exp_ch5.adb (Expand_N_Case_Statement): Check the statements of all
1953 alternatives of a case statement for controlled objects. Rename local
1954 variable A to Dead_Alt.
1955 (Expand_N_If_Statement): Check the then and else statements of an if
1956 statement for controlled objects. Check the then statements of all
1957 elsif parts of an if statement for controlled objects.
1958 (Expand_N_Loop_Statement): Check the statements of a loop for controlled
1959 objects.
1960 * exp_ch7.adb (Process_Transient_Objects): Rewrite the condition which
1961 detects a loop associated with the expansion of an array object.
1962 Augment the processing of the loop statements to account for a possible
1963 wrap done by Process_Statements_For_Controlled_Objects.
1964 * exp_ch9.adb (Expand_N_Asynchronous_Select): Check the triggering
1965 statements and abortable part of an asynchronous select for controlled
1966 objects.
1967 (Expand_N_Conditional_Entry_Call): Check the else statements of a
1968 conditional entry call for controlled objects.
1969 (Expand_N_Selective_Accept): Check the alternatives of a selective
1970 accept for controlled objects.
1971 (Expand_N_Timed_Entry_Call): Check the entry call and delay
1972 alternatives of a timed entry call for controlled objects.
1973 * exp_ch11.adb (Expand_Exception_Handlers): Check the statements of an
1974 exception handler for controlled objects.
1975 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
1976 Add formal parameter Nested_Constructs along with its associated
1977 comment.
1978 (Requires_Cleanup_Actions (Node_Id)): Update all calls to
1979 Requires_Cleanup_Actions.
1980 (Process_Statements_For_Controlled_Objects): New routine.
1981 * exp_util.ads (Process_Statements_For_Controlled_Objects): New
1982 routine. Inspect a node which contains a non-handled sequence of
1983 statements for controlled objects. If such an object is found, the
1984 statements are wrapped in a block.
1985
1bf773bb
AC
19862011-08-04 Bob Duff <duff@adacore.com>
1987
1988 * sem_type.adb (Covers): If T2 is a subtype of a class-wide type, we
1989 need to compare with Class_Wide_Type (T2), in order to get at the
1990 original class-wide type node.
1991 * sem_type.ads (Covers): Improve the comment.
1992 * einfo.ads (Class_Wide_Type): Improve the comment.
1993 * exp_intr.adb (Expand_Unc_Deallocation): Remove unnecessary setting of
1994 the type of the Deref.
1995
19962011-08-04 Yannick Moy <moy@adacore.com>
1997
1998 * gnat_rm.texi: Document that Test_Case pragma can only appear on
1999 separate declarations.
2000 * sem_prag.adb (procedure Check_Identifier_Is_One_Of): new procedure to
2001 check identifier of pragma argument.
2002 (Chain_TC): check that no other test case associated to the same entity
2003 share the same name.
2004 (Check_Test_Case): disallow test case inside subprogram body
2005 (Analyze_Pragma): correct call to check identifier and not argument
2006 * sem_util.adb, sem_util.ads (Get_Name_From_Test_Case_Pragma): new
2007 function gets name from test case pragma.
2008
dac3bede
YM
20092011-08-04 Yannick Moy <moy@adacore.com>
2010
2011 * gnat_rm.texi: Document new pragma and aspect.
2012 * aspects.adb, aspects.ads (Aspect_Id): new value Aspect_Test_Case
2013 (No_Duplicates_Allowed): new constant array defining whether duplicates
2014 aspects of each kind can appear on the same declaration.
2015 * einfo.adb, einfo.ads (Spec_PPC_List): replace field with Contract
2016 field, which points to a node holding the previous Spec_PPC_List.
2017 * exp_ch9.adb, sem_ch6.adb, sem_prag.adb: Reach to Spec_PPC_List
2018 through the indirection with Contract.
2019 * exp_util.adb (Insert_Actions): raise Program_Error on N_Contract node
2020 * par-prag.adb (Prag): do nothing on Test_Case pragma
2021 * sem.adb (Analyze): abort on N_Contract, on which Analyze should not
2022 be called directly.
2023 * sem_attr.adb (Analyze_Attribute): allow attribute 'Result in
2024 component Ensures of Test_Case.
2025 * sem_ch12.adb, sem_ch6.adb, sem_ch9.adb
2026 (Analyze_Generic_Subprogram_Declaration,
2027 Analyze_Subprogram_Instantiation,
2028 Analyze_Abstract_Subprogram_Declaration,
2029 Analyze_Subprogram_Body_Helper,
2030 Analyze_Subprogram_Specification, Analyze_Entry_Declaration):
2031 insert contract in subprogram node at point of definition
2032 * sem_ch13.adb
2033 (Aspect_Loop): do not raise error on duplicate Test_Case aspect
2034 (Analyze_Aspect_Specifications): analyze Test_Case aspect and create
2035 corresponding pragma
2036 (Check_Aspect_At_Freeze_Point): raise Program_Error on Test_Case aspect
2037 * sem_ch3.adb (Analyze_Declarations): insert analysis of test-cases,
2038 similar to the analysis of pre/post
2039 (Derive_Subprogram): insert contract in subprogram node at point of
2040 derivation.
2041 * sem_prag.adb, sem_prag.ads
2042 (Check_Arg_Is_String_Literal, Check_Identifier):
2043 new checking procedures to be called in treatment of pragmas
2044 (Check_Test_Case): new procedure to check that a Test_Case aspect or
2045 pragma is well-formed. This does not check currently that 'Result is
2046 used only in the Ensures component of a Test_Case.
2047 (Analyze_Pragma): add case for Test_Case
2048 (Analyze_TC_In_Decl_Part): pre-analyze the Requires and Ensures
2049 components of a Test_Case.
2050 (Preanalyze_TC_Args): new procedure to preanalyze the boolean
2051 expressions in the 3rd (and 4th if present) arguments of a Test_Case
2052 pragma, treated as spec expressions.
2053 (Sig_Flags): add value -1 for Test_Case.
2054 * sem_util.adb, sem_util.ads (Get_Ensures_From_Test_Case_Pragma,
2055 Get_Requires_From_Test_Case_Pragma): getters for both expression
2056 components of a Test_Case.
2057 * sinfo.adb, sinfo.ads (N_Contract): new kind of node used as
2058 indirection between an entry or [generic] subprogram entity and its
2059 pre/post + test-cases.
2060 (Spec_PPC_List, Spec_TC_List, Set_Spec_PPC_List, Set_Spec_TC_List):
2061 get/set for fields of an N_Contract node.
2062 * snames.ads-tmpl (Name_Test_Case, Name_Ensures, Name_Mode,
2063 Name_Normal, Name_Requires, Name_Robustness, Pragma_Test_Case): new
2064 names and pragma for Test_Case.
2065 * sprint.adb (Sprint_Node): raise Program_Error on N_Contract node
2066
6a2e5d0f
AC
20672011-08-04 Vincent Celier <celier@adacore.com>
2068
2069 * gnat_ugn.texi: Improve documentation of gnatmake switch
2070 --source-info-file=.
2071
20722011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2073
2074 * exp_ch7.adb (Make_Final_Call): Add local variable Atyp (assertion
2075 type). Initialize Atyp to the appropriate type which is later checked
2076 for completion. Rewrite the assertion associated with private type
2077 completion.
2078
20792011-08-04 Ed Falis <falis@adacore.com>
2080
2081 * adaint.c: Add call to vxCpuConfiguredGet for VxWorks SMP to
2082 initialize the number of CPUs.
2083
20842011-08-04 Ed Schonberg <schonberg@adacore.com>
2085
2086 * sem_type.adb (Disambiguate): New subsidiary routine
2087 In_Same_Declaration_List, to implement AI05-0020: a user-defined
2088 equality on an anonymous access type whose designated type is private
2089 does not lead to an ambiguity with the universal access equality
2090 operator in the body or child units of the defining package. The same
2091 is true for a multiplication operator on a private type completed with
2092 a fixed-point-type.
2093
20942011-08-04 Javier Miranda <miranda@adacore.com>
2095
2096 * opt.ads (Init_Or_Norm_Scalars_Config): Removed.
2097 (Normalize_Scalars_Config): Removed.
2098 * opt.adb
2099 (Register_Opt_Config_Switches): Remove registering config values of
2100 Init_Or_Norm_Scalars_Config and Normalize_Scalars_Config.
2101 (Restore_Opt_Config_Switches): Remove code which restores the values of
2102 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
2103 Init_Or_Norm_Scalars.
2104 (Save_Opt_Config_Switches): Remove code which saves values of
2105 Init_Or_Norm_Scalars and Normalize_Scalars.
2106 (Set_Opt_Config_Switches): Remove code which restores config values of
2107 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
2108 Init_Or_Norm_Scalars.
2109
21102011-08-04 Yannick Moy <moy@adacore.com>
2111
2112 * frontend.adb (Frontend): remove previous patch to avoid full
2113 qualification in ALFA mode.
2114 * lib-xref-alfa.adb (Add_ALFA_Xrefs): use unique name for variables.
2115 * sem_util.adb, sem_util.ads (Unique_Name): new function to define a
2116 unique name for an entity, which could be used to identify the entity
2117 across compilation units.
2118
21192011-08-04 Thomas Quinot <quinot@adacore.com>
2120
2121 * prj-env.adb
2122 (Initialize_Default_Project_Path): Add target specific directory
2123 ($prefix/$target/lib/gnat) in front of project path in all cases
2124 (making gnatmake's behaviour consistent with gprbuild).
2125 * gnatcmd.adb, make.adb, prj-makr.adb, clean.adb:
2126 Pass target name from Sdefault to project subsystem.
2127 * gnatls.adb: Show new target specific default project directory.
2128
21292011-08-04 Johannes Kanig <kanig@adacore.com>
2130
2131 * cstand.adb: Add Information to Identifier in Standard
2132 (Identifer_For): Set Entity to the corresponding entity
2133
483361a6
AC
21342011-08-04 Sergey Rybin <rybin@adacore.com>
2135
2136 * gnat_ugn.texi: Update doc on gnatcheck.
2137
21382011-08-04 Yannick Moy <moy@adacore.com>
2139
2140 * lib-xref-alfa.adb (Add_ALFA_Xrefs): correct definition of ranges of
2141 xrefs in a scope.
2142
21432011-08-04 Yannick Moy <moy@adacore.com>
2144
2145 * exp_prag.adb (Expand_Pragma_Check): in ALFA mode, return without
2146 performing expansion.
2147 * sem_ch6.adb (Analyze_Subprogram_Body_Helper,
2148 Analyze_Generic_Subprogram_Body): protect call to Process_PCCs so that
2149 it is not called in ALFA mode.
2150
ef5569c6
AC
21512011-08-04 Emmanuel Briot <briot@adacore.com>
2152
2153 * make.adb, osint.adb, osint.ads (Reset_Command_Line_Files): not used
2154 after all, so removed.
2155
21562011-08-04 Sergey Rybin <rybin@adacore.com>
2157
2158 * vms_data.ads: Add missing VMS qualifiers.
2159
1ab4a286
EB
21602011-08-04 Emmanuel Briot <briot@adacore.com>
2161
2162 * make.adb, makeutl.adb, osint.adb, osint.ads (Check_Mains): rebuild
2163 the list of files on the command line after processing it through
2164 Complete_Mains.
2165
7ae0d98c
AC
21662011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2167
2168 * exp_ch7.adb (Build_Raise_Statement): Remove the specialized
2169 processing for .NET/JVM. These targets can now benefit from
2170 Raise_From_Controlled_Operation and they share the same processing with
2171 standard targets.
2172 (Establish_Transient_Scope): Remove the restriction for .NET/JVM.
2173 These targets need transient scopes in order to properly finalize short
2174 lived controlled objects.
2175 (Make_Handler_For_Ctrl_Operation): Remove the specialized processing for
2176 NET/JVM. These targets can now benefit from
2177 Raise_From_Controlled_Operation and they share the same processing with
2178 standard targets.
2179
21802011-08-04 Geert Bosch <bosch@adacore.com>
2181
2182 * tracebak.c (STOP_FRAME): Stop at any next pointer outside the stack
2183
21842011-08-04 Ed Schonberg <schonberg@adacore.com>
2185
2186 * exp_aggr.adb (Has_Visible_Private_Ancestor): subsidiary routine to
2187 Expand_Record_Aggregate, to determine whether aggregate must be
2188 expanded into assignments. This is the case if the ancestor part is
2189 private, regarless of the setting of the flag Has_Private_Ancestor.
2190
21912011-08-04 Ed Falis <falis@adacore.com>
2192
2193 * vxaddr2line.adb: Add support for e500v2 and for Linux hosts
2194
21952011-08-04 Bob Duff <duff@adacore.com>
2196
2197 * sinfo.ads: Fix comment.
2198
21992011-08-04 Steve Baird <baird@adacore.com>
2200
2201 * bindgen.adb (Get_Ada_Main_Name): If CodePeer_Mode is set, then
2202 choose a package name in much the same way as is
2203 done for JGNAT when VM_Target /= No_VM, except that
2204 a slightly more distinctive prefix string is used.
2205
22062011-08-04 Emmanuel Briot <briot@adacore.com>
2207
2208 * makeutl.adb (Complete_Mains): no longer accept unit names on the
2209 gnatmake command line.
2210 This behavior was never documented (and was supported only because of
2211 an early bug in the code). This case might lead to ambiguous cases
2212 (between unit names and truncated base names without suffixes).
2213
87729e5a
AC
22142011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2215
2216 * a-tags.ads, a-tags.adb (Unregister_Tag): New routine.
2217 Remove the external tag of a tagged type from the internal hash table.
2218 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on the
2219 expanded usage of the routine. Strenghten the check for Is_Master. Add
2220 processing for tagged types.
2221 (Build_Finalizer): Create all the necessary lists used in finalizer
2222 creation when the processed context is a package that may contain
2223 tagged types.
2224 (Expand_Cleanup_Actions): Rename the call to Has_Controlled_Objects to
2225 Requires_Cleanup_Actions.
2226 (Expand_N_Package_Body): Package bodies may need clean up code
2227 depending on whether they contain tagged types.
2228 (Expand_N_Package_Declaration): Package declarations may need clean up
2229 code depending on whether they contain tagged types.
2230 (Unregister_Tagged_Types): New routine. Search through a list of
2231 declarations or statements, looking for non-abstract Ada tagged types.
2232 For each such type, generate code to unregister the external tag.
2233 * exp_util.adb (Has_Controlled_Objects (Node_Id)): Renamed to
2234 Requires_Cleanup_Actions.
2235 (Requires_Cleanup_Actions (List_Id, Boolean)): New routine. Search
2236 through a list of declarations or statements looking for non-abstract
2237 Ada tagged types or controlled objects.
2238 * exp_util.ads (Has_Controlled_Objects (Node_Id)): Renamed to
2239 Requires_Cleanup_Actions.
2240 (Has_Controlled_Objects (List_Id, Boolean)): Removed.
2241 * rtsfind.ads: Add entry RE_Unregister_Tag to tables RE_Id and
2242 RE_Unit_Table.
2243
22442011-08-04 Vincent Celier <celier@adacore.com>
2245
2246 * prj-env.adb (For_All_Source_Dirs.For_Project): Check if project Prj
2247 has Ada sources, not project Project, because if the root project
2248 Project has no sources of its own, all projects will be deemed without
2249 sources.
2250
22512011-08-04 Gary Dismukes <dismukes@adacore.com>
2252
2253 * bindgen.adb (Gen_Adainit_Ada): Move the generation of the declaration
2254 of the No_Param_Proc acc-to-subp type used for initialization of
2255 __gnat_finalize_library_objects so that it's declared at library level
2256 rather than nested inside of the adainit routine.
2257
22582011-08-04 Javier Miranda <miranda@adacore.com>
2259
2260 * exp_disp.adb (Make_DT): Generate code to check the external tag ONLY
2261 if the tagged type has a representation clause which specifies its
2262 external tag.
2263
22642011-08-04 Ed Schonberg <schonberg@adacore.com>
2265
2266 * einfo.ads, einfo.adb (Has_Private_Ancestor): now a flag on types.
2267 Remove previous procedure with that name.
2268 * sem_ch3.adb (Build_Derived_Record_Type): set Has_Private_Ancestor
2269 when appropriate.
2270 * sem_aggr.adb (Resolve_Extension_Aggregate): if the ancestor part is a
2271 subtype mark, the ancestor cannot have unknown discriminants.
2272 (Resolve_Record_Aggregate): if the type has invisible components
2273 because of a private ancestor, the aggregate is illegal.
2274
22752011-08-04 Vincent Celier <celier@adacore.com>
2276
2277 * switch-m.adb (Normalize_Compiler_Switches): Recognize and take into
2278 account switches -gnat2005, -gnat12 and -gnat2012.
2279
22802011-08-04 Bob Duff <duff@adacore.com>
2281
2282 * s-tasdeb.ads: Minor comment fix.
2283
22842011-08-04 Arnaud Charlet <charlet@adacore.com>
2285
2286 * gnatlink.adb (Gnatlink): Pass -gnat83/95/05/12 switch to gcc in
2287 CodePeer mode.
2288 * switch.ads, switch.adb (Is_Language_Switch): New function.
2289
22902011-08-04 Vincent Celier <celier@adacore.com>
2291
2292 * switch-c.adb: Minor comment addition.
2293
22942011-08-04 Vincent Celier <celier@adacore.com>
2295
2296 * vms_conv.adb (Process_Argument): Fail graciously when qualifier
2297 ending with '=' is followed by a space (missing file name).
2298
22992011-08-04 Pascal Obry <obry@adacore.com>
2300
2301 * g-regist.ads: Fix size of HKEY on x86_64-windows.
2302
23032011-08-04 Ed Schonberg <schonberg@adacore.com>
2304
2305 * sem_ch12.adb (Analyze_Associations): New routine
2306 Check_Overloaded_Formal_Subprogram to reject a formal package when
2307 there is a named association or a box initialisation for an overloaded
2308 formal subprogram of the corresponding generic.
2309
23102011-08-04 Yannick Moy <moy@adacore.com>
2311
2312 * alfa.ads (ALFA_Xref_Record): add component for type of entity
2313 * get_alfa.adb, put_alfa.adb: Read and write new component of
2314 cross-reference.
2315 * lib-xref-alfa.adb (Collect_ALFA): generate new component.
2316
88f47280
AC
23172011-08-04 Pascal Obry <obry@adacore.com>
2318
2319 * urealp.adb: Minor reformatting.
2320
23212011-08-04 Tristan Gingold <gingold@adacore.com>
2322
2323 * exp_ch7.adb (build_finalizer.process_declarations.processing_actions):
2324 Handle the case when Cleanup_Protected_Object returns Empty.
2325
23262011-08-04 Yannick Moy <moy@adacore.com>
2327
2328 * frontend.adb (Frontend): only qualify names in non-ALFA mode
2329
23302011-08-04 Ed Schonberg <schonberg@adacore.com>
2331
2332 * sem_ch4.adb (Try_Class_Wide_Operation): if the context is a procedure
2333 call, ignore functions.
2334
05c53a69
GB
23352011-08-04 Geert Bosch <bosch@adacore.com>
2336
2337 * urealp.adb (Equivalent_Decimal_Exponent): Avoid the use of floating
2338 point.
2339
23cc1ace
EB
23402011-08-04 Emmanuel Briot <briot@adacore.com>
2341
2342 * makeutl.adb (Compute_Builder_Switches): no longer accept a unit name
2343 as an index for Builder'Switches. This conforms to the documentation.
2344 * make.adb (Insert_Project_Sources): avoid duplicate code
2345
cef14201
AC
23462011-08-04 Emmanuel Briot <briot@adacore.com>
2347
2348 * makeutl.adb (Complete_Mains): if the user has passed a relative file
2349 name on the command line (for instance "../dummy"), never assume it can
2350 be a unit name.
2351
23522011-08-04 Tristan Gingold <gingold@adacore.com>
2353
2354 * bindgen.adb: Remove code the reference or create the
2355 Break_Start/__gnat_break_start procedure.
2356 * s-stalib.adb (Break_Start): Removed.
2357
e2fee30d
EB
23582011-08-04 Emmanuel Briot <briot@adacore.com>
2359
2360 * make.adb, makeutl.adb, makeutl.ads (Compute_Builder_Switches): now
2361 shared with gprbuild.
2362
2d395256
AC
23632011-08-04 Yannick Moy <moy@adacore.com>
2364
2365 * par-ch4.adb (P_Primary): preferentially issue an error message about
2366 a missing parenthesis arount a conditional or case expression in Ada
2367 2012 mode, if we detect that the alignment is not correct for a
2368 statement.
2369
23702011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2371
2372 * exp_ch7.adb (Process_Declarations): Do not consider the result of a
2373 tag-to-class-wide conversion as needing finalization actions.
2374 * exp_util.adb (Has_Controlled_Objects): Do not consider the result of
2375 a tag-to-class-wide conversion as needing finalization actions.
2376 (Is_Finalizable_Transient): The result of a tag-to-class-wide
2377 conversion does not need finalization actions.
2378 (Is_Tag_To_CW_Conversion): New routine.
2379 * exp_util.ads (Is_Tag_To_CW_Conversion): New routine. Determines
2380 whether an object is the result of a tag-to-class-wide conversion.
2381
23822011-08-04 Yannick Moy <moy@adacore.com>
2383
2384 * sem_ch13.adb (Analyze_Aspect_Specifications): correct order in which
2385 the left-hand-side and right-hand-side of a conjunct are inserted when
2386 translating a pre- or postcondition
2387 * sem_ch6.adb: Correct typo in comment
2388
23892011-08-04 Ed Schonberg <schonberg@adacore.com>
2390
2391 * gnat_rm.texi: Ravenscar does not prohibit dependence on
2392 Unchecked_Conversion and Unchecked_Deallocation.
2393
23942011-08-04 Thomas Quinot <quinot@adacore.com>
2395
2396 * make.adb: Minor reformatting.
2397
767ab2fd
EB
23982011-08-04 Emmanuel Briot <briot@adacore.com>
2399
2400 * prj.adb, prj.ads, makeutl.adb (Complete_Mains): search for the
2401 sources in the project and its imported projects, but not in the whole
2402 tree.
2403
8fb3f5df
AC
24042011-08-04 Emmanuel Briot <briot@adacore.com>
2405
2406 * make.adb: Remove debug trace.
2407
24082011-08-04 Vincent Celier <celier@adacore.com>
2409
2410 * makeutl.adb (Do_Complete): Get the absolute path name of a relative
2411 path in canonical form, to be able to compare path names on platforms
2412 such as Windows or Darwin.
2413
24142011-08-04 Thomas Quinot <quinot@adacore.com>
2415
2416 * par_sco.adb (Traverse_Declarations_Or_Statements.Set_Statement_Entry):
2417 For a pragma (statement with C1 = 'P'), record the sloc of the pragma.
2418 * scos.ads: Update documentation accordingly.
2419 * put_scos.adb (Output_SCO_Line): Omit statement SCOs for disabled
2420 pragmas.
2421
9515740f
AC
24222011-08-04 Ed Schonberg <schonberg@adacore.com>
2423
2424 * sem_attr.adb (Bad_Attribute_For_Predicate): flag illegal use of
2425 attribute only if prefix type is scalar.
2426
24272011-08-04 Emmanuel Briot <briot@adacore.com>
2428
2429 * make.adb, makeutl.adb, prj-env.adb (Check_Mains): put back support
2430 in gnatmake for specifying mains on the command line that do not belong
2431 to the main project. These mains must currently all belong to the same
2432 project, though.
2433 (Ultimate_Extension_Of): removed, since duplicated
2434 Ultimate_Extending_Project.
2435
92966893
AC
24362011-08-04 Arnaud Charlet <charlet@adacore.com>
2437
2438 * make.adb (Do_Codepeer_Globalize_Step): Removed. Use CodePeer_Mode
2439 instead.
2440 (CodePeer_Mode_String): New.
2441 (Linking_Phase, Binding_Phase): Call gnatlink with -P switch in
2442 CodePeer mode.
2443 (Scan_Make_Arg): Do not disable binding/linking phase in CodePeer mode.
2444 * bindgen.adb (Gen_Elab_Calls_Ada): Ignore subprograms in CodePeer
2445 mode, since no useful elaboration subprogram is needed by CodePeer.
2446 * gnatlink.adb (Gnatlink): Add support for -P switch (CodePeer mode).
2447 In this mode, compile binder file with -gnatC and do stop after this
2448 step.
2449
24502011-08-04 Vincent Celier <celier@adacore.com>
2451
2452 * exp_ch7.adb: Minor comment fix.
2453
5969611f
RD
24542011-08-04 Robert Dewar <dewar@adacore.com>
2455
2456 * exp_ch7.adb, make.adb, sem_ch10.adb, bindgen.adb, sem_res.adb,
2457 exp_ch4.adb, makeutl.adb: Minor reformatting.
2458
6367dd30
AC
24592011-08-04 Emmanuel Briot <briot@adacore.com>
2460
2461 * make.adb, makeutl.adb, makeutl.ads (Make): major refactoring.
2462 Create several new subprograms to move code out of Make. This makes the
2463 code more readable, removes code duplication, and is a preparation work
2464 for adding support for aggregate projects.
2465
24662011-08-04 Tristan Gingold <gingold@adacore.com>
2467
2468 * s-po32gl.ads, s-po32gl.adb: New files.
2469 * exp_ch7.ads (Get_Global_Pool_For_Access_Type): New function.
2470 * exp_ch7.adb (Get_Global_Pool_For_Access_Type): New function.
2471 (Build_Finalization_Collection): Use it.
2472 * exp_ch4.adb (Complete_Controlled_Allocation): Ditto.
2473 * rtsfind.ads: System_Pool_32_Global, Re_Global_Pool_32_Object: New
2474 literals.
2475 * gcc-interface/Makefile.in: Use s-po32gl.o on VMS.
2476 * gcc-interface/Make-lang.in: Update dependencies.
2477
cd8bfe35
EB
24782011-08-04 Emmanuel Briot <briot@adacore.com>
2479
2480 * makeutl.adb (Complete_Mains): add support for specs with no suffix on
2481 the command line.
2482
7db29ea7
EB
24832011-08-04 Emmanuel Briot <briot@adacore.com>
2484
2485 * make.adb, makeutl.adb (Complete_Mains): if a main specified on the
2486 command line is not a file name, also check whether it could be a unit
2487 name.
2488
d9b056ea
AC
24892011-08-04 Eric Botcazou <ebotcazou@adacore.com>
2490
2491 * bindgen.adb (Gen_Finalize_Library_Ada): Factor out code to generate
2492 the header of the finalization routine.
2493 If the unit has no finalizer but is a body whose spec has one, then
2494 generate the decrement of the elaboration entity only.
2495 If the unit has a finalizer and is a spec, then do not generate the
2496 decrement of the elaboration entity.
2497 (Gen_Finalize_Library_C): Likewise.
2498
24992011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2500
2501 * exp_ch7.adb (Alignment_Of): New subsidiary routine.
2502 (Bounds_Size_Expression): Removed.
2503 (Double_Alignment_Of): New subsidiary routine.
2504 (Make_Finalize_Address_Stmts): New local variable Index_Typ. Account
2505 for a hole in the dope vector of unconstrained arrays due to different
2506 index and element alignments.
2507
25082011-08-04 Ed Schonberg <schonberg@adacore.com>
2509
2510 * sem_res.adb (Resolve_Allocator): diagnose task allocator that will
2511 raise program_error because body has not been seen yet.
2512
25132011-08-04 Ed Schonberg <schonberg@adacore.com>
2514
2515 * sem_ch10.adb (Analyze_With_Clause): Protect against child unit with
2516 an unresolved name.
2517
25182011-08-04 Vincent Celier <celier@adacore.com>
2519
2520 * makeutl.adb (Do_Complete): Check absolute paths in canonical forms
2521
25222011-08-04 Yannick Moy <moy@adacore.com>
2523
2524 * alfa.adb, alfa.ads (Unique_Defining_Entity): move function from here
2525 * sem_util.adb, sem_util.ads (Unique_Defining_Entity): ...to here
2526
25272011-08-04 Thomas Quinot <quinot@adacore.com>
2528
2529 * sem_ch12.adb (Analyze_Package_Instantiation): Do not omit body for
2530 instantiation in RCI.
2531
25322011-08-04 Emmanuel Briot <briot@adacore.com>
2533
2534 * make.adb: Share more code with gprbuild
2535
f5fc5b9d
AC
25362011-08-04 Emmanuel Briot <briot@adacore.com>
2537
2538 * projects.texi: Added documentation for the IDE'Gnat project file
2539 attribute.
2540
25412011-08-04 Nicolas Roche <roche@adacore.com>
2542
2543 * gnat_rm.texi: Minor editing.
2544
25452011-08-04 Javier Miranda <miranda@adacore.com>
2546
2547 * bindgen.adb (Gen_Adafinal_Ada): Do not differentiate the main case
2548 and the library case for VM targets.
2549 (Gen_Adainit_Ada): Likewise.
2550
25512011-08-04 Robert Dewar <dewar@adacore.com>
2552
2553 * g-altive.ads: Minor comment updates.
2554 * prj-nmsc.adb: Minor reformatting.
2555
25562011-08-04 Javier Miranda <miranda@adacore.com>
2557
2558 * opt.ads
2559 (Normalize_Scalars_Config): Value of the configuration switch set by
2560 pragma Normalize_Scalars when it appears in the gnat.adc file.
2561 (Normalize_Scalars): New field for record Config_Switches_Type. Used
2562 to save and restore settings of this pragma.
2563 * opt.adb
2564 (Register_Opt_Config_Switches, Save_Opt_Config_Switches,
2565 Restore_Opt_Config_Switches): Add missing support for Normalize_Scalars.
2566
25672011-08-04 Vincent Celier <celier@adacore.com>
2568
2569 * gnat_ugn.texi: Document gnatlink options -M and -M=mapfile
2570
0c4683cf
AC
25712011-08-04 Arnaud Charlet <charlet@adacore.com>
2572
2573 * makeutl.adb: Minor reformatting.
2574
25752011-08-04 Olivier Hainque <hainque@adacore.com>
2576
2577 * g-altive.ads: Update comments to reflect that only the soft
2578 binding is available today.
2579
2598ee6d
RD
25802011-08-04 Robert Dewar <dewar@adacore.com>
2581
2582 * bindgen.adb, einfo.adb, sem_ch12.adb, s-tasren.adb, sem_res.adb,
2583 makeutl.adb, prj-nmsc.adb, opt.ads, prj-env.adb: Minor reformatting
2584 * gcc-interface/Make-lang.in: Update dependencies.
2585
c2db4b32
AC
25862011-08-04 Arnaud Charlet <charlet@adacore.com>
2587
2588 * prj-env.adb: Remove local debug traces.
2589
25902011-08-04 Yannick Moy <moy@adacore.com>
2591
2592 * checks.adb (Apply_Float_Conversion_Check): correct a typo where Lo_OK
2593 was used instead of Hi_OK, which could cause a read of an uninitialized
2594 value later on. Detected while working on the new warning.
2595 * exp_ch9.adb (Expand_N_Entry_Declaration): remove useless assignment
2596 to local variable.
2597 * sem_ch5.adb (Analyze_Assignment): set the last assignment component
2598 in more cases, in order to detect more unreferenced values.
2599 * sem_util.adb, sem_util.ads (Get_Enclosing_Object): return enclosing
2600 object for expression, if any.
2601
26022011-08-04 Eric Botcazou <ebotcazou@adacore.com>
2603
2604 * exp_intr.adb (Expand_Binary_Operator_Call): Look at the RM size of
2605 the operand types instead of the Esize.
2606
26072011-08-04 Steve Baird <baird@adacore.com>
2608
2609 * switch-b.adb (Scan_Binder_Switches): Add -P binder switch, used to
2610 enable CodePeer_Mode.
2611 * bindusg.adb (Display): Add help message describing -P binder switch.
2612 * gnat_ugn.texi: Document -P binder switch.
2613 * bindgen.adb (Gen_Main_Ada): If CodePeer_Mode is set, then call the
2614 user-defined main program directly.
2615 (Gen_Output_File_Ada): If CodePeer_Mode is set, generate a with of the
2616 user-defined main program in the context clause of the package body.
2617
ad05f2e9
AC
26182011-08-04 Yannick Moy <moy@adacore.com>
2619
2620 * alfa.adb, alfa.ads (Get_Entity_For_Decl): remove function, partial
2621 duplicate of Defining_Entity
2622 (Get_Unique_Entity_For_Decl): rename function into
2623 Unique_Defining_Entity
2624 * einfo.adb, einfo.ads (Is_In_ALFA, Body_Is_In_ALFA): remove flags
2625 (Formal_Proof_On): remove synthesized flag
2626 * cstand.adb, sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
2627 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_res.adb, sem_util.adb,
2628 sem_util.ads, stand.ads: Remove treatment associated to entities in ALFA
2629 * sem_prag.adb (Analyze_Pragma): remove special treatment for pragma
2630 Annotate (Formal_Proof)
2631
26322011-08-04 Emmanuel Briot <briot@adacore.com>
2633
2634 * prj-env.adb (Create_Config_Pragmas_File): fix handling of multi-unit
2635 source files with non-standard naming schemes, in imported projects
2636
756ef2a0
AC
26372011-08-04 Emmanuel Briot <briot@adacore.com>
2638
2639 * makeutl.adb (Complete_Mains): when a multi-unit source file is
2640 specified on the gprbuild command line, we need to compile all units
2641 within that file, not just the first one we find
2642 Fix error message for mains that are not found.
2643
26442011-08-04 Thomas Quinot <quinot@adacore.com>
2645
2646 * sem_ch6.adb: Update comment.
2647 * sem_ch12.adb: Minor reformatting.
2648
26492011-08-04 Bob Duff <duff@adacore.com>
2650
2651 * s-tasren.adb (Task_Do_Or_Queue): Previous code was reading
2652 Acceptor.Terminate_Alternative without locking Acceptor, which causes a
2653 race condition whose symptom is to fail to lock Parent. That, in turn,
2654 causes Parent.Awake_Count to be accessed without locking Parent, which
2655 causes another race condition whose symptom is that Parent.Awake_Count
2656 can be off by 1 (either too high or too low). The solution is to lock
2657 Parent unconditionally, and then lock Acceptor, before reading
2658 Acceptor.Terminate_Alternative.
2659
4fdebd93
AC
26602011-08-04 Arnaud Charlet <charlet@adacore.com>
2661
2662 * debug.adb: Update comment.
2663
26642011-08-04 Robert Dewar <dewar@adacore.com>
2665
2666 * par_sco.adb, exp_util.adb, make.adb, a-tags.adb, sem_prag.adb,
2667 sem_util.adb, sem_attr.adb, exp_ch4.adb, g-comlin.adb, g-comlin.ads,
2668 exp_ch6.adb: Minor reformatting.
2669
26702011-08-04 Gary Dismukes <dismukes@adacore.com>
2671
2672 * gnat_ugn.texi: Add sentence about the case of compile-time-detected
2673 checks for -gnateE.
2674
26752011-08-04 Ed Schonberg <schonberg@adacore.com>
2676
2677 * gnat_rm.texi: update Ravenscar desription to reflect Ada2012 RM.
2678
26792011-08-04 Thomas Quinot <quinot@adacore.com>
2680
2681 * sinfo.ads: Minor reformatting.
2682
26832011-08-04 Emmanuel Briot <briot@adacore.com>
2684
2685 * makeutl.adb, makeutl.ads, prj-nmsc.adb (Complete_Mains): report error
2686 even if there is no location.
2687
6aaa0587
ES
26882011-08-04 Ed Schonberg <schonberg@adacore.com>
2689
2690 * sem_res.adb, sem_ch4.adb: move check for restriction
2691 No_Task_Hierarchy to resolve_allocator.
2692
35a1c212
AC
26932011-08-04 Thomas Quinot <quinot@adacore.com>
2694
2695 * sinfo.adb, sinfo.ads, sem_prag.adb, sem_ch12.adb (Pragma_Enabled):
2696 This flag of N_Pragma nodes is not used, remove it as well as all of
2697 the associated circuitry.
2698
26992011-08-04 Javier Miranda <miranda@adacore.com>
2700
2701 * exp_disp.adb (Make_DT): Switch -gnatdQ disables the generation of the
2702 runtime check on duplicated externa tags
2703 * debug.adb Document switch -gnatdQ.
2704
27052011-08-04 Gary Dismukes <dismukes@adacore.com>
2706
2707 * a-fihema.ads: Minor typo fix.
2708
27092011-08-04 Yannick Moy <moy@adacore.com>
2710
2711 * sem_ch10.adb: Minor comment update.
2712
27132011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2714
2715 * einfo.adb: Update the node field usage to reflect the renaming of
2716 Return_Flag to Return_ Flag_Or_Transient_Decl.
2717 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl.
2718 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl.
2719 (Write_Field15_Name): Change Return_Flag to
2720 Return_Flag_Or_Transient_Decl.
2721 * einfo.ads: Rename node field Return_Flag to
2722 Return_Flag_Or_Transient_Decl. Update the associated comment and all
2723 occurrences in entities.
2724 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl. Update
2725 associated Inline pragma.
2726 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl. Update
2727 associated Inline pragma.
2728 * exp_ch4.ads, exp_ch4.adb (Expand_N_Expression_With_Actions): New
2729 routine.
2730 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Update the calls to
2731 Return_Flag and Set_Return_Flag.
2732 * exp_ch7.adb (Process_Declarations): Add code to recognize hook
2733 objects generated for controlled transients declared inside an
2734 Exception_With_Actions. Update the calls to Return_Flag.
2735 (Process_Object_Declaration): Add code to add a null guard for hook
2736 objects generated for controlled transients declared inside an
2737 Exception_With_Actions. Update related comment.
2738 * exp_util.adb (Has_Controlled_Objects): Add code to recognize hook
2739 objects generated for controlled transients declared inside an
2740 Exception_With_Actions. Update the calls to Return_Flag.
2741 * expander.adb (Expand): Add new case for N_Expression_With_Actions.
2742
27432011-08-04 Ed Schonberg <schonberg@adacore.com>
2744
2745 * sem_util.adb:(Wrong_Type): Improve error message on a one-element
2746 positional aggregate.
2747
27482011-08-04 Vincent Celier <celier@adacore.com>
2749
2750 * par_sco.adb (Process_Decisions.Output_Header): Check and record pragma
2751 SLOC only for pragmas.
2752
27532011-08-04 Emmanuel Briot <briot@adacore.com>
2754
2755 * projects.texi: Minor typo fix.
2756
27572011-08-04 Emmanuel Briot <briot@adacore.com>
2758
2759 * prj-nmsc.adb (Check_File): Minor change to traces, to help debugging
2760 on case-sensitive file systems.
2761
c2873f74
TQ
27622011-08-04 Thomas Quinot <quinot@adacore.com>
2763
2764 * put_scos.adb (Put_SCOs): Do not emit decision SCO for an X decision
2765 nested in a disabled pragma.
2766 * scos.ads, scos.adb, par_sco.ads, par_sco.adb: Record sloc of
2767 enclosing pragma, if any, for X decisions.
2768
27692011-08-04 Thomas Quinot <quinot@adacore.com>
2770
2771 * sem_prag.adb: Minor reformatting.
2772
46414266
VC
27732011-08-04 Vincent Celier <celier@adacore.com>
2774
2775 * a-tags.adb (Check_TSD): Avoid concatenation of strings, as it is not
2776 allowed in no run time mode.
2777
27782011-08-04 Vincent Celier <celier@adacore.com>
2779
2780 * make.adb (Check): When -gnatc is used, check for the source file
2781 inside the ALI file with a canonical case file name.
2782
afab164f
EB
27832011-08-04 Emmanuel Briot <briot@adacore.com>
2784
2785 * g-comlin.adb, g-comlin.ads (Add_Switch): Put back support for
2786 overriding the separator.
2787
fe0ec02f
AC
27882011-08-04 Robert Dewar <dewar@adacore.com>
2789
2790 * sem_aggr.adb, par_sco.adb, sem_type.adb, exp_util.adb, exp_ch9.adb,
2791 prj-nmsc.adb, sem_ch13.adb, exp_strm.adb: Minor reformatting.
2792
27932011-08-04 Robert Dewar <dewar@adacore.com>
2794
2795 * gnat_rm.texi: Minor documentation fix for pragma Annotate.
2796
27972011-08-04 Yannick Moy <moy@adacore.com>
2798
2799 * sem_attr.adb (Analyze_Attribute): add check during pre-analysis that
2800 'Result only appears in postcondition of function.
2801
28022011-08-04 Thomas Quinot <quinot@adacore.com>
2803
2804 * a-tags.adb (Check_TSD): When raising PROGRAM_ERROR for a duplicated
2805 external tag, include the value of the external tag in the exception
2806 message.
2807
0180fd26
AC
28082011-08-04 Yannick Moy <moy@adacore.com>
2809
2810 * sem_attr.adb (Result): modify error message for misplaced 'Result
2811
28122011-08-04 Sergey Rybin <rybin@adacore.com>
2813
2814 * gnat_rm.texi (pragma Annotate): Fix syntax description to make it
2815 clear that the second argument must be an identifier.
2816
28172011-08-04 Thomas Quinot <quinot@adacore.com>
2818
2819 * exp_ch9.adb (Build_Barrier_Function): When compiling with
2820 -fpreserve-control-flow, insert an IF statement on the barrier
2821 condition to ensure that a conditional branch instruction is generated.
2822
28232011-08-04 Emmanuel Briot <briot@adacore.com>
2824
2825 * prj-part.adb, prj.adb, prj.ads, prj-tree.ads
2826 (Processing_Flags.Ignore_Missing_With): new flag.
2827
28282011-08-04 Emmanuel Briot <briot@adacore.com>
2829
2830 * prj-nmsc.adb (Find_Sources, Path_Name_Of): Fix handling of
2831 Source_List_File on case-insensitive systems where the file is actually
2832 on a case-sensitive file system (NFS,...).
2833
28342011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2835
2836 * sem_ch6.adb (Analyze_Function_Return): In a rare case where a
2837 function return contains a controlled [extension] aggregate and the
2838 return statement is not part of a handled sequence of statements, wrap
2839 the return in a block. This ensures that all controlled temporaries
2840 generated during aggregate resolution will be picked up by the
2841 finalization machinery.
2842
28432011-08-04 Ed Schonberg <schonberg@adacore.com>
2844
2845 * sem_aggr.adb (Resolve_Aggregate): If aggregate has box-initialized
2846 components, freeze type before resolution, to ensure that default
2847 initializations are present for all components.
2848 * sem_res.adb (Resolve_Actuals): the designated object of an
2849 accces-to-constant type is a legal actual in a call to an
2850 initialization procedure.
2851
28522011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2853
2854 * exp_util.adb (Extract_Renamed_Object): Add N_Type_Conversion and
2855 N_Unchecked_Type_Conversion to the possible containers of a renamed
2856 transient variable.
2857
78efd712
AC
28582011-08-04 Yannick Moy <moy@adacore.com>
2859
2860 * par-ch13.adb (Aspect_Specifications_Present): recognize
2861 "with Identifier'Class =>" as an aspect, so that a meaningful warning
2862 is issued in Strict mode.
2863 * par.adb: Fix typos in comments.
2864
28652011-08-04 Yannick Moy <moy@adacore.com>
2866
2867 * sem_attr.adb (Result): modify error message to take into account Post
2868 aspect when compiling Ada 2012 (or newer) code.
2869
28702011-08-04 Nicolas Roche <roche@adacore.com>
2871
2872 * env.c (__gnat_clearenv): Avoid use of dynamic size array in order to
2c7f9cc0 2873 remove need for GCC exceptions.
78efd712
AC
2874
28752011-08-04 Vincent Celier <celier@adacore.com>
2876
2877 * makeutl.adb (Do_Complete): Call Debug_Output with the name of the
2878 project, not the source file name.
2879 * prj.adb (Find_Sources.Look_For_Sources): If the source has been
2880 excluded, continue looking. This excluded source will only be returned
2881 if there is no other source with the same base name that is not locally
2882 removed.
2883
28842011-08-04 Ed Schonberg <schonberg@adacore.com>
2885
2886 * sem_res.adb (Resolve_Intrinsic_Operator): if the result type is
2887 private and one of the operands is a real literal, use a qualified
2888 expression rather than a conversion which is not meaningful to the
2889 back-end.
2890
0170a691
AC
28912011-08-04 Yannick Moy <moy@adacore.com>
2892
2893 * sem_ch13.adb (Aspect_Loop): when an aspect X and its classwise
2894 corresponding aspect X'Class are allowed, proceed with analysis of the
2895 aspect instead of skipping it.
2896
28972011-08-04 Tristan Gingold <gingold@adacore.com>
2898
2899 * s-flocon.adb, s-flocon.ads: Add a body for s-flocon.ads
2900 This will allow to have an Ada implementation for the subprogram.
2901
deb4f5ba
ES
29022011-08-04 Ed Schonberg <schonberg@adacore.com>
2903
2904 * sem_ch3.adb (Analyze_Full_Type_Declaration): If the declaration is a
2905 completion and aspects are present, apply them to the entity for the
2906 type which is currently the partial view, but which is the one that
2907 will be frozen.
2908 * sem_ch13.adb (Analyze_Aspect_Specifications): if the predicate
2909 applies to a partial view, indicate that the full view has predicates
2910 and delayed aspects.
2911 (Replace_Type_Reference): Handle properly predicates that apply to the
2912 full view of a private completion.
2913
fc893455
AC
29142011-08-04 Eric Botcazou <ebotcazou@adacore.com>
2915
2916 * layout.adb (Layout_Type): For composite types, do not set Esize.
2917 * freeze.adb (Set_Small_Size): Remove test on alignment and do not
2918 set Esize.
2919 (Size_Known): Look at the RM size of components instead of the Esize.
2920 (Freeze_Record_Type): Look at the RM size instead of the Esize to
2921 issue warning and activate Implicit_Packing.
2922 (Freeze_Entity): Likewise. Do not issue a warning for alias/atomic
2923 if the Esize is not known.
2924 * sem_ch13.adb (Analyze_Attribute_Definition_Clause) <Size>: Set Esize
2925 for elementary types only.
2926 (Analyze_Record_Representation_Clause): Look at the RM size instead
2927 of the Esize to issue errors.
2928 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not set Esize if it
2929 is not known.
2930 <E_Record_Type>: Look at the RM size instead of the Esize. Remove
2c7f9cc0 2931 obsolete block.
fc893455
AC
2932 Look at the RM size instead of the Esize for types if the latter is
2933 not known.
2934 (gnat_to_gnu_field): Use Known_Esize instead of Known_Static_Esize.
2935
29362011-08-04 Ed Schonberg <schonberg@adacore.com>
2937
2938 * sem_type.adb: proper handling of equality not involving anonymous
2939 access types.
2940
b37d5bc6
AC
29412011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
2942
2943 * exp_ch7.adb (Create_Finalizer): Remove local variables Spec_Nod and
2944 Vis_Decls. When creating a library-level finalizer for a package spec,
2945 both the declaration and body of the finalizer are inserted either in
2946 the visible or private declarations of the package spec.
2947
29482011-08-04 Javier Miranda <miranda@adacore.com>
2949
2950 * sem_ch3.adb (Derive_Subprograms): Complete assertion to request the
2951 use of the full-view of a type when invoking Is_Ancestor.
2952 * sem_type.adb (Is_Ancestor): For consistency, when the traversal of
2953 the full-view of private parents is requested, then use also the
2954 full-view of the parent of the first derivation.
2955
7ab4d95a
AC
29562011-08-04 Tristan Gingold <gingold@adacore.com>
2957
2958 * s-taprop-vxworks.adb (Enter_Task): Use System.Float_Control.Reset
2959 instead of the locally imported procedure.
2960 * s-taprop-mingw.adb (Enter_Task): Ditto.
2961 * s-valrea.adb (Scan_Real): Ditto.
2962 * s-imgrea.adb (Set_Image_Real): Ditto.
2963 * s-flocon.ads: Make the package pure.
2964
29652011-08-04 Thomas Quinot <quinot@adacore.com>
2966
2967 * sinfo.ads, sinfo.adb (Debug_Statement, Set_Debug_Statement): Remove.
2968 * tbuild.ads, tbuild.adb (Make_Pragma): Adjust accordingly.
2969 * sinfo-cn.ads, sinfo-cn.adb (Change_Name_To_Procedure_Call_Statement):
2970 New subprogram, moved here from...
2971 * par.adb, par-ch5.adb (P_Statement_Name): ... here.
2972 * par-prag.adb (Par.Prag, case Pragma_Debug): Do not perform any
2973 rewriting of the last argument into a procedure call statement here...
2974 * sem_prag.adb (Analyze_Pragma, case Pragma_Debug): ...do it there
2975 instead.
2976
29772011-08-04 Thomas Quinot <quinot@adacore.com>
2978
2979 * par_sco.adb: Minor reformatting.
2980
51c400f5
AC
29812011-08-04 Robert Dewar <dewar@adacore.com>
2982
2983 * erroutc.adb: Minor reformatting.
2984
29852011-08-04 Thomas Quinot <quinot@adacore.com>
2986
2987 * par_sco.adb: Comment update.
2988
29892011-08-04 Tristan Gingold <gingold@adacore.com>
2990
2991 * s-flocon.ads: New file.
2992 * g-flocon.ads: Now a renaming of s-flocon.
2993 * Makefile.rtl: Add s-flocon.o
2994
6a49f110
AC
29952011-08-04 Javier Miranda <miranda@adacore.com>
2996
2997 * exp_strm.adb (Build_Array_Input_Function): if the array type is
2998 constrained, do not attempt to build a subtype of it.
2999
30002011-08-04 Yannick Moy <moy@adacore.com>
3001
3002 * errout.ads Change comments: remove 'R'M as an example where quotes
3003 are needed; add ALFA as another case where quotes are not needed
3004 * erroutc.adb (Set_Msg_Insertion_Reserved_Word): add ALFA as another
3005 case where quotes are not needed.
3006 * sem_ch11.adb, sem_ch13.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
3007 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_prag.adb, sem_res.adb:
3008 Remove all occurrences of 'A'L'F'A
3009
30102011-08-04 Ed Schonberg <schonberg@adacore.com>
3011
3012 * sem_ch13.adb: check legality of invariant pragma.
3013
a4640a39
AC
30142011-08-04 Eric Botcazou <ebotcazou@adacore.com>
3015
3016 * bindgen.adb: Add comments.
3017
30182011-08-04 Yannick Moy <moy@adacore.com>
3019
3020 * einfo.adb, einfo.ads: Free Flag254 and make Formal_Proof_On a
3021 synthesized flag.
3022 * sem_prag.adb (Analyze_Pragma): record the pragma Annotate
3023 (Formal_Proof, On/Off) in the Rep_Item list of the current subprogram.
3024
30252011-08-04 Robert Dewar <dewar@adacore.com>
3026
3027 * exp_ch7.adb, exp_ch6.adb, sem_ch3.adb, layout.adb, sem_ch5.adb,
3028 osint-c.ads, sem_util.ads, gnat1drv.adb, targparm.ads, sem_ch6.adb,
3029 sem_ch13.adb, s-pooloc.adb: Minor reformatting.
3030
39ade2f9
AC
30312011-08-04 Thomas Quinot <quinot@adacore.com>
3032
3033 * s-pooloc.ads, s-pooglo.ads: Minor reformatting
3034
30352011-08-04 Thomas Quinot <quinot@adacore.com>
3036
3037 PR ada/47880
3038 * s-pooloc.adb (Deallocate): Fix the case of deallocating the only
3039 allocated object.
3040
30412011-08-04 Robert Dewar <dewar@adacore.com>
3042
3043 * einfo.ads, exp_ch4.adb: Minor reformatting.
3044
30452011-08-04 Jerome Lambourg <lambourg@adacore.com>
3046
3047 * back_end.ads (Gen_Or_Update_Object_File): Add more comments.
3048
7efc3f2d
AC
30492011-08-04 Ed Schonberg <schonberg@adacore.com>
3050
3051 * exp_ch4.adb (Expand_Composite_Equality): code cleanup: use component
3052 type in all cases to compute list of primitive operations, because full
3053 view may be an itype that is not attached to the list of declarations.
3054
30552011-08-04 Eric Botcazou <ebotcazou@adacore.com>
3056
3057 * bindgen.adb (Gen_Adafinal_Ada): Generate an early return if the
3058 library has already been finalized.
3059 (Gen_Adafinal_C): Likewise.
3060 (Gen_Adainit_Ada): Generate an early return if the library has
3061 already been elaborated.
3062 (Gen_Adainit_C): Likewise.
3063 (Gen_Output_File_Ada): Generate an elaboration flag.
3064 (Gen_Output_File_C): Likewise.
3065
f65df609
HK
30662011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
3067
3068 * exp_ch4.adb (Expand_Allocator_Expression): Disable the generation of
3069 Set_Finalize_Address_Ptr for CodePeer because Finalize_Address was not
3070 built in the first place.
3071 (Expand_N_Allocator): Disable the generation of Set_Finalize_Address_Ptr
3072 for CodePeer because Finalize_Address was not built to begin with.
3073 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Ditto.
3074
a0fb8fe8
AC
30752011-08-04 Pascal Obry <obry@adacore.com>
3076
3077 * adaint.c (__gnat_tmp_name): Use current process id to create temp
3078 filenames, this ensures unicity of filenames across processes.
3079
30802011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
3081
3082 * bindgen.adb (Gen_Finalize_Library_Ada): Rename generated routine
3083 Raise_Controlled to Raise_From_Controlled_Operation. Update the
3084 signature of Raise_From_Controlled_Operation by adding flag From_Abort.
3085 Add False as the actual to From_Abort in the generated call to
3086 Raise_From_Controlled_Operation.
3087
30882011-08-04 Jerome Lambourg <lambourg@adacore.com>
3089
3090 * osint-c.ads, osint-c.adb (Set_Library_Info_Name): Move to declaration
3091 so that the ali file name can be retrieved from outside of this package.
3092 * back_end.ads, back_end.adb (Gen_Or_Update_Object_File): New method
3093 doing nothing in the general case, but used to update the object file
3094 timestamp if directly generated by the backend.
3095 * gnat1drv.adb (Gnat1drv): Make sure the object file's timestamp is set
3096 to a later time than the ali file one.
3097
9534ab17
AC
30982011-08-04 Yannick Moy <moy@adacore.com>
3099
3100 * einfo.adb, einfo.ads (Formal_Proof_On): new flag set on subprogram
3101 entities whose body contains an Annotate pragma which forces formal
3102 proof on this body.
3103 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
3104 sem_ch6.adb, sem_ch9.adb, sem_res.adb: Adapt call to
3105 Mark_Non_ALFA_Subprogram to pass in a message and node.
3106 * sem_prag.adb (Analyze_Pragma): add treatment of pragma Annotate
3107 (Forma_Proof, On) which sets the flag Formal_Proof_On in the
3108 surrounding subprogram.
3109 * sem_util.adb, sem_util.ads (Mark_Non_ALFA_Subprogram,
3110 Mark_Non_ALFA_Subprogram_Unconditional): if the subprogram being marked
3111 as not in ALFA is annotated with Formal_Proof being On, then an error
3112 is issued based on the additional parameters for message and node.
3113 * snames.ads-tmpl (Name_Formal_Proof): new name for annotation.
3114 * gcc-interface/Make-lang.in: Update dependencies.
3115
31162011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
3117
3118 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Do not generate
3119 Finalize_Address when CodePeer is enabled.
3120
31212011-08-04 Pascal Obry <obry@adacore.com>
3122
3123 * adaint.c (__gnat_tmp_name): Use _tempnam() instead of tempnam() as
3124 the latter returns a pointer to a static buffer which is deallocated
3125 at the end of the routine.
3126
5c0e97dd
AC
31272011-08-04 Yannick Moy <moy@adacore.com>
3128
3129 * sem_ch3.adb (Array_Type_Declaration): move test for type in ALFA
3130 after index creation; mark unconstrained base array type generated as
3131 being in/not in ALFA as well
3132 (Make_Index): mark subtype created as in/not in ALFA
3133 * sem_ch5.adb (Analyze_Iteration_Scheme): mark entity for iterating
3134 over a loop as in/not in ALFA, depending on its type and form of loop
3135 iteration.
3136
31372011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
3138
3139 * exp_ch7.adb (Build_Object_Declarations): Initialize flag Abort
3140 directly to False on .NET and JVM.
3141
7a93c64b
YM
31422011-08-04 Yannick Moy <moy@adacore.com>
3143
3144 * sem_ch3.adb (Constrain_Enumeration, Constrain_Integer): remove
3145 constraint that subtype must come from source code to be in ALFA, so
3146 that anonymous subtypes can be in ALFA too.
3147
e9a1ed9b
YM
31482011-08-04 Yannick Moy <moy@adacore.com>
3149
3150 * sem_ch3.adb (Analyze_Object_Declaration): remove obsolete addition of
3151 reference for ALFA mode.
3152 * lib-xref-alfa.adb, lib-xref.ads (Traverse_Compilation_Unit): make
3153 procedure public so as to use it from formal verification back-end.
3154
8e293fbd
AC
31552011-08-04 Jerome Lambourg <lambourg@adacore.com>
3156
3157 * g-comlin.adb (For_Each_Simple_Switch.Is_In_Config): Remove the
3158 invalid checks of the Parameter, making Remove_Switch not working
3159 correctly.
3160
31612011-08-04 Arnaud Charlet <charlet@adacore.com>
3162
3163 * targparm.ads: Update header: no run-time exception is needed on this
3164 file.
3165
31662011-08-04 Vincent Celier <celier@adacore.com>
3167
3168 * a-fihema.adb: Use System.IO instead of GNAT.IO
3169
31702011-08-04 Thomas Quinot <quinot@adacore.com>
3171
3172 * sem_ch3.adb (Access_Definition): Anonymous access to subprogram types
3173 are forbidden in Compiler_Unit mode.
3174
cfae2bed
AC
31752011-08-04 Robert Dewar <dewar@adacore.com>
3176
3177 * sem_util.adb: Minor reformatting.
3178
31792011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
3180
3181 * bindgen.adb (Gen_Finalize_Library_Ada): Update the import string for
3182 library-level finalizers.
3183 (Gen_Finalize_Library_C): Update the import string for library-level
3184 finalizers.
3185 (Gen_Finalize_Library_Defs_C): Update the definition name of a
3186 library-level finalizer.
3187 * exp_ch7.adb: Remove with and use clauses for Stringt.
3188 (Create_Finalizer): Remove local variables Conv_Name, Prag_Decl,
3189 Spec_Decl. Add local variable Body_Id. The names of library-level
3190 finalizers are now manually fully qualified and are no longer external.
3191 A single name is now capable of servicing .NET, JVM and non-VM targets.
3192 Pragma Export is no longer required to provide visibility for the name.
3193 (Create_Finalizer_String): Removed.
3194 (New_Finalizer_Name): New routine which mimics New_..._Name.
3195
01f0729a
AC
31962011-08-04 Eric Botcazou <ebotcazou@adacore.com>
3197
3198 * sem_elab.adb (Check_Internal_Call_Continue): Change the type of the
3199 elaboration counter to Standard_Short_Integer.
3200 * sem_util.adb (Build_Elaboration_Entity): Likewise.
3201 * bindgen.adb (Gen_Elab_Externals_Ada): Adjust to above change.
3202 (Gen_Elab_Externals_C): Likewise.
3203
32042011-08-04 Ed Falis <falis@adacore.com>
3205
3206 * system-vxworks-arm.ads, system-vxworks-sparcv9.ads,
3207 system-vxworks-ppc.ads, system-vxworks-m68k.ads,
3208 system-vxworks-mips.ads, system-vxworks-x86.ads
3209 (Always_Compatible_Rep): set to False for all VxWorks targets.
3210
2c1b72d7
AC
32112011-08-04 Robert Dewar <dewar@adacore.com>
3212
3213 * par_sco.adb, prj-proc.adb, make.adb, bindgen.adb, prj.adb, prj.ads,
3214 makeutl.adb, makeutl.ads, prj-nmsc.adb, exp_ch5.adb, exp_ch12.adb,
3215 exp_ch7.ads, exp_util.ads, sem_util.ads, g-comlin.ads, exp_ch6.adb,
3216 exp_ch6.ads, lib-xref.ads, exp_ch7.adb, exp_util.adb, exp_dist.adb,
3217 exp_strm.adb, gnatcmd.adb, freeze.adb, g-comlin.adb, lib-xref-alfa.adb,
3218 sem_attr.adb, sem_prag.adb, sem_util.adb, sem_elab.adb, sem_ch8.adb,
3219 sem_ch11.adb, sem_eval.adb, sem_ch13.adb, sem_disp.adb, a-fihema.adb:
3220 Minor reformatting and code reorganization.
3221
32222011-08-04 Emmanuel Briot <briot@adacore.com>
3223
3224 * projects.texi: Added doc for aggregate projects.
3225
824e9320
AC
32262011-08-04 Emmanuel Briot <briot@adacore.com>
3227
3228 * prj-proc.adb, prj-nmsc.adb, prj-env.adb (Process_Declarative_Items):
3229 Add support for overriding the Project_Path in aggregate projects.
3230
32312011-08-04 Robert Dewar <dewar@adacore.com>
3232
3233 * a-cofove.ads: Minor reformatting.
3234
32352011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
3236
3237 * exp_ch7.adb (Build_Adjust_Or_Finalize_Statements): Update the comment
3238 on the generated code.
3239 (Build_Finalize_Statements): Update the comment on the generated code.
3240 (Build_Initialize_Statements): Update the comment on the generated code.
3241 (Build_Object_Declarations): Add local variable Result. The object
3242 declarations are now built in sequence.
3243 * rtsfind.ads: Add RE_Exception_Occurrence_Access to tables RE_Id and
3244 RE_Unit_Table.
3245
32462011-08-04 Robert Dewar <dewar@adacore.com>
3247
3248 * checks.adb, alfa.adb, alfa.ads: Minor reformatting.
3249
32502011-08-04 Eric Botcazou <ebotcazou@adacore.com>
3251
3252 * einfo.ads (Elaboration_Entity): Document new definition and use.
3253 (Elaboration_Entity_Required): Adjust to above change.
3254 * exp_attr.adb (Expand_N_Attribute_Reference): Likewise.
3255 * exp_ch12.adb: And with and use for Snames.
3256 (Expand_N_Generic_Instantiation): Test 'Elaborated attribute.
3257 * exp_util.adb (Set_Elaboration_Flag): Likewise.
3258 * sem_attr.adb (Analyze_Attribute) <Check_Library_Unit>: Delete.
3259 <Check_Unit_Name>: Deal with N_Expanded_Name.
3260 <Attribute_Elaborated>: Extend to all unit names.
3261 * sem_elab.adb: And with and use for Uintp.
3262 (Check_Internal_Call_Continue): Adjust to Elaboration_Entity change.
3263 * sem_util.ads (Build_Elaboration_Entity): Adjust comment.
3264 * sem_util.adb (Build_Elaboration_Entity): Change type to Integer.
3265 * bindgen.adb (Gen_Elab_Externals_Ada): New local subprogram taken
3266 from Gen_Adainit_Ada.
3267 (Gen_Elab_Externals_C): Likewise, but taken from Gen_Adainit_C.
3268 (Gen_Adafinal_Ada): Remove redundant test. In the non-main program
3269 case, do not call System.Standard_Library.Adafinal; instead call
3270 finalize_library if needed.
3271 (Gen_Adafinal_C): Likewise.
3272 (Gen_Adainit_Ada): Do not set SSL.Finalize_Library_Objects in the
3273 non-main program case.
3274 (Gen_Adainit_C): Generate a couple of external declarations here.
3275 In the main program case, set SSL.Finalize_Library_Objects.
3276 (Gen_Elab_Calls_Ada): Adjust to Elaboration_Entity change.
3277 (Gen_Elab_Calls_C): Likewise.
3278 (Gen_Finalize_Library_Ada): Likewise. Skip SAL interface units.
3279 (Gen_Finalize_Library_C): Likewise. Generate a full function.
3280 (Gen_Main_C): Put back call to Ada_Final and don't finalize library
3281 objects here.
3282 (Gen_Output_File_Ada): Generate pragma Linker_Destructor for Ada_Final
3283 if -a is specified. Call Gen_Elab_Externals_Ada. Move around call to
3284 Gen_Adafinal_Ada.
3285 (Gen_Output_File_C): Generate __attribute__((destructor)) for Ada_Final
3286 if -a is specified. Call Gen_Elab_Externals_C. Remove useless couple
2c7f9cc0 3287 of external declarations. Call Gen_Finalize_Library_C.
824e9320 3288
316d9d4f
EB
32892011-08-04 Emmanuel Briot <briot@adacore.com>
3290
3291 * prj.adb, prj.ads, makeutl.adb, makeutl.ads (Complete_Mains,
3292 Compute_Compilation_Phases): new subprogram.
3293 (Builder_Data, Builder_Project_Tree_Data): new subprogram and type
3294 The number of mains as well as the various compilation phases that
3295 need to be run are now project tree specific, since various
3296 aggregated trees might have different requirements. In particular,
3297 they do not all require bind or link phases.
3298
9434c32e
EB
32992011-08-04 Emmanuel Briot <briot@adacore.com>
3300
3301 * prj.adb, prj.ads, makeutl.adb, makeutl.ads, prj-env.adb
3302 (Project_Tree_Appdata): New type.
3303 It is now possible to associate application-specific data to a project
3304 tree. In particular, this is used in the gprbuild builder to avoid a
3305 number of global tables and htables, especially now that there can be
3306 several project trees loaded at once because of aggregate projects.
3307 (Debug_Name): new procedure.
3308 * projects.texi: Clarify syntax of "**" for Source_Dirs
3309
41ba34db
EB
33102011-08-03 Emmanuel Briot <briot@adacore.com>
3311
3312 * prj.ads, makeutl.adb, makeutl.ads (Queue.Insert): now also inserts
3313 the "roots" for a main.
3314 (Fill_From_Project): add support for aggregate projects. Main units
3315 in aggregated projects are now automatically added in the list of
3316 files to build (although this fails later on in gprbuild, because
3317 these files are not using the root proejct tree, so this needs
3318 further cleanup)
3319 * gcc-interface/Make-lang.in: Update dependencies.
3320
fccd42a9
AC
33212011-08-03 Yannick Moy <moy@adacore.com>
3322
3323 * sem_ch4.adb (Analyze_Conditional_Expression): only allow boolean
3324 conditional expression in ALFA.
3325 * sem_res.adb (Resolve_Conditional_Expression): mark non-boolean
3326 expressions as not in ALFA.
3327
33282011-08-03 Robert Dewar <dewar@adacore.com>
3329
3330 * a-cofove.adb: Minor reformatting.
3331
33322011-08-03 Emmanuel Briot <briot@adacore.com>
3333
3334 * make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads
3335 (Insert_Project_Sources, Insert_withed_Sources_For): moved from the
3336 gprbuild sources.
3337 These packages are more logically placed in the Queue package, since
3338 they manipulate the queue. It is also likely that they can be adapted
3339 for gnatmake, thus sharing more code.
3340 (Finish_Program, Fail_Program): moved from the gprbuild sources, so
3341 that we could move the above.
3342
33432011-08-03 Emmanuel Briot <briot@adacore.com>
3344
3345 * errutil.adb (Finalize): clean up the list of error messages on exit.
3346 Calling this subprogram multiple times will no longer show duplicate
3347 error messages on stderr.
3348
33492011-08-03 Emmanuel Briot <briot@adacore.com>
3350
3351 * g-comlin.adb, g-comlin.ads (Set_Command_Line): ignore the parameter
3352 Getopt_Switches when we have already define a command line
3353 configuration.
3354
5e8c8e44
YM
33552011-08-03 Yannick Moy <moy@adacore.com>
3356
3357 * sem_ch11.adb (Analyze_Raise_xxx_Error): do not mark such nodes as not
3358 in ALFA. Instead, they are considered as assertions to prove.
3359 * sem_ch4.adb (Analyze_Conditional_Expression): do not always mark such
3360 nodes as not in ALFA. Instead, include conditional expressions in ALFA
3361 if they have no ELSE part, or if they occur in pre- and postconditions,
3362 where the Condition cannot have side-effects in ALFA
3363 (Analyze_Membership_Op): do not mark such nodes as not in ALFA
3364 (Analyze_Type_Conversion): do not always mark such nodes as not in ALFA.
3365 Instead, include type conversion between scalar types in ALFA.
3366 * sem_ch6.adb (Process_Formals): correctly mark a parameter in ALFA
3367 if-and-only-if its type is in ALFA.
3368
5ffe0bab
AC
33692011-08-03 Thomas Quinot <quinot@adacore.com>
3370
3371 * scos.adb, get_scos.adb, put_scos.adb
3372 New code letter for decisions: G (entry guard)
3373 * par_sco.adb
3374 (Traverse_Subprogram_Body): Rename to...
3375 (Traverse_Subprogram_Or_Task_Body): New subrpogram.
3376 (Traverse_Protected_Body): New subprogram
3377 (Traverse_Declarations_Or_Statements): Add traversal of task bodies,
3378 protected bodies and entry bodies.
3379
33802011-08-03 Yannick Moy <moy@adacore.com>
3381
3382 * einfo.adb, einfo.ads (Is_Postcondition_Proc): new flag for procedure
3383 entities with get/set subprograms, which is set on procedure entities
3384 generated by the compiler for a postcondition.
3385 * sem_ch6.adb (Process_PPCs): set new flag on postcondition procedures
3386 * alfa.adb, alfa.ads (Get_Entity_For_Decl): new function returning the
3387 entity for a declaration
3388 (Get_Unique_Entity_For_Decl): new function returning an entity which
3389 represents a declaration, so that matching spec and body have the same
3390 entity.
3391
33922011-08-03 Robert Dewar <dewar@adacore.com>
3393
3394 * a-except-2005.adb, a-cfhama.adb, a-cfhase.adb, a-cfhase.ads,
3395 a-cforma.adb, a-cforse.ads, a-cforse.adb: Minor reformatting
3396
33972011-08-03 Yannick Moy <moy@adacore.com>
3398
3399 * lib-xref-alfa.adb (Detect_And_Add_ALFA_Scope): make the subprogram
3400 library-level because retriction No_Implicit_Dynamic_Code in the
3401 front-end prevents its definition as a local subprogram
3402 (Traverse_Compilation_Unit): extract new procedure from Add_ALFA_File,
3403 for reuse in other contexts
3404 (Traverse_Declarations_Or_Statements,
3405 Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
3406 Traverse_Package_Declaration, Traverse_Subprogram_Body): make all these
3407 procedures take a callback parameter to be called on all declarations
3408 * lib-xref.ads
3409 (Traverse_All_Compilation_Units): new generic function to traverse a
3410 compilation unit and call a callback parameter on all declarations
3411
f9ad6b62
AC
34122011-08-03 Javier Miranda <miranda@adacore.com>
3413
3414 * sem_prag.adb (Process_Interface_Name): Allow duplicated export names
3415 in Java since they are always enclosed in a namespace that
3416 differentiates them, and overloaded entities are supported by the VM.
3417
34182011-08-03 Ed Schonberg <schonberg@adacore.com>
3419
3420 * checks.adb (Determine_Range): If a computed bound of an operation is
3421 outside the range of the base type of the expression, and overflow
3422 checks are enabled, the result is unknown and cannot be used for any
3423 subsequent constant folding.
3424 * sem_eval.adb (Compile_Time_Compare): if the bounds of one operand are
3425 unknown, so is the result of the comparison.
3426
34272011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3428
3429 * a-except-2005.adb (Raise_From_Controlled_Operation): Add new formal
3430 From_Abort. When finalization was triggered by an abort, propagate
3431 Standard'Abort_Signal rather than Program_Error.
3432 * a-except-2005.ads (Raise_From_Controlled_Operation): Add new formal
3433 From_Abort.
3434 * a-except.adb (Raise_From_Controlled_Operation): Add new formal
3435 From_Abort. When finalization was triggered by an abort, propagate
3436 Standard'Abort_Signal rather than Program_Error.
3437 * a-except.ads:(Raise_From_Controlled_Operation): Add new formal
3438 From_Abort.
3439 * exp_ch7.adb:(Build_Adjust_Or_Finalize_Statements): New local variable
3440 Abort_Id. Update the calls to Build_Object_Declarations and
3441 Build_Raise_Statement to include Abort_Id.
3442 (Build_Adjust_Statements): New local variable Abort_Id. Update the
3443 calls to Build_Object_Declarations and Build_Raise_Statement to include
3444 Abort_Id.
3445 (Build_Finalize_Statements): New local variable Abort_Id. Update the
3446 calls to Build_Object_Declarations and Build_Raise_Statement to include
3447 Abort_Id.
3448 (Build_Components): Create an entity for Abort_Id when exceptions are
3449 allowed on the target.
3450 (Build_Finalizer): New local variable Abort_Id.
3451 (Build_Initialize_Statements): New local variable Abort_Id. Update the
3452 calls to Build_Object_Declarations and Build_Raise_Statement to include
3453 Abort_Id.
3454 (Build_Object_Declarations): Add new formal Abort_Id. Create the
3455 declaration of flag Abort_Id to preserve the original abort status
3456 before finalization code is executed.
3457 (Build_Raise_Statement): Add new formal Abort_Id. Pass Abort_Id to
3458 runtime routine Raise_From_Controlled_Operation.
3459 (Create_Finalizer): Update the call to Build_Raise_Statement to include
3460 Abort_Id. Update the call to Build_Object_Declarations to include
3461 Abort_Id. Update the layout of the finalizer body.
3462 (Make_Handler_For_Ctrl_Operation): Add an actual for From_Abort.
3463 (Process_Transient_Objects): New local variable Abort_Id. Remove the
3464 clunky code to create all flags and objects related to
3465 exception propagation and replace it with a call to
3466 Build_Object_Declarations. Update the call to Build_Raise_Statement to
3467 include Abort_Id.
3468 * exp_ch7.ads (Build_Object_Declarations): Moved from body to spec.
3469 Add new formal Abort_Id and associated comment on its use.
3470 (Build_Raise_Statement): Add new formal Abort_Id and associated comment
3471 on its use.
3472 * exp_intr.adb (Expand_Unc_Deallocation): New local variable Abort_Id.
3473 Remove the clunky code to create all flags and objects related to
3474 exception propagation and replace it with a call to
3475 Build_Object_Declarations. Update the call to Build_Raise_Statement.
3476
34772011-08-03 Eric Botcazou <ebotcazou@adacore.com>
3478
3479 * s-tassta.adb: Fix minor typos.
3480
34812011-08-03 Robert Dewar <dewar@adacore.com>
3482
3483 * rtsfind.ads, makeutl.ads, prj.ads, prj.adb, make.adb,
3484 lib-writ.adb, makeutl.adb, s-soflin.ads, clean.adb: Minor reformatting.
3485
1cdfa9be
AC
34862011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3487
3488 * exp_ch7.adb (Create_Finalizer): Treat freeze nodes in similar fashion
3489 to packages. This ensures that the finalizer body will not end up
3490 inside the freeze node.
3491 (Process_Declarations): Add code to detect whether a freeze node has a
3492 nested finalization collection.
3493
34942011-08-03 Pascal Obry <obry@adacore.com>
3495
3496 * g-awk.adb, g-awk.ads: Make GNAT.AWK API compatible with Ada 2005.
3497 (Current_Session): Return a not null access to Session_Type.
3498 (Default_Session): Likewise.
3499
243cae0a
AC
35002011-08-03 Robert Dewar <dewar@adacore.com>
3501
3502 * a-cfdlli.adb, bindgen.adb, exp_ch4.adb, exp_ch13.adb, sem_warn.adb,
3503 exp_ch3.adb, exp_ch3.ads: Minor reformatting.
3504
35052011-08-03 Pascal Obry <obry@adacore.com>
3506
3507 * g-awk.ads: Minor comment fix.
3508
35092011-08-03 Sergey Rybin <rybin@adacore.com>
3510
3511 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
3512 the tree structure related to discriminant constraints.
3513 Original_Discriminant cannot be used any more for computing the
3514 defining name for the reference to a discriminant.
3515
35162011-08-03 Ed Schonberg <schonberg@adacore.com>
3517
3518 * sem_disp.adb (Is_Tag_Indeterminate): If the return type of the
3519 function is not visibly tagged, this is not a dispatching call and
3520 therfore is not Tag_Indeterminate, even if the function is marked as
3521 dispatching on result.
3522
f553e7bc
AC
35232011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3524
3525 * exp_ch13.adb: Add with and use clauses for Restrict and Rident.
3526 (Expand_N_Free_Statement): Add a guard to protect against run-times
3527 which do not support controlled types.
3528 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Add a guard to protect
3529 against run-times which do not support controlled types.
3530 * exp_ch4.adb (Complete_Controlled_Allocation): Add a guard to protect
3531 against run-times which do not support controlled types.
3532 * exp_ch7.adb (Build_Finalization_Collection): Add a guard to protect
3533 against run-times which do not support controlled types.
3534 * exp_util.adb (Needs_Finalization): Code reformatting. Add a guard to
3535 protect against run-times which do not support controlled types.
3536
35372011-08-03 Eric Botcazou <ebotcazou@adacore.com>
3538
3539 * exp_intr.adb: Put back with and use clauses for Exp_Ch11.
3540 (Expand_Unc_Deallocation): Expand the AT_END handler at the very end.
3541
e4982b64
AC
35422011-08-03 Ed Schonberg <schonberg@adacore.com>
3543
3544 * exp_ch5.adb (Expand_Iterator_Loop): indicate that the cursor is
3545 modified in the source, to prevent spurious warnings when compiling
3546 with -gnatg.
3547
35482011-08-03 Thomas Quinot <quinot@adacore.com>
3549
3550 * a-except-2005.adb: Minor reformatting.
3551
35522011-08-03 Ed Schonberg <schonberg@adacore.com>
3553
3554 * sem_warn.adb (Check_One_Unit): if the only mention of a withed unit
3555 is a renaming declaration in the private part of a package, do not emit
3556 a warning that the with_clause could be moved because the renaming may
3557 be used in the body or in a child unit.
3558
35592011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3560
3561 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
3562 Propagate the Comes_From_Source attribute from the original return
3563 object to the renaming.
3564
35652011-08-03 Jose Ruiz <ruiz@adacore.com>
3566
3567 * exp_ch7.adb (Build_Raise_Statement): Do not call
3568 Raise_From_Controlled_Operation when this routine is not present in
3569 the run-time library.
3570 (Cleanup_Protected_Object, Cleanup_Task): For restricted run-time
3571 libraries (Ravenscar), tasks are non-terminating, and protected objects
3572 and tasks can only appear at library level, so we do not want
3573 finalization of protected objects nor tasks.
3574 * exp_intr.adb: Minor clarification in comment.
3575 bindgen.adb (Gen_Adainit_Ada, Gen_Main_C, Gen_Output_File_Ada,
3576 Gen_Output_File_C): Remove references to finalization of library-level
3577 objects when using restricted run-time libraries.
3578
35792011-08-03 Ed Schonberg <schonberg@adacore.com>
3580
3581 * sem_ch3.adb (Build_Discriminant_Constraints): Set
3582 Original_Discriminant only if the parent type is a generic formal.
3583
deb8dacc
HK
35842011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3585
3586 * exp_ch13.adb: Add with and use clause for Targparm;
3587 (Expand_N_Free_Statement): Prevent the generation of a custom
3588 Deallocate on .NET/JVM targets since this requires pools and address
3589 arithmetic.
3590 * exp_ch4.adb (Expand_Allocator_Expression): When compiling for
3591 .NET/JVM targets, attach the newly allocated object to the access
3592 type's finalization collection. Do not generate a call to
3593 Set_Finalize_Address_Ptr on .NET/JVM because this routine does not
3594 exist in the runtime.
3595 (Expand_N_Allocator): When compiling for .NET/JVM targets, do not
3596 create a custom Allocate for object that do not require initialization.
3597 Attach a newly allocated object to the access type's finalization
3598 collection on .NET/JVM.
3599 * exp_ch5.adb (Make_Tag_Ctrl_Assignment): Add special processing for
3600 assignment of controlled types on .NET/JVM. The two hidden pointers
3601 Prev and Next and stored and later restored after the assignment takes
3602 place.
3603 * exp_ch6.adb (Expand_Call): Add local constant Curr_S. Add specialized
3604 kludge for .NET/JVM to recognize a particular piece of code coming from
3605 Heap_Management and change the call to Finalize into Deep_Finalize.
3606 * exp_ch7.adb (Build_Finalization_Collection): Allow the creation of
3607 finalization collections on .NET/JVM only for types derived from
3608 Controlled. Separate the association of storage pools with a collection
3609 and only allow it on non-.NET/JVM targets.
3610 (Make_Attach_Call): New routine.
3611 (Make_Detach_Call): New routine.
3612 (Process_Object_Declarations): Suppress the generation of
3613 build-in-place return object clean up code on .NET/JVM since it uses
3614 pools.
3615 * exp_ch7.ads (Make_Attach_Call): New routine.
3616 (Make_Detach_Call): New routine.
3617 * exp_intr.adb Add with and use clause for Targparm.
3618 (Expand_Unc_Deallocation): Detach a controlled object from a collection
3619 on .NET/JVM targets.
3620 * rtsfind.ads: Add entries RE_Attach, RE_Detach and
3621 RE_Root_Controlled_Ptr to tables RE_Id and RE_Unit_Table.
3622 * snames.ads-tmpl: Add name Name_Prev. Move Name_Prev to the special
3623 names used in finalization.
3624
36252011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3626
3627 * a-fihema.adb: Add with and use clauses for System.Soft_Links.
3628 (Attach, Detach): Lock the current task when chaining an object onto a
3629 collection.
3630
df3e68b1
HK
36312011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
3632
3633 * a-except.adb, a-except-2005.adb (Raise_From_Controlled_Operation):
3634 Rewritten to create the message strings when the exception is not
3635 raised by an abort during finalization.
3636 * a-except.ads, a-except-2005.ads: Add pragma Export for procedure
3637 Raise_From_Controlled_Operation and update its associated comment.
3638 * a-fihema.ads, a-fihema.adb: New GNAT unit.
3639 Ada.Finalization.Heap_Management provides key functionality
3640 associated with controlled objects on the heap, their creation,
3641 finalization and reclamation. Type Finalization_Collection is
3642 effectively a wrapper which sits ontop of a storage pool and performs
3643 all necessary bookkeeping for all the objects it contains. Each
3644 access-to-controlled or access-to-class-wide type receives a collection
3645 as part of its expansion. The compiler generates buffer code and
3646 invokes Allocate / Deallocate to create and destroy allocated
3647 controlled objects.
3648 * a-finali.adb ("="): Removed.
3649 * a-finali.ads ("="): Removed. Controlled types no longer carry hidden
3650 fields Prev and Next.
3651 * ali.adb (Scan_ALI): Add parsing code to process PF / Has_Finalizer.
3652 A library unit with at least one controlled object on the library level
3653 has a special finalizer which is invoked by the binder. To signal this,
3654 ali files carry field PF.
3655 * ali.ads: New field in type Unit_Record called Has_Finalizer. Add
3656 associated comment on field usage.
3657 * a-tags.adb (Get_RC_Offset): Removed.
3658 (Needs_Finalization): New routine.
3659 * a-tags.ads: Update the structure of the GNAT dispatch tables.
3660 Dispatch tables now carry field Needs_Finalization which provides
3661 runtime indication whether a type is controlled or has controlled
3662 components or both. Remove field RC_Offset.
3663 (Get_RC_Offset): Removed along with its associated pragma Export.
3664 Since tagged types with controlled components no longer carry hidden
3665 field _controller, the special mechanism to retrieve its location is no
3666 longer needed.
3667 (Needs_Finalization): New routine.
3668 * atree.ads, atree.adb (Elist24): New routine.
3669 (Set_Elist24): New routine.
3670 * atree.h: Add a define clause for Elist24.
3671 * bindgen.adb New library-level variable Lib_Final_Built.
3672 (Gen_Adafinal_Ada): Reimplemented. Depending on the restrictions or the
3673 presence of a VM target, the routine generates calls to the proper
3674 library finalization routine.
3675 (Gen_Adainit_Ada): Import Finalize_Library_Objects only on non-VM
3676 targets. Set the correct library finalization routine depending on
3677 whether the library has controlled objects or this is a VM compilation.
3678 (Gen_Finalize_Library_Ada): New routine. This procedure generates calls
3679 to library-level finalizers of compiled units in reverse order of
3680 elaboration. It also produces exception management code and reraises a
3681 potential exception after all units have been finalized.
3682 (Gen_Finalize_Library_C): New routine. This procedure generates calls to
3683 library-level finalizers of compiled units in reverse order of
3684 elaboration.
3685 (Gen_Finalize_Library_Defs_C): New routine. This procedure generates the
3686 definitions of all library-level finalizers available to the compilation
3687 (Gen_Main_Ada): Directly call Adafinal which now contails all target
3688 dependent code.
3689 (Gen_Main_C): Add new local constant Needs_Library_Finalization. Call
3690 System.Standard_Library.Adafinal directly. If the library needs
3691 finalization actions, create the sequence of finalization calls.
3692 (Gen_Output_File_Ada): Alphabetize local variables and constants.
3693 Generate a with clause for System.Soft_Links when compiling for a VM.
3694 Remove the code which imports System.Standard_Library.Adafinal as
3695 Do_Finalize. Generate the library finalization routine.
3696 (Gen_Output_File_C): Add new local constant Needs_Library_Finalization.
3697 If the library needs finalization actions, create all the definitions
3698 of library- level finalizers.
3699 (Has_Finalizer): New routine. Determines whether at least one compiled
3700 unit has a library-level finalizer.
3701 Add type Qualification_Mode.
3702 (Set_Unit_Name): Add a formal which controls the replacement of a dot.
3703 * einfo.adb: New usage of field 15 as Return_Flag.
3704 Remove Finalization_Chain_Entity from the usages of field 19.
3705 Remove Associated_Final_Chain from the usages of field 23.
3706 New usage of field 23 as Associated_Collection.
3707 New usage of field 24 as Finalizer.
3708 New usage of flag 252 as Is_Processed_Transient.
3709 (Associated_Final_Chain): Removed.
3710 (Associated_Collection): New routine.
3711 (Finalization_Chain_Entity): Removed.
3712 (Finalizer): New routine.
3713 (Is_Finalizer): New routine.
3714 (Is_Processed_Transient): New routine.
3715 (Return_Flag): New routine.
3716 (Set_Associated_Final_Chain): Removed.
3717 (Set_Associated_Collection): New routine.
3718 (Set_Finalization_Chain_Entity): Removed.
3719 (Set_Finalizer): New routine.
3720 (Set_Is_Processed_Transient): New routine.
3721 (Set_Return_Flag): New routine.
3722 (Write_Entity_Flags): Include Is_Processed_Transient to the list of
3723 displayed flags.
3724 (Write_Field8_Name): Alphabetize the output.
3725 (Write_Field11_Name): Alphabetize the output.
3726 (Write_Field12_Name): Alphabetize the output.
3727 (Write_Field13_Name): Alphabetize the output.
3728 (Write_Field14_Name): Alphabetize the output.
3729 (Write_Field15_Name): Alphabetize the output.
3730 (Write_Field16_Name): Alphabetize the output.
3731 (Write_Field17_Name): Alphabetize the output.
3732 (Write_Field18_Name): Alphabetize the output.
3733 (Write_Field19_Name): Alphabetize the output. Remove the output of
3734 Finalization_Chain_Entity.
3735 (Write_Field20_Name): Alphabetize the output.
3736 (Write_Field21_Name): Alphabetize the output.
3737 (Write_Field22_Name): Alphabetize the output.
3738 (Write_Field23_Name): Alphabetize the output. Remove the output of
3739 Associated_Final_Chain. Add output for Associated_Collection.
3740 (Write_Field24_Name): Alphabetize the output.
3741 (Write_Field25_Name): Add output for Finalizer.
3742 (Write_Field26_Name): Alphabetize the output.
3743 (Write_Field27_Name): Alphabetize the output.
3744 (Write_Field28_Name): Alphabetize the output.
3745 * einfo.ads: Add new field description for Associated_Collection and
3746 its uses in nodes.
3747 Remove Associated_Final_Chain and its uses in nodes.
3748 Remove Finalization_Chain_Entity and its uses in nodes.
3749 Add new field description for Finalizer and its uses in nodes.
3750 Add new synthesized attribute Is_Finalizer.
3751 Add new flag description for Is_Processed_Transient and its uses in
3752 nodes.
3753 Add new field description for Return_Flag and its uses in nodes.
3754 (Associated_Final_Chain): Removed along with its pragma Inline.
3755 (Associated_Collection): New routine and pragma Inline.
3756 (Finalization_Chain_Entity): Removed along with its pragma Inline.
3757 (Finalizer): New routine and pragma Inline.
3758 (Is_Finalizer): New routine and pragma Inline.
3759 (Is_Processed_Transient): New routine and pragma Inline.
3760 (Return_Flag): New routine and pragma Inline.
3761 (Set_Associated_Final_Chain): Removed along with its pragma Inline.
3762 (Set_Associated_Collection): New routine and pragma Inline.
3763 (Set_Finalization_Chain_Entity): Removed along with its pragma Inline.
3764 (Set_Finalizer): New routine and pragma Inline.
3765 (Set_Is_Processed_Transient): New routine and pragma Inline.
3766 (Set_Return_Flag): New routine and pragma Inline.
3767 * exp_aggr.adb: Alphabetize subprograms.
3768 (Build_Array_Aggr_Code): Remove formal Flist and its associated comment.
3769 (Build_Record_Aggr_Code): Remove formals Flist and Obj along with their
3770 associated comments. Remove local variables External_Final_List and
3771 Attach.
3772 Rename Ctrl_Stuff_Done to Finalization_Done. Rename local variable A to
3773 Ancestor. Remove the retrieval of finalization lists. Update the call to
3774 Make_Adjust_Call.
3775 (Convert_Aggr_In_Allocator): Remove the retrieval of finalization
3776 lists. Update the call to Late_Expansion.
3777 (Convert_Aggr_In_Assignment): Update the call to Late_Expansion.
3778 (Convert_Aggr_In_Object_Decl): Update the call to Late_Expansion.
3779 (Gen_Assign): Remove the retrieval of the finalization list used to
3780 build the assignment. Update the calls to Make_Init_Call and
3781 Make_Adjust_Call.
3782 (Gen_Ctrl_Actions_For_Aggr): Renamed to Generate_Finalization_Actions.
3783 Remove the mechanism to determine attachment levels and finalization
3784 list retrieval. Remove the processing for coextensions.
3785 (Init_Controller): Removed. Controllers no longer exist.
3786 (Late_Expansion): Remove formals Flist and Obj along with their
3787 associated comments. Update the calls to Build_Record_Aggr_Code and
3788 Build_Array_Aggr_Code.
3789 * exp_ch13.adb (Expand_N_Free_Statement): New routine.
3790 (Expand_N_Freeze_Entity): Add special processing for finalizers which
3791 appear in entry bodies, protected subprograms and task bodies.
3792 * exp_ch13.ads (Expand_N_Free_Statement): New routine.
3793 * exp_ch3.adb (Add_Final_Chain): Removed.
3794 (Build_Array_Init_Proc): Alphabetize local variables.
3795 (Build_Assignment): Alphabetize local variables. Update the call to
3796 Maked_Adjust_Call.
3797 (Build_Class_Wide_Master): Rename local variables to better reflect
3798 their role.
3799 (Build_Discriminant_Assignments): Code reformatting.
3800 (Build_Init_Call_Thru): Code reformatting.
3801 (Build_Init_Procedure): Code reformatting. Generate a special version
3802 of Deep_Finalize which is capable of finalizing all initialized
3803 components and ignore the rest.
3804 (Build_Init_Statements): Rename local variables to better reflect their
3805 role.
3806 Reimplement the mechanism to include the creation and update of an index
3807 variable called a "counter". It is used as a bookmark for tracing
3808 initialized and non-initialized components.
3809 (Build_Initialization_Call): Remove local variable Controller_Typ.
3810 Alphabetize all local variables. Remove the initialization of the
3811 record controller and update the call to Make_Init_Call.
3812 (Build_Record_Init_Proc): Rename formal Pe to Rec_Ent.
3813 New local variable Counter.
3814 (Constrain_Array): Alphabetize.
3815 (Expand_Freeze_Array_Type): Create a collection instead of a
3816 finalization list.
3817 (Expand_Freeze_Class_Wide_Type): New routine. Creates TSS primitive
3818 Finalize_Address which is used in conjunction with allocated controlled
3819 objects.
3820 (Expand_N_Object_Declaration): Remove the creation of a finalization
3821 list for anonymous access types. Update the calls to Make_Init_Call and
3822 Make_Adjust_Call.
3823 (Expand_Freeze_Record_Type): Remove local variable Flist. Remove the
3824 retrieval of finalization lists. Remove the expansion of the record
3825 controller. Create TSS primitive Finalize_Address used in conjunction
3826 with controlled objects on the heap. Create finalization collections
3827 for access-to-controlled record components.
3828 (Expand_Record_Controller): Removed.
3829 (Freeze_Type): Remove the freezing of record controllers. Freezing of
3830 class-wide types now requires additional processing. Create
3831 finalization collections for access-to-controlled types.
3832 (Increment_Counter): New routine.
3833 (Make_Counter): New routine.
3834 (Make_Eq_If): Remove the mention of Name_uController.
3835 (Make_Predefined_Primitive_Specs): There is no longer need to skip
3836 types coming from System.Finalization_Root.
3837 (Predef_Deep_Spec): Reimplemented to reflect the new parameter profiles.
3838 (Predefined_Primitive_Bodies): There is no longer need to skip types
3839 coming from System.Finalization_Root.
3840 (Stream_Operation_OK): Do not generate stream routines for
3841 type Ada.Finalization.Heap_Management.Finalization_Collection.
3842 * exp_ch3.ads: Alphabetize subprograms.
3843 * exp_ch4.adb: Remove with and use clause for Sem_Ch8.
3844 Add with and use clause for Lib.
3845 (Complete_Coextension_Finalization): Removed.
3846 (Complete_Controlled_Allocation): New routine. Create a finalization
3847 collection for anonymous access-to-controlled types. Create a custom
3848 Allocate which interfaces with the back end and the machinery in
3849 Heap_Management.
3850 (Expand_Allocator_Expression): Add necessary calls to
3851 Complete_Controlled_Allocation. Remove the retrieval of finalization
3852 lists. Update the calls to Make_Adjust_Call. Generate a call to
3853 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
3854 the associated collection.
3855 (Expand_N_Allocator): Remove the processing for dynamic coextensions.
3856 Code clean up. Remove the retrieval of finalization lists and
3857 attachment levels.
3858 Update the call to Make_Init_Call. Generate a call to
3859 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
3860 the associated collection.
3861 (Get_Allocator_Final_List): Removed. Finalization lists are not
3862 available.
3863 (Suitable_Element): Remove the mention of Name_uController.
3864 * exp_ch5.adb: Remove with and use clauses for Ttypes and Uintp.
3865 (Make_Tag_Ctrl_Assignment): Rewritten to simply do a finalization of
3866 the left hand side, carry out the assignment and adjust the left hand
3867 side.
3868 * exp_ch6.adb (Add_Final_List_Actual_To_Build_In_Place_Call): Removed.
3869 (Add_Collection_Actual_To_Build_In_Place_Call): New routine.
3870 (BIP_Formal_Suffix): Rename BIP_Final_List and BIPfinallist to
3871 BIP_Collection and BIPcollection.
3872 (Build_Heap_Allocator): New routine used to allocate the return object
3873 of a build-in-place function onto a collection.
3874 (Expand_Ctrl_Function_Call): Moved from Exp_Ch7.
3875 (Expand_Call): Do not replace direct calls to Deep routines with their
3876 aliases.
3877 (Expand_N_Extended_Return_Statement): Give all variables shorter names
3878 and update their occurrences. Add a special return flag to monitor the
3879 [ab]normal execution of the function. The flag is set right before the
3880 return statement.
3881 Rewrite the mechanism used to allocate a build-in-place return object
3882 on the heap or on a storage pool.
3883 (Is_Direct_Deep_Call): New routine.
3884 (Make_Build_In_Place_Call_In_Allocator): Add a collection to a
3885 build-in-place function call instead of a final list. Build a call to
3886 Set_Finalize_Address_Ptr to decorate the associated collection.
3887 (Make_Build_In_Place_Call_In_Anonymous_Context): Create a temporary in
3888 order to name the build-in-place function call's result for later
3889 finalization. Add a collection to a build-in-place function call
3890 instead of a final list.
3891 (Make_Build_In_Place_Call_In_Assignment): Add a collection to a
3892 build-in-place function call instead of a final list. Remove the code
3893 which moves one final list and transforms it into the actual in a
3894 nested build-in-place call.
3895 (Make_Build_In_Place_Call_In_Object_Declaration): Add a collection to a
3896 build-in-place function call instead of a final list.
3897 (Move_Final_List): Removed.
3898 (Needs_BIP_Collection): New routine.
3899 (Needs_BIP_Final_List): Removed.
3900 * exp_ch6.ads: Replace BIP_Final_List with BIP_Collection in
3901 enumeration type BIP_Formal_Kind.
3902 Update the related comment.
3903 (Needs_BIP_Collection): New routine.
3904 (Needs_BIP_Final_List): Removed.
3905 * exp_ch7.adb: Add with and use clauses for Elists, Exp_Ch6, Stringt
3906 and Ttypes. Remove with and use clauses for Sem_Type. Alphabetize the
3907 majority of subprograms in this unit. Add Name_Finalize_Address to
3908 array Name_Of and TSS_Finalize_Address to array Deep_Name_Of.
3909 (Build_Adjust_Or_Finalize_Statements): Create the adjust or finalization
3910 statements for an array type.
3911 (Build_Adjust_Statements): Create the adjust statements for a record
3912 type.
3913 (Build_Cleanup_Statements): New routine. A procedure which given any
3914 construct containing asynchronous calls, references to _master, or is a
3915 task body, a task allocation or a protected body produces the necessary
3916 runtime calls to clean up these constructs.
3917 (Build_Exception_Handler): New routine.
3918 (Build_Final_List): Removed.
3919 (Build_Finalization_Collection): New routine. A core procedure which
3920 creates a collection to service heap allocated controlled objects
3921 associated with an access-to-controlled type.
3922 (Build_Finalize_Statements): Create the finalization statements for a
3923 record types.
3924 (Build_Finalizer): New routine. A core procedure which given any
3925 construct with declarations and/or statements detects all objects which
3926 need any type of clean up (controlled objects, protected objects) and
3927 generates all necessary code to clean up the said objects in the proper
3928 order.
3929 (Build_Finalizer_Call): New routine.
3930 (Build_Initialize_Statements): Create the initialization statements for
3931 an array type. The generated routine contains code to finalize partially
3932 initialized arrays.
3933 (Build_Object_Declarations): New routine.
3934 (Build_Raise_Statement): New routine.
3935 (Clean_Simple_Protected_Objects): Removed.
3936 (Controller_Component): Removed.
3937 (Enclosing_Function): New routine.
3938 (Expand_Cleanup_Actions): Create a finalizer for a construct which has
3939 either declarations or statements or both.
3940 (Expand_N_Package_Body): Create a finalizer for a non-generic package.
3941 (Expand_N_Package_Declaration): Create a finalizer for a non-generic
3942 package.
3943 (Find_Final_List): Removed.
3944 (Global_Flist_Ref): Removed.
3945 (In_Finalization_Root): Removed.
3946 (Insert_Actions_In_Scope_Around): Determine the range of the transient
3947 scope in terms of tree nodes. Process all transient variables within
3948 that range.
3949 (Make_Adjust_Call): Rewritten. There is no longer an attach call
3950 generated after the adjust.
3951 (Make_Attach_Call): Removed.
3952 (Make_Call): New routine.
3953 (Make_Clean): Removed.
3954 (Make_Deep_Array_Body): Rewritten to simply invoke the appropriate
3955 build routines.
3956 (Make_Deep_Proc): Rewritten to generate the new profile signature used
3957 in Deep routines.
3958 (Make_Deep_Record_Body): Rewritten to simply invoke the appropriate
3959 build routines.
3960 (Make_Final_Call): Modified to simply create a call to either
3961 Deep_Finalize or Finalize.
3962 (Make_Finalize_Address_Body): New routine.
3963 (Make_Finalize_Address_Stmts): New routine. A function which produces
3964 TSS primitive Finalize_Address used in conjunction with heap allocated
3965 controlled objects.
3966 (Make_Handler_For_Ctrl_Operation): Add specialized code for .NET/JVM.
3967 (Make_Init_Call): Rewritten. There is no longer an attach call
3968 generated after initialization.
3969 (Make_Local_Deep_Finalize): New routine.
3970 (Make_Set_Finalize_Address_Ptr_Call): New routine.
3971 (Make_Transient_Block): Remove the finalization list retrieval and
3972 manipulation.
3973 (Needs_Finalization): Moved to Exp_Util.
3974 (Parent_Field_Type): New routine.
3975 (Preprocess_Components): New routine.
3976 (Process_Transient_Objects): New routine.
3977 (Wrap_HSS_In_Block): New routine.
3978 (Wrap_Transient_Declaration): Remove finalization list management and
3979 controller insertion.
3980 (Wrap_Transient_Expression): Code reformatting.
3981 (Wrap_Transient_Statement): Code reformatting.
3982 * exp_ch7.ads (Build_Final_List): Removed.
3983 (Build_Finalization_Collection): New routine.
3984 (Build_Raise_Statement): New routine.
3985 (Controller_Component): Removed.
3986 (Expand_Ctrl_Function_Call): Moved to Exp_Ch6.
3987 (Find_Final_List): Removed.
3988 (In_Finalization_Root): Removed.
3989 (Is_Simple_Protected_Type): Update related comment.
3990 (Make_Adjust_Call): New parameter profile and associated comments.
3991 (Make_Attach_Call): Removed.
3992 (Make_Final_Call): New parameter profile and associated comments.
3993 (Make_Finalize_Address_Body): New routine.
3994 (Make_Init_Call): New parameter profile and associated comments.
3995 (Make_Local_Deep_Finalize): New routine.
3996 (Make_Set_Finalize_Address_Ptr_Call): New routine.
3997 (Needs_Finalization): Moved to Exp_Util.
3998 * exp_ch9.adb (Add_Object_Pointer): Code reformatting.
3999 (Expand_N_Protected_Body): Remove the handling of finalization lists.
4000 (Find_Protection_Type): Moved to Exp_Util.
4001 * exp_disp.adb: Remove with and use clauses for Exp_Ch7.
4002 (Make_DT): Update sequence of dispatch table initialization. Remove the
4003 initialization of field RC_Offset. Add initialization of field Needs_
4004 Finalization.
4005 * exp_intr.adb (Expand_Unc_Deallocation): Code reformatting.
4006 Reimplement how an object is first finalized, then deallocated.
4007 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
4008 Code reformatting.
4009 * exp_tss.ads: Add special suffix for TSS primitive Finalize_Address.
4010 Register TSS_Finalize_Address with type TSS_Names.
4011 * exp_util.adb (Build_Allocate_Deallocate_Proc): New routine. This core
4012 procedure provides the interface between an allocation / deallocation
4013 and the support machinery in Ada.Finalization.Heap_Management.
4014 (Find_Init_Call): Code reformatting.
4015 (Find_Init_Call_In_List): Code reformatting.
4016 (Find_Protection_Type): Moved from Exp_Ch9.
4017 (Find_Prim_Op): Reimplement to add preference of recovered primitive.
4018 (Has_Controlled_Coextensions): Removed.
4019 (Has_Controlled_Objects): New routine.
4020 (In_Library_Level_Package_Body): New routine.
4021 (Insert_Action_After): New routine.
4022 (Is_Finalizable_Transient): New routine. This predicate determines
4023 whether an object declaration is one of the many variants of controlled
4024 transients.
4025 (Is_Null_Access_BIP_Func_Call): New routine.
4026 (Is_Non_BIP_Func_Call): New routine.
4027 (Is_Related_To_Func_Return): New routine.
4028 (Needs_Finalization): Moved from Exp_Ch7.
4029 * exp_util.ads (Build_Allocate_Deallocate_Proc): New routine.
4030 (Find_Protection_Type): Moved from Exp_Ch9.
4031 (Has_Controlled_Coextensions): Removed.
4032 (Has_Controlled_Objects): New routine.
4033 (In_Library_Level_Package_Body): New routine.
4034 (Insert_Action_After): New routine.
4035 (Is_Finalizable_Transient): New routine.
4036 (Is_Null_Access_BIP_Func_Call): New routine.
4037 (Is_Non_BIP_Func_Call): New routine.
4038 (Is_Related_To_Func_Return): New routine.
4039 (Needs_Finalization): Moved from Exp_ch7.
4040 * expander.adb (Expand): Add a case for N_Free_Statement.
4041 * freeze.adb (Freeze_All): Replace the generation of a finalization
4042 list with a collection for access-to-controlled types.
4043 (Freeze_Entity): Code reformatting.
4044 (Freeze_Record_Type): Remove the freezing of a record controller
4045 component.
4046 (Freeze_Subprogram): Code reformatting.
4047 * inline.adb (Cleanup_Scopes): Remove the reset of the scope
4048 finalization list.
4049 * lib-writ.adb (Write_Unit_Information): Output "PF" when a package
4050 has a library-level finalizer.
4051 * lib-writ.ads: Add "PF" to the sequence of unit attributes.
4052 * a-filico.ads, a-filico.adb, s-finimp.ads, s-finimp.adb: Removed.
4053 * Makefile.rtl: Remove a-filico and s-finimp from the list of object
4054 files. Add a-fihema to the list of object files.
4055 * par-ch4.adb:
4056 Alphabetize the associations in type Is_Parameterless_Attribute.
4057 * rtsfind.ads: Ada.Finalization_List.Controller and
4058 System.Finalization_Implementation are no longer a GNAT unit.
4059 Update the range of type Ada_Finalization_Child. Remove the following
4060 recoverable entities:
2c7f9cc0 4061
df3e68b1
HK
4062 RE_Attach_To_Final_List
4063 RE_Deep_Tag_Attach
4064 RE_Finalize_List
4065 RE_Finalize_One
4066 RE_Finalizable_Ptr_Ptr
4067 RE_Global_Final_List
4068 RE_Limited_Record_Controller
4069 RE_List_Controller
4070 RE_Move_Final_List
4071 RE_Record_Controller
4072 RE_Simple_List_Controller
2c7f9cc0 4073
df3e68b1 4074 Add the following recoverable entities:
2c7f9cc0 4075
df3e68b1
HK
4076 RE_Add_Offset_To_Address
4077 RE_Allocate
4078 RE_Base_Pool
4079 RE_Deallocate
4080 RE_Exception_Identity
4081 RE_Finalization_Collection
4082 RE_Finalization_Collection_Ptr
4083 RE_Needs_Finalization
4084 RE_Save_Library_Occurrence
4085 RE_Set_Finalize_Address_Ptr
4086 RE_Set_Storage_Pool_Ptr
4087 RE_Storage_Count
4088 * sem_aggr.adb (Resolve_Record_Aggregate): Remove mention of
4089 Name_uController.
4090 * sem_aux.adb (First_Discriminant): Remove mention of Name_uController.
4091 (First_Stored_Discriminant): Remove the mention of Name_uController.
4092 * sem_aux.ads: Comment reformatting.
4093 * sem_ch10.adb (Build_Chain): Signal the class-wide creation machinery
4094 to redecorate an already existing class-wide type.
4095 (Decorate_Tagged_Type): New parameter profile and associated comment.
4096 Create a "shadow class-wide type" for a shadow entity.
4097 * sem_ch11.adb (Analyze_Exception_Handlers): Remove the dubious setting
4098 of the final chain along with the associated comment.
4099 * sem_ch3.adb (Access_Type_Declaration): Add new local variable
4100 Full_Desig and set it to the full view of the designated type.
4101 Initialize the finalization collection to empty.
4102 (Build_Derived_Record_Type): Alphabetize local variables. Code
4103 reformatting.
4104 (Collect_Fixed_Components): Remove the mention of Name_uController.
4105 (Create_Constrained_Components): Remove the mention of Name_uController.
4106 (Make_Class_Wide_Type): Add specialized code to redecorate an existing
4107 class-wide type of a shadow entity.
4108 (Process_Full_View): Update the machinery which marks type
4109 Limited_Controlled's entity as limited.
4110 * sem_ch4.adb (Analyze_One_Call): Code reformatting.
4111 * sem_ch6.adb (Create_Extra_Formals): Do not generate a finalization
4112 list, instead make a collection build-in-place formal.
4113 * sem_ch8.adb (Analyze_Object_Renaming): Look at the available view of
4114 a designated type in order to establish a match between the renaming
4115 and the renamed entity.
4116 (Find_Selected_Component): Add guard to prevent spurious exceptions
4117 from being raised on .NET/JVM.
4118 * sem_disp.adb (Check_Dispatching_Operation): Include Finalize_Address
4119 to the list of primitive that need special processing. Update arrays
4120 C_Names and D_Names.
4121 (Replace_Types): Handle class-wide types.
4122 * sem_elab.adb (Check_A_Call): Since Deep_Initialize now has a
4123 different parameter profile, look at the first formal.
4124 * sem_prag.adb: Remove with and use clauses for Exp_Ch7. Add with and
4125 use clauses for Exp_Util.
4126 * sem_res.adb: Remove with and use clauses for Elists.
4127 (Propagate_Coextensions): Removed.
4128 (Resolve_Allocator): Do not propagate the list of coextensions from one
4129 allocator to another.
4130 * sem_util.adb (Build_Actual_Subtype_Of_Component): Rename variable
4131 Deaccessed_T to Desig_Typ.
4132 (Enter_Name): Remove the mention of Name_uController.
4133 (Gather_Components): Remove the mention of Name_uController.
4134 (Incomplete_Or_Private_View): New routine.
4135 (Is_Coextension_Root): Removed.
4136 (Is_Fully_Initialized_Type): Remove the mention of Name_uController.
4137 * sem_util.ads (Incomplete_Or_Private_View): New routine.
4138 (Is_Coextension_Root): Removed.
4139 * s-finroo.ads: Remove with clause for Ada.Unchecked_Conversion.
4140 Controlled types are now derived from a null tagged record. Remove
4141 types Finalizable_Ptr, Finalizable and Empty_Root_Controlled.
4142 * sinfo.adb (Coextensions): Removed.
4143 (Set_Coextensions): Removed.
4144 * sinfo.ads: Remove Coextensions from the explanation of node fields
4145 and its uses in nodes.
4146 Update the field usage of N_Allocator.
4147 (Coextensions): Removed along with its pragma Inline.
4148 (Set_Coextensions): Removed along with its pragma Inline.
4149 * snames.ads-tmpl: Remove names
2c7f9cc0 4150
df3e68b1
HK
4151 Name_uClean
4152 Name_uController
4153 Name_uFinal_List
4154 Name_uLocal_Final_List
4155 Name_Finalization_Root
4156 Name_Next
4157 Name_Prev
2c7f9cc0 4158
df3e68b1 4159 Add names
2c7f9cc0 4160
df3e68b1
HK
4161 Name_uFinalizer
4162 Name_Finalize_Address
4163 * s-pooglo.adb (Allocate): Add overriding indicator.
4164 (Deallocate): Add overriding indicator.
4165 (Storage_Size): Add overriding indicator.
4166 * s-soflin.adb (Adafinal_NT): Invoke Finalize_Library_Objects rather
4167 than Finalize_Global_List.
4168 (Null_Finalize_Global_List): Removed.
4169 (Save_Library_Occurrence): New routine.
4170 * s-soflin.ads: Remove variable Finalize_Global_List along with its
4171 initialization. Add variable Finalize_Library_Objects along with its
4172 pragma Export. Add variables Library_Exception and
4173 Library_Exception_Set along with their pragma Export.
4174 (Null_Finalize_Global_List): Removed.
4175 (Save_Library_Occurrence): New routine.
4176 * s-tassta.adb (Finalize_Global_Tasks): Call Finalize_Library_Objects
4177 rather than Finalize_Global_List.
4178 * tbuild.adb (Unchecked_Convert_To): Capture and set the parent field
4179 of the constructed node.
4180
2ee06322
RO
41812011-08-03 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4182
4183 * link.c: Include "auto-host.h" before system headers.
4184
f77b022b
VC
41852011-08-03 Vincent Celier <celier@adacore.com>
4186
4187 * make.adb (Gnatmake): Add to table Library_Projs only library projects
4188 that are not extended. Do not check if a library project that is
4189 extended should be regenerated. Do not add to table Library_Paths the
4190 libraries that are in extended projects. Link only with libraries that
4191 are in libray projects that are not extended.
4192 * prj-nmsc.adb (Check_Library_Attributes): Do not reset flag Library
4193 for a library project that is extended.
4194
0187b60e
AC
41952011-08-03 Gary Dismukes <dismukes@adacore.com>
4196
4197 * sem_ch6.adb (Find_Corresponding_Spec): When in an instance, skip
4198 conforming subprogram renamings that appear to be completions if they
4199 are not fully conformant.
4200 Such renamings are homographs but not completions.
4201 * sem_type.adb (Disambiguate): Handle disambiguation of overloaded
4202 names in a subprogram renaming that appears in an instance.
4203
42042011-08-03 Ed Schonberg <schonberg@adacore.com>
4205
4206 * exp_util.adb (Expand_Subtype_From_Expr): if the type is limited but
4207 not immutably limited, build actual subtype from expression to provide
4208 proper bounds to caller.
4209
42102011-08-03 Gary Dismukes <dismukes@adacore.com>
4211
4212 * sem_ch8.adb: Minor comment correction.
4213
42142011-08-03 Thomas Quinot <quinot@adacore.com>
4215
4216 * exp_strm.adb (Build_Array_Input_Function): In Ada 2005 mode, when
4217 returning a limited array, use an extended return statement.
4218
42192011-08-03 Vincent Celier <celier@adacore.com>
4220
4221 * make.adb (Initialize): If --subdirs= is used, but no project file is
4222 specified, attempt to create the specify subdir if it does not already
4223 exist and use it as the object directory as if -D had been specified.
4224
42252011-08-03 Arnaud Charlet <charlet@adacore.com>
4226
4227 * s-tpopsp-vms.adb: New file.
4228 * s-taprop-vms.adb: Put back ATCB_Key, since needed by this file on VMS.
4229 * gcc-interfaces/Makefile.in: Use s-taprop-vms.adb on VMS.
4230
e280f981
AC
42312011-08-03 Emmanuel Briot <briot@adacore.com>
4232
4233 * make.adb, makeutl.adb, makeutl.ads, clean.adb (Makeutl.Queue): new
4234 package.
4235
42362011-08-03 Yannick Moy <moy@adacore.com>
4237
4238 * cstand.adb (Create_Standard): select Universal_Integer as an ALFA type
4239 * sem_ch3.adb (Array_Type_Declaration): detect array types in ALFA
4240 * sem_util.adb, sem_util.ads (Has_Static_Array_Bounds): new function to
4241 detect that an array has static bounds.
4242
98c99a5a
AC
42432011-08-03 Thomas Quinot <quinot@adacore.com>
4244
4245 * exp_dist.adb: Minor reformatting.
4246
42472011-08-03 Arnaud Charlet <charlet@adacore.com>
4248
4249 * s-taprop-irix.adb, s-taprop-hpux-dce.adb, s-taprop-vms.adb
4250 (ATCB_Key): Removed, not always used.
4251
42522011-08-03 Emmanuel Briot <briot@adacore.com>
4253
4254 * gnatcmd.adb, make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads,
4255 clean.adb, prj-conf.adb, prj-env.adb, prj-env.ads (Makeutl): remove
4256 most remaining global variables.
4257
686d0984
AC
42582011-08-03 Robert Dewar <dewar@adacore.com>
4259
4260 * gnatcmd.adb, prj-proc.adb, mlib-prj.adb, prj.adb, makeutl.ads,
4261 prj-util.adb, prj-util.ads, prj-conf.adb, prj-env.adb: Minor
4262 reformatting.
4263
42642011-08-03 Javier Miranda <miranda@adacore.com>
4265
4266 * exp_util.adb (Is_VM_By_Copy_Actual): Include N_Slide nodes as actuals
4267 that must be passed by copy in VM targets.
4268
42692011-08-03 Emmanuel Briot <briot@adacore.com>
4270
4271 * prj.ads, prj-nmsc.adb (Files_Htable): removed this htable, which
4272 duplicates a similar htable now in the project tree.
4273
42742011-08-03 Claire Dross <dross@adacore.com>
4275
4276 * a-cfdlli.adb, a-cfhama.adb, a-cfhase.adb, a-cforma.adb, a-cforse.adb,
4277 a-cofove.adb ("=", Length, Is_Empty, Clear, Assign, Copy, Element,
4278 Replace_Element, Query_Element, Update_Element, Move, Insert, Prepend,
4279 Append, Delete, Delete_First, Delete_Last, Reverse_Element, Swap,
4280 Splice, First, First_Element, Last, Last_Element, Next, Previous, Find,
4281 Reverse_Find, Contains, Has_Element, Iterate, Reverse_Iterate, Capacity,
4282 Reserve_Length, Length, Strict_Equal, Left, Right): Data-structure
4283 update.
4284
42852011-08-03 Arnaud Charlet <charlet@adacore.com>
4286
4287 * s-taprop-posix.adb, s-taprop-linux.adb, s-taprop-tru64.adb
4288 (ATCB_Key): Removed, not always used.
4289 * s-tpopsp-posix.adb, s-tpopsp-posix-foreign.adb (ATCB_Key): Moved from
4290 s-taprop-posix.adb.
4291 * s-tpopsp-tls.adb: New file.
4292 * gcc-interface/Makefile.in: Use TLS implementation of s-tpopsp.adb on
4293 x86/x64/ia64/powerpc/sparc Linux.
4294
42952011-08-03 Arnaud Charlet <charlet@adacore.com>
4296
4297 * system-aix.ads, system-aix64.ads: Set ZCX_By_Default to True.
4298 * gcc-interface/Makefile.in: Switch to ZCX by default on AIX ports.
4299
43002011-08-03 Thomas Quinot <quinot@adacore.com>
4301
4302 * rtsfind.ads, exp_dist.adb, exp_dist.ads
4303 (Build_From_Any_Call, Build_To_Any_Call, Build_TypeCode_Call):
4304 Fix type selection for mapping integer types to PolyORB types.
4305
43062011-08-03 Bob Duff <duff@adacore.com>
4307
4308 * sem_ch7.adb: Minor comment clarification.
4309
43102011-08-03 Bob Duff <duff@adacore.com>
4311
4312 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): If we get
4313 an error analyzing a choice, skip further processing. Further
4314 processing could cause a crash or cascade errors.
4315
40ecf2f5
EB
43162011-08-03 Emmanuel Briot <briot@adacore.com>
4317
4318 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, mlib-prj.adb,
4319 prj.adb, prj.ads, makeutl.adb, makeutl.ads, clean.adb, prj-nmsc.adb,
4320 prj-util.adb, prj-util.ads, prj-conf.adb, prj-conf.ads, prj-env.adb,
4321 prj-env.ads (Shared_Project_Tree_Data): new type
4322 An aggregate project and its aggregated trees need to share the common
4323 data structures used for lists of strings, packages,... This makes the
4324 code simpler since otherwise we have to pass the root tree (also used
4325 for the configuration file data) in addition to the current project
4326 tree. This also avoids ambiguities as to which tree should be used.
4327 And finally this saves a bit of memory.
4328 (For_Every_Project_Imported): new parameter Tree.
4329 Since aggregated projects are using a different tree, we need to let
4330 the caller know which tree to use to manipulate the returned project.
4331
9fde638d
RD
43322011-08-03 Robert Dewar <dewar@adacore.com>
4333
4334 * prj-proc.adb, exp_util.ads, exp_ch9.adb, make.adb, prj-ext.adb,
4335 prj-ext.ads, alfa.ads, sem_ch4.adb, makeutl.adb, makeutl.ads,
4336 lib-xref-alfa.adb, sem_cat.adb, exp_dist.adb, get_alfa.adb,
4337 prj-env.adb, prj-env.ads, prj-tree.adb, alfa.ads: Minor reformatting.
4338
95eb8b69
AC
43392011-08-03 Javier Miranda <miranda@adacore.com>
4340
4341 * exp_util.adb, sem_aux.adb, exp_util.ads, sem_aux.ads:
4342 Move routine Is_VM_By_Copy_Actual from sem_aux to exp_util.
4343
43442011-08-03 Bob Duff <duff@adacore.com>
4345
4346 * sem_ch8.adb (Is_Primitive_Operator_In_Use): Always check In_Use on
4347 the Base_Type.
4348
43492011-08-03 Joel Brobecker <brobecker@adacore.com brobecker>
4350
4351 * g-sha256.ads, g-sha512.ads, g-sha1.ads, g-sha224.ads, g-sha384.ads,
4352 g-sehash.ads: Fix typo. Update header.
4353
43542011-08-03 Thomas Quinot <quinot@adacore.com>
4355
4356 * exp_ch6.adb (Expand_Actuals): Remove Ada_2005 guard on build-in-place
4357 expansion.
4358
43592011-08-03 Gary Dismukes <dismukes@adacore.com>
4360
4361 * sem_ch4.adb (Analyze_Overloaded_Selected_Component): Consider
4362 prefixes of private types along with records, since the selector may be
4363 a discriminant.
4364 * sem_res.adb (Resolve_Selected_Component): Consider prefixes of
4365 private types along with records, since the selector may be a
4366 discriminant.
4367
92e77027
AC
43682011-08-03 Emmanuel Briot <briot@adacore.com>
4369
b2f7ebc1 4370 * prj-pp.adb (Pretty_Print): Remove trailing blank line.
92e77027
AC
4371
43722011-08-03 Javier Miranda <miranda@adacore.com>
4373
4374 * sem_aux.adb (Is_VM_By_Copy_Actual): Fix wrong use of
4375 Tagged_Type_Expansion.
4376
43772011-08-03 Yannick Moy <moy@adacore.com>
4378
b2f7ebc1
GP
4379 * sem_res.adb (Resolve_Op_Concat_Arg): Do not issue a SPARK
4380 violation when the argument of concatenation is the name of a
4381 constant.
92e77027 4382
ab29a348
EB
43832011-08-03 Emmanuel Briot <briot@adacore.com>
4384
4385 * prj-proc.adb, prj-ext.adb, prj-ext.ads, prj-env.adb, prj-env.ads,
4386 prj-tree.adb, prj-tree.ads (Initialize_And_Copy, Copy): new subprograms
4387 (Process_Declarative_Items): new parameter Child_Env.
4388
9466892f
AC
43892011-08-03 Yannick Moy <moy@adacore.com>
4390
589ef536
GP
4391 * alfa.ads: Update format of ALFA section in ALI file in order to
4392 add a mapping from bodies to specs when both are present.
4393 (ALFA_Scope_Record): Add components for spec file/scope.
4394 * get_alfa.adb (Get_ALFA): Read the new file/scope for spec when
4395 present.
4396 * lib-xref-alfa.adb (Collect_ALFA): After all scopes have been
4397 collected, fill in the spec information when relevant.
4398 * put_alfa.adb (Put_ALFA): Write the new file/scope for spec when
9466892f
AC
4399 present.
4400
44012011-08-03 Eric Botcazou <ebotcazou@adacore.com>
4402
4403 * inline.adb (Add_Inlined_Subprogram): Do not consider the enclosing
4404 code unit to decide whether to add internally generated subprograms.
2c7f9cc0 4405
9466892f
AC
44062011-08-03 Javier Miranda <miranda@adacore.com>
4407
4408 * sem_aux.ads, sem_aux.adb (Is_VM_By_Copy_Actual): New subprogram.
589ef536
GP
4409 * exp_ch9.adb (Build_Simple_Entry_Call): Handle actuals that must
4410 be handled by copy in VM targets.
9466892f
AC
4411
44122011-08-03 Emmanuel Briot <briot@adacore.com>
4413
589ef536 4414 * make.adb, makeutl.adb, makeutl.ads (Make.Switches_Of): Share
9466892f
AC
4415 code with Makeutl.Get_Switches.
4416 * prj-tree.adb: Update comment.
4417
b5ea9143
AC
44182011-08-03 Thomas Quinot <quinot@adacore.com>
4419
4420 * sem_cat.adb (Validate_RCI_Subprogram_Declaration): Reject a remote
4421 subprogram with a limited formal that does not support external
4422 streaming.
4423
44242011-08-03 Yannick Moy <moy@adacore.com>
4425
4426 * get_alfa.adb (Get_ALFA): add missing Skip_Spaces at start of
4427 continuation line
4428 * lib-xref-alfa.adb (Add_ALFA_File): split removal of scopes that are
4429 not from current unit in two phases, because it is not possible to
4430 change the table while iterating over its content.
4431 * put_alfa.adb (Put_ALFA): reset current file/scope at each new entity
4432
44332011-08-03 Sergey Rybin <rybin@adacore.com>
4434
4435 * vms_data.ads: Add qualifier for gnatmetric --no-static-loop option
4436 * gnat_ugn.texi: Update description of complexity metrics (gnatmetric)
4437
668a19bc
ES
44382011-08-03 Ed Schonberg <schonberg@adacore.com>
4439
4440 * sem_res.adb (Resolve_Op_Concat_Arg): if the argument is an aggregate
4441 and the component type is composite, this is ambiguous for predefined
4442 concatenation, but if the node is not overloaded and the entity is a use
4443 -defined function its profile can be used to resolve that aggregate.
4444
170b2989
AC
44452011-08-03 Robert Dewar <dewar@adacore.com>
4446
4447 * exp_ch4.adb: Minor code cleanup.
4448
44492011-08-03 Thomas Quinot <quinot@adacore.com>
4450
4451 * exp_dist.adb: Do not generate distribution stubs if serious errors
4452 have been diagnosed.
4453
44542011-08-03 Ed Schonberg <schonberg@adacore.com>
4455
4456 * sem_ch4.adb (Try_Primitive_Operation): when checking the validity of
4457 the first formal of a primitive operation, go to the base type to
4458 handle properly an access to a derived type with constrained
4459 discriminants.
4460 * sem_type.adb (Disambiguate): an immediately visible operator hides a
4461 user-defined function that is only use-visible.
170b2989 4462
e917aec2
RD
44632011-08-03 Robert Dewar <dewar@adacore.com>
4464
4465 * sem_aggr.adb, sem_ch3.adb, lib.ads, gnatcmd.adb, prj-proc.adb,
4466 make.adb, lib-writ.adb, prj-part.adb, prj-part.ads, prj-ext.adb,
4467 fname-uf.adb, prj-ext.ads, prj.adb, prj.ads, sem_attr.adb, alfa.adb,
4468 prj-makr.adb, errout.adb, makeutl.adb, makeutl.ads, restrict.ads,
4469 sem_ch6.adb, g-pehage.adb, clean.adb, put_alfa.adb, lib-xref-alfa.adb,
4470 prj-nmsc.adb, prj-nmsc.ads, sem_ch8.adb, prj-pars.ads, exp_aggr.adb,
4471 prj-attr.ads, sem_ch13.adb, get_alfa.adb, prj-env.adb, prj-env.ads,
4472 alfa_test.adb, prj-tree.adb, prj-tree.ads, einfo.ads: Minor reformatting
4473
44742011-08-03 Robert Dewar <dewar@adacore.com>
4475
4476 * repinfo.adb (List_Mechanism): Add handling of
4477 Convention_Ada_Pass_By_XXX.
4478 * sem_mech.adb (Set_Mechanism): Ditto.
4479 * sem_prag.adb (Process_Convention): Add entries for
4480 Convention_Ada_Pass_By_XXX.
4481 * snames.adb-tmpl, snames.ads-tmpl: Ditto.
4482
49bfcf43
AC
44832011-08-03 Pascal Obry <obry@adacore.com>
4484
4485 * makeutl.adb: Minor reformatting.
4486
44872011-08-03 Vincent Celier <celier@adacore.com>
4488
4489 * fname-uf.adb
4490 (Get_File_Name) If the file cannot be found when there are no config
4491 pragmas file and May_Fail is True, return No_File instead of the file
4492 name, to be consistent.
4493
44942011-08-03 Pascal Obry <obry@adacore.com>
4495
4496 * adaint.c (__gnat_is_executable_file_attr): Avoid access
4497 to null pointer.
4498
44992011-08-03 Javier Miranda <miranda@adacore.com>
4500
4501 * sem_ch13.adb
4502 (Same_Representation): In VM targets the representation of arrays with
4503 aliased components differs from arrays with non-aliased components.
4504
34798441
EB
45052011-08-03 Emmanuel Briot <briot@adacore.com>
4506
4507 * prj-proc.adb, prj-attr.adb, prj-attr.ads (Get_Attribute_Index): do
4508 not systematically lower case attribute indexes that contain no "."
4509 Fix definition of several Naming attributes, which take
4510 a unit name as index and therefore should be case insensitive.
4511 Minor refactoring (reduce length of variable names).
4512
45132011-08-03 Emmanuel Briot <briot@adacore.com>
4514
4515 * makeutl.adb, makeutl.ads (Get_Switches): new subprogram.
4516
4437a530
EB
45172011-08-03 Emmanuel Briot <briot@adacore.com>
4518
4519 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, prj-part.adb,
4520 prj-part.ads, switch-m.adb, switch-m.ads, prj-makr.adb, clean.adb,
4521 prj-pars.adb, prj-pars.ads, prj-conf.adb, prj-conf.ads, prj-tree.adb,
4522 prj-tree.ads (Prj.Tree.Environment): new type.
4523
804fe3c4
EB
45242011-08-03 Emmanuel Briot <briot@adacore.com>
4525
4526 * prj-proc.adb, prj.ads, makeutl.adb, makeutl.ads, prj-conf.adb,
4527 prj-tree.adb, prj-tree.ads (Environment): new type.
4528
c565bc66
AC
45292011-08-03 Emmanuel Briot <briot@adacore.com>
4530
4531 * prj-tree.ads: Remove unused variable.
4532
45332011-08-03 Yannick Moy <moy@adacore.com>
4534
4535 * restrict.adb (Restriction_Msg): set "SPARK" all in upper case for
4536 issuing messages related to SPARK restriction violation.
4537
4ee646da
AC
45382011-08-03 Ed Schonberg <schonberg@adacore.com>
4539
4540 * sem_ch6.adb: guard against error nodes in return statements.
4541
45422011-08-03 Arnaud Charlet <charlet@adacore.com>
4543
4544 * errout.adb (Error_Msg_Internal): the main unit has not been read yet,
4545 a warning can only appear on a configuration file, so emit warning
4546 without further checks.
4547
45482011-08-03 Arnaud Charlet <charlet@adacore.com>
4549
4550 * s-interr.ads: add overriding keyword.
4551
45522011-08-03 Geert Bosch <bosch@adacore.com>
4553
4554 * exp_attr.adb: Fix minor typo.
4555
45562011-08-03 Ed Schonberg <schonberg@adacore.com>
4557
4558 * par-ch4.adb: improve error recovery.
4559
c0e538ad
AC
45602011-08-03 Emmanuel Briot <briot@adacore.com>
4561
4562 * prj-part.adb, prj-part.ads, prj-makr.adb, prj-pars.adb, prj-conf.adb,
4563 prj-env.adb (Prj.Part.Parse): change parameter Always_Errout_Finalize
4564 to Errout_Handling.
4565
45662011-08-03 Emmanuel Briot <briot@adacore.com>
4567
4568 * prj-dect.adb (Parse_Attribute_Declaration): make sure we can use
4569 "external" as an attribute name in aggregate projects.
4570
45712011-08-03 Jose Ruiz <ruiz@adacore.com>
4572
4573 * s-taprop-vxworks.adb: (Create_Task, Initialize): Ada 2012 pragma CPU
4574 uses CPU numbers starting 1, while VxWorks uses CPU numbers starting
4575 from 0, so we need to adjust.
4576
45772011-08-03 Emmanuel Briot <briot@adacore.com>
4578
4579 * prj-proc.adb, prj-ext.adb, prj-ext.ads, makeutl.adb, prj-tree.adb,
4580 prj-tree.ads, gnatcmd.adb, clean.adb (External_References): new type.
4581
c4d67e2d
AC
45822011-08-03 Yannick Moy <moy@adacore.com>
4583
4584 * sem_ch6.adb (New_Overloaded_Entity): only issue error for SPARK
4585 restriction on overloaded entity if the entity is not an operator.
4586
45872011-08-03 Yannick Moy <moy@adacore.com>
4588
4589 * sem_ch7.adb, sem_res.adb, sem_attr.adb, restrict.adb,
4590 restrict.ads: Rename remaining Check_Formal_Restriction* into
4591 Check_SPARK_Restriction*.
4592
45932011-08-03 Emmanuel Briot <briot@adacore.com>
4594
4595 * prj-proc.adb, prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb,
4596 prj-nmsc.ads, prj-err.adb (Project_Data): now discriminated on its
4597 qualifier.
4598 (Project_Empty): removed
4599 (Empty_Project): new parameter Qualifier
4600 This is used to have fields specific to aggregate projects, cleaner
4601 New field to store the list of aggregated projects.
4602 (Check_Aggregate_Project): removed
4603 (Process_Aggregated_Projects, Free): new subprograms.
4604
3f5a8fee
AC
46052011-08-03 Olivier Hainque <hainque@adacore.com>
4606
4607 * tracebak.c (STOP_FRAME ppc AIX): Stop at null return address as well.
4608
46092011-08-03 Ed Schonberg <schonberg@adacore.com>
4610
4611 * sem_ch8.adb (Analyze_Object_Renaming): if the renamed object is an
4612 explicit dereference of an unconstrained type, create a constrained
4613 subtype for it, as is done for function calls that return an
4614 unconstrained type.
4615
46162011-08-03 Thomas Quinot <quinot@adacore.com>
4617
4618 * g-pehage.adb (Finalize): Avoid possible double-free.
4619
46202011-08-03 Steve Baird <baird@adacore.com>
4621
4622 * exp_attr.adb (Expand_N_Attribute_Reference): Don't expand
4623 Elab_Spec/Body attrs in CodePeer_Mode.
4624
46252011-08-03 Javier Miranda <miranda@adacore.com>
4626
4627 * exp_aggr.adb (Flatten): Convert to positional form aggregates whose
4628 low bound is not known at compile time but they have no others choice.
4629 Done because in this case the bounds can be obtained directly from the
4630 aggregate.
4631
46322011-08-03 Ed Falis <falis@adacore.com>
4633
4634 * s-tasinf-vxworks.ads: Update comment to reflect 0 indexing of CPUs
4635 on VxWorks SMP. Remove unusable constant ANY_CPU.
4636
a96ca600
EB
46372011-08-03 Emmanuel Briot <briot@adacore.com>
4638
4639 * gnatcmd.adb, make.adb, prj-part.adb, prj-part.ads, prj-makr.adb,
4640 clean.adb, prj-nmsc.adb, prj-pars.adb, prj-conf.adb, prj-env.adb,
4641 prj-env.ads (Prj.Env.Initialize_Default_Project_Path,
4642 Prj.Env.Initialize_Empty): new subprograms
4643 (Get_Env, Find_Project): remove parameter Target_Name.
4644
3e582869
AC
46452011-08-03 Gary Dismukes <dismukes@adacore.com>
4646
4647 * sem_ch3.adb (Build_Derived_Record_Type): Test the Derive_Subps formal
4648 as a condition for the delayed call to Derived_Subprograms done for the
4649 case of the rewriting of a derived type that constrains the
4650 discriminants of its parent type.
4651 Avoids redundant subprogram derivations for private subtype derivations.
4652
46532011-08-03 Javier Miranda <miranda@adacore.com>
4654
4655 * exp_aggr.adb (Init_Hidden_Discriminants): New subprogram of
4656 Build_Record_Aggr_Code.
4657 (Build_Record_Aggr_Code): Add missing support to initialize hidden
4658 discriminants in extension aggregates.
4659
46602011-08-03 Emmanuel Briot <briot@adacore.com>
4661
4662 * prj-pp.adb (Print): also output project qualifiers, since in
4663 particular "aggregate" is mandatory in an aggregate project.
4664
46652011-08-03 Emmanuel Briot <briot@adacore.com>
4666
4667 * prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb, prj-env.adb:
4668 (Debug_Output): new function.
4669
56e94186
AC
46702011-08-03 Eric Botcazou <ebotcazou@adacore.com>
4671
4672 * gnat_ugn.texi: Document -Wstack-usage.
4673 * gcc-interface/misc.c (enumerate_modes): Add guard for ghost FP modes.
4674
46752011-08-03 Thomas Quinot <quinot@adacore.com>
4676
4677 * sem_prag.adb Issue an error (not a warning) when a C++ type does not
4678 have keyword LIMITED.
4679
46802011-08-03 Yannick Moy <moy@adacore.com>
4681
4682 * alfa.adb, alfa.ads, alfa_test.adb: New files.
4683 * ali.adb (Known_ALI_Lines): add 'C' lines (SCO) and 'F' lines (ALFA)
4684 (Scan_ALI): do not issue a fatal error if parsing known lines after Xref
4685 section (does not happen in compiler, only if code directly calls
4686 Scan_ALI).
4687 * get_alfa.adb, get_alfa.ads: New files.
4688 * lib-writ.adb, lib-writ.ads (Write_ALI): output ALFA information if
4689 needed.
4690 * lib-xref-alfa.adb: New file.
4691 * lib-xref.adb, lib-xref.ads
4692 (Xref_Entry): redefine information needed in cross-references for ALFA.
4693 Push ALFA treatments in separated local package.
4694 (Enclosing_Subpragram_Or_Package): treat specially subprogram
4695 identifiers. Return entity of package body instead of spec. Return
4696 Empty for a scope with no location.
4697 (Generate_Reference): adapt to new components for ALFA information.
4698 Remove the need for D references on definitions.
4699 (Is_Local_Reference): moved to ALFA local package
4700 (Output_References): extract subfunction as Extract_Source_Name
4701 (Output_Local_References): remove procedure, replaced by filtering of
4702 cross-references in package ALFA and printing in Put_ALFA.
4703 (Write_Entity_Name): remove procedure
4704 * lib.adb, lib.ads (Extract_Source_Name): extract here function to
4705 print exact name of entity as it appears in source file
4706 (Unit_Ref_Table): make type public for use in Lib.Xref.ALFA
4707 * put_alfa.adb, put_alfa.ads: New files.
4708 * xref_lib.adb (Search_Xref): protect read of cross-references against
4709 reading other sections of the ALI file, in gnatxref
4710 (Search): protect read of cross-references against reading other
4711 sections of the ALI file, in gnatfind.
4712 * gcc-interface/Make-lang.in: Update dependencies.
4713
47142011-08-03 Thomas Quinot <quinot@adacore.com>
4715
4716 * sem_ch3.adb: Minor reformatting.
4717
47182011-08-03 Jose Ruiz <ruiz@adacore.com>
4719
4720 * s-inmaop-vxworks.adb (Setup_Interrupt_Mask): Do nothing instead of
4721 raising an exception.
4722
47232011-08-03 Ed Schonberg <schonberg@adacore.com>
4724
4725 * sem_res.adb (Set_String_Literal_Subtype): if index type is an integer
4726 type, always use 1 as the lower bound or string, even if lower bound of
4727 context is not static, to handle properly null strings in a non-static
4728 context.
4729
47302011-08-03 Bob Duff <duff@adacore.com>
4731
4732 * sem_prag.adb (Resolve_Aggregate): An array aggregate with 'others' is
4733 always legal on the right-hand side of an assignment statement; there
4734 is always an applicable index constraint in this case. Therefore, the
4735 check for Pkind = N_Assignment_Statement is now unconditional -- it
4736 doesn't depend on whether Is_Constrained (Typ).
4737
4317e442
AC
47382011-08-03 Robert Dewar <dewar@adacore.com>
4739
4740 * exp_ch5.adb, sem_prag.adb, exp_ch4.adb: Minor reformatting.
4741
47422011-08-03 Ed Schonberg <schonberg@adacore.com>
4743
4744 * sem_ch3.adb (Build_Itype_Reference): do not create an itype reference
4745 for an itype created within a generic unit.
4746
47472011-08-03 Eric Botcazou <ebotcazou@adacore.com>
4748
4749 * gnat_ugn.texi (Switches for gcc): Make it clearer that -fno-inline
4750 suppresses all inlining.
4751
53f29d4f
AC
47522011-08-03 Robert Dewar <dewar@adacore.com>
4753
4754 * sem_ch3.adb, sem_res.adb, exp_ch13.adb, exp_disp.adb,
4755 exp_aggr.adb: Minor reformatting.
4756
47572011-08-03 Thomas Quinot <quinot@adacore.com>
4758
4759 * exp_ch5.adb (Expand_N_Assignment_Statement): Do not force inlining of
4760 tagged assignment when discriminant checks are suppressed. This is
4761 useless and extremely costly in terms of static stack usage.
4762
47632011-08-03 Bob Duff <duff@adacore.com>
4764
4765 * sem_prag.adb (Get_Base_Subprogram): Do not follow Alias for instances
4766 of generics, because this leads to the wrong entity in the wrong scope,
4767 causing (e.g.) pragma Export_Procedure to get an error if the entity is
4768 an instance.
4769 (Process_Interface_Name): Follow Alias for instances of generics, to
4770 correct for the above change.
4771
47722011-08-03 Ed Schonberg <schonberg@adacore.com>
4773
4774 * exp_ch4.adb (Expand_N_Selected_Component): If the discriminant value
4775 is an integer literal it is always safe to replace the reference. In
4776 addition, if the reference appears in the generated code for an object
4777 declaration it is necessary to copy because otherwise the reference
4778 might be to the uninitilized value of the discriminant of the object
4779 itself.
4780
47812011-08-03 Pascal Obry <obry@adacore.com>
4782
4783 * adaint.c (__gnat_is_executable_file_attr): Fix Win32 circuitry when no
4784 ACL used, in this case we want to check for ending .exe, not .exe
4785 anywhere in the path.
4786
47872011-08-03 Sergey Rybin <rybin@adacore.com>
4788
4789 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
4790 the tree structure (semantic decoration of references to record
4791 discriminants).
4792
c0b11850
AC
47932011-08-03 Gary Dismukes <dismukes@adacore.com>
4794
4795 * sem_aggr.adb (Analyze_Array_Aggregate): When checking the discrete
4796 choices of a named array aggregate, bail out when any choices are
4797 marked as Errors_Posted.
4798
47992011-08-03 Ed Schonberg <schonberg@adacore.com>
4800
4801 * exp_ch13.adb (Expand_N_Freeze_Entity): cleanup determination of scope
4802 in which entity is frozen, to handle properly loop variables in
4803 iterators.
4804
48052011-08-03 Ed Schonberg <schonberg@adacore.com>
4806
4807 * sem_res.adb (Set_String_Literal_Subtype): if the lower bound of the
4808 subtype is not static, compute the upper bound using attributes, to
4809 handle properly index types that are not integer types.
4810
48112011-08-03 Bob Duff <duff@adacore.com>
4812
4813 * gnat_rm.texi, gnat_ugn.texi: Fix some dangling URLs.
4814 Update copyright notice.
4815
48162011-08-03 Ed Schonberg <schonberg@adacore.com>
4817
4818 * sem_ch3.adb (Build_Discriminant_Constraints): Only use
4819 Original_Discriminant if within an instance.
4820 * sem_ch4.adb (Analyze_Selected_Component): Ditto.
4821
48222011-08-03 Thomas Quinot <quinot@adacore.com>
4823
4824 * einfo.ads: Minor reformatting.
4825
48262011-08-03 Ed Schonberg <schonberg@adacore.com>
4827
4828 * exp_disp.adb (Check_Premature_Freezing): diagnose the presence of a
4829 composite type with an unfrozen subcomponent, in the profile of a
4830 primitive operation.
4831
5c34e9cd
AC
48322011-08-03 Robert Dewar <dewar@adacore.com>
4833
4834 * sem_util.ads, exp_aggr.adb, exp_ch3.adb: Minor reformatting.
4835
48362011-08-03 Ed Schonberg <schonberg@adacore.com>
4837
4838 * sem_ch3.adb (Analyze_Object_Declaration): if a constant object of an
4839 unconstrained type with discriminants is initialized with an aggregate,
4840 use the constrained subtype of the aggregate as the type of the object,
4841 because it is immutable, and this allows the back-end to generate no
4842 code for the object declaration.
4843
abcd9db2
AC
48442011-08-03 Robert Dewar <dewar@adacore.com>
4845
4846 * exp_ch4.adb (Optimize_Length_Check): Fix bad handling of case where
4847 comparison operand is variable, and turns out to be zero or negative.
4848
48492011-08-03 Javier Miranda <miranda@adacore.com>
4850
4851 * exp_intr.adb
4852 (Expand_Dispatching_Constructor_Call): Disable expansion of
4853 code required for native targets. Done to avoid generating
4854 references to unavailable runtime entities in VM targets.
4855 * exp_ch3.adb
4856 (Expand_N_Object_Declaration): Add missing support to handle
4857 the explicit initialization of class-wide interface objects.
4858 Fix documentation.
4859
48602011-08-03 Matthew Heaney <heaney@adacore.com>
4861
4862 * a-cobove.adb (Merge): Move source onto target, instead of using Assign
4863
48642011-08-03 Matthew Heaney <heaney@adacore.com>
4865
4866 * a-cbdlli.adb (Splice): move source items from first to last
4867
48682011-08-03 Yannick Moy <moy@adacore.com>
4869
4870 * sem_util.ads: comment added.
4871
48722011-08-03 Javier Miranda <miranda@adacore.com>
4873
4874 * exp_aggr.adb
4875 (Expand_Record_Aggregate): In VM targets disable the expansion into
4876 assignments of aggregates whose type is not known at compile time.
4877
b474d6c3
ES
48782011-08-03 Ed Schonberg <schonberg@adacore.com>
4879
4880 * exp_ch9.adb (Build_Renamed_Formal_Declaration): common procedure for
4881 protected entries and task entries, to build the proper renaming
4882 declaration for entry formals, used in debugging.
4883 * exp_ch2.adb (Expand_Entry_Parameter): handle task and entry
4884 parameters in the same way.
4885
0580d807
AC
48862011-08-02 Robert Dewar <dewar@adacore.com>
4887
4888 * a-direct.adb, sinfo.ads, exp_ch9.adb, scng.adb, sem_util.adb,
4889 sem_util.ads, restrict.ads, par-prag.adb: Minor reformatting and/or
4890 code reorganization.
4891
48922011-08-02 Robert Dewar <dewar@adacore.com>
4893
4894 * debug.adb: Debug flag d.P to suppress length comparison optimization
4895 * exp_ch4.adb (Optimize_Length_Comparison): New routine to optimize
4896 comparison of Length by comparing First/Last instead.
4897
48982011-08-02 Matthew Heaney <heaney@adacore.com>
4899
4900 * a-cobove.ads: Code clean up.
4901
b191a125
AC
49022011-08-02 Vincent Celier <celier@adacore.com>
4903
4904 * adaint.c (file_names_case_sensitive_cache): New static int.
4905 (__gnat_get_file_names_case_sensitive): Cache the return value in
4906 file_names_case_sensitive_cache at the first invocation, to avoid
4907 multiple calls to getenv.
4908
49092011-08-02 Bob Duff <duff@adacore.com>
4910
4911 * sem_ch12.adb (Validate_Derived_Type_Instance): Implement AI05-0218-1.
4912
316a0661
AC
49132011-08-02 Yannick Moy <moy@adacore.com>
4914
4915 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_prag.adb, sem.ads,
4916 sem_util.adb, sem_util.ads, sem_res.adb, sem_ch2.adb, sem_ch4.adb,
4917 sem_ch6.adb, sem_ch11.adb: Add semantic flag In_Pre_Post_Expression to
4918 indicate that we are in a precondition or postcondition. This is used in
4919 Mark_Non_ALFA_Subprogram (renaming of Mark_Non_ALFA_Subprogram_Body) to
4920 decide whether to flag the spec or body of the current subprogram as
4921 not in ALFA.
4922
49232011-08-02 Fabien Chouteau <chouteau@adacore.com>
4924
4925 * impunit.adb: Add Ada.Execution_Time.Interrupts in the Ada2012 package
4926 list.
4927 * a-extiin.ads: New file.
4928
49292011-08-02 Bob Duff <duff@adacore.com>
4930
4931 * a-direct.adb (Rename): Implement AI05-0231-1. In particular, Rename
4932 now raises Name_Error instead of Use_Error in certain cases. The other
4933 parts of this AI were already implemented properly.
4934
f9adb9d4
AC
49352011-08-02 Vincent Celier <celier@adacore.com>
4936
4937 * link.c: Only import "auto-host.h" when building the gnattools.
4938
49392011-08-02 Yannick Moy <moy@adacore.com>
4940
4941 * sem_util.adb: Inter-unit inlining does not work for a subprogram
4942 which calls a local subprogram, so extract subprogram
4943 from Mark_Non_ALFA_Subprogram_Body.
4944
49452011-08-02 Javier Miranda <miranda@adacore.com>
4946
4947 * exp_ch9.adb
4948 (Extract_Dispatching_Call): If the type of the dispatching object is an
4949 access type then return an explicit dereference in the Object out-mode
4950 parameter.
4951
49522011-08-02 Gary Dismukes <dismukes@adacore.com>
4953
4954 * sem_ch3.adb (Analyze_Subtype_Declaration): Generate range
4955 compatibility checks for all indexes of an array subtype, not just the
4956 first. Reset Has_Dynamic_Range_Check on the subtype before each
4957 potential check to ensure that Insert_Range_Checks will not elide any
4958 of the dynamic checks.
4959
49602011-08-02 Yannick Moy <moy@adacore.com>
4961
4962 * par-prag.ad (Process_Restrictions_Or_Restriction_Warnings): recognize
4963 SPARK restriction at parsing time.
4964 * scng.adb (Scan): Generate a token Tok_SPARK_Hide for a SPARK HIDE
4965 directive only if the SPARK restriction is set for this unit.
4966
83f33150
YM
49672011-08-02 Yannick Moy <moy@adacore.com>
4968
4969 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb, sem_util.ads,
4970 sem_res.adb, sem_ch2.adb, sem_ch4.adb, sem_ch6.adb,
4971 sem_ch11.adb: Protect call to Current_Subprogram which might be costly
4972 when repeated. Rename Current_Subprogram_Is_Not_In_ALFA into
4973 Mark_Non_ALFA_Subprogram_Body.
4974 Split body of Mark_Non_ALFA_Subprogram_Body to get body small and
4975 inlined.
4976
7b98672f
YM
49772011-08-02 Yannick Moy <moy@adacore.com>
4978
4979 * sem_res.adb: Protect calls to Matching_Static_Array_Bounds which
4980 might be costly.
4981
052e0603
AC
49822011-08-02 Robert Dewar <dewar@adacore.com>
4983
4984 * exp_ch9.adb, exp_sel.adb, restrict.ads, exp_disp.adb, erroutc.ads,
4985 exp_ch3.adb: Minor reformatting.
4986
49872011-08-02 Emmanuel Briot <briot@adacore.com>
4988
4989 * adaint.c (__gnat_locate_exec_on_path): only returns executable
4990 files, not any regular file.
4991 (__gnat_locate_file_with_predicate): new subprogram.
4992
49932011-08-02 Yannick Moy <moy@adacore.com>
4994
4995 * sinfo.adb, sinfo.ads: Restrict the use of flags
4996 Has_Dynamic_Length_Check and Has_Dynamic_Range_Check to expression
4997 nodes, plus N_Subtype_Declaration for the 2nd one.
4998
4fbad0ba
AC
49992011-08-02 Sergey Rybin <rybin@adacore.com>
5000
5001 * gnat_rm.texi: Ramification of pragma Eliminate documentation
5002 - fix bugs in the description of Source_Trace;
5003 - get rid of UNIT_NAME;
5004
052e0603
AC
50052011-08-02 Javier Miranda <miranda@adacore.com>
5006
5007 * exp_ch9.adb
5008 (Build_Dispatching_Requeue): Adding support for VM targets
5009 since we cannot directly reference the Tag entity.
5010 * exp_sel.adb (Build_K): Adding support for VM targets.
5011 (Build_S_Assignment): Adding support for VM targets.
5012 * exp_disp.adb
5013 (Default_Prim_Op_Position): In VM targets do not restrict availability
5014 of predefined interface primitives to compiling in Ada 2005 mode.
5015 (Is_Predefined_Interface_Primitive): In VM targets this service is not
5016 restricted to compiling in Ada 2005 mode.
5017 (Make_VM_TSD): Generate code that declares and initializes the OSD
5018 record. Needed to support dispatching calls through synchronized
5019 interfaces.
5020 * exp_ch3.adb
5021 (Make_Predefined_Primitive_Specs): Enable generation of predefined
5022 primitives associated with synchronized interfaces.
5023 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
5024 primitives associated with synchronized interfaces.
5025
50262011-08-02 Yannick Moy <moy@adacore.com>
5027
5028 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
5029 statements hidden in SPARK if preceded by the HIDE directive
5030 (Parse_Exception_Handlers): mark each exception handler in a sequence of
5031 exception handlers as hidden in SPARK if preceded by the HIDE directive
5032 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
5033 if starting with the HIDE directive
5034 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
5035 starting with the HIDE directive; mark the declarations in a private
5036 part as hidden in SPARK if the private part starts with the HIDE
5037 directive
5038 * restrict.adb, restrict.ads
5039 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
5040 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
5041 argument node belongs to a part which is hidden in SPARK
5042 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
5043 parts in SPARK; protect the possibly costly call to
5044 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
5045 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
5046 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
5047 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
5048 Tok_SPARK_Hide.
5049 (Scan): recognize special comment starting with '#' and followed by
5050 SPARK keyword "hide" as a HIDE directive.
5051
50522011-08-02 Yannick Moy <moy@adacore.com>
5053
5054 * types.ads, erroutc.ads: Minor reformatting.
5055
50562011-08-02 Vincent Celier <celier@adacore.com>
5057
5058 * link.c: Add response file support for cross platforms.
5059
50602011-08-02 Ed Schonberg <schonberg@adacore.com>
5061
5062 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
5063 in an association, set parent field of copy before partial analysis.
5064 * sem_res.adb (Resolve_Slice): create reference to itype only when
5065 expansion is enabled.
5066
50672011-08-02 Yannick Moy <moy@adacore.com>
5068
5069 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
5070 for new flag denoting which subprogram bodies are in ALFA
5071 * restrict.adb, sem_ch7.adb: Update comment
5072 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
5073 sem_ch9.adb, sem_res.adb: Add calls to
5074 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
5075 * sem_ch6.adb (Analyze_Function_Return): add calls to
5076 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
5077 middle of the body, and extended return.
5078 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
5079 False when missing return.
5080 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
5081 to True for subprograms whose spec is in ALFA. Remove later on the flag
5082 on the entity used for a subprogram body when there exists a separate
5083 declaration.
5084 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
5085 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
5086 False, otherwise do nothing.
5087
50882011-08-02 Robert Dewar <dewar@adacore.com>
5089
5090 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
5091
50922011-08-02 Yannick Moy <moy@adacore.com>
5093
5094 * sem_ch4.ads: minor formatting.
5095
50962011-08-02 Yannick Moy <moy@adacore.com>
5097
5098 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
5099 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
5100 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
5101 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
5102 opt.ads: cleanup of SPARK mode
5103
51042011-08-02 Yannick Moy <moy@adacore.com>
5105
5106 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
5107 types.
5108 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
5109 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
5110 * sem_ch3.adb
5111 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
5112 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
5113 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
5114 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
5115 types.
5116 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
5117 non-static range.
5118 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
5119 functions whose return type is not in ALFA.
5120 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
5121 specifications.
5122 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
5123 parameter's type is not in ALFA.
5124 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
5125 types are in ALFA.
5126
51272011-08-02 Ed Schonberg <schonberg@adacore.com>
5128
5129 * sem_ch6 (Analyze_Expression_Function): treat the function as
5130 Inline_Always, and introduce a subprogram declaration for it when it is
5131 not a completion.
5132 * inline.adb (Add_Inlined_Body): recognize bodies that come from
5133 expression functions, so that the back-end can determine whether they
5134 can in fact be inlined.
5135 * sem_util.adb (Is_Expression_Function): predicate to determine whether
5136 a function body comes from an expression function.
5137
51382011-08-02 Gary Dismukes <dismukes@adacore.com>
5139
5140 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
5141 null exclusions to test Can_Never_Be_Null on the anonymous access types
5142 of the formals rather than testing the formals themselves. Exclude this
5143 check in cases where the Old_Formal is marked as a controlling formal,
5144 to avoid issuing spurious errors for bodies completing dispatching
5145 operations (due to the flag not getting set on controlling access
5146 formals in body specs).
5147 (Find_Corresponding_Spec): When checking full and subtype conformance of
5148 subprogram bodies in instances, pass Designated and E in that order, for
5149 consistency with the expected order of the formals (New_Id followed by
5150 Old_Id).
5151
51522011-08-02 Robert Dewar <dewar@adacore.com>
5153
5154 * sem_ch8.adb: Minor reformatting.
5155
51562011-08-02 Ed Schonberg <schonberg@adacore.com>
5157
5158 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
5159 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
5160 primitive operations of class-wide actuals.
5161
51622011-08-02 Javier Miranda <miranda@adacore.com>
5163
5164 * exp_atag.ads, exp_atag.adb
5165 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
5166 since its value is implicitly passed in argument Typ.
5167 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
5168 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
5169 Build_Common_Dispatching_Select_Statements.
5170
51712011-08-02 Robert Dewar <dewar@adacore.com>
5172
5173 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
5174 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
5175 Minor reformatting.
5176
51772011-08-02 Robert Dewar <dewar@adacore.com>
5178
5179 * sem_res.adb: Minor reformatting.
5180 * sem_prag.adb: Minor reformatting.
5181
51822011-08-02 Javier Miranda <miranda@adacore.com>
5183
5184 * exp_atag.adb, exp_atags.ads
5185 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
5186 by the tagged type Entity. Required to use this routine in the VM
5187 targets since we do not have available the Tag entity in the VM
5188 platforms.
5189 * exp_ch6.adb
5190 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
5191 Ada.Tags has not been previously loaded.
5192 * exp_ch7.adb
5193 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
5194 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
5195 * sem_aux.adb
5196 (Enclosing_Dynamic_Scope): Add missing support to handle the full
5197 view of enclosing scopes. Required to handle enclosing scopes that
5198 are synchronized types whose full view is a task type.
5199 * exp_disp.adb
5200 (Build_VM_TSDs): Minor code improvement to avoid generating and
5201 analyzing lists with empty nodes.
5202 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
5203 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
5204 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
5205 (Make_Disp_Timed_Select_Body): Add support for VM targets.
5206 (Make_Select_Specific_Data_Table): Add support for VM targets.
5207 (Make_VM_TSD): Generate code to initialize the SSD structure of
5208 the TSD.
5209
52102011-08-02 Yannick Moy <moy@adacore.com>
5211
5212 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
5213 cross-references section in ALI.
5214 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
5215 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
5216 Sub).
5217 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
5218 subprogram or package entity of a node
5219 (Is_Local_Reference_Type): new function returns True for references
5220 selected in local cross-references.
5221 (Lt): function extracted from Lt in Output_References
5222 (Write_Entity_Name): function extracted from Output_References
5223 (Generate_Definition): generate reference with type 'D' for definition
5224 of objects (object declaration and parameter specification), with
5225 appropriate locations and units, for use in local cross-references.
5226 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
5227 references of type 'I' for initialization in object definition.
5228 (Output_References): move part of function Lt and procedure
5229 Write_Entity_Name outside of the body. Ignore references of types 'D'
5230 and 'I' introduced for local cross-references.
5231 (Output_Local_References): new procedure to output the local
5232 cross-references sections.
5233 (Lref_Entity_Status): new array defining whether an entity is a local
5234 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
5235 with 'I' type when initialization expression is present.
5236 * get_scos.adb, get_scos.ads: Correct comments and typos
5237
52382011-08-02 Javier Miranda <miranda@adacore.com>
5239
5240 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
5241 the JVM target.
5242 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
5243 the JVM target.
5244 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
5245 TSD support.
5246
52472011-08-02 Vincent Celier <celier@adacore.com>
5248
5249 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
5250 (No_Space_Img): New function
5251 (Find_Excluded_Sources): When reading from a file, record the file name
5252 and the line number for each excluded source.
5253 (Mark_Excluded_Sources): When reporting an error, if the excluded
5254 sources were read from a file, include file name and line number in
5255 the error message.
5256
52572011-08-02 Ed Schonberg <schonberg@adacore.com>
5258
5259 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
5260
52612011-08-02 Robert Dewar <dewar@adacore.com>
5262
5263 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
5264
52652011-08-02 Javier Miranda <miranda@adacore.com>
5266
5267 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
5268 generation of TSDs to the DOTNET compiler.
5269 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
5270 generation of TSDs to the DOTNET compiler.
5271
52722011-08-02 Javier Miranda <miranda@adacore.com>
5273
5274 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
5275 record of all the tagged types declared inside library level package
5276 declarations, library level package bodies or library level subprograms.
5277 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
5278 associated with a given tagged type.
5279 (Build_VM_TSDs): New subprogram.
5280 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
5281 compilation units that are subprograms.
5282 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
5283 compilation units that are package bodies.
5284 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
5285 units that are a package declaration or a package instantiation.
5286 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
5287 reorganization to improve the error generated by the frontend when the
5288 function Ada.Tags.Secondary_Tag is not available.
5289 * rtsfind.ads (RE_Register_TSD): New runtime entity.
5290 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
5291
52922011-08-02 Javier Miranda <miranda@adacore.com>
5293
5294 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
5295
52962011-08-02 Robert Dewar <dewar@adacore.com>
5297
5298 * s-imenne.ads: Minor reformatting.
5299
53002011-08-02 Robert Dewar <dewar@adacore.com>
5301
5302 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
5303 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
5304 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
5305
53062011-08-02 Robert Dewar <dewar@adacore.com>
5307
5308 * einfo.ads (Materialize_Entity): Document this is only for renamings
5309 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
5310 required debug information in the case where we transform the object
5311 declaration into a renaming declaration.
5312 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
5313 object
5314 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
5315 Materialize_Entity.
5316
53172011-08-02 Robert Dewar <dewar@adacore.com>
5318
5319 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
5320 Suppress_Init_Procs.
5321 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
5322 Suppress_Initialization/Initialization_Suppressed.
5323 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
5324 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
5325 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
5326 * sem_prag.adb: New processing for pragma Suppress_Initialization.
5327
53282011-08-02 Robert Dewar <dewar@adacore.com>
5329
5330 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
5331 Minor reformatting.
5332
53332011-08-02 Ed Schonberg <schonberg@adacore.com>
5334
5335 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
5336 only have inheritable classwide pre/postconditions.
5337
53382011-08-02 Javier Miranda <miranda@adacore.com>
5339
5340 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
5341 * rtsfind.ads (RE_Check_TSD): New runtime entity.
5342 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
5343 checks if the external tag of a type is the same as the external tag
5344 of some other declaration.
5345
53462011-08-02 Thomas Quinot <quinot@adacore.com>
5347
5348 * s-taskin.ads: Minor reformatting.
5349
53502011-08-02 Emmanuel Briot <briot@adacore.com>
5351
5352 * g-comlin.adb (Display_Help): swap the order in which it prints the
5353 short help and the general usage.
5354
53552011-08-02 Ed Schonberg <schonberg@adacore.com>
5356
5357 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
5358 the aspect declarations and attach them to the generic copy for
5359 subsequent analysis.
5360 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
5361 declarations of the generic tree to the new subprogram declarations.
5362 * sem_attr.adb (Check_Precondition_Postcondition): recognize
5363 conditions that apply to a subprogram instance.
5364
53652011-08-02 Robert Dewar <dewar@adacore.com>
5366
5367 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
5368
53692011-08-02 Ed Schonberg <schonberg@adacore.com>
5370
5371 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
5372 private type with a tagged full view is not derived in the immediate
5373 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
5374
53752011-08-02 Robert Dewar <dewar@adacore.com>
5376
5377 * exp_ch4.adb: Minor reformatting.
5378
53792011-08-02 Ed Schonberg <schonberg@adacore.com>
5380
5381 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
5382 Ada2012 iterator, the loop will be rewritten during expansion into a
5383 while loop with a cursor and an element declaration. Do not analyze the
5384 body in this case, because if the container is for indefinite types the
5385 actual subtype of the elements will only be determined when the cursor
5386 declaration is analyzed.
5387
53882011-08-02 Arnaud Charlet <charlet@adacore.com>
5389
5390 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
5391 size/alignment related attributes in CodePeer_Mode.
5392
53932011-08-02 Gary Dismukes <dismukes@adacore.com>
5394
5395 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
5396 Prepend_Element, since this can result in the operation getting the
5397 wrong slot in the full type's dispatch table if the full type has
5398 inherited operations. The incomplete type's operation will get added
5399 to the proper position in the full type's primitives
5400 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
5401 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
5402 dispatching operations, since there are cases where nonprimitive
5403 subprograms can get added to the list of incomplete dependents (such
5404 as subprograms in nested packages).
5405 * sem_ch6.adb (Process_Formals): First, remove test for being in a
5406 private part when determining whether to add a primitive with a
5407 parameter of a tagged incomplete type to the Private_Dependents list.
5408 Such primitives can also occur in the visible part, and should not have
5409 been excluded from being private dependents.
5410 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
5411 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
5412 list of a Taft-amendment incomplete type is a primitive before issuing
5413 an error that the full type must appear in the same unit. There are
5414 cases where nonprimitives can be in the list (such as subprograms in
5415 nested packages).
5416 * sem_disp.adb (Derives_From): Use correct condition for checking that
5417 a formal's type is derived from the type of the corresponding formal in
5418 the parent subprogram (the condition was completely wrong). Add
5419 checking that was missing for controlling result types being derived
5420 from the result type of the parent operation.
5421
54222011-08-02 Yannick Moy <moy@adacore.com>
5423
5424 * errout.adb (First_Node): minor renaming
5425 * restrict.adb (Check_Formal_Restriction): put restriction warning on
5426 first node.
5427
54282011-08-02 Yannick Moy <moy@adacore.com>
5429
5430 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
5431 before accessing operands.
5432 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
5433 decide whether an initialization expression respects SPARK rules, as
5434 the plain node is the expanded one. This allows for more valid warnings
5435 to be issued.
5436 * gnat_rm.texi: Minor update.
5437
54382011-08-02 Arnaud Charlet <charlet@adacore.com>
5439
5440 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
5441 previous change.
5442
54432011-08-02 Robert Dewar <dewar@adacore.com>
5444
5445 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
5446
54472011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
5448
5449 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
5450 loop statements and the element renaming declaration with a block when
5451 the element type is controlled.
5452
54532011-08-02 Yannick Moy <moy@adacore.com>
5454
5455 * sinfo.ads: Minor formatting.
5456
54572011-08-02 Ed Schonberg <schonberg@adacore.com>
5458
5459 * sem_aggr.adb (Add_Association): if the association has a box and no
5460 expression, use the Sloc of the aggregate itself for the new
5461 association.
5462 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
5463 the Original_Node.
5464
54652011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
5466
5467 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
5468 When a container is provided via a function call, generate a renaming
5469 of the function result. This avoids the creation of a transient scope
5470 and the premature finalization of the container.
5471 * exp_ch7.adb (Is_Container_Cursor): Removed.
5472 (Wrap_Transient_Declaration): Remove the supression of the finalization
5473 of the list controller when the declaration denotes a container cursor,
5474 it is not needed.
5475
54762011-08-02 Yannick Moy <moy@adacore.com>
5477
5478 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
5479 node is from source, instead of the original node being from source.
5480 * sem_aggr.adb
5481 (Resolve_Array_Aggregate): refine the check for a static expression, to
5482 recognize also static ranges
5483 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
5484 Array_Type_Declaration): postpone the test for the type being a subtype
5485 mark after the type has been resolved, so that component-selection and
5486 expanded-name are discriminated.
5487 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
5488 to distinguish the case of an iteration scheme, so that an error is
5489 issed on a non-static range in SPARK except in an iteration scheme.
5490 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
5491 In_Iter_Schm = True.
5492 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
5493 user-defined operators so that they are allowed in renaming
5494 * sem_ch8.adb
5495 (Find_Selected_Component): refine the check for prefixing of operators
5496 so that they are allowed in renaming. Move the checks for restrictions
5497 on selector name after analysis discriminated between
5498 component-selection and expanded-name.
5499 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
5500 concatenation argument of string type if it is static.
5501 * sem_util.adb, sem_util.ads
5502 (Check_Later_Vs_Basic_Declarations): add a new function
5503 Is_Later_Declarative_Item to decice which declarations are allowed as
5504 later items, in the two different modes Ada 83 and SPARK. In the SPARK
5505 mode, add that renamings are considered as later items.
5506 (Enclosing_Package): new function to return the enclosing package
5507 (Enter_Name): correct the rule for homonyms in SPARK
5508 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
5509 from source (result of expansion) to avoid issuing wrong warnings.
5510
55112011-08-02 Ed Schonberg <schonberg@adacore.com>
5512
5513 * errout.adb: On anything but an expression First_Node returns its
5514 argument.
5515
55162011-08-02 Pascal Obry <obry@adacore.com>
5517
5518 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
5519
55202011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
5521
5522 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
5523 Set the associated loop as the related expression of internally
5524 generated cursors.
5525 * exp_ch7.adb (Is_Container_Cursor): New routine.
5526 (Wrap_Transient_Declaration): Supress the finalization of the list
5527 controller when the declaration denotes a container cursor.
5528
55292011-08-02 Yannick Moy <moy@adacore.com>
5530
5531 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
5532 command line now.
5533 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
5534 expression is a simple expression. This check cannot be performed in
5535 the semantics, so just drop it.
5536 (P_Index_Or_Discriminant_Constraint): move check that the index or
5537 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
5538 semantics. Other cases were previously checked in the semantics.
5539 * par-ch4.adb (P_Name): move checks that a selector name is not
5540 character literal or an operator symbol to Find_Selected_Component in
5541 the semantics
5542 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
5543 declarations are not placed after later declarations in a separate
5544 procedure in Sem_Util (possibly not the best choice?), to be used both
5545 during parsing, for Ada 83 mode, and during semantic analysis, for
5546 SPARK mode.
5547 * par-endh.adb (Check_End): move check that end label is not missing
5548 to Process_End_Label in the semantics
5549 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
5550 the special case for SPARK restriction
5551 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
5552 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
5553 parameter Force to issue the error message even on internal node (used
5554 for generated end label). Call Check_Restriction to check when an error
5555 must be issued. In SPARK mode, issue an error message even if the
5556 restriction is not set.
5557 (Check_Restriction): new procedure with an additional out parameter to
5558 inform the caller that a message has been issued
5559 * sem_aggr.adb: Minor modification of message
5560 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
5561 instead of issuing an error message directly
5562 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
5563 declarations are not placed after later declarations, by calling
5564 Check_Later_Vs_Basic_Declarations
5565 (Analyze_Subtype_Declaration): move here the check that an index or
5566 discriminant constraint must be a subtype mark. Change the check that
5567 a subtype of String must start at one so that it works on subtype marks.
5568 * sem_ch4.adb (Analyze_Call): move here the check that a named
5569 association cannot follow a positional one in a call
5570 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
5571 instead of issuing an error message directly
5572 * sem_ch8.adb (Find_Selected_Component): move here the check that a
5573 selector name is not a character literal or an operator symbol. Move
5574 here the check that the prefix of an expanded name cannot be a
5575 subprogram or a loop statement.
5576 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
5577 procedure called from parsing and semantics to check that basic
5578 declarations are not placed after later declarations
5579 (Process_End_Label): move here the check that end label is not missing
5580
55812011-08-02 Arnaud Charlet <charlet@adacore.com>
5582
5583 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
5584 representation clause in codepeer mode, since it confuses CodePeer and
5585 does not bring useful info.
5586
55872011-08-02 Ed Falis <falis@adacore.com>
5588
5589 * init.c: initialize fp hw on MILS.
5590
55912011-08-02 Ed Schonberg <schonberg@adacore.com>
5592
5593 * errout.adb (First_Node): for bodies, return the node itself (small
5594 optimization). For other nodes, do not check source_unit if the node
5595 comes from Standard.
5596
55972011-08-02 Robert Dewar <dewar@adacore.com>
5598
5599 * exp_ch3.adb: Minor comment additions.
5600 * sem_ch13.adb: Minor reformatting.
5601
56022011-08-02 Pascal Obry <obry@adacore.com>
5603
5604 * make.adb, makeutl.adb: Removes some superfluous directory separator.
5605
56062011-08-02 Robert Dewar <dewar@adacore.com>
5607
5608 * sem_attr.adb: Minor reformatting.
5609
56102011-08-02 Robert Dewar <dewar@adacore.com>
5611
5612 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
5613 (Has_Default_Component_Value): Removed
5614 * einfo.ads Comment updates
5615 (Has_Default_Aspect): Replaces Has_Default_Value
5616 (Has_Default_Component_Value): Removed
5617 * exp_ch13.adb
5618 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
5619 * exp_ch3.adb
5620 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
5621 (Get_Simple_Init_Val): Handle Default_Value aspect
5622 (Needs_Simple_Initialization): Handle Default_Value aspect
5623 * exp_ch3.ads: Needs_Simple_Initialization
5624 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
5625 * par-prag.adb (Pragma_Default[_Component]Value) Removed
5626 * sem_ch13.adb
5627 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
5628 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
5629 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
5630
56312011-08-02 Ed Schonberg <schonberg@adacore.com>
5632
5633 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
5634 package containing iteration primitives.
5635 exp_ch5.adb (Expand_Iterator_Loop): ditto.
5636
56372011-08-02 Ed Schonberg <schonberg@adacore.com>
5638
5639 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
5640 "of", pre-analyze expression in case it is a function call with
5641 finalization actions that must be placed ahead of the loop.
5642 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
5643 on an Ada2012 iterator, insert them ahead of the rewritten loop.
5644
56452011-08-02 Geert Bosch <bosch@adacore.com>
5646
5647 * cstand.adb (Create_Float_Types): Only consider C's long double for
5648 Long_Long_Float, in addition to double.
5649
56502011-08-02 Robert Dewar <dewar@adacore.com>
5651
5652 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
5653 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
5654 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
5655 Minor reformatting.
5656
56572011-08-02 Ed Schonberg <schonberg@adacore.com>
5658
5659 * sem_attr.adb: handle properly 'Result when it is a prefix of an
5660 indexed component.
5661
56622011-08-02 Javier Miranda <miranda@adacore.com>
5663
5664 * einfo.ads, einfo.adb
5665 (Original_Access_Type): Move this attribute to Node26 since there was
5666 an undocumented use of Node21 in E_Access_Subprogram_Type entities
5667 which causes conflicts and breaks the generation of the .NET compiler.
5668 (Interface_Name): Add missing documentation on JGNAT only uses of
5669 this attribute.
5670
56712011-08-02 Geert Bosch <bosch@adacore.com>
5672
5673 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
5674 (Find_Back_End_Float_Type): Likewise
5675 (Create_Back_End_Float_Types): Likewise
5676 (Create_Float_Types): Likewise
5677 (Register_Float_Type): Likewise
5678 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
5679 Nlist and split out type selection in new local Find_Base_Type function.
5680 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
5681 Nlist
5682 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
5683
56842011-08-02 Robert Dewar <dewar@adacore.com>
5685
5686 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
5687 alpha order).
5688 * opt.ads: Minor comment change.
5689 * sem_ch12.adb: Minor code reorganization.
5690
56912011-08-02 Gary Dismukes <dismukes@adacore.com>
5692
5693 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
5694 subtype's list of rep items to the list on the full subtype in the case
5695 where the lists are the same.
5696
56972011-08-02 Geert Bosch <bosch@adacore.com>
5698
5699 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
5700 using the one from System.Strings, which also deallocates all strings.
5701
57022011-08-02 Geert Bosch <bosch@adacore.com>
5703
5704 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
5705 function.
5706 * gcc-interface/Make-lang.in: Update dependencies.
5707
57082011-08-02 Olivier Hainque <hainque@adacore.com>
5709
5710 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
5711 end_locus.
5712
57132011-08-02 Javier Miranda <miranda@adacore.com>
5714
5715 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
5716 associated with anonymous access to subprograms.
5717
57182011-08-02 Geert Bosch <bosch@adacore.com>
5719
5720 * opt.ads
5721 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
5722 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
5723 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
5724 (Add_Symbol_Definition): Move to switch-c.adb
5725 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
5726 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
5727 (Add_Symbol_Definition): Move to switch-c.adb.
5728 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
5729 * sem_warn.adb
5730 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
5731 Move to warnsw.adb.
5732 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
5733 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
5734 Move to warnsw.adb.
5735 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
5736 (Add_Symbol_Definition): Moved from Prepcomp.
5737 * switch-c.ads: Update copyright notice. Use String_List instead of
5738 Argument_List, removing dependency on System.OS_Lib.
5739
57402011-08-02 Yannick Moy <moy@adacore.com>
5741
5742 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
5743 mode on initialization expression which does not respect SPARK
5744 restrictions.
5745 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
5746 if the tree referenced by its argument represents an initialization
5747 expression in SPARK, suitable for initializing an object in an object
5748 declaration.
5749
57502011-08-02 Javier Miranda <miranda@adacore.com>
5751
5752 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
5753 internally generated access to subprogram with its associated protected
5754 subprogram type.
5755 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
5756
57572011-08-02 Geert Bosch <bosch@adacore.com>
5758
5759 * cstand.adb (Register_Float_Type): Print information about type to
5760 register, if the Debug_Flag_Dot_B is set.
5761 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
5762 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
5763 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
5764 with a requested precision of more than Max_Digits digits and no more
5765 than Max_Base_Digits digits, if a range specification is present and the
5766 Predefined_Float_Types list has a suitable type to derive from.
5767 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
5768 case of type completion with pragma Import
5769 * sem_prag.adb
5770 (Process_Import_Predefined_Type): Processing to complete a type
5771 with pragma Import. Currently supports floating point types only.
5772 (Set_Convention_From_Pragma): Do nothing without underlying type.
5773 (Process_Convention): Guard against absence of underlying type,
5774 which may happen when importing incomplete types.
5775 (Process_Import_Or_Interface): Handle case of importing predefined
5776 types. Tweak error message.
5777
57782011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5779
5780 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
5781 functions to previous change. Reorganize code slightly.
5782
57832011-08-02 Geert Bosch <bosch@adacore.com>
5784
5785 * back_end.ads (Register_Type_Proc): New call back procedure type for
5786 allowing the back end to provide information about available types.
5787 (Register_Back_End_Types): New procedure to register back end types.
5788 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
5789 available types.
5790 * cstand.adb (Back_End_Float_Types): New list for floating point types
5791 supported by the back end.
5792 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
5793 (Copy_Float_Type): New procedure to make new copies of predefined types.
5794 (Register_Float_Type): New call back procedure to populate the BEFT list
5795 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
5796 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
5797 (Create_Float_Types): New procedure to create entities for floating
5798 point types predefined in Standard, and put these and any remaining
5799 BEFTs on the Predefined_Float_Types list.
5800 * stand.ads (Predefined_Float_Types): New list for predefined floating
5801 point types that do not have declarations in package Standard.
5802
58032011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5804
5805 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
5806 entity node for the unit containing the parameter.
5807 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
5808 (Add_Inlined_Subprogram): Likewise.
5809 * gcc-interface/Make-lang.in: Update dependencies.
5810
58112011-08-02 Thomas Quinot <quinot@adacore.com>
5812
5813 * s-stusta.adb (Print): Make sure Pos is always initialized to a
5814 suitable value.
5815
58162011-08-02 Geert Bosch <bosch@adacore.com>
5817
5818 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
5819
58202011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5821
5822 * sem_type.adb (Covers): Move trivial case to the top and reuse the
5823 computed value of Base_Type.
5824
58252011-08-02 Yannick Moy <moy@adacore.com>
5826
5827 * restrict.adb (Check_Restriction): issue an error for any use of
5828 class-wide, even if the No_Dispatch restriction is not set.
5829 * sem_aggr.adb: Correct typos in comments and messages in formal mode
5830 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
5831 when completing a private extension, the type named in the private part
5832 is not the same as that named in the visible part.
5833 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
5834 of an inherited primitive operations of a tagged type or type extension
5835 that returns the tagged type.
5836 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
5837 function which returns True for an implicit operation inherited by the
5838 derived type declaration for the argument type.
5839 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
5840 order.
5841
58422011-08-02 Ed Schonberg <schonberg@adacore.com>
5843
5844 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
5845 Process_Bounds, to perform analysis with expansion of a range or an
5846 expression that is the iteration scheme for a loop.
5847 (Analyze_Iterator_Specification): If domain of iteration is given by a
5848 function call with a controlled result, as is the case if call returns
5849 a predefined container, ensure that finalization actions are properly
5850 generated.
5851 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
5852
58532011-08-02 Javier Miranda <miranda@adacore.com>
5854
5855 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
5856 * gcc-interface/Make-lang.in: Update dependencies.
5857
58582011-08-02 Javier Miranda <miranda@adacore.com>
5859
5860 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
5861 determine if the analysis is performed using N or Original_Node (N).
5862 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
5863 functionality of routine Is_Variable avoids code duplication.
5864 * checks.adb (Determine_Range): Handle temporaries generated by
5865 Remove_Side_Effects.
5866
58672011-08-02 Javier Miranda <miranda@adacore.com>
5868
5869 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
5870 expansion of the condition. Required since the previous analysis was
5871 done with expansion disabled (see Resolve_Quantified_Expression) and
5872 hence checks were not inserted and record comparisons have not been
5873 expanded.
5874
58752011-08-02 Ed Falis <falis@adacore.com>
5876
5877 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
5878 Update header.
5879
58802011-08-02 Bob Duff <duff@adacore.com>
5881
5882 * opt.ads: Minor comment fix.
5883
58842011-08-02 Bob Duff <duff@adacore.com>
5885
5886 * sem_ch12.adb (Analyze_Package_Instantiation,
5887 Analyze_Subprogram_Instantiation): Turn off style checking while
5888 analyzing an instance. Whatever style checks that apply to the generic
5889 unit should apply, so it makes no sense to apply them in an instance.
5890 This was causing trouble when compiling an instance of a runtime
5891 unit that violates the -gnatyO switch.
5892 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
5893 one of the two case statements, causing spurious errors.
5894
58952011-08-02 Robert Dewar <dewar@adacore.com>
5896
5897 * uname.adb: Minor reformatting.
5898 * gnatcmd.adb: Minor reformatting.
5899 * exp_attr.adb: Minor reformatting.
5900
59012011-08-02 Ed Schonberg <schonberg@adacore.com>
5902
5903 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
5904 No_Dispatching_Calls, do not look for the Assign primitive, because
5905 predefined primitives are not created in this case.
5906
59072011-08-02 Bob Duff <duff@adacore.com>
5908
5909 * stylesw.ads: Minor comment fixes.
5910
59112011-08-02 Robert Dewar <dewar@adacore.com>
5912
5913 * freeze.adb (Add_To_Result): New procedure.
5914
59152011-08-02 Jose Ruiz <ruiz@adacore.com>
5916
5917 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
5918 time, if the specific run-time routines for handling streams of strings
5919 are not available, use the default mechanism.
5920
59212011-08-02 Arnaud Charlet <charlet@adacore.com>
5922
5923 * s-regpat.ads: Fix typo.
5924
59252011-08-02 Vincent Celier <celier@adacore.com>
5926
5927 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
5928 not null, call it to create the in memory config project file without
5929 parsing an existing default config project file.
5930
59312011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5932
5933 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
5934
59352011-08-02 Ed Schonberg <schonberg@adacore.com>
5936
5937 * sem_elim.adb: an abstract subprogram does not need an eliminate
5938 pragma for its descendant to be eliminable.
5939
59402011-08-02 Ed Falis <falis@adacore.com>
5941
5942 * init.c: revert to handling before previous checkin for VxWorks
5943 * s-intman-vxworks.adb: delete unnecessary declarations related to
5944 using Ada interrupt facilities for handling signals.
5945 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
5946 * s-intman-vxworks.ads: Import __gnat_install_handler as
5947 Initialize_Interrupts.
5948 * s-taprop-vxworks.adb: Delete Signal_Mask.
5949 (Abort_Handler): change construction of mask to unblock exception
5950 signals.
5951
59522011-08-02 Jerome Guitton <guitton@adacore.com>
5953
5954 * a-except-2005.adb (Raise_From_Signal_Handler): Call
5955 Debug_Raise_Exception before propagation starts.
5956
59572011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5958
5959 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
5960 to Restriction_Check_Required.
5961 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
5962 * sem_res.adb (Resolve_Call): Likewise.
5963 * sem_attr.adb (Check_Stream_Attribute): Likewise.
5964
59652011-08-02 Bob Duff <duff@adacore.com>
5966
5967 * stylesw.ads: Update comment.
5968 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
5969 * errout.ads: Remove obsolete comment.
5970
59712011-08-02 Javier Miranda <miranda@adacore.com>
5972
5973 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
5974 (Set_Is_Safe_To_Reevaluate): new procedure.
5975 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
5976 assignment is allowed on safe-to-reevaluate variables.
5977 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
5978 temporary created to remove side effects in expressions that use
5979 the secondary stack as safe-to-reevaluate.
5980 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
5981 variables that are not true constants.
5982
59832011-08-02 Robert Dewar <dewar@adacore.com>
5984
5985 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
5986 sem_res.adb, sem_ch6.adb: Minor reformatting.
5987
59882011-08-02 Jerome Guitton <guitton@adacore.com>
5989
5990 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
5991
59922011-08-02 Ed Schonberg <schonberg@adacore.com>
5993
5994 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
5995 not set Overridden_Operation if subprogram is an initialization
5996 procedure.
5997
59982011-08-02 Yannick Moy <moy@adacore.com>
5999
6000 * par-ch6.adb: Correct obsolete name in comments
6001 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
6002 which takes two message arguments (existing function takes one), with
6003 second message used for continuation.
6004 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
6005 block statements that originate from a source block statement, not
6006 generated block statements
6007 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
6008 symmetry with procedure case
6009 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
6010 function to issue an error in formal mode if a package specification
6011 contains more than one tagged type or type extension.
6012 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
6013 parameters matching formals of tagged types are objects (or ancestor
6014 type conversions of objects), not general expressions. Issue an error
6015 on view conversions that are not involving ancestor conversion of an
6016 extended type.
6017 (Resolve_Type_Conversion): in formal mode, issue an error on the
6018 operand of an ancestor type conversion which is not an object
6019 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
6020 procedure so that it works also for actuals of function calls
6021 (Is_Actual_Tagged_Parameter): new function which determines if its
6022 argument is an actual parameter of a formal of tagged type in a
6023 subprogram call
6024 (Is_SPARK_Object_Reference): new function which determines if the tree
6025 referenced by its argument represents an object in SPARK
6026
60272011-08-02 Robert Dewar <dewar@adacore.com>
6028
6029 * sem_ch3.adb: Minor reformatting
6030 Minor comment addition
6031 Minor error msg text change
6032
60332011-08-02 Javier Miranda <miranda@adacore.com>
6034
6035 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
6036 function. Used to be more precise when we generate a variable plus one
6037 assignment to remove side effects in the evaluation of the Bound
6038 expressions.
6039 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
6040 of the bound expression to force its re-analysis and thus expand the
6041 associated transient scope (if required). Code cleanup replacing the
6042 previous code that declared the constant entity by an invocation to
6043 routine Force_Evaluation which centralizes this work in the frontend.
6044
60452011-08-02 Robert Dewar <dewar@adacore.com>
6046
6047 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
6048 (Base_Type): Now uses improved Is_Base_Type function
6049 * einfo.ads (Base_Type): Inline this function
6050
60512011-08-02 Robert Dewar <dewar@adacore.com>
6052
6053 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
6054 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
6055
60562011-08-02 Arnaud Charlet <charlet@adacore.com>
6057
6058 * gcc-interface/Make-lang.in: Update dependencies.
6059 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
6060 targets.
6061
60622011-08-02 Yannick Moy <moy@adacore.com>
6063
6064 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
6065 non-simple expression used in delta constraint
6066 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
6067 index constraint which is not a subtype mark
6068 * par.adb: With and use Restrict
6069 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
6070 mode on component type which is not a subtype mark and default
6071 expression on component
6072 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
6073 of string which does not have a lower index bound equal to 1
6074 (Array_Type_Declaration): issue an error in formal mode on index or
6075 component type which is not a subtype mark, and on aliased keyword on
6076 component
6077 (Derived_Type_Declaration): issue an error in formal mode on interface,
6078 limited or abstract type
6079 (Record_Type_Declaration): issue an error in formal mode on interface
6080 (Record_Type_Definition): issue an error in formal mode on tagged types
6081 and type extensions not declared in the specification of a library unit
6082 package; on null non-tagged record; on variant part
6083
60842011-08-02 Vincent Celier <celier@adacore.com>
6085
6086 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
6087 not declared for qualified library project when Library_Name is not
6088 declared, but Library_Dir is.
6089
60902011-08-02 Robert Dewar <dewar@adacore.com>
6091
6092 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
6093 pragmas (affects aspects [Component_]Default_Value
6094 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
6095 component type for the resolution
6096
60972011-08-02 Eric Botcazou <ebotcazou@adacore.com>
6098
6099 * einfo.adb (Base_Type): Tune implementation for speed.
6100
61012011-08-02 Robert Dewar <dewar@adacore.com>
6102
6103 * freeze.adb: Minor reformatting.
6104
61052011-08-02 Thomas Quinot <quinot@adacore.com>
6106
6107 * scos.ads: Update comments.
6108
61092011-08-02 Ed Schonberg <schonberg@adacore.com>
6110
6111 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
6112 base type, because the parent may be a subtype of a private type whose
6113 convention is established in a private part.
6114
61152011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
6116
6117 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
6118 statement in a block when the expansion of the return expression has
6119 created a finalization chain.
6120 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
6121 with the parent node.
6122 Add N_Extended_Return_Statement to handle the case where a transient
6123 object declaration appears in the Return_Object_Declarations list of
6124 an extended return statement.
6125
61262011-08-02 Matthew Gingell <gingell@adacore.com>
6127
6128 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
6129 unused parameter 'name'.
6130
61312011-08-02 Ed Schonberg <schonberg@adacore.com>
6132
6133 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
6134 inherited operation, check whether its alias, which is the source
6135 operastion that it renames, has been marked eliminated.
6136
61372011-08-02 Javier Miranda <miranda@adacore.com>
6138
6139 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
6140 in-mode parameter whose type is an access type since it can be used to
6141 modify its designated object. Enforce code that handles as safe an
6142 access type that is not access-to-constant but it is the result of a
6143 previous removal of side-effects.
6144 (Remove_Side_Effects): Minor code reorganization of cases which require
6145 no action. Done to incorporate documentation on new cases uncovered
6146 working in this ticket: no action needed if this routine was invoked
6147 too early and the nodes are not yet decorated.
6148 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
6149 to routine Remove_Side_Effects by calls to Force_Evaluation since they
6150 were issued with actuals that are implicitly provided by
6151 Force_Evaluation.
6152
61532011-08-02 Robert Dewar <dewar@adacore.com>
6154
6155 * sem_ch3.adb, sem_res.adb: Minor reformatting.
6156
61572011-08-02 Yannick Moy <moy@adacore.com>
6158
6159 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
6160 to issue an error in formal mode on attribute not supported in this mode
6161 (Analyze_Attribute): issue errors on standard attributes not supported
6162 in formal mode.
6163 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
6164 comment, and issue error in formal mode on modulus which is not a power
6165 of 2.
6166 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
6167 range.
6168 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
6169 subtype mark.
6170 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
6171 operator on modular type (except 'not').
6172
61732011-08-02 Robert Dewar <dewar@adacore.com>
6174
6175 * gnat_rm.texi: Minor reformatting.
6176
61772011-08-02 Arnaud Charlet <charlet@adacore.com>
6178
6179 * s-osinte-linux.ads: Minor comment update and reformatting.
6180 * i-cexten.ads: Make this unit pure, as for its parent.
6181 Will allow its usage in more contexts if needed.
6182
61832011-08-02 Robert Dewar <dewar@adacore.com>
6184
6185 * s-utf_32.ads: Minor comment fix.
6186
61872011-08-02 Ed Schonberg <schonberg@adacore.com>
6188
6189 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
6190 operation of a tagged synchronized type, handle the case where the
6191 controlling argument is overloaded.
6192
61932011-08-02 Yannick Moy <moy@adacore.com>
6194
6195 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
6196 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
6197 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
6198 SPARK mode and formal verification mode on processing SPARK restriction
6199 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
6200 requiring consistency checking.
6201
62022011-08-02 Robert Dewar <dewar@adacore.com>
6203
6204 * sem_res.adb: Minor reformatting.
6205
62062011-08-02 Robert Dewar <dewar@adacore.com>
6207
6208 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
6209 a-cforse.ads: Remove unneeded with of Ada.Containers
6210 Remove commented out pragma Inline's
6211 Move specifications of new subprograms to the actual specs
6212
62132011-08-02 Yannick Moy <moy@adacore.com>
6214
6215 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
6216 a-cforse.ads: Update comments.
6217
62182011-08-02 Ed Schonberg <schonberg@adacore.com>
6219
6220 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
6221
62222011-08-02 Robert Dewar <dewar@adacore.com>
6223
6224 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
6225 a-cforse.ads, a-cofove.ads: Minor reformatting.
6226
62272011-08-02 Claire Dross <dross@adacore.com>
6228
6229 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
6230 a-cofove.ads: Add comments.
6231
62322011-08-02 Yannick Moy <moy@adacore.com>
6233
6234 * gnat_rm.texi: Document formal containers.
6235
62362011-08-02 Emmanuel Briot <briot@adacore.com>
6237
6238 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
6239 are empty sections.
6240
62412011-08-02 Robert Dewar <dewar@adacore.com>
6242
6243 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
6244 reformatting.
6245
62462011-08-02 Robert Dewar <dewar@adacore.com>
6247
6248 * aspects.adb: New aspects Default_Value and Default_Component_Value
6249 New format of Aspect_Names table checks for omitted entries
6250 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
6251 handling of boolean aspects for derived types.
6252 New aspects Default_Value and Default_Component_Value
6253 New format of Aspect_Names table checks for omitted entries
6254 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
6255 (Has_Default_Value): New flag
6256 (Has_Default_Component_Value): New flag
6257 (Has_Default_Value): New flag
6258 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
6259 table.
6260 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
6261 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
6262 Default_Value and Default_Component_Value
6263 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
6264 New aspects Default_Value and Default_Component_Value
6265 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
6266 * sprint.adb: Print N_Aspect_Specification node when called from gdb
6267
62682011-08-02 Vincent Celier <celier@adacore.com>
6269
6270 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
6271 inherit library kind.
6272
62732011-08-02 Ed Schonberg <schonberg@adacore.com>
6274
6275 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
6276 Minor reformatting.
6277
62782011-08-02 Robert Dewar <dewar@adacore.com>
6279
6280 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
6281
62822011-08-02 Yannick Moy <moy@adacore.com>
6283
6284 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
6285
62862011-08-02 Robert Dewar <dewar@adacore.com>
6287
6288 * impunit.adb: Add comment.
6289
62902011-08-02 Yannick Moy <moy@adacore.com>
6291
6292 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
6293 qualification of aggregates in formal mode
6294 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
6295 another aggregate
6296 (Resolve_Aggregate): complete the test that an aggregate is adequately
6297 qualified in formal mode
6298
62992011-08-02 Pascal Obry <obry@adacore.com>
6300
6301 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
6302 * mlib-prj.adb: Supress warning when compiling binder generated file.
6303 (Build_Library): Supress all warnings when compiling the binder
6304 generated file.
6305
63062011-08-02 Yannick Moy <moy@adacore.com>
6307
6308 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
6309 from here...
6310 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
6311 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
6312 Add with/use clauses to make Check_Formal_Restriction visible
6313
63142011-08-02 Ed Schonberg <schonberg@adacore.com>
6315
6316 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
6317 in-parameters when type of the generic formal is private in the generic
6318 spec and non-private in the body.
6319
63202011-08-02 Claire Dross <dross@adacore.com>
6321
6322 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
6323 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
6324 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
6325 * impunit.adb, Makefile.rtl: Take new files into account.
6326
63272011-08-02 Robert Dewar <dewar@adacore.com>
6328
6329 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
6330 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
6331
63322011-08-02 Yannick Moy <moy@adacore.com>
6333
6334 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
6335 formal mode
6336 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
6337 matching static array bounds, taking into account the special case of
6338 string literals
6339 * sem_ch3.adb: Typo in comment.
6340
63412011-08-02 Yannick Moy <moy@adacore.com>
6342
6343 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
6344 which issues an error in formal mode if its argument node is originally
6345 from source
6346 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
6347 has a discriminant specification so that it does not include the case
6348 of derived types
6349 (Derived_Type_Declaration): move here the test that a derived type has a
6350 discriminant specification
6351 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
6352 first element of a component association before accessing its choices
6353 (presence of component association is not enough)
6354 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
6355 declaration is a library item before accessing the next element in a
6356 list, as library items are not member of lists
6357 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
6358 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
6359 Check_Formal_Restriction whenever possible.
6360
63612011-08-02 Ed Schonberg <schonberg@adacore.com>
6362
6363 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
6364 reference when needed.
6365
63662011-08-02 Bob Duff <duff@adacore.com>
6367
6368 * gnat_ugn.texi: Fix typo.
6369
63702011-08-02 Vincent Celier <celier@adacore.com>
6371
6372 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
6373 archive file name. Do not use the full path name of archives for Open
6374 VMS.
6375
63762011-08-02 Robert Dewar <dewar@adacore.com>
6377
6378 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
6379 Analyze_Aspect_Specifications
6380 * sem_ch13.adb
6381 (Analyze_Aspect_Specifications): New handling for boolean aspects
6382 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
6383 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
6384 sequence for Analyze_Aspect_Specifications
6385 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
6386 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
6387
63882011-08-02 Robert Dewar <dewar@adacore.com>
6389
6390 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
6391 aspects, since these no longer exist.
6392
63932011-08-02 Robert Dewar <dewar@adacore.com>
6394
6395 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
6396 semicolon, do not try to see if there are aspects following it.
6397 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
6398 aspect spec.
6399
64002011-08-02 Robert Dewar <dewar@adacore.com>
6401
6402 * sem_ch8.adb, aspects.ads: Minor reformatting.
6403
64042011-08-02 Eric Botcazou <ebotcazou@adacore.com>
6405
6406 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
6407 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
6408 extracted from...
6409 (Analyze_Aspect_Specifications): ...here. Call above procedure.
6410
64112011-08-02 Yannick Moy <moy@adacore.com>
6412
6413 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
6414 mode on subprogram declaration outside of package specification, unless
6415 it is followed by a pragma Import
6416 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
6417 Access_Type_Declaration): issue error in formal mode on access type
6418 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
6419 incomplete type
6420 (Analyze_Object_Declaration): issue error in formal mode on object
6421 declaration which does not respect SPARK restrictions
6422 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
6423 declaration which does not respect SPARK restrictions
6424 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
6425 error in formal mode on digits or delta constraint
6426 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
6427 decimal fixed point type
6428 (Derived_Type_Declaration): issue error in formal mode on derived type
6429 other than type extensions of tagged record types
6430 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
6431 with check on access definition
6432 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
6433 mode on protected definition.
6434 (Analyze_Task_Definition): issue error in formal mode on task definition
6435
64362011-08-02 Robert Dewar <dewar@adacore.com>
6437
6438 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
6439
64402011-08-02 Javier Miranda <miranda@adacore.com>
6441
6442 * sem_ch6.adb (Can_Override_Operator): New function.
6443 (Verify_Overriding_Indicator): Add missing code to check overriding
6444 indicator in operators. Fixes regression.
6445 (Check_Overriding_Indicator): Minor reformating after replacing the
6446 code that evaluates if the subprogram can override an operator by
6447 invocations to the above new function.
6448 * einfo.adb
6449 (Write_Field26_Name): Add missing code to ensure that, following
6450 the documentation in einfo.ads, this field is not shown as attribute
6451 "Static_Initialization" on non-dispatching functions.
6452
64532011-08-02 Jose Ruiz <ruiz@adacore.com>
6454
6455 * sem_res.adb (Resolve_Call): A call to
6456 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
6457 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
6458 i.e., when the second parameter is of type Time_Span.
6459
64602011-08-02 Vincent Celier <celier@adacore.com>
6461
6462 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
6463 with an archive instead of -L<library dir> -l<library name>.
6464
64652011-08-02 Ed Schonberg <schonberg@adacore.com>
6466
6467 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
6468 mark the base types In_Use in addition to making the operations
6469 use_visible.
6470
64712011-08-02 Ed Falis <falis@adacore.com>
6472
6473 * init.c: add and setup __gnat_signal_mask for the exception signals
6474 * s-inmaop-vxworks.adb: new file.
6475 * s-intman-vxworks.adb: remove unnecessary initializations and
6476 simplify remaining
6477 * s-intman-vxworks.ads: remove unnecessary variable
6478 * s-taprop-vxworks.adb: simplify signal initialization
6479
64802011-08-02 Robert Dewar <dewar@adacore.com>
6481
6482 * sem_ch8.adb: Minor code reorganization, comment updates.
6483
64842011-08-02 Robert Dewar <dewar@adacore.com>
6485
6486 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
6487 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
6488 here from Sem_Res.
6489 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
6490 (Matching_Static_Array_Bounds): Moved here from Sem_Res
6491
64922011-08-02 Ed Schonberg <schonberg@adacore.com>
6493
6494 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
6495 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
6496 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
6497 use_type_clauses, to handle more efficiently use_type and use_all_type
6498 constructs.
6499 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
6500 Ada2012 Use_All_Type clause.
6501 (Use_Class_Wide_Operations): new procedure.
6502
65032011-08-02 Robert Dewar <dewar@adacore.com>
6504
6505 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
6506 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
6507 expression to expression function.
6508
65092011-08-02 Ed Schonberg <schonberg@adacore.com>
6510
6511 * sem_ch4.adb: transform simple Ada2012 membership into equality only
6512 if types are compatible.
6513
65142011-08-02 Yannick Moy <moy@adacore.com>
6515
6516 * sem_res.adb (Matching_Static_Array_Bounds): new function which
6517 returns True if its argument array types have same dimension and same
6518 static bounds at each index.
6519 (Resolve_Actuals): issue an error in formal mode on actuals passed as
6520 OUT or IN OUT paramaters which are not view conversions in SPARK.
6521 (Resolve_Arithmetic_Op): issue an error in formal mode on
6522 multiplication or division with operands of fixed point types which are
6523 not qualified or explicitly converted.
6524 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
6525 Boolean or array type (except String) operands.
6526 (Resolve_Equality_Op): issue an error in formal mode on equality
6527 operators for array types other than String with non-matching static
6528 bounds.
6529 (Resolve_Logical_Op): issue an error in formal mode on logical operators
6530 for array types with non-matching static bounds. Factorize the code in
6531 Matching_Static_Array_Bounds.
6532 (Resolve_Qualified_Expression): issue an error in formal mode on
6533 qualified expressions for array types with non-matching static bounds.
6534 (Resolve_Type_Conversion): issue an error in formal mode on type
6535 conversion for array types with non-matching static bounds
6536
65372011-08-02 Robert Dewar <dewar@adacore.com>
6538
6539 * par-ch10.adb: Minor code reorganization (use Nkind_In).
6540
65412011-08-02 Ed Schonberg <schonberg@adacore.com>
6542
6543 * par-ch9.adb: save location of entry for proper error message.
6544
65452011-08-02 Javier Miranda <miranda@adacore.com>
6546
6547 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
6548 (Use_Full_View) which permits this routine to climb through the
6549 ancestors using the full-view of private parents.
6550 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
6551 Use_Full_View to true in calls to Is_Ancestor.
6552 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
6553 true in call to Is_Ancestor.
6554 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
6555 Use_Full_View to true in call to Is_Ancestor.
6556 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
6557 call to Is_Ancestor.
6558 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
6559 Use_Full_View to true in calls to Is_Ancestor.
6560 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
6561 Make_Select_Specific_Data_Table, Register_Primitive,
6562 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
6563 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
6564 to true in call to Is_Ancestor.
6565 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
6566 Use_Full_View to true in calls to Is_Ancestor.
6567 * exp_cg.adb
6568 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
6569 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
6570
65712011-08-02 Robert Dewar <dewar@adacore.com>
6572
6573 * gnat_rm.texi: Minor reformatting.
6574 * sem_prag.adb: Minor reformatting.
6575
65762011-08-02 Tristan Gingold <gingold@adacore.com>
6577
6578 * vms_data.ads: Add VMS qualifier for -gnateP.
6579
65802011-08-02 Robert Dewar <dewar@adacore.com>
6581
6582 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
6583 * par-ch7.adb (P_Package): Proper placement of aspects for package
6584 decl/instantiation.
6585 * par-endh.adb (Check_End): Ad Is_Sloc parameter
6586 (End_Statements): Add Is_Sloc parameterr
6587 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
6588 (Check_End): Ad Is_Sloc parameter
6589 (End_Statements): Add Is_Sloc parameterr
6590
65912011-08-02 Vincent Celier <celier@adacore.com>
6592
6593 * ug_words: Add VMS qualifier equivalent to -gnateP:
6594 /SYMBOL_PREPROCESSING.
6595
65962011-08-02 Jose Ruiz <ruiz@adacore.com>
6597
6598 * gnat-style.texi: For hexadecimal numeric literals the typical
6599 grouping of digits is 4 to represent 2 bytes.
6600 A procedure spec which is split into several lines is indented two
6601 characters.
6602
66032011-08-02 Yannick Moy <moy@adacore.com>
6604
6605 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
6606 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
6607 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
6608 properly qualified
6609 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
6610 choice in array aggregate
6611 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
6612 mark as ancestor
6613 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
6614 positional and named aggregate for record, or others in record
6615 aggregate, or multiple choice in record aggregate
6616 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
6617 array operands to logical operations AND, OR and XOR do not have the
6618 same static lower and higher bounds
6619 * sem_ch5.adb, sinfo.ads: Correct typos in comments
6620
66212011-08-01 Robert Dewar <dewar@adacore.com>
6622
6623 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
6624 Replaces Last_Source_Node_In_Sequence.
6625 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
6626 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
6627 parens and blank in string (this was inconsistently implemented).
6628 * errout.ads
6629 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
6630 blank in string (this was inconsistently implemented).
6631 * gnat1drv.adb
6632 (Set_Global_Switches): Set formal mode switches appropriately
6633 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
6634 * par-prag.adb
6635 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
6636 call Set_Error_Msg_Lang to set "spark" as language name.
6637 * par.adb: Remove unnecessary call to set formal language for errout
6638 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
6639 appropriately and call Set_Error_Msg_Lang to set "spark" as language
6640 name.
6641 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
6642 calls to it, moved after resolution so that types are known
6643 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
6644 result of concatenation is not of type String
6645 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
6646 concatenation is not properly restricted
6647 * gnat_rm.texi: Add doc on pragma Spark_95.
6648 * gcc-interface/Makefile.in: Remove obsolete target pairs for
6649 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
6650 * gcc-interface/Make-lang.in: Update dependencies.
6651
66522011-08-01 Javier Miranda <miranda@adacore.com>
6653
6654 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
6655 condition that detects if the overridden operation must replace an
6656 existing entity.
6657
66582011-08-01 Javier Miranda <miranda@adacore.com>
6659
6660 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
6661 code declarations inserted by Insert_Actions in each alternative of the
6662 N_Case_Expression node.
6663
66642011-08-01 Robert Dewar <dewar@adacore.com>
6665
6666 * sem_ch6.adb: Minor code reorganization.
6667 * sem_util.adb: Minor reformatting.
6668
66692011-08-01 Pascal Obry <obry@adacore.com>
6670
6671 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
6672 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
6673
66742011-08-01 Yannick Moy <moy@adacore.com>
6675
6676 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
6677 literal or operator symbol which is prefixed
6678 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
6679 mode on access attributes.
6680 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
6681 that concatenation operands are properly restricted in formal mode
6682 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
6683 Analyze_Concatenation_Operand. Issue an error in formal mode if the
6684 result of the concatenation has a type different from String.
6685 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
6686 Analyze_Quantified_Expression, Analyze_Slice,
6687 Analyze_Null): issue an error in formal mode on unsupported constructs
6688 * sem_ch5.adb
6689 (Analyze_Block_Statement): only issue error on source block statement
6690 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
6691 function which returns the last node in a list of nodes for which
6692 Comes_From_Source returns True, if any
6693 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
6694 Last_Source_Node_In_Sequence
6695 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
6696 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
6697 mode on unsupported constructs
6698 * sem_ch9.adb Do not return after issuing error in formal mode, as the
6699 rest of the actions may be needed later on since the error is marked as
6700 not serious.
6701 * sinfo.ads: Typos in comments.
6702
67032011-08-01 Pascal Obry <obry@adacore.com>
6704
6705 * projects.texi: Minor editing.
6706
67072011-08-01 Yannick Moy <moy@adacore.com>
6708
6709 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
6710 insertion character ~~
6711 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
6712 (Set_Error_Msg_Lang): new procedure which fixes the language for use
6713 with insertion character ~~
6714 (Set_Msg_Text): treat insertion character ~~
6715 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
6716 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
6717 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
6718 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
6719 errors related to the formal language restriction not serious
6720 (insertion character |).
6721 * par.adb (Par): set formal language for error messages if needed
6722 * sem_ch6.adb (Check_Missing_Return): take into account possible
6723 generated statements at the end of the function
6724 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
6725 enumeration value to define a new pragma SPARK_95
6726 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
6727 SPARK_Version): new type and variables to store the SPARK version
6728 (none by default).
6729 (SPARK_Mode): return True when SPARK_Version is set
6730 * par-prag.adb: Correct indentation
6731 (Prag): take Pragma_SPARK_95 into account
6732 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
6733 into account.
6734
67352011-08-01 Robert Dewar <dewar@adacore.com>
6736
6737 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
6738 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
6739 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
6740
67412011-08-01 Pascal Obry <obry@adacore.com>
6742
6743 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
6744 Target_Name to Get_Path call.
6745 (Parse_Single_Project): Likewise.
6746 (Post_Parse_Context_Clause): Likewise.
6747 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
6748 Call Initialise_Project_Path with the proper Target_Name.
6749 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
6750 search path.
6751 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
6752 with the proper Target_Name.
6753 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
6754 Part.Parse routine.
6755 (Parse_Project_And_Apply_Config): Likewise.
6756 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
6757 This is fine as this part of the code is supporting only native
6758 compilation.
6759 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
6760 is fine as this part of the code is supporting only native compilation.
6761
67622011-08-01 Yannick Moy <moy@adacore.com>
6763
6764 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
6765 of homonym, unless the homonym is one of the cases allowed in SPARK
6766 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
6767 package declaration occurring after a body.
6768
67692011-08-01 Robert Dewar <dewar@adacore.com>
6770
6771 * checks.adb, exp_ch4.adb: Minor reformatting.
6772
67732011-08-01 Javier Miranda <miranda@adacore.com>
6774
6775 * einfo.ads (Access_Disp_Table): Fix documentation.
6776 (Dispatch_Table_Wrappers): Fix documentation.
6777
67782011-08-01 Pascal Obry <obry@adacore.com>
6779
6780 * prj-env.adb, prj-env.ads: Minor reformatting.
6781
67822011-08-01 Yannick Moy <moy@adacore.com>
6783
6784 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
6785 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
6786 procedures out of these packages.
2c7f9cc0 6787 * errout.ads, errout.adb
052e0603
AC
6788 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
6789 procedures in of this package
6790 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
6791 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
6792 on misplaced later vs initial declarations, like in Ada 83
6793 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
6794 formal mode on attribute of private type whose full type declaration
6795 is not visible
6796 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
6797 package declaration inside a package specification
6798 (Analyze_Full_Type_Declaration): issue error in formal mode on
6799 controlled type or discriminant type
6800 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
6801 user-defined operator means that it should come from the source
6802 (New_Overloaded_Entity): issue error in formal mode on overloaded
6803 entity.
6804 * sem_ch6.ads, sem_ch13.ads: typos in comments.
6805
68062011-08-01 Thomas Quinot <quinot@adacore.com>
6807
6808 * atree.adb: Minor reformatting.
6809 * checks.adb: Minor reformatting.
6810
68112011-08-01 Vincent Celier <celier@adacore.com>
6812
6813 * s-parame-vms-ia64.ads: Fix typo in comment
6814 Minor reformatting
6815 * s-parame-vms-restrict.ads: Removed, unused.
6816
68172011-08-01 Javier Miranda <miranda@adacore.com>
6818
6819 * exp_ch3.adb
6820 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
6821 * sem_ch3.adb
6822 (Constrain_Index): Remove side effects in the evaluation of the bounds.
6823 * sem_ch3.ads, sem_ch3.adb
6824 (Is_Constant_Bound): New extended version of the subprogram that was
6825 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
6826 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
6827 * sem_aux.ads (Constant_Value): Fix typo in comment.
6828 * checks.adb (Generate_Index_Checks): New implementation which, for
6829 array objects with constant bounds, generates the runtime check
6830 referencing the bounds of the array type. For other cases this routine
6831 provides its previous behavior obtaining such values from the array
6832 object.
6833 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
6834 parent type.
6835 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
6836 we cannot have semantic interpretations of the new node.
6837
68382011-08-01 Ed Schonberg <schonberg@adacore.com>
6839
6840 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
6841 expressions.
6842
68432011-08-01 Arnaud Charlet <charlet@adacore.com>
6844
6845 * sem_ch8.adb: Minor code editing.
6846 * s-vxwext.adb: Remove trailing space.
6847 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
6848 consistency with other files.
6849
68502011-08-01 Thomas Quinot <quinot@adacore.com>
6851
6852 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
6853
68542011-08-01 Ed Schonberg <schonberg@adacore.com>
6855
6856 * par-ch10.adb: reject parameterized expressions as compilation unit.
6857 * sem_ch4.adb: handle properly conditional expression with overloaded
6858 then_clause and no else_clause.
6859
68602011-08-01 Tristan Gingold <gingold@adacore.com>
6861
6862 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
6863 like done by System.Aux_DEC.
6864 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
6865
68662011-08-01 Yannick Moy <moy@adacore.com>
6867
6868 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
6869 missing label at end of declaration (subprogram or package)
6870 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
6871 of positional and named parameter association
6872 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
6873 Error_Msg_SP which adds a prefix to the error message giving the name
6874 of the formal language analyzed
6875 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
6876 access result type in subprogram, unconstrained array as result type,.
6877 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
6878 procedure
6879 * sem_ch8.adb: Code clean up.
6880
68812011-08-01 Javier Miranda <miranda@adacore.com>
6882
6883 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
6884 * einfo.ads (Access_Disp_Table): Fix documentation.
6885 (Dispatch_Table_Wrappers): Fix documentation.
6886 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
6887 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
6888 to enforce the documentation of this attribute.
6889 (Set_Is_Interface): Cleanup the assertion.
6890 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
6891 the Underlying_Type entity before reading attribute Access_Disp_Table.
6892 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
6893 Locate the Underlying_Type before reading attribute Access_Disp_Table.
6894 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
6895 the Underlying_Type entity before reading attribute Access_Disp_Table.
6896 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
6897 Locate the Underlying_Type entity before reading attribute
6898 Access_Disp_Table.
6899
69002011-08-01 Ed Schonberg <schonberg@adacore.com>
6901
6902 * s-poosiz.ads: Additional overriding indicators.
6903
69042011-08-01 Yannick Moy <moy@adacore.com>
6905
6906 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
6907 formal mode.
6908 (Analyze_Iteration_Scheme): issue error in formal mode when loop
6909 parameter specification does not include a subtype mark.
6910 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
6911 formal mode on abstract subprogram.
6912 (Analyze_Subprogram_Specification): issue error in formal mode on
6913 user-defined operator.
6914 (Process_Formals): issue error in formal mode on access parameter and
6915 default expression.
6916 * sem_ch9.adb (Analyze_Abort_Statement,
6917 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
6918 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
6919 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
6920 Analyze_Requeue, Analyze_Selective_Accept,
6921 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
6922 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
6923 issue error in formal mode on user-defined raise statement.
6924
69252011-08-01 Thomas Quinot <quinot@adacore.com>
6926
6927 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
6928 declaration being hidden when overriding an implicit inherited
6929 subprogram.
6930 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
6931 (-gnats), do not complain about a source file that contains only a
6932 pragma No_Body.
6933
69342011-08-01 Ed Schonberg <schonberg@adacore.com>
6935
6936 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
6937 variable if already set.
6938
69392011-08-01 Arnaud Charlet <charlet@adacore.com>
6940
6941 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
6942 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
6943 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
6944 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
6945 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
6946 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
6947 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
6948 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
6949 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
6950 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
6951 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
6952 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
6953 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
6954 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
6955 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
6956 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
6957 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
6958 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
6959 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
6960 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
6961 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
6962 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
6963 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
6964 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
6965 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
6966 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
6967 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
6968 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
6969 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
6970 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
6971 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
6972 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
6973 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
6974 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
6975 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
6976 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
6977 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
6978 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
6979 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
6980 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
6981 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
6982 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
6983 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
6984 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
6985 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
6986 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
6987 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
6988 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
6989 s-osinte-mingw.ads: Update to GPLv3 run-time license.
6990 Use GNAT instead of GNARL.
6991
69922011-08-01 Bob Duff <duff@adacore.com>
6993
6994 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
6995 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
6996 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
6997 reformatting.
6998
69992011-08-01 Yannick Moy <moy@adacore.com>
7000
7001 * debug.adb (d.D) reverve flag for the SPARK mode
7002 (d.E) reverve flag for SPARK generation mode
7003 (d.F) reverve flag for Why generation mode
2c7f9cc0 7004 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
052e0603
AC
7005 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
7006 functions which return True when the corresponding modes are set
7007 (Formal_Language): return "spark" or "alfa" when in formal verification
7008 mode.
7009 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
7010 Error_Msg to prefix the error message with a tag giving the formal
7011 language
7012 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
7013 message with a tag giving the formal language
7014 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
7015 block statement
7016 (Analyze_Case_Statement): issue error in formal mode on case statement
7017 with a single "others" case alternative
7018 (Analyze_Exit_Statement): issue errors in formal mode on exit
7019 statements which do not respect SPARK restrictions
7020 (Analyze_Goto_Statement): issue error in formal mode on goto statement
7021 (Check_Unreachable_Code): always issue an error (not a warning) in
7022 formal mode on unreachable code (concerns both code after an infinite
7023 loop and after an unconditional jump, both not allowed in SPARK)
7024 * sem_ch6.adb (Analyze_Return_Statement): add call to
7025 Set_Return_Present for a procedure containing a return statement
7026 (already done for functions in Analyze_Function_Return)
7027 (Analyze_Function_Return): issue error in formal mode on extended
7028 return or if return is not last statement in function
7029 (Check_Missing_Return): issue error in formal mode if function does
7030 not end with return or if procedure contains a return
7031 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
7032 function to detect if there is an inner scope of its parameter S which
7033 is a loop.
7034
70352011-08-01 Thomas Quinot <quinot@adacore.com>
7036
7037 * sem_ch6.ads: Minor reformatting.
7038
70392011-08-01 Javier Miranda <miranda@adacore.com>
7040
7041 * sem_util.adb (Abstract_Interface_List): Complete condition when
7042 processing private type declarations to avoid reading unavailable
7043 attribute.
7044 (Is_Synchronized_Tagged_Type): Complete condition when processing
7045 private extension declaration nodes to avoid reading unavailable
7046 attribute.
7047
70482011-08-01 Thomas Quinot <quinot@adacore.com>
7049
7050 * sem_ch3.adb: Minor reformatting.
7051
70522011-08-01 Thomas Quinot <quinot@adacore.com>
7053
7054 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
7055 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
7056 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
7057 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
7058 for VMS, instead parametrize the common implementation with
7059 System.Parameters declarations.
7060
70612011-08-01 Eric Botcazou <ebotcazou@adacore.com>
7062
7063 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
7064
70652011-08-01 Tristan Gingold <gingold@adacore.com>
7066
7067 * seh_init.c: Fix SEH handler installation on win64.
7068
70692011-08-01 Ed Schonberg <schonberg@adacore.com>
7070
7071 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
7072 double analysis of an anonymous access to subprogram, because it can
7073 lead to improper sharing of profiles and a back-end crash.
7074
70752011-08-01 Robert Dewar <dewar@adacore.com>
7076
7077 * make.adb, sem_ch4.adb: Minor reformatting.
7078 * gcc-interface/Make-lang.in: Update dependencies.
7079 * sem_util.adb, exp_ch5.adb: Minor reformatting.
7080
70812011-08-01 Arnaud Charlet <charlet@adacore.com>
7082
7083 * gnat_rm.texi: Fix definition of Long_Integer.
7084
70852011-08-01 Ed Schonberg <schonberg@adacore.com>
7086
7087 * exp_aggr.adb: check limit size of static aggregate unconditionally,
7088 to prevent storage exhaustion.
7089 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
7090 finalized is a function body, insert the cleanup code before the final
7091 return statement, to prevent spurious warnings.
7092 * s-pooglo.ads: add overriding indicator.
7093
70942011-08-01 Ed Schonberg <schonberg@adacore.com>
7095
7096 * sem_ch4.adb (Operator_Check): improve error message when both a
7097 with_clause and a use_clause are needed to make operator usage legal.
7098 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
7099 determine whether a compilation unit is visible within an other,
7100 either through a with_clause in the current unit, or a with_clause in
7101 its library unit or one one of its parents.
7102
71032011-08-01 Ed Schonberg <schonberg@adacore.com>
7104
7105 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
7106 over an arbitrary expression of an array or container type.
7107 * lib-xref.adb: clarify comment.
7108
71092011-08-01 Bob Duff <duff@adacore.com>
7110
7111 * einfo.ads: Minor reformatting.
7112 * debug.adb: Minor comment improvement.
7113
71142011-08-01 Javier Miranda <miranda@adacore.com>
7115
7116 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
7117 consider hidden subprograms as valid candidates.
7118
71192011-08-01 Arnaud Charlet <charlet@adacore.com>
7120
7121 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
7122
71232011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
7124
7125 * gnat_ugn.texi: Fix typo.
7126
71272011-08-01 Robert Dewar <dewar@adacore.com>
7128
7129 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
7130 lib-xref.adb: Minor reformatting
7131
71322011-08-01 Gary Dismukes <dismukes@adacore.com>
7133
7134 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
7135 when to generate a call to Move_Final_List.
7136 (Has_Controlled_Parts): Remove this function.
7137
71382011-08-01 Geert Bosch <bosch@adacore.com>
7139
7140 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
7141 "," in choice list.
7142
71432011-08-01 Thomas Quinot <quinot@adacore.com>
7144
7145 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
7146 explicit raise of a predefined exception as Comes_From_Source if the
7147 original N_Raise_Statement comes from source.
7148
71492011-08-01 Robert Dewar <dewar@adacore.com>
7150
7151 * sinfo.ads: Add comment.
7152 * sem_ch6.adb: Minor reformatting.
7153
71542011-08-01 Robert Dewar <dewar@adacore.com>
7155
7156 * freeze.adb (Freeze_Entity): Refine check for bad component size
7157 clause to avoid rejecting confirming clause when atomic/aliased present.
7158
71592011-08-01 Ed Schonberg <schonberg@adacore.com>
7160
7161 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
7162 better determine whether an entity reference is a write.
7163 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
7164 subcomponent.
7165 * lib-xref.adb (Output_References): Do no suppress a read reference at
7166 the same location as an immediately preceeding modify-reference, to
7167 handle properly in-out actuals.
7168
71692011-08-01 Tristan Gingold <gingold@adacore.com>
7170
7171 * env.c (__gnat_setenv) [VMS]: Refine previous change.
7172
71732011-08-01 Quentin Ochem <ochem@adacore.com>
7174
7175 * i-cstrin.adb (New_String): Changed implementation, now uses only the
7176 heap to compute the result.
7177
71782011-08-01 Robert Dewar <dewar@adacore.com>
7179
7180 * atree.ads: Minor reformatting.
7181
71822011-08-01 Emmanuel Briot <briot@adacore.com>
7183
7184 * g-expect.adb (Get_Command_Output): Fix memory leak.
7185
71862011-08-01 Geert Bosch <bosch@adacore.com>
7187
7188 * cstand.adb (P_Float_Type): New procedure to print the definition of
7189 predefined fpt types.
7190 (P_Mixed_Name): New procedure to print a name using mixed case
7191 (Print_Standard): Use P_Float_Type for printing floating point types
7192 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
7193 precision IEEE float.
7194
71952011-08-01 Thomas Quinot <quinot@adacore.com>
7196
7197 * sem_ch3.adb: Minor reformatting.
7198
71992011-08-01 Ed Schonberg <schonberg@adacore.com>
7200
7201 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
7202 the completion of a generic function, insert the new body rather than
7203 rewriting the original.
7204
72052011-08-01 Yannick Moy <moy@adacore.com>
7206
7207 * sinfo.ads, errout.ads: Typos in comments.
7208
72092011-08-01 Robert Dewar <dewar@adacore.com>
7210
7211 * par-endh.adb: Minor reformatting.
7212
72132011-08-01 Robert Dewar <dewar@adacore.com>
7214
7215 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
7216 (Pre_Post_Aspects): New subtype.
7217 * par-ch12.adb (P_Generic): New syntax for aspects in packages
7218 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
7219 * par-ch7.adb (P_Package): Remove Decl parameter
7220 (P_Package): Handle new syntax for aspects (before IS)
7221 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
7222 new aspect syntax
7223 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
7224 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
7225 (P_Package): Remove Decl parameter
7226 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
7227 aspects
7228 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
7229 specs
7230 * sem_util.ads, sem_util.adb (Static_Boolean): New function
7231 * sinfo.ads: Document new syntax for aspects in packages etc.
7232 * sprint.adb: Handle new syntax of aspects before IS in package
7233
72342011-08-01 Thomas Quinot <quinot@adacore.com>
7235
7236 * atree.ads: Minor reformatting.
7237 * sem_prag.adb: Minor reformatting.
7238
72392011-08-01 Robert Dewar <dewar@adacore.com>
7240
7241 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
7242 case expr alternative.
7243
72442011-08-01 Ed Schonberg <schonberg@adacore.com>
7245
7246 * sem_ch12.adb: Fix typo.
7247
72482011-08-01 Geert Bosch <bosch@adacore.com>
7249
7250 * sem_prag.adb (Check_No_Link_Name): New procedure.
7251 (Process_Import_Or_Interface): Use Check_No_Link_Name.
7252 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
7253 instead of Standard_Long_Long_Float_Size global. Preparation for
7254 eventual removal of per type constants.
7255 * exp_util.ads (Get_Stream_Size): New function returning the stream
7256 size value of subtype E.
7257 * exp_util.adb (Get_Stream_Size): Implement new function.
7258 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
7259 function.
7260 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
7261 * einfo.adb:
7262 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
7263
72642011-08-01 Geert Bosch <bosch@adacore.com>
7265
7266 * cstand.adb: Fix comments.
7267 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
7268 count of arguments.
7269
72702011-08-01 Robert Dewar <dewar@adacore.com>
7271
7272 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
7273
72742011-08-01 Geert Bosch <bosch@adacore.com>
7275
7276 * atree.ads: Fix comment.
7277
72782011-08-01 Robert Dewar <dewar@adacore.com>
7279
7280 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
7281 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
7282 * par.adb: Add with for Namet.Sp.
7283 * par-tchk.adb: Minor reformatting.
7284
72852011-08-01 Vincent Celier <celier@adacore.com>
7286
7287 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
7288 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
7289 of the init procedure of a SAL.
7290 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
7291 New procedure.
7292
72932011-08-01 Thomas Quinot <quinot@adacore.com>
7294
7295 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
7296 reformatting.
7297
72982011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
7299
7300 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
7301
73022011-08-01 Thomas Quinot <quinot@adacore.com>
7303
7304 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
7305 conformant with its spec (return True only for types that have
7306 an overriding Initialize primitive operation that prevents them from
7307 having preelaborable initialization).
7308 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
7309 initialization for controlled types in Ada 2005 or later mode.
7310
73112011-08-01 Robert Dewar <dewar@adacore.com>
7312
7313 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
7314 Postcondition.
7315 (Same_Aspect): New function.
7316 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
7317 Type_Invariant, Precondition, Postcondition.
7318 * snames.ads-tmpl: Add Name_Type_Invariant.
7319
73202011-08-01 Robert Dewar <dewar@adacore.com>
7321
7322 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
7323 here.
7324 (Freeze_All_Ent): Fix error in handling inherited aspects.
7325 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
7326 already analyzed, but don't skip entire processing of a declaration,
7327 that's wrong in some cases of declarations being rewritten.
7328 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
7329 Don't delay for integer, string literals
7330 Treat predicates in usual manner for delay, remove special case code,
7331 not needed.
7332 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
7333 (Build_Predicate_Function): Update saved expression in aspect
7334 (Build_Invariant_Procedure): Update saved expression in aspect
7335 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
7336 of replacement of discriminant references if the reference is simple.
7337
73382011-08-01 Robert Dewar <dewar@adacore.com>
7339
7340 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
7341 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
7342 Static_Predicate and Dynamic_Predicate.
7343 (Build_Predicate_Function): Add processing for Static_Predicate
7344 and Dynamic_Predicate.
7345 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
7346 (From_Static_Predicate): New flag
7347 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
7348
73492011-08-01 Robert Dewar <dewar@adacore.com>
7350
7351 * usage.adb: Documentation cleanup for Ada version modes in usage.
7352 * expander.adb: Minor reformatting.
7353
73542011-08-01 Robert Dewar <dewar@adacore.com>
7355
7356 * atree.ads: Minor comment fix.
7357 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
7358 a-witeio.ads, sem_prag.adb: Minor reformatting.
7359
73602011-08-01 Doug Rupp <rupp@adacore.com>
7361
7362 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
7363 pointers. Use descrip.h header file for convenience. Add some
7364 comments.
7365
73662011-08-01 Robert Dewar <dewar@adacore.com>
7367
7368 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
7369 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
7370 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
7371 New procedure.
7372 (Check_Aspect_At_End_Of_Declarations): New procedure
7373 (Analye_Aspect_Specification): Minor changes for above procedures
7374 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
7375 specification node as well.
7376
73772011-08-01 Pascal Obry <obry@adacore.com>
7378
7379 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
7380 Windows files. Use GetFilesAttributes() in this case to check for file
7381 existence instead of returning with an error code.
7382
73832011-08-01 Vincent Celier <celier@adacore.com>
7384
7385 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
7386 High is above Source length.
7387
73882011-08-01 Robert Dewar <dewar@adacore.com>
7389
7390 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
7391
73922011-08-01 Robert Dewar <dewar@adacore.com>
7393
7394 * aspects.ads (Boolean_Aspects): New subtype.
7395 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
7396 for derived types in cases where the parent type and derived type have
7397 aspects.
7398 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
7399 with aspects when parent type also has aspects.
7400 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
7401 boolean expression at this point).
7402 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
7403 accordance with final decision on the Ada 2012 feature.
7404 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
7405
74062011-08-01 Matthew Heaney <heaney@adacore.com>
7407
7408 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
7409
74102011-08-01 Pascal Obry <obry@adacore.com>
7411
7412 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
7413 Fix Replace_Slice when High is above current string size.
7414 (Replace_Slice): Fix DL computation when High is above current
7415 string length.
7416
74172011-08-01 Gary Dismukes <dismukes@adacore.com>
7418
7419 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
7420
74212011-08-01 Matthew Heaney <heaney@adacore.com>
7422
7423 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
7424 of node.
7425
74262011-08-01 Pascal Obry <obry@adacore.com>
7427
7428 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
7429 reformatting.
7430
74312011-08-01 Ed Schonberg <schonberg@adacore.com>
7432
7433 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
7434 access to protected subprograms in generic bodies.
7435 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
7436 protected type, indicate that the convention of the subprogram is
7437 Convention_Protected, because it may be used in subsequent declarations
7438 within the protected declaration.
7439
74402011-08-01 Vincent Celier <celier@adacore.com>
7441
7442 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
7443 and "final" procedures when the name of the library is "ada", to avoid
7444 duplicate symbols "adainit" and "adafinal" in executables.
7445
74462011-08-01 Ed Schonberg <schonberg@adacore.com>
7447
7448 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
7449 quantified expression that appears within a postcondition and uses the
7450 Ada2012 'Result attribute.
7451
74522011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7453
7454 * init.c (__gnat_error_handler): Cast reason to int.
7455 (__gnat_install_handler): Explain sa_sigaction use.
7456
74572011-07-24 Eric Botcazou <ebotcazou@adacore.com>
7458
7459 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
7460 subprogram has copy-in copy-out parameters, try to promote the mode of
7461 the return type if it is passed in registers.
7462
74632011-07-24 Eric Botcazou <ebotcazou@adacore.com>
7464
7465 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
7466 left operand as addressable.
7467
74682011-07-24 Eric Botcazou <ebotcazou@adacore.com>
7469
7470 * gcc-interface/gigi.h (build_function_stub): Remove.
7471 (build_return_expr): Likewise.
7472 (convert_vms_descriptor): Declare.
7473 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
7474 (build_function_stub): Move to...
7475 * gcc-interface/utils2.c (build_return_expr): Move to...
7476 * gcc-interface/trans.c (build_function_stub): ...here.
7477 (build_return_expr): ...here.
7478 (Subprogram_Body_to_gnu): Add local variable for language_function.
7479 Disconnect the parameter attributes cache, if any, once done with it.
7480 Call end_subprog_body only after setting the end_locus.
7481 Build the stub associated with the function, if any, at the very end.
7482 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
7483 variables and streamline control flow.
7484
74852011-07-23 Arnaud Charlet <charlet@adacore.com>
7486
7487 PR ada/49819
7488 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
7489 g-trasym-dwarf.adb.
7490
74912011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7492
7493 PR bootstrap/49794
7494 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
7495 Assign to act.sa_sigaction.
7496 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
7497 current->return_address to char * before arithmetic.
7498
74992011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7500
7501 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
7502 Correct argument types.
7503 Extract code from reason.
7504 (__gnat_install_handler): Assign to act.sa_sigaction.
7505
75062011-07-21 Eric Botcazou <ebotcazou@adacore.com>
7507
7508 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
7509 (GNAT1_OBJS): ...here.
7510
75112011-07-15 Eric Botcazou <ebotcazou@adacore.com>
7512
7513 PR ada/48711
7514 * g-socthi-mingw.adb (Fill): Fix formatting.
7515
7516 * gcc-interface/gigi.h: Move around comment.
7517
75182011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
7519
7520 PR ada/46350
7521 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
7522
75232011-07-14 Florian Weimer <fw@deneb.enyo.de>
7524
7525 PR ada/48711
7526 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
7527
75282011-07-13 Eric Botcazou <ebotcazou@adacore.com>
7529
7530 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
7531 range comparison if Pmode is SImode.
7532
75332011-07-12 Laurent GUERBY <laurent@guerby.net>
7534 Eric Botcazou <ebotcazou@adacore.com>
7535
7536 * adadecode.c: Wrap up in extern "C" block.
7537 * adadecode.h: Likewise.
7538 * adaint.c: Likewise. Remove 'const' keyword.
7539 * adaint.h: Likewise.
7540 * argv.c: Likewise.
7541 * atree.h: Likewise.
7542 * cio.c: Likewise.
7543 * cstreams.c: Likewise.
7544 * env.c: Likewise.
7545 * exit.c: Likewise.
7546 * fe.h: Likewise.
7547 * final.c: Likewise.
7548 * init.c: Likewise.
7549 * initialize.c: Likewise.
7550 * link.c: Likewise.
7551 * namet.h: Likewise.
7552 * nlists.h: Likewise.
7553 * raise.c: Likewise.
7554 * raise.h: Likewise.
7555 * repinfo.h: Likewise.
7556 * seh_init.c: Likewise.
7557 * targext.c: Likewise.
7558 * tracebak.c: Likewise.
7559 * uintp.h: Likewise.
7560 * urealp.h: Likewise.
7561 * xeinfo.adb: Wrap up generated C code in extern "C" block.
7562 * xsinfo.adb: Likewise.
7563 * xsnamest.adb: Likewise.
7564 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
7565 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
7566 * gcc-interface/misc.c: Likewise.
7567 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
7568 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
7569 ada/targext.o here...
7570 (GNAT_ADA_OBJS): ...and not here.
7571 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
7572 (GNATBIND_OBJS): Reorder.
7573
75742011-07-07 Richard Henderson <rth@redhat.com>
7575
7576 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
7577 dwarf2out_frame_init.
7578
75792011-07-07 Eric Botcazou <ebotcazou@adacore.com>
7580
7581 * gcc-interface/misc.c (gnat_init): Tweak previous change.
7582
75832011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7584
7585 PR target/39150
7586 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
7587
75882011-07-06 Richard Guenther <rguenther@suse.de>
7589
7590 * gcc-interface/misc.c (gnat_init): Merge calls to
7591 build_common_tree_nodes and build_common_tree_nodes_2.
7592 Re-initialize boolean_false_node.
7593
75942011-07-02 Eric Botcazou <ebotcazou@adacore.com>
7595 Olivier Hainque <hainque@adacore.com>
7596 Nicolas Setton <setton@adacore.com>
7597
7598 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
7599 the type according to the ARTIFICIAL_P parameter.
7600 (create_type_decl): Likewise.
7601 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
7602
76032011-07-01 Eric Botcazou <ebotcazou@adacore.com>
7604
7605 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
7606 (gnatbind): Likewise.
7607
76082011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7609
7610 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
7611
76122011-06-18 Eric Botcazou <ebotcazou@adacore.com>
7613
7614 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
7615 local variable throughout. Remove useless call to Base_Type.
7616 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
7617 Take it also into account for the volatileness of the field. Set the
7618 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
7619
76202011-06-18 Eric Botcazou <ebotcazou@adacore.com>
7621
7622 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
7623 on a dereference built for a by-ref object if it has an address clause.
7624
76252011-06-18 Eric Botcazou <ebotcazou@adacore.com>
7626
7627 * einfo.ads (Address_Taken): Document use for the second argument of
7628 Asm_Input and Asm_Output attributes.
7629 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
7630 argument is an entity name, then set Address_Taken on it.
7631 <Attribute_Asm_Output>: Likewise.
7632 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
7633 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
7634 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
7635 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
7636
76372011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
7638
7639 PR middle-end/46500
7640 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
7641
76422011-06-14 Joseph Myers <joseph@codesourcery.com>
7643
7644 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
7645 (ada/utils.o): Update dependencies.
7646 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
7647 ../../../libcpp/libcpp.a.
7648 * gcc-interface/utils.c: Include common/common-target.h.
7649 (process_attributes): Use targetm_common.have_named_sections.
7650
76512011-06-07 Richard Guenther <rguenther@suse.de>
7652
7653 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
7654 set_sizetype.
7655
76562011-06-06 Eric Botcazou <ebotcazou@adacore.com>
7657
7658 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
7659 TREE_THIS_NOTRAP flag.
7660
76612011-06-06 Eric Botcazou <ebotcazou@adacore.com>
7662
7663 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
7664 Fix thinko.
7665
76662011-06-06 Eric Botcazou <ebotcazou@adacore.com>
7667
7668 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
7669 constants whose full view has discriminants specially.
7670
76712011-06-06 Eric Botcazou <ebotcazou@adacore.com>
7672
7673 * gcc-interface/utils.c: Include diagnostic.h.
7674 (gnat_write_global_declarations): Output debug information for all
7675 global type declarations before finalizing the compilation unit.
7676 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
7677
76782011-05-25 Jakub Jelinek <jakub@redhat.com>
7679
7680 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
7681
76822011-05-25 Kai Tietz <ktietz@redhat.com>
7683
7684 * adaint.c (__gnat_to_canonical_file_list_next): Use array
7685 initialization instead of const/none-const pointer assignment.
7686
76872011-05-24 Joseph Myers <joseph@codesourcery.com>
7688
7689 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
7690 $(EXTRA_GNAT1_OBJS).
7691 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
7692 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
7693 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
7694 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
7695 libcommon-target.a instead of prefix.o.
7696
76972011-05-21 Joseph Myers <joseph@codesourcery.com>
7698
7699 PR ada/49097
7700 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
7701
77022011-05-20 Joseph Myers <joseph@codesourcery.com>
7703
7704 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
7705 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
7706 instead of version.o.
7707
77082011-05-18 Kai Tietz <ktietz@redhat.com>
7709
7710 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
7711 boolean_false_node instead of integer_zero_node.
7712 (convert_with_check): Likewise.
7713 * gcc-interface/decl.c (choices_to_gnu): Likewise.
7714
77152011-05-12 Eric Botcazou <ebotcazou@adacore.com>
7716
7717 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
7718 type of the parameter is an unconstrained array, convert the actual to
7719 the type of the formal in the In Out and Out cases as well.
7720
77212011-05-11 Nathan Froyd <froydnj@codesourcery.com>
7722
7723 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
7724 call build_function_type_array or build_varargs_function_type_array
7725 instead.
7726 (create_subprog_type): Don't call build_function_type; call
7727 build_function_type_vec instead.
7728
77292011-05-11 Nathan Froyd <froydnj@codesourcery.com>
7730
7731 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
7732 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
7733 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
7734
77352011-05-07 Eric Botcazou <ebotcazou@adacore.com>
7736
7737 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
7738
7739 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
7740 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
7741
77422011-05-05 Nathan Froyd <froydnj@codesourcery.com>
7743
7744 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
7745
77462011-05-05 Nathan Froyd <froydnj@codesourcery.com>
7747
7748 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
7749 instead of accessing TYPE_ARG_TYPES directly.
7750 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
7751
77522011-05-05 Eric Botcazou <ebotcazou@adacore.com>
7753
7754 PR ada/48844
7755 * gcc-interface/gigi.h (get_variant_part): Declare.
7756 * gcc-interface/decl.c (get_variant_part): Make global.
7757 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
7758 types have the same constant size, are record types and T1 has a
7759 variant part while T2 doesn't.
7760
77612011-05-05 Eric Botcazou <ebotcazou@adacore.com>
7762
7763 * gcc-interface/utils.c (begin_subprog_body): Do not call
7764 get_pending_sizes.
7765 (end_subprog_body): Likewise.
7766
77672011-05-04 Richard Guenther <rguenther@suse.de>
7768
7769 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
7770 int_const_binop.
7771 (pos_to_constructor): Likewise.
7772
77732011-05-03 Nathan Froyd <froydnj@codesourcery.com>
2c7f9cc0 7774 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
7775
7776 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
7777 of build_function_type. Adjust calls to...
7778 (build_raise_check): ...this. Do not take a void_tree parameter.
7779 Call build_function_type_list instead of build_function_type.
7780 Fix head comment and swap couple of conditional blocks.
7781
77822011-04-30 Eric Botcazou <ebotcazou@adacore.com>
7783
7784 * gnatvsn.ads (Library_Version): Bump to 4.7.
7785 (Current_Year): Bump to 2011.
7786
77872011-04-29 Michael Matz <matz@suse.de>
7788
7789 * gcc-interface/misc.c (gnat_handle_option): Set
7790 warn_maybe_uninitialized.
7791
77922011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
7793
7794 * gnat_ugn.texi (Complexity Metrics Control): Update link to
7795 the Watson/McCabe paper.
7796
77972011-04-23 Jim Meyering <meyering@redhat.com>
7798
7799 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
7800
78012011-04-22 Eric Botcazou <ebotcazou@adacore.com>
7802
7803 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
7804 onto the new type.
7805
78062011-04-22 Eric Botcazou <ebotcazou@adacore.com>
7807
7808 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
7809 parameter.
7810 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
7811 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
7812 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
7813 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
7814 <all>: Do not set flags on the reused DECL node coming from an alias.
7815 Set DECL_IGNORED_P on the DECL node built for subprograms if they
7816 don't need debug info here...
7817 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
7818 (gigi): Adjust calls to create_subprog_decl.
7819 (build_raise_check): Likewise.
7820 (establish_gnat_vms_condition_handler): Likewise.
7821 (Compilation_Unit_to_gnu): Likewise.
7822 (gnat_to_gnu): Likewise.
7823
78242011-04-21 Eric Botcazou <ebotcazou@adacore.com>
7825
7826 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
7827 (NO_REORDER_ADAFLAGS): New variable.
7828 (EXTRA_GNATTOOLS): Always define.
7829 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
7830 Clean up and adjust list of files compiled with special options.
7831 * gcc-interface/Make-lang.in: Likewise.
7832 (ada/decl.o): Cosmetical change.
7833 (ada/misc.o): Remove dependency on $(PLUGIN_H).
7834
78352011-04-20 Jim Meyering <meyering@redhat.com>
7836
7837 * initialize.c (__gnat_initialize): Remove useless if-before-free.
7838
78392011-04-17 Eric Botcazou <ebotcazou@adacore.com>
7840
7841 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
7842 $(CFLAGS) on the link line.
7843
78442011-04-17 Eric Botcazou <ebotcazou@adacore.com>
7845
7846 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
7847 padded type built for the return type if it is unconstrained.
7848
78492011-04-14 Nathan Froyd <froydnj@codesourcery.com>
7850
7851 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
7852
78532011-04-12 Nathan Froyd <froydnj@codesourcery.com>
7854
7855 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
7856 before calling TREE_CHAIN.
7857 * gcc-interface/misc.c (gnat_init_ts): New function.
7858 (LANG_HOOKS_INIT_TS): Define.
7859
78602011-04-12 Martin Jambor <mjambor@suse.cz>
7861
7862 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
7863 instead of cgraph_node.
7864
78652011-04-08 Eric Botcazou <ebotcazou@adacore.com>
7866
7867 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
7868 alignment on fields of the RETURN type built for the Copy-In Copy-Out
7869 mechanism.
7870
78712011-04-08 Eric Botcazou <ebotcazou@adacore.com>
7872
7873 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
7874 of aggregate types that contain a placeholder.
7875
78762011-04-08 Nathan Froyd <froydnj@codesourcery.com>
7877
7878 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
7879 TYPE_ARG_TYPES.
7880 (handle_type_generic_attribute): Likewise.
7881
78822011-04-04 Eric Botcazou <ebotcazou@adacore.com>
7883
7884 PR ada/47163
7885 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
7886
78872011-04-04 Kai Tietz <ktietz@redhat.com>
7888
7889 PR ada/47163
7890 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
7891 to flag value.
7892
78932011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7894
7895 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
7896 type case, do not strip a padding type around the array type.
7897
78982011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7899
7900 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
7901 types.
7902
79032011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7904
7905 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
7906 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
7907 code for -feliminate-unused-debug-types.
7908 (gnat_post_options): Likewise.
7909
79102011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7911
7912 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
7913 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
7914 distinct copy.
7915
79162011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7917
7918 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
7919 DECL_ARTIFICIAL flag on enumeration types.
7920
79212011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7922
7923 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
7924 fat pointer types artificial unconditionally.
7925 <E_Array_Subtype>: Attach the base array type as a parallel type if it
7926 isn't artificial.
7927
79282011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7929
7930 * gcc-interface/gigi.h (get_dummy_type): Declare.
7931 (build_dummy_unc_pointer_types): Likewise.
7932 (finish_fat_pointer_type): Likewise.
7933 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
7934 fat pointer type has been built, complete it in place.
7935 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
7936 and thin pointers. Remove useless variable.
7937 (finish_fat_pointer_type): Make global and move to...
7938 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
7939 (get_dummy_type): New function.
7940 (build_dummy_unc_pointer_types): Likewise.
7941 (gnat_pushdecl): Propage the name to the anonymous variants only.
7942 (update_pointer_to): Only adjust the pointer types in the unconstrained
7943 array case.
7944
79452011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7946
7947 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
7948 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
7949 if this is a Taft amendment type and the full declaration is available.
7950 * gcc-interface/trans.c (process_type): Likewise.
7951 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
7952 (process_freeze_entity): Likewise.
7953 * gcc-interface/utils.c (dummy_global): New static variable.
7954 (gnat_write_global_declarations): If there are types declared as used
7955 at the global level, insert them in the global hash table.
7956
79572011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7958
7959 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
7960 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
7961 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
7962 copy.
7963 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
7964 flag of the type accordingly.
7965 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
7966
79672011-04-02 Eric Botcazou <ebotcazou@adacore.com>
7968
7969 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
7970 finalizing types when updating the pointers to the designated type.
7971 <all>: Finalize the deferred types even if we didn't defer processing
7972 of incomplete types in this invocation.
7973
79742011-04-01 Olivier Hainque <hainque@adacore.com>
2c7f9cc0
AS
7975 Nicolas Setton <setton@adacore.com>
7976 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
7977
7978 * gcc-interface/misc.c (gnat_descriptive_type): New function.
7979 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
7980
79812011-03-28 Kai Tietz <ktietz@redhat.com>
7982
7983 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
7984 Windows targets.
7985 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
7986 * system-mingw.ads (System): Change ZCX_By_Default default to True.
7987
7988 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
7989
79902011-03-28 Tristan Gingold <gingold@adacore.com>
7991
7992 PR ada/44431
7993 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
7994 Use ada output of gnatbind.
7995 (ada/b_gnatb.adb): Ditto.
7996 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
7997 (ada.mostlyclean, ada.stage1)
7998 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
7999 (ada.stagefeedback): Adjust.
8000 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
8001 Use ada output of gnatbind.
8002 (b_gnatm.adb): Ditto.
8003 (b_gnatl.o, b_gnatm.o): New rules.
8004
80052011-03-26 Eric Botcazou <ebotcazou@adacore.com>
8006
8007 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
8008 for the padded type built to support a specified size or alignment.
8009
80102011-03-26 Eric Botcazou <ebotcazou@adacore.com>
8011
8012 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
8013 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
8014 unconditionally to the end of the unit when the designated type is
8015 limited_with'ed.
8016 <all>: Rename local variable. Attempt to un-defer types only and do it
8017 for limited_with'ed types as well.
8018 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
8019 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
8020 consistently and remove redundant call to finalize_from_with_types.
8021
80222011-03-26 Eric Botcazou <ebotcazou@adacore.com>
8023
8024 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
8025 subprograms without a previous spec declared in the same unit.
8026 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
8027 subprograms at the end of the unit instead of at the beginning.
8028 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
8029 isn't public for the special handling of non-inline functions nested
8030 inside inline external functions.
8031
80322011-03-25 Jeff Law <law@redhat.com>
8033
8034 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
8035
80362011-03-24 Eric Botcazou <ebotcazou@adacore.com>
8037
8038 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
8039 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
8040 to compute Set_Size_Depends_On_Discriminant.
8041 (Layout_Type): Call it on array types in back-end layout mode.
8042 * sem_util.adb (Requires_Transient_Scope): Return true for array
8043 types only if the size depends on the value of discriminants.
8044 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
8045 type if the RHS is a call to a function that returns an unconstrained
8046 type with default discriminant.
8047
80482011-03-24 Eric Botcazou <ebotcazou@adacore.com>
8049
8050 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
8051 non-conversion to the nominal result type at the end.
8052
80532011-03-23 Eric Botcazou <ebotcazou@adacore.com>
8054
8055 * gcc-interface/trans.c (create_temporary): New function taken from...
8056 (create_init_temporary): ...here. Call it.
8057 (call_to_gnu): Create the temporary for the return value early, if any.
8058 Create it for a function with copy-in/copy-out parameters if there is
8059 no target; in other cases of copy-in/copy-out, use another temporary.
8060 Push the new binding level lazily. Add and rename local variables.
8061
80622011-03-23 Eric Botcazou <ebotcazou@adacore.com>
8063
8064 * gcc-interface/decl.c (validate_size): Improve comments and tweak
8065 error message.
8066 (set_rm_size): Likewise.
8067
80682011-03-23 Eric Botcazou <ebotcazou@adacore.com>
8069
8070 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
8071 for the padded type built in order to support a specified alignment.
8072 Fix incorrect formatting.
8073
80742011-03-21 Eric Botcazou <ebotcazou@adacore.com>
8075
8076 PR bootstrap/48216
8077 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
8078
80792011-03-21 Eric Botcazou <ebotcazou@adacore.com>
8080
8081 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
8082 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
8083 to the end of the list. Adjust recursive call. Rename local variable.
8084 If REORDER is true, reorder components of the record type.
8085 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
8086 components_to_record and adjust the parameter list.
8087
80882011-03-21 Eric Botcazou <ebotcazou@adacore.com>
8089
8090 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
8091 disabled, use the variable for bounds of loop iteration scheme.
8092
80932011-03-21 Kai Tietz <ktietz@redhat.com>
8094
8095 PR target/12171
8096 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
8097
80982011-03-17 Eric Botcazou <ebotcazou@adacore.com>
8099
8100 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
8101 out whether the expression is read-only. Short-circuit placeholder
8102 case and rename a couple of local variables.
8103
81042011-03-17 Eric Botcazou <ebotcazou@adacore.com>
8105
8106 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
8107 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
8108 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
8109 (convert): Deal with conversions from a smaller form type specially.
8110
81112011-02-14 Eric Botcazou <ebotcazou@adacore.com>
8112
8113 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
8114 its argument, except for the special -I- switch.
8115
81162011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
8117
8118 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
8119 "Ada Issues".
8120
81212011-02-08 Eric Botcazou <ebotcazou@adacore.com>
8122
8123 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
8124
81252011-02-03 Eric Botcazou <ebotcazou@adacore.com>
8126
8127 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
8128 GNAT_FORMAL.
8129 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
8130 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
8131 instead of GNAT_FORMAL. Protect the expression against multiple uses.
8132 Do not generate the check directly, instead instantiate the template
8133 check present in the descriptor.
8134 (make_descriptor_field): Move around.
8135 (build_vms_descriptor32): Build a template check in the POINTER field.
8136 (build_vms_descriptor): Remove useless suffixes.
8137 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
8138
81392011-01-26 Eric Botcazou <ebotcazou@adacore.com>
8140
8141 PR bootstrap/47467
8142 * targext.c: Include target files if IN_RTS is defined.
8143
81442011-01-26 Richard Guenther <rguenther@suse.de>
8145
8146 PR bootstrap/47467
8147 * targext.c: Include config.h.
8148 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
8149 dependency.
8150
81512011-01-04 Pascal Obry <obry@adacore.com>
2c7f9cc0 8152 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
8153
8154 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
8155
81562011-01-04 Eric Botcazou <ebotcazou@adacore.com>
8157
8158 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
8159 end-of-case on the end label and its associated gotos, if any.
8160
81612011-01-04 Eric Botcazou <ebotcazou@adacore.com>
8162
8163 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
8164 expressions of the parameter cache within the statement group of
8165 the CICO mechanism.
8166
81672011-01-04 Olivier Hainque <hainque@adacore.com>
2c7f9cc0 8168 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
8169
8170 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
8171 (set_end_locus_from_node): New function.
8172 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
8173 make and the function end_locus.
8174 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
8175 for the elaboration subprogram.
8176 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
8177 set the end_locus of the expression as well.
8178
81792011-01-04 Eric Botcazou <ebotcazou@adacore.com>
8180
8181 PR ada/47131
8182 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
8183 variables that are referenced in exception handlers volatile.
8184
8185
8186\f
8187Copyright (C) 2011 Free Software Foundation, Inc.
8188
8189Copying and distribution of this file, with or without modification,
8190are permitted in any medium without royalty provided the copyright
8191notice and this notice are preserved.
8192
8193 * gnat_rm.texi: Ramification of pragma Eliminate documentation
8194 - fix bugs in the description of Source_Trace;
8195 - get rid of UNIT_NAME;
8196
4fbad0ba
AC
81972011-08-02 Javier Miranda <miranda@adacore.com>
8198
8199 * exp_ch9.adb
8200 (Build_Dispatching_Requeue): Adding support for VM targets
8201 since we cannot directly reference the Tag entity.
8202 * exp_sel.adb (Build_K): Adding support for VM targets.
8203 (Build_S_Assignment): Adding support for VM targets.
8204 * exp_disp.adb
8205 (Default_Prim_Op_Position): In VM targets do not restrict availability
8206 of predefined interface primitives to compiling in Ada 2005 mode.
8207 (Is_Predefined_Interface_Primitive): In VM targets this service is not
8208 restricted to compiling in Ada 2005 mode.
8209 (Make_VM_TSD): Generate code that declares and initializes the OSD
8210 record. Needed to support dispatching calls through synchronized
8211 interfaces.
8212 * exp_ch3.adb
8213 (Make_Predefined_Primitive_Specs): Enable generation of predefined
8214 primitives associated with synchronized interfaces.
8215 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
8216 primitives associated with synchronized interfaces.
8217
82182011-08-02 Yannick Moy <moy@adacore.com>
8219
8220 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
8221 statements hidden in SPARK if preceded by the HIDE directive
8222 (Parse_Exception_Handlers): mark each exception handler in a sequence of
8223 exception handlers as hidden in SPARK if preceded by the HIDE directive
8224 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
8225 if starting with the HIDE directive
8226 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
8227 starting with the HIDE directive; mark the declarations in a private
8228 part as hidden in SPARK if the private part starts with the HIDE
8229 directive
8230 * restrict.adb, restrict.ads
8231 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
8232 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
8233 argument node belongs to a part which is hidden in SPARK
8234 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
8235 parts in SPARK; protect the possibly costly call to
8236 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
8237 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
8238 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
8239 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
8240 Tok_SPARK_Hide.
8241 (Scan): recognize special comment starting with '#' and followed by
8242 SPARK keyword "hide" as a HIDE directive.
8243
82442011-08-02 Yannick Moy <moy@adacore.com>
8245
8246 * types.ads, erroutc.ads: Minor reformatting.
8247
82482011-08-02 Vincent Celier <celier@adacore.com>
8249
8250 * link.c: Add response file support for cross platforms.
8251
6ff6152d
ES
82522011-08-02 Ed Schonberg <schonberg@adacore.com>
8253
8254 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
8255 in an association, set parent field of copy before partial analysis.
8256 * sem_res.adb (Resolve_Slice): create reference to itype only when
8257 expansion is enabled.
8258
975c6896
YM
82592011-08-02 Yannick Moy <moy@adacore.com>
8260
8261 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
8262 for new flag denoting which subprogram bodies are in ALFA
8263 * restrict.adb, sem_ch7.adb: Update comment
8264 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
8265 sem_ch9.adb, sem_res.adb: Add calls to
8266 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
8267 * sem_ch6.adb (Analyze_Function_Return): add calls to
8268 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
8269 middle of the body, and extended return.
8270 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
8271 False when missing return.
8272 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
8273 to True for subprograms whose spec is in ALFA. Remove later on the flag
8274 on the entity used for a subprogram body when there exists a separate
8275 declaration.
8276 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
8277 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
8278 False, otherwise do nothing.
8279
afc8324d
AC
82802011-08-02 Robert Dewar <dewar@adacore.com>
8281
8282 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
8283
82842011-08-02 Yannick Moy <moy@adacore.com>
8285
8286 * sem_ch4.ads: minor formatting.
8287
2ba431e5
YM
82882011-08-02 Yannick Moy <moy@adacore.com>
8289
8290 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
8291 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
8292 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
8293 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
8294 opt.ads: cleanup of SPARK mode
8295
0f853035
YM
82962011-08-02 Yannick Moy <moy@adacore.com>
8297
8298 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
8299 types.
8300 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
8301 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
8302 * sem_ch3.adb
8303 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
8304 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
8305 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
8306 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
8307 types.
8308 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
8309 non-static range.
8310 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
8311 functions whose return type is not in ALFA.
8312 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
8313 specifications.
8314 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
8315 parameter's type is not in ALFA.
8316 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
8317 types are in ALFA.
8318
d2b10647
ES
83192011-08-02 Ed Schonberg <schonberg@adacore.com>
8320
8321 * sem_ch6 (Analyze_Expression_Function): treat the function as
8322 Inline_Always, and introduce a subprogram declaration for it when it is
8323 not a completion.
8324 * inline.adb (Add_Inlined_Body): recognize bodies that come from
8325 expression functions, so that the back-end can determine whether they
8326 can in fact be inlined.
8327 * sem_util.adb (Is_Expression_Function): predicate to determine whether
8328 a function body comes from an expression function.
8329
c7b9d548
AC
83302011-08-02 Gary Dismukes <dismukes@adacore.com>
8331
8332 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
8333 null exclusions to test Can_Never_Be_Null on the anonymous access types
8334 of the formals rather than testing the formals themselves. Exclude this
8335 check in cases where the Old_Formal is marked as a controlling formal,
8336 to avoid issuing spurious errors for bodies completing dispatching
8337 operations (due to the flag not getting set on controlling access
8338 formals in body specs).
8339 (Find_Corresponding_Spec): When checking full and subtype conformance of
8340 subprogram bodies in instances, pass Designated and E in that order, for
8341 consistency with the expected order of the formals (New_Id followed by
8342 Old_Id).
8343
83442011-08-02 Robert Dewar <dewar@adacore.com>
8345
8346 * sem_ch8.adb: Minor reformatting.
8347
1138cf59
AC
83482011-08-02 Ed Schonberg <schonberg@adacore.com>
8349
8350 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
8351 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
8352 primitive operations of class-wide actuals.
8353
83542011-08-02 Javier Miranda <miranda@adacore.com>
8355
8356 * exp_atag.ads, exp_atag.adb
8357 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
8358 since its value is implicitly passed in argument Typ.
8359 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
8360 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
8361 Build_Common_Dispatching_Select_Statements.
8362
7b9db926
RD
83632011-08-02 Robert Dewar <dewar@adacore.com>
8364
8365 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
8366 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
8367 Minor reformatting.
8368
e8374e7a
AC
83692011-08-02 Robert Dewar <dewar@adacore.com>
8370
8371 * sem_res.adb: Minor reformatting.
8372 * sem_prag.adb: Minor reformatting.
8373
83742011-08-02 Javier Miranda <miranda@adacore.com>
8375
8376 * exp_atag.adb, exp_atags.ads
8377 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
8378 by the tagged type Entity. Required to use this routine in the VM
8379 targets since we do not have available the Tag entity in the VM
8380 platforms.
8381 * exp_ch6.adb
8382 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
8383 Ada.Tags has not been previously loaded.
8384 * exp_ch7.adb
8385 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
8386 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
8387 * sem_aux.adb
8388 (Enclosing_Dynamic_Scope): Add missing support to handle the full
8389 view of enclosing scopes. Required to handle enclosing scopes that
8390 are synchronized types whose full view is a task type.
8391 * exp_disp.adb
8392 (Build_VM_TSDs): Minor code improvement to avoid generating and
8393 analyzing lists with empty nodes.
8394 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
8395 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
8396 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
8397 (Make_Disp_Timed_Select_Body): Add support for VM targets.
8398 (Make_Select_Specific_Data_Table): Add support for VM targets.
8399 (Make_VM_TSD): Generate code to initialize the SSD structure of
8400 the TSD.
8401
84022011-08-02 Yannick Moy <moy@adacore.com>
8403
8404 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
8405 cross-references section in ALI.
8406 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
8407 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
8408 Sub).
8409 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
8410 subprogram or package entity of a node
8411 (Is_Local_Reference_Type): new function returns True for references
8412 selected in local cross-references.
8413 (Lt): function extracted from Lt in Output_References
8414 (Write_Entity_Name): function extracted from Output_References
8415 (Generate_Definition): generate reference with type 'D' for definition
8416 of objects (object declaration and parameter specification), with
8417 appropriate locations and units, for use in local cross-references.
8418 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
8419 references of type 'I' for initialization in object definition.
8420 (Output_References): move part of function Lt and procedure
8421 Write_Entity_Name outside of the body. Ignore references of types 'D'
8422 and 'I' introduced for local cross-references.
8423 (Output_Local_References): new procedure to output the local
8424 cross-references sections.
8425 (Lref_Entity_Status): new array defining whether an entity is a local
8426 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
8427 with 'I' type when initialization expression is present.
8428 * get_scos.adb, get_scos.ads: Correct comments and typos
8429
1f6439e3
AC
84302011-08-02 Javier Miranda <miranda@adacore.com>
8431
8432 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
8433 the JVM target.
8434 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
8435 the JVM target.
8436 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
8437 TSD support.
8438
84392011-08-02 Vincent Celier <celier@adacore.com>
8440
8441 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
8442 (No_Space_Img): New function
8443 (Find_Excluded_Sources): When reading from a file, record the file name
8444 and the line number for each excluded source.
8445 (Mark_Excluded_Sources): When reporting an error, if the excluded
8446 sources were read from a file, include file name and line number in
8447 the error message.
8448
84492011-08-02 Ed Schonberg <schonberg@adacore.com>
8450
8451 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
8452
ab027d28
RD
84532011-08-02 Robert Dewar <dewar@adacore.com>
8454
8455 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
8456
b3b28b0c
JM
84572011-08-02 Javier Miranda <miranda@adacore.com>
8458
8459 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
8460 generation of TSDs to the DOTNET compiler.
8461 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
8462 generation of TSDs to the DOTNET compiler.
8463
9732e886
JM
84642011-08-02 Javier Miranda <miranda@adacore.com>
8465
8466 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
8467 record of all the tagged types declared inside library level package
8468 declarations, library level package bodies or library level subprograms.
8469 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
8470 associated with a given tagged type.
8471 (Build_VM_TSDs): New subprogram.
8472 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
8473 compilation units that are subprograms.
8474 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
8475 compilation units that are package bodies.
8476 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
8477 units that are a package declaration or a package instantiation.
8478 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
8479 reorganization to improve the error generated by the frontend when the
8480 function Ada.Tags.Secondary_Tag is not available.
8481 * rtsfind.ads (RE_Register_TSD): New runtime entity.
8482 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
8483
e526d0c7
AC
84842011-08-02 Javier Miranda <miranda@adacore.com>
8485
8486 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
8487
84882011-08-02 Robert Dewar <dewar@adacore.com>
8489
8490 * s-imenne.ads: Minor reformatting.
8491
84922011-08-02 Robert Dewar <dewar@adacore.com>
8493
8494 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
8495 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
8496 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
8497
84982011-08-02 Robert Dewar <dewar@adacore.com>
8499
8500 * einfo.ads (Materialize_Entity): Document this is only for renamings
8501 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
8502 required debug information in the case where we transform the object
8503 declaration into a renaming declaration.
8504 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
8505 object
8506 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
8507 Materialize_Entity.
8508
5b1e6aca
RD
85092011-08-02 Robert Dewar <dewar@adacore.com>
8510
8511 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
8512 Suppress_Init_Procs.
8513 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
8514 Suppress_Initialization/Initialization_Suppressed.
8515 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
8516 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
8517 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
8518 * sem_prag.adb: New processing for pragma Suppress_Initialization.
8519
5ad4969d
RD
85202011-08-02 Robert Dewar <dewar@adacore.com>
8521
8522 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
8523 Minor reformatting.
8524
8c4ee6f5
AC
85252011-08-02 Ed Schonberg <schonberg@adacore.com>
8526
8527 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
8528 only have inheritable classwide pre/postconditions.
8529
85302011-08-02 Javier Miranda <miranda@adacore.com>
8531
8532 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
8533 * rtsfind.ads (RE_Check_TSD): New runtime entity.
8534 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
8535 checks if the external tag of a type is the same as the external tag
8536 of some other declaration.
8537
0b3d16c0
AC
85382011-08-02 Thomas Quinot <quinot@adacore.com>
8539
8540 * s-taskin.ads: Minor reformatting.
8541
85422011-08-02 Emmanuel Briot <briot@adacore.com>
8543
8544 * g-comlin.adb (Display_Help): swap the order in which it prints the
8545 short help and the general usage.
8546
85472011-08-02 Ed Schonberg <schonberg@adacore.com>
8548
8549 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
8550 the aspect declarations and attach them to the generic copy for
8551 subsequent analysis.
8552 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
8553 declarations of the generic tree to the new subprogram declarations.
8554 * sem_attr.adb (Check_Precondition_Postcondition): recognize
8555 conditions that apply to a subprogram instance.
8556
85572011-08-02 Robert Dewar <dewar@adacore.com>
8558
8559 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
8560
85612011-08-02 Ed Schonberg <schonberg@adacore.com>
8562
8563 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
8564 private type with a tagged full view is not derived in the immediate
8565 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
8566
4637729f
AC
85672011-08-02 Robert Dewar <dewar@adacore.com>
8568
8569 * exp_ch4.adb: Minor reformatting.
8570
85712011-08-02 Ed Schonberg <schonberg@adacore.com>
8572
8573 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
8574 Ada2012 iterator, the loop will be rewritten during expansion into a
8575 while loop with a cursor and an element declaration. Do not analyze the
8576 body in this case, because if the container is for indefinite types the
8577 actual subtype of the elements will only be determined when the cursor
8578 declaration is analyzed.
8579
85802011-08-02 Arnaud Charlet <charlet@adacore.com>
8581
8582 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
8583 size/alignment related attributes in CodePeer_Mode.
8584
85852011-08-02 Gary Dismukes <dismukes@adacore.com>
8586
8587 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
8588 Prepend_Element, since this can result in the operation getting the
8589 wrong slot in the full type's dispatch table if the full type has
8590 inherited operations. The incomplete type's operation will get added
8591 to the proper position in the full type's primitives
8592 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
8593 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
8594 dispatching operations, since there are cases where nonprimitive
8595 subprograms can get added to the list of incomplete dependents (such
8596 as subprograms in nested packages).
8597 * sem_ch6.adb (Process_Formals): First, remove test for being in a
8598 private part when determining whether to add a primitive with a
8599 parameter of a tagged incomplete type to the Private_Dependents list.
8600 Such primitives can also occur in the visible part, and should not have
8601 been excluded from being private dependents.
8602 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
8603 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
8604 list of a Taft-amendment incomplete type is a primitive before issuing
8605 an error that the full type must appear in the same unit. There are
8606 cases where nonprimitives can be in the list (such as subprograms in
8607 nested packages).
8608 * sem_disp.adb (Derives_From): Use correct condition for checking that
8609 a formal's type is derived from the type of the corresponding formal in
8610 the parent subprogram (the condition was completely wrong). Add
8611 checking that was missing for controlling result types being derived
8612 from the result type of the parent operation.
8613
4c60de0c
YM
86142011-08-02 Yannick Moy <moy@adacore.com>
8615
8616 * errout.adb (First_Node): minor renaming
8617 * restrict.adb (Check_Formal_Restriction): put restriction warning on
8618 first node.
8619
f5afb270
AC
86202011-08-02 Yannick Moy <moy@adacore.com>
8621
8622 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
8623 before accessing operands.
8624 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
8625 decide whether an initialization expression respects SPARK rules, as
8626 the plain node is the expanded one. This allows for more valid warnings
8627 to be issued.
8628 * gnat_rm.texi: Minor update.
8629
86302011-08-02 Arnaud Charlet <charlet@adacore.com>
8631
8632 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
8633 previous change.
8634
86352011-08-02 Robert Dewar <dewar@adacore.com>
8636
8637 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
8638
86392011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
8640
8641 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
8642 loop statements and the element renaming declaration with a block when
8643 the element type is controlled.
8644
86452011-08-02 Yannick Moy <moy@adacore.com>
8646
8647 * sinfo.ads: Minor formatting.
8648
86492011-08-02 Ed Schonberg <schonberg@adacore.com>
8650
8651 * sem_aggr.adb (Add_Association): if the association has a box and no
8652 expression, use the Sloc of the aggregate itself for the new
8653 association.
8654 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
8655 the Original_Node.
8656
db72f10a
AC
86572011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
8658
8659 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
8660 When a container is provided via a function call, generate a renaming
8661 of the function result. This avoids the creation of a transient scope
8662 and the premature finalization of the container.
8663 * exp_ch7.adb (Is_Container_Cursor): Removed.
8664 (Wrap_Transient_Declaration): Remove the supression of the finalization
8665 of the list controller when the declaration denotes a container cursor,
8666 it is not needed.
8667
86682011-08-02 Yannick Moy <moy@adacore.com>
8669
8670 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
8671 node is from source, instead of the original node being from source.
8672 * sem_aggr.adb
8673 (Resolve_Array_Aggregate): refine the check for a static expression, to
8674 recognize also static ranges
8675 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
8676 Array_Type_Declaration): postpone the test for the type being a subtype
8677 mark after the type has been resolved, so that component-selection and
8678 expanded-name are discriminated.
8679 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
8680 to distinguish the case of an iteration scheme, so that an error is
8681 issed on a non-static range in SPARK except in an iteration scheme.
8682 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
8683 In_Iter_Schm = True.
8684 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
8685 user-defined operators so that they are allowed in renaming
8686 * sem_ch8.adb
8687 (Find_Selected_Component): refine the check for prefixing of operators
8688 so that they are allowed in renaming. Move the checks for restrictions
8689 on selector name after analysis discriminated between
8690 component-selection and expanded-name.
8691 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
8692 concatenation argument of string type if it is static.
8693 * sem_util.adb, sem_util.ads
8694 (Check_Later_Vs_Basic_Declarations): add a new function
8695 Is_Later_Declarative_Item to decice which declarations are allowed as
8696 later items, in the two different modes Ada 83 and SPARK. In the SPARK
8697 mode, add that renamings are considered as later items.
8698 (Enclosing_Package): new function to return the enclosing package
8699 (Enter_Name): correct the rule for homonyms in SPARK
8700 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
8701 from source (result of expansion) to avoid issuing wrong warnings.
8702
87032011-08-02 Ed Schonberg <schonberg@adacore.com>
8704
8705 * errout.adb: On anything but an expression First_Node returns its
8706 argument.
8707
23685ae6
AC
87082011-08-02 Pascal Obry <obry@adacore.com>
8709
8710 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
8711
87122011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
8713
8714 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
8715 Set the associated loop as the related expression of internally
8716 generated cursors.
8717 * exp_ch7.adb (Is_Container_Cursor): New routine.
8718 (Wrap_Transient_Declaration): Supress the finalization of the list
8719 controller when the declaration denotes a container cursor.
8720
87212011-08-02 Yannick Moy <moy@adacore.com>
8722
8723 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
8724 command line now.
8725 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
8726 expression is a simple expression. This check cannot be performed in
8727 the semantics, so just drop it.
8728 (P_Index_Or_Discriminant_Constraint): move check that the index or
8729 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
8730 semantics. Other cases were previously checked in the semantics.
8731 * par-ch4.adb (P_Name): move checks that a selector name is not
8732 character literal or an operator symbol to Find_Selected_Component in
8733 the semantics
8734 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
8735 declarations are not placed after later declarations in a separate
8736 procedure in Sem_Util (possibly not the best choice?), to be used both
8737 during parsing, for Ada 83 mode, and during semantic analysis, for
8738 SPARK mode.
8739 * par-endh.adb (Check_End): move check that end label is not missing
8740 to Process_End_Label in the semantics
8741 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
8742 the special case for SPARK restriction
8743 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
8744 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
8745 parameter Force to issue the error message even on internal node (used
8746 for generated end label). Call Check_Restriction to check when an error
8747 must be issued. In SPARK mode, issue an error message even if the
8748 restriction is not set.
8749 (Check_Restriction): new procedure with an additional out parameter to
8750 inform the caller that a message has been issued
8751 * sem_aggr.adb: Minor modification of message
8752 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
8753 instead of issuing an error message directly
8754 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
8755 declarations are not placed after later declarations, by calling
8756 Check_Later_Vs_Basic_Declarations
8757 (Analyze_Subtype_Declaration): move here the check that an index or
8758 discriminant constraint must be a subtype mark. Change the check that
8759 a subtype of String must start at one so that it works on subtype marks.
8760 * sem_ch4.adb (Analyze_Call): move here the check that a named
8761 association cannot follow a positional one in a call
8762 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
8763 instead of issuing an error message directly
8764 * sem_ch8.adb (Find_Selected_Component): move here the check that a
8765 selector name is not a character literal or an operator symbol. Move
8766 here the check that the prefix of an expanded name cannot be a
8767 subprogram or a loop statement.
8768 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
8769 procedure called from parsing and semantics to check that basic
8770 declarations are not placed after later declarations
8771 (Process_End_Label): move here the check that end label is not missing
8772
87732011-08-02 Arnaud Charlet <charlet@adacore.com>
8774
8775 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
8776 representation clause in codepeer mode, since it confuses CodePeer and
8777 does not bring useful info.
8778
87792011-08-02 Ed Falis <falis@adacore.com>
8780
8781 * init.c: initialize fp hw on MILS.
8782
87832011-08-02 Ed Schonberg <schonberg@adacore.com>
8784
8785 * errout.adb (First_Node): for bodies, return the node itself (small
8786 optimization). For other nodes, do not check source_unit if the node
8787 comes from Standard.
8788
d2d9cc22
AC
87892011-08-02 Robert Dewar <dewar@adacore.com>
8790
8791 * exp_ch3.adb: Minor comment additions.
8792 * sem_ch13.adb: Minor reformatting.
8793
87942011-08-02 Pascal Obry <obry@adacore.com>
8795
8796 * make.adb, makeutl.adb: Removes some superfluous directory separator.
8797
a01b9df6
AC
87982011-08-02 Robert Dewar <dewar@adacore.com>
8799
8800 * sem_attr.adb: Minor reformatting.
8801
88022011-08-02 Robert Dewar <dewar@adacore.com>
8803
8804 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
8805 (Has_Default_Component_Value): Removed
8806 * einfo.ads Comment updates
8807 (Has_Default_Aspect): Replaces Has_Default_Value
8808 (Has_Default_Component_Value): Removed
8809 * exp_ch13.adb
8810 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
8811 * exp_ch3.adb
8812 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
8813 (Get_Simple_Init_Val): Handle Default_Value aspect
8814 (Needs_Simple_Initialization): Handle Default_Value aspect
8815 * exp_ch3.ads: Needs_Simple_Initialization
8816 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
8817 * par-prag.adb (Pragma_Default[_Component]Value) Removed
8818 * sem_ch13.adb
8819 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
8820 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
8821 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
8822
88232011-08-02 Ed Schonberg <schonberg@adacore.com>
8824
8825 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
8826 package containing iteration primitives.
8827 exp_ch5.adb (Expand_Iterator_Loop): ditto.
8828
75c90775
AC
88292011-08-02 Ed Schonberg <schonberg@adacore.com>
8830
8831 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
8832 "of", pre-analyze expression in case it is a function call with
8833 finalization actions that must be placed ahead of the loop.
8834 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
8835 on an Ada2012 iterator, insert them ahead of the rewritten loop.
8836
88372011-08-02 Geert Bosch <bosch@adacore.com>
8838
8839 * cstand.adb (Create_Float_Types): Only consider C's long double for
8840 Long_Long_Float, in addition to double.
8841
ded8909b
AC
88422011-08-02 Robert Dewar <dewar@adacore.com>
8843
8844 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
8845 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
8846 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
8847 Minor reformatting.
8848
88492011-08-02 Ed Schonberg <schonberg@adacore.com>
8850
8851 * sem_attr.adb: handle properly 'Result when it is a prefix of an
8852 indexed component.
8853
88542011-08-02 Javier Miranda <miranda@adacore.com>
8855
8856 * einfo.ads, einfo.adb
8857 (Original_Access_Type): Move this attribute to Node26 since there was
8858 an undocumented use of Node21 in E_Access_Subprogram_Type entities
8859 which causes conflicts and breaks the generation of the .NET compiler.
8860 (Interface_Name): Add missing documentation on JGNAT only uses of
8861 this attribute.
8862
70c34e1c
AC
88632011-08-02 Geert Bosch <bosch@adacore.com>
8864
8865 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
8866 (Find_Back_End_Float_Type): Likewise
8867 (Create_Back_End_Float_Types): Likewise
8868 (Create_Float_Types): Likewise
8869 (Register_Float_Type): Likewise
8870 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
8871 Nlist and split out type selection in new local Find_Base_Type function.
8872 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
8873 Nlist
8874 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
8875
88762011-08-02 Robert Dewar <dewar@adacore.com>
8877
8878 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
8879 alpha order).
8880 * opt.ads: Minor comment change.
8881 * sem_ch12.adb: Minor code reorganization.
8882
b715bc59
AC
88832011-08-02 Gary Dismukes <dismukes@adacore.com>
8884
8885 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
8886 subtype's list of rep items to the list on the full subtype in the case
8887 where the lists are the same.
8888
88892011-08-02 Geert Bosch <bosch@adacore.com>
8890
8891 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
8892 using the one from System.Strings, which also deallocates all strings.
8893
002bdd68
AC
88942011-08-02 Geert Bosch <bosch@adacore.com>
8895
8896 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
8897 function.
8898 * gcc-interface/Make-lang.in: Update dependencies.
8899
89002011-08-02 Olivier Hainque <hainque@adacore.com>
8901
8902 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
8903 end_locus.
8904
499769ec
AC
89052011-08-02 Javier Miranda <miranda@adacore.com>
8906
8907 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
8908 associated with anonymous access to subprograms.
8909
89102011-08-02 Geert Bosch <bosch@adacore.com>
8911
8912 * opt.ads
8913 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
8914 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
8915 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
8916 (Add_Symbol_Definition): Move to switch-c.adb
8917 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
8918 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
8919 (Add_Symbol_Definition): Move to switch-c.adb.
8920 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
8921 * sem_warn.adb
8922 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
8923 Move to warnsw.adb.
8924 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
8925 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
8926 Move to warnsw.adb.
8927 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
8928 (Add_Symbol_Definition): Moved from Prepcomp.
8929 * switch-c.ads: Update copyright notice. Use String_List instead of
8930 Argument_List, removing dependency on System.OS_Lib.
8931
aa1e353a
AC
89322011-08-02 Yannick Moy <moy@adacore.com>
8933
8934 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
8935 mode on initialization expression which does not respect SPARK
8936 restrictions.
8937 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
8938 if the tree referenced by its argument represents an initialization
8939 expression in SPARK, suitable for initializing an object in an object
8940 declaration.
8941
89422011-08-02 Javier Miranda <miranda@adacore.com>
8943
8944 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
8945 internally generated access to subprogram with its associated protected
8946 subprogram type.
8947 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
8948
15b682ca
GB
89492011-08-02 Geert Bosch <bosch@adacore.com>
8950
8951 * cstand.adb (Register_Float_Type): Print information about type to
8952 register, if the Debug_Flag_Dot_B is set.
8953 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
8954 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
8955 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
8956 with a requested precision of more than Max_Digits digits and no more
8957 than Max_Base_Digits digits, if a range specification is present and the
8958 Predefined_Float_Types list has a suitable type to derive from.
8959 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
8960 case of type completion with pragma Import
8961 * sem_prag.adb
8962 (Process_Import_Predefined_Type): Processing to complete a type
8963 with pragma Import. Currently supports floating point types only.
8964 (Set_Convention_From_Pragma): Do nothing without underlying type.
8965 (Process_Convention): Guard against absence of underlying type,
8966 which may happen when importing incomplete types.
8967 (Process_Import_Or_Interface): Handle case of importing predefined
8968 types. Tweak error message.
8969
f8726f2b
AC
89702011-08-02 Eric Botcazou <ebotcazou@adacore.com>
8971
8972 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
8973 functions to previous change. Reorganize code slightly.
8974
89752011-08-02 Geert Bosch <bosch@adacore.com>
8976
8977 * back_end.ads (Register_Type_Proc): New call back procedure type for
8978 allowing the back end to provide information about available types.
8979 (Register_Back_End_Types): New procedure to register back end types.
8980 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
8981 available types.
8982 * cstand.adb (Back_End_Float_Types): New list for floating point types
8983 supported by the back end.
8984 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
8985 (Copy_Float_Type): New procedure to make new copies of predefined types.
8986 (Register_Float_Type): New call back procedure to populate the BEFT list
8987 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
8988 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
8989 (Create_Float_Types): New procedure to create entities for floating
8990 point types predefined in Standard, and put these and any remaining
8991 BEFTs on the Predefined_Float_Types list.
8992 * stand.ads (Predefined_Float_Types): New list for predefined floating
8993 point types that do not have declarations in package Standard.
8994
feecad68
AC
89952011-08-02 Eric Botcazou <ebotcazou@adacore.com>
8996
8997 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
8998 entity node for the unit containing the parameter.
8999 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
9000 (Add_Inlined_Subprogram): Likewise.
9001 * gcc-interface/Make-lang.in: Update dependencies.
9002
90032011-08-02 Thomas Quinot <quinot@adacore.com>
9004
9005 * s-stusta.adb (Print): Make sure Pos is always initialized to a
9006 suitable value.
9007
12f0c50c
AC
90082011-08-02 Geert Bosch <bosch@adacore.com>
9009
9010 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
9011
90122011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9013
9014 * sem_type.adb (Covers): Move trivial case to the top and reuse the
9015 computed value of Base_Type.
9016
90172011-08-02 Yannick Moy <moy@adacore.com>
9018
9019 * restrict.adb (Check_Restriction): issue an error for any use of
9020 class-wide, even if the No_Dispatch restriction is not set.
9021 * sem_aggr.adb: Correct typos in comments and messages in formal mode
9022 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
9023 when completing a private extension, the type named in the private part
9024 is not the same as that named in the visible part.
9025 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
9026 of an inherited primitive operations of a tagged type or type extension
9027 that returns the tagged type.
9028 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
9029 function which returns True for an implicit operation inherited by the
9030 derived type declaration for the argument type.
9031 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
9032 order.
9033
fb86fe11
ES
90342011-08-02 Ed Schonberg <schonberg@adacore.com>
9035
9036 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
9037 Process_Bounds, to perform analysis with expansion of a range or an
9038 expression that is the iteration scheme for a loop.
9039 (Analyze_Iterator_Specification): If domain of iteration is given by a
9040 function call with a controlled result, as is the case if call returns
9041 a predefined container, ensure that finalization actions are properly
9042 generated.
9043 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
9044
62be5d0a
JM
90452011-08-02 Javier Miranda <miranda@adacore.com>
9046
9047 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
9048 * gcc-interface/Make-lang.in: Update dependencies.
9049
90502011-08-02 Javier Miranda <miranda@adacore.com>
9051
9052 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
9053 determine if the analysis is performed using N or Original_Node (N).
9054 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
9055 functionality of routine Is_Variable avoids code duplication.
9056 * checks.adb (Determine_Range): Handle temporaries generated by
9057 Remove_Side_Effects.
9058
90592011-08-02 Javier Miranda <miranda@adacore.com>
9060
9061 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
9062 expansion of the condition. Required since the previous analysis was
9063 done with expansion disabled (see Resolve_Quantified_Expression) and
9064 hence checks were not inserted and record comparisons have not been
9065 expanded.
9066
a20f4389
AC
90672011-08-02 Ed Falis <falis@adacore.com>
9068
9069 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
9070 Update header.
9071
90722011-08-02 Bob Duff <duff@adacore.com>
9073
9074 * opt.ads: Minor comment fix.
9075
90762011-08-02 Bob Duff <duff@adacore.com>
9077
9078 * sem_ch12.adb (Analyze_Package_Instantiation,
9079 Analyze_Subprogram_Instantiation): Turn off style checking while
9080 analyzing an instance. Whatever style checks that apply to the generic
9081 unit should apply, so it makes no sense to apply them in an instance.
9082 This was causing trouble when compiling an instance of a runtime
9083 unit that violates the -gnatyO switch.
9084 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
9085 one of the two case statements, causing spurious errors.
9086
90872011-08-02 Robert Dewar <dewar@adacore.com>
9088
9089 * uname.adb: Minor reformatting.
9090 * gnatcmd.adb: Minor reformatting.
9091 * exp_attr.adb: Minor reformatting.
9092
90878b12
AC
90932011-08-02 Ed Schonberg <schonberg@adacore.com>
9094
9095 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
9096 No_Dispatching_Calls, do not look for the Assign primitive, because
9097 predefined primitives are not created in this case.
9098
90992011-08-02 Bob Duff <duff@adacore.com>
9100
9101 * stylesw.ads: Minor comment fixes.
9102
91032011-08-02 Robert Dewar <dewar@adacore.com>
9104
9105 * freeze.adb (Add_To_Result): New procedure.
9106
91072011-08-02 Jose Ruiz <ruiz@adacore.com>
9108
9109 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
9110 time, if the specific run-time routines for handling streams of strings
9111 are not available, use the default mechanism.
9112
91132011-08-02 Arnaud Charlet <charlet@adacore.com>
9114
9115 * s-regpat.ads: Fix typo.
9116
91172011-08-02 Vincent Celier <celier@adacore.com>
9118
9119 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
9120 not null, call it to create the in memory config project file without
9121 parsing an existing default config project file.
9122
91232011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9124
9125 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
9126
91272011-08-02 Ed Schonberg <schonberg@adacore.com>
9128
9129 * sem_elim.adb: an abstract subprogram does not need an eliminate
9130 pragma for its descendant to be eliminable.
9131
91322011-08-02 Ed Falis <falis@adacore.com>
9133
9134 * init.c: revert to handling before previous checkin for VxWorks
9135 * s-intman-vxworks.adb: delete unnecessary declarations related to
9136 using Ada interrupt facilities for handling signals.
9137 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
9138 * s-intman-vxworks.ads: Import __gnat_install_handler as
9139 Initialize_Interrupts.
9140 * s-taprop-vxworks.adb: Delete Signal_Mask.
9141 (Abort_Handler): change construction of mask to unblock exception
9142 signals.
9143
273adcdf
AC
91442011-08-02 Jerome Guitton <guitton@adacore.com>
9145
9146 * a-except-2005.adb (Raise_From_Signal_Handler): Call
9147 Debug_Raise_Exception before propagation starts.
9148
91492011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9150
9151 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
9152 to Restriction_Check_Required.
9153 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
9154 * sem_res.adb (Resolve_Call): Likewise.
9155 * sem_attr.adb (Check_Stream_Attribute): Likewise.
9156
91572011-08-02 Bob Duff <duff@adacore.com>
9158
9159 * stylesw.ads: Update comment.
9160 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
9161 * errout.ads: Remove obsolete comment.
9162
91632011-08-02 Javier Miranda <miranda@adacore.com>
9164
9165 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
9166 (Set_Is_Safe_To_Reevaluate): new procedure.
9167 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
9168 assignment is allowed on safe-to-reevaluate variables.
9169 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
9170 temporary created to remove side effects in expressions that use
9171 the secondary stack as safe-to-reevaluate.
9172 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
9173 variables that are not true constants.
9174
6320f5e1
AC
91752011-08-02 Robert Dewar <dewar@adacore.com>
9176
9177 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
9178 sem_res.adb, sem_ch6.adb: Minor reformatting.
9179
91802011-08-02 Jerome Guitton <guitton@adacore.com>
9181
9182 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
9183
2fe829ae
ES
91842011-08-02 Ed Schonberg <schonberg@adacore.com>
9185
9186 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
9187 not set Overridden_Operation if subprogram is an initialization
9188 procedure.
9189
e24329cd
YM
91902011-08-02 Yannick Moy <moy@adacore.com>
9191
9192 * par-ch6.adb: Correct obsolete name in comments
9193 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
9194 which takes two message arguments (existing function takes one), with
9195 second message used for continuation.
9196 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
9197 block statements that originate from a source block statement, not
9198 generated block statements
9199 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
9200 symmetry with procedure case
9201 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
9202 function to issue an error in formal mode if a package specification
9203 contains more than one tagged type or type extension.
9204 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
9205 parameters matching formals of tagged types are objects (or ancestor
9206 type conversions of objects), not general expressions. Issue an error
9207 on view conversions that are not involving ancestor conversion of an
9208 extended type.
9209 (Resolve_Type_Conversion): in formal mode, issue an error on the
9210 operand of an ancestor type conversion which is not an object
9211 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
9212 procedure so that it works also for actuals of function calls
9213 (Is_Actual_Tagged_Parameter): new function which determines if its
9214 argument is an actual parameter of a formal of tagged type in a
9215 subprogram call
9216 (Is_SPARK_Object_Reference): new function which determines if the tree
9217 referenced by its argument represents an object in SPARK
9218
176dadf6
AC
92192011-08-02 Robert Dewar <dewar@adacore.com>
9220
9221 * sem_ch3.adb: Minor reformatting
9222 Minor comment addition
9223 Minor error msg text change
9224
92252011-08-02 Javier Miranda <miranda@adacore.com>
9226
9227 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
9228 function. Used to be more precise when we generate a variable plus one
9229 assignment to remove side effects in the evaluation of the Bound
9230 expressions.
9231 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
9232 of the bound expression to force its re-analysis and thus expand the
9233 associated transient scope (if required). Code cleanup replacing the
9234 previous code that declared the constant entity by an invocation to
9235 routine Force_Evaluation which centralizes this work in the frontend.
9236
d8b962d8
AC
92372011-08-02 Robert Dewar <dewar@adacore.com>
9238
9239 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
9240 (Base_Type): Now uses improved Is_Base_Type function
9241 * einfo.ads (Base_Type): Inline this function
9242
92432011-08-02 Robert Dewar <dewar@adacore.com>
9244
9245 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
9246 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
9247
92482011-08-02 Arnaud Charlet <charlet@adacore.com>
9249
9250 * gcc-interface/Make-lang.in: Update dependencies.
9251 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
9252 targets.
9253
92542011-08-02 Yannick Moy <moy@adacore.com>
9255
9256 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
9257 non-simple expression used in delta constraint
9258 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
9259 index constraint which is not a subtype mark
9260 * par.adb: With and use Restrict
9261 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
9262 mode on component type which is not a subtype mark and default
9263 expression on component
9264 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
9265 of string which does not have a lower index bound equal to 1
9266 (Array_Type_Declaration): issue an error in formal mode on index or
9267 component type which is not a subtype mark, and on aliased keyword on
9268 component
9269 (Derived_Type_Declaration): issue an error in formal mode on interface,
9270 limited or abstract type
9271 (Record_Type_Declaration): issue an error in formal mode on interface
9272 (Record_Type_Definition): issue an error in formal mode on tagged types
9273 and type extensions not declared in the specification of a library unit
9274 package; on null non-tagged record; on variant part
9275
92762011-08-02 Vincent Celier <celier@adacore.com>
9277
9278 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
9279 not declared for qualified library project when Library_Name is not
9280 declared, but Library_Dir is.
9281
92822011-08-02 Robert Dewar <dewar@adacore.com>
9283
9284 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
9285 pragmas (affects aspects [Component_]Default_Value
9286 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
9287 component type for the resolution
9288
f96b2d85
AC
92892011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9290
9291 * einfo.adb (Base_Type): Tune implementation for speed.
9292
92932011-08-02 Robert Dewar <dewar@adacore.com>
9294
9295 * freeze.adb: Minor reformatting.
9296
8b3c6430
AC
92972011-08-02 Thomas Quinot <quinot@adacore.com>
9298
9299 * scos.ads: Update comments.
9300
93012011-08-02 Ed Schonberg <schonberg@adacore.com>
9302
9303 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
9304 base type, because the parent may be a subtype of a private type whose
9305 convention is established in a private part.
9306
93072011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
9308
9309 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
9310 statement in a block when the expansion of the return expression has
9311 created a finalization chain.
9312 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
9313 with the parent node.
9314 Add N_Extended_Return_Statement to handle the case where a transient
9315 object declaration appears in the Return_Object_Declarations list of
9316 an extended return statement.
9317
93182011-08-02 Matthew Gingell <gingell@adacore.com>
9319
9320 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
9321 unused parameter 'name'.
9322
93232011-08-02 Ed Schonberg <schonberg@adacore.com>
9324
9325 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
9326 inherited operation, check whether its alias, which is the source
9327 operastion that it renames, has been marked eliminated.
9328
cae81f17
JM
93292011-08-02 Javier Miranda <miranda@adacore.com>
9330
9331 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
9332 in-mode parameter whose type is an access type since it can be used to
9333 modify its designated object. Enforce code that handles as safe an
9334 access type that is not access-to-constant but it is the result of a
9335 previous removal of side-effects.
9336 (Remove_Side_Effects): Minor code reorganization of cases which require
9337 no action. Done to incorporate documentation on new cases uncovered
9338 working in this ticket: no action needed if this routine was invoked
9339 too early and the nodes are not yet decorated.
9340 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
9341 to routine Remove_Side_Effects by calls to Force_Evaluation since they
9342 were issued with actuals that are implicitly provided by
9343 Force_Evaluation.
9344
218e6dee
RD
93452011-08-02 Robert Dewar <dewar@adacore.com>
9346
9347 * sem_ch3.adb, sem_res.adb: Minor reformatting.
9348
7a489a2b
AC
93492011-08-02 Yannick Moy <moy@adacore.com>
9350
9351 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
9352 to issue an error in formal mode on attribute not supported in this mode
9353 (Analyze_Attribute): issue errors on standard attributes not supported
9354 in formal mode.
9355 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
9356 comment, and issue error in formal mode on modulus which is not a power
9357 of 2.
9358 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
9359 range.
9360 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
9361 subtype mark.
9362 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
9363 operator on modular type (except 'not').
9364
93652011-08-02 Robert Dewar <dewar@adacore.com>
9366
9367 * gnat_rm.texi: Minor reformatting.
9368
cb7fa356
AC
93692011-08-02 Arnaud Charlet <charlet@adacore.com>
9370
9371 * s-osinte-linux.ads: Minor comment update and reformatting.
9372 * i-cexten.ads: Make this unit pure, as for its parent.
9373 Will allow its usage in more contexts if needed.
9374
93752011-08-02 Robert Dewar <dewar@adacore.com>
9376
9377 * s-utf_32.ads: Minor comment fix.
9378
93792011-08-02 Ed Schonberg <schonberg@adacore.com>
9380
9381 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
9382 operation of a tagged synchronized type, handle the case where the
9383 controlling argument is overloaded.
9384
93852011-08-02 Yannick Moy <moy@adacore.com>
9386
9387 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
9388 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
9389 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
9390 SPARK mode and formal verification mode on processing SPARK restriction
9391 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
9392 requiring consistency checking.
9393
5cc9353d
RD
93942011-08-02 Robert Dewar <dewar@adacore.com>
9395
9396 * sem_res.adb: Minor reformatting.
9397
e51537ff
RD
93982011-08-02 Robert Dewar <dewar@adacore.com>
9399
9400 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
9401 a-cforse.ads: Remove unneeded with of Ada.Containers
9402 Remove commented out pragma Inline's
9403 Move specifications of new subprograms to the actual specs
9404
83fa09c5
AC
94052011-08-02 Yannick Moy <moy@adacore.com>
9406
9407 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
9408 a-cforse.ads: Update comments.
9409
94102011-08-02 Ed Schonberg <schonberg@adacore.com>
9411
9412 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
9413
d11cfaf8
RD
94142011-08-02 Robert Dewar <dewar@adacore.com>
9415
9416 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
9417 a-cforse.ads, a-cofove.ads: Minor reformatting.
9418
300b98bb
AC
94192011-08-02 Claire Dross <dross@adacore.com>
9420
9421 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
9422 a-cofove.ads: Add comments.
9423
94242011-08-02 Yannick Moy <moy@adacore.com>
9425
9426 * gnat_rm.texi: Document formal containers.
9427
94282011-08-02 Emmanuel Briot <briot@adacore.com>
9429
9430 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
9431 are empty sections.
9432
19fb051c
AC
94332011-08-02 Robert Dewar <dewar@adacore.com>
9434
9435 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
9436 reformatting.
9437
94382011-08-02 Robert Dewar <dewar@adacore.com>
9439
9440 * aspects.adb: New aspects Default_Value and Default_Component_Value
9441 New format of Aspect_Names table checks for omitted entries
9442 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
9443 handling of boolean aspects for derived types.
9444 New aspects Default_Value and Default_Component_Value
9445 New format of Aspect_Names table checks for omitted entries
9446 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
9447 (Has_Default_Value): New flag
9448 (Has_Default_Component_Value): New flag
9449 (Has_Default_Value): New flag
9450 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
9451 table.
9452 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
9453 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
9454 Default_Value and Default_Component_Value
9455 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
9456 New aspects Default_Value and Default_Component_Value
9457 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
9458 * sprint.adb: Print N_Aspect_Specification node when called from gdb
9459
94602011-08-02 Vincent Celier <celier@adacore.com>
9461
9462 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
9463 inherit library kind.
9464
94652011-08-02 Ed Schonberg <schonberg@adacore.com>
9466
9467 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
9468 Minor reformatting.
9469
94702011-08-02 Robert Dewar <dewar@adacore.com>
9471
9472 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
9473
5f7747af
AC
94742011-08-02 Yannick Moy <moy@adacore.com>
9475
9476 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
9477
94782011-08-02 Robert Dewar <dewar@adacore.com>
9479
9480 * impunit.adb: Add comment.
9481
a5fe697b
AC
94822011-08-02 Yannick Moy <moy@adacore.com>
9483
9484 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
9485 qualification of aggregates in formal mode
9486 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
9487 another aggregate
9488 (Resolve_Aggregate): complete the test that an aggregate is adequately
9489 qualified in formal mode
9490
94912011-08-02 Pascal Obry <obry@adacore.com>
9492
9493 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
9494 * mlib-prj.adb: Supress warning when compiling binder generated file.
9495 (Build_Library): Supress all warnings when compiling the binder
9496 generated file.
9497
bd65a2d7 94982011-08-02 Yannick Moy <moy@adacore.com>
d4487611 9499
bd65a2d7
AC
9500 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
9501 from here...
9502 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
9503 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
9504 Add with/use clauses to make Check_Formal_Restriction visible
9505
95062011-08-02 Ed Schonberg <schonberg@adacore.com>
9507
9508 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
9509 in-parameters when type of the generic formal is private in the generic
9510 spec and non-private in the body.
9511
95122011-08-02 Claire Dross <dross@adacore.com>
9513
9514 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
9515 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
9516 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
9517 * impunit.adb, Makefile.rtl: Take new files into account.
d4487611
AC
9518
95192011-08-02 Robert Dewar <dewar@adacore.com>
9520
9521 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
9522 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
9523
bd434b3f
YM
95242011-08-02 Yannick Moy <moy@adacore.com>
9525
9526 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
9527 formal mode
9528 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
9529 matching static array bounds, taking into account the special case of
9530 string literals
9531 * sem_ch3.adb: Typo in comment.
9532
fe5d3068
YM
95332011-08-02 Yannick Moy <moy@adacore.com>
9534
9535 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
9536 which issues an error in formal mode if its argument node is originally
9537 from source
9538 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
9539 has a discriminant specification so that it does not include the case
9540 of derived types
9541 (Derived_Type_Declaration): move here the test that a derived type has a
9542 discriminant specification
9543 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
9544 first element of a component association before accessing its choices
9545 (presence of component association is not enough)
9546 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
9547 declaration is a library item before accessing the next element in a
9548 list, as library items are not member of lists
9549 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
9550 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
9551 Check_Formal_Restriction whenever possible.
9552
b60a3f26
AC
95532011-08-02 Ed Schonberg <schonberg@adacore.com>
9554
9555 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
9556 reference when needed.
9557
95582011-08-02 Bob Duff <duff@adacore.com>
9559
9560 * gnat_ugn.texi: Fix typo.
9561
95622011-08-02 Vincent Celier <celier@adacore.com>
9563
9564 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
9565 archive file name. Do not use the full path name of archives for Open
9566 VMS.
9567
eaba57fb
RD
95682011-08-02 Robert Dewar <dewar@adacore.com>
9569
9570 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
9571 Analyze_Aspect_Specifications
9572 * sem_ch13.adb
9573 (Analyze_Aspect_Specifications): New handling for boolean aspects
9574 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
9575 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
9576 sequence for Analyze_Aspect_Specifications
9577 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
9578 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
9579
95802011-08-02 Robert Dewar <dewar@adacore.com>
9581
9582 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
9583 aspects, since these no longer exist.
9584
95852011-08-02 Robert Dewar <dewar@adacore.com>
9586
9587 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
9588 semicolon, do not try to see if there are aspects following it.
9589 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
9590 aspect spec.
9591
8830d1d2
AC
95922011-08-02 Robert Dewar <dewar@adacore.com>
9593
9594 * sem_ch8.adb, aspects.ads: Minor reformatting.
9595
95962011-08-02 Eric Botcazou <ebotcazou@adacore.com>
9597
9598 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
9599 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
9600 extracted from...
9601 (Analyze_Aspect_Specifications): ...here. Call above procedure.
9602
7ff2d234
AC
96032011-08-02 Yannick Moy <moy@adacore.com>
9604
9605 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
9606 mode on subprogram declaration outside of package specification, unless
9607 it is followed by a pragma Import
9608 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
9609 Access_Type_Declaration): issue error in formal mode on access type
9610 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
9611 incomplete type
9612 (Analyze_Object_Declaration): issue error in formal mode on object
9613 declaration which does not respect SPARK restrictions
9614 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
9615 declaration which does not respect SPARK restrictions
9616 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
9617 error in formal mode on digits or delta constraint
9618 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
9619 decimal fixed point type
9620 (Derived_Type_Declaration): issue error in formal mode on derived type
9621 other than type extensions of tagged record types
9622 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
9623 with check on access definition
9624 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
9625 mode on protected definition.
9626 (Analyze_Task_Definition): issue error in formal mode on task definition
9627
96282011-08-02 Robert Dewar <dewar@adacore.com>
9629
9630 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
9631
806f6d37
AC
96322011-08-02 Javier Miranda <miranda@adacore.com>
9633
9634 * sem_ch6.adb (Can_Override_Operator): New function.
9635 (Verify_Overriding_Indicator): Add missing code to check overriding
9636 indicator in operators. Fixes regression.
9637 (Check_Overriding_Indicator): Minor reformating after replacing the
9638 code that evaluates if the subprogram can override an operator by
9639 invocations to the above new function.
9640 * einfo.adb
9641 (Write_Field26_Name): Add missing code to ensure that, following
9642 the documentation in einfo.ads, this field is not shown as attribute
9643 "Static_Initialization" on non-dispatching functions.
9644
96452011-08-02 Jose Ruiz <ruiz@adacore.com>
9646
9647 * sem_res.adb (Resolve_Call): A call to
9648 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
9649 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
9650 i.e., when the second parameter is of type Time_Span.
9651
96522011-08-02 Vincent Celier <celier@adacore.com>
9653
9654 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
9655 with an archive instead of -L<library dir> -l<library name>.
9656
96572011-08-02 Ed Schonberg <schonberg@adacore.com>
9658
9659 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
9660 mark the base types In_Use in addition to making the operations
9661 use_visible.
9662
96632011-08-02 Ed Falis <falis@adacore.com>
9664
9665 * init.c: add and setup __gnat_signal_mask for the exception signals
9666 * s-inmaop-vxworks.adb: new file.
9667 * s-intman-vxworks.adb: remove unnecessary initializations and
9668 simplify remaining
9669 * s-intman-vxworks.ads: remove unnecessary variable
9670 * s-taprop-vxworks.adb: simplify signal initialization
9671
780d052e
RD
96722011-08-02 Robert Dewar <dewar@adacore.com>
9673
9674 * sem_ch8.adb: Minor code reorganization, comment updates.
9675
96762011-08-02 Robert Dewar <dewar@adacore.com>
9677
9678 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
9679 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
9680 here from Sem_Res.
9681 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
9682 (Matching_Static_Array_Bounds): Moved here from Sem_Res
9683
29efbb8c
ES
96842011-08-02 Ed Schonberg <schonberg@adacore.com>
9685
9686 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
9687 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
9688 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
9689 use_type_clauses, to handle more efficiently use_type and use_all_type
9690 constructs.
9691 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
9692 Ada2012 Use_All_Type clause.
9693 (Use_Class_Wide_Operations): new procedure.
9694
b0186f71
AC
96952011-08-02 Robert Dewar <dewar@adacore.com>
9696
9697 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
9698 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
9699 expression to expression function.
9700
97012011-08-02 Ed Schonberg <schonberg@adacore.com>
9702
9703 * sem_ch4.adb: transform simple Ada2012 membership into equality only
9704 if types are compatible.
9705
97062011-08-02 Yannick Moy <moy@adacore.com>
9707
9708 * sem_res.adb (Matching_Static_Array_Bounds): new function which
9709 returns True if its argument array types have same dimension and same
9710 static bounds at each index.
9711 (Resolve_Actuals): issue an error in formal mode on actuals passed as
9712 OUT or IN OUT paramaters which are not view conversions in SPARK.
9713 (Resolve_Arithmetic_Op): issue an error in formal mode on
9714 multiplication or division with operands of fixed point types which are
9715 not qualified or explicitly converted.
9716 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
9717 Boolean or array type (except String) operands.
9718 (Resolve_Equality_Op): issue an error in formal mode on equality
9719 operators for array types other than String with non-matching static
9720 bounds.
9721 (Resolve_Logical_Op): issue an error in formal mode on logical operators
9722 for array types with non-matching static bounds. Factorize the code in
9723 Matching_Static_Array_Bounds.
9724 (Resolve_Qualified_Expression): issue an error in formal mode on
9725 qualified expressions for array types with non-matching static bounds.
9726 (Resolve_Type_Conversion): issue an error in formal mode on type
9727 conversion for array types with non-matching static bounds
9728
767bb4e8
AC
97292011-08-02 Robert Dewar <dewar@adacore.com>
9730
9731 * par-ch10.adb: Minor code reorganization (use Nkind_In).
9732
97332011-08-02 Ed Schonberg <schonberg@adacore.com>
9734
9735 * par-ch9.adb: save location of entry for proper error message.
9736
4ac2477e
JM
97372011-08-02 Javier Miranda <miranda@adacore.com>
9738
9739 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
9740 (Use_Full_View) which permits this routine to climb through the
9741 ancestors using the full-view of private parents.
9742 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
9743 Use_Full_View to true in calls to Is_Ancestor.
9744 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
9745 true in call to Is_Ancestor.
9746 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
9747 Use_Full_View to true in call to Is_Ancestor.
9748 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
9749 call to Is_Ancestor.
9750 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
9751 Use_Full_View to true in calls to Is_Ancestor.
9752 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
9753 Make_Select_Specific_Data_Table, Register_Primitive,
9754 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
9755 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
9756 to true in call to Is_Ancestor.
9757 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
9758 Use_Full_View to true in calls to Is_Ancestor.
9759 * exp_cg.adb
9760 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
9761 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
9762
9f90d123
AC
97632011-08-02 Robert Dewar <dewar@adacore.com>
9764
9765 * gnat_rm.texi: Minor reformatting.
9766 * sem_prag.adb: Minor reformatting.
9767
97682011-08-02 Tristan Gingold <gingold@adacore.com>
9769
9770 * vms_data.ads: Add VMS qualifier for -gnateP.
9771
97722011-08-02 Robert Dewar <dewar@adacore.com>
9773
9774 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
9775 * par-ch7.adb (P_Package): Proper placement of aspects for package
9776 decl/instantiation.
9777 * par-endh.adb (Check_End): Ad Is_Sloc parameter
9778 (End_Statements): Add Is_Sloc parameterr
9779 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
9780 (Check_End): Ad Is_Sloc parameter
9781 (End_Statements): Add Is_Sloc parameterr
9782
97832011-08-02 Vincent Celier <celier@adacore.com>
9784
9785 * ug_words: Add VMS qualifier equivalent to -gnateP:
9786 /SYMBOL_PREPROCESSING.
9787
97882011-08-02 Jose Ruiz <ruiz@adacore.com>
9789
9790 * gnat-style.texi: For hexadecimal numeric literals the typical
9791 grouping of digits is 4 to represent 2 bytes.
9792 A procedure spec which is split into several lines is indented two
9793 characters.
9794
97952011-08-02 Yannick Moy <moy@adacore.com>
9796
9797 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
9798 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
9799 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
9800 properly qualified
9801 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
9802 choice in array aggregate
9803 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
9804 mark as ancestor
9805 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
9806 positional and named aggregate for record, or others in record
9807 aggregate, or multiple choice in record aggregate
9808 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
9809 array operands to logical operations AND, OR and XOR do not have the
9810 same static lower and higher bounds
9811 * sem_ch5.adb, sinfo.ads: Correct typos in comments
9812
2933b16c
RD
98132011-08-01 Robert Dewar <dewar@adacore.com>
9814
9815 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
9816 Replaces Last_Source_Node_In_Sequence.
9817 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
9818 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
9819 parens and blank in string (this was inconsistently implemented).
9820 * errout.ads
9821 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
9822 blank in string (this was inconsistently implemented).
9823 * gnat1drv.adb
9824 (Set_Global_Switches): Set formal mode switches appropriately
9825 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
9826 * par-prag.adb
9827 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
9828 call Set_Error_Msg_Lang to set "spark" as language name.
9829 * par.adb: Remove unnecessary call to set formal language for errout
9830 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
9831 appropriately and call Set_Error_Msg_Lang to set "spark" as language
9832 name.
9833 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
9834 calls to it, moved after resolution so that types are known
9835 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
9836 result of concatenation is not of type String
9837 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
9838 concatenation is not properly restricted
9839 * gnat_rm.texi: Add doc on pragma Spark_95.
9840 * gcc-interface/Makefile.in: Remove obsolete target pairs for
9841 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
9842 * gcc-interface/Make-lang.in: Update dependencies.
9843
05dbd302
AC
98442011-08-01 Javier Miranda <miranda@adacore.com>
9845
9846 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
9847 condition that detects if the overridden operation must replace an
9848 existing entity.
9849
98502011-08-01 Javier Miranda <miranda@adacore.com>
9851
9852 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
9853 code declarations inserted by Insert_Actions in each alternative of the
9854 N_Case_Expression node.
9855
98562011-08-01 Robert Dewar <dewar@adacore.com>
9857
9858 * sem_ch6.adb: Minor code reorganization.
9859 * sem_util.adb: Minor reformatting.
9860
af9e051f
PO
98612011-08-01 Pascal Obry <obry@adacore.com>
9862
9863 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
9864 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
9865
1d801f21
AC
98662011-08-01 Yannick Moy <moy@adacore.com>
9867
9868 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
9869 literal or operator symbol which is prefixed
9870 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
9871 mode on access attributes.
9872 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
9873 that concatenation operands are properly restricted in formal mode
9874 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
9875 Analyze_Concatenation_Operand. Issue an error in formal mode if the
9876 result of the concatenation has a type different from String.
9877 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
9878 Analyze_Quantified_Expression, Analyze_Slice,
9879 Analyze_Null): issue an error in formal mode on unsupported constructs
9880 * sem_ch5.adb
9881 (Analyze_Block_Statement): only issue error on source block statement
9882 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
9883 function which returns the last node in a list of nodes for which
9884 Comes_From_Source returns True, if any
9885 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
9886 Last_Source_Node_In_Sequence
9887 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
9888 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
9889 mode on unsupported constructs
9890 * sem_ch9.adb Do not return after issuing error in formal mode, as the
9891 rest of the actions may be needed later on since the error is marked as
9892 not serious.
9893 * sinfo.ads: Typos in comments.
9894
98952011-08-01 Pascal Obry <obry@adacore.com>
9896
9897 * projects.texi: Minor editing.
9898
53beff22
YM
98992011-08-01 Yannick Moy <moy@adacore.com>
9900
9901 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
9902 insertion character ~~
9903 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
9904 (Set_Error_Msg_Lang): new procedure which fixes the language for use
9905 with insertion character ~~
9906 (Set_Msg_Text): treat insertion character ~~
9907 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
9908 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
9909 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
9910 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
9911 errors related to the formal language restriction not serious
9912 (insertion character |).
9913 * par.adb (Par): set formal language for error messages if needed
9914 * sem_ch6.adb (Check_Missing_Return): take into account possible
9915 generated statements at the end of the function
9916 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
9917 enumeration value to define a new pragma SPARK_95
9918 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
9919 SPARK_Version): new type and variables to store the SPARK version
9920 (none by default).
9921 (SPARK_Mode): return True when SPARK_Version is set
9922 * par-prag.adb: Correct indentation
9923 (Prag): take Pragma_SPARK_95 into account
9924 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
9925 into account.
9926
8d606a78
RD
99272011-08-01 Robert Dewar <dewar@adacore.com>
9928
9929 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
9930 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
9931 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
9932
1982d5a8
PO
99332011-08-01 Pascal Obry <obry@adacore.com>
9934
9935 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
9936 Target_Name to Get_Path call.
9937 (Parse_Single_Project): Likewise.
9938 (Post_Parse_Context_Clause): Likewise.
9939 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
9940 Call Initialise_Project_Path with the proper Target_Name.
9941 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
9942 search path.
9943 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
9944 with the proper Target_Name.
9945 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
9946 Part.Parse routine.
9947 (Parse_Project_And_Apply_Config): Likewise.
9948 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
9949 This is fine as this part of the code is supporting only native
9950 compilation.
9951 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
9952 is fine as this part of the code is supporting only native compilation.
9953
0d53d36b
AC
99542011-08-01 Yannick Moy <moy@adacore.com>
9955
9956 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
9957 of homonym, unless the homonym is one of the cases allowed in SPARK
9958 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
9959 package declaration occurring after a body.
9960
99612011-08-01 Robert Dewar <dewar@adacore.com>
9962
9963 * checks.adb, exp_ch4.adb: Minor reformatting.
9964
99652011-08-01 Javier Miranda <miranda@adacore.com>
9966
9967 * einfo.ads (Access_Disp_Table): Fix documentation.
9968 (Dispatch_Table_Wrappers): Fix documentation.
9969
99702011-08-01 Pascal Obry <obry@adacore.com>
9971
9972 * prj-env.adb, prj-env.ads: Minor reformatting.
9973
8ed68165
AC
99742011-08-01 Yannick Moy <moy@adacore.com>
9975
9976 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
9977 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
9978 procedures out of these packages.
2c7f9cc0 9979 * errout.ads, errout.adb
8ed68165
AC
9980 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
9981 procedures in of this package
9982 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
9983 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
9984 on misplaced later vs initial declarations, like in Ada 83
9985 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
9986 formal mode on attribute of private type whose full type declaration
9987 is not visible
9988 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
9989 package declaration inside a package specification
9990 (Analyze_Full_Type_Declaration): issue error in formal mode on
9991 controlled type or discriminant type
9992 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
9993 user-defined operator means that it should come from the source
9994 (New_Overloaded_Entity): issue error in formal mode on overloaded
9995 entity.
9996 * sem_ch6.ads, sem_ch13.ads: typos in comments.
9997
99982011-08-01 Thomas Quinot <quinot@adacore.com>
9999
10000 * atree.adb: Minor reformatting.
10001 * checks.adb: Minor reformatting.
10002
4230bdb7
AC
100032011-08-01 Vincent Celier <celier@adacore.com>
10004
10005 * s-parame-vms-ia64.ads: Fix typo in comment
10006 Minor reformatting
10007 * s-parame-vms-restrict.ads: Removed, unused.
10008
100092011-08-01 Javier Miranda <miranda@adacore.com>
10010
10011 * exp_ch3.adb
10012 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
10013 * sem_ch3.adb
10014 (Constrain_Index): Remove side effects in the evaluation of the bounds.
10015 * sem_ch3.ads, sem_ch3.adb
10016 (Is_Constant_Bound): New extended version of the subprogram that was
10017 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
10018 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
10019 * sem_aux.ads (Constant_Value): Fix typo in comment.
10020 * checks.adb (Generate_Index_Checks): New implementation which, for
10021 array objects with constant bounds, generates the runtime check
10022 referencing the bounds of the array type. For other cases this routine
10023 provides its previous behavior obtaining such values from the array
10024 object.
10025 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
10026 parent type.
10027 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
10028 we cannot have semantic interpretations of the new node.
10029
2010d078
AC
100302011-08-01 Ed Schonberg <schonberg@adacore.com>
10031
10032 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
10033 expressions.
10034
100352011-08-01 Arnaud Charlet <charlet@adacore.com>
10036
10037 * sem_ch8.adb: Minor code editing.
10038 * s-vxwext.adb: Remove trailing space.
10039 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
10040 consistency with other files.
10041
100422011-08-01 Thomas Quinot <quinot@adacore.com>
10043
10044 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
10045
100462011-08-01 Ed Schonberg <schonberg@adacore.com>
10047
10048 * par-ch10.adb: reject parameterized expressions as compilation unit.
10049 * sem_ch4.adb: handle properly conditional expression with overloaded
10050 then_clause and no else_clause.
10051
100522011-08-01 Tristan Gingold <gingold@adacore.com>
10053
10054 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
10055 like done by System.Aux_DEC.
10056 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
10057
daec8eeb
YM
100582011-08-01 Yannick Moy <moy@adacore.com>
10059
10060 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
10061 missing label at end of declaration (subprogram or package)
10062 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
10063 of positional and named parameter association
10064 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
10065 Error_Msg_SP which adds a prefix to the error message giving the name
10066 of the formal language analyzed
10067 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
10068 access result type in subprogram, unconstrained array as result type,.
10069 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
10070 procedure
10071 * sem_ch8.adb: Code clean up.
10072
38171f43
AC
100732011-08-01 Javier Miranda <miranda@adacore.com>
10074
10075 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
10076 * einfo.ads (Access_Disp_Table): Fix documentation.
10077 (Dispatch_Table_Wrappers): Fix documentation.
10078 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
10079 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
10080 to enforce the documentation of this attribute.
10081 (Set_Is_Interface): Cleanup the assertion.
10082 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
10083 the Underlying_Type entity before reading attribute Access_Disp_Table.
10084 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
10085 Locate the Underlying_Type before reading attribute Access_Disp_Table.
10086 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
10087 the Underlying_Type entity before reading attribute Access_Disp_Table.
10088 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
10089 Locate the Underlying_Type entity before reading attribute
10090 Access_Disp_Table.
10091
100922011-08-01 Ed Schonberg <schonberg@adacore.com>
10093
10094 * s-poosiz.ads: Additional overriding indicators.
10095
100962011-08-01 Yannick Moy <moy@adacore.com>
10097
10098 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
10099 formal mode.
10100 (Analyze_Iteration_Scheme): issue error in formal mode when loop
10101 parameter specification does not include a subtype mark.
10102 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
10103 formal mode on abstract subprogram.
10104 (Analyze_Subprogram_Specification): issue error in formal mode on
10105 user-defined operator.
10106 (Process_Formals): issue error in formal mode on access parameter and
10107 default expression.
10108 * sem_ch9.adb (Analyze_Abort_Statement,
10109 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
10110 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
10111 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
10112 Analyze_Requeue, Analyze_Selective_Accept,
10113 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
10114 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
10115 issue error in formal mode on user-defined raise statement.
10116
1f250383
AC
101172011-08-01 Thomas Quinot <quinot@adacore.com>
10118
10119 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
10120 declaration being hidden when overriding an implicit inherited
10121 subprogram.
10122 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
10123 (-gnats), do not complain about a source file that contains only a
10124 pragma No_Body.
10125
101262011-08-01 Ed Schonberg <schonberg@adacore.com>
10127
10128 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
10129 variable if already set.
10130
607d0635
AC
101312011-08-01 Arnaud Charlet <charlet@adacore.com>
10132
10133 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
10134 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
10135 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
10136 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
10137 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
10138 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
10139 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
10140 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
10141 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
10142 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
10143 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
10144 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
10145 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
10146 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
10147 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
10148 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
10149 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
10150 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
10151 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
10152 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
10153 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
10154 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
10155 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
10156 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
10157 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
10158 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
10159 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
10160 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
10161 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
10162 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
10163 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
10164 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
10165 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
10166 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
10167 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
10168 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
10169 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
10170 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
10171 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
10172 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
10173 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
10174 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
10175 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
10176 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
10177 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
10178 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
10179 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
10180 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
10181 s-osinte-mingw.ads: Update to GPLv3 run-time license.
10182 Use GNAT instead of GNARL.
10183
101842011-08-01 Bob Duff <duff@adacore.com>
10185
10186 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
10187 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
10188 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
10189 reformatting.
10190
101912011-08-01 Yannick Moy <moy@adacore.com>
10192
10193 * debug.adb (d.D) reverve flag for the SPARK mode
10194 (d.E) reverve flag for SPARK generation mode
10195 (d.F) reverve flag for Why generation mode
2c7f9cc0 10196 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
607d0635
AC
10197 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
10198 functions which return True when the corresponding modes are set
10199 (Formal_Language): return "spark" or "alfa" when in formal verification
10200 mode.
10201 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
10202 Error_Msg to prefix the error message with a tag giving the formal
10203 language
10204 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
10205 message with a tag giving the formal language
10206 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
10207 block statement
10208 (Analyze_Case_Statement): issue error in formal mode on case statement
10209 with a single "others" case alternative
10210 (Analyze_Exit_Statement): issue errors in formal mode on exit
10211 statements which do not respect SPARK restrictions
10212 (Analyze_Goto_Statement): issue error in formal mode on goto statement
10213 (Check_Unreachable_Code): always issue an error (not a warning) in
10214 formal mode on unreachable code (concerns both code after an infinite
10215 loop and after an unconditional jump, both not allowed in SPARK)
10216 * sem_ch6.adb (Analyze_Return_Statement): add call to
10217 Set_Return_Present for a procedure containing a return statement
10218 (already done for functions in Analyze_Function_Return)
10219 (Analyze_Function_Return): issue error in formal mode on extended
10220 return or if return is not last statement in function
10221 (Check_Missing_Return): issue error in formal mode if function does
10222 not end with return or if procedure contains a return
10223 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
10224 function to detect if there is an inner scope of its parameter S which
10225 is a loop.
10226
102272011-08-01 Thomas Quinot <quinot@adacore.com>
10228
10229 * sem_ch6.ads: Minor reformatting.
10230
d8b3ccb9
AC
102312011-08-01 Javier Miranda <miranda@adacore.com>
10232
10233 * sem_util.adb (Abstract_Interface_List): Complete condition when
10234 processing private type declarations to avoid reading unavailable
10235 attribute.
10236 (Is_Synchronized_Tagged_Type): Complete condition when processing
10237 private extension declaration nodes to avoid reading unavailable
10238 attribute.
10239
102402011-08-01 Thomas Quinot <quinot@adacore.com>
10241
10242 * sem_ch3.adb: Minor reformatting.
10243
102442011-08-01 Thomas Quinot <quinot@adacore.com>
10245
10246 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
10247 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
10248 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
10249 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
10250 for VMS, instead parametrize the common implementation with
10251 System.Parameters declarations.
10252
0bb9276c
AC
102532011-08-01 Eric Botcazou <ebotcazou@adacore.com>
10254
10255 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
10256
102572011-08-01 Tristan Gingold <gingold@adacore.com>
10258
10259 * seh_init.c: Fix SEH handler installation on win64.
10260
102612011-08-01 Ed Schonberg <schonberg@adacore.com>
10262
10263 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
10264 double analysis of an anonymous access to subprogram, because it can
10265 lead to improper sharing of profiles and a back-end crash.
10266
6a2e4f0b
AC
102672011-08-01 Robert Dewar <dewar@adacore.com>
10268
10269 * make.adb, sem_ch4.adb: Minor reformatting.
10270 * gcc-interface/Make-lang.in: Update dependencies.
10271 * sem_util.adb, exp_ch5.adb: Minor reformatting.
10272
102732011-08-01 Arnaud Charlet <charlet@adacore.com>
10274
10275 * gnat_rm.texi: Fix definition of Long_Integer.
10276
102772011-08-01 Ed Schonberg <schonberg@adacore.com>
10278
10279 * exp_aggr.adb: check limit size of static aggregate unconditionally,
10280 to prevent storage exhaustion.
10281 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
10282 finalized is a function body, insert the cleanup code before the final
10283 return statement, to prevent spurious warnings.
10284 * s-pooglo.ads: add overriding indicator.
10285
4561baf7
ES
102862011-08-01 Ed Schonberg <schonberg@adacore.com>
10287
10288 * sem_ch4.adb (Operator_Check): improve error message when both a
10289 with_clause and a use_clause are needed to make operator usage legal.
10290 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
10291 determine whether a compilation unit is visible within an other,
10292 either through a with_clause in the current unit, or a with_clause in
10293 its library unit or one one of its parents.
10294
383e179e
AC
102952011-08-01 Ed Schonberg <schonberg@adacore.com>
10296
10297 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
10298 over an arbitrary expression of an array or container type.
10299 * lib-xref.adb: clarify comment.
10300
103012011-08-01 Bob Duff <duff@adacore.com>
10302
10303 * einfo.ads: Minor reformatting.
10304 * debug.adb: Minor comment improvement.
10305
103062011-08-01 Javier Miranda <miranda@adacore.com>
10307
10308 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
10309 consider hidden subprograms as valid candidates.
10310
103112011-08-01 Arnaud Charlet <charlet@adacore.com>
10312
10313 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
10314
103152011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
10316
10317 * gnat_ugn.texi: Fix typo.
10318
61c161b2
AC
103192011-08-01 Robert Dewar <dewar@adacore.com>
10320
10321 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
10322 lib-xref.adb: Minor reformatting
10323
103242011-08-01 Gary Dismukes <dismukes@adacore.com>
10325
10326 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
10327 when to generate a call to Move_Final_List.
10328 (Has_Controlled_Parts): Remove this function.
10329
84df40f7
AC
103302011-08-01 Geert Bosch <bosch@adacore.com>
10331
10332 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
10333 "," in choice list.
10334
103352011-08-01 Thomas Quinot <quinot@adacore.com>
10336
10337 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
10338 explicit raise of a predefined exception as Comes_From_Source if the
10339 original N_Raise_Statement comes from source.
10340
103412011-08-01 Robert Dewar <dewar@adacore.com>
10342
10343 * sinfo.ads: Add comment.
10344 * sem_ch6.adb: Minor reformatting.
10345
103462011-08-01 Robert Dewar <dewar@adacore.com>
10347
10348 * freeze.adb (Freeze_Entity): Refine check for bad component size
10349 clause to avoid rejecting confirming clause when atomic/aliased present.
10350
103512011-08-01 Ed Schonberg <schonberg@adacore.com>
10352
10353 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
10354 better determine whether an entity reference is a write.
10355 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
10356 subcomponent.
10357 * lib-xref.adb (Output_References): Do no suppress a read reference at
10358 the same location as an immediately preceeding modify-reference, to
10359 handle properly in-out actuals.
10360
103612011-08-01 Tristan Gingold <gingold@adacore.com>
10362
10363 * env.c (__gnat_setenv) [VMS]: Refine previous change.
10364
103652011-08-01 Quentin Ochem <ochem@adacore.com>
10366
10367 * i-cstrin.adb (New_String): Changed implementation, now uses only the
10368 heap to compute the result.
10369
c7f0d2c0
AC
103702011-08-01 Robert Dewar <dewar@adacore.com>
10371
10372 * atree.ads: Minor reformatting.
10373
103742011-08-01 Emmanuel Briot <briot@adacore.com>
10375
10376 * g-expect.adb (Get_Command_Output): Fix memory leak.
10377
103782011-08-01 Geert Bosch <bosch@adacore.com>
10379
10380 * cstand.adb (P_Float_Type): New procedure to print the definition of
10381 predefined fpt types.
10382 (P_Mixed_Name): New procedure to print a name using mixed case
10383 (Print_Standard): Use P_Float_Type for printing floating point types
10384 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
10385 precision IEEE float.
10386
103872011-08-01 Thomas Quinot <quinot@adacore.com>
10388
10389 * sem_ch3.adb: Minor reformatting.
10390
103912011-08-01 Ed Schonberg <schonberg@adacore.com>
10392
10393 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
10394 the completion of a generic function, insert the new body rather than
10395 rewriting the original.
10396
103972011-08-01 Yannick Moy <moy@adacore.com>
10398
10399 * sinfo.ads, errout.ads: Typos in comments.
10400
1c54829e
AC
104012011-08-01 Robert Dewar <dewar@adacore.com>
10402
10403 * par-endh.adb: Minor reformatting.
10404
104052011-08-01 Robert Dewar <dewar@adacore.com>
10406
10407 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
10408 (Pre_Post_Aspects): New subtype.
10409 * par-ch12.adb (P_Generic): New syntax for aspects in packages
10410 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
10411 * par-ch7.adb (P_Package): Remove Decl parameter
10412 (P_Package): Handle new syntax for aspects (before IS)
10413 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
10414 new aspect syntax
10415 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
10416 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
10417 (P_Package): Remove Decl parameter
10418 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
10419 aspects
10420 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
10421 specs
10422 * sem_util.ads, sem_util.adb (Static_Boolean): New function
10423 * sinfo.ads: Document new syntax for aspects in packages etc.
10424 * sprint.adb: Handle new syntax of aspects before IS in package
10425
104262011-08-01 Thomas Quinot <quinot@adacore.com>
10427
10428 * atree.ads: Minor reformatting.
10429 * sem_prag.adb: Minor reformatting.
10430
104312011-08-01 Robert Dewar <dewar@adacore.com>
10432
10433 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
10434 case expr alternative.
10435
104362011-08-01 Ed Schonberg <schonberg@adacore.com>
10437
10438 * sem_ch12.adb: Fix typo.
10439
9eea4346
GB
104402011-08-01 Geert Bosch <bosch@adacore.com>
10441
10442 * sem_prag.adb (Check_No_Link_Name): New procedure.
10443 (Process_Import_Or_Interface): Use Check_No_Link_Name.
10444 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
10445 instead of Standard_Long_Long_Float_Size global. Preparation for
10446 eventual removal of per type constants.
10447 * exp_util.ads (Get_Stream_Size): New function returning the stream
10448 size value of subtype E.
10449 * exp_util.adb (Get_Stream_Size): Implement new function.
10450 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
10451 function.
10452 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
10453 * einfo.adb:
10454 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
10455
3d6c3bd7
GB
104562011-08-01 Geert Bosch <bosch@adacore.com>
10457
10458 * cstand.adb: Fix comments.
10459 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
10460 count of arguments.
10461
e7d897b8
AC
104622011-08-01 Robert Dewar <dewar@adacore.com>
10463
10464 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
10465
104662011-08-01 Geert Bosch <bosch@adacore.com>
10467
10468 * atree.ads: Fix comment.
10469
c228a069
AC
104702011-08-01 Robert Dewar <dewar@adacore.com>
10471
10472 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
10473 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
10474 * par.adb: Add with for Namet.Sp.
10475 * par-tchk.adb: Minor reformatting.
10476
104772011-08-01 Vincent Celier <celier@adacore.com>
10478
10479 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
10480 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
10481 of the init procedure of a SAL.
10482 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
10483 New procedure.
10484
104852011-08-01 Thomas Quinot <quinot@adacore.com>
10486
10487 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
10488 reformatting.
10489
104902011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
10491
10492 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
10493
104942011-08-01 Thomas Quinot <quinot@adacore.com>
10495
10496 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
10497 conformant with its spec (return True only for types that have
10498 an overriding Initialize primitive operation that prevents them from
10499 having preelaborable initialization).
10500 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
10501 initialization for controlled types in Ada 2005 or later mode.
10502
857ade1b
RD
105032011-08-01 Robert Dewar <dewar@adacore.com>
10504
10505 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
10506 Postcondition.
10507 (Same_Aspect): New function.
10508 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
10509 Type_Invariant, Precondition, Postcondition.
10510 * snames.ads-tmpl: Add Name_Type_Invariant.
10511
bd949ee2
RD
105122011-08-01 Robert Dewar <dewar@adacore.com>
10513
10514 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
10515 here.
10516 (Freeze_All_Ent): Fix error in handling inherited aspects.
10517 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
10518 already analyzed, but don't skip entire processing of a declaration,
10519 that's wrong in some cases of declarations being rewritten.
10520 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
10521 Don't delay for integer, string literals
10522 Treat predicates in usual manner for delay, remove special case code,
10523 not needed.
10524 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
10525 (Build_Predicate_Function): Update saved expression in aspect
10526 (Build_Invariant_Procedure): Update saved expression in aspect
10527 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
10528 of replacement of discriminant references if the reference is simple.
10529
f1c952af
RD
105302011-08-01 Robert Dewar <dewar@adacore.com>
10531
10532 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
10533 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
10534 Static_Predicate and Dynamic_Predicate.
10535 (Build_Predicate_Function): Add processing for Static_Predicate
10536 and Dynamic_Predicate.
10537 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
10538 (From_Static_Predicate): New flag
10539 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
10540
105412011-08-01 Robert Dewar <dewar@adacore.com>
10542
10543 * usage.adb: Documentation cleanup for Ada version modes in usage.
10544 * expander.adb: Minor reformatting.
10545
47e11d08
AC
105462011-08-01 Robert Dewar <dewar@adacore.com>
10547
10548 * atree.ads: Minor comment fix.
10549 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
10550 a-witeio.ads, sem_prag.adb: Minor reformatting.
10551
105522011-08-01 Doug Rupp <rupp@adacore.com>
10553
10554 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
10555 pointers. Use descrip.h header file for convenience. Add some
10556 comments.
10557
105582011-08-01 Robert Dewar <dewar@adacore.com>
10559
10560 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
10561 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
10562 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
10563 New procedure.
10564 (Check_Aspect_At_End_Of_Declarations): New procedure
10565 (Analye_Aspect_Specification): Minor changes for above procedures
10566 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
10567 specification node as well.
10568
105692011-08-01 Pascal Obry <obry@adacore.com>
10570
10571 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
10572 Windows files. Use GetFilesAttributes() in this case to check for file
10573 existence instead of returning with an error code.
10574
a3a16b21
VC
105752011-08-01 Vincent Celier <celier@adacore.com>
10576
10577 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
10578 High is above Source length.
10579
ff58cc69
RD
105802011-08-01 Robert Dewar <dewar@adacore.com>
10581
10582 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
10583
6bb88533
AC
105842011-08-01 Robert Dewar <dewar@adacore.com>
10585
10586 * aspects.ads (Boolean_Aspects): New subtype.
10587 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
10588 for derived types in cases where the parent type and derived type have
10589 aspects.
10590 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
10591 with aspects when parent type also has aspects.
10592 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
10593 boolean expression at this point).
10594 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
10595 accordance with final decision on the Ada 2012 feature.
10596 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
10597
105982011-08-01 Matthew Heaney <heaney@adacore.com>
10599
10600 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
10601
060a3f28
AC
106022011-08-01 Pascal Obry <obry@adacore.com>
10603
10604 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
10605 Fix Replace_Slice when High is above current string size.
10606 (Replace_Slice): Fix DL computation when High is above current
10607 string length.
10608
106092011-08-01 Gary Dismukes <dismukes@adacore.com>
10610
10611 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
10612
e7f567a3
AC
106132011-08-01 Matthew Heaney <heaney@adacore.com>
10614
10615 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
10616 of node.
10617
106182011-08-01 Pascal Obry <obry@adacore.com>
10619
10620 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
10621 reformatting.
10622
1a265e78
AC
106232011-08-01 Ed Schonberg <schonberg@adacore.com>
10624
10625 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
10626 access to protected subprograms in generic bodies.
10627 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
10628 protected type, indicate that the convention of the subprogram is
10629 Convention_Protected, because it may be used in subsequent declarations
10630 within the protected declaration.
10631
106322011-08-01 Vincent Celier <celier@adacore.com>
10633
10634 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
10635 and "final" procedures when the name of the library is "ada", to avoid
10636 duplicate symbols "adainit" and "adafinal" in executables.
10637
67e28ef8
ES
106382011-08-01 Ed Schonberg <schonberg@adacore.com>
10639
10640 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
10641 quantified expression that appears within a postcondition and uses the
10642 Ada2012 'Result attribute.
10643
6da2ca7d
RO
106442011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10645
10646 * init.c (__gnat_error_handler): Cast reason to int.
10647 (__gnat_install_handler): Explain sa_sigaction use.
10648
7d5997c6
EB
106492011-07-24 Eric Botcazou <ebotcazou@adacore.com>
10650
10651 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
10652 subprogram has copy-in copy-out parameters, try to promote the mode of
10653 the return type if it is passed in registers.
10654
4b4cfdd5
EB
106552011-07-24 Eric Botcazou <ebotcazou@adacore.com>
10656
10657 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
10658 left operand as addressable.
10659
f3d34576
EB
106602011-07-24 Eric Botcazou <ebotcazou@adacore.com>
10661
10662 * gcc-interface/gigi.h (build_function_stub): Remove.
10663 (build_return_expr): Likewise.
10664 (convert_vms_descriptor): Declare.
10665 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
10666 (build_function_stub): Move to...
10667 * gcc-interface/utils2.c (build_return_expr): Move to...
10668 * gcc-interface/trans.c (build_function_stub): ...here.
10669 (build_return_expr): ...here.
10670 (Subprogram_Body_to_gnu): Add local variable for language_function.
10671 Disconnect the parameter attributes cache, if any, once done with it.
10672 Call end_subprog_body only after setting the end_locus.
10673 Build the stub associated with the function, if any, at the very end.
10674 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
10675 variables and streamline control flow.
10676
0a6ecc08
AC
106772011-07-23 Arnaud Charlet <charlet@adacore.com>
10678
10679 PR ada/49819
10680 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
10681 g-trasym-dwarf.adb.
10682
5b6d595b
RO
106832011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10684
10685 PR bootstrap/49794
10686 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
10687 Assign to act.sa_sigaction.
10688 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
10689 current->return_address to char * before arithmetic.
10690
94017021
RO
106912011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10692
10693 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
10694 Correct argument types.
10695 Extract code from reason.
10696 (__gnat_install_handler): Assign to act.sa_sigaction.
10697
52fd02bb
EB
106982011-07-21 Eric Botcazou <ebotcazou@adacore.com>
10699
10700 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
10701 (GNAT1_OBJS): ...here.
10702
f39a9ca2
EB
107032011-07-15 Eric Botcazou <ebotcazou@adacore.com>
10704
10705 PR ada/48711
10706 * g-socthi-mingw.adb (Fill): Fix formatting.
10707
9e36aa23
EB
10708 * gcc-interface/gigi.h: Move around comment.
10709
e3aca522
JDA
107102011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
10711
10712 PR ada/46350
10713 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
10714
696b1960
FW
107152011-07-14 Florian Weimer <fw@deneb.enyo.de>
10716
10717 PR ada/48711
10718 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
10719
f542c405
EB
107202011-07-13 Eric Botcazou <ebotcazou@adacore.com>
10721
10722 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
10723 range comparison if Pmode is SImode.
10724
9e9bd455
LG
107252011-07-12 Laurent GUERBY <laurent@guerby.net>
10726 Eric Botcazou <ebotcazou@adacore.com>
10727
10728 * adadecode.c: Wrap up in extern "C" block.
10729 * adadecode.h: Likewise.
10730 * adaint.c: Likewise. Remove 'const' keyword.
10731 * adaint.h: Likewise.
10732 * argv.c: Likewise.
10733 * atree.h: Likewise.
10734 * cio.c: Likewise.
10735 * cstreams.c: Likewise.
10736 * env.c: Likewise.
10737 * exit.c: Likewise.
10738 * fe.h: Likewise.
10739 * final.c: Likewise.
10740 * init.c: Likewise.
10741 * initialize.c: Likewise.
10742 * link.c: Likewise.
10743 * namet.h: Likewise.
10744 * nlists.h: Likewise.
10745 * raise.c: Likewise.
10746 * raise.h: Likewise.
10747 * repinfo.h: Likewise.
10748 * seh_init.c: Likewise.
10749 * targext.c: Likewise.
10750 * tracebak.c: Likewise.
10751 * uintp.h: Likewise.
10752 * urealp.h: Likewise.
10753 * xeinfo.adb: Wrap up generated C code in extern "C" block.
10754 * xsinfo.adb: Likewise.
10755 * xsnamest.adb: Likewise.
10756 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
10757 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
10758 * gcc-interface/misc.c: Likewise.
10759 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
10760 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
10761 ada/targext.o here...
10762 (GNAT_ADA_OBJS): ...and not here.
10763 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
10764 (GNATBIND_OBJS): Reorder.
10765
7644b3c7
RH
107662011-07-07 Richard Henderson <rth@redhat.com>
10767
10768 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
10769 dwarf2out_frame_init.
10770
8384ac41
EB
107712011-07-07 Eric Botcazou <ebotcazou@adacore.com>
10772
10773 * gcc-interface/misc.c (gnat_init): Tweak previous change.
10774
fbdd5d87
RO
107752011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10776
10777 PR target/39150
10778 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
10779
1a072294
RG
107802011-07-06 Richard Guenther <rguenther@suse.de>
10781
8384ac41
EB
10782 * gcc-interface/misc.c (gnat_init): Merge calls to
10783 build_common_tree_nodes and build_common_tree_nodes_2.
1a072294
RG
10784 Re-initialize boolean_false_node.
10785
bc712852
EB
107862011-07-02 Eric Botcazou <ebotcazou@adacore.com>
10787 Olivier Hainque <hainque@adacore.com>
10788 Nicolas Setton <setton@adacore.com>
10789
10790 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
10791 the type according to the ARTIFICIAL_P parameter.
10792 (create_type_decl): Likewise.
10793 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
10794
2eb22389
EB
107952011-07-01 Eric Botcazou <ebotcazou@adacore.com>
10796
10797 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
10798 (gnatbind): Likewise.
10799
4bdaaf2f
RO
108002011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10801
10802 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
10803
c020c92b
EB
108042011-06-18 Eric Botcazou <ebotcazou@adacore.com>
10805
10806 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
10807 local variable throughout. Remove useless call to Base_Type.
10808 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
10809 Take it also into account for the volatileness of the field. Set the
10810 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
10811
96769d32
EB
108122011-06-18 Eric Botcazou <ebotcazou@adacore.com>
10813
10814 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
10815 on a dereference built for a by-ref object if it has an address clause.
10816
7e4680c1
EB
108172011-06-18 Eric Botcazou <ebotcazou@adacore.com>
10818
10819 * einfo.ads (Address_Taken): Document use for the second argument of
10820 Asm_Input and Asm_Output attributes.
10821 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
10822 argument is an entity name, then set Address_Taken on it.
10823 <Attribute_Asm_Output>: Likewise.
10824 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
10825 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
10826 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
10827 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
10828
108292011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
d5cc9181
JR
10830
10831 PR middle-end/46500
10832 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
10833
677f3fa8
JM
108342011-06-14 Joseph Myers <joseph@codesourcery.com>
10835
10836 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
10837 (ada/utils.o): Update dependencies.
10838 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
10839 ../../../libcpp/libcpp.a.
10840 * gcc-interface/utils.c: Include common/common-target.h.
10841 (process_attributes): Use targetm_common.have_named_sections.
10842
009db074
RG
108432011-06-07 Richard Guenther <rguenther@suse.de>
10844
0bad0e23
EB
10845 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
10846 set_sizetype.
009db074 10847
3bfc61cf
EB
108482011-06-06 Eric Botcazou <ebotcazou@adacore.com>
10849
0bad0e23 10850 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
3bfc61cf
EB
10851 TREE_THIS_NOTRAP flag.
10852
5c4a1c7b
EB
108532011-06-06 Eric Botcazou <ebotcazou@adacore.com>
10854
10855 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
10856 Fix thinko.
10857
e9f57686
EB
108582011-06-06 Eric Botcazou <ebotcazou@adacore.com>
10859
10860 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
10861 constants whose full view has discriminants specially.
10862
10e4d056
EB
108632011-06-06 Eric Botcazou <ebotcazou@adacore.com>
10864
10865 * gcc-interface/utils.c: Include diagnostic.h.
10866 (gnat_write_global_declarations): Output debug information for all
10867 global type declarations before finalizing the compilation unit.
10868 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
10869
0957c029
JJ
108702011-05-25 Jakub Jelinek <jakub@redhat.com>
10871
10872 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
10873
52d0a7ac
KT
108742011-05-25 Kai Tietz <ktietz@redhat.com>
10875
10876 * adaint.c (__gnat_to_canonical_file_list_next): Use array
10877 initialization instead of const/none-const pointer assignment.
10878
1ed1641d
JM
108792011-05-24 Joseph Myers <joseph@codesourcery.com>
10880
10881 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
10882 $(EXTRA_GNAT1_OBJS).
10883 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
10884 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
10885 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
10886 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
10887 libcommon-target.a instead of prefix.o.
10888
9fe72ebd
JM
108892011-05-21 Joseph Myers <joseph@codesourcery.com>
10890
10891 PR ada/49097
0bad0e23 10892 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
9fe72ebd 10893
2691e6d7
JM
108942011-05-20 Joseph Myers <joseph@codesourcery.com>
10895
0bad0e23
EB
10896 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
10897 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
10898 instead of version.o.
2691e6d7 10899
bf6490b5
KT
109002011-05-18 Kai Tietz <ktietz@redhat.com>
10901
10902 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
10903 boolean_false_node instead of integer_zero_node.
10904 (convert_with_check): Likewise.
10905 * gcc-interface/decl.c (choices_to_gnu): Likewise.
10906
7bf9a5ac
EB
109072011-05-12 Eric Botcazou <ebotcazou@adacore.com>
10908
10909 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
10910 type of the parameter is an unconstrained array, convert the actual to
10911 the type of the formal in the In Out and Out cases as well.
10912
e5b00edf
NF
109132011-05-11 Nathan Froyd <froydnj@codesourcery.com>
10914
10915 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
10916 call build_function_type_array or build_varargs_function_type_array
10917 instead.
10918 (create_subprog_type): Don't call build_function_type; call
10919 build_function_type_vec instead.
10920
51545682
NF
109212011-05-11 Nathan Froyd <froydnj@codesourcery.com>
10922
10923 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
10924 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
10925 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
10926
c99c0026
EB
109272011-05-07 Eric Botcazou <ebotcazou@adacore.com>
10928
f620bd21
EB
10929 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
10930
c99c0026
EB
10931 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
10932 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
10933
3d528853
NF
109342011-05-05 Nathan Froyd <froydnj@codesourcery.com>
10935
c99c0026 10936 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
3d528853 10937
d7d058c5
NF
109382011-05-05 Nathan Froyd <froydnj@codesourcery.com>
10939
10940 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
10941 instead of accessing TYPE_ARG_TYPES directly.
10942 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
10943
805e60a0
EB
109442011-05-05 Eric Botcazou <ebotcazou@adacore.com>
10945
10946 PR ada/48844
10947 * gcc-interface/gigi.h (get_variant_part): Declare.
10948 * gcc-interface/decl.c (get_variant_part): Make global.
10949 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
10950 types have the same constant size, are record types and T1 has a
10951 variant part while T2 doesn't.
10952
907a08d9
EB
109532011-05-05 Eric Botcazou <ebotcazou@adacore.com>
10954
10955 * gcc-interface/utils.c (begin_subprog_body): Do not call
10956 get_pending_sizes.
10957 (end_subprog_body): Likewise.
10958
d35936ab
RG
109592011-05-04 Richard Guenther <rguenther@suse.de>
10960
10961 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
10962 int_const_binop.
10963 (pos_to_constructor): Likewise.
10964
c1fd8753 109652011-05-03 Nathan Froyd <froydnj@codesourcery.com>
2c7f9cc0 10966 Eric Botcazou <ebotcazou@adacore.com>
c1fd8753
NF
10967
10968 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
10969 of build_function_type. Adjust calls to...
10970 (build_raise_check): ...this. Do not take a void_tree parameter.
10971 Call build_function_type_list instead of build_function_type.
10972 Fix head comment and swap couple of conditional blocks.
10973
4fb87d2b
EB
109742011-04-30 Eric Botcazou <ebotcazou@adacore.com>
10975
10976 * gnatvsn.ads (Library_Version): Bump to 4.7.
10977 (Current_Year): Bump to 2011.
10978
fa5e5a76
MM
109792011-04-29 Michael Matz <matz@suse.de>
10980
10981 * gcc-interface/misc.c (gnat_handle_option): Set
10982 warn_maybe_uninitialized.
10983
8d6a2f69
GP
109842011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
10985
10986 * gnat_ugn.texi (Complexity Metrics Control): Update link to
10987 the Watson/McCabe paper.
10988
770937fd
JM
109892011-04-23 Jim Meyering <meyering@redhat.com>
10990
10991 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
10992
eb601ae1
EB
109932011-04-22 Eric Botcazou <ebotcazou@adacore.com>
10994
10995 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
10996 onto the new type.
10997
7d7fcb08
EB
109982011-04-22 Eric Botcazou <ebotcazou@adacore.com>
10999
11000 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
11001 parameter.
11002 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
11003 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
11004 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
11005 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
11006 <all>: Do not set flags on the reused DECL node coming from an alias.
11007 Set DECL_IGNORED_P on the DECL node built for subprograms if they
11008 don't need debug info here...
11009 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
11010 (gigi): Adjust calls to create_subprog_decl.
11011 (build_raise_check): Likewise.
11012 (establish_gnat_vms_condition_handler): Likewise.
11013 (Compilation_Unit_to_gnu): Likewise.
11014 (gnat_to_gnu): Likewise.
11015
e1876cac
EB
110162011-04-21 Eric Botcazou <ebotcazou@adacore.com>
11017
11018 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
11019 (NO_REORDER_ADAFLAGS): New variable.
11020 (EXTRA_GNATTOOLS): Always define.
11021 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
11022 Clean up and adjust list of files compiled with special options.
11023 * gcc-interface/Make-lang.in: Likewise.
11024 (ada/decl.o): Cosmetical change.
11025 (ada/misc.o): Remove dependency on $(PLUGIN_H).
11026
04695783
JM
110272011-04-20 Jim Meyering <meyering@redhat.com>
11028
11029 * initialize.c (__gnat_initialize): Remove useless if-before-free.
11030
23399579
EB
110312011-04-17 Eric Botcazou <ebotcazou@adacore.com>
11032
11033 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
11034 $(CFLAGS) on the link line.
11035
51c5169c
EB
110362011-04-17 Eric Botcazou <ebotcazou@adacore.com>
11037
11038 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
11039 padded type built for the return type if it is unconstrained.
11040
61e46a7d
NF
110412011-04-14 Nathan Froyd <froydnj@codesourcery.com>
11042
11043 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
11044
81f653d6
NF
110452011-04-12 Nathan Froyd <froydnj@codesourcery.com>
11046
b4867846
EB
11047 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
11048 before calling TREE_CHAIN.
81f653d6
NF
11049 * gcc-interface/misc.c (gnat_init_ts): New function.
11050 (LANG_HOOKS_INIT_TS): Define.
11051
a358e188
MJ
110522011-04-12 Martin Jambor <mjambor@suse.cz>
11053
b4867846
EB
11054 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
11055 instead of cgraph_node.
a358e188 11056
29b1c5a4
EB
110572011-04-08 Eric Botcazou <ebotcazou@adacore.com>
11058
11059 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
11060 alignment on fields of the RETURN type built for the Copy-In Copy-Out
11061 mechanism.
11062
88872b00
EB
110632011-04-08 Eric Botcazou <ebotcazou@adacore.com>
11064
11065 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
11066 of aggregate types that contain a placeholder.
11067
dcf0c47e
NF
110682011-04-08 Nathan Froyd <froydnj@codesourcery.com>
11069
11070 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
b4867846 11071 TYPE_ARG_TYPES.
dcf0c47e
NF
11072 (handle_type_generic_attribute): Likewise.
11073
53e3000c
EB
110742011-04-04 Eric Botcazou <ebotcazou@adacore.com>
11075
11076 PR ada/47163
11077 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
11078
ab380bb4
KT
110792011-04-04 Kai Tietz <ktietz@redhat.com>
11080
11081 PR ada/47163
0bad0e23
EB
11082 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
11083 to flag value.
ab380bb4 11084
8ffac116
EB
110852011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11086
11087 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
11088 type case, do not strip a padding type around the array type.
11089
de9528f0
EB
110902011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11091
11092 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
11093 types.
11094
d9d7a26c
EB
110952011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11096
11097 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
11098 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
de9528f0 11099 code for -feliminate-unused-debug-types.
d9d7a26c
EB
11100 (gnat_post_options): Likewise.
11101
4cb12a90
EB
111022011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11103
11104 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
11105 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
11106 distinct copy.
11107
acccc61c
EB
111082011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11109
11110 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
11111 DECL_ARTIFICIAL flag on enumeration types.
11112
583eb0c9
EB
111132011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11114
11115 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
11116 fat pointer types artificial unconditionally.
11117 <E_Array_Subtype>: Attach the base array type as a parallel type if it
11118 isn't artificial.
11119
e3edbd56
EB
111202011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11121
11122 * gcc-interface/gigi.h (get_dummy_type): Declare.
11123 (build_dummy_unc_pointer_types): Likewise.
11124 (finish_fat_pointer_type): Likewise.
11125 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
11126 fat pointer type has been built, complete it in place.
11127 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
11128 and thin pointers. Remove useless variable.
11129 (finish_fat_pointer_type): Make global and move to...
11130 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
11131 (get_dummy_type): New function.
11132 (build_dummy_unc_pointer_types): Likewise.
11133 (gnat_pushdecl): Propage the name to the anonymous variants only.
11134 (update_pointer_to): Only adjust the pointer types in the unconstrained
11135 array case.
11136
65444786
EB
111372011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11138
11139 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
11140 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
11141 if this is a Taft amendment type and the full declaration is available.
11142 * gcc-interface/trans.c (process_type): Likewise.
11143 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
11144 (process_freeze_entity): Likewise.
11145 * gcc-interface/utils.c (dummy_global): New static variable.
11146 (gnat_write_global_declarations): If there are types declared as used
11147 at the global level, insert them in the global hash table.
11148
1aeb40dd
EB
111492011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11150
11151 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
11152 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
11153 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
11154 copy.
11155 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
11156 flag of the type accordingly.
11157 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
11158
80ec8b4c
EB
111592011-04-02 Eric Botcazou <ebotcazou@adacore.com>
11160
11161 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
11162 finalizing types when updating the pointers to the designated type.
11163 <all>: Finalize the deferred types even if we didn't defer processing
11164 of incomplete types in this invocation.
11165
2a9d769a 111662011-04-01 Olivier Hainque <hainque@adacore.com>
2c7f9cc0
AS
11167 Nicolas Setton <setton@adacore.com>
11168 Eric Botcazou <ebotcazou@adacore.com>
2a9d769a
OH
11169
11170 * gcc-interface/misc.c (gnat_descriptive_type): New function.
11171 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
11172
2438d7a6
KT
111732011-03-28 Kai Tietz <ktietz@redhat.com>
11174
333d8aff 11175 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
80ec8b4c
EB
11176 Windows targets.
11177 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
11178 * system-mingw.ads (System): Change ZCX_By_Default default to True.
333d8aff 11179
80ec8b4c 11180 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
2438d7a6 11181
8ad150f6
TG
111822011-03-28 Tristan Gingold <gingold@adacore.com>
11183
11184 PR ada/44431
80ec8b4c
EB
11185 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
11186 Use ada output of gnatbind.
8ad150f6
TG
11187 (ada/b_gnatb.adb): Ditto.
11188 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
11189 (ada.mostlyclean, ada.stage1)
11190 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
11191 (ada.stagefeedback): Adjust.
80ec8b4c 11192 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
8ad150f6
TG
11193 Use ada output of gnatbind.
11194 (b_gnatm.adb): Ditto.
11195 (b_gnatl.o, b_gnatm.o): New rules.
11196
51c7954d
EB
111972011-03-26 Eric Botcazou <ebotcazou@adacore.com>
11198
11199 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
11200 for the padded type built to support a specified size or alignment.
11201
6ddf9843
EB
112022011-03-26 Eric Botcazou <ebotcazou@adacore.com>
11203
11204 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
11205 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
11206 unconditionally to the end of the unit when the designated type is
11207 limited_with'ed.
11208 <all>: Rename local variable. Attempt to un-defer types only and do it
11209 for limited_with'ed types as well.
11210 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
11211 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
11212 consistently and remove redundant call to finalize_from_with_types.
11213
5daed84a
EB
112142011-03-26 Eric Botcazou <ebotcazou@adacore.com>
11215
11216 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
11217 subprograms without a previous spec declared in the same unit.
11218 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
11219 subprograms at the end of the unit instead of at the beginning.
11220 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
11221 isn't public for the special handling of non-inline functions nested
11222 inside inline external functions.
11223
0edf1bb2
JL
112242011-03-25 Jeff Law <law@redhat.com>
11225
5daed84a 11226 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
0edf1bb2 11227
e3c4580e
EB
112282011-03-24 Eric Botcazou <ebotcazou@adacore.com>
11229
11230 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
11231 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
11232 to compute Set_Size_Depends_On_Discriminant.
11233 (Layout_Type): Call it on array types in back-end layout mode.
11234 * sem_util.adb (Requires_Transient_Scope): Return true for array
11235 types only if the size depends on the value of discriminants.
11236 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
11237 type if the RHS is a call to a function that returns an unconstrained
11238 type with default discriminant.
11239
abbc8c7b
EB
112402011-03-24 Eric Botcazou <ebotcazou@adacore.com>
11241
11242 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
11243 non-conversion to the nominal result type at the end.
11244
ddb5a105
EB
112452011-03-23 Eric Botcazou <ebotcazou@adacore.com>
11246
11247 * gcc-interface/trans.c (create_temporary): New function taken from...
11248 (create_init_temporary): ...here. Call it.
11249 (call_to_gnu): Create the temporary for the return value early, if any.
11250 Create it for a function with copy-in/copy-out parameters if there is
11251 no target; in other cases of copy-in/copy-out, use another temporary.
11252 Push the new binding level lazily. Add and rename local variables.
11253
0d853156
EB
112542011-03-23 Eric Botcazou <ebotcazou@adacore.com>
11255
11256 * gcc-interface/decl.c (validate_size): Improve comments and tweak
11257 error message.
11258 (set_rm_size): Likewise.
11259
4184ef1b
EB
112602011-03-23 Eric Botcazou <ebotcazou@adacore.com>
11261
11262 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
11263 for the padded type built in order to support a specified alignment.
11264 Fix incorrect formatting.
11265
bf7eefab
EB
112662011-03-21 Eric Botcazou <ebotcazou@adacore.com>
11267
11268 PR bootstrap/48216
11269 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
11270
ef0feeb2
EB
112712011-03-21 Eric Botcazou <ebotcazou@adacore.com>
11272
11273 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
11274 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
11275 to the end of the list. Adjust recursive call. Rename local variable.
11276 If REORDER is true, reorder components of the record type.
11277 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
11278 components_to_record and adjust the parameter list.
11279
646f9414
EB
112802011-03-21 Eric Botcazou <ebotcazou@adacore.com>
11281
11282 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
11283 disabled, use the variable for bounds of loop iteration scheme.
11284
62d784f7
KT
112852011-03-21 Kai Tietz <ktietz@redhat.com>
11286
11287 PR target/12171
0bad0e23 11288 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
62d784f7 11289
f230d759
EB
112902011-03-17 Eric Botcazou <ebotcazou@adacore.com>
11291
11292 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
11293 out whether the expression is read-only. Short-circuit placeholder
11294 case and rename a couple of local variables.
11295
bb1f7929
EB
112962011-03-17 Eric Botcazou <ebotcazou@adacore.com>
11297
11298 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
11299 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
11300 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
11301 (convert): Deal with conversions from a smaller form type specially.
11302
400a2d24
EB
113032011-02-14 Eric Botcazou <ebotcazou@adacore.com>
11304
11305 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
11306 its argument, except for the special -I- switch.
11307
c26bc3ad
GP
113082011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
11309
0bad0e23
EB
11310 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
11311 "Ada Issues".
c26bc3ad 11312
07b8e910
EB
113132011-02-08 Eric Botcazou <ebotcazou@adacore.com>
11314
11315 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
11316
31a5a547
EB
113172011-02-03 Eric Botcazou <ebotcazou@adacore.com>
11318
11319 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
11320 GNAT_FORMAL.
11321 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
11322 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
11323 instead of GNAT_FORMAL. Protect the expression against multiple uses.
11324 Do not generate the check directly, instead instantiate the template
11325 check present in the descriptor.
11326 (make_descriptor_field): Move around.
11327 (build_vms_descriptor32): Build a template check in the POINTER field.
11328 (build_vms_descriptor): Remove useless suffixes.
11329 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
11330
dcf25f59
EB
113312011-01-26 Eric Botcazou <ebotcazou@adacore.com>
11332
11333 PR bootstrap/47467
11334 * targext.c: Include target files if IN_RTS is defined.
11335
0418e131
RG
113362011-01-26 Richard Guenther <rguenther@suse.de>
11337
11338 PR bootstrap/47467
11339 * targext.c: Include config.h.
11340 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
11341 dependency.
11342
c6eecbd8 113432011-01-04 Pascal Obry <obry@adacore.com>
2c7f9cc0 11344 Eric Botcazou <ebotcazou@adacore.com>
c6eecbd8
PO
11345
11346 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
11347
2d3c7e4f
EB
113482011-01-04 Eric Botcazou <ebotcazou@adacore.com>
11349
11350 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
11351 end-of-case on the end label and its associated gotos, if any.
11352
0394741f
EB
113532011-01-04 Eric Botcazou <ebotcazou@adacore.com>
11354
11355 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
11356 expressions of the parameter cache within the statement group of
11357 the CICO mechanism.
11358
2a02d090 113592011-01-04 Olivier Hainque <hainque@adacore.com>
2c7f9cc0 11360 Eric Botcazou <ebotcazou@adacore.com>
2a02d090
OH
11361
11362 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
11363 (set_end_locus_from_node): New function.
11364 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
11365 make and the function end_locus.
11366 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
11367 for the elaboration subprogram.
11368 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
11369 set the end_locus of the expression as well.
11370
89f5e978
EB
113712011-01-04 Eric Botcazou <ebotcazou@adacore.com>
11372
11373 PR ada/47131
11374 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
11375 variables that are referenced in exception handlers volatile.
11376
11377
ad41bd84 11378\f
797103eb 11379Copyright (C) 2011 Free Software Foundation, Inc.
ad41bd84
JM
11380
11381Copying and distribution of this file, with or without modification,
11382are permitted in any medium without royalty provided the copyright
11383notice and this notice are preserved.
This page took 1.999817 seconds and 5 git commands to generate.