]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/ada/ChangeLog
[multiple changes]
[thirdparty/gcc.git] / gcc / ada / ChangeLog
CommitLineData
9ee76313
AC
12011-11-07 Yannick Moy <moy@adacore.com>
2
3 * sem_util.adb (Note_Possible_Modification): In Alfa mode,
4 generate a reference for a modification even when the modification
5 does not come from source.
6
72011-11-07 Ed Schonberg <schonberg@adacore.com>
8
9 * exp_ch5.adb (Expand_Iterator_Loop): For the "of" iterator form,
10 use the indexing attributes rather than the Element function,
11 to obtain variable references.
12 * sem_ch4.adb (Try_Container_Indexing): Code cleanup. Use
13 Find_Aspect rather than iterating over representation
14 items. Improve error message.
15 * a-cohama.adb, a-cohama.ads Update to latest RM, with two versions
16 of Reference functions.
17
7b7a0c2b
AC
182011-11-07 Yannick Moy <moy@adacore.com>
19
20 * sem_util.adb (Unique_Entity): For a parameter on a subprogram
21 body that has a corresponding parameter on the subprogram
22 declaration, define the unique entity as being the declaration
23 one.
24
252011-11-07 Ed Schonberg <schonberg@adacore.com>
26
27 * sem_ch6.adb (Analyze_Return_Type): In Ada 2012 mode, if the
28 return type of a function is the class-wide type of an incomplete
29 type T, T can be a Taft-amendment type and does not have to be
30 completed in the current private part.
31
322011-11-07 Ed Schonberg <schonberg@adacore.com>
33
34 * aspects.ads (Inherited_Aspect): Map that indicates type aspects
35 that are inherited by default, and apply to the class-wide type
36 as well.
37 * aspects.adb (Find_Aspect): If the entity is class-wide and the
38 aspect is inherited, use the aspect of the specific type.
39
cc570be6
AC
402011-11-07 Hristian Kirtchev <kirtchev@adacore.com>
41
42 * exp_alfa.adb: Remove with and use clause for
43 Exp_Ch8. Add with and use clause for Exp_Util.
44 Remove local constant Disable_Processing_Of_Renamings.
45 (Expand_Alfa_N_Object_Renaming_Declaration): The expansion of
46 object renamings has been reenabled.
47 (Expand_Possible_Renaming):
48 The expansion of identifier and expanded names has been
49 reenabled. Perform the substitutions only for entities that
50 denote an object.
51 * exp_ch8.ads, exp_ch8.adb (Evaluate_Name): Moved to Exp_Util.
52 * exp_util.adb (Evaluate_Name): Moved from Exp_Ch8.
53 (Remove_Side_Effects): Alphabetize local variables. Add a guard
54 to avoid the infinite expansion of an expression in Alfa mode. Add
55 processing for function calls in Alfa mode.
56 * exp_util.ads (Evaliate_Name): Moved from Exp_Ch8.
57
582011-11-07 Ed Schonberg <schonberg@adacore.com>
59
60 * freeze.adb (Freeze_Entity): If the entity is an access to
61 subprogram whose designated type is itself a subprogram type,
62 its own return type must be decorated with size information.
63
b6d185a5
AC
642011-11-04 Arnaud Charlet <charlet@adacore.com>
65
66 * gcc-interface/Make-lang.in: Update dependencies.
67
1adaea16
AC
682011-11-04 Robert Dewar <dewar@adacore.com>
69
70 * sprint.adb (Sprint_Node_Actual, case Qualified_Expression):
71 Avoid junk semicolon after argument of machine code Asm operand.
72
732011-11-04 Robert Dewar <dewar@adacore.com>
74
75 * exp_ch11.adb (Generate_Push_Pop): Inhibit push/pop nodes in
76 CodePeer mode or if restriction No_Exception_Handlers is present.
77 * exp_ch6.adb (Expand_N_Subprogram_Body): (Inhibit push/pop
78 nodes in CodePeer mode or if restriction No_Exception_Handlers
79 is present.
80
812011-11-04 Robert Dewar <dewar@adacore.com>
82
83 * s-tassta.adb, atree.ads, errout.adb, sinput.adb: Minor reformatting.
84
852011-11-04 Ed Schonberg <schonberg@adacore.com>
86
87 * sem_ch6.adb (Analyze_Subprogram_Specification): The
88 specification is legal if it is a function that returns an
89 abstract type, if it comes from an attribute renaming of a stream
90 attribute of an abstract type.
91
922011-11-04 Gary Dismukes <dismukes@adacore.com>
93
94 * exp_util.adb (Is_Possibly_Unaligned_Object): In case of indexed
95 components, check whether recursively check whether the prefix
96 denotes an unaligned object.
97
982011-11-04 Ed Schonberg <schonberg@adacore.com>
99
100 * sem_prag.adb (Analyze_Pragma, case Debug): The argument of
101 the pragma is legal if it is an expanded name that denotes a
102 procedure that be can called without parameters.
103
1042011-11-04 Eric Botcazou <ebotcazou@adacore.com>
105
106 * gnat_ugn.texi (Performance Considerations) <Vectorization
107 of loops>: New sub-section. <Other Optimization Switches>:
108 Minor tweak.
109
4c9fe6c7
AC
1102011-11-04 Robert Dewar <dewar@adacore.com>
111
112 * gnat_rm.texi: Minor reformatting.
113
1142011-11-04 Matthew Heaney <heaney@adacore.com>
115
116 * a-convec.adb, a-coinve.adb, a-cobove.adb (Merge): Raise PE
117 when Target and Source denote same non-empty object
118 * a-cdlili.adb, a-cidlli.adb, a-cbdlli.adb (Merge): Ditto
119
1202011-11-04 Robert Dewar <dewar@adacore.com>
121
122 * exp_attr.adb: Minor reformatting.
123
1242011-11-04 Ed Schonberg <schonberg@adacore.com>
125
126 * exp_ch5.adb (Expand_Assign_Record): Do not generate a
127 discriminant assignment within an initialization proc if the
128 record is an unchecked union, as it can only come from the
129 initialization of an unchecked union component.
130
1312011-11-04 Robert Dewar <dewar@adacore.com>
132
133 * gnat_ugn.texi: Minor reformatting.
134
1352011-11-04 Robert Dewar <dewar@adacore.com>
136
137 * par-labl.adb (Rewrite_As_Loop): Generate info msg rather than
138 warning message.
139
1402011-11-04 Robert Dewar <dewar@adacore.com>
141
142 * exp_ch4.adb: Minor code reorganization (remove junk obsolete
143 var Save_Space).
144
6ec084f3
HK
1452011-11-04 Hristian Kirtchev <kirtchev@adacore.com>
146
147 * exp_alfa.adb: Add local constant
148 Disable_Processing_Of_Renamings;
149 (Expand_Alfa_N_Object_Renaming_Declaration): Disable
150 the name evaluation of object renamings for now.
151 (Expand_Potential_Renaming): Do not perform the substitution
152 for now.
153 * exp_util.adb (Remove_Side_Effects): Remove processing for
154 functions with side effects in Alfa mode.
155
73fe1679
AC
1562011-11-04 Gary Dismukes <dismukes@adacore.com>
157
158 * bindgen.adb (Gen_Elab_Calls): In the case
159 of the AAMP target, set elaboration entities to 1 rather than
160 incrementing.
161
1622011-11-04 Ed Schonberg <schonberg@adacore.com>
163
164 * sem_ch10.adb (Install_Limited_With_Unit): To establish the
165 proper entities on the ancestors of a child unit that appear
166 in a limited_with clause, follow the unit links because the
167 units are not analyzed and scope information is incomplete.
168
1692011-11-04 Eric Botcazou <ebotcazou@adacore.com>
170
171 * exp_ch4.adb (Expand_N_Selected_Component): Refine code
172 setting the Atomic_Sync_Required flag to detect one more case.
173 * exp_util.adb (Activate_Atomic_Synchronization): Refine code
174 setting the Atomic_Sync_Required flag to exclude more cases,
175 depending on the parent of the node to be examined.
176
1772011-11-04 Bob Duff <duff@adacore.com>
178
179 * g-excact.adb: Minor: use named notation.
180
1812011-11-04 Ed Schonberg <schonberg@adacore.com>
182
183 * sem_ch5.adb: Improve error messages for illegal iterators.
184
b2ab8c33
AC
1852011-11-04 Hristian Kirtchev <kirtchev@adacore.com>
186
187 * exp_alfa.adb: Add with and use clauses for Exp_Ch8 and
188 Sem_Util.
189 (Expand_Alfa): Alphabetize cases on first choice. Add
190 processing for object renaming declarations, identifiers and
191 expanded names.
192 (Expand_Alfa_N_In): Remove useless return.
193 (Expand_Alfa_N_Object_Renaming_Declaration): New routine.
194 (Expand_Potential_Renaming): New routine.
195 * exp_ch8.adb (Evaluate_Name): Moved to the top level.
196 (Expand_N_Object_Declaration): Alphabetize local variables. Move
197 Evaluate_Name out to the top level.
198 * exp_ch8.ads (Evaluate_Name): Moved from body to package spec.
199 * exp_util.adb (Remove_Side_Effects): Add processing for
200 functions with side effects in Alfa mode.
201
2022011-11-04 Hristian Kirtchev <kirtchev@adacore.com>
203
204 * gnat_rm.texi: Add entries for
205 restrictions No_Relative_Delay, No_Requeue_Statements and
206 No_Stream_Optimizations.
207
2082011-11-04 Ed Schonberg <schonberg@adacore.com>
209
210 * sem_ch4.adb: Set type of entity in prefixed call, for
211 completeness in a generic context.
212
4c318253
AC
2132011-11-04 Yannick Moy <moy@adacore.com>
214
215 * sem_prag.adb: Minor refactoring (renaming of a parameter).
216
2172011-11-04 Robert Dewar <dewar@adacore.com>
218
219 * atree.ads: Minor reformatting.
220
2212011-11-04 Robert Dewar <dewar@adacore.com>
222
223 * checks.adb (Atomic_Synchronization_Disabled): Check -gnatd.d
224 and -gnatd.e here
225 * exp_ch2.adb (Expand_Entity_Reference): Use
226 Activate_Atomic_Synchronization
227 * exp_ch4.adb (Expand_N_Explicit_Dereference): Use
228 Activate_Atomic_Synchronization (Expand_N_Indexed_Compoonent):
229 Activate_Atomic_Synchronization (Expand_N_Selected_Component):
230 Use Activate_Atomic_Synchronization
231 * exp_util.ads, exp_util.adb (Activate_Atomic_Synchronization): New
232 procedure.
233 * sinfo.ads, sinfo.adb (Atomic_Sync_Required): Can now apply to
234 N_Selected_Component node
235
37765e95
RD
2362011-11-04 Robert Dewar <dewar@adacore.com>
237
238 * sem_prag.adb, atree.ads, prj-env.adb, prj-env.ads: Minor reformatting.
239
8c18a165
AC
2402011-11-04 Yannick Moy <moy@adacore.com>
241
242 * atree.adb, atree.ads (Set_Original_Node): New set procedure.
243 * sem_ch13.adb (Analyze_Aspect_Specifications/Pre_Post_Aspects):
244 In ASIS mode, no splitting of aspects between conjuncts.
245 (Analyze_Aspect_Specifications/Aspect_Test_Case): Make pragma
246 expressions refer to the original aspect expressions through
247 the Original_Node link. This is used in semantic analysis for
248 ASIS mode, so that the original expression also gets analyzed.
249 * sem_prag.adb (Preanalyze_TC_Args,
250 Check_Precondition_Postcondition,
251 Analyze_Pragma/Pragma_Test_Case): In ASIS mode, for a pragma
252 generated from a source aspect, also analyze the original aspect
253 expression.
254 (Check_Expr_Is_Static_Expression): New procedure
255 similar to existing procedure Check_Arg_Is_Static_Expression,
256 except called on expression inside pragma.
257
2582011-11-04 Tristan Gingold <gingold@adacore.com>
259
260 * prj-env.adb, prj-env.ads (Find_Name_In_Path): New function, from
261 Find_Project.Try_Path_Name.
262 (Find_Project): Use Find_Name_In_Path to implement Try_Path_Name.
263
2642011-11-04 Eric Botcazou <ebotcazou@adacore.com>
265
266 * s-atocou.ads (Atomic_Counter): Remove redundant pragma Volatile.
267
2682011-11-04 Pascal Obry <obry@adacore.com>
269
270 * projects.texi: Add short description for qualifiers aggregate
271 and aggregate library.
272
2732011-11-04 Matthew Heaney <heaney@adacore.com>
274
275 * Makefile.rtl, impunit.adb: Added a-cogeso.ad[sb]
276 * a-cgaaso.adb: Replaced implementation with instantiation
277 of Generic_Sort.
278 * a-cogeso.ad[sb] This is the new Ada 2012 unit
279 Ada.Containers.Generic_Sort
280
5972791c
AC
2812011-11-04 Robert Dewar <dewar@adacore.com>
282
283 * exp_ch2.adb (Expand_Entity_Reference): Do not set
284 Atomic_Sync_Required for the case of a prefix of an attribute.
285 * exp_ch4.adb (Expand_N_Explicit_Dereference): May require
286 atomic synchronization
287 (Expand_N_Indexed_Component): Ditto.
288 (Expand_B_Selected_Component): Ditto.
289 * sem_prag.adb (Process_Suppress_Unsuppress):
290 Disable/Enable_Atomic_Synchronization can now occur for array
291 types with pragma Atomic_Components.
292 * sinfo.ads, sinfo.adb (Atomic_Sync_Required): Can now occur on
293 N_Explicit_Dereference nodes and on N_Indexed_Component nodes.
294
2952011-11-04 Gary Dismukes <dismukes@adacore.com>
296
297 * gnat_ugn.texi: Editorial corrections for gnattest section.
298
8751a35c
RD
2992011-11-04 Robert Dewar <dewar@adacore.com>
300
301 * sem_prag.adb: Minor reformatting.
302 * gnat_rm.texi: Update documentation for pragma Warnings (Off,
303 "***") usage.
304 * exp_ch2.adb (Expand_Entity_Reference): Only set
305 Atomic_Sync_Required on entities that are variables. Doesn't
306 make any sense on anything else.
307
fb5d63c6
RD
3082011-11-04 Robert Dewar <dewar@adacore.com>
309
310 * exp_ch2.adb (Expand_Entity_Reference): Extend handling of
311 atomic sync to type case.
312 * sem_prag.adb (Process_Suppress_Unsuppress): Atomic Sync can
313 apply to types.
314
a51cd0ec 3152011-11-04 Robert Dewar <dewar@adacore.com>
25ec1790 316
a51cd0ec
AC
317 * sem_warn.adb (Warn_On_Useless_Assignment): More accurate test
318 for call vs assign.
319 * gcc-interface/Make-lang.in: Update dependencies.
320
3212011-11-04 Robert Dewar <dewar@adacore.com>
322
323 * sem_prag.adb: Detect more cases of Long_Float inconsistencies at
324 compile time.
325
3262011-11-04 Matthew Heaney <heaney@adacore.com>
327
328 * Makefile.rtl, impunit.adb: Added a-sfecin.ads,
329 * a-sfhcin.ads, a-sflcin.ads, a-sbecin.ad[sb], a-sbhcin.ad[sb],
330 a-sblcin.ad[sb], a-suecin.ad[sb], a-suhcin.ad[sb], a-sulcin.ad[sb]
331 * a-sfecin.ads, a-sfhcin.ads, a-sflcin.ads, a-sbecin.ad[sb],
332 a-sbhcin.ad[sb], a-sblcin.ad[sb], a-suecin.ad[sb], a-suhcin.ad[sb],
333 a-sulcin.ad[sb]: New files.
334
3352011-11-04 Geert Bosch <bosch@adacore.com>
336
337 * i-forbla-unimplemented.ads, s-gecola.adb, s-gecola.ads,
338 s-gerebl.adb, s-gerebl.ads, i-forbla.adb, i-forbla.ads,
339 i-forlap.ads, i-forbla-darwin.adb, s-gecobl.adb, s-gecobl.ads,
340 s-gerela.adb, s-gerela.ads: Remove partial interface to BLAS/LAPACK.
341 * gcc-interface/Makefile.in: Remove libgnala and related objects.
25ec1790 342
a31945d7
AC
3432011-11-04 Matthew Heaney <heaney@adacore.com>
344
345 * a-cdlili.ad[sb], a-cidlli.ad[sb], a-coorse.ad[sb], a-ciorse.ad[sb],
346 a-coorma.ad[sb], a-ciorma.ad[sb], a-coormu.ad[sb], a-ciormu.ad[sb],
347 a-cohama.ad[sb], a-cihama.ad[sb], a-cohase.ad[sb], a-cihase.ad[sb],
348 a-convec.ad[sb], a-coinve.ad[sb] (Assign, Copy): New operations
349 added to package.
350
a51cd0ec
AC
3512011-11-04 Eric Botcazou <ebotcazou@adacore.com>
352
353 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Do not assert
354 that the type of the parameters isn't dummy in type_annotate_only mode.
355
a31945d7
AC
3562011-11-04 Robert Dewar <dewar@adacore.com>
357
358 * sem_ch12.adb: Minor reformatting
359
3602011-11-04 Gary Dismukes <dismukes@adacore.com>
361
362 * bindgen.adb (Gen_Elab_Calls): In the case of the AAMP target,
363 initialize elaboration entities to zero when specs are processed.
364
a53f3523
IS
3652011-10-28 Iain Sandoe <iains@gcc.gnu.org>
366 Eric Botcazou <ebotcazou@adacore.com>
367
368 PR target/50678
be7552fc
EB
369 * init.c (__gnat_error_handler) [Darwin]: Apply a work-around to the
370 bug filed as radar #10302855 (inconsistent unwind data for sigtramp).
a53f3523 371
0de82be5
EB
3722011-10-28 Eric Botcazou <ebotcazou@adacore.com>
373
374 PR ada/50842
375 * gcc-interface/Makefile.in (SYMDEPS): Delete.
376 (LIBICONV): New variable.
377 (LIBICONV_DEP): Likewise.
378 (LIBS): Add $(LIBICONV).
379 (LIBDEPS): Add $(LIBICONV_DEP).
380 (EXTRA_GNATTOOLS_OBJS): Merge into...
381 (TOOLS_LIBS): ...this. Add $(LIBICONV).
e1e5852c 382
1586f8a3
EB
3832011-10-26 Eric Botcazou <ebotcazou@adacore.com>
384
385 * gcc-interface/decl.c (elaborate_expression_1): Add EXPR_PUBLIC_P local
386 variable. Always create the elaboration variable, if any, as constant.
387
e1e5852c
EB
3882011-10-26 Eric Botcazou <ebotcazou@adacore.com>
389
390 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Subtype>: Try to
391 make a packable type for fields of union types as well.
392 <is_type>: Use RECORD_OR_UNION_TYPE_P predicate.
393 (gnat_to_gnu_component_type): Try to make a packable type for fields
394 of union types as well.
395 (make_packable_type): Use RECORD_OR_UNION_TYPE_P predicate.
396 (maybe_pad_type): Try to make a packable type for fields of union types
397 as well.
398 (gnat_to_gnu_field): Likewise.
399 (is_variable_size): Use RECORD_OR_UNION_TYPE_P predicate.
400 (set_rm_size): Likewise.
401 (rm_size): Likewise.
402 * gcc-interface/misc.c (gnat_type_max_size): Likewise.
403 * gcc-interface/trans.c (add_decl_expr): Likewise.
404 * gcc-interface/utils.c (finish_record_type): Likewise.
405 * gcc-interface/utils2.c (build_simple_component_ref): Likewise.
406
0025cb63
EB
4072011-10-26 Eric Botcazou <ebotcazou@adacore.com>
408
409 * gcc-interface/decl.c (gnat_to_gnu_field): Always check components
410 declared as atomic. Move around conditionally executed code.
411
b3c33641
AC
4122011-10-24 Robert Dewar <dewar@adacore.com>
413
be7552fc 414 * sem.adb (Initialize): Fix bug that blew up if called a second time.
b3c33641
AC
415
4162011-10-24 Robert Dewar <dewar@adacore.com>
417
418 * tb-alvxw.c, tracebak.c, expect.c, initflt.c, tb-alvms.c,
419 tb-ivms.c, tb-gcc.c: Update headers to GPL 3.
420
4212011-10-24 Robert Dewar <dewar@adacore.com>
422
423 * sem_prag.adb (Analyze_Pragma, case Debug): Give proper pragma
424 name in error msg.
425
4262011-10-24 Hristian Kirtchev <kirtchev@adacore.com>
427
be7552fc 428 * gnat_rm.texi: Add an entry for restriction No_Finalization.
b3c33641
AC
429
4302011-10-24 Ed Schonberg <schonberg@adacore.com>
431
432 * sem_ch12.adb (Insert_Freeze_Node_For_Instance): If the
433 current instance is within the one that contains the generic,
434 the freeze node for the current one must appear in the current
435 declarative part. Ditto if the current instance is within another
436 package instance. In both of these cases the freeze node of the
437 previous instance is not relevant.
438
4392011-10-24 Gary Dismukes <dismukes@adacore.com>
440
441 * switch-m.adb (Normalize_Compiler_Switches): Add recognition
442 of AAMP-specific switches -univ and -aamp_target.
443
4442011-10-24 Robert Dewar <dewar@adacore.com>
445
446 * a-tienau.adb (Put): Deal properly with limited line length.
447
4482011-10-24 Robert Dewar <dewar@adacore.com>
449
450 * sem_warn.adb, sem_ch12.adb: Minor reformatting.
451
30e1709c 4522011-10-24 Tristan Gingold <gingold@adacore.com>
8263e17a
TG
453
454 * gcc-interface/Makefile.in: Use GNU ld switches to generate map files
455 on AIX.
456
12b4d338
AC
4572011-10-24 Ed Schonberg <schonberg@adacore.com>
458
459 * sem_ch12.adb (Earlier): make available globally. If both
460 nodes have the same sloc, the freeze node that does not come
461 from source is the later one.
462 (True_Parent): Make available globally.
463 (Previous_Instance): Subsidiary of
464 Insert_Freeze_Node_For_Instance, to check whether the generic
465 parent of the current instance is declared within a previous
466 instance in the same unit or declarative part, in which case the
467 freeze nodes of both instances must appear in order to prevent
468 elaboration problems in gigi.
469 * sem_ch12.adb (Insert_Freeze_Node_For_Instance): A stub is a
470 freeze point, and the freeze node of a preceding instantiation
471 must be inserted before it.
472
4732011-10-24 Robert Dewar <dewar@adacore.com>
474
475 * checks.ads, checks.adb: Add handling of Synchronization_Check
476 * debug.adb: Add doc for -gnatd.d and -gnatd.e (disable/enable
477 atomic sync).
478 * exp_ch2.adb (Expand_Entity_Reference): Set Atomic_Sync_Required
479 flag Minor code reorganization.
480 * opt.ads (Warn_On_Atomic_Synchronization): New switch.
481 * par-prag.adb: Add dummy entries for pragma
482 Disable/Enable_Atomic_Synchronization.
483 * sem_prag.adb (Process_Suppress_Unsuppress): Handle
484 case of Atomic_Synchronization specially (not suppressed
485 by All_Checks, cannot be set from Source).
486 (Pragma Disable/Enable_Atomic_Synchronization): Add processing.
487 * sinfo.ads, sinfo.adb: Add Atomic_Sync_Required flag
488 * snames.ads-tmpl: Add entry for Atomic_Synchronization Add
489 entry for pragma Disable/Enable_Atomic_Synchronization
490 * switch-c.adb: The -gnatp switch does not disable
491 Atomic_Synchronization Add -gnatep switch to disable
492 Atomic_Synchronization.
493 * types.ads: Add entry for Synchronization_Check
494 * usage.adb: Add line for -gnated switch
495 * warnsw.adb: Settings for Warn_On_Atomic_Synchronization
496
08ce7bb8
AC
4972011-10-24 Geert Bosch <bosch@adacore.com>
498
be7552fc
EB
499 * s-gearop.adb (Back_Substitute): Avoid overflow if matrix bounds start
500 at Integer'First.
08ce7bb8
AC
501
5022011-10-24 Robert Dewar <dewar@adacore.com>
503
be7552fc 504 * sem_ch12.adb, s-gearop.adb: Minor reformatting.
08ce7bb8
AC
505
5062011-10-24 Robert Dewar <dewar@adacore.com>
507
be7552fc
EB
508 * warnsw.adb: Add some missing warnings to Set_GNAT_Mode_Warnings.
509 * warnsw.ads: Add comments to Set_GNAT_Mode_Warnings.
08ce7bb8 510
292689c2
AC
5112011-10-24 Emmanuel Briot <briot@adacore.com>
512
513 * prj-proc.adb (Process_Expression_Variable_Decl): No special
514 handling for Project_Path unless it is an attribute.
515
5162011-10-24 Javier Miranda <miranda@adacore.com>
517
518 * sem_ch12.adb (Check_Hidden_Primitives): New subprogram.
519 (Install_Hidden_Primitives): New subprogram.
520 (Restore_Hidden_Primitives): New subprogram.
521 (Analyze_Formal_Package_Declaration,
522 Analyze_Package_Instantiation, Analyze_Subprogram_Instantiation):
523 Invoke Check_Hidden_Primitives after every call to
524 Analyze_Associations, and invoke Restore_Hidden_Primitives to
525 restore their visibility after processing the instantiation.
526 (Instantiate_Package_Body): Install visible primitives before
527 analyzing the instantiation and uninstall them to restore their
528 visibility when the instantiation has been analyzed.
529 * sem_util.ads, sem_util.adb (Add_Suffix): New subprogram
530 (Remove_Suffix): New subprogram
531 * sem_ch3.adb (Derive_Subprogram): When handling
532 a derived subprogram for the instantiation of a formal derived
533 tagged type, inherit the dispatching attributes from the actual
534 subprogram (not from the parent type).
535
db4b3c49
AC
5362011-10-24 Vasiliy Fofanov <fofanov@adacore.com>
537
538 * gnat_ugn.texi: Document explicit use of XDECGNAT library.
539
5402011-10-24 Hristian Kirtchev <kirtchev@adacore.com>
541
542 * exp_ch3.adb (Build_Assignment): Add local constant N_Loc and
543 update its uses.
544 (Build_Discriminant_Assignments): Add local variable D_Loc and update
545 its uses.
546 (Build_Init_Statements): Add local variables Comp_Loc, Decl_Loc and
547 Var_Loc and update their uses.
548 (Build_Record_Init_Proc): Code reformatting.
549 (Increment_Counter): Add formal parameter Loc.
550 (Make_Counter): Add formal parameter Loc.
551
5522011-10-24 Eric Botcazou <ebotcazou@adacore.com>
553
554 * sem_disp.adb (Covers_Some_Interface): Fix typo.
555
5562011-10-24 Matthew Heaney <heaney@adacore.com>
557
be7552fc
EB
558 * a-cuprqu.adb, a-cbprqu.adb (Dequeue_Only_High_Priority): Fix sense
559 of predicate.
db4b3c49
AC
560
5612011-10-24 Yannick Moy <moy@adacore.com>
562
563 * sem_ch13.adb (Analyze_Aspect_Specifications/Aspect_Test_Case):
564 Translate arguments in positional notation into pragma argument
565 association arguments for the generated pragma.
566
5672011-10-24 Arnaud Charlet <charlet@adacore.com>
568
569 * exp_ch5.adb: Fix minor typo.
570
5712011-10-24 Ed Schonberg <schonberg@adacore.com>
572
573 * sem_ch3.adb (Is_Visible_Component): Refine predicate for
574 the case of a component reference in an instance body, when the
575 enclosing type is private.
576
86f0e17a
AC
5772011-10-24 Sergey Rybin <rybin@adacore.com frybin>
578
579 * gnat_ugn.texi: For gnatelim, move the note about using the GNAT
580 driver for getting the project support into gnatelim section.
581
5822011-10-24 Robert Dewar <dewar@adacore.com>
583
be7552fc 584 * gnat_rm.texi: Minor correction to documentation on address clause.
86f0e17a
AC
585
5862011-10-24 Hristian Kirtchev <kirtchev@adacore.com>
587
588 * s-finmas.adb (Attach): Synchronize and call the unprotected version.
589 (Attach_Unprotected): New routine.
590 (Delete_Finalize_Address): Removed.
591 (Delete_Finalize_Address_Unprotected): New routine.
592 (Detach): Synchronize and call the unprotected version.
593 (Detach_Unprotected): Remove locking.
594 (Finalize): Add various comment on synchronization. Lock the critical
595 region and call the unprotected versions of routines.
596 (Finalize_Address): Removed.
597 (Finalize_Address_Unprotected): New routine.
598 (Set_Finalize_Address): Synchronize and call
599 the unprotected version.
600 (Set_Finalize_Address_Unprotected): New routine.
601 (Set_Heterogeneous_Finalize_Address): Removed.
602 (Set_Heterogeneous_Finalize_Address_Unprotected): New routine.
603 (Set_Is_Heterogeneous): Add comment on synchronization and
604 locking.
605 * s-finmas.ads: Flag Finalization_Started is no longer atomic
606 because synchronization uses task locking / unlocking.
607 (Attach): Add comment on usage.
608 (Attach_Unprotected): New routine.
609 (Delete_Finalize_Address): Renamed to
610 Delete_Finalize_Address_Unprotected.
611 (Detach): Add comment on usage.
612 (Detach_Unprotected): New routine.
613 (Finalize_Address): Renamed to Finalize_Address_Unprotected.
614 (Set_Finalize_Address): Add comment on usage.
615 (Set_Finalize_Address_Unprotected): New routine.
616 (Set_Heterogeneous_Finalize_Address): Renamed to
617 Set_Heterogeneous_Finalize_Address_Unprotected.
618 * s-stposu.adb (Allocate_Any_Controlled): Add local variable
619 Allocation_Locked. Add various comments on synchronization. Lock
620 the critical region and call the unprotected version of
621 routines.
622 (Deallocate_Any_Controlled): Add various comments on
623 synchronization. Lock the critical region and call the unprotected
624 version of routines.
625
6262011-10-24 Ed Schonberg <schonberg@adacore.com>
627
628 * sem_ch3.adb (Set_Fixed_Range): The bounds of a fixed point type
629 are universal and must carry the corresponding type.
630 * sem_eval.adb (Check_Non_Static_Context): If the type of the
631 expression is universal real, as may be the case for a fixed point
632 expression with constant operands in the context of a conversion,
633 there is nothing to check.
634 * s-finmas.adb: Minor reformatting
635
be98aaf0
EB
6362011-10-23 Eric Botcazou <ebotcazou@adacore.com>
637
638 * gcc-interface/decl.c (create_concat_name): Add explicit cast.
639
e45c0886
EB
6402011-10-20 Eric Botcazou <ebotcazou@adacore.com>
641
642 * gcc-interface/Make-lang.in (GNATLIBFLAGS, GNATLIBCFLAGS, THREAD_KIND,
643 TRACE): Reintroduce.
644 (ada/tracebak.o, ada/targext.o, ada/cio.o, ada/init.o,
645 ada/initialize.o, ada/raise.o): Reintroduce explicit compilation rules.
646
27ab5bd8
EB
6472011-10-20 Eric Botcazou <ebotcazou@adacore.com>
648
649 * gcc-interface/trans.c (lhs_or_actual_p): New predicate.
650 (unchecked_conversion_nop): Use it.
651 (gnat_to_gnu): Likewise.
652
b7562769
EB
6532011-10-20 Eric Botcazou <ebotcazou@adacore.com>
654
655 * back_end.adb (Call_Back_End): Pass the maximum logical line number
656 instead of the maximum physical line number to gigi.
657 * gcc-interface/trans.c (Sloc_to_locus): Cope with line zero.
658
53e7c794 6592011-10-16 Tom Tromey <tromey@redhat.com>
46427374
TT
660 Dodji Seketeli <dodji@redhat.com>
661
be7552fc
EB
662 * gcc-interface/trans.c (gigi, Sloc_to_locus): Adjust to use the new
663 public ordinary map interface.
46427374 664
ea10ca9c
AC
6652011-10-16 Tristan Gingold <gingold@adacore.com>
666
53e7c794 667 * link.c (_AIX): Add support for GNU ld.
ea10ca9c
AC
668
6692011-10-16 Fedor Rybin <frybin@adacore.com>
670
671 * gnat_ugn.texi: Fixing gnattest example names in the doc.
672 Adding explanation to additional tests usage.
673
6742011-10-16 Robert Dewar <dewar@adacore.com>
675
676 * exp_ch6.adb, sem_ch6.adb: Minor reformatting.
677
6782011-10-16 Eric Botcazou <ebotcazou@adacore.com>
679
680 * a-convec.adb: Fix minor inconsistencies.
681
6822011-10-16 Matthew Heaney <heaney@adacore.com>
683
684 * a-cusyqu.ads, a-cbsyqu.ads, a-cuprqu.ads, a-cbprqu.ads (package
685 Implementation): Specify pragma Implementation_Defined.
686
c225ba50
NR
6872011-10-15 Nicolas Roche <roche@adacore.com>
688
689 * gcc-interface/lang-specs.h: Ensure -mrtp switch is passed when using
690 either rtp-smp or ravenscar-cert-rtp runtimes.
691
3e452820
AC
6922011-10-15 Bob Duff <duff@adacore.com>
693
694 * exp_ch6.adb (Add_Unconstrained_Actuals_To_Build_In_Place_Call):
695 Do not create a pool formal on unless RE_Root_Storage_Pool_Ptr
696 is available.
697 (Expand_N_Extended_Return_Statement): Do not create a renaming of the
698 build-in-place pool parameter unless RE_Root_Storage_Pool_Ptr is
699 available.
700 (Make_Build_In_Place_Call_In_Allocator): Add the user-defined
701 pool only if RE_Root_Storage_Pool_Ptr is available.
702 (Make_Build_In_Place_Call_In_Object_Declaration): Do not add a
703 pool actual unless RE_Root_Storage_Pool_Ptr is available.
704 * sem_ch6.adb (Create_Extra_Formals): Add build-in-place pool
705 formal only if RE_Root_Storage_Pool_Ptr is available.
706
7072011-10-15 Matthew Heaney <heaney@adacore.com>
708
709 * a-cusyqu.ads, a-cbsyqu.ads, a-cuprqu.ads, a-cbprqu.ads (Queue
710 type): Specify Priority aspect for protected type.
711
b7539c3b
AC
7122011-10-14 Ed Schonberg <schonberg@adacore.com>
713
714 * exp_disp.adb (Check_Premature_Freezing): If an untagged type
715 is a generic actual, it is a subtype of a type that was frozen
716 by the instantiation, and even if not marked frozen it does not
717 affect the construction of the dispatch table.
718
7192011-10-14 Robert Dewar <dewar@adacore.com>
720
721 * make.adb, mlib-utl.adb, sem_util.adb, sem_ch4.adb: Minor code
722 reformatting.
723 * s-rident.ads: Add missing Compiler_Unit pragma.
724
af89615f
AC
7252011-10-14 Gary Dismukes <dismukes@adacore.com>
726
727 * sem_res.adb: Minor reformatting.
728
7292011-10-14 Hristian Kirtchev <kirtchev@adacore.com>
730
731 * exp_ch6.adb (Add_Task_Actuals_To_Build_In_Place_Call):
732 Code and comment reformatting. Use BIP_Task_Master
733 when creating a _master.
734 (BIP_Formal_Suffix): Code reformatting. Correct the case for
735 BIP_Task_Master.
736 (Make_Build_In_Place_Call_In_Object_Declaration): Use
737 BIP_Task_Master when creating a reference to the enclosing
738 function's _master formal.
739 (Move_Activation_Chain): Use BIP_Task_Master when creating a reference
740 to the _master.
741 * exp_ch6.ads: Change BIP_Master to BIP_Task_Master.
742 (Needs_BIP_Finalization_Master): Alphabetized.
743 * sem_ch6.adb (Create_Extra_Formals): Update the usage of
744 BIP_Task_Master.
745
7462011-10-14 Ed Schonberg <schonberg@adacore.com>
747
748 * par-ch6.adb (P_Return_Object_Declaration): In Ada 2012 mode,
749 reject an aliased keyword on the object declaration of an extended
750 return statement. In older versions of the language indicate
751 that this is illegal in the standard.
752
7532011-10-14 Pascal Obry <obry@adacore.com>
754
755 * sem_util.adb, sem_ch4.adb: Minor reformatting.
756
7572011-10-14 Ed Schonberg <schonberg@adacore.com>
758
759 * sem_ch13.adb: Recognize properly procedure calls that are
760 transformed into code statements.
761
7622011-10-14 Vincent Celier <celier@adacore.com>
763
764 * projects.texi: Minor fix in project example.
765
f2d10a02
AC
7662011-10-14 Ed Schonberg <schonberg@adacore.com>
767
768 * sem_util.adb: Return objects are aliased if their type is
769 immutably limited as per AI05-0053.
770
7712011-10-14 Gary Dismukes <dismukes@adacore.com>
772
773 * exp_ch4.adb (Expand_N_Op_And): Remove Short_Circuit_And_Or
774 expansion code (moved to sem_res) (Expand_N_Op_Or): Remove
775 Short_Circuit_And_Or expansion code (moved to sem_res).
776 * sem_res.adb (Resolve_Logical_Op): Add code to rewrite Boolean
777 "and" and "or" operators as short-circuit "and then" and "or
778 else", when pragma Short_Circuit_And_Or is active.
779
2fcc44fa
AC
7802011-10-13 Robert Dewar <dewar@adacore.com>
781
782 * sem_ch9.adb, sem_util.adb, sem_util.ads, exp_ch6.adb, sem_ch4.adb,
783 sem_ch6.adb, exp_ch3.adb: Minor reformatting.
784
7852011-10-13 Arnaud Charlet <charlet@adacore.com>
786
787 * Makefile.rtl (GNATRTL_NONTASKING_OBJS): Add a-ngcoar.o.
788
7892011-10-13 Jerome Guitton <guitton@adacore.com>
790
791 * sysdep.c (__gnat_get_task_options): Re-enable VX_SPE_TASK on vThreads
792
7932011-10-13 Eric Botcazou <ebotcazou@adacore.com>
794
795 * a-convec.ads (Cursor): Minor reformatting.
796 * a-convec.adb (Next): Fix minor inconsistencies.
797 (Previous): Likewise.
798
9b62eb32
AC
7992011-10-13 Ed Schonberg <schonberg@adacore.com>
800
801 * sem_util.ads, sem_util.adb (Available_Full_View_Of_Component):
802 New predicate to determine whether some operations on an array
803 type are available when the full view of its component may differ
804 from the view of the point of the array declaration.
805 * sem_ch4.adb (Find_Equality_Types): Use
806 Available_Full_View_Of_Component.
807 * sem_type.adb (Valid_Boolean_Arg, Valid_Comparison_Arg): Ditto
808
8092011-10-13 Ed Schonberg <schonberg@adacore.com>
810
811 * sem_ch9.adb: Analyze aspects while discriminants of protected
812 type are visible.
813
8142011-10-13 Geert Bosch <bosch@adacore.com>
815
816 * Makefile.rtl (GNATRTL_TASKING_OBJECTS): Add
817 a-nlcoar.o, a-nllcar.o, a-nucoar.o and s-gearop.o, as these no
818 longer depend on an external library.
819 * gcc-interface/Makefile.in (GNATRTL_LINEARALGEBRA_OBJS): Remove
820 a-nlcoar.o, a-nllcar.o, a-nucoar.o and s-gearop.o.
821 Update dependencies.
822 * gcc-interface/Make-lang.in: Update dependencies.
823
1a36a0cd
AC
8242011-10-13 Cyrille Comar <comar@adacore.com>
825
826 * gnat_ugn.texi: Minor editing.
827
8282011-10-13 Vincent Celier <celier@adacore.com>
829
830 * projects.texi: Add documentation on packages and attributes
831 that are inherited from a project being extended into the
832 extended project.
833
8342011-10-13 Hristian Kirtchev <kirtchev@adacore.com>
835
836 * exp_ch3.adb (Build_Master): Rewritten.
837 (Expand_N_Full_Type_Declaration): Reformat the declarative
838 region. Update the call to Build_Master_Renaming.
839 (Expand_Previous_Access_Type): Rewritten.
840 * exp_ch6.adb (Add_Task_Actuals_To_Build_In_Place_Call):
841 Add local constant Result_Subt and update related usage.
842 (Expand_N_Extended_Return_Statement): Add local constant
843 Result_Subt and update related usage.
844 * exp_ch9.adb (Build_Activation_Chain): Rewritten to use the
845 new context detection mechanism.
846 (Build_Class_Wide_Master):
847 Use Insert_Action to add the renaming into the tree.
848 (Build_Master_Entity): Rewritten to use the new context detection
849 mechanism.
850 (Build_Master_Renaming): Add formal parameter Ins_Nod
851 and related usage. Use Insert_Action to add the renaming into the
852 tree.
853 (Find_Enclosing_Context): New subsidiary routine. Rather
854 than relying on enclosing scopes, this routine looks at the
855 tree structure to figure out the proper context for a _master
856 or a _chain. This approach eliminates the issues with transient
857 scopes which have not been converted into blocks.
858 * exp_ch9.ads (Build_Master_Entity): Change parameter profile
859 to better reflect the new usage. Update the related comment.
860 (Build_Master_Renaming): Add formal parameter Ins_Nod. Update
861 the comment on usage.
862 * sem_ch3.adb (Access_Definition): Update the calls to
863 Build_Master_Entity and Build_Master_Renaming.
864 * sem_ch6.adb (Create_Extra_Formals): Add local variable
865 Full_Subt. Code reformatting.
866 * sem_util.adb (Is_Iterator): Alphabetized.
867 (Is_LHS): Alphabetized.
868 (Is_Limited_Class_Wide_Type): New routine.
869 * sem_util.ads (Is_Limited_Class_Wide_Type): New routine.
870
a5917ffb
GB
8712011-10-13 Geert Bosch <bosch@adacore.com>
872
873 * a-ngrear.adb (Solve): Make generic and move to
874 System.Generic_Array_Operations.
875 * s-gearop.ads (Matrix_Vector_Solution, Matrix_Matrix_Solution):
876 New generic solvers to compute a vector resp. matrix Y such
877 that A * Y = X, approximately.
878 * s-gearop.adb (Matrix_Vector_Solution, Matrix_Matrix_Solution):
879 Implement using Forward_Eliminate and Back_Substitute
880 * a-ngcoar.adb: Reimplement in pure Ada to remove dependencies
881 on BLAS and LAPACK.
882 * a-ngcoar.ads ("abs"): Fix return type to be real.
883
574ec945
EB
8842011-10-13 Eric Botcazou <ebotcazou@adacore.com>
885
886 PR ada/50589
887 * s-linux-alpha.ads: Do not "with" Interfaces.C.
888 * s-linux-sparc.ads: Likewise.
889
8668ea36
GB
8902011-10-13 Geert Bosch <bosch@adacore.com>
891
892 * s-gearop.ads (Forward_Eliminate): Add "abs" formal function
893 returning a Real.
894 * s-gearop.adb (Forward_Eliminate): Remove local "abs" function
895 and use formal.
896 * a-ngrear.adb (Forward_Eliminate): Adjust instantiation for
897 new profile.
898
edcf5983
GB
8992011-10-13 Geert Bosch <bosch@adacore.com>
900
901 * a-ngrear.adb, s-gearop.adb, s-gearop.ads (Sqrt): Make generic and
902 move to System.Generic_Array_Operations.
903
a4935dea
GB
9042011-10-13 Geert Bosch <bosch@adacore.com>
905
906 * a-ngrear.adb ("abs"): Adjust for modified L2_Norm generic
907 * s-gearop.ads (L2_Norm): Change profile to be suitable for
908 Complex_Vector
909 * s-gearop.adb (L2_Norm): Reimplement using direct definition,
910 not inner product
911
3e7302c3
AC
9122011-10-13 Robert Dewar <dewar@adacore.com>
913
914 * exp_ch5.adb, sem_ch3.adb, impunit.adb, impunit.ads, sem_type.adb,
915 prj-proc.adb, exp_ch9.adb, s-regpat.adb, sem_ch10.adb, sem_prag.adb,
916 sem_ch12.adb, freeze.adb, sem_attr.adb, sem_attr.ads, gnatlink.adb,
917 par-ch6.adb, exp_ch6.adb, sem_ch4.adb, sem_ch6.adb, sem_ch8.adb,
918 par-util.adb, sem_ch13.adb, lib-xref.adb, g-trasym.adb, g-trasym.ads,
919 exp_aggr.adb, s-taprop-posix.adb: Minor reformatting.
920
9212011-10-13 Geert Bosch <bosch@adacore.com>
922
923 * s-gearop.adb: Minor comment additions.
924
8417f4b2
AC
9252011-10-13 Fedor Rybin <frybin@adacore.com>
926
927 * gnat_ugn.texi: Add gnattest section.
928
9292011-10-13 Ed Schonberg <schonberg@adacore.com>
930
931 * freeze.adb: Do not create body of renaming if declaration has
932 errors.
933
9342011-10-13 Olivier Hainque <hainque@adacore.com>
935
936 * init.c (__gnat_error_handler - vxworks case): Restrict sigtramp calls
937 further, to the ppc+kernel case only.
938
9392011-10-13 Hristian Kirtchev <kirtchev@adacore.com>
940
941 * exp_ch4.adb (Expand_N_Allocator): Comment reformatting.
942 * exp_ch6.adb (Add_Unconstrained_Actuals_To_Build_In_Place_Call):
943 Do not create a pool formal on .NET/JVM.
944 (Expand_N_Extended_Return_Statement): Alphabetize local
945 variables. Do not create a renaming of the build-in-place pool
946 parameter on .NET/JVM. (Make_Build_In_Place_Call_In_Allocator):
947 Add the user-defined pool only on non-VM targets.
948 (Make_Build_In_Place_Call_In_Object_Declaration): Alphabetize
949 local variables. Do not add a pool actual on .NET/JVM.
950 * sem_ch6.adb: Add with and use clause for Targparm.
951 (Create_Extra_Formals): Add build-in-place pool formal only on
952 non-VM targets.
953 * rtsfind.ads: Alphabetize entries.
954
4674dd21
AC
9552011-10-13 Sergey Rybin <rybin@adacore.com>
956
957 * gnat_ugn.texi: Minor correction.
958
9592011-10-13 Ed Schonberg <schonberg@adacore.com>
960
961 * sem_ch8.adb: Minor error message improvement.
962
9632011-10-13 Robert Dewar <dewar@adacore.com>
964
965 * a-cbprqu.adb, a-ciorma.adb, exp_ch3.adb: Minor reformatting.
966
95aeda79
GD
9672011-10-13 Gary Dismukes <dismukes@adacore.com>
968
969 * exp_ch5.adb (Expand_N_Loop_Statement): For the transformation
970 of a for loop for an enumeration type with an enumeration rep
971 clause, which involves moving the original loop parameter into
972 a nested block, the loop parameter's entity must be removed from
973 the entity list of the loop scope.
974
200b7162
BD
9752011-10-13 Bob Duff <duff@adacore.com>
976
977 * exp_ch6.ads (BIP_Storage_Pool): New "extra implicit parameter"
978 that gets passed in the same cases where BIP_Alloc_Form is passed
979 (caller-unknown-size results). BIP_Storage_Pool is used when
980 BIP_Alloc_Form = User_Storage_Pool. In that case, a pointer
981 to the user-defined storage pool is passed at the call site,
982 and this pool is used in callee to allocate the result.
983 * exp_ch6.adb (Add_Unconstrained_Actuals_To_Build_In_Place_Call): New
984 version of Add_Alloc_Form_Actual_To_Build_In_Place_Call. Passes
985 the additional BIP_Storage_Pool actual.
986 (Expand_N_Extended_Return_Statement): Allocate the function
987 result using the user-defined storage pool, if BIP_Alloc_Form =
988 User_Storage_Pool.
989 * sem_ch6.adb: Add the "extra formal" for BIP_Storage_Pool.
990 * exp_ch4.adb: Don't overwrite storage pool set by
991 Expand_N_Extended_Return_Statement.
992 * s-stopoo.ads, rtsfind.ads (Root_Storage_Pool_Ptr): New type,
993 for use in build-in-place function calls within allocators
994 where the access type has a user-defined storage pool.
995
9f8d1e5c
AC
9962011-10-13 Sergey Rybin <rybin@adacore.com>
997
998 * gnat_ugn.texi, vms_data.ads: Add an option to control enumeration
999 literal casing.
1000
10012011-10-13 Nicolas Roche <roche@adacore.com>
1002
be7552fc
EB
1003 * gnatlink.adb: Ensure that -mrtp is passed when runtime name ends
1004 with 'rtp'.
9f8d1e5c
AC
1005
10062011-10-13 Ed Schonberg <schonberg@adacore.com>
1007
be7552fc
EB
1008 * sem_prag.adb (Analyze_Pragma, case Unchecked_Union): Take into
1009 account that an unchecked union type can be limited.
9f8d1e5c
AC
1010
10112011-10-13 Olivier Hainque <hainque@adacore.com>
1012
1013 * init.c (__gnat_error_handler) <VxWorks version>: Add comments on
1014 the use of the signal trampoline for PPC in the sjlj case as well.
1015 Add legitimate casts, preventing compile time warnings on the
1016 (sighandler *) profile.
1017
10182011-10-13 Yannick Moy <moy@adacore.com>
1019
be7552fc
EB
1020 * sem_aggr.adb (Resolve_Aggr_Expr): Always perform semantic analysis
1021 in Alfa mode.
9f8d1e5c
AC
1022
10232011-10-13 Ed Schonberg <schonberg@adacore.com>
1024
1025 * sem_ch3.adb (OK_For_Limited_Init_In_05): Conditional and case
1026 expressions are legal limited return values if each one of their
1027 dependent expressions are legal.
1028
10292011-10-13 Ed Schonberg <schonberg@adacore.com>
1030
1031 * sem_ch6.adb (Analyze_Procedure_Call_Statement): In Ada 2012 mode,
1032 if the prefix of the call is a qualified expression, rewrite as
1033 a code statement.
1034 * sem_ch13.adb (Analyze_Code_Statement): In Ada 2012 mode, the
1035 code statement is legal if it is a rewriting of a procedure call.
1036
10372011-10-13 Ed Schonberg <schonberg@adacore.com>
1038
1039 * exp_aggr.adb (Flatten): If a component association has a box,
1040 assume that aggregate is not static.
1041 (Safe_Aggregate): If a component association in a non-limited
1042 aggregate has a box, assume that it cannot be expanded in place.
1043
10442011-10-13 Vincent Celier <celier@adacore.com>
1045
1046 * prj-conf.adb (Get_Or_Create_Configuration_File): Call
1047 Process_Project_Tree_Phase_1 with Packages_To_Check.
1048 (Process_Project_And_Apply_Config): Ditto
1049 * prj-part.ads, prj-part.adb, prj-pars.ads, prj-pars.adb (Parse):
1050 Remove default for argument Packages_To_Check.
1051 * prj-proc.adb (Recursive_Process): New argument
1052 Packages_To_Check.
1053 (Process): Ditto.
1054 (Process_Project_Tree_Phase_1): Ditto.
1055 (Recursive_Project.Process_Aggregated_Projects): Call
1056 Prj.Part.Parse and Process_Project_Tree_Phase_1 with
1057 Packages_To_Check.
1058 * prj-proc.ads (Process): New argument Packages_To_Check
1059 (Process_Project_Tree_Phase_1): Ditto
1060
46f8e1ac
AC
10612011-10-13 Arnaud Charlet <charlet@adacore.com>
1062
1063 * gcc-interface/Makefile.in: Fix typo.
1064
8097203f
AC
10652011-10-13 Ed Schonberg <schonberg@adacore.com>
1066
1067 * sem_ch12.adb (Analyze_Formal_{Floating_Type,
1068 Signed_Integer_Type, Decimal_Fixed_Point_Type, Discrete_Type}):
1069 Use sloc of defining identifier of farmal type declaration,
1070 as sloc of generated internal entity, to prevent misplaced
1071 references in ali.
1072
10732011-10-13 Ed Schonberg <schonberg@adacore.com>
1074
1075 * sem_intr.adb (Check_Intrinsic_Operator): Check that type
1076 is fully defined before checking that it is a numeric type.
1077
10782011-10-13 Ed Schonberg <schonberg@adacore.com>
1079
1080 * sem_aggr.adb (Resolve_Record_Aggregate): If a component
1081 association for component X has a box, then X is covered in the
1082 aggregate even if there is not default value for X in the type
1083 declaration, and X has to be default-initialized.
1084
10852011-10-13 Ed Schonberg <schonberg@adacore.com>
1086
be7552fc
EB
1087 * sem_attr.adb (Check_Enum_Image, Analyze_Attribute case 'Value): Mark
1088 literals as referenced only if reference is in current source unit.
8097203f
AC
1089
10902011-10-13 Matthew Heaney <heaney@adacore.com>
1091
1092 * a-csquin.ads (Enque, Dequeue): Mark interface operations as entries.
1093
10942011-10-13 Olivier Hainque <hainque@adacore.com>
1095
1096 * sigtramp.h: New file. Prototype and spec of the signal
1097 trampoline to be called by an established handler to provide
1098 dwarf call frame info before the real signal processing code.
1099 * sigtramp-ppcvxw.c: New file. Implementation of the signal
1100 trampoline for ppc-vxworks.
1101 * init.c (vxworks section): Use it for ppc.
1102
e192a2cd
AC
11032011-10-13 Thomas Quinot <quinot@adacore.com>
1104
1105 * par-ch2.adb, par.adb, par-util.adb, par-ch3.adb
1106 (Check_Future_Identifier): New subprogram,
1107 factors duplicated code from Par.Ch2.P_Identifier and
1108 Par.Ch3.P_Defining_Identifier.
1109
11102011-10-13 Thomas Quinot <quinot@adacore.com>
1111
1112 * s-taprop-posix.adb (Initialize): Always raise Storage_Error
1113 if we fail to initialize CV attributes or CV.
1114
11152011-10-13 Thomas Quinot <quinot@adacore.com>
1116
1117 * s-tasren.adb (Timed_Selective_Wait, case
1118 Accept_Alternative_Selected): Use Defer_Abort_Nestable, since
1119 we know abortion is already deferred.
1120
11212011-10-13 Hristian Kirtchev <kirtchev@adacore.com>
1122
1123 * exp_ch3.adb (Build_Class_Wide_Master): Moved to exp_ch9.
1124 (Build_Master_Renaming (function)): Removed.
1125 (Build_Master_Renaming (procedure)): Moved to exp_ch9.
1126 (Expand_Full_Type_Declaration): Alphabetize
1127 variables. Reformatting of code and comments. Rewrite the
1128 section on processing of anonymous access-to-task types in
1129 record components.
1130 * exp_ch3.ads (Build_Class_Wide_Master): Moved to exp_ch9.
1131 (Build_Master_Renaming): Moved to exp_ch9.
1132 * exp_ch9.adb (Build_Class_Wide_Master): Moved from exp_ch3.
1133 (Build_Master_Entity): Add formal parameter
1134 Use_Current. Reformatting of code and comments.
1135 (Build_Master_Renaming): Moved from exp_ch3.
1136 * exp_ch9.ads (Build_Class_Wide_Master): Moved from
1137 exp_ch3. Update comment on usage.
1138 (Build_Master_Entity):
1139 Add formal parameter Use_Current. Update comment on usage.
1140 (Build_Master_Renaming): Moved from exp_ch3.
1141 * sem_ch3.adb (Access_Definition): Remove redundant code to
1142 create a _master and a renaming.
1143
11442011-10-13 Ed Schonberg <schonberg@adacore.com>
1145
1146 * lib-xref.adb: Do no emit reference to overridden operation,
1147 if it is internally generated.
1148
11492011-10-13 Vincent Celier <celier@adacore.com>
1150
1151 * bindgen.adb: Remove any processing related to g-trasym
1152 * Makefile.rtl: Add g-trasym.o to GNATRTL_NONTASKING_OBJS
1153 * mlib-prj.adb: Remove any processing related to g-trasym.
1154
0cfaf83f
EB
11552011-10-12 Eric Botcazou <ebotcazou@adacore.com>
1156
1157 * sem_util.adb (Denotes_Same_Prefix): Fix fatal warning.
1158 * gcc-interface/Make-lang.in (WARN_ADAFLAGS): New.
1159 (ALL_ADAFLAGS): Include WARN_ADAFLAGS.
1160 (ADA_FLAGS_TO_PASS): Likewise.
1161 (COMMON_FLAGS_TO_PASS): New.
1162 (ADA_TOOLS_FLAGS_TO_PASS): Use COMMON_FLAGS_TO_PASS. In the regular
1163 native case, also use FLAGS_TO_PASS and ADA_FLAGS_TO_PASS.
1164 (gnatlib): Use COMMON_FLAGS_TO_PASS.
1165 (ada.install-common): Likewise.
1166 (install-gnatlib): Likewise.
1167 (install-gnatlib-obj): Likewise.
1168 (gnattools): Use ADA_TOOLS_FLAGS_TO_PASS for gnattools1 as well.
1169 (gnat-cross): Delete.
1170 (gnatboot): Likewise.
1171 (gnatboot2): Likewise.
1172 (gnatboot3): Likewise.
1173 (gnatstage1): Likewise.
1174 (gnatstage2): Likewise.
1175 * gcc-interface/Makefile.in (SOME_ADAFLAGS): Likewise.
1176 (MOST_ADAFLAGS): Likewise.
1177 (LOOSE_CFLAGS): Likewise.
1178 (gnat-cross): Likewise.
1179 (GNATLIBFLAGS): Add -W -Wall.
1180 (GNATLIBCFLAGS_FOR_C): Likewise.
1181 * gcc-interface/lang.opt: Remove C-specific warnings. Add doc lines.
1182 * gcc-interface/misc.c (gnat_handle_option): Remove obsolete cases.
1183
722356ce
EB
11842011-10-12 Eric Botcazou <ebotcazou@adacore.com>
1185
1186 * gcc-interface/trans.c (Attribute_to_gnu): Use remove_conversions.
1187 (push_range_check_info): Likewise.
1188 (gnat_to_gnu) <N_Code_Statement>: Likewise.
1189 * gcc-interface/utils2.c (build_unary_op) <INDIRECT_REF>: Likewise.
1190 (gnat_invariant_expr): Likewise.
1191 * gcc-interface/utils.c (compute_related_constant): Likewise.
1192 (max_size): Fix handling of SAVE_EXPR.
1193 (remove_conversions): Fix formatting.
1194
15bf7d19
EB
11952011-10-12 Eric Botcazou <ebotcazou@adacore.com>
1196
1197 * gcc-interface/ada-tree.h (DECL_LOOP_PARM_P): New flag.
1198 (DECL_INDUCTION_VAR): New macro.
1199 (SET_DECL_INDUCTION_VAR): Likewise.
1200 * gcc-interface/gigi.h (convert_to_index_type): Declare.
1201 (gnat_invariant_expr): Likewise.
1202 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: If this is a loop
1203 parameter, set DECL_LOOP_PARM_P on it.
1204 * gcc-interface/misc.c (gnat_print_decl) <VAR_DECL>: If DECL_LOOP_PARM_P
1205 is set, print DECL_INDUCTION_VAR instead of DECL_RENAMED_OBJECT.
1206 * gcc-interface/trans.c (gnu_loop_label_stack): Delete.
1207 (struct range_check_info_d): New type.
1208 (struct loop_info_d): Likewise.
1209 (gnu_loop_stack): New stack.
1210 (Identifier_to_gnu): Set TREE_READONLY flag on the first dereference
1211 built for a by-double-ref read-only parameter. If DECL_LOOP_PARM_P
1212 is set, do not test DECL_RENAMED_OBJECT.
1213 (push_range_check_info): New function.
1214 (Loop_Statement_to_gnu): Push a new struct loop_info_d instead of just
1215 the label. Reference the label and the iteration variable from it.
1216 Build the special induction variable in the unsigned version of the
1217 size type, if it is larger than the base type. And attach it to the
1218 iteration variable if the latter isn't by-ref. In the iteration scheme
1219 case, initialize the invariant conditions in front of the loop if
1220 deemed profitable. Use gnu_loop_stack.
1221 (gnat_to_gnu) <N_Exit_Statement>: Use gnu_loop_stack.
1222 <N_Raise_Constraint_Error>: Always process the reason. In the range
1223 check and related cases, and if loop unswitching is enabled, compute
1224 invariant conditions and push this information onto the stack.
1225 Do not translate again the condition if it has been already translated.
1226 * gcc-interface/utils.c (record_global_renaming_pointer): Assert that
1227 DECL_LOOP_PARM_P isn't set.
1228 (convert_to_index_type): New function.
1229 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Use it in order
1230 to convert the index from the base index type to sizetype.
1231 (gnat_invariant_expr): New function.
1232
e79983f4
MM
12332011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
1234
1235 * gcc-interface/utils.c (def_builtin_1): Delete old interface with
1236 two parallel arrays to hold standard builtin declarations, and
1237 replace it with a function based interface that can support
15bf7d19 1238 creating builtins on the fly in the future.
e79983f4
MM
1239 * gcc-interface/trans.c (Exception_Handler_to_gnu_zcx): Ditto.
1240 (gnat_to_gnu): Ditto.
1241
228ee426
EB
12422011-10-07 Eric Botcazou <ebotcazou@adacore.com>
1243
1244 PR lto/50492
1245 * gcc-interface/gigi.h (gnat_pushdecl): Adjust comment.
1246 * gcc-interface/utils.c (global_context): New variable.
1247 (gnat_pushdecl): Initialize it and set it as the DECL_CONTEXT of DECLs
1248 that are either public external or at top level. Use "No" macro.
1249 (end_subprog_body): Call decl_function_context.
1250 (rest_of_subprog_body_compilation): Likewise.
1251
71196d4e
EB
12522011-10-07 Eric Botcazou <ebotcazou@adacore.com>
1253
1254 * gcc-interface/gigi.h (gnat_useless_type_conversion): Declare.
1255 (rest_of_subprog_body_compilation): Likewise.
1256 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Variable>: For renaming,
1257 test for useless conversions by means of gnat_useless_type_conversion.
1258 * gcc-interface/trans.c: Include bitmap.h and cgraph.h.
1259 (language_function): Add named_ret_val and other_ret_val.
1260 (f_named_ret_val): New macro.
1261 (f_other_ret_val): Likewise.
1262 (gigi): Call rest_of_subprog_body_compilation.
1263 (struct nrv_data): New structure.
1264 (is_nrv_p): New predicate.
1265 (prune_nrv_r): New helper function.
1266 (prune_nrv_in_block): New function.
1267 (finalize_nrv_r): New helper function.
1268 (finalize_nrv): New function.
1269 (return_value_ok_for_nrv_p): New predicate.
1270 (build_return_expr): If optimization is enabled, record candidates for
1271 the Named Return Value optimization.
1272 (build_function_stub): Call rest_of_subprog_body_compilation.
1273 (Subprogram_Body_to_gnu): If optimization is enabled and there are
1274 candidates, finalize the Named Return Value optimization.
1275 Call rest_of_subprog_body_compilation.
1276 (call_to_gnu): At the end, if a return value is needed, simplify the
1277 result before wrapping it up in a COMPOUND_EXPR.
1278 * gcc-interface/utils.c (end_subprog_body): Split into...
1279 (rest_of_subprog_body_compilation): ...this. New function.
1280 (gnat_useless_type_conversion): Likewise.
1281
885c4871
AC
12822011-10-06 Thomas Quinot <quinot@adacore.com>
1283
1284 * einfo.ads, exp_attr.adb, exp_ch3.adb, exp_ch4.adb, exp_ch7.adb,
1285 exp_ch9.adb, exp_ch9.ads, exp_strm.adb, exp_util.adb, freeze.adb,
1286 g-debpoo.ads, opt.ads, par-ch12.adb, par-ch2.adb, par-ch3.adb,
1287 par-ch5.adb, par-ch6.adb, sem_aggr.adb, sem_attr.adb, sem_cat.adb,
1288 sem_ch10.adb, sem_ch12.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
1289 sem_ch6.adb, sem_intr.adb, sem_res.ads, sem_type.adb, sem_util.adb,
1290 s-regpat.adb, s-tpopde-vms.ads: Minor reformatting.
1291 * s-osinte-freebsd.ads: Fix for tasking failures on FreeBSD.
1292
12932011-10-06 Ed Schonberg <schonberg@adacore.com>
1294
1295 * a-cihase.adb, a-ciorma.adb: Avoid accessibility checks in container
1296 references.
1297
12982011-10-06 Matthew Heaney <heaney@adacore.com>
1299
1300 * a-cuprqu.ads, a-cuprqu.adb, a-cbprqu.ads, a-cbprqu.adb
1301 (Dequeue_Only_High_Priority): Protected procedure now implemented.
1302
13032011-10-06 Vincent Celier <celier@adacore.com>
1304
1305 * g-trasym.adb: Replace old implementation with the default
1306 implementation that returns list of addresses as "0x...".
1307 * g-trasym.ads: Update the list of platforms with the full
1308 capability. Indicate that there is a default implementation
1309 for other platforms.
1310 * g-trasym-unimplemented.ads, g-trasym-unimplemented.adb: Remove.
1311 * gcc-interface/Makefile.in: Remove g-trasym-unimplemented, as there
1312 is now a default implementation for all platforms without the full
1313 capability.
1314
ce72a9a3
AC
13152011-10-06 Robert Dewar <dewar@adacore.com>
1316
1317 * a-ciorse.adb, a-cihase.adb, a-cihase.ads, a-coorse.adb,
1318 a-cborse.adb, a-comutr.adb, a-ciorma.adb, a-cbmutr.adb,
1319 a-cbmutr.ads, a-cbhase.adb, a-cbhase.ads: Minor reformatting and code
1320 reorganization (use conditional expressions).
1321
13222011-10-06 Robert Dewar <dewar@adacore.com>
1323
1324 * sem_res.adb (Resolve_Arithmetic_Op): Fix bad warning for
1325 floating divide by zero.
1326
13272011-10-06 Ed Schonberg <schonberg@adacore.com>
1328
1329 * sem_ch6.adb: Limited interfaces that are not immutably limited
1330 are OK in return statements.
1331
a912d7d9
IS
13322011-09-30 Iain Sandoe <iains@gcc.gnu.org>
1333
1334 * gcc-interface/Makefile.in (Darwin): Partial reversion of previous
1335 change to powerpc section.
1336
39ffb1f9
IS
13372011-09-29 Iain Sandoe <iains@gcc.gnu.org>
1338
1339 * gcc-interface/Makefile.in (Darwin): Factor LIBGNAT_TARGET_PAIRS
1340 across the port.
1341
ffb35bbf
ES
13422011-09-27 Ed Schonberg <schonberg@adacore.com>
1343
1344 * a-cbhase.adb, a-cbhase.ads, a-cborse.adb, a-cborse.ads,
1345 a-cihase.adb, a-cihase.ads, a-ciorse.adb, a-ciorse.ads,
1346 a-coorse.adb, a-coorse.ads: Add iterator machinery to bounded sets and
1347 indefinite sets.
1348 * a-coorma.ads: Minor reformmating.
1349 * einfo.ads: Improve the comment describing the
1350 Directly_Designated_Type function.
1351 * a-ciorma.adb, a-ciorma.ads: Add iterator machinery to indefinite
1352 ordered maps.
1353 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
1354 dependencies.
1355
da124b6a
AC
13562011-09-27 Robert Dewar <dewar@adacore.com>
1357
1358 * a-comutr.ads: Minor reformatting.
1359
13602011-09-27 Ed Schonberg <schonberg@adacore.com>
1361
1362 * a-cimutr.adb, a-cimutr.ads, a-cbmutr.adb, a-cbmutr.ads: Add children
1363 iterators to multiway trees.
1364
13652011-09-27 Yannick Moy <moy@adacore.com>
1366
1367 * debug.adb (d.D): New option for strict Alfa mode.
1368 * opt.ads (Strict_Alfa_Mode): New flag to interpret compiler
1369 permissions as strictly as possible.
1370 * sem_ch3.adb (Signed_Integer_Type_Declaration): In non-strict
1371 Alfa mode, now, interpret ranges of base types like GNAT does; in
1372 strict mode, simply change the range of the implicit base Itype.
1373 * gnat1drv.adb: Update comments. Set Strict_Alfa_Mode.
1374
706a4067
AC
13752011-09-27 Robert Dewar <dewar@adacore.com>
1376
1377 * exp_ch9.adb: Minor comment fixes.
1378
13792011-09-27 Ed Schonberg <schonberg@adacore.com>
1380
1381 * a-comutr.adb, a-comutr.ads: Add children iterators on multiway
1382 trees.
1383
05c1e7d2
AC
13842011-09-27 Eric Botcazou <ebotcazou@adacore.com>
1385
1386 * checks.adb (Apply_Scalar_Range_Check): Use Designated_Type
1387 instead of Directly_Designated_Type in the indirect array case.
1388
13892011-09-27 Robert Dewar <dewar@adacore.com>
1390
1391 * exp_util.adb, exp_aggr.adb: Minor reformatting.
1392
65e78a74
AC
13932011-09-27 Ed Schonberg <schonberg@adacore.com>
1394
1395 * sinfo.ads, par-ch3.adb: Minor comment update: aspect specification
1396 on subtype declarations.
1397 * exp_aggr.adb: Minor comment update.
1398
13992011-09-27 Eric Botcazou <ebotcazou@adacore.com>
1400
1401 * exp_util.adb (Safe_Prefixed_Reference): Remove always-false
1402 test in the N_Explicit_Dereference case. Fold double logical
1403 negation in the special loop case and conditionalize it on
1404 Variable_Ref being true.
1405
14062011-09-27 Ed Schonberg <schonberg@adacore.com>
1407
1408 * sem_ch4.adb (Analyze_Selected_Component): If the prefix is a
1409 single protected object and the selector is a discriminant or an
1410 entry family, this is a non-overloaded candidate interpretation,
1411 and possible primitive operations of the type must not be
1412 examined.
1413
14142011-09-27 Arnaud Charlet <charlet@adacore.com>
1415
1416 * s-taspri-posix-noaltstack.ads (Lock): Mark fields aliased.
1417
6f5add73
AC
14182011-09-27 Pascal Obry <obry@adacore.com>
1419
1420 * s-osinte-hpux.ads, s-osinte-aix.ads, s-osinte-solaris-posix.ads,
1421 s-osinte-irix.ads, s-osinte-darwin.ads, s-osinte-freebsd.ads:
1422 Add dummy definitions for pthread_rwlock_t
1423 and pthread_rwlockattr_t on all POSIX platforms.
1424 * s-taprop-irix.adb, s-taprop-posix.adb (Initialize_Lock): Fix lock
1425 reference.
1426 (Finalize_Lock): Likewise.
1427 (Write_Lock): Likewise.
1428 (Unlock): Likewise.
1429
14302011-09-27 Tristan Gingold <gingold@adacore.com>
1431
1432 * s-tassta.adb (Task_Wrapper): Increase Guard_Page_Size value for
1433 windows 64.
1434
64a63cd5
PO
14352011-09-27 Pascal Obry <obry@adacore.com>
1436
1437 * s-osinte-hpux.ads, s-taprop-vxworks.adb, s-taspri-vxworks.ads,
1438 s-taprop-tru64.adb, s-osinte-aix.ads, s-taspri-posix-noaltstack.ads,
1439 s-taspri-mingw.ads, s-taprop-vms.adb, s-tpoben.adb, s-tpoben.ads,
1440 s-taprop-mingw.adb, s-taprob.adb, s-taprob.ads,
1441 s-osinte-solaris-posix.ads, s-taprop-solaris.adb, s-taspri-solaris.ads,
1442 s-osinte-irix.ads, s-taprop-irix.adb, s-osinte-darwin.ads,
1443 s-taspri-dummy.ads, s-taspri-posix.ads, s-taprop.ads,
1444 s-taspri-vms.ads, s-osinte-freebsd.ads, s-taprop-hpux-dce.adb,
1445 s-taspri-hpux-dce.ads, s-taspri-tru64.ads, s-taprop-dummy.adb,
1446 s-taprop-posix.adb: Revert previous changes.
1447 (Lock): Now a record containing the two possible lock
1448 (mutex and read/write) defined in OS_Interface.
1449 * s-taprop-linux.adb (Finalize_Protection): Use r/w lock for
1450 'R' locking policy.
1451 (Initialize_Protection): Likewise.
1452 (Lock): Likewise.
1453 (Lock_Read_Only): Likewise.
1454 (Unlock): Likewise.
1455
f672a756
AC
14562011-09-27 Pascal Obry <obry@adacore.com>
1457
1458 * s-taspri-posix-noaltstack.ads (RW_Lock): This type is now defined as
1459 OS_Interface.pthread_rwlock_t.
1460
14612011-09-27 Robert Dewar <dewar@adacore.com>
1462
1463 * exp_ch9.adb, a-cimutr.adb, a-cimutr.ads, gnat1drv.adb, a-comutr.adb,
1464 a-comutr.ads, exp_dist.adb, a-cbmutr.adb, a-cbmutr.ads,
1465 sem_ch5.adb, sem_util.adb: Minor reformatting.
1466
7a44cb69
PO
14672011-09-27 Pascal Obry <obry@adacore.com>
1468
1469 * s-taprop.ads (Initialize_Lock)[RW_Lock]: New spec for r/w lock.
1470 (Finalize_Lock)[RW_Lock]: Likewise.
1471 (Write_Lock)[RW_Lock]: Likewise.
1472 (Unlock)[RW_Lock]: Likewise.
1473 (Read_Lock): Define L as RW_Lock (instead of Lock).
1474 * s-taprop-linux.adb (Initialize_Lock)[RW_Lock]: New
1475 routine for r/w lock.
1476 (Finalize_Lock)[RW_Lock]: Likewise.
1477 (Write_Lock)[RW_Lock]: Likewise.
1478 (Unlock)[RW_Lock]: Likewise.
1479 (Read_Lock): Define L as RW_Lock (instead of Lock).
1480
1481 * s-taprop-vxworks.adb, s-taprop-tru64.adb, s-taprop-vms.adb,
1482 s-taprop-mingw.adb, s-taprop-solaris.adb, s-taprop-irix.adb,
1483 s-taprop-hpux-dce.adb, s-taprop-dummy.adb, s-taprop-posix.adb
1484 (Initialize_Lock)[RW_Lock]: Same implementation as corresponding
1485 routine for standard lock.
1486 (Finalize_Lock)[RW_Lock]: Likewise.
1487 (Write_Lock)[RW_Lock]: Likewise.
1488 (Unlock)[RW_Lock]: Likewise.
1489 (Read_Lock): Define L as RW_Lock (instead of Lock).
1490 * s-taprob.ads, s-tpoben.ads (Protection): Add RWL (RW_Lock)
1491 in the record definition.
1492 * s-taprob.adb, s-taproben.adb (Finalize_Protection): Use r/w
1493 lock for 'R' locking policy.
1494 (Initialize_Protection): Likewise.
1495 (Lock): Likewise.
1496 (Lock_Read_Only): Likewise.
1497 (Unlock): Likewise.
1498 * s-taspri-posix.ads (RW_Lock): New type defined as
1499 OS_Interface.pthread_rwlock_t.
1500
1501 * s-taspri-vxworks.ads, s-taspri-posix-noaltstack.ads,
1502 s-taspri-mingw.ads, s-taspri-solaris.ads, s-taspri-dummy.ads,
1503 s-taspri-posix.ads, s-taspri-vms.ads, s-taspri-hpux-dce.ads,
1504 s-taspri-tru64.ads (RW_Lock): New type defined as alias to Lock.
1505
4c173b50
PO
15062011-09-27 Pascal Obry <obry@adacore.com>
1507
1508 * exp_ch9.adb, s-taspri-posix.ads: Minor reformatting.
1509
15102011-09-27 Pascal Obry <obry@adacore.com>
1511
1512 * s-osinte-aix.ads, s-osinte-darwin.ads, s-osinte-freebsd.ads,
1513 s-osinte-hpux.ads, s-osinte-irix.ads,
1514 s-osinte-solaris-posix.ads (pthread_rwlock_t): New definition alias of
1515 pthread_mutex_t.
1516 (pthread_rwlockattr_t): New definition alias of pthread_mutexattr_t.
1517 * s-osinte-linux.ads (pthread_rwlock_t, pthread_rwlockattr_t,
1518 pthread_rwlockattr_init, pthread_rwlockattr_destroy,
1519 pthread_rwlockattr_setkind_np, pthread_rwlock_init,
1520 pthread_rwlock_destroy, pthread_rwlock_rdlock,
1521 pthread_rwlock_wrlock, pthread_rwlock_unlock): New.
1522
343250a6
PO
15232011-09-27 Pascal Obry <obry@adacore.com>
1524
1525 * rtsfind.ads: Add RE_Lock_Read_Only into rtsfind circuitry.
1526 (RE_Id): Add RE_Lock_Read_Only.
1527 (RE_Unit_Table): Likewise.
1528 * sem_prag.adb (Process_Convention): Change Pragma_Locking_Policy
1529 to lift restriction on first character. Handle now the
1530 Name_Concurrent_Readers_Locking where policy character is set to
1531 'R'.
1532 * snames.ads-tmpl (Name_Concurrent_Readers_Locking): New
1533 constant.
1534 * exp_ch9.adb (Build_Protected_Subprogram_Body): Generate a
1535 read only lock for function in protected object.
1536 * s-taprob.ads (Lock_Read_Only): Remove obsolete comment as
1537 this routine is now used.
1538
2d0dd51a
EB
15392011-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1540
1541 * s-atocou-x86.adb (Decrement): Use %;.
1542 (Increment): Likewise.
1543
bdbebf66
EB
15442011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1545
1546 * gcc-interface/utils2.c (build_allocator): Set TREE_THIS_NOTRAP on the
1547 dereference of the pointer to the storage area. Remove useless type
1548 conversions and factor out common code.
1549
1aa291f7
EB
15502011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1551
1552 * gcc-interface/utils.c (maybe_unconstrained_array): Declare TYPE local
1553 variable and use it throughout.
1554 <UNCONSTRAINED_ARRAY_TYPE>: Add 'break' at the end.
1555 <RECORD_TYPE>: Do not unconditionally convert to the unpadded type as a
1556 first step. Also convert to the unpadded type as a last step.
1557
7d76717d
EB
15582011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1559
1560 * gcc-interface/gigi.h (create_subprog_decl): Replace TREE_CHAIN with
1561 DECL_CHAIN in comment.
1562 * gcc-interface/trans.c (gigi): Likewise.
1563 (Attribute_to_gnu): Likewise.
1564 (build_function_stub): Likewise.
1565 (gnat_to_gnu): Likewise.
1566 * gcc-interface/utils.c (create_subprog_decl): Likewise.
1567 (convert_vms_descriptor64): Likewise.
1568 (convert_vms_descriptor32): Likewise.
1569
42acad07
EB
15702011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1571
1572 * gcc-interface/trans.c (assoc_to_constructor): Minor tweaks.
1573 * gcc-interface/utils2.c (build_simple_component_ref): Fix formatting
1574 issues. Use COMPLETE_TYPE_P in assertion. Also set TREE_READONLY if
1575 the type of the record is TYPE_READONLY.
1576
a1d72281
EB
15772011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1578 Robert Dewar <dewar@adacore.com>
1579
1580 * sem_ch6.adb (Set_Formal_Mode): Set Can_Never_Be_Null on an IN or IN
1581 OUT formal parameter which is of an null-exclusion access subtype.
1582
a1c7d797
EB
15832011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1584
1585 * gcc-interface/ada-tree.h (DECL_CAN_NEVER_BE_NULL_P): New macro.
1586 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Set the flag.
1587 (gnat_to_gnu_param): Likewise.
1588 * gcc-interface/utils.c (convert) <UNCONSTRAINED_ARRAY_REF>: Invoke
1589 maybe_unconstrained_array instead of doing the work manually.
1590 (maybe_unconstrained_array): Propagate the TREE_THIS_NOTRAP flag.
1591 * gcc-interface/utils2.c (build_unary_op) <INDIRECT_REF>: If operand
1592 is a DECL with the flag, set TREE_THIS_NOTRAP on the reference.
1593 (gnat_stabilize_reference_1): Propagate the TREE_THIS_NOTRAP flag.
1594 (gnat_stabilize_reference): Likewise.
1595
50179d58
EB
15962011-09-26 Eric Botcazou <ebotcazou@adacore.com>
1597
1598 * gcc-interface/ada-tree.h (TYPE_NULL_BOUNDS): New macro.
1599 (SET_TYPE_NULL_BOUNDS): Likewise.
1600 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Set again
1601 TREE_THIS_NOTRAP on the INDIRECT_REF node built for the template.
1602 * gcc-interface/trans.c (Identifier_to_gnu): Return initializers of fat
1603 pointer types.
1604 * gcc-interface/utils.c (create_var_decl_1): If the object is external,
1605 check that the initializer is a valid constant expression for use in
1606 initializing a static variable. Add missing guard.
1607 (update_pointer_to): Adjust TYPE_NULL_BOUNDS if set.
1608 (convert_to_fat_pointer): In the null fat pointer case, build a valid
1609 pointer for the bounds.
1610 * gcc-interface/utils2.c (compare_fat_pointers): New function.
1611 (build_binary_op) <EQ_EXPR>: Call it to compare fat pointers.
1612
ad1d36ba
EB
16132011-09-25 Eric Botcazou <ebotcazou@adacore.com>
1614
1615 * gcc-interface/ada-tree.h (TREE_THIS_NOTRAP): Redefine.
1616 * gcc-interface/trans.c (Identifier_to_gnu): Factor out common code in
1617 the by-ref case. Do not set TREE_READONLY on a renamed object. Set
1618 TREE_THIS_NOTRAP on UNCONSTRAINED_ARRAY_REF nodes.
1619 (Attribute_to_gnu) <Attr_Length>: Expand the use of the parameter cache
1620 to the indirect case.
1621 * gcc-interface/utils.c (convert) <UNCONSTRAINED_ARRAY_REF>: Preserve
1622 the TREE_THIS_NOTRAP flag.
1623
6162cec0
EB
16242011-09-25 Eric Botcazou <ebotcazou@adacore.com>
1625
1626 * gcc-interface/trans.c (Loop_Statement_to_gnu): In the case of an
1627 iteration scheme, always generate the do-while form if optimization
1628 is enabled. Use more straightforward test at the end.
1629
dee12fcd
EB
16302011-09-25 Eric Botcazou <ebotcazou@adacore.com>
1631
1632 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Subtype>: Use
1633 XNEW instead of xmalloc. Do not build useless pointer type.
1634 <E_Anonymous_Access_Subprogram_Type>: Use XNEW instead of xmalloc.
1635 * gcc-interface/trans.c (gnat_to_gnu) <N_Raise_Constraint_Error>: Tidy.
1636 * gcc-interface/utils2.c (build_unary_op): Remove local variable.
1637
dea976c4
EB
16382011-09-25 Eric Botcazou <ebotcazou@adacore.com>
1639
1640 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Do not promote
1641 the alignment if this doesn't prevent BLKmode access to the object.
1642
655ae828
IS
16432011-09-24 Iain Sandoe <iains@gcc.gnu.org>
1644
1645 * gcc-interface/Makefile.in (darwin): Do not issue the
1646 '-flat_namespace' linker flag during Ada build.
1647 * mlib-tgt-specific-darwin.adb: Remove '-flat_namespace' flag from the
1648 default shared library options.
1649
0e871c15
AO
16502011-09-19 Alexandre Oliva <aoliva@redhat.com>
1651
1652 * gcc-interface/decl.c (annotate_value): Look up expression for
1653 insertion in the cache at the end.
1654
1e6a52b4
AC
16552011-09-19 Arnaud Charlet <charlet@adacore.com>
1656
1657 * gcc-interface/Make-lang.in: Update dependencies.
1658
a3068ca6
AC
16592011-09-19 Steve Baird <baird@adacore.com>
1660
1661 * snames.ads-tmpl: Move declaration of Name_Annotate into range of
1662 configuration pragma names so that Is_Configuration_Pragma_Name
1663 will return True for Name_Annotate. Make corresponding change in
1664 Pragma_Id enumeration type. This is needed to allow an Annotate
1665 pragma to occur in a configuration pragma file (typically,
1666 a gnat.adc file).
1667 * gnat_ugn.texi: Add Annotate to the list of configuration pragmas.
1668 * gnat_rm.texi: Note that pragma Annotate may be used as a
1669 configuration pragma.
1670
16712011-09-19 Ed Schonberg <schonberg@adacore.com>
1672
1673 * a-cbmutr.adb, a-cbmutr.ads, a-cimutr.adb, a-cimutr.ads,
1674 a-comutr.adb, a-comutr.ads: Add iterator machinery for multiway trees.
1675
16762011-09-19 Yannick Moy <moy@adacore.com>
1677
1678 * exp_alfa.adb, exp_alfa.ads (Expand_Alfa_N_In): New function
1679 for expansion of set membership.
1680 (Expand_Alfa): Call expansion for N_In and N_Not_In nodes.
1681 * exp_ch4.adb, exp_ch4.ads (Expand_Set_Membership): Make procedure
1682 visible for use in Alfa expansion.
1683 * sem_ch5.adb (Analyze_Iterator_Specification): Introduce loop
1684 variable in Alfa mode.
1685
16862011-09-19 Thomas Quinot <quinot@adacore.com>
1687
1688 * s-osinte-darwin.ads: Change SIGADAABRT on Darwin to SIGABRT.
1689
16902011-09-19 Thomas Quinot <quinot@adacore.com>
1691
1692 * exp_ch9.adb: Minor reformatting.
1693
16942011-09-19 Hristian Kirtchev <kirtchev@adacore.com>
1695
1696 * freeze.adb (Build_Renamed_Body): Generic subprograms
1697 instantiations cannot be poperly inlined by the compiler, do
1698 not set the Body_To_Inline attribute in such cases.
1699 * sem_ch12.adb (Analyze_Subprogram_Instantiation): Inherit all
1700 inlining-related flags from the generic subprogram declaration.
1701
17022011-09-19 Thomas Quinot <quinot@adacore.com>
1703
1704 * exp_dist.adb, rtsfind.ads, sem_util.adb, sem_util.ads
1705 (Build_Stub_Type): Remove, instead copy components from
1706 System.Partition_Interface.RACW_Stub_Type.
1707 (RPC_Receiver_Decl): Remainder of code from old Build_Stub_Type routine.
1708 (Copy_Component_List): New subprogram.
1709
17102011-09-19 Yannick Moy <moy@adacore.com>
1711
1712 * lib-xref.adb (Generate_Reference): Ignore references to
1713 constants in Standard.
1714
e7fceebc
AC
17152011-09-19 Robert Dewar <dewar@adacore.com>
1716
1717 * err_vars.ads, errout.ads: Minor reformatting.
1718
17192011-09-19 Robert Dewar <dewar@adacore.com>
1720
1721 * aspects.ads (Impl_Defined_Aspects): New array
1722 * lib-writ.adb (No_Dependences): New name for No_Dependence
1723 * restrict.adb (No_Dependences): New name for No_Dependence
1724 (Check_Restriction_No_Specification_Of_Aspect): New
1725 procedure.
1726 (Set_Restriction_No_Specification_Of_Aspect): New procedure
1727 (Restricted_Profile_Result): New variable
1728 (No_Specification_Of_Aspects): New variable
1729 (No_Specification_Of_Aspect_Warning): New variable
1730 * restrict.ads (No_Dependences): New name for No_Dependence
1731 (Check_Restriction_No_Specification_Of_Aspect): New procedure
1732 (Set_Restriction_No_Specification_Of_Aspect): New procedure
1733 * s-rident.ads: Add restriction
1734 No_Implementation_Aspect_Specifications, this is also added to
1735 the No_Implementation_Extensions profile.
1736 * sem_ch13.adb (Analyze_Aspect_Specifications): Check
1737 No_Implementation_Defined_Aspects
1738 (Analyze_Aspect_Specifications): Check No_Specification_Of_Aspect
1739 * sem_prag.adb (Analyze_Aspect_Specifications): Check
1740 No_Implementation_Aspects
1741 (Analyze_Aspect_Specifications): Check No_Specification_Of_Aspect
1742 * snames.ads-tmpl (Name_No_Specification_Of_Aspect): New name
1743
17442011-09-19 Yannick Moy <moy@adacore.com>
1745
1746 * lib-xref.adb (Generate_Reference): Take into account multiple
1747 renamings for Alfa refs.
1748
17492011-09-19 Thomas Quinot <quinot@adacore.com>
1750
1751 * g-socthi-mingw.adb: Minor reformatting.
1752
17532011-09-19 Yannick Moy <moy@adacore.com>
1754
1755 * gnat1drv.adb (Adjust_Global_Switches): Set tagged type
1756 expansion to False in mode Alfa
1757
17582011-09-19 Pascal Obry <obry@adacore.com>
1759
1760 * mingw32.h: Remove obsolete code needed for old versions
1761 of MingW.
1762
e5a163fc
RD
17632011-09-19 Robert Dewar <dewar@adacore.com>
1764
1765 * errout.ads: Minor reformatting.
1766
6d7e5c54
AC
17672011-09-19 Ed Schonberg <schonberg@adacore.com>
1768
1769 * sem_ch6.adb (Analyze_Expression_Function): When the expression
1770 function is transformed into a declaration and a body, insert
1771 body at the end of the declarative part, to prevent premature
1772 freeze actions, and preserve original specification in the
1773 subprogram declaration.
1774
17752011-09-19 Vincent Celier <celier@adacore.com>
1776
1777 * projects.texi: Minor editing.
1778
99ba07a3
AC
17792011-09-19 Robert Dewar <dewar@adacore.com>
1780
1781 * sem_aggr.adb, lib-writ.ads, s-restri.ads, sem_ch6.adb,
1782 exp_aggr.adb: Minor reformatting.
1783
17842011-09-19 Yannick Moy <moy@adacore.com>
1785
1786 * lib-xref.adb (Generate_Reference): Change entity referenced
1787 to underlying object if any, or else reference to the HEAP.
1788
41781043
AC
17892011-09-15 Arnaud Charlet <charlet@adacore.com>
1790
1791 * gcc-interface/Make-lang.in: Update dependencies.
1792
804ff4c3
AC
17932011-09-15 Robert Dewar <dewar@adacore.com>
1794
1795 * tree_io.ads: Minor reformatting.
1796 * a-intnam.ads: Fix bad header.
1797
17982011-09-15 Thomas Quinot <quinot@adacore.com>
1799
1800 * a-exexpr-gcc.adb: Minor reformatting.
1801
18022011-09-15 Yannick Moy <moy@adacore.com>
1803
1804 * sem_ch6.adb: Propagate information that an expression function comes
1805 from source (otherwise references to this entity are not stored).
1806
0b5b2bbc
AC
18072011-09-15 Robert Dewar <dewar@adacore.com>
1808
1809 * a-cdlili.adb, a-coinve.adb, a-stzunb-shared.ads, a-suezst.adb,
1810 a-suenco.adb, a-stwiun-shared.ads, a-cobove.adb, a-convec.adb,
1811 a-btgbso.adb, a-cbdlli.adb, a-suewst.adb: Minor reformatting.
1812
18132011-09-15 Ed Schonberg <schonberg@adacore.com>
1814
1815 * sem_ch6.adb (Analyze_Expression_Function): Code cleanup:
1816 if the expression function is not a completion, create a
1817 new specification for the generated declaration, and keep the
1818 original specification in the generated body. Shorter code also
1819 ensures that proper warnings are generated for unused formals
1820 in all cases.
1821
18222011-09-15 Sergey Rybin <rybin@adacore.com>
1823
1824 * tree_io.ads: Update ASIS_Version_Number because of the changes
1825 in the tree structures for expression functions.
1826
18272011-09-15 Arnaud Charlet <charlet@adacore.com>
1828
1829 * s-osinte-aix.ads, s-osinte-darwin.ads, s-osinte-freebsd.ads,
1830 s-osinte-hpux.ads, s-osinte-lynxos.ads, s-osinte-solaris-posix.ads,
1831 s-taprop-posix.adb (CLOCK_MONOTONIC): New constant.
1832 (CLOCK_REALTIME): Fix wrong value on some OSes.
1833 * s-taprop-posix.adb (Monotonic_Clock): Use CLOCK_MONOTONIC.
1834
7e169899
EB
18352011-09-11 Eric Botcazou <ebotcazou@adacore.com>
1836
1837 * gcc-interface/utils.c (maybe_unconstrained_array): In the reference
1838 to unconstrained array case, deal with each branch of a COND_EXPR.
1839 * gcc-interface/utils2.c (build_allocator): Deal with each branch of
1840 a COND_EXPR in the initializer, if present.
1841
819a653e
EB
18422011-09-11 Eric Botcazou <ebotcazou@adacore.com>
1843
1844 * gcc-interface/decl.c (maybe_pad_type): Do not try to change the form
1845 of an addressable type.
1846 * gcc-interface/trans.c (gnat_gimplify_expr) <VIEW_CONVERT_EXPR>: New.
1847 Deal with those cases for which creating a temporary is mandatory.
1848
c946adde
EB
18492011-09-11 Eric Botcazou <ebotcazou@adacore.com>
1850
1851 * gcc-interface/trans.c (call_to_gnu): Use local variable. Make sure
1852 this is a real formal parameter before testing whether it is by ref.
1853
dddf8120
EB
18542011-09-11 Eric Botcazou <ebotcazou@adacore.com>
1855
1856 * gcc-interface/gigi.h (build_call_0_expr): Delete.
1857 (build_call_1_expr): Likewise.
1858 (build_call_2_expr): Likewise.
1859 (build_call_n_expr): New prototype.
1860 * gcc-interface/decl.c (gnat_to_gnu_entity): Use build_call_n_expr.
1861 * gcc-interface/trans.c (establish_gnat_vms_condition_handler): Ditto.
1862 (Handled_Sequence_Of_Statements_to_gnu): Likewise.
1863 (Exception_Handler_to_gnu_zcx): Likewise.
1864 (gnat_to_gnu): Likewise.
1865 (build_binary_op_trapv): Likewise.
1866 * gcc-interface/utils2.c (build_call_0_expr): Delete.
1867 (build_call_1_expr): Likewise.
1868 (build_call_2_expr): Likewise.
1869 (build_call_n_expr): New function.
1870 (build_call_raise): Use build_call_n_expr.
1871 (build_call_raise_range): Likewise.
1872 (build_call_raise_column): Likewise.
1873 (build_call_alloc_dealloc_proc): Likewise.
1874 (maybe_wrap_malloc): Likewise.
1875 (maybe_wrap_free): Likewise.
1876
d8e38554
EB
18772011-09-11 Eric Botcazou <ebotcazou@adacore.com>
1878
1879 * gcc-interface/trans.c (build_return_expr): Use void_type_node for
1880 MODIFY_EXPR.
1881 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Assert that
1882 the result type is null if ENABLE_CHECKING. Set operation_type at the
1883 end unconditionally if not set in the previous cases.
1884 Use build2 and void_type_node for MODIFY_EXPR.
1885 (build_allocator): Use NULL_TREE for MODIFY_EXPR.
1886
416de7d5
EB
18872011-09-08 Eric Botcazou <ebotcazou@adacore.com>
1888
1889 * gcc-interface/utils.c (unchecked_convert): Use a field of the right
1890 precision when converting to or from an integral type whose precision
1891 is not equal to its size.
1892
88b76013
IS
18932011-09-08 Iain Sandoe <iains@gcc.gnu.org>
1894
416de7d5 1895 * traceback.c (Darwin) USE_GCC_UNWINDER for Darwin versions >= 8.
88b76013 1896
1aeee5ad
IS
18972011-09-07 Iain Sandoe <iains@gcc.gnu.org>
1898
416de7d5 1899 * gcc-interface/Makefile.in (darwin): Provide powerpc64 system
1aeee5ad
IS
1900 implementation.
1901 * system-darwin-ppc64.ads: New file.
1902
f61fc398
IS
19032011-09-06 Iain Sandoe <iains@gcc.gnu.org>
1904
1905 * gcc-interface/Makefile.in (gnatlib-shared-darwin): Remove
1906 reference to "-lm".
1907
84ef27d3
IS
19082011-09-06 Iain Sandoe <iains@gcc.gnu.org>
1909
1910 * gcc-interface/Makefile.in (darwin, SO_OPTS): Provide architecture
1911 size switches to the link phase for shared libs.
1912
a1bf1ec7
IS
19132011-09-06 Iain Sandoe <iains@gcc.gnu.org>
1914
416de7d5 1915 * gcc-interface/Makefile.in (x86_64 darwin arch): Adjust
a1bf1ec7
IS
1916 LIBGNAT_TARGET_PAIRS for x86 and x86_64 variants.
1917
e972fd52
AC
19182011-09-06 Arnaud Charlet <charlet@adacore.com>
1919
1920 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in
1921 (gnattools, regnattools, cross-gnattools, canadian-gnattools,
1922 gnatlib, gnatlib-sjlj, gnatlib-zcx, gnatlib-shared, gnatlib_and_tools):
1923 New targets.
1924 (TOOLS_FLAGS_TO_PASS): New.
1925 (../stamp-tools): Reintroduce, to avoid merge conflicts.
1926
ef417be1
RD
19272011-09-06 Robert Dewar <dewar@adacore.com>
1928
1929 * sem_ch10.adb, impunit.ads, impunit.adb (Not_Impl_Defined_Unit): New
1930 name for Is_RM_Defined_Unit. Also several fixes to this unit.
1931
0a034606
RD
19322011-09-06 Robert Dewar <dewar@adacore.com>
1933
1934 * impunit.ads, impunit.adb (Is_RM_Defined_Unit): New function.
1935 * s-rident.ads: New restriction No_Implementation_Units
1936 (this restriction is also part of the profile
1937 No_Implementation_Extensions)
1938 * sem_ch10.adb (Analyze_With_Clause): Add check for
1939 No_Implementation_Units restriction.
1940
ebb6faaa
AC
19412011-09-06 Jerome Guitton <guitton@adacore.com>
1942
1943 * sysdep.c (__gnat_get_task_options): Disable VX_SPE_TASK
1944 on vThreads.
1945
19462011-09-06 Thomas Quinot <quinot@adacore.com>
1947
1948 * s-solita.adb: Minor reformatting.
1949
19502011-09-06 Ed Schonberg <schonberg@adacore.com>
1951
1952 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): The body that
1953 is a rewriting of an expression function does not freeze previous
1954 entities.
1955
19562011-09-06 Robert Dewar <dewar@adacore.com>
1957
1958 * impunit.adb (Is_Known_Unit): Fix bad handling of Ada 2012 case
1959
60435286
TG
19602011-09-06 Tristan Gingold <gingold@adacore.com>
1961
1962 * gcc-interface/Makefile.in: Handle e500v2-wrs-vxworksae like
1963 powerpc-wrs-vxworksae.
1964
08f8a983
AC
19652011-09-06 Thomas Quinot <quinot@adacore.com>
1966
1967 * s-os_lib.ads (Spawn): Minor documentation clarification,
1968 Success is True for a zero exit status.
1969
19702011-09-06 Ed Schonberg <schonberg@adacore.com>
1971
1972 * sem_ch5.adb: Add message for common iterator error.
1973
19742011-09-06 Ed Schonberg <schonberg@adacore.com>
1975
1976 * exp_ch3.adb (Build_Initialization_Call): If the target is a
1977 selected component discriminated by a current instance, replace
1978 the constraint with a reference to the target object, regardless
1979 of whether the context is an init_proc.
1980
19812011-09-06 Robert Dewar <dewar@adacore.com>
1982
1983 * exp_attr.adb: Descriptor_Size is never static.
1984
19852011-09-06 Robert Dewar <dewar@adacore.com>
1986
1987 * gnat_ugn.texi: Add documentation for LSLOC metric in gnatmetric
1988
19892011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
1990
1991 * gnat_rm.texi: Clarify that attribute Descriptor_Size is
1992 non-static.
1993
19942011-09-06 Ed Schonberg <schonberg@adacore.com>
1995
1996 * sem_res.adb (Resolve): An expression that is the body of an
1997 expression function does not freeze.
1998
19992011-09-06 Matthew Heaney <heaney@adacore.com>
2000
2001 * a-csquin.ads, a-cusyqu.adb, a-cbprqu.adb, a-cbsyqu.adb,
2002 a-cuprqu.adb: Changed copyright notice to indicate current
2003 year only.
2004
20052011-09-06 Vincent Celier <celier@adacore.com>
2006
2007 * prj.adb: Minor spelling error fix in comment
2008 * sem_res.adb: Minor reformatting
2009
20102011-09-06 Pascal Obry <obry@adacore.com>
2011
2012 * sysdep.c (winflush_nt): Removed as not needed anymore.
2013 (winflush_95): Likewise.
2014 (winflush_init): Likewise.
2015 (winflush_function): Likewise.
2016 (getc_immediate_common): Remove call to winflush_function.
2017
cb3d8731
HK
20182011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
2019
2020 * exp_attr.adb (Expand_N_Attribute_Reference): Rewrite the
2021 processing for Descriptor_Size.
2022 * gnat_rm.texi: Rephrase the wording for attribute Descriptor_Size
2023 to account for its broader usage.
2024 * sem_attr.adb (Analyze_Attribute): Change the error detection
2025 circuitry for Descriptor_Size as the attribute is now applicable
2026 to all types.
2027
f7e6fc47
RD
20282011-09-06 Robert Dewar <dewar@adacore.com>
2029
2030 * sem_attr.adb, prj-nmsc.adb, exp_aggr.adb: Minor reformatting.
2031
f8e9fc30
AC
20322011-09-06 Ed Schonberg <schonberg@adacore.com>
2033
2034 * lib-xref.adb (OK_To_Set_Referenced): A reference to a formal
2035 in a parameter association must not set the Referenced flag on
2036 the formal.
2037 * prj-nmsc.adb (Check_File_Naming_Schemes): Remove useless formal
2038
20392011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
2040
2041 * gnat_rm.texi: Add a section on attribute Descriptor_Size
2042
e8e38f35
AC
20432011-09-06 Arnaud Charlet <charlet@adacore.com>
2044
2045 * gcc-interface/Makefile.in (common-tools, gnatmake-re,
2046 gnatlink-re): Speed up by using -j0.
2047
ba759acd
AC
20482011-09-06 Yannick Moy <moy@adacore.com>
2049
2050 * sem_ch13.adb (Analyze_Aspect_Specifications): Call
2051 Set_Corresponding_Aspect when creating pragma from aspect.
2052 (Add_Predicates): Use new field Corresponding_Aspect.
2053 * sem_prag.adb (Analyze_Pragma): Make Pname hold source aspect
2054 name when present, for the purpose of issuing error messages;
2055 remove local procedure Error_Pragma_Arg_Alternate_Name.
2056 * sinfo.adb, sinfo.ads (Corresponding_Aspect): New field in
2057 N_Pragma node.
2058 (From_Dynamic_Predicate, From_Static_Predicate): Remove fields from
2059 N_Pragma node.
2060
20612011-09-06 Robert Dewar <dewar@adacore.com>
2062
2063 * checks.adb, s-except.ads, g-socket.adb: Minor reformatting.
2064
20652011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
2066
2067 * exp_ch6.adb (Build_Heap_Allocator): Add new
2068 local variable Desig_Typ. Code and comment reformatting. Add
2069 machinery to ensure that the allocation uses a fat pointer when
2070 the type of the return object is a constrained array and the
2071 function return type is an unconstrained array.
2072
20732011-09-06 Vincent Celier <celier@adacore.com>
2074
2075 * make.adb, prj-part.adb, prj-nmsc.adb: Remove unused formal
2076 parameters in subprograms.
2077
20782011-09-06 Arnaud Charlet <charlet@adacore.com>
2079
2080 * s-taprop-mingw.adb (Finalize_TCB): Fix typo.
2081
20822011-09-06 Thomas Quinot <quinot@adacore.com>
2083
2084 * s-taprop-vxworks.adb, s-tpoaal.adb, s-tpopsp-vxworks.adb
2085 (System.Tasking.Primitive_Operations.Specific.Delete): Remove
2086 subprogram.
2087 (System.Tasking.Primitive_Operations.Specific.Set): If argument
2088 is null, destroy task specific data, to make API consistent with
2089 other platforms, and thus compatible with the shared version
2090 of s-tpoaal.adb.
2091 (System.Tasking.Primitive_Operations.ATCB_Allocation.Free_ATCB):
2092 Document the above assumption.
2093
f4f92d9d
AC
20942011-09-06 Ed Schonberg <schonberg@adacore.com>
2095
2096 * exp_ch6.adb (Expand_Inlined_Call): Fix use of uninitialized
2097 variable for type of return value when return type is
2098 unconstrained and context is an assignment.
2099
21002011-09-06 Ed Schonberg <schonberg@adacore.com>
2101
2102 * sem_ch8.adb (Check_Class_Wide_Actual): Do not generate body of
2103 class-wide operation if expansion is not enabled.
2104
21052011-09-06 Eric Botcazou <ebotcazou@adacore.com>
2106
2107 * checks.adb (Apply_Scalar_Range_Check): Deal with access
2108 type prefix.
2109
21102011-09-06 Yannick Moy <moy@adacore.com>
2111
2112 * sem_ch13.adb (Analyze_Aspect_Specifications, case
2113 Aspect_Invariant): Do not issue error at this point on illegal
2114 pragma placement, as this is checked later on when analyzing
2115 the corresponding pragma.
2116 * sem_prag.adb (Error_Pragma_Arg_Alternate_Name): New procedure
2117 similar to Error_Pragma_Arg, except the source name of the
2118 aspect/pragma to use in warnings may be equal to parameter
2119 Alt_Name (Analyze_Pragma, case Pragma_Invariant): refine error
2120 message to distinguish source name of pragma/aspect, and whether
2121 the illegality resides in the type being public, or being private
2122 without a public declaration
2123
21242011-09-06 Thomas Quinot <quinot@adacore.com>
2125
2126 * g-socket.adb (Check_For_Fd_Set): On Windows, no need for bitmap
2127 size check (fd_set is implemented differently on that platform).
2128
21292011-09-06 Thomas Quinot <quinot@adacore.com>
2130
2131 * s-taprop-vxworks.adb, s-taprop-tru64.adb, s-taprop-vms.adb,
2132 s-tpoaal.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
2133 s-taprop-solaris.adb, s-taprop-irix.adb, s-taprop.ads,
2134 s-taprop-hpux-dce.adb, s-taprop-dummy.adb, s-taprop-posix.adb
2135 (ATCB_Allocation): New subpackage of
2136 System.Tasking.Primitive_Operations, shared across all targets
2137 with full tasking runtime.
2138 (ATCB_Allocation.New_ATCB): Moved there (from target specific
2139 s-taprop bodies).
2140 (ATCB_Allocation.Free_ATCB): New subprogram. Deallocate an ATCB,
2141 taking care of establishing a local temporary ATCB if the one
2142 being deallocated is Self, to avoid a reference to the freed
2143 ATCB in Abort_Undefer.
2144
21452011-09-06 Thomas Quinot <quinot@adacore.com>
2146
2147 * s-tassta.adb, s-taskin.ads (Free_Task): If the task is not
2148 terminated, mark it for deallocation upon termination.
2149 (Terminate_Task): Call Free_Task again if the task is marked
2150 for automatic deallocation upon termination.
2151
df177175
RD
21522011-09-06 Robert Dewar <dewar@adacore.com>
2153
2154 * a-cbprqu.ads, a-cbsyqu.ads, a-cuprqu.ads, a-cusyqu.ads,
2155 a-intnam-aix.ads, a-intnam-darwin.ads, a-intnam-dummy.ads,
2156 a-intnam-freebsd.ads, a-intnam-hpux.ads, a-intnam-irix.ads,
2157 a-intnam-linux.ads, a-intnam-lynxos.ads, a-intnam-mingw.ads,
2158 a-intnam-solaris.ads, a-intnam-tru64.ads,
2159 a-intnam-vms.ads, a-intnam-vxworks.ads, a-intnam.ads, interfac.ads,
2160 cstand.adb, s-maccod.ads: Mark all entities as Implementation_Defined
2161 * einfo.ads, einfo.adb (Is_Implementation_Defined): New flag
2162 * par-prag.adb: Add dummy entry for pragma Implementation_Defined
2163 * s-rident.ads: Add new restriction No_Implementation_Identifiers
2164 Add new profile No_Implementation_Extensions
2165 * sem_prag.adb: Implement pragma Implementation_Defined Implement
2166 profile No_Implementation_Extensions
2167 * sem_util.adb: Minor reformatting (Set_Entity_With_Style_Check):
2168 Check violation of restriction No_Implementation_Identifiers
2169 * snames.ads-tmpl: Add entries for pragma Implementation_Defined
2170 Add entry for Name_No_Implementation_Extensions
2171
21722011-09-06 Robert Dewar <dewar@adacore.com>
2173
2174 * impunit.ads: Minor reformatting.
2175
b991dd43
AC
21762011-09-06 Robert Dewar <dewar@adacore.com>
2177
2178 * ali.adb, sem_ch13.adb, lib-xref.adb: Minor reformatting.
2179
21802011-09-06 Pascal Obry <obry@adacore.com>
2181
2182 * s-osinte-linux.ads, s-oscons-tmplt.c: Use oscons to define sigset_t
2183 types.
2184
516785cc
AC
21852011-09-06 Robert Dewar <dewar@adacore.com>
2186
2187 * g-socket.adb: Minor reformatting
2188
21892011-09-06 Javier Miranda <miranda@adacore.com>
2190
2191 * ali.adb (Scan_ALI): Add missing support to load references of
2192 entities imported from other languages.
2193 * ali.ads (Xref_Record): Adding new fields to store the language and
2194 name of an imported entity.
2195 * lib-xref.adb (Output_Import_Export_Info): Fix typo
2196 in comment.
2197
21982011-09-06 Ed Schonberg <schonberg@adacore.com>
2199
2200 * sem_prag.adb (Analyze_Pragma, case Type_Invariant): A type invariant
2201 is allowed on a full type declaration if it is the completion of
2202 a private declarations.
2203 * sem_ch13.adb (Analyze_Aspect_Specifications): An invariant
2204 aspect is allowed on a full type declaration in the private part
2205 of a package.
2206
96691943
AC
22072011-09-06 Robert Dewar <dewar@adacore.com>
2208
2209 * sem_ch8.ads: Minor reformatting
2210
22112011-09-06 Thomas Quinot <quinot@adacore.com>
2212
2213 * s-oscons-tmplt.c, g-socket.adb (GNAT.Sockets.Clear,Set,Is_Set):
2214 Guard against socket values that are not in [0;FD_SETSIZE[
2215
54bf19e4
AC
22162011-09-06 Robert Dewar <dewar@adacore.com>
2217
2218 * s-osinte-linux.ads, a-iteint.ads, exp_ch6.adb, s-solita.adb: Minor
2219 reformatting.
2220
22212011-09-06 Arnaud Charlet <charlet@adacore.com>
2222
2223 * s-linux-alpha.ads: Minor reformatting
2224 * s-oscons-tmplt.c: Fix generated comments in s-oscons template.
2225 Use sizeof instead of corresponding C defines in s-oscons template.
2226
5d42cba1
VG
22272011-09-06 Vadim Godunko <godunko@adacore.com>
2228
2229 * a-convec.ads, a-iteint.ads: Minor reformatting.
2230
77aa62e7
AC
22312011-09-06 Vincent Celier <celier@adacore.com>
2232
2233 * projects.texi: Add menus and @node lines.
2234
22352011-09-06 Ed Schonberg <schonberg@adacore.com>
2236
2237 * exp_ch6.adb (Expand_Inlined_Call): Handle properly the case
2238 where the return type is an unconstrained array and the context
2239 is an assignment. Optimize the case when the target of the
2240 assignment is a selected component.
2241
22422011-09-06 Arnaud Charlet <charlet@adacore.com>
2243
2244 * s-solita.adb: Update comments.
2245
22462011-09-06 Pascal Obry <obry@adacore.com>
2247
2248 * s-linux.ads, s-linux-alpha.ads, s-linux-hppa.ads, s-linux-mipsel.ads,
2249 s-linux-sparc.ads: Remove hard coded and now wrong definitions.
2250 * s-oscons-tmplt.c: Add support for generating pthread related
2251 types size on GNU/Linux as done for Darwin.
2252 * s-osinte-linux.ads: Use s-oscons to define the pthread types.
2253
886b5a18
AC
22542011-09-06 Robert Dewar <dewar@adacore.com>
2255
2256 * exp_ch6.adb: Fix minor typo.
2257
22582011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
2259
2260 * exp_ch7.adb: Remove with and use clauses for Get_Targ.
2261 (Alignment_Of): Moved to the body of Nearest_Multiple_Rounded_Up.
2262 (Double_Size_Of): Alphabetized. Update the comment on usage.
2263 (Make_Finalize_Address_Stmts): Update comments and reformat code.
2264 (Nearest_Multiple_Rounded_Up): New routine.
2265 (Size_Of): Update comment on usage. The generated expression now
2266 accounts for alignment gaps by rounding the size of the type to the
2267 nearest multiple rounded up of the type's alignment.
2268
57a3fca9
AC
22692011-09-06 Robert Dewar <dewar@adacore.com>
2270
2271 * exp_ch7.adb, g-comlin.adb: Minor reformatting.
2272
22732011-09-06 Steve Baird <baird@adacore.com>
2274
2275 * exp_ch4.adb (Expand_Allocator_Expression): Look through
2276 derived subprograms in checking for presence of an
2277 Extra_Accessibility_Of_Result formal parameter.
2278 * exp_ch6.adb (Expand_Call): Look through derived subprograms in
2279 checking for presence of an Extra_Accessibility_Of_Result formal
2280 parameter.
2281 (Expand_Call.Add_Actual_Parameter): Fix a bug in the
2282 case where the Parameter_Associatiations attribute is already set,
2283 but set to an empty list.
2284 (Needs_Result_Accessibility_Level):
2285 Unconditionally return False. This is a temporary
2286 change, disabling the Extra_Accessibility_Of_Result
2287 mechanism.
2288 (Expand_Simple_Function_Return): Check for
2289 Extra_Accessibility_Of_Result parameter's presence instead of
2290 testing Ada_Version when generating a runtime accessibility
2291 check which makes use of the parameter.
2292
eaed0c37
AC
22932011-09-06 Ed Schonberg <schonberg@adacore.com>
2294
2295 * exp_ch4.adb (Expand_N_Case_Expression): Actions created for the
2296 expression in a given case alternative must be attached to the
2297 statement list of the ccrresponding case statement alternative
2298 They cannot be propagated ahead of the case statement, because
2299 the validity of the expression that generated the action may
2300 hold only for that alternative.
2301
23022011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
2303
2304 * exp_ch7.adb: Remove with and use clauses for Get_Targ.
2305 (Alignment_Of): Remove the code for strict alignment targets.
2306 (Double_Alignment_Of): Removed.
2307 (Double_Size_Of): New routine.
2308 (Make_Finalize_Address_Stmts): Change the
2309 calculation of the dope's size. Update relevant comments.
2310 (Size_Of): New routine.
2311
b8a93198
AC
23122011-09-06 Steve Baird <baird@adacore.com>
2313
2314 * einfo.ads (Extra_Accessibility): Update associated comment to use
2315 the term "present" correctly ("present" just means that it is not
2316 an error to query the value of the attribute - it does not imply
2317 that the value must be non-null).
2318 (Extra_Constrained): Ditto.
2319 (Is_Visible_Formal): Ditto.
2320 (Extra_Accessibility_Of_Result) Ditto; also add Inline pragma.
2321 (Set_Extra_Accessibility_Of_Result): Add Inline pragma.
2322 * exp_ch4.adb (Expand_Allocator_Expression): Improve a comment.
2323 * exp_ch6.adb (Expand_Call): The callee may require an
2324 Extra_Accessibility_Of_Result actual parameter even if Ada_Version
2325 < Ada_2012. This can occur if the callee is exported from a Gnat
2326 runtimes unit. Also improve a comment.
2327
23282011-09-06 Hristian Kirtchev <kirtchev@adacore.com>
2329
2330 * exp_ch7.adb: Add with and use clauses for Get_Targ.
2331 (Alignment_Of): Rename formal parameter Some_Typ
2332 to Typ, update related comment. Use the allocator alignment on
2333 strict alignment targets such as SPARC.
2334 (Double_Alignment_Of): Rename formal parameter Some_Typ to Typ, update
2335 related comment.
2336
23372011-09-06 Gary Dismukes <dismukes@adacore.com>
2338
2339 * sem_ch9.adb (Check_Interfaces): Test
2340 Is_Limited_Type rather than Is_Limited_Record when checking that
2341 the partial view of a synchronized full view must be limited.
2342
23432011-09-06 Emmanuel Briot <briot@adacore.com>
2344
2345 * g-comlin.adb (Free): Fix memory leak.
2346
ebf494ec
RD
23472011-09-06 Robert Dewar <dewar@adacore.com>
2348
2349 * sem_util.adb, exp_ch6.adb: Minor reformatting and code reorganization.
2350
63585f75
SB
23512011-09-06 Steve Baird <baird@adacore.com>
2352
2353 * einfo.ads (Extra_Accessibility_Of_Result): New function; in the
2354 (Ada2012) cases described in AI05-0234 where the accessibility
2355 level of a function result is "determined by the point of
2356 call", an implicit parameter representing that accessibility
2357 level is passed in. Extra_Accessibilty_Of_Result yields this
2358 additional formal parameter. Extra_Accessibility_Of_Result
2359 is analogous to the existing Extra_Accessibility
2360 function used in the implementation of access parameters.
2361 (Set_Extra_Accessibility_Of_Result): New procedure; sets
2362 Extra_Accessibility_Of_Result attribute.
2363 * einfo.adb (Extra_Accessibility_Of_Result): New function.
2364 (Set_Extra_Accessibility_Of_Result): New procedure.
2365 (Write_Field19_Name): Display Extra_Accessibilty_Of_Result attribute.
2366 * sem_util.adb (Dynamic_Accessibility_Level): Set Etype of
2367 an accessibility level literal to Natural; introduce a nested
2368 function, Make_Level_Literal, to do this.
2369 * exp_ch6.ads (Needs_Result_Accessibility_Level): New function;
2370 determines whether a given function (or access-to-function
2371 type) needs to have an implicitly-declared accessibility-level
2372 parameter added to its profile.
2373 (Add_Extra_Actual_To_Call): Export an existing procedure which was
2374 previously declared in the body of Exp_Ch6.
2375 * exp_ch6.adb (Add_Extra_Actual_To_Call): Export declaration by moving
2376 it to exp_ch6.ads.
2377 (Has_Unconstrained_Access_Discriminants): New Function; a
2378 predicate on subtype entities which returns True if the given
2379 subtype is unconstrained and has one or more access discriminants.
2380 (Expand_Call): When expanding a call to a function which takes an
2381 Extra_Accessibility_Of_Result parameter, pass in the appropriate
2382 actual parameter value. In the case of a function call which is
2383 used to initialize an allocator, this may not be possible because
2384 the Etype of the allocator may not have been set yet. In this
2385 case, we defer passing in the parameter and handle it later in
2386 Expand_Allocator_Expression.
2387 (Expand_Simple_Function_Return): When returning from a function which
2388 returns an unconstrained subtype having at least one access
2389 discriminant, generate the accessibility check needed to ensure that
2390 the function result will not outlive any objects designated by its
2391 discriminants.
2392 (Needs_Result_Accessibility_Level): New function; see exp_ch6.ads
2393 description.
2394 * exp_ch4.adb (Expand_Allocator_Expression): When a function call
2395 is used to initialize an allocator, we may need to pass in "the
2396 accessibility level determined by the point of call" (AI05-0234)
2397 to the function. Expand_Call, where such actual parameters are
2398 usually generated, is too early in this case because the Etype of
2399 the allocator (which is used in determining the level to be passed
2400 in) may not have been set yet when Expand_Call executes. Instead,
2401 we generate code to pass in the appropriate actual parameter
2402 in Expand_Allocator_Expression.
2403 * sem_ch6.adb (Create_Extra_Formals): Create
2404 the new Extra_Accessibility_Of_Result formal if
2405 Needs_Result_Accessibility_Level returns True. This includes the
2406 introduction of a nested procedure, Check_Against_Result_Level.
2407
1a982c6e
AC
24082011-09-06 Arnaud Charlet <charlet@adacore.com>
2409
2410 * gcc-interface/Makefile.in (X86_TARGET_PAIRS): Remove duplicate
2411 declaration.
2412
e42bcfa3
AC
24132011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
2414
2415 * s-finmas.adb (Set_Finalize_Address): Explain the reason
2416 for the synchronization. Move the test for null from
2417 s-stposu.Allocate_Any_Controlled to this routine since the check
2418 needs to be protected too.
2419 (Set_Heterogeneous_Finalize_Address): Explain the reason for the
2420 synchronization code.
2421 * s-finmas.ads (Set_Heterogeneous_Finalize_Address): Add comment
2422 explaining the context in which this routine is used.
2423 * s-stposu.adb (Allocate_Any_Controlled): Move the test for null
2424 to s-finmas.Set_Finalize_Address.
2425
24262011-09-05 Ed Schonberg <schonberg@adacore.com>
2427
2428 * einfo.ads: Document that itypes have no parent field.
2429
24302011-09-05 Robert Dewar <dewar@adacore.com>
2431
2432 * rtsfind.adb (Check_CRT): Check for overloaded entity
2433 * rtsfind.ads: Document that entities to be found by rtsfind
2434 cannot be overloaded
2435 * s-taenca.adb, s-tasren.adb, s-tpobop.adb, s-tpoben.ads, s-tpoben.adb
2436 (Lock_Entries_With_Status): New name for Lock_Entries with two
2437 arguments (changed to meet rtsfind no overloading rule).
2438
544e7c17
AC
24392011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
2440
2441 * s-finmas.adb (Set_Finalize_Address (Address,
2442 Finalize_Address_Ptr)): Renamed to Set_Heterogeneous_Finalize_Address.
2443 (Set_Finalize_Address (in out Finalization_Master,
2444 Finalize_Address_Ptr): Add synchronization code.
2445 * s-finmas.ads (Set_Finalize_Address (Address,
2446 Finalize_Address_Ptr)): Renamed to Set_Heterogeneous_Finalize_Address.
2447 * s-stposu.adb (Allocate_Any_Controlled): Update the call to
2448 Set_Finalize_Address for the heterogeneous case.
2449
24502011-09-05 Ed Schonberg <schonberg@adacore.com>
2451
2452 * sem_ch3.adb: Undo previous change, not suitable after all.
2453
24542011-09-05 Robert Dewar <dewar@adacore.com>
2455
2456 * einfo.ads: Minor comment clarification.
2457
0613fb33
AC
24582011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
2459
2460 * exp_ch6.adb (Move_Activation_Chain): Rewritten. The routine
2461 no longer needs to search through the entities of the return
2462 statement scope to find the _chain.
2463 * sem_ch5.adb: Add with and use clauses for Exp_Ch6 and Sem_Ch6.
2464 (Analyze_Block_Statement): Add local variable
2465 Is_BIP_Return_Statement. Add machinery to install all entities
2466 produced by the expansion of the return object declaration.
2467 (Install_Return_Entities): New routine.
2468 * sem_ch6.ads, sem_ch6.adb (Install_Entity): Moved from body to spec.
2469
24702011-09-05 Ed Schonberg <schonberg@adacore.com>
2471
2472 * sem_ch10.adb (Analyze_Context): Apply simple fixup if context
2473 of subunit is incomplete.
2474 (Analyze_Proper_Body): If parent spec is not available, do not
2475 attempt analysis.
2476
5dcab3ca
AC
24772011-09-05 Ed Schonberg <schonberg@adacore.com>
2478
2479 * sem_disp.adb (Find_Controlling_Arg): Add checks for
2480 interface type conversions, that are expanded into dereferences.
2481
24822011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
2483
2484 * sem_ch6.adb (Analyze_Subprogram_Body_Helper):
2485 Examine the parameter and return profile of a subprogram and swap
2486 any incomplete types coming from a limited context with their
2487 corresponding non-limited views.
2488 (Exchange_Limited_Views): New routine.
2489
24902011-09-05 Ed Schonberg <schonberg@adacore.com>
2491
2492 * sem_ch3.adb (Prepare_Private_Subtype_Completion): Set parent
2493 of internal entity to the subtype declaration, so that when
2494 entities are subsequently exchanged in a package body, the tree
2495 remains properly formatted for ASIS.
2496
8da1a312
AC
24972011-09-05 Johannes Kanig <kanig@adacore.com>
2498
2499 * g-comlin.adb (Set_Usage): Additional optional argument to set help
2500 message.
2501 (Display_Help): display the user given help message, if available.
2502
25032011-09-05 Ed Schonberg <schonberg@adacore.com>
2504
2505 * sem_ch3.adb (OK_For_Limited_Init_In_05): The expression
2506 is legal if the original node is an identifier that is a
2507 parameterless function call.
2508
69b73847
PO
25092011-09-05 Pascal Obry <obry@adacore.com>
2510
2511 * prj-nmsc.adb: Minor reformatting.
2512 Add support for standalone aggregate library.
2513 (Check_Stand_Alone_Library): Handle standalone aggregate library.
2514 * projects.texi: Fix documentation for aggregate library projects.
2515
81bf2382
AC
25162011-09-05 Robert Dewar <dewar@adacore.com>
2517
2518 * sem_ch6.adb: Minor reformatting.
2519
25202011-09-05 Matthew Gingell <gingell@adacore.com>
2521
2522 * s-tassta.adb (Task_Wrapper): Ensure that we don't try to write the
2523 stack guard page on PPC Linux. This patch ensures the 64K guard page at
2524 the bottom of the stack is not overwritten.
2525
13a0b1e8
AC
25262011-09-05 Thomas Quinot <quinot@adacore.com>
2527
2528 * exp_intr.adb, s-tasini.adb: Minor reformatting.
2529
25302011-09-05 Ed Schonberg <schonberg@adacore.com>
2531
2532 * sem_ch3.adb (Access_Definition): If an access type declaration
2533 appears in a child unit, the scope of whatever anonymous type
2534 may be generated is the child unit itself.
2535
25362011-09-05 Ed Schonberg <schonberg@adacore.com>
2537
2538 * sem_ch6.adb (Analyze_Expression_Function): Do not set
2539 Comes_From_Source on rewritten body.
2540 (Analyze_Subprogram_Body_Helper): Check that the original node for
2541 the body comes from source, when determining whether expansion
2542 of a protected operation is needed.
2543
20428725
AC
25442011-09-05 Ed Schonberg <schonberg@adacore.com>
2545
2546 * exp_aggr.adb (Replace_Type): If the target of the assignment is
2547 a selected component and the right-hand side is a self-referential
2548 access, the proper prefix of the rewritten attribute is a copy
2549 of the left-hand side, not of its prefix.
2550
25512011-09-05 Robert Dewar <dewar@adacore.com>
2552
2553 * sem_ch5.adb: Minor reformatting.
2554 * sem_ch3.adb: Minor code clean up.
2555
25562011-09-05 Jose Ruiz <ruiz@adacore.com>
2557
2558 * exp_ch9.adb (Make_Initialize_Protection): The fact that
2559 restriction No_Dynamic_Attachment is in effect or not should
2560 not influence the default priority associated to a protected
2561 object. With this change, when the restriction is in effect (as
2562 is the case for the Ravenscar profile) the default priority of
2563 a protected object with an interrupt handler is in the range of
2564 interrupt priorities (Default_Interrupt_Priority) as required
2565 by D.3(10).
2566
25672011-09-05 Arnaud Charlet <charlet@adacore.com>
2568
2569 * a-iteint.ads: Fix header.
2570
25712011-09-05 Vincent Celier <celier@adacore.com>
2572
2573 * prj-conf.adb (Do_Autoconf): Make sure Obj_Dir always ends
2574 with a directory separator to avoid output such as:
2575 "/path/to/objauto.cgpr" has been deleted.
2576
4a1bfefb
AC
25772011-09-05 Robert Dewar <dewar@adacore.com>
2578
2579 * sem_ch3.adb: Minor reformatting.
2580
25812011-09-05 Ed Schonberg <schonberg@adacore.com>
2582
2583 * sem_ch5.adb: Better error message.
2584
25852011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
2586
2587 * exp_aggr.adb: Add with and use clause for Exp_Ch6.
2588 (Expand_Array_Aggregate): Detect a special case of an aggregate
2589 which contains tasks in the context of an unexpanded return
2590 statement of a build-in-place function.
2591 * exp_ch6.adb: Add with and use clause for Exp_Aggr.
2592 (Expand_N_Extended_Return_Statement): Detect a delayed aggregate
2593 which contains tasks and expand it now that the original simple
2594 return statement has been rewritten.
2595 * exp_ch9.adb (Build_Activation_Chain_Entity): Code
2596 reformatting. Do not create a chain for an extended return
2597 statement if one is already available.
2598 (Has_Activation_Chain): New routine.
2599
9ec080cb
AC
26002011-09-05 Marc Sango <sango@adacore.com>
2601
2602 * sem_ch3.adb (Analyze_Object_Declaration): Remove
2603 the wrong test and add the correct test to detect the violation
2604 of illegal use of unconstrained string type in SPARK mode.
2605
26062011-09-05 Ed Schonberg <schonberg@adacore.com>
2607
2608 * sem_ch5.adb (Analyze_Iteration_Specification): Improve error
2609 message on an iterator over an array.
2610
26112011-09-05 Robert Dewar <dewar@adacore.com>
2612
2613 * lib-xref-alfa.adb: Minor reformatting.
2614
aeae67ed
RD
26152011-09-05 Robert Dewar <dewar@adacore.com>
2616
2617 * sem_ch3.adb, sem_res.adb, par.adb, par-ch6.adb, g-comlin.adb,
2618 exp_ch6.adb, lib-xref-alfa.adb: Minor reformatting.
2619
d72e7628
AC
26202011-09-05 Gary Dismukes <dismukes@adacore.com>
2621
2622 * exp_ch7.adb, exp_ch6.adb: Minor reformatting.
2623
26242011-09-05 Johannes Kanig <kanig@adacore.com>
2625
2626 * lib-xref-alfa.adb: Update comments.
2627
26282011-09-05 Thomas Quinot <quinot@adacore.com>
2629
2630 * sem_res.adb: Minor reformatting
2631
0d566e01
ES
26322011-09-05 Ed Schonberg <schonberg@adacore.com>
2633
2634 * exp_ch6.adb (Build_In_Place_Formal): If extra formals are not
2635 present, create them now. Needed in case the return type was
2636 a limited view in the function declaration.
2637 (Make_Build_In_Place_Call_In_Allocator): If return type contains
2638 tasks, build the activation chain for it. Pass a reference to
2639 the Master_Id in call to Add_Task_Actuals_To_Build_In_Place call.
2640 * exp_ch7.adb (Make_Set_Finalize_Address_Call): Clean up interface
2641 with build_in_place calls.
2642 * sem_ch9.adb (Analyze_Task_Type_Declaration): If partial view was
2643 incomplete, inatialize its Corresponding_Record_Type component.
2644 * sem_ch10.adb (Build_Chain): Initialize Private_Dependents field
2645 of limited views.
2646
ec09f261
AC
26472011-09-05 Johannes Kanig <kanig@adacore.com>
2648
2649 * lib-xref-alfa.adb (Is_Alfa_Reference): Filter constants from effect
2650 information.
2651
26522011-09-05 Ed Schonberg <schonberg@adacore.com>
2653
2654 * par-ch6.adb (P_Subprogram): In Ada2012 mode, if the subprogram
2655 appears within a package specification and the token after "IS"
2656 is not a parenthesis, assume that this is an unparenthesized
2657 expression function, even if the token appears in a line by
2658 itself.
2659 * par.adb: Clarify use of Labl field of scope stack in error
2660 recovery.
2661
7109f4f5
AC
26622011-09-05 Bob Duff <duff@adacore.com>
2663
2664 * sem_res.adb (Resolve_Intrinsic_Operator): Use unchecked
2665 conversions instead of normal type conversions in all cases where a
2666 type conversion would be illegal. In particular, use unchecked
2667 conversions when the operand types are private.
2668
26692011-09-05 Johannes Kanig <kanig@adacore.com>
2670
2671 * lib-xref-alfa.adb (Is_Alfa_Reference): Never declare effects on
2672 objects of task type or protected type.
2673
66dc8075
AC
26742011-09-05 Ed Schonberg <schonberg@adacore.com>
2675
2676 * sem_ch6.adb (Analyze_Expression_Function): If the expression
2677 function comes from source, indicate that so does its rewriting,
2678 so it is compatible with any subsequent expansion of the
2679 subprogram body (e.g. when it is a protected operation).
2680 * sem_ch4.adb: minor reformatting
2681
26822011-09-05 Hristian Kirtchev <kirtchev@adacore.com>
2683
2684 * lib.adb (Check_Same_Extended_Unit): Comment rewriting. Use
2685 Get_Source_Unit rather than Get_Code_Unit as instantiation unfolding
2686 may lead to wrong ancestor package in the case of instantiated subunit
2687 bodies. If a subunit is instantiated, follow the chain of instantiations
2688 rather than the stub structure.
2689
bd38b431
AC
26902011-09-02 Robert Dewar <dewar@adacore.com>
2691
2692 * sem_ch4.adb, sem_ch6.adb: Minor reformatting.
2693 * gcc-interface/Make-lang.in: Update dependencies.
2694
26952011-09-02 Marc Sango <sango@adacore.com>
2696
2697 * sem_ch3.adb (Analyze_Object_Declaration): Change
2698 comment and add additional check to differentiate constant of
2699 type string from others unconstrained type.
2700
99d520ad
ES
27012011-09-02 Ed Schonberg <schonberg@adacore.com>
2702
2703 * sinfo.ads, sinfo.adb: New semantic attribute Premature_Use,
2704 present in incomplete type declarations to refine the error
2705 message the full declaration is in the same unit.
2706 * sem_ch4.adb (Analyze_Selected_Component): If the prefix is of
2707 an incomplete type, set the Premature_Use for additional message.
2708 * sem_ch3.adb (Find_Type_Name): If partial view is incomplete
2709 and Premature_Use is set, place additional information at the
2710 point of premature use.
2711
5b5588dd
AC
27122011-09-02 Bob Duff <duff@adacore.com>
2713
2714 * sem_ch6.adb: (Check_Post_State): Suppress warning
2715 "postcondition refers only to pre-state" when the expression has not
2716 yet been analyzed, because it causes false alarms. This can happen when
2717 the postcondition contains a quantified expression, because those are
2718 analyzed later. This is a temporary/partial fix.
2719 (Process_Post_Conditions): Minor: change wording of warning.
2720
27212011-09-02 Marc Sango <sango@adacore.com>
2722
2723 * sem_ch3.adb (Analyze_Object_Declaration): Detect the violation of
2724 illegal use of unconstrained string type in SPARK mode.
2725 * sem_res.adb (Analyze_Operator_Symbol): Set the
2726 right place where the string operand of concatenation should be
2727 violate in SPARK mode.
2728
bd603506
RD
27292011-09-02 Robert Dewar <dewar@adacore.com>
2730
2731 * sem_prag.adb, sem_util.adb, sem_ch6.adb, prj-nmsc.adb,
2732 exp_ch3.adb: Minor reformatting.
2733
24a120ac
AC
27342011-09-02 Vincent Celier <celier@adacore.com>
2735
2736 * prj-conf.adb (Add_Default_GNAT_Naming_Scheme): Declare "gcc"
2737 as the compiler driver so Is_Compilable returns True for sources.
2738 * prj-nmsc.adb (Override_Kind): When Kind is Sep, set the source
2739 for the body.
2740
27412011-09-02 Ed Schonberg <schonberg@adacore.com>
2742
2743 * sem_prag.adb (Analyze_PPC_In_Decl_Part): for a class-wide
2744 condition, a reference to a controlling formal must be interpreted
2745 as having the class-wide type (or an access to such) so that the
2746 inherited condition can be properly applied to any overriding
2747 operation (see ARM12 6.6.1 (7)).
2748
27492011-09-02 Tristan Gingold <gingold@adacore.com>
2750
2751 * init.c (__gnat_is_vms_v7): Fix case and add prototype
2752 for LIB$GETSYI.
2753
27542011-09-02 Javier Miranda <miranda@adacore.com>
2755
2756 * exp_ch3.adb (Expand_N_Object_Declaration): Do not copy the
2757 initializing expression of a class-wide interface object declaration
2758 if its type is limited.
2759
27602011-09-02 Johannes Kanig <kanig@adacore.com>
2761
2762 * sem_util.adb (Unique_Name): To obtain a unique name for enumeration
2763 literals, take into account the type name; the type is *not*
2764 the scope for an enumeration literal.
2765
27662011-09-02 Ed Schonberg <schonberg@adacore.com>
2767
2768 * sem_ch6.adb (Check_Overriding_Indicator): add special check
2769 to reject an overriding indicator on a user-defined Adjust
2770 subprogram for a limited controlled type.
2771
27722011-09-02 Ed Schonberg <schonberg@adacore.com>
2773
2774 * sem_res.adb (Resolve_Actuals): add missing call to Resolve
2775 for an actual that is a function call returning an unconstrained
2776 limited controlled type.
2777
27782011-09-02 Tristan Gingold <gingold@adacore.com>
2779
2780 * g-socthi-vms.adb (c_sendmsg, c_recvmsg): Use unpacked msg if on vms 7
2781
27822011-09-02 Johannes Kanig <kanig@adacore.com>
2783
2784 * alfa.ads (Name_Of_Heap_Variable): Change value of the HEAP variable
2785 from "HEAP" to __HEAP Change comment that refers to that variable
2786 * put_alfa.adb: Change comment that refers to that variable
2787
c5f5123f
AC
27882011-09-02 Robert Dewar <dewar@adacore.com>
2789
2790 * exp_ch4.adb, exp_ch6.adb, prj-nmsc.adb: Minor reformatting.
2791
27922011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
2793
2794 * exp_util.adb (Extract_Renamed_Object): Renamed to
2795 Find_Renamed_Object. This routine has been reimplemented and now uses
2796 tree traversal to locate a renamed object.
2797 (Is_Aliased): Replace call to Extract_Renamed_Object with
2798 Find_Renamed_Object.
2799
28002011-09-02 Tristan Gingold <gingold@adacore.com>
2801
2802 * init.c: (__gnat_is_vms_v7): New function.
2803
28042011-09-02 Olivier Hainque <hainque@adacore.com>
2805
2806 * tracebak.c (STOP_FRAME, ppc elf/vxworks case): Stop on frames
2807 that have a misaligned backchain, necessarily bogus.
2808
2bfa5484
HK
28092011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
2810
2811 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Do not create
2812 TSS routine Finalize_Address when compiling in Alfa mode.
2813 (Expand_Freeze_Record_Type): Do not create TSS routine
2814 Finalize_Address when compiling in Alfa mode.
2815 * exp_ch4.adb (Expand_Allocator_Expression): Do not produce a
2816 call to Set_Finalize_Address in Alfa mode because Finalize_Address is
2817 not built.
2818 (Expand_N_Allocator): Do not produce a call to
2819 Set_Finalize_Address in Alfa mode because Finalize_Address is not built.
2820 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Do not
2821 produce a call to primitive Set_Finalize_Address in Alfa mode because
2822 Finalize_Address is not built.
2823 * exp_ch7.adb (Build_Finalization_Master): Do not create
2824 finalization masters in Afa mode since they are not needed.
2825 (Build_Finalizer): Do not create scope and library-level
2826 finalizers in Alfa mode since they are not needed.
2827 * exp_util.adb (Build_Allocate_Deallocate_Proc): Do not expand
2828 "new" and "free" when applied to controlled objects in Alfa mode since
2829 this is not needed.
2830
7a0ddd20
AC
28312011-09-02 Vincent Celier <celier@adacore.com>
2832
2833 * prj-nmsc.db: (Check_Stand_Alone_Library): For SALs, allow
2834 only library names with the syntax of Ada identifiers, to avoid errors
2835 when compiling the binder generated files.
2836 * projects.texi: Document restriction on SAL library names
2837
28382011-09-02 Thomas Quinot <quinot@adacore.com>
2839
2840 * a-chtgbo.adb: Minor comment fix.
2841
439b6dfa
AC
28422011-09-02 Robert Dewar <dewar@adacore.com>
2843
2844 * lib-xref.adb: Minor reformatting
2845
28462011-09-02 Vincent Celier <celier@adacore.com>
2847
2848 * bindusg.adb, clean.adb, gnatchop.adb, gnatfind.adb, gnatlink.adb,
2849 gnatls.adb, gnatname.adb, gnatxref.adb, gprep.adb, makeusg.adb: Add
2850 --version and --help in usage.
2851 * switch.ads, switch.adb (Display_Usage_Version_And_Help): New procedure
2852
f2404867
AC
28532011-09-02 Bob Duff <duff@adacore.com>
2854
2855 * lib-xref.adb: (Hash): Avoid use of 'Mod attribute, because old
2856 compilers don't understand it.
2857
28582011-09-02 Gary Dismukes <dismukes@adacore.com>
2859
2860 * exp_attr.adb (Expand_N_Attribute_Reference): Pass the
2861 underlying subtype rather than its base type on the call to
2862 Build_Record_Or_Elementary_Input_Function, so that any
2863 constraints on a discriminated subtype will be available for
2864 doing the check required by AI05-0192.
2865 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
2866 If the prefix subtype of the 'Input attribute is a constrained
2867 discriminated subtype, then check each constrained discriminant value
2868 against the corresponding value read from the stream.
2869
029b67ba
YM
28702011-09-02 Yannick Moy <moy@adacore.com>
2871
2872 * usage.adb, warnsw.adb, sem_ch6.adb, opt.ads: Disable by default
2873 warnings on suspicious contracts, and enable them with -gnatwa.
2874
dc36a7e3
RD
28752011-09-02 Robert Dewar <dewar@adacore.com>
2876
2877 * exp_util.adb, exp_ch9.adb, sem_attr.adb, sem_ch6.adb: Minor
2878 reformatting.
2879
d5aa443c
AC
28802011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
2881
2882 * exp_ch9.adb (Install_Private_Data_Declarations): Add guards
2883 which ensure that restriction No_Dynamic_Attachment has not been
2884 violated.
2885 (Make_Initialize_Protection): Protected types with attach or
2886 interrupt handlers must not violate restriction No_Dynamic_Attachment.
2887 * exp_util.adb (Corresponding_Runtime_Package): Add a guard
2888 which ensures that restriction No_Dynamic_Attachment has not been
2889 violated.
2890 * sem_attr.adb: (Eval_Attribute): Transform
2891 VAX_Float_Type'First and 'Last into references to
2892 the temporaries which store the corresponding bounds. The
2893 transformation is needed since the back end cannot evaluate
2894 'First and 'Last on VAX.
2895 (Is_VAX_Float): New routine.
2896
28972011-09-02 Ed Schonberg <schonberg@adacore.com>
2898
2899 * sem_ch12.adb (Analyze_Subprogram_Instantiation): If the
2900 generic unit is not intrinsic and has an explicit convention,
2901 the instance inherits it.
2902
67c86178
AC
29032011-09-02 Robert Dewar <dewar@adacore.com>
2904
2905 * prj-dect.adb, prj-env.adb, prj-nmsc.adb, prj-proc.adb, prj-tree.adb,
2906 prj.adb, prj.ads, sem_ch5.adb: Minor reformatting.
2907
29082011-09-02 Thomas Quinot <quinot@adacore.com>
2909
2910 * sem_attr.adb (Analyze_Attribute, case Unrestriced_Access):
2911 Guard against a prefix that is an N_Has_Entity but has no
2912 associated entity.
2913
29142011-09-02 Yannick Moy <moy@adacore.com>
2915
2916 * lib-xref-alfa.adb (Is_Alfa_Reference): Ignore IN parameters in Alfa
2917 references.
2918
29192011-09-02 Yannick Moy <moy@adacore.com>
2920
2921 * opt.ads (Warn_On_Suspicious_Contract): New warning flag.
2922 * sem_ch3.adb (Analyze_Declarations): Call checker for suspicious
2923 contracts.
2924 * sem_ch6.adb, sem_ch6.ads (Check_Subprogram_Contract): New
2925 procedure looking for suspicious postconditions.
2926 * usage.adb (Usage): New options -gnatw.t and -gnatw.T.
2927 * warnsw.adb (Set_Dot_Warning_Switch): Take into account new
2928 options -gnatw.t and -gnatw.T.
2929
735ca1b9
PO
29302011-09-02 Pascal Obry <obry@adacore.com>
2931
2932 * prj.adb: Minor code refactoring. Move check for null project in
2933 Project_Changed.
2934 * projects.texi: Fix minor typos.
2935
86828d40
AC
29362011-09-02 Ed Schonberg <schonberg@adacore.com>
2937
2938 * sem_ch5.adb (Analyze_Iterator_Specification): If the domain
2939 of iteration is an expression, its value must be captured in a
2940 renaming declaration, so that modification of the elements is
2941 propagated to the original container.
2942
29432011-09-02 Pascal Obry <obry@adacore.com>
2944
2945 * prj-proc.adb, prj.adb, makeutl.adb, makeutl.ads, prj-dect.adb,
2946 prj-nmsc.adb, prj-util.adb, prj-conf.adb, prj-env.adb,
2947 prj-tree.adb: Minor reformatting and style fixes.
2948
83de674b
AC
29492011-09-02 Robert Dewar <dewar@adacore.com>
2950
2951 * s-rident.ads: Add new restriction No_Implicit_Aliasing
2952 * sem_attr.adb: (Analyze_Access_Attribute): Deal with
2953 No_Implicit_Aliasing
2954 (Analyze_Attribute, case Address): ditto
2955 (Analyze_Attribute, case Unrestricted_Access): ditto
2956 * sem_util.ads, sem_util.adb: (Is_Aliased_View): Handle
2957 No_Implicit_Aliasing restriction.
2958 * gnat_rm.texi: Add documentation for No_Implicit_Aliasing
2959
29602011-09-02 Ed Schonberg <schonberg@adacore.com>
2961
2962 * exp_util.adb: (Possible_Bit_Aligned_Object): If the object
2963 is an unchecked conversion, apply test to its expression.
2964
29652011-09-02 Javier Miranda <miranda@adacore.com>
2966
2967 * sem_ch3.adb (Check_Abstract_Overriding): When
2968 traversing the chain of aliased subprograms avoid reporting a
2969 redundant error on the current entity.
2970
29712011-09-02 Sergey Rybin <rybin@adacore.com>
2972
2973 * gnat_ugn.texi: Minor clean up.
2974
29752011-09-02 Bob Duff <duff@adacore.com>
2976
2977 * s-htable.adb (Set_If_Not_Present): Use renaming
2978 instead of ":=", because the type Key is limited in the generic (even
2979 if not in the instances).
2980
2c17ca0a
AC
29812011-09-02 Robert Dewar <dewar@adacore.com>
2982
2983 * exp_util.adb, sem_ch10.adb, sem_attr.adb, s-htable.adb,
2984 g-comlin.adb, g-comlin.ads, lib-xref-alfa.adb, lib-xref.adb: Minor
2985 reformatting.
2986
29872011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
2988
2989 * sem_ch3.adb: (Set_Anonymous_Type): Associate the itype of an
2990 inherited component with the enclosing derived type. Code reformatting.
2991
29922011-09-02 Gary Dismukes <dismukes@adacore.com>
2993
2994 * checks.adb: (Determine_Range): Add test of OK1 to prevent the early
2995 return done when overflow checks are enabled, since comparisons against
2996 Lor and Hir should not be done when OK1 is False.
2997
29982011-09-02 Gary Dismukes <dismukes@adacore.com>
2999
3000 * exp_ch6.adb (Add_Finalization_Master_Actual_To_Build_In_Place_Call):
3001 Add new formal Master_Exp. When present, add that expression to the
3002 call as an extra actual.
3003 (Make_Build_In_Place_Call_In_Object_Declaration): Add variable
3004 Fmaster_Actual and in the case of a BIP call initializing a return
3005 object of an enclosing BIP function set it to a
3006 new reference to the implicit finalization master
3007 formal of the enclosing function. Fmaster_Actual is
3008 then passed to the new formal Master_Exp on the call to
3009 Add_Finalization_Master_Actual_To_Build_ In_Place_Call. Move
3010 initializations of Enclosing_Func to its declaration.
3011
30122011-09-02 Thomas Quinot <quinot@adacore.com>
3013
3014 * csets.ads: Minor reformatting
3015
30162011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
3017
3018 * exp_aggr.adb: (Get_Constraint_Association): Add code to retrieve
3019 the full view of a private type coming from an instantiation.
3020 * exp_ch4.adb: (Current_Anonymous_Master): Reimplement the search
3021 loop to iterate over the declarations rather than use the
3022 First_Entity / Next_Entity scheme.
3023
ed32b82e
ES
30242011-09-02 Ed Schonberg <schonberg@adacore.com>
3025
3026 * sem_attr.adb: (Analyze_Attribute, case 'Range): when expanding
3027 X'range (N) into X'First (N) .. X'Last (N), do not share the
3028 dimension indicator N, if present. Even though it is a static
3029 constant, its source location may be modified when printing
3030 expanded code under -gnatDL, and node sharing will lead to chaos
3031 in Sprint on large files, by generating a sloc value that does
3032 not correspond to any source file.
3033
f7bb41af
AC
30342011-09-02 Bob Duff <duff@adacore.com>
3035
3036 * einfo.adb: (Has_Xref_Entry): Do not call
3037 Implementation_Base_Type. Lib.Xref has been
3038 rewritten to avoid the need for it, and it was costly.
3039 * s-htable.ads,s-htable.adb: (Present,Set_If_Not_Present): New
3040 functions in support of efficient xref.
3041 * lib-xref-alfa.adb: Misc changes related to Key component of
3042 type Xref_Entry.
3043 * lib-xref.adb: (Add_Entry,etc): Speed improvement.
3044 (New_Entry): Call Implementation_Base_Type, because Has_Xref_Entry
3045 no longer does. This is the one place where it is needed.
3046
30472011-09-02 Johannes Kanig <kanig@adacore.com>
3048
3049 * g-comlin.adb (Getopt): New optional argument Concatenate to have
3050 similar interface as the other Getopt function.
3051
30522011-09-02 Hristian Kirtchev <kirtchev@adacore.com>
3053
3054 * exp_ch4.adb: (Expand_Allocator_Expression): Do not generate
3055 a call to Set_Finalize_Address if there is no allocator available.
3056 * exp_util.adb: (Build_Allocate_Deallocate_Proc): Account for
3057 a case of allocator expansion where the allocator is not expanded but
3058 needs a custom allocate routine. Code reformatting.
3059 (Is_Finalizable_Transient): Remove local variables Has_Rens and
3060 Ren_Obj. Code reformatting.
3061 (Is_Renamed): Renamed to Is_Aliased. Add code to detect aliasing
3062 through the use of 'reference.
3063 * sem_ch4.adb: (Analyze_Allocator): Detect allocators generated
3064 as part of build-in-place expansion. They are intentionally marked as
3065 coming from source, but their parents are not.
3066
bd0bc43e
AC
30672011-09-02 Ed Schonberg <schonberg@adacore.com>
3068
3069 * sem_ch10.adb (Analyze_With_Clause): If the library unit
3070 is the generated subprogram declaration for a child unit body
3071 that acts as spec, use the original body in the with_clause,
3072 to prevent binding errors.
3073
30742011-09-02 Vincent Celier <celier@adacore.com>
3075
3076 * gnat_ugn.texi: Adapt documentation of -gnateInnn to new VMS
3077 qualifier /MULTI_UNIT_INDEX=
3078
30792011-09-02 Johannes Kanig <kanig@adacore.com>
3080
3081 * g-comlin.adb (Getopt): Return when switch is dealt with automatically,
3082 instead of calling the callback function
3083
9fdb5d21
RD
30842011-09-02 Robert Dewar <dewar@adacore.com>
3085
3086 * prj-proc.adb, prj.ads, sem_util.adb, s-taprop-linux.adb,
3087 prj-nmsc.adb, prj-util.ads, prj-env.adb: Minor reformatting.
3088
c6d5d1ac
AC
30892011-09-02 Vincent Celier <celier@adacore.com>
3090
3091 * prj-nmsc.adb: (Find_Sources): When the list of sources is
3092 explicitly declared in an extending project, do not warn if a source
3093 for an inherited naming exception is not found.
3094
30952011-09-02 Gary Dismukes <dismukes@adacore.com>
3096
3097 * exp_ch6.adb: (Is_Build_In_Place_Function_Call): Return False if
3098 expansion is inactive.
3099
31002011-09-02 Ed Schonberg <schonberg@adacore.com>
3101
3102 * sem_util.adb (Note_Possible_Modification): If the entity
3103 being modified is the renaming generated for an Ada2012 iterator
3104 element, the enclosing container or array is modified as well.
3105
2ba1a7c7
AC
31062011-09-02 Jose Ruiz <ruiz@adacore.com>
3107
3108 * s-taprop-linux.adb (Initialize_Lock, Initialize_TCB,
3109 Initialize): Define and initialize the
3110 mutex attributes and condition variable attributes locally.
3111
31122011-09-02 Vincent Celier <celier@adacore.com>
3113
3114 * prj-nmsc.adb (Check_File): Mark as Locally_Removed a naming
3115 exception replaced in an extending project.
3116 (Check_Object): No error when the other source is locally removed.
3117
31182011-09-02 Yannick Moy <moy@adacore.com>
3119
3120 * exp_ch6.adb (Is_Build_In_Place_Function_Call): in Alfa mode, allow
3121 unresolved calls.
3122
d51813db
AC
31232011-08-31 Arnaud Charlet <charlet@adacore.com>
3124
3125 * gcc-interface/Makefile.in: Clean up handling of x86 and x86-64
3126 run-time files.
3127 * gcc-interface/Make-lang.in: Update dependencies.
3128
9f55bc62
AC
31292011-09-01 Robert Dewar <dewar@adacore.com>
3130
3131 * sem_ch3.adb, s-taprop-linux.adb, gnatls.adb: Minor reformatting.
3132
31332011-09-01 Jose Ruiz <ruiz@adacore.com>
3134
3135 * adaint.h (__gnat_cpu_free): Fix the name of this profile.
3136 * adaint.c (__gnat_cpu_alloc, __gnat_cpu_alloc_size, __gnat_cpu_free,
3137 __gnat_cpu_zero, __gnat_cpu_set): Create version of these subprograms
3138 specific for systems where their glibc version does not define the
3139 routines to handle dynamically allocated CPU sets.
3140
31412011-09-01 Vincent Celier <celier@adacore.com>
3142
3143 * prj-proc.adb, prj.ads, prj-nmsc.adb, prj-util.adb, prj-util.ads,
3144 prj-env.adb: Implement inheritance of naming exceptions in extending
3145 projects.
3146
d7386a7a
AC
31472011-09-01 Romain Berrendonner <berrendo@adacore.com>
3148
3149 * gnatls.adb: Display simple message instead of content of
3150 gnatlic.adl.
3151
31522011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
3153
3154 * sem_ch3.adb: (Build_Derived_Record_Type) Remove the kludgy update of
3155 access discriminant and anonymous access component scopes.
3156 (Inherit_Component): Reuse the itype of an access discriminant
3157 or anonymous access component by copying it in order to set the proper
3158 scope. This is done only when the parent and the derived type
3159 are in different scopes.
3160 (Set_Anonymous_Etype): New routine.
3161
31622011-09-01 Robert Dewar <dewar@adacore.com>
3163
3164 * a-convec.adb: Minor reformatting throughout.
3165
9d1e0e72
JR
31662011-09-01 Jose Ruiz <ruiz@adacore.com>
3167
3168 * adaint.c, adaint.h (__gnat_cpu_alloc, __gnat_cpu_alloc_size,
3169 __gnat_cpu_set_free): Create these wrappers around the CPU_ALLOC,
3170 CPU_ALLOC_SIZE and CPU_FREE linux macros.
3171 (__gnat_cpu_zero, __gnat_cpu_set): Use the CPU_ZERO_S and
3172 CPU_SET_S respectively because we are now using dynamically allocated
3173 CPU sets which are more portable across different glibc versions.
3174 * s-osinte-linux.ads (cpu_set_t_ptr, CPU_ALLOC, CPU_ALLOC_SIZE,
3175 CPU_FREE): Add this type and subprograms to be able to create cpu_set_t
3176 masks dynamically according to the number of processors in the target
3177 platform.
3178 (CPU_ZERO, CPU_SET): They are now mapped to the CPU_ZERO_S and CPU_SET_S
3179 respectively, so we need to pass the size of the masks as
3180 parameters.
3181 * s-taprop-linux.adb (Create_Task, Set_Task_Affinity): Use dynamically
3182 created cpu_set_t masks
3183 with the number of processors available in the target platform,
3184 instead of static bit arrays. It enhances portability because
3185 it uses the information from the target platform.
3186 * sem_ch8.adb: (Attribute_Renaming): When checking whether we
3187 are using a restricted run-time library, use the flag
3188 Configurable_Run_Time_Mode instead of Restricted_Profile.
3189
a95be2d4
AC
31902011-09-01 Vincent Celier <celier@adacore.com>
3191
3192 * ug_words: Add /MULTI_UNIT_INDEX= -> -gnateI
3193 * vms_data.ads: Add new VMS qualifier equivalent for -gnateInnn
3194
31952011-09-01 Nicolas Roche <roche@adacore.com>
3196
3197 * adaint.c (__gnat_tmp_name): Don't use tmpnam function from the system
3198 on VxWorks in kernel mode.
3199
6b81741c
AC
32002011-09-01 Jose Ruiz <ruiz@adacore.com>
3201
3202 * s-taprop-linux.adb (Create_Task, Set_Task_Affinity): Use the linux
3203 macros for handling CPU sets (CPU_ZERO, CPU_SET) instead of modifying
3204 directly the bit array.
3205 * s-osinte-linux.ads (CPU_ZERO, CPU_SET): Import these wrappers around
3206 the linux macros with the same name.
3207 * adaint.h, adaint.c (__gnat_cpu_zero, __gnat_cpu_set): Create these
3208 wrappers around the CPU_ZERO and CPU_SET linux macros.
3209
32102011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
3211
3212 * exp_ch7.adb (Find_Insertion_List): Removed.
3213 (Process_Transient_Objects): Insert the declarations of the hook
3214 access type and the hook object before the associated transient object.
3215
32162011-09-01 Jose Ruiz <ruiz@adacore.com>
3217
3218 * sem_ch8.adb (Attribute_Renaming): Add missing check to avoid loading
3219 package System.Aux_Dec when using restricted run-time libraries which
3220 do not have this package.
3221
32222011-09-01 Tristan Gingold <gingold@adacore.com>
3223
3224 * s-vaflop-vms-alpha.adb: Remove pragma optimize, useless.
3225
32262011-09-01 Bob Duff <duff@adacore.com>
3227
3228 * sem_attr.adb (Analyze_Access_Attribute): Do not call
3229 Kill_Current_Values for P'Unrestricted_Access, where P is library level
3230
32312011-09-01 Thomas Quinot <quinot@adacore.com>
3232
3233 * exp_ch5.adb: Minor reformatting
3234 * gnat_ugn.texi: Fix minor typos.
3235 * gcc-interface/Make-lang.in: Update dependencies.
3236
8256c1bf
AC
32372011-09-01 Robert Dewar <dewar@adacore.com>
3238
3239 * inline.adb, sem_aggr.adb: Minor reformatting.
3240
32412011-09-01 Ed Schonberg <schonberg@adacore.com>
3242
3243 * a-convec.adb: Proper handling of cursors for Ada2012 iterators.
3244
d1c5f424
AC
32452011-09-01 Robert Dewar <dewar@adacore.com>
3246
3247 * prj-proc.adb, exp_ch6.adb, prj-env.adb: Minor reformatting.
3248
32492011-09-01 Bob Duff <duff@adacore.com>
3250
3251 * sem_aggr.adb (Resolve_Aggregate): Need to treat "in instance
3252 body" the same as "in inlined body", because visibility shouldn't
3253 apply there.
3254
32552011-09-01 Eric Botcazou <ebotcazou@adacore.com>
3256
3257 * inline.adb (Add_Inlined_Body): Refine previous change.
3258
1bb6e262
AC
32592011-09-01 Gary Dismukes <dismukes@adacore.com>
3260
3261 * exp_ch6.ads (Needs_BIP_Alloc_Form): New utility function.
3262 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
3263 Test for case where call
3264 initializes an object of a return statement before testing for
3265 a constrained call, to ensure that all such cases get handled
3266 by simply passing on the caller's parameters. Also, in that
3267 case call Needs_BIP_Alloc_Form to determine whether to pass on
3268 the BIP_Alloc_Form parameter of the enclosing function rather
3269 than testing Is_Constrained. Add similar tests for the return
3270 of a BIP call to later processing to ensure consistent handling.
3271 (Needs_BIP_Alloc_Form): New utility function.
3272 * sem_ch6.adb: (Create_Extra_Formals): Replace test for adding
3273 a BIP_Alloc_Form formal with call to new utility function
3274 Needs_BIP_Alloc_Form.
3275
32762011-09-01 Pascal Obry <obry@adacore.com>
3277
3278 * prj-part.adb: Minor reformatting.
3279
32802011-09-01 Vincent Celier <celier@adacore.com>
3281
3282 * prj-env.adb (Create_Mapping_File.Process): Encode the upper
3283 half character in the unit name.
3284
db15225a
AC
32852011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
3286
3287 * exp_ch4.adb: Minor code and comment reformatting.
3288
32892011-09-01 Thomas Quinot <quinot@adacore.com>
3290
3291 * exp_ch6.adb (Expand_Inlined_Call): Remove redundant tests
3292 for Is_Limited_Type and Is_Tagged_Type in condition checking
3293 for by-reference type.
3294 * inline.adb (Add_Inlined_Body): Only exclude init_procs. Other
3295 subprograms may have a completion because of a previous
3296 Inline_Always clause, but the enclosing package must be marked
3297 inlined for the subprogram body to become visible to the backend.
3298
9d641fc0
TQ
32992011-09-01 Thomas Quinot <quinot@adacore.com>
3300
3301 * sem_aux.adb, exp_ch4.adb: Minor reformatting
3302
dbe36d67
AC
33032011-09-01 Pascal Obry <obry@adacore.com>
3304
3305 * prj-proc.adb, prj.ads, sinput-p.adb: Minor reformatting.
3306
33072011-09-01 Ed Schonberg <schonberg@adacore.com>
3308
3309 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Generate references to
3310 the formals of a subprogram stub that acts as a spec.
3311
33122011-09-01 Ed Schonberg <schonberg@adacore.com>
3313
3314 * exp_ch6.adb (Expand_Inlined_Call): If an actual is a by_reference
3315 type, declare a renaming for it, not an object declaration.
3316
f5037886
AC
33172011-09-01 Yannick Moy <moy@adacore.com>
3318
3319 * ali-util.adb, ali-util.ads (Read_Withed_ALIs): Add parameter
3320 Ignore_Errors to ignore failures to read ALI files when True.
3321
33222011-09-01 Javier Miranda <miranda@adacore.com>
3323
3324 * exp_ch3.adb (Expand_N_Object_Declaration): Handle non-default
3325 constructor calls associated with non-tagged record types.
3326
33272011-09-01 Robert Dewar <dewar@adacore.com>
3328
3329 * g-socthi-vms.adb: Minor reformatting.
3330
33312011-09-01 Nicolas Roche <roche@adacore.com>
3332
3333 * sysdep.c: Don't use macro functions for stdio functions on VxWorks
3334 in order to avoid impact of imcompatible changes.
3335 * cstreams.c: Likewise
3336 * cio.c: Likewise
3337 * aux-io.c: Likewise
3338
33392011-09-01 Yannick Moy <moy@adacore.com>
3340
3341 * lib-writ.adb (Write_With_Lines): Always output complete information
3342 on "with" line in Alfa mode, as this is required by formal verification
3343 back-end.
3344
549e4558
AC
33452011-09-01 Tristan Gingold <gingold@adacore.com>
3346
3347 * g-socthi-vms.adb: Add comments.
3348
33492011-09-01 Pascal Obry <obry@adacore.com>
3350
3351 * prj.ads: Minor reformatting.
3352
70c0422d
AC
33532011-09-01 Vincent Celier <celier@adacore.com>
3354
3355 * prj-env.adb (Create_Config_Pragmas_File.Check): Put all naming
3356 exceptions in the config pragmas file.
3357
33582011-09-01 Tristan Gingold <gingold@adacore.com>
3359
3360 * gnat_ugn.texi: Document GNAT_STACK_SIZE on IVMS.
3361
8c5b03a0
AC
33622011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
3363
3364 * exp_ch7.adb (Find_Insertion_List): New routine.
3365 (Process_Transient_Objects): Add code to handle the abnormal
3366 finalization of a controlled transient associated with a subprogram
3367 call. Since transients are cleaned up right after the associated
3368 context, an exception raised during a subprogram call may bypass the
3369 finalization code.
3370
33712011-09-01 Robert Dewar <dewar@adacore.com>
3372
3373 * exp_ch6.adb (Expand_Call): Check actual for aliased parameter is
3374 aliased.
3375
3040dbd4
RD
33762011-09-01 Robert Dewar <dewar@adacore.com>
3377
3378 * exp_ch4.adb, a-exexda.adb: Minor reformatting.
3379
fecbd779
AC
33802011-09-01 Robert Dewar <dewar@adacore.com>
3381
3382 * s-taskin.ads, s-tassta.adb, sem_ch13.adb: Minor reformatting.
3383
33842011-09-01 Thomas Quinot <quinot@adacore.com>
3385
3386 * Makefile.rtl: Move s-oscons.o from GNATRTL_TASKING_OBJS to
3387 GNATRTL_NONTASKING_OBJS.
3388
33892011-09-01 Robert Dewar <dewar@adacore.com>
3390
3391 * einfo.ads (Is_Aliased): Fix existing documentation and add note on
3392 possibility of this flag being set for formals in Ada 2012 mode.
3393 * par-ch6.adb (P_Formal_Part): Handle aliased for parameters for Ada
3394 2012.
3395 * sem_ch6.adb (Process_Formals): Handle aliased parameters in Ada 2012
3396 mode.
3397 * sinfo.adb (Aliased_Present): Allowed in N_Parameter_Specification for
3398 Ada 2012.
3399 * sinfo.ads (Aliased_Present): Allowed in N_Parameter_Specification for
3400 Ada 2012.
3401
34022011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
3403
3404 * exp_ch4.adb (Find_Insertion_Node): New routine. Determines the proper
3405 insertion node in a tree of nested Expression_With_Actions nodes.
3406 (Process_Transient_Object): In the case where a complex if statement
3407 has been converted into nested Expression_With_Actions nodes, the
3408 "hook" object and the associated access type must be inserted before
3409 the top most Expression_With_Actions.
3410
516f608f
AC
34112011-09-01 Robert Dewar <dewar@adacore.com>
3412
3413 * a-cbprqu.adb, a-cbprqu.ads, a-cuprqu.adb, a-cuprqu.ads,
3414 a-cbsyqu.adb, a-cbsyqu.ads: Minor reformatting.
3415
34162011-09-01 Ed Schonberg <schonberg@adacore.com>
3417
3418 * sem_attr.adb: Conditionalize aliasing predicates to Ada2012.
3419
34202011-09-01 Jose Ruiz <ruiz@adacore.com>
3421
3422 * aspects.ads (Aspect_Id, Aspect_Argument, Aspect_Names): Add the CPU
3423 aspect.
3424 * aspects.adb (Canonical_Aspect): Add entry for the CPU aspect.
3425 * sem_ch13.adb (Analyze_Aspect_Specifications): Analyze the CPU aspect
3426 in a similar way as we do for the Priority or Dispatching_Domain aspect.
3427 * s-mudido-affinity.adb (Dispatching_Domain_Tasks,
3428 Dispatching_Domains_Frozen): Move this local data to package
3429 System.Tasking because with the CPU aspect we need to have access
3430 to this data when creating the task in System.Tasking.Stages.Create_Task
3431 * s-taskin.ads (Dispatching_Domain_Tasks, Dispatching_Domains_Frozen):
3432 Move these variables from the body of
3433 System.Multiprocessors.Dispatching_Domains because with the CPU aspect
3434 we need to have access to this data when creating the task in
3435 System.Tasking.Stages.Create_Task.
3436 * s-taskin.adb (Initialize): Signal the allocation of the environment
3437 task to a CPU, if any, so that we know whether the CPU can be
3438 transferred to a different dispatching domain.
3439 * s-tassta.adb (Create_Task): Check whether the CPU to which this task
3440 is being allocated belongs to the dispatching domain where the task
3441 lives. Signal the allocation of the task to a CPU, if any, so that we
3442 know whether the CPU can be transferred to a different dispatching
3443 domain.
3444
2d42e881
ES
34452011-09-01 Ed Schonberg <schonberg@adacore.com>
3446
3447 * exp_attr.adb, sem_attr.adb, snames.ads-tmpl: Implementation of
3448 attributes Same_Storage and Overlaps_Storage.
3449
579fda56
AC
34502011-09-01 Hristian Kirtchev <kirtchev@adacore.com>
3451
3452 * exp_strm.adb: Remove with and use clause for Opt.
3453 (Build_Array_Input_Function): Remove the version-dependent generation
3454 of the return statement. The Ada 2005 tree is now the default.
3455
34562011-09-01 Yannick Moy <moy@adacore.com>
3457
3458 * put_alfa.adb: Unconditionnally write files in Alfa section, so that
3459 it is never empty when compiling in Alfa mode.
3460
34612011-09-01 Robert Dewar <dewar@adacore.com>
3462
3463 * sem_aggr.adb, sem_ch3.adb, a-direct.adb, s-taprop-vxworks.adb,
3464 comperr.adb, exp_ch9.adb, exp_pakd.adb, sem_ch12.adb, freeze.adb,
3465 s-taprop-mingw.adb, s-taprop-linux.adb, s-taprop-solaris.adb,
3466 gnat1drv.adb, a-rbtgbo.adb, exp_dist.adb: Minor reformatting
3467
34682011-09-01 Matthew Heaney <heaney@adacore.com>
3469
3470 * Makefile.rtl, impunit.adb: Add a-csquin.ads, a-cusyqu.ad[sb],
3471 a-cuprqu.ad[sb], a-cbsyqu.ad[sb], a-cbprqu.ad[sb]
3472 * a-csquin.ads: New Ada 2012 unit that specifies the queue interface
3473 * a-cusyqu.ads, a-cusyqu.adb: New Ada 2012 unit that specifies the
3474 unbounded queue container.
3475 * a-cbsyqu.ads, a-cbsyqu.adb: New Ada 2012 unit that specifies the
3476 bounded queue container.
3477 * a-cuprqu.ads, a-cuprqu.adb: New Ada 2012 unit that specifies the
3478 unbounded priority queue container.
3479 * a-cbprqu.ads, a-cbprqu.adb: New Ada 2012 unit that specifies the
3480 bounded priority queue container.
3481
24c34107
AC
34822011-08-31 Pascal Obry <obry@adacore.com>
3483
3484 * a-direct.adb: Do not try to create an UNC path on Windows.
3485 (Create_Path): Skip leading computer name in UNC path if any.
3486
34872011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3488
3489 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function): Remove the
3490 version-dependent generation of the return statement. The Ada 2005 tree
3491 is now the default.
3492
34932011-08-31 Thomas Quinot <quinot@adacore.com>
3494
3495 * rtsfind.ads, exp_dist.adb (Find_Numeric_Representation): Predefined
3496 types Stream_Element_Offset and Storage_Offset have a different native
3497 type depending on whether the platform is 32 or 64 bits. When
3498 exchanging them, always convert to 64 bits.
3499
35002011-08-31 Yannick Moy <moy@adacore.com>
3501
3502 * debug.adb: Reserve debug option -gnatd.E for passing gnatprove option
3503 --force-alfa to gnat2why.
3504
35052011-08-31 Ed Schonberg <schonberg@adacore.com>
3506
3507 * sem_ch12.adb (Save_References): If the node has aspects, save
3508 references within the corresponding expressions in a separate step,
3509 because the aspects are not directly in the tree for the declaration
3510 to which they belong.
3511
35122011-08-31 Arnaud Charlet <charlet@adacore.com>
3513
3514 * freeze.adb (Freeze_Record_Type): Omit test on variable size component
3515 in CodePeer mode, since representation clauses are partially ignored.
3516 * gcc-interface/Make-lang.in: Update dependencies.
3517
702d2020
AC
35182011-08-31 Jose Ruiz <ruiz@adacore.com>
3519
3520 * s-taprop-vxworks.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
3521 s-taprop-solaris.adb (Create_Task): Not_A_Specific_CPU can be assigned
3522 to any dispatching domain.
3523
35242011-08-31 Thomas Quinot <quinot@adacore.com>
3525
3526 * exp_ch4.adb: Minor reformatting.
3527
35282011-08-31 Bob Duff <duff@adacore.com>
3529
3530 * sem_ch6.adb (Get_Generic_Parent_Type): Don't query Subtype_Indication
3531 on nodes for which it is not defined.
3532 (Is_Non_Overriding_Operation): Exit the loop when we find a generic
3533 parent type.
3534
35352011-08-31 Bob Duff <duff@adacore.com>
3536
3537 * sem_ch3.adb (Process_Full_View): Disable legality check if
3538 In_Instance, to avoid spurious errors.
3539 * sem_ch12.adb (Validate_Derived_Type_Instance): Disable legality check
3540 if In_Instance, to avoid spurious errors.
3541
35422011-08-31 Pascal Obry <obry@adacore.com>
3543
3544 * a-direct.adb: Use Dir_Seps everywhere to properly handle all
3545 directory speparators.
3546 (Compose): Use Dir_Seps to handle both forms.
3547 (Create_Path): Use Dir_Seps instead of explicit check, no semantic
3548 changes.
3549 (Extension): Use Dir_Seps to handle both forms.
3550
35512011-08-31 Pascal Obry <obry@adacore.com>
3552
3553 * prj-conf.adb: Minor reformatting.
3554
67645bde
AC
35552011-08-31 Jose Ruiz <ruiz@adacore.com>
3556
3557 * aspects.ads (Aspect_Id, Aspect_Argument, Aspect_Names): Add the
3558 dispatching domain aspect.
3559 * aspects.adb (Canonical_Aspect): Add entry for the dispatching domain
3560 aspect.
3561 * sem_ch13.adb (Analyze_Aspect_Specifications): Analyze the
3562 Dispatching_Domain aspect in a similar way as we do for the Priority
3563 aspect.
3564 * exp_ch9.adb (Expand_N_Task_Type_Declaration): Add the
3565 Dispatching_Domain component if a Dispatching_Domain pragma or aspect
3566 is present.
3567 (Make_Task_Create_Call): Add the Dispatching_Domain when creating a task
3568 * par-prag.adb (Prag): Add Pragma_Dispatching_Domain as a known pragma.
3569 * sem_prag.adb (Analyze_Pragma): Check the correctness of a pragma
3570 Dispatching_Domain and add it to the task definition.
3571 (Sig_Flags): Add Pragma_Dispatching_Domain.
3572 * rtsfind.ads, rtsfind.adb (RTU_Id, RE_Id, Get_Unit_Name): Add the
3573 support to find the types Dispatching_Domain and
3574 Dispatching_Domain_Access.
3575 * sinfo.ads, sinfo.adb (Has_Pragma_Dispatching_Domain,
3576 Set_Has_Pragma_Dispatching_Domain): Add these subprograms to set and
3577 query the availability of a pragma Dispatching_Domain.
3578 * snames.ads-tmpl (Name_uDispatching_Domain): Add this name required by
3579 the expander to pass the Dispatching_Domain when creating a task.
3580 (Name_Dispatching_Domain): Add this new name for a pragma.
3581 (Pragma_Id): Add the new Pragma_Dispatching_Domain.
3582 * s-tassta.ads, s-tassta.adb (Create_Task): Set the domain to which the
3583 task has been allocated at creation time.
3584 * s-tarest.adb (Create_Restricted_Task): The dispatching domain using
3585 Ravenscar is always null.
3586 * s-taskin.ads, s-taskin.adb (Initialize_ATCB): Set the domain to which
3587 the task has been allocated at creation time.
3588 * s-tporft.adb (Register_Foreign_Thread): A foreign task will not have
3589 a specific dispatching domain.
3590 * s-taprop-linux.adb, s-taprop-solaris.adb, s-taprop-vxworks.adb,
3591 s-taprop-mingw.adb (Create_Task): Check whether both Dispatching_Domain
3592 and CPU are specified for the task, and the CPU value is not contained
3593 within the range of processors for the domain.
3594
35952011-08-31 Vincent Celier <celier@adacore.com>
3596
3597 * make.adb (Original_Gcc) : New constant String_Access.
3598 (Gnatmake): For VM targets, do not use VM version of the compiler if
3599 --GCC= has been specified.
3600
36012011-08-31 Thomas Quinot <quinot@adacore.com>
3602
3603 * sem_ch5.adb: Minor reformatting.
3604
36052011-08-31 Ed Schonberg <schonberg@adacore.com>
3606
3607 * exp_pakd.adb (Convert_To_PAT_Type): If prefix is a function call, do
3608 not reanalyze it.
3609
36102011-08-31 Bob Duff <duff@adacore.com>
3611
3612 * exp_ch4.adb (Expand_N_Selected_Component): Use the full type, in case
3613 the access type is private; we don't care about privacy in expansion.
3614
36152011-08-31 Ed Schonberg <schonberg@adacore.com>
3616
3617 * sem_aggr.adb (Resolve_Aggregate): In an instance, ignore aggregate
3618 subcomponents tnat may be limited, because they originate in view
3619 conflicts. If the original aggregate is legal and the actuals are
3620 legal, the aggregate itself is legal.
3621
b8789727
AC
36222011-08-31 Matthew Heaney <heaney@adacore.com>
3623
3624 * a-rbtgbo.adb (Clear_Tree): Assert representation invariant for lock
3625 status.
3626
36272011-08-31 Ed Schonberg <schonberg@adacore.com>
3628
3629 * sem_ch5.adb: Set kind of loop parameter properly, to preserve all
3630 errors in B tests.
3631
36322011-08-31 Jose Ruiz <ruiz@adacore.com>
3633
3634 * sem_ch13.adb (Analyze_Aspect_Specifications): For the Priority and
3635 Interrupt_Priority aspects, force the analysis of the aspect expression
3636 (when building the equivalent pragma). Otherwise, its analysis is done
3637 too late, after the task or protected object has been created.
3638 * sem_ch9.adb (Analyze_Single_Protected_Declaration,
3639 Analyze_Single_Task_Declaration): Remove the code to move the aspects
3640 to the object declaration because they are needed in the type
3641 declaration.
3642
e0c32166
AC
36432011-08-31 Robert Dewar <dewar@adacore.com>
3644
3645 * exp_ch5.adb, exp_ch7.ads, sem_ch5.adb, put_scos.adb, s-rannum.adb,
3646 a-rbtgbo.adb, exp_intr.adb, a-cbdlli.adb, a-cbdlli.ads: Minor
3647 reformatting.
3648
36492011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3650
3651 * exp_util.adb (Find_Protection_Type): Do not look for fields _object
3652 if the corresponding type is malformed due to restriction violations.
3653
36542011-08-31 Robert Dewar <dewar@adacore.com>
3655
3656 * s-ransee.ads, s-ransee.adb: Minor reformatting.
3657
36582011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3659
3660 * exp_ch4.adb (Expand_N_Allocator): Correct faulty condition which
3661 would cause the generation of Set_Finalize_Address if the target is a
3662 VM and the designated type is not derived from [Limited_]Controlled.
3663
36642011-08-31 Arnaud Charlet <charlet@adacore.com>
3665
3666 * comperr.adb, comperr.ads, gnat1drv.adb (Delete_SCIL_Files): New
3667 subprogram.
3668 (Compiler_Abort, Gnat1drv): Call Delete_SCIL_Files in codepeer mode in
3669 case of a compilation error.
3670
36712011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3672
3673 * init.c (__gnat_error_handler): Standardize the stack overflow or
3674 erroneous memory access message.
3675 * seh_init.c (__gnat_SEH_error_handler): Standardize the stack overflow
3676 or erroneous memory access message.
3677
11bc76df
AC
36782011-08-31 Robert Dewar <dewar@adacore.com>
3679
3680 * sem_ch4.adb: Minor reformatting.
3681 * sem_ch6.adb: Minor code reorganization (use Ekind_In).
3682
36832011-08-31 Thomas Quinot <quinot@adacore.com>
3684
3685 * scos.ads: Minor documentation clarification.
3686 * put_scos.adb: Do not generate SCO unit header line for a unit that
3687 has no SCO lines.
3688
876d4394
RD
36892011-08-31 Robert Dewar <dewar@adacore.com>
3690
3691 * a-rbtgbo.adb, alfa_test.adb: Minor reformatting.
3692
36b8f95f
AC
36932011-08-31 Tristan Gingold <gingold@adacore.com>
3694
3695 * exp_ch7.ads, exp_ch7.adb (Finalization_Exception_Data): New type to
3696 hold variables between these following subprograms.
3697 (Build_Exception_Handler, Build_Object_Declarations,
3698 Build_Raise_Statement): Use the above type as parameter.
3699 Make the above adjustments.
3700 * exp_intr.adb (Expand_Unc_Deallocation): Adjust.
3701
37022011-08-31 Pascal Obry <obry@adacore.com>
3703
3704 * projects.texi: Minor reformatting.
3705
37062011-08-31 Tristan Gingold <gingold@adacore.com>
3707
3708 * s-ransee.ads, s-ransee.adb: Add system.random_seed unit.
3709 * s-rannum.adb (Reset): Use Get_Seed from s-ransee.
3710
37112011-08-31 Ed Schonberg <schonberg@adacore.com>
3712
3713 * exp_ch5.adb: Minor code cleanup.
3714 * sem_ch5.adb (Analyze_Iteration_Scheme): Set ekind of loop variable to
3715 prevent cascaded errors.
3716 (Analyze_Loop_Statement): In semantics-only mode, introduce loop
3717 variable of an iterator specification in current scope.
3718 * sem_ch6.adb (Analyze_Return_Statement, Find_what_It_Apples_To): Skip
3719 postconditions on the stack, as they contain no return statements.
3720
37212011-08-31 Yannick Moy <moy@adacore.com>
3722
3723 * exp_alfa.adb (Expand_Alfa_N_Package_Declaration,
3724 Expand_Alfa_N_Subprogram_Body): Remove useless procedures which simply
3725 call Qualify_Entity_Names.
3726 (Expand_Alfa): call Qualify_Entity_Names in more cases
3727 * lib-xref-alfa.adb: Take into account system package.
3728 * sem_prag.adb Take into account restrictions in Alfa mode, contrary to
3729 CodePeer mode in which we are interested in finding bugs even if
3730 compiler cannot compile source.
3731 * sem_util.adb, sem_util.ads (Unique_Entity): Take into account case of
3732 deferred constant.
3733
37342011-08-31 Gary Dismukes <dismukes@adacore.com>
3735
3736 * sem_ch3.adb (Constrain_Concurrent): Retrieve Base_Type of the subtype
3737 denoted by the subtype mark to ensure getting the concurrent type in
3738 the case where the subtype mark denotes a private subtype of a
3739 concurrent type (needed when using -gnatc).
3740 (Process_Subtype): For the processing specific to type kinds, case on
3741 the Base_Type kind of the Subtype_Mark_Id, to handle cases where the
3742 subtype denotes a private subtype whose base type is nonprivate (needed
3743 for subtypes of private fulfilled by task types when compiling with
3744 -gnatc).
3745
37462011-08-31 Gary Dismukes <dismukes@adacore.com>
3747
3748 * sem_disp.adb (Check_Dispatching_Operation): Bypass registration of
3749 late primitives that override interface operations when the full
3750 expander is not active, to avoid blowups in Register_Primitive when
3751 types don't have associated secondary dispatch tables.
3752
37532011-08-31 Yannick Moy <moy@adacore.com>
3754
3755 * alfa_test.adb: Code clean up.
3756
37572011-08-31 Marc Sango <sango@adacore.com>
3758
3759 * restrict.adb (Check_SPARK_Restriction): Change Comes_From_Source (N)
3760 by Comes_From_Source (Original_Node (N)) in order to treat also the
3761 nodes which have been rewritten.
3762 * sem_ch4.adb (Analyze_Explicit_Dereference, Analyze_Slice): Guard the
3763 explicit dereference and slice violation in spark mode on the nodes
3764 coming only from the source code.
3765
8cf23b91
AC
37662011-08-31 Robert Dewar <dewar@adacore.com>
3767
3768 * exp_ch5.adb, exp_alfa.ads, prj.ads, sem_attr.adb,
3769 lib-xref-alfa.adb: Minor reformatting.
3770
37712011-08-31 Matthew Heaney <heaney@adacore.com>
3772
3773 * a-crbltr.ads (Tree_Type): Default-initialize the Nodes component.
3774
37752011-08-31 Javier Miranda <miranda@adacore.com>
3776
3777 * sem_ch4.adb (Try_Object_Operation): Addition of one formal to search
3778 only for class-wide subprograms conflicting with entities of concurrent
3779 tagged types.
3780
37812011-08-31 Matthew Heaney <heaney@adacore.com>
3782
3783 * a-rbtgbo.adb (Generic_Allocate): Initialize pointer components of
3784 node to null value.
3785
37862011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3787
3788 * sem_ch12.adb (Insert_Freeze_Node_For_Instance): Provide a more
3789 general description of the routine.
3790
37912011-08-31 Ed Schonberg <schonberg@adacore.com>
3792
3793 * a-cbdlli.adb, a-cbdlli.ads: Add iterator machinery to bounded
3794 doubly-linked lists.
3795
0bb3bfb8
GD
37962011-08-31 Gary Dismukes <dismukes@adacore.com>
3797
3798 * exp_ch5.adb (Expand_N_Assignment_Statement): When a discriminant
3799 check is needed for a left-hand side that is a dereference, and the
3800 base type is private without discriminants (whereas the full type does
3801 have discriminants), an extra retrieval of the underlying type may be
3802 needed in the case where the subtype is a record subtype whose base
3803 type is private. Update comments.
3804
11fa950b
AC
38052011-08-31 Javier Miranda <miranda@adacore.com>
3806
3807 * sem_ch4.adb (Try_Object_Operation): When a dispatching primitive is
3808 found check if there is a class-wide subprogram covering the primitive.
3809
38102011-08-31 Yannick Moy <moy@adacore.com>
3811
3812 * sem_res.adb: Further cases where full expansion test is needed,
3813 rather than expansion test.
3814
38152011-08-31 Pascal Obry <obry@adacore.com>
3816
3817 * prj-attr.adb: Fix Source_File_Switches attribute kind (must be a list)
3818
38192011-08-31 Ed Schonberg <schonberg@adacore.com>
3820
3821 * exp_ch5.adb: Handle iterators over derived container types.
3822
38232011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3824
3825 * einfo.ads, einfo.adb: Add new flag Has_Anonymous_Master.
3826 (Has_Anonymous_Master): New routine.
3827 (Set_Has_Anonymous_Master): New routine.
3828 (Write_Entity_Flags): Add an entry for Has_Anonymous_Master.
3829 * exp_ch4.adb: Add with and use clause for Sem_Ch8.
3830 (Current_Anonymous_Master): New routine.
3831 (Current_Unit_First_Declaration): Removed.
3832 (Current_Unit_Scope): Removed.
3833 (Expand_N_Allocator): Anonymous access-to-controlled types now chain
3834 their objects on a per-unit heterogeneous finalization master.
3835
38362011-08-31 Matthew Heaney <heaney@adacore.com>
3837
3838 * a-cbhama.adb, a-cbhase.adb (Insert): Check for zero-length buckets
3839 array.
3840
38412011-08-31 Jose Ruiz <ruiz@adacore.com>
3842
3843 * s-taprop-linux.adb (Create_Task): Avoid changing the affinity mask
3844 when not needed.
3845
38462011-08-31 Gary Dismukes <dismukes@adacore.com>
3847
3848 * sem_disp.adb (Propagate_Tag): Return without propagating in the case
3849 where the actual is an unexpanded call to 'Input.
3850
d2b4b3da
AC
38512011-08-31 Yannick Moy <moy@adacore.com>
3852
3853 * sem_ch4.adb: Code clean up.
3854
38552011-08-31 Yannick Moy <moy@adacore.com>
3856
3857 * exp_alfa.adb, exp_alfa.ads: Minor correction of copyright notice.
3858
38592011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3860
3861 * exp_ch7.adb (Build_Array_Deep_Procs): Do not generate Deep_Finalize
3862 and TSS primitive Finalize_Address if finalization is suppressed.
3863 (Build_Record_Deep_Procs): Do not generate Deep_Finalize and TSS
3864 primitive Finalize_Address if finalization is suppressed.
3865
38662011-08-31 Jose Ruiz <ruiz@adacore.com>
3867
3868 * s-mudido-affinity.adb, s-taprop-linux.adb, s-taprop-mingw.adb,
3869 s-taprop-solaris.adb, s-taprop-vxworks.adb (Set_Task_Affinity): Make
3870 sure that the underlying task has already been created before trying
3871 to change its affinity.
3872 (Set_CPU): Use the term processor instead of CPU, as we do in
3873 Assign_Task.
3874
38752011-08-31 Vincent Celier <celier@adacore.com>
3876
3877 * prj-attr.adb: New Compiler attribute Source_File_Switches.
3878 * prj-nmsc.adb (Process_Compiler): Process attribute
3879 Source_File_Switches.
3880 * prj.ads (Language_Config): New name list component
3881 Name_Source_File_Switches.
3882 * snames.ads-tmpl (Name_Source_File_Switches): New standard name.
3883
38842011-08-31 Ed Schonberg <schonberg@adacore.com>
3885
3886 * sem_attr.adb (Analyze_Attribute, case 'Old): If prefix may be a
3887 discriminated component of an actual, expand at once to prevent
3888 ouf-of-order references with generated subtypes.
3889
38902011-08-31 Yannick Moy <moy@adacore.com>
3891
3892 * lib-xref-alfa.adb (Add_Alfa_Xrefs): Do not take into account read
3893 reference to operator in Alfa xrefs.
3894
38952011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3896
3897 * sem_ch12.adb (Freeze_Subprogram_Body): Add code to handle the case
3898 where the parent instance was frozen before the current instance due to
3899 the presence of a source body. Update calls to Insert_After_Last_Decl.
3900 (Insert_After_Last_Decl): Renamed to Insert_Freeze_Node_For_Instance.
3901 Update the comment which illustrates the purpose of the routine.
3902 Package instances are now frozen by source bodies which appear after
3903 the instance. This ensures that entities coming from within the
3904 instance are available for use in the said bodies.
3905 (Install_Body): Add code to handle the case where the parent instance
3906 was frozen before the current instance due to the presence of a source
3907 body. Update calls to Insert_After_Last_Decl.
3908
56812278
AC
39092011-08-31 Jose Ruiz <ruiz@adacore.com>
3910
3911 * s-taprop-linux.adb (Set_Task_Affinity): Avoid the use of anonymous
3912 access types.
3913 * affinity.c (__gnat_set_affinity_mask): Declare index variable.
3914
39152011-08-31 Yannick Moy <moy@adacore.com>
3916
3917 * sem_ch8.adb (Analyze_Subprogram_Renaming): Refine expander test in
3918 full-expander test.
16c3301a
AC
3919 * alfa.adb, alfa.ads, alfa_test.adb, ali.adb, debug.adb, errout.adb,
3920 errout.ads, erroutc.adb, expander.adb, exp_ch4.adb, exp_ch7.adb,
3921 freeze.adb, get_alfa.adb, get_alfa.ads, gnat1drv.adb, lib-writ.adb,
3922 lib-writ.ads, lib-xref.adb, lib-xref.ads, lib-xref-alfa.adb, opt.adb,
3923 opt.ads, put_alfa.adb, put_alfa.ads, restrict.adb, sem_ch12.adb,
3924 sem_ch13.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
3925 sem_prag.adb, sem_res.adb, sem_util.adb: Minor reformatting, renaming
3926 ALFA in Alfa (we dropped acronym).
56812278
AC
3927 * einfo.adb (Primitive_Operations): Correctly return list of primitive
3928 operations in a case where it returned previously No_Elist.
3929
7cda9727
RD
39302011-08-31 Robert Dewar <dewar@adacore.com>
3931
3932 * s-taprop-vxworks.adb, sem_ch5.adb, s-taprop-tru64.adb, exp_alfa.adb,
3933 s-taprop-vms.adb, bindgen.adb, s-mudido.adb, s-mudido.ads,
3934 sem_res.adb, expander.adb, s-taprop-mingw.adb, s-taprop-linux.adb,
3935 s-taprop-solaris.adb, s-mudido-affinity.adb, vms_conv.adb,
3936 s-taprop-irix.adb, s-taprop.ads, s-taskin.adb, s-taskin.ads,
3937 s-taprop-hpux-dce.adb, a-chtgbo.adb, s-taprop-posix.adb: Minor
3938 reformatting.
3939
0a190dfd
AC
39402011-08-31 Hristian Kirtchev <kirtchev@adacore.com>
3941
3942 * sem_ch12 (Check_Private_View): Revert previous change.
3943 * sem_res.adb (Conversion_Check): Do not emit the error message if the
3944 conversion is in a generic instance.
3945
39462011-08-31 Matthew Heaney <heaney@adacore.com>
3947
3948 * a-cbhase.adb (Symmetric_Difference): Dereference correct node array.
3949 * a-chtgbo.adb (Free): Allow 0 as index value.
3950
39512011-08-31 Matthew Heaney <heaney@adacore.com>
3952
3953 * a-cborma.adb (Insert): Add comment to explain why no element
3954 assignment.
3955
39562011-08-31 Gary Dismukes <dismukes@adacore.com>
3957
3958 * sem_util.adb (Find_Body_Discriminal): Test whether the scope of the
3959 spec discriminant is already a concurrent type, in which case just use
3960 it, otherwise fetch the Corresponding_Concurrent_Type as before.
3961
7d266442
EB
39622011-08-30 Eric Botcazou <ebotcazou@adacore.com>
3963
3964 * system-irix-n64.ads, system-linux-armeb.ads, system-linux-armel.ads,
3965 system-linux-mips.ads, system-linux-mipsel.ads,
3966 system-linux-mips64el.ads, system-linux-ppc64.ads,
3967 system-linux-sparcv9.ads, system-rtems.ads: Remove GCC_ZCX_Support.
3968
4f1a975c
EB
39692011-08-30 Eric Botcazou <ebotcazou@adacore.com>
3970
3971 * gcc-interface/ada-tree.h (TYPE_EXTRA_SUBTYPE_P): Add internal check.
3972 * gcc-interface/utils2.c (build_binary_op): Tighten condition.
3973 (build_unary_op): Likewise.
3974
f2991b48
EB
39752011-08-30 Eric Botcazou <ebotcazou@adacore.com>
3976
3977 * raise-gcc.c: Do not include coretypes.h and tm.h.
3978 (setup_to_install): Remove test for compiler macro.
3979 * targext.c: Document use for the library.
3980 * gcc-interface/Makefile.in: Fix comment on the use of IN_GCC.
3981
10a22f43
EB
39822011-08-30 Eric Botcazou <ebotcazou@adacore.com>
3983
3984 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Do not convert
3985 the expression to the nominal type if the latter is a record type with
3986 a variant part and the type of the former is a record type without one.
3987
bfa2e39d
AC
39882011-08-30 Yannick Moy <moy@adacore.com>
3989
3990 * exp_aggr.adb, exp_ch11.adb, exp_prag.adb: Remove early exit during
3991 expansion in Alfa mode.
3992 * exp_ch6.adb, exp_ch6.ads (Expand_Actuals): Make subprogram public
3993 * exp_alfa.adb, exp_alfa.ads: New package defining light expansion for
3994 Alfa mode.
3995 * gnat1drv.adb (Adjust_Global_Switches): Update Comment.
3996 * sem_res.adb: Ditto.
bd34109a 3997 * gcc-interface/Make-lang.in: Update dependencies.
bfa2e39d
AC
3998
39992011-08-30 Thomas Quinot <quinot@adacore.com>
4000
4001 * g-socket.ads: Minor documentation adjustment.
4002
a0347839
AC
40032011-08-30 Robert Dewar <dewar@adacore.com>
4004
4005 * exp_ch9.adb, s-tassta.adb, s-secsta.adb: Minor reformatting.
4006
40072011-08-30 Yannick Moy <moy@adacore.com>
4008
4009 * exp_ch6_light.adb, exp_ch6_light.ads, exp_attr_light.adb,
4010 exp_attr_light.ads, exp_ch7_light.adb, exp_ch7_light.ads,
4011 exp_light.adb, exp_light.ads, exp_prag.adb, expander.adb,
4012 gnat1drv.adb, exp_ch11.adb, exp_ch6.adb, exp_ch6.ads, exp_aggr.adb:
4013 Revert change which introduced files for "light"
4014 expansion, to be replaced by a single file for Alfa expansion.
4015
3597c0e9
RD
40162011-08-30 Robert Dewar <dewar@adacore.com>
4017
4018 * opt.ads, s-soflin.adb, exp_ch9.adb, sem_res.adb: Update comment.
4019 Minor code reorg/reformatting.
4020
da94696d
AC
40212011-08-30 Yannick Moy <moy@adacore.com>
4022
4023 * opt.adb, opt.ads (Full_Expander_Active): New function defines a
4024 common shorthand for (Expander_Active and not ALFA_Mode) that can be
4025 used for testing full expansion, that is active expansion not in the
4026 reduced mode for Alfa
4027 * exp_ch4.adb, exp_ch9.adb, exp_disp.adb, sem_ch10.adb, sem_ch12.adb,
4028 sem_ch6.adb, sem_ch9.adb, sem_res.adb: Use newly defined "flag" instead
4029 of the verbose (Expander_Active and not ALFA_Mode)
4030
40312011-08-30 Tristan Gingold <gingold@adacore.com>
4032
4033 * s-parame-vms-alpha.ads, s-parame-hpux.ads, s-tassta.adb,
4034 s-tarest.adb, s-parame-vms-ia64.ads, s-soflin.adb, s-secsta.adb,
5b8ca141
TG
4035 s-secsta.ads, s-parame.ads, s-parame-vxworks.ads, s-parame-ae653.ads:
4036 Renames Ratio to Percentage, and Sec_Stack_Ratio to Sec_Stack_Percentage
da94696d 4037
c199ccf7
AC
40382011-08-30 Gary Dismukes <dismukes@adacore.com>
4039
4040 * sem_res.adb (Valid_Conversion): Revise test for implicit anonymous
4041 access conversions to check that the conversion is a rewritten node,
4042 rather than just having Comes_From_Source set to False, which wasn't
4043 sufficient.
4044
40452011-08-30 Robert Dewar <dewar@adacore.com>
4046
4047 * exp_ch9.adb, sem_ch9.adb, sem_ch6.adb, exp_disp.adb,
4048 g-socket.ads: Minor reformatting.
4049
40502011-08-30 Thomas Quinot <quinot@adacore.com>
4051
4052 * sem_util.adb: Minor reformatting.
4053
40542011-08-30 Tristan Gingold <gingold@adacore.com>
4055
4056 * raise-gcc.c: Never catch exception if _UA_FORCE_UNWIND flag is set,
4057 to be compliant with the ABI.
4058
dff99e1a
AC
40592011-08-30 Hristian Kirtchev <kirtchev@adacore.com>
4060
4061 * sem_ch12.adb (Check_Private_View): Exchange the private and full view
4062 of a designated type when the related access type is an actual in an
4063 instance. This ensures that the full view of designated type is
4064 available when inside the body of the instance.
4065
40662011-08-30 Ed Schonberg <schonberg@adacore.com>
4067
4068 * sem_util.adb (May_Be_Lvalue): To determine whether a reference may be
4069 in a position to be modified, a slice is treated like an indexed
4070 component.
4071
63be2a5a
AC
40722011-08-30 Thomas Quinot <quinot@adacore.com>
4073
4074 * s-oscons-tmplt.c, g-socket.ads: Adjust maximum allowed value for
4075 field tv_sec in struct timeval.
4076
40772011-08-30 Yannick Moy <moy@adacore.com>
4078
4079 * exp_ch9.adb, exp_disp.adb, sem_ch9.adb, sem_res.adb: Protect several
4080 blocks of code doing full expansion, previously only guarded by
4081 Expander_Active, by anding the test that ALFA_Mode is not set
4082
40832011-08-30 Ed Schonberg <schonberg@adacore.com>
4084
4085 * sem_ch6.adb (Analyze_Return_Type): If the return type is incomplete,
4086 add the function to the list of private dependents, for subsequent
4087 legality check on Taft amendment types.
4088 * sem_ch12.adb (Analyze_Formal_Incomplete_Type): Initialize
4089 Private_Dependents, as for other incomplete types.
4090 * sem_util.adb (Wrong_Type): Avoid cascaded errors when a
4091 Taft-amendment type is used as the return type of a function.
4092
dd54644b
JM
40932011-08-30 Javier Miranda <miranda@adacore.com>
4094
4095 * sem_ch3.adb (Check_Abstract_Overriding): Code cleanup: replace code
4096 which emits an error by a call to a new routine which report the error.
4097 * exp_ch9.adb (Build_Wrapper_Spec): Build the wrapper even if the
4098 entity does not cover an existing interface.
4099 * errout.ads, errout.adb (Error_Msg_PT): New routine. Used to factorize
4100 code.
4101 * sem_ch6.adb (Check_Conformance): Add specific error for wrappers of
4102 protected procedures or entries whose mode is not conformant.
4103 (Check_Synchronized_Overriding): Code cleanup: replace code which emits
4104 an error by a call to a new routine which report the error.
4105
d3ba478e
AC
41062011-08-30 Robert Dewar <dewar@adacore.com>
4107
4108 * gnat_rm.texi: Minor change.
4109 * exp_attr_light.adb: Minor reformatting.
4110
41112011-08-30 Ed Schonberg <schonberg@adacore.com>
4112
4113 * sem_ch3.adb: Patch inheritance of aspects in
4114 Complete_Private_Subtype, to avoid infinite loop.
4115
c01817d2
AC
41162011-08-30 Javier Miranda <miranda@adacore.com>
4117
4118 * sem_ch3.adb (Add_Internal_Interface_Entities): If serious errors have
4119 been reported and a subprogram covering an interface primitive is not
4120 found then skip generating the internal entity. Done to avoid crashing
4121 the frontend.
4122 (Check_Abstract_Overriding): Change text of error of wrong formal of
4123 protected subprogram or entry. Done for consistency to emit exactly the
4124 same error reported by Check_Synchronized_Overriding. In addition, the
4125 error is restricted to protected types (bug found working on AI05-0090)
4126
41272011-08-30 Yannick Moy <moy@adacore.com>
4128
4129 * exp_aggr.adb, exp_ch11.adb, exp_prag.adb: Remove early exit during
4130 expansion in Alfa mode.
4131 * exp_ch6.adb, exp_ch6.ads (Expand_Actuals): Make subprogram public.
4132 * exp_light.adb, exp_light.ads: New package defining light expansion.
4133 * expander.adb (Expand): Call light expansion in Alfa mode
4134 * exp_ch6_light.adb, exp_ch6_light.ads: Light expansion of chapter 6
4135 constructs.
4136 * exp_ch7_light.adb, exp_ch7_light.ads: Light expansion of chapter 7
4137 constructs.
4138 * exp_attr_light.adb, exp_attr_light.ads: Light expansion of attributes
4139 * gnat1drv.adb (Adjust_Global_Switches): Comment
4140
41412011-08-30 Yannick Moy <moy@adacore.com>
4142
4143 * lib-xref-alfa.adb: Minor refactoring.
4144
41452011-08-30 Yannick Moy <moy@adacore.com>
4146
4147 * exp_ch9.adb (Expand_Entry_Barrier): Do not perform expansion in Alfa
4148 mode.
4149 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Do not perform
4150 expansion in Alfa mode.
4151 * sem_ch9.adb (Analyze_Entry_Body): Do not perform expansion in Alfa
4152 mode.
4153
41542011-08-30 Robert Dewar <dewar@adacore.com>
4155
4156 * debug_a.adb: Update comment.
4157
996c8821
RD
41582011-08-30 Robert Dewar <dewar@adacore.com>
4159
4160 * exp_ch5.adb, sem_ch3.adb, sem_ch5.adb, einfo.adb, checks.adb,
4161 sem_util.adb, sem_util.ads, sem_res.adb, s-stposu.adb, sem_attr.adb,
4162 exp_ch4.adb, exp_ch6.adb, lib-xref-alfa.adb,
4163 sem_ch8.adb, sem_disp.adb, exp_ch3.adb: Minor reformatting
4164
41652011-08-30 Robert Dewar <dewar@adacore.com>
4166
4167 * gnat_rm.texi: Add section on C.6(16) implementation advice for pragma
4168 volatile.
4169
3647ca26
HK
41702011-08-30 Hristian Kirtchev <kirtchev@adacore.com>
4171
4172 * exp_ch3.adb (Expand_Freeze_Array_Type): Correct the call to
4173 Build_Finalization_Master by supplying an insertion node and enclosing
4174 scope. In its old version, the call did not generate a finalization
4175 master.
4176 (Expand_Freeze_Record_Type): Add local variable Has_AACC. Add code to
4177 recognize anonymous access-to-controlled components. Rewrite the
4178 machinery which creates finalization masters to service anonymous
4179 access-to-controlled components of a record type. In its current state,
4180 only one heterogeneous master is necessary to handle multiple anonymous
4181 components.
4182 (Freeze_Type): Comment reformatting.
4183 * rtsfind.ads: Add RE_Set_Is_Heterogeneous to tables RE_Id and
4184 RE_Unit_Table.
4185 * s-stposu.adb (Allocate_Any_Controlled): Rewrite the machinery which
4186 associates TSS primitive Finalize_Address with either the master itself
4187 or with the internal hash table depending on the mode of operation of
4188 the master.
4189
6d4e4fbc
JM
41902011-08-30 Javier Miranda <miranda@adacore.com>
4191
4192 * exp_ch3.adb (Make_Eq_If): If the etype of the _parent component is an
4193 interface type then do not generate code to compare this component.
4194 Required since they have no components and their equality operator is
4195 abstract.
4196
d15f9422
AC
41972011-08-30 Steve Baird <baird@adacore.com>
4198
4199 * sem_util.ads (Deepest_Type_Access_Level): New function; for the type
4200 of a saooaaat (i.e, a stand-alone object of an anonymous access type),
4201 returns the (static) accessibility level of the object. Otherwise, the
4202 same as Type_Access_Level.
4203 (Dynamic_Accessibility_Level): New function; given an expression which
4204 could occur as the rhs of an assignment to a saooaaat (i.e., an
4205 expression of an access-to-object type), return the new value for the
4206 saooaaat's associated Extra_Accessibility object.
4207 (Effective_Extra_Accessibility): New function; same as
4208 Einfo.Extra_Accessibility except that object renames are looked through.
4209 * sem_util.adb
4210 (Deepest_Type_Access_Level): New function; see sem_util.ads description.
4211 (Dynamic_Accessibility_Level): New function; see sem_util.ads
4212 description.
4213 (Effective_Extra_Accessibility): New function; see sem_util.ads
4214 description.
4215 * einfo.ads (Is_Local_Anonymous_Access): Update comments.
4216 (Extra_Accessibility): Update comments.
4217 (Init_Object_Size_Align): New procedure; same as Init_Size_Align
4218 except RM_Size field (which is only for types) is unaffected.
4219 * einfo.adb
4220 (Extra_Accessibility): Expand domain to allow objects, not just formals.
4221 (Set_Extra_Accessibility): Expand domain to allow objects, not just
4222 formals.
4223 (Init_Size): Add assertion that we are not trashing the
4224 Extra_Accessibility attribute of an object.
4225 (Init_Size_Align): Add assertion that we are not trashing the
4226 Extra_Accessibility attribute of an object.
4227 (Init_Object_Size_Align): New procedure; see einfo.ads description.
4228 * sem_ch3.adb (Find_Type_Of_Object): Set Is_Local_Anonymous_Access
4229 differently for the type of a (non-library-level) saooaaat depending
4230 whether Ada_Version < Ada_2012. This is the only point where Ada_Version
4231 is queried in this set of changes - everything else (in particular,
4232 setting of the Extra_Accessibility attribute in exp_ch3.adb) is
4233 driven off of the setting of the Is_Local_Anonymous_Access attribute.
4234 The special treatment of library-level saooaaats is an optimization,
4235 not required for correctnesss. This is based on the observation that the
4236 Ada2012 rules (static and dynamic) for saooaaats turn out to be
4237 equivalent to the Ada2005 rules in the case of a library-level saooaaat.
4238 * exp_ch3.adb
4239 (Expand_N_Object_Declaration): If Is_Local_Anonymous_Access is
4240 false for the type of a saooaaat, declare and initialize its
4241 accessibility level object and set the Extra_Accessibility attribute
4242 of the saooaaat to refer to this object.
4243 * checks.adb (Apply_Accessibility_Check): Add Ada 2012 saooaaat support.
4244 * exp_ch4.adb (Expand_N_In): Replace some Extra_Accessibility calls with
4245 calls to Effective_Extra_Accessibility in order to support
4246 renames of saooaaats.
4247 (Expand_N_Type_Conversion): Add new local function,
4248 Has_Extra_Accessibility, and call it when determining whether an
4249 accessibility check is needed.
4250 It returns True iff Present (Effective_Extra_Accessibility (Id)) would
4251 evaluate to True (without raising an exception).
4252 * exp_ch5.adb
4253 (Expand_N_Assignment_Statement): When assigning to an Ada2012
4254 saooaaat, update its associated Extra_Accessibility object (if
4255 it has one). This includes an accessibility check.
4256 * exp_ch6.adb (Add_Call_By_Copy_Code): When parameter copy-back updates
4257 a saooaaat, update its Extra_Accessibility object too (if it
4258 has one).
4259 (Expand_Call): Replace a couple of calls to Type_Access_Level
4260 with calls to Dynamic_Access_Level to handle cases where
4261 passing a literal (any literal) is incorrect.
4262 * sem_attr.adb (Resolve_Attribute): Handle the static accessibility
4263 checks associated with "Saooaat := Some_Object'Access;"; this must
4264 be rejected if Some_Object is declared in a more nested scope
4265 than Saooaat.
4266 * sem_ch5.adb (Analyze_Assignment): Force accessibility checking for an
4267 assignment to a saooaaat even if Is_Local_Anonymous_Access
4268 returns False for its type (indicating a 2012-style saooaaat).
4269 * sem_ch8.adb
4270 (Analyze_Object_Renaming): Replace a call to Init_Size_Align
4271 (which is only appropriate for objects, not types) with a call
4272 of Init_Object_Size_Align in order to avoid trashing the
4273 Extra_Accessibility attribute of a rename (the two attributes
4274 share storage).
4275 * sem_res.adb
4276 (Valid_Conversion) Replace six calls to Type_Access_Level with
4277 calls to Deepest_Type_Access_Level. This is a bit tricky. For an
4278 Ada2012 non-library-level saooaaat, the former returns library level
4279 while the latter returns the (static) accessibility level of the
4280 saooaaat. A type conversion to the anonymous type of a saooaaat
4281 can only occur as part of an assignment to the saooaaat, so we
4282 know that such a conversion must be in a lhs context, so Deepest
4283 yields the result that we need. If such a conversion could occur,
4284 say, as the operand of an equality operator, then this might not
4285 be right. Also add a test so that static accessibilty checks are
4286 performed for converting to a saooaaat's type even if
4287 Is_Local_Anonymous_Access yields False for the type.
4288
42892011-08-30 Javier Miranda <miranda@adacore.com>
4290
4291 * sem_disp.adb (Check_Dispatching_Operation): Complete condition that
4292 controls generation of a warning associated with late declaration of
4293 dispatching functions. Required to avoid generating spurious
4294 warnings.
4295
6cce2156
GD
42962011-08-30 Gary Dismukes <dismukes@adacore.com>
4297
4298 * sem_ch6.adb (Check_Return_Subtype_Indication): Issue error if the
4299 return object has an anonymous access type and the function's type is
4300 a named access type.
4301 * sem_ch8.adb (Analyze_Object_Renaming): Suppress error about renaming
4302 conversions on implicit conversions, since such conversions can occur
4303 for anonymous access cases due to expansion. Issue error for attempt
4304 to rename an anonymous expression as an object of a named access type.
4305 * sem_res.ads (Valid_Conversion): Add defaulted parameter Report_Errs,
4306 to indicate whether this function should report errors on invalid
4307 conversions.
4308 * sem_res.adb (Resolve): For Ada 2012, in the case where the type of
4309 the expression is of an anonymous access type and the expected type is
4310 a named general access type, rewrite the expression as a type
4311 conversion, unless this is an expression of a membership test.
4312 (Valid_Conversion.Error_Msg_N): New procedure that conditions the
4313 calling of Error_Msg_N on new formal Report_Errs.
4314 (Valid_Conversion.Error_Msg_NE): New procedure that conditions the
4315 calling of Error_Msg_NE on new formal Report_Errs.
4316 (Valid_Conversion): Move declaration of this function to the package
4317 spec, to allow calls from membership test processing. For Ada 2012,
4318 enforce legality restrictions on implicit conversions of anonymous
4319 access values to general access types, disallowing such conversions in
4320 cases where the expression has a dynamic accessibility level (access
4321 parameters, stand-alone anonymous access objects, or a component of a
4322 dereference of one of the first two cases).
4323 * sem_type.adb (Covers): For Ada 2012, allow an anonymous access type
4324 in the context of a named general access expected type.
4325 * exp_ch4.adb Add with and use of Exp_Ch2.
4326 (Expand_N_In): Add processing for membership tests applied to
4327 expressions of an anonymous access type. First, Valid_Conversion is
4328 called to check whether the test is statically False, and then the
4329 conversion is expanded to test that the expression's accessibility
4330 level is no deeper than that of the tested type. In the case of
4331 anonymous access-to-tagged types, a tagged membership test is applied
4332 as well.
4333 (Tagged_Membership): Extend to handle access type cases, applying the
4334 test to the designated types.
4335 * exp_ch6.adb (Expand_Call): When creating an extra actual for an
4336 accessibility level, and the actual is a 'Access applied to a current
4337 instance, pass the accessibility level of the type of the current
4338 instance rather than applying Object_Access_Level to the prefix. Add a
4339 ??? comment, since this level isn't quite right either (will eventually
4340 need to pass an implicit level parameter to init procs).
4341
747de90b
AC
43422011-08-30 Bob Duff <duff@adacore.com>
4343
4344 * s-taskin.ads: Minor comment fix.
4345
43462011-08-30 Ed Schonberg <schonberg@adacore.com>
4347
4348 * sem_res.adb (Check_Parameterless_Call): If the node is a selected
4349 component and the selector is a dispatching operation, check if it is
4350 a prefixed call before rewriting as a parameterless function call.
4351
cdc4cc65
JJ
43522011-08-29 Jakub Jelinek <jakub@redhat.com>
4353
4354 * gcc-interface/Makefile.in (../stamp-gnatlib1-$(RTSDIR)): Copy
4355 tsystem.h into $(RTSDIR) instead of rts.
4356
226a7fa4
AC
43572011-08-29 Robert Dewar <dewar@adacore.com>
4358
4359 * sem_ch10.adb, a-coorse.adb, exp_dist.adb, exp_ch3.adb: Minor
4360 reformatting.
4361 * gcc-interface/Make-lang.in: Update dependencies.
4362
43632011-08-29 Yannick Moy <moy@adacore.com>
4364
4365 * alfa.ads (Name_Of_Heap_Variable): New constant name.
4366 * lib-xref-alfa.adb, lib-xref.adb, lib-xref.ads (Drefs): New global
4367 table to hold dereferences.
4368 (Add_ALFA_Xrefs): Take into account dereferences as special
4369 reads/writes to the variable "HEAP".
4370 (Enclosing_Subprogram_Or_Package): Move subprogram here.
4371 (Generate_Dereference): New procedure to store a read/write dereferencew
4372 in the table Drefs.
4373 * put_alfa.adb (Put_ALFA): Use different default than (0,0) used for
4374 the special "HEAP" var.
4375 * sem_ch4.adb (Analyze_Explicit_Dereference): Store read dereference
4376 in ALFA mode.
4377 * sem_util.adb (Note_Possible_Modification): Store write dereference
4378 in ALFA mode.
4379
dfbcb149
HK
43802011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4381
4382 * exp_ch3.adb (Freeze_Type): Generate an accessibility check which
4383 ensures that the level of the subpool access type is not deeper than
4384 that of the pool object.
4385 * sem_util.adb (Object_Access_Level): Expand to handle defining
4386 identifiers.
4387 * sem_res.adb (Resolve_Allocator): Add a guard to avoid examining the
4388 subpool handle name of a rewritten allocator.
4389
1df4f514
AC
43902011-08-29 Robert Dewar <dewar@adacore.com>
4391
4392 * impunit.adb, exp_ch4.adb, s-finmas.adb: Minor reformatting.
4393
43942011-08-29 Thomas Quinot <quinot@adacore.com>
4395
4396 * exp_dist.adb (TC_Rec_Add_Process_Element): For a choice with multiple
4397 values, we generate multiple triples of parameters in the TypeCode.
4398 Bump Choice_Index for each such triple so that a subsequent default
4399 choice is associated with the correct index in the typecode.
4400
44012011-08-29 Ed Schonberg <schonberg@adacore.com>
4402
4403 * a-cdlili.adb (Iterate): Initialize properly an iterator over a null
4404 container.
4405 (First, Last): Handle properly an iterator over a null container.
4406
44072011-08-29 Bob Duff <duff@adacore.com>
4408
4409 * sem_ch10.adb (Analyze_With_Clause,Install_Withed_Unit): Abandon
4410 processing if we run across a node with no Scope. This can happen if
4411 we're with-ing an library-level instance, and that instance got errors
4412 that caused "instantiation abandoned".
4413 * sem_util.adb (Unit_Declaration_Node): Make it more robust, by raising
4414 an exception instead of using Assert, so it won't go into an infinite
4415 loop, even when assertions are turned off.
4416
44172011-08-29 Ed Schonberg <schonberg@adacore.com>
4418
4419 * a-coorse.adb: Proper handling of empty ordered sets.
4420
14f0f659
AC
44212011-08-29 Johannes Kanig <kanig@adacore.com>
4422
4423 * debug.adb: Add comments.
4424
8027b455
AC
44252011-08-29 Thomas Quinot <quinot@adacore.com>
4426
4427 * a-except.adb, a-except-2005.adb: Minor comment rewording and
4428 reformatting.
4429
44302011-08-29 Yannick Moy <moy@adacore.com>
4431
4432 * sem_ch3.adb (Array_Type_Declaration): Remove insertion of
4433 declaration for Itypes in Alfa mode.
4434
d85fd922
AC
44352011-08-29 Robert Dewar <dewar@adacore.com>
4436
4437 * a-cdlili.ads, a-coinve.ads, a-coorma.adb, a-coorma.ads, s-tassta.adb,
4438 a-cborma.adb, a-cborma.ads, a-cohama.ads, a-coorse.ads, a-cbhama.ads,
4439 a-cborse.ads, a-cobove.adb, a-cobove.ads, a-cbhase.ads: Minor
4440 reformatting.
4441
44422011-08-29 Tristan Gingold <gingold@adacore.com>
4443
4444 * exp_ch7.adb, exp_ch7.ads (Build_Exception_Handler): Move its spec to
4445 package spec.
4446 * exp_intr.adb (Expand_Unc_Deallocation): Use Build_Exception_Handler.
4447 * a-except.adb, a-except-2005.adb (Rcheck_22): Do not defer aborts
4448 while raising PE.
4449
fd3d2680
AC
44502011-08-29 Robert Dewar <dewar@adacore.com>
4451
4452 * a-cbhama.adb, a-cbhama.ads: Minor reformatting.
4453
44542011-08-29 Javier Miranda <miranda@adacore.com>
4455
4456 * sem_ch8.adb (Analyze_Subprogram_Renaming): Complete support for
4457 renamings of formal subprograms when the actual for a formal type is
4458 class-wide.
4459
dfbf013f
MH
44602011-08-29 Matthew Heaney <heaney@adacore.com>
4461
4462 * a-cbhama.ads, a-cbhase.ads (Move): Clear Source following assignment
4463 to Target.
4464
44652011-08-29 Matthew Heaney <heaney@adacore.com>
4466
4467 * a-cborma.ads, a-cborse.ads (Cursor): Default-initialize all
4468 components of record type.
4469 * a-cborma.adb, a-cborse.adb (Move): Clear Source following assignmentw
4470 to Target.
4471
a6dd3a54
ES
44722011-08-29 Ed Schonberg <schonberg@adacore.com>
4473
4474 * a-cbhama.adb, a-cbhama.ads, a-cborma.adb, a-cborma.ads, a-cobove.adb,
4475 a-cobove.ads, a-coorma.adb, a-coorma.ads: Add iterator machinery to
4476 container packages.
4477
c54796e0
AC
44782011-08-29 Robert Dewar <dewar@adacore.com>
4479
4480 * sem_ch3.adb, sem_util.adb, gnat1drv.adb, s-parint.ads: Minor
4481 reformatting.
4482
44832011-08-29 Matthew Heaney <heaney@adacore.com>
4484
4485 * a-cbhama.ads, a-cbhase.ads (Cursor): Default-initialize all
4486 components of record type.
4487
44882011-08-29 Bob Duff <duff@adacore.com>
4489
4490 * s-tassta.adb (Task_Wrapper): Handle and ignore exceptions propagated
4491 by the termination handler.
4492
9fd9d2be
AC
44932011-08-29 Yannick Moy <moy@adacore.com>
4494
4495 * sem_ch3.adb (Array_Type_Declaration): Create declarations for Itypes
4496 created in Alfa mode, instead of inserting artificial declarations of
4497 non-Itypes in the tree.
4498 * sem_util.adb, sem_util.ads (Itype_Has_Declaration): New function to
4499 know if an Itype has a corresponding declaration, as defined in
4500 itypes.ads.
4501
45022011-08-29 Yannick Moy <moy@adacore.com>
4503
4504 * gnat1drv.adb: Minor rewrite.
4505
45062011-08-29 Bob Duff <duff@adacore.com>
4507
4508 * s-tasuti.adb (Make_Passive): Work around race condition in
4509 Make_Independent, which can cause Wait_Count to be zero. So instead of
4510 asserting that Wait_Count > 0, and then decrementing it, decrement it
4511 only if Wait_Count > 0.
4512 * s-taskin.ads (Wait_Count, Alive_Count, Awake_Count): All of these
4513 should be nonnegative, so declare them Natural instead of Integer.
4514
833eaa8a
AC
45152011-08-29 Robert Dewar <dewar@adacore.com>
4516
4517 * exp_ch5.adb, sem_ch3.adb, a-cihama.adb, a-cihama.ads, exp_ch7.adb,
4518 sem_ch5.adb, a-ciorse.adb, a-ciorse.ads, sem_ch12.adb, a-cidlli.adb,
4519 a-cidlli.ads, sem_util.adb, sem_res.adb, gnat1drv.adb, a-except.adb,
4520 a-except.ads, a-except-2005.ads, sem_ch4.adb, exp_disp.adb,
4521 exp_aggr.adb, sem_ch13.adb, par-ch3.adb: Minor reformatting.
4522
45232011-08-29 Tristan Gingold <gingold@adacore.com>
4524
4525 * s-auxdec-vms-alpha.adb: Add comments, remove some HT before labels.
4526
45272011-08-29 Vadim Godunko <godunko@adacore.com>
4528
4529 * s-parint.ads: Minor comment clarification.
4530
45312011-08-29 Vincent Celier <celier@adacore.com>
4532
4533 * prj.adb (Initialize): Make sure that new reserved words after Ada 95
4534 may be used as identifiers.
4535
45362011-08-29 Ed Schonberg <schonberg@adacore.com>
4537
4538 * a-coinho.ads: Minor reformating.
4539
3a613a36
AC
45402011-08-29 Ed Schonberg <schonberg@adacore.com>
4541
4542 * exp_ch5.adb (Expand_Iterator_Loop): Handle properly a loop over a
4543 container of a derived type.
4544
3a613a36
AC
45452011-08-29 Ed Schonberg <schonberg@adacore.com>
4546
4547 * a-cidlli.adb, a-cidlli.ads, a-cihama.adb, a-cihama.ads,
4548 a-ciorse.adb, a-ciorse.ads: Add iterator machinery to containers.
4549
14848f57
AC
45502011-08-29 Pascal Obry <obry@adacore.com>
4551
4552 * exp_disp.adb: Minor comment fix.
4553 (Make_Disp_Asynchronous_Select_Body): Properly initialize out parameters
4554 to avoid warnings when compiling with -Wall.
4555 (Make_Disp_Conditional_Select_Body): Likewise.
4556 (Make_Disp_Timed_Select_Body): Likewise.
4557
45582011-08-29 Ed Schonberg <schonberg@adacore.com>
4559
4560 * sem_ch12.adb (Analyze_Formal_Subprogram_Declaration): If default is
4561 an entity name, generate reference for it.
4562
45632011-08-29 Ed Schonberg <schonberg@adacore.com>
4564
4565 * exp_ch5.adb (Expand_Iterator_Loop): Uniform handling of "X of S"
4566 iterator form.
4567 * sem_util.adb (Is_Iterator, Is_Reversible_Iterator): Yield True for
4568 the class-wide type.
4569 * sem_ch5.adb: Move some rewriting to the expander, where it belongs.
4570
45712011-08-29 Ed Schonberg <schonberg@adacore.com>
4572
4573 * sem_ch8.adb (Check_Constrained_Object): Do not create an actual
4574 subtype for an object whose type is an unconstrained union.
4575
45762011-08-29 Ed Schonberg <schonberg@adacore.com>
4577
4578 * par-ch3.adb (P_Array_Type_Definiation, P_Component_Items): "aliased"
4579 is allowed in a component definition, by AI95-406.
4580
45812011-08-29 Matthew Heaney <heaney@adacore.com>
4582
4583 * a-chtgbo.adb (Generic_Iteration): Use correct overloading of Next.
4584
45852011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4586
4587 * a-except-2005.adb: Alphabetize all routines.
4588 (Triggered_By_Abort): New routine.
4589 * a-except-2005.ads (Triggered_By_Abort): New routine.
4590 * a-except.adb Alphabetize all routines.
4591 (Triggered_By_Abort): New routine.
4592 * a-except.ads (Triggered_By_Abort): New routine.
4593 * exp_ch7.adb: Update all comments involving the detection of aborts in
4594 finalization code.
4595 (Build_Object_Declarations): Do not generate code to detect the
4596 presence of an abort at the start of finalization code, use a runtime
4597 routine istead.
4598 * rtsfind.ads: Add RE_Triggered_By_Abort to tables RE_Id and
4599 RE_Unit_Table.
4600 * sem_res.adb (Resolve_Allocator): Emit a warning when attempting to
4601 allocate a task on a subpool.
4602 * s-stposu.adb: Add library-level flag Finalize_Address_Table_In_Use.
4603 The flag disables all actions related to the maintenance of
4604 Finalize_Address_Table when subpools are not in use.
4605 (Allocate_Any_Controlled): Signal the machinery that subpools are in
4606 use.
4607 (Deallocate_Any_Controlled): Do not call Delete_Finalize_Address which
4608 performs costly task locking when subpools are not in use.
4609
57a8057a
AC
46102011-08-29 Yannick Moy <moy@adacore.com>
4611
4612 * gnat1drv.adb (Adjust_Global_Switches): Restore expansion of tagged
4613 types and dispatching calls in Alfa mode.
4614 * lib-xref-alfa.adb (Collect_ALFA): Rewrite computation of
4615 correspondance between body and spec scopes, to reuse utility functions
4616 (Traverse_Declarations_Or_Statements): Protect access to body for stub
4617 by testing the presence of the library unit for the body
4618 * sem_ch6.adb (Set_Actual_Subtypes): take into account that in Alfa
4619 mode the expansion of accept statements is skipped
4620 * sem_util.adb, sem_util.ads (Unique_Entity): New function returning
4621 the unique entity corresponding to the one returned by
4622 Unique_Defining_Entity applied to the enclosing declaration of the
4623 argument.
4624
46252011-08-29 Bob Duff <duff@adacore.com>
4626
4627 * treepr.ads: Improve debugging facilities. pn(x) no longer crashes in
4628 gdb when x is not a node (it can be a node list, name_id, etc). pp is
4629 an alias for pn. ppp is an alias for pt.
4630
46312011-08-29 Javier Miranda <miranda@adacore.com>
4632
4633 * exp_aggr.adb (Expand_Record_Aggregate): Use the top-level enclosing
4634 aggregate to take a consistent decision on the need to convert into
4635 assignments aggregates that initialize constant objects.
4636
46372011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4638
4639 * exp_ch4.adb (Expand_Allocator_Expression): Add a call to
4640 Build_Allocate_Deallocate_Proc in order to handle allocation of
4641 non-controlled objects on subpools.
4642 * impunit.adb: Remove s-finmas and s-spsufi since they were never meant
4643 to be end-user visible.
4644 * s-finmas.adb: Add with and use clause for System.HTable.
4645 Add an instantiation of Simple_HTable which provides a mapping between
4646 the address of a controlled object and the corresponding
4647 Finalize_Address used to clean up the object. The table is used when a
4648 master is operating in heterogeneous mode.
4649 (Attach): Explain why the input node is not verified on being already
4650 attached.
4651 (Delete_Finalize_Address): New routine.
4652 (Detach): Add pragma Assert which ensures that a node is already
4653 attached.
4654 (Finalize): Add local variable Cleanup. Rewrite the iteration scheme
4655 since nodes are no longer removed on traversal. Explain why node
4656 detachment is undesirable in this case.
4657 (Get_Finalize_Address): New routine.
4658 (Hash): New routine.
4659 (Is_Empty_List): Removed.
4660 (pm): Renamed to Print_Master. Add output for discriminant
4661 Is_Homogeneous.
4662 Comment reformatting.
4663 (Set_Finalize_Address (Address, Finalize_Address_Ptr)): New routine.
4664 * s-finmas.ads: Various comments additions / improvements.
4665 Type Finalization_Master has a discriminant which determines the mode of
4666 operation.
4667 (Delete_Finalize_Address): New routine.
4668 (Get_Finalize_Address): New routine.
4669 (pm): Renamed to Print_Master.
4670 (Set_Finalize_Address (Address, Finalize_Address_Ptr)): New routine.
4671 * s-stposu.adb: Add with clause for System.Address_Image; Add with and
4672 use clause for System.IO.
4673 (Allocate_Any_Controlled): Add machinery to set TSS primitive
4674 Finalize_Address depending on the mode of allocation and the mode of
4675 the master.
4676 (Deallocate_Any_Controlled): Remove the relation pair object -
4677 Finalize_Address regardless of the master mode. Add comment explaining
4678 the reason.
4679 (Detach): Ensure that fields Prev and Next are null after detachment.
4680 (Finalize_Pool): Remove local variable Next_Ptr. Rewrite the iteration
4681 scheme to check whether the list of subpools is empty. There is no
4682 longer need to store the next subpool or advance the current pointer.
4683 (Is_Empty_List): New routine.
4684 (Print_Pool): New routine.
4685 (Print_Subpool): New routine.
4686 * s-stposu.ads: Various comments additions / improvements.
4687 Field Master of type Root_Subpool is now a heterogeneous collection.
4688 (Print_Pool): New routine.
4689 (Print_Subpool): New routine.
4690
46912011-08-29 Ed Schonberg <schonberg@adacore.com>
4692
4693 * exp_ch5.adb (Expand_N_Iterator_Loop): Implement Ada2012 loop iterator
4694 forms, using aspects of container types.
4695 * sem_ch3.adb (Find_Type_Name): Preserve Has_Delayed_Aspects and
4696 Has_Implicit_Dereference flags, that may be set on the partial view.
4697 * sem_ch4.adb (Process_Overloaded_Indexed_Component): Prefix may be a
4698 container type with an indexing aspect.
4699 (Analyze_Quantified_Expression): Analyze construct with expansion
4700 disabled, because it will be rewritten as a loop during expansion.
4701 (Try_Container_Indexing): The prefix itself may be a container type
4702 with an indexing aspect, as with a vector of vectors.
4703 * sem_ch5.adb (Analyze_Iteration_Scheme): In a generic context, analyze
4704 the original doamin of iteration, for name capture.
4705 (Analyze_Iterator_Specification): If the domain is an expression that
4706 needs finalization, create a separate declaration for it.
4707 For an iterator with "of" retrieve default iterator info from aspect of
4708 container type. For "in" iterator, retrieve type of Iterate function.
4709 * sem_ch13.adb (Check_Iterator_Function): Fix typo.
4710 (Check_Aspect_At_End_Of_Declaration): Make type unfrozen before
4711 analysis, to prevent spurious errors about late attributes.
4712 * sprint.adb: Handle quantified expression with either loop or iterator
4713 specification.
4714 * a-convec.ads, a-convec.adb: Iterate function returns a reversible
4715 iterator.
4716
ddf67a1d
AC
47172011-08-29 Vincent Celier <celier@adacore.com>
4718
4719 * make.adb (Scan_Make_Arg): Take any option as is in packages Compiler,
4720 Binder or Linker of the main project file.
4721
47222011-08-29 Ed Schonberg <schonberg@adacore.com>
4723
4724 * inline.adb (Add_Scopes_To_Clean): Exclude any entity within a generic
4725 unit.
4726
47272011-08-29 Yannick Moy <moy@adacore.com>
4728
4729 * exp_ch9.adb: Partial revert of previous change for Alfa mode
4730
47312011-08-29 Yannick Moy <moy@adacore.com>
4732
4733 * exp_ch11.adb: Minor expansion of comment.
4734
47352011-08-29 Yannick Moy <moy@adacore.com>
4736
4737 * lib-xref-alfa.adb (Add_ALFA_Scope): Treat generic entities.
4738
47392011-08-29 Ed Schonberg <schonberg@adacore.com>
4740
4741 * sem_res.adb (Resolve_Arithmetic_Op): If the node has a universal
4742 interpretation, set the type before resolving the operands, because
4743 legality checks on an exponention operand need to know the type of the
4744 context.
4745
47462011-08-29 Ed Schonberg <schonberg@adacore.com>
4747
4748 * sem_ch12.adb (Analyze_Package_Instantiation): Do not set delayed
4749 cleanups on a master if the instance is within a generic unit.
4750 Complement to the corresponding fix to inline.adb for K520-030.
4751
47522011-08-29 Tristan Gingold <gingold@adacore.com>
4753
4754 * exp_ch7.adb (Build_Raise_Statement): Raise PE instead of the current
4755 occurrence.
4756 * exp_intr.adb: Minor comment fix.
4757
47582011-08-29 Bob Duff <duff@adacore.com>
4759
4760 * sem_ch13.adb (Analyze_Aspect_Specifications): Fix cases where
4761 Delay_Required was used as an uninitialized variable.
4762
690943fc
RD
47632011-08-29 Robert Dewar <dewar@adacore.com>
4764
4765 * a-cdlili.adb, a-cdlili.ads, a-coinve.adb, a-coinve.ads,
4766 sem_util.adb, sem_util.ads, a-cohama.adb, a-cohama.ads, a-coorse.adb,
4767 a-coorse.ads, aspects.ads, sem_ch8.adb: Minor reformatting.
4768
9f0ee988
TQ
47692011-08-29 Thomas Quinot <quinot@adacore.com>
4770
4771 * system-freebsd-x86_64.ads (Backend_Overflow_Checks): Set true True.
4772 Remove unused variables.
4773
3e24afaa
AC
47742011-08-29 Ed Schonberg <schonberg@adacore.com>
4775
4776 * sem_res.adb: Remove Build_Explicit_Dereference.
4777 * sem_util.adb, sem_util.ads (Build_Explicit_Dereference): Moved here
4778 from sem_res.adb, used in analysis of additional constructs.
4779 (Is_Iterator, Is_Reversible_Iterator): New predicates for Ada2012
4780 expansion of iterators.
4781 (Is_Object_Reference): Recognize variables rewritten as explicit
4782 dereferences in Ada2012.
4783 * snames.ads-tmpl: Add Has_Element, Forward_Iterator,
4784 Reversible_Iterator names, for expansion of Ada2012 iterators.
4785 * aspects.ads, aspects.adb (Find_Aspect): Utility.
4786 * a-cdlili.ads, a-cdlili.adb: Add new iterator machinery to doubly
4787 linked list container.
4788 * a-coinve.ads, a-coinve.adb: Ditto for indefinite vector containers.
4789 * a-coorse.ads, a-coorse.adb: Ditto for ordered sets.
4790
47912011-08-29 Ed Schonberg <schonberg@adacore.com>
4792
4793 * a-cohama.adb, a-cohama.ads: Add iterator primitives to hashed map
4794 containers.
4795
47962011-08-29 Vincent Celier <celier@adacore.com>
4797
4798 * make.adb (Gnatmake): Get the maximum number of simultaneous
4799 compilation processes after the Builder switches has been scanned, as
4800 there may include -jnn.
4801
48022011-08-29 Matthew Heaney <heaney@adacore.com>
4803
4804 * a-chtgbo.adb (Generic_Equal): Use correct overloading of Next.
4805
48062011-08-29 Tristan Gingold <gingold@adacore.com>
4807
4808 * gnatcmd.adb (GNATCmd): On OpenVMS, truncate the length of
4809 GNAT_DRIVER_COMMAND_LINE to 255.
4810
48112011-08-29 Pascal Obry <obry@adacore.com>
4812
4813 * freeze.adb, sem_ch8.adb, a-convec.adb, a-convec.ads: Minor
4814 reformatting and style fix (class attribute casing).
4815
48162011-08-29 Yannick Moy <moy@adacore.com>
4817
4818 * exp_ch11.adb: Yet another case where expansion should be common
4819 between CodePeer and Alfa.
4820
48212011-08-29 Yannick Moy <moy@adacore.com>
4822
4823 * exp_ch9.adb: Partial revert of previous change for Alfa mode.
4824
48252011-08-29 Ed Schonberg <schonberg@adacore.com>
4826
4827 * sem_ch6.adb (Matches_Limited_With_View): The limited views of an
4828 incomplete type and its completion match.
4829
3ddd922e
AC
48302011-08-29 Yannick Moy <moy@adacore.com>
4831
4832 * exp_ch13.adb: Adjust previous change.
4833
48342011-08-29 Robert Dewar <dewar@adacore.com>
4835
4836 * sem_prag.adb, prj.adb, sem_util.adb, sem_res.adb, gnat1drv.adb,
4837 exp_ch4.adb, sem_ch8.adb: Minor code reorganization
4838 Minor reformatting.
4839
444acbdd
AC
48402011-08-29 Emmanuel Briot <briot@adacore.com>
4841
4842 * make.adb, prj.adb, prj.ads (Compute_All_Imported_Projects): Also
4843 initialize aggregated projects.
4844
48452011-08-29 Ed Schonberg <schonberg@adacore.com>
4846
4847 * sem_ch8.adb (Find_Renamed_Entity): Within an instance, use scope
4848 depth of candidates to resolve a potentially spurious ambiguity between
4849 two visible subprograms.
4850
e0296583
AC
48512011-08-29 Yannick Moy <moy@adacore.com>
4852
4853 * sem_prag.adb (Analyze_Pragma): Allow Test_Case pragma without
4854 Requires/Ensures.
4855 * sem_util.adb (Get_Ensures_From_Test_Case_Pragma,
4856 Get_Requires_From_Test_Case_Pragma): Allow Test_Case pragma without
4857 Requires/Ensures.
4858
48592011-08-29 Arnaud Charlet <charlet@adacore.com>
4860
4861 * gnat1drv.adb (Adjust_Global_Switches): Improve previous change.
4862 Add comment.
4863
48642011-08-29 Thomas Quinot <quinot@adacore.com>
4865
4866 * sem_res.adb: Minor reformatting.
4867
69794413
JK
48682011-08-29 Johannes Kanig <kanig@adacore.com>
4869
4870 * exp_ch4.adb (Expand_Quantified_Expression): Do not expand in ALFA
4871 mode.
4872 * gnat1drv.adb (Adjust_Global_Switches): Set
4873 Use_Expressions_With_Actions to False in ALFA mode.
4874 * sem_res.adb (Resolve_Quantified_Expression): Simpler treatment in
4875 ALFA mode.
4876
59e6b23c
AC
48772011-08-29 Yannick Moy <moy@adacore.com>
4878
4879 * exp_ch13.adb (Expand_N_Freeze_Entity): Do nothing in Alfa mode.
4880 * exp_ch9.adb: Do not expand tasking constructs in Alfa mode.
4881 * gnat1drv.adb (Adjust_Global_Switches): Suppress the expansion of
4882 tagged types and dispatching calls in Alfa mode.
4883
48842011-08-29 Javier Miranda <miranda@adacore.com>
4885
4886 * sem_ch3.adb (Process_Discriminants): Add missing check to ensure that
4887 we do not report an error on an Empty node.
4888
48892011-08-29 Geert Bosch <bosch@adacore.com>
4890
4891 * Makefile.rtl (GNATRTL_NONTASKING_OBJECTS): Add a-nllrar.o,
4892 a-nlrear.o and a-nurear.o.
4893
48942011-08-29 Robert Dewar <dewar@adacore.com>
4895
4896 * freeze.adb: Minor code reorganization.
4897 Minor reformatting.
4898 * sem_util.adb, errout.adb, exp_ch11.adb, a-ngrear.adb, s-gearop.adb,
4899 sem_ch6.adb: Minor reformatting
4900
49012011-08-29 Tristan Gingold <gingold@adacore.com>
4902
4903 * s-except.ads, s-except.adb: Provide dummy body.
4904
49052011-08-29 Yannick Moy <moy@adacore.com>
4906
4907 * sem_warn.adb (Within_Postcondition): Take into account the case of
4908 an Ensures component in a Test_Case.
4909
4d792549
AC
49102011-08-29 Tristan Gingold <gingold@adacore.com>
4911
4912 * s-excdeb.ads, s-excdeb.adb: New files, created from s-except.
4913 * rtsfind.ads (RTU_Id): Replaces System_Exceptions by
4914 System_Exceptions_Debug
4915 (RE_Unit_Table): Search RE_Local_Raise in System_Exceptions_Debug
4916 * a-except.adb: With and use System.Exceptions_Debug instead of
4917 System.Exceptions.
4918 * a-except-2005.adb: Likewise.
4919 * s-assert.adb: Likewise.
4920 * s-except.adb, s-except.ads: Move debugging hooks to s-excdeb.
4921 * Makefile.rtl: Add s-excdeb. Adjust compilation rule.
4922 * gcc-interfaces/Makefile.in, gcc-interface/Make-lang.in: Add
4923 s-excdeb. Update dependencies.
4924 (GNATRTL_LINEARALGEBRA_OBJS): Remove a-nlrear.o a-nurear.o a-nllrar.o
4925 as these no longer need external libraries.
4926
49272011-08-29 Ed Schonberg <schonberg@adacore.com>
4928
4929 * sem_res.adb (Resolve_Op_Expon): Additional check to reject an
4930 exponentiation operator on universal values in a context that requires
4931 a fixed-point type.
4932
49332011-08-29 Tristan Gingold <gingold@adacore.com>
4934
4935 * raise-gcc.c (personnality_routine): Fix thinko. Set Ada occurrence
4936 before calling notify_handled_exception.
4937 * a-exextr.adb: Fix comment.
4938
b254da66
AC
49392011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
4940
4941 * exp_ch4.adb (Expand_Allocator_Expression): Add code to set attribute
4942 Finalize_Address of the access type's finalization master.
4943 (Expand_N_Allocator): Add code to set attribute Finalize_Address of the
4944 access type's finalization master. Add a guard to prevent
4945 Associated_Storage_Pool from being set on .NET/JVM.
4946 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Add code to set
4947 attribute Finalize_Address of the access type's finalization master.
4948 * exp_ch7.adb (Make_Finalize_Address_Call): New routine.
4949 * exp_ch7.ads (Make_Finalize_Address_Call): New routine.
4950 * rtsfind.ads: Add RE_Set_Finalize_Address to tables RE_Id and
4951 RE_Unit_Table.
4952 * s-finmas.adb: Add with clause for System.Address_Image. Add with and
4953 use clause for System.IO
4954 (Detach): Relax the assertion, to be reinstated later.
4955 (Finalize): Rewrite the iteration loop to avoid pointer comparison.
4956 Relax the assertion on Finalize_Address, to be reinstated later.
4957 (Is_Empty_List): New routine.
4958 (pm): New debug routine.
4959 (Set_Finalize_Address): New routine.
4960 * s-finmas.ads (pm): New debug routine.
4961 (Set_Finalize_Address): New routine.
4962 * s-stposu.adb (Allocate_Any_Controlled): Code reformatting.
4963
49642011-08-29 Tristan Gingold <gingold@adacore.com>
4965
4966 * a-exexpr-gcc.adb (GCC_Exception_Access, GNAT_GCC_Exception_Access):
4967 Remove convention C.
4968
49692011-08-29 Tristan Gingold <gingold@adacore.com>
4970
4971 * s-taprop-vms.adb (Get_Exc_Stack_Addr): Remove.
4972 (Initialize_TCB): Remove Exc_Stack_Ptr initialization.
4973 (Finalize_TCB): Remove its finalization.
4974 (Initialize): Remove assignment of GET_Exc_Stack_Addr
4975 * s-soflin.adb (NT_Exc_Stack): Remove
4976 (Get_Exc_Stack_Addr_NT): Likewise.
4977 (Get_Exc_Stack_Addr_Soft): Likewise.
4978 * s-soflin.ads (Get_Exc_Stack_Addr_NT): Remove.
4979 (Get_Exc_Stack_Addr): Likewise.
4980 (Get_Exc_Stack_Addr_Soft): Likewise
4981 * s-taspri-vms.ads (Exc_Stack_T): Remove.
4982 (Exc_Stack_Ptr_T): Likewise.
4983 (Private_Data): Remove Exc_Stack_Ptr component.
4984
49852011-08-29 Tristan Gingold <gingold@adacore.com>
4986
4987 * raise-gcc.c (get_ip_from_context): New function. Factorize code.
4988
49892011-08-29 Tristan Gingold <gingold@adacore.com>
4990
4991 * gnat_ugn.texi: Fix aix and x86-solaris info for run-time.
4992
49932011-08-29 Geert Bosch <bosch@adacore.com>
4994
4995 * s-gearop.ads (Back_Substitute, Diagonal, Forward_Eliminate,
4996 L2_Norm, Swap_Column): New generic subprograms
4997 * s-gearop.adb (Back_Substitute, Diagonal, Forward_Eliminate,
4998 L2_Norm, Swap_Column): Implement new subprograms in order to
4999 eliminate dependency on BLAS and LAPACK libraries in
5000 Ada.Numerics.Generic_Real_Arrays and eventually also the complex
5001 version. Forward_Eliminate/Back_Substitute can be used to put a
5002 matrix in row echelon or reduced row echelon form using partial
5003 pivoting.
5004 * a-ngrear.adb: (Back_Substitute, Diagonal, Forward_Eleminate,
5005 Swap_Column): Instantiate from System.Generic_Array_Operations.
5006 ("*", "abs"): Implement by instantiation from Generic_Array_Operations.
5007 (Sqrt): Local function for simple computation of square root without
5008 adding dependencies on Generic_Elementary_Functions.
5009 (Swap): New subprogram to exchange floating point numbers.
5010 (Inverse): Reimplement using Jordan-Gauss elimination.
5011 (Jacobi): New procedure implementing Jacobi's method for computation
5012 of eigensystems, based on Rutishauser's implementation.
5013 (L2_Norm): Implement directly using the inner product.
5014 (Sort_Eigensystem): Sort eigenvalue/eigenvector pairs in order of
5015 decreasing eigenvalue as required by the Ada RM.
5016 (Swap_Column): New helper procedure for Sort_Eigensystem.
5017 Remove with of System.Generic_Real_BLAS and System.Generic_Real_LAPACK.
5018 Add with of Ada.Containers.Generic_Anonymous_Array_Sort, for
5019 Sort_Eigensystems.
5020
50212011-08-29 Thomas Quinot <quinot@adacore.com>
5022
5023 * put_scos.adb (Put_SCOs): Do not emit a newline for an empty
5024 statements line.
5025
60370fb1
AC
50262011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5027
5028 * s-finmas.adb (Finalize): Check Finalize_Address of the master rather
5029 than the current node.
5030 * s-finmas.ads: Move field Finalize_Address from type FM_Node to
5031 Finalization_Master. The list headers have two fields instead of three.
5032 This should fix alignment issue but subpool allocations are now
5033 unusable. Alphabetize subprograms.
5034 * s-stposu.adb (Allocate_Any_Controlled): Use the offset rather than
5035 the size of the header when converting the beginning of the object to
5036 a FM_Node. Set the master's Finalize_Address attribute if not already
5037 set.
5038 (Deallocate_Any_Controlled): Use the offset rather than the size of the
5039 header when converting the beginning of the object to a FM_Node.
5040
50412011-08-29 Gary Dismukes <dismukes@adacore.com>
5042
5043 * exp_ch11.adb (Expand_N_Raise_Statement): Don't suppress expansion of
5044 reraise when compiling for CodePeer.
5045
50462011-08-29 Arnaud Charlet <charlet@adacore.com>
5047
5048 * a-iteint.ads, Makefile.rtl: Add missing compilation of a-iteint.ads,
5049 now needed by a-convec.adb. Fix warning.
5050
50512011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5052
5053 * exp_util.adb (Build_Allocate_Deallocate_Proc): Add a guard for the
5054 processing of TSS routine Finalize_Address when compiling in
5055 CodePeer_Mode.
5056
50572011-08-29 Thomas Quinot <quinot@adacore.com>
5058
5059 * a-strunb.ads, einfo.ads, g-comlin.ads, sem_ch6.adb,
5060 sem_warn.adb: Minor reformatting.
5061
50622011-08-29 Emmanuel Briot <briot@adacore.com>
5063
5064 * prj-conf.adb (Get_Config_Switches): Also collect the list of
5065 languages from aggregated projects.
5066
50672011-08-29 Yannick Moy <moy@adacore.com>
5068
5069 * lib-xref-alfa.adb, lib-xref.ads (Traverse_Declarations_Or_Statements,
5070 Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
5071 Traverse_Package_Declaration, Traverse_Subprogram_Body,
5072 Traverse_Compilation_Unit): Add a parameter Inside_Stubs so that bodies
5073 for stubs are traversed too when parameter is set
5074 (Traverse_All_Compilation_Units): Traverse without going inside stubs
5075 (Traverse_Declarations_Or_Statements): Do the special traversing for
5076 stubs when required.
5077 * sem_util.adb, sem_util.ads (Get_Body_From_Stub): New function to
5078 return subprogram or package body from stub.
5079 (Is_Subprogram_Stub_Without_Prior_Declaration): New function to detect
5080 stubs without prior subprogram decl.
5081
50822011-08-29 Vasiliy Fofanov <fofanov@adacore.com>
5083
5084 * gnat_ugn.texi: Fix typo.
5085
e9c9d122
HK
50862011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5087
5088 * s-stposu.adb (Allocate_Any_Controlled): Reimplement the mechanism
5089 which accounts for size vs alignment issues and calculates the size of
5090 the list header.
5091 (Deallocate_Any_Controlled): Ditto.
5092 (Nearest_Multiple_Rounded_Up): New routine.
5093
25ebc085
AC
50942011-08-29 Tristan Gingold <gingold@adacore.com>
5095
5096 * a-exstat.adb (String_To_EO): Do no set Cleanup_Flag.
5097 * a-exexda.adb (Set_Exception_C_Msg): Ditto.
5098 (Set_Exception_Msg): Ditto.
5099 * a-exexpr-gcc.adb (Setup_Current_Excep): Ditto. Do not set
5100 Private_Data.
5101 * a-except.adb, a-except-2005.adb (Save_Occurrence_No_Private): Remove.
5102 Use Save_Occurrence instead of Save_Occurrence_No_Private.
5103 (Raise_With_Msg): Remove Cleanup_Flag.
5104 * a-except.ads, a-except-2005.ads (Exception_Occurrence): Remove
5105 Clean_Flag and Private_Data components.
5106
51072011-08-29 Yannick Moy <moy@adacore.com>
5108
5109 * freeze.adb (Freeze_Record_Type): Ignore packing in Alfa mode, like
5110 in CodePeer mode.
5111 * sem_ch3.adb (Signed_Integer_Type_Declaration): Correct the generation
5112 of an explicitly declared type, so that the base types of the original
5113 type and this generated type are the same, and a "type" (not a subtype
5114 like previously).
5115 * errout.adb (Special_Msg_Delete): Do not issue messages "Size too
5116 small" in Alfa mode, like in CodePeer mode.
5117 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore rep
5118 clauses in Alfa mode.
5119
51202011-08-29 Javier Miranda <miranda@adacore.com>
5121
5122 * exp_ch6.ads, exp_ch6.adb (Is_Null_Procedure): Move the spec of this
5123 function to the package spec.
5124 * sem_ch6.adb (Find_Corresponding_Spec, New_Overloaded_Entity): For
5125 internally generated bodies of null procedures locate the internally
5126 generated spec enforcing mode conformance.
5127 (Is_Interface_Conformant): Ensure that the controlling formal of the
5128 primitives match.
5129
51302011-08-29 Ed Schonberg <schonberg@adacore.com>
5131
5132 * sem_prag.adb (Analyze_Pragma, case Inline): In an instance, do not
5133 reject the pragma if it appears to apply to a formal subprogram.
5134
51352011-08-29 Ed Schonberg <schonberg@adacore.com>
5136
5137 * exp_ch4.adb (Expand_Allocator_Expression): Use consistent name for
5138 inner expression, to prevent double evaluation.
5139
590549fb
AC
51402011-08-29 Tristan Gingold <gingold@adacore.com>
5141
5142 * a-exexpr.adb (Propagate_Exception): Remove all the parameters as
5143 they were unused.
5144 * a-exexpr-gcc.adb (Propagate_Exception): Ditto.
5145 * a-except-2005.adb (Propagate_Exception): Adjust spec.
5146 (Raise_Current_Excep): Adjust call.
5147 (Raise_From_Signal_Handler): Call now simply call Raise_Current_Excep.
5148
51492011-08-29 Thomas Quinot <quinot@adacore.com>
5150
5151 * exp_disp.adb: Minor reformatting.
5152
62380e66
TG
51532011-08-29 Tristan Gingold <gingold@adacore.com>
5154
5155 * a-exexpr.adb (Setup_Exception): Removed.
5156 * a-exexpr-gcc.adb (Setup_Exception): Removed.
5157 * a-except.adb (Exception_Propagation): Removed.
5158 * a-except-2005.adb (Setup_Exception): Removed.
5159 (Reraise): Remove call to Setup_Exception.
5160 (Reraise_Occurrence): Ditto.
5161 (Reraise_Occurrence_Always): Ditto.
5162 (Reraise_Occurrence_No_Defer): Ditto.
5163 (Transfer_Occurrence): Ditto.
5164 * a-exexda.adb (Set_Exception_C_Msg): Remove call to Setup_Exception.
5165 (Set_Exception_Msg): Ditto.
5166
c95aa61c
AC
51672011-08-29 Robert Dewar <dewar@adacore.com>
5168
5169 * a-convec.adb, exp_disp.adb: Minor reformatting.
5170
51712011-08-29 Tristan Gingold <gingold@adacore.com>
5172
5173 * a-exexpr-gcc.adb (GNAT_GCC_Exception_Access): Set to convention C.
5174
624e1688
AC
51752011-08-29 Gary Dismukes <dismukes@adacore.com>
5176
5177 * exp_ch3.adb (Build_Record_Init_Proc.Build_Init_Procedure): Set
5178 Exception_Handlers to No_List instead of Empty_List in the case where
5179 there are no handlers.
5180
51812011-08-29 Tristan Gingold <gingold@adacore.com>
5182
5183 * gcc-interface/gigi.h (enum standard_datatypes): Add
5184 ADT_reraise_zcx_decl
5185 (reraise_zcx_decl): New macro.
5186 * gcc-interface/trans.c (gnu_incoming_exc_ptr): New variable.
5187 (gigi): Set reraise_zcx_decl.
5188 (Exception_Handler_to_gnu_zcx): Save and restore gnu_incoming_exc_ptr.
5189 (gnat_to_gnu): Handle N_Raise_Statement.
5190
7134062a
AC
51912011-08-29 Robert Dewar <dewar@adacore.com>
5192
5193 * sem_ch6.adb, exp_ch3.adb, s-stposu.adb, a-undesu.ads,
5194 a-undesu.adb: Minor reformatting.
5195
51962011-08-29 Ed Schonberg <schonberg@adacore.com>
5197
5198 * exp_disp.adb (Check_Premature_Freezing): When building a dispatch
5199 table, accept an unfrozen untagged component if it is an actual for a
5200 formal incomplete type.
5201 * a-convec.ads, a-convec.adb: Instantiate Ada.Iterator_Interfaces to
5202 provide new iterator forms over vectors.
5203 Introduce type Iterator in package body to implement operations of
5204 Reversible_Iterator interface.
5205 * a-iteint.ads: Make package pure so it is usable with new container
5206 packages, that are categorized Remote_Types.
5207
ca5af305
AC
52082011-08-29 Robert Dewar <dewar@adacore.com>
5209
5210 * a-exexpr-gcc.adb, a-synbar.adb, sem_ch13.adb: Minor reformatting.
5211
52122011-08-29 Bob Duff <duff@adacore.com>
5213
5214 * sem_aggr.adb (Resolve_Aggr_Expr): Call this routine even in the case
5215 of <>, because this is the routine that checks for dimensionality
5216 errors (for example, for a two-dimensional array, (others => <>) should
5217 be (others => (others => <>)).
5218
52192011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5220
5221 * impunit.adb: Add new run-time units.
5222 * freeze.adb, exp_ch7.ads, exp_ch7.adb, exp_util.ads, exp_util.adb,
5223 s-stposu.ads, s-stposu.adb: Code clean up.
5224 Handle protected class-wide or task class-wide types
5225 Handle C/C++/CIL/Java types.
5226 * s-spsufi.adb, s-spsufi.ads: New files.
5227
5accd7b6
AC
52282011-08-29 Yannick Moy <moy@adacore.com>
5229
5230 * sem_ch13.adb (Analyze_Aspect_Specifications): Reject test-case on
5231 library-level subprogram.
5232 * sem_prag.adb (Check_Test_Case): Stricter rules for test-case
5233 placement.
5234 (Analyze_Pragma): Change name "Normal" for "Nominal" in test-case
5235 component.
5236 * snames.ads-tmpl: Change name "Normal" for "Nominal" in test-case
5237 component.
5238 * gnat_rm.texi: Update doc for Test_Case pragma.
5239
52402011-08-29 Tristan Gingold <gingold@adacore.com>
5241
5242 * a-exexpr-gcc.adb (Unwind_Exception): Remove default value, made it
5243 convention C.
5244 (GCC_Exception_Access): New type.
5245 (Unwind_DeleteException): New imported procedure
5246 (Foreign_Exception): Import it.
5247 (GNAT_GCC_Exception): Simply have the occurrence inside.
5248 (To_GCC_Exception): New function.
5249 (To_GNAT_GCC_Exception): New function.
5250 (GNAT_GCC_Exception_Cleanup): New procedure..
5251 (Propagate_GCC_Exception): New procedure.
5252 (Reraise_GCC_Exception): New procedure.
5253 (Setup_Current_Excep): New procedure.
5254 (CleanupUnwind_Handler): Change type of UW_Exception parameter.
5255 (Unwind_RaiseException): Ditto.
5256 (Unwind_ForcedUnwind): Ditto.
5257 (Remove): Removed.
5258 (Begin_Handler): Change type of parameter.
5259 (End_Handler): Ditto. Now delete the exception if still present.
5260 (Setup_Key): Removed.
5261 (Is_Setup_And_Not_Propagated): Removed.
5262 (Set_Setup_And_Not_Propagated): Ditto.
5263 (Clear_Setup_And_Not_Propagated): Ditto.
5264 (Save_Occurrence_And_Private): Ditto.
5265 (EID_For): Add 'not null' constraint on parameter.
5266 (Setup_Exception): Does nothing.
5267 (Propagate_Exception): Simplified.
5268 * exp_ch11.adb (Expand_N_Raise_Statement): In back-end exception model,
5269 re-raise is not expanded anymore.
5270 * s-except.ads (Foreign_Exception): New exception - placeholder for
5271 non Ada exceptions.
5272 * raise-gcc.c (__gnat_setup_current_excep): Declare
5273 (CXX_EXCEPTION_CLASS): Define (not yet used)
5274 (GNAT_EXCEPTION_CLASS): Define.
5275 (is_handled_by): Handle foreign exceptions.
5276 (PERSONALITY_FUNCTION): Call __gnat_setup_current_excep.
5277
52782011-08-29 Jose Ruiz <ruiz@adacore.com>
5279
5280 * a-synbar.adb (Synchronous_Barrier): Some additional clarification.
5281
2ef48385
AC
52822011-08-29 Thomas Quinot <quinot@adacore.com>
5283
5284 * a-synbar-posix.adb: Minor reformatting.
5285
52862011-08-29 Jose Ruiz <ruiz@adacore.com>
5287
5288 * a-exetim-posix.adb, a-exetim-mingw.adb, a-exetim-mingw.ads,
5289 a-exetim-default.ads (Interrupt_Clocks_Supported,
5290 Separate_Interrupt_Clocks_Supported, Clock_For_Interrupts): Add these
5291 definitions to be compliant with AI-0171. The target systems do not
5292 support separate account for the execution time of interrupt handlers.
5293
52942011-08-29 Jose Ruiz <ruiz@adacore.com>
5295
5296 * a-synbar.adb (Wait): Change the order of evaluation of the conditions
5297 in the barrier to put first the easiest to evaluate (and the one which
5298 will be True more often). More efficient.
5299
53002011-08-29 Eric Botcazou <ebotcazou@adacore.com>
5301
5302 * s-atocou-x86.adb: Fix constraint in machine code insertion.
5303
53042011-08-29 Bob Duff <duff@adacore.com>
5305
5306 * aspects.ads, aspects.adb: Add new aspects for various pragmas and
5307 attributes that are now aspects, as specified by AI05-0229-1.
5308 * sem_ch13.adb (Analyze_Aspect_Specifications,
5309 Check_Aspect_At_Freeze_Point): Analyze the new aspects. Turn them into
5310 pragmas or attribute references, as appropriate.
5311
0db16b1e
AC
53122011-08-29 Robert Dewar <dewar@adacore.com>
5313
5314 * a-synbar.ads, a-synbar.adb, a-synbar-posix.adb,
5315 a-synbar-posix.ads: Minor reformatting.
5316
53172011-08-29 Yannick Moy <moy@adacore.com>
5318
5319 * snames.ads-tmpl: Add name Force.
5320
978ffe02
AC
53212011-08-29 Pascal Obry <obry@adacore.com>
5322
5323 * prj-nmsc.adb: Minor reformatting.
5324
53252011-08-29 Jose Ruiz <ruiz@adacore.com>
5326
5327 * a-exetim.ads (Interrupt_Clocks_Supported,
5328 Separate_Interrupt_Clocks_Supported, Clock_For_Interrupts): Add these
5329 definitions to be compliant with AI-0171.
5330
53312011-08-29 Robert Dewar <dewar@adacore.com>
5332
5333 * a-ngelfu.adb: Add comments.
5334
718f39dc
AC
53352011-08-29 Geert Bosch <bosch@adacore.com>
5336
5337 * a-ngelfu.adb (Tan): Do not raise Constraint_Error if the argument is
5338 the closest machine number to Pi / 2.0.
5339
53402011-08-29 Jose Ruiz <ruiz@adacore.com>
5341
5342 * impunit.adb (Non_Imp_File_Names_12): Add a-synbar for new Ada 2012
5343 package Ada.Synchronous_Barriers.
5344 * a-synbar.ads, a-synbar.adb, a-synbar-posix.ads, a-synbar-posix.adb:
5345 Add new specs and bodies for Ada.Synchronous_Barriers. There is a
5346 default implementation using protected objects and another one
5347 a-synbar-posix using POSIX barriers as the underlying support.
5348 * gcc-interface/Makefile.in (LIBGNAT_TARGET_PAIRS for Linux (x86,
5349 x86_64, ia64) and MIPS IRIX): Use the a-synbar-posix implementation of
5350 Ada.Synchronous_Barriers which uses POSIX barriers (more efficient).
5351 Clean up dependencies.
5352 * Makefile.rtl (GNATRTL_TASKING_OBJS): Add a-synbar.o
5353
ee2e3f6b
AC
53542011-08-29 Robert Dewar <dewar@adacore.com>
5355
5356 * sem_ch7.adb, make.adb, sem_res.adb, exp_intr.adb,
5357 exp_dist.adb: Minor code reorganization.
5358 Minor reformatting.
5359
53602011-08-29 Thomas Quinot <quinot@adacore.com>
5361
5362 * sem_cat.adb (Validate_RACW_Primitive): The return type of an RACW
5363 primitive operation must support external streaming if it is not a
5364 controlling access result.
5365
646e2823
AC
53662011-08-29 Thomas Quinot <quinot@adacore.com>
5367
5368 * sinfo.ads, sem_ch7.adb: Minor reformatting.
5369
53702011-08-29 Bob Duff <duff@adacore.com>
5371
5372 * sem_ch4.adb (Analyze_Allocator): Check No_Nested_Finalization
5373 restriction on allocators, as required by AI05-0013-1.
5374 * restrict.ads: Minor comment fix.
5375
5d59eef2
AC
53762011-08-29 Tristan Gingold <gingold@adacore.com>
5377
5378 * a-exexpr.adb, a-except-2005.ads (Jmpbuf_Address): Move to a-exexpr.adb
5379 (To_Jmpbuf_Address): Ditto
5380 (builtin_longjmp): Ditto
5381
53822011-08-29 Thomas Quinot <quinot@adacore.com>
5383
5384 * sem_res.adb: Minor reformatting.
5385
53862011-08-29 Vincent Celier <celier@adacore.com>
5387
5388 * make.adb (Gnatmake): Move special processing for VM targets after the
5389 call to Get_Target_Parameters.
5390
53912011-08-29 Thomas Quinot <quinot@adacore.com>
5392
5393 * sem_ch12.adb, par-ch12.adb: Minor reformatting.
5394
949a18cc
AC
53952011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5396
5397 * sem_res.adb (Resolve_Allocator): Implement Ada2012-B052. Detect cases
5398 where an anonymous access discriminant of a limited designated type
5399 appears in a non-immutably limited discriminated type and issue an
5400 error message. Add local variable Desig_T and replace all occurrences
5401 of Designated_Type.
5402
54032011-08-29 Jose Ruiz <ruiz@adacore.com>
5404
5405 * a-rttiev.adb (Set_Handler): Update comment to indicate that our
5406 implementation is compliant to RM D.15(15/2) after the modification
5407 imposed by AI05-0094-1 (binding interpretation).
5408
cb25faf8
AC
54092011-08-29 Robert Dewar <dewar@adacore.com>
5410
5411 * exp_ch9.adb, s-tasren.adb, exp_sel.adb, exp_sel.ads, exp_ch11.adb,
5412 s-interr-hwint.adb, s-tpobop.adb, sem_ch13.adb: Minor reformatting.
5413
54142011-08-29 Thomas Quinot <quinot@adacore.com>
5415
5416 * par-endh.adb (Check_End): For an END where it is mandatory to repeat
5417 the scope name, do not report a missing label as a style violation (it
5418 will be diagnosed as an illegality).
5419 * exp_dist.adb (Add_Params_For_Variant_Components): Fix handling of
5420 variant records: Get_Enum_Lit_From_Pos already returns a usage
5421 occurrence of the literal, no need to use New_Occurrence_Of. Set Etype
5422 on Expr in Integer_Literal case so that it can be used by
5423 Build_To_Any_Call.
5424
1d10f669
AC
54252011-08-29 Tristan Gingold <gingold@adacore.com>
5426
5427 * exp_sel.ads (Build_Abort_BLock_Handler): New function spec.
5428 Adjust comment.
5429 * exp_sel.adb (Build_Abort_Block): Use Build_Abort_Block_Handler.
5430 (Build_Abort_Block_Handler): New function to build an Abort_Signal
5431 exception handler.
5432 * exp_ch9.adb (Expand_N_Asynchronous_Select): Call
5433 Build_Abort_Block_Handler to build the exception handler. Do not
5434 undefer aborts for the Abort_Signal exception handler if back-end
5435 exception mechanism.
5436 * exp_ch11.adb (Expand_Exception_Handlers): Do not undefer aborts if
5437 back_end exceptions for all others and abort_signal.
5438 * s-except.ads (ZCX_By_Default): New constant.
5439 * a-except-2005.adb (Raise_Exception): Do not defer abort if ZCX.
5440 (Raise_Exception_Always): Ditto.
5441 (Raise_From_Signal_Handler): Ditto.
5442 (Raise_With_Location_And_Msg): Ditto.
5443 (Raise_With_Msg): Ditto.
5444 (Reraise): Ditto.
5445 (Reraise_Occurence): Ditto.
5446 (Reraise_Occurrence_Always): Ditto.
5447 * s-tasren.adb (Exceptional_Complete_Rendezvous): Defer aborts if ZCX.
5448 * s-tpobop.adb: (Exceptional_Complete_Body): Undefer abort if ZCX.
1d10f669
AC
5449
54502011-08-29 Thomas Quinot <quinot@adacore.com>
5451
5452 * sem_util.ads (Get_Enum_Lit_From_Pos): Clarify documentation.
5453
d986066d
AC
54542011-08-29 Robert Dewar <dewar@adacore.com>
5455
5456 * snames.adb-tmpl, sem_ch13.adb: Minor reformatting
5457 Minor code reorganization.
5458
54592011-08-29 Bob Duff <duff@adacore.com>
5460
5461 * usage.adb (-gnatwy): Fix documentation: this switch applies to Ada
5462 2012, not just Ada 2005.
5463
54642011-08-29 Vincent Celier <celier@adacore.com>
5465
5466 * gnat_ugn.texi: Indicate that when the compiler is called by gnatmake
5467 with a project file or with gprbuid, if -gnatep= is specified, the
5468 builder may need to be invoked with -x.
5469
54702011-08-29 Tristan Gingold <gingold@adacore.com>
5471
5472 * a-exexpr-gcc.adb: Minor comment fix.
5473
ff4f0ed0
AC
54742011-08-29 Robert Dewar <dewar@adacore.com>
5475
5476 * sem_ch8.adb: Minor reformatting.
5477
54782011-08-29 Bob Duff <duff@adacore.com>
5479
5480 * par-ch2.adb (P_Identifier): Warn that "some" is reserved in Ada 2012.
5481 * par-ch4.adb (P_Quantified_Expression): Remove unnecessary code for
5482 treating "some" as unreserved in earlier Ada versions. This is now
5483 handled in Snames.Is_Keyword_Name. Parse "for some" using Tok_Some,
5484 rather than Name_Some, since Tok_Some is now recognized as reserved.
5485 * scans.adb (Initialize_Ada_Keywords): Handle Tok_Some like any other
5486 reserved word.
5487 * scans.ads: Minor comment fixes.
5488 * snames.adb-tmpl (Is_Keyword_Name): Handle Ada 2012 reserved words as
5489 for other language versions.
5490 * scn.adb (Scan_Reserved_Identifier): Remove unnecessary code for
5491 treating "some" as unreserved in earlier Ada versions. This is now
5492 handled in Snames.Is_Keyword_Name.
5493 * par-ch3.adb (P_Defining_Identifier): Warn that "some" is reserved in
5494 Ada 2012.
5495 (P_Subtype_Mark_Resync): Remove unnecessary code for treating "some" as
5496 unreserved in earlier Ada versions. This is now handled in
5497 Snames.Is_Keyword_Name.
5498 * snames.ads-tmpl (Ada_2012_Reserved_Words): Handle Ada 2012 reserved
5499 words as for other language versions.
5500 * gnat_ugn.texi (-gnatwy): Fix documentation: this switch applies to
5501 Ada 2012, not just Ada 2005.
5502
d941cee6
AC
55032011-08-29 Ed Schonberg <schonberg@adacore.com>
5504
5505 * sem_ch13.adb: Additional semantic checks for aspects involved in
5506 iterators.
5507
55082011-08-29 Matthew Heaney <heaney@adacore.com>
5509
5510 * a-comutr.ads, a-comutr.adb, a-cimutr.ads, a-cimutr.adb,
5511 a-cbmutr.ads, a-cbmutr.adb (Find_In_Subtree): Remove superfluous
5512 Container parameter.
5513 (Ancestor_Find): ditto.
5514
b970af39
TQ
55152011-08-29 Thomas Quinot <quinot@adacore.com>
5516
5517 * par-endh.adb: Minor reformatting.
d941cee6 5518
92db5dee
AC
55192011-08-29 Tristan Gingold <gingold@adacore.com>
5520
5521 * a-exexpr-gcc.adb (Unwind_Action) Rewrite as an integer with constants.
5522 (GNAT_GCC_Exception): Remove N_Cleanups_To_Trigger component.
5523 (Adjust_N_CLeanups_For): Remove.
5524 (CleanupUnwind_Handler): Call Unhandled_Exception_Terminate when end of
5525 stack is reached.
5526 (Propgate_Exception): Adjust.
5527 * raise-gcc.c: Add a few static/const.
5528 (Adjust_N_Cleanups_For): Remove declaration.
5529 (PERSONALITY_FUNCTION): Remove code dealing with N_Cleanups_To_Trigger.
5530
55312011-08-29 Ed Schonberg <schonberg@adacore.com>
5532
5533 * sem_ch8.adb: Use type of function return when rewriting as object
5534 declaration.
5535
1378bf10
AC
55362011-08-29 Gary Dismukes <dismukes@adacore.com>
5537
5538 * sem_type.adb: Minor reformatting.
5539
55402011-08-29 Robert Dewar <dewar@adacore.com>
5541
5542 * makeutl.adb: Minor reformatting.
5543
55442011-08-29 Ed Schonberg <schonberg@adacore.com>
5545
5546 * sem_ch8.adb (Analyze_Object_Renaming): If the renamed object is a
5547 function call of a limited type, the expansion of the renaming is
5548 complicated by the presence of various temporaries and subtypes that
5549 capture constraints of the renamed object.
5550 Rewrite node as an object declaration, whose expansion is simpler.
5551 Given that the object is limited there is no copy involved and no
5552 performance hit.
5553
164e06c6
AC
55542011-08-29 Robert Dewar <dewar@adacore.com>
5555
5556 * exp_ch5.adb, sinfo.ads, make.adb, s-pooglo.adb, sem_ch12.adb,
5557 freeze.adb, sem_ch6.adb, par-ch12.adb: Minor reformatting.
5558
55592011-08-29 Tristan Gingold <gingold@adacore.com>
5560
5561 * system-darwin-x86.ads, system-linux-s390x.ads, system-linux-alpha.ads,
5562 system-tru64.ads, system-irix-n32.ads, system-vxworks-arm.ads,
5563 system-linux-hppa.ads, system-linux-s390.ads,
5564 system-solaris-sparcv9.ads, system-mingw.ads, system-linux-ia64.ads,
5565 system-vms_64.ads, system-vxworks-sparcv9.ads, system-linux-ppc.ads,
5566 system-aix64.ads, system-lynxos-ppc.ads, system-linux-sh4.ads,
5567 system-solaris-x86.ads, system-linux-x86_64.ads, system-linux-x86.ads,
5568 system-vxworks-ppc.ads, system-hpux.ads, system-darwin-ppc.ads,
5569 system-solaris-sparc.ads, system-lynxos-x86.ads,
5570 system-vxworks-m68k.ads, system-hpux-ia64.ads, system-irix-o32.ads,
5571 system-solaris-x86_64.ads, system-mingw-x86_64.ads,
5572 system-vxworks-mips.ads, system-linux-sparc.ads, system-vms-ia64.ads,
5573 system-freebsd-x86.ads, system-aix.ads, system-darwin-x86_64.ads,
7d266442 5574 system-vxworks-x86.ads: Remove GCC_ZCX_Support.
164e06c6
AC
5575 * s-taprop-posix.adb, s-taprop-irix.adb, s-taprop-vxworks.adb,
5576 s-taprop-tru64.adb, s-taprop-linux.adb, s-taprop-solaris.adb: Ditto.
5577 * opt.ads: Adjust comment.
5578 * targparm.ads, targparm.adb: Remove GCC_ZCX_Support_On_Target.
5579 * gnat1drv.adb: Do not check for GCC_ZCX_Support_On_Target.
5580 * system.ads: Move GCC_ZCX_Support to obsolete entries.
5581
55822011-08-29 Emmanuel Briot <briot@adacore.com>
5583
5584 * makeutl.adb (Do_Complete): Resolve symbolic links when a relative
5585 file name is specified on the gnatmake or gprbuild command line, and
5586 before we search for that file in the project.
5587
55882011-08-29 Ed Schonberg <schonberg@adacore.com>
5589
5590 * sem_type.adb (Within_Instance): New predicate in Collect_Interps,
5591 used to determine whether a possible interpretation for an overloadable
5592 entity is declared within the current instantiation and should be
5593 included in the candidate set.
5594
55952011-08-29 Vasiliy Fofanov <fofanov@adacore.com>
5596
5597 * gnat_rm.texi, gnat_ugn.texi: Clean ups.
5598
97216ca8
ES
55992011-08-29 Ed Schonberg <schonberg@adacore.com>
5600
5601 * sem_res.adb (Resolve_Actuals): Use base type to determine whether an
5602 access subtype is access_to_subprogram, when applying checks for
5603 RM 3.10.2 (27).
5604
d3cb4cc0
AC
56052011-08-29 Matthew Heaney <heaney@adacore.com>
5606
5607 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Splice_Subtree): Only check
5608 for sibling when common parent.
5609
56102011-08-29 Thomas Quinot <quinot@adacore.com>
5611
5612 * get_scos.adb: Literals of Pragma_Id are pragma names prefixed with
5613 "pragma_".
5614
56152011-08-29 Ed Schonberg <schonberg@adacore.com>
5616
5617 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Enable freeze actions
5618 for the return type when in ASIS mode.
5619
56202011-08-29 Vincent Celier <celier@adacore.com>
5621
5622 * make.adb (Gnatmake): Get the default search dirs, then the target
5623 parameters after getting the Builder switches, as the Builder switches
5624 may include --RTS= and that could change the default search dirs.
5625
56262011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5627
5628 * exp_ch7.adb (Make_Adjust_Call): Rewrite to mimic the structure of
5629 Make_Final_Call. Move the processing for class-wide types before the
5630 processing for derivations from [Limited_]Controlled.
5631 (Make_Final_Call): Move the processing for class-wide types before the
5632 processing for derivations from [Limited_]Controlled.
5633 * s-stposu.adb (Allocate_Any_Controlled): Correct the membership check.
5634 Add code to account for alignments larger than the list header. Add a
5635 comment illustrating the structure of the allocated object + padding +
5636 header.
5637 (Deallocate_Any_Controlled): Add code to account for alignments larger
5638 than the list header.
5639
56402011-08-29 Ed Schonberg <schonberg@adacore.com>
5641
5642 * sinfo.ads, sinfo.adb: New node kind
5643 N_Formal_Incomplete_Type_Definition, related flags.
5644 par-ch12.adb (P_Formal_Type_Declaration, G_Formal_Type_Definition):
5645 Parse formal incomplete types.
5646 * sem.adb (Analyze): Formal_Incomplete_Type_Definitions are handled in
5647 sem_ch12.
5648 * sem_ch7.adb (Analyze_Package_Specification, Unit_Requires_Body):
5649 Formal incomplete types do not need completion.
5650 * sem_ch12.adb (Analyze_Formal_Incomplete_Type,
5651 Validate_Incomplete_Type_Instance): New procedures to handle formal
5652 incomplete types.
5653 * freeze.adb (Freeze_Entity): Do not freeze the subtype of an actual
5654 that corresponds to a formal incomplete type.
5655 * sprint.adb: Handle formal incomplete type declarations.
5656 * exp_util.adb (Insert_Actions): An incomplete_type_definition is not
5657 an insertion point.
5658
d3f70b35
AC
56592011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
5660
5661 * a-fihema.ads, a-fihema.adb: Unit removed.
5662 * a-undesu.ads, a-undesu.adb: New unit implementing
5663 Ada.Unchecked_Deallocate_Subpool.
5664 * einfo.adb: Remove Associated_Collection from the node usage.
5665 Add Finalization_Master to the node usage.
5666 (Associated_Collection): Removed.
5667 (Finalization_Master): New routine.
5668 (Set_Associated_Collection): Removed.
5669 (Set_Finalization_Master): New routine.
5670 (Write_Field23_Name): Remove Associated_Collection from the output. Add
5671 Finalization_Master to the output.
5672 * einfo.ads: Remove attribute Associated_Collection and its uses in
5673 entities.
5674 Add new attribute Finalization_Master along with its uses in entitites.
5675 (Associated_Collection): Removed along with its pragma import.
5676 (Finalization_Master): New routine along with a pragma import.
5677 (Set_Associated_Collection): Removed along with its pragma import.
5678 (Set_Finalization_Master): New routine along with a pragma import.
5679 * exp_ch3.adb (Expand_Freeze_Array_Type): Replace call to
5680 Build_Finalization_Collection with Build_Finalization_Master.
5681 (Expand_Freeze_Record_Type): Move the generation of Finalize_Address
5682 before the bodies of the predefined routines. Add comment explaining
5683 this. Replace call to Build_Finalization_Collection with
5684 Build_Finalization_Master.
5685 (Freeze_Type): Replace call to Build_Finalization_Collection with
5686 Build_Finalization_Master.
5687 (Make_Finalize_Address_Body): Comment reformatting.
5688 (Make_Predefined_Primitive_Specs): Code reformatting.
5689 (Stream_Operation_OK): Update comment mentioning finalization
5690 collections. Replace RE_Finalization_Collection with
5691 RE_Finalization_Master.
5692 * exp_ch4.adb (Complete_Controlled_Allocation): Replace call to
5693 Associated_Collection with Finalization_Master. Replace call to
5694 Build_Finalization_Collection with Build_Finalization_Master.
5695 (Expand_Allocator_Expression): Replace call to Associated_Collection
5696 with Finalization_Master. Replace call to Set_Associated_Collection with
5697 Set_Finalization_Master. Remove the generation of
5698 Set_Finalize_Address_Ptr.
5699 (Expand_N_Allocator): Replace call to Associated_Collection with
5700 Finalization_Master. Remove the generation of Set_Finalize_Address_Ptr.
5701 * exp_ch6.adb (Add_Collection_Actual_To_Build_In_Place_Call): Renamed to
5702 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Update the
5703 comment on usage. Replace call to Needs_BIP_Collection with
5704 Needs_BIP_Finalization_Master Remplace BIP_Collection with
5705 BIP_Finalization_Master. Update all comments which mention finalization
5706 collections. Replace Associated_Collection with
5707 Finalization_Master. Replace Build_Finalization_Collection with
5708 Build_Finalization_Master.
5709 (BIP_Formal_Suffix): Update BIP_Collection's case.
5710 (Build_Heap_Allocator): Update the related comment. Rename local
5711 variable Collect to Fin_Mas_Id and update its occurrences. Update
5712 comments which mention finalization collections. Replace
5713 Set_Associated_Collection with Set_Finalization_Master.
5714 (Expand_Call): Update the code which detects a special piece of library
5715 code for .NET/JVM.
5716 (Make_Build_In_Place_Call_In_Allocator): Replace the call to
5717 Add_Collection_Actual_To_Build_In_Place_Call with
5718 Add_Finalization_Master_Actual_To_Build_In_Place_Call. Remove the code
5719 which generates a call to Make_Set_Finalize_Address_Ptr_Call.
5720 (Make_Build_In_Place_Call_In_Anonymous_Context): Replace call to
5721 Add_Collection_Actual_To_Build_In_Place_Call with
5722 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
5723 (Make_Build_In_Place_Call_In_Assignment): Replace call to
5724 Add_Collection_Actual_To_Build_In_Place_Call with
5725 Add_Finalization_Master_Actual_To_Build_In_Place_Call.
5726 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
5727 * exp_ch6.ads: Rename BIP_Collection to BIP_Finalization_Master.
5728 (Needs_BIP_Collection): Renamed to Needs_BIP_Finalization_Master.
5729 * exp_ch7.adb (Build_BIP_Cleanup_Stmts): Update comment on usage.
5730 Rename local variable Collect to Fin_Mas_Id and update its occurrences.
5731 Replace call to Set_Associated_Collection with Set_Finalization_Master.
5732 (Build_Finalization_Collection): Renamed to Build_Finalization_Master.
5733 Replace the call to Associated_Collection with Finalization_Master.
5734 Rename local variable Coll_Id to Fin_Mas_Id and update its occurrences.
5735 Update the way finalization master names are generated. Update the
5736 retrieval of the correct access type which will carry the pool and
5737 master attributes.
5738 (Make_Final_Call): Reimplement the way [Deep_]Finalize is retrieved.
5739 (Make_Finalize_Address_Body): Abstract types do not need
5740 Finalize_Address. Code reformatting.
5741 (Make_Finalize_Address_Stmts): Update comment on usage.
5742 (Make_Set_Finalize_Address_Ptr_Call): Removed.
5743 (Process_Declarations): Update comments.
5744 * exp_ch7.ads (Build_Finalization_Collection): Renamed to
5745 Build_Finalization_Master. Update associated comment.
5746 (Make_Set_Finalize_Address_Ptr_Call): Removed.
5747 * exp_ch13.adb: Update comments which mention finalization collections.
5748 (Expand_N_Free_Statement): Replace the call to Associated_Collection
5749 with Finalization_Master.
5750 * exp_util.adb (Build_Allocate_Deallocate_Proc): Reimplemented to
5751 create calls to routines Allocate_Any_Controlled and
5752 Deallocate_Any_Controlled.
5753 (Find_Finalize_Address): New routine.
5754 (Is_Allocate_Deallocate_Proc): Update the RTE entities used in the
5755 comparison.
5756 (Requires_Cleanup_Actions): Update the comment on freeze node
5757 inspection.
5758 * exp_util.ads: Remove comment on generated code for
5759 Build_Allocate_Deallocate_Proc. The code is now quite complex and it
5760 is better to simply look in the body.
5761 * freeze.adb (Freeze_All): Update the comment of finalization
5762 collections. Replace the call to Associated_Collection with
5763 Finalization_Master. Replace the call to Build_Finalization_Collection
5764 with Build_Finalization_Master.
5765 * impunit.adb: Add a-undesu and s-stposu to the list of units.
5766 * Makefile.rtl: Add files a-undesu, s-finmas and s-stposu. Remove file
5767 a-fihema.
5768 * rtsfind.adb (Get_Unit_Name): Remove the processing for children of
5769 Ada.Finalization. Add processing for children of System.Storage_Pools.
5770 * rtsfind.ads: Remove the naming of second level children of
5771 Ada.Finalization.
5772 Remove Ada_Finalization_Heap_Management from the list of units.
5773 Remove subtype Ada_Finalization_Child.
5774 Remove the following subprogram entities:
5775
5776 RE_Allocate
5777 RE_Deallocate
5778 RE_Finalization_Collection
5779 RE_Finalization_Collection_Ptr
5780 RE_Set_Finalize_Address_Ptr
5781
5782 Add the naming of second level children of System.Storage_Pools.
5783 Add System_Finalization_Masters and System_Storage_Pools_Subpools to
5784 the list of units.
5785 Add subtype System_Storage_Pools_Child.
5786 Add the following subprogram entities to System.Finalization_Masters:
5787
5788 RE_Finalization_Master
5789 RE_Finalization_Master_Ptr
5790
5791 Add the following subprogram entities to System.Storage_Pools.Subpools:
5792
5793 RE_Allocate_Any_Controlled
5794 RE_Deallocate_Any_Controlled
5795 RE_Root_Storage_Pool_With_Subpools
5796 RE_Root_Subpool
5797 RE_Subpool_Handle
5798
5799 Move the following subprogram entities from
5800 Ada.Finalization.Heap_Management to System.Finalization_Masters:
5801
5802 RE_Add_Offset_To_Address
5803 RE_Attach
5804 RE_Base_Pool
5805 RE_Detach
5806
5807 * sem_ch3.adb (Access_Type_Declaration): Replace the call to
5808 Set_Associated_Collection with Set_Finalization_Master.
5809 * sem_ch6.adb (Create_Extra_Formals): Update the way extra formal
5810 BIP_Finalization_Master is created.
5811 * s-finmas.adb: New unit System.Finalization_Masters.
5812 * s-finmas.ads: New unit System.Finalization_Masters.
5813 * s-stopoo.ads, s-stopoo.adb: Minor code reformatting.
5814 * s-stposu.ads, s-stposu.adb: New unit implementing
5815 System.Storage_Pools.Subpools.
5816
58172011-08-29 Bob Duff <duff@adacore.com>
5818
5819 * tbuild.adb: Add assertion.
5820
8c889ae4
AC
58212011-08-29 Thomas Quinot <quinot@adacore.com>
5822
5823 * s-pooglo.adb: Minor reformatting.
5824
58252011-08-29 Ed Schonberg <schonberg@adacore.com>
5826
5827 * exp_ch5.adb (Expand_N_Assignment_Statement): if the left-hand side is
5828 an indexed component of a packed array whose element type is a record
5829 with a representation clause different from that of the right-hand
5830 side, generate a temporary to minimuze the number of bit-field
5831 operations generated.
5832
58332011-08-29 Ed Schonberg <schonberg@adacore.com>
5834
5835 * exp_util.adb (Insert_Actions): Use clauses can be part of lists of
5836 declarations, and thus are likely insertion points for actions.
5837
58382011-08-29 Bob Duff <duff@adacore.com>
5839
5840 * einfo.ads: Minor comment fix.
5841
1a07a71a
AC
58422011-08-29 Robert Dewar <dewar@adacore.com>
5843
5844 * frontend.adb, gnat1drv.adb: Minor reformatting.
5845
58462011-08-29 Tristan Gingold <gingold@adacore.com>
5847
5848 * s-pooglo.adb (Allocate, Deallocate): Take into account the alignment.
5849 * a-fihema.adb (Allocate, Deallocate): Ditto. Possibly add padding
5850 space in front of the header.
5851
4bcd6411
JK
58522011-08-29 Johannes Kanig <kanig@adacore.com>
5853
5854 * frontend.adb (Frontend): Exit after creating Standard package when
5855 -gnatd.H is present.
5856 * gnat1drv.adb (Gnat1drv): Call Backend right away when -gnatd.H is
5857 present.
5858
f0f88eb6
RD
58592011-08-29 Robert Dewar <dewar@adacore.com>
5860
5861 * exp_ch9.adb, mlib-prj.adb, prj.adb, prj.ads, ttypes.ads, sem_ch4.adb,
5862 makeutl.adb, makeutl.ads, atree.ads, snames.adb-tmpl,
5863 snames.ads-tmpl: Minor reformatting.
5864
3e37be71
PG
58652011-08-29 Philippe Gil <gil@adacore.com>
5866
5867 * prj.adb (Reset_Units_In_Table): New procedure.
5868 Reset units to avoid access to freed memory.
5869
94fb7608
AC
58702011-08-29 Thomas Quinot <quinot@adacore.com>
5871
5872 * get_scos.adb: When reading a P statement SCO without a pragma name
5873 (from an older ALI file), ensure that the Pragma_Name component is set
5874 to Unknown_Pragma (not left uninitialized).
5875
58762011-08-29 Vincent Celier <celier@adacore.com>
5877
5878 * makeutl.adb (Get_Directories): New procedure moved from Buildgpr and
5879 modified to compute correctly the object path of a SAL project that is
5880 extending another library project.
5881 (Write_Path_File): New procedure.
5882 * makeutl.ads (Directories): New table moved from Buildgpr
5883 (Get_Directories): New procedure moved from Buildgpr
5884 (Write_Path_File): New procedure
5885 * mlib-prj.adb (Build_Library): Use Makeutl.Get_Directories to set the
5886 paths before binding SALs, instead of Set_Ada_Paths.
5887 * prj-env.adb (Set_Path_File_Var): Procedure has been moved to package
5888 Prj.
5889 * prj.adb (Set_Path_File_Var): New procedure moved from Prj.Env
5890 (Current_Source_Path_File_Of): New function
5891 (Set_Current_Object_Path_File_Of): New procedure
5892 (Current_Source_Object_File_Of): New function
5893 (Set_Current_Object_Path_File_Of): New procedure
5894 * prj.ads (Set_Path_File_Var): New procedure moved from Prj.Env
5895 (Current_Source_Path_File_Of): New function
5896 (Set_Current_Object_Path_File_Of): New procedure
5897 (Current_Source_Object_File_Of): New function
5898 (Set_Current_Object_Path_File_Of): New procedure
5899
59002011-08-29 Ed Schonberg <schonberg@adacore.com>
5901
5902 * exp_ch5.adb (Expand_N_Assignment_Statement): For an assignment to a
5903 packed entity, use a bit-field assignment only if there is no change of
5904 representation.
5905
c5ecd6b7
AC
59062011-08-29 Thomas Quinot <quinot@adacore.com>
5907
5908 * rtsfind.ads, exp_ch3.adb (In_Runtime): Minor code improvement, use
5909 Is_RTU instead of using Chars comparisons.
5910
59112011-08-29 Thomas Quinot <quinot@adacore.com>
5912
5913 * exp_strm.adb (Build_Mutable_Record_Read_Procedure): Do not create a
5914 temporary object if the actual is constrained, and the discriminants
5915 read from the stream don't match.
5916
59172011-08-29 Tristan Gingold <gingold@adacore.com>
5918
5919 * sem_attr.adb, exp_attr.adb: Add handling of
5920 Attribute_System_Allocator_Alignment
5921 * snames.ads-tmpl: Add Name_System_Allocator_Alignment and
5922 Attribute_System_Allocator_Alignment.
5923 * ttypes.ads, get_targ.ads: Add Get_System_Allocator_Alignment.
5924 * gcc-interface/targtyps.c, gcc-interface/utils2.c,
5925 gcc-interface/gigi.h: Renames get_target_default_allocator_alignment to
5926 get_target_system_allocator_alignment.
5927
59282011-08-29 Arnaud Charlet <charlet@adacore.com>
5929
5930 * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Update
5931 dependencies.
5932
8abdac29
AC
59332011-08-29 Arnaud Charlet <charlet@adacore.com>
5934
5935 * exp_ch3.adb (In_Runtime): Fix typo.
5936
df170605
AC
59372011-08-29 Bob Duff <duff@adacore.com>
5938
5939 * sem_ch4.adb (Analyze_Allocator): Analyze the subpool specification.
5940
59412011-08-29 Ed Schonberg <schonberg@adacore.com>
5942
5943 * exp_ch3.adb (Expand_N_Object_Declaration): If the entity is tagged
5944 and a separate tag assignment is generated, ensure that the tag
5945 assignment is analyzed.
5946
864a4236
ES
59472011-08-29 Ed Schonberg <schonberg@adacore.com>
5948
5949 * atree.ads, atree.adb (Copy_Separate_List): New function that applies
5950 Copy_Separate_Tree to a list of nodes. Used to create disjoint copies
5951 of statement lists that may contain local declarations.
df170605
AC
5952 * exp_ch9.adb (Expand_N_Timed_Entry_Call): Use Copy_Separate_List to
5953 duplicate the triggering statements needed for the expansion of this
5954 construct, when the trigger is a dispatching call to a synchronized
5955 primitive.
864a4236 5956
7f394c1d
AC
59572011-08-29 Arnaud Charlet <charlet@adacore.com>
5958
5959 * gnat_rm.texi: Add doc for 'Elab_Subp_Body.
5960 * bindgen.adb: Add comments.
5961 * snames.adb-tmpl (Is_Attribute_Name): Only recognize 'Elab_Subp_Body
5962 in CodePeer mode.
5963
2c1a2cf3
RD
59642011-08-29 Robert Dewar <dewar@adacore.com>
5965
5966 * exp_attr.adb: Minor reformatting.
5967 Minor code reorganization and commenting.
5968 * par_sco.adb, checks.adb, sem_attr.adb, get_scos.adb: Minor
5969 reformatting.
5970
0bfc9a64
AC
59712011-08-29 Thomas Quinot <quinot@adacore.com>
5972
5973 * get_scos.adb: Ignore chaining indicators not currently supported
5974 by Ada.
5975
59762011-08-29 Arnaud Charlet <charlet@adacore.com>
5977
5978 * system.ads: Minor editing.
5979
59802011-08-29 Arnaud Charlet <charlet@adacore.com>
5981
5982 * bindgen.adb (Gen_Elab_Calls): Generate calls to subp'Elab_Subp_Body in
5983 CodePeer mode.
5984 * sem_attr.ads, sem_attr.adb, exp_Attr.adb, sem_ch6.adb: Add handling of
5985 Attribute_Elab_Subp_Body.
5986 * snames.ads-tmpl (Attribute_Elab_Subp_Body, Name_Elab_Subp_Body): New.
5987 * sem_util.adb: Update comments.
5988
828d4cf0
TQ
59892011-08-29 Thomas Quinot <quinot@adacore.com>
5990
5991 * par_sco.adb, scos.adb, scos.ads, put_scos.adb, get_scos.adb: Record
5992 pragma name for each SCO statement corresponding to a pragma.
5993
5cd7bb15
AC
59942011-08-29 Arnaud Charlet <charlet@adacore.com>
5995
5996 * opt.ads: Minor editing.
5997
59982011-08-29 Yannick Moy <moy@adacore.com>
5999
6000 * gnat1drv.adb (Adjust_Global_Switches): Remove options for ALFA mode
6001 that only made sense for CodePeer mode.
6002
60032011-08-29 Jose Ruiz <ruiz@adacore.com>
6004
6005 * targparm.ads (Support_64_Bit_Divides_On_Target): Remove this flag
6006 which is no longer used.
6007 * targparm.adb (S64, S64_Str, Get_Target_Parameters): Remove the
6008 handling of the 64-bit division check.
6009 * exp_ch4.adb (Expand_N_Op_Divide): Remove the check for 64-bit
6010 division available.
6011 * system*.ads (Support_64_Bit_Divides): Remove this flag which is no
6012 longer used.
6013
60142011-08-29 Thomas Quinot <quinot@adacore.com>
6015
6016 * get_scos.adb: Minor reformatting.
6017
25b589cb
AC
60182011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
6019
6020 * exp_util.adb (Process_Statements_For_Controlled_Objects): Whenever a
6021 statement list is wrapped in a block, the block is explicitly analyzed
6022 in order to properly redecorate the entities and create a servicing
6023 finalizer.
6024
60252011-08-29 Tristan Gingold <gingold@adacore.com>
6026
6027 * sinfo.ads, sinfo.adb (Zero_Cost_Handling): Remove.
6028 (Set_Zero_Cost_Handling): Remove.
6029
60302011-08-29 Thomas Quinot <quinot@adacore.com>
6031
6032 * par_sco.adb, scos.ads, put_scos.adb, get_scos.adb: Minor reformatting
6033
1197ddb1
AC
60342011-08-29 Geert Bosch <bosch@adacore.com>
6035
6036 * s-vaflop-vms-alpha.adb (Neg_F): Use subtraction instead of negation
6037 instruction, as the latter may produce -0.0, which is not a valid VAX
6038 F float number.
6039 (Neg_G): Likewise for VAX F float.
6040
60412011-08-29 Robert Dewar <dewar@adacore.com>
6042
6043 * exp_util.adb: Minor reformatting.
6044
60452011-08-29 Yannick Moy <moy@adacore.com>
6046
6047 * sem_ch3.adb: Minor comment update.
6048
60492011-08-29 Thomas Quinot <quinot@adacore.com>
6050
6051 * checks.adb (Apply_Type_Conversion_Checks): Use the Underlying_Type of
6052 the operand type.
6053
60542011-08-29 Thomas Quinot <quinot@adacore.com>
6055
6056 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not flush
6057 current statement sequence on a generic instantiation or a subprogram
6058 declaration.
6059
8f66cda7
AC
60602011-08-29 Robert Dewar <dewar@adacore.com>
6061
6062 * sem_type.adb, einfo.ads, freeze.adb, exp_ch4.adb, sem_ch13.adb:
6063 Minor reformatting.
6064
60652011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
6066
6067 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
6068 Correct the check which involves the freeze node of a controlled or
6069 access-to-controlled type.
6070
60712011-08-29 Geert Bosch <bosch@adacore.com>
6072
6073 * sem_warn.adb (Check_Code_Statement): Remove check for consecutive Asm
6074 statements.
6075 * s-vaflop-vms-alpha.adb: Remove bogus Volatile => True arguments from
6076 Asm statements.
6077
cf161d66
AC
60782011-08-29 Yannick Moy <moy@adacore.com>
6079
6080 * sem_ch3.adb (Array_Type_Declaration): Insert a subtype declaration
6081 for every index type and component type that is not a subtype_mark.
6082 (Process_Subtype): Set Etype of subtype.
6083
60842011-08-29 Robert Dewar <dewar@adacore.com>
6085
6086 * a-cbmutr.adb, a-cimutr.adb, a-comutr.adb, prj-nmsc.adb: Minor code
6087 reorganization. Minor reformatting.
6088
7cc83cd8
AC
60892011-08-29 Steve Baird <baird@adacore.com>
6090
6091 * exp_ch4.adb (Expand_N_Op_Expon): Suppress N_Op_Expon node expansion
6092 for CodePeer and ALFA modes.
6093
60942011-08-29 Ed Schonberg <schonberg@adacore.com>
6095
6096 * sem_type.adb (Collect_Interps): Within an instance, collect a homonym
6097 that comes from an enclosing scope if it is not the renaming of an
6098 actual, to handle properly a spurious ambiguity in an instance.
6099
76af4137
AC
61002011-08-29 Eric Botcazou <ebotcazou@adacore.com>
6101
6102 * sem_ch13.adb (Alignment_Check_For_Esize_Change): Rename to...
6103 (Alignment_Check_For_Size_Change): ...this. Add SIZE parameter and
6104 use it instead of the Esize of the first parameter.
6105 (Analyze_Attribute_Definition_Clause) <Object_Size>: Adjust call to
6106 above change.
6107 <Size>: Likewise. Call it for composite types on the RM size.
6108
61092011-08-29 Yannick Moy <moy@adacore.com>
6110
6111 * exp_ch4.adb (Expand_N_Op_Not): Do not expand not on array.
6112 * sem_util.adb (Unique_Name): Correct behaviour for names of
6113 compilation units.
6114
9b20e59b
AC
61152011-08-29 Yannick Moy <moy@adacore.com>
6116
6117 * sem_prag.adb (Check_Precondition_Postcondition): In formal
6118 verification mode, analyze pragma expression for correctness, for
6119 pre/post on library-level subprogram, as it is not expanded later.
6120
61212011-08-29 Yannick Moy <moy@adacore.com>
6122
6123 * exp_aggr.adb (Expand_Array_Aggregate): Do not expand array aggregates
6124 in formal verification.
6125
61262011-08-29 Thomas Quinot <quinot@adacore.com>
6127
6128 * sem_util.adb: Minor reformatting.
6129 * freeze.adb, sem_ch13.adb: Fix comment: Bit_Order is an attribute,
6130 there's no pragma.
6131 * par_sco.ads, par_sco.adb: Update comments.
6132
61332011-08-29 Yannick Moy <moy@adacore.com>
6134
6135 * einfo.adb, einfo.ads: Remove flag Is_Postcondition_Proc and
6136 associated getter/setter.
6137 * sem_ch6.adb: Remove reference to Is_Postcondition_Proc.
6138
61392011-08-29 Vincent Celier <celier@adacore.com>
6140
6141 * prj-attr.adb: New Compiler attribute Dependency_Kind and Language_Kind
6142 * prj-conf.adb: Add_Default_GNAT_Naming_Scheme: Add a package Compiler
6143 with declarations for Language_Kind and Dependency_Kind for Ada.
6144 * prj-nmsc.adb (Check_Unit_Name): New name of procedure Check_Ada_Name
6145 (Process_Compiler): Take into account the new attributes Dependency_Kind
6146 and Language_Kind.
6147 (Check_Configuration): Check if language kind is unit based, not if the
6148 language name is Ada.
6149 (Process_Exceptions_Unit_Based): Ditto
6150 (Add_Language): Remove default additions of language and dependency kind
6151 * prj.ads: Minor comment change
6152 * snames.ads-tmpl: New standard names Dependency_Kind and Language_Kind
6153
61542011-08-29 Johannes Kanig <kanig@adacore.com>
6155
6156 * debug.adb: Update comments.
6157
c5bc3df6
JM
61582011-08-24 Joseph Myers <joseph@codesourcery.com>
6159
6160 * gcc-interface/Make-lang.in (CFLAGS-ada/tracebak.o)
6161 (CFLAGS-ada/targext.o, CFLAGS-ada/cio.o, CFLAGS-ada/init.o)
6162 (CFLAGS-ada/initialize.o, CFLAGS-ada/raise.o): New.
6163 (ada/tracebak.o, ada/targext.o, ada/cio.o, ada/init.o)
6164 (ada/initialize.o, ada/raise.o): Remove explicit compilation rules.
6165
e3aa9eba
RO
61662011-08-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6167
6168 * gcc-interface/Makefile.in (PICFLAG_FOR_TARGET): New.
6169 (GNATLIBCFLAGS_FOR_C): Replace
6170 TARGET_LIBGCC2_CFLAGS by PICFLAG_FOR_TARGET.
6171 (gnatlib-shared-default, gnatlib-shared-dual-win32)
6172 (gnatlib-shared-win32, gnatlib-shared-darwin, gnatlib-shared)
6173 (gnatlib-sjlj, gnatlib-zcx): Likewise.
6174
f446d60e
EB
61752011-08-07 Eric Botcazou <ebotcazou@adacore.com>
6176
6177 * gcc-interface/Makefile.in (raise-gcc.o): Fix previous change.
6178
588c8f48
EB
6179 * gcc-interface/gigi.h (enumerate_modes): Fix formatting.
6180
6181 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Revert latest change.
6182
28d711bf
NR
61832011-08-05 Nicolas Roche <roche@adacore.com>
6184
6185 * gcc-interface/Makefile.in: Don't use directly ../xgcc to build shared
6186 libgnat. Use rather the value of GCC_FOR_TARGET. Fix issue with
6187 canadian cross.
6188 * gcc-interface/Make-lang.in: Add support for canadian cross setting.
6189
993f8920
AC
61902011-08-05 Matthew Heaney <heaney@adacore.com>
6191
6192 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Child_Count, Child_Depth):
6193 subprogram bodies declared out-of-order.
6194
61952011-08-05 Yannick Moy <moy@adacore.com>
6196
6197 * sem_util.adb (Unique_Name): only prefix with "standard" the names of
6198 entities directly in package Standard, otherwise skip the standard
6199 prefix.
6200
9b3956dd
RD
62012011-08-05 Robert Dewar <dewar@adacore.com>
6202
6203 * a-cbmutr.adb: Minor reformatting
6204 (Allocate_Node): refactor node allocation algorithm
6205
62062011-08-05 Robert Dewar <dewar@adacore.com>
6207
6208 * opt.ads, opt.adb (Debug_Pragmas_Disabled): New switch.
6209 * sem_prag.adb (Analyze_Pragma, case Debug_Policy): Implement Disable
6210 mode.
6211 (Analyze_Pragma, case Check_Policy): Ditto.
6212 * sem_prag.ads (Check_Disabled): New function
6213 * snames.ads-tmpl: Add Name_Disable.
6214
62152011-08-05 Robert Dewar <dewar@adacore.com>
6216
6217 * gnat_rm.texi: Document implementation-defined policy DISABLE for
6218 pragmas Assertion_Policy, Check_Policy, Debug_Policy.
6219
79e705d6
AC
62202011-08-05 Ed Schonberg <schonberg@adacore.com>
6221
6222 * sem_prag.adb (Analyze_Pragma, case Inline): reject an Inline pragma
6223 that appears in a generic formal part and applies to a formal
6224 subprogram.
6225
62262011-08-05 Robert Dewar <dewar@adacore.com>
6227
6228 * a-cbmutr.ads: Minor reformatting.
6229
23b6deca
AC
62302011-08-05 Matthew Heaney <heaney@adacore.com>
6231
6232 * a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Read): do not use T'Valid
6233 to check count, check sign of value instead.
6234 * a-comutr.adb, a-cimutr.adb (Write): return immediately if tree empty
6235 (Copy_Subtree): allocate copy of source element
6236 (Equal_Subtree): compare elements, not access objects
6237
62382011-08-05 Vincent Celier <celier@adacore.com>
6239
6240 * gnat_ugn.texi: Fix VMS alternative.
6241
a2773bd3
AC
62422011-08-05 Thomas Quinot <quinot@adacore.com>
6243
6244 * sem_ch11.adb: Add comment.
6245
62462011-08-05 Robert Dewar <dewar@adacore.com>
6247
6248 * exp_util.adb: Minor comment fix.
6249
62502011-08-05 Robert Dewar <dewar@adacore.com>
6251
6252 * scng.adb (Error_Unterminated_String): Improve flag position when
6253 comma present.
6254
62552011-08-05 Matthew Heaney <heaney@adacore.com>
6256
6257 * Makefile.rtl, impunit.adb: Added a-cbmutr.ad[sb] (bounded multiway
6258 tree containers).
6259 * a-cbmutr.ads, a-cbmutr.adb: This is the new Ada 2012 unit for bounded
6260 multiway tree containers.
6261
62622011-08-05 Robert Dewar <dewar@adacore.com>
6263
6264 * styleg.adb (Check_Comment): Implement comment spacing of 1 or 2
6265 * stylesw.adb: Implement -gnatyC to control comment spacing
6266 * stylesw.ads (Style_Check_Comments_Spacing): New switch (set by
6267 -gnatyc/C).
6268 * usage.adb: Add line for -gnatyC.
6269
62702011-08-05 Robert Dewar <dewar@adacore.com>
6271
f446d60e 6272 * gnat_ugn.texi: Document -gnatyC.
a2773bd3
AC
6273 * vms_data.ads: Implement COMMENTS1/COMMENTS2 (retaining COMMENTS as a
6274 synonym for COMMENTS2).
6275
dedac3eb
RD
62762011-08-05 Robert Dewar <dewar@adacore.com>
6277
6278 * par_sco.adb, sem_ch3.adb, scos.ads, a-iteint.ads, sem_ch12.adb,
6279 a-cimutr.adb, a-cimutr.ads, sem_util.ads, sem_res.adb, a-fihema.adb,
6280 sem_ch4.adb, lib-xref-alfa.adb, exp_disp.adb, a-comutr.adb,
6281 a-comutr.ads, lib-xref.adb: Minor reformatting.
6282
62832011-08-05 Robert Dewar <dewar@adacore.com>
6284
6285 * sem_ch11.adb (Analyze_Raise_Statement): Kill assignment to formal
6286 warning if there is an exception handler present.
6287
7c62a85a
AC
62882011-08-05 Pascal Obry <obry@adacore.com>
6289
6290 * a-iteint.ads: Fix copyright year.
6291
62922011-08-05 Thomas Quinot <quinot@adacore.com>
6293
6294 * par_sco.adb (Traverse_Declarations_Or_Statements): Do not generate a
6295 statement SCO for a USE clause or a representation clause.
6296
62972011-08-05 Yannick Moy <moy@adacore.com>
6298
6299 * lib-xref-alfa.adb (Collect_ALFA): generate the proper relation
6300 between body and spec for stub.
6301 (Detect_And_Add_ALFA_Scope): take into account subprogram stub
6302 * lib-xref.adb (Enclosing_Subprogram_Or_Package): in the case of a
6303 pragma precondition or postcondition, for which the enclosing
6304 subprogram or package in the AST is not the desired one, return empty.
6305
e49208a9
AC
63062011-08-05 Thomas Quinot <quinot@adacore.com>
6307
6308 * g-expect.adb: Minor reformatting.
6309
63102011-08-05 Bob Duff <duff@adacore.com>
6311
6312 * a-fihema.adb: Comment out OS_Lib.
6313
63142011-08-05 Matthew Heaney <heaney@adacore.com>
6315
6316 * Makefile.rtl, impunit.adb: Added a-c[oi]mutr.ad[sb]
6317 (unbounded multiway tree containers) and a-iteint.ads.
6318 * a-comutr.ads, a-comutr.adb:
6319 This is the new Ada 2012 unit for unbounded multiway tree containers
6320 * a-cimutr.ads, a-cimutr.adb
6321 This is the new Ada 2012 unit for indefinite multiway tree containers
6322 * a-iteint.ads: New file.
6323
201cdb74
RO
63242011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6325
f446d60e 6326 * gcc-interface/Makefile.in (raise-gcc.o): Search $(srcdir)/../libgcc.
201cdb74 6327
d50f4827
AC
63282011-08-05 Bob Duff <duff@adacore.com>
6329
6330 * sinfo.ads, sinfo.adb (Subpool_Handle_Name): New attribute for
6331 subpools.
6332 * par-ch4.adb (P_Allocator): Parse new subpool specification syntax.
6333
63342011-08-05 Ed Schonberg <schonberg@adacore.com>
6335
6336 * sem_ch4.adb (Try_Container_Indexing): New procedure to implement the
6337 general indexing aspects of Ada2012. Called when analyzing indexed
6338 components when other interpretations fail.
6339 * sem_ch8.adb (Find_Direct_Name): check for implicit dereference only
6340 in an expression context where overloading is meaningful. This excludes
6341 the occurrence in an aspect specification (efficiency only).
6342 * sem_attr.adb (Analyze_Attribute): indicate that the attributes
6343 related to iterators can be set by an attribute specification, but
6344 cannot be queried.
6345 * sem_ch13.adb (Analyze_Aspect_Specifications): handle
6346 Constant_Indexing and Variable_Indexing.
6347 (Check_Indexing_Functions): New procedure to perform legality checks.
6348 Additional semantic checks at end of declarations.
6349
efe05dfc
AC
63502011-08-05 Sergey Rybin <rybin@adacore.com>
6351
6352 * tree_io.ads: Update ASIS_Version_Number because of the change of the
6353 order of calling Tree_Write/Tree_Read routines made for aspects.
6354
63552011-08-05 Bob Duff <duff@adacore.com>
6356
6357 * a-fihema.adb (Finalize): Fix race condition.
6358
5f9cdefe
AC
63592011-08-05 Yannick Moy <moy@adacore.com>
6360
6361 * sem_ch12.adb (Analyze_Package_Instantiation,
6362 Need_Subprogram_Instance_Body): do not generate instance bodies in ALFA
6363 mode.
6364
63652011-08-05 Ed Schonberg <schonberg@adacore.com>
6366
6367 * sem_type.adb (Specific_Type): in an instance, the type-specific
6368 operand of an equality check that involves null may have a private
6369 type. Use full view to determine legality of construct.
6370
822868aa
AC
63712011-08-05 Vincent Celier <celier@adacore.com>
6372
6373 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
6374 delete or close the file when the call to gnatmake was successful.
6375
63762011-08-05 Yannick Moy <moy@adacore.com>
6377
6378 * gnat1drv.adb (Adjust_Global_Switches): in ALFA mode, set
6379 Global_Discard_Names.
6380
63812011-08-05 Ed Schonberg <schonberg@adacore.com>
6382
6383 * sinfo.ads: comments on use of entity field for aspect specifications.
6384
63852011-08-05 Ed Schonberg <schonberg@adacore.com>
6386
6387 * sem_ch12.adb (Reset_Entity): If the entity field of the associated
6388 node is not itself an entity but a selected component, it is a
6389 rewritten parameterless call to an en enclosing synchronized operation,
6390 and this expansion will be performed again in the instance, so there is
6391 no global information to preserve.
6392
44a10091
AC
63932011-08-05 Javier Miranda <miranda@adacore.com>
6394
6395 * exp_disp.adb (Set_All_DT_Position): Cleanup code and improve support
6396 for renamings of predefined primitives.
6397 (In_Predef_Prims_DT): New subprogram.
6398
63992011-08-05 Ed Schonberg <schonberg@adacore.com>
6400
6401 * sem_util.adb, sem_util.ads (Check_Implicit_Dereference): If a
6402 possible interpretation of name is a reference type, add an
6403 interpretation that is the designated type of the reference
6404 discriminant of that type.
6405 * sem_res.adb (resolve): If the interpretation imposed by context is an
6406 implicit dereference, rewrite the node as the deference of the
6407 reference discriminant.
6408 * sem_ch3.adb (Analyze_Subtype_Declaration, Build_Derived_Record_Type,
6409 Build_Discriminated_Subtype): Inherit Has_Implicit_Dereference from
6410 parent type or base type.
6411 * sem_ch4.adb (Process_Indexed_Component,
6412 Process_Overloaded_Indexed_Component, Indicate_Name_And_Type,
6413 Analyze_Overloaded_Selected_Component, Analyze_Selected_Component):
6414 Check for implicit dereference.
6415 (List_Operand_Interps): Indicate when an implicit dereference is
6416 ambiguous.
6417 * sem_ch8.adb (Find_Direct_Name): Check for implicit dereference.
6418
64192011-08-05 Thomas Quinot <quinot@adacore.com>
6420
6421 * scos.ads: Update documentation of SCO table. Pragma statements can now
6422 be marked as disabled (using 'p' instead of 'P' as the statement kind).
6423 * par_sco.ads, par_sco.adb: Implement the above change.
6424 (Process_Decisions_Defer): Generate a P decision for the first parameter
6425 of a dyadic pragma Debug.
6426 * sem_prag.adb (Analyze_Pragma, case Debug): Mark pragma as enabled if
6427 necessary.
6428 * put_scos.adb: Code simplification based on above change.
6429
bb3c784c
AC
64302011-08-05 Robert Dewar <dewar@adacore.com>
6431
6432 * sem_ch3.adb, gnatcmd.adb, switch-c.adb, exp_attr.adb, make.adb,
6433 bindgen.adb, einfo.adb, sem_ch12.adb, sem_attr.adb, a-fihema.adb,
6434 a-fihema.ads, sem_elab.adb, sem_elab.ads, aspects.adb, opt.ads,
6435 prj-conf.adb, sem_ch13.adb, s-ficobl.ads: Minor reformatting
6436
64372011-08-05 Bob Duff <duff@adacore.com>
6438
6439 * a-stunau.ads, g-spipat.adb: Update comments.
6440
36f686f9
BD
64412011-08-05 Bob Duff <duff@adacore.com>
6442
6443 * a-fihema.ads: Minor comment fix.
6444 * a-fihema.adb (Allocate, Deallocate): Assert that the alignment is
6445 correct.
6446 (Attach, Detach): Remove some unnecessary code.
6447 (Finalize): Remove Node_Ptr_To_Address, replace with a constant.
6448
7882673f
BD
64492011-08-05 Bob Duff <duff@adacore.com>
6450
6451 * a-fihema.ads, a-fihema.adb (Finalization_Collection): Avoid heap
6452 allocation for Objects component. This simplifies the code somewhat. It
6453 is also a little more efficient in the not-so-unusual case where there
6454 are no controlled objects allocated.
6455 Make Finalization_Started flag atomic.
6456 (Finalize): Avoid unnecessary detachment of items from the list.
6457 (pcol): Minor cleanup.
6458
d34cd274
AC
64592011-08-05 Ed Schonberg <schonberg@adacore.com>
6460
6461 * sem_ch12.adb (Analyze_Formal_Package_Declaration): reject a formal
6462 package whose name is the same as that of the generic unit, or its
6463 ultimate prefix.
6464
64652011-08-05 Bob Duff <duff@adacore.com>
6466
6467 * a-fihema.adb, a-fihema.ads: Minor comment improvements.
6468 * sem_ch3.adb, exp_ch5.adb, exp_ch7.adb, exp_ch7.ads, exp_util.adb:
6469 Minor comment fixes.
6470
00332244
AC
64712011-08-05 Arnaud Charlet <charlet@adacore.com>
6472
6473 * make.adb (Linking_Phase): No longer need to set source search path
6474 before calling gnatlink in CodePeer mode.
6475 * gnatlink.adb (Gnatlink): No longer pass -gnat83/95/05/12 switch to
6476 gcc in CodePeer mode, since the binder generated file no longer has a
6477 'with Main'.
6478 * switch.ads, switch.adb (Is_Language_Switch): Removed.
6479 * switch-c.adb: Update comment.
6480
64812011-08-05 Thomas Quinot <quinot@adacore.com>
6482
6483 * exp_strm.adb, bindgen.adb, s-ficobl.ads: Minor reformatting.
6484
64852011-08-05 Nicolas Roche <roche@adacore.com>
6486
6487 * gnat_ugn.texi: Fix minor syntax error issue.
6488
64892011-08-05 Vincent Celier <celier@adacore.com>
6490
6491 * gnatcmd.adb (Get_Closure): Do not crash when it is not possible to
6492 delete or close the file when the call to gnatmake returns a non
6493 successful return code.
6494
64952011-08-05 Ed Schonberg <schonberg@adacore.com>
6496
6497 * exp_ch4.adb (Expand_N_Type_Conversion): When expanding a predicate
6498 check, indicate that the copy of the original node does not come from
6499 source, to prevent an infinite recursion of the expansion.
6500
65012011-08-05 Johannes Kanig <kanig@adacore.com>
6502
6503 * debug.adb: document switch -gnatd.G for gnat2why, which deactivates
6504 VC generation for subprogram bodies.
6505
65062011-08-05 Yannick Moy <moy@adacore.com>
6507
6508 * einfo.ads: Typo.
6509 * sem_ch3.adb (Signed_Integer_Type_Declaration): in ALFA mode, define
6510 the base type with the smallest allowed base type.
6511
65122011-08-05 Sergey Rybin <rybin@adacore.com>
6513
6514 * tree_gen.adb, tree_in.adb, aspects.adb: Fix tree read-write for
6515 aspects.
6516
65172011-08-05 Ed Schonberg <schonberg@adacore.com>
6518
6519 * sem_ch12.ads: minor comment updates.
6520
65212011-08-05 Ed Schonberg <schonberg@adacore.com>
6522
6523 * sem_ch12.adb (Analyze_Formal_Package_Declaration): in an
6524 instantiation and a formal package the compiler generates a package
6525 renaming declaration so that the generic name within the declaration
6526 is interpreted as a renaming of the instance. At the end of a formal
6527 package declaration, this renaming must become invisible.
6528
0da80d7d
AC
65292011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
6530
6531 * exp_ch7.adb (Is_Init_Call): Reimplemented to avoid character
6532 comparison and rely on concrete entities instead.
6533
65342011-08-05 Ed Schonberg <schonberg@adacore.com>
6535
6536 * einfo.ads, einfo.adb (Has_Implicit_Dereference): new flag on types
6537 and discriminants, to indicate that the type has an access discriminant
6538 that supports implicit dereference.
6539 * snames.ads-tmpl: Add names of aspects and attributes related to
6540 Ada2012 iterators: constant_indexing, default_iterator,
6541 iterator_element, implicit_dereference, variable_indexing.
6542 * aspects.ads, aspects.adb: entries for iterator-related aspects.
6543 * sem_ch13.adb (Analyze_aspect_specifications): dummy entries for
6544 iterator-related aspects.
6545 * sem_attr.adb, exp_attr.adb Dummy entries for iterator-related aspects.
6546
65472011-08-05 Sergey Rybin <rybin@adacore.com>
6548
6549 * gnat_ugn.texi, vms_data.ads: Extend the subsection about coupling
6550 metrics in gnatmetric to cover new kinds of coupling mentrics.
6551
65522011-08-05 Steve Baird <baird@adacore.com>
6553
6554 * bindgen.adb (Gen_CodePeer_Wrapper): Call Ada_Main_Program instead
2c7f9cc0 6555 of calling the user-defined main subprogram.
0da80d7d
AC
6556 (Gen_Main): Declare Ada_Main_Program and (if CodePeer_Mode
6557 is set) Call_Main_Subprogram ahead of, as opposed to
6558 inside of, Main.
6559 (Gen_Output_File_Ada): Remove CodePeer_Mode-conditional
6560 generation of a "with" of the user-defined main subprogram.
6561 Remove CodePeer_Mode-conditional call to Gen_CodePeer_Wrapper
6562 (which is now called from Gen_Main instead).
6563
73242473
AC
65642011-08-05 Emmanuel Briot <briot@adacore.com>
6565
6566 * projects.texi: Added reference to the Makefile package.
6567
65682011-08-05 Thomas Quinot <quinot@adacore.com>
6569
6570 * exp_ch7.adb: Minor comment rewording.
6571
65722011-08-05 Ed Falis <falis@adacore.com>
6573
6574 * env.c: Fix comment.
6575
65762011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
6577
6578 * sem_elab.adb (Is_Finalization_Procedure): Reimplemented to avoid
6579 character comparison and rely on concrete entities instead.
6580
97ed5872
AC
65812011-08-05 Ed Schonberg <schonberg@adacore.com>
6582
6583 * sem_ch3.adb: (Check_Private_Overriding): better error message,
6584 suggested by AI95-0068.
6585
65862011-08-05 Hristian Kirtchev <kirtchev@adacore.com>
6587
6588 * exp_ch7.adb (Find_Last_Init): Use Next_Suitable_Statement to retrieve
6589 the two potential initialization calls. This accounts for any
6590 access-before-elaboration checks which may precede the initialization
6591 calls.
6592 (Next_Suitable_Statement): New routine. Returns the next real statement
6593 after the input node while skipping generated checks.
6594 * sem_elab.adb (Check_A_Call): New formal parameter In_Init_Proc along
6595 with comment on usage.
6596 Do not generate Elaborate_All when the trigger is a finalization call
6597 coming from a type init proc.
6598 (Check_Elab_Call): Propagate the initialization procedure context to
6599 subsequent calls to Check_A_Call.
6600 (Check_Internal_Call_Continue): Propagate the initialization procedure
6601 context to subsequent calls to Check_Elab_Call.
6602 (Is_Finalization_Procedure): New routine. Returns True if the input
6603 entity denotes a [Deep_]Finalize routine.
6604 * sem_elab.ads (Check_Elab_Call): New formal parameter In_Init_Proc
6605 along with comment on usage.
6606
66072011-08-05 Vadim Godunko <godunko@adacore.com>
6608
6609 * s-atocou.ads: Add list of supported platforms.
6610
66112011-08-05 Yannick Moy <moy@adacore.com>
6612
6613 * sem_prag.adb, restrict.adb: Correct style for or'ing Boolean variables
6614
6615 * opt.ads (Disable_ALI_File): new Boolean flag
6616 * lib-writ.adb (Write_ALI): when Disable_ALI_File is set, do nothing
6617
66182011-08-05 Ed Falis <falis@adacore.com>
6619
6620 * env.c (__gnat_environ): Fix includes for RTPs and VTHREADS so that
6621 environ is properly defined.
6622
66232011-08-05 Vincent Celier <celier@adacore.com>
6624
6625 * make.adb (Compilation_Phase): Exit immediately when all objects have
6626 been found up to date, to avoid multiple exit messages.
6627 * prj-nmsc.adb (Add_Source): Allow duplicate source file names in the
6628 same project for languages with no compiler.
6629 * gnat_ugn.texi: Document compiler switch -gnateI and gnatmake switch
6630 -eI.
9aff36e9
RD
66312011-08-05 Robert Dewar <dewar@adacore.com>
6632
6633 * exp_ch7.ads, sem_type.adb, make.adb, sem_prag.adb, sem_util.adb,
6634 sem_util.ads, sem_attr.adb, restrict.ads, sem_ch6.adb, prj-conf.adb,
6635 prj-conf.ads, s-atocou.ads, s-atocou.adb, s-atocou-x86.adb,
6636 s-atocou-builtin.adb: Minor reformatting.
6637
406935b6
AC
66382011-08-05 Yannick Moy <moy@adacore.com>
6639
6640 * exp_ch7.adb (Establish_Transient_Scope): in formal verification mode,
6641 if the node to wrap is a pragma check, this node and enclosed
6642 expression are not expanded, so do not apply any transformations here.
6643 * exp_prag.adb (Expand_Pragma_Check): document the need to avoid
6644 introducing transient scopes.
6645
66462011-08-05 Jose Ruiz <ruiz@adacore.com>
6647
6648 * adaint.c (__gnat_set_writable, __gnat_set_readable,
6649 __gnat_set_executable, __gnat_set_non_writable, __gnat_set_non_readable,
6650 __gnat_copy_attribs): On VxWorks 6.x and later, the required chmod
6651 routine is available, so we use the default implementation of these
6652 functions.
6653 * s-os_lib.ads (Copy_File, Copy_Time_Stamps): Document that there is
6654 support for copying attributes on VxWorks 6.
6655
66562011-08-05 Yannick Moy <moy@adacore.com>
6657
6658 * debug.adb: Remove use of -gnatd.D.
6659 * gnat1drv.adb (Adjust_Global_Switches): adjust switches for ALFA mode
6660 * opt.ads: Simplify variables for ALFA mode, to keep one only
6661 * restrict.adb, sem_prag.adb: Adapt treatment done for CodePeer mode
6662 to ALFA mode.
6663
66642011-08-05 Vincent Celier <celier@adacore.com>
6665
6666 * prj-conf.adb (Do_Autoconf): Look also for --RTS in
6667 Builder'Default_Switches.
6668
66692011-08-05 Vincent Celier <celier@adacore.com>
6670
6671 * makeusg.adb: Add lines for --create-map-file switches.
6672
66732011-08-05 Ed Schonberg <schonberg@adacore.com>
6674
6675 * freeze.adb (Freeze_Entity): For a subprogram, if a type in the
6676 profile is incomplete and the full view is available, replace it with
6677 the full view.
6678 * sem_ch6.adb (Possible_Freeze): if a type in the profile is
6679 incomplete, freezing the subprogram is delayed until the full view is
6680 frozen.
6681 * sem_type.adb (Disambiguate): an ambiguity between a user-defined
6682 fixed-point multiplication operator and the predefined operator is
6683 resolved in favor of the user-defined one.
6684
96c891b3
RO
66852011-08-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6686
6687 * init.c [__alpha__ && __osf__] (__gnat_error_handler): Use
6688 CONST_CAST.
6689
276e7ed0
AC
66902011-08-04 Ed Schonberg <schonberg@adacore.com>
6691
6692 * sem_util.ads, sem_unit.adb (Type_Without_Stream_Operation): determine
6693 whether a type lacks user-defined Read or Write operations, or has a
6694 component that lacks them.
6695 * sem_attr.adb (Check_Stream_Attribute): if restriction
6696 No_Default_Stream_Attributes is active, verify that all subcomponent
6697 types of the target have user-defined stream operations, and report
6698 error otherwise.
6699 * exp_ch3.adb (Stream_Operqtion_OK): use Type_Without_Stream_Operation.
6700 * exp_strm.adb: Build_Elementary_Input_Call,
6701 Build_Elementary_Write_Call): remove checks for restriction
6702 No_Default_Stream_Attributes, now checked in semantics.
6703
67042011-08-04 Vincent Celier <celier@adacore.com>
6705
6706 * prj-conf.ads, prj-conf.adb (Do_Autoconf): If there is no --RTS
6707 switches on the command line, look for all valid --RTS switches in the
6708 Builder switches and for each language use the first runtime name found
6709 to invoke gprconfig.
6710 (Get_Or_Create_Configuration_File): Warn if --RTS is specified on the
6711 command line and there is no auto-configuration.
6712 (Runtime_Name_Set_For): New function.
6713
67142011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6715
6716 * exp_ch7.adb (Build_Object_Declarations): Do not generate the
6717 elaborate initialization expression for variable Abort when processing
6718 a package body or a declaration.
6719 (Create_Finalizer): Propagate the package context when creating the
6720 exception-related variables.
6721 * exp_ch7.ads (Build_Object_Declarations): New formal parameter
6722 For_Package along with usage comment.
6723
19172ae9
AC
67242011-08-04 Arnaud Charlet <charlet@adacore.com>
6725
6726 * gcc-interface/Makefile.in: Clean up targets.
6727 Enable new package for atomic counters and copy-on-write implementation
6728 of unbounded strings on x86 platforms.
6729 * gcc-interface/Make-lang.in: Update dependencies.
6730
0319cacc
AC
67312011-08-04 Robert Dewar <dewar@adacore.com>
6732
6733 * exp_ch7.adb: Minor reformatting.
6734
67352011-08-04 Robert Dewar <dewar@adacore.com>
6736
6737 * exp_strm.adb: Minor reformatting.
6738
67392011-08-04 Vadim Godunko <godunko@adacore.com>
6740
6741 * s-atocou.adb: Replace by dummy version and use on targets where atomic
6742 operations are not supported.
6743 * s-atocou-builtin.adb: Renamed from s-atocou.adb.
6744 * s-atocou-x86.adb: New file.
6745 * Makefile.rtl: Add s-atocou.o file
6746
67472011-08-04 Arnaud Charlet <charlet@adacore.com>
6748
6749 * make.adb (Compile): Move setting of CodePeer_Mode to ...
6750 (Compilation_Phase): ... here.
6751 (Scan_Make_Arg): Now bind and link by default in CodePeer mode.
6752
67532011-08-04 Thomas Quinot <quinot@adacore.com>
6754
6755 * Make-generated.in: Fix minor typo in comment.
6756
26e7e1a0
AC
67572011-08-04 Thomas Quinot <quinot@adacore.com>
6758
6759 * gnatls.adb: Use Prj.Env.Initialize_Default_Project_Path to retrieve
6760 the project path.
6761
67622011-08-04 Robert Dewar <dewar@adacore.com>
6763
6764 * a-coinho.adb: Minor reformatting.
6765
67662011-08-04 Robert Dewar <dewar@adacore.com>
6767
6768 * a-coinho.ads: Minor reformatting.
6769
67702011-08-04 Vadim Godunko <godunko@adacore.com>
6771
6772 * s-atocou.ads, s-atocou.adb: New files.
6773 * a-strunb-shared.ads, a-strunb-shared.adb, a-stwiun-shared.ads,
6774 a-stwiun-shared.adb, a-stzunb-shared.ads, a-stzunb-shared.adb: Remove
6775 direct use of GCC's atomic builtins and replace them by use of new
6776 atomic counter package.
6777
67782011-08-04 Ed Schonberg <schonberg@adacore.com>
6779
6780 * exp_strm.adb: better error message for No_Default_Stream_Attributes.
6781
67822011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6783
6784 * a-tags.adb (Unregister_Tag): Replace the complex address arithmetic
6785 with a call to Get_External_Tag.
6786 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on
6787 subprogram usage. Remove the guard against package declarations and
6788 bodies since Build_Cleanup_Statements is no longer invoked in that
6789 context.
6790 (Build_Components): Initialize Tagged_Type_Stmts when the context
6791 contains at least one library-level tagged type.
6792 (Build_Finalizer): New local variables Has_Tagged_Types and
6793 Tagged_Type_Stmts along with associated comments on usage. Update the
6794 logic to include tagged type processing.
6795 (Create_Finalizer): Insert all library-level tagged type unregistration
6796 code before the jump block circuitry.
6797 (Expand_N_Package_Body): Remove the call to Build_Cleanup_Statements.
6798 (Expand_N_Package_Declaration): Remove the call to
6799 Build_Cleanup_Statements.
6800 (Process_Tagged_Type_Declaration): New routine. Generate a call to
6801 unregister the external tag of a tagged type.
6802 (Processing_Actions): Reimplemented to handle tagged types.
6803 (Process_Declarations): Detect the declaration of a library-level
6804 tagged type and carry out the appropriate actions.
6805 (Unregister_Tagged_Types): Removed. The machinery has been directly
6806 merged with Build_Finalizer.
6807
7483c888
AC
68082011-08-04 Robert Dewar <dewar@adacore.com>
6809
6810 * bindgen.ads, gnatlink.adb, sem_ch4.adb, gnatbind.adb, put_alfa.adb,
6811 gnatls.adb, exp_ch3.adb: Minor reformatting.
6812
68132011-08-04 Marc Sango <sango@adacore.com>
6814
6815 * sem_attr.adb (Analyze_Attribute): Replace the message
6816 "invisible attribute of}" of the spark restriction violation in
6817 attribute reference by the simple message "invisible attribute of type".
6818 Indeed, the node value Error_Msg_Node_1 used is in conflit with the
6819 two insertion characters: '&' and '}'.
6820
68212011-08-04 Vadim Godunko <godunko@adacore.com>
6822
6823 * impunit.adb (Non_Imp_File_Names_12): Add "a-coinho".
6824 * a-coinho.ads, a-coinho.adb: New file.
6825 * Makefile.rtl: Add Ada.Containers.Indefinite_Holders.
6826
5207696c
AC
68272011-08-04 Nicolas Roche <roche@adacore.com>
6828
6829 * alfa_test.adb: Not all ali files are containing alfa information even
6830 if compiled with -gnatd.F. So suppress warning about missing ALFA
6831 information.
6832
68332011-08-04 Yannick Moy <moy@adacore.com>
6834
6835 * lib-xref-alfa.adb (Add_ALFA_Scope): use non-empty unique name for
6836 scope.
6837 * put_alfa.adb: Check that scope name is not empty.
6838
68392011-08-04 Ed Schonberg <schonberg@adacore.com>
6840
6841 * exp_ch3.adb (Stream_Operation_Ok): new predicate
6842 Needs_Elementary_Stream_Operation, to determine whether user-defined
6843 Read and Write attributes are available for the elementary components
6844 of the given type. If only the predefined attributes are available,
6845 then when restriction No_Default_Stream_Attributes is active the
6846 predefined stream attributes for the composite type cannot be created.
6847
68482011-08-04 Robert Dewar <dewar@adacore.com>
6849
6850 * bindgen.adb: Fix obsolete comments and names from Ada/C days.
6851 Put routines in alpha order
6852
2bd2d858
JR
68532011-08-04 Jose Ruiz <ruiz@adacore.com>
6854
6855 * gcc-interface/Makefile.in: Remove xenomai specific versions of system.
6856 * gcc-interface/Make-lang.in: Update dependencies.
6857
8fae6016
AC
68582011-08-04 Arnaud Charlet <charlet@adacore.com>
6859
6860 * gcc-interface/lang.opt: Add AdaWhy language, simimlar to Ada.
6861 * gcc-interface/lang-specs.h: Add handling of AdaWhy specs (calls
6862 gnat1why).
6863
a54d0eb4
AC
68642011-08-04 Robert Dewar <dewar@adacore.com>
6865
6866 * sem_ch3.adb, make.adb, a-cohata.ads, sem_prag.adb, makeutl.adb,
6867 lib-xref-alfa.adb: Minor reformatting.
6868
68692011-08-04 Marc Sango <sango@adacore.com>
6870
6871 * sem_ch12.adb (Analyze_Generic_Package_Declaration,
6872 Analyze_Generic_Subprogram_Declaration, Analyze_Package_Instantiation,
6873 Analyze_Subprogram_Instantiation): Check absence of generic in SPARK
6874 mode.
6875
68762011-08-04 Tristan Gingold <gingold@adacore.com>
6877
6878 * bindgen.adb (Gen_Adainit_C): Remove.
6879 (Gen_Adafinal_C): Ditto.
6880 (Gen_Elab_Externals_C): Ditto.
6881 (Gen_Elab_Calls_C): Ditto.
6882 (Gen_Elab_Order_C): Ditto.
6883 (Gen_Elab_Defs_C): Ditto.
6884 (Gen_Finalize_Library_C): Ditto.
6885 (Gen_Finalize_Library_Defs_C): Ditto.
6886 (Gen_Main_C): Ditto.
6887 (Gen_Output_File_C): Ditto.
6888 (Gen_Restrictions_C): Ditto.
6889 (Gen_Versions_C): Ditto.
6890 (Write_Info_Ada_C): Ditto.
6891 (Gen_Object_Files_Options): Call WBI instead of Write_Info_Ada_C
6892 (Gen_Output_File): Do not force Ada_Bind_File anymore.
6893 Always call Gen_Output_File_Ada.
6894 * gnatlink.adb (Begin_Info): Now a constant.
6895 (End_Info): Ditto.
6896 (Ada_Bind_File): Remove
6897 (Process_Args): Do not handle -A/-C. Remove not Ada_Bind_File cases.
6898 * switch-b.adb (Scan_Binder_Switches): Do not handle -C.
6899 * gnatbind.adb (Gnatbind): Remove not Ada_Bind_File cases.
6900 * opt.ads (Ada_Bind_File): Remove.
6901
69022011-08-04 Thomas Quinot <quinot@adacore.com>
6903
6904 * projects.texi: Document target-specific directory in default project
6905 path for gnatmake.
6906
69072011-08-04 Thomas Quinot <quinot@adacore.com>
6908
6909 * gnatls.adb, prj-env.adb: Add $prefix/share/gpr to default project
6910 path in all cases .
6911
24558db8
AC
69122011-08-04 Yannick Moy <moy@adacore.com>
6913
6914 * sem_ch3.adb, sem_ch5.adb, sem_util.adb, sem_ch4.adb, sem_ch8.adb,
6915 opt.ads, lib-xref.ads: Code clean up.
6916
69172011-08-04 Yannick Moy <moy@adacore.com>
6918
6919 * gnat_rm.texi: Update description of Test_Case
6920 * gnat_ugn.texi: Typo.
6921
69222011-08-04 Ed Falis <falis@adacore.com>
6923
6924 * adaint.c (__gnat_get_number_of_cpus): fix typo in last checkin.
6925
69262011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
6927
6928 * exp_ch4.adb (Suitable_Element): Skip field _parent on .NET/JVM when
6929 it is of type Root_Controlled. This action eliminates fields Prev and
6930 Next from type equality.
6931
69322011-08-04 Yannick Moy <moy@adacore.com>
6933
6934 * lib-xref-alfa.adb: Correct typo.
6935
69362011-08-04 Matthew Heaney <heaney@adacore.com>
6937
6938 * a-cohata.ads (Hash_Table_Type): default-initialize the Nodes
6939 component.
6940
1f9939b5
AC
69412011-08-04 Yannick Moy <moy@adacore.com>
6942
6943 * sem_prag.adb (Check_Arg_Is_String_Literal): remove useless procedure
6944 (Analyze_Pragma): allow static string expression for name of Test_Case,
6945 instead of simply string literals.
6946 * sem_util.adb (Get_Name_From_Test_Case_Pragma): adapt to static string
6947 expressions.
6948
69492011-08-04 Vincent Celier <celier@adacore.com>
6950
6951 * makeutl.adb (Complete_Mains.Find_File_Add_Extension): Use canonical
6952 case suffixes to find truncated main sources.
6953
69542011-08-04 Tristan Gingold <gingold@adacore.com>
6955
6956 * impunit.adb (Non_Imp_File_Names_95): Add g-tastus.
6957 s-stusta.adb (Compute_All_Task): Use Put_Line instead of Put.
6958 (Compute_Current_Task): Ditto.
6959
69602011-08-04 Tristan Gingold <gingold@adacore.com>
6961
6962 * gnat_ugn.texi: Mention GNAT.Task_Stack_Usage.
6963
69642011-08-04 Yannick Moy <moy@adacore.com>
6965
6966 * lib-xref-alfa.adb (Is_Global_Constant): new function that detects
6967 library-level constant.
6968 (Add_ALFA_Xrefs): ignore global constants in ALFA xref.
6969 * sem_res.adb (Resolve_Actuals): do not add cross-reference to Formal
6970 used as selector of parameter association, in ALFA mode.
6971
15d8a51d
AC
69722011-08-04 Robert Dewar <dewar@adacore.com>
6973
6974 * exp_ch5.adb, exp_ch7.adb, exp_util.adb, bindgen.adb, sem_prag.adb,
6975 s-tassta.adb, exp_ch4.adb, exp_disp.adb, s-stausa.adb: Minor
6976 reformatting.
6977
69782011-08-04 Arnaud Charlet <charlet@adacore.com>
6979
6980 * make.adb (Linking_Phase): Set source search path before calling
6981 gnatlink in CodePeer mode.
6982
f46faa08
AC
69832011-08-04 Javier Miranda <miranda@adacore.com>
6984
6985 * exp_ch7.adb (Expand_N_Package_Body, Expand_N_Package_Declaration):
6986 Remove code which takes care of building TSDs.
6987 * rtsfind.ads (RE_Check_Interface_Conversion): New entity.
6988 * exp_ch4.adb (Apply_Accessibility_Check): Add support for generating
6989 the accessibility check in VM targets.
6990 * exp_disp.adb (Make_VM_TSD): Spec moved to exp_disp.ads
6991 (Building_Static_DT): Now returns false for VM targets.
6992 (Build_VM_TSDs): Removed.
6993 (Expand_Interface_Conversion): Generate missing runtime check for
6994 conversions to interface types whose target type is unknown at compile
6995 time.
6996 (Make_VM_TSD): Add missing code to disable the generation of calls to
6997 Check_TSD if the tagged type is not defined at library level, or not
6998 has a representation clause specifying its external tag, or -gnatdQ is
6999 active.
7000 * exp_disp.ads (Build_VM_TSDs): Removed.
7001 (Make_VM_TSDs): Spec relocated from exp_disp.adb
7002 * sem_disp.adb (Check_Dispatching_Operation): No code required to
7003 register primitives in the dispatch tables in VM targets.
7004 * exp_ch3.adb (Expand_N_Object_Declaration): Remove wrong expansion of
7005 initialization of class-wide interface objects in VM targets.
7006 (Expand_Freeze_Record_Type): For VM targets call Make_VM_TSD (instead
7007 of Make_DT).
7008
70092011-08-04 Jerome Lambourg <lambourg@adacore.com>
7010
7011 * gnatlink.adb (Gnatlink): Correct missleading error message displayed
7012 when dotnet-ld cannot be found.
7013
70142011-08-04 Arnaud Charlet <charlet@adacore.com>
7015
7016 * bindgen.adb: Simplify significantly generation of binder body file in
7017 CodePeer mode.
7018 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Prevent assert failure
7019 when compiling binder generated file in CodePeer mode (xxx'Elab_Spec
7020 not expanded).
7021
2ba7e31e
AC
70222011-08-04 Yannick Moy <moy@adacore.com>
7023
7024 * sem_prag.adb, sem.ads: Code cleanup.
7025
70262011-08-04 Tristan Gingold <gingold@adacore.com>
7027
7028 * s-tassta.adb (Task_Wrapper): Rewrite the dynamic stack usage part.
7029 * s-stausa.adb, s-stausa.ads: Major rewrite. Now provides accurate
7030 results if possible.
7031 * s-stusta.adb (Print): Adjust after changes in s-stausa.
7032 * gnat_ugn.texi: Update dynamic stack usage section.
7033
70342011-08-04 Steve Baird <baird@adacore.com>
7035
7036 * bindgen.adb (Gen_CodePeer_Wrapper): new procedure.
7037 Generate (if CodePeer_Mode is set) a "wrapper" subprogram which
7038 contains only a call to the user-defined main subprogram.
7039 (Gen_Main_Ada) - If CodePeer_Mode is set, then
7040 call the "wrapper" subprogram instead of directly
7041 calling the user-defined main subprogram.
7042
70432011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7044
7045 * exp_ch5.adb (Expand_N_Case_Statement): Check the statements of all
7046 alternatives of a case statement for controlled objects. Rename local
7047 variable A to Dead_Alt.
7048 (Expand_N_If_Statement): Check the then and else statements of an if
7049 statement for controlled objects. Check the then statements of all
7050 elsif parts of an if statement for controlled objects.
7051 (Expand_N_Loop_Statement): Check the statements of a loop for controlled
7052 objects.
7053 * exp_ch7.adb (Process_Transient_Objects): Rewrite the condition which
7054 detects a loop associated with the expansion of an array object.
7055 Augment the processing of the loop statements to account for a possible
7056 wrap done by Process_Statements_For_Controlled_Objects.
7057 * exp_ch9.adb (Expand_N_Asynchronous_Select): Check the triggering
7058 statements and abortable part of an asynchronous select for controlled
7059 objects.
7060 (Expand_N_Conditional_Entry_Call): Check the else statements of a
7061 conditional entry call for controlled objects.
7062 (Expand_N_Selective_Accept): Check the alternatives of a selective
7063 accept for controlled objects.
7064 (Expand_N_Timed_Entry_Call): Check the entry call and delay
7065 alternatives of a timed entry call for controlled objects.
7066 * exp_ch11.adb (Expand_Exception_Handlers): Check the statements of an
7067 exception handler for controlled objects.
7068 * exp_util.adb (Requires_Cleanup_Actions (List_Id, Boolean, Boolean)):
7069 Add formal parameter Nested_Constructs along with its associated
7070 comment.
7071 (Requires_Cleanup_Actions (Node_Id)): Update all calls to
7072 Requires_Cleanup_Actions.
7073 (Process_Statements_For_Controlled_Objects): New routine.
7074 * exp_util.ads (Process_Statements_For_Controlled_Objects): New
7075 routine. Inspect a node which contains a non-handled sequence of
7076 statements for controlled objects. If such an object is found, the
7077 statements are wrapped in a block.
7078
1bf773bb
AC
70792011-08-04 Bob Duff <duff@adacore.com>
7080
7081 * sem_type.adb (Covers): If T2 is a subtype of a class-wide type, we
7082 need to compare with Class_Wide_Type (T2), in order to get at the
7083 original class-wide type node.
7084 * sem_type.ads (Covers): Improve the comment.
7085 * einfo.ads (Class_Wide_Type): Improve the comment.
7086 * exp_intr.adb (Expand_Unc_Deallocation): Remove unnecessary setting of
7087 the type of the Deref.
7088
70892011-08-04 Yannick Moy <moy@adacore.com>
7090
7091 * gnat_rm.texi: Document that Test_Case pragma can only appear on
7092 separate declarations.
7093 * sem_prag.adb (procedure Check_Identifier_Is_One_Of): new procedure to
7094 check identifier of pragma argument.
7095 (Chain_TC): check that no other test case associated to the same entity
7096 share the same name.
7097 (Check_Test_Case): disallow test case inside subprogram body
7098 (Analyze_Pragma): correct call to check identifier and not argument
7099 * sem_util.adb, sem_util.ads (Get_Name_From_Test_Case_Pragma): new
7100 function gets name from test case pragma.
7101
dac3bede
YM
71022011-08-04 Yannick Moy <moy@adacore.com>
7103
7104 * gnat_rm.texi: Document new pragma and aspect.
7105 * aspects.adb, aspects.ads (Aspect_Id): new value Aspect_Test_Case
7106 (No_Duplicates_Allowed): new constant array defining whether duplicates
7107 aspects of each kind can appear on the same declaration.
7108 * einfo.adb, einfo.ads (Spec_PPC_List): replace field with Contract
7109 field, which points to a node holding the previous Spec_PPC_List.
7110 * exp_ch9.adb, sem_ch6.adb, sem_prag.adb: Reach to Spec_PPC_List
7111 through the indirection with Contract.
7112 * exp_util.adb (Insert_Actions): raise Program_Error on N_Contract node
7113 * par-prag.adb (Prag): do nothing on Test_Case pragma
7114 * sem.adb (Analyze): abort on N_Contract, on which Analyze should not
7115 be called directly.
7116 * sem_attr.adb (Analyze_Attribute): allow attribute 'Result in
7117 component Ensures of Test_Case.
7118 * sem_ch12.adb, sem_ch6.adb, sem_ch9.adb
7119 (Analyze_Generic_Subprogram_Declaration,
7120 Analyze_Subprogram_Instantiation,
7121 Analyze_Abstract_Subprogram_Declaration,
7122 Analyze_Subprogram_Body_Helper,
7123 Analyze_Subprogram_Specification, Analyze_Entry_Declaration):
7124 insert contract in subprogram node at point of definition
7125 * sem_ch13.adb
7126 (Aspect_Loop): do not raise error on duplicate Test_Case aspect
7127 (Analyze_Aspect_Specifications): analyze Test_Case aspect and create
7128 corresponding pragma
7129 (Check_Aspect_At_Freeze_Point): raise Program_Error on Test_Case aspect
7130 * sem_ch3.adb (Analyze_Declarations): insert analysis of test-cases,
7131 similar to the analysis of pre/post
7132 (Derive_Subprogram): insert contract in subprogram node at point of
7133 derivation.
7134 * sem_prag.adb, sem_prag.ads
7135 (Check_Arg_Is_String_Literal, Check_Identifier):
7136 new checking procedures to be called in treatment of pragmas
7137 (Check_Test_Case): new procedure to check that a Test_Case aspect or
7138 pragma is well-formed. This does not check currently that 'Result is
7139 used only in the Ensures component of a Test_Case.
7140 (Analyze_Pragma): add case for Test_Case
7141 (Analyze_TC_In_Decl_Part): pre-analyze the Requires and Ensures
7142 components of a Test_Case.
7143 (Preanalyze_TC_Args): new procedure to preanalyze the boolean
7144 expressions in the 3rd (and 4th if present) arguments of a Test_Case
7145 pragma, treated as spec expressions.
7146 (Sig_Flags): add value -1 for Test_Case.
7147 * sem_util.adb, sem_util.ads (Get_Ensures_From_Test_Case_Pragma,
7148 Get_Requires_From_Test_Case_Pragma): getters for both expression
7149 components of a Test_Case.
7150 * sinfo.adb, sinfo.ads (N_Contract): new kind of node used as
7151 indirection between an entry or [generic] subprogram entity and its
7152 pre/post + test-cases.
7153 (Spec_PPC_List, Spec_TC_List, Set_Spec_PPC_List, Set_Spec_TC_List):
7154 get/set for fields of an N_Contract node.
7155 * snames.ads-tmpl (Name_Test_Case, Name_Ensures, Name_Mode,
7156 Name_Normal, Name_Requires, Name_Robustness, Pragma_Test_Case): new
7157 names and pragma for Test_Case.
7158 * sprint.adb (Sprint_Node): raise Program_Error on N_Contract node
7159
6a2e5d0f
AC
71602011-08-04 Vincent Celier <celier@adacore.com>
7161
7162 * gnat_ugn.texi: Improve documentation of gnatmake switch
7163 --source-info-file=.
7164
71652011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7166
7167 * exp_ch7.adb (Make_Final_Call): Add local variable Atyp (assertion
7168 type). Initialize Atyp to the appropriate type which is later checked
7169 for completion. Rewrite the assertion associated with private type
7170 completion.
7171
71722011-08-04 Ed Falis <falis@adacore.com>
7173
7174 * adaint.c: Add call to vxCpuConfiguredGet for VxWorks SMP to
7175 initialize the number of CPUs.
7176
71772011-08-04 Ed Schonberg <schonberg@adacore.com>
7178
7179 * sem_type.adb (Disambiguate): New subsidiary routine
7180 In_Same_Declaration_List, to implement AI05-0020: a user-defined
7181 equality on an anonymous access type whose designated type is private
7182 does not lead to an ambiguity with the universal access equality
7183 operator in the body or child units of the defining package. The same
7184 is true for a multiplication operator on a private type completed with
7185 a fixed-point-type.
7186
71872011-08-04 Javier Miranda <miranda@adacore.com>
7188
7189 * opt.ads (Init_Or_Norm_Scalars_Config): Removed.
7190 (Normalize_Scalars_Config): Removed.
7191 * opt.adb
7192 (Register_Opt_Config_Switches): Remove registering config values of
7193 Init_Or_Norm_Scalars_Config and Normalize_Scalars_Config.
7194 (Restore_Opt_Config_Switches): Remove code which restores the values of
7195 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
7196 Init_Or_Norm_Scalars.
7197 (Save_Opt_Config_Switches): Remove code which saves values of
7198 Init_Or_Norm_Scalars and Normalize_Scalars.
7199 (Set_Opt_Config_Switches): Remove code which restores config values of
7200 Init_Or_Norm_Scalars and Normalize_Scalars. Recalculate value of
7201 Init_Or_Norm_Scalars.
7202
72032011-08-04 Yannick Moy <moy@adacore.com>
7204
7205 * frontend.adb (Frontend): remove previous patch to avoid full
7206 qualification in ALFA mode.
7207 * lib-xref-alfa.adb (Add_ALFA_Xrefs): use unique name for variables.
7208 * sem_util.adb, sem_util.ads (Unique_Name): new function to define a
7209 unique name for an entity, which could be used to identify the entity
7210 across compilation units.
7211
72122011-08-04 Thomas Quinot <quinot@adacore.com>
7213
7214 * prj-env.adb
7215 (Initialize_Default_Project_Path): Add target specific directory
7216 ($prefix/$target/lib/gnat) in front of project path in all cases
7217 (making gnatmake's behaviour consistent with gprbuild).
7218 * gnatcmd.adb, make.adb, prj-makr.adb, clean.adb:
7219 Pass target name from Sdefault to project subsystem.
7220 * gnatls.adb: Show new target specific default project directory.
7221
72222011-08-04 Johannes Kanig <kanig@adacore.com>
7223
7224 * cstand.adb: Add Information to Identifier in Standard
7225 (Identifer_For): Set Entity to the corresponding entity
7226
483361a6
AC
72272011-08-04 Sergey Rybin <rybin@adacore.com>
7228
7229 * gnat_ugn.texi: Update doc on gnatcheck.
7230
72312011-08-04 Yannick Moy <moy@adacore.com>
7232
7233 * lib-xref-alfa.adb (Add_ALFA_Xrefs): correct definition of ranges of
7234 xrefs in a scope.
7235
72362011-08-04 Yannick Moy <moy@adacore.com>
7237
7238 * exp_prag.adb (Expand_Pragma_Check): in ALFA mode, return without
7239 performing expansion.
7240 * sem_ch6.adb (Analyze_Subprogram_Body_Helper,
7241 Analyze_Generic_Subprogram_Body): protect call to Process_PCCs so that
7242 it is not called in ALFA mode.
7243
ef5569c6
AC
72442011-08-04 Emmanuel Briot <briot@adacore.com>
7245
7246 * make.adb, osint.adb, osint.ads (Reset_Command_Line_Files): not used
7247 after all, so removed.
7248
72492011-08-04 Sergey Rybin <rybin@adacore.com>
7250
7251 * vms_data.ads: Add missing VMS qualifiers.
7252
1ab4a286
EB
72532011-08-04 Emmanuel Briot <briot@adacore.com>
7254
7255 * make.adb, makeutl.adb, osint.adb, osint.ads (Check_Mains): rebuild
7256 the list of files on the command line after processing it through
7257 Complete_Mains.
7258
7ae0d98c
AC
72592011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7260
7261 * exp_ch7.adb (Build_Raise_Statement): Remove the specialized
7262 processing for .NET/JVM. These targets can now benefit from
7263 Raise_From_Controlled_Operation and they share the same processing with
7264 standard targets.
7265 (Establish_Transient_Scope): Remove the restriction for .NET/JVM.
7266 These targets need transient scopes in order to properly finalize short
7267 lived controlled objects.
7268 (Make_Handler_For_Ctrl_Operation): Remove the specialized processing for
7269 NET/JVM. These targets can now benefit from
7270 Raise_From_Controlled_Operation and they share the same processing with
7271 standard targets.
7272
72732011-08-04 Geert Bosch <bosch@adacore.com>
7274
7275 * tracebak.c (STOP_FRAME): Stop at any next pointer outside the stack
7276
72772011-08-04 Ed Schonberg <schonberg@adacore.com>
7278
7279 * exp_aggr.adb (Has_Visible_Private_Ancestor): subsidiary routine to
7280 Expand_Record_Aggregate, to determine whether aggregate must be
7281 expanded into assignments. This is the case if the ancestor part is
7282 private, regarless of the setting of the flag Has_Private_Ancestor.
7283
72842011-08-04 Ed Falis <falis@adacore.com>
7285
7286 * vxaddr2line.adb: Add support for e500v2 and for Linux hosts
7287
72882011-08-04 Bob Duff <duff@adacore.com>
7289
7290 * sinfo.ads: Fix comment.
7291
72922011-08-04 Steve Baird <baird@adacore.com>
7293
7294 * bindgen.adb (Get_Ada_Main_Name): If CodePeer_Mode is set, then
7295 choose a package name in much the same way as is
7296 done for JGNAT when VM_Target /= No_VM, except that
7297 a slightly more distinctive prefix string is used.
7298
72992011-08-04 Emmanuel Briot <briot@adacore.com>
7300
7301 * makeutl.adb (Complete_Mains): no longer accept unit names on the
7302 gnatmake command line.
7303 This behavior was never documented (and was supported only because of
7304 an early bug in the code). This case might lead to ambiguous cases
7305 (between unit names and truncated base names without suffixes).
7306
87729e5a
AC
73072011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7308
7309 * a-tags.ads, a-tags.adb (Unregister_Tag): New routine.
7310 Remove the external tag of a tagged type from the internal hash table.
7311 * exp_ch7.adb (Build_Cleanup_Statements): Update the comment on the
7312 expanded usage of the routine. Strenghten the check for Is_Master. Add
7313 processing for tagged types.
7314 (Build_Finalizer): Create all the necessary lists used in finalizer
7315 creation when the processed context is a package that may contain
7316 tagged types.
7317 (Expand_Cleanup_Actions): Rename the call to Has_Controlled_Objects to
7318 Requires_Cleanup_Actions.
7319 (Expand_N_Package_Body): Package bodies may need clean up code
7320 depending on whether they contain tagged types.
7321 (Expand_N_Package_Declaration): Package declarations may need clean up
7322 code depending on whether they contain tagged types.
7323 (Unregister_Tagged_Types): New routine. Search through a list of
7324 declarations or statements, looking for non-abstract Ada tagged types.
7325 For each such type, generate code to unregister the external tag.
7326 * exp_util.adb (Has_Controlled_Objects (Node_Id)): Renamed to
7327 Requires_Cleanup_Actions.
7328 (Requires_Cleanup_Actions (List_Id, Boolean)): New routine. Search
7329 through a list of declarations or statements looking for non-abstract
7330 Ada tagged types or controlled objects.
7331 * exp_util.ads (Has_Controlled_Objects (Node_Id)): Renamed to
7332 Requires_Cleanup_Actions.
7333 (Has_Controlled_Objects (List_Id, Boolean)): Removed.
7334 * rtsfind.ads: Add entry RE_Unregister_Tag to tables RE_Id and
7335 RE_Unit_Table.
7336
73372011-08-04 Vincent Celier <celier@adacore.com>
7338
7339 * prj-env.adb (For_All_Source_Dirs.For_Project): Check if project Prj
7340 has Ada sources, not project Project, because if the root project
7341 Project has no sources of its own, all projects will be deemed without
7342 sources.
7343
73442011-08-04 Gary Dismukes <dismukes@adacore.com>
7345
7346 * bindgen.adb (Gen_Adainit_Ada): Move the generation of the declaration
7347 of the No_Param_Proc acc-to-subp type used for initialization of
7348 __gnat_finalize_library_objects so that it's declared at library level
7349 rather than nested inside of the adainit routine.
7350
73512011-08-04 Javier Miranda <miranda@adacore.com>
7352
7353 * exp_disp.adb (Make_DT): Generate code to check the external tag ONLY
7354 if the tagged type has a representation clause which specifies its
7355 external tag.
7356
73572011-08-04 Ed Schonberg <schonberg@adacore.com>
7358
7359 * einfo.ads, einfo.adb (Has_Private_Ancestor): now a flag on types.
7360 Remove previous procedure with that name.
7361 * sem_ch3.adb (Build_Derived_Record_Type): set Has_Private_Ancestor
7362 when appropriate.
7363 * sem_aggr.adb (Resolve_Extension_Aggregate): if the ancestor part is a
7364 subtype mark, the ancestor cannot have unknown discriminants.
7365 (Resolve_Record_Aggregate): if the type has invisible components
7366 because of a private ancestor, the aggregate is illegal.
7367
73682011-08-04 Vincent Celier <celier@adacore.com>
7369
7370 * switch-m.adb (Normalize_Compiler_Switches): Recognize and take into
7371 account switches -gnat2005, -gnat12 and -gnat2012.
7372
73732011-08-04 Bob Duff <duff@adacore.com>
7374
7375 * s-tasdeb.ads: Minor comment fix.
7376
73772011-08-04 Arnaud Charlet <charlet@adacore.com>
7378
7379 * gnatlink.adb (Gnatlink): Pass -gnat83/95/05/12 switch to gcc in
7380 CodePeer mode.
7381 * switch.ads, switch.adb (Is_Language_Switch): New function.
7382
73832011-08-04 Vincent Celier <celier@adacore.com>
7384
7385 * switch-c.adb: Minor comment addition.
7386
73872011-08-04 Vincent Celier <celier@adacore.com>
7388
7389 * vms_conv.adb (Process_Argument): Fail graciously when qualifier
7390 ending with '=' is followed by a space (missing file name).
7391
73922011-08-04 Pascal Obry <obry@adacore.com>
7393
7394 * g-regist.ads: Fix size of HKEY on x86_64-windows.
7395
73962011-08-04 Ed Schonberg <schonberg@adacore.com>
7397
7398 * sem_ch12.adb (Analyze_Associations): New routine
7399 Check_Overloaded_Formal_Subprogram to reject a formal package when
7400 there is a named association or a box initialisation for an overloaded
7401 formal subprogram of the corresponding generic.
7402
74032011-08-04 Yannick Moy <moy@adacore.com>
7404
7405 * alfa.ads (ALFA_Xref_Record): add component for type of entity
7406 * get_alfa.adb, put_alfa.adb: Read and write new component of
7407 cross-reference.
7408 * lib-xref-alfa.adb (Collect_ALFA): generate new component.
7409
88f47280
AC
74102011-08-04 Pascal Obry <obry@adacore.com>
7411
7412 * urealp.adb: Minor reformatting.
7413
74142011-08-04 Tristan Gingold <gingold@adacore.com>
7415
7416 * exp_ch7.adb (build_finalizer.process_declarations.processing_actions):
7417 Handle the case when Cleanup_Protected_Object returns Empty.
7418
74192011-08-04 Yannick Moy <moy@adacore.com>
7420
7421 * frontend.adb (Frontend): only qualify names in non-ALFA mode
7422
74232011-08-04 Ed Schonberg <schonberg@adacore.com>
7424
7425 * sem_ch4.adb (Try_Class_Wide_Operation): if the context is a procedure
7426 call, ignore functions.
7427
05c53a69
GB
74282011-08-04 Geert Bosch <bosch@adacore.com>
7429
7430 * urealp.adb (Equivalent_Decimal_Exponent): Avoid the use of floating
7431 point.
7432
23cc1ace
EB
74332011-08-04 Emmanuel Briot <briot@adacore.com>
7434
7435 * makeutl.adb (Compute_Builder_Switches): no longer accept a unit name
7436 as an index for Builder'Switches. This conforms to the documentation.
7437 * make.adb (Insert_Project_Sources): avoid duplicate code
7438
cef14201
AC
74392011-08-04 Emmanuel Briot <briot@adacore.com>
7440
7441 * makeutl.adb (Complete_Mains): if the user has passed a relative file
7442 name on the command line (for instance "../dummy"), never assume it can
7443 be a unit name.
7444
74452011-08-04 Tristan Gingold <gingold@adacore.com>
7446
7447 * bindgen.adb: Remove code the reference or create the
7448 Break_Start/__gnat_break_start procedure.
7449 * s-stalib.adb (Break_Start): Removed.
7450
e2fee30d
EB
74512011-08-04 Emmanuel Briot <briot@adacore.com>
7452
7453 * make.adb, makeutl.adb, makeutl.ads (Compute_Builder_Switches): now
7454 shared with gprbuild.
7455
2d395256
AC
74562011-08-04 Yannick Moy <moy@adacore.com>
7457
7458 * par-ch4.adb (P_Primary): preferentially issue an error message about
7459 a missing parenthesis arount a conditional or case expression in Ada
7460 2012 mode, if we detect that the alignment is not correct for a
7461 statement.
7462
74632011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7464
7465 * exp_ch7.adb (Process_Declarations): Do not consider the result of a
7466 tag-to-class-wide conversion as needing finalization actions.
7467 * exp_util.adb (Has_Controlled_Objects): Do not consider the result of
7468 a tag-to-class-wide conversion as needing finalization actions.
7469 (Is_Finalizable_Transient): The result of a tag-to-class-wide
7470 conversion does not need finalization actions.
7471 (Is_Tag_To_CW_Conversion): New routine.
7472 * exp_util.ads (Is_Tag_To_CW_Conversion): New routine. Determines
7473 whether an object is the result of a tag-to-class-wide conversion.
7474
74752011-08-04 Yannick Moy <moy@adacore.com>
7476
7477 * sem_ch13.adb (Analyze_Aspect_Specifications): correct order in which
7478 the left-hand-side and right-hand-side of a conjunct are inserted when
7479 translating a pre- or postcondition
7480 * sem_ch6.adb: Correct typo in comment
7481
74822011-08-04 Ed Schonberg <schonberg@adacore.com>
7483
7484 * gnat_rm.texi: Ravenscar does not prohibit dependence on
7485 Unchecked_Conversion and Unchecked_Deallocation.
7486
74872011-08-04 Thomas Quinot <quinot@adacore.com>
7488
7489 * make.adb: Minor reformatting.
7490
767ab2fd
EB
74912011-08-04 Emmanuel Briot <briot@adacore.com>
7492
7493 * prj.adb, prj.ads, makeutl.adb (Complete_Mains): search for the
7494 sources in the project and its imported projects, but not in the whole
7495 tree.
7496
8fb3f5df
AC
74972011-08-04 Emmanuel Briot <briot@adacore.com>
7498
7499 * make.adb: Remove debug trace.
7500
75012011-08-04 Vincent Celier <celier@adacore.com>
7502
7503 * makeutl.adb (Do_Complete): Get the absolute path name of a relative
7504 path in canonical form, to be able to compare path names on platforms
7505 such as Windows or Darwin.
7506
75072011-08-04 Thomas Quinot <quinot@adacore.com>
7508
7509 * par_sco.adb (Traverse_Declarations_Or_Statements.Set_Statement_Entry):
7510 For a pragma (statement with C1 = 'P'), record the sloc of the pragma.
7511 * scos.ads: Update documentation accordingly.
7512 * put_scos.adb (Output_SCO_Line): Omit statement SCOs for disabled
7513 pragmas.
7514
9515740f
AC
75152011-08-04 Ed Schonberg <schonberg@adacore.com>
7516
7517 * sem_attr.adb (Bad_Attribute_For_Predicate): flag illegal use of
7518 attribute only if prefix type is scalar.
7519
75202011-08-04 Emmanuel Briot <briot@adacore.com>
7521
7522 * make.adb, makeutl.adb, prj-env.adb (Check_Mains): put back support
7523 in gnatmake for specifying mains on the command line that do not belong
7524 to the main project. These mains must currently all belong to the same
7525 project, though.
7526 (Ultimate_Extension_Of): removed, since duplicated
7527 Ultimate_Extending_Project.
7528
92966893
AC
75292011-08-04 Arnaud Charlet <charlet@adacore.com>
7530
7531 * make.adb (Do_Codepeer_Globalize_Step): Removed. Use CodePeer_Mode
7532 instead.
7533 (CodePeer_Mode_String): New.
7534 (Linking_Phase, Binding_Phase): Call gnatlink with -P switch in
7535 CodePeer mode.
7536 (Scan_Make_Arg): Do not disable binding/linking phase in CodePeer mode.
7537 * bindgen.adb (Gen_Elab_Calls_Ada): Ignore subprograms in CodePeer
7538 mode, since no useful elaboration subprogram is needed by CodePeer.
7539 * gnatlink.adb (Gnatlink): Add support for -P switch (CodePeer mode).
7540 In this mode, compile binder file with -gnatC and do stop after this
7541 step.
7542
75432011-08-04 Vincent Celier <celier@adacore.com>
7544
7545 * exp_ch7.adb: Minor comment fix.
7546
5969611f
RD
75472011-08-04 Robert Dewar <dewar@adacore.com>
7548
7549 * exp_ch7.adb, make.adb, sem_ch10.adb, bindgen.adb, sem_res.adb,
7550 exp_ch4.adb, makeutl.adb: Minor reformatting.
7551
6367dd30
AC
75522011-08-04 Emmanuel Briot <briot@adacore.com>
7553
7554 * make.adb, makeutl.adb, makeutl.ads (Make): major refactoring.
7555 Create several new subprograms to move code out of Make. This makes the
7556 code more readable, removes code duplication, and is a preparation work
7557 for adding support for aggregate projects.
7558
75592011-08-04 Tristan Gingold <gingold@adacore.com>
7560
7561 * s-po32gl.ads, s-po32gl.adb: New files.
7562 * exp_ch7.ads (Get_Global_Pool_For_Access_Type): New function.
7563 * exp_ch7.adb (Get_Global_Pool_For_Access_Type): New function.
7564 (Build_Finalization_Collection): Use it.
7565 * exp_ch4.adb (Complete_Controlled_Allocation): Ditto.
7566 * rtsfind.ads: System_Pool_32_Global, Re_Global_Pool_32_Object: New
7567 literals.
7568 * gcc-interface/Makefile.in: Use s-po32gl.o on VMS.
7569 * gcc-interface/Make-lang.in: Update dependencies.
7570
cd8bfe35
EB
75712011-08-04 Emmanuel Briot <briot@adacore.com>
7572
7573 * makeutl.adb (Complete_Mains): add support for specs with no suffix on
7574 the command line.
7575
7db29ea7
EB
75762011-08-04 Emmanuel Briot <briot@adacore.com>
7577
7578 * make.adb, makeutl.adb (Complete_Mains): if a main specified on the
7579 command line is not a file name, also check whether it could be a unit
7580 name.
7581
d9b056ea
AC
75822011-08-04 Eric Botcazou <ebotcazou@adacore.com>
7583
7584 * bindgen.adb (Gen_Finalize_Library_Ada): Factor out code to generate
7585 the header of the finalization routine.
7586 If the unit has no finalizer but is a body whose spec has one, then
7587 generate the decrement of the elaboration entity only.
7588 If the unit has a finalizer and is a spec, then do not generate the
7589 decrement of the elaboration entity.
7590 (Gen_Finalize_Library_C): Likewise.
7591
75922011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7593
7594 * exp_ch7.adb (Alignment_Of): New subsidiary routine.
7595 (Bounds_Size_Expression): Removed.
7596 (Double_Alignment_Of): New subsidiary routine.
7597 (Make_Finalize_Address_Stmts): New local variable Index_Typ. Account
7598 for a hole in the dope vector of unconstrained arrays due to different
7599 index and element alignments.
7600
76012011-08-04 Ed Schonberg <schonberg@adacore.com>
7602
7603 * sem_res.adb (Resolve_Allocator): diagnose task allocator that will
7604 raise program_error because body has not been seen yet.
7605
76062011-08-04 Ed Schonberg <schonberg@adacore.com>
7607
7608 * sem_ch10.adb (Analyze_With_Clause): Protect against child unit with
7609 an unresolved name.
7610
76112011-08-04 Vincent Celier <celier@adacore.com>
7612
7613 * makeutl.adb (Do_Complete): Check absolute paths in canonical forms
7614
76152011-08-04 Yannick Moy <moy@adacore.com>
7616
7617 * alfa.adb, alfa.ads (Unique_Defining_Entity): move function from here
7618 * sem_util.adb, sem_util.ads (Unique_Defining_Entity): ...to here
7619
76202011-08-04 Thomas Quinot <quinot@adacore.com>
7621
7622 * sem_ch12.adb (Analyze_Package_Instantiation): Do not omit body for
7623 instantiation in RCI.
7624
76252011-08-04 Emmanuel Briot <briot@adacore.com>
7626
7627 * make.adb: Share more code with gprbuild
7628
f5fc5b9d
AC
76292011-08-04 Emmanuel Briot <briot@adacore.com>
7630
7631 * projects.texi: Added documentation for the IDE'Gnat project file
7632 attribute.
7633
76342011-08-04 Nicolas Roche <roche@adacore.com>
7635
7636 * gnat_rm.texi: Minor editing.
7637
76382011-08-04 Javier Miranda <miranda@adacore.com>
7639
7640 * bindgen.adb (Gen_Adafinal_Ada): Do not differentiate the main case
7641 and the library case for VM targets.
7642 (Gen_Adainit_Ada): Likewise.
7643
76442011-08-04 Robert Dewar <dewar@adacore.com>
7645
7646 * g-altive.ads: Minor comment updates.
7647 * prj-nmsc.adb: Minor reformatting.
7648
76492011-08-04 Javier Miranda <miranda@adacore.com>
7650
7651 * opt.ads
7652 (Normalize_Scalars_Config): Value of the configuration switch set by
7653 pragma Normalize_Scalars when it appears in the gnat.adc file.
7654 (Normalize_Scalars): New field for record Config_Switches_Type. Used
7655 to save and restore settings of this pragma.
7656 * opt.adb
7657 (Register_Opt_Config_Switches, Save_Opt_Config_Switches,
7658 Restore_Opt_Config_Switches): Add missing support for Normalize_Scalars.
7659
76602011-08-04 Vincent Celier <celier@adacore.com>
7661
7662 * gnat_ugn.texi: Document gnatlink options -M and -M=mapfile
7663
0c4683cf
AC
76642011-08-04 Arnaud Charlet <charlet@adacore.com>
7665
7666 * makeutl.adb: Minor reformatting.
7667
76682011-08-04 Olivier Hainque <hainque@adacore.com>
7669
7670 * g-altive.ads: Update comments to reflect that only the soft
7671 binding is available today.
7672
2598ee6d
RD
76732011-08-04 Robert Dewar <dewar@adacore.com>
7674
7675 * bindgen.adb, einfo.adb, sem_ch12.adb, s-tasren.adb, sem_res.adb,
7676 makeutl.adb, prj-nmsc.adb, opt.ads, prj-env.adb: Minor reformatting
7677 * gcc-interface/Make-lang.in: Update dependencies.
7678
c2db4b32
AC
76792011-08-04 Arnaud Charlet <charlet@adacore.com>
7680
7681 * prj-env.adb: Remove local debug traces.
7682
76832011-08-04 Yannick Moy <moy@adacore.com>
7684
7685 * checks.adb (Apply_Float_Conversion_Check): correct a typo where Lo_OK
7686 was used instead of Hi_OK, which could cause a read of an uninitialized
7687 value later on. Detected while working on the new warning.
7688 * exp_ch9.adb (Expand_N_Entry_Declaration): remove useless assignment
7689 to local variable.
7690 * sem_ch5.adb (Analyze_Assignment): set the last assignment component
7691 in more cases, in order to detect more unreferenced values.
7692 * sem_util.adb, sem_util.ads (Get_Enclosing_Object): return enclosing
7693 object for expression, if any.
7694
76952011-08-04 Eric Botcazou <ebotcazou@adacore.com>
7696
7697 * exp_intr.adb (Expand_Binary_Operator_Call): Look at the RM size of
7698 the operand types instead of the Esize.
7699
77002011-08-04 Steve Baird <baird@adacore.com>
7701
7702 * switch-b.adb (Scan_Binder_Switches): Add -P binder switch, used to
7703 enable CodePeer_Mode.
7704 * bindusg.adb (Display): Add help message describing -P binder switch.
7705 * gnat_ugn.texi: Document -P binder switch.
7706 * bindgen.adb (Gen_Main_Ada): If CodePeer_Mode is set, then call the
7707 user-defined main program directly.
7708 (Gen_Output_File_Ada): If CodePeer_Mode is set, generate a with of the
7709 user-defined main program in the context clause of the package body.
7710
ad05f2e9
AC
77112011-08-04 Yannick Moy <moy@adacore.com>
7712
7713 * alfa.adb, alfa.ads (Get_Entity_For_Decl): remove function, partial
7714 duplicate of Defining_Entity
7715 (Get_Unique_Entity_For_Decl): rename function into
7716 Unique_Defining_Entity
7717 * einfo.adb, einfo.ads (Is_In_ALFA, Body_Is_In_ALFA): remove flags
7718 (Formal_Proof_On): remove synthesized flag
7719 * cstand.adb, sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
7720 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_res.adb, sem_util.adb,
7721 sem_util.ads, stand.ads: Remove treatment associated to entities in ALFA
7722 * sem_prag.adb (Analyze_Pragma): remove special treatment for pragma
7723 Annotate (Formal_Proof)
7724
77252011-08-04 Emmanuel Briot <briot@adacore.com>
7726
7727 * prj-env.adb (Create_Config_Pragmas_File): fix handling of multi-unit
7728 source files with non-standard naming schemes, in imported projects
7729
756ef2a0
AC
77302011-08-04 Emmanuel Briot <briot@adacore.com>
7731
7732 * makeutl.adb (Complete_Mains): when a multi-unit source file is
7733 specified on the gprbuild command line, we need to compile all units
7734 within that file, not just the first one we find
7735 Fix error message for mains that are not found.
7736
77372011-08-04 Thomas Quinot <quinot@adacore.com>
7738
7739 * sem_ch6.adb: Update comment.
7740 * sem_ch12.adb: Minor reformatting.
7741
77422011-08-04 Bob Duff <duff@adacore.com>
7743
7744 * s-tasren.adb (Task_Do_Or_Queue): Previous code was reading
7745 Acceptor.Terminate_Alternative without locking Acceptor, which causes a
7746 race condition whose symptom is to fail to lock Parent. That, in turn,
7747 causes Parent.Awake_Count to be accessed without locking Parent, which
7748 causes another race condition whose symptom is that Parent.Awake_Count
7749 can be off by 1 (either too high or too low). The solution is to lock
7750 Parent unconditionally, and then lock Acceptor, before reading
7751 Acceptor.Terminate_Alternative.
7752
4fdebd93
AC
77532011-08-04 Arnaud Charlet <charlet@adacore.com>
7754
7755 * debug.adb: Update comment.
7756
77572011-08-04 Robert Dewar <dewar@adacore.com>
7758
7759 * par_sco.adb, exp_util.adb, make.adb, a-tags.adb, sem_prag.adb,
7760 sem_util.adb, sem_attr.adb, exp_ch4.adb, g-comlin.adb, g-comlin.ads,
7761 exp_ch6.adb: Minor reformatting.
7762
77632011-08-04 Gary Dismukes <dismukes@adacore.com>
7764
7765 * gnat_ugn.texi: Add sentence about the case of compile-time-detected
7766 checks for -gnateE.
7767
77682011-08-04 Ed Schonberg <schonberg@adacore.com>
7769
7770 * gnat_rm.texi: update Ravenscar desription to reflect Ada2012 RM.
7771
77722011-08-04 Thomas Quinot <quinot@adacore.com>
7773
7774 * sinfo.ads: Minor reformatting.
7775
77762011-08-04 Emmanuel Briot <briot@adacore.com>
7777
7778 * makeutl.adb, makeutl.ads, prj-nmsc.adb (Complete_Mains): report error
7779 even if there is no location.
7780
6aaa0587
ES
77812011-08-04 Ed Schonberg <schonberg@adacore.com>
7782
7783 * sem_res.adb, sem_ch4.adb: move check for restriction
7784 No_Task_Hierarchy to resolve_allocator.
7785
35a1c212
AC
77862011-08-04 Thomas Quinot <quinot@adacore.com>
7787
7788 * sinfo.adb, sinfo.ads, sem_prag.adb, sem_ch12.adb (Pragma_Enabled):
7789 This flag of N_Pragma nodes is not used, remove it as well as all of
7790 the associated circuitry.
7791
77922011-08-04 Javier Miranda <miranda@adacore.com>
7793
7794 * exp_disp.adb (Make_DT): Switch -gnatdQ disables the generation of the
7795 runtime check on duplicated externa tags
7796 * debug.adb Document switch -gnatdQ.
7797
77982011-08-04 Gary Dismukes <dismukes@adacore.com>
7799
7800 * a-fihema.ads: Minor typo fix.
7801
78022011-08-04 Yannick Moy <moy@adacore.com>
7803
7804 * sem_ch10.adb: Minor comment update.
7805
78062011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7807
7808 * einfo.adb: Update the node field usage to reflect the renaming of
7809 Return_Flag to Return_ Flag_Or_Transient_Decl.
7810 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl.
7811 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl.
7812 (Write_Field15_Name): Change Return_Flag to
7813 Return_Flag_Or_Transient_Decl.
7814 * einfo.ads: Rename node field Return_Flag to
7815 Return_Flag_Or_Transient_Decl. Update the associated comment and all
7816 occurrences in entities.
7817 (Return_Flag): Renamed to Return_Flag_Or_Transient_Decl. Update
7818 associated Inline pragma.
7819 (Set_Return_Flag): Renamed to Set_Return_Flag_Or_Transient_Decl. Update
7820 associated Inline pragma.
7821 * exp_ch4.ads, exp_ch4.adb (Expand_N_Expression_With_Actions): New
7822 routine.
7823 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Update the calls to
7824 Return_Flag and Set_Return_Flag.
7825 * exp_ch7.adb (Process_Declarations): Add code to recognize hook
7826 objects generated for controlled transients declared inside an
7827 Exception_With_Actions. Update the calls to Return_Flag.
7828 (Process_Object_Declaration): Add code to add a null guard for hook
7829 objects generated for controlled transients declared inside an
7830 Exception_With_Actions. Update related comment.
7831 * exp_util.adb (Has_Controlled_Objects): Add code to recognize hook
7832 objects generated for controlled transients declared inside an
7833 Exception_With_Actions. Update the calls to Return_Flag.
7834 * expander.adb (Expand): Add new case for N_Expression_With_Actions.
7835
78362011-08-04 Ed Schonberg <schonberg@adacore.com>
7837
7838 * sem_util.adb:(Wrong_Type): Improve error message on a one-element
7839 positional aggregate.
7840
78412011-08-04 Vincent Celier <celier@adacore.com>
7842
7843 * par_sco.adb (Process_Decisions.Output_Header): Check and record pragma
7844 SLOC only for pragmas.
7845
78462011-08-04 Emmanuel Briot <briot@adacore.com>
7847
7848 * projects.texi: Minor typo fix.
7849
78502011-08-04 Emmanuel Briot <briot@adacore.com>
7851
7852 * prj-nmsc.adb (Check_File): Minor change to traces, to help debugging
7853 on case-sensitive file systems.
7854
c2873f74
TQ
78552011-08-04 Thomas Quinot <quinot@adacore.com>
7856
7857 * put_scos.adb (Put_SCOs): Do not emit decision SCO for an X decision
7858 nested in a disabled pragma.
7859 * scos.ads, scos.adb, par_sco.ads, par_sco.adb: Record sloc of
7860 enclosing pragma, if any, for X decisions.
7861
78622011-08-04 Thomas Quinot <quinot@adacore.com>
7863
7864 * sem_prag.adb: Minor reformatting.
7865
46414266
VC
78662011-08-04 Vincent Celier <celier@adacore.com>
7867
7868 * a-tags.adb (Check_TSD): Avoid concatenation of strings, as it is not
7869 allowed in no run time mode.
7870
78712011-08-04 Vincent Celier <celier@adacore.com>
7872
7873 * make.adb (Check): When -gnatc is used, check for the source file
7874 inside the ALI file with a canonical case file name.
7875
afab164f
EB
78762011-08-04 Emmanuel Briot <briot@adacore.com>
7877
7878 * g-comlin.adb, g-comlin.ads (Add_Switch): Put back support for
7879 overriding the separator.
7880
fe0ec02f
AC
78812011-08-04 Robert Dewar <dewar@adacore.com>
7882
7883 * sem_aggr.adb, par_sco.adb, sem_type.adb, exp_util.adb, exp_ch9.adb,
7884 prj-nmsc.adb, sem_ch13.adb, exp_strm.adb: Minor reformatting.
7885
78862011-08-04 Robert Dewar <dewar@adacore.com>
7887
7888 * gnat_rm.texi: Minor documentation fix for pragma Annotate.
7889
78902011-08-04 Yannick Moy <moy@adacore.com>
7891
7892 * sem_attr.adb (Analyze_Attribute): add check during pre-analysis that
7893 'Result only appears in postcondition of function.
7894
78952011-08-04 Thomas Quinot <quinot@adacore.com>
7896
7897 * a-tags.adb (Check_TSD): When raising PROGRAM_ERROR for a duplicated
7898 external tag, include the value of the external tag in the exception
7899 message.
7900
0180fd26
AC
79012011-08-04 Yannick Moy <moy@adacore.com>
7902
7903 * sem_attr.adb (Result): modify error message for misplaced 'Result
7904
79052011-08-04 Sergey Rybin <rybin@adacore.com>
7906
7907 * gnat_rm.texi (pragma Annotate): Fix syntax description to make it
7908 clear that the second argument must be an identifier.
7909
79102011-08-04 Thomas Quinot <quinot@adacore.com>
7911
7912 * exp_ch9.adb (Build_Barrier_Function): When compiling with
7913 -fpreserve-control-flow, insert an IF statement on the barrier
7914 condition to ensure that a conditional branch instruction is generated.
7915
79162011-08-04 Emmanuel Briot <briot@adacore.com>
7917
7918 * prj-part.adb, prj.adb, prj.ads, prj-tree.ads
7919 (Processing_Flags.Ignore_Missing_With): new flag.
7920
79212011-08-04 Emmanuel Briot <briot@adacore.com>
7922
7923 * prj-nmsc.adb (Find_Sources, Path_Name_Of): Fix handling of
7924 Source_List_File on case-insensitive systems where the file is actually
7925 on a case-sensitive file system (NFS,...).
7926
79272011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7928
7929 * sem_ch6.adb (Analyze_Function_Return): In a rare case where a
7930 function return contains a controlled [extension] aggregate and the
7931 return statement is not part of a handled sequence of statements, wrap
7932 the return in a block. This ensures that all controlled temporaries
7933 generated during aggregate resolution will be picked up by the
7934 finalization machinery.
7935
79362011-08-04 Ed Schonberg <schonberg@adacore.com>
7937
7938 * sem_aggr.adb (Resolve_Aggregate): If aggregate has box-initialized
7939 components, freeze type before resolution, to ensure that default
7940 initializations are present for all components.
7941 * sem_res.adb (Resolve_Actuals): the designated object of an
7942 accces-to-constant type is a legal actual in a call to an
7943 initialization procedure.
7944
79452011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
7946
7947 * exp_util.adb (Extract_Renamed_Object): Add N_Type_Conversion and
7948 N_Unchecked_Type_Conversion to the possible containers of a renamed
7949 transient variable.
7950
78efd712
AC
79512011-08-04 Yannick Moy <moy@adacore.com>
7952
7953 * par-ch13.adb (Aspect_Specifications_Present): recognize
7954 "with Identifier'Class =>" as an aspect, so that a meaningful warning
7955 is issued in Strict mode.
7956 * par.adb: Fix typos in comments.
7957
79582011-08-04 Yannick Moy <moy@adacore.com>
7959
7960 * sem_attr.adb (Result): modify error message to take into account Post
7961 aspect when compiling Ada 2012 (or newer) code.
7962
79632011-08-04 Nicolas Roche <roche@adacore.com>
7964
7965 * env.c (__gnat_clearenv): Avoid use of dynamic size array in order to
2c7f9cc0 7966 remove need for GCC exceptions.
78efd712
AC
7967
79682011-08-04 Vincent Celier <celier@adacore.com>
7969
7970 * makeutl.adb (Do_Complete): Call Debug_Output with the name of the
7971 project, not the source file name.
7972 * prj.adb (Find_Sources.Look_For_Sources): If the source has been
7973 excluded, continue looking. This excluded source will only be returned
7974 if there is no other source with the same base name that is not locally
7975 removed.
7976
79772011-08-04 Ed Schonberg <schonberg@adacore.com>
7978
7979 * sem_res.adb (Resolve_Intrinsic_Operator): if the result type is
7980 private and one of the operands is a real literal, use a qualified
7981 expression rather than a conversion which is not meaningful to the
7982 back-end.
7983
0170a691
AC
79842011-08-04 Yannick Moy <moy@adacore.com>
7985
7986 * sem_ch13.adb (Aspect_Loop): when an aspect X and its classwise
7987 corresponding aspect X'Class are allowed, proceed with analysis of the
7988 aspect instead of skipping it.
7989
79902011-08-04 Tristan Gingold <gingold@adacore.com>
7991
7992 * s-flocon.adb, s-flocon.ads: Add a body for s-flocon.ads
7993 This will allow to have an Ada implementation for the subprogram.
7994
deb4f5ba
ES
79952011-08-04 Ed Schonberg <schonberg@adacore.com>
7996
7997 * sem_ch3.adb (Analyze_Full_Type_Declaration): If the declaration is a
7998 completion and aspects are present, apply them to the entity for the
7999 type which is currently the partial view, but which is the one that
8000 will be frozen.
8001 * sem_ch13.adb (Analyze_Aspect_Specifications): if the predicate
8002 applies to a partial view, indicate that the full view has predicates
8003 and delayed aspects.
8004 (Replace_Type_Reference): Handle properly predicates that apply to the
8005 full view of a private completion.
8006
fc893455
AC
80072011-08-04 Eric Botcazou <ebotcazou@adacore.com>
8008
8009 * layout.adb (Layout_Type): For composite types, do not set Esize.
8010 * freeze.adb (Set_Small_Size): Remove test on alignment and do not
8011 set Esize.
8012 (Size_Known): Look at the RM size of components instead of the Esize.
8013 (Freeze_Record_Type): Look at the RM size instead of the Esize to
8014 issue warning and activate Implicit_Packing.
8015 (Freeze_Entity): Likewise. Do not issue a warning for alias/atomic
8016 if the Esize is not known.
8017 * sem_ch13.adb (Analyze_Attribute_Definition_Clause) <Size>: Set Esize
8018 for elementary types only.
8019 (Analyze_Record_Representation_Clause): Look at the RM size instead
8020 of the Esize to issue errors.
8021 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not set Esize if it
8022 is not known.
8023 <E_Record_Type>: Look at the RM size instead of the Esize. Remove
2c7f9cc0 8024 obsolete block.
fc893455
AC
8025 Look at the RM size instead of the Esize for types if the latter is
8026 not known.
8027 (gnat_to_gnu_field): Use Known_Esize instead of Known_Static_Esize.
8028
80292011-08-04 Ed Schonberg <schonberg@adacore.com>
8030
8031 * sem_type.adb: proper handling of equality not involving anonymous
8032 access types.
8033
b37d5bc6
AC
80342011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8035
8036 * exp_ch7.adb (Create_Finalizer): Remove local variables Spec_Nod and
8037 Vis_Decls. When creating a library-level finalizer for a package spec,
8038 both the declaration and body of the finalizer are inserted either in
8039 the visible or private declarations of the package spec.
8040
80412011-08-04 Javier Miranda <miranda@adacore.com>
8042
8043 * sem_ch3.adb (Derive_Subprograms): Complete assertion to request the
8044 use of the full-view of a type when invoking Is_Ancestor.
8045 * sem_type.adb (Is_Ancestor): For consistency, when the traversal of
8046 the full-view of private parents is requested, then use also the
8047 full-view of the parent of the first derivation.
8048
7ab4d95a
AC
80492011-08-04 Tristan Gingold <gingold@adacore.com>
8050
8051 * s-taprop-vxworks.adb (Enter_Task): Use System.Float_Control.Reset
8052 instead of the locally imported procedure.
8053 * s-taprop-mingw.adb (Enter_Task): Ditto.
8054 * s-valrea.adb (Scan_Real): Ditto.
8055 * s-imgrea.adb (Set_Image_Real): Ditto.
8056 * s-flocon.ads: Make the package pure.
8057
80582011-08-04 Thomas Quinot <quinot@adacore.com>
8059
8060 * sinfo.ads, sinfo.adb (Debug_Statement, Set_Debug_Statement): Remove.
8061 * tbuild.ads, tbuild.adb (Make_Pragma): Adjust accordingly.
8062 * sinfo-cn.ads, sinfo-cn.adb (Change_Name_To_Procedure_Call_Statement):
8063 New subprogram, moved here from...
8064 * par.adb, par-ch5.adb (P_Statement_Name): ... here.
8065 * par-prag.adb (Par.Prag, case Pragma_Debug): Do not perform any
8066 rewriting of the last argument into a procedure call statement here...
8067 * sem_prag.adb (Analyze_Pragma, case Pragma_Debug): ...do it there
8068 instead.
8069
80702011-08-04 Thomas Quinot <quinot@adacore.com>
8071
8072 * par_sco.adb: Minor reformatting.
8073
51c400f5
AC
80742011-08-04 Robert Dewar <dewar@adacore.com>
8075
8076 * erroutc.adb: Minor reformatting.
8077
80782011-08-04 Thomas Quinot <quinot@adacore.com>
8079
8080 * par_sco.adb: Comment update.
8081
80822011-08-04 Tristan Gingold <gingold@adacore.com>
8083
8084 * s-flocon.ads: New file.
8085 * g-flocon.ads: Now a renaming of s-flocon.
8086 * Makefile.rtl: Add s-flocon.o
8087
6a49f110
AC
80882011-08-04 Javier Miranda <miranda@adacore.com>
8089
8090 * exp_strm.adb (Build_Array_Input_Function): if the array type is
8091 constrained, do not attempt to build a subtype of it.
8092
80932011-08-04 Yannick Moy <moy@adacore.com>
8094
8095 * errout.ads Change comments: remove 'R'M as an example where quotes
8096 are needed; add ALFA as another case where quotes are not needed
8097 * erroutc.adb (Set_Msg_Insertion_Reserved_Word): add ALFA as another
8098 case where quotes are not needed.
8099 * sem_ch11.adb, sem_ch13.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb,
8100 sem_ch5.adb, sem_ch6.adb, sem_ch9.adb, sem_prag.adb, sem_res.adb:
8101 Remove all occurrences of 'A'L'F'A
8102
81032011-08-04 Ed Schonberg <schonberg@adacore.com>
8104
8105 * sem_ch13.adb: check legality of invariant pragma.
8106
a4640a39
AC
81072011-08-04 Eric Botcazou <ebotcazou@adacore.com>
8108
8109 * bindgen.adb: Add comments.
8110
81112011-08-04 Yannick Moy <moy@adacore.com>
8112
8113 * einfo.adb, einfo.ads: Free Flag254 and make Formal_Proof_On a
8114 synthesized flag.
8115 * sem_prag.adb (Analyze_Pragma): record the pragma Annotate
8116 (Formal_Proof, On/Off) in the Rep_Item list of the current subprogram.
8117
81182011-08-04 Robert Dewar <dewar@adacore.com>
8119
8120 * exp_ch7.adb, exp_ch6.adb, sem_ch3.adb, layout.adb, sem_ch5.adb,
8121 osint-c.ads, sem_util.ads, gnat1drv.adb, targparm.ads, sem_ch6.adb,
8122 sem_ch13.adb, s-pooloc.adb: Minor reformatting.
8123
39ade2f9
AC
81242011-08-04 Thomas Quinot <quinot@adacore.com>
8125
8126 * s-pooloc.ads, s-pooglo.ads: Minor reformatting
8127
81282011-08-04 Thomas Quinot <quinot@adacore.com>
8129
8130 PR ada/47880
8131 * s-pooloc.adb (Deallocate): Fix the case of deallocating the only
8132 allocated object.
8133
81342011-08-04 Robert Dewar <dewar@adacore.com>
8135
8136 * einfo.ads, exp_ch4.adb: Minor reformatting.
8137
81382011-08-04 Jerome Lambourg <lambourg@adacore.com>
8139
8140 * back_end.ads (Gen_Or_Update_Object_File): Add more comments.
8141
7efc3f2d
AC
81422011-08-04 Ed Schonberg <schonberg@adacore.com>
8143
8144 * exp_ch4.adb (Expand_Composite_Equality): code cleanup: use component
8145 type in all cases to compute list of primitive operations, because full
8146 view may be an itype that is not attached to the list of declarations.
8147
81482011-08-04 Eric Botcazou <ebotcazou@adacore.com>
8149
8150 * bindgen.adb (Gen_Adafinal_Ada): Generate an early return if the
8151 library has already been finalized.
8152 (Gen_Adafinal_C): Likewise.
8153 (Gen_Adainit_Ada): Generate an early return if the library has
8154 already been elaborated.
8155 (Gen_Adainit_C): Likewise.
8156 (Gen_Output_File_Ada): Generate an elaboration flag.
8157 (Gen_Output_File_C): Likewise.
8158
f65df609
HK
81592011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8160
8161 * exp_ch4.adb (Expand_Allocator_Expression): Disable the generation of
8162 Set_Finalize_Address_Ptr for CodePeer because Finalize_Address was not
8163 built in the first place.
8164 (Expand_N_Allocator): Disable the generation of Set_Finalize_Address_Ptr
8165 for CodePeer because Finalize_Address was not built to begin with.
8166 * exp_ch6.adb (Make_Build_In_Place_Call_In_Allocator): Ditto.
8167
a0fb8fe8
AC
81682011-08-04 Pascal Obry <obry@adacore.com>
8169
8170 * adaint.c (__gnat_tmp_name): Use current process id to create temp
8171 filenames, this ensures unicity of filenames across processes.
8172
81732011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8174
8175 * bindgen.adb (Gen_Finalize_Library_Ada): Rename generated routine
8176 Raise_Controlled to Raise_From_Controlled_Operation. Update the
8177 signature of Raise_From_Controlled_Operation by adding flag From_Abort.
8178 Add False as the actual to From_Abort in the generated call to
8179 Raise_From_Controlled_Operation.
8180
81812011-08-04 Jerome Lambourg <lambourg@adacore.com>
8182
8183 * osint-c.ads, osint-c.adb (Set_Library_Info_Name): Move to declaration
8184 so that the ali file name can be retrieved from outside of this package.
8185 * back_end.ads, back_end.adb (Gen_Or_Update_Object_File): New method
8186 doing nothing in the general case, but used to update the object file
8187 timestamp if directly generated by the backend.
8188 * gnat1drv.adb (Gnat1drv): Make sure the object file's timestamp is set
8189 to a later time than the ali file one.
8190
9534ab17
AC
81912011-08-04 Yannick Moy <moy@adacore.com>
8192
8193 * einfo.adb, einfo.ads (Formal_Proof_On): new flag set on subprogram
8194 entities whose body contains an Annotate pragma which forces formal
8195 proof on this body.
8196 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
8197 sem_ch6.adb, sem_ch9.adb, sem_res.adb: Adapt call to
8198 Mark_Non_ALFA_Subprogram to pass in a message and node.
8199 * sem_prag.adb (Analyze_Pragma): add treatment of pragma Annotate
8200 (Forma_Proof, On) which sets the flag Formal_Proof_On in the
8201 surrounding subprogram.
8202 * sem_util.adb, sem_util.ads (Mark_Non_ALFA_Subprogram,
8203 Mark_Non_ALFA_Subprogram_Unconditional): if the subprogram being marked
8204 as not in ALFA is annotated with Formal_Proof being On, then an error
8205 is issued based on the additional parameters for message and node.
8206 * snames.ads-tmpl (Name_Formal_Proof): new name for annotation.
8207 * gcc-interface/Make-lang.in: Update dependencies.
8208
82092011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8210
8211 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Do not generate
8212 Finalize_Address when CodePeer is enabled.
8213
82142011-08-04 Pascal Obry <obry@adacore.com>
8215
8216 * adaint.c (__gnat_tmp_name): Use _tempnam() instead of tempnam() as
8217 the latter returns a pointer to a static buffer which is deallocated
8218 at the end of the routine.
8219
5c0e97dd
AC
82202011-08-04 Yannick Moy <moy@adacore.com>
8221
8222 * sem_ch3.adb (Array_Type_Declaration): move test for type in ALFA
8223 after index creation; mark unconstrained base array type generated as
8224 being in/not in ALFA as well
8225 (Make_Index): mark subtype created as in/not in ALFA
8226 * sem_ch5.adb (Analyze_Iteration_Scheme): mark entity for iterating
8227 over a loop as in/not in ALFA, depending on its type and form of loop
8228 iteration.
8229
82302011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8231
8232 * exp_ch7.adb (Build_Object_Declarations): Initialize flag Abort
8233 directly to False on .NET and JVM.
8234
7a93c64b
YM
82352011-08-04 Yannick Moy <moy@adacore.com>
8236
8237 * sem_ch3.adb (Constrain_Enumeration, Constrain_Integer): remove
8238 constraint that subtype must come from source code to be in ALFA, so
8239 that anonymous subtypes can be in ALFA too.
8240
e9a1ed9b
YM
82412011-08-04 Yannick Moy <moy@adacore.com>
8242
8243 * sem_ch3.adb (Analyze_Object_Declaration): remove obsolete addition of
8244 reference for ALFA mode.
8245 * lib-xref-alfa.adb, lib-xref.ads (Traverse_Compilation_Unit): make
8246 procedure public so as to use it from formal verification back-end.
8247
8e293fbd
AC
82482011-08-04 Jerome Lambourg <lambourg@adacore.com>
8249
8250 * g-comlin.adb (For_Each_Simple_Switch.Is_In_Config): Remove the
8251 invalid checks of the Parameter, making Remove_Switch not working
8252 correctly.
8253
82542011-08-04 Arnaud Charlet <charlet@adacore.com>
8255
8256 * targparm.ads: Update header: no run-time exception is needed on this
8257 file.
8258
82592011-08-04 Vincent Celier <celier@adacore.com>
8260
8261 * a-fihema.adb: Use System.IO instead of GNAT.IO
8262
82632011-08-04 Thomas Quinot <quinot@adacore.com>
8264
8265 * sem_ch3.adb (Access_Definition): Anonymous access to subprogram types
8266 are forbidden in Compiler_Unit mode.
8267
cfae2bed
AC
82682011-08-04 Robert Dewar <dewar@adacore.com>
8269
8270 * sem_util.adb: Minor reformatting.
8271
82722011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8273
8274 * bindgen.adb (Gen_Finalize_Library_Ada): Update the import string for
8275 library-level finalizers.
8276 (Gen_Finalize_Library_C): Update the import string for library-level
8277 finalizers.
8278 (Gen_Finalize_Library_Defs_C): Update the definition name of a
8279 library-level finalizer.
8280 * exp_ch7.adb: Remove with and use clauses for Stringt.
8281 (Create_Finalizer): Remove local variables Conv_Name, Prag_Decl,
8282 Spec_Decl. Add local variable Body_Id. The names of library-level
8283 finalizers are now manually fully qualified and are no longer external.
8284 A single name is now capable of servicing .NET, JVM and non-VM targets.
8285 Pragma Export is no longer required to provide visibility for the name.
8286 (Create_Finalizer_String): Removed.
8287 (New_Finalizer_Name): New routine which mimics New_..._Name.
8288
01f0729a
AC
82892011-08-04 Eric Botcazou <ebotcazou@adacore.com>
8290
8291 * sem_elab.adb (Check_Internal_Call_Continue): Change the type of the
8292 elaboration counter to Standard_Short_Integer.
8293 * sem_util.adb (Build_Elaboration_Entity): Likewise.
8294 * bindgen.adb (Gen_Elab_Externals_Ada): Adjust to above change.
8295 (Gen_Elab_Externals_C): Likewise.
8296
82972011-08-04 Ed Falis <falis@adacore.com>
8298
8299 * system-vxworks-arm.ads, system-vxworks-sparcv9.ads,
8300 system-vxworks-ppc.ads, system-vxworks-m68k.ads,
8301 system-vxworks-mips.ads, system-vxworks-x86.ads
8302 (Always_Compatible_Rep): set to False for all VxWorks targets.
8303
2c1b72d7
AC
83042011-08-04 Robert Dewar <dewar@adacore.com>
8305
8306 * par_sco.adb, prj-proc.adb, make.adb, bindgen.adb, prj.adb, prj.ads,
8307 makeutl.adb, makeutl.ads, prj-nmsc.adb, exp_ch5.adb, exp_ch12.adb,
8308 exp_ch7.ads, exp_util.ads, sem_util.ads, g-comlin.ads, exp_ch6.adb,
8309 exp_ch6.ads, lib-xref.ads, exp_ch7.adb, exp_util.adb, exp_dist.adb,
8310 exp_strm.adb, gnatcmd.adb, freeze.adb, g-comlin.adb, lib-xref-alfa.adb,
8311 sem_attr.adb, sem_prag.adb, sem_util.adb, sem_elab.adb, sem_ch8.adb,
8312 sem_ch11.adb, sem_eval.adb, sem_ch13.adb, sem_disp.adb, a-fihema.adb:
8313 Minor reformatting and code reorganization.
8314
83152011-08-04 Emmanuel Briot <briot@adacore.com>
8316
8317 * projects.texi: Added doc for aggregate projects.
8318
824e9320
AC
83192011-08-04 Emmanuel Briot <briot@adacore.com>
8320
8321 * prj-proc.adb, prj-nmsc.adb, prj-env.adb (Process_Declarative_Items):
8322 Add support for overriding the Project_Path in aggregate projects.
8323
83242011-08-04 Robert Dewar <dewar@adacore.com>
8325
8326 * a-cofove.ads: Minor reformatting.
8327
83282011-08-04 Hristian Kirtchev <kirtchev@adacore.com>
8329
8330 * exp_ch7.adb (Build_Adjust_Or_Finalize_Statements): Update the comment
8331 on the generated code.
8332 (Build_Finalize_Statements): Update the comment on the generated code.
8333 (Build_Initialize_Statements): Update the comment on the generated code.
8334 (Build_Object_Declarations): Add local variable Result. The object
8335 declarations are now built in sequence.
8336 * rtsfind.ads: Add RE_Exception_Occurrence_Access to tables RE_Id and
8337 RE_Unit_Table.
8338
83392011-08-04 Robert Dewar <dewar@adacore.com>
8340
8341 * checks.adb, alfa.adb, alfa.ads: Minor reformatting.
8342
83432011-08-04 Eric Botcazou <ebotcazou@adacore.com>
8344
8345 * einfo.ads (Elaboration_Entity): Document new definition and use.
8346 (Elaboration_Entity_Required): Adjust to above change.
8347 * exp_attr.adb (Expand_N_Attribute_Reference): Likewise.
8348 * exp_ch12.adb: And with and use for Snames.
8349 (Expand_N_Generic_Instantiation): Test 'Elaborated attribute.
8350 * exp_util.adb (Set_Elaboration_Flag): Likewise.
8351 * sem_attr.adb (Analyze_Attribute) <Check_Library_Unit>: Delete.
8352 <Check_Unit_Name>: Deal with N_Expanded_Name.
8353 <Attribute_Elaborated>: Extend to all unit names.
8354 * sem_elab.adb: And with and use for Uintp.
8355 (Check_Internal_Call_Continue): Adjust to Elaboration_Entity change.
8356 * sem_util.ads (Build_Elaboration_Entity): Adjust comment.
8357 * sem_util.adb (Build_Elaboration_Entity): Change type to Integer.
8358 * bindgen.adb (Gen_Elab_Externals_Ada): New local subprogram taken
8359 from Gen_Adainit_Ada.
8360 (Gen_Elab_Externals_C): Likewise, but taken from Gen_Adainit_C.
8361 (Gen_Adafinal_Ada): Remove redundant test. In the non-main program
8362 case, do not call System.Standard_Library.Adafinal; instead call
8363 finalize_library if needed.
8364 (Gen_Adafinal_C): Likewise.
8365 (Gen_Adainit_Ada): Do not set SSL.Finalize_Library_Objects in the
8366 non-main program case.
8367 (Gen_Adainit_C): Generate a couple of external declarations here.
8368 In the main program case, set SSL.Finalize_Library_Objects.
8369 (Gen_Elab_Calls_Ada): Adjust to Elaboration_Entity change.
8370 (Gen_Elab_Calls_C): Likewise.
8371 (Gen_Finalize_Library_Ada): Likewise. Skip SAL interface units.
8372 (Gen_Finalize_Library_C): Likewise. Generate a full function.
8373 (Gen_Main_C): Put back call to Ada_Final and don't finalize library
8374 objects here.
8375 (Gen_Output_File_Ada): Generate pragma Linker_Destructor for Ada_Final
8376 if -a is specified. Call Gen_Elab_Externals_Ada. Move around call to
8377 Gen_Adafinal_Ada.
8378 (Gen_Output_File_C): Generate __attribute__((destructor)) for Ada_Final
8379 if -a is specified. Call Gen_Elab_Externals_C. Remove useless couple
2c7f9cc0 8380 of external declarations. Call Gen_Finalize_Library_C.
824e9320 8381
316d9d4f
EB
83822011-08-04 Emmanuel Briot <briot@adacore.com>
8383
8384 * prj.adb, prj.ads, makeutl.adb, makeutl.ads (Complete_Mains,
8385 Compute_Compilation_Phases): new subprogram.
8386 (Builder_Data, Builder_Project_Tree_Data): new subprogram and type
8387 The number of mains as well as the various compilation phases that
8388 need to be run are now project tree specific, since various
8389 aggregated trees might have different requirements. In particular,
8390 they do not all require bind or link phases.
8391
9434c32e
EB
83922011-08-04 Emmanuel Briot <briot@adacore.com>
8393
8394 * prj.adb, prj.ads, makeutl.adb, makeutl.ads, prj-env.adb
8395 (Project_Tree_Appdata): New type.
8396 It is now possible to associate application-specific data to a project
8397 tree. In particular, this is used in the gprbuild builder to avoid a
8398 number of global tables and htables, especially now that there can be
8399 several project trees loaded at once because of aggregate projects.
8400 (Debug_Name): new procedure.
8401 * projects.texi: Clarify syntax of "**" for Source_Dirs
8402
41ba34db
EB
84032011-08-03 Emmanuel Briot <briot@adacore.com>
8404
8405 * prj.ads, makeutl.adb, makeutl.ads (Queue.Insert): now also inserts
8406 the "roots" for a main.
8407 (Fill_From_Project): add support for aggregate projects. Main units
8408 in aggregated projects are now automatically added in the list of
8409 files to build (although this fails later on in gprbuild, because
8410 these files are not using the root proejct tree, so this needs
8411 further cleanup)
8412 * gcc-interface/Make-lang.in: Update dependencies.
8413
fccd42a9
AC
84142011-08-03 Yannick Moy <moy@adacore.com>
8415
8416 * sem_ch4.adb (Analyze_Conditional_Expression): only allow boolean
8417 conditional expression in ALFA.
8418 * sem_res.adb (Resolve_Conditional_Expression): mark non-boolean
8419 expressions as not in ALFA.
8420
84212011-08-03 Robert Dewar <dewar@adacore.com>
8422
8423 * a-cofove.adb: Minor reformatting.
8424
84252011-08-03 Emmanuel Briot <briot@adacore.com>
8426
8427 * make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads
8428 (Insert_Project_Sources, Insert_withed_Sources_For): moved from the
8429 gprbuild sources.
8430 These packages are more logically placed in the Queue package, since
8431 they manipulate the queue. It is also likely that they can be adapted
8432 for gnatmake, thus sharing more code.
8433 (Finish_Program, Fail_Program): moved from the gprbuild sources, so
8434 that we could move the above.
8435
84362011-08-03 Emmanuel Briot <briot@adacore.com>
8437
8438 * errutil.adb (Finalize): clean up the list of error messages on exit.
8439 Calling this subprogram multiple times will no longer show duplicate
8440 error messages on stderr.
8441
84422011-08-03 Emmanuel Briot <briot@adacore.com>
8443
8444 * g-comlin.adb, g-comlin.ads (Set_Command_Line): ignore the parameter
8445 Getopt_Switches when we have already define a command line
8446 configuration.
8447
5e8c8e44
YM
84482011-08-03 Yannick Moy <moy@adacore.com>
8449
8450 * sem_ch11.adb (Analyze_Raise_xxx_Error): do not mark such nodes as not
8451 in ALFA. Instead, they are considered as assertions to prove.
8452 * sem_ch4.adb (Analyze_Conditional_Expression): do not always mark such
8453 nodes as not in ALFA. Instead, include conditional expressions in ALFA
8454 if they have no ELSE part, or if they occur in pre- and postconditions,
8455 where the Condition cannot have side-effects in ALFA
8456 (Analyze_Membership_Op): do not mark such nodes as not in ALFA
8457 (Analyze_Type_Conversion): do not always mark such nodes as not in ALFA.
8458 Instead, include type conversion between scalar types in ALFA.
8459 * sem_ch6.adb (Process_Formals): correctly mark a parameter in ALFA
8460 if-and-only-if its type is in ALFA.
8461
5ffe0bab
AC
84622011-08-03 Thomas Quinot <quinot@adacore.com>
8463
8464 * scos.adb, get_scos.adb, put_scos.adb
8465 New code letter for decisions: G (entry guard)
8466 * par_sco.adb
8467 (Traverse_Subprogram_Body): Rename to...
8468 (Traverse_Subprogram_Or_Task_Body): New subrpogram.
8469 (Traverse_Protected_Body): New subprogram
8470 (Traverse_Declarations_Or_Statements): Add traversal of task bodies,
8471 protected bodies and entry bodies.
8472
84732011-08-03 Yannick Moy <moy@adacore.com>
8474
8475 * einfo.adb, einfo.ads (Is_Postcondition_Proc): new flag for procedure
8476 entities with get/set subprograms, which is set on procedure entities
8477 generated by the compiler for a postcondition.
8478 * sem_ch6.adb (Process_PPCs): set new flag on postcondition procedures
8479 * alfa.adb, alfa.ads (Get_Entity_For_Decl): new function returning the
8480 entity for a declaration
8481 (Get_Unique_Entity_For_Decl): new function returning an entity which
8482 represents a declaration, so that matching spec and body have the same
8483 entity.
8484
84852011-08-03 Robert Dewar <dewar@adacore.com>
8486
8487 * a-except-2005.adb, a-cfhama.adb, a-cfhase.adb, a-cfhase.ads,
8488 a-cforma.adb, a-cforse.ads, a-cforse.adb: Minor reformatting
8489
84902011-08-03 Yannick Moy <moy@adacore.com>
8491
8492 * lib-xref-alfa.adb (Detect_And_Add_ALFA_Scope): make the subprogram
8493 library-level because retriction No_Implicit_Dynamic_Code in the
8494 front-end prevents its definition as a local subprogram
8495 (Traverse_Compilation_Unit): extract new procedure from Add_ALFA_File,
8496 for reuse in other contexts
8497 (Traverse_Declarations_Or_Statements,
8498 Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
8499 Traverse_Package_Declaration, Traverse_Subprogram_Body): make all these
8500 procedures take a callback parameter to be called on all declarations
8501 * lib-xref.ads
8502 (Traverse_All_Compilation_Units): new generic function to traverse a
8503 compilation unit and call a callback parameter on all declarations
8504
f9ad6b62
AC
85052011-08-03 Javier Miranda <miranda@adacore.com>
8506
8507 * sem_prag.adb (Process_Interface_Name): Allow duplicated export names
8508 in Java since they are always enclosed in a namespace that
8509 differentiates them, and overloaded entities are supported by the VM.
8510
85112011-08-03 Ed Schonberg <schonberg@adacore.com>
8512
8513 * checks.adb (Determine_Range): If a computed bound of an operation is
8514 outside the range of the base type of the expression, and overflow
8515 checks are enabled, the result is unknown and cannot be used for any
8516 subsequent constant folding.
8517 * sem_eval.adb (Compile_Time_Compare): if the bounds of one operand are
8518 unknown, so is the result of the comparison.
8519
85202011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8521
8522 * a-except-2005.adb (Raise_From_Controlled_Operation): Add new formal
8523 From_Abort. When finalization was triggered by an abort, propagate
8524 Standard'Abort_Signal rather than Program_Error.
8525 * a-except-2005.ads (Raise_From_Controlled_Operation): Add new formal
8526 From_Abort.
8527 * a-except.adb (Raise_From_Controlled_Operation): Add new formal
8528 From_Abort. When finalization was triggered by an abort, propagate
8529 Standard'Abort_Signal rather than Program_Error.
8530 * a-except.ads:(Raise_From_Controlled_Operation): Add new formal
8531 From_Abort.
8532 * exp_ch7.adb:(Build_Adjust_Or_Finalize_Statements): New local variable
8533 Abort_Id. Update the calls to Build_Object_Declarations and
8534 Build_Raise_Statement to include Abort_Id.
8535 (Build_Adjust_Statements): New local variable Abort_Id. Update the
8536 calls to Build_Object_Declarations and Build_Raise_Statement to include
8537 Abort_Id.
8538 (Build_Finalize_Statements): New local variable Abort_Id. Update the
8539 calls to Build_Object_Declarations and Build_Raise_Statement to include
8540 Abort_Id.
8541 (Build_Components): Create an entity for Abort_Id when exceptions are
8542 allowed on the target.
8543 (Build_Finalizer): New local variable Abort_Id.
8544 (Build_Initialize_Statements): New local variable Abort_Id. Update the
8545 calls to Build_Object_Declarations and Build_Raise_Statement to include
8546 Abort_Id.
8547 (Build_Object_Declarations): Add new formal Abort_Id. Create the
8548 declaration of flag Abort_Id to preserve the original abort status
8549 before finalization code is executed.
8550 (Build_Raise_Statement): Add new formal Abort_Id. Pass Abort_Id to
8551 runtime routine Raise_From_Controlled_Operation.
8552 (Create_Finalizer): Update the call to Build_Raise_Statement to include
8553 Abort_Id. Update the call to Build_Object_Declarations to include
8554 Abort_Id. Update the layout of the finalizer body.
8555 (Make_Handler_For_Ctrl_Operation): Add an actual for From_Abort.
8556 (Process_Transient_Objects): New local variable Abort_Id. Remove the
8557 clunky code to create all flags and objects related to
8558 exception propagation and replace it with a call to
8559 Build_Object_Declarations. Update the call to Build_Raise_Statement to
8560 include Abort_Id.
8561 * exp_ch7.ads (Build_Object_Declarations): Moved from body to spec.
8562 Add new formal Abort_Id and associated comment on its use.
8563 (Build_Raise_Statement): Add new formal Abort_Id and associated comment
8564 on its use.
8565 * exp_intr.adb (Expand_Unc_Deallocation): New local variable Abort_Id.
8566 Remove the clunky code to create all flags and objects related to
8567 exception propagation and replace it with a call to
8568 Build_Object_Declarations. Update the call to Build_Raise_Statement.
8569
85702011-08-03 Eric Botcazou <ebotcazou@adacore.com>
8571
8572 * s-tassta.adb: Fix minor typos.
8573
85742011-08-03 Robert Dewar <dewar@adacore.com>
8575
8576 * rtsfind.ads, makeutl.ads, prj.ads, prj.adb, make.adb,
8577 lib-writ.adb, makeutl.adb, s-soflin.ads, clean.adb: Minor reformatting.
8578
1cdfa9be
AC
85792011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8580
8581 * exp_ch7.adb (Create_Finalizer): Treat freeze nodes in similar fashion
8582 to packages. This ensures that the finalizer body will not end up
8583 inside the freeze node.
8584 (Process_Declarations): Add code to detect whether a freeze node has a
8585 nested finalization collection.
8586
85872011-08-03 Pascal Obry <obry@adacore.com>
8588
8589 * g-awk.adb, g-awk.ads: Make GNAT.AWK API compatible with Ada 2005.
8590 (Current_Session): Return a not null access to Session_Type.
8591 (Default_Session): Likewise.
8592
243cae0a
AC
85932011-08-03 Robert Dewar <dewar@adacore.com>
8594
8595 * a-cfdlli.adb, bindgen.adb, exp_ch4.adb, exp_ch13.adb, sem_warn.adb,
8596 exp_ch3.adb, exp_ch3.ads: Minor reformatting.
8597
85982011-08-03 Pascal Obry <obry@adacore.com>
8599
8600 * g-awk.ads: Minor comment fix.
8601
86022011-08-03 Sergey Rybin <rybin@adacore.com>
8603
8604 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
8605 the tree structure related to discriminant constraints.
8606 Original_Discriminant cannot be used any more for computing the
8607 defining name for the reference to a discriminant.
8608
86092011-08-03 Ed Schonberg <schonberg@adacore.com>
8610
8611 * sem_disp.adb (Is_Tag_Indeterminate): If the return type of the
8612 function is not visibly tagged, this is not a dispatching call and
8613 therfore is not Tag_Indeterminate, even if the function is marked as
8614 dispatching on result.
8615
f553e7bc
AC
86162011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8617
8618 * exp_ch13.adb: Add with and use clauses for Restrict and Rident.
8619 (Expand_N_Free_Statement): Add a guard to protect against run-times
8620 which do not support controlled types.
8621 * exp_ch3.adb (Expand_Freeze_Class_Wide_Type): Add a guard to protect
8622 against run-times which do not support controlled types.
8623 * exp_ch4.adb (Complete_Controlled_Allocation): Add a guard to protect
8624 against run-times which do not support controlled types.
8625 * exp_ch7.adb (Build_Finalization_Collection): Add a guard to protect
8626 against run-times which do not support controlled types.
8627 * exp_util.adb (Needs_Finalization): Code reformatting. Add a guard to
8628 protect against run-times which do not support controlled types.
8629
86302011-08-03 Eric Botcazou <ebotcazou@adacore.com>
8631
8632 * exp_intr.adb: Put back with and use clauses for Exp_Ch11.
8633 (Expand_Unc_Deallocation): Expand the AT_END handler at the very end.
8634
e4982b64
AC
86352011-08-03 Ed Schonberg <schonberg@adacore.com>
8636
8637 * exp_ch5.adb (Expand_Iterator_Loop): indicate that the cursor is
8638 modified in the source, to prevent spurious warnings when compiling
8639 with -gnatg.
8640
86412011-08-03 Thomas Quinot <quinot@adacore.com>
8642
8643 * a-except-2005.adb: Minor reformatting.
8644
86452011-08-03 Ed Schonberg <schonberg@adacore.com>
8646
8647 * sem_warn.adb (Check_One_Unit): if the only mention of a withed unit
8648 is a renaming declaration in the private part of a package, do not emit
8649 a warning that the with_clause could be moved because the renaming may
8650 be used in the body or in a child unit.
8651
86522011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8653
8654 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
8655 Propagate the Comes_From_Source attribute from the original return
8656 object to the renaming.
8657
86582011-08-03 Jose Ruiz <ruiz@adacore.com>
8659
8660 * exp_ch7.adb (Build_Raise_Statement): Do not call
8661 Raise_From_Controlled_Operation when this routine is not present in
8662 the run-time library.
8663 (Cleanup_Protected_Object, Cleanup_Task): For restricted run-time
8664 libraries (Ravenscar), tasks are non-terminating, and protected objects
8665 and tasks can only appear at library level, so we do not want
8666 finalization of protected objects nor tasks.
8667 * exp_intr.adb: Minor clarification in comment.
8668 bindgen.adb (Gen_Adainit_Ada, Gen_Main_C, Gen_Output_File_Ada,
8669 Gen_Output_File_C): Remove references to finalization of library-level
8670 objects when using restricted run-time libraries.
8671
86722011-08-03 Ed Schonberg <schonberg@adacore.com>
8673
8674 * sem_ch3.adb (Build_Discriminant_Constraints): Set
8675 Original_Discriminant only if the parent type is a generic formal.
8676
deb8dacc
HK
86772011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8678
8679 * exp_ch13.adb: Add with and use clause for Targparm;
8680 (Expand_N_Free_Statement): Prevent the generation of a custom
8681 Deallocate on .NET/JVM targets since this requires pools and address
8682 arithmetic.
8683 * exp_ch4.adb (Expand_Allocator_Expression): When compiling for
8684 .NET/JVM targets, attach the newly allocated object to the access
8685 type's finalization collection. Do not generate a call to
8686 Set_Finalize_Address_Ptr on .NET/JVM because this routine does not
8687 exist in the runtime.
8688 (Expand_N_Allocator): When compiling for .NET/JVM targets, do not
8689 create a custom Allocate for object that do not require initialization.
8690 Attach a newly allocated object to the access type's finalization
8691 collection on .NET/JVM.
8692 * exp_ch5.adb (Make_Tag_Ctrl_Assignment): Add special processing for
8693 assignment of controlled types on .NET/JVM. The two hidden pointers
8694 Prev and Next and stored and later restored after the assignment takes
8695 place.
8696 * exp_ch6.adb (Expand_Call): Add local constant Curr_S. Add specialized
8697 kludge for .NET/JVM to recognize a particular piece of code coming from
8698 Heap_Management and change the call to Finalize into Deep_Finalize.
8699 * exp_ch7.adb (Build_Finalization_Collection): Allow the creation of
8700 finalization collections on .NET/JVM only for types derived from
8701 Controlled. Separate the association of storage pools with a collection
8702 and only allow it on non-.NET/JVM targets.
8703 (Make_Attach_Call): New routine.
8704 (Make_Detach_Call): New routine.
8705 (Process_Object_Declarations): Suppress the generation of
8706 build-in-place return object clean up code on .NET/JVM since it uses
8707 pools.
8708 * exp_ch7.ads (Make_Attach_Call): New routine.
8709 (Make_Detach_Call): New routine.
8710 * exp_intr.adb Add with and use clause for Targparm.
8711 (Expand_Unc_Deallocation): Detach a controlled object from a collection
8712 on .NET/JVM targets.
8713 * rtsfind.ads: Add entries RE_Attach, RE_Detach and
8714 RE_Root_Controlled_Ptr to tables RE_Id and RE_Unit_Table.
8715 * snames.ads-tmpl: Add name Name_Prev. Move Name_Prev to the special
8716 names used in finalization.
8717
87182011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8719
8720 * a-fihema.adb: Add with and use clauses for System.Soft_Links.
8721 (Attach, Detach): Lock the current task when chaining an object onto a
8722 collection.
8723
df3e68b1
HK
87242011-08-03 Hristian Kirtchev <kirtchev@adacore.com>
8725
8726 * a-except.adb, a-except-2005.adb (Raise_From_Controlled_Operation):
8727 Rewritten to create the message strings when the exception is not
8728 raised by an abort during finalization.
8729 * a-except.ads, a-except-2005.ads: Add pragma Export for procedure
8730 Raise_From_Controlled_Operation and update its associated comment.
8731 * a-fihema.ads, a-fihema.adb: New GNAT unit.
8732 Ada.Finalization.Heap_Management provides key functionality
8733 associated with controlled objects on the heap, their creation,
8734 finalization and reclamation. Type Finalization_Collection is
8735 effectively a wrapper which sits ontop of a storage pool and performs
8736 all necessary bookkeeping for all the objects it contains. Each
8737 access-to-controlled or access-to-class-wide type receives a collection
8738 as part of its expansion. The compiler generates buffer code and
8739 invokes Allocate / Deallocate to create and destroy allocated
8740 controlled objects.
8741 * a-finali.adb ("="): Removed.
8742 * a-finali.ads ("="): Removed. Controlled types no longer carry hidden
8743 fields Prev and Next.
8744 * ali.adb (Scan_ALI): Add parsing code to process PF / Has_Finalizer.
8745 A library unit with at least one controlled object on the library level
8746 has a special finalizer which is invoked by the binder. To signal this,
8747 ali files carry field PF.
8748 * ali.ads: New field in type Unit_Record called Has_Finalizer. Add
8749 associated comment on field usage.
8750 * a-tags.adb (Get_RC_Offset): Removed.
8751 (Needs_Finalization): New routine.
8752 * a-tags.ads: Update the structure of the GNAT dispatch tables.
8753 Dispatch tables now carry field Needs_Finalization which provides
8754 runtime indication whether a type is controlled or has controlled
8755 components or both. Remove field RC_Offset.
8756 (Get_RC_Offset): Removed along with its associated pragma Export.
8757 Since tagged types with controlled components no longer carry hidden
8758 field _controller, the special mechanism to retrieve its location is no
8759 longer needed.
8760 (Needs_Finalization): New routine.
8761 * atree.ads, atree.adb (Elist24): New routine.
8762 (Set_Elist24): New routine.
8763 * atree.h: Add a define clause for Elist24.
8764 * bindgen.adb New library-level variable Lib_Final_Built.
8765 (Gen_Adafinal_Ada): Reimplemented. Depending on the restrictions or the
8766 presence of a VM target, the routine generates calls to the proper
8767 library finalization routine.
8768 (Gen_Adainit_Ada): Import Finalize_Library_Objects only on non-VM
8769 targets. Set the correct library finalization routine depending on
8770 whether the library has controlled objects or this is a VM compilation.
8771 (Gen_Finalize_Library_Ada): New routine. This procedure generates calls
8772 to library-level finalizers of compiled units in reverse order of
8773 elaboration. It also produces exception management code and reraises a
8774 potential exception after all units have been finalized.
8775 (Gen_Finalize_Library_C): New routine. This procedure generates calls to
8776 library-level finalizers of compiled units in reverse order of
8777 elaboration.
8778 (Gen_Finalize_Library_Defs_C): New routine. This procedure generates the
8779 definitions of all library-level finalizers available to the compilation
8780 (Gen_Main_Ada): Directly call Adafinal which now contails all target
8781 dependent code.
8782 (Gen_Main_C): Add new local constant Needs_Library_Finalization. Call
8783 System.Standard_Library.Adafinal directly. If the library needs
8784 finalization actions, create the sequence of finalization calls.
8785 (Gen_Output_File_Ada): Alphabetize local variables and constants.
8786 Generate a with clause for System.Soft_Links when compiling for a VM.
8787 Remove the code which imports System.Standard_Library.Adafinal as
8788 Do_Finalize. Generate the library finalization routine.
8789 (Gen_Output_File_C): Add new local constant Needs_Library_Finalization.
8790 If the library needs finalization actions, create all the definitions
8791 of library- level finalizers.
8792 (Has_Finalizer): New routine. Determines whether at least one compiled
8793 unit has a library-level finalizer.
8794 Add type Qualification_Mode.
8795 (Set_Unit_Name): Add a formal which controls the replacement of a dot.
8796 * einfo.adb: New usage of field 15 as Return_Flag.
8797 Remove Finalization_Chain_Entity from the usages of field 19.
8798 Remove Associated_Final_Chain from the usages of field 23.
8799 New usage of field 23 as Associated_Collection.
8800 New usage of field 24 as Finalizer.
8801 New usage of flag 252 as Is_Processed_Transient.
8802 (Associated_Final_Chain): Removed.
8803 (Associated_Collection): New routine.
8804 (Finalization_Chain_Entity): Removed.
8805 (Finalizer): New routine.
8806 (Is_Finalizer): New routine.
8807 (Is_Processed_Transient): New routine.
8808 (Return_Flag): New routine.
8809 (Set_Associated_Final_Chain): Removed.
8810 (Set_Associated_Collection): New routine.
8811 (Set_Finalization_Chain_Entity): Removed.
8812 (Set_Finalizer): New routine.
8813 (Set_Is_Processed_Transient): New routine.
8814 (Set_Return_Flag): New routine.
8815 (Write_Entity_Flags): Include Is_Processed_Transient to the list of
8816 displayed flags.
8817 (Write_Field8_Name): Alphabetize the output.
8818 (Write_Field11_Name): Alphabetize the output.
8819 (Write_Field12_Name): Alphabetize the output.
8820 (Write_Field13_Name): Alphabetize the output.
8821 (Write_Field14_Name): Alphabetize the output.
8822 (Write_Field15_Name): Alphabetize the output.
8823 (Write_Field16_Name): Alphabetize the output.
8824 (Write_Field17_Name): Alphabetize the output.
8825 (Write_Field18_Name): Alphabetize the output.
8826 (Write_Field19_Name): Alphabetize the output. Remove the output of
8827 Finalization_Chain_Entity.
8828 (Write_Field20_Name): Alphabetize the output.
8829 (Write_Field21_Name): Alphabetize the output.
8830 (Write_Field22_Name): Alphabetize the output.
8831 (Write_Field23_Name): Alphabetize the output. Remove the output of
8832 Associated_Final_Chain. Add output for Associated_Collection.
8833 (Write_Field24_Name): Alphabetize the output.
8834 (Write_Field25_Name): Add output for Finalizer.
8835 (Write_Field26_Name): Alphabetize the output.
8836 (Write_Field27_Name): Alphabetize the output.
8837 (Write_Field28_Name): Alphabetize the output.
8838 * einfo.ads: Add new field description for Associated_Collection and
8839 its uses in nodes.
8840 Remove Associated_Final_Chain and its uses in nodes.
8841 Remove Finalization_Chain_Entity and its uses in nodes.
8842 Add new field description for Finalizer and its uses in nodes.
8843 Add new synthesized attribute Is_Finalizer.
8844 Add new flag description for Is_Processed_Transient and its uses in
8845 nodes.
8846 Add new field description for Return_Flag and its uses in nodes.
8847 (Associated_Final_Chain): Removed along with its pragma Inline.
8848 (Associated_Collection): New routine and pragma Inline.
8849 (Finalization_Chain_Entity): Removed along with its pragma Inline.
8850 (Finalizer): New routine and pragma Inline.
8851 (Is_Finalizer): New routine and pragma Inline.
8852 (Is_Processed_Transient): New routine and pragma Inline.
8853 (Return_Flag): New routine and pragma Inline.
8854 (Set_Associated_Final_Chain): Removed along with its pragma Inline.
8855 (Set_Associated_Collection): New routine and pragma Inline.
8856 (Set_Finalization_Chain_Entity): Removed along with its pragma Inline.
8857 (Set_Finalizer): New routine and pragma Inline.
8858 (Set_Is_Processed_Transient): New routine and pragma Inline.
8859 (Set_Return_Flag): New routine and pragma Inline.
8860 * exp_aggr.adb: Alphabetize subprograms.
8861 (Build_Array_Aggr_Code): Remove formal Flist and its associated comment.
8862 (Build_Record_Aggr_Code): Remove formals Flist and Obj along with their
8863 associated comments. Remove local variables External_Final_List and
8864 Attach.
8865 Rename Ctrl_Stuff_Done to Finalization_Done. Rename local variable A to
8866 Ancestor. Remove the retrieval of finalization lists. Update the call to
8867 Make_Adjust_Call.
8868 (Convert_Aggr_In_Allocator): Remove the retrieval of finalization
8869 lists. Update the call to Late_Expansion.
8870 (Convert_Aggr_In_Assignment): Update the call to Late_Expansion.
8871 (Convert_Aggr_In_Object_Decl): Update the call to Late_Expansion.
8872 (Gen_Assign): Remove the retrieval of the finalization list used to
8873 build the assignment. Update the calls to Make_Init_Call and
8874 Make_Adjust_Call.
8875 (Gen_Ctrl_Actions_For_Aggr): Renamed to Generate_Finalization_Actions.
8876 Remove the mechanism to determine attachment levels and finalization
8877 list retrieval. Remove the processing for coextensions.
8878 (Init_Controller): Removed. Controllers no longer exist.
8879 (Late_Expansion): Remove formals Flist and Obj along with their
8880 associated comments. Update the calls to Build_Record_Aggr_Code and
8881 Build_Array_Aggr_Code.
8882 * exp_ch13.adb (Expand_N_Free_Statement): New routine.
8883 (Expand_N_Freeze_Entity): Add special processing for finalizers which
8884 appear in entry bodies, protected subprograms and task bodies.
8885 * exp_ch13.ads (Expand_N_Free_Statement): New routine.
8886 * exp_ch3.adb (Add_Final_Chain): Removed.
8887 (Build_Array_Init_Proc): Alphabetize local variables.
8888 (Build_Assignment): Alphabetize local variables. Update the call to
8889 Maked_Adjust_Call.
8890 (Build_Class_Wide_Master): Rename local variables to better reflect
8891 their role.
8892 (Build_Discriminant_Assignments): Code reformatting.
8893 (Build_Init_Call_Thru): Code reformatting.
8894 (Build_Init_Procedure): Code reformatting. Generate a special version
8895 of Deep_Finalize which is capable of finalizing all initialized
8896 components and ignore the rest.
8897 (Build_Init_Statements): Rename local variables to better reflect their
8898 role.
8899 Reimplement the mechanism to include the creation and update of an index
8900 variable called a "counter". It is used as a bookmark for tracing
8901 initialized and non-initialized components.
8902 (Build_Initialization_Call): Remove local variable Controller_Typ.
8903 Alphabetize all local variables. Remove the initialization of the
8904 record controller and update the call to Make_Init_Call.
8905 (Build_Record_Init_Proc): Rename formal Pe to Rec_Ent.
8906 New local variable Counter.
8907 (Constrain_Array): Alphabetize.
8908 (Expand_Freeze_Array_Type): Create a collection instead of a
8909 finalization list.
8910 (Expand_Freeze_Class_Wide_Type): New routine. Creates TSS primitive
8911 Finalize_Address which is used in conjunction with allocated controlled
8912 objects.
8913 (Expand_N_Object_Declaration): Remove the creation of a finalization
8914 list for anonymous access types. Update the calls to Make_Init_Call and
8915 Make_Adjust_Call.
8916 (Expand_Freeze_Record_Type): Remove local variable Flist. Remove the
8917 retrieval of finalization lists. Remove the expansion of the record
8918 controller. Create TSS primitive Finalize_Address used in conjunction
8919 with controlled objects on the heap. Create finalization collections
8920 for access-to-controlled record components.
8921 (Expand_Record_Controller): Removed.
8922 (Freeze_Type): Remove the freezing of record controllers. Freezing of
8923 class-wide types now requires additional processing. Create
8924 finalization collections for access-to-controlled types.
8925 (Increment_Counter): New routine.
8926 (Make_Counter): New routine.
8927 (Make_Eq_If): Remove the mention of Name_uController.
8928 (Make_Predefined_Primitive_Specs): There is no longer need to skip
8929 types coming from System.Finalization_Root.
8930 (Predef_Deep_Spec): Reimplemented to reflect the new parameter profiles.
8931 (Predefined_Primitive_Bodies): There is no longer need to skip types
8932 coming from System.Finalization_Root.
8933 (Stream_Operation_OK): Do not generate stream routines for
8934 type Ada.Finalization.Heap_Management.Finalization_Collection.
8935 * exp_ch3.ads: Alphabetize subprograms.
8936 * exp_ch4.adb: Remove with and use clause for Sem_Ch8.
8937 Add with and use clause for Lib.
8938 (Complete_Coextension_Finalization): Removed.
8939 (Complete_Controlled_Allocation): New routine. Create a finalization
8940 collection for anonymous access-to-controlled types. Create a custom
8941 Allocate which interfaces with the back end and the machinery in
8942 Heap_Management.
8943 (Expand_Allocator_Expression): Add necessary calls to
8944 Complete_Controlled_Allocation. Remove the retrieval of finalization
8945 lists. Update the calls to Make_Adjust_Call. Generate a call to
8946 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
8947 the associated collection.
8948 (Expand_N_Allocator): Remove the processing for dynamic coextensions.
8949 Code clean up. Remove the retrieval of finalization lists and
8950 attachment levels.
8951 Update the call to Make_Init_Call. Generate a call to
8952 Ada.Finalization.Heap_Management.Set_Finalize_Address_Ptr to decorate
8953 the associated collection.
8954 (Get_Allocator_Final_List): Removed. Finalization lists are not
8955 available.
8956 (Suitable_Element): Remove the mention of Name_uController.
8957 * exp_ch5.adb: Remove with and use clauses for Ttypes and Uintp.
8958 (Make_Tag_Ctrl_Assignment): Rewritten to simply do a finalization of
8959 the left hand side, carry out the assignment and adjust the left hand
8960 side.
8961 * exp_ch6.adb (Add_Final_List_Actual_To_Build_In_Place_Call): Removed.
8962 (Add_Collection_Actual_To_Build_In_Place_Call): New routine.
8963 (BIP_Formal_Suffix): Rename BIP_Final_List and BIPfinallist to
8964 BIP_Collection and BIPcollection.
8965 (Build_Heap_Allocator): New routine used to allocate the return object
8966 of a build-in-place function onto a collection.
8967 (Expand_Ctrl_Function_Call): Moved from Exp_Ch7.
8968 (Expand_Call): Do not replace direct calls to Deep routines with their
8969 aliases.
8970 (Expand_N_Extended_Return_Statement): Give all variables shorter names
8971 and update their occurrences. Add a special return flag to monitor the
8972 [ab]normal execution of the function. The flag is set right before the
8973 return statement.
8974 Rewrite the mechanism used to allocate a build-in-place return object
8975 on the heap or on a storage pool.
8976 (Is_Direct_Deep_Call): New routine.
8977 (Make_Build_In_Place_Call_In_Allocator): Add a collection to a
8978 build-in-place function call instead of a final list. Build a call to
8979 Set_Finalize_Address_Ptr to decorate the associated collection.
8980 (Make_Build_In_Place_Call_In_Anonymous_Context): Create a temporary in
8981 order to name the build-in-place function call's result for later
8982 finalization. Add a collection to a build-in-place function call
8983 instead of a final list.
8984 (Make_Build_In_Place_Call_In_Assignment): Add a collection to a
8985 build-in-place function call instead of a final list. Remove the code
8986 which moves one final list and transforms it into the actual in a
8987 nested build-in-place call.
8988 (Make_Build_In_Place_Call_In_Object_Declaration): Add a collection to a
8989 build-in-place function call instead of a final list.
8990 (Move_Final_List): Removed.
8991 (Needs_BIP_Collection): New routine.
8992 (Needs_BIP_Final_List): Removed.
8993 * exp_ch6.ads: Replace BIP_Final_List with BIP_Collection in
8994 enumeration type BIP_Formal_Kind.
8995 Update the related comment.
8996 (Needs_BIP_Collection): New routine.
8997 (Needs_BIP_Final_List): Removed.
8998 * exp_ch7.adb: Add with and use clauses for Elists, Exp_Ch6, Stringt
8999 and Ttypes. Remove with and use clauses for Sem_Type. Alphabetize the
9000 majority of subprograms in this unit. Add Name_Finalize_Address to
9001 array Name_Of and TSS_Finalize_Address to array Deep_Name_Of.
9002 (Build_Adjust_Or_Finalize_Statements): Create the adjust or finalization
9003 statements for an array type.
9004 (Build_Adjust_Statements): Create the adjust statements for a record
9005 type.
9006 (Build_Cleanup_Statements): New routine. A procedure which given any
9007 construct containing asynchronous calls, references to _master, or is a
9008 task body, a task allocation or a protected body produces the necessary
9009 runtime calls to clean up these constructs.
9010 (Build_Exception_Handler): New routine.
9011 (Build_Final_List): Removed.
9012 (Build_Finalization_Collection): New routine. A core procedure which
9013 creates a collection to service heap allocated controlled objects
9014 associated with an access-to-controlled type.
9015 (Build_Finalize_Statements): Create the finalization statements for a
9016 record types.
9017 (Build_Finalizer): New routine. A core procedure which given any
9018 construct with declarations and/or statements detects all objects which
9019 need any type of clean up (controlled objects, protected objects) and
9020 generates all necessary code to clean up the said objects in the proper
9021 order.
9022 (Build_Finalizer_Call): New routine.
9023 (Build_Initialize_Statements): Create the initialization statements for
9024 an array type. The generated routine contains code to finalize partially
9025 initialized arrays.
9026 (Build_Object_Declarations): New routine.
9027 (Build_Raise_Statement): New routine.
9028 (Clean_Simple_Protected_Objects): Removed.
9029 (Controller_Component): Removed.
9030 (Enclosing_Function): New routine.
9031 (Expand_Cleanup_Actions): Create a finalizer for a construct which has
9032 either declarations or statements or both.
9033 (Expand_N_Package_Body): Create a finalizer for a non-generic package.
9034 (Expand_N_Package_Declaration): Create a finalizer for a non-generic
9035 package.
9036 (Find_Final_List): Removed.
9037 (Global_Flist_Ref): Removed.
9038 (In_Finalization_Root): Removed.
9039 (Insert_Actions_In_Scope_Around): Determine the range of the transient
9040 scope in terms of tree nodes. Process all transient variables within
9041 that range.
9042 (Make_Adjust_Call): Rewritten. There is no longer an attach call
9043 generated after the adjust.
9044 (Make_Attach_Call): Removed.
9045 (Make_Call): New routine.
9046 (Make_Clean): Removed.
9047 (Make_Deep_Array_Body): Rewritten to simply invoke the appropriate
9048 build routines.
9049 (Make_Deep_Proc): Rewritten to generate the new profile signature used
9050 in Deep routines.
9051 (Make_Deep_Record_Body): Rewritten to simply invoke the appropriate
9052 build routines.
9053 (Make_Final_Call): Modified to simply create a call to either
9054 Deep_Finalize or Finalize.
9055 (Make_Finalize_Address_Body): New routine.
9056 (Make_Finalize_Address_Stmts): New routine. A function which produces
9057 TSS primitive Finalize_Address used in conjunction with heap allocated
9058 controlled objects.
9059 (Make_Handler_For_Ctrl_Operation): Add specialized code for .NET/JVM.
9060 (Make_Init_Call): Rewritten. There is no longer an attach call
9061 generated after initialization.
9062 (Make_Local_Deep_Finalize): New routine.
9063 (Make_Set_Finalize_Address_Ptr_Call): New routine.
9064 (Make_Transient_Block): Remove the finalization list retrieval and
9065 manipulation.
9066 (Needs_Finalization): Moved to Exp_Util.
9067 (Parent_Field_Type): New routine.
9068 (Preprocess_Components): New routine.
9069 (Process_Transient_Objects): New routine.
9070 (Wrap_HSS_In_Block): New routine.
9071 (Wrap_Transient_Declaration): Remove finalization list management and
9072 controller insertion.
9073 (Wrap_Transient_Expression): Code reformatting.
9074 (Wrap_Transient_Statement): Code reformatting.
9075 * exp_ch7.ads (Build_Final_List): Removed.
9076 (Build_Finalization_Collection): New routine.
9077 (Build_Raise_Statement): New routine.
9078 (Controller_Component): Removed.
9079 (Expand_Ctrl_Function_Call): Moved to Exp_Ch6.
9080 (Find_Final_List): Removed.
9081 (In_Finalization_Root): Removed.
9082 (Is_Simple_Protected_Type): Update related comment.
9083 (Make_Adjust_Call): New parameter profile and associated comments.
9084 (Make_Attach_Call): Removed.
9085 (Make_Final_Call): New parameter profile and associated comments.
9086 (Make_Finalize_Address_Body): New routine.
9087 (Make_Init_Call): New parameter profile and associated comments.
9088 (Make_Local_Deep_Finalize): New routine.
9089 (Make_Set_Finalize_Address_Ptr_Call): New routine.
9090 (Needs_Finalization): Moved to Exp_Util.
9091 * exp_ch9.adb (Add_Object_Pointer): Code reformatting.
9092 (Expand_N_Protected_Body): Remove the handling of finalization lists.
9093 (Find_Protection_Type): Moved to Exp_Util.
9094 * exp_disp.adb: Remove with and use clauses for Exp_Ch7.
9095 (Make_DT): Update sequence of dispatch table initialization. Remove the
9096 initialization of field RC_Offset. Add initialization of field Needs_
9097 Finalization.
9098 * exp_intr.adb (Expand_Unc_Deallocation): Code reformatting.
9099 Reimplement how an object is first finalized, then deallocated.
9100 * exp_strm.adb (Build_Record_Or_Elementary_Input_Function):
9101 Code reformatting.
9102 * exp_tss.ads: Add special suffix for TSS primitive Finalize_Address.
9103 Register TSS_Finalize_Address with type TSS_Names.
9104 * exp_util.adb (Build_Allocate_Deallocate_Proc): New routine. This core
9105 procedure provides the interface between an allocation / deallocation
9106 and the support machinery in Ada.Finalization.Heap_Management.
9107 (Find_Init_Call): Code reformatting.
9108 (Find_Init_Call_In_List): Code reformatting.
9109 (Find_Protection_Type): Moved from Exp_Ch9.
9110 (Find_Prim_Op): Reimplement to add preference of recovered primitive.
9111 (Has_Controlled_Coextensions): Removed.
9112 (Has_Controlled_Objects): New routine.
9113 (In_Library_Level_Package_Body): New routine.
9114 (Insert_Action_After): New routine.
9115 (Is_Finalizable_Transient): New routine. This predicate determines
9116 whether an object declaration is one of the many variants of controlled
9117 transients.
9118 (Is_Null_Access_BIP_Func_Call): New routine.
9119 (Is_Non_BIP_Func_Call): New routine.
9120 (Is_Related_To_Func_Return): New routine.
9121 (Needs_Finalization): Moved from Exp_Ch7.
9122 * exp_util.ads (Build_Allocate_Deallocate_Proc): New routine.
9123 (Find_Protection_Type): Moved from Exp_Ch9.
9124 (Has_Controlled_Coextensions): Removed.
9125 (Has_Controlled_Objects): New routine.
9126 (In_Library_Level_Package_Body): New routine.
9127 (Insert_Action_After): New routine.
9128 (Is_Finalizable_Transient): New routine.
9129 (Is_Null_Access_BIP_Func_Call): New routine.
9130 (Is_Non_BIP_Func_Call): New routine.
9131 (Is_Related_To_Func_Return): New routine.
9132 (Needs_Finalization): Moved from Exp_ch7.
9133 * expander.adb (Expand): Add a case for N_Free_Statement.
9134 * freeze.adb (Freeze_All): Replace the generation of a finalization
9135 list with a collection for access-to-controlled types.
9136 (Freeze_Entity): Code reformatting.
9137 (Freeze_Record_Type): Remove the freezing of a record controller
9138 component.
9139 (Freeze_Subprogram): Code reformatting.
9140 * inline.adb (Cleanup_Scopes): Remove the reset of the scope
9141 finalization list.
9142 * lib-writ.adb (Write_Unit_Information): Output "PF" when a package
9143 has a library-level finalizer.
9144 * lib-writ.ads: Add "PF" to the sequence of unit attributes.
9145 * a-filico.ads, a-filico.adb, s-finimp.ads, s-finimp.adb: Removed.
9146 * Makefile.rtl: Remove a-filico and s-finimp from the list of object
9147 files. Add a-fihema to the list of object files.
9148 * par-ch4.adb:
9149 Alphabetize the associations in type Is_Parameterless_Attribute.
9150 * rtsfind.ads: Ada.Finalization_List.Controller and
9151 System.Finalization_Implementation are no longer a GNAT unit.
9152 Update the range of type Ada_Finalization_Child. Remove the following
9153 recoverable entities:
2c7f9cc0 9154
df3e68b1
HK
9155 RE_Attach_To_Final_List
9156 RE_Deep_Tag_Attach
9157 RE_Finalize_List
9158 RE_Finalize_One
9159 RE_Finalizable_Ptr_Ptr
9160 RE_Global_Final_List
9161 RE_Limited_Record_Controller
9162 RE_List_Controller
9163 RE_Move_Final_List
9164 RE_Record_Controller
9165 RE_Simple_List_Controller
2c7f9cc0 9166
df3e68b1 9167 Add the following recoverable entities:
2c7f9cc0 9168
df3e68b1
HK
9169 RE_Add_Offset_To_Address
9170 RE_Allocate
9171 RE_Base_Pool
9172 RE_Deallocate
9173 RE_Exception_Identity
9174 RE_Finalization_Collection
9175 RE_Finalization_Collection_Ptr
9176 RE_Needs_Finalization
9177 RE_Save_Library_Occurrence
9178 RE_Set_Finalize_Address_Ptr
9179 RE_Set_Storage_Pool_Ptr
9180 RE_Storage_Count
9181 * sem_aggr.adb (Resolve_Record_Aggregate): Remove mention of
9182 Name_uController.
9183 * sem_aux.adb (First_Discriminant): Remove mention of Name_uController.
9184 (First_Stored_Discriminant): Remove the mention of Name_uController.
9185 * sem_aux.ads: Comment reformatting.
9186 * sem_ch10.adb (Build_Chain): Signal the class-wide creation machinery
9187 to redecorate an already existing class-wide type.
9188 (Decorate_Tagged_Type): New parameter profile and associated comment.
9189 Create a "shadow class-wide type" for a shadow entity.
9190 * sem_ch11.adb (Analyze_Exception_Handlers): Remove the dubious setting
9191 of the final chain along with the associated comment.
9192 * sem_ch3.adb (Access_Type_Declaration): Add new local variable
9193 Full_Desig and set it to the full view of the designated type.
9194 Initialize the finalization collection to empty.
9195 (Build_Derived_Record_Type): Alphabetize local variables. Code
9196 reformatting.
9197 (Collect_Fixed_Components): Remove the mention of Name_uController.
9198 (Create_Constrained_Components): Remove the mention of Name_uController.
9199 (Make_Class_Wide_Type): Add specialized code to redecorate an existing
9200 class-wide type of a shadow entity.
9201 (Process_Full_View): Update the machinery which marks type
9202 Limited_Controlled's entity as limited.
9203 * sem_ch4.adb (Analyze_One_Call): Code reformatting.
9204 * sem_ch6.adb (Create_Extra_Formals): Do not generate a finalization
9205 list, instead make a collection build-in-place formal.
9206 * sem_ch8.adb (Analyze_Object_Renaming): Look at the available view of
9207 a designated type in order to establish a match between the renaming
9208 and the renamed entity.
9209 (Find_Selected_Component): Add guard to prevent spurious exceptions
9210 from being raised on .NET/JVM.
9211 * sem_disp.adb (Check_Dispatching_Operation): Include Finalize_Address
9212 to the list of primitive that need special processing. Update arrays
9213 C_Names and D_Names.
9214 (Replace_Types): Handle class-wide types.
9215 * sem_elab.adb (Check_A_Call): Since Deep_Initialize now has a
9216 different parameter profile, look at the first formal.
9217 * sem_prag.adb: Remove with and use clauses for Exp_Ch7. Add with and
9218 use clauses for Exp_Util.
9219 * sem_res.adb: Remove with and use clauses for Elists.
9220 (Propagate_Coextensions): Removed.
9221 (Resolve_Allocator): Do not propagate the list of coextensions from one
9222 allocator to another.
9223 * sem_util.adb (Build_Actual_Subtype_Of_Component): Rename variable
9224 Deaccessed_T to Desig_Typ.
9225 (Enter_Name): Remove the mention of Name_uController.
9226 (Gather_Components): Remove the mention of Name_uController.
9227 (Incomplete_Or_Private_View): New routine.
9228 (Is_Coextension_Root): Removed.
9229 (Is_Fully_Initialized_Type): Remove the mention of Name_uController.
9230 * sem_util.ads (Incomplete_Or_Private_View): New routine.
9231 (Is_Coextension_Root): Removed.
9232 * s-finroo.ads: Remove with clause for Ada.Unchecked_Conversion.
9233 Controlled types are now derived from a null tagged record. Remove
9234 types Finalizable_Ptr, Finalizable and Empty_Root_Controlled.
9235 * sinfo.adb (Coextensions): Removed.
9236 (Set_Coextensions): Removed.
9237 * sinfo.ads: Remove Coextensions from the explanation of node fields
9238 and its uses in nodes.
9239 Update the field usage of N_Allocator.
9240 (Coextensions): Removed along with its pragma Inline.
9241 (Set_Coextensions): Removed along with its pragma Inline.
9242 * snames.ads-tmpl: Remove names
2c7f9cc0 9243
df3e68b1
HK
9244 Name_uClean
9245 Name_uController
9246 Name_uFinal_List
9247 Name_uLocal_Final_List
9248 Name_Finalization_Root
9249 Name_Next
9250 Name_Prev
2c7f9cc0 9251
df3e68b1 9252 Add names
2c7f9cc0 9253
df3e68b1
HK
9254 Name_uFinalizer
9255 Name_Finalize_Address
9256 * s-pooglo.adb (Allocate): Add overriding indicator.
9257 (Deallocate): Add overriding indicator.
9258 (Storage_Size): Add overriding indicator.
9259 * s-soflin.adb (Adafinal_NT): Invoke Finalize_Library_Objects rather
9260 than Finalize_Global_List.
9261 (Null_Finalize_Global_List): Removed.
9262 (Save_Library_Occurrence): New routine.
9263 * s-soflin.ads: Remove variable Finalize_Global_List along with its
9264 initialization. Add variable Finalize_Library_Objects along with its
9265 pragma Export. Add variables Library_Exception and
9266 Library_Exception_Set along with their pragma Export.
9267 (Null_Finalize_Global_List): Removed.
9268 (Save_Library_Occurrence): New routine.
9269 * s-tassta.adb (Finalize_Global_Tasks): Call Finalize_Library_Objects
9270 rather than Finalize_Global_List.
9271 * tbuild.adb (Unchecked_Convert_To): Capture and set the parent field
9272 of the constructed node.
9273
2ee06322
RO
92742011-08-03 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
9275
9276 * link.c: Include "auto-host.h" before system headers.
9277
f77b022b
VC
92782011-08-03 Vincent Celier <celier@adacore.com>
9279
9280 * make.adb (Gnatmake): Add to table Library_Projs only library projects
9281 that are not extended. Do not check if a library project that is
9282 extended should be regenerated. Do not add to table Library_Paths the
9283 libraries that are in extended projects. Link only with libraries that
9284 are in libray projects that are not extended.
9285 * prj-nmsc.adb (Check_Library_Attributes): Do not reset flag Library
9286 for a library project that is extended.
9287
0187b60e
AC
92882011-08-03 Gary Dismukes <dismukes@adacore.com>
9289
9290 * sem_ch6.adb (Find_Corresponding_Spec): When in an instance, skip
9291 conforming subprogram renamings that appear to be completions if they
9292 are not fully conformant.
9293 Such renamings are homographs but not completions.
9294 * sem_type.adb (Disambiguate): Handle disambiguation of overloaded
9295 names in a subprogram renaming that appears in an instance.
9296
92972011-08-03 Ed Schonberg <schonberg@adacore.com>
9298
9299 * exp_util.adb (Expand_Subtype_From_Expr): if the type is limited but
9300 not immutably limited, build actual subtype from expression to provide
9301 proper bounds to caller.
9302
93032011-08-03 Gary Dismukes <dismukes@adacore.com>
9304
9305 * sem_ch8.adb: Minor comment correction.
9306
93072011-08-03 Thomas Quinot <quinot@adacore.com>
9308
9309 * exp_strm.adb (Build_Array_Input_Function): In Ada 2005 mode, when
9310 returning a limited array, use an extended return statement.
9311
93122011-08-03 Vincent Celier <celier@adacore.com>
9313
9314 * make.adb (Initialize): If --subdirs= is used, but no project file is
9315 specified, attempt to create the specify subdir if it does not already
9316 exist and use it as the object directory as if -D had been specified.
9317
93182011-08-03 Arnaud Charlet <charlet@adacore.com>
9319
9320 * s-tpopsp-vms.adb: New file.
9321 * s-taprop-vms.adb: Put back ATCB_Key, since needed by this file on VMS.
9322 * gcc-interfaces/Makefile.in: Use s-taprop-vms.adb on VMS.
9323
e280f981
AC
93242011-08-03 Emmanuel Briot <briot@adacore.com>
9325
9326 * make.adb, makeutl.adb, makeutl.ads, clean.adb (Makeutl.Queue): new
9327 package.
9328
93292011-08-03 Yannick Moy <moy@adacore.com>
9330
9331 * cstand.adb (Create_Standard): select Universal_Integer as an ALFA type
9332 * sem_ch3.adb (Array_Type_Declaration): detect array types in ALFA
9333 * sem_util.adb, sem_util.ads (Has_Static_Array_Bounds): new function to
9334 detect that an array has static bounds.
9335
98c99a5a
AC
93362011-08-03 Thomas Quinot <quinot@adacore.com>
9337
9338 * exp_dist.adb: Minor reformatting.
9339
93402011-08-03 Arnaud Charlet <charlet@adacore.com>
9341
9342 * s-taprop-irix.adb, s-taprop-hpux-dce.adb, s-taprop-vms.adb
9343 (ATCB_Key): Removed, not always used.
9344
93452011-08-03 Emmanuel Briot <briot@adacore.com>
9346
9347 * gnatcmd.adb, make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads,
9348 clean.adb, prj-conf.adb, prj-env.adb, prj-env.ads (Makeutl): remove
9349 most remaining global variables.
9350
686d0984
AC
93512011-08-03 Robert Dewar <dewar@adacore.com>
9352
9353 * gnatcmd.adb, prj-proc.adb, mlib-prj.adb, prj.adb, makeutl.ads,
9354 prj-util.adb, prj-util.ads, prj-conf.adb, prj-env.adb: Minor
9355 reformatting.
9356
93572011-08-03 Javier Miranda <miranda@adacore.com>
9358
9359 * exp_util.adb (Is_VM_By_Copy_Actual): Include N_Slide nodes as actuals
9360 that must be passed by copy in VM targets.
9361
93622011-08-03 Emmanuel Briot <briot@adacore.com>
9363
9364 * prj.ads, prj-nmsc.adb (Files_Htable): removed this htable, which
9365 duplicates a similar htable now in the project tree.
9366
93672011-08-03 Claire Dross <dross@adacore.com>
9368
9369 * a-cfdlli.adb, a-cfhama.adb, a-cfhase.adb, a-cforma.adb, a-cforse.adb,
9370 a-cofove.adb ("=", Length, Is_Empty, Clear, Assign, Copy, Element,
9371 Replace_Element, Query_Element, Update_Element, Move, Insert, Prepend,
9372 Append, Delete, Delete_First, Delete_Last, Reverse_Element, Swap,
9373 Splice, First, First_Element, Last, Last_Element, Next, Previous, Find,
9374 Reverse_Find, Contains, Has_Element, Iterate, Reverse_Iterate, Capacity,
9375 Reserve_Length, Length, Strict_Equal, Left, Right): Data-structure
9376 update.
9377
93782011-08-03 Arnaud Charlet <charlet@adacore.com>
9379
9380 * s-taprop-posix.adb, s-taprop-linux.adb, s-taprop-tru64.adb
9381 (ATCB_Key): Removed, not always used.
9382 * s-tpopsp-posix.adb, s-tpopsp-posix-foreign.adb (ATCB_Key): Moved from
9383 s-taprop-posix.adb.
9384 * s-tpopsp-tls.adb: New file.
9385 * gcc-interface/Makefile.in: Use TLS implementation of s-tpopsp.adb on
9386 x86/x64/ia64/powerpc/sparc Linux.
9387
93882011-08-03 Arnaud Charlet <charlet@adacore.com>
9389
9390 * system-aix.ads, system-aix64.ads: Set ZCX_By_Default to True.
9391 * gcc-interface/Makefile.in: Switch to ZCX by default on AIX ports.
9392
93932011-08-03 Thomas Quinot <quinot@adacore.com>
9394
9395 * rtsfind.ads, exp_dist.adb, exp_dist.ads
9396 (Build_From_Any_Call, Build_To_Any_Call, Build_TypeCode_Call):
9397 Fix type selection for mapping integer types to PolyORB types.
9398
93992011-08-03 Bob Duff <duff@adacore.com>
9400
9401 * sem_ch7.adb: Minor comment clarification.
9402
94032011-08-03 Bob Duff <duff@adacore.com>
9404
9405 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): If we get
9406 an error analyzing a choice, skip further processing. Further
9407 processing could cause a crash or cascade errors.
9408
40ecf2f5
EB
94092011-08-03 Emmanuel Briot <briot@adacore.com>
9410
9411 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, mlib-prj.adb,
9412 prj.adb, prj.ads, makeutl.adb, makeutl.ads, clean.adb, prj-nmsc.adb,
9413 prj-util.adb, prj-util.ads, prj-conf.adb, prj-conf.ads, prj-env.adb,
9414 prj-env.ads (Shared_Project_Tree_Data): new type
9415 An aggregate project and its aggregated trees need to share the common
9416 data structures used for lists of strings, packages,... This makes the
9417 code simpler since otherwise we have to pass the root tree (also used
9418 for the configuration file data) in addition to the current project
9419 tree. This also avoids ambiguities as to which tree should be used.
9420 And finally this saves a bit of memory.
9421 (For_Every_Project_Imported): new parameter Tree.
9422 Since aggregated projects are using a different tree, we need to let
9423 the caller know which tree to use to manipulate the returned project.
9424
9fde638d
RD
94252011-08-03 Robert Dewar <dewar@adacore.com>
9426
9427 * prj-proc.adb, exp_util.ads, exp_ch9.adb, make.adb, prj-ext.adb,
9428 prj-ext.ads, alfa.ads, sem_ch4.adb, makeutl.adb, makeutl.ads,
9429 lib-xref-alfa.adb, sem_cat.adb, exp_dist.adb, get_alfa.adb,
9430 prj-env.adb, prj-env.ads, prj-tree.adb, alfa.ads: Minor reformatting.
9431
95eb8b69
AC
94322011-08-03 Javier Miranda <miranda@adacore.com>
9433
9434 * exp_util.adb, sem_aux.adb, exp_util.ads, sem_aux.ads:
9435 Move routine Is_VM_By_Copy_Actual from sem_aux to exp_util.
9436
94372011-08-03 Bob Duff <duff@adacore.com>
9438
9439 * sem_ch8.adb (Is_Primitive_Operator_In_Use): Always check In_Use on
9440 the Base_Type.
9441
94422011-08-03 Joel Brobecker <brobecker@adacore.com brobecker>
9443
9444 * g-sha256.ads, g-sha512.ads, g-sha1.ads, g-sha224.ads, g-sha384.ads,
9445 g-sehash.ads: Fix typo. Update header.
9446
94472011-08-03 Thomas Quinot <quinot@adacore.com>
9448
9449 * exp_ch6.adb (Expand_Actuals): Remove Ada_2005 guard on build-in-place
9450 expansion.
9451
94522011-08-03 Gary Dismukes <dismukes@adacore.com>
9453
9454 * sem_ch4.adb (Analyze_Overloaded_Selected_Component): Consider
9455 prefixes of private types along with records, since the selector may be
9456 a discriminant.
9457 * sem_res.adb (Resolve_Selected_Component): Consider prefixes of
9458 private types along with records, since the selector may be a
9459 discriminant.
9460
92e77027
AC
94612011-08-03 Emmanuel Briot <briot@adacore.com>
9462
b2f7ebc1 9463 * prj-pp.adb (Pretty_Print): Remove trailing blank line.
92e77027
AC
9464
94652011-08-03 Javier Miranda <miranda@adacore.com>
9466
9467 * sem_aux.adb (Is_VM_By_Copy_Actual): Fix wrong use of
9468 Tagged_Type_Expansion.
9469
94702011-08-03 Yannick Moy <moy@adacore.com>
9471
b2f7ebc1
GP
9472 * sem_res.adb (Resolve_Op_Concat_Arg): Do not issue a SPARK
9473 violation when the argument of concatenation is the name of a
9474 constant.
92e77027 9475
ab29a348
EB
94762011-08-03 Emmanuel Briot <briot@adacore.com>
9477
9478 * prj-proc.adb, prj-ext.adb, prj-ext.ads, prj-env.adb, prj-env.ads,
9479 prj-tree.adb, prj-tree.ads (Initialize_And_Copy, Copy): new subprograms
9480 (Process_Declarative_Items): new parameter Child_Env.
9481
9466892f
AC
94822011-08-03 Yannick Moy <moy@adacore.com>
9483
589ef536
GP
9484 * alfa.ads: Update format of ALFA section in ALI file in order to
9485 add a mapping from bodies to specs when both are present.
9486 (ALFA_Scope_Record): Add components for spec file/scope.
9487 * get_alfa.adb (Get_ALFA): Read the new file/scope for spec when
9488 present.
9489 * lib-xref-alfa.adb (Collect_ALFA): After all scopes have been
9490 collected, fill in the spec information when relevant.
9491 * put_alfa.adb (Put_ALFA): Write the new file/scope for spec when
9466892f
AC
9492 present.
9493
94942011-08-03 Eric Botcazou <ebotcazou@adacore.com>
9495
9496 * inline.adb (Add_Inlined_Subprogram): Do not consider the enclosing
9497 code unit to decide whether to add internally generated subprograms.
2c7f9cc0 9498
9466892f
AC
94992011-08-03 Javier Miranda <miranda@adacore.com>
9500
9501 * sem_aux.ads, sem_aux.adb (Is_VM_By_Copy_Actual): New subprogram.
589ef536
GP
9502 * exp_ch9.adb (Build_Simple_Entry_Call): Handle actuals that must
9503 be handled by copy in VM targets.
9466892f
AC
9504
95052011-08-03 Emmanuel Briot <briot@adacore.com>
9506
589ef536 9507 * make.adb, makeutl.adb, makeutl.ads (Make.Switches_Of): Share
9466892f
AC
9508 code with Makeutl.Get_Switches.
9509 * prj-tree.adb: Update comment.
9510
b5ea9143
AC
95112011-08-03 Thomas Quinot <quinot@adacore.com>
9512
9513 * sem_cat.adb (Validate_RCI_Subprogram_Declaration): Reject a remote
9514 subprogram with a limited formal that does not support external
9515 streaming.
9516
95172011-08-03 Yannick Moy <moy@adacore.com>
9518
9519 * get_alfa.adb (Get_ALFA): add missing Skip_Spaces at start of
9520 continuation line
9521 * lib-xref-alfa.adb (Add_ALFA_File): split removal of scopes that are
9522 not from current unit in two phases, because it is not possible to
9523 change the table while iterating over its content.
9524 * put_alfa.adb (Put_ALFA): reset current file/scope at each new entity
9525
95262011-08-03 Sergey Rybin <rybin@adacore.com>
9527
9528 * vms_data.ads: Add qualifier for gnatmetric --no-static-loop option
9529 * gnat_ugn.texi: Update description of complexity metrics (gnatmetric)
9530
668a19bc
ES
95312011-08-03 Ed Schonberg <schonberg@adacore.com>
9532
9533 * sem_res.adb (Resolve_Op_Concat_Arg): if the argument is an aggregate
9534 and the component type is composite, this is ambiguous for predefined
9535 concatenation, but if the node is not overloaded and the entity is a use
9536 -defined function its profile can be used to resolve that aggregate.
9537
170b2989
AC
95382011-08-03 Robert Dewar <dewar@adacore.com>
9539
9540 * exp_ch4.adb: Minor code cleanup.
9541
95422011-08-03 Thomas Quinot <quinot@adacore.com>
9543
9544 * exp_dist.adb: Do not generate distribution stubs if serious errors
9545 have been diagnosed.
9546
95472011-08-03 Ed Schonberg <schonberg@adacore.com>
9548
9549 * sem_ch4.adb (Try_Primitive_Operation): when checking the validity of
9550 the first formal of a primitive operation, go to the base type to
9551 handle properly an access to a derived type with constrained
9552 discriminants.
9553 * sem_type.adb (Disambiguate): an immediately visible operator hides a
9554 user-defined function that is only use-visible.
170b2989 9555
e917aec2
RD
95562011-08-03 Robert Dewar <dewar@adacore.com>
9557
9558 * sem_aggr.adb, sem_ch3.adb, lib.ads, gnatcmd.adb, prj-proc.adb,
9559 make.adb, lib-writ.adb, prj-part.adb, prj-part.ads, prj-ext.adb,
9560 fname-uf.adb, prj-ext.ads, prj.adb, prj.ads, sem_attr.adb, alfa.adb,
9561 prj-makr.adb, errout.adb, makeutl.adb, makeutl.ads, restrict.ads,
9562 sem_ch6.adb, g-pehage.adb, clean.adb, put_alfa.adb, lib-xref-alfa.adb,
9563 prj-nmsc.adb, prj-nmsc.ads, sem_ch8.adb, prj-pars.ads, exp_aggr.adb,
9564 prj-attr.ads, sem_ch13.adb, get_alfa.adb, prj-env.adb, prj-env.ads,
9565 alfa_test.adb, prj-tree.adb, prj-tree.ads, einfo.ads: Minor reformatting
9566
95672011-08-03 Robert Dewar <dewar@adacore.com>
9568
9569 * repinfo.adb (List_Mechanism): Add handling of
9570 Convention_Ada_Pass_By_XXX.
9571 * sem_mech.adb (Set_Mechanism): Ditto.
9572 * sem_prag.adb (Process_Convention): Add entries for
9573 Convention_Ada_Pass_By_XXX.
9574 * snames.adb-tmpl, snames.ads-tmpl: Ditto.
9575
49bfcf43
AC
95762011-08-03 Pascal Obry <obry@adacore.com>
9577
9578 * makeutl.adb: Minor reformatting.
9579
95802011-08-03 Vincent Celier <celier@adacore.com>
9581
9582 * fname-uf.adb
9583 (Get_File_Name) If the file cannot be found when there are no config
9584 pragmas file and May_Fail is True, return No_File instead of the file
9585 name, to be consistent.
9586
95872011-08-03 Pascal Obry <obry@adacore.com>
9588
9589 * adaint.c (__gnat_is_executable_file_attr): Avoid access
9590 to null pointer.
9591
95922011-08-03 Javier Miranda <miranda@adacore.com>
9593
9594 * sem_ch13.adb
9595 (Same_Representation): In VM targets the representation of arrays with
9596 aliased components differs from arrays with non-aliased components.
9597
34798441
EB
95982011-08-03 Emmanuel Briot <briot@adacore.com>
9599
9600 * prj-proc.adb, prj-attr.adb, prj-attr.ads (Get_Attribute_Index): do
9601 not systematically lower case attribute indexes that contain no "."
9602 Fix definition of several Naming attributes, which take
9603 a unit name as index and therefore should be case insensitive.
9604 Minor refactoring (reduce length of variable names).
9605
96062011-08-03 Emmanuel Briot <briot@adacore.com>
9607
9608 * makeutl.adb, makeutl.ads (Get_Switches): new subprogram.
9609
4437a530
EB
96102011-08-03 Emmanuel Briot <briot@adacore.com>
9611
9612 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, prj-part.adb,
9613 prj-part.ads, switch-m.adb, switch-m.ads, prj-makr.adb, clean.adb,
9614 prj-pars.adb, prj-pars.ads, prj-conf.adb, prj-conf.ads, prj-tree.adb,
9615 prj-tree.ads (Prj.Tree.Environment): new type.
9616
804fe3c4
EB
96172011-08-03 Emmanuel Briot <briot@adacore.com>
9618
9619 * prj-proc.adb, prj.ads, makeutl.adb, makeutl.ads, prj-conf.adb,
9620 prj-tree.adb, prj-tree.ads (Environment): new type.
9621
c565bc66
AC
96222011-08-03 Emmanuel Briot <briot@adacore.com>
9623
9624 * prj-tree.ads: Remove unused variable.
9625
96262011-08-03 Yannick Moy <moy@adacore.com>
9627
9628 * restrict.adb (Restriction_Msg): set "SPARK" all in upper case for
9629 issuing messages related to SPARK restriction violation.
9630
4ee646da
AC
96312011-08-03 Ed Schonberg <schonberg@adacore.com>
9632
9633 * sem_ch6.adb: guard against error nodes in return statements.
9634
96352011-08-03 Arnaud Charlet <charlet@adacore.com>
9636
9637 * errout.adb (Error_Msg_Internal): the main unit has not been read yet,
9638 a warning can only appear on a configuration file, so emit warning
9639 without further checks.
9640
96412011-08-03 Arnaud Charlet <charlet@adacore.com>
9642
9643 * s-interr.ads: add overriding keyword.
9644
96452011-08-03 Geert Bosch <bosch@adacore.com>
9646
9647 * exp_attr.adb: Fix minor typo.
9648
96492011-08-03 Ed Schonberg <schonberg@adacore.com>
9650
9651 * par-ch4.adb: improve error recovery.
9652
c0e538ad
AC
96532011-08-03 Emmanuel Briot <briot@adacore.com>
9654
9655 * prj-part.adb, prj-part.ads, prj-makr.adb, prj-pars.adb, prj-conf.adb,
9656 prj-env.adb (Prj.Part.Parse): change parameter Always_Errout_Finalize
9657 to Errout_Handling.
9658
96592011-08-03 Emmanuel Briot <briot@adacore.com>
9660
9661 * prj-dect.adb (Parse_Attribute_Declaration): make sure we can use
9662 "external" as an attribute name in aggregate projects.
9663
96642011-08-03 Jose Ruiz <ruiz@adacore.com>
9665
9666 * s-taprop-vxworks.adb: (Create_Task, Initialize): Ada 2012 pragma CPU
9667 uses CPU numbers starting 1, while VxWorks uses CPU numbers starting
9668 from 0, so we need to adjust.
9669
96702011-08-03 Emmanuel Briot <briot@adacore.com>
9671
9672 * prj-proc.adb, prj-ext.adb, prj-ext.ads, makeutl.adb, prj-tree.adb,
9673 prj-tree.ads, gnatcmd.adb, clean.adb (External_References): new type.
9674
c4d67e2d
AC
96752011-08-03 Yannick Moy <moy@adacore.com>
9676
9677 * sem_ch6.adb (New_Overloaded_Entity): only issue error for SPARK
9678 restriction on overloaded entity if the entity is not an operator.
9679
96802011-08-03 Yannick Moy <moy@adacore.com>
9681
9682 * sem_ch7.adb, sem_res.adb, sem_attr.adb, restrict.adb,
9683 restrict.ads: Rename remaining Check_Formal_Restriction* into
9684 Check_SPARK_Restriction*.
9685
96862011-08-03 Emmanuel Briot <briot@adacore.com>
9687
9688 * prj-proc.adb, prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb,
9689 prj-nmsc.ads, prj-err.adb (Project_Data): now discriminated on its
9690 qualifier.
9691 (Project_Empty): removed
9692 (Empty_Project): new parameter Qualifier
9693 This is used to have fields specific to aggregate projects, cleaner
9694 New field to store the list of aggregated projects.
9695 (Check_Aggregate_Project): removed
9696 (Process_Aggregated_Projects, Free): new subprograms.
9697
3f5a8fee
AC
96982011-08-03 Olivier Hainque <hainque@adacore.com>
9699
9700 * tracebak.c (STOP_FRAME ppc AIX): Stop at null return address as well.
9701
97022011-08-03 Ed Schonberg <schonberg@adacore.com>
9703
9704 * sem_ch8.adb (Analyze_Object_Renaming): if the renamed object is an
9705 explicit dereference of an unconstrained type, create a constrained
9706 subtype for it, as is done for function calls that return an
9707 unconstrained type.
9708
97092011-08-03 Thomas Quinot <quinot@adacore.com>
9710
9711 * g-pehage.adb (Finalize): Avoid possible double-free.
9712
97132011-08-03 Steve Baird <baird@adacore.com>
9714
9715 * exp_attr.adb (Expand_N_Attribute_Reference): Don't expand
9716 Elab_Spec/Body attrs in CodePeer_Mode.
9717
97182011-08-03 Javier Miranda <miranda@adacore.com>
9719
9720 * exp_aggr.adb (Flatten): Convert to positional form aggregates whose
9721 low bound is not known at compile time but they have no others choice.
9722 Done because in this case the bounds can be obtained directly from the
9723 aggregate.
9724
97252011-08-03 Ed Falis <falis@adacore.com>
9726
9727 * s-tasinf-vxworks.ads: Update comment to reflect 0 indexing of CPUs
9728 on VxWorks SMP. Remove unusable constant ANY_CPU.
9729
a96ca600
EB
97302011-08-03 Emmanuel Briot <briot@adacore.com>
9731
9732 * gnatcmd.adb, make.adb, prj-part.adb, prj-part.ads, prj-makr.adb,
9733 clean.adb, prj-nmsc.adb, prj-pars.adb, prj-conf.adb, prj-env.adb,
9734 prj-env.ads (Prj.Env.Initialize_Default_Project_Path,
9735 Prj.Env.Initialize_Empty): new subprograms
9736 (Get_Env, Find_Project): remove parameter Target_Name.
9737
3e582869
AC
97382011-08-03 Gary Dismukes <dismukes@adacore.com>
9739
9740 * sem_ch3.adb (Build_Derived_Record_Type): Test the Derive_Subps formal
9741 as a condition for the delayed call to Derived_Subprograms done for the
9742 case of the rewriting of a derived type that constrains the
9743 discriminants of its parent type.
9744 Avoids redundant subprogram derivations for private subtype derivations.
9745
97462011-08-03 Javier Miranda <miranda@adacore.com>
9747
9748 * exp_aggr.adb (Init_Hidden_Discriminants): New subprogram of
9749 Build_Record_Aggr_Code.
9750 (Build_Record_Aggr_Code): Add missing support to initialize hidden
9751 discriminants in extension aggregates.
9752
97532011-08-03 Emmanuel Briot <briot@adacore.com>
9754
9755 * prj-pp.adb (Print): also output project qualifiers, since in
9756 particular "aggregate" is mandatory in an aggregate project.
9757
97582011-08-03 Emmanuel Briot <briot@adacore.com>
9759
9760 * prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb, prj-env.adb:
9761 (Debug_Output): new function.
9762
56e94186
AC
97632011-08-03 Eric Botcazou <ebotcazou@adacore.com>
9764
9765 * gnat_ugn.texi: Document -Wstack-usage.
9766 * gcc-interface/misc.c (enumerate_modes): Add guard for ghost FP modes.
9767
97682011-08-03 Thomas Quinot <quinot@adacore.com>
9769
9770 * sem_prag.adb Issue an error (not a warning) when a C++ type does not
9771 have keyword LIMITED.
9772
97732011-08-03 Yannick Moy <moy@adacore.com>
9774
9775 * alfa.adb, alfa.ads, alfa_test.adb: New files.
9776 * ali.adb (Known_ALI_Lines): add 'C' lines (SCO) and 'F' lines (ALFA)
9777 (Scan_ALI): do not issue a fatal error if parsing known lines after Xref
9778 section (does not happen in compiler, only if code directly calls
9779 Scan_ALI).
9780 * get_alfa.adb, get_alfa.ads: New files.
9781 * lib-writ.adb, lib-writ.ads (Write_ALI): output ALFA information if
9782 needed.
9783 * lib-xref-alfa.adb: New file.
9784 * lib-xref.adb, lib-xref.ads
9785 (Xref_Entry): redefine information needed in cross-references for ALFA.
9786 Push ALFA treatments in separated local package.
9787 (Enclosing_Subpragram_Or_Package): treat specially subprogram
9788 identifiers. Return entity of package body instead of spec. Return
9789 Empty for a scope with no location.
9790 (Generate_Reference): adapt to new components for ALFA information.
9791 Remove the need for D references on definitions.
9792 (Is_Local_Reference): moved to ALFA local package
9793 (Output_References): extract subfunction as Extract_Source_Name
9794 (Output_Local_References): remove procedure, replaced by filtering of
9795 cross-references in package ALFA and printing in Put_ALFA.
9796 (Write_Entity_Name): remove procedure
9797 * lib.adb, lib.ads (Extract_Source_Name): extract here function to
9798 print exact name of entity as it appears in source file
9799 (Unit_Ref_Table): make type public for use in Lib.Xref.ALFA
9800 * put_alfa.adb, put_alfa.ads: New files.
9801 * xref_lib.adb (Search_Xref): protect read of cross-references against
9802 reading other sections of the ALI file, in gnatxref
9803 (Search): protect read of cross-references against reading other
9804 sections of the ALI file, in gnatfind.
9805 * gcc-interface/Make-lang.in: Update dependencies.
9806
98072011-08-03 Thomas Quinot <quinot@adacore.com>
9808
9809 * sem_ch3.adb: Minor reformatting.
9810
98112011-08-03 Jose Ruiz <ruiz@adacore.com>
9812
9813 * s-inmaop-vxworks.adb (Setup_Interrupt_Mask): Do nothing instead of
9814 raising an exception.
9815
98162011-08-03 Ed Schonberg <schonberg@adacore.com>
9817
9818 * sem_res.adb (Set_String_Literal_Subtype): if index type is an integer
9819 type, always use 1 as the lower bound or string, even if lower bound of
9820 context is not static, to handle properly null strings in a non-static
9821 context.
9822
98232011-08-03 Bob Duff <duff@adacore.com>
9824
9825 * sem_prag.adb (Resolve_Aggregate): An array aggregate with 'others' is
9826 always legal on the right-hand side of an assignment statement; there
9827 is always an applicable index constraint in this case. Therefore, the
9828 check for Pkind = N_Assignment_Statement is now unconditional -- it
9829 doesn't depend on whether Is_Constrained (Typ).
9830
4317e442
AC
98312011-08-03 Robert Dewar <dewar@adacore.com>
9832
9833 * exp_ch5.adb, sem_prag.adb, exp_ch4.adb: Minor reformatting.
9834
98352011-08-03 Ed Schonberg <schonberg@adacore.com>
9836
9837 * sem_ch3.adb (Build_Itype_Reference): do not create an itype reference
9838 for an itype created within a generic unit.
9839
98402011-08-03 Eric Botcazou <ebotcazou@adacore.com>
9841
9842 * gnat_ugn.texi (Switches for gcc): Make it clearer that -fno-inline
9843 suppresses all inlining.
9844
53f29d4f
AC
98452011-08-03 Robert Dewar <dewar@adacore.com>
9846
9847 * sem_ch3.adb, sem_res.adb, exp_ch13.adb, exp_disp.adb,
9848 exp_aggr.adb: Minor reformatting.
9849
98502011-08-03 Thomas Quinot <quinot@adacore.com>
9851
9852 * exp_ch5.adb (Expand_N_Assignment_Statement): Do not force inlining of
9853 tagged assignment when discriminant checks are suppressed. This is
9854 useless and extremely costly in terms of static stack usage.
9855
98562011-08-03 Bob Duff <duff@adacore.com>
9857
9858 * sem_prag.adb (Get_Base_Subprogram): Do not follow Alias for instances
9859 of generics, because this leads to the wrong entity in the wrong scope,
9860 causing (e.g.) pragma Export_Procedure to get an error if the entity is
9861 an instance.
9862 (Process_Interface_Name): Follow Alias for instances of generics, to
9863 correct for the above change.
9864
98652011-08-03 Ed Schonberg <schonberg@adacore.com>
9866
9867 * exp_ch4.adb (Expand_N_Selected_Component): If the discriminant value
9868 is an integer literal it is always safe to replace the reference. In
9869 addition, if the reference appears in the generated code for an object
9870 declaration it is necessary to copy because otherwise the reference
9871 might be to the uninitilized value of the discriminant of the object
9872 itself.
9873
98742011-08-03 Pascal Obry <obry@adacore.com>
9875
9876 * adaint.c (__gnat_is_executable_file_attr): Fix Win32 circuitry when no
9877 ACL used, in this case we want to check for ending .exe, not .exe
9878 anywhere in the path.
9879
98802011-08-03 Sergey Rybin <rybin@adacore.com>
9881
9882 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
9883 the tree structure (semantic decoration of references to record
9884 discriminants).
9885
c0b11850
AC
98862011-08-03 Gary Dismukes <dismukes@adacore.com>
9887
9888 * sem_aggr.adb (Analyze_Array_Aggregate): When checking the discrete
9889 choices of a named array aggregate, bail out when any choices are
9890 marked as Errors_Posted.
9891
98922011-08-03 Ed Schonberg <schonberg@adacore.com>
9893
9894 * exp_ch13.adb (Expand_N_Freeze_Entity): cleanup determination of scope
9895 in which entity is frozen, to handle properly loop variables in
9896 iterators.
9897
98982011-08-03 Ed Schonberg <schonberg@adacore.com>
9899
9900 * sem_res.adb (Set_String_Literal_Subtype): if the lower bound of the
9901 subtype is not static, compute the upper bound using attributes, to
9902 handle properly index types that are not integer types.
9903
99042011-08-03 Bob Duff <duff@adacore.com>
9905
9906 * gnat_rm.texi, gnat_ugn.texi: Fix some dangling URLs.
9907 Update copyright notice.
9908
99092011-08-03 Ed Schonberg <schonberg@adacore.com>
9910
9911 * sem_ch3.adb (Build_Discriminant_Constraints): Only use
9912 Original_Discriminant if within an instance.
9913 * sem_ch4.adb (Analyze_Selected_Component): Ditto.
9914
99152011-08-03 Thomas Quinot <quinot@adacore.com>
9916
9917 * einfo.ads: Minor reformatting.
9918
99192011-08-03 Ed Schonberg <schonberg@adacore.com>
9920
9921 * exp_disp.adb (Check_Premature_Freezing): diagnose the presence of a
9922 composite type with an unfrozen subcomponent, in the profile of a
9923 primitive operation.
9924
5c34e9cd
AC
99252011-08-03 Robert Dewar <dewar@adacore.com>
9926
9927 * sem_util.ads, exp_aggr.adb, exp_ch3.adb: Minor reformatting.
9928
99292011-08-03 Ed Schonberg <schonberg@adacore.com>
9930
9931 * sem_ch3.adb (Analyze_Object_Declaration): if a constant object of an
9932 unconstrained type with discriminants is initialized with an aggregate,
9933 use the constrained subtype of the aggregate as the type of the object,
9934 because it is immutable, and this allows the back-end to generate no
9935 code for the object declaration.
9936
abcd9db2
AC
99372011-08-03 Robert Dewar <dewar@adacore.com>
9938
9939 * exp_ch4.adb (Optimize_Length_Check): Fix bad handling of case where
9940 comparison operand is variable, and turns out to be zero or negative.
9941
99422011-08-03 Javier Miranda <miranda@adacore.com>
9943
9944 * exp_intr.adb
9945 (Expand_Dispatching_Constructor_Call): Disable expansion of
9946 code required for native targets. Done to avoid generating
9947 references to unavailable runtime entities in VM targets.
9948 * exp_ch3.adb
9949 (Expand_N_Object_Declaration): Add missing support to handle
9950 the explicit initialization of class-wide interface objects.
9951 Fix documentation.
9952
99532011-08-03 Matthew Heaney <heaney@adacore.com>
9954
7089ef0f
GP
9955 * a-cobove.adb (Merge): Move source onto target, instead of using
9956 Assign.
abcd9db2
AC
9957
99582011-08-03 Matthew Heaney <heaney@adacore.com>
9959
7089ef0f 9960 * a-cbdlli.adb (Splice): Move source items from first to last.
abcd9db2
AC
9961
99622011-08-03 Yannick Moy <moy@adacore.com>
9963
7089ef0f 9964 * sem_util.ads: Add comment.
abcd9db2
AC
9965
99662011-08-03 Javier Miranda <miranda@adacore.com>
9967
9968 * exp_aggr.adb
9969 (Expand_Record_Aggregate): In VM targets disable the expansion into
9970 assignments of aggregates whose type is not known at compile time.
9971
b474d6c3
ES
99722011-08-03 Ed Schonberg <schonberg@adacore.com>
9973
9974 * exp_ch9.adb (Build_Renamed_Formal_Declaration): common procedure for
9975 protected entries and task entries, to build the proper renaming
9976 declaration for entry formals, used in debugging.
9977 * exp_ch2.adb (Expand_Entry_Parameter): handle task and entry
9978 parameters in the same way.
9979
0580d807
AC
99802011-08-02 Robert Dewar <dewar@adacore.com>
9981
9982 * a-direct.adb, sinfo.ads, exp_ch9.adb, scng.adb, sem_util.adb,
9983 sem_util.ads, restrict.ads, par-prag.adb: Minor reformatting and/or
9984 code reorganization.
9985
99862011-08-02 Robert Dewar <dewar@adacore.com>
9987
9988 * debug.adb: Debug flag d.P to suppress length comparison optimization
9989 * exp_ch4.adb (Optimize_Length_Comparison): New routine to optimize
9990 comparison of Length by comparing First/Last instead.
9991
99922011-08-02 Matthew Heaney <heaney@adacore.com>
9993
9994 * a-cobove.ads: Code clean up.
9995
b191a125
AC
99962011-08-02 Vincent Celier <celier@adacore.com>
9997
9998 * adaint.c (file_names_case_sensitive_cache): New static int.
9999 (__gnat_get_file_names_case_sensitive): Cache the return value in
10000 file_names_case_sensitive_cache at the first invocation, to avoid
10001 multiple calls to getenv.
10002
100032011-08-02 Bob Duff <duff@adacore.com>
10004
10005 * sem_ch12.adb (Validate_Derived_Type_Instance): Implement AI05-0218-1.
10006
316a0661
AC
100072011-08-02 Yannick Moy <moy@adacore.com>
10008
10009 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_prag.adb, sem.ads,
10010 sem_util.adb, sem_util.ads, sem_res.adb, sem_ch2.adb, sem_ch4.adb,
10011 sem_ch6.adb, sem_ch11.adb: Add semantic flag In_Pre_Post_Expression to
10012 indicate that we are in a precondition or postcondition. This is used in
10013 Mark_Non_ALFA_Subprogram (renaming of Mark_Non_ALFA_Subprogram_Body) to
10014 decide whether to flag the spec or body of the current subprogram as
10015 not in ALFA.
10016
100172011-08-02 Fabien Chouteau <chouteau@adacore.com>
10018
10019 * impunit.adb: Add Ada.Execution_Time.Interrupts in the Ada2012 package
10020 list.
10021 * a-extiin.ads: New file.
10022
100232011-08-02 Bob Duff <duff@adacore.com>
10024
10025 * a-direct.adb (Rename): Implement AI05-0231-1. In particular, Rename
10026 now raises Name_Error instead of Use_Error in certain cases. The other
10027 parts of this AI were already implemented properly.
10028
f9adb9d4
AC
100292011-08-02 Vincent Celier <celier@adacore.com>
10030
10031 * link.c: Only import "auto-host.h" when building the gnattools.
10032
100332011-08-02 Yannick Moy <moy@adacore.com>
10034
10035 * sem_util.adb: Inter-unit inlining does not work for a subprogram
10036 which calls a local subprogram, so extract subprogram
10037 from Mark_Non_ALFA_Subprogram_Body.
10038
100392011-08-02 Javier Miranda <miranda@adacore.com>
10040
10041 * exp_ch9.adb
10042 (Extract_Dispatching_Call): If the type of the dispatching object is an
10043 access type then return an explicit dereference in the Object out-mode
10044 parameter.
10045
100462011-08-02 Gary Dismukes <dismukes@adacore.com>
10047
10048 * sem_ch3.adb (Analyze_Subtype_Declaration): Generate range
10049 compatibility checks for all indexes of an array subtype, not just the
10050 first. Reset Has_Dynamic_Range_Check on the subtype before each
10051 potential check to ensure that Insert_Range_Checks will not elide any
10052 of the dynamic checks.
10053
100542011-08-02 Yannick Moy <moy@adacore.com>
10055
10056 * par-prag.ad (Process_Restrictions_Or_Restriction_Warnings): recognize
10057 SPARK restriction at parsing time.
10058 * scng.adb (Scan): Generate a token Tok_SPARK_Hide for a SPARK HIDE
10059 directive only if the SPARK restriction is set for this unit.
10060
83f33150
YM
100612011-08-02 Yannick Moy <moy@adacore.com>
10062
10063 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb, sem_util.ads,
10064 sem_res.adb, sem_ch2.adb, sem_ch4.adb, sem_ch6.adb,
10065 sem_ch11.adb: Protect call to Current_Subprogram which might be costly
10066 when repeated. Rename Current_Subprogram_Is_Not_In_ALFA into
10067 Mark_Non_ALFA_Subprogram_Body.
10068 Split body of Mark_Non_ALFA_Subprogram_Body to get body small and
10069 inlined.
10070
7b98672f
YM
100712011-08-02 Yannick Moy <moy@adacore.com>
10072
10073 * sem_res.adb: Protect calls to Matching_Static_Array_Bounds which
10074 might be costly.
10075
052e0603
AC
100762011-08-02 Robert Dewar <dewar@adacore.com>
10077
10078 * exp_ch9.adb, exp_sel.adb, restrict.ads, exp_disp.adb, erroutc.ads,
10079 exp_ch3.adb: Minor reformatting.
10080
100812011-08-02 Emmanuel Briot <briot@adacore.com>
10082
10083 * adaint.c (__gnat_locate_exec_on_path): only returns executable
10084 files, not any regular file.
10085 (__gnat_locate_file_with_predicate): new subprogram.
10086
100872011-08-02 Yannick Moy <moy@adacore.com>
10088
10089 * sinfo.adb, sinfo.ads: Restrict the use of flags
10090 Has_Dynamic_Length_Check and Has_Dynamic_Range_Check to expression
10091 nodes, plus N_Subtype_Declaration for the 2nd one.
10092
4fbad0ba
AC
100932011-08-02 Sergey Rybin <rybin@adacore.com>
10094
10095 * gnat_rm.texi: Ramification of pragma Eliminate documentation
10096 - fix bugs in the description of Source_Trace;
10097 - get rid of UNIT_NAME;
10098
052e0603
AC
100992011-08-02 Javier Miranda <miranda@adacore.com>
10100
10101 * exp_ch9.adb
10102 (Build_Dispatching_Requeue): Adding support for VM targets
10103 since we cannot directly reference the Tag entity.
10104 * exp_sel.adb (Build_K): Adding support for VM targets.
10105 (Build_S_Assignment): Adding support for VM targets.
10106 * exp_disp.adb
10107 (Default_Prim_Op_Position): In VM targets do not restrict availability
10108 of predefined interface primitives to compiling in Ada 2005 mode.
10109 (Is_Predefined_Interface_Primitive): In VM targets this service is not
10110 restricted to compiling in Ada 2005 mode.
10111 (Make_VM_TSD): Generate code that declares and initializes the OSD
10112 record. Needed to support dispatching calls through synchronized
10113 interfaces.
10114 * exp_ch3.adb
10115 (Make_Predefined_Primitive_Specs): Enable generation of predefined
10116 primitives associated with synchronized interfaces.
10117 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
10118 primitives associated with synchronized interfaces.
10119
101202011-08-02 Yannick Moy <moy@adacore.com>
10121
10122 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
10123 statements hidden in SPARK if preceded by the HIDE directive
10124 (Parse_Exception_Handlers): mark each exception handler in a sequence of
10125 exception handlers as hidden in SPARK if preceded by the HIDE directive
10126 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
10127 if starting with the HIDE directive
10128 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
10129 starting with the HIDE directive; mark the declarations in a private
10130 part as hidden in SPARK if the private part starts with the HIDE
10131 directive
10132 * restrict.adb, restrict.ads
10133 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
10134 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
10135 argument node belongs to a part which is hidden in SPARK
10136 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
10137 parts in SPARK; protect the possibly costly call to
10138 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
10139 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
10140 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
10141 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
10142 Tok_SPARK_Hide.
10143 (Scan): recognize special comment starting with '#' and followed by
10144 SPARK keyword "hide" as a HIDE directive.
10145
101462011-08-02 Yannick Moy <moy@adacore.com>
10147
10148 * types.ads, erroutc.ads: Minor reformatting.
10149
101502011-08-02 Vincent Celier <celier@adacore.com>
10151
10152 * link.c: Add response file support for cross platforms.
10153
101542011-08-02 Ed Schonberg <schonberg@adacore.com>
10155
10156 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
10157 in an association, set parent field of copy before partial analysis.
10158 * sem_res.adb (Resolve_Slice): create reference to itype only when
10159 expansion is enabled.
10160
101612011-08-02 Yannick Moy <moy@adacore.com>
10162
10163 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
10164 for new flag denoting which subprogram bodies are in ALFA
10165 * restrict.adb, sem_ch7.adb: Update comment
10166 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
10167 sem_ch9.adb, sem_res.adb: Add calls to
10168 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
10169 * sem_ch6.adb (Analyze_Function_Return): add calls to
10170 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
10171 middle of the body, and extended return.
10172 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
10173 False when missing return.
10174 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
10175 to True for subprograms whose spec is in ALFA. Remove later on the flag
10176 on the entity used for a subprogram body when there exists a separate
10177 declaration.
10178 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
10179 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
10180 False, otherwise do nothing.
10181
101822011-08-02 Robert Dewar <dewar@adacore.com>
10183
10184 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
10185
101862011-08-02 Yannick Moy <moy@adacore.com>
10187
10188 * sem_ch4.ads: minor formatting.
10189
101902011-08-02 Yannick Moy <moy@adacore.com>
10191
10192 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
10193 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
10194 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
10195 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
10196 opt.ads: cleanup of SPARK mode
10197
101982011-08-02 Yannick Moy <moy@adacore.com>
10199
10200 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
10201 types.
10202 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
10203 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
10204 * sem_ch3.adb
10205 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
10206 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
10207 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
10208 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
10209 types.
10210 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
10211 non-static range.
10212 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
10213 functions whose return type is not in ALFA.
10214 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
10215 specifications.
10216 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
10217 parameter's type is not in ALFA.
10218 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
10219 types are in ALFA.
10220
102212011-08-02 Ed Schonberg <schonberg@adacore.com>
10222
10223 * sem_ch6 (Analyze_Expression_Function): treat the function as
10224 Inline_Always, and introduce a subprogram declaration for it when it is
10225 not a completion.
10226 * inline.adb (Add_Inlined_Body): recognize bodies that come from
10227 expression functions, so that the back-end can determine whether they
10228 can in fact be inlined.
10229 * sem_util.adb (Is_Expression_Function): predicate to determine whether
10230 a function body comes from an expression function.
10231
102322011-08-02 Gary Dismukes <dismukes@adacore.com>
10233
10234 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
10235 null exclusions to test Can_Never_Be_Null on the anonymous access types
10236 of the formals rather than testing the formals themselves. Exclude this
10237 check in cases where the Old_Formal is marked as a controlling formal,
10238 to avoid issuing spurious errors for bodies completing dispatching
10239 operations (due to the flag not getting set on controlling access
10240 formals in body specs).
10241 (Find_Corresponding_Spec): When checking full and subtype conformance of
10242 subprogram bodies in instances, pass Designated and E in that order, for
10243 consistency with the expected order of the formals (New_Id followed by
10244 Old_Id).
10245
102462011-08-02 Robert Dewar <dewar@adacore.com>
10247
10248 * sem_ch8.adb: Minor reformatting.
10249
102502011-08-02 Ed Schonberg <schonberg@adacore.com>
10251
10252 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
10253 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
10254 primitive operations of class-wide actuals.
10255
102562011-08-02 Javier Miranda <miranda@adacore.com>
10257
10258 * exp_atag.ads, exp_atag.adb
10259 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
10260 since its value is implicitly passed in argument Typ.
10261 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
10262 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
10263 Build_Common_Dispatching_Select_Statements.
10264
102652011-08-02 Robert Dewar <dewar@adacore.com>
10266
10267 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
10268 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
10269 Minor reformatting.
10270
102712011-08-02 Robert Dewar <dewar@adacore.com>
10272
10273 * sem_res.adb: Minor reformatting.
10274 * sem_prag.adb: Minor reformatting.
10275
102762011-08-02 Javier Miranda <miranda@adacore.com>
10277
10278 * exp_atag.adb, exp_atags.ads
10279 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
10280 by the tagged type Entity. Required to use this routine in the VM
10281 targets since we do not have available the Tag entity in the VM
10282 platforms.
10283 * exp_ch6.adb
10284 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
10285 Ada.Tags has not been previously loaded.
10286 * exp_ch7.adb
10287 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
10288 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
10289 * sem_aux.adb
10290 (Enclosing_Dynamic_Scope): Add missing support to handle the full
10291 view of enclosing scopes. Required to handle enclosing scopes that
10292 are synchronized types whose full view is a task type.
10293 * exp_disp.adb
10294 (Build_VM_TSDs): Minor code improvement to avoid generating and
10295 analyzing lists with empty nodes.
10296 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
10297 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
10298 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
10299 (Make_Disp_Timed_Select_Body): Add support for VM targets.
10300 (Make_Select_Specific_Data_Table): Add support for VM targets.
10301 (Make_VM_TSD): Generate code to initialize the SSD structure of
10302 the TSD.
10303
103042011-08-02 Yannick Moy <moy@adacore.com>
10305
10306 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
10307 cross-references section in ALI.
10308 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
10309 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
10310 Sub).
10311 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
10312 subprogram or package entity of a node
10313 (Is_Local_Reference_Type): new function returns True for references
10314 selected in local cross-references.
10315 (Lt): function extracted from Lt in Output_References
10316 (Write_Entity_Name): function extracted from Output_References
10317 (Generate_Definition): generate reference with type 'D' for definition
10318 of objects (object declaration and parameter specification), with
10319 appropriate locations and units, for use in local cross-references.
10320 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
10321 references of type 'I' for initialization in object definition.
10322 (Output_References): move part of function Lt and procedure
10323 Write_Entity_Name outside of the body. Ignore references of types 'D'
10324 and 'I' introduced for local cross-references.
10325 (Output_Local_References): new procedure to output the local
10326 cross-references sections.
10327 (Lref_Entity_Status): new array defining whether an entity is a local
10328 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
10329 with 'I' type when initialization expression is present.
10330 * get_scos.adb, get_scos.ads: Correct comments and typos
10331
103322011-08-02 Javier Miranda <miranda@adacore.com>
10333
10334 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
10335 the JVM target.
10336 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
10337 the JVM target.
10338 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
10339 TSD support.
10340
103412011-08-02 Vincent Celier <celier@adacore.com>
10342
10343 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
10344 (No_Space_Img): New function
10345 (Find_Excluded_Sources): When reading from a file, record the file name
10346 and the line number for each excluded source.
10347 (Mark_Excluded_Sources): When reporting an error, if the excluded
10348 sources were read from a file, include file name and line number in
10349 the error message.
10350
103512011-08-02 Ed Schonberg <schonberg@adacore.com>
10352
10353 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
10354
103552011-08-02 Robert Dewar <dewar@adacore.com>
10356
10357 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
10358
103592011-08-02 Javier Miranda <miranda@adacore.com>
10360
10361 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
10362 generation of TSDs to the DOTNET compiler.
10363 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
10364 generation of TSDs to the DOTNET compiler.
10365
103662011-08-02 Javier Miranda <miranda@adacore.com>
10367
10368 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
10369 record of all the tagged types declared inside library level package
10370 declarations, library level package bodies or library level subprograms.
10371 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
10372 associated with a given tagged type.
10373 (Build_VM_TSDs): New subprogram.
10374 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
10375 compilation units that are subprograms.
10376 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
10377 compilation units that are package bodies.
10378 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
10379 units that are a package declaration or a package instantiation.
10380 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
10381 reorganization to improve the error generated by the frontend when the
10382 function Ada.Tags.Secondary_Tag is not available.
10383 * rtsfind.ads (RE_Register_TSD): New runtime entity.
10384 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
10385
103862011-08-02 Javier Miranda <miranda@adacore.com>
10387
10388 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
10389
103902011-08-02 Robert Dewar <dewar@adacore.com>
10391
10392 * s-imenne.ads: Minor reformatting.
10393
103942011-08-02 Robert Dewar <dewar@adacore.com>
10395
10396 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
10397 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
10398 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
10399
104002011-08-02 Robert Dewar <dewar@adacore.com>
10401
10402 * einfo.ads (Materialize_Entity): Document this is only for renamings
10403 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
10404 required debug information in the case where we transform the object
10405 declaration into a renaming declaration.
10406 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
10407 object
10408 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
10409 Materialize_Entity.
10410
104112011-08-02 Robert Dewar <dewar@adacore.com>
10412
10413 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
10414 Suppress_Init_Procs.
10415 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
10416 Suppress_Initialization/Initialization_Suppressed.
10417 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
10418 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
10419 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
10420 * sem_prag.adb: New processing for pragma Suppress_Initialization.
10421
104222011-08-02 Robert Dewar <dewar@adacore.com>
10423
10424 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
10425 Minor reformatting.
10426
104272011-08-02 Ed Schonberg <schonberg@adacore.com>
10428
10429 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
10430 only have inheritable classwide pre/postconditions.
10431
104322011-08-02 Javier Miranda <miranda@adacore.com>
10433
10434 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
10435 * rtsfind.ads (RE_Check_TSD): New runtime entity.
10436 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
10437 checks if the external tag of a type is the same as the external tag
10438 of some other declaration.
10439
104402011-08-02 Thomas Quinot <quinot@adacore.com>
10441
10442 * s-taskin.ads: Minor reformatting.
10443
104442011-08-02 Emmanuel Briot <briot@adacore.com>
10445
10446 * g-comlin.adb (Display_Help): swap the order in which it prints the
10447 short help and the general usage.
10448
104492011-08-02 Ed Schonberg <schonberg@adacore.com>
10450
10451 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
10452 the aspect declarations and attach them to the generic copy for
10453 subsequent analysis.
10454 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
10455 declarations of the generic tree to the new subprogram declarations.
10456 * sem_attr.adb (Check_Precondition_Postcondition): recognize
10457 conditions that apply to a subprogram instance.
10458
104592011-08-02 Robert Dewar <dewar@adacore.com>
10460
10461 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
10462
104632011-08-02 Ed Schonberg <schonberg@adacore.com>
10464
10465 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
10466 private type with a tagged full view is not derived in the immediate
10467 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
10468
104692011-08-02 Robert Dewar <dewar@adacore.com>
10470
10471 * exp_ch4.adb: Minor reformatting.
10472
104732011-08-02 Ed Schonberg <schonberg@adacore.com>
10474
10475 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
10476 Ada2012 iterator, the loop will be rewritten during expansion into a
10477 while loop with a cursor and an element declaration. Do not analyze the
10478 body in this case, because if the container is for indefinite types the
10479 actual subtype of the elements will only be determined when the cursor
10480 declaration is analyzed.
10481
104822011-08-02 Arnaud Charlet <charlet@adacore.com>
10483
10484 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
10485 size/alignment related attributes in CodePeer_Mode.
10486
104872011-08-02 Gary Dismukes <dismukes@adacore.com>
10488
10489 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
10490 Prepend_Element, since this can result in the operation getting the
10491 wrong slot in the full type's dispatch table if the full type has
10492 inherited operations. The incomplete type's operation will get added
10493 to the proper position in the full type's primitives
10494 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
10495 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
10496 dispatching operations, since there are cases where nonprimitive
10497 subprograms can get added to the list of incomplete dependents (such
10498 as subprograms in nested packages).
10499 * sem_ch6.adb (Process_Formals): First, remove test for being in a
10500 private part when determining whether to add a primitive with a
10501 parameter of a tagged incomplete type to the Private_Dependents list.
10502 Such primitives can also occur in the visible part, and should not have
10503 been excluded from being private dependents.
10504 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
10505 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
10506 list of a Taft-amendment incomplete type is a primitive before issuing
10507 an error that the full type must appear in the same unit. There are
10508 cases where nonprimitives can be in the list (such as subprograms in
10509 nested packages).
10510 * sem_disp.adb (Derives_From): Use correct condition for checking that
10511 a formal's type is derived from the type of the corresponding formal in
10512 the parent subprogram (the condition was completely wrong). Add
10513 checking that was missing for controlling result types being derived
10514 from the result type of the parent operation.
10515
105162011-08-02 Yannick Moy <moy@adacore.com>
10517
10518 * errout.adb (First_Node): minor renaming
10519 * restrict.adb (Check_Formal_Restriction): put restriction warning on
10520 first node.
10521
105222011-08-02 Yannick Moy <moy@adacore.com>
10523
10524 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
10525 before accessing operands.
10526 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
10527 decide whether an initialization expression respects SPARK rules, as
10528 the plain node is the expanded one. This allows for more valid warnings
10529 to be issued.
10530 * gnat_rm.texi: Minor update.
10531
105322011-08-02 Arnaud Charlet <charlet@adacore.com>
10533
10534 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
10535 previous change.
10536
105372011-08-02 Robert Dewar <dewar@adacore.com>
10538
10539 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
10540
105412011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
10542
10543 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
10544 loop statements and the element renaming declaration with a block when
10545 the element type is controlled.
10546
105472011-08-02 Yannick Moy <moy@adacore.com>
10548
10549 * sinfo.ads: Minor formatting.
10550
105512011-08-02 Ed Schonberg <schonberg@adacore.com>
10552
10553 * sem_aggr.adb (Add_Association): if the association has a box and no
10554 expression, use the Sloc of the aggregate itself for the new
10555 association.
10556 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
10557 the Original_Node.
10558
105592011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
10560
10561 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
10562 When a container is provided via a function call, generate a renaming
10563 of the function result. This avoids the creation of a transient scope
10564 and the premature finalization of the container.
10565 * exp_ch7.adb (Is_Container_Cursor): Removed.
10566 (Wrap_Transient_Declaration): Remove the supression of the finalization
10567 of the list controller when the declaration denotes a container cursor,
10568 it is not needed.
10569
105702011-08-02 Yannick Moy <moy@adacore.com>
10571
10572 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
10573 node is from source, instead of the original node being from source.
10574 * sem_aggr.adb
10575 (Resolve_Array_Aggregate): refine the check for a static expression, to
10576 recognize also static ranges
10577 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
10578 Array_Type_Declaration): postpone the test for the type being a subtype
10579 mark after the type has been resolved, so that component-selection and
10580 expanded-name are discriminated.
10581 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
10582 to distinguish the case of an iteration scheme, so that an error is
10583 issed on a non-static range in SPARK except in an iteration scheme.
10584 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
10585 In_Iter_Schm = True.
10586 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
10587 user-defined operators so that they are allowed in renaming
10588 * sem_ch8.adb
10589 (Find_Selected_Component): refine the check for prefixing of operators
10590 so that they are allowed in renaming. Move the checks for restrictions
10591 on selector name after analysis discriminated between
10592 component-selection and expanded-name.
10593 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
10594 concatenation argument of string type if it is static.
10595 * sem_util.adb, sem_util.ads
10596 (Check_Later_Vs_Basic_Declarations): add a new function
10597 Is_Later_Declarative_Item to decice which declarations are allowed as
10598 later items, in the two different modes Ada 83 and SPARK. In the SPARK
10599 mode, add that renamings are considered as later items.
10600 (Enclosing_Package): new function to return the enclosing package
10601 (Enter_Name): correct the rule for homonyms in SPARK
10602 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
10603 from source (result of expansion) to avoid issuing wrong warnings.
10604
106052011-08-02 Ed Schonberg <schonberg@adacore.com>
10606
10607 * errout.adb: On anything but an expression First_Node returns its
10608 argument.
10609
106102011-08-02 Pascal Obry <obry@adacore.com>
10611
10612 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
10613
106142011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
10615
10616 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
10617 Set the associated loop as the related expression of internally
10618 generated cursors.
10619 * exp_ch7.adb (Is_Container_Cursor): New routine.
10620 (Wrap_Transient_Declaration): Supress the finalization of the list
10621 controller when the declaration denotes a container cursor.
10622
106232011-08-02 Yannick Moy <moy@adacore.com>
10624
10625 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
10626 command line now.
10627 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
10628 expression is a simple expression. This check cannot be performed in
10629 the semantics, so just drop it.
10630 (P_Index_Or_Discriminant_Constraint): move check that the index or
10631 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
10632 semantics. Other cases were previously checked in the semantics.
10633 * par-ch4.adb (P_Name): move checks that a selector name is not
10634 character literal or an operator symbol to Find_Selected_Component in
10635 the semantics
10636 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
10637 declarations are not placed after later declarations in a separate
10638 procedure in Sem_Util (possibly not the best choice?), to be used both
10639 during parsing, for Ada 83 mode, and during semantic analysis, for
10640 SPARK mode.
10641 * par-endh.adb (Check_End): move check that end label is not missing
10642 to Process_End_Label in the semantics
10643 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
10644 the special case for SPARK restriction
10645 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
10646 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
10647 parameter Force to issue the error message even on internal node (used
10648 for generated end label). Call Check_Restriction to check when an error
10649 must be issued. In SPARK mode, issue an error message even if the
10650 restriction is not set.
10651 (Check_Restriction): new procedure with an additional out parameter to
10652 inform the caller that a message has been issued
10653 * sem_aggr.adb: Minor modification of message
10654 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
10655 instead of issuing an error message directly
10656 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
10657 declarations are not placed after later declarations, by calling
10658 Check_Later_Vs_Basic_Declarations
10659 (Analyze_Subtype_Declaration): move here the check that an index or
10660 discriminant constraint must be a subtype mark. Change the check that
10661 a subtype of String must start at one so that it works on subtype marks.
10662 * sem_ch4.adb (Analyze_Call): move here the check that a named
10663 association cannot follow a positional one in a call
10664 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
10665 instead of issuing an error message directly
10666 * sem_ch8.adb (Find_Selected_Component): move here the check that a
10667 selector name is not a character literal or an operator symbol. Move
10668 here the check that the prefix of an expanded name cannot be a
10669 subprogram or a loop statement.
10670 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
10671 procedure called from parsing and semantics to check that basic
10672 declarations are not placed after later declarations
10673 (Process_End_Label): move here the check that end label is not missing
10674
106752011-08-02 Arnaud Charlet <charlet@adacore.com>
10676
10677 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
10678 representation clause in codepeer mode, since it confuses CodePeer and
10679 does not bring useful info.
10680
106812011-08-02 Ed Falis <falis@adacore.com>
10682
10683 * init.c: initialize fp hw on MILS.
10684
106852011-08-02 Ed Schonberg <schonberg@adacore.com>
10686
10687 * errout.adb (First_Node): for bodies, return the node itself (small
10688 optimization). For other nodes, do not check source_unit if the node
10689 comes from Standard.
10690
106912011-08-02 Robert Dewar <dewar@adacore.com>
10692
10693 * exp_ch3.adb: Minor comment additions.
10694 * sem_ch13.adb: Minor reformatting.
10695
106962011-08-02 Pascal Obry <obry@adacore.com>
10697
10698 * make.adb, makeutl.adb: Removes some superfluous directory separator.
10699
107002011-08-02 Robert Dewar <dewar@adacore.com>
10701
10702 * sem_attr.adb: Minor reformatting.
10703
107042011-08-02 Robert Dewar <dewar@adacore.com>
10705
10706 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
10707 (Has_Default_Component_Value): Removed
10708 * einfo.ads Comment updates
10709 (Has_Default_Aspect): Replaces Has_Default_Value
10710 (Has_Default_Component_Value): Removed
10711 * exp_ch13.adb
10712 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
10713 * exp_ch3.adb
10714 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
10715 (Get_Simple_Init_Val): Handle Default_Value aspect
10716 (Needs_Simple_Initialization): Handle Default_Value aspect
10717 * exp_ch3.ads: Needs_Simple_Initialization
10718 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
10719 * par-prag.adb (Pragma_Default[_Component]Value) Removed
10720 * sem_ch13.adb
10721 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
10722 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
10723 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
10724
107252011-08-02 Ed Schonberg <schonberg@adacore.com>
10726
10727 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
10728 package containing iteration primitives.
10729 exp_ch5.adb (Expand_Iterator_Loop): ditto.
10730
107312011-08-02 Ed Schonberg <schonberg@adacore.com>
10732
10733 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
10734 "of", pre-analyze expression in case it is a function call with
10735 finalization actions that must be placed ahead of the loop.
10736 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
10737 on an Ada2012 iterator, insert them ahead of the rewritten loop.
10738
107392011-08-02 Geert Bosch <bosch@adacore.com>
10740
10741 * cstand.adb (Create_Float_Types): Only consider C's long double for
10742 Long_Long_Float, in addition to double.
10743
107442011-08-02 Robert Dewar <dewar@adacore.com>
10745
10746 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
10747 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
10748 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
10749 Minor reformatting.
10750
107512011-08-02 Ed Schonberg <schonberg@adacore.com>
10752
10753 * sem_attr.adb: handle properly 'Result when it is a prefix of an
10754 indexed component.
10755
107562011-08-02 Javier Miranda <miranda@adacore.com>
10757
10758 * einfo.ads, einfo.adb
10759 (Original_Access_Type): Move this attribute to Node26 since there was
10760 an undocumented use of Node21 in E_Access_Subprogram_Type entities
10761 which causes conflicts and breaks the generation of the .NET compiler.
10762 (Interface_Name): Add missing documentation on JGNAT only uses of
10763 this attribute.
10764
107652011-08-02 Geert Bosch <bosch@adacore.com>
10766
10767 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
10768 (Find_Back_End_Float_Type): Likewise
10769 (Create_Back_End_Float_Types): Likewise
10770 (Create_Float_Types): Likewise
10771 (Register_Float_Type): Likewise
10772 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
10773 Nlist and split out type selection in new local Find_Base_Type function.
10774 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
10775 Nlist
10776 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
10777
107782011-08-02 Robert Dewar <dewar@adacore.com>
10779
10780 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
10781 alpha order).
10782 * opt.ads: Minor comment change.
10783 * sem_ch12.adb: Minor code reorganization.
10784
107852011-08-02 Gary Dismukes <dismukes@adacore.com>
10786
10787 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
10788 subtype's list of rep items to the list on the full subtype in the case
10789 where the lists are the same.
10790
107912011-08-02 Geert Bosch <bosch@adacore.com>
10792
10793 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
10794 using the one from System.Strings, which also deallocates all strings.
10795
107962011-08-02 Geert Bosch <bosch@adacore.com>
10797
10798 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
10799 function.
10800 * gcc-interface/Make-lang.in: Update dependencies.
10801
108022011-08-02 Olivier Hainque <hainque@adacore.com>
10803
10804 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
10805 end_locus.
10806
108072011-08-02 Javier Miranda <miranda@adacore.com>
10808
10809 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
10810 associated with anonymous access to subprograms.
10811
108122011-08-02 Geert Bosch <bosch@adacore.com>
10813
10814 * opt.ads
10815 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
10816 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
10817 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
10818 (Add_Symbol_Definition): Move to switch-c.adb
10819 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
10820 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
10821 (Add_Symbol_Definition): Move to switch-c.adb.
10822 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
10823 * sem_warn.adb
10824 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
10825 Move to warnsw.adb.
10826 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
10827 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
10828 Move to warnsw.adb.
10829 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
10830 (Add_Symbol_Definition): Moved from Prepcomp.
10831 * switch-c.ads: Update copyright notice. Use String_List instead of
10832 Argument_List, removing dependency on System.OS_Lib.
10833
108342011-08-02 Yannick Moy <moy@adacore.com>
10835
10836 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
10837 mode on initialization expression which does not respect SPARK
10838 restrictions.
10839 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
10840 if the tree referenced by its argument represents an initialization
10841 expression in SPARK, suitable for initializing an object in an object
10842 declaration.
10843
108442011-08-02 Javier Miranda <miranda@adacore.com>
10845
10846 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
10847 internally generated access to subprogram with its associated protected
10848 subprogram type.
10849 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
10850
108512011-08-02 Geert Bosch <bosch@adacore.com>
10852
10853 * cstand.adb (Register_Float_Type): Print information about type to
10854 register, if the Debug_Flag_Dot_B is set.
10855 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
10856 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
10857 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
10858 with a requested precision of more than Max_Digits digits and no more
10859 than Max_Base_Digits digits, if a range specification is present and the
10860 Predefined_Float_Types list has a suitable type to derive from.
10861 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
10862 case of type completion with pragma Import
10863 * sem_prag.adb
10864 (Process_Import_Predefined_Type): Processing to complete a type
10865 with pragma Import. Currently supports floating point types only.
10866 (Set_Convention_From_Pragma): Do nothing without underlying type.
10867 (Process_Convention): Guard against absence of underlying type,
10868 which may happen when importing incomplete types.
10869 (Process_Import_Or_Interface): Handle case of importing predefined
10870 types. Tweak error message.
10871
108722011-08-02 Eric Botcazou <ebotcazou@adacore.com>
10873
10874 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
10875 functions to previous change. Reorganize code slightly.
10876
108772011-08-02 Geert Bosch <bosch@adacore.com>
10878
10879 * back_end.ads (Register_Type_Proc): New call back procedure type for
10880 allowing the back end to provide information about available types.
10881 (Register_Back_End_Types): New procedure to register back end types.
10882 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
10883 available types.
10884 * cstand.adb (Back_End_Float_Types): New list for floating point types
10885 supported by the back end.
10886 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
10887 (Copy_Float_Type): New procedure to make new copies of predefined types.
10888 (Register_Float_Type): New call back procedure to populate the BEFT list
10889 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
10890 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
10891 (Create_Float_Types): New procedure to create entities for floating
10892 point types predefined in Standard, and put these and any remaining
10893 BEFTs on the Predefined_Float_Types list.
10894 * stand.ads (Predefined_Float_Types): New list for predefined floating
10895 point types that do not have declarations in package Standard.
10896
108972011-08-02 Eric Botcazou <ebotcazou@adacore.com>
10898
10899 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
10900 entity node for the unit containing the parameter.
10901 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
10902 (Add_Inlined_Subprogram): Likewise.
10903 * gcc-interface/Make-lang.in: Update dependencies.
10904
109052011-08-02 Thomas Quinot <quinot@adacore.com>
10906
10907 * s-stusta.adb (Print): Make sure Pos is always initialized to a
10908 suitable value.
10909
109102011-08-02 Geert Bosch <bosch@adacore.com>
10911
10912 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
10913
109142011-08-02 Eric Botcazou <ebotcazou@adacore.com>
10915
10916 * sem_type.adb (Covers): Move trivial case to the top and reuse the
10917 computed value of Base_Type.
10918
109192011-08-02 Yannick Moy <moy@adacore.com>
10920
10921 * restrict.adb (Check_Restriction): issue an error for any use of
10922 class-wide, even if the No_Dispatch restriction is not set.
10923 * sem_aggr.adb: Correct typos in comments and messages in formal mode
10924 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
10925 when completing a private extension, the type named in the private part
10926 is not the same as that named in the visible part.
10927 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
10928 of an inherited primitive operations of a tagged type or type extension
10929 that returns the tagged type.
10930 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
10931 function which returns True for an implicit operation inherited by the
10932 derived type declaration for the argument type.
10933 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
10934 order.
10935
109362011-08-02 Ed Schonberg <schonberg@adacore.com>
10937
10938 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
10939 Process_Bounds, to perform analysis with expansion of a range or an
10940 expression that is the iteration scheme for a loop.
10941 (Analyze_Iterator_Specification): If domain of iteration is given by a
10942 function call with a controlled result, as is the case if call returns
10943 a predefined container, ensure that finalization actions are properly
10944 generated.
10945 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
10946
109472011-08-02 Javier Miranda <miranda@adacore.com>
10948
10949 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
10950 * gcc-interface/Make-lang.in: Update dependencies.
10951
109522011-08-02 Javier Miranda <miranda@adacore.com>
10953
10954 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
10955 determine if the analysis is performed using N or Original_Node (N).
10956 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
10957 functionality of routine Is_Variable avoids code duplication.
10958 * checks.adb (Determine_Range): Handle temporaries generated by
10959 Remove_Side_Effects.
10960
109612011-08-02 Javier Miranda <miranda@adacore.com>
10962
10963 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
10964 expansion of the condition. Required since the previous analysis was
10965 done with expansion disabled (see Resolve_Quantified_Expression) and
10966 hence checks were not inserted and record comparisons have not been
10967 expanded.
10968
109692011-08-02 Ed Falis <falis@adacore.com>
10970
10971 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
10972 Update header.
10973
109742011-08-02 Bob Duff <duff@adacore.com>
10975
10976 * opt.ads: Minor comment fix.
10977
109782011-08-02 Bob Duff <duff@adacore.com>
10979
10980 * sem_ch12.adb (Analyze_Package_Instantiation,
10981 Analyze_Subprogram_Instantiation): Turn off style checking while
10982 analyzing an instance. Whatever style checks that apply to the generic
10983 unit should apply, so it makes no sense to apply them in an instance.
10984 This was causing trouble when compiling an instance of a runtime
10985 unit that violates the -gnatyO switch.
10986 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
10987 one of the two case statements, causing spurious errors.
10988
109892011-08-02 Robert Dewar <dewar@adacore.com>
10990
10991 * uname.adb: Minor reformatting.
10992 * gnatcmd.adb: Minor reformatting.
10993 * exp_attr.adb: Minor reformatting.
10994
109952011-08-02 Ed Schonberg <schonberg@adacore.com>
10996
10997 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
10998 No_Dispatching_Calls, do not look for the Assign primitive, because
10999 predefined primitives are not created in this case.
11000
110012011-08-02 Bob Duff <duff@adacore.com>
11002
11003 * stylesw.ads: Minor comment fixes.
11004
110052011-08-02 Robert Dewar <dewar@adacore.com>
11006
11007 * freeze.adb (Add_To_Result): New procedure.
11008
110092011-08-02 Jose Ruiz <ruiz@adacore.com>
11010
11011 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
11012 time, if the specific run-time routines for handling streams of strings
11013 are not available, use the default mechanism.
11014
110152011-08-02 Arnaud Charlet <charlet@adacore.com>
11016
11017 * s-regpat.ads: Fix typo.
11018
110192011-08-02 Vincent Celier <celier@adacore.com>
11020
11021 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
11022 not null, call it to create the in memory config project file without
11023 parsing an existing default config project file.
11024
110252011-08-02 Eric Botcazou <ebotcazou@adacore.com>
11026
11027 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
11028
110292011-08-02 Ed Schonberg <schonberg@adacore.com>
11030
11031 * sem_elim.adb: an abstract subprogram does not need an eliminate
11032 pragma for its descendant to be eliminable.
11033
110342011-08-02 Ed Falis <falis@adacore.com>
11035
11036 * init.c: revert to handling before previous checkin for VxWorks
11037 * s-intman-vxworks.adb: delete unnecessary declarations related to
11038 using Ada interrupt facilities for handling signals.
11039 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
11040 * s-intman-vxworks.ads: Import __gnat_install_handler as
11041 Initialize_Interrupts.
11042 * s-taprop-vxworks.adb: Delete Signal_Mask.
11043 (Abort_Handler): change construction of mask to unblock exception
11044 signals.
11045
110462011-08-02 Jerome Guitton <guitton@adacore.com>
11047
11048 * a-except-2005.adb (Raise_From_Signal_Handler): Call
11049 Debug_Raise_Exception before propagation starts.
11050
110512011-08-02 Eric Botcazou <ebotcazou@adacore.com>
11052
11053 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
11054 to Restriction_Check_Required.
11055 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
11056 * sem_res.adb (Resolve_Call): Likewise.
11057 * sem_attr.adb (Check_Stream_Attribute): Likewise.
11058
110592011-08-02 Bob Duff <duff@adacore.com>
11060
11061 * stylesw.ads: Update comment.
11062 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
11063 * errout.ads: Remove obsolete comment.
11064
110652011-08-02 Javier Miranda <miranda@adacore.com>
11066
11067 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
11068 (Set_Is_Safe_To_Reevaluate): new procedure.
11069 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
11070 assignment is allowed on safe-to-reevaluate variables.
11071 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
11072 temporary created to remove side effects in expressions that use
11073 the secondary stack as safe-to-reevaluate.
11074 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
11075 variables that are not true constants.
11076
110772011-08-02 Robert Dewar <dewar@adacore.com>
11078
11079 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
11080 sem_res.adb, sem_ch6.adb: Minor reformatting.
11081
110822011-08-02 Jerome Guitton <guitton@adacore.com>
11083
11084 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
11085
110862011-08-02 Ed Schonberg <schonberg@adacore.com>
11087
11088 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
11089 not set Overridden_Operation if subprogram is an initialization
11090 procedure.
11091
110922011-08-02 Yannick Moy <moy@adacore.com>
11093
11094 * par-ch6.adb: Correct obsolete name in comments
11095 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
11096 which takes two message arguments (existing function takes one), with
11097 second message used for continuation.
11098 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
11099 block statements that originate from a source block statement, not
11100 generated block statements
11101 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
11102 symmetry with procedure case
11103 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
11104 function to issue an error in formal mode if a package specification
11105 contains more than one tagged type or type extension.
11106 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
11107 parameters matching formals of tagged types are objects (or ancestor
11108 type conversions of objects), not general expressions. Issue an error
11109 on view conversions that are not involving ancestor conversion of an
11110 extended type.
11111 (Resolve_Type_Conversion): in formal mode, issue an error on the
11112 operand of an ancestor type conversion which is not an object
11113 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
11114 procedure so that it works also for actuals of function calls
11115 (Is_Actual_Tagged_Parameter): new function which determines if its
11116 argument is an actual parameter of a formal of tagged type in a
11117 subprogram call
11118 (Is_SPARK_Object_Reference): new function which determines if the tree
11119 referenced by its argument represents an object in SPARK
11120
111212011-08-02 Robert Dewar <dewar@adacore.com>
11122
11123 * sem_ch3.adb: Minor reformatting
11124 Minor comment addition
11125 Minor error msg text change
11126
111272011-08-02 Javier Miranda <miranda@adacore.com>
11128
11129 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
11130 function. Used to be more precise when we generate a variable plus one
11131 assignment to remove side effects in the evaluation of the Bound
11132 expressions.
11133 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
11134 of the bound expression to force its re-analysis and thus expand the
11135 associated transient scope (if required). Code cleanup replacing the
11136 previous code that declared the constant entity by an invocation to
11137 routine Force_Evaluation which centralizes this work in the frontend.
11138
111392011-08-02 Robert Dewar <dewar@adacore.com>
11140
11141 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
11142 (Base_Type): Now uses improved Is_Base_Type function
11143 * einfo.ads (Base_Type): Inline this function
11144
111452011-08-02 Robert Dewar <dewar@adacore.com>
11146
11147 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
11148 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
11149
111502011-08-02 Arnaud Charlet <charlet@adacore.com>
11151
11152 * gcc-interface/Make-lang.in: Update dependencies.
11153 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
11154 targets.
11155
111562011-08-02 Yannick Moy <moy@adacore.com>
11157
11158 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
11159 non-simple expression used in delta constraint
11160 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
11161 index constraint which is not a subtype mark
11162 * par.adb: With and use Restrict
11163 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
11164 mode on component type which is not a subtype mark and default
11165 expression on component
11166 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
11167 of string which does not have a lower index bound equal to 1
11168 (Array_Type_Declaration): issue an error in formal mode on index or
11169 component type which is not a subtype mark, and on aliased keyword on
11170 component
11171 (Derived_Type_Declaration): issue an error in formal mode on interface,
11172 limited or abstract type
11173 (Record_Type_Declaration): issue an error in formal mode on interface
11174 (Record_Type_Definition): issue an error in formal mode on tagged types
11175 and type extensions not declared in the specification of a library unit
11176 package; on null non-tagged record; on variant part
11177
111782011-08-02 Vincent Celier <celier@adacore.com>
11179
11180 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
11181 not declared for qualified library project when Library_Name is not
11182 declared, but Library_Dir is.
11183
111842011-08-02 Robert Dewar <dewar@adacore.com>
11185
11186 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
11187 pragmas (affects aspects [Component_]Default_Value
11188 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
11189 component type for the resolution
11190
111912011-08-02 Eric Botcazou <ebotcazou@adacore.com>
11192
11193 * einfo.adb (Base_Type): Tune implementation for speed.
11194
111952011-08-02 Robert Dewar <dewar@adacore.com>
11196
11197 * freeze.adb: Minor reformatting.
11198
111992011-08-02 Thomas Quinot <quinot@adacore.com>
11200
11201 * scos.ads: Update comments.
11202
112032011-08-02 Ed Schonberg <schonberg@adacore.com>
11204
11205 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
11206 base type, because the parent may be a subtype of a private type whose
11207 convention is established in a private part.
11208
112092011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
11210
11211 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
11212 statement in a block when the expansion of the return expression has
11213 created a finalization chain.
11214 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
11215 with the parent node.
11216 Add N_Extended_Return_Statement to handle the case where a transient
11217 object declaration appears in the Return_Object_Declarations list of
11218 an extended return statement.
11219
112202011-08-02 Matthew Gingell <gingell@adacore.com>
11221
11222 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
11223 unused parameter 'name'.
11224
112252011-08-02 Ed Schonberg <schonberg@adacore.com>
11226
11227 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
11228 inherited operation, check whether its alias, which is the source
11229 operastion that it renames, has been marked eliminated.
11230
112312011-08-02 Javier Miranda <miranda@adacore.com>
11232
11233 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
11234 in-mode parameter whose type is an access type since it can be used to
11235 modify its designated object. Enforce code that handles as safe an
11236 access type that is not access-to-constant but it is the result of a
11237 previous removal of side-effects.
11238 (Remove_Side_Effects): Minor code reorganization of cases which require
11239 no action. Done to incorporate documentation on new cases uncovered
11240 working in this ticket: no action needed if this routine was invoked
11241 too early and the nodes are not yet decorated.
11242 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
11243 to routine Remove_Side_Effects by calls to Force_Evaluation since they
11244 were issued with actuals that are implicitly provided by
11245 Force_Evaluation.
11246
112472011-08-02 Robert Dewar <dewar@adacore.com>
11248
11249 * sem_ch3.adb, sem_res.adb: Minor reformatting.
11250
112512011-08-02 Yannick Moy <moy@adacore.com>
11252
11253 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
11254 to issue an error in formal mode on attribute not supported in this mode
11255 (Analyze_Attribute): issue errors on standard attributes not supported
11256 in formal mode.
11257 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
11258 comment, and issue error in formal mode on modulus which is not a power
11259 of 2.
11260 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
11261 range.
11262 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
11263 subtype mark.
11264 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
11265 operator on modular type (except 'not').
11266
112672011-08-02 Robert Dewar <dewar@adacore.com>
11268
11269 * gnat_rm.texi: Minor reformatting.
11270
112712011-08-02 Arnaud Charlet <charlet@adacore.com>
11272
11273 * s-osinte-linux.ads: Minor comment update and reformatting.
11274 * i-cexten.ads: Make this unit pure, as for its parent.
11275 Will allow its usage in more contexts if needed.
11276
112772011-08-02 Robert Dewar <dewar@adacore.com>
11278
11279 * s-utf_32.ads: Minor comment fix.
11280
112812011-08-02 Ed Schonberg <schonberg@adacore.com>
11282
11283 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
11284 operation of a tagged synchronized type, handle the case where the
11285 controlling argument is overloaded.
11286
112872011-08-02 Yannick Moy <moy@adacore.com>
11288
11289 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
11290 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
11291 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
11292 SPARK mode and formal verification mode on processing SPARK restriction
11293 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
11294 requiring consistency checking.
11295
112962011-08-02 Robert Dewar <dewar@adacore.com>
11297
11298 * sem_res.adb: Minor reformatting.
11299
113002011-08-02 Robert Dewar <dewar@adacore.com>
11301
11302 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
11303 a-cforse.ads: Remove unneeded with of Ada.Containers
11304 Remove commented out pragma Inline's
11305 Move specifications of new subprograms to the actual specs
11306
113072011-08-02 Yannick Moy <moy@adacore.com>
11308
11309 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
11310 a-cforse.ads: Update comments.
11311
113122011-08-02 Ed Schonberg <schonberg@adacore.com>
11313
11314 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
11315
113162011-08-02 Robert Dewar <dewar@adacore.com>
11317
11318 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
11319 a-cforse.ads, a-cofove.ads: Minor reformatting.
11320
113212011-08-02 Claire Dross <dross@adacore.com>
11322
11323 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
11324 a-cofove.ads: Add comments.
11325
113262011-08-02 Yannick Moy <moy@adacore.com>
11327
11328 * gnat_rm.texi: Document formal containers.
11329
113302011-08-02 Emmanuel Briot <briot@adacore.com>
11331
11332 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
11333 are empty sections.
11334
113352011-08-02 Robert Dewar <dewar@adacore.com>
11336
11337 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
11338 reformatting.
11339
113402011-08-02 Robert Dewar <dewar@adacore.com>
11341
11342 * aspects.adb: New aspects Default_Value and Default_Component_Value
11343 New format of Aspect_Names table checks for omitted entries
11344 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
11345 handling of boolean aspects for derived types.
11346 New aspects Default_Value and Default_Component_Value
11347 New format of Aspect_Names table checks for omitted entries
11348 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
11349 (Has_Default_Value): New flag
11350 (Has_Default_Component_Value): New flag
11351 (Has_Default_Value): New flag
11352 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
11353 table.
11354 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
11355 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
11356 Default_Value and Default_Component_Value
11357 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
11358 New aspects Default_Value and Default_Component_Value
11359 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
11360 * sprint.adb: Print N_Aspect_Specification node when called from gdb
11361
113622011-08-02 Vincent Celier <celier@adacore.com>
11363
11364 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
11365 inherit library kind.
11366
113672011-08-02 Ed Schonberg <schonberg@adacore.com>
11368
11369 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
11370 Minor reformatting.
11371
113722011-08-02 Robert Dewar <dewar@adacore.com>
11373
11374 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
11375
113762011-08-02 Yannick Moy <moy@adacore.com>
11377
11378 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
11379
113802011-08-02 Robert Dewar <dewar@adacore.com>
11381
11382 * impunit.adb: Add comment.
11383
113842011-08-02 Yannick Moy <moy@adacore.com>
11385
11386 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
11387 qualification of aggregates in formal mode
11388 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
11389 another aggregate
11390 (Resolve_Aggregate): complete the test that an aggregate is adequately
11391 qualified in formal mode
11392
113932011-08-02 Pascal Obry <obry@adacore.com>
11394
11395 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
11396 * mlib-prj.adb: Supress warning when compiling binder generated file.
11397 (Build_Library): Supress all warnings when compiling the binder
11398 generated file.
11399
114002011-08-02 Yannick Moy <moy@adacore.com>
11401
11402 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
11403 from here...
11404 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
11405 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
11406 Add with/use clauses to make Check_Formal_Restriction visible
11407
114082011-08-02 Ed Schonberg <schonberg@adacore.com>
11409
11410 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
11411 in-parameters when type of the generic formal is private in the generic
11412 spec and non-private in the body.
11413
114142011-08-02 Claire Dross <dross@adacore.com>
11415
11416 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
11417 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
11418 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
11419 * impunit.adb, Makefile.rtl: Take new files into account.
11420
114212011-08-02 Robert Dewar <dewar@adacore.com>
11422
11423 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
11424 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
11425
114262011-08-02 Yannick Moy <moy@adacore.com>
11427
11428 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
11429 formal mode
11430 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
11431 matching static array bounds, taking into account the special case of
11432 string literals
11433 * sem_ch3.adb: Typo in comment.
11434
114352011-08-02 Yannick Moy <moy@adacore.com>
11436
11437 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
11438 which issues an error in formal mode if its argument node is originally
11439 from source
11440 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
11441 has a discriminant specification so that it does not include the case
11442 of derived types
11443 (Derived_Type_Declaration): move here the test that a derived type has a
11444 discriminant specification
11445 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
11446 first element of a component association before accessing its choices
11447 (presence of component association is not enough)
11448 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
11449 declaration is a library item before accessing the next element in a
11450 list, as library items are not member of lists
11451 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
11452 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
11453 Check_Formal_Restriction whenever possible.
11454
114552011-08-02 Ed Schonberg <schonberg@adacore.com>
11456
11457 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
11458 reference when needed.
11459
114602011-08-02 Bob Duff <duff@adacore.com>
11461
11462 * gnat_ugn.texi: Fix typo.
11463
114642011-08-02 Vincent Celier <celier@adacore.com>
11465
11466 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
11467 archive file name. Do not use the full path name of archives for Open
11468 VMS.
11469
114702011-08-02 Robert Dewar <dewar@adacore.com>
11471
11472 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
11473 Analyze_Aspect_Specifications
11474 * sem_ch13.adb
11475 (Analyze_Aspect_Specifications): New handling for boolean aspects
11476 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
11477 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
11478 sequence for Analyze_Aspect_Specifications
11479 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
11480 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
11481
114822011-08-02 Robert Dewar <dewar@adacore.com>
11483
11484 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
11485 aspects, since these no longer exist.
11486
114872011-08-02 Robert Dewar <dewar@adacore.com>
11488
11489 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
11490 semicolon, do not try to see if there are aspects following it.
11491 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
11492 aspect spec.
11493
114942011-08-02 Robert Dewar <dewar@adacore.com>
11495
11496 * sem_ch8.adb, aspects.ads: Minor reformatting.
11497
114982011-08-02 Eric Botcazou <ebotcazou@adacore.com>
11499
11500 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
11501 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
11502 extracted from...
11503 (Analyze_Aspect_Specifications): ...here. Call above procedure.
11504
115052011-08-02 Yannick Moy <moy@adacore.com>
11506
11507 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
11508 mode on subprogram declaration outside of package specification, unless
11509 it is followed by a pragma Import
11510 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
11511 Access_Type_Declaration): issue error in formal mode on access type
11512 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
11513 incomplete type
11514 (Analyze_Object_Declaration): issue error in formal mode on object
11515 declaration which does not respect SPARK restrictions
11516 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
11517 declaration which does not respect SPARK restrictions
11518 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
11519 error in formal mode on digits or delta constraint
11520 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
11521 decimal fixed point type
11522 (Derived_Type_Declaration): issue error in formal mode on derived type
11523 other than type extensions of tagged record types
11524 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
11525 with check on access definition
11526 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
11527 mode on protected definition.
11528 (Analyze_Task_Definition): issue error in formal mode on task definition
11529
115302011-08-02 Robert Dewar <dewar@adacore.com>
11531
11532 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
11533
115342011-08-02 Javier Miranda <miranda@adacore.com>
11535
11536 * sem_ch6.adb (Can_Override_Operator): New function.
11537 (Verify_Overriding_Indicator): Add missing code to check overriding
11538 indicator in operators. Fixes regression.
11539 (Check_Overriding_Indicator): Minor reformating after replacing the
11540 code that evaluates if the subprogram can override an operator by
11541 invocations to the above new function.
11542 * einfo.adb
11543 (Write_Field26_Name): Add missing code to ensure that, following
11544 the documentation in einfo.ads, this field is not shown as attribute
11545 "Static_Initialization" on non-dispatching functions.
11546
115472011-08-02 Jose Ruiz <ruiz@adacore.com>
11548
11549 * sem_res.adb (Resolve_Call): A call to
11550 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
11551 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
11552 i.e., when the second parameter is of type Time_Span.
11553
115542011-08-02 Vincent Celier <celier@adacore.com>
11555
11556 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
11557 with an archive instead of -L<library dir> -l<library name>.
11558
115592011-08-02 Ed Schonberg <schonberg@adacore.com>
11560
11561 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
11562 mark the base types In_Use in addition to making the operations
11563 use_visible.
11564
115652011-08-02 Ed Falis <falis@adacore.com>
11566
11567 * init.c: add and setup __gnat_signal_mask for the exception signals
11568 * s-inmaop-vxworks.adb: new file.
11569 * s-intman-vxworks.adb: remove unnecessary initializations and
11570 simplify remaining
11571 * s-intman-vxworks.ads: remove unnecessary variable
11572 * s-taprop-vxworks.adb: simplify signal initialization
11573
115742011-08-02 Robert Dewar <dewar@adacore.com>
11575
11576 * sem_ch8.adb: Minor code reorganization, comment updates.
11577
115782011-08-02 Robert Dewar <dewar@adacore.com>
11579
11580 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
11581 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
11582 here from Sem_Res.
11583 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
11584 (Matching_Static_Array_Bounds): Moved here from Sem_Res
11585
115862011-08-02 Ed Schonberg <schonberg@adacore.com>
11587
11588 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
11589 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
11590 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
11591 use_type_clauses, to handle more efficiently use_type and use_all_type
11592 constructs.
11593 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
11594 Ada2012 Use_All_Type clause.
11595 (Use_Class_Wide_Operations): new procedure.
11596
115972011-08-02 Robert Dewar <dewar@adacore.com>
11598
11599 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
11600 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
11601 expression to expression function.
11602
116032011-08-02 Ed Schonberg <schonberg@adacore.com>
11604
11605 * sem_ch4.adb: transform simple Ada2012 membership into equality only
11606 if types are compatible.
11607
116082011-08-02 Yannick Moy <moy@adacore.com>
11609
11610 * sem_res.adb (Matching_Static_Array_Bounds): new function which
11611 returns True if its argument array types have same dimension and same
11612 static bounds at each index.
11613 (Resolve_Actuals): issue an error in formal mode on actuals passed as
11614 OUT or IN OUT paramaters which are not view conversions in SPARK.
11615 (Resolve_Arithmetic_Op): issue an error in formal mode on
11616 multiplication or division with operands of fixed point types which are
11617 not qualified or explicitly converted.
11618 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
11619 Boolean or array type (except String) operands.
11620 (Resolve_Equality_Op): issue an error in formal mode on equality
11621 operators for array types other than String with non-matching static
11622 bounds.
11623 (Resolve_Logical_Op): issue an error in formal mode on logical operators
11624 for array types with non-matching static bounds. Factorize the code in
11625 Matching_Static_Array_Bounds.
11626 (Resolve_Qualified_Expression): issue an error in formal mode on
11627 qualified expressions for array types with non-matching static bounds.
11628 (Resolve_Type_Conversion): issue an error in formal mode on type
11629 conversion for array types with non-matching static bounds
11630
116312011-08-02 Robert Dewar <dewar@adacore.com>
11632
11633 * par-ch10.adb: Minor code reorganization (use Nkind_In).
11634
116352011-08-02 Ed Schonberg <schonberg@adacore.com>
11636
11637 * par-ch9.adb: save location of entry for proper error message.
11638
116392011-08-02 Javier Miranda <miranda@adacore.com>
11640
11641 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
11642 (Use_Full_View) which permits this routine to climb through the
11643 ancestors using the full-view of private parents.
11644 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
11645 Use_Full_View to true in calls to Is_Ancestor.
11646 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
11647 true in call to Is_Ancestor.
11648 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
11649 Use_Full_View to true in call to Is_Ancestor.
11650 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
11651 call to Is_Ancestor.
11652 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
11653 Use_Full_View to true in calls to Is_Ancestor.
11654 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
11655 Make_Select_Specific_Data_Table, Register_Primitive,
11656 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
11657 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
11658 to true in call to Is_Ancestor.
11659 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
11660 Use_Full_View to true in calls to Is_Ancestor.
11661 * exp_cg.adb
11662 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
11663 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
11664
116652011-08-02 Robert Dewar <dewar@adacore.com>
11666
11667 * gnat_rm.texi: Minor reformatting.
11668 * sem_prag.adb: Minor reformatting.
11669
116702011-08-02 Tristan Gingold <gingold@adacore.com>
11671
11672 * vms_data.ads: Add VMS qualifier for -gnateP.
11673
116742011-08-02 Robert Dewar <dewar@adacore.com>
11675
11676 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
11677 * par-ch7.adb (P_Package): Proper placement of aspects for package
11678 decl/instantiation.
11679 * par-endh.adb (Check_End): Ad Is_Sloc parameter
11680 (End_Statements): Add Is_Sloc parameterr
11681 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
11682 (Check_End): Ad Is_Sloc parameter
11683 (End_Statements): Add Is_Sloc parameterr
11684
116852011-08-02 Vincent Celier <celier@adacore.com>
11686
11687 * ug_words: Add VMS qualifier equivalent to -gnateP:
11688 /SYMBOL_PREPROCESSING.
11689
116902011-08-02 Jose Ruiz <ruiz@adacore.com>
11691
11692 * gnat-style.texi: For hexadecimal numeric literals the typical
11693 grouping of digits is 4 to represent 2 bytes.
11694 A procedure spec which is split into several lines is indented two
11695 characters.
11696
116972011-08-02 Yannick Moy <moy@adacore.com>
11698
11699 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
11700 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
11701 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
11702 properly qualified
11703 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
11704 choice in array aggregate
11705 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
11706 mark as ancestor
11707 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
11708 positional and named aggregate for record, or others in record
11709 aggregate, or multiple choice in record aggregate
11710 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
11711 array operands to logical operations AND, OR and XOR do not have the
11712 same static lower and higher bounds
11713 * sem_ch5.adb, sinfo.ads: Correct typos in comments
11714
117152011-08-01 Robert Dewar <dewar@adacore.com>
11716
11717 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
11718 Replaces Last_Source_Node_In_Sequence.
11719 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
11720 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
11721 parens and blank in string (this was inconsistently implemented).
11722 * errout.ads
11723 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
11724 blank in string (this was inconsistently implemented).
11725 * gnat1drv.adb
11726 (Set_Global_Switches): Set formal mode switches appropriately
11727 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
11728 * par-prag.adb
11729 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
11730 call Set_Error_Msg_Lang to set "spark" as language name.
11731 * par.adb: Remove unnecessary call to set formal language for errout
11732 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
11733 appropriately and call Set_Error_Msg_Lang to set "spark" as language
11734 name.
11735 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
11736 calls to it, moved after resolution so that types are known
11737 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
11738 result of concatenation is not of type String
11739 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
11740 concatenation is not properly restricted
11741 * gnat_rm.texi: Add doc on pragma Spark_95.
11742 * gcc-interface/Makefile.in: Remove obsolete target pairs for
11743 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
11744 * gcc-interface/Make-lang.in: Update dependencies.
11745
117462011-08-01 Javier Miranda <miranda@adacore.com>
11747
11748 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
11749 condition that detects if the overridden operation must replace an
11750 existing entity.
11751
117522011-08-01 Javier Miranda <miranda@adacore.com>
11753
11754 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
11755 code declarations inserted by Insert_Actions in each alternative of the
11756 N_Case_Expression node.
11757
117582011-08-01 Robert Dewar <dewar@adacore.com>
11759
11760 * sem_ch6.adb: Minor code reorganization.
11761 * sem_util.adb: Minor reformatting.
11762
117632011-08-01 Pascal Obry <obry@adacore.com>
11764
11765 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
11766 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
11767
117682011-08-01 Yannick Moy <moy@adacore.com>
11769
11770 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
11771 literal or operator symbol which is prefixed
11772 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
11773 mode on access attributes.
11774 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
11775 that concatenation operands are properly restricted in formal mode
11776 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
11777 Analyze_Concatenation_Operand. Issue an error in formal mode if the
11778 result of the concatenation has a type different from String.
11779 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
11780 Analyze_Quantified_Expression, Analyze_Slice,
11781 Analyze_Null): issue an error in formal mode on unsupported constructs
11782 * sem_ch5.adb
11783 (Analyze_Block_Statement): only issue error on source block statement
11784 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
11785 function which returns the last node in a list of nodes for which
11786 Comes_From_Source returns True, if any
11787 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
11788 Last_Source_Node_In_Sequence
11789 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
11790 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
11791 mode on unsupported constructs
11792 * sem_ch9.adb Do not return after issuing error in formal mode, as the
11793 rest of the actions may be needed later on since the error is marked as
11794 not serious.
11795 * sinfo.ads: Typos in comments.
11796
117972011-08-01 Pascal Obry <obry@adacore.com>
11798
11799 * projects.texi: Minor editing.
11800
118012011-08-01 Yannick Moy <moy@adacore.com>
11802
11803 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
11804 insertion character ~~
11805 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
11806 (Set_Error_Msg_Lang): new procedure which fixes the language for use
11807 with insertion character ~~
11808 (Set_Msg_Text): treat insertion character ~~
11809 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
11810 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
11811 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
11812 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
11813 errors related to the formal language restriction not serious
11814 (insertion character |).
11815 * par.adb (Par): set formal language for error messages if needed
11816 * sem_ch6.adb (Check_Missing_Return): take into account possible
11817 generated statements at the end of the function
11818 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
11819 enumeration value to define a new pragma SPARK_95
11820 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
11821 SPARK_Version): new type and variables to store the SPARK version
11822 (none by default).
11823 (SPARK_Mode): return True when SPARK_Version is set
11824 * par-prag.adb: Correct indentation
11825 (Prag): take Pragma_SPARK_95 into account
11826 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
11827 into account.
11828
118292011-08-01 Robert Dewar <dewar@adacore.com>
11830
11831 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
11832 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
11833 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
11834
118352011-08-01 Pascal Obry <obry@adacore.com>
11836
11837 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
11838 Target_Name to Get_Path call.
11839 (Parse_Single_Project): Likewise.
11840 (Post_Parse_Context_Clause): Likewise.
11841 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
11842 Call Initialise_Project_Path with the proper Target_Name.
11843 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
11844 search path.
11845 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
11846 with the proper Target_Name.
11847 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
11848 Part.Parse routine.
11849 (Parse_Project_And_Apply_Config): Likewise.
11850 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
11851 This is fine as this part of the code is supporting only native
11852 compilation.
11853 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
11854 is fine as this part of the code is supporting only native compilation.
11855
118562011-08-01 Yannick Moy <moy@adacore.com>
11857
11858 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
11859 of homonym, unless the homonym is one of the cases allowed in SPARK
11860 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
11861 package declaration occurring after a body.
11862
118632011-08-01 Robert Dewar <dewar@adacore.com>
11864
11865 * checks.adb, exp_ch4.adb: Minor reformatting.
11866
118672011-08-01 Javier Miranda <miranda@adacore.com>
11868
11869 * einfo.ads (Access_Disp_Table): Fix documentation.
11870 (Dispatch_Table_Wrappers): Fix documentation.
11871
118722011-08-01 Pascal Obry <obry@adacore.com>
11873
11874 * prj-env.adb, prj-env.ads: Minor reformatting.
11875
118762011-08-01 Yannick Moy <moy@adacore.com>
11877
11878 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
11879 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
11880 procedures out of these packages.
2c7f9cc0 11881 * errout.ads, errout.adb
052e0603
AC
11882 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
11883 procedures in of this package
11884 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
11885 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
11886 on misplaced later vs initial declarations, like in Ada 83
11887 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
11888 formal mode on attribute of private type whose full type declaration
11889 is not visible
11890 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
11891 package declaration inside a package specification
11892 (Analyze_Full_Type_Declaration): issue error in formal mode on
11893 controlled type or discriminant type
11894 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
11895 user-defined operator means that it should come from the source
11896 (New_Overloaded_Entity): issue error in formal mode on overloaded
11897 entity.
11898 * sem_ch6.ads, sem_ch13.ads: typos in comments.
11899
119002011-08-01 Thomas Quinot <quinot@adacore.com>
11901
11902 * atree.adb: Minor reformatting.
11903 * checks.adb: Minor reformatting.
11904
119052011-08-01 Vincent Celier <celier@adacore.com>
11906
11907 * s-parame-vms-ia64.ads: Fix typo in comment
11908 Minor reformatting
11909 * s-parame-vms-restrict.ads: Removed, unused.
11910
119112011-08-01 Javier Miranda <miranda@adacore.com>
11912
11913 * exp_ch3.adb
11914 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
11915 * sem_ch3.adb
11916 (Constrain_Index): Remove side effects in the evaluation of the bounds.
11917 * sem_ch3.ads, sem_ch3.adb
11918 (Is_Constant_Bound): New extended version of the subprogram that was
11919 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
11920 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
11921 * sem_aux.ads (Constant_Value): Fix typo in comment.
11922 * checks.adb (Generate_Index_Checks): New implementation which, for
11923 array objects with constant bounds, generates the runtime check
11924 referencing the bounds of the array type. For other cases this routine
11925 provides its previous behavior obtaining such values from the array
11926 object.
11927 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
11928 parent type.
11929 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
11930 we cannot have semantic interpretations of the new node.
11931
119322011-08-01 Ed Schonberg <schonberg@adacore.com>
11933
11934 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
11935 expressions.
11936
119372011-08-01 Arnaud Charlet <charlet@adacore.com>
11938
11939 * sem_ch8.adb: Minor code editing.
11940 * s-vxwext.adb: Remove trailing space.
11941 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
11942 consistency with other files.
11943
119442011-08-01 Thomas Quinot <quinot@adacore.com>
11945
11946 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
11947
119482011-08-01 Ed Schonberg <schonberg@adacore.com>
11949
11950 * par-ch10.adb: reject parameterized expressions as compilation unit.
11951 * sem_ch4.adb: handle properly conditional expression with overloaded
11952 then_clause and no else_clause.
11953
119542011-08-01 Tristan Gingold <gingold@adacore.com>
11955
11956 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
11957 like done by System.Aux_DEC.
11958 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
11959
119602011-08-01 Yannick Moy <moy@adacore.com>
11961
11962 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
11963 missing label at end of declaration (subprogram or package)
11964 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
11965 of positional and named parameter association
11966 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
11967 Error_Msg_SP which adds a prefix to the error message giving the name
11968 of the formal language analyzed
11969 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
11970 access result type in subprogram, unconstrained array as result type,.
11971 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
11972 procedure
11973 * sem_ch8.adb: Code clean up.
11974
119752011-08-01 Javier Miranda <miranda@adacore.com>
11976
11977 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
11978 * einfo.ads (Access_Disp_Table): Fix documentation.
11979 (Dispatch_Table_Wrappers): Fix documentation.
11980 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
11981 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
11982 to enforce the documentation of this attribute.
11983 (Set_Is_Interface): Cleanup the assertion.
11984 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
11985 the Underlying_Type entity before reading attribute Access_Disp_Table.
11986 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
11987 Locate the Underlying_Type before reading attribute Access_Disp_Table.
11988 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
11989 the Underlying_Type entity before reading attribute Access_Disp_Table.
11990 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
11991 Locate the Underlying_Type entity before reading attribute
11992 Access_Disp_Table.
11993
119942011-08-01 Ed Schonberg <schonberg@adacore.com>
11995
11996 * s-poosiz.ads: Additional overriding indicators.
11997
119982011-08-01 Yannick Moy <moy@adacore.com>
11999
12000 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
12001 formal mode.
12002 (Analyze_Iteration_Scheme): issue error in formal mode when loop
12003 parameter specification does not include a subtype mark.
12004 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
12005 formal mode on abstract subprogram.
12006 (Analyze_Subprogram_Specification): issue error in formal mode on
12007 user-defined operator.
12008 (Process_Formals): issue error in formal mode on access parameter and
12009 default expression.
12010 * sem_ch9.adb (Analyze_Abort_Statement,
12011 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
12012 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
12013 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
12014 Analyze_Requeue, Analyze_Selective_Accept,
12015 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
12016 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
12017 issue error in formal mode on user-defined raise statement.
12018
120192011-08-01 Thomas Quinot <quinot@adacore.com>
12020
12021 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
12022 declaration being hidden when overriding an implicit inherited
12023 subprogram.
12024 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
12025 (-gnats), do not complain about a source file that contains only a
12026 pragma No_Body.
12027
120282011-08-01 Ed Schonberg <schonberg@adacore.com>
12029
12030 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
12031 variable if already set.
12032
120332011-08-01 Arnaud Charlet <charlet@adacore.com>
12034
12035 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
12036 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
12037 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
12038 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
12039 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
12040 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
12041 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
12042 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
12043 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
12044 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
12045 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
12046 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
12047 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
12048 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
12049 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
12050 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
12051 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
12052 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
12053 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
12054 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
12055 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
12056 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
12057 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
12058 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
12059 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
12060 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
12061 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
12062 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
12063 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
12064 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
12065 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
12066 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
12067 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
12068 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
12069 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
12070 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
12071 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
12072 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
12073 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
12074 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
12075 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
12076 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
12077 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
12078 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
12079 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
12080 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
12081 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
12082 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
12083 s-osinte-mingw.ads: Update to GPLv3 run-time license.
12084 Use GNAT instead of GNARL.
12085
120862011-08-01 Bob Duff <duff@adacore.com>
12087
12088 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
12089 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
12090 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
12091 reformatting.
12092
120932011-08-01 Yannick Moy <moy@adacore.com>
12094
12095 * debug.adb (d.D) reverve flag for the SPARK mode
12096 (d.E) reverve flag for SPARK generation mode
12097 (d.F) reverve flag for Why generation mode
2c7f9cc0 12098 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
052e0603
AC
12099 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
12100 functions which return True when the corresponding modes are set
12101 (Formal_Language): return "spark" or "alfa" when in formal verification
12102 mode.
12103 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
12104 Error_Msg to prefix the error message with a tag giving the formal
12105 language
12106 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
12107 message with a tag giving the formal language
12108 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
12109 block statement
12110 (Analyze_Case_Statement): issue error in formal mode on case statement
12111 with a single "others" case alternative
12112 (Analyze_Exit_Statement): issue errors in formal mode on exit
12113 statements which do not respect SPARK restrictions
12114 (Analyze_Goto_Statement): issue error in formal mode on goto statement
12115 (Check_Unreachable_Code): always issue an error (not a warning) in
12116 formal mode on unreachable code (concerns both code after an infinite
12117 loop and after an unconditional jump, both not allowed in SPARK)
12118 * sem_ch6.adb (Analyze_Return_Statement): add call to
12119 Set_Return_Present for a procedure containing a return statement
12120 (already done for functions in Analyze_Function_Return)
12121 (Analyze_Function_Return): issue error in formal mode on extended
12122 return or if return is not last statement in function
12123 (Check_Missing_Return): issue error in formal mode if function does
12124 not end with return or if procedure contains a return
12125 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
12126 function to detect if there is an inner scope of its parameter S which
12127 is a loop.
12128
121292011-08-01 Thomas Quinot <quinot@adacore.com>
12130
12131 * sem_ch6.ads: Minor reformatting.
12132
121332011-08-01 Javier Miranda <miranda@adacore.com>
12134
12135 * sem_util.adb (Abstract_Interface_List): Complete condition when
12136 processing private type declarations to avoid reading unavailable
12137 attribute.
12138 (Is_Synchronized_Tagged_Type): Complete condition when processing
12139 private extension declaration nodes to avoid reading unavailable
12140 attribute.
12141
121422011-08-01 Thomas Quinot <quinot@adacore.com>
12143
12144 * sem_ch3.adb: Minor reformatting.
12145
121462011-08-01 Thomas Quinot <quinot@adacore.com>
12147
12148 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
12149 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
12150 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
12151 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
12152 for VMS, instead parametrize the common implementation with
12153 System.Parameters declarations.
12154
121552011-08-01 Eric Botcazou <ebotcazou@adacore.com>
12156
12157 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
12158
121592011-08-01 Tristan Gingold <gingold@adacore.com>
12160
12161 * seh_init.c: Fix SEH handler installation on win64.
12162
121632011-08-01 Ed Schonberg <schonberg@adacore.com>
12164
12165 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
12166 double analysis of an anonymous access to subprogram, because it can
12167 lead to improper sharing of profiles and a back-end crash.
12168
121692011-08-01 Robert Dewar <dewar@adacore.com>
12170
12171 * make.adb, sem_ch4.adb: Minor reformatting.
12172 * gcc-interface/Make-lang.in: Update dependencies.
12173 * sem_util.adb, exp_ch5.adb: Minor reformatting.
12174
121752011-08-01 Arnaud Charlet <charlet@adacore.com>
12176
12177 * gnat_rm.texi: Fix definition of Long_Integer.
12178
121792011-08-01 Ed Schonberg <schonberg@adacore.com>
12180
12181 * exp_aggr.adb: check limit size of static aggregate unconditionally,
12182 to prevent storage exhaustion.
12183 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
12184 finalized is a function body, insert the cleanup code before the final
12185 return statement, to prevent spurious warnings.
12186 * s-pooglo.ads: add overriding indicator.
12187
121882011-08-01 Ed Schonberg <schonberg@adacore.com>
12189
12190 * sem_ch4.adb (Operator_Check): improve error message when both a
12191 with_clause and a use_clause are needed to make operator usage legal.
12192 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
12193 determine whether a compilation unit is visible within an other,
12194 either through a with_clause in the current unit, or a with_clause in
12195 its library unit or one one of its parents.
12196
121972011-08-01 Ed Schonberg <schonberg@adacore.com>
12198
12199 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
12200 over an arbitrary expression of an array or container type.
12201 * lib-xref.adb: clarify comment.
12202
122032011-08-01 Bob Duff <duff@adacore.com>
12204
12205 * einfo.ads: Minor reformatting.
12206 * debug.adb: Minor comment improvement.
12207
122082011-08-01 Javier Miranda <miranda@adacore.com>
12209
12210 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
12211 consider hidden subprograms as valid candidates.
12212
122132011-08-01 Arnaud Charlet <charlet@adacore.com>
12214
12215 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
12216
122172011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
12218
12219 * gnat_ugn.texi: Fix typo.
12220
122212011-08-01 Robert Dewar <dewar@adacore.com>
12222
12223 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
12224 lib-xref.adb: Minor reformatting
12225
122262011-08-01 Gary Dismukes <dismukes@adacore.com>
12227
12228 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
12229 when to generate a call to Move_Final_List.
12230 (Has_Controlled_Parts): Remove this function.
12231
122322011-08-01 Geert Bosch <bosch@adacore.com>
12233
12234 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
12235 "," in choice list.
12236
122372011-08-01 Thomas Quinot <quinot@adacore.com>
12238
12239 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
12240 explicit raise of a predefined exception as Comes_From_Source if the
12241 original N_Raise_Statement comes from source.
12242
122432011-08-01 Robert Dewar <dewar@adacore.com>
12244
12245 * sinfo.ads: Add comment.
12246 * sem_ch6.adb: Minor reformatting.
12247
122482011-08-01 Robert Dewar <dewar@adacore.com>
12249
12250 * freeze.adb (Freeze_Entity): Refine check for bad component size
12251 clause to avoid rejecting confirming clause when atomic/aliased present.
12252
122532011-08-01 Ed Schonberg <schonberg@adacore.com>
12254
12255 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
12256 better determine whether an entity reference is a write.
12257 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
12258 subcomponent.
12259 * lib-xref.adb (Output_References): Do no suppress a read reference at
12260 the same location as an immediately preceeding modify-reference, to
12261 handle properly in-out actuals.
12262
122632011-08-01 Tristan Gingold <gingold@adacore.com>
12264
12265 * env.c (__gnat_setenv) [VMS]: Refine previous change.
12266
122672011-08-01 Quentin Ochem <ochem@adacore.com>
12268
12269 * i-cstrin.adb (New_String): Changed implementation, now uses only the
12270 heap to compute the result.
12271
122722011-08-01 Robert Dewar <dewar@adacore.com>
12273
12274 * atree.ads: Minor reformatting.
12275
122762011-08-01 Emmanuel Briot <briot@adacore.com>
12277
12278 * g-expect.adb (Get_Command_Output): Fix memory leak.
12279
122802011-08-01 Geert Bosch <bosch@adacore.com>
12281
12282 * cstand.adb (P_Float_Type): New procedure to print the definition of
12283 predefined fpt types.
12284 (P_Mixed_Name): New procedure to print a name using mixed case
12285 (Print_Standard): Use P_Float_Type for printing floating point types
12286 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
12287 precision IEEE float.
12288
122892011-08-01 Thomas Quinot <quinot@adacore.com>
12290
12291 * sem_ch3.adb: Minor reformatting.
12292
122932011-08-01 Ed Schonberg <schonberg@adacore.com>
12294
12295 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
12296 the completion of a generic function, insert the new body rather than
12297 rewriting the original.
12298
122992011-08-01 Yannick Moy <moy@adacore.com>
12300
12301 * sinfo.ads, errout.ads: Typos in comments.
12302
123032011-08-01 Robert Dewar <dewar@adacore.com>
12304
12305 * par-endh.adb: Minor reformatting.
12306
123072011-08-01 Robert Dewar <dewar@adacore.com>
12308
12309 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
12310 (Pre_Post_Aspects): New subtype.
12311 * par-ch12.adb (P_Generic): New syntax for aspects in packages
12312 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
12313 * par-ch7.adb (P_Package): Remove Decl parameter
12314 (P_Package): Handle new syntax for aspects (before IS)
12315 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
12316 new aspect syntax
12317 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
12318 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
12319 (P_Package): Remove Decl parameter
12320 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
12321 aspects
12322 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
12323 specs
12324 * sem_util.ads, sem_util.adb (Static_Boolean): New function
12325 * sinfo.ads: Document new syntax for aspects in packages etc.
12326 * sprint.adb: Handle new syntax of aspects before IS in package
12327
123282011-08-01 Thomas Quinot <quinot@adacore.com>
12329
12330 * atree.ads: Minor reformatting.
12331 * sem_prag.adb: Minor reformatting.
12332
123332011-08-01 Robert Dewar <dewar@adacore.com>
12334
12335 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
12336 case expr alternative.
12337
123382011-08-01 Ed Schonberg <schonberg@adacore.com>
12339
12340 * sem_ch12.adb: Fix typo.
12341
123422011-08-01 Geert Bosch <bosch@adacore.com>
12343
12344 * sem_prag.adb (Check_No_Link_Name): New procedure.
12345 (Process_Import_Or_Interface): Use Check_No_Link_Name.
12346 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
12347 instead of Standard_Long_Long_Float_Size global. Preparation for
12348 eventual removal of per type constants.
12349 * exp_util.ads (Get_Stream_Size): New function returning the stream
12350 size value of subtype E.
12351 * exp_util.adb (Get_Stream_Size): Implement new function.
12352 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
12353 function.
12354 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
12355 * einfo.adb:
12356 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
12357
123582011-08-01 Geert Bosch <bosch@adacore.com>
12359
12360 * cstand.adb: Fix comments.
12361 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
12362 count of arguments.
12363
123642011-08-01 Robert Dewar <dewar@adacore.com>
12365
12366 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
12367
123682011-08-01 Geert Bosch <bosch@adacore.com>
12369
12370 * atree.ads: Fix comment.
12371
123722011-08-01 Robert Dewar <dewar@adacore.com>
12373
12374 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
12375 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
12376 * par.adb: Add with for Namet.Sp.
12377 * par-tchk.adb: Minor reformatting.
12378
123792011-08-01 Vincent Celier <celier@adacore.com>
12380
12381 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
12382 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
12383 of the init procedure of a SAL.
12384 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
12385 New procedure.
12386
123872011-08-01 Thomas Quinot <quinot@adacore.com>
12388
12389 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
12390 reformatting.
12391
123922011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
12393
12394 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
12395
123962011-08-01 Thomas Quinot <quinot@adacore.com>
12397
12398 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
12399 conformant with its spec (return True only for types that have
12400 an overriding Initialize primitive operation that prevents them from
12401 having preelaborable initialization).
12402 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
12403 initialization for controlled types in Ada 2005 or later mode.
12404
124052011-08-01 Robert Dewar <dewar@adacore.com>
12406
12407 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
12408 Postcondition.
12409 (Same_Aspect): New function.
12410 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
12411 Type_Invariant, Precondition, Postcondition.
12412 * snames.ads-tmpl: Add Name_Type_Invariant.
12413
124142011-08-01 Robert Dewar <dewar@adacore.com>
12415
12416 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
12417 here.
12418 (Freeze_All_Ent): Fix error in handling inherited aspects.
12419 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
12420 already analyzed, but don't skip entire processing of a declaration,
12421 that's wrong in some cases of declarations being rewritten.
12422 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
12423 Don't delay for integer, string literals
12424 Treat predicates in usual manner for delay, remove special case code,
12425 not needed.
12426 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
12427 (Build_Predicate_Function): Update saved expression in aspect
12428 (Build_Invariant_Procedure): Update saved expression in aspect
12429 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
12430 of replacement of discriminant references if the reference is simple.
12431
124322011-08-01 Robert Dewar <dewar@adacore.com>
12433
12434 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
12435 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
12436 Static_Predicate and Dynamic_Predicate.
12437 (Build_Predicate_Function): Add processing for Static_Predicate
12438 and Dynamic_Predicate.
12439 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
12440 (From_Static_Predicate): New flag
12441 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
12442
124432011-08-01 Robert Dewar <dewar@adacore.com>
12444
12445 * usage.adb: Documentation cleanup for Ada version modes in usage.
12446 * expander.adb: Minor reformatting.
12447
124482011-08-01 Robert Dewar <dewar@adacore.com>
12449
12450 * atree.ads: Minor comment fix.
12451 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
12452 a-witeio.ads, sem_prag.adb: Minor reformatting.
12453
124542011-08-01 Doug Rupp <rupp@adacore.com>
12455
12456 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
12457 pointers. Use descrip.h header file for convenience. Add some
12458 comments.
12459
124602011-08-01 Robert Dewar <dewar@adacore.com>
12461
12462 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
12463 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
12464 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
12465 New procedure.
12466 (Check_Aspect_At_End_Of_Declarations): New procedure
12467 (Analye_Aspect_Specification): Minor changes for above procedures
12468 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
12469 specification node as well.
12470
124712011-08-01 Pascal Obry <obry@adacore.com>
12472
12473 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
12474 Windows files. Use GetFilesAttributes() in this case to check for file
12475 existence instead of returning with an error code.
12476
124772011-08-01 Vincent Celier <celier@adacore.com>
12478
12479 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
12480 High is above Source length.
12481
124822011-08-01 Robert Dewar <dewar@adacore.com>
12483
12484 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
12485
124862011-08-01 Robert Dewar <dewar@adacore.com>
12487
12488 * aspects.ads (Boolean_Aspects): New subtype.
12489 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
12490 for derived types in cases where the parent type and derived type have
12491 aspects.
12492 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
12493 with aspects when parent type also has aspects.
12494 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
12495 boolean expression at this point).
12496 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
12497 accordance with final decision on the Ada 2012 feature.
12498 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
12499
125002011-08-01 Matthew Heaney <heaney@adacore.com>
12501
12502 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
12503
125042011-08-01 Pascal Obry <obry@adacore.com>
12505
12506 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
12507 Fix Replace_Slice when High is above current string size.
12508 (Replace_Slice): Fix DL computation when High is above current
12509 string length.
12510
125112011-08-01 Gary Dismukes <dismukes@adacore.com>
12512
12513 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
12514
125152011-08-01 Matthew Heaney <heaney@adacore.com>
12516
12517 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
12518 of node.
12519
125202011-08-01 Pascal Obry <obry@adacore.com>
12521
12522 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
12523 reformatting.
12524
125252011-08-01 Ed Schonberg <schonberg@adacore.com>
12526
12527 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
12528 access to protected subprograms in generic bodies.
12529 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
12530 protected type, indicate that the convention of the subprogram is
12531 Convention_Protected, because it may be used in subsequent declarations
12532 within the protected declaration.
12533
125342011-08-01 Vincent Celier <celier@adacore.com>
12535
12536 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
12537 and "final" procedures when the name of the library is "ada", to avoid
12538 duplicate symbols "adainit" and "adafinal" in executables.
12539
125402011-08-01 Ed Schonberg <schonberg@adacore.com>
12541
12542 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
12543 quantified expression that appears within a postcondition and uses the
12544 Ada2012 'Result attribute.
12545
125462011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12547
12548 * init.c (__gnat_error_handler): Cast reason to int.
12549 (__gnat_install_handler): Explain sa_sigaction use.
12550
125512011-07-24 Eric Botcazou <ebotcazou@adacore.com>
12552
12553 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
12554 subprogram has copy-in copy-out parameters, try to promote the mode of
12555 the return type if it is passed in registers.
12556
125572011-07-24 Eric Botcazou <ebotcazou@adacore.com>
12558
12559 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
12560 left operand as addressable.
12561
125622011-07-24 Eric Botcazou <ebotcazou@adacore.com>
12563
12564 * gcc-interface/gigi.h (build_function_stub): Remove.
12565 (build_return_expr): Likewise.
12566 (convert_vms_descriptor): Declare.
12567 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
12568 (build_function_stub): Move to...
12569 * gcc-interface/utils2.c (build_return_expr): Move to...
12570 * gcc-interface/trans.c (build_function_stub): ...here.
12571 (build_return_expr): ...here.
12572 (Subprogram_Body_to_gnu): Add local variable for language_function.
12573 Disconnect the parameter attributes cache, if any, once done with it.
12574 Call end_subprog_body only after setting the end_locus.
12575 Build the stub associated with the function, if any, at the very end.
12576 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
12577 variables and streamline control flow.
12578
125792011-07-23 Arnaud Charlet <charlet@adacore.com>
12580
12581 PR ada/49819
12582 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
12583 g-trasym-dwarf.adb.
12584
125852011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12586
12587 PR bootstrap/49794
12588 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
12589 Assign to act.sa_sigaction.
12590 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
12591 current->return_address to char * before arithmetic.
12592
125932011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12594
12595 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
12596 Correct argument types.
12597 Extract code from reason.
12598 (__gnat_install_handler): Assign to act.sa_sigaction.
12599
126002011-07-21 Eric Botcazou <ebotcazou@adacore.com>
12601
12602 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
12603 (GNAT1_OBJS): ...here.
12604
126052011-07-15 Eric Botcazou <ebotcazou@adacore.com>
12606
12607 PR ada/48711
12608 * g-socthi-mingw.adb (Fill): Fix formatting.
12609
12610 * gcc-interface/gigi.h: Move around comment.
12611
126122011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
12613
12614 PR ada/46350
12615 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
12616
126172011-07-14 Florian Weimer <fw@deneb.enyo.de>
12618
12619 PR ada/48711
12620 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
12621
126222011-07-13 Eric Botcazou <ebotcazou@adacore.com>
12623
12624 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
12625 range comparison if Pmode is SImode.
12626
126272011-07-12 Laurent GUERBY <laurent@guerby.net>
12628 Eric Botcazou <ebotcazou@adacore.com>
12629
12630 * adadecode.c: Wrap up in extern "C" block.
12631 * adadecode.h: Likewise.
12632 * adaint.c: Likewise. Remove 'const' keyword.
12633 * adaint.h: Likewise.
12634 * argv.c: Likewise.
12635 * atree.h: Likewise.
12636 * cio.c: Likewise.
12637 * cstreams.c: Likewise.
12638 * env.c: Likewise.
12639 * exit.c: Likewise.
12640 * fe.h: Likewise.
12641 * final.c: Likewise.
12642 * init.c: Likewise.
12643 * initialize.c: Likewise.
12644 * link.c: Likewise.
12645 * namet.h: Likewise.
12646 * nlists.h: Likewise.
12647 * raise.c: Likewise.
12648 * raise.h: Likewise.
12649 * repinfo.h: Likewise.
12650 * seh_init.c: Likewise.
12651 * targext.c: Likewise.
12652 * tracebak.c: Likewise.
12653 * uintp.h: Likewise.
12654 * urealp.h: Likewise.
12655 * xeinfo.adb: Wrap up generated C code in extern "C" block.
12656 * xsinfo.adb: Likewise.
12657 * xsnamest.adb: Likewise.
12658 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
12659 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
12660 * gcc-interface/misc.c: Likewise.
12661 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
12662 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
12663 ada/targext.o here...
12664 (GNAT_ADA_OBJS): ...and not here.
12665 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
12666 (GNATBIND_OBJS): Reorder.
12667
126682011-07-07 Richard Henderson <rth@redhat.com>
12669
12670 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
12671 dwarf2out_frame_init.
12672
126732011-07-07 Eric Botcazou <ebotcazou@adacore.com>
12674
12675 * gcc-interface/misc.c (gnat_init): Tweak previous change.
12676
126772011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12678
12679 PR target/39150
12680 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
12681
126822011-07-06 Richard Guenther <rguenther@suse.de>
12683
12684 * gcc-interface/misc.c (gnat_init): Merge calls to
12685 build_common_tree_nodes and build_common_tree_nodes_2.
12686 Re-initialize boolean_false_node.
12687
126882011-07-02 Eric Botcazou <ebotcazou@adacore.com>
12689 Olivier Hainque <hainque@adacore.com>
12690 Nicolas Setton <setton@adacore.com>
12691
12692 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
12693 the type according to the ARTIFICIAL_P parameter.
12694 (create_type_decl): Likewise.
12695 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
12696
126972011-07-01 Eric Botcazou <ebotcazou@adacore.com>
12698
12699 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
12700 (gnatbind): Likewise.
12701
127022011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12703
12704 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
12705
127062011-06-18 Eric Botcazou <ebotcazou@adacore.com>
12707
12708 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
12709 local variable throughout. Remove useless call to Base_Type.
12710 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
12711 Take it also into account for the volatileness of the field. Set the
12712 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
12713
127142011-06-18 Eric Botcazou <ebotcazou@adacore.com>
12715
12716 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
12717 on a dereference built for a by-ref object if it has an address clause.
12718
127192011-06-18 Eric Botcazou <ebotcazou@adacore.com>
12720
12721 * einfo.ads (Address_Taken): Document use for the second argument of
12722 Asm_Input and Asm_Output attributes.
12723 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
12724 argument is an entity name, then set Address_Taken on it.
12725 <Attribute_Asm_Output>: Likewise.
12726 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
12727 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
12728 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
12729 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
12730
127312011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
12732
12733 PR middle-end/46500
12734 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
12735
127362011-06-14 Joseph Myers <joseph@codesourcery.com>
12737
12738 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
12739 (ada/utils.o): Update dependencies.
12740 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
12741 ../../../libcpp/libcpp.a.
12742 * gcc-interface/utils.c: Include common/common-target.h.
12743 (process_attributes): Use targetm_common.have_named_sections.
12744
127452011-06-07 Richard Guenther <rguenther@suse.de>
12746
12747 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
12748 set_sizetype.
12749
127502011-06-06 Eric Botcazou <ebotcazou@adacore.com>
12751
12752 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
12753 TREE_THIS_NOTRAP flag.
12754
127552011-06-06 Eric Botcazou <ebotcazou@adacore.com>
12756
12757 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
12758 Fix thinko.
12759
127602011-06-06 Eric Botcazou <ebotcazou@adacore.com>
12761
12762 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
12763 constants whose full view has discriminants specially.
12764
127652011-06-06 Eric Botcazou <ebotcazou@adacore.com>
12766
12767 * gcc-interface/utils.c: Include diagnostic.h.
12768 (gnat_write_global_declarations): Output debug information for all
12769 global type declarations before finalizing the compilation unit.
12770 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
12771
127722011-05-25 Jakub Jelinek <jakub@redhat.com>
12773
12774 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
12775
127762011-05-25 Kai Tietz <ktietz@redhat.com>
12777
12778 * adaint.c (__gnat_to_canonical_file_list_next): Use array
12779 initialization instead of const/none-const pointer assignment.
12780
127812011-05-24 Joseph Myers <joseph@codesourcery.com>
12782
12783 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
12784 $(EXTRA_GNAT1_OBJS).
12785 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
12786 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
12787 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
12788 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
12789 libcommon-target.a instead of prefix.o.
12790
127912011-05-21 Joseph Myers <joseph@codesourcery.com>
12792
12793 PR ada/49097
12794 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
12795
127962011-05-20 Joseph Myers <joseph@codesourcery.com>
12797
12798 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
12799 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
12800 instead of version.o.
12801
2d0dd51a 128022011-05-18 Kai Tietz <ktietz@redhat.com>
052e0603
AC
12803
12804 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
12805 boolean_false_node instead of integer_zero_node.
12806 (convert_with_check): Likewise.
12807 * gcc-interface/decl.c (choices_to_gnu): Likewise.
12808
128092011-05-12 Eric Botcazou <ebotcazou@adacore.com>
12810
12811 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
12812 type of the parameter is an unconstrained array, convert the actual to
12813 the type of the formal in the In Out and Out cases as well.
12814
128152011-05-11 Nathan Froyd <froydnj@codesourcery.com>
12816
12817 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
12818 call build_function_type_array or build_varargs_function_type_array
12819 instead.
12820 (create_subprog_type): Don't call build_function_type; call
12821 build_function_type_vec instead.
12822
128232011-05-11 Nathan Froyd <froydnj@codesourcery.com>
12824
12825 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
12826 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
12827 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
12828
128292011-05-07 Eric Botcazou <ebotcazou@adacore.com>
12830
12831 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
12832
12833 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
12834 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
12835
128362011-05-05 Nathan Froyd <froydnj@codesourcery.com>
12837
12838 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
12839
128402011-05-05 Nathan Froyd <froydnj@codesourcery.com>
12841
12842 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
12843 instead of accessing TYPE_ARG_TYPES directly.
12844 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
12845
128462011-05-05 Eric Botcazou <ebotcazou@adacore.com>
12847
12848 PR ada/48844
12849 * gcc-interface/gigi.h (get_variant_part): Declare.
12850 * gcc-interface/decl.c (get_variant_part): Make global.
12851 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
12852 types have the same constant size, are record types and T1 has a
12853 variant part while T2 doesn't.
12854
128552011-05-05 Eric Botcazou <ebotcazou@adacore.com>
12856
12857 * gcc-interface/utils.c (begin_subprog_body): Do not call
12858 get_pending_sizes.
12859 (end_subprog_body): Likewise.
12860
128612011-05-04 Richard Guenther <rguenther@suse.de>
12862
12863 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
12864 int_const_binop.
12865 (pos_to_constructor): Likewise.
12866
128672011-05-03 Nathan Froyd <froydnj@codesourcery.com>
2c7f9cc0 12868 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
12869
12870 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
12871 of build_function_type. Adjust calls to...
12872 (build_raise_check): ...this. Do not take a void_tree parameter.
12873 Call build_function_type_list instead of build_function_type.
12874 Fix head comment and swap couple of conditional blocks.
12875
128762011-04-30 Eric Botcazou <ebotcazou@adacore.com>
12877
12878 * gnatvsn.ads (Library_Version): Bump to 4.7.
12879 (Current_Year): Bump to 2011.
12880
128812011-04-29 Michael Matz <matz@suse.de>
12882
12883 * gcc-interface/misc.c (gnat_handle_option): Set
12884 warn_maybe_uninitialized.
12885
128862011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
12887
12888 * gnat_ugn.texi (Complexity Metrics Control): Update link to
12889 the Watson/McCabe paper.
12890
128912011-04-23 Jim Meyering <meyering@redhat.com>
12892
12893 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
12894
128952011-04-22 Eric Botcazou <ebotcazou@adacore.com>
12896
12897 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
12898 onto the new type.
12899
129002011-04-22 Eric Botcazou <ebotcazou@adacore.com>
12901
12902 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
12903 parameter.
12904 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
12905 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
12906 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
12907 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
12908 <all>: Do not set flags on the reused DECL node coming from an alias.
12909 Set DECL_IGNORED_P on the DECL node built for subprograms if they
12910 don't need debug info here...
12911 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
12912 (gigi): Adjust calls to create_subprog_decl.
12913 (build_raise_check): Likewise.
12914 (establish_gnat_vms_condition_handler): Likewise.
12915 (Compilation_Unit_to_gnu): Likewise.
12916 (gnat_to_gnu): Likewise.
12917
129182011-04-21 Eric Botcazou <ebotcazou@adacore.com>
12919
12920 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
12921 (NO_REORDER_ADAFLAGS): New variable.
12922 (EXTRA_GNATTOOLS): Always define.
12923 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
12924 Clean up and adjust list of files compiled with special options.
12925 * gcc-interface/Make-lang.in: Likewise.
12926 (ada/decl.o): Cosmetical change.
12927 (ada/misc.o): Remove dependency on $(PLUGIN_H).
12928
129292011-04-20 Jim Meyering <meyering@redhat.com>
12930
12931 * initialize.c (__gnat_initialize): Remove useless if-before-free.
12932
129332011-04-17 Eric Botcazou <ebotcazou@adacore.com>
12934
12935 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
12936 $(CFLAGS) on the link line.
12937
129382011-04-17 Eric Botcazou <ebotcazou@adacore.com>
12939
12940 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
12941 padded type built for the return type if it is unconstrained.
12942
129432011-04-14 Nathan Froyd <froydnj@codesourcery.com>
12944
12945 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
12946
129472011-04-12 Nathan Froyd <froydnj@codesourcery.com>
12948
12949 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
12950 before calling TREE_CHAIN.
12951 * gcc-interface/misc.c (gnat_init_ts): New function.
12952 (LANG_HOOKS_INIT_TS): Define.
12953
129542011-04-12 Martin Jambor <mjambor@suse.cz>
12955
12956 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
12957 instead of cgraph_node.
12958
129592011-04-08 Eric Botcazou <ebotcazou@adacore.com>
12960
12961 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
12962 alignment on fields of the RETURN type built for the Copy-In Copy-Out
12963 mechanism.
12964
129652011-04-08 Eric Botcazou <ebotcazou@adacore.com>
12966
12967 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
12968 of aggregate types that contain a placeholder.
12969
129702011-04-08 Nathan Froyd <froydnj@codesourcery.com>
12971
12972 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
12973 TYPE_ARG_TYPES.
12974 (handle_type_generic_attribute): Likewise.
12975
129762011-04-04 Eric Botcazou <ebotcazou@adacore.com>
12977
12978 PR ada/47163
12979 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
12980
129812011-04-04 Kai Tietz <ktietz@redhat.com>
12982
12983 PR ada/47163
12984 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
12985 to flag value.
12986
129872011-04-02 Eric Botcazou <ebotcazou@adacore.com>
12988
12989 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
12990 type case, do not strip a padding type around the array type.
12991
129922011-04-02 Eric Botcazou <ebotcazou@adacore.com>
12993
12994 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
12995 types.
12996
129972011-04-02 Eric Botcazou <ebotcazou@adacore.com>
12998
12999 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
13000 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
13001 code for -feliminate-unused-debug-types.
13002 (gnat_post_options): Likewise.
13003
130042011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13005
13006 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
13007 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
13008 distinct copy.
13009
130102011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13011
13012 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
13013 DECL_ARTIFICIAL flag on enumeration types.
13014
130152011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13016
13017 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
13018 fat pointer types artificial unconditionally.
13019 <E_Array_Subtype>: Attach the base array type as a parallel type if it
13020 isn't artificial.
13021
130222011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13023
13024 * gcc-interface/gigi.h (get_dummy_type): Declare.
13025 (build_dummy_unc_pointer_types): Likewise.
13026 (finish_fat_pointer_type): Likewise.
13027 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
13028 fat pointer type has been built, complete it in place.
13029 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
13030 and thin pointers. Remove useless variable.
13031 (finish_fat_pointer_type): Make global and move to...
13032 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
13033 (get_dummy_type): New function.
13034 (build_dummy_unc_pointer_types): Likewise.
13035 (gnat_pushdecl): Propage the name to the anonymous variants only.
13036 (update_pointer_to): Only adjust the pointer types in the unconstrained
13037 array case.
13038
130392011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13040
13041 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
13042 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
13043 if this is a Taft amendment type and the full declaration is available.
13044 * gcc-interface/trans.c (process_type): Likewise.
13045 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
13046 (process_freeze_entity): Likewise.
13047 * gcc-interface/utils.c (dummy_global): New static variable.
13048 (gnat_write_global_declarations): If there are types declared as used
13049 at the global level, insert them in the global hash table.
13050
130512011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13052
13053 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
13054 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
13055 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
13056 copy.
13057 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
13058 flag of the type accordingly.
13059 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
13060
130612011-04-02 Eric Botcazou <ebotcazou@adacore.com>
13062
13063 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
13064 finalizing types when updating the pointers to the designated type.
13065 <all>: Finalize the deferred types even if we didn't defer processing
13066 of incomplete types in this invocation.
13067
130682011-04-01 Olivier Hainque <hainque@adacore.com>
2c7f9cc0
AS
13069 Nicolas Setton <setton@adacore.com>
13070 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
13071
13072 * gcc-interface/misc.c (gnat_descriptive_type): New function.
13073 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
13074
130752011-03-28 Kai Tietz <ktietz@redhat.com>
13076
13077 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
13078 Windows targets.
13079 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
13080 * system-mingw.ads (System): Change ZCX_By_Default default to True.
13081
13082 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
13083
130842011-03-28 Tristan Gingold <gingold@adacore.com>
13085
13086 PR ada/44431
13087 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
13088 Use ada output of gnatbind.
13089 (ada/b_gnatb.adb): Ditto.
13090 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
13091 (ada.mostlyclean, ada.stage1)
13092 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
13093 (ada.stagefeedback): Adjust.
13094 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
13095 Use ada output of gnatbind.
13096 (b_gnatm.adb): Ditto.
13097 (b_gnatl.o, b_gnatm.o): New rules.
13098
130992011-03-26 Eric Botcazou <ebotcazou@adacore.com>
13100
13101 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
13102 for the padded type built to support a specified size or alignment.
13103
131042011-03-26 Eric Botcazou <ebotcazou@adacore.com>
13105
13106 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
13107 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
13108 unconditionally to the end of the unit when the designated type is
13109 limited_with'ed.
13110 <all>: Rename local variable. Attempt to un-defer types only and do it
13111 for limited_with'ed types as well.
13112 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
13113 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
13114 consistently and remove redundant call to finalize_from_with_types.
13115
131162011-03-26 Eric Botcazou <ebotcazou@adacore.com>
13117
13118 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
13119 subprograms without a previous spec declared in the same unit.
13120 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
13121 subprograms at the end of the unit instead of at the beginning.
13122 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
13123 isn't public for the special handling of non-inline functions nested
13124 inside inline external functions.
13125
131262011-03-25 Jeff Law <law@redhat.com>
13127
13128 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
13129
131302011-03-24 Eric Botcazou <ebotcazou@adacore.com>
13131
13132 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
13133 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
13134 to compute Set_Size_Depends_On_Discriminant.
13135 (Layout_Type): Call it on array types in back-end layout mode.
13136 * sem_util.adb (Requires_Transient_Scope): Return true for array
13137 types only if the size depends on the value of discriminants.
13138 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
13139 type if the RHS is a call to a function that returns an unconstrained
13140 type with default discriminant.
13141
131422011-03-24 Eric Botcazou <ebotcazou@adacore.com>
13143
13144 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
13145 non-conversion to the nominal result type at the end.
13146
131472011-03-23 Eric Botcazou <ebotcazou@adacore.com>
13148
13149 * gcc-interface/trans.c (create_temporary): New function taken from...
13150 (create_init_temporary): ...here. Call it.
13151 (call_to_gnu): Create the temporary for the return value early, if any.
13152 Create it for a function with copy-in/copy-out parameters if there is
13153 no target; in other cases of copy-in/copy-out, use another temporary.
13154 Push the new binding level lazily. Add and rename local variables.
13155
131562011-03-23 Eric Botcazou <ebotcazou@adacore.com>
13157
13158 * gcc-interface/decl.c (validate_size): Improve comments and tweak
13159 error message.
13160 (set_rm_size): Likewise.
13161
131622011-03-23 Eric Botcazou <ebotcazou@adacore.com>
13163
13164 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
13165 for the padded type built in order to support a specified alignment.
13166 Fix incorrect formatting.
13167
131682011-03-21 Eric Botcazou <ebotcazou@adacore.com>
13169
13170 PR bootstrap/48216
13171 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
13172
131732011-03-21 Eric Botcazou <ebotcazou@adacore.com>
13174
13175 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
13176 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
13177 to the end of the list. Adjust recursive call. Rename local variable.
13178 If REORDER is true, reorder components of the record type.
13179 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
13180 components_to_record and adjust the parameter list.
13181
131822011-03-21 Eric Botcazou <ebotcazou@adacore.com>
13183
13184 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
13185 disabled, use the variable for bounds of loop iteration scheme.
13186
131872011-03-21 Kai Tietz <ktietz@redhat.com>
13188
13189 PR target/12171
13190 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
13191
131922011-03-17 Eric Botcazou <ebotcazou@adacore.com>
13193
13194 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
13195 out whether the expression is read-only. Short-circuit placeholder
13196 case and rename a couple of local variables.
13197
131982011-03-17 Eric Botcazou <ebotcazou@adacore.com>
13199
13200 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
13201 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
13202 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
13203 (convert): Deal with conversions from a smaller form type specially.
13204
132052011-02-14 Eric Botcazou <ebotcazou@adacore.com>
13206
13207 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
13208 its argument, except for the special -I- switch.
13209
132102011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
13211
13212 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
13213 "Ada Issues".
13214
132152011-02-08 Eric Botcazou <ebotcazou@adacore.com>
13216
13217 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
13218
132192011-02-03 Eric Botcazou <ebotcazou@adacore.com>
13220
13221 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
13222 GNAT_FORMAL.
13223 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
13224 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
13225 instead of GNAT_FORMAL. Protect the expression against multiple uses.
13226 Do not generate the check directly, instead instantiate the template
13227 check present in the descriptor.
13228 (make_descriptor_field): Move around.
13229 (build_vms_descriptor32): Build a template check in the POINTER field.
13230 (build_vms_descriptor): Remove useless suffixes.
13231 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
13232
132332011-01-26 Eric Botcazou <ebotcazou@adacore.com>
13234
13235 PR bootstrap/47467
13236 * targext.c: Include target files if IN_RTS is defined.
13237
132382011-01-26 Richard Guenther <rguenther@suse.de>
13239
13240 PR bootstrap/47467
13241 * targext.c: Include config.h.
13242 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
13243 dependency.
13244
132452011-01-04 Pascal Obry <obry@adacore.com>
2c7f9cc0 13246 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
13247
13248 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
13249
132502011-01-04 Eric Botcazou <ebotcazou@adacore.com>
13251
13252 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
13253 end-of-case on the end label and its associated gotos, if any.
13254
132552011-01-04 Eric Botcazou <ebotcazou@adacore.com>
13256
13257 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
13258 expressions of the parameter cache within the statement group of
13259 the CICO mechanism.
13260
132612011-01-04 Olivier Hainque <hainque@adacore.com>
2c7f9cc0 13262 Eric Botcazou <ebotcazou@adacore.com>
052e0603
AC
13263
13264 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
13265 (set_end_locus_from_node): New function.
13266 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
13267 make and the function end_locus.
13268 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
13269 for the elaboration subprogram.
13270 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
13271 set the end_locus of the expression as well.
13272
132732011-01-04 Eric Botcazou <ebotcazou@adacore.com>
13274
13275 PR ada/47131
13276 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
13277 variables that are referenced in exception handlers volatile.
13278
13279
13280\f
13281Copyright (C) 2011 Free Software Foundation, Inc.
13282
13283Copying and distribution of this file, with or without modification,
13284are permitted in any medium without royalty provided the copyright
13285notice and this notice are preserved.
13286
13287 * gnat_rm.texi: Ramification of pragma Eliminate documentation
13288 - fix bugs in the description of Source_Trace;
13289 - get rid of UNIT_NAME;
13290
4fbad0ba
AC
132912011-08-02 Javier Miranda <miranda@adacore.com>
13292
13293 * exp_ch9.adb
13294 (Build_Dispatching_Requeue): Adding support for VM targets
13295 since we cannot directly reference the Tag entity.
13296 * exp_sel.adb (Build_K): Adding support for VM targets.
13297 (Build_S_Assignment): Adding support for VM targets.
13298 * exp_disp.adb
13299 (Default_Prim_Op_Position): In VM targets do not restrict availability
13300 of predefined interface primitives to compiling in Ada 2005 mode.
13301 (Is_Predefined_Interface_Primitive): In VM targets this service is not
13302 restricted to compiling in Ada 2005 mode.
13303 (Make_VM_TSD): Generate code that declares and initializes the OSD
13304 record. Needed to support dispatching calls through synchronized
13305 interfaces.
13306 * exp_ch3.adb
13307 (Make_Predefined_Primitive_Specs): Enable generation of predefined
13308 primitives associated with synchronized interfaces.
13309 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
13310 primitives associated with synchronized interfaces.
13311
133122011-08-02 Yannick Moy <moy@adacore.com>
13313
13314 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
13315 statements hidden in SPARK if preceded by the HIDE directive
13316 (Parse_Exception_Handlers): mark each exception handler in a sequence of
13317 exception handlers as hidden in SPARK if preceded by the HIDE directive
13318 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
13319 if starting with the HIDE directive
13320 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
13321 starting with the HIDE directive; mark the declarations in a private
13322 part as hidden in SPARK if the private part starts with the HIDE
13323 directive
13324 * restrict.adb, restrict.ads
13325 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
13326 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
13327 argument node belongs to a part which is hidden in SPARK
13328 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
13329 parts in SPARK; protect the possibly costly call to
13330 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
13331 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
13332 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
13333 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
13334 Tok_SPARK_Hide.
13335 (Scan): recognize special comment starting with '#' and followed by
13336 SPARK keyword "hide" as a HIDE directive.
13337
133382011-08-02 Yannick Moy <moy@adacore.com>
13339
13340 * types.ads, erroutc.ads: Minor reformatting.
13341
133422011-08-02 Vincent Celier <celier@adacore.com>
13343
13344 * link.c: Add response file support for cross platforms.
13345
6ff6152d
ES
133462011-08-02 Ed Schonberg <schonberg@adacore.com>
13347
13348 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
13349 in an association, set parent field of copy before partial analysis.
13350 * sem_res.adb (Resolve_Slice): create reference to itype only when
13351 expansion is enabled.
13352
975c6896
YM
133532011-08-02 Yannick Moy <moy@adacore.com>
13354
13355 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
13356 for new flag denoting which subprogram bodies are in ALFA
13357 * restrict.adb, sem_ch7.adb: Update comment
13358 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
13359 sem_ch9.adb, sem_res.adb: Add calls to
13360 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
13361 * sem_ch6.adb (Analyze_Function_Return): add calls to
13362 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
13363 middle of the body, and extended return.
13364 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
13365 False when missing return.
13366 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
13367 to True for subprograms whose spec is in ALFA. Remove later on the flag
13368 on the entity used for a subprogram body when there exists a separate
13369 declaration.
13370 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
13371 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
13372 False, otherwise do nothing.
13373
afc8324d
AC
133742011-08-02 Robert Dewar <dewar@adacore.com>
13375
13376 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
13377
133782011-08-02 Yannick Moy <moy@adacore.com>
13379
13380 * sem_ch4.ads: minor formatting.
13381
2ba431e5
YM
133822011-08-02 Yannick Moy <moy@adacore.com>
13383
13384 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
13385 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
13386 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
13387 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
13388 opt.ads: cleanup of SPARK mode
13389
0f853035
YM
133902011-08-02 Yannick Moy <moy@adacore.com>
13391
13392 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
13393 types.
13394 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
13395 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
13396 * sem_ch3.adb
13397 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
13398 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
13399 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
13400 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
13401 types.
13402 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
13403 non-static range.
13404 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
13405 functions whose return type is not in ALFA.
13406 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
13407 specifications.
13408 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
13409 parameter's type is not in ALFA.
13410 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
13411 types are in ALFA.
13412
d2b10647
ES
134132011-08-02 Ed Schonberg <schonberg@adacore.com>
13414
13415 * sem_ch6 (Analyze_Expression_Function): treat the function as
13416 Inline_Always, and introduce a subprogram declaration for it when it is
13417 not a completion.
13418 * inline.adb (Add_Inlined_Body): recognize bodies that come from
13419 expression functions, so that the back-end can determine whether they
13420 can in fact be inlined.
13421 * sem_util.adb (Is_Expression_Function): predicate to determine whether
13422 a function body comes from an expression function.
13423
c7b9d548
AC
134242011-08-02 Gary Dismukes <dismukes@adacore.com>
13425
13426 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
13427 null exclusions to test Can_Never_Be_Null on the anonymous access types
13428 of the formals rather than testing the formals themselves. Exclude this
13429 check in cases where the Old_Formal is marked as a controlling formal,
13430 to avoid issuing spurious errors for bodies completing dispatching
13431 operations (due to the flag not getting set on controlling access
13432 formals in body specs).
13433 (Find_Corresponding_Spec): When checking full and subtype conformance of
13434 subprogram bodies in instances, pass Designated and E in that order, for
13435 consistency with the expected order of the formals (New_Id followed by
13436 Old_Id).
13437
134382011-08-02 Robert Dewar <dewar@adacore.com>
13439
13440 * sem_ch8.adb: Minor reformatting.
13441
1138cf59
AC
134422011-08-02 Ed Schonberg <schonberg@adacore.com>
13443
13444 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
13445 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
13446 primitive operations of class-wide actuals.
13447
134482011-08-02 Javier Miranda <miranda@adacore.com>
13449
13450 * exp_atag.ads, exp_atag.adb
13451 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
13452 since its value is implicitly passed in argument Typ.
13453 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
13454 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
13455 Build_Common_Dispatching_Select_Statements.
13456
7b9db926
RD
134572011-08-02 Robert Dewar <dewar@adacore.com>
13458
13459 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
13460 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
13461 Minor reformatting.
13462
e8374e7a
AC
134632011-08-02 Robert Dewar <dewar@adacore.com>
13464
13465 * sem_res.adb: Minor reformatting.
13466 * sem_prag.adb: Minor reformatting.
13467
134682011-08-02 Javier Miranda <miranda@adacore.com>
13469
13470 * exp_atag.adb, exp_atags.ads
13471 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
13472 by the tagged type Entity. Required to use this routine in the VM
13473 targets since we do not have available the Tag entity in the VM
13474 platforms.
13475 * exp_ch6.adb
13476 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
13477 Ada.Tags has not been previously loaded.
13478 * exp_ch7.adb
13479 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
13480 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
13481 * sem_aux.adb
13482 (Enclosing_Dynamic_Scope): Add missing support to handle the full
13483 view of enclosing scopes. Required to handle enclosing scopes that
13484 are synchronized types whose full view is a task type.
13485 * exp_disp.adb
13486 (Build_VM_TSDs): Minor code improvement to avoid generating and
13487 analyzing lists with empty nodes.
13488 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
13489 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
13490 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
13491 (Make_Disp_Timed_Select_Body): Add support for VM targets.
13492 (Make_Select_Specific_Data_Table): Add support for VM targets.
13493 (Make_VM_TSD): Generate code to initialize the SSD structure of
13494 the TSD.
13495
134962011-08-02 Yannick Moy <moy@adacore.com>
13497
13498 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
13499 cross-references section in ALI.
13500 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
13501 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
13502 Sub).
13503 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
13504 subprogram or package entity of a node
13505 (Is_Local_Reference_Type): new function returns True for references
13506 selected in local cross-references.
13507 (Lt): function extracted from Lt in Output_References
13508 (Write_Entity_Name): function extracted from Output_References
13509 (Generate_Definition): generate reference with type 'D' for definition
13510 of objects (object declaration and parameter specification), with
13511 appropriate locations and units, for use in local cross-references.
13512 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
13513 references of type 'I' for initialization in object definition.
13514 (Output_References): move part of function Lt and procedure
13515 Write_Entity_Name outside of the body. Ignore references of types 'D'
13516 and 'I' introduced for local cross-references.
13517 (Output_Local_References): new procedure to output the local
13518 cross-references sections.
13519 (Lref_Entity_Status): new array defining whether an entity is a local
13520 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
13521 with 'I' type when initialization expression is present.
13522 * get_scos.adb, get_scos.ads: Correct comments and typos
13523
1f6439e3
AC
135242011-08-02 Javier Miranda <miranda@adacore.com>
13525
13526 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
13527 the JVM target.
13528 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
13529 the JVM target.
13530 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
13531 TSD support.
13532
135332011-08-02 Vincent Celier <celier@adacore.com>
13534
13535 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
13536 (No_Space_Img): New function
13537 (Find_Excluded_Sources): When reading from a file, record the file name
13538 and the line number for each excluded source.
13539 (Mark_Excluded_Sources): When reporting an error, if the excluded
13540 sources were read from a file, include file name and line number in
13541 the error message.
13542
135432011-08-02 Ed Schonberg <schonberg@adacore.com>
13544
13545 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
13546
ab027d28
RD
135472011-08-02 Robert Dewar <dewar@adacore.com>
13548
13549 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
13550
b3b28b0c
JM
135512011-08-02 Javier Miranda <miranda@adacore.com>
13552
13553 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
13554 generation of TSDs to the DOTNET compiler.
13555 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
13556 generation of TSDs to the DOTNET compiler.
13557
9732e886
JM
135582011-08-02 Javier Miranda <miranda@adacore.com>
13559
13560 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
13561 record of all the tagged types declared inside library level package
13562 declarations, library level package bodies or library level subprograms.
13563 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
13564 associated with a given tagged type.
13565 (Build_VM_TSDs): New subprogram.
13566 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
13567 compilation units that are subprograms.
13568 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
13569 compilation units that are package bodies.
13570 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
13571 units that are a package declaration or a package instantiation.
13572 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
13573 reorganization to improve the error generated by the frontend when the
13574 function Ada.Tags.Secondary_Tag is not available.
13575 * rtsfind.ads (RE_Register_TSD): New runtime entity.
13576 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
13577
e526d0c7
AC
135782011-08-02 Javier Miranda <miranda@adacore.com>
13579
13580 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
13581
135822011-08-02 Robert Dewar <dewar@adacore.com>
13583
13584 * s-imenne.ads: Minor reformatting.
13585
135862011-08-02 Robert Dewar <dewar@adacore.com>
13587
13588 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
13589 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
13590 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
13591
135922011-08-02 Robert Dewar <dewar@adacore.com>
13593
13594 * einfo.ads (Materialize_Entity): Document this is only for renamings
13595 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
13596 required debug information in the case where we transform the object
13597 declaration into a renaming declaration.
13598 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
13599 object
13600 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
13601 Materialize_Entity.
13602
5b1e6aca
RD
136032011-08-02 Robert Dewar <dewar@adacore.com>
13604
13605 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
13606 Suppress_Init_Procs.
13607 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
13608 Suppress_Initialization/Initialization_Suppressed.
13609 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
13610 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
13611 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
13612 * sem_prag.adb: New processing for pragma Suppress_Initialization.
13613
5ad4969d
RD
136142011-08-02 Robert Dewar <dewar@adacore.com>
13615
13616 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
13617 Minor reformatting.
13618
8c4ee6f5
AC
136192011-08-02 Ed Schonberg <schonberg@adacore.com>
13620
13621 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
13622 only have inheritable classwide pre/postconditions.
13623
136242011-08-02 Javier Miranda <miranda@adacore.com>
13625
13626 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
13627 * rtsfind.ads (RE_Check_TSD): New runtime entity.
13628 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
13629 checks if the external tag of a type is the same as the external tag
13630 of some other declaration.
13631
0b3d16c0
AC
136322011-08-02 Thomas Quinot <quinot@adacore.com>
13633
13634 * s-taskin.ads: Minor reformatting.
13635
136362011-08-02 Emmanuel Briot <briot@adacore.com>
13637
13638 * g-comlin.adb (Display_Help): swap the order in which it prints the
13639 short help and the general usage.
13640
136412011-08-02 Ed Schonberg <schonberg@adacore.com>
13642
13643 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
13644 the aspect declarations and attach them to the generic copy for
13645 subsequent analysis.
13646 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
13647 declarations of the generic tree to the new subprogram declarations.
13648 * sem_attr.adb (Check_Precondition_Postcondition): recognize
13649 conditions that apply to a subprogram instance.
13650
136512011-08-02 Robert Dewar <dewar@adacore.com>
13652
13653 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
13654
136552011-08-02 Ed Schonberg <schonberg@adacore.com>
13656
13657 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
13658 private type with a tagged full view is not derived in the immediate
13659 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
13660
4637729f
AC
136612011-08-02 Robert Dewar <dewar@adacore.com>
13662
13663 * exp_ch4.adb: Minor reformatting.
13664
136652011-08-02 Ed Schonberg <schonberg@adacore.com>
13666
13667 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
13668 Ada2012 iterator, the loop will be rewritten during expansion into a
13669 while loop with a cursor and an element declaration. Do not analyze the
13670 body in this case, because if the container is for indefinite types the
13671 actual subtype of the elements will only be determined when the cursor
13672 declaration is analyzed.
13673
136742011-08-02 Arnaud Charlet <charlet@adacore.com>
13675
13676 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
13677 size/alignment related attributes in CodePeer_Mode.
13678
136792011-08-02 Gary Dismukes <dismukes@adacore.com>
13680
13681 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
13682 Prepend_Element, since this can result in the operation getting the
13683 wrong slot in the full type's dispatch table if the full type has
13684 inherited operations. The incomplete type's operation will get added
13685 to the proper position in the full type's primitives
13686 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
13687 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
13688 dispatching operations, since there are cases where nonprimitive
13689 subprograms can get added to the list of incomplete dependents (such
13690 as subprograms in nested packages).
13691 * sem_ch6.adb (Process_Formals): First, remove test for being in a
13692 private part when determining whether to add a primitive with a
13693 parameter of a tagged incomplete type to the Private_Dependents list.
13694 Such primitives can also occur in the visible part, and should not have
13695 been excluded from being private dependents.
13696 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
13697 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
13698 list of a Taft-amendment incomplete type is a primitive before issuing
13699 an error that the full type must appear in the same unit. There are
13700 cases where nonprimitives can be in the list (such as subprograms in
13701 nested packages).
13702 * sem_disp.adb (Derives_From): Use correct condition for checking that
13703 a formal's type is derived from the type of the corresponding formal in
13704 the parent subprogram (the condition was completely wrong). Add
13705 checking that was missing for controlling result types being derived
13706 from the result type of the parent operation.
13707
4c60de0c
YM
137082011-08-02 Yannick Moy <moy@adacore.com>
13709
13710 * errout.adb (First_Node): minor renaming
13711 * restrict.adb (Check_Formal_Restriction): put restriction warning on
13712 first node.
13713
f5afb270
AC
137142011-08-02 Yannick Moy <moy@adacore.com>
13715
13716 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
13717 before accessing operands.
13718 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
13719 decide whether an initialization expression respects SPARK rules, as
13720 the plain node is the expanded one. This allows for more valid warnings
13721 to be issued.
13722 * gnat_rm.texi: Minor update.
13723
137242011-08-02 Arnaud Charlet <charlet@adacore.com>
13725
13726 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
13727 previous change.
13728
137292011-08-02 Robert Dewar <dewar@adacore.com>
13730
13731 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
13732
137332011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
13734
13735 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
13736 loop statements and the element renaming declaration with a block when
13737 the element type is controlled.
13738
137392011-08-02 Yannick Moy <moy@adacore.com>
13740
13741 * sinfo.ads: Minor formatting.
13742
137432011-08-02 Ed Schonberg <schonberg@adacore.com>
13744
13745 * sem_aggr.adb (Add_Association): if the association has a box and no
13746 expression, use the Sloc of the aggregate itself for the new
13747 association.
13748 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
13749 the Original_Node.
13750
db72f10a
AC
137512011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
13752
13753 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
13754 When a container is provided via a function call, generate a renaming
13755 of the function result. This avoids the creation of a transient scope
13756 and the premature finalization of the container.
13757 * exp_ch7.adb (Is_Container_Cursor): Removed.
13758 (Wrap_Transient_Declaration): Remove the supression of the finalization
13759 of the list controller when the declaration denotes a container cursor,
13760 it is not needed.
13761
137622011-08-02 Yannick Moy <moy@adacore.com>
13763
13764 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
13765 node is from source, instead of the original node being from source.
13766 * sem_aggr.adb
13767 (Resolve_Array_Aggregate): refine the check for a static expression, to
13768 recognize also static ranges
13769 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
13770 Array_Type_Declaration): postpone the test for the type being a subtype
13771 mark after the type has been resolved, so that component-selection and
13772 expanded-name are discriminated.
13773 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
13774 to distinguish the case of an iteration scheme, so that an error is
13775 issed on a non-static range in SPARK except in an iteration scheme.
13776 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
13777 In_Iter_Schm = True.
13778 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
13779 user-defined operators so that they are allowed in renaming
13780 * sem_ch8.adb
13781 (Find_Selected_Component): refine the check for prefixing of operators
13782 so that they are allowed in renaming. Move the checks for restrictions
13783 on selector name after analysis discriminated between
13784 component-selection and expanded-name.
13785 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
13786 concatenation argument of string type if it is static.
13787 * sem_util.adb, sem_util.ads
13788 (Check_Later_Vs_Basic_Declarations): add a new function
13789 Is_Later_Declarative_Item to decice which declarations are allowed as
13790 later items, in the two different modes Ada 83 and SPARK. In the SPARK
13791 mode, add that renamings are considered as later items.
13792 (Enclosing_Package): new function to return the enclosing package
13793 (Enter_Name): correct the rule for homonyms in SPARK
13794 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
13795 from source (result of expansion) to avoid issuing wrong warnings.
13796
137972011-08-02 Ed Schonberg <schonberg@adacore.com>
13798
13799 * errout.adb: On anything but an expression First_Node returns its
13800 argument.
13801
23685ae6
AC
138022011-08-02 Pascal Obry <obry@adacore.com>
13803
13804 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
13805
138062011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
13807
13808 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
13809 Set the associated loop as the related expression of internally
13810 generated cursors.
13811 * exp_ch7.adb (Is_Container_Cursor): New routine.
13812 (Wrap_Transient_Declaration): Supress the finalization of the list
13813 controller when the declaration denotes a container cursor.
13814
138152011-08-02 Yannick Moy <moy@adacore.com>
13816
13817 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
13818 command line now.
13819 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
13820 expression is a simple expression. This check cannot be performed in
13821 the semantics, so just drop it.
13822 (P_Index_Or_Discriminant_Constraint): move check that the index or
13823 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
13824 semantics. Other cases were previously checked in the semantics.
13825 * par-ch4.adb (P_Name): move checks that a selector name is not
13826 character literal or an operator symbol to Find_Selected_Component in
13827 the semantics
13828 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
13829 declarations are not placed after later declarations in a separate
13830 procedure in Sem_Util (possibly not the best choice?), to be used both
13831 during parsing, for Ada 83 mode, and during semantic analysis, for
13832 SPARK mode.
13833 * par-endh.adb (Check_End): move check that end label is not missing
13834 to Process_End_Label in the semantics
13835 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
13836 the special case for SPARK restriction
13837 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
13838 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
13839 parameter Force to issue the error message even on internal node (used
13840 for generated end label). Call Check_Restriction to check when an error
13841 must be issued. In SPARK mode, issue an error message even if the
13842 restriction is not set.
13843 (Check_Restriction): new procedure with an additional out parameter to
13844 inform the caller that a message has been issued
13845 * sem_aggr.adb: Minor modification of message
13846 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
13847 instead of issuing an error message directly
13848 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
13849 declarations are not placed after later declarations, by calling
13850 Check_Later_Vs_Basic_Declarations
13851 (Analyze_Subtype_Declaration): move here the check that an index or
13852 discriminant constraint must be a subtype mark. Change the check that
13853 a subtype of String must start at one so that it works on subtype marks.
13854 * sem_ch4.adb (Analyze_Call): move here the check that a named
13855 association cannot follow a positional one in a call
13856 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
13857 instead of issuing an error message directly
13858 * sem_ch8.adb (Find_Selected_Component): move here the check that a
13859 selector name is not a character literal or an operator symbol. Move
13860 here the check that the prefix of an expanded name cannot be a
13861 subprogram or a loop statement.
13862 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
13863 procedure called from parsing and semantics to check that basic
13864 declarations are not placed after later declarations
13865 (Process_End_Label): move here the check that end label is not missing
13866
138672011-08-02 Arnaud Charlet <charlet@adacore.com>
13868
13869 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
13870 representation clause in codepeer mode, since it confuses CodePeer and
13871 does not bring useful info.
13872
138732011-08-02 Ed Falis <falis@adacore.com>
13874
13875 * init.c: initialize fp hw on MILS.
13876
138772011-08-02 Ed Schonberg <schonberg@adacore.com>
13878
13879 * errout.adb (First_Node): for bodies, return the node itself (small
13880 optimization). For other nodes, do not check source_unit if the node
13881 comes from Standard.
13882
d2d9cc22
AC
138832011-08-02 Robert Dewar <dewar@adacore.com>
13884
13885 * exp_ch3.adb: Minor comment additions.
13886 * sem_ch13.adb: Minor reformatting.
13887
138882011-08-02 Pascal Obry <obry@adacore.com>
13889
13890 * make.adb, makeutl.adb: Removes some superfluous directory separator.
13891
a01b9df6
AC
138922011-08-02 Robert Dewar <dewar@adacore.com>
13893
13894 * sem_attr.adb: Minor reformatting.
13895
138962011-08-02 Robert Dewar <dewar@adacore.com>
13897
13898 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
13899 (Has_Default_Component_Value): Removed
13900 * einfo.ads Comment updates
13901 (Has_Default_Aspect): Replaces Has_Default_Value
13902 (Has_Default_Component_Value): Removed
13903 * exp_ch13.adb
13904 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
13905 * exp_ch3.adb
13906 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
13907 (Get_Simple_Init_Val): Handle Default_Value aspect
13908 (Needs_Simple_Initialization): Handle Default_Value aspect
13909 * exp_ch3.ads: Needs_Simple_Initialization
13910 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
13911 * par-prag.adb (Pragma_Default[_Component]Value) Removed
13912 * sem_ch13.adb
13913 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
13914 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
13915 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
13916
139172011-08-02 Ed Schonberg <schonberg@adacore.com>
13918
13919 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
13920 package containing iteration primitives.
13921 exp_ch5.adb (Expand_Iterator_Loop): ditto.
13922
75c90775
AC
139232011-08-02 Ed Schonberg <schonberg@adacore.com>
13924
13925 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
13926 "of", pre-analyze expression in case it is a function call with
13927 finalization actions that must be placed ahead of the loop.
13928 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
13929 on an Ada2012 iterator, insert them ahead of the rewritten loop.
13930
139312011-08-02 Geert Bosch <bosch@adacore.com>
13932
13933 * cstand.adb (Create_Float_Types): Only consider C's long double for
13934 Long_Long_Float, in addition to double.
13935
ded8909b
AC
139362011-08-02 Robert Dewar <dewar@adacore.com>
13937
13938 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
13939 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
13940 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
13941 Minor reformatting.
13942
139432011-08-02 Ed Schonberg <schonberg@adacore.com>
13944
13945 * sem_attr.adb: handle properly 'Result when it is a prefix of an
13946 indexed component.
13947
139482011-08-02 Javier Miranda <miranda@adacore.com>
13949
13950 * einfo.ads, einfo.adb
13951 (Original_Access_Type): Move this attribute to Node26 since there was
13952 an undocumented use of Node21 in E_Access_Subprogram_Type entities
13953 which causes conflicts and breaks the generation of the .NET compiler.
13954 (Interface_Name): Add missing documentation on JGNAT only uses of
13955 this attribute.
13956
70c34e1c
AC
139572011-08-02 Geert Bosch <bosch@adacore.com>
13958
13959 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
13960 (Find_Back_End_Float_Type): Likewise
13961 (Create_Back_End_Float_Types): Likewise
13962 (Create_Float_Types): Likewise
13963 (Register_Float_Type): Likewise
13964 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
13965 Nlist and split out type selection in new local Find_Base_Type function.
13966 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
13967 Nlist
13968 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
13969
139702011-08-02 Robert Dewar <dewar@adacore.com>
13971
13972 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
13973 alpha order).
13974 * opt.ads: Minor comment change.
13975 * sem_ch12.adb: Minor code reorganization.
13976
b715bc59
AC
139772011-08-02 Gary Dismukes <dismukes@adacore.com>
13978
13979 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
13980 subtype's list of rep items to the list on the full subtype in the case
13981 where the lists are the same.
13982
139832011-08-02 Geert Bosch <bosch@adacore.com>
13984
13985 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
13986 using the one from System.Strings, which also deallocates all strings.
13987
002bdd68
AC
139882011-08-02 Geert Bosch <bosch@adacore.com>
13989
13990 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
13991 function.
13992 * gcc-interface/Make-lang.in: Update dependencies.
13993
139942011-08-02 Olivier Hainque <hainque@adacore.com>
13995
13996 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
13997 end_locus.
13998
499769ec
AC
139992011-08-02 Javier Miranda <miranda@adacore.com>
14000
14001 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
14002 associated with anonymous access to subprograms.
14003
140042011-08-02 Geert Bosch <bosch@adacore.com>
14005
14006 * opt.ads
14007 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
14008 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
14009 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
14010 (Add_Symbol_Definition): Move to switch-c.adb
14011 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
14012 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
14013 (Add_Symbol_Definition): Move to switch-c.adb.
14014 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
14015 * sem_warn.adb
14016 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
14017 Move to warnsw.adb.
14018 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
14019 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
14020 Move to warnsw.adb.
14021 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
14022 (Add_Symbol_Definition): Moved from Prepcomp.
14023 * switch-c.ads: Update copyright notice. Use String_List instead of
14024 Argument_List, removing dependency on System.OS_Lib.
14025
aa1e353a
AC
140262011-08-02 Yannick Moy <moy@adacore.com>
14027
14028 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
14029 mode on initialization expression which does not respect SPARK
14030 restrictions.
14031 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
14032 if the tree referenced by its argument represents an initialization
14033 expression in SPARK, suitable for initializing an object in an object
14034 declaration.
14035
140362011-08-02 Javier Miranda <miranda@adacore.com>
14037
14038 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
14039 internally generated access to subprogram with its associated protected
14040 subprogram type.
14041 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
14042
15b682ca
GB
140432011-08-02 Geert Bosch <bosch@adacore.com>
14044
14045 * cstand.adb (Register_Float_Type): Print information about type to
14046 register, if the Debug_Flag_Dot_B is set.
14047 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
14048 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
14049 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
14050 with a requested precision of more than Max_Digits digits and no more
14051 than Max_Base_Digits digits, if a range specification is present and the
14052 Predefined_Float_Types list has a suitable type to derive from.
14053 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
14054 case of type completion with pragma Import
14055 * sem_prag.adb
14056 (Process_Import_Predefined_Type): Processing to complete a type
14057 with pragma Import. Currently supports floating point types only.
14058 (Set_Convention_From_Pragma): Do nothing without underlying type.
14059 (Process_Convention): Guard against absence of underlying type,
14060 which may happen when importing incomplete types.
14061 (Process_Import_Or_Interface): Handle case of importing predefined
14062 types. Tweak error message.
14063
f8726f2b
AC
140642011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14065
14066 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
14067 functions to previous change. Reorganize code slightly.
14068
140692011-08-02 Geert Bosch <bosch@adacore.com>
14070
14071 * back_end.ads (Register_Type_Proc): New call back procedure type for
14072 allowing the back end to provide information about available types.
14073 (Register_Back_End_Types): New procedure to register back end types.
14074 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
14075 available types.
14076 * cstand.adb (Back_End_Float_Types): New list for floating point types
14077 supported by the back end.
14078 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
14079 (Copy_Float_Type): New procedure to make new copies of predefined types.
14080 (Register_Float_Type): New call back procedure to populate the BEFT list
14081 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
14082 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
14083 (Create_Float_Types): New procedure to create entities for floating
14084 point types predefined in Standard, and put these and any remaining
14085 BEFTs on the Predefined_Float_Types list.
14086 * stand.ads (Predefined_Float_Types): New list for predefined floating
14087 point types that do not have declarations in package Standard.
14088
feecad68
AC
140892011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14090
14091 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
14092 entity node for the unit containing the parameter.
14093 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
14094 (Add_Inlined_Subprogram): Likewise.
14095 * gcc-interface/Make-lang.in: Update dependencies.
14096
140972011-08-02 Thomas Quinot <quinot@adacore.com>
14098
14099 * s-stusta.adb (Print): Make sure Pos is always initialized to a
14100 suitable value.
14101
12f0c50c
AC
141022011-08-02 Geert Bosch <bosch@adacore.com>
14103
14104 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
14105
141062011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14107
14108 * sem_type.adb (Covers): Move trivial case to the top and reuse the
14109 computed value of Base_Type.
14110
141112011-08-02 Yannick Moy <moy@adacore.com>
14112
14113 * restrict.adb (Check_Restriction): issue an error for any use of
14114 class-wide, even if the No_Dispatch restriction is not set.
14115 * sem_aggr.adb: Correct typos in comments and messages in formal mode
14116 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
14117 when completing a private extension, the type named in the private part
14118 is not the same as that named in the visible part.
14119 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
14120 of an inherited primitive operations of a tagged type or type extension
14121 that returns the tagged type.
14122 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
14123 function which returns True for an implicit operation inherited by the
14124 derived type declaration for the argument type.
14125 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
14126 order.
14127
fb86fe11
ES
141282011-08-02 Ed Schonberg <schonberg@adacore.com>
14129
14130 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
14131 Process_Bounds, to perform analysis with expansion of a range or an
14132 expression that is the iteration scheme for a loop.
14133 (Analyze_Iterator_Specification): If domain of iteration is given by a
14134 function call with a controlled result, as is the case if call returns
14135 a predefined container, ensure that finalization actions are properly
14136 generated.
14137 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
14138
62be5d0a
JM
141392011-08-02 Javier Miranda <miranda@adacore.com>
14140
14141 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
14142 * gcc-interface/Make-lang.in: Update dependencies.
14143
141442011-08-02 Javier Miranda <miranda@adacore.com>
14145
14146 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
14147 determine if the analysis is performed using N or Original_Node (N).
14148 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
14149 functionality of routine Is_Variable avoids code duplication.
14150 * checks.adb (Determine_Range): Handle temporaries generated by
14151 Remove_Side_Effects.
14152
141532011-08-02 Javier Miranda <miranda@adacore.com>
14154
14155 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
14156 expansion of the condition. Required since the previous analysis was
14157 done with expansion disabled (see Resolve_Quantified_Expression) and
14158 hence checks were not inserted and record comparisons have not been
14159 expanded.
14160
a20f4389
AC
141612011-08-02 Ed Falis <falis@adacore.com>
14162
14163 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
14164 Update header.
14165
141662011-08-02 Bob Duff <duff@adacore.com>
14167
14168 * opt.ads: Minor comment fix.
14169
141702011-08-02 Bob Duff <duff@adacore.com>
14171
14172 * sem_ch12.adb (Analyze_Package_Instantiation,
14173 Analyze_Subprogram_Instantiation): Turn off style checking while
14174 analyzing an instance. Whatever style checks that apply to the generic
14175 unit should apply, so it makes no sense to apply them in an instance.
14176 This was causing trouble when compiling an instance of a runtime
14177 unit that violates the -gnatyO switch.
14178 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
14179 one of the two case statements, causing spurious errors.
14180
141812011-08-02 Robert Dewar <dewar@adacore.com>
14182
14183 * uname.adb: Minor reformatting.
14184 * gnatcmd.adb: Minor reformatting.
14185 * exp_attr.adb: Minor reformatting.
14186
90878b12
AC
141872011-08-02 Ed Schonberg <schonberg@adacore.com>
14188
14189 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
14190 No_Dispatching_Calls, do not look for the Assign primitive, because
14191 predefined primitives are not created in this case.
14192
141932011-08-02 Bob Duff <duff@adacore.com>
14194
14195 * stylesw.ads: Minor comment fixes.
14196
141972011-08-02 Robert Dewar <dewar@adacore.com>
14198
14199 * freeze.adb (Add_To_Result): New procedure.
14200
142012011-08-02 Jose Ruiz <ruiz@adacore.com>
14202
14203 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
14204 time, if the specific run-time routines for handling streams of strings
14205 are not available, use the default mechanism.
14206
142072011-08-02 Arnaud Charlet <charlet@adacore.com>
14208
14209 * s-regpat.ads: Fix typo.
14210
142112011-08-02 Vincent Celier <celier@adacore.com>
14212
14213 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
14214 not null, call it to create the in memory config project file without
14215 parsing an existing default config project file.
14216
142172011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14218
14219 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
14220
142212011-08-02 Ed Schonberg <schonberg@adacore.com>
14222
14223 * sem_elim.adb: an abstract subprogram does not need an eliminate
14224 pragma for its descendant to be eliminable.
14225
142262011-08-02 Ed Falis <falis@adacore.com>
14227
14228 * init.c: revert to handling before previous checkin for VxWorks
14229 * s-intman-vxworks.adb: delete unnecessary declarations related to
14230 using Ada interrupt facilities for handling signals.
14231 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
14232 * s-intman-vxworks.ads: Import __gnat_install_handler as
14233 Initialize_Interrupts.
14234 * s-taprop-vxworks.adb: Delete Signal_Mask.
14235 (Abort_Handler): change construction of mask to unblock exception
14236 signals.
14237
273adcdf
AC
142382011-08-02 Jerome Guitton <guitton@adacore.com>
14239
14240 * a-except-2005.adb (Raise_From_Signal_Handler): Call
14241 Debug_Raise_Exception before propagation starts.
14242
142432011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14244
14245 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
14246 to Restriction_Check_Required.
14247 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
14248 * sem_res.adb (Resolve_Call): Likewise.
14249 * sem_attr.adb (Check_Stream_Attribute): Likewise.
14250
142512011-08-02 Bob Duff <duff@adacore.com>
14252
14253 * stylesw.ads: Update comment.
14254 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
14255 * errout.ads: Remove obsolete comment.
14256
142572011-08-02 Javier Miranda <miranda@adacore.com>
14258
14259 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
14260 (Set_Is_Safe_To_Reevaluate): new procedure.
14261 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
14262 assignment is allowed on safe-to-reevaluate variables.
14263 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
14264 temporary created to remove side effects in expressions that use
14265 the secondary stack as safe-to-reevaluate.
14266 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
14267 variables that are not true constants.
14268
6320f5e1
AC
142692011-08-02 Robert Dewar <dewar@adacore.com>
14270
14271 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
14272 sem_res.adb, sem_ch6.adb: Minor reformatting.
14273
142742011-08-02 Jerome Guitton <guitton@adacore.com>
14275
14276 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
14277
2fe829ae
ES
142782011-08-02 Ed Schonberg <schonberg@adacore.com>
14279
14280 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
14281 not set Overridden_Operation if subprogram is an initialization
14282 procedure.
14283
e24329cd
YM
142842011-08-02 Yannick Moy <moy@adacore.com>
14285
14286 * par-ch6.adb: Correct obsolete name in comments
14287 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
14288 which takes two message arguments (existing function takes one), with
14289 second message used for continuation.
14290 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
14291 block statements that originate from a source block statement, not
14292 generated block statements
14293 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
14294 symmetry with procedure case
14295 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
14296 function to issue an error in formal mode if a package specification
14297 contains more than one tagged type or type extension.
14298 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
14299 parameters matching formals of tagged types are objects (or ancestor
14300 type conversions of objects), not general expressions. Issue an error
14301 on view conversions that are not involving ancestor conversion of an
14302 extended type.
14303 (Resolve_Type_Conversion): in formal mode, issue an error on the
14304 operand of an ancestor type conversion which is not an object
14305 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
14306 procedure so that it works also for actuals of function calls
14307 (Is_Actual_Tagged_Parameter): new function which determines if its
14308 argument is an actual parameter of a formal of tagged type in a
14309 subprogram call
14310 (Is_SPARK_Object_Reference): new function which determines if the tree
14311 referenced by its argument represents an object in SPARK
14312
176dadf6
AC
143132011-08-02 Robert Dewar <dewar@adacore.com>
14314
14315 * sem_ch3.adb: Minor reformatting
14316 Minor comment addition
14317 Minor error msg text change
14318
143192011-08-02 Javier Miranda <miranda@adacore.com>
14320
14321 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
14322 function. Used to be more precise when we generate a variable plus one
14323 assignment to remove side effects in the evaluation of the Bound
14324 expressions.
14325 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
14326 of the bound expression to force its re-analysis and thus expand the
14327 associated transient scope (if required). Code cleanup replacing the
14328 previous code that declared the constant entity by an invocation to
14329 routine Force_Evaluation which centralizes this work in the frontend.
14330
d8b962d8
AC
143312011-08-02 Robert Dewar <dewar@adacore.com>
14332
14333 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
14334 (Base_Type): Now uses improved Is_Base_Type function
14335 * einfo.ads (Base_Type): Inline this function
14336
143372011-08-02 Robert Dewar <dewar@adacore.com>
14338
14339 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
14340 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
14341
143422011-08-02 Arnaud Charlet <charlet@adacore.com>
14343
14344 * gcc-interface/Make-lang.in: Update dependencies.
14345 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
14346 targets.
14347
143482011-08-02 Yannick Moy <moy@adacore.com>
14349
14350 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
14351 non-simple expression used in delta constraint
14352 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
14353 index constraint which is not a subtype mark
14354 * par.adb: With and use Restrict
14355 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
14356 mode on component type which is not a subtype mark and default
14357 expression on component
14358 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
14359 of string which does not have a lower index bound equal to 1
14360 (Array_Type_Declaration): issue an error in formal mode on index or
14361 component type which is not a subtype mark, and on aliased keyword on
14362 component
14363 (Derived_Type_Declaration): issue an error in formal mode on interface,
14364 limited or abstract type
14365 (Record_Type_Declaration): issue an error in formal mode on interface
14366 (Record_Type_Definition): issue an error in formal mode on tagged types
14367 and type extensions not declared in the specification of a library unit
14368 package; on null non-tagged record; on variant part
14369
143702011-08-02 Vincent Celier <celier@adacore.com>
14371
14372 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
14373 not declared for qualified library project when Library_Name is not
14374 declared, but Library_Dir is.
14375
143762011-08-02 Robert Dewar <dewar@adacore.com>
14377
14378 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
14379 pragmas (affects aspects [Component_]Default_Value
14380 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
14381 component type for the resolution
14382
f96b2d85
AC
143832011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14384
14385 * einfo.adb (Base_Type): Tune implementation for speed.
14386
143872011-08-02 Robert Dewar <dewar@adacore.com>
14388
14389 * freeze.adb: Minor reformatting.
14390
8b3c6430
AC
143912011-08-02 Thomas Quinot <quinot@adacore.com>
14392
14393 * scos.ads: Update comments.
14394
143952011-08-02 Ed Schonberg <schonberg@adacore.com>
14396
14397 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
14398 base type, because the parent may be a subtype of a private type whose
14399 convention is established in a private part.
14400
144012011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
14402
14403 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
14404 statement in a block when the expansion of the return expression has
14405 created a finalization chain.
14406 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
14407 with the parent node.
14408 Add N_Extended_Return_Statement to handle the case where a transient
14409 object declaration appears in the Return_Object_Declarations list of
14410 an extended return statement.
14411
144122011-08-02 Matthew Gingell <gingell@adacore.com>
14413
14414 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
14415 unused parameter 'name'.
14416
144172011-08-02 Ed Schonberg <schonberg@adacore.com>
14418
14419 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
14420 inherited operation, check whether its alias, which is the source
14421 operastion that it renames, has been marked eliminated.
14422
cae81f17
JM
144232011-08-02 Javier Miranda <miranda@adacore.com>
14424
14425 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
14426 in-mode parameter whose type is an access type since it can be used to
14427 modify its designated object. Enforce code that handles as safe an
14428 access type that is not access-to-constant but it is the result of a
14429 previous removal of side-effects.
14430 (Remove_Side_Effects): Minor code reorganization of cases which require
14431 no action. Done to incorporate documentation on new cases uncovered
14432 working in this ticket: no action needed if this routine was invoked
14433 too early and the nodes are not yet decorated.
14434 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
14435 to routine Remove_Side_Effects by calls to Force_Evaluation since they
14436 were issued with actuals that are implicitly provided by
14437 Force_Evaluation.
14438
218e6dee
RD
144392011-08-02 Robert Dewar <dewar@adacore.com>
14440
14441 * sem_ch3.adb, sem_res.adb: Minor reformatting.
14442
7a489a2b
AC
144432011-08-02 Yannick Moy <moy@adacore.com>
14444
14445 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
14446 to issue an error in formal mode on attribute not supported in this mode
14447 (Analyze_Attribute): issue errors on standard attributes not supported
14448 in formal mode.
14449 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
14450 comment, and issue error in formal mode on modulus which is not a power
14451 of 2.
14452 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
14453 range.
14454 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
14455 subtype mark.
14456 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
14457 operator on modular type (except 'not').
14458
144592011-08-02 Robert Dewar <dewar@adacore.com>
14460
14461 * gnat_rm.texi: Minor reformatting.
14462
cb7fa356
AC
144632011-08-02 Arnaud Charlet <charlet@adacore.com>
14464
14465 * s-osinte-linux.ads: Minor comment update and reformatting.
14466 * i-cexten.ads: Make this unit pure, as for its parent.
14467 Will allow its usage in more contexts if needed.
14468
144692011-08-02 Robert Dewar <dewar@adacore.com>
14470
14471 * s-utf_32.ads: Minor comment fix.
14472
144732011-08-02 Ed Schonberg <schonberg@adacore.com>
14474
14475 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
14476 operation of a tagged synchronized type, handle the case where the
14477 controlling argument is overloaded.
14478
144792011-08-02 Yannick Moy <moy@adacore.com>
14480
14481 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
14482 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
14483 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
14484 SPARK mode and formal verification mode on processing SPARK restriction
14485 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
14486 requiring consistency checking.
14487
5cc9353d
RD
144882011-08-02 Robert Dewar <dewar@adacore.com>
14489
14490 * sem_res.adb: Minor reformatting.
14491
e51537ff
RD
144922011-08-02 Robert Dewar <dewar@adacore.com>
14493
14494 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
14495 a-cforse.ads: Remove unneeded with of Ada.Containers
14496 Remove commented out pragma Inline's
14497 Move specifications of new subprograms to the actual specs
14498
83fa09c5
AC
144992011-08-02 Yannick Moy <moy@adacore.com>
14500
14501 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
14502 a-cforse.ads: Update comments.
14503
145042011-08-02 Ed Schonberg <schonberg@adacore.com>
14505
14506 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
14507
d11cfaf8
RD
145082011-08-02 Robert Dewar <dewar@adacore.com>
14509
14510 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
14511 a-cforse.ads, a-cofove.ads: Minor reformatting.
14512
300b98bb
AC
145132011-08-02 Claire Dross <dross@adacore.com>
14514
14515 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
14516 a-cofove.ads: Add comments.
14517
145182011-08-02 Yannick Moy <moy@adacore.com>
14519
14520 * gnat_rm.texi: Document formal containers.
14521
145222011-08-02 Emmanuel Briot <briot@adacore.com>
14523
14524 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
14525 are empty sections.
14526
19fb051c
AC
145272011-08-02 Robert Dewar <dewar@adacore.com>
14528
14529 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
14530 reformatting.
14531
145322011-08-02 Robert Dewar <dewar@adacore.com>
14533
14534 * aspects.adb: New aspects Default_Value and Default_Component_Value
14535 New format of Aspect_Names table checks for omitted entries
14536 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
14537 handling of boolean aspects for derived types.
14538 New aspects Default_Value and Default_Component_Value
14539 New format of Aspect_Names table checks for omitted entries
14540 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
14541 (Has_Default_Value): New flag
14542 (Has_Default_Component_Value): New flag
14543 (Has_Default_Value): New flag
14544 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
14545 table.
14546 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
14547 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
14548 Default_Value and Default_Component_Value
14549 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
14550 New aspects Default_Value and Default_Component_Value
14551 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
14552 * sprint.adb: Print N_Aspect_Specification node when called from gdb
14553
145542011-08-02 Vincent Celier <celier@adacore.com>
14555
14556 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
14557 inherit library kind.
14558
145592011-08-02 Ed Schonberg <schonberg@adacore.com>
14560
14561 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
14562 Minor reformatting.
14563
145642011-08-02 Robert Dewar <dewar@adacore.com>
14565
14566 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
14567
5f7747af
AC
145682011-08-02 Yannick Moy <moy@adacore.com>
14569
14570 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
14571
145722011-08-02 Robert Dewar <dewar@adacore.com>
14573
14574 * impunit.adb: Add comment.
14575
a5fe697b
AC
145762011-08-02 Yannick Moy <moy@adacore.com>
14577
14578 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
14579 qualification of aggregates in formal mode
14580 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
14581 another aggregate
14582 (Resolve_Aggregate): complete the test that an aggregate is adequately
14583 qualified in formal mode
14584
145852011-08-02 Pascal Obry <obry@adacore.com>
14586
14587 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
14588 * mlib-prj.adb: Supress warning when compiling binder generated file.
14589 (Build_Library): Supress all warnings when compiling the binder
14590 generated file.
14591
bd65a2d7 145922011-08-02 Yannick Moy <moy@adacore.com>
d4487611 14593
bd65a2d7
AC
14594 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
14595 from here...
14596 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
14597 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
14598 Add with/use clauses to make Check_Formal_Restriction visible
14599
146002011-08-02 Ed Schonberg <schonberg@adacore.com>
14601
14602 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
14603 in-parameters when type of the generic formal is private in the generic
14604 spec and non-private in the body.
14605
146062011-08-02 Claire Dross <dross@adacore.com>
14607
14608 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
14609 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
14610 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
14611 * impunit.adb, Makefile.rtl: Take new files into account.
d4487611
AC
14612
146132011-08-02 Robert Dewar <dewar@adacore.com>
14614
14615 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
14616 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
14617
bd434b3f
YM
146182011-08-02 Yannick Moy <moy@adacore.com>
14619
14620 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
14621 formal mode
14622 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
14623 matching static array bounds, taking into account the special case of
14624 string literals
14625 * sem_ch3.adb: Typo in comment.
14626
fe5d3068
YM
146272011-08-02 Yannick Moy <moy@adacore.com>
14628
14629 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
14630 which issues an error in formal mode if its argument node is originally
14631 from source
14632 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
14633 has a discriminant specification so that it does not include the case
14634 of derived types
14635 (Derived_Type_Declaration): move here the test that a derived type has a
14636 discriminant specification
14637 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
14638 first element of a component association before accessing its choices
14639 (presence of component association is not enough)
14640 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
14641 declaration is a library item before accessing the next element in a
14642 list, as library items are not member of lists
14643 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
14644 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
14645 Check_Formal_Restriction whenever possible.
14646
b60a3f26
AC
146472011-08-02 Ed Schonberg <schonberg@adacore.com>
14648
14649 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
14650 reference when needed.
14651
146522011-08-02 Bob Duff <duff@adacore.com>
14653
14654 * gnat_ugn.texi: Fix typo.
14655
146562011-08-02 Vincent Celier <celier@adacore.com>
14657
14658 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
14659 archive file name. Do not use the full path name of archives for Open
14660 VMS.
14661
eaba57fb
RD
146622011-08-02 Robert Dewar <dewar@adacore.com>
14663
14664 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
14665 Analyze_Aspect_Specifications
14666 * sem_ch13.adb
14667 (Analyze_Aspect_Specifications): New handling for boolean aspects
14668 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
14669 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
14670 sequence for Analyze_Aspect_Specifications
14671 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
14672 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
14673
146742011-08-02 Robert Dewar <dewar@adacore.com>
14675
14676 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
14677 aspects, since these no longer exist.
14678
146792011-08-02 Robert Dewar <dewar@adacore.com>
14680
14681 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
14682 semicolon, do not try to see if there are aspects following it.
14683 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
14684 aspect spec.
14685
8830d1d2
AC
146862011-08-02 Robert Dewar <dewar@adacore.com>
14687
14688 * sem_ch8.adb, aspects.ads: Minor reformatting.
14689
146902011-08-02 Eric Botcazou <ebotcazou@adacore.com>
14691
14692 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
14693 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
14694 extracted from...
14695 (Analyze_Aspect_Specifications): ...here. Call above procedure.
14696
7ff2d234
AC
146972011-08-02 Yannick Moy <moy@adacore.com>
14698
14699 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
14700 mode on subprogram declaration outside of package specification, unless
14701 it is followed by a pragma Import
14702 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
14703 Access_Type_Declaration): issue error in formal mode on access type
14704 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
14705 incomplete type
14706 (Analyze_Object_Declaration): issue error in formal mode on object
14707 declaration which does not respect SPARK restrictions
14708 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
14709 declaration which does not respect SPARK restrictions
14710 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
14711 error in formal mode on digits or delta constraint
14712 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
14713 decimal fixed point type
14714 (Derived_Type_Declaration): issue error in formal mode on derived type
14715 other than type extensions of tagged record types
14716 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
14717 with check on access definition
14718 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
14719 mode on protected definition.
14720 (Analyze_Task_Definition): issue error in formal mode on task definition
14721
147222011-08-02 Robert Dewar <dewar@adacore.com>
14723
14724 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
14725
806f6d37
AC
147262011-08-02 Javier Miranda <miranda@adacore.com>
14727
14728 * sem_ch6.adb (Can_Override_Operator): New function.
14729 (Verify_Overriding_Indicator): Add missing code to check overriding
14730 indicator in operators. Fixes regression.
14731 (Check_Overriding_Indicator): Minor reformating after replacing the
14732 code that evaluates if the subprogram can override an operator by
14733 invocations to the above new function.
14734 * einfo.adb
14735 (Write_Field26_Name): Add missing code to ensure that, following
14736 the documentation in einfo.ads, this field is not shown as attribute
14737 "Static_Initialization" on non-dispatching functions.
14738
147392011-08-02 Jose Ruiz <ruiz@adacore.com>
14740
14741 * sem_res.adb (Resolve_Call): A call to
14742 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
14743 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
14744 i.e., when the second parameter is of type Time_Span.
14745
147462011-08-02 Vincent Celier <celier@adacore.com>
14747
14748 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
14749 with an archive instead of -L<library dir> -l<library name>.
14750
147512011-08-02 Ed Schonberg <schonberg@adacore.com>
14752
14753 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
14754 mark the base types In_Use in addition to making the operations
14755 use_visible.
14756
147572011-08-02 Ed Falis <falis@adacore.com>
14758
14759 * init.c: add and setup __gnat_signal_mask for the exception signals
14760 * s-inmaop-vxworks.adb: new file.
14761 * s-intman-vxworks.adb: remove unnecessary initializations and
14762 simplify remaining
14763 * s-intman-vxworks.ads: remove unnecessary variable
14764 * s-taprop-vxworks.adb: simplify signal initialization
14765
780d052e
RD
147662011-08-02 Robert Dewar <dewar@adacore.com>
14767
14768 * sem_ch8.adb: Minor code reorganization, comment updates.
14769
147702011-08-02 Robert Dewar <dewar@adacore.com>
14771
14772 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
14773 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
14774 here from Sem_Res.
14775 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
14776 (Matching_Static_Array_Bounds): Moved here from Sem_Res
14777
29efbb8c
ES
147782011-08-02 Ed Schonberg <schonberg@adacore.com>
14779
14780 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
14781 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
14782 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
14783 use_type_clauses, to handle more efficiently use_type and use_all_type
14784 constructs.
14785 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
14786 Ada2012 Use_All_Type clause.
14787 (Use_Class_Wide_Operations): new procedure.
14788
b0186f71
AC
147892011-08-02 Robert Dewar <dewar@adacore.com>
14790
14791 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
14792 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
14793 expression to expression function.
14794
147952011-08-02 Ed Schonberg <schonberg@adacore.com>
14796
14797 * sem_ch4.adb: transform simple Ada2012 membership into equality only
14798 if types are compatible.
14799
148002011-08-02 Yannick Moy <moy@adacore.com>
14801
14802 * sem_res.adb (Matching_Static_Array_Bounds): new function which
14803 returns True if its argument array types have same dimension and same
14804 static bounds at each index.
14805 (Resolve_Actuals): issue an error in formal mode on actuals passed as
14806 OUT or IN OUT paramaters which are not view conversions in SPARK.
14807 (Resolve_Arithmetic_Op): issue an error in formal mode on
14808 multiplication or division with operands of fixed point types which are
14809 not qualified or explicitly converted.
14810 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
14811 Boolean or array type (except String) operands.
14812 (Resolve_Equality_Op): issue an error in formal mode on equality
14813 operators for array types other than String with non-matching static
14814 bounds.
14815 (Resolve_Logical_Op): issue an error in formal mode on logical operators
14816 for array types with non-matching static bounds. Factorize the code in
14817 Matching_Static_Array_Bounds.
14818 (Resolve_Qualified_Expression): issue an error in formal mode on
14819 qualified expressions for array types with non-matching static bounds.
14820 (Resolve_Type_Conversion): issue an error in formal mode on type
14821 conversion for array types with non-matching static bounds
14822
767bb4e8
AC
148232011-08-02 Robert Dewar <dewar@adacore.com>
14824
14825 * par-ch10.adb: Minor code reorganization (use Nkind_In).
14826
148272011-08-02 Ed Schonberg <schonberg@adacore.com>
14828
14829 * par-ch9.adb: save location of entry for proper error message.
14830
4ac2477e
JM
148312011-08-02 Javier Miranda <miranda@adacore.com>
14832
14833 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
14834 (Use_Full_View) which permits this routine to climb through the
14835 ancestors using the full-view of private parents.
14836 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
14837 Use_Full_View to true in calls to Is_Ancestor.
14838 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
14839 true in call to Is_Ancestor.
14840 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
14841 Use_Full_View to true in call to Is_Ancestor.
14842 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
14843 call to Is_Ancestor.
14844 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
14845 Use_Full_View to true in calls to Is_Ancestor.
14846 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
14847 Make_Select_Specific_Data_Table, Register_Primitive,
14848 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
14849 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
14850 to true in call to Is_Ancestor.
14851 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
14852 Use_Full_View to true in calls to Is_Ancestor.
14853 * exp_cg.adb
14854 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
14855 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
14856
9f90d123
AC
148572011-08-02 Robert Dewar <dewar@adacore.com>
14858
14859 * gnat_rm.texi: Minor reformatting.
14860 * sem_prag.adb: Minor reformatting.
14861
148622011-08-02 Tristan Gingold <gingold@adacore.com>
14863
14864 * vms_data.ads: Add VMS qualifier for -gnateP.
14865
148662011-08-02 Robert Dewar <dewar@adacore.com>
14867
14868 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
14869 * par-ch7.adb (P_Package): Proper placement of aspects for package
14870 decl/instantiation.
14871 * par-endh.adb (Check_End): Ad Is_Sloc parameter
14872 (End_Statements): Add Is_Sloc parameterr
14873 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
14874 (Check_End): Ad Is_Sloc parameter
14875 (End_Statements): Add Is_Sloc parameterr
14876
148772011-08-02 Vincent Celier <celier@adacore.com>
14878
14879 * ug_words: Add VMS qualifier equivalent to -gnateP:
14880 /SYMBOL_PREPROCESSING.
14881
148822011-08-02 Jose Ruiz <ruiz@adacore.com>
14883
14884 * gnat-style.texi: For hexadecimal numeric literals the typical
14885 grouping of digits is 4 to represent 2 bytes.
14886 A procedure spec which is split into several lines is indented two
14887 characters.
14888
148892011-08-02 Yannick Moy <moy@adacore.com>
14890
14891 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
14892 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
14893 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
14894 properly qualified
14895 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
14896 choice in array aggregate
14897 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
14898 mark as ancestor
14899 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
14900 positional and named aggregate for record, or others in record
14901 aggregate, or multiple choice in record aggregate
14902 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
14903 array operands to logical operations AND, OR and XOR do not have the
14904 same static lower and higher bounds
14905 * sem_ch5.adb, sinfo.ads: Correct typos in comments
14906
2933b16c
RD
149072011-08-01 Robert Dewar <dewar@adacore.com>
14908
14909 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
14910 Replaces Last_Source_Node_In_Sequence.
14911 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
14912 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
14913 parens and blank in string (this was inconsistently implemented).
14914 * errout.ads
14915 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
14916 blank in string (this was inconsistently implemented).
14917 * gnat1drv.adb
14918 (Set_Global_Switches): Set formal mode switches appropriately
14919 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
14920 * par-prag.adb
14921 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
14922 call Set_Error_Msg_Lang to set "spark" as language name.
14923 * par.adb: Remove unnecessary call to set formal language for errout
14924 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
14925 appropriately and call Set_Error_Msg_Lang to set "spark" as language
14926 name.
14927 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
14928 calls to it, moved after resolution so that types are known
14929 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
14930 result of concatenation is not of type String
14931 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
14932 concatenation is not properly restricted
14933 * gnat_rm.texi: Add doc on pragma Spark_95.
14934 * gcc-interface/Makefile.in: Remove obsolete target pairs for
14935 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
14936 * gcc-interface/Make-lang.in: Update dependencies.
14937
05dbd302
AC
149382011-08-01 Javier Miranda <miranda@adacore.com>
14939
14940 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
14941 condition that detects if the overridden operation must replace an
14942 existing entity.
14943
149442011-08-01 Javier Miranda <miranda@adacore.com>
14945
14946 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
14947 code declarations inserted by Insert_Actions in each alternative of the
14948 N_Case_Expression node.
14949
149502011-08-01 Robert Dewar <dewar@adacore.com>
14951
14952 * sem_ch6.adb: Minor code reorganization.
14953 * sem_util.adb: Minor reformatting.
14954
af9e051f
PO
149552011-08-01 Pascal Obry <obry@adacore.com>
14956
14957 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
14958 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
14959
1d801f21
AC
149602011-08-01 Yannick Moy <moy@adacore.com>
14961
14962 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
14963 literal or operator symbol which is prefixed
14964 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
14965 mode on access attributes.
14966 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
14967 that concatenation operands are properly restricted in formal mode
14968 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
14969 Analyze_Concatenation_Operand. Issue an error in formal mode if the
14970 result of the concatenation has a type different from String.
14971 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
14972 Analyze_Quantified_Expression, Analyze_Slice,
14973 Analyze_Null): issue an error in formal mode on unsupported constructs
14974 * sem_ch5.adb
14975 (Analyze_Block_Statement): only issue error on source block statement
14976 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
14977 function which returns the last node in a list of nodes for which
14978 Comes_From_Source returns True, if any
14979 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
14980 Last_Source_Node_In_Sequence
14981 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
14982 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
14983 mode on unsupported constructs
14984 * sem_ch9.adb Do not return after issuing error in formal mode, as the
14985 rest of the actions may be needed later on since the error is marked as
14986 not serious.
14987 * sinfo.ads: Typos in comments.
14988
149892011-08-01 Pascal Obry <obry@adacore.com>
14990
14991 * projects.texi: Minor editing.
14992
53beff22
YM
149932011-08-01 Yannick Moy <moy@adacore.com>
14994
14995 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
14996 insertion character ~~
14997 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
14998 (Set_Error_Msg_Lang): new procedure which fixes the language for use
14999 with insertion character ~~
15000 (Set_Msg_Text): treat insertion character ~~
15001 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
15002 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
15003 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
15004 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
15005 errors related to the formal language restriction not serious
15006 (insertion character |).
15007 * par.adb (Par): set formal language for error messages if needed
15008 * sem_ch6.adb (Check_Missing_Return): take into account possible
15009 generated statements at the end of the function
15010 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
15011 enumeration value to define a new pragma SPARK_95
15012 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
15013 SPARK_Version): new type and variables to store the SPARK version
15014 (none by default).
15015 (SPARK_Mode): return True when SPARK_Version is set
15016 * par-prag.adb: Correct indentation
15017 (Prag): take Pragma_SPARK_95 into account
15018 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
15019 into account.
15020
8d606a78
RD
150212011-08-01 Robert Dewar <dewar@adacore.com>
15022
15023 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
15024 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
15025 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
15026
1982d5a8
PO
150272011-08-01 Pascal Obry <obry@adacore.com>
15028
15029 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
15030 Target_Name to Get_Path call.
15031 (Parse_Single_Project): Likewise.
15032 (Post_Parse_Context_Clause): Likewise.
15033 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
15034 Call Initialise_Project_Path with the proper Target_Name.
15035 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
15036 search path.
15037 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
15038 with the proper Target_Name.
15039 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
15040 Part.Parse routine.
15041 (Parse_Project_And_Apply_Config): Likewise.
15042 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
15043 This is fine as this part of the code is supporting only native
15044 compilation.
15045 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
15046 is fine as this part of the code is supporting only native compilation.
15047
0d53d36b
AC
150482011-08-01 Yannick Moy <moy@adacore.com>
15049
15050 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
15051 of homonym, unless the homonym is one of the cases allowed in SPARK
15052 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
15053 package declaration occurring after a body.
15054
150552011-08-01 Robert Dewar <dewar@adacore.com>
15056
15057 * checks.adb, exp_ch4.adb: Minor reformatting.
15058
150592011-08-01 Javier Miranda <miranda@adacore.com>
15060
15061 * einfo.ads (Access_Disp_Table): Fix documentation.
15062 (Dispatch_Table_Wrappers): Fix documentation.
15063
150642011-08-01 Pascal Obry <obry@adacore.com>
15065
15066 * prj-env.adb, prj-env.ads: Minor reformatting.
15067
8ed68165
AC
150682011-08-01 Yannick Moy <moy@adacore.com>
15069
15070 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
15071 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
15072 procedures out of these packages.
2c7f9cc0 15073 * errout.ads, errout.adb
8ed68165
AC
15074 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
15075 procedures in of this package
15076 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
15077 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
15078 on misplaced later vs initial declarations, like in Ada 83
15079 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
15080 formal mode on attribute of private type whose full type declaration
15081 is not visible
15082 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
15083 package declaration inside a package specification
15084 (Analyze_Full_Type_Declaration): issue error in formal mode on
15085 controlled type or discriminant type
15086 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
15087 user-defined operator means that it should come from the source
15088 (New_Overloaded_Entity): issue error in formal mode on overloaded
15089 entity.
15090 * sem_ch6.ads, sem_ch13.ads: typos in comments.
15091
150922011-08-01 Thomas Quinot <quinot@adacore.com>
15093
15094 * atree.adb: Minor reformatting.
15095 * checks.adb: Minor reformatting.
15096
4230bdb7
AC
150972011-08-01 Vincent Celier <celier@adacore.com>
15098
15099 * s-parame-vms-ia64.ads: Fix typo in comment
15100 Minor reformatting
15101 * s-parame-vms-restrict.ads: Removed, unused.
15102
151032011-08-01 Javier Miranda <miranda@adacore.com>
15104
15105 * exp_ch3.adb
15106 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
15107 * sem_ch3.adb
15108 (Constrain_Index): Remove side effects in the evaluation of the bounds.
15109 * sem_ch3.ads, sem_ch3.adb
15110 (Is_Constant_Bound): New extended version of the subprogram that was
15111 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
15112 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
15113 * sem_aux.ads (Constant_Value): Fix typo in comment.
15114 * checks.adb (Generate_Index_Checks): New implementation which, for
15115 array objects with constant bounds, generates the runtime check
15116 referencing the bounds of the array type. For other cases this routine
15117 provides its previous behavior obtaining such values from the array
15118 object.
15119 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
15120 parent type.
15121 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
15122 we cannot have semantic interpretations of the new node.
15123
2010d078
AC
151242011-08-01 Ed Schonberg <schonberg@adacore.com>
15125
15126 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
15127 expressions.
15128
151292011-08-01 Arnaud Charlet <charlet@adacore.com>
15130
15131 * sem_ch8.adb: Minor code editing.
15132 * s-vxwext.adb: Remove trailing space.
15133 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
15134 consistency with other files.
15135
151362011-08-01 Thomas Quinot <quinot@adacore.com>
15137
15138 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
15139
151402011-08-01 Ed Schonberg <schonberg@adacore.com>
15141
15142 * par-ch10.adb: reject parameterized expressions as compilation unit.
15143 * sem_ch4.adb: handle properly conditional expression with overloaded
15144 then_clause and no else_clause.
15145
151462011-08-01 Tristan Gingold <gingold@adacore.com>
15147
15148 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
15149 like done by System.Aux_DEC.
15150 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
15151
daec8eeb
YM
151522011-08-01 Yannick Moy <moy@adacore.com>
15153
15154 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
15155 missing label at end of declaration (subprogram or package)
15156 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
15157 of positional and named parameter association
15158 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
15159 Error_Msg_SP which adds a prefix to the error message giving the name
15160 of the formal language analyzed
15161 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
15162 access result type in subprogram, unconstrained array as result type,.
15163 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
15164 procedure
15165 * sem_ch8.adb: Code clean up.
15166
38171f43
AC
151672011-08-01 Javier Miranda <miranda@adacore.com>
15168
15169 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
15170 * einfo.ads (Access_Disp_Table): Fix documentation.
15171 (Dispatch_Table_Wrappers): Fix documentation.
15172 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
15173 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
15174 to enforce the documentation of this attribute.
15175 (Set_Is_Interface): Cleanup the assertion.
15176 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
15177 the Underlying_Type entity before reading attribute Access_Disp_Table.
15178 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
15179 Locate the Underlying_Type before reading attribute Access_Disp_Table.
15180 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
15181 the Underlying_Type entity before reading attribute Access_Disp_Table.
15182 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
15183 Locate the Underlying_Type entity before reading attribute
15184 Access_Disp_Table.
15185
151862011-08-01 Ed Schonberg <schonberg@adacore.com>
15187
15188 * s-poosiz.ads: Additional overriding indicators.
15189
151902011-08-01 Yannick Moy <moy@adacore.com>
15191
15192 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
15193 formal mode.
15194 (Analyze_Iteration_Scheme): issue error in formal mode when loop
15195 parameter specification does not include a subtype mark.
15196 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
15197 formal mode on abstract subprogram.
15198 (Analyze_Subprogram_Specification): issue error in formal mode on
15199 user-defined operator.
15200 (Process_Formals): issue error in formal mode on access parameter and
15201 default expression.
15202 * sem_ch9.adb (Analyze_Abort_Statement,
15203 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
15204 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
15205 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
15206 Analyze_Requeue, Analyze_Selective_Accept,
15207 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
15208 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
15209 issue error in formal mode on user-defined raise statement.
15210
1f250383
AC
152112011-08-01 Thomas Quinot <quinot@adacore.com>
15212
15213 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
15214 declaration being hidden when overriding an implicit inherited
15215 subprogram.
15216 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
15217 (-gnats), do not complain about a source file that contains only a
15218 pragma No_Body.
15219
152202011-08-01 Ed Schonberg <schonberg@adacore.com>
15221
15222 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
15223 variable if already set.
15224
607d0635
AC
152252011-08-01 Arnaud Charlet <charlet@adacore.com>
15226
15227 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
15228 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
15229 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
15230 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
15231 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
15232 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
15233 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
15234 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
15235 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
15236 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
15237 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
15238 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
15239 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
15240 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
15241 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
15242 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
15243 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
15244 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
15245 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
15246 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
15247 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
15248 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
15249 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
15250 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
15251 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
15252 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
15253 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
15254 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
15255 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
15256 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
15257 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
15258 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
15259 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
15260 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
15261 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
15262 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
15263 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
15264 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
15265 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
15266 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
15267 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
15268 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
15269 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
15270 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
15271 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
15272 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
15273 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
15274 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
15275 s-osinte-mingw.ads: Update to GPLv3 run-time license.
15276 Use GNAT instead of GNARL.
15277
152782011-08-01 Bob Duff <duff@adacore.com>
15279
15280 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
15281 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
15282 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
15283 reformatting.
15284
152852011-08-01 Yannick Moy <moy@adacore.com>
15286
15287 * debug.adb (d.D) reverve flag for the SPARK mode
15288 (d.E) reverve flag for SPARK generation mode
15289 (d.F) reverve flag for Why generation mode
2c7f9cc0 15290 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
607d0635
AC
15291 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
15292 functions which return True when the corresponding modes are set
15293 (Formal_Language): return "spark" or "alfa" when in formal verification
15294 mode.
15295 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
15296 Error_Msg to prefix the error message with a tag giving the formal
15297 language
15298 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
15299 message with a tag giving the formal language
15300 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
15301 block statement
15302 (Analyze_Case_Statement): issue error in formal mode on case statement
15303 with a single "others" case alternative
15304 (Analyze_Exit_Statement): issue errors in formal mode on exit
15305 statements which do not respect SPARK restrictions
15306 (Analyze_Goto_Statement): issue error in formal mode on goto statement
15307 (Check_Unreachable_Code): always issue an error (not a warning) in
15308 formal mode on unreachable code (concerns both code after an infinite
15309 loop and after an unconditional jump, both not allowed in SPARK)
15310 * sem_ch6.adb (Analyze_Return_Statement): add call to
15311 Set_Return_Present for a procedure containing a return statement
15312 (already done for functions in Analyze_Function_Return)
15313 (Analyze_Function_Return): issue error in formal mode on extended
15314 return or if return is not last statement in function
15315 (Check_Missing_Return): issue error in formal mode if function does
15316 not end with return or if procedure contains a return
15317 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
15318 function to detect if there is an inner scope of its parameter S which
15319 is a loop.
15320
153212011-08-01 Thomas Quinot <quinot@adacore.com>
15322
15323 * sem_ch6.ads: Minor reformatting.
15324
d8b3ccb9
AC
153252011-08-01 Javier Miranda <miranda@adacore.com>
15326
15327 * sem_util.adb (Abstract_Interface_List): Complete condition when
15328 processing private type declarations to avoid reading unavailable
15329 attribute.
15330 (Is_Synchronized_Tagged_Type): Complete condition when processing
15331 private extension declaration nodes to avoid reading unavailable
15332 attribute.
15333
153342011-08-01 Thomas Quinot <quinot@adacore.com>
15335
15336 * sem_ch3.adb: Minor reformatting.
15337
153382011-08-01 Thomas Quinot <quinot@adacore.com>
15339
15340 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
15341 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
15342 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
15343 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
15344 for VMS, instead parametrize the common implementation with
15345 System.Parameters declarations.
15346
0bb9276c
AC
153472011-08-01 Eric Botcazou <ebotcazou@adacore.com>
15348
15349 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
15350
153512011-08-01 Tristan Gingold <gingold@adacore.com>
15352
15353 * seh_init.c: Fix SEH handler installation on win64.
15354
153552011-08-01 Ed Schonberg <schonberg@adacore.com>
15356
15357 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
15358 double analysis of an anonymous access to subprogram, because it can
15359 lead to improper sharing of profiles and a back-end crash.
15360
6a2e4f0b
AC
153612011-08-01 Robert Dewar <dewar@adacore.com>
15362
15363 * make.adb, sem_ch4.adb: Minor reformatting.
15364 * gcc-interface/Make-lang.in: Update dependencies.
15365 * sem_util.adb, exp_ch5.adb: Minor reformatting.
15366
153672011-08-01 Arnaud Charlet <charlet@adacore.com>
15368
15369 * gnat_rm.texi: Fix definition of Long_Integer.
15370
153712011-08-01 Ed Schonberg <schonberg@adacore.com>
15372
15373 * exp_aggr.adb: check limit size of static aggregate unconditionally,
15374 to prevent storage exhaustion.
15375 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
15376 finalized is a function body, insert the cleanup code before the final
15377 return statement, to prevent spurious warnings.
15378 * s-pooglo.ads: add overriding indicator.
15379
4561baf7
ES
153802011-08-01 Ed Schonberg <schonberg@adacore.com>
15381
15382 * sem_ch4.adb (Operator_Check): improve error message when both a
15383 with_clause and a use_clause are needed to make operator usage legal.
15384 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
15385 determine whether a compilation unit is visible within an other,
15386 either through a with_clause in the current unit, or a with_clause in
15387 its library unit or one one of its parents.
15388
383e179e
AC
153892011-08-01 Ed Schonberg <schonberg@adacore.com>
15390
15391 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
15392 over an arbitrary expression of an array or container type.
15393 * lib-xref.adb: clarify comment.
15394
153952011-08-01 Bob Duff <duff@adacore.com>
15396
15397 * einfo.ads: Minor reformatting.
15398 * debug.adb: Minor comment improvement.
15399
154002011-08-01 Javier Miranda <miranda@adacore.com>
15401
15402 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
15403 consider hidden subprograms as valid candidates.
15404
154052011-08-01 Arnaud Charlet <charlet@adacore.com>
15406
15407 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
15408
154092011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
15410
15411 * gnat_ugn.texi: Fix typo.
15412
61c161b2
AC
154132011-08-01 Robert Dewar <dewar@adacore.com>
15414
15415 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
15416 lib-xref.adb: Minor reformatting
15417
154182011-08-01 Gary Dismukes <dismukes@adacore.com>
15419
15420 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
15421 when to generate a call to Move_Final_List.
15422 (Has_Controlled_Parts): Remove this function.
15423
84df40f7
AC
154242011-08-01 Geert Bosch <bosch@adacore.com>
15425
15426 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
15427 "," in choice list.
15428
154292011-08-01 Thomas Quinot <quinot@adacore.com>
15430
15431 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
15432 explicit raise of a predefined exception as Comes_From_Source if the
15433 original N_Raise_Statement comes from source.
15434
154352011-08-01 Robert Dewar <dewar@adacore.com>
15436
15437 * sinfo.ads: Add comment.
15438 * sem_ch6.adb: Minor reformatting.
15439
154402011-08-01 Robert Dewar <dewar@adacore.com>
15441
15442 * freeze.adb (Freeze_Entity): Refine check for bad component size
15443 clause to avoid rejecting confirming clause when atomic/aliased present.
15444
154452011-08-01 Ed Schonberg <schonberg@adacore.com>
15446
15447 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
15448 better determine whether an entity reference is a write.
15449 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
15450 subcomponent.
15451 * lib-xref.adb (Output_References): Do no suppress a read reference at
15452 the same location as an immediately preceeding modify-reference, to
15453 handle properly in-out actuals.
15454
154552011-08-01 Tristan Gingold <gingold@adacore.com>
15456
15457 * env.c (__gnat_setenv) [VMS]: Refine previous change.
15458
154592011-08-01 Quentin Ochem <ochem@adacore.com>
15460
15461 * i-cstrin.adb (New_String): Changed implementation, now uses only the
15462 heap to compute the result.
15463
c7f0d2c0
AC
154642011-08-01 Robert Dewar <dewar@adacore.com>
15465
15466 * atree.ads: Minor reformatting.
15467
154682011-08-01 Emmanuel Briot <briot@adacore.com>
15469
15470 * g-expect.adb (Get_Command_Output): Fix memory leak.
15471
154722011-08-01 Geert Bosch <bosch@adacore.com>
15473
15474 * cstand.adb (P_Float_Type): New procedure to print the definition of
15475 predefined fpt types.
15476 (P_Mixed_Name): New procedure to print a name using mixed case
15477 (Print_Standard): Use P_Float_Type for printing floating point types
15478 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
15479 precision IEEE float.
15480
154812011-08-01 Thomas Quinot <quinot@adacore.com>
15482
15483 * sem_ch3.adb: Minor reformatting.
15484
154852011-08-01 Ed Schonberg <schonberg@adacore.com>
15486
15487 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
15488 the completion of a generic function, insert the new body rather than
15489 rewriting the original.
15490
154912011-08-01 Yannick Moy <moy@adacore.com>
15492
15493 * sinfo.ads, errout.ads: Typos in comments.
15494
1c54829e
AC
154952011-08-01 Robert Dewar <dewar@adacore.com>
15496
15497 * par-endh.adb: Minor reformatting.
15498
154992011-08-01 Robert Dewar <dewar@adacore.com>
15500
15501 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
15502 (Pre_Post_Aspects): New subtype.
15503 * par-ch12.adb (P_Generic): New syntax for aspects in packages
15504 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
15505 * par-ch7.adb (P_Package): Remove Decl parameter
15506 (P_Package): Handle new syntax for aspects (before IS)
15507 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
15508 new aspect syntax
15509 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
15510 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
15511 (P_Package): Remove Decl parameter
15512 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
15513 aspects
15514 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
15515 specs
15516 * sem_util.ads, sem_util.adb (Static_Boolean): New function
15517 * sinfo.ads: Document new syntax for aspects in packages etc.
15518 * sprint.adb: Handle new syntax of aspects before IS in package
15519
155202011-08-01 Thomas Quinot <quinot@adacore.com>
15521
15522 * atree.ads: Minor reformatting.
15523 * sem_prag.adb: Minor reformatting.
15524
155252011-08-01 Robert Dewar <dewar@adacore.com>
15526
15527 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
15528 case expr alternative.
15529
155302011-08-01 Ed Schonberg <schonberg@adacore.com>
15531
15532 * sem_ch12.adb: Fix typo.
15533
9eea4346
GB
155342011-08-01 Geert Bosch <bosch@adacore.com>
15535
15536 * sem_prag.adb (Check_No_Link_Name): New procedure.
15537 (Process_Import_Or_Interface): Use Check_No_Link_Name.
15538 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
15539 instead of Standard_Long_Long_Float_Size global. Preparation for
15540 eventual removal of per type constants.
15541 * exp_util.ads (Get_Stream_Size): New function returning the stream
15542 size value of subtype E.
15543 * exp_util.adb (Get_Stream_Size): Implement new function.
15544 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
15545 function.
15546 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
15547 * einfo.adb:
15548 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
15549
3d6c3bd7
GB
155502011-08-01 Geert Bosch <bosch@adacore.com>
15551
15552 * cstand.adb: Fix comments.
15553 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
15554 count of arguments.
15555
e7d897b8
AC
155562011-08-01 Robert Dewar <dewar@adacore.com>
15557
15558 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
15559
155602011-08-01 Geert Bosch <bosch@adacore.com>
15561
15562 * atree.ads: Fix comment.
15563
c228a069
AC
155642011-08-01 Robert Dewar <dewar@adacore.com>
15565
15566 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
15567 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
15568 * par.adb: Add with for Namet.Sp.
15569 * par-tchk.adb: Minor reformatting.
15570
155712011-08-01 Vincent Celier <celier@adacore.com>
15572
15573 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
15574 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
15575 of the init procedure of a SAL.
15576 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
15577 New procedure.
15578
155792011-08-01 Thomas Quinot <quinot@adacore.com>
15580
15581 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
15582 reformatting.
15583
155842011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
15585
15586 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
15587
155882011-08-01 Thomas Quinot <quinot@adacore.com>
15589
15590 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
15591 conformant with its spec (return True only for types that have
15592 an overriding Initialize primitive operation that prevents them from
15593 having preelaborable initialization).
15594 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
15595 initialization for controlled types in Ada 2005 or later mode.
15596
857ade1b
RD
155972011-08-01 Robert Dewar <dewar@adacore.com>
15598
15599 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
15600 Postcondition.
15601 (Same_Aspect): New function.
15602 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
15603 Type_Invariant, Precondition, Postcondition.
15604 * snames.ads-tmpl: Add Name_Type_Invariant.
15605
bd949ee2
RD
156062011-08-01 Robert Dewar <dewar@adacore.com>
15607
15608 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
15609 here.
15610 (Freeze_All_Ent): Fix error in handling inherited aspects.
15611 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
15612 already analyzed, but don't skip entire processing of a declaration,
15613 that's wrong in some cases of declarations being rewritten.
15614 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
15615 Don't delay for integer, string literals
15616 Treat predicates in usual manner for delay, remove special case code,
15617 not needed.
15618 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
15619 (Build_Predicate_Function): Update saved expression in aspect
15620 (Build_Invariant_Procedure): Update saved expression in aspect
15621 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
15622 of replacement of discriminant references if the reference is simple.
15623
f1c952af
RD
156242011-08-01 Robert Dewar <dewar@adacore.com>
15625
15626 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
15627 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
15628 Static_Predicate and Dynamic_Predicate.
15629 (Build_Predicate_Function): Add processing for Static_Predicate
15630 and Dynamic_Predicate.
15631 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
15632 (From_Static_Predicate): New flag
15633 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
15634
156352011-08-01 Robert Dewar <dewar@adacore.com>
15636
15637 * usage.adb: Documentation cleanup for Ada version modes in usage.
15638 * expander.adb: Minor reformatting.
15639
47e11d08
AC
156402011-08-01 Robert Dewar <dewar@adacore.com>
15641
15642 * atree.ads: Minor comment fix.
15643 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
15644 a-witeio.ads, sem_prag.adb: Minor reformatting.
15645
156462011-08-01 Doug Rupp <rupp@adacore.com>
15647
15648 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
15649 pointers. Use descrip.h header file for convenience. Add some
15650 comments.
15651
156522011-08-01 Robert Dewar <dewar@adacore.com>
15653
15654 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
15655 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
15656 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
15657 New procedure.
15658 (Check_Aspect_At_End_Of_Declarations): New procedure
15659 (Analye_Aspect_Specification): Minor changes for above procedures
15660 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
15661 specification node as well.
15662
156632011-08-01 Pascal Obry <obry@adacore.com>
15664
15665 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
15666 Windows files. Use GetFilesAttributes() in this case to check for file
15667 existence instead of returning with an error code.
15668
a3a16b21
VC
156692011-08-01 Vincent Celier <celier@adacore.com>
15670
15671 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
15672 High is above Source length.
15673
ff58cc69
RD
156742011-08-01 Robert Dewar <dewar@adacore.com>
15675
15676 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
15677
6bb88533
AC
156782011-08-01 Robert Dewar <dewar@adacore.com>
15679
15680 * aspects.ads (Boolean_Aspects): New subtype.
15681 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
15682 for derived types in cases where the parent type and derived type have
15683 aspects.
15684 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
15685 with aspects when parent type also has aspects.
15686 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
15687 boolean expression at this point).
15688 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
15689 accordance with final decision on the Ada 2012 feature.
15690 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
15691
156922011-08-01 Matthew Heaney <heaney@adacore.com>
15693
15694 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
15695
060a3f28
AC
156962011-08-01 Pascal Obry <obry@adacore.com>
15697
15698 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
15699 Fix Replace_Slice when High is above current string size.
15700 (Replace_Slice): Fix DL computation when High is above current
15701 string length.
15702
157032011-08-01 Gary Dismukes <dismukes@adacore.com>
15704
15705 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
15706
e7f567a3
AC
157072011-08-01 Matthew Heaney <heaney@adacore.com>
15708
15709 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
15710 of node.
15711
157122011-08-01 Pascal Obry <obry@adacore.com>
15713
15714 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
15715 reformatting.
15716
1a265e78
AC
157172011-08-01 Ed Schonberg <schonberg@adacore.com>
15718
15719 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
15720 access to protected subprograms in generic bodies.
15721 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
15722 protected type, indicate that the convention of the subprogram is
15723 Convention_Protected, because it may be used in subsequent declarations
15724 within the protected declaration.
15725
157262011-08-01 Vincent Celier <celier@adacore.com>
15727
15728 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
15729 and "final" procedures when the name of the library is "ada", to avoid
15730 duplicate symbols "adainit" and "adafinal" in executables.
15731
67e28ef8
ES
157322011-08-01 Ed Schonberg <schonberg@adacore.com>
15733
15734 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
15735 quantified expression that appears within a postcondition and uses the
15736 Ada2012 'Result attribute.
15737
6da2ca7d
RO
157382011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15739
15740 * init.c (__gnat_error_handler): Cast reason to int.
15741 (__gnat_install_handler): Explain sa_sigaction use.
15742
7d5997c6
EB
157432011-07-24 Eric Botcazou <ebotcazou@adacore.com>
15744
15745 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
15746 subprogram has copy-in copy-out parameters, try to promote the mode of
15747 the return type if it is passed in registers.
15748
4b4cfdd5
EB
157492011-07-24 Eric Botcazou <ebotcazou@adacore.com>
15750
15751 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
15752 left operand as addressable.
15753
f3d34576
EB
157542011-07-24 Eric Botcazou <ebotcazou@adacore.com>
15755
15756 * gcc-interface/gigi.h (build_function_stub): Remove.
15757 (build_return_expr): Likewise.
15758 (convert_vms_descriptor): Declare.
15759 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
15760 (build_function_stub): Move to...
15761 * gcc-interface/utils2.c (build_return_expr): Move to...
15762 * gcc-interface/trans.c (build_function_stub): ...here.
15763 (build_return_expr): ...here.
15764 (Subprogram_Body_to_gnu): Add local variable for language_function.
15765 Disconnect the parameter attributes cache, if any, once done with it.
15766 Call end_subprog_body only after setting the end_locus.
15767 Build the stub associated with the function, if any, at the very end.
15768 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
15769 variables and streamline control flow.
15770
0a6ecc08
AC
157712011-07-23 Arnaud Charlet <charlet@adacore.com>
15772
15773 PR ada/49819
15774 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
15775 g-trasym-dwarf.adb.
15776
5b6d595b
RO
157772011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15778
15779 PR bootstrap/49794
15780 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
15781 Assign to act.sa_sigaction.
15782 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
15783 current->return_address to char * before arithmetic.
15784
94017021
RO
157852011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15786
15787 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
15788 Correct argument types.
15789 Extract code from reason.
15790 (__gnat_install_handler): Assign to act.sa_sigaction.
15791
52fd02bb
EB
157922011-07-21 Eric Botcazou <ebotcazou@adacore.com>
15793
15794 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
15795 (GNAT1_OBJS): ...here.
15796
f39a9ca2
EB
157972011-07-15 Eric Botcazou <ebotcazou@adacore.com>
15798
15799 PR ada/48711
15800 * g-socthi-mingw.adb (Fill): Fix formatting.
15801
9e36aa23
EB
15802 * gcc-interface/gigi.h: Move around comment.
15803
e3aca522
JDA
158042011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
15805
15806 PR ada/46350
15807 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
15808
696b1960
FW
158092011-07-14 Florian Weimer <fw@deneb.enyo.de>
15810
15811 PR ada/48711
15812 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
15813
f542c405
EB
158142011-07-13 Eric Botcazou <ebotcazou@adacore.com>
15815
15816 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
15817 range comparison if Pmode is SImode.
15818
9e9bd455
LG
158192011-07-12 Laurent GUERBY <laurent@guerby.net>
15820 Eric Botcazou <ebotcazou@adacore.com>
15821
15822 * adadecode.c: Wrap up in extern "C" block.
15823 * adadecode.h: Likewise.
15824 * adaint.c: Likewise. Remove 'const' keyword.
15825 * adaint.h: Likewise.
15826 * argv.c: Likewise.
15827 * atree.h: Likewise.
15828 * cio.c: Likewise.
15829 * cstreams.c: Likewise.
15830 * env.c: Likewise.
15831 * exit.c: Likewise.
15832 * fe.h: Likewise.
15833 * final.c: Likewise.
15834 * init.c: Likewise.
15835 * initialize.c: Likewise.
15836 * link.c: Likewise.
15837 * namet.h: Likewise.
15838 * nlists.h: Likewise.
15839 * raise.c: Likewise.
15840 * raise.h: Likewise.
15841 * repinfo.h: Likewise.
15842 * seh_init.c: Likewise.
15843 * targext.c: Likewise.
15844 * tracebak.c: Likewise.
15845 * uintp.h: Likewise.
15846 * urealp.h: Likewise.
15847 * xeinfo.adb: Wrap up generated C code in extern "C" block.
15848 * xsinfo.adb: Likewise.
15849 * xsnamest.adb: Likewise.
15850 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
15851 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
15852 * gcc-interface/misc.c: Likewise.
15853 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
15854 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
15855 ada/targext.o here...
15856 (GNAT_ADA_OBJS): ...and not here.
15857 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
15858 (GNATBIND_OBJS): Reorder.
15859
7644b3c7
RH
158602011-07-07 Richard Henderson <rth@redhat.com>
15861
15862 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
15863 dwarf2out_frame_init.
15864
8384ac41
EB
158652011-07-07 Eric Botcazou <ebotcazou@adacore.com>
15866
15867 * gcc-interface/misc.c (gnat_init): Tweak previous change.
15868
fbdd5d87
RO
158692011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15870
15871 PR target/39150
15872 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
15873
1a072294
RG
158742011-07-06 Richard Guenther <rguenther@suse.de>
15875
8384ac41
EB
15876 * gcc-interface/misc.c (gnat_init): Merge calls to
15877 build_common_tree_nodes and build_common_tree_nodes_2.
1a072294
RG
15878 Re-initialize boolean_false_node.
15879
bc712852
EB
158802011-07-02 Eric Botcazou <ebotcazou@adacore.com>
15881 Olivier Hainque <hainque@adacore.com>
15882 Nicolas Setton <setton@adacore.com>
15883
15884 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
15885 the type according to the ARTIFICIAL_P parameter.
15886 (create_type_decl): Likewise.
15887 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
15888
2eb22389
EB
158892011-07-01 Eric Botcazou <ebotcazou@adacore.com>
15890
15891 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
15892 (gnatbind): Likewise.
15893
4bdaaf2f
RO
158942011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15895
15896 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
15897
c020c92b
EB
158982011-06-18 Eric Botcazou <ebotcazou@adacore.com>
15899
15900 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
15901 local variable throughout. Remove useless call to Base_Type.
15902 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
15903 Take it also into account for the volatileness of the field. Set the
15904 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
15905
96769d32
EB
159062011-06-18 Eric Botcazou <ebotcazou@adacore.com>
15907
15908 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
15909 on a dereference built for a by-ref object if it has an address clause.
15910
7e4680c1
EB
159112011-06-18 Eric Botcazou <ebotcazou@adacore.com>
15912
15913 * einfo.ads (Address_Taken): Document use for the second argument of
15914 Asm_Input and Asm_Output attributes.
15915 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
15916 argument is an entity name, then set Address_Taken on it.
15917 <Attribute_Asm_Output>: Likewise.
15918 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
15919 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
15920 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
15921 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
15922
159232011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
d5cc9181
JR
15924
15925 PR middle-end/46500
15926 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
15927
677f3fa8
JM
159282011-06-14 Joseph Myers <joseph@codesourcery.com>
15929
15930 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
15931 (ada/utils.o): Update dependencies.
15932 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
15933 ../../../libcpp/libcpp.a.
15934 * gcc-interface/utils.c: Include common/common-target.h.
15935 (process_attributes): Use targetm_common.have_named_sections.
15936
009db074
RG
159372011-06-07 Richard Guenther <rguenther@suse.de>
15938
0bad0e23
EB
15939 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
15940 set_sizetype.
009db074 15941
3bfc61cf
EB
159422011-06-06 Eric Botcazou <ebotcazou@adacore.com>
15943
0bad0e23 15944 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
3bfc61cf
EB
15945 TREE_THIS_NOTRAP flag.
15946
5c4a1c7b
EB
159472011-06-06 Eric Botcazou <ebotcazou@adacore.com>
15948
15949 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
15950 Fix thinko.
15951
e9f57686
EB
159522011-06-06 Eric Botcazou <ebotcazou@adacore.com>
15953
15954 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
15955 constants whose full view has discriminants specially.
15956
10e4d056
EB
159572011-06-06 Eric Botcazou <ebotcazou@adacore.com>
15958
15959 * gcc-interface/utils.c: Include diagnostic.h.
15960 (gnat_write_global_declarations): Output debug information for all
15961 global type declarations before finalizing the compilation unit.
15962 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
15963
0957c029
JJ
159642011-05-25 Jakub Jelinek <jakub@redhat.com>
15965
15966 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
15967
52d0a7ac
KT
159682011-05-25 Kai Tietz <ktietz@redhat.com>
15969
15970 * adaint.c (__gnat_to_canonical_file_list_next): Use array
15971 initialization instead of const/none-const pointer assignment.
15972
1ed1641d
JM
159732011-05-24 Joseph Myers <joseph@codesourcery.com>
15974
15975 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
15976 $(EXTRA_GNAT1_OBJS).
15977 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
15978 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
15979 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
15980 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
15981 libcommon-target.a instead of prefix.o.
15982
9fe72ebd
JM
159832011-05-21 Joseph Myers <joseph@codesourcery.com>
15984
15985 PR ada/49097
0bad0e23 15986 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
9fe72ebd 15987
2691e6d7
JM
159882011-05-20 Joseph Myers <joseph@codesourcery.com>
15989
0bad0e23
EB
15990 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
15991 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
15992 instead of version.o.
2691e6d7 15993
2d0dd51a 159942011-05-18 Kai Tietz <ktietz@redhat.com>
bf6490b5
KT
15995
15996 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
15997 boolean_false_node instead of integer_zero_node.
15998 (convert_with_check): Likewise.
15999 * gcc-interface/decl.c (choices_to_gnu): Likewise.
16000
7bf9a5ac
EB
160012011-05-12 Eric Botcazou <ebotcazou@adacore.com>
16002
16003 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
16004 type of the parameter is an unconstrained array, convert the actual to
16005 the type of the formal in the In Out and Out cases as well.
16006
e5b00edf
NF
160072011-05-11 Nathan Froyd <froydnj@codesourcery.com>
16008
16009 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
16010 call build_function_type_array or build_varargs_function_type_array
16011 instead.
16012 (create_subprog_type): Don't call build_function_type; call
16013 build_function_type_vec instead.
16014
51545682
NF
160152011-05-11 Nathan Froyd <froydnj@codesourcery.com>
16016
16017 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
16018 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
16019 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
16020
c99c0026
EB
160212011-05-07 Eric Botcazou <ebotcazou@adacore.com>
16022
f620bd21
EB
16023 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
16024
c99c0026
EB
16025 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
16026 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
16027
3d528853
NF
160282011-05-05 Nathan Froyd <froydnj@codesourcery.com>
16029
c99c0026 16030 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
3d528853 16031
d7d058c5
NF
160322011-05-05 Nathan Froyd <froydnj@codesourcery.com>
16033
16034 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
16035 instead of accessing TYPE_ARG_TYPES directly.
16036 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
16037
805e60a0
EB
160382011-05-05 Eric Botcazou <ebotcazou@adacore.com>
16039
16040 PR ada/48844
16041 * gcc-interface/gigi.h (get_variant_part): Declare.
16042 * gcc-interface/decl.c (get_variant_part): Make global.
16043 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
16044 types have the same constant size, are record types and T1 has a
16045 variant part while T2 doesn't.
16046
907a08d9
EB
160472011-05-05 Eric Botcazou <ebotcazou@adacore.com>
16048
16049 * gcc-interface/utils.c (begin_subprog_body): Do not call
16050 get_pending_sizes.
16051 (end_subprog_body): Likewise.
16052
d35936ab
RG
160532011-05-04 Richard Guenther <rguenther@suse.de>
16054
16055 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
16056 int_const_binop.
16057 (pos_to_constructor): Likewise.
16058
c1fd8753 160592011-05-03 Nathan Froyd <froydnj@codesourcery.com>
2c7f9cc0 16060 Eric Botcazou <ebotcazou@adacore.com>
c1fd8753
NF
16061
16062 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
16063 of build_function_type. Adjust calls to...
16064 (build_raise_check): ...this. Do not take a void_tree parameter.
16065 Call build_function_type_list instead of build_function_type.
16066 Fix head comment and swap couple of conditional blocks.
16067
4fb87d2b
EB
160682011-04-30 Eric Botcazou <ebotcazou@adacore.com>
16069
16070 * gnatvsn.ads (Library_Version): Bump to 4.7.
16071 (Current_Year): Bump to 2011.
16072
fa5e5a76
MM
160732011-04-29 Michael Matz <matz@suse.de>
16074
16075 * gcc-interface/misc.c (gnat_handle_option): Set
16076 warn_maybe_uninitialized.
16077
8d6a2f69
GP
160782011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
16079
16080 * gnat_ugn.texi (Complexity Metrics Control): Update link to
16081 the Watson/McCabe paper.
16082
770937fd
JM
160832011-04-23 Jim Meyering <meyering@redhat.com>
16084
16085 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
16086
eb601ae1
EB
160872011-04-22 Eric Botcazou <ebotcazou@adacore.com>
16088
16089 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
16090 onto the new type.
16091
7d7fcb08
EB
160922011-04-22 Eric Botcazou <ebotcazou@adacore.com>
16093
16094 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
16095 parameter.
16096 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
16097 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
16098 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
16099 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
16100 <all>: Do not set flags on the reused DECL node coming from an alias.
16101 Set DECL_IGNORED_P on the DECL node built for subprograms if they
16102 don't need debug info here...
16103 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
16104 (gigi): Adjust calls to create_subprog_decl.
16105 (build_raise_check): Likewise.
16106 (establish_gnat_vms_condition_handler): Likewise.
16107 (Compilation_Unit_to_gnu): Likewise.
16108 (gnat_to_gnu): Likewise.
16109
e1876cac
EB
161102011-04-21 Eric Botcazou <ebotcazou@adacore.com>
16111
16112 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
16113 (NO_REORDER_ADAFLAGS): New variable.
16114 (EXTRA_GNATTOOLS): Always define.
16115 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
16116 Clean up and adjust list of files compiled with special options.
16117 * gcc-interface/Make-lang.in: Likewise.
16118 (ada/decl.o): Cosmetical change.
16119 (ada/misc.o): Remove dependency on $(PLUGIN_H).
16120
04695783
JM
161212011-04-20 Jim Meyering <meyering@redhat.com>
16122
16123 * initialize.c (__gnat_initialize): Remove useless if-before-free.
16124
23399579
EB
161252011-04-17 Eric Botcazou <ebotcazou@adacore.com>
16126
16127 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
16128 $(CFLAGS) on the link line.
16129
51c5169c
EB
161302011-04-17 Eric Botcazou <ebotcazou@adacore.com>
16131
16132 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
16133 padded type built for the return type if it is unconstrained.
16134
61e46a7d
NF
161352011-04-14 Nathan Froyd <froydnj@codesourcery.com>
16136
16137 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
16138
81f653d6
NF
161392011-04-12 Nathan Froyd <froydnj@codesourcery.com>
16140
b4867846
EB
16141 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
16142 before calling TREE_CHAIN.
81f653d6
NF
16143 * gcc-interface/misc.c (gnat_init_ts): New function.
16144 (LANG_HOOKS_INIT_TS): Define.
16145
a358e188
MJ
161462011-04-12 Martin Jambor <mjambor@suse.cz>
16147
b4867846
EB
16148 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
16149 instead of cgraph_node.
a358e188 16150
29b1c5a4
EB
161512011-04-08 Eric Botcazou <ebotcazou@adacore.com>
16152
16153 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
16154 alignment on fields of the RETURN type built for the Copy-In Copy-Out
16155 mechanism.
16156
88872b00
EB
161572011-04-08 Eric Botcazou <ebotcazou@adacore.com>
16158
16159 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
16160 of aggregate types that contain a placeholder.
16161
dcf0c47e
NF
161622011-04-08 Nathan Froyd <froydnj@codesourcery.com>
16163
16164 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
b4867846 16165 TYPE_ARG_TYPES.
dcf0c47e
NF
16166 (handle_type_generic_attribute): Likewise.
16167
53e3000c
EB
161682011-04-04 Eric Botcazou <ebotcazou@adacore.com>
16169
16170 PR ada/47163
16171 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
16172
ab380bb4
KT
161732011-04-04 Kai Tietz <ktietz@redhat.com>
16174
16175 PR ada/47163
0bad0e23
EB
16176 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
16177 to flag value.
ab380bb4 16178
8ffac116
EB
161792011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16180
16181 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
16182 type case, do not strip a padding type around the array type.
16183
de9528f0
EB
161842011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16185
16186 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
16187 types.
16188
d9d7a26c
EB
161892011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16190
16191 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
16192 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
de9528f0 16193 code for -feliminate-unused-debug-types.
d9d7a26c
EB
16194 (gnat_post_options): Likewise.
16195
4cb12a90
EB
161962011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16197
16198 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
16199 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
16200 distinct copy.
16201
acccc61c
EB
162022011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16203
16204 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
16205 DECL_ARTIFICIAL flag on enumeration types.
16206
583eb0c9
EB
162072011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16208
16209 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
16210 fat pointer types artificial unconditionally.
16211 <E_Array_Subtype>: Attach the base array type as a parallel type if it
16212 isn't artificial.
16213
e3edbd56
EB
162142011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16215
16216 * gcc-interface/gigi.h (get_dummy_type): Declare.
16217 (build_dummy_unc_pointer_types): Likewise.
16218 (finish_fat_pointer_type): Likewise.
16219 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
16220 fat pointer type has been built, complete it in place.
16221 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
16222 and thin pointers. Remove useless variable.
16223 (finish_fat_pointer_type): Make global and move to...
16224 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
16225 (get_dummy_type): New function.
16226 (build_dummy_unc_pointer_types): Likewise.
16227 (gnat_pushdecl): Propage the name to the anonymous variants only.
16228 (update_pointer_to): Only adjust the pointer types in the unconstrained
16229 array case.
16230
65444786
EB
162312011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16232
16233 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
16234 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
16235 if this is a Taft amendment type and the full declaration is available.
16236 * gcc-interface/trans.c (process_type): Likewise.
16237 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
16238 (process_freeze_entity): Likewise.
16239 * gcc-interface/utils.c (dummy_global): New static variable.
16240 (gnat_write_global_declarations): If there are types declared as used
16241 at the global level, insert them in the global hash table.
16242
1aeb40dd
EB
162432011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16244
16245 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
16246 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
16247 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
16248 copy.
16249 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
16250 flag of the type accordingly.
16251 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
16252
80ec8b4c
EB
162532011-04-02 Eric Botcazou <ebotcazou@adacore.com>
16254
16255 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
16256 finalizing types when updating the pointers to the designated type.
16257 <all>: Finalize the deferred types even if we didn't defer processing
16258 of incomplete types in this invocation.
16259
2a9d769a 162602011-04-01 Olivier Hainque <hainque@adacore.com>
2c7f9cc0
AS
16261 Nicolas Setton <setton@adacore.com>
16262 Eric Botcazou <ebotcazou@adacore.com>
2a9d769a
OH
16263
16264 * gcc-interface/misc.c (gnat_descriptive_type): New function.
16265 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
16266
2438d7a6
KT
162672011-03-28 Kai Tietz <ktietz@redhat.com>
16268
333d8aff 16269 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
80ec8b4c
EB
16270 Windows targets.
16271 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
16272 * system-mingw.ads (System): Change ZCX_By_Default default to True.
333d8aff 16273
80ec8b4c 16274 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
2438d7a6 16275
8ad150f6
TG
162762011-03-28 Tristan Gingold <gingold@adacore.com>
16277
16278 PR ada/44431
80ec8b4c
EB
16279 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
16280 Use ada output of gnatbind.
8ad150f6
TG
16281 (ada/b_gnatb.adb): Ditto.
16282 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
16283 (ada.mostlyclean, ada.stage1)
16284 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
16285 (ada.stagefeedback): Adjust.
80ec8b4c 16286 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
8ad150f6
TG
16287 Use ada output of gnatbind.
16288 (b_gnatm.adb): Ditto.
16289 (b_gnatl.o, b_gnatm.o): New rules.
16290
51c7954d
EB
162912011-03-26 Eric Botcazou <ebotcazou@adacore.com>
16292
16293 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
16294 for the padded type built to support a specified size or alignment.
16295
6ddf9843
EB
162962011-03-26 Eric Botcazou <ebotcazou@adacore.com>
16297
16298 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
16299 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
16300 unconditionally to the end of the unit when the designated type is
16301 limited_with'ed.
16302 <all>: Rename local variable. Attempt to un-defer types only and do it
16303 for limited_with'ed types as well.
16304 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
16305 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
16306 consistently and remove redundant call to finalize_from_with_types.
16307
5daed84a
EB
163082011-03-26 Eric Botcazou <ebotcazou@adacore.com>
16309
16310 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
16311 subprograms without a previous spec declared in the same unit.
16312 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
16313 subprograms at the end of the unit instead of at the beginning.
16314 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
16315 isn't public for the special handling of non-inline functions nested
16316 inside inline external functions.
16317
0edf1bb2
JL
163182011-03-25 Jeff Law <law@redhat.com>
16319
5daed84a 16320 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
0edf1bb2 16321
e3c4580e
EB
163222011-03-24 Eric Botcazou <ebotcazou@adacore.com>
16323
16324 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
16325 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
16326 to compute Set_Size_Depends_On_Discriminant.
16327 (Layout_Type): Call it on array types in back-end layout mode.
16328 * sem_util.adb (Requires_Transient_Scope): Return true for array
16329 types only if the size depends on the value of discriminants.
16330 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
16331 type if the RHS is a call to a function that returns an unconstrained
16332 type with default discriminant.
16333
abbc8c7b
EB
163342011-03-24 Eric Botcazou <ebotcazou@adacore.com>
16335
16336 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
16337 non-conversion to the nominal result type at the end.
16338
ddb5a105
EB
163392011-03-23 Eric Botcazou <ebotcazou@adacore.com>
16340
16341 * gcc-interface/trans.c (create_temporary): New function taken from...
16342 (create_init_temporary): ...here. Call it.
16343 (call_to_gnu): Create the temporary for the return value early, if any.
16344 Create it for a function with copy-in/copy-out parameters if there is
16345 no target; in other cases of copy-in/copy-out, use another temporary.
16346 Push the new binding level lazily. Add and rename local variables.
16347
0d853156
EB
163482011-03-23 Eric Botcazou <ebotcazou@adacore.com>
16349
16350 * gcc-interface/decl.c (validate_size): Improve comments and tweak
16351 error message.
16352 (set_rm_size): Likewise.
16353
4184ef1b
EB
163542011-03-23 Eric Botcazou <ebotcazou@adacore.com>
16355
16356 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
16357 for the padded type built in order to support a specified alignment.
16358 Fix incorrect formatting.
16359
bf7eefab
EB
163602011-03-21 Eric Botcazou <ebotcazou@adacore.com>
16361
16362 PR bootstrap/48216
16363 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
16364
ef0feeb2
EB
163652011-03-21 Eric Botcazou <ebotcazou@adacore.com>
16366
16367 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
16368 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
16369 to the end of the list. Adjust recursive call. Rename local variable.
16370 If REORDER is true, reorder components of the record type.
16371 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
16372 components_to_record and adjust the parameter list.
16373
646f9414
EB
163742011-03-21 Eric Botcazou <ebotcazou@adacore.com>
16375
16376 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
16377 disabled, use the variable for bounds of loop iteration scheme.
16378
62d784f7
KT
163792011-03-21 Kai Tietz <ktietz@redhat.com>
16380
16381 PR target/12171
0bad0e23 16382 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
62d784f7 16383
f230d759
EB
163842011-03-17 Eric Botcazou <ebotcazou@adacore.com>
16385
16386 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
16387 out whether the expression is read-only. Short-circuit placeholder
16388 case and rename a couple of local variables.
16389
bb1f7929
EB
163902011-03-17 Eric Botcazou <ebotcazou@adacore.com>
16391
16392 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
16393 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
16394 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
16395 (convert): Deal with conversions from a smaller form type specially.
16396
400a2d24
EB
163972011-02-14 Eric Botcazou <ebotcazou@adacore.com>
16398
16399 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
16400 its argument, except for the special -I- switch.
16401
c26bc3ad
GP
164022011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
16403
0bad0e23
EB
16404 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
16405 "Ada Issues".
c26bc3ad 16406
07b8e910
EB
164072011-02-08 Eric Botcazou <ebotcazou@adacore.com>
16408
16409 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
16410
31a5a547
EB
164112011-02-03 Eric Botcazou <ebotcazou@adacore.com>
16412
16413 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
16414 GNAT_FORMAL.
16415 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
16416 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
16417 instead of GNAT_FORMAL. Protect the expression against multiple uses.
16418 Do not generate the check directly, instead instantiate the template
16419 check present in the descriptor.
16420 (make_descriptor_field): Move around.
16421 (build_vms_descriptor32): Build a template check in the POINTER field.
16422 (build_vms_descriptor): Remove useless suffixes.
16423 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
16424
dcf25f59
EB
164252011-01-26 Eric Botcazou <ebotcazou@adacore.com>
16426
16427 PR bootstrap/47467
16428 * targext.c: Include target files if IN_RTS is defined.
16429
0418e131
RG
164302011-01-26 Richard Guenther <rguenther@suse.de>
16431
16432 PR bootstrap/47467
16433 * targext.c: Include config.h.
16434 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
16435 dependency.
16436
c6eecbd8 164372011-01-04 Pascal Obry <obry@adacore.com>
2c7f9cc0 16438 Eric Botcazou <ebotcazou@adacore.com>
c6eecbd8
PO
16439
16440 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
16441
2d3c7e4f
EB
164422011-01-04 Eric Botcazou <ebotcazou@adacore.com>
16443
16444 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
16445 end-of-case on the end label and its associated gotos, if any.
16446
0394741f
EB
164472011-01-04 Eric Botcazou <ebotcazou@adacore.com>
16448
16449 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
16450 expressions of the parameter cache within the statement group of
16451 the CICO mechanism.
16452
2a02d090 164532011-01-04 Olivier Hainque <hainque@adacore.com>
2c7f9cc0 16454 Eric Botcazou <ebotcazou@adacore.com>
2a02d090
OH
16455
16456 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
16457 (set_end_locus_from_node): New function.
16458 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
16459 make and the function end_locus.
16460 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
16461 for the elaboration subprogram.
16462 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
16463 set the end_locus of the expression as well.
16464
89f5e978
EB
164652011-01-04 Eric Botcazou <ebotcazou@adacore.com>
16466
16467 PR ada/47131
16468 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
16469 variables that are referenced in exception handlers volatile.
16470
16471
ad41bd84 16472\f
797103eb 16473Copyright (C) 2011 Free Software Foundation, Inc.
ad41bd84
JM
16474
16475Copying and distribution of this file, with or without modification,
16476are permitted in any medium without royalty provided the copyright
16477notice and this notice are preserved.