]> gcc.gnu.org Git - gcc.git/blame - gcc/ada/ChangeLog
re PR rtl-optimization/49941 (segmentation fault in redirect_jump_2)
[gcc.git] / gcc / ada / ChangeLog
CommitLineData
0187b60e
AC
12011-08-03 Gary Dismukes <dismukes@adacore.com>
2
3 * sem_ch6.adb (Find_Corresponding_Spec): When in an instance, skip
4 conforming subprogram renamings that appear to be completions if they
5 are not fully conformant.
6 Such renamings are homographs but not completions.
7 * sem_type.adb (Disambiguate): Handle disambiguation of overloaded
8 names in a subprogram renaming that appears in an instance.
9
102011-08-03 Ed Schonberg <schonberg@adacore.com>
11
12 * exp_util.adb (Expand_Subtype_From_Expr): if the type is limited but
13 not immutably limited, build actual subtype from expression to provide
14 proper bounds to caller.
15
162011-08-03 Gary Dismukes <dismukes@adacore.com>
17
18 * sem_ch8.adb: Minor comment correction.
19
202011-08-03 Thomas Quinot <quinot@adacore.com>
21
22 * exp_strm.adb (Build_Array_Input_Function): In Ada 2005 mode, when
23 returning a limited array, use an extended return statement.
24
252011-08-03 Vincent Celier <celier@adacore.com>
26
27 * make.adb (Initialize): If --subdirs= is used, but no project file is
28 specified, attempt to create the specify subdir if it does not already
29 exist and use it as the object directory as if -D had been specified.
30
312011-08-03 Arnaud Charlet <charlet@adacore.com>
32
33 * s-tpopsp-vms.adb: New file.
34 * s-taprop-vms.adb: Put back ATCB_Key, since needed by this file on VMS.
35 * gcc-interfaces/Makefile.in: Use s-taprop-vms.adb on VMS.
36
e280f981
AC
372011-08-03 Emmanuel Briot <briot@adacore.com>
38
39 * make.adb, makeutl.adb, makeutl.ads, clean.adb (Makeutl.Queue): new
40 package.
41
422011-08-03 Yannick Moy <moy@adacore.com>
43
44 * cstand.adb (Create_Standard): select Universal_Integer as an ALFA type
45 * sem_ch3.adb (Array_Type_Declaration): detect array types in ALFA
46 * sem_util.adb, sem_util.ads (Has_Static_Array_Bounds): new function to
47 detect that an array has static bounds.
48
98c99a5a
AC
492011-08-03 Thomas Quinot <quinot@adacore.com>
50
51 * exp_dist.adb: Minor reformatting.
52
532011-08-03 Arnaud Charlet <charlet@adacore.com>
54
55 * s-taprop-irix.adb, s-taprop-hpux-dce.adb, s-taprop-vms.adb
56 (ATCB_Key): Removed, not always used.
57
582011-08-03 Emmanuel Briot <briot@adacore.com>
59
60 * gnatcmd.adb, make.adb, prj.adb, prj.ads, makeutl.adb, makeutl.ads,
61 clean.adb, prj-conf.adb, prj-env.adb, prj-env.ads (Makeutl): remove
62 most remaining global variables.
63
686d0984
AC
642011-08-03 Robert Dewar <dewar@adacore.com>
65
66 * gnatcmd.adb, prj-proc.adb, mlib-prj.adb, prj.adb, makeutl.ads,
67 prj-util.adb, prj-util.ads, prj-conf.adb, prj-env.adb: Minor
68 reformatting.
69
702011-08-03 Javier Miranda <miranda@adacore.com>
71
72 * exp_util.adb (Is_VM_By_Copy_Actual): Include N_Slide nodes as actuals
73 that must be passed by copy in VM targets.
74
752011-08-03 Emmanuel Briot <briot@adacore.com>
76
77 * prj.ads, prj-nmsc.adb (Files_Htable): removed this htable, which
78 duplicates a similar htable now in the project tree.
79
802011-08-03 Claire Dross <dross@adacore.com>
81
82 * a-cfdlli.adb, a-cfhama.adb, a-cfhase.adb, a-cforma.adb, a-cforse.adb,
83 a-cofove.adb ("=", Length, Is_Empty, Clear, Assign, Copy, Element,
84 Replace_Element, Query_Element, Update_Element, Move, Insert, Prepend,
85 Append, Delete, Delete_First, Delete_Last, Reverse_Element, Swap,
86 Splice, First, First_Element, Last, Last_Element, Next, Previous, Find,
87 Reverse_Find, Contains, Has_Element, Iterate, Reverse_Iterate, Capacity,
88 Reserve_Length, Length, Strict_Equal, Left, Right): Data-structure
89 update.
90
912011-08-03 Arnaud Charlet <charlet@adacore.com>
92
93 * s-taprop-posix.adb, s-taprop-linux.adb, s-taprop-tru64.adb
94 (ATCB_Key): Removed, not always used.
95 * s-tpopsp-posix.adb, s-tpopsp-posix-foreign.adb (ATCB_Key): Moved from
96 s-taprop-posix.adb.
97 * s-tpopsp-tls.adb: New file.
98 * gcc-interface/Makefile.in: Use TLS implementation of s-tpopsp.adb on
99 x86/x64/ia64/powerpc/sparc Linux.
100
1012011-08-03 Arnaud Charlet <charlet@adacore.com>
102
103 * system-aix.ads, system-aix64.ads: Set ZCX_By_Default to True.
104 * gcc-interface/Makefile.in: Switch to ZCX by default on AIX ports.
105
1062011-08-03 Thomas Quinot <quinot@adacore.com>
107
108 * rtsfind.ads, exp_dist.adb, exp_dist.ads
109 (Build_From_Any_Call, Build_To_Any_Call, Build_TypeCode_Call):
110 Fix type selection for mapping integer types to PolyORB types.
111
1122011-08-03 Bob Duff <duff@adacore.com>
113
114 * sem_ch7.adb: Minor comment clarification.
115
1162011-08-03 Bob Duff <duff@adacore.com>
117
118 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): If we get
119 an error analyzing a choice, skip further processing. Further
120 processing could cause a crash or cascade errors.
121
40ecf2f5
EB
1222011-08-03 Emmanuel Briot <briot@adacore.com>
123
124 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, mlib-prj.adb,
125 prj.adb, prj.ads, makeutl.adb, makeutl.ads, clean.adb, prj-nmsc.adb,
126 prj-util.adb, prj-util.ads, prj-conf.adb, prj-conf.ads, prj-env.adb,
127 prj-env.ads (Shared_Project_Tree_Data): new type
128 An aggregate project and its aggregated trees need to share the common
129 data structures used for lists of strings, packages,... This makes the
130 code simpler since otherwise we have to pass the root tree (also used
131 for the configuration file data) in addition to the current project
132 tree. This also avoids ambiguities as to which tree should be used.
133 And finally this saves a bit of memory.
134 (For_Every_Project_Imported): new parameter Tree.
135 Since aggregated projects are using a different tree, we need to let
136 the caller know which tree to use to manipulate the returned project.
137
9fde638d
RD
1382011-08-03 Robert Dewar <dewar@adacore.com>
139
140 * prj-proc.adb, exp_util.ads, exp_ch9.adb, make.adb, prj-ext.adb,
141 prj-ext.ads, alfa.ads, sem_ch4.adb, makeutl.adb, makeutl.ads,
142 lib-xref-alfa.adb, sem_cat.adb, exp_dist.adb, get_alfa.adb,
143 prj-env.adb, prj-env.ads, prj-tree.adb, alfa.ads: Minor reformatting.
144
95eb8b69
AC
1452011-08-03 Javier Miranda <miranda@adacore.com>
146
147 * exp_util.adb, sem_aux.adb, exp_util.ads, sem_aux.ads:
148 Move routine Is_VM_By_Copy_Actual from sem_aux to exp_util.
149
1502011-08-03 Bob Duff <duff@adacore.com>
151
152 * sem_ch8.adb (Is_Primitive_Operator_In_Use): Always check In_Use on
153 the Base_Type.
154
1552011-08-03 Joel Brobecker <brobecker@adacore.com brobecker>
156
157 * g-sha256.ads, g-sha512.ads, g-sha1.ads, g-sha224.ads, g-sha384.ads,
158 g-sehash.ads: Fix typo. Update header.
159
1602011-08-03 Thomas Quinot <quinot@adacore.com>
161
162 * exp_ch6.adb (Expand_Actuals): Remove Ada_2005 guard on build-in-place
163 expansion.
164
1652011-08-03 Gary Dismukes <dismukes@adacore.com>
166
167 * sem_ch4.adb (Analyze_Overloaded_Selected_Component): Consider
168 prefixes of private types along with records, since the selector may be
169 a discriminant.
170 * sem_res.adb (Resolve_Selected_Component): Consider prefixes of
171 private types along with records, since the selector may be a
172 discriminant.
173
92e77027
AC
1742011-08-03 Emmanuel Briot <briot@adacore.com>
175
176 * prj-pp.adb (Pretty_Print): remove trailing blank line in the file
177
1782011-08-03 Javier Miranda <miranda@adacore.com>
179
180 * sem_aux.adb (Is_VM_By_Copy_Actual): Fix wrong use of
181 Tagged_Type_Expansion.
182
1832011-08-03 Yannick Moy <moy@adacore.com>
184
185 * sem_res.adb
186 (Resolve_Op_Concat_Arg): do not issue a SPARK violation when argument of
187 concatenation is the name of a constant
188
ab29a348
EB
1892011-08-03 Emmanuel Briot <briot@adacore.com>
190
191 * prj-proc.adb, prj-ext.adb, prj-ext.ads, prj-env.adb, prj-env.ads,
192 prj-tree.adb, prj-tree.ads (Initialize_And_Copy, Copy): new subprograms
193 (Process_Declarative_Items): new parameter Child_Env.
194
9466892f
AC
1952011-08-03 Yannick Moy <moy@adacore.com>
196
197 * alfa.ads Update format of ALFA section in ALI file in order to add a
198 mapping from bodies to specs when both are present
199 (ALFA_Scope_Record): add components for spec file/scope
200 * get_alfa.adb (Get_ALFA): read the new file/scope for spec when present
201 * lib-xref-alfa.adb
202 (Collect_ALFA): after all scopes have been collected, fill in the spec
203 information when relevant
204 * put_alfa.adb (Put_ALFA): write the new file/scope for spec when
205 present.
206
2072011-08-03 Eric Botcazou <ebotcazou@adacore.com>
208
209 * inline.adb (Add_Inlined_Subprogram): Do not consider the enclosing
210 code unit to decide whether to add internally generated subprograms.
211
2122011-08-03 Javier Miranda <miranda@adacore.com>
213
214 * sem_aux.ads, sem_aux.adb (Is_VM_By_Copy_Actual): New subprogram.
215 * exp_ch9.adb
216 (Build_Simple_Entry_Call): Handle actuals that must be handled by copy
217 in VM targets.
218
2192011-08-03 Emmanuel Briot <briot@adacore.com>
220
221 * make.adb, makeutl.adb, makeutl.ads (Make.Switches_Of): now shares
222 code with Makeutl.Get_Switches.
223 * prj-tree.adb: Update comment.
224
b5ea9143
AC
2252011-08-03 Thomas Quinot <quinot@adacore.com>
226
227 * sem_cat.adb (Validate_RCI_Subprogram_Declaration): Reject a remote
228 subprogram with a limited formal that does not support external
229 streaming.
230
2312011-08-03 Yannick Moy <moy@adacore.com>
232
233 * get_alfa.adb (Get_ALFA): add missing Skip_Spaces at start of
234 continuation line
235 * lib-xref-alfa.adb (Add_ALFA_File): split removal of scopes that are
236 not from current unit in two phases, because it is not possible to
237 change the table while iterating over its content.
238 * put_alfa.adb (Put_ALFA): reset current file/scope at each new entity
239
2402011-08-03 Sergey Rybin <rybin@adacore.com>
241
242 * vms_data.ads: Add qualifier for gnatmetric --no-static-loop option
243 * gnat_ugn.texi: Update description of complexity metrics (gnatmetric)
244
668a19bc
ES
2452011-08-03 Ed Schonberg <schonberg@adacore.com>
246
247 * sem_res.adb (Resolve_Op_Concat_Arg): if the argument is an aggregate
248 and the component type is composite, this is ambiguous for predefined
249 concatenation, but if the node is not overloaded and the entity is a use
250 -defined function its profile can be used to resolve that aggregate.
251
170b2989
AC
2522011-08-03 Robert Dewar <dewar@adacore.com>
253
254 * exp_ch4.adb: Minor code cleanup.
255
2562011-08-03 Thomas Quinot <quinot@adacore.com>
257
258 * exp_dist.adb: Do not generate distribution stubs if serious errors
259 have been diagnosed.
260
2612011-08-03 Ed Schonberg <schonberg@adacore.com>
262
263 * sem_ch4.adb (Try_Primitive_Operation): when checking the validity of
264 the first formal of a primitive operation, go to the base type to
265 handle properly an access to a derived type with constrained
266 discriminants.
267 * sem_type.adb (Disambiguate): an immediately visible operator hides a
268 user-defined function that is only use-visible.
170b2989 269
e917aec2
RD
2702011-08-03 Robert Dewar <dewar@adacore.com>
271
272 * sem_aggr.adb, sem_ch3.adb, lib.ads, gnatcmd.adb, prj-proc.adb,
273 make.adb, lib-writ.adb, prj-part.adb, prj-part.ads, prj-ext.adb,
274 fname-uf.adb, prj-ext.ads, prj.adb, prj.ads, sem_attr.adb, alfa.adb,
275 prj-makr.adb, errout.adb, makeutl.adb, makeutl.ads, restrict.ads,
276 sem_ch6.adb, g-pehage.adb, clean.adb, put_alfa.adb, lib-xref-alfa.adb,
277 prj-nmsc.adb, prj-nmsc.ads, sem_ch8.adb, prj-pars.ads, exp_aggr.adb,
278 prj-attr.ads, sem_ch13.adb, get_alfa.adb, prj-env.adb, prj-env.ads,
279 alfa_test.adb, prj-tree.adb, prj-tree.ads, einfo.ads: Minor reformatting
280
2812011-08-03 Robert Dewar <dewar@adacore.com>
282
283 * repinfo.adb (List_Mechanism): Add handling of
284 Convention_Ada_Pass_By_XXX.
285 * sem_mech.adb (Set_Mechanism): Ditto.
286 * sem_prag.adb (Process_Convention): Add entries for
287 Convention_Ada_Pass_By_XXX.
288 * snames.adb-tmpl, snames.ads-tmpl: Ditto.
289
49bfcf43
AC
2902011-08-03 Pascal Obry <obry@adacore.com>
291
292 * makeutl.adb: Minor reformatting.
293
2942011-08-03 Vincent Celier <celier@adacore.com>
295
296 * fname-uf.adb
297 (Get_File_Name) If the file cannot be found when there are no config
298 pragmas file and May_Fail is True, return No_File instead of the file
299 name, to be consistent.
300
3012011-08-03 Pascal Obry <obry@adacore.com>
302
303 * adaint.c (__gnat_is_executable_file_attr): Avoid access
304 to null pointer.
305
3062011-08-03 Javier Miranda <miranda@adacore.com>
307
308 * sem_ch13.adb
309 (Same_Representation): In VM targets the representation of arrays with
310 aliased components differs from arrays with non-aliased components.
311
34798441
EB
3122011-08-03 Emmanuel Briot <briot@adacore.com>
313
314 * prj-proc.adb, prj-attr.adb, prj-attr.ads (Get_Attribute_Index): do
315 not systematically lower case attribute indexes that contain no "."
316 Fix definition of several Naming attributes, which take
317 a unit name as index and therefore should be case insensitive.
318 Minor refactoring (reduce length of variable names).
319
3202011-08-03 Emmanuel Briot <briot@adacore.com>
321
322 * makeutl.adb, makeutl.ads (Get_Switches): new subprogram.
323
4437a530
EB
3242011-08-03 Emmanuel Briot <briot@adacore.com>
325
326 * gnatcmd.adb, prj-proc.adb, prj-proc.ads, make.adb, prj-part.adb,
327 prj-part.ads, switch-m.adb, switch-m.ads, prj-makr.adb, clean.adb,
328 prj-pars.adb, prj-pars.ads, prj-conf.adb, prj-conf.ads, prj-tree.adb,
329 prj-tree.ads (Prj.Tree.Environment): new type.
330
804fe3c4
EB
3312011-08-03 Emmanuel Briot <briot@adacore.com>
332
333 * prj-proc.adb, prj.ads, makeutl.adb, makeutl.ads, prj-conf.adb,
334 prj-tree.adb, prj-tree.ads (Environment): new type.
335
c565bc66
AC
3362011-08-03 Emmanuel Briot <briot@adacore.com>
337
338 * prj-tree.ads: Remove unused variable.
339
3402011-08-03 Yannick Moy <moy@adacore.com>
341
342 * restrict.adb (Restriction_Msg): set "SPARK" all in upper case for
343 issuing messages related to SPARK restriction violation.
344
4ee646da
AC
3452011-08-03 Ed Schonberg <schonberg@adacore.com>
346
347 * sem_ch6.adb: guard against error nodes in return statements.
348
3492011-08-03 Arnaud Charlet <charlet@adacore.com>
350
351 * errout.adb (Error_Msg_Internal): the main unit has not been read yet,
352 a warning can only appear on a configuration file, so emit warning
353 without further checks.
354
3552011-08-03 Arnaud Charlet <charlet@adacore.com>
356
357 * s-interr.ads: add overriding keyword.
358
3592011-08-03 Geert Bosch <bosch@adacore.com>
360
361 * exp_attr.adb: Fix minor typo.
362
3632011-08-03 Ed Schonberg <schonberg@adacore.com>
364
365 * par-ch4.adb: improve error recovery.
366
c0e538ad
AC
3672011-08-03 Emmanuel Briot <briot@adacore.com>
368
369 * prj-part.adb, prj-part.ads, prj-makr.adb, prj-pars.adb, prj-conf.adb,
370 prj-env.adb (Prj.Part.Parse): change parameter Always_Errout_Finalize
371 to Errout_Handling.
372
3732011-08-03 Emmanuel Briot <briot@adacore.com>
374
375 * prj-dect.adb (Parse_Attribute_Declaration): make sure we can use
376 "external" as an attribute name in aggregate projects.
377
3782011-08-03 Jose Ruiz <ruiz@adacore.com>
379
380 * s-taprop-vxworks.adb: (Create_Task, Initialize): Ada 2012 pragma CPU
381 uses CPU numbers starting 1, while VxWorks uses CPU numbers starting
382 from 0, so we need to adjust.
383
3842011-08-03 Emmanuel Briot <briot@adacore.com>
385
386 * prj-proc.adb, prj-ext.adb, prj-ext.ads, makeutl.adb, prj-tree.adb,
387 prj-tree.ads, gnatcmd.adb, clean.adb (External_References): new type.
388
c4d67e2d
AC
3892011-08-03 Yannick Moy <moy@adacore.com>
390
391 * sem_ch6.adb (New_Overloaded_Entity): only issue error for SPARK
392 restriction on overloaded entity if the entity is not an operator.
393
3942011-08-03 Yannick Moy <moy@adacore.com>
395
396 * sem_ch7.adb, sem_res.adb, sem_attr.adb, restrict.adb,
397 restrict.ads: Rename remaining Check_Formal_Restriction* into
398 Check_SPARK_Restriction*.
399
4002011-08-03 Emmanuel Briot <briot@adacore.com>
401
402 * prj-proc.adb, prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb,
403 prj-nmsc.ads, prj-err.adb (Project_Data): now discriminated on its
404 qualifier.
405 (Project_Empty): removed
406 (Empty_Project): new parameter Qualifier
407 This is used to have fields specific to aggregate projects, cleaner
408 New field to store the list of aggregated projects.
409 (Check_Aggregate_Project): removed
410 (Process_Aggregated_Projects, Free): new subprograms.
411
3f5a8fee
AC
4122011-08-03 Olivier Hainque <hainque@adacore.com>
413
414 * tracebak.c (STOP_FRAME ppc AIX): Stop at null return address as well.
415
4162011-08-03 Ed Schonberg <schonberg@adacore.com>
417
418 * sem_ch8.adb (Analyze_Object_Renaming): if the renamed object is an
419 explicit dereference of an unconstrained type, create a constrained
420 subtype for it, as is done for function calls that return an
421 unconstrained type.
422
4232011-08-03 Thomas Quinot <quinot@adacore.com>
424
425 * g-pehage.adb (Finalize): Avoid possible double-free.
426
4272011-08-03 Steve Baird <baird@adacore.com>
428
429 * exp_attr.adb (Expand_N_Attribute_Reference): Don't expand
430 Elab_Spec/Body attrs in CodePeer_Mode.
431
4322011-08-03 Javier Miranda <miranda@adacore.com>
433
434 * exp_aggr.adb (Flatten): Convert to positional form aggregates whose
435 low bound is not known at compile time but they have no others choice.
436 Done because in this case the bounds can be obtained directly from the
437 aggregate.
438
4392011-08-03 Ed Falis <falis@adacore.com>
440
441 * s-tasinf-vxworks.ads: Update comment to reflect 0 indexing of CPUs
442 on VxWorks SMP. Remove unusable constant ANY_CPU.
443
a96ca600
EB
4442011-08-03 Emmanuel Briot <briot@adacore.com>
445
446 * gnatcmd.adb, make.adb, prj-part.adb, prj-part.ads, prj-makr.adb,
447 clean.adb, prj-nmsc.adb, prj-pars.adb, prj-conf.adb, prj-env.adb,
448 prj-env.ads (Prj.Env.Initialize_Default_Project_Path,
449 Prj.Env.Initialize_Empty): new subprograms
450 (Get_Env, Find_Project): remove parameter Target_Name.
451
3e582869
AC
4522011-08-03 Gary Dismukes <dismukes@adacore.com>
453
454 * sem_ch3.adb (Build_Derived_Record_Type): Test the Derive_Subps formal
455 as a condition for the delayed call to Derived_Subprograms done for the
456 case of the rewriting of a derived type that constrains the
457 discriminants of its parent type.
458 Avoids redundant subprogram derivations for private subtype derivations.
459
4602011-08-03 Javier Miranda <miranda@adacore.com>
461
462 * exp_aggr.adb (Init_Hidden_Discriminants): New subprogram of
463 Build_Record_Aggr_Code.
464 (Build_Record_Aggr_Code): Add missing support to initialize hidden
465 discriminants in extension aggregates.
466
4672011-08-03 Emmanuel Briot <briot@adacore.com>
468
469 * prj-pp.adb (Print): also output project qualifiers, since in
470 particular "aggregate" is mandatory in an aggregate project.
471
4722011-08-03 Emmanuel Briot <briot@adacore.com>
473
474 * prj-part.adb, prj.adb, prj.ads, prj-nmsc.adb, prj-env.adb:
475 (Debug_Output): new function.
476
56e94186
AC
4772011-08-03 Eric Botcazou <ebotcazou@adacore.com>
478
479 * gnat_ugn.texi: Document -Wstack-usage.
480 * gcc-interface/misc.c (enumerate_modes): Add guard for ghost FP modes.
481
4822011-08-03 Thomas Quinot <quinot@adacore.com>
483
484 * sem_prag.adb Issue an error (not a warning) when a C++ type does not
485 have keyword LIMITED.
486
4872011-08-03 Yannick Moy <moy@adacore.com>
488
489 * alfa.adb, alfa.ads, alfa_test.adb: New files.
490 * ali.adb (Known_ALI_Lines): add 'C' lines (SCO) and 'F' lines (ALFA)
491 (Scan_ALI): do not issue a fatal error if parsing known lines after Xref
492 section (does not happen in compiler, only if code directly calls
493 Scan_ALI).
494 * get_alfa.adb, get_alfa.ads: New files.
495 * lib-writ.adb, lib-writ.ads (Write_ALI): output ALFA information if
496 needed.
497 * lib-xref-alfa.adb: New file.
498 * lib-xref.adb, lib-xref.ads
499 (Xref_Entry): redefine information needed in cross-references for ALFA.
500 Push ALFA treatments in separated local package.
501 (Enclosing_Subpragram_Or_Package): treat specially subprogram
502 identifiers. Return entity of package body instead of spec. Return
503 Empty for a scope with no location.
504 (Generate_Reference): adapt to new components for ALFA information.
505 Remove the need for D references on definitions.
506 (Is_Local_Reference): moved to ALFA local package
507 (Output_References): extract subfunction as Extract_Source_Name
508 (Output_Local_References): remove procedure, replaced by filtering of
509 cross-references in package ALFA and printing in Put_ALFA.
510 (Write_Entity_Name): remove procedure
511 * lib.adb, lib.ads (Extract_Source_Name): extract here function to
512 print exact name of entity as it appears in source file
513 (Unit_Ref_Table): make type public for use in Lib.Xref.ALFA
514 * put_alfa.adb, put_alfa.ads: New files.
515 * xref_lib.adb (Search_Xref): protect read of cross-references against
516 reading other sections of the ALI file, in gnatxref
517 (Search): protect read of cross-references against reading other
518 sections of the ALI file, in gnatfind.
519 * gcc-interface/Make-lang.in: Update dependencies.
520
5212011-08-03 Thomas Quinot <quinot@adacore.com>
522
523 * sem_ch3.adb: Minor reformatting.
524
5252011-08-03 Jose Ruiz <ruiz@adacore.com>
526
527 * s-inmaop-vxworks.adb (Setup_Interrupt_Mask): Do nothing instead of
528 raising an exception.
529
5302011-08-03 Ed Schonberg <schonberg@adacore.com>
531
532 * sem_res.adb (Set_String_Literal_Subtype): if index type is an integer
533 type, always use 1 as the lower bound or string, even if lower bound of
534 context is not static, to handle properly null strings in a non-static
535 context.
536
5372011-08-03 Bob Duff <duff@adacore.com>
538
539 * sem_prag.adb (Resolve_Aggregate): An array aggregate with 'others' is
540 always legal on the right-hand side of an assignment statement; there
541 is always an applicable index constraint in this case. Therefore, the
542 check for Pkind = N_Assignment_Statement is now unconditional -- it
543 doesn't depend on whether Is_Constrained (Typ).
544
4317e442
AC
5452011-08-03 Robert Dewar <dewar@adacore.com>
546
547 * exp_ch5.adb, sem_prag.adb, exp_ch4.adb: Minor reformatting.
548
5492011-08-03 Ed Schonberg <schonberg@adacore.com>
550
551 * sem_ch3.adb (Build_Itype_Reference): do not create an itype reference
552 for an itype created within a generic unit.
553
5542011-08-03 Eric Botcazou <ebotcazou@adacore.com>
555
556 * gnat_ugn.texi (Switches for gcc): Make it clearer that -fno-inline
557 suppresses all inlining.
558
53f29d4f
AC
5592011-08-03 Robert Dewar <dewar@adacore.com>
560
561 * sem_ch3.adb, sem_res.adb, exp_ch13.adb, exp_disp.adb,
562 exp_aggr.adb: Minor reformatting.
563
5642011-08-03 Thomas Quinot <quinot@adacore.com>
565
566 * exp_ch5.adb (Expand_N_Assignment_Statement): Do not force inlining of
567 tagged assignment when discriminant checks are suppressed. This is
568 useless and extremely costly in terms of static stack usage.
569
5702011-08-03 Bob Duff <duff@adacore.com>
571
572 * sem_prag.adb (Get_Base_Subprogram): Do not follow Alias for instances
573 of generics, because this leads to the wrong entity in the wrong scope,
574 causing (e.g.) pragma Export_Procedure to get an error if the entity is
575 an instance.
576 (Process_Interface_Name): Follow Alias for instances of generics, to
577 correct for the above change.
578
5792011-08-03 Ed Schonberg <schonberg@adacore.com>
580
581 * exp_ch4.adb (Expand_N_Selected_Component): If the discriminant value
582 is an integer literal it is always safe to replace the reference. In
583 addition, if the reference appears in the generated code for an object
584 declaration it is necessary to copy because otherwise the reference
585 might be to the uninitilized value of the discriminant of the object
586 itself.
587
5882011-08-03 Pascal Obry <obry@adacore.com>
589
590 * adaint.c (__gnat_is_executable_file_attr): Fix Win32 circuitry when no
591 ACL used, in this case we want to check for ending .exe, not .exe
592 anywhere in the path.
593
5942011-08-03 Sergey Rybin <rybin@adacore.com>
595
596 * tree_io.ads (ASIS_Version_Number): Update because of the changes in
597 the tree structure (semantic decoration of references to record
598 discriminants).
599
c0b11850
AC
6002011-08-03 Gary Dismukes <dismukes@adacore.com>
601
602 * sem_aggr.adb (Analyze_Array_Aggregate): When checking the discrete
603 choices of a named array aggregate, bail out when any choices are
604 marked as Errors_Posted.
605
6062011-08-03 Ed Schonberg <schonberg@adacore.com>
607
608 * exp_ch13.adb (Expand_N_Freeze_Entity): cleanup determination of scope
609 in which entity is frozen, to handle properly loop variables in
610 iterators.
611
6122011-08-03 Ed Schonberg <schonberg@adacore.com>
613
614 * sem_res.adb (Set_String_Literal_Subtype): if the lower bound of the
615 subtype is not static, compute the upper bound using attributes, to
616 handle properly index types that are not integer types.
617
6182011-08-03 Bob Duff <duff@adacore.com>
619
620 * gnat_rm.texi, gnat_ugn.texi: Fix some dangling URLs.
621 Update copyright notice.
622
6232011-08-03 Ed Schonberg <schonberg@adacore.com>
624
625 * sem_ch3.adb (Build_Discriminant_Constraints): Only use
626 Original_Discriminant if within an instance.
627 * sem_ch4.adb (Analyze_Selected_Component): Ditto.
628
6292011-08-03 Thomas Quinot <quinot@adacore.com>
630
631 * einfo.ads: Minor reformatting.
632
6332011-08-03 Ed Schonberg <schonberg@adacore.com>
634
635 * exp_disp.adb (Check_Premature_Freezing): diagnose the presence of a
636 composite type with an unfrozen subcomponent, in the profile of a
637 primitive operation.
638
5c34e9cd
AC
6392011-08-03 Robert Dewar <dewar@adacore.com>
640
641 * sem_util.ads, exp_aggr.adb, exp_ch3.adb: Minor reformatting.
642
6432011-08-03 Ed Schonberg <schonberg@adacore.com>
644
645 * sem_ch3.adb (Analyze_Object_Declaration): if a constant object of an
646 unconstrained type with discriminants is initialized with an aggregate,
647 use the constrained subtype of the aggregate as the type of the object,
648 because it is immutable, and this allows the back-end to generate no
649 code for the object declaration.
650
abcd9db2
AC
6512011-08-03 Robert Dewar <dewar@adacore.com>
652
653 * exp_ch4.adb (Optimize_Length_Check): Fix bad handling of case where
654 comparison operand is variable, and turns out to be zero or negative.
655
6562011-08-03 Javier Miranda <miranda@adacore.com>
657
658 * exp_intr.adb
659 (Expand_Dispatching_Constructor_Call): Disable expansion of
660 code required for native targets. Done to avoid generating
661 references to unavailable runtime entities in VM targets.
662 * exp_ch3.adb
663 (Expand_N_Object_Declaration): Add missing support to handle
664 the explicit initialization of class-wide interface objects.
665 Fix documentation.
666
6672011-08-03 Matthew Heaney <heaney@adacore.com>
668
669 * a-cobove.adb (Merge): Move source onto target, instead of using Assign
670
6712011-08-03 Matthew Heaney <heaney@adacore.com>
672
673 * a-cbdlli.adb (Splice): move source items from first to last
674
6752011-08-03 Yannick Moy <moy@adacore.com>
676
677 * sem_util.ads: comment added.
678
6792011-08-03 Javier Miranda <miranda@adacore.com>
680
681 * exp_aggr.adb
682 (Expand_Record_Aggregate): In VM targets disable the expansion into
683 assignments of aggregates whose type is not known at compile time.
684
b474d6c3
ES
6852011-08-03 Ed Schonberg <schonberg@adacore.com>
686
687 * exp_ch9.adb (Build_Renamed_Formal_Declaration): common procedure for
688 protected entries and task entries, to build the proper renaming
689 declaration for entry formals, used in debugging.
690 * exp_ch2.adb (Expand_Entry_Parameter): handle task and entry
691 parameters in the same way.
692
0580d807
AC
6932011-08-02 Robert Dewar <dewar@adacore.com>
694
695 * a-direct.adb, sinfo.ads, exp_ch9.adb, scng.adb, sem_util.adb,
696 sem_util.ads, restrict.ads, par-prag.adb: Minor reformatting and/or
697 code reorganization.
698
6992011-08-02 Robert Dewar <dewar@adacore.com>
700
701 * debug.adb: Debug flag d.P to suppress length comparison optimization
702 * exp_ch4.adb (Optimize_Length_Comparison): New routine to optimize
703 comparison of Length by comparing First/Last instead.
704
7052011-08-02 Matthew Heaney <heaney@adacore.com>
706
707 * a-cobove.ads: Code clean up.
708
b191a125
AC
7092011-08-02 Vincent Celier <celier@adacore.com>
710
711 * adaint.c (file_names_case_sensitive_cache): New static int.
712 (__gnat_get_file_names_case_sensitive): Cache the return value in
713 file_names_case_sensitive_cache at the first invocation, to avoid
714 multiple calls to getenv.
715
7162011-08-02 Bob Duff <duff@adacore.com>
717
718 * sem_ch12.adb (Validate_Derived_Type_Instance): Implement AI05-0218-1.
719
316a0661
AC
7202011-08-02 Yannick Moy <moy@adacore.com>
721
722 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_prag.adb, sem.ads,
723 sem_util.adb, sem_util.ads, sem_res.adb, sem_ch2.adb, sem_ch4.adb,
724 sem_ch6.adb, sem_ch11.adb: Add semantic flag In_Pre_Post_Expression to
725 indicate that we are in a precondition or postcondition. This is used in
726 Mark_Non_ALFA_Subprogram (renaming of Mark_Non_ALFA_Subprogram_Body) to
727 decide whether to flag the spec or body of the current subprogram as
728 not in ALFA.
729
7302011-08-02 Fabien Chouteau <chouteau@adacore.com>
731
732 * impunit.adb: Add Ada.Execution_Time.Interrupts in the Ada2012 package
733 list.
734 * a-extiin.ads: New file.
735
7362011-08-02 Bob Duff <duff@adacore.com>
737
738 * a-direct.adb (Rename): Implement AI05-0231-1. In particular, Rename
739 now raises Name_Error instead of Use_Error in certain cases. The other
740 parts of this AI were already implemented properly.
741
f9adb9d4
AC
7422011-08-02 Vincent Celier <celier@adacore.com>
743
744 * link.c: Only import "auto-host.h" when building the gnattools.
745
7462011-08-02 Yannick Moy <moy@adacore.com>
747
748 * sem_util.adb: Inter-unit inlining does not work for a subprogram
749 which calls a local subprogram, so extract subprogram
750 from Mark_Non_ALFA_Subprogram_Body.
751
7522011-08-02 Javier Miranda <miranda@adacore.com>
753
754 * exp_ch9.adb
755 (Extract_Dispatching_Call): If the type of the dispatching object is an
756 access type then return an explicit dereference in the Object out-mode
757 parameter.
758
7592011-08-02 Gary Dismukes <dismukes@adacore.com>
760
761 * sem_ch3.adb (Analyze_Subtype_Declaration): Generate range
762 compatibility checks for all indexes of an array subtype, not just the
763 first. Reset Has_Dynamic_Range_Check on the subtype before each
764 potential check to ensure that Insert_Range_Checks will not elide any
765 of the dynamic checks.
766
7672011-08-02 Yannick Moy <moy@adacore.com>
768
769 * par-prag.ad (Process_Restrictions_Or_Restriction_Warnings): recognize
770 SPARK restriction at parsing time.
771 * scng.adb (Scan): Generate a token Tok_SPARK_Hide for a SPARK HIDE
772 directive only if the SPARK restriction is set for this unit.
773
83f33150
YM
7742011-08-02 Yannick Moy <moy@adacore.com>
775
776 * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb, sem_util.ads,
777 sem_res.adb, sem_ch2.adb, sem_ch4.adb, sem_ch6.adb,
778 sem_ch11.adb: Protect call to Current_Subprogram which might be costly
779 when repeated. Rename Current_Subprogram_Is_Not_In_ALFA into
780 Mark_Non_ALFA_Subprogram_Body.
781 Split body of Mark_Non_ALFA_Subprogram_Body to get body small and
782 inlined.
783
7b98672f
YM
7842011-08-02 Yannick Moy <moy@adacore.com>
785
786 * sem_res.adb: Protect calls to Matching_Static_Array_Bounds which
787 might be costly.
788
052e0603
AC
7892011-08-02 Robert Dewar <dewar@adacore.com>
790
791 * exp_ch9.adb, exp_sel.adb, restrict.ads, exp_disp.adb, erroutc.ads,
792 exp_ch3.adb: Minor reformatting.
793
7942011-08-02 Emmanuel Briot <briot@adacore.com>
795
796 * adaint.c (__gnat_locate_exec_on_path): only returns executable
797 files, not any regular file.
798 (__gnat_locate_file_with_predicate): new subprogram.
799
8002011-08-02 Yannick Moy <moy@adacore.com>
801
802 * sinfo.adb, sinfo.ads: Restrict the use of flags
803 Has_Dynamic_Length_Check and Has_Dynamic_Range_Check to expression
804 nodes, plus N_Subtype_Declaration for the 2nd one.
805
4fbad0ba
AC
8062011-08-02 Sergey Rybin <rybin@adacore.com>
807
808 * gnat_rm.texi: Ramification of pragma Eliminate documentation
809 - fix bugs in the description of Source_Trace;
810 - get rid of UNIT_NAME;
811
052e0603
AC
8122011-08-02 Javier Miranda <miranda@adacore.com>
813
814 * exp_ch9.adb
815 (Build_Dispatching_Requeue): Adding support for VM targets
816 since we cannot directly reference the Tag entity.
817 * exp_sel.adb (Build_K): Adding support for VM targets.
818 (Build_S_Assignment): Adding support for VM targets.
819 * exp_disp.adb
820 (Default_Prim_Op_Position): In VM targets do not restrict availability
821 of predefined interface primitives to compiling in Ada 2005 mode.
822 (Is_Predefined_Interface_Primitive): In VM targets this service is not
823 restricted to compiling in Ada 2005 mode.
824 (Make_VM_TSD): Generate code that declares and initializes the OSD
825 record. Needed to support dispatching calls through synchronized
826 interfaces.
827 * exp_ch3.adb
828 (Make_Predefined_Primitive_Specs): Enable generation of predefined
829 primitives associated with synchronized interfaces.
830 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
831 primitives associated with synchronized interfaces.
832
8332011-08-02 Yannick Moy <moy@adacore.com>
834
835 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
836 statements hidden in SPARK if preceded by the HIDE directive
837 (Parse_Exception_Handlers): mark each exception handler in a sequence of
838 exception handlers as hidden in SPARK if preceded by the HIDE directive
839 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
840 if starting with the HIDE directive
841 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
842 starting with the HIDE directive; mark the declarations in a private
843 part as hidden in SPARK if the private part starts with the HIDE
844 directive
845 * restrict.adb, restrict.ads
846 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
847 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
848 argument node belongs to a part which is hidden in SPARK
849 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
850 parts in SPARK; protect the possibly costly call to
851 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
852 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
853 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
854 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
855 Tok_SPARK_Hide.
856 (Scan): recognize special comment starting with '#' and followed by
857 SPARK keyword "hide" as a HIDE directive.
858
8592011-08-02 Yannick Moy <moy@adacore.com>
860
861 * types.ads, erroutc.ads: Minor reformatting.
862
8632011-08-02 Vincent Celier <celier@adacore.com>
864
865 * link.c: Add response file support for cross platforms.
866
8672011-08-02 Ed Schonberg <schonberg@adacore.com>
868
869 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
870 in an association, set parent field of copy before partial analysis.
871 * sem_res.adb (Resolve_Slice): create reference to itype only when
872 expansion is enabled.
873
8742011-08-02 Yannick Moy <moy@adacore.com>
875
876 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
877 for new flag denoting which subprogram bodies are in ALFA
878 * restrict.adb, sem_ch7.adb: Update comment
879 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
880 sem_ch9.adb, sem_res.adb: Add calls to
881 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
882 * sem_ch6.adb (Analyze_Function_Return): add calls to
883 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
884 middle of the body, and extended return.
885 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
886 False when missing return.
887 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
888 to True for subprograms whose spec is in ALFA. Remove later on the flag
889 on the entity used for a subprogram body when there exists a separate
890 declaration.
891 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
892 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
893 False, otherwise do nothing.
894
8952011-08-02 Robert Dewar <dewar@adacore.com>
896
897 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
898
8992011-08-02 Yannick Moy <moy@adacore.com>
900
901 * sem_ch4.ads: minor formatting.
902
9032011-08-02 Yannick Moy <moy@adacore.com>
904
905 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
906 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
907 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
908 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
909 opt.ads: cleanup of SPARK mode
910
9112011-08-02 Yannick Moy <moy@adacore.com>
912
913 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
914 types.
915 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
916 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
917 * sem_ch3.adb
918 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
919 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
920 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
921 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
922 types.
923 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
924 non-static range.
925 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
926 functions whose return type is not in ALFA.
927 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
928 specifications.
929 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
930 parameter's type is not in ALFA.
931 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
932 types are in ALFA.
933
9342011-08-02 Ed Schonberg <schonberg@adacore.com>
935
936 * sem_ch6 (Analyze_Expression_Function): treat the function as
937 Inline_Always, and introduce a subprogram declaration for it when it is
938 not a completion.
939 * inline.adb (Add_Inlined_Body): recognize bodies that come from
940 expression functions, so that the back-end can determine whether they
941 can in fact be inlined.
942 * sem_util.adb (Is_Expression_Function): predicate to determine whether
943 a function body comes from an expression function.
944
9452011-08-02 Gary Dismukes <dismukes@adacore.com>
946
947 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
948 null exclusions to test Can_Never_Be_Null on the anonymous access types
949 of the formals rather than testing the formals themselves. Exclude this
950 check in cases where the Old_Formal is marked as a controlling formal,
951 to avoid issuing spurious errors for bodies completing dispatching
952 operations (due to the flag not getting set on controlling access
953 formals in body specs).
954 (Find_Corresponding_Spec): When checking full and subtype conformance of
955 subprogram bodies in instances, pass Designated and E in that order, for
956 consistency with the expected order of the formals (New_Id followed by
957 Old_Id).
958
9592011-08-02 Robert Dewar <dewar@adacore.com>
960
961 * sem_ch8.adb: Minor reformatting.
962
9632011-08-02 Ed Schonberg <schonberg@adacore.com>
964
965 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
966 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
967 primitive operations of class-wide actuals.
968
9692011-08-02 Javier Miranda <miranda@adacore.com>
970
971 * exp_atag.ads, exp_atag.adb
972 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
973 since its value is implicitly passed in argument Typ.
974 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
975 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
976 Build_Common_Dispatching_Select_Statements.
977
9782011-08-02 Robert Dewar <dewar@adacore.com>
979
980 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
981 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
982 Minor reformatting.
983
9842011-08-02 Robert Dewar <dewar@adacore.com>
985
986 * sem_res.adb: Minor reformatting.
987 * sem_prag.adb: Minor reformatting.
988
9892011-08-02 Javier Miranda <miranda@adacore.com>
990
991 * exp_atag.adb, exp_atags.ads
992 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
993 by the tagged type Entity. Required to use this routine in the VM
994 targets since we do not have available the Tag entity in the VM
995 platforms.
996 * exp_ch6.adb
997 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
998 Ada.Tags has not been previously loaded.
999 * exp_ch7.adb
1000 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
1001 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
1002 * sem_aux.adb
1003 (Enclosing_Dynamic_Scope): Add missing support to handle the full
1004 view of enclosing scopes. Required to handle enclosing scopes that
1005 are synchronized types whose full view is a task type.
1006 * exp_disp.adb
1007 (Build_VM_TSDs): Minor code improvement to avoid generating and
1008 analyzing lists with empty nodes.
1009 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
1010 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
1011 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
1012 (Make_Disp_Timed_Select_Body): Add support for VM targets.
1013 (Make_Select_Specific_Data_Table): Add support for VM targets.
1014 (Make_VM_TSD): Generate code to initialize the SSD structure of
1015 the TSD.
1016
10172011-08-02 Yannick Moy <moy@adacore.com>
1018
1019 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
1020 cross-references section in ALI.
1021 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
1022 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
1023 Sub).
1024 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
1025 subprogram or package entity of a node
1026 (Is_Local_Reference_Type): new function returns True for references
1027 selected in local cross-references.
1028 (Lt): function extracted from Lt in Output_References
1029 (Write_Entity_Name): function extracted from Output_References
1030 (Generate_Definition): generate reference with type 'D' for definition
1031 of objects (object declaration and parameter specification), with
1032 appropriate locations and units, for use in local cross-references.
1033 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
1034 references of type 'I' for initialization in object definition.
1035 (Output_References): move part of function Lt and procedure
1036 Write_Entity_Name outside of the body. Ignore references of types 'D'
1037 and 'I' introduced for local cross-references.
1038 (Output_Local_References): new procedure to output the local
1039 cross-references sections.
1040 (Lref_Entity_Status): new array defining whether an entity is a local
1041 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
1042 with 'I' type when initialization expression is present.
1043 * get_scos.adb, get_scos.ads: Correct comments and typos
1044
10452011-08-02 Javier Miranda <miranda@adacore.com>
1046
1047 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
1048 the JVM target.
1049 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
1050 the JVM target.
1051 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
1052 TSD support.
1053
10542011-08-02 Vincent Celier <celier@adacore.com>
1055
1056 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
1057 (No_Space_Img): New function
1058 (Find_Excluded_Sources): When reading from a file, record the file name
1059 and the line number for each excluded source.
1060 (Mark_Excluded_Sources): When reporting an error, if the excluded
1061 sources were read from a file, include file name and line number in
1062 the error message.
1063
10642011-08-02 Ed Schonberg <schonberg@adacore.com>
1065
1066 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
1067
10682011-08-02 Robert Dewar <dewar@adacore.com>
1069
1070 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
1071
10722011-08-02 Javier Miranda <miranda@adacore.com>
1073
1074 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
1075 generation of TSDs to the DOTNET compiler.
1076 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
1077 generation of TSDs to the DOTNET compiler.
1078
10792011-08-02 Javier Miranda <miranda@adacore.com>
1080
1081 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
1082 record of all the tagged types declared inside library level package
1083 declarations, library level package bodies or library level subprograms.
1084 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
1085 associated with a given tagged type.
1086 (Build_VM_TSDs): New subprogram.
1087 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
1088 compilation units that are subprograms.
1089 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
1090 compilation units that are package bodies.
1091 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
1092 units that are a package declaration or a package instantiation.
1093 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
1094 reorganization to improve the error generated by the frontend when the
1095 function Ada.Tags.Secondary_Tag is not available.
1096 * rtsfind.ads (RE_Register_TSD): New runtime entity.
1097 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
1098
10992011-08-02 Javier Miranda <miranda@adacore.com>
1100
1101 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
1102
11032011-08-02 Robert Dewar <dewar@adacore.com>
1104
1105 * s-imenne.ads: Minor reformatting.
1106
11072011-08-02 Robert Dewar <dewar@adacore.com>
1108
1109 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
1110 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
1111 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
1112
11132011-08-02 Robert Dewar <dewar@adacore.com>
1114
1115 * einfo.ads (Materialize_Entity): Document this is only for renamings
1116 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
1117 required debug information in the case where we transform the object
1118 declaration into a renaming declaration.
1119 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
1120 object
1121 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
1122 Materialize_Entity.
1123
11242011-08-02 Robert Dewar <dewar@adacore.com>
1125
1126 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
1127 Suppress_Init_Procs.
1128 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
1129 Suppress_Initialization/Initialization_Suppressed.
1130 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
1131 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
1132 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
1133 * sem_prag.adb: New processing for pragma Suppress_Initialization.
1134
11352011-08-02 Robert Dewar <dewar@adacore.com>
1136
1137 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
1138 Minor reformatting.
1139
11402011-08-02 Ed Schonberg <schonberg@adacore.com>
1141
1142 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
1143 only have inheritable classwide pre/postconditions.
1144
11452011-08-02 Javier Miranda <miranda@adacore.com>
1146
1147 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
1148 * rtsfind.ads (RE_Check_TSD): New runtime entity.
1149 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
1150 checks if the external tag of a type is the same as the external tag
1151 of some other declaration.
1152
11532011-08-02 Thomas Quinot <quinot@adacore.com>
1154
1155 * s-taskin.ads: Minor reformatting.
1156
11572011-08-02 Emmanuel Briot <briot@adacore.com>
1158
1159 * g-comlin.adb (Display_Help): swap the order in which it prints the
1160 short help and the general usage.
1161
11622011-08-02 Ed Schonberg <schonberg@adacore.com>
1163
1164 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
1165 the aspect declarations and attach them to the generic copy for
1166 subsequent analysis.
1167 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
1168 declarations of the generic tree to the new subprogram declarations.
1169 * sem_attr.adb (Check_Precondition_Postcondition): recognize
1170 conditions that apply to a subprogram instance.
1171
11722011-08-02 Robert Dewar <dewar@adacore.com>
1173
1174 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
1175
11762011-08-02 Ed Schonberg <schonberg@adacore.com>
1177
1178 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
1179 private type with a tagged full view is not derived in the immediate
1180 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
1181
11822011-08-02 Robert Dewar <dewar@adacore.com>
1183
1184 * exp_ch4.adb: Minor reformatting.
1185
11862011-08-02 Ed Schonberg <schonberg@adacore.com>
1187
1188 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
1189 Ada2012 iterator, the loop will be rewritten during expansion into a
1190 while loop with a cursor and an element declaration. Do not analyze the
1191 body in this case, because if the container is for indefinite types the
1192 actual subtype of the elements will only be determined when the cursor
1193 declaration is analyzed.
1194
11952011-08-02 Arnaud Charlet <charlet@adacore.com>
1196
1197 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
1198 size/alignment related attributes in CodePeer_Mode.
1199
12002011-08-02 Gary Dismukes <dismukes@adacore.com>
1201
1202 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
1203 Prepend_Element, since this can result in the operation getting the
1204 wrong slot in the full type's dispatch table if the full type has
1205 inherited operations. The incomplete type's operation will get added
1206 to the proper position in the full type's primitives
1207 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
1208 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
1209 dispatching operations, since there are cases where nonprimitive
1210 subprograms can get added to the list of incomplete dependents (such
1211 as subprograms in nested packages).
1212 * sem_ch6.adb (Process_Formals): First, remove test for being in a
1213 private part when determining whether to add a primitive with a
1214 parameter of a tagged incomplete type to the Private_Dependents list.
1215 Such primitives can also occur in the visible part, and should not have
1216 been excluded from being private dependents.
1217 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
1218 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
1219 list of a Taft-amendment incomplete type is a primitive before issuing
1220 an error that the full type must appear in the same unit. There are
1221 cases where nonprimitives can be in the list (such as subprograms in
1222 nested packages).
1223 * sem_disp.adb (Derives_From): Use correct condition for checking that
1224 a formal's type is derived from the type of the corresponding formal in
1225 the parent subprogram (the condition was completely wrong). Add
1226 checking that was missing for controlling result types being derived
1227 from the result type of the parent operation.
1228
12292011-08-02 Yannick Moy <moy@adacore.com>
1230
1231 * errout.adb (First_Node): minor renaming
1232 * restrict.adb (Check_Formal_Restriction): put restriction warning on
1233 first node.
1234
12352011-08-02 Yannick Moy <moy@adacore.com>
1236
1237 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
1238 before accessing operands.
1239 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
1240 decide whether an initialization expression respects SPARK rules, as
1241 the plain node is the expanded one. This allows for more valid warnings
1242 to be issued.
1243 * gnat_rm.texi: Minor update.
1244
12452011-08-02 Arnaud Charlet <charlet@adacore.com>
1246
1247 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
1248 previous change.
1249
12502011-08-02 Robert Dewar <dewar@adacore.com>
1251
1252 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
1253
12542011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
1255
1256 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
1257 loop statements and the element renaming declaration with a block when
1258 the element type is controlled.
1259
12602011-08-02 Yannick Moy <moy@adacore.com>
1261
1262 * sinfo.ads: Minor formatting.
1263
12642011-08-02 Ed Schonberg <schonberg@adacore.com>
1265
1266 * sem_aggr.adb (Add_Association): if the association has a box and no
1267 expression, use the Sloc of the aggregate itself for the new
1268 association.
1269 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
1270 the Original_Node.
1271
12722011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
1273
1274 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
1275 When a container is provided via a function call, generate a renaming
1276 of the function result. This avoids the creation of a transient scope
1277 and the premature finalization of the container.
1278 * exp_ch7.adb (Is_Container_Cursor): Removed.
1279 (Wrap_Transient_Declaration): Remove the supression of the finalization
1280 of the list controller when the declaration denotes a container cursor,
1281 it is not needed.
1282
12832011-08-02 Yannick Moy <moy@adacore.com>
1284
1285 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
1286 node is from source, instead of the original node being from source.
1287 * sem_aggr.adb
1288 (Resolve_Array_Aggregate): refine the check for a static expression, to
1289 recognize also static ranges
1290 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
1291 Array_Type_Declaration): postpone the test for the type being a subtype
1292 mark after the type has been resolved, so that component-selection and
1293 expanded-name are discriminated.
1294 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
1295 to distinguish the case of an iteration scheme, so that an error is
1296 issed on a non-static range in SPARK except in an iteration scheme.
1297 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
1298 In_Iter_Schm = True.
1299 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
1300 user-defined operators so that they are allowed in renaming
1301 * sem_ch8.adb
1302 (Find_Selected_Component): refine the check for prefixing of operators
1303 so that they are allowed in renaming. Move the checks for restrictions
1304 on selector name after analysis discriminated between
1305 component-selection and expanded-name.
1306 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
1307 concatenation argument of string type if it is static.
1308 * sem_util.adb, sem_util.ads
1309 (Check_Later_Vs_Basic_Declarations): add a new function
1310 Is_Later_Declarative_Item to decice which declarations are allowed as
1311 later items, in the two different modes Ada 83 and SPARK. In the SPARK
1312 mode, add that renamings are considered as later items.
1313 (Enclosing_Package): new function to return the enclosing package
1314 (Enter_Name): correct the rule for homonyms in SPARK
1315 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
1316 from source (result of expansion) to avoid issuing wrong warnings.
1317
13182011-08-02 Ed Schonberg <schonberg@adacore.com>
1319
1320 * errout.adb: On anything but an expression First_Node returns its
1321 argument.
1322
13232011-08-02 Pascal Obry <obry@adacore.com>
1324
1325 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
1326
13272011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
1328
1329 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
1330 Set the associated loop as the related expression of internally
1331 generated cursors.
1332 * exp_ch7.adb (Is_Container_Cursor): New routine.
1333 (Wrap_Transient_Declaration): Supress the finalization of the list
1334 controller when the declaration denotes a container cursor.
1335
13362011-08-02 Yannick Moy <moy@adacore.com>
1337
1338 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
1339 command line now.
1340 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
1341 expression is a simple expression. This check cannot be performed in
1342 the semantics, so just drop it.
1343 (P_Index_Or_Discriminant_Constraint): move check that the index or
1344 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
1345 semantics. Other cases were previously checked in the semantics.
1346 * par-ch4.adb (P_Name): move checks that a selector name is not
1347 character literal or an operator symbol to Find_Selected_Component in
1348 the semantics
1349 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
1350 declarations are not placed after later declarations in a separate
1351 procedure in Sem_Util (possibly not the best choice?), to be used both
1352 during parsing, for Ada 83 mode, and during semantic analysis, for
1353 SPARK mode.
1354 * par-endh.adb (Check_End): move check that end label is not missing
1355 to Process_End_Label in the semantics
1356 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
1357 the special case for SPARK restriction
1358 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
1359 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
1360 parameter Force to issue the error message even on internal node (used
1361 for generated end label). Call Check_Restriction to check when an error
1362 must be issued. In SPARK mode, issue an error message even if the
1363 restriction is not set.
1364 (Check_Restriction): new procedure with an additional out parameter to
1365 inform the caller that a message has been issued
1366 * sem_aggr.adb: Minor modification of message
1367 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
1368 instead of issuing an error message directly
1369 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
1370 declarations are not placed after later declarations, by calling
1371 Check_Later_Vs_Basic_Declarations
1372 (Analyze_Subtype_Declaration): move here the check that an index or
1373 discriminant constraint must be a subtype mark. Change the check that
1374 a subtype of String must start at one so that it works on subtype marks.
1375 * sem_ch4.adb (Analyze_Call): move here the check that a named
1376 association cannot follow a positional one in a call
1377 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
1378 instead of issuing an error message directly
1379 * sem_ch8.adb (Find_Selected_Component): move here the check that a
1380 selector name is not a character literal or an operator symbol. Move
1381 here the check that the prefix of an expanded name cannot be a
1382 subprogram or a loop statement.
1383 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
1384 procedure called from parsing and semantics to check that basic
1385 declarations are not placed after later declarations
1386 (Process_End_Label): move here the check that end label is not missing
1387
13882011-08-02 Arnaud Charlet <charlet@adacore.com>
1389
1390 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
1391 representation clause in codepeer mode, since it confuses CodePeer and
1392 does not bring useful info.
1393
13942011-08-02 Ed Falis <falis@adacore.com>
1395
1396 * init.c: initialize fp hw on MILS.
1397
13982011-08-02 Ed Schonberg <schonberg@adacore.com>
1399
1400 * errout.adb (First_Node): for bodies, return the node itself (small
1401 optimization). For other nodes, do not check source_unit if the node
1402 comes from Standard.
1403
14042011-08-02 Robert Dewar <dewar@adacore.com>
1405
1406 * exp_ch3.adb: Minor comment additions.
1407 * sem_ch13.adb: Minor reformatting.
1408
14092011-08-02 Pascal Obry <obry@adacore.com>
1410
1411 * make.adb, makeutl.adb: Removes some superfluous directory separator.
1412
14132011-08-02 Robert Dewar <dewar@adacore.com>
1414
1415 * sem_attr.adb: Minor reformatting.
1416
14172011-08-02 Robert Dewar <dewar@adacore.com>
1418
1419 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
1420 (Has_Default_Component_Value): Removed
1421 * einfo.ads Comment updates
1422 (Has_Default_Aspect): Replaces Has_Default_Value
1423 (Has_Default_Component_Value): Removed
1424 * exp_ch13.adb
1425 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
1426 * exp_ch3.adb
1427 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
1428 (Get_Simple_Init_Val): Handle Default_Value aspect
1429 (Needs_Simple_Initialization): Handle Default_Value aspect
1430 * exp_ch3.ads: Needs_Simple_Initialization
1431 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
1432 * par-prag.adb (Pragma_Default[_Component]Value) Removed
1433 * sem_ch13.adb
1434 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
1435 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
1436 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
1437
14382011-08-02 Ed Schonberg <schonberg@adacore.com>
1439
1440 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
1441 package containing iteration primitives.
1442 exp_ch5.adb (Expand_Iterator_Loop): ditto.
1443
14442011-08-02 Ed Schonberg <schonberg@adacore.com>
1445
1446 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
1447 "of", pre-analyze expression in case it is a function call with
1448 finalization actions that must be placed ahead of the loop.
1449 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
1450 on an Ada2012 iterator, insert them ahead of the rewritten loop.
1451
14522011-08-02 Geert Bosch <bosch@adacore.com>
1453
1454 * cstand.adb (Create_Float_Types): Only consider C's long double for
1455 Long_Long_Float, in addition to double.
1456
14572011-08-02 Robert Dewar <dewar@adacore.com>
1458
1459 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
1460 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
1461 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
1462 Minor reformatting.
1463
14642011-08-02 Ed Schonberg <schonberg@adacore.com>
1465
1466 * sem_attr.adb: handle properly 'Result when it is a prefix of an
1467 indexed component.
1468
14692011-08-02 Javier Miranda <miranda@adacore.com>
1470
1471 * einfo.ads, einfo.adb
1472 (Original_Access_Type): Move this attribute to Node26 since there was
1473 an undocumented use of Node21 in E_Access_Subprogram_Type entities
1474 which causes conflicts and breaks the generation of the .NET compiler.
1475 (Interface_Name): Add missing documentation on JGNAT only uses of
1476 this attribute.
1477
14782011-08-02 Geert Bosch <bosch@adacore.com>
1479
1480 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
1481 (Find_Back_End_Float_Type): Likewise
1482 (Create_Back_End_Float_Types): Likewise
1483 (Create_Float_Types): Likewise
1484 (Register_Float_Type): Likewise
1485 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
1486 Nlist and split out type selection in new local Find_Base_Type function.
1487 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
1488 Nlist
1489 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
1490
14912011-08-02 Robert Dewar <dewar@adacore.com>
1492
1493 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
1494 alpha order).
1495 * opt.ads: Minor comment change.
1496 * sem_ch12.adb: Minor code reorganization.
1497
14982011-08-02 Gary Dismukes <dismukes@adacore.com>
1499
1500 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
1501 subtype's list of rep items to the list on the full subtype in the case
1502 where the lists are the same.
1503
15042011-08-02 Geert Bosch <bosch@adacore.com>
1505
1506 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
1507 using the one from System.Strings, which also deallocates all strings.
1508
15092011-08-02 Geert Bosch <bosch@adacore.com>
1510
1511 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
1512 function.
1513 * gcc-interface/Make-lang.in: Update dependencies.
1514
15152011-08-02 Olivier Hainque <hainque@adacore.com>
1516
1517 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
1518 end_locus.
1519
15202011-08-02 Javier Miranda <miranda@adacore.com>
1521
1522 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
1523 associated with anonymous access to subprograms.
1524
15252011-08-02 Geert Bosch <bosch@adacore.com>
1526
1527 * opt.ads
1528 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
1529 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
1530 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
1531 (Add_Symbol_Definition): Move to switch-c.adb
1532 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
1533 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
1534 (Add_Symbol_Definition): Move to switch-c.adb.
1535 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
1536 * sem_warn.adb
1537 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
1538 Move to warnsw.adb.
1539 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
1540 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
1541 Move to warnsw.adb.
1542 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
1543 (Add_Symbol_Definition): Moved from Prepcomp.
1544 * switch-c.ads: Update copyright notice. Use String_List instead of
1545 Argument_List, removing dependency on System.OS_Lib.
1546
15472011-08-02 Yannick Moy <moy@adacore.com>
1548
1549 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
1550 mode on initialization expression which does not respect SPARK
1551 restrictions.
1552 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
1553 if the tree referenced by its argument represents an initialization
1554 expression in SPARK, suitable for initializing an object in an object
1555 declaration.
1556
15572011-08-02 Javier Miranda <miranda@adacore.com>
1558
1559 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
1560 internally generated access to subprogram with its associated protected
1561 subprogram type.
1562 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
1563
15642011-08-02 Geert Bosch <bosch@adacore.com>
1565
1566 * cstand.adb (Register_Float_Type): Print information about type to
1567 register, if the Debug_Flag_Dot_B is set.
1568 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
1569 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
1570 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
1571 with a requested precision of more than Max_Digits digits and no more
1572 than Max_Base_Digits digits, if a range specification is present and the
1573 Predefined_Float_Types list has a suitable type to derive from.
1574 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
1575 case of type completion with pragma Import
1576 * sem_prag.adb
1577 (Process_Import_Predefined_Type): Processing to complete a type
1578 with pragma Import. Currently supports floating point types only.
1579 (Set_Convention_From_Pragma): Do nothing without underlying type.
1580 (Process_Convention): Guard against absence of underlying type,
1581 which may happen when importing incomplete types.
1582 (Process_Import_Or_Interface): Handle case of importing predefined
1583 types. Tweak error message.
1584
15852011-08-02 Eric Botcazou <ebotcazou@adacore.com>
1586
1587 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
1588 functions to previous change. Reorganize code slightly.
1589
15902011-08-02 Geert Bosch <bosch@adacore.com>
1591
1592 * back_end.ads (Register_Type_Proc): New call back procedure type for
1593 allowing the back end to provide information about available types.
1594 (Register_Back_End_Types): New procedure to register back end types.
1595 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
1596 available types.
1597 * cstand.adb (Back_End_Float_Types): New list for floating point types
1598 supported by the back end.
1599 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
1600 (Copy_Float_Type): New procedure to make new copies of predefined types.
1601 (Register_Float_Type): New call back procedure to populate the BEFT list
1602 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
1603 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
1604 (Create_Float_Types): New procedure to create entities for floating
1605 point types predefined in Standard, and put these and any remaining
1606 BEFTs on the Predefined_Float_Types list.
1607 * stand.ads (Predefined_Float_Types): New list for predefined floating
1608 point types that do not have declarations in package Standard.
1609
16102011-08-02 Eric Botcazou <ebotcazou@adacore.com>
1611
1612 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
1613 entity node for the unit containing the parameter.
1614 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
1615 (Add_Inlined_Subprogram): Likewise.
1616 * gcc-interface/Make-lang.in: Update dependencies.
1617
16182011-08-02 Thomas Quinot <quinot@adacore.com>
1619
1620 * s-stusta.adb (Print): Make sure Pos is always initialized to a
1621 suitable value.
1622
16232011-08-02 Geert Bosch <bosch@adacore.com>
1624
1625 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
1626
16272011-08-02 Eric Botcazou <ebotcazou@adacore.com>
1628
1629 * sem_type.adb (Covers): Move trivial case to the top and reuse the
1630 computed value of Base_Type.
1631
16322011-08-02 Yannick Moy <moy@adacore.com>
1633
1634 * restrict.adb (Check_Restriction): issue an error for any use of
1635 class-wide, even if the No_Dispatch restriction is not set.
1636 * sem_aggr.adb: Correct typos in comments and messages in formal mode
1637 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
1638 when completing a private extension, the type named in the private part
1639 is not the same as that named in the visible part.
1640 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
1641 of an inherited primitive operations of a tagged type or type extension
1642 that returns the tagged type.
1643 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
1644 function which returns True for an implicit operation inherited by the
1645 derived type declaration for the argument type.
1646 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
1647 order.
1648
16492011-08-02 Ed Schonberg <schonberg@adacore.com>
1650
1651 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
1652 Process_Bounds, to perform analysis with expansion of a range or an
1653 expression that is the iteration scheme for a loop.
1654 (Analyze_Iterator_Specification): If domain of iteration is given by a
1655 function call with a controlled result, as is the case if call returns
1656 a predefined container, ensure that finalization actions are properly
1657 generated.
1658 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
1659
16602011-08-02 Javier Miranda <miranda@adacore.com>
1661
1662 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
1663 * gcc-interface/Make-lang.in: Update dependencies.
1664
16652011-08-02 Javier Miranda <miranda@adacore.com>
1666
1667 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
1668 determine if the analysis is performed using N or Original_Node (N).
1669 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
1670 functionality of routine Is_Variable avoids code duplication.
1671 * checks.adb (Determine_Range): Handle temporaries generated by
1672 Remove_Side_Effects.
1673
16742011-08-02 Javier Miranda <miranda@adacore.com>
1675
1676 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
1677 expansion of the condition. Required since the previous analysis was
1678 done with expansion disabled (see Resolve_Quantified_Expression) and
1679 hence checks were not inserted and record comparisons have not been
1680 expanded.
1681
16822011-08-02 Ed Falis <falis@adacore.com>
1683
1684 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
1685 Update header.
1686
16872011-08-02 Bob Duff <duff@adacore.com>
1688
1689 * opt.ads: Minor comment fix.
1690
16912011-08-02 Bob Duff <duff@adacore.com>
1692
1693 * sem_ch12.adb (Analyze_Package_Instantiation,
1694 Analyze_Subprogram_Instantiation): Turn off style checking while
1695 analyzing an instance. Whatever style checks that apply to the generic
1696 unit should apply, so it makes no sense to apply them in an instance.
1697 This was causing trouble when compiling an instance of a runtime
1698 unit that violates the -gnatyO switch.
1699 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
1700 one of the two case statements, causing spurious errors.
1701
17022011-08-02 Robert Dewar <dewar@adacore.com>
1703
1704 * uname.adb: Minor reformatting.
1705 * gnatcmd.adb: Minor reformatting.
1706 * exp_attr.adb: Minor reformatting.
1707
17082011-08-02 Ed Schonberg <schonberg@adacore.com>
1709
1710 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
1711 No_Dispatching_Calls, do not look for the Assign primitive, because
1712 predefined primitives are not created in this case.
1713
17142011-08-02 Bob Duff <duff@adacore.com>
1715
1716 * stylesw.ads: Minor comment fixes.
1717
17182011-08-02 Robert Dewar <dewar@adacore.com>
1719
1720 * freeze.adb (Add_To_Result): New procedure.
1721
17222011-08-02 Jose Ruiz <ruiz@adacore.com>
1723
1724 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
1725 time, if the specific run-time routines for handling streams of strings
1726 are not available, use the default mechanism.
1727
17282011-08-02 Arnaud Charlet <charlet@adacore.com>
1729
1730 * s-regpat.ads: Fix typo.
1731
17322011-08-02 Vincent Celier <celier@adacore.com>
1733
1734 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
1735 not null, call it to create the in memory config project file without
1736 parsing an existing default config project file.
1737
17382011-08-02 Eric Botcazou <ebotcazou@adacore.com>
1739
1740 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
1741
17422011-08-02 Ed Schonberg <schonberg@adacore.com>
1743
1744 * sem_elim.adb: an abstract subprogram does not need an eliminate
1745 pragma for its descendant to be eliminable.
1746
17472011-08-02 Ed Falis <falis@adacore.com>
1748
1749 * init.c: revert to handling before previous checkin for VxWorks
1750 * s-intman-vxworks.adb: delete unnecessary declarations related to
1751 using Ada interrupt facilities for handling signals.
1752 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
1753 * s-intman-vxworks.ads: Import __gnat_install_handler as
1754 Initialize_Interrupts.
1755 * s-taprop-vxworks.adb: Delete Signal_Mask.
1756 (Abort_Handler): change construction of mask to unblock exception
1757 signals.
1758
17592011-08-02 Jerome Guitton <guitton@adacore.com>
1760
1761 * a-except-2005.adb (Raise_From_Signal_Handler): Call
1762 Debug_Raise_Exception before propagation starts.
1763
17642011-08-02 Eric Botcazou <ebotcazou@adacore.com>
1765
1766 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
1767 to Restriction_Check_Required.
1768 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
1769 * sem_res.adb (Resolve_Call): Likewise.
1770 * sem_attr.adb (Check_Stream_Attribute): Likewise.
1771
17722011-08-02 Bob Duff <duff@adacore.com>
1773
1774 * stylesw.ads: Update comment.
1775 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
1776 * errout.ads: Remove obsolete comment.
1777
17782011-08-02 Javier Miranda <miranda@adacore.com>
1779
1780 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
1781 (Set_Is_Safe_To_Reevaluate): new procedure.
1782 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
1783 assignment is allowed on safe-to-reevaluate variables.
1784 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
1785 temporary created to remove side effects in expressions that use
1786 the secondary stack as safe-to-reevaluate.
1787 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
1788 variables that are not true constants.
1789
17902011-08-02 Robert Dewar <dewar@adacore.com>
1791
1792 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
1793 sem_res.adb, sem_ch6.adb: Minor reformatting.
1794
17952011-08-02 Jerome Guitton <guitton@adacore.com>
1796
1797 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
1798
17992011-08-02 Ed Schonberg <schonberg@adacore.com>
1800
1801 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
1802 not set Overridden_Operation if subprogram is an initialization
1803 procedure.
1804
18052011-08-02 Yannick Moy <moy@adacore.com>
1806
1807 * par-ch6.adb: Correct obsolete name in comments
1808 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
1809 which takes two message arguments (existing function takes one), with
1810 second message used for continuation.
1811 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
1812 block statements that originate from a source block statement, not
1813 generated block statements
1814 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
1815 symmetry with procedure case
1816 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
1817 function to issue an error in formal mode if a package specification
1818 contains more than one tagged type or type extension.
1819 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
1820 parameters matching formals of tagged types are objects (or ancestor
1821 type conversions of objects), not general expressions. Issue an error
1822 on view conversions that are not involving ancestor conversion of an
1823 extended type.
1824 (Resolve_Type_Conversion): in formal mode, issue an error on the
1825 operand of an ancestor type conversion which is not an object
1826 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
1827 procedure so that it works also for actuals of function calls
1828 (Is_Actual_Tagged_Parameter): new function which determines if its
1829 argument is an actual parameter of a formal of tagged type in a
1830 subprogram call
1831 (Is_SPARK_Object_Reference): new function which determines if the tree
1832 referenced by its argument represents an object in SPARK
1833
18342011-08-02 Robert Dewar <dewar@adacore.com>
1835
1836 * sem_ch3.adb: Minor reformatting
1837 Minor comment addition
1838 Minor error msg text change
1839
18402011-08-02 Javier Miranda <miranda@adacore.com>
1841
1842 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
1843 function. Used to be more precise when we generate a variable plus one
1844 assignment to remove side effects in the evaluation of the Bound
1845 expressions.
1846 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
1847 of the bound expression to force its re-analysis and thus expand the
1848 associated transient scope (if required). Code cleanup replacing the
1849 previous code that declared the constant entity by an invocation to
1850 routine Force_Evaluation which centralizes this work in the frontend.
1851
18522011-08-02 Robert Dewar <dewar@adacore.com>
1853
1854 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
1855 (Base_Type): Now uses improved Is_Base_Type function
1856 * einfo.ads (Base_Type): Inline this function
1857
18582011-08-02 Robert Dewar <dewar@adacore.com>
1859
1860 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
1861 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
1862
18632011-08-02 Arnaud Charlet <charlet@adacore.com>
1864
1865 * gcc-interface/Make-lang.in: Update dependencies.
1866 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
1867 targets.
1868
18692011-08-02 Yannick Moy <moy@adacore.com>
1870
1871 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
1872 non-simple expression used in delta constraint
1873 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
1874 index constraint which is not a subtype mark
1875 * par.adb: With and use Restrict
1876 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
1877 mode on component type which is not a subtype mark and default
1878 expression on component
1879 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
1880 of string which does not have a lower index bound equal to 1
1881 (Array_Type_Declaration): issue an error in formal mode on index or
1882 component type which is not a subtype mark, and on aliased keyword on
1883 component
1884 (Derived_Type_Declaration): issue an error in formal mode on interface,
1885 limited or abstract type
1886 (Record_Type_Declaration): issue an error in formal mode on interface
1887 (Record_Type_Definition): issue an error in formal mode on tagged types
1888 and type extensions not declared in the specification of a library unit
1889 package; on null non-tagged record; on variant part
1890
18912011-08-02 Vincent Celier <celier@adacore.com>
1892
1893 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
1894 not declared for qualified library project when Library_Name is not
1895 declared, but Library_Dir is.
1896
18972011-08-02 Robert Dewar <dewar@adacore.com>
1898
1899 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
1900 pragmas (affects aspects [Component_]Default_Value
1901 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
1902 component type for the resolution
1903
19042011-08-02 Eric Botcazou <ebotcazou@adacore.com>
1905
1906 * einfo.adb (Base_Type): Tune implementation for speed.
1907
19082011-08-02 Robert Dewar <dewar@adacore.com>
1909
1910 * freeze.adb: Minor reformatting.
1911
19122011-08-02 Thomas Quinot <quinot@adacore.com>
1913
1914 * scos.ads: Update comments.
1915
19162011-08-02 Ed Schonberg <schonberg@adacore.com>
1917
1918 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
1919 base type, because the parent may be a subtype of a private type whose
1920 convention is established in a private part.
1921
19222011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
1923
1924 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
1925 statement in a block when the expansion of the return expression has
1926 created a finalization chain.
1927 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
1928 with the parent node.
1929 Add N_Extended_Return_Statement to handle the case where a transient
1930 object declaration appears in the Return_Object_Declarations list of
1931 an extended return statement.
1932
19332011-08-02 Matthew Gingell <gingell@adacore.com>
1934
1935 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
1936 unused parameter 'name'.
1937
19382011-08-02 Ed Schonberg <schonberg@adacore.com>
1939
1940 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
1941 inherited operation, check whether its alias, which is the source
1942 operastion that it renames, has been marked eliminated.
1943
19442011-08-02 Javier Miranda <miranda@adacore.com>
1945
1946 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
1947 in-mode parameter whose type is an access type since it can be used to
1948 modify its designated object. Enforce code that handles as safe an
1949 access type that is not access-to-constant but it is the result of a
1950 previous removal of side-effects.
1951 (Remove_Side_Effects): Minor code reorganization of cases which require
1952 no action. Done to incorporate documentation on new cases uncovered
1953 working in this ticket: no action needed if this routine was invoked
1954 too early and the nodes are not yet decorated.
1955 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
1956 to routine Remove_Side_Effects by calls to Force_Evaluation since they
1957 were issued with actuals that are implicitly provided by
1958 Force_Evaluation.
1959
19602011-08-02 Robert Dewar <dewar@adacore.com>
1961
1962 * sem_ch3.adb, sem_res.adb: Minor reformatting.
1963
19642011-08-02 Yannick Moy <moy@adacore.com>
1965
1966 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
1967 to issue an error in formal mode on attribute not supported in this mode
1968 (Analyze_Attribute): issue errors on standard attributes not supported
1969 in formal mode.
1970 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
1971 comment, and issue error in formal mode on modulus which is not a power
1972 of 2.
1973 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
1974 range.
1975 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
1976 subtype mark.
1977 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
1978 operator on modular type (except 'not').
1979
19802011-08-02 Robert Dewar <dewar@adacore.com>
1981
1982 * gnat_rm.texi: Minor reformatting.
1983
19842011-08-02 Arnaud Charlet <charlet@adacore.com>
1985
1986 * s-osinte-linux.ads: Minor comment update and reformatting.
1987 * i-cexten.ads: Make this unit pure, as for its parent.
1988 Will allow its usage in more contexts if needed.
1989
19902011-08-02 Robert Dewar <dewar@adacore.com>
1991
1992 * s-utf_32.ads: Minor comment fix.
1993
19942011-08-02 Ed Schonberg <schonberg@adacore.com>
1995
1996 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
1997 operation of a tagged synchronized type, handle the case where the
1998 controlling argument is overloaded.
1999
20002011-08-02 Yannick Moy <moy@adacore.com>
2001
2002 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
2003 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
2004 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
2005 SPARK mode and formal verification mode on processing SPARK restriction
2006 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
2007 requiring consistency checking.
2008
20092011-08-02 Robert Dewar <dewar@adacore.com>
2010
2011 * sem_res.adb: Minor reformatting.
2012
20132011-08-02 Robert Dewar <dewar@adacore.com>
2014
2015 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
2016 a-cforse.ads: Remove unneeded with of Ada.Containers
2017 Remove commented out pragma Inline's
2018 Move specifications of new subprograms to the actual specs
2019
20202011-08-02 Yannick Moy <moy@adacore.com>
2021
2022 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
2023 a-cforse.ads: Update comments.
2024
20252011-08-02 Ed Schonberg <schonberg@adacore.com>
2026
2027 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
2028
20292011-08-02 Robert Dewar <dewar@adacore.com>
2030
2031 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
2032 a-cforse.ads, a-cofove.ads: Minor reformatting.
2033
20342011-08-02 Claire Dross <dross@adacore.com>
2035
2036 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
2037 a-cofove.ads: Add comments.
2038
20392011-08-02 Yannick Moy <moy@adacore.com>
2040
2041 * gnat_rm.texi: Document formal containers.
2042
20432011-08-02 Emmanuel Briot <briot@adacore.com>
2044
2045 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
2046 are empty sections.
2047
20482011-08-02 Robert Dewar <dewar@adacore.com>
2049
2050 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
2051 reformatting.
2052
20532011-08-02 Robert Dewar <dewar@adacore.com>
2054
2055 * aspects.adb: New aspects Default_Value and Default_Component_Value
2056 New format of Aspect_Names table checks for omitted entries
2057 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
2058 handling of boolean aspects for derived types.
2059 New aspects Default_Value and Default_Component_Value
2060 New format of Aspect_Names table checks for omitted entries
2061 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
2062 (Has_Default_Value): New flag
2063 (Has_Default_Component_Value): New flag
2064 (Has_Default_Value): New flag
2065 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
2066 table.
2067 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
2068 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
2069 Default_Value and Default_Component_Value
2070 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
2071 New aspects Default_Value and Default_Component_Value
2072 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
2073 * sprint.adb: Print N_Aspect_Specification node when called from gdb
2074
20752011-08-02 Vincent Celier <celier@adacore.com>
2076
2077 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
2078 inherit library kind.
2079
20802011-08-02 Ed Schonberg <schonberg@adacore.com>
2081
2082 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
2083 Minor reformatting.
2084
20852011-08-02 Robert Dewar <dewar@adacore.com>
2086
2087 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
2088
20892011-08-02 Yannick Moy <moy@adacore.com>
2090
2091 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
2092
20932011-08-02 Robert Dewar <dewar@adacore.com>
2094
2095 * impunit.adb: Add comment.
2096
20972011-08-02 Yannick Moy <moy@adacore.com>
2098
2099 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
2100 qualification of aggregates in formal mode
2101 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
2102 another aggregate
2103 (Resolve_Aggregate): complete the test that an aggregate is adequately
2104 qualified in formal mode
2105
21062011-08-02 Pascal Obry <obry@adacore.com>
2107
2108 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
2109 * mlib-prj.adb: Supress warning when compiling binder generated file.
2110 (Build_Library): Supress all warnings when compiling the binder
2111 generated file.
2112
21132011-08-02 Yannick Moy <moy@adacore.com>
2114
2115 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
2116 from here...
2117 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
2118 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
2119 Add with/use clauses to make Check_Formal_Restriction visible
2120
21212011-08-02 Ed Schonberg <schonberg@adacore.com>
2122
2123 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
2124 in-parameters when type of the generic formal is private in the generic
2125 spec and non-private in the body.
2126
21272011-08-02 Claire Dross <dross@adacore.com>
2128
2129 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
2130 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
2131 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
2132 * impunit.adb, Makefile.rtl: Take new files into account.
2133
21342011-08-02 Robert Dewar <dewar@adacore.com>
2135
2136 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
2137 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
2138
21392011-08-02 Yannick Moy <moy@adacore.com>
2140
2141 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
2142 formal mode
2143 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
2144 matching static array bounds, taking into account the special case of
2145 string literals
2146 * sem_ch3.adb: Typo in comment.
2147
21482011-08-02 Yannick Moy <moy@adacore.com>
2149
2150 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
2151 which issues an error in formal mode if its argument node is originally
2152 from source
2153 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
2154 has a discriminant specification so that it does not include the case
2155 of derived types
2156 (Derived_Type_Declaration): move here the test that a derived type has a
2157 discriminant specification
2158 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
2159 first element of a component association before accessing its choices
2160 (presence of component association is not enough)
2161 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
2162 declaration is a library item before accessing the next element in a
2163 list, as library items are not member of lists
2164 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
2165 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
2166 Check_Formal_Restriction whenever possible.
2167
21682011-08-02 Ed Schonberg <schonberg@adacore.com>
2169
2170 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
2171 reference when needed.
2172
21732011-08-02 Bob Duff <duff@adacore.com>
2174
2175 * gnat_ugn.texi: Fix typo.
2176
21772011-08-02 Vincent Celier <celier@adacore.com>
2178
2179 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
2180 archive file name. Do not use the full path name of archives for Open
2181 VMS.
2182
21832011-08-02 Robert Dewar <dewar@adacore.com>
2184
2185 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
2186 Analyze_Aspect_Specifications
2187 * sem_ch13.adb
2188 (Analyze_Aspect_Specifications): New handling for boolean aspects
2189 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
2190 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
2191 sequence for Analyze_Aspect_Specifications
2192 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
2193 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
2194
21952011-08-02 Robert Dewar <dewar@adacore.com>
2196
2197 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
2198 aspects, since these no longer exist.
2199
22002011-08-02 Robert Dewar <dewar@adacore.com>
2201
2202 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
2203 semicolon, do not try to see if there are aspects following it.
2204 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
2205 aspect spec.
2206
22072011-08-02 Robert Dewar <dewar@adacore.com>
2208
2209 * sem_ch8.adb, aspects.ads: Minor reformatting.
2210
22112011-08-02 Eric Botcazou <ebotcazou@adacore.com>
2212
2213 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
2214 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
2215 extracted from...
2216 (Analyze_Aspect_Specifications): ...here. Call above procedure.
2217
22182011-08-02 Yannick Moy <moy@adacore.com>
2219
2220 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
2221 mode on subprogram declaration outside of package specification, unless
2222 it is followed by a pragma Import
2223 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
2224 Access_Type_Declaration): issue error in formal mode on access type
2225 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
2226 incomplete type
2227 (Analyze_Object_Declaration): issue error in formal mode on object
2228 declaration which does not respect SPARK restrictions
2229 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
2230 declaration which does not respect SPARK restrictions
2231 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
2232 error in formal mode on digits or delta constraint
2233 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
2234 decimal fixed point type
2235 (Derived_Type_Declaration): issue error in formal mode on derived type
2236 other than type extensions of tagged record types
2237 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
2238 with check on access definition
2239 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
2240 mode on protected definition.
2241 (Analyze_Task_Definition): issue error in formal mode on task definition
2242
22432011-08-02 Robert Dewar <dewar@adacore.com>
2244
2245 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
2246
22472011-08-02 Javier Miranda <miranda@adacore.com>
2248
2249 * sem_ch6.adb (Can_Override_Operator): New function.
2250 (Verify_Overriding_Indicator): Add missing code to check overriding
2251 indicator in operators. Fixes regression.
2252 (Check_Overriding_Indicator): Minor reformating after replacing the
2253 code that evaluates if the subprogram can override an operator by
2254 invocations to the above new function.
2255 * einfo.adb
2256 (Write_Field26_Name): Add missing code to ensure that, following
2257 the documentation in einfo.ads, this field is not shown as attribute
2258 "Static_Initialization" on non-dispatching functions.
2259
22602011-08-02 Jose Ruiz <ruiz@adacore.com>
2261
2262 * sem_res.adb (Resolve_Call): A call to
2263 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
2264 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
2265 i.e., when the second parameter is of type Time_Span.
2266
22672011-08-02 Vincent Celier <celier@adacore.com>
2268
2269 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
2270 with an archive instead of -L<library dir> -l<library name>.
2271
22722011-08-02 Ed Schonberg <schonberg@adacore.com>
2273
2274 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
2275 mark the base types In_Use in addition to making the operations
2276 use_visible.
2277
22782011-08-02 Ed Falis <falis@adacore.com>
2279
2280 * init.c: add and setup __gnat_signal_mask for the exception signals
2281 * s-inmaop-vxworks.adb: new file.
2282 * s-intman-vxworks.adb: remove unnecessary initializations and
2283 simplify remaining
2284 * s-intman-vxworks.ads: remove unnecessary variable
2285 * s-taprop-vxworks.adb: simplify signal initialization
2286
22872011-08-02 Robert Dewar <dewar@adacore.com>
2288
2289 * sem_ch8.adb: Minor code reorganization, comment updates.
2290
22912011-08-02 Robert Dewar <dewar@adacore.com>
2292
2293 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
2294 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
2295 here from Sem_Res.
2296 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
2297 (Matching_Static_Array_Bounds): Moved here from Sem_Res
2298
22992011-08-02 Ed Schonberg <schonberg@adacore.com>
2300
2301 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
2302 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
2303 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
2304 use_type_clauses, to handle more efficiently use_type and use_all_type
2305 constructs.
2306 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
2307 Ada2012 Use_All_Type clause.
2308 (Use_Class_Wide_Operations): new procedure.
2309
23102011-08-02 Robert Dewar <dewar@adacore.com>
2311
2312 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
2313 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
2314 expression to expression function.
2315
23162011-08-02 Ed Schonberg <schonberg@adacore.com>
2317
2318 * sem_ch4.adb: transform simple Ada2012 membership into equality only
2319 if types are compatible.
2320
23212011-08-02 Yannick Moy <moy@adacore.com>
2322
2323 * sem_res.adb (Matching_Static_Array_Bounds): new function which
2324 returns True if its argument array types have same dimension and same
2325 static bounds at each index.
2326 (Resolve_Actuals): issue an error in formal mode on actuals passed as
2327 OUT or IN OUT paramaters which are not view conversions in SPARK.
2328 (Resolve_Arithmetic_Op): issue an error in formal mode on
2329 multiplication or division with operands of fixed point types which are
2330 not qualified or explicitly converted.
2331 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
2332 Boolean or array type (except String) operands.
2333 (Resolve_Equality_Op): issue an error in formal mode on equality
2334 operators for array types other than String with non-matching static
2335 bounds.
2336 (Resolve_Logical_Op): issue an error in formal mode on logical operators
2337 for array types with non-matching static bounds. Factorize the code in
2338 Matching_Static_Array_Bounds.
2339 (Resolve_Qualified_Expression): issue an error in formal mode on
2340 qualified expressions for array types with non-matching static bounds.
2341 (Resolve_Type_Conversion): issue an error in formal mode on type
2342 conversion for array types with non-matching static bounds
2343
23442011-08-02 Robert Dewar <dewar@adacore.com>
2345
2346 * par-ch10.adb: Minor code reorganization (use Nkind_In).
2347
23482011-08-02 Ed Schonberg <schonberg@adacore.com>
2349
2350 * par-ch9.adb: save location of entry for proper error message.
2351
23522011-08-02 Javier Miranda <miranda@adacore.com>
2353
2354 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
2355 (Use_Full_View) which permits this routine to climb through the
2356 ancestors using the full-view of private parents.
2357 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
2358 Use_Full_View to true in calls to Is_Ancestor.
2359 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
2360 true in call to Is_Ancestor.
2361 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
2362 Use_Full_View to true in call to Is_Ancestor.
2363 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
2364 call to Is_Ancestor.
2365 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
2366 Use_Full_View to true in calls to Is_Ancestor.
2367 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
2368 Make_Select_Specific_Data_Table, Register_Primitive,
2369 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
2370 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
2371 to true in call to Is_Ancestor.
2372 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
2373 Use_Full_View to true in calls to Is_Ancestor.
2374 * exp_cg.adb
2375 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
2376 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
2377
23782011-08-02 Robert Dewar <dewar@adacore.com>
2379
2380 * gnat_rm.texi: Minor reformatting.
2381 * sem_prag.adb: Minor reformatting.
2382
23832011-08-02 Tristan Gingold <gingold@adacore.com>
2384
2385 * vms_data.ads: Add VMS qualifier for -gnateP.
2386
23872011-08-02 Robert Dewar <dewar@adacore.com>
2388
2389 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
2390 * par-ch7.adb (P_Package): Proper placement of aspects for package
2391 decl/instantiation.
2392 * par-endh.adb (Check_End): Ad Is_Sloc parameter
2393 (End_Statements): Add Is_Sloc parameterr
2394 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
2395 (Check_End): Ad Is_Sloc parameter
2396 (End_Statements): Add Is_Sloc parameterr
2397
23982011-08-02 Vincent Celier <celier@adacore.com>
2399
2400 * ug_words: Add VMS qualifier equivalent to -gnateP:
2401 /SYMBOL_PREPROCESSING.
2402
24032011-08-02 Jose Ruiz <ruiz@adacore.com>
2404
2405 * gnat-style.texi: For hexadecimal numeric literals the typical
2406 grouping of digits is 4 to represent 2 bytes.
2407 A procedure spec which is split into several lines is indented two
2408 characters.
2409
24102011-08-02 Yannick Moy <moy@adacore.com>
2411
2412 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
2413 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
2414 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
2415 properly qualified
2416 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
2417 choice in array aggregate
2418 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
2419 mark as ancestor
2420 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
2421 positional and named aggregate for record, or others in record
2422 aggregate, or multiple choice in record aggregate
2423 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
2424 array operands to logical operations AND, OR and XOR do not have the
2425 same static lower and higher bounds
2426 * sem_ch5.adb, sinfo.ads: Correct typos in comments
2427
24282011-08-01 Robert Dewar <dewar@adacore.com>
2429
2430 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
2431 Replaces Last_Source_Node_In_Sequence.
2432 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
2433 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
2434 parens and blank in string (this was inconsistently implemented).
2435 * errout.ads
2436 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
2437 blank in string (this was inconsistently implemented).
2438 * gnat1drv.adb
2439 (Set_Global_Switches): Set formal mode switches appropriately
2440 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
2441 * par-prag.adb
2442 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
2443 call Set_Error_Msg_Lang to set "spark" as language name.
2444 * par.adb: Remove unnecessary call to set formal language for errout
2445 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
2446 appropriately and call Set_Error_Msg_Lang to set "spark" as language
2447 name.
2448 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
2449 calls to it, moved after resolution so that types are known
2450 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
2451 result of concatenation is not of type String
2452 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
2453 concatenation is not properly restricted
2454 * gnat_rm.texi: Add doc on pragma Spark_95.
2455 * gcc-interface/Makefile.in: Remove obsolete target pairs for
2456 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
2457 * gcc-interface/Make-lang.in: Update dependencies.
2458
24592011-08-01 Javier Miranda <miranda@adacore.com>
2460
2461 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
2462 condition that detects if the overridden operation must replace an
2463 existing entity.
2464
24652011-08-01 Javier Miranda <miranda@adacore.com>
2466
2467 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
2468 code declarations inserted by Insert_Actions in each alternative of the
2469 N_Case_Expression node.
2470
24712011-08-01 Robert Dewar <dewar@adacore.com>
2472
2473 * sem_ch6.adb: Minor code reorganization.
2474 * sem_util.adb: Minor reformatting.
2475
24762011-08-01 Pascal Obry <obry@adacore.com>
2477
2478 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
2479 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
2480
24812011-08-01 Yannick Moy <moy@adacore.com>
2482
2483 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
2484 literal or operator symbol which is prefixed
2485 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
2486 mode on access attributes.
2487 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
2488 that concatenation operands are properly restricted in formal mode
2489 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
2490 Analyze_Concatenation_Operand. Issue an error in formal mode if the
2491 result of the concatenation has a type different from String.
2492 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
2493 Analyze_Quantified_Expression, Analyze_Slice,
2494 Analyze_Null): issue an error in formal mode on unsupported constructs
2495 * sem_ch5.adb
2496 (Analyze_Block_Statement): only issue error on source block statement
2497 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
2498 function which returns the last node in a list of nodes for which
2499 Comes_From_Source returns True, if any
2500 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
2501 Last_Source_Node_In_Sequence
2502 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
2503 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
2504 mode on unsupported constructs
2505 * sem_ch9.adb Do not return after issuing error in formal mode, as the
2506 rest of the actions may be needed later on since the error is marked as
2507 not serious.
2508 * sinfo.ads: Typos in comments.
2509
25102011-08-01 Pascal Obry <obry@adacore.com>
2511
2512 * projects.texi: Minor editing.
2513
25142011-08-01 Yannick Moy <moy@adacore.com>
2515
2516 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
2517 insertion character ~~
2518 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
2519 (Set_Error_Msg_Lang): new procedure which fixes the language for use
2520 with insertion character ~~
2521 (Set_Msg_Text): treat insertion character ~~
2522 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
2523 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
2524 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
2525 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
2526 errors related to the formal language restriction not serious
2527 (insertion character |).
2528 * par.adb (Par): set formal language for error messages if needed
2529 * sem_ch6.adb (Check_Missing_Return): take into account possible
2530 generated statements at the end of the function
2531 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
2532 enumeration value to define a new pragma SPARK_95
2533 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
2534 SPARK_Version): new type and variables to store the SPARK version
2535 (none by default).
2536 (SPARK_Mode): return True when SPARK_Version is set
2537 * par-prag.adb: Correct indentation
2538 (Prag): take Pragma_SPARK_95 into account
2539 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
2540 into account.
2541
25422011-08-01 Robert Dewar <dewar@adacore.com>
2543
2544 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
2545 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
2546 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
2547
25482011-08-01 Pascal Obry <obry@adacore.com>
2549
2550 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
2551 Target_Name to Get_Path call.
2552 (Parse_Single_Project): Likewise.
2553 (Post_Parse_Context_Clause): Likewise.
2554 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
2555 Call Initialise_Project_Path with the proper Target_Name.
2556 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
2557 search path.
2558 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
2559 with the proper Target_Name.
2560 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
2561 Part.Parse routine.
2562 (Parse_Project_And_Apply_Config): Likewise.
2563 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
2564 This is fine as this part of the code is supporting only native
2565 compilation.
2566 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
2567 is fine as this part of the code is supporting only native compilation.
2568
25692011-08-01 Yannick Moy <moy@adacore.com>
2570
2571 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
2572 of homonym, unless the homonym is one of the cases allowed in SPARK
2573 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
2574 package declaration occurring after a body.
2575
25762011-08-01 Robert Dewar <dewar@adacore.com>
2577
2578 * checks.adb, exp_ch4.adb: Minor reformatting.
2579
25802011-08-01 Javier Miranda <miranda@adacore.com>
2581
2582 * einfo.ads (Access_Disp_Table): Fix documentation.
2583 (Dispatch_Table_Wrappers): Fix documentation.
2584
25852011-08-01 Pascal Obry <obry@adacore.com>
2586
2587 * prj-env.adb, prj-env.ads: Minor reformatting.
2588
25892011-08-01 Yannick Moy <moy@adacore.com>
2590
2591 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
2592 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
2593 procedures out of these packages.
2594 * errout.ads, errout.adb
2595 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
2596 procedures in of this package
2597 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
2598 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
2599 on misplaced later vs initial declarations, like in Ada 83
2600 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
2601 formal mode on attribute of private type whose full type declaration
2602 is not visible
2603 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
2604 package declaration inside a package specification
2605 (Analyze_Full_Type_Declaration): issue error in formal mode on
2606 controlled type or discriminant type
2607 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
2608 user-defined operator means that it should come from the source
2609 (New_Overloaded_Entity): issue error in formal mode on overloaded
2610 entity.
2611 * sem_ch6.ads, sem_ch13.ads: typos in comments.
2612
26132011-08-01 Thomas Quinot <quinot@adacore.com>
2614
2615 * atree.adb: Minor reformatting.
2616 * checks.adb: Minor reformatting.
2617
26182011-08-01 Vincent Celier <celier@adacore.com>
2619
2620 * s-parame-vms-ia64.ads: Fix typo in comment
2621 Minor reformatting
2622 * s-parame-vms-restrict.ads: Removed, unused.
2623
26242011-08-01 Javier Miranda <miranda@adacore.com>
2625
2626 * exp_ch3.adb
2627 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
2628 * sem_ch3.adb
2629 (Constrain_Index): Remove side effects in the evaluation of the bounds.
2630 * sem_ch3.ads, sem_ch3.adb
2631 (Is_Constant_Bound): New extended version of the subprogram that was
2632 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
2633 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
2634 * sem_aux.ads (Constant_Value): Fix typo in comment.
2635 * checks.adb (Generate_Index_Checks): New implementation which, for
2636 array objects with constant bounds, generates the runtime check
2637 referencing the bounds of the array type. For other cases this routine
2638 provides its previous behavior obtaining such values from the array
2639 object.
2640 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
2641 parent type.
2642 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
2643 we cannot have semantic interpretations of the new node.
2644
26452011-08-01 Ed Schonberg <schonberg@adacore.com>
2646
2647 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
2648 expressions.
2649
26502011-08-01 Arnaud Charlet <charlet@adacore.com>
2651
2652 * sem_ch8.adb: Minor code editing.
2653 * s-vxwext.adb: Remove trailing space.
2654 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
2655 consistency with other files.
2656
26572011-08-01 Thomas Quinot <quinot@adacore.com>
2658
2659 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
2660
26612011-08-01 Ed Schonberg <schonberg@adacore.com>
2662
2663 * par-ch10.adb: reject parameterized expressions as compilation unit.
2664 * sem_ch4.adb: handle properly conditional expression with overloaded
2665 then_clause and no else_clause.
2666
26672011-08-01 Tristan Gingold <gingold@adacore.com>
2668
2669 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
2670 like done by System.Aux_DEC.
2671 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
2672
26732011-08-01 Yannick Moy <moy@adacore.com>
2674
2675 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
2676 missing label at end of declaration (subprogram or package)
2677 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
2678 of positional and named parameter association
2679 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
2680 Error_Msg_SP which adds a prefix to the error message giving the name
2681 of the formal language analyzed
2682 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
2683 access result type in subprogram, unconstrained array as result type,.
2684 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
2685 procedure
2686 * sem_ch8.adb: Code clean up.
2687
26882011-08-01 Javier Miranda <miranda@adacore.com>
2689
2690 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
2691 * einfo.ads (Access_Disp_Table): Fix documentation.
2692 (Dispatch_Table_Wrappers): Fix documentation.
2693 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
2694 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
2695 to enforce the documentation of this attribute.
2696 (Set_Is_Interface): Cleanup the assertion.
2697 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
2698 the Underlying_Type entity before reading attribute Access_Disp_Table.
2699 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
2700 Locate the Underlying_Type before reading attribute Access_Disp_Table.
2701 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
2702 the Underlying_Type entity before reading attribute Access_Disp_Table.
2703 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
2704 Locate the Underlying_Type entity before reading attribute
2705 Access_Disp_Table.
2706
27072011-08-01 Ed Schonberg <schonberg@adacore.com>
2708
2709 * s-poosiz.ads: Additional overriding indicators.
2710
27112011-08-01 Yannick Moy <moy@adacore.com>
2712
2713 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
2714 formal mode.
2715 (Analyze_Iteration_Scheme): issue error in formal mode when loop
2716 parameter specification does not include a subtype mark.
2717 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
2718 formal mode on abstract subprogram.
2719 (Analyze_Subprogram_Specification): issue error in formal mode on
2720 user-defined operator.
2721 (Process_Formals): issue error in formal mode on access parameter and
2722 default expression.
2723 * sem_ch9.adb (Analyze_Abort_Statement,
2724 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
2725 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
2726 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
2727 Analyze_Requeue, Analyze_Selective_Accept,
2728 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
2729 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
2730 issue error in formal mode on user-defined raise statement.
2731
27322011-08-01 Thomas Quinot <quinot@adacore.com>
2733
2734 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
2735 declaration being hidden when overriding an implicit inherited
2736 subprogram.
2737 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
2738 (-gnats), do not complain about a source file that contains only a
2739 pragma No_Body.
2740
27412011-08-01 Ed Schonberg <schonberg@adacore.com>
2742
2743 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
2744 variable if already set.
2745
27462011-08-01 Arnaud Charlet <charlet@adacore.com>
2747
2748 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
2749 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
2750 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
2751 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
2752 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
2753 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
2754 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
2755 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
2756 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
2757 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
2758 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
2759 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
2760 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
2761 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
2762 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
2763 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
2764 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
2765 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
2766 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
2767 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
2768 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
2769 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
2770 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
2771 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
2772 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
2773 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
2774 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
2775 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
2776 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
2777 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
2778 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
2779 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
2780 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
2781 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
2782 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
2783 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
2784 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
2785 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
2786 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
2787 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
2788 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
2789 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
2790 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
2791 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
2792 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
2793 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
2794 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
2795 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
2796 s-osinte-mingw.ads: Update to GPLv3 run-time license.
2797 Use GNAT instead of GNARL.
2798
27992011-08-01 Bob Duff <duff@adacore.com>
2800
2801 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
2802 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
2803 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
2804 reformatting.
2805
28062011-08-01 Yannick Moy <moy@adacore.com>
2807
2808 * debug.adb (d.D) reverve flag for the SPARK mode
2809 (d.E) reverve flag for SPARK generation mode
2810 (d.F) reverve flag for Why generation mode
2811 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
2812 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
2813 functions which return True when the corresponding modes are set
2814 (Formal_Language): return "spark" or "alfa" when in formal verification
2815 mode.
2816 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
2817 Error_Msg to prefix the error message with a tag giving the formal
2818 language
2819 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
2820 message with a tag giving the formal language
2821 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
2822 block statement
2823 (Analyze_Case_Statement): issue error in formal mode on case statement
2824 with a single "others" case alternative
2825 (Analyze_Exit_Statement): issue errors in formal mode on exit
2826 statements which do not respect SPARK restrictions
2827 (Analyze_Goto_Statement): issue error in formal mode on goto statement
2828 (Check_Unreachable_Code): always issue an error (not a warning) in
2829 formal mode on unreachable code (concerns both code after an infinite
2830 loop and after an unconditional jump, both not allowed in SPARK)
2831 * sem_ch6.adb (Analyze_Return_Statement): add call to
2832 Set_Return_Present for a procedure containing a return statement
2833 (already done for functions in Analyze_Function_Return)
2834 (Analyze_Function_Return): issue error in formal mode on extended
2835 return or if return is not last statement in function
2836 (Check_Missing_Return): issue error in formal mode if function does
2837 not end with return or if procedure contains a return
2838 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
2839 function to detect if there is an inner scope of its parameter S which
2840 is a loop.
2841
28422011-08-01 Thomas Quinot <quinot@adacore.com>
2843
2844 * sem_ch6.ads: Minor reformatting.
2845
28462011-08-01 Javier Miranda <miranda@adacore.com>
2847
2848 * sem_util.adb (Abstract_Interface_List): Complete condition when
2849 processing private type declarations to avoid reading unavailable
2850 attribute.
2851 (Is_Synchronized_Tagged_Type): Complete condition when processing
2852 private extension declaration nodes to avoid reading unavailable
2853 attribute.
2854
28552011-08-01 Thomas Quinot <quinot@adacore.com>
2856
2857 * sem_ch3.adb: Minor reformatting.
2858
28592011-08-01 Thomas Quinot <quinot@adacore.com>
2860
2861 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
2862 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
2863 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
2864 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
2865 for VMS, instead parametrize the common implementation with
2866 System.Parameters declarations.
2867
28682011-08-01 Eric Botcazou <ebotcazou@adacore.com>
2869
2870 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
2871
28722011-08-01 Tristan Gingold <gingold@adacore.com>
2873
2874 * seh_init.c: Fix SEH handler installation on win64.
2875
28762011-08-01 Ed Schonberg <schonberg@adacore.com>
2877
2878 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
2879 double analysis of an anonymous access to subprogram, because it can
2880 lead to improper sharing of profiles and a back-end crash.
2881
28822011-08-01 Robert Dewar <dewar@adacore.com>
2883
2884 * make.adb, sem_ch4.adb: Minor reformatting.
2885 * gcc-interface/Make-lang.in: Update dependencies.
2886 * sem_util.adb, exp_ch5.adb: Minor reformatting.
2887
28882011-08-01 Arnaud Charlet <charlet@adacore.com>
2889
2890 * gnat_rm.texi: Fix definition of Long_Integer.
2891
28922011-08-01 Ed Schonberg <schonberg@adacore.com>
2893
2894 * exp_aggr.adb: check limit size of static aggregate unconditionally,
2895 to prevent storage exhaustion.
2896 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
2897 finalized is a function body, insert the cleanup code before the final
2898 return statement, to prevent spurious warnings.
2899 * s-pooglo.ads: add overriding indicator.
2900
29012011-08-01 Ed Schonberg <schonberg@adacore.com>
2902
2903 * sem_ch4.adb (Operator_Check): improve error message when both a
2904 with_clause and a use_clause are needed to make operator usage legal.
2905 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
2906 determine whether a compilation unit is visible within an other,
2907 either through a with_clause in the current unit, or a with_clause in
2908 its library unit or one one of its parents.
2909
29102011-08-01 Ed Schonberg <schonberg@adacore.com>
2911
2912 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
2913 over an arbitrary expression of an array or container type.
2914 * lib-xref.adb: clarify comment.
2915
29162011-08-01 Bob Duff <duff@adacore.com>
2917
2918 * einfo.ads: Minor reformatting.
2919 * debug.adb: Minor comment improvement.
2920
29212011-08-01 Javier Miranda <miranda@adacore.com>
2922
2923 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
2924 consider hidden subprograms as valid candidates.
2925
29262011-08-01 Arnaud Charlet <charlet@adacore.com>
2927
2928 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
2929
29302011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
2931
2932 * gnat_ugn.texi: Fix typo.
2933
29342011-08-01 Robert Dewar <dewar@adacore.com>
2935
2936 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
2937 lib-xref.adb: Minor reformatting
2938
29392011-08-01 Gary Dismukes <dismukes@adacore.com>
2940
2941 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
2942 when to generate a call to Move_Final_List.
2943 (Has_Controlled_Parts): Remove this function.
2944
29452011-08-01 Geert Bosch <bosch@adacore.com>
2946
2947 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
2948 "," in choice list.
2949
29502011-08-01 Thomas Quinot <quinot@adacore.com>
2951
2952 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
2953 explicit raise of a predefined exception as Comes_From_Source if the
2954 original N_Raise_Statement comes from source.
2955
29562011-08-01 Robert Dewar <dewar@adacore.com>
2957
2958 * sinfo.ads: Add comment.
2959 * sem_ch6.adb: Minor reformatting.
2960
29612011-08-01 Robert Dewar <dewar@adacore.com>
2962
2963 * freeze.adb (Freeze_Entity): Refine check for bad component size
2964 clause to avoid rejecting confirming clause when atomic/aliased present.
2965
29662011-08-01 Ed Schonberg <schonberg@adacore.com>
2967
2968 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
2969 better determine whether an entity reference is a write.
2970 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
2971 subcomponent.
2972 * lib-xref.adb (Output_References): Do no suppress a read reference at
2973 the same location as an immediately preceeding modify-reference, to
2974 handle properly in-out actuals.
2975
29762011-08-01 Tristan Gingold <gingold@adacore.com>
2977
2978 * env.c (__gnat_setenv) [VMS]: Refine previous change.
2979
29802011-08-01 Quentin Ochem <ochem@adacore.com>
2981
2982 * i-cstrin.adb (New_String): Changed implementation, now uses only the
2983 heap to compute the result.
2984
29852011-08-01 Robert Dewar <dewar@adacore.com>
2986
2987 * atree.ads: Minor reformatting.
2988
29892011-08-01 Emmanuel Briot <briot@adacore.com>
2990
2991 * g-expect.adb (Get_Command_Output): Fix memory leak.
2992
29932011-08-01 Geert Bosch <bosch@adacore.com>
2994
2995 * cstand.adb (P_Float_Type): New procedure to print the definition of
2996 predefined fpt types.
2997 (P_Mixed_Name): New procedure to print a name using mixed case
2998 (Print_Standard): Use P_Float_Type for printing floating point types
2999 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
3000 precision IEEE float.
3001
30022011-08-01 Thomas Quinot <quinot@adacore.com>
3003
3004 * sem_ch3.adb: Minor reformatting.
3005
30062011-08-01 Ed Schonberg <schonberg@adacore.com>
3007
3008 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
3009 the completion of a generic function, insert the new body rather than
3010 rewriting the original.
3011
30122011-08-01 Yannick Moy <moy@adacore.com>
3013
3014 * sinfo.ads, errout.ads: Typos in comments.
3015
30162011-08-01 Robert Dewar <dewar@adacore.com>
3017
3018 * par-endh.adb: Minor reformatting.
3019
30202011-08-01 Robert Dewar <dewar@adacore.com>
3021
3022 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
3023 (Pre_Post_Aspects): New subtype.
3024 * par-ch12.adb (P_Generic): New syntax for aspects in packages
3025 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
3026 * par-ch7.adb (P_Package): Remove Decl parameter
3027 (P_Package): Handle new syntax for aspects (before IS)
3028 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
3029 new aspect syntax
3030 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
3031 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
3032 (P_Package): Remove Decl parameter
3033 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
3034 aspects
3035 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
3036 specs
3037 * sem_util.ads, sem_util.adb (Static_Boolean): New function
3038 * sinfo.ads: Document new syntax for aspects in packages etc.
3039 * sprint.adb: Handle new syntax of aspects before IS in package
3040
30412011-08-01 Thomas Quinot <quinot@adacore.com>
3042
3043 * atree.ads: Minor reformatting.
3044 * sem_prag.adb: Minor reformatting.
3045
30462011-08-01 Robert Dewar <dewar@adacore.com>
3047
3048 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
3049 case expr alternative.
3050
30512011-08-01 Ed Schonberg <schonberg@adacore.com>
3052
3053 * sem_ch12.adb: Fix typo.
3054
30552011-08-01 Geert Bosch <bosch@adacore.com>
3056
3057 * sem_prag.adb (Check_No_Link_Name): New procedure.
3058 (Process_Import_Or_Interface): Use Check_No_Link_Name.
3059 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
3060 instead of Standard_Long_Long_Float_Size global. Preparation for
3061 eventual removal of per type constants.
3062 * exp_util.ads (Get_Stream_Size): New function returning the stream
3063 size value of subtype E.
3064 * exp_util.adb (Get_Stream_Size): Implement new function.
3065 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
3066 function.
3067 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
3068 * einfo.adb:
3069 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
3070
30712011-08-01 Geert Bosch <bosch@adacore.com>
3072
3073 * cstand.adb: Fix comments.
3074 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
3075 count of arguments.
3076
30772011-08-01 Robert Dewar <dewar@adacore.com>
3078
3079 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
3080
30812011-08-01 Geert Bosch <bosch@adacore.com>
3082
3083 * atree.ads: Fix comment.
3084
30852011-08-01 Robert Dewar <dewar@adacore.com>
3086
3087 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
3088 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
3089 * par.adb: Add with for Namet.Sp.
3090 * par-tchk.adb: Minor reformatting.
3091
30922011-08-01 Vincent Celier <celier@adacore.com>
3093
3094 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
3095 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
3096 of the init procedure of a SAL.
3097 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
3098 New procedure.
3099
31002011-08-01 Thomas Quinot <quinot@adacore.com>
3101
3102 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
3103 reformatting.
3104
31052011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
3106
3107 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
3108
31092011-08-01 Thomas Quinot <quinot@adacore.com>
3110
3111 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
3112 conformant with its spec (return True only for types that have
3113 an overriding Initialize primitive operation that prevents them from
3114 having preelaborable initialization).
3115 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
3116 initialization for controlled types in Ada 2005 or later mode.
3117
31182011-08-01 Robert Dewar <dewar@adacore.com>
3119
3120 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
3121 Postcondition.
3122 (Same_Aspect): New function.
3123 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
3124 Type_Invariant, Precondition, Postcondition.
3125 * snames.ads-tmpl: Add Name_Type_Invariant.
3126
31272011-08-01 Robert Dewar <dewar@adacore.com>
3128
3129 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
3130 here.
3131 (Freeze_All_Ent): Fix error in handling inherited aspects.
3132 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
3133 already analyzed, but don't skip entire processing of a declaration,
3134 that's wrong in some cases of declarations being rewritten.
3135 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
3136 Don't delay for integer, string literals
3137 Treat predicates in usual manner for delay, remove special case code,
3138 not needed.
3139 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
3140 (Build_Predicate_Function): Update saved expression in aspect
3141 (Build_Invariant_Procedure): Update saved expression in aspect
3142 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
3143 of replacement of discriminant references if the reference is simple.
3144
31452011-08-01 Robert Dewar <dewar@adacore.com>
3146
3147 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
3148 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
3149 Static_Predicate and Dynamic_Predicate.
3150 (Build_Predicate_Function): Add processing for Static_Predicate
3151 and Dynamic_Predicate.
3152 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
3153 (From_Static_Predicate): New flag
3154 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
3155
31562011-08-01 Robert Dewar <dewar@adacore.com>
3157
3158 * usage.adb: Documentation cleanup for Ada version modes in usage.
3159 * expander.adb: Minor reformatting.
3160
31612011-08-01 Robert Dewar <dewar@adacore.com>
3162
3163 * atree.ads: Minor comment fix.
3164 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
3165 a-witeio.ads, sem_prag.adb: Minor reformatting.
3166
31672011-08-01 Doug Rupp <rupp@adacore.com>
3168
3169 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
3170 pointers. Use descrip.h header file for convenience. Add some
3171 comments.
3172
31732011-08-01 Robert Dewar <dewar@adacore.com>
3174
3175 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
3176 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
3177 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
3178 New procedure.
3179 (Check_Aspect_At_End_Of_Declarations): New procedure
3180 (Analye_Aspect_Specification): Minor changes for above procedures
3181 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
3182 specification node as well.
3183
31842011-08-01 Pascal Obry <obry@adacore.com>
3185
3186 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
3187 Windows files. Use GetFilesAttributes() in this case to check for file
3188 existence instead of returning with an error code.
3189
31902011-08-01 Vincent Celier <celier@adacore.com>
3191
3192 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
3193 High is above Source length.
3194
31952011-08-01 Robert Dewar <dewar@adacore.com>
3196
3197 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
3198
31992011-08-01 Robert Dewar <dewar@adacore.com>
3200
3201 * aspects.ads (Boolean_Aspects): New subtype.
3202 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
3203 for derived types in cases where the parent type and derived type have
3204 aspects.
3205 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
3206 with aspects when parent type also has aspects.
3207 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
3208 boolean expression at this point).
3209 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
3210 accordance with final decision on the Ada 2012 feature.
3211 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
3212
32132011-08-01 Matthew Heaney <heaney@adacore.com>
3214
3215 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
3216
32172011-08-01 Pascal Obry <obry@adacore.com>
3218
3219 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
3220 Fix Replace_Slice when High is above current string size.
3221 (Replace_Slice): Fix DL computation when High is above current
3222 string length.
3223
32242011-08-01 Gary Dismukes <dismukes@adacore.com>
3225
3226 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
3227
32282011-08-01 Matthew Heaney <heaney@adacore.com>
3229
3230 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
3231 of node.
3232
32332011-08-01 Pascal Obry <obry@adacore.com>
3234
3235 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
3236 reformatting.
3237
32382011-08-01 Ed Schonberg <schonberg@adacore.com>
3239
3240 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
3241 access to protected subprograms in generic bodies.
3242 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
3243 protected type, indicate that the convention of the subprogram is
3244 Convention_Protected, because it may be used in subsequent declarations
3245 within the protected declaration.
3246
32472011-08-01 Vincent Celier <celier@adacore.com>
3248
3249 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
3250 and "final" procedures when the name of the library is "ada", to avoid
3251 duplicate symbols "adainit" and "adafinal" in executables.
3252
32532011-08-01 Ed Schonberg <schonberg@adacore.com>
3254
3255 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
3256 quantified expression that appears within a postcondition and uses the
3257 Ada2012 'Result attribute.
3258
32592011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3260
3261 * init.c (__gnat_error_handler): Cast reason to int.
3262 (__gnat_install_handler): Explain sa_sigaction use.
3263
32642011-07-24 Eric Botcazou <ebotcazou@adacore.com>
3265
3266 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
3267 subprogram has copy-in copy-out parameters, try to promote the mode of
3268 the return type if it is passed in registers.
3269
32702011-07-24 Eric Botcazou <ebotcazou@adacore.com>
3271
3272 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
3273 left operand as addressable.
3274
32752011-07-24 Eric Botcazou <ebotcazou@adacore.com>
3276
3277 * gcc-interface/gigi.h (build_function_stub): Remove.
3278 (build_return_expr): Likewise.
3279 (convert_vms_descriptor): Declare.
3280 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
3281 (build_function_stub): Move to...
3282 * gcc-interface/utils2.c (build_return_expr): Move to...
3283 * gcc-interface/trans.c (build_function_stub): ...here.
3284 (build_return_expr): ...here.
3285 (Subprogram_Body_to_gnu): Add local variable for language_function.
3286 Disconnect the parameter attributes cache, if any, once done with it.
3287 Call end_subprog_body only after setting the end_locus.
3288 Build the stub associated with the function, if any, at the very end.
3289 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
3290 variables and streamline control flow.
3291
32922011-07-23 Arnaud Charlet <charlet@adacore.com>
3293
3294 PR ada/49819
3295 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
3296 g-trasym-dwarf.adb.
3297
32982011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3299
3300 PR bootstrap/49794
3301 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
3302 Assign to act.sa_sigaction.
3303 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
3304 current->return_address to char * before arithmetic.
3305
33062011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3307
3308 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
3309 Correct argument types.
3310 Extract code from reason.
3311 (__gnat_install_handler): Assign to act.sa_sigaction.
3312
33132011-07-21 Eric Botcazou <ebotcazou@adacore.com>
3314
3315 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
3316 (GNAT1_OBJS): ...here.
3317
33182011-07-15 Eric Botcazou <ebotcazou@adacore.com>
3319
3320 PR ada/48711
3321 * g-socthi-mingw.adb (Fill): Fix formatting.
3322
3323 * gcc-interface/gigi.h: Move around comment.
3324
33252011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
3326
3327 PR ada/46350
3328 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
3329
33302011-07-14 Florian Weimer <fw@deneb.enyo.de>
3331
3332 PR ada/48711
3333 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
3334
33352011-07-13 Eric Botcazou <ebotcazou@adacore.com>
3336
3337 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
3338 range comparison if Pmode is SImode.
3339
33402011-07-12 Laurent GUERBY <laurent@guerby.net>
3341 Eric Botcazou <ebotcazou@adacore.com>
3342
3343 * adadecode.c: Wrap up in extern "C" block.
3344 * adadecode.h: Likewise.
3345 * adaint.c: Likewise. Remove 'const' keyword.
3346 * adaint.h: Likewise.
3347 * argv.c: Likewise.
3348 * atree.h: Likewise.
3349 * cio.c: Likewise.
3350 * cstreams.c: Likewise.
3351 * env.c: Likewise.
3352 * exit.c: Likewise.
3353 * fe.h: Likewise.
3354 * final.c: Likewise.
3355 * init.c: Likewise.
3356 * initialize.c: Likewise.
3357 * link.c: Likewise.
3358 * namet.h: Likewise.
3359 * nlists.h: Likewise.
3360 * raise.c: Likewise.
3361 * raise.h: Likewise.
3362 * repinfo.h: Likewise.
3363 * seh_init.c: Likewise.
3364 * targext.c: Likewise.
3365 * tracebak.c: Likewise.
3366 * uintp.h: Likewise.
3367 * urealp.h: Likewise.
3368 * xeinfo.adb: Wrap up generated C code in extern "C" block.
3369 * xsinfo.adb: Likewise.
3370 * xsnamest.adb: Likewise.
3371 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
3372 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
3373 * gcc-interface/misc.c: Likewise.
3374 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
3375 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
3376 ada/targext.o here...
3377 (GNAT_ADA_OBJS): ...and not here.
3378 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
3379 (GNATBIND_OBJS): Reorder.
3380
33812011-07-07 Richard Henderson <rth@redhat.com>
3382
3383 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
3384 dwarf2out_frame_init.
3385
33862011-07-07 Eric Botcazou <ebotcazou@adacore.com>
3387
3388 * gcc-interface/misc.c (gnat_init): Tweak previous change.
3389
33902011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3391
3392 PR target/39150
3393 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
3394
33952011-07-06 Richard Guenther <rguenther@suse.de>
3396
3397 * gcc-interface/misc.c (gnat_init): Merge calls to
3398 build_common_tree_nodes and build_common_tree_nodes_2.
3399 Re-initialize boolean_false_node.
3400
34012011-07-02 Eric Botcazou <ebotcazou@adacore.com>
3402 Olivier Hainque <hainque@adacore.com>
3403 Nicolas Setton <setton@adacore.com>
3404
3405 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
3406 the type according to the ARTIFICIAL_P parameter.
3407 (create_type_decl): Likewise.
3408 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
3409
34102011-07-01 Eric Botcazou <ebotcazou@adacore.com>
3411
3412 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
3413 (gnatbind): Likewise.
3414
34152011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3416
3417 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
3418
34192011-06-18 Eric Botcazou <ebotcazou@adacore.com>
3420
3421 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
3422 local variable throughout. Remove useless call to Base_Type.
3423 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
3424 Take it also into account for the volatileness of the field. Set the
3425 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
3426
34272011-06-18 Eric Botcazou <ebotcazou@adacore.com>
3428
3429 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
3430 on a dereference built for a by-ref object if it has an address clause.
3431
34322011-06-18 Eric Botcazou <ebotcazou@adacore.com>
3433
3434 * einfo.ads (Address_Taken): Document use for the second argument of
3435 Asm_Input and Asm_Output attributes.
3436 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
3437 argument is an entity name, then set Address_Taken on it.
3438 <Attribute_Asm_Output>: Likewise.
3439 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
3440 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
3441 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
3442 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
3443
34442011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
3445
3446 PR middle-end/46500
3447 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
3448
34492011-06-14 Joseph Myers <joseph@codesourcery.com>
3450
3451 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
3452 (ada/utils.o): Update dependencies.
3453 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
3454 ../../../libcpp/libcpp.a.
3455 * gcc-interface/utils.c: Include common/common-target.h.
3456 (process_attributes): Use targetm_common.have_named_sections.
3457
34582011-06-07 Richard Guenther <rguenther@suse.de>
3459
3460 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
3461 set_sizetype.
3462
34632011-06-06 Eric Botcazou <ebotcazou@adacore.com>
3464
3465 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
3466 TREE_THIS_NOTRAP flag.
3467
34682011-06-06 Eric Botcazou <ebotcazou@adacore.com>
3469
3470 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
3471 Fix thinko.
3472
34732011-06-06 Eric Botcazou <ebotcazou@adacore.com>
3474
3475 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
3476 constants whose full view has discriminants specially.
3477
34782011-06-06 Eric Botcazou <ebotcazou@adacore.com>
3479
3480 * gcc-interface/utils.c: Include diagnostic.h.
3481 (gnat_write_global_declarations): Output debug information for all
3482 global type declarations before finalizing the compilation unit.
3483 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
3484
34852011-05-25 Jakub Jelinek <jakub@redhat.com>
3486
3487 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
3488
34892011-05-25 Kai Tietz <ktietz@redhat.com>
3490
3491 * adaint.c (__gnat_to_canonical_file_list_next): Use array
3492 initialization instead of const/none-const pointer assignment.
3493
34942011-05-24 Joseph Myers <joseph@codesourcery.com>
3495
3496 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
3497 $(EXTRA_GNAT1_OBJS).
3498 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
3499 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
3500 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
3501 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
3502 libcommon-target.a instead of prefix.o.
3503
35042011-05-21 Joseph Myers <joseph@codesourcery.com>
3505
3506 PR ada/49097
3507 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
3508
35092011-05-20 Joseph Myers <joseph@codesourcery.com>
3510
3511 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
3512 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
3513 instead of version.o.
3514
35152011-05-18 Kai Tietz <ktietz@redhat.com>
3516
3517 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
3518 boolean_false_node instead of integer_zero_node.
3519 (convert_with_check): Likewise.
3520 * gcc-interface/decl.c (choices_to_gnu): Likewise.
3521
35222011-05-12 Eric Botcazou <ebotcazou@adacore.com>
3523
3524 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
3525 type of the parameter is an unconstrained array, convert the actual to
3526 the type of the formal in the In Out and Out cases as well.
3527
35282011-05-11 Nathan Froyd <froydnj@codesourcery.com>
3529
3530 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
3531 call build_function_type_array or build_varargs_function_type_array
3532 instead.
3533 (create_subprog_type): Don't call build_function_type; call
3534 build_function_type_vec instead.
3535
35362011-05-11 Nathan Froyd <froydnj@codesourcery.com>
3537
3538 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
3539 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
3540 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
3541
35422011-05-07 Eric Botcazou <ebotcazou@adacore.com>
3543
3544 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
3545
3546 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
3547 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
3548
35492011-05-05 Nathan Froyd <froydnj@codesourcery.com>
3550
3551 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
3552
35532011-05-05 Nathan Froyd <froydnj@codesourcery.com>
3554
3555 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
3556 instead of accessing TYPE_ARG_TYPES directly.
3557 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
3558
35592011-05-05 Eric Botcazou <ebotcazou@adacore.com>
3560
3561 PR ada/48844
3562 * gcc-interface/gigi.h (get_variant_part): Declare.
3563 * gcc-interface/decl.c (get_variant_part): Make global.
3564 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
3565 types have the same constant size, are record types and T1 has a
3566 variant part while T2 doesn't.
3567
35682011-05-05 Eric Botcazou <ebotcazou@adacore.com>
3569
3570 * gcc-interface/utils.c (begin_subprog_body): Do not call
3571 get_pending_sizes.
3572 (end_subprog_body): Likewise.
3573
35742011-05-04 Richard Guenther <rguenther@suse.de>
3575
3576 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
3577 int_const_binop.
3578 (pos_to_constructor): Likewise.
3579
35802011-05-03 Nathan Froyd <froydnj@codesourcery.com>
3581 Eric Botcazou <ebotcazou@adacore.com>
3582
3583 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
3584 of build_function_type. Adjust calls to...
3585 (build_raise_check): ...this. Do not take a void_tree parameter.
3586 Call build_function_type_list instead of build_function_type.
3587 Fix head comment and swap couple of conditional blocks.
3588
35892011-04-30 Eric Botcazou <ebotcazou@adacore.com>
3590
3591 * gnatvsn.ads (Library_Version): Bump to 4.7.
3592 (Current_Year): Bump to 2011.
3593
35942011-04-29 Michael Matz <matz@suse.de>
3595
3596 * gcc-interface/misc.c (gnat_handle_option): Set
3597 warn_maybe_uninitialized.
3598
35992011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
3600
3601 * gnat_ugn.texi (Complexity Metrics Control): Update link to
3602 the Watson/McCabe paper.
3603
36042011-04-23 Jim Meyering <meyering@redhat.com>
3605
3606 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
3607
36082011-04-22 Eric Botcazou <ebotcazou@adacore.com>
3609
3610 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
3611 onto the new type.
3612
36132011-04-22 Eric Botcazou <ebotcazou@adacore.com>
3614
3615 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
3616 parameter.
3617 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
3618 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
3619 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
3620 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
3621 <all>: Do not set flags on the reused DECL node coming from an alias.
3622 Set DECL_IGNORED_P on the DECL node built for subprograms if they
3623 don't need debug info here...
3624 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
3625 (gigi): Adjust calls to create_subprog_decl.
3626 (build_raise_check): Likewise.
3627 (establish_gnat_vms_condition_handler): Likewise.
3628 (Compilation_Unit_to_gnu): Likewise.
3629 (gnat_to_gnu): Likewise.
3630
36312011-04-21 Eric Botcazou <ebotcazou@adacore.com>
3632
3633 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
3634 (NO_REORDER_ADAFLAGS): New variable.
3635 (EXTRA_GNATTOOLS): Always define.
3636 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
3637 Clean up and adjust list of files compiled with special options.
3638 * gcc-interface/Make-lang.in: Likewise.
3639 (ada/decl.o): Cosmetical change.
3640 (ada/misc.o): Remove dependency on $(PLUGIN_H).
3641
36422011-04-20 Jim Meyering <meyering@redhat.com>
3643
3644 * initialize.c (__gnat_initialize): Remove useless if-before-free.
3645
36462011-04-17 Eric Botcazou <ebotcazou@adacore.com>
3647
3648 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
3649 $(CFLAGS) on the link line.
3650
36512011-04-17 Eric Botcazou <ebotcazou@adacore.com>
3652
3653 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
3654 padded type built for the return type if it is unconstrained.
3655
36562011-04-14 Nathan Froyd <froydnj@codesourcery.com>
3657
3658 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
3659
36602011-04-12 Nathan Froyd <froydnj@codesourcery.com>
3661
3662 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
3663 before calling TREE_CHAIN.
3664 * gcc-interface/misc.c (gnat_init_ts): New function.
3665 (LANG_HOOKS_INIT_TS): Define.
3666
36672011-04-12 Martin Jambor <mjambor@suse.cz>
3668
3669 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
3670 instead of cgraph_node.
3671
36722011-04-08 Eric Botcazou <ebotcazou@adacore.com>
3673
3674 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
3675 alignment on fields of the RETURN type built for the Copy-In Copy-Out
3676 mechanism.
3677
36782011-04-08 Eric Botcazou <ebotcazou@adacore.com>
3679
3680 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
3681 of aggregate types that contain a placeholder.
3682
36832011-04-08 Nathan Froyd <froydnj@codesourcery.com>
3684
3685 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
3686 TYPE_ARG_TYPES.
3687 (handle_type_generic_attribute): Likewise.
3688
36892011-04-04 Eric Botcazou <ebotcazou@adacore.com>
3690
3691 PR ada/47163
3692 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
3693
36942011-04-04 Kai Tietz <ktietz@redhat.com>
3695
3696 PR ada/47163
3697 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
3698 to flag value.
3699
37002011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3701
3702 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
3703 type case, do not strip a padding type around the array type.
3704
37052011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3706
3707 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
3708 types.
3709
37102011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3711
3712 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
3713 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
3714 code for -feliminate-unused-debug-types.
3715 (gnat_post_options): Likewise.
3716
37172011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3718
3719 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
3720 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
3721 distinct copy.
3722
37232011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3724
3725 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
3726 DECL_ARTIFICIAL flag on enumeration types.
3727
37282011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3729
3730 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
3731 fat pointer types artificial unconditionally.
3732 <E_Array_Subtype>: Attach the base array type as a parallel type if it
3733 isn't artificial.
3734
37352011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3736
3737 * gcc-interface/gigi.h (get_dummy_type): Declare.
3738 (build_dummy_unc_pointer_types): Likewise.
3739 (finish_fat_pointer_type): Likewise.
3740 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
3741 fat pointer type has been built, complete it in place.
3742 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
3743 and thin pointers. Remove useless variable.
3744 (finish_fat_pointer_type): Make global and move to...
3745 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
3746 (get_dummy_type): New function.
3747 (build_dummy_unc_pointer_types): Likewise.
3748 (gnat_pushdecl): Propage the name to the anonymous variants only.
3749 (update_pointer_to): Only adjust the pointer types in the unconstrained
3750 array case.
3751
37522011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3753
3754 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
3755 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
3756 if this is a Taft amendment type and the full declaration is available.
3757 * gcc-interface/trans.c (process_type): Likewise.
3758 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
3759 (process_freeze_entity): Likewise.
3760 * gcc-interface/utils.c (dummy_global): New static variable.
3761 (gnat_write_global_declarations): If there are types declared as used
3762 at the global level, insert them in the global hash table.
3763
37642011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3765
3766 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
3767 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
3768 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
3769 copy.
3770 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
3771 flag of the type accordingly.
3772 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
3773
37742011-04-02 Eric Botcazou <ebotcazou@adacore.com>
3775
3776 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
3777 finalizing types when updating the pointers to the designated type.
3778 <all>: Finalize the deferred types even if we didn't defer processing
3779 of incomplete types in this invocation.
3780
37812011-04-01 Olivier Hainque <hainque@adacore.com>
3782 Nicolas Setton <setton@adacore.com>
3783 Eric Botcazou <ebotcazou@adacore.com>
3784
3785 * gcc-interface/misc.c (gnat_descriptive_type): New function.
3786 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
3787
37882011-03-28 Kai Tietz <ktietz@redhat.com>
3789
3790 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
3791 Windows targets.
3792 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
3793 * system-mingw.ads (System): Change ZCX_By_Default default to True.
3794
3795 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
3796
37972011-03-28 Tristan Gingold <gingold@adacore.com>
3798
3799 PR ada/44431
3800 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
3801 Use ada output of gnatbind.
3802 (ada/b_gnatb.adb): Ditto.
3803 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
3804 (ada.mostlyclean, ada.stage1)
3805 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
3806 (ada.stagefeedback): Adjust.
3807 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
3808 Use ada output of gnatbind.
3809 (b_gnatm.adb): Ditto.
3810 (b_gnatl.o, b_gnatm.o): New rules.
3811
38122011-03-26 Eric Botcazou <ebotcazou@adacore.com>
3813
3814 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
3815 for the padded type built to support a specified size or alignment.
3816
38172011-03-26 Eric Botcazou <ebotcazou@adacore.com>
3818
3819 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
3820 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
3821 unconditionally to the end of the unit when the designated type is
3822 limited_with'ed.
3823 <all>: Rename local variable. Attempt to un-defer types only and do it
3824 for limited_with'ed types as well.
3825 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
3826 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
3827 consistently and remove redundant call to finalize_from_with_types.
3828
38292011-03-26 Eric Botcazou <ebotcazou@adacore.com>
3830
3831 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
3832 subprograms without a previous spec declared in the same unit.
3833 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
3834 subprograms at the end of the unit instead of at the beginning.
3835 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
3836 isn't public for the special handling of non-inline functions nested
3837 inside inline external functions.
3838
38392011-03-25 Jeff Law <law@redhat.com>
3840
3841 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
3842
38432011-03-24 Eric Botcazou <ebotcazou@adacore.com>
3844
3845 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
3846 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
3847 to compute Set_Size_Depends_On_Discriminant.
3848 (Layout_Type): Call it on array types in back-end layout mode.
3849 * sem_util.adb (Requires_Transient_Scope): Return true for array
3850 types only if the size depends on the value of discriminants.
3851 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
3852 type if the RHS is a call to a function that returns an unconstrained
3853 type with default discriminant.
3854
38552011-03-24 Eric Botcazou <ebotcazou@adacore.com>
3856
3857 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
3858 non-conversion to the nominal result type at the end.
3859
38602011-03-23 Eric Botcazou <ebotcazou@adacore.com>
3861
3862 * gcc-interface/trans.c (create_temporary): New function taken from...
3863 (create_init_temporary): ...here. Call it.
3864 (call_to_gnu): Create the temporary for the return value early, if any.
3865 Create it for a function with copy-in/copy-out parameters if there is
3866 no target; in other cases of copy-in/copy-out, use another temporary.
3867 Push the new binding level lazily. Add and rename local variables.
3868
38692011-03-23 Eric Botcazou <ebotcazou@adacore.com>
3870
3871 * gcc-interface/decl.c (validate_size): Improve comments and tweak
3872 error message.
3873 (set_rm_size): Likewise.
3874
38752011-03-23 Eric Botcazou <ebotcazou@adacore.com>
3876
3877 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
3878 for the padded type built in order to support a specified alignment.
3879 Fix incorrect formatting.
3880
38812011-03-21 Eric Botcazou <ebotcazou@adacore.com>
3882
3883 PR bootstrap/48216
3884 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
3885
38862011-03-21 Eric Botcazou <ebotcazou@adacore.com>
3887
3888 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
3889 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
3890 to the end of the list. Adjust recursive call. Rename local variable.
3891 If REORDER is true, reorder components of the record type.
3892 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
3893 components_to_record and adjust the parameter list.
3894
38952011-03-21 Eric Botcazou <ebotcazou@adacore.com>
3896
3897 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
3898 disabled, use the variable for bounds of loop iteration scheme.
3899
39002011-03-21 Kai Tietz <ktietz@redhat.com>
3901
3902 PR target/12171
3903 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
3904
39052011-03-17 Eric Botcazou <ebotcazou@adacore.com>
3906
3907 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
3908 out whether the expression is read-only. Short-circuit placeholder
3909 case and rename a couple of local variables.
3910
39112011-03-17 Eric Botcazou <ebotcazou@adacore.com>
3912
3913 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
3914 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
3915 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
3916 (convert): Deal with conversions from a smaller form type specially.
3917
39182011-02-14 Eric Botcazou <ebotcazou@adacore.com>
3919
3920 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
3921 its argument, except for the special -I- switch.
3922
39232011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
3924
3925 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
3926 "Ada Issues".
3927
39282011-02-08 Eric Botcazou <ebotcazou@adacore.com>
3929
3930 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
3931
39322011-02-03 Eric Botcazou <ebotcazou@adacore.com>
3933
3934 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
3935 GNAT_FORMAL.
3936 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
3937 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
3938 instead of GNAT_FORMAL. Protect the expression against multiple uses.
3939 Do not generate the check directly, instead instantiate the template
3940 check present in the descriptor.
3941 (make_descriptor_field): Move around.
3942 (build_vms_descriptor32): Build a template check in the POINTER field.
3943 (build_vms_descriptor): Remove useless suffixes.
3944 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
3945
39462011-01-26 Eric Botcazou <ebotcazou@adacore.com>
3947
3948 PR bootstrap/47467
3949 * targext.c: Include target files if IN_RTS is defined.
3950
39512011-01-26 Richard Guenther <rguenther@suse.de>
3952
3953 PR bootstrap/47467
3954 * targext.c: Include config.h.
3955 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
3956 dependency.
3957
39582011-01-04 Pascal Obry <obry@adacore.com>
3959 Eric Botcazou <ebotcazou@adacore.com>
3960
3961 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
3962
39632011-01-04 Eric Botcazou <ebotcazou@adacore.com>
3964
3965 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
3966 end-of-case on the end label and its associated gotos, if any.
3967
39682011-01-04 Eric Botcazou <ebotcazou@adacore.com>
3969
3970 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
3971 expressions of the parameter cache within the statement group of
3972 the CICO mechanism.
3973
39742011-01-04 Olivier Hainque <hainque@adacore.com>
3975 Eric Botcazou <ebotcazou@adacore.com>
3976
3977 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
3978 (set_end_locus_from_node): New function.
3979 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
3980 make and the function end_locus.
3981 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
3982 for the elaboration subprogram.
3983 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
3984 set the end_locus of the expression as well.
3985
39862011-01-04 Eric Botcazou <ebotcazou@adacore.com>
3987
3988 PR ada/47131
3989 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
3990 variables that are referenced in exception handlers volatile.
3991
3992
3993\f
3994Copyright (C) 2011 Free Software Foundation, Inc.
3995
3996Copying and distribution of this file, with or without modification,
3997are permitted in any medium without royalty provided the copyright
3998notice and this notice are preserved.
3999
4000 * gnat_rm.texi: Ramification of pragma Eliminate documentation
4001 - fix bugs in the description of Source_Trace;
4002 - get rid of UNIT_NAME;
4003
4fbad0ba
AC
40042011-08-02 Javier Miranda <miranda@adacore.com>
4005
4006 * exp_ch9.adb
4007 (Build_Dispatching_Requeue): Adding support for VM targets
4008 since we cannot directly reference the Tag entity.
4009 * exp_sel.adb (Build_K): Adding support for VM targets.
4010 (Build_S_Assignment): Adding support for VM targets.
4011 * exp_disp.adb
4012 (Default_Prim_Op_Position): In VM targets do not restrict availability
4013 of predefined interface primitives to compiling in Ada 2005 mode.
4014 (Is_Predefined_Interface_Primitive): In VM targets this service is not
4015 restricted to compiling in Ada 2005 mode.
4016 (Make_VM_TSD): Generate code that declares and initializes the OSD
4017 record. Needed to support dispatching calls through synchronized
4018 interfaces.
4019 * exp_ch3.adb
4020 (Make_Predefined_Primitive_Specs): Enable generation of predefined
4021 primitives associated with synchronized interfaces.
4022 (Make_Predefined_Primitive_Bodies): Enable generation of predefined
4023 primitives associated with synchronized interfaces.
4024
40252011-08-02 Yannick Moy <moy@adacore.com>
4026
4027 * par-ch11.adb (P_Handled_Sequence_Of_Statements): mark a sequence of
4028 statements hidden in SPARK if preceded by the HIDE directive
4029 (Parse_Exception_Handlers): mark each exception handler in a sequence of
4030 exception handlers as hidden in SPARK if preceded by the HIDE directive
4031 * par-ch6.adb (P_Subprogram): mark a subprogram body hidden in SPARK
4032 if starting with the HIDE directive
4033 * par-ch7.adb (P_Package): mark a package body hidden in SPARK if
4034 starting with the HIDE directive; mark the declarations in a private
4035 part as hidden in SPARK if the private part starts with the HIDE
4036 directive
4037 * restrict.adb, restrict.ads
4038 (Set_Hidden_Part_In_SPARK): record a range of slocs as hidden in SPARK
4039 (Is_In_Hidden_Part_In_SPARK): new function which returns whether its
4040 argument node belongs to a part which is hidden in SPARK
4041 (Check_SPARK_Restriction): do not issue violations on nodes in hidden
4042 parts in SPARK; protect the possibly costly call to
4043 Is_In_Hidden_Part_In_SPARK by a check that the SPARK restriction is on
4044 * scans.ads (Token_Type): new value Tok_SPARK_Hide in enumeration
4045 * scng.adb (Accumulate_Token_Checksum_GNAT_6_3,
4046 Accumulate_Token_Checksum_GNAT_5_03): add case for new token
4047 Tok_SPARK_Hide.
4048 (Scan): recognize special comment starting with '#' and followed by
4049 SPARK keyword "hide" as a HIDE directive.
4050
40512011-08-02 Yannick Moy <moy@adacore.com>
4052
4053 * types.ads, erroutc.ads: Minor reformatting.
4054
40552011-08-02 Vincent Celier <celier@adacore.com>
4056
4057 * link.c: Add response file support for cross platforms.
4058
6ff6152d
ES
40592011-08-02 Ed Schonberg <schonberg@adacore.com>
4060
4061 * sem_aggr.adb (Resolve_Array_Aggregate): when copying the expression
4062 in an association, set parent field of copy before partial analysis.
4063 * sem_res.adb (Resolve_Slice): create reference to itype only when
4064 expansion is enabled.
4065
975c6896
YM
40662011-08-02 Yannick Moy <moy@adacore.com>
4067
4068 * einfo.adb, einfo.ads (Body_Is_In_ALFA, Set_Body_Is_In_ALFA): get/set
4069 for new flag denoting which subprogram bodies are in ALFA
4070 * restrict.adb, sem_ch7.adb: Update comment
4071 * sem_ch11.adb, sem_ch2.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
4072 sem_ch9.adb, sem_res.adb: Add calls to
4073 Current_Subprogram_Body_Is_Not_In_ALFA on unsupported constructs.
4074 * sem_ch6.adb (Analyze_Function_Return): add calls to
4075 Current_Subprogram_Body_Is_Not_In_ALFA on return statement in the
4076 middle of the body, and extended return.
4077 (Check_Missing_Return): add calls to Set_Body_Is_In_ALFA with argument
4078 False when missing return.
4079 (Analyze_Subprogram_Body_Helper): initialize the flag Body_Is_In_ALFA
4080 to True for subprograms whose spec is in ALFA. Remove later on the flag
4081 on the entity used for a subprogram body when there exists a separate
4082 declaration.
4083 * sem_util.adb, sem_util.ads (Current_Subprogram_Body_Is_Not_In_ALFA):
4084 if Current_Subprogram is not Empty, set its flag Body_Is_In_ALFA to
4085 False, otherwise do nothing.
4086
afc8324d
AC
40872011-08-02 Robert Dewar <dewar@adacore.com>
4088
4089 * inline.adb, stand.ads, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
4090
40912011-08-02 Yannick Moy <moy@adacore.com>
4092
4093 * sem_ch4.ads: minor formatting.
4094
2ba431e5
YM
40952011-08-02 Yannick Moy <moy@adacore.com>
4096
4097 * sem_aggr.adb, err_vars.ads, sem_ch3.adb, sem_ch5.adb, sem_ch9.adb,
4098 debug.adb, sem_util.adb, sem_res.adb, sem_attr.adb, gnat1drv.adb,
4099 errout.adb, errout.ads, exp_ch6.adb, sem_ch4.adb, restrict.adb,
4100 restrict.ads, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb,
4101 opt.ads: cleanup of SPARK mode
4102
0f853035
YM
41032011-08-02 Yannick Moy <moy@adacore.com>
4104
4105 * cstand.adb (Create_Standard): sets Is_In_ALFA component of standard
4106 types.
4107 * einfo.adb, einfo.ads (Is_In_ALFA): add flag for all entities
4108 (Is_In_ALFA, Set_Is_In_ALFA): new subprograms to access flag Is_In_ALFA
4109 * sem_ch3.adb
4110 (Analyze_Object_Declaration): set Is_In_ALFA flag for objects
4111 (Constrain_Enumeration): set Is_In_ALFA flag for enumeration subtypes
4112 (Constrain_Integer): set Is_In_ALFA flag for integer subtypes
4113 (Enumeration_Type_Declaration): set Is_In_ALFA flag for enumeration
4114 types.
4115 (Set_Scalar_Range_For_Subtype): unset Is_In_ALFA flag for subtypes with
4116 non-static range.
4117 * sem_ch6.adb (Analyze_Return_Type): unset Is_In_ALFA flag for
4118 functions whose return type is not in ALFA.
4119 (Analyze_Subprogram_Specification): set Is_In_ALFA flag for subprogram
4120 specifications.
4121 (Process_Formals): unset Is_In_ALFA flag for subprograms if a
4122 parameter's type is not in ALFA.
4123 * stand.ads (Standard_Type_Is_In_ALFA): array defines which standard
4124 types are in ALFA.
4125
d2b10647
ES
41262011-08-02 Ed Schonberg <schonberg@adacore.com>
4127
4128 * sem_ch6 (Analyze_Expression_Function): treat the function as
4129 Inline_Always, and introduce a subprogram declaration for it when it is
4130 not a completion.
4131 * inline.adb (Add_Inlined_Body): recognize bodies that come from
4132 expression functions, so that the back-end can determine whether they
4133 can in fact be inlined.
4134 * sem_util.adb (Is_Expression_Function): predicate to determine whether
4135 a function body comes from an expression function.
4136
c7b9d548
AC
41372011-08-02 Gary Dismukes <dismukes@adacore.com>
4138
4139 * sem_ch6.adb (Check_Conformance): Revise the check for nonconforming
4140 null exclusions to test Can_Never_Be_Null on the anonymous access types
4141 of the formals rather than testing the formals themselves. Exclude this
4142 check in cases where the Old_Formal is marked as a controlling formal,
4143 to avoid issuing spurious errors for bodies completing dispatching
4144 operations (due to the flag not getting set on controlling access
4145 formals in body specs).
4146 (Find_Corresponding_Spec): When checking full and subtype conformance of
4147 subprogram bodies in instances, pass Designated and E in that order, for
4148 consistency with the expected order of the formals (New_Id followed by
4149 Old_Id).
4150
41512011-08-02 Robert Dewar <dewar@adacore.com>
4152
4153 * sem_ch8.adb: Minor reformatting.
4154
1138cf59
AC
41552011-08-02 Ed Schonberg <schonberg@adacore.com>
4156
4157 * sem_ch8.adb (Analyze_Subprogram_Renaming): new procedure
4158 Check_Class_Wide_Actual, to implement AI05-0071, on defaulted
4159 primitive operations of class-wide actuals.
4160
41612011-08-02 Javier Miranda <miranda@adacore.com>
4162
4163 * exp_atag.ads, exp_atag.adb
4164 (Build_Common_Dispatching_Select_Statements): Remove argument Loc
4165 since its value is implicitly passed in argument Typ.
4166 * exp_disp.adb (Make_Disp_Conditional_Select_Body,
4167 Make_Disp_Timed_Select_Body): Remove Loc in calls to routine
4168 Build_Common_Dispatching_Select_Statements.
4169
7b9db926
RD
41702011-08-02 Robert Dewar <dewar@adacore.com>
4171
4172 * sem_ch3.adb, exp_atag.ads, get_scos.adb, get_scos.ads,
4173 exp_disp.adb, lib-xref.adb, lib-xref.ads: Update comments.
4174 Minor reformatting.
4175
e8374e7a
AC
41762011-08-02 Robert Dewar <dewar@adacore.com>
4177
4178 * sem_res.adb: Minor reformatting.
4179 * sem_prag.adb: Minor reformatting.
4180
41812011-08-02 Javier Miranda <miranda@adacore.com>
4182
4183 * exp_atag.adb, exp_atags.ads
4184 (Build_Common_Dispatching_Select_Statement): Replace argument DT_Ptr
4185 by the tagged type Entity. Required to use this routine in the VM
4186 targets since we do not have available the Tag entity in the VM
4187 platforms.
4188 * exp_ch6.adb
4189 (Expand_N_Subprogram_Body): Do not invoke Build_VM_TSDs if package
4190 Ada.Tags has not been previously loaded.
4191 * exp_ch7.adb
4192 (Expand_N_Package_Declaration, Expand_N_Package_Body): Do not invoke
4193 Build_VM_TSDs if package Ada.Tags has not been previously loaded.
4194 * sem_aux.adb
4195 (Enclosing_Dynamic_Scope): Add missing support to handle the full
4196 view of enclosing scopes. Required to handle enclosing scopes that
4197 are synchronized types whose full view is a task type.
4198 * exp_disp.adb
4199 (Build_VM_TSDs): Minor code improvement to avoid generating and
4200 analyzing lists with empty nodes.
4201 (Make_Disp_Asynchronous_Select_Body): Add support for VM targets.
4202 (Make_Disp_Conditional_Select_Body): Add support for VM targets.
4203 (Make_Disp_Get_Prim_Op_Kind): Add support for VM targets.
4204 (Make_Disp_Timed_Select_Body): Add support for VM targets.
4205 (Make_Select_Specific_Data_Table): Add support for VM targets.
4206 (Make_VM_TSD): Generate code to initialize the SSD structure of
4207 the TSD.
4208
42092011-08-02 Yannick Moy <moy@adacore.com>
4210
4211 * lib-writ.adb (Write_ALI): when ALFA mode is set, write local
4212 cross-references section in ALI.
4213 * lib-xref.adb, lib-xref.ads (Xref_Entry): add components Sub
4214 (enclosing subprogram), Slc (location of Sub) and Sun (unit number of
4215 Sub).
4216 (Enclosing_Subprogram_Or_Package): new function to return the enclosing
4217 subprogram or package entity of a node
4218 (Is_Local_Reference_Type): new function returns True for references
4219 selected in local cross-references.
4220 (Lt): function extracted from Lt in Output_References
4221 (Write_Entity_Name): function extracted from Output_References
4222 (Generate_Definition): generate reference with type 'D' for definition
4223 of objects (object declaration and parameter specification), with
4224 appropriate locations and units, for use in local cross-references.
4225 (Generate_Reference): update fields Sub, Slc and Sun. Keep newly created
4226 references of type 'I' for initialization in object definition.
4227 (Output_References): move part of function Lt and procedure
4228 Write_Entity_Name outside of the body. Ignore references of types 'D'
4229 and 'I' introduced for local cross-references.
4230 (Output_Local_References): new procedure to output the local
4231 cross-references sections.
4232 (Lref_Entity_Status): new array defining whether an entity is a local
4233 * sem_ch3.adb (Analyze_Object_Declaration): call Generate_Reference
4234 with 'I' type when initialization expression is present.
4235 * get_scos.adb, get_scos.ads: Correct comments and typos
4236
1f6439e3
AC
42372011-08-02 Javier Miranda <miranda@adacore.com>
4238
4239 * exp_ch6.adb (Expand_N_Subprogram_Body): Enable generation of TSDs in
4240 the JVM target.
4241 * exp_ch7.adb (Expand_N_Package_Body): Enable generation of TSDs in
4242 the JVM target.
4243 * exp_disp.adb (Build_VM_TSDs): No action needed if the runtime has no
4244 TSD support.
4245
42462011-08-02 Vincent Celier <celier@adacore.com>
4247
4248 * prj-nmsc.adb (File_Found): New components Excl_File and Excl_Line
4249 (No_Space_Img): New function
4250 (Find_Excluded_Sources): When reading from a file, record the file name
4251 and the line number for each excluded source.
4252 (Mark_Excluded_Sources): When reporting an error, if the excluded
4253 sources were read from a file, include file name and line number in
4254 the error message.
4255
42562011-08-02 Ed Schonberg <schonberg@adacore.com>
4257
4258 * sem_res.adb (Resolve_Call): implement rule in RM 12.5.1 (23.3/2).
4259
ab027d28
RD
42602011-08-02 Robert Dewar <dewar@adacore.com>
4261
4262 * exp_ch7.adb exp_ch6.adb, exp_disp.adb: Minor reformatting
4263
b3b28b0c
JM
42642011-08-02 Javier Miranda <miranda@adacore.com>
4265
4266 * exp_ch6.adb (Expand_N_Subprogram_Body): Temporarily restrict the
4267 generation of TSDs to the DOTNET compiler.
4268 * exp_ch7.adb (Expand_N_Package_Body): Temporarily restrict the
4269 generation of TSDs to the DOTNET compiler.
4270
9732e886
JM
42712011-08-02 Javier Miranda <miranda@adacore.com>
4272
4273 * exp_disp.ads (Build_VM_TSDs): Build the runtime Type Specific Data
4274 record of all the tagged types declared inside library level package
4275 declarations, library level package bodies or library level subprograms.
4276 * exp_disp.adb (Make_VM_TSD): New subprogram that builds the TSD
4277 associated with a given tagged type.
4278 (Build_VM_TSDs): New subprogram.
4279 * exp_ch6.adb (Expand_N_Subprogram_Body): Generate TSDs records of main
4280 compilation units that are subprograms.
4281 * exp_ch7.adb (Expand_N_Package_Body): Generate TSDs of main
4282 compilation units that are package bodies.
4283 (Expand_N_Package_Declaration): Generate TSDs of the main compilation
4284 units that are a package declaration or a package instantiation.
4285 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Minor code
4286 reorganization to improve the error generated by the frontend when the
4287 function Ada.Tags.Secondary_Tag is not available.
4288 * rtsfind.ads (RE_Register_TSD): New runtime entity.
4289 * exp_ch4.adb (Expand_N_Type_Conversion): Minor code cleanup.
4290
e526d0c7
AC
42912011-08-02 Javier Miranda <miranda@adacore.com>
4292
4293 * exp_disp.adb (Make_DT): Generate call to Check_TSD in Ada 2005 mode.
4294
42952011-08-02 Robert Dewar <dewar@adacore.com>
4296
4297 * s-imenne.ads: Minor reformatting.
4298
42992011-08-02 Robert Dewar <dewar@adacore.com>
4300
4301 * a-stunau.ads: Add pragma Suppress_Initialization for Big_String
4302 * freeze.adb (Warn_Overlay): Don't warn if initialization suppressed
4303 * s-stalib.ads: Add pragma Suppress_Initialization for Big_String
4304
43052011-08-02 Robert Dewar <dewar@adacore.com>
4306
4307 * einfo.ads (Materialize_Entity): Document this is only for renamings
4308 * exp_ch3.adb (Expand_N_Object_Declaration): Make sure we generate
4309 required debug information in the case where we transform the object
4310 declaration into a renaming declaration.
4311 * exp_ch4.adb (Expand_Concatenate): Generate debug info for result
4312 object
4313 * exp_dbug.ads (Debug_Renaming_Declaration): Document setting of
4314 Materialize_Entity.
4315
5b1e6aca
RD
43162011-08-02 Robert Dewar <dewar@adacore.com>
4317
4318 * einfo.ads, einfo.adb (Suppress_Initialization): Replaces
4319 Suppress_Init_Procs.
4320 * exp_ch3.adb, exp_disp.adb, freeze.adb: Use
4321 Suppress_Initialization/Initialization_Suppressed.
4322 * gnat_rm.texi: New documentation for pragma Suppress_Initialization
4323 * sem_aux.ads, sem_aux.adb (Initialization_Suppressed): New function
4324 * sem_dist.adb: Use Suppress_Initialization/Initialization_Suppressed
4325 * sem_prag.adb: New processing for pragma Suppress_Initialization.
4326
5ad4969d
RD
43272011-08-02 Robert Dewar <dewar@adacore.com>
4328
4329 * gnat_rm.texi, a-tags.ads, sem_prag.adb, sem_ch12.adb, exp_disp.adb:
4330 Minor reformatting.
4331
8c4ee6f5
AC
43322011-08-02 Ed Schonberg <schonberg@adacore.com>
4333
4334 * sem_prag.adb (Chain_PPC): Implement AI04-0230: null procedures can
4335 only have inheritable classwide pre/postconditions.
4336
43372011-08-02 Javier Miranda <miranda@adacore.com>
4338
4339 * a-tags.ads, a-tags.adb (Check_TSD): New subprogram.
4340 * rtsfind.ads (RE_Check_TSD): New runtime entity.
4341 * exp_disp.adb (Make_DT): Generate call to the new runtime routine that
4342 checks if the external tag of a type is the same as the external tag
4343 of some other declaration.
4344
0b3d16c0
AC
43452011-08-02 Thomas Quinot <quinot@adacore.com>
4346
4347 * s-taskin.ads: Minor reformatting.
4348
43492011-08-02 Emmanuel Briot <briot@adacore.com>
4350
4351 * g-comlin.adb (Display_Help): swap the order in which it prints the
4352 short help and the general usage.
4353
43542011-08-02 Ed Schonberg <schonberg@adacore.com>
4355
4356 * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): copy properly
4357 the aspect declarations and attach them to the generic copy for
4358 subsequent analysis.
4359 (Analyze_Subprogram_Instantiation): copy explicitly the aspect
4360 declarations of the generic tree to the new subprogram declarations.
4361 * sem_attr.adb (Check_Precondition_Postcondition): recognize
4362 conditions that apply to a subprogram instance.
4363
43642011-08-02 Robert Dewar <dewar@adacore.com>
4365
4366 * gnat_rm.texi: Clarify doc on pragma Source_File_Name[_Project].
4367
43682011-08-02 Ed Schonberg <schonberg@adacore.com>
4369
4370 * sem_ch3.adb (Derived_Type_Declaration): When checking that a untagged
4371 private type with a tagged full view is not derived in the immediate
4372 scope of the partial view, (RM 7.3 (7)) use the scope of the base type.
4373
4637729f
AC
43742011-08-02 Robert Dewar <dewar@adacore.com>
4375
4376 * exp_ch4.adb: Minor reformatting.
4377
43782011-08-02 Ed Schonberg <schonberg@adacore.com>
4379
4380 * sem_ch5.adb (Analyze_Loop_Statement): If the iteration scheme is an
4381 Ada2012 iterator, the loop will be rewritten during expansion into a
4382 while loop with a cursor and an element declaration. Do not analyze the
4383 body in this case, because if the container is for indefinite types the
4384 actual subtype of the elements will only be determined when the cursor
4385 declaration is analyzed.
4386
43872011-08-02 Arnaud Charlet <charlet@adacore.com>
4388
4389 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): Ignore
4390 size/alignment related attributes in CodePeer_Mode.
4391
43922011-08-02 Gary Dismukes <dismukes@adacore.com>
4393
4394 * sem_ch3.adb (Check_Ops_From_Incomplete_Type): Remove call to
4395 Prepend_Element, since this can result in the operation getting the
4396 wrong slot in the full type's dispatch table if the full type has
4397 inherited operations. The incomplete type's operation will get added
4398 to the proper position in the full type's primitives
4399 list later in Sem_Disp.Check_Operation_From_Incomplete_Type.
4400 (Process_Incomplete_Dependents): Add Is_Primitive test when checking for
4401 dispatching operations, since there are cases where nonprimitive
4402 subprograms can get added to the list of incomplete dependents (such
4403 as subprograms in nested packages).
4404 * sem_ch6.adb (Process_Formals): First, remove test for being in a
4405 private part when determining whether to add a primitive with a
4406 parameter of a tagged incomplete type to the Private_Dependents list.
4407 Such primitives can also occur in the visible part, and should not have
4408 been excluded from being private dependents.
4409 * sem_ch7.adb (Uninstall_Declarations): When checking the rule of
4410 RM05-3.10.1(9.3/2), test that a subprogram in the Private_Dependents
4411 list of a Taft-amendment incomplete type is a primitive before issuing
4412 an error that the full type must appear in the same unit. There are
4413 cases where nonprimitives can be in the list (such as subprograms in
4414 nested packages).
4415 * sem_disp.adb (Derives_From): Use correct condition for checking that
4416 a formal's type is derived from the type of the corresponding formal in
4417 the parent subprogram (the condition was completely wrong). Add
4418 checking that was missing for controlling result types being derived
4419 from the result type of the parent operation.
4420
4c60de0c
YM
44212011-08-02 Yannick Moy <moy@adacore.com>
4422
4423 * errout.adb (First_Node): minor renaming
4424 * restrict.adb (Check_Formal_Restriction): put restriction warning on
4425 first node.
4426
f5afb270
AC
44272011-08-02 Yannick Moy <moy@adacore.com>
4428
4429 * sem_res.adb (Resolve_Logical_Op): ensure N is a binary operator
4430 before accessing operands.
4431 * sem_util.adb (Is_SPARK_Initialization_Expr): follow original nodes to
4432 decide whether an initialization expression respects SPARK rules, as
4433 the plain node is the expanded one. This allows for more valid warnings
4434 to be issued.
4435 * gnat_rm.texi: Minor update.
4436
44372011-08-02 Arnaud Charlet <charlet@adacore.com>
4438
4439 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Revert
4440 previous change.
4441
44422011-08-02 Robert Dewar <dewar@adacore.com>
4443
4444 * sem_ch3.adb, sem_ch4.adb: Minor reformatting.
4445
44462011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
4447
4448 * exp_ch5.adb (Expand_Iterator_Loop): Reformatting. Wrap the original
4449 loop statements and the element renaming declaration with a block when
4450 the element type is controlled.
4451
44522011-08-02 Yannick Moy <moy@adacore.com>
4453
4454 * sinfo.ads: Minor formatting.
4455
44562011-08-02 Ed Schonberg <schonberg@adacore.com>
4457
4458 * sem_aggr.adb (Add_Association): if the association has a box and no
4459 expression, use the Sloc of the aggregate itself for the new
4460 association.
4461 * errout.adb (First_Node): Exclude nodes with no Sloc, and always use
4462 the Original_Node.
4463
db72f10a
AC
44642011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
4465
4466 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and refactoring.
4467 When a container is provided via a function call, generate a renaming
4468 of the function result. This avoids the creation of a transient scope
4469 and the premature finalization of the container.
4470 * exp_ch7.adb (Is_Container_Cursor): Removed.
4471 (Wrap_Transient_Declaration): Remove the supression of the finalization
4472 of the list controller when the declaration denotes a container cursor,
4473 it is not needed.
4474
44752011-08-02 Yannick Moy <moy@adacore.com>
4476
4477 * restrict.adb (Check_Formal_Restriction): only issue a warning if the
4478 node is from source, instead of the original node being from source.
4479 * sem_aggr.adb
4480 (Resolve_Array_Aggregate): refine the check for a static expression, to
4481 recognize also static ranges
4482 * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration,
4483 Array_Type_Declaration): postpone the test for the type being a subtype
4484 mark after the type has been resolved, so that component-selection and
4485 expanded-name are discriminated.
4486 (Make_Index, Process_Range_Expr_In_Decl): add a parameter In_Iter_Schm
4487 to distinguish the case of an iteration scheme, so that an error is
4488 issed on a non-static range in SPARK except in an iteration scheme.
4489 * sem_ch5.adb (Analyze_Iteration_Scheme): call Make_Index with
4490 In_Iter_Schm = True.
4491 * sem_ch6.adb (Analyze_Subprogram_Specification): refine the check for
4492 user-defined operators so that they are allowed in renaming
4493 * sem_ch8.adb
4494 (Find_Selected_Component): refine the check for prefixing of operators
4495 so that they are allowed in renaming. Move the checks for restrictions
4496 on selector name after analysis discriminated between
4497 component-selection and expanded-name.
4498 * sem_res.adb (Resolve_Op_Concat_Arg): do not issue a warning on
4499 concatenation argument of string type if it is static.
4500 * sem_util.adb, sem_util.ads
4501 (Check_Later_Vs_Basic_Declarations): add a new function
4502 Is_Later_Declarative_Item to decice which declarations are allowed as
4503 later items, in the two different modes Ada 83 and SPARK. In the SPARK
4504 mode, add that renamings are considered as later items.
4505 (Enclosing_Package): new function to return the enclosing package
4506 (Enter_Name): correct the rule for homonyms in SPARK
4507 (Is_SPARK_Initialization_Expr): default to returning True on nodes not
4508 from source (result of expansion) to avoid issuing wrong warnings.
4509
45102011-08-02 Ed Schonberg <schonberg@adacore.com>
4511
4512 * errout.adb: On anything but an expression First_Node returns its
4513 argument.
4514
23685ae6
AC
45152011-08-02 Pascal Obry <obry@adacore.com>
4516
4517 * prj-proc.adb, make.adb, makeutl.adb: Minor reformatting.
4518
45192011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
4520
4521 * exp_ch5.adb (Expand_Iterator_Loop): Code cleanup and reorganization.
4522 Set the associated loop as the related expression of internally
4523 generated cursors.
4524 * exp_ch7.adb (Is_Container_Cursor): New routine.
4525 (Wrap_Transient_Declaration): Supress the finalization of the list
4526 controller when the declaration denotes a container cursor.
4527
45282011-08-02 Yannick Moy <moy@adacore.com>
4529
4530 * opt.ads (SPARK_Mode): update comment, SPARK_Mode only set through
4531 command line now.
4532 * par-ch3.adb (P_Delta_Constraint): remove check in SPARK mode that the
4533 expression is a simple expression. This check cannot be performed in
4534 the semantics, so just drop it.
4535 (P_Index_Or_Discriminant_Constraint): move check that the index or
4536 discriminant is a subtype mark to Analyze_Subtype_Declaration in the
4537 semantics. Other cases were previously checked in the semantics.
4538 * par-ch4.adb (P_Name): move checks that a selector name is not
4539 character literal or an operator symbol to Find_Selected_Component in
4540 the semantics
4541 * par-ch5.adb (Parse_Decls_Begin_End): move check that basic
4542 declarations are not placed after later declarations in a separate
4543 procedure in Sem_Util (possibly not the best choice?), to be used both
4544 during parsing, for Ada 83 mode, and during semantic analysis, for
4545 SPARK mode.
4546 * par-endh.adb (Check_End): move check that end label is not missing
4547 to Process_End_Label in the semantics
4548 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): remove
4549 the special case for SPARK restriction
4550 * par.adb: use and with Sem_Util, for use in Parse_Decls_Begin_End
4551 * restrict.adb, restrict.ads (Check_Formal_Restriction): add a
4552 parameter Force to issue the error message even on internal node (used
4553 for generated end label). Call Check_Restriction to check when an error
4554 must be issued. In SPARK mode, issue an error message even if the
4555 restriction is not set.
4556 (Check_Restriction): new procedure with an additional out parameter to
4557 inform the caller that a message has been issued
4558 * sem_aggr.adb: Minor modification of message
4559 * sem_attr.adb (Analyze_Attribute): call Check_Formal_Restriction
4560 instead of issuing an error message directly
4561 * sem_ch3.adb (Analyze_Declarations): move here the check that basic
4562 declarations are not placed after later declarations, by calling
4563 Check_Later_Vs_Basic_Declarations
4564 (Analyze_Subtype_Declaration): move here the check that an index or
4565 discriminant constraint must be a subtype mark. Change the check that
4566 a subtype of String must start at one so that it works on subtype marks.
4567 * sem_ch4.adb (Analyze_Call): move here the check that a named
4568 association cannot follow a positional one in a call
4569 * sem_ch5.adb (Check_Unreachable_Code): call Check_Formal_Restriction
4570 instead of issuing an error message directly
4571 * sem_ch8.adb (Find_Selected_Component): move here the check that a
4572 selector name is not a character literal or an operator symbol. Move
4573 here the check that the prefix of an expanded name cannot be a
4574 subprogram or a loop statement.
4575 * sem_util.adb, sem_util.ads (Check_Later_Vs_Basic_Declarations): new
4576 procedure called from parsing and semantics to check that basic
4577 declarations are not placed after later declarations
4578 (Process_End_Label): move here the check that end label is not missing
4579
45802011-08-02 Arnaud Charlet <charlet@adacore.com>
4581
4582 * sem_ch13.adb (Analyze_Enumeration_Representation_Clause): Ignore enum
4583 representation clause in codepeer mode, since it confuses CodePeer and
4584 does not bring useful info.
4585
45862011-08-02 Ed Falis <falis@adacore.com>
4587
4588 * init.c: initialize fp hw on MILS.
4589
45902011-08-02 Ed Schonberg <schonberg@adacore.com>
4591
4592 * errout.adb (First_Node): for bodies, return the node itself (small
4593 optimization). For other nodes, do not check source_unit if the node
4594 comes from Standard.
4595
d2d9cc22
AC
45962011-08-02 Robert Dewar <dewar@adacore.com>
4597
4598 * exp_ch3.adb: Minor comment additions.
4599 * sem_ch13.adb: Minor reformatting.
4600
46012011-08-02 Pascal Obry <obry@adacore.com>
4602
4603 * make.adb, makeutl.adb: Removes some superfluous directory separator.
4604
a01b9df6
AC
46052011-08-02 Robert Dewar <dewar@adacore.com>
4606
4607 * sem_attr.adb: Minor reformatting.
4608
46092011-08-02 Robert Dewar <dewar@adacore.com>
4610
4611 * einfo.adb (Has_Default_Aspect): Replaces Has_Default_Value
4612 (Has_Default_Component_Value): Removed
4613 * einfo.ads Comment updates
4614 (Has_Default_Aspect): Replaces Has_Default_Value
4615 (Has_Default_Component_Value): Removed
4616 * exp_ch13.adb
4617 (Expand_N_Freeze_Entity): Handle Default[_Component]_Value aspects
4618 * exp_ch3.adb
4619 (Build_Array_Init_Proc): Handle Default_[Component_]Value aspects
4620 (Get_Simple_Init_Val): Handle Default_Value aspect
4621 (Needs_Simple_Initialization): Handle Default_Value aspect
4622 * exp_ch3.ads: Needs_Simple_Initialization
4623 * freeze.adb (Freeze_Entity): Handle Default_[Component_]Value aspect
4624 * par-prag.adb (Pragma_Default[_Component]Value) Removed
4625 * sem_ch13.adb
4626 (Analyze_Aspect_Specifications): Fix Default[_Component]_Value aspects
4627 * sem_prag.adb (Pragma_Default[_Component]Value) Removed
4628 * snames.ads-tmpl (Pragma_Default[_Component]Value) Removed
4629
46302011-08-02 Ed Schonberg <schonberg@adacore.com>
4631
4632 * sem_ch5.adb (Analyze_Iterator_Specification): use base type to locate
4633 package containing iteration primitives.
4634 exp_ch5.adb (Expand_Iterator_Loop): ditto.
4635
75c90775
AC
46362011-08-02 Ed Schonberg <schonberg@adacore.com>
4637
4638 * sem_ch5.adb (Analyze_Iteration_Scheme): For an Ada2012 iterator with
4639 "of", pre-analyze expression in case it is a function call with
4640 finalization actions that must be placed ahead of the loop.
4641 * exp_ch5.adb (Expand_Iterator_Loop): If condition_actions are present
4642 on an Ada2012 iterator, insert them ahead of the rewritten loop.
4643
46442011-08-02 Geert Bosch <bosch@adacore.com>
4645
4646 * cstand.adb (Create_Float_Types): Only consider C's long double for
4647 Long_Long_Float, in addition to double.
4648
ded8909b
AC
46492011-08-02 Robert Dewar <dewar@adacore.com>
4650
4651 * sem_ch3.adb, sem_ch5.adb, sem_type.adb, switch-c.adb, switch-c.ads,
4652 sem_prag.adb, sem_util.adb, sem_util.ads, sem_res.adb, warnsw.ads,
4653 prepcomp.ads, cstand.adb, stand.ads, a-calfor.adb, s-stusta.adb:
4654 Minor reformatting.
4655
46562011-08-02 Ed Schonberg <schonberg@adacore.com>
4657
4658 * sem_attr.adb: handle properly 'Result when it is a prefix of an
4659 indexed component.
4660
46612011-08-02 Javier Miranda <miranda@adacore.com>
4662
4663 * einfo.ads, einfo.adb
4664 (Original_Access_Type): Move this attribute to Node26 since there was
4665 an undocumented use of Node21 in E_Access_Subprogram_Type entities
4666 which causes conflicts and breaks the generation of the .NET compiler.
4667 (Interface_Name): Add missing documentation on JGNAT only uses of
4668 this attribute.
4669
70c34e1c
AC
46702011-08-02 Geert Bosch <bosch@adacore.com>
4671
4672 * cstand.adb (Back_End_Float_Types): Use Elist instead of Nlist
4673 (Find_Back_End_Float_Type): Likewise
4674 (Create_Back_End_Float_Types): Likewise
4675 (Create_Float_Types): Likewise
4676 (Register_Float_Type): Likewise
4677 * sem_ch3.adb (Floating_Point_Type_Declaration): Use Elist instead of
4678 Nlist and split out type selection in new local Find_Base_Type function.
4679 * sem_prag.adb (Process_Import_Predefined_Type): Use Elist instead of
4680 Nlist
4681 * stand.ads (Predefined_Float_Types): Use Elist instead of Nlist
4682
46832011-08-02 Robert Dewar <dewar@adacore.com>
4684
4685 * inline.adb: Minor code reorganization (put Get_Code_Unit_Entity in
4686 alpha order).
4687 * opt.ads: Minor comment change.
4688 * sem_ch12.adb: Minor code reorganization.
4689
b715bc59
AC
46902011-08-02 Gary Dismukes <dismukes@adacore.com>
4691
4692 * sem_ch3.adb (Complete_Private_Subtype): Don't append the private
4693 subtype's list of rep items to the list on the full subtype in the case
4694 where the lists are the same.
4695
46962011-08-02 Geert Bosch <bosch@adacore.com>
4697
4698 * switch-c.adb (Free): New deallocation procedure to avoid implicitly
4699 using the one from System.Strings, which also deallocates all strings.
4700
002bdd68
AC
47012011-08-02 Geert Bosch <bosch@adacore.com>
4702
4703 * gcc-interface/gigi.h, gcc-interface/misc.c (enumerate_modes): New
4704 function.
4705 * gcc-interface/Make-lang.in: Update dependencies.
4706
47072011-08-02 Olivier Hainque <hainque@adacore.com>
4708
4709 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Set the function
4710 end_locus.
4711
499769ec
AC
47122011-08-02 Javier Miranda <miranda@adacore.com>
4713
4714 * sem_ch3.adb (Check_Anonymous_Access_Components): Create extra formals
4715 associated with anonymous access to subprograms.
4716
47172011-08-02 Geert Bosch <bosch@adacore.com>
4718
4719 * opt.ads
4720 (Preprocessing_Symbol_Defs): Move from Prepcomp.Symbol_Definitions.
4721 (Preprocessing_Symbol_Last): Move from Prepcomp.Last_Definition.
4722 * prepcomp.adb (Symbol_Definitions, Last_Definition): Move to opt.ads
4723 (Add_Symbol_Definition): Move to switch-c.adb
4724 (Process_Command_Line_Symbol_Definitions): Adjust references to above.
4725 * prepcomp.ads: Remove dependency on Ada.Unchecked_Deallocation.
4726 (Add_Symbol_Definition): Move to switch-c.adb.
4727 * sem_ch13.adb, sem_prag.adb: Add dependency on Warnsw.
4728 * sem_warn.adb
4729 (Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
4730 Move to warnsw.adb.
4731 * sem_warn.ads (Warn_On_Record_Holes, Warn_On_Overridden_Size,
4732 Set_Dot_Warning_Switch, Set_GNAT_Mode_Warnings, Set_Warning_Switch):
4733 Move to warnsw.adb.
4734 * switch-c.adb: Replace dependency on Prepcomp and Sem_Warn by Warnsw.
4735 (Add_Symbol_Definition): Moved from Prepcomp.
4736 * switch-c.ads: Update copyright notice. Use String_List instead of
4737 Argument_List, removing dependency on System.OS_Lib.
4738
aa1e353a
AC
47392011-08-02 Yannick Moy <moy@adacore.com>
4740
4741 * sem_ch3.adb (Analyze_Object_Declaration): issue an error in formal
4742 mode on initialization expression which does not respect SPARK
4743 restrictions.
4744 * sem_util.adb, sem_util.ads (Is_SPARK_Initialization_Expr): determines
4745 if the tree referenced by its argument represents an initialization
4746 expression in SPARK, suitable for initializing an object in an object
4747 declaration.
4748
47492011-08-02 Javier Miranda <miranda@adacore.com>
4750
4751 * exp_ch9.adb (Expand_Access_Protected_Subprogram_Type): Link the
4752 internally generated access to subprogram with its associated protected
4753 subprogram type.
4754 * einfo.ads, einfo.adb (Original_Access_Type): New attribute.
4755
15b682ca
GB
47562011-08-02 Geert Bosch <bosch@adacore.com>
4757
4758 * cstand.adb (Register_Float_Type): Print information about type to
4759 register, if the Debug_Flag_Dot_B is set.
4760 * debug.adb (Debug_Flag_Dot_B): Document d.b debug option.
4761 * rtsfind.ads (RE_Max_Base_Digits): New run time entity.
4762 * sem_ch3.adb (Floating_Point_Type_Declaration): Allow declarations
4763 with a requested precision of more than Max_Digits digits and no more
4764 than Max_Base_Digits digits, if a range specification is present and the
4765 Predefined_Float_Types list has a suitable type to derive from.
4766 * sem_ch3.adb (Rep_Item_Too_Early): Avoid generating error in the
4767 case of type completion with pragma Import
4768 * sem_prag.adb
4769 (Process_Import_Predefined_Type): Processing to complete a type
4770 with pragma Import. Currently supports floating point types only.
4771 (Set_Convention_From_Pragma): Do nothing without underlying type.
4772 (Process_Convention): Guard against absence of underlying type,
4773 which may happen when importing incomplete types.
4774 (Process_Import_Or_Interface): Handle case of importing predefined
4775 types. Tweak error message.
4776
f8726f2b
AC
47772011-08-02 Eric Botcazou <ebotcazou@adacore.com>
4778
4779 * inline.adb (Add_Inlined_Body): Adjust check for library-level inlined
4780 functions to previous change. Reorganize code slightly.
4781
47822011-08-02 Geert Bosch <bosch@adacore.com>
4783
4784 * back_end.ads (Register_Type_Proc): New call back procedure type for
4785 allowing the back end to provide information about available types.
4786 (Register_Back_End_Types): New procedure to register back end types.
4787 * back_end.adb (Register_Back_End_Types): Call the back end to enumerate
4788 available types.
4789 * cstand.adb (Back_End_Float_Types): New list for floating point types
4790 supported by the back end.
4791 (Build_Float_Type): Add extra parameter for Float_Rep_Kind.
4792 (Copy_Float_Type): New procedure to make new copies of predefined types.
4793 (Register_Float_Type): New call back procedure to populate the BEFT list
4794 (Find_Back_End_Float_Type): New procedure to find a BEFT by name
4795 (Create_Back_End_Float_Types): New procedure to populate the BEFT list.
4796 (Create_Float_Types): New procedure to create entities for floating
4797 point types predefined in Standard, and put these and any remaining
4798 BEFTs on the Predefined_Float_Types list.
4799 * stand.ads (Predefined_Float_Types): New list for predefined floating
4800 point types that do not have declarations in package Standard.
4801
feecad68
AC
48022011-08-02 Eric Botcazou <ebotcazou@adacore.com>
4803
4804 * inline.adb (Get_Code_Unit_Entity): New local function. Returns the
4805 entity node for the unit containing the parameter.
4806 (Add_Inlined_Body): Use it to find the unit containing the subprogram.
4807 (Add_Inlined_Subprogram): Likewise.
4808 * gcc-interface/Make-lang.in: Update dependencies.
4809
48102011-08-02 Thomas Quinot <quinot@adacore.com>
4811
4812 * s-stusta.adb (Print): Make sure Pos is always initialized to a
4813 suitable value.
4814
12f0c50c
AC
48152011-08-02 Geert Bosch <bosch@adacore.com>
4816
4817 * a-calfor.adb (Image): Simplify, removing unnecessary uses of 'Image.
4818
48192011-08-02 Eric Botcazou <ebotcazou@adacore.com>
4820
4821 * sem_type.adb (Covers): Move trivial case to the top and reuse the
4822 computed value of Base_Type.
4823
48242011-08-02 Yannick Moy <moy@adacore.com>
4825
4826 * restrict.adb (Check_Restriction): issue an error for any use of
4827 class-wide, even if the No_Dispatch restriction is not set.
4828 * sem_aggr.adb: Correct typos in comments and messages in formal mode
4829 * sem_ch3.adb (Process_Full_View): issue an error in formal mode is,
4830 when completing a private extension, the type named in the private part
4831 is not the same as that named in the visible part.
4832 * sem_res.adb (Resolve_Call): issue an error in formal mode on the use
4833 of an inherited primitive operations of a tagged type or type extension
4834 that returns the tagged type.
4835 * sem_util.adb, sem_util.ads (Is_Inherited_Operation_For_Type): new
4836 function which returns True for an implicit operation inherited by the
4837 derived type declaration for the argument type.
4838 (Is_SPARK_Object_Reference): move to appropriate place in alphabetic
4839 order.
4840
fb86fe11
ES
48412011-08-02 Ed Schonberg <schonberg@adacore.com>
4842
4843 * sem_ch5.adb (Pre_Analyze_Range): new procedure extracted from
4844 Process_Bounds, to perform analysis with expansion of a range or an
4845 expression that is the iteration scheme for a loop.
4846 (Analyze_Iterator_Specification): If domain of iteration is given by a
4847 function call with a controlled result, as is the case if call returns
4848 a predefined container, ensure that finalization actions are properly
4849 generated.
4850 * par-ch3.adb: accept Ada2012 iterator form in P_Discrete_Range.
4851
62be5d0a
JM
48522011-08-02 Javier Miranda <miranda@adacore.com>
4853
4854 * sem_ch5.adb (Analyze_Iteration_Scheme): Fix typo.
4855 * gcc-interface/Make-lang.in: Update dependencies.
4856
48572011-08-02 Javier Miranda <miranda@adacore.com>
4858
4859 * sem_util.ads, sem_util.adb (Is_Variable): Add a new formal to
4860 determine if the analysis is performed using N or Original_Node (N).
4861 * exp_util.adb (Side_Effect_Free): Code cleanup since the new
4862 functionality of routine Is_Variable avoids code duplication.
4863 * checks.adb (Determine_Range): Handle temporaries generated by
4864 Remove_Side_Effects.
4865
48662011-08-02 Javier Miranda <miranda@adacore.com>
4867
4868 * exp_ch4.adb (Expand_N_Quantified_Expression): Force reanalysis and
4869 expansion of the condition. Required since the previous analysis was
4870 done with expansion disabled (see Resolve_Quantified_Expression) and
4871 hence checks were not inserted and record comparisons have not been
4872 expanded.
4873
a20f4389
AC
48742011-08-02 Ed Falis <falis@adacore.com>
4875
4876 * s-taprop-vxworks.adb, s-intman-vxworks.adb, s-intman-vxworks.ads:
4877 Update header.
4878
48792011-08-02 Bob Duff <duff@adacore.com>
4880
4881 * opt.ads: Minor comment fix.
4882
48832011-08-02 Bob Duff <duff@adacore.com>
4884
4885 * sem_ch12.adb (Analyze_Package_Instantiation,
4886 Analyze_Subprogram_Instantiation): Turn off style checking while
4887 analyzing an instance. Whatever style checks that apply to the generic
4888 unit should apply, so it makes no sense to apply them in an instance.
4889 This was causing trouble when compiling an instance of a runtime
4890 unit that violates the -gnatyO switch.
4891 * stylesw.adb (Set_Style_Check_Options): "when 'O' =>" was missing from
4892 one of the two case statements, causing spurious errors.
4893
48942011-08-02 Robert Dewar <dewar@adacore.com>
4895
4896 * uname.adb: Minor reformatting.
4897 * gnatcmd.adb: Minor reformatting.
4898 * exp_attr.adb: Minor reformatting.
4899
90878b12
AC
49002011-08-02 Ed Schonberg <schonberg@adacore.com>
4901
4902 * exp_ch5.adb (Expand_N_Assignment_Statement): under restriction
4903 No_Dispatching_Calls, do not look for the Assign primitive, because
4904 predefined primitives are not created in this case.
4905
49062011-08-02 Bob Duff <duff@adacore.com>
4907
4908 * stylesw.ads: Minor comment fixes.
4909
49102011-08-02 Robert Dewar <dewar@adacore.com>
4911
4912 * freeze.adb (Add_To_Result): New procedure.
4913
49142011-08-02 Jose Ruiz <ruiz@adacore.com>
4915
4916 * exp_attr.adb (Find_Stream_Subprogram): When using a configurable run
4917 time, if the specific run-time routines for handling streams of strings
4918 are not available, use the default mechanism.
4919
49202011-08-02 Arnaud Charlet <charlet@adacore.com>
4921
4922 * s-regpat.ads: Fix typo.
4923
49242011-08-02 Vincent Celier <celier@adacore.com>
4925
4926 * prj-conf.adb (Get_Or_Create_Configuration_File): If On_Load_Config is
4927 not null, call it to create the in memory config project file without
4928 parsing an existing default config project file.
4929
49302011-08-02 Eric Botcazou <ebotcazou@adacore.com>
4931
4932 * atree.adb (Allocate_Initialize_Node): Remove useless temporaries.
4933
49342011-08-02 Ed Schonberg <schonberg@adacore.com>
4935
4936 * sem_elim.adb: an abstract subprogram does not need an eliminate
4937 pragma for its descendant to be eliminable.
4938
49392011-08-02 Ed Falis <falis@adacore.com>
4940
4941 * init.c: revert to handling before previous checkin for VxWorks
4942 * s-intman-vxworks.adb: delete unnecessary declarations related to
4943 using Ada interrupt facilities for handling signals.
4944 Delete Initialize_Interrupts. Use __gnat_install_handler instead.
4945 * s-intman-vxworks.ads: Import __gnat_install_handler as
4946 Initialize_Interrupts.
4947 * s-taprop-vxworks.adb: Delete Signal_Mask.
4948 (Abort_Handler): change construction of mask to unblock exception
4949 signals.
4950
273adcdf
AC
49512011-08-02 Jerome Guitton <guitton@adacore.com>
4952
4953 * a-except-2005.adb (Raise_From_Signal_Handler): Call
4954 Debug_Raise_Exception before propagation starts.
4955
49562011-08-02 Eric Botcazou <ebotcazou@adacore.com>
4957
4958 * exp_ch6.adb (Expand_Call): Guard restriction checks with a call
4959 to Restriction_Check_Required.
4960 * sem_ch3.adb (Analyze_Object_Declaration): Likewise.
4961 * sem_res.adb (Resolve_Call): Likewise.
4962 * sem_attr.adb (Check_Stream_Attribute): Likewise.
4963
49642011-08-02 Bob Duff <duff@adacore.com>
4965
4966 * stylesw.ads: Update comment.
4967 * style.adb: Minor: Use Error_Msg_NE instead of Error_Msg_N.
4968 * errout.ads: Remove obsolete comment.
4969
49702011-08-02 Javier Miranda <miranda@adacore.com>
4971
4972 * einfo.ads, einfo.adb (Is_Safe_To_Reevaluate): new function.
4973 (Set_Is_Safe_To_Reevaluate): new procedure.
4974 * sem_ch5.adb (Analyze_Assignment): Add one assertion to ensure that no
4975 assignment is allowed on safe-to-reevaluate variables.
4976 (Analyze_Iteration_Schine.Process_Bounds.One_Bound): Decorate the
4977 temporary created to remove side effects in expressions that use
4978 the secondary stack as safe-to-reevaluate.
4979 * exp_util.adb (Side_Effect_Free): Add missing code to handle well
4980 variables that are not true constants.
4981
6320f5e1
AC
49822011-08-02 Robert Dewar <dewar@adacore.com>
4983
4984 * sem_ch5.adb, sem_ch7.adb, einfo.ads, sem_util.adb, sem_util.ads,
4985 sem_res.adb, sem_ch6.adb: Minor reformatting.
4986
49872011-08-02 Jerome Guitton <guitton@adacore.com>
4988
4989 * a-except-2005.adb (Raise_Current_Excep): Remove obsolete dead code.
4990
2fe829ae
ES
49912011-08-02 Ed Schonberg <schonberg@adacore.com>
4992
4993 * sem_ch6.adb (New_Overloaded_Entity, Check_Overriding_Indicator): Do
4994 not set Overridden_Operation if subprogram is an initialization
4995 procedure.
4996
e24329cd
YM
49972011-08-02 Yannick Moy <moy@adacore.com>
4998
4999 * par-ch6.adb: Correct obsolete name in comments
5000 * restrict.adb, restrict.ads (Check_Formal_Restriction): new function
5001 which takes two message arguments (existing function takes one), with
5002 second message used for continuation.
5003 * sem_ch5.adb (Analyze_Block_Statement): in formal mode, only reject
5004 block statements that originate from a source block statement, not
5005 generated block statements
5006 * sem_ch6.adb (Analyze_Function_Call): rename L into Actuals, for
5007 symmetry with procedure case
5008 * sem_ch7.adb (Check_One_Tagged_Type_Or_Extension_At_Most): new
5009 function to issue an error in formal mode if a package specification
5010 contains more than one tagged type or type extension.
5011 * sem_res.adb (Resolve_Actuals): in formal mode, check that actual
5012 parameters matching formals of tagged types are objects (or ancestor
5013 type conversions of objects), not general expressions. Issue an error
5014 on view conversions that are not involving ancestor conversion of an
5015 extended type.
5016 (Resolve_Type_Conversion): in formal mode, issue an error on the
5017 operand of an ancestor type conversion which is not an object
5018 * sem_util.adb, sem_util.ads (Find_Actual): extend the behavior of the
5019 procedure so that it works also for actuals of function calls
5020 (Is_Actual_Tagged_Parameter): new function which determines if its
5021 argument is an actual parameter of a formal of tagged type in a
5022 subprogram call
5023 (Is_SPARK_Object_Reference): new function which determines if the tree
5024 referenced by its argument represents an object in SPARK
5025
176dadf6
AC
50262011-08-02 Robert Dewar <dewar@adacore.com>
5027
5028 * sem_ch3.adb: Minor reformatting
5029 Minor comment addition
5030 Minor error msg text change
5031
50322011-08-02 Javier Miranda <miranda@adacore.com>
5033
5034 * sem_ch5.adb (Analyze_Iteration_Scheme.Uses_Secondary_Stack): New
5035 function. Used to be more precise when we generate a variable plus one
5036 assignment to remove side effects in the evaluation of the Bound
5037 expressions.
5038 (Analyze_Iteration_Scheme): Clean attribute analyzed in all the nodes
5039 of the bound expression to force its re-analysis and thus expand the
5040 associated transient scope (if required). Code cleanup replacing the
5041 previous code that declared the constant entity by an invocation to
5042 routine Force_Evaluation which centralizes this work in the frontend.
5043
d8b962d8
AC
50442011-08-02 Robert Dewar <dewar@adacore.com>
5045
5046 * einfo.adb (Is_Base_Type): Improve efficiency by using a flag table
5047 (Base_Type): Now uses improved Is_Base_Type function
5048 * einfo.ads (Base_Type): Inline this function
5049
50502011-08-02 Robert Dewar <dewar@adacore.com>
5051
5052 * sem_prag.adb (Analyze_Pragma): Defend against infinite recursion
5053 (Analyze_Aspect_Specifications): Fix Sloc values for constructed pragmas
5054
50552011-08-02 Arnaud Charlet <charlet@adacore.com>
5056
5057 * gcc-interface/Make-lang.in: Update dependencies.
5058 * gcc-interface/Makefile.in: Use s-inmapop-vxworks.adb for all VxWorks
5059 targets.
5060
50612011-08-02 Yannick Moy <moy@adacore.com>
5062
5063 * par-ch3.adb (P_Delta_Constraint): issue an error in formal mode on
5064 non-simple expression used in delta constraint
5065 (P_Index_Or_Discriminant_Constraint): issue an error in formal mode on
5066 index constraint which is not a subtype mark
5067 * par.adb: With and use Restrict
5068 * sem_ch3.adb (Analyze_Component_Declaration): issue an error in formal
5069 mode on component type which is not a subtype mark and default
5070 expression on component
5071 (Analyze_Subtype_Declaration): issue an error in formal mode on subtype
5072 of string which does not have a lower index bound equal to 1
5073 (Array_Type_Declaration): issue an error in formal mode on index or
5074 component type which is not a subtype mark, and on aliased keyword on
5075 component
5076 (Derived_Type_Declaration): issue an error in formal mode on interface,
5077 limited or abstract type
5078 (Record_Type_Declaration): issue an error in formal mode on interface
5079 (Record_Type_Definition): issue an error in formal mode on tagged types
5080 and type extensions not declared in the specification of a library unit
5081 package; on null non-tagged record; on variant part
5082
50832011-08-02 Vincent Celier <celier@adacore.com>
5084
5085 * prj-nmsc.adb (Check_Library_Attributes): Do not report Library_Dir
5086 not declared for qualified library project when Library_Name is not
5087 declared, but Library_Dir is.
5088
50892011-08-02 Robert Dewar <dewar@adacore.com>
5090
5091 * sem_ch13.adb (Analyze_Aspect_Specification): Fix slocs on generated
5092 pragmas (affects aspects [Component_]Default_Value
5093 (Check_Aspect_At_Freeze_Point): For Component_Default_Value, use
5094 component type for the resolution
5095
f96b2d85
AC
50962011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5097
5098 * einfo.adb (Base_Type): Tune implementation for speed.
5099
51002011-08-02 Robert Dewar <dewar@adacore.com>
5101
5102 * freeze.adb: Minor reformatting.
5103
8b3c6430
AC
51042011-08-02 Thomas Quinot <quinot@adacore.com>
5105
5106 * scos.ads: Update comments.
5107
51082011-08-02 Ed Schonberg <schonberg@adacore.com>
5109
5110 * sem_ch3.adb (Build_Derived_Type): Inherit the convention from the
5111 base type, because the parent may be a subtype of a private type whose
5112 convention is established in a private part.
5113
51142011-08-02 Hristian Kirtchev <kirtchev@adacore.com>
5115
5116 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Wrap the return
5117 statement in a block when the expansion of the return expression has
5118 created a finalization chain.
5119 * freeze.adb (Freeze_Expression): Alphabetize all choices associated
5120 with the parent node.
5121 Add N_Extended_Return_Statement to handle the case where a transient
5122 object declaration appears in the Return_Object_Declarations list of
5123 an extended return statement.
5124
51252011-08-02 Matthew Gingell <gingell@adacore.com>
5126
5127 * adaint.c (__gnat_is_symbolic_link_attr): Supress warning on possibly
5128 unused parameter 'name'.
5129
51302011-08-02 Ed Schonberg <schonberg@adacore.com>
5131
5132 * sem_elim.adb (Set_Eliminated): If the overridden operation is an
5133 inherited operation, check whether its alias, which is the source
5134 operastion that it renames, has been marked eliminated.
5135
cae81f17
JM
51362011-08-02 Javier Miranda <miranda@adacore.com>
5137
5138 * exp_util.adb (Safe_Prefixed_Reference): Do not consider safe an
5139 in-mode parameter whose type is an access type since it can be used to
5140 modify its designated object. Enforce code that handles as safe an
5141 access type that is not access-to-constant but it is the result of a
5142 previous removal of side-effects.
5143 (Remove_Side_Effects): Minor code reorganization of cases which require
5144 no action. Done to incorporate documentation on new cases uncovered
5145 working in this ticket: no action needed if this routine was invoked
5146 too early and the nodes are not yet decorated.
5147 * sem_res.adb (Resolve_Slice): Minor code cleanup replacling two calls
5148 to routine Remove_Side_Effects by calls to Force_Evaluation since they
5149 were issued with actuals that are implicitly provided by
5150 Force_Evaluation.
5151
218e6dee
RD
51522011-08-02 Robert Dewar <dewar@adacore.com>
5153
5154 * sem_ch3.adb, sem_res.adb: Minor reformatting.
5155
7a489a2b
AC
51562011-08-02 Yannick Moy <moy@adacore.com>
5157
5158 * sem_attr.adb (Check_Formal_Restriction_On_Attribute): new procedure
5159 to issue an error in formal mode on attribute not supported in this mode
5160 (Analyze_Attribute): issue errors on standard attributes not supported
5161 in formal mode.
5162 * sem_ch3.adb (Modular_Type_Declaration): remove obsolete part of
5163 comment, and issue error in formal mode on modulus which is not a power
5164 of 2.
5165 (Process_Range_Expr_In_Decl): issue error in formal mode on non-static
5166 range.
5167 * sem_ch8.adb (Find_Type): issue error in formal mode on 'Base in
5168 subtype mark.
5169 * sem_res.adb (Resolve_Unary_Op): issue error in formal mode on unary
5170 operator on modular type (except 'not').
5171
51722011-08-02 Robert Dewar <dewar@adacore.com>
5173
5174 * gnat_rm.texi: Minor reformatting.
5175
cb7fa356
AC
51762011-08-02 Arnaud Charlet <charlet@adacore.com>
5177
5178 * s-osinte-linux.ads: Minor comment update and reformatting.
5179 * i-cexten.ads: Make this unit pure, as for its parent.
5180 Will allow its usage in more contexts if needed.
5181
51822011-08-02 Robert Dewar <dewar@adacore.com>
5183
5184 * s-utf_32.ads: Minor comment fix.
5185
51862011-08-02 Ed Schonberg <schonberg@adacore.com>
5187
5188 * sem_res.adb (Resolve_Actuals): if the subprogram is a primitive
5189 operation of a tagged synchronized type, handle the case where the
5190 controlling argument is overloaded.
5191
51922011-08-02 Yannick Moy <moy@adacore.com>
5193
5194 * gnat_rm.texi, opt.ads, sem_prag.adb, snames.ads-tmpl:
5195 Replace pragma SPARK_95 with pragma Restrictions (SPARK)
5196 * par-prag.adb (Process_Restrictions_Or_Restriction_Warnings): set
5197 SPARK mode and formal verification mode on processing SPARK restriction
5198 * s-rident.ads (Restriction_Id): add SPARK restriction in those not
5199 requiring consistency checking.
5200
5cc9353d
RD
52012011-08-02 Robert Dewar <dewar@adacore.com>
5202
5203 * sem_res.adb: Minor reformatting.
5204
e51537ff
RD
52052011-08-02 Robert Dewar <dewar@adacore.com>
5206
5207 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
5208 a-cforse.ads: Remove unneeded with of Ada.Containers
5209 Remove commented out pragma Inline's
5210 Move specifications of new subprograms to the actual specs
5211
83fa09c5
AC
52122011-08-02 Yannick Moy <moy@adacore.com>
5213
5214 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
5215 a-cforse.ads: Update comments.
5216
52172011-08-02 Ed Schonberg <schonberg@adacore.com>
5218
5219 * sem_attr.adb: add attribute name when 'Result has the wrong prefix.
5220
d11cfaf8
RD
52212011-08-02 Robert Dewar <dewar@adacore.com>
5222
5223 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
5224 a-cforse.ads, a-cofove.ads: Minor reformatting.
5225
300b98bb
AC
52262011-08-02 Claire Dross <dross@adacore.com>
5227
5228 * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
5229 a-cofove.ads: Add comments.
5230
52312011-08-02 Yannick Moy <moy@adacore.com>
5232
5233 * gnat_rm.texi: Document formal containers.
5234
52352011-08-02 Emmanuel Briot <briot@adacore.com>
5236
5237 * g-comlin.adb (Goto_Section, Getopt): fix handling of "*" when there
5238 are empty sections.
5239
19fb051c
AC
52402011-08-02 Robert Dewar <dewar@adacore.com>
5241
5242 * mlib-prj.adb, restrict.ads, sem_aggr.adb, sem_ch12.adb: Minor
5243 reformatting.
5244
52452011-08-02 Robert Dewar <dewar@adacore.com>
5246
5247 * aspects.adb: New aspects Default_Value and Default_Component_Value
5248 New format of Aspect_Names table checks for omitted entries
5249 * aspects.ads: Remove mention of Aspect_Cancel and add documentation on
5250 handling of boolean aspects for derived types.
5251 New aspects Default_Value and Default_Component_Value
5252 New format of Aspect_Names table checks for omitted entries
5253 * einfo.ads, einfo.adb (Has_Default_Component_Value): New flag
5254 (Has_Default_Value): New flag
5255 (Has_Default_Component_Value): New flag
5256 (Has_Default_Value): New flag
5257 * par-ch13.adb (P_Aspect_Specifications): New format of Aspect_Names
5258 table.
5259 * par-prag.adb: New pragmas Default_Value and Default_Component_Value
5260 * sem_ch13.adb (Analyze_Aspect_Specifications): New aspects
5261 Default_Value and Default_Component_Value
5262 * sem_prag.adb: New pragmas Default_Value and Default_Component_Value
5263 New aspects Default_Value and Default_Component_Value
5264 * snames.ads-tmpl: New pragmas Default_Value and Default_Component_Value
5265 * sprint.adb: Print N_Aspect_Specification node when called from gdb
5266
52672011-08-02 Vincent Celier <celier@adacore.com>
5268
5269 * prj-nmsc.adb (Check_Library_Attributes): For virtual library project,
5270 inherit library kind.
5271
52722011-08-02 Ed Schonberg <schonberg@adacore.com>
5273
5274 * sem_res.adb: Add guards in calls to Matching_Static_Array_Bounds.
5275 Minor reformatting.
5276
52772011-08-02 Robert Dewar <dewar@adacore.com>
5278
5279 * i-cstrin.ads: Updates to make Interfaces.C.Strings match RM
5280
5f7747af
AC
52812011-08-02 Yannick Moy <moy@adacore.com>
5282
5283 * sem_aggr.adb (Resolve_Aggregate): Fix thinko.
5284
52852011-08-02 Robert Dewar <dewar@adacore.com>
5286
5287 * impunit.adb: Add comment.
5288
a5fe697b
AC
52892011-08-02 Yannick Moy <moy@adacore.com>
5290
5291 * sem_aggr.adb (Check_Qualified_Aggregate): new procedure which checks
5292 qualification of aggregates in formal mode
5293 (Is_Top_Level_Aggregate): returns True for an aggregate not contained in
5294 another aggregate
5295 (Resolve_Aggregate): complete the test that an aggregate is adequately
5296 qualified in formal mode
5297
52982011-08-02 Pascal Obry <obry@adacore.com>
5299
5300 * make.adb, bindgen.adb, gnatbind.adb: Minor reformatting.
5301 * mlib-prj.adb: Supress warning when compiling binder generated file.
5302 (Build_Library): Supress all warnings when compiling the binder
5303 generated file.
5304
bd65a2d7 53052011-08-02 Yannick Moy <moy@adacore.com>
d4487611 5306
bd65a2d7
AC
5307 * errout.adb, errout.ads (Check_Formal_Restriction): move procedure
5308 from here...
5309 * restrict.adb, restrict.ads (Check_Formal_Restriction): ...to here
5310 * sem_aggr.adb, sem_ch5.adb, sem_util.adb:
5311 Add with/use clauses to make Check_Formal_Restriction visible
5312
53132011-08-02 Ed Schonberg <schonberg@adacore.com>
5314
5315 * sem_ch12.adb (Check_Generic_Actuals): handle properly actual
5316 in-parameters when type of the generic formal is private in the generic
5317 spec and non-private in the body.
5318
53192011-08-02 Claire Dross <dross@adacore.com>
5320
5321 * a-cfdlli.adb, a-cfdlli.ads, a-cfhase.adb, a-cfhase.ads, a-cfhama.adb,
5322 a-cfhama.ads, a-cforse.adb, a-cforse.ads, a-cforma.adb, a-cforma.ads,
5323 a-cofove.adb, a-cofove.ads: New files implementing formal containers.
5324 * impunit.adb, Makefile.rtl: Take new files into account.
d4487611
AC
5325
53262011-08-02 Robert Dewar <dewar@adacore.com>
5327
5328 * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, make.adb, sem_res.adb,
5329 sem_attr.adb, sem_ch6.adb, sem_ch8.adb: Minor reformatting.
5330
bd434b3f
YM
53312011-08-02 Yannick Moy <moy@adacore.com>
5332
5333 * sem_aggr.adb (Resolve_Aggregate): disable incorrectly placed check in
5334 formal mode
5335 * sem_util.adb (Matching_Static_Array_Bounds): proper detection of
5336 matching static array bounds, taking into account the special case of
5337 string literals
5338 * sem_ch3.adb: Typo in comment.
5339
fe5d3068
YM
53402011-08-02 Yannick Moy <moy@adacore.com>
5341
5342 * errout.adb, errout.ads (Check_Formal_Restriction): new procedure
5343 which issues an error in formal mode if its argument node is originally
5344 from source
5345 * sem_ch3.adb (Analyze_Full_Type_Declaration): move test that a type
5346 has a discriminant specification so that it does not include the case
5347 of derived types
5348 (Derived_Type_Declaration): move here the test that a derived type has a
5349 discriminant specification
5350 * sem_aggr.adb (Resolve_Record_Aggregate): test the presence of the
5351 first element of a component association before accessing its choices
5352 (presence of component association is not enough)
5353 * exp_ch6.adb (Expand_N_Subprogram_Declaration): test if a subprogram
5354 declaration is a library item before accessing the next element in a
5355 list, as library items are not member of lists
5356 * sem_attr.adb, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb,
5357 sem_ch8.adb, sem_ch9.adb, sem_res.adb, sem_util.adb: use
5358 Check_Formal_Restriction whenever possible.
5359
b60a3f26
AC
53602011-08-02 Ed Schonberg <schonberg@adacore.com>
5361
5362 * sem_ch3.adb (Find_Type_Of_Object): In ASIS mode, create an itype
5363 reference when needed.
5364
53652011-08-02 Bob Duff <duff@adacore.com>
5366
5367 * gnat_ugn.texi: Fix typo.
5368
53692011-08-02 Vincent Celier <celier@adacore.com>
5370
5371 * make.adb (Gnatmake): Use MLib.Tgt.Archive_Ext as the extension of
5372 archive file name. Do not use the full path name of archives for Open
5373 VMS.
5374
eaba57fb
RD
53752011-08-02 Robert Dewar <dewar@adacore.com>
5376
5377 * sem_ch12.adb, sem_ch11.adb: New calling sequence for
5378 Analyze_Aspect_Specifications
5379 * sem_ch13.adb
5380 (Analyze_Aspect_Specifications): New handling for boolean aspects
5381 * sem_ch13.ads (Analyze_Aspect_Specifications): New calling sequence
5382 * sem_ch3.adb, sem_ch6.adb, sem_ch7.adb, sem_ch9.adb: New calling
5383 sequence for Analyze_Aspect_Specifications
5384 * sem_prag.adb (Analyze_Pragma): Remove use of Aspect_Cancel entirely
5385 * sinfo.ads, sinfo.adb (Aspect_Cancel): Remove, no longer used
5386
53872011-08-02 Robert Dewar <dewar@adacore.com>
5388
5389 * freeze.adb (Freeze_Entity): Remove handling of delayed boolean
5390 aspects, since these no longer exist.
5391
53922011-08-02 Robert Dewar <dewar@adacore.com>
5393
5394 * par-ch13.adb (Aspect_Specifications_Present): Always return false on
5395 semicolon, do not try to see if there are aspects following it.
5396 * par-ch3.adb (P_Declarative_Items): Better message for unexpected
5397 aspect spec.
5398
8830d1d2
AC
53992011-08-02 Robert Dewar <dewar@adacore.com>
5400
5401 * sem_ch8.adb, aspects.ads: Minor reformatting.
5402
54032011-08-02 Eric Botcazou <ebotcazou@adacore.com>
5404
5405 * sem_ch13.ads (Analyze_Aspect_Specification): Add pragma Inline.
5406 * sem_ch13.adb (Analyze_Non_Null_Aspect_Specifications): New procedure
5407 extracted from...
5408 (Analyze_Aspect_Specifications): ...here. Call above procedure.
5409
7ff2d234
AC
54102011-08-02 Yannick Moy <moy@adacore.com>
5411
5412 * exp_ch6.adb (Expand_N_Subprogram_Declaration): issue error in formal
5413 mode on subprogram declaration outside of package specification, unless
5414 it is followed by a pragma Import
5415 * sem_ch3.adb (Access_Definition, Access_Subprogram_Declaration,
5416 Access_Type_Declaration): issue error in formal mode on access type
5417 (Analyze_Incomplete_Type_Decl): issue error in formal mode on
5418 incomplete type
5419 (Analyze_Object_Declaration): issue error in formal mode on object
5420 declaration which does not respect SPARK restrictions
5421 (Analyze_Subtype_Declaration): issue error in formal mode on subtype
5422 declaration which does not respect SPARK restrictions
5423 (Constrain_Decimal, Constrain_Float, Constrain_Ordinary_Fixed): issue
5424 error in formal mode on digits or delta constraint
5425 (Decimal_Fixed_Point_Type_Declaration): issue error in formal mode on
5426 decimal fixed point type
5427 (Derived_Type_Declaration): issue error in formal mode on derived type
5428 other than type extensions of tagged record types
5429 * sem_ch6.adb (Process_Formals): remove check in formal mode, redundant
5430 with check on access definition
5431 * sem_ch9.adb (Analyze_Protected_Definition): issue error in formal
5432 mode on protected definition.
5433 (Analyze_Task_Definition): issue error in formal mode on task definition
5434
54352011-08-02 Robert Dewar <dewar@adacore.com>
5436
5437 * make.adb, sem_ch8.adb, s-inmaop-vxworks.adb: Minor reformatting.
5438
806f6d37
AC
54392011-08-02 Javier Miranda <miranda@adacore.com>
5440
5441 * sem_ch6.adb (Can_Override_Operator): New function.
5442 (Verify_Overriding_Indicator): Add missing code to check overriding
5443 indicator in operators. Fixes regression.
5444 (Check_Overriding_Indicator): Minor reformating after replacing the
5445 code that evaluates if the subprogram can override an operator by
5446 invocations to the above new function.
5447 * einfo.adb
5448 (Write_Field26_Name): Add missing code to ensure that, following
5449 the documentation in einfo.ads, this field is not shown as attribute
5450 "Static_Initialization" on non-dispatching functions.
5451
54522011-08-02 Jose Ruiz <ruiz@adacore.com>
5453
5454 * sem_res.adb (Resolve_Call): A call to
5455 Ada.Real_Time.Timing_Events.Set_Handler violates restriction
5456 No_Relative_Delay (AI-0211) only when it sets a relative timing event,
5457 i.e., when the second parameter is of type Time_Span.
5458
54592011-08-02 Vincent Celier <celier@adacore.com>
5460
5461 * make.adb (Gnatmake): use <library dir>/lib<library name>.a to link
5462 with an archive instead of -L<library dir> -l<library name>.
5463
54642011-08-02 Ed Schonberg <schonberg@adacore.com>
5465
5466 * sem_ch8.adb (Analyze_Use_Type): If the clause is being re-analyzed,
5467 mark the base types In_Use in addition to making the operations
5468 use_visible.
5469
54702011-08-02 Ed Falis <falis@adacore.com>
5471
5472 * init.c: add and setup __gnat_signal_mask for the exception signals
5473 * s-inmaop-vxworks.adb: new file.
5474 * s-intman-vxworks.adb: remove unnecessary initializations and
5475 simplify remaining
5476 * s-intman-vxworks.ads: remove unnecessary variable
5477 * s-taprop-vxworks.adb: simplify signal initialization
5478
780d052e
RD
54792011-08-02 Robert Dewar <dewar@adacore.com>
5480
5481 * sem_ch8.adb: Minor code reorganization, comment updates.
5482
54832011-08-02 Robert Dewar <dewar@adacore.com>
5484
5485 * sem_res.adb (Matching_Static_Array_Bounds): Moved to Sem_Util
5486 * sem_util.ads, sem_util.adb (Matching_Static_Array_Bounds): Moved
5487 here from Sem_Res.
5488 (Matching_Static_Array_Bounds): Use Is_Ok_Static_Expression
5489 (Matching_Static_Array_Bounds): Moved here from Sem_Res
5490
29efbb8c
ES
54912011-08-02 Ed Schonberg <schonberg@adacore.com>
5492
5493 * atree.h, atree.ads, atree.adb: New subprograms to manipulate Elist5.
5494 * par_ch8.adb (P_Use_Type): initialize Used_Operations for node.
5495 * sinfo.ads, sinfo.adb (Used_Operations): new attribute of
5496 use_type_clauses, to handle more efficiently use_type and use_all_type
5497 constructs.
5498 * sem_ch8.adb: Rewrite Use_One_Type and End_Use_Type to handle the
5499 Ada2012 Use_All_Type clause.
5500 (Use_Class_Wide_Operations): new procedure.
5501
b0186f71
AC
55022011-08-02 Robert Dewar <dewar@adacore.com>
5503
5504 * exp_util.adb, par-ch10.adb, par-ch6.adb, sem.adb, sem_ch6.adb,
5505 sem_ch6.ads, sinfo.adb, sinfo.ads, sprint.adb: Change parameterized
5506 expression to expression function.
5507
55082011-08-02 Ed Schonberg <schonberg@adacore.com>
5509
5510 * sem_ch4.adb: transform simple Ada2012 membership into equality only
5511 if types are compatible.
5512
55132011-08-02 Yannick Moy <moy@adacore.com>
5514
5515 * sem_res.adb (Matching_Static_Array_Bounds): new function which
5516 returns True if its argument array types have same dimension and same
5517 static bounds at each index.
5518 (Resolve_Actuals): issue an error in formal mode on actuals passed as
5519 OUT or IN OUT paramaters which are not view conversions in SPARK.
5520 (Resolve_Arithmetic_Op): issue an error in formal mode on
5521 multiplication or division with operands of fixed point types which are
5522 not qualified or explicitly converted.
5523 (Resolve_Comparison_Op): issue an error in formal mode on comparisons of
5524 Boolean or array type (except String) operands.
5525 (Resolve_Equality_Op): issue an error in formal mode on equality
5526 operators for array types other than String with non-matching static
5527 bounds.
5528 (Resolve_Logical_Op): issue an error in formal mode on logical operators
5529 for array types with non-matching static bounds. Factorize the code in
5530 Matching_Static_Array_Bounds.
5531 (Resolve_Qualified_Expression): issue an error in formal mode on
5532 qualified expressions for array types with non-matching static bounds.
5533 (Resolve_Type_Conversion): issue an error in formal mode on type
5534 conversion for array types with non-matching static bounds
5535
767bb4e8
AC
55362011-08-02 Robert Dewar <dewar@adacore.com>
5537
5538 * par-ch10.adb: Minor code reorganization (use Nkind_In).
5539
55402011-08-02 Ed Schonberg <schonberg@adacore.com>
5541
5542 * par-ch9.adb: save location of entry for proper error message.
5543
4ac2477e
JM
55442011-08-02 Javier Miranda <miranda@adacore.com>
5545
5546 * sem_type.ads, sem_type.adb (Is_Ancestor): Addition of a new formal
5547 (Use_Full_View) which permits this routine to climb through the
5548 ancestors using the full-view of private parents.
5549 * sem_util.adb (Collect_Interfaces_Info, Implements_Interface): Set
5550 Use_Full_View to true in calls to Is_Ancestor.
5551 * sem_disp.adb (Override_Dispatching_Operation): Set Use_Full_View to
5552 true in call to Is_Ancestor.
5553 * exp_ch3.adb (Build_Offset_To_Top_Functions, Initialize_Tag): Set
5554 Use_Full_View to true in call to Is_Ancestor.
5555 * exp_ch7.adb (Controller_Component): Set Use_Full_View to true in
5556 call to Is_Ancestor.
5557 * exp_ch4.adb (Expand_N_Type_Conversion, Tagged_Membership): Set
5558 Use_Full_View to true in calls to Is_Ancestor.
5559 * exp_disp.adb (Expand_Interface_Actuals, Make_Secondary_DT, Make_DT,
5560 Make_Select_Specific_Data_Table, Register_Primitive,
5561 Set_All_DT_Position): Set Use_Full_View to true in calls to Is_Ancestor.
5562 * exp_intr.adb (Expand_Dispatching_Constructor_Call): Set Use_Full_View
5563 to true in call to Is_Ancestor.
5564 * exp_util.adb (Find_Interface_ADT, Find_Interface_Tag): Set
5565 Use_Full_View to true in calls to Is_Ancestor.
5566 * exp_cg.adb
5567 (Write_Call_Info): Set Use_Full_View to true in call to Is_Ancestor.
5568 (Write_Type_Info): Set Use_Full_View to true in call to Is_Ancestor.
5569
9f90d123
AC
55702011-08-02 Robert Dewar <dewar@adacore.com>
5571
5572 * gnat_rm.texi: Minor reformatting.
5573 * sem_prag.adb: Minor reformatting.
5574
55752011-08-02 Tristan Gingold <gingold@adacore.com>
5576
5577 * vms_data.ads: Add VMS qualifier for -gnateP.
5578
55792011-08-02 Robert Dewar <dewar@adacore.com>
5580
5581 * par-ch13.adb (P_Aspect_Specification): New meaning of Decl = Empty
5582 * par-ch7.adb (P_Package): Proper placement of aspects for package
5583 decl/instantiation.
5584 * par-endh.adb (Check_End): Ad Is_Sloc parameter
5585 (End_Statements): Add Is_Sloc parameterr
5586 * par.adb (P_Aspect_Specification): New meaning of Decl = Empty
5587 (Check_End): Ad Is_Sloc parameter
5588 (End_Statements): Add Is_Sloc parameterr
5589
55902011-08-02 Vincent Celier <celier@adacore.com>
5591
5592 * ug_words: Add VMS qualifier equivalent to -gnateP:
5593 /SYMBOL_PREPROCESSING.
5594
55952011-08-02 Jose Ruiz <ruiz@adacore.com>
5596
5597 * gnat-style.texi: For hexadecimal numeric literals the typical
5598 grouping of digits is 4 to represent 2 bytes.
5599 A procedure spec which is split into several lines is indented two
5600 characters.
5601
56022011-08-02 Yannick Moy <moy@adacore.com>
5603
5604 * exp_aggr.adb (Is_Others_Aggregate): move function to other unit.
5605 * sem_aggr.adb, sem_aggr.ads (Is_Others_Aggregate): move function here
5606 (Resolve_Aggregate): issue errors in formal modes when aggregate is not
5607 properly qualified
5608 (Resolve_Array_Aggregate): issue errors in formal modes on non-static
5609 choice in array aggregate
5610 (Resolve_Extension_Aggregate): issue errors in formal modes on subtype
5611 mark as ancestor
5612 (Resolve_Record_Aggregate): issue errors in formal modes on mixed
5613 positional and named aggregate for record, or others in record
5614 aggregate, or multiple choice in record aggregate
5615 * sem_res.adb (Resolve_Logical_Op): issue errors in formal mode when
5616 array operands to logical operations AND, OR and XOR do not have the
5617 same static lower and higher bounds
5618 * sem_ch5.adb, sinfo.ads: Correct typos in comments
5619
2933b16c
RD
56202011-08-01 Robert Dewar <dewar@adacore.com>
5621
5622 * sem_util.ads, sem_util.adb, sem_ch6.adb (Last_Source_Statement):
5623 Replaces Last_Source_Node_In_Sequence.
5624 * err_vars.ads (Error_Msg_Lang): 16 is OK, don't need 4K
5625 * errout.adb (Set_Error_Msg_Lang): Takes arg with no parens, but stores
5626 parens and blank in string (this was inconsistently implemented).
5627 * errout.ads
5628 (Set_Error_Msg_Lang): Takes arg with no parens, but stores parens and
5629 blank in string (this was inconsistently implemented).
5630 * gnat1drv.adb
5631 (Set_Global_Switches): Set formal mode switches appropriately
5632 * opt.ads, opt.adb: Formal mode is now global switches, more consistent
5633 * par-prag.adb
5634 (Analyze_Pragma, case SPARK_95): Set opt switches appropriately and
5635 call Set_Error_Msg_Lang to set "spark" as language name.
5636 * par.adb: Remove unnecessary call to set formal language for errout
5637 * sem_prag.adb (P_Pragma, case SPARK_95): Set opt switches
5638 appropriately and call Set_Error_Msg_Lang to set "spark" as language
5639 name.
5640 * sem_ch4.adb (Analyze_Concatenation_Operand): remove procedure and
5641 calls to it, moved after resolution so that types are known
5642 * sem_res.adb (Resolve_Op_Concat): issue an error in formal mode if
5643 result of concatenation is not of type String
5644 (Resolve_Op_Concat_Arg): issue an error in formal mode if an operand of
5645 concatenation is not properly restricted
5646 * gnat_rm.texi: Add doc on pragma Spark_95.
5647 * gcc-interface/Makefile.in: Remove obsolete target pairs for
5648 Interfaces.C.* on VMS. Remove s-parame-vms-restrict.ads.
5649 * gcc-interface/Make-lang.in: Update dependencies.
5650
05dbd302
AC
56512011-08-01 Javier Miranda <miranda@adacore.com>
5652
5653 * sem_disp.adb (Override_Dispatching_Operation): Enforce strictness of
5654 condition that detects if the overridden operation must replace an
5655 existing entity.
5656
56572011-08-01 Javier Miranda <miranda@adacore.com>
5658
5659 * exp_ch4.adb (Expand_N_Case_Expression): Propagate to the expanded
5660 code declarations inserted by Insert_Actions in each alternative of the
5661 N_Case_Expression node.
5662
56632011-08-01 Robert Dewar <dewar@adacore.com>
5664
5665 * sem_ch6.adb: Minor code reorganization.
5666 * sem_util.adb: Minor reformatting.
5667
af9e051f
PO
56682011-08-01 Pascal Obry <obry@adacore.com>
5669
5670 * prj-env.adb: Remove <prefix>/lib/gpr/<target> project search path.
5671 * gnat_ugn.texi: Add documentation for VERSIONINFO Windows resource.
5672
1d801f21
AC
56732011-08-01 Yannick Moy <moy@adacore.com>
5674
5675 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode on character
5676 literal or operator symbol which is prefixed
5677 * sem_attr.adb (Analyze_Access_Attribute): issue an error in formal
5678 mode on access attributes.
5679 * sem_ch4.adb (Analyze_Concatenation_Operand): new procedure to check
5680 that concatenation operands are properly restricted in formal mode
5681 (Analyze_Concatenation, Analyze_Concatenation_Rest): call new procedure
5682 Analyze_Concatenation_Operand. Issue an error in formal mode if the
5683 result of the concatenation has a type different from String.
5684 (Analyze_Conditional_Expression, Analyze_Explicit_Dereference,
5685 Analyze_Quantified_Expression, Analyze_Slice,
5686 Analyze_Null): issue an error in formal mode on unsupported constructs
5687 * sem_ch5.adb
5688 (Analyze_Block_Statement): only issue error on source block statement
5689 * sem_util.ads, sem_util.adb (Last_Source_Node_In_Sequence): new
5690 function which returns the last node in a list of nodes for which
5691 Comes_From_Source returns True, if any
5692 * sem_ch6.adb (Check_Missing_Return): minor refactoring to use
5693 Last_Source_Node_In_Sequence
5694 * sem_ch8.adb (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
5695 Analyze_Object_Renaming, Analyze_Use_Package): issue an error in formal
5696 mode on unsupported constructs
5697 * sem_ch9.adb Do not return after issuing error in formal mode, as the
5698 rest of the actions may be needed later on since the error is marked as
5699 not serious.
5700 * sinfo.ads: Typos in comments.
5701
57022011-08-01 Pascal Obry <obry@adacore.com>
5703
5704 * projects.texi: Minor editing.
5705
53beff22
YM
57062011-08-01 Yannick Moy <moy@adacore.com>
5707
5708 * err_vars.ads (Error_Msg_Lang, Error_Msg_Langlen): new variables for
5709 insertion character ~~
5710 * errout.ads, errout.adb (Formal_Error_Msg_...): remove procedures
5711 (Set_Error_Msg_Lang): new procedure which fixes the language for use
5712 with insertion character ~~
5713 (Set_Msg_Text): treat insertion character ~~
5714 * par-ch4.adb, par-ch5.adb, par-endh.adb, sem_attr.adb, sem_ch11.adb,
5715 sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_util.adb: Replace calls to
5716 Formal_Error_Msg_... procedures by equivalent Error_Msg_...
5717 procedures. Favor calls to Error_Msg_F(E) over Error_Msg_N(E). Make
5718 errors related to the formal language restriction not serious
5719 (insertion character |).
5720 * par.adb (Par): set formal language for error messages if needed
5721 * sem_ch6.adb (Check_Missing_Return): take into account possible
5722 generated statements at the end of the function
5723 * snames.ads-tmpl (Name_SPARK_95, Pragma_SPARK_95): new variable and
5724 enumeration value to define a new pragma SPARK_95
5725 * opt.ads, opt.adb (SPARK_Version_Type, SPARK_Version_Default,
5726 SPARK_Version): new type and variables to store the SPARK version
5727 (none by default).
5728 (SPARK_Mode): return True when SPARK_Version is set
5729 * par-prag.adb: Correct indentation
5730 (Prag): take Pragma_SPARK_95 into account
5731 * sem_prag.adb (Set_Mechanism_Value, Sig_Flags): take Pragma_SPARK_95
5732 into account.
5733
8d606a78
RD
57342011-08-01 Robert Dewar <dewar@adacore.com>
5735
5736 * sem_ch3.adb, sem_ch3.ads, sem_ch5.adb, prj-part.adb, par-ch4.adb,
5737 sem_util.adb, sem_ch4.adb, sem_ch6.adb, sem_ch6.ads, sem_ch8.adb,
5738 sem_ch8.ads, sem_ch13.ads, par-ch5.adb, prj-env.ads: Minor reformatting
5739
1982d5a8
PO
57402011-08-01 Pascal Obry <obry@adacore.com>
5741
5742 * prj-part.ads, prj-part.adb (Parse): Add Target_Name parameter. Pass
5743 Target_Name to Get_Path call.
5744 (Parse_Single_Project): Likewise.
5745 (Post_Parse_Context_Clause): Likewise.
5746 * prj-env.ads, prj-env.adb (Find_Project): Add Target_Name parameter.
5747 Call Initialise_Project_Path with the proper Target_Name.
5748 (Initialize_Project_Path): Add <gnat_root>/<target_name>/lib/gnat
5749 search path.
5750 (Get_Path): Add Target_Name parameter. Call Initialise_Project_Path
5751 with the proper Target_Name.
5752 * prj-conf.adb (Get_Or_Create_Configuration_File): Pass Target_Name to
5753 Part.Parse routine.
5754 (Parse_Project_And_Apply_Config): Likewise.
5755 * prj-makr.adb (Initialize): Pass empty Target_Name to Parse routine.
5756 This is fine as this part of the code is supporting only native
5757 compilation.
5758 * prj-pars.adb (Parse): Pass empty Target_Name to Parse routine. This
5759 is fine as this part of the code is supporting only native compilation.
5760
0d53d36b
AC
57612011-08-01 Yannick Moy <moy@adacore.com>
5762
5763 * sem_util.adb (Enter_Name): issue error in formal mode on declaration
5764 of homonym, unless the homonym is one of the cases allowed in SPARK
5765 * par-ch5.adb (Parse_Decls_Begin_End): issue error in SPARK mode for
5766 package declaration occurring after a body.
5767
57682011-08-01 Robert Dewar <dewar@adacore.com>
5769
5770 * checks.adb, exp_ch4.adb: Minor reformatting.
5771
57722011-08-01 Javier Miranda <miranda@adacore.com>
5773
5774 * einfo.ads (Access_Disp_Table): Fix documentation.
5775 (Dispatch_Table_Wrappers): Fix documentation.
5776
57772011-08-01 Pascal Obry <obry@adacore.com>
5778
5779 * prj-env.adb, prj-env.ads: Minor reformatting.
5780
8ed68165
AC
57812011-08-01 Yannick Moy <moy@adacore.com>
5782
5783 * sem_util.ads, sem_util.adb, par.adb, par_util.adb
5784 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
5785 procedures out of these packages.
5786 * errout.ads, errout.adb
5787 (Formal_Error_Msg, Formal_Error_Msg_N, Formal_Error_Msg_SP): move
5788 procedures in of this package
5789 (Formal_Error_Msg_NE): new procedure for wrapper on Error_Msg_NE
5790 * par-ch5.adb (Parse_Decls_Begin_End): issue syntax error in SPARK mode
5791 on misplaced later vs initial declarations, like in Ada 83
5792 * sem_attr.adb (Processing for Analyze_Attribute): issue error in
5793 formal mode on attribute of private type whose full type declaration
5794 is not visible
5795 * sem_ch3.adb (Analyze_Declarations): issue error in formal mode on a
5796 package declaration inside a package specification
5797 (Analyze_Full_Type_Declaration): issue error in formal mode on
5798 controlled type or discriminant type
5799 * sem_ch6.adb (Analyze_Subprogram_Specification): only issue error on
5800 user-defined operator means that it should come from the source
5801 (New_Overloaded_Entity): issue error in formal mode on overloaded
5802 entity.
5803 * sem_ch6.ads, sem_ch13.ads: typos in comments.
5804
58052011-08-01 Thomas Quinot <quinot@adacore.com>
5806
5807 * atree.adb: Minor reformatting.
5808 * checks.adb: Minor reformatting.
5809
4230bdb7
AC
58102011-08-01 Vincent Celier <celier@adacore.com>
5811
5812 * s-parame-vms-ia64.ads: Fix typo in comment
5813 Minor reformatting
5814 * s-parame-vms-restrict.ads: Removed, unused.
5815
58162011-08-01 Javier Miranda <miranda@adacore.com>
5817
5818 * exp_ch3.adb
5819 (Is_Variable_Size_Array): Remove local subprogram Is_Constant_Bound.
5820 * sem_ch3.adb
5821 (Constrain_Index): Remove side effects in the evaluation of the bounds.
5822 * sem_ch3.ads, sem_ch3.adb
5823 (Is_Constant_Bound): New extended version of the subprogram that was
5824 previously located inside function Exp_Ch3.Is_Variable_Size_Array.
5825 Moved here since it is shared by routines of sem_ch3 and exp_ch3.
5826 * sem_aux.ads (Constant_Value): Fix typo in comment.
5827 * checks.adb (Generate_Index_Checks): New implementation which, for
5828 array objects with constant bounds, generates the runtime check
5829 referencing the bounds of the array type. For other cases this routine
5830 provides its previous behavior obtaining such values from the array
5831 object.
5832 * sem_res.adb (Set_Slice_Subtype): Link a copied range subtree with its
5833 parent type.
5834 * atree.adb (New_Copy): Reset flag Is_Overloaded in the new copy since
5835 we cannot have semantic interpretations of the new node.
5836
2010d078
AC
58372011-08-01 Ed Schonberg <schonberg@adacore.com>
5838
5839 * sem_ch6.adb (Fully_Conformant_Expressions): handle quantified
5840 expressions.
5841
58422011-08-01 Arnaud Charlet <charlet@adacore.com>
5843
5844 * sem_ch8.adb: Minor code editing.
5845 * s-vxwext.adb: Remove trailing space.
5846 * freeze.adb, freeze.ads, errout.ads, erroutc.adb: Fix GPLv3 header for
5847 consistency with other files.
5848
58492011-08-01 Thomas Quinot <quinot@adacore.com>
5850
5851 * s-auxdec.ads, s-auxdec-vms_64.ads: Minor reformatting.
5852
58532011-08-01 Ed Schonberg <schonberg@adacore.com>
5854
5855 * par-ch10.adb: reject parameterized expressions as compilation unit.
5856 * sem_ch4.adb: handle properly conditional expression with overloaded
5857 then_clause and no else_clause.
5858
58592011-08-01 Tristan Gingold <gingold@adacore.com>
5860
5861 * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads: Redeclare C_Address
5862 like done by System.Aux_DEC.
5863 * env.c (__gnat_setenv) [VMS]: Put logicals into LNM$PROCESS table.
5864
daec8eeb
YM
58652011-08-01 Yannick Moy <moy@adacore.com>
5866
5867 * par-endh.adb (Check_End): issue a syntax error in SPARK mode for
5868 missing label at end of declaration (subprogram or package)
5869 * par-ch4.adb (P_Name): issue a syntax error in SPARK mode for mixing
5870 of positional and named parameter association
5871 * par.adb, par-util.adb (Formal_Error_Msg_SP): new wrapper on
5872 Error_Msg_SP which adds a prefix to the error message giving the name
5873 of the formal language analyzed
5874 * sem_ch6.adb (Analyze_Return_Type): issue an error in formal mode for
5875 access result type in subprogram, unconstrained array as result type,.
5876 (Analyze_Subprogram_Declaration): issue an error in formal mode for null
5877 procedure
5878 * sem_ch8.adb: Code clean up.
5879
38171f43
AC
58802011-08-01 Javier Miranda <miranda@adacore.com>
5881
5882 * sem_ch7.adb (Uninstall_Declarations): Remove useless code.
5883 * einfo.ads (Access_Disp_Table): Fix documentation.
5884 (Dispatch_Table_Wrappers): Fix documentation.
5885 * einfo.adb (Access_Disp_Table, Dispatch_Table_Wrappers,
5886 Set_Access_Disp_Table, Set_Dispatch_Table_Wrappers): Fix the assertions
5887 to enforce the documentation of this attribute.
5888 (Set_Is_Interface): Cleanup the assertion.
5889 * exp_ch4.adb (Expand_Allocator_Expression, Tagged_Membership): Locate
5890 the Underlying_Type entity before reading attribute Access_Disp_Table.
5891 * exp_disp.adb (Expand_Dispatching_Call, Expand_Interface_Conversion):
5892 Locate the Underlying_Type before reading attribute Access_Disp_Table.
5893 * exp_aggr.adb (Build_Array_Aggr_Code, Build_Record_Aggr_Code): Locate
5894 the Underlying_Type entity before reading attribute Access_Disp_Table.
5895 * exp_ch3.adb (Build_Record_Init_Proc, Expand_N_Object_Declaration):
5896 Locate the Underlying_Type entity before reading attribute
5897 Access_Disp_Table.
5898
58992011-08-01 Ed Schonberg <schonberg@adacore.com>
5900
5901 * s-poosiz.ads: Additional overriding indicators.
5902
59032011-08-01 Yannick Moy <moy@adacore.com>
5904
5905 * sem_ch5.adb (Analyze_Exit_Statement): add return after error in
5906 formal mode.
5907 (Analyze_Iteration_Scheme): issue error in formal mode when loop
5908 parameter specification does not include a subtype mark.
5909 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): issue error in
5910 formal mode on abstract subprogram.
5911 (Analyze_Subprogram_Specification): issue error in formal mode on
5912 user-defined operator.
5913 (Process_Formals): issue error in formal mode on access parameter and
5914 default expression.
5915 * sem_ch9.adb (Analyze_Abort_Statement,
5916 Analyze_Accept_Statement, Analyze_Asynchronous_Select,
5917 Analyze_Conditional_Entry_Call, Analyze_Delay_Relative,
5918 Analyze_Delay_Until, Analyze_Entry_Call_Alternative,
5919 Analyze_Requeue, Analyze_Selective_Accept,
5920 Analyze_Timed_Entry_Call): issue error in formal mode on such constructs
5921 * sem_ch11.adb (Analyze_Raise_Statement, Analyze_Raise_xxx_Error):
5922 issue error in formal mode on user-defined raise statement.
5923
1f250383
AC
59242011-08-01 Thomas Quinot <quinot@adacore.com>
5925
5926 * sem_ch6.adb (Enter_Overloaded_Entity): Do not warn about a
5927 declaration being hidden when overriding an implicit inherited
5928 subprogram.
5929 * par-ch10.adb (P_Compilation_Unit): In syntax check only mode
5930 (-gnats), do not complain about a source file that contains only a
5931 pragma No_Body.
5932
59332011-08-01 Ed Schonberg <schonberg@adacore.com>
5934
5935 * sem_ch5.adb (Analyze_Iterator_Scheme): Do not overwrite type of loop
5936 variable if already set.
5937
607d0635
AC
59382011-08-01 Arnaud Charlet <charlet@adacore.com>
5939
5940 * g-socket-dummy.adb, s-osinte-linux.ads, g-socket-dummy.ads,
5941 g-debuti.adb, g-tasloc.adb, g-debuti.ads, g-tasloc.ads,
5942 s-osinte-hpux.ads, g-sercom.adb, g-soliop-solaris.ads, g-sercom.ads,
5943 g-sptain.ads, g-curexc.ads, s-tasloc.adb, s-tasloc.ads, s-tataat.adb,
5944 g-ctrl_c.adb, a-reatim.adb, s-tataat.ads, g-dirope.adb, g-ctrl_c.ads,
5945 g-dirope.ads, g-boubuf.adb, g-calend.adb, g-boubuf.ads, g-souinf.ads,
5946 g-table.adb, g-bytswa-x86.adb, g-wispch.adb, g-io.adb, g-table.ads,
5947 g-wispch.ads, g-io.ads, g-memdum.adb, g-memdum.ads, g-busorg.adb,
5948 g-busorg.ads, g-regpat.adb, g-sothco-dummy.adb, g-encstr.adb,
5949 g-regpat.ads, g-sothco-dummy.ads, s-osinte-aix.ads, g-encstr.ads,
5950 g-sercom-mingw.adb, s-mastop-vms.adb, g-diopit.adb, g-diopit.ads,
5951 s-vxwext.adb, g-dyntab.adb, g-dyntab.ads, g-crc32.adb,
5952 g-sercom-linux.adb, g-crc32.ads, s-regpat.adb, g-flocon.ads,
5953 s-regpat.ads, g-stheme.adb, g-sestin.ads, s-taspri-posix-noaltstack.ads,
5954 g-soliop.ads, s-inmaop-posix.adb, g-locfil.ads, g-enblsp-vms-alpha.adb,
5955 g-socthi-dummy.adb, g-socthi-dummy.ads, gnat.ads, g-moreex.adb,
5956 g-moreex.ads, g-dynhta.adb, g-dynhta.ads, g-deutst.ads, g-htable.adb,
5957 g-cgicoo.adb, g-htable.ads, g-cgicoo.ads, a-interr.adb,
5958 g-socthi-vms.adb, g-socthi-vms.ads, g-hesora.adb, g-bubsor.adb,
5959 g-hesora.ads, g-bubsor.ads, g-md5.adb, g-md5.ads, s-intman-irix.adb,
5960 s-htable.adb, s-osinte-vms.adb, s-htable.ads, s-osinte-vms.ads,
5961 s-taprob.adb, g-bytswa.adb, g-bytswa.ads, s-osinte-solaris-posix.ads,
5962 a-suenco.adb, g-comver.adb, g-comver.ads, g-exctra.adb,
5963 s-osinte-solaris.adb, g-exctra.ads, s-osinte-irix.ads,
5964 s-osinte-solaris.ads, a-caldel-vms.adb, g-socthi-vxworks.adb,
5965 g-expect.adb, g-socthi-vxworks.ads, g-expect.ads, g-comlin.ads,
5966 g-heasor.adb, g-heasor.ads, g-traceb.adb, g-traceb.ads, g-decstr.adb,
5967 g-spipat.adb, g-decstr.ads, g-spipat.ads, s-mastop-tru64.adb,
5968 g-except.ads, g-thread.adb, g-hesorg.adb, g-thread.ads, g-hesorg.ads,
5969 g-expect-vms.adb, a-stuten.ads, g-spchge.adb, g-spchge.ads,
5970 g-u3spch.adb, g-u3spch.ads, g-spitbo.adb, g-spitbo.ads,
5971 s-osinte-dummy.ads, s-osinte-posix.adb, g-pehage.adb, g-pehage.ads,
5972 s-gloloc-mingw.adb, g-sha1.ads, s-traceb-hpux.adb,
5973 g-trasym-unimplemented.adb, g-trasym-unimplemented.ads, g-io_aux.adb,
5974 g-regexp.adb, g-io_aux.ads, g-socthi-mingw.adb, g-regexp.ads,
5975 s-osinte-hpux-dce.adb, g-socthi-mingw.ads, g-cgi.adb,
5976 s-osinte-hpux-dce.ads, g-cgi.ads, g-byorma.adb, g-boumai.ads,
5977 g-byorma.ads, a-caldel.adb, s-regexp.adb, s-regexp.ads,
5978 g-soliop-mingw.ads, g-sptavs.ads, s-osinte-tru64.ads, g-speche.adb,
5979 g-speche.ads, g-socthi.adb, g-stsifd-sockets.adb, g-socthi.ads,
5980 s-osinte-darwin.ads, i-vxwork-x86.ads, g-awk.adb, i-vxwork.ads,
5981 g-awk.ads, g-zspche.adb, g-zspche.ads, g-socket.adb, g-sptabo.ads,
5982 g-socket.ads, g-semaph.adb, g-semaph.ads, s-taspri-posix.ads,
5983 g-enblsp-vms-ia64.adb, g-cgideb.adb, g-cgideb.ads, g-sothco.adb,
5984 s-osinte-freebsd.ads, g-sothco.ads, g-catiio.adb, g-casuti.adb,
5985 g-catiio.ads, g-casuti.ads, g-trasym.adb, g-trasym.ads, s-casuti.adb,
5986 g-os_lib.adb, s-traceb-mastop.adb, g-busora.adb, s-interr-dummy.adb,
5987 g-busora.ads, g-enutst.ads, s-os_lib.adb, a-tasatt.adb,
5988 s-osinte-mingw.ads: Update to GPLv3 run-time license.
5989 Use GNAT instead of GNARL.
5990
59912011-08-01 Bob Duff <duff@adacore.com>
5992
5993 * a-cdlili.ads, a-cihama.ads, a-coinve.ads, a-ciorse.ads, a-coorma.ads,
5994 a-cidlli.ads, a-ciormu.ads, a-cihase.ads, a-cohama.ads, a-coorse.ads,
5995 a-ciorma.ads, a-coormu.ads, a-convec.ads, a-cohase.ads: Minor
5996 reformatting.
5997
59982011-08-01 Yannick Moy <moy@adacore.com>
5999
6000 * debug.adb (d.D) reverve flag for the SPARK mode
6001 (d.E) reverve flag for SPARK generation mode
6002 (d.F) reverve flag for Why generation mode
6003 * opt.ads, opt.adb (ALFA_Mode, ALFA_Through_SPARK_Mode,
6004 ALFA_Through_Why_Mode, Formal_Verification_Mode, SPARK_Mode): New
6005 functions which return True when the corresponding modes are set
6006 (Formal_Language): return "spark" or "alfa" when in formal verification
6007 mode.
6008 * sem_util.ads, sem_util.adb (Formal_Error_Msg): new wrapper on
6009 Error_Msg to prefix the error message with a tag giving the formal
6010 language
6011 (Formal_Error_Msg_N): new wrapper on Error_Msg_N to prefix the error
6012 message with a tag giving the formal language
6013 * sem_ch5.adb (Analyze_Block_Statement): issue error in formal mode on
6014 block statement
6015 (Analyze_Case_Statement): issue error in formal mode on case statement
6016 with a single "others" case alternative
6017 (Analyze_Exit_Statement): issue errors in formal mode on exit
6018 statements which do not respect SPARK restrictions
6019 (Analyze_Goto_Statement): issue error in formal mode on goto statement
6020 (Check_Unreachable_Code): always issue an error (not a warning) in
6021 formal mode on unreachable code (concerns both code after an infinite
6022 loop and after an unconditional jump, both not allowed in SPARK)
6023 * sem_ch6.adb (Analyze_Return_Statement): add call to
6024 Set_Return_Present for a procedure containing a return statement
6025 (already done for functions in Analyze_Function_Return)
6026 (Analyze_Function_Return): issue error in formal mode on extended
6027 return or if return is not last statement in function
6028 (Check_Missing_Return): issue error in formal mode if function does
6029 not end with return or if procedure contains a return
6030 * sem_ch8.ads, sem_ch8.adb (Has_Loop_In_Inner_Open_Scopes): new
6031 function to detect if there is an inner scope of its parameter S which
6032 is a loop.
6033
60342011-08-01 Thomas Quinot <quinot@adacore.com>
6035
6036 * sem_ch6.ads: Minor reformatting.
6037
d8b3ccb9
AC
60382011-08-01 Javier Miranda <miranda@adacore.com>
6039
6040 * sem_util.adb (Abstract_Interface_List): Complete condition when
6041 processing private type declarations to avoid reading unavailable
6042 attribute.
6043 (Is_Synchronized_Tagged_Type): Complete condition when processing
6044 private extension declaration nodes to avoid reading unavailable
6045 attribute.
6046
60472011-08-01 Thomas Quinot <quinot@adacore.com>
6048
6049 * sem_ch3.adb: Minor reformatting.
6050
60512011-08-01 Thomas Quinot <quinot@adacore.com>
6052
6053 * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads,
6054 i-cpoint.adb, i-cstrin.adb, i-cpoint.ads, i-cstrin.ads,
6055 s-parame-vms-ia64.ads, s-parame.ads, i-c.ads, s-parame-vxworks.ads,
6056 s-parame-vms-restrict.ads: Remove duplicated Interfaces.C.* packages
6057 for VMS, instead parametrize the common implementation with
6058 System.Parameters declarations.
6059
0bb9276c
AC
60602011-08-01 Eric Botcazou <ebotcazou@adacore.com>
6061
6062 * gnat_rm.texi: Document limitation of Pragma No_Strict_Aliasing.
6063
60642011-08-01 Tristan Gingold <gingold@adacore.com>
6065
6066 * seh_init.c: Fix SEH handler installation on win64.
6067
60682011-08-01 Ed Schonberg <schonberg@adacore.com>
6069
6070 * sem_ch3.adb (Access_Subprogram_Declaration): in Asis mode, prevent
6071 double analysis of an anonymous access to subprogram, because it can
6072 lead to improper sharing of profiles and a back-end crash.
6073
6a2e4f0b
AC
60742011-08-01 Robert Dewar <dewar@adacore.com>
6075
6076 * make.adb, sem_ch4.adb: Minor reformatting.
6077 * gcc-interface/Make-lang.in: Update dependencies.
6078 * sem_util.adb, exp_ch5.adb: Minor reformatting.
6079
60802011-08-01 Arnaud Charlet <charlet@adacore.com>
6081
6082 * gnat_rm.texi: Fix definition of Long_Integer.
6083
60842011-08-01 Ed Schonberg <schonberg@adacore.com>
6085
6086 * exp_aggr.adb: check limit size of static aggregate unconditionally,
6087 to prevent storage exhaustion.
6088 * exp_ch7.adb (Clean_Simple_Protected_Objects): if the scope being
6089 finalized is a function body, insert the cleanup code before the final
6090 return statement, to prevent spurious warnings.
6091 * s-pooglo.ads: add overriding indicator.
6092
4561baf7
ES
60932011-08-01 Ed Schonberg <schonberg@adacore.com>
6094
6095 * sem_ch4.adb (Operator_Check): improve error message when both a
6096 with_clause and a use_clause are needed to make operator usage legal.
6097 * sem_util.ads, sem_util.adb (Unit_Is_Visible): new predicate to
6098 determine whether a compilation unit is visible within an other,
6099 either through a with_clause in the current unit, or a with_clause in
6100 its library unit or one one of its parents.
6101
383e179e
AC
61022011-08-01 Ed Schonberg <schonberg@adacore.com>
6103
6104 * exp_ch5.adb (Expand_N_Iterator_Loop): handle properly an iterator
6105 over an arbitrary expression of an array or container type.
6106 * lib-xref.adb: clarify comment.
6107
61082011-08-01 Bob Duff <duff@adacore.com>
6109
6110 * einfo.ads: Minor reformatting.
6111 * debug.adb: Minor comment improvement.
6112
61132011-08-01 Javier Miranda <miranda@adacore.com>
6114
6115 * sem_ch4.adb (Try_Object_Operation): For class-wide subprograms do not
6116 consider hidden subprograms as valid candidates.
6117
61182011-08-01 Arnaud Charlet <charlet@adacore.com>
6119
6120 * make.adb (Compile): Strip -mxxx switches in CodePeer mode.
6121
61222011-08-01 Vasiliy Fofanov <fofanov@adacore.com>
6123
6124 * gnat_ugn.texi: Fix typo.
6125
61c161b2
AC
61262011-08-01 Robert Dewar <dewar@adacore.com>
6127
6128 * i-cstrin.adb, sem_util.adb, exp_ch11.adb, sem_ch8.adb,
6129 lib-xref.adb: Minor reformatting
6130
61312011-08-01 Gary Dismukes <dismukes@adacore.com>
6132
6133 * exp_ch6.adb (Expand_N_Extended_Return_Statement): Replace test of
6134 when to generate a call to Move_Final_List.
6135 (Has_Controlled_Parts): Remove this function.
6136
84df40f7
AC
61372011-08-01 Geert Bosch <bosch@adacore.com>
6138
6139 * par-ch3.adb (P_Discrete_Choice_List): Improve error message for extra
6140 "," in choice list.
6141
61422011-08-01 Thomas Quinot <quinot@adacore.com>
6143
6144 * exp_ch11.adb (Expand_N_Raise_Statement): Mark N_Raise_xxx_Error for
6145 explicit raise of a predefined exception as Comes_From_Source if the
6146 original N_Raise_Statement comes from source.
6147
61482011-08-01 Robert Dewar <dewar@adacore.com>
6149
6150 * sinfo.ads: Add comment.
6151 * sem_ch6.adb: Minor reformatting.
6152
61532011-08-01 Robert Dewar <dewar@adacore.com>
6154
6155 * freeze.adb (Freeze_Entity): Refine check for bad component size
6156 clause to avoid rejecting confirming clause when atomic/aliased present.
6157
61582011-08-01 Ed Schonberg <schonberg@adacore.com>
6159
6160 * sem_ch8.adb (Find_Direct_Name, Analyze_Expanded_Name): use Is_LHS to
6161 better determine whether an entity reference is a write.
6162 * sem_util.adb (Is_LHS): refine predicate to handle assignment to a
6163 subcomponent.
6164 * lib-xref.adb (Output_References): Do no suppress a read reference at
6165 the same location as an immediately preceeding modify-reference, to
6166 handle properly in-out actuals.
6167
61682011-08-01 Tristan Gingold <gingold@adacore.com>
6169
6170 * env.c (__gnat_setenv) [VMS]: Refine previous change.
6171
61722011-08-01 Quentin Ochem <ochem@adacore.com>
6173
6174 * i-cstrin.adb (New_String): Changed implementation, now uses only the
6175 heap to compute the result.
6176
c7f0d2c0
AC
61772011-08-01 Robert Dewar <dewar@adacore.com>
6178
6179 * atree.ads: Minor reformatting.
6180
61812011-08-01 Emmanuel Briot <briot@adacore.com>
6182
6183 * g-expect.adb (Get_Command_Output): Fix memory leak.
6184
61852011-08-01 Geert Bosch <bosch@adacore.com>
6186
6187 * cstand.adb (P_Float_Type): New procedure to print the definition of
6188 predefined fpt types.
6189 (P_Mixed_Name): New procedure to print a name using mixed case
6190 (Print_Standard): Use P_Float_Type for printing floating point types
6191 * einfo.adb (Machine_Emax_Value): Add preliminary support for quad
6192 precision IEEE float.
6193
61942011-08-01 Thomas Quinot <quinot@adacore.com>
6195
6196 * sem_ch3.adb: Minor reformatting.
6197
61982011-08-01 Ed Schonberg <schonberg@adacore.com>
6199
6200 * sem_ch6.adb (Analyze_Parameterized_Expression): If the expression is
6201 the completion of a generic function, insert the new body rather than
6202 rewriting the original.
6203
62042011-08-01 Yannick Moy <moy@adacore.com>
6205
6206 * sinfo.ads, errout.ads: Typos in comments.
6207
1c54829e
AC
62082011-08-01 Robert Dewar <dewar@adacore.com>
6209
6210 * par-endh.adb: Minor reformatting.
6211
62122011-08-01 Robert Dewar <dewar@adacore.com>
6213
6214 * aspects.ads, aspects.adb: Add aspects for library unit pragmas
6215 (Pre_Post_Aspects): New subtype.
6216 * par-ch12.adb (P_Generic): New syntax for aspects in packages
6217 * par-ch13.adb (P_Aspect_Specifications): Add Semicolon parameter
6218 * par-ch7.adb (P_Package): Remove Decl parameter
6219 (P_Package): Handle new syntax for aspects (before IS)
6220 * par-ch9.adb (P_Protected_Definition): Remove Decl parameter, handle
6221 new aspect syntax
6222 (P_Task_Definition): Remove Decl parameter, handle new aspect syntax
6223 * par.adb (P_Aspect_Specifications): Add Semicolon parameter
6224 (P_Package): Remove Decl parameter
6225 * sem_ch13.adb (Analyze_Aspect_Specifications): Handle library unit
6226 aspects
6227 * sem_ch7.adb (Analyze_Package_Declaration): Analyze new format aspect
6228 specs
6229 * sem_util.ads, sem_util.adb (Static_Boolean): New function
6230 * sinfo.ads: Document new syntax for aspects in packages etc.
6231 * sprint.adb: Handle new syntax of aspects before IS in package
6232
62332011-08-01 Thomas Quinot <quinot@adacore.com>
6234
6235 * atree.ads: Minor reformatting.
6236 * sem_prag.adb: Minor reformatting.
6237
62382011-08-01 Robert Dewar <dewar@adacore.com>
6239
6240 * exp_util.adb (Insert_Actions): Fix error in handling Actions for
6241 case expr alternative.
6242
62432011-08-01 Ed Schonberg <schonberg@adacore.com>
6244
6245 * sem_ch12.adb: Fix typo.
6246
9eea4346
GB
62472011-08-01 Geert Bosch <bosch@adacore.com>
6248
6249 * sem_prag.adb (Check_No_Link_Name): New procedure.
6250 (Process_Import_Or_Interface): Use Check_No_Link_Name.
6251 * cstand.adb (Create_Standard): Use Esize (Standard_Long_Long_Float)
6252 instead of Standard_Long_Long_Float_Size global. Preparation for
6253 eventual removal of per type constants.
6254 * exp_util.ads (Get_Stream_Size): New function returning the stream
6255 size value of subtype E.
6256 * exp_util.adb (Get_Stream_Size): Implement new function.
6257 * exp_strm.adb (Build_Elementary_Input_Call): Use Get_Stream_Size
6258 function.
6259 * exp_attr.adb (Attribute_Stream_Size): Use Get_Stream_Size
6260 * einfo.adb:
6261 (Machine_Mantissa_Value): Handle 128-bit quad precision IEEE floats
6262
3d6c3bd7
GB
62632011-08-01 Geert Bosch <bosch@adacore.com>
6264
6265 * cstand.adb: Fix comments.
6266 * sem_prag.adb (Analyze_Pragma): Use List_Length instead of explicit
6267 count of arguments.
6268
e7d897b8
AC
62692011-08-01 Robert Dewar <dewar@adacore.com>
6270
6271 * exp_ch4.adb, sem_cat.adb: Minor reformatting.
6272
62732011-08-01 Geert Bosch <bosch@adacore.com>
6274
6275 * atree.ads: Fix comment.
6276
c228a069
AC
62772011-08-01 Robert Dewar <dewar@adacore.com>
6278
6279 * aspects.ads, aspects.adb (Aspect_Names): Moved from body to spec.
6280 * par-ch13.adb (P_Aspect_Specifications): Check misspelled aspect name.
6281 * par.adb: Add with for Namet.Sp.
6282 * par-tchk.adb: Minor reformatting.
6283
62842011-08-01 Vincent Celier <celier@adacore.com>
6285
6286 * mlib-tgt-specific-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb
6287 (Build_Dynamic_Library): Use new function Init_Proc_Name to get the name
6288 of the init procedure of a SAL.
6289 * mlib-tgt-vms_common.ads, mlib-tgt-vms_common.adb (Init_Proc_Name):
6290 New procedure.
6291
62922011-08-01 Thomas Quinot <quinot@adacore.com>
6293
6294 * exp_ch4.adb, s-tasini.ads, sem_attr.adb, s-soflin.ads: Minor
6295 reformatting.
6296
62972011-08-01 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
6298
6299 * adaint.c (__gnat_file_time_name_attr): Get rid of warning.
6300
63012011-08-01 Thomas Quinot <quinot@adacore.com>
6302
6303 * sem_util.adb, sem_util.ads (Has_Overriding_Initialize): Make function
6304 conformant with its spec (return True only for types that have
6305 an overriding Initialize primitive operation that prevents them from
6306 having preelaborable initialization).
6307 * sem_cat.adb (Validate_Object_Declaration): Fix test for preelaborable
6308 initialization for controlled types in Ada 2005 or later mode.
6309
857ade1b
RD
63102011-08-01 Robert Dewar <dewar@adacore.com>
6311
6312 * aspects.ads, aspects.adb: Add aspect Type_Invariant, Precondition,
6313 Postcondition.
6314 (Same_Aspect): New function.
6315 * sem_ch13.adb (Analyze_Aspect_Specifications): Add aspect
6316 Type_Invariant, Precondition, Postcondition.
6317 * snames.ads-tmpl: Add Name_Type_Invariant.
6318
bd949ee2
RD
63192011-08-01 Robert Dewar <dewar@adacore.com>
6320
6321 * freeze.adb (Freeze_Entity): Don't call Check_Aspect_At_Freeze_Point
6322 here.
6323 (Freeze_All_Ent): Fix error in handling inherited aspects.
6324 * sem_ch13.adb (Analyze_Aspect_Specifications): Skip aspect that is
6325 already analyzed, but don't skip entire processing of a declaration,
6326 that's wrong in some cases of declarations being rewritten.
6327 (Analyze_Aspect_Specification): Set Is_Delayed_Aspect in aspects.
6328 Don't delay for integer, string literals
6329 Treat predicates in usual manner for delay, remove special case code,
6330 not needed.
6331 (Analyze_Freeze_Entity): Make call to Check_Aspect_At_Freeze_Point
6332 (Build_Predicate_Function): Update saved expression in aspect
6333 (Build_Invariant_Procedure): Update saved expression in aspect
6334 * exp_ch4.adb (Expand_N_Selected_Component): Only do the optimization
6335 of replacement of discriminant references if the reference is simple.
6336
f1c952af
RD
63372011-08-01 Robert Dewar <dewar@adacore.com>
6338
6339 * aspects.ads, aspects.adb: Add Static_Predicate and Dynamic_Predicate.
6340 * sem_ch13.adb (Analyze_Aspect_Specification): Add processing for
6341 Static_Predicate and Dynamic_Predicate.
6342 (Build_Predicate_Function): Add processing for Static_Predicate
6343 and Dynamic_Predicate.
6344 * sinfo.ads, sinfo.adb (From_Dynamic_Predicate): New flag
6345 (From_Static_Predicate): New flag
6346 * snames.ads-tmpl: Add Name_Static_Predicate and Name_Dynamic_Predicate
6347
63482011-08-01 Robert Dewar <dewar@adacore.com>
6349
6350 * usage.adb: Documentation cleanup for Ada version modes in usage.
6351 * expander.adb: Minor reformatting.
6352
47e11d08
AC
63532011-08-01 Robert Dewar <dewar@adacore.com>
6354
6355 * atree.ads: Minor comment fix.
6356 * a-stwifi.adb, a-stzfix.adb, a-strfix.adb, a-ztexio.ads, a-textio.ads,
6357 a-witeio.ads, sem_prag.adb: Minor reformatting.
6358
63592011-08-01 Doug Rupp <rupp@adacore.com>
6360
6361 * env.c (__gnat_setenv) [VMS]: Force 32bit on item list structure
6362 pointers. Use descrip.h header file for convenience. Add some
6363 comments.
6364
63652011-08-01 Robert Dewar <dewar@adacore.com>
6366
6367 * freeze.adb (Freeze_Entity): Call Check_Aspect_At_Freeze_Point
6368 (Freeze_All): Call Check_Aspect_At_End_Of_Declarations
6369 * sem_ch13.ads, sem_ch13.adb (Check_Aspect_At_Freeze_Point):
6370 New procedure.
6371 (Check_Aspect_At_End_Of_Declarations): New procedure
6372 (Analye_Aspect_Specification): Minor changes for above procedures
6373 * sinfo.ads, sinfo.adb (Is_Delayed_Aspect): Now set in aspect
6374 specification node as well.
6375
63762011-08-01 Pascal Obry <obry@adacore.com>
6377
6378 * adaint.c (_gnat_stat): GetFilesAttributesEx() would fail on special
6379 Windows files. Use GetFilesAttributes() in this case to check for file
6380 existence instead of returning with an error code.
6381
a3a16b21
VC
63822011-08-01 Vincent Celier <celier@adacore.com>
6383
6384 * a-stzfix.adb, a-stwifi.adb (Replace_Slice): Fixed computation when
6385 High is above Source length.
6386
ff58cc69
RD
63872011-08-01 Robert Dewar <dewar@adacore.com>
6388
6389 * a-ztexio.ads, a-textio.ads, a-witeio.ads: Fix comment.
6390
6bb88533
AC
63912011-08-01 Robert Dewar <dewar@adacore.com>
6392
6393 * aspects.ads (Boolean_Aspects): New subtype.
6394 * exp_ch13.adb (Expand_Freeze_Entity): Fix errors in handling aspects
6395 for derived types in cases where the parent type and derived type have
6396 aspects.
6397 * freeze.adb (Freeze_Entity): Fix problems in handling derived type
6398 with aspects when parent type also has aspects.
6399 (Freeze_Entity): Deal with delay of boolean aspects (must evaluate
6400 boolean expression at this point).
6401 * sem_ch13.adb (Analyze_Aspect_Specifications): Delay all aspects in
6402 accordance with final decision on the Ada 2012 feature.
6403 * sinfo.ads, sinfo.adb (Is_Boolean_Aspect): New flag.
6404
64052011-08-01 Matthew Heaney <heaney@adacore.com>
6406
6407 * a-chtgbo.adb (Delete_Node_Sans_Free): Replace iterator with selector.
6408
060a3f28
AC
64092011-08-01 Pascal Obry <obry@adacore.com>
6410
6411 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb:
6412 Fix Replace_Slice when High is above current string size.
6413 (Replace_Slice): Fix DL computation when High is above current
6414 string length.
6415
64162011-08-01 Gary Dismukes <dismukes@adacore.com>
6417
6418 * gnat_rm.texi: Add documentation for pragma Static_Elaboration_Desired.
6419
e7f567a3
AC
64202011-08-01 Matthew Heaney <heaney@adacore.com>
6421
6422 * a-rbtgbo.adb (Delete_Node_Sans_Free): Fixed assignment to left child
6423 of node.
6424
64252011-08-01 Pascal Obry <obry@adacore.com>
6426
6427 * a-stzunb-shared.adb, a-strunb-shared.adb, a-stwiun-shared.adb: Minor
6428 reformatting.
6429
1a265e78
AC
64302011-08-01 Ed Schonberg <schonberg@adacore.com>
6431
6432 * sem_attr.adb (Analyze_Attribute, case 'Access): Handle properly named
6433 access to protected subprograms in generic bodies.
6434 * sem_ch6.adb (Analyze_Subprogram_Declaration): If the context is a
6435 protected type, indicate that the convention of the subprogram is
6436 Convention_Protected, because it may be used in subsequent declarations
6437 within the protected declaration.
6438
64392011-08-01 Vincent Celier <celier@adacore.com>
6440
6441 * mlib-prj.adb (Build_Library): Use "ada_" as the prefix for the "init"
6442 and "final" procedures when the name of the library is "ada", to avoid
6443 duplicate symbols "adainit" and "adafinal" in executables.
6444
67e28ef8
ES
64452011-08-01 Ed Schonberg <schonberg@adacore.com>
6446
6447 * sem_attr.adb (Analyze_Attribute, case 'Result): Handle properly a
6448 quantified expression that appears within a postcondition and uses the
6449 Ada2012 'Result attribute.
6450
6da2ca7d
RO
64512011-07-28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6452
6453 * init.c (__gnat_error_handler): Cast reason to int.
6454 (__gnat_install_handler): Explain sa_sigaction use.
6455
7d5997c6
EB
64562011-07-24 Eric Botcazou <ebotcazou@adacore.com>
6457
6458 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: If the
6459 subprogram has copy-in copy-out parameters, try to promote the mode of
6460 the return type if it is passed in registers.
6461
4b4cfdd5
EB
64622011-07-24 Eric Botcazou <ebotcazou@adacore.com>
6463
6464 * gcc-interface/utils2.c (build_binary_op) <ARRAY_REF>: Do not mark the
6465 left operand as addressable.
6466
f3d34576
EB
64672011-07-24 Eric Botcazou <ebotcazou@adacore.com>
6468
6469 * gcc-interface/gigi.h (build_function_stub): Remove.
6470 (build_return_expr): Likewise.
6471 (convert_vms_descriptor): Declare.
6472 * gcc-interface/utils.c (convert_vms_descriptor): Make global.
6473 (build_function_stub): Move to...
6474 * gcc-interface/utils2.c (build_return_expr): Move to...
6475 * gcc-interface/trans.c (build_function_stub): ...here.
6476 (build_return_expr): ...here.
6477 (Subprogram_Body_to_gnu): Add local variable for language_function.
6478 Disconnect the parameter attributes cache, if any, once done with it.
6479 Call end_subprog_body only after setting the end_locus.
6480 Build the stub associated with the function, if any, at the very end.
6481 (gnat_to_gnu) <N_Return_Statement>: Remove couple of useless local
6482 variables and streamline control flow.
6483
0a6ecc08
AC
64842011-07-23 Arnaud Charlet <charlet@adacore.com>
6485
6486 PR ada/49819
6487 * gcc-interface/Makefile.in (powerpc-linux): Remove reference to
6488 g-trasym-dwarf.adb.
6489
5b6d595b
RO
64902011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6491
6492 PR bootstrap/49794
6493 * init.c [sun && __SVR4 && !__vxworks] (__gnat_install_handler):
6494 Assign to act.sa_sigaction.
6495 * tracebak.c [USE_GENERIC_UNWINDER] (__gnat_backtrace): Cast
6496 current->return_address to char * before arithmetic.
6497
94017021
RO
64982011-07-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6499
6500 * init.c [sgi] (__gnat_error_handler): Update sigaction(2) citation.
6501 Correct argument types.
6502 Extract code from reason.
6503 (__gnat_install_handler): Assign to act.sa_sigaction.
6504
52fd02bb
EB
65052011-07-21 Eric Botcazou <ebotcazou@adacore.com>
6506
6507 * gcc-interface/Make-lang.in (GNAT1_ADA_OBJS): Move ada/b_gnat1.o to...
6508 (GNAT1_OBJS): ...here.
6509
f39a9ca2
EB
65102011-07-15 Eric Botcazou <ebotcazou@adacore.com>
6511
6512 PR ada/48711
6513 * g-socthi-mingw.adb (Fill): Fix formatting.
6514
9e36aa23
EB
6515 * gcc-interface/gigi.h: Move around comment.
6516
e3aca522
JDA
65172011-07-14 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
6518
6519 PR ada/46350
6520 * s-taprop-hpux-dce.adb (Abort_Task): Remove unnecessary cast.
6521
696b1960
FW
65222011-07-14 Florian Weimer <fw@deneb.enyo.de>
6523
6524 PR ada/48711
6525 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL.
6526
f542c405
EB
65272011-07-13 Eric Botcazou <ebotcazou@adacore.com>
6528
6529 * gcc-interface/utils.c (build_vms_descriptor32): Skip the 32-bit
6530 range comparison if Pmode is SImode.
6531
9e9bd455
LG
65322011-07-12 Laurent GUERBY <laurent@guerby.net>
6533 Eric Botcazou <ebotcazou@adacore.com>
6534
6535 * adadecode.c: Wrap up in extern "C" block.
6536 * adadecode.h: Likewise.
6537 * adaint.c: Likewise. Remove 'const' keyword.
6538 * adaint.h: Likewise.
6539 * argv.c: Likewise.
6540 * atree.h: Likewise.
6541 * cio.c: Likewise.
6542 * cstreams.c: Likewise.
6543 * env.c: Likewise.
6544 * exit.c: Likewise.
6545 * fe.h: Likewise.
6546 * final.c: Likewise.
6547 * init.c: Likewise.
6548 * initialize.c: Likewise.
6549 * link.c: Likewise.
6550 * namet.h: Likewise.
6551 * nlists.h: Likewise.
6552 * raise.c: Likewise.
6553 * raise.h: Likewise.
6554 * repinfo.h: Likewise.
6555 * seh_init.c: Likewise.
6556 * targext.c: Likewise.
6557 * tracebak.c: Likewise.
6558 * uintp.h: Likewise.
6559 * urealp.h: Likewise.
6560 * xeinfo.adb: Wrap up generated C code in extern "C" block.
6561 * xsinfo.adb: Likewise.
6562 * xsnamest.adb: Likewise.
6563 * gcc-interface/gadaint.h: Wrap up in extern "C" block.
6564 * gcc-interface/gigi.h: Wrap up some prototypes in extern "C" block.
6565 * gcc-interface/misc.c: Likewise.
6566 * gcc-interface/Make-lang.in (GCC_LINK): Use LINKER.
6567 (GNAT1_C_OBJS): Remove ada/b_gnat1.o. List ada/seh_init.o and
6568 ada/targext.o here...
6569 (GNAT_ADA_OBJS): ...and not here.
6570 (GNAT1_ADA_OBJS): Add ada/b_gnat1.o.
6571 (GNATBIND_OBJS): Reorder.
6572
7644b3c7
RH
65732011-07-07 Richard Henderson <rth@redhat.com>
6574
6575 * gcc-interface/misc.c (gnat_init_gcc_eh): Don't call
6576 dwarf2out_frame_init.
6577
8384ac41
EB
65782011-07-07 Eric Botcazou <ebotcazou@adacore.com>
6579
6580 * gcc-interface/misc.c (gnat_init): Tweak previous change.
6581
fbdd5d87
RO
65822011-07-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6583
6584 PR target/39150
6585 * gcc-interface/Makefile.in: Handle x86_64-solaris2.
6586
1a072294
RG
65872011-07-06 Richard Guenther <rguenther@suse.de>
6588
8384ac41
EB
6589 * gcc-interface/misc.c (gnat_init): Merge calls to
6590 build_common_tree_nodes and build_common_tree_nodes_2.
1a072294
RG
6591 Re-initialize boolean_false_node.
6592
bc712852
EB
65932011-07-02 Eric Botcazou <ebotcazou@adacore.com>
6594 Olivier Hainque <hainque@adacore.com>
6595 Nicolas Setton <setton@adacore.com>
6596
6597 * gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
6598 the type according to the ARTIFICIAL_P parameter.
6599 (create_type_decl): Likewise.
6600 (create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.
6601
2eb22389
EB
66022011-07-01 Eric Botcazou <ebotcazou@adacore.com>
6603
6604 * gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
6605 (gnatbind): Likewise.
6606
4bdaaf2f
RO
66072011-06-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6608
6609 * gcc-interface/Makefile.in (TOOLS_LIBS): Add $(LIBINTL).
6610
c020c92b
EB
66112011-06-18 Eric Botcazou <ebotcazou@adacore.com>
6612
6613 * gcc-interface/decl.c (gnat_to_gnu_component_type): Use GNAT_TYPE
6614 local variable throughout. Remove useless call to Base_Type.
6615 (gnat_to_gnu_field): Use GNAT_FIELD_TYPE local variable throughout.
6616 Take it also into account for the volatileness of the field. Set the
6617 TREE_SIDE_EFFECTS flag as well in this case. Reorder some warnings.
6618
96769d32
EB
66192011-06-18 Eric Botcazou <ebotcazou@adacore.com>
6620
6621 * gcc-interface/trans.c (Identifier_to_gnu): Don't set TREE_THIS_NOTRAP
6622 on a dereference built for a by-ref object if it has an address clause.
6623
7e4680c1
EB
66242011-06-18 Eric Botcazou <ebotcazou@adacore.com>
6625
6626 * einfo.ads (Address_Taken): Document use for the second argument of
6627 Asm_Input and Asm_Output attributes.
6628 * sem_attr.adb (Analyze_Attribute) <Attribute_Asm_Input>: If the second
6629 argument is an entity name, then set Address_Taken on it.
6630 <Attribute_Asm_Output>: Likewise.
6631 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Handle the
6632 Attr_Asm_Input and Attr_Asm_Output attributes explicitly.
6633 (gnat_to_gnu) <N_Code_Statement>: If an operand is going to end up in
6634 memory and is a CONST_DECL, retrieve its corresponding VAR_DECL.
6635
66362011-06-16 Joern Rennecke <joern.rennecke@embecosm.com>
d5cc9181
JR
6637
6638 PR middle-end/46500
6639 * gcc-interface/decl.c (gnat_to_gnu_param): Use pack_cumulative_args.
6640
677f3fa8
JM
66412011-06-14 Joseph Myers <joseph@codesourcery.com>
6642
6643 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Use ggc-none.o.
6644 (ada/utils.o): Update dependencies.
6645 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Add
6646 ../../../libcpp/libcpp.a.
6647 * gcc-interface/utils.c: Include common/common-target.h.
6648 (process_attributes): Use targetm_common.have_named_sections.
6649
009db074
RG
66502011-06-07 Richard Guenther <rguenther@suse.de>
6651
0bad0e23
EB
6652 * gcc-interface/misc.c (gnat_init): Do not set size_type_node or call
6653 set_sizetype.
009db074 6654
3bfc61cf
EB
66552011-06-06 Eric Botcazou <ebotcazou@adacore.com>
6656
0bad0e23 6657 * gcc-interface/utils2.c (gnat_stabilize_reference): Propagate the
3bfc61cf
EB
6658 TREE_THIS_NOTRAP flag.
6659
5c4a1c7b
EB
66602011-06-06 Eric Botcazou <ebotcazou@adacore.com>
6661
6662 * gcc-interface/utils2.c (gnat_stabilize_reference) <COMPOUND_EXPR>:
6663 Fix thinko.
6664
e9f57686
EB
66652011-06-06 Eric Botcazou <ebotcazou@adacore.com>
6666
6667 * gcc-interface/trans.c (Identifier_to_gnu): Also handle deferred
6668 constants whose full view has discriminants specially.
6669
10e4d056
EB
66702011-06-06 Eric Botcazou <ebotcazou@adacore.com>
6671
6672 * gcc-interface/utils.c: Include diagnostic.h.
6673 (gnat_write_global_declarations): Output debug information for all
6674 global type declarations before finalizing the compilation unit.
6675 * gcc-interface/Make-lang.in (ada/utils.o): Add dependency.
6676
0957c029
JJ
66772011-05-25 Jakub Jelinek <jakub@redhat.com>
6678
6679 * gcc-interface/utils.c (def_fn_type): Remove extra va_end.
6680
52d0a7ac
KT
66812011-05-25 Kai Tietz <ktietz@redhat.com>
6682
6683 * adaint.c (__gnat_to_canonical_file_list_next): Use array
6684 initialization instead of const/none-const pointer assignment.
6685
1ed1641d
JM
66862011-05-24 Joseph Myers <joseph@codesourcery.com>
6687
6688 * gcc-interface/Make-lang.in (GNAT1_OBJS): Don't include
6689 $(EXTRA_GNAT1_OBJS).
6690 (GNATBIND_OBJS): Don't include $(EXTRA_GNATBIND_OBJS).
6691 (EXTRA_GNAT1_OBJS, EXTRA_GNATBIND_OBJS): Remove.
6692 (gnat1$(exeext), gnatbind$(exeext)): Use libcommon-target.a.
6693 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use
6694 libcommon-target.a instead of prefix.o.
6695
9fe72ebd
JM
66962011-05-21 Joseph Myers <joseph@codesourcery.com>
6697
6698 PR ada/49097
0bad0e23 6699 * gcc-interface/Make-lang.in (gnatbind$(exeext)): Depend on $(LIBDEPS).
9fe72ebd 6700
2691e6d7
JM
67012011-05-20 Joseph Myers <joseph@codesourcery.com>
6702
0bad0e23
EB
6703 * gcc-interface/Make-lang.in (EXTRA_GNATBIND_OBJS): Remove version.o.
6704 * gcc-interface/Makefile.in (EXTRA_GNATTOOLS_OBJS): Use libcommon.a
6705 instead of version.o.
2691e6d7 6706
bf6490b5
KT
67072011-05-18 Kai Tietz <ktietz@redhat.com>
6708
6709 * gcc-interface/trans.c (Exception_Handler_to_gnu_sjlj): Use
6710 boolean_false_node instead of integer_zero_node.
6711 (convert_with_check): Likewise.
6712 * gcc-interface/decl.c (choices_to_gnu): Likewise.
6713
7bf9a5ac
EB
67142011-05-12 Eric Botcazou <ebotcazou@adacore.com>
6715
6716 * gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
6717 type of the parameter is an unconstrained array, convert the actual to
6718 the type of the formal in the In Out and Out cases as well.
6719
e5b00edf
NF
67202011-05-11 Nathan Froyd <froydnj@codesourcery.com>
6721
6722 * gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
6723 call build_function_type_array or build_varargs_function_type_array
6724 instead.
6725 (create_subprog_type): Don't call build_function_type; call
6726 build_function_type_vec instead.
6727
51545682
NF
67282011-05-11 Nathan Froyd <froydnj@codesourcery.com>
6729
6730 * gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
6731 (TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
6732 (TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.
6733
c99c0026
EB
67342011-05-07 Eric Botcazou <ebotcazou@adacore.com>
6735
f620bd21
EB
6736 * gcc-interface/decl.c (intrin_arglists_compatible_p): Remove spaces.
6737
c99c0026
EB
6738 * gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
6739 * gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
6740
3d528853
NF
67412011-05-05 Nathan Froyd <froydnj@codesourcery.com>
6742
c99c0026 6743 * gcc-interface/trans.c (Case_Statement_to_gnu): Call build_case_label.
3d528853 6744
d7d058c5
NF
67452011-05-05 Nathan Froyd <froydnj@codesourcery.com>
6746
6747 * gcc-interface/decl.c (intrin_arglists_compatible_p): Use iterators
6748 instead of accessing TYPE_ARG_TYPES directly.
6749 * gcc-interface/utils.c (handle_nonnull_attribute): Likewise.
6750
805e60a0
EB
67512011-05-05 Eric Botcazou <ebotcazou@adacore.com>
6752
6753 PR ada/48844
6754 * gcc-interface/gigi.h (get_variant_part): Declare.
6755 * gcc-interface/decl.c (get_variant_part): Make global.
6756 * gcc-interface/utils2.c (find_common_type): Do not return T1 if the
6757 types have the same constant size, are record types and T1 has a
6758 variant part while T2 doesn't.
6759
907a08d9
EB
67602011-05-05 Eric Botcazou <ebotcazou@adacore.com>
6761
6762 * gcc-interface/utils.c (begin_subprog_body): Do not call
6763 get_pending_sizes.
6764 (end_subprog_body): Likewise.
6765
d35936ab
RG
67662011-05-04 Richard Guenther <rguenther@suse.de>
6767
6768 * gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
6769 int_const_binop.
6770 (pos_to_constructor): Likewise.
6771
c1fd8753
NF
67722011-05-03 Nathan Froyd <froydnj@codesourcery.com>
6773 Eric Botcazou <ebotcazou@adacore.com>
6774
6775 * gcc-interface/trans.c (gigi): Call build_function_type_list instead
6776 of build_function_type. Adjust calls to...
6777 (build_raise_check): ...this. Do not take a void_tree parameter.
6778 Call build_function_type_list instead of build_function_type.
6779 Fix head comment and swap couple of conditional blocks.
6780
4fb87d2b
EB
67812011-04-30 Eric Botcazou <ebotcazou@adacore.com>
6782
6783 * gnatvsn.ads (Library_Version): Bump to 4.7.
6784 (Current_Year): Bump to 2011.
6785
fa5e5a76
MM
67862011-04-29 Michael Matz <matz@suse.de>
6787
6788 * gcc-interface/misc.c (gnat_handle_option): Set
6789 warn_maybe_uninitialized.
6790
8d6a2f69
GP
67912011-04-23 Gerald Pfeifer <gerald@pfeifer.com>
6792
6793 * gnat_ugn.texi (Complexity Metrics Control): Update link to
6794 the Watson/McCabe paper.
6795
770937fd
JM
67962011-04-23 Jim Meyering <meyering@redhat.com>
6797
6798 * gnat_ugn.texi (Examples of gnatxref Usage): Fix typo: s/it it/it is/
6799
eb601ae1
EB
68002011-04-22 Eric Botcazou <ebotcazou@adacore.com>
6801
6802 * gcc-interface/decl.c (make_packable_type): Copy DECL_PARALLEL_TYPE
6803 onto the new type.
6804
7d7fcb08
EB
68052011-04-22 Eric Botcazou <ebotcazou@adacore.com>
6806
6807 * gcc-interface/gigi.h (create_subprog_decl): Add ARTIFICIAL_FLAG
6808 parameter.
6809 * gcc-interface/utils.c (create_subprog_decl): Likewise. Set
6810 DECL_ARTIFICIAL and DECL_NO_INLINE_WARNING_P on the DECL accordingly.
6811 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>: Add
6812 ARTIFICIAL_FLAG local variable and pass it to create_subprog_decl.
6813 <all>: Do not set flags on the reused DECL node coming from an alias.
6814 Set DECL_IGNORED_P on the DECL node built for subprograms if they
6815 don't need debug info here...
6816 * gcc-interface/trans.c (Subprogram_Body_to_gnu): ...and not here.
6817 (gigi): Adjust calls to create_subprog_decl.
6818 (build_raise_check): Likewise.
6819 (establish_gnat_vms_condition_handler): Likewise.
6820 (Compilation_Unit_to_gnu): Likewise.
6821 (gnat_to_gnu): Likewise.
6822
e1876cac
EB
68232011-04-21 Eric Botcazou <ebotcazou@adacore.com>
6824
6825 * gcc-interface/Makefile.in (NO_SIBLING_ADAFLAGS): Always define.
6826 (NO_REORDER_ADAFLAGS): New variable.
6827 (EXTRA_GNATTOOLS): Always define.
6828 (../stamp-gnatlib1-$(RTSDIR): Copy tsystem.h.
6829 Clean up and adjust list of files compiled with special options.
6830 * gcc-interface/Make-lang.in: Likewise.
6831 (ada/decl.o): Cosmetical change.
6832 (ada/misc.o): Remove dependency on $(PLUGIN_H).
6833
04695783
JM
68342011-04-20 Jim Meyering <meyering@redhat.com>
6835
6836 * initialize.c (__gnat_initialize): Remove useless if-before-free.
6837
23399579
EB
68382011-04-17 Eric Botcazou <ebotcazou@adacore.com>
6839
6840 * gcc-interface/Make-lang.in (gnatbind): Replace $(ALL_CFLAGS) with
6841 $(CFLAGS) on the link line.
6842
51c5169c
EB
68432011-04-17 Eric Botcazou <ebotcazou@adacore.com>
6844
6845 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Function>: Declare the
6846 padded type built for the return type if it is unconstrained.
6847
61e46a7d
NF
68482011-04-14 Nathan Froyd <froydnj@codesourcery.com>
6849
6850 * gcc-interface/utils.c (gnat_poplevel): Use block_chainon.
6851
81f653d6
NF
68522011-04-12 Nathan Froyd <froydnj@codesourcery.com>
6853
b4867846
EB
6854 * gcc-interface/ada-tree.h (union lang_tree_node): Check for TS_COMMON
6855 before calling TREE_CHAIN.
81f653d6
NF
6856 * gcc-interface/misc.c (gnat_init_ts): New function.
6857 (LANG_HOOKS_INIT_TS): Define.
6858
a358e188
MJ
68592011-04-12 Martin Jambor <mjambor@suse.cz>
6860
b4867846
EB
6861 * gcc-interface/utils.c (end_subprog_body): Call cgraph_get_create_node
6862 instead of cgraph_node.
a358e188 6863
29b1c5a4
EB
68642011-04-08 Eric Botcazou <ebotcazou@adacore.com>
6865
6866 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set minimum
6867 alignment on fields of the RETURN type built for the Copy-In Copy-Out
6868 mechanism.
6869
88872b00
EB
68702011-04-08 Eric Botcazou <ebotcazou@adacore.com>
6871
6872 * gcc-interface/trans.c (Identifier_to_gnu): Do not return initializers
6873 of aggregate types that contain a placeholder.
6874
dcf0c47e
NF
68752011-04-08 Nathan Froyd <froydnj@codesourcery.com>
6876
6877 * gcc-interface/utils.c (handle_sentinel_attribute): Don't use
b4867846 6878 TYPE_ARG_TYPES.
dcf0c47e
NF
6879 (handle_type_generic_attribute): Likewise.
6880
53e3000c
EB
68812011-04-04 Eric Botcazou <ebotcazou@adacore.com>
6882
6883 PR ada/47163
6884 * s-oscons-tmplt.c (MSG_WAITALL): Fix thinko in previous change.
6885
ab380bb4
KT
68862011-04-04 Kai Tietz <ktietz@redhat.com>
6887
6888 PR ada/47163
0bad0e23
EB
6889 * s-oscons-tmplt.c (MSG_WAITALL): Define it for native windows targets
6890 to flag value.
ab380bb4 6891
8ffac116
EB
68922011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6893
6894 * gcc-interface/utils2.c (build_allocator): In the unconstrained array
6895 type case, do not strip a padding type around the array type.
6896
de9528f0
EB
68972011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6898
6899 * gcc-interface/utils.c (update_pointer_to): Finalize named pointer
6900 types.
6901
d9d7a26c
EB
69022011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6903
6904 * gcc-interface/lang.opt (feliminate-unused-debug-types): Delete.
6905 * gcc-interface/misc.c (gnat_handle_option): Remove special handling
de9528f0 6906 code for -feliminate-unused-debug-types.
d9d7a26c
EB
6907 (gnat_post_options): Likewise.
6908
4cb12a90
EB
69092011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6910
6911 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
6912 declaration of a pointer type, then set DECL_ORIGINAL_TYPE to a
6913 distinct copy.
6914
acccc61c
EB
69152011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6916
6917 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not force the
6918 DECL_ARTIFICIAL flag on enumeration types.
6919
583eb0c9
EB
69202011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6921
6922 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Do not make
6923 fat pointer types artificial unconditionally.
6924 <E_Array_Subtype>: Attach the base array type as a parallel type if it
6925 isn't artificial.
6926
e3edbd56
EB
69272011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6928
6929 * gcc-interface/gigi.h (get_dummy_type): Declare.
6930 (build_dummy_unc_pointer_types): Likewise.
6931 (finish_fat_pointer_type): Likewise.
6932 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: If a dummy
6933 fat pointer type has been built, complete it in place.
6934 <E_Access_Type>: Call build_dummy_unc_pointer_types to build dummy fat
6935 and thin pointers. Remove useless variable.
6936 (finish_fat_pointer_type): Make global and move to...
6937 * gcc-interface/utils.c (finish_fat_pointer_type): ...here.
6938 (get_dummy_type): New function.
6939 (build_dummy_unc_pointer_types): Likewise.
6940 (gnat_pushdecl): Propage the name to the anonymous variants only.
6941 (update_pointer_to): Only adjust the pointer types in the unconstrained
6942 array case.
6943
65444786
EB
69442011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6945
6946 * gcc-interface/ada-tree.h (DECL_TAFT_TYPE_P): New flag.
6947 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Incomplete_Type>: Set it
6948 if this is a Taft amendment type and the full declaration is available.
6949 * gcc-interface/trans.c (process_type): Likewise.
6950 If there is an old type, mark the new one as used if DECL_TAFT_TYPE_P.
6951 (process_freeze_entity): Likewise.
6952 * gcc-interface/utils.c (dummy_global): New static variable.
6953 (gnat_write_global_declarations): If there are types declared as used
6954 at the global level, insert them in the global hash table.
6955
1aeb40dd
EB
69562011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6957
6958 * gcc-interface/gigi.h (record_builtin_type): Add ARTIFICIAL_P param.
6959 * gcc-interface/utils.c (gnat_pushdecl): If this is a non-artificial
6960 declaration of an array type, then set DECL_ORIGINAL_TYPE to a distinct
6961 copy.
6962 (record_builtin_type): Add ARTIFICIAL_P parameter. Set DECL_ARTIFICIAL
6963 flag of the type accordingly.
6964 * gcc-interface/trans.c (gigi): Adjust calls to record_builtin_type.
6965
80ec8b4c
EB
69662011-04-02 Eric Botcazou <ebotcazou@adacore.com>
6967
6968 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
6969 finalizing types when updating the pointers to the designated type.
6970 <all>: Finalize the deferred types even if we didn't defer processing
6971 of incomplete types in this invocation.
6972
2a9d769a
OH
69732011-04-01 Olivier Hainque <hainque@adacore.com>
6974 Nicolas Setton <setton@adacore.com>
6975 Eric Botcazou <ebotcazou@adacore.com>
6976
6977 * gcc-interface/misc.c (gnat_descriptive_type): New function.
6978 (LANG_HOOKS_DESCRIPTIVE_TYPE): Redefine to gnat_descriptive_type.
6979
2438d7a6
KT
69802011-03-28 Kai Tietz <ktietz@redhat.com>
6981
333d8aff 6982 * gcc-interface/Makefile.in (SO_LIB): Handle multilib build for native
80ec8b4c
EB
6983 Windows targets.
6984 (EH_MECHANISM): Use GCC exception mechanism for native Windows targets.
6985 * system-mingw.ads (System): Change ZCX_By_Default default to True.
333d8aff 6986
80ec8b4c 6987 * raise-gcc.c (PERSONALITY_FUNCTION): Add prototype.
2438d7a6 6988
8ad150f6
TG
69892011-03-28 Tristan Gingold <gingold@adacore.com>
6990
6991 PR ada/44431
80ec8b4c
EB
6992 * gcc-interface/Make-lang.in (ada/b_gnat1.adb): Replace ada/b_gnat1.c.
6993 Use ada output of gnatbind.
8ad150f6
TG
6994 (ada/b_gnatb.adb): Ditto.
6995 (ada/b_gnat1.o, ada/b_gnatb.o): New rules.
6996 (ada.mostlyclean, ada.stage1)
6997 (ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
6998 (ada.stagefeedback): Adjust.
80ec8b4c 6999 * gcc-interface/Makefile.in (b_gnatl.adb): Replace b_gnatl.c.
8ad150f6
TG
7000 Use ada output of gnatbind.
7001 (b_gnatm.adb): Ditto.
7002 (b_gnatl.o, b_gnatm.o): New rules.
7003
51c7954d
EB
70042011-03-26 Eric Botcazou <ebotcazou@adacore.com>
7005
7006 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
7007 for the padded type built to support a specified size or alignment.
7008
6ddf9843
EB
70092011-03-26 Eric Botcazou <ebotcazou@adacore.com>
7010
7011 * gcc-interface/gigi.h (finalize_from_with_types): Adjust comment.
7012 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Access_Type>: Defer
7013 unconditionally to the end of the unit when the designated type is
7014 limited_with'ed.
7015 <all>: Rename local variable. Attempt to un-defer types only and do it
7016 for limited_with'ed types as well.
7017 (finalize_from_with_types): Adjust comment. Rename variable and tidy.
7018 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Use GNAT_UNIT
7019 consistently and remove redundant call to finalize_from_with_types.
7020
5daed84a
EB
70212011-03-26 Eric Botcazou <ebotcazou@adacore.com>
7022
7023 * inline.adb (Back_End_Cannot_Inline): Lift restriction on calls to
7024 subprograms without a previous spec declared in the same unit.
7025 * gcc-interface/trans.c (Compilation_Unit_to_gnu): Process inlined
7026 subprograms at the end of the unit instead of at the beginning.
7027 * gcc-interface/utils.c (create_subprog_decl): Check that the entity
7028 isn't public for the special handling of non-inline functions nested
7029 inside inline external functions.
7030
0edf1bb2
JL
70312011-03-25 Jeff Law <law@redhat.com>
7032
5daed84a 7033 * gcc-interface/utils.c (def_fn_type): Add missing va_end.
0edf1bb2 7034
e3c4580e
EB
70352011-03-24 Eric Botcazou <ebotcazou@adacore.com>
7036
7037 * einfo.ads (Size_Depends_On_Discriminant): Adjust description.
7038 * layout.adb (Compute_Size_Depends_On_Discriminant): New procedure
7039 to compute Set_Size_Depends_On_Discriminant.
7040 (Layout_Type): Call it on array types in back-end layout mode.
7041 * sem_util.adb (Requires_Transient_Scope): Return true for array
7042 types only if the size depends on the value of discriminants.
7043 * gcc-interface/utils2.c (build_binary_op) <MODIFY_EXPR>: Use the RHS
7044 type if the RHS is a call to a function that returns an unconstrained
7045 type with default discriminant.
7046
abbc8c7b
EB
70472011-03-24 Eric Botcazou <ebotcazou@adacore.com>
7048
7049 * gcc-interface/trans.c (gnat_to_gnu): Remove obsolete case of
7050 non-conversion to the nominal result type at the end.
7051
ddb5a105
EB
70522011-03-23 Eric Botcazou <ebotcazou@adacore.com>
7053
7054 * gcc-interface/trans.c (create_temporary): New function taken from...
7055 (create_init_temporary): ...here. Call it.
7056 (call_to_gnu): Create the temporary for the return value early, if any.
7057 Create it for a function with copy-in/copy-out parameters if there is
7058 no target; in other cases of copy-in/copy-out, use another temporary.
7059 Push the new binding level lazily. Add and rename local variables.
7060
0d853156
EB
70612011-03-23 Eric Botcazou <ebotcazou@adacore.com>
7062
7063 * gcc-interface/decl.c (validate_size): Improve comments and tweak
7064 error message.
7065 (set_rm_size): Likewise.
7066
4184ef1b
EB
70672011-03-23 Eric Botcazou <ebotcazou@adacore.com>
7068
7069 * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create TYPE_DECL
7070 for the padded type built in order to support a specified alignment.
7071 Fix incorrect formatting.
7072
bf7eefab
EB
70732011-03-21 Eric Botcazou <ebotcazou@adacore.com>
7074
7075 PR bootstrap/48216
7076 * gcc-interface/decl.c (elaborate_expression_1): Localize GNU_DECL.
7077
ef0feeb2
EB
70782011-03-21 Eric Botcazou <ebotcazou@adacore.com>
7079
7080 * gcc-interface/decl.c (components_to_record): Add REORDER parameter,
7081 rename DEBUG_INFO_P into DEBUG_INFO and move P_GNU_REP_LIST parameter
7082 to the end of the list. Adjust recursive call. Rename local variable.
7083 If REORDER is true, reorder components of the record type.
7084 (gnat_to_gnu_entity): Pass OK_To_Reorder_Components flag as argument to
7085 components_to_record and adjust the parameter list.
7086
646f9414
EB
70872011-03-21 Eric Botcazou <ebotcazou@adacore.com>
7088
7089 * gcc-interface/decl.c (elaborate_expression_1): When optimization is
7090 disabled, use the variable for bounds of loop iteration scheme.
7091
62d784f7
KT
70922011-03-21 Kai Tietz <ktietz@redhat.com>
7093
7094 PR target/12171
0bad0e23 7095 * gcc-interface/utils.c (gnat_internal_attribute_table): Add column.
62d784f7 7096
f230d759
EB
70972011-03-17 Eric Botcazou <ebotcazou@adacore.com>
7098
7099 * gcc-interface/decl.c (elaborate_expression_1): Try harder to find
7100 out whether the expression is read-only. Short-circuit placeholder
7101 case and rename a couple of local variables.
7102
bb1f7929
EB
71032011-03-17 Eric Botcazou <ebotcazou@adacore.com>
7104
7105 * gcc-interface/gigi.h (smaller_form_type_p): Declare.
7106 * gcc-interface/trans.c (smaller_form_type_p): Make global and move...
7107 * gcc-interface/utils.c (smaller_form_type_p): ...to here.
7108 (convert): Deal with conversions from a smaller form type specially.
7109
400a2d24
EB
71102011-02-14 Eric Botcazou <ebotcazou@adacore.com>
7111
7112 * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
7113 its argument, except for the special -I- switch.
7114
c26bc3ad
GP
71152011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
7116
0bad0e23
EB
7117 * gnat_ugn.texi (Compiling Different Versions of Ada): Update link to
7118 "Ada Issues".
c26bc3ad 7119
07b8e910
EB
71202011-02-08 Eric Botcazou <ebotcazou@adacore.com>
7121
7122 * gcc-interface/Makefile.in (x86-64 darwin): Handle multilibs.
7123
31a5a547
EB
71242011-02-03 Eric Botcazou <ebotcazou@adacore.com>
7125
7126 * gcc-interface/gigi.h (fill_vms_descriptor): Take GNU_TYPE instead of
7127 GNAT_FORMAL.
7128 * gcc-interface/utils2.c (fill_vms_descriptor): Move from here to...
7129 * gcc-interface/utils.c (fill_vms_descriptor): ...here. Take GNU_TYPE
7130 instead of GNAT_FORMAL. Protect the expression against multiple uses.
7131 Do not generate the check directly, instead instantiate the template
7132 check present in the descriptor.
7133 (make_descriptor_field): Move around.
7134 (build_vms_descriptor32): Build a template check in the POINTER field.
7135 (build_vms_descriptor): Remove useless suffixes.
7136 * gcc-interface/trans.c (call_to_gnu): Adjust fill_vms_descriptor call.
7137
dcf25f59
EB
71382011-01-26 Eric Botcazou <ebotcazou@adacore.com>
7139
7140 PR bootstrap/47467
7141 * targext.c: Include target files if IN_RTS is defined.
7142
0418e131
RG
71432011-01-26 Richard Guenther <rguenther@suse.de>
7144
7145 PR bootstrap/47467
7146 * targext.c: Include config.h.
7147 * gcc-interface/Make-lang.in (ada/targext.o): Add $(CONFIG_H)
7148 dependency.
7149
c6eecbd8
PO
71502011-01-04 Pascal Obry <obry@adacore.com>
7151 Eric Botcazou <ebotcazou@adacore.com>
7152
7153 * gcc-interface/decl.c: Disable Stdcall convention handling for 64-bit.
7154
2d3c7e4f
EB
71552011-01-04 Eric Botcazou <ebotcazou@adacore.com>
7156
7157 * gcc-interface/trans.c (Case_Statement_to_gnu): Put the SLOC of the
7158 end-of-case on the end label and its associated gotos, if any.
7159
0394741f
EB
71602011-01-04 Eric Botcazou <ebotcazou@adacore.com>
7161
7162 * gcc-interface/trans.c (Subprogram_Body_to_gnu): Evaluate the
7163 expressions of the parameter cache within the statement group of
7164 the CICO mechanism.
7165
2a02d090
OH
71662011-01-04 Olivier Hainque <hainque@adacore.com>
7167 Eric Botcazou <ebotcazou@adacore.com>
7168
7169 * gcc-interface/trans.c (BLOCK_SOURCE_END_LOCATION): Provide default.
7170 (set_end_locus_from_node): New function.
7171 (Subprogram_Body_to_gnu): Use it to mark both the inner BIND_EXPR we
7172 make and the function end_locus.
7173 (Compilation_Unit_to_gnu): Call it instead of a straight Sloc_to_locus
7174 for the elaboration subprogram.
7175 (set_gnu_expr_location_from_node) <default case>: Use it to attempt to
7176 set the end_locus of the expression as well.
7177
89f5e978
EB
71782011-01-04 Eric Botcazou <ebotcazou@adacore.com>
7179
7180 PR ada/47131
7181 * gcc-interface/trans.c (Identifier_to_gnu): In SJLJ mode, do not make
7182 variables that are referenced in exception handlers volatile.
7183
7184
ad41bd84 7185\f
797103eb 7186Copyright (C) 2011 Free Software Foundation, Inc.
ad41bd84
JM
7187
7188Copying and distribution of this file, with or without modification,
7189are permitted in any medium without royalty provided the copyright
7190notice and this notice are preserved.
This page took 1.539266 seconds and 5 git commands to generate.