]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/ada/ChangeLog
gfortran.texi (Fortran 2008 status, [...]): Update implementation status, change...
[thirdparty/gcc.git] / gcc / ada / ChangeLog
CommitLineData
b7539c3b
AC
12011-10-14 Ed Schonberg <schonberg@adacore.com>
2
3 * exp_disp.adb (Check_Premature_Freezing): If an untagged type
4 is a generic actual, it is a subtype of a type that was frozen
5 by the instantiation, and even if not marked frozen it does not
6 affect the construction of the dispatch table.
7
82011-10-14 Robert Dewar <dewar@adacore.com>
9
10 * make.adb, mlib-utl.adb, sem_util.adb, sem_ch4.adb: Minor code
11 reformatting.
12 * s-rident.ads: Add missing Compiler_Unit pragma.
13
af89615f
AC
142011-10-14 Gary Dismukes <dismukes@adacore.com>
15
16 * sem_res.adb: Minor reformatting.
17
182011-10-14 Hristian Kirtchev <kirtchev@adacore.com>
19
20 * exp_ch6.adb (Add_Task_Actuals_To_Build_In_Place_Call):
21 Code and comment reformatting. Use BIP_Task_Master
22 when creating a _master.
23 (BIP_Formal_Suffix): Code reformatting. Correct the case for
24 BIP_Task_Master.
25 (Make_Build_In_Place_Call_In_Object_Declaration): Use
26 BIP_Task_Master when creating a reference to the enclosing
27 function's _master formal.
28 (Move_Activation_Chain): Use BIP_Task_Master when creating a reference
29 to the _master.
30 * exp_ch6.ads: Change BIP_Master to BIP_Task_Master.
31 (Needs_BIP_Finalization_Master): Alphabetized.
32 * sem_ch6.adb (Create_Extra_Formals): Update the usage of
33 BIP_Task_Master.
34
352011-10-14 Ed Schonberg <schonberg@adacore.com>
36
37 * par-ch6.adb (P_Return_Object_Declaration): In Ada 2012 mode,
38 reject an aliased keyword on the object declaration of an extended
39 return statement. In older versions of the language indicate
40 that this is illegal in the standard.
41
422011-10-14 Pascal Obry <obry@adacore.com>
43
44 * sem_util.adb, sem_ch4.adb: Minor reformatting.
45
462011-10-14 Ed Schonberg <schonberg@adacore.com>
47
48 * sem_ch13.adb: Recognize properly procedure calls that are
49 transformed into code statements.
50
512011-10-14 Vincent Celier <celier@adacore.com>
52
53 * projects.texi: Minor fix in project example.
54
f2d10a02
AC
552011-10-14 Ed Schonberg <schonberg@adacore.com>
56
57 * sem_util.adb: Return objects are aliased if their type is
58 immutably limited as per AI05-0053.
59
602011-10-14 Gary Dismukes <dismukes@adacore.com>
61
62 * exp_ch4.adb (Expand_N_Op_And): Remove Short_Circuit_And_Or
63 expansion code (moved to sem_res) (Expand_N_Op_Or): Remove
64 Short_Circuit_And_Or expansion code (moved to sem_res).
65 * sem_res.adb (Resolve_Logical_Op): Add code to rewrite Boolean
66 "and" and "or" operators as short-circuit "and then" and "or
67 else", when pragma Short_Circuit_And_Or is active.
68
2fcc44fa
AC
692011-10-13 Robert Dewar <dewar@adacore.com>
70
71 * sem_ch9.adb, sem_util.adb, sem_util.ads, exp_ch6.adb, sem_ch4.adb,
72 sem_ch6.adb, exp_ch3.adb: Minor reformatting.
73
742011-10-13 Arnaud Charlet <charlet@adacore.com>
75
76 * Makefile.rtl (GNATRTL_NONTASKING_OBJS): Add a-ngcoar.o.
77
782011-10-13 Jerome Guitton <guitton@adacore.com>
79
80 * sysdep.c (__gnat_get_task_options): Re-enable VX_SPE_TASK on vThreads
81
822011-10-13 Eric Botcazou <ebotcazou@adacore.com>
83
84 * a-convec.ads (Cursor): Minor reformatting.
85 * a-convec.adb (Next): Fix minor inconsistencies.
86 (Previous): Likewise.
87
9b62eb32
AC
882011-10-13 Ed Schonberg <schonberg@adacore.com>
89
90 * sem_util.ads, sem_util.adb (Available_Full_View_Of_Component):
91 New predicate to determine whether some operations on an array
92 type are available when the full view of its component may differ
93 from the view of the point of the array declaration.
94 * sem_ch4.adb (Find_Equality_Types): Use
95 Available_Full_View_Of_Component.
96 * sem_type.adb (Valid_Boolean_Arg, Valid_Comparison_Arg): Ditto
97
982011-10-13 Ed Schonberg <schonberg@adacore.com>
99
100 * sem_ch9.adb: Analyze aspects while discriminants of protected
101 type are visible.
102
1032011-10-13 Geert Bosch <bosch@adacore.com>
104
105 * Makefile.rtl (GNATRTL_TASKING_OBJECTS): Add
106 a-nlcoar.o, a-nllcar.o, a-nucoar.o and s-gearop.o, as these no
107 longer depend on an external library.
108 * gcc-interface/Makefile.in (GNATRTL_LINEARALGEBRA_OBJS): Remove
109 a-nlcoar.o, a-nllcar.o, a-nucoar.o and s-gearop.o.
110 Update dependencies.
111 * gcc-interface/Make-lang.in: Update dependencies.
112
1a36a0cd
AC
1132011-10-13 Cyrille Comar <comar@adacore.com>
114
115 * gnat_ugn.texi: Minor editing.
116
1172011-10-13 Vincent Celier <celier@adacore.com>
118
119 * projects.texi: Add documentation on packages and attributes
120 that are inherited from a project being extended into the
121 extended project.
122
1232011-10-13 Hristian Kirtchev <kirtchev@adacore.com>
124
125 * exp_ch3.adb (Build_Master): Rewritten.
126 (Expand_N_Full_Type_Declaration): Reformat the declarative
127 region. Update the call to Build_Master_Renaming.
128 (Expand_Previous_Access_Type): Rewritten.
129 * exp_ch6.adb (Add_Task_Actuals_To_Build_In_Place_Call):
130 Add local constant Result_Subt and update related usage.
131 (Expand_N_Extended_Return_Statement): Add local constant
132 Result_Subt and update related usage.
133 * exp_ch9.adb (Build_Activation_Chain): Rewritten to use the
134 new context detection mechanism.
135 (Build_Class_Wide_Master):
136 Use Insert_Action to add the renaming into the tree.
137 (Build_Master_Entity): Rewritten to use the new context detection
138 mechanism.
139 (Build_Master_Renaming): Add formal parameter Ins_Nod
140 and related usage. Use Insert_Action to add the renaming into the
141 tree.
142 (Find_Enclosing_Context): New subsidiary routine. Rather
143 than relying on enclosing scopes, this routine looks at the
144 tree structure to figure out the proper context for a _master
145 or a _chain. This approach eliminates the issues with transient
146 scopes which have not been converted into blocks.
147 * exp_ch9.ads (Build_Master_Entity): Change parameter profile
148 to better reflect the new usage. Update the related comment.
149 (Build_Master_Renaming): Add formal parameter Ins_Nod. Update
150 the comment on usage.
151 * sem_ch3.adb (Access_Definition): Update the calls to
152 Build_Master_Entity and Build_Master_Renaming.
153 * sem_ch6.adb (Create_Extra_Formals): Add local variable
154 Full_Subt. Code reformatting.
155 * sem_util.adb (Is_Iterator): Alphabetized.
156 (Is_LHS): Alphabetized.
157 (Is_Limited_Class_Wide_Type): New routine.
158 * sem_util.ads (Is_Limited_Class_Wide_Type): New routine.
159
a5917ffb
GB
1602011-10-13 Geert Bosch <bosch@adacore.com>
161
162 * a-ngrear.adb (Solve): Make generic and move to
163 System.Generic_Array_Operations.
164 * s-gearop.ads (Matrix_Vector_Solution, Matrix_Matrix_Solution):
165 New generic solvers to compute a vector resp. matrix Y such
166 that A * Y = X, approximately.
167 * s-gearop.adb (Matrix_Vector_Solution, Matrix_Matrix_Solution):
168 Implement using Forward_Eliminate and Back_Substitute
169 * a-ngcoar.adb: Reimplement in pure Ada to remove dependencies
170 on BLAS and LAPACK.
171 * a-ngcoar.ads ("abs"): Fix return type to be real.
172
574ec945
EB
1732011-10-13 Eric Botcazou <ebotcazou@adacore.com>
174
175 PR ada/50589
176 * s-linux-alpha.ads: Do not "with" Interfaces.C.
177 * s-linux-sparc.ads: Likewise.
178
8668ea36
GB
1792011-10-13 Geert Bosch <bosch@adacore.com>
180
181 * s-gearop.ads (Forward_Eliminate): Add "abs" formal function
182 returning a Real.
183 * s-gearop.adb (Forward_Eliminate): Remove local "abs" function
184 and use formal.
185 * a-ngrear.adb (Forward_Eliminate): Adjust instantiation for
186 new profile.
187
edcf5983
GB
1882011-10-13 Geert Bosch <bosch@adacore.com>
189
190 * a-ngrear.adb, s-gearop.adb, s-gearop.ads (Sqrt): Make generic and
191 move to System.Generic_Array_Operations.
192
a4935dea
GB
1932011-10-13 Geert Bosch <bosch@adacore.com>
194
195 * a-ngrear.adb ("abs"): Adjust for modified L2_Norm generic
196 * s-gearop.ads (L2_Norm): Change profile to be suitable for
197 Complex_Vector
198 * s-gearop.adb (L2_Norm): Reimplement using direct definition,
199 not inner product
200
3e7302c3
AC
2012011-10-13 Robert Dewar <dewar@adacore.com>
202
203 * exp_ch5.adb, sem_ch3.adb, impunit.adb, impunit.ads, sem_type.adb,
204 prj-proc.adb, exp_ch9.adb, s-regpat.adb, sem_ch10.adb, sem_prag.adb,
205 sem_ch12.adb, freeze.adb, sem_attr.adb, sem_attr.ads, gnatlink.adb,
206 par-ch6.adb, exp_ch6.adb, sem_ch4.adb, sem_ch6.adb, sem_ch8.adb,
207 par-util.adb, sem_ch13.adb, lib-xref.adb, g-trasym.adb, g-trasym.ads,
208 exp_aggr.adb, s-taprop-posix.adb: Minor reformatting.
209
2102011-10-13 Geert Bosch <bosch@adacore.com>
211
212 * s-gearop.adb: Minor comment additions.
213
8417f4b2
AC
2142011-10-13 Fedor Rybin <frybin@adacore.com>
215
216 * gnat_ugn.texi: Add gnattest section.
217
2182011-10-13 Ed Schonberg <schonberg@adacore.com>
219
220 * freeze.adb: Do not create body of renaming if declaration has
221 errors.
222
2232011-10-13 Olivier Hainque <hainque@adacore.com>
224
225 * init.c (__gnat_error_handler - vxworks case): Restrict sigtramp calls
226 further, to the ppc+kernel case only.
227
2282011-10-13 Hristian Kirtchev <kirtchev@adacore.com>
229
230 * exp_ch4.adb (Expand_N_Allocator): Comment reformatting.
231 * exp_ch6.adb (Add_Unconstrained_Actuals_To_Build_In_Place_Call):
232 Do not create a pool formal on .NET/JVM.
233 (Expand_N_Extended_Return_Statement): Alphabetize local
234 variables. Do not create a renaming of the build-in-place pool
235 parameter on .NET/JVM. (Make_Build_In_Place_Call_In_Allocator):
236 Add the user-defined pool only on non-VM targets.
237 (Make_Build_In_Place_Call_In_Object_Declaration): Alphabetize
238 local variables. Do not add a pool actual on .NET/JVM.
239 * sem_ch6.adb: Add with and use clause for Targparm.
240 (Create_Extra_Formals): Add build-in-place pool formal only on
241 non-VM targets.
242 * rtsfind.ads: Alphabetize entries.
243
4674dd21
AC
2442011-10-13 Sergey Rybin <rybin@adacore.com>
245
246 * gnat_ugn.texi: Minor correction.
247
2482011-10-13 Ed Schonberg <schonberg@adacore.com>
249
250 * sem_ch8.adb: Minor error message improvement.
251
2522011-10-13 Robert Dewar <dewar@adacore.com>
253
254 * a-cbprqu.adb, a-ciorma.adb, exp_ch3.adb: Minor reformatting.
255
95aeda79
GD
2562011-10-13 Gary Dismukes <dismukes@adacore.com>
257
258 * exp_ch5.adb (Expand_N_Loop_Statement): For the transformation
259 of a for loop for an enumeration type with an enumeration rep
260 clause, which involves moving the original loop parameter into
261 a nested block, the loop parameter's entity must be removed from
262 the entity list of the loop scope.
263
200b7162
BD
2642011-10-13 Bob Duff <duff@adacore.com>
265
266 * exp_ch6.ads (BIP_Storage_Pool): New "extra implicit parameter"
267 that gets passed in the same cases where BIP_Alloc_Form is passed
268 (caller-unknown-size results). BIP_Storage_Pool is used when
269 BIP_Alloc_Form = User_Storage_Pool. In that case, a pointer
270 to the user-defined storage pool is passed at the call site,
271 and this pool is used in callee to allocate the result.
272 * exp_ch6.adb (Add_Unconstrained_Actuals_To_Build_In_Place_Call): New
273 version of Add_Alloc_Form_Actual_To_Build_In_Place_Call. Passes
274 the additional BIP_Storage_Pool actual.
275 (Expand_N_Extended_Return_Statement): Allocate the function
276 result using the user-defined storage pool, if BIP_Alloc_Form =
277 User_Storage_Pool.
278 * sem_ch6.adb: Add the "extra formal" for BIP_Storage_Pool.
279 * exp_ch4.adb: Don't overwrite storage pool set by
280 Expand_N_Extended_Return_Statement.
281 * s-stopoo.ads, rtsfind.ads (Root_Storage_Pool_Ptr): New type,
282 for use in build-in-place function calls within allocators
283 where the access type has a user-defined storage pool.
284
9f8d1e5c
AC
2852011-10-13 Sergey Rybin <rybin@adacore.com>
286
287 * gnat_ugn.texi, vms_data.ads: Add an option to control enumeration
288 literal casing.
289
2902011-10-13 Nicolas Roche <roche@adacore.com>
291
292 * gnatlink.adb: Ensure that -mrtp is passed when
293 runtime name ends with 'rtp'.
294
2952011-10-13 Ed Schonberg <schonberg@adacore.com>
296
297 * sem_prag.adb (Analyze_Pragma, case Unchecked_Union): an
298 unchecked union type can be limited.
299
3002011-10-13 Olivier Hainque <hainque@adacore.com>
301
302 * init.c (__gnat_error_handler) <VxWorks version>: Add comments on
303 the use of the signal trampoline for PPC in the sjlj case as well.
304 Add legitimate casts, preventing compile time warnings on the
305 (sighandler *) profile.
306
3072011-10-13 Yannick Moy <moy@adacore.com>
308
309 * sem_aggr.adb (Resolve_Aggr_Expr): Always perform semantic
310 analysis in Alfa mode.
311
3122011-10-13 Ed Schonberg <schonberg@adacore.com>
313
314 * sem_ch3.adb (OK_For_Limited_Init_In_05): Conditional and case
315 expressions are legal limited return values if each one of their
316 dependent expressions are legal.
317
3182011-10-13 Ed Schonberg <schonberg@adacore.com>
319
320 * sem_ch6.adb (Analyze_Procedure_Call_Statement): In Ada 2012 mode,
321 if the prefix of the call is a qualified expression, rewrite as
322 a code statement.
323 * sem_ch13.adb (Analyze_Code_Statement): In Ada 2012 mode, the
324 code statement is legal if it is a rewriting of a procedure call.
325
3262011-10-13 Ed Schonberg <schonberg@adacore.com>
327
328 * exp_aggr.adb (Flatten): If a component association has a box,
329 assume that aggregate is not static.
330 (Safe_Aggregate): If a component association in a non-limited
331 aggregate has a box, assume that it cannot be expanded in place.
332
3332011-10-13 Vincent Celier <celier@adacore.com>
334
335 * prj-conf.adb (Get_Or_Create_Configuration_File): Call
336 Process_Project_Tree_Phase_1 with Packages_To_Check.
337 (Process_Project_And_Apply_Config): Ditto
338 * prj-part.ads, prj-part.adb, prj-pars.ads, prj-pars.adb (Parse):
339 Remove default for argument Packages_To_Check.
340 * prj-proc.adb (Recursive_Process): New argument
341 Packages_To_Check.
342 (Process): Ditto.
343 (Process_Project_Tree_Phase_1): Ditto.
344 (Recursive_Project.Process_Aggregated_Projects): Call
345 Prj.Part.Parse and Process_Project_Tree_Phase_1 with
346 Packages_To_Check.
347 * prj-proc.ads (Process): New argument Packages_To_Check
348 (Process_Project_Tree_Phase_1): Ditto
349
46f8e1ac
AC
3502011-10-13 Arnaud Charlet <charlet@adacore.com>
351
352 * gcc-interface/Makefile.in: Fix typo.
353
8097203f
AC
3542011-10-13 Ed Schonberg <schonberg@adacore.com>
355
356 * sem_ch12.adb (Analyze_Formal_{Floating_Type,
357 Signed_Integer_Type, Decimal_Fixed_Point_Type, Discrete_Type}):
358 Use sloc of defining identifier of farmal type declaration,
359 as sloc of generated internal entity, to prevent misplaced
360 references in ali.
361
3622011-10-13 Ed Schonberg <schonberg@adacore.com>
363
364 * sem_intr.adb (Check_Intrinsic_Operator): Check that type
365 is fully defined before checking that it is a numeric type.
366
3672011-10-13 Ed Schonberg <schonberg@adacore.com>
368
369 * sem_aggr.adb (Resolve_Record_Aggregate): If a component
370 association for component X has a box, then X is covered in the
371 aggregate even if there is not default value for X in the type
372 declaration, and X has to be default-initialized.
373
3742011-10-13 Ed Schonberg <schonberg@adacore.com>
375
376 * sem_attr.adb (Check_Enum_Image, Analyze_Attribute case
377 'Value): Mark literals as referenced only if reference is in
378 current source unit.
379
3802011-10-13 Matthew Heaney <heaney@adacore.com>
381
382 * a-csquin.ads (Enque, Dequeue): Mark interface operations as entries.
383
3842011-10-13 Olivier Hainque <hainque@adacore.com>
385
386 * sigtramp.h: New file. Prototype and spec of the signal
387 trampoline to be called by an established handler to provide
388 dwarf call frame info before the real signal processing code.
389 * sigtramp-ppcvxw.c: New file. Implementation of the signal
390 trampoline for ppc-vxworks.
391 * init.c (vxworks section): Use it for ppc.
392
e192a2cd
AC
3932011-10-13 Thomas Quinot <quinot@adacore.com>
394
395 * par-ch2.adb, par.adb, par-util.adb, par-ch3.adb
396 (Check_Future_Identifier): New subprogram,
397 factors duplicated code from Par.Ch2.P_Identifier and
398 Par.Ch3.P_Defining_Identifier.
399
4002011-10-13 Thomas Quinot <quinot@adacore.com>
401
402 * s-taprop-posix.adb (Initialize): Always raise Storage_Error
403 if we fail to initialize CV attributes or CV.
404
4052011-10-13 Thomas Quinot <quinot@adacore.com>
406
407 * s-tasren.adb (Timed_Selective_Wait, case
408 Accept_Alternative_Selected): Use Defer_Abort_Nestable, since
409 we know abortion is already deferred.
410
4112011-10-13 Hristian Kirtchev <kirtchev@adacore.com>
412
413 * exp_ch3.adb (Build_Class_Wide_Master): Moved to exp_ch9.
414 (Build_Master_Renaming (function)): Removed.
415 (Build_Master_Renaming (procedure)): Moved to exp_ch9.
416 (Expand_Full_Type_Declaration): Alphabetize
417 variables. Reformatting of code and comments. Rewrite the
418 section on processing of anonymous access-to-task types in
419 record components.
420 * exp_ch3.ads (Build_Class_Wide_Master): Moved to exp_ch9.
421 (Build_Master_Renaming): Moved to exp_ch9.
422 * exp_ch9.adb (Build_Class_Wide_Master): Moved from exp_ch3.
423 (Build_Master_Entity): Add formal parameter
424 Use_Current. Reformatting of code and comments.
425 (Build_Master_Renaming): Moved from exp_ch3.
426 * exp_ch9.ads (Build_Class_Wide_Master): Moved from
427 exp_ch3. Update comment on usage.
428 (Build_Master_Entity):
429 Add formal parameter Use_Current. Update comment on usage.
430 (Build_Master_Renaming): Moved from exp_ch3.
431 * sem_ch3.adb (Access_Definition): Remove redundant code to
432 create a _master and a renaming.
433
4342011-10-13 Ed Schonberg <schonberg@adacore.com>
435
436 * lib-xref.adb: Do no emit reference to overridden operation,
437 if it is internally generated.
438
4392011-10-13 Vincent Celier <celier@adacore.com>
440
441 * bindgen.adb: Remove any processing related to g-trasym
442 * Makefile.rtl: Add g-trasym.o to GNATRTL_NONTASKING_OBJS
443 * mlib-prj.adb: Remove any processing related to g-trasym.
444
0cfaf83f
EB
4452011-10-12 Eric Botcazou <ebotcazou@adacore.com>
446
447 * sem_util.adb (Denotes_Same_Prefix): Fix fatal warning.
448 * gcc-interface/Make-lang.in (WARN_ADAFLAGS): New.
449 (ALL_ADAFLAGS): Include WARN_ADAFLAGS.
450 (ADA_FLAGS_TO_PASS): Likewise.
451 (COMMON_FLAGS_TO_PASS): New.
452 (ADA_TOOLS_FLAGS_TO_PASS): Use COMMON_FLAGS_TO_PASS. In the regular
453 native case, also use FLAGS_TO_PASS and ADA_FLAGS_TO_PASS.
454 (gnatlib): Use COMMON_FLAGS_TO_PASS.
455 (ada.install-common): Likewise.
456 (install-gnatlib): Likewise.
457 (install-gnatlib-obj): Likewise.
458 (gnattools): Use ADA_TOOLS_FLAGS_TO_PASS for gnattools1 as well.
459 (gnat-cross): Delete.
460 (gnatboot): Likewise.
461 (gnatboot2): Likewise.
462 (gnatboot3): Likewise.
463 (gnatstage1): Likewise.
464 (gnatstage2): Likewise.
465 * gcc-interface/Makefile.in (SOME_ADAFLAGS): Likewise.
466 (MOST_ADAFLAGS): Likewise.
467 (LOOSE_CFLAGS): Likewise.
468 (gnat-cross): Likewise.
469 (GNATLIBFLAGS): Add -W -Wall.
470 (GNATLIBCFLAGS_FOR_C): Likewise.
471 * gcc-interface/lang.opt: Remove C-specific warnings. Add doc lines.
472 * gcc-interface/misc.c (gnat_handle_option): Remove obsolete cases.
473
722356ce
EB
4742011-10-12 Eric Botcazou <ebotcazou@adacore.com>
475
476 * gcc-interface/trans.c (Attribute_to_gnu): Use remove_conversions.
477 (push_range_check_info): Likewise.
478 (gnat_to_gnu) <N_Code_Statement>: Likewise.
479 * gcc-interface/utils2.c (build_unary_op) <INDIRECT_REF>: Likewise.
480 (gnat_invariant_expr): Likewise.
481 * gcc-interface/utils.c (compute_related_constant): Likewise.
482 (max_size): Fix handling of SAVE_EXPR.
483 (remove_conversions): Fix formatting.
484
15bf7d19
EB
4852011-10-12 Eric Botcazou <ebotcazou@adacore.com>
486
487 * gcc-interface/ada-tree.h (DECL_LOOP_PARM_P): New flag.
488 (DECL_INDUCTION_VAR): New macro.
489 (SET_DECL_INDUCTION_VAR): Likewise.
490 * gcc-interface/gigi.h (convert_to_index_type): Declare.
491 (gnat_invariant_expr): Likewise.
492 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: If this is a loop
493 parameter, set DECL_LOOP_PARM_P on it.
494 * gcc-interface/misc.c (gnat_print_decl) <VAR_DECL>: If DECL_LOOP_PARM_P
495 is set, print DECL_INDUCTION_VAR instead of DECL_RENAMED_OBJECT.
496 * gcc-interface/trans.c (gnu_loop_label_stack): Delete.
497 (struct range_check_info_d): New type.
498 (struct loop_info_d): Likewise.
499 (gnu_loop_stack): New stack.
500 (Identifier_to_gnu): Set TREE_READONLY flag on the first dereference
501 built for a by-double-ref read-only parameter. If DECL_LOOP_PARM_P
502 is set, do not test DECL_RENAMED_OBJECT.
503 (push_range_check_info): New function.
504 (Loop_Statement_to_gnu): Push a new struct loop_info_d instead of just
505 the label. Reference the label and the iteration variable from it.
506 Build the special induction variable in the unsigned version of the
507 size type, if it is larger than the base type. And attach it to the
508 iteration variable if the latter isn't by-ref. In the iteration scheme
509 case, initialize the invariant conditions in front of the loop if
510 deemed profitable. Use gnu_loop_stack.
511 (gnat_to_gnu) <N_Exit_Statement>: Use gnu_loop_stack.
512 <N_Raise_Constraint_Error>: Always process the reason. In the range
513 check and related cases, and if loop unswitching is enabled, compute
514 invariant conditions and push this information onto the stack.
515 Do not translate again the condition if it has been already translated.
516 * gcc-interface/utils.c (record_global_renaming_pointer): Assert that
517 DECL_LOOP_PARM_P isn't set.
518 (convert_to_index_type): New function.
519 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Use it in order
520 to convert the index from the base index type to sizetype.
521 (gnat_invariant_expr): New function.
522
e79983f4
MM
5232011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
524
525 * gcc-interface/utils.c (def_builtin_1): Delete old interface with
526 two parallel arrays to hold standard builtin declarations, and
527 replace it with a function based interface that can support
15bf7d19 528 creating builtins on the fly in the future.
e79983f4
MM
529 * gcc-interface/trans.c (Exception_Handler_to_gnu_zcx): Ditto.
530 (gnat_to_gnu): Ditto.
531
228ee426
EB
5322011-10-07 Eric Botcazou <ebotcazou@adacore.com>
533
534 PR lto/50492
535 * gcc-interface/gigi.h (gnat_pushdecl): Adjust comment.
536 * gcc-interface/utils.c (global_context): New variable.
537 (gnat_pushdecl): Initialize it and set it as the DECL_CONTEXT of DECLs
538 that are either public external or at top level. Use "No" macro.
539 (end_subprog_body): Call decl_function_context.
540 (rest_of_subprog_body_compilation): Likewise.
541
71196d4e
EB
5422011-10-07 Eric Botcazou <ebotcazou@adacore.com>
543
544 * gcc-interface/gigi.h (gnat_useless_type_conversion): Declare.
545 (rest_of_subprog_body_compilation): Likewise.
546 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Variable>: For renaming,
547 test for useless conversions by means of gnat_useless_type_conversion.
548 * gcc-interface/trans.c: Include bitmap.h and cgraph.h.
549 (language_function): Add named_ret_val and other_ret_val.
550 (f_named_ret_val): New macro.
551 (f_other_ret_val): Likewise.
552 (gigi): Call rest_of_subprog_body_compilation.
553 (struct nrv_data): New structure.
554 (is_nrv_p): New predicate.
555 (prune_nrv_r): New helper function.
556 (prune_nrv_in_block): New function.
557 (finalize_nrv_r): New helper function.
558 (finalize_nrv): New function.
559 (return_value_ok_for_nrv_p): New predicate.
560 (build_return_expr): If optimization is enabled, record candidates for
561 the Named Return Value optimization.
562 (build_function_stub): Call rest_of_subprog_body_compilation.
563 (Subprogram_Body_to_gnu): If optimization is enabled and there are
564 candidates, finalize the Named Return Value optimization.
565 Call rest_of_subprog_body_compilation.
566 (call_to_gnu): At the end, if a return value is needed, simplify the
567 result before wrapping it up in a COMPOUND_EXPR.
568 * gcc-interface/utils.c (end_subprog_body): Split into...
569 (rest_of_subprog_body_compilation): ...this. New function.
570 (gnat_useless_type_conversion): Likewise.
571
885c4871
AC
5722011-10-06 Thomas Quinot <quinot@adacore.com>
573
574 * einfo.ads, exp_attr.adb, exp_ch3.adb, exp_ch4.adb, exp_ch7.adb,
575 exp_ch9.adb, exp_ch9.ads, exp_strm.adb, exp_util.adb, freeze.adb,
576 g-debpoo.ads, opt.ads, par-ch12.adb, par-ch2.adb, par-ch3.adb,
577 par-ch5.adb, par-ch6.adb, sem_aggr.adb, sem_attr.adb, sem_cat.adb,
578 sem_ch10.adb, sem_ch12.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
579 sem_ch6.adb, sem_intr.adb, sem_res.ads, sem_type.adb, sem_util.adb,
580 s-regpat.adb, s-tpopde-vms.ads: Minor reformatting.
581 * s-osinte-freebsd.ads: Fix for tasking failures on FreeBSD.
582
5832011-10-06 Ed Schonberg <schonberg@adacore.com>
584
585 * a-cihase.adb, a-ciorma.adb: Avoid accessibility checks in container
586 references.
587
5882011-10-06 Matthew Heaney <heaney@adacore.com>
589
590 * a-cuprqu.ads, a-cuprqu.adb, a-cbprqu.ads, a-cbprqu.adb
591 (Dequeue_Only_High_Priority): Protected procedure now implemented.
592
5932011-10-06 Vincent Celier <celier@adacore.com>
594
595 * g-trasym.adb: Replace old implementation with the default
596 implementation that returns list of addresses as "0x...".
597 * g-trasym.ads: Update the list of platforms with the full
598 capability. Indicate that there is a default implementation
599 for other platforms.
600 * g-trasym-unimplemented.ads, g-trasym-unimplemented.adb: Remove.
601 * gcc-interface/Makefile.in: Remove g-trasym-unimplemented, as there
602 is now a default implementation for all platforms without the full
603 capability.
604
ce72a9a3
AC
6052011-10-06 Robert Dewar <dewar@adacore.com>
606
607 * a-ciorse.adb, a-cihase.adb, a-cihase.ads, a-coorse.adb,
608 a-cborse.adb, a-comutr.adb, a-ciorma.adb, a-cbmutr.adb,
609 a-cbmutr.ads, a-cbhase.adb, a-cbhase.ads: Minor reformatting and code
610 reorganization (use conditional expressions).
611
6122011-10-06 Robert Dewar <dewar@adacore.com>
613
614 * sem_res.adb (Resolve_Arithmetic_Op): Fix bad warning for
615 floating divide by zero.
616
6172011-10-06 Ed Schonberg <schonberg@adacore.com>
618
619 * sem_ch6.adb: Limited interfaces that are not immutably limited
620 are OK in return statements.
621
a912d7d9
IS
6222011-09-30 Iain Sandoe <iains@gcc.gnu.org>
623
624 * gcc-interface/Makefile.in (Darwin): Partial reversion of previous
625 change to powerpc section.
626
39ffb1f9
IS
6272011-09-29 Iain Sandoe <iains@gcc.gnu.org>
628
629 * gcc-interface/Makefile.in (Darwin): Factor LIBGNAT_TARGET_PAIRS
630 across the port.
631
ffb35bbf
ES
6322011-09-27 Ed Schonberg <schonberg@adacore.com>
633
634 * a-cbhase.adb, a-cbhase.ads, a-cborse.adb, a-cborse.ads,
635 a-cihase.adb, a-cihase.ads, a-ciorse.adb, a-ciorse.ads,
636 a-coorse.adb, a-coorse.ads: Add iterator machinery to bounded sets and
637 indefinite sets.
638 * a-coorma.ads: Minor reformmating.
639 * einfo.ads: Improve the comment describing the
640 Directly_Designated_Type function.
641 * a-ciorma.adb, a-ciorma.ads: Add iterator machinery to indefinite
642 ordered maps.
643 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
644 dependencies.
645
da124b6a
AC
6462011-09-27 Robert Dewar <dewar@adacore.com>
647
648 * a-comutr.ads: Minor reformatting.
649
6502011-09-27 Ed Schonberg <schonberg@adacore.com>
651
652 * a-cimutr.adb, a-cimutr.ads, a-cbmutr.adb, a-cbmutr.ads: Add children
653 iterators to multiway trees.
654
6552011-09-27 Yannick Moy <moy@adacore.com>
656
657 * debug.adb (d.D): New option for strict Alfa mode.
658 * opt.ads (Strict_Alfa_Mode): New flag to interpret compiler
659 permissions as strictly as possible.
660 * sem_ch3.adb (Signed_Integer_Type_Declaration): In non-strict
661 Alfa mode, now, interpret ranges of base types like GNAT does; in
662 strict mode, simply change the range of the implicit base Itype.
663 * gnat1drv.adb: Update comments. Set Strict_Alfa_Mode.
664
706a4067
AC
6652011-09-27 Robert Dewar <dewar@adacore.com>
666
667 * exp_ch9.adb: Minor comment fixes.
668
6692011-09-27 Ed Schonberg <schonberg@adacore.com>
670
671 * a-comutr.adb, a-comutr.ads: Add children iterators on multiway
672 trees.
673
05c1e7d2
AC
6742011-09-27 Eric Botcazou <ebotcazou@adacore.com>
675
676 * checks.adb (Apply_Scalar_Range_Check): Use Designated_Type
677 instead of Directly_Designated_Type in the indirect array case.
678
6792011-09-27 Robert Dewar <dewar@adacore.com>
680
681 * exp_util.adb, exp_aggr.adb: Minor reformatting.
682
65e78a74
AC
6832011-09-27 Ed Schonberg <schonberg@adacore.com>
684
685 * sinfo.ads, par-ch3.adb: Minor comment update: aspect specification
686 on subtype declarations.
687 * exp_aggr.adb: Minor comment update.
688
6892011-09-27 Eric Botcazou <ebotcazou@adacore.com>
690
691 * exp_util.adb (Safe_Prefixed_Reference): Remove always-false
692 test in the N_Explicit_Dereference case. Fold double logical
693 negation in the special loop case and conditionalize it on
694 Variable_Ref being true.
695
6962011-09-27 Ed Schonberg <schonberg@adacore.com>
697
698 * sem_ch4.adb (Analyze_Selected_Component): If the prefix is a
699 single protected object and the selector is a discriminant or an
700 entry family, this is a non-overloaded candidate interpretation,
701 and possible primitive operations of the type must not be
702 examined.
703
7042011-09-27 Arnaud Charlet <charlet@adacore.com>
705
706 * s-taspri-posix-noaltstack.ads (Lock): Mark fields aliased.
707
6f5add73
AC
7082011-09-27 Pascal Obry <obry@adacore.com>
709
710 * s-osinte-hpux.ads, s-osinte-aix.ads, s-osinte-solaris-posix.ads,
711 s-osinte-irix.ads, s-osinte-darwin.ads, s-osinte-freebsd.ads:
712 Add dummy definitions for pthread_rwlock_t
713 and pthread_rwlockattr_t on all POSIX platforms.
714 * s-taprop-irix.adb, s-taprop-posix.adb (Initialize_Lock): Fix lock
715 reference.
716 (Finalize_Lock): Likewise.
717 (Write_Lock): Likewise.
718 (Unlock): Likewise.
719
7202011-09-27 Tristan Gingold <gingold@adacore.com>
721
722 * s-tassta.adb (Task_Wrapper): Increase Guard_Page_Size value for
723 windows 64.
724
64a63cd5
PO
7252011-09-27 Pascal Obry <obry@adacore.com>
726
727 * s-osinte-hpux.ads, s-taprop-vxworks.adb, s-taspri-vxworks.ads,
728 s-taprop-tru64.adb, s-osinte-aix.ads, s-taspri-posix-noaltstack.ads,
729 s-taspri-mingw.ads, s-taprop-vms.adb, s-tpoben.adb, s-tpoben.ads,
730 s-taprop-mingw.adb, s-taprob.adb, s-taprob.ads,
731 s-osinte-solaris-posix.ads, s-taprop-solaris.adb, s-taspri-solaris.ads,
732 s-osinte-irix.ads, s-taprop-irix.adb, s-osinte-darwin.ads,
733 s-taspri-dummy.ads, s-taspri-posix.ads, s-taprop.ads,
734 s-taspri-vms.ads, s-osinte-freebsd.ads, s-taprop-hpux-dce.adb,
735 s-taspri-hpux-dce.ads, s-taspri-tru64.ads, s-taprop-dummy.adb,
736 s-taprop-posix.adb: Revert previous changes.
737 (Lock): Now a record containing the two possible lock
738 (mutex and read/write) defined in OS_Interface.
739 * s-taprop-linux.adb (Finalize_Protection): Use r/w lock for
740 'R' locking policy.
741 (Initialize_Protection): Likewise.
742 (Lock): Likewise.
743 (Lock_Read_Only): Likewise.
744 (Unlock): Likewise.
745
f672a756
AC
7462011-09-27 Pascal Obry <obry@adacore.com>
747
748 * s-taspri-posix-noaltstack.ads (RW_Lock): This type is now defined as
749 OS_Interface.pthread_rwlock_t.
750
7512011-09-27 Robert Dewar <dewar@adacore.com>
752
753 * exp_ch9.adb, a-cimutr.adb, a-cimutr.ads, gnat1drv.adb, a-comutr.adb,
754 a-comutr.ads, exp_dist.adb, a-cbmutr.adb, a-cbmutr.ads,
755 sem_ch5.adb, sem_util.adb: Minor reformatting.
756
7a44cb69
PO
7572011-09-27 Pascal Obry <obry@adacore.com>
758
759 * s-taprop.ads (Initialize_Lock)[RW_Lock]: New spec for r/w lock.
760 (Finalize_Lock)[RW_Lock]: Likewise.
761 (Write_Lock)[RW_Lock]: Likewise.
762 (Unlock)[RW_Lock]: Likewise.
763 (Read_Lock): Define L as RW_Lock (instead of Lock).
764 * s-taprop-linux.adb (Initialize_Lock)[RW_Lock]: New
765 routine for r/w lock.
766 (Finalize_Lock)[RW_Lock]: Likewise.
767 (Write_Lock)[RW_Lock]: Likewise.
768 (Unlock)[RW_Lock]: Likewise.
769 (Read_Lock): Define L as RW_Lock (instead of Lock).
770
771 * s-taprop-vxworks.adb, s-taprop-tru64.adb, s-taprop-vms.adb,
772 s-taprop-mingw.adb, s-taprop-solaris.adb, s-taprop-irix.adb,
773 s-taprop-hpux-dce.adb, s-taprop-dummy.adb, s-taprop-posix.adb
774 (Initialize_Lock)[RW_Lock]: Same implementation as corresponding
775 routine for standard lock.
776 (Finalize_Lock)[RW_Lock]: Likewise.
777 (Write_Lock)[RW_Lock]: Likewise.
778 (Unlock)[RW_Lock]: Likewise.
779 (Read_Lock): Define L as RW_Lock (instead of Lock).
780 * s-taprob.ads, s-tpoben.ads (Protection): Add RWL (RW_Lock)
781 in the record definition.
782 * s-taprob.adb, s-taproben.adb (Finalize_Protection): Use r/w
783 lock for 'R' locking policy.
784 (Initialize_Protection): Likewise.
785 (Lock): Likewise.
786 (Lock_Read_Only): Likewise.
787 (Unlock): Likewise.
788 * s-taspri-posix.ads (RW_Lock): New type defined as
789 OS_Interface.pthread_rwlock_t.
790
791 * s-taspri-vxworks.ads, s-taspri-posix-noaltstack.ads,
792 s-taspri-mingw.ads, s-taspri-solaris.ads, s-taspri-dummy.ads,
793 s-taspri-posix.ads, s-taspri-vms.ads, s-taspri-hpux-dce.ads,
794 s-taspri-tru64.ads (RW_Lock): New type defined as alias to Lock.
795
4c173b50
PO
7962011-09-27 Pascal Obry <obry@adacore.com>
797
798 * exp_ch9.adb, s-taspri-posix.ads: Minor reformatting.
799
8002011-09-27 Pascal Obry <obry@adacore.com>
801
802 * s-osinte-aix.ads, s-osinte-darwin.ads, s-osinte-freebsd.ads,
803 s-osinte-hpux.ads, s-osinte-irix.ads,
804 s-osinte-solaris-posix.ads (pthread_rwlock_t): New definition alias of
805 pthread_mutex_t.
806 (pthread_rwlockattr_t): New definition alias of pthread_mutexattr_t.
807 * s-osinte-linux.ads (pthread_rwlock_t, pthread_rwlockattr_t,
808 pthread_rwlockattr_init, pthread_rwlockattr_destroy,
809 pthread_rwlockattr_setkind_np, pthread_rwlock_init,
810 pthread_rwlock_destroy, pthread_rwlock_rdlock,
811 pthread_rwlock_wrlock, pthread_rwlock_unlock): New.
812
343250a6
PO
8132011-09-27 Pascal Obry <obry@adacore.com>
814
815 * rtsfind.ads: Add RE_Lock_Read_Only into rtsfind circuitry.
816 (RE_Id): Add RE_Lock_Read_Only.
817 (RE_Unit_Table): Likewise.
818 * sem_prag.adb (Process_Convention): Change Pragma_Locking_Policy
819 to lift restriction on first character. Handle now the
820 Name_Concurrent_Readers_Locking where policy character is set to
821 'R'.
822 * snames.ads-tmpl (Name_Concurrent_Readers_Locking): New
823 constant.
824 * exp_ch9.adb (Build_Protected_Subprogram_Body): Generate a
825 read only lock for function in protected object.
826 * s-taprob.ads (Lock_Read_Only): Remove obsolete comment as
827 this routine is now used.
828
2d0dd51a
EB
8292011-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
830
831 * s-atocou-x86.adb (Decrement): Use %;.
832 (Increment): Likewise.
833
bdbebf66
EB
8342011-09-26 Eric Botcazou <ebotcazou@adacore.com>
835
836 * gcc-interface/utils2.c (build_allocator): Set TREE_THIS_NOTRAP on the
837 dereference of the pointer to the storage area. Remove useless type
838 conversions and factor out common code.
839
1aa291f7
EB
8402011-09-26 Eric Botcazou <ebotcazou@adacore.com>
841
842 * gcc-interface/utils.c (maybe_unconstrained_array): Declare TYPE local
843 variable and use it throughout.
844 <UNCONSTRAINED_ARRAY_TYPE>: Add 'break' at the end.
845 <RECORD_TYPE>: Do not unconditionally convert to the unpadded type as a
846 first step. Also convert to the unpadded type as a last step.
847
7d76717d
EB
8482011-09-26 Eric Botcazou <ebotcazou@adacore.com>
849
850 * gcc-interface/gigi.h (create_subprog_decl): Replace TREE_CHAIN with
851 DECL_CHAIN in comment.
852 * gcc-interface/trans.c (gigi): Likewise.
853 (Attribute_to_gnu): Likewise.
854 (build_function_stub): Likewise.
855 (gnat_to_gnu): Likewise.
856 * gcc-interface/utils.c (create_subprog_decl): Likewise.
857 (convert_vms_descriptor64): Likewise.
858 (convert_vms_descriptor32): Likewise.
859
42acad07
EB
8602011-09-26 Eric Botcazou <ebotcazou@adacore.com>
861
862 * gcc-interface/trans.c (assoc_to_constructor): Minor tweaks.
863 * gcc-interface/utils2.c (build_simple_component_ref): Fix formatting
864 issues. Use COMPLETE_TYPE_P in assertion. Also set TREE_READONLY if
865 the type of the record is TYPE_READONLY.
866
a1d72281
EB
8672011-09-26 Eric Botcazou <ebotcazou@adacore.com>
868 Robert Dewar <dewar@adacore.com>
869
870 * sem_ch6.adb (Set_Formal_Mode): Set Can_Never_Be_Null on an IN or IN
871 OUT formal parameter which is of an null-exclusion access subtype.
872
a1c7d797
EB
8732011-09-26 Eric Botcazou <ebotcazou@adacore.com>
874
875 * gcc-interface/ada-tree.h (DECL_CAN_NEVER_BE_NULL_P): New macro.
876 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Set the flag.
877 (gnat_to_gnu_param): Likewise.
878 * gcc-interface/utils.c (convert) <UNCONSTRAINED_ARRAY_REF>: Invoke
879 maybe_unconstrained_array instead of doing the work manually.
880 (maybe_unconstrained_array): Propagate the TREE_THIS_NOTRAP flag.
881 * gcc-interface/utils2.c (build_unary_op) <INDIRECT_REF>: If operand
882 is a DECL with the flag, set TREE_THIS_NOTRAP on the reference.
883 (gnat_stabilize_reference_1): Propagate the TREE_THIS_NOTRAP flag.
884 (gnat_stabilize_reference): Likewise.
885
50179d58
EB
8862011-09-26 Eric Botcazou <ebotcazou@adacore.com>
887
888 * gcc-interface/ada-tree.h (TYPE_NULL_BOUNDS): New macro.
889 (SET_TYPE_NULL_BOUNDS): Likewise.
890 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Set again
891 TREE_THIS_NOTRAP on the INDIRECT_REF node built for the template.
892 * gcc-interface/trans.c (Identifier_to_gnu): Return initializers of fat
893 pointer types.
894 * gcc-interface/utils.c (create_var_decl_1): If the object is external,
895 check that the initializer is a valid constant expression for use in
896 initializing a static variable. Add missing guard.
897 (update_pointer_to): Adjust TYPE_NULL_BOUNDS if set.
898 (convert_to_fat_pointer): In the null fat pointer case, build a valid
899 pointer for the bounds.
900 * gcc-interface/utils2.c (compare_fat_pointers): New function.
901 (build_binary_op) <EQ_EXPR>: Call it to compare fat pointers.
902
ad1d36ba
EB
9032011-09-25 Eric Botcazou <ebotcazou@adacore.com>
904
905 * gcc-interface/ada-tree.h (TREE_THIS_NOTRAP): Redefine.
906 * gcc-interface/trans.c (Identifier_to_gnu): Factor out common code in
907 the by-ref case. Do not set TREE_READONLY on a renamed object. Set
908 TREE_THIS_NOTRAP on UNCONSTRAINED_ARRAY_REF nodes.
909 (Attribute_to_gnu) <Attr_Length>: Expand the use of the parameter cache
910 to the indirect case.
911 * gcc-interface/utils.c (convert) <UNCONSTRAINED_ARRAY_REF>: Preserve
912 the TREE_THIS_NOTRAP flag.
913
6162cec0
EB
9142011-09-25 Eric Botcazou <ebotcazou@adacore.com>
915
916 * gcc-interface/trans.c (Loop_Statement_to_gnu): In the case of an
917 iteration scheme, always generate the do-while form if optimization
918 is enabled. Use more straightforward test at the end.
919
dee12fcd
EB
9202011-09-25 Eric Botcazou <ebotcazou@adacore.com>
921
922 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Subtype>: Use
923 XNEW instead of xmalloc. Do not build useless pointer type.
924 <E_Anonymous_Access_Subprogram_Type>: Use XNEW instead of xmalloc.
925 * gcc-interface/trans.c (gnat_to_gnu) <N_Raise_Constraint_Error>: Tidy.
926 * gcc-interface/utils2.c (build_unary_op): Remove local variable.
927
dea976c4
EB
9282011-09-25 Eric Botcazou <ebotcazou@adacore.com>
929
930 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Do not promote
931 the alignment if this doesn't prevent BLKmode access to the object.
932
655ae828
IS
9332011-09-24 Iain Sandoe <iains@gcc.gnu.org>
934
935 * gcc-interface/Makefile.in (darwin): Do not issue the
936 '-flat_namespace' linker flag during Ada build.
937 * mlib-tgt-specific-darwin.adb: Remove '-flat_namespace' flag from the
938 default shared library options.
939
0e871c15
AO
9402011-09-19 Alexandre Oliva <aoliva@redhat.com>
941
942 * gcc-interface/decl.c (annotate_value): Look up expression for
943 insertion in the cache at the end.
944
1e6a52b4
AC
9452011-09-19 Arnaud Charlet <charlet@adacore.com>
946
947 * gcc-interface/Make-lang.in: Update dependencies.
948
a3068ca6
AC
9492011-09-19 Steve Baird <baird@adacore.com>
950
951 * snames.ads-tmpl: Move declaration of Name_Annotate into range of
952 configuration pragma names so that Is_Configuration_Pragma_Name
953 will return True for Name_Annotate. Make corresponding change in
954 Pragma_Id enumeration type. This is needed to allow an Annotate
955 pragma to occur in a configuration pragma file (typically,
956 a gnat.adc file).
957 * gnat_ugn.texi: Add Annotate to the list of configuration pragmas.
958 * gnat_rm.texi: Note that pragma Annotate may be used as a
959 configuration pragma.
960
9612011-09-19 Ed Schonberg <schonberg@adacore.com>
962
963 * a-cbmutr.adb, a-cbmutr.ads, a-cimutr.adb, a-cimutr.ads,
964 a-comutr.adb, a-comutr.ads: Add iterator machinery for multiway trees.
965
9662011-09-19 Yannick Moy <moy@adacore.com>
967
968 * exp_alfa.adb, exp_alfa.ads (Expand_Alfa_N_In): New function
969 for expansion of set membership.
970 (Expand_Alfa): Call expansion for N_In and N_Not_In nodes.
971 * exp_ch4.adb, exp_ch4.ads (Expand_Set_Membership): Make procedure
972 visible for use in Alfa expansion.
973 * sem_ch5.adb (Analyze_Iterator_Specification): Introduce loop
974 variable in Alfa mode.
975
9762011-09-19 Thomas Quinot <quinot@adacore.com>
977
978 * s-osinte-darwin.ads: Change SIGADAABRT on Darwin to SIGABRT.
979
9802011-09-19 Thomas Quinot <quinot@adacore.com>
981
982 * exp_ch9.adb: Minor reformatting.
983
9842011-09-19 Hristian Kirtchev <kirtchev@adacore.com>
985
986 * freeze.adb (Build_Renamed_Body): Generic subprograms
987 instantiations cannot be poperly inlined by the compiler, do
988 not set the Body_To_Inline attribute in such cases.
989 * sem_ch12.adb (Analyze_Subprogram_Instantiation): Inherit all
990 inlining-related flags from the generic subprogram declaration.
991
9922011-09-19 Thomas Quinot <quinot@adacore.com>
993
994 * exp_dist.adb, rtsfind.ads, sem_util.adb, sem_util.ads
995 (Build_Stub_Type): Remove, instead copy components from
996 System.Partition_Interface.RACW_Stub_Type.
997 (RPC_Receiver_Decl): Remainder of code from old Build_Stub_Type routine.
998 (Copy_Component_List): New subprogram.
999
10002011-09-19 Yannick Moy <moy@adacore.com>
1001
1002 * lib-xref.adb (Generate_Reference): Ignore references to
1003 constants in Standard.
1004
e7fceebc
AC
10052011-09-19 Robert Dewar <dewar@adacore.com>
1006
1007 * err_vars.ads, errout.ads: Minor reformatting.
1008
10092011-09-19 Robert Dewar <dewar@adacore.com>
1010
1011 * aspects.ads (Impl_Defined_Aspects): New array
1012 * lib-writ.adb (No_Dependences): New name for No_Dependence
1013 * restrict.adb (No_Dependences): New name for No_Dependence
1014 (Check_Restriction_No_Specification_Of_Aspect): New
1015 procedure.
1016 (Set_Restriction_No_Specification_Of_Aspect): New procedure
1017 (Restricted_Profile_Result): New variable
1018 (No_Specification_Of_Aspects): New variable
1019 (No_Specification_Of_Aspect_Warning): New variable
1020 * restrict.ads (No_Dependences): New name for No_Dependence
1021 (Check_Restriction_No_Specification_Of_Aspect): New procedure
1022 (Set_Restriction_No_Specification_Of_Aspect): New procedure
1023 * s-rident.ads: Add restriction
1024 No_Implementation_Aspect_Specifications, this is also added to
1025 the No_Implementation_Extensions profile.
1026 * sem_ch13.adb (Analyze_Aspect_Specifications): Check
1027 No_Implementation_Defined_Aspects
1028 (Analyze_Aspect_Specifications): Check No_Specification_Of_Aspect
1029 * sem_prag.adb (Analyze_Aspect_Specifications): Check
1030 No_Implementation_Aspects
1031 (Analyze_Aspect_Specifications): Check No_Specification_Of_Aspect
1032 * snames.ads-tmpl (Name_No_Specification_Of_Aspect): New name
1033
10342011-09-19 Yannick Moy <moy@adacore.com>
1035
1036 * lib-xref.adb (Generate_Reference): Take into account multiple
1037 renamings for Alfa refs.
1038
10392011-09-19 Thomas Quinot <quinot@adacore.com>
1040
1041 * g-socthi-mingw.adb: Minor reformatting.
1042
10432011-09-19 Yannick Moy <moy@adacore.com>
1044
1045 * gnat1drv.adb (Adjust_Global_Switches): Set tagged type
1046 expansion to False in mode Alfa
1047
10482011-09-19 Pascal Obry <obry@adacore.com>
1049
1050 * mingw32.h: Remove obsolete code needed for old versions
1051 of MingW.
1052
e5a163fc
RD
10532011-09-19 Robert Dewar <dewar@adacore.com>
1054
1055 * errout.ads: Minor reformatting.
1056
6d7e5c54
AC
10572011-09-19 Ed Schonberg <schonberg@adacore.com>
1058
1059 * sem_ch6.adb (Analyze_Expression_Function): When the expression
1060 function is transformed into a declaration and a body, insert
1061 body at the end of the declarative part, to prevent premature
1062 freeze actions, and preserve original specification in the
1063 subprogram declaration.
1064
10652011-09-19 Vincent Celier <celier@adacore.com>
1066
1067 * projects.texi: Minor editing.
1068
99ba07a3
AC
10692011-09-19 Robert Dewar <dewar@adacore.com>
1070
1071 * sem_aggr.adb, lib-writ.ads, s-restri.ads, sem_ch6.adb,
1072 exp_aggr.adb: Minor reformatting.
1073
10742011-09-19 Yannick Moy <moy@adacore.com>
1075
1076 * lib-xref.adb (Generate_Reference): Change entity referenced
1077 to underlying object if any, or else reference to the HEAP.
1078
41781043
AC
10792011-09-15 Arnaud Charlet <charlet@adacore.com>
1080
1081 * gcc-interface/Make-lang.in: Update dependencies.
1082
804ff4c3
AC
10832011-09-15 Robert Dewar <dewar@adacore.com>
1084
1085 * tree_io.ads: Minor reformatting.
1086 * a-intnam.ads: Fix bad header.
1087
10882011-09-15 Thomas Quinot <quinot@adacore.com>
1089
1090 * a-exexpr-gcc.adb: Minor reformatting.
1091
10922011-09-15 Yannick Moy <moy@adacore.com>
1093
1094 * sem_ch6.adb: Propagate information that an expression function comes
1095 from source (otherwise references to this entity are not stored).
1096
0b5b2bbc
AC
10972011-09-15 Robert Dewar <dewar@adacore.com>
1098
1099 * a-cdlili.adb, a-coinve.adb, a-stzunb-shared.ads, a-suezst.adb,
1100 a-suenco.adb, a-stwiun-shared.ads, a-cobove.adb, a-convec.adb,
1101 a-btgbso.adb, a-cbdlli.adb, a-suewst.adb: Minor reformatting.
1102
11032011-09-15 Ed Schonberg <schonberg@adacore.com>
1104
1105 * sem_ch6.adb (Analyze_Expression_Function): Code cleanup:
1106 if the expression function is not a completion, create a
1107 new specification for the generated declaration, and keep the
1108 original specification in the generated body. Shorter code also
1109 ensures that proper warnings are generated for unused formals
1110 in all cases.
1111
11122011-09-15 Sergey Rybin <rybin@adacore.com>
1113
1114 * tree_io.ads: Update ASIS_Version_Number because of the changes
1115 in the tree structures for expression functions.
1116
11172011-09-15 Arnaud Charlet <charlet@adacore.com>
1118
1119 * s-osinte-aix.ads, s-osinte-darwin.ads, s-osinte-freebsd.ads,
1120 s-osinte-hpux.ads, s-osinte-lynxos.ads, s-osinte-solaris-posix.ads,
1121 s-taprop-posix.adb (CLOCK_MONOTONIC): New constant.
1122 (CLOCK_REALTIME): Fix wrong value on some OSes.
1123 * s-taprop-posix.adb (Monotonic_Clock): Use CLOCK_MONOTONIC.
1124
7e169899
EB
11252011-09-11 Eric Botcazou <ebotcazou@adacore.com>
1126
1127 * gcc-interface/utils.c (maybe_unconstrained_array): In the reference
1128 to unconstrained array case, deal with each branch of a COND_EXPR.
1129 * gcc-interface/utils2.c (build_allocator): Deal with each branch of
1130 a COND_EXPR in the initializer, if present.
1131
819a653e
EB
11322011-09-11 Eric Botcazou <ebotcazou@adacore.com>
1133
1134 * gcc-interface/decl.c (maybe_pad_type): Do not try to change the form
1135 of an addressable type.
1136 * gcc-interface/trans.c (gnat_gimplify_expr) <VIEW_CONVERT_EXPR>: New.
1137 Deal with those cases for which creating a temporary is mandatory.
1138
c946adde
EB
11392011-09-11 Eric Botcazou <ebotcazou@adacore.com>
1140
1141 * gcc-interface/trans.c (call_to_gnu): Use local variable. Make sure
1142 this is a real formal parameter before testing whether it is by ref.
1143
dddf8120
EB
11442011-09-11 Eric Botcazou <ebotcazou@adacore.com>
1145
1146 * gcc-interface/gigi.h (build_call_0_expr): Delete.
1147 (build_call_1_expr): Likewise.
1148 (build_call_2_expr): Likewise.
1149 (build_call_n_expr): New prototype.
1150 * gcc-interface/decl.c (gnat_to_gnu_entity): Use build_call_n_expr.
1151 * gcc-interface/trans.c (establish_gnat_vms_condition_handler): Ditto.
1152 (Handled_Sequence_Of_Statements_to_gnu): Likewise.
1153 (Exception_Handler_to_gnu_zcx): Likewise.
1154 (gnat_to_gnu): Likewise.
1155 (build_binary_op_trapv): Likewise.
1156 * gcc-interface/utils2.c (build_call_0_expr): Delete.
1157 (build_call_1_expr): Likewise.
1158 (build_call_2_expr): Likewise.
1159 (build_call_n_expr): New function.
1160 (build_call_raise): Use build_call_n_expr.
1161 (build_call_raise_range): Likewise.
1162 (build_call_raise_column): Likewise.
1163 (build_call_alloc_dealloc_proc): Likewise.
1164 (maybe_wrap_malloc): Likewise.
1165 (maybe_wrap_free): Likewise.
1166
d8e38554
EB
11672011-09-11 Eric Botcazou <ebotcazou@adacore.com>
1168
1169 * gcc-interface/trans.c (build_return_expr): Use void_type_node for
1170 MODIFY_EXPR.
1171 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Assert that
1172 the result type is null if ENABLE_CHECKING. Set operation_type at the
1173 end unconditionally if not set in the previous cases.
1174 Use build2 and void_type_node for MODIFY_EXPR.
1175 (build_allocator): Use NULL_TREE for MODIFY_EXPR.
1176
416de7d5
EB
11772011-09-08 Eric Botcazou <ebotcazou@adacore.com>
1178
1179 * gcc-interface/utils.c (unchecked_convert): Use a field of the right
1180 precision when converting to or from an integral type whose precision
1181 is not equal to its size.
1182
88b76013
IS
11832011-09-08 Iain Sandoe <iains@gcc.gnu.org>
1184
416de7d5 1185 * traceback.c (Darwin) USE_GCC_UNWINDER for Darwin versions >= 8.
88b76013 1186
1aeee5ad
IS
11872011-09-07 Iain Sandoe <iains@gcc.gnu.org>
1188
416de7d5 1189 * gcc-interface/Makefile.in (darwin): Provide powerpc64 system
1aeee5ad
IS
1190 implementation.
1191 * system-darwin-ppc64.ads: New file.
1192
f61fc398
IS
11932011-09-06 Iain Sandoe <iains@gcc.gnu.org>
1194
1195 * gcc-interface/Makefile.in (gnatlib-shared-darwin): Remove
1196 reference to "-lm".
1197
84ef27d3
IS
11982011-09-06 Iain Sandoe <iains@gcc.gnu.org>
1199
1200 * gcc-interface/Makefile.in (darwin, SO_OPTS): Provide architecture
1201 size switches to the link phase for shared libs.
1202
a1bf1ec7
IS
12032011-09-06 Iain Sandoe <iains@gcc.gnu.org>
1204
416de7d5 1205 * gcc-interface/Makefile.in (x86_64 darwin arch): Adjust
a1bf1ec7
IS
1206 LIBGNAT_TARGET_PAIRS for x86 and x86_64 variants.
1207
e972fd52
AC
12082011-09-06 Arnaud Charlet <charlet@adacore.com>
1209
1210 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in
1211 (gnattools, regnattools, cross-gnattools, canadian-gnattools,
1212 gnatlib, gnatlib-sjlj, gnatlib-zcx, gnatlib-shared, gnatlib_and_tools):
1213 New targets.
1214 (TOOLS_FLAGS_TO_PASS): New.
1215 (../stamp-tools): Reintroduce, to avoid merge conflicts.
1216
ef417be1
RD
12172011-09-06 Robert Dewar <dewar@adacore.com>
1218
1219 * sem_ch10.adb, impunit.ads, impunit.adb (Not_Impl_Defined_Unit): New
1220 name for Is_RM_Defined_Unit. Also several fixes to this unit.
1221
0a034606
RD
12222011-09-06 Robert Dewar <dewar@adacore.com>
1223
1224 * impunit.ads, impunit.adb (Is_RM_Defined_Unit): New function.
1225 * s-rident.ads: New restriction No_Implementation_Units
1226 (this restriction is also part of the profile
1227 No_Implementation_Extensions)
1228 * sem_ch10.adb (Analyze_With_Clause): Add check for
1229 No_Implementation_Units restriction.
1230
ebb6faaa
AC
12312011-09-06 Jerome Guitton <guitton@adacore.com>
1232
1233 * sysdep.c (__gnat_get_task_options): Disable VX_SPE_TASK
1234 on vThreads.
1235
12362011-09-06 Thomas Quinot <quinot@adacore.com>
1237
1238 * s-solita.adb: Minor reformatting.
1239
12402011-09-06 Ed Schonberg <schonberg@adacore.com>
1241
1242 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): The body that
1243 is a rewriting of an expression function does not freeze previous
1244 entities.
1245
12462011-09-06 Robert Dewar <dewar@adacore.com>
1247
1248 * impunit.adb (Is_Known_Unit): Fix bad handling of Ada 2012 case
1249
60435286
TG
12502011-09-06 Tristan Gingold <gingold@adacore.com>
1251
1252 * gcc-interface/Makefile.in: Handle e500v2-wrs-vxworksae like
1253 powerpc-wrs-vxworksae.
1254
08f8a983
AC
12552011-09-06 Thomas Quinot <quinot@adacore.com>
1256
1257 * s-os_lib.ads (Spawn): Minor documentation clarification,
1258 Success is True for a zero exit status.
1259
12602011-09-06 Ed Schonberg <schonberg@adacore.com>
1261
1262 * sem_ch5.adb: Add message for common iterator error.
1263
12642011-09-06 Ed Schonberg <schonberg@adacore.com>
1265
1266 * exp_ch3.adb (Build_Initialization_Call): If the target is a
1267 selected component discriminated by a current instance, replace
1268 the constraint with a reference to the target object, regardless
1269 of whether the context is an init_proc.
1270
12712011-09-06 Robert Dewar <dewar@adacore.com>
1272
1273 * exp_attr.adb: Descriptor_Size is never static.
1274
12752011-09-06 Robert Dewar <dewar@adacore.com>
1276
1277 * gnat_ugn.texi: Add documentation for LSLOC metric in gnatmetric
1278
12792011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
1280
1281 * gnat_rm.texi: Clarify that attribute Descriptor_Size is
1282 non-static.
1283
12842011-09-06 Ed Schonberg <schonberg@adacore.com>
1285
1286 * sem_res.adb (Resolve): An expression that is the body of an
1287 expression function does not freeze.
1288
12892011-09-06 Matthew Heaney <heaney@adacore.com>
1290
1291 * a-csquin.ads, a-cusyqu.adb, a-cbprqu.adb, a-cbsyqu.adb,
1292 a-cuprqu.adb: Changed copyright notice to indicate current
1293 year only.
1294
12952011-09-06 Vincent Celier <celier@adacore.com>
1296
1297 * prj.adb: Minor spelling error fix in comment
1298 * sem_res.adb: Minor reformatting
1299
13002011-09-06 Pascal Obry <obry@adacore.com>
1301
1302 * sysdep.c (winflush_nt): Removed as not needed anymore.
1303 (winflush_95): Likewise.
1304 (winflush_init): Likewise.
1305 (winflush_function): Likewise.
1306 (getc_immediate_common): Remove call to winflush_function.
1307
cb3d8731
HK
13082011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
1309
1310 * exp_attr.adb (Expand_N_Attribute_Reference): Rewrite the
1311 processing for Descriptor_Size.
1312 * gnat_rm.texi: Rephrase the wording for attribute Descriptor_Size
1313 to account for its broader usage.
1314 * sem_attr.adb (Analyze_Attribute): Change the error detection
1315 circuitry for Descriptor_Size as the attribute is now applicable
1316 to all types.
1317
f7e6fc47
RD
13182011-09-06 Robert Dewar <dewar@adacore.com>
1319
1320 * sem_attr.adb, prj-nmsc.adb, exp_aggr.adb: Minor reformatting.
1321
f8e9fc30
AC
13222011-09-06 Ed Schonberg <schonberg@adacore.com>
1323
1324 * lib-xref.adb (OK_To_Set_Referenced): A reference to a formal
1325 in a parameter association must not set the Referenced flag on
1326 the formal.
1327 * prj-nmsc.adb (Check_File_Naming_Schemes): Remove useless formal
1328
13292011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
1330
1331 * gnat_rm.texi: Add a section on attribute Descriptor_Size
1332
e8e38f35
AC
13332011-09-06 Arnaud Charlet <charlet@adacore.com>
1334
1335 * gcc-interface/Makefile.in (common-tools, gnatmake-re,
1336 gnatlink-re): Speed up by using -j0.
1337
ba759acd
AC
13382011-09-06 Yannick Moy <moy@adacore.com>
1339
1340 * sem_ch13.adb (Analyze_Aspect_Specifications): Call
1341 Set_Corresponding_Aspect when creating pragma from aspect.
1342 (Add_Predicates): Use new field Corresponding_Aspect.
1343 * sem_prag.adb (Analyze_Pragma): Make Pname hold source aspect
1344 name when present, for the purpose of issuing error messages;
1345 remove local procedure Error_Pragma_Arg_Alternate_Name.
1346 * sinfo.adb, sinfo.ads (Corresponding_Aspect): New field in
1347 N_Pragma node.
1348 (From_Dynamic_Predicate, From_Static_Predicate): Remove fields from
1349 N_Pragma node.
1350
13512011-09-06 Robert Dewar <dewar@adacore.com>
1352
1353 * checks.adb, s-except.ads, g-socket.adb: Minor reformatting.
1354
13552011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
1356
1357 * exp_ch6.adb (Build_Heap_Allocator): Add new
1358 local variable Desig_Typ. Code and comment reformatting. Add
1359 machinery to ensure that the allocation uses a fat pointer when
1360 the type of the return object is a constrained array and the
1361 function return type is an unconstrained array.
1362
13632011-09-06 Vincent Celier <celier@adacore.com>
1364
1365 * make.adb, prj-part.adb, prj-nmsc.adb: Remove unused formal
1366 parameters in subprograms.
1367
13682011-09-06 Arnaud Charlet <charlet@adacore.com>
1369
1370 * s-taprop-mingw.adb (Finalize_TCB): Fix typo.
1371
13722011-09-06 Thomas Quinot <quinot@adacore.com>
1373
1374 * s-taprop-vxworks.adb, s-tpoaal.adb, s-tpopsp-vxworks.adb
1375 (System.Tasking.Primitive_Operations.Specific.Delete): Remove
1376 subprogram.
1377 (System.Tasking.Primitive_Operations.Specific.Set): If argument
1378 is null, destroy task specific data, to make API consistent with
1379 other platforms, and thus compatible with the shared version
1380 of s-tpoaal.adb.
1381 (System.Tasking.Primitive_Operations.ATCB_Allocation.Free_ATCB):
1382 Document the above assumption.
1383
f4f92d9d
AC
13842011-09-06 Ed Schonberg <schonberg@adacore.com>
1385
1386 * exp_ch6.adb (Expand_Inlined_Call): Fix use of uninitialized
1387 variable for type of return value when return type is
1388 unconstrained and context is an assignment.
1389
13902011-09-06 Ed Schonberg <schonberg@adacore.com>
1391
1392 * sem_ch8.adb (Check_Class_Wide_Actual): Do not generate body of
1393 class-wide operation if expansion is not enabled.
1394
13952011-09-06 Eric Botcazou <ebotcazou@adacore.com>
1396
1397 * checks.adb (Apply_Scalar_Range_Check): Deal with access
1398 type prefix.
1399
14002011-09-06 Yannick Moy <moy@adacore.com>
1401
1402 * sem_ch13.adb (Analyze_Aspect_Specifications, case
1403 Aspect_Invariant): Do not issue error at this point on illegal
1404 pragma placement, as this is checked later on when analyzing
1405 the corresponding pragma.
1406 * sem_prag.adb (Error_Pragma_Arg_Alternate_Name): New procedure
1407 similar to Error_Pragma_Arg, except the source name of the
1408 aspect/pragma to use in warnings may be equal to parameter
1409 Alt_Name (Analyze_Pragma, case Pragma_Invariant): refine error
1410 message to distinguish source name of pragma/aspect, and whether
1411 the illegality resides in the type being public, or being private
1412 without a public declaration
1413
14142011-09-06 Thomas Quinot <quinot@adacore.com>
1415
1416 * g-socket.adb (Check_For_Fd_Set): On Windows, no need for bitmap
1417 size check (fd_set is implemented differently on that platform).
1418
14192011-09-06 Thomas Quinot <quinot@adacore.com>
1420
1421 * s-taprop-vxworks.adb, s-taprop-tru64.adb, s-taprop-vms.adb,
1422 s-tpoaal.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
1423 s-taprop-solaris.adb, s-taprop-irix.adb, s-taprop.ads,
1424 s-taprop-hpux-dce.adb, s-taprop-dummy.adb, s-taprop-posix.adb
1425 (ATCB_Allocation): New subpackage of
1426 System.Tasking.Primitive_Operations, shared across all targets
1427 with full tasking runtime.
1428 (ATCB_Allocation.New_ATCB): Moved there (from target specific
1429 s-taprop bodies).
1430 (ATCB_Allocation.Free_ATCB): New subprogram. Deallocate an ATCB,
1431 taking care of establishing a local temporary ATCB if the one
1432 being deallocated is Self, to avoid a reference to the freed
1433 ATCB in Abort_Undefer.
1434
14352011-09-06 Thomas Quinot <quinot@adacore.com>
1436
1437 * s-tassta.adb, s-taskin.ads (Free_Task): If the task is not
1438 terminated, mark it for deallocation upon termination.
1439 (Terminate_Task): Call Free_Task again if the task is marked
1440 for automatic deallocation upon termination.
1441
df177175
RD
14422011-09-06 Robert Dewar <dewar@adacore.com>
1443
1444 * a-cbprqu.ads, a-cbsyqu.ads, a-cuprqu.ads, a-cusyqu.ads,
1445 a-intnam-aix.ads, a-intnam-darwin.ads, a-intnam-dummy.ads,
1446 a-intnam-freebsd.ads, a-intnam-hpux.ads, a-intnam-irix.ads,
1447 a-intnam-linux.ads, a-intnam-lynxos.ads, a-intnam-mingw.ads,
1448 a-intnam-solaris.ads, a-intnam-tru64.ads,
1449 a-intnam-vms.ads, a-intnam-vxworks.ads, a-intnam.ads, interfac.ads,
1450 cstand.adb, s-maccod.ads: Mark all entities as Implementation_Defined
1451 * einfo.ads, einfo.adb (Is_Implementation_Defined): New flag
1452 * par-prag.adb: Add dummy entry for pragma Implementation_Defined
1453 * s-rident.ads: Add new restriction No_Implementation_Identifiers
1454 Add new profile No_Implementation_Extensions
1455 * sem_prag.adb: Implement pragma Implementation_Defined Implement
1456 profile No_Implementation_Extensions
1457 * sem_util.adb: Minor reformatting (Set_Entity_With_Style_Check):
1458 Check violation of restriction No_Implementation_Identifiers
1459 * snames.ads-tmpl: Add entries for pragma Implementation_Defined
1460 Add entry for Name_No_Implementation_Extensions
1461
14622011-09-06 Robert Dewar <dewar@adacore.com>
1463
1464 * impunit.ads: Minor reformatting.
1465
b991dd43
AC
14662011-09-06 Robert Dewar <dewar@adacore.com>
1467
1468 * ali.adb, sem_ch13.adb, lib-xref.adb: Minor reformatting.
1469
14702011-09-06 Pascal Obry <obry@adacore.com>
1471
1472 * s-osinte-linux.ads, s-oscons-tmplt.c: Use oscons to define sigset_t
1473 types.
1474
516785cc
AC
14752011-09-06 Robert Dewar <dewar@adacore.com>
1476
1477 * g-socket.adb: Minor reformatting
1478
14792011-09-06 Javier Miranda <miranda@adacore.com>
1480
1481 * ali.adb (Scan_ALI): Add missing support to load references of
1482 entities imported from other languages.
1483 * ali.ads (Xref_Record): Adding new fields to store the language and
1484 name of an imported entity.
1485 * lib-xref.adb (Output_Import_Export_Info): Fix typo
1486 in comment.
1487
14882011-09-06 Ed Schonberg <schonberg@adacore.com>
1489
1490 * sem_prag.adb (Analyze_Pragma, case Type_Invariant): A type invariant
1491 is allowed on a full type declaration if it is the completion of
1492 a private declarations.
1493 * sem_ch13.adb (Analyze_Aspect_Specifications): An invariant
1494 aspect is allowed on a full type declaration in the private part
1495 of a package.
1496
96691943
AC
14972011-09-06 Robert Dewar <dewar@adacore.com>
1498
1499 * sem_ch8.ads: Minor reformatting
1500
15012011-09-06 Thomas Quinot <quinot@adacore.com>
1502
1503 * s-oscons-tmplt.c, g-socket.adb (GNAT.Sockets.Clear,Set,Is_Set):
1504 Guard against socket values that are not in [0;FD_SETSIZE[
1505
54bf19e4
AC
15062011-09-06 Robert Dewar <dewar@adacore.com>
1507
1508 * s-osinte-linux.ads, a-iteint.ads, exp_ch6.adb, s-solita.adb: Minor
1509 reformatting.
1510
15112011-09-06 Arnaud Charlet <charlet@adacore.com>
1512
1513 * s-linux-alpha.ads: Minor reformatting
1514 * s-oscons-tmplt.c: Fix generated comments in s-oscons template.
1515 Use sizeof instead of corresponding C defines in s-oscons template.
1516
5d42cba1
VG
15172011-09-06 Vadim Godunko <godunko@adacore.com>
1518
1519 * a-convec.ads, a-iteint.ads: Minor reformatting.
1520
77aa62e7
AC
15212011-09-06 Vincent Celier <celier@adacore.com>
1522
1523 * projects.texi: Add menus and @node lines.
1524
15252011-09-06 Ed Schonberg <schonberg@adacore.com>
1526
1527 * exp_ch6.adb (Expand_Inlined_Call): Handle properly the case
1528 where the return type is an unconstrained array and the context
1529 is an assignment. Optimize the case when the target of the
1530 assignment is a selected component.
1531
15322011-09-06 Arnaud Charlet <charlet@adacore.com>
1533
1534 * s-solita.adb: Update comments.
1535
15362011-09-06 Pascal Obry <obry@adacore.com>
1537
1538 * s-linux.ads, s-linux-alpha.ads, s-linux-hppa.ads, s-linux-mipsel.ads,
1539 s-linux-sparc.ads: Remove hard coded and now wrong definitions.
1540 * s-oscons-tmplt.c: Add support for generating pthread related
1541 types size on GNU/Linux as done for Darwin.
1542 * s-osinte-linux.ads: Use s-oscons to define the pthread types.
1543
886b5a18
AC
15442011-09-06 Robert Dewar <dewar@adacore.com>
1545
1546 * exp_ch6.adb: Fix minor typo.
1547
15482011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
1549
1550 * exp_ch7.adb: Remove with and use clauses for Get_Targ.
1551 (Alignment_Of): Moved to the body of Nearest_Multiple_Rounded_Up.
1552 (Double_Size_Of): Alphabetized. Update the comment on usage.
1553 (Make_Finalize_Address_Stmts): Update comments and reformat code.
1554 (Nearest_Multiple_Rounded_Up): New routine.
1555 (Size_Of): Update comment on usage. The generated expression now
1556 accounts for alignment gaps by rounding the size of the type to the
1557 nearest multiple rounded up of the type's alignment.
1558
57a3fca9
AC
15592011-09-06 Robert Dewar <dewar@adacore.com>
1560
1561 * exp_ch7.adb, g-comlin.adb: Minor reformatting.
1562
15632011-09-06 Steve Baird <baird@adacore.com>
1564
1565 * exp_ch4.adb (Expand_Allocator_Expression): Look through
1566 derived subprograms in checking for presence of an
1567 Extra_Accessibility_Of_Result formal parameter.
1568 * exp_ch6.adb (Expand_Call): Look through derived subprograms in
1569 checking for presence of an Extra_Accessibility_Of_Result formal
1570 parameter.
1571 (Expand_Call.Add_Actual_Parameter): Fix a bug in the
1572 case where the Parameter_Associatiations attribute is already set,
1573 but set to an empty list.
1574 (Needs_Result_Accessibility_Level):
1575 Unconditionally return False. This is a temporary
1576 change, disabling the Extra_Accessibility_Of_Result
1577 mechanism.
1578 (Expand_Simple_Function_Return): Check for
1579 Extra_Accessibility_Of_Result parameter's presence instead of
1580 testing Ada_Version when generating a runtime accessibility
1581 check which makes use of the parameter.
1582
eaed0c37
AC
15832011-09-06 Ed Schonberg <schonberg@adacore.com>
1584
1585 * exp_ch4.adb (Expand_N_Case_Expression): Actions created for the
1586 expression in a given case alternative must be attached to the
1587 statement list of the ccrresponding case statement alternative
1588 They cannot be propagated ahead of the case statement, because
1589 the validity of the expression that generated the action may
1590 hold only for that alternative.
1591
15922011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
1593
1594 * exp_ch7.adb: Remove with and use clauses for Get_Targ.
1595 (Alignment_Of): Remove the code for strict alignment targets.
1596 (Double_Alignment_Of): Removed.
1597 (Double_Size_Of): New routine.
1598 (Make_Finalize_Address_Stmts): Change the
1599 calculation of the dope's size. Update relevant comments.
1600 (Size_Of): New routine.
1601
b8a93198
AC
16022011-09-06 Steve Baird <baird@adacore.com>
1603
1604 * einfo.ads (Extra_Accessibility): Update associated comment to use
1605 the term "present" correctly ("present" just means that it is not
1606 an error to query the value of the attribute - it does not imply
1607 that the value must be non-null).
1608 (Extra_Constrained): Ditto.
1609 (Is_Visible_Formal): Ditto.
1610 (Extra_Accessibility_Of_Result) Ditto; also add Inline pragma.
1611 (Set_Extra_Accessibility_Of_Result): Add Inline pragma.
1612 * exp_ch4.adb (Expand_Allocator_Expression): Improve a comment.
1613 * exp_ch6.adb (Expand_Call): The callee may require an
1614 Extra_Accessibility_Of_Result actual parameter even if Ada_Version
1615 < Ada_2012. This can occur if the callee is exported from a Gnat
1616 runtimes unit. Also improve a comment.
1617
16182011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
1619
1620 * exp_ch7.adb: Add with and use clauses for Get_Targ.
1621 (Alignment_Of): Rename formal parameter Some_Typ
1622 to Typ, update related comment. Use the allocator alignment on
1623 strict alignment targets such as SPARC.
1624 (Double_Alignment_Of): Rename formal parameter Some_Typ to Typ, update
1625 related comment.
1626
16272011-09-06 Gary Dismukes <dismukes@adacore.com>
1628
1629 * sem_ch9.adb (Check_Interfaces): Test
1630 Is_Limited_Type rather than Is_Limited_Record when checking that
1631 the partial view of a synchronized full view must be limited.
1632
16332011-09-06 Emmanuel Briot <briot@adacore.com>
1634
1635 * g-comlin.adb (Free): Fix memory leak.
1636
ebf494ec
RD
16372011-09-06 Robert Dewar <dewar@adacore.com>
1638
1639 * sem_util.adb, exp_ch6.adb: Minor reformatting and code reorganization.
1640
63585f75
SB
16412011-09-06 Steve Baird <baird@adacore.com>
1642
1643 * einfo.ads (Extra_Accessibility_Of_Result): New function; in the
1644 (Ada2012) cases described in AI05-0234 where the accessibility
1645 level of a function result is "determined by the point of
1646 call", an implicit parameter representing that accessibility
1647 level is passed in. Extra_Accessibilty_Of_Result yields this
1648 additional formal parameter. Extra_Accessibility_Of_Result
1649 is analogous to the existing Extra_Accessibility
1650 function used in the implementation of access parameters.
1651 (Set_Extra_Accessibility_Of_Result): New procedure; sets
1652 Extra_Accessibility_Of_Result attribute.
1653 * einfo.adb (Extra_Accessibility_Of_Result): New function.
1654 (Set_Extra_Accessibility_Of_Result): New procedure.
1655 (Write_Field19_Name): Display Extra_Accessibilty_Of_Result attribute.
1656 * sem_util.adb (Dynamic_Accessibility_Level): Set Etype of
1657 an accessibility level literal to Natural; introduce a nested
1658 function, Make_Level_Literal, to do this.
1659 * exp_ch6.ads (Needs_Result_Accessibility_Level): New function;
1660 determines whether a given function (or access-to-function
1661 type) needs to have an implicitly-declared accessibility-level
1662 parameter added to its profile.
1663 (Add_Extra_Actual_To_Call): Export an existing procedure which was
1664 previously declared in the body of Exp_Ch6.
1665 * exp_ch6.adb (Add_Extra_Actual_To_Call): Export declaration by moving
1666 it to exp_ch6.ads.
1667 (Has_Unconstrained_Access_Discriminants): New Function; a
1668 predicate on subtype entities which returns True if the given
1669 subtype is unconstrained and has one or more access discriminants.
1670 (Expand_Call): When expanding a call to a function which takes an
1671 Extra_Accessibility_Of_Result parameter, pass in the appropriate
1672 actual parameter value. In the case of a function call which is
1673 used to initialize an allocator, this may not be possible because
1674 the Etype of the allocator may not have been set yet. In this
1675 case, we defer passing in the parameter and handle it later in
1676 Expand_Allocator_Expression.
1677 (Expand_Simple_Function_Return): When returning from a function which
1678 returns an unconstrained subtype having at least one access
1679 discriminant, generate the accessibility check needed to ensure that
1680 the function result will not outlive any objects designated by its
1681 discriminants.
1682 (Needs_Result_Accessibility_Level): New function; see exp_ch6.ads
1683 description.
1684 * exp_ch4.adb (Expand_Allocator_Expression): When a function call
1685 is used to initialize an allocator, we may need to pass in "the
1686 accessibility level determined by the point of call" (AI05-0234)
1687 to the function. Expand_Call, where such actual parameters are
1688 usually generated, is too early in this case because the Etype of
1689 the allocator (which is used in determining the level to be passed
1690 in) may not have been set yet when Expand_Call executes. Instead,
1691 we generate code to pass in the appropriate actual parameter
1692 in Expand_Allocator_Expression.
1693 * sem_ch6.adb (Create_Extra_Formals): Create
1694 the new Extra_Accessibility_Of_Result formal if
1695 Needs_Result_Accessibility_Level returns True. This includes the
1696 introduction of a nested procedure, Check_Against_Result_Level.
1697
1a982c6e
AC
16982011-09-06 Arnaud Charlet <charlet@adacore.com>
1699
1700 * gcc-interface/Makefile.in (X86_TARGET_PAIRS): Remove duplicate
1701 declaration.
1702
e42bcfa3
AC
17032011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
1704
1705 * s-finmas.adb (Set_Finalize_Address): Explain the reason
1706 for the synchronization. Move the test for null from
1707 s-stposu.Allocate_Any_Controlled to this routine since the check
1708 needs to be protected too.
1709 (Set_Heterogeneous_Finalize_Address): Explain the reason for the
1710 synchronization code.
1711 * s-finmas.ads (Set_Heterogeneous_Finalize_Address): Add comment
1712 explaining the context in which this routine is used.
1713 * s-stposu.adb (Allocate_Any_Controlled): Move the test for null
1714 to s-finmas.Set_Finalize_Address.
1715
17162011-09-05 Ed Schonberg <schonberg@adacore.com>
1717
1718 * einfo.ads: Document that itypes have no parent field.
1719
17202011-09-05 Robert Dewar <dewar@adacore.com>
1721
1722 * rtsfind.adb (Check_CRT): Check for overloaded entity
1723 * rtsfind.ads: Document that entities to be found by rtsfind
1724 cannot be overloaded
1725 * s-taenca.adb, s-tasren.adb, s-tpobop.adb, s-tpoben.ads, s-tpoben.adb
1726 (Lock_Entries_With_Status): New name for Lock_Entries with two
1727 arguments (changed to meet rtsfind no overloading rule).
1728
544e7c17
AC
17292011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
1730
1731 * s-finmas.adb (Set_Finalize_Address (Address,
1732 Finalize_Address_Ptr)): Renamed to Set_Heterogeneous_Finalize_Address.
1733 (Set_Finalize_Address (in out Finalization_Master,
1734 Finalize_Address_Ptr): Add synchronization code.
1735 * s-finmas.ads (Set_Finalize_Address (Address,
1736 Finalize_Address_Ptr)): Renamed to Set_Heterogeneous_Finalize_Address.
1737 * s-stposu.adb (Allocate_Any_Controlled): Update the call to
1738 Set_Finalize_Address for the heterogeneous case.
1739
17402011-09-05 Ed Schonberg <schonberg@adacore.com>
1741
1742 * sem_ch3.adb: Undo previous change, not suitable after all.
1743
17442011-09-05 Robert Dewar <dewar@adacore.com>
1745
1746 * einfo.ads: Minor comment clarification.
1747
0613fb33
AC
17482011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
1749
1750 * exp_ch6.adb (Move_Activation_Chain): Rewritten. The routine
1751 no longer needs to search through the entities of the return
1752 statement scope to find the _chain.
1753 * sem_ch5.adb: Add with and use clauses for Exp_Ch6 and Sem_Ch6.
1754 (Analyze_Block_Statement): Add local variable
1755 Is_BIP_Return_Statement. Add machinery to install all entities
1756 produced by the expansion of the return object declaration.
1757 (Install_Return_Entities): New routine.
1758 * sem_ch6.ads, sem_ch6.adb (Install_Entity): Moved from body to spec.
1759
17602011-09-05 Ed Schonberg <schonberg@adacore.com>
1761
1762 * sem_ch10.adb (Analyze_Context): Apply simple fixup if context
1763 of subunit is incomplete.
1764 (Analyze_Proper_Body): If parent spec is not available, do not
1765 attempt analysis.
1766
5dcab3ca
AC
17672011-09-05 Ed Schonberg <schonberg@adacore.com>
1768
1769 * sem_disp.adb (Find_Controlling_Arg): Add checks for
1770 interface type conversions, that are expanded into dereferences.
1771
17722011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
1773
1774 * sem_ch6.adb (Analyze_Subprogram_Body_Helper):
1775 Examine the parameter and return profile of a subprogram and swap
1776 any incomplete types coming from a limited context with their
1777 corresponding non-limited views.
1778 (Exchange_Limited_Views): New routine.
1779
17802011-09-05 Ed Schonberg <schonberg@adacore.com>
1781
1782 * sem_ch3.adb (Prepare_Private_Subtype_Completion): Set parent
1783 of internal entity to the subtype declaration, so that when
1784 entities are subsequently exchanged in a package body, the tree
1785 remains properly formatted for ASIS.
1786
8da1a312
AC
17872011-09-05 Johannes Kanig <kanig@adacore.com>
1788
1789 * g-comlin.adb (Set_Usage): Additional optional argument to set help
1790 message.
1791 (Display_Help): display the user given help message, if available.
1792
17932011-09-05 Ed Schonberg <schonberg@adacore.com>
1794
1795 * sem_ch3.adb (OK_For_Limited_Init_In_05): The expression
1796 is legal if the original node is an identifier that is a
1797 parameterless function call.
1798
69b73847
PO
17992011-09-05 Pascal Obry <obry@adacore.com>
1800
1801 * prj-nmsc.adb: Minor reformatting.
1802 Add support for standalone aggregate library.
1803 (Check_Stand_Alone_Library): Handle standalone aggregate library.
1804 * projects.texi: Fix documentation for aggregate library projects.
1805
81bf2382
AC
18062011-09-05 Robert Dewar <dewar@adacore.com>
1807
1808 * sem_ch6.adb: Minor reformatting.
1809
18102011-09-05 Matthew Gingell <gingell@adacore.com>
1811
1812 * s-tassta.adb (Task_Wrapper): Ensure that we don't try to write the
1813 stack guard page on PPC Linux. This patch ensures the 64K guard page at
1814 the bottom of the stack is not overwritten.
1815
13a0b1e8
AC
18162011-09-05 Thomas Quinot <quinot@adacore.com>
1817
1818 * exp_intr.adb, s-tasini.adb: Minor reformatting.
1819
18202011-09-05 Ed Schonberg <schonberg@adacore.com>
1821
1822 * sem_ch3.adb (Access_Definition): If an access type declaration
1823 appears in a child unit, the scope of whatever anonymous type
1824 may be generated is the child unit itself.
1825
18262011-09-05 Ed Schonberg <schonberg@adacore.com>
1827
1828 * sem_ch6.adb (Analyze_Expression_Function): Do not set
1829 Comes_From_Source on rewritten body.
1830 (Analyze_Subprogram_Body_Helper): Check that the original node for
1831 the body comes from source, when determining whether expansion
1832 of a protected operation is needed.
1833
20428725
AC
18342011-09-05 Ed Schonberg <schonberg@adacore.com>
1835
1836 * exp_aggr.adb (Replace_Type): If the target of the assignment is
1837 a selected component and the right-hand side is a self-referential
1838 access, the proper prefix of the rewritten attribute is a copy
1839 of the left-hand side, not of its prefix.
1840
18412011-09-05 Robert Dewar <dewar@adacore.com>
1842
1843 * sem_ch5.adb: Minor reformatting.
1844 * sem_ch3.adb: Minor code clean up.
1845
18462011-09-05 Jose Ruiz <ruiz@adacore.com>
1847
1848 * exp_ch9.adb (Make_Initialize_Protection): The fact that
1849 restriction No_Dynamic_Attachment is in effect or not should
1850 not influence the default priority associated to a protected
1851 object. With this change, when the restriction is in effect (as
1852 is the case for the Ravenscar profile) the default priority of
1853 a protected object with an interrupt handler is in the range of
1854 interrupt priorities (Default_Interrupt_Priority) as required
1855 by D.3(10).
1856
18572011-09-05 Arnaud Charlet <charlet@adacore.com>
1858
1859 * a-iteint.ads: Fix header.
1860
18612011-09-05 Vincent Celier <celier@adacore.com>
1862
1863 * prj-conf.adb (Do_Autoconf): Make sure Obj_Dir always ends
1864 with a directory separator to avoid output such as:
1865 "/path/to/objauto.cgpr" has been deleted.
1866
4a1bfefb
AC
18672011-09-05 Robert Dewar <dewar@adacore.com>
1868
1869 * sem_ch3.adb: Minor reformatting.
1870
18712011-09-05 Ed Schonberg <schonberg@adacore.com>
1872
1873 * sem_ch5.adb: Better error message.
1874
18752011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
1876
1877 * exp_aggr.adb: Add with and use clause for Exp_Ch6.
1878 (Expand_Array_Aggregate): Detect a special case of an aggregate
1879 which contains tasks in the context of an unexpanded return
1880 statement of a build-in-place function.
1881 * exp_ch6.adb: Add with and use clause for Exp_Aggr.
1882 (Expand_N_Extended_Return_Statement): Detect a delayed aggregate
1883 which contains tasks and expand it now that the original simple
1884 return statement has been rewritten.
1885 * exp_ch9.adb (Build_Activation_Chain_Entity): Code
1886 reformatting. Do not create a chain for an extended return
1887 statement if one is already available.
1888 (Has_Activation_Chain): New routine.
1889
9ec080cb
AC
18902011-09-05 Marc Sango <sango@adacore.com>
1891
1892 * sem_ch3.adb (Analyze_Object_Declaration): Remove
1893 the wrong test and add the correct test to detect the violation
1894 of illegal use of unconstrained string type in SPARK mode.
1895
18962011-09-05 Ed Schonberg <schonberg@adacore.com>
1897
1898 * sem_ch5.adb (Analyze_Iteration_Specification): Improve error
1899 message on an iterator over an array.
1900
19012011-09-05 Robert Dewar <dewar@adacore.com>
1902
1903 * lib-xref-alfa.adb: Minor reformatting.
1904
aeae67ed
RD
19052011-09-05 Robert Dewar <dewar@adacore.com>
1906
1907 * sem_ch3.adb, sem_res.adb, par.adb, par-ch6.adb, g-comlin.adb,
1908 exp_ch6.adb, lib-xref-alfa.adb: Minor reformatting.
1909
d72e7628
AC
19102011-09-05 Gary Dismukes <dismukes@adacore.com>
1911
1912 * exp_ch7.adb, exp_ch6.adb: Minor reformatting.
1913
19142011-09-05 Johannes Kanig <kanig@adacore.com>
1915
1916 * lib-xref-alfa.adb: Update comments.
1917
19182011-09-05 Thomas Quinot <quinot@adacore.com>
1919
1920 * sem_res.adb: Minor reformatting
1921
0d566e01
ES
19222011-09-05 Ed Schonberg <schonberg@adacore.com>
1923
1924 * exp_ch6.adb (Build_In_Place_Formal): If extra formals are not
1925 present, create them now. Needed in case the return type was
1926 a limited view in the function declaration.
1927 (Make_Build_In_Place_Call_In_Allocator): If return type contains
1928 tasks, build the activation chain for it. Pass a reference to
1929 the Master_Id in call to Add_Task_Actuals_To_Build_In_Place call.
1930 * exp_ch7.adb (Make_Set_Finalize_Address_Call): Clean up interface
1931 with build_in_place calls.
1932 * sem_ch9.adb (Analyze_Task_Type_Declaration): If partial view was
1933 incomplete, inatialize its Corresponding_Record_Type component.
1934 * sem_ch10.adb (Build_Chain): Initialize Private_Dependents field
1935 of limited views.
1936
ec09f261
AC
19372011-09-05 Johannes Kanig <kanig@adacore.com>
1938
1939 * lib-xref-alfa.adb (Is_Alfa_Reference): Filter constants from effect
1940 information.
1941
19422011-09-05 Ed Schonberg <schonberg@adacore.com>
1943
1944 * par-ch6.adb (P_Subprogram): In Ada2012 mode, if the subprogram
1945 appears within a package specification and the token after "IS"
1946 is not a parenthesis, assume that this is an unparenthesized
1947 expression function, even if the token appears in a line by
1948 itself.
1949 * par.adb: Clarify use of Labl field of scope stack in error
1950 recovery.
1951
7109f4f5
AC
19522011-09-05 Bob Duff <duff@adacore.com>
1953
1954 * sem_res.adb (Resolve_Intrinsic_Operator): Use unchecked
1955 conversions instead of normal type conversions in all cases where a
1956 type conversion would be illegal. In particular, use unchecked
1957 conversions when the operand types are private.
1958
19592011-09-05 Johannes Kanig <kanig@adacore.com>
1960
1961 * lib-xref-alfa.adb (Is_Alfa_Reference): Never declare effects on
1962 objects of task type or protected type.
1963
66dc8075
AC
19642011-09-05 Ed Schonberg <schonberg@adacore.com>
1965
1966 * sem_ch6.adb (Analyze_Expression_Function): If the expression
1967 function comes from source, indicate that so does its rewriting,
1968 so it is compatible with any subsequent expansion of the
1969 subprogram body (e.g. when it is a protected operation).
1970 * sem_ch4.adb: minor reformatting
1971
19722011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
1973
1974 * lib.adb (Check_Same_Extended_Unit): Comment rewriting. Use
1975 Get_Source_Unit rather than Get_Code_Unit as instantiation unfolding
1976 may lead to wrong ancestor package in the case of instantiated subunit
1977 bodies. If a subunit is instantiated, follow the chain of instantiations
1978 rather than the stub structure.
1979
bd38b431
AC
19802011-09-02 Robert Dewar <dewar@adacore.com>
1981
1982 * sem_ch4.adb, sem_ch6.adb: Minor reformatting.
1983 * gcc-interface/Make-lang.in: Update dependencies.
1984
19852011-09-02 Marc Sango <sango@adacore.com>
1986
1987 * sem_ch3.adb (Analyze_Object_Declaration): Change
1988 comment and add additional check to differentiate constant of
1989 type string from others unconstrained type.
1990
99d520ad
ES
19912011-09-02 Ed Schonberg <schonberg@adacore.com>
1992
1993 * sinfo.ads, sinfo.adb: New semantic attribute Premature_Use,
1994 present in incomplete type declarations to refine the error
1995 message the full declaration is in the same unit.
1996 * sem_ch4.adb (Analyze_Selected_Component): If the prefix is of
1997 an incomplete type, set the Premature_Use for additional message.
1998 * sem_ch3.adb (Find_Type_Name): If partial view is incomplete
1999 and Premature_Use is set, place additional information at the
2000 point of premature use.
2001
5b5588dd
AC
20022011-09-02 Bob Duff <duff@adacore.com>
2003
2004 * sem_ch6.adb: (Check_Post_State): Suppress warning
2005 "postcondition refers only to pre-state" when the expression has not
2006 yet been analyzed, because it causes false alarms. This can happen when
2007 the postcondition contains a quantified expression, because those are
2008 analyzed later. This is a temporary/partial fix.
2009 (Process_Post_Conditions): Minor: change wording of warning.
2010
20112011-09-02 Marc Sango <sango@adacore.com>
2012
2013 * sem_ch3.adb (Analyze_Object_Declaration): Detect the violation of
2014 illegal use of unconstrained string type in SPARK mode.
2015 * sem_res.adb (Analyze_Operator_Symbol): Set the
2016 right place where the string operand of concatenation should be
2017 violate in SPARK mode.
2018
bd603506
RD
20192011-09-02 Robert Dewar <dewar@adacore.com>
2020
2021 * sem_prag.adb, sem_util.adb, sem_ch6.adb, prj-nmsc.adb,
2022 exp_ch3.adb: Minor reformatting.
2023
24a120ac
AC
20242011-09-02 Vincent Celier <celier@adacore.com>
2025
2026 * prj-conf.adb (Add_Default_GNAT_Naming_Scheme): Declare "gcc"
2027 as the compiler driver so Is_Compilable returns True for sources.
2028 * prj-nmsc.adb (Override_Kind): When Kind is Sep, set the source
2029 for the body.
2030
20312011-09-02 Ed Schonberg <schonberg@adacore.com>
2032
2033 * sem_prag.adb (Analyze_PPC_In_Decl_Part): for a class-wide
2034 condition, a reference to a controlling formal must be interpreted
2035 as having the class-wide type (or an access to such) so that the
2036 inherited condition can be properly applied to any overriding
2037 operation (see ARM12 6.6.1 (7)).
2038
20392011-09-02 Tristan Gingold <gingold@adacore.com>
2040
2041 * init.c (__gnat_is_vms_v7): Fix case and add prototype
2042 for LIB$GETSYI.
2043
20442011-09-02 Javier Miranda <miranda@adacore.com>
2045
2046 * exp_ch3.adb (Expand_N_Object_Declaration): Do not copy the
2047 initializing expression of a class-wide interface object declaration
2048 if its type is limited.
2049
20502011-09-02 Johannes Kanig <kanig@adacore.com>
2051
2052 * sem_util.adb (Unique_Name): To obtain a unique name for enumeration
2053 literals, take into account the type name; the type is *not*
2054 the scope for an enumeration literal.
2055
20562011-09-02 Ed Schonberg <schonberg@adacore.com>
2057
2058 * sem_ch6.adb (Check_Overriding_Indicator): add special check
2059 to reject an overriding indicator on a user-defined Adjust
2060 subprogram for a limited controlled type.
2061
20622011-09-02 Ed Schonberg <schonberg@adacore.com>
2063
2064 * sem_res.adb (Resolve_Actuals): add missing call to Resolve
2065 for an actual that is a function call returning an unconstrained
2066 limited controlled type.
2067
20682011-09-02 Tristan Gingold <gingold@adacore.com>
2069
2070 * g-socthi-vms.adb (c_sendmsg, c_recvmsg): Use unpacked msg if on vms 7
2071
20722011-09-02 Johannes Kanig <kanig@adacore.com>
2073
2074 * alfa.ads (Name_Of_Heap_Variable): Change value of the HEAP variable
2075 from "HEAP" to __HEAP Change comment that refers to that variable
2076 * put_alfa.adb: Change comment that refers to that variable
2077
c5f5123f
AC
20782011-09-02 Robert Dewar <dewar@adacore.com>
2079
2080 * exp_ch4.adb, exp_ch6.adb, prj-nmsc.adb: Minor reformatting.
2081
20822011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
2083
2084 * exp_util.adb (Extract_Renamed_Object): Renamed to
2085 Find_Renamed_Object. This routine has been reimplemented and now uses
2086 tree traversal to locate a renamed object.
2087 (Is_Aliased): Replace call to Extract_Renamed_Object with
2088 Find_Renamed_Object.
2089
20902011-09-02 Tristan Gingold <gingold@adacore.com>
2091
2092 * init.c: (__gnat_is_vms_v7): New function.
2093
20942011-09-02 Olivier Hainque <hainque@adacore.com>
2095
2096 * tracebak.c (STOP_FRAME, ppc elf/vxworks case): Stop on frames
2097 that have a misaligned backchain, necessarily bogus.
2098
2bfa5484
HK
20992011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
2100
2101 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Do not create
2102 TSS routine Finalize_Address when compiling in Alfa mode.
2103 (Expand_Freeze_Record_Type): Do not create TSS routine
2104 Finalize_Address when compiling in Alfa mode.
2105 * exp_ch4.adb (Expand_Allocator_Expression): Do not produce a
2106 call to Set_Finalize_Address in Alfa mode because Finalize_Address is
2107 not built.
2108 (Expand_N_Allocator): Do not produce a call to
2109 Set_Finalize_Address in Alfa mode because Finalize_Address is not built.
2110 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Do not
2111 produce a call to primitive Set_Finalize_Address in Alfa mode because
2112 Finalize_Address is not built.
2113 * exp_ch7.adb (Build_Finalization_Master): Do not create
2114 finalization masters in Afa mode since they are not needed.
2115 (Build_Finalizer): Do not create scope and library-level
2116 finalizers in Alfa mode since they are not needed.
2117 * exp_util.adb (Build_Allocate_Deallocate_Proc): Do not expand
2118 "new" and "free" when applied to controlled objects in Alfa mode since
2119 this is not needed.
2120
7a0ddd20
AC
21212011-09-02 Vincent Celier <celier@adacore.com>
2122
2123 * prj-nmsc.db: (Check_Stand_Alone_Library): For SALs, allow
2124 only library names with the syntax of Ada identifiers, to avoid errors
2125 when compiling the binder generated files.
2126 * projects.texi: Document restriction on SAL library names
2127
21282011-09-02 Thomas Quinot <quinot@adacore.com>
2129
2130 * a-chtgbo.adb: Minor comment fix.
2131
439b6dfa
AC
21322011-09-02 Robert Dewar <dewar@adacore.com>
2133
2134 * lib-xref.adb: Minor reformatting
2135
21362011-09-02 Vincent Celier <celier@adacore.com>
2137
2138 * bindusg.adb, clean.adb, gnatchop.adb, gnatfind.adb, gnatlink.adb,
2139 gnatls.adb, gnatname.adb, gnatxref.adb, gprep.adb, makeusg.adb: Add
2140 --version and --help in usage.
2141 * switch.ads, switch.adb (Display_Usage_Version_And_Help): New procedure
2142
f2404867
AC
21432011-09-02 Bob Duff <duff@adacore.com>
2144
2145 * lib-xref.adb: (Hash): Avoid use of 'Mod attribute, because old
2146 compilers don't understand it.
2147
21482011-09-02 Gary Dismukes <dismukes@adacore.com>
2149
2150 * exp_attr.adb (Expand_N_Attribute_Reference): Pass the
2151 underlying subtype rather than its base type on the call to
2152 Build_Record_Or_Elementary_Input_Function, so that any
2153 constraints on a discriminated subtype will be available for
2154 doing the check required by AI05-0192.
2155 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
2156 If the prefix subtype of the 'Input attribute is a constrained
2157 discriminated subtype, then check each constrained discriminant value
2158 against the corresponding value read from the stream.
2159
029b67ba
YM
21602011-09-02 Yannick Moy <moy@adacore.com>
2161
2162 * usage.adb, warnsw.adb, sem_ch6.adb, opt.ads: Disable by default
2163 warnings on suspicious contracts, and enable them with -gnatwa.
2164
dc36a7e3
RD
21652011-09-02 Robert Dewar <dewar@adacore.com>
2166
2167 * exp_util.adb, exp_ch9.adb, sem_attr.adb, sem_ch6.adb: Minor
2168 reformatting.
2169
d5aa443c
AC
21702011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
2171
2172 * exp_ch9.adb (Install_Private_Data_Declarations): Add guards
2173 which ensure that restriction No_Dynamic_Attachment has not been
2174 violated.
2175 (Make_Initialize_Protection): Protected types with attach or
2176 interrupt handlers must not violate restriction No_Dynamic_Attachment.
2177 * exp_util.adb (Corresponding_Runtime_Package): Add a guard
2178 which ensures that restriction No_Dynamic_Attachment has not been
2179 violated.
2180 * sem_attr.adb: (Eval_Attribute): Transform
2181 VAX_Float_Type'First and 'Last into references to
2182 the temporaries which store the corresponding bounds. The
2183 transformation is needed since the back end cannot evaluate
2184 'First and 'Last on VAX.
2185 (Is_VAX_Float): New routine.
2186
21872011-09-02 Ed Schonberg <schonberg@adacore.com>
2188
2189 * sem_ch12.adb (Analyze_Subprogram_Instantiation): If the
2190 generic unit is not intrinsic and has an explicit convention,
2191 the instance inherits it.
2192
67c86178
AC
21932011-09-02 Robert Dewar <dewar@adacore.com>
2194
2195 * prj-dect.adb, prj-env.adb, prj-nmsc.adb, prj-proc.adb, prj-tree.adb,
2196 prj.adb, prj.ads, sem_ch5.adb: Minor reformatting.
2197
21982011-09-02 Thomas Quinot <quinot@adacore.com>
2199
2200 * sem_attr.adb (Analyze_Attribute, case Unrestriced_Access):
2201 Guard against a prefix that is an N_Has_Entity but has no
2202 associated entity.
2203
22042011-09-02 Yannick Moy <moy@adacore.com>
2205
2206 * lib-xref-alfa.adb (Is_Alfa_Reference): Ignore IN parameters in Alfa
2207 references.
2208
22092011-09-02 Yannick Moy <moy@adacore.com>
2210
2211 * opt.ads (Warn_On_Suspicious_Contract): New warning flag.
2212 * sem_ch3.adb (Analyze_Declarations): Call checker for suspicious
2213 contracts.
2214 * sem_ch6.adb, sem_ch6.ads (Check_Subprogram_Contract): New
2215 procedure looking for suspicious postconditions.
2216 * usage.adb (Usage): New options -gnatw.t and -gnatw.T.
2217 * warnsw.adb (Set_Dot_Warning_Switch): Take into account new
2218 options -gnatw.t and -gnatw.T.
2219
735ca1b9
PO
22202011-09-02 Pascal Obry <obry@adacore.com>
2221
2222 * prj.adb: Minor code refactoring. Move check for null project in
2223 Project_Changed.
2224 * projects.texi: Fix minor typos.
2225
86828d40
AC
22262011-09-02 Ed Schonberg <schonberg@adacore.com>
2227
2228 * sem_ch5.adb (Analyze_Iterator_Specification): If the domain
2229 of iteration is an expression, its value must be captured in a
2230 renaming declaration, so that modification of the elements is
2231 propagated to the original container.
2232
22332011-09-02 Pascal Obry <obry@adacore.com>
2234
2235 * prj-proc.adb, prj.adb, makeutl.adb, makeutl.ads, prj-dect.adb,
2236 prj-nmsc.adb, prj-util.adb, prj-conf.adb, prj-env.adb,
2237 prj-tree.adb: Minor reformatting and style fixes.
2238
83de674b
AC
22392011-09-02 Robert Dewar <dewar@adacore.com>
2240
2241 * s-rident.ads: Add new restriction No_Implicit_Aliasing
2242 * sem_attr.adb: (Analyze_Access_Attribute): Deal with
2243 No_Implicit_Aliasing
2244 (Analyze_Attribute, case Address): ditto
2245 (Analyze_Attribute, case Unrestricted_Access): ditto
2246 * sem_util.ads, sem_util.adb: (Is_Aliased_View): Handle
2247 No_Implicit_Aliasing restriction.
2248 * gnat_rm.texi: Add documentation for No_Implicit_Aliasing
2249
22502011-09-02 Ed Schonberg <schonberg@adacore.com>
2251
2252 * exp_util.adb: (Possible_Bit_Aligned_Object): If the object
2253 is an unchecked conversion, apply test to its expression.
2254
22552011-09-02 Javier Miranda <miranda@adacore.com>
2256
2257 * sem_ch3.adb (Check_Abstract_Overriding): When
2258 traversing the chain of aliased subprograms avoid reporting a
2259 redundant error on the current entity.
2260
22612011-09-02 Sergey Rybin <rybin@adacore.com>
2262
2263 * gnat_ugn.texi: Minor clean up.
2264
22652011-09-02 Bob Duff <duff@adacore.com>
2266
2267 * s-htable.adb (Set_If_Not_Present): Use renaming
2268 instead of ":=", because the type Key is limited in the generic (even
2269 if not in the instances).
2270
2c17ca0a
AC
22712011-09-02 Robert Dewar <dewar@adacore.com>
2272
2273 * exp_util.adb, sem_ch10.adb, sem_attr.adb, s-htable.adb,
2274 g-comlin.adb, g-comlin.ads, lib-xref-alfa.adb, lib-xref.adb: Minor
2275 reformatting.
2276
22772011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
2278
2279 * sem_ch3.adb: (Set_Anonymous_Type): Associate the itype of an
2280 inherited component with the enclosing derived type. Code reformatting.
2281
22822011-09-02 Gary Dismukes <dismukes@adacore.com>
2283
2284 * checks.adb: (Determine_Range): Add test of OK1 to prevent the early
2285 return done when overflow checks are enabled, since comparisons against
2286 Lor and Hir should not be done when OK1 is False.
2287
22882011-09-02 Gary Dismukes <dismukes@adacore.com>
2289
2290 * exp_ch6.adb (Add_Finalization_Master_Actual_To_Build_In_Place_Call):
2291 Add new formal Master_Exp. When present, add that expression to the
2292 call as an extra actual.
2293 (Make_Build_In_Place_Call_In_Object_Declaration): Add variable
2294 Fmaster_Actual and in the case of a BIP call initializing a return
2295 object of an enclosing BIP function set it to a
2296 new reference to the implicit finalization master
2297 formal of the enclosing function. Fmaster_Actual is
2298 then passed to the new formal Master_Exp on the call to
2299 Add_Finalization_Master_Actual_To_Build_ In_Place_Call. Move
2300 initializations of Enclosing_Func to its declaration.
2301
23022011-09-02 Thomas Quinot <quinot@adacore.com>
2303
2304 * csets.ads: Minor reformatting
2305
23062011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
2307
2308 * exp_aggr.adb: (Get_Constraint_Association): Add code to retrieve
2309 the full view of a private type coming from an instantiation.
2310 * exp_ch4.adb: (Current_Anonymous_Master): Reimplement the search
2311 loop to iterate over the declarations rather than use the
2312 First_Entity / Next_Entity scheme.
2313
ed32b82e
ES
23142011-09-02 Ed Schonberg <schonberg@adacore.com>
2315
2316 * sem_attr.adb: (Analyze_Attribute, case 'Range): when expanding
2317 X'range (N) into X'First (N) .. X'Last (N), do not share the
2318 dimension indicator N, if present. Even though it is a static
2319 constant, its source location may be modified when printing
2320 expanded code under -gnatDL, and node sharing will lead to chaos
2321 in Sprint on large files, by generating a sloc value that does
2322 not correspond to any source file.
2323
f7bb41af
AC
23242011-09-02 Bob Duff <duff@adacore.com>
2325
2326 * einfo.adb: (Has_Xref_Entry): Do not call
2327 Implementation_Base_Type. Lib.Xref has been
2328 rewritten to avoid the need for it, and it was costly.
2329 * s-htable.ads,s-htable.adb: (Present,Set_If_Not_Present): New
2330 functions in support of efficient xref.
2331 * lib-xref-alfa.adb: Misc changes related to Key component of
2332 type Xref_Entry.
2333 * lib-xref.adb: (Add_Entry,etc): Speed improvement.
2334 (New_Entry): Call Implementation_Base_Type, because Has_Xref_Entry
2335 no longer does. This is the one place where it is needed.
2336
23372011-09-02 Johannes Kanig <kanig@adacore.com>
2338
2339 * g-comlin.adb (Getopt): New optional argument Concatenate to have
2340 similar interface as the other Getopt function.
2341
23422011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
2343
2344 * exp_ch4.adb: (Expand_Allocator_Expression): Do not generate
2345 a call to Set_Finalize_Address if there is no allocator available.
2346 * exp_util.adb: (Build_Allocate_Deallocate_Proc): Account for
2347 a case of allocator expansion where the allocator is not expanded but
2348 needs a custom allocate routine. Code reformatting.
2349 (Is_Finalizable_Transient): Remove local variables Has_Rens and
2350 Ren_Obj. Code reformatting.
2351 (Is_Renamed): Renamed to Is_Aliased. Add code to detect aliasing
2352 through the use of 'reference.
2353 * sem_ch4.adb: (Analyze_Allocator): Detect allocators generated
2354 as part of build-in-place expansion. They are intentionally marked as
2355 coming from source, but their parents are not.
2356
bd0bc43e
AC
23572011-09-02 Ed Schonberg <schonberg@adacore.com>
2358
2359 * sem_ch10.adb (Analyze_With_Clause): If the library unit
2360 is the generated subprogram declaration for a child unit body
2361 that acts as spec, use the original body in the with_clause,
2362 to prevent binding errors.
2363
23642011-09-02 Vincent Celier <celier@adacore.com>
2365
2366 * gnat_ugn.texi: Adapt documentation of -gnateInnn to new VMS
2367 qualifier /MULTI_UNIT_INDEX=
2368
23692011-09-02 Johannes Kanig <kanig@adacore.com>
2370
2371 * g-comlin.adb (Getopt): Return when switch is dealt with automatically,
2372 instead of calling the callback function
2373
9fdb5d21
RD
23742011-09-02 Robert Dewar <dewar@adacore.com>
2375
2376 * prj-proc.adb, prj.ads, sem_util.adb, s-taprop-linux.adb,
2377 prj-nmsc.adb, prj-util.ads, prj-env.adb: Minor reformatting.
2378
c6d5d1ac
AC
23792011-09-02 Vincent Celier <celier@adacore.com>
2380
2381 * prj-nmsc.adb: (Find_Sources): When the list of sources is
2382 explicitly declared in an extending project, do not warn if a source
2383 for an inherited naming exception is not found.
2384
23852011-09-02 Gary Dismukes <dismukes@adacore.com>
2386
2387 * exp_ch6.adb: (Is_Build_In_Place_Function_Call): Return False if
2388 expansion is inactive.
2389
23902011-09-02 Ed Schonberg <schonberg@adacore.com>
2391
2392 * sem_util.adb (Note_Possible_Modification): If the entity
2393 being modified is the renaming generated for an Ada2012 iterator
2394 element, the enclosing container or array is modified as well.
2395
2ba1a7c7
AC
23962011-09-02 Jose Ruiz <ruiz@adacore.com>
2397
2398 * s-taprop-linux.adb (Initialize_Lock, Initialize_TCB,
2399 Initialize): Define and initialize the
2400 mutex attributes and condition variable attributes locally.
2401
24022011-09-02 Vincent Celier <celier@adacore.com>
2403
2404 * prj-nmsc.adb (Check_File): Mark as Locally_Removed a naming
2405 exception replaced in an extending project.
2406 (Check_Object): No error when the other source is locally removed.
2407
24082011-09-02 Yannick Moy <moy@adacore.com>
2409
2410 * exp_ch6.adb (Is_Build_In_Place_Function_Call): in Alfa mode, allow
2411 unresolved calls.
2412
d51813db
AC
24132011-08-31 Arnaud Charlet <charlet@adacore.com>
2414
2415 * gcc-interface/Makefile.in: Clean up handling of x86 and x86-64
2416 run-time files.
2417 * gcc-interface/Make-lang.in: Update dependencies.
2418
9f55bc62
AC
24192011-09-01 Robert Dewar <dewar@adacore.com>
2420
2421 * sem_ch3.adb, s-taprop-linux.adb, gnatls.adb: Minor reformatting.
2422
24232011-09-01 Jose Ruiz <ruiz@adacore.com>
2424
2425 * adaint.h (__gnat_cpu_free): Fix the name of this profile.
2426 * adaint.c (__gnat_cpu_alloc, __gnat_cpu_alloc_size, __gnat_cpu_free,
2427 __gnat_cpu_zero, __gnat_cpu_set): Create version of these subprograms
2428 specific for systems where their glibc version does not define the
2429 routines to handle dynamically allocated CPU sets.
2430
24312011-09-01 Vincent Celier <celier@adacore.com>
2432
2433 * prj-proc.adb, prj.ads, prj-nmsc.adb, prj-util.adb, prj-util.ads,
2434 prj-env.adb: Implement inheritance of naming exceptions in extending
2435 projects.
2436
d7386a7a
AC
24372011-09-01 Romain Berrendonner <berrendo@adacore.com>
2438
2439 * gnatls.adb: Display simple message instead of content of
2440 gnatlic.adl.
2441
24422011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
2443
2444 * sem_ch3.adb: (Build_Derived_Record_Type) Remove the kludgy update of
2445 access discriminant and anonymous access component scopes.
2446 (Inherit_Component): Reuse the itype of an access discriminant
2447 or anonymous access component by copying it in order to set the proper
2448 scope. This is done only when the parent and the derived type
2449 are in different scopes.
2450 (Set_Anonymous_Etype): New routine.
2451
24522011-09-01 Robert Dewar <dewar@adacore.com>
2453
2454 * a-convec.adb: Minor reformatting throughout.
2455
9d1e0e72
JR
24562011-09-01 Jose Ruiz <ruiz@adacore.com>
2457
2458 * adaint.c, adaint.h (__gnat_cpu_alloc, __gnat_cpu_alloc_size,
2459 __gnat_cpu_set_free): Create these wrappers around the CPU_ALLOC,
2460 CPU_ALLOC_SIZE and CPU_FREE linux macros.
2461 (__gnat_cpu_zero, __gnat_cpu_set): Use the CPU_ZERO_S and
2462 CPU_SET_S respectively because we are now using dynamically allocated
2463 CPU sets which are more portable across different glibc versions.
2464 * s-osinte-linux.ads (cpu_set_t_ptr, CPU_ALLOC, CPU_ALLOC_SIZE,
2465 CPU_FREE): Add this type and subprograms to be able to create cpu_set_t
2466 masks dynamically according to the number of processors in the target
2467 platform.
2468 (CPU_ZERO, CPU_SET): They are now mapped to the CPU_ZERO_S and CPU_SET_S
2469 respectively, so we need to pass the size of the masks as
2470 parameters.
2471 * s-taprop-linux.adb (Create_Task, Set_Task_Affinity): Use dynamically
2472 created cpu_set_t masks
2473 with the number of processors available in the target platform,
2474 instead of static bit arrays. It enhances portability because
2475 it uses the information from the target platform.
2476 * sem_ch8.adb: (Attribute_Renaming): When checking whether we
2477 are using a restricted run-time library, use the flag
2478 Configurable_Run_Time_Mode instead of Restricted_Profile.
2479
a95be2d4
AC
24802011-09-01 Vincent Celier <celier@adacore.com>
2481
2482 * ug_words: Add /MULTI_UNIT_INDEX= -> -gnateI
2483 * vms_data.ads: Add new VMS qualifier equivalent for -gnateInnn
2484
24852011-09-01 Nicolas Roche <roche@adacore.com>
2486
2487 * adaint.c (__gnat_tmp_name): Don't use tmpnam function from the system
2488 on VxWorks in kernel mode.
2489
6b81741c
AC
24902011-09-01 Jose Ruiz <ruiz@adacore.com>
2491
2492 * s-taprop-linux.adb (Create_Task, Set_Task_Affinity): Use the linux
2493 macros for handling CPU sets (CPU_ZERO, CPU_SET) instead of modifying
2494 directly the bit array.
2495 * s-osinte-linux.ads (CPU_ZERO, CPU_SET): Import these wrappers around
2496 the linux macros with the same name.
2497 * adaint.h, adaint.c (__gnat_cpu_zero, __gnat_cpu_set): Create these
2498 wrappers around the CPU_ZERO and CPU_SET linux macros.
2499
25002011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
2501
2502 * exp_ch7.adb (Find_Insertion_List): Removed.
2503 (Process_Transient_Objects): Insert the declarations of the hook
2504 access type and the hook object before the associated transient object.
2505
25062011-09-01 Jose Ruiz <ruiz@adacore.com>
2507
2508 * sem_ch8.adb (Attribute_Renaming): Add missing check to avoid loading
2509 package System.Aux_Dec when using restricted run-time libraries which
2510 do not have this package.
2511
25122011-09-01 Tristan Gingold <gingold@adacore.com>
2513
2514 * s-vaflop-vms-alpha.adb: Remove pragma optimize, useless.
2515
25162011-09-01 Bob Duff <duff@adacore.com>
2517
2518 * sem_attr.adb (Analyze_Access_Attribute): Do not call
2519 Kill_Current_Values for P'Unrestricted_Access, where P is library level
2520
25212011-09-01 Thomas Quinot <quinot@adacore.com>
2522
2523 * exp_ch5.adb: Minor reformatting
2524 * gnat_ugn.texi: Fix minor typos.
2525 * gcc-interface/Make-lang.in: Update dependencies.
2526
8256c1bf
AC
25272011-09-01 Robert Dewar <dewar@adacore.com>
2528
2529 * inline.adb, sem_aggr.adb: Minor reformatting.
2530
25312011-09-01 Ed Schonberg <schonberg@adacore.com>
2532
2533 * a-convec.adb: Proper handling of cursors for Ada2012 iterators.
2534
d1c5f424
AC
25352011-09-01 Robert Dewar <dewar@adacore.com>
2536
2537 * prj-proc.adb, exp_ch6.adb, prj-env.adb: Minor reformatting.
2538
25392011-09-01 Bob Duff <duff@adacore.com>
2540
2541 * sem_aggr.adb (Resolve_Aggregate): Need to treat "in instance
2542 body" the same as "in inlined body", because visibility shouldn't
2543 apply there.
2544
25452011-09-01 Eric Botcazou <ebotcazou@adacore.com>
2546
2547 * inline.adb (Add_Inlined_Body): Refine previous change.
2548
1bb6e262
AC
25492011-09-01 Gary Dismukes <dismukes@adacore.com>
2550
2551 * exp_ch6.ads (Needs_BIP_Alloc_Form): New utility function.
2552 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
2553 Test for case where call
2554 initializes an object of a return statement before testing for
2555 a constrained call, to ensure that all such cases get handled
2556 by simply passing on the caller's parameters. Also, in that
2557 case call Needs_BIP_Alloc_Form to determine whether to pass on
2558 the BIP_Alloc_Form parameter of the enclosing function rather
2559 than testing Is_Constrained. Add similar tests for the return
2560 of a BIP call to later processing to ensure consistent handling.
2561 (Needs_BIP_Alloc_Form): New utility function.
2562 * sem_ch6.adb: (Create_Extra_Formals): Replace test for adding
2563 a BIP_Alloc_Form formal with call to new utility function
2564 Needs_BIP_Alloc_Form.
2565
25662011-09-01 Pascal Obry <obry@adacore.com>
2567
2568 * prj-part.adb: Minor reformatting.
2569
25702011-09-01 Vincent Celier <celier@adacore.com>
2571
2572 * prj-env.adb (Create_Mapping_File.Process): Encode the upper
2573 half character in the unit name.
2574
db15225a
AC
25752011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
2576
2577 * exp_ch4.adb: Minor code and comment reformatting.
2578
25792011-09-01 Thomas Quinot <quinot@adacore.com>
2580
2581 * exp_ch6.adb (Expand_Inlined_Call): Remove redundant tests
2582 for Is_Limited_Type and Is_Tagged_Type in condition checking
2583 for by-reference type.
2584 * inline.adb (Add_Inlined_Body): Only exclude init_procs. Other
2585 subprograms may have a completion because of a previous
2586 Inline_Always clause, but the enclosing package must be marked
2587 inlined for the subprogram body to become visible to the backend.
2588
9d641fc0
TQ
25892011-09-01 Thomas Quinot <quinot@adacore.com>
2590
2591 * sem_aux.adb, exp_ch4.adb: Minor reformatting
2592
dbe36d67
AC
25932011-09-01 Pascal Obry <obry@adacore.com>
2594
2595 * prj-proc.adb, prj.ads, sinput-p.adb: Minor reformatting.
2596
25972011-09-01 Ed Schonberg <schonberg@adacore.com>
2598
2599 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Generate references to
2600 the formals of a subprogram stub that acts as a spec.
2601
26022011-09-01 Ed Schonberg <schonberg@adacore.com>
2603
2604 * exp_ch6.adb (Expand_Inlined_Call): If an actual is a by_reference
2605 type, declare a renaming for it, not an object declaration.
2606
f5037886
AC
26072011-09-01 Yannick Moy <moy@adacore.com>
2608
2609 * ali-util.adb, ali-util.ads (Read_Withed_ALIs): Add parameter
2610 Ignore_Errors to ignore failures to read ALI files when True.
2611
26122011-09-01 Javier Miranda <miranda@adacore.com>
2613
2614 * exp_ch3.adb (Expand_N_Object_Declaration): Handle non-default
2615 constructor calls associated with non-tagged record types.
2616
26172011-09-01 Robert Dewar <dewar@adacore.com>
2618
2619 * g-socthi-vms.adb: Minor reformatting.
2620
26212011-09-01 Nicolas Roche <roche@adacore.com>
2622
2623 * sysdep.c: Don't use macro functions for stdio functions on VxWorks
2624 in order to avoid impact of imcompatible changes.
2625 * cstreams.c: Likewise
2626 * cio.c: Likewise
2627 * aux-io.c: Likewise
2628
26292011-09-01 Yannick Moy <moy@adacore.com>
2630
2631 * lib-writ.adb (Write_With_Lines): Always output complete information
2632 on "with" line in Alfa mode, as this is required by formal verification
2633 back-end.
2634
549e4558
AC
26352011-09-01 Tristan Gingold <gingold@adacore.com>
2636
2637 * g-socthi-vms.adb: Add comments.
2638
26392011-09-01 Pascal Obry <obry@adacore.com>
2640
2641 * prj.ads: Minor reformatting.
2642
70c0422d
AC
26432011-09-01 Vincent Celier <celier@adacore.com>
2644
2645 * prj-env.adb (Create_Config_Pragmas_File.Check): Put all naming
2646 exceptions in the config pragmas file.
2647
26482011-09-01 Tristan Gingold <gingold@adacore.com>
2649
2650 * gnat_ugn.texi: Document GNAT_STACK_SIZE on IVMS.
2651
8c5b03a0
AC
26522011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
2653
2654 * exp_ch7.adb (Find_Insertion_List): New routine.
2655 (Process_Transient_Objects): Add code to handle the abnormal
2656 finalization of a controlled transient associated with a subprogram
2657 call. Since transients are cleaned up right after the associated
2658 context, an exception raised during a subprogram call may bypass the
2659 finalization code.
2660
26612011-09-01 Robert Dewar <dewar@adacore.com>
2662
2663 * exp_ch6.adb (Expand_Call): Check actual for aliased parameter is
2664 aliased.
2665
3040dbd4
RD
26662011-09-01 Robert Dewar <dewar@adacore.com>
2667
2668 * exp_ch4.adb, a-exexda.adb: Minor reformatting.
2669
fecbd779
AC
26702011-09-01 Robert Dewar <dewar@adacore.com>
2671
2672 * s-taskin.ads, s-tassta.adb, sem_ch13.adb: Minor reformatting.
2673
26742011-09-01 Thomas Quinot <quinot@adacore.com>
2675
2676 * Makefile.rtl: Move s-oscons.o from GNATRTL_TASKING_OBJS to
2677 GNATRTL_NONTASKING_OBJS.
2678
26792011-09-01 Robert Dewar <dewar@adacore.com>
2680
2681 * einfo.ads (Is_Aliased): Fix existing documentation and add note on
2682 possibility of this flag being set for formals in Ada 2012 mode.
2683 * par-ch6.adb (P_Formal_Part): Handle aliased for parameters for Ada
2684 2012.
2685 * sem_ch6.adb (Process_Formals): Handle aliased parameters in Ada 2012
2686 mode.
2687 * sinfo.adb (Aliased_Present): Allowed in N_Parameter_Specification for
2688 Ada 2012.
2689 * sinfo.ads (Aliased_Present): Allowed in N_Parameter_Specification for
2690 Ada 2012.
2691
26922011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
2693
2694 * exp_ch4.adb (Find_Insertion_Node): New routine. Determines the proper
2695 insertion node in a tree of nested Expression_With_Actions nodes.
2696 (Process_Transient_Object): In the case where a complex if statement
2697 has been converted into nested Expression_With_Actions nodes, the
2698 "hook" object and the associated access type must be inserted before
2699 the top most Expression_With_Actions.
2700
516f608f
AC
27012011-09-01 Robert Dewar <dewar@adacore.com>
2702
2703 * a-cbprqu.adb, a-cbprqu.ads, a-cuprqu.adb, a-cuprqu.ads,
2704 a-cbsyqu.adb, a-cbsyqu.ads: Minor reformatting.
2705
27062011-09-01 Ed Schonberg <schonberg@adacore.com>
2707
2708 * sem_attr.adb: Conditionalize aliasing predicates to Ada2012.
2709
27102011-09-01 Jose Ruiz <ruiz@adacore.com>
2711
2712 * aspects.ads (Aspect_Id, Aspect_Argument, Aspect_Names): Add the CPU
2713 aspect.
2714 * aspects.adb (Canonical_Aspect): Add entry for the CPU aspect.
2715 * sem_ch13.adb (Analyze_Aspect_Specifications): Analyze the CPU aspect
2716 in a similar way as we do for the Priority or Dispatching_Domain aspect.
2717 * s-mudido-affinity.adb (Dispatching_Domain_Tasks,
2718 Dispatching_Domains_Frozen): Move this local data to package
2719 System.Tasking because with the CPU aspect we need to have access
2720 to this data when creating the task in System.Tasking.Stages.Create_Task
2721 * s-taskin.ads (Dispatching_Domain_Tasks, Dispatching_Domains_Frozen):
2722 Move these variables from the body of
2723 System.Multiprocessors.Dispatching_Domains because with the CPU aspect
2724 we need to have access to this data when creating the task in
2725 System.Tasking.Stages.Create_Task.
2726 * s-taskin.adb (Initialize): Signal the allocation of the environment
2727 task to a CPU, if any, so that we know whether the CPU can be
2728 transferred to a different dispatching domain.
2729 * s-tassta.adb (Create_Task): Check whether the CPU to which this task
2730 is being allocated belongs to the dispatching domain where the task
2731 lives. Signal the allocation of the task to a CPU, if any, so that we
2732 know whether the CPU can be transferred to a different dispatching
2733 domain.
2734
2d42e881
ES
27352011-09-01 Ed Schonberg <schonberg@adacore.com>
2736
2737 * exp_attr.adb, sem_attr.adb, snames.ads-tmpl: Implementation of
2738 attributes Same_Storage and Overlaps_Storage.
2739
579fda56
AC
27402011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
2741
2742 * exp_strm.adb: Remove with and use clause for Opt.
2743 (Build_Array_Input_Function): Remove the version-dependent generation
2744 of the return statement. The Ada 2005 tree is now the default.
2745
27462011-09-01 Yannick Moy <moy@adacore.com>
2747
2748 * put_alfa.adb: Unconditionnally write files in Alfa section, so that
2749 it is never empty when compiling in Alfa mode.
2750
27512011-09-01 Robert Dewar <dewar@adacore.com>
2752
2753 * sem_aggr.adb, sem_ch3.adb, a-direct.adb, s-taprop-vxworks.adb,
2754 comperr.adb, exp_ch9.adb, exp_pakd.adb, sem_ch12.adb, freeze.adb,
2755 s-taprop-mingw.adb, s-taprop-linux.adb, s-taprop-solaris.adb,
2756 gnat1drv.adb, a-rbtgbo.adb, exp_dist.adb: Minor reformatting
2757
27582011-09-01 Matthew Heaney <heaney@adacore.com>
2759
2760 * Makefile.rtl, impunit.adb: Add a-csquin.ads, a-cusyqu.ad[sb],
2761 a-cuprqu.ad[sb], a-cbsyqu.ad[sb], a-cbprqu.ad[sb]
2762 * a-csquin.ads: New Ada 2012 unit that specifies the queue interface
2763 * a-cusyqu.ads, a-cusyqu.adb: New Ada 2012 unit that specifies the
2764 unbounded queue container.
2765 * a-cbsyqu.ads, a-cbsyqu.adb: New Ada 2012 unit that specifies the
2766 bounded queue container.
2767 * a-cuprqu.ads, a-cuprqu.adb: New Ada 2012 unit that specifies the
2768 unbounded priority queue container.
2769 * a-cbprqu.ads, a-cbprqu.adb: New Ada 2012 unit that specifies the
2770 bounded priority queue container.
2771
24c34107
AC
27722011-08-31 Pascal Obry <obry@adacore.com>
2773
2774 * a-direct.adb: Do not try to create an UNC path on Windows.
2775 (Create_Path): Skip leading computer name in UNC path if any.
2776
27772011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
2778
2779 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function): Remove the
2780 version-dependent generation of the return statement. The Ada 2005 tree
2781 is now the default.
2782
27832011-08-31 Thomas Quinot <quinot@adacore.com>
2784
2785 * rtsfind.ads, exp_dist.adb (Find_Numeric_Representation): Predefined
2786 types Stream_Element_Offset and Storage_Offset have a different native
2787 type depending on whether the platform is 32 or 64 bits. When
2788 exchanging them, always convert to 64 bits.
2789
27902011-08-31 Yannick Moy <moy@adacore.com>
2791
2792 * debug.adb: Reserve debug option -gnatd.E for passing gnatprove option
2793 --force-alfa to gnat2why.
2794
27952011-08-31 Ed Schonberg <schonberg@adacore.com>
2796
2797 * sem_ch12.adb (Save_References): If the node has aspects, save
2798 references within the corresponding expressions in a separate step,
2799 because the aspects are not directly in the tree for the declaration
2800 to which they belong.
2801
28022011-08-31 Arnaud Charlet <charlet@adacore.com>
2803
2804 * freeze.adb (Freeze_Record_Type): Omit test on variable size component
2805 in CodePeer mode, since representation clauses are partially ignored.
2806 * gcc-interface/Make-lang.in: Update dependencies.
2807
702d2020
AC
28082011-08-31 Jose Ruiz <ruiz@adacore.com>
2809
2810 * s-taprop-vxworks.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
2811 s-taprop-solaris.adb (Create_Task): Not_A_Specific_CPU can be assigned
2812 to any dispatching domain.
2813
28142011-08-31 Thomas Quinot <quinot@adacore.com>
2815
2816 * exp_ch4.adb: Minor reformatting.
2817
28182011-08-31 Bob Duff <duff@adacore.com>
2819
2820 * sem_ch6.adb (Get_Generic_Parent_Type): Don't query Subtype_Indication
2821 on nodes for which it is not defined.
2822 (Is_Non_Overriding_Operation): Exit the loop when we find a generic
2823 parent type.
2824
28252011-08-31 Bob Duff <duff@adacore.com>
2826
2827 * sem_ch3.adb (Process_Full_View): Disable legality check if
2828 In_Instance, to avoid spurious errors.
2829 * sem_ch12.adb (Validate_Derived_Type_Instance): Disable legality check
2830 if In_Instance, to avoid spurious errors.
2831
28322011-08-31 Pascal Obry <obry@adacore.com>
2833
2834 * a-direct.adb: Use Dir_Seps everywhere to properly handle all
2835 directory speparators.
2836 (Compose): Use Dir_Seps to handle both forms.
2837 (Create_Path): Use Dir_Seps instead of explicit check, no semantic
2838 changes.
2839 (Extension): Use Dir_Seps to handle both forms.
2840
28412011-08-31 Pascal Obry <obry@adacore.com>
2842
2843 * prj-conf.adb: Minor reformatting.
2844
67645bde
AC
28452011-08-31 Jose Ruiz <ruiz@adacore.com>
2846
2847 * aspects.ads (Aspect_Id, Aspect_Argument, Aspect_Names): Add the
2848 dispatching domain aspect.
2849 * aspects.adb (Canonical_Aspect): Add entry for the dispatching domain
2850 aspect.
2851 * sem_ch13.adb (Analyze_Aspect_Specifications): Analyze the
2852 Dispatching_Domain aspect in a similar way as we do for the Priority
2853 aspect.
2854 * exp_ch9.adb (Expand_N_Task_Type_Declaration): Add the
2855 Dispatching_Domain component if a Dispatching_Domain pragma or aspect
2856 is present.
2857 (Make_Task_Create_Call): Add the Dispatching_Domain when creating a task
2858 * par-prag.adb (Prag): Add Pragma_Dispatching_Domain as a known pragma.
2859 * sem_prag.adb (Analyze_Pragma): Check the correctness of a pragma
2860 Dispatching_Domain and add it to the task definition.
2861 (Sig_Flags): Add Pragma_Dispatching_Domain.
2862 * rtsfind.ads, rtsfind.adb (RTU_Id, RE_Id, Get_Unit_Name): Add the
2863 support to find the types Dispatching_Domain and
2864 Dispatching_Domain_Access.
2865 * sinfo.ads, sinfo.adb (Has_Pragma_Dispatching_Domain,
2866 Set_Has_Pragma_Dispatching_Domain): Add these subprograms to set and
2867 query the availability of a pragma Dispatching_Domain.
2868 * snames.ads-tmpl (Name_uDispatching_Domain): Add this name required by
2869 the expander to pass the Dispatching_Domain when creating a task.
2870 (Name_Dispatching_Domain): Add this new name for a pragma.
2871 (Pragma_Id): Add the new Pragma_Dispatching_Domain.
2872 * s-tassta.ads, s-tassta.adb (Create_Task): Set the domain to which the
2873 task has been allocated at creation time.
2874 * s-tarest.adb (Create_Restricted_Task): The dispatching domain using
2875 Ravenscar is always null.
2876 * s-taskin.ads, s-taskin.adb (Initialize_ATCB): Set the domain to which
2877 the task has been allocated at creation time.
2878 * s-tporft.adb (Register_Foreign_Thread): A foreign task will not have
2879 a specific dispatching domain.
2880 * s-taprop-linux.adb, s-taprop-solaris.adb, s-taprop-vxworks.adb,
2881 s-taprop-mingw.adb (Create_Task): Check whether both Dispatching_Domain
2882 and CPU are specified for the task, and the CPU value is not contained
2883 within the range of processors for the domain.
2884
28852011-08-31 Vincent Celier <celier@adacore.com>
2886
2887 * make.adb (Original_Gcc) : New constant String_Access.
2888 (Gnatmake): For VM targets, do not use VM version of the compiler if
2889 --GCC= has been specified.
2890
28912011-08-31 Thomas Quinot <quinot@adacore.com>
2892
2893 * sem_ch5.adb: Minor reformatting.
2894
28952011-08-31 Ed Schonberg <schonberg@adacore.com>
2896
2897 * exp_pakd.adb (Convert_To_PAT_Type): If prefix is a function call, do
2898 not reanalyze it.
2899
29002011-08-31 Bob Duff <duff@adacore.com>
2901
2902 * exp_ch4.adb (Expand_N_Selected_Component): Use the full type, in case
2903 the access type is private; we don't care about privacy in expansion.
2904
29052011-08-31 Ed Schonberg <schonberg@adacore.com>
2906
2907 * sem_aggr.adb (Resolve_Aggregate): In an instance, ignore aggregate
2908 subcomponents tnat may be limited, because they originate in view
2909 conflicts. If the original aggregate is legal and the actuals are
2910 legal, the aggregate itself is legal.
2911
b8789727
AC
29122011-08-31 Matthew Heaney <heaney@adacore.com>
2913
2914 * a-rbtgbo.adb (Clear_Tree): Assert representation invariant for lock
2915 status.
2916
29172011-08-31 Ed Schonberg <schonberg@adacore.com>
2918
2919 * sem_ch5.adb: Set kind of loop parameter properly, to preserve all
2920 errors in B tests.
2921
29222011-08-31 Jose Ruiz <ruiz@adacore.com>
2923
2924 * sem_ch13.adb (Analyze_Aspect_Specifications): For the Priority and
2925 Interrupt_Priority aspects, force the analysis of the aspect expression
2926 (when building the equivalent pragma). Otherwise, its analysis is done
2927 too late, after the task or protected object has been created.
2928 * sem_ch9.adb (Analyze_Single_Protected_Declaration,
2929 Analyze_Single_Task_Declaration): Remove the code to move the aspects
2930 to the object declaration because they are needed in the type
2931 declaration.
2932
e0c32166
AC
29332011-08-31 Robert Dewar <dewar@adacore.com>
2934
2935 * exp_ch5.adb, exp_ch7.ads, sem_ch5.adb, put_scos.adb, s-rannum.adb,
2936 a-rbtgbo.adb, exp_intr.adb, a-cbdlli.adb, a-cbdlli.ads: Minor
2937 reformatting.
2938
29392011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
2940
2941 * exp_util.adb (Find_Protection_Type): Do not look for fields _object
2942 if the corresponding type is malformed due to restriction violations.
2943
29442011-08-31 Robert Dewar <dewar@adacore.com>
2945
2946 * s-ransee.ads, s-ransee.adb: Minor reformatting.
2947
29482011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
2949
2950 * exp_ch4.adb (Expand_N_Allocator): Correct faulty condition which
2951 would cause the generation of Set_Finalize_Address if the target is a
2952 VM and the designated type is not derived from [Limited_]Controlled.
2953
29542011-08-31 Arnaud Charlet <charlet@adacore.com>
2955
2956 * comperr.adb, comperr.ads, gnat1drv.adb (Delete_SCIL_Files): New
2957 subprogram.
2958 (Compiler_Abort, Gnat1drv): Call Delete_SCIL_Files in codepeer mode in
2959 case of a compilation error.
2960
29612011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
2962
2963 * init.c (__gnat_error_handler): Standardize the stack overflow or
2964 erroneous memory access message.
2965 * seh_init.c (__gnat_SEH_error_handler): Standardize the stack overflow
2966 or erroneous memory access message.
2967
11bc76df
AC
29682011-08-31 Robert Dewar <dewar@adacore.com>
2969
2970 * sem_ch4.adb: Minor reformatting.
2971 * sem_ch6.adb: Minor code reorganization (use Ekind_In).
2972
29732011-08-31 Thomas Quinot <quinot@adacore.com>
2974
2975 * scos.ads: Minor documentation clarification.
2976 * put_scos.adb: Do not generate SCO unit header line for a unit that
2977 has no SCO lines.
2978
876d4394
RD
29792011-08-31 Robert Dewar <dewar@adacore.com>
2980
2981 * a-rbtgbo.adb, alfa_test.adb: Minor reformatting.
2982
36b8f95f
AC
29832011-08-31 Tristan Gingold <gingold@adacore.com>
2984
2985 * exp_ch7.ads, exp_ch7.adb (Finalization_Exception_Data): New type to
2986 hold variables between these following subprograms.
2987 (Build_Exception_Handler, Build_Object_Declarations,
2988 Build_Raise_Statement): Use the above type as parameter.
2989 Make the above adjustments.
2990 * exp_intr.adb (Expand_Unc_Deallocation): Adjust.
2991
29922011-08-31 Pascal Obry <obry@adacore.com>
2993
2994 * projects.texi: Minor reformatting.
2995
29962011-08-31 Tristan Gingold <gingold@adacore.com>
2997
2998 * s-ransee.ads, s-ransee.adb: Add system.random_seed unit.
2999 * s-rannum.adb (Reset): Use Get_Seed from s-ransee.
3000
30012011-08-31 Ed Schonberg <schonberg@adacore.com>
3002
3003 * exp_ch5.adb: Minor code cleanup.
3004 * sem_ch5.adb (Analyze_Iteration_Scheme): Set ekind of loop variable to
3005 prevent cascaded errors.
3006 (Analyze_Loop_Statement): In semantics-only mode, introduce loop
3007 variable of an iterator specification in current scope.
3008 * sem_ch6.adb (Analyze_Return_Statement, Find_what_It_Apples_To): Skip
3009 postconditions on the stack, as they contain no return statements.
3010
30112011-08-31 Yannick Moy <moy@adacore.com>
3012
3013 * exp_alfa.adb (Expand_Alfa_N_Package_Declaration,
3014 Expand_Alfa_N_Subprogram_Body): Remove useless procedures which simply
3015 call Qualify_Entity_Names.
3016 (Expand_Alfa): call Qualify_Entity_Names in more cases
3017 * lib-xref-alfa.adb: Take into account system package.
3018 * sem_prag.adb Take into account restrictions in Alfa mode, contrary to
3019 CodePeer mode in which we are interested in finding bugs even if
3020 compiler cannot compile source.
3021 * sem_util.adb, sem_util.ads (Unique_Entity): Take into account case of
3022 deferred constant.
3023
30242011-08-31 Gary Dismukes <dismukes@adacore.com>
3025
3026 * sem_ch3.adb (Constrain_Concurrent): Retrieve Base_Type of the subtype
3027 denoted by the subtype mark to ensure getting the concurrent type in
3028 the case where the subtype mark denotes a private subtype of a
3029 concurrent type (needed when using -gnatc).
3030 (Process_Subtype): For the processing specific to type kinds, case on
3031 the Base_Type kind of the Subtype_Mark_Id, to handle cases where the
3032 subtype denotes a private subtype whose base type is nonprivate (needed
3033 for subtypes of private fulfilled by task types when compiling with
3034 -gnatc).
3035
30362011-08-31 Gary Dismukes <dismukes@adacore.com>
3037
3038 * sem_disp.adb (Check_Dispatching_Operation): Bypass registration of
3039 late primitives that override interface operations when the full
3040 expander is not active, to avoid blowups in Register_Primitive when
3041 types don't have associated secondary dispatch tables.
3042
30432011-08-31 Yannick Moy <moy@adacore.com>
3044
3045 * alfa_test.adb: Code clean up.
3046
30472011-08-31 Marc Sango <sango@adacore.com>
3048
3049 * restrict.adb (Check_SPARK_Restriction): Change Comes_From_Source (N)
3050 by Comes_From_Source (Original_Node (N)) in order to treat also the
3051 nodes which have been rewritten.
3052 * sem_ch4.adb (Analyze_Explicit_Dereference, Analyze_Slice): Guard the
3053 explicit dereference and slice violation in spark mode on the nodes
3054 coming only from the source code.
3055
8cf23b91
AC
30562011-08-31 Robert Dewar <dewar@adacore.com>
3057
3058 * exp_ch5.adb, exp_alfa.ads, prj.ads, sem_attr.adb,
3059 lib-xref-alfa.adb: Minor reformatting.
3060
30612011-08-31 Matthew Heaney <heaney@adacore.com>
3062
3063 * a-crbltr.ads (Tree_Type): Default-initialize the Nodes component.
3064
30652011-08-31 Javier Miranda <miranda@adacore.com>
3066
3067 * sem_ch4.adb (Try_Object_Operation): Addition of one formal to search
3068 only for class-wide subprograms conflicting with entities of concurrent
3069 tagged types.
3070
30712011-08-31 Matthew Heaney <heaney@adacore.com>
3072
3073 * a-rbtgbo.adb (Generic_Allocate): Initialize pointer components of
3074 node to null value.
3075
30762011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3077
3078 * sem_ch12.adb (Insert_Freeze_Node_For_Instance): Provide a more
3079 general description of the routine.
3080
30812011-08-31 Ed Schonberg <schonberg@adacore.com>
3082
3083 * a-cbdlli.adb, a-cbdlli.ads: Add iterator machinery to bounded
3084 doubly-linked lists.
3085
0bb3bfb8
GD
30862011-08-31 Gary Dismukes <dismukes@adacore.com>
3087
3088 * exp_ch5.adb (Expand_N_Assignment_Statement): When a discriminant
3089 check is needed for a left-hand side that is a dereference, and the
3090 base type is private without discriminants (whereas the full type does
3091 have discriminants), an extra retrieval of the underlying type may be
3092 needed in the case where the subtype is a record subtype whose base
3093 type is private. Update comments.
3094
11fa950b
AC
30952011-08-31 Javier Miranda <miranda@adacore.com>
3096
3097 * sem_ch4.adb (Try_Object_Operation): When a dispatching primitive is
3098 found check if there is a class-wide subprogram covering the primitive.
3099
31002011-08-31 Yannick Moy <moy@adacore.com>
3101
3102 * sem_res.adb: Further cases where full expansion test is needed,
3103 rather than expansion test.
3104
31052011-08-31 Pascal Obry <obry@adacore.com>
3106
3107 * prj-attr.adb: Fix Source_File_Switches attribute kind (must be a list)
3108
31092011-08-31 Ed Schonberg <schonberg@adacore.com>
3110
3111 * exp_ch5.adb: Handle iterators over derived container types.
3112
31132011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3114
3115 * einfo.ads, einfo.adb: Add new flag Has_Anonymous_Master.
3116 (Has_Anonymous_Master): New routine.
3117 (Set_Has_Anonymous_Master): New routine.
3118 (Write_Entity_Flags): Add an entry for Has_Anonymous_Master.
3119 * exp_ch4.adb: Add with and use clause for Sem_Ch8.
3120 (Current_Anonymous_Master): New routine.
3121 (Current_Unit_First_Declaration): Removed.
3122 (Current_Unit_Scope): Removed.
3123 (Expand_N_Allocator): Anonymous access-to-controlled types now chain
3124 their objects on a per-unit heterogeneous finalization master.
3125
31262011-08-31 Matthew Heaney <heaney@adacore.com>
3127
3128 * a-cbhama.adb, a-cbhase.adb (Insert): Check for zero-length buckets
3129 array.
3130
31312011-08-31 Jose Ruiz <ruiz@adacore.com>
3132
3133 * s-taprop-linux.adb (Create_Task): Avoid changing the affinity mask
3134 when not needed.
3135
31362011-08-31 Gary Dismukes <dismukes@adacore.com>
3137
3138 * sem_disp.adb (Propagate_Tag): Return without propagating in the case
3139 where the actual is an unexpanded call to 'Input.
3140
d2b4b3da
AC
31412011-08-31 Yannick Moy <moy@adacore.com>
3142
3143 * sem_ch4.adb: Code clean up.
3144
31452011-08-31 Yannick Moy <moy@adacore.com>
3146
3147 * exp_alfa.adb, exp_alfa.ads: Minor correction of copyright notice.
3148
31492011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3150
3151 * exp_ch7.adb (Build_Array_Deep_Procs): Do not generate Deep_Finalize
3152 and TSS primitive Finalize_Address if finalization is suppressed.
3153 (Build_Record_Deep_Procs): Do not generate Deep_Finalize and TSS
3154 primitive Finalize_Address if finalization is suppressed.
3155
31562011-08-31 Jose Ruiz <ruiz@adacore.com>
3157
3158 * s-mudido-affinity.adb, s-taprop-linux.adb, s-taprop-mingw.adb,
3159 s-taprop-solaris.adb, s-taprop-vxworks.adb (Set_Task_Affinity): Make
3160 sure that the underlying task has already been created before trying
3161 to change its affinity.
3162 (Set_CPU): Use the term processor instead of CPU, as we do in
3163 Assign_Task.
3164
31652011-08-31 Vincent Celier <celier@adacore.com>
3166
3167 * prj-attr.adb: New Compiler attribute Source_File_Switches.
3168 * prj-nmsc.adb (Process_Compiler): Process attribute
3169 Source_File_Switches.
3170 * prj.ads (Language_Config): New name list component
3171 Name_Source_File_Switches.
3172 * snames.ads-tmpl (Name_Source_File_Switches): New standard name.
3173
31742011-08-31 Ed Schonberg <schonberg@adacore.com>
3175
3176 * sem_attr.adb (Analyze_Attribute, case 'Old): If prefix may be a
3177 discriminated component of an actual, expand at once to prevent
3178 ouf-of-order references with generated subtypes.
3179
31802011-08-31 Yannick Moy <moy@adacore.com>
3181
3182 * lib-xref-alfa.adb (Add_Alfa_Xrefs): Do not take into account read
3183 reference to operator in Alfa xrefs.
3184
31852011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3186
3187 * sem_ch12.adb (Freeze_Subprogram_Body): Add code to handle the case
3188 where the parent instance was frozen before the current instance due to
3189 the presence of a source body. Update calls to Insert_After_Last_Decl.
3190 (Insert_After_Last_Decl): Renamed to Insert_Freeze_Node_For_Instance.
3191 Update the comment which illustrates the purpose of the routine.
3192 Package instances are now frozen by source bodies which appear after
3193 the instance. This ensures that entities coming from within the
3194 instance are available for use in the said bodies.
3195 (Install_Body): Add code to handle the case where the parent instance
3196 was frozen before the current instance due to the presence of a source
3197 body. Update calls to Insert_After_Last_Decl.
3198
56812278
AC
31992011-08-31 Jose Ruiz <ruiz@adacore.com>
3200
3201 * s-taprop-linux.adb (Set_Task_Affinity): Avoid the use of anonymous
3202 access types.
3203 * affinity.c (__gnat_set_affinity_mask): Declare index variable.
3204
32052011-08-31 Yannick Moy <moy@adacore.com>
3206
3207 * sem_ch8.adb (Analyze_Subprogram_Renaming): Refine expander test in
3208 full-expander test.
16c3301a
AC
3209 * alfa.adb, alfa.ads, alfa_test.adb, ali.adb, debug.adb, errout.adb,
3210 errout.ads, erroutc.adb, expander.adb, exp_ch4.adb, exp_ch7.adb,
3211 freeze.adb, get_alfa.adb, get_alfa.ads, gnat1drv.adb, lib-writ.adb,
3212 lib-writ.ads, lib-xref.adb, lib-xref.ads, lib-xref-alfa.adb, opt.adb,
3213 opt.ads, put_alfa.adb, put_alfa.ads, restrict.adb, sem_ch12.adb,
3214 sem_ch13.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
3215 sem_prag.adb, sem_res.adb, sem_util.adb: Minor reformatting, renaming
3216 ALFA in Alfa (we dropped acronym).
56812278
AC
3217 * einfo.adb (Primitive_Operations): Correctly return list of primitive
3218 operations in a case where it returned previously No_Elist.
3219
7cda9727
RD
32202011-08-31 Robert Dewar <dewar@adacore.com>
3221
3222 * s-taprop-vxworks.adb, sem_ch5.adb, s-taprop-tru64.adb, exp_alfa.adb,
3223 s-taprop-vms.adb, bindgen.adb, s-mudido.adb, s-mudido.ads,
3224 sem_res.adb, expander.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
3225 s-taprop-solaris.adb, s-mudido-affinity.adb, vms_conv.adb,
3226 s-taprop-irix.adb, s-taprop.ads, s-taskin.adb, s-taskin.ads,
3227 s-taprop-hpux-dce.adb, a-chtgbo.adb, s-taprop-posix.adb: Minor
3228 reformatting.
3229
0a190dfd
AC
32302011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3231
3232 * sem_ch12 (Check_Private_View): Revert previous change.
3233 * sem_res.adb (Conversion_Check): Do not emit the error message if the
3234 conversion is in a generic instance.
3235
32362011-08-31 Matthew Heaney <heaney@adacore.com>
3237
3238 * a-cbhase.adb (Symmetric_Difference): Dereference correct node array.
3239 * a-chtgbo.adb (Free): Allow 0 as index value.
3240
32412011-08-31 Matthew Heaney <heaney@adacore.com>
3242
3243 * a-cborma.adb (Insert): Add comment to explain why no element
3244 assignment.
3245
32462011-08-31 Gary Dismukes <dismukes@adacore.com>
3247
3248 * sem_util.adb (Find_Body_Discriminal): Test whether the scope of the
3249 spec discriminant is already a concurrent type, in which case just use
3250 it, otherwise fetch the Corresponding_Concurrent_Type as before.
3251
7d266442
EB
32522011-08-30 Eric Botcazou <ebotcazou@adacore.com>
3253
3254 * system-irix-n64.ads, system-linux-armeb.ads, system-linux-armel.ads,
3255 system-linux-mips.ads, system-linux-mipsel.ads,
3256 system-linux-mips64el.ads, system-linux-ppc64.ads,
3257 system-linux-sparcv9.ads, system-rtems.ads: Remove GCC_ZCX_Support.
3258
4f1a975c
EB
32592011-08-30 Eric Botcazou <ebotcazou@adacore.com>
3260
3261 * gcc-interface/ada-tree.h (TYPE_EXTRA_SUBTYPE_P): Add internal check.
3262 * gcc-interface/utils2.c (build_binary_op): Tighten condition.
3263 (build_unary_op): Likewise.
3264
f2991b48
EB
32652011-08-30 Eric Botcazou <ebotcazou@adacore.com>
3266
3267 * raise-gcc.c: Do not include coretypes.h and tm.h.
3268 (setup_to_install): Remove test for compiler macro.
3269 * targext.c: Document use for the library.
3270 * gcc-interface/Makefile.in: Fix comment on the use of IN_GCC.
3271
10a22f43
EB
32722011-08-30 Eric Botcazou <ebotcazou@adacore.com>
3273
3274 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Do not convert
3275 the expression to the nominal type if the latter is a record type with
3276 a variant part and the type of the former is a record type without one.
3277
bfa2e39d
AC
32782011-08-30 Yannick Moy <moy@adacore.com>
3279
3280 * exp_aggr.adb, exp_ch11.adb, exp_prag.adb: Remove early exit during
3281 expansion in Alfa mode.
3282 * exp_ch6.adb, exp_ch6.ads (Expand_Actuals): Make subprogram public
3283 * exp_alfa.adb, exp_alfa.ads: New package defining light expansion for
3284 Alfa mode.
3285 * gnat1drv.adb (Adjust_Global_Switches): Update Comment.
3286 * sem_res.adb: Ditto.
bd34109a 3287 * gcc-interface/Make-lang.in: Update dependencies.
bfa2e39d
AC
3288
32892011-08-30 Thomas Quinot <quinot@adacore.com>
3290
3291 * g-socket.ads: Minor documentation adjustment.
3292
a0347839
AC
32932011-08-30 Robert Dewar <dewar@adacore.com>
3294
3295 * exp_ch9.adb, s-tassta.adb, s-secsta.adb: Minor reformatting.
3296
32972011-08-30 Yannick Moy <moy@adacore.com>
3298
3299 * exp_ch6_light.adb, exp_ch6_light.ads, exp_attr_light.adb,
3300 exp_attr_light.ads, exp_ch7_light.adb, exp_ch7_light.ads,
3301 exp_light.adb, exp_light.ads, exp_prag.adb, expander.adb,
3302 gnat1drv.adb, exp_ch11.adb, exp_ch6.adb, exp_ch6.ads, exp_aggr.adb:
3303 Revert change which introduced files for "light"
3304 expansion, to be replaced by a single file for Alfa expansion.
3305
3597c0e9
RD
33062011-08-30 Robert Dewar <dewar@adacore.com>
3307
3308 * opt.ads, s-soflin.adb, exp_ch9.adb, sem_res.adb: Update comment.
3309 Minor code reorg/reformatting.
3310
da94696d
AC
33112011-08-30 Yannick Moy <moy@adacore.com>
3312
3313 * opt.adb, opt.ads (Full_Expander_Active): New function defines a
3314 common shorthand for (Expander_Active and not ALFA_Mode) that can be
3315 used for testing full expansion, that is active expansion not in the
3316 reduced mode for Alfa
3317 * exp_ch4.adb, exp_ch9.adb, exp_disp.adb, sem_ch10.adb, sem_ch12.adb,
3318 sem_ch6.adb, sem_ch9.adb, sem_res.adb: Use newly defined "flag" instead
3319 of the verbose (Expander_Active and not ALFA_Mode)
3320
33212011-08-30 Tristan Gingold <gingold@adacore.com>
3322
3323 * s-parame-vms-alpha.ads, s-parame-hpux.ads, s-tassta.adb,
3324 s-tarest.adb, s-parame-vms-ia64.ads, s-soflin.adb, s-secsta.adb,
5b8ca141
TG
3325 s-secsta.ads, s-parame.ads, s-parame-vxworks.ads, s-parame-ae653.ads:
3326 Renames Ratio to Percentage, and Sec_Stack_Ratio to Sec_Stack_Percentage
da94696d 3327
c199ccf7
AC
33282011-08-30 Gary Dismukes <dismukes@adacore.com>
3329
3330 * sem_res.adb (Valid_Conversion): Revise test for implicit anonymous
3331 access conversions to check that the conversion is a rewritten node,
3332 rather than just having Comes_From_Source set to False, which wasn't
3333 sufficient.
3334
33352011-08-30 Robert Dewar <dewar@adacore.com>
3336
3337 * exp_ch9.adb, sem_ch9.adb, sem_ch6.adb, exp_disp.adb,
3338 g-socket.ads: Minor reformatting.
3339
33402011-08-30 Thomas Quinot <quinot@adacore.com>
3341
3342 * sem_util.adb: Minor reformatting.
3343
33442011-08-30 Tristan Gingold <gingold@adacore.com>
3345
3346 * raise-gcc.c: Never catch exception if _UA_FORCE_UNWIND flag is set,
3347 to be compliant with the ABI.
3348
dff99e1a
AC
33492011-08-30 Hristian Kirtchev <kirtchev@adacore.com>
3350
3351 * sem_ch12.adb (Check_Private_View): Exchange the private and full view
3352 of a designated type when the related access type is an actual in an
3353 instance. This ensures that the full view of designated type is
3354 available when inside the body of the instance.
3355
33562011-08-30 Ed Schonberg <schonberg@adacore.com>
3357
3358 * sem_util.adb (May_Be_Lvalue): To determine whether a reference may be
3359 in a position to be modified, a slice is treated like an indexed
3360 component.
3361
63be2a5a
AC
33622011-08-30 Thomas Quinot <quinot@adacore.com>
3363
3364 * s-oscons-tmplt.c, g-socket.ads: Adjust maximum allowed value for
3365 field tv_sec in struct timeval.
3366
33672011-08-30 Yannick Moy <moy@adacore.com>
3368
3369 * exp_ch9.adb, exp_disp.adb, sem_ch9.adb, sem_res.adb: Protect several
3370 blocks of code doing full expansion, previously only guarded by
3371 Expander_Active, by anding the test that ALFA_Mode is not set
3372
33732011-08-30 Ed Schonberg <schonberg@adacore.com>
3374
3375 * sem_ch6.adb (Analyze_Return_Type): If the return type is incomplete,
3376 add the function to the list of private dependents, for subsequent
3377 legality check on Taft amendment types.
3378 * sem_ch12.adb (Analyze_Formal_Incomplete_Type): Initialize
3379 Private_Dependents, as for other incomplete types.
3380 * sem_util.adb (Wrong_Type): Avoid cascaded errors when a
3381 Taft-amendment type is used as the return type of a function.
3382
dd54644b
JM
33832011-08-30 Javier Miranda <miranda@adacore.com>
3384
3385 * sem_ch3.adb (Check_Abstract_Overriding): Code cleanup: replace code
3386 which emits an error by a call to a new routine which report the error.
3387 * exp_ch9.adb (Build_Wrapper_Spec): Build the wrapper even if the
3388 entity does not cover an existing interface.
3389 * errout.ads, errout.adb (Error_Msg_PT): New routine. Used to factorize
3390 code.
3391 * sem_ch6.adb (Check_Conformance): Add specific error for wrappers of
3392 protected procedures or entries whose mode is not conformant.
3393 (Check_Synchronized_Overriding): Code cleanup: replace code which emits
3394 an error by a call to a new routine which report the error.
3395
d3ba478e
AC
33962011-08-30 Robert Dewar <dewar@adacore.com>
3397
3398 * gnat_rm.texi: Minor change.
3399 * exp_attr_light.adb: Minor reformatting.
3400
34012011-08-30 Ed Schonberg <schonberg@adacore.com>
3402
3403 * sem_ch3.adb: Patch inheritance of aspects in
3404 Complete_Private_Subtype, to avoid infinite loop.
3405
c01817d2
AC
34062011-08-30 Javier Miranda <miranda@adacore.com>
3407
3408 * sem_ch3.adb (Add_Internal_Interface_Entities): If serious errors have
3409 been reported and a subprogram covering an interface primitive is not
3410 found then skip generating the internal entity. Done to avoid crashing
3411 the frontend.
3412 (Check_Abstract_Overriding): Change text of error of wrong formal of
3413 protected subprogram or entry. Done for consistency to emit exactly the
3414 same error reported by Check_Synchronized_Overriding. In addition, the
3415 error is restricted to protected types (bug found working on AI05-0090)
3416
34172011-08-30 Yannick Moy <moy@adacore.com>
3418
3419 * exp_aggr.adb, exp_ch11.adb, exp_prag.adb: Remove early exit during
3420 expansion in Alfa mode.
3421 * exp_ch6.adb, exp_ch6.ads (Expand_Actuals): Make subprogram public.
3422 * exp_light.adb, exp_light.ads: New package defining light expansion.
3423 * expander.adb (Expand): Call light expansion in Alfa mode
3424 * exp_ch6_light.adb, exp_ch6_light.ads: Light expansion of chapter 6
3425 constructs.
3426 * exp_ch7_light.adb, exp_ch7_light.ads: Light expansion of chapter 7
3427 constructs.
3428 * exp_attr_light.adb, exp_attr_light.ads: Light expansion of attributes
3429 * gnat1drv.adb (Adjust_Global_Switches): Comment
3430
34312011-08-30 Yannick Moy <moy@adacore.com>
3432
3433 * lib-xref-alfa.adb: Minor refactoring.
3434
34352011-08-30 Yannick Moy <moy@adacore.com>
3436
3437 * exp_ch9.adb (Expand_Entry_Barrier): Do not perform expansion in Alfa
3438 mode.
3439 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Do not perform
3440 expansion in Alfa mode.
3441 * sem_ch9.adb (Analyze_Entry_Body): Do not perform expansion in Alfa
3442 mode.
3443
34442011-08-30 Robert Dewar <dewar@adacore.com>
3445
3446 * debug_a.adb: Update comment.
3447
996c8821
RD
34482011-08-30 Robert Dewar <dewar@adacore.com>
3449
3450 * exp_ch5.adb, sem_ch3.adb, sem_ch5.adb, einfo.adb, checks.adb,
3451 sem_util.adb, sem_util.ads, sem_res.adb, s-stposu.adb, sem_attr.adb,
3452 exp_ch4.adb, exp_ch6.adb, lib-xref-alfa.adb,
3453 sem_ch8.adb, sem_disp.adb, exp_ch3.adb: Minor reformatting
3454
34552011-08-30 Robert Dewar <dewar@adacore.com>
3456
3457 * gnat_rm.texi: Add section on C.6(16) implementation advice for pragma
3458 volatile.
3459
3647ca26
HK
34602011-08-30 Hristian Kirtchev <kirtchev@adacore.com>
3461
3462 * exp_ch3.adb (Expand_Freeze_Array_Type): Correct the call to
3463 Build_Finalization_Master by supplying an insertion node and enclosing
3464 scope. In its old version, the call did not generate a finalization
3465 master.
3466 (Expand_Freeze_Record_Type): Add local variable Has_AACC. Add code to
3467 recognize anonymous access-to-controlled components. Rewrite the
3468 machinery which creates finalization masters to service anonymous
3469 access-to-controlled components of a record type. In its current state,
3470 only one heterogeneous master is necessary to handle multiple anonymous
3471 components.
3472 (Freeze_Type): Comment reformatting.
3473 * rtsfind.ads: Add RE_Set_Is_Heterogeneous to tables RE_Id and
3474 RE_Unit_Table.
3475 * s-stposu.adb (Allocate_Any_Controlled): Rewrite the machinery which
3476 associates TSS primitive Finalize_Address with either the master itself
3477 or with the internal hash table depending on the mode of operation of
3478 the master.
3479
6d4e4fbc
JM
34802011-08-30 Javier Miranda <miranda@adacore.com>
3481
3482 * exp_ch3.adb (Make_Eq_If): If the etype of the _parent component is an
3483 interface type then do not generate code to compare this component.
3484 Required since they have no components and their equality operator is
3485 abstract.
3486
d15f9422
AC
34872011-08-30 Steve Baird <baird@adacore.com>
3488
3489 * sem_util.ads (Deepest_Type_Access_Level): New function; for the type
3490 of a saooaaat (i.e, a stand-alone object of an anonymous access type),
3491 returns the (static) accessibility level of the object. Otherwise, the
3492 same as Type_Access_Level.
3493 (Dynamic_Accessibility_Level): New function; given an expression which
3494 could occur as the rhs of an assignment to a saooaaat (i.e., an
3495 expression of an access-to-object type), return the new value for the
3496 saooaaat's associated Extra_Accessibility object.
3497 (Effective_Extra_Accessibility): New function; same as
3498 Einfo.Extra_Accessibility except that object renames are looked through.
3499 * sem_util.adb
3500 (Deepest_Type_Access_Level): New function; see sem_util.ads description.
3501 (Dynamic_Accessibility_Level): New function; see sem_util.ads
3502 description.
3503 (Effective_Extra_Accessibility): New function; see sem_util.ads
3504 description.
3505 * einfo.ads (Is_Local_Anonymous_Access): Update comments.
3506 (Extra_Accessibility): Update comments.
3507 (Init_Object_Size_Align): New procedure; same as Init_Size_Align
3508 except RM_Size field (which is only for types) is unaffected.
3509 * einfo.adb
3510 (Extra_Accessibility): Expand domain to allow objects, not just formals.
3511 (Set_Extra_Accessibility): Expand domain to allow objects, not just
3512 formals.
3513 (Init_Size): Add assertion that we are not trashing the
3514 Extra_Accessibility attribute of an object.
3515 (Init_Size_Align): Add assertion that we are not trashing the
3516 Extra_Accessibility attribute of an object.
3517 (Init_Object_Size_Align): New procedure; see einfo.ads description.
3518 * sem_ch3.adb (Find_Type_Of_Object): Set Is_Local_Anonymous_Access
3519 differently for the type of a (non-library-level) saooaaat depending
3520 whether Ada_Version < Ada_2012. This is the only point where Ada_Version
3521 is queried in this set of changes - everything else (in particular,
3522 setting of the Extra_Accessibility attribute in exp_ch3.adb) is
3523 driven off of the setting of the Is_Local_Anonymous_Access attribute.
3524 The special treatment of library-level saooaaats is an optimization,
3525 not required for correctnesss. This is based on the observation that the
3526 Ada2012 rules (static and dynamic) for saooaaats turn out to be
3527 equivalent to the Ada2005 rules in the case of a library-level saooaaat.
3528 * exp_ch3.adb
3529 (Expand_N_Object_Declaration): If Is_Local_Anonymous_Access is
3530 false for the type of a saooaaat, declare and initialize its
3531 accessibility level object and set the Extra_Accessibility attribute
3532 of the saooaaat to refer to this object.
3533 * checks.adb (Apply_Accessibility_Check): Add Ada 2012 saooaaat support.
3534 * exp_ch4.adb (Expand_N_In): Replace some Extra_Accessibility calls with
3535 calls to Effective_Extra_Accessibility in order to support
3536 renames of saooaaats.
3537 (Expand_N_Type_Conversion): Add new local function,
3538 Has_Extra_Accessibility, and call it when determining whether an
3539 accessibility check is needed.
3540 It returns True iff Present (Effective_Extra_Accessibility (Id)) would
3541 evaluate to True (without raising an exception).
3542 * exp_ch5.adb
3543 (Expand_N_Assignment_Statement): When assigning to an Ada2012
3544 saooaaat, update its associated Extra_Accessibility object (if
3545 it has one). This includes an accessibility check.
3546 * exp_ch6.adb (Add_Call_By_Copy_Code): When parameter copy-back updates
3547 a saooaaat, update its Extra_Accessibility object too (if it
3548 has one).
3549 (Expand_Call): Replace a couple of calls to Type_Access_Level
3550 with calls to Dynamic_Access_Level to handle cases where
3551 passing a literal (any literal) is incorrect.
3552 * sem_attr.adb (Resolve_Attribute): Handle the static accessibility
3553 checks associated with "Saooaat := Some_Object'Access;"; this must
3554 be rejected if Some_Object is declared in a more nested scope
3555 than Saooaat.
3556 * sem_ch5.adb (Analyze_Assignment): Force accessibility checking for an
3557 assignment to a saooaaat even if Is_Local_Anonymous_Access
3558 returns False for its type (indicating a 2012-style saooaaat).
3559 * sem_ch8.adb
3560 (Analyze_Object_Renaming): Replace a call to Init_Size_Align
3561 (which is only appropriate for objects, not types) with a call
3562 of Init_Object_Size_Align in order to avoid trashing the
3563 Extra_Accessibility attribute of a rename (the two attributes
3564 share storage).
3565 * sem_res.adb
3566 (Valid_Conversion) Replace six calls to Type_Access_Level with
3567 calls to Deepest_Type_Access_Level. This is a bit tricky. For an
3568 Ada2012 non-library-level saooaaat, the former returns library level
3569 while the latter returns the (static) accessibility level of the
3570 saooaaat. A type conversion to the anonymous type of a saooaaat
3571 can only occur as part of an assignment to the saooaaat, so we
3572 know that such a conversion must be in a lhs context, so Deepest
3573 yields the result that we need. If such a conversion could occur,
3574 say, as the operand of an equality operator, then this might not
3575 be right. Also add a test so that static accessibilty checks are
3576 performed for converting to a saooaaat's type even if
3577 Is_Local_Anonymous_Access yields False for the type.
3578
35792011-08-30 Javier Miranda <miranda@adacore.com>
3580
3581 * sem_disp.adb (Check_Dispatching_Operation): Complete condition that
3582 controls generation of a warning associated with late declaration of
3583 dispatching functions. Required to avoid generating spurious
3584 warnings.
3585
6cce2156
GD
35862011-08-30 Gary Dismukes <dismukes@adacore.com>
3587
3588 * sem_ch6.adb (Check_Return_Subtype_Indication): Issue error if the
3589 return object has an anonymous access type and the function's type is
3590 a named access type.
3591 * sem_ch8.adb (Analyze_Object_Renaming): Suppress error about renaming
3592 conversions on implicit conversions, since such conversions can occur
3593 for anonymous access cases due to expansion. Issue error for attempt
3594 to rename an anonymous expression as an object of a named access type.
3595 * sem_res.ads (Valid_Conversion): Add defaulted parameter Report_Errs,
3596 to indicate whether this function should report errors on invalid
3597 conversions.
3598 * sem_res.adb (Resolve): For Ada 2012, in the case where the type of
3599 the expression is of an anonymous access type and the expected type is
3600 a named general access type, rewrite the expression as a type
3601 conversion, unless this is an expression of a membership test.
3602 (Valid_Conversion.Error_Msg_N): New procedure that conditions the
3603 calling of Error_Msg_N on new formal Report_Errs.
3604 (Valid_Conversion.Error_Msg_NE): New procedure that conditions the
3605 calling of Error_Msg_NE on new formal Report_Errs.
3606 (Valid_Conversion): Move declaration of this function to the package
3607 spec, to allow calls from membership test processing. For Ada 2012,
3608 enforce legality restrictions on implicit conversions of anonymous
3609 access values to general access types, disallowing such conversions in
3610 cases where the expression has a dynamic accessibility level (access
3611 parameters, stand-alone anonymous access objects, or a component of a
3612 dereference of one of the first two cases).
3613 * sem_type.adb (Covers): For Ada 2012, allow an anonymous access type
3614 in the context of a named general access expected type.
3615 * exp_ch4.adb Add with and use of Exp_Ch2.
3616 (Expand_N_In): Add processing for membership tests applied to
3617 expressions of an anonymous access type. First, Valid_Conversion is
3618 called to check whether the test is statically False, and then the
3619 conversion is expanded to test that the expression's accessibility
3620 level is no deeper than that of the tested type. In the case of
3621 anonymous access-to-tagged types, a tagged membership test is applied
3622 as well.
3623 (Tagged_Membership): Extend to handle access type cases, applying the
3624 test to the designated types.
3625 * exp_ch6.adb (Expand_Call): When creating an extra actual for an
3626 accessibility level, and the actual is a 'Access applied to a current
3627 instance, pass the accessibility level of the type of the current
3628 instance rather than applying Object_Access_Level to the prefix. Add a
3629 ??? comment, since this level isn't quite right either (will eventually
3630 need to pass an implicit level parameter to init procs).
3631
747de90b
AC
36322011-08-30 Bob Duff <duff@adacore.com>
3633
3634 * s-taskin.ads: Minor comment fix.
3635
36362011-08-30 Ed Schonberg <schonberg@adacore.com>
3637
3638 * sem_res.adb (Check_Parameterless_Call): If the node is a selected
3639 component and the selector is a dispatching operation, check if it is
3640 a prefixed call before rewriting as a parameterless function call.
3641
cdc4cc65
JJ
36422011-08-29 Jakub Jelinek <jakub@redhat.com>
3643
3644 * gcc-interface/Makefile.in (../stamp-gnatlib1-$(RTSDIR)): Copy
3645 tsystem.h into $(RTSDIR) instead of rts.
3646
226a7fa4
AC
36472011-08-29 Robert Dewar <dewar@adacore.com>
3648
3649 * sem_ch10.adb, a-coorse.adb, exp_dist.adb, exp_ch3.adb: Minor
3650 reformatting.
3651 * gcc-interface/Make-lang.in: Update dependencies.
3652
36532011-08-29 Yannick Moy <moy@adacore.com>
3654
3655 * alfa.ads (Name_Of_Heap_Variable): New constant name.
3656 * lib-xref-alfa.adb, lib-xref.adb, lib-xref.ads (Drefs): New global
3657 table to hold dereferences.
3658 (Add_ALFA_Xrefs): Take into account dereferences as special
3659 reads/writes to the variable "HEAP".
3660 (Enclosing_Subprogram_Or_Package): Move subprogram here.
3661 (Generate_Dereference): New procedure to store a read/write dereferencew
3662 in the table Drefs.
3663 * put_alfa.adb (Put_ALFA): Use different default than (0,0) used for
3664 the special "HEAP" var.
3665 * sem_ch4.adb (Analyze_Explicit_Dereference): Store read dereference
3666 in ALFA mode.
3667 * sem_util.adb (Note_Possible_Modification): Store write dereference
3668 in ALFA mode.
3669
dfbcb149
HK
36702011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
3671
3672 * exp_ch3.adb (Freeze_Type): Generate an accessibility check which
3673 ensures that the level of the subpool access type is not deeper than
3674 that of the pool object.
3675 * sem_util.adb (Object_Access_Level): Expand to handle defining
3676 identifiers.
3677 * sem_res.adb (Resolve_Allocator): Add a guard to avoid examining the
3678 subpool handle name of a rewritten allocator.
3679
1df4f514
AC
36802011-08-29 Robert Dewar <dewar@adacore.com>
3681
3682 * impunit.adb, exp_ch4.adb, s-finmas.adb: Minor reformatting.
3683
36842011-08-29 Thomas Quinot <quinot@adacore.com>
3685
3686 * exp_dist.adb (TC_Rec_Add_Process_Element): For a choice with multiple
3687 values, we generate multiple triples of parameters in the TypeCode.
3688 Bump Choice_Index for each such triple so that a subsequent default
3689 choice is associated with the correct index in the typecode.
3690
36912011-08-29 Ed Schonberg <schonberg@adacore.com>
3692
3693 * a-cdlili.adb (Iterate): Initialize properly an iterator over a null
3694 container.
3695 (First, Last): Handle properly an iterator over a null container.
3696
36972011-08-29 Bob Duff <duff@adacore.com>
3698
3699 * sem_ch10.adb (Analyze_With_Clause,Install_Withed_Unit): Abandon
3700 processing if we run across a node with no Scope. This can happen if
3701 we're with-ing an library-level instance, and that instance got errors
3702 that caused "instantiation abandoned".
3703 * sem_util.adb (Unit_Declaration_Node): Make it more robust, by raising
3704 an exception instead of using Assert, so it won't go into an infinite
3705 loop, even when assertions are turned off.
3706
37072011-08-29 Ed Schonberg <schonberg@adacore.com>
3708
3709 * a-coorse.adb: Proper handling of empty ordered sets.
3710
14f0f659
AC
37112011-08-29 Johannes Kanig <kanig@adacore.com>
3712
3713 * debug.adb: Add comments.
3714
8027b455
AC
37152011-08-29 Thomas Quinot <quinot@adacore.com>
3716
3717 * a-except.adb, a-except-2005.adb: Minor comment rewording and
3718 reformatting.
3719
37202011-08-29 Yannick Moy <moy@adacore.com>
3721
3722 * sem_ch3.adb (Array_Type_Declaration): Remove insertion of
3723 declaration for Itypes in Alfa mode.
3724
d85fd922
AC
37252011-08-29 Robert Dewar <dewar@adacore.com>
3726
3727 * a-cdlili.ads, a-coinve.ads, a-coorma.adb, a-coorma.ads, s-tassta.adb,
3728 a-cborma.adb, a-cborma.ads, a-cohama.ads, a-coorse.ads, a-cbhama.ads,
3729 a-cborse.ads, a-cobove.adb, a-cobove.ads, a-cbhase.ads: Minor
3730 reformatting.
3731
37322011-08-29 Tristan Gingold <gingold@adacore.com>
3733
3734 * exp_ch7.adb, exp_ch7.ads (Build_Exception_Handler): Move its spec to
3735 package spec.
3736 * exp_intr.adb (Expand_Unc_Deallocation): Use Build_Exception_Handler.
3737 * a-except.adb, a-except-2005.adb (Rcheck_22): Do not defer aborts
3738 while raising PE.
3739
fd3d2680
AC
37402011-08-29 Robert Dewar <dewar@adacore.com>
3741
3742 * a-cbhama.adb, a-cbhama.ads: Minor reformatting.
3743
37442011-08-29 Javier Miranda <miranda@adacore.com>
3745
3746 * sem_ch8.adb (Analyze_Subprogram_Renaming): Complete support for
3747 renamings of formal subprograms when the actual for a formal type is
3748 class-wide.
3749
dfbf013f
MH
37502011-08-29 Matthew Heaney <heaney@adacore.com>
3751
3752 * a-cbhama.ads, a-cbhase.ads (Move): Clear Source following assignment
3753 to Target.
3754
37552011-08-29 Matthew Heaney <heaney@adacore.com>
3756
3757 * a-cborma.ads, a-cborse.ads (Cursor): Default-initialize all
3758 components of record type.
3759 * a-cborma.adb, a-cborse.adb (Move): Clear Source following assignmentw
3760 to Target.
3761
a6dd3a54
ES
37622011-08-29 Ed Schonberg <schonberg@adacore.com>
3763
3764 * a-cbhama.adb, a-cbhama.ads, a-cborma.adb, a-cborma.ads, a-cobove.adb,
3765 a-cobove.ads, a-coorma.adb, a-coorma.ads: Add iterator machinery to
3766 container packages.
3767
c54796e0
AC
37682011-08-29 Robert Dewar <dewar@adacore.com>
3769
3770 * sem_ch3.adb, sem_util.adb, gnat1drv.adb, s-parint.ads: Minor
3771 reformatting.
3772
37732011-08-29 Matthew Heaney <heaney@adacore.com>
3774
3775 * a-cbhama.ads, a-cbhase.ads (Cursor): Default-initialize all
3776 components of record type.
3777
37782011-08-29 Bob Duff <duff@adacore.com>
3779
3780 * s-tassta.adb (Task_Wrapper): Handle and ignore exceptions propagated
3781 by the termination handler.
3782
9fd9d2be
AC
37832011-08-29 Yannick Moy <moy@adacore.com>
3784
3785 * sem_ch3.adb (Array_Type_Declaration): Create declarations for Itypes
3786 created in Alfa mode, instead of inserting artificial declarations of
3787 non-Itypes in the tree.
3788 * sem_util.adb, sem_util.ads (Itype_Has_Declaration): New function to
3789 know if an Itype has a corresponding declaration, as defined in
3790 itypes.ads.
3791
37922011-08-29 Yannick Moy <moy@adacore.com>
3793
3794 * gnat1drv.adb: Minor rewrite.
3795
37962011-08-29 Bob Duff <duff@adacore.com>
3797
3798 * s-tasuti.adb (Make_Passive): Work around race condition in
3799 Make_Independent, which can cause Wait_Count to be zero. So instead of
3800 asserting that Wait_Count > 0, and then decrementing it, decrement it
3801 only if Wait_Count > 0.
3802 * s-taskin.ads (Wait_Count, Alive_Count, Awake_Count): All of these
3803 should be nonnegative, so declare them Natural instead of Integer.
3804
833eaa8a
AC
38052011-08-29 Robert Dewar <dewar@adacore.com>
3806
3807 * exp_ch5.adb, sem_ch3.adb, a-cihama.adb, a-cihama.ads, exp_ch7.adb,
3808 sem_ch5.adb, a-ciorse.adb, a-ciorse.ads, sem_ch12.adb, a-cidlli.adb,
3809 a-cidlli.ads, sem_util.adb, sem_res.adb, gnat1drv.adb, a-except.adb,
3810 a-except.ads, a-except-2005.ads, sem_ch4.adb, exp_disp.adb,
3811 exp_aggr.adb, sem_ch13.adb, par-ch3.adb: Minor reformatting.
3812
38132011-08-29 Tristan Gingold <gingold@adacore.com>
3814
3815 * s-auxdec-vms-alpha.adb: Add comments, remove some HT before labels.
3816
38172011-08-29 Vadim Godunko <godunko@adacore.com>
3818
3819 * s-parint.ads: Minor comment clarification.
3820
38212011-08-29 Vincent Celier <celier@adacore.com>
3822
3823 * prj.adb (Initialize): Make sure that new reserved words after Ada 95
3824 may be used as identifiers.
3825
38262011-08-29 Ed Schonberg <schonberg@adacore.com>
3827
3828 * a-coinho.ads: Minor reformating.
3829
3a613a36
AC
38302011-08-29 Ed Schonberg <schonberg@adacore.com>
3831
3832 * exp_ch5.adb (Expand_Iterator_Loop): Handle properly a loop over a
3833 container of a derived type.
3834
3a613a36
AC
38352011-08-29 Ed Schonberg <schonberg@adacore.com>
3836
3837 * a-cidlli.adb, a-cidlli.ads, a-cihama.adb, a-cihama.ads,
3838 a-ciorse.adb, a-ciorse.ads: Add iterator machinery to containers.
3839
14848f57
AC
38402011-08-29 Pascal Obry <obry@adacore.com>
3841
3842 * exp_disp.adb: Minor comment fix.
3843 (Make_Disp_Asynchronous_Select_Body): Properly initialize out parameters
3844 to avoid warnings when compiling with -Wall.
3845 (Make_Disp_Conditional_Select_Body): Likewise.
3846 (Make_Disp_Timed_Select_Body): Likewise.
3847
38482011-08-29 Ed Schonberg <schonberg@adacore.com>
3849
3850 * sem_ch12.adb (Analyze_Formal_Subprogram_Declaration): If default is
3851 an entity name, generate reference for it.
3852
38532011-08-29 Ed Schonberg <schonberg@adacore.com>
3854
3855 * exp_ch5.adb (Expand_Iterator_Loop): Uniform handling of "X of S"
3856 iterator form.
3857 * sem_util.adb (Is_Iterator, Is_Reversible_Iterator): Yield True for
3858 the class-wide type.
3859 * sem_ch5.adb: Move some rewriting to the expander, where it belongs.
3860
38612011-08-29 Ed Schonberg <schonberg@adacore.com>
3862
3863 * sem_ch8.adb (Check_Constrained_Object): Do not create an actual
3864 subtype for an object whose type is an unconstrained union.
3865
38662011-08-29 Ed Schonberg <schonberg@adacore.com>
3867
3868 * par-ch3.adb (P_Array_Type_Definiation, P_Component_Items): "aliased"
3869 is allowed in a component definition, by AI95-406.
3870
38712011-08-29 Matthew Heaney <heaney@adacore.com>
3872
3873 * a-chtgbo.adb (Generic_Iteration): Use correct overloading of Next.
3874
38752011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
3876
3877 * a-except-2005.adb: Alphabetize all routines.
3878 (Triggered_By_Abort): New routine.
3879 * a-except-2005.ads (Triggered_By_Abort): New routine.
3880 * a-except.adb Alphabetize all routines.
3881 (Triggered_By_Abort): New routine.
3882 * a-except.ads (Triggered_By_Abort): New routine.
3883 * exp_ch7.adb: Update all comments involving the detection of aborts in
3884 finalization code.
3885 (Build_Object_Declarations): Do not generate code to detect the
3886 presence of an abort at the start of finalization code, use a runtime
3887 routine istead.
3888 * rtsfind.ads: Add RE_Triggered_By_Abort to tables RE_Id and
3889 RE_Unit_Table.
3890 * sem_res.adb (Resolve_Allocator): Emit a warning when attempting to
3891 allocate a task on a subpool.
3892 * s-stposu.adb: Add library-level flag Finalize_Address_Table_In_Use.
3893 The flag disables all actions related to the maintenance of
3894 Finalize_Address_Table when subpools are not in use.
3895 (Allocate_Any_Controlled): Signal the machinery that subpools are in
3896 use.
3897 (Deallocate_Any_Controlled): Do not call Delete_Finalize_Address which
3898 performs costly task locking when subpools are not in use.
3899
57a8057a
AC
39002011-08-29 Yannick Moy <moy@adacore.com>
3901
3902 * gnat1drv.adb (Adjust_Global_Switches): Restore expansion of tagged
3903 types and dispatching calls in Alfa mode.
3904 * lib-xref-alfa.adb (Collect_ALFA): Rewrite computation of
3905 correspondance between body and spec scopes, to reuse utility functions
3906 (Traverse_Declarations_Or_Statements): Protect access to body for stub
3907 by testing the presence of the library unit for the body
3908 * sem_ch6.adb (Set_Actual_Subtypes): take into account that in Alfa
3909 mode the expansion of accept statements is skipped
3910 * sem_util.adb, sem_util.ads (Unique_Entity): New function returning
3911 the unique entity corresponding to the one returned by
3912 Unique_Defining_Entity applied to the enclosing declaration of the
3913 argument.
3914
39152011-08-29 Bob Duff <duff@adacore.com>
3916
3917 * treepr.ads: Improve debugging facilities. pn(x) no longer crashes in
3918 gdb when x is not a node (it can be a node list, name_id, etc). pp is
3919 an alias for pn. ppp is an alias for pt.
3920
39212011-08-29 Javier Miranda <miranda@adacore.com>
3922
3923 * exp_aggr.adb (Expand_Record_Aggregate): Use the top-level enclosing
3924 aggregate to take a consistent decision on the need to convert into
3925 assignments aggregates that initialize constant objects.
3926
39272011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
3928
3929 * exp_ch4.adb (Expand_Allocator_Expression): Add a call to
3930 Build_Allocate_Deallocate_Proc in order to handle allocation of
3931 non-controlled objects on subpools.
3932 * impunit.adb: Remove s-finmas and s-spsufi since they were never meant
3933 to be end-user visible.
3934 * s-finmas.adb: Add with and use clause for System.HTable.
3935 Add an instantiation of Simple_HTable which provides a mapping between
3936 the address of a controlled object and the corresponding
3937 Finalize_Address used to clean up the object. The table is used when a
3938 master is operating in heterogeneous mode.
3939 (Attach): Explain why the input node is not verified on being already
3940 attached.
3941 (Delete_Finalize_Address): New routine.
3942 (Detach): Add pragma Assert which ensures that a node is already
3943 attached.
3944 (Finalize): Add local variable Cleanup. Rewrite the iteration scheme
3945 since nodes are no longer removed on traversal. Explain why node
3946 detachment is undesirable in this case.
3947 (Get_Finalize_Address): New routine.
3948 (Hash): New routine.
3949 (Is_Empty_List): Removed.
3950 (pm): Renamed to Print_Master. Add output for discriminant
3951 Is_Homogeneous.
3952 Comment reformatting.
3953 (Set_Finalize_Address (Address, Finalize_Address_Ptr)): New routine.
3954 * s-finmas.ads: Various comments additions / improvements.
3955 Type Finalization_Master has a discriminant which determines the mode of
3956 operation.
3957 (Delete_Finalize_Address): New routine.
3958 (Get_Finalize_Address): New routine.
3959 (pm): Renamed to Print_Master.
3960 (Set_Finalize_Address (Address, Finalize_Address_Ptr)): New routine.
3961 * s-stposu.adb: Add with clause for System.Address_Image; Add with and
3962 use clause for System.IO.
3963 (Allocate_Any_Controlled): Add machinery to set TSS primitive
3964 Finalize_Address depending on the mode of allocation and the mode of
3965 the master.
3966 (Deallocate_Any_Controlled): Remove the relation pair object -
3967 Finalize_Address regardless of the master mode. Add comment explaining
3968 the reason.
3969 (Detach): Ensure that fields Prev and Next are null after detachment.
3970 (Finalize_Pool): Remove local variable Next_Ptr. Rewrite the iteration
3971 scheme to check whether the list of subpools is empty. There is no
3972 longer need to store the next subpool or advance the current pointer.
3973 (Is_Empty_List): New routine.
3974 (Print_Pool): New routine.
3975 (Print_Subpool): New routine.
3976 * s-stposu.ads: Various comments additions / improvements.
3977 Field Master of type Root_Subpool is now a heterogeneous collection.
3978 (Print_Pool): New routine.
3979 (Print_Subpool): New routine.
3980
39812011-08-29 Ed Schonberg <schonberg@adacore.com>
3982
3983 * exp_ch5.adb (Expand_N_Iterator_Loop): Implement Ada2012 loop iterator
3984 forms, using aspects of container types.
3985 * sem_ch3.adb (Find_Type_Name): Preserve Has_Delayed_Aspects and
3986 Has_Implicit_Dereference flags, that may be set on the partial view.
3987 * sem_ch4.adb (Process_Overloaded_Indexed_Component): Prefix may be a
3988 container type with an indexing aspect.
3989 (Analyze_Quantified_Expression): Analyze construct with expansion
3990 disabled, because it will be rewritten as a loop during expansion.
3991 (Try_Container_Indexing): The prefix itself may be a container type
3992 with an indexing aspect, as with a vector of vectors.
3993 * sem_ch5.adb (Analyze_Iteration_Scheme): In a generic context, analyze
3994 the original doamin of iteration, for name capture.
3995 (Analyze_Iterator_Specification): If the domain is an expression that
3996 needs finalization, create a separate declaration for it.
3997 For an iterator with "of" retrieve default iterator info from aspect of
3998 container type. For "in" iterator, retrieve type of Iterate function.
3999 * sem_ch13.adb (Check_Iterator_Function): Fix typo.
4000 (Check_Aspect_At_End_Of_Declaration): Make type unfrozen before
4001 analysis, to prevent spurious errors about late attributes.
4002 * sprint.adb: Handle quantified expression with either loop or iterator
4003 specification.
4004 * a-convec.ads, a-convec.adb: Iterate function returns a reversible
4005 iterator.
4006
ddf67a1d
AC
40072011-08-29 Vincent Celier <celier@adacore.com>
4008
4009 * make.adb (Scan_Make_Arg): Take any option as is in packages Compiler,
4010 Binder or Linker of the main project file.
4011
40122011-08-29 Ed Schonberg <schonberg@adacore.com>
4013
4014 * inline.adb (Add_Scopes_To_Clean): Exclude any entity within a generic
4015 unit.
4016
40172011-08-29 Yannick Moy <moy@adacore.com>
4018
4019 * exp_ch9.adb: Partial revert of previous change for Alfa mode
4020
40212011-08-29 Yannick Moy <moy@adacore.com>
4022
4023 * exp_ch11.adb: Minor expansion of comment.
4024
40252011-08-29 Yannick Moy <moy@adacore.com>
4026
4027 * lib-xref-alfa.adb (Add_ALFA_Scope): Treat generic entities.
4028
40292011-08-29 Ed Schonberg <schonberg@adacore.com>
4030
4031 * sem_res.adb (Resolve_Arithmetic_Op): If the node has a universal
4032 interpretation, set the type before resolving the operands, because
4033 legality checks on an exponention operand need to know the type of the
4034 context.
4035
40362011-08-29 Ed Schonberg <schonberg@adacore.com>
4037
4038 * sem_ch12.adb (Analyze_Package_Instantiation): Do not set delayed
4039 cleanups on a master if the instance is within a generic unit.
4040 Complement to the corresponding fix to inline.adb for K520-030.
4041
40422011-08-29 Tristan Gingold <gingold@adacore.com>
4043
4044 * exp_ch7.adb (Build_Raise_Statement): Raise PE instead of the current
4045 occurrence.
4046 * exp_intr.adb: Minor comment fix.
4047
40482011-08-29 Bob Duff <duff@adacore.com>
4049
4050 * sem_ch13.adb (Analyze_Aspect_Specifications): Fix cases where
4051 Delay_Required was used as an uninitialized variable.
4052
690943fc
RD
40532011-08-29 Robert Dewar <dewar@adacore.com>
4054
4055 * a-cdlili.adb, a-cdlili.ads, a-coinve.adb, a-coinve.ads,
4056 sem_util.adb, sem_util.ads, a-cohama.adb, a-cohama.ads, a-coorse.adb,
4057 a-coorse.ads, aspects.ads, sem_ch8.adb: Minor reformatting.
4058
9f0ee988
TQ
40592011-08-29 Thomas Quinot <quinot@adacore.com>
4060
4061 * system-freebsd-x86_64.ads (Backend_Overflow_Checks): Set true True.
4062 Remove unused variables.
4063
3e24afaa
AC
40642011-08-29 Ed Schonberg <schonberg@adacore.com>
4065
4066 * sem_res.adb: Remove Build_Explicit_Dereference.
4067 * sem_util.adb, sem_util.ads (Build_Explicit_Dereference): Moved here
4068 from sem_res.adb, used in analysis of additional constructs.
4069 (Is_Iterator, Is_Reversible_Iterator): New predicates for Ada2012
4070 expansion of iterators.
4071 (Is_Object_Reference): Recognize variables rewritten as explicit
4072 dereferences in Ada2012.
4073 * snames.ads-tmpl: Add Has_Element, Forward_Iterator,
4074 Reversible_Iterator names, for expansion of Ada2012 iterators.
4075 * aspects.ads, aspects.adb (Find_Aspect): Utility.
4076 * a-cdlili.ads, a-cdlili.adb: Add new iterator machinery to doubly
4077 linked list container.
4078 * a-coinve.ads, a-coinve.adb: Ditto for indefinite vector containers.
4079 * a-coorse.ads, a-coorse.adb: Ditto for ordered sets.
4080
40812011-08-29 Ed Schonberg <schonberg@adacore.com>
4082
4083 * a-cohama.adb, a-cohama.ads: Add iterator primitives to hashed map
4084 containers.
4085
40862011-08-29 Vincent Celier <celier@adacore.com>
4087
4088 * make.adb (Gnatmake): Get the maximum number of simultaneous
4089 compilation processes after the Builder switches has been scanned, as
4090 there may include -jnn.
4091
40922011-08-29 Matthew Heaney <heaney@adacore.com>
4093
4094 * a-chtgbo.adb (Generic_Equal): Use correct overloading of Next.
4095
40962011-08-29 Tristan Gingold <gingold@adacore.com>
4097
4098 * gnatcmd.adb (GNATCmd): On OpenVMS, truncate the length of
4099 GNAT_DRIVER_COMMAND_LINE to 255.
4100
41012011-08-29 Pascal Obry <obry@adacore.com>
4102
4103 * freeze.adb, sem_ch8.adb, a-convec.adb, a-convec.ads: Minor
4104 reformatting and style fix (class attribute casing).
4105
41062011-08-29 Yannick Moy <moy@adacore.com>
4107
4108 * exp_ch11.adb: Yet another case where expansion should be common
4109 between CodePeer and Alfa.
4110
41112011-08-29 Yannick Moy <moy@adacore.com>
4112
4113 * exp_ch9.adb: Partial revert of previous change for Alfa mode.
4114
41152011-08-29 Ed Schonberg <schonberg@adacore.com>
4116
4117 * sem_ch6.adb (Matches_Limited_With_View): The limited views of an
4118 incomplete type and its completion match.
4119
3ddd922e
AC
41202011-08-29 Yannick Moy <moy@adacore.com>
4121
4122 * exp_ch13.adb: Adjust previous change.
4123
41242011-08-29 Robert Dewar <dewar@adacore.com>
4125
4126 * sem_prag.adb, prj.adb, sem_util.adb, sem_res.adb, gnat1drv.adb,
4127 exp_ch4.adb, sem_ch8.adb: Minor code reorganization
4128 Minor reformatting.
4129
444acbdd
AC
41302011-08-29 Emmanuel Briot <briot@adacore.com>
4131
4132 * make.adb, prj.adb, prj.ads (Compute_All_Imported_Projects): Also
4133 initialize aggregated projects.
4134
41352011-08-29 Ed Schonberg <schonberg@adacore.com>
4136
4137 * sem_ch8.adb (Find_Renamed_Entity): Within an instance, use scope
4138 depth of candidates to resolve a potentially spurious ambiguity between
4139 two visible subprograms.
4140
e0296583
AC
41412011-08-29 Yannick Moy <moy@adacore.com>
4142
4143 * sem_prag.adb (Analyze_Pragma): Allow Test_Case pragma without
4144 Requires/Ensures.
4145 * sem_util.adb (Get_Ensures_From_Test_Case_Pragma,
4146 Get_Requires_From_Test_Case_Pragma): Allow Test_Case pragma without
4147 Requires/Ensures.
4148
41492011-08-29 Arnaud Charlet <charlet@adacore.com>
4150
4151 * gnat1drv.adb (Adjust_Global_Switches): Improve previous change.
4152 Add comment.
4153
41542011-08-29 Thomas Quinot <quinot@adacore.com>
4155
4156 * sem_res.adb: Minor reformatting.
4157
69794413
JK
41582011-08-29 Johannes Kanig <kanig@adacore.com>
4159
4160 * exp_ch4.adb (Expand_Quantified_Expression): Do not expand in ALFA
4161 mode.
4162 * gnat1drv.adb (Adjust_Global_Switches): Set
4163 Use_Expressions_With_Actions to False in ALFA mode.
4164 * sem_res.adb (Resolve_Quantified_Expression): Simpler treatment in
4165 ALFA mode.
4166
59e6b23c
AC
41672011-08-29 Yannick Moy <moy@adacore.com>
4168
4169 * exp_ch13.adb (Expand_N_Freeze_Entity): Do nothing in Alfa mode.
4170 * exp_ch9.adb: Do not expand tasking constructs in Alfa mode.
4171 * gnat1drv.adb (Adjust_Global_Switches): Suppress the expansion of
4172 tagged types and dispatching calls in Alfa mode.
4173
41742011-08-29 Javier Miranda <miranda@adacore.com>
4175
4176 * sem_ch3.adb (Process_Discriminants): Add missing check to ensure that
4177 we do not report an error on an Empty node.
4178
41792011-08-29 Geert Bosch <bosch@adacore.com>
4180
4181 * Makefile.rtl (GNATRTL_NONTASKING_OBJECTS): Add a-nllrar.o,
4182 a-nlrear.o and a-nurear.o.
4183
41842011-08-29 Robert Dewar <dewar@adacore.com>
4185
4186 * freeze.adb: Minor code reorganization.
4187 Minor reformatting.
4188 * sem_util.adb, errout.adb, exp_ch11.adb, a-ngrear.adb, s-gearop.adb,
4189 sem_ch6.adb: Minor reformatting
4190
41912011-08-29 Tristan Gingold <gingold@adacore.com>
4192
4193 * s-except.ads, s-except.adb: Provide dummy body.
4194
41952011-08-29 Yannick Moy <moy@adacore.com>
4196
4197 * sem_warn.adb (Within_Postcondition): Take into account the case of
4198 an Ensures component in a Test_Case.
4199
4d792549
AC
42002011-08-29 Tristan Gingold <gingold@adacore.com>
4201
4202 * s-excdeb.ads, s-excdeb.adb: New files, created from s-except.
4203 * rtsfind.ads (RTU_Id): Replaces System_Exceptions by
4204 System_Exceptions_Debug
4205 (RE_Unit_Table): Search RE_Local_Raise in System_Exceptions_Debug
4206 * a-except.adb: With and use System.Exceptions_Debug instead of
4207 System.Exceptions.
4208 * a-except-2005.adb: Likewise.
4209 * s-assert.adb: Likewise.
4210 * s-except.adb, s-except.ads: Move debugging hooks to s-excdeb.
4211 * Makefile.rtl: Add s-excdeb. Adjust compilation rule.
4212 * gcc-interfaces/Makefile.in, gcc-interface/Make-lang.in: Add
4213 s-excdeb. Update dependencies.
4214 (GNATRTL_LINEARALGEBRA_OBJS): Remove a-nlrear.o a-nurear.o a-nllrar.o
4215 as these no longer need external libraries.
4216
42172011-08-29 Ed Schonberg <schonberg@adacore.com>
4218
4219 * sem_res.adb (Resolve_Op_Expon): Additional check to reject an
4220 exponentiation operator on universal values in a context that requires
4221 a fixed-point type.
4222
42232011-08-29 Tristan Gingold <gingold@adacore.com>
4224
4225 * raise-gcc.c (personnality_routine): Fix thinko. Set Ada occurrence
4226 before calling notify_handled_exception.
4227 * a-exextr.adb: Fix comment.
4228
b254da66
AC
42292011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4230
4231 * exp_ch4.adb (Expand_Allocator_Expression): Add code to set attribute
4232 Finalize_Address of the access type's finalization master.
4233 (Expand_N_Allocator): Add code to set attribute Finalize_Address of the
4234 access type's finalization master. Add a guard to prevent
4235 Associated_Storage_Pool from being set on .NET/JVM.
4236 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Add code to set
4237 attribute Finalize_Address of the access type's finalization master.
4238 * exp_ch7.adb (Make_Finalize_Address_Call): New routine.
4239 * exp_ch7.ads (Make_Finalize_Address_Call): New routine.
4240 * rtsfind.ads: Add RE_Set_Finalize_Address to tables RE_Id and
4241 RE_Unit_Table.
4242 * s-finmas.adb: Add with clause for System.Address_Image. Add with and
4243 use clause for System.IO
4244 (Detach): Relax the assertion, to be reinstated later.
4245 (Finalize): Rewrite the iteration loop to avoid pointer comparison.
4246 Relax the assertion on Finalize_Address, to be reinstated later.
4247 (Is_Empty_List): New routine.
4248 (pm): New debug routine.
4249 (Set_Finalize_Address): New routine.
4250 * s-finmas.ads (pm): New debug routine.
4251 (Set_Finalize_Address): New routine.
4252 * s-stposu.adb (Allocate_Any_Controlled): Code reformatting.
4253
42542011-08-29 Tristan Gingold <gingold@adacore.com>
4255
4256 * a-exexpr-gcc.adb (GCC_Exception_Access, GNAT_GCC_Exception_Access):
4257 Remove convention C.
4258
42592011-08-29 Tristan Gingold <gingold@adacore.com>
4260
4261 * s-taprop-vms.adb (Get_Exc_Stack_Addr): Remove.
4262 (Initialize_TCB): Remove Exc_Stack_Ptr initialization.
4263 (Finalize_TCB): Remove its finalization.
4264 (Initialize): Remove assignment of GET_Exc_Stack_Addr
4265 * s-soflin.adb (NT_Exc_Stack): Remove
4266 (Get_Exc_Stack_Addr_NT): Likewise.
4267 (Get_Exc_Stack_Addr_Soft): Likewise.
4268 * s-soflin.ads (Get_Exc_Stack_Addr_NT): Remove.
4269 (Get_Exc_Stack_Addr): Likewise.
4270 (Get_Exc_Stack_Addr_Soft): Likewise
4271 * s-taspri-vms.ads (Exc_Stack_T): Remove.
4272 (Exc_Stack_Ptr_T): Likewise.
4273 (Private_Data): Remove Exc_Stack_Ptr component.
4274
42752011-08-29 Tristan Gingold <gingold@adacore.com>
4276
4277 * raise-gcc.c (get_ip_from_context): New function. Factorize code.
4278
42792011-08-29 Tristan Gingold <gingold@adacore.com>
4280
4281 * gnat_ugn.texi: Fix aix and x86-solaris info for run-time.
4282
42832011-08-29 Geert Bosch <bosch@adacore.com>
4284
4285 * s-gearop.ads (Back_Substitute, Diagonal, Forward_Eliminate,
4286 L2_Norm, Swap_Column): New generic subprograms
4287 * s-gearop.adb (Back_Substitute, Diagonal, Forward_Eliminate,
4288 L2_Norm, Swap_Column): Implement new subprograms in order to
4289 eliminate dependency on BLAS and LAPACK libraries in
4290 Ada.Numerics.Generic_Real_Arrays and eventually also the complex
4291 version. Forward_Eliminate/Back_Substitute can be used to put a
4292 matrix in row echelon or reduced row echelon form using partial
4293 pivoting.
4294 * a-ngrear.adb: (Back_Substitute, Diagonal, Forward_Eleminate,
4295 Swap_Column): Instantiate from System.Generic_Array_Operations.
4296 ("*", "abs"): Implement by instantiation from Generic_Array_Operations.
4297 (Sqrt): Local function for simple computation of square root without
4298 adding dependencies on Generic_Elementary_Functions.
4299 (Swap): New subprogram to exchange floating point numbers.
4300 (Inverse): Reimplement using Jordan-Gauss elimination.
4301 (Jacobi): New procedure implementing Jacobi's method for computation
4302 of eigensystems, based on Rutishauser's implementation.
4303 (L2_Norm): Implement directly using the inner product.
4304 (Sort_Eigensystem): Sort eigenvalue/eigenvector pairs in order of
4305 decreasing eigenvalue as required by the Ada RM.
4306 (Swap_Column): New helper procedure for Sort_Eigensystem.
4307 Remove with of System.Generic_Real_BLAS and System.Generic_Real_LAPACK.
4308 Add with of Ada.Containers.Generic_Anonymous_Array_Sort, for
4309 Sort_Eigensystems.
4310
43112011-08-29 Thomas Quinot <quinot@adacore.com>
4312
4313 * put_scos.adb (Put_SCOs): Do not emit a newline for an empty
4314 statements line.
4315
60370fb1
AC
43162011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4317
4318 * s-finmas.adb (Finalize): Check Finalize_Address of the master rather
4319 than the current node.
4320 * s-finmas.ads: Move field Finalize_Address from type FM_Node to
4321 Finalization_Master. The list headers have two fields instead of three.
4322 This should fix alignment issue but subpool allocations are now
4323 unusable. Alphabetize subprograms.
4324 * s-stposu.adb (Allocate_Any_Controlled): Use the offset rather than
4325 the size of the header when converting the beginning of the object to
4326 a FM_Node. Set the master's Finalize_Address attribute if not already
4327 set.
4328 (Deallocate_Any_Controlled): Use the offset rather than the size of the
4329 header when converting the beginning of the object to a FM_Node.
4330
43312011-08-29 Gary Dismukes <dismukes@adacore.com>
4332
4333 * exp_ch11.adb (Expand_N_Raise_Statement): Don't suppress expansion of
4334 reraise when compiling for CodePeer.
4335
43362011-08-29 Arnaud Charlet <charlet@adacore.com>
4337
4338 * a-iteint.ads, Makefile.rtl: Add missing compilation of a-iteint.ads,
4339 now needed by a-convec.adb. Fix warning.
4340
43412011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4342
4343 * exp_util.adb (Build_Allocate_Deallocate_Proc): Add a guard for the
4344 processing of TSS routine Finalize_Address when compiling in
4345 CodePeer_Mode.
4346
43472011-08-29 Thomas Quinot <quinot@adacore.com>
4348
4349 * a-strunb.ads, einfo.ads, g-comlin.ads, sem_ch6.adb,
4350 sem_warn.adb: Minor reformatting.
4351
43522011-08-29 Emmanuel Briot <briot@adacore.com>
4353
4354 * prj-conf.adb (Get_Config_Switches): Also collect the list of
4355 languages from aggregated projects.
4356
43572011-08-29 Yannick Moy <moy@adacore.com>
4358
4359 * lib-xref-alfa.adb, lib-xref.ads (Traverse_Declarations_Or_Statements,
4360 Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
4361 Traverse_Package_Declaration, Traverse_Subprogram_Body,
4362 Traverse_Compilation_Unit): Add a parameter Inside_Stubs so that bodies
4363 for stubs are traversed too when parameter is set
4364 (Traverse_All_Compilation_Units): Traverse without going inside stubs
4365 (Traverse_Declarations_Or_Statements): Do the special traversing for
4366 stubs when required.
4367 * sem_util.adb, sem_util.ads (Get_Body_From_Stub): New function to
4368 return subprogram or package body from stub.
4369 (Is_Subprogram_Stub_Without_Prior_Declaration): New function to detect
4370 stubs without prior subprogram decl.
4371
43722011-08-29 Vasiliy Fofanov <fofanov@adacore.com>
4373
4374 * gnat_ugn.texi: Fix typo.
4375
e9c9d122
HK
43762011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4377
4378 * s-stposu.adb (Allocate_Any_Controlled): Reimplement the mechanism
4379 which accounts for size vs alignment issues and calculates the size of
4380 the list header.
4381 (Deallocate_Any_Controlled): Ditto.
4382 (Nearest_Multiple_Rounded_Up): New routine.
4383
25ebc085
AC
43842011-08-29 Tristan Gingold <gingold@adacore.com>
4385
4386 * a-exstat.adb (String_To_EO): Do no set Cleanup_Flag.
4387 * a-exexda.adb (Set_Exception_C_Msg): Ditto.
4388 (Set_Exception_Msg): Ditto.
4389 * a-exexpr-gcc.adb (Setup_Current_Excep): Ditto. Do not set
4390 Private_Data.
4391 * a-except.adb, a-except-2005.adb (Save_Occurrence_No_Private): Remove.
4392 Use Save_Occurrence instead of Save_Occurrence_No_Private.
4393 (Raise_With_Msg): Remove Cleanup_Flag.
4394 * a-except.ads, a-except-2005.ads (Exception_Occurrence): Remove
4395 Clean_Flag and Private_Data components.
4396
43972011-08-29 Yannick Moy <moy@adacore.com>
4398
4399 * freeze.adb (Freeze_Record_Type): Ignore packing in Alfa mode, like
4400 in CodePeer mode.
4401 * sem_ch3.adb (Signed_Integer_Type_Declaration): Correct the generation
4402 of an explicitly declared type, so that the base types of the original
4403 type and this generated type are the same, and a "type" (not a subtype
4404 like previously).
4405 * errout.adb (Special_Msg_Delete): Do not issue messages "Size too
4406 small" in Alfa mode, like in CodePeer mode.
4407 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore rep
4408 clauses in Alfa mode.
4409
44102011-08-29 Javier Miranda <miranda@adacore.com>
4411
4412 * exp_ch6.ads, exp_ch6.adb (Is_Null_Procedure): Move the spec of this
4413 function to the package spec.
4414 * sem_ch6.adb (Find_Corresponding_Spec, New_Overloaded_Entity): For
4415 internally generated bodies of null procedures locate the internally
4416 generated spec enforcing mode conformance.
4417 (Is_Interface_Conformant): Ensure that the controlling formal of the
4418 primitives match.
4419
44202011-08-29 Ed Schonberg <schonberg@adacore.com>
4421
4422 * sem_prag.adb (Analyze_Pragma, case Inline): In an instance, do not
4423 reject the pragma if it appears to apply to a formal subprogram.
4424
44252011-08-29 Ed Schonberg <schonberg@adacore.com>
4426
4427 * exp_ch4.adb (Expand_Allocator_Expression): Use consistent name for
4428 inner expression, to prevent double evaluation.
4429
590549fb
AC
44302011-08-29 Tristan Gingold <gingold@adacore.com>
4431
4432 * a-exexpr.adb (Propagate_Exception): Remove all the parameters as
4433 they were unused.
4434 * a-exexpr-gcc.adb (Propagate_Exception): Ditto.
4435 * a-except-2005.adb (Propagate_Exception): Adjust spec.
4436 (Raise_Current_Excep): Adjust call.
4437 (Raise_From_Signal_Handler): Call now simply call Raise_Current_Excep.
4438
44392011-08-29 Thomas Quinot <quinot@adacore.com>
4440
4441 * exp_disp.adb: Minor reformatting.
4442
62380e66
TG
44432011-08-29 Tristan Gingold <gingold@adacore.com>
4444
4445 * a-exexpr.adb (Setup_Exception): Removed.
4446 * a-exexpr-gcc.adb (Setup_Exception): Removed.
4447 * a-except.adb (Exception_Propagation): Removed.
4448 * a-except-2005.adb (Setup_Exception): Removed.
4449 (Reraise): Remove call to Setup_Exception.
4450 (Reraise_Occurrence): Ditto.
4451 (Reraise_Occurrence_Always): Ditto.
4452 (Reraise_Occurrence_No_Defer): Ditto.
4453 (Transfer_Occurrence): Ditto.
4454 * a-exexda.adb (Set_Exception_C_Msg): Remove call to Setup_Exception.
4455 (Set_Exception_Msg): Ditto.
4456
c95aa61c
AC
44572011-08-29 Robert Dewar <dewar@adacore.com>
4458
4459 * a-convec.adb, exp_disp.adb: Minor reformatting.
4460
44612011-08-29 Tristan Gingold <gingold@adacore.com>
4462
4463 * a-exexpr-gcc.adb (GNAT_GCC_Exception_Access): Set to convention C.
4464
624e1688
AC
44652011-08-29 Gary Dismukes <dismukes@adacore.com>
4466
4467 * exp_ch3.adb (Build_Record_Init_Proc.Build_Init_Procedure): Set
4468 Exception_Handlers to No_List instead of Empty_List in the case where
4469 there are no handlers.
4470
44712011-08-29 Tristan Gingold <gingold@adacore.com>
4472
4473 * gcc-interface/gigi.h (enum standard_datatypes): Add
4474 ADT_reraise_zcx_decl
4475 (reraise_zcx_decl): New macro.
4476 * gcc-interface/trans.c (gnu_incoming_exc_ptr): New variable.
4477 (gigi): Set reraise_zcx_decl.
4478 (Exception_Handler_to_gnu_zcx): Save and restore gnu_incoming_exc_ptr.
4479 (gnat_to_gnu): Handle N_Raise_Statement.
4480
7134062a
AC
44812011-08-29 Robert Dewar <dewar@adacore.com>
4482
4483 * sem_ch6.adb, exp_ch3.adb, s-stposu.adb, a-undesu.ads,
4484 a-undesu.adb: Minor reformatting.
4485
44862011-08-29 Ed Schonberg <schonberg@adacore.com>
4487
4488 * exp_disp.adb (Check_Premature_Freezing): When building a dispatch
4489 table, accept an unfrozen untagged component if it is an actual for a
4490 formal incomplete type.
4491 * a-convec.ads, a-convec.adb: Instantiate Ada.Iterator_Interfaces to
4492 provide new iterator forms over vectors.
4493 Introduce type Iterator in package body to implement operations of
4494 Reversible_Iterator interface.
4495 * a-iteint.ads: Make package pure so it is usable with new container
4496 packages, that are categorized Remote_Types.
4497
ca5af305
AC
44982011-08-29 Robert Dewar <dewar@adacore.com>
4499
4500 * a-exexpr-gcc.adb, a-synbar.adb, sem_ch13.adb: Minor reformatting.
4501
45022011-08-29 Bob Duff <duff@adacore.com>
4503
4504 * sem_aggr.adb (Resolve_Aggr_Expr): Call this routine even in the case
4505 of <>, because this is the routine that checks for dimensionality
4506 errors (for example, for a two-dimensional array, (others => <>) should
4507 be (others => (others => <>)).
4508
45092011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4510
4511 * impunit.adb: Add new run-time units.
4512 * freeze.adb, exp_ch7.ads, exp_ch7.adb, exp_util.ads, exp_util.adb,
4513 s-stposu.ads, s-stposu.adb: Code clean up.
4514 Handle protected class-wide or task class-wide types
4515 Handle C/C++/CIL/Java types.
4516 * s-spsufi.adb, s-spsufi.ads: New files.
4517
5accd7b6
AC
45182011-08-29 Yannick Moy <moy@adacore.com>
4519
4520 * sem_ch13.adb (Analyze_Aspect_Specifications): Reject test-case on
4521 library-level subprogram.
4522 * sem_prag.adb (Check_Test_Case): Stricter rules for test-case
4523 placement.
4524 (Analyze_Pragma): Change name "Normal" for "Nominal" in test-case
4525 component.
4526 * snames.ads-tmpl: Change name "Normal" for "Nominal" in test-case
4527 component.
4528 * gnat_rm.texi: Update doc for Test_Case pragma.
4529
45302011-08-29 Tristan Gingold <gingold@adacore.com>
4531
4532 * a-exexpr-gcc.adb (Unwind_Exception): Remove default value, made it
4533 convention C.
4534 (GCC_Exception_Access): New type.
4535 (Unwind_DeleteException): New imported procedure
4536 (Foreign_Exception): Import it.
4537 (GNAT_GCC_Exception): Simply have the occurrence inside.
4538 (To_GCC_Exception): New function.
4539 (To_GNAT_GCC_Exception): New function.
4540 (GNAT_GCC_Exception_Cleanup): New procedure..
4541 (Propagate_GCC_Exception): New procedure.
4542 (Reraise_GCC_Exception): New procedure.
4543 (Setup_Current_Excep): New procedure.
4544 (CleanupUnwind_Handler): Change type of UW_Exception parameter.
4545 (Unwind_RaiseException): Ditto.
4546 (Unwind_ForcedUnwind): Ditto.
4547 (Remove): Removed.
4548 (Begin_Handler): Change type of parameter.
4549 (End_Handler): Ditto. Now delete the exception if still present.
4550 (Setup_Key): Removed.
4551 (Is_Setup_And_Not_Propagated): Removed.
4552 (Set_Setup_And_Not_Propagated): Ditto.
4553 (Clear_Setup_And_Not_Propagated): Ditto.
4554 (Save_Occurrence_And_Private): Ditto.
4555 (EID_For): Add 'not null' constraint on parameter.
4556 (Setup_Exception): Does nothing.
4557 (Propagate_Exception): Simplified.
4558 * exp_ch11.adb (Expand_N_Raise_Statement): In back-end exception model,
4559 re-raise is not expanded anymore.
4560 * s-except.ads (Foreign_Exception): New exception - placeholder for
4561 non Ada exceptions.
4562 * raise-gcc.c (__gnat_setup_current_excep): Declare
4563 (CXX_EXCEPTION_CLASS): Define (not yet used)
4564 (GNAT_EXCEPTION_CLASS): Define.
4565 (is_handled_by): Handle foreign exceptions.
4566 (PERSONALITY_FUNCTION): Call __gnat_setup_current_excep.
4567
45682011-08-29 Jose Ruiz <ruiz@adacore.com>
4569
4570 * a-synbar.adb (Synchronous_Barrier): Some additional clarification.
4571
2ef48385
AC
45722011-08-29 Thomas Quinot <quinot@adacore.com>
4573
4574 * a-synbar-posix.adb: Minor reformatting.
4575
45762011-08-29 Jose Ruiz <ruiz@adacore.com>
4577
4578 * a-exetim-posix.adb, a-exetim-mingw.adb, a-exetim-mingw.ads,
4579 a-exetim-default.ads (Interrupt_Clocks_Supported,
4580 Separate_Interrupt_Clocks_Supported, Clock_For_Interrupts): Add these
4581 definitions to be compliant with AI-0171. The target systems do not
4582 support separate account for the execution time of interrupt handlers.
4583
45842011-08-29 Jose Ruiz <ruiz@adacore.com>
4585
4586 * a-synbar.adb (Wait): Change the order of evaluation of the conditions
4587 in the barrier to put first the easiest to evaluate (and the one which
4588 will be True more often). More efficient.
4589
45902011-08-29 Eric Botcazou <ebotcazou@adacore.com>
4591
4592 * s-atocou-x86.adb: Fix constraint in machine code insertion.
4593
45942011-08-29 Bob Duff <duff@adacore.com>
4595
4596 * aspects.ads, aspects.adb: Add new aspects for various pragmas and
4597 attributes that are now aspects, as specified by AI05-0229-1.
4598 * sem_ch13.adb (Analyze_Aspect_Specifications,
4599 Check_Aspect_At_Freeze_Point): Analyze the new aspects. Turn them into
4600 pragmas or attribute references, as appropriate.
4601
0db16b1e
AC
46022011-08-29 Robert Dewar <dewar@adacore.com>
4603
4604 * a-synbar.ads, a-synbar.adb, a-synbar-posix.adb,
4605 a-synbar-posix.ads: Minor reformatting.
4606
46072011-08-29 Yannick Moy <moy@adacore.com>
4608
4609 * snames.ads-tmpl: Add name Force.
4610
978ffe02
AC
46112011-08-29 Pascal Obry <obry@adacore.com>
4612
4613 * prj-nmsc.adb: Minor reformatting.
4614
46152011-08-29 Jose Ruiz <ruiz@adacore.com>
4616
4617 * a-exetim.ads (Interrupt_Clocks_Supported,
4618 Separate_Interrupt_Clocks_Supported, Clock_For_Interrupts): Add these
4619 definitions to be compliant with AI-0171.
4620
46212011-08-29 Robert Dewar <dewar@adacore.com>
4622
4623 * a-ngelfu.adb: Add comments.
4624
718f39dc
AC
46252011-08-29 Geert Bosch <bosch@adacore.com>
4626
4627 * a-ngelfu.adb (Tan): Do not raise Constraint_Error if the argument is
4628 the closest machine number to Pi / 2.0.
4629
46302011-08-29 Jose Ruiz <ruiz@adacore.com>
4631
4632 * impunit.adb (Non_Imp_File_Names_12): Add a-synbar for new Ada 2012
4633 package Ada.Synchronous_Barriers.
4634 * a-synbar.ads, a-synbar.adb, a-synbar-posix.ads, a-synbar-posix.adb:
4635 Add new specs and bodies for Ada.Synchronous_Barriers. There is a
4636 default implementation using protected objects and another one
4637 a-synbar-posix using POSIX barriers as the underlying support.
4638 * gcc-interface/Makefile.in (LIBGNAT_TARGET_PAIRS for Linux (x86,
4639 x86_64, ia64) and MIPS IRIX): Use the a-synbar-posix implementation of
4640 Ada.Synchronous_Barriers which uses POSIX barriers (more efficient).
4641 Clean up dependencies.
4642 * Makefile.rtl (GNATRTL_TASKING_OBJS): Add a-synbar.o
4643
ee2e3f6b
AC
46442011-08-29 Robert Dewar <dewar@adacore.com>
4645
4646 * sem_ch7.adb, make.adb, sem_res.adb, exp_intr.adb,
4647 exp_dist.adb: Minor code reorganization.
4648 Minor reformatting.
4649
46502011-08-29 Thomas Quinot <quinot@adacore.com>
4651
4652 * sem_cat.adb (Validate_RACW_Primitive): The return type of an RACW
4653 primitive operation must support external streaming if it is not a
4654 controlling access result.
4655
646e2823
AC
46562011-08-29 Thomas Quinot <quinot@adacore.com>
4657
4658 * sinfo.ads, sem_ch7.adb: Minor reformatting.
4659
46602011-08-29 Bob Duff <duff@adacore.com>
4661
4662 * sem_ch4.adb (Analyze_Allocator): Check No_Nested_Finalization
4663 restriction on allocators, as required by AI05-0013-1.
4664 * restrict.ads: Minor comment fix.
4665
5d59eef2
AC
46662011-08-29 Tristan Gingold <gingold@adacore.com>
4667
4668 * a-exexpr.adb, a-except-2005.ads (Jmpbuf_Address): Move to a-exexpr.adb
4669 (To_Jmpbuf_Address): Ditto
4670 (builtin_longjmp): Ditto
4671
46722011-08-29 Thomas Quinot <quinot@adacore.com>
4673
4674 * sem_res.adb: Minor reformatting.
4675
46762011-08-29 Vincent Celier <celier@adacore.com>
4677
4678 * make.adb (Gnatmake): Move special processing for VM targets after the
4679 call to Get_Target_Parameters.
4680
46812011-08-29 Thomas Quinot <quinot@adacore.com>
4682
4683 * sem_ch12.adb, par-ch12.adb: Minor reformatting.
4684
949a18cc
AC
46852011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4686
4687 * sem_res.adb (Resolve_Allocator): Implement Ada2012-B052. Detect cases
4688 where an anonymous access discriminant of a limited designated type
4689 appears in a non-immutably limited discriminated type and issue an
4690 error message. Add local variable Desig_T and replace all occurrences
4691 of Designated_Type.
4692
46932011-08-29 Jose Ruiz <ruiz@adacore.com>
4694
4695 * a-rttiev.adb (Set_Handler): Update comment to indicate that our
4696 implementation is compliant to RM D.15(15/2) after the modification
4697 imposed by AI05-0094-1 (binding interpretation).
4698
cb25faf8
AC
46992011-08-29 Robert Dewar <dewar@adacore.com>
4700
4701 * exp_ch9.adb, s-tasren.adb, exp_sel.adb, exp_sel.ads, exp_ch11.adb,
4702 s-interr-hwint.adb, s-tpobop.adb, sem_ch13.adb: Minor reformatting.
4703
47042011-08-29 Thomas Quinot <quinot@adacore.com>
4705
4706 * par-endh.adb (Check_End): For an END where it is mandatory to repeat
4707 the scope name, do not report a missing label as a style violation (it
4708 will be diagnosed as an illegality).
4709 * exp_dist.adb (Add_Params_For_Variant_Components): Fix handling of
4710 variant records: Get_Enum_Lit_From_Pos already returns a usage
4711 occurrence of the literal, no need to use New_Occurrence_Of. Set Etype
4712 on Expr in Integer_Literal case so that it can be used by
4713 Build_To_Any_Call.
4714
1d10f669
AC
47152011-08-29 Tristan Gingold <gingold@adacore.com>
4716
4717 * exp_sel.ads (Build_Abort_BLock_Handler): New function spec.
4718 Adjust comment.
4719 * exp_sel.adb (Build_Abort_Block): Use Build_Abort_Block_Handler.
4720 (Build_Abort_Block_Handler): New function to build an Abort_Signal
4721 exception handler.
4722 * exp_ch9.adb (Expand_N_Asynchronous_Select): Call
4723 Build_Abort_Block_Handler to build the exception handler. Do not
4724 undefer aborts for the Abort_Signal exception handler if back-end
4725 exception mechanism.
4726 * exp_ch11.adb (Expand_Exception_Handlers): Do not undefer aborts if
4727 back_end exceptions for all others and abort_signal.
4728 * s-except.ads (ZCX_By_Default): New constant.
4729 * a-except-2005.adb (Raise_Exception): Do not defer abort if ZCX.
4730 (Raise_Exception_Always): Ditto.
4731 (Raise_From_Signal_Handler): Ditto.
4732 (Raise_With_Location_And_Msg): Ditto.
4733 (Raise_With_Msg): Ditto.
4734 (Reraise): Ditto.
4735 (Reraise_Occurence): Ditto.
4736 (Reraise_Occurrence_Always): Ditto.
4737 * s-tasren.adb (Exceptional_Complete_Rendezvous): Defer aborts if ZCX.
4738 * s-tpobop.adb: (Exceptional_Complete_Body): Undefer abort if ZCX.
1d10f669
AC
4739
47402011-08-29 Thomas Quinot <quinot@adacore.com>
4741
4742 * sem_util.ads (Get_Enum_Lit_From_Pos): Clarify documentation.
4743
d986066d
AC
47442011-08-29 Robert Dewar <dewar@adacore.com>
4745
4746 * snames.adb-tmpl, sem_ch13.adb: Minor reformatting
4747 Minor code reorganization.
4748
47492011-08-29 Bob Duff <duff@adacore.com>
4750
4751 * usage.adb (-gnatwy): Fix documentation: this switch applies to Ada
4752 2012, not just Ada 2005.
4753
47542011-08-29 Vincent Celier <celier@adacore.com>
4755
4756 * gnat_ugn.texi: Indicate that when the compiler is called by gnatmake
4757 with a project file or with gprbuid, if -gnatep= is specified, the
4758 builder may need to be invoked with -x.
4759
47602011-08-29 Tristan Gingold <gingold@adacore.com>
4761
4762 * a-exexpr-gcc.adb: Minor comment fix.
4763
ff4f0ed0
AC
47642011-08-29 Robert Dewar <dewar@adacore.com>
4765
4766 * sem_ch8.adb: Minor reformatting.
4767
47682011-08-29 Bob Duff <duff@adacore.com>
4769
4770 * par-ch2.adb (P_Identifier): Warn that "some" is reserved in Ada 2012.
4771 * par-ch4.adb (P_Quantified_Expression): Remove unnecessary code for
4772 treating "some" as unreserved in earlier Ada versions. This is now
4773 handled in Snames.Is_Keyword_Name. Parse "for some" using Tok_Some,
4774 rather than Name_Some, since Tok_Some is now recognized as reserved.
4775 * scans.adb (Initialize_Ada_Keywords): Handle Tok_Some like any other
4776 reserved word.
4777 * scans.ads: Minor comment fixes.
4778 * snames.adb-tmpl (Is_Keyword_Name): Handle Ada 2012 reserved words as
4779 for other language versions.
4780 * scn.adb (Scan_Reserved_Identifier): Remove unnecessary code for
4781 treating "some" as unreserved in earlier Ada versions. This is now
4782 handled in Snames.Is_Keyword_Name.
4783 * par-ch3.adb (P_Defining_Identifier): Warn that "some" is reserved in
4784 Ada 2012.
4785 (P_Subtype_Mark_Resync): Remove unnecessary code for treating "some" as
4786 unreserved in earlier Ada versions. This is now handled in
4787 Snames.Is_Keyword_Name.
4788 * snames.ads-tmpl (Ada_2012_Reserved_Words): Handle Ada 2012 reserved
4789 words as for other language versions.
4790 * gnat_ugn.texi (-gnatwy): Fix documentation: this switch applies to
4791 Ada 2012, not just Ada 2005.
4792
d941cee6
AC
47932011-08-29 Ed Schonberg <schonberg@adacore.com>
4794
4795 * sem_ch13.adb: Additional semantic checks for aspects involved in
4796 iterators.
4797
47982011-08-29 Matthew Heaney <heaney@adacore.com>
4799
4800 * a-comutr.ads, a-comutr.adb, a-cimutr.ads, a-cimutr.adb,
4801 a-cbmutr.ads, a-cbmutr.adb (Find_In_Subtree): Remove superfluous
4802 Container parameter.
4803 (Ancestor_Find): ditto.
4804
b970af39
TQ
48052011-08-29 Thomas Quinot <quinot@adacore.com>
4806
4807 * par-endh.adb: Minor reformatting.
d941cee6 4808
92db5dee
AC
48092011-08-29 Tristan Gingold <gingold@adacore.com>
4810
4811 * a-exexpr-gcc.adb (Unwind_Action) Rewrite as an integer with constants.
4812 (GNAT_GCC_Exception): Remove N_Cleanups_To_Trigger component.
4813 (Adjust_N_CLeanups_For): Remove.
4814 (CleanupUnwind_Handler): Call Unhandled_Exception_Terminate when end of
4815 stack is reached.
4816 (Propgate_Exception): Adjust.
4817 * raise-gcc.c: Add a few static/const.
4818 (Adjust_N_Cleanups_For): Remove declaration.
4819 (PERSONALITY_FUNCTION): Remove code dealing with N_Cleanups_To_Trigger.
4820
48212011-08-29 Ed Schonberg <schonberg@adacore.com>
4822
4823 * sem_ch8.adb: Use type of function return when rewriting as object
4824 declaration.
4825
1378bf10
AC
48262011-08-29 Gary Dismukes <dismukes@adacore.com>
4827
4828 * sem_type.adb: Minor reformatting.
4829
48302011-08-29 Robert Dewar <dewar@adacore.com>
4831
4832 * makeutl.adb: Minor reformatting.
4833
48342011-08-29 Ed Schonberg <schonberg@adacore.com>
4835
4836 * sem_ch8.adb (Analyze_Object_Renaming): If the renamed object is a
4837 function call of a limited type, the expansion of the renaming is
4838 complicated by the presence of various temporaries and subtypes that
4839 capture constraints of the renamed object.
4840 Rewrite node as an object declaration, whose expansion is simpler.
4841 Given that the object is limited there is no copy involved and no
4842 performance hit.
4843
164e06c6
AC
48442011-08-29 Robert Dewar <dewar@adacore.com>
4845
4846 * exp_ch5.adb, sinfo.ads, make.adb, s-pooglo.adb, sem_ch12.adb,
4847 freeze.adb, sem_ch6.adb, par-ch12.adb: Minor reformatting.
4848
48492011-08-29 Tristan Gingold <gingold@adacore.com>
4850
4851 * system-darwin-x86.ads, system-linux-s390x.ads, system-linux-alpha.ads,
4852 system-tru64.ads, system-irix-n32.ads, system-vxworks-arm.ads,
4853 system-linux-hppa.ads, system-linux-s390.ads,
4854 system-solaris-sparcv9.ads, system-mingw.ads, system-linux-ia64.ads,
4855 system-vms_64.ads, system-vxworks-sparcv9.ads, system-linux-ppc.ads,
4856 system-aix64.ads, system-lynxos-ppc.ads, system-linux-sh4.ads,
4857 system-solaris-x86.ads, system-linux-x86_64.ads, system-linux-x86.ads,
4858 system-vxworks-ppc.ads, system-hpux.ads, system-darwin-ppc.ads,
4859 system-solaris-sparc.ads, system-lynxos-x86.ads,
4860 system-vxworks-m68k.ads, system-hpux-ia64.ads, system-irix-o32.ads,
4861 system-solaris-x86_64.ads, system-mingw-x86_64.ads,
4862 system-vxworks-mips.ads, system-linux-sparc.ads, system-vms-ia64.ads,
4863 system-freebsd-x86.ads, system-aix.ads, system-darwin-x86_64.ads,
7d266442 4864 system-vxworks-x86.ads: Remove GCC_ZCX_Support.
164e06c6
AC
4865 * s-taprop-posix.adb, s-taprop-irix.adb, s-taprop-vxworks.adb,
4866 s-taprop-tru64.adb, s-taprop-linux.adb, s-taprop-solaris.adb: Ditto.
4867 * opt.ads: Adjust comment.
4868 * targparm.ads, targparm.adb: Remove GCC_ZCX_Support_On_Target.
4869 * gnat1drv.adb: Do not check for GCC_ZCX_Support_On_Target.
4870 * system.ads: Move GCC_ZCX_Support to obsolete entries.
4871
48722011-08-29 Emmanuel Briot <briot@adacore.com>
4873
4874 * makeutl.adb (Do_Complete): Resolve symbolic links when a relative
4875 file name is specified on the gnatmake or gprbuild command line, and
4876 before we search for that file in the project.
4877
48782011-08-29 Ed Schonberg <schonberg@adacore.com>
4879
4880 * sem_type.adb (Within_Instance): New predicate in Collect_Interps,
4881 used to determine whether a possible interpretation for an overloadable
4882 entity is declared within the current instantiation and should be
4883 included in the candidate set.
4884
48852011-08-29 Vasiliy Fofanov <fofanov@adacore.com>
4886
4887 * gnat_rm.texi, gnat_ugn.texi: Clean ups.
4888
97216ca8
ES
48892011-08-29 Ed Schonberg <schonberg@adacore.com>
4890
4891 * sem_res.adb (Resolve_Actuals): Use base type to determine whether an
4892 access subtype is access_to_subprogram, when applying checks for
4893 RM 3.10.2 (27).
4894
d3cb4cc0
AC
48952011-08-29 Matthew Heaney <heaney@adacore.com>
4896
4897 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Splice_Subtree): Only check
4898 for sibling when common parent.
4899
49002011-08-29 Thomas Quinot <quinot@adacore.com>
4901
4902 * get_scos.adb: Literals of Pragma_Id are pragma names prefixed with
4903 "pragma_".
4904
49052011-08-29 Ed Schonberg <schonberg@adacore.com>
4906
4907 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Enable freeze actions
4908 for the return type when in ASIS mode.
4909
49102011-08-29 Vincent Celier <celier@adacore.com>
4911
4912 * make.adb (Gnatmake): Get the default search dirs, then the target
4913 parameters after getting the Builder switches, as the Builder switches
4914 may include --RTS= and that could change the default search dirs.
4915
49162011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4917
4918 * exp_ch7.adb (Make_Adjust_Call): Rewrite to mimic the structure of
4919 Make_Final_Call. Move the processing for class-wide types before the
4920 processing for derivations from [Limited_]Controlled.
4921 (Make_Final_Call): Move the processing for class-wide types before the
4922 processing for derivations from [Limited_]Controlled.
4923 * s-stposu.adb (Allocate_Any_Controlled): Correct the membership check.
4924 Add code to account for alignments larger than the list header. Add a
4925 comment illustrating the structure of the allocated object + padding +
4926 header.
4927 (Deallocate_Any_Controlled): Add code to account for alignments larger
4928 than the list header.
4929
49302011-08-29 Ed Schonberg <schonberg@adacore.com>
4931
4932 * sinfo.ads, sinfo.adb: New node kind
4933 N_Formal_Incomplete_Type_Definition, related flags.
4934 par-ch12.adb (P_Formal_Type_Declaration, G_Formal_Type_Definition):
4935 Parse formal incomplete types.
4936 * sem.adb (Analyze): Formal_Incomplete_Type_Definitions are handled in
4937 sem_ch12.
4938 * sem_ch7.adb (Analyze_Package_Specification, Unit_Requires_Body):
4939 Formal incomplete types do not need completion.
4940 * sem_ch12.adb (Analyze_Formal_Incomplete_Type,
4941 Validate_Incomplete_Type_Instance): New procedures to handle formal
4942 incomplete types.
4943 * freeze.adb (Freeze_Entity): Do not freeze the subtype of an actual
4944 that corresponds to a formal incomplete type.
4945 * sprint.adb: Handle formal incomplete type declarations.
4946 * exp_util.adb (Insert_Actions): An incomplete_type_definition is not
4947 an insertion point.
4948
d3f70b35
AC
49492011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4950
4951 * a-fihema.ads, a-fihema.adb: Unit removed.
4952 * a-undesu.ads, a-undesu.adb: New unit implementing
4953 Ada.Unchecked_Deallocate_Subpool.
4954 * einfo.adb: Remove Associated_Collection from the node usage.
4955 Add Finalization_Master to the node usage.
4956 (Associated_Collection): Removed.
4957 (Finalization_Master): New routine.
4958 (Set_Associated_Collection): Removed.
4959 (Set_Finalization_Master): New routine.
4960 (Write_Field23_Name): Remove Associated_Collection from the output. Add
4961 Finalization_Master to the output.
4962 * einfo.ads: Remove attribute Associated_Collection and its uses in
4963 entities.
4964 Add new attribute Finalization_Master along with its uses in entitites.
4965 (Associated_Collection): Removed along with its pragma import.
4966 (Finalization_Master): New routine along with a pragma import.
4967 (Set_Associated_Collection): Removed along with its pragma import.
4968 (Set_Finalization_Master): New routine along with a pragma import.
4969 * exp_ch3.adb (Expand_Freeze_Array_Type): Replace call to
4970 Build_Finalization_Collection with Build_Finalization_Master.
4971 (Expand_Freeze_Record_Type): Move the generation of Finalize_Address
4972 before the bodies of the predefined routines. Add comment explaining
4973 this. Replace call to Build_Finalization_Collection with
4974 Build_Finalization_Master.
4975 (Freeze_Type): Replace call to Build_Finalization_Collection with
4976 Build_Finalization_Master.
4977 (Make_Finalize_Address_Body): Comment reformatting.
4978 (Make_Predefined_Primitive_Specs): Code reformatting.
4979 (Stream_Operation_OK): Update comment mentioning finalization
4980 collections. Replace RE_Finalization_Collection with
4981 RE_Finalization_Master.
4982 * exp_ch4.adb (Complete_Controlled_Allocation): Replace call to
4983 Associated_Collection with Finalization_Master. Replace call to
4984 Build_Finalization_Collection with Build_Finalization_Master.
4985 (Expand_Allocator_Expression): Replace call to Associated_Collection
4986 with Finalization_Master. Replace call to Set_Associated_Collection with
4987 Set_Finalization_Master. Remove the generation of
4988 Set_Finalize_Address_Ptr.
4989 (Expand_N_Allocator): Replace call to Associated_Collection with
4990 Finalization_Master. Remove the generation of Set_Finalize_Address_Ptr.
4991 * exp_ch6.adb (Add_Collection_Actual_To_Build_In_Place_Call): Renamed to
4992 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Update the
4993 comment on usage. Replace call to Needs_BIP_Collection with
4994 Needs_BIP_Finalization_Master Remplace BIP_Collection with
4995 BIP_Finalization_Master. Update all comments which mention finalization
4996 collections. Replace Associated_Collection with
4997 Finalization_Master. Replace Build_Finalization_Collection with
4998 Build_Finalization_Master.
4999 (BIP_Formal_Suffix): Update BIP_Collection's case.
5000 (Build_Heap_Allocator): Update the related comment. Rename local
5001 variable Collect to Fin_Mas_Id and update its occurrences. Update
5002 comments which mention finalization collections. Replace
5003 Set_Associated_Collection with Set_Finalization_Master.
5004 (Expand_Call): Update the code which detects a special piece of library
5005 code for .NET/JVM.
5006 (Make_Build_In_Place_Call_In_Allocator): Replace the call to
5007 Add_Collection_Actual_To_Build_In_Place_Call with
5008 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Remove the code
5009 which generates a call to Make_Set_Finalize_Address_Ptr_Call.
5010 (Make_Build_In_Place_Call_In_Anonymous_Context): Replace call to
5011 Add_Collection_Actual_To_Build_In_Place_Call with
5012 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
5013 (Make_Build_In_Place_Call_In_Assignment): Replace call to
5014 Add_Collection_Actual_To_Build_In_Place_Call with
5015 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
5016 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
5017 * exp_ch6.ads: Rename BIP_Collection to BIP_Finalization_Master.
5018 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
5019 * exp_ch7.adb (Build_BIP_Cleanup_Stmts): Update comment on usage.
5020 Rename local variable Collect to Fin_Mas_Id and update its occurrences.
5021 Replace call to Set_Associated_Collection with Set_Finalization_Master.
5022 (Build_Finalization_Collection): Renamed to Build_Finalization_Master.
5023 Replace the call to Associated_Collection with Finalization_Master.
5024 Rename local variable Coll_Id to Fin_Mas_Id and update its occurrences.
5025 Update the way finalization master names are generated. Update the
5026 retrieval of the correct access type which will carry the pool and
5027 master attributes.
5028 (Make_Final_Call): Reimplement the way [Deep_]Finalize is retrieved.
5029 (Make_Finalize_Address_Body): Abstract types do not need
5030 Finalize_Address. Code reformatting.
5031 (Make_Finalize_Address_Stmts): Update comment on usage.
5032 (Make_Set_Finalize_Address_Ptr_Call): Removed.
5033 (Process_Declarations): Update comments.
5034 * exp_ch7.ads (Build_Finalization_Collection): Renamed to
5035 Build_Finalization_Master. Update associated comment.
5036 (Make_Set_Finalize_Address_Ptr_Call): Removed.
5037 * exp_ch13.adb: Update comments which mention finalization collections.
5038 (Expand_N_Free_Statement): Replace the call to Associated_Collection
5039 with Finalization_Master.
5040 * exp_util.adb (Build_Allocate_Deallocate_Proc): Reimplemented to
5041 create calls to routines Allocate_Any_Controlled and
5042 Deallocate_Any_Controlled.
5043 (Find_Finalize_Address): New routine.
5044 (Is_Allocate_Deallocate_Proc): Update the RTE entities used in the
5045 comparison.
5046 (Requires_Cleanup_Actions): Update the comment on freeze node
5047 inspection.
5048 * exp_util.ads: Remove comment on generated code for
5049 Build_Allocate_Deallocate_Proc. The code is now quite complex and it
5050 is better to simply look in the body.
5051 * freeze.adb (Freeze_All): Update the comment of finalization
5052 collections. Replace the call to Associated_Collection with
5053 Finalization_Master. Replace the call to Build_Finalization_Collection
5054 with Build_Finalization_Master.
5055 * impunit.adb: Add a-undesu and s-stposu to the list of units.
5056 * Makefile.rtl: Add files a-undesu, s-finmas and s-stposu. Remove file
5057 a-fihema.
5058 * rtsfind.adb (Get_Unit_Name): Remove the processing for children of
5059 Ada.Finalization. Add processing for children of System.Storage_Pools.
5060 * rtsfind.ads: Remove the naming of second level children of
5061 Ada.Finalization.
5062 Remove Ada_Finalization_Heap_Management from the list of units.
5063 Remove subtype Ada_Finalization_Child.
5064 Remove the following subprogram entities:
5065
5066 RE_Allocate
5067 RE_Deallocate
5068 RE_Finalization_Collection
5069 RE_Finalization_Collection_Ptr
5070 RE_Set_Finalize_Address_Ptr
5071
5072 Add the naming of second level children of System.Storage_Pools.
5073 Add System_Finalization_Masters and System_Storage_Pools_Subpools to
5074 the list of units.
5075 Add subtype System_Storage_Pools_Child.
5076 Add the following subprogram entities to System.Finalization_Masters:
5077
5078 RE_Finalization_Master
5079 RE_Finalization_Master_Ptr
5080
5081 Add the following subprogram entities to System.Storage_Pools.Subpools:
5082
5083 RE_Allocate_Any_Controlled
5084 RE_Deallocate_Any_Controlled
5085 RE_Root_Storage_Pool_With_Subpools
5086 RE_Root_Subpool
5087 RE_Subpool_Handle
5088
5089 Move the following subprogram entities from
5090 Ada.Finalization.Heap_Management to System.Finalization_Masters:
5091
5092 RE_Add_Offset_To_Address
5093 RE_Attach
5094 RE_Base_Pool
5095 RE_Detach
5096
5097 * sem_ch3.adb (Access_Type_Declaration): Replace the call to
5098 Set_Associated_Collection with Set_Finalization_Master.
5099 * sem_ch6.adb (Create_Extra_Formals): Update the way extra formal
5100 BIP_Finalization_Master is created.
5101 * s-finmas.adb: New unit System.Finalization_Masters.
5102 * s-finmas.ads: New unit System.Finalization_Masters.
5103 * s-stopoo.ads, s-stopoo.adb: Minor code reformatting.
5104 * s-stposu.ads, s-stposu.adb: New unit implementing
5105 System.Storage_Pools.Subpools.
5106
51072011-08-29 Bob Duff <duff@adacore.com>
5108
5109 * tbuild.adb: Add assertion.
5110
8c889ae4
AC
51112011-08-29 Thomas Quinot <quinot@adacore.com>
5112
5113 * s-pooglo.adb: Minor reformatting.
5114
51152011-08-29 Ed Schonberg <schonberg@adacore.com>
5116
5117 * exp_ch5.adb (Expand_N_Assignment_Statement): if the left-hand side is
5118 an indexed component of a packed array whose element type is a record
5119 with a representation clause different from that of the right-hand
5120 side, generate a temporary to minimuze the number of bit-field
5121 operations generated.
5122
51232011-08-29 Ed Schonberg <schonberg@adacore.com>
5124
5125 * exp_util.adb (Insert_Actions): Use clauses can be part of lists of
5126 declarations, and thus are likely insertion points for actions.
5127
51282011-08-29 Bob Duff <duff@adacore.com>
5129
5130 * einfo.ads: Minor comment fix.
5131
1a07a71a
AC
51322011-08-29 Robert Dewar <dewar@adacore.com>
5133
5134 * frontend.adb, gnat1drv.adb: Minor reformatting.
5135
51362011-08-29 Tristan Gingold <gingold@adacore.com>
5137
5138 * s-pooglo.adb (Allocate, Deallocate): Take into account the alignment.
5139 * a-fihema.adb (Allocate, Deallocate): Ditto. Possibly add padding
5140 space in front of the header.
5141
4bcd6411
JK
51422011-08-29 Johannes Kanig <kanig@adacore.com>
5143
5144 * frontend.adb (Frontend): Exit after creating Standard package when
5145 -gnatd.H is present.
5146 * gnat1drv.adb (Gnat1drv): Call Backend right away when -gnatd.H is
5147 present.
5148
f0f88eb6
RD
51492011-08-29 Robert Dewar <dewar@adacore.com>
5150
5151 * exp_ch9.adb, mlib-prj.adb, prj.adb, prj.ads, ttypes.ads, sem_ch4.adb,
5152 makeutl.adb, makeutl.ads, atree.ads, snames.adb-tmpl,
5153 snames.ads-tmpl: Minor reformatting.
5154
3e37be71
PG
51552011-08-29 Philippe Gil <gil@adacore.com>
5156
5157 * prj.adb (Reset_Units_In_Table): New procedure.
5158 Reset units to avoid access to freed memory.
5159
94fb7608
AC
51602011-08-29 Thomas Quinot <quinot@adacore.com>
5161
5162 * get_scos.adb: When reading a P statement SCO without a pragma name
5163 (from an older ALI file), ensure that the Pragma_Name component is set
5164 to Unknown_Pragma (not left uninitialized).
5165
51662011-08-29 Vincent Celier <celier@adacore.com>
5167
5168 * makeutl.adb (Get_Directories): New procedure moved from Buildgpr and
5169 modified to compute correctly the object path of a SAL project that is
5170 extending another library project.
5171 (Write_Path_File): New procedure.
5172 * makeutl.ads (Directories): New table moved from Buildgpr
5173 (Get_Directories): New procedure moved from Buildgpr
5174 (Write_Path_File): New procedure
5175 * mlib-prj.adb (Build_Library): Use Makeutl.Get_Directories to set the
5176 paths before binding SALs, instead of Set_Ada_Paths.
5177 * prj-env.adb (Set_Path_File_Var): Procedure has been moved to package
5178 Prj.
5179 * prj.adb (Set_Path_File_Var): New procedure moved from Prj.Env
5180 (Current_Source_Path_File_Of): New function
5181 (Set_Current_Object_Path_File_Of): New procedure
5182 (Current_Source_Object_File_Of): New function
5183 (Set_Current_Object_Path_File_Of): New procedure
5184 * prj.ads (Set_Path_File_Var): New procedure moved from Prj.Env
5185 (Current_Source_Path_File_Of): New function
5186 (Set_Current_Object_Path_File_Of): New procedure
5187 (Current_Source_Object_File_Of): New function
5188 (Set_Current_Object_Path_File_Of): New procedure
5189
51902011-08-29 Ed Schonberg <schonberg@adacore.com>
5191
5192 * exp_ch5.adb (Expand_N_Assignment_Statement): For an assignment to a
5193 packed entity, use a bit-field assignment only if there is no change of
5194 representation.
5195
c5ecd6b7
AC
51962011-08-29 Thomas Quinot <quinot@adacore.com>
5197
5198 * rtsfind.ads, exp_ch3.adb (In_Runtime): Minor code improvement, use
5199 Is_RTU instead of using Chars comparisons.
5200
52012011-08-29 Thomas Quinot <quinot@adacore.com>
5202
5203 * exp_strm.adb (Build_Mutable_Record_Read_Procedure): Do not create a
5204 temporary object if the actual is constrained, and the discriminants
5205 read from the stream don't match.
5206
52072011-08-29 Tristan Gingold <gingold@adacore.com>
5208
5209 * sem_attr.adb, exp_attr.adb: Add handling of
5210 Attribute_System_Allocator_Alignment
5211 * snames.ads-tmpl: Add Name_System_Allocator_Alignment and
5212 Attribute_System_Allocator_Alignment.
5213 * ttypes.ads, get_targ.ads: Add Get_System_Allocator_Alignment.
5214 * gcc-interface/targtyps.c, gcc-interface/utils2.c,
5215 gcc-interface/gigi.h: Renames get_target_default_allocator_alignment to
5216 get_target_system_allocator_alignment.
5217
52182011-08-29 Arnaud Charlet <charlet@adacore.com>
5219
5220 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
5221 dependencies.
5222
8abdac29
AC
52232011-08-29 Arnaud Charlet <charlet@adacore.com>
5224
5225 * exp_ch3.adb (In_Runtime): Fix typo.
5226
df170605
AC
52272011-08-29 Bob Duff <duff@adacore.com>
5228
5229 * sem_ch4.adb (Analyze_Allocator): Analyze the subpool specification.
5230
52312011-08-29 Ed Schonberg <schonberg@adacore.com>
5232
5233 * exp_ch3.adb (Expand_N_Object_Declaration): If the entity is tagged
5234 and a separate tag assignment is generated, ensure that the tag
5235 assignment is analyzed.
5236
864a4236
ES
52372011-08-29 Ed Schonberg <schonberg@adacore.com>
5238
5239 * atree.ads, atree.adb (Copy_Separate_List): New function that applies
5240 Copy_Separate_Tree to a list of nodes. Used to create disjoint copies
5241 of statement lists that may contain local declarations.
df170605
AC
5242 * exp_ch9.adb (Expand_N_Timed_Entry_Call): Use Copy_Separate_List to
5243 duplicate the triggering statements needed for the expansion of this
5244 construct, when the trigger is a dispatching call to a synchronized
5245 primitive.
864a4236 5246
7f394c1d
AC
52472011-08-29 Arnaud Charlet <charlet@adacore.com>
5248
5249 * gnat_rm.texi: Add doc for 'Elab_Subp_Body.
5250 * bindgen.adb: Add comments.
5251 * snames.adb-tmpl (Is_Attribute_Name): Only recognize 'Elab_Subp_Body
5252 in CodePeer mode.
5253
2c1a2cf3
RD
52542011-08-29 Robert Dewar <dewar@adacore.com>
5255
5256 * exp_attr.adb: Minor reformatting.
5257 Minor code reorganization and commenting.
5258 * par_sco.adb, checks.adb, sem_attr.adb, get_scos.adb: Minor
5259 reformatting.
5260
0bfc9a64
AC
52612011-08-29 Thomas Quinot <quinot@adacore.com>
5262
5263 * get_scos.adb: Ignore chaining indicators not currently supported
5264 by Ada.
5265
52662011-08-29 Arnaud Charlet <charlet@adacore.com>
5267
5268 * system.ads: Minor editing.
5269
52702011-08-29 Arnaud Charlet <charlet@adacore.com>
5271
5272 * bindgen.adb (Gen_Elab_Calls): Generate calls to subp'Elab_Subp_Body in
5273 CodePeer mode.
5274 * sem_attr.ads, sem_attr.adb, exp_Attr.adb, sem_ch6.adb: Add handling of
5275 Attribute_Elab_Subp_Body.
5276 * snames.ads-tmpl (Attribute_Elab_Subp_Body, Name_Elab_Subp_Body): New.
5277 * sem_util.adb: Update comments.
5278
828d4cf0
TQ
52792011-08-29 Thomas Quinot <quinot@adacore.com>
5280
5281 * par_sco.adb, scos.adb, scos.ads, put_scos.adb, get_scos.adb: Record
5282 pragma name for each SCO statement corresponding to a pragma.
5283
5cd7bb15
AC
52842011-08-29 Arnaud Charlet <charlet@adacore.com>
5285
5286 * opt.ads: Minor editing.
5287
52882011-08-29 Yannick Moy <moy@adacore.com>
5289
5290 * gnat1drv.adb (Adjust_Global_Switches): Remove options for ALFA mode
5291 that only made sense for CodePeer mode.
5292
52932011-08-29 Jose Ruiz <ruiz@adacore.com>
5294
5295 * targparm.ads (Support_64_Bit_Divides_On_Target): Remove this flag
5296 which is no longer used.
5297 * targparm.adb (S64, S64_Str, Get_Target_Parameters): Remove the
5298 handling of the 64-bit division check.
5299 * exp_ch4.adb (Expand_N_Op_Divide): Remove the check for 64-bit
5300 division available.
5301 * system*.ads (Support_64_Bit_Divides): Remove this flag which is no
5302 longer used.
5303
53042011-08-29 Thomas Quinot <quinot@adacore.com>
5305
5306 * get_scos.adb: Minor reformatting.
5307
25b589cb
AC
53082011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5309
5310 * exp_util.adb (Process_Statements_For_Controlled_Objects): Whenever a
5311 statement list is wrapped in a block, the block is explicitly analyzed
5312 in order to properly redecorate the entities and create a servicing
5313 finalizer.
5314
53152011-08-29 Tristan Gingold <gingold@adacore.com>
5316
5317 * sinfo.ads, sinfo.adb (Zero_Cost_Handling): Remove.
5318 (Set_Zero_Cost_Handling): Remove.
5319
53202011-08-29 Thomas Quinot <quinot@adacore.com>
5321
5322 * par_sco.adb, scos.ads, put_scos.adb, get_scos.adb: Minor reformatting
5323
1197ddb1
AC
53242011-08-29 Geert Bosch <bosch@adacore.com>
5325
5326 * s-vaflop-vms-alpha.adb (Neg_F): Use subtraction instead of negation
5327 instruction, as the latter may produce -0.0, which is not a valid VAX
5328 F float number.
5329 (Neg_G): Likewise for VAX F float.
5330
53312011-08-29 Robert Dewar <dewar@adacore.com>
5332
5333 * exp_util.adb: Minor reformatting.
5334
53352011-08-29 Yannick Moy <moy@adacore.com>
5336
5337 * sem_ch3.adb: Minor comment update.
5338
53392011-08-29 Thomas Quinot <quinot@adacore.com>
5340
5341 * checks.adb (Apply_Type_Conversion_Checks): Use the Underlying_Type of
5342 the operand type.
5343
53442011-08-29 Thomas Quinot <quinot@adacore.com>
5345
5346 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not flush
5347 current statement sequence on a generic instantiation or a subprogram
5348 declaration.
5349
8f66cda7
AC
53502011-08-29 Robert Dewar <dewar@adacore.com>
5351
5352 * sem_type.adb, einfo.ads, freeze.adb, exp_ch4.adb, sem_ch13.adb:
5353 Minor reformatting.
5354
53552011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5356
5357 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
5358 Correct the check which involves the freeze node of a controlled or
5359 access-to-controlled type.
5360
53612011-08-29 Geert Bosch <bosch@adacore.com>
5362
5363 * sem_warn.adb (Check_Code_Statement): Remove check for consecutive Asm
5364 statements.
5365 * s-vaflop-vms-alpha.adb: Remove bogus Volatile => True arguments from
5366 Asm statements.
5367
cf161d66
AC
53682011-08-29 Yannick Moy <moy@adacore.com>
5369
5370 * sem_ch3.adb (Array_Type_Declaration): Insert a subtype declaration
5371 for every index type and component type that is not a subtype_mark.
5372 (Process_Subtype): Set Etype of subtype.
5373
53742011-08-29 Robert Dewar <dewar@adacore.com>
5375
5376 * a-cbmutr.adb, a-cimutr.adb, a-comutr.adb, prj-nmsc.adb: Minor code
5377 reorganization. Minor reformatting.
5378
7cc83cd8
AC
53792011-08-29 Steve Baird <baird@adacore.com>
5380
5381 * exp_ch4.adb (Expand_N_Op_Expon): Suppress N_Op_Expon node expansion
5382 for CodePeer and ALFA modes.
5383
53842011-08-29 Ed Schonberg <schonberg@adacore.com>
5385
5386 * sem_type.adb (Collect_Interps): Within an instance, collect a homonym
5387 that comes from an enclosing scope if it is not the renaming of an
5388 actual, to handle properly a spurious ambiguity in an instance.
5389
76af4137
AC
53902011-08-29 Eric Botcazou <ebotcazou@adacore.com>
5391
5392 * sem_ch13.adb (Alignment_Check_For_Esize_Change): Rename to...
5393 (Alignment_Check_For_Size_Change): ...this. Add SIZE parameter and
5394 use it instead of the Esize of the first parameter.
5395 (Analyze_Attribute_Definition_Clause) <Object_Size>: Adjust call to
5396 above change.
5397 <Size>: Likewise. Call it for composite types on the RM size.
5398
53992011-08-29 Yannick Moy <moy@adacore.com>
5400
5401 * exp_ch4.adb (Expand_N_Op_Not): Do not expand not on array.
5402 * sem_util.adb (Unique_Name): Correct behaviour for names of
5403 compilation units.
5404
9b20e59b
AC
54052011-08-29 Yannick Moy <moy@adacore.com>
5406
5407 * sem_prag.adb (Check_Precondition_Postcondition): In formal
5408 verification mode, analyze pragma expression for correctness, for
5409 pre/post on library-level subprogram, as it is not expanded later.
5410
54112011-08-29 Yannick Moy <moy@adacore.com>
5412
5413 * exp_aggr.adb (Expand_Array_Aggregate): Do not expand array aggregates
5414 in formal verification.
5415
54162011-08-29 Thomas Quinot <quinot@adacore.com>
5417
5418 * sem_util.adb: Minor reformatting.
5419 * freeze.adb, sem_ch13.adb: Fix comment: Bit_Order is an attribute,
5420 there's no pragma.
5421 * par_sco.ads, par_sco.adb: Update comments.
5422
54232011-08-29 Yannick Moy <moy@adacore.com>
5424
5425 * einfo.adb, einfo.ads: Remove flag Is_Postcondition_Proc and
5426 associated getter/setter.
5427 * sem_ch6.adb: Remove reference to Is_Postcondition_Proc.
5428
54292011-08-29 Vincent Celier <celier@adacore.com>
5430
5431 * prj-attr.adb: New Compiler attribute Dependency_Kind and Language_Kind
5432 * prj-conf.adb: Add_Default_GNAT_Naming_Scheme: Add a package Compiler
5433 with declarations for Language_Kind and Dependency_Kind for Ada.
5434 * prj-nmsc.adb (Check_Unit_Name): New name of procedure Check_Ada_Name
5435 (Process_Compiler): Take into account the new attributes Dependency_Kind
5436 and Language_Kind.
5437 (Check_Configuration): Check if language kind is unit based, not if the
5438 language name is Ada.
5439 (Process_Exceptions_Unit_Based): Ditto
5440 (Add_Language): Remove default additions of language and dependency kind
5441 * prj.ads: Minor comment change
5442 * snames.ads-tmpl: New standard names Dependency_Kind and Language_Kind
5443
54442011-08-29 Johannes Kanig <kanig@adacore.com>
5445
5446 * debug.adb: Update comments.
5447
c5bc3df6
JM
54482011-08-24 Joseph Myers <joseph@codesourcery.com>
5449
5450 * gcc-interface/Make-lang.in (CFLAGS-ada/tracebak.o)
5451 (CFLAGS-ada/targext.o, CFLAGS-ada/cio.o, CFLAGS-ada/init.o)
5452 (CFLAGS-ada/initialize.o, CFLAGS-ada/raise.o): New.
5453 (ada/tracebak.o, ada/targext.o, ada/cio.o, ada/init.o)
5454 (ada/initialize.o, ada/raise.o): Remove explicit compilation rules.
5455
e3aa9eba
RO
54562011-08-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5457
5458 * gcc-interface/Makefile.in (PICFLAG_FOR_TARGET): New.
5459 (GNATLIBCFLAGS_FOR_C): Replace
5460 TARGET_LIBGCC2_CFLAGS by PICFLAG_FOR_TARGET.
5461 (gnatlib-shared-default, gnatlib-shared-dual-win32)
5462 (gnatlib-shared-win32, gnatlib-shared-darwin, gnatlib-shared)
5463 (gnatlib-sjlj, gnatlib-zcx): Likewise.
5464
f446d60e
EB
54652011-08-07 Eric Botcazou <ebotcazou@adacore.com>
5466
5467 * gcc-interface/Makefile.in (raise-gcc.o): Fix previous change.
5468
588c8f48
EB
5469 * gcc-interface/gigi.h (enumerate_modes): Fix formatting.
5470
5471 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Revert latest change.
5472
28d711bf
NR
54732011-08-05 Nicolas Roche <roche@adacore.com>
5474
5475 * gcc-interface/Makefile.in: Don't use directly ../xgcc to build shared
5476 libgnat. Use rather the value of GCC_FOR_TARGET. Fix issue with
5477 canadian cross.
5478 * gcc-interface/Make-lang.in: Add support for canadian cross setting.
5479
993f8920
AC
54802011-08-05 Matthew Heaney <heaney@adacore.com>
5481
5482 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Child_Count, Child_Depth):
5483 subprogram bodies declared out-of-order.
5484
54852011-08-05 Yannick Moy <moy@adacore.com>
5486
5487 * sem_util.adb (Unique_Name): only prefix with "standard" the names of
5488 entities directly in package Standard, otherwise skip the standard
5489 prefix.
5490
9b3956dd
RD
54912011-08-05 Robert Dewar <dewar@adacore.com>
5492
5493 * a-cbmutr.adb: Minor reformatting
5494 (Allocate_Node): refactor node allocation algorithm
5495
54962011-08-05 Robert Dewar <dewar@adacore.com>
5497
5498 * opt.ads, opt.adb (Debug_Pragmas_Disabled): New switch.
5499 * sem_prag.adb (Analyze_Pragma, case Debug_Policy): Implement Disable
5500 mode.
5501 (Analyze_Pragma, case Check_Policy): Ditto.
5502 * sem_prag.ads (Check_Disabled): New function
5503 * snames.ads-tmpl: Add Name_Disable.
5504
55052011-08-05 Robert Dewar <dewar@adacore.com>
5506
5507 * gnat_rm.texi: Document implementation-defined policy DISABLE for
5508 pragmas Assertion_Policy, Check_Policy, Debug_Policy.
5509
79e705d6
AC
55102011-08-05 Ed Schonberg <schonberg@adacore.com>
5511
5512 * sem_prag.adb (Analyze_Pragma, case Inline): reject an Inline pragma
5513 that appears in a generic formal part and applies to a formal
5514 subprogram.
5515
55162011-08-05 Robert Dewar <dewar@adacore.com>
5517
5518 * a-cbmutr.ads: Minor reformatting.
5519
23b6deca
AC
55202011-08-05 Matthew Heaney <heaney@adacore.com>
5521
5522 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Read): do not use T'Valid
5523 to check count, check sign of value instead.
5524 * a-comutr.adb, a-cimutr.adb (Write): return immediately if tree empty
5525 (Copy_Subtree): allocate copy of source element
5526 (Equal_Subtree): compare elements, not access objects
5527
55282011-08-05 Vincent Celier <celier@adacore.com>
5529
5530 * gnat_ugn.texi: Fix VMS alternative.
5531
a2773bd3
AC
55322011-08-05 Thomas Quinot <quinot@adacore.com>
5533
5534 * sem_ch11.adb: Add comment.
5535
55362011-08-05 Robert Dewar <dewar@adacore.com>
5537
5538 * exp_util.adb: Minor comment fix.
5539
55402011-08-05 Robert Dewar <dewar@adacore.com>
5541
5542 * scng.adb (Error_Unterminated_String): Improve flag position when
5543 comma present.
5544
55452011-08-05 Matthew Heaney <heaney@adacore.com>
5546
5547 * Makefile.rtl, impunit.adb: Added a-cbmutr.ad[sb] (bounded multiway
5548 tree containers).
5549 * a-cbmutr.ads, a-cbmutr.adb: This is the new Ada 2012 unit for bounded
5550 multiway tree containers.
5551
55522011-08-05 Robert Dewar <dewar@adacore.com>
5553
5554 * styleg.adb (Check_Comment): Implement comment spacing of 1 or 2
5555 * stylesw.adb: Implement -gnatyC to control comment spacing
5556 * stylesw.ads (Style_Check_Comments_Spacing): New switch (set by
5557 -gnatyc/C).
5558 * usage.adb: Add line for -gnatyC.
5559
55602011-08-05 Robert Dewar <dewar@adacore.com>
5561
f446d60e 5562 * gnat_ugn.texi: Document -gnatyC.
a2773bd3
AC
5563 * vms_data.ads: Implement COMMENTS1/COMMENTS2 (retaining COMMENTS as a
5564 synonym for COMMENTS2).
5565
dedac3eb
RD
55662011-08-05 Robert Dewar <dewar@adacore.com>
5567
5568 * par_sco.adb, sem_ch3.adb, scos.ads, a-iteint.ads, sem_ch12.adb,
5569 a-cimutr.adb, a-cimutr.ads, sem_util.ads, sem_res.adb, a-fihema.adb,
5570 sem_ch4.adb, lib-xref-alfa.adb, exp_disp.adb, a-comutr.adb,
5571 a-comutr.ads, lib-xref.adb: Minor reformatting.
5572
55732011-08-05 Robert Dewar <dewar@adacore.com>
5574
5575 * sem_ch11.adb (Analyze_Raise_Statement): Kill assignment to formal
5576 warning if there is an exception handler present.
5577
7c62a85a
AC
55782011-08-05 Pascal Obry <obry@adacore.com>
5579
5580 * a-iteint.ads: Fix copyright year.
5581
55822011-08-05 Thomas Quinot <quinot@adacore.com>
5583
5584 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not generate a
5585 statement SCO for a USE clause or a representation clause.
5586
55872011-08-05 Yannick Moy <moy@adacore.com>
5588
5589 * lib-xref-alfa.adb (Collect_ALFA): generate the proper relation
5590 between body and spec for stub.
5591 (Detect_And_Add_ALFA_Scope): take into account subprogram stub
5592 * lib-xref.adb (Enclosing_Subprogram_Or_Package): in the case of a
5593 pragma precondition or postcondition, for which the enclosing
5594 subprogram or package in the AST is not the desired one, return empty.
5595
e49208a9
AC
55962011-08-05 Thomas Quinot <quinot@adacore.com>
5597
5598 * g-expect.adb: Minor reformatting.
5599
56002011-08-05 Bob Duff <duff@adacore.com>
5601
5602 * a-fihema.adb: Comment out OS_Lib.
5603
56042011-08-05 Matthew Heaney <heaney@adacore.com>
5605
5606 * Makefile.rtl, impunit.adb: Added a-c[oi]mutr.ad[sb]
5607 (unbounded multiway tree containers) and a-iteint.ads.
5608 * a-comutr.ads, a-comutr.adb:
5609 This is the new Ada 2012 unit for unbounded multiway tree containers
5610 * a-cimutr.ads, a-cimutr.adb
5611 This is the new Ada 2012 unit for indefinite multiway tree containers
5612 * a-iteint.ads: New file.
5613
201cdb74
RO
56142011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5615
f446d60e 5616 * gcc-interface/Makefile.in (raise-gcc.o): Search $(srcdir)/../libgcc.
201cdb74 5617
d50f4827
AC
56182011-08-05 Bob Duff <duff@adacore.com>
5619
5620 * sinfo.ads, sinfo.adb (Subpool_Handle_Name): New attribute for
5621 subpools.
5622 * par-ch4.adb (P_Allocator): Parse new subpool specification syntax.
5623
56242011-08-05 Ed Schonberg <schonberg@adacore.com>
5625
5626 * sem_ch4.adb (Try_Container_Indexing): New procedure to implement the
5627 general indexing aspects of Ada2012. Called when analyzing indexed
5628 components when other interpretations fail.
5629 * sem_ch8.adb (Find_Direct_Name): check for implicit dereference only
5630 in an expression context where overloading is meaningful. This excludes
5631 the occurrence in an aspect specification (efficiency only).
5632 * sem_attr.adb (Analyze_Attribute): indicate that the attributes
5633 related to iterators can be set by an attribute specification, but
5634 cannot be queried.
5635 * sem_ch13.adb (Analyze_Aspect_Specifications): handle
5636 Constant_Indexing and Variable_Indexing.
5637 (Check_Indexing_Functions): New procedure to perform legality checks.
5638 Additional semantic checks at end of declarations.
5639
efe05dfc
AC
56402011-08-05 Sergey Rybin <rybin@adacore.com>
5641
5642 * tree_io.ads: Update ASIS_Version_Number because of the change of the
5643 order of calling Tree_Write/Tree_Read routines made for aspects.
5644
56452011-08-05 Bob Duff <duff@adacore.com>
5646
5647 * a-fihema.adb (Finalize): Fix race condition.
5648
5f9cdefe
AC
56492011-08-05 Yannick Moy <moy@adacore.com>
5650
5651 * sem_ch12.adb (Analyze_Package_Instantiation,
5652 Need_Subprogram_Instance_Body): do not generate instance bodies in ALFA
5653 mode.
5654
56552011-08-05 Ed Schonberg <schonberg@adacore.com>
5656
5657 * sem_type.adb (Specific_Type): in an instance, the type-specific
5658 operand of an equality check that involves null may have a private
5659 type. Use full view to determine legality of construct.
5660
822868aa
AC
56612011-08-05 Vincent Celier <celier@adacore.com>
5662
5663 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
5664 delete or close the file when the call to gnatmake was successful.
5665
56662011-08-05 Yannick Moy <moy@adacore.com>
5667
5668 * gnat1drv.adb (Adjust_Global_Switches): in ALFA mode, set
5669 Global_Discard_Names.
5670
56712011-08-05 Ed Schonberg <schonberg@adacore.com>
5672
5673 * sinfo.ads: comments on use of entity field for aspect specifications.
5674
56752011-08-05 Ed Schonberg <schonberg@adacore.com>
5676
5677 * sem_ch12.adb (Reset_Entity): If the entity field of the associated
5678 node is not itself an entity but a selected component, it is a
5679 rewritten parameterless call to an en enclosing synchronized operation,
5680 and this expansion will be performed again in the instance, so there is
5681 no global information to preserve.
5682
44a10091
AC
56832011-08-05 Javier Miranda <miranda@adacore.com>
5684
5685 * exp_disp.adb (Set_All_DT_Position): Cleanup code and improve support
5686 for renamings of predefined primitives.
5687 (In_Predef_Prims_DT): New subprogram.
5688
56892011-08-05 Ed Schonberg <schonberg@adacore.com>
5690
5691 * sem_util.adb, sem_util.ads (Check_Implicit_Dereference): If a
5692 possible interpretation of name is a reference type, add an
5693 interpretation that is the designated type of the reference
5694 discriminant of that type.
5695 * sem_res.adb (resolve): If the interpretation imposed by context is an
5696 implicit dereference, rewrite the node as the deference of the
5697 reference discriminant.
5698 * sem_ch3.adb (Analyze_Subtype_Declaration, Build_Derived_Record_Type,
5699 Build_Discriminated_Subtype): Inherit Has_Implicit_Dereference from
5700 parent type or base type.
5701 * sem_ch4.adb (Process_Indexed_Component,
5702 Process_Overloaded_Indexed_Component, Indicate_Name_And_Type,
5703 Analyze_Overloaded_Selected_Component, Analyze_Selected_Component):
5704 Check for implicit dereference.
5705 (List_Operand_Interps): Indicate when an implicit dereference is
5706 ambiguous.
5707 * sem_ch8.adb (Find_Direct_Name): Check for implicit dereference.
5708
57092011-08-05 Thomas Quinot <quinot@adacore.com>
5710
5711 * scos.ads: Update documentation of SCO table. Pragma statements can now
5712 be marked as disabled (using 'p' instead of 'P' as the statement kind).
5713 * par_sco.ads, par_sco.adb: Implement the above change.
5714 (Process_Decisions_Defer): Generate a P decision for the first parameter
5715 of a dyadic pragma Debug.
5716 * sem_prag.adb (Analyze_Pragma, case Debug): Mark pragma as enabled if
5717 necessary.
5718 * put_scos.adb: Code simplification based on above change.
5719
bb3c784c
AC
57202011-08-05 Robert Dewar <dewar@adacore.com>
5721
5722 * sem_ch3.adb, gnatcmd.adb, switch-c.adb, exp_attr.adb, make.adb,
5723 bindgen.adb, einfo.adb, sem_ch12.adb, sem_attr.adb, a-fihema.adb,
5724 a-fihema.ads, sem_elab.adb, sem_elab.ads, aspects.adb, opt.ads,
5725 prj-conf.adb, sem_ch13.adb, s-ficobl.ads: Minor reformatting
5726
57272011-08-05 Bob Duff <duff@adacore.com>
5728
5729 * a-stunau.ads, g-spipat.adb: Update comments.
5730
36f686f9
BD
57312011-08-05 Bob Duff <duff@adacore.com>
5732
5733 * a-fihema.ads: Minor comment fix.
5734 * a-fihema.adb (Allocate, Deallocate): Assert that the alignment is
5735 correct.
5736 (Attach, Detach): Remove some unnecessary code.
5737 (Finalize): Remove Node_Ptr_To_Address, replace with a constant.
5738
7882673f
BD
57392011-08-05 Bob Duff <duff@adacore.com>
5740
5741 * a-fihema.ads, a-fihema.adb (Finalization_Collection): Avoid heap
5742 allocation for Objects component. This simplifies the code somewhat. It
5743 is also a little more efficient in the not-so-unusual case where there
5744 are no controlled objects allocated.
5745 Make Finalization_Started flag atomic.
5746 (Finalize): Avoid unnecessary detachment of items from the list.
5747 (pcol): Minor cleanup.
5748
d34cd274
AC
57492011-08-05 Ed Schonberg <schonberg@adacore.com>
5750
5751 * sem_ch12.adb (Analyze_Formal_Package_Declaration): reject a formal
5752 package whose name is the same as that of the generic unit, or its
5753 ultimate prefix.
5754
57552011-08-05 Bob Duff <duff@adacore.com>
5756
5757 * a-fihema.adb, a-fihema.ads: Minor comment improvements.
5758 * sem_ch3.adb, exp_ch5.adb, exp_ch7.adb, exp_ch7.ads, exp_util.adb:
5759 Minor comment fixes.
5760
00332244
AC
57612011-08-05 Arnaud Charlet <charlet@adacore.com>
5762
5763 * make.adb (Linking_Phase): No longer need to set source search path
5764 before calling gnatlink in CodePeer mode.
5765 * gnatlink.adb (Gnatlink): No longer pass -gnat83/95/05/12 switch to
5766 gcc in CodePeer mode, since the binder generated file no longer has a
5767 'with Main'.
5768 * switch.ads, switch.adb (Is_Language_Switch): Removed.
5769 * switch-c.adb: Update comment.
5770
57712011-08-05 Thomas Quinot <quinot@adacore.com>
5772
5773 * exp_strm.adb, bindgen.adb, s-ficobl.ads: Minor reformatting.
5774
57752011-08-05 Nicolas Roche <roche@adacore.com>
5776
5777 * gnat_ugn.texi: Fix minor syntax error issue.
5778
57792011-08-05 Vincent Celier <celier@adacore.com>
5780
5781 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
5782 delete or close the file when the call to gnatmake returns a non
5783 successful return code.
5784
57852011-08-05 Ed Schonberg <schonberg@adacore.com>
5786
5787 * exp_ch4.adb (Expand_N_Type_Conversion): When expanding a predicate
5788 check, indicate that the copy of the original node does not come from
5789 source, to prevent an infinite recursion of the expansion.
5790
57912011-08-05 Johannes Kanig <kanig@adacore.com>
5792
5793 * debug.adb: document switch -gnatd.G for gnat2why, which deactivates
5794 VC generation for subprogram bodies.
5795
57962011-08-05 Yannick Moy <moy@adacore.com>
5797
5798 * einfo.ads: Typo.
5799 * sem_ch3.adb (Signed_Integer_Type_Declaration): in ALFA mode, define
5800 the base type with the smallest allowed base type.
5801
58022011-08-05 Sergey Rybin <rybin@adacore.com>
5803
5804 * tree_gen.adb, tree_in.adb, aspects.adb: Fix tree read-write for
5805 aspects.
5806
58072011-08-05 Ed Schonberg <schonberg@adacore.com>
5808
5809 * sem_ch12.ads: minor comment updates.
5810
58112011-08-05 Ed Schonberg <schonberg@adacore.com>
5812
5813 * sem_ch12.adb (Analyze_Formal_Package_Declaration): in an
5814 instantiation and a formal package the compiler generates a package
5815 renaming declaration so that the generic name within the declaration
5816 is interpreted as a renaming of the instance. At the end of a formal
5817 package declaration, this renaming must become invisible.
5818
0da80d7d
AC
58192011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
5820
5821 * exp_ch7.adb (Is_Init_Call): Reimplemented to avoid character
5822 comparison and rely on concrete entities instead.
5823
58242011-08-05 Ed Schonberg <schonberg@adacore.com>
5825
5826 * einfo.ads, einfo.adb (Has_Implicit_Dereference): new flag on types
5827 and discriminants, to indicate that the type has an access discriminant
5828 that supports implicit dereference.
5829 * snames.ads-tmpl: Add names of aspects and attributes related to
5830 Ada2012 iterators: constant_indexing, default_iterator,
5831 iterator_element, implicit_dereference, variable_indexing.
5832 * aspects.ads, aspects.adb: entries for iterator-related aspects.
5833 * sem_ch13.adb (Analyze_aspect_specifications): dummy entries for
5834 iterator-related aspects.
5835 * sem_attr.adb, exp_attr.adb Dummy entries for iterator-related aspects.
5836
58372011-08-05 Sergey Rybin <rybin@adacore.com>
5838
5839 * gnat_ugn.texi, vms_data.ads: Extend the subsection about coupling
5840 metrics in gnatmetric to cover new kinds of coupling mentrics.
5841
58422011-08-05 Steve Baird <baird@adacore.com>
5843
5844 * bindgen.adb (Gen_CodePeer_Wrapper): Call Ada_Main_Program instead
2c7f9cc0 5845 of calling the user-defined main subprogram.
0da80d7d
AC
5846 (Gen_Main): Declare Ada_Main_Program and (if CodePeer_Mode
5847 is set) Call_Main_Subprogram ahead of, as opposed to
5848 inside of, Main.
5849 (Gen_Output_File_Ada): Remove CodePeer_Mode-conditional
5850 generation of a "with" of the user-defined main subprogram.
5851 Remove CodePeer_Mode-conditional call to Gen_CodePeer_Wrapper
5852 (which is now called from Gen_Main instead).
5853
73242473
AC
58542011-08-05 Emmanuel Briot <briot@adacore.com>
5855
5856 * projects.texi: Added reference to the Makefile package.
5857
58582011-08-05 Thomas Quinot <quinot@adacore.com>
5859
5860 * exp_ch7.adb: Minor comment rewording.
5861
58622011-08-05 Ed Falis <falis@adacore.com>
5863
5864 * env.c: Fix comment.
5865
58662011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
5867
5868 * sem_elab.adb (Is_Finalization_Procedure): Reimplemented to avoid
5869 character comparison and rely on concrete entities instead.
5870
97ed5872
AC
58712011-08-05 Ed Schonberg <schonberg@adacore.com>
5872
5873 * sem_ch3.adb: (Check_Private_Overriding): better error message,
5874 suggested by AI95-0068.
5875
58762011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
5877
5878 * exp_ch7.adb (Find_Last_Init): Use Next_Suitable_Statement to retrieve
5879 the two potential initialization calls. This accounts for any
5880 access-before-elaboration checks which may precede the initialization
5881 calls.
5882 (Next_Suitable_Statement): New routine. Returns the next real statement
5883 after the input node while skipping generated checks.
5884 * sem_elab.adb (Check_A_Call): New formal parameter In_Init_Proc along
5885 with comment on usage.
5886 Do not generate Elaborate_All when the trigger is a finalization call
5887 coming from a type init proc.
5888 (Check_Elab_Call): Propagate the initialization procedure context to
5889 subsequent calls to Check_A_Call.
5890 (Check_Internal_Call_Continue): Propagate the initialization procedure
5891 context to subsequent calls to Check_Elab_Call.
5892 (Is_Finalization_Procedure): New routine. Returns True if the input
5893 entity denotes a [Deep_]Finalize routine.
5894 * sem_elab.ads (Check_Elab_Call): New formal parameter In_Init_Proc
5895 along with comment on usage.
5896
58972011-08-05 Vadim Godunko <godunko@adacore.com>
5898
5899 * s-atocou.ads: Add list of supported platforms.
5900
59012011-08-05 Yannick Moy <moy@adacore.com>
5902
5903 * sem_prag.adb, restrict.adb: Correct style for or'ing Boolean variables
5904
5905 * opt.ads (Disable_ALI_File): new Boolean flag
5906 * lib-writ.adb (Write_ALI): when Disable_ALI_File is set, do nothing
5907
59082011-08-05 Ed Falis <falis@adacore.com>
5909
5910 * env.c (__gnat_environ): Fix includes for RTPs and VTHREADS so that
5911 environ is properly defined.
5912
59132011-08-05 Vincent Celier <celier@adacore.com>
5914
5915 * make.adb (Compilation_Phase): Exit immediately when all objects have
5916 been found up to date, to avoid multiple exit messages.
5917 * prj-nmsc.adb (Add_Source): Allow duplicate source file names in the
5918 same project for languages with no compiler.
5919 * gnat_ugn.texi: Document compiler switch -gnateI and gnatmake switch
5920 -eI.
9aff36e9
RD
59212011-08-05 Robert Dewar <dewar@adacore.com>
5922
5923 * exp_ch7.ads, sem_type.adb, make.adb, sem_prag.adb, sem_util.adb,
5924 sem_util.ads, sem_attr.adb, restrict.ads, sem_ch6.adb, prj-conf.adb,
5925 prj-conf.ads, s-atocou.ads, s-atocou.adb, s-atocou-x86.adb,
5926 s-atocou-builtin.adb: Minor reformatting.
5927
406935b6
AC
59282011-08-05 Yannick Moy <moy@adacore.com>
5929
5930 * exp_ch7.adb (Establish_Transient_Scope): in formal verification mode,
5931 if the node to wrap is a pragma check, this node and enclosed
5932 expression are not expanded, so do not apply any transformations here.
5933 * exp_prag.adb (Expand_Pragma_Check): document the need to avoid
5934 introducing transient scopes.
5935
59362011-08-05 Jose Ruiz <ruiz@adacore.com>
5937
5938 * adaint.c (__gnat_set_writable, __gnat_set_readable,
5939 __gnat_set_executable, __gnat_set_non_writable, __gnat_set_non_readable,
5940 __gnat_copy_attribs): On VxWorks 6.x and later, the required chmod
5941 routine is available, so we use the default implementation of these
5942 functions.
5943 * s-os_lib.ads (Copy_File, Copy_Time_Stamps): Document that there is
5944 support for copying attributes on VxWorks 6.
5945
59462011-08-05 Yannick Moy <moy@adacore.com>
5947
5948 * debug.adb: Remove use of -gnatd.D.
5949 * gnat1drv.adb (Adjust_Global_Switches): adjust switches for ALFA mode
5950 * opt.ads: Simplify variables for ALFA mode, to keep one only
5951 * restrict.adb, sem_prag.adb: Adapt treatment done for CodePeer mode
5952 to ALFA mode.
5953
59542011-08-05 Vincent Celier <celier@adacore.com>
5955
5956 * prj-conf.adb (Do_Autoconf): Look also for --RTS in
5957 Builder'Default_Switches.
5958
59592011-08-05 Vincent Celier <celier@adacore.com>
5960
5961 * makeusg.adb: Add lines for --create-map-file switches.
5962
59632011-08-05 Ed Schonberg <schonberg@adacore.com>
5964
5965 * freeze.adb (Freeze_Entity): For a subprogram, if a type in the
5966 profile is incomplete and the full view is available, replace it with
5967 the full view.
5968 * sem_ch6.adb (Possible_Freeze): if a type in the profile is
5969 incomplete, freezing the subprogram is delayed until the full view is
5970 frozen.
5971 * sem_type.adb (Disambiguate): an ambiguity between a user-defined
5972 fixed-point multiplication operator and the predefined operator is
5973 resolved in favor of the user-defined one.
5974
96c891b3
RO
59752011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5976
5977 * init.c [__alpha__ && __osf__] (__gnat_error_handler): Use
5978 CONST_CAST.
5979
276e7ed0
AC
59802011-08-04 Ed Schonberg <schonberg@adacore.com>
5981
5982 * sem_util.ads, sem_unit.adb (Type_Without_Stream_Operation): determine
5983 whether a type lacks user-defined Read or Write operations, or has a
5984 component that lacks them.
5985 * sem_attr.adb (Check_Stream_Attribute): if restriction
5986 No_Default_Stream_Attributes is active, verify that all subcomponent
5987 types of the target have user-defined stream operations, and report
5988 error otherwise.
5989 * exp_ch3.adb (Stream_Operqtion_OK): use Type_Without_Stream_Operation.
5990 * exp_strm.adb: Build_Elementary_Input_Call,
5991 Build_Elementary_Write_Call): remove checks for restriction
5992 No_Default_Stream_Attributes, now checked in semantics.
5993
59942011-08-04 Vincent Celier <celier@adacore.com>
5995
5996 * prj-conf.ads, prj-conf.adb (Do_Autoconf): If there is no --RTS
5997 switches on the command line, look for all valid --RTS switches in the
5998 Builder switches and for each language use the first runtime name found
5999 to invoke gprconfig.
6000 (Get_Or_Create_Configuration_File): Warn if --RTS is specified on the
6001 command line and there is no auto-configuration.
6002 (Runtime_Name_Set_For): New function.
6003
60042011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6005
6006 * exp_ch7.adb (Build_Object_Declarations): Do not generate the
6007 elaborate initialization expression for variable Abort when processing
6008 a package body or a declaration.
6009 (Create_Finalizer): Propagate the package context when creating the
6010 exception-related variables.
6011 * exp_ch7.ads (Build_Object_Declarations): New formal parameter
6012 For_Package along with usage comment.
6013
19172ae9
AC
60142011-08-04 Arnaud Charlet <charlet@adacore.com>
6015
6016 * gcc-interface/Makefile.in: Clean up targets.
6017 Enable new package for atomic counters and copy-on-write implementation
6018 of unbounded strings on x86 platforms.
6019 * gcc-interface/Make-lang.in: Update dependencies.
6020
0319cacc
AC
60212011-08-04 Robert Dewar <dewar@adacore.com>
6022
6023 * exp_ch7.adb: Minor reformatting.
6024
60252011-08-04 Robert Dewar <dewar@adacore.com>
6026
6027 * exp_strm.adb: Minor reformatting.
6028
60292011-08-04 Vadim Godunko <godunko@adacore.com>
6030
6031 * s-atocou.adb: Replace by dummy version and use on targets where atomic
6032 operations are not supported.
6033 * s-atocou-builtin.adb: Renamed from s-atocou.adb.
6034 * s-atocou-x86.adb: New file.
6035 * Makefile.rtl: Add s-atocou.o file
6036
60372011-08-04 Arnaud Charlet <charlet@adacore.com>
6038
6039 * make.adb (Compile): Move setting of CodePeer_Mode to ...
6040 (Compilation_Phase): ... here.
6041 (Scan_Make_Arg): Now bind and link by default in CodePeer mode.
6042
60432011-08-04 Thomas Quinot <quinot@adacore.com>
6044
6045 * Make-generated.in: Fix minor typo in comment.
6046
26e7e1a0
AC
60472011-08-04 Thomas Quinot <quinot@adacore.com>
6048
6049 * gnatls.adb: Use Prj.Env.Initialize_Default_Project_Path to retrieve
6050 the project path.
6051
60522011-08-04 Robert Dewar <dewar@adacore.com>
6053
6054 * a-coinho.adb: Minor reformatting.
6055
60562011-08-04 Robert Dewar <dewar@adacore.com>
6057
6058 * a-coinho.ads: Minor reformatting.
6059
60602011-08-04 Vadim Godunko <godunko@adacore.com>
6061
6062 * s-atocou.ads, s-atocou.adb: New files.
6063 * a-strunb-shared.ads, a-strunb-shared.adb, a-stwiun-shared.ads,
6064 a-stwiun-shared.adb, a-stzunb-shared.ads, a-stzunb-shared.adb: Remove
6065 direct use of GCC's atomic builtins and replace them by use of new
6066 atomic counter package.
6067
60682011-08-04 Ed Schonberg <schonberg@adacore.com>
6069
6070 * exp_strm.adb: better error message for No_Default_Stream_Attributes.
6071
60722011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6073
6074 * a-tags.adb (Unregister_Tag): Replace the complex address arithmetic
6075 with a call to Get_External_Tag.
6076 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on
6077 subprogram usage. Remove the guard against package declarations and
6078 bodies since Build_Cleanup_Statements is no longer invoked in that
6079 context.
6080 (Build_Components): Initialize Tagged_Type_Stmts when the context
6081 contains at least one library-level tagged type.
6082 (Build_Finalizer): New local variables Has_Tagged_Types and
6083 Tagged_Type_Stmts along with associated comments on usage. Update the
6084 logic to include tagged type processing.
6085 (Create_Finalizer): Insert all library-level tagged type unregistration
6086 code before the jump block circuitry.
6087 (Expand_N_Package_Body): Remove the call to Build_Cleanup_Statements.
6088 (Expand_N_Package_Declaration): Remove the call to
6089 Build_Cleanup_Statements.
6090 (Process_Tagged_Type_Declaration): New routine. Generate a call to
6091 unregister the external tag of a tagged type.
6092 (Processing_Actions): Reimplemented to handle tagged types.
6093 (Process_Declarations): Detect the declaration of a library-level
6094 tagged type and carry out the appropriate actions.
6095 (Unregister_Tagged_Types): Removed. The machinery has been directly
6096 merged with Build_Finalizer.
6097
7483c888
AC
60982011-08-04 Robert Dewar <dewar@adacore.com>
6099
6100 * bindgen.ads, gnatlink.adb, sem_ch4.adb, gnatbind.adb, put_alfa.adb,
6101 gnatls.adb, exp_ch3.adb: Minor reformatting.
6102
61032011-08-04 Marc Sango <sango@adacore.com>
6104
6105 * sem_attr.adb (Analyze_Attribute): Replace the message
6106 "invisible attribute of}" of the spark restriction violation in
6107 attribute reference by the simple message "invisible attribute of type".
6108 Indeed, the node value Error_Msg_Node_1 used is in conflit with the
6109 two insertion characters: '&' and '}'.
6110
61112011-08-04 Vadim Godunko <godunko@adacore.com>
6112
6113 * impunit.adb (Non_Imp_File_Names_12): Add "a-coinho".
6114 * a-coinho.ads, a-coinho.adb: New file.
6115 * Makefile.rtl: Add Ada.Containers.Indefinite_Holders.
6116
5207696c
AC
61172011-08-04 Nicolas Roche <roche@adacore.com>
6118
6119 * alfa_test.adb: Not all ali files are containing alfa information even
6120 if compiled with -gnatd.F. So suppress warning about missing ALFA
6121 information.
6122
61232011-08-04 Yannick Moy <moy@adacore.com>
6124
6125 * lib-xref-alfa.adb (Add_ALFA_Scope): use non-empty unique name for
6126 scope.
6127 * put_alfa.adb: Check that scope name is not empty.
6128
61292011-08-04 Ed Schonberg <schonberg@adacore.com>
6130
6131 * exp_ch3.adb (Stream_Operation_Ok): new predicate
6132 Needs_Elementary_Stream_Operation, to determine whether user-defined
6133 Read and Write attributes are available for the elementary components
6134 of the given type. If only the predefined attributes are available,
6135 then when restriction No_Default_Stream_Attributes is active the
6136 predefined stream attributes for the composite type cannot be created.
6137
61382011-08-04 Robert Dewar <dewar@adacore.com>
6139
6140 * bindgen.adb: Fix obsolete comments and names from Ada/C days.
6141 Put routines in alpha order
6142
2bd2d858
JR
61432011-08-04 Jose Ruiz <ruiz@adacore.com>
6144
6145 * gcc-interface/Makefile.in: Remove xenomai specific versions of system.
6146 * gcc-interface/Make-lang.in: Update dependencies.
6147
8fae6016
AC
61482011-08-04 Arnaud Charlet <charlet@adacore.com>
6149
6150 * gcc-interface/lang.opt: Add AdaWhy language, simimlar to Ada.
6151 * gcc-interface/lang-specs.h: Add handling of AdaWhy specs (calls
6152 gnat1why).
6153
a54d0eb4
AC
61542011-08-04 Robert Dewar <dewar@adacore.com>
6155
6156 * sem_ch3.adb, make.adb, a-cohata.ads, sem_prag.adb, makeutl.adb,
6157 lib-xref-alfa.adb: Minor reformatting.
6158
61592011-08-04 Marc Sango <sango@adacore.com>
6160
6161 * sem_ch12.adb (Analyze_Generic_Package_Declaration,
6162 Analyze_Generic_Subprogram_Declaration, Analyze_Package_Instantiation,
6163 Analyze_Subprogram_Instantiation): Check absence of generic in SPARK
6164 mode.
6165
61662011-08-04 Tristan Gingold <gingold@adacore.com>
6167
6168 * bindgen.adb (Gen_Adainit_C): Remove.
6169 (Gen_Adafinal_C): Ditto.
6170 (Gen_Elab_Externals_C): Ditto.
6171 (Gen_Elab_Calls_C): Ditto.
6172 (Gen_Elab_Order_C): Ditto.
6173 (Gen_Elab_Defs_C): Ditto.
6174 (Gen_Finalize_Library_C): Ditto.
6175 (Gen_Finalize_Library_Defs_C): Ditto.
6176 (Gen_Main_C): Ditto.
6177 (Gen_Output_File_C): Ditto.
6178 (Gen_Restrictions_C): Ditto.
6179 (Gen_Versions_C): Ditto.
6180 (Write_Info_Ada_C): Ditto.
6181 (Gen_Object_Files_Options): Call WBI instead of Write_Info_Ada_C
6182 (Gen_Output_File): Do not force Ada_Bind_File anymore.
6183 Always call Gen_Output_File_Ada.
6184 * gnatlink.adb (Begin_Info): Now a constant.
6185 (End_Info): Ditto.
6186 (Ada_Bind_File): Remove
6187 (Process_Args): Do not handle -A/-C. Remove not Ada_Bind_File cases.
6188 * switch-b.adb (Scan_Binder_Switches): Do not handle -C.
6189 * gnatbind.adb (Gnatbind): Remove not Ada_Bind_File cases.
6190 * opt.ads (Ada_Bind_File): Remove.
6191
61922011-08-04 Thomas Quinot <quinot@adacore.com>
6193
6194 * projects.texi: Document target-specific directory in default project
6195 path for gnatmake.
6196
61972011-08-04 Thomas Quinot <quinot@adacore.com>
6198
6199 * gnatls.adb, prj-env.adb: Add $prefix/share/gpr to default project
6200 path in all cases .
6201
24558db8
AC
62022011-08-04 Yannick Moy <moy@adacore.com>
6203
6204 * sem_ch3.adb, sem_ch5.adb, sem_util.adb, sem_ch4.adb, sem_ch8.adb,
6205 opt.ads, lib-xref.ads: Code clean up.
6206
62072011-08-04 Yannick Moy <moy@adacore.com>
6208
6209 * gnat_rm.texi: Update description of Test_Case
6210 * gnat_ugn.texi: Typo.
6211
62122011-08-04 Ed Falis <falis@adacore.com>
6213
6214 * adaint.c (__gnat_get_number_of_cpus): fix typo in last checkin.
6215
62162011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6217
6218 * exp_ch4.adb (Suitable_Element): Skip field _parent on .NET/JVM when
6219 it is of type Root_Controlled. This action eliminates fields Prev and
6220 Next from type equality.
6221
62222011-08-04 Yannick Moy <moy@adacore.com>
6223
6224 * lib-xref-alfa.adb: Correct typo.
6225
62262011-08-04 Matthew Heaney <heaney@adacore.com>
6227
6228 * a-cohata.ads (Hash_Table_Type): default-initialize the Nodes
6229 component.
6230
1f9939b5
AC
62312011-08-04 Yannick Moy <moy@adacore.com>
6232
6233 * sem_prag.adb (Check_Arg_Is_String_Literal): remove useless procedure
6234 (Analyze_Pragma): allow static string expression for name of Test_Case,
6235 instead of simply string literals.
6236 * sem_util.adb (Get_Name_From_Test_Case_Pragma): adapt to static string
6237 expressions.
6238
62392011-08-04 Vincent Celier <celier@adacore.com>
6240
6241 * makeutl.adb (Complete_Mains.Find_File_Add_Extension): Use canonical
6242 case suffixes to find truncated main sources.
6243
62442011-08-04 Tristan Gingold <gingold@adacore.com>
6245
6246 * impunit.adb (Non_Imp_File_Names_95): Add g-tastus.
6247 s-stusta.adb (Compute_All_Task): Use Put_Line instead of Put.
6248 (Compute_Current_Task): Ditto.
6249
62502011-08-04 Tristan Gingold <gingold@adacore.com>
6251
6252 * gnat_ugn.texi: Mention GNAT.Task_Stack_Usage.
6253
62542011-08-04 Yannick Moy <moy@adacore.com>
6255
6256 * lib-xref-alfa.adb (Is_Global_Constant): new function that detects
6257 library-level constant.
6258 (Add_ALFA_Xrefs): ignore global constants in ALFA xref.
6259 * sem_res.adb (Resolve_Actuals): do not add cross-reference to Formal
6260 used as selector of parameter association, in ALFA mode.
6261
15d8a51d
AC
62622011-08-04 Robert Dewar <dewar@adacore.com>
6263
6264 * exp_ch5.adb, exp_ch7.adb, exp_util.adb, bindgen.adb, sem_prag.adb,
6265 s-tassta.adb, exp_ch4.adb, exp_disp.adb, s-stausa.adb: Minor
6266 reformatting.
6267
62682011-08-04 Arnaud Charlet <charlet@adacore.com>
6269
6270 * make.adb (Linking_Phase): Set source search path before calling
6271 gnatlink in CodePeer mode.
6272
f46faa08
AC
62732011-08-04 Javier Miranda <miranda@adacore.com>
6274
6275 * exp_ch7.adb (Expand_N_Package_Body, Expand_N_Package_Declaration):
6276 Remove code which takes care of building TSDs.
6277 * rtsfind.ads (RE_Check_Interface_Conversion): New entity.
6278 * exp_ch4.adb (Apply_Accessibility_Check): Add support for generating
6279 the accessibility check in VM targets.
6280 * exp_disp.adb (Make_VM_TSD): Spec moved to exp_disp.ads
6281 (Building_Static_DT): Now returns false for VM targets.
6282 (Build_VM_TSDs): Removed.
6283 (Expand_Interface_Conversion): Generate missing runtime check for
6284 conversions to interface types whose target type is unknown at compile
6285 time.
6286 (Make_VM_TSD): Add missing code to disable the generation of calls to
6287 Check_TSD if the tagged type is not defined at library level, or not
6288 has a representation clause specifying its external tag, or -gnatdQ is
6289 active.
6290 * exp_disp.ads (Build_VM_TSDs): Removed.
6291 (Make_VM_TSDs): Spec relocated from exp_disp.adb
6292 * sem_disp.adb (Check_Dispatching_Operation): No code required to
6293 register primitives in the dispatch tables in VM targets.
6294 * exp_ch3.adb (Expand_N_Object_Declaration): Remove wrong expansion of
6295 initialization of class-wide interface objects in VM targets.
6296 (Expand_Freeze_Record_Type): For VM targets call Make_VM_TSD (instead
6297 of Make_DT).
6298
62992011-08-04 Jerome Lambourg <lambourg@adacore.com>
6300
6301 * gnatlink.adb (Gnatlink): Correct missleading error message displayed
6302 when dotnet-ld cannot be found.
6303
63042011-08-04 Arnaud Charlet <charlet@adacore.com>
6305
6306 * bindgen.adb: Simplify significantly generation of binder body file in
6307 CodePeer mode.
6308 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Prevent assert failure
6309 when compiling binder generated file in CodePeer mode (xxx'Elab_Spec
6310 not expanded).
6311
2ba7e31e
AC
63122011-08-04 Yannick Moy <moy@adacore.com>
6313
6314 * sem_prag.adb, sem.ads: Code cleanup.
6315
63162011-08-04 Tristan Gingold <gingold@adacore.com>
6317
6318 * s-tassta.adb (Task_Wrapper): Rewrite the dynamic stack usage part.
6319 * s-stausa.adb, s-stausa.ads: Major rewrite. Now provides accurate
6320 results if possible.
6321 * s-stusta.adb (Print): Adjust after changes in s-stausa.
6322 * gnat_ugn.texi: Update dynamic stack usage section.
6323
63242011-08-04 Steve Baird <baird@adacore.com>
6325
6326 * bindgen.adb (Gen_CodePeer_Wrapper): new procedure.
6327 Generate (if CodePeer_Mode is set) a "wrapper" subprogram which
6328 contains only a call to the user-defined main subprogram.
6329 (Gen_Main_Ada) - If CodePeer_Mode is set, then
6330 call the "wrapper" subprogram instead of directly
6331 calling the user-defined main subprogram.
6332
63332011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6334
6335 * exp_ch5.adb (Expand_N_Case_Statement): Check the statements of all
6336 alternatives of a case statement for controlled objects. Rename local
6337 variable A to Dead_Alt.
6338 (Expand_N_If_Statement): Check the then and else statements of an if
6339 statement for controlled objects. Check the then statements of all
6340 elsif parts of an if statement for controlled objects.
6341 (Expand_N_Loop_Statement): Check the statements of a loop for controlled
6342 objects.
6343 * exp_ch7.adb (Process_Transient_Objects): Rewrite the condition which
6344 detects a loop associated with the expansion of an array object.
6345 Augment the processing of the loop statements to account for a possible
6346 wrap done by Process_Statements_For_Controlled_Objects.
6347 * exp_ch9.adb (Expand_N_Asynchronous_Select): Check the triggering
6348 statements and abortable part of an asynchronous select for controlled
6349 objects.
6350 (Expand_N_Conditional_Entry_Call): Check the else statements of a
6351 conditional entry call for controlled objects.
6352 (Expand_N_Selective_Accept): Check the alternatives of a selective
6353 accept for controlled objects.
6354 (Expand_N_Timed_Entry_Call): Check the entry call and delay
6355 alternatives of a timed entry call for controlled objects.
6356 * exp_ch11.adb (Expand_Exception_Handlers): Check the statements of an
6357 exception handler for controlled objects.
6358 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
6359 Add formal parameter Nested_Constructs along with its associated
6360 comment.
6361 (Requires_Cleanup_Actions (Node_Id)): Update all calls to
6362 Requires_Cleanup_Actions.
6363 (Process_Statements_For_Controlled_Objects): New routine.
6364 * exp_util.ads (Process_Statements_For_Controlled_Objects): New
6365 routine. Inspect a node which contains a non-handled sequence of
6366 statements for controlled objects. If such an object is found, the
6367 statements are wrapped in a block.
6368
1bf773bb
AC
63692011-08-04 Bob Duff <duff@adacore.com>
6370
6371 * sem_type.adb (Covers): If T2 is a subtype of a class-wide type, we
6372 need to compare with Class_Wide_Type (T2), in order to get at the
6373 original class-wide type node.
6374 * sem_type.ads (Covers): Improve the comment.
6375 * einfo.ads (Class_Wide_Type): Improve the comment.
6376 * exp_intr.adb (Expand_Unc_Deallocation): Remove unnecessary setting of
6377 the type of the Deref.
6378
63792011-08-04 Yannick Moy <moy@adacore.com>
6380
6381 * gnat_rm.texi: Document that Test_Case pragma can only appear on
6382 separate declarations.
6383 * sem_prag.adb (procedure Check_Identifier_Is_One_Of): new procedure to
6384 check identifier of pragma argument.
6385 (Chain_TC): check that no other test case associated to the same entity
6386 share the same name.
6387 (Check_Test_Case): disallow test case inside subprogram body
6388 (Analyze_Pragma): correct call to check identifier and not argument
6389 * sem_util.adb, sem_util.ads (Get_Name_From_Test_Case_Pragma): new
6390 function gets name from test case pragma.
6391
dac3bede
YM
63922011-08-04 Yannick Moy <moy@adacore.com>
6393
6394 * gnat_rm.texi: Document new pragma and aspect.
6395 * aspects.adb, aspects.ads (Aspect_Id): new value Aspect_Test_Case
6396 (No_Duplicates_Allowed): new constant array defining whether duplicates
6397 aspects of each kind can appear on the same declaration.
6398 * einfo.adb, einfo.ads (Spec_PPC_List): replace field with Contract
6399 field, which points to a node holding the previous Spec_PPC_List.
6400 * exp_ch9.adb, sem_ch6.adb, sem_prag.adb: Reach to Spec_PPC_List
6401 through the indirection with Contract.
6402 * exp_util.adb (Insert_Actions): raise Program_Error on N_Contract node
6403 * par-prag.adb (Prag): do nothing on Test_Case pragma
6404 * sem.adb (Analyze): abort on N_Contract, on which Analyze should not
6405 be called directly.
6406 * sem_attr.adb (Analyze_Attribute): allow attribute 'Result in
6407 component Ensures of Test_Case.
6408 * sem_ch12.adb, sem_ch6.adb, sem_ch9.adb
6409 (Analyze_Generic_Subprogram_Declaration,
6410 Analyze_Subprogram_Instantiation,
6411 Analyze_Abstract_Subprogram_Declaration,
6412 Analyze_Subprogram_Body_Helper,
6413 Analyze_Subprogram_Specification, Analyze_Entry_Declaration):
6414 insert contract in subprogram node at point of definition
6415 * sem_ch13.adb
6416 (Aspect_Loop): do not raise error on duplicate Test_Case aspect
6417 (Analyze_Aspect_Specifications): analyze Test_Case aspect and create
6418 corresponding pragma
6419 (Check_Aspect_At_Freeze_Point): raise Program_Error on Test_Case aspect
6420 * sem_ch3.adb (Analyze_Declarations): insert analysis of test-cases,
6421 similar to the analysis of pre/post
6422 (Derive_Subprogram): insert contract in subprogram node at point of
6423 derivation.
6424 * sem_prag.adb, sem_prag.ads
6425 (Check_Arg_Is_String_Literal, Check_Identifier):
6426 new checking procedures to be called in treatment of pragmas
6427 (Check_Test_Case): new procedure to check that a Test_Case aspect or
6428 pragma is well-formed. This does not check currently that 'Result is
6429 used only in the Ensures component of a Test_Case.
6430 (Analyze_Pragma): add case for Test_Case
6431 (Analyze_TC_In_Decl_Part): pre-analyze the Requires and Ensures
6432 components of a Test_Case.
6433 (Preanalyze_TC_Args): new procedure to preanalyze the boolean
6434 expressions in the 3rd (and 4th if present) arguments of a Test_Case
6435 pragma, treated as spec expressions.
6436 (Sig_Flags): add value -1 for Test_Case.
6437 * sem_util.adb, sem_util.ads (Get_Ensures_From_Test_Case_Pragma,
6438 Get_Requires_From_Test_Case_Pragma): getters for both expression
6439 components of a Test_Case.
6440 * sinfo.adb, sinfo.ads (N_Contract): new kind of node used as
6441 indirection between an entry or [generic] subprogram entity and its
6442 pre/post + test-cases.
6443 (Spec_PPC_List, Spec_TC_List, Set_Spec_PPC_List, Set_Spec_TC_List):
6444 get/set for fields of an N_Contract node.
6445 * snames.ads-tmpl (Name_Test_Case, Name_Ensures, Name_Mode,
6446 Name_Normal, Name_Requires, Name_Robustness, Pragma_Test_Case): new
6447 names and pragma for Test_Case.
6448 * sprint.adb (Sprint_Node): raise Program_Error on N_Contract node
6449
6a2e5d0f
AC
64502011-08-04 Vincent Celier <celier@adacore.com>
6451
6452 * gnat_ugn.texi: Improve documentation of gnatmake switch
6453 --source-info-file=.
6454
64552011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6456
6457 * exp_ch7.adb (Make_Final_Call): Add local variable Atyp (assertion
6458 type). Initialize Atyp to the appropriate type which is later checked
6459 for completion. Rewrite the assertion associated with private type
6460 completion.
6461
64622011-08-04 Ed Falis <falis@adacore.com>
6463
6464 * adaint.c: Add call to vxCpuConfiguredGet for VxWorks SMP to
6465 initialize the number of CPUs.
6466
64672011-08-04 Ed Schonberg <schonberg@adacore.com>
6468
6469 * sem_type.adb (Disambiguate): New subsidiary routine
6470 In_Same_Declaration_List, to implement AI05-0020: a user-defined
6471 equality on an anonymous access type whose designated type is private
6472 does not lead to an ambiguity with the universal access equality
6473 operator in the body or child units of the defining package. The same
6474 is true for a multiplication operator on a private type completed with
6475 a fixed-point-type.
6476
64772011-08-04 Javier Miranda <miranda@adacore.com>
6478
6479 * opt.ads (Init_Or_Norm_Scalars_Config): Removed.
6480 (Normalize_Scalars_Config): Removed.
6481 * opt.adb
6482 (Register_Opt_Config_Switches): Remove registering config values of
6483 Init_Or_Norm_Scalars_Config and Normalize_Scalars_Config.
6484 (Restore_Opt_Config_Switches): Remove code which restores the values of
6485 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
6486 Init_Or_Norm_Scalars.
6487 (Save_Opt_Config_Switches): Remove code which saves values of
6488 Init_Or_Norm_Scalars and Normalize_Scalars.
6489 (Set_Opt_Config_Switches): Remove code which restores config values of
6490 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
6491 Init_Or_Norm_Scalars.
6492
64932011-08-04 Yannick Moy <moy@adacore.com>
6494
6495 * frontend.adb (Frontend): remove previous patch to avoid full
6496 qualification in ALFA mode.
6497 * lib-xref-alfa.adb (Add_ALFA_Xrefs): use unique name for variables.
6498 * sem_util.adb, sem_util.ads (Unique_Name): new function to define a
6499 unique name for an entity, which could be used to identify the entity
6500 across compilation units.
6501
65022011-08-04 Thomas Quinot <quinot@adacore.com>
6503
6504 * prj-env.adb
6505 (Initialize_Default_Project_Path): Add target specific directory
6506 ($prefix/$target/lib/gnat) in front of project path in all cases
6507 (making gnatmake's behaviour consistent with gprbuild).
6508 * gnatcmd.adb, make.adb, prj-makr.adb, clean.adb:
6509 Pass target name from Sdefault to project subsystem.
6510 * gnatls.adb: Show new target specific default project directory.
6511
65122011-08-04 Johannes Kanig <kanig@adacore.com>
6513
6514 * cstand.adb: Add Information to Identifier in Standard
6515 (Identifer_For): Set Entity to the corresponding entity
6516
483361a6
AC
65172011-08-04 Sergey Rybin <rybin@adacore.com>
6518
6519 * gnat_ugn.texi: Update doc on gnatcheck.
6520
65212011-08-04 Yannick Moy <moy@adacore.com>
6522
6523 * lib-xref-alfa.adb (Add_ALFA_Xrefs): correct definition of ranges of
6524 xrefs in a scope.
6525
65262011-08-04 Yannick Moy <moy@adacore.com>
6527
6528 * exp_prag.adb (Expand_Pragma_Check): in ALFA mode, return without
6529 performing expansion.
6530 * sem_ch6.adb (Analyze_Subprogram_Body_Helper,
6531 Analyze_Generic_Subprogram_Body): protect call to Process_PCCs so that
6532 it is not called in ALFA mode.
6533
ef5569c6
AC
65342011-08-04 Emmanuel Briot <briot@adacore.com>
6535
6536 * make.adb, osint.adb, osint.ads (Reset_Command_Line_Files): not used
6537 after all, so removed.
6538
65392011-08-04 Sergey Rybin <rybin@adacore.com>
6540
6541 * vms_data.ads: Add missing VMS qualifiers.
6542
1ab4a286
EB
65432011-08-04 Emmanuel Briot <briot@adacore.com>
6544
6545 * make.adb, makeutl.adb, osint.adb, osint.ads (Check_Mains): rebuild
6546 the list of files on the command line after processing it through
6547 Complete_Mains.
6548
7ae0d98c
AC
65492011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6550
6551 * exp_ch7.adb (Build_Raise_Statement): Remove the specialized
6552 processing for .NET/JVM. These targets can now benefit from
6553 Raise_From_Controlled_Operation and they share the same processing with
6554 standard targets.
6555 (Establish_Transient_Scope): Remove the restriction for .NET/JVM.
6556 These targets need transient scopes in order to properly finalize short
6557 lived controlled objects.
6558 (Make_Handler_For_Ctrl_Operation): Remove the specialized processing for
6559 NET/JVM. These targets can now benefit from
6560 Raise_From_Controlled_Operation and they share the same processing with
6561 standard targets.
6562
65632011-08-04 Geert Bosch <bosch@adacore.com>
6564
6565 * tracebak.c (STOP_FRAME): Stop at any next pointer outside the stack
6566
65672011-08-04 Ed Schonberg <schonberg@adacore.com>
6568
6569 * exp_aggr.adb (Has_Visible_Private_Ancestor): subsidiary routine to
6570 Expand_Record_Aggregate, to determine whether aggregate must be
6571 expanded into assignments. This is the case if the ancestor part is
6572 private, regarless of the setting of the flag Has_Private_Ancestor.
6573
65742011-08-04 Ed Falis <falis@adacore.com>
6575
6576 * vxaddr2line.adb: Add support for e500v2 and for Linux hosts
6577
65782011-08-04 Bob Duff <duff@adacore.com>
6579
6580 * sinfo.ads: Fix comment.
6581
65822011-08-04 Steve Baird <baird@adacore.com>
6583
6584 * bindgen.adb (Get_Ada_Main_Name): If CodePeer_Mode is set, then
6585 choose a package name in much the same way as is
6586 done for JGNAT when VM_Target /= No_VM, except that
6587 a slightly more distinctive prefix string is used.
6588
65892011-08-04 Emmanuel Briot <briot@adacore.com>
6590
6591 * makeutl.adb (Complete_Mains): no longer accept unit names on the
6592 gnatmake command line.
6593 This behavior was never documented (and was supported only because of
6594 an early bug in the code). This case might lead to ambiguous cases
6595 (between unit names and truncated base names without suffixes).
6596
87729e5a
AC
65972011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6598
6599 * a-tags.ads, a-tags.adb (Unregister_Tag): New routine.
6600 Remove the external tag of a tagged type from the internal hash table.
6601 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on the
6602 expanded usage of the routine. Strenghten the check for Is_Master. Add
6603 processing for tagged types.
6604 (Build_Finalizer): Create all the necessary lists used in finalizer
6605 creation when the processed context is a package that may contain
6606 tagged types.
6607 (Expand_Cleanup_Actions): Rename the call to Has_Controlled_Objects to
6608 Requires_Cleanup_Actions.
6609 (Expand_N_Package_Body): Package bodies may need clean up code
6610 depending on whether they contain tagged types.
6611 (Expand_N_Package_Declaration): Package declarations may need clean up
6612 code depending on whether they contain tagged types.
6613 (Unregister_Tagged_Types): New routine. Search through a list of
6614 declarations or statements, looking for non-abstract Ada tagged types.
6615 For each such type, generate code to unregister the external tag.
6616 * exp_util.adb (Has_Controlled_Objects (Node_Id)): Renamed to
6617 Requires_Cleanup_Actions.
6618 (Requires_Cleanup_Actions (List_Id, Boolean)): New routine. Search
6619 through a list of declarations or statements looking for non-abstract
6620 Ada tagged types or controlled objects.
6621 * exp_util.ads (Has_Controlled_Objects (Node_Id)): Renamed to
6622 Requires_Cleanup_Actions.
6623 (Has_Controlled_Objects (List_Id, Boolean)): Removed.
6624 * rtsfind.ads: Add entry RE_Unregister_Tag to tables RE_Id and
6625 RE_Unit_Table.
6626
66272011-08-04 Vincent Celier <celier@adacore.com>
6628
6629 * prj-env.adb (For_All_Source_Dirs.For_Project): Check if project Prj
6630 has Ada sources, not project Project, because if the root project
6631 Project has no sources of its own, all projects will be deemed without
6632 sources.
6633
66342011-08-04 Gary Dismukes <dismukes@adacore.com>
6635
6636 * bindgen.adb (Gen_Adainit_Ada): Move the generation of the declaration
6637 of the No_Param_Proc acc-to-subp type used for initialization of
6638 __gnat_finalize_library_objects so that it's declared at library level
6639 rather than nested inside of the adainit routine.
6640
66412011-08-04 Javier Miranda <miranda@adacore.com>
6642
6643 * exp_disp.adb (Make_DT): Generate code to check the external tag ONLY
6644 if the tagged type has a representation clause which specifies its
6645 external tag.
6646
66472011-08-04 Ed Schonberg <schonberg@adacore.com>
6648
6649 * einfo.ads, einfo.adb (Has_Private_Ancestor): now a flag on types.
6650 Remove previous procedure with that name.
6651 * sem_ch3.adb (Build_Derived_Record_Type): set Has_Private_Ancestor
6652 when appropriate.
6653 * sem_aggr.adb (Resolve_Extension_Aggregate): if the ancestor part is a
6654 subtype mark, the ancestor cannot have unknown discriminants.
6655 (Resolve_Record_Aggregate): if the type has invisible components
6656 because of a private ancestor, the aggregate is illegal.
6657
66582011-08-04 Vincent Celier <celier@adacore.com>
6659
6660 * switch-m.adb (Normalize_Compiler_Switches): Recognize and take into
6661 account switches -gnat2005, -gnat12 and -gnat2012.
6662
66632011-08-04 Bob Duff <duff@adacore.com>
6664
6665 * s-tasdeb.ads: Minor comment fix.
6666
66672011-08-04 Arnaud Charlet <charlet@adacore.com>
6668
6669 * gnatlink.adb (Gnatlink): Pass -gnat83/95/05/12 switch to gcc in
6670 CodePeer mode.
6671 * switch.ads, switch.adb (Is_Language_Switch): New function.
6672
66732011-08-04 Vincent Celier <celier@adacore.com>
6674
6675 * switch-c.adb: Minor comment addition.
6676
66772011-08-04 Vincent Celier <celier@adacore.com>
6678
6679 * vms_conv.adb (Process_Argument): Fail graciously when qualifier
6680 ending with '=' is followed by a space (missing file name).
6681
66822011-08-04 Pascal Obry <obry@adacore.com>
6683
6684 * g-regist.ads: Fix size of HKEY on x86_64-windows.
6685
66862011-08-04 Ed Schonberg <schonberg@adacore.com>
6687
6688 * sem_ch12.adb (Analyze_Associations): New routine
6689 Check_Overloaded_Formal_Subprogram to reject a formal package when
6690 there is a named association or a box initialisation for an overloaded
6691 formal subprogram of the corresponding generic.
6692
66932011-08-04 Yannick Moy <moy@adacore.com>
6694
6695 * alfa.ads (ALFA_Xref_Record): add component for type of entity
6696 * get_alfa.adb, put_alfa.adb: Read and write new component of
6697 cross-reference.
6698 * lib-xref-alfa.adb (Collect_ALFA): generate new component.
6699
88f47280
AC
67002011-08-04 Pascal Obry <obry@adacore.com>
6701
6702 * urealp.adb: Minor reformatting.
6703
67042011-08-04 Tristan Gingold <gingold@adacore.com>
6705
6706 * exp_ch7.adb (build_finalizer.process_declarations.processing_actions):
6707 Handle the case when Cleanup_Protected_Object returns Empty.
6708
67092011-08-04 Yannick Moy <moy@adacore.com>
6710
6711 * frontend.adb (Frontend): only qualify names in non-ALFA mode
6712
67132011-08-04 Ed Schonberg <schonberg@adacore.com>
6714
6715 * sem_ch4.adb (Try_Class_Wide_Operation): if the context is a procedure
6716 call, ignore functions.
6717
05c53a69
GB
67182011-08-04 Geert Bosch <bosch@adacore.com>
6719
6720 * urealp.adb (Equivalent_Decimal_Exponent): Avoid the use of floating
6721 point.
6722
23cc1ace
EB
67232011-08-04 Emmanuel Briot <briot@adacore.com>
6724
6725 * makeutl.adb (Compute_Builder_Switches): no longer accept a unit name
6726 as an index for Builder'Switches. This conforms to the documentation.
6727 * make.adb (Insert_Project_Sources): avoid duplicate code
6728
cef14201
AC
67292011-08-04 Emmanuel Briot <briot@adacore.com>
6730
6731 * makeutl.adb (Complete_Mains): if the user has passed a relative file
6732 name on the command line (for instance "../dummy"), never assume it can
6733 be a unit name.
6734
67352011-08-04 Tristan Gingold <gingold@adacore.com>
6736
6737 * bindgen.adb: Remove code the reference or create the
6738 Break_Start/__gnat_break_start procedure.
6739 * s-stalib.adb (Break_Start): Removed.
6740
e2fee30d
EB
67412011-08-04 Emmanuel Briot <briot@adacore.com>
6742
6743 * make.adb, makeutl.adb, makeutl.ads (Compute_Builder_Switches): now
6744 shared with gprbuild.
6745
2d395256
AC
67462011-08-04 Yannick Moy <moy@adacore.com>
6747
6748 * par-ch4.adb (P_Primary): preferentially issue an error message about
6749 a missing parenthesis arount a conditional or case expression in Ada
6750 2012 mode, if we detect that the alignment is not correct for a
6751 statement.
6752
67532011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6754
6755 * exp_ch7.adb (Process_Declarations): Do not consider the result of a
6756 tag-to-class-wide conversion as needing finalization actions.
6757 * exp_util.adb (Has_Controlled_Objects): Do not consider the result of
6758 a tag-to-class-wide conversion as needing finalization actions.
6759 (Is_Finalizable_Transient): The result of a tag-to-class-wide
6760 conversion does not need finalization actions.
6761 (Is_Tag_To_CW_Conversion): New routine.
6762 * exp_util.ads (Is_Tag_To_CW_Conversion): New routine. Determines
6763 whether an object is the result of a tag-to-class-wide conversion.
6764
67652011-08-04 Yannick Moy <moy@adacore.com>
6766
6767 * sem_ch13.adb (Analyze_Aspect_Specifications): correct order in which
6768 the left-hand-side and right-hand-side of a conjunct are inserted when
6769 translating a pre- or postcondition
6770 * sem_ch6.adb: Correct typo in comment
6771
67722011-08-04 Ed Schonberg <schonberg@adacore.com>
6773
6774 * gnat_rm.texi: Ravenscar does not prohibit dependence on
6775 Unchecked_Conversion and Unchecked_Deallocation.
6776
67772011-08-04 Thomas Quinot <quinot@adacore.com>
6778
6779 * make.adb: Minor reformatting.
6780
767ab2fd
EB
67812011-08-04 Emmanuel Briot <briot@adacore.com>
6782
6783 * prj.adb, prj.ads, makeutl.adb (Complete_Mains): search for the
6784 sources in the project and its imported projects, but not in the whole
6785 tree.
6786
8fb3f5df
AC
67872011-08-04 Emmanuel Briot <briot@adacore.com>
6788
6789 * make.adb: Remove debug trace.
6790
67912011-08-04 Vincent Celier <celier@adacore.com>
6792
6793 * makeutl.adb (Do_Complete): Get the absolute path name of a relative
6794 path in canonical form, to be able to compare path names on platforms
6795 such as Windows or Darwin.
6796
67972011-08-04 Thomas Quinot <quinot@adacore.com>
6798
6799 * par_sco.adb (Traverse_Declarations_Or_Statements.Set_Statement_Entry):
6800 For a pragma (statement with C1 = 'P'), record the sloc of the pragma.
6801 * scos.ads: Update documentation accordingly.
6802 * put_scos.adb (Output_SCO_Line): Omit statement SCOs for disabled
6803 pragmas.
6804
9515740f
AC
68052011-08-04 Ed Schonberg <schonberg@adacore.com>
6806
6807 * sem_attr.adb (Bad_Attribute_For_Predicate): flag illegal use of
6808 attribute only if prefix type is scalar.
6809
68102011-08-04 Emmanuel Briot <briot@adacore.com>
6811
6812 * make.adb, makeutl.adb, prj-env.adb (Check_Mains): put back support
6813 in gnatmake for specifying mains on the command line that do not belong
6814 to the main project. These mains must currently all belong to the same
6815 project, though.
6816 (Ultimate_Extension_Of): removed, since duplicated
6817 Ultimate_Extending_Project.
6818
92966893
AC
68192011-08-04 Arnaud Charlet <charlet@adacore.com>
6820
6821 * make.adb (Do_Codepeer_Globalize_Step): Removed. Use CodePeer_Mode
6822 instead.
6823 (CodePeer_Mode_String): New.
6824 (Linking_Phase, Binding_Phase): Call gnatlink with -P switch in
6825 CodePeer mode.
6826 (Scan_Make_Arg): Do not disable binding/linking phase in CodePeer mode.
6827 * bindgen.adb (Gen_Elab_Calls_Ada): Ignore subprograms in CodePeer
6828 mode, since no useful elaboration subprogram is needed by CodePeer.
6829 * gnatlink.adb (Gnatlink): Add support for -P switch (CodePeer mode).
6830 In this mode, compile binder file with -gnatC and do stop after this
6831 step.
6832
68332011-08-04 Vincent Celier <celier@adacore.com>
6834
6835 * exp_ch7.adb: Minor comment fix.
6836
5969611f
RD
68372011-08-04 Robert Dewar <dewar@adacore.com>
6838
6839 * exp_ch7.adb, make.adb, sem_ch10.adb, bindgen.adb, sem_res.adb,
6840 exp_ch4.adb, makeutl.adb: Minor reformatting.
6841
6367dd30
AC
68422011-08-04 Emmanuel Briot <briot@adacore.com>
6843
6844 * make.adb, makeutl.adb, makeutl.ads (Make): major refactoring.
6845 Create several new subprograms to move code out of Make. This makes the
6846 code more readable, removes code duplication, and is a preparation work
6847 for adding support for aggregate projects.
6848
68492011-08-04 Tristan Gingold <gingold@adacore.com>
6850
6851 * s-po32gl.ads, s-po32gl.adb: New files.
6852 * exp_ch7.ads (Get_Global_Pool_For_Access_Type): New function.
6853 * exp_ch7.adb (Get_Global_Pool_For_Access_Type): New function.
6854 (Build_Finalization_Collection): Use it.
6855 * exp_ch4.adb (Complete_Controlled_Allocation): Ditto.
6856 * rtsfind.ads: System_Pool_32_Global, Re_Global_Pool_32_Object: New
6857 literals.
6858 * gcc-interface/Makefile.in: Use s-po32gl.o on VMS.
6859 * gcc-interface/Make-lang.in: Update dependencies.
6860
cd8bfe35
EB
68612011-08-04 Emmanuel Briot <briot@adacore.com>
6862
6863 * makeutl.adb (Complete_Mains): add support for specs with no suffix on
6864 the command line.
6865
7db29ea7
EB
68662011-08-04 Emmanuel Briot <briot@adacore.com>
6867
6868 * make.adb, makeutl.adb (Complete_Mains): if a main specified on the
6869 command line is not a file name, also check whether it could be a unit
6870 name.
6871
d9b056ea
AC
68722011-08-04 Eric Botcazou <ebotcazou@adacore.com>
6873
6874 * bindgen.adb (Gen_Finalize_Library_Ada): Factor out code to generate
6875 the header of the finalization routine.
6876 If the unit has no finalizer but is a body whose spec has one, then
6877 generate the decrement of the elaboration entity only.
6878 If the unit has a finalizer and is a spec, then do not generate the
6879 decrement of the elaboration entity.
6880 (Gen_Finalize_Library_C): Likewise.
6881
68822011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6883
6884 * exp_ch7.adb (Alignment_Of): New subsidiary routine.
6885 (Bounds_Size_Expression): Removed.
6886 (Double_Alignment_Of): New subsidiary routine.
6887 (Make_Finalize_Address_Stmts): New local variable Index_Typ. Account
6888 for a hole in the dope vector of unconstrained arrays due to different
6889 index and element alignments.
6890
68912011-08-04 Ed Schonberg <schonberg@adacore.com>
6892
6893 * sem_res.adb (Resolve_Allocator): diagnose task allocator that will
6894 raise program_error because body has not been seen yet.
6895
68962011-08-04 Ed Schonberg <schonberg@adacore.com>
6897
6898 * sem_ch10.adb (Analyze_With_Clause): Protect against child unit with
6899 an unresolved name.
6900
69012011-08-04 Vincent Celier <celier@adacore.com>
6902
6903 * makeutl.adb (Do_Complete): Check absolute paths in canonical forms
6904
69052011-08-04 Yannick Moy <moy@adacore.com>
6906
6907 * alfa.adb, alfa.ads (Unique_Defining_Entity): move function from here
6908 * sem_util.adb, sem_util.ads (Unique_Defining_Entity): ...to here
6909
69102011-08-04 Thomas Quinot <quinot@adacore.com>
6911
6912 * sem_ch12.adb (Analyze_Package_Instantiation): Do not omit body for
6913 instantiation in RCI.
6914
69152011-08-04 Emmanuel Briot <briot@adacore.com>
6916
6917 * make.adb: Share more code with gprbuild
6918
f5fc5b9d
AC
69192011-08-04 Emmanuel Briot <briot@adacore.com>
6920
6921 * projects.texi: Added documentation for the IDE'Gnat project file
6922 attribute.
6923
69242011-08-04 Nicolas Roche <roche@adacore.com>
6925
6926 * gnat_rm.texi: Minor editing.
6927
69282011-08-04 Javier Miranda <miranda@adacore.com>
6929
6930 * bindgen.adb (Gen_Adafinal_Ada): Do not differentiate the main case
6931 and the library case for VM targets.
6932 (Gen_Adainit_Ada): Likewise.
6933
69342011-08-04 Robert Dewar <dewar@adacore.com>
6935
6936 * g-altive.ads: Minor comment updates.
6937 * prj-nmsc.adb: Minor reformatting.
6938
69392011-08-04 Javier Miranda <miranda@adacore.com>
6940
6941 * opt.ads
6942 (Normalize_Scalars_Config): Value of the configuration switch set by
6943 pragma Normalize_Scalars when it appears in the gnat.adc file.
6944 (Normalize_Scalars): New field for record Config_Switches_Type. Used
6945 to save and restore settings of this pragma.
6946 * opt.adb
6947 (Register_Opt_Config_Switches, Save_Opt_Config_Switches,
6948 Restore_Opt_Config_Switches): Add missing support for Normalize_Scalars.
6949
69502011-08-04 Vincent Celier <celier@adacore.com>
6951
6952 * gnat_ugn.texi: Document gnatlink options -M and -M=mapfile
6953
0c4683cf
AC
69542011-08-04 Arnaud Charlet <charlet@adacore.com>
6955
6956 * makeutl.adb: Minor reformatting.
6957
69582011-08-04 Olivier Hainque <hainque@adacore.com>
6959
6960 * g-altive.ads: Update comments to reflect that only the soft
6961 binding is available today.
6962
2598ee6d
RD
69632011-08-04 Robert Dewar <dewar@adacore.com>
6964
6965 * bindgen.adb, einfo.adb, sem_ch12.adb, s-tasren.adb, sem_res.adb,
6966 makeutl.adb, prj-nmsc.adb, opt.ads, prj-env.adb: Minor reformatting
6967 * gcc-interface/Make-lang.in: Update dependencies.
6968
c2db4b32
AC
69692011-08-04 Arnaud Charlet <charlet@adacore.com>
6970
6971 * prj-env.adb: Remove local debug traces.
6972
69732011-08-04 Yannick Moy <moy@adacore.com>
6974
6975 * checks.adb (Apply_Float_Conversion_Check): correct a typo where Lo_OK
6976 was used instead of Hi_OK, which could cause a read of an uninitialized
6977 value later on. Detected while working on the new warning.
6978 * exp_ch9.adb (Expand_N_Entry_Declaration): remove useless assignment
6979 to local variable.
6980 * sem_ch5.adb (Analyze_Assignment): set the last assignment component
6981 in more cases, in order to detect more unreferenced values.
6982 * sem_util.adb, sem_util.ads (Get_Enclosing_Object): return enclosing
6983 object for expression, if any.
6984
69852011-08-04 Eric Botcazou <ebotcazou@adacore.com>
6986
6987 * exp_intr.adb (Expand_Binary_Operator_Call): Look at the RM size of
6988 the operand types instead of the Esize.
6989
69902011-08-04 Steve Baird <baird@adacore.com>
6991
6992 * switch-b.adb (Scan_Binder_Switches): Add -P binder switch, used to
6993 enable CodePeer_Mode.
6994 * bindusg.adb (Display): Add help message describing -P binder switch.
6995 * gnat_ugn.texi: Document -P binder switch.
6996 * bindgen.adb (Gen_Main_Ada): If CodePeer_Mode is set, then call the
6997 user-defined main program directly.
6998 (Gen_Output_File_Ada): If CodePeer_Mode is set, generate a with of the
6999 user-defined main program in the context clause of the package body.
7000
ad05f2e9
AC
70012011-08-04 Yannick Moy <moy@adacore.com>
7002
7003 * alfa.adb, alfa.ads (Get_Entity_For_Decl): remove function, partial
7004 duplicate of Defining_Entity
7005 (Get_Unique_Entity_For_Decl): rename function into
7006 Unique_Defining_Entity
7007 * einfo.adb, einfo.ads (Is_In_ALFA, Body_Is_In_ALFA): remove flags
7008 (Formal_Proof_On): remove synthesized flag
7009 * cstand.adb, sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
7010 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_res.adb, sem_util.adb,
7011 sem_util.ads, stand.ads: Remove treatment associated to entities in ALFA
7012 * sem_prag.adb (Analyze_Pragma): remove special treatment for pragma
7013 Annotate (Formal_Proof)
7014
70152011-08-04 Emmanuel Briot <briot@adacore.com>
7016
7017 * prj-env.adb (Create_Config_Pragmas_File): fix handling of multi-unit
7018 source files with non-standard naming schemes, in imported projects
7019
756ef2a0
AC
70202011-08-04 Emmanuel Briot <briot@adacore.com>
7021
7022 * makeutl.adb (Complete_Mains): when a multi-unit source file is
7023 specified on the gprbuild command line, we need to compile all units
7024 within that file, not just the first one we find
7025 Fix error message for mains that are not found.
7026
70272011-08-04 Thomas Quinot <quinot@adacore.com>
7028
7029 * sem_ch6.adb: Update comment.
7030 * sem_ch12.adb: Minor reformatting.
7031
70322011-08-04 Bob Duff <duff@adacore.com>
7033
7034 * s-tasren.adb (Task_Do_Or_Queue): Previous code was reading
7035 Acceptor.Terminate_Alternative without locking Acceptor, which causes a
7036 race condition whose symptom is to fail to lock Parent. That, in turn,
7037 causes Parent.Awake_Count to be accessed without locking Parent, which
7038 causes another race condition whose symptom is that Parent.Awake_Count
7039 can be off by 1 (either too high or too low). The solution is to lock
7040 Parent unconditionally, and then lock Acceptor, before reading
7041 Acceptor.Terminate_Alternative.
7042
4fdebd93
AC
70432011-08-04 Arnaud Charlet <charlet@adacore.com>
7044
7045 * debug.adb: Update comment.
7046
70472011-08-04 Robert Dewar <dewar@adacore.com>
7048
7049 * par_sco.adb, exp_util.adb, make.adb, a-tags.adb, sem_prag.adb,
7050 sem_util.adb, sem_attr.adb, exp_ch4.adb, g-comlin.adb, g-comlin.ads,
7051 exp_ch6.adb: Minor reformatting.
7052
70532011-08-04 Gary Dismukes <dismukes@adacore.com>
7054
7055 * gnat_ugn.texi: Add sentence about the case of compile-time-detected
7056 checks for -gnateE.
7057
70582011-08-04 Ed Schonberg <schonberg@adacore.com>
7059
7060 * gnat_rm.texi: update Ravenscar desription to reflect Ada2012 RM.
7061
70622011-08-04 Thomas Quinot <quinot@adacore.com>
7063
7064 * sinfo.ads: Minor reformatting.
7065
70662011-08-04 Emmanuel Briot <briot@adacore.com>
7067
7068 * makeutl.adb, makeutl.ads, prj-nmsc.adb (Complete_Mains): report error
7069 even if there is no location.
7070
6aaa0587
ES
70712011-08-04 Ed Schonberg <schonberg@adacore.com>
7072
7073 * sem_res.adb, sem_ch4.adb: move check for restriction
7074 No_Task_Hierarchy to resolve_allocator.
7075
35a1c212
AC
70762011-08-04 Thomas Quinot <quinot@adacore.com>
7077
7078 * sinfo.adb, sinfo.ads, sem_prag.adb, sem_ch12.adb (Pragma_Enabled):
7079 This flag of N_Pragma nodes is not used, remove it as well as all of
7080 the associated circuitry.
7081
70822011-08-04 Javier Miranda <miranda@adacore.com>
7083
7084 * exp_disp.adb (Make_DT): Switch -gnatdQ disables the generation of the
7085 runtime check on duplicated externa tags
7086 * debug.adb Document switch -gnatdQ.
7087
70882011-08-04 Gary Dismukes <dismukes@adacore.com>
7089
7090 * a-fihema.ads: Minor typo fix.
7091
70922011-08-04 Yannick Moy <moy@adacore.com>
7093
7094 * sem_ch10.adb: Minor comment update.
7095
70962011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7097
7098 * einfo.adb: Update the node field usage to reflect the renaming of
7099 Return_Flag to Return_ Flag_Or_Transient_Decl.
7100 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl.
7101 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl.
7102 (Write_Field15_Name): Change Return_Flag to
7103 Return_Flag_Or_Transient_Decl.
7104 * einfo.ads: Rename node field Return_Flag to
7105 Return_Flag_Or_Transient_Decl. Update the associated comment and all
7106 occurrences in entities.
7107 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl. Update
7108 associated Inline pragma.
7109 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl. Update
7110 associated Inline pragma.
7111 * exp_ch4.ads, exp_ch4.adb (Expand_N_Expression_With_Actions): New
7112 routine.
7113 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Update the calls to
7114 Return_Flag and Set_Return_Flag.
7115 * exp_ch7.adb (Process_Declarations): Add code to recognize hook
7116 objects generated for controlled transients declared inside an
7117 Exception_With_Actions. Update the calls to Return_Flag.
7118 (Process_Object_Declaration): Add code to add a null guard for hook
7119 objects generated for controlled transients declared inside an
7120 Exception_With_Actions. Update related comment.
7121 * exp_util.adb (Has_Controlled_Objects): Add code to recognize hook
7122 objects generated for controlled transients declared inside an
7123 Exception_With_Actions. Update the calls to Return_Flag.
7124 * expander.adb (Expand): Add new case for N_Expression_With_Actions.
7125
71262011-08-04 Ed Schonberg <schonberg@adacore.com>
7127
7128 * sem_util.adb:(Wrong_Type): Improve error message on a one-element
7129 positional aggregate.
7130
71312011-08-04 Vincent Celier <celier@adacore.com>
7132
7133 * par_sco.adb (Process_Decisions.Output_Header): Check and record pragma
7134 SLOC only for pragmas.
7135
71362011-08-04 Emmanuel Briot <briot@adacore.com>
7137
7138 * projects.texi: Minor typo fix.
7139
71402011-08-04 Emmanuel Briot <briot@adacore.com>
7141
7142 * prj-nmsc.adb (Check_File): Minor change to traces, to help debugging
7143 on case-sensitive file systems.
7144
c2873f74
TQ
71452011-08-04 Thomas Quinot <quinot@adacore.com>
7146
7147 * put_scos.adb (Put_SCOs): Do not emit decision SCO for an X decision
7148 nested in a disabled pragma.
7149 * scos.ads, scos.adb, par_sco.ads, par_sco.adb: Record sloc of
7150 enclosing pragma, if any, for X decisions.
7151
71522011-08-04 Thomas Quinot <quinot@adacore.com>
7153
7154 * sem_prag.adb: Minor reformatting.
7155
46414266
VC
71562011-08-04 Vincent Celier <celier@adacore.com>
7157
7158 * a-tags.adb (Check_TSD): Avoid concatenation of strings, as it is not
7159 allowed in no run time mode.
7160
71612011-08-04 Vincent Celier <celier@adacore.com>
7162
7163 * make.adb (Check): When -gnatc is used, check for the source file
7164 inside the ALI file with a canonical case file name.
7165
afab164f
EB
71662011-08-04 Emmanuel Briot <briot@adacore.com>
7167
7168 * g-comlin.adb, g-comlin.ads (Add_Switch): Put back support for
7169 overriding the separator.
7170
fe0ec02f
AC
71712011-08-04 Robert Dewar <dewar@adacore.com>
7172
7173 * sem_aggr.adb, par_sco.adb, sem_type.adb, exp_util.adb, exp_ch9.adb,
7174 prj-nmsc.adb, sem_ch13.adb, exp_strm.adb: Minor reformatting.
7175
71762011-08-04 Robert Dewar <dewar@adacore.com>
7177
7178 * gnat_rm.texi: Minor documentation fix for pragma Annotate.
7179
71802011-08-04 Yannick Moy <moy@adacore.com>
7181
7182 * sem_attr.adb (Analyze_Attribute): add check during pre-analysis that
7183 'Result only appears in postcondition of function.
7184
71852011-08-04 Thomas Quinot <quinot@adacore.com>
7186
7187 * a-tags.adb (Check_TSD): When raising PROGRAM_ERROR for a duplicated
7188 external tag, include the value of the external tag in the exception
7189 message.
7190
0180fd26
AC
71912011-08-04 Yannick Moy <moy@adacore.com>
7192
7193 * sem_attr.adb (Result): modify error message for misplaced 'Result
7194
71952011-08-04 Sergey Rybin <rybin@adacore.com>
7196
7197 * gnat_rm.texi (pragma Annotate): Fix syntax description to make it
7198 clear that the second argument must be an identifier.
7199
72002011-08-04 Thomas Quinot <quinot@adacore.com>
7201
7202 * exp_ch9.adb (Build_Barrier_Function): When compiling with
7203 -fpreserve-control-flow, insert an IF statement on the barrier
7204 condition to ensure that a conditional branch instruction is generated.
7205
72062011-08-04 Emmanuel Briot <briot@adacore.com>
7207
7208 * prj-part.adb, prj.adb, prj.ads, prj-tree.ads
7209 (Processing_Flags.Ignore_Missing_With): new flag.
7210
72112011-08-04 Emmanuel Briot <briot@adacore.com>
7212
7213 * prj-nmsc.adb (Find_Sources, Path_Name_Of): Fix handling of
7214 Source_List_File on case-insensitive systems where the file is actually
7215 on a case-sensitive file system (NFS,...).
7216
72172011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7218
7219 * sem_ch6.adb (Analyze_Function_Return): In a rare case where a
7220 function return contains a controlled [extension] aggregate and the
7221 return statement is not part of a handled sequence of statements, wrap
7222 the return in a block. This ensures that all controlled temporaries
7223 generated during aggregate resolution will be picked up by the
7224 finalization machinery.
7225
72262011-08-04 Ed Schonberg <schonberg@adacore.com>
7227
7228 * sem_aggr.adb (Resolve_Aggregate): If aggregate has box-initialized
7229 components, freeze type before resolution, to ensure that default
7230 initializations are present for all components.
7231 * sem_res.adb (Resolve_Actuals): the designated object of an
7232 accces-to-constant type is a legal actual in a call to an
7233 initialization procedure.
7234
72352011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7236
7237 * exp_util.adb (Extract_Renamed_Object): Add N_Type_Conversion and
7238 N_Unchecked_Type_Conversion to the possible containers of a renamed
7239 transient variable.
7240
78efd712
AC
72412011-08-04 Yannick Moy <moy@adacore.com>
7242
7243 * par-ch13.adb (Aspect_Specifications_Present): recognize
7244 "with Identifier'Class =>" as an aspect, so that a meaningful warning
7245 is issued in Strict mode.
7246 * par.adb: Fix typos in comments.
7247
72482011-08-04 Yannick Moy <moy@adacore.com>
7249
7250 * sem_attr.adb (Result): modify error message to take into account Post
7251 aspect when compiling Ada 2012 (or newer) code.
7252
72532011-08-04 Nicolas Roche <roche@adacore.com>
7254
7255 * env.c (__gnat_clearenv): Avoid use of dynamic size array in order to
2c7f9cc0 7256 remove need for GCC exceptions.
78efd712
AC
7257
72582011-08-04 Vincent Celier <celier@adacore.com>
7259
7260 * makeutl.adb (Do_Complete): Call Debug_Output with the name of the
7261 project, not the source file name.
7262 * prj.adb (Find_Sources.Look_For_Sources): If the source has been
7263 excluded, continue looking. This excluded source will only be returned
7264 if there is no other source with the same base name that is not locally
7265 removed.
7266
72672011-08-04 Ed Schonberg <schonberg@adacore.com>
7268
7269 * sem_res.adb (Resolve_Intrinsic_Operator): if the result type is
7270 private and one of the operands is a real literal, use a qualified
7271 expression rather than a conversion which is not meaningful to the
7272 back-end.
7273
0170a691
AC
72742011-08-04 Yannick Moy <moy@adacore.com>
7275
7276 * sem_ch13.adb (Aspect_Loop): when an aspect X and its classwise
7277 corresponding aspect X'Class are allowed, proceed with analysis of the
7278 aspect instead of skipping it.
7279
72802011-08-04 Tristan Gingold <gingold@adacore.com>
7281
7282 * s-flocon.adb, s-flocon.ads: Add a body for s-flocon.ads
7283 This will allow to have an Ada implementation for the subprogram.
7284
deb4f5ba
ES
72852011-08-04 Ed Schonberg <schonberg@adacore.com>
7286
7287 * sem_ch3.adb (Analyze_Full_Type_Declaration): If the declaration is a
7288 completion and aspects are present, apply them to the entity for the
7289 type which is currently the partial view, but which is the one that
7290 will be frozen.
7291 * sem_ch13.adb (Analyze_Aspect_Specifications): if the predicate
7292 applies to a partial view, indicate that the full view has predicates
7293 and delayed aspects.
7294 (Replace_Type_Reference): Handle properly predicates that apply to the
7295 full view of a private completion.
7296
fc893455
AC
72972011-08-04 Eric Botcazou <ebotcazou@adacore.com>
7298
7299 * layout.adb (Layout_Type): For composite types, do not set Esize.
7300 * freeze.adb (Set_Small_Size): Remove test on alignment and do not
7301 set Esize.
7302 (Size_Known): Look at the RM size of components instead of the Esize.
7303 (Freeze_Record_Type): Look at the RM size instead of the Esize to
7304 issue warning and activate Implicit_Packing.
7305 (Freeze_Entity): Likewise. Do not issue a warning for alias/atomic
7306 if the Esize is not known.
7307 * sem_ch13.adb (Analyze_Attribute_Definition_Clause) <Size>: Set Esize
7308 for elementary types only.
7309 (Analyze_Record_Representation_Clause): Look at the RM size instead
7310 of the Esize to issue errors.
7311 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not set Esize if it
7312 is not known.
7313 <E_Record_Type>: Look at the RM size instead of the Esize. Remove
2c7f9cc0 7314 obsolete block.
fc893455
AC
7315 Look at the RM size instead of the Esize for types if the latter is
7316 not known.
7317 (gnat_to_gnu_field): Use Known_Esize instead of Known_Static_Esize.
7318
73192011-08-04 Ed Schonberg <schonberg@adacore.com>
7320
7321 * sem_type.adb: proper handling of equality not involving anonymous
7322 access types.
7323
b37d5bc6
AC
73242011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7325
7326 * exp_ch7.adb (Create_Finalizer): Remove local variables Spec_Nod and
7327 Vis_Decls. When creating a library-level finalizer for a package spec,
7328 both the declaration and body of the finalizer are inserted either in
7329 the visible or private declarations of the package spec.
7330
73312011-08-04 Javier Miranda <miranda@adacore.com>
7332
7333 * sem_ch3.adb (Derive_Subprograms): Complete assertion to request the
7334 use of the full-view of a type when invoking Is_Ancestor.
7335 * sem_type.adb (Is_Ancestor): For consistency, when the traversal of
7336 the full-view of private parents is requested, then use also the
7337 full-view of the parent of the first derivation.
7338
7ab4d95a
AC
73392011-08-04 Tristan Gingold <gingold@adacore.com>
7340
7341 * s-taprop-vxworks.adb (Enter_Task): Use System.Float_Control.Reset
7342 instead of the locally imported procedure.
7343 * s-taprop-mingw.adb (Enter_Task): Ditto.
7344 * s-valrea.adb (Scan_Real): Ditto.
7345 * s-imgrea.adb (Set_Image_Real): Ditto.
7346 * s-flocon.ads: Make the package pure.
7347
73482011-08-04 Thomas Quinot <quinot@adacore.com>
7349
7350 * sinfo.ads, sinfo.adb (Debug_Statement, Set_Debug_Statement): Remove.
7351 * tbuild.ads, tbuild.adb (Make_Pragma): Adjust accordingly.
7352 * sinfo-cn.ads, sinfo-cn.adb (Change_Name_To_Procedure_Call_Statement):
7353 New subprogram, moved here from...
7354 * par.adb, par-ch5.adb (P_Statement_Name): ... here.
7355 * par-prag.adb (Par.Prag, case Pragma_Debug): Do not perform any
7356 rewriting of the last argument into a procedure call statement here...
7357 * sem_prag.adb (Analyze_Pragma, case Pragma_Debug): ...do it there
7358 instead.
7359
73602011-08-04 Thomas Quinot <quinot@adacore.com>
7361
7362 * par_sco.adb: Minor reformatting.
7363
51c400f5
AC
73642011-08-04 Robert Dewar <dewar@adacore.com>
7365
7366 * erroutc.adb: Minor reformatting.
7367
73682011-08-04 Thomas Quinot <quinot@adacore.com>
7369
7370 * par_sco.adb: Comment update.
7371
73722011-08-04 Tristan Gingold <gingold@adacore.com>
7373
7374 * s-flocon.ads: New file.
7375 * g-flocon.ads: Now a renaming of s-flocon.
7376 * Makefile.rtl: Add s-flocon.o
7377
6a49f110
AC
73782011-08-04 Javier Miranda <miranda@adacore.com>
7379
7380 * exp_strm.adb (Build_Array_Input_Function): if the array type is
7381 constrained, do not attempt to build a subtype of it.
7382
73832011-08-04 Yannick Moy <moy@adacore.com>
7384
7385 * errout.ads Change comments: remove 'R'M as an example where quotes
7386 are needed; add ALFA as another case where quotes are not needed
7387 * erroutc.adb (Set_Msg_Insertion_Reserved_Word): add ALFA as another
7388 case where quotes are not needed.
7389 * sem_ch11.adb, sem_ch13.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
7390 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_prag.adb, sem_res.adb:
7391 Remove all occurrences of 'A'L'F'A
7392
73932011-08-04 Ed Schonberg <schonberg@adacore.com>
7394
7395 * sem_ch13.adb: check legality of invariant pragma.
7396
a4640a39
AC
73972011-08-04 Eric Botcazou <ebotcazou@adacore.com>
7398
7399 * bindgen.adb: Add comments.
7400
74012011-08-04 Yannick Moy <moy@adacore.com>
7402
7403 * einfo.adb, einfo.ads: Free Flag254 and make Formal_Proof_On a
7404 synthesized flag.
7405 * sem_prag.adb (Analyze_Pragma): record the pragma Annotate
7406 (Formal_Proof, On/Off) in the Rep_Item list of the current subprogram.
7407
74082011-08-04 Robert Dewar <dewar@adacore.com>
7409
7410 * exp_ch7.adb, exp_ch6.adb, sem_ch3.adb, layout.adb, sem_ch5.adb,
7411 osint-c.ads, sem_util.ads, gnat1drv.adb, targparm.ads, sem_ch6.adb,
7412 sem_ch13.adb, s-pooloc.adb: Minor reformatting.
7413
39ade2f9
AC
74142011-08-04 Thomas Quinot <quinot@adacore.com>
7415
7416 * s-pooloc.ads, s-pooglo.ads: Minor reformatting
7417
74182011-08-04 Thomas Quinot <quinot@adacore.com>
7419
7420 PR ada/47880
7421 * s-pooloc.adb (Deallocate): Fix the case of deallocating the only
7422 allocated object.
7423
74242011-08-04 Robert Dewar <dewar@adacore.com>
7425
7426 * einfo.ads, exp_ch4.adb: Minor reformatting.
7427
74282011-08-04 Jerome Lambourg <lambourg@adacore.com>
7429
7430 * back_end.ads (Gen_Or_Update_Object_File): Add more comments.
7431
7efc3f2d
AC
74322011-08-04 Ed Schonberg <schonberg@adacore.com>
7433
7434 * exp_ch4.adb (Expand_Composite_Equality): code cleanup: use component
7435 type in all cases to compute list of primitive operations, because full
7436 view may be an itype that is not attached to the list of declarations.
7437
74382011-08-04 Eric Botcazou <ebotcazou@adacore.com>
7439
7440 * bindgen.adb (Gen_Adafinal_Ada): Generate an early return if the
7441 library has already been finalized.
7442 (Gen_Adafinal_C): Likewise.
7443 (Gen_Adainit_Ada): Generate an early return if the library has
7444 already been elaborated.
7445 (Gen_Adainit_C): Likewise.
7446 (Gen_Output_File_Ada): Generate an elaboration flag.
7447 (Gen_Output_File_C): Likewise.
7448
f65df609
HK
74492011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7450
7451 * exp_ch4.adb (Expand_Allocator_Expression): Disable the generation of
7452 Set_Finalize_Address_Ptr for CodePeer because Finalize_Address was not
7453 built in the first place.
7454 (Expand_N_Allocator): Disable the generation of Set_Finalize_Address_Ptr
7455 for CodePeer because Finalize_Address was not built to begin with.
7456 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Ditto.
7457
a0fb8fe8
AC
74582011-08-04 Pascal Obry <obry@adacore.com>
7459
7460 * adaint.c (__gnat_tmp_name): Use current process id to create temp
7461 filenames, this ensures unicity of filenames across processes.
7462
74632011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7464
7465 * bindgen.adb (Gen_Finalize_Library_Ada): Rename generated routine
7466 Raise_Controlled to Raise_From_Controlled_Operation. Update the
7467 signature of Raise_From_Controlled_Operation by adding flag From_Abort.
7468 Add False as the actual to From_Abort in the generated call to
7469 Raise_From_Controlled_Operation.
7470
74712011-08-04 Jerome Lambourg <lambourg@adacore.com>
7472
7473 * osint-c.ads, osint-c.adb (Set_Library_Info_Name): Move to declaration
7474 so that the ali file name can be retrieved from outside of this package.
7475 * back_end.ads, back_end.adb (Gen_Or_Update_Object_File): New method
7476 doing nothing in the general case, but used to update the object file
7477 timestamp if directly generated by the backend.
7478 * gnat1drv.adb (Gnat1drv): Make sure the object file's timestamp is set
7479 to a later time than the ali file one.
7480
9534ab17
AC
74812011-08-04 Yannick Moy <moy@adacore.com>
7482
7483 * einfo.adb, einfo.ads (Formal_Proof_On): new flag set on subprogram
7484 entities whose body contains an Annotate pragma which forces formal
7485 proof on this body.
7486 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
7487 sem_ch6.adb, sem_ch9.adb, sem_res.adb: Adapt call to
7488 Mark_Non_ALFA_Subprogram to pass in a message and node.
7489 * sem_prag.adb (Analyze_Pragma): add treatment of pragma Annotate
7490 (Forma_Proof, On) which sets the flag Formal_Proof_On in the
7491 surrounding subprogram.
7492 * sem_util.adb, sem_util.ads (Mark_Non_ALFA_Subprogram,
7493 Mark_Non_ALFA_Subprogram_Unconditional): if the subprogram being marked
7494 as not in ALFA is annotated with Formal_Proof being On, then an error
7495 is issued based on the additional parameters for message and node.
7496 * snames.ads-tmpl (Name_Formal_Proof): new name for annotation.
7497 * gcc-interface/Make-lang.in: Update dependencies.
7498
74992011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7500
7501 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Do not generate
7502 Finalize_Address when CodePeer is enabled.
7503
75042011-08-04 Pascal Obry <obry@adacore.com>
7505
7506 * adaint.c (__gnat_tmp_name): Use _tempnam() instead of tempnam() as
7507 the latter returns a pointer to a static buffer which is deallocated
7508 at the end of the routine.
7509
5c0e97dd
AC
75102011-08-04 Yannick Moy <moy@adacore.com>
7511
7512 * sem_ch3.adb (Array_Type_Declaration): move test for type in ALFA
7513 after index creation; mark unconstrained base array type generated as
7514 being in/not in ALFA as well
7515 (Make_Index): mark subtype created as in/not in ALFA
7516 * sem_ch5.adb (Analyze_Iteration_Scheme): mark entity for iterating
7517 over a loop as in/not in ALFA, depending on its type and form of loop
7518 iteration.
7519
75202011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7521
7522 * exp_ch7.adb (Build_Object_Declarations): Initialize flag Abort
7523 directly to False on .NET and JVM.
7524
7a93c64b
YM
75252011-08-04 Yannick Moy <moy@adacore.com>
7526
7527 * sem_ch3.adb (Constrain_Enumeration, Constrain_Integer): remove
7528 constraint that subtype must come from source code to be in ALFA, so
7529 that anonymous subtypes can be in ALFA too.
7530
e9a1ed9b
YM
75312011-08-04 Yannick Moy <moy@adacore.com>
7532
7533 * sem_ch3.adb (Analyze_Object_Declaration): remove obsolete addition of
7534 reference for ALFA mode.
7535 * lib-xref-alfa.adb, lib-xref.ads (Traverse_Compilation_Unit): make
7536 procedure public so as to use it from formal verification back-end.
7537
8e293fbd
AC
75382011-08-04 Jerome Lambourg <lambourg@adacore.com>
7539
7540 * g-comlin.adb (For_Each_Simple_Switch.Is_In_Config): Remove the
7541 invalid checks of the Parameter, making Remove_Switch not working
7542 correctly.
7543
75442011-08-04 Arnaud Charlet <charlet@adacore.com>
7545
7546 * targparm.ads: Update header: no run-time exception is needed on this
7547 file.
7548
75492011-08-04 Vincent Celier <celier@adacore.com>
7550
7551 * a-fihema.adb: Use System.IO instead of GNAT.IO
7552
75532011-08-04 Thomas Quinot <quinot@adacore.com>
7554
7555 * sem_ch3.adb (Access_Definition): Anonymous access to subprogram types
7556 are forbidden in Compiler_Unit mode.
7557
cfae2bed
AC
75582011-08-04 Robert Dewar <dewar@adacore.com>
7559
7560 * sem_util.adb: Minor reformatting.
7561
75622011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7563
7564 * bindgen.adb (Gen_Finalize_Library_Ada): Update the import string for
7565 library-level finalizers.
7566 (Gen_Finalize_Library_C): Update the import string for library-level
7567 finalizers.
7568 (Gen_Finalize_Library_Defs_C): Update the definition name of a
7569 library-level finalizer.
7570 * exp_ch7.adb: Remove with and use clauses for Stringt.
7571 (Create_Finalizer): Remove local variables Conv_Name, Prag_Decl,
7572 Spec_Decl. Add local variable Body_Id. The names of library-level
7573 finalizers are now manually fully qualified and are no longer external.
7574 A single name is now capable of servicing .NET, JVM and non-VM targets.
7575 Pragma Export is no longer required to provide visibility for the name.
7576 (Create_Finalizer_String): Removed.
7577 (New_Finalizer_Name): New routine which mimics New_..._Name.
7578
01f0729a
AC
75792011-08-04 Eric Botcazou <ebotcazou@adacore.com>
7580
7581 * sem_elab.adb (Check_Internal_Call_Continue): Change the type of the
7582 elaboration counter to Standard_Short_Integer.
7583 * sem_util.adb (Build_Elaboration_Entity): Likewise.
7584 * bindgen.adb (Gen_Elab_Externals_Ada): Adjust to above change.
7585 (Gen_Elab_Externals_C): Likewise.
7586
75872011-08-04 Ed Falis <falis@adacore.com>
7588
7589 * system-vxworks-arm.ads, system-vxworks-sparcv9.ads,
7590 system-vxworks-ppc.ads, system-vxworks-m68k.ads,
7591 system-vxworks-mips.ads, system-vxworks-x86.ads
7592 (Always_Compatible_Rep): set to False for all VxWorks targets.
7593
2c1b72d7
AC
75942011-08-04 Robert Dewar <dewar@adacore.com>
7595
7596 * par_sco.adb, prj-proc.adb, make.adb, bindgen.adb, prj.adb, prj.ads,
7597 makeutl.adb, makeutl.ads, prj-nmsc.adb, exp_ch5.adb, exp_ch12.adb,
7598 exp_ch7.ads, exp_util.ads, sem_util.ads, g-comlin.ads, exp_ch6.adb,
7599 exp_ch6.ads, lib-xref.ads, exp_ch7.adb, exp_util.adb, exp_dist.adb,
7600 exp_strm.adb, gnatcmd.adb, freeze.adb, g-comlin.adb, lib-xref-alfa.adb,
7601 sem_attr.adb, sem_prag.adb, sem_util.adb, sem_elab.adb, sem_ch8.adb,
7602 sem_ch11.adb, sem_eval.adb, sem_ch13.adb, sem_disp.adb, a-fihema.adb:
7603 Minor reformatting and code reorganization.
7604
76052011-08-04 Emmanuel Briot <briot@adacore.com>
7606
7607 * projects.texi: Added doc for aggregate projects.
7608
824e9320
AC
76092011-08-04 Emmanuel Briot <briot@adacore.com>
7610
7611 * prj-proc.adb, prj-nmsc.adb, prj-env.adb (Process_Declarative_Items):
7612 Add support for overriding the Project_Path in aggregate projects.
7613
76142011-08-04 Robert Dewar <dewar@adacore.com>
7615
7616 * a-cofove.ads: Minor reformatting.
7617
76182011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7619
7620 * exp_ch7.adb (Build_Adjust_Or_Finalize_Statements): Update the comment
7621 on the generated code.
7622 (Build_Finalize_Statements): Update the comment on the generated code.
7623 (Build_Initialize_Statements): Update the comment on the generated code.
7624 (Build_Object_Declarations): Add local variable Result. The object
7625 declarations are now built in sequence.
7626 * rtsfind.ads: Add RE_Exception_Occurrence_Access to tables RE_Id and
7627 RE_Unit_Table.
7628
76292011-08-04 Robert Dewar <dewar@adacore.com>
7630
7631 * checks.adb, alfa.adb, alfa.ads: Minor reformatting.
7632
76332011-08-04 Eric Botcazou <ebotcazou@adacore.com>
7634
7635 * einfo.ads (Elaboration_Entity): Document new definition and use.
7636 (Elaboration_Entity_Required): Adjust to above change.
7637 * exp_attr.adb (Expand_N_Attribute_Reference): Likewise.
7638 * exp_ch12.adb: And with and use for Snames.
7639 (Expand_N_Generic_Instantiation): Test 'Elaborated attribute.
7640 * exp_util.adb (Set_Elaboration_Flag): Likewise.
7641 * sem_attr.adb (Analyze_Attribute) <Check_Library_Unit>: Delete.
7642 <Check_Unit_Name>: Deal with N_Expanded_Name.
7643 <Attribute_Elaborated>: Extend to all unit names.
7644 * sem_elab.adb: And with and use for Uintp.
7645 (Check_Internal_Call_Continue): Adjust to Elaboration_Entity change.
7646 * sem_util.ads (Build_Elaboration_Entity): Adjust comment.
7647 * sem_util.adb (Build_Elaboration_Entity): Change type to Integer.
7648 * bindgen.adb (Gen_Elab_Externals_Ada): New local subprogram taken
7649 from Gen_Adainit_Ada.
7650 (Gen_Elab_Externals_C): Likewise, but taken from Gen_Adainit_C.
7651 (Gen_Adafinal_Ada): Remove redundant test. In the non-main program
7652 case, do not call System.Standard_Library.Adafinal; instead call
7653 finalize_library if needed.
7654 (Gen_Adafinal_C): Likewise.
7655 (Gen_Adainit_Ada): Do not set SSL.Finalize_Library_Objects in the
7656 non-main program case.
7657 (Gen_Adainit_C): Generate a couple of external declarations here.
7658 In the main program case, set SSL.Finalize_Library_Objects.
7659 (Gen_Elab_Calls_Ada): Adjust to Elaboration_Entity change.
7660 (Gen_Elab_Calls_C): Likewise.
7661 (Gen_Finalize_Library_Ada): Likewise. Skip SAL interface units.
7662 (Gen_Finalize_Library_C): Likewise. Generate a full function.
7663 (Gen_Main_C): Put back call to Ada_Final and don't finalize library
7664 objects here.
7665 (Gen_Output_File_Ada): Generate pragma Linker_Destructor for Ada_Final
7666 if -a is specified. Call Gen_Elab_Externals_Ada. Move around call to
7667 Gen_Adafinal_Ada.
7668 (Gen_Output_File_C): Generate __attribute__((destructor)) for Ada_Final
7669 if -a is specified. Call Gen_Elab_Externals_C. Remove useless couple
2c7f9cc0 7670 of external declarations. Call Gen_Finalize_Library_C.
824e9320 7671
316d9d4f
EB
76722011-08-04 Emmanuel Briot <briot@adacore.com>
7673
7674 * prj.adb, prj.ads, makeutl.adb, makeutl.ads (Complete_Mains,
7675 Compute_Compilation_Phases): new subprogram.
7676 (Builder_Data, Builder_Project_Tree_Data): new subprogram and type
7677 The number of mains as well as the various compilation phases that
7678 need to be run are now project tree specific, since various
7679 aggregated trees might have different requirements. In particular,
7680 they do not all require bind or link phases.
7681
9434c32e
EB
76822011-08-04 Emmanuel Briot <briot@adacore.com>
7683
7684 * prj.adb, prj.ads, makeutl.adb, makeutl.ads, prj-env.adb
7685 (Project_Tree_Appdata): New type.
7686 It is now possible to associate application-specific data to a project
7687 tree. In particular, this is used in the gprbuild builder to avoid a
7688 number of global tables and htables, especially now that there can be
7689 several project trees loaded at once because of aggregate projects.
7690 (Debug_Name): new procedure.
7691 * projects.texi: Clarify syntax of "**" for Source_Dirs
7692
41ba34db
EB
76932011-08-03 Emmanuel Briot <briot@adacore.com>
7694
7695 * prj.ads, makeutl.adb, makeutl.ads (Queue.Insert): now also inserts
7696 the "roots" for a main.
7697 (Fill_From_Project): add support for aggregate projects. Main units
7698 in aggregated projects are now automatically added in the list of
7699 files to build (although this fails later on in gprbuild, because
7700 these files are not using the root proejct tree, so this needs
7701 further cleanup)
7702 * gcc-interface/Make-lang.in: Update dependencies.
7703
fccd42a9
AC
77042011-08-03 Yannick Moy <moy@adacore.com>
7705
7706 * sem_ch4.adb (Analyze_Conditional_Expression): only allow boolean
7707 conditional expression in ALFA.
7708 * sem_res.adb (Resolve_Conditional_Expression): mark non-boolean
7709 expressions as not in ALFA.
7710
77112011-08-03 Robert Dewar <dewar@adacore.com>
7712
7713 * a-cofove.adb: Minor reformatting.
7714
77152011-08-03 Emmanuel Briot <briot@adacore.com>
7716
7717 * make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads
7718 (Insert_Project_Sources, Insert_withed_Sources_For): moved from the
7719 gprbuild sources.
7720 These packages are more logically placed in the Queue package, since
7721 they manipulate the queue. It is also likely that they can be adapted
7722 for gnatmake, thus sharing more code.
7723 (Finish_Program, Fail_Program): moved from the gprbuild sources, so
7724 that we could move the above.
7725
77262011-08-03 Emmanuel Briot <briot@adacore.com>
7727
7728 * errutil.adb (Finalize): clean up the list of error messages on exit.
7729 Calling this subprogram multiple times will no longer show duplicate
7730 error messages on stderr.
7731
77322011-08-03 Emmanuel Briot <briot@adacore.com>
7733
7734 * g-comlin.adb, g-comlin.ads (Set_Command_Line): ignore the parameter
7735 Getopt_Switches when we have already define a command line
7736 configuration.
7737
5e8c8e44
YM
77382011-08-03 Yannick Moy <moy@adacore.com>
7739
7740 * sem_ch11.adb (Analyze_Raise_xxx_Error): do not mark such nodes as not
7741 in ALFA. Instead, they are considered as assertions to prove.
7742 * sem_ch4.adb (Analyze_Conditional_Expression): do not always mark such
7743 nodes as not in ALFA. Instead, include conditional expressions in ALFA
7744 if they have no ELSE part, or if they occur in pre- and postconditions,
7745 where the Condition cannot have side-effects in ALFA
7746 (Analyze_Membership_Op): do not mark such nodes as not in ALFA
7747 (Analyze_Type_Conversion): do not always mark such nodes as not in ALFA.
7748 Instead, include type conversion between scalar types in ALFA.
7749 * sem_ch6.adb (Process_Formals): correctly mark a parameter in ALFA
7750 if-and-only-if its type is in ALFA.
7751
5ffe0bab
AC
77522011-08-03 Thomas Quinot <quinot@adacore.com>
7753
7754 * scos.adb, get_scos.adb, put_scos.adb
7755 New code letter for decisions: G (entry guard)
7756 * par_sco.adb
7757 (Traverse_Subprogram_Body): Rename to...
7758 (Traverse_Subprogram_Or_Task_Body): New subrpogram.
7759 (Traverse_Protected_Body): New subprogram
7760 (Traverse_Declarations_Or_Statements): Add traversal of task bodies,
7761 protected bodies and entry bodies.
7762
77632011-08-03 Yannick Moy <moy@adacore.com>
7764
7765 * einfo.adb, einfo.ads (Is_Postcondition_Proc): new flag for procedure
7766 entities with get/set subprograms, which is set on procedure entities
7767 generated by the compiler for a postcondition.
7768 * sem_ch6.adb (Process_PPCs): set new flag on postcondition procedures
7769 * alfa.adb, alfa.ads (Get_Entity_For_Decl): new function returning the
7770 entity for a declaration
7771 (Get_Unique_Entity_For_Decl): new function returning an entity which
7772 represents a declaration, so that matching spec and body have the same
7773 entity.
7774
77752011-08-03 Robert Dewar <dewar@adacore.com>
7776
7777 * a-except-2005.adb, a-cfhama.adb, a-cfhase.adb, a-cfhase.ads,
7778 a-cforma.adb, a-cforse.ads, a-cforse.adb: Minor reformatting
7779
77802011-08-03 Yannick Moy <moy@adacore.com>
7781
7782 * lib-xref-alfa.adb (Detect_And_Add_ALFA_Scope): make the subprogram
7783 library-level because retriction No_Implicit_Dynamic_Code in the
7784 front-end prevents its definition as a local subprogram
7785 (Traverse_Compilation_Unit): extract new procedure from Add_ALFA_File,
7786 for reuse in other contexts
7787 (Traverse_Declarations_Or_Statements,
7788 Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
7789 Traverse_Package_Declaration, Traverse_Subprogram_Body): make all these
7790 procedures take a callback parameter to be called on all declarations
7791 * lib-xref.ads
7792 (Traverse_All_Compilation_Units): new generic function to traverse a
7793 compilation unit and call a callback parameter on all declarations
7794
f9ad6b62
AC
77952011-08-03 Javier Miranda <miranda@adacore.com>
7796
7797 * sem_prag.adb (Process_Interface_Name): Allow duplicated export names
7798 in Java since they are always enclosed in a namespace that
7799 differentiates them, and overloaded entities are supported by the VM.
7800
78012011-08-03 Ed Schonberg <schonberg@adacore.com>
7802
7803 * checks.adb (Determine_Range): If a computed bound of an operation is
7804 outside the range of the base type of the expression, and overflow
7805 checks are enabled, the result is unknown and cannot be used for any
7806 subsequent constant folding.
7807 * sem_eval.adb (Compile_Time_Compare): if the bounds of one operand are
7808 unknown, so is the result of the comparison.
7809
78102011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
7811
7812 * a-except-2005.adb (Raise_From_Controlled_Operation): Add new formal
7813 From_Abort. When finalization was triggered by an abort, propagate
7814 Standard'Abort_Signal rather than Program_Error.
7815 * a-except-2005.ads (Raise_From_Controlled_Operation): Add new formal
7816 From_Abort.
7817 * a-except.adb (Raise_From_Controlled_Operation): Add new formal
7818 From_Abort. When finalization was triggered by an abort, propagate
7819 Standard'Abort_Signal rather than Program_Error.
7820 * a-except.ads:(Raise_From_Controlled_Operation): Add new formal
7821 From_Abort.
7822 * exp_ch7.adb:(Build_Adjust_Or_Finalize_Statements): New local variable
7823 Abort_Id. Update the calls to Build_Object_Declarations and
7824 Build_Raise_Statement to include Abort_Id.
7825 (Build_Adjust_Statements): New local variable Abort_Id. Update the
7826 calls to Build_Object_Declarations and Build_Raise_Statement to include
7827 Abort_Id.
7828 (Build_Finalize_Statements): New local variable Abort_Id. Update the
7829 calls to Build_Object_Declarations and Build_Raise_Statement to include
7830 Abort_Id.
7831 (Build_Components): Create an entity for Abort_Id when exceptions are
7832 allowed on the target.
7833 (Build_Finalizer): New local variable Abort_Id.
7834 (Build_Initialize_Statements): New local variable Abort_Id. Update the
7835 calls to Build_Object_Declarations and Build_Raise_Statement to include
7836 Abort_Id.
7837 (Build_Object_Declarations): Add new formal Abort_Id. Create the
7838 declaration of flag Abort_Id to preserve the original abort status
7839 before finalization code is executed.
7840 (Build_Raise_Statement): Add new formal Abort_Id. Pass Abort_Id to
7841 runtime routine Raise_From_Controlled_Operation.
7842 (Create_Finalizer): Update the call to Build_Raise_Statement to include
7843 Abort_Id. Update the call to Build_Object_Declarations to include
7844 Abort_Id. Update the layout of the finalizer body.
7845 (Make_Handler_For_Ctrl_Operation): Add an actual for From_Abort.
7846 (Process_Transient_Objects): New local variable Abort_Id. Remove the
7847 clunky code to create all flags and objects related to
7848 exception propagation and replace it with a call to
7849 Build_Object_Declarations. Update the call to Build_Raise_Statement to
7850 include Abort_Id.
7851 * exp_ch7.ads (Build_Object_Declarations): Moved from body to spec.
7852 Add new formal Abort_Id and associated comment on its use.
7853 (Build_Raise_Statement): Add new formal Abort_Id and associated comment
7854 on its use.
7855 * exp_intr.adb (Expand_Unc_Deallocation): New local variable Abort_Id.
7856 Remove the clunky code to create all flags and objects related to
7857 exception propagation and replace it with a call to
7858 Build_Object_Declarations. Update the call to Build_Raise_Statement.
7859
78602011-08-03 Eric Botcazou <ebotcazou@adacore.com>
7861
7862 * s-tassta.adb: Fix minor typos.
7863
78642011-08-03 Robert Dewar <dewar@adacore.com>
7865
7866 * rtsfind.ads, makeutl.ads, prj.ads, prj.adb, make.adb,
7867 lib-writ.adb, makeutl.adb, s-soflin.ads, clean.adb: Minor reformatting.
7868
1cdfa9be
AC
78692011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
7870
7871 * exp_ch7.adb (Create_Finalizer): Treat freeze nodes in similar fashion
7872 to packages. This ensures that the finalizer body will not end up
7873 inside the freeze node.
7874 (Process_Declarations): Add code to detect whether a freeze node has a
7875 nested finalization collection.
7876
78772011-08-03 Pascal Obry <obry@adacore.com>
7878
7879 * g-awk.adb, g-awk.ads: Make GNAT.AWK API compatible with Ada 2005.
7880 (Current_Session): Return a not null access to Session_Type.
7881 (Default_Session): Likewise.
7882
243cae0a
AC
78832011-08-03 Robert Dewar <dewar@adacore.com>
7884
7885 * a-cfdlli.adb, bindgen.adb, exp_ch4.adb, exp_ch13.adb, sem_warn.adb,
7886 exp_ch3.adb, exp_ch3.ads: Minor reformatting.
7887
78882011-08-03 Pascal Obry <obry@adacore.com>
7889
7890 * g-awk.ads: Minor comment fix.
7891
78922011-08-03 Sergey Rybin <rybin@adacore.com>
7893
7894 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
7895 the tree structure related to discriminant constraints.
7896 Original_Discriminant cannot be used any more for computing the
7897 defining name for the reference to a discriminant.
7898
78992011-08-03 Ed Schonberg <schonberg@adacore.com>
7900
7901 * sem_disp.adb (Is_Tag_Indeterminate): If the return type of the
7902 function is not visibly tagged, this is not a dispatching call and
7903 therfore is not Tag_Indeterminate, even if the function is marked as
7904 dispatching on result.
7905
f553e7bc
AC
79062011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
7907
7908 * exp_ch13.adb: Add with and use clauses for Restrict and Rident.
7909 (Expand_N_Free_Statement): Add a guard to protect against run-times
7910 which do not support controlled types.
7911 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Add a guard to protect
7912 against run-times which do not support controlled types.
7913 * exp_ch4.adb (Complete_Controlled_Allocation): Add a guard to protect
7914 against run-times which do not support controlled types.
7915 * exp_ch7.adb (Build_Finalization_Collection): Add a guard to protect
7916 against run-times which do not support controlled types.
7917 * exp_util.adb (Needs_Finalization): Code reformatting. Add a guard to
7918 protect against run-times which do not support controlled types.
7919
79202011-08-03 Eric Botcazou <ebotcazou@adacore.com>
7921
7922 * exp_intr.adb: Put back with and use clauses for Exp_Ch11.
7923 (Expand_Unc_Deallocation): Expand the AT_END handler at the very end.
7924
e4982b64
AC
79252011-08-03 Ed Schonberg <schonberg@adacore.com>
7926
7927 * exp_ch5.adb (Expand_Iterator_Loop): indicate that the cursor is
7928 modified in the source, to prevent spurious warnings when compiling
7929 with -gnatg.
7930
79312011-08-03 Thomas Quinot <quinot@adacore.com>
7932
7933 * a-except-2005.adb: Minor reformatting.
7934
79352011-08-03 Ed Schonberg <schonberg@adacore.com>
7936
7937 * sem_warn.adb (Check_One_Unit): if the only mention of a withed unit
7938 is a renaming declaration in the private part of a package, do not emit
7939 a warning that the with_clause could be moved because the renaming may
7940 be used in the body or in a child unit.
7941
79422011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
7943
7944 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
7945 Propagate the Comes_From_Source attribute from the original return
7946 object to the renaming.
7947
79482011-08-03 Jose Ruiz <ruiz@adacore.com>
7949
7950 * exp_ch7.adb (Build_Raise_Statement): Do not call
7951 Raise_From_Controlled_Operation when this routine is not present in
7952 the run-time library.
7953 (Cleanup_Protected_Object, Cleanup_Task): For restricted run-time
7954 libraries (Ravenscar), tasks are non-terminating, and protected objects
7955 and tasks can only appear at library level, so we do not want
7956 finalization of protected objects nor tasks.
7957 * exp_intr.adb: Minor clarification in comment.
7958 bindgen.adb (Gen_Adainit_Ada, Gen_Main_C, Gen_Output_File_Ada,
7959 Gen_Output_File_C): Remove references to finalization of library-level
7960 objects when using restricted run-time libraries.
7961
79622011-08-03 Ed Schonberg <schonberg@adacore.com>
7963
7964 * sem_ch3.adb (Build_Discriminant_Constraints): Set
7965 Original_Discriminant only if the parent type is a generic formal.
7966
deb8dacc
HK
79672011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
7968
7969 * exp_ch13.adb: Add with and use clause for Targparm;
7970 (Expand_N_Free_Statement): Prevent the generation of a custom
7971 Deallocate on .NET/JVM targets since this requires pools and address
7972 arithmetic.
7973 * exp_ch4.adb (Expand_Allocator_Expression): When compiling for
7974 .NET/JVM targets, attach the newly allocated object to the access
7975 type's finalization collection. Do not generate a call to
7976 Set_Finalize_Address_Ptr on .NET/JVM because this routine does not
7977 exist in the runtime.
7978 (Expand_N_Allocator): When compiling for .NET/JVM targets, do not
7979 create a custom Allocate for object that do not require initialization.
7980 Attach a newly allocated object to the access type's finalization
7981 collection on .NET/JVM.
7982 * exp_ch5.adb (Make_Tag_Ctrl_Assignment): Add special processing for
7983 assignment of controlled types on .NET/JVM. The two hidden pointers
7984 Prev and Next and stored and later restored after the assignment takes
7985 place.
7986 * exp_ch6.adb (Expand_Call): Add local constant Curr_S. Add specialized
7987 kludge for .NET/JVM to recognize a particular piece of code coming from
7988 Heap_Management and change the call to Finalize into Deep_Finalize.
7989 * exp_ch7.adb (Build_Finalization_Collection): Allow the creation of
7990 finalization collections on .NET/JVM only for types derived from
7991 Controlled. Separate the association of storage pools with a collection
7992 and only allow it on non-.NET/JVM targets.
7993 (Make_Attach_Call): New routine.
7994 (Make_Detach_Call): New routine.
7995 (Process_Object_Declarations): Suppress the generation of
7996 build-in-place return object clean up code on .NET/JVM since it uses
7997 pools.
7998 * exp_ch7.ads (Make_Attach_Call): New routine.
7999 (Make_Detach_Call): New routine.
8000 * exp_intr.adb Add with and use clause for Targparm.
8001 (Expand_Unc_Deallocation): Detach a controlled object from a collection
8002 on .NET/JVM targets.
8003 * rtsfind.ads: Add entries RE_Attach, RE_Detach and
8004 RE_Root_Controlled_Ptr to tables RE_Id and RE_Unit_Table.
8005 * snames.ads-tmpl: Add name Name_Prev. Move Name_Prev to the special
8006 names used in finalization.
8007
80082011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8009
8010 * a-fihema.adb: Add with and use clauses for System.Soft_Links.
8011 (Attach, Detach): Lock the current task when chaining an object onto a
8012 collection.
8013
df3e68b1
HK
80142011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8015
8016 * a-except.adb, a-except-2005.adb (Raise_From_Controlled_Operation):
8017 Rewritten to create the message strings when the exception is not
8018 raised by an abort during finalization.
8019 * a-except.ads, a-except-2005.ads: Add pragma Export for procedure
8020 Raise_From_Controlled_Operation and update its associated comment.
8021 * a-fihema.ads, a-fihema.adb: New GNAT unit.
8022 Ada.Finalization.Heap_Management provides key functionality
8023 associated with controlled objects on the heap, their creation,
8024 finalization and reclamation. Type Finalization_Collection is
8025 effectively a wrapper which sits ontop of a storage pool and performs
8026 all necessary bookkeeping for all the objects it contains. Each
8027 access-to-controlled or access-to-class-wide type receives a collection
8028 as part of its expansion. The compiler generates buffer code and
8029 invokes Allocate / Deallocate to create and destroy allocated
8030 controlled objects.
8031 * a-finali.adb ("="): Removed.
8032 * a-finali.ads ("="): Removed. Controlled types no longer carry hidden
8033 fields Prev and Next.
8034 * ali.adb (Scan_ALI): Add parsing code to process PF / Has_Finalizer.
8035 A library unit with at least one controlled object on the library level
8036 has a special finalizer which is invoked by the binder. To signal this,
8037 ali files carry field PF.
8038 * ali.ads: New field in type Unit_Record called Has_Finalizer. Add
8039 associated comment on field usage.
8040 * a-tags.adb (Get_RC_Offset): Removed.
8041 (Needs_Finalization): New routine.
8042 * a-tags.ads: Update the structure of the GNAT dispatch tables.
8043 Dispatch tables now carry field Needs_Finalization which provides
8044 runtime indication whether a type is controlled or has controlled
8045 components or both. Remove field RC_Offset.
8046 (Get_RC_Offset): Removed along with its associated pragma Export.
8047 Since tagged types with controlled components no longer carry hidden
8048 field _controller, the special mechanism to retrieve its location is no
8049 longer needed.
8050 (Needs_Finalization): New routine.
8051 * atree.ads, atree.adb (Elist24): New routine.
8052 (Set_Elist24): New routine.
8053 * atree.h: Add a define clause for Elist24.
8054 * bindgen.adb New library-level variable Lib_Final_Built.
8055 (Gen_Adafinal_Ada): Reimplemented. Depending on the restrictions or the
8056 presence of a VM target, the routine generates calls to the proper
8057 library finalization routine.
8058 (Gen_Adainit_Ada): Import Finalize_Library_Objects only on non-VM
8059 targets. Set the correct library finalization routine depending on
8060 whether the library has controlled objects or this is a VM compilation.
8061 (Gen_Finalize_Library_Ada): New routine. This procedure generates calls
8062 to library-level finalizers of compiled units in reverse order of
8063 elaboration. It also produces exception management code and reraises a
8064 potential exception after all units have been finalized.
8065 (Gen_Finalize_Library_C): New routine. This procedure generates calls to
8066 library-level finalizers of compiled units in reverse order of
8067 elaboration.
8068 (Gen_Finalize_Library_Defs_C): New routine. This procedure generates the
8069 definitions of all library-level finalizers available to the compilation
8070 (Gen_Main_Ada): Directly call Adafinal which now contails all target
8071 dependent code.
8072 (Gen_Main_C): Add new local constant Needs_Library_Finalization. Call
8073 System.Standard_Library.Adafinal directly. If the library needs
8074 finalization actions, create the sequence of finalization calls.
8075 (Gen_Output_File_Ada): Alphabetize local variables and constants.
8076 Generate a with clause for System.Soft_Links when compiling for a VM.
8077 Remove the code which imports System.Standard_Library.Adafinal as
8078 Do_Finalize. Generate the library finalization routine.
8079 (Gen_Output_File_C): Add new local constant Needs_Library_Finalization.
8080 If the library needs finalization actions, create all the definitions
8081 of library- level finalizers.
8082 (Has_Finalizer): New routine. Determines whether at least one compiled
8083 unit has a library-level finalizer.
8084 Add type Qualification_Mode.
8085 (Set_Unit_Name): Add a formal which controls the replacement of a dot.
8086 * einfo.adb: New usage of field 15 as Return_Flag.
8087 Remove Finalization_Chain_Entity from the usages of field 19.
8088 Remove Associated_Final_Chain from the usages of field 23.
8089 New usage of field 23 as Associated_Collection.
8090 New usage of field 24 as Finalizer.
8091 New usage of flag 252 as Is_Processed_Transient.
8092 (Associated_Final_Chain): Removed.
8093 (Associated_Collection): New routine.
8094 (Finalization_Chain_Entity): Removed.
8095 (Finalizer): New routine.
8096 (Is_Finalizer): New routine.
8097 (Is_Processed_Transient): New routine.
8098 (Return_Flag): New routine.
8099 (Set_Associated_Final_Chain): Removed.
8100 (Set_Associated_Collection): New routine.
8101 (Set_Finalization_Chain_Entity): Removed.
8102 (Set_Finalizer): New routine.
8103 (Set_Is_Processed_Transient): New routine.
8104 (Set_Return_Flag): New routine.
8105 (Write_Entity_Flags): Include Is_Processed_Transient to the list of
8106 displayed flags.
8107 (Write_Field8_Name): Alphabetize the output.
8108 (Write_Field11_Name): Alphabetize the output.
8109 (Write_Field12_Name): Alphabetize the output.
8110 (Write_Field13_Name): Alphabetize the output.
8111 (Write_Field14_Name): Alphabetize the output.
8112 (Write_Field15_Name): Alphabetize the output.
8113 (Write_Field16_Name): Alphabetize the output.
8114 (Write_Field17_Name): Alphabetize the output.
8115 (Write_Field18_Name): Alphabetize the output.
8116 (Write_Field19_Name): Alphabetize the output. Remove the output of
8117 Finalization_Chain_Entity.
8118 (Write_Field20_Name): Alphabetize the output.
8119 (Write_Field21_Name): Alphabetize the output.
8120 (Write_Field22_Name): Alphabetize the output.
8121 (Write_Field23_Name): Alphabetize the output. Remove the output of
8122 Associated_Final_Chain. Add output for Associated_Collection.
8123 (Write_Field24_Name): Alphabetize the output.
8124 (Write_Field25_Name): Add output for Finalizer.
8125 (Write_Field26_Name): Alphabetize the output.
8126 (Write_Field27_Name): Alphabetize the output.
8127 (Write_Field28_Name): Alphabetize the output.
8128 * einfo.ads: Add new field description for Associated_Collection and
8129 its uses in nodes.
8130 Remove Associated_Final_Chain and its uses in nodes.
8131 Remove Finalization_Chain_Entity and its uses in nodes.
8132 Add new field description for Finalizer and its uses in nodes.
8133 Add new synthesized attribute Is_Finalizer.
8134 Add new flag description for Is_Processed_Transient and its uses in
8135 nodes.
8136 Add new field description for Return_Flag and its uses in nodes.
8137 (Associated_Final_Chain): Removed along with its pragma Inline.
8138 (Associated_Collection): New routine and pragma Inline.
8139 (Finalization_Chain_Entity): Removed along with its pragma Inline.
8140 (Finalizer): New routine and pragma Inline.
8141 (Is_Finalizer): New routine and pragma Inline.
8142 (Is_Processed_Transient): New routine and pragma Inline.
8143 (Return_Flag): New routine and pragma Inline.
8144 (Set_Associated_Final_Chain): Removed along with its pragma Inline.
8145 (Set_Associated_Collection): New routine and pragma Inline.
8146 (Set_Finalization_Chain_Entity): Removed along with its pragma Inline.
8147 (Set_Finalizer): New routine and pragma Inline.
8148 (Set_Is_Processed_Transient): New routine and pragma Inline.
8149 (Set_Return_Flag): New routine and pragma Inline.
8150 * exp_aggr.adb: Alphabetize subprograms.
8151 (Build_Array_Aggr_Code): Remove formal Flist and its associated comment.
8152 (Build_Record_Aggr_Code): Remove formals Flist and Obj along with their
8153 associated comments. Remove local variables External_Final_List and
8154 Attach.
8155 Rename Ctrl_Stuff_Done to Finalization_Done. Rename local variable A to
8156 Ancestor. Remove the retrieval of finalization lists. Update the call to
8157 Make_Adjust_Call.
8158 (Convert_Aggr_In_Allocator): Remove the retrieval of finalization
8159 lists. Update the call to Late_Expansion.
8160 (Convert_Aggr_In_Assignment): Update the call to Late_Expansion.
8161 (Convert_Aggr_In_Object_Decl): Update the call to Late_Expansion.
8162 (Gen_Assign): Remove the retrieval of the finalization list used to
8163 build the assignment. Update the calls to Make_Init_Call and
8164 Make_Adjust_Call.
8165 (Gen_Ctrl_Actions_For_Aggr): Renamed to Generate_Finalization_Actions.
8166 Remove the mechanism to determine attachment levels and finalization
8167 list retrieval. Remove the processing for coextensions.
8168 (Init_Controller): Removed. Controllers no longer exist.
8169 (Late_Expansion): Remove formals Flist and Obj along with their
8170 associated comments. Update the calls to Build_Record_Aggr_Code and
8171 Build_Array_Aggr_Code.
8172 * exp_ch13.adb (Expand_N_Free_Statement): New routine.
8173 (Expand_N_Freeze_Entity): Add special processing for finalizers which
8174 appear in entry bodies, protected subprograms and task bodies.
8175 * exp_ch13.ads (Expand_N_Free_Statement): New routine.
8176 * exp_ch3.adb (Add_Final_Chain): Removed.
8177 (Build_Array_Init_Proc): Alphabetize local variables.
8178 (Build_Assignment): Alphabetize local variables. Update the call to
8179 Maked_Adjust_Call.
8180 (Build_Class_Wide_Master): Rename local variables to better reflect
8181 their role.
8182 (Build_Discriminant_Assignments): Code reformatting.
8183 (Build_Init_Call_Thru): Code reformatting.
8184 (Build_Init_Procedure): Code reformatting. Generate a special version
8185 of Deep_Finalize which is capable of finalizing all initialized
8186 components and ignore the rest.
8187 (Build_Init_Statements): Rename local variables to better reflect their
8188 role.
8189 Reimplement the mechanism to include the creation and update of an index
8190 variable called a "counter". It is used as a bookmark for tracing
8191 initialized and non-initialized components.
8192 (Build_Initialization_Call): Remove local variable Controller_Typ.
8193 Alphabetize all local variables. Remove the initialization of the
8194 record controller and update the call to Make_Init_Call.
8195 (Build_Record_Init_Proc): Rename formal Pe to Rec_Ent.
8196 New local variable Counter.
8197 (Constrain_Array): Alphabetize.
8198 (Expand_Freeze_Array_Type): Create a collection instead of a
8199 finalization list.
8200 (Expand_Freeze_Class_Wide_Type): New routine. Creates TSS primitive
8201 Finalize_Address which is used in conjunction with allocated controlled
8202 objects.
8203 (Expand_N_Object_Declaration): Remove the creation of a finalization
8204 list for anonymous access types. Update the calls to Make_Init_Call and
8205 Make_Adjust_Call.
8206 (Expand_Freeze_Record_Type): Remove local variable Flist. Remove the
8207 retrieval of finalization lists. Remove the expansion of the record
8208 controller. Create TSS primitive Finalize_Address used in conjunction
8209 with controlled objects on the heap. Create finalization collections
8210 for access-to-controlled record components.
8211 (Expand_Record_Controller): Removed.
8212 (Freeze_Type): Remove the freezing of record controllers. Freezing of
8213 class-wide types now requires additional processing. Create
8214 finalization collections for access-to-controlled types.
8215 (Increment_Counter): New routine.
8216 (Make_Counter): New routine.
8217 (Make_Eq_If): Remove the mention of Name_uController.
8218 (Make_Predefined_Primitive_Specs): There is no longer need to skip
8219 types coming from System.Finalization_Root.
8220 (Predef_Deep_Spec): Reimplemented to reflect the new parameter profiles.
8221 (Predefined_Primitive_Bodies): There is no longer need to skip types
8222 coming from System.Finalization_Root.
8223 (Stream_Operation_OK): Do not generate stream routines for
8224 type Ada.Finalization.Heap_Management.Finalization_Collection.
8225 * exp_ch3.ads: Alphabetize subprograms.
8226 * exp_ch4.adb: Remove with and use clause for Sem_Ch8.
8227 Add with and use clause for Lib.
8228 (Complete_Coextension_Finalization): Removed.
8229 (Complete_Controlled_Allocation): New routine. Create a finalization
8230 collection for anonymous access-to-controlled types. Create a custom
8231 Allocate which interfaces with the back end and the machinery in
8232 Heap_Management.
8233 (Expand_Allocator_Expression): Add necessary calls to
8234 Complete_Controlled_Allocation. Remove the retrieval of finalization
8235 lists. Update the calls to Make_Adjust_Call. Generate a call to
8236 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
8237 the associated collection.
8238 (Expand_N_Allocator): Remove the processing for dynamic coextensions.
8239 Code clean up. Remove the retrieval of finalization lists and
8240 attachment levels.
8241 Update the call to Make_Init_Call. Generate a call to
8242 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
8243 the associated collection.
8244 (Get_Allocator_Final_List): Removed. Finalization lists are not
8245 available.
8246 (Suitable_Element): Remove the mention of Name_uController.
8247 * exp_ch5.adb: Remove with and use clauses for Ttypes and Uintp.
8248 (Make_Tag_Ctrl_Assignment): Rewritten to simply do a finalization of
8249 the left hand side, carry out the assignment and adjust the left hand
8250 side.
8251 * exp_ch6.adb (Add_Final_List_Actual_To_Build_In_Place_Call): Removed.
8252 (Add_Collection_Actual_To_Build_In_Place_Call): New routine.
8253 (BIP_Formal_Suffix): Rename BIP_Final_List and BIPfinallist to
8254 BIP_Collection and BIPcollection.
8255 (Build_Heap_Allocator): New routine used to allocate the return object
8256 of a build-in-place function onto a collection.
8257 (Expand_Ctrl_Function_Call): Moved from Exp_Ch7.
8258 (Expand_Call): Do not replace direct calls to Deep routines with their
8259 aliases.
8260 (Expand_N_Extended_Return_Statement): Give all variables shorter names
8261 and update their occurrences. Add a special return flag to monitor the
8262 [ab]normal execution of the function. The flag is set right before the
8263 return statement.
8264 Rewrite the mechanism used to allocate a build-in-place return object
8265 on the heap or on a storage pool.
8266 (Is_Direct_Deep_Call): New routine.
8267 (Make_Build_In_Place_Call_In_Allocator): Add a collection to a
8268 build-in-place function call instead of a final list. Build a call to
8269 Set_Finalize_Address_Ptr to decorate the associated collection.
8270 (Make_Build_In_Place_Call_In_Anonymous_Context): Create a temporary in
8271 order to name the build-in-place function call's result for later
8272 finalization. Add a collection to a build-in-place function call
8273 instead of a final list.
8274 (Make_Build_In_Place_Call_In_Assignment): Add a collection to a
8275 build-in-place function call instead of a final list. Remove the code
8276 which moves one final list and transforms it into the actual in a
8277 nested build-in-place call.
8278 (Make_Build_In_Place_Call_In_Object_Declaration): Add a collection to a
8279 build-in-place function call instead of a final list.
8280 (Move_Final_List): Removed.
8281 (Needs_BIP_Collection): New routine.
8282 (Needs_BIP_Final_List): Removed.
8283 * exp_ch6.ads: Replace BIP_Final_List with BIP_Collection in
8284 enumeration type BIP_Formal_Kind.
8285 Update the related comment.
8286 (Needs_BIP_Collection): New routine.
8287 (Needs_BIP_Final_List): Removed.
8288 * exp_ch7.adb: Add with and use clauses for Elists, Exp_Ch6, Stringt
8289 and Ttypes. Remove with and use clauses for Sem_Type. Alphabetize the
8290 majority of subprograms in this unit. Add Name_Finalize_Address to
8291 array Name_Of and TSS_Finalize_Address to array Deep_Name_Of.
8292 (Build_Adjust_Or_Finalize_Statements): Create the adjust or finalization
8293 statements for an array type.
8294 (Build_Adjust_Statements): Create the adjust statements for a record
8295 type.
8296 (Build_Cleanup_Statements): New routine. A procedure which given any
8297 construct containing asynchronous calls, references to _master, or is a
8298 task body, a task allocation or a protected body produces the necessary
8299 runtime calls to clean up these constructs.
8300 (Build_Exception_Handler): New routine.
8301 (Build_Final_List): Removed.
8302 (Build_Finalization_Collection): New routine. A core procedure which
8303 creates a collection to service heap allocated controlled objects
8304 associated with an access-to-controlled type.
8305 (Build_Finalize_Statements): Create the finalization statements for a
8306 record types.
8307 (Build_Finalizer): New routine. A core procedure which given any
8308 construct with declarations and/or statements detects all objects which
8309 need any type of clean up (controlled objects, protected objects) and
8310 generates all necessary code to clean up the said objects in the proper
8311 order.
8312 (Build_Finalizer_Call): New routine.
8313 (Build_Initialize_Statements): Create the initialization statements for
8314 an array type. The generated routine contains code to finalize partially
8315 initialized arrays.
8316 (Build_Object_Declarations): New routine.
8317 (Build_Raise_Statement): New routine.
8318 (Clean_Simple_Protected_Objects): Removed.
8319 (Controller_Component): Removed.
8320 (Enclosing_Function): New routine.
8321 (Expand_Cleanup_Actions): Create a finalizer for a construct which has
8322 either declarations or statements or both.
8323 (Expand_N_Package_Body): Create a finalizer for a non-generic package.
8324 (Expand_N_Package_Declaration): Create a finalizer for a non-generic
8325 package.
8326 (Find_Final_List): Removed.
8327 (Global_Flist_Ref): Removed.
8328 (In_Finalization_Root): Removed.
8329 (Insert_Actions_In_Scope_Around): Determine the range of the transient
8330 scope in terms of tree nodes. Process all transient variables within
8331 that range.
8332 (Make_Adjust_Call): Rewritten. There is no longer an attach call
8333 generated after the adjust.
8334 (Make_Attach_Call): Removed.
8335 (Make_Call): New routine.
8336 (Make_Clean): Removed.
8337 (Make_Deep_Array_Body): Rewritten to simply invoke the appropriate
8338 build routines.
8339 (Make_Deep_Proc): Rewritten to generate the new profile signature used
8340 in Deep routines.
8341 (Make_Deep_Record_Body): Rewritten to simply invoke the appropriate
8342 build routines.
8343 (Make_Final_Call): Modified to simply create a call to either
8344 Deep_Finalize or Finalize.
8345 (Make_Finalize_Address_Body): New routine.
8346 (Make_Finalize_Address_Stmts): New routine. A function which produces
8347 TSS primitive Finalize_Address used in conjunction with heap allocated
8348 controlled objects.
8349 (Make_Handler_For_Ctrl_Operation): Add specialized code for .NET/JVM.
8350 (Make_Init_Call): Rewritten. There is no longer an attach call
8351 generated after initialization.
8352 (Make_Local_Deep_Finalize): New routine.
8353 (Make_Set_Finalize_Address_Ptr_Call): New routine.
8354 (Make_Transient_Block): Remove the finalization list retrieval and
8355 manipulation.
8356 (Needs_Finalization): Moved to Exp_Util.
8357 (Parent_Field_Type): New routine.
8358 (Preprocess_Components): New routine.
8359 (Process_Transient_Objects): New routine.
8360 (Wrap_HSS_In_Block): New routine.
8361 (Wrap_Transient_Declaration): Remove finalization list management and
8362 controller insertion.
8363 (Wrap_Transient_Expression): Code reformatting.
8364 (Wrap_Transient_Statement): Code reformatting.
8365 * exp_ch7.ads (Build_Final_List): Removed.
8366 (Build_Finalization_Collection): New routine.
8367 (Build_Raise_Statement): New routine.
8368 (Controller_Component): Removed.
8369 (Expand_Ctrl_Function_Call): Moved to Exp_Ch6.
8370 (Find_Final_List): Removed.
8371 (In_Finalization_Root): Removed.
8372 (Is_Simple_Protected_Type): Update related comment.
8373 (Make_Adjust_Call): New parameter profile and associated comments.
8374 (Make_Attach_Call): Removed.
8375 (Make_Final_Call): New parameter profile and associated comments.
8376 (Make_Finalize_Address_Body): New routine.
8377 (Make_Init_Call): New parameter profile and associated comments.
8378 (Make_Local_Deep_Finalize): New routine.
8379 (Make_Set_Finalize_Address_Ptr_Call): New routine.
8380 (Needs_Finalization): Moved to Exp_Util.
8381 * exp_ch9.adb (Add_Object_Pointer): Code reformatting.
8382 (Expand_N_Protected_Body): Remove the handling of finalization lists.
8383 (Find_Protection_Type): Moved to Exp_Util.
8384 * exp_disp.adb: Remove with and use clauses for Exp_Ch7.
8385 (Make_DT): Update sequence of dispatch table initialization. Remove the
8386 initialization of field RC_Offset. Add initialization of field Needs_
8387 Finalization.
8388 * exp_intr.adb (Expand_Unc_Deallocation): Code reformatting.
8389 Reimplement how an object is first finalized, then deallocated.
8390 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
8391 Code reformatting.
8392 * exp_tss.ads: Add special suffix for TSS primitive Finalize_Address.
8393 Register TSS_Finalize_Address with type TSS_Names.
8394 * exp_util.adb (Build_Allocate_Deallocate_Proc): New routine. This core
8395 procedure provides the interface between an allocation / deallocation
8396 and the support machinery in Ada.Finalization.Heap_Management.
8397 (Find_Init_Call): Code reformatting.
8398 (Find_Init_Call_In_List): Code reformatting.
8399 (Find_Protection_Type): Moved from Exp_Ch9.
8400 (Find_Prim_Op): Reimplement to add preference of recovered primitive.
8401 (Has_Controlled_Coextensions): Removed.
8402 (Has_Controlled_Objects): New routine.
8403 (In_Library_Level_Package_Body): New routine.
8404 (Insert_Action_After): New routine.
8405 (Is_Finalizable_Transient): New routine. This predicate determines
8406 whether an object declaration is one of the many variants of controlled
8407 transients.
8408 (Is_Null_Access_BIP_Func_Call): New routine.
8409 (Is_Non_BIP_Func_Call): New routine.
8410 (Is_Related_To_Func_Return): New routine.
8411 (Needs_Finalization): Moved from Exp_Ch7.
8412 * exp_util.ads (Build_Allocate_Deallocate_Proc): New routine.
8413 (Find_Protection_Type): Moved from Exp_Ch9.
8414 (Has_Controlled_Coextensions): Removed.
8415 (Has_Controlled_Objects): New routine.
8416 (In_Library_Level_Package_Body): New routine.
8417 (Insert_Action_After): New routine.
8418 (Is_Finalizable_Transient): New routine.
8419 (Is_Null_Access_BIP_Func_Call): New routine.
8420 (Is_Non_BIP_Func_Call): New routine.
8421 (Is_Related_To_Func_Return): New routine.
8422 (Needs_Finalization): Moved from Exp_ch7.
8423 * expander.adb (Expand): Add a case for N_Free_Statement.
8424 * freeze.adb (Freeze_All): Replace the generation of a finalization
8425 list with a collection for access-to-controlled types.
8426 (Freeze_Entity): Code reformatting.
8427 (Freeze_Record_Type): Remove the freezing of a record controller
8428 component.
8429 (Freeze_Subprogram): Code reformatting.
8430 * inline.adb (Cleanup_Scopes): Remove the reset of the scope
8431 finalization list.
8432 * lib-writ.adb (Write_Unit_Information): Output "PF" when a package
8433 has a library-level finalizer.
8434 * lib-writ.ads: Add "PF" to the sequence of unit attributes.
8435 * a-filico.ads, a-filico.adb, s-finimp.ads, s-finimp.adb: Removed.
8436 * Makefile.rtl: Remove a-filico and s-finimp from the list of object
8437 files. Add a-fihema to the list of object files.
8438 * par-ch4.adb:
8439 Alphabetize the associations in type Is_Parameterless_Attribute.
8440 * rtsfind.ads: Ada.Finalization_List.Controller and
8441 System.Finalization_Implementation are no longer a GNAT unit.
8442 Update the range of type Ada_Finalization_Child. Remove the following
8443 recoverable entities:
2c7f9cc0 8444
df3e68b1
HK
8445 RE_Attach_To_Final_List
8446 RE_Deep_Tag_Attach
8447 RE_Finalize_List
8448 RE_Finalize_One
8449 RE_Finalizable_Ptr_Ptr
8450 RE_Global_Final_List
8451 RE_Limited_Record_Controller
8452 RE_List_Controller
8453 RE_Move_Final_List
8454 RE_Record_Controller
8455 RE_Simple_List_Controller
2c7f9cc0 8456
df3e68b1 8457 Add the following recoverable entities:
2c7f9cc0 8458
df3e68b1
HK
8459 RE_Add_Offset_To_Address
8460 RE_Allocate
8461 RE_Base_Pool
8462 RE_Deallocate
8463 RE_Exception_Identity
8464 RE_Finalization_Collection
8465 RE_Finalization_Collection_Ptr
8466 RE_Needs_Finalization
8467 RE_Save_Library_Occurrence
8468 RE_Set_Finalize_Address_Ptr
8469 RE_Set_Storage_Pool_Ptr
8470 RE_Storage_Count
8471 * sem_aggr.adb (Resolve_Record_Aggregate): Remove mention of
8472 Name_uController.
8473 * sem_aux.adb (First_Discriminant): Remove mention of Name_uController.
8474 (First_Stored_Discriminant): Remove the mention of Name_uController.
8475 * sem_aux.ads: Comment reformatting.
8476 * sem_ch10.adb (Build_Chain): Signal the class-wide creation machinery
8477 to redecorate an already existing class-wide type.
8478 (Decorate_Tagged_Type): New parameter profile and associated comment.
8479 Create a "shadow class-wide type" for a shadow entity.
8480 * sem_ch11.adb (Analyze_Exception_Handlers): Remove the dubious setting
8481 of the final chain along with the associated comment.
8482 * sem_ch3.adb (Access_Type_Declaration): Add new local variable
8483 Full_Desig and set it to the full view of the designated type.
8484 Initialize the finalization collection to empty.
8485 (Build_Derived_Record_Type): Alphabetize local variables. Code
8486 reformatting.
8487 (Collect_Fixed_Components): Remove the mention of Name_uController.
8488 (Create_Constrained_Components): Remove the mention of Name_uController.
8489 (Make_Class_Wide_Type): Add specialized code to redecorate an existing
8490 class-wide type of a shadow entity.
8491 (Process_Full_View): Update the machinery which marks type
8492 Limited_Controlled's entity as limited.
8493 * sem_ch4.adb (Analyze_One_Call): Code reformatting.
8494 * sem_ch6.adb (Create_Extra_Formals): Do not generate a finalization
8495 list, instead make a collection build-in-place formal.
8496 * sem_ch8.adb (Analyze_Object_Renaming): Look at the available view of
8497 a designated type in order to establish a match between the renaming
8498 and the renamed entity.
8499 (Find_Selected_Component): Add guard to prevent spurious exceptions
8500 from being raised on .NET/JVM.
8501 * sem_disp.adb (Check_Dispatching_Operation): Include Finalize_Address
8502 to the list of primitive that need special processing. Update arrays
8503 C_Names and D_Names.
8504 (Replace_Types): Handle class-wide types.
8505 * sem_elab.adb (Check_A_Call): Since Deep_Initialize now has a
8506 different parameter profile, look at the first formal.
8507 * sem_prag.adb: Remove with and use clauses for Exp_Ch7. Add with and
8508 use clauses for Exp_Util.
8509 * sem_res.adb: Remove with and use clauses for Elists.
8510 (Propagate_Coextensions): Removed.
8511 (Resolve_Allocator): Do not propagate the list of coextensions from one
8512 allocator to another.
8513 * sem_util.adb (Build_Actual_Subtype_Of_Component): Rename variable
8514 Deaccessed_T to Desig_Typ.
8515 (Enter_Name): Remove the mention of Name_uController.
8516 (Gather_Components): Remove the mention of Name_uController.
8517 (Incomplete_Or_Private_View): New routine.
8518 (Is_Coextension_Root): Removed.
8519 (Is_Fully_Initialized_Type): Remove the mention of Name_uController.
8520 * sem_util.ads (Incomplete_Or_Private_View): New routine.
8521 (Is_Coextension_Root): Removed.
8522 * s-finroo.ads: Remove with clause for Ada.Unchecked_Conversion.
8523 Controlled types are now derived from a null tagged record. Remove
8524 types Finalizable_Ptr, Finalizable and Empty_Root_Controlled.
8525 * sinfo.adb (Coextensions): Removed.
8526 (Set_Coextensions): Removed.
8527 * sinfo.ads: Remove Coextensions from the explanation of node fields
8528 and its uses in nodes.
8529 Update the field usage of N_Allocator.
8530 (Coextensions): Removed along with its pragma Inline.
8531 (Set_Coextensions): Removed along with its pragma Inline.
8532 * snames.ads-tmpl: Remove names
2c7f9cc0 8533
df3e68b1
HK
8534 Name_uClean
8535 Name_uController
8536 Name_uFinal_List
8537 Name_uLocal_Final_List
8538 Name_Finalization_Root
8539 Name_Next
8540 Name_Prev
2c7f9cc0 8541
df3e68b1 8542 Add names
2c7f9cc0 8543
df3e68b1
HK
8544 Name_uFinalizer
8545 Name_Finalize_Address
8546 * s-pooglo.adb (Allocate): Add overriding indicator.
8547 (Deallocate): Add overriding indicator.
8548 (Storage_Size): Add overriding indicator.
8549 * s-soflin.adb (Adafinal_NT): Invoke Finalize_Library_Objects rather
8550 than Finalize_Global_List.
8551 (Null_Finalize_Global_List): Removed.
8552 (Save_Library_Occurrence): New routine.
8553 * s-soflin.ads: Remove variable Finalize_Global_List along with its
8554 initialization. Add variable Finalize_Library_Objects along with its
8555 pragma Export. Add variables Library_Exception and
8556 Library_Exception_Set along with their pragma Export.
8557 (Null_Finalize_Global_List): Removed.
8558 (Save_Library_Occurrence): New routine.
8559 * s-tassta.adb (Finalize_Global_Tasks): Call Finalize_Library_Objects
8560 rather than Finalize_Global_List.
8561 * tbuild.adb (Unchecked_Convert_To): Capture and set the parent field
8562 of the constructed node.
8563
2ee06322
RO
85642011-08-03 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8565
8566 * link.c: Include "auto-host.h" before system headers.
8567
f77b022b
VC
85682011-08-03 Vincent Celier <celier@adacore.com>
8569
8570 * make.adb (Gnatmake): Add to table Library_Projs only library projects
8571 that are not extended. Do not check if a library project that is
8572 extended should be regenerated. Do not add to table Library_Paths the
8573 libraries that are in extended projects. Link only with libraries that
8574 are in libray projects that are not extended.
8575 * prj-nmsc.adb (Check_Library_Attributes): Do not reset flag Library
8576 for a library project that is extended.
8577
0187b60e
AC
85782011-08-03 Gary Dismukes <dismukes@adacore.com>
8579
8580 * sem_ch6.adb (Find_Corresponding_Spec): When in an instance, skip
8581 conforming subprogram renamings that appear to be completions if they
8582 are not fully conformant.
8583 Such renamings are homographs but not completions.
8584 * sem_type.adb (Disambiguate): Handle disambiguation of overloaded
8585 names in a subprogram renaming that appears in an instance.
8586
85872011-08-03 Ed Schonberg <schonberg@adacore.com>
8588
8589 * exp_util.adb (Expand_Subtype_From_Expr): if the type is limited but
8590 not immutably limited, build actual subtype from expression to provide
8591 proper bounds to caller.
8592
85932011-08-03 Gary Dismukes <dismukes@adacore.com>
8594
8595 * sem_ch8.adb: Minor comment correction.
8596
85972011-08-03 Thomas Quinot <quinot@adacore.com>
8598
8599 * exp_strm.adb (Build_Array_Input_Function): In Ada 2005 mode, when
8600 returning a limited array, use an extended return statement.
8601
86022011-08-03 Vincent Celier <celier@adacore.com>
8603
8604 * make.adb (Initialize): If --subdirs= is used, but no project file is
8605 specified, attempt to create the specify subdir if it does not already
8606 exist and use it as the object directory as if -D had been specified.
8607
86082011-08-03 Arnaud Charlet <charlet@adacore.com>
8609
8610 * s-tpopsp-vms.adb: New file.
8611 * s-taprop-vms.adb: Put back ATCB_Key, since needed by this file on VMS.
8612 * gcc-interfaces/Makefile.in: Use s-taprop-vms.adb on VMS.
8613
e280f981
AC
86142011-08-03 Emmanuel Briot <briot@adacore.com>
8615
8616 * make.adb, makeutl.adb, makeutl.ads, clean.adb (Makeutl.Queue): new
8617 package.
8618
86192011-08-03 Yannick Moy <moy@adacore.com>
8620
8621 * cstand.adb (Create_Standard): select Universal_Integer as an ALFA type
8622 * sem_ch3.adb (Array_Type_Declaration): detect array types in ALFA
8623 * sem_util.adb, sem_util.ads (Has_Static_Array_Bounds): new function to
8624 detect that an array has static bounds.
8625
98c99a5a
AC
86262011-08-03 Thomas Quinot <quinot@adacore.com>
8627
8628 * exp_dist.adb: Minor reformatting.
8629
86302011-08-03 Arnaud Charlet <charlet@adacore.com>
8631
8632 * s-taprop-irix.adb, s-taprop-hpux-dce.adb, s-taprop-vms.adb
8633 (ATCB_Key): Removed, not always used.
8634
86352011-08-03 Emmanuel Briot <briot@adacore.com>
8636
8637 * gnatcmd.adb, make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads,
8638 clean.adb, prj-conf.adb, prj-env.adb, prj-env.ads (Makeutl): remove
8639 most remaining global variables.
8640
686d0984
AC
86412011-08-03 Robert Dewar <dewar@adacore.com>
8642
8643 * gnatcmd.adb, prj-proc.adb, mlib-prj.adb, prj.adb, makeutl.ads,
8644 prj-util.adb, prj-util.ads, prj-conf.adb, prj-env.adb: Minor
8645 reformatting.
8646
86472011-08-03 Javier Miranda <miranda@adacore.com>
8648
8649 * exp_util.adb (Is_VM_By_Copy_Actual): Include N_Slide nodes as actuals
8650 that must be passed by copy in VM targets.
8651
86522011-08-03 Emmanuel Briot <briot@adacore.com>
8653
8654 * prj.ads, prj-nmsc.adb (Files_Htable): removed this htable, which
8655 duplicates a similar htable now in the project tree.
8656
86572011-08-03 Claire Dross <dross@adacore.com>
8658
8659 * a-cfdlli.adb, a-cfhama.adb, a-cfhase.adb, a-cforma.adb, a-cforse.adb,
8660 a-cofove.adb ("=", Length, Is_Empty, Clear, Assign, Copy, Element,
8661 Replace_Element, Query_Element, Update_Element, Move, Insert, Prepend,
8662 Append, Delete, Delete_First, Delete_Last, Reverse_Element, Swap,
8663 Splice, First, First_Element, Last, Last_Element, Next, Previous, Find,
8664 Reverse_Find, Contains, Has_Element, Iterate, Reverse_Iterate, Capacity,
8665 Reserve_Length, Length, Strict_Equal, Left, Right): Data-structure
8666 update.
8667
86682011-08-03 Arnaud Charlet <charlet@adacore.com>
8669
8670 * s-taprop-posix.adb, s-taprop-linux.adb, s-taprop-tru64.adb
8671 (ATCB_Key): Removed, not always used.
8672 * s-tpopsp-posix.adb, s-tpopsp-posix-foreign.adb (ATCB_Key): Moved from
8673 s-taprop-posix.adb.
8674 * s-tpopsp-tls.adb: New file.
8675 * gcc-interface/Makefile.in: Use TLS implementation of s-tpopsp.adb on
8676 x86/x64/ia64/powerpc/sparc Linux.
8677
86782011-08-03 Arnaud Charlet <charlet@adacore.com>
8679
8680 * system-aix.ads, system-aix64.ads: Set ZCX_By_Default to True.
8681 * gcc-interface/Makefile.in: Switch to ZCX by default on AIX ports.
8682
86832011-08-03 Thomas Quinot <quinot@adacore.com>
8684
8685 * rtsfind.ads, exp_dist.adb, exp_dist.ads
8686 (Build_From_Any_Call, Build_To_Any_Call, Build_TypeCode_Call):
8687 Fix type selection for mapping integer types to PolyORB types.
8688
86892011-08-03 Bob Duff <duff@adacore.com>
8690
8691 * sem_ch7.adb: Minor comment clarification.
8692
86932011-08-03 Bob Duff <duff@adacore.com>
8694
8695 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): If we get
8696 an error analyzing a choice, skip further processing. Further
8697 processing could cause a crash or cascade errors.
8698
40ecf2f5
EB
86992011-08-03 Emmanuel Briot <briot@adacore.com>
8700
8701 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, mlib-prj.adb,
8702 prj.adb, prj.ads, makeutl.adb, makeutl.ads, clean.adb, prj-nmsc.adb,
8703 prj-util.adb, prj-util.ads, prj-conf.adb, prj-conf.ads, prj-env.adb,
8704 prj-env.ads (Shared_Project_Tree_Data): new type
8705 An aggregate project and its aggregated trees need to share the common
8706 data structures used for lists of strings, packages,... This makes the
8707 code simpler since otherwise we have to pass the root tree (also used
8708 for the configuration file data) in addition to the current project
8709 tree. This also avoids ambiguities as to which tree should be used.
8710 And finally this saves a bit of memory.
8711 (For_Every_Project_Imported): new parameter Tree.
8712 Since aggregated projects are using a different tree, we need to let
8713 the caller know which tree to use to manipulate the returned project.
8714
9fde638d
RD
87152011-08-03 Robert Dewar <dewar@adacore.com>
8716
8717 * prj-proc.adb, exp_util.ads, exp_ch9.adb, make.adb, prj-ext.adb,
8718 prj-ext.ads, alfa.ads, sem_ch4.adb, makeutl.adb, makeutl.ads,
8719 lib-xref-alfa.adb, sem_cat.adb, exp_dist.adb, get_alfa.adb,
8720 prj-env.adb, prj-env.ads, prj-tree.adb, alfa.ads: Minor reformatting.
8721
95eb8b69
AC
87222011-08-03 Javier Miranda <miranda@adacore.com>
8723
8724 * exp_util.adb, sem_aux.adb, exp_util.ads, sem_aux.ads:
8725 Move routine Is_VM_By_Copy_Actual from sem_aux to exp_util.
8726
87272011-08-03 Bob Duff <duff@adacore.com>
8728
8729 * sem_ch8.adb (Is_Primitive_Operator_In_Use): Always check In_Use on
8730 the Base_Type.
8731
87322011-08-03 Joel Brobecker <brobecker@adacore.com brobecker>
8733
8734 * g-sha256.ads, g-sha512.ads, g-sha1.ads, g-sha224.ads, g-sha384.ads,
8735 g-sehash.ads: Fix typo. Update header.
8736
87372011-08-03 Thomas Quinot <quinot@adacore.com>
8738
8739 * exp_ch6.adb (Expand_Actuals): Remove Ada_2005 guard on build-in-place
8740 expansion.
8741
87422011-08-03 Gary Dismukes <dismukes@adacore.com>
8743
8744 * sem_ch4.adb (Analyze_Overloaded_Selected_Component): Consider
8745 prefixes of private types along with records, since the selector may be
8746 a discriminant.
8747 * sem_res.adb (Resolve_Selected_Component): Consider prefixes of
8748 private types along with records, since the selector may be a
8749 discriminant.
8750
92e77027
AC
87512011-08-03 Emmanuel Briot <briot@adacore.com>
8752
b2f7ebc1 8753 * prj-pp.adb (Pretty_Print): Remove trailing blank line.
92e77027
AC
8754
87552011-08-03 Javier Miranda <miranda@adacore.com>
8756
8757 * sem_aux.adb (Is_VM_By_Copy_Actual): Fix wrong use of
8758 Tagged_Type_Expansion.
8759
87602011-08-03 Yannick Moy <moy@adacore.com>
8761
b2f7ebc1
GP
8762 * sem_res.adb (Resolve_Op_Concat_Arg): Do not issue a SPARK
8763 violation when the argument of concatenation is the name of a
8764 constant.
92e77027 8765
ab29a348
EB
87662011-08-03 Emmanuel Briot <briot@adacore.com>
8767
8768 * prj-proc.adb, prj-ext.adb, prj-ext.ads, prj-env.adb, prj-env.ads,
8769 prj-tree.adb, prj-tree.ads (Initialize_And_Copy, Copy): new subprograms
8770 (Process_Declarative_Items): new parameter Child_Env.
8771
9466892f
AC
87722011-08-03 Yannick Moy <moy@adacore.com>
8773
589ef536
GP
8774 * alfa.ads: Update format of ALFA section in ALI file in order to
8775 add a mapping from bodies to specs when both are present.
8776 (ALFA_Scope_Record): Add components for spec file/scope.
8777 * get_alfa.adb (Get_ALFA): Read the new file/scope for spec when
8778 present.
8779 * lib-xref-alfa.adb (Collect_ALFA): After all scopes have been
8780 collected, fill in the spec information when relevant.
8781 * put_alfa.adb (Put_ALFA): Write the new file/scope for spec when
9466892f
AC
8782 present.
8783
87842011-08-03 Eric Botcazou <ebotcazou@adacore.com>
8785
8786 * inline.adb (Add_Inlined_Subprogram): Do not consider the enclosing
8787 code unit to decide whether to add internally generated subprograms.
2c7f9cc0 8788
9466892f
AC
87892011-08-03 Javier Miranda <miranda@adacore.com>
8790
8791 * sem_aux.ads, sem_aux.adb (Is_VM_By_Copy_Actual): New subprogram.
589ef536
GP
8792 * exp_ch9.adb (Build_Simple_Entry_Call): Handle actuals that must
8793 be handled by copy in VM targets.
9466892f
AC
8794
87952011-08-03 Emmanuel Briot <briot@adacore.com>
8796
589ef536 8797 * make.adb, makeutl.adb, makeutl.ads (Make.Switches_Of): Share
9466892f
AC
8798 code with Makeutl.Get_Switches.
8799 * prj-tree.adb: Update comment.
8800
b5ea9143
AC
88012011-08-03 Thomas Quinot <quinot@adacore.com>
8802
8803 * sem_cat.adb (Validate_RCI_Subprogram_Declaration): Reject a remote
8804 subprogram with a limited formal that does not support external
8805 streaming.
8806
88072011-08-03 Yannick Moy <moy@adacore.com>
8808
8809 * get_alfa.adb (Get_ALFA): add missing Skip_Spaces at start of
8810 continuation line
8811 * lib-xref-alfa.adb (Add_ALFA_File): split removal of scopes that are
8812 not from current unit in two phases, because it is not possible to
8813 change the table while iterating over its content.
8814 * put_alfa.adb (Put_ALFA): reset current file/scope at each new entity
8815
88162011-08-03 Sergey Rybin <rybin@adacore.com>
8817
8818 * vms_data.ads: Add qualifier for gnatmetric --no-static-loop option
8819 * gnat_ugn.texi: Update description of complexity metrics (gnatmetric)
8820
668a19bc
ES
88212011-08-03 Ed Schonberg <schonberg@adacore.com>
8822
8823 * sem_res.adb (Resolve_Op_Concat_Arg): if the argument is an aggregate
8824 and the component type is composite, this is ambiguous for predefined
8825 concatenation, but if the node is not overloaded and the entity is a use
8826 -defined function its profile can be used to resolve that aggregate.
8827
170b2989
AC
88282011-08-03 Robert Dewar <dewar@adacore.com>
8829
8830 * exp_ch4.adb: Minor code cleanup.
8831
88322011-08-03 Thomas Quinot <quinot@adacore.com>
8833
8834 * exp_dist.adb: Do not generate distribution stubs if serious errors
8835 have been diagnosed.
8836
88372011-08-03 Ed Schonberg <schonberg@adacore.com>
8838
8839 * sem_ch4.adb (Try_Primitive_Operation): when checking the validity of
8840 the first formal of a primitive operation, go to the base type to
8841 handle properly an access to a derived type with constrained
8842 discriminants.
8843 * sem_type.adb (Disambiguate): an immediately visible operator hides a
8844 user-defined function that is only use-visible.
170b2989 8845
e917aec2
RD
88462011-08-03 Robert Dewar <dewar@adacore.com>
8847
8848 * sem_aggr.adb, sem_ch3.adb, lib.ads, gnatcmd.adb, prj-proc.adb,
8849 make.adb, lib-writ.adb, prj-part.adb, prj-part.ads, prj-ext.adb,
8850 fname-uf.adb, prj-ext.ads, prj.adb, prj.ads, sem_attr.adb, alfa.adb,
8851 prj-makr.adb, errout.adb, makeutl.adb, makeutl.ads, restrict.ads,
8852 sem_ch6.adb, g-pehage.adb, clean.adb, put_alfa.adb, lib-xref-alfa.adb,
8853 prj-nmsc.adb, prj-nmsc.ads, sem_ch8.adb, prj-pars.ads, exp_aggr.adb,
8854 prj-attr.ads, sem_ch13.adb, get_alfa.adb, prj-env.adb, prj-env.ads,
8855 alfa_test.adb, prj-tree.adb, prj-tree.ads, einfo.ads: Minor reformatting
8856
88572011-08-03 Robert Dewar <dewar@adacore.com>
8858
8859 * repinfo.adb (List_Mechanism): Add handling of
8860 Convention_Ada_Pass_By_XXX.
8861 * sem_mech.adb (Set_Mechanism): Ditto.
8862 * sem_prag.adb (Process_Convention): Add entries for
8863 Convention_Ada_Pass_By_XXX.
8864 * snames.adb-tmpl, snames.ads-tmpl: Ditto.
8865
49bfcf43
AC
88662011-08-03 Pascal Obry <obry@adacore.com>
8867
8868 * makeutl.adb: Minor reformatting.
8869
88702011-08-03 Vincent Celier <celier@adacore.com>
8871
8872 * fname-uf.adb
8873 (Get_File_Name) If the file cannot be found when there are no config
8874 pragmas file and May_Fail is True, return No_File instead of the file
8875 name, to be consistent.
8876
88772011-08-03 Pascal Obry <obry@adacore.com>
8878
8879 * adaint.c (__gnat_is_executable_file_attr): Avoid access
8880 to null pointer.
8881
88822011-08-03 Javier Miranda <miranda@adacore.com>
8883
8884 * sem_ch13.adb
8885 (Same_Representation): In VM targets the representation of arrays with
8886 aliased components differs from arrays with non-aliased components.
8887
34798441
EB
88882011-08-03 Emmanuel Briot <briot@adacore.com>
8889
8890 * prj-proc.adb, prj-attr.adb, prj-attr.ads (Get_Attribute_Index): do
8891 not systematically lower case attribute indexes that contain no "."
8892 Fix definition of several Naming attributes, which take
8893 a unit name as index and therefore should be case insensitive.
8894 Minor refactoring (reduce length of variable names).
8895
88962011-08-03 Emmanuel Briot <briot@adacore.com>
8897
8898 * makeutl.adb, makeutl.ads (Get_Switches): new subprogram.
8899
4437a530
EB
89002011-08-03 Emmanuel Briot <briot@adacore.com>
8901
8902 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, prj-part.adb,
8903 prj-part.ads, switch-m.adb, switch-m.ads, prj-makr.adb, clean.adb,
8904 prj-pars.adb, prj-pars.ads, prj-conf.adb, prj-conf.ads, prj-tree.adb,
8905 prj-tree.ads (Prj.Tree.Environment): new type.
8906
804fe3c4
EB
89072011-08-03 Emmanuel Briot <briot@adacore.com>
8908
8909 * prj-proc.adb, prj.ads, makeutl.adb, makeutl.ads, prj-conf.adb,
8910 prj-tree.adb, prj-tree.ads (Environment): new type.
8911
c565bc66
AC
89122011-08-03 Emmanuel Briot <briot@adacore.com>
8913
8914 * prj-tree.ads: Remove unused variable.
8915
89162011-08-03 Yannick Moy <moy@adacore.com>
8917
8918 * restrict.adb (Restriction_Msg): set "SPARK" all in upper case for
8919 issuing messages related to SPARK restriction violation.
8920
4ee646da
AC
89212011-08-03 Ed Schonberg <schonberg@adacore.com>
8922
8923 * sem_ch6.adb: guard against error nodes in return statements.
8924
89252011-08-03 Arnaud Charlet <charlet@adacore.com>
8926
8927 * errout.adb (Error_Msg_Internal): the main unit has not been read yet,
8928 a warning can only appear on a configuration file, so emit warning
8929 without further checks.
8930
89312011-08-03 Arnaud Charlet <charlet@adacore.com>
8932
8933 * s-interr.ads: add overriding keyword.
8934
89352011-08-03 Geert Bosch <bosch@adacore.com>
8936
8937 * exp_attr.adb: Fix minor typo.
8938
89392011-08-03 Ed Schonberg <schonberg@adacore.com>
8940
8941 * par-ch4.adb: improve error recovery.
8942
c0e538ad
AC
89432011-08-03 Emmanuel Briot <briot@adacore.com>
8944
8945 * prj-part.adb, prj-part.ads, prj-makr.adb, prj-pars.adb, prj-conf.adb,
8946 prj-env.adb (Prj.Part.Parse): change parameter Always_Errout_Finalize
8947 to Errout_Handling.
8948
89492011-08-03 Emmanuel Briot <briot@adacore.com>
8950
8951 * prj-dect.adb (Parse_Attribute_Declaration): make sure we can use
8952 "external" as an attribute name in aggregate projects.
8953
89542011-08-03 Jose Ruiz <ruiz@adacore.com>
8955
8956 * s-taprop-vxworks.adb: (Create_Task, Initialize): Ada 2012 pragma CPU
8957 uses CPU numbers starting 1, while VxWorks uses CPU numbers starting
8958 from 0, so we need to adjust.
8959
89602011-08-03 Emmanuel Briot <briot@adacore.com>
8961
8962 * prj-proc.adb, prj-ext.adb, prj-ext.ads, makeutl.adb, prj-tree.adb,
8963 prj-tree.ads, gnatcmd.adb, clean.adb (External_References): new type.
8964
c4d67e2d
AC
89652011-08-03 Yannick Moy <moy@adacore.com>
8966
8967 * sem_ch6.adb (New_Overloaded_Entity): only issue error for SPARK
8968 restriction on overloaded entity if the entity is not an operator.
8969
89702011-08-03 Yannick Moy <moy@adacore.com>
8971
8972 * sem_ch7.adb, sem_res.adb, sem_attr.adb, restrict.adb,
8973 restrict.ads: Rename remaining Check_Formal_Restriction* into
8974 Check_SPARK_Restriction*.
8975
89762011-08-03 Emmanuel Briot <briot@adacore.com>
8977
8978 * prj-proc.adb, prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb,
8979 prj-nmsc.ads, prj-err.adb (Project_Data): now discriminated on its
8980 qualifier.
8981 (Project_Empty): removed
8982 (Empty_Project): new parameter Qualifier
8983 This is used to have fields specific to aggregate projects, cleaner
8984 New field to store the list of aggregated projects.
8985 (Check_Aggregate_Project): removed
8986 (Process_Aggregated_Projects, Free): new subprograms.
8987
3f5a8fee
AC
89882011-08-03 Olivier Hainque <hainque@adacore.com>
8989
8990 * tracebak.c (STOP_FRAME ppc AIX): Stop at null return address as well.
8991
89922011-08-03 Ed Schonberg <schonberg@adacore.com>
8993
8994 * sem_ch8.adb (Analyze_Object_Renaming): if the renamed object is an
8995 explicit dereference of an unconstrained type, create a constrained
8996 subtype for it, as is done for function calls that return an
8997 unconstrained type.
8998
89992011-08-03 Thomas Quinot <quinot@adacore.com>
9000
9001 * g-pehage.adb (Finalize): Avoid possible double-free.
9002
90032011-08-03 Steve Baird <baird@adacore.com>
9004
9005 * exp_attr.adb (Expand_N_Attribute_Reference): Don't expand
9006 Elab_Spec/Body attrs in CodePeer_Mode.
9007
90082011-08-03 Javier Miranda <miranda@adacore.com>
9009
9010 * exp_aggr.adb (Flatten): Convert to positional form aggregates whose
9011 low bound is not known at compile time but they have no others choice.
9012 Done because in this case the bounds can be obtained directly from the
9013 aggregate.
9014
90152011-08-03 Ed Falis <falis@adacore.com>
9016
9017 * s-tasinf-vxworks.ads: Update comment to reflect 0 indexing of CPUs
9018 on VxWorks SMP. Remove unusable constant ANY_CPU.
9019
a96ca600
EB
90202011-08-03 Emmanuel Briot <briot@adacore.com>
9021
9022 * gnatcmd.adb, make.adb, prj-part.adb, prj-part.ads, prj-makr.adb,
9023 clean.adb, prj-nmsc.adb, prj-pars.adb, prj-conf.adb, prj-env.adb,
9024 prj-env.ads (Prj.Env.Initialize_Default_Project_Path,
9025 Prj.Env.Initialize_Empty): new subprograms
9026 (Get_Env, Find_Project): remove parameter Target_Name.
9027
3e582869
AC
90282011-08-03 Gary Dismukes <dismukes@adacore.com>
9029
9030 * sem_ch3.adb (Build_Derived_Record_Type): Test the Derive_Subps formal
9031 as a condition for the delayed call to Derived_Subprograms done for the
9032 case of the rewriting of a derived type that constrains the
9033 discriminants of its parent type.
9034 Avoids redundant subprogram derivations for private subtype derivations.
9035
90362011-08-03 Javier Miranda <miranda@adacore.com>
9037
9038 * exp_aggr.adb (Init_Hidden_Discriminants): New subprogram of
9039 Build_Record_Aggr_Code.
9040 (Build_Record_Aggr_Code): Add missing support to initialize hidden
9041 discriminants in extension aggregates.
9042
90432011-08-03 Emmanuel Briot <briot@adacore.com>
9044
9045 * prj-pp.adb (Print): also output project qualifiers, since in
9046 particular "aggregate" is mandatory in an aggregate project.
9047
90482011-08-03 Emmanuel Briot <briot@adacore.com>
9049
9050 * prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb, prj-env.adb:
9051 (Debug_Output): new function.
9052
56e94186
AC
90532011-08-03 Eric Botcazou <ebotcazou@adacore.com>
9054
9055 * gnat_ugn.texi: Document -Wstack-usage.
9056 * gcc-interface/misc.c (enumerate_modes): Add guard for ghost FP modes.
9057
90582011-08-03 Thomas Quinot <quinot@adacore.com>
9059
9060 * sem_prag.adb Issue an error (not a warning) when a C++ type does not
9061 have keyword LIMITED.
9062
90632011-08-03 Yannick Moy <moy@adacore.com>
9064
9065 * alfa.adb, alfa.ads, alfa_test.adb: New files.
9066 * ali.adb (Known_ALI_Lines): add 'C' lines (SCO) and 'F' lines (ALFA)
9067 (Scan_ALI): do not issue a fatal error if parsing known lines after Xref
9068 section (does not happen in compiler, only if code directly calls
9069 Scan_ALI).
9070 * get_alfa.adb, get_alfa.ads: New files.
9071 * lib-writ.adb, lib-writ.ads (Write_ALI): output ALFA information if
9072 needed.
9073 * lib-xref-alfa.adb: New file.
9074 * lib-xref.adb, lib-xref.ads
9075 (Xref_Entry): redefine information needed in cross-references for ALFA.
9076 Push ALFA treatments in separated local package.
9077 (Enclosing_Subpragram_Or_Package): treat specially subprogram
9078 identifiers. Return entity of package body instead of spec. Return
9079 Empty for a scope with no location.
9080 (Generate_Reference): adapt to new components for ALFA information.
9081 Remove the need for D references on definitions.
9082 (Is_Local_Reference): moved to ALFA local package
9083 (Output_References): extract subfunction as Extract_Source_Name
9084 (Output_Local_References): remove procedure, replaced by filtering of
9085 cross-references in package ALFA and printing in Put_ALFA.
9086 (Write_Entity_Name): remove procedure
9087 * lib.adb, lib.ads (Extract_Source_Name): extract here function to
9088 print exact name of entity as it appears in source file
9089 (Unit_Ref_Table): make type public for use in Lib.Xref.ALFA
9090 * put_alfa.adb, put_alfa.ads: New files.
9091 * xref_lib.adb (Search_Xref): protect read of cross-references against
9092 reading other sections of the ALI file, in gnatxref
9093 (Search): protect read of cross-references against reading other
9094 sections of the ALI file, in gnatfind.
9095 * gcc-interface/Make-lang.in: Update dependencies.
9096
90972011-08-03 Thomas Quinot <quinot@adacore.com>
9098
9099 * sem_ch3.adb: Minor reformatting.
9100
91012011-08-03 Jose Ruiz <ruiz@adacore.com>
9102
9103 * s-inmaop-vxworks.adb (Setup_Interrupt_Mask): Do nothing instead of
9104 raising an exception.
9105
91062011-08-03 Ed Schonberg <schonberg@adacore.com>
9107
9108 * sem_res.adb (Set_String_Literal_Subtype): if index type is an integer
9109 type, always use 1 as the lower bound or string, even if lower bound of
9110 context is not static, to handle properly null strings in a non-static
9111 context.
9112
91132011-08-03 Bob Duff <duff@adacore.com>
9114
9115 * sem_prag.adb (Resolve_Aggregate): An array aggregate with 'others' is
9116 always legal on the right-hand side of an assignment statement; there
9117 is always an applicable index constraint in this case. Therefore, the
9118 check for Pkind = N_Assignment_Statement is now unconditional -- it
9119 doesn't depend on whether Is_Constrained (Typ).
9120
4317e442
AC
91212011-08-03 Robert Dewar <dewar@adacore.com>
9122
9123 * exp_ch5.adb, sem_prag.adb, exp_ch4.adb: Minor reformatting.
9124
91252011-08-03 Ed Schonberg <schonberg@adacore.com>
9126
9127 * sem_ch3.adb (Build_Itype_Reference): do not create an itype reference
9128 for an itype created within a generic unit.
9129
91302011-08-03 Eric Botcazou <ebotcazou@adacore.com>
9131
9132 * gnat_ugn.texi (Switches for gcc): Make it clearer that -fno-inline
9133 suppresses all inlining.
9134
53f29d4f
AC
91352011-08-03 Robert Dewar <dewar@adacore.com>
9136
9137 * sem_ch3.adb, sem_res.adb, exp_ch13.adb, exp_disp.adb,
9138 exp_aggr.adb: Minor reformatting.
9139
91402011-08-03 Thomas Quinot <quinot@adacore.com>
9141
9142 * exp_ch5.adb (Expand_N_Assignment_Statement): Do not force inlining of
9143 tagged assignment when discriminant checks are suppressed. This is
9144 useless and extremely costly in terms of static stack usage.
9145
91462011-08-03 Bob Duff <duff@adacore.com>
9147
9148 * sem_prag.adb (Get_Base_Subprogram): Do not follow Alias for instances
9149 of generics, because this leads to the wrong entity in the wrong scope,
9150 causing (e.g.) pragma Export_Procedure to get an error if the entity is
9151 an instance.
9152 (Process_Interface_Name): Follow Alias for instances of generics, to
9153 correct for the above change.
9154
91552011-08-03 Ed Schonberg <schonberg@adacore.com>
9156
9157 * exp_ch4.adb (Expand_N_Selected_Component): If the discriminant value
9158 is an integer literal it is always safe to replace the reference. In
9159 addition, if the reference appears in the generated code for an object
9160 declaration it is necessary to copy because otherwise the reference
9161 might be to the uninitilized value of the discriminant of the object
9162 itself.
9163
91642011-08-03 Pascal Obry <obry@adacore.com>
9165
9166 * adaint.c (__gnat_is_executable_file_attr): Fix Win32 circuitry when no
9167 ACL used, in this case we want to check for ending .exe, not .exe
9168 anywhere in the path.
9169
91702011-08-03 Sergey Rybin <rybin@adacore.com>
9171
9172 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
9173 the tree structure (semantic decoration of references to record
9174 discriminants).
9175
c0b11850
AC
91762011-08-03 Gary Dismukes <dismukes@adacore.com>
9177
9178 * sem_aggr.adb (Analyze_Array_Aggregate): When checking the discrete
9179 choices of a named array aggregate, bail out when any choices are
9180 marked as Errors_Posted.
9181
91822011-08-03 Ed Schonberg <schonberg@adacore.com>
9183
9184 * exp_ch13.adb (Expand_N_Freeze_Entity): cleanup determination of scope
9185 in which entity is frozen, to handle properly loop variables in
9186 iterators.
9187
91882011-08-03 Ed Schonberg <schonberg@adacore.com>
9189
9190 * sem_res.adb (Set_String_Literal_Subtype): if the lower bound of the
9191 subtype is not static, compute the upper bound using attributes, to
9192 handle properly index types that are not integer types.
9193
91942011-08-03 Bob Duff <duff@adacore.com>
9195
9196 * gnat_rm.texi, gnat_ugn.texi: Fix some dangling URLs.
9197 Update copyright notice.
9198
91992011-08-03 Ed Schonberg <schonberg@adacore.com>
9200
9201 * sem_ch3.adb (Build_Discriminant_Constraints): Only use
9202 Original_Discriminant if within an instance.
9203 * sem_ch4.adb (Analyze_Selected_Component): Ditto.
9204
92052011-08-03 Thomas Quinot <quinot@adacore.com>
9206
9207 * einfo.ads: Minor reformatting.
9208
92092011-08-03 Ed Schonberg <schonberg@adacore.com>
9210
9211 * exp_disp.adb (Check_Premature_Freezing): diagnose the presence of a
9212 composite type with an unfrozen subcomponent, in the profile of a
9213 primitive operation.
9214
5c34e9cd
AC
92152011-08-03 Robert Dewar <dewar@adacore.com>
9216
9217 * sem_util.ads, exp_aggr.adb, exp_ch3.adb: Minor reformatting.
9218
92192011-08-03 Ed Schonberg <schonberg@adacore.com>
9220
9221 * sem_ch3.adb (Analyze_Object_Declaration): if a constant object of an
9222 unconstrained type with discriminants is initialized with an aggregate,
9223 use the constrained subtype of the aggregate as the type of the object,
9224 because it is immutable, and this allows the back-end to generate no
9225 code for the object declaration.
9226
abcd9db2
AC
92272011-08-03 Robert Dewar <dewar@adacore.com>
9228
9229 * exp_ch4.adb (Optimize_Length_Check): Fix bad handling of case where
9230 comparison operand is variable, and turns out to be zero or negative.
9231
92322011-08-03 Javier Miranda <miranda@adacore.com>
9233
9234 * exp_intr.adb
9235 (Expand_Dispatching_Constructor_Call): Disable expansion of
9236 code required for native targets. Done to avoid generating
9237 references to unavailable runtime entities in VM targets.
9238 * exp_ch3.adb
9239 (Expand_N_Object_Declaration): Add missing support to handle
9240 the explicit initialization of class-wide interface objects.
9241 Fix documentation.
9242
92432011-08-03 Matthew Heaney <heaney@adacore.com>
9244
7089ef0f
GP
9245 * a-cobove.adb (Merge): Move source onto target, instead of using
9246 Assign.
abcd9db2
AC
9247
92482011-08-03 Matthew Heaney <heaney@adacore.com>
9249
7089ef0f 9250 * a-cbdlli.adb (Splice): Move source items from first to last.
abcd9db2
AC
9251
92522011-08-03 Yannick Moy <moy@adacore.com>
9253
7089ef0f 9254 * sem_util.ads: Add comment.
abcd9db2
AC
9255
92562011-08-03 Javier Miranda <miranda@adacore.com>
9257
9258 * exp_aggr.adb
9259 (Expand_Record_Aggregate): In VM targets disable the expansion into
9260 assignments of aggregates whose type is not known at compile time.
9261
b474d6c3
ES
92622011-08-03 Ed Schonberg <schonberg@adacore.com>
9263
9264 * exp_ch9.adb (Build_Renamed_Formal_Declaration): common procedure for
9265 protected entries and task entries, to build the proper renaming
9266 declaration for entry formals, used in debugging.
9267 * exp_ch2.adb (Expand_Entry_Parameter): handle task and entry
9268 parameters in the same way.
9269
0580d807
AC
92702011-08-02 Robert Dewar <dewar@adacore.com>
9271
9272 * a-direct.adb, sinfo.ads, exp_ch9.adb, scng.adb, sem_util.adb,
9273 sem_util.ads, restrict.ads, par-prag.adb: Minor reformatting and/or
9274 code reorganization.
9275
92762011-08-02 Robert Dewar <dewar@adacore.com>
9277
9278 * debug.adb: Debug flag d.P to suppress length comparison optimization
9279 * exp_ch4.adb (Optimize_Length_Comparison): New routine to optimize
9280 comparison of Length by comparing First/Last instead.
9281
92822011-08-02 Matthew Heaney <heaney@adacore.com>
9283
9284 * a-cobove.ads: Code clean up.
9285
b191a125
AC
92862011-08-02 Vincent Celier <celier@adacore.com>
9287
9288 * adaint.c (file_names_case_sensitive_cache): New static int.
9289 (__gnat_get_file_names_case_sensitive): Cache the return value in
9290 file_names_case_sensitive_cache at the first invocation, to avoid
9291 multiple calls to getenv.
9292
92932011-08-02 Bob Duff <duff@adacore.com>
9294
9295 * sem_ch12.adb (Validate_Derived_Type_Instance): Implement AI05-0218-1.
9296
316a0661
AC
92972011-08-02 Yannick Moy <moy@adacore.com>
9298
9299 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_prag.adb, sem.ads,
9300 sem_util.adb, sem_util.ads, sem_res.adb, sem_ch2.adb, sem_ch4.adb,
9301 sem_ch6.adb, sem_ch11.adb: Add semantic flag In_Pre_Post_Expression to
9302 indicate that we are in a precondition or postcondition. This is used in
9303 Mark_Non_ALFA_Subprogram (renaming of Mark_Non_ALFA_Subprogram_Body) to
9304 decide whether to flag the spec or body of the current subprogram as
9305 not in ALFA.
9306
93072011-08-02 Fabien Chouteau <chouteau@adacore.com>
9308
9309 * impunit.adb: Add Ada.Execution_Time.Interrupts in the Ada2012 package
9310 list.
9311 * a-extiin.ads: New file.
9312
93132011-08-02 Bob Duff <duff@adacore.com>
9314
9315 * a-direct.adb (Rename): Implement AI05-0231-1. In particular, Rename
9316 now raises Name_Error instead of Use_Error in certain cases. The other
9317 parts of this AI were already implemented properly.
9318
f9adb9d4
AC
93192011-08-02 Vincent Celier <celier@adacore.com>
9320
9321 * link.c: Only import "auto-host.h" when building the gnattools.
9322
93232011-08-02 Yannick Moy <moy@adacore.com>
9324
9325 * sem_util.adb: Inter-unit inlining does not work for a subprogram
9326 which calls a local subprogram, so extract subprogram
9327 from Mark_Non_ALFA_Subprogram_Body.
9328
93292011-08-02 Javier Miranda <miranda@adacore.com>
9330
9331 * exp_ch9.adb
9332 (Extract_Dispatching_Call): If the type of the dispatching object is an
9333 access type then return an explicit dereference in the Object out-mode
9334 parameter.
9335
93362011-08-02 Gary Dismukes <dismukes@adacore.com>
9337
9338 * sem_ch3.adb (Analyze_Subtype_Declaration): Generate range
9339 compatibility checks for all indexes of an array subtype, not just the
9340 first. Reset Has_Dynamic_Range_Check on the subtype before each
9341 potential check to ensure that Insert_Range_Checks will not elide any
9342 of the dynamic checks.
9343
93442011-08-02 Yannick Moy <moy@adacore.com>
9345
9346 * par-prag.ad (Process_Restrictions_Or_Restriction_Warnings): recognize
9347 SPARK restriction at parsing time.
9348 * scng.adb (Scan): Generate a token Tok_SPARK_Hide for a SPARK HIDE
9349 directive only if the SPARK restriction is set for this unit.
9350
83f33150
YM
93512011-08-02 Yannick Moy <moy@adacore.com>
9352
9353 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb, sem_util.ads,
9354 sem_res.adb, sem_ch2.adb, sem_ch4.adb, sem_ch6.adb,
9355 sem_ch11.adb: Protect call to Current_Subprogram which might be costly
9356 when repeated. Rename Current_Subprogram_Is_Not_In_ALFA into
9357 Mark_Non_ALFA_Subprogram_Body.
9358 Split body of Mark_Non_ALFA_Subprogram_Body to get body small and
9359 inlined.
9360
7b98672f
YM
93612011-08-02 Yannick Moy <moy@adacore.com>
9362
9363 * sem_res.adb: Protect calls to Matching_Static_Array_Bounds which
9364 might be costly.
9365
052e0603
AC
93662011-08-02 Robert Dewar <dewar@adacore.com>
9367
9368 * exp_ch9.adb, exp_sel.adb, restrict.ads, exp_disp.adb, erroutc.ads,
9369 exp_ch3.adb: Minor reformatting.
9370
93712011-08-02 Emmanuel Briot <briot@adacore.com>
9372
9373 * adaint.c (__gnat_locate_exec_on_path): only returns executable
9374 files, not any regular file.
9375 (__gnat_locate_file_with_predicate): new subprogram.
9376
93772011-08-02 Yannick Moy <moy@adacore.com>
9378
9379 * sinfo.adb, sinfo.ads: Restrict the use of flags
9380 Has_Dynamic_Length_Check and Has_Dynamic_Range_Check to expression
9381 nodes, plus N_Subtype_Declaration for the 2nd one.
9382
4fbad0ba
AC
93832011-08-02 Sergey Rybin <rybin@adacore.com>
9384
9385 * gnat_rm.texi: Ramification of pragma Eliminate documentation
9386 - fix bugs in the description of Source_Trace;
9387 - get rid of UNIT_NAME;
9388
052e0603
AC
93892011-08-02 Javier Miranda <miranda@adacore.com>
9390
9391 * exp_ch9.adb
9392 (Build_Dispatching_Requeue): Adding support for VM targets
9393 since we cannot directly reference the Tag entity.
9394 * exp_sel.adb (Build_K): Adding support for VM targets.
9395 (Build_S_Assignment): Adding support for VM targets.
9396 * exp_disp.adb
9397 (Default_Prim_Op_Position): In VM targets do not restrict availability
9398 of predefined interface primitives to compiling in Ada 2005 mode.
9399 (Is_Predefined_Interface_Primitive): In VM targets this service is not
9400 restricted to compiling in Ada 2005 mode.
9401 (Make_VM_TSD): Generate code that declares and initializes the OSD
9402 record. Needed to support dispatching calls through synchronized
9403 interfaces.
9404 * exp_ch3.adb
9405 (Make_Predefined_Primitive_Specs): Enable generation of predefined
9406 primitives associated with synchronized interfaces.
9407 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
9408 primitives associated with synchronized interfaces.
9409
94102011-08-02 Yannick Moy <moy@adacore.com>
9411
9412 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
9413 statements hidden in SPARK if preceded by the HIDE directive
9414 (Parse_Exception_Handlers): mark each exception handler in a sequence of
9415 exception handlers as hidden in SPARK if preceded by the HIDE directive
9416 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
9417 if starting with the HIDE directive
9418 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
9419 starting with the HIDE directive; mark the declarations in a private
9420 part as hidden in SPARK if the private part starts with the HIDE
9421 directive
9422 * restrict.adb, restrict.ads
9423 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
9424 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
9425 argument node belongs to a part which is hidden in SPARK
9426 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
9427 parts in SPARK; protect the possibly costly call to
9428 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
9429 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
9430 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
9431 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
9432 Tok_SPARK_Hide.
9433 (Scan): recognize special comment starting with '#' and followed by
9434 SPARK keyword "hide" as a HIDE directive.
9435
94362011-08-02 Yannick Moy <moy@adacore.com>
9437
9438 * types.ads, erroutc.ads: Minor reformatting.
9439
94402011-08-02 Vincent Celier <celier@adacore.com>
9441
9442 * link.c: Add response file support for cross platforms.
9443
94442011-08-02 Ed Schonberg <schonberg@adacore.com>
9445
9446 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
9447 in an association, set parent field of copy before partial analysis.
9448 * sem_res.adb (Resolve_Slice): create reference to itype only when
9449 expansion is enabled.
9450
94512011-08-02 Yannick Moy <moy@adacore.com>
9452
9453 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
9454 for new flag denoting which subprogram bodies are in ALFA
9455 * restrict.adb, sem_ch7.adb: Update comment
9456 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
9457 sem_ch9.adb, sem_res.adb: Add calls to
9458 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
9459 * sem_ch6.adb (Analyze_Function_Return): add calls to
9460 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
9461 middle of the body, and extended return.
9462 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
9463 False when missing return.
9464 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
9465 to True for subprograms whose spec is in ALFA. Remove later on the flag
9466 on the entity used for a subprogram body when there exists a separate
9467 declaration.
9468 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
9469 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
9470 False, otherwise do nothing.
9471
94722011-08-02 Robert Dewar <dewar@adacore.com>
9473
9474 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
9475
94762011-08-02 Yannick Moy <moy@adacore.com>
9477
9478 * sem_ch4.ads: minor formatting.
9479
94802011-08-02 Yannick Moy <moy@adacore.com>
9481
9482 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
9483 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
9484 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
9485 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
9486 opt.ads: cleanup of SPARK mode
9487
94882011-08-02 Yannick Moy <moy@adacore.com>
9489
9490 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
9491 types.
9492 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
9493 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
9494 * sem_ch3.adb
9495 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
9496 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
9497 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
9498 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
9499 types.
9500 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
9501 non-static range.
9502 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
9503 functions whose return type is not in ALFA.
9504 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
9505 specifications.
9506 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
9507 parameter's type is not in ALFA.
9508 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
9509 types are in ALFA.
9510
95112011-08-02 Ed Schonberg <schonberg@adacore.com>
9512
9513 * sem_ch6 (Analyze_Expression_Function): treat the function as
9514 Inline_Always, and introduce a subprogram declaration for it when it is
9515 not a completion.
9516 * inline.adb (Add_Inlined_Body): recognize bodies that come from
9517 expression functions, so that the back-end can determine whether they
9518 can in fact be inlined.
9519 * sem_util.adb (Is_Expression_Function): predicate to determine whether
9520 a function body comes from an expression function.
9521
95222011-08-02 Gary Dismukes <dismukes@adacore.com>
9523
9524 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
9525 null exclusions to test Can_Never_Be_Null on the anonymous access types
9526 of the formals rather than testing the formals themselves. Exclude this
9527 check in cases where the Old_Formal is marked as a controlling formal,
9528 to avoid issuing spurious errors for bodies completing dispatching
9529 operations (due to the flag not getting set on controlling access
9530 formals in body specs).
9531 (Find_Corresponding_Spec): When checking full and subtype conformance of
9532 subprogram bodies in instances, pass Designated and E in that order, for
9533 consistency with the expected order of the formals (New_Id followed by
9534 Old_Id).
9535
95362011-08-02 Robert Dewar <dewar@adacore.com>
9537
9538 * sem_ch8.adb: Minor reformatting.
9539
95402011-08-02 Ed Schonberg <schonberg@adacore.com>
9541
9542 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
9543 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
9544 primitive operations of class-wide actuals.
9545
95462011-08-02 Javier Miranda <miranda@adacore.com>
9547
9548 * exp_atag.ads, exp_atag.adb
9549 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
9550 since its value is implicitly passed in argument Typ.
9551 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
9552 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
9553 Build_Common_Dispatching_Select_Statements.
9554
95552011-08-02 Robert Dewar <dewar@adacore.com>
9556
9557 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
9558 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
9559 Minor reformatting.
9560
95612011-08-02 Robert Dewar <dewar@adacore.com>
9562
9563 * sem_res.adb: Minor reformatting.
9564 * sem_prag.adb: Minor reformatting.
9565
95662011-08-02 Javier Miranda <miranda@adacore.com>
9567
9568 * exp_atag.adb, exp_atags.ads
9569 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
9570 by the tagged type Entity. Required to use this routine in the VM
9571 targets since we do not have available the Tag entity in the VM
9572 platforms.
9573 * exp_ch6.adb
9574 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
9575 Ada.Tags has not been previously loaded.
9576 * exp_ch7.adb
9577 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
9578 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
9579 * sem_aux.adb
9580 (Enclosing_Dynamic_Scope): Add missing support to handle the full
9581 view of enclosing scopes. Required to handle enclosing scopes that
9582 are synchronized types whose full view is a task type.
9583 * exp_disp.adb
9584 (Build_VM_TSDs): Minor code improvement to avoid generating and
9585 analyzing lists with empty nodes.
9586 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
9587 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
9588 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
9589 (Make_Disp_Timed_Select_Body): Add support for VM targets.
9590 (Make_Select_Specific_Data_Table): Add support for VM targets.
9591 (Make_VM_TSD): Generate code to initialize the SSD structure of
9592 the TSD.
9593
95942011-08-02 Yannick Moy <moy@adacore.com>
9595
9596 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
9597 cross-references section in ALI.
9598 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
9599 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
9600 Sub).
9601 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
9602 subprogram or package entity of a node
9603 (Is_Local_Reference_Type): new function returns True for references
9604 selected in local cross-references.
9605 (Lt): function extracted from Lt in Output_References
9606 (Write_Entity_Name): function extracted from Output_References
9607 (Generate_Definition): generate reference with type 'D' for definition
9608 of objects (object declaration and parameter specification), with
9609 appropriate locations and units, for use in local cross-references.
9610 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
9611 references of type 'I' for initialization in object definition.
9612 (Output_References): move part of function Lt and procedure
9613 Write_Entity_Name outside of the body. Ignore references of types 'D'
9614 and 'I' introduced for local cross-references.
9615 (Output_Local_References): new procedure to output the local
9616 cross-references sections.
9617 (Lref_Entity_Status): new array defining whether an entity is a local
9618 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
9619 with 'I' type when initialization expression is present.
9620 * get_scos.adb, get_scos.ads: Correct comments and typos
9621
96222011-08-02 Javier Miranda <miranda@adacore.com>
9623
9624 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
9625 the JVM target.
9626 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
9627 the JVM target.
9628 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
9629 TSD support.
9630
96312011-08-02 Vincent Celier <celier@adacore.com>
9632
9633 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
9634 (No_Space_Img): New function
9635 (Find_Excluded_Sources): When reading from a file, record the file name
9636 and the line number for each excluded source.
9637 (Mark_Excluded_Sources): When reporting an error, if the excluded
9638 sources were read from a file, include file name and line number in
9639 the error message.
9640
96412011-08-02 Ed Schonberg <schonberg@adacore.com>
9642
9643 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
9644
96452011-08-02 Robert Dewar <dewar@adacore.com>
9646
9647 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
9648
96492011-08-02 Javier Miranda <miranda@adacore.com>
9650
9651 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
9652 generation of TSDs to the DOTNET compiler.
9653 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
9654 generation of TSDs to the DOTNET compiler.
9655
96562011-08-02 Javier Miranda <miranda@adacore.com>
9657
9658 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
9659 record of all the tagged types declared inside library level package
9660 declarations, library level package bodies or library level subprograms.
9661 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
9662 associated with a given tagged type.
9663 (Build_VM_TSDs): New subprogram.
9664 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
9665 compilation units that are subprograms.
9666 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
9667 compilation units that are package bodies.
9668 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
9669 units that are a package declaration or a package instantiation.
9670 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
9671 reorganization to improve the error generated by the frontend when the
9672 function Ada.Tags.Secondary_Tag is not available.
9673 * rtsfind.ads (RE_Register_TSD): New runtime entity.
9674 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
9675
96762011-08-02 Javier Miranda <miranda@adacore.com>
9677
9678 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
9679
96802011-08-02 Robert Dewar <dewar@adacore.com>
9681
9682 * s-imenne.ads: Minor reformatting.
9683
96842011-08-02 Robert Dewar <dewar@adacore.com>
9685
9686 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
9687 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
9688 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
9689
96902011-08-02 Robert Dewar <dewar@adacore.com>
9691
9692 * einfo.ads (Materialize_Entity): Document this is only for renamings
9693 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
9694 required debug information in the case where we transform the object
9695 declaration into a renaming declaration.
9696 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
9697 object
9698 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
9699 Materialize_Entity.
9700
97012011-08-02 Robert Dewar <dewar@adacore.com>
9702
9703 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
9704 Suppress_Init_Procs.
9705 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
9706 Suppress_Initialization/Initialization_Suppressed.
9707 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
9708 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
9709 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
9710 * sem_prag.adb: New processing for pragma Suppress_Initialization.
9711
97122011-08-02 Robert Dewar <dewar@adacore.com>
9713
9714 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
9715 Minor reformatting.
9716
97172011-08-02 Ed Schonberg <schonberg@adacore.com>
9718
9719 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
9720 only have inheritable classwide pre/postconditions.
9721
97222011-08-02 Javier Miranda <miranda@adacore.com>
9723
9724 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
9725 * rtsfind.ads (RE_Check_TSD): New runtime entity.
9726 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
9727 checks if the external tag of a type is the same as the external tag
9728 of some other declaration.
9729
97302011-08-02 Thomas Quinot <quinot@adacore.com>
9731
9732 * s-taskin.ads: Minor reformatting.
9733
97342011-08-02 Emmanuel Briot <briot@adacore.com>
9735
9736 * g-comlin.adb (Display_Help): swap the order in which it prints the
9737 short help and the general usage.
9738
97392011-08-02 Ed Schonberg <schonberg@adacore.com>
9740
9741 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
9742 the aspect declarations and attach them to the generic copy for
9743 subsequent analysis.
9744 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
9745 declarations of the generic tree to the new subprogram declarations.
9746 * sem_attr.adb (Check_Precondition_Postcondition): recognize
9747 conditions that apply to a subprogram instance.
9748
97492011-08-02 Robert Dewar <dewar@adacore.com>
9750
9751 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
9752
97532011-08-02 Ed Schonberg <schonberg@adacore.com>
9754
9755 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
9756 private type with a tagged full view is not derived in the immediate
9757 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
9758
97592011-08-02 Robert Dewar <dewar@adacore.com>
9760
9761 * exp_ch4.adb: Minor reformatting.
9762
97632011-08-02 Ed Schonberg <schonberg@adacore.com>
9764
9765 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
9766 Ada2012 iterator, the loop will be rewritten during expansion into a
9767 while loop with a cursor and an element declaration. Do not analyze the
9768 body in this case, because if the container is for indefinite types the
9769 actual subtype of the elements will only be determined when the cursor
9770 declaration is analyzed.
9771
97722011-08-02 Arnaud Charlet <charlet@adacore.com>
9773
9774 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
9775 size/alignment related attributes in CodePeer_Mode.
9776
97772011-08-02 Gary Dismukes <dismukes@adacore.com>
9778
9779 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
9780 Prepend_Element, since this can result in the operation getting the
9781 wrong slot in the full type's dispatch table if the full type has
9782 inherited operations. The incomplete type's operation will get added
9783 to the proper position in the full type's primitives
9784 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
9785 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
9786 dispatching operations, since there are cases where nonprimitive
9787 subprograms can get added to the list of incomplete dependents (such
9788 as subprograms in nested packages).
9789 * sem_ch6.adb (Process_Formals): First, remove test for being in a
9790 private part when determining whether to add a primitive with a
9791 parameter of a tagged incomplete type to the Private_Dependents list.
9792 Such primitives can also occur in the visible part, and should not have
9793 been excluded from being private dependents.
9794 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
9795 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
9796 list of a Taft-amendment incomplete type is a primitive before issuing
9797 an error that the full type must appear in the same unit. There are
9798 cases where nonprimitives can be in the list (such as subprograms in
9799 nested packages).
9800 * sem_disp.adb (Derives_From): Use correct condition for checking that
9801 a formal's type is derived from the type of the corresponding formal in
9802 the parent subprogram (the condition was completely wrong). Add
9803 checking that was missing for controlling result types being derived
9804 from the result type of the parent operation.
9805
98062011-08-02 Yannick Moy <moy@adacore.com>
9807
9808 * errout.adb (First_Node): minor renaming
9809 * restrict.adb (Check_Formal_Restriction): put restriction warning on
9810 first node.
9811
98122011-08-02 Yannick Moy <moy@adacore.com>
9813
9814 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
9815 before accessing operands.
9816 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
9817 decide whether an initialization expression respects SPARK rules, as
9818 the plain node is the expanded one. This allows for more valid warnings
9819 to be issued.
9820 * gnat_rm.texi: Minor update.
9821
98222011-08-02 Arnaud Charlet <charlet@adacore.com>
9823
9824 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
9825 previous change.
9826
98272011-08-02 Robert Dewar <dewar@adacore.com>
9828
9829 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
9830
98312011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
9832
9833 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
9834 loop statements and the element renaming declaration with a block when
9835 the element type is controlled.
9836
98372011-08-02 Yannick Moy <moy@adacore.com>
9838
9839 * sinfo.ads: Minor formatting.
9840
98412011-08-02 Ed Schonberg <schonberg@adacore.com>
9842
9843 * sem_aggr.adb (Add_Association): if the association has a box and no
9844 expression, use the Sloc of the aggregate itself for the new
9845 association.
9846 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
9847 the Original_Node.
9848
98492011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
9850
9851 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
9852 When a container is provided via a function call, generate a renaming
9853 of the function result. This avoids the creation of a transient scope
9854 and the premature finalization of the container.
9855 * exp_ch7.adb (Is_Container_Cursor): Removed.
9856 (Wrap_Transient_Declaration): Remove the supression of the finalization
9857 of the list controller when the declaration denotes a container cursor,
9858 it is not needed.
9859
98602011-08-02 Yannick Moy <moy@adacore.com>
9861
9862 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
9863 node is from source, instead of the original node being from source.
9864 * sem_aggr.adb
9865 (Resolve_Array_Aggregate): refine the check for a static expression, to
9866 recognize also static ranges
9867 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
9868 Array_Type_Declaration): postpone the test for the type being a subtype
9869 mark after the type has been resolved, so that component-selection and
9870 expanded-name are discriminated.
9871 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
9872 to distinguish the case of an iteration scheme, so that an error is
9873 issed on a non-static range in SPARK except in an iteration scheme.
9874 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
9875 In_Iter_Schm = True.
9876 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
9877 user-defined operators so that they are allowed in renaming
9878 * sem_ch8.adb
9879 (Find_Selected_Component): refine the check for prefixing of operators
9880 so that they are allowed in renaming. Move the checks for restrictions
9881 on selector name after analysis discriminated between
9882 component-selection and expanded-name.
9883 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
9884 concatenation argument of string type if it is static.
9885 * sem_util.adb, sem_util.ads
9886 (Check_Later_Vs_Basic_Declarations): add a new function
9887 Is_Later_Declarative_Item to decice which declarations are allowed as
9888 later items, in the two different modes Ada 83 and SPARK. In the SPARK
9889 mode, add that renamings are considered as later items.
9890 (Enclosing_Package): new function to return the enclosing package
9891 (Enter_Name): correct the rule for homonyms in SPARK
9892 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
9893 from source (result of expansion) to avoid issuing wrong warnings.
9894
98952011-08-02 Ed Schonberg <schonberg@adacore.com>
9896
9897 * errout.adb: On anything but an expression First_Node returns its
9898 argument.
9899
99002011-08-02 Pascal Obry <obry@adacore.com>
9901
9902 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
9903
99042011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
9905
9906 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
9907 Set the associated loop as the related expression of internally
9908 generated cursors.
9909 * exp_ch7.adb (Is_Container_Cursor): New routine.
9910 (Wrap_Transient_Declaration): Supress the finalization of the list
9911 controller when the declaration denotes a container cursor.
9912
99132011-08-02 Yannick Moy <moy@adacore.com>
9914
9915 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
9916 command line now.
9917 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
9918 expression is a simple expression. This check cannot be performed in
9919 the semantics, so just drop it.
9920 (P_Index_Or_Discriminant_Constraint): move check that the index or
9921 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
9922 semantics. Other cases were previously checked in the semantics.
9923 * par-ch4.adb (P_Name): move checks that a selector name is not
9924 character literal or an operator symbol to Find_Selected_Component in
9925 the semantics
9926 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
9927 declarations are not placed after later declarations in a separate
9928 procedure in Sem_Util (possibly not the best choice?), to be used both
9929 during parsing, for Ada 83 mode, and during semantic analysis, for
9930 SPARK mode.
9931 * par-endh.adb (Check_End): move check that end label is not missing
9932 to Process_End_Label in the semantics
9933 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
9934 the special case for SPARK restriction
9935 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
9936 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
9937 parameter Force to issue the error message even on internal node (used
9938 for generated end label). Call Check_Restriction to check when an error
9939 must be issued. In SPARK mode, issue an error message even if the
9940 restriction is not set.
9941 (Check_Restriction): new procedure with an additional out parameter to
9942 inform the caller that a message has been issued
9943 * sem_aggr.adb: Minor modification of message
9944 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
9945 instead of issuing an error message directly
9946 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
9947 declarations are not placed after later declarations, by calling
9948 Check_Later_Vs_Basic_Declarations
9949 (Analyze_Subtype_Declaration): move here the check that an index or
9950 discriminant constraint must be a subtype mark. Change the check that
9951 a subtype of String must start at one so that it works on subtype marks.
9952 * sem_ch4.adb (Analyze_Call): move here the check that a named
9953 association cannot follow a positional one in a call
9954 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
9955 instead of issuing an error message directly
9956 * sem_ch8.adb (Find_Selected_Component): move here the check that a
9957 selector name is not a character literal or an operator symbol. Move
9958 here the check that the prefix of an expanded name cannot be a
9959 subprogram or a loop statement.
9960 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
9961 procedure called from parsing and semantics to check that basic
9962 declarations are not placed after later declarations
9963 (Process_End_Label): move here the check that end label is not missing
9964
99652011-08-02 Arnaud Charlet <charlet@adacore.com>
9966
9967 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
9968 representation clause in codepeer mode, since it confuses CodePeer and
9969 does not bring useful info.
9970
99712011-08-02 Ed Falis <falis@adacore.com>
9972
9973 * init.c: initialize fp hw on MILS.
9974
99752011-08-02 Ed Schonberg <schonberg@adacore.com>
9976
9977 * errout.adb (First_Node): for bodies, return the node itself (small
9978 optimization). For other nodes, do not check source_unit if the node
9979 comes from Standard.
9980
99812011-08-02 Robert Dewar <dewar@adacore.com>
9982
9983 * exp_ch3.adb: Minor comment additions.
9984 * sem_ch13.adb: Minor reformatting.
9985
99862011-08-02 Pascal Obry <obry@adacore.com>
9987
9988 * make.adb, makeutl.adb: Removes some superfluous directory separator.
9989
99902011-08-02 Robert Dewar <dewar@adacore.com>
9991
9992 * sem_attr.adb: Minor reformatting.
9993
99942011-08-02 Robert Dewar <dewar@adacore.com>
9995
9996 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
9997 (Has_Default_Component_Value): Removed
9998 * einfo.ads Comment updates
9999 (Has_Default_Aspect): Replaces Has_Default_Value
10000 (Has_Default_Component_Value): Removed
10001 * exp_ch13.adb
10002 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
10003 * exp_ch3.adb
10004 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
10005 (Get_Simple_Init_Val): Handle Default_Value aspect
10006 (Needs_Simple_Initialization): Handle Default_Value aspect
10007 * exp_ch3.ads: Needs_Simple_Initialization
10008 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
10009 * par-prag.adb (Pragma_Default[_Component]Value) Removed
10010 * sem_ch13.adb
10011 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
10012 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
10013 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
10014
100152011-08-02 Ed Schonberg <schonberg@adacore.com>
10016
10017 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
10018 package containing iteration primitives.
10019 exp_ch5.adb (Expand_Iterator_Loop): ditto.
10020
100212011-08-02 Ed Schonberg <schonberg@adacore.com>
10022
10023 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
10024 "of", pre-analyze expression in case it is a function call with
10025 finalization actions that must be placed ahead of the loop.
10026 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
10027 on an Ada2012 iterator, insert them ahead of the rewritten loop.
10028
100292011-08-02 Geert Bosch <bosch@adacore.com>
10030
10031 * cstand.adb (Create_Float_Types): Only consider C's long double for
10032 Long_Long_Float, in addition to double.
10033
100342011-08-02 Robert Dewar <dewar@adacore.com>
10035
10036 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
10037 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
10038 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
10039 Minor reformatting.
10040
100412011-08-02 Ed Schonberg <schonberg@adacore.com>
10042
10043 * sem_attr.adb: handle properly 'Result when it is a prefix of an
10044 indexed component.
10045
100462011-08-02 Javier Miranda <miranda@adacore.com>
10047
10048 * einfo.ads, einfo.adb
10049 (Original_Access_Type): Move this attribute to Node26 since there was
10050 an undocumented use of Node21 in E_Access_Subprogram_Type entities
10051 which causes conflicts and breaks the generation of the .NET compiler.
10052 (Interface_Name): Add missing documentation on JGNAT only uses of
10053 this attribute.
10054
100552011-08-02 Geert Bosch <bosch@adacore.com>
10056
10057 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
10058 (Find_Back_End_Float_Type): Likewise
10059 (Create_Back_End_Float_Types): Likewise
10060 (Create_Float_Types): Likewise
10061 (Register_Float_Type): Likewise
10062 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
10063 Nlist and split out type selection in new local Find_Base_Type function.
10064 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
10065 Nlist
10066 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
10067
100682011-08-02 Robert Dewar <dewar@adacore.com>
10069
10070 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
10071 alpha order).
10072 * opt.ads: Minor comment change.
10073 * sem_ch12.adb: Minor code reorganization.
10074
100752011-08-02 Gary Dismukes <dismukes@adacore.com>
10076
10077 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
10078 subtype's list of rep items to the list on the full subtype in the case
10079 where the lists are the same.
10080
100812011-08-02 Geert Bosch <bosch@adacore.com>
10082
10083 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
10084 using the one from System.Strings, which also deallocates all strings.
10085
100862011-08-02 Geert Bosch <bosch@adacore.com>
10087
10088 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
10089 function.
10090 * gcc-interface/Make-lang.in: Update dependencies.
10091
100922011-08-02 Olivier Hainque <hainque@adacore.com>
10093
10094 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
10095 end_locus.
10096
100972011-08-02 Javier Miranda <miranda@adacore.com>
10098
10099 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
10100 associated with anonymous access to subprograms.
10101
101022011-08-02 Geert Bosch <bosch@adacore.com>
10103
10104 * opt.ads
10105 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
10106 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
10107 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
10108 (Add_Symbol_Definition): Move to switch-c.adb
10109 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
10110 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
10111 (Add_Symbol_Definition): Move to switch-c.adb.
10112 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
10113 * sem_warn.adb
10114 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
10115 Move to warnsw.adb.
10116 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
10117 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
10118 Move to warnsw.adb.
10119 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
10120 (Add_Symbol_Definition): Moved from Prepcomp.
10121 * switch-c.ads: Update copyright notice. Use String_List instead of
10122 Argument_List, removing dependency on System.OS_Lib.
10123
101242011-08-02 Yannick Moy <moy@adacore.com>
10125
10126 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
10127 mode on initialization expression which does not respect SPARK
10128 restrictions.
10129 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
10130 if the tree referenced by its argument represents an initialization
10131 expression in SPARK, suitable for initializing an object in an object
10132 declaration.
10133
101342011-08-02 Javier Miranda <miranda@adacore.com>
10135
10136 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
10137 internally generated access to subprogram with its associated protected
10138 subprogram type.
10139 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
10140
101412011-08-02 Geert Bosch <bosch@adacore.com>
10142
10143 * cstand.adb (Register_Float_Type): Print information about type to
10144 register, if the Debug_Flag_Dot_B is set.
10145 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
10146 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
10147 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
10148 with a requested precision of more than Max_Digits digits and no more
10149 than Max_Base_Digits digits, if a range specification is present and the
10150 Predefined_Float_Types list has a suitable type to derive from.
10151 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
10152 case of type completion with pragma Import
10153 * sem_prag.adb
10154 (Process_Import_Predefined_Type): Processing to complete a type
10155 with pragma Import. Currently supports floating point types only.
10156 (Set_Convention_From_Pragma): Do nothing without underlying type.
10157 (Process_Convention): Guard against absence of underlying type,
10158 which may happen when importing incomplete types.
10159 (Process_Import_Or_Interface): Handle case of importing predefined
10160 types. Tweak error message.
10161
101622011-08-02 Eric Botcazou <ebotcazou@adacore.com>
10163
10164 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
10165 functions to previous change. Reorganize code slightly.
10166
101672011-08-02 Geert Bosch <bosch@adacore.com>
10168
10169 * back_end.ads (Register_Type_Proc): New call back procedure type for
10170 allowing the back end to provide information about available types.
10171 (Register_Back_End_Types): New procedure to register back end types.
10172 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
10173 available types.
10174 * cstand.adb (Back_End_Float_Types): New list for floating point types
10175 supported by the back end.
10176 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
10177 (Copy_Float_Type): New procedure to make new copies of predefined types.
10178 (Register_Float_Type): New call back procedure to populate the BEFT list
10179 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
10180 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
10181 (Create_Float_Types): New procedure to create entities for floating
10182 point types predefined in Standard, and put these and any remaining
10183 BEFTs on the Predefined_Float_Types list.
10184 * stand.ads (Predefined_Float_Types): New list for predefined floating
10185 point types that do not have declarations in package Standard.
10186
101872011-08-02 Eric Botcazou <ebotcazou@adacore.com>
10188
10189 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
10190 entity node for the unit containing the parameter.
10191 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
10192 (Add_Inlined_Subprogram): Likewise.
10193 * gcc-interface/Make-lang.in: Update dependencies.
10194
101952011-08-02 Thomas Quinot <quinot@adacore.com>
10196
10197 * s-stusta.adb (Print): Make sure Pos is always initialized to a
10198 suitable value.
10199
102002011-08-02 Geert Bosch <bosch@adacore.com>
10201
10202 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
10203
102042011-08-02 Eric Botcazou <ebotcazou@adacore.com>
10205
10206 * sem_type.adb (Covers): Move trivial case to the top and reuse the
10207 computed value of Base_Type.
10208
102092011-08-02 Yannick Moy <moy@adacore.com>
10210
10211 * restrict.adb (Check_Restriction): issue an error for any use of
10212 class-wide, even if the No_Dispatch restriction is not set.
10213 * sem_aggr.adb: Correct typos in comments and messages in formal mode
10214 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
10215 when completing a private extension, the type named in the private part
10216 is not the same as that named in the visible part.
10217 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
10218 of an inherited primitive operations of a tagged type or type extension
10219 that returns the tagged type.
10220 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
10221 function which returns True for an implicit operation inherited by the
10222 derived type declaration for the argument type.
10223 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
10224 order.
10225
102262011-08-02 Ed Schonberg <schonberg@adacore.com>
10227
10228 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
10229 Process_Bounds, to perform analysis with expansion of a range or an
10230 expression that is the iteration scheme for a loop.
10231 (Analyze_Iterator_Specification): If domain of iteration is given by a
10232 function call with a controlled result, as is the case if call returns
10233 a predefined container, ensure that finalization actions are properly
10234 generated.
10235 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
10236
102372011-08-02 Javier Miranda <miranda@adacore.com>
10238
10239 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
10240 * gcc-interface/Make-lang.in: Update dependencies.
10241
102422011-08-02 Javier Miranda <miranda@adacore.com>
10243
10244 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
10245 determine if the analysis is performed using N or Original_Node (N).
10246 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
10247 functionality of routine Is_Variable avoids code duplication.
10248 * checks.adb (Determine_Range): Handle temporaries generated by
10249 Remove_Side_Effects.
10250
102512011-08-02 Javier Miranda <miranda@adacore.com>
10252
10253 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
10254 expansion of the condition. Required since the previous analysis was
10255 done with expansion disabled (see Resolve_Quantified_Expression) and
10256 hence checks were not inserted and record comparisons have not been
10257 expanded.
10258
102592011-08-02 Ed Falis <falis@adacore.com>
10260
10261 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
10262 Update header.
10263
102642011-08-02 Bob Duff <duff@adacore.com>
10265
10266 * opt.ads: Minor comment fix.
10267
102682011-08-02 Bob Duff <duff@adacore.com>
10269
10270 * sem_ch12.adb (Analyze_Package_Instantiation,
10271 Analyze_Subprogram_Instantiation): Turn off style checking while
10272 analyzing an instance. Whatever style checks that apply to the generic
10273 unit should apply, so it makes no sense to apply them in an instance.
10274 This was causing trouble when compiling an instance of a runtime
10275 unit that violates the -gnatyO switch.
10276 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
10277 one of the two case statements, causing spurious errors.
10278
102792011-08-02 Robert Dewar <dewar@adacore.com>
10280
10281 * uname.adb: Minor reformatting.
10282 * gnatcmd.adb: Minor reformatting.
10283 * exp_attr.adb: Minor reformatting.
10284
102852011-08-02 Ed Schonberg <schonberg@adacore.com>
10286
10287 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
10288 No_Dispatching_Calls, do not look for the Assign primitive, because
10289 predefined primitives are not created in this case.
10290
102912011-08-02 Bob Duff <duff@adacore.com>
10292
10293 * stylesw.ads: Minor comment fixes.
10294
102952011-08-02 Robert Dewar <dewar@adacore.com>
10296
10297 * freeze.adb (Add_To_Result): New procedure.
10298
102992011-08-02 Jose Ruiz <ruiz@adacore.com>
10300
10301 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
10302 time, if the specific run-time routines for handling streams of strings
10303 are not available, use the default mechanism.
10304
103052011-08-02 Arnaud Charlet <charlet@adacore.com>
10306
10307 * s-regpat.ads: Fix typo.
10308
103092011-08-02 Vincent Celier <celier@adacore.com>
10310
10311 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
10312 not null, call it to create the in memory config project file without
10313 parsing an existing default config project file.
10314
103152011-08-02 Eric Botcazou <ebotcazou@adacore.com>
10316
10317 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
10318
103192011-08-02 Ed Schonberg <schonberg@adacore.com>
10320
10321 * sem_elim.adb: an abstract subprogram does not need an eliminate
10322 pragma for its descendant to be eliminable.
10323
103242011-08-02 Ed Falis <falis@adacore.com>
10325
10326 * init.c: revert to handling before previous checkin for VxWorks
10327 * s-intman-vxworks.adb: delete unnecessary declarations related to
10328 using Ada interrupt facilities for handling signals.
10329 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
10330 * s-intman-vxworks.ads: Import __gnat_install_handler as
10331 Initialize_Interrupts.
10332 * s-taprop-vxworks.adb: Delete Signal_Mask.
10333 (Abort_Handler): change construction of mask to unblock exception
10334 signals.
10335
103362011-08-02 Jerome Guitton <guitton@adacore.com>
10337
10338 * a-except-2005.adb (Raise_From_Signal_Handler): Call
10339 Debug_Raise_Exception before propagation starts.
10340
103412011-08-02 Eric Botcazou <ebotcazou@adacore.com>
10342
10343 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
10344 to Restriction_Check_Required.
10345 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
10346 * sem_res.adb (Resolve_Call): Likewise.
10347 * sem_attr.adb (Check_Stream_Attribute): Likewise.
10348
103492011-08-02 Bob Duff <duff@adacore.com>
10350
10351 * stylesw.ads: Update comment.
10352 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
10353 * errout.ads: Remove obsolete comment.
10354
103552011-08-02 Javier Miranda <miranda@adacore.com>
10356
10357 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
10358 (Set_Is_Safe_To_Reevaluate): new procedure.
10359 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
10360 assignment is allowed on safe-to-reevaluate variables.
10361 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
10362 temporary created to remove side effects in expressions that use
10363 the secondary stack as safe-to-reevaluate.
10364 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
10365 variables that are not true constants.
10366
103672011-08-02 Robert Dewar <dewar@adacore.com>
10368
10369 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
10370 sem_res.adb, sem_ch6.adb: Minor reformatting.
10371
103722011-08-02 Jerome Guitton <guitton@adacore.com>
10373
10374 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
10375
103762011-08-02 Ed Schonberg <schonberg@adacore.com>
10377
10378 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
10379 not set Overridden_Operation if subprogram is an initialization
10380 procedure.
10381
103822011-08-02 Yannick Moy <moy@adacore.com>
10383
10384 * par-ch6.adb: Correct obsolete name in comments
10385 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
10386 which takes two message arguments (existing function takes one), with
10387 second message used for continuation.
10388 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
10389 block statements that originate from a source block statement, not
10390 generated block statements
10391 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
10392 symmetry with procedure case
10393 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
10394 function to issue an error in formal mode if a package specification
10395 contains more than one tagged type or type extension.
10396 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
10397 parameters matching formals of tagged types are objects (or ancestor
10398 type conversions of objects), not general expressions. Issue an error
10399 on view conversions that are not involving ancestor conversion of an
10400 extended type.
10401 (Resolve_Type_Conversion): in formal mode, issue an error on the
10402 operand of an ancestor type conversion which is not an object
10403 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
10404 procedure so that it works also for actuals of function calls
10405 (Is_Actual_Tagged_Parameter): new function which determines if its
10406 argument is an actual parameter of a formal of tagged type in a
10407 subprogram call
10408 (Is_SPARK_Object_Reference): new function which determines if the tree
10409 referenced by its argument represents an object in SPARK
10410
104112011-08-02 Robert Dewar <dewar@adacore.com>
10412
10413 * sem_ch3.adb: Minor reformatting
10414 Minor comment addition
10415 Minor error msg text change
10416
104172011-08-02 Javier Miranda <miranda@adacore.com>
10418
10419 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
10420 function. Used to be more precise when we generate a variable plus one
10421 assignment to remove side effects in the evaluation of the Bound
10422 expressions.
10423 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
10424 of the bound expression to force its re-analysis and thus expand the
10425 associated transient scope (if required). Code cleanup replacing the
10426 previous code that declared the constant entity by an invocation to
10427 routine Force_Evaluation which centralizes this work in the frontend.
10428
104292011-08-02 Robert Dewar <dewar@adacore.com>
10430
10431 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
10432 (Base_Type): Now uses improved Is_Base_Type function
10433 * einfo.ads (Base_Type): Inline this function
10434
104352011-08-02 Robert Dewar <dewar@adacore.com>
10436
10437 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
10438 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
10439
104402011-08-02 Arnaud Charlet <charlet@adacore.com>
10441
10442 * gcc-interface/Make-lang.in: Update dependencies.
10443 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
10444 targets.
10445
104462011-08-02 Yannick Moy <moy@adacore.com>
10447
10448 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
10449 non-simple expression used in delta constraint
10450 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
10451 index constraint which is not a subtype mark
10452 * par.adb: With and use Restrict
10453 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
10454 mode on component type which is not a subtype mark and default
10455 expression on component
10456 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
10457 of string which does not have a lower index bound equal to 1
10458 (Array_Type_Declaration): issue an error in formal mode on index or
10459 component type which is not a subtype mark, and on aliased keyword on
10460 component
10461 (Derived_Type_Declaration): issue an error in formal mode on interface,
10462 limited or abstract type
10463 (Record_Type_Declaration): issue an error in formal mode on interface
10464 (Record_Type_Definition): issue an error in formal mode on tagged types
10465 and type extensions not declared in the specification of a library unit
10466 package; on null non-tagged record; on variant part
10467
104682011-08-02 Vincent Celier <celier@adacore.com>
10469
10470 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
10471 not declared for qualified library project when Library_Name is not
10472 declared, but Library_Dir is.
10473
104742011-08-02 Robert Dewar <dewar@adacore.com>
10475
10476 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
10477 pragmas (affects aspects [Component_]Default_Value
10478 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
10479 component type for the resolution
10480
104812011-08-02 Eric Botcazou <ebotcazou@adacore.com>
10482
10483 * einfo.adb (Base_Type): Tune implementation for speed.
10484
104852011-08-02 Robert Dewar <dewar@adacore.com>
10486
10487 * freeze.adb: Minor reformatting.
10488
104892011-08-02 Thomas Quinot <quinot@adacore.com>
10490
10491 * scos.ads: Update comments.
10492
104932011-08-02 Ed Schonberg <schonberg@adacore.com>
10494
10495 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
10496 base type, because the parent may be a subtype of a private type whose
10497 convention is established in a private part.
10498
104992011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
10500
10501 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
10502 statement in a block when the expansion of the return expression has
10503 created a finalization chain.
10504 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
10505 with the parent node.
10506 Add N_Extended_Return_Statement to handle the case where a transient
10507 object declaration appears in the Return_Object_Declarations list of
10508 an extended return statement.
10509
105102011-08-02 Matthew Gingell <gingell@adacore.com>
10511
10512 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
10513 unused parameter 'name'.
10514
105152011-08-02 Ed Schonberg <schonberg@adacore.com>
10516
10517 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
10518 inherited operation, check whether its alias, which is the source
10519 operastion that it renames, has been marked eliminated.
10520
105212011-08-02 Javier Miranda <miranda@adacore.com>
10522
10523 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
10524 in-mode parameter whose type is an access type since it can be used to
10525 modify its designated object. Enforce code that handles as safe an
10526 access type that is not access-to-constant but it is the result of a
10527 previous removal of side-effects.
10528 (Remove_Side_Effects): Minor code reorganization of cases which require
10529 no action. Done to incorporate documentation on new cases uncovered
10530 working in this ticket: no action needed if this routine was invoked
10531 too early and the nodes are not yet decorated.
10532 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
10533 to routine Remove_Side_Effects by calls to Force_Evaluation since they
10534 were issued with actuals that are implicitly provided by
10535 Force_Evaluation.
10536
105372011-08-02 Robert Dewar <dewar@adacore.com>
10538
10539 * sem_ch3.adb, sem_res.adb: Minor reformatting.
10540
105412011-08-02 Yannick Moy <moy@adacore.com>
10542
10543 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
10544 to issue an error in formal mode on attribute not supported in this mode
10545 (Analyze_Attribute): issue errors on standard attributes not supported
10546 in formal mode.
10547 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
10548 comment, and issue error in formal mode on modulus which is not a power
10549 of 2.
10550 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
10551 range.
10552 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
10553 subtype mark.
10554 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
10555 operator on modular type (except 'not').
10556
105572011-08-02 Robert Dewar <dewar@adacore.com>
10558
10559 * gnat_rm.texi: Minor reformatting.
10560
105612011-08-02 Arnaud Charlet <charlet@adacore.com>
10562
10563 * s-osinte-linux.ads: Minor comment update and reformatting.
10564 * i-cexten.ads: Make this unit pure, as for its parent.
10565 Will allow its usage in more contexts if needed.
10566
105672011-08-02 Robert Dewar <dewar@adacore.com>
10568
10569 * s-utf_32.ads: Minor comment fix.
10570
105712011-08-02 Ed Schonberg <schonberg@adacore.com>
10572
10573 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
10574 operation of a tagged synchronized type, handle the case where the
10575 controlling argument is overloaded.
10576
105772011-08-02 Yannick Moy <moy@adacore.com>
10578
10579 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
10580 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
10581 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
10582 SPARK mode and formal verification mode on processing SPARK restriction
10583 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
10584 requiring consistency checking.
10585
105862011-08-02 Robert Dewar <dewar@adacore.com>
10587
10588 * sem_res.adb: Minor reformatting.
10589
105902011-08-02 Robert Dewar <dewar@adacore.com>
10591
10592 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
10593 a-cforse.ads: Remove unneeded with of Ada.Containers
10594 Remove commented out pragma Inline's
10595 Move specifications of new subprograms to the actual specs
10596
105972011-08-02 Yannick Moy <moy@adacore.com>
10598
10599 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
10600 a-cforse.ads: Update comments.
10601
106022011-08-02 Ed Schonberg <schonberg@adacore.com>
10603
10604 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
10605
106062011-08-02 Robert Dewar <dewar@adacore.com>
10607
10608 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
10609 a-cforse.ads, a-cofove.ads: Minor reformatting.
10610
106112011-08-02 Claire Dross <dross@adacore.com>
10612
10613 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
10614 a-cofove.ads: Add comments.
10615
106162011-08-02 Yannick Moy <moy@adacore.com>
10617
10618 * gnat_rm.texi: Document formal containers.
10619
106202011-08-02 Emmanuel Briot <briot@adacore.com>
10621
10622 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
10623 are empty sections.
10624
106252011-08-02 Robert Dewar <dewar@adacore.com>
10626
10627 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
10628 reformatting.
10629
106302011-08-02 Robert Dewar <dewar@adacore.com>
10631
10632 * aspects.adb: New aspects Default_Value and Default_Component_Value
10633 New format of Aspect_Names table checks for omitted entries
10634 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
10635 handling of boolean aspects for derived types.
10636 New aspects Default_Value and Default_Component_Value
10637 New format of Aspect_Names table checks for omitted entries
10638 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
10639 (Has_Default_Value): New flag
10640 (Has_Default_Component_Value): New flag
10641 (Has_Default_Value): New flag
10642 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
10643 table.
10644 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
10645 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
10646 Default_Value and Default_Component_Value
10647 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
10648 New aspects Default_Value and Default_Component_Value
10649 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
10650 * sprint.adb: Print N_Aspect_Specification node when called from gdb
10651
106522011-08-02 Vincent Celier <celier@adacore.com>
10653
10654 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
10655 inherit library kind.
10656
106572011-08-02 Ed Schonberg <schonberg@adacore.com>
10658
10659 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
10660 Minor reformatting.
10661
106622011-08-02 Robert Dewar <dewar@adacore.com>
10663
10664 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
10665
106662011-08-02 Yannick Moy <moy@adacore.com>
10667
10668 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
10669
106702011-08-02 Robert Dewar <dewar@adacore.com>
10671
10672 * impunit.adb: Add comment.
10673
106742011-08-02 Yannick Moy <moy@adacore.com>
10675
10676 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
10677 qualification of aggregates in formal mode
10678 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
10679 another aggregate
10680 (Resolve_Aggregate): complete the test that an aggregate is adequately
10681 qualified in formal mode
10682
106832011-08-02 Pascal Obry <obry@adacore.com>
10684
10685 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
10686 * mlib-prj.adb: Supress warning when compiling binder generated file.
10687 (Build_Library): Supress all warnings when compiling the binder
10688 generated file.
10689
106902011-08-02 Yannick Moy <moy@adacore.com>
10691
10692 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
10693 from here...
10694 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
10695 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
10696 Add with/use clauses to make Check_Formal_Restriction visible
10697
106982011-08-02 Ed Schonberg <schonberg@adacore.com>
10699
10700 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
10701 in-parameters when type of the generic formal is private in the generic
10702 spec and non-private in the body.
10703
107042011-08-02 Claire Dross <dross@adacore.com>
10705
10706 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
10707 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
10708 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
10709 * impunit.adb, Makefile.rtl: Take new files into account.
10710
107112011-08-02 Robert Dewar <dewar@adacore.com>
10712
10713 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
10714 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
10715
107162011-08-02 Yannick Moy <moy@adacore.com>
10717
10718 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
10719 formal mode
10720 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
10721 matching static array bounds, taking into account the special case of
10722 string literals
10723 * sem_ch3.adb: Typo in comment.
10724
107252011-08-02 Yannick Moy <moy@adacore.com>
10726
10727 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
10728 which issues an error in formal mode if its argument node is originally
10729 from source
10730 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
10731 has a discriminant specification so that it does not include the case
10732 of derived types
10733 (Derived_Type_Declaration): move here the test that a derived type has a
10734 discriminant specification
10735 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
10736 first element of a component association before accessing its choices
10737 (presence of component association is not enough)
10738 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
10739 declaration is a library item before accessing the next element in a
10740 list, as library items are not member of lists
10741 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
10742 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
10743 Check_Formal_Restriction whenever possible.
10744
107452011-08-02 Ed Schonberg <schonberg@adacore.com>
10746
10747 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
10748 reference when needed.
10749
107502011-08-02 Bob Duff <duff@adacore.com>
10751
10752 * gnat_ugn.texi: Fix typo.
10753
107542011-08-02 Vincent Celier <celier@adacore.com>
10755
10756 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
10757 archive file name. Do not use the full path name of archives for Open
10758 VMS.
10759
107602011-08-02 Robert Dewar <dewar@adacore.com>
10761
10762 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
10763 Analyze_Aspect_Specifications
10764 * sem_ch13.adb
10765 (Analyze_Aspect_Specifications): New handling for boolean aspects
10766 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
10767 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
10768 sequence for Analyze_Aspect_Specifications
10769 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
10770 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
10771
107722011-08-02 Robert Dewar <dewar@adacore.com>
10773
10774 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
10775 aspects, since these no longer exist.
10776
107772011-08-02 Robert Dewar <dewar@adacore.com>
10778
10779 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
10780 semicolon, do not try to see if there are aspects following it.
10781 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
10782 aspect spec.
10783
107842011-08-02 Robert Dewar <dewar@adacore.com>
10785
10786 * sem_ch8.adb, aspects.ads: Minor reformatting.
10787
107882011-08-02 Eric Botcazou <ebotcazou@adacore.com>
10789
10790 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
10791 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
10792 extracted from...
10793 (Analyze_Aspect_Specifications): ...here. Call above procedure.
10794
107952011-08-02 Yannick Moy <moy@adacore.com>
10796
10797 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
10798 mode on subprogram declaration outside of package specification, unless
10799 it is followed by a pragma Import
10800 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
10801 Access_Type_Declaration): issue error in formal mode on access type
10802 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
10803 incomplete type
10804 (Analyze_Object_Declaration): issue error in formal mode on object
10805 declaration which does not respect SPARK restrictions
10806 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
10807 declaration which does not respect SPARK restrictions
10808 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
10809 error in formal mode on digits or delta constraint
10810 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
10811 decimal fixed point type
10812 (Derived_Type_Declaration): issue error in formal mode on derived type
10813 other than type extensions of tagged record types
10814 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
10815 with check on access definition
10816 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
10817 mode on protected definition.
10818 (Analyze_Task_Definition): issue error in formal mode on task definition
10819
108202011-08-02 Robert Dewar <dewar@adacore.com>
10821
10822 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
10823
108242011-08-02 Javier Miranda <miranda@adacore.com>
10825
10826 * sem_ch6.adb (Can_Override_Operator): New function.
10827 (Verify_Overriding_Indicator): Add missing code to check overriding
10828 indicator in operators. Fixes regression.
10829 (Check_Overriding_Indicator): Minor reformating after replacing the
10830 code that evaluates if the subprogram can override an operator by
10831 invocations to the above new function.
10832 * einfo.adb
10833 (Write_Field26_Name): Add missing code to ensure that, following
10834 the documentation in einfo.ads, this field is not shown as attribute
10835 "Static_Initialization" on non-dispatching functions.
10836
108372011-08-02 Jose Ruiz <ruiz@adacore.com>
10838
10839 * sem_res.adb (Resolve_Call): A call to
10840 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
10841 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
10842 i.e., when the second parameter is of type Time_Span.
10843
108442011-08-02 Vincent Celier <celier@adacore.com>
10845
10846 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
10847 with an archive instead of -L<library dir> -l<library name>.
10848
108492011-08-02 Ed Schonberg <schonberg@adacore.com>
10850
10851 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
10852 mark the base types In_Use in addition to making the operations
10853 use_visible.
10854
108552011-08-02 Ed Falis <falis@adacore.com>
10856
10857 * init.c: add and setup __gnat_signal_mask for the exception signals
10858 * s-inmaop-vxworks.adb: new file.
10859 * s-intman-vxworks.adb: remove unnecessary initializations and
10860 simplify remaining
10861 * s-intman-vxworks.ads: remove unnecessary variable
10862 * s-taprop-vxworks.adb: simplify signal initialization
10863
108642011-08-02 Robert Dewar <dewar@adacore.com>
10865
10866 * sem_ch8.adb: Minor code reorganization, comment updates.
10867
108682011-08-02 Robert Dewar <dewar@adacore.com>
10869
10870 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
10871 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
10872 here from Sem_Res.
10873 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
10874 (Matching_Static_Array_Bounds): Moved here from Sem_Res
10875
108762011-08-02 Ed Schonberg <schonberg@adacore.com>
10877
10878 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
10879 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
10880 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
10881 use_type_clauses, to handle more efficiently use_type and use_all_type
10882 constructs.
10883 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
10884 Ada2012 Use_All_Type clause.
10885 (Use_Class_Wide_Operations): new procedure.
10886
108872011-08-02 Robert Dewar <dewar@adacore.com>
10888
10889 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
10890 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
10891 expression to expression function.
10892
108932011-08-02 Ed Schonberg <schonberg@adacore.com>
10894
10895 * sem_ch4.adb: transform simple Ada2012 membership into equality only
10896 if types are compatible.
10897
108982011-08-02 Yannick Moy <moy@adacore.com>
10899
10900 * sem_res.adb (Matching_Static_Array_Bounds): new function which
10901 returns True if its argument array types have same dimension and same
10902 static bounds at each index.
10903 (Resolve_Actuals): issue an error in formal mode on actuals passed as
10904 OUT or IN OUT paramaters which are not view conversions in SPARK.
10905 (Resolve_Arithmetic_Op): issue an error in formal mode on
10906 multiplication or division with operands of fixed point types which are
10907 not qualified or explicitly converted.
10908 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
10909 Boolean or array type (except String) operands.
10910 (Resolve_Equality_Op): issue an error in formal mode on equality
10911 operators for array types other than String with non-matching static
10912 bounds.
10913 (Resolve_Logical_Op): issue an error in formal mode on logical operators
10914 for array types with non-matching static bounds. Factorize the code in
10915 Matching_Static_Array_Bounds.
10916 (Resolve_Qualified_Expression): issue an error in formal mode on
10917 qualified expressions for array types with non-matching static bounds.
10918 (Resolve_Type_Conversion): issue an error in formal mode on type
10919 conversion for array types with non-matching static bounds
10920
109212011-08-02 Robert Dewar <dewar@adacore.com>
10922
10923 * par-ch10.adb: Minor code reorganization (use Nkind_In).
10924
109252011-08-02 Ed Schonberg <schonberg@adacore.com>
10926
10927 * par-ch9.adb: save location of entry for proper error message.
10928
109292011-08-02 Javier Miranda <miranda@adacore.com>
10930
10931 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
10932 (Use_Full_View) which permits this routine to climb through the
10933 ancestors using the full-view of private parents.
10934 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
10935 Use_Full_View to true in calls to Is_Ancestor.
10936 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
10937 true in call to Is_Ancestor.
10938 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
10939 Use_Full_View to true in call to Is_Ancestor.
10940 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
10941 call to Is_Ancestor.
10942 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
10943 Use_Full_View to true in calls to Is_Ancestor.
10944 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
10945 Make_Select_Specific_Data_Table, Register_Primitive,
10946 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
10947 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
10948 to true in call to Is_Ancestor.
10949 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
10950 Use_Full_View to true in calls to Is_Ancestor.
10951 * exp_cg.adb
10952 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
10953 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
10954
109552011-08-02 Robert Dewar <dewar@adacore.com>
10956
10957 * gnat_rm.texi: Minor reformatting.
10958 * sem_prag.adb: Minor reformatting.
10959
109602011-08-02 Tristan Gingold <gingold@adacore.com>
10961
10962 * vms_data.ads: Add VMS qualifier for -gnateP.
10963
109642011-08-02 Robert Dewar <dewar@adacore.com>
10965
10966 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
10967 * par-ch7.adb (P_Package): Proper placement of aspects for package
10968 decl/instantiation.
10969 * par-endh.adb (Check_End): Ad Is_Sloc parameter
10970 (End_Statements): Add Is_Sloc parameterr
10971 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
10972 (Check_End): Ad Is_Sloc parameter
10973 (End_Statements): Add Is_Sloc parameterr
10974
109752011-08-02 Vincent Celier <celier@adacore.com>
10976
10977 * ug_words: Add VMS qualifier equivalent to -gnateP:
10978 /SYMBOL_PREPROCESSING.
10979
109802011-08-02 Jose Ruiz <ruiz@adacore.com>
10981
10982 * gnat-style.texi: For hexadecimal numeric literals the typical
10983 grouping of digits is 4 to represent 2 bytes.
10984 A procedure spec which is split into several lines is indented two
10985 characters.
10986
109872011-08-02 Yannick Moy <moy@adacore.com>
10988
10989 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
10990 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
10991 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
10992 properly qualified
10993 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
10994 choice in array aggregate
10995 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
10996 mark as ancestor
10997 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
10998 positional and named aggregate for record, or others in record
10999 aggregate, or multiple choice in record aggregate
11000 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
11001 array operands to logical operations AND, OR and XOR do not have the
11002 same static lower and higher bounds
11003 * sem_ch5.adb, sinfo.ads: Correct typos in comments
11004
110052011-08-01 Robert Dewar <dewar@adacore.com>
11006
11007 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
11008 Replaces Last_Source_Node_In_Sequence.
11009 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
11010 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
11011 parens and blank in string (this was inconsistently implemented).
11012 * errout.ads
11013 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
11014 blank in string (this was inconsistently implemented).
11015 * gnat1drv.adb
11016 (Set_Global_Switches): Set formal mode switches appropriately
11017 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
11018 * par-prag.adb
11019 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
11020 call Set_Error_Msg_Lang to set "spark" as language name.
11021 * par.adb: Remove unnecessary call to set formal language for errout
11022 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
11023 appropriately and call Set_Error_Msg_Lang to set "spark" as language
11024 name.
11025 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
11026 calls to it, moved after resolution so that types are known
11027 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
11028 result of concatenation is not of type String
11029 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
11030 concatenation is not properly restricted
11031 * gnat_rm.texi: Add doc on pragma Spark_95.
11032 * gcc-interface/Makefile.in: Remove obsolete target pairs for
11033 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
11034 * gcc-interface/Make-lang.in: Update dependencies.
11035
110362011-08-01 Javier Miranda <miranda@adacore.com>
11037
11038 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
11039 condition that detects if the overridden operation must replace an
11040 existing entity.
11041
110422011-08-01 Javier Miranda <miranda@adacore.com>
11043
11044 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
11045 code declarations inserted by Insert_Actions in each alternative of the
11046 N_Case_Expression node.
11047
110482011-08-01 Robert Dewar <dewar@adacore.com>
11049
11050 * sem_ch6.adb: Minor code reorganization.
11051 * sem_util.adb: Minor reformatting.
11052
110532011-08-01 Pascal Obry <obry@adacore.com>
11054
11055 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
11056 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
11057
110582011-08-01 Yannick Moy <moy@adacore.com>
11059
11060 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
11061 literal or operator symbol which is prefixed
11062 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
11063 mode on access attributes.
11064 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
11065 that concatenation operands are properly restricted in formal mode
11066 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
11067 Analyze_Concatenation_Operand. Issue an error in formal mode if the
11068 result of the concatenation has a type different from String.
11069 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
11070 Analyze_Quantified_Expression, Analyze_Slice,
11071 Analyze_Null): issue an error in formal mode on unsupported constructs
11072 * sem_ch5.adb
11073 (Analyze_Block_Statement): only issue error on source block statement
11074 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
11075 function which returns the last node in a list of nodes for which
11076 Comes_From_Source returns True, if any
11077 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
11078 Last_Source_Node_In_Sequence
11079 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
11080 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
11081 mode on unsupported constructs
11082 * sem_ch9.adb Do not return after issuing error in formal mode, as the
11083 rest of the actions may be needed later on since the error is marked as
11084 not serious.
11085 * sinfo.ads: Typos in comments.
11086
110872011-08-01 Pascal Obry <obry@adacore.com>
11088
11089 * projects.texi: Minor editing.
11090
110912011-08-01 Yannick Moy <moy@adacore.com>
11092
11093 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
11094 insertion character ~~
11095 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
11096 (Set_Error_Msg_Lang): new procedure which fixes the language for use
11097 with insertion character ~~
11098 (Set_Msg_Text): treat insertion character ~~
11099 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
11100 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
11101 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
11102 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
11103 errors related to the formal language restriction not serious
11104 (insertion character |).
11105 * par.adb (Par): set formal language for error messages if needed
11106 * sem_ch6.adb (Check_Missing_Return): take into account possible
11107 generated statements at the end of the function
11108 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
11109 enumeration value to define a new pragma SPARK_95
11110 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
11111 SPARK_Version): new type and variables to store the SPARK version
11112 (none by default).
11113 (SPARK_Mode): return True when SPARK_Version is set
11114 * par-prag.adb: Correct indentation
11115 (Prag): take Pragma_SPARK_95 into account
11116 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
11117 into account.
11118
111192011-08-01 Robert Dewar <dewar@adacore.com>
11120
11121 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
11122 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
11123 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
11124
111252011-08-01 Pascal Obry <obry@adacore.com>
11126
11127 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
11128 Target_Name to Get_Path call.
11129 (Parse_Single_Project): Likewise.
11130 (Post_Parse_Context_Clause): Likewise.
11131 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
11132 Call Initialise_Project_Path with the proper Target_Name.
11133 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
11134 search path.
11135 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
11136 with the proper Target_Name.
11137 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
11138 Part.Parse routine.
11139 (Parse_Project_And_Apply_Config): Likewise.
11140 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
11141 This is fine as this part of the code is supporting only native
11142 compilation.
11143 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
11144 is fine as this part of the code is supporting only native compilation.
11145
111462011-08-01 Yannick Moy <moy@adacore.com>
11147
11148 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
11149 of homonym, unless the homonym is one of the cases allowed in SPARK
11150 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
11151 package declaration occurring after a body.
11152
111532011-08-01 Robert Dewar <dewar@adacore.com>
11154
11155 * checks.adb, exp_ch4.adb: Minor reformatting.
11156
111572011-08-01 Javier Miranda <miranda@adacore.com>
11158
11159 * einfo.ads (Access_Disp_Table): Fix documentation.
11160 (Dispatch_Table_Wrappers): Fix documentation.
11161
111622011-08-01 Pascal Obry <obry@adacore.com>
11163
11164 * prj-env.adb, prj-env.ads: Minor reformatting.
11165
111662011-08-01 Yannick Moy <moy@adacore.com>
11167
11168 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
11169 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
11170 procedures out of these packages.
2c7f9cc0 11171 * errout.ads, errout.adb
052e0603
AC
11172 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
11173 procedures in of this package
11174 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
11175 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
11176 on misplaced later vs initial declarations, like in Ada 83
11177 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
11178 formal mode on attribute of private type whose full type declaration
11179 is not visible
11180 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
11181 package declaration inside a package specification
11182 (Analyze_Full_Type_Declaration): issue error in formal mode on
11183 controlled type or discriminant type
11184 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
11185 user-defined operator means that it should come from the source
11186 (New_Overloaded_Entity): issue error in formal mode on overloaded
11187 entity.
11188 * sem_ch6.ads, sem_ch13.ads: typos in comments.
11189
111902011-08-01 Thomas Quinot <quinot@adacore.com>
11191
11192 * atree.adb: Minor reformatting.
11193 * checks.adb: Minor reformatting.
11194
111952011-08-01 Vincent Celier <celier@adacore.com>
11196
11197 * s-parame-vms-ia64.ads: Fix typo in comment
11198 Minor reformatting
11199 * s-parame-vms-restrict.ads: Removed, unused.
11200
112012011-08-01 Javier Miranda <miranda@adacore.com>
11202
11203 * exp_ch3.adb
11204 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
11205 * sem_ch3.adb
11206 (Constrain_Index): Remove side effects in the evaluation of the bounds.
11207 * sem_ch3.ads, sem_ch3.adb
11208 (Is_Constant_Bound): New extended version of the subprogram that was
11209 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
11210 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
11211 * sem_aux.ads (Constant_Value): Fix typo in comment.
11212 * checks.adb (Generate_Index_Checks): New implementation which, for
11213 array objects with constant bounds, generates the runtime check
11214 referencing the bounds of the array type. For other cases this routine
11215 provides its previous behavior obtaining such values from the array
11216 object.
11217 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
11218 parent type.
11219 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
11220 we cannot have semantic interpretations of the new node.
11221
112222011-08-01 Ed Schonberg <schonberg@adacore.com>
11223
11224 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
11225 expressions.
11226
112272011-08-01 Arnaud Charlet <charlet@adacore.com>
11228
11229 * sem_ch8.adb: Minor code editing.
11230 * s-vxwext.adb: Remove trailing space.
11231 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
11232 consistency with other files.
11233
112342011-08-01 Thomas Quinot <quinot@adacore.com>
11235
11236 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
11237
112382011-08-01 Ed Schonberg <schonberg@adacore.com>
11239
11240 * par-ch10.adb: reject parameterized expressions as compilation unit.
11241 * sem_ch4.adb: handle properly conditional expression with overloaded
11242 then_clause and no else_clause.
11243
112442011-08-01 Tristan Gingold <gingold@adacore.com>
11245
11246 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
11247 like done by System.Aux_DEC.
11248 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
11249
112502011-08-01 Yannick Moy <moy@adacore.com>
11251
11252 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
11253 missing label at end of declaration (subprogram or package)
11254 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
11255 of positional and named parameter association
11256 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
11257 Error_Msg_SP which adds a prefix to the error message giving the name
11258 of the formal language analyzed
11259 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
11260 access result type in subprogram, unconstrained array as result type,.
11261 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
11262 procedure
11263 * sem_ch8.adb: Code clean up.
11264
112652011-08-01 Javier Miranda <miranda@adacore.com>
11266
11267 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
11268 * einfo.ads (Access_Disp_Table): Fix documentation.
11269 (Dispatch_Table_Wrappers): Fix documentation.
11270 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
11271 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
11272 to enforce the documentation of this attribute.
11273 (Set_Is_Interface): Cleanup the assertion.
11274 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
11275 the Underlying_Type entity before reading attribute Access_Disp_Table.
11276 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
11277 Locate the Underlying_Type before reading attribute Access_Disp_Table.
11278 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
11279 the Underlying_Type entity before reading attribute Access_Disp_Table.
11280 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
11281 Locate the Underlying_Type entity before reading attribute
11282 Access_Disp_Table.
11283
112842011-08-01 Ed Schonberg <schonberg@adacore.com>
11285
11286 * s-poosiz.ads: Additional overriding indicators.
11287
112882011-08-01 Yannick Moy <moy@adacore.com>
11289
11290 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
11291 formal mode.
11292 (Analyze_Iteration_Scheme): issue error in formal mode when loop
11293 parameter specification does not include a subtype mark.
11294 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
11295 formal mode on abstract subprogram.
11296 (Analyze_Subprogram_Specification): issue error in formal mode on
11297 user-defined operator.
11298 (Process_Formals): issue error in formal mode on access parameter and
11299 default expression.
11300 * sem_ch9.adb (Analyze_Abort_Statement,
11301 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
11302 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
11303 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
11304 Analyze_Requeue, Analyze_Selective_Accept,
11305 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
11306 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
11307 issue error in formal mode on user-defined raise statement.
11308
113092011-08-01 Thomas Quinot <quinot@adacore.com>
11310
11311 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
11312 declaration being hidden when overriding an implicit inherited
11313 subprogram.
11314 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
11315 (-gnats), do not complain about a source file that contains only a
11316 pragma No_Body.
11317
113182011-08-01 Ed Schonberg <schonberg@adacore.com>
11319
11320 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
11321 variable if already set.
11322
113232011-08-01 Arnaud Charlet <charlet@adacore.com>
11324
11325 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
11326 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
11327 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
11328 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
11329 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
11330 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
11331 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
11332 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
11333 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
11334 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
11335 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
11336 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
11337 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
11338 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
11339 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
11340 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
11341 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
11342 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
11343 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
11344 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
11345 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
11346 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
11347 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
11348 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
11349 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
11350 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
11351 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
11352 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
11353 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
11354 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
11355 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
11356 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
11357 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
11358 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
11359 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
11360 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
11361 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
11362 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
11363 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
11364 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
11365 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
11366 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
11367 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
11368 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
11369 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
11370 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
11371 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
11372 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
11373 s-osinte-mingw.ads: Update to GPLv3 run-time license.
11374 Use GNAT instead of GNARL.
11375
113762011-08-01 Bob Duff <duff@adacore.com>
11377
11378 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
11379 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
11380 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
11381 reformatting.
11382
113832011-08-01 Yannick Moy <moy@adacore.com>
11384
11385 * debug.adb (d.D) reverve flag for the SPARK mode
11386 (d.E) reverve flag for SPARK generation mode
11387 (d.F) reverve flag for Why generation mode
2c7f9cc0 11388 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
052e0603
AC
11389 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
11390 functions which return True when the corresponding modes are set
11391 (Formal_Language): return "spark" or "alfa" when in formal verification
11392 mode.
11393 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
11394 Error_Msg to prefix the error message with a tag giving the formal
11395 language
11396 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
11397 message with a tag giving the formal language
11398 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
11399 block statement
11400 (Analyze_Case_Statement): issue error in formal mode on case statement
11401 with a single "others" case alternative
11402 (Analyze_Exit_Statement): issue errors in formal mode on exit
11403 statements which do not respect SPARK restrictions
11404 (Analyze_Goto_Statement): issue error in formal mode on goto statement
11405 (Check_Unreachable_Code): always issue an error (not a warning) in
11406 formal mode on unreachable code (concerns both code after an infinite
11407 loop and after an unconditional jump, both not allowed in SPARK)
11408 * sem_ch6.adb (Analyze_Return_Statement): add call to
11409 Set_Return_Present for a procedure containing a return statement
11410 (already done for functions in Analyze_Function_Return)
11411 (Analyze_Function_Return): issue error in formal mode on extended
11412 return or if return is not last statement in function
11413 (Check_Missing_Return): issue error in formal mode if function does
11414 not end with return or if procedure contains a return
11415 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
11416 function to detect if there is an inner scope of its parameter S which
11417 is a loop.
11418
114192011-08-01 Thomas Quinot <quinot@adacore.com>
11420
11421 * sem_ch6.ads: Minor reformatting.
11422
114232011-08-01 Javier Miranda <miranda@adacore.com>
11424
11425 * sem_util.adb (Abstract_Interface_List): Complete condition when
11426 processing private type declarations to avoid reading unavailable
11427 attribute.
11428 (Is_Synchronized_Tagged_Type): Complete condition when processing
11429 private extension declaration nodes to avoid reading unavailable
11430 attribute.
11431
114322011-08-01 Thomas Quinot <quinot@adacore.com>
11433
11434 * sem_ch3.adb: Minor reformatting.
11435
114362011-08-01 Thomas Quinot <quinot@adacore.com>
11437
11438 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
11439 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
11440 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
11441 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
11442 for VMS, instead parametrize the common implementation with
11443 System.Parameters declarations.
11444
114452011-08-01 Eric Botcazou <ebotcazou@adacore.com>
11446
11447 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
11448
114492011-08-01 Tristan Gingold <gingold@adacore.com>
11450
11451 * seh_init.c: Fix SEH handler installation on win64.
11452
114532011-08-01 Ed Schonberg <schonberg@adacore.com>
11454
11455 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
11456 double analysis of an anonymous access to subprogram, because it can
11457 lead to improper sharing of profiles and a back-end crash.
11458
114592011-08-01 Robert Dewar <dewar@adacore.com>
11460
11461 * make.adb, sem_ch4.adb: Minor reformatting.
11462 * gcc-interface/Make-lang.in: Update dependencies.
11463 * sem_util.adb, exp_ch5.adb: Minor reformatting.
11464
114652011-08-01 Arnaud Charlet <charlet@adacore.com>
11466
11467 * gnat_rm.texi: Fix definition of Long_Integer.
11468
114692011-08-01 Ed Schonberg <schonberg@adacore.com>
11470
11471 * exp_aggr.adb: check limit size of static aggregate unconditionally,
11472 to prevent storage exhaustion.
11473 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
11474 finalized is a function body, insert the cleanup code before the final
11475 return statement, to prevent spurious warnings.
11476 * s-pooglo.ads: add overriding indicator.
11477
114782011-08-01 Ed Schonberg <schonberg@adacore.com>
11479
11480 * sem_ch4.adb (Operator_Check): improve error message when both a
11481 with_clause and a use_clause are needed to make operator usage legal.
11482 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
11483 determine whether a compilation unit is visible within an other,
11484 either through a with_clause in the current unit, or a with_clause in
11485 its library unit or one one of its parents.
11486
114872011-08-01 Ed Schonberg <schonberg@adacore.com>
11488
11489 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
11490 over an arbitrary expression of an array or container type.
11491 * lib-xref.adb: clarify comment.
11492
114932011-08-01 Bob Duff <duff@adacore.com>
11494
11495 * einfo.ads: Minor reformatting.
11496 * debug.adb: Minor comment improvement.
11497
114982011-08-01 Javier Miranda <miranda@adacore.com>
11499
11500 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
11501 consider hidden subprograms as valid candidates.
11502
115032011-08-01 Arnaud Charlet <charlet@adacore.com>
11504
11505 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
11506
115072011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
11508
11509 * gnat_ugn.texi: Fix typo.
11510
115112011-08-01 Robert Dewar <dewar@adacore.com>
11512
11513 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
11514 lib-xref.adb: Minor reformatting
11515
115162011-08-01 Gary Dismukes <dismukes@adacore.com>
11517
11518 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
11519 when to generate a call to Move_Final_List.
11520 (Has_Controlled_Parts): Remove this function.
11521
115222011-08-01 Geert Bosch <bosch@adacore.com>
11523
11524 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
11525 "," in choice list.
11526
115272011-08-01 Thomas Quinot <quinot@adacore.com>
11528
11529 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
11530 explicit raise of a predefined exception as Comes_From_Source if the
11531 original N_Raise_Statement comes from source.
11532
115332011-08-01 Robert Dewar <dewar@adacore.com>
11534
11535 * sinfo.ads: Add comment.
11536 * sem_ch6.adb: Minor reformatting.
11537
115382011-08-01 Robert Dewar <dewar@adacore.com>
11539
11540 * freeze.adb (Freeze_Entity): Refine check for bad component size
11541 clause to avoid rejecting confirming clause when atomic/aliased present.
11542
115432011-08-01 Ed Schonberg <schonberg@adacore.com>
11544
11545 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
11546 better determine whether an entity reference is a write.
11547 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
11548 subcomponent.
11549 * lib-xref.adb (Output_References): Do no suppress a read reference at
11550 the same location as an immediately preceeding modify-reference, to
11551 handle properly in-out actuals.
11552
115532011-08-01 Tristan Gingold <gingold@adacore.com>
11554
11555 * env.c (__gnat_setenv) [VMS]: Refine previous change.
11556
115572011-08-01 Quentin Ochem <ochem@adacore.com>
11558
11559 * i-cstrin.adb (New_String): Changed implementation, now uses only the
11560 heap to compute the result.
11561
115622011-08-01 Robert Dewar <dewar@adacore.com>
11563
11564 * atree.ads: Minor reformatting.
11565
115662011-08-01 Emmanuel Briot <briot@adacore.com>
11567
11568 * g-expect.adb (Get_Command_Output): Fix memory leak.
11569
115702011-08-01 Geert Bosch <bosch@adacore.com>
11571
11572 * cstand.adb (P_Float_Type): New procedure to print the definition of
11573 predefined fpt types.
11574 (P_Mixed_Name): New procedure to print a name using mixed case
11575 (Print_Standard): Use P_Float_Type for printing floating point types
11576 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
11577 precision IEEE float.
11578
115792011-08-01 Thomas Quinot <quinot@adacore.com>
11580
11581 * sem_ch3.adb: Minor reformatting.
11582
115832011-08-01 Ed Schonberg <schonberg@adacore.com>
11584
11585 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
11586 the completion of a generic function, insert the new body rather than
11587 rewriting the original.
11588
115892011-08-01 Yannick Moy <moy@adacore.com>
11590
11591 * sinfo.ads, errout.ads: Typos in comments.
11592
115932011-08-01 Robert Dewar <dewar@adacore.com>
11594
11595 * par-endh.adb: Minor reformatting.
11596
115972011-08-01 Robert Dewar <dewar@adacore.com>
11598
11599 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
11600 (Pre_Post_Aspects): New subtype.
11601 * par-ch12.adb (P_Generic): New syntax for aspects in packages
11602 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
11603 * par-ch7.adb (P_Package): Remove Decl parameter
11604 (P_Package): Handle new syntax for aspects (before IS)
11605 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
11606 new aspect syntax
11607 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
11608 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
11609 (P_Package): Remove Decl parameter
11610 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
11611 aspects
11612 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
11613 specs
11614 * sem_util.ads, sem_util.adb (Static_Boolean): New function
11615 * sinfo.ads: Document new syntax for aspects in packages etc.
11616 * sprint.adb: Handle new syntax of aspects before IS in package
11617
116182011-08-01 Thomas Quinot <quinot@adacore.com>
11619
11620 * atree.ads: Minor reformatting.
11621 * sem_prag.adb: Minor reformatting.
11622
116232011-08-01 Robert Dewar <dewar@adacore.com>
11624
11625 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
11626 case expr alternative.
11627
116282011-08-01 Ed Schonberg <schonberg@adacore.com>
11629
11630 * sem_ch12.adb: Fix typo.
11631
116322011-08-01 Geert Bosch <bosch@adacore.com>
11633
11634 * sem_prag.adb (Check_No_Link_Name): New procedure.
11635 (Process_Import_Or_Interface): Use Check_No_Link_Name.
11636 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
11637 instead of Standard_Long_Long_Float_Size global. Preparation for
11638 eventual removal of per type constants.
11639 * exp_util.ads (Get_Stream_Size): New function returning the stream
11640 size value of subtype E.
11641 * exp_util.adb (Get_Stream_Size): Implement new function.
11642 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
11643 function.
11644 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
11645 * einfo.adb:
11646 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
11647
116482011-08-01 Geert Bosch <bosch@adacore.com>
11649
11650 * cstand.adb: Fix comments.
11651 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
11652 count of arguments.
11653
116542011-08-01 Robert Dewar <dewar@adacore.com>
11655
11656 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
11657
116582011-08-01 Geert Bosch <bosch@adacore.com>
11659
11660 * atree.ads: Fix comment.
11661
116622011-08-01 Robert Dewar <dewar@adacore.com>
11663
11664 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
11665 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
11666 * par.adb: Add with for Namet.Sp.
11667 * par-tchk.adb: Minor reformatting.
11668
116692011-08-01 Vincent Celier <celier@adacore.com>
11670
11671 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
11672 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
11673 of the init procedure of a SAL.
11674 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
11675 New procedure.
11676
116772011-08-01 Thomas Quinot <quinot@adacore.com>
11678
11679 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
11680 reformatting.
11681
116822011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
11683
11684 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
11685
116862011-08-01 Thomas Quinot <quinot@adacore.com>
11687
11688 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
11689 conformant with its spec (return True only for types that have
11690 an overriding Initialize primitive operation that prevents them from
11691 having preelaborable initialization).
11692 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
11693 initialization for controlled types in Ada 2005 or later mode.
11694
116952011-08-01 Robert Dewar <dewar@adacore.com>
11696
11697 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
11698 Postcondition.
11699 (Same_Aspect): New function.
11700 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
11701 Type_Invariant, Precondition, Postcondition.
11702 * snames.ads-tmpl: Add Name_Type_Invariant.
11703
117042011-08-01 Robert Dewar <dewar@adacore.com>
11705
11706 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
11707 here.
11708 (Freeze_All_Ent): Fix error in handling inherited aspects.
11709 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
11710 already analyzed, but don't skip entire processing of a declaration,
11711 that's wrong in some cases of declarations being rewritten.
11712 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
11713 Don't delay for integer, string literals
11714 Treat predicates in usual manner for delay, remove special case code,
11715 not needed.
11716 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
11717 (Build_Predicate_Function): Update saved expression in aspect
11718 (Build_Invariant_Procedure): Update saved expression in aspect
11719 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
11720 of replacement of discriminant references if the reference is simple.
11721
117222011-08-01 Robert Dewar <dewar@adacore.com>
11723
11724 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
11725 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
11726 Static_Predicate and Dynamic_Predicate.
11727 (Build_Predicate_Function): Add processing for Static_Predicate
11728 and Dynamic_Predicate.
11729 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
11730 (From_Static_Predicate): New flag
11731 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
11732
117332011-08-01 Robert Dewar <dewar@adacore.com>
11734
11735 * usage.adb: Documentation cleanup for Ada version modes in usage.
11736 * expander.adb: Minor reformatting.
11737
117382011-08-01 Robert Dewar <dewar@adacore.com>
11739
11740 * atree.ads: Minor comment fix.
11741 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
11742 a-witeio.ads, sem_prag.adb: Minor reformatting.
11743
117442011-08-01 Doug Rupp <rupp@adacore.com>
11745
11746 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
11747 pointers. Use descrip.h header file for convenience. Add some
11748 comments.
11749
117502011-08-01 Robert Dewar <dewar@adacore.com>
11751
11752 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
11753 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
11754 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
11755 New procedure.
11756 (Check_Aspect_At_End_Of_Declarations): New procedure
11757 (Analye_Aspect_Specification): Minor changes for above procedures
11758 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
11759 specification node as well.
11760
117612011-08-01 Pascal Obry <obry@adacore.com>
11762
11763 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
11764 Windows files. Use GetFilesAttributes() in this case to check for file
11765 existence instead of returning with an error code.
11766
117672011-08-01 Vincent Celier <celier@adacore.com>
11768
11769 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
11770 High is above Source length.
11771
117722011-08-01 Robert Dewar <dewar@adacore.com>
11773
11774 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
11775
117762011-08-01 Robert Dewar <dewar@adacore.com>
11777
11778 * aspects.ads (Boolean_Aspects): New subtype.
11779 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
11780 for derived types in cases where the parent type and derived type have
11781 aspects.
11782 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
11783 with aspects when parent type also has aspects.
11784 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
11785 boolean expression at this point).
11786 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
11787 accordance with final decision on the Ada 2012 feature.
11788 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
11789
117902011-08-01 Matthew Heaney <heaney@adacore.com>
11791
11792 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
11793
117942011-08-01 Pascal Obry <obry@adacore.com>
11795
11796 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
11797 Fix Replace_Slice when High is above current string size.
11798 (Replace_Slice): Fix DL computation when High is above current
11799 string length.
11800
118012011-08-01 Gary Dismukes <dismukes@adacore.com>
11802
11803 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
11804
118052011-08-01 Matthew Heaney <heaney@adacore.com>
11806
11807 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
11808 of node.
11809
118102011-08-01 Pascal Obry <obry@adacore.com>
11811
11812 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
11813 reformatting.
11814
118152011-08-01 Ed Schonberg <schonberg@adacore.com>
11816
11817 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
11818 access to protected subprograms in generic bodies.
11819 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
11820 protected type, indicate that the convention of the subprogram is
11821 Convention_Protected, because it may be used in subsequent declarations
11822 within the protected declaration.
11823
118242011-08-01 Vincent Celier <celier@adacore.com>
11825
11826 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
11827 and "final" procedures when the name of the library is "ada", to avoid
11828 duplicate symbols "adainit" and "adafinal" in executables.
11829
118302011-08-01 Ed Schonberg <schonberg@adacore.com>
11831
11832 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
11833 quantified expression that appears within a postcondition and uses the
11834 Ada2012 'Result attribute.
11835
118362011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11837
11838 * init.c (__gnat_error_handler): Cast reason to int.
11839 (__gnat_install_handler): Explain sa_sigaction use.
11840
118412011-07-24 Eric Botcazou <ebotcazou@adacore.com>
11842
11843 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
11844 subprogram has copy-in copy-out parameters, try to promote the mode of
11845 the return type if it is passed in registers.
11846
118472011-07-24 Eric Botcazou <ebotcazou@adacore.com>
11848
11849 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
11850 left operand as addressable.
11851
118522011-07-24 Eric Botcazou <ebotcazou@adacore.com>
11853
11854 * gcc-interface/gigi.h (build_function_stub): Remove.
11855 (build_return_expr): Likewise.
11856 (convert_vms_descriptor): Declare.
11857 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
11858 (build_function_stub): Move to...
11859 * gcc-interface/utils2.c (build_return_expr): Move to...
11860 * gcc-interface/trans.c (build_function_stub): ...here.
11861 (build_return_expr): ...here.
11862 (Subprogram_Body_to_gnu): Add local variable for language_function.
11863 Disconnect the parameter attributes cache, if any, once done with it.
11864 Call end_subprog_body only after setting the end_locus.
11865 Build the stub associated with the function, if any, at the very end.
11866 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
11867 variables and streamline control flow.
11868
118692011-07-23 Arnaud Charlet <charlet@adacore.com>
11870
11871 PR ada/49819
11872 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
11873 g-trasym-dwarf.adb.
11874
118752011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11876
11877 PR bootstrap/49794
11878 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
11879 Assign to act.sa_sigaction.
11880 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
11881 current->return_address to char * before arithmetic.
11882
118832011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11884
11885 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
11886 Correct argument types.
11887 Extract code from reason.
11888 (__gnat_install_handler): Assign to act.sa_sigaction.
11889
118902011-07-21 Eric Botcazou <ebotcazou@adacore.com>
11891
11892 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
11893 (GNAT1_OBJS): ...here.
11894
118952011-07-15 Eric Botcazou <ebotcazou@adacore.com>
11896
11897 PR ada/48711
11898 * g-socthi-mingw.adb (Fill): Fix formatting.
11899
11900 * gcc-interface/gigi.h: Move around comment.
11901
119022011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
11903
11904 PR ada/46350
11905 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
11906
119072011-07-14 Florian Weimer <fw@deneb.enyo.de>
11908
11909 PR ada/48711
11910 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
11911
119122011-07-13 Eric Botcazou <ebotcazou@adacore.com>
11913
11914 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
11915 range comparison if Pmode is SImode.
11916
119172011-07-12 Laurent GUERBY <laurent@guerby.net>
11918 Eric Botcazou <ebotcazou@adacore.com>
11919
11920 * adadecode.c: Wrap up in extern "C" block.
11921 * adadecode.h: Likewise.
11922 * adaint.c: Likewise. Remove 'const' keyword.
11923 * adaint.h: Likewise.
11924 * argv.c: Likewise.
11925 * atree.h: Likewise.
11926 * cio.c: Likewise.
11927 * cstreams.c: Likewise.
11928 * env.c: Likewise.
11929 * exit.c: Likewise.
11930 * fe.h: Likewise.
11931 * final.c: Likewise.
11932 * init.c: Likewise.
11933 * initialize.c: Likewise.
11934 * link.c: Likewise.
11935 * namet.h: Likewise.
11936 * nlists.h: Likewise.
11937 * raise.c: Likewise.
11938 * raise.h: Likewise.
11939 * repinfo.h: Likewise.
11940 * seh_init.c: Likewise.
11941 * targext.c: Likewise.
11942 * tracebak.c: Likewise.
11943 * uintp.h: Likewise.
11944 * urealp.h: Likewise.
11945 * xeinfo.adb: Wrap up generated C code in extern "C" block.
11946 * xsinfo.adb: Likewise.
11947 * xsnamest.adb: Likewise.
11948 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
11949 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
11950 * gcc-interface/misc.c: Likewise.
11951 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
11952 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
11953 ada/targext.o here...
11954 (GNAT_ADA_OBJS): ...and not here.
11955 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
11956 (GNATBIND_OBJS): Reorder.
11957
119582011-07-07 Richard Henderson <rth@redhat.com>
11959
11960 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
11961 dwarf2out_frame_init.
11962
119632011-07-07 Eric Botcazou <ebotcazou@adacore.com>
11964
11965 * gcc-interface/misc.c (gnat_init): Tweak previous change.
11966
119672011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11968
11969 PR target/39150
11970 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
11971
119722011-07-06 Richard Guenther <rguenther@suse.de>
11973
11974 * gcc-interface/misc.c (gnat_init): Merge calls to
11975 build_common_tree_nodes and build_common_tree_nodes_2.
11976 Re-initialize boolean_false_node.
11977
119782011-07-02 Eric Botcazou <ebotcazou@adacore.com>
11979 Olivier Hainque <hainque@adacore.com>
11980 Nicolas Setton <setton@adacore.com>
11981
11982 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
11983 the type according to the ARTIFICIAL_P parameter.
11984 (create_type_decl): Likewise.
11985 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
11986
119872011-07-01 Eric Botcazou <ebotcazou@adacore.com>
11988
11989 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
11990 (gnatbind): Likewise.
11991
119922011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11993
11994 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
11995
119962011-06-18 Eric Botcazou <ebotcazou@adacore.com>
11997
11998 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
11999 local variable throughout. Remove useless call to Base_Type.
12000 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
12001 Take it also into account for the volatileness of the field. Set the
12002 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
12003
120042011-06-18 Eric Botcazou <ebotcazou@adacore.com>
12005
12006 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
12007 on a dereference built for a by-ref object if it has an address clause.
12008
120092011-06-18 Eric Botcazou <ebotcazou@adacore.com>
12010
12011 * einfo.ads (Address_Taken): Document use for the second argument of
12012 Asm_Input and Asm_Output attributes.
12013 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
12014 argument is an entity name, then set Address_Taken on it.
12015 <Attribute_Asm_Output>: Likewise.
12016 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
12017 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
12018 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
12019 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
12020
120212011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
12022
12023 PR middle-end/46500
12024 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
12025
120262011-06-14 Joseph Myers <joseph@codesourcery.com>
12027
12028 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
12029 (ada/utils.o): Update dependencies.
12030 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
12031 ../../../libcpp/libcpp.a.
12032 * gcc-interface/utils.c: Include common/common-target.h.
12033 (process_attributes): Use targetm_common.have_named_sections.
12034
120352011-06-07 Richard Guenther <rguenther@suse.de>
12036
12037 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
12038 set_sizetype.
12039
120402011-06-06 Eric Botcazou <ebotcazou@adacore.com>
12041
12042 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
12043 TREE_THIS_NOTRAP flag.
12044
120452011-06-06 Eric Botcazou <ebotcazou@adacore.com>
12046
12047 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
12048 Fix thinko.
12049
120502011-06-06 Eric Botcazou <ebotcazou@adacore.com>
12051
12052 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
12053 constants whose full view has discriminants specially.
12054
120552011-06-06 Eric Botcazou <ebotcazou@adacore.com>
12056
12057 * gcc-interface/utils.c: Include diagnostic.h.
12058 (gnat_write_global_declarations): Output debug information for all
12059 global type declarations before finalizing the compilation unit.
12060 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
12061
120622011-05-25 Jakub Jelinek <jakub@redhat.com>
12063
12064 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
12065
120662011-05-25 Kai Tietz <ktietz@redhat.com>
12067
12068 * adaint.c (__gnat_to_canonical_file_list_next): Use array
12069 initialization instead of const/none-const pointer assignment.
12070
120712011-05-24 Joseph Myers <joseph@codesourcery.com>
12072
12073 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
12074 $(EXTRA_GNAT1_OBJS).
12075 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
12076 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
12077 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
12078 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
12079 libcommon-target.a instead of prefix.o.
12080
120812011-05-21 Joseph Myers <joseph@codesourcery.com>
12082
12083 PR ada/49097
12084 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
12085
120862011-05-20 Joseph Myers <joseph@codesourcery.com>
12087
12088 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
12089 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
12090 instead of version.o.
12091
2d0dd51a 120922011-05-18 Kai Tietz <ktietz@redhat.com>
052e0603
AC
12093
12094 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
12095 boolean_false_node instead of integer_zero_node.
12096 (convert_with_check): Likewise.
12097 * gcc-interface/decl.c (choices_to_gnu): Likewise.
12098
120992011-05-12 Eric Botcazou <ebotcazou@adacore.com>
12100
12101 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
12102 type of the parameter is an unconstrained array, convert the actual to
12103 the type of the formal in the In Out and Out cases as well.
12104
121052011-05-11 Nathan Froyd <froydnj@codesourcery.com>
12106
12107 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
12108 call build_function_type_array or build_varargs_function_type_array
12109 instead.
12110 (create_subprog_type): Don't call build_function_type; call
12111 build_function_type_vec instead.
12112
121132011-05-11 Nathan Froyd <froydnj@codesourcery.com>
12114
12115 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
12116 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
12117 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
12118
121192011-05-07 Eric Botcazou <ebotcazou@adacore.com>
12120
12121 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
12122
12123 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
12124 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
12125
121262011-05-05 Nathan Froyd <froydnj@codesourcery.com>
12127
12128 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
12129
121302011-05-05 Nathan Froyd <froydnj@codesourcery.com>
12131
12132 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
12133 instead of accessing TYPE_ARG_TYPES directly.
12134 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
12135
121362011-05-05 Eric Botcazou <ebotcazou@adacore.com>
12137
12138 PR ada/48844
12139 * gcc-interface/gigi.h (get_variant_part): Declare.
12140 * gcc-interface/decl.c (get_variant_part): Make global.
12141 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
12142 types have the same constant size, are record types and T1 has a
12143 variant part while T2 doesn't.
12144
121452011-05-05 Eric Botcazou <ebotcazou@adacore.com>
12146
12147 * gcc-interface/utils.c (begin_subprog_body): Do not call
12148 get_pending_sizes.
12149 (end_subprog_body): Likewise.
12150
121512011-05-04 Richard Guenther <rguenther@suse.de>
12152
12153 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
12154 int_const_binop.
12155 (pos_to_constructor): Likewise.
12156
121572011-05-03 Nathan Froyd <froydnj@codesourcery.com>
2c7f9cc0 12158 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
12159
12160 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
12161 of build_function_type. Adjust calls to...
12162 (build_raise_check): ...this. Do not take a void_tree parameter.
12163 Call build_function_type_list instead of build_function_type.
12164 Fix head comment and swap couple of conditional blocks.
12165
121662011-04-30 Eric Botcazou <ebotcazou@adacore.com>
12167
12168 * gnatvsn.ads (Library_Version): Bump to 4.7.
12169 (Current_Year): Bump to 2011.
12170
121712011-04-29 Michael Matz <matz@suse.de>
12172
12173 * gcc-interface/misc.c (gnat_handle_option): Set
12174 warn_maybe_uninitialized.
12175
121762011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
12177
12178 * gnat_ugn.texi (Complexity Metrics Control): Update link to
12179 the Watson/McCabe paper.
12180
121812011-04-23 Jim Meyering <meyering@redhat.com>
12182
12183 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
12184
121852011-04-22 Eric Botcazou <ebotcazou@adacore.com>
12186
12187 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
12188 onto the new type.
12189
121902011-04-22 Eric Botcazou <ebotcazou@adacore.com>
12191
12192 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
12193 parameter.
12194 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
12195 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
12196 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
12197 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
12198 <all>: Do not set flags on the reused DECL node coming from an alias.
12199 Set DECL_IGNORED_P on the DECL node built for subprograms if they
12200 don't need debug info here...
12201 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
12202 (gigi): Adjust calls to create_subprog_decl.
12203 (build_raise_check): Likewise.
12204 (establish_gnat_vms_condition_handler): Likewise.
12205 (Compilation_Unit_to_gnu): Likewise.
12206 (gnat_to_gnu): Likewise.
12207
122082011-04-21 Eric Botcazou <ebotcazou@adacore.com>
12209
12210 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
12211 (NO_REORDER_ADAFLAGS): New variable.
12212 (EXTRA_GNATTOOLS): Always define.
12213 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
12214 Clean up and adjust list of files compiled with special options.
12215 * gcc-interface/Make-lang.in: Likewise.
12216 (ada/decl.o): Cosmetical change.
12217 (ada/misc.o): Remove dependency on $(PLUGIN_H).
12218
122192011-04-20 Jim Meyering <meyering@redhat.com>
12220
12221 * initialize.c (__gnat_initialize): Remove useless if-before-free.
12222
122232011-04-17 Eric Botcazou <ebotcazou@adacore.com>
12224
12225 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
12226 $(CFLAGS) on the link line.
12227
122282011-04-17 Eric Botcazou <ebotcazou@adacore.com>
12229
12230 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
12231 padded type built for the return type if it is unconstrained.
12232
122332011-04-14 Nathan Froyd <froydnj@codesourcery.com>
12234
12235 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
12236
122372011-04-12 Nathan Froyd <froydnj@codesourcery.com>
12238
12239 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
12240 before calling TREE_CHAIN.
12241 * gcc-interface/misc.c (gnat_init_ts): New function.
12242 (LANG_HOOKS_INIT_TS): Define.
12243
122442011-04-12 Martin Jambor <mjambor@suse.cz>
12245
12246 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
12247 instead of cgraph_node.
12248
122492011-04-08 Eric Botcazou <ebotcazou@adacore.com>
12250
12251 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
12252 alignment on fields of the RETURN type built for the Copy-In Copy-Out
12253 mechanism.
12254
122552011-04-08 Eric Botcazou <ebotcazou@adacore.com>
12256
12257 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
12258 of aggregate types that contain a placeholder.
12259
122602011-04-08 Nathan Froyd <froydnj@codesourcery.com>
12261
12262 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
12263 TYPE_ARG_TYPES.
12264 (handle_type_generic_attribute): Likewise.
12265
122662011-04-04 Eric Botcazou <ebotcazou@adacore.com>
12267
12268 PR ada/47163
12269 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
12270
122712011-04-04 Kai Tietz <ktietz@redhat.com>
12272
12273 PR ada/47163
12274 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
12275 to flag value.
12276
122772011-04-02 Eric Botcazou <ebotcazou@adacore.com>
12278
12279 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
12280 type case, do not strip a padding type around the array type.
12281
122822011-04-02 Eric Botcazou <ebotcazou@adacore.com>
12283
12284 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
12285 types.
12286
122872011-04-02 Eric Botcazou <ebotcazou@adacore.com>
12288
12289 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
12290 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
12291 code for -feliminate-unused-debug-types.
12292 (gnat_post_options): Likewise.
12293
122942011-04-02 Eric Botcazou <ebotcazou@adacore.com>
12295
12296 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
12297 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
12298 distinct copy.
12299
123002011-04-02 Eric Botcazou <ebotcazou@adacore.com>
12301
12302 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
12303 DECL_ARTIFICIAL flag on enumeration types.
12304
123052011-04-02 Eric Botcazou <ebotcazou@adacore.com>
12306
12307 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
12308 fat pointer types artificial unconditionally.
12309 <E_Array_Subtype>: Attach the base array type as a parallel type if it
12310 isn't artificial.
12311
123122011-04-02 Eric Botcazou <ebotcazou@adacore.com>
12313
12314 * gcc-interface/gigi.h (get_dummy_type): Declare.
12315 (build_dummy_unc_pointer_types): Likewise.
12316 (finish_fat_pointer_type): Likewise.
12317 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
12318 fat pointer type has been built, complete it in place.
12319 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
12320 and thin pointers. Remove useless variable.
12321 (finish_fat_pointer_type): Make global and move to...
12322 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
12323 (get_dummy_type): New function.
12324 (build_dummy_unc_pointer_types): Likewise.
12325 (gnat_pushdecl): Propage the name to the anonymous variants only.
12326 (update_pointer_to): Only adjust the pointer types in the unconstrained
12327 array case.
12328
123292011-04-02 Eric Botcazou <ebotcazou@adacore.com>
12330
12331 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
12332 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
12333 if this is a Taft amendment type and the full declaration is available.
12334 * gcc-interface/trans.c (process_type): Likewise.
12335 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
12336 (process_freeze_entity): Likewise.
12337 * gcc-interface/utils.c (dummy_global): New static variable.
12338 (gnat_write_global_declarations): If there are types declared as used
12339 at the global level, insert them in the global hash table.
12340
123412011-04-02 Eric Botcazou <ebotcazou@adacore.com>
12342
12343 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
12344 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
12345 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
12346 copy.
12347 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
12348 flag of the type accordingly.
12349 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
12350
123512011-04-02 Eric Botcazou <ebotcazou@adacore.com>
12352
12353 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
12354 finalizing types when updating the pointers to the designated type.
12355 <all>: Finalize the deferred types even if we didn't defer processing
12356 of incomplete types in this invocation.
12357
123582011-04-01 Olivier Hainque <hainque@adacore.com>
2c7f9cc0
AS
12359 Nicolas Setton <setton@adacore.com>
12360 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
12361
12362 * gcc-interface/misc.c (gnat_descriptive_type): New function.
12363 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
12364
123652011-03-28 Kai Tietz <ktietz@redhat.com>
12366
12367 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
12368 Windows targets.
12369 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
12370 * system-mingw.ads (System): Change ZCX_By_Default default to True.
12371
12372 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
12373
123742011-03-28 Tristan Gingold <gingold@adacore.com>
12375
12376 PR ada/44431
12377 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
12378 Use ada output of gnatbind.
12379 (ada/b_gnatb.adb): Ditto.
12380 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
12381 (ada.mostlyclean, ada.stage1)
12382 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
12383 (ada.stagefeedback): Adjust.
12384 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
12385 Use ada output of gnatbind.
12386 (b_gnatm.adb): Ditto.
12387 (b_gnatl.o, b_gnatm.o): New rules.
12388
123892011-03-26 Eric Botcazou <ebotcazou@adacore.com>
12390
12391 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
12392 for the padded type built to support a specified size or alignment.
12393
123942011-03-26 Eric Botcazou <ebotcazou@adacore.com>
12395
12396 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
12397 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
12398 unconditionally to the end of the unit when the designated type is
12399 limited_with'ed.
12400 <all>: Rename local variable. Attempt to un-defer types only and do it
12401 for limited_with'ed types as well.
12402 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
12403 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
12404 consistently and remove redundant call to finalize_from_with_types.
12405
124062011-03-26 Eric Botcazou <ebotcazou@adacore.com>
12407
12408 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
12409 subprograms without a previous spec declared in the same unit.
12410 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
12411 subprograms at the end of the unit instead of at the beginning.
12412 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
12413 isn't public for the special handling of non-inline functions nested
12414 inside inline external functions.
12415
124162011-03-25 Jeff Law <law@redhat.com>
12417
12418 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
12419
124202011-03-24 Eric Botcazou <ebotcazou@adacore.com>
12421
12422 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
12423 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
12424 to compute Set_Size_Depends_On_Discriminant.
12425 (Layout_Type): Call it on array types in back-end layout mode.
12426 * sem_util.adb (Requires_Transient_Scope): Return true for array
12427 types only if the size depends on the value of discriminants.
12428 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
12429 type if the RHS is a call to a function that returns an unconstrained
12430 type with default discriminant.
12431
124322011-03-24 Eric Botcazou <ebotcazou@adacore.com>
12433
12434 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
12435 non-conversion to the nominal result type at the end.
12436
124372011-03-23 Eric Botcazou <ebotcazou@adacore.com>
12438
12439 * gcc-interface/trans.c (create_temporary): New function taken from...
12440 (create_init_temporary): ...here. Call it.
12441 (call_to_gnu): Create the temporary for the return value early, if any.
12442 Create it for a function with copy-in/copy-out parameters if there is
12443 no target; in other cases of copy-in/copy-out, use another temporary.
12444 Push the new binding level lazily. Add and rename local variables.
12445
124462011-03-23 Eric Botcazou <ebotcazou@adacore.com>
12447
12448 * gcc-interface/decl.c (validate_size): Improve comments and tweak
12449 error message.
12450 (set_rm_size): Likewise.
12451
124522011-03-23 Eric Botcazou <ebotcazou@adacore.com>
12453
12454 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
12455 for the padded type built in order to support a specified alignment.
12456 Fix incorrect formatting.
12457
124582011-03-21 Eric Botcazou <ebotcazou@adacore.com>
12459
12460 PR bootstrap/48216
12461 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
12462
124632011-03-21 Eric Botcazou <ebotcazou@adacore.com>
12464
12465 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
12466 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
12467 to the end of the list. Adjust recursive call. Rename local variable.
12468 If REORDER is true, reorder components of the record type.
12469 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
12470 components_to_record and adjust the parameter list.
12471
124722011-03-21 Eric Botcazou <ebotcazou@adacore.com>
12473
12474 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
12475 disabled, use the variable for bounds of loop iteration scheme.
12476
124772011-03-21 Kai Tietz <ktietz@redhat.com>
12478
12479 PR target/12171
12480 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
12481
124822011-03-17 Eric Botcazou <ebotcazou@adacore.com>
12483
12484 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
12485 out whether the expression is read-only. Short-circuit placeholder
12486 case and rename a couple of local variables.
12487
124882011-03-17 Eric Botcazou <ebotcazou@adacore.com>
12489
12490 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
12491 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
12492 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
12493 (convert): Deal with conversions from a smaller form type specially.
12494
124952011-02-14 Eric Botcazou <ebotcazou@adacore.com>
12496
12497 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
12498 its argument, except for the special -I- switch.
12499
125002011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
12501
12502 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
12503 "Ada Issues".
12504
125052011-02-08 Eric Botcazou <ebotcazou@adacore.com>
12506
12507 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
12508
125092011-02-03 Eric Botcazou <ebotcazou@adacore.com>
12510
12511 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
12512 GNAT_FORMAL.
12513 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
12514 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
12515 instead of GNAT_FORMAL. Protect the expression against multiple uses.
12516 Do not generate the check directly, instead instantiate the template
12517 check present in the descriptor.
12518 (make_descriptor_field): Move around.
12519 (build_vms_descriptor32): Build a template check in the POINTER field.
12520 (build_vms_descriptor): Remove useless suffixes.
12521 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
12522
125232011-01-26 Eric Botcazou <ebotcazou@adacore.com>
12524
12525 PR bootstrap/47467
12526 * targext.c: Include target files if IN_RTS is defined.
12527
125282011-01-26 Richard Guenther <rguenther@suse.de>
12529
12530 PR bootstrap/47467
12531 * targext.c: Include config.h.
12532 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
12533 dependency.
12534
125352011-01-04 Pascal Obry <obry@adacore.com>
2c7f9cc0 12536 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
12537
12538 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
12539
125402011-01-04 Eric Botcazou <ebotcazou@adacore.com>
12541
12542 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
12543 end-of-case on the end label and its associated gotos, if any.
12544
125452011-01-04 Eric Botcazou <ebotcazou@adacore.com>
12546
12547 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
12548 expressions of the parameter cache within the statement group of
12549 the CICO mechanism.
12550
125512011-01-04 Olivier Hainque <hainque@adacore.com>
2c7f9cc0 12552 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
12553
12554 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
12555 (set_end_locus_from_node): New function.
12556 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
12557 make and the function end_locus.
12558 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
12559 for the elaboration subprogram.
12560 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
12561 set the end_locus of the expression as well.
12562
125632011-01-04 Eric Botcazou <ebotcazou@adacore.com>
12564
12565 PR ada/47131
12566 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
12567 variables that are referenced in exception handlers volatile.
12568
12569
12570\f
12571Copyright (C) 2011 Free Software Foundation, Inc.
12572
12573Copying and distribution of this file, with or without modification,
12574are permitted in any medium without royalty provided the copyright
12575notice and this notice are preserved.
12576
12577 * gnat_rm.texi: Ramification of pragma Eliminate documentation
12578 - fix bugs in the description of Source_Trace;
12579 - get rid of UNIT_NAME;
12580
4fbad0ba
AC
125812011-08-02 Javier Miranda <miranda@adacore.com>
12582
12583 * exp_ch9.adb
12584 (Build_Dispatching_Requeue): Adding support for VM targets
12585 since we cannot directly reference the Tag entity.
12586 * exp_sel.adb (Build_K): Adding support for VM targets.
12587 (Build_S_Assignment): Adding support for VM targets.
12588 * exp_disp.adb
12589 (Default_Prim_Op_Position): In VM targets do not restrict availability
12590 of predefined interface primitives to compiling in Ada 2005 mode.
12591 (Is_Predefined_Interface_Primitive): In VM targets this service is not
12592 restricted to compiling in Ada 2005 mode.
12593 (Make_VM_TSD): Generate code that declares and initializes the OSD
12594 record. Needed to support dispatching calls through synchronized
12595 interfaces.
12596 * exp_ch3.adb
12597 (Make_Predefined_Primitive_Specs): Enable generation of predefined
12598 primitives associated with synchronized interfaces.
12599 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
12600 primitives associated with synchronized interfaces.
12601
126022011-08-02 Yannick Moy <moy@adacore.com>
12603
12604 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
12605 statements hidden in SPARK if preceded by the HIDE directive
12606 (Parse_Exception_Handlers): mark each exception handler in a sequence of
12607 exception handlers as hidden in SPARK if preceded by the HIDE directive
12608 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
12609 if starting with the HIDE directive
12610 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
12611 starting with the HIDE directive; mark the declarations in a private
12612 part as hidden in SPARK if the private part starts with the HIDE
12613 directive
12614 * restrict.adb, restrict.ads
12615 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
12616 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
12617 argument node belongs to a part which is hidden in SPARK
12618 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
12619 parts in SPARK; protect the possibly costly call to
12620 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
12621 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
12622 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
12623 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
12624 Tok_SPARK_Hide.
12625 (Scan): recognize special comment starting with '#' and followed by
12626 SPARK keyword "hide" as a HIDE directive.
12627
126282011-08-02 Yannick Moy <moy@adacore.com>
12629
12630 * types.ads, erroutc.ads: Minor reformatting.
12631
126322011-08-02 Vincent Celier <celier@adacore.com>
12633
12634 * link.c: Add response file support for cross platforms.
12635
6ff6152d
ES
126362011-08-02 Ed Schonberg <schonberg@adacore.com>
12637
12638 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
12639 in an association, set parent field of copy before partial analysis.
12640 * sem_res.adb (Resolve_Slice): create reference to itype only when
12641 expansion is enabled.
12642
975c6896
YM
126432011-08-02 Yannick Moy <moy@adacore.com>
12644
12645 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
12646 for new flag denoting which subprogram bodies are in ALFA
12647 * restrict.adb, sem_ch7.adb: Update comment
12648 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
12649 sem_ch9.adb, sem_res.adb: Add calls to
12650 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
12651 * sem_ch6.adb (Analyze_Function_Return): add calls to
12652 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
12653 middle of the body, and extended return.
12654 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
12655 False when missing return.
12656 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
12657 to True for subprograms whose spec is in ALFA. Remove later on the flag
12658 on the entity used for a subprogram body when there exists a separate
12659 declaration.
12660 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
12661 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
12662 False, otherwise do nothing.
12663
afc8324d
AC
126642011-08-02 Robert Dewar <dewar@adacore.com>
12665
12666 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
12667
126682011-08-02 Yannick Moy <moy@adacore.com>
12669
12670 * sem_ch4.ads: minor formatting.
12671
2ba431e5
YM
126722011-08-02 Yannick Moy <moy@adacore.com>
12673
12674 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
12675 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
12676 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
12677 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
12678 opt.ads: cleanup of SPARK mode
12679
0f853035
YM
126802011-08-02 Yannick Moy <moy@adacore.com>
12681
12682 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
12683 types.
12684 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
12685 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
12686 * sem_ch3.adb
12687 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
12688 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
12689 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
12690 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
12691 types.
12692 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
12693 non-static range.
12694 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
12695 functions whose return type is not in ALFA.
12696 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
12697 specifications.
12698 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
12699 parameter's type is not in ALFA.
12700 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
12701 types are in ALFA.
12702
d2b10647
ES
127032011-08-02 Ed Schonberg <schonberg@adacore.com>
12704
12705 * sem_ch6 (Analyze_Expression_Function): treat the function as
12706 Inline_Always, and introduce a subprogram declaration for it when it is
12707 not a completion.
12708 * inline.adb (Add_Inlined_Body): recognize bodies that come from
12709 expression functions, so that the back-end can determine whether they
12710 can in fact be inlined.
12711 * sem_util.adb (Is_Expression_Function): predicate to determine whether
12712 a function body comes from an expression function.
12713
c7b9d548
AC
127142011-08-02 Gary Dismukes <dismukes@adacore.com>
12715
12716 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
12717 null exclusions to test Can_Never_Be_Null on the anonymous access types
12718 of the formals rather than testing the formals themselves. Exclude this
12719 check in cases where the Old_Formal is marked as a controlling formal,
12720 to avoid issuing spurious errors for bodies completing dispatching
12721 operations (due to the flag not getting set on controlling access
12722 formals in body specs).
12723 (Find_Corresponding_Spec): When checking full and subtype conformance of
12724 subprogram bodies in instances, pass Designated and E in that order, for
12725 consistency with the expected order of the formals (New_Id followed by
12726 Old_Id).
12727
127282011-08-02 Robert Dewar <dewar@adacore.com>
12729
12730 * sem_ch8.adb: Minor reformatting.
12731
1138cf59
AC
127322011-08-02 Ed Schonberg <schonberg@adacore.com>
12733
12734 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
12735 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
12736 primitive operations of class-wide actuals.
12737
127382011-08-02 Javier Miranda <miranda@adacore.com>
12739
12740 * exp_atag.ads, exp_atag.adb
12741 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
12742 since its value is implicitly passed in argument Typ.
12743 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
12744 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
12745 Build_Common_Dispatching_Select_Statements.
12746
7b9db926
RD
127472011-08-02 Robert Dewar <dewar@adacore.com>
12748
12749 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
12750 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
12751 Minor reformatting.
12752
e8374e7a
AC
127532011-08-02 Robert Dewar <dewar@adacore.com>
12754
12755 * sem_res.adb: Minor reformatting.
12756 * sem_prag.adb: Minor reformatting.
12757
127582011-08-02 Javier Miranda <miranda@adacore.com>
12759
12760 * exp_atag.adb, exp_atags.ads
12761 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
12762 by the tagged type Entity. Required to use this routine in the VM
12763 targets since we do not have available the Tag entity in the VM
12764 platforms.
12765 * exp_ch6.adb
12766 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
12767 Ada.Tags has not been previously loaded.
12768 * exp_ch7.adb
12769 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
12770 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
12771 * sem_aux.adb
12772 (Enclosing_Dynamic_Scope): Add missing support to handle the full
12773 view of enclosing scopes. Required to handle enclosing scopes that
12774 are synchronized types whose full view is a task type.
12775 * exp_disp.adb
12776 (Build_VM_TSDs): Minor code improvement to avoid generating and
12777 analyzing lists with empty nodes.
12778 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
12779 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
12780 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
12781 (Make_Disp_Timed_Select_Body): Add support for VM targets.
12782 (Make_Select_Specific_Data_Table): Add support for VM targets.
12783 (Make_VM_TSD): Generate code to initialize the SSD structure of
12784 the TSD.
12785
127862011-08-02 Yannick Moy <moy@adacore.com>
12787
12788 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
12789 cross-references section in ALI.
12790 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
12791 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
12792 Sub).
12793 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
12794 subprogram or package entity of a node
12795 (Is_Local_Reference_Type): new function returns True for references
12796 selected in local cross-references.
12797 (Lt): function extracted from Lt in Output_References
12798 (Write_Entity_Name): function extracted from Output_References
12799 (Generate_Definition): generate reference with type 'D' for definition
12800 of objects (object declaration and parameter specification), with
12801 appropriate locations and units, for use in local cross-references.
12802 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
12803 references of type 'I' for initialization in object definition.
12804 (Output_References): move part of function Lt and procedure
12805 Write_Entity_Name outside of the body. Ignore references of types 'D'
12806 and 'I' introduced for local cross-references.
12807 (Output_Local_References): new procedure to output the local
12808 cross-references sections.
12809 (Lref_Entity_Status): new array defining whether an entity is a local
12810 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
12811 with 'I' type when initialization expression is present.
12812 * get_scos.adb, get_scos.ads: Correct comments and typos
12813
1f6439e3
AC
128142011-08-02 Javier Miranda <miranda@adacore.com>
12815
12816 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
12817 the JVM target.
12818 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
12819 the JVM target.
12820 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
12821 TSD support.
12822
128232011-08-02 Vincent Celier <celier@adacore.com>
12824
12825 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
12826 (No_Space_Img): New function
12827 (Find_Excluded_Sources): When reading from a file, record the file name
12828 and the line number for each excluded source.
12829 (Mark_Excluded_Sources): When reporting an error, if the excluded
12830 sources were read from a file, include file name and line number in
12831 the error message.
12832
128332011-08-02 Ed Schonberg <schonberg@adacore.com>
12834
12835 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
12836
ab027d28
RD
128372011-08-02 Robert Dewar <dewar@adacore.com>
12838
12839 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
12840
b3b28b0c
JM
128412011-08-02 Javier Miranda <miranda@adacore.com>
12842
12843 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
12844 generation of TSDs to the DOTNET compiler.
12845 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
12846 generation of TSDs to the DOTNET compiler.
12847
9732e886
JM
128482011-08-02 Javier Miranda <miranda@adacore.com>
12849
12850 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
12851 record of all the tagged types declared inside library level package
12852 declarations, library level package bodies or library level subprograms.
12853 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
12854 associated with a given tagged type.
12855 (Build_VM_TSDs): New subprogram.
12856 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
12857 compilation units that are subprograms.
12858 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
12859 compilation units that are package bodies.
12860 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
12861 units that are a package declaration or a package instantiation.
12862 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
12863 reorganization to improve the error generated by the frontend when the
12864 function Ada.Tags.Secondary_Tag is not available.
12865 * rtsfind.ads (RE_Register_TSD): New runtime entity.
12866 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
12867
e526d0c7
AC
128682011-08-02 Javier Miranda <miranda@adacore.com>
12869
12870 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
12871
128722011-08-02 Robert Dewar <dewar@adacore.com>
12873
12874 * s-imenne.ads: Minor reformatting.
12875
128762011-08-02 Robert Dewar <dewar@adacore.com>
12877
12878 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
12879 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
12880 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
12881
128822011-08-02 Robert Dewar <dewar@adacore.com>
12883
12884 * einfo.ads (Materialize_Entity): Document this is only for renamings
12885 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
12886 required debug information in the case where we transform the object
12887 declaration into a renaming declaration.
12888 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
12889 object
12890 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
12891 Materialize_Entity.
12892
5b1e6aca
RD
128932011-08-02 Robert Dewar <dewar@adacore.com>
12894
12895 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
12896 Suppress_Init_Procs.
12897 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
12898 Suppress_Initialization/Initialization_Suppressed.
12899 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
12900 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
12901 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
12902 * sem_prag.adb: New processing for pragma Suppress_Initialization.
12903
5ad4969d
RD
129042011-08-02 Robert Dewar <dewar@adacore.com>
12905
12906 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
12907 Minor reformatting.
12908
8c4ee6f5
AC
129092011-08-02 Ed Schonberg <schonberg@adacore.com>
12910
12911 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
12912 only have inheritable classwide pre/postconditions.
12913
129142011-08-02 Javier Miranda <miranda@adacore.com>
12915
12916 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
12917 * rtsfind.ads (RE_Check_TSD): New runtime entity.
12918 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
12919 checks if the external tag of a type is the same as the external tag
12920 of some other declaration.
12921
0b3d16c0
AC
129222011-08-02 Thomas Quinot <quinot@adacore.com>
12923
12924 * s-taskin.ads: Minor reformatting.
12925
129262011-08-02 Emmanuel Briot <briot@adacore.com>
12927
12928 * g-comlin.adb (Display_Help): swap the order in which it prints the
12929 short help and the general usage.
12930
129312011-08-02 Ed Schonberg <schonberg@adacore.com>
12932
12933 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
12934 the aspect declarations and attach them to the generic copy for
12935 subsequent analysis.
12936 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
12937 declarations of the generic tree to the new subprogram declarations.
12938 * sem_attr.adb (Check_Precondition_Postcondition): recognize
12939 conditions that apply to a subprogram instance.
12940
129412011-08-02 Robert Dewar <dewar@adacore.com>
12942
12943 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
12944
129452011-08-02 Ed Schonberg <schonberg@adacore.com>
12946
12947 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
12948 private type with a tagged full view is not derived in the immediate
12949 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
12950
4637729f
AC
129512011-08-02 Robert Dewar <dewar@adacore.com>
12952
12953 * exp_ch4.adb: Minor reformatting.
12954
129552011-08-02 Ed Schonberg <schonberg@adacore.com>
12956
12957 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
12958 Ada2012 iterator, the loop will be rewritten during expansion into a
12959 while loop with a cursor and an element declaration. Do not analyze the
12960 body in this case, because if the container is for indefinite types the
12961 actual subtype of the elements will only be determined when the cursor
12962 declaration is analyzed.
12963
129642011-08-02 Arnaud Charlet <charlet@adacore.com>
12965
12966 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
12967 size/alignment related attributes in CodePeer_Mode.
12968
129692011-08-02 Gary Dismukes <dismukes@adacore.com>
12970
12971 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
12972 Prepend_Element, since this can result in the operation getting the
12973 wrong slot in the full type's dispatch table if the full type has
12974 inherited operations. The incomplete type's operation will get added
12975 to the proper position in the full type's primitives
12976 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
12977 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
12978 dispatching operations, since there are cases where nonprimitive
12979 subprograms can get added to the list of incomplete dependents (such
12980 as subprograms in nested packages).
12981 * sem_ch6.adb (Process_Formals): First, remove test for being in a
12982 private part when determining whether to add a primitive with a
12983 parameter of a tagged incomplete type to the Private_Dependents list.
12984 Such primitives can also occur in the visible part, and should not have
12985 been excluded from being private dependents.
12986 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
12987 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
12988 list of a Taft-amendment incomplete type is a primitive before issuing
12989 an error that the full type must appear in the same unit. There are
12990 cases where nonprimitives can be in the list (such as subprograms in
12991 nested packages).
12992 * sem_disp.adb (Derives_From): Use correct condition for checking that
12993 a formal's type is derived from the type of the corresponding formal in
12994 the parent subprogram (the condition was completely wrong). Add
12995 checking that was missing for controlling result types being derived
12996 from the result type of the parent operation.
12997
4c60de0c
YM
129982011-08-02 Yannick Moy <moy@adacore.com>
12999
13000 * errout.adb (First_Node): minor renaming
13001 * restrict.adb (Check_Formal_Restriction): put restriction warning on
13002 first node.
13003
f5afb270
AC
130042011-08-02 Yannick Moy <moy@adacore.com>
13005
13006 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
13007 before accessing operands.
13008 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
13009 decide whether an initialization expression respects SPARK rules, as
13010 the plain node is the expanded one. This allows for more valid warnings
13011 to be issued.
13012 * gnat_rm.texi: Minor update.
13013
130142011-08-02 Arnaud Charlet <charlet@adacore.com>
13015
13016 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
13017 previous change.
13018
130192011-08-02 Robert Dewar <dewar@adacore.com>
13020
13021 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
13022
130232011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
13024
13025 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
13026 loop statements and the element renaming declaration with a block when
13027 the element type is controlled.
13028
130292011-08-02 Yannick Moy <moy@adacore.com>
13030
13031 * sinfo.ads: Minor formatting.
13032
130332011-08-02 Ed Schonberg <schonberg@adacore.com>
13034
13035 * sem_aggr.adb (Add_Association): if the association has a box and no
13036 expression, use the Sloc of the aggregate itself for the new
13037 association.
13038 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
13039 the Original_Node.
13040
db72f10a
AC
130412011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
13042
13043 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
13044 When a container is provided via a function call, generate a renaming
13045 of the function result. This avoids the creation of a transient scope
13046 and the premature finalization of the container.
13047 * exp_ch7.adb (Is_Container_Cursor): Removed.
13048 (Wrap_Transient_Declaration): Remove the supression of the finalization
13049 of the list controller when the declaration denotes a container cursor,
13050 it is not needed.
13051
130522011-08-02 Yannick Moy <moy@adacore.com>
13053
13054 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
13055 node is from source, instead of the original node being from source.
13056 * sem_aggr.adb
13057 (Resolve_Array_Aggregate): refine the check for a static expression, to
13058 recognize also static ranges
13059 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
13060 Array_Type_Declaration): postpone the test for the type being a subtype
13061 mark after the type has been resolved, so that component-selection and
13062 expanded-name are discriminated.
13063 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
13064 to distinguish the case of an iteration scheme, so that an error is
13065 issed on a non-static range in SPARK except in an iteration scheme.
13066 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
13067 In_Iter_Schm = True.
13068 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
13069 user-defined operators so that they are allowed in renaming
13070 * sem_ch8.adb
13071 (Find_Selected_Component): refine the check for prefixing of operators
13072 so that they are allowed in renaming. Move the checks for restrictions
13073 on selector name after analysis discriminated between
13074 component-selection and expanded-name.
13075 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
13076 concatenation argument of string type if it is static.
13077 * sem_util.adb, sem_util.ads
13078 (Check_Later_Vs_Basic_Declarations): add a new function
13079 Is_Later_Declarative_Item to decice which declarations are allowed as
13080 later items, in the two different modes Ada 83 and SPARK. In the SPARK
13081 mode, add that renamings are considered as later items.
13082 (Enclosing_Package): new function to return the enclosing package
13083 (Enter_Name): correct the rule for homonyms in SPARK
13084 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
13085 from source (result of expansion) to avoid issuing wrong warnings.
13086
130872011-08-02 Ed Schonberg <schonberg@adacore.com>
13088
13089 * errout.adb: On anything but an expression First_Node returns its
13090 argument.
13091
23685ae6
AC
130922011-08-02 Pascal Obry <obry@adacore.com>
13093
13094 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
13095
130962011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
13097
13098 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
13099 Set the associated loop as the related expression of internally
13100 generated cursors.
13101 * exp_ch7.adb (Is_Container_Cursor): New routine.
13102 (Wrap_Transient_Declaration): Supress the finalization of the list
13103 controller when the declaration denotes a container cursor.
13104
131052011-08-02 Yannick Moy <moy@adacore.com>
13106
13107 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
13108 command line now.
13109 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
13110 expression is a simple expression. This check cannot be performed in
13111 the semantics, so just drop it.
13112 (P_Index_Or_Discriminant_Constraint): move check that the index or
13113 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
13114 semantics. Other cases were previously checked in the semantics.
13115 * par-ch4.adb (P_Name): move checks that a selector name is not
13116 character literal or an operator symbol to Find_Selected_Component in
13117 the semantics
13118 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
13119 declarations are not placed after later declarations in a separate
13120 procedure in Sem_Util (possibly not the best choice?), to be used both
13121 during parsing, for Ada 83 mode, and during semantic analysis, for
13122 SPARK mode.
13123 * par-endh.adb (Check_End): move check that end label is not missing
13124 to Process_End_Label in the semantics
13125 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
13126 the special case for SPARK restriction
13127 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
13128 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
13129 parameter Force to issue the error message even on internal node (used
13130 for generated end label). Call Check_Restriction to check when an error
13131 must be issued. In SPARK mode, issue an error message even if the
13132 restriction is not set.
13133 (Check_Restriction): new procedure with an additional out parameter to
13134 inform the caller that a message has been issued
13135 * sem_aggr.adb: Minor modification of message
13136 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
13137 instead of issuing an error message directly
13138 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
13139 declarations are not placed after later declarations, by calling
13140 Check_Later_Vs_Basic_Declarations
13141 (Analyze_Subtype_Declaration): move here the check that an index or
13142 discriminant constraint must be a subtype mark. Change the check that
13143 a subtype of String must start at one so that it works on subtype marks.
13144 * sem_ch4.adb (Analyze_Call): move here the check that a named
13145 association cannot follow a positional one in a call
13146 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
13147 instead of issuing an error message directly
13148 * sem_ch8.adb (Find_Selected_Component): move here the check that a
13149 selector name is not a character literal or an operator symbol. Move
13150 here the check that the prefix of an expanded name cannot be a
13151 subprogram or a loop statement.
13152 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
13153 procedure called from parsing and semantics to check that basic
13154 declarations are not placed after later declarations
13155 (Process_End_Label): move here the check that end label is not missing
13156
131572011-08-02 Arnaud Charlet <charlet@adacore.com>
13158
13159 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
13160 representation clause in codepeer mode, since it confuses CodePeer and
13161 does not bring useful info.
13162
131632011-08-02 Ed Falis <falis@adacore.com>
13164
13165 * init.c: initialize fp hw on MILS.
13166
131672011-08-02 Ed Schonberg <schonberg@adacore.com>
13168
13169 * errout.adb (First_Node): for bodies, return the node itself (small
13170 optimization). For other nodes, do not check source_unit if the node
13171 comes from Standard.
13172
d2d9cc22
AC
131732011-08-02 Robert Dewar <dewar@adacore.com>
13174
13175 * exp_ch3.adb: Minor comment additions.
13176 * sem_ch13.adb: Minor reformatting.
13177
131782011-08-02 Pascal Obry <obry@adacore.com>
13179
13180 * make.adb, makeutl.adb: Removes some superfluous directory separator.
13181
a01b9df6
AC
131822011-08-02 Robert Dewar <dewar@adacore.com>
13183
13184 * sem_attr.adb: Minor reformatting.
13185
131862011-08-02 Robert Dewar <dewar@adacore.com>
13187
13188 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
13189 (Has_Default_Component_Value): Removed
13190 * einfo.ads Comment updates
13191 (Has_Default_Aspect): Replaces Has_Default_Value
13192 (Has_Default_Component_Value): Removed
13193 * exp_ch13.adb
13194 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
13195 * exp_ch3.adb
13196 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
13197 (Get_Simple_Init_Val): Handle Default_Value aspect
13198 (Needs_Simple_Initialization): Handle Default_Value aspect
13199 * exp_ch3.ads: Needs_Simple_Initialization
13200 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
13201 * par-prag.adb (Pragma_Default[_Component]Value) Removed
13202 * sem_ch13.adb
13203 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
13204 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
13205 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
13206
132072011-08-02 Ed Schonberg <schonberg@adacore.com>
13208
13209 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
13210 package containing iteration primitives.
13211 exp_ch5.adb (Expand_Iterator_Loop): ditto.
13212
75c90775
AC
132132011-08-02 Ed Schonberg <schonberg@adacore.com>
13214
13215 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
13216 "of", pre-analyze expression in case it is a function call with
13217 finalization actions that must be placed ahead of the loop.
13218 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
13219 on an Ada2012 iterator, insert them ahead of the rewritten loop.
13220
132212011-08-02 Geert Bosch <bosch@adacore.com>
13222
13223 * cstand.adb (Create_Float_Types): Only consider C's long double for
13224 Long_Long_Float, in addition to double.
13225
ded8909b
AC
132262011-08-02 Robert Dewar <dewar@adacore.com>
13227
13228 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
13229 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
13230 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
13231 Minor reformatting.
13232
132332011-08-02 Ed Schonberg <schonberg@adacore.com>
13234
13235 * sem_attr.adb: handle properly 'Result when it is a prefix of an
13236 indexed component.
13237
132382011-08-02 Javier Miranda <miranda@adacore.com>
13239
13240 * einfo.ads, einfo.adb
13241 (Original_Access_Type): Move this attribute to Node26 since there was
13242 an undocumented use of Node21 in E_Access_Subprogram_Type entities
13243 which causes conflicts and breaks the generation of the .NET compiler.
13244 (Interface_Name): Add missing documentation on JGNAT only uses of
13245 this attribute.
13246
70c34e1c
AC
132472011-08-02 Geert Bosch <bosch@adacore.com>
13248
13249 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
13250 (Find_Back_End_Float_Type): Likewise
13251 (Create_Back_End_Float_Types): Likewise
13252 (Create_Float_Types): Likewise
13253 (Register_Float_Type): Likewise
13254 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
13255 Nlist and split out type selection in new local Find_Base_Type function.
13256 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
13257 Nlist
13258 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
13259
132602011-08-02 Robert Dewar <dewar@adacore.com>
13261
13262 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
13263 alpha order).
13264 * opt.ads: Minor comment change.
13265 * sem_ch12.adb: Minor code reorganization.
13266
b715bc59
AC
132672011-08-02 Gary Dismukes <dismukes@adacore.com>
13268
13269 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
13270 subtype's list of rep items to the list on the full subtype in the case
13271 where the lists are the same.
13272
132732011-08-02 Geert Bosch <bosch@adacore.com>
13274
13275 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
13276 using the one from System.Strings, which also deallocates all strings.
13277
002bdd68
AC
132782011-08-02 Geert Bosch <bosch@adacore.com>
13279
13280 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
13281 function.
13282 * gcc-interface/Make-lang.in: Update dependencies.
13283
132842011-08-02 Olivier Hainque <hainque@adacore.com>
13285
13286 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
13287 end_locus.
13288
499769ec
AC
132892011-08-02 Javier Miranda <miranda@adacore.com>
13290
13291 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
13292 associated with anonymous access to subprograms.
13293
132942011-08-02 Geert Bosch <bosch@adacore.com>
13295
13296 * opt.ads
13297 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
13298 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
13299 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
13300 (Add_Symbol_Definition): Move to switch-c.adb
13301 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
13302 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
13303 (Add_Symbol_Definition): Move to switch-c.adb.
13304 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
13305 * sem_warn.adb
13306 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
13307 Move to warnsw.adb.
13308 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
13309 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
13310 Move to warnsw.adb.
13311 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
13312 (Add_Symbol_Definition): Moved from Prepcomp.
13313 * switch-c.ads: Update copyright notice. Use String_List instead of
13314 Argument_List, removing dependency on System.OS_Lib.
13315
aa1e353a
AC
133162011-08-02 Yannick Moy <moy@adacore.com>
13317
13318 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
13319 mode on initialization expression which does not respect SPARK
13320 restrictions.
13321 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
13322 if the tree referenced by its argument represents an initialization
13323 expression in SPARK, suitable for initializing an object in an object
13324 declaration.
13325
133262011-08-02 Javier Miranda <miranda@adacore.com>
13327
13328 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
13329 internally generated access to subprogram with its associated protected
13330 subprogram type.
13331 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
13332
15b682ca
GB
133332011-08-02 Geert Bosch <bosch@adacore.com>
13334
13335 * cstand.adb (Register_Float_Type): Print information about type to
13336 register, if the Debug_Flag_Dot_B is set.
13337 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
13338 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
13339 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
13340 with a requested precision of more than Max_Digits digits and no more
13341 than Max_Base_Digits digits, if a range specification is present and the
13342 Predefined_Float_Types list has a suitable type to derive from.
13343 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
13344 case of type completion with pragma Import
13345 * sem_prag.adb
13346 (Process_Import_Predefined_Type): Processing to complete a type
13347 with pragma Import. Currently supports floating point types only.
13348 (Set_Convention_From_Pragma): Do nothing without underlying type.
13349 (Process_Convention): Guard against absence of underlying type,
13350 which may happen when importing incomplete types.
13351 (Process_Import_Or_Interface): Handle case of importing predefined
13352 types. Tweak error message.
13353
f8726f2b
AC
133542011-08-02 Eric Botcazou <ebotcazou@adacore.com>
13355
13356 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
13357 functions to previous change. Reorganize code slightly.
13358
133592011-08-02 Geert Bosch <bosch@adacore.com>
13360
13361 * back_end.ads (Register_Type_Proc): New call back procedure type for
13362 allowing the back end to provide information about available types.
13363 (Register_Back_End_Types): New procedure to register back end types.
13364 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
13365 available types.
13366 * cstand.adb (Back_End_Float_Types): New list for floating point types
13367 supported by the back end.
13368 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
13369 (Copy_Float_Type): New procedure to make new copies of predefined types.
13370 (Register_Float_Type): New call back procedure to populate the BEFT list
13371 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
13372 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
13373 (Create_Float_Types): New procedure to create entities for floating
13374 point types predefined in Standard, and put these and any remaining
13375 BEFTs on the Predefined_Float_Types list.
13376 * stand.ads (Predefined_Float_Types): New list for predefined floating
13377 point types that do not have declarations in package Standard.
13378
feecad68
AC
133792011-08-02 Eric Botcazou <ebotcazou@adacore.com>
13380
13381 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
13382 entity node for the unit containing the parameter.
13383 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
13384 (Add_Inlined_Subprogram): Likewise.
13385 * gcc-interface/Make-lang.in: Update dependencies.
13386
133872011-08-02 Thomas Quinot <quinot@adacore.com>
13388
13389 * s-stusta.adb (Print): Make sure Pos is always initialized to a
13390 suitable value.
13391
12f0c50c
AC
133922011-08-02 Geert Bosch <bosch@adacore.com>
13393
13394 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
13395
133962011-08-02 Eric Botcazou <ebotcazou@adacore.com>
13397
13398 * sem_type.adb (Covers): Move trivial case to the top and reuse the
13399 computed value of Base_Type.
13400
134012011-08-02 Yannick Moy <moy@adacore.com>
13402
13403 * restrict.adb (Check_Restriction): issue an error for any use of
13404 class-wide, even if the No_Dispatch restriction is not set.
13405 * sem_aggr.adb: Correct typos in comments and messages in formal mode
13406 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
13407 when completing a private extension, the type named in the private part
13408 is not the same as that named in the visible part.
13409 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
13410 of an inherited primitive operations of a tagged type or type extension
13411 that returns the tagged type.
13412 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
13413 function which returns True for an implicit operation inherited by the
13414 derived type declaration for the argument type.
13415 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
13416 order.
13417
fb86fe11
ES
134182011-08-02 Ed Schonberg <schonberg@adacore.com>
13419
13420 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
13421 Process_Bounds, to perform analysis with expansion of a range or an
13422 expression that is the iteration scheme for a loop.
13423 (Analyze_Iterator_Specification): If domain of iteration is given by a
13424 function call with a controlled result, as is the case if call returns
13425 a predefined container, ensure that finalization actions are properly
13426 generated.
13427 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
13428
62be5d0a
JM
134292011-08-02 Javier Miranda <miranda@adacore.com>
13430
13431 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
13432 * gcc-interface/Make-lang.in: Update dependencies.
13433
134342011-08-02 Javier Miranda <miranda@adacore.com>
13435
13436 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
13437 determine if the analysis is performed using N or Original_Node (N).
13438 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
13439 functionality of routine Is_Variable avoids code duplication.
13440 * checks.adb (Determine_Range): Handle temporaries generated by
13441 Remove_Side_Effects.
13442
134432011-08-02 Javier Miranda <miranda@adacore.com>
13444
13445 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
13446 expansion of the condition. Required since the previous analysis was
13447 done with expansion disabled (see Resolve_Quantified_Expression) and
13448 hence checks were not inserted and record comparisons have not been
13449 expanded.
13450
a20f4389
AC
134512011-08-02 Ed Falis <falis@adacore.com>
13452
13453 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
13454 Update header.
13455
134562011-08-02 Bob Duff <duff@adacore.com>
13457
13458 * opt.ads: Minor comment fix.
13459
134602011-08-02 Bob Duff <duff@adacore.com>
13461
13462 * sem_ch12.adb (Analyze_Package_Instantiation,
13463 Analyze_Subprogram_Instantiation): Turn off style checking while
13464 analyzing an instance. Whatever style checks that apply to the generic
13465 unit should apply, so it makes no sense to apply them in an instance.
13466 This was causing trouble when compiling an instance of a runtime
13467 unit that violates the -gnatyO switch.
13468 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
13469 one of the two case statements, causing spurious errors.
13470
134712011-08-02 Robert Dewar <dewar@adacore.com>
13472
13473 * uname.adb: Minor reformatting.
13474 * gnatcmd.adb: Minor reformatting.
13475 * exp_attr.adb: Minor reformatting.
13476
90878b12
AC
134772011-08-02 Ed Schonberg <schonberg@adacore.com>
13478
13479 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
13480 No_Dispatching_Calls, do not look for the Assign primitive, because
13481 predefined primitives are not created in this case.
13482
134832011-08-02 Bob Duff <duff@adacore.com>
13484
13485 * stylesw.ads: Minor comment fixes.
13486
134872011-08-02 Robert Dewar <dewar@adacore.com>
13488
13489 * freeze.adb (Add_To_Result): New procedure.
13490
134912011-08-02 Jose Ruiz <ruiz@adacore.com>
13492
13493 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
13494 time, if the specific run-time routines for handling streams of strings
13495 are not available, use the default mechanism.
13496
134972011-08-02 Arnaud Charlet <charlet@adacore.com>
13498
13499 * s-regpat.ads: Fix typo.
13500
135012011-08-02 Vincent Celier <celier@adacore.com>
13502
13503 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
13504 not null, call it to create the in memory config project file without
13505 parsing an existing default config project file.
13506
135072011-08-02 Eric Botcazou <ebotcazou@adacore.com>
13508
13509 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
13510
135112011-08-02 Ed Schonberg <schonberg@adacore.com>
13512
13513 * sem_elim.adb: an abstract subprogram does not need an eliminate
13514 pragma for its descendant to be eliminable.
13515
135162011-08-02 Ed Falis <falis@adacore.com>
13517
13518 * init.c: revert to handling before previous checkin for VxWorks
13519 * s-intman-vxworks.adb: delete unnecessary declarations related to
13520 using Ada interrupt facilities for handling signals.
13521 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
13522 * s-intman-vxworks.ads: Import __gnat_install_handler as
13523 Initialize_Interrupts.
13524 * s-taprop-vxworks.adb: Delete Signal_Mask.
13525 (Abort_Handler): change construction of mask to unblock exception
13526 signals.
13527
273adcdf
AC
135282011-08-02 Jerome Guitton <guitton@adacore.com>
13529
13530 * a-except-2005.adb (Raise_From_Signal_Handler): Call
13531 Debug_Raise_Exception before propagation starts.
13532
135332011-08-02 Eric Botcazou <ebotcazou@adacore.com>
13534
13535 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
13536 to Restriction_Check_Required.
13537 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
13538 * sem_res.adb (Resolve_Call): Likewise.
13539 * sem_attr.adb (Check_Stream_Attribute): Likewise.
13540
135412011-08-02 Bob Duff <duff@adacore.com>
13542
13543 * stylesw.ads: Update comment.
13544 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
13545 * errout.ads: Remove obsolete comment.
13546
135472011-08-02 Javier Miranda <miranda@adacore.com>
13548
13549 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
13550 (Set_Is_Safe_To_Reevaluate): new procedure.
13551 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
13552 assignment is allowed on safe-to-reevaluate variables.
13553 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
13554 temporary created to remove side effects in expressions that use
13555 the secondary stack as safe-to-reevaluate.
13556 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
13557 variables that are not true constants.
13558
6320f5e1
AC
135592011-08-02 Robert Dewar <dewar@adacore.com>
13560
13561 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
13562 sem_res.adb, sem_ch6.adb: Minor reformatting.
13563
135642011-08-02 Jerome Guitton <guitton@adacore.com>
13565
13566 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
13567
2fe829ae
ES
135682011-08-02 Ed Schonberg <schonberg@adacore.com>
13569
13570 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
13571 not set Overridden_Operation if subprogram is an initialization
13572 procedure.
13573
e24329cd
YM
135742011-08-02 Yannick Moy <moy@adacore.com>
13575
13576 * par-ch6.adb: Correct obsolete name in comments
13577 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
13578 which takes two message arguments (existing function takes one), with
13579 second message used for continuation.
13580 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
13581 block statements that originate from a source block statement, not
13582 generated block statements
13583 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
13584 symmetry with procedure case
13585 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
13586 function to issue an error in formal mode if a package specification
13587 contains more than one tagged type or type extension.
13588 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
13589 parameters matching formals of tagged types are objects (or ancestor
13590 type conversions of objects), not general expressions. Issue an error
13591 on view conversions that are not involving ancestor conversion of an
13592 extended type.
13593 (Resolve_Type_Conversion): in formal mode, issue an error on the
13594 operand of an ancestor type conversion which is not an object
13595 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
13596 procedure so that it works also for actuals of function calls
13597 (Is_Actual_Tagged_Parameter): new function which determines if its
13598 argument is an actual parameter of a formal of tagged type in a
13599 subprogram call
13600 (Is_SPARK_Object_Reference): new function which determines if the tree
13601 referenced by its argument represents an object in SPARK
13602
176dadf6
AC
136032011-08-02 Robert Dewar <dewar@adacore.com>
13604
13605 * sem_ch3.adb: Minor reformatting
13606 Minor comment addition
13607 Minor error msg text change
13608
136092011-08-02 Javier Miranda <miranda@adacore.com>
13610
13611 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
13612 function. Used to be more precise when we generate a variable plus one
13613 assignment to remove side effects in the evaluation of the Bound
13614 expressions.
13615 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
13616 of the bound expression to force its re-analysis and thus expand the
13617 associated transient scope (if required). Code cleanup replacing the
13618 previous code that declared the constant entity by an invocation to
13619 routine Force_Evaluation which centralizes this work in the frontend.
13620
d8b962d8
AC
136212011-08-02 Robert Dewar <dewar@adacore.com>
13622
13623 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
13624 (Base_Type): Now uses improved Is_Base_Type function
13625 * einfo.ads (Base_Type): Inline this function
13626
136272011-08-02 Robert Dewar <dewar@adacore.com>
13628
13629 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
13630 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
13631
136322011-08-02 Arnaud Charlet <charlet@adacore.com>
13633
13634 * gcc-interface/Make-lang.in: Update dependencies.
13635 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
13636 targets.
13637
136382011-08-02 Yannick Moy <moy@adacore.com>
13639
13640 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
13641 non-simple expression used in delta constraint
13642 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
13643 index constraint which is not a subtype mark
13644 * par.adb: With and use Restrict
13645 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
13646 mode on component type which is not a subtype mark and default
13647 expression on component
13648 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
13649 of string which does not have a lower index bound equal to 1
13650 (Array_Type_Declaration): issue an error in formal mode on index or
13651 component type which is not a subtype mark, and on aliased keyword on
13652 component
13653 (Derived_Type_Declaration): issue an error in formal mode on interface,
13654 limited or abstract type
13655 (Record_Type_Declaration): issue an error in formal mode on interface
13656 (Record_Type_Definition): issue an error in formal mode on tagged types
13657 and type extensions not declared in the specification of a library unit
13658 package; on null non-tagged record; on variant part
13659
136602011-08-02 Vincent Celier <celier@adacore.com>
13661
13662 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
13663 not declared for qualified library project when Library_Name is not
13664 declared, but Library_Dir is.
13665
136662011-08-02 Robert Dewar <dewar@adacore.com>
13667
13668 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
13669 pragmas (affects aspects [Component_]Default_Value
13670 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
13671 component type for the resolution
13672
f96b2d85
AC
136732011-08-02 Eric Botcazou <ebotcazou@adacore.com>
13674
13675 * einfo.adb (Base_Type): Tune implementation for speed.
13676
136772011-08-02 Robert Dewar <dewar@adacore.com>
13678
13679 * freeze.adb: Minor reformatting.
13680
8b3c6430
AC
136812011-08-02 Thomas Quinot <quinot@adacore.com>
13682
13683 * scos.ads: Update comments.
13684
136852011-08-02 Ed Schonberg <schonberg@adacore.com>
13686
13687 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
13688 base type, because the parent may be a subtype of a private type whose
13689 convention is established in a private part.
13690
136912011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
13692
13693 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
13694 statement in a block when the expansion of the return expression has
13695 created a finalization chain.
13696 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
13697 with the parent node.
13698 Add N_Extended_Return_Statement to handle the case where a transient
13699 object declaration appears in the Return_Object_Declarations list of
13700 an extended return statement.
13701
137022011-08-02 Matthew Gingell <gingell@adacore.com>
13703
13704 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
13705 unused parameter 'name'.
13706
137072011-08-02 Ed Schonberg <schonberg@adacore.com>
13708
13709 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
13710 inherited operation, check whether its alias, which is the source
13711 operastion that it renames, has been marked eliminated.
13712
cae81f17
JM
137132011-08-02 Javier Miranda <miranda@adacore.com>
13714
13715 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
13716 in-mode parameter whose type is an access type since it can be used to
13717 modify its designated object. Enforce code that handles as safe an
13718 access type that is not access-to-constant but it is the result of a
13719 previous removal of side-effects.
13720 (Remove_Side_Effects): Minor code reorganization of cases which require
13721 no action. Done to incorporate documentation on new cases uncovered
13722 working in this ticket: no action needed if this routine was invoked
13723 too early and the nodes are not yet decorated.
13724 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
13725 to routine Remove_Side_Effects by calls to Force_Evaluation since they
13726 were issued with actuals that are implicitly provided by
13727 Force_Evaluation.
13728
218e6dee
RD
137292011-08-02 Robert Dewar <dewar@adacore.com>
13730
13731 * sem_ch3.adb, sem_res.adb: Minor reformatting.
13732
7a489a2b
AC
137332011-08-02 Yannick Moy <moy@adacore.com>
13734
13735 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
13736 to issue an error in formal mode on attribute not supported in this mode
13737 (Analyze_Attribute): issue errors on standard attributes not supported
13738 in formal mode.
13739 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
13740 comment, and issue error in formal mode on modulus which is not a power
13741 of 2.
13742 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
13743 range.
13744 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
13745 subtype mark.
13746 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
13747 operator on modular type (except 'not').
13748
137492011-08-02 Robert Dewar <dewar@adacore.com>
13750
13751 * gnat_rm.texi: Minor reformatting.
13752
cb7fa356
AC
137532011-08-02 Arnaud Charlet <charlet@adacore.com>
13754
13755 * s-osinte-linux.ads: Minor comment update and reformatting.
13756 * i-cexten.ads: Make this unit pure, as for its parent.
13757 Will allow its usage in more contexts if needed.
13758
137592011-08-02 Robert Dewar <dewar@adacore.com>
13760
13761 * s-utf_32.ads: Minor comment fix.
13762
137632011-08-02 Ed Schonberg <schonberg@adacore.com>
13764
13765 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
13766 operation of a tagged synchronized type, handle the case where the
13767 controlling argument is overloaded.
13768
137692011-08-02 Yannick Moy <moy@adacore.com>
13770
13771 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
13772 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
13773 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
13774 SPARK mode and formal verification mode on processing SPARK restriction
13775 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
13776 requiring consistency checking.
13777
5cc9353d
RD
137782011-08-02 Robert Dewar <dewar@adacore.com>
13779
13780 * sem_res.adb: Minor reformatting.
13781
e51537ff
RD
137822011-08-02 Robert Dewar <dewar@adacore.com>
13783
13784 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
13785 a-cforse.ads: Remove unneeded with of Ada.Containers
13786 Remove commented out pragma Inline's
13787 Move specifications of new subprograms to the actual specs
13788
83fa09c5
AC
137892011-08-02 Yannick Moy <moy@adacore.com>
13790
13791 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
13792 a-cforse.ads: Update comments.
13793
137942011-08-02 Ed Schonberg <schonberg@adacore.com>
13795
13796 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
13797
d11cfaf8
RD
137982011-08-02 Robert Dewar <dewar@adacore.com>
13799
13800 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
13801 a-cforse.ads, a-cofove.ads: Minor reformatting.
13802
300b98bb
AC
138032011-08-02 Claire Dross <dross@adacore.com>
13804
13805 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
13806 a-cofove.ads: Add comments.
13807
138082011-08-02 Yannick Moy <moy@adacore.com>
13809
13810 * gnat_rm.texi: Document formal containers.
13811
138122011-08-02 Emmanuel Briot <briot@adacore.com>
13813
13814 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
13815 are empty sections.
13816
19fb051c
AC
138172011-08-02 Robert Dewar <dewar@adacore.com>
13818
13819 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
13820 reformatting.
13821
138222011-08-02 Robert Dewar <dewar@adacore.com>
13823
13824 * aspects.adb: New aspects Default_Value and Default_Component_Value
13825 New format of Aspect_Names table checks for omitted entries
13826 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
13827 handling of boolean aspects for derived types.
13828 New aspects Default_Value and Default_Component_Value
13829 New format of Aspect_Names table checks for omitted entries
13830 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
13831 (Has_Default_Value): New flag
13832 (Has_Default_Component_Value): New flag
13833 (Has_Default_Value): New flag
13834 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
13835 table.
13836 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
13837 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
13838 Default_Value and Default_Component_Value
13839 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
13840 New aspects Default_Value and Default_Component_Value
13841 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
13842 * sprint.adb: Print N_Aspect_Specification node when called from gdb
13843
138442011-08-02 Vincent Celier <celier@adacore.com>
13845
13846 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
13847 inherit library kind.
13848
138492011-08-02 Ed Schonberg <schonberg@adacore.com>
13850
13851 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
13852 Minor reformatting.
13853
138542011-08-02 Robert Dewar <dewar@adacore.com>
13855
13856 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
13857
5f7747af
AC
138582011-08-02 Yannick Moy <moy@adacore.com>
13859
13860 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
13861
138622011-08-02 Robert Dewar <dewar@adacore.com>
13863
13864 * impunit.adb: Add comment.
13865
a5fe697b
AC
138662011-08-02 Yannick Moy <moy@adacore.com>
13867
13868 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
13869 qualification of aggregates in formal mode
13870 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
13871 another aggregate
13872 (Resolve_Aggregate): complete the test that an aggregate is adequately
13873 qualified in formal mode
13874
138752011-08-02 Pascal Obry <obry@adacore.com>
13876
13877 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
13878 * mlib-prj.adb: Supress warning when compiling binder generated file.
13879 (Build_Library): Supress all warnings when compiling the binder
13880 generated file.
13881
bd65a2d7 138822011-08-02 Yannick Moy <moy@adacore.com>
d4487611 13883
bd65a2d7
AC
13884 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
13885 from here...
13886 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
13887 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
13888 Add with/use clauses to make Check_Formal_Restriction visible
13889
138902011-08-02 Ed Schonberg <schonberg@adacore.com>
13891
13892 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
13893 in-parameters when type of the generic formal is private in the generic
13894 spec and non-private in the body.
13895
138962011-08-02 Claire Dross <dross@adacore.com>
13897
13898 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
13899 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
13900 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
13901 * impunit.adb, Makefile.rtl: Take new files into account.
d4487611
AC
13902
139032011-08-02 Robert Dewar <dewar@adacore.com>
13904
13905 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
13906 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
13907
bd434b3f
YM
139082011-08-02 Yannick Moy <moy@adacore.com>
13909
13910 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
13911 formal mode
13912 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
13913 matching static array bounds, taking into account the special case of
13914 string literals
13915 * sem_ch3.adb: Typo in comment.
13916
fe5d3068
YM
139172011-08-02 Yannick Moy <moy@adacore.com>
13918
13919 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
13920 which issues an error in formal mode if its argument node is originally
13921 from source
13922 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
13923 has a discriminant specification so that it does not include the case
13924 of derived types
13925 (Derived_Type_Declaration): move here the test that a derived type has a
13926 discriminant specification
13927 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
13928 first element of a component association before accessing its choices
13929 (presence of component association is not enough)
13930 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
13931 declaration is a library item before accessing the next element in a
13932 list, as library items are not member of lists
13933 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
13934 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
13935 Check_Formal_Restriction whenever possible.
13936
b60a3f26
AC
139372011-08-02 Ed Schonberg <schonberg@adacore.com>
13938
13939 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
13940 reference when needed.
13941
139422011-08-02 Bob Duff <duff@adacore.com>
13943
13944 * gnat_ugn.texi: Fix typo.
13945
139462011-08-02 Vincent Celier <celier@adacore.com>
13947
13948 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
13949 archive file name. Do not use the full path name of archives for Open
13950 VMS.
13951
eaba57fb
RD
139522011-08-02 Robert Dewar <dewar@adacore.com>
13953
13954 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
13955 Analyze_Aspect_Specifications
13956 * sem_ch13.adb
13957 (Analyze_Aspect_Specifications): New handling for boolean aspects
13958 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
13959 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
13960 sequence for Analyze_Aspect_Specifications
13961 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
13962 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
13963
139642011-08-02 Robert Dewar <dewar@adacore.com>
13965
13966 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
13967 aspects, since these no longer exist.
13968
139692011-08-02 Robert Dewar <dewar@adacore.com>
13970
13971 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
13972 semicolon, do not try to see if there are aspects following it.
13973 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
13974 aspect spec.
13975
8830d1d2
AC
139762011-08-02 Robert Dewar <dewar@adacore.com>
13977
13978 * sem_ch8.adb, aspects.ads: Minor reformatting.
13979
139802011-08-02 Eric Botcazou <ebotcazou@adacore.com>
13981
13982 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
13983 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
13984 extracted from...
13985 (Analyze_Aspect_Specifications): ...here. Call above procedure.
13986
7ff2d234
AC
139872011-08-02 Yannick Moy <moy@adacore.com>
13988
13989 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
13990 mode on subprogram declaration outside of package specification, unless
13991 it is followed by a pragma Import
13992 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
13993 Access_Type_Declaration): issue error in formal mode on access type
13994 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
13995 incomplete type
13996 (Analyze_Object_Declaration): issue error in formal mode on object
13997 declaration which does not respect SPARK restrictions
13998 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
13999 declaration which does not respect SPARK restrictions
14000 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
14001 error in formal mode on digits or delta constraint
14002 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
14003 decimal fixed point type
14004 (Derived_Type_Declaration): issue error in formal mode on derived type
14005 other than type extensions of tagged record types
14006 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
14007 with check on access definition
14008 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
14009 mode on protected definition.
14010 (Analyze_Task_Definition): issue error in formal mode on task definition
14011
140122011-08-02 Robert Dewar <dewar@adacore.com>
14013
14014 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
14015
806f6d37
AC
140162011-08-02 Javier Miranda <miranda@adacore.com>
14017
14018 * sem_ch6.adb (Can_Override_Operator): New function.
14019 (Verify_Overriding_Indicator): Add missing code to check overriding
14020 indicator in operators. Fixes regression.
14021 (Check_Overriding_Indicator): Minor reformating after replacing the
14022 code that evaluates if the subprogram can override an operator by
14023 invocations to the above new function.
14024 * einfo.adb
14025 (Write_Field26_Name): Add missing code to ensure that, following
14026 the documentation in einfo.ads, this field is not shown as attribute
14027 "Static_Initialization" on non-dispatching functions.
14028
140292011-08-02 Jose Ruiz <ruiz@adacore.com>
14030
14031 * sem_res.adb (Resolve_Call): A call to
14032 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
14033 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
14034 i.e., when the second parameter is of type Time_Span.
14035
140362011-08-02 Vincent Celier <celier@adacore.com>
14037
14038 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
14039 with an archive instead of -L<library dir> -l<library name>.
14040
140412011-08-02 Ed Schonberg <schonberg@adacore.com>
14042
14043 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
14044 mark the base types In_Use in addition to making the operations
14045 use_visible.
14046
140472011-08-02 Ed Falis <falis@adacore.com>
14048
14049 * init.c: add and setup __gnat_signal_mask for the exception signals
14050 * s-inmaop-vxworks.adb: new file.
14051 * s-intman-vxworks.adb: remove unnecessary initializations and
14052 simplify remaining
14053 * s-intman-vxworks.ads: remove unnecessary variable
14054 * s-taprop-vxworks.adb: simplify signal initialization
14055
780d052e
RD
140562011-08-02 Robert Dewar <dewar@adacore.com>
14057
14058 * sem_ch8.adb: Minor code reorganization, comment updates.
14059
140602011-08-02 Robert Dewar <dewar@adacore.com>
14061
14062 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
14063 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
14064 here from Sem_Res.
14065 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
14066 (Matching_Static_Array_Bounds): Moved here from Sem_Res
14067
29efbb8c
ES
140682011-08-02 Ed Schonberg <schonberg@adacore.com>
14069
14070 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
14071 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
14072 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
14073 use_type_clauses, to handle more efficiently use_type and use_all_type
14074 constructs.
14075 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
14076 Ada2012 Use_All_Type clause.
14077 (Use_Class_Wide_Operations): new procedure.
14078
b0186f71
AC
140792011-08-02 Robert Dewar <dewar@adacore.com>
14080
14081 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
14082 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
14083 expression to expression function.
14084
140852011-08-02 Ed Schonberg <schonberg@adacore.com>
14086
14087 * sem_ch4.adb: transform simple Ada2012 membership into equality only
14088 if types are compatible.
14089
140902011-08-02 Yannick Moy <moy@adacore.com>
14091
14092 * sem_res.adb (Matching_Static_Array_Bounds): new function which
14093 returns True if its argument array types have same dimension and same
14094 static bounds at each index.
14095 (Resolve_Actuals): issue an error in formal mode on actuals passed as
14096 OUT or IN OUT paramaters which are not view conversions in SPARK.
14097 (Resolve_Arithmetic_Op): issue an error in formal mode on
14098 multiplication or division with operands of fixed point types which are
14099 not qualified or explicitly converted.
14100 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
14101 Boolean or array type (except String) operands.
14102 (Resolve_Equality_Op): issue an error in formal mode on equality
14103 operators for array types other than String with non-matching static
14104 bounds.
14105 (Resolve_Logical_Op): issue an error in formal mode on logical operators
14106 for array types with non-matching static bounds. Factorize the code in
14107 Matching_Static_Array_Bounds.
14108 (Resolve_Qualified_Expression): issue an error in formal mode on
14109 qualified expressions for array types with non-matching static bounds.
14110 (Resolve_Type_Conversion): issue an error in formal mode on type
14111 conversion for array types with non-matching static bounds
14112
767bb4e8
AC
141132011-08-02 Robert Dewar <dewar@adacore.com>
14114
14115 * par-ch10.adb: Minor code reorganization (use Nkind_In).
14116
141172011-08-02 Ed Schonberg <schonberg@adacore.com>
14118
14119 * par-ch9.adb: save location of entry for proper error message.
14120
4ac2477e
JM
141212011-08-02 Javier Miranda <miranda@adacore.com>
14122
14123 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
14124 (Use_Full_View) which permits this routine to climb through the
14125 ancestors using the full-view of private parents.
14126 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
14127 Use_Full_View to true in calls to Is_Ancestor.
14128 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
14129 true in call to Is_Ancestor.
14130 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
14131 Use_Full_View to true in call to Is_Ancestor.
14132 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
14133 call to Is_Ancestor.
14134 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
14135 Use_Full_View to true in calls to Is_Ancestor.
14136 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
14137 Make_Select_Specific_Data_Table, Register_Primitive,
14138 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
14139 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
14140 to true in call to Is_Ancestor.
14141 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
14142 Use_Full_View to true in calls to Is_Ancestor.
14143 * exp_cg.adb
14144 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
14145 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
14146
9f90d123
AC
141472011-08-02 Robert Dewar <dewar@adacore.com>
14148
14149 * gnat_rm.texi: Minor reformatting.
14150 * sem_prag.adb: Minor reformatting.
14151
141522011-08-02 Tristan Gingold <gingold@adacore.com>
14153
14154 * vms_data.ads: Add VMS qualifier for -gnateP.
14155
141562011-08-02 Robert Dewar <dewar@adacore.com>
14157
14158 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
14159 * par-ch7.adb (P_Package): Proper placement of aspects for package
14160 decl/instantiation.
14161 * par-endh.adb (Check_End): Ad Is_Sloc parameter
14162 (End_Statements): Add Is_Sloc parameterr
14163 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
14164 (Check_End): Ad Is_Sloc parameter
14165 (End_Statements): Add Is_Sloc parameterr
14166
141672011-08-02 Vincent Celier <celier@adacore.com>
14168
14169 * ug_words: Add VMS qualifier equivalent to -gnateP:
14170 /SYMBOL_PREPROCESSING.
14171
141722011-08-02 Jose Ruiz <ruiz@adacore.com>
14173
14174 * gnat-style.texi: For hexadecimal numeric literals the typical
14175 grouping of digits is 4 to represent 2 bytes.
14176 A procedure spec which is split into several lines is indented two
14177 characters.
14178
141792011-08-02 Yannick Moy <moy@adacore.com>
14180
14181 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
14182 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
14183 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
14184 properly qualified
14185 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
14186 choice in array aggregate
14187 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
14188 mark as ancestor
14189 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
14190 positional and named aggregate for record, or others in record
14191 aggregate, or multiple choice in record aggregate
14192 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
14193 array operands to logical operations AND, OR and XOR do not have the
14194 same static lower and higher bounds
14195 * sem_ch5.adb, sinfo.ads: Correct typos in comments
14196
2933b16c
RD
141972011-08-01 Robert Dewar <dewar@adacore.com>
14198
14199 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
14200 Replaces Last_Source_Node_In_Sequence.
14201 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
14202 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
14203 parens and blank in string (this was inconsistently implemented).
14204 * errout.ads
14205 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
14206 blank in string (this was inconsistently implemented).
14207 * gnat1drv.adb
14208 (Set_Global_Switches): Set formal mode switches appropriately
14209 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
14210 * par-prag.adb
14211 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
14212 call Set_Error_Msg_Lang to set "spark" as language name.
14213 * par.adb: Remove unnecessary call to set formal language for errout
14214 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
14215 appropriately and call Set_Error_Msg_Lang to set "spark" as language
14216 name.
14217 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
14218 calls to it, moved after resolution so that types are known
14219 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
14220 result of concatenation is not of type String
14221 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
14222 concatenation is not properly restricted
14223 * gnat_rm.texi: Add doc on pragma Spark_95.
14224 * gcc-interface/Makefile.in: Remove obsolete target pairs for
14225 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
14226 * gcc-interface/Make-lang.in: Update dependencies.
14227
05dbd302
AC
142282011-08-01 Javier Miranda <miranda@adacore.com>
14229
14230 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
14231 condition that detects if the overridden operation must replace an
14232 existing entity.
14233
142342011-08-01 Javier Miranda <miranda@adacore.com>
14235
14236 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
14237 code declarations inserted by Insert_Actions in each alternative of the
14238 N_Case_Expression node.
14239
142402011-08-01 Robert Dewar <dewar@adacore.com>
14241
14242 * sem_ch6.adb: Minor code reorganization.
14243 * sem_util.adb: Minor reformatting.
14244
af9e051f
PO
142452011-08-01 Pascal Obry <obry@adacore.com>
14246
14247 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
14248 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
14249
1d801f21
AC
142502011-08-01 Yannick Moy <moy@adacore.com>
14251
14252 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
14253 literal or operator symbol which is prefixed
14254 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
14255 mode on access attributes.
14256 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
14257 that concatenation operands are properly restricted in formal mode
14258 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
14259 Analyze_Concatenation_Operand. Issue an error in formal mode if the
14260 result of the concatenation has a type different from String.
14261 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
14262 Analyze_Quantified_Expression, Analyze_Slice,
14263 Analyze_Null): issue an error in formal mode on unsupported constructs
14264 * sem_ch5.adb
14265 (Analyze_Block_Statement): only issue error on source block statement
14266 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
14267 function which returns the last node in a list of nodes for which
14268 Comes_From_Source returns True, if any
14269 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
14270 Last_Source_Node_In_Sequence
14271 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
14272 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
14273 mode on unsupported constructs
14274 * sem_ch9.adb Do not return after issuing error in formal mode, as the
14275 rest of the actions may be needed later on since the error is marked as
14276 not serious.
14277 * sinfo.ads: Typos in comments.
14278
142792011-08-01 Pascal Obry <obry@adacore.com>
14280
14281 * projects.texi: Minor editing.
14282
53beff22
YM
142832011-08-01 Yannick Moy <moy@adacore.com>
14284
14285 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
14286 insertion character ~~
14287 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
14288 (Set_Error_Msg_Lang): new procedure which fixes the language for use
14289 with insertion character ~~
14290 (Set_Msg_Text): treat insertion character ~~
14291 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
14292 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
14293 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
14294 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
14295 errors related to the formal language restriction not serious
14296 (insertion character |).
14297 * par.adb (Par): set formal language for error messages if needed
14298 * sem_ch6.adb (Check_Missing_Return): take into account possible
14299 generated statements at the end of the function
14300 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
14301 enumeration value to define a new pragma SPARK_95
14302 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
14303 SPARK_Version): new type and variables to store the SPARK version
14304 (none by default).
14305 (SPARK_Mode): return True when SPARK_Version is set
14306 * par-prag.adb: Correct indentation
14307 (Prag): take Pragma_SPARK_95 into account
14308 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
14309 into account.
14310
8d606a78
RD
143112011-08-01 Robert Dewar <dewar@adacore.com>
14312
14313 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
14314 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
14315 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
14316
1982d5a8
PO
143172011-08-01 Pascal Obry <obry@adacore.com>
14318
14319 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
14320 Target_Name to Get_Path call.
14321 (Parse_Single_Project): Likewise.
14322 (Post_Parse_Context_Clause): Likewise.
14323 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
14324 Call Initialise_Project_Path with the proper Target_Name.
14325 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
14326 search path.
14327 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
14328 with the proper Target_Name.
14329 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
14330 Part.Parse routine.
14331 (Parse_Project_And_Apply_Config): Likewise.
14332 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
14333 This is fine as this part of the code is supporting only native
14334 compilation.
14335 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
14336 is fine as this part of the code is supporting only native compilation.
14337
0d53d36b
AC
143382011-08-01 Yannick Moy <moy@adacore.com>
14339
14340 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
14341 of homonym, unless the homonym is one of the cases allowed in SPARK
14342 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
14343 package declaration occurring after a body.
14344
143452011-08-01 Robert Dewar <dewar@adacore.com>
14346
14347 * checks.adb, exp_ch4.adb: Minor reformatting.
14348
143492011-08-01 Javier Miranda <miranda@adacore.com>
14350
14351 * einfo.ads (Access_Disp_Table): Fix documentation.
14352 (Dispatch_Table_Wrappers): Fix documentation.
14353
143542011-08-01 Pascal Obry <obry@adacore.com>
14355
14356 * prj-env.adb, prj-env.ads: Minor reformatting.
14357
8ed68165
AC
143582011-08-01 Yannick Moy <moy@adacore.com>
14359
14360 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
14361 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
14362 procedures out of these packages.
2c7f9cc0 14363 * errout.ads, errout.adb
8ed68165
AC
14364 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
14365 procedures in of this package
14366 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
14367 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
14368 on misplaced later vs initial declarations, like in Ada 83
14369 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
14370 formal mode on attribute of private type whose full type declaration
14371 is not visible
14372 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
14373 package declaration inside a package specification
14374 (Analyze_Full_Type_Declaration): issue error in formal mode on
14375 controlled type or discriminant type
14376 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
14377 user-defined operator means that it should come from the source
14378 (New_Overloaded_Entity): issue error in formal mode on overloaded
14379 entity.
14380 * sem_ch6.ads, sem_ch13.ads: typos in comments.
14381
143822011-08-01 Thomas Quinot <quinot@adacore.com>
14383
14384 * atree.adb: Minor reformatting.
14385 * checks.adb: Minor reformatting.
14386
4230bdb7
AC
143872011-08-01 Vincent Celier <celier@adacore.com>
14388
14389 * s-parame-vms-ia64.ads: Fix typo in comment
14390 Minor reformatting
14391 * s-parame-vms-restrict.ads: Removed, unused.
14392
143932011-08-01 Javier Miranda <miranda@adacore.com>
14394
14395 * exp_ch3.adb
14396 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
14397 * sem_ch3.adb
14398 (Constrain_Index): Remove side effects in the evaluation of the bounds.
14399 * sem_ch3.ads, sem_ch3.adb
14400 (Is_Constant_Bound): New extended version of the subprogram that was
14401 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
14402 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
14403 * sem_aux.ads (Constant_Value): Fix typo in comment.
14404 * checks.adb (Generate_Index_Checks): New implementation which, for
14405 array objects with constant bounds, generates the runtime check
14406 referencing the bounds of the array type. For other cases this routine
14407 provides its previous behavior obtaining such values from the array
14408 object.
14409 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
14410 parent type.
14411 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
14412 we cannot have semantic interpretations of the new node.
14413
2010d078
AC
144142011-08-01 Ed Schonberg <schonberg@adacore.com>
14415
14416 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
14417 expressions.
14418
144192011-08-01 Arnaud Charlet <charlet@adacore.com>
14420
14421 * sem_ch8.adb: Minor code editing.
14422 * s-vxwext.adb: Remove trailing space.
14423 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
14424 consistency with other files.
14425
144262011-08-01 Thomas Quinot <quinot@adacore.com>
14427
14428 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
14429
144302011-08-01 Ed Schonberg <schonberg@adacore.com>
14431
14432 * par-ch10.adb: reject parameterized expressions as compilation unit.
14433 * sem_ch4.adb: handle properly conditional expression with overloaded
14434 then_clause and no else_clause.
14435
144362011-08-01 Tristan Gingold <gingold@adacore.com>
14437
14438 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
14439 like done by System.Aux_DEC.
14440 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
14441
daec8eeb
YM
144422011-08-01 Yannick Moy <moy@adacore.com>
14443
14444 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
14445 missing label at end of declaration (subprogram or package)
14446 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
14447 of positional and named parameter association
14448 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
14449 Error_Msg_SP which adds a prefix to the error message giving the name
14450 of the formal language analyzed
14451 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
14452 access result type in subprogram, unconstrained array as result type,.
14453 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
14454 procedure
14455 * sem_ch8.adb: Code clean up.
14456
38171f43
AC
144572011-08-01 Javier Miranda <miranda@adacore.com>
14458
14459 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
14460 * einfo.ads (Access_Disp_Table): Fix documentation.
14461 (Dispatch_Table_Wrappers): Fix documentation.
14462 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
14463 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
14464 to enforce the documentation of this attribute.
14465 (Set_Is_Interface): Cleanup the assertion.
14466 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
14467 the Underlying_Type entity before reading attribute Access_Disp_Table.
14468 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
14469 Locate the Underlying_Type before reading attribute Access_Disp_Table.
14470 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
14471 the Underlying_Type entity before reading attribute Access_Disp_Table.
14472 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
14473 Locate the Underlying_Type entity before reading attribute
14474 Access_Disp_Table.
14475
144762011-08-01 Ed Schonberg <schonberg@adacore.com>
14477
14478 * s-poosiz.ads: Additional overriding indicators.
14479
144802011-08-01 Yannick Moy <moy@adacore.com>
14481
14482 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
14483 formal mode.
14484 (Analyze_Iteration_Scheme): issue error in formal mode when loop
14485 parameter specification does not include a subtype mark.
14486 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
14487 formal mode on abstract subprogram.
14488 (Analyze_Subprogram_Specification): issue error in formal mode on
14489 user-defined operator.
14490 (Process_Formals): issue error in formal mode on access parameter and
14491 default expression.
14492 * sem_ch9.adb (Analyze_Abort_Statement,
14493 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
14494 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
14495 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
14496 Analyze_Requeue, Analyze_Selective_Accept,
14497 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
14498 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
14499 issue error in formal mode on user-defined raise statement.
14500
1f250383
AC
145012011-08-01 Thomas Quinot <quinot@adacore.com>
14502
14503 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
14504 declaration being hidden when overriding an implicit inherited
14505 subprogram.
14506 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
14507 (-gnats), do not complain about a source file that contains only a
14508 pragma No_Body.
14509
145102011-08-01 Ed Schonberg <schonberg@adacore.com>
14511
14512 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
14513 variable if already set.
14514
607d0635
AC
145152011-08-01 Arnaud Charlet <charlet@adacore.com>
14516
14517 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
14518 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
14519 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
14520 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
14521 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
14522 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
14523 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
14524 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
14525 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
14526 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
14527 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
14528 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
14529 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
14530 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
14531 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
14532 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
14533 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
14534 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
14535 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
14536 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
14537 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
14538 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
14539 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
14540 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
14541 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
14542 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
14543 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
14544 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
14545 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
14546 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
14547 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
14548 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
14549 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
14550 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
14551 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
14552 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
14553 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
14554 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
14555 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
14556 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
14557 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
14558 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
14559 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
14560 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
14561 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
14562 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
14563 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
14564 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
14565 s-osinte-mingw.ads: Update to GPLv3 run-time license.
14566 Use GNAT instead of GNARL.
14567
145682011-08-01 Bob Duff <duff@adacore.com>
14569
14570 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
14571 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
14572 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
14573 reformatting.
14574
145752011-08-01 Yannick Moy <moy@adacore.com>
14576
14577 * debug.adb (d.D) reverve flag for the SPARK mode
14578 (d.E) reverve flag for SPARK generation mode
14579 (d.F) reverve flag for Why generation mode
2c7f9cc0 14580 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
607d0635
AC
14581 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
14582 functions which return True when the corresponding modes are set
14583 (Formal_Language): return "spark" or "alfa" when in formal verification
14584 mode.
14585 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
14586 Error_Msg to prefix the error message with a tag giving the formal
14587 language
14588 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
14589 message with a tag giving the formal language
14590 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
14591 block statement
14592 (Analyze_Case_Statement): issue error in formal mode on case statement
14593 with a single "others" case alternative
14594 (Analyze_Exit_Statement): issue errors in formal mode on exit
14595 statements which do not respect SPARK restrictions
14596 (Analyze_Goto_Statement): issue error in formal mode on goto statement
14597 (Check_Unreachable_Code): always issue an error (not a warning) in
14598 formal mode on unreachable code (concerns both code after an infinite
14599 loop and after an unconditional jump, both not allowed in SPARK)
14600 * sem_ch6.adb (Analyze_Return_Statement): add call to
14601 Set_Return_Present for a procedure containing a return statement
14602 (already done for functions in Analyze_Function_Return)
14603 (Analyze_Function_Return): issue error in formal mode on extended
14604 return or if return is not last statement in function
14605 (Check_Missing_Return): issue error in formal mode if function does
14606 not end with return or if procedure contains a return
14607 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
14608 function to detect if there is an inner scope of its parameter S which
14609 is a loop.
14610
146112011-08-01 Thomas Quinot <quinot@adacore.com>
14612
14613 * sem_ch6.ads: Minor reformatting.
14614
d8b3ccb9
AC
146152011-08-01 Javier Miranda <miranda@adacore.com>
14616
14617 * sem_util.adb (Abstract_Interface_List): Complete condition when
14618 processing private type declarations to avoid reading unavailable
14619 attribute.
14620 (Is_Synchronized_Tagged_Type): Complete condition when processing
14621 private extension declaration nodes to avoid reading unavailable
14622 attribute.
14623
146242011-08-01 Thomas Quinot <quinot@adacore.com>
14625
14626 * sem_ch3.adb: Minor reformatting.
14627
146282011-08-01 Thomas Quinot <quinot@adacore.com>
14629
14630 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
14631 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
14632 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
14633 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
14634 for VMS, instead parametrize the common implementation with
14635 System.Parameters declarations.
14636
0bb9276c
AC
146372011-08-01 Eric Botcazou <ebotcazou@adacore.com>
14638
14639 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
14640
146412011-08-01 Tristan Gingold <gingold@adacore.com>
14642
14643 * seh_init.c: Fix SEH handler installation on win64.
14644
146452011-08-01 Ed Schonberg <schonberg@adacore.com>
14646
14647 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
14648 double analysis of an anonymous access to subprogram, because it can
14649 lead to improper sharing of profiles and a back-end crash.
14650
6a2e4f0b
AC
146512011-08-01 Robert Dewar <dewar@adacore.com>
14652
14653 * make.adb, sem_ch4.adb: Minor reformatting.
14654 * gcc-interface/Make-lang.in: Update dependencies.
14655 * sem_util.adb, exp_ch5.adb: Minor reformatting.
14656
146572011-08-01 Arnaud Charlet <charlet@adacore.com>
14658
14659 * gnat_rm.texi: Fix definition of Long_Integer.
14660
146612011-08-01 Ed Schonberg <schonberg@adacore.com>
14662
14663 * exp_aggr.adb: check limit size of static aggregate unconditionally,
14664 to prevent storage exhaustion.
14665 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
14666 finalized is a function body, insert the cleanup code before the final
14667 return statement, to prevent spurious warnings.
14668 * s-pooglo.ads: add overriding indicator.
14669
4561baf7
ES
146702011-08-01 Ed Schonberg <schonberg@adacore.com>
14671
14672 * sem_ch4.adb (Operator_Check): improve error message when both a
14673 with_clause and a use_clause are needed to make operator usage legal.
14674 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
14675 determine whether a compilation unit is visible within an other,
14676 either through a with_clause in the current unit, or a with_clause in
14677 its library unit or one one of its parents.
14678
383e179e
AC
146792011-08-01 Ed Schonberg <schonberg@adacore.com>
14680
14681 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
14682 over an arbitrary expression of an array or container type.
14683 * lib-xref.adb: clarify comment.
14684
146852011-08-01 Bob Duff <duff@adacore.com>
14686
14687 * einfo.ads: Minor reformatting.
14688 * debug.adb: Minor comment improvement.
14689
146902011-08-01 Javier Miranda <miranda@adacore.com>
14691
14692 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
14693 consider hidden subprograms as valid candidates.
14694
146952011-08-01 Arnaud Charlet <charlet@adacore.com>
14696
14697 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
14698
146992011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
14700
14701 * gnat_ugn.texi: Fix typo.
14702
61c161b2
AC
147032011-08-01 Robert Dewar <dewar@adacore.com>
14704
14705 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
14706 lib-xref.adb: Minor reformatting
14707
147082011-08-01 Gary Dismukes <dismukes@adacore.com>
14709
14710 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
14711 when to generate a call to Move_Final_List.
14712 (Has_Controlled_Parts): Remove this function.
14713
84df40f7
AC
147142011-08-01 Geert Bosch <bosch@adacore.com>
14715
14716 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
14717 "," in choice list.
14718
147192011-08-01 Thomas Quinot <quinot@adacore.com>
14720
14721 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
14722 explicit raise of a predefined exception as Comes_From_Source if the
14723 original N_Raise_Statement comes from source.
14724
147252011-08-01 Robert Dewar <dewar@adacore.com>
14726
14727 * sinfo.ads: Add comment.
14728 * sem_ch6.adb: Minor reformatting.
14729
147302011-08-01 Robert Dewar <dewar@adacore.com>
14731
14732 * freeze.adb (Freeze_Entity): Refine check for bad component size
14733 clause to avoid rejecting confirming clause when atomic/aliased present.
14734
147352011-08-01 Ed Schonberg <schonberg@adacore.com>
14736
14737 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
14738 better determine whether an entity reference is a write.
14739 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
14740 subcomponent.
14741 * lib-xref.adb (Output_References): Do no suppress a read reference at
14742 the same location as an immediately preceeding modify-reference, to
14743 handle properly in-out actuals.
14744
147452011-08-01 Tristan Gingold <gingold@adacore.com>
14746
14747 * env.c (__gnat_setenv) [VMS]: Refine previous change.
14748
147492011-08-01 Quentin Ochem <ochem@adacore.com>
14750
14751 * i-cstrin.adb (New_String): Changed implementation, now uses only the
14752 heap to compute the result.
14753
c7f0d2c0
AC
147542011-08-01 Robert Dewar <dewar@adacore.com>
14755
14756 * atree.ads: Minor reformatting.
14757
147582011-08-01 Emmanuel Briot <briot@adacore.com>
14759
14760 * g-expect.adb (Get_Command_Output): Fix memory leak.
14761
147622011-08-01 Geert Bosch <bosch@adacore.com>
14763
14764 * cstand.adb (P_Float_Type): New procedure to print the definition of
14765 predefined fpt types.
14766 (P_Mixed_Name): New procedure to print a name using mixed case
14767 (Print_Standard): Use P_Float_Type for printing floating point types
14768 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
14769 precision IEEE float.
14770
147712011-08-01 Thomas Quinot <quinot@adacore.com>
14772
14773 * sem_ch3.adb: Minor reformatting.
14774
147752011-08-01 Ed Schonberg <schonberg@adacore.com>
14776
14777 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
14778 the completion of a generic function, insert the new body rather than
14779 rewriting the original.
14780
147812011-08-01 Yannick Moy <moy@adacore.com>
14782
14783 * sinfo.ads, errout.ads: Typos in comments.
14784
1c54829e
AC
147852011-08-01 Robert Dewar <dewar@adacore.com>
14786
14787 * par-endh.adb: Minor reformatting.
14788
147892011-08-01 Robert Dewar <dewar@adacore.com>
14790
14791 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
14792 (Pre_Post_Aspects): New subtype.
14793 * par-ch12.adb (P_Generic): New syntax for aspects in packages
14794 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
14795 * par-ch7.adb (P_Package): Remove Decl parameter
14796 (P_Package): Handle new syntax for aspects (before IS)
14797 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
14798 new aspect syntax
14799 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
14800 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
14801 (P_Package): Remove Decl parameter
14802 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
14803 aspects
14804 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
14805 specs
14806 * sem_util.ads, sem_util.adb (Static_Boolean): New function
14807 * sinfo.ads: Document new syntax for aspects in packages etc.
14808 * sprint.adb: Handle new syntax of aspects before IS in package
14809
148102011-08-01 Thomas Quinot <quinot@adacore.com>
14811
14812 * atree.ads: Minor reformatting.
14813 * sem_prag.adb: Minor reformatting.
14814
148152011-08-01 Robert Dewar <dewar@adacore.com>
14816
14817 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
14818 case expr alternative.
14819
148202011-08-01 Ed Schonberg <schonberg@adacore.com>
14821
14822 * sem_ch12.adb: Fix typo.
14823
9eea4346
GB
148242011-08-01 Geert Bosch <bosch@adacore.com>
14825
14826 * sem_prag.adb (Check_No_Link_Name): New procedure.
14827 (Process_Import_Or_Interface): Use Check_No_Link_Name.
14828 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
14829 instead of Standard_Long_Long_Float_Size global. Preparation for
14830 eventual removal of per type constants.
14831 * exp_util.ads (Get_Stream_Size): New function returning the stream
14832 size value of subtype E.
14833 * exp_util.adb (Get_Stream_Size): Implement new function.
14834 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
14835 function.
14836 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
14837 * einfo.adb:
14838 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
14839
3d6c3bd7
GB
148402011-08-01 Geert Bosch <bosch@adacore.com>
14841
14842 * cstand.adb: Fix comments.
14843 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
14844 count of arguments.
14845
e7d897b8
AC
148462011-08-01 Robert Dewar <dewar@adacore.com>
14847
14848 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
14849
148502011-08-01 Geert Bosch <bosch@adacore.com>
14851
14852 * atree.ads: Fix comment.
14853
c228a069
AC
148542011-08-01 Robert Dewar <dewar@adacore.com>
14855
14856 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
14857 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
14858 * par.adb: Add with for Namet.Sp.
14859 * par-tchk.adb: Minor reformatting.
14860
148612011-08-01 Vincent Celier <celier@adacore.com>
14862
14863 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
14864 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
14865 of the init procedure of a SAL.
14866 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
14867 New procedure.
14868
148692011-08-01 Thomas Quinot <quinot@adacore.com>
14870
14871 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
14872 reformatting.
14873
148742011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
14875
14876 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
14877
148782011-08-01 Thomas Quinot <quinot@adacore.com>
14879
14880 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
14881 conformant with its spec (return True only for types that have
14882 an overriding Initialize primitive operation that prevents them from
14883 having preelaborable initialization).
14884 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
14885 initialization for controlled types in Ada 2005 or later mode.
14886
857ade1b
RD
148872011-08-01 Robert Dewar <dewar@adacore.com>
14888
14889 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
14890 Postcondition.
14891 (Same_Aspect): New function.
14892 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
14893 Type_Invariant, Precondition, Postcondition.
14894 * snames.ads-tmpl: Add Name_Type_Invariant.
14895
bd949ee2
RD
148962011-08-01 Robert Dewar <dewar@adacore.com>
14897
14898 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
14899 here.
14900 (Freeze_All_Ent): Fix error in handling inherited aspects.
14901 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
14902 already analyzed, but don't skip entire processing of a declaration,
14903 that's wrong in some cases of declarations being rewritten.
14904 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
14905 Don't delay for integer, string literals
14906 Treat predicates in usual manner for delay, remove special case code,
14907 not needed.
14908 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
14909 (Build_Predicate_Function): Update saved expression in aspect
14910 (Build_Invariant_Procedure): Update saved expression in aspect
14911 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
14912 of replacement of discriminant references if the reference is simple.
14913
f1c952af
RD
149142011-08-01 Robert Dewar <dewar@adacore.com>
14915
14916 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
14917 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
14918 Static_Predicate and Dynamic_Predicate.
14919 (Build_Predicate_Function): Add processing for Static_Predicate
14920 and Dynamic_Predicate.
14921 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
14922 (From_Static_Predicate): New flag
14923 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
14924
149252011-08-01 Robert Dewar <dewar@adacore.com>
14926
14927 * usage.adb: Documentation cleanup for Ada version modes in usage.
14928 * expander.adb: Minor reformatting.
14929
47e11d08
AC
149302011-08-01 Robert Dewar <dewar@adacore.com>
14931
14932 * atree.ads: Minor comment fix.
14933 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
14934 a-witeio.ads, sem_prag.adb: Minor reformatting.
14935
149362011-08-01 Doug Rupp <rupp@adacore.com>
14937
14938 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
14939 pointers. Use descrip.h header file for convenience. Add some
14940 comments.
14941
149422011-08-01 Robert Dewar <dewar@adacore.com>
14943
14944 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
14945 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
14946 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
14947 New procedure.
14948 (Check_Aspect_At_End_Of_Declarations): New procedure
14949 (Analye_Aspect_Specification): Minor changes for above procedures
14950 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
14951 specification node as well.
14952
149532011-08-01 Pascal Obry <obry@adacore.com>
14954
14955 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
14956 Windows files. Use GetFilesAttributes() in this case to check for file
14957 existence instead of returning with an error code.
14958
a3a16b21
VC
149592011-08-01 Vincent Celier <celier@adacore.com>
14960
14961 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
14962 High is above Source length.
14963
ff58cc69
RD
149642011-08-01 Robert Dewar <dewar@adacore.com>
14965
14966 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
14967
6bb88533
AC
149682011-08-01 Robert Dewar <dewar@adacore.com>
14969
14970 * aspects.ads (Boolean_Aspects): New subtype.
14971 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
14972 for derived types in cases where the parent type and derived type have
14973 aspects.
14974 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
14975 with aspects when parent type also has aspects.
14976 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
14977 boolean expression at this point).
14978 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
14979 accordance with final decision on the Ada 2012 feature.
14980 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
14981
149822011-08-01 Matthew Heaney <heaney@adacore.com>
14983
14984 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
14985
060a3f28
AC
149862011-08-01 Pascal Obry <obry@adacore.com>
14987
14988 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
14989 Fix Replace_Slice when High is above current string size.
14990 (Replace_Slice): Fix DL computation when High is above current
14991 string length.
14992
149932011-08-01 Gary Dismukes <dismukes@adacore.com>
14994
14995 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
14996
e7f567a3
AC
149972011-08-01 Matthew Heaney <heaney@adacore.com>
14998
14999 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
15000 of node.
15001
150022011-08-01 Pascal Obry <obry@adacore.com>
15003
15004 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
15005 reformatting.
15006
1a265e78
AC
150072011-08-01 Ed Schonberg <schonberg@adacore.com>
15008
15009 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
15010 access to protected subprograms in generic bodies.
15011 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
15012 protected type, indicate that the convention of the subprogram is
15013 Convention_Protected, because it may be used in subsequent declarations
15014 within the protected declaration.
15015
150162011-08-01 Vincent Celier <celier@adacore.com>
15017
15018 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
15019 and "final" procedures when the name of the library is "ada", to avoid
15020 duplicate symbols "adainit" and "adafinal" in executables.
15021
67e28ef8
ES
150222011-08-01 Ed Schonberg <schonberg@adacore.com>
15023
15024 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
15025 quantified expression that appears within a postcondition and uses the
15026 Ada2012 'Result attribute.
15027
6da2ca7d
RO
150282011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15029
15030 * init.c (__gnat_error_handler): Cast reason to int.
15031 (__gnat_install_handler): Explain sa_sigaction use.
15032
7d5997c6
EB
150332011-07-24 Eric Botcazou <ebotcazou@adacore.com>
15034
15035 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
15036 subprogram has copy-in copy-out parameters, try to promote the mode of
15037 the return type if it is passed in registers.
15038
4b4cfdd5
EB
150392011-07-24 Eric Botcazou <ebotcazou@adacore.com>
15040
15041 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
15042 left operand as addressable.
15043
f3d34576
EB
150442011-07-24 Eric Botcazou <ebotcazou@adacore.com>
15045
15046 * gcc-interface/gigi.h (build_function_stub): Remove.
15047 (build_return_expr): Likewise.
15048 (convert_vms_descriptor): Declare.
15049 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
15050 (build_function_stub): Move to...
15051 * gcc-interface/utils2.c (build_return_expr): Move to...
15052 * gcc-interface/trans.c (build_function_stub): ...here.
15053 (build_return_expr): ...here.
15054 (Subprogram_Body_to_gnu): Add local variable for language_function.
15055 Disconnect the parameter attributes cache, if any, once done with it.
15056 Call end_subprog_body only after setting the end_locus.
15057 Build the stub associated with the function, if any, at the very end.
15058 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
15059 variables and streamline control flow.
15060
0a6ecc08
AC
150612011-07-23 Arnaud Charlet <charlet@adacore.com>
15062
15063 PR ada/49819
15064 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
15065 g-trasym-dwarf.adb.
15066
5b6d595b
RO
150672011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15068
15069 PR bootstrap/49794
15070 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
15071 Assign to act.sa_sigaction.
15072 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
15073 current->return_address to char * before arithmetic.
15074
94017021
RO
150752011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15076
15077 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
15078 Correct argument types.
15079 Extract code from reason.
15080 (__gnat_install_handler): Assign to act.sa_sigaction.
15081
52fd02bb
EB
150822011-07-21 Eric Botcazou <ebotcazou@adacore.com>
15083
15084 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
15085 (GNAT1_OBJS): ...here.
15086
f39a9ca2
EB
150872011-07-15 Eric Botcazou <ebotcazou@adacore.com>
15088
15089 PR ada/48711
15090 * g-socthi-mingw.adb (Fill): Fix formatting.
15091
9e36aa23
EB
15092 * gcc-interface/gigi.h: Move around comment.
15093
e3aca522
JDA
150942011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
15095
15096 PR ada/46350
15097 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
15098
696b1960
FW
150992011-07-14 Florian Weimer <fw@deneb.enyo.de>
15100
15101 PR ada/48711
15102 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
15103
f542c405
EB
151042011-07-13 Eric Botcazou <ebotcazou@adacore.com>
15105
15106 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
15107 range comparison if Pmode is SImode.
15108
9e9bd455
LG
151092011-07-12 Laurent GUERBY <laurent@guerby.net>
15110 Eric Botcazou <ebotcazou@adacore.com>
15111
15112 * adadecode.c: Wrap up in extern "C" block.
15113 * adadecode.h: Likewise.
15114 * adaint.c: Likewise. Remove 'const' keyword.
15115 * adaint.h: Likewise.
15116 * argv.c: Likewise.
15117 * atree.h: Likewise.
15118 * cio.c: Likewise.
15119 * cstreams.c: Likewise.
15120 * env.c: Likewise.
15121 * exit.c: Likewise.
15122 * fe.h: Likewise.
15123 * final.c: Likewise.
15124 * init.c: Likewise.
15125 * initialize.c: Likewise.
15126 * link.c: Likewise.
15127 * namet.h: Likewise.
15128 * nlists.h: Likewise.
15129 * raise.c: Likewise.
15130 * raise.h: Likewise.
15131 * repinfo.h: Likewise.
15132 * seh_init.c: Likewise.
15133 * targext.c: Likewise.
15134 * tracebak.c: Likewise.
15135 * uintp.h: Likewise.
15136 * urealp.h: Likewise.
15137 * xeinfo.adb: Wrap up generated C code in extern "C" block.
15138 * xsinfo.adb: Likewise.
15139 * xsnamest.adb: Likewise.
15140 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
15141 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
15142 * gcc-interface/misc.c: Likewise.
15143 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
15144 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
15145 ada/targext.o here...
15146 (GNAT_ADA_OBJS): ...and not here.
15147 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
15148 (GNATBIND_OBJS): Reorder.
15149
7644b3c7
RH
151502011-07-07 Richard Henderson <rth@redhat.com>
15151
15152 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
15153 dwarf2out_frame_init.
15154
8384ac41
EB
151552011-07-07 Eric Botcazou <ebotcazou@adacore.com>
15156
15157 * gcc-interface/misc.c (gnat_init): Tweak previous change.
15158
fbdd5d87
RO
151592011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15160
15161 PR target/39150
15162 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
15163
1a072294
RG
151642011-07-06 Richard Guenther <rguenther@suse.de>
15165
8384ac41
EB
15166 * gcc-interface/misc.c (gnat_init): Merge calls to
15167 build_common_tree_nodes and build_common_tree_nodes_2.
1a072294
RG
15168 Re-initialize boolean_false_node.
15169
bc712852
EB
151702011-07-02 Eric Botcazou <ebotcazou@adacore.com>
15171 Olivier Hainque <hainque@adacore.com>
15172 Nicolas Setton <setton@adacore.com>
15173
15174 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
15175 the type according to the ARTIFICIAL_P parameter.
15176 (create_type_decl): Likewise.
15177 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
15178
2eb22389
EB
151792011-07-01 Eric Botcazou <ebotcazou@adacore.com>
15180
15181 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
15182 (gnatbind): Likewise.
15183
4bdaaf2f
RO
151842011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15185
15186 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
15187
c020c92b
EB
151882011-06-18 Eric Botcazou <ebotcazou@adacore.com>
15189
15190 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
15191 local variable throughout. Remove useless call to Base_Type.
15192 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
15193 Take it also into account for the volatileness of the field. Set the
15194 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
15195
96769d32
EB
151962011-06-18 Eric Botcazou <ebotcazou@adacore.com>
15197
15198 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
15199 on a dereference built for a by-ref object if it has an address clause.
15200
7e4680c1
EB
152012011-06-18 Eric Botcazou <ebotcazou@adacore.com>
15202
15203 * einfo.ads (Address_Taken): Document use for the second argument of
15204 Asm_Input and Asm_Output attributes.
15205 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
15206 argument is an entity name, then set Address_Taken on it.
15207 <Attribute_Asm_Output>: Likewise.
15208 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
15209 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
15210 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
15211 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
15212
152132011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
d5cc9181
JR
15214
15215 PR middle-end/46500
15216 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
15217
677f3fa8
JM
152182011-06-14 Joseph Myers <joseph@codesourcery.com>
15219
15220 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
15221 (ada/utils.o): Update dependencies.
15222 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
15223 ../../../libcpp/libcpp.a.
15224 * gcc-interface/utils.c: Include common/common-target.h.
15225 (process_attributes): Use targetm_common.have_named_sections.
15226
009db074
RG
152272011-06-07 Richard Guenther <rguenther@suse.de>
15228
0bad0e23
EB
15229 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
15230 set_sizetype.
009db074 15231
3bfc61cf
EB
152322011-06-06 Eric Botcazou <ebotcazou@adacore.com>
15233
0bad0e23 15234 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
3bfc61cf
EB
15235 TREE_THIS_NOTRAP flag.
15236
5c4a1c7b
EB
152372011-06-06 Eric Botcazou <ebotcazou@adacore.com>
15238
15239 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
15240 Fix thinko.
15241
e9f57686
EB
152422011-06-06 Eric Botcazou <ebotcazou@adacore.com>
15243
15244 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
15245 constants whose full view has discriminants specially.
15246
10e4d056
EB
152472011-06-06 Eric Botcazou <ebotcazou@adacore.com>
15248
15249 * gcc-interface/utils.c: Include diagnostic.h.
15250 (gnat_write_global_declarations): Output debug information for all
15251 global type declarations before finalizing the compilation unit.
15252 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
15253
0957c029
JJ
152542011-05-25 Jakub Jelinek <jakub@redhat.com>
15255
15256 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
15257
52d0a7ac
KT
152582011-05-25 Kai Tietz <ktietz@redhat.com>
15259
15260 * adaint.c (__gnat_to_canonical_file_list_next): Use array
15261 initialization instead of const/none-const pointer assignment.
15262
1ed1641d
JM
152632011-05-24 Joseph Myers <joseph@codesourcery.com>
15264
15265 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
15266 $(EXTRA_GNAT1_OBJS).
15267 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
15268 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
15269 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
15270 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
15271 libcommon-target.a instead of prefix.o.
15272
9fe72ebd
JM
152732011-05-21 Joseph Myers <joseph@codesourcery.com>
15274
15275 PR ada/49097
0bad0e23 15276 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
9fe72ebd 15277
2691e6d7
JM
152782011-05-20 Joseph Myers <joseph@codesourcery.com>
15279
0bad0e23
EB
15280 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
15281 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
15282 instead of version.o.
2691e6d7 15283
2d0dd51a 152842011-05-18 Kai Tietz <ktietz@redhat.com>
bf6490b5
KT
15285
15286 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
15287 boolean_false_node instead of integer_zero_node.
15288 (convert_with_check): Likewise.
15289 * gcc-interface/decl.c (choices_to_gnu): Likewise.
15290
7bf9a5ac
EB
152912011-05-12 Eric Botcazou <ebotcazou@adacore.com>
15292
15293 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
15294 type of the parameter is an unconstrained array, convert the actual to
15295 the type of the formal in the In Out and Out cases as well.
15296
e5b00edf
NF
152972011-05-11 Nathan Froyd <froydnj@codesourcery.com>
15298
15299 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
15300 call build_function_type_array or build_varargs_function_type_array
15301 instead.
15302 (create_subprog_type): Don't call build_function_type; call
15303 build_function_type_vec instead.
15304
51545682
NF
153052011-05-11 Nathan Froyd <froydnj@codesourcery.com>
15306
15307 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
15308 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
15309 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
15310
c99c0026
EB
153112011-05-07 Eric Botcazou <ebotcazou@adacore.com>
15312
f620bd21
EB
15313 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
15314
c99c0026
EB
15315 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
15316 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
15317
3d528853
NF
153182011-05-05 Nathan Froyd <froydnj@codesourcery.com>
15319
c99c0026 15320 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
3d528853 15321
d7d058c5
NF
153222011-05-05 Nathan Froyd <froydnj@codesourcery.com>
15323
15324 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
15325 instead of accessing TYPE_ARG_TYPES directly.
15326 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
15327
805e60a0
EB
153282011-05-05 Eric Botcazou <ebotcazou@adacore.com>
15329
15330 PR ada/48844
15331 * gcc-interface/gigi.h (get_variant_part): Declare.
15332 * gcc-interface/decl.c (get_variant_part): Make global.
15333 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
15334 types have the same constant size, are record types and T1 has a
15335 variant part while T2 doesn't.
15336
907a08d9
EB
153372011-05-05 Eric Botcazou <ebotcazou@adacore.com>
15338
15339 * gcc-interface/utils.c (begin_subprog_body): Do not call
15340 get_pending_sizes.
15341 (end_subprog_body): Likewise.
15342
d35936ab
RG
153432011-05-04 Richard Guenther <rguenther@suse.de>
15344
15345 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
15346 int_const_binop.
15347 (pos_to_constructor): Likewise.
15348
c1fd8753 153492011-05-03 Nathan Froyd <froydnj@codesourcery.com>
2c7f9cc0 15350 Eric Botcazou <ebotcazou@adacore.com>
c1fd8753
NF
15351
15352 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
15353 of build_function_type. Adjust calls to...
15354 (build_raise_check): ...this. Do not take a void_tree parameter.
15355 Call build_function_type_list instead of build_function_type.
15356 Fix head comment and swap couple of conditional blocks.
15357
4fb87d2b
EB
153582011-04-30 Eric Botcazou <ebotcazou@adacore.com>
15359
15360 * gnatvsn.ads (Library_Version): Bump to 4.7.
15361 (Current_Year): Bump to 2011.
15362
fa5e5a76
MM
153632011-04-29 Michael Matz <matz@suse.de>
15364
15365 * gcc-interface/misc.c (gnat_handle_option): Set
15366 warn_maybe_uninitialized.
15367
8d6a2f69
GP
153682011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
15369
15370 * gnat_ugn.texi (Complexity Metrics Control): Update link to
15371 the Watson/McCabe paper.
15372
770937fd
JM
153732011-04-23 Jim Meyering <meyering@redhat.com>
15374
15375 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
15376
eb601ae1
EB
153772011-04-22 Eric Botcazou <ebotcazou@adacore.com>
15378
15379 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
15380 onto the new type.
15381
7d7fcb08
EB
153822011-04-22 Eric Botcazou <ebotcazou@adacore.com>
15383
15384 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
15385 parameter.
15386 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
15387 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
15388 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
15389 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
15390 <all>: Do not set flags on the reused DECL node coming from an alias.
15391 Set DECL_IGNORED_P on the DECL node built for subprograms if they
15392 don't need debug info here...
15393 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
15394 (gigi): Adjust calls to create_subprog_decl.
15395 (build_raise_check): Likewise.
15396 (establish_gnat_vms_condition_handler): Likewise.
15397 (Compilation_Unit_to_gnu): Likewise.
15398 (gnat_to_gnu): Likewise.
15399
e1876cac
EB
154002011-04-21 Eric Botcazou <ebotcazou@adacore.com>
15401
15402 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
15403 (NO_REORDER_ADAFLAGS): New variable.
15404 (EXTRA_GNATTOOLS): Always define.
15405 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
15406 Clean up and adjust list of files compiled with special options.
15407 * gcc-interface/Make-lang.in: Likewise.
15408 (ada/decl.o): Cosmetical change.
15409 (ada/misc.o): Remove dependency on $(PLUGIN_H).
15410
04695783
JM
154112011-04-20 Jim Meyering <meyering@redhat.com>
15412
15413 * initialize.c (__gnat_initialize): Remove useless if-before-free.
15414
23399579
EB
154152011-04-17 Eric Botcazou <ebotcazou@adacore.com>
15416
15417 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
15418 $(CFLAGS) on the link line.
15419
51c5169c
EB
154202011-04-17 Eric Botcazou <ebotcazou@adacore.com>
15421
15422 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
15423 padded type built for the return type if it is unconstrained.
15424
61e46a7d
NF
154252011-04-14 Nathan Froyd <froydnj@codesourcery.com>
15426
15427 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
15428
81f653d6
NF
154292011-04-12 Nathan Froyd <froydnj@codesourcery.com>
15430
b4867846
EB
15431 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
15432 before calling TREE_CHAIN.
81f653d6
NF
15433 * gcc-interface/misc.c (gnat_init_ts): New function.
15434 (LANG_HOOKS_INIT_TS): Define.
15435
a358e188
MJ
154362011-04-12 Martin Jambor <mjambor@suse.cz>
15437
b4867846
EB
15438 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
15439 instead of cgraph_node.
a358e188 15440
29b1c5a4
EB
154412011-04-08 Eric Botcazou <ebotcazou@adacore.com>
15442
15443 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
15444 alignment on fields of the RETURN type built for the Copy-In Copy-Out
15445 mechanism.
15446
88872b00
EB
154472011-04-08 Eric Botcazou <ebotcazou@adacore.com>
15448
15449 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
15450 of aggregate types that contain a placeholder.
15451
dcf0c47e
NF
154522011-04-08 Nathan Froyd <froydnj@codesourcery.com>
15453
15454 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
b4867846 15455 TYPE_ARG_TYPES.
dcf0c47e
NF
15456 (handle_type_generic_attribute): Likewise.
15457
53e3000c
EB
154582011-04-04 Eric Botcazou <ebotcazou@adacore.com>
15459
15460 PR ada/47163
15461 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
15462
ab380bb4
KT
154632011-04-04 Kai Tietz <ktietz@redhat.com>
15464
15465 PR ada/47163
0bad0e23
EB
15466 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
15467 to flag value.
ab380bb4 15468
8ffac116
EB
154692011-04-02 Eric Botcazou <ebotcazou@adacore.com>
15470
15471 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
15472 type case, do not strip a padding type around the array type.
15473
de9528f0
EB
154742011-04-02 Eric Botcazou <ebotcazou@adacore.com>
15475
15476 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
15477 types.
15478
d9d7a26c
EB
154792011-04-02 Eric Botcazou <ebotcazou@adacore.com>
15480
15481 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
15482 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
de9528f0 15483 code for -feliminate-unused-debug-types.
d9d7a26c
EB
15484 (gnat_post_options): Likewise.
15485
4cb12a90
EB
154862011-04-02 Eric Botcazou <ebotcazou@adacore.com>
15487
15488 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
15489 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
15490 distinct copy.
15491
acccc61c
EB
154922011-04-02 Eric Botcazou <ebotcazou@adacore.com>
15493
15494 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
15495 DECL_ARTIFICIAL flag on enumeration types.
15496
583eb0c9
EB
154972011-04-02 Eric Botcazou <ebotcazou@adacore.com>
15498
15499 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
15500 fat pointer types artificial unconditionally.
15501 <E_Array_Subtype>: Attach the base array type as a parallel type if it
15502 isn't artificial.
15503
e3edbd56
EB
155042011-04-02 Eric Botcazou <ebotcazou@adacore.com>
15505
15506 * gcc-interface/gigi.h (get_dummy_type): Declare.
15507 (build_dummy_unc_pointer_types): Likewise.
15508 (finish_fat_pointer_type): Likewise.
15509 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
15510 fat pointer type has been built, complete it in place.
15511 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
15512 and thin pointers. Remove useless variable.
15513 (finish_fat_pointer_type): Make global and move to...
15514 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
15515 (get_dummy_type): New function.
15516 (build_dummy_unc_pointer_types): Likewise.
15517 (gnat_pushdecl): Propage the name to the anonymous variants only.
15518 (update_pointer_to): Only adjust the pointer types in the unconstrained
15519 array case.
15520
65444786
EB
155212011-04-02 Eric Botcazou <ebotcazou@adacore.com>
15522
15523 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
15524 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
15525 if this is a Taft amendment type and the full declaration is available.
15526 * gcc-interface/trans.c (process_type): Likewise.
15527 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
15528 (process_freeze_entity): Likewise.
15529 * gcc-interface/utils.c (dummy_global): New static variable.
15530 (gnat_write_global_declarations): If there are types declared as used
15531 at the global level, insert them in the global hash table.
15532
1aeb40dd
EB
155332011-04-02 Eric Botcazou <ebotcazou@adacore.com>
15534
15535 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
15536 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
15537 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
15538 copy.
15539 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
15540 flag of the type accordingly.
15541 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
15542
80ec8b4c
EB
155432011-04-02 Eric Botcazou <ebotcazou@adacore.com>
15544
15545 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
15546 finalizing types when updating the pointers to the designated type.
15547 <all>: Finalize the deferred types even if we didn't defer processing
15548 of incomplete types in this invocation.
15549
2a9d769a 155502011-04-01 Olivier Hainque <hainque@adacore.com>
2c7f9cc0
AS
15551 Nicolas Setton <setton@adacore.com>
15552 Eric Botcazou <ebotcazou@adacore.com>
2a9d769a
OH
15553
15554 * gcc-interface/misc.c (gnat_descriptive_type): New function.
15555 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
15556
2438d7a6
KT
155572011-03-28 Kai Tietz <ktietz@redhat.com>
15558
333d8aff 15559 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
80ec8b4c
EB
15560 Windows targets.
15561 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
15562 * system-mingw.ads (System): Change ZCX_By_Default default to True.
333d8aff 15563
80ec8b4c 15564 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
2438d7a6 15565
8ad150f6
TG
155662011-03-28 Tristan Gingold <gingold@adacore.com>
15567
15568 PR ada/44431
80ec8b4c
EB
15569 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
15570 Use ada output of gnatbind.
8ad150f6
TG
15571 (ada/b_gnatb.adb): Ditto.
15572 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
15573 (ada.mostlyclean, ada.stage1)
15574 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
15575 (ada.stagefeedback): Adjust.
80ec8b4c 15576 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
8ad150f6
TG
15577 Use ada output of gnatbind.
15578 (b_gnatm.adb): Ditto.
15579 (b_gnatl.o, b_gnatm.o): New rules.
15580
51c7954d
EB
155812011-03-26 Eric Botcazou <ebotcazou@adacore.com>
15582
15583 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
15584 for the padded type built to support a specified size or alignment.
15585
6ddf9843
EB
155862011-03-26 Eric Botcazou <ebotcazou@adacore.com>
15587
15588 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
15589 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
15590 unconditionally to the end of the unit when the designated type is
15591 limited_with'ed.
15592 <all>: Rename local variable. Attempt to un-defer types only and do it
15593 for limited_with'ed types as well.
15594 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
15595 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
15596 consistently and remove redundant call to finalize_from_with_types.
15597
5daed84a
EB
155982011-03-26 Eric Botcazou <ebotcazou@adacore.com>
15599
15600 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
15601 subprograms without a previous spec declared in the same unit.
15602 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
15603 subprograms at the end of the unit instead of at the beginning.
15604 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
15605 isn't public for the special handling of non-inline functions nested
15606 inside inline external functions.
15607
0edf1bb2
JL
156082011-03-25 Jeff Law <law@redhat.com>
15609
5daed84a 15610 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
0edf1bb2 15611
e3c4580e
EB
156122011-03-24 Eric Botcazou <ebotcazou@adacore.com>
15613
15614 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
15615 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
15616 to compute Set_Size_Depends_On_Discriminant.
15617 (Layout_Type): Call it on array types in back-end layout mode.
15618 * sem_util.adb (Requires_Transient_Scope): Return true for array
15619 types only if the size depends on the value of discriminants.
15620 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
15621 type if the RHS is a call to a function that returns an unconstrained
15622 type with default discriminant.
15623
abbc8c7b
EB
156242011-03-24 Eric Botcazou <ebotcazou@adacore.com>
15625
15626 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
15627 non-conversion to the nominal result type at the end.
15628
ddb5a105
EB
156292011-03-23 Eric Botcazou <ebotcazou@adacore.com>
15630
15631 * gcc-interface/trans.c (create_temporary): New function taken from...
15632 (create_init_temporary): ...here. Call it.
15633 (call_to_gnu): Create the temporary for the return value early, if any.
15634 Create it for a function with copy-in/copy-out parameters if there is
15635 no target; in other cases of copy-in/copy-out, use another temporary.
15636 Push the new binding level lazily. Add and rename local variables.
15637
0d853156
EB
156382011-03-23 Eric Botcazou <ebotcazou@adacore.com>
15639
15640 * gcc-interface/decl.c (validate_size): Improve comments and tweak
15641 error message.
15642 (set_rm_size): Likewise.
15643
4184ef1b
EB
156442011-03-23 Eric Botcazou <ebotcazou@adacore.com>
15645
15646 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
15647 for the padded type built in order to support a specified alignment.
15648 Fix incorrect formatting.
15649
bf7eefab
EB
156502011-03-21 Eric Botcazou <ebotcazou@adacore.com>
15651
15652 PR bootstrap/48216
15653 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
15654
ef0feeb2
EB
156552011-03-21 Eric Botcazou <ebotcazou@adacore.com>
15656
15657 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
15658 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
15659 to the end of the list. Adjust recursive call. Rename local variable.
15660 If REORDER is true, reorder components of the record type.
15661 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
15662 components_to_record and adjust the parameter list.
15663
646f9414
EB
156642011-03-21 Eric Botcazou <ebotcazou@adacore.com>
15665
15666 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
15667 disabled, use the variable for bounds of loop iteration scheme.
15668
62d784f7
KT
156692011-03-21 Kai Tietz <ktietz@redhat.com>
15670
15671 PR target/12171
0bad0e23 15672 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
62d784f7 15673
f230d759
EB
156742011-03-17 Eric Botcazou <ebotcazou@adacore.com>
15675
15676 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
15677 out whether the expression is read-only. Short-circuit placeholder
15678 case and rename a couple of local variables.
15679
bb1f7929
EB
156802011-03-17 Eric Botcazou <ebotcazou@adacore.com>
15681
15682 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
15683 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
15684 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
15685 (convert): Deal with conversions from a smaller form type specially.
15686
400a2d24
EB
156872011-02-14 Eric Botcazou <ebotcazou@adacore.com>
15688
15689 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
15690 its argument, except for the special -I- switch.
15691
c26bc3ad
GP
156922011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
15693
0bad0e23
EB
15694 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
15695 "Ada Issues".
c26bc3ad 15696
07b8e910
EB
156972011-02-08 Eric Botcazou <ebotcazou@adacore.com>
15698
15699 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
15700
31a5a547
EB
157012011-02-03 Eric Botcazou <ebotcazou@adacore.com>
15702
15703 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
15704 GNAT_FORMAL.
15705 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
15706 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
15707 instead of GNAT_FORMAL. Protect the expression against multiple uses.
15708 Do not generate the check directly, instead instantiate the template
15709 check present in the descriptor.
15710 (make_descriptor_field): Move around.
15711 (build_vms_descriptor32): Build a template check in the POINTER field.
15712 (build_vms_descriptor): Remove useless suffixes.
15713 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
15714
dcf25f59
EB
157152011-01-26 Eric Botcazou <ebotcazou@adacore.com>
15716
15717 PR bootstrap/47467
15718 * targext.c: Include target files if IN_RTS is defined.
15719
0418e131
RG
157202011-01-26 Richard Guenther <rguenther@suse.de>
15721
15722 PR bootstrap/47467
15723 * targext.c: Include config.h.
15724 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
15725 dependency.
15726
c6eecbd8 157272011-01-04 Pascal Obry <obry@adacore.com>
2c7f9cc0 15728 Eric Botcazou <ebotcazou@adacore.com>
c6eecbd8
PO
15729
15730 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
15731
2d3c7e4f
EB
157322011-01-04 Eric Botcazou <ebotcazou@adacore.com>
15733
15734 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
15735 end-of-case on the end label and its associated gotos, if any.
15736
0394741f
EB
157372011-01-04 Eric Botcazou <ebotcazou@adacore.com>
15738
15739 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
15740 expressions of the parameter cache within the statement group of
15741 the CICO mechanism.
15742
2a02d090 157432011-01-04 Olivier Hainque <hainque@adacore.com>
2c7f9cc0 15744 Eric Botcazou <ebotcazou@adacore.com>
2a02d090
OH
15745
15746 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
15747 (set_end_locus_from_node): New function.
15748 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
15749 make and the function end_locus.
15750 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
15751 for the elaboration subprogram.
15752 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
15753 set the end_locus of the expression as well.
15754
89f5e978
EB
157552011-01-04 Eric Botcazou <ebotcazou@adacore.com>
15756
15757 PR ada/47131
15758 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
15759 variables that are referenced in exception handlers volatile.
15760
15761
ad41bd84 15762\f
797103eb 15763Copyright (C) 2011 Free Software Foundation, Inc.
ad41bd84
JM
15764
15765Copying and distribution of this file, with or without modification,
15766are permitted in any medium without royalty provided the copyright
15767notice and this notice are preserved.