2014-10-17 Robert Dewar <dewar@adacore.com>
[official-gcc.git] / gcc / ada / ChangeLog
bloba151364dc72a0ccbf44af81f3c5f9327c31ff0ae
1 2014-10-17  Robert Dewar  <dewar@adacore.com>
3         * aspects.ads: Documentation fix, aspect Lock_Free does have a
4         corresponding pragma.
5         * gnat_rm.texi: Document implementation defined boolean aspects
6         as boolean.
8 2014-10-17  Ed Schonberg  <schonberg@adacore.com>
10         * sem_ch13.adb (Add_Invariants): For a class-wide type invariant,
11         preserve semantic information on the invariant expression
12         (typically a function call) because it may be inherited by a
13         type extension in a different unit, and it cannot be resolved
14         by visibility elsewhere because it may refer to local entities.
16 2014-10-17  Robert Dewar  <dewar@adacore.com>
18         * gnat_rm.texi: Document that string literal can be used for
19         pragma Warnings when operating in Ada 83 mode.
21 2014-10-17  Ed Schonberg  <schonberg@adacore.com>
23         * freeze.adb (Find_Aggregate_Component_Desig_Type): New
24         subsidiary function to Freeze_ Expression, used to determine
25         whether an aggregate for an array of access types also freezes the
26         designated type, when some aggregate components are allocators.
28 2014-10-17  Ed Schonberg  <schonberg@adacore.com>
30         * a-strsea.adb (Find_Token): AI05-031 indicates that the
31         procedure must raise Index_Error when Source is not empty and
32         the From parameter is not within the range of the Source string.
34 2014-10-17  Robert Dewar  <dewar@adacore.com>
36         * sem_prag.adb (Is_Static_String_Expression): Allow string
37         literal in Ada 83 mode.
39 2014-10-17  Vincent Celier  <celier@adacore.com>
41         * prj-conf.adb (Get_Config_Switches): In CodePeer mode, do
42         not take into account any compiler command from package IDE.
44 2014-10-17  Ed Schonberg  <schonberg@adacore.com>
46         * sem_ch12.adb (Build_Function_Wrapper): The formals of the
47         wrapper must have the same identifiers as those of the formal
48         subprogram, because calls within the generic may use named
49         associations.
51 2014-10-17  Robert Dewar  <dewar@adacore.com>
53         * sem_ch3.adb, a-strsea.adb: Minor reformatting.
54         * par-ch6.adb (P_Subprogram): Fix bad handling of null procedures.
56 2014-10-17  Ed Schonberg  <schonberg@adacore.com>
58         * sem_ch3.adb (Build_Derived_Enumeration_Type): Propagate aspect
59         specfications from original type declaration to declaration of
60         implicit base, because original node is rewritten as a subtype
61         declaration on which type aspects do not belong.
63 2014-10-17  Hristian Kirtchev  <kirtchev@adacore.com>
65         * sem_ch3.adb (Propagate_Default_Init_Cond_Attributes): A derived type
66         inherits the attributes related to pragma Default_Initial_Condition
67         from its parent type.
69 2014-10-17  Ed Schonberg  <schonberg@adacore.com>
71         * a-strsea.adb (Index - versions with a From parameter):
72         According to AI05-056, the Index functions with a From parameter
73         return 0 if the source is an empty string.
75 2014-10-17  Hristian Kirtchev  <kirtchev@adacore.com>
77         * sem_prag.adb (Analyze_Refined_Depends_In_Decl_Part): Disable
78         the consistency checks in ASIS mode.
80 2014-10-17  Arnaud Charlet  <charlet@adacore.com>
82         * s-expmod.ads: Minor typo fix.
84 2014-10-17  Robert Dewar  <dewar@adacore.com>
86         * sem_util.adb: Minor reformatting.
88 2014-10-17  Ed Schonberg  <schonberg@adacore.com>
90         * sem_ch12.adb (Build_Function_Wrapper): Build wrappers for
91         actuals that are defaulted subprograms of the formal subprogram
92         declaration.
94 2014-10-17  Robert Dewar  <dewar@adacore.com>
96         * exp_ch4.adb (Expand_N_Op_Eq): Make sure we deal with the
97         implementation base type.
98         * sinfo.ads: Add a note for N_Op_Eq and N_Op_Ne that record
99         operands are always expanded out into component comparisons.
101 2014-10-17  Robert Dewar  <dewar@adacore.com>
103         * s-vallli.adb: Minor comment correction.
104         * s-valuti.ads: Minor comment reformatting.
106 2014-10-17  Robert Dewar  <dewar@adacore.com>
108         * gnat_rm.texi: Document System.Atomic_Counters.
109         * impunit.adb: Add System.Atomic_Counters (s-atocou.ads) to the
110         list of user- accessible units added as children of System.
111         * s-atocou.ads: Update comment.
113 2014-10-17  Arnaud Charlet  <charlet@adacore.com>
115         * s-expmod.ads: Add comments.
117 2014-10-17  Hristian Kirtchev  <kirtchev@adacore.com>
119         * sem_ch3.adb (Build_Derived_Record_Type): Remove the propagation
120         of all attributes related to pragma Default_Initial_Condition.
121         (Build_Derived_Type): Propagation of all attributes related
122         to pragma Default_Initial_Condition.
123         (Process_Full_View): Account for the case where the full view derives
124         from another private type and propagate the attributes related
125         to pragma Default_Initial_Condition to the private view.
126         (Propagate_Default_Init_Cond_Attributes): New routine.
127         * sem_util.adb: Alphabetize various routines.
128         (Build_Default_Init_Cond_Call): Use an unchecked type conversion
129         when calling the default initial condition procedure of a private type.
130         (Build_Default_Init_Cond_Procedure_Declaration): Prevent
131         the generation of multiple default initial condition procedures.
133 2014-10-17  Robert Dewar  <dewar@adacore.com>
135         * prj-conf.adb: Revert previous change.
137 2014-10-17  Robert Dewar  <dewar@adacore.com>
139         * lib-writ.ads, s-valdec.ads: Minor reformatting.
141 2014-10-17  Ed Schonberg  <schonberg@adacore.com>
143         * sem_ch12.adb: Additional work on function wrappers.
145 2014-10-17  Eric Botcazou  <ebotcazou@adacore.com>
147         * exp_util.adb (Possible_Bit_Aligned_Component): Also recurse
148         on the renamed object of renamings.
150 2014-10-17  Vincent Celier  <celier@adacore.com>
152         * prj-conf.adb (Parse_Project_And_Apply_Config): In CodePeer
153         mode, always use the native target.
155 2014-10-16  Andrew MacLeod  <amacleod@redhat.com>
157         * gcc-interface/misc.c: Adjust include files.
159 2014-10-13  Eric Botcazou  <ebotcazou@adacore.com>
160             Alan Modra  <amodra@gmail.com>
162         PR ada/63225
163         * uintp.adb (Vector_To_Uint): Move from here to...
164         * uintp.ads (UI_Vector): Make public.
165         (Vector_To_Uint): ...here.
167 2014-10-10  Robert Dewar  <dewar@adacore.com>
169         * freeze.adb, sem_attr.adb: Minor reformatting.
171 2014-10-10  Johannes Kanig  <kanig@adacore.com>
173         * a-cfdlli.ads, a-cfhama.ads, a-cfhase.ads, a-cforma.ads,
174         a-cforse.ads, a-cofove.ads: add "Default_Initial_Condition"
175         to container type.
177 2014-10-10  Vincent Celier  <celier@adacore.com>
179         * prj-conf.adb (Do_Autoconf): In Codepeer mode, do not try to get
180         any configuration switches from the project file.
182 2014-10-10  Ed Schonberg  <schonberg@adacore.com>
184         * sem_ch12.adb (Build_Wrapper): Renamed as Build_Operator_Wrapper.
185         (Build_Function_Wrapper): New function, to construct a wrapper
186         function for actuals that are functions with an arbitrary
187         number of parameters. Used in GNATProve mode to simplify proof
188         propagation in instantiations.
190 2014-10-10  Robert Dewar  <dewar@adacore.com>
192         * freeze.adb, gnat1drv.adb, sem_ch13.adb: Minor reformatting and
193         code clean up.
195 2014-10-10  Hristian Kirtchev  <kirtchev@adacore.com>
197         * sem_res.adb (Is_OK_Volatile_Context): Allow
198         a volatile object reference to appear as the expression of a
199         type conversion.
201 2014-10-10  Ed Schonberg  <schonberg@adacore.com>
203         * sem_ch13.adb (Analyze_Aspect_Specifications, Library_Unit_Aspects):
204         Aspect specification is legal on a local instantiation of a
205         library-level generic unit.
207 2014-10-10  Gary Dismukes  <dismukes@adacore.com>
209         * gnat1drv.adb (Adjust_Global_Switches): Set Front_End_Inlining
210         if inlining has been enabled via -gnatn and the target is not GCC.
212 2014-10-10  Ed Schonberg  <schonberg@adacore.com>
214         * freeze.adb (Freeze_Entity): Freezing a subprogram does
215         not always freeze its profile.  In particular, an attribute
216         reference that takes the access type does not freeze the types
217         of the formals.
219 2014-10-10  Robert Dewar  <dewar@adacore.com>
221         * errout.adb (Adjust_Name_Case): New procedure.
222         (Set_Msg_Node): Use Adjust_Name_Case.
223         * errout.ads (Adjust_Name_Case): New procedure.
224         * exp_intr.adb (Add_Source_Info): Minor code reorganization
225         (use Ekind_In).
226         (Write_Entity_Name): Use Errout.Adjust_Name_Case.
227         * sem_prag.adb (Is_Non_Significant_Pragma_Reference): Review
228         and fix up entries in Sig_Flags, and correct logical errors in
229         function itself.
230         * sprint.adb (Sprint_Node_Actual): Properly print string for
231         raise statement.
233 2014-10-10  Ed Schonberg  <schonberg@adacore.com>
235         * sem_ch3.adb (Analyze_Object_Declaration): For an object of an
236         anonymous array type with delayed aspects, defer freezing of
237         type until object itself is frozen.
238         * freeze.adb (Freeze_Entity): When freezing an object of an
239         anonymous array type with delayed aspects, remove freeze node of
240         object after freezing type, to prevent out-of-order elaboration
241         in the back-end. The initialization call for the object has
242         already been constructed when expanding the object declaration.
244 2014-10-10  Robert Dewar  <dewar@adacore.com>
246         * exp_intr.adb (Write_Entity_Name): Moved to outer level
247         (Write_Entity_Name): Properly handle operator names
248         (Expand_Source_Info): New procedure.
249         * exp_intr.ads (Add_Source_Info): New procedure.
251 2014-10-10  Robert Dewar  <dewar@adacore.com>
253         * butil.ads: Minor reformatting.
254         * sem_ch5.adb: Code clean up.
256 2014-10-10  Robert Dewar  <dewar@adacore.com>
258         * exp_ch11.adb (Expand_N_Raise_Statement): Handle
259         Prefix_Exception_Messages.
260         * opt.adb: Handle new flags Prefix_Exception_Message[_Config].
261         * opt.ads: New flags Prefix_Exception_Message[_Config].
262         * par-prag.adb: New dummy entry for pragma Prefix_Exception_Messages.
263         * snames.ads-tmpl: Add entries for new pragma Prefix_Exception_Messages.
264         * sem_prag.adb: Implement new pragma Prefix_Exception_Messages
265         * gnat_rm.texi: Document pragma Prefix_Exception_Messages.
267 2014-10-10  Gary Dismukes  <dismukes@adacore.com>
269         * sinfo.ads, gnat_ugn.texi, a-except.adb, a-except-2005.adb,
270         raise-gcc.c Spelling changes (prolog => prologue, epilog => epilogue).
272 2014-10-10  Ed Schonberg  <schonberg@adacore.com>
274         * sem_ch5.adb (Is_Wrapped_In_Block): Handle properly blocks that
275         contain pragmas generated for loop invariants and type predicates.
276         Clarify use of this subprogram.
278 2014-10-10  Yannick Moy  <moy@adacore.com>
280         * sem_prag.adb (Analyze_Global_Item): Accept formal objects in Global
281         contracts.
282         * errout.adb, errout.ads (SPARK_Msg_NE): Issue error unless
283         SPARK_Mode is Off.
285 2014-10-10  Vadim Godunko  <godunko@adacore.com>
287         * a-stwima.adb (To_Sequence): Compute size of result array.
289 2014-10-10  Javier Miranda  <miranda@adacore.com>
291         * gnat_ugn.texi (Interfacing with C++ at the Class Level): Update the
292         sources of the example to avoid a warning when the Ada files are
293         automatically generated by the binding generator.
295 2014-10-10  Ed Schonberg  <schonberg@adacore.com>
297         * sem_attr.adb (Resolve_Attribute, case 'Update): Set
298         Do_Range_Check on the expression of a record component
299         association when needed, as is done for array components, when
300         the corresponding type is a scalar type.
302 2014-10-10  Gary Dismukes  <dismukes@adacore.com>
304         * a-coinho-shared.adb: Minor typo fix.
305         * prj-env.ads: Minor reformatting.
307 2014-10-10  Hristian Kirtchev  <kirtchev@adacore.com>
309         * sem_res.adb (Resolve_String_Literal): Do not
310         generate a string literal subtype for the default expression of
311         a formal parameter in GNATprove mode.
313 2014-10-10  Yannick Moy  <moy@adacore.com>
315         * errout.adb (SPARK_Msg_N): Issue error unless SPARK_Mode is Off.
317 2014-10-10  Ed Schonberg  <schonberg@adacore.com>
319         * exp_ch5.adb (Expand_Formal_Container_Element_Loop): Analyze
320         declaration for loop parameter before rest of loop, and set
321         entity kind to prevent assignments to it in the user code.
322         * sem_ch3.adb (Analyze_Object_Contract): No contracts apply to the
323         loop parameter in an element iteration over o formal container.
325 2014-10-10  Robert Dewar  <dewar@adacore.com>
327         * gnat_ugn.texi: Document use of user-level routines to handle
328         e.g. col major arrays.
330 2014-10-10  Doug Rupp  <rupp@adacore.com>
332         * s-osinte-android.adb: Fix misspelling.
333         * gsocket.h: Tweak the Android quirks.
335 2014-10-10  Robert Dewar  <dewar@adacore.com>
337         * errout.ads (SPARK_Msg_N): Fix spec to match change in body.
339 2014-10-10  Robert Dewar  <dewar@adacore.com>
341         * sem_ch13.adb: Minor code reorganization.
343 2014-10-10  Pat Rogers  <rogers@adacore.com>
345         * gnat_rm.texi: Text now indicates pragma No_Run_Time is not
346         for users.
348 2014-10-10  Vadim Godunko  <godunko@adacore.com>
350         * a-coinho-shared.adb: Add minor comment.
351         * a-stzmap.adb (To_Sequence): Compute size of result array.
353 2014-10-10  Javier Miranda  <miranda@adacore.com>
355         * exp_ch3.adb (Build_Init_Procedure): Complete the condition of an
356         if-stmt to match its current documentation.
358 2014-10-10  Robert Dewar  <dewar@adacore.com>
360         * sem_ch7.adb, einfo.adb, einfo.ads, sem_prag.adb, sem_ch12.adb,
361         freeze.adb, sem_util.adb, sem_res.adb, exp_ch6.adb, exp_ch13.adb,
362         sem_ch6.adb, sem_cat.adb, sem_disp.adb
363         (Is_Subprogram_Or_Generic_Subprogram): New primitive. Use this primitive
364         throughout where appropriate.
366 2014-10-10  Bob Duff  <duff@adacore.com>
368         * a-coinho-shared.ads: Minor reformatting.
369         * s-traceb.adb: Minor clean up.
371 2014-10-10  Robert Dewar  <dewar@adacore.com>
373         * ali.adb (Scan_ALI): Read and process new GP flag on ALI P line.
374         * ali.ads (GNATprove_Mode): New component in ALI table.
375         (GNATprove_Mode_Specified): New global.
376         * gnatbind.adb (Gnatbind): Give fatal error if any file compiled
377         in GNATProve mode.
378         * lib-writ.ads, lib-writ.adb (GP): New flag on P line for
379         GNATProve_Mode.
381 2014-10-10  Javier Miranda  <miranda@adacore.com>
383         * exp_ch3.adb (Build_Init_Procedure): Adding assertion.
384         (Build_Init_Statement): Ensure that statements
385         associated with the parent components are located at the beginning
386         of the returned list of statements.
388 2014-10-10  Ed Schonberg  <schonberg@adacore.com>
390         * sem_ch13.adb (Inherit_Aspects_At_Freeze_Node): If the full
391         view of a private type T that has a type invariant is a scalar
392         or constrained array type, the base type created for the full
393         view has the same type invariant.
395 2014-10-10  Robert Dewar  <dewar@adacore.com>
397         * exp_util.ads, sem_ch12.adb, exp_util.adb, i-fortra.ads: Minor code
398         reorganization.
400 2014-09-22  Eric Botcazou  <ebotcazou@adacore.com>
402         * gcc-interface/decl.c (gnat_to_gnu_entity): Adjust comment.
403         * gcc-interface/utils.c (gnat_write_global_declarations): Fix typo.
405 2014-09-15  Jakub Jelinek  <jakub@redhat.com>
407         * gcc-interface/Make-lang.in (check_acats_numbers0,
408         check_acats_numbers1, check_acats_numbers2, check_acats_numbers3,
409         check_acats_numbers4, check_acats_numbers5, check_acats_numbers6,
410         check_acats_numbers, check_acats_subdirs): New variables.
411         (check_acats_targets): Use $(check_acats_subdirs).
412         (check-acats, check-acats%): Rewritten so that for parallelized
413         testing each job runs all the chapters files, with
414         GCC_RUNTEST_PARALLELIZE_DIR set in environment.  Prepare the support
415         directory sequentially and share it.
416         (check-acats-subtargets): Always print just check-acats.
418 2014-08-25  Martin Liska  <mliska@suse.cz>
420         * gcc-interface/utils.c (rest_of_subprog_body_compilation): Adjust to
421         new cgraph interface.
422         (gnat_write_global_declarations): Likewise.
424 2014-08-13  Sylvestre Ledru  <sylvestre@debian.org>
426         * 9drpc.adb: Fix a typo
427         * s-interr.ads: Likewise
428         * s-taskin.ads: Likewise
429         * s-traces.ads: Likewise
430         * sysdep.c: Likewise
432 2014-08-12  Joel Sherrill <joel.sherrill@oarcorp.com>
434         * socket.c: For RTEMS, use correct prototype of gethostbyname_r().
435         * gsocket.h Add include of <unistd.h> on RTEMS.
437 2014-08-11  Joel Sherrill <joel.sherrill@oarcorp.com>
439         * s-osinte-rtems.adb: Correct formatting of line in license block.
441 2014-08-04  Claire Dross  <dross@adacore.com>
443         * exp_util.adb (Get_First_Parent_With_Ext_Axioms_For_Entity):
444         For an instance, look at the scope before the generic parent.
446 2014-08-04  Yannick Moy  <moy@adacore.com>
448         * lib-writ.ads: Update comments.
449         * sem_disp.ads, sem_disp.adb (Inherited_Subprograms): Add
450         parameters to filter inherited subprograms.
452 2014-08-04  Robert Dewar  <dewar@adacore.com>
454         * gnat_rm.texi: Add section on use of address clause for memory
455         mapped I/O.
457 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
459         * sem_ch3.adb (Analyze_Subtype_Declaration): A subtype, in
460         particular the subtype created for a generic actual, inherits
461         invariant information from the base type.
463 2014-08-04  Robert Dewar  <dewar@adacore.com>
465         * aspects.ads, aspects.adb: Add entries for aspect Obsolescent.
466         * gnat_rm.texi: Add documentation for aspect Obsolescent.
467         * sem_ch13.adb (Analyze_Aspect_Specifications): Implement aspect
468         Obsolescent.
469         (Check_Aspect_At_Freeze_Point): Add dummy entry for pragma Obsolescent.
470         * s-osprim-mingw.adb: Minor reformatting.
471         * sem_res.adb (Is_Atomic_Ref_With_Address): New function
472         (Resolve_Indexed_Component): Rework warnings for non-atomic access
473         (Resolve_Selected_Component): Add warnings for non-atomic access.
475 2014-08-04  Doug Rupp  <rupp@adacore.com>
477         * g-calend.adb (timeval_to_duration, duration_to_timeval): Change sec
478         formal to long_long.
479         * g-calend.ads (timeval): Bump up size to accomodate sec type.
480         * s-taprop-linux.adb (timeval_to_duration): Change sec formal to
481         long_long
482         * s-osprim-posix.adb (timeval): Bump up size to accomodate
483         new sec type.
484         (timeval_to_duration): Change sec formal to Long_Long_Integer
485         * s-osinte-darwin.adb (timeval): Bump up
486         size to accomodate new sec type.
487         (timeval_to_duration): Change sec formal to long_long
488         * s-osinte-android.adb: Likewise.
489         * cal.c (__gnat_timeal_to_duration, __gnat_duration_to_timeval): Change
490         sec formal from long to long long.
492 2014-08-04  Robert Dewar  <dewar@adacore.com>
494         * sem_res.adb (Resolve_Qualified_Expression): Make sure
495         Do_Range_Check flag gets set.
497 2014-08-04  Robert Dewar  <dewar@adacore.com>
499         * einfo.ads, einfo.adb (Is_Standard_String_Type): New function.
500         * exp_ch3.adb (Build_Array_Init_Proc): Use
501         Is_Standard_String_Type.
502         (Expand_Freeze_Array_Type): ditto.
503         (Get_Simple_Init_Val): ditto.
504         (Needs_Simple_Initialization): ditto.
505         * sem_eval.adb (Eval_String_Literal): Use Is_Standard_String_Type.
506         * sem_warn.adb (Is_Suspicious_Type): Use Is_Standard_String_Type.
508 2014-08-04  Pascal Obry  <obry@adacore.com>
510         * adaint.c (__gnat_try_lock): Use _tcscpy and _tcscat instead of
511         _stprintf which insert garbage into the wfull_path buffer.
513 2014-08-04  Arnaud Charlet  <charlet@adacore.com>
515         * cal.c: Remove old VMS/nucleus code. Remove obsolete vxworks
516         code.
517         * fe.h: Minor reformatting.
519 2014-08-04  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
521         * cstreams.c: (_LARGEFILE_SOURCE): Guard definition.
523 2014-08-04  Robert Dewar  <dewar@adacore.com>
525         * par-ch13.adb (Get_Aspect_Specifications): Improve error
526         recovery, fixing a -gnatQ bomb.
528 2014-08-04  Yannick Moy  <moy@adacore.com>
530         * sem_ch3.adb (Analyze_Object_Declaration): In GNATprove mode,
531         do not generate two Itypes with the same name for an array
532         definition.
533         * sinfo.ads: Expand doc on GNATprove mode.
535 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
537         * exp_ch3.adb (Expand_Freeze_Record_Type): Set the finalization
538         master and storage pool attributes on the root type of an
539         anonymous access type.
540         * exp_ch4.adb (Expand_N_Allocator): Set the finalization master
541         and storage pool attributes on the root type of an anonymous
542         access type.
544 2014-08-04  Arnaud Charlet  <charlet@adacore.com>
546         * exp_ch3.adb: Minor reformatting.
547         * tb-alvms.c, tb-alvxw.c, tb-ivms.c: Removed.
548         * tracebak.c: Remove use of above files.
549         * gcc-interface/Makefile.in: Update dependencies.
551 2014-08-04  Pierre-Marie Derodat  <derodat@adacore.com>
553         * gcc-interface/utils.c (gnat_set_type_context): Also set the
554         context for parallel types' TYPE_STUB_DECL.  Do not change
555         anything if the context is already set for them.
556         (gnat_pushdecl): Update the comment for calls to
557         gnat_set_type_context to mention parallel types.
558         (add_parallel_type): When adding a context-less parallel type to
559         a type that has a context, propagate the context from the latter
560         type to the former.
561         (process_deferred_decl_context): Call gnat_set_type_context
562         rather than manually setting the type context.
563         (build_unc_object_type): Call gnat_set_type_context on the
564         template type.
566 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
568         * exp_ch5.adb (Expand_N_Case_Statement): If a choice is a
569         subtype indication and the case statement has only two choices,
570         replace subtype indication with its range, because the resulting
571         membership test cannot have a subtype indication as an operand.
573 2014-08-04  Arnaud Charlet  <charlet@adacore.com>
575         * exp_ch3.adb: Update comments, minor reformatting.
577 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
579         * sem_ch3.adb (Analyze_Declarations): Explain why the bodies of
580         the default initial condition procedures are build here.
581         * sem_util.adb (Build_Default_Init_Cond_Procedure): Wrap the
582         analyzed argument of pragma Default_Initial_Condition in some
583         dummy code as GNATprove mode disables assertions, but still
584         needs to see the argument.
586 2014-08-04  Robert Dewar  <dewar@adacore.com>
588         * exp_ch6.adb, sem_util.adb: Minor reformatting.
590 2014-08-04  Olivier Hainque  <hainque@adacore.com>
592         * a-comutr.ads: Set Root_Node_Type'Alignment to
593         Standard'Maximum_Alignment, so that it is at least as large as
594         the max default for Tree_Node_Type'Alignment.
596 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
598         * exp_ch3.adb (Freeze_Type): Remove the generation and inheritance
599         of the default initial condition procedure [body].
600         * sem_ch3.adb (Analyze_Declarations): Create the bodies of
601         all default initial condition procedures at the end of private
602         declaration analysis.
603         * sem_util.adb (Build_Default_Init_Cond_Procedure_Bodies): New
604         routine.
605         (Build_Default_Init_Cond_Procedure_Body): Merged in the
606         processing of routine Build_Default_Init_Cond_Procedure_Bodies.
607         * sem_util.ads (Build_Default_Init_Cond_Procedure_Bodies):
608         New routine.
609         (Build_Default_Init_Cond_Procedure_Body): Removed.
611 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
613         * sem_elab.adb (Check_Elab_Call): Do not check a call to a
614         postcondtion.
615         * exp_ch6.adb (Expand_Call): Clarify handling of inserted
616         postcondition call.
618 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
620         * sem_prag.adb (Analyze_Pragma): Ensure that an
621         internally generated spec for a stand alone body is recognized
622         as a proper context for pragma SPARK_Mode.
624 2014-08-04  Robert Dewar  <dewar@adacore.com>
626         * erroutc.adb (Delete_Msg): Do not decrement Warnings_Treated_As_Errors.
628 2014-08-04  Arnaud Charlet  <charlet@adacore.com>
630         * adabkend.adb (Scan_Back_End_Switches): Ignore extra -o
631         when -gnatO has already been specified, for compatibility
632         with gcc driver.
633         (Scan_Compiler_Args): Do not call Set_Output_Object_File_Name in
634         codepeer mode.
635         * g-expect.ads: Fix typo.
637 2014-08-04  Thomas Quinot  <quinot@adacore.com>
639         * exp_ch4.adb (Insert_Dereference_Action): the actual Size
640         must account for the bounds template if the designated type is
641         an unconstrained array.
643 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
645         * a-cfhama.adb, a-cfhase.adb, a-cforma.adb, a-cforse.adb Add
646         SPARK_Mode in the body.
647         * sem_ch7.adb (Analyze_Package_Body_Helper): Restore the original
648         way to verify the consistency of SPARK_Mode between a spec and
649         a body.
650         * sem_ch12.adb (Analyze_Package_Instantiation): Remove the call
651         to Set_Ignore_Pragma_SPARK_Mode. Set flag Ignore_Pragma_SPARK_Mode
652         manually.
653         (Analyze_Subprogram_Instantiation): Remove the call to
654         Set_Ignore_Pragma_SPARK_Mode. Set flag Ignore_Pragma_SPARK_Mode
655         manually.
656         * sem_prag.adb (Analyze_Pragma): Remove local variable
657         Inst_Id. SPARK_Mode can no longer be applied to a package or
658         subprogram instantiation.
659         * sem_util.adb, sem_util.ads (Set_Ignore_Pragma_SPARK_Mode):
660         Removed.
662 2014-08-04  Robert Dewar  <dewar@adacore.com>
664         * sem_prag.adb, osint.adb, osint.ads: Minor reformatting.
666 2014-08-04  Yannick Moy  <moy@adacore.com>
668         * sem_ch3.adb (Derive_Type_Declaration,
669         Process_Discriminants): Remove SPARK-specific legality checks.
671 2014-08-04  Thomas Quinot  <quinot@adacore.com>
673         * g-sechas.ads, g-sechas.adb (HMAC_Initial_Context): New subprogram.
674         * gnat_rm.texi (GNAT.MD5/SHA1/SHA224/SHA256/SHA512): Document support
675         for HMAC.
677 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
679         * sem_ch7.adb (Analyze_Package_Body_Helper): When verifying the
680         compatibility of SPARK_Mode between a spec and a body, use the
681         SPARK_Mode of the public part.
682         * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): Use
683         the already available routine to exchange the aspects between
684         the template and its copy. Analyze the aspects of copy to
685         ensure that the corresponding pragmas perform their semantic
686         effects.  The partial analysis of aspects is no longer needed.
687         (Analyze_Package_Instantiation): Save and restore the SPARK_Mode
688         of the context.
689         (Analyze_Subprogram_Instantiation): Save and restore the SPARK_Mode of
690         the context.
691         * sem_prag.adb (Analyze_Pragma): Do not bypass a subprogram
692         instantiation which does not come from source.
694 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
696         * a-cfhama.ads, a-cfhase.ads, a-cforma.ads, a-cforse.ads Add
697         SPARK_Mode pragmas to the public and private part of the unit.
698         * sem_ch3.adb (Derive_Type_Declaration): Ensure that a derived
699         type cannot have discriminants if the parent type already has
700         discriminants.
701         (Process_Discriminants): Ensure that the type of a discriminant is
702         discrete.
703         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): The check on
704         SPARK_Mode compatibility between a spec and a body can now be
705         safely performed while processing a generic.
706         * sem_ch7.adb (Analyze_Package_Body_Helper): The check on
707         SPARK_Mode compatibility between a spec and a body can now be
708         safely performed while processing a generic.
709         * sem_prag.adb (Analyze_Pragma): Pragma SPARK_Mode can now be
710         safely analyzed when processing a generic.
712 2014-08-04  Nicolas Roche  <roche@adacore.com>
714         * g-dirope.adb: Minor reformating.
716 2014-08-04  Robert Dewar  <dewar@adacore.com>
718         * sem_ch6.adb: Minor reformatting.
720 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
722         * sem_prag.adb (Analyze_Pragma, case Assert and related pragmas):
723         Before normalizing these pragmas into a pragma Check, preanalyze
724         the optional Message argument, (which is subsequently copied)
725         so that it has the proper semantic information for ASIS use.
726         * sem_case.adb: Initialize flag earlier.
727         * osint.adb, osint.ads (Find_File): Add parameter Full_Name, used when
728         the full source path of a configuration file is requested.
729         (Read_Source_File): Use Full_Name parameter..
731 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
733         * opt.ads Alphabetize various global flags. New flag
734         Ignore_Pragma_SPARK_Mode along with a comment on usage.
735         * sem_ch6.adb (Analyze_Generic_Subprogram_Body):
736         Pragma SPARK_Mode is now allowed in generic units.
737         (Analyze_Subprogram_Body_Helper): Do not verify the compatibility
738         between the SPARK_Mode of a spec and that of a body when inside
739         a generic.
740         * sem_ch7.adb (Analyze_Package_Body_Helper): Do not verify the
741         compatibility between the SPARK_Mode of a spec and that of a
742         body when inside a generic.
743         * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration):
744         Pragma SPARK_Mode is now allowed in generic units.
745         (Analyze_Package_Instantiation): Save and restore the value of
746         flag Ignore_ Pragma_SPARK_Mode in a stack-like fasion. Set
747         the governing SPARK_Mode before analyzing the instance.
748         (Analyze_Subprogram_Instantiation): Save and restore the value
749         of flag Ignore_ Pragma_SPARK_Mode in a stack-like fasion. Set
750         the governing SPARK_Mode before analyzing the instance.
751         * sem_ch13.adb (Analyze_Aspect_Specifications): Emulate the
752         placement of a source pragma when inserting the generated pragma
753         for aspect SPARK_Mode.
754         * sem_prag.adb (Analyze_Pragma): Reimplement the handling of
755         pragma SPARK_Mode to allow for generics and their respective
756         instantiations.
757         * sem_util.ads, sem_util.adb (Check_SPARK_Mode_In_Generic): Removed.
758         (Set_Ignore_Pragma_SPARK_Mode): New routine.
760 2014-08-04  Eric Botcazou  <ebotcazou@adacore.com>
762         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Component>: Deal with
763         renaming discriminants in tagged types first.
764         * gcc-interface/trans.c (gnat_to_gnu) <N_Selected_Component>: Test
765         the underlying type of the prefix.
766         (Pragma_to_gnu, case Pragma_Warning): Ignore Reason => "..."
767         (process_freeze_entity): Reset the nodes of all the view of a type,
768         if any.
770 2014-08-04  Doug Rupp  <rupp@adacore.com>
771             Olivier Hainque  <hainque@adacore.com>
773         * gcc-interface/Makefile.in (x86 VxWorks): Add filter-out for vxworks7
774         and remove incorrect EH_MECHANISM macros.
775         Add sigtramp.h to EXTRA_LIBGNAT_SRCS when we add sigtramp-vxworks.o to
776         EXTRA_LIBGNAT_OBJS.
778 2014-08-04  Robert Dewar  <dewar@adacore.com>
780         * exp_attr.adb (Expand_N_Attribute_Reference): Make sure prefix
781         of constructed 'Valid attribute in -gnatVa mode does not appear
782         to come from source.
783         * sem_attr.adb (Analyze_Access_Attribute): Don't set
784         Never_Set_In_Source for non-source reference.
785         * sem_util.adb: Minor reformatting.
786         * sem_warn.adb (Check_References): Don't check Address_Taken,
787         not necessary, see comment.
789 2014-08-04  Robert Dewar  <dewar@adacore.com>
791         * sem_util.adb, sem_case.adb: Minor reformatting.
793 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
795         * exp_ch9.adb (Extract_Entry): If the synchronized object is a
796         limited view, replace with non-limited view, which is available
797         at the point of an entry call.
799 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
801         * exp_ch6.adb (Expand_Call): If the call is to a function in
802         a run-time unit that is marked Inline_Always, we must suppress
803         debugging information on it, so that the code that is eventually
804         inlined will not affect debugging of the user program.
806 2014-08-04  Robert Dewar  <dewar@adacore.com>
808         * inline.adb, einfo.ads, s-tassta.adb, s-tarest.adb: Minor comment
809         fixes.
811 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
813         * sem_prag.adb (Process_Import_Or_Interface): Handle properly
814         an aspect Import that specifies a False value.
816 2014-08-04  Robert Dewar  <dewar@adacore.com>
818         * gnat_rm.texi: Add section on aspect Invariant'Class.
820 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
822         * sem_case.adb (Check_Choice_Set): New flag Predicate_Error,
823         for better control of cascaded error messages when some choice
824         in a case statement over a predicated type violates the given
825         static predicate.
827 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
829         * sem_ch3.adb (Build_Derived_Type): Modify the
830         inheritance of the rep chain to ensure that a non-tagged type's
831         items are not clobbered during the inheritance.
833 2014-08-04  Robert Dewar  <dewar@adacore.com>
835         * sem_ch3.adb, einfo.ads: Minor reformatting.
837 2014-08-04  Yannick Moy  <moy@adacore.com>
839         * inline.adb (Can_Be_Inlined_In_GNATprove_Mode): Fix
840         detection of subprograms that cannot be inlined in GNATprove mode.
842 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
844         * einfo.adb: Add guard to Returns_Limited_View.
846 2014-08-04  Jose Ruiz  <ruiz@adacore.com>
848         * s-tassta.adb, s-tarest.adb (Task_Wrapper): Force maximum alignment of
849         the secondary stack to respect the alignments of the returned objects.
851 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
853         * einfo.ads, einfo.adb (Returns_Limited_View): New flag defined
854         on function entities whose return type is a limited view.
855         * freeze.adb (Freeze_Entity): Use Returns_Limited_View to determine
856         where to place the freeze node for a function that returns the
857         limited view of a type, when the function is called and frozen
858         in a different unit.
860 2014-08-04  Eric Botcazou  <ebotcazou@adacore.com>
862         * sem_ch3.adb (Build_Derived_Private_Type): Minor code
863         refactoring.
865 2014-08-04  Robert Dewar  <dewar@adacore.com>
867         * gnat_ugn.texi: Clarify documentation on assertions.
869 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
871         * sem_aggr.adb (Resolve_Record_Aggregate, Get_Value): Warn
872         if a component association has a box initialization when the
873         component type has no default initialization, either through an
874         initial value, an aspect, or an implicit initialization procedure.
876 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
878         * freeze.adb: Code clean up.
880 2014-08-04  Thomas Quinot  <quinot@adacore.com>
882         * sem_ch5.adb: Minor reformatting.
884 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
886         * freeze.adb (Late_Freeze_Subprogram): Following AI05-151,
887         a function can return a limited view of a type declared
888         elsewhere. In that case the function cannot be frozen at the end
889         of its enclosing package. If its first use is in a different unit,
890         it cannot be frozen there, but if the call is legal the full view
891         of the return type is available and the subprogram can now be
892         frozen. However the freeze node cannot be inserted at the point
893         of call, but rather must go in the package holding the function,
894         so that the backend can process it in the proper context.
896 2014-08-04  Robert Dewar  <dewar@adacore.com>
898         * exp_ch5.adb, sem_ch5.adb, einfo.ads: Minor reformatting.
900 2014-08-04  Arnaud Charlet  <charlet@adacore.com>
902         * sem_ch4.adb (Operator_Check): Refine previous change.
904 2014-08-04  Arnaud Charlet  <charlet@adacore.com>
906         * sem_scil.ads: Improve comments.
907         * sem_ch4.adb (Analyze_Equality_Op): Add support for
908         Allow_Integer_Address (equality between Address and Integer).
910 2014-08-04  Yannick Moy  <moy@adacore.com>
912         * a-cfhama.adb, a-cforse.adb: Minor fixes to avoid using prefix
913         notation on untagged objects.
914         * sem.ads: Update comment.
915         * inline.adb (Can_Be_Inlined_In_GNATprove_Mode): Do
916         not inline subprograms declared in the visible part of a package.
918 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
920         * exp_ch5.adb: minor reformatting.
921         * einfo.ads, einfo.adb (Is_Processed_Transient): Applies to loop
922         parameters.
924 2014-08-04  Thomas Quinot  <quinot@adacore.com>
926         * s-fatgen.adb: Minor reformatting.
928 2014-08-04  Arnaud Charlet  <charlet@adacore.com>
930         * exp_util.adb (Is_Possibly_Unaligned_Object): Always return
931         False on .NET.
933 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
935         * sem_ch5.adb (Analyze_Loop_Statement): Set properly the kind of
936         the loop parameter for element iterators over containers and
937         arrays, so that improper uses of it are detected in the loop
938         body when expansion is disabled.
939         * exp_ch5.adb (Expand_Iterator_Loop): The entity kind of the
940         generated cursor is that of the analyzed loop parameter.
942 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
944         * exp_ch3.adb (Build_CPP_Init_Procedure): Remove
945         Flag_Decl. Do not analyze the declaration of the flag as it is
946         not part of the tree yet, instead add it to the freeze actions
947         of the C++ type.
949 2014-08-04  Robert Dewar  <dewar@adacore.com>
951         * checks.adb (Apply_Scalar_Range_Check): Make sure we handle
952         case of OUT and IN OUT parameter correctly (where Source_Typ is
953         set), we were missing one case where a check must be applied.
955 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
957         * sem_ch8.adb (Build_Class_Wide_Wrapper): Update the comment on
958         the generated code. Instead of hiding the renaming and using the
959         wrapper as the proper association, have the subprogram renaming
960         alias the wrapper.
961         (Build_Spec): The entity of the wrapper is
962         now derived from the entity of the related primitive.
964 2014-08-04  Emmanuel Briot  <briot@adacore.com>
966         * s-regpat.adb: s-regpat.adb (Parse): fix incorrect link when
967         using non-capturing groups.
969 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
971         * inline.adb (Build_Body_To_Inline): Remove Unmodified and
972         related pragmas before copying the original body, to prevent
973         spurious errors when the pragmas apply to formals that will not
974         appear in the inlined body.
976 2014-08-04  Robert Dewar  <dewar@adacore.com>
978         * exp_prag.adb, sem_ch7.adb, einfo.adb, sem_prag.adb, sem_util.adb,
979         exp_ch3.adb: Minor reformatting.
981 2014-08-04  Robert Dewar  <dewar@adacore.com>
983         * prj-strt.adb, prj-strt.ads, sem_attr.adb: Minor reformatting.
985 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
987         * aspects.adb Add an entry in table Canonical_Aspect for
988         Default_Initial_Condition.
989         * aspects.ads Add an entry in tables Aspect_Id, Aspect_Argument,
990         Aspect_Names and Aspect_Delay for Default_Initial_Condition.
991         * einfo.adb Flag3 is now Has_Default_Init_Cond. Flag132
992         is now Is_Default_Init_Cond_ Procedure. Flag133 is now
993         Has_Inherited_Default_Init_Cond.
994         (Default_Init_Cond_Procedure): New routine.
995         (Has_Default_Init_Cond): New routine.
996         (Has_Inherited_Default_Init_Cond): New routine.
997         (Is_Default_Init_Cond_Procedure): New routine.
998         (Set_Default_Init_Cond_Procedure): New routine.
999         (Set_Has_Default_Init_Cond): New routine.
1000         (Set_Has_Inherited_Default_Init_Cond): New routine.
1001         (Set_Is_Default_Init_Cond_Procedure): New routine.
1002         (Write_Entity_Flags): Output all the new flags.
1003         * einfo.ads New attributes Default_Init_Cond_Procedure,
1004         Has_Inherited_Default_Init_Cond and Is_Default_Init_Cond_Procedure
1005         along with usage in nodes.
1006         (Default_Init_Cond_Procedure): New routine.
1007         (Has_Default_Init_Cond): New routine and pragma Inline.
1008         (Has_Inherited_Default_Init_Cond): New routine and
1009         pragma Inline.
1010         (Is_Default_Init_Cond_Procedure): New routine and
1011         pragma Inline.
1012         (Set_Default_Init_Cond_Procedure): New routine.
1013         (Set_Has_Default_Init_Cond): New routine and pragma Inline.
1014         (Set_Has_Inherited_Default_Init_Cond): New routine and pragma Inline.
1015         (Set_Is_Default_Init_Cond_Procedure): New routine and pragma Inline.
1016         * exp_ch3.adb (Expand_N_Object_Declaration): New constant
1017         Next_N. Generate a call to the default initial condition procedure
1018         if the object's type is subject to the pragma.  (Freeze_Type):
1019         Generate the body of the default initial condition procedure or
1020         inherit the spec from a parent type.
1021         * exp_ch7.adb Add with and use clause for Exp_Prag.
1022         (Expand_Pragma_Initial_Condition): Removed.
1023         * exp_prag.ads, exp_prag.adb (Expand_Pragma_Initial_Condition): New
1024         routine.
1025         * par-prag.adb (Prag): Pragma Default_Initial_Condition does
1026         not need special treatment by the parser.
1027         * sem_ch3.adb (Build_Derived_Record_Type): Propagate the
1028         attributes related to pragma Default_Initial_Condition to the
1029         derived type.
1030         (Process_Full_View): Propagate the attributes
1031         related to pragma Default_Initial_Condition to the full view.
1032         * sem_ch7.adb (Analyze_Package_Specification): Build the
1033         declaration of the default initial condition procedure for all
1034         types that qualify or inherit the one from the parent type.
1035         * sem_ch13.adb (Analyze_Aspect_Specifications):
1036         Add processing for aspect Default_Initial_Condition.
1037         (Check_Aspect_At_Freeze_Point): Aspect
1038         Default_Initial_Condition does not require delayed analysis.
1039         (Replace_Type_References_Generic): Moved to spec.
1040         * sem_ch13.ads (Replace_Type_References_Generic): Moved from body.
1041         * sem_prag.adb Add an entry in table Sif_Glags for
1042         Default_Initial_Condition.
1043         (Analyze_Pragma): Pragma
1044         Default_Initial_Condition is now part of assertion
1045         policy. Add processing for pragma Default_Initial_Condition.
1046         (Is_Valid_Assertion_Kind): Pragma Default_Initial_Condition is
1047         now recognized as a proper assertion policy.
1048         * sem_util.ads, sem_util.adb (Build_Default_Init_Cond_Call): New
1049         routine.
1050         (Build_Default_Init_Cond_Procedure_Body): New routine.
1051         (Build_Default_Init_Cond_Procedure_Declaration): New routine.
1052         (Inherit_Default_Init_Cond_Procedure): New routine.
1053         * snames.ads-tmpl Add new predefined name and pragma id for
1054         Default_Initial_Condition.
1056 2014-08-04  Vincent Celier  <celier@adacore.com>
1058         * prj-dect.adb (Parse_Case_Construction): It is no longer
1059         an error if the variable for a case construction is not
1060         typed, only if the variable value is not a single string. Call
1061         Parse_Choice_List and End_Case_Construction with the new parameter
1062         to indicate that the variable is typed.
1063         * prj-strt.adb (End_Case_Construction): Only check the labels
1064         if the variable is typed.  If the variable is not typed,
1065         issue a warning when there is no "when others" allternative.
1066         (Parse_Choice_List): Manage the labels only if the variable
1067         is typed.
1068         * prj-strt.ads (End_Case_Construction): New Boolean parameter
1069         String_Type.
1070         (Parse_Choice_List): Ditto.
1072 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
1074         * sem_ch5.adb: Additional fix to Check_Predicate_Use.
1076 2014-08-04  Vincent Celier  <celier@adacore.com>
1078         * projects.texi: Update documentation of case constructions with
1079         variables that are not typed.
1081 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
1083         * sem_ch8.adb (Build_Class_Wide_Wrapper): If the operator carries
1084         an Eliminated pragma, indicate that the wrapper is also to be
1085         eliminated, to prevent spurious errors when using gnatelim on
1086         programs that include box-initialization of equality operators
1087         (consequence of AI05-071)..
1089 2014-08-04  Robert Dewar  <dewar@adacore.com>
1091         * checks.adb (Activate_Overflow_Check): Handle floating-point
1092         case correctly.
1093         * checks.ads (Activate_Overflow_Check): Clarify handling of
1094         floating-point cases.
1095         * exp_util.adb (Check_Float_Op_Overflow): Reset Do_Overflow_Check
1096         flag if we generate an explicit overflow check (for
1097         Check_Float_Overflow mode).
1099 2014-08-04  Robert Dewar  <dewar@adacore.com>
1101         * prj-proc.adb, prj-part.adb, prj-strt.adb, prj.adb, prj.ads,
1102         prj-attr.adb, prj-attr.ads: Minor reformatting.
1104 2014-08-04  Yannick Moy  <moy@adacore.com>
1106         * expander.adb (Expand): Always perform special
1107         expansion in GNATprove mode, even when doing pre-analysis.
1109 2014-08-04  Thomas Quinot  <quinot@adacore.com>
1111         * repinfo.adb (List_Scalar_Storage_Order): List bit order if
1112         not default. Also list bit order if SSO is specified. Do not
1113         assume that bit order is always equal to scalar storage order.
1115 2014-08-04  Thomas Quinot  <quinot@adacore.com>
1117         * freeze.adb (Set_SSO_From_Default): Do not set scalar storage
1118         order to reverse SSO for a type that has an explicit native
1119         Bit_Order.
1121 2014-08-04  Doug Rupp  <rupp@adacore.com>
1123         * cal.c: Macro check for VxWorks7.
1124         * init.c (getpid): Likewise.
1125         * mkdir.c (__gnat_mkdir): Likewise.
1126         * sysdep.c (__gnat_is_file_not_found_error): Likewise.
1128 2014-08-04  Gary Dismukes  <dismukes@adacore.com>
1130         * exp_ch3.adb (Expand_N_Object_Declaration): Inhibit generation
1131         of an invariant check in the case where No_Initialization is set,
1132         since the object is uninitialized.
1134 2014-08-04  Thomas Quinot  <quinot@adacore.com>
1136         * snames.ads-tmpl (Default_Scalar_Storage_Order): Now an attribute
1137         name, in addition to a pragma name.
1138         * snames.adb-tmpl (Get_Pragma_Id, Is_Configuration_Pragma_Name,
1139         Is_Pragma_Name): Adjust accordingly.
1140         * sem_attr.ads, sem_attr.adb, exp_attr.adb
1141         (Attribute_Default_Scalar_Storage_Order): Add handling of new
1142         attribute.
1143         * gnat_rm.texi: Document the above.
1145 2014-08-04  Arnaud Charlet  <charlet@adacore.com>
1147         * exp_util.adb (Check_Float_Op_Overflow): No-op in codepeer
1148         mode for now, to revert to previous behavior.
1149         * checks.adb: Revert previous change, no longer needed.
1151 2014-08-04  Robert Dewar  <dewar@adacore.com>
1153         * gnat1drv.adb (Adjust_Global_Switches): Don't set
1154         Check_Float_Overflow if Machine_Oveflows_On_Target is True.
1155         * sem_prag.adb (Analyze_Pragma, case Check_Float_Overflow): Don't
1156         set Check_Float_Overflow if Machine_Oveflows_On_Target is True.
1157         * switch-c.adb (Scan_Front_End_Switches): Don't set
1158         Check_Float_Overflow if Machine_Oveflows_On_Target is True.
1160 2014-08-04  Vincent Celier  <celier@adacore.com>
1162         * prj-attr.adb: Add new default indications for
1163         attributes Object_Dir, Exec_Dir, Source_Dirs and Target.
1164         (Attribute_Default_Of): New function (Initialize): Set the
1165         default for those attributes that have one specified.
1166         * prj-attr.ads (Attribute_Data): New component Default.
1167         * prj-proc.adb (Expression): Take into account the new defaults
1168         for attributes Object_Dir, Exec_Dir and Source_Dirs.
1169         * prj-strt.adb (Attribute_Reference): Set the default for
1170         the attribute.
1171         * prj-tree.ads, prj-tree.adb (Default_Of): New function.
1172         (Set_Default_Of): New procedure.
1173         * prj.adb (The_Dot_String): New global Name_Id variable,
1174         initialized in procedure Initialize.
1175         (Dot_String): New function
1176         (Initialize): Initialize The_Dot_String.
1177         (Reset): Create the string list Shared.Dot_String_List.
1178         * prj.ads (Attribute_Default_Value): New enumeration type.
1179         (Project_Qualifier): Change enumeration value Dry to Abstract_Project.
1180         (Dot_String): New function.
1181         (Shared_Project_Tree_Data): New string list component Dot_String_List.
1182         * projects.texi: Document new defaults for attribute Object_Dir,
1183         Exec_Dir and Source_Dirs.
1185 2014-08-04  Robert Dewar  <dewar@adacore.com>
1187         * sem_ch12.adb: Minor reformatting.
1189 2014-08-04  Arnaud Charlet  <charlet@adacore.com>
1191         * exp_util.adb, checks.adb (Check_Float_Op_Overflow): Add special
1192         expansion in CodePeer_Mode.
1193         (Selected_Range_Checks): Add handling of overflow checks in
1194         CodePeer_Mode.
1196 2014-08-04  Robert Dewar  <dewar@adacore.com>
1198         * exp_attr.adb (Expand_N_Attribute_Reference, case Pred):
1199         Remove special test for Float'First, no longer required.
1200         (Expand_N_Attribute_Reference, case Succ): Remove special test
1201         for Float'First, no longer required.
1202         * s-fatgen.adb (Pred): return infinity unchanged.
1203         (Succ): ditto.
1205 2014-08-04  Claire Dross  <dross@adacore.com>
1207         * sem_ch12.adb (Analyze_Associations): Defaults should only be
1208         used if there is no explicit match.
1209         * exp_util.adb (Get_First_Parent_With_Ext_Axioms_For_Entity):
1210         Also check for pragma external_axiomatization on generic units.
1212 2014-08-04  Robert Dewar  <dewar@adacore.com>
1214         * checks.adb (Activate_Overflow_Check): Remove
1215         Check_Float_Overflow processing.
1216         (Apply_Scalar_Range_Check): Ditto.
1217         (Generate_Range_Check): Ditto.
1218         * exp_ch4.adb (Expand_N_Op_Add): Add call to
1219         Check_Float_Op_Overflow.
1220         (Expand_N_Op_Divide): ditto.
1221         (Expand_N_Op_Multiply): ditto.
1222         (Expand_N_Op_Subtract): ditto.
1223         * exp_util.ads, exp_util.adb (Check_Float_Op_Overflow): New procedure.
1224         * sem_attr.adb (Analyze_Attribute, case Pred): Make sure
1225         Do_Range_Check is set for floating-point case in -gnatc or
1226         GNATprove mode.
1227         (Analyze_Attribute, case Succ): Make sure
1228         Do_Range_Check is set for floating-point case in -gnatc or
1229         GNATprove mode.
1230         * sem_res.adb (Resolve_Type_Conversion): Make sure Do_Range_Check
1231         flag is set for real to integer conversion in GNATprove or
1232         -gnatc mode.
1234 2014-08-04  Gary Dismukes  <dismukes@adacore.com>
1236         * sem_ch13.adb (Analyze_Aspect_Specifications): Resolve
1237         the expression of an Import or Export aspect as type Boolean
1238         and require it to be static. Add ??? comment. Also, set the
1239         Is_Exported flag when appropriate.
1241 2014-08-04  Robert Dewar  <dewar@adacore.com>
1243         * exp_ch4.adb: Minor reformatting.
1244         * exp_attr.adb: Minor reformatting.
1246 2014-08-04  Thomas Quinot  <quinot@adacore.com>
1248         * s-fatgen.ads, s-fatgen.adb (S, P): New visible type declarations
1249         (Unaligned_Valid): Remove now unused subprogram.
1250         * exp_attr.adb (Expand_N_Attribute_Reference, case
1251         Attribute_Valid): If the prefix is in reverse SSO or potentially
1252         unaligned, copy it using a byte copy operation to a temporary
1253         variable.
1254         * einfo.adb: Minor comment fix.
1256 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
1258         * freeze.adb (Freeze_Entity): Do not freeze formal subprograms.
1260 2014-08-04  Robert Dewar  <dewar@adacore.com>
1262         * s-imgrea.adb (Image_Floating_Point): Don't add space before +Inf.
1263         * s-fatgen.adb (Pred): Handle Float'First.
1264         (Succ): Handle Float'Last.
1266 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
1268         * sem_util.adb (Is_Potentially_Unevaluated): If the original
1269         node of a parent node in the tree is a short-circuit operation,
1270         the node is potentially unevaluated.
1272 2014-08-04  Robert Dewar  <dewar@adacore.com>
1274         * sem_res.adb (Resolve_Type_Conversion): Set Do_Range_Check on
1275         conversion from a real type to an integer type.
1277 2014-08-04  Yannick Moy  <moy@adacore.com>
1279         * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, sem_ch7.adb, sem_ch9.adb,
1280         sem_ch12.adb, sem_util.adb, sem_util.ads, sem_res.adb, sem_attr.adb,
1281         exp_ch6.adb, sem_ch4.adb, restrict.adb, restrict.ads, sem_ch6.adb,
1282         sem_ch8.adb, sem_ch11.adb: Update some subprogram names to refer to
1283         SPARK_05 instead of SPARK.
1285 2014-08-04  Robert Dewar  <dewar@adacore.com>
1287         * sem.ads: Minor reformatting.
1288         * sem_ch13.adb (Analyze_Aspect_External_Or_Link_Name): Minor
1289         reformatting.
1290         (Analyze_Aspect_Specifications, case Convention): Put External_Name
1291         before Link_Name when constructing pragma.
1293 2014-08-04  Yannick Moy  <moy@adacore.com>
1295         * sem.adb, sem.ads (In_Default_Expr): Global flag that is set
1296         to True during analysis of a default component expression.
1297         (Semantics): Save and restore In_Default_Expr around analysis.
1298         * sem_ch3.adb, sem_ch3.ads (Analyze_Component_Declaration):
1299         Call new wrapper Preanalyze_Default_Expression.
1300         (Preanalyze_Default_Expression): New wrapper on
1301         Preanalyze_Spec_Expression which sets and restores In_Default_Expr.
1302         * sem_res.adb (Resolve_Call): Mark calls inside default
1303         expressions as not inlined in GNATprove mode.
1305 2014-08-04  Robert Dewar  <dewar@adacore.com>
1307         * exp_ch4.adb: Minor reformatting.
1309 2014-08-04  Olivier Hainque  <hainque@adacore.com>
1311         * link.c: remove const on __gnat_objlist_file_supported for AIX
1313 2014-08-04  Robert Dewar  <dewar@adacore.com>
1315         * sem_util.ads: Minor addition of comment.
1317 2014-08-04  Vincent Celier  <celier@adacore.com>
1319         * prj-dect.adb (Check_Package_Allowed): Allow package IDE in
1320         all projects, including aggregate and aggregate library projects.
1322 2014-08-04  Yannick Moy  <moy@adacore.com>
1324         * back_end.adb (Call_Back_End): Do not call gigi in GNATprove mode.
1326 2014-08-04  Robert Dewar  <dewar@adacore.com>
1328         * sem_eval.adb (Test_In_Range): Always in range for
1329         Is_Known_Valid target type, where input type has smaller or
1330         equal size and does not have biased rep.
1332 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
1334         * sem_attr.adb (Eval_Attribute): Constrained is not treated as
1335         a static attribute, and the Static flag must not be set on it
1336         during resolution. It may be constant-folded during expansion,
1337         but if expansion is disabled it is not a static expression.
1339 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
1341         * sem_ch8.adb (Build_Class_Wide_Wrapper): Mark the primitive as
1342         referenced once resolution has taken place.
1344 2014-08-04  Gary Dismukes  <dismukes@adacore.com>
1346         * exp_ch4.adb (Expand_N_Type_Conversion): Don't
1347         compare access levels in the case where the target type is the
1348         anonymous type of an access discriminant, since the level of
1349         such types is defined based on context. Add comment.
1351 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
1353         * sem_ch8.adb (Build_Class_Wide_Wrapper): Handle various special
1354         cases related to equality.  Remove the special processing
1355         for dispatching abstract subprograms as it is not needed.
1356         (Interpretation_Error): Add a specialized error message for
1357         predefined operators.
1358         (Is_Intrinsic_Equality): New routine.
1359         (Is_Suitable_Candidate): New routine.
1361 2014-08-04  Gary Dismukes  <dismukes@adacore.com>
1363         * checks.adb: Minor comment reformatting.
1365 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
1367         * restrict.adb (Check_Restriction): For checked max_parameter
1368         restrictions reset Violated flag, so that subsequent violations
1369         are properly detected.
1371 2014-08-04  Robert Dewar  <dewar@adacore.com>
1373         * sem_ch3.adb (Check_Initialization): Fix bad test of GNATprove
1374         mode.
1375         (Process_Discriminants): Fix bad test of GNATprove mode
1377 2014-08-04  Hristian Kirtchev  <kirtchev@adacore.com>
1379         * sem_ch12.adb (Instantiate_Formal_Subprogram):
1380         Move variable to their own section. Propagate the source
1381         location of a formal parameter to the corresponding formal of
1382         the subprogram renaming declaration. Code reformatting.
1384 2014-08-04  Arnaud Charlet  <charlet@adacore.com>
1386         * g-trasym-vms-ia64.adb, g-trasym-vms-alpha.adb: Removed.
1388 2014-08-04  Ed Schonberg  <schonberg@adacore.com>
1390         * exp_aggr.adb (Expand_Array_Aggregate): Do not attempt expansion
1391         if error already detected.  We may reach this point in spite of
1392         previous errors when compiling with -gnatq, to force all possible
1393         errors (this is the usual ACATS mode).
1395 2014-08-04  Gary Dismukes  <dismukes@adacore.com>
1397         * checks.adb (Generate_Range_Check): For the case of converting
1398         a base type with a larger range to a smaller target subtype, only
1399         use unchecked conversions of bounds in the range check followed
1400         by conversion in the case where both types are discrete. In other
1401         cases, convert to the target base type and save in a temporary
1402         followed by the range check.
1403         (Convert_And_Check_Range): New procedure factoring code to save
1404         conversion to a temporary followed by a range check (called two
1405         places in Generate_Range_Check).
1406         * exp_ch4.adb (Expand_N_Type_Conversion): Relax previous
1407         check-in, to generate range checks for conversions between
1408         any floating-point types rather than limiting it to matching
1409         base types.
1411 2014-08-02  Trevor Saunders  <tsaunders@mozilla.com>
1413         * gcc-interface/trans.c: Use hash_set instead of pointer_set.
1415 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
1417         * restrict.adb (Update_Restrictions): For restrictions with a
1418         maximum parameter (e.g. number of protected entries in Ravenscar)
1419         do not compute the maximum of the violation over several objects,
1420         because the restriction is per-object.
1421         (Check_Restriction): After possible message, reset the value
1422         of of a checked max_parameter restriction to zero, to prevent
1423         cascaded errors.
1424         * sem_ch3.adb (Build_Derived_Private_Type): Use base of parent
1425         (sub)type to determine whether derived type should be on the
1426         list of private dependents of a type whose full view may become
1427         visible subsequently.
1429 2014-08-01  Olivier Hainque  <hainque@adacore.com>
1431         * gcc-interface/Make-lang.in (ADA_TOOLS_FLAGS_TO_PASS, native): use
1432         $(CXX) instead of ../../xg++ to feed CXX.
1433         (CXX_LFLAGS): Remove. Now unused as the proper flags
1434         are expected to be included in the CXX variable.
1436 2014-08-01  Pierre-Marie Derodat  <derodat@adacore.com>
1438         * gcc-interface/decl.c (elaborate_expression_1): Return the new
1439         variable when debug info is needed and the expression is not
1440         constant.  Tag as external only new variables that are global.
1441         (gnat_to_gnu_entity): Call it after the GNU declaration is saved.
1442         * gcc-interface/trans.c (Attribute_to_gnu): Do not cache
1443         attributes for IN array parameters when their actual subtype
1444         needs debug info.
1445         (Compilation_Unit_to_gnu): Call it to process all remaining nodes.
1446         * gcc-interface/gigi.h (process_deferred_decl_context): New.
1447         * gcc-interface/utils.c (gnat_write_global_declarations): Do not
1448         emit debug info for ignored global declarations.
1449         (struct deferred_decl_context_node,
1450         add_deferred_decl_context, add_deferred_type_context,
1451         compute_deferred_decl_context, defer_or_set_type_context,
1452         deferred_decl_context_queue, get_debug_scope,
1453         get_global_context, process_deferred_decl_context): New.
1454         (gnat_pushdecl): Re-implement the DECL_CONTEXT and TYPE_CONTEXT
1455         computation machinery to rely on the GNAT Scope attribute.
1457 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
1459         * gcc-interface/utils2.c (build_simple_component_ref): Add guard.
1461 2014-08-01  Robert Dewar  <dewar@adacore.com>
1463         * sem_ch8.adb, opt.ads Minor comment updates.
1465 2014-08-01  Hristian Kirtchev  <kirtchev@adacore.com>
1467         * exp_intr.adb (Expand_Unc_Deallocation): Request a renaming
1468         from the side effects removal machinery.
1469         * exp_util.adb (Duplicate_Subexpr): Add formal parameter
1470         Renaming_Req. Update the nested call to Remove_Side_Effects.
1471         (Duplicate_Subexpr_No_Checks): Add formal parameter
1472         Renaming_Req. Update the nested call to Remove_Side_Effects.
1473         (Duplicate_Subexpr_Move_Checks): Add formal parameter
1474         Renaming_Req. Update the nested call to Remove_Side_Effects.
1475         (Remove_Side_Effects): Add formal parameter Renaming_Req. Generate
1476         an object renaming declaration when the caller requests it.
1477         * exp_util.ads (Duplicate_Subexpr): Add formal
1478         parameter Renaming_Req. Update comment on usage.
1479         (Duplicate_Subexpr_No_Checks): Add formal parameter Renaming_Req.
1480         (Duplicate_Subexpr_Move_Checks): Add formal parameter
1481         Renaming_Req.
1483 2014-08-01  Bob Duff  <duff@adacore.com>
1485         * gnat_ugn.texi: Minor updates.
1487 2014-08-01  Robert Dewar  <dewar@adacore.com>
1489         * atree.adb: Minor reformatting.
1491 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
1493         * exp_aggr.adb (Init_Hidden_Discriminants): If some ancestor is a
1494         private extension, get stored constraint, if any, from full view.
1496 2014-08-01  Robert Dewar  <dewar@adacore.com>
1498         * opt.ads (No_Elab_Code_All_Pragma): New global variable.
1499         * sem_ch10.adb (Check_No_Elab_Code_All): New procedure
1500         (Analyze_Compilation_Unit): Call Check_No_Elab_Code_All
1501         (Analyze_Subunit_Context): Call Check_No_Elab_Code_All.
1502         * sem_prag.adb (Analyze_Pragma, case No_Elaboration_Code_All):
1503         Remove code for checking with's, now in sem_ch10.adb, set
1504         Opt.No_Elab_Code_All_Pragma.
1506 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
1508         * sem_ch3.adb (Copy_And_Build): Copy the declaration for
1509         access types as well and adjust the subtype mark if there are
1510         no constraints.
1512 2014-08-01  Robert Dewar  <dewar@adacore.com>
1514         * sem_eval.adb (Test_In_Range): Return Unknown if error posted.
1516 2014-08-01  Robert Dewar  <dewar@adacore.com>
1518         * sem_ch3.adb, einfo.ads, exp_ch4.adb: Code clean ups.
1520 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
1522         * einfo.ads (Has_Private_Ancestor): Remove obsolete usage.
1523         * exp_ch4.adb (Expand_Composite_Equality): Add conversion
1524         of the actuals in the case of untagged record types too.
1525         * sem_ch3.adb (Build_Full_Derivation): New procedure to create the
1526         full derivation of a derived private type, extracted from...
1527         (Copy_And_Build): In the case of record types and most
1528         enumeration types, copy the original declaration.  Build the
1529         full derivation according to the approach extracted from...
1530         (Build_Derived_Private_Type): ...here.  Call Build_Full_Derivation
1531         to create the full derivation in all existing cases and also
1532         create it in the no-discriminants/discriminants case instead of
1533         deriving directly from the full view.
1534         (Is_Visible_Component): Remove obsolete code.
1535         * sem_aggr.adb (Resolve_Record_Aggregate): Likewise.
1537 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
1539         * fe.h (GNAT_Mode): New.
1540         * gcc-interface/decl.c (gnat_to_gnu_entity): Do not error out on
1541         reverse SSO in GNAT mode.
1543 2014-08-01  Thomas Quinot  <quinot@adacore.com>
1545         * freeze.adb: Minor reformatting.
1547 2014-08-01  Thomas Quinot  <quinot@adacore.com>
1549         * exp_ch3.adb (Default_Initialize_Object): Do not generate
1550         default initialization for an imported object.
1552 2014-08-01  Olivier Hainque  <hainque@adacore.com>
1554         * seh_init.c (__gnat_map_SEH): Cast argument of IsBadCodePtr
1555         to the expected FARPROC type instead of void *.
1556         * adaint.c (f2t): Expect __time64_t * as second argument, in line with
1557         other datastructures.
1558         (__gnat_file_time_name_attr): Adjust accordingly.
1559         (__gnat_check_OWNER_ACL): Declare pSD as PSECURITY_DESCRIPTOR,
1560         in line with uses.
1561         (__gnat_check_OWNER_ACL): Declare AccessMode
1562         parameter as ACCESS_MODE instead of DWORD, in line with callers
1563         and uses.
1564         (__gnat_set_executable): Add ATTRIBUTE_UNUSED on mode,
1565         unused on win32.  Correct cast of "args" on call to spawnvp.
1566         (add_handle): Cast realloc calls into their destination types.
1567         (win32_wait): Remove declaration and initialization of unused variable.
1568         (__gnat_locate_exec_on_path): Cast alloca calls
1569         into their destination types.
1570         * initialize.c (append_arg, __gnat_initialize): Cast xmalloc calls into
1571         their destination types.
1573 2014-08-01  Gary Dismukes  <dismukes@adacore.com>
1575         * exp_ch4.adb (Expand_N_Type_Conversion): Expand
1576         range checks for conversions between floating-point subtypes
1577         when the target and source types are the same.
1579 2014-08-01  Robert Dewar  <dewar@adacore.com>
1581         * exp_aggr.adb: Minor reformatting.
1583 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
1585         * sem_ch13.adb (Check_Indexing_Functions): Initialize
1586         Indexing_Found.
1588 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
1590         * gnat1drv.adb (Gnat1drv): In gnatprove mode, we now write the
1591         ALI file before we call the backend (so that gnat2why can append
1592         to it).
1594 2014-08-01  Thomas Quinot  <quinot@adacore.com>
1596         * exp_pakd.adb (Expand_Bit_Packed_Element_Set,
1597         Expand_Packed_Element_Reference): Pass additional Rev_SSO
1598         parameter indicating whether the packed array type has reverse
1599         scalar storage order to the s-pack* Set/Get routines.
1600         * s-pack*.ad* (Get, Set, GetU, SetU): New formal Rev_SSO
1601         indicating reverse scalar storage order.
1603 2014-08-01  Robert Dewar  <dewar@adacore.com>
1605         * sem_ch3.adb (Check_Initialization): Set Do_Range_Check
1606         for initial component value in -gnatc or GNATprove mode.
1607         (Process_Discriminants): Same fix for default discriminant values.
1608         * sem_eval.adb (Test_In_Range): Improve accuracy of results by
1609         checking subtypes.
1611 2014-08-01  Robert Dewar  <dewar@adacore.com>
1613         * sinfo.ads: Minor comment clarification.
1615 2014-08-01  Hristian Kirtchev  <kirtchev@adacore.com>
1617         * sem_ch13.adb (Analyze_Aspect_Specifications): Code
1618         reformatting. Store the generated pragma Import in the related
1619         subprogram as routine Wrap_Imported_Subprogram will need it later.
1620         * sem_prag.adb (Is_Unconstrained_Or_Tagged_Item): An item of
1621         a private type with discriminants is considered to fall in the
1622         category of unconstrained or tagged items.
1624 2014-08-01  Arnaud charlet  <charlet@adacore.com>
1626         * s-os_lib.adb (Open_Append): New functions to open a file for
1627         appending. This binds to the already existing (but not used)
1628         __gnat_open_append.
1629         * osint.ads, osint.adb (Open_File_To_Append_And_Check): New procedure
1630         to open a file for appending.
1631         * osint-c.ads, osint-c.adb (Open_Output_Library_Info): New procedure
1632         to open the ALI file for appending.
1634 2014-08-01  Robert Dewar  <dewar@adacore.com>
1636         * sem_ch8.adb: Minor reformatting.
1638 2014-08-01  Yannick Moy  <moy@adacore.com>
1640         * sem_ch13.adb (Insert_Pragma): Add special case for precondition
1641         pragmas from aspects, which need to be inserted in proper order.
1643 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
1645         * exp_aggr.adb (Expand_Record_Aggregate, Init_Hidden_Discriminants):
1646         Handle properly a type extension that constrains a discriminated
1647         derived type that renames other discriminants of an ancestor.
1649 2014-08-01  Thomas Quinot  <quinot@adacore.com>
1651         * s-pack06.adb, s-pack10.adb, s-pack03.ads, s-pack12.adb, s-pack14.ads,
1652         s-pack25.adb: Fix minor inconsistencies and typos.
1654 2014-08-01  Hristian Kirtchev  <kirtchev@adacore.com>
1656         * sem_ch8.adb (Analyze_Subprogram_Renaming): Alphabetize
1657         globals and move certain variables to the "local
1658         variable" section. Call Build_Class_Wide_Wrapper when
1659         renaming a default actual subprogram with a class-wide actual.
1660         (Build_Class_Wide_Wrapper): New routine.
1661         (Check_Class_Wide_Actual): Removed.
1662         (Find_Renamed_Entity): Code reformatting.
1663         (Has_Class_Wide_Actual): Alphabetize. Change the
1664         logic of the predicate as the renamed name may not necessarely
1665         denote the correct subprogram.
1667 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
1669         * sem_ch7.adb: Fix minor oversight in condition.
1671 2014-08-01  Bob Duff  <duff@adacore.com>
1673         * projects.texi: Minor documentation improvements.
1675 2014-08-01  Robert Dewar  <dewar@adacore.com>
1677         * aspects.ads, aspects.adb: Add aspect No_Elaboration_Code_All.
1678         * gnat_rm.texi: Document No_Elaboration_Code_All pragma and aspect.
1679         * lib-load.adb: Initialize No_Elab_Code_All field.
1680         * lib-writ.adb: Initialize No_Elab_Code_All.
1681         * lib.ads, lib.adb: New field No_Elab_Code_All.
1682         * par-prag.adb: Add dummy entry for pragma No_Elaboration_Code_All.
1683         * restrict.ads, restrict.adb: Restriction No_Elaboration_Code_All no
1684         longer exists.
1685         * sem_ch10.adb (Analyze_Context): Processing for
1686         No_Elaboration_Code_All removed.
1687         (Generate_Parent_References): Moved to Sem_Util.
1688         * sem_prag.adb: Add processing for pragma No_Elaboration_Code_All.
1689         * sem_util.ads, sem_util.adb (Get_Parent_Entity): Moved here from
1690         Sem_Ch10.
1691         * snames.ads-tmpl: Add entry for pragma No_Elaboration_Code_All.
1692         * targparm.adb: Minor comment updates Add comments on ignoring
1693         pragma No_Elaboration_Code_All.
1695 2014-08-01  Nicolas Roche  <roche@adacore.com>
1697         * adaint.c (__gnat_set_close_on_exec): Ensure that
1698         we can unset "close_on_exec" flag.
1700 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
1702         * exp_ch9.adb (Build_Wrapper_Spec, Replicate_Formals): When building
1703         the parameter specs of the wrapper program for a primitive operation
1704         of a synchronized type that implements an interface, copy the
1705         null_exclusion indicator as well.
1707 2014-08-01  Robert Dewar  <dewar@adacore.com>
1709         * sem_eval.ads: Minor reformatting.
1711 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
1713         * exp_ch3.adb (Build_Initialization_Call): Call Underlying_Type
1714         to go down the chain of private derivations.
1715         * freeze.adb (Freeze_Entity): Fix typo in comment.
1717 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
1719         * sem_ch3.adb (Access_Type_Declaration): If designated type is
1720         a limited view, create a master entity (as is already done for
1721         class-wide types) in case the full view designates a type that
1722         contains tasks.
1723         * sem_ch8.adb (Find_Selected_Component): If prefix is a dereference
1724         and the designated type is a limited view, use the non-limited
1725         view if available.
1727 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
1729         * gcc-interface/ada-tree.h (DECL_BY_DESCRIPTOR_P): Delete.
1730         (DECL_FUNCTION_STUB): Likewise.
1731         (SET_DECL_FUNCTION_STUB): Likewise.
1732         (DECL_PARM_ALT_TYPE): Likewise.
1733         (SET_DECL_PARM_ALT_TYPE): Likewise.
1734         (TYPE_VAX_FLOATING_POINT_P): Delete.
1735         (TYPE_DIGITS_VALUE): Likewise.
1736         (SET_TYPE_DIGITS_VALUE): Likewise.
1737         * gcc-interface/gigi.h (standard_datatypes): Remove ADT_malloc32_decl.
1738         (malloc32_decl): Delete.
1739         (build_vms_descriptor): Likewise.
1740         (build_vms_descriptor32): Likewise.
1741         (fill_vms_descriptor): Likewise.
1742         (convert_vms_descriptor): Likewise.
1743         (TARGET_ABI_OPEN_VMS): Likewise.
1744         (TARGET_MALLOC64): Likewise.
1745         * gcc-interface/decl.c (add_parallel_type_for_packed_array): New.
1746         (gnat_to_gnu_entity): Call it to add the original type as a parallel
1747         type to the implementation type of a packed array type.
1748         <E_Procedure>: Remove now obsolete kludge.
1749         <E_Exception>: Delete obsolete comment.
1750         <object>: Small tweak.
1751         <E_Subprogram_Type>: Remove support for stub subprograms, as well as
1752         for the descriptor passing mechanism.
1753         (gnat_to_gnu_param): Likewise.
1754         * gcc-interface/misc.c (gnat_init_gcc_fp): Remove special case.
1755         (gnat_print_type): Adjust.
1756         * gcc-interface/trans.c (gigi): Remove obsolete initializations.
1757         (vms_builtin_establish_handler_decl): Delete.
1758         (gnat_vms_condition_handler_decl): Likewise.
1759         (establish_gnat_vms_condition_handler): Likewise.
1760         (build_function_stub): Likewise.
1761         (Subprogram_Body_to_gnu): Do not call above functions.
1762         (Call_to_gnu): Remove support for the descriptor passing mechanism.
1763         * gcc-interface/utils.c (make_descriptor_field): Delete.
1764         (build_vms_descriptor32): Likewise.
1765         (build_vms_descriptor): Likewise.
1766         (fill_vms_descriptor): Likewise.
1767         (convert_vms_descriptor64): Likewise.
1768         (convert_vms_descriptor32): Likewise.
1769         (convert_vms_descriptor): Likewise.
1770         * gcc-interface/utils.c (unchecked_convert): Likewise.
1771         * gcc-interface/utils2.c (maybe_wrap_malloc): Remove obsolete stuff.
1773 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
1775         * gcc-interface/trans.c (gigi): Use gnat_to_gnu_type for the exception
1776         type and get_unpadded_type for the longest FP type.
1777         (Attribute_to_gnu) <Machine>: Compare the precision of the types.
1778         (convert_with_check): Adjust formatting and remove FIXME.
1780 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
1782         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Signed_Integer_Subtype>:
1783         Do not convert the RM bounds to the base type.
1784         (E_Floating_Point_Subtype): Likewise.
1785         (E_Array_Subtype): Convert the bounds to the base type.
1786         * gcc-interface/trans.c (get_type_length): New function.
1787         (Attribute_to_gnu) <Range_Length>: Call it.
1788         <Length>: Likewise.
1789         (Loop_Statement_to_gnu): Convert the bounds to the base type.
1790         (gnat_to_gnu) <N_In>: Likewise.
1791         * gcc-interface/utils.c (make_type_from_size): Do not convert the RM
1792         bounds to the base type.
1793         (create_range_type): Likewise.
1794         (convert): Convert the bounds to the base type for biased types.
1795         * gcc-interface/utils2.c (compare_arrays): Convert the bounds to the
1796         base type.
1798 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
1800         * gcc-interface/trans.c (gnat_to_gnu) <N_Selected_Component>: Remove
1801         incorrect implicit type derivation.
1802         * gcc-interface/utils.c (max_size) <tcc_reference>: Convert the bounds
1803         to the base type.
1805 2014-08-01  Hristian Kirtchev  <kirtchev@adacore.com>
1807         * sem_attr.adb (Analyze_Attribute): Preanalyze and resolve the
1808         prefix of attribute Loop_Entry.
1809         * sem_prag.adb (Analyze_Pragma): Verify the placement of pragma
1810         Loop_Variant with respect to an enclosing loop (if any).
1811         (Contains_Loop_Entry): Update the parameter profile and all
1812         calls to this routine.
1813         * sem_res.adb (Resolve_Call): Code reformatting. Do not ask
1814         for the corresponding body before determining the nature of the
1815         ultimate alias's declarative node.
1817 2014-08-01  Robert Dewar  <dewar@adacore.com>
1819         * gnat1drv.adb, sem_ch4.adb: Minor reformatting.
1821 2014-08-01  Robert Dewar  <dewar@adacore.com>
1823         * sem_eval.adb (Rewrite_In_Raise_CE): Don't try to reuse inner
1824         constraint error node since it is a list member.
1826 2014-08-01  Robert Dewar  <dewar@adacore.com>
1828         * sem_warn.adb: Minor reformatting.
1830 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
1832         * einfo.adb (Underlying_Type): Return the underlying full view
1833         of a private type if present.
1834         * freeze.adb (Freeze_Entity):
1835         Build a single freeze node for partial, full and underlying full
1836         views, if any.
1837         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Private_Type>: Add a
1838         missing guard before the access to the Underlying_Full_View.
1839         * gcc-interface/trans.c (process_freeze_entity): Deal with underlying
1840         full view if present.
1841         * gcc-interface/utils.c (make_dummy_type): Avoid superfluous work.
1843 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
1845         * sem_res.adb (Resolve_Entry_Call): When an entry has
1846         preconditions, the entry call is wrapped in a procedure call
1847         that incorporates the precondition checks. To prevent a double
1848         expansion, with possible duplication of extra formals, that
1849         procedure call must only be pre-analyzed and resolved. Expansion
1850         takes place upon return to the caller Resolve_Call.
1852 2014-08-01  Hristian Kirtchev  <kirtchev@adacore.com>
1854         * sem_res.adb (Resolve_Call): Do not perform
1855         GNATprove-specific inlining while within a generic.
1857 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
1859         * sem_ch4.adb (Analyze_Case_Expression): Handle properly a
1860         case expression with incompatible alternatives, when the first
1861         alternative is overloaded.
1863 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
1865         * sem_res.adb (Check_Parameterless_Call): Use Relocate_Node
1866         to create the name of the parameterless call, rather than
1867         New_Copy, to preserve the tree structure when the name is a
1868         complex expression, e.g. a selected component that denotes a
1869         protected operation, whose prefix is itself a selected component.
1871 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
1873         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Use
1874         Unit_Declaration_Node to retrieve body when inlining, to handle
1875         properly subprogram child units.
1877 2014-08-01  Robert Dewar  <dewar@adacore.com>
1879         * sem_attr.adb: Minor reformatting.
1881 2014-08-01  Vincent Celier  <celier@adacore.com>
1883         * debug.adb: Minor documentation addition for -dn switch.
1885 2014-08-01  Robert Dewar  <dewar@adacore.com>
1887         * sem_aggr.adb, exp_ch9.adb, sem_prag.adb, sem_util.adb,
1888         sem_attr.adb, sem_eval.ads, sem_cat.adb, sem_ch13.adb: Improve
1889         documentation of Is_Static_Expression vs Is_OK_Static_Expression.
1890         In several places, use the Is_OK version as suggested by the spec.
1892 2014-08-01  Vincent Celier  <celier@adacore.com>
1894         * gnatcmd.adb: Revert last change which was not correct.
1896 2014-08-01  Hristian Kirtchev  <kirtchev@adacore.com>
1898         * freeze.adb (Find_Constant): Ensure that the constant being
1899         inspected is still an object declaration (i.e. not a renaming).
1901 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
1903         * sem_ch5.adb (Analyze_Loop_Parameter_Specification): a)
1904         An attribute_reference to Loop_Entry denotes an iterator
1905         specification: its prefix is an object, as is the case for 'Old.
1906         b) If the domain of iteration is an expression whose type has
1907         the Iterable aspect defined, this is an iterator specification.
1909 2014-08-01  Robert Dewar  <dewar@adacore.com>
1911         * gnatcmd.adb: Minor reformatting.
1913 2014-08-01  Robert Dewar  <dewar@adacore.com>
1915         * atree.ads (Info_Messages): New counter.
1916         * err_vars.ads: Minor comment update.
1917         * errout.adb (Delete_Warning_And_Continuations): Deal
1918         with new Info_Messages counter.
1919         (Error_Msg_Internal): ditto.
1920         (Delete_Warning): ditto.
1921         (Initialize): ditto.
1922         (Write_Error_Summary): ditto.
1923         (Output_Messages): ditto.
1924         (To_Be_Removed): ditto.
1925         * erroutc.adb (Delete_Msg): Deal with Info_Messages counter.
1926         (Compilation_Errors): ditto.
1927         * errutil.adb (Error_Msg): Deal with Info_Messages counter.
1928         (Finalize): ditto.
1929         (Initialize): ditto.
1930         * sem_prag.adb (Analyze_Pragma): Minor comment addition.
1931         * gnat_ugn.texi: Document that -gnatwe does not affect info
1932         messages.
1934 2014-08-01  Robert Dewar  <dewar@adacore.com>
1936         * debug.adb: Document debug switch -gnatd.Z.
1937         * sem.adb (Semantics): Force expansion on in no or configurable
1938         run time mode.
1940 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
1942         * sem_ch5.adb (Analyze_Loop_Parameter_Specification): An
1943         unchecked conversion denotes an iterator specification. Such a
1944         conversion will be inserted in the context of an inlined call
1945         when needed, and its argument is always an object.
1947 2014-08-01  Robert Dewar  <dewar@adacore.com>
1949         * make.adb, makeutl.ads: Minor reformatting.
1950         * debug.adb, opt.ads: Clarify documentation of Front_End_Inlining and
1951         Back_End_Inlining.
1953 2014-08-01  Tristan Gingold  <gingold@adacore.com>
1955         * gnatcmd.adb (GNATCmd): Set AAMP_On_Target using command name.
1957 2014-08-01  Javier Miranda  <miranda@adacore.com>
1959         * gnat1drv.adb (Adjust_Global_Switches): Reverse meaning of
1960         -gnatd.z.
1961         * debug.adb: Updating documentation.
1962         * exp_ch6.adb (Expand_Call): Remove assertion.
1964 2014-08-01  Robert Dewar  <dewar@adacore.com>
1966         * sem_aggr.adb, sem_ch3.adb, sem_ch5.adb, sem_util.adb,
1967         sem_res.adb: Minor reformatting.
1969 2014-08-01  Vincent Celier  <celier@adacore.com>
1971         * make.adb (Initialize): Set Keep_Temporary_Files to True when
1972         -dn is specified.
1973         * makeusg.adb: Add line for new switch --keep-temp-files.
1974         * makeutl.ads (Keep_Temp_Files_Option): New constant String.
1975         * opt.ads (Keep_Temporary_Files): Document that it is also used
1976         by gnatmake and gprbuild.
1977         * switch-m.adb: Recognize new switch --keep-temp-files.
1979 2014-08-01  Tristan Gingold  <gingold@adacore.com>
1981         * sem_ch9.adb (Analyze_Task_Type_Declaration): Move code from ...
1982         * exp_ch9.adb (Make_Task_Create_Call): ... here.
1984 2014-08-01  Vincent Celier  <celier@adacore.com>
1986         * gnat1drv.adb: Do not try to get the target parameters when
1987         invoked with -gnats.
1989 2014-08-01  Hristian Kirtchev  <kirtchev@adacore.com>
1991         * exp_ch7.adb (Find_Last_Init): Nothing to do for an object
1992         declaration subject to No_Initialization.
1994 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
1996         * sem_aggr.adb (Resolve_Array_Aggregate): Reject choice that
1997         is a subtype with dynamic predicates, or a non-static subtype
1998         with predicates.
1999         * sem_ch3.adb (Analyze_Number_Declaration): Reject qualified
2000         expression if subtype has a dynamic predicate.
2001         (Constrain_Index): Reject subtype indication if subtype mark
2002         has predicates.
2003         (Inerit_Predicate_Flags): Inherit Has_Predicates as well.
2004         (Make_Index): If index is a subtype indication, itype inhereits
2005         predicate flags for subsequent testing.
2006         * sem_ch5.adb (Analyze_Loop_Parameter_Specification): New
2007         procedure Check_Predicate_Use, to reject illegal uses of domains
2008         of iteration that have dynamic predicates.
2009         * sem_res.adb (Resolve_Slice): Reject slices given by a subtype
2010         indication to which a predicate applies.
2011         * sem_util.adb (Bad_Predicated_Subtype_Use): Add guard to
2012         prevent cascaded errors when subtype is invalid.
2014 2014-08-01  Robert Dewar  <dewar@adacore.com>
2016         * sem_ch10.adb: Minor reformatting.
2018 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
2020         * sem_ch6.adb (Same_Generic_Actual): Make function symmetric,
2021         because either type may be a subtype of the other.
2023 2014-08-01  Vincent Celier  <celier@adacore.com>
2025         * makeusg.adb: Add documentation for debug switch -dn.
2027 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
2029         * sem_dim.adb (Process_Minus, Process_Divide): Label dimension
2030         expression with standard operator and type, for pretty-printing
2031         use, when in ASIS_Mode. When generating code dimensional analysis
2032         is not involved and dimension expressions are handled statically,
2033         and other operators are resolved in the usual way.
2035 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
2037         * sem_ch3.adb (Build_Derived_Record_Type): Remove setting of
2038         Parent_Subtype in ASIS mode, leads to several failures.
2039         * sem_ch4.adb (Analyze_Selected_Component): In an instance,
2040         if the prefix is a type extension, check whether component is
2041         declared in the parent type, possibly in a parent unit. Needed
2042         in ASIS mode when Parent_Subtype is not set.
2044 2014-08-01  Robert Dewar  <dewar@adacore.com>
2046         * sem_prag.adb: Minor reformatting.
2047         * s-regpat.adb: Minor reformatting.
2048         * sem_ch3.adb (Analyze_Object_Declaration): Do not set
2049         Treat_As_Volatile on constants.
2051 2014-08-01  Tristan Gingold  <gingold@adacore.com>
2053         * exp_ch9.adb (Make_Task_Create_Call): Improve error message.
2055 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
2057         * sem_ch10.adb (Analyze_Compilation_Unit): Do not place a
2058         warning on a with_clause created for the renaming of a parent
2059         unit in an explicit with_clause.
2061 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
2063         * sem_ch13.adb (Analyze_Aspect_Specifications, case Aspect_Import):
2064         Set Is_Imported flag at once, to simplify subsequent legality
2065         checks. Reject the aspect on an object whose declaration has an
2066         explicit initial value.
2067         * sem_prag.adb (Process_Import_Or_Interface): Use original node
2068         to check legality of an initial value for an imported entity.
2069         Set Is_Imported flag in case of error to prevent cascaded errors.
2070         Do not set the Is_Imported flag if the pragma comes from an
2071         aspect, because it is already done when analyzing the aspect.
2073 2014-08-01  Emmanuel Briot  <briot@adacore.com>
2075         * g-regpat.adb (Parse): Add support for non-capturing parenthesis.
2077 2014-08-01  Robert Dewar  <dewar@adacore.com>
2079         * sem_ch7.adb, einfo.adb, einfo.ads, sem_ch13.adb: Minor change of
2080         identifier name.
2082 2014-08-01  Hristian Kirtchev  <kirtchev@adacore.com>
2084         * sem_ch3.adb (Analyze_Object_Contract): Enable the volatility
2085         checks when the related variable comes from source.
2086         * sem_res.adb (Resolve_Actuals): Enable the volatility checks
2087         when the related actual parameter comes from source. Update comment.
2088         * freeze.adb (Freeze_Record_Type): Do not freeze the designated
2089         type of an array of pointers when the designated type is
2090         class-wide and its root type is the record being currently frozen.
2092 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
2094         * sem_ch5.adb (Analyze_Iterator_Specification): Preserve Ekind
2095         of renaming declaration created for domain of iteration.
2096         * sem_aggr.adb (Resolve_Array_Aggregate): Better placement
2097         for error messages on aggregates whose index subtypes have
2098         predicates. The new placement avoids posting messages on previous
2099         subtype declarations rather than on the aggregate itself.
2100         * sem_disp.adb (Is_Inherited_Public_Operation): New predicate for
2101         Add_Dispatching_Operation, to handle properly the overriding of
2102         the predefined operations on controlled types, when the partial
2103         view of a type is not visibly controlled.
2105 2014-08-01  Ben Brosgol  <brosgol@adacore.com>
2107         * gnat_ugn.texi: Add tutorial on portable fixed-point types as an
2108         appendix.
2110 2014-08-01  Hristian Kirtchev  <kirtchev@adacore.com>
2112         * einfo.adb (Is_Hidden_Non_Overridden_Subprogram): Remove the
2113         assertion check as the attribute is defined for all entities.
2114         (Set_Is_Hidden_Non_Overridden_Subprogram): Remove the assertion
2115         check as the attribute is defined for all entities.
2116         * einfo.ads Update the documentation of attribute
2117         Is_Hidden_Non_Overridden_Subprogram.
2118         * sem_ch7.adb (Install_Package_Entity): No need to check the
2119         entity kind of the Id.
2120         * sem_ch13.adb (Hide_Matching_Homograph): Update the comment on
2121         usage. Ensure that the homographs are of the same entity kind
2122         and not fully conformant.
2123         (Hide_Non_Overridden_Subprograms): Update the comment on usage.
2125 2014-08-01  Robert Dewar  <dewar@adacore.com>
2127         * inline.adb: Minor code reorganization.
2128         * sem_ch12.adb, s-tasdeb.ads: Minor reformatting.
2130 2014-08-01  Robert Dewar  <dewar@adacore.com>
2132         * inline.adb, s-os_lib.ads: Minor reformatting.
2134 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
2136         * s-tasdeb.ads, s-tasdeb.adb (Master_Hook, Master_Completed_Hook): New.
2137         * s-tassta.adb (Task_Wrapper, Vulnerable_Complete_Master): Call new
2138         hooks.
2140 2014-08-01  Yannick Moy  <moy@adacore.com>
2142         * inline.adb (Cannot_Inline): Issue info message instead of
2143         warning for subprograms not inlined in GNATprove mode.
2144         * sem_res.adb (Resolve_Call): Take body into account for deciding
2145         whether subprogram can be inlined in GNATprove mode or not.
2147 2014-08-01  Claire Dross  <dross@adacore.com>
2149         * exp_util.ads (Get_First_Parent_With_Ext_Axioms_For_Entity): Renaming
2150         of Get_First_Parent_With_External_Axiomatization_For_Entity for
2151         shorter.
2152         * sem_ch12.adb (Analyze_Associations): Only call Build_Wrapper
2153         for parameters of packages with external axiomatization.
2155 2014-08-01  Robert Dewar  <dewar@adacore.com>
2157         * sem_res.adb: Minor comment addition.
2159 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
2161         * s-crtl.ads, i-cstrea.ads, adaint.c, adaint.h, osint.adb,
2162         s-fileio.adb (__gnat_fopen, __gnat_freopen): Remove vms_form parameter,
2163         no longer used.
2164         * s-os_lib.ads: Minor reformatting.
2166 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
2168         * exp_attr.adb (Is_Inline_Floating_Point_Attribute): Restore more
2169         completely previous code since only GCC back-ends are prepared
2170         to handle e.g. 'Machine attribute.
2171         * targparm.adb, targparm.ads: Remove remaining refs and
2172         handling of OpenVMS_On_Target, VAX_Float_On_Target and
2173         RTX_RTSS_Kernel_Module_On_Target.
2174         * hostparm.ads (OpenVMS, Max_Debug_Name_Length): Removed,
2175         no longer used.
2177 2014-08-01  Robert Dewar  <dewar@adacore.com>
2179         * exp_dist.adb, exp_attr.adb: Minor reformatting.
2180         * sem_ch3.adb, mlib-tgt-specific-hpux.adb, a-direct.ads,
2181         a-synbar-posix.adb, exp_ch9.adb, sem_ch10.adb, sem_prag.adb,
2182         sem_ch12.adb, sem.ads, sem_res.adb, s-exctra.adb, s-soflin.ads,
2183         g-alveop.ads, sem_ch8.adb, vxaddr2line.adb, sem_cat.ads: Remove
2184         improper use of shall.
2186 2014-08-01  Robert Dewar  <dewar@adacore.com>
2188         * sem_aggr.adb, exp_atag.adb, layout.adb, nlists.adb, nlists.ads,
2189         exp_attr.adb, exp_ch9.adb, par-ch12.adb, exp_aggr.adb,
2190         exp_ch3.adb: Minor reformatting & code reorganization.
2192 2014-08-01  Robert Dewar  <dewar@adacore.com>
2194         * gnat_rm.texi: Remove VMS specific rules for pragma Ident.
2195         * Makefile.rtl, adaint.c, gnat_rm.texi, s-asthan.adb, s-asthan.ads,
2196         s-filofl.ads, s-fishfl.ads, s-fvadfl.ads, s-fvaffl.ads, s-fvagfl.ads,
2197         s-po32gl.adb, s-po32gl.ads, s-vaflop.adb, s-vaflop.ads, s-vmexta.adb,
2198         s-vmexta.ads, sem_vfpt.adb, sem_vfpt.ads, socket.c: Remove VMS specific
2199         code.
2200         * gcc-interface/decl.c, gcc-interface/Makefile.in,
2201         gcc-interface/Make-lang.in: Ditto. Also remove refs to rTX.
2203 2014-08-01  Pascal Obry  <obry@adacore.com>
2205         * s-os_lib.ads: Rename File_Size to Large_File_Size.
2207 2014-08-01  Robert Dewar  <dewar@adacore.com>
2209         * a-numaux-vxworks.ads, a-numaux-x86.adb, a-numaux-x86.ads,
2210         a-numaux-darwin.adb, a-numaux-darwin.ads, a-numaux.ads,
2211         a-numaux-libc-x86.ads: Fix bad package header comments.
2212         * elists.ads, elists.adb (Append_New_Elmt): New procedure.
2213         * gnat_rm.texi, a-calend.adb, gnatcmd.adb, einfo.adb, einfo.ads,
2214         checks.adb, sem_prag.adb, sem_prag.ads, rtsfind.ads, freeze.adb,
2215         sem_util.adb, sem_attr.adb, exp_dbug.adb, exp_dbug.ads, gnat1drv.adb,
2216         targparm.adb, targparm.ads, exp_ch6.adb, switch-b.adb, s-shasto.ads,
2217         stand.ads, s-auxdec.ads, opt.adb, opt.ads, mlib-tgt.ads, s-fatgen.adb,
2218         s-fatgen.ads, system.ads, snames.ads-tmpl, s-stalib.ads,
2219         s-os_lib.adb: Remove VMS-specific code.
2221 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
2223         * exp_attr.adb (Is_Inline_Floating_Point_Attribute): Revert to
2224         previous state in CodePeer_Mode.
2226 2014-08-01  Robert Dewar  <dewar@adacore.com>
2228         * hostparm.ads: Put back definition of OpenVMS as False to aid
2229         the transition process.
2230         * sem_ch7.adb: Minor reformatting.
2231         * prj-env.adb: Minor code fix.
2232         * gnat_rm.texi: Complete previous change.
2233         * sem_ch3.adb: Minor reformatting.
2234         * sem_ch6.adb: Minor reformatting.
2235         * sem_elab.adb: Minor reformatting.
2236         * exp_strm.adb: Complete previous change.
2238 2014-08-01  Vincent Celier  <celier@adacore.com>
2240         * sem_warn.adb (Warn_On_Unreferenced_Entity): Do not issue a
2241         warning when a constant is unreferenced and its type has pragma
2242         Unreferenced_Objects.
2244 2014-08-01  Hristian Kirtchev  <kirtchev@adacore.com>
2246         * einfo.adb: Flag2 is now known as
2247         Is_Hidden_Non_Overridden_Subprogram.
2248         (Is_Hidden_Non_Overridden_Subprogram): New routine.
2249         (Set_Is_Hidden_Non_Overridden_Subprogram): New routine.
2250         (Write_Entity_Fields): Output Flag2.
2251         * einfo.ads: New attribute Is_Hidden_Non_Overridden_Subprogram
2252         along with occurrences in entities.
2253         (Is_Hidden_Non_Overridden_Subprogram): New routine and pragma Inline.
2254         (Set_Is_Hidden_Non_Overridden_Subprogram): New routine
2255         and pragma Inline.
2256         * sem_ch7.adb (Install_Package_Entity): Do not enter implicitly
2257         declared non-overriden homographs into visibility.
2258         * sem_ch13.adb (Freeze_Entity_Checks): Hide all
2259         implicitly declared non-overriden homographs.
2260         (Hide_Non_Overridden_Subprograms): New routine.
2262 2014-08-01  Robert Dewar  <dewar@adacore.com>
2264         * snames.ads-tmpl, s-os_lib.adb, s-os_lib.ads, s-fileio.adb: Remove
2265         VMS-specific code.
2266         * prj-conf.adb: Minor reformatting.
2267         * xr_tabls.adb (Read_File): Restore code which was enabled on
2268         non VMS platforms before.
2269         * prj-env.adb (Initialize_Default_Project_Path): Ditto.
2270         * sem_ch5.adb: Minor reformatting.
2271         * lib-writ.adb, lib-writ.ads, bindgen.adb, sem_vfpt.adb,
2272         sem_vfpt.ads, ali.adb, ali.ads, opt.ads, bcheck.adb, exp_strm.adb:
2273         Remove VMS-specific code.
2275 2014-08-01  Vincent Celier  <celier@adacore.com>
2277         * make.adb (Await_Compile): Remove loop that was only needed
2278         for VMS.
2280 2014-08-01  Robert Dewar  <dewar@adacore.com>
2282         * a-calcon.ads, a-direct.adb, a-dirval-mingw.adb, a-dirval.adb,
2283         a-dirval.ads, a-except-2005.adb, a-excpol-abort.adb,
2284         a-numaux-darwin.ads, a-numaux.ads, bindgen.adb, bindusg.adb,
2285         einfo.adb, einfo.ads, err_vars.ads, errout.ads, errutil.adb,
2286         exp_ch3.adb, exp_ch4.adb, exp_ch7.adb, exp_ch7.ads, fname-uf.adb,
2287         fname.adb, fname.ads, freeze.adb, g-debpoo.adb, g-dirope.ads,
2288         g-excact.ads, g-expect.ads, g-socket.adb, g-socket.ads, g-sothco.ads,
2289         g-traceb.ads, gnat_rm.texi, gnatlink.adb, gnatls.adb, i-cstrea.adb,
2290         krunch.adb, krunch.ads, layout.adb, lib-util.adb, make.adb,
2291         mlib.adb, osint-b.adb, osint-b.ads, osint-c.adb, osint.adb,
2292         osint.ads, output.ads, par.adb, prj-conf.adb, prj-env.adb,
2293         prj-makr.adb, prj-nmsc.adb, prj.adb, prj.ads, repinfo.adb, rtsfind.adb,
2294         rtsfind.ads, s-excmac-gcc.ads, s-fatgen.adb, s-mastop.ads,
2295         s-parame-ae653.ads, s-parame-hpux.ads, s-parame-vxworks.ads,
2296         s-parame.ads, s-soflin.ads, s-stoele.adb, s-tasini.adb,
2297         s-taspri-dummy.ads, s-taspri-hpux-dce.ads, s-taspri-mingw.ads,
2298         s-taspri-posix-noaltstack.ads, s-taspri-posix.ads,
2299         s-taspri-solaris.ads, s-taspri-vxworks.ads, s-trasym.ads,
2300         sem_ch12.adb, sem_ch4.adb, sem_eval.adb, sem_intr.adb, sem_mech.adb,
2301         sem_mech.ads, sem_prag.adb, sem_res.adb, sem_util.adb, sem_util.ads,
2302         sinfo.adb, sinfo.ads, sinput-c.adb, symbols.ads, targparm.adb,
2303         treepr.adb, types.ads, xr_tabls.adb, xr_tabls.ads: Remove VMS
2304         specific code and comments.
2306 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
2308         * sem_ch5.adb (Analyze_Iterator_Specification): New procedure
2309         Check_Reverse_Iteration, to verify the legality of the Reverse
2310         indicator on various container types, and to detect illegal
2311         reverse iterations on containers that only supoort forward
2312         iteration.
2314 2014-08-01  Vincent Celier  <celier@adacore.com>
2316         * gnatcmd.adb: Remove the VMS specific stuff.  Integrate in
2317         procedure GNATCmd the relevant declarations from packages VMS_Cmds
2318         and VMS_Conv.
2319         * gnatcmd.ads: Update comments to remove any trace of VMS
2321 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
2323         * sem_ch12.adb: sem_ch12.adb (Build_Wrapper): Capture entity for
2324         defaulted actual that is an operator, before building wrapper
2325         for it in GNATprove mode. Restrict construction of wrapper to
2326         actuals that are operators.
2328 2014-08-01  Vincent Celier  <celier@adacore.com>
2330         * vms_conv.adb, vms_conv.ads, vms_data.ads, vms_cmds.ads: Remove VMS
2331         specific packages no longer needed.
2333 2014-08-01  Pascal Obry  <obry@adacore.com>
2335         * s-os_lib.ads (System.CRTL): Move with clause to body.
2336         (File_Size): New type.
2337         (File_Length64): Use it.
2338         (File_Length): Restore previous spec returning a Long_Integer.
2339         * s-os_lib.adb (System.CRTL): Move with clause here.
2341 2014-08-01  Vincent Celier  <celier@adacore.com>
2343         * mlib-prj.adb: Update comments to remove any mention of VMS.
2345 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
2347         * ug_words, xgnatugn.adb, gcc-interface/Make-lang.in: Remove
2348         xgnatugn.adb and ug_words.
2350 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
2352         * exp_attr.adb (Expand_N_Attribute_Reference): Check whether
2353         expansion can be avoid for Machine, Model and Rounding.
2354         (Is_Inline_Floating_Point_Attribute): Return true for Machine
2355         & Model, as well as Rounding if wrapped in a conversion to an
2356         integer type.
2357         * sem_res.adb (Simplify_Type_Conversion): Deal with Rounding as well.
2358         * gcc-interface/gigi.h (fp_arith_may_widen): Declare.
2359         * gcc-interface/utils.c (fp_arith_may_widen): New global variable.
2360         * gcc-interface/misc.c (enumerate_modes): Compute it.
2361         * gcc-interface/trans.c (FP_ARITH_MAY_WIDEN): Delete.
2362         (lvalue_required_for_attribute_p): Deal with Descriptor_Size,
2363         Machine and Model.
2364         (Attribute_to_gnu) <Attr_Model>: New case.
2365         <Attr_Machine>): Likewise.
2366         (convert_with_check): Test
2367         fp_arith_may_widen variable.
2369 2014-08-01  Pascal Obry  <obry@adacore.com>
2371         * adaint.h (GNAT_FOPEN): New definition for Windows.
2372         (GNAT_OPEN): Likewise.
2373         (GNAT_STAT): Likewise.
2374         (GNAT_FSTAT): Likewise.
2375         (GNAT_LSTAT): Likewise.
2376         (GNAT_STRUCT_STAT): Likewise.
2377         * adaint.c (__gnat_stat): Fix computation of file size for
2378         Windows.
2380 2014-08-01  Vincent Celier  <celier@adacore.com>
2382         * Makefile.rtl: Minor comment update.
2384 2014-08-01  Vincent Celier  <celier@adacore.com>
2386         * Make-generated.in: Remove dependencies for vms-help.
2388 2014-08-01  Gary Dismukes  <dismukes@adacore.com>
2390         * makeutl.ads, opt.ads: Minor grammar fixes.
2391         * makeutl.adb: Minor code reorganization.
2393 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
2395         * gcc-interface/Makefile.in, gcc-interface/Make-lang.in,
2396         gnatsym.adb: Remove gnatsym (VMS only tool).
2398 2014-08-01  Ben Brosgol  <brosgol@adacore.com>
2400         * gnat_ugn.texi, projects.texi, xgnatugn.adb: Removed all VMS
2401         conditionalization from gnat_ugn.texi and projects.texi, and updated
2402         (considerably simplified) xgnatugn.adb, to be removed soon.
2404 2014-08-01  Vincent Celier  <celier@adacore.com>
2406         * debug.adb: Remove doc for gnatmake/gprbuild switch -ds.
2407         * make.adb (List_Bad_Compilations): Use Opt.No_Exit_Message
2408         instead of Debug.Debug_Flag_S.
2409         * makeutl.adb (Finish_Program, Fail_Program): Use Opt flag
2410         No_Exit_Message instead of Debug.Debug_Flag_S to suppress exit
2411         error messages.
2412         * makeutl.ads (No_Exit_Message_Option): New constant string
2413         for switch --no-exit-message.
2414         * opt.ads (No_Exit_Message): New Boolean flag, defaulted to False.
2415         * switch-m.adb (Scan_Make_Switches): Recognize new switch
2416         --no-exit-message.
2418 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
2420         * exp_vfpt.adb, exp_vfpt.ads: Removed, no longer used.
2421         * gcc-interface/Make-lang.in: Remove exp_vfpt.o
2423 2014-08-01  Javier Miranda  <miranda@adacore.com>
2425         * inline.ads (Inlined_Calls, Backend_Calls,
2426         Backend_Inlined_Subps, Backend_Not_Inlined_Subps): Declarations
2427         moved to inline.adb (Cannot_Inline): Update documentation.
2428         (Check_And_Build_Body_To_Inline): Renamed.
2429         (List_Inlining_Info): Subprogram moved here from package exp_ch6.
2430         * inline.adb (Check_Inlining_Restrictions): New local variable.
2431         (Inlined_Calls, Backend_Calls, Backend_Inlined_Subps,
2432         Backend_Not_Inlined_Subps): Declarations moved here
2433         from inline.ads (Number_Of_Statements): Removed.
2434         (Remove_Pragmas): Avoid duplicated version of this subprogram.
2435         (Build_Body_To_Inline): Code cleanup.
2436         (Build_Body_To_Inline.Has_Excluded_Statament): Removed.
2437         (Check_And_Build_Body_To_Inline): Renamed. Code cleanup.
2438         (Check_Body_To_Inline): Removed.
2439         (Generate_Body_To_Inline): Renamed as Generate_Subprogram_Body.
2440         (Has_Excluded_Declaration): No action if not
2441         Check_Inlining_Restrictions.
2442         (Has_Excluded_Statement): No action if not Check_Inlining_Restrictions.
2443         (Initialize): Initialize the lists of inlined calls and subprograms.
2444         (List_Inlining_Info): Subprogram moved here from package exp_ch6.
2445         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Update call
2446         to Check_And_Build_Body_To_Inline since it has been renamed as
2447         Check_And_Split_Unconstrained_Function
2448         * exp_ch6.ad[sb] (List_Inlining_Info): Subprogram moved to
2449         package inline.
2450         * gnat1drv.adb Update call to Inline.List_Inlining_Info.
2452 2014-08-01  Vincent Celier  <celier@adacore.com>
2454         * debug.adb: Add documentation for new debug switch -ds.
2455         * make.adb (List_Bad_Compilations): Do not issue any message
2456         when switch -ds is specified.
2457         * makeutl.adb (Fail_Program): Do not issue any message when
2458         -ds is specified.
2459         (Finish_Program): Ditto.
2461 2014-08-01  Robert Dewar  <dewar@adacore.com>
2463         * s-exnint.adb, s-exnint.ads, s-wwdwch.ads, s-carsi8.ads,
2464         s-casi32.ads, indepsw.adb, a-timoau.ads, s-explli.adb, s-explli.ads,
2465         s-casi16.ads, s-powtab.ads, g-wistsp.ads, a-ztmoau.adb,
2466         indepsw-gnu.adb, s-imgllb.ads, types.adb, gnat.ads, s-proinf.adb,
2467         indepsw-aix.adb, s-caun64.ads, s-imgllw.ads, s-traces-default.adb,
2468         s-vxwork-x86.ads, s-expllu.adb, s-exnlli.adb, s-exnlli.ads,
2469         s-traces.adb, widechar.ads, stand.adb, s-expint.adb,
2470         s-tratas-default.adb, s-expint.ads, s-geveop.ads, s-caun32.ads,
2471         s-expuns.adb, s-mantis.adb, s-mantis.ads, s-caun16.ads, s-tasinf.adb,
2472         s-memcop.ads, s-dsaser.ads, s-imgbiu.ads, a-szmzco.ads, g-strspl.ads,
2473         s-casi64.ads, g-zstspl.ads, indepsw-mingw.adb, tree_io.adb,
2474         s-boarop.ads, uname.ads, s-fore.adb, s-fore.ads, g-timsta.adb,
2475         g-timsta.ads, s-assert.adb, s-vector.ads, s-tratas.adb,
2476         s-tratas.ads: Minor fix to copyright notices.
2478 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
2480         * sinfo.ads: Remove long obsolete comment.
2481 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
2483         * sem_util.adb: Add guard to setting of No_Predicate_On_Actual.
2484         * sem_ch3.adb: Minor reformatting.
2486 2014-08-01  Pascal Obry  <obry@adacore.com>
2488         * cstreams.c: Only enable large file support on know supported
2489         platforms. Add missing defines/includes.
2491 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
2493         * einfo.ads, einfo.adb New flags No_Predicate_On_Actual and
2494         No_Dynamic_Predicate_On_Actual, to enforce the generic contract
2495         on generic units that contain constructs that forbid subtypes
2496         with predicates.
2497         * sem_ch3.adb (Analyze_Subtype_Declaration, Process_Subtype):
2498         Inherit flags indicating the presence of predicates in subtype
2499         declarations with and without constraints.
2500         (Inherit_Predicate_Flags): Utility for the above.
2501         * sem_util.adb (Bad_Predicated_Subtype_Use): In a generic context,
2502         indicate that the actual cannot have predicates, and preserve
2503         warning. In an instance, report error if actual has predicates
2504         and the construct appears in a package declaration.
2505         * sem_ch12.adb (Diagnose_Predicated_Actual): Report error
2506         for an actual with predicates, if the corresponding formal
2507         carries No_Predicate_On_Actual or (in the case of a loop)
2508         No_Dynamic_Predicate_On_Actual.
2509         * sem_ch13.adb (Build_Predicate_Functions); Do not build a
2510         Static_Predicate function if the type is non-static (in the
2511         presence of previous errors),
2512         * sem_ch5.adb (Analyze_Loop_Parameter_Specification): Set flag
2513         No_Dynamic_Predicate_On_Actual in a generic context, to enforce
2514         generic contract on actuals that cannot have predicates.
2516 2014-08-01  Pascal Obry  <obry@adacore.com>
2518         * a-direct.adb (C_Size): Returns an int64.
2519         * osint.adb (System.CRTL): New with clause.
2520         (File_Length.Internal): Returns an int64.
2521         * s-os_lib.ads (File_Length): Returns an int64.
2523 2014-08-01  Robert Dewar  <dewar@adacore.com>
2525         * gnatchop.adb, gnatcmd.adb, make.adb, mlib-prj.adb, bindgen.adb,
2526         mlib.ads, butil.adb, clean.adb, binde.adb, gnatls.adb, gnatname.adb,
2527         osint.adb, krunch.adb: Minor reformatting.
2529 2014-08-01  Robert Dewar  <dewar@adacore.com>
2531         * inline.adb, inline.ads, fe.h, einfo.adb, einfo.ads, sem_util.adb,
2532         sem_util.ads, exp_ch4.adb, exp_ch11.adb, exp_ch6.adb, cstand.adb,
2533         sem_mech.adb, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb, snames.ads-tmpl:
2534         Remove VMS-specific code.
2535         * gcc-interface/decl.c, gcc-interface/trans.c: Ditto.
2537 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
2539         * binde.adb, bindgen.adb, butil.adb, clean.adb, gnatbind.adb,
2540         gnatchop.adb, gnatcmd.adb, gnatls.adb, gnatname.adb, krunch.adb,
2541         make.adb, makeutl.adb, memtrack.adb, mlib-prj.adb, mlib.adb,
2542         mlib.ads, tempdir.adb: Remove VMS handling.
2544 2014-08-01  Pascal Obry  <obry@adacore.com>
2546         * adaint.h, adaint.c (__gnat_file_length): Returns an __int64.
2547         (__gnat_named_file_length): Likewise.
2548         (__gnat_file_length_attr): Likewise.
2549         * a-direct.adb (C_Size): Use size_t as returned type.
2550         * osint.adb (File_Length): Adjust spec for Internal routine
2551         (returns size_t).
2552         * s-os_lib.adb (File_Length): Now returns a CRTL.size_t.
2553         (System.CRTL): With claused moved to spec.
2554         * s-os_lib.ads (System.CRTL): With clause moved to here.
2556 2014-08-01  Pascal Obry  <obry@adacore.com>
2558         * adaint.h, adaint.c (__gnat_open): Added.
2559         * s-crtl.ads (open): Import __gnat_open for large file support.
2561 2014-08-01  Robert Dewar  <dewar@adacore.com>
2563         * sem_case.adb (Dup_Choice): Improve message for integer constants.
2565 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
2567         * gnatlink.adb: Remove special handling of VMS, RTX and JVM.
2569 2014-08-01  Pascal Obry  <obry@adacore.com>
2571         * adaint.h (GNAT_OPEN): Defines as open64 where supported.
2572         * adaint.c (GNAT_OPEN): Uses new macro where needed.
2574 2014-07-31  Eric Botcazou  <ebotcazou@adacore.com>
2576         * gcc-interface/utils.c (lookup_and_insert_pad_type): New function
2577         extracted from...
2578         (maybe_pad_type): ...here.  Call it to canonicalize the pad type.
2579         * gcc-interface/gigi.h: Update comment.
2581 2014-07-31  Javier Miranda  <miranda@adacore.com>
2583         * debug.adb Remove documentation of -gnatd.k (no longer needed).
2584         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Code cleanup.
2585         * inline.ads (Backend_Inlined_Subps): New
2586         Elist.  (Backend_Not_Inlined_Subps): New Elist.
2587         (Has_Excluded_Declaration): Declaration previously located in
2588         * inline.adb (Has_Excluded_Statement): Declaration previously
2589         located in inline.adb
2590         * inline.adb (Has_Single_Return): Moved out of
2591         Build_Body_To_Inline to avoid having duplicated code.
2592         (Number_Of_Statements): New subprogram.
2593         (Register_Backend_Inlined_Subprogram): New subprogram.
2594         (Register_Backend_Not_Inlined_Subprogram): New subprogram.
2595         (Add_Inlined_Subprogram): Register backend inlined subprograms and
2596         also register subprograms that cannot be inlined by the backend.
2597         (Has_Excluded_Declaration): Moved out of Build_Body_To_Inline
2598         to avoid having duplicated code.  Replace occurrences of
2599         Debug_Flag_Dot_K by Back_End_Inlining.
2600         * sem_res.adb (Resolve_Call): Code cleanup.
2601         * exp_ch6.adb (Expand_Call): Complete previous patch. Replace
2602         occurrence of Debug_Flag_Dot_K by Back_End_Inlining.
2603         (List_Inlining_Info): Add listing of subprograms passed to the
2604         backend and listing of subprograms that cannot be inlined by
2605         the backend.
2606         * sem_ch12.adb, sem_ch3.adb Replace occurrences of
2607         Debug_Flag_Dot_K by Back_End_Inlining.
2609 2014-07-31  Robert Dewar  <dewar@adacore.com>
2611         * nlists.ads: Minor code fix (remove unwise Inline for
2612         List_Length).
2614 2014-07-31  Arnaud Charlet  <charlet@adacore.com>
2616         * einfo.adb: Remove VMS specific code.
2617         * exp_attr.adb: Remove VAX specific code.
2618         * set_targ.adb: Remove handling of VAX_Float.
2619         * sem_vfpt.adb: Remove references to Vax_Native.
2620         * sem_attr.adb (Is_VAX_Float): Remove ref to VAX_Native.
2622 2014-07-31  Robert Dewar  <dewar@adacore.com>
2624         * sem_ch4.adb: Minor reformatting.
2626 2014-07-31  Arnaud Charlet  <charlet@adacore.com>
2628         * gcc-interface/trans.c, gcc-interface/misc.c: Remove references
2629         to VMS. Misc clean ups.
2630         * gcc-interface/Makefile.in (gnatlib-shared-vms): Remove.
2632 2014-07-31  Robert Dewar  <dewar@adacore.com>
2634         * cstand.adb, einfo.adb, einfo.ads, errout.adb, exp_attr.adb,
2635         exp_prag.adb, frontend.adb, interfac.ads,
2636         par-prag.adb, s-auxdec.ads, s-filofl.ads, s-fishfl.ads, s-fvadfl.ads,
2637         s-fvaffl.ads, s-fvagfl.ads, s-vaflop.ads, sem_attr.adb, sem_attr.ads,
2638         sem_ch13.adb, sem_ch3.adb, sem_ch8.adb, sem_prag.adb, snames.adb-tmpl,
2639         snames.ads-tmpl: Remove obsolete VMS-specific code.
2641 2014-07-31  Robert Dewar  <dewar@adacore.com>
2643         * sem_ch3.adb, sem_ch13.adb: Minor reformatting.
2645 2014-07-31  Arnaud Charlet  <charlet@adacore.com>
2647         * a-intnam-linux.ads: Minor: update obsolete comments.
2648         * s-taasde.adb: Minor: fix comment header.
2650 2014-07-31  Arnaud Charlet  <charlet@adacore.com>
2652         * s-auxdec-vms-ia64.adb, s-parame-vms-alpha.ads, s-asthan-vms-alpha.adb,
2653         s-tpopde-vms.adb, s-mastop-vms.adb, s-tpopde-vms.ads, s-taprop-vms.adb,
2654         mlib-tgt-vms_common.adb, mlib-tgt-vms_common.ads, s-inmaop-vms.adb,
2655         g-enblsp-vms-alpha.adb, s-ransee-vms.adb, s-osprim-vms.adb,
2656         s-osprim-vms.ads, g-socthi-vms.adb, g-socthi-vms.ads, system-vms_64.ads,
2657         s-osinte-vms.adb, s-osinte-vms.ads, g-eacodu-vms.adb,
2658         s-vaflop-vms-alpha.adb, s-parame-vms-ia64.ads, a-dirval-vms.adb,
2659         a-caldel-vms.adb, mlib-tgt-specific-vms-alpha.adb, s-tasdeb-vms.adb,
2660         symbols-vms.adb, a-intnam-vms.ads, g-expect-vms.adb,
2661         symbols-processing-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb,
2662         s-traent-vms.adb, s-traent-vms.ads, i-cstrea-vms.adb, a-numaux-vms.ads,
2663         symbols-processing-vms-ia64.adb, s-interr-vms.adb, s-memory-vms_64.adb,
2664         s-memory-vms_64.ads, g-enblsp-vms-ia64.adb, s-taspri-vms.ads,
2665         s-auxdec-vms_64.ads, s-intman-vms.adb, s-intman-vms.ads,
2666         s-tpopsp-vms.adb, s-asthan-vms-ia64.adb, a-calend-vms.adb,
2667         a-calend-vms.ads, system-vms-ia64.ads, s-auxdec-vms-alpha.adb: Removed.
2668         * namet.h (Is_Non_Ada_Error): Remove.
2670 2014-07-31  Robert Dewar  <dewar@adacore.com>
2672         * exp_util.adb, lib-writ.adb, sem_ch12.adb, s-direio.adb: Minor
2673         reformatting.
2675 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
2677         * exp_attr.adb (Expand_Loop_Entry_Attribute): Update the comment
2678         which demonstrates the expansion of while loops subject to
2679         attribute 'Loop_Entry. The condition of a while loop along with
2680         related condition actions is now wrapped in a function.  Instead
2681         of repeating the condition, the expansion now calls the function.
2683 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
2685         * sem_case.adb (Check_Against_Predicate): Correct off-by-one
2686         error when reporting of missing values in a case statement for
2687         a type with a static predicate.
2688         (Check_Choices): Reject a choice given by a subtype to which a
2689         Dynamic_Predicate applies.
2690         * sem_ch3.adb (Analyze_Subtype_Declaration): Inherit
2691         Has_Dynamic_Predicate_Aspect flag from parent.
2693 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
2695         * sem_ch13.adb (Analyze_Aspect_Specifications): A predicate
2696         cannot apply to a subtype of an incomplete type.
2697         (Is_Static_Choice): Treat an Others_Clause as static. The
2698         staticness of the expression and of the range are checked
2699         elsewhere.
2701 2014-07-31  Pascal Obry  <obry@adacore.com>
2703         * adaint.h (__gnat_ftell64): Added.
2704         (__gnat_fseek64): Added.
2705         (__int64): Added.
2706         * cstreams.c (__int64): Removed.
2708 2014-07-31  Pascal Obry  <obry@adacore.com>
2710         * a-stream.ads (Stream_Element_Offset): Now a signed 64bit type.
2711         * i-cstrea.ads, s-crtl.ads (fseek64): Offset is always a 64bit value.
2712         (ftell64): Always returns a 64bit value.
2713         * cstreams.c (int64): New definition.
2714         (_FILE_OFFSET_BITS): Set to 64 to enable 64bit offset support.
2715         (__gnat_ftell64): Always returns a 64bit value. The implemenation now
2716         uses ftello() on UNIX.
2717         (__gnat_fseek64): Offset is always a 64bit value. The
2718         implementation now uses fseeko() on UNIX.
2719         * a-ststio.adb, s-direio.adb (Set_Position): Simplify code,
2720         always use fseek64 to set the offset.
2721         (Size): Simplify code, always use fseek64/ftell64.
2722         * s-direio.ads (Count): Now an int64.
2723         * g-socket.ads (Vector_Element): Adjust definition for Length
2724         to be a size_t. This matches the C definition and avoid using
2725         a 64bit integer on 32bit platforms now that Count is always 64bit.
2726         * g-socthi-mingw.adb (Ada.Streams): Removed as not used anymore.
2727         (C_Recvmsg): Change some conversion to account for change in
2728         Vector_Element.
2729         (C_Sendmsg): Likewise.
2731 2014-07-31  Robert Dewar  <dewar@adacore.com>
2733         * cstand.adb (Create_Standard): Remove handling of -gnatdm flag.
2734         * debug.adb: Remove documentation of -gnatdm flag.
2735         * gnat1drv.adb (Adjust_Global_Switches): Remove handling of
2736         -gnatdm flag.
2738 2014-07-31  Arnaud Charlet  <charlet@adacore.com>
2740         * lib-writ.adb (Write_Unit_Information): Fix case where U =
2741         No_Unit.
2743 2014-07-31  Claire Dross  <dross@adacore.com>
2745         * exp_util.adb, exp_util.ads
2746         (Get_First_Parent_With_External_Axiomatization_For_Entity):
2747         New routine to find the first parent of an entity with
2748         a pragma Annotate (GNATprove, External_Axiomatization).
2749         (Has_Annotate_Pragma_For_External_Axiomatization): New function
2750         to check if a package has a pragma Annotate (GNATprove,
2751         External_Axiomatization).
2752         * einfo.ads, einfo.adb (Is_Generic_Actual_Subprogram): New
2753         flag on the entity for the declaration created for a formal
2754         subprogram in an instance. This is a renaming declaration,
2755         or in GNATprove_Mode the declaration of an expression function
2756         that captures the axiomatization of the actual.
2757         * sem_ch6.adb (Analyze_Expression_Function): For a
2758         Generic_Actual_Subprogram, place body immediately after the
2759         declaration because it may be used in a subsequent declaration
2760         in the instance.
2761         * sem_ch12.adb (Build_Wrapper): Add code to handle instances where
2762         the actual is a function, not an operator. Handle functions with
2763         one and two parameters and binary and unary operators.
2765 2014-07-31  Pascal Obry  <obry@adacore.com>
2767         * cstreams.c (__gnat_is_regular_file_fd): Removed.
2768         * adaint.c (__gnat_is_regular_file_fd): Added.
2770 2014-07-31  Robert Dewar  <dewar@adacore.com>
2772         * exp_strm.adb: Minor reformatting.
2774 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
2776         * sem_ch12.adb (Build_Wrapper): New procedure, subsidiary to
2777         Analyze_Associations, to create a wrapper around operators that
2778         are actuals to formal subprograms. This is done in GNATProve
2779         mode in order to propagate the contracts of the operators to
2780         the body of the instance.
2782 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
2784         * sem_attr.adb (Analyze_Attribute, case 'Old):  The reference is
2785         legal if within an aspect specification for a generic subprogram.
2787 2014-07-31  Javier Miranda  <miranda@adacore.com>
2789         * gnat1drv.adb (Back_End_Inlining): Set to false if
2790         Suppress_All_Inlining is set.
2791         * debug.adb: Adding documentation for -gnatd.z.
2792         * inline.adb (Add_Inlined_Body): Extend the -gnatn2
2793         processing to -gnatn1 for calls to Inline_Always routines.
2794         (Add_Inlined_Subprogram): Remove previous patch.
2796 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
2798         * sem_ch13.adb (Check_One_Function): Apply properly the static
2799         semantic rules for indexing aspects and the functions they denote.
2801 2014-07-31  Javier Miranda  <miranda@adacore.com>
2803         * debug.adb: Complete documentation of -gnatd.z.
2805 2014-07-31  Bob Duff  <duff@adacore.com>
2807         * gnat_ugn.texi: Minor doc fixes.
2809 2014-07-31  Robert Dewar  <dewar@adacore.com>
2811         * sem_aggr.adb (Resolve_Array_Aggregate): Fix posting of missing
2812         index value.
2814 2014-07-31  Tristan Gingold  <gingold@adacore.com>
2816         * s-unstyp.ads (Packed_Byte): Make this type universal aliasing.
2817         (Packed_Bytes1): Make component aliased.
2819 2014-07-31  Robert Dewar  <dewar@adacore.com>
2821         * s-unstyp.ads, s-fileio.adb: Minor reformatting.
2823 2014-07-31  Robert Dewar  <dewar@adacore.com>
2825         * inline.adb, gnat1drv.adb, exp_ch6.adb, s-fileio.adb: Minor
2826         reformatting.
2828 2014-07-31  Eric Botcazou  <ebotcazou@adacore.com>
2830         * gcc-interface/utils2.c ((build_binary_op): Don't set TREE_THIS_NOTRAP
2831         on array references here, now done more selectively in trans.c.
2833 2014-07-31  Doug Rupp  <rupp@adacore.com>
2835         * gcc-interface/misc.c (gnat_init_gcc_fp(): Set flag_errno_math to 0.
2837 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
2839         * sem_util.adb (Is_Effectively_Volatile): New routine.
2841 2014-07-31  Fedor Rybin  <frybin@adacore.com>
2843         * gnat_ugn.texi: Document --test-duration option for gnattest.
2845 2014-07-31  Javier Miranda  <miranda@adacore.com>
2846             Eric Botcazou  <ebotcazou@adacore.com>
2848         * opt.ads (Back_End_Inlining): New variable which controls
2849         activation of inlining by back-end expansion.
2850         * gnat1drv.adb (Adjust_Global_Switches): Initialize Back_End_Inlining
2851         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Do not build
2852         the body to be inlined by the frontend if Back_End_Inlining
2853         is enabled.
2854         * exp_ch6.adb (Register_Backend_Call): Moved to inline.adb.
2855         (Expand_Call): If backend inlining is enabled let the backend to
2856         handle inlined subprograms.
2857         * inline.ads (Register_Backend_Call): Moved here from exp_ch6
2858         * inline.adb (Register_Backend_Call): Moved here from exp_ch6.
2859         (Add_Inlined_Subprogram): Add subprograms when Back_End_Inlining is set.
2860         (Must_Inline): Do not return Inline_Call if Back_End_Inlining is
2861         enabled.
2862         * debug.adb Document -gnatd.z
2863         * fe.h Import Back_End_Inlining variable.
2864         * gcc-interface/utils.c (create_subprog_decl): If Back_End_Inlining is
2865         enabled then declare attribute "always inline"
2866         * gcc-interface/decl.c, gcc-interface/trans.c,
2867         gcc-interface/gigi.h: Add handling of Inline_Always pragma.
2869 2014-07-31  Robert Dewar  <dewar@adacore.com>
2871         * a-ngelfu.ads: Minor comment fix.
2873 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
2875         * freeze.adb (Freeze_Record_Type): Replace all calls to
2876         Is_SPARK_Volatile with Is_Effectively_Volatile and update
2877         related comments.
2878         * sem_ch3.adb (Analyze_Object_Contract, Process_Discriminants):
2879         Replace all calls to Is_SPARK_Volatile with
2880         Is_Effectively_Volatile and update related comments.
2881         * sem_ch5.adb (Analyze_Iterator_Specification,
2882         Analyze_Loop_Parameter_Specification): Replace all calls to
2883         Is_SPARK_Volatile with Is_Effectively_Volatile and update
2884         related comments.
2885         * sem_ch6.adb (Process_Formals): Replace all calls to
2886         Is_SPARK_Volatile with Is_Effectively_Volatile and update
2887         related comments.
2888         * sem_ch12.adb (Instantiate_Object): Replace the call to
2889         Is_SPARK_Volatile_Object with Is_Effectively_Volatile_Object
2890         and update related comment.
2891         * sem_prag.adb (Analyze_External_Property_In_Decl_Part,
2892         Analyze_Global_Item): Replace all calls to Is_SPARK_Volatile
2893         with Is_Effectively_Volatile and update related comments.
2894         * sem_res.adb (Resolve_Actuals, Resolve_Entity_Name): Replace
2895         all calls to Is_SPARK_Volatile with Is_Effectively_Volatile and
2896         update related comments.
2897         * sem_util.adb (Has_Enabled_Property,
2898         Variable_Has_Enabled_Property): Replace all calls
2899         to Is_SPARK_Volatile with Is_Effectively_Volatile and
2900         update related comments.
2901         (Is_Effectively_Volatile): New routine.
2902         (Is_Effectively_Volatile_Object): New routine.
2903         (Is_SPARK_Volatile): Removed.
2904         (Is_SPARK_Volatile_Object): Removed.
2905         * sem_util.ads (Is_Effectively_Volatile): New routine.
2906         (Is_Effectively_Volatile_Object): New routine.
2907         (Is_SPARK_Volatile): Removed.
2908         (Is_SPARK_Volatile_Object): Removed.
2910 2014-07-31  Pascal Obry  <obry@adacore.com>
2912         * s-fileio.adb (Open): Make sure a shared file gets inserted into
2913         the global list atomically. This ensures that the file descriptor
2914         won't be freed because another tasks is closing the file.
2916 2014-07-31  Robert Dewar  <dewar@adacore.com>
2918         * sem_ch3.adb (Process_Range_Expr_In_Decl): Add comments on
2919         generation of _FIRST and _LAST variables even in GNATprove_Mode.
2920         * gnat_ugn.texi: Minor editing.
2921         * sem_prag.adb (Ensure_Aggregate_Form): Make sure generated
2922         aggregate is marked Comes_From_Source if argument is CFS.
2924 2014-07-31  Pascal Obry  <obry@adacore.com>
2926         * s-fileio.adb: Remove obsolete comment.
2928 2014-07-31  Vincent Celier  <celier@adacore.com>
2930         * a-strbou.ads ("=" (Bounded_String, Bounded_String): Add
2931         overriding keyword before function to avoid error when compiler
2932         is called with -gnatyO (check overriding indicators).
2934 2014-07-31  Tucker Taft  <taft@adacore.com>
2936         * gnat_ugn.texi: Add a paragraph pointing the reader
2937         to the "plugins" example.
2939 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
2941         * freeze.adb (Freeze_Expression): Document the
2942         purpose of the parent chain traversal.
2944 2014-07-31  Robert Dewar  <dewar@adacore.com>
2946         * checks.ads, checks.adb (Activate_Overflow_Check): Do not set flag for
2947         unconstrained fpt ops.
2949 2014-07-31  Pascal Obry  <obry@adacore.com>
2951         * s-fileio.adb (Open): Make sure a shared file gets inserted into
2952         the global list atomically. This ensures that the file descriptor
2953         won't be freed because another tasks is closing the file.
2955 2014-07-31  Vincent Celier  <celier@adacore.com>
2957         * projects.texi: Minor spelling error fix.
2959 2014-07-31  Robert Dewar  <dewar@adacore.com>
2961         * gnat_rm.texi: Document No_Elaboration_Code_All restriction.
2962         * lib-writ.adb, lib-load.adb: Initialize No_Elab_Code field in unit
2963         information.
2964         * lib.ads, lib.adb (No_Elab_Code): New field in unit information.
2965         * restrict.adb (Process_Restriction_Synonyms): Add handling
2966         of No_Elaboration_Code_All.
2967         * restrict.ads (Process_Restriction_Synonyms): Now handles
2968         No_Elaboration_Code_All.
2969         * sem_ch10.adb (Analyze_Context): Enforce transitive with for
2970         No_Elaboration_Code_All.
2971         * sem_prag.adb (Process_Restrictions_Or_Restriction_Warnings):
2972         Handle setting of No_Elab_Code in unit information. Handle
2973         No_Elaboration_Code_All.
2974         * snames.ads-tmpl (Name_No_Elaboration_Code): New name for
2975         pragma processing.
2976         (Name_No_Elaboration_Code_All): New name for pragma processing.
2978 2014-07-31  Eric Botcazou  <ebotcazou@adacore.com>
2980         * exp_aggr.adb (Aggr_Assignment_OK_For_Backend): Reject array
2981         types with a null range and use the Esize of the component
2982         instead of its RM_Size to identify appropriate values.
2984 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
2986         * freeze.adb Add with and use clause for Aspects.
2987         (Freeze_Expression): Emit an error when a volatile constant lacks
2988         Boolean aspect Import.
2989         (Has_Boolean_Aspect_Import): New routine.
2991 2014-07-31  Gary Dismukes  <dismukes@adacore.com>
2993         * exp_util.adb: Minor reformatting.
2995 2014-07-31  Vincent Celier  <celier@adacore.com>
2997         * errutil.adb (Error_Msg): Make sure that all components of
2998         the error message object are initialized.
3000 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
3002         * sem_ch4.adb (Try_Container_Indexing): If the container type is
3003         class-wide, use specific type to locate iteration primitives.
3004         * sem_ch13.adb (Check_Indexing_Functions): Add legality checks for
3005         rules in RM 4.1.6 (Illegal_Indexing): New diagnostic procedure.
3006         Minor error message reformating.
3007         * exp_ch5.adb (Expand_Iterator_Loop): Handle properly Iterator
3008         aspect for a derived type.
3010 2014-07-31  Robert Dewar  <dewar@adacore.com>
3012         * debug.adb: Document debug flag d.X.
3014 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
3016         * sem_util.ads (Find_Specific_Type): Moved here from exp_disp.adb.
3017         * sem_util.adb (Find_Specific_Type): If type is untagged private,
3018         retrieve full view so that primitive operations can be located.
3019         * exp_disp.adb Move Find_Specific_Type to sem_util.
3020         * exp_ch4.adb (Expand_N_Op_Eq): If operands are class-wide, use
3021         Find_Specific_Type to locate primitive equality.
3022         * exp_util.adb (Make_CW_Equivalent_Type): A class_wide equivalent
3023         type does not require initialization.
3024         * exp_attr.adb (Compile_Stream_Body_In_Scope): Within an instance
3025         body all visibility is established, and the enclosing package
3026         declarations must not be installed.
3028 2014-07-31  Yannick Moy  <moy@adacore.com>
3030         * sem_parg.adb, sem_prag.ads (Collect_Subprogram_Inputs_Outputs):
3031         Make subprogram public.
3033 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
3035         * exp_ch9.adb (Expand_N_Protected_Type_Declaration): New
3036         predicate Discriminated_Size, to distinguish between private
3037         components that depend on discriminants from those whose size
3038         depends on some other non-static expression.
3040 2014-07-31  Nicolas Setton  <setton@adacore.com>
3042         * g-exptty.adb (Close): Fix binding to Waitpid: use the
3043         tty version.
3045 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
3047         * sem_ch3.adb (Make_Index): Reject properly the use of 'Length
3048         in a discrete range, when 'range was probably intended.
3050 2014-07-31  Robert Dewar  <dewar@adacore.com>
3052         * sem_warn.adb, sem_warn.ads (Has_Junk_Name): Moved from body to spec.
3054 2014-07-31  Robert Dewar  <dewar@adacore.com>
3056         * frontend.adb: Minor reformatting.
3057         * sem.adb: Minor reformatting.
3058         * sem_ch6.adb (Analyze_Null_Procedure): Set proper sloc for
3059         identifiers on rewrite.
3060         * par.adb: Minor comment updates.
3061         * a-ngelfu.adb (Cos): Minor simplification.
3062         * par-ch13.adb (Get_Aspect_Specifications): Improve messages
3063         and recovery for bad aspect.
3064         * exp_ch3.adb: Code clean up.
3065         * sem_util.ads: Minor comment correction.
3066         * sem_ch13.adb (Check_Array_Type): Properly handle large types.
3067         * sem_ch3.adb: Code clean up.
3068         * binderr.ads: Minor comment correction.
3070 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
3072         * exp_disp.adb (Expand_Interface_Conversion): A call whose
3073         prefix is a static conversion to an interface type that is not
3074         class-wide is not dispatching.
3076 2014-07-31  Robert Dewar  <dewar@adacore.com>
3078         * inline.adb, s-traceb.adb, s-traceb-hpux.adb, memtrack.adb,
3079         s-traceb-mastop.adb: Minor reformatting.
3081 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
3083         * exp_ch3.adb (Expand_Record_Extension): In ASIS_Mode perform
3084         expansion, to handle properly visibility of selected components
3085         in instance bodies.
3087 2014-07-31  Robert Dewar  <dewar@adacore.com>
3089         * par-ch13.adb (Get_Aspect_Specifications): Set Inside_Depends.
3090         * par-ch2.adb (P_Pragma): Set Inside_Depends.
3091         * par-ch4.adb (P_Simple_Expression): Pass Inside_Depends to
3092         Check_Unary_Plus_Or_Minus.
3093         * scans.ads (Inside_Depends): New flag.
3094         * scng.adb (Scan): Pass Inside_Depends to Check_Arrow.
3095         * style.ads: Add Inside_Depends parameter to Check_Arrow Add
3096         Inside_Depends parameter to Check_Unary_Plus_Or_Minus.
3097         * styleg.adb (Check_Arrow): Handle Inside_Depends case.
3098         (Check_Unary_Plus_Or_Minus): Handle Inside_Depends case.
3099         * styleg.ads: Add Inside_Depends parameter to Check_Arrow Add.
3100         Inside_Depends parameter to Check_Unary_Plus_Or_Minus.
3102 2014-07-31  Javier Miranda  <miranda@adacore.com>
3104         * s-vaflop.adb Move the body of function T_To_G before
3105         T_To_D. Required for frontend inlining.
3106         * inline.adb (Has_Excluded_Contract): New subprogram used to
3107         check if a subprogram inlined by the frontend has contracts
3108         which cannot be inlined.
3110 2014-07-31  Bob Duff  <duff@adacore.com>
3112         * s-traceb.adb, s-traceb-hpux.adb, s-traceb-mastop.adb:
3113         (Call_Chain): Add 1 to number of frames to skip, to account for
3114         the fact that there's one more frame on the stack.
3115         * gcc-interface/Makefile.in (s-traceb.o): Adjust rules.
3117 2014-07-31  Robert Dewar  <dewar@adacore.com>
3119         * checks.adb (Enable_Overflow_Check): More precise setting of
3120         Do_Overflow_Check flag for division.
3122 2014-07-31  Eric Botcazou  <ebotcazou@adacore.com>
3124         * exp_aggr.adb (Aggr_Assignment_OK_For_Backend): Reject packed
3125         array types with implementation type.
3127 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
3129         * sem_ch10.adb (Process_State): Remove local variable Name. Add
3130         local variable Decl. Partially declare an abstract state by
3131         generating an entity and storing it in the state declaration.
3132         * sem_prag.adb (Create_Abstract_State): Fully declare a
3133         semi-declared abstract state.
3135 2014-07-31  Robert Dewar  <dewar@adacore.com>
3137         * prj-nmsc.adb: Minor reformatting.
3139 2014-07-31  Bob Duff  <duff@adacore.com>
3141         * s-tasdeb.adb (System.Tasking.Debug): Remove
3142         all usage of the secondary stack from this package.
3144 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
3146         * freeze.adb (Freeze_Expression): Update the loop in charge
3147         of finding a proper insertion place for freeze nodes to handle
3148         N_Expression_With_Actions nodes.
3150 2014-07-31  Robert Dewar  <dewar@adacore.com>
3152         * sem_util.adb, a-ngelfu.ads, prj-nmsc.adb, prj-conf.adb: Minor
3153         reformatting.
3155 2014-07-31  Pascal Obry  <obry@adacore.com>
3157         * prj-nmsc.adb: Minor reformatting.
3159 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
3161         * sem_util.adb (Has_Preelaborable_Initialization): Check that
3162         type is tagged before checking whether a user-defined Initialize
3163         procedure is present.
3165 2014-07-31  Gary Dismukes  <dismukes@adacore.com>
3167         * a-ngelfu.ads (Sqrt): Augment postcondition.
3169 2014-07-31  Pascal Obry  <obry@adacore.com>
3171         * prj-nmsc.adb (Check_Library_Attributes): An aggegate library
3172         directory and ALI directory must be different than all object
3173         and library directories of aggregated projects.
3175 2014-07-31  Vincent Celier  <celier@adacore.com>
3177         * prj-pars.adb, prj-conf.ads, prj-conf.adb (Locate_Runtime): Move spec
3178         to package body, as it is not called from outside. Remove argument
3179         Project_Tree, no longer used. When runtime cannot be found,
3180         call Raise_Invalid_Config instead of failing the program.
3182 2014-07-31  Robert Dewar  <dewar@adacore.com>
3184         * bindgen.adb (Gen_Output_File_Ada): Generate pragma Suppress
3185         (Overflow_Check).
3186         * gnatlink.adb (Process_Args): Remove generation of -gnato0,
3187         no longer needed.
3189 2014-07-31  Robert Dewar  <dewar@adacore.com>
3191         * gnat_ugn.texi: Document new switch -gnato0.
3192         * sem_ch3.ads: Minor reformatting.
3193         * gnatlink.adb (Process_Args): Compile bind file with -gnato0
3194         (we do not want overflow checks when incrementing elaboration
3195         counters).
3196         * einfo.ads: Minor reformatting.
3198 2014-07-31  Robert Dewar  <dewar@adacore.com>
3200         * exp_ch5.adb, freeze.adb, exp_ch3.adb: Minor comment correction.
3201         * s-arit64.adb: Minor reformatting.
3203 2014-07-31  Robert Dewar  <dewar@adacore.com>
3205         * gnat1drv.adb (Adjust_Global_Switches): Default for overflow
3206         checking is enabled except in GNAT_Mode.
3207         * switch-c.adb (Scan_Front_End_Switches): Implement -gnato0
3208         (suppress overflow checks).
3210 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
3212         * exp_ch3.adb (Expand_Freeze_Record_Type): Do not build an
3213         invariant procedure for an internally generated subtype that is
3214         created for an object of a class-wide type.
3216 2014-07-31  Vincent Celier  <celier@adacore.com>
3218         * prj-nmsc.adb, errutil.adb: Make code similar to Errout.
3220 2014-07-31  Gary Dismukes  <dismukes@adacore.com>
3222         * gnat_rm.texi, sem_aux.ads, einfo.ads, sem_util.ads, sem_ch6.adb,
3223         exp_disp.adb: Minor reformatting.
3225 2014-07-31  Robert Dewar  <dewar@adacore.com>
3227         * exp_ch5.adb, sem_ch3.adb, exp_ch7.adb, exp_util.adb, exp_ch9.adb,
3228         sem_ch7.adb, checks.adb, s-exctra.adb, exp_ch6.adb, exp_disp.adb,
3229         exp_dist.adb, sem_ch13.adb, exp_strm.adb, exp_ch3.adb: Minor
3230         reformatting.
3232 2014-07-31  Robert Dewar  <dewar@adacore.com>
3234         * sem_ch13.adb: Minor reformatting.
3236 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
3238         * exp_ch3.adb (Build_Invariant_Checks): If the enclosing record
3239         is an unchecked_union, warn that invariants will not be checked
3240         on components that have them.
3242 2014-07-31  Robert Dewar  <dewar@adacore.com>
3244         * freeze.adb (Freeze_Entity): Check for error of
3245         Type_Invariant'Class applied to a untagged type.
3246         * sem_ch6.adb (Analyze_Null_Procedure): Unconditionally rewrite
3247         as null body, so that we perform error checks even if expansion
3248         is off.
3250 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
3252         * sem_ch13.adb (Build_Invariant_Procedure): If body of procedure
3253         is already present, nothing to do.
3254         * exp_ch3.adb (Build_Component_Invariant_Call): For an access
3255         component, check whether the access type has an invariant before
3256         checking the designated type.
3257         (Build_Record_Invariant_Proc): Change suffix of generated
3258         name to prevent ambiguity when record type has invariants
3259         in addition to those of components, and two subprograms are
3260         constructed. Consistent with handling of array types.
3261         (Insert_Component_Invariant_Checks): Build invariant procedure
3262         body when one has not been created yet, in the case of composite
3263         types that are completions and whose full declarations carry
3264         invariants.
3266 2014-07-30  Thomas Quinot  <quinot@adacore.com>
3268         * gnat_rm.texi: Minor doc fixes.
3270 2014-07-30  Robert Dewar  <dewar@adacore.com>
3272         * a-rbtgbo.adb, sem_ch13.adb: Minor reformatting.
3274 2014-07-30  Vincent Celier  <celier@adacore.com>
3276         * errutil.adb (Set_Msg_Text): Process tilde ('~'): no processing
3277         of error message.
3278         * prj-nmsc.adb (Locate_Directory): Use a tilde ('~') in the
3279         message to report that a directory cannot be created, to avoid
3280         processing of the directory path that may contains special
3281         insertion characters.
3283 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3285         * a-crdlli.ads: Place declaration of Empty_List after full type
3286         declaration for Curosr, to prevent freezing error.
3288 2014-07-30  Robert Dewar  <dewar@adacore.com>
3290         * get_targ.adb: Minor code reorganization.
3291         * prj-proc.adb, prj-proc.ads, get_targ.ads, sem_ch6.adb: Minor
3292         reformatting.
3294 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3296         * a-cbhase.adb: a-cbhase.adb (Insert): Raise Constraint_Error,
3297         not Program_Error, when attempting to remove an element not in
3298         the set. This is the given semantics for all set containers.
3300 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3302         * a-rbtgbo.adb (Delete_Node_Sans_Free): If
3303         element is not present in tree return rather than violating
3304         an assertion. Constraint_Error will be raised in the caller if
3305         element is not in the container.
3307 2014-07-30  Arnaud Charlet  <charlet@adacore.com>
3309         * set_targ.adb (Read_Target_Dependent_Values): New subprogram.
3310         (elab body): Add provision for default target config file.
3311         * get_targ.ads, get_targ.adb (Get_Back_End_Config_File): New subprogram.
3313 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3315         * a-cbhase.adb (Delete): Raise Constraint_Error, not Program_Error,
3316         when attempting to remove an element not in the set. This is
3317         the given semantics for all set containers.
3318         * a-cborse.adb (Delete): Attempt removal first, to check for
3319         tampering, before checking whether this is an attempt to
3320         delete a  non-existing element, and in fthe latter case raise
3321         Constraint_Error.
3323 2014-07-30  Vincent Celier  <celier@adacore.com>
3325         * prj-proc.adb (Recursive_Process): Do not create a new
3326         Project_Id if the project is already in the list of projects of
3327         the tree.
3329 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3331         * sem_ch6.adb (Analyze_Function_Return): Reject a return expression
3332         whose type is an incomplete formal type.
3333         (Analyze_Return_Type): Reject a return type that is an untagged
3334         imcomplete formal type.
3335         (Process_Formals): Reject a formal parameter whose type is an
3336         untagged formal incomplete type.
3337         * sem_res.adb (Resolve_Actuals): Reject an actual whose type is
3338         an untagged formal incomplete type.
3340 2014-07-30  Robert Dewar  <dewar@adacore.com>
3342         * gnat_ugn.texi: Minor spelling correction.
3343         * makeutl.adb: Minor code reorganization.
3344         * exp_ch4.adb, exp_aggr.adb, exp_ch3.adb: Minor reformatting.
3346 2014-07-30  Robert Dewar  <dewar@adacore.com>
3348         * einfo.ads (Has_Unchecked_Union): Document that this is used
3349         to check for illegal Valid_Scalars attribute references.
3350         * exp_attr.adb (Build_Record_VS_Func): New function
3351         (Expand_N_Attribute_Reference, case Valid_Scalars): Call this
3352         function.
3353         * gnat_rm.texi: Document 'Valid_Scalars cannot be applied to
3354         Unchecked_Union Add note on 'Valid_Scalars generating a lot
3355         of code.
3356         * sem_attr.adb (Analyze_Attribute, case Valid_Scalars): Give
3357         error on attempt to apply Valid_Scalars to Unchecked_Union type.
3359 2014-07-30  Steve Baird  <baird@adacore.com>
3361         * exp_ch4.adb (Expand_N_Indexed_Component): Disable optimized handling
3362         of A(I..J)(K) in CodePeer_Mode.
3364 2014-07-30  Ben Brosgol  <brosgol@adacore.com>
3366         * gnat_ugn.texi: Fix typo.
3368 2014-07-30  Thomas Quinot  <quinot@adacore.com>
3370         * lib-writ.ads: document format change.
3372 2014-07-30  Pascal Obry  <obry@adacore.com>
3374         * prj-util.adb (For_Interface_Sources): Do not
3375         include sources from withed externally built projects.
3377 2014-07-30  Robert Dewar  <dewar@adacore.com>
3379         * lib.adb: Minor reformatting.
3380         * prj-util.adb: Minor reformatting.
3382 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3384         * exp_aggr.adb (Build_Record_Aggr_Code): For an array component
3385         that depends on discriminants, and which is given by an others
3386         clause, create an explicit subtype with the discriminant values
3387         of the enclosing aggregate, because the backend cannot otherwise
3388         retrieve the actual bounds of the array.
3390 2014-07-30  Fedor Rybin  <frybin@adacore.com>
3392         * gnat_ugn.texi: Improve gnattest documentation.
3394 2014-07-30  Pascal Obry  <obry@adacore.com>
3396         * makeutl.adb (Insert_Project_Sources): Properly handle sources
3397         that are aggregated. We want to include sources not only part
3398         of libraries but also if part of an aggregated project from an
3399         aggregate library.
3400         * prj.adb (For_Project_And_Aggregated_Context): Properly check
3401         state of root project.
3403 2014-07-30  Thomas Quinot  <quinot@adacore.com>
3405         * lib-load.ads: Minor reformatting.
3406         * sinfo.ads (Library_Unit): Update comment.
3407         * lib.ads (Notes): Simplify. The Unit component in Notes_Entry
3408         is redundant. Instead used the pragma Node_Id directly as the
3409         element type.
3411 2014-07-30  Thomas Quinot  <quinot@adacore.com>
3413         * lib.adb (Store_Note): Store only notes that do not come from
3414         an instance, and that are in the extended main source unit.
3415         * lib-writ (Write_Unit_Information): Annotations from subunits
3416         must be emitted along with those for the main unit, and they
3417         must carry a specific file name.
3418         * ali.ads (Notes_Record): Use a File_Name_Type instead of a
3419         Unit_Id for the source file containing the pragma, as in the
3420         case of annotations from subunits we might not have a readily
3421         available unit id.
3422         * ali.adb (Scan_ALI): Account for above change in data structure.
3424 2014-07-30  Vincent Celier  <celier@adacore.com>
3426         * makeutl.adb (Insert_Project_Sources): When the library project
3427         is an aggregate Stand-Alone Library, insert in the queue the
3428         Ada interface units, with Closure set to True;
3430 2014-07-30  Eric Botcazou  <ebotcazou@adacore.com>
3432         * sem_util.adb: Fix minor typo.
3433         * makeutl.adb: Minor reformatting.
3435 2014-07-30  Robert Dewar  <dewar@adacore.com>
3437         * exp_ch7.adb, checks.adb, makeutl.adb, makeutl.ads: Minor reformatting.
3439 2014-07-30  Yannick Moy  <moy@adacore.com>
3441         * checks.ads: Fix typo in comment.
3443 2014-07-30  Pierre-Marie Derodat  <derodat@adacore.com>
3445         * sem_util.adb (Set_Debug_Info_Needed): For scalar types, recurse on
3446         entities that materialize range bounds, if any.
3448 2014-07-30  Vincent Celier  <celier@adacore.com>
3450         * projects.texi: Minor spelling fix.
3452 2014-07-30  Hristian Kirtchev  <kirtchev@adacore.com>
3454         * checks.adb (Make_Bignum_Block): Use the new secondary stack
3455         build routines to manage the mark.
3456         * exp_ch7.adb (Create_Finalizer, Expand_Cleanup_Actions):
3457         Use the new secodary stack build routines to manage the mark.
3458         (Insert_Actions_In_Scope_Around): Add new formal parameter
3459         Manage_SS along with comment on its usage. Code and comment
3460         reformatting. Mark and release the secondary stack when the
3461         context warrants it.
3462         (Make_Transient_Block): Update the call
3463         to Insert_Actions_In_Scope_Around to account for parameter Manage_SS.
3464         (Wrap_Transient_Declaration): Remove local variable
3465         Uses_SS. Ensure that the secondary stack is marked and released
3466         when the related object declaration appears in a library level
3467         package or package body. Code and comment reformatting.
3468         * exp_util.ads, exp_util.adb (Build_SS_Mark_Call): New routine.
3469         (Build_SS_Release_Call): New routine.
3471 2014-07-30  Steve Baird  <baird@adacore.com>
3473         * exp_attr.adb: Revert previous change, not needed after all.
3475 2014-07-30  Vincent Celier  <celier@adacore.com>
3477         * makeutl.adb (Queue.Insert_Project_Sources): Insert with
3478         Closure => True for interfaces of Stand-Alone Libraries.
3479         * makeutl.ads (Source_Info (Format => Gprbuild)): Add new
3480         Boolean component Closure, defaulted to False.
3482 2014-07-30  Yannick Moy  <moy@adacore.com>
3484         * sem_res.adb: Fix typo in error message.
3486 2014-07-30  Robert Dewar  <dewar@adacore.com>
3488         * sem_ch3.adb (Process_Range_Expr_In_Decl): Use _FIRST/_LAST
3489         as name suffixes rather than L/H for subtype bounds.
3490         * tbuild.ads: Minor comment improvements and fixes
3491         (Make_External_Name): Document that suffix can start with an
3492         underscore.
3494 2014-07-30  Bob Duff  <duff@adacore.com>
3496         * gnat_ugn.texi: Document --rep-clauses switch.
3498 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3500         * sem_ch13.adb (Analyze_Aspect_Specifications): Default_Value and
3501         Default_Component_Value can only be specified for scalar type or
3502         arrays of scalar types respectively.  This legality check must
3503         be performed at the point the aspect is analyzed, in order to
3504         reject aspect specifications that apply to a partial view.
3506 2014-07-30  Thomas Quinot  <quinot@adacore.com>
3508         * freeze.adb: Minor reformatting.
3510 2014-07-30  Robert Dewar  <dewar@adacore.com>
3512         * exp_attr.adb (Expand_Attribute, case First/Last): Don't expand in
3513         codepeer mode.
3515 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3517         * freeze.adb (Check_Expression_Function): At the freeze point
3518         of an expression function, verify that the expression in the
3519         function does not contain references to any deferred constants
3520         that have no completion yet.
3521         (Freeze_Expression, Freeze_Before): call
3522         Check_Expression_Function.
3523         * a-ciorse.ads: Add Reference_Control_Type to detect tampering.
3524         * a-ciorse.adb: Add Adjust and Finalize routines for
3525         Reference_Control_Type. Use it in the construction of Reference
3526         and Constant_Reference values.
3528 2014-07-30  Robert Dewar  <dewar@adacore.com>
3530         * exp_aggr.adb: Update comments.
3531         * a-chtgbo.adb, a-chtgbo.ads, a-cbhase.adb, a-cbhase.ads: Minor
3532         reformatting.
3534 2014-07-30  Robert Dewar  <dewar@adacore.com>
3536         * cstand.adb (New_Standard_Entity): New version takes name
3537         string to call Make_Name.
3538         (Create_Standard): Use this routine to set name before setting other
3539         fields.
3541 2014-07-30  Robert Dewar  <dewar@adacore.com>
3543         * exp_attr.adb (Expand_Attribute, case First): Rewrite simple
3544         entity reference.
3545         (Expand_Attribute, case Last): Ditto.
3546         * exp_ch3.adb (Constrain_Index): New calling sequence for
3547         Process_Range_Expr_In_Decl.
3548         (Expand_N_Object_Declaration): Avoid setting Is_Known_Valid in one
3549         problematical case.
3550         * sem_ch3.adb (Constrain_Index): New calling sequence for
3551         Process_Range_Expr_In_Decl.
3552         (Set_Scalar_Range_For_Subtype): ditto.
3553         (Process_Range_Expr_In_Decl): Create constants to hold bounds for
3554         subtype.
3555         * sem_ch3.ads (Process_Range_Expr_In_Decl): Add Subtyp parameter.
3556         * sem_eval.adb (Compile_Time_Compare): Make sure we use base
3557         types if we are not assuming no invalid values.
3559 2014-07-30  Robert Dewar  <dewar@adacore.com>
3561         * clean.adb: Minor reformatting.
3562         * opt.ads: Minor fix to incorrect comment.
3564 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3566         * a-chtgbo.ads, a-chtgbo.adb (Delete_Node_At_Index): New
3567         subprogram, used by bounded hashed sets, to delete a node at
3568         a given index, whose element may have been improperly updated
3569         through a Reference_Preserving key.
3570         * a-cbhase.ads: Add Reference_Control_Type to package Generic_Keys.
3571         * a-cbhase.adb: Add Adjust and Finalize routines for
3572         Reference_Control_Type.
3573         (Delete, Insert): Raise Program_Error, not Constraint_Error,
3574         when operation is illegal.
3575         (Reference_Preserving_Key): Build aggregate for Reference_Control_Type
3576         * a-cmbutr.ads: Add Reference_Control_Type to detect tampering. Add
3577         private with_clause for Ada.Finalization.
3578         * a-cbmutr.adb: Add Adjust and Finalize routines for
3579         Reference_Control_Type. Use it in the construction of Reference
3580         and Constant_Reference values.
3582 2014-07-30  Robert Dewar  <dewar@adacore.com>
3584         * sem_ch3.adb, sem_ch3.ads: Minor code reorganization.
3586 2014-07-30  Pascal Obry  <obry@adacore.com>
3588         * clean.adb (Clean_Project): Properly check for directory
3589         existence before trying to enter it.
3591 2014-07-30  Robert Dewar  <dewar@adacore.com>
3593         * sem_ch3.ads, prj.ads, prj-nmsc.adb: Minor reformatting.
3595 2014-07-30  Robert Dewar  <dewar@adacore.com>
3597         * par-ch5.adb (P_Sequence_Of_Statements): Properly handle
3598         missing semicolon after name.
3600 2014-07-30  Pascal Obry  <obry@adacore.com>
3602         * prj.ads (Gprinstall_Flags): New constant.
3603         * prj-nmsc.adb (Check_Library_Attributes): Do not fails for
3604         missing library dir if Directories_Must_Exist_In_Projects
3605         is false.
3607 2014-07-30  Bob Duff  <duff@adacore.com>
3609         * a-except-2005.adb, a-except.adb: Remove obsolete comments.
3610         * s-traceb.ads: Updagte comments.
3612 2014-07-30  Robert Dewar  <dewar@adacore.com>
3614         * checks.adb, a-cihase.adb, a-cihase.ads, a-chtgop.adb, a-chtgop.ads,
3615         a-except.adb, a-except-2005.adb, a-cborse.adb, a-cborse.ads,
3616         a-exexda.adb, a-elchha.adb, exp_aggr.adb, a-cohase.adb: Minor
3617         reformatting.
3619 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3621         * a-chtgop.ads, a-chtgop.adb (Delete_Node_At_Index): New
3622         subprogram, used by all versions of hashed sets, to delete a node
3623         whose element has been improperly updated through a Reference_
3624         Preserving key.
3625         * a-cohase.adb: Remove Delete_Node, use new common procedure
3626         Delete_Node_At_Index.
3627         * a-cihase.ads: Add Reference_Control_Type to package Generic_Keys.
3628         * a-cihase.adb: Add Adjust and Finalize routines for
3629         Reference_Control_Type.
3630         (Reference_Preserving_Key): Build aggregate for
3631         Reference_Control_Type
3633 2014-07-30  Yannick Moy  <moy@adacore.com>
3635         * checks.adb, checks.ads (Determine_Range_R): New procedure to
3636         determine the possible range of a floating-point expression.
3638 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3640         * a-cborse.ads: Add Reference_Control_Type to package Generic_Keys.
3641         * a-cborse.adb: Add Adjust and Finalize routines for
3642         Reference_Control_Type.
3643         (Reference_Preserving_Key): Build aggregate for
3644         Reference_Control_Type.
3645         (Delete): Check for tampering, and raise Program_Error (not
3646         Constraint_Error) when attempting to delete an element not in
3647         the set.
3648         (Insert): Ditto.
3650 2014-07-30  Bob Duff  <duff@adacore.com>
3652         * a-elchha.adb, a-except-2005.adb, a-except.adb, a-exexda.adb,
3653         * a-exextr.adb, a-exstat.adb, exp_intr.ads, s-tassta.adb:
3654         Exception_Information is used to produce useful debugging
3655         information for the programmer. However, it was also used to
3656         implement the stream attributes for type Exception_Occurrence. The
3657         latter requires a stable and portable interface, which meant
3658         that we couldn't include a symbolic traceback. A separate set of
3659         routines was used to provide symbolic tracebacks under program
3660         control (i.e. not automatically). The goal of this ticket is
3661         to provide such automatic tracebacks, so the change here is to
3662         split the two functionalities: Exception_Information gives the
3663         maximally useful information for debugging (i.e. it now includes
3664         a symbolic traceback when a decorator is set, and it can be
3665         improved freely in the future without disturbing streaming).
3666         Untailored_Exception_Information always uses hexadecimal addresses
3667         in the traceback, has a stable and portable output, and is now
3668         used for streaming.
3670 2014-07-30  Eric Botcazou  <ebotcazou@adacore.com>
3672         * exp_aggr.adb (Expand_Array_Aggregate): Add missing test
3673         on the target of the assignment to find out whether it
3674         can be directly done by the back-end.
3675         * exp_util.adb (Is_Possibly_Unaligned_Slice): Remove obscure test.
3677 2014-07-30  Robert Dewar  <dewar@adacore.com>
3679         * inline.adb, a-coorse.adb, a-coorse.ads, a-cohase.adb, a-cohase.ads,
3680         a-tasatt.adb: Minor reformatting.
3682 2014-07-30  Robert Dewar  <dewar@adacore.com>
3684         * exp_ch4.adb: Minor reformatting.
3686 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3688         * a-coorse.adb, a-coorse.ads (Generic_Keys): Add a
3689         Reference_Control_Type to generic package, to keep additional
3690         information for Reference_Types that manipulate keys. Add Adjust and
3691         Finalize procedures for this type.
3692         (Finalize): When finalizing a reference_preserving_key, verify
3693         that the key of the new value is equivalent to the key of the
3694         original element, raise Program_Error otherwise.
3695         (Insert): Detect tampering.
3696         (Reference_Preserving_Key): Build proper Reference_Control_Type,
3697         and update Busy and Lock bits to detect tampering.
3698         * a-cohase.ads: Keep with-clause private.
3700 2014-07-30  Hristian Kirtchev  <kirtchev@adacore.com>
3702         * exp_ch4.adb (Expand_N_Op_Eq): Emit a warning when the operands
3703         of an equality are of an Unchecked_Union type and lack inferable
3704         discriminants.
3706 2014-07-30  Bob Duff  <duff@adacore.com>
3708         * g-exctra.adb, g-exctra.ads, s-exctra.adb, s-exctra.ads, Makefile.rtl,
3709         g-trasym.adb, g-trasym.ads, s-trasym.adb, s-trasym.ads: Move
3710         GNAT.Traceback.Symbolic and GNAT.Exception_Traces into the System
3711         hierarchy (System.Traceback.Symbolic and System.Exception_Traces), so
3712         we can call them from the runtimes. Leave renamings in place under GNAT.
3714 2014-07-30  Yannick Moy  <moy@adacore.com>
3716         * inline.adb (Check_And_Build_Body_To_Inline): Include code for
3717         inlining in GNATprove mode.
3719 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3721         * a-cohase.adb, a-cohase.ads (Generic_Keys): Add a
3722         Reference_Control_Type to generic package, to keep additional
3723         information for Reference_Types that manipulate keys. Add Adjust and
3724         Finalize procedures for this type.
3725         (Delete_Node): New procedure called when finalizing a
3726         Reference_Control_Type, to remove a node whose element has been
3727         improperly updated through a Reference.
3728         (Insert): Detect tampering.
3729         (Reference_Preserving_Key): Build proper Reference_Control_Type,
3730         and update Busy and Lock bits to detect tampering.
3732 2014-07-30  Bob Duff  <duff@adacore.com>
3734         * exp_intr.ads: Minor comment fix.
3736 2014-07-30  Gary Dismukes  <dismukes@adacore.com>
3738         * exp_prag.adb, a-tags.ads: Minor typo fixes.
3740 2014-07-30  Bob Duff  <duff@adacore.com>
3742         * a-excach.adb, a-excach-cert.adb, a-except-2005.ads,
3743         a-except.ads, g-traceb.adb, memtrack.adb,
3744         s-traceb.adb, s-traceb.ads, s-traceb-hpux.adb, s-traceb-mastop.adb:
3745         Cleanup: Make the three versions of System.Traceback.Call_Chain
3746         have the same interface. Use an array for the Traceback parameter
3747         instead of an Address.  This will enable reduction in code
3748         duplication.
3750 2014-07-30  Pat Rogers  <rogers@adacore.com>
3752         * gnat_ugn.texi: Corrected minor textual error in description
3753         of switch -gnatwl.
3755 2014-07-30  Bob Duff  <duff@adacore.com>
3757         * Makefile.rtl: Sort file names.
3759 2014-07-30  Arnaud Charlet  <charlet@adacore.com>
3761         * a-tasatt.adb: Complete previous change: kill spurious warning
3762         on e.g. sparc, and make sure we only use the fast path when the
3763         alignment is compatible.
3765 2014-07-30  Yannick Moy  <moy@adacore.com>
3767         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Mark new Spec_Id as
3768         coming from source.
3770 2014-07-30  Yannick Moy  <moy@adacore.com>
3772         * inline.adb (Build_Body_To_Inline): Issue more precise messages
3773         for declarations that prevent inlining.
3774         (Cannot_Inline): Change usual start of message to refer to contextual
3775         analysis in GNATprove mode.
3776         * sem_res.adb (Resolve_Call): Change usual start of message to
3777         refer to contextual analysis in GNATprove mode, when inlining
3778         not possible.
3780 2014-07-30  Robert Dewar  <dewar@adacore.com>
3782         * sem_res.adb, sem_ch6.adb: Minor code reorganization.
3783         * inline.adb: Minor reformatting.
3785 2014-07-30  Javier Miranda  <miranda@adacore.com>
3787         * a-tags.ads: Add comments.
3789 2014-07-30  Pat Rogers  <rogers@adacore.com>
3791         * gnat_rm.texi: Minor word error.
3793 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3795         * exp_prag.adb (Expand_Old): Insert declarationss of temporaries
3796         created to capture the value of the prefix of 'Old at the
3797         beginning of the current declarative part, to prevent data flow
3798         anomalies in the postcondition procedure that will follow.
3800 2014-07-30  Yannick Moy  <moy@adacore.com>
3802         * debug.adb: Retire debug flag -gnatdQ.
3803         * inline.adb (Can_Be_Inlined_In_GNATprove_Mode): Check SPARK_Mode
3804         on decl, not on body.  Ignore predicate functions.
3805         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Remove use of
3806         debug flag -gnatdQ.  Correctly analyze SPARK_Mode on decl and
3807         body when generating a decl for a body on which SPARK_Mode aspect
3808         is given.
3809         * sem_prag.adb (Analyze_Pragma|SPARK_Mode): Reorder tests for
3810         attaching pragma to entity, to account for declaration not coming
3811         from source.
3812         * sem_res.adb (Resolve_Call): Issue warning and flag subprogram
3813         as not always inlined in GNATprove mode, when called in an
3814         assertion context.
3816 2014-07-30  Vincent Celier  <celier@adacore.com>
3818         * debug.adb: Minor comment update.
3820 2014-07-30  Robert Dewar  <dewar@adacore.com>
3822         * s-tasuti.adb, s-tassta.adb: Minor reformatting.
3823         * sprint.adb (Sprint_Node): Handle N_Contract case.
3824         * exp_prag.adb: Minor reformatting.
3825         * freeze.adb (Freeze_Entity): Check useless postcondition for
3826         No_Return subprogram.
3827         * sem_prag.adb: Minor reformatting.
3829 2014-07-30  Javier Miranda  <miranda@adacore.com>
3831         * a-tags.ads: Complete comments about performance.
3833 2014-07-30  Fedor Rybin  <frybin@adacore.com>
3835         * gnat_ugn.texi: Adding description for --exit-status option to
3836         gnattest section.  Fixing index entry of --passed-tests option
3837         in gnattest section.
3839 2014-07-30  Javier Miranda  <miranda@adacore.com>
3841         * Makefile.rtl, gnat_rm.texi, i-cpp.adb, i-cpp.ads, impunit.adb,
3842         rtsfind.ads: Remove references to package Interfaces.CPP since this
3843         package is no longer needed.
3845 2014-07-30  Bob Duff  <duff@adacore.com>
3847         * s-taasde.adb (Timer_Queue): Don't use a
3848         build-in-place function call to initialize the Timer_Queue.
3849         * s-traent.adb, s-traent.ads, s-traent-vms.adb, s-traent-vms.ads:
3850         Turn off polling in these units, because otherwise we get
3851         elaboration circularities with Ada.Exceptions when the -gnatP
3852         switch is used.
3853         * s-tassta.adb (Create_Task): Make sure independent tasks
3854         are created with Parent = Environment_Task. This was not true,
3855         for example, in s-interr.adb, when Interrupt_Manager does "new
3856         Server_Task"; the Server_Task had Parent = Interrupt_Manager,
3857         which is wrong because the master is determined by the access
3858         type, which is at library level.
3859         * s-tasuti.adb (Make_Independent): Avoid setting Parent; it is
3860         now set correctly by Create_Task.
3861         (Make_Passive): Remove the workaround for the race condition in
3862         Make_Independent.
3863         * frontend.adb (Frontend): Revert to previous method of detecting
3864         temporary configuration pragma files, recognizing such files by
3865         ".tmp" in the name. This is more general than detecting pragmas
3866         Source_File_Name_Project, because it allows any tool to use
3867         this naming convention, no matter the content of the file.
3868         * gnat_ugn.texi: Document this naming convention.
3870 2014-07-30  Robert Dewar  <dewar@adacore.com>
3872         * exp_ch7.adb, s-tataat.adb, s-tataat.ads, s-parame-vms-alpha.ads,
3873         inline.adb, s-parame-hpux.ads, exp_smem.adb, s-tasini.adb,
3874         s-tasini.ads, s-parame-vms-ia64.ads, s-parame.ads, s-taskin.ads,
3875         s-parame-vxworks.ads, a-tasatt.adb, a-tasatt.ads: Minor reformatting.
3876         * a-suenco.adb (Convert): Handle overlong encodings in UTF8-UTF8
3877         conversion.
3879 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3881         * sem_ch5.adb: Improve error recovery.
3882         * inline.adb (Build_Body_To_Inline): Set Full_Analysis to false
3883         before analyzing the body, so that in GNATprove mode there is
3884         no light expansion. Whatever expansion is required by SPARK will
3885         be performed when analysing the inlined code.
3887 2014-07-30  Bob Duff  <duff@adacore.com>
3889         * s-tataat.adb, s-tataat.ads, a-tasatt.adb: Minor comment fixes.
3891 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3893         * sem_ch5.adb (Analyze_Loop_Statement): If loop has a label,
3894         verify that it is not hidden by an inner implicit declaration.
3896 2014-07-30  Thomas Quinot  <quinot@adacore.com>
3898         * sem.ads (Scope_Table_Entry): New component Locked_Shared_Objects.
3899         * sem_ch8.adb (Push_Scope): Initialize Locked_Shared_Objects.
3900         * exp_smem.adb (Add_Shared_Var_Lock_Procs): Handle the case where
3901         the call returns an unconstrained type: in this case there is
3902         already a transient scope, and we should not establish a new one.
3903         * exp_ch7.adb (Insert_Actions_In_Scope_Around): New formal Clean. If
3904         True, also insert cleanup actions in the tree.
3905         (Wrap_Transient_Declaration): Call Insert_Actions_In_Scope_Around
3906         with Clean set True.
3908 2014-07-30  Arnaud Charlet  <charlet@adacore.com>
3910         * s-taskin.ads (Direct_Index, Direct_Index_Range,
3911         Direct_Attribute_Element, Direct_Attribute_Array,
3912         Direct_Index_Vector, Direct_Attributes, Is_Defined,
3913         Indirect_Attributes): Removed.  (Atomic_Address,
3914         Attribute_Array, Attributes): New.
3915         * s-tasini.ads, s-tasini.adb (Proc_T, Initialize_Attributes,
3916         Finalize_Attributes_Link, Initialize_Attributes_Link): Removed.
3917         (Finalize_Attributes): Reimplement.
3918         * s-tassta.adb (Create_Task): Remove call to
3919         Initialize_Attributes_Link (Free_Task, Vulnerable_Free_Task):
3920         Replace Finalize_Attributes_Link by Finalize_Attributes.
3921         * a-tasatt.ads, a-tasatt.adb, s-tataat.ads, s-tataat.adb:
3922         Reimplement from scratch, using a simpler and more efficient
3923         implementation.
3924         * s-tporft.adb (Register_Foreign_Thread): Remove now obsolete comment.
3925         * s-parame.ads, s-parame-hpux.ads,
3926         * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads,
3927         * s-parame-vxworks.ads (Max_Attribute_Count): New, replace
3928         Default_Attribute_Count.
3930 2014-07-30  Olivier Hainque  <hainque@adacore.com>
3932         * vxworks-ppc-link.spec: New file. Extra link
3933         instructions for ppc-vxworks.
3934         * vxworks-crtbe-link.spec: Likewise, for ZCX related support.
3935         * system-vxworks-ppc.ads: Adjust linker options to use spec files.
3936         * system-vxworks-arm.ads: Likewise.
3937         * gcc-interface/Makefile.in: Enable .spec files.
3939 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3941         * sem_aggr.adb: Minor comment reformatting.
3943 2014-07-30  Robert Dewar  <dewar@adacore.com>
3945         * sem_util.ads, sem_util.adb (Is_Junk_Name): Removed.
3946         * sem_warn.adb (Has_Junk_Name): New function
3947         (Check_References): Use Has_Junk_Name to delete junk warnings
3948         (Check_Unset_Reference): ditto.
3949         (Warn_On_Unreferenced_Entity): ditto.
3950         (Warn_On_Useless_Assignment): ditto.
3952 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3954         * checks.adb (Insert_Valid_Check): Do not check for the packed
3955         array type of a prefix that is an access type.
3957 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
3959         * sem_attr.adb (Eval_Attribute): Evaluate the GNAT attribute
3960         Unconstrained_Array even if prefix is not frozen yet, as can
3961         occur with a private subtype used as a generic actual.
3963 2014-07-30  Gary Dismukes  <dismukes@adacore.com>
3965         * sem_attr.adb: Minor reformatting.
3967 2014-07-30  Pat Rogers  <rogers@adacore.com>
3969         * gnat_rm.texi: Corrected minor wording error in description
3970         of No_Exception_Registration.
3972 2014-07-30  Yannick Moy  <moy@adacore.com>
3974         * einfo.ads, einfo.adb: New flag Is_Inlined_Always for use in GNATprove
3975         mode. Realphabetize two subprograms.
3976         * inline.adb (Cannot_Inline): Use Is_Inlined_Always in GNATprove mode.
3977         (Can_Be_Inlined_In_GNATprove_Mode): Adapt to possible Empty Body_Id.
3978         (Check_And_Build_Body_To_Inline): Use Is_Inlined_Always in GNATprove
3979         mode.
3980         (Expand_Inline_Call): Use Is_Inlined_Always in GNATprove mode.
3981         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Do not use
3982         Is_Inline in GNATprove mode.
3983         (Analyze_Subprogram_Specification):
3984         Set Is_Inlined_Always at subprogram entity creation.
3985         * sem_res.adb (Resolve_Call): Do not deal with inlining during
3986         pre-analysis.  Issue warning on call to possibly inlined
3987         subprogram when body not seen.
3989 2014-07-30  Yannick Moy  <moy@adacore.com>
3991         * lib-xref.adb (Generate_Reference): Add special
3992         case for compiler-generated formals in GNATprove mode.
3994 2014-07-30  Yannick Moy  <moy@adacore.com>
3996         * sem_ch6.adb: Add comments.
3998 2014-07-30  Thomas Quinot  <quinot@adacore.com>
4000         * s-os_lib.ads (GM_Time_Of): Clarify documentation.
4002 2014-07-30  Robert Dewar  <dewar@adacore.com>
4004         * sem_aggr.adb, sem_res.adb: Minor reformatting.
4006 2014-07-30  Thomas Quinot  <quinot@adacore.com>
4008         * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case
4009         Bit_Order): Set Reverse_Bit_Order on the base type of the
4010         specified first subtype.
4012 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4014         * inline.adb (Expand_Inlined_Call): Use a renaming declaration
4015         to capture the value of actuals of a limited type rather than
4016         an object declaration, to prevent spurious errors when analyzing
4017         the inlined body.
4019 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4021         * sem_ch4.adb (Analyze_Type_Conversion): Treat an inlined body
4022         as an instance, and inhibit semantic checks on already analyzed
4023         code to prevent spurious errors.
4025 2014-07-30  Arnaud Charlet  <charlet@adacore.com>
4027         * a-exctra.ads ("="): New function, to restore compatibility.
4029 2014-07-30  Pascal Obry  <obry@adacore.com>
4031         * adaint.c (__gnat_to_os_time): Set isdst to -1 for the mktime
4032         routine to use the OS dst setting.
4034 2014-07-30  Pat Rogers  <rogers@adacore.com>
4036         * gnat_ugn.texi: Minor correction to description of -gnatw.K.
4038 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4040         * sem_util.adb (Wrong_Type): Disable some checks equally within
4041         instances and within inlined bodies, to suppress spurious type
4042         errors on already analyzed code.
4043         * sem_aggr.adb (Check_Expr_OK_In_Limited_Aggregate): Expression
4044         is legal in an inlined body, juts as it is in an instance body.
4046 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4048         * sem_res.adb (Resolve_Unchecked_Conversion): Within an inlined
4049         body the operand of an unchecked conversion may be a literal, in
4050         which case its type is the target type of the conversion. This
4051         is in contrast to conversions in other contexts, where the
4052         operand cannot be a literal and must be resolvable independent
4053         of the context.
4055 2014-07-30  Pierre-Marie Derodat  <derodat@adacore.com>
4057         * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create a
4058         mere scalar constant instead of a reference for a renaming of
4059         scalar literal.
4060         * gcc-interface/utils.c (renaming_from_generic_instantiation_p): New.
4061         * gcc-interface/gigi.h (renaming_from_generic_instantiation_p): New.
4063 2014-07-30  Robert Dewar  <dewar@adacore.com>
4065         * s-tasuti.adb, s-tasuti.ads, einfo.ads, sem_prag.adb, s-taasde.adb,
4066         g-socthi-vms.adb, s-taprop-mingw.adb, s-interr.adb, s-interr-hwint.adb,
4067         g-decstr.adb, s-tasdeb-vms.adb, g-expect-vms.adb, makeutl.adb,
4068         s-interr-vms.adb, g-socthi.adb, exp_aggr.adb, s-tasdeb.adb,
4069         g-awk.adb, gnatls.adb, s-taspri-posix.ads, g-catiio.adb,
4070         s-interr-sigaction.adb, s-os_lib.adb, s-fileio.adb: Minor reformatting
4071         & code reorganization.
4073 2014-07-30  Bob Duff  <duff@adacore.com>
4075         * s-tassta.adb, sem_util.ads: Minor reformatting.
4077 2014-07-30  Yannick Moy  <moy@adacore.com>
4079         * inline.adb (Build_Body_To_Inline): Detect when
4080         subprogram has multiple returns, or not a single last return
4081         statement, in GNATprove mode.
4082         (Cannot_Inline): Simplify logic to handle case of GNATprove
4083         inlining first.
4085 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4087         * sem_ch6.adb: Stubs are not subject to inlining.
4089 2014-07-30  Bob Duff  <duff@adacore.com>
4091         * s-tasuti.ads, s-tasuti.adb (Make_Independent): Change this
4092         from a procedure to a function, so that it can more easily be
4093         called before the "begin" of a task.
4094         * s-taasde.ads (Delay_Block): Make this type immutably limited,
4095         so we can use a build-in-place function call to initialize
4096         Timer_Queue in the body.
4097         * a-rttiev.adb, s-asthan-vms-alpha.adb, s-asthan-vms-ia64.adb,
4098         * s-interr.adb, s-interr-hwint.adb, s-interr-sigaction.adb,
4099         * s-interr-vms.adb, s-taasde.adb: Each independent task now calls
4100         Make_Independent before reaching its "begin", to avoid race
4101         conditions. This causes the activating task to wait until after
4102         Make_Independent is complete before proceeding.  In addition,
4103         we initialize data structures used by independent tasks before
4104         activating those tasks, to avoid possible use of uninitialized data.
4105         * s-interr.ads, s-intman.ads, s-taspri-posix.ads, s-tasdeb.ads:
4106         Minor comment fixes.
4108 2014-07-30  Bob Duff  <duff@adacore.com>
4110         * a-exctra.ads, s-traent-vms.ads, s-traent.ads (Tracebacks_Array): Move
4111         the declaration of Tracebacks_Array from Ada.Exceptions.Traceback to
4112         System.Traceback_Entries (s-traent.ads and s-traent-vms.ads).  Add
4113         subtypes renaming Tracebacks_Array in Ada.Exceptions.Traceback.
4114         * g-debpoo.adb: Refer to Tracebacks_Array in its new home.
4116 2014-07-30  Arnaud Charlet  <charlet@adacore.com>
4118         * a-tasatt.adb: Remove old comments.
4120 2014-07-30  Yannick Moy  <moy@adacore.com>
4122         * einfo.ads (Is_Inlined): Document new use in GNATprove mode.
4123         * inline.adb (Can_Be_Inlined_In_GNATprove_Mode): Add comments
4124         to explain rationale for inlining or not in GNATprove mode.
4125         (Expand_Inlined_Call): In GNATprove mode, set Is_Inlined flag
4126         to False when inlining is not possible.
4127         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Set Is_Inlined
4128         flag to indicate that subprogram is fully inlined. To be reversed
4129         if inlining problem is found.
4130         * sem_res.adb (Resolve_Call): Set Is_Inlined flag to False when
4131         call in potentially unevaluated context.
4133 2014-07-30  Jose Ruiz  <ruiz@adacore.com>
4135         * s-tarest.adb, s-tarest.ads: Fix comments.
4137 2014-07-30  Robert Dewar  <dewar@adacore.com>
4139         * exp_attr.adb, checks.adb, sem_util.adb, sem_util.ads, sem_attr.adb:
4140         Change No_Scalar_Parts predicate to Scalar_Part_Present and
4141         invert sense of test. This avoids the "not No_xxx" situation
4142         which is always ugly.
4144 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4146         * inline.adb (Expand_Inlined_Call): When generating code for
4147         an internal subprogram the expansion uses the location of the
4148         call, so that gdb can skip over it. In GNATprove mode we want to
4149         preserve slocs of original subprogram when expanding an inlined
4150         call, to obtain better warnings, even though subprogram appears
4151         not to come from source if it is the inlining of a subprogram
4152         body without a previous spec.
4154 2014-07-30  Eric Botcazou  <ebotcazou@adacore.com>
4156         * exp_aggr.adb (Aggr_Assignment_OK_For_Backend): Reject array
4157         types with atomic components.
4159 2014-07-30  Thomas Quinot  <quinot@adacore.com>
4161         * Make-generated.in: Remove now unnecessary targets after s-oscons
4162         reorg.
4164 2014-07-30  Yannick Moy  <moy@adacore.com>
4166         * sem_res.adb (Resolve_Call): Use ultimate alias
4167         of callee when available.
4169 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4171         * sem_ch6.adb (Analyze_Expression_Function): To check whether
4172         an expression function is a completion, use the specification of
4173         the previous declaration, not its entity, which may be internally
4174         generated in an inlined context.
4176 2014-07-30  Doug Rupp  <rupp@adacore.com>
4178         * adaint.c (__gnat_tmp_name) [__ANDROID__]: Default to putting
4179         temp files in /cache directory unless overridden by TMPDIR.
4181 2014-07-30  Jose Ruiz  <ruiz@adacore.com>
4183         * s-tassta.adb, s-tarest.adb (Initialize, Create_Task,
4184         Create_Restricted_Task): Remove redundant check. Number_Of_CPUs returns
4185         type CPU, so it can never be greater than CPU_Range'Last.
4187 2014-07-30  Bob Duff  <duff@adacore.com>
4189         * s-taskin.ads: Minor comment fix.
4191 2014-07-30  Thomas Quinot  <quinot@adacore.com>
4193         * g-socket.adb: Remove now useless WITH, USE, and USE TYPE
4194         clauses.
4196 2014-07-30  Yannick Moy  <moy@adacore.com>
4198         * debug.adb: Free debug flag dQ used for frontend inlining in
4199         GNATprove mode..
4200         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Remove test of
4201         debug flag..
4203 2014-07-30  Thomas Quinot  <quinot@adacore.com>
4205         * Make-generated.in: Remove generation of s-oscons.ads, only
4206         generate the xoscons utility, in runtime-agnostic rules.
4207         * gcc-interface/Makefile.in: Clean up rules. Remove VMS parts,
4208         no longer supported.
4210 2014-07-30  Bob Duff  <duff@adacore.com>
4212         * exp_ch6.adb (Add_Task_Actuals_To_Build_In_Place_Call): New
4213         parameter Chain to be used in the allocator case.
4214         (Make_Build_In_Place_Call_In_Allocator): If the allocated object
4215         has tasks, wrap the code in a block that will activate them,
4216         including the usual finalization code to kill them off in case
4217         of exception or abort.
4219 2014-07-30  Robert Dewar  <dewar@adacore.com>
4221         * treepr.adb, treepr.ads; Reorganize documentation for new pp routines
4222         Remove renamings (don't work for gdb).
4223         (par): New synonym for p (avoid gdb ambiguities).
4224         * inline.adb, sem_ch6.adb, sem_ch13.adb: Minor reformatting.
4226 2014-07-30  Bob Duff  <duff@adacore.com>
4228         * exp_ch9.ads, sem_prag.adb, exp_ch4.adb, sem_ch13.adb: Minor comment
4229         fixes.
4230         * treepr.ads, treepr.adb (ppp): Make this debugging routine
4231         accept any type covered by Union_Id.
4233 2014-07-30  Robert Dewar  <dewar@adacore.com>
4235         * sem_ch4.adb (Analyze_If_Expression): Resolve condition before
4236         analyzing branches.
4237         * sem_eval.adb (Out_Of_Range): Check for statically unevaluated
4238         expression case.
4240 2014-07-30  Robert Dewar  <dewar@adacore.com>
4242         * sem_ch13.adb (Analyze_Aspect, predicate cases): Diagnose use
4243         of predicate aspect on entity other than a type.
4245 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4247         * sem_ch6.adb (Body_Has_Contract): New predicate to determine
4248         when a subprogram body without a previous spec cannot be inlined
4249         in GNATprove mode, because it includes aspects or pragmas that
4250         generate a SPARK contract clause.
4251         * inline.adb (Can_Be_Inlined_In_GNATprove_Mode): A subprogram
4252         instance cannot be inlined.
4254 2014-07-30  Robert Dewar  <dewar@adacore.com>
4256         * debug.adb: Document that d7 suppresses compilation time output.
4257         * errout.adb (Write_Header): Include compilation time in
4258         header output.
4259         * exp_intr.adb (Expand_Intrinsic_Call): Add
4260         Compilation_Date/Compilation_Time (Expand_Source_Info): Expand
4261         Compilation_Date/Compilation_Time.
4262         * g-souinf.ads (Compilation_Date): New function
4263         (Compilation_Time): New function.
4264         * gnat1drv.adb (Gnat1drv): Set Opt.Compilation_Time.
4265         * gnat_rm.texi (Compilation_Date): New function
4266         (Compilation_Time): New function.
4267         * opt.ads (Compilation_Time): New variable.
4268         * s-os_lib.ads, s-os_lib.adb (Current_Time_String): New function.
4269         * sem_intr.adb (Compilation_Date): New function.
4270         (Compilation_Time): New function.
4271         * snames.ads-tmpl (Name_Compilation_Date): New entry.
4272         (Name_Compilation_Time): New entry.
4274 2014-07-30  Yannick Moy  <moy@adacore.com>
4276         * inline.adb: Add comment.
4278 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4280         * par-ch4.adb (Is_Parameterless_Attribute): 'Result is a
4281         parameterless attribute, and a postondition can mention an
4282         indexed component or a slice whose prefix is an attribute
4283         reference F'Result.
4285 2014-07-30  Robert Dewar  <dewar@adacore.com>
4287         * sprint.adb (Sprint_Node_Actual, case Object_Declaration):
4288         Avoid bomb when printing package Standard.
4290 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4292         * sem_elab.adb (Check_Internal_Call_Continue): If an elaboration
4293         entity is created at this point, ensure that the name of the
4294         flag is unique, because the subprogram may be overloaded and
4295         other homonyms may also have elaboration flags created on the fly.
4297 2014-07-30  Hristian Kirtchev  <kirtchev@adacore.com>
4299         * sem_attr.adb (Analyze_Array_Component_Update): New routine.
4300         (Analyze_Attribute): Major cleanup of attribute
4301         'Update. The logic is now split into two distinct routines
4302         depending on the type of the prefix. The use of <> is now illegal
4303         in attribute 'Update.
4304         (Analyze_Record_Component_Update): New routine.
4305         (Check_Component_Reference): Removed.
4306         (Resolve_Attribute): Remove the return statement and ??? comment
4307         following the processing for attribute 'Update. As a result,
4308         the attribute now freezes its prefix.
4310 2014-07-30  Javier Miranda  <miranda@adacore.com>
4312         * exp_ch4.adb (Apply_Accessibility_Check): Do
4313         not call Base_Address() in VM targets.
4315 2014-07-30  Yannick Moy  <moy@adacore.com>
4317         * gnat1drv.adb (Adjust_Global_Switches): Set
4318         Ineffective_Inline_Warnings to True in GNATprove mode.
4319         * inline.adb (Cannot_Inline): Prepare new semantics for GNATprove
4320         mode of inlining.
4321         * opt.ads (Ineffective_Inline_Warnings): Add comment that
4322         describes use in GNATprove mode.
4323         * sem_prag.adb (Analyze_Pragma|SPARK_Mode): Ignore
4324         pragma when applied to the special body created for inlining.
4326 2014-07-30  Robert Dewar  <dewar@adacore.com>
4328         * inline.adb, exp_ch4.adb, sinput.adb, sem_ch6.adb, sem_ch13.adb:
4329         Minor reformatting.
4331 2014-07-30  Hristian Kirtchev  <kirtchev@adacore.com>
4333         * aspects.ads Add a comment explaining why SPARK 2014 aspects are
4334         not delayed. Update the delay status of most SPARK 2014 aspects.
4335         * sem_ch13.adb (Analyze_Aspect_Specifications): Update all calls
4336         to Decorate_Aspect_And_Pragma and Insert_Delayed_Pragma to refert
4337         to Decorate and Insert_Pragma. Add various comments concerning
4338         the delay status of several SPARK 2014 aspects. The insertion
4339         of Refined_State now uses routine Insert_After_SPARK_Mode.
4340         (Decorate): New routine.
4341         (Decorate_Aspect_And_Pragma): Removed.
4342         (Insert_Delayed_Pragma): Removed.
4343         (Insert_Pragma): New routine.
4345 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4347         * inline.adb (Expand_Inlined_Call): In GNATprove mode, emit
4348         only a warning, not an error on an attempt to inline a recursive
4349         subprogram.
4351 2014-07-30  Robert Dewar  <dewar@adacore.com>
4353         * g-forstr.adb: Minor code reorganization (use J rather than I
4354         as a variable name).
4355         * gnat_rm.texi, sem_prag.adb, sem_util.adb, sem_ch13.adb,
4356         g-forstr.ads: Minor reformatting.
4358 2014-07-30  Eric Botcazou  <ebotcazou@adacore.com>
4360         * sprint.adb (Set_Debug_Sloc): Also reset the end location if
4361         we are debugging the generated code.
4363 2014-07-30  Yannick Moy  <moy@adacore.com>
4365         * sinput.ads, sinput.adb (Comes_From_Inlined_Body): New function that
4366         returns True for source pointer for an inlined body.
4368 2014-07-30  Javier Miranda  <miranda@adacore.com>
4370         * exp_ch4.adb (Apply_Accessibility_Check): Add
4371         missing calls to Base_Address().
4373 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4375         * sem_ch6.adb (Hanalyze_Subprogram_Body_Helper): In GNATprove
4376         mode, subprogram bodies without a previous declaration are also
4377         candidates for front-end inlining.
4379 2014-07-30  Hristian Kirtchev  <kirtchev@adacore.com>
4381         * aspects.ads Aspects Async_Readers, Async_Writers,
4382         Effective_Reads and Effective_Writes do not need to be delayed.
4383         * sem_ch13.adb (Analyze_Aspect_Specifications): Propagate the
4384         optional Boolean expression when generating the corresponding
4385         pragma for an external property aspect.
4386         * sem_prag.adb (Analyze_External_Property_In_Decl_Part): Remove
4387         local constant Obj. Add local constant Obj_Id. Reimplement the
4388         check which ensures that the related variable is in fact volatile.
4389         (Analyze_Pragma): Reimplement the analysis of external property pragmas.
4390         * sem_util.adb (Is_Enabled): New routine.
4391         (Variable_Has_Enabled_Property): Reimplement the detection of
4392         an enabled external property.
4394 2014-07-30  Sergey Rybin  <rybin@adacore.com frybin>
4396         * gnat_ugn.texi, vms_data.ads: gnatstub: describe generating subunits
4397         for body stubs.
4399 2014-07-30  Pascal Obry  <obry@adacore.com>
4401         * g-forstr.adb, g-forstr.ads: New.
4402         * gnat_rm.texi, impunit.adb Makefile.rtl: Add new unit
4403         GNAT.Formatted_String.
4405 2014-07-30  Eric Botcazou  <ebotcazou@adacore.com>
4407         * exp_aggr.adb (Aggr_Assignment_OK_For_Backend): New predicate.
4408         (Expand_Array_Aggregate): Also enable in-place expansion for
4409         code generated by the compiler.  For an object declaration,
4410         set the kind of the object in addition to its type.  If an
4411         in-place assignment is to be generated and it can be directly
4412         done by the back-end, do not expand the aggregate.
4413         * fe.h (Is_Others_Aggregate): Declare.
4414         * gcc-interface/trans.c
4415         (gnat_to_gnu) <N_Assignment_Statement>: Add support for an
4416         aggregate with a single Others choice on the RHS by means of
4417         __builtin_memset.  Tidy up.
4419 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4421         * gnat_rm.texi: minor reformatting.
4423 2014-07-30  Yannick Moy  <moy@adacore.com>
4425         * sem_ch6.adb (Analyze_Subprogram_Helper_Body): Remove body to inline
4426         in SPARK_Mode Off.
4428 2014-07-30  Robert Dewar  <dewar@adacore.com>
4430         * gnat_rm.texi: Document additional implementation-defined use
4431         of Constrained.
4433 2014-07-30  Robert Dewar  <dewar@adacore.com>
4435         * prj-proc.adb, prj-strt.adb: Update comments.
4437 2014-07-30  Gary Dismukes  <dismukes@adacore.com>
4439         * sinfo.ads, einfo.ads, checks.ads: Minor typo fix and reformatting.
4441 2014-07-30  Vincent Celier  <celier@adacore.com>
4443         * prj-proc.adb (Imported_Or_Extended_Project_From): New Boolean
4444         parameter No_Extending, defaulted to False. When No_Extending
4445         is True, do not look for an extending project.
4446         (Expression): For a variable reference that is not for the current
4447         project, get its Id calling Imported_Or_Extended_Project_From
4448         with No_Extending set to True.
4449         * prj-strt.adb (Parse_Variable_Reference): If a referenced
4450         variable is not found in the current project, check if it is
4451         defined in one of the projects it extends.
4453 2014-07-30  Robert Dewar  <dewar@adacore.com>
4455         * sem_util.adb (Predicate_Tests_On_Arguments): Omit tests for
4456         some additional cases of internally generated routines.
4458 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
4460         * sem_ch10.adb (Analyze_Proper_Body): When compiling for ASIS,
4461         if the compilation unit is a subunit, extend optional processing
4462         to all subunits of the current one. This allows gnatstub to
4463         supress generation of spurious bodies.
4465 2014-07-30  Hristian Kirtchev  <kirtchev@adacore.com>
4467         * a-cbmutr.adb (Insert_Child): Use local variable First to keep
4468         track of the initial element's index within the tree.
4470 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
4472         * a-cbmutr.adb (Allocate_Node): Remove the two parameter version.
4473         (Insert_Child): Add local variable First. Capture the index of the
4474         first node being created to ensure correct cursor construction
4475         later on. Use the three parameter version of Allocate_Node
4476         when creating multiple children as this method allows aspect
4477         Default_Value to take effect (if applicable).
4479 2014-07-29  Eric Botcazou  <ebotcazou@adacore.com>
4481         * exp_aggr.adb (Safe_Slice_Assignment): Remove.
4482         (Expand_Array_Aggregate): For a safe slice assignment, just set
4483         the target and use the common code path.
4485 2014-07-29  Robert Dewar  <dewar@adacore.com>
4487         * sem_util.adb, sem_util.ads, sem_res.adb, exp_ch6.adb: Invert
4488         predicate No_Predicate_Test_On_Arguments, new name is
4489         Predicate_Tests_On_Arguments (with the opposite sense).
4491 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
4493         * sem_attr.adb (Resolve_Attribute): Clean up the code for
4494         attribute 'Access. Do not generate an elaboration flag for a
4495         stand alone expression function. The expression of an expression
4496         function is now frozen when the expression function appears as
4497         the prefix of attribute 'Access.
4498         * sem_ch6.adb (Analyze_Expression_Function): Remove local
4499         variable New_Decl and update all references to it after the
4500         rewriting has taken place. Establish the linkages between the
4501         generated spec and body.
4503 2014-07-29  Robert Dewar  <dewar@adacore.com>
4505         * sem_prag.adb (ip, rv): Prevent from being optimized away.
4506         * gnatls.adb (gnatls): Set E_Fatal exit status if ali file not found.
4507         * s-imgllb.adb, s-imgllw.adb, s-imgwiu.adb, s-imgbiu.adb: Minor
4508         reformatting.
4510 2014-07-29  Vincent Celier  <celier@adacore.com>
4512         * prj-pp.adb: Minor comment update.
4513         * frontend.adb: If a target dependency info file has been read
4514         through switch -gnateT= add it to the dependencies of the source
4515         being compiled.
4517 2014-07-29  Robert Dewar  <dewar@adacore.com>
4519         * sem_ch3.adb, prj.adb: Minor reformatting.
4521 2014-07-29  Vincent Celier  <celier@adacore.com>
4523         * prj-pp.adb (Pretty_Print.Output_Project_File): New
4524         procedure to output project file names between quotes without
4525         concatenation, even if the line is too long.
4526         (Pretty_Print): Use Output_Project_File for project being extended and
4527         project imported.
4529 2014-07-29  Vincent Celier  <celier@adacore.com>
4531         * gnat_ugn.texi: Document that configuration pragmas files are
4532         added to the dependencies, unless they contain only pragmas
4533         Source_File_Name_Project.
4535 2014-07-29  Robert Dewar  <dewar@adacore.com>
4537         * frontend.adb: Minor reformatting.
4539 2014-07-29  Robert Dewar  <dewar@adacore.com>
4541         * exp_ch6.adb (Add_Call_By_Copy_Code): Minor reformatting
4542         (Expand_Actuals): Make sure predicate checks are properly applied
4543         for the case of OUT or IN OUT parameters.
4544         * sem_res.adb: Minor reformatting (Resolve_Actuals): Skip
4545         predicate tests on arguments for Finalize
4546         * sem_util.adb (No_Predicate_Test_On_Arguments): Returns True
4547         if predicate tests on subprogram arguments should be skipped.
4548         * sem_util.ads (No_Predicate_Test_On_Arguments): New function
4550 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
4552         * sem_ch3.adb (Analyze_Object_Declaration): If there is an address
4553         clause for the object and the expression is an aggregate, defer
4554         resolution and expansion of the aggregate until the freeze point
4555         of the entity.
4556         * sem_aggr.adb (Resolve_Aggregate): An others_clause is legal if
4557         the parent node is an N_Reference generated during expansion.
4559 2014-07-29  Vincent Celier  <celier@adacore.com>
4561         * prj.adb (Add_To_Buffer): Effectively double the size of the buffer.
4563 2014-07-29  Robert Dewar  <dewar@adacore.com>
4565         * frontend.adb, inline.adb, sem_util.adb, sem_res.adb,
4566         prepcomp.ads: Minor reformatting and code clean up.
4567         * exp_ch6.adb (Expand_Actuals): Generate predicate test
4568         unconditionally for case of OUT or IN OUT actual (before this
4569         was generated only for certain subcases, which is wrong, the
4570         test is always needed).
4572 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
4574         * sem_ch3.adb: Move Has_Defaulted_Discriminants to sem_util.
4575         * sem_ch4.adb (Analyze_Allocator): Defer resolution of expression
4576         until context type is available.
4577         * sem_res.adb (Resolve_Allocator): In the case of a qualified
4578         expression, complete resolution of expression.
4579         (Check_Aliased_Parameter): New procedure within Resolve_Actuals,
4580         to apply Ada2012 checks on aliased formals, as well as
4581         accesibility checks when the context of the call is an allocator
4582         or a qualified expression.
4583         * sem_util.ads, sem_util.adb (Has_Defaulted_Discriminants):
4584         Moved here from sem_ch3.
4585         (Object_Access_Level): Handle properly aliased formals and
4586         aggregates.
4587         * exp_ch6.adb (Expand_Call): Remove check on aliased parameters,
4588         now properly performed in sem_res (Resolve_Actuals,
4589         Check_Aliased_Parameter).
4591 2014-07-29  Yannick Moy  <moy@adacore.com>
4593         * debug.adb Enable GNATprove inlining under debug flag -gnatdQ for now.
4594         * inline.ads, inline.adb (Can_Be_Inlined_In_GNATprove_Mode): New
4595         function to decide when a subprogram can be inlined in GNATprove mode.
4596         (Check_And_Build_Body_To_Inline): Include GNATprove_Mode as a
4597         condition for possible inlining.
4598         * sem_ch10.adb (Analyze_Compilation_Unit): Remove special case
4599         for Inline_Always in GNATprove mode.
4600         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Build inlined
4601         body for subprograms in GNATprove mode, under debug flag -gnatdQ.
4602         * sem_prag.adb Minor change in comments.
4603         * sem_res.adb (Resolve_Call): Only perform GNATprove inlining
4604         inside subprograms marked as SPARK_Mode On.
4605         * sinfo.ads: Minor typo fix.
4607 2014-07-29  Vincent Celier  <celier@adacore.com>
4609         * frontend.adb: Add dependency on gnat.adc when taken into account
4610         and on non-temporary configuration pragmas files specified in
4611         switches -gnatec.
4612         * prepcomp.ads, prepcomp.adb (Add_Dependency): New procedure to add
4613         dependencies on configuration pragmas files.
4615 2014-07-29  Pat Rogers  <rogers@adacore.com>
4617         * gnat_ugn.texi: Minor clarification to the explanation for the
4618         GNATtest -v switch.
4620 2014-07-29  Robert Dewar  <dewar@adacore.com>
4622         * types.ads (Mechanism_Type): Change range back to -18 .. Int'Last with
4623         documentation that explains the need for this extended range
4624         (use by C_Pass_By_Copy).
4626 2014-07-29  Robert Dewar  <dewar@adacore.com>
4628         * gnat_rm.texi, sem_prag.adb: Minor reformatting.
4630 2014-07-29  Sergey Rybin  <rybin@adacore.com frybin>
4632         * gnat_ugn.texi: gnatmetric: clarify documentation for cyclomatic
4633         complexity metrics.
4635 2014-07-29  Thomas Quinot  <quinot@adacore.com>
4637         PR ada/60652
4638         * s-oscons-tmplt.c: For Linux, define _BSD_SOURCE in order for
4639         CRTSCTS to be visible.
4641 2014-07-29  Bob Duff  <duff@adacore.com>
4643         * g-trasym.adb, g-trasym.ads: Code cleanup.
4645 2014-07-29  Doug Rupp  <rupp@adacore.com>
4647         * sigtramp-vxworks.c: Minor reformatting.
4649 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
4651         * gnat_rm.texi: No doc needed for Ada2012 aspect
4652         Implicit_dereference.
4654 2014-07-29  Robert Dewar  <dewar@adacore.com>
4656         * sem_attr.adb (Attribute_12): New array
4657         (Analyze_Attribute): Check impl-defined Ada 2012 attributes.
4658         (Check_Ada_2012_Attribute): Removed.
4660 2014-07-29  Doug Rupp  <rupp@adacore.com>
4662         * init.c (vxworks6): Call sigtramp for RTP (as well as DKM) for ARM,
4663         PPC, and e500.
4664         * sigtramp-vxworks.c: New file.
4665         * sigtramp-armvxw.c, sigtramp-ppcvxw.c: removed files.
4667 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
4669         * lib-xref.adb (Output_Refs, Check_Type_Reference): For a
4670         derived array type, add information about component type, which
4671         was previously missing in ali file.
4672         * gnat_rm.texi: Add documentation for Atomic_Always_Lock_Free.
4674 2014-07-29  Thomas Quinot  <quinot@adacore.com>
4676         * sem_ch3.adb (Constrain_Corresponding_Record): For the case
4677         of the subtype created for a record component, do not mark
4678         the subtype as frozen. For one thing, this is anomalous (in
4679         particular, the base type might not itself be frozen yet);
4680         furthermore, proper freezing of the subtype must happen in any
4681         case. So, we just mark the subtype as requiring delayed freezing
4682         (and we'll actually freeze it when generating the init_proc of
4683         the enclosing record).
4684         Also change the name of the constrained record subtype (append a
4685         'C' so that it is clearly different from the unconstrained record
4686         type, "related_idV") to make debugging easier.
4687         (Process_Full_View): When creating a full subtype for a pending
4688         private subtype, re-establish the scope of the private subtype
4689         so that we get proper visibility on outer discriminants.
4690         * exp_ch3.adb (Build_Init_Statements): Freeze any component
4691         subtype that is not frozen yet.
4693 2014-07-29  Vincent Celier  <celier@adacore.com>
4695         * prj-proc.adb (Recursive_Process): Always initialize the
4696         environment when the project is an aggregate project, even when
4697         it is not the root tree.
4698 2014-07-29  Robert Dewar  <dewar@adacore.com>
4700         * exp_ch5.adb, exp_ch9.adb: Minor comment additions.
4701         * gnat_rm.texi: Complete list of implementation aspects.
4702         * aspects.ads: Minor comment clarification.
4704 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
4706         * exp_ch5.adb (Expand_N_Assignment_Statement): If the target type
4707         is a null-excluding access type, do not generate a constraint
4708         check if Suppress_Assignment_Checks is set on assignment node.
4709         * exp_ch9.adb (Build_Simple_Entry_Call): If actual is an out
4710         parameter of a null-excluding access type, there is access check
4711         on entry, so set Suppress_Assignment_Checks on generated statement
4712         that assigns actual to parameter block.
4713         * sinfo.ads: Document additional use of Suppress_Assignment_Checks.
4715 2014-07-29  Robert Dewar  <dewar@adacore.com>
4717         * gnat_rm.texi: Change theta to @ in documentation of aspect
4718         Dimension_System.
4720 2014-07-29  Robert Dewar  <dewar@adacore.com>
4722         * sem_attr.adb (Uneval_Old_Msg): Flags Uneval_Old_Accept/Warn
4723         are now on pragma.
4724         * sem_ch13.adb (Analyze_Aspect_Specifications): Remove setting
4725         of Uneval_Old_*
4726         * sem_prag.adb (Analyze_Pragma): Set Uneval_Old_* flags
4727         * sinfo.ads, sinfo.adb: Move Uneval_Old_Accept/Warn to N_Pragma node.
4729 2014-07-29  Javier Miranda  <miranda@adacore.com>
4731         * types.ads Update documentation on how to add new reason codes
4732         for exceptions.
4733         (RT_Exception_Code): Keep values ordered by their
4734         reason code.  Required by the .NET backend.
4735         (RT_CE_Exceptions): Subtype declaration removed.
4736         (RT_PE_Exceptions): Subtype declaration removed.
4737         (RT_SE_Exceptions): Subtype declaration removed.
4738         (Kind): New mapping table of RT_Exception_Codes.
4739         * exp_ch11.adb (Get_RT_Exception_Entity): Updated to use the
4740         new mapping table.
4741         * tbuild.adb (Make_Raise_Storage_Error): Updated to use the new
4742         mapping table.  (Make_Raise_Program_Error): Updated to use the
4743         new mapping table.
4744         (Make_Raise_Storage_Error): Updated to use the new mapping table.
4745         * a-except.adb Keep Rcheck_CE_xxx entities ordered according to
4746         their reason code.
4748 2014-07-29  Thomas Quinot  <quinot@adacore.com>
4750         * gnat_rm.texi: Document internal attributes used for PolyORB/DSA
4751         distributed stubs generation.
4752         * exp_ch3.adb: Minor reformatting.
4754 2014-07-29  Yannick Moy  <moy@adacore.com>
4756         * sinfo.ads: Document constraint between frontend and GNATprove.
4758 2014-07-29  Robert Dewar  <dewar@adacore.com>
4760         * a-except.adb: Minor comment clarification.
4762 2014-07-29  Robert Dewar  <dewar@adacore.com>
4764         * gnat_rm.texi: Complete list of implementation attributes.
4765         * snames.ads-tmpl: Clean up list of impl-defined attributes.
4767 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
4769         * freeze.adb (Freeze_Record_Type): Perform various
4770         volatility-related checks.
4772 2014-07-29  Robert Dewar  <dewar@adacore.com>
4774         * sem_ch3.adb, sem_eval.adb: Minor reformatting.
4776 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
4778         * sem_attr.adb: sem_attr.adb (Access_Attribute): Handle properly
4779         the case where the attribute reference appears in a nested scope
4780         from that of the subprogram prefix.
4781         * sem_attr.adb: Minor reformatting.
4783 2014-07-29  Robert Dewar  <dewar@adacore.com>
4785         * gnat_ugn.texi: Clarify documentation of Initialize_Scalar
4786         initialization options.
4788 2014-07-29  Robert Dewar  <dewar@adacore.com>
4790         * sinfo.ads: Minor comment addition.
4792 2014-07-29  Bob Duff  <duff@adacore.com>
4794         * sem_eval.adb, sem_ch13.adb: Minor reformatting.
4796 2014-07-29  Doug Rupp  <rupp@adacore.com>
4798         * init.c: Complete previous change.
4800 2014-07-29  Robert Dewar  <dewar@adacore.com>
4802         * exp_ch4.adb (Expand_N_If_Expression): Deal with unconstrained
4803         array case.
4805 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
4807         * sem_attr.adb (Access_Attribute): If the prefix is a subprogram
4808         and the completion will appear in the same declarative part,
4809         create elaboration flag.
4810         * exp_util.adb (Set_Elaboration_Flag): If the subprogram body
4811         is a completion of a declaration in the same declarative part,
4812         and the subprogram has had its address taken, add elaboration
4813         check inside the subprogram body, to detect elaboration errors
4814         that may occur through indirect calls.
4816 2014-07-29  Doug Rupp  <rupp@adacore.com>
4818         * sigtramp-armvxw.c: Enhance to handle RTP trampolining.
4819         * init.c: Remove guard on sigtramp for ARM VxWorks RTP.
4821 2014-07-29  Vincent Celier  <celier@adacore.com>
4823         * switch-c.adb (Scan_Front_End_Switches): Do not fail when two
4824         runtime directorie specified with two switches --RTS= designate
4825         the same directory, even when there are no literarily the same.
4827 2014-07-29  Robert Dewar  <dewar@adacore.com>
4829         * gnat_ugn.texi: Minor documentation clarification.
4830         * switch-c.adb: Minor reformatting.
4832 2014-07-29  Robert Dewar  <dewar@adacore.com>
4834         * sem_prag.adb (Analyze_Pragma, case Allow_Integer_Address):
4835         Fix incorrect RTE call which caused bomb if pragma was in
4836         configuration pragma file.
4838 2014-07-29  Jerome Lambourg  <lambourg@adacore.com>
4840         * expect.c (__gnat_expect_poll): Fix typo in previous change.
4841         * g-expect.adb: Update comments.
4843 2014-07-29  Arnaud Charlet  <charlet@adacore.com>
4845         * s-parame-hpux.ads, s-parame-vms-ia64.ads, s-parame.ads
4846         (Default_Attribute_Count): Bump to 16 on native platforms.
4848 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
4850         * sem_res.adb: Add guard to front-end inlining for SPARK.
4852 2014-07-29  Robert Dewar  <dewar@adacore.com>
4854         * sem_ch10.adb, debug.adb, sem_prag.adb, sem_res.adb, sem_ch6.adb:
4855         Minor reformatting.
4857 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
4859         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Build body to
4860         inline in GNATprove mode when subprogran is marked Inline_Always.
4861         * sem_res.adb (Resolve_Call): Expand call in place in GNATProve
4862         mode if body to inline is available.
4863         * sem_prag.adb (Analyze_Pragma, case Inline_Always): Make pragma
4864         effective in GNATprove mode.
4865         * sem_ch10.adb (Analyze_Compilation_Unit): Call
4866         Check_Package_Body_For_Inlining in GNATprove mode, so that body
4867         containing subprograms with Inline_Always can be available before
4868         calls to them.
4870 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
4872         * inline.ads, inline.adb, sem_ch10.adb: Rename Check_Body_For_Inlining
4873         to Check_Package_Body_For_Inlining, to prevent confusion with other
4874         inlining subprograms.
4876 2014-07-29  Robert Dewar  <dewar@adacore.com>
4878         * opt.ads: Minor comment update.
4879         * sem_attr.adb (Uneval_Old_Msg): Deal with case of aspect, where
4880         we want setting of Uneval_Old at time of encountering the aspect.
4881         * sem_ch13.adb (Analyze_Aspect_Specifications): Capture setting
4882         of Opt.Uneval_Old.
4883         * sinfo.adb (Uneval_Old_Accept): New function (Uneval_Old_Warn):
4884         New function (Set_Uneval_Old_Accept): New procedure.
4885         (Set_Uneval_Old_Warn): New procedure.
4886         * sinfo.ads: Uneval_Old_Accept: New flag Uneval_Old_Warn: New flag.
4888 2014-07-29  Robert Dewar  <dewar@adacore.com>
4890         * sinfo.ads, inline.adb, inline.ads, sem_ch6.adb: Minor reformatting.
4891         * snames.ads-tmpl: Minor reformatting.
4892         * xsnamest.adb (XSnamesT): Remove special casing of Name_Error
4893         to give <Error>.  Not clear why this was there, but the compiler
4894         sources do not reference Name_Error, and this interfered with
4895         the circuits for pragma Unevaluated_Use_Of_Old.
4897 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
4899         * sem_prag.adb (Process_Atomic_Shared_Volatile): Allow volatile
4900         types in SPARK 2014 (again).
4901         * sem_res.adb (Is_OK_Volatile_Context): New routine.
4902         (Resolve_Entity_Name): Ensure that a volatile object with
4903         enabled properties Async_Writers or Effectire_Reads appears in
4904         a non-interfering context.
4906 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
4908         * sem_ch6.adb: Move Build_Body_To_Inline,
4909         Check_And_Buid_Body_To_Inline, and Cannot_Inline to package Inline.
4910         * exp_ch6.adb: Mode Expand_Inlined_Body to package Inline.
4911         * inline.ads, inline.adb: Package now contains subprograms that
4912         implement front-end inlining.  No functional changes, no test
4913         needed.
4915 2014-07-29  Robert Dewar  <dewar@adacore.com>
4917         * exp_dbug.adb, g-expect.adb, sem_elab.adb: Minor typo fix.
4919 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
4921         * sem_ch6.adb (Analyze_Return_Type): Reject a return type that
4922         is a limited view when the context is a package body, because
4923         there is no subsequent place at which the non-limited view may
4924         become visible.
4925         (Process_Formals): Ditto.
4926         * sinfo.ads, par-ch3.adb: Minor reformatting.
4928 2014-07-29  Jerome Lambourg  <lambourg@adacore.com>
4930         * expect.c (__gnat_expect_poll): New parameter dead_process
4931         used to return the dead process among the array of file
4932         descriptors. The Windows, VMS and HPUX implementations now
4933         properly report the dead process via this parameter. Other unixes
4934         don't need it.
4935         * g-expect.adb (Poll): Adapt to the C profile.
4936         (Expect_Internal): Use the new parameter to properly close the
4937         File Descriptor.  This then can be properly reported by the
4938         function First_Dead_Process as is expected.
4940 2014-07-29  Robert Dewar  <dewar@adacore.com>
4942         * gnat_ugn.texi: Minor clarification of -gnatQ switch.
4944 2014-07-29  Robert Dewar  <dewar@adacore.com>
4946         * einfo.adb (Derived_Type_Link): New function
4947         (Set_Derived_Type_Link): New procedure.
4948         (Write_Field31_Name): Output Derived_Type_Link.
4949         * einfo.ads: New field Derived_Type_Link.
4950         * exp_ch6.adb (Expand_Call): Warn if change of representation
4951         needed on call.
4952         * sem_ch13.adb: Minor addition of ??? comment.
4953         (Rep_Item_Too_Late): Warn on case that is legal but could cause an
4954         expensive implicit conversion.
4955         * sem_ch3.adb (Build_Derived_Type): Set Derived_Type_Link if needed.
4957 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
4959         * exp_ch3.adb (Build_Init_Procedure): Renamed Local_DF_Id
4960         to DF_Id. Add new local variable DF_Call. Do not perform any
4961         elaboration-related checks on the call to the partial finalization
4962         routine within an init proc to avoid generating bogus elaboration
4963         warnings on expansion-related code.
4964         * sem_elab.adb (Check_A_Call): Move constant Access_Case to
4965         the top level of the routine.  Ensure that Output_Calls takes
4966         into account flags -gnatel and -gnatwl when emitting warnings
4967         or info messages.
4968         (Check_Internal_Call_Continue): Update the call to Output_Calls.
4969         (Elab_Warning): Moved to the top level of routine Check_A_Call.
4970         (Emit): New routines.
4971         (Output_Calls): Add new formal parameter Check_Elab_Flag along with a
4972         comment on usage. Output all warnings or info messages only when the
4973         caller context demands it and the proper elaboration flag is set.
4975 2014-07-29  Yannick Moy  <moy@adacore.com>
4977         * sem_attr.adb (Analyze_Attribute/Attribute_Old):
4978         Check rule about Old appearing in potentially unevaluated
4979         expression everywhere, not only in Post.
4981 2014-07-29  Arnaud Charlet  <charlet@adacore.com>
4983         * sem_prag.adb: Update comment.
4984         * a-except.adb, a-except-2005.adb: Minor editing.
4986 2014-07-29  Pierre-Marie Derodat  <derodat@adacore.com>
4988         * exp_dbug.adb (Debug_Renaming_Declaration):
4989         Do not create renaming entities for renamings of non-packed
4990         objects and for exceptions.
4992 2014-07-29  Robert Dewar  <dewar@adacore.com>
4994         * sem_ch3.adb, sinfo.ads, types.ads, sem_prag.adb, a-except-2005.adb,
4995         sem_ch6.adb, par-ch3.adb: Minor reformatting.
4997 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
4999         * sem_ch6.adb (Check_Return_Subtype_Indication): Reject a return
5000         subtype indication in an extended return statement when the
5001         return value is an ancestor of the return type of the function,
5002         and that return type is a null record extension.
5004 2014-07-29  Thomas Quinot  <quinot@adacore.com>
5006         * sem_ch13.adb (Rep_Item_Too_Late): Specialize/clarify error
5007         message produced for the case of a type-related representation
5008         item that is made illegal by 13.10(1).
5009         * gnat_rm.texi (Scalar_Storage_Order): Minor change in
5010         documentation.
5012 2014-07-29  Robert Dewar  <dewar@adacore.com>
5014         * gnat_ugn.texi: Add section on Wide_Wide_Character encodings.
5015         * erroutc.adb (Output_Error_Msgs): Take wide characters into
5016         account in computing position of error flags.
5017         * sinput.adb (Get_Column_Number): Take wide characters into
5018         account.
5020 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
5022         * par-ch3.adb (P_Access_Type_Definition): The subtype indication
5023         in an access type definition can carry a null_exclusion indicator.
5024         * sem_ch3.adb (Access_Type_Declaration): If the subtype indication
5025         carries a null_exclusion indicator, verify that the subtype
5026         indication denotes an access type, and create a null-excluding
5027         subtype for it.
5028         * sinfo.ads, sinfo.adb: New attribute Null_Excluding_Subtype,
5029         defined on N_Access_To_Object_Definition to indicate that the
5030         subtype indication carries a null_exclusion indicator.
5032 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
5034         * exp_ch6.adb (Add_Extra_Actual): Do not construct
5035         the extra actual by name, generate a reference instead.
5037 2014-07-29  Arnaud Charlet  <charlet@adacore.com>
5039         * sem_prag.adb (Analyze_Pragma): Do not crash analyzing
5040         Allow_Integer_Address if already set.
5041         * a-except-2005.adb (Rcheck_PE_Stream_Operation_Not_Allowed):
5042         Fix order, for consistency with Rmsg_xx declarations.
5044 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
5046         * sem_ch4.adb (Complete_Object_Operation): If the type of the
5047         candidate subprogram is a limited view, use non-limited view
5048         when available.
5050 2014-07-29  Robert Dewar  <dewar@adacore.com>
5052         * sem_ch13.adb: Minor change in RM reference.
5053         * sem_mech.ads: Minor reformatting.
5054         * einfo.ads: Minor comment fix.
5055         * types.ads: Minor correction to range given for Mechanism_Type.
5056         * exp_ch6.adb (Add_Invariant_And_Predicate_Checks): Do not
5057         check predicate on way out for OUT or IN OUT parameters.
5058         * par-ch3.adb (P_Constraint_Opt): Handle missing RANGE keyword
5059         better (P_Range_Constraint): Corresponding fix.
5060         * checks.ads: Minor comment clarification.
5062 2014-07-29  Gary Dismukes  <dismukes@adacore.com>
5064         * sem_ch8.adb (Analyze_Object_Renaming): Set the Is_Volatile
5065         and Treat_As_Volatile flags based on whether the renamed object
5066         is a volatile object.
5068 2014-07-29  Olivier Hainque  <hainque@adacore.com>
5070         * g-debpoo.adb
5071         (Default_Alignment): Rename as Storage_Alignment. This is not
5072         a "default" that can be overriden. Augment comment to clarify
5073         intent and document why we need to manage alignment padding.
5074         (Header_Offset): Set to Header'Object_Size instead of 'Size
5075         rounded up to Storage_Alignment. Storage_Alignment on the
5076         allocation header is not required by our internals so was
5077         overkill. 'Object_Size is enough to ensure proper alignment
5078         of the header address when substracted from a storage address
5079         aligned on Storage_Alignment.
5080         (Minimum_Allocation): Rename as Extra_Allocation, conveying that
5081         this is always added on top of the incoming allocation requests.
5082         (Align): New function, to perform alignment rounding operations.
5083         (Allocate): Add comments on the Storage_Address computation
5084         scheme and adjust so that the alignment padding applies to that
5085         (Storage_Address) only.
5087 2014-07-29  Robert Dewar  <dewar@adacore.com>
5089         * exp_ch3.adb (Default_Initialize_Object): Remove incorrect
5090         pragma Unreferenced.
5091         * cstand.adb (Create_Standard): Use E_Array_Type for standard
5092         string types. Make sure index of Any_String/Any_Array is in a list.
5093         * errout.adb: Minor reformatting.
5095 2014-07-29  Robert Dewar  <dewar@adacore.com>
5097         * gnat_ugn.texi: Clean up and correct documentation of warnings.
5098         * usage.adb: Minor corrections to make sure warnings are properly
5099         documented.
5100         * warnsw.adb (Set_Warning_Switch): Remove redundant return statement.
5101         (WA_Warnings): Add Warn_On_Suspicious_Modulus_Value.
5103 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
5105         * exp_ch3.adb (Expand_N_Object_Declaration): The dummy block
5106         created to match internal sequence numbers between compilations
5107         with/without abort must have its type properly set.
5109 2014-07-29  Robert Dewar  <dewar@adacore.com>
5111         * ali.adb (Initialize_ALI): Initialize SSO_Default_Specified
5112         (Scan_ALI): Set SSO_Default in ALIs_Record (Scan_ALI): Set
5113         SSO_Default_Specified.
5114         * ali.ads (ALIs_Record): Add field SSO_Default
5115         (SSO_Default_Specified): New global switch.
5116         * bcheck.adb (Check_Consistent_SSO_Default): New procedure
5117         (Check_Configuration_Consistency): Call this procedure
5118         * einfo.adb (SSO_Set_High_By_Default): New
5119         function (SSO_Set_Low_By_Default): New function
5120         (Set_SSO_Set_High_By_Default): New procedure
5121         (Set_SSO_Set_Low_By_Default): New procedure (Write_Entity_Flags):
5122         List new flags
5123         * einfo.ads (SSO_Set_Low_By_Default): New flag
5124         (SSO_Set_High_By_Default): New flag
5125         * freeze.adb (Set_SSO_From_Default): New procedure
5126         (Freeze_Array_Type): Call Set_SSO_From_Default
5127         (Freeze_Record_Type): Call Set_SSO_From_Default
5128         * gnat_rm.texi: Document pragma Default_Scalar_Storage_Order
5129         * lib-writ.adb (Write_ALI): Set OL/OH in P line as needed
5130         * lib-writ.ads: Add OL/OH parameters to P line
5131         * opt.adb: Set Default_SSO, Default_SSO_Config as appropriate
5132         * opt.ads (Default_SSO): New global switch (Default_SSO_Config):
5133         New global switch
5134         * repinfo.adb (List_Scalar_Storage_Order): List SSO when it is
5135         set by default using pragma Default_Scalar_Storage_Order.
5136         * sem.ads (Scope_Stack_Entry): Add component Save_Default_SSO
5137         * sem_ch13.adb (Inherit_Delayed_Rep_Aspects):
5138         Clear SSO defaults when explicit SSO is inherited.
5139         (Analyze_Attribute_Definition_Clause): Clear SSO defaults when
5140         explicit SSO is specified.
5141         (Inherit_Aspects_At_Freeze_Point):
5142         Clear SSO default when inheriting SSO.
5143         * sem_ch3.adb (Set_Default_SSO): New procedure
5144         (Analyze_Private_Extension_Declaration): Set defualt SSO
5145         (Array_Type_Declaration): ditto (Build_Derived_Array_Type): ditto
5146         (Build_Derived_Private_Type): ditto (Build_Derived_Record_Type):
5147         ditto (Build_Derived_Type): ditto (Make_Class_Wide_Type): ditto
5148         (Record_Type_Declaration): ditto
5149         * sem_ch8.adb (Pop_Scope): Restore Default_SSO (Push_Scope):
5150         Save Default_SSO
5151         * sem_prag.adb (Analyze_Pragma, case
5152         Default_Scalar_Storage_Order): Set Default_SSO
5154 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
5156         * sem_ch6.adb (Valid_Operator_Definition): Verify that
5157         all parameter have mode IN. This check must be done here for
5158         subprogram instantiations that have operator names, because their
5159         analysis does not follow the same path as that for subprogram
5160         declarations.
5162 2014-07-29  Robert Dewar  <dewar@adacore.com>
5164         * freeze.adb (Freeze_Entity, Concurrent_Type case): Add a guard
5165         to make sure that the Etype of a component of the corresponding
5166         record type is present before trying to freeze it.
5167         * sem_ch5.adb: Minor reformatting.
5169 2014-07-29  Robert Dewar  <dewar@adacore.com>
5171         * exp_attr.adb, types.ads, types.h, exp_ch11.adb, a-except.adb,
5172         a-except-2005.adb: Add new reason code PE_Stream_Operation_Not_Allowed,
5173         and then use it when a stream operation is used from a library generic
5174         when the restriction (No_Streams) is active.
5176 2014-07-29  Thomas Quinot  <quinot@adacore.com>
5178         * projects.texi: Fix minor typo.
5180 2014-07-29  Yannick Moy  <moy@adacore.com>
5182         * sem_attr.adb (Analyze_Attribute): Fix generation of warning.
5184 2014-07-29  Arnaud Charlet  <charlet@adacore.com>
5186         * sem_ch5.adb (Check_Unreachable_Code): Do not remove code in
5187         CodePeer mode.
5189 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
5191         * exp_ch7.adb (Find_Last_Init): Add local variable
5192         Deep_Init_Found. Check the statement immediately following the
5193         declaration if [Deep_]Initialization was not found.
5195 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
5197         * exp_util.adb (Is_Aliased): It appears that
5198         'reference-d and renamed objects still play some role in Boolean
5199         expression with actions and cannot be finalized immediately.
5201 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
5203         * exp_dbug.adb (Qualify_Needed):  For debugging purposes,
5204         Loop names are not part of the full qualification of entity names.
5206 2014-07-29  Robert Dewar  <dewar@adacore.com>
5208         * einfo.adb (Has_Protected): Test base type.
5209         * sem_ch4.adb (Analyze_Allocator): Reorganize code to make sure
5210         that we always properly check No_Protected_Type_Allocators.
5212 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
5214         * sem_util.ads, sem_util.adb (Defining_Entity): Now applies to
5215         loop declarations as well.
5216         * exp_ch5.adb (Expand_Loop_Statement): Apply Qualify_Entity_Names
5217         to an iterator loop, because it may contain local renaming
5218         declarations that require debugging information.
5220 2014-07-29  Robert Dewar  <dewar@adacore.com>
5222         * sem_util.ads, exp_util.adb, sem_attr.adb: Minor reformatting.
5224 2014-07-29  Robert Dewar  <dewar@adacore.com>
5226         * einfo.ads, einfo.adb (Static_Real_Or_String_Predicate): New function
5227         (Set_Static_Real_Or_String_Predicate): New procedure
5228         * sem_ch13.adb (Build_Predicate_Functions): Accomodate static
5229         string predicates (Is_Predicate_Static): Handle static string
5230         predicates.
5231         * sem_eval.adb (Real_Or_String_Static_Predicate_Matches):
5232         New procedure (Check_Expression_Against_Static_Predicate):
5233         Deal with static string predicates, now fully implemented
5234         (Eval_Relational_Op): Allow string equality/inequality as static
5235         if not comes from source.
5237 2014-07-29  Robert Dewar  <dewar@adacore.com>
5239         * sem_aggr.adb, exp_ch5.adb, sem_ch5.adb, exp_util.adb, einfo.adb,
5240         einfo.ads, sem_util.adb, sem_attr.adb, sem_case.adb, sem_eval.adb,
5241         sem_eval.ads, sem_ch13.adb: General cleanup of static predicate
5242         handling. Change name of Discrete_Predicate to
5243         Discrete_Static_Predicate, and replace testing of the presence of this
5244         field by testing the flag Has_Static_Expression.
5246 2014-07-29  Robert Dewar  <dewar@adacore.com>
5248         * gnat_rm.texi: Document pragma Unevaluated_Use_Of_Old.
5249         * opt.adb: Handle Uneval_Old.
5250         * opt.ads (Uneval_Old, Uneval_Old_Config): New variables.
5251         * par-prag.adb: Add dummy entry for pragma Unevaluated_Use_Of_Old.
5252         * sem.ads (Save_Uneval_Old): New field in Scope_Stack_Entry.
5253         * sem_attr.adb (Uneval_Old_Msg): New procedure.
5254         * sem_ch8.adb (Push_Scope): Save Uneval_Old.
5255         (Pop_Scope): Restore Uneval_Old.
5256         * sem_prag.adb (Analyze_Pragma, case Unevaluated_Use_Of_Old):
5257         Implemented.
5258         * snames.ads-tmpl: Add entries for pragma Unevaluated_Use_Of_Old
5259         Add entries for Name_Warn, Name_Allow.
5261 2014-07-29  Robert Dewar  <dewar@adacore.com>
5263         * sem_aggr.adb (Resolve_Array_Aggregate): Change Is_Static_Range
5264         to Is_OK_Static_Range.
5265         * sem_attr.adb (Eval_Attribute): Make sure we properly flag
5266         static attributes (Eval_Attribute, case Size): Handle size of
5267         zero properly (Eval_Attribute, case Value_Size): Handle size of
5268         zero properly.
5269         * sem_ch13.adb: Minor reformatting.
5270         * sem_ch3.adb (Process_Range_Expr_In_Decl): Change
5271         Is_Static_Range to Is_OK_Static_Range.
5272         * sem_eval.adb (Eval_Case_Expression): Total rewrite, was
5273         wrong in several ways (Is_Static_Range): Moved here from spec
5274         (Is_Static_Subtype): Moved here from spec Change some incorrect
5275         Is_Static_Subtype calls to Is_OK_Static_Subtype.
5276         * sem_eval.ads: Add comments to section on
5277         Is_Static_Expression/Raises_Constraint_Error (Is_OK_Static_Range):
5278         Add clarifying comments (Is_Static_Range): Moved to body
5279         (Is_Statically_Unevaluated): New function.
5280         * sem_util.ads, sem_util.adb (Is_Preelaborable_Expression): Change
5281         Is_Static_Range to Is_OK_Static_Range.
5282         * sinfo.ads: Additional commments for Is_Static_Expression noting
5283         that clients should almost always use Is_OK_Static_Expression
5284         instead. Many other changes throughout front end units to obey
5285         this rule.
5286         * tbuild.ads, tbuild.adb (New_Occurrence_Of): Set Is_Static_Expression
5287         for enumeration literal.
5288         * exp_ch5.adb, sem_intr.adb, sem_ch5.adb, exp_attr.adb, exp_ch9.adb,
5289         lib-writ.adb, sem_ch9.adb, einfo.ads, checks.adb, checks.ads,
5290         sem_prag.adb, sem_ch12.adb, freeze.adb, sem_res.adb, exp_ch4.adb,
5291         exp_ch6.adb, sem_ch4.adb, sem_ch6.adb, exp_aggr.adb, sem_cat.adb:
5292         Replace all occurrences of Is_Static_Expression by
5293         Is_OK_Static_Expression.
5295 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
5297         * exp_ch4.adb (Process_Transient_Object): Remove constant
5298         In_Cond_Expr, use its initialization expression in place.
5299         * exp_ch7.adb (Process_Declarations): There is no need to check
5300         that a transient object being hooked is controlled as it would
5301         not have been hooked in the first place.
5302         * exp_util.adb (Is_Aliased): 'Reference-d or renamed transient
5303         objects are not considered aliased when the related context is
5304         a Boolean expression_with_actions.
5305         (Requires_Cleanup_Actions): There is no need to check that a transient
5306         object being hooked is controlled as it would not have been hooked in
5307         the first place.
5309 2014-07-29  Robert Dewar  <dewar@adacore.com>
5311         * errout.adb: Minor reformatting.
5313 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
5315         * exp_ch3.adb (Default_Initialize_Object): Add new variables
5316         Abrt_Blk and Dummy. Generate a dummy temporary when aborts are
5317         not allowed to ensure the symmetrical generation of symbols.
5318         * exp_ch7.adb (Build_Object_Declarations): Remove variables A_Expr
5319         and E_Decl. Add new variables Decl and Dummy. Generate a dummy
5320         temporary when aborts are not allowed to ensure symmertrical
5321         generation of symbols.
5322         * exp_intr.adb (Expand_Unc_Deallocation): Add new variable
5323         Dummy. Generate a dummy temporary when aborts are not allowed
5324         to ensure symmertrical generation of symbols.
5326 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
5328         * exp_dbug.adb (Debug_Renaming_Declaration): For an object
5329         renaming, indicate that the renamed entity itself needs debug
5330         information. This is necessary if that entity is a temporary,
5331         e.g. part of the expansion of an explicit dereference in an
5332         iterator.
5334 2014-07-29  Thomas Quinot  <quinot@adacore.com>
5336         * errout.adb (Set_Error_Posted): When propagating flag to
5337         an enclosing named association, also propagate to the parent
5338         of that node, so that named and positional associations are
5339         treated consistently.
5341 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
5343         * sem_attr.adb (Resolve_Attribute, case 'Update):  Set
5344         Do_Range_Check properly on array component expressions that
5345         have a scalar type. In GNATprove mode, only checks on scalar
5346         components must be marked by the front-end.
5348 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
5350         * sem_res.adb (Resolve_Type_Conversion): If the type of the
5351         expression is a limited view, use the non-limited view when
5352         available.
5354 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
5356         * exp_ch4.adb (Expand_N_Case_Expression): Mark the generated
5357         case statement as coming from a conditional expression.
5358         (Expand_N_If_Expression): Mark the generated if statement as
5359         coming from a conditional expression.
5360         * exp_ch5.adb (Expand_N_Case_Statement): Do not process controlled
5361         objects found in case statement alternatives when the case
5362         statement is actually a case expression.
5363         (Expand_N_If_Statement):
5364         Do not process controlled objects found in an if statement when
5365         the if statement is actually an if expression.
5366         * sinfo.adb (From_Conditional_Expression): New routine.
5367         (Set_From_Conditional_Expression): New routine.
5368         * sinfo.ads Add new semantic flag From_Conditional_Expression and
5369         update related nodes.
5370         (From_Conditional_Expression): New routine along with pragma Inline.
5371         (Set_From_Conditional_Expression): New routine along with pragma Inline.
5373 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
5375         * exp_ch7.adb (Build_BIP_Cleanup_Stmts): Remove
5376         formal parameter Obj_Id and update the comment on usage. Renamed
5377         Obj_Typ to Func_Typ and update all occurrences.
5378         (Find_Last_Init): Remove formal parameter Decl and update the comment
5379         on usage.
5380         Remove local constants Obj_Id and Obj_Typ. Remove local variables
5381         Init_Typ and Is_Conc. Remove the extraction of the initialization type.
5382         (Find_Last_Init_In_Block): Remove formal parameter
5383         Init_Typ and update the comment on usage.
5384         (Is_Init_Call): Remove formal parameter Init_Typ and update the comment
5385         on usage. Check whether the procedure call is an initialization
5386         procedure of either the object type or the initialization type.
5387         (Is_Init_Proc_Of): New routine.
5388         (Process_Object_Declaration): Obj_Id and Obj_Typ are now global to this
5389         routine. Add new variable Init_Typ. Add circuitry to extract the object
5390         type as well as the initialization type.
5392 2014-07-29  Robert Dewar  <dewar@adacore.com>
5394         * sem_case.adb: Minor reformatting.
5395         * sem_aux.ads: Minor reformatting.
5397 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
5399         * sinfo.adb (Set_Else_Actions, Set_Then_Actions): Set parent
5400         pointer on these fields, even though they are semantic, because
5401         subsequent analysis and expansion of action nades may require
5402         exploring the tree, for example to locate a node to be wrapped
5403         when a function with controlled result is called.
5405 2014-07-29  Claire Dross  <dross@adacore.com>
5407         * sem_aux.adb (Get_Binary_Nkind): Use case on
5408         Name_Id instead of an intermediate string.
5409         (Get_Unary_Nkind): Use case on Name_Id instead of an intermediate
5410         string.
5412 2014-07-29  Sergey Rybin  <rybin@adacore.com frybin>
5414         * gnat_ugn.texi (gnatelim, gnatstub, gnatmetric): Add note
5415         about processing sources with preprocessor directives.
5417 2014-07-24  Martin Liska  <mliska@suse.cz>
5419         * gcc-interface/trans.c (finalize_nrv): Adjust function call.
5420         * gcc-interface/utils.c (rest_of_subprog_body_compilation): Likewise.
5421         (gnat_write_global_declarations): Likewise.
5423 2014-07-19  David Wohlferd  <dw@LimeGreenSocks.com>
5425         * gnat_rm.texi: Clean up for makeinfo 5.2.
5427 2014-07-19  David Wohlferd  <dw@LimeGreenSocks.com>
5429         * gnat_rm.texi (Machine Code Insertions): Clean up.
5431 2014-07-18  Robert Dewar  <dewar@adacore.com>
5433         * exp_ch7.adb: Minor reformatting.
5435 2014-07-18  Claire Dross  <dross@adacore.com>
5437         * sem_aux.ads (Get_Binary_Nkind): New function that returns
5438         the Node_Kind value of an entity defining a binary operator.
5439         (Get_Unary_Nkind): New function that returns the Node_Kind value
5440         of an entity defining a unary operator.
5442 2014-07-18  Pascal Obry  <obry@adacore.com>
5444         * sysdep.c: comment update.
5445         * adaint.c (__gnat_fputwc): Use wchar_t on a limited set of
5446         platforms where it is known to be supported.
5448 2014-07-18  Thomas Quinot  <quinot@adacore.com>
5450         * sem_dist.adb (Process_Remote_AST_Declaration): Need
5451         to set Fat_Type's Ekind in order to be able to use its
5452         Corresponding_Remote_Type attribute.
5454 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
5456         * einfo.adb Last_Aggregate_Assignment is now Node 30.
5457         (Last_Aggregate_Assignment): Include
5458         constants in the assertion. Update the underlying node.
5459         (Set_Last_Aggregate_Assignment): Include constants in the
5460         assertion. Update the underlying node.  (Write_Field11_Name):
5461         Remove the entry for Last_Aggregate_Assignment.
5462         (Write_Field30_Name): Add an entry for Last_Aggregate_Assignment.
5463         * einfo.ads Update the node designation and usage of attribute
5464         Last_Aggregate_Assignment.
5465         * exp_aggr.adb (Expand_Array_Aggregate): Store the last
5466         assignment statement used to initialize a controlled object.
5467         (Late_Expansion): Store the last assignment statement used to
5468         initialize a controlled record or an array of controlled objects.
5469         * exp_ch3.adb (Expand_N_Object_Declaration): Default
5470         initialization of objects is now performed in a separate routine.
5471         (Default_Initialize_Object): New routine.
5472         * exp_ch7.adb (Build_BIP_Cleanup_Stmts): Add formal parameter
5473         Obj_Id. Update the comment on usage.
5474         (Find_Last_Init): Remove formal parameter Typ. Update comment on usage.
5475         Reimplement the logic.  (Find_Last_Init_In_Block): New routine.
5476         (Is_Init_Call): Add formal parameter Init_Typ. Update the
5477         comment on usage.  Account for the type init proc when trying
5478         to determine whether a statement is an initialization call.
5479         (Make_Adjust_Call): Rename formal parameter For_Parent to
5480         Skip_Self. Update all occurrences of For_Parent. Account for
5481         non-tagged types. Update the call to Make_Call.
5482         (Make_Call): Rename formal parameter For_Parent to Skip_Self. Update
5483         comment on usage. Update all occurrences of For_Parent.
5484         (Make_Final_Call): Rename formal parameter For_Parent to
5485         Skip_Self. Update all occurrences of For_Parent. Account
5486         for non-tagged types. Update the call to Make_Call.
5487         (Process_Object_Declaration): Most variables and constants are
5488         now local to the routine.
5489         * exp_ch7.ads (Make_Adjust_Call): Rename formal parameter
5490         For_Parent to Skip_Self. Update the comment on usage.
5491         (Make_Final_Call): Rename formal parameter For_Parent to
5492         Skip_Self. Update the comment on usage.
5494 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
5496         * sem_ch9.adb (Analyze_Requeue): The entry being referenced
5497         can be a procedure that is implemented by entry, and have a
5498         formal that is a synchronized interface.  It does not have to
5499         be declared as a protected operation.
5501 2014-07-18  Robert Dewar  <dewar@adacore.com>
5503         * gnat_rm.texi: Remove mention of obsolete attributes
5504         Max[_Interrupt]_Priority, which have never been implemented
5505         (or at the very least were removed long ago if they ever were
5506         implemented.  Add documentation of Max[_Interrupt]_Priority
5507         constants in package System.
5508         * ttypes.ads: Document actual handling of package System,
5509         rather than a historical fantasy version.  Remove mention of
5510         non-existent attributes Max[_Interrupt]_Priority.
5512 2014-07-18  Pascal Obry  <obry@adacore.com>
5514         * a-witeio.adb (Put): No 16-bit character output when text
5515         translation is disabled.
5516         * i-cstrea.ads: Code clean up.
5518 2014-07-18  Robert Dewar  <dewar@adacore.com>
5520         * gnat_rm.texi: Document that Wchar_T_Size and Word_Size are
5521         static attributes.
5523 2014-07-18  Arnaud Charlet  <charlet@adacore.com>
5525         * a-witeio.adb, initialize.c: Update comments. Minor clean ups.
5527 2014-07-18  Pascal Obry  <obry@adacore.com>
5529         * adaint.c: Do not include wchar.h on VxWorks.
5530         * mingw32.h: Remove obsolete definition.
5532 2014-07-18  Pascal Obry  <obry@adacore.com>
5534         * a-textio.adb, a-witeio.adb, a-ztexio.adb: Use C_Streams Default_Text.
5535         * i-cstrea.ads (Content_Encoding): Moved here, add convention C.
5536         * s-ficobl.ads (Content_Encoding): Moved to C_Streams.
5537         * s-fileio.adb (Open): Adjust to use Content_Encoding from C_Streams.
5539 2014-07-18  Pascal Obry  <obry@adacore.com>
5541         * a-textio.adb: Rename Is_Text_File to Text_Encoding.
5542         * a-ztexio.adb: Likewise.
5543         * a-witeio.adb: Likewise.
5544         (Open): Pass file's translation mode to set_text_mode.
5545         * s-ficobl.ads (Content_Encoding): New type.
5546         (Text_Content_Encoding): New subtype.
5547         (AFCB): Rename Is_Text_File to Text_Encoding.
5548         * s-fileio.adb (Open): Handles new text_translation
5549         values. Remove Is_Text_File which is equivalent to Text_Encoding
5550         in Text_Content_Encoding.
5551         * adaint.h (__gnat_set_mode): New routine.
5552         * sysdep.c (__gnat_set_wide_text_mode): Removed.
5553         (__gnat_set_mode): New routine.
5555 2014-07-18  Arnaud Charlet  <charlet@adacore.com>
5557         * gcc-interface/decl.c, gcc-interface/trans.c,
5558         gcc-interface/utils.c (Is_Packed_Array_Type): Renamed 
5559         Is_Packed_Array_Impl_Type.
5561 2014-07-18  Gary Dismukes  <dismukes@adacore.com>
5563         * sem_util.adb: Minor typo correction.
5565 2014-07-18  Ben Brosgol  <brosgol@adacore.com>
5567         * gnat_rm.texi: Complete previous change.
5569 2014-07-18  Pascal Obry  <obry@adacore.com>
5571         * s-fileio.adb: Minor style fix.
5573 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
5575         * sem_ch13.adb (Analyze_Aspect_Specifications): Detect improper
5576         specification of stream attributes for subtypes that are not
5577         first subtypes, to prevent malformed rep_item chains in the case
5578         of such illegal specifications for discriminated private subtypes.
5579         (Check_Overloaded_Name): Verify that the name is an entity name
5580         before other checks.
5582 2014-07-18  Pascal Obry  <obry@adacore.com>
5584         * adaint.c (__gnat_fputwc) Do not disable on cross-build.
5586 2014-07-18  Robert Dewar  <dewar@adacore.com>
5588         * sem_prag.adb, sem_attr.adb,
5589         sem_aggr.adb, sinfo.ads, sem_eval.ads: Minor reformatting.
5591 2014-07-18  Pascal Obry  <obry@adacore.com>
5593         * sysdep.c (__gnat_wide_text_translation_required): Removed from here.
5594         * initialize.c (__gnat_wide_text_translation_required): Defined here.
5596 2014-07-18  Pascal Obry  <obry@adacore.com>
5598         * adaint.c (__gnat_fputwc): New routine.
5599         * s-crtl.ads (fputwc): Now imported as __gnat_fputwc.
5601 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
5603         * einfo.adb: Flag 270 is now used as Stores_Attribute_Old_Prefix.
5604         (Set_Stores_Attribute_Old_Prefix): New routine.
5605         (Stores_Attribute_Old_Prefix): New routine.
5606         (Write_Entity_Flags):
5607         Output flag Stores_Attribute_Old_Prefix.
5608         * einfo.ads Add new flag Stores_Attribute_Old_Prefix along with
5609         comment on usage.
5610         (Set_Stores_Attribute_Old_Prefix): New routine
5611         along with pragma Inline.
5612         (Stores_Attribute_Old_Prefix): New
5613         routine along with pragma Inline.
5614         * exp_attr.adb (Expand_N_Attribute_Reference): Mark the generated
5615         constant which captures the result of attribute 'Old's prefix.
5616         * sem_util.adb (In_Assertion_Expression_Pragma): Recognize a
5617         relocated expression which acted as a prefix of attribute 'Old.
5619 2014-07-18  Bob Duff  <duff@adacore.com>
5621         * s-spsufi.adb (Finalize_And_Deallocate): Set Subpool.Owner to
5622         null before dispatching to Deallocate_Subpool.
5623         * s-stposu.ads (Default_Subpool_For_Pool): Change mode of
5624         parameter of Default_Subpool_For_Pool to 'in out'.
5625         * s-stposu.adb (Set_Pool_Of_Subpool): Use raise expression. Add
5626         a message to the raise.
5627         * sem_util.adb: Minor reformatting.
5629 2014-07-18  Robert Dewar  <dewar@adacore.com>
5631         * sem_util.adb (Check_Expression_Against_Static_Predicate):
5632         Mark expression as non-static if it fails static predicate check,
5633         and issue additional warning.
5635 2014-07-18  Pascal Obry  <obry@adacore.com>
5637         * a-witeio.adb (Put): Control translation based on
5638         wide_text_translation_required.
5639         * adaint.c (CurrentCCSEncoding): New variable.
5640         * initialize.c (__gnat_initialize): On Windows initialize
5641         CurrentCCSEncoding based on values in GNAT_CCS_ENCODING
5642         environment variable.
5643         * mingw32.h (CurrentCCSEncoding): New external.
5644         (__gnat_wide_text_translation_required): Likewise.
5645         * sysdep.c (wide_text_translation_required): New variable.
5646         (__gnat_set_wide_text_mode): Set mode based on CurrentCCSEncoding.
5648 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
5650         * sem_prag.adb (Analyze_Refined_Depends_In_Decl_Part): Remove global
5651         variable Refined_States.  Add global variable Matched_Items.
5652         (Check_Dependency_Clause): Account for dependency
5653         clauses utilizing states with visible null refinements.
5654         (Is_Null_Refined_State): New routine.
5655         (Match_Items): Record each successfully matched item of pragma Depends.
5656         (Record_Item): New routine.
5658 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
5660         * sem_attr.adb (Analyze_Attribute, case 'Update): Set
5661         Do_Range_Check flag on a dynamic index expression used in a
5662         component association in the argument of Update.
5664 2014-07-18  Gary Dismukes  <dismukes@adacore.com>
5666         * einfo.ads, sem_eval.ads, sem_ch13.adb: Minor reformatting.
5668 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
5670         * exp_ch6.adb (Expand_Simple_Function_Return): Redo the marking
5671         of enclosing blocks, loops and the enclosing function using a
5672         parent-based traversal.
5673         * exp_util.adb (Wrap_Statements_In_Block): Suppress the secondary
5674         stack reclamation if the iterator loop contains a return statement
5675         that uses the stack.
5676         * sem_ch5.adb (Analyze_Loop_Statement): There is no need to
5677         patch up the scope stack as the secondary stack management now
5678         takes into account the enclosing function of the iterator loop.
5680 2014-07-18  Robert Dewar  <dewar@adacore.com>
5682         * sem_ch3.adb, g-memdum.ads, i-cstrea.ads: Minor reformatting.
5684 2014-07-18  Robert Dewar  <dewar@adacore.com>
5686         * einfo.adb (Has_Static_Predicate): New function.
5687         (Set_Has_Static_Predicate): New procedure.
5688         * einfo.ads (Has_Static_Predicate): New flag.
5689         * sem_ch13.adb (Is_Predicate_Static): New function
5690         (Build_Predicate_Functions): Use Is_Predicate_Static to reorganize
5691         (Add_Call): Minor change in Sloc of generated expression
5692         (Add_Predicates): Remove setting of Static_Pred, no longer used.
5693         * sem_ch4.adb (Has_Static_Predicate): Removed this function,
5694         replace by use of the entity flag Has_Static_Predicate_Aspect.
5695         * sem_eval.adb (Eval_Static_Predicate_Check): Check real case
5696         and issue warning that predicate is not checked for now.
5697         * sem_eval.ads (Eval_Static_Predicate_Check): Fix comments in
5698         spec.
5699         * sem_util.adb (Check_Expression_Against_Static_Predicate):
5700         Carry out check for any case where there is a static predicate,
5701         and output appropriate message.
5702         * sinfo.ads: Minor comment corrections.
5704 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
5706         * exp_ch3.adb (Expand_Freeze_Record_Type): If the type is derived
5707         from an untagged private type whose full view is tagged, the type
5708         is marked tagged for layout reasons, but it has no dispatch table,
5709         so Set_All_DT_Position must not be called.
5710         * exp_ch13.adb: If the freeze node is for a type internal to a
5711         record declaration, as is the case for a class-wide subtype
5712         of a parent component, the relevant scope is the scope of the
5713         enclosing record.
5715 2014-07-18  Thomas Quinot  <quinot@adacore.com>
5717         * g-memdum.adb, g-memdum.ads: Code clean ups.
5719 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
5721         * sem_prag.adb (Check_Dependency_Clause):
5722         Update the comment on usage. Reimplement the mechanism which
5723         attempts to match a single clause of Depends against one or
5724         more clauses of Refined_Depends.
5725         (Input_Match): Removed.
5726         (Inputs_Match): Removed.
5727         (Is_Self_Referential): Removed.
5728         (Normalize_Clause): Update the call to Split_Multiple_Outputs.
5729         (Normalize_Outputs): Rename variable Split to New_Claue and update
5730         all its occurrences.
5731         (Report_Extra_Clauses): Update the comment on usage.
5732         (Split_Multiple_Outputs): Renamed to Normalize_Outputs.
5734 2014-07-18  Gary Dismukes  <dismukes@adacore.com>
5736         * i-cstrea.ads: Minor reformatting.
5738 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
5740         * exp_util.adb (Wrap_Statements_In_Block): Propagate both
5741         secondary stack-related flags to the generated block.
5742         * sem_ch5.adb (Analyze_Loop_Statement): Update the scope chain
5743         once the loop is relocated in a block.
5745 2014-07-18  Robert Dewar  <dewar@adacore.com>
5747         * repinfo.ads: Add documentation on handling of back annotation
5748         for dynamic case.
5750 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
5752         * sinfo.ads, sinfo.adb (Incomplete_View): New semantic attribute
5753         of full type declaration, denotes previous declaration for
5754         incomplete view of the type.
5755         * sem_ch3.adb (Analyze_Full_Type_Declaration): Set Incomplete_View
5756         of declaration if one is present.
5757         (Replace_Type): When constructing the signature of an inherited
5758         operation, handle properly the case where the operation has a
5759         formal whose type is an incomplete view.
5760         * sem_util.adb (Collect_Primitive_Operations): Handle properly
5761         the case of an operation declared after an incomplete declaration
5762         for a type T and before the full declaration of T.
5764 2014-07-18  Pascal Obry  <obry@adacore.com>
5766         * i-cstrea.ads: Add documentation for set_wide_text_mode.
5768 2014-07-18  Robert Dewar  <dewar@adacore.com>
5770         * a-witeio.adb: Minor code reorganization.
5771         * i-cstrea.ads: Add comment.
5773 2014-07-18  Thomas Quinot  <quinot@adacore.com>
5775         * s-oscons-tmplt.c (NAME_MAX): Minor cleaup and comment
5776         clarifications.
5778 2014-07-18  Robert Dewar  <dewar@adacore.com>
5780         * g-memdum.adb, g-memdum.ads, exp_strm.adb: Minor reformatting.
5782 2014-07-18  Pascal Obry  <obry@adacore.com>
5784         * s-crtl.ads, i-cstrea.ads (fputwc): New routine.
5785         * a-witeio.adb (Put): On platforms where there is translation
5786         done by the OS output the raw text.
5787         (New_Line): Use Put above to properly handle the LM wide characters.
5789 2014-07-18  Thomas Quinot  <quinot@adacore.com>
5791         * g-memdum.adb, g-memdum.ads (Dump): New parameter Prefix, defaulted
5792         to Absolute_Address.
5794 2014-07-18  Eric Botcazou  <ebotcazou@adacore.com>
5796         * opt.ads (Suppress_Back_Annotation): Remove as unused.
5797         * fe.h (Back_Annotate_Rep_Info): Likewise.
5798         (Global_Discard_Names): Likewise.
5800 2014-07-18  Robert Dewar  <dewar@adacore.com>
5802         * sem_ch13.adb (Is_Type_Ref): Check that type name is not
5803         parenthesized.
5805 2014-07-18  Vincent Celier  <celier@adacore.com>
5807         * s-osinte-vms.ads: Fix style errors.
5809 2014-07-18  Thomas Quinot  <quinot@adacore.com>
5811         * s-oscons-tmplt.c (_POSIX_SOURCE): Define in order to get
5812         NAME_MAX and PATH_MAX.
5814 2014-07-18  Bob Duff  <duff@adacore.com>
5816         * exp_strm.adb (Build_Record_Or_Elementary_Input_Function,
5817         Build_Record_Or_Elementary_Output_Procedure): For Input and
5818         Output attributes, do not read/write the discriminants if they
5819         have default values; that will be done by Read/Write.
5821 2014-07-18  Robert Dewar  <dewar@adacore.com>
5823         * sem_aggr.adb, exp_ch5.adb, sem_ch3.adb, layout.adb, sem_type.adb,
5824         exp_util.adb, exp_attr.adb, einfo.adb, einfo.ads, exp_pakd.adb,
5825         checks.adb, exp_pakd.ads, freeze.adb, sem_util.adb, exp_dbug.adb,
5826         exp_dbug.ads, exp_ch4.adb, sem_ch8.adb, exp_aggr.adb, sem_eval.adb,
5827         sem_ch13.adb: Change name Packed_Array_Type to Packed_Array_Impl_Type.
5829 2014-07-18  Robert Dewar  <dewar@adacore.com>
5831         * lib-writ.adb, makeutl.adb, ali.ads: Minor reformatting.
5833 2014-07-18  Vincent Celier  <celier@adacore.com>
5835         * lib-writ.ads: Update documentation about the D lines.
5837 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
5839         * sem_ch13.adb (Replace_Type_References_Generic): Use type entity
5840         as a parameter, rather than its Chars field, in order to locate
5841         freeze node of type. If the predicate or invariant has references
5842         to types other than the one to which the contract applies, these
5843         types must be frozen, and the corresponding predicate functions
5844         created, before that freeze node.
5846 2014-07-18  Robert Dewar  <dewar@adacore.com>
5848         * freeze.adb, einfo.ads, einfo.adb: Minor code reorganization.
5849         * par_sco.adb: Minor reformatting.
5851 2014-07-18  Gary Dismukes  <dismukes@adacore.com>
5853         * exp_ch4.adb (Real_Range_Check): Turn off
5854         the Do_Range_Check flag on the conversion's current Expression
5855         argument rather than on the originally captured Operand node,
5856         as Expression may reflect a rewriting (as in conversions to a
5857         fixed-point type).
5859 2014-07-18  Vincent Celier  <celier@adacore.com>
5861         * ali.adb (Scan_ALI): Set Sdep_Record.Unit_Name, when the unit
5862         is not a subunit.
5863         * ali.ads (Sdep_Record): New component Unit_Name.
5864         * lib-writ.adb (Write_ALI): Write the unit name in D lines.
5865         * makeutl.adb (Check_Source_Info_In_ALI): Return False if a
5866         dependent unit is in a project and the source file name is not
5867         one of its sources.
5869 2014-07-18  Bob Duff  <duff@adacore.com>
5871         * s-addima.ads: Minor: add comment.
5873 2014-07-18  Thomas Quinot  <quinot@adacore.com>
5875         * freeze.adb (Check_Component_Storage_Order): Fix enforcement
5876         of nesting rules for composites with different SSOs.
5878 2014-07-18  Thomas Quinot  <quinot@adacore.com>
5880         * par_sco.adb (Is_Logical_Operator): An If_Expression is not
5881         a proper logical operator.
5882         (Has_Decision): An If_Expression indicates the presence of a decision
5883         although it is not a logical operator.
5885 2014-07-18  Robert Dewar  <dewar@adacore.com>
5887         * gnat_ugn.texi: Remove note that -gnatR not allowed with -gnatc.
5888         * switch-c.adb: Remove prohibition of -gnatR and -gnatc together.
5890 2014-07-18  Eric Botcazou  <ebotcazou@adacore.com>
5892         * sem_ch13.adb (Kill_Rep_Clause): Clear Comes_From_Source flag
5893         on the null statement.
5895 2014-07-18  Thomas Quinot  <quinot@adacore.com>
5897         * adaint.c: Minor comment rewording.
5898         * socket.c: Define macros _REENTRANT and _THREAD_SAFE so that
5899         use of errno in this file is thread safe.
5901 2014-07-18  Arnaud Charlet  <charlet@adacore.com>
5903         * gnat_ugn.texi: Doc clarification.
5904         * sem_ch13.adb (Kill_Rep_Clause): Use Replace not Rewrite.
5905         * sem_ch13.ads: Minor comment update.
5907 2014-07-18  Robert Dewar  <dewar@adacore.com>
5909         * repinfo.ads: Minor comment fix.
5911 2014-07-18  Robert Dewar  <dewar@adacore.com>
5913         * par-prag.adb: Add dummy entry for Default_Scalar_Storage_Order.
5914         * sem_prag.adb: Add dummy implementation of
5915         Default_Scalar_Storage_Order.
5916         * snames.ads-tmpl: Add dummy entry for
5917         Default_Scalar_Storage_Order pragma.
5919 2014-07-18  Robert Dewar  <dewar@adacore.com>
5921         * opt.adb (Tree_Read): Read Address_Is_Private,
5922         Ignore_Rep_Clauses, Ignore_Style_Check_Pragmas, Multiple_Unit_Index.
5923         (Tree_Write): Corresponding writes
5924         * opt.ads: Minor comment reformatting and fixes.
5925         * tree_io.ads: Increment ASIS_Version_Number.
5927 2014-07-18  Robert Dewar  <dewar@adacore.com>
5929         * sem_attr.adb, s-os_lib.ads, prj-tree.adb: Minor reformatting.
5930         * types.h: Fix typo.
5932 2014-07-18  Robert Dewar  <dewar@adacore.com>
5934         * freeze.adb (Check_Address_Clause): Use Kill_Rep_Clause (no
5935         functional change).
5936         * gnat_ugn.texi: Document that -gnatI removes rep clauses from
5937         ASIS trees.
5938         * sem_ch13.adb (Kill_Rep_Clause): New procedure
5939         (Analyze_Attribute_Definition_Clause): Use
5940         Kill_Rep_Clause. This is just a cleanup, no functional effect.
5941         (Analyze_Enumeration_Representation_Clause):
5942         Use Kill_Rep_Clause. This means that enum rep
5943         clauses are now properly removed from -gnatct trees.
5944         (Analyze_Record_Representation_Clause): Same change.
5945         * sem_ch13.ads (Kill_Rep_Clause): New procedure.
5947 2014-07-18  Pascal Obry  <obry@adacore.com>
5949         * s-os_lib.ads, s-os_lib.adb (GM_Time_Of): New routine to create an
5950         OS_Time from time parts.
5951         * adaint.h, adaint.c (__gnat_to_os_time): New routine.
5953 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
5955         * sem_ch4.adb (Try_Container_Indexing): Refine previous patch for
5956         indexing over containers that are derived types: check whether
5957         signature of found operation has the correct first parameter
5958         before retrieving directly a primitive operation.
5960 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
5962         * sem_attr.adb (Analyze_Attribute, case 'Update): Set
5963         Do_Range_Check flag on dynamic bounds of a range used in a
5964         component association in the argument of Update.
5966 2014-07-18  Thomas Quinot  <quinot@adacore.com>
5968         * adaint.c: #define _REENTRANT and _THREAD_SAFE in order for
5969         accesses to errno(3) to be thread safe.
5971 2014-07-18  Vincent Celier  <celier@adacore.com>
5973         * prj-tree.adb (Imported_Or_Extended_Project_Of): For each non
5974         limited imported project that is an extending project, return
5975         a project being extended if it has the expected name.
5977 2014-07-18  Pascal Obry  <obry@adacore.com>
5979         * s-os_lib.ads, s-os_lib.adb (Set_File_Last_Modify_Time_Stamp): New
5980         routine to set the last modification time stamp for the given file.
5981         * gnatchop.adb (File_Time_Stamp): Removed.
5982         (Write_Unit): Use
5983         Set_File_Last_Modify_Time_Stamp instead of ad-hoc implementation.
5985 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
5987         * sem_aggr.adb (Aggregate_Constraint_Checks): Moved to sem_util.
5988         * sem_util.ads, sem_util.adb (Aggregate_Constraint_Checks):
5989         Moved here, so it can be shared with the resolution of 'Update,
5990         whose argument shares some features with aggregates.
5991         * sem_attr.adb (Resolve_Attribute, case 'Update): Apply
5992         Aggregate_Constraint_Checks with the expression of each
5993         association, so that the Do_Range_Check flag is set when needed.
5995 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
5997         * sem_ch4.adb (Try_Container_Indexing):  If the container
5998         type is a derived type, the value of the inherited  aspect is
5999         the Reference operation declared for the parent type. However,
6000         Reference is also a primitive operation of the new type, and
6001         the inherited operation has a different signature. We retrieve
6002         the right one from the list of primitive operations of the
6003         derived type.
6005 2014-07-18  Vincent Celier  <celier@adacore.com>
6007         * debug.adb: Update comment.
6009 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
6011         * exp_util.adb (Needs_Finalization): There is no reason why a
6012         C type should not benefit from finalization actions.
6014 2014-07-18  Thomas Quinot  <quinot@adacore.com>
6016         * s-oscons-tmplt.c (NAME_MAX): Fix definition for Solaris
6017         (FILENAME_MAX): Remove unneeded definition.
6019 2014-07-18  Robert Dewar  <dewar@adacore.com>
6021         * exp_attr.adb, debug.adb: Update comments.
6023 2014-07-18  Vincent Celier  <celier@adacore.com>
6025         * par-ch4.adb (Simple_Expression): Add missing style check
6026         for binary adding operators.
6027         (Term): Add missing style check for multiplying operators.
6029 2014-07-18  Robert Dewar  <dewar@adacore.com>
6031         * impunit.adb: Minor comment correction.
6032         * widechar.adb, s-wchcon.ads: Minor comment corrections.
6034 2014-07-18  Robert Dewar  <dewar@adacore.com>
6036         * sem_ch13.adb (Build_Discrete_Static_Predicate): New name
6037         for Build_Static_Predicate (Build_Predicate_Functions):
6038         Don't try to build discrete predicate for real type.
6039         (Build_Predicate_Functions): Report attempt to use
6040         Static_Predicate function on real type as unimplemented.
6041         * sem_util.adb (Check_Expression_Against_Static_Predicate):
6042         Add guard to prevent blow up on predicate for real type.
6044 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
6046         * einfo.adb (Set_Static_Predicate): Simplify assertion to handle
6047         properly static predicate on enumeration types and modular types
6048         (not subtypes).
6050 2014-07-18  Pierre-Marie Derodat  <derodat@adacore.com>
6052         * scos.ads (SCO_Unit_Table_Entry): Add a field to keep track of
6053         the corresponding source file index.
6054         * get_scos.ads (Get_SCOs): Add a default value for it.
6055         * par_sco.adb (SCO_Record): Fill the corresponding value.
6056         * scos.h: New.
6058 2014-07-18  Vincent Celier  <celier@adacore.com>
6060         * a-strunb-shared.adb, s-auxdec.ads, s-rannum.adb, atree.ads,
6061         urealp.adb, vms_data.ads, lib.ads, s-auxdec-vms_64.ads: Minor
6062         reformatting.
6063         * gnat_ugn.texi: Add documentation for new gnatmem switch -t.
6065 2014-07-18  Thomas Quinot  <quinot@adacore.com>
6067         * g-sercom.ads (Set): document possible data loss.
6069 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
6071         * exp_attr.adb (Expand_N_Attribute_Reference, cases Input,
6072         Output, Read, Write): If the restriction No_Streams is active,
6073         replace each occurrence of a stream attribute by an explicit
6074         Raise statement.
6076 2014-07-18  Robert Dewar  <dewar@adacore.com>
6078         * par_sco.adb, a-reatim.ads, exp_attr.adb, sem_util.adb: Minor
6079         reformatting.
6081 2014-07-18  Robert Dewar  <dewar@adacore.com>
6083         * einfo.ads, einfo.adb (Has_Out_Or_In_Out_Parameter): New flag and
6084         function.
6085         (Set_Has_Out_Or_In_Out_Parameter): New procedure.
6086         * sem_ch6.adb (Set_Formal_Mode): Set Has_Out_Or_In_Out_Parameter flag.
6087         * sem_res.adb (Resolve_Call): Error if call of Ada 2012 function
6088         with OUT or IN OUT from earlier Ada mode (e.g. Ada 2005)
6090 2014-07-18  Robert Dewar  <dewar@adacore.com>
6092         * bcheck.adb (Check_Consistent_Restrictions):
6093         Remove obsolete code checking for violation of
6094         No_Standard_Allocators_After_Elaboration (main program)
6095         * bindgen.adb (Gen_Adainit): Handle
6096         No_Standard_Allocators_After_Elaboration
6097         (Gen_Output_File_Ada): ditto.
6098         * exp_ch4.adb (Expand_N_Allocator): Handle
6099         No_Standard_Allocators_After_Elaboration.
6100         * Makefile.rtl: Add entry for s-elaall
6101         * rtsfind.ads: Add entry for Check_Standard_Allocator.
6102         * s-elaall.ads, s-elaall.adb: New files.
6103         * sem_ch4.adb (Analyze_Allocator): Handle
6104         No_Standard_Allocators_After_Elaboration.
6106 2014-07-18  Robert Dewar  <dewar@adacore.com>
6108         * lib.adb, lib.ads, lib-writ.adb, lib-writ.ads, ali.adb,
6109         ali.ads, lib-load.adb: Remove Lib.Has_Allocator and all uses.
6110         Remove AB parameter from ali files and all uses.
6111         Remove Allocator_In_Body and all uses.
6113 2014-07-18  Robert Dewar  <dewar@adacore.com>
6115         * g-expect-vms.adb: Add comment.
6117 2014-07-18  Thomas Quinot  <quinot@adacore.com>
6119         * par_sco.adb (Is_Logical_Operation): return True for
6120         N_If_Expression.
6122 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
6124         * sem_attr.adb (Resolve_Attribute, case 'Update): Do full
6125         analysis and resolution of each choice in the associations within
6126         the argument of Update, because they may be variable names.
6128 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
6130         * exp_attr.adb (Expand_Loop_Entry_Attribute): Insert any condition
6131         actions before the generated if statement.
6133 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
6135         * gnat_ugn.texi Enhance the documentation of
6136         switches -gnateA and -gnateV.
6138 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
6140         * sem_util.adb (Build_Default_Subtype): Add missing condition
6141         so that code matches description: use the full view of the base
6142         only if the base is private and the subtype is not.
6144 2014-07-17  Gary Dismukes  <dismukes@adacore.com>
6146         * exp_disp.adb: Minor reformatting.
6147         * exp_disp.adb: Minor code reorganization.
6149 2014-07-17  Thomas Quinot  <quinot@adacore.com>
6151         * gnat_rm.texi, freeze.adb (Check_Component_Storage_Order): Do not
6152         require an explicit SSO attribute definition clause on a composite type
6153         just because one of its components has one.
6155 2014-07-17  Robert Dewar  <dewar@adacore.com>
6157         * sem_attr.adb (Analyze_Attribute, case Loop_Entry): Rewrite
6158         attribute out of existence if the enclosing pragma is ignored.
6159         * sem_util.adb: Minor reformatting.
6161 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
6163         * exp_aggr.adb (Expand_Array_Aggregate): Handle properly an
6164         array aggregate expanded into assignments when it appears as a
6165         local declaration in an inlined body.
6167 2014-07-17  Doug Rupp  <rupp@adacore.com>
6169         * init.c [__ANDROID__]: Modify for ZCX.
6170         * exp_aggr.adb: Minor reformatting
6171         * sigtramp-armvxw.c, sigtramp-ppcvxw.c: Update comments.
6173 2014-07-17  Robert Dewar  <dewar@adacore.com>
6175         * a-strunb-shared.ads, a-stwiun-shared.ads, a-stzunb-shared.ads,
6176         exp_ch7.adb, g-pehage.ads, g-socket.ads, gnat_ugn.texi, gnat_ugx.texi,
6177         scng.adb: Remove incorrect usage "allow to" and "allows to".
6179 2014-07-17  Robert Dewar  <dewar@adacore.com>
6181         * exp_dist.adb: Minor reformatting.
6183 2014-07-17  Bob Duff  <duff@adacore.com>
6185         * gnat_ugn.texi: Improve documentation of Unrestricted_Access.
6187 2014-07-17  Robert Dewar  <dewar@adacore.com>
6189         * sem_ch13.adb (Build_Invariant_Procedure): Add variable Nam
6190         (Add_Invariants): Set Nam to Name_Type_Invariant if from aspect.
6192 2014-07-17  Thomas Quinot  <quinot@adacore.com>
6194         * exp_pakd.adb (Create_Packed_Array_Type.Install_PAT): For a
6195         non-bit-packed array, propagate Reverse_Storage_Order to the
6196         packed array type.
6198 2014-07-17  Javier Miranda  <miranda@adacore.com>
6200         * exp_disp.adb: Fix comment.
6201         * exp_pakd.adb: Minor reformatting.
6203 2014-07-17  Robert Dewar  <dewar@adacore.com>
6205         * bindgen.adb (Gen_Elab_Calls): Skip reference to elab
6206         entity if none exists (Gen_Elab_Calls): Complain if clash with
6207         No_Multiple_Elaboration.
6208         * s-rident.ads, restrict.ads: Add restriction No_Multiple_Elaboration.
6209         * sem_util.adb (Build_Elaboration_Entity): Skip building entity
6210         if not needed.
6211         * gnat_rm.texi: Document restriction No_Multiple_Elaboration.
6212         * sem_ch4.adb: Minor comment updates.
6214 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
6216         * exp_ch9.adb (Buid_Protected_Subprogram_Call): Preserve type
6217         of function call for later use when shared passive objects
6218         are involved.
6220 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
6222         * par-ch13.adb (Get_Aspect_Specifications):
6223         Catch a case where the argument of SPARK aspect Refined_State
6224         is not properly parenthesized.
6226 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
6228         * exp_ch6.adb (Expand_Ctrl_Function_Call): Do not extend
6229         the lifetime of a reference to an Ada 2012 container element.
6230         (Is_Element_Reference): New routine.
6232 2014-07-17  Robert Dewar  <dewar@adacore.com>
6234         * ali.ads: Minor comment fix.
6235         * lib-writ.adb: Minor reformatting.
6237 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
6239         * sem_ch10.adb (Analyze_Proper_Body): When analyzing a subunit
6240         in ASIS mode, load another subunit only if it a subunit of the
6241         current one, not a sibling that has been reached through the
6242         analysis of an ancestor. This allows the construction of the
6243         ASIS tree for the subunit even when sibling subunits have errors.
6245 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
6247         * sem_ch3.adb (Analyze_Declarations): Remove the guard which
6248         prevents the analysis of various contracts when the associated
6249         construct is erroneous.
6250         * sem_util.adb (Save_SPARK_Mode_And_Set): Do not query the
6251         SPARK_Pragma of an illegal or a partially decorated construct.
6253 2014-07-17  Robert Dewar  <dewar@adacore.com>
6255         * s-imguns.ads: Minor reformatting.
6257 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
6259         * exp_ch7.adb (Build_Finalization_Master): Move all local
6260         variables to the proper code section. When looking for an existing
6261         finalization master, inspect the ultimate ancestor type of the
6262         full view.
6263         * sem_util.ads, sem_util.adb (Root_Type_Of_Full_View): New routine.
6265 2014-07-17  Robert Dewar  <dewar@adacore.com>
6267         * aspects.ads, aspects.adb: Add entries for aspect Annotate.
6268         * gnat_rm.texi: Document Entity argument for pragma Annotate and
6269         Annotate aspect.
6270         * sem_ch13.adb (Analyze_Aspect_Specification): Add processing
6271         for Annotate aspect.
6272         * sem_prag.adb (Analyze_Pragma, case Annotate): Allow optional
6273         Entity argument at end.
6274         * sinfo.ads (N_Aspect_Specification): Add note on Annotate aspect.
6276 2014-07-17  Tristan Gingold  <gingold@adacore.com>
6278         * s-imguns.ads: Fix minor typo.
6280 2014-07-17  Thomas Quinot  <quinot@adacore.com>
6282         * sprint.adb: Minor reformatting.
6284 2014-07-17  Robert Dewar  <dewar@adacore.com>
6286         * sprint.adb (Write_Itype): Print proper header for string
6287         literal subtype.
6289 2014-07-17  Steve Baird  <baird@adacore.com>
6291         * sinfo.ads, sem_scil.ads: Improve comments, minor reformatting.
6293 2014-07-17  Vincent Celier  <celier@adacore.com>
6295         * gnatbind.adb: Change in message "try ... for more information".
6297 2014-07-17  Robert Dewar  <dewar@adacore.com>
6299         * sprint.adb: Code clean up.
6301 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
6303         * exp_ch7.adb (Find_Last_Init): Relocate local variables to
6304         the relevant code section. Add new local constant Obj_Id. When
6305         a limited controlled object is initialized by a function call,
6306         the build-in-place object access function call acts as the last
6307         initialization statement.
6308         * exp_util.adb (Is_Object_Access_BIP_Func_Call): New routine.
6309         (Is_Secondary_Stack_BIP_Func_Call): Code reformatting.
6310         * exp_util.ads (Is_Object_Access_BIP_Func_Call): New routine.
6312 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
6314         * sem_ch8.adb (Analyze_Generic_Renaming): For generic subprograms,
6315         propagate intrinsic flag to renamed entity, to allow e.g. renaming
6316         of Unchecked_Conversion.
6317         * sem_ch3.adb (Analyze_Declarations): Do not analyze contracts
6318         if the declaration has errors.
6320 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
6322         * a-rbtgbk.adb: a-rbtgbk.adb (Generic_Insert_Post): Check whether
6323         container is busy before checking whether capacity allows for
6324         a further insertion. Insertion in a busy container that is full
6325         raises Program_Error rather than Capacity_Error. Previous to that
6326         patch which exception was raised varied among container types.
6328 2014-07-17  Robert Dewar  <dewar@adacore.com>
6330         * g-comlin.ads, g-comlin.adb: Minor clean up.
6332 2014-07-17  Bob Duff  <duff@adacore.com>
6334         * gnat_ugn.texi: Update gnatpp doc.
6336 2014-07-17  Robert Dewar  <dewar@adacore.com>
6338         * gnat_rm.texi: Document new restriction No_Long_Long_Integers.
6339         * exp_ch4.adb (Make_Array_Comparison_Op): Add note that we
6340         could do this by actually expanding a real generic.
6341         * a-tags.ads: Add comments about performance.
6342         * sprint.adb (Sprint_Node_Actual, case N_Object_Declaration):
6343         Print Etype of defining identifier, rather than the object
6344         definition. More information.
6346 2014-07-17  Thomas Quinot  <quinot@adacore.com>
6348         * exp_dist.adb: Minor documentation clarification.
6350 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
6352         * exp_util.adb (Is_Aliased): Revert previous change.
6354 2014-07-17  Vincent Celier  <celier@adacore.com>
6356         * g-comlin.adb (Try_Help): New procedure.
6357         (Getopt): Use new procedure Try_Help.
6358         * g-comlin.ads (Try_Help): New procedure.
6360 2014-07-17  Bob Duff  <duff@adacore.com>
6362         * gnat_ugn.texi: Minor update.
6364 2014-07-17  Robert Dewar  <dewar@adacore.com>
6366         * gnat_rm.texi: Improve documentation of Unrestricted_Access.
6367         * sinfo.ads: Document restriction on aggregates (must expand to
6368         assignments if one or more assignments needs expansion, e.g. for
6369         controlled types).
6370         * sem_ch13.adb: All warning messages regarding bit order should
6371         be info: messages.
6372         * gnat_ugn.texi: Minor correction of missing @ on @code
6374 2014-07-17  Robert Dewar  <dewar@adacore.com>
6376         * restrict.ads (Implementation_Restriction): Add No_Long_Long_Integer.
6377         * s-rident.ads (Partition_Boolean_Restrictions): Add
6378         No_Long_Long_Integer.
6379         * sem_ch3.adb (Modular_Type_Declaration): Size must be <=
6380         Long_Integer'Size if restriction No_Long_Long_Integer is active.
6381         (Signed_Integer_Type_Declaration): Do not allow Long_Long_Integer
6382         as the implicit base type for a signed integer type declaration
6383         if restriction No_Long_Long_Integer is active.
6384         * sem_util.ads, sem_util.adb (Set_Entity_With_Checks): Include check for
6385         No_Long_Long_Integer.
6387 2014-07-17  Robert Dewar  <dewar@adacore.com>
6389         * sem_ch3.adb, a-ztexio.ads, exp_imgv.adb, casing.adb, casing.ads,
6390         einfo.ads, checks.adb, sem_ch12.adb, a-textio.ads, freeze.adb,
6391         repinfo.adb, exp_ch6.adb, sem_ch4.adb, a-witeio.ads, sem_ch8.adb,
6392         sem_warn.adb, exp_aggr.adb, exp_dist.adb, par-tchk.adb, s-fatgen.adb,
6393         treepr.adb, lib-xref.adb: Remove the word kludge from ada sources.
6395 2014-07-17  Robert Dewar  <dewar@adacore.com>
6397         * debug.adb: Remove -gnatdQ.
6398         * exp_disp.adb: Remove -gnatdQ.
6399         * a-ztenio.ads, a-wtinio.ads, a-wtmoio.ads, a-ztcoau.ads, a-tiinio.ads,
6400         a-wtfiio.ads, a-timoio.ads, sem_ch12.adb, a-tifiio.ads, a-ztinio.ads,
6401         rtsfind.adb, rtsfind.ads, a-ztmoio.ads, a-wtdeio.ads, a-ztfiio.ads,
6402         a-tideio.ads, a-wtflio.ads, a-ztdeio.ads, sem_ch8.adb, a-tiflio.ads,
6403         sprint.adb, a-ztflio.ads, snames.ads-tmpl, a-wtenio.ads,
6404         a-tienio.ads: Rename Text_IO_Kludge to Text_IO_Special_Unit.
6406 2014-07-17  Robert Dewar  <dewar@adacore.com>
6408         * back_end.adb: Minor reformatting and comment additions.
6409         * checks.ads, checks.adb (Duplicated_Tag_Checks_Suppressed): New
6410         function.
6411         * exp_disp.adb (Make_DT): Use Duplicated_Tag_Checks_Suppressed.
6412         (Make_VM_TSD): Use Duplicated_Tag_Checks_Suppressed.
6413         * gnat_rm.texi: Document new check Duplicated_Tag_Checks_Suppressed.
6414         * gnat_ugn.texi: Additional documentation for Duplicated_Tag_Check.
6415         * snames.ads-tmpl (Duplicated_Tag_Checks_Suppressed): New check.
6416         * types.ads (Duplicated_Tag_Checks_Suppressed): New check.
6418 2014-07-17  Robert Dewar  <dewar@adacore.com>
6420         * gnat_rm.texi: Minor comment updates.
6422 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
6424         * sem_util.adb (Make_Explicit_Dereference): If the expression
6425         being dereferenced is a generalized indexing, reset the overloaded
6426         flag on the generalized indexing call, consistent with the
6427         resetting of the flag on the original indexed component.
6429 2014-07-17  Robert Dewar  <dewar@adacore.com>
6431         * gnat_ugn.texi: Document advise not to mix -gnatV? and
6432         optimization.
6434 2014-07-17  Robert Dewar  <dewar@adacore.com>
6436         * checks.adb (Insert_Valid_Check): Don't insist on a name
6437         for the prefix when we make calls to Force_Evaluation and
6438         Duplicate_Subexpr_No_Checks.
6439         * exp_util.adb (Is_Volatile_Reference): Handle all cases properly
6440         (Remove_Side_Effects): Handle all volatile references right
6441         (Side_Effect_Free): Volatile reference is never side effect free
6442         * sinfo.ads (N_Attribute_Reference): Add comments explaining
6443         that in the tree, the prefix can be a general expression.
6445 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
6447         * sem_ch6.adb (Analyze_Subprogram_Body_Contract,
6448         Analyze_Subprogram_Contract): Add comments on SPARK_Mode save/restore.
6449         * sem_ch7.adb (Analyze_Package_Body_Contract,
6450         Analyze_Package_Contract): Add comments on SPARK_Mode save/restore.
6452 2014-07-17  Robert Dewar  <dewar@adacore.com>
6454         * exp_ch7.ads, exp_util.ads: Document Insert_Action_After,
6455         Store_After_Actions_In_Scope.
6457 2014-07-17  Robert Dewar  <dewar@adacore.com>
6459         * sem_aux.ads: Minor comment addition.
6461 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
6463         * sem_res.adb (Make_Call_Into_Operator): If the call is already
6464         a rewriting of an operator node, there are no actuals to be
6465         propagated from original node to rewritten node when in ASIS mode.
6467 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
6469         * sem_ch6.adb (Analyze_Subprogram_Body_Contract,
6470         Analyze_Subprogram_Contract): Add new local variable Mode. Save
6471         and restore the SPARK mode of the related construct in a
6472         stack-like fashion.
6473         * sem_ch7.adb (Analyze_Package_Body_Contract,
6474         Analyze_Package_Contract): Add new local variable Mode. Save and
6475         restore the SPARK mode of the related construct in a stack-like fashion.
6476         * sem_util.adb Remove with and use clause for Opt.
6477         (Restore_SPARK_Mode): New routine.
6478         (Save_SPARK_Mode_And_Set): New routine.
6479         * sem_util.ads Add with and use clause for Opt.
6480         (Restore_SPARK_Mode): New routine.
6481         (Save_SPARK_Mode_And_Set): New routine.
6483 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
6485         * exp_util.adb (Is_Aliased): Transient objects
6486         within an expression with actions cannot be considered aliased.
6488 2014-07-17  Thomas Quinot  <quinot@adacore.com>
6490         * sem.ads (Scope_Stack_Entry): Reorganize storage of action lists;
6491         introduce a new list (cleanup actions) for each (transient) scope.
6492         * sinfo.ads, sinfo.adb (Cleanup_Actions): New attribute for
6493         N_Block_Statement
6494         * exp_ch7.ads (Store_Cleanup_Actions_In_Scope): New subprogram.
6495         * exp_ch7.adb (Store_Actions_In_Scope): New subprogram, common
6496         processing for Store_xxx_Actions_In_Scope.
6497         (Build_Cleanup_Statements): Allow for a list of additional
6498         cleanup statements to be passed by the caller.
6499         (Expand_Cleanup_Actions): Take custom cleanup actions associated
6500         with an N_Block_Statement into account.
6501         (Insert_Actions_In_Scope_Around): Account for Scope_Stack_Entry
6502         reorganization (refactoring only, no behaviour change).
6503         (Make_Transient_Block): Add assertion to ensure that the current
6504         scope is indeed a block (namely, the entity for the transient
6505         block being constructed syntactically, which has already been
6506         established as a scope).  If cleanup actions are present in the
6507         transient scope, transfer them now to the transient block.
6508         * exp_ch6.adb (Expand_Protected_Subprogram_Call): Freeze the
6509         called function while it is still present as the name in a call
6510         in the tree. This may not be the case later on if the call is
6511         rewritten into a transient block.
6512         * exp_smem.adb (Add_Shared_Var_Lock_Procs): The post-actions
6513         inserted after calling a protected operation on a shared passive
6514         protected must be performed in a block finalizer, not just
6515         inserted in the tree, so that they are executed even in case of
6516         a normal (RETURN) or abnormal (exception) transfer of control
6517         outside of the current scope.
6518         * exp_smem.ads (Add_Shared_Var_Lock_Procs): Update documentation
6519         * sem_ch8.adb, expander.adb, exp_ch11.adb: Adjust for
6520         Scope_Stack_Entry reorganization.
6522 2014-07-17  Thomas Quinot  <quinot@adacore.com>
6524         * exp_disp.adb (Make_DT, Make_VM_TSD): Do not omit Check_TSD
6525         call for types that do not have an explicit attribute definition
6526         clause for External_Tag, as their default tag may clash with an
6527         explicit tag defined for some other type.
6529 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
6531         * exp_util.adb (Is_Controlled_Function_Call): Recognize a
6532         controlled function call with multiple actual parameters that
6533         appears in Object.Operation form.
6535 2014-07-17  Thomas Quinot  <quinot@adacore.com>
6537         * einfo.ads, einfo.adb (Has_External_Tag_Rep_Clause): Remove
6538         entity flag.
6539         * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case
6540         External_Tag): No need to set entity flag.
6541         * sem_aux.ads, sem_aux.adb (Has_External_Tag_Rep_Clause):
6542         Reimplement correctly in terms of Has_Rep_Item.
6544 2014-07-17  Thomas Quinot  <quinot@adacore.com>
6546         * exp_ch7.adb (Establish_Transient_Scope.Find_Node_To_Be_Wrapped):
6547         Start examining the tree at the node passed to
6548         Establish_Transient_Scope (not its parent).
6549         * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
6550         The access type for the variable storing the reference to
6551         the call must be declared and frozen prior to establishing a
6552         transient scope.
6553         * exp_ch9.adb: Minor reformatting.
6555 2014-07-17  Pascal Obry  <obry@adacore.com>
6557         * s-os_lib.ads: Minor comment update.
6559 2014-07-17  Tristan Gingold  <gingold@adacore.com>
6561         * sysdep.c: Add ATTRIBUTE_UNUSED to avoid warnings.  Fix some
6562         indentation.
6563         * socket.c: Remove #warning to avoid warning.
6564         * expect.c: Indent some preprocessor directives to clarify
6565         nested if.  Do not use wait.h on PikeOS.  Add ATTRIBUTE_UNUSED
6566         to remove warnings.
6567         * env.c: Fix indentation.  Port to PikeOS.
6568         * gsocket.h: Port to PikeOS.  Remove #warning.
6569         * terminals.c: Port to PikeOS.  Fix indentation of the stubs.
6570         Add ATTRIBUTE_UNUSED to stubs arguments.  Fix return statement
6571         of stubbed __gnat_setup_parent_communication.
6572         * adaint.c: Port to PikeOS.  Reindent some preprocessor
6573         directives to clarify nested if.  Fix indentation.  Add missing
6574         ATTRIBUTE_UNUSED.
6576 2014-07-17  Robert Dewar  <dewar@adacore.com>
6578         * sem_attr.adb: Minor reformatting.
6580 2014-07-17  Robert Dewar  <dewar@adacore.com>
6582         * exp_ch7.adb, exp_ch7.ads, sinfo.ads: Minor reformatting.
6584 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
6586         * sem_case.adb (Check_Choice_Set): If the case expression is the
6587         expression in a predicate, do not recheck coverage against itself,
6588         to prevent spurious errors.
6589         * sem_ch13.adb (Check_Aspect_At_End_Of_Declarations): Indicate that
6590         expression comes from an aspect specification, to prevent spurious
6591         errors when expression is a case expression in a predicate.
6593 2014-07-17  Pascal Obry  <obry@adacore.com>
6595         * adaint.c, adaint.h (__gnat_set_executable): Add mode parameter.
6596         * s-os_lib.ads, s-os_lib.adb (Set_Executable): Add Mode parameter.
6598 2014-07-17  Vincent Celier  <celier@adacore.com>
6600         * gnatchop.adb, make.adb, gnatbind.adb, clean.adb, gprep.adb,
6601         gnatxref.adb, gnatls.adb, gnatfind.adb, gnatname.adb: Do not output
6602         the usage for an erroneous invocation of a gnat tool.
6604 2014-07-16  Vincent Celier  <celier@adacore.com>
6606         * gnatls.adb: Get the target parameters only if -nostdinc was
6607         not specified.
6609 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
6611         * checks.adb (Insert_Valid_Check): If the expression is a packed
6612         component of a modular type of the right size the data is always
6613         valid. This os particularly useful if the component is part of
6614         a volatile variable.
6616 2014-07-16  Robert Dewar  <dewar@adacore.com>
6618         * gnat_rm.texi, sinfo.ads, freeze.adb, exp_aggr.adb: Minor reformatting
6620 2014-07-16  Thomas Quinot  <quinot@adacore.com>
6622         * exp_ch7.ads: Minor documentation fix.
6624 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
6626         * sem_ch3.adb (Find_Type_Name): Diagnose properly
6627         a private extension completion that is an interface definition
6628         with an interface list.
6630 2014-07-16  Arnaud Charlet  <charlet@adacore.com>
6632         * gnatls.adb (Gnatls): Code clean ups.
6634 2014-07-16  Thomas Quinot  <quinot@adacore.com>
6636         * sinfo.ads, sinfo.adb (N_Compound_Statement): New node kind.
6637         * sem.adb (Analyze): Handle N_Compound_Statement.
6638         * sprint.adb (Sprint_Node_Actual): Ditto.
6639         * sem_ch5.ads, sem_ch5.adb (Analyze_Compound_Statement): New
6640         procedure to handle N_Compound_Statement.
6641         * exp_aggr.adb (Collect_Initialization_Statements):
6642         Use a proper compound statement node, instead of a bogus
6643         expression-with-actions with a NULL statement as its expression,
6644         to wrap collected initialization statements.
6645         * freeze.ads, freeze.adb
6646         (Explode_Initialization_Compound_Statement): New public procedure,
6647         lifted from Freeze_Entity.
6648         (Freeze_Entity): When freezing
6649         an object with captured initialization statements and without
6650         delayed freezing, explode compount statement.
6651         * sem_ch4.adb (Analyze_Expression_With_Actions): Remove special
6652         case that used to handle bogus EWAs with NULL statement as
6653         the expression.
6654         * exp_ch13.adb (Expand_N_Freeze_Entity): For an object with
6655         delayed freezing and captured initialization statements, explode
6656         compound statement.
6658 2014-07-16  Gary Dismukes  <dismukes@adacore.com>
6660         * g-rewdat.adb, g-rewdat.ads: Minor reformatting.
6662 2014-07-16  Doug Rupp  <rupp@adacore.com>
6664         * s-interr-hwint.adb: Casing error on parameter.
6666 2014-07-16  Pascal Obry  <obry@adacore.com>
6668         * Makefile.rtl: Add g-rewdat.o dependencies in
6669         GNATRTL_NONTASKING_OBJS.
6671 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
6673         * sem_case.adb: Code clean up.
6675 2014-07-16  Vincent Celier  <celier@adacore.com>
6677         * make.adb: Do not read gnat.adc when gnatmake is invoked
6678         with -gnatA.
6680 2014-07-16  Pascal Obry  <obry@adacore.com>
6682         * gnat_rm.texi, impunit.adb, g-rewdat.adb, g-rewdat.ads: Initial
6683         implementation of GNAT.Rewrite_Data.
6685 2014-07-16  Vincent Celier  <celier@adacore.com>
6687         * gnatls.adb (Normalize): New function.
6688         (Gnatls): Get the target parameters. On targets other than VMS,
6689         normalize the path names in the source search path, the object search
6690         path and the project search path.
6692 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
6694         * sem_case.adb: Avoid self-checking of case expressions in
6695         dynamic predicates.
6697 2014-07-16  Robert Dewar  <dewar@adacore.com>
6699         * gnat_rm.texi: Document effect of Suppress_Initialization on tags and
6700         discriminants.
6702 2014-07-16  Eric Botcazou  <ebotcazou@adacore.com>
6704         * switch-b.adb (Scan_Binder_Switches): Add missing guard.
6706 2014-07-16  Ben Brosgol  <brosgol@adacore.com>
6708         * gnat_ugn.texi: Fix typo.
6710 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
6712         * exp_ch4.adb (Expand_N_Case_Expression): Do not expand case
6713         expression if it is the specification of a subtype predicate:
6714         it will be expanded when the return statement is analyzed, or
6715         when a static predicate is transformed into a static expression
6716         for evaluation by the front-end.
6717         * sem_ch13.adb (Get_RList): If the expression for a static
6718         predicate is a case expression, extract the alternatives of the
6719         branches with a True value to create the required statically
6720         evaluable expression.
6722 2014-07-16  Thomas Quinot  <quinot@adacore.com>
6724         * exp_prag.adb (Expand_Pragma_Check): Use the location of the
6725         expression, not the location of the aspect, for all generated
6726         code, so that in particular the call to raise_assert_failure
6727         gets the sloc of the associated condition.
6728         * exp_ch6.adb
6729         (Expand_Subprogram_Contract.Build_Postconditions_Procedure):
6730         Set an explicit End_Label on the handled sequence of statements
6731         for the _Postconditions procedure so that the implicit return
6732         statement does not erroneously get associated with code generated
6733         for the last condition in postconditions.
6735 2014-07-16  Thomas Quinot  <quinot@adacore.com>
6737         * ug_words: Fix name of VMS synonym for -gnatw.z (SIZE_ALIGNMENT,
6738         not SIZE_ALIGN) and -gnatw.Z (NOSIZE_ALIGNMENT, not NOSIZE_ALIGN).
6739         * vms_data.ads: Add missing spaces in VMS synonyms for -gnatw.z /
6740         -gnatw.Z.
6742 2014-07-16  Robert Dewar  <dewar@adacore.com>
6744         * sem_ch3.adb, sem_prag.adb, sem_util.adb, sem_res.adb, sem_ch13.adb:
6745         Minor code reorganization (use Is_Access_Type, not in Access_Kind).
6746         * exp_ch3.adb: Minor code reorganization, use Is_Access_Type,
6747         not in Access_Kind.
6748         * par-ch4.adb (At_Start_Of_Attribute): New function
6749         (P_Simple_Expression): Better msg for bad attribute prefix.
6750         * scans.ads: Minor reformatting.
6752 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
6754         * sem_attr.adb (Resolve_Attribute, case 'Update): If choice is a
6755         static constant, check that in belongs to the corresponding index
6756         subtype, to produce the proer warning when expansion is disabled.
6758 2014-07-16  Robert Dewar  <dewar@adacore.com>
6760         * freeze.adb (Freeze_Entity): Warn on incompatible size/alignment.
6761         * gnat_ugn.texi: Document -gnatw.z and -gnatw.Z.
6762         * ug_words: VMS synonyms (WARNINGS=[NO]SIZE_ALIGN) for -gnatw.z/-gnatw.Z
6763         * usage.adb: Add lines for -gnatw.z/-gnatw.Z.
6764         * vms_data.ads: VMS synonyms (WARNINGS=[NO]SIZE_ALIGN) for
6765         -gnatw.z/-gnatw.Z
6766         * warnsw.adb: Set Warn_On_Size_Alignment appropriately.
6767         * warnsw.ads (Warn_On_Size_Alignment): New flag Minor
6768         reformatting.
6770 2014-07-16  Hristian Kirtchev  <kirtchev@adacore.com>
6772         * exp_ch7.adb (Process_Declarations): Reinstate the check on
6773         a hook object to ensure that the related transient declaration
6774         is finalizable.
6775         * exp_util.adb (Is_Aliased): Do not consider expresison with
6776         actions as a special context.
6777         (Requires_Cleanup_Actions): Reinstate the check on a hook object to
6778         ensure that the related transient declaration is finalizable.
6780 2014-07-16  Robert Dewar  <dewar@adacore.com>
6782         * checks.ads, checks.adb (Allocation_Checks_Suppressed): New function.
6783         * snames.ads-tmpl: Add Allocation_Check to list of check names.
6784         * types.ads: Add Allocation_Check to list of check names.
6786 2014-07-16  Thomas Quinot  <quinot@adacore.com>
6788         * sem_util.adb (Enter_Name): replace bogus test for presence of
6789         Corresponding_Remote_Type with correct test on Ekind.
6790         * sem_res.adb (Valid_Conversion): ditto; also clarify validity
6791         of calls to Corresponding_ Remote_Type (documentation fix).
6793 2014-07-16  Robert Dewar  <dewar@adacore.com>
6795         * gnat_rm.texi: Document illegal case of Unrestricted_Access.
6796         * sem_attr.adb (Analyze_Access_Attribute): Set_Non_Aliased_Prefix
6797         where it applies.
6798         (Resolve_Attribute, case Access): Flag illegal Unrestricted_Access use.
6799         * sinfo.ads, sinfo.adb (Non_Aliased_Prefix): New flag.
6801 2014-07-16  Robert Dewar  <dewar@adacore.com>
6803         * gnat_ugn.texi: Document binder switch -Ra.
6804         * gnatbind.adb (List_Closure_Display): Implement -Ra switch
6805         (List_Closure_All).
6806         * opt.ads (List_Closure_All): New switch.
6807         * switch-b.adb (Scan_Binder_Switches): Recognize -Ra to set
6808         List_Closure_All.
6810 2014-07-16  Ben Brosgol  <brosgol@adacore.com>
6812         * gnat_rm.texi: Minor edits, to make case consistent in names
6813         of types and fields.
6815 2014-07-16  Robert Dewar  <dewar@adacore.com>
6817         * gnat_rm.texi: Document erroneous mixing of thin pointers and
6818         unrestricted access
6819         * gnat_ugn.texi: Add note on size of access types about thin
6820         pointers and the use of attribute Unrestricted_Access.
6822 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
6824         * a-cbdlli.ads, a-cbdlli.adb, a-cbhama.ads, a-cbhama.adb,
6825         * a-cbhase.ads, a-cbhase.adb, a-cborma.ads, a-cborma.adb,
6826         * a-cborse.ads, a-cborse.adb, a-cobove.ads a-cobove.adb: Add Control
6827         machinery to detect tampering on bounded vectors.
6829 2014-07-16  Robert Dewar  <dewar@adacore.com>
6831         * gnat_rm.texi: Document that leading/trailing asterisks are
6832         now implied for the pattern match string for pragma Warnings
6833         and Warning_As_Error.
6834         * sem_prag.adb (Acquire_Warning_Match_String): New procedure.
6835         (Analyze_Pragma, case Warning_As_Error): Call
6836         Acquire_Warning_Match_String.
6837         (Analyze_Pragma, case Warnings): Call Acquire_Warning_Match_String.
6839 2014-07-16  Bob Duff  <duff@adacore.com>
6841         * gnat_ugn.texi: Document need for project file
6842         for --incremental switch for gnat2xml.
6844 2014-07-16  Robert Dewar  <dewar@adacore.com>
6846         * gnat_rm.texi: Fix example of non-packable components in packed
6847         records section.
6849 2014-07-16  Robert Dewar  <dewar@adacore.com>
6851         * s-tpoben.adb, s-tasren.adb, s-interr.adb, s-interr-hwint.adb,
6852         s-shasto.adb, s-interr-vms.adb, s-interr-sigaction.adb: Avoid use of
6853         upper case in exception messages.
6855 2014-07-16  Robert Dewar  <dewar@adacore.com>
6857         * snames.ads-tmpl, sem_attr.adb, exp_attr.adb: Same_Storage attribute
6858         is renamed Has_Same_Storage.
6859         * gnat_rm.texi: Document missing SPARK pragmas and attributes.
6860         * sem_prag.adb: Minor comment fix (use LOCAL_NAME in syntax
6861         descriptions).
6863 2014-07-16  Robert Dewar  <dewar@adacore.com>
6865         * exp_util.adb, sem_attr.adb, exp_ch4.adb, a-cohase.ads,
6866         a-coinho-shared.adb, a-coinho-shared.ads: Minor reformatting.
6868 2014-07-16  Robert Dewar  <dewar@adacore.com>
6870         * gnat_ugn.texi: Add note that integrated
6871         preprocessing cannot be applied to configuration pragma files.
6873 2014-07-16  Yannick Moy  <moy@adacore.com>
6875         * sem_attr.adb (Analyze_Attribute/cases Pred
6876         and Succ): Always enable range check on fixed-point types if
6877         not suppressed for the type.
6879 2014-07-16  Hristian Kirtchev  <kirtchev@adacore.com>
6881         * sem_util.adb (State_Has_Enabled_Property):
6882         Account for an external property denoted by an others choice.
6884 2014-07-16  Hristian Kirtchev  <kirtchev@adacore.com>
6886         * exp_ch4.ads, exp_ch4.adb (Find_Hook_Context): Relocated to Exp_Util.
6887         * exp_ch7.adb (Process_Declarations): There is no need to check
6888         that a transient object being hooked is controlled as it would
6889         not have been hooked in the first place.
6890         * exp_ch9.adb Remove with and use clause for Exp_Ch4.
6891         * exp_util.adb (Find_Hook_Context): Relocated from Exp_Ch4.
6892         (Is_Aliased): A renaming of a transient controlled object is
6893         not considered aliasing when it occurs within an expression
6894         with actions.
6895         (Requires_Cleanup_Actions): There is no need to
6896         check that a transient object being hooked is controlled as it
6897         would not have been hooked in the first place.
6898         * exp_util.ads (Find_Hook_Context): Relocated from Exp_Ch4.
6900 2014-07-16  Hristian Kirtchev  <kirtchev@adacore.com>
6902         * sem_ch13.adb (Insert_After_SPARK_Mode): Moved to
6903         the outer level of routine Analyze_Aspect_Specifications. Ensure
6904         that the corresponding pragmas of aspects Initial_Condition and
6905         Initializes are inserted after pragma SPARK_Mode.
6907 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
6909         * sem_attr.adb (Analyze_Attribute, case 'Update): Handle
6910         properly a choice list with more than one choice, where each
6911         is an aggregate denoting a sequence of array indices for a
6912         multidimentional array. For SPARK use.
6914 2014-07-16  Vadim Godunko  <godunko@adacore.com>
6916         * a-coinho-shared.adb (Adjust): Create
6917         copy of internal shared object and element when source container
6918         is locked.
6919         (Copy): Likewise.
6920         (Query_Element): Likewise.
6921         (Update_Element): Likewise.
6922         (Constant_Reference): Likewise. Raise Constraint_Error on attempt
6923         to get reference for empty holder.
6924         (Reference): Likewise.
6926 2014-07-16  Thomas Quinot  <quinot@adacore.com>
6928         * exp_ch4.adb (Find_Hook_Context): New subprogram, extracted
6929         from Process_Transient_Oject.
6930         * exp_ch4.ads: Ditto.
6931         * exp_ch9.adb (Build_Class_Wide_Master): Insert the _master
6932         declaration as an action on the topmost enclosing expression,
6933         not on a possibly conditional subexpreession.
6935 2014-07-16  Vadim Godunko  <godunko@adacore.com>
6937         * a-coinho.adb, a-coinho-shared.adb, a-coinho.ads, a-coinho-shared.ads:
6938         Fix parameter mode of Update_Element.
6940 2014-07-16  Robert Dewar  <dewar@adacore.com>
6942         * a-coinho.adb, a-coinho-shared.adb, a-coinho-shared.ads: Minor
6943         reformatting.
6945 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
6947         * a-cohase.ads: Type Iterator must be controlled, so that the
6948         tampering bit is properly set through an iteration.
6949         * a-cohase.adb: Add Finalize operation for type Iterator.
6951 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
6953         * a-coinho-shared.adb, a-coinho-shared.ads: Proper structures for
6954         tampering checks.
6956 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
6958         * a-coinho-shared.adb: Fix spurious accessibility check.
6960 2014-06-15  Jan Hubicka  <hubicka@ucw.cz>
6962         * gcc-interface/utils.c (process_attributes): Use set_decl_tls_model.
6964 2014-06-14  Bernd Edlinger  <bernd.edlinger@hotmail.de>
6966         PR ada/61505
6967         * gnat_rm.texi: Fix errors with makeinfo 5.1.
6969 2014-06-14  Arnaud Charlet  <charlet@adacore.com>
6971         PR ada/61505
6972         * gnat_rm.texi: Attempt to fix error with makeinfo 5.1.
6974 2014-06-13  Yannick Moy  <moy@adacore.com>
6976         * exp_attr.adb: Fix typo in comment.
6977         * gnat1drv.adb (Adjust_Global_Switches): Force float overflow
6978         checking in GNATprove_Mode.
6980 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
6982         * a-coinho-shared.adb, a-coinho-shared.ads: Update shared version.
6984 2014-06-13  Robert Dewar  <dewar@adacore.com>
6986         * sem_ch3.adb, sem_ch9.adb, a-coinho.adb, a-coinho.ads: Minor
6987         reformatting.
6989 2014-06-13  Hristian Kirtchev  <kirtchev@adacore.com>
6991         * sem_prag.adb (Analyze_Pragma): Add local
6992         variable Missing_Parentheses. Emit an error when a state
6993         declaration with options appears without parentheses. Add a
6994         guard to prevent a bogus error when a state declaration may be
6995         interpreted as an option if a previous declaration with options
6996         was not parenthesized.
6998 2014-06-13  Robert Dewar  <dewar@adacore.com>
7000         * checks.adb: Validate_Alignment_Check_Warnings: New procedure
7001         (Apply_Address_Clause_Check): Make Aligment_Warnings table entry.
7002         * checks.ads (Alignment_Warnings_Record): New type.
7003         (Alignment_Warnings): New table
7004         (Validate_Alignment_Check_Warnings): New procedure.
7005         * errout.adb (Delete_Warning_And_Continuations): New procedure
7006         (Error_Msg_Internal): Set Warning_Msg (Delete_Warning): Handle
7007         Warnings_Treated_As_Errors (Finalize): Minor reformatting
7008         * errout.ads (Warning_Msg): New variable
7009         (Delete_Warning_And_Continuations): New procedure
7010         * erroutc.adb (Delete_Msg): Handle Warnings_Treated_As_Errors count.
7011         * gnat1drv.adb (Post_Compilation_Validation_Checks): New procedure.
7013 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
7015         * a-coinho.adb, a-coinho.ads: Add Reference machinery.
7017 2014-06-13  Hristian Kirtchev  <kirtchev@adacore.com>
7019         * errout.adb (SPARK_Msg_N): New routine.
7020         (SPARK_Msg_NE): New routine.
7021         * errout.ads Add a section on SPARK-related error routines.
7022         (SPARK_Msg_N): New routine.
7023         (SPARK_Msg_NE): New routine.
7024         * sem_ch13.adb (Analyze_Aspect_Specifications): Ensure that
7025         pragma Abstract_State is always inserted after SPARK_Mode.
7026         (Insert_After_SPARK_Mode): New routine.
7027         * sem_prag.adb (Analyze_Abstract_State,
7028         Analyze_Constituent, Analyze_External_Property,
7029         Analyze_External_Property_In_Decl_Part, Analyze_Global_Item,
7030         Analyze_Global_List, Analyze_Initialization_Item,
7031         Analyze_Initialization_Item_With_Inputs, Analyze_Input_Item,
7032         Analyze_Input_List, Analyze_Input_Output, Analyze_Part_Of,
7033         Analyze_Pragma, Analyze_Refined_Depends_In_Decl_Part,
7034         Analyze_Refined_Global_In_Decl_Part,
7035         Analyze_Refined_State_In_Decl_Part, Analyze_Refinement_Clause,
7036         Check_Aspect_Specification_Order, Check_Constituent_Usage,
7037         Check_Declaration_Order, Check_Dependency_Clause,
7038         Check_Duplicate_Mode, Check_Duplicate_Option,
7039         Check_Duplicate_Property, Check_External_Properties,
7040         Check_External_Property, Check_Function_Return,
7041         Check_Matching_Constituent, Check_Matching_State,
7042         Check_Mode_Restriction_In_Enclosing_Context,
7043         Check_Mode_Restriction_In_Function, Check_Refined_Global_Item,
7044         Check_State_And_Constituent_Use, Create_Or_Modify_Clause,
7045         Has_Extra_Parentheses, Inconsistent_Mode_Error,
7046         Match_Error, Propagate_Part_Of, Report_Extra_Clauses,
7047         Report_Extra_Constituents_In_List, Report_Extra_Inputs,
7048         Report_Unrefined_States, Report_Unused_Constituents,
7049         Report_Unused_States, Role_Error, Usage_Error):
7050         Convert Error_Msg_XXX calls to SPARK_Msg_XXX calls
7051         to report semantic errors only when SPARK_Mode is on.
7052         (Analyze_Depends_In_Decl_Part): Do not check the syntax of
7053         pragma Depends explicitly, this is now done by the analysis.
7054         (Analyze_Global_In_Decl_List): Do not check the syntax of
7055         pragma Global explicitly, this is now done by the analysis.
7056         (Analyze_Initializes_In_Decl_Part): Do not check the syntax of
7057         pragma Initializes explicitly, this is now done by the analysis.
7058         (Analyze_Part_Of): Do not check the syntax of the encapsulating
7059         state, this is now done by the analysis.
7060         (Analyze_Pragma): Do
7061         not check the syntax of a state declaration, this is now done
7062         by the analysis.
7063         (Analyze_Refined_Depends_In_Decl_Part): Do not
7064         check the syntax of pragma Refined_Depends explicitly, this is now
7065         done by the analysis.
7066         (Analyze_Refined_Global_In_Decl_Part): Do
7067         not check the syntax of pragma Refined_Global explicitly, this is
7068         now done by the analysis.
7069         (Analyze_Refined_State_In_Decl_Part):
7070         Do not check the syntax of pragma Refined_State explicitly, this
7071         is now done by the analysis.
7072         (Check_Dependence_List_Syntax): Removed.
7073         (Check_Global_List_Syntax): Removed.
7074         (Check_Initialization_List_Syntax): Removed.
7075         (Check_Item_Syntax): Removed.
7076         (Check_Missing_Part_Of): Do not consider items from an instance.
7077         (Check_Refinement_List_Syntax): Removed.
7078         (Check_State_Declaration_Syntax): Removed.
7079         (Collect_Global_List): Do not raise Program_Error when the input is
7080         malformed.
7081         (Process_Global_List): Do not raise Program_Error when the input
7082         is malformed.
7083         * sem_ch13.adb: Minor reformatting.
7085 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
7087         * sem_ch3.adb (Find_Type_Name): Diagnose a private type completion
7088         that is an interface definition with an interface list.
7089         (Process_Full_View): Move error message on missmatched interfaces
7090         between views to the declaration of full view, for clarity.
7091         * sem_ch9.adb (Check_Interfaces): Move error message to full view,
7092         for clarity.
7094 2014-06-13  Robert Dewar  <dewar@adacore.com>
7096         * exp_attr.adb (Expand_N_Attribute_Reference, case Pred/Succ): Change
7097         reason to Overflow.
7099 2014-06-13  Robert Dewar  <dewar@adacore.com>
7101         * makeutl.adb: Minor reformatting.
7103 2014-06-13  Gail Schenker  <schenker@adacore.com>
7105         * debug.adb, sem_eval.adb (Why_Not_Static): Remove temporary code and
7106         associated flag (d.z), no longer needed.
7108 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
7110         * sem_ch13.adb (Analyze_Aspect_Specifications): For Import and
7111         Export aspects, do not check whether a corresponding Convention
7112         aspect has been specified. Convention is optional in Ada2012,
7113         and defaults to Convention_Ada.
7115 2014-06-13  Eric Botcazou  <ebotcazou@adacore.com>
7117         * checks.adb (Apply_Address_Clause_Check): Only issue the new
7118         warning if the propagation warning is issued.
7120 2014-06-13  Thomas Quinot  <quinot@adacore.com>
7122         * exp_ch4.adb: Minor reformatting.
7124 2014-06-13  Robert Dewar  <dewar@adacore.com>
7126         * exp_attr.adb (Expand_N_Attribute_Reference, case Pred):
7127         Handle float range check case (Expand_N_Attribute_Reference,
7128         case Succ): Handle float range check case.
7129         * sem_attr.adb (Analyze_Attribute, case Pred/Succ): Handle float
7130         range check case.
7132 2014-06-13  Vincent Celier  <celier@adacore.com>
7134         * makeutl.ads (Compute_Builder_Switches): Change name of
7135         parameter Root_Environment to Env.
7136         * prj-conf.adb (Check_Switches): Call Locate_Runtime with the
7137         Env parameter of procedure Get_Or_Create_Configuration_File.
7138         (Locate_Runtime): Call Find_Rts_In_Path with the Project_Path
7139         of new parameter Env.
7140         * prj-conf.ads (Locate_Runtime): New parameter Env of type
7141         Prj.Tree.Environment.
7143 2014-06-13  Robert Dewar  <dewar@adacore.com>
7145         * gnat_rm.texi: Minor comment clarification for Check_Float_Overflow.
7147 2014-06-13  Robert Dewar  <dewar@adacore.com>
7149         * exp_attr.adb, exp_ch9.adb, lib-writ.adb, g-comlin.adb: Minor
7150         reformatting.
7151         * sem_attr.adb: Minor code reformatting and simplification.
7152         * checks.adb: Fix minor typo.
7154 2014-06-13  Emmanuel Briot  <briot@adacore.com>
7156         * g-comlin.adb (Get_Argument): fix expansion
7157         of command line arguments (e.g. "*.adb") when using a custom
7158         parser. The parser was not passed to the recursive call, and
7159         thus we were trying to do the expansion on the default command
7160         line parser.
7162 2014-06-13  Thomas Quinot  <quinot@adacore.com>
7164         * exp_ch9.adb: Minor reformatting.
7166 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
7168         * exp_attr.adb (Expand_N_Attribute_Reference, case 'Old):
7169         To determine whether the attribute should be expanded, examine
7170         whether the enclosing postcondition pragma is to be checked,
7171         rather than using the internal flag Assertions_Enabled.
7173 2014-06-13  Ben Brosgol  <brosgol@adacore.com>
7175         * gnat_rm.texi: Minor fixes.
7176         * gnat_ugn.texi: Added a missing "@itemize".
7178 2014-06-13  Robert Dewar  <dewar@adacore.com>
7180         * debug.adb: Remove -gnatd.1 flag documentation.
7181         * layout.adb (Layout_Type): Remove special handling of size
7182         for anonymous access type.
7183         * sem_ch3.adb (Replace_Type): Remove special handling of size
7184         for anonymous access type.
7186 2014-06-13  Robert Dewar  <dewar@adacore.com>
7188         * debug.adb: Document debug flag -gnatd.1.
7189         * layout.adb (Layout_Type): Size change for anonymous access
7190         types under -gnatd.1.
7191         * sem_ch3.adb (Replace_Type): Size change for anonymous access
7192         types under -gnatd.1.
7194 2014-06-13  Robert Dewar  <dewar@adacore.com>
7196         * layout.adb (Layout_Type): Anonymous access types designating
7197         unconstrained arrays are always thin pointers.
7198         * sem_ch3.adb (Replace_Type): Anonymous access types designating
7199         unconstrained arrays are always thin pointers.
7201 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
7203         * sem_attr.adb (Analyze_Attribute): Use Check_Parameterless_Call
7204         to resolve the prefix of an attribute that is an entity name
7205         and may be a parameterless call.  Minor code reorganization.
7207 2014-06-13  Robert Dewar  <dewar@adacore.com>
7209         * lib.ads, lib.adb, lib-writ.adb, lib-load.adb (Is_Compiler_Unit):
7210         Removed.
7211         * opt.ads (Compiler_Unit): New flag.
7212         * par-ch5.adb (Test_Statement_Required): Call Check_Compiler_Unit
7213         for null statement sequence (not allowed in compiler unit).
7214         * par-prag.adb (Prag): Handle Compiler_Unit[_Warning] during
7215         parsing.
7216         * restrict.ads, restrict.adb (Check_Compiler_Unit): New version and new
7217         calling sequence.
7218         * sem_ch11.adb, sem_ch3.adb, sem_ch4.adb: New calling sequence for
7219         Check_Compiler_Unit.
7220         * sem_ch6.adb (Analyze_Extended_Return_Statement): Call
7221         Check_Compiler_Unit (this construct is not allowed in compiler
7222         units).
7223         * sem_prag.adb (Analyze_Pragma, case Compiler_Unit[_Warning]):
7224         Set Opt.Compiler_Unit.
7226 2014-06-13  Geert Bosch  <bosch@adacore.com>
7228         * gnat_rm.texi, s-tasinf-solaris.ads, sem_prag.adb, gnat_ugn.texi,
7229         s-tasinf-mingw.ads, s-tasinf.ads, s-tasinf-linux.ads,
7230         s-tasinf-vxworks.ads: Make Task_Info pragma and package obsolescent.
7232 2014-06-13  Robert Dewar  <dewar@adacore.com>
7234         * s-tasini.adb, s-tarest.adb, s-taprob.adb: Minor reformatting.
7236 2014-06-13  Hristian Kirtchev  <kirtchev@adacore.com>
7238         * freeze.adb (Freeze_Entity): Remove the check concerning volatile
7239         types in SPARK as it is poorly placed and poorly formulated. The
7240         check was flagging ALL volatile entities as illegal in SPARK.
7241         * sem_prag.adb (Process_Atomic_Shared_Volatile): Flag volatile
7242         types as illegal in SPARK.
7244 2014-06-13  Robert Dewar  <dewar@adacore.com>
7246         * sem_cat.adb: Minor reformatting.
7248 2014-06-13  Yannick Moy  <moy@adacore.com>
7250         * sem_prag.adb (Analyze_Pragma/Post_Class): Fix typo.
7252 2014-06-13  Arnaud Charlet  <charlet@adacore.com>
7254         * gnat_rm.texi: Add detail on SPARK_05 restriction.
7256 2014-06-13  Bob Duff  <duff@adacore.com>
7258         * s-solita.adb (Get_Sec_Stack_Addr, Init_Tasking_Soft_Links):
7259         Add assertions requiring the secondary stack to be initialized.
7260         * s-solita.ads (Init_Tasking_Soft_Links): Comment.
7261         * s-taprob.adb, s-tarest.adb, s-tasini.adb (elab code): Make sure the
7262         secondary stack is initialized before calling Init_Tasking_Soft_Links,
7263         by adding pragmas Elaborate_Body.
7265 2014-06-13  Thomas Quinot  <quinot@adacore.com>
7267         * sem_ch13.adb (Analyze_Stream_TSS_Definition): Remove temporary
7268         kludge disabling new legality check.
7270 2014-06-13  Hristian Kirtchev  <kirtchev@adacore.com>
7272         * freeze.adb (Freeze_Record_Type): Remove checks related to SPARK
7273         volatile types.
7274         (Freeze_Type): Volatile types are now illegal in SPARK.
7276 2014-06-13  Robert Dewar  <dewar@adacore.com>
7278         * aspects.ads, aspects.adb: Add aspect Thread_Local_Storage.
7279         * gnat_rm.texi: Document aspect Thread_Local_Storage.
7281 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
7283         * sem_cat.adb (Validate_Static_Object_Name): A constant whose
7284         value is a temporary that renames an aggregate is legal in a
7285         preelaborated unit. Illegalities, if any will be detected in
7286         the aggregate components.
7288 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
7290         * einfo.ads: Minor reformatting an comment expansion.
7292 2014-06-13  Robert Dewar  <dewar@adacore.com>
7294         * back_end.ads, back_end.adb: Make_Id, Make_SC, Set_RND are moved to
7295         Tbuild.
7296         * tbuild.ads, tbuild.adb: Make_Id, Make_SC, Set_RND are moved here from
7297         Back_End.
7298         * gnat1drv.adb: Make_Id, Make_SC, Set_RND are moved to Tbuild
7299         * sem_warn.adb: Minor reformatting.
7301 2014-06-13  Doug Rupp  <rupp@adacore.com>
7303         * adaint.c (__gnat_open_new_temp) [VMS]: Open binary
7304         files with rfm=udf.
7306 2014-06-13  Yannick Moy  <moy@adacore.com>
7308         * sem_warn.adb (Check_Unset_References): Take
7309         case of Refined_Post into account in Within_Postcondition check.
7311 2014-06-13  Hristian Kirtchev  <kirtchev@adacore.com>
7313         * freeze.adb (Freeze_Record_Type): Volatile types are not allowed in
7314         SPARK.
7316 2014-06-13  Yannick Moy  <moy@adacore.com>
7318         * sem_ch13.adb (Analyze_Aspect_Specifications/Aspect_Import,
7319         Aspect_Export): Consider that variables may be set outside the program.
7321 2014-06-13  Robert Dewar  <dewar@adacore.com>
7323         * back_end.adb (Make_Id): New function.
7324         (Make_SC): New function.
7325         (Set_RND): New procedure.
7326         * back_end.ads (Make_Id): New function.
7327         (Make_SC): New function.
7328         (Set_RND): New procedure.
7329         * einfo.ads: Minor comment updates.
7330         * frontend.adb: Move Atree.Initialize call to Gnat1drv.
7331         * gnat1drv.adb (Gnat1drv): New calling sequence for
7332         Get_Target_Parameters.
7333         (Gnat1drv): Move Atree.Initialize here from Frontend.
7334         * targparm.adb (Get_Target_Parameters): New calling
7335         sequence (Get_Target_Parameters): Handle pragma Restriction
7336         (No_Dependence,..)
7337         * targparm.ads (Get_Target_Parameters): New calling sequence.
7339 2014-06-13  Gary Dismukes  <dismukes@adacore.com>
7341         * sem_prag.adb (Process_Import_Or_Interface): Exit the homonym
7342         loop if the pragma does not come from source, so that an implicit
7343         pragma Import only applies to the first declaration, avoiding
7344         possible conflicts with earlier explicit and implicit declarations
7345         due to multiple Provide_Shift_Operators pragmas.
7346         (Set_Imported): Remove previous fix that bypassed pragma duplication
7347         error.
7348         * gnat_rm.texi: Change 'equivalent' to 'similar' in description
7349         of Provide_Shift_Operators.
7351 2014-06-12  Jan Hubicka  <hubicka@ucw.cz>
7353         * gcc-interface/utils.c (process_attributes) <ATTR_LINK_SECTION>: Pass
7354         string pointer directly to set_decl_section_name.
7356 2014-06-11  Robert Dewar  <dewar@adacore.com>
7358         * sem_ch13.adb: Minor reformatting.
7360 2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>
7362         * sem_prag.adb (Check_Clause_Syntax): Add new
7363         local variable Outputs. Account for the case where multiple
7364         output items appear as an aggregate.
7366 2014-06-11  Robert Dewar  <dewar@adacore.com>
7368         * sem_warn.adb (Output_Obsolescent_Entity_Warnings): Tag warning
7369         with ?j? not ??.
7371 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
7373         * einfo.ads: Minor reformatting.
7375 2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>
7377         * a-cbdlli.adb, a-cdlili.adb, a-cidlli.adb, a-crdlli.adb (Insert): Add
7378         new variable First_Node. Update the position after all insertions have
7379         taken place to First_Node.
7381 2014-06-11  Robert Dewar  <dewar@adacore.com>
7383         * debug.adb: Remove debug flag -gnatd.1, no longer needed.
7384         * layout.adb (Layout_Type): Remove test of -gnatd.1.
7386 2014-06-11  Robert Dewar  <dewar@adacore.com>
7388         * sem_ch13.adb: Minor reformatting.
7390 2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>
7392         * sem_prag.adb (Check_Clause_Syntax): Add new
7393         local variable Outputs. Account for the case where multiple
7394         output items appear as an aggregate.
7396 2014-06-11  Robert Dewar  <dewar@adacore.com>
7398         * sem_warn.adb (Output_Obsolescent_Entity_Warnings): Tag warning
7399         with ?j? not ??.
7401 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
7403         * einfo.ads: Minor reformatting.
7405 2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>
7407         * a-cbdlli.adb, a-cdlili.adb, a-cidlli.adb, a-crdlli.adb (Insert): Add
7408         new variable First_Node. Update the position after all insertions have
7409         taken place to First_Node.
7411 2014-06-11  Robert Dewar  <dewar@adacore.com>
7413         * debug.adb: Remove debug flag -gnatd.1, no longer needed.
7414         * layout.adb (Layout_Type): Remove test of -gnatd.1.
7416 2014-06-11  Thomas Quinot  <quinot@adacore.com>
7418         * freeze.ads: Minor reformatting.
7419         * checks.adb (Determine_Range): Do not attempt to determine
7420         the range of a deferred constant whose full view has not been
7421         seen yet.
7422         * sem_res.adb (Resolve): Remove undesirable guard against
7423         resolving expressions from expression functions.
7425 2014-06-11  Robert Dewar  <dewar@adacore.com>
7427         * debug.adb (Debug_Flag_Dot_1): Set to enable fix for anonymous
7428         access types.
7429         * layout.adb (Layout_Type): Make anonymous access types for
7430         subprogram formal types and return types always thin. For now
7431         only enabled if -gnatd.1 set.
7433 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
7435         * sem_ch13.adb (Analyze_Stream_TSS_Definition): Apply legality
7436         rule for stream attributes of interface types (RM 13.13.2 (38/3)):
7437         subprogram must be a null procedure.
7439 2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>
7441         * sem_prag.adb (Analyze_Input_Item): Allow formal
7442         parameters to appear as input_items in an initialization_list
7443         of pragma Initializes. Encapsulation now applies to states and
7444         variables only (as it should). Add RM references to key errors.
7445         * sem_prag.adb (Set_Imported): Suppress errors
7446         about preceding Imports when the pragma does not come from source,
7447         which can happen through use of pragma Provide_Shift_Operators.
7449 2014-06-11  Thomas Quinot  <quinot@adacore.com>
7451         * sem_ch3.adb: Minor reformatting.
7452         * einfo.ads (Full_View): Minor comment update.
7454 2014-06-11  Robert Dewar  <dewar@adacore.com>
7456         * einfo.adb (Is_Independent): New flag.
7457         * einfo.ads (Is_Independent): New flag.
7458         (Has_Independent_Components): Clean up and fix comments.
7459         * sem_prag.adb (Fix_Error): Deal with changing argument
7460         [of] to entity [for].
7461         (Analyze_Pragma, case Independent): Set Is_Independent flag
7462         (Analyze_Pragma, case Independent_Components): Set Is_Independent flag
7463         in all components of specified record.
7465 2014-06-11  Thomas Quinot  <quinot@adacore.com>
7467         * sem_ch12.adb (Analyze_Formal_Decimal_Fixed_Point_Type):
7468         Set proper Etype on bounds of dummy type created for analysis
7469         of the generic.
7471 2014-06-11  Robert Dewar  <dewar@adacore.com>
7473         * debug.adb: Minor comment fix (add missing section of dot
7474         numeric flags).
7476 2014-06-11  Robert Dewar  <dewar@adacore.com>
7478         * gnat_rm.texi, switch-c.adb, sem_prag.adb, a-tgdico.ads, par-prag.adb,
7479         opt.ads, a-finali.ads, snames.ads-tmpl: Remove all traces of
7480         pragma/aspects Pure_05 Pure_12 Preelaborate_05.
7481         * errout.adb (Output_Messages): Avoid duplicate output for
7482         library level instance.
7483         * sem_elab.adb (Is_Call_Of_Generic_Formal): Moved to outer level
7484         (Check_Elab_Call): Add call to Is_Call_Of_Generic_Formal
7485         * exp_ch4.adb (Expand_N_Op_Expon): New interface for Exp_Modular.
7486         * s-expmod.ads, s-expmod.adb (Exp_Modular): Change interface to
7487         accomodate largest modulus value.
7488         * gnat_ugn.texi: Minor updates.
7490 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
7492         * sem_ch12.adb (Instantiate_Package_Body): Do not attempt to
7493         load body of generic package or its parent, if body is optional
7494         and the unit does not require a body.
7496 2014-06-11  Robert Dewar  <dewar@adacore.com>
7498         * gnat_rm.texi: Document System.Unsigned_Types.
7499         * impunit.adb: System.Unsigned_Types (s-unstyp.ads) is user accessible.
7500         * s-unstyp.ads: Update comments (this is now user available unit).
7502 2014-06-11  Robert Dewar  <dewar@adacore.com>
7504         * make.adb, sem_res.adb: Minor reformatting.
7506 2014-06-11  Thomas Quinot  <quinot@adacore.com>
7508         * a-astaco.ads, a-tags.ads, s-excdeb.ads, a-tgdico.ads, a-stmaco.ads,
7509         a-except-2005.ads, s-except.ads, a-taside.ads, a-dynpri.ads,
7510         a-chahan.ads, a-sytaco.ads, s-stalib.ads, a-strmap.ads: Change pragmas
7511         Preelaborate_05 to just Preelaborate in runtime units, and similarly
7512         change Pure_05 to just Pure.
7514 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
7516         * sem_ch6.adb (Analyze_Subprogram_Body_Contract): Do not attempt
7517         analysis if error has been posted on subprogram body.
7519 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
7521         * sem_ch13.adb (Analyze_Stream_TSS_Definition): Apply legality
7522         rule given in RM 13.1 (8/1) for operational attributes to stream
7523         attributes: the attribute must apply to a first subtype. Fixes
7524         missing errors in ACATS test bdd2004.
7526 2014-06-11  Robert Dewar  <dewar@adacore.com>
7528         * exp_ch3.adb (Build_Record_Init_Proc): Don't build for variant
7529         record type if restriction No_Implicit_Conditionals is active.
7530         (Expand_N_Object_Declaration): Don't allow default initialization
7531         for variant record type if restriction No_Implicit_Condition is active.
7532         (Build_Variant_Record_Equality): Don't build for variant
7533         record type if restriction No_Implicit_Conditionals is active.
7534         * exp_ch4.adb (Expand_N_Op_Eq): Error if variant records with
7535         No_Implicit_Conditionals.
7536         * sem_aux.ads, sem_aux.adb (Has_Variant_Part): New function.
7538 2014-06-11  Ramon Fernandez  <fernandez@adacore.com>
7540         * i-cstrin.ads: Update comments.
7542 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
7544         * sem_res.adb (Resolve_Selected_Component): Handle properly a
7545         selected component whose prefix is overloaded, when none of the
7546         interpretations matches the expected type.
7548 2014-06-11  Bob Duff  <duff@adacore.com>
7550         * make.adb (Wait_For_Available_Slot): Give a more
7551         informative error message; if the ALI file is not found, print
7552         the full path of what it's looking for.
7554 2014-06-11  Sergey Rybin  <rybin@adacore.com frybin>
7556         * gnat_ugn.texi, vms_data.ads: add description of gnatstub -W<par>
7557         option to specify the result file encoding.
7559 2014-06-11  Robert Dewar  <dewar@adacore.com>
7561         * errout.ads, sem_ch12.adb: Minor reformatting.
7562         * debug.adb, erroutc.adb: Remove -gnatd.q debug switch.
7563         * lib-xref.adb: Minor reformatting.
7564         * restrict.adb: Minor code reorganization (put routines in
7565         alpha order).
7567 2014-06-11  Yannick Moy  <moy@adacore.com>
7569         * einfo.ads: Minor typo in comment
7571 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
7573         * sinfo.ads, sinfo.adb: New attribute Uninitialized_Variable, for
7574         formal private types and private type extensions, to indicate
7575         variable in a generic unit whose uninitialized use suggest that
7576         actual type should be fully initialized.
7577         Needs_Initialized_Actual:  removed, functionaity replaced by
7578         the above.
7579         * lib-xref.adb (Generate_Reference): Generate a reference for
7580         variables of a formal type when the unit is not the main unit,
7581         to enable appropriate warnings in an instance.
7582         * sem_ch12.adb (Check_Ininialized_Type): Improve warning on use
7583         of variable in a generic unit that suggests that actual type
7584         should be full initialized.
7585         * sem_warn.adb; (May_Need_Initialized_Actual): Make into procedure
7586         and do not emot warning, which now only appears in an instance.
7588 2014-06-11  Eric Botcazou  <ebotcazou@adacore.com>
7590         * gnat_ugn.texi: Fix minor typo.
7592 2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>
7594         * sem_ch3.adb Add with and use clause for Sem_Ch10.
7595         (Analyze_Declarations): Code reformatting. Analyze the contract
7596         of a subprogram body stub at the end of the declarative region.
7597         * sem_ch6.adb (Analyze_Subprogram_Body_Contract): Spec_Id is
7598         now a variable. Do not process the body if its contract is not
7599         available. Account for subprogram body stubs when extracting
7600         the corresponding spec.
7601         * sem_ch6.ads (Analyze_Subprogram_Contract): Update the comment
7602         on usage.
7603         * sem_ch10.ads, sem_ch10.adb (Analyze_Subprogram_Body_Stub_Contract):
7604         New routine.
7605         * sem_prag.adb (Analyze_Depends_In_Decl_Part):
7606         Account for subprogram body stubs when extracting the
7607         corresponding spec.
7608         (Analyze_Global_In_Decl_List):
7609         Account for subprogram body stubs when extracting the
7610         corresponding spec.
7611         (Analyze_Refined_Depends_In_Decl_Part):
7612         Use Find_Related_Subprogram_Or_Body to retrieve the declaration
7613         of the related body. Spec_Is now a variable. Account for
7614         subprogram body stubs when extracting the corresponding spec.
7615         (Analyze_Refined_Global_In_Decl_Part): Use
7616         Find_Related_Subprogram_Or_Body to retrieve the declaration
7617         of the related body. Spec_Is now a variable. Account for
7618         subprogram body stubs when extracting the corresponding spec.
7619         (Collect_Subprogram_Inputs_Output): Account for subprogram body
7620         stubs when extracting the corresponding spec.
7622 2014-06-11  Vincent Celier  <celier@adacore.com>
7624         * gnatcmd.adb (Process_Link): Do not invoke gnatlink with
7625         -lgnarl or -lgnat.
7627 2014-06-11  Robert Dewar  <dewar@adacore.com>
7629         * debug.adb: Add debug flag -gnatd.q.
7630         * erroutc.adb (Prescan_Message): Bomb if untagged warning with
7631         -gnatd.q set.
7632         * styleg.adb (Check_Xtra_Parens): Message should be a style
7633         message.
7634         * sem_aggr.adb, sem_ch3.adb, exp_ch9.adb, checks.adb, sem_prag.adb,
7635         par-endh.adb, eval_fat.adb, freeze.adb, sem_util.adb, sem_attr.adb,
7636         sem_elab.adb, sem_ch6.adb, sem_warn.adb, sem_cat.adb,
7637         sem_ch13.adb, lib-xref.adb: Add remaining warning tags.
7639 2014-06-11  Ben Brosgol  <brosgol@adacore.com>
7641         * gnat_rm.texi: Revised chapter on Implementation Defined
7642         Characteristics.
7644 2014-06-11  Geert Bosch  <bosch@adacore.com>
7646         * s-exctab.adb: avoid race conditions in exception registration.
7648 2014-06-11  Robert Dewar  <dewar@adacore.com>
7650         * errout.adb (Warn_Insertion): New function.
7651         (Error_Msg): Use Warn_Insertion and Prescan_Message.
7652         (Error_Msg_Internal): Set Info field of error object.
7653         (Error_Msg_NEL): Use Prescan_Message.
7654         (Set_Msg_Text): Don't store info: at start of message.
7655         (Skip_Msg_Insertion_Warning): New name for Set_Msg_Insertion_Warning.
7656         (Skip_Msg_Insertion_Warning): Now just skips warning insertion.
7657         * errout.ads: Document new ?$? and >$> insertion sequences
7658         Document use of "(style)" and "info: "
7659         * erroutc.adb (dmsg): Print several missing fields
7660         (Get_Warning_Tag): Handle -gnatel case (?$?)  (Output_Msg_Text):
7661         Deal with new tagging of info messages
7662         * erroutc.ads: Is_Info_Msg: New global (Error_Msg_Object):
7663         Add field Info (Prescan_Message): New procedure, this procedure
7664         replaces the old Test_Style_Warning_Serious_Unconditional_Msg
7665         * errutil.adb, exp_util.adb, par-ch7.adb, sem_ch13.adb, sem_ch7.adb,
7666         sem_elab.adb: Follow new rules for info message (info belongs
7667         only at the start of a message, and only in the first message,
7668         not in any of the continuations).
7669         * gnat_ugn.texi: Document full set of warning tags.
7671 2014-06-11  Gary Dismukes  <dismukes@adacore.com>
7673         * sem_util.adb: Minor typo fix.
7675 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
7677         * sem_warn.adb (Check_References): Do not emit spurious warnings
7678         on uninitialzed variable of a formal private type if variable
7679         is not read.
7681 2014-06-09  Jan Hubicka  <hubicka@ucw.cz>
7683         * gcc-interface/utils.c (process_attributes) <ATTR_LINK_SECTION>: Use
7684         set_decl_section_name accessor.
7686 2014-05-22  Thomas Schwinge  <thomas@codesourcery.com>
7688         * gcc-interface/utils.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
7689         (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
7690         (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
7692 2014-05-21  Robert Dewar  <dewar@adacore.com>
7694         * layout.adb: Minor reformatting.
7695         * sem_prag.adb (Analyze_Pragma, case Inspection_Point): Call
7696         dummy procedure ip.
7698 2014-05-21  Robert Dewar  <dewar@adacore.com>
7700         * restrict.ads (Implementation_Restriction): Add entry for
7701         No_Fixed_IO.
7702         * rtsfind.ads: Add entries for Fixed_IO and Decimal_IO in
7703         Ada.[Wide_[Wide_]Text_IO.
7704         * s-rident.ads (Restriction_Id): Add entry for No_Fixed_IO.
7705         * sem_attr.adb (Analyze_Attribute): Disallow fixed point types
7706         for Img, Image, Value, Wide_Image, Wide_Value, Wide_Wide_Image,
7707         Wide_Wide_Value if restriction No_Fixed_IO is set.
7708         * sem_util.adb (Set_Entity_Checks): Check restriction No_Fixed_IO.
7710 2014-05-21  Robert Dewar  <dewar@adacore.com>
7712         * gnatcmd.adb: Minor error msg changes (no upper case letter
7713         at start).
7714         * sem_ch12.adb, sem_ch5.adb, sem_res.adb, sem_util.adb: Minor
7715         reformatting.
7717 2014-05-21  Robert Dewar  <dewar@adacore.com>
7719         * debug.adb: Debug flag -gnatd.G inhibits static elab tracing
7720         via generic formals.
7721         * sem_elab.adb (Is_Call_Of_Generic_Formal): Return False if
7722         -gnatd.G is set.
7724 2014-05-21  Thomas Quinot  <quinot@adacore.com>
7726         * exp_pakd.adb (Revert_Storage_Order): Renamed from Byte_Swap to
7727         more accurately describe that this subprogram needs to come into
7728         play also in cases where no byte swapping is involved, because
7729         it also takes care of some required shifts (left-justification
7730         of values).
7732 2014-05-21  Thomas Quinot  <quinot@adacore.com>
7734         * freeze.adb (Check_Component_Storage_Order): Indicate whether
7735         a Scalar_Storage_Order attribute definition is present for the
7736         component's type.
7737         (Freeze_Record_Type): Suppress junk warnings
7738         about purportedly junk Bit_Order / Scalar_Storage_Order attribute
7739         definitions.
7741 2014-05-21  Robert Dewar  <dewar@adacore.com>
7743         * sem_ch8.adb (Analyze_Subprogram_Renaming): Put back call
7744         to Kill_Elaboration_Checks.
7746 2014-05-21  Gary Dismukes  <dismukes@adacore.com>
7748         * layout.adb (Assoc_Add): Suppress the optimization of the (E
7749         - C1) + C2 case, when the expression type is unsigned and C1 <
7750         C2, to avoid creating a negative literal when folding.
7752 2014-05-21  Hristian Kirtchev  <kirtchev@adacore.com>
7754         * freeze.adb (Freeze_Record_Type): Update the use of
7755         Is_SPARK_Volatile.
7756         * sem_ch3.adb (Analyze_Object_Contract): Update the use of
7757         Is_SPARK_Volatile.
7758         (Process_Discriminants): Update the use of Is_SPARK_Volatile.
7759         * sem_ch5.adb (Analyze_Iterator_Specification): Update the use
7760         of Is_SPARK_Volatile.
7761         (Analyze_Loop_Parameter_Specification):
7762         Update the use of Is_SPARK_Volatile.
7763         * sem_ch6.adb (Process_Formals): Catch an illegal use of an IN
7764         formal parameter when its type is volatile.
7765         * sem_prag.adb (Analyze_Global_Item): Update the use of
7766         Is_SPARK_Volatile.
7767         * sem_res.adb (Resolve_Entity_Name): Correct the guard which
7768         determines whether an entity is a volatile source SPARK object.
7769         * sem_util.adb (Has_Enabled_Property): Accout for external
7770         properties being set on objects other than abstract states
7771         and variables. An example would be a formal parameter.
7772         (Is_SPARK_Volatile): New routine.
7773         (Is_SPARK_Volatile_Object):
7774         Remove the entity-specific tests. Call routine Is_SPARK_Volatile
7775         when checking entities and/or types.
7776         * sem_util.ads (Is_SPARK_Volatile): New routine.
7778 2014-05-21  Robert Dewar  <dewar@adacore.com>
7780         * sem_warn.adb: Minor fix to warning messages (use ?? instead
7781         of ?).
7783 2014-05-21  Vincent Celier  <celier@adacore.com>
7785         * gnatcmd.adb (GNATCmd): For platforms other than VMS, recognize
7786         switch --version and --help.
7788 2014-05-21  Robert Dewar  <dewar@adacore.com>
7790         * sem_elab.adb (Is_Call_Of_Generic_Formal): New function.
7792 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
7794         * sem_ch5.adb (Analyze_Iterator_Specification): Set type of
7795         iterator variable when the domain of iteration is a formal
7796         container and this is an element iterator.
7798 2014-05-21  Bob Duff  <duff@adacore.com>
7800         * sem_ch12.adb: Minor reformatting.
7802 2014-05-21  Robert Dewar  <dewar@adacore.com>
7804         * sinfo.ads, sem_ch12.adb, sem_warn.adb: Minor reformatting.
7806 2014-05-21  Robert Dewar  <dewar@adacore.com>
7808         * sem_elab.adb: Minor reformatting.
7809         * s-taprop.ads: Minor comment fix.
7810         * sem_ch8.adb (Analyze_Subprogram_Renaming): Remove call to
7811         Kill_Elaboration_Checks.
7812         * errout.adb, erroutc.adb: Minor reformatting.
7814 2014-05-21  Thomas Quinot  <quinot@adacore.com>
7816         * exp_pakd.adb (Byte_Swap): Handle the case of a sub-byte
7817         component. No byte swapping occurs, but this procedure also takes
7818         care of appropriately justifying the argument.
7820 2014-05-21  Hristian Kirtchev  <kirtchev@adacore.com>
7822         * sem_ch6.adb: sem_ch6.adb (Analyze_Aspects_On_Body_Or_Stub):
7823         New routine.
7824         (Analyze_Subprogram_Body_Helper): Move the
7825         analysis of aspect specifications and the processing of the
7826         subprogram body contract after inlining has taken place.
7827         (Diagnose_Misplaced_Aspect_Specifications): Removed.
7829 2014-05-21  Javier Miranda  <miranda@adacore.com>
7831         * sem_ch3.adb (Build_Derived_Record_Type): Revert previous change.
7833 2014-05-21  Robert Dewar  <dewar@adacore.com>
7835         * sem_eval.ads, sem_eval.adb (Why_Not_Static): Messages are not
7836         continuations any more.
7838 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
7840         * sinfo.ads, sinfo.adb: New flag Needs_Initialized_Actual,
7841         present in formal_Private_Definitions and on private extension
7842         declarations of a formal derived type. Set when the use of the
7843         formal type in a generic suggests that the actual should be a
7844         fully initialized type.
7845         * sem_warn.adb (May_Need_Initialized_Actual): new subprogram
7846         to indicate that an entity of a generic type has default
7847         initialization, and that the corresponing actual type in any
7848         subsequent instantiation should be fully initialized.
7849         * sem_ch12.adb (Check_Initialized_Type): new subprogram,
7850         to emit a warning if the actual for a generic type on which
7851         Needs_Initialized_Actual is set is not a fully initialized type.
7853 2014-05-21  Robert Dewar  <dewar@adacore.com>
7855         * sem_elab.adb, prj-dect.adb: Minor reformatting.
7857 2014-05-21  Robert Dewar  <dewar@adacore.com>
7859         * erroutc.ads: Minor comment addition.
7861 2014-05-21  Robert Dewar  <dewar@adacore.com>
7863         * errout.ads: Add documentation for use of >*> tag.
7864         * restrict.adb: Make sure we use >*> tag for restriction warnings.
7866 2014-05-21  Gary Dismukes  <dismukes@adacore.com>
7868         * debug.adb: Add case of illegal overriding_indicator for a
7869         protected subprogram body to description of -gnatd.E switch.
7870         * sem_ch6.adb (Verify_Overriding_Indicator): Issue error message
7871         for cases of giving overriding_indicators on protected subprogram
7872         bodies, but change this to a warning if -gnatd.E is enabled. No
7873         longer give a style warning about missing indicators on protected
7874         subprogram bodies.
7876 2014-05-21  Robert Dewar  <dewar@adacore.com>
7878         * prj.ads, sem_ch12.adb, prj.adb, exp_pakd.adb,
7879         sem_elab.ads: Minor reformatting.
7880         * erroutc.adb, erroutc.ads (Warning_Specifically_Suppressed): Make Tag
7881         parameter optional.
7883 2014-05-21  Pascal Obry  <obry@adacore.com>
7885         * prj-dect.adb: Allow package Install in aggregate project.
7887 2014-05-21  Robert Dewar  <dewar@adacore.com>
7889         * sem_ch13.adb (Analyze_Aspect_Specifications):
7890         Insert_Delayed_Pragma is now used for the case of Attach_Handler.
7891         * sem_prag.adb: Minor comment improvements.
7893 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
7895         * sem_ch12.adb (Install_Body): When checking whether freezing of
7896         instantiation must be delayed, verify that the common enclosing
7897         subprogram to generic and instance is in fact an overloadable
7898         entity.
7900 2014-05-21  Vincent Celier  <celier@adacore.com>
7902         * makeutl.adb (Mains.Complete_Mains.Do_Complete): Look for all
7903         mains with the same name and fail if there is more than one.
7904         * prj.ads, prj.adb (Find_All_Sources): New function
7906 2014-05-21  Robert Dewar  <dewar@adacore.com>
7908         * sem_ch13.adb: Minor reformatting.
7909         * lib-xref-spark_specific.adb, sem_util.adb: Minor reformatting.
7910         * sem_prag.adb: Minor error message improvement.
7912 2014-05-21  Yannick Moy  <moy@adacore.com>
7914         * lib-xref-spark_specific.adb, lib-xref.ads, lib-xref.adb
7915         (Enclosing_Subprogram_Or_Package): Only return a library-level
7916         package.
7918 2014-05-21  Javier Miranda  <miranda@adacore.com>
7920         * sem_ch3.adb (Build_Derived_Record_Type): Initialize Parent_Base
7921         to the full view of the parent type when processing a derived type
7922         which is the full view of a private type not defined in a generic
7923         unit which is derived from a private type with discriminants
7924         whose full view is a non-tagged record type.
7926 2014-05-21  Javier Miranda  <miranda@adacore.com>
7928         * exp_ch4.adb (Expand_Allocator_Expression.Apply_Accessibility_Check):
7929         Complete previous patch.
7931 2014-05-21  Thomas Quinot  <quinot@adacore.com>
7933         PR ada/9535
7934         * g-socket.adb (Read and Write for Datagram_Socket_Stream_Type):
7935         Provide a behaviour more consistent with underlying datagram
7936         socket: do not attempt to loop over Send_Socket/Receive_Socket
7937         iterating along the buffer.
7939 2014-05-21  Hristian Kirtchev  <kirtchev@adacore.com>
7941         * freeze.adb (Freeze_Record_Type): Ensure that a discriminated
7942         or a tagged type is not labelled as volatile. Ensure that a
7943         non-volatile type has no volatile components.
7944         * sem_ch3.adb (Analyze_Object_Contract): Add local constant
7945         Obj_Typ. Code reformatting.  Ensure that a discriminated or
7946         tagged object is not labelled as volatile.
7947         * sem_prag.adb (Process_Atomic_Shared_Volatile): Ensure that
7948         pragma Volatile applies to a full type declaration or an object
7949         declaration when SPARK mode is on.
7951 2014-05-21  Sergey Rybin  <rybin@adacore.com frybin>
7953         * gnat_ugn.texi: For ASIS tools, reword the paragraph about
7954         providing options needed for compiling the argument source for
7955         the situation when a project file can be used as a tool parameter.
7957 2014-05-21  Gary Dismukes  <dismukes@adacore.com>
7959         * gnat_rm.texi: Minor typo fix.
7961 2014-05-21  Robert Dewar  <dewar@adacore.com>
7963         * stand.adb (Tree_Read): Read missing entities.
7964         (Tree_Write): Write missing entities.
7966 2014-05-21  Ben Brosgol  <brosgol@adacore.com>
7968         * gnat_ugn.texi: Wordsmithing edits to Coupling Metrics Control
7969         section in gnatmetric chapter.
7971 2014-05-21  Robert Dewar  <dewar@adacore.com>
7973         * exp_ch6.adb (Expand_Actuals): Spec moved here, since not used
7974         outside Exp_Ch6 (Expand_Actuals): Deal with proper insertion of
7975         post-call copy write back (see detailed comment in code).
7976         * exp_ch6.ads (Expand_Actuals): Moved to body, not used outside
7977         Exp_Ch6.
7978         * tbuild.ads: Minor reformatting.
7980 2014-05-21  Robert Dewar  <dewar@adacore.com>
7982         * stand.ads: Add warning about adding new entities and
7983         Tree_Read/Tree_Write.
7985 2014-05-21  Robert Dewar  <dewar@adacore.com>
7987         * sem_util.adb (Set_Entity_With_Checks): Don't complain about
7988         references to restricted entities within the units in which they
7989         are declared.
7991 2014-05-21  Robert Dewar  <dewar@adacore.com>
7993         * gnat1drv.adb (Check_Bad_Body): Use Source_File_Is_Body to
7994         simplify the needed test, and also deal with failure to catch
7995         situations with non-standard names.
7996         * sinput-l.ads, sinput-l.adb (Source_File_Is_No_Body): New function
7997         (Source_File_Is_Subunit): Removed, no longer used.
7999 2014-05-21  Javier Miranda  <miranda@adacore.com>
8001         * exp_ch4.adb
8002         (Expand_Allocator_Expression.Apply_Accessibility_Check): for a
8003         renaming of an access to interface object there is no need to
8004         generate extra code to reference the tag.
8006 2014-05-21  Robert Dewar  <dewar@adacore.com>
8008         * errout.adb, erroutc.adb, erroutc.ads: Allow warning tag in pragma
8009         Warnings (Off, string).
8011 2014-05-21  Robert Dewar  <dewar@adacore.com>
8013         * osint.adb: Fix three error messages to say invalid instead
8014         of erroneous.
8015         * par-ch4.adb, exp_aggr.adb, sem_attr.adb, sem_aux.adb, sem_ch3.adb,
8016         sem_ch5.adb, sem_ch6.adb, sem_ch7.adb, sem_dim.adb, sem_res.adb,
8017         sem_util.adb, sem_util.ads: Fix incorrect use of erroneous in comments.
8019 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
8021         * freeze.adb, sem_ch13.adb, sem_ch13.ads, sem_ch9.adb,
8022         sem_ch9.ads: Move discriminant manipulation routines for analysis of
8023         aspect specifications from sem_ch9 to sem_ch13, where they belong.
8025 2014-05-21  Robert Dewar  <dewar@adacore.com>
8027         * gnat_ugn.texi: Clearly document -gnatw.g (GNAT warnings).
8028         Clearly document -gnatyg (GNAT style switches).
8029         * usage.adb: Add line line for -gnatw.g (GNAT warnings) More
8030         detail for line for -gnatyg (GNAT style switches) -gnatw.d/D is
8031         available for VMS after all.
8032         * warnsw.adb: Reorganize to eliminate duplicated code
8033         (Restore_Warnings): Add a couple of missing entries
8034         (Save_Warnings): Add a couple of missing entries.
8035         * warnsw.ads: Add missing entries to Warning_Record (not clear
8036         what the impact is).
8038 2014-05-21  Robert Dewar  <dewar@adacore.com>
8040         * errout.adb (Set_Msg_Insertion_Warning): Handle ?*? (restriction
8041         warning) case.
8042         * errout.ads: Document ?*? (restriction warning) insertion.
8043         * erroutc.adb (Get_Warning_Tag): Deal with ?*? (restriction
8044         warning) case.
8045         * erroutc.ads: Document use of * for restriction warning tag.
8046         * restrict.adb (Restriction_Msg): Tag with ?*? instead of ??.
8048 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
8050         * sem_ch9.adb (Push_Scope_And_Install_Discriminants): Do not
8051         make discriminants immediately visible when analyzing an aspect
8052         of a subtype declaration.
8053         (Uninstall_Discriminants): Do not apply to the entity in a
8054         subtype declaration.
8056 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
8058         * sem_util.adb: Code clean up.
8060 2014-05-21  Eric Botcazou  <ebotcazou@adacore.com>
8062         * gnat_ugn.texi: Document -Werror.
8064 2014-05-21  Bob Duff  <duff@adacore.com>
8066         * sem_util.adb (Is_Dependent_Component_Of_Mutable_Object):
8067         This was returning False if the Object is a constant view. Fix
8068         it to return True in that case, because it might be a view of
8069         a variable.
8070         (Has_Discriminant_Dependent_Constraint): Fix latent
8071         bug; this function was crashing when passed a discriminant.
8073 2014-05-21  Robert Dewar  <dewar@adacore.com>
8075         * gnat_ugn.texi: Remove misplaced section that is now obsolete.
8076         * s-arit64.adb: Minor code reorganization.
8077         * sem_prag.adb: Minor comment fix (remove erroneous use of the
8078         term erroneous).
8080 2014-05-21  Robert Dewar  <dewar@adacore.com>
8082         * g-table.adb, g-dyntab.adb (Reallocate): Fix possible overflow in
8083         computing new table size.
8085 2014-05-21  Robert Dewar  <dewar@adacore.com>
8087         * einfo.ads: Minor reformatting.
8088         * ceinfo.adb: Deal with slight format change of einfo.ads.
8090 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
8092         * sem_prag.adb (Analyze_Part_Of): Further work on the proper
8093         implementation of the SPARK 2014 rule concerning private child
8094         units (LRM 7.2.6).
8096 2014-05-21  Vincent Celier  <celier@adacore.com>
8098         * makeusg.adb: Add switch -d to usage.
8100 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
8102         * sem_util.adb (Find_Actual): If an actual that is the prefix
8103         of an enclosing prefixed call has been rewritten, use Nkind
8104         and Sloc to identify the corresponding formal, when handling
8105         deferred references.
8107 2014-05-21  Robert Dewar  <dewar@adacore.com>
8109         * debug.adb: Document -gnatd.z switch.
8110         * sem_eval.adb (Why_Non_Static): Test -gnatd.z switch.
8112 2014-05-21  Robert Dewar  <dewar@adacore.com>
8114         * einfo.ads (Can_Never_Be_Null): Minor comment update.
8115         * sem_prag.adb (Check_Arg_Is_Task_Dispatching_Policy): Minor
8116         error message change.
8117         * s-arit64.adb ("abs"): New function. Use expression functions
8118         for the simple conversions and arithmetic.
8120 2014-05-18  Eric Botcazou  <ebotcazou@adacore.com>
8122         * gcc-interface/trans.c (Subprogram_Body_to_gnu): Rework comment and
8123         set function_start_locus.
8125 2014-05-18  Eric Botcazou  <ebotcazou@adacore.com>
8127         * utils.c (gnat_write_global_declarations): Adjust the flags put on
8128         dummy_global.
8130 2014-05-18  Eric Botcazou  <ebotcazou@adacore.com>
8132         * gcc-interface/decl.c (change_qualified_type): New static function.
8133         (gnat_to_gnu_entity): Use it throughout to add qualifiers on types.
8134         <E_Array_Type>: Set TYPE_VOLATILE on the array type directly.
8135         <E_Array_Subtype>: Likewise.
8136         Do not set flags on an UNCONSTRAINED_ARRAY_TYPE directly.
8137         (gnat_to_gnu_component_type): Likewise.
8138         (gnat_to_gnu_param): Likewise.
8140 2014-05-18  Eric Botcazou  <ebotcazou@adacore.com>
8142         * fe.h (Set_Present_Expr): Move around.
8143         (End_Location): New macro.
8144         * gcc-interface/trans.c (Case_Statement_to_gnu): Use End_Location.
8146 2014-05-18  Eric Botcazou  <ebotcazou@adacore.com>
8148         * gcc-interface/decl.c (gnat_to_gnu_entity): Use Underlying_Type in
8149         lieu of more verbose construct.
8150         * gcc-interface/trans.c (Call_to_gnu): Likewise.
8151         (gnat_to_gnu): Likewise.  Remove obsolete code.
8153 2014-05-18  Eric Botcazou  <ebotcazou@adacore.com>
8155         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Subtype>: Do not
8156         consider that regular packed arrays can never be superflat.
8158 2014-05-17  Trevor Saunders  <tsaunders@mozilla.com>
8160         * gcc-interface/ada-tree.h: Remove usage of variable_size gty
8161         annotation.
8162         * gcc-interface/decl.c (annotate_value): Adjust.
8163         * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
8164         (push_range_check_info): Likewise.
8165         (Loop_Statement_to_gnu): Likewise.
8166         (Subprogram_Body_to_gnu): Likewise.
8167         (Compilation_Unit_to_gnu): Likewise.
8168         (start_stmt_group): Likewise.
8169         * gcc-interface/utils.c (init_gnat_utils): Likewise.
8170         (gnat_pushlevel): Likewise.
8171         (maybe_pad_type): Likewise.
8173 2014-05-14  Eric Botcazou  <ebotcazou@adacore.com>
8175         * seh_init.c: Fix copyright year.
8177 2014-05-14  Bernd Edlinger  <bernd.edlinger@hotmail.de>
8179         * seh_init.c (__gnat_map_SEH): Compile also when __CYGWIN__ and __SEH__
8180         are defined.  Move include windows.h before system.h.
8181         * s-oscons-tmplt.c (DTR_CONTROL_ENABLE, RTS_CONTROL_ENABLE): Compile
8182         also when __CYGWIN__ is defined.  Include windef.h before winbase.h.
8184 2014-05-14  Richard Sandiford  <r.sandiford@uk.ibm.com>
8186         * gcc-interface/decl.c (gnat_to_gnu_entity): Convert integer_one_node
8187         to the appropriate type.
8188         * gcc-interface/trans.c (gnat_to_gnu): Likewise.
8189         (pos_to_constructor): Likewise.
8191 2014-05-13  Eric Botcazou  <ebotcazou@adacore.com>
8193         * gcc-interface/decl.c (annotate_value): Fix thinko in latest change.
8195 2014-05-06  Kenneth Zadeck  <zadeck@naturalbridge.com>
8196             Mike Stump  <mikestump@comcast.net>
8197             Richard Sandiford  <rdsandiford@googlemail.com>
8199         * gcc-interface/cuintp.c (UI_From_gnu): Use wide-int interfaces.
8200         * gcc-interface/decl.c (gnat_to_gnu_entity): Use TYPE_SIGN.
8201         (annotate_value): Use wide-int interfaces.
8202         * gcc-interface/utils.c (get_nonnull_operand): Use tree_fits_uhwi_p.
8204 2014-04-28  Richard Henderson  <rth@redhat.com>
8206         * gcc-interface/Makefile.in: Support aarch64-linux.
8208 2014-04-28  Eric Botcazou  <ebotcazou@adacore.com>
8210         * exp_dbug.ads (Get_External_Name): Add 'False' default to Has_Suffix,
8211         add 'Suffix' parameter and adjust comment.
8212         (Get_External_Name_With_Suffix): Delete.
8213         * exp_dbug.adb (Get_External_Name_With_Suffix): Merge into...
8214         (Get_External_Name): ...here.  Add 'False' default to Has_Suffix, add
8215         'Suffix' parameter.
8216         (Get_Encoded_Name): Remove 2nd argument in call to Get_External_Name.
8217         Call Get_External_Name instead of Get_External_Name_With_Suffix.
8218         (Get_Secondary_DT_External_Name): Likewise.
8219         * exp_cg.adb (Write_Call_Info): Likewise.
8220         * exp_disp.adb (Export_DT): Likewise.
8221         (Import_DT): Likewise.
8222         * comperr.ads (Compiler_Abort): Remove Code parameter and add From_GCC
8223         parameter with False default.
8224         * comperr.adb (Compiler_Abort): Likewise.  Adjust accordingly.
8225         * types.h (Fat_Pointer): Rename into...
8226         (String_Pointer): ...this.  Add comment on interfacing rules.
8227         * fe.h (Compiler_Abort): Adjust for above renaming.
8228         (Error_Msg_N): Likewise.
8229         (Error_Msg_NE): Likewise.
8230         (Get_External_Name): Likewise.  Add third parameter.
8231         (Get_External_Name_With_Suffix): Delete.
8232         * gcc-interface/decl.c (STDCALL_PREFIX): Define.
8233         (create_concat_name): Adjust call to Get_External_Name, remove call to
8234         Get_External_Name_With_Suffix, use STDCALL_PREFIX, adjust for renaming.
8235         * gcc-interface/trans.c (post_error): Likewise.
8236         (post_error_ne): Likewise.
8237         * gcc-interface/misc.c (internal_error_function): Likewise.
8239 2014-04-28  Richard Biener  <rguenther@suse.de>
8241         PR middle-end/60092
8242         * gcc-interface/utils.c: Define flag_isoc11.
8244 2014-04-26  Eric Botcazou  <ebotcazou@adacore.com>
8246         * gnatvsn.ads (Library_Version): Bump to 4.10.
8248 2014-04-23  Eric Botcazou  <ebotcazou@adacore.com>
8250         Revert
8251         2014-04-22  Richard Henderson  <rth@redhat.com>
8253         * gcc-interface/Makefile.in: Support aarch64-linux.
8255         2014-04-22  Eric Botcazou  <ebotcazou@adacore.com>
8257         * fe.h (Compiler_Abort): Replace Fat_Pointer with String_Pointer.
8258         (Error_Msg_N): Likewise.
8259         (Error_Msg_NE): Likewise.
8260         (Get_External_Name_With_Suffix): Likewise.
8261         * types.h (Fat_Pointer): Delete.
8262         (String_Pointer): New type.
8263         (DECLARE_STRING_POINTER): New macro.
8264         * gcc-interface/decl.c (create_concat_name): Adjust.
8265         * gcc-interface/trans.c (post_error): Likewise.
8266         (post_error_ne): Likewise.
8267         * gcc-interface/misc.c (internal_error_function): Likewise.
8269 2014-04-22  Richard Henderson  <rth@redhat.com>
8271         * gcc-interface/Makefile.in: Support aarch64-linux.
8273         * init.c [__linux__] (HAVE_GNAT_ALTERNATE_STACK): New define.
8274         (__gnat_alternate_stack): Enable for all linux except ia64.
8276 2014-04-22  Eric Botcazou  <ebotcazou@adacore.com>
8278         * fe.h (Compiler_Abort): Replace Fat_Pointer with String_Pointer.
8279         (Error_Msg_N): Likewise.
8280         (Error_Msg_NE): Likewise.
8281         (Get_External_Name_With_Suffix): Likewise.
8282         * types.h (Fat_Pointer): Delete.
8283         (String_Pointer): New type.
8284         (DECLARE_STRING_POINTER): New macro.
8285         * gcc-interface/decl.c (create_concat_name): Adjust.
8286         * gcc-interface/trans.c (post_error): Likewise.
8287         (post_error_ne): Likewise.
8288         * gcc-interface/misc.c (internal_error_function): Likewise.
8290 2014-04-15  Eric Botcazou  <ebotcazou@adacore.com>
8291             Pierre-Marie de Rodat  <derodat@adacore.com>
8293         * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create a mere
8294         scalar constant instead of a reference for renaming of scalar literal.
8295         Do not create a new object for constant renaming except for a function
8296         call.  Make sure a VAR_DECL is created for the renaming pointer.
8297         * gcc-interface/trans.c (constant_decl_with_initializer_p): New.
8298         (fold_constant_decl_in_expr): New function.
8299         (Identifier_to_gnu): Use constant_decl_with_initializer_p.
8300         For a constant renaming, try to fold a constant DECL in the result.
8301         (lvalue_required_p) <N_Object_Renaming_Declaration>: Always return 1.
8302         (Identifier_to_gnu): Reference the renamed object of constant renaming
8303         pointers directly.
8304         * gcc-interface/utils.c (invalidate_global_renaming_pointers): Do not
8305         invalidate constant renaming pointers.
8307 2014-04-15  Eric Botcazou  <ebotcazou@adacore.com>
8309         * gcc-interface/utils.c (type_for_vector_element_p): New predicate.
8310         (build_vector_type_for_size): New function.
8311         (build_vector_type_for_array): Likewise.
8312         (unchecked_convert): Build an intermediate vector type to convert
8313         from a generic array type to a vector type.
8314         (handle_vector_size_attribute): Reimplement.
8315         (handle_vector_type_attribute): Likewise.
8317 2014-04-15  Eric Botcazou  <ebotcazou@adacore.com>
8319         * gcc-interface/decl.c (prepend_one_attribute_pragma): Call
8320         Is_OK_Static_Expression in lieu of Is_Static_Expression to
8321         detect valid arguments.
8323 2014-04-15  Eric Botcazou  <ebotcazou@adacore.com>
8325         * gcc-interface/trans.c (gnat_gimplify_stmt): Propagate loop hints.
8327 2014-04-14  Paolo Carlini  <paolo.carlini@oracle.com>
8329         * gcc-interface/decl.c (gnat_to_gnu_entity): Use TYPE_IDENTIFIER.
8330         (components_to_record): Likewise.
8331         * gcc-interface/utils.c (make_aligning_type): Likewise.
8332         (maybe_pad_type): Likewise.
8333         (finish_record_type): Likewise.
8334         (rest_of_record_type_compilation): Likewise.
8336 2014-04-14  Eric Botcazou  <ebotcazou@adacore.com>
8338         * snames.ads-tmpl (Name_Ivdep): New pragma-related name.
8339         * sem_prag.adb (Analyze_Pragma) <Pragma_Loop_Optimize>: Add support
8340         for Ivdep hint.
8341         * gnat_rm.texi (Implementation Defined Pragmas): Document new Ivdep
8342         hint for Loop_Optimize.
8343         * gnat_ugn.texi (Vectorization of loops): Mention new Ivdep hint.
8344         * gcc-interface/trans.c (Pragma_to_gnu) <Pragma_Loop_Optimize>: Deal
8345         with new Ivdep hint.
8346         * gcc-interface/ada-tree.h (LOOP_STMT_IVDEP): New macro.
8347         * gcc-interface/trans.c (Pragma_to_gnu) <Pragma_Loop_Optimize>: Deal
8348         with new Ivdep hint.
8349         (gnat_gimplify_stmt) <LOOP_STMT>: Propagate loop hints.
8351 2014-04-14  Eric Botcazou  <ebotcazou@adacore.com>
8352             Robert Dewar  <dewar@adacore.com>
8354         * opt.ads (Suppress_Back_Annotation): Remove as unused.
8355         * fe.h (Back_Annotate_Rep_Info): Likewise.
8356         (Global_Discard_Names): Likewise.
8357         (List_Representation_Info): Declare.
8358         * types.h (Uint_Minus_1): Likewise.
8359         * repinfo.ads: Document back-annotation change.
8360         * gcc-interface/gigi.h (init_gnat_decl): Declare.
8361         (destroy_gnat_decl): Likewise.
8362         * gcc-interface/decl.c (annotate_value): Do not create the cache of
8363         annotated values here but...
8364         <CALL_EXPR>: Only inline the call if -gnatR3 is specified or we are
8365         in ASIS mode.
8366         (init_gnat_decl): ...here instead.  New function.
8367         (destroy_gnat_decl): Likewise.
8368         * gcc-interface/trans.c (gigi): Call {init|destroy}_gnat_decl.
8369         * gcc-interface/utils.c (init_gnat_utils): Minor reformatting.
8371 2014-04-14  Eric Botcazou  <ebotcazou@adacore.com>
8373         * gcc-interface/decl.c (create_field_decl_from): Finalize non-constant
8374         offset for the field, if any.
8376 2014-04-09  Eric Botcazou  <ebotcazou@adacore.com>
8377             Svante Signell  <svante.signell@gmail.com>
8379         PR ada/54040
8380         PR ada/59346
8381         * s-osinte-x32.adb: New file.
8382         * s-linux.ads (Time): New section.
8383         * s-linux-alpha.ads (Time): Likewise.
8384         * s-linux-android.ads (Time: Likewise.
8385         * s-linux-hppa.ads (Time): Likewise.
8386         * s-linux-mipsel.ads (Time): Likewise.
8387         * s-linux-sparc.ads (Time): Likewise.
8388         * s-linux-x32.ads (Time): Likewise.
8389         * s-osprim-x32.ads (timespec): Adjust.
8390         (Clock): Likewise.
8391         (To_Timespec): Likewise.
8392         * s-osinte-linux.ads (Time): Define local subtypes for those defined
8393         in System.Linux.
8394         * s-taprop-linux.adb (Monotonic_Clock): Do not define timeval.
8395         * s-osinte-hpux.ads (timespec): Revert POSIX breakage.
8396         * s-osinte-kfreebsd-gnu.ads (timespec): Likewise.
8397         * s-osinte-solaris-posix.ads (timespec): Likewise.
8398         * s-osinte-posix.adb (To_Timespec): Likewise.
8399         * gcc-interface/Makefile.in (x32/Linux): Use s-osinte-x32.adb.
8401 2014-04-08  Eric Botcazou  <ebotcazou@adacore.com>
8403         PR ada/60411
8404         * gcc-interface/Makefile.in (arm% linux-android): Switch to EHABI.
8405         * s-linux-android.ads: New file.
8406         * s-intman-android.adb: Likewise.
8407         * s-osinte-android.ads: Adjust.
8408         * sigtramp-armdroid.c: Likewise.
8409         * sigtramp.h: Add Android support.
8411 2014-04-07  Eric Botcazou  <ebotcazou@adacore.com>
8413         * gcc-interface/Makefile.in (alpha-vms): Add missing line.
8415 2014-03-30  Eric Botcazou  <ebotcazou@adacore.com>
8417         PR ada/60703
8418         * system-linux-alpha.ads: Adjust for Ada 2005.
8419         * system-linux-mips.ads: Likewise.
8420         * system-linux-mips64el.ads: Likewise.
8421         * system-linux-mipsel.ads: Likewise.
8422         * system-linux-s390.ads: Likewise.
8423         * system-linux-s390x.ads: Likewise.
8424         * system-linux-sparc.ads: Likewise.
8425         * system-linux-sparcv9.ads: Likewise.
8426         * system-rtems.ads: Likewise.
8427         * system-vxworks-arm.ads: Likewise.
8429 2014-03-16  Andreas Schwab  <schwab@linux-m68k.org>
8431         PR ada/39172
8432         * gcc-interface/Makefile.in (target_cpu_default): Revert
8433         2013-10-11 change.
8435 2014-03-13  Eric Botcazou  <ebotcazou@adacore.com>
8437         PR ada/51483
8438         * cstand.adb (Register_Float_Type): Add 'precision' parameter and use
8439         it to set the RM size.  Use directly 'size' for the Esize.
8440         (Create_Back_End_Float_Types): Adjust call to above.
8441         * get_targ.ads (Register_Type_Proc): Add 'precision' parameter.
8442         * set_targ.ads (FPT_Mode_Entry): Add 'precision' component.
8443         (Write_Target_Dependent_Values): Adjust comment.
8444         * set_targ.adb (Register_Float_Type): Add 'precision' parameter and
8445         deal with it.
8446         (Write_Target_Dependent_Values): Write the precision in lieu of size.
8447         (Initialization): Read the precision in lieu of size and compute the
8448         size from the precision and the alignment.
8449         * gcc-interface/gigi.h (enumerate_modes): Add integer parameter.
8450         * gcc-interface/misc.c (enumerate_modes): Likewise.  Do not register
8451         types for vector modes, pass the size in addition to the precision.
8453 2014-03-10  Eric Botcazou  <ebotcazou@adacore.com>
8455         * gcc-interface/Make-lang.in (ADA_DEPFILES): Fix typo.
8457 2014-03-07  Doug Rupp  <rupp@adacore.com>
8459         PR ada/60411
8460         * system-linux-armel.ads (Backend_Overflow_Checks): Set to True.
8461         (Support_64_Bit_Divides): Removed, no longer used.
8462         (ZCX_By_Default): Enabled.
8464 2014-02-25  Doug Rupp  <rupp@adacore.com>
8466         * gcc-interface/Makefile.in (arm-linux):
8467         (EH_MECHANISM): Use ARM unwinder (-arm)
8468         (LIBGNAT_TARGET_PAIRS: Override defaults with a-exexpr-gcc.adb and
8469         s-excmac-arm.ads.
8470         (EXTRA_LIBGNAT_OBJS): Add raise-gcc.o
8471         (EXTRA_GNATRTL_NONTASKING_OBJS): Add g-cppexc.o s-excmac.o.
8472         (arm-wrs-vxworks): Add EH_MECHANISM=-gcc for kernel mode.
8473         (EXTRA_LIBGNAT_OBJS): Add sigtramp-armvxw.o
8474         Add dependencies for sigtramp-armvxw.o.
8476 2014-02-25  Eric Botcazou  <ebotcazou@adacore.com>
8478         * gcc-interface/trans.c (Pragma_to_gnu): Deal with Warning_As_Error.
8480 2014-02-25  Robert Dewar  <dewar@adacore.com>
8482         * rtsfind.adb (Is_RTE): Protect against entity with no scope
8483         field (previously this call blew up on the Standard entity).
8484         * sem_attr.adb (Analyze_Attribute, case Access): Remove
8485         test for No_Abort_Statements, this is now handled in
8486         Set_Entity_With_Checks.
8487         * exp_ch6.adb, sem_ch10.adb, sem_ch4.adb, sem_ch8.adb, sem_res.adb:
8488         Change name Set_Entity_With_Style_Check => Set_Entity_With_Checks.
8489         * sem_util.ads, sem_util.adb: Change name Set_Entity_With_Style_Check =>
8490         Set_Entity_With_Checks.
8491         (Set_Entity_With_Checks): Add checks for No_Dynamic_Attachment,
8492         Add checks for No_Abort_Statements.
8494 2014-02-25  Robert Dewar  <dewar@adacore.com>
8496         * exp_ch9.adb (Expand_Entry_Barrier): Add comment that call to
8497         Check_Restriction is OK.
8499 2014-02-25  Ed Schonberg  <schonberg@adacore.com>
8501         * sem_ch3.adb (Process_Full_View): Better error message when
8502         the full view of  a private type without discriminants is an
8503         unconstrained type.
8504         * sem_ch7.adb (Uninstall_Declarations): Ditto.
8506 2014-02-25  Eric Botcazou  <ebotcazou@adacore.com>
8508         * sigtramp-armvxw.c: Also restore r0.
8510 2014-02-25  Robert Dewar  <dewar@adacore.com>
8512         * errout.adb (Error_Msg_Internal): Warning_Msg_Char set
8513         unconditionally (Set_Msg_Insertion_Warning): Warning_Msg_Char
8514         set unconditionally.
8515         * erroutc.adb (Get_Warning_Tag): Does not give a leading space
8516         any more (Output_Msg_Text): Rewritten with new convention on
8517         output of warnings that are treated as errors.
8518         * erroutc.ads (Error_Msg_Object): Warn_Chr is always set even
8519         if Warn is False.
8520         * gnat_rm.texi: Updates to documentation on pragma
8521         Warning_As_Error.
8522         * warnsw.adb (Set_Dot_Warning_Switch): -gnatw.e should not
8523         set Warning_Doc_Switch.
8524         * lib-writ.ads: Add documentation note on ALI file generation
8525         for C.
8526         * exp_ch6.adb (Expand_Call): Remove check for No_Abort_Statements
8527         (belongs in Sem).
8528         * sem_attr.adb (Resolve_Attribute, case Access):
8529         Abort_Task'Access violates the No_Abort_Statements restriction.
8530         * sem_res.adb (Resolve_Call): Check restriction
8531         No_Abort_Statements for call to Abort_Task or a renaming of it.
8533 2014-02-25  Robert Dewar  <dewar@adacore.com>
8535         * sem_ch3.adb (Array_Type_Declaration): Check for case of using
8536         type name as index.
8537         * lib.ads: Minor reformatting.
8538         * einfo.ads: Minor reformatting.
8540 2014-02-25  Doug Rupp  <rupp@adacore.com>
8542         * sem_mech.adb (Set_Mechanisms): For convention Fortran on VMS
8543         use Short_Descriptor(S) as the argument passing mechanism.
8545 2014-02-25  Eric Botcazou  <ebotcazou@adacore.com>
8547         * sigtramp-ppcvxw.c (CFI_COMMON_REGS): Also include r0.
8549 2014-02-25  Robert Dewar  <dewar@adacore.com>
8551         * atree.ads (Warnings_Treated_As_Errors): New variable.
8552         * errout.adb (Error_Msg_Internal): Set Warn_Err flag in
8553         error object (Initialize): Initialize Warnings_As_Errors_Count
8554         (Write_Error_Summary): Include count of warnings treated as errors.
8555         * erroutc.adb (Warning_Treated_As_Error): New function.
8556         (Matches): Function moved to outer level of package.
8557         * erroutc.ads (Error_Msg_Object): Add Warn_Err flag.
8558         (Warning_Treated_As_Error): New function.
8559         * gnat_rm.texi: Document pragma Treat_Warning_As_Error.
8560         * opt.adb: Add handling of Warnings_As_Errors_Count[_Config].
8561         * opt.ads (Config_Switches_Type): Add entry for
8562         Warnings_As_Errors_Count.
8563         (Warnings_As_Errors_Count): New variable.
8564         (Warnings_As_Errors): New array.
8565         * par-prag.adb: Add dummy entry for Warning_As_Error.
8566         * sem_prag.adb (Analyze_Pragma): Implement new pragma
8567         Warning_As_Error.
8568         * snames.ads-tmpl: Add entries for Warning_As_Error pragma.
8570 2014-02-25  Eric Botcazou  <ebotcazou@adacore.com>
8572         * sigtramp.h: Fix minor inaccuracy.
8574 2014-02-25  Ben Brosgol  <brosgol@adacore.com>
8576         * gnat_ugn.texi: Added description of kill command.
8578 2014-02-25  Robert Dewar  <dewar@adacore.com>
8580         * gnat_rm.texi (Address_Clauses): Add a section discussing the
8581         problem of address clauses causing unexpected initialization,
8582         including the effect of Initialize_Scalars.
8584 2014-02-25  Robert Dewar  <dewar@adacore.com>
8586         * errout.adb: Various changes for better msgs for anonmous access
8587         subprogram types.
8588         * erroutc.ads, erroutc.adb (Buffer_Ends_With): Version with character
8589         argument.
8590         (Buffer_Remove): Version with character argument.
8591         * sem_attr.adb (Resolve_Attribute, case Access): Better handling
8592         of mismatching conventions for access-to-subprogram case.
8593         * sem_prag.adb (Set_Convention_From_Pragma): Deal with anonymous
8594         access types in record.
8595         * sem_util.ads, sem_util.adb (Set_Convention): Handle anonymous access
8596         types, including in records.
8598 2014-02-25  Doug Rupp  <rupp@adacore.com>
8600         * sigtramp-ppcvxw.c, sigtramp.h, sigtramp-armvxw.c: Comment
8601         enhancements and corrections.
8603 2014-02-25  Robert Dewar  <dewar@adacore.com>
8605         * gnat_rm.texi: New section "Conventions and Anonymous Access Types"
8607 2014-02-25  Robert Dewar  <dewar@adacore.com>
8609         * gnat_rm.texi: First set of documentation additions for
8610         predefined RM units.
8611         * checks.adb: Minor reformatting.
8612         * sem_elab.adb (Check_Task_Activation): Minor fix to error
8613         message.
8614         * sem_util.adb: Minor reformatting.
8616 2014-02-25  Arnaud Charlet  <charlet@adacore.com>
8618         * usage.adb (Usage): Add help on -gnateC.
8619         * switch-c.adb (Scan_Front_End_Switches): Add handling of -gnateC.
8620         * opt.ads (Generate_CodePeer_Messages): New flag.
8621         * gnat_ugn.texi: Document new switch -gnateC.
8623 2014-02-25  Ben Brosgol  <brosgol@adacore.com>
8625         * gnat_rm.texi: Corrected minor typos in Implementation Defined
8626         Aspects.
8627         * opt.ads: Minor reformatting.
8629 2014-02-25  Robert Dewar  <dewar@adacore.com>
8631         * binde.adb: Change messages to mention -gnatel instead of -gnatwl.
8632         * gnat_ugn.texi: Update documentation of -gnatwl Add documentation
8633         of -gnatel/-gnateL.
8634         * opt.ads (Warn_Info_Messages): New flag.
8635         * sem_elab.adb: Use Elab_Warnings, Elab_Info_Messages to control
8636         messages.
8637         * sem_prag.adb: Use Elab_Warnings, Elab_Info_Messages to control
8638         messages.
8639         * switch-m.ad, switch-c.adb: Recognize new -gnatel/EL switches.
8640         * usage.adb: Add documentation of -gnatel/-gnateL Update
8641         documentation of -gnatwl/-gnatwL.
8642         * warnsw.adb: New handling of Elab_Warnings, Elab_Info_Messages
8643         * warnsw.ads (Elab_Info_Messages): New field in Warning_Record
8645 2014-02-25  Robert Dewar  <dewar@adacore.com>
8647         * einfo.ads, einfo.adb (Has_Shift_Operator): New flag.
8648         * gnat_rm.texi: Document pragma Provide_Shift_Operators.
8649         * interfac.ads: Minor code reorganization (add pragma
8650         Compiler_Unit_Warning).
8651         * par-prag.adb: Add dummy entry for Provide_Shift_Operators.
8652         * sem_ch3.adb (Build_Derived_Numeric_Type): Copy
8653         Has_Shift_Operator flag.
8654         * sem_intr.adb (Check_Intrinsic_Subprogram): Make sure
8655         Check_Shift is always called (Check_Shift): Set Has_Shift_Operator.
8656         * sem_prag.adb: Implement pragma Provide_Shift_Operators.
8657         * snames.ads-tmpl: Add entries for pragma Provide_Shift_Operators
8658         Add entry for Name_Amount.
8659         * checks.adb (Selected_Range_Checks): When checking for a null
8660         range, make sure we use the base type, and not the subtype for
8661         deciding a range is null.
8662         * sem_ch5.adb (Analyze_Loop_Parameter_Specification): Check
8663         for suspicious loop bound which is outside the range of the
8664         loop subtype.
8665         * gnat_ugn.texi: Add documentation section "Determining the
8666         Chosen Elaboration Order"
8667         * sem_ch13.adb (UC_Entry): Add field Act_Unit
8668         (Validate_Unchecked_Conversion): Store Act_Unit
8669         (Validate_Unchecked_Conversions): Test Warnings_Off in Act_Unit
8670         * treepr.adb: Minor reformatting.
8672 2014-02-25  Arnaud Charlet  <charlet@adacore.com>
8674         * usage.adb: Minor: fix typo.
8676 2014-02-25  Robert Dewar  <dewar@adacore.com>
8678         * lib.ads, s-bitops.adb, s-bitops.ads, s-conca5.adb, gnat_rm.texi,
8679         s-conca5.ads, s-conca7.adb, s-conca7.ads, s-crc32.adb, s-crc32.ads,
8680         s-conca9.adb, s-conca9.ads, g-dyntab.adb, s-crtl.ads, g-dyntab.ads,
8681         s-excdeb.adb, s-addope.adb, s-addope.ads, s-carun8.adb, s-carun8.ads,
8682         g-htable.adb, g-htable.ads, g-hesora.adb, g-hesora.ads, s-conca2.adb,
8683         s-conca2.ads, a-comlin.adb, a-chlat1.ads, a-comlin.ads, errout.ads,
8684         a-except.adb, s-conca4.adb, a-except.ads, s-conca4.ads, s-conca6.adb,
8685         s-conca6.ads, g-spchge.adb, g-spchge.ads, g-u3spch.adb, g-u3spch.ads,
8686         a-strhas.ads, restrict.adb, aspects.adb, aspects.ads, s-conca8.adb,
8687         s-conca8.ads, back_end.adb, par-prag.adb, g-byorma.adb, g-byorma.ads,
8688         a-elchha.adb, a-elchha.ads, g-speche.adb, g-speche.ads, s-casuti.adb,
8689         s-assert.adb, s-casuti.ads, s-assert.ads, a-clrefi.adb, a-clrefi.ads,
8690         s-conca3.adb, s-conca3.ads, a-ioexce.ads: Implement pragma
8691         Compiler_Unit_Warning, change Compiler_Unit everywhere to
8692         Compiler_Unit_Warning.
8694 2014-02-25  Sergey Rybin  <rybin@adacore.com frybin>
8696         * sem_prag.adb (Analyze_Depends_In_Decl_Part): Do not normalize
8697         in ASIS mode aggregates that are used as aspect definitions.
8699 2014-02-25  Robert Dewar  <dewar@adacore.com>
8701         * exp_ch7.adb, sem_util.adb, sem_util.ads, exp_ch6.adb: Minor
8702         reformatting.
8704 2014-02-25  Ed Schonberg  <schonberg@adacore.com>
8706         * freeze.adb (Freeze_Entity): If the return type of a function
8707         is a limited view, and the non-limited view has not been seen yet,
8708         defer freezing to some later point.
8710 2014-02-25  Robert Dewar  <dewar@adacore.com>
8712         * sem_ch3.adb: Minor reformatting.
8714 2014-02-25  Robert Dewar  <dewar@adacore.com>
8716         * s-excdeb.ads, s-except.ads, s-exctab.adb, s-exctab.ads, s-finmas.ads,
8717         s-htable.adb, s-htable.ads, s-imenne.adb, s-imenne.ads, s-imgenu.adb,
8718         s-imgenu.ads, s-mastop.adb, s-mastop.ads, s-memory-vms_64.adb,
8719         s-memory-vms_64.ads, s-memory.adb, s-memory.ads, s-os_lib.adb,
8720         s-os_lib.ads, s-parame.adb, s-parame.ads, s-purexc.ads, s-restri.adb,
8721         s-restri.ads, s-rident.ads, s-secsta.adb, s-secsta.ads, s-soflin.adb,
8722         s-soflin.ads, s-sopco3.adb, s-sopco3.ads, s-sopco4.adb, s-sopco4.ads,
8723         s-sopco5.adb, s-sopco5.ads, s-spsufi.ads, s-stache.adb, s-stache.ads,
8724         s-stalib.adb, s-stalib.ads, s-stoele.adb, s-stoele.ads, s-strcom.adb,
8725         s-strcom.ads, s-strhas.adb, s-string.adb, s-string.ads, s-strops.adb,
8726         s-strops.ads, s-ststop.adb, s-ststop.ads, s-traceb.adb, s-traceb.ads,
8727         s-traent.adb, s-traent.ads, s-unstyp.ads, s-utf_32.adb, s-utf_32.ads,
8728         s-wchcnv.adb, s-wchcnv.ads, s-wchcon.adb, s-wchcon.ads, s-wchjis.adb,
8729         s-wchjis.ads, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_prag.adb,
8730         snames.ads-tmpl: Change Compiler_Unit everywhere to
8731         Compiler_Unit_Warning.
8733 2014-02-25  Hristian Kirtchev  <kirtchev@adacore.com>
8735         * exp_ch6.adb (Add_Or_Save_Precondition): New routine.
8736         (Collect_Body_Postconditions_In_Decls): New routine.
8737         (Collect_Body_Postconditions_Of_Kind): Factor out code. Handle
8738         postcondition aspects or pragmas that appear on a subprogram
8739         body stub.
8740         (Collect_Spec_Preconditions): Factor out code. Handle
8741         precondition aspects or pragmas that appear on a subprogram
8742         body stub.
8743         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): The analysis of
8744         aspects that apply to a subprogram body stub is no longer delayed,
8745         the aspects are analyzed on the spot.
8746         (SPARK_Aspect_Error):
8747         Aspects that apply to a subprogram declaration cannot appear in
8748         a subunit.
8749         * sem_ch10.adb Remove with and use clause for Sem_Ch13.
8750         (Analyze_Proper_Body): Add local variable Comp_Unit. Unum
8751         is now a local variable. Code cleanup. Analysis related to
8752         the aspects of a subprogram body stub is now carried out by
8753         Analyze_Subprogram_Body_Helper. Do not propagate the aspects
8754         and/or pragmas of a subprogram body stub to the proper body
8755         as this is no longer needed. Do not analyze the aspects of a
8756         subprogram stub when the corresponding source unit is missing.
8757         (Analyze_Protected_Body_Stub): Flag the illegal use of aspects
8758         on a stub.
8759         (Analyze_Task_Body_Stub): Flag the illegal use of
8760         aspects on a stub.
8761         (Optional_Subunit): Add local variable Unum.
8762         * sem_ch13.adb (Insert_Delayed_Pragma): Do not analyze a generated
8763         pragma when it applies to a subprogram body stub.
8764         * sem_prag.adb (Analyze_Pragma): Pragmas Contract_Cases,
8765         Depends and Global can now apply to a subprogram body stub as
8766         long as it acts as its own spec.
8767         (Analyze_Refined_Pragma):
8768         Code reformatting. Refinement pragmas cannot apply to a subunit.
8770 2014-02-25  Hristian Kirtchev  <kirtchev@adacore.com>
8772         * einfo.ads Update the usage of flag
8773         Uses_Sec_Stack. Uses_Sec_Stack now applies to E_Loop entities.
8774         * exp_ch5.adb (Expand_Iterator_Loop): The temporary for a cursor
8775         now starts with the letter 'C'. This makes reading expanded
8776         code easier.
8777         * exp_ch7.adb (Establish_Transient_Scope): Add local variable
8778         Iter_Loop. Signal that an Ada 2012 iterator loop requires
8779         secondary stack management when creating a transient scope for
8780         an element reference.
8781         * exp_util.adb (Process_Statements_For_Controlled_Objects):
8782         When wrapping the statements of a loop, pass the E_Loop entity
8783         to the wrapping machinery.
8784         (Wrap_Statements_In_Block): Add
8785         formal parameter Scop along with comment on usage. Add local
8786         variables Block_Id, Block_Nod and Iter_Loop. Mark the generated
8787         block as requiring secondary stack management when the block is
8788         created inside an Ada 2012 iterator loop. This ensures that any
8789         reference objects are reclaimed on each iteration of the loop.
8790         * sem_ch5.adb (Analyze_Loop_Statement): Mark the generated block
8791         tasked with the handling of container iterators as requiring
8792         secondary stack management. This ensures that iterators are
8793         reclaimed when the loop terminates or is exited in any fashion.
8794         * sem_util.adb (Add_Block_Identifier): New routine.
8795         (Find_Enclosing_Iterator_Loop): New routine.
8796         * sem_util.ads (Add_Block_Identifier): New routine.
8797         (Find_Enclosing_Iterator_Loop): New routine.
8799 2014-02-25  Robert Dewar  <dewar@adacore.com>
8801         * sinfo.ads: Minor reformatting.
8803 2014-02-25  Tristan Gingold  <gingold@adacore.com>
8805         * s-expllu.ads, s-expuns.ads, s-expmod.ads: Minor comment fix.
8807 2014-02-25  Pascal Obry  <obry@adacore.com>
8809         * sinput-l.adb, osint.adb, osint.ads: Add Prep_Suffix to factorize code.
8811 2014-02-25  Tristan Gingold  <gingold@adacore.com>
8813         * sem_ch10.adb: Minor comment fix.
8815 2014-02-25  Bob Duff  <duff@adacore.com>
8817         * s-tasdeb.adb: Misc cleanup of this package,
8818         including printing addresses in hexadecimal.
8819         (Write): Fix minor bug when taking 'Address of an empty string.
8821 2014-02-25  Ed Schonberg  <schonberg@adacore.com>
8823         * sem_prag.adb (Analyze_Part_Of): Reject state refinement in a
8824         public child unit when it does not refer to the abstract state
8825         of a public ancestor.
8827 2014-02-25  Yannick Moy  <moy@adacore.com>
8829         * sem_prag.adb (Analyze_Pragma/Pragma_Validity_Checks): Ignore pragma
8830         Validity_Checks in GNATprove and CodePeer modes.
8832 2014-02-25  Pascal Obry  <obry@adacore.com>
8834         * prj-attr.adb, projects.texi, snames.ads-tmpl: Add package Install's
8835         Artifacts attribute.
8837 2014-02-25  Yannick Moy  <moy@adacore.com>
8839         * sem_prag.adb: Minor reformatting to get consistent messages.
8841 2014-02-25  Robert Dewar  <dewar@adacore.com>
8843         * checks.adb: Minor reformatting.
8844         * sinfo.ads (Do_Range_Check): Document that this flag is never
8845         passed to the back end.
8847 2014-02-25  Yannick Moy  <moy@adacore.com>
8849         * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_prag.adb, sem_attr.adb,
8850         sem_ch6.adb: Remove useless references to SPARK RM in error messages.
8852 2014-02-25  Hristian Kirtchev  <kirtchev@adacore.com>
8854         * sem_res.adb (Appears_In_Check): New routine.
8855         (Resolve_Entity_Name): Remove local variables Prev and
8856         Usage_OK. Par is now a constant. Remove the parent chain traversal
8857         as the placement of a volatile object with enabled property
8858         Async_Writers and/or Effective_Reads must appear immediately
8859         within a legal construct.
8861 2014-02-25  Hristian Kirtchev  <kirtchev@adacore.com>
8863         * checks.adb (Apply_Selected_Range_Checks):
8864         Alphabetize local constants and variables. Add comments.
8865         Always insert a range check that requires runtime evaluation into
8866         the tree.
8868 2014-02-25  Robert Dewar  <dewar@adacore.com>
8870         * sem_attr.adb, sem_ch6.adb, par-ch3.adb: Minor reformatting.
8872 2014-02-25  Bob Duff  <duff@adacore.com>
8874         * s-tassta.adb (Finalize_Global_Tasks): Limit the number of loop
8875         iterations while waiting for independent tasks to terminate;
8876         if an independent task does not terminate, we do not want to
8877         hang here. In that case, the thread will be terminated when the
8878         process exits.
8879         * s-taprop-linux.adb (Abort_Task): Fix Assert to allow for ESRCH.
8881 2014-02-25  Ed Schonberg  <schonberg@adacore.com>
8883         * sem_prag.adb (Check_SPARK_Aspect_For_ASIS): New subprogram,
8884         used to perform pre-analysis of the expression for SPARK
8885         aspects that have a non-standard syntax, such as GLobal and
8886         Initializes. The procedure applies to the original expression
8887         in an aspect specification, prior to the analysis of the
8888         corresponding pragma, in order to provide semantic information
8889         for ASIS navigation purposes.
8890         (Analyze_Global_In_Decl_List, Analyze_Initializes_In_Decl_Part):
8891         Call new subprogram.
8893 2014-02-25  Yannick Moy  <moy@adacore.com>
8895         * sem_prag.adb: Remove obsolete reference to SPARK RM in error message.
8897 2014-02-25  Doug Rupp  <rupp@adacore.com>
8899         * init.c (HAVE_GNAT_ADJUST_CONTEXT_FOR_RAISE): Enable for ARM.
8900         (__gnat_adjust_context_for_raise): Bump the PC by 2.
8902 2014-02-25  Ed Schonberg  <schonberg@adacore.com>
8904         * par-ch3.adb (P_Basic_Declarative_Items): In the case of a
8905         misplaced IS, add a statement sequence to improper body only if
8906         one has not been parsed already.
8908 2014-02-25  Ed Schonberg  <schonberg@adacore.com>
8910         * sem_attr.adb (Analyze_Attribute, case 'Update): Check for
8911         mismatch when multidimensional array is updated with a single
8912         index.
8914 2014-02-25  Yannick Moy  <moy@adacore.com>
8916         * sem_ch3.adb, sem_ch5.adb, sem_prag.adb, sem_attr.adb, errout.ads,
8917         sem_ch6.adb: Mark most references to SPARK RM in error messages
8918         for removal.
8920 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
8922         * par-ch3.adb (P_Basic_Declarative_Items): If an improper body
8923         appears in a list of basic declarations, complete the tree with
8924         an empty statement list, to prevent cascaded errors and crashes
8925         if semantic analysis is attempted.
8927 2014-02-24  Thomas Quinot  <quinot@adacore.com>
8929         * g-sercom-mingw.adb (Open): Fix incorrect test for error return
8930         value.
8931         * erroutc.adb: Minor reformatting.
8933 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
8935         * sem_prag.adb (Check_Clause_Syntax): Account
8936         for a solitary input item in a dependency list.
8938 2014-02-24  Yannick Moy  <moy@adacore.com>
8940         * gnat1drv.adb (Adjust_Global_Switches): Do not
8941         use validity checks at all in GNATprove_Mode.
8943 2014-02-24  Robert Dewar  <dewar@adacore.com>
8945         * g-sercom-mingw.adb, g-sercom-linux.adb, sem_prag.adb, freeze.adb,
8946         atree.adb, atree.ads: Minor reformatting.
8948 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
8950         * sem_ch6.adb (Analyze_Subprogram_Body_Contract): Do not enforce
8951         global and dependence refinement when SPARK_Mode is off.
8952         * sem_ch7.adb (Analyze_Package_Body_Contract): Do not enforce
8953         state refinement when SPARK_Mode is off.
8954         * sem_ch13.adb (Analyze_Aspect_Specifications): Add local
8955         variable Decl. Insert the generated pragma for Refined_State
8956         after a potential pragma SPARK_Mode.
8957         * sem_prag.adb (Analyze_Depends_In_Decl_Part): Add local
8958         constant Deps. Remove local variable Expr. Check the syntax
8959         of pragma Depends when SPARK_Mode is off. Factor out the
8960         processing for extra parenthesis around individual clauses.
8961         (Analyze_Global_In_Decl_List): Items is now a constant. Check
8962         the syntax of pragma Global when SPARK_Mode is off.
8963         (Analyze_Initializes_In_Decl_Part): Check the syntax of pragma
8964         Initializes when SPARK_Mode is off.
8965         (Analyze_Part_Of): Check
8966         the syntax of the encapsulating state when SPARK_Mode is off.
8967         (Analyze_Pragma): Check the syntax of pragma Abstract_State when
8968         SPARK_Mode is off. Move the declaration order check with respect
8969         to pragma Initializes to the end of the processing. Do not verify
8970         the declaration order for pragma Initial_Condition when SPARK_Mode
8971         is off. Do not complain about a useless package refinement when
8972         SPARK_Mode is off.
8973         (Analyze_Refined_Depends_In_Decl_Part): Refs
8974         is now a constant. Check the syntax of pragma Refined_Depends
8975         when SPARK_Mode is off.
8976         (Analyze_Refined_Global_In_Decl_Part):
8977         Check the syntax of pragma Refined_Global when SPARK_Mode is off.
8978         (Analyze_Refined_State_In_Decl_Part): Check the syntax of pragma
8979         Refined_State when SPARK_Mode is off.
8980         (Check_Dependence_List_Syntax): New routine.
8981         (Check_Global_List_Syntax): New routine.
8982         (Check_Initialization_List_Syntax): New routine.
8983         (Check_Item_Syntax): New routine.
8984         (Check_State_Declaration_Syntax): New routine.
8985         (Check_Refinement_List_Syntax): New routine.
8986         (Has_Extra_Parentheses): Moved to the top level of Sem_Prag.
8988 2014-02-24  Robert Dewar  <dewar@adacore.com>
8990         * a-tags.adb, s-os_lib.adb: Minor reformatting.
8992 2014-02-24  Thomas Quinot  <quinot@adacore.com>
8994         * g-sercom-mingw.adb, g-sercom-linux.adb (Raise_Error): Include
8995         strerror message, not just numeric errno value.
8997 2014-02-24  Doug Rupp  <rupp@adacore.com>
8999         * raise-gcc.c (exception_class_eq): Make endian neutral.
9001 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
9003         * atree.ads, atree,adb (Copy_Separate_Tree): Remove Syntax_Only
9004         flag, and reset Etype and Analyzed attributes unconditionally
9005         when copying a tree that may be partly analyzed.
9006         * freeze.adb: Change calls to Copy_Separate_Tree accordingly.
9007         * sem_ch6.adb (Check_Inline_Pragma): If the Inline pragma appears
9008         within a subprogram body and applies to it, remove it from the
9009         body before making a copy of it, to prevent spurious errors when
9010         analyzing the copied body.
9012 2014-02-24  Thomas Quinot  <quinot@adacore.com>
9014         * s-os_lib.adb (Errno_Message): Do not depend on Integer'Image.
9015         * s-oscons-tmplt.c: On VxWorks, include adaint.h only after
9016         vxWorks.h has been included.  Also ensure that file attributes
9017         related definitions are output even in cases where socket support
9018         is not enabled.
9019         * a-tags.adb: Code clean up.
9020         * Make-generated.in (OSCONS_CPP, OSCONS_EXTRACT): Use -iquote
9021         instead of -I to add the main ada source directory to the header
9022         search path, in order to avoid conflict between our own "types.h"
9023         and VxWork's <types.h>.
9025 2014-02-24  Robert Dewar  <dewar@adacore.com>
9027         * atree.ads, atree.adb (Copy_Separate_Tree): Add Syntax_Only parameter.
9028         * debug.adb: Remove documentation of -gnatd.X, no longer used.
9029         * freeze.adb (Wrap_Imported_Subprogram): Fixed and activated.
9031 2014-02-24  Bob Duff  <duff@adacore.com>
9033         * gnat_ugn.texi: Improve documentation of gnatpp.
9035 2014-02-24  Thomas Quinot  <quinot@adacore.com>
9037         * g-stheme.adb, g-socthi-vms.adb, g-socthi-vms.ads,
9038         g-socthi-vxworks.adb, g-socthi-vxworks.ads, g-stseme.adb,
9039         g-socthi-mingw.adb, g-socthi-mingw.ads, g-socthi.adb,
9040         g-socthi.ads, g-socket.adb (Host_Error_Message): Return a string, not
9041         a chars_ptr, because on Windows this is a renaming of
9042         Socket_Error_Message.
9044 2014-02-24  Robert Dewar  <dewar@adacore.com>
9046         * a-direct.adb, sem_ch5.adb, a-cfdlli.adb, a-cfhase.adb, a-tags.adb,
9047         s-filatt.ads, a-cforma.adb, sem_ch6.adb, g-socthi-mingw.adb,
9048         a-cfhama.adb, a-cforse.adb, a-cofove.adb: Minor reformatting and code
9049         reorganization.
9051 2014-02-24  Thomas Quinot  <quinot@adacore.com>
9053         * Make-generated.in (OSCONS_CPP, OSCONS_EXTRACT): Make sure
9054         that the source directory containing s-oscons-tmplt.c is on the
9055         include path, so that all internal header files are available.
9057 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
9059         * sem_ch5.adb (Analyze_Loop_Parameter_Specification): If the
9060         domain of iteration is an attribute reference 'Old, this is an
9061         Ada 2012 iterator and the loop must be rewritten as such.
9063 2014-02-24  Thomas Quinot  <quinot@adacore.com>
9065         * s-fileio.adb (Errno_Message): Remove, use shared version from
9066         s-os_lib instead.
9067         * s-crtrun.ads, Makefile.rtl: Remove now unused unit.
9068         * g-stseme (Socket_Error_Message): Reimplement in terms of new
9069         s-os_lib function.
9070         * g-socthi.ads, g-socthi.adb: Change profile of
9071         Socket_Error_Message to return String to allow the above.
9072         * g-socket.adb, g-socthi-mingw.adb, g-socthi-mingw.ads,
9073         * g-socthi-vms.adb, g-socthi-vms.ads, g-socthi-vxworks.adb,
9074         * g-socthi-vxworks.ads: Update to account for the above profile
9075         change.
9076         * a-tags.adb: Use strlen builtin binding provided by s-crtl.
9077         * s-crtl.ads (strncpy): New procedure.
9078         * s-os_lib.adb (Copy_Attributes): Import just once (strncpy):
9079         Use import from s-crtl.
9080         * a-envvar.adb, osint.adb: Use imports of C runtime functions
9081         from s-crtl instead of re-importing locally.
9083 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
9085         * sem_prag.adb (Analyze_Global_Item): Emit the
9086         variable related checks concerning volatile objects only when
9087         SPARK_Mode is on.
9089 2014-02-24  Robert Dewar  <dewar@adacore.com>
9091         * sem_ch5.adb (Analyze_Iterator_Specification): use
9092         Error_Msg_Ada_2012_Feature.
9094 2014-02-24  Jose Ruiz  <ruiz@adacore.com>
9096         * s-rident.ads (Profile_Info): For Ravenscar, the restrictions
9097         No_Local_Timing_Events and No_Specific_Termination_Handlers
9098         must be set, according to the Ravenscar profile definition
9099         in D.13(6/3).
9101 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
9103         * sem_ch6.adb (Analyze_Expression_Function): If this is a
9104         completion, freeze return type and its designated type if needed.
9106 2014-02-24  Thomas Quinot  <quinot@adacore.com>
9108         * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case
9109         'Address): When moving initialization statements to a freeze
9110         entity, keep them under a single node (i.e. do not unwrap
9111         expressions with actions), and set the Initialization_Statements
9112         attribute again so that processing of a later pragma Import can
9113         still remove them.
9115 2014-02-24  Claire Dross  <dross@adacore.com>
9117         * a-cfdlli.adb, a-cfdlli.ads, a-cfhama.adb, a-cfhama.ads,
9118         a-cfhase.adb, a-cfhase.ads, a-cforma.adb, a-cforma.ads,
9119         a-cforse.adb, a-cforse.ads, a-cofove.adb, a-cofove.ads: Rename
9120         Left/Right to First_To_Previous/Current_To_Last.
9122 2014-02-24  Thomas Quinot  <quinot@adacore.com>
9124         * adaint.h (struct file_attributes): New component "error"
9125         (__gnat_error_attributes): Accessor for the above.
9126         * adaint.c (__gnat_error_attributes): New subprogram
9127         (__gnat_stat): Fix returned value (expect errno value)
9128         (__gnat_stat_to_attr): Add management of error component (set to
9129         stat errno value, except for missing files where it is set to 0,
9130         and exists is set to 0).
9131         * osint.ads (File_Attributes_Size): Update per change above,
9132         also clarify documentation.
9133         * s-filatt.ads: New file, binding to file attributes related
9134         functions.
9135         * Makefile.rtl (s-filatt): New runtime unit.
9136         * s-crtl.ads (strlen): Expose binding to GCC builtin (falls back
9137         to library function if not available on target).
9138         * s-os_lib.ads, s-os_lib.adb (Errno_Message): New subprogram.
9139         * s-oscons-tmplt.c (SIZEOF_struct_file_attributes,
9140         SIZEOF_struct_dirent_alloc): New constants.
9141         * Make-generated.in (s-oscons.ads): Now requires adaint.h.
9142         * a-direct.adb (Fetch_Next_Entry): Fix incorrect buffer sizes.
9143         Perform appropriate error checking if stat fails (do not just
9144         ignore existing files if stat fails)
9145         * gcc-interface/Make-lang.in (GNAT_ADA_OBJS, GNATBIND_OBJS): Update
9146         dependencies.
9148 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
9150         * sem_prag.adb (Analyze_Global_Item): Move the check concerning
9151         the use of volatile objects as global items in a function to
9152         the variable related checks section.
9153         * sem_util.adb (Async_Readers_Enabled): Directly call
9154         Has_Enabled_Property.
9155         (Async_Writers_Enabled): Directly call Has_Enabled_Property.
9156         (Effective_Reads_Enabled): Directly call Has_Enabled_Property.
9157         (Effective_Writes_Enabled): Directly call Has_Enabled_Property.
9158         (Has_Enabled_Property): Rename formal parameter State_Id to Item_Id.
9159         Update the comment on usage. State_Has_Enabled_Property how handles
9160         the original logic of the routine. Add processing for variables.
9161         (State_Has_Enabled_Property): New routine.
9162         (Variable_Has_Enabled_Property): New routine.
9164 2014-02-24  Robert Dewar  <dewar@adacore.com>
9166         * sinfo.ads, sem_ch12.adb, sem_res.adb, sem_ch4.adb, par-ch12.adb:
9167         Minor reformatting.
9168         * atree.ads, atree.adb (Node35): New function.
9169         (Set_Node35): New procedure.
9170         * debug.adb: Define new debug flag -gnatd.X.
9171         * einfo.ads, einfo.adb (Import_Pragma): New field.
9172         * freeze.adb (Wrap_Imported_Procedure): New procedure (not
9173         really active yet, has to be activated with -gnatd.X.
9174         * sem_prag.adb (Set_Imported): Set new Import_Pragma
9175         field (Set_Imported): Don't set Is_Public (see
9176         Freeze.Wrap_Imported_Subprogram)
9177         * par-ch3.adb (P_Component_List): Handle unexpected null component.
9179 2014-02-24  Yannick Moy  <moy@adacore.com>
9181         * sem_ch3.adb: Correct reference to SPARK RM in error messages.
9182         * gnat_rm.texi: Correct documentation of attribute Update.
9184 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
9186         * sem_ch5.adb (Analyze_Iterator_Specification): Reject container
9187         iterator in older versions of Ada.
9189 2014-02-24  Gary Dismukes  <dismukes@adacore.com>
9191         * sem_ch5.adb, sem_aux.ads, sem_ch12.adb, gnat_ugn.texi, par.adb,
9192         par-ch12.adb: Change spelling 'parametrization' to 'parameterization'.
9194 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
9196         * sinfo.ads, sinfo.adb: New attribute Generalized_Indexing, for
9197         indexed_components that are instances of Ada 2012 container
9198         indexing operations. Analysis and resolution of such nodes
9199         is performed on the attribute, and the original source is
9200         preserved for ASIS operations. If expansion is enabled, the
9201         indexed component is replaced by the value of this attribute,
9202         which is in a call to an Indexing aspect, in most case wrapped
9203         in a dereference operation.
9204         * sem_ch4.adb (Analyze_Indexed_Component): Create
9205         Generalized_Indexing attribute when appropriate.
9206         (Analyze_Call): If prefix is not overloadable and has an indexing
9207         aspect, transform into an indexed component so it can be analyzed
9208         as a potential container indexing.
9209         (Analyze_Expression): If node is an indexed component with a
9210         Generalized_ Indexing, do not re-analyze.
9211         * sem_res.adb (Resolve_Generalized_Indexing): Complete resolution
9212         of an indexed_component that has been transformed into a container
9213         indexing operation.
9214         (Resolve_Indexed_Component): Call the above when required.
9215         (Resolve): Do not insert an explicit dereference operation on
9216         an indexed_component whose type has an implicit dereference:
9217         the operation is inserted when resolving the related
9218         Generalized_Indexing.
9220 2014-02-24  Olivier Ramonat  <ramonat@adacore.com>
9222         * gnat_rm.texi, gnat_ugn.texi: Replace Ada Compiler by Ada Development
9223         Environment.
9225 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
9227         * sem_prag.adb (Check_Constituent_Usage): Remove leading spaces in
9228         error messages.
9229         (Inconsistent_Mode_Error): Remove leading spaces in error messages.
9230         Merge the expected and available mode errors.
9231         (Report_Unused_Constituents): Remove leading spaces in error messages.
9232         (Report_Unused_States): Remove leading spaces in error messages.
9234 2014-02-24  Thomas Quinot  <quinot@adacore.com>
9236         * par_sco.adb (Traverse_One): Refine categorization of statement
9237         SCOs.
9239 2014-02-24  Robert Dewar  <dewar@adacore.com>
9241         * aspects.ads, aspects.adb: Remove aspects Ada_2005 and Ada_2012,
9242         Pure_05, Pure_12 and Preelaborate_05.
9243         * gnat_rm.texi: Update accordingly.
9244         * sem_prag.adb: Document one argument form of Ada_05/Ada_2005
9245         pragmas Document one argument form of Ada_12/Ada_2012 pragmas
9246         Recognize one argument form of these pragmas only in GNAT mode
9247         (-gnatg).
9249 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
9251         * s-dimmks.ads: Replace symbol for temperature, previously the
9252         Greek letter Theta, by the ASCII @ sign.
9253         * s-diflio.ads: ditto.
9255 2014-02-24  Robert Dewar  <dewar@adacore.com>
9257         * exp_ch4.adb: Minor code reorganization (use OR for boolean
9258         variables).
9259         * sem_ch3.adb, sem_prag.adb, freeze.adb: Minor reformatting.
9261 2014-02-24  Ben Brosgol  <brosgol@adacore.com>
9263         * gnat_ugn.texi, projects.texi: Added the necessary conditionalization
9264         so that references to gnatmem and ASIS tools do not appear in the FSF
9265         edition of the GNAT User's Guide.
9267 2014-02-24  Yannick Moy  <moy@adacore.com>
9269         * freeze.adb (Freeze_Entity): Do not issue warning
9270         for pre/post being ignored on imported subprogram in GNATprove
9271         mode.
9273 2014-02-24  Robert Dewar  <dewar@adacore.com>
9275         * exp_ch5.adb, sem_ch5.adb, sem_type.adb, sem_res.adb, sem_attr.adb,
9276         stand.ads, sem_eval.adb: Minor reformatting.
9278 2014-02-24  Yannick Moy  <moy@adacore.com>
9280         * sem_prag.adb: Minor rewording in error message.
9282 2014-02-24  Johannes Kanig  <kanig@adacore.com>
9284         * exp_util.adb (Expand_Subtype_From_Expr): Do not expand subtypes in
9285         GNATprove_mode, gnat2why doesn't need nor use these types.
9287 2014-02-24  Gary Dismukes  <dismukes@adacore.com>
9289         * exp_ch4.adb (Expand_N_Op_Expon): On the AAMP
9290         target, in the case of signed integer exponentiation that uses a
9291         run-time routine, always select the Exp_* versions, since overflow
9292         checking is automatically done by AAMP arithmetic instructions.
9294 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
9296         * sem_ch13.adb (Analyze_Aspect_Specifications):
9297         When the related context is a package instace, insert pragma
9298         Abstract_State after all internally-generated renamings related
9299         to the instance "header".
9301 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
9303         * sem_ch3.adb (Analyze_Declarations): Analyze Contract of abstract
9304         subprograms.
9305         * sem_disp.adb (Check_Dispatching_Context): A non-dispatching
9306         call to an abstract subprogram is legal if it appears in a
9307         pre/postcondition of another abstract operation.
9309 2014-02-24  Sergey Rybin  <rybin@adacore.com frybin>
9311         * gnat_ugn.texi: Misc updates.
9313 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
9315         * exp_prag.adb (Expand_Old): Set the type of the generated temporary.
9317 2014-02-24  Gary Dismukes  <dismukes@adacore.com>
9319         * layout.adb (Layout_Variant_Record): Instantiate
9320         Generic_Check_Choices and call Check_Choices before calling
9321         Build_Discr_Checking_Funcs, since we need Others_Discrete_Choices
9322         set to prevent generating incorrect discriminant-checking
9323         functions for 'others' variants (functions that unconditionally
9324         return True rather than accounting for the values covered by the
9325         'others' choice).
9326         * sem_eval.ads (Subtypes_Statically_Compatible): Add formal
9327         Formal_Derived_Matching.
9328         (Subtypes_Statically_Match): Add formal Formal_Derived_Matching.
9329         * sem_eval.adb (Subtypes_Statically_Compatible): Pass new
9330         Formal_Derived_Matching formal to Subtypes_Statically_Match.
9331         (Subtypes_Statically_Match): Suppress the Object_Size matching
9332         test in the case where Formal_Derived_Matching is True.
9333         * sem_ch12.adb (Validate_Derived_Type_Instance): Pass
9334         True for Formal_Derived_Matching_Formal on the call to
9335         Subtypes_Statically_Compatible.
9337 2014-02-23  Eric Botcazou  <ebotcazou@adacore.com>
9339         * gcc-interface/Make-lang.in (ADA_TOOLS_FLAGS_TO_PASS): Robustify.
9341 2014-02-23  Eric Botcazou  <ebotcazou@adacore.com>
9343         * gcc-interface/utils2.c (build_simple_component_ref): Fix formatting.
9344         Look through a conversion between original and packable version to get
9345         the base object.
9346         (build_component_ref): Rework comment and fix formatting.
9348 2014-02-20  Sergey Rybin  <rybin@adacore.com frybin>
9350         * gnat_ugn.texi, vms_data.ads (gnatelim): Add description of
9351         project-specific options.
9353 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
9355         * a-cbdlli.adb (Insert): When capacity exceeded, raise Capacity_Error,
9356         not Constraint_Error.
9357         * a-cbmutr.adb (Append_Child, Insert_Child, Prepend_Child): Ditto.
9358         * sem_ch5.adb: Code clean up.
9360 2014-02-20  Hristian Kirtchev  <kirtchev@adacore.com>
9362         * sem_prag.adb (Usage_Error): Remove local
9363         constant Typ. Remove the specialized diagnostics for unconstrained
9364         or tagged items as those are not part of the explicit input set
9365         of the related subprogram and should not be flagged.
9367 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
9369         * sem_attr.adb: Add guard to preserve all errors.
9371 2014-02-20  Vincent Celier  <celier@adacore.com>
9373         * switch-m.adb (Normalize_Compiler_Switches): Take into account
9374         switches that are recorded in ALI files: -gnateA, -gnateE,
9375         -gnateF, -gnateinn, -gnateu, -gnateV and -gnateY.
9377 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
9379         * sem_ch5.adb (Analyze_Iterator_Specification): Check legality
9380         of an element iterator form over a formal container with an
9381         Iterable aspect.
9382         * exp_ch5.adb (Build_Formal_Container_Iteration): Utility
9383         to create declaration and loop statements for both forms of
9384         container iterators.
9385         (Expand_Formal_Container_Element_Iterator): New procedure
9386         to handle loops of the form  "for E of C" when C is a formal
9387         container.
9388         (Expand_Formal_Container_Iterator): Code cleanup.
9390 2014-02-20  Hristian Kirtchev  <kirtchev@adacore.com>
9392         * sem_prag.adb (Add_Item_To_Name_Buffer): New routine.
9393         (Analyze_Contract_Case): Remove the use of
9394         "may". Replace "aspect Contract_Cases" to avoid categorization
9395         of aspect vs pragma.
9396         (Analyze_External_Property_In_Decl_Part): Remove the use of "formal".
9397         (Analyze_Global_Item): Remove
9398         the use of "formal", specify the subprogram.  Split the
9399         error message about a state with visible refinement into
9400         two. Remove the use of "global" from "volatile global item".
9401         (Analyze_Initialization_Item): Ensure that the SPARK RM reference
9402         is on one line.
9403         (Analyze_Input_Output): Update the call to
9404         Check_Mode. Specify the duplicated item. Reword the error
9405         message concerning an input of a null output list. Use "\"
9406         for error message continuation.
9407         (Analyze_Part_Of): Remove
9408         the use of "may". Use "\" for error message continuation.
9409         (Analyze_Refined_Depends_In_Decl_Part): Update the error
9410         message concerning a useless refinement to match the format
9411         of Refined_Global.
9412         (Analyze_Refined_Global_In_Decl_Part): Reword the error message
9413         concerning a useless refinement.
9414         (Analyze_Refinement_Clause): Use "\" for error message continuation.
9415         (Check_Constituent_Usage): Use "\" for error message continuation.
9416         (Check_Dependency_Clause): Use "\" for error message continuation.
9417         (Check_Matching_Constituent): Use "\" for error message continuation.
9418         (Check_Missing_Part_Of): Use "\" for error message continuation.
9419         (Check_Mode): Renamed to
9420         Check_Role. Update the comment on usage. Redo the error reporting
9421         to use Role_Error.
9422         (Check_Mode_Restriction_In_Enclosing_Context): Use "\" for error
9423         message continuation.
9424         (Find_Mode): Renamed to Find_Role. Update the parameter profile along
9425         with comment on usage. Update all occurrences of Is_Input and Is_Output.
9426         (Inconsistent_Mode_Error): Use "\" for error message continuation.
9427         (Input_Match): Use "\" for error message continuation.
9428         (Role_Error): New routine.
9429         (Set_Convention_From_Pragma): Use "\" for error message continuation.
9430         (Usage_Error): Add local variable Error_Msg. Build specialized error
9431         message showcasing the offending item kind. Redo the diagnostics for
9432         unconstrained types.
9434 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
9436         * exp_util.adb (Is_Iterated_Container): Use high-level primitives
9437         to determine whether a type is a container type, rather than
9438         examining only its type declaration, so that subtypes and derived
9439         types are handled properly.
9441 2014-02-20  Sergey Rybin  <rybin@adacore.com frybin>
9443         * gnat_ugn.texi: gnatmetric: add description of project-specific
9444         options.
9446 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
9448         * sem_attr.adb (Analyze_Attribute, case 'Update): Verify that
9449         all choices in an association for a record type have the same
9450         type, as is done for record aggregates.
9452 2014-02-20  Robert Dewar  <dewar@adacore.com>
9454         * a-cborma.adb, a-cbhama.adb, a-cbdlli.adb, a-cbmutr.adb: Use pragma
9455         Unmodified rather than Warnings (Off). Make comments
9456         uniform in the four affected units.
9458 2014-02-20  Robert Dewar  <dewar@adacore.com>
9460         * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case
9461         Object_Size): For non-scalar types allow any value that is a
9462         multiple of 8.
9463         * gnat_rm.texi: Document Object_Size for composites more clearly.
9465 2014-02-20  Yannick Moy  <moy@adacore.com>
9467         * sem_util.ads, sem_util.adb (Default_Initialization): Remove function.
9469 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
9471         * stand.ads: Raise_Type: new predefined entity, used as the type
9472         of a Raise_Expression prior to resolution.
9473         * cstand.adb: Build entity for Raise_Type.
9474         * sem_ch11.adb (Analyze_Raise_Expression): use Raise_Type as the
9475         initial type of the node.
9476         * sem_type.adb (Covers): Raise_Type is compatible with all
9477         other types.
9478         * sem_res.adb (Resolve): Remove special handling of Any_Type on
9479         Raise_Expression nodes.
9480         (Resolve_Raise_Expression): Signal ambiguity if the type of the
9481         context is still Raise_Type.
9483 2014-02-20  Robert Dewar  <dewar@adacore.com>
9485         * sem_ch12.adb (Validate_Access_Type_Instance): Add message if
9486         mismatching predicates.
9487         * sem_ch6.adb (Check_Conformance): Give better messages on
9488         predicate mismatch.
9489         * sem_eval.adb (Predicates_Match): Move to spec.
9490         * sem_eval.ads (Predicates_Match): Moved here from body.
9492 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
9494         * a-cbmutr.adb: Use default value in Insert_Child.
9496 2014-02-20  Vincent Celier  <celier@adacore.com>
9498         * gnatcmd.adb, make.adb, prj-makr.adb, clean.adb: Call
9499         Stringt.Initialize in all project aware tools.
9501 2014-02-20  Doug Rupp  <rupp@adacore.com>
9503         * gnat_ugn.texi: Document gnatbind -X option.
9504         * vms_data.ads: Minor warnings documentation reformatting.
9506 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
9508         * exp_ch3.adb (Expand_Freeze_Array_Type): Only create invariant
9509         procedure for a base type.
9511 2014-02-20  Robert Dewar  <dewar@adacore.com>
9513         * sem_ch4.adb (Analyze_Case_Expression): Get type from first
9514         expression with type info.
9515         * sem_ch13.adb: Minor reformatting.
9516         * sem_eval.adb (Subtypes_Statically_Match): Make sure we return
9517         False if predicates do not match on the two types.
9519 2014-02-20  Arnaud Charlet  <charlet@adacore.com>
9521         * sem_prag.adb (Analyze_Pragma [pragma Attach_Handler]):
9522         In Relaxed_RM_Semantics mode, allow any static integer value,
9523         for compatibility with other compilers.
9525 2014-02-20  Vincent Celier  <celier@adacore.com>
9527         * errutil.adb (Initialize): Properly initialize entry in table
9528         Warnings when warnings are suppressed.
9530 2014-02-20  Robert Dewar  <dewar@adacore.com>
9532         * s-os_lib.ads: Add warning about non-portability of Rename_File.
9533         * sem_util.ads, sem_util.adb (Is_Junk_Name): New function.
9534         * sem_warn.adb: Use Is_Junk_Name to suppress some warnings.
9535         * gnat_ugn.texi: Document no warnings on junk variable names.
9536         * layout.adb: Minor code reorganization (use Ekind_In).
9537         * stringt.adb: Move initialization of Null_String_Id to Initialize
9538         routine.
9540 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
9542         * sem_ch13.adb: Initialize optional Element_Id.
9544 2014-02-20  Robert Dewar  <dewar@adacore.com>
9546         * s-os_lib.ads (Rename_File): Minor commment addition.
9548 2014-02-20  Thomas Quinot  <quinot@adacore.com>
9550         * einfo.ads: Minor reformatting.
9552 2014-02-20  Hristian Kirtchev  <kirtchev@adacore.com>
9554         * aspects.adb (Exchange_Aspects): New routine.
9555         * aspects.ads (Exchange_Aspects): New routine.
9556         * atree.adb (Rewrite): Do not check whether the save node has
9557         aspects as it never will, instead check the node about to be clobbered.
9558         * einfo.adb (Write_Field25_Name): Abstract_States can appear in
9559         entities of generic packages.
9560         * sem_ch6.adb (Analyze_Expression_Function): Fix the parent
9561         pointer of an aspect specification list after rewriting takes place.
9562         * sem_ch7.adb (Analyze_Package_Body_Helper): Swap the aspect
9563         specifications of the generic template and the copy used for analysis.
9564         * sem_ch12.adb (Analyze_Generic_Package_Declaration): Swap
9565         the aspect specifications of the generic template and the
9566         copy used for analysis.
9567         (Analyze_Package_Instantiation): Propagate the aspect specifications
9568         from the generic template to the instantiation.
9569         (Build_Instance_Compilation_Unit_Nodes): Propagate the aspect
9570         specifications from the generic template to the instantiation.
9571         * sem_ch13.adb (Analyze_Aspect_Specifications): Handle aspects
9572         Abstract_State, Initializes and Initial_Condition when they
9573         apply to a package instantiation.
9575 2014-02-20  Robert Dewar  <dewar@adacore.com>
9577         * stringt.adb: Add call to Initialize in package initialization.
9579 2014-02-20  Robert Dewar  <dewar@adacore.com>
9581         * a-crbtgk.adb, a-cihama.adb, a-coinve.adb, a-ciorse.adb, a-crbtgo.adb,
9582         a-cidlli.adb, a-cimutr.adb, a-cihase.adb, a-cohama.adb, a-coorse.adb,
9583         a-chtgke.adb, a-chtgop.adb, a-comutr.adb, a-ciorma.adb, a-cobove.adb,
9584         a-convec.adb, a-cohase.adb, a-chtgbk.adb, a-chtgbo.adb: Minor
9585         reformatting.
9587 2014-02-20  Bob Duff  <duff@adacore.com>
9589         * s-os_lib.ads: Minor: Remove incorrect comment.
9591 2014-02-20  Robert Dewar  <dewar@adacore.com>
9593         * sem_elab.adb (Check_Elab_Assign): Clearer warning message.
9595 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
9597         * a-cborma.adb (Assign): When creating a node without a specified
9598         element, insert an uninitialized element in the map, because
9599         the instance may provide an element type with a default
9600         initialization, e.g a scalar with a Default_Value aspect.
9601         * a-cbhama.adb (Assign_Key): Remove useless Allocate procedure.
9602         (Insert): In the version without explicit element, provide an
9603         uninitialized element, as above.
9604         * a-cbdlli.adb (Append): In the version without explicit element,
9605         provide an uninitalized element, as above.
9606         (Allocate): Remove unused version.
9608 2014-02-20  Robert Dewar  <dewar@adacore.com>
9610         * sem_elab.adb: Minor code reorganization (use Nkind_In).
9611         * stringt.adb: Remove temporary pragma Warnings (Off).
9612         * stringt.ads: Add pragma Elaborate_Body to ensure initialization
9613         of Null_String_Id.
9615 2014-02-20  Matthew Heaney  <heaney@adacore.com>
9617         * a-chtgbk.adb (Replace): Use correct offset when calculating bucket
9618         index.
9620 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
9622         * sem_ch5.adb (Analyze_Iterator_Specification): Initialize
9623         properly the cursor type for subsequent volatile testing in SPARK
9624         mode, when domain is a formal container with an Iterabe aspect.
9626 2014-02-20  Robert Dewar  <dewar@adacore.com>
9628         * errout.adb (Set_Warnings_Mode_Off): Add Reason argument.
9629         (Set_Specific_Warning_Off): Add Reason argument.
9630         * errout.ads (Set_Warnings_Mode_Off): Add Reason argument.
9631         (Set_Specific_Warning_Off): Add Reason argument.
9632         * erroutc.adb (Warnings_Entry): Add Reason field
9633         (Specific_Warning_Entry): Add Reason field.
9634         (Warnings_Suppressed): return String_Id for Reason.
9635         (Warning_Specifically_Suppressed): return String_Id for Reason.
9636         * erroutc.ads (Warnings_Entry): Add Reason field.
9637         (Specific_Warning_Entry): Add Reason field.
9638         (Set_Specific_Warning_Off): Add Reason argument.
9639         (Set_Warnings_Mode_Off): Add Reason argument.
9640         (Warnings_Suppressed): return String_Id for Reason.
9641         (Warning_Specifically_Suppressed): return String_Id for Reason.
9642         * errutil.adb (Warnings_Suppressed): returns String_Id for Reason
9643         (Warning_Specifically_Suppressed): returns String_Id for Reason
9644         * gnat_rm.texi: Document that Warning parameter is string literal
9645         or a concatenation of string literals.
9646         * par-prag.adb: New handling for Reason argument.
9647         * sem_prag.adb (Analyze_Pragma, case Warning): New handling
9648         for Reason argument.
9649         * sem_util.ads, sem_util.adb (Get_Reason_String): New procedure.
9650         * sem_warn.ads (Warnings_Off_Entry): Add reason field.
9651         * stringt.adb: Set Null_String_Id.
9652         * stringt.ads (Null_String_Id): New constant.
9654 2014-02-20  Robert Dewar  <dewar@adacore.com>
9656         * einfo.ads: Minor comment addition: Etype of package is
9657         Standard_Void_Type.
9658         * checks.adb, exp_aggr.adb, exp_atag.adb, exp_attr.adb, exp_ch13.adb,
9659         exp_ch2.adb, exp_ch3.adb, exp_ch4.adb, exp_ch5.adb, exp_ch6.adb,
9660         exp_ch7.adb, exp_ch9.adb, exp_dbug.adb, exp_disp.adb, exp_imgv.adb,
9661         exp_intr.adb, exp_prag.adb, exp_sel.adb, exp_strm.adb, exp_util.adb,
9662         freeze.adb, rtsfind.adb, sem_aggr.adb, sem_attr.adb, sem_ch10.adb,
9663         sem_ch12.adb, sem_ch13.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
9664         sem_ch6.adb, sem_ch8.adb, sem_dim.adb, sem_prag.adb, sem_res.adb,
9665         sem_util.adb, tbuild.adb, tbuild.ads: Remove New_Reference_To.
9666         Replace all calls with calls to New_Occurrence_Of.
9668 2014-02-20  Robert Dewar  <dewar@adacore.com>
9670         * par-util.adb (Ignore, case of right paren): Make this a
9671         serious error.
9673 2014-02-19  Robert Dewar  <dewar@adacore.com>
9675         * sem_ch5.adb, sem_prag.adb, sem_attr.adb: Minor reformatting.
9676         * debug.adb: Remove -gnatd.X switch, no longer used.
9677         * styleg.adb (Check_Then): Remove check of -gnatd.X, check is
9678         now always made.
9680 2014-02-19  Bob Duff  <duff@adacore.com>
9682         * g-socket.ads: Minor: Correct some comments.
9684 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
9686         * sem_ch5.adb: Inhibit iterator rewriting in ASIS mode.
9688 2014-02-19  Arnaud Charlet  <charlet@adacore.com>
9690         * sem_ch13.adb (Analyze_Aspect_Specifications): Do not generate
9691         an error on out of range priorities if Relaxed_RM_Semantics.
9692         * sem_prag.adb (Analyze_Pragma): Ditto.
9694 2014-02-19  Bob Duff  <duff@adacore.com>
9696         * sem_attr.adb (Resolve_Attribute): Detect the case of F'Access
9697         where F denotes the renaming of an enumeration literal, and
9698         issue a specialized error message.
9700 2014-02-19  Matthew Heaney  <heaney@adacore.com>
9702         * a-chtgop.ads (Checked_Index): New operation.
9703         (Next): Changed mode of hash table.
9704         * a-chtgop.adb (Adjust, Delete_Node_Sans_Free): Detect tampering
9705         (Generic_Read, Reserve_Capacity): Ditto.
9706         (Generic_Equal): Detect tampering.
9707         (Next): Changed mode of hash table, detect tampering.
9708         * a-chtgke.ads (Checked_Index, Checked_Equivalent_Keys): New
9709         operation.
9710         (Find): Changed mode of hash table.
9711         * a-chtgke.adb (Checked_Equivalent_Keys): New operation
9712         (Delete_Key_Sans_Free, Generic_Conditional_Insert): Detect
9713         tampering.
9714         (Find): Changed mode of hash table, check for tampering.
9715         (Generic_Replace_Element): Check for tampering.
9716         * a-chtgbk.ads (Checked_Index, Checked_Equivalent_Keys): New operation.
9717         * a-chtgbk.adb (Checked_Index, Checked_Equivalent_Keys): New
9718         operation (Delete_Key_Sans_Free, Generic_Conditional_Insert):
9719         Detect tampering.
9720         (Find, Generic_Replace_Element): Check for tampering.
9721         * a-chtgbo.ads (Checked_Index): New operation.
9722         * a-chtgbo.adb (Checked_Index): New operation
9723         (Delete_Node_Sans_Free, Generic_Equal): Detect tampering.
9724         (Generic_Read, Next): Ditto.
9725         * a-cohase.adb, a-cihase.adb (Is_In): Changed mode of hash
9726         table (Difference, Intersection): Use variable view of
9727         source, detect tampering (Find, Is_Subset, Overlap): Use
9728         variable view of container (Symmetric_Difference, Union):
9729         Detect tampering (Vet): Use Checked_Index to detect tampering
9730         (Constant_Reference, Element, Find): Use variable view of
9731         container.
9732         (Update_Element_Preserving_Key): Detect tampering.
9733         * a-cbhase.adb (Difference, Find, Is_In): Use variable view
9734         of container.
9735         (Is_Subset): Ditto.
9736         (Equivalent_Sets, Overlap): Use Node's Next component.
9737         (Vet): Use Checked_Index to detect tampering.
9738         (Constant_Reference, Element, Find): Use variable view of container.
9739         (Update_Element_Preserving_Key): Detect tampering.
9740         * a-cohama.adb, a-cihama.adb, a-cbhama.adb (Constant_Reference,
9741         Element, Find): Use variable view of container.
9742         (Reference): Rename hash table component.
9743         (Vet): Use Checked_Index to detect tampering.
9745 2014-02-19  Arnaud Charlet  <charlet@adacore.com>
9747         * adabkend.adb (Scan_Compiler_Arguments): Add missing handling
9748         of -nostdinc.
9750 2014-02-19  Thomas Quinot  <quinot@adacore.com>
9752         * tbuild.adb (New_Occurrence_Of, New_Rerefence_To): Guard
9753         against calls without Def_Id.
9755 2014-02-19  Claire Dross  <dross@adacore.com>
9757         * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
9758         a-cofove.ads: Add global annotations to subprograms.
9760 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
9762         * sem_prag.adb (Analyze_Initial_Condition_In_Decl_Part): Remove
9763         constants Errors, Pack_Id and Pack_Init. Remove variable Vars.
9764         Initial_Condition no longer requires the presence of pragma
9765         Initialized. Do not try to diagnose whether all variables mentioned in
9766         pragma Initializes also appear in Initial_Condition.
9767         (Collect_Variables): Removed.
9768         (Match_Variable): Removed.
9769         (Match_Variables): Removed.
9770         (Report_Unused_Variables): Removed.
9772 2014-02-19  Thomas Quinot  <quinot@adacore.com>
9774         * gnat_rm.texi (pragma Stream_Convert): Minor rewording.
9776 2014-02-19  Robert Dewar  <dewar@adacore.com>
9778         * sem_util.adb, sem_util.ads, prj-conf.adb, s-os_lib.adb: Minor
9779         reformatting.
9781 2014-02-19  Vincent Celier  <celier@adacore.com>
9783         * prj-part.adb (Parse_Single_Project): Use the fully resolved
9784         project path, with all symbolic links resolved, to check if the
9785         same project is imported with a different unresolved path.
9786         * prj-tree.ads (Project_Name_And_Node): Component Canonical_Path
9787         changed to Resolved_Path to reflect that all symbolic links
9788         are resolved.
9790 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
9792         * sem_util.ads, sem_util.adb (Get_Cursor_Type): Moved to sem_util
9793         from sem_ch13, for use elsewhere.
9794         * sem_ch13.adb (Get_Cursor_Type): Moved to sem_util.
9795         * sem_ch5.adb (Analyze_Iterator_Specification): Set properly the
9796         cursor type on the loop variable when the iteration is over o
9797         formal container.
9799 2014-02-19  Vincent Celier  <celier@adacore.com>
9801         * prj-conf.adb (Add_Default_GNAT_Naming_Scheme): Add declaration
9802         for an empty Target (Check_Target): Never fail when an empty
9803         target is declared in the configuration project.
9805 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
9807         * sem_prag.adb (Check_Arg_Is_Local_Name): Argument is local if
9808         the pragma comes fron a predicate aspect and the context is a
9809         record declaration within the scope that declares the type.
9811 2014-02-19  Robert Dewar  <dewar@adacore.com>
9813         * gnat_rm.texi: Minor clarifications.
9814         * expander.adb, sem_aggr.adb: Add comments.
9816 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
9818         * sem_prag.adb (Check_Arg_Is_Local_Name): For an aspect that
9819         applies to a subprogram body, the name is the current scope,
9820         rather than being declared in the current scope.
9821         (Analyze_Pragma, case No_Return): Handle properly a No_Return
9822         aspect applied to a subprogram body.
9824 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
9826         * sem_ch13.adb (Resolve_Iterable_Operation): Improve resolution
9827         of overloaded subprograms, and fix bug in handling of primitive
9828         operation Element.
9830 2014-02-19  Pascal Obry  <obry@adacore.com>
9832         * s-os_lib.adb: Minor reformatting.
9834 2014-02-19  Yannick Moy  <moy@adacore.com>
9836         * expander.adb (Expand): Do nothing inside generics.
9837         * sem_aggr.adb (Aggregate_Constraint_Checks): Do nothing inside
9838         generics.
9840 2014-02-19  Yannick Moy  <moy@adacore.com>
9842         * exp_ch2.adb: Remove useless 'with' of unit Uintp.
9844 2014-02-19  Robert Dewar  <dewar@adacore.com>
9846         * sem_ch3.adb, style.adb, sem_prag.adb, sem_ch13.adb: Minor reformatting
9847         * a-sequio.adb: Remove useless pragma Extensions_Allowed (no
9848         longer needed).
9850 2014-02-19  Claire Dross  <dross@adacore.com>
9852         * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
9853         a-cforse.ads, a-cofove.ads: Add Iterable aspect to formal containers.
9855 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
9857         * sem_ch3.adb (Analyze_Declarations): Analyze
9858         a package contract at the end of the private declarations (if
9859         applicable), otherwise analyze it and the end of the visible
9860         declarations.
9862 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
9864         * style.adb (Missing_Overriding): If subprogram is an
9865         instantiation, place warning on the instance node itself,
9866         without mention of the original generic. Do not emit message
9867         if explicit Ada version is older than the introduction of the
9868         overriding indicator.
9870 2014-02-19  Yannick Moy  <moy@adacore.com>
9872         * gnat_rm.texi: Doc clarifications.
9874 2014-02-19  Yannick Moy  <moy@adacore.com>
9876         * exp_util.adb (Remove_Side_Effects): Do not remove side-effects
9877         inside a generic.
9879 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
9881         * sem_ch13.adb (Get_Cursor_Type): Obtain cursor type from
9882         specified First primitive, rather than by name.
9883         (Validate_Iterable_Aspect, Resolve_Iterable_Operation): Use it,
9884         and extend error checking for missing primitives and incorrect
9885         signatures.
9887 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
9889         * sem_ch3.adb (Check_Pragma_Implemented): Detect additional
9890         errors when a Synchronization aspect on an overriding protected
9891         operation does not match the given aspect on the overridden
9892         operation of an ancestor interface.
9894 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
9896         * sem_prag.adb (Check_Loop_Pragma_Grouping): New routine.
9897         (Check_Loop_Pragma_Placement): Update
9898         comment on usage. Remove local variables Orig_Stmt and
9899         Within_Same_Sequence. Check that the current Loop_Invariant or
9900         Loop_Variant pragma is grouped together with other such pragmas.
9901         (Is_Loop_Pragma): New routine.
9902         (Prev_In_Loop): Removed.
9904 2014-02-19  Robert Dewar  <dewar@adacore.com>
9906         * par-ch6.adb (P_Return): For extended return, end column lines
9907         up with RETURN.
9908         * par.adb: Minor documentation clarification.
9910 2014-02-19  Yannick Moy  <moy@adacore.com>
9912         * sem_prag.adb (Check_Loop_Pragma_Placement): Add check
9913         that Loop_Invariant and Loop_Variant appear consecutively.
9914         * gnat_rm.texi Update documentation of Loop_Invariant and
9915         Loop_Variant pragmas.
9917 2014-02-19  Robert Dewar  <dewar@adacore.com>
9919         * debug.adb: Document -gnatd.X.
9920         * par-ch5.adb (P_If_Statement): Always check THEN, even if not
9921         first token
9922         (Check_Then_Column): Ditto.
9923         * styleg.adb (Check_Then): Allow THEN on line after IF.
9924         (Check_Then): Check THEN placement under control of -gnatd.X
9925         * styleg.ads (Check_Then): Now called even if THEN is not first
9926         token on line.
9927         * stylesw.ads (Style_Check_If_Then_Layout): Document new
9928         relaxed rules.
9929         * gnat_ugn.texi: For -gnatyi, THEN can now be on line after IF.
9931 2014-02-19  Robert Dewar  <dewar@adacore.com>
9933         * a-cfhama.adb, a-cfhase.adb, a-cforse.adb, a-cofove.adb, a-ngcefu.adb,
9934         a-teioed.adb, a-wtedit.adb, a-ztedit.adb, exp_ch5.adb, inline.adb,
9935         prj-pp.adb, prj-tree.adb, sem_ch12.adb, sem_ch8.adb,
9936         vms_conv.adb: Fix bad layout of IF statements
9938 2014-02-19  Robert Dewar  <dewar@adacore.com>
9940         * exp_util.adb (Side_Effect_Free): Scalar if expressions can be SEF.
9942 2014-02-19  Robert Dewar  <dewar@adacore.com>
9944         * exp_util.adb: Update comments.
9946 2014-02-19  Doug Rupp  <rupp@adacore.com>
9948         * bindgen.adb (Gen_Adainit) [VMS] New global Float_Format.
9949         * init.c (__gl_float_format): [VMS] New global.
9950         (__gnat_set_features): Call FP_CONTROL to set FPSR for the float
9951         representation in effect.
9953 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
9955         * exp_ch6.adb Add with and use clause for Exp_Prag.
9956         (Expand_Contract_Cases): Relocated to Exp_Prag.
9957         * exp_ch6.ads (Expand_Contract_Cases): Relocated to Exp_Prag.
9958         * exp_prag.adb Add with and use clauses for Checks and Validsw.
9959         (Expand_Contract_Cases): Relocated from Exp_Ch6. Update the
9960         structure of the expanded code to showcase the evaluation of
9961         attribute 'Old prefixes. Add local variable Old_Evals. Expand
9962         any attribute 'Old references found within a consequence. Add
9963         circuitry to evaluate the prefixes of attribute 'Old that
9964         belong to a selected consequence.
9965         (Expand_Old_In_Consequence): New routine.
9966         * exp_prag.ads (Expand_Contract_Cases): Relocated from Exp_Ch6.
9967         * sem_attr.adb (Check_Use_In_Contract_Cases): Warn that a
9968         potentially unevaluated prefix is always evaluated.
9970 2014-02-19  Robert Dewar  <dewar@adacore.com>
9972         * exp_attr.adb (Expand_Min_Max_Attribute): Use Insert_Declaration
9973         (Expand_Min_Max_Attribute): Use Matching_Standard_Type.
9974         * exp_ch4.adb (Expand_N_Expression_With_Actions): Remove special
9975         handling for the case of Modify_Tree_For_C, this approach did
9976         not work.
9977         * exp_util.adb (Matching_Standard_Type): New function
9978         (Side_Effect_Free): New top level functions (from
9979         Remove_Side_Effects).
9980         * exp_util.ads (Side_Effect_Free): New top level functions
9981         (moved from body).
9982         * sinfo.ads: Minor comment updates.
9984 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
9986         * exp_ch6.adb (Expand_Simple_Function_Return): If return
9987         type is unconstrained and uses the secondary stack, mark the
9988         enclosing function accordingly, to ensure that the value is not
9989         prematurely removed.
9991 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
9993         * par.adb Alphabetize the routines in Par.Sync.
9994         (Resync_Past_Malformed_Aspect): New routine.
9995         * par-ch13.adb (Get_Aspect_Specifications): Alphabetize local
9996         variables. Code and comment reformatting. Detect missing
9997         parentheses on aspects [Refined_]Global and [Refined_]Depends
9998         with a non-null definition.
9999         * par-sync.adb: Alphabetize all routines in this separate unit.
10000         (Resync_Past_Malformed_Aspect): New routine.
10002 2014-02-19  Robert Dewar  <dewar@adacore.com>
10004         * sem_eval.ads, sem_eval.adb (Subtypes_Statically_Match): Return False
10005         if Esize values do not match.
10007 2014-02-19  Yannick Moy  <moy@adacore.com>
10009         * sinfo.ads: Minor comment update.
10011 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
10013         * atree.ads: Minor reformatting (change Entity_Info to Einfo).
10015 2014-02-19  Thomas Quinot  <quinot@adacore.com>
10017         * exp_ch7.adb (Find_Node_To_Be_Wrapped): An assignment statement
10018         that has the No_Ctrl_Actions flag is a suitable node to be
10019         wrapped if the assigned expression has no finalization actions.
10020         * sem_eval.adb (Eval_Entity_Name): For a compile time known
10021         boolean value, mark the corresponding condition SCO as constant.
10023 2014-02-19  Robert Dewar  <dewar@adacore.com>
10025         * exp_util.adb: Minor reformatting.
10026         * exp_util.ads (Matching_Standard_Type): New function.
10027         * exp_ch7.adb: Minor reformatting.
10029 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
10031         * sem_ch13.adb (Get_Cursor_Type): Use scope of iterable type
10032         to find declaration for Cursor, to handle properly the case of
10033         a discriminated iterable type.
10035 2014-02-19  Vincent Celier  <celier@adacore.com>
10037         * gnatcmd.adb (GNATCmd): Always replace the object dirs of
10038         imported library projects with the library ALI dirs, when setting
10039         the object paths.
10040         * prj-env.ads (Ada_Objects_Path): Correct comments about
10041         argument Including_Libraries.
10043 2014-02-19  Gary Dismukes  <dismukes@adacore.com>
10045         * gnat_rm.texi: Minor spelling fixes.
10047 2014-02-19  Doug Rupp  <rupp@adacore.com>
10049         * init.c: Remove unneeded code.
10050         * fe.h (Float_Format): New macro
10051         * gcc-interface/trans.c (gigi): On VMS, set vms_float_format.
10053 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
10055         * sem_prag.adb (Check_Refined_Global_Item):
10056         A state or variable acts as a constituent only it is part of an
10057         encapsulating state and the state has visible refinement.
10059 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
10061         * sem_ch6.adb (Analyze_Subprogram_Contract): Do not warn on a
10062         postcondition for a function when the expression does not mention
10063         'Result but the function has in-out parameters.
10065 2014-02-19  Robert Dewar  <dewar@adacore.com>
10067         * gnat_rm.texi: Add documentation on Value_Size forcing biased
10068         representation.
10070 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
10072         * lib-xref.ads Remove the small table of letter and symbol usage as we
10073         already have one.
10075 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
10077         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Emit specific error
10078         messages depending on the offending misplaced aspect specifications.
10079         (Diagnose_Misplaced_Aspect_Specifications): New routine.
10081 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
10083         * sem_ch13.adb (Get_Cursor): Utility to retrieve cursor type
10084         for iterable aspect primitives.
10085         (Resolve_Iterable_Operation): Use expected signature of iterable
10086         aspect to resolve primitive when overloading is present.
10087         (Validate_Iterable_Aspect, Analyze_Aspects_At_Freeze_Point): use it.
10088         (Check_Signature): Removed.
10090 2014-02-19  Yannick Moy  <moy@adacore.com>
10092         * sem_ch10.adb (Analyze_Proper_Body): Issue error on missing
10093         subunit in GNATprove_Mode.
10094         * sinfo.ads (GNATprove_Mode): Document error issued in GNATprove_Mode.
10096 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
10098         * lib-xref.ads Alphabetize the contents of table
10099         Xref_Entity_Letters. Add an entry in table Xref_Entity_Letters
10100         for E_Abstract_State. List all letters and symbols in use.
10101         * sem_prag.adb (Analyze_Abstract_State): Update all calls
10102         to Create_Abstract_State to reflect the new signature.
10103         (Create_Abstract_State): Change subprogram profile and update
10104         the comment on usage. Use the proper location of the state
10105         declaration when creating a new abstract state entity. Do not
10106         generate an external name, but simply reuse the name coming from
10107         the state declaration.
10109 2014-02-19  Robert Dewar  <dewar@adacore.com>
10111         * exp_ch4.adb (Expand_N_Expression_With_Actions): Make sure
10112         declarations get properly inserted in Modify_Tree_For_C mode.
10113         * sinfo.ads: Minor comment addition.
10115 2014-02-19  Robert Dewar  <dewar@adacore.com>
10117         * par-ch9.adb, exp_ch5.adb, sem_ch5.adb, exp_attr.adb, sem_util.adb,
10118         sem_util.ads, sem_ch13.adb, sem_ch13.ads: Minor reformatting.
10120 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
10122         * style.adb (Missing_Overriding): Warning does not apply in
10123         language versions prior to Ada 2005.
10124         * snames.ads-tmpl: Add Name_Iterable and Attribute_Iterable.
10125         * sem_attr.adb: Add Attribute_Iterable where needed.
10126         * exp_attr.adb: ditto.
10127         * exp_ch5.adb (Expand_Formal_Container_Loop): New procedure to
10128         handle loops and quantified expressions over types that have an
10129         iterable aspect.  Called from Expand_Iterator_Loop.
10130         * sem_ch5.adb (Analyze_Iterator_Specification): Recognize types
10131         with Iterable aspect.
10132         * sem_ch13.adb (Validate_Iterable_Aspect): Verify that the
10133         subprograms specified in the Iterable aspect have the proper
10134         signature involving container and cursor.
10135         (Check_Aspect_At_Freeze_Point): Analyze value of iterable aspect.
10136         * sem_ch13.ads (Validate_Iterable_Aspect): New subprogram.
10137         * sem_util.ads, sem_util.adb (Get_Iterable_Type_Primitive):
10138         New procedure to retrieve one of the primitives First, Last,
10139         or Has_Element, from the value of the iterable aspect of a
10140         formal container.
10141         (Is_Container_Element): Predicate to recognize expressions
10142         that denote an element of one of the predefined containers,
10143         for possible optimization.  This subprogram is not currently
10144         used, pending ARG discussions on the legality of the proposed
10145         optimization. Worth preserving for eventual use.
10146         (Is_Iterator): Recognize formal container types.
10147         * aspects.ads, aspects.adb: Add Aspect_Iterable where needed.
10149 2014-02-19  Robert Dewar  <dewar@adacore.com>
10151         * exp_attr.adb (Expand_Min_Max_Attribute): New procedure
10152         (Expand_N_Attribute_Reference): Use this procedure for Min and Max.
10153         * exp_ch4.adb (Expand_N_Expression_With_Actions): Remove object
10154         declarations from list of actions.
10155         * output.ads, output.adb (Delete_Last_Char): New procedure.
10156         * sinfo.ads: Document handling of Mod and expression with actions
10157         in Modify_Tree_For_C mode.
10159 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
10161         * par-ch9.adb (P_Task): Add a null statement to produce a
10162         well-formed task body when due to a previous syntax error the
10163         statement list is empty.
10165 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
10167         * sem_prag.adb (Check_Dependency_Clause): Account
10168         for the case where a state with a non-null refinement matches a
10169         null output list. Comment reformatting.
10170         (Inputs_Match): Copy a solitary input to avoid an assertion failure
10171         when trying to match the same input in multiple clauses.
10173 2014-02-19  Gary Dismukes  <dismukes@adacore.com>
10175         * sem_attr.adb: Minor typo fix.
10177 2014-02-18  Robert Dewar  <dewar@adacore.com>
10179         * cstand.adb (Build_Signed_Integer_Type): Minor change of formal
10180         from Int to Nat (Build_Unsigned_Integer_Type): New procedure
10181         (Create_Standard): Create new unsigned types.
10182         * exp_ch4.adb (Expand_N_Op_Mod): Expand mod in Modify_Tree_For_C
10183         mode (Expand_N_Reference): Removed, problematic and not needed
10184         for now.
10185         * exp_ch4.ads (Expand_N_Reference): Removed, problematic and
10186         not needed for now.
10187         * exp_util.ads, exp_util.adb (Power_Of_Two): New function.
10188         * expander.adb: Remove call to Expand_N_Reference (problematic,
10189         and not needed now).
10190         * sem_aux.ads, sem_aux.adb (Corresponding_Unsigned_Type): New function.
10191         * stand.adb: Read and write unsigned type entities.
10192         * stand.ads: Add new unsigned types.
10194 2014-02-18  Hristian Kirtchev  <kirtchev@adacore.com>
10196         * sem_ch4.adb (Analyze_Call): Do not mark a function call
10197         as being inside an assertion expression as the flag is now removed.
10198         (Check_Ghost_Subprogram_Call): Do not query the
10199         In_Assertion_Expression flag as it is now removed, instead use
10200         a predicate function.
10201         * sem_elab.adb (Check_Internal_Call_Continue): Do not query the
10202         In_Assertion_Expression flag as it is now removed, instead use
10203         a predicate function.
10204         * sem_prag.ads: Add new table Assertion_Expression_Pragma.
10205         * sem_util.adb Add with and use clause for Sem_Prag.
10206         (In_Assertion_Expression_Pragma): New routine.
10207         * sem_util.ads (In_Assertion_Expression_Pragma): New routine.
10208         * sinfo.adb (In_Assertion_Expression): Removed.
10209         (Set_In_Assertion_Expression): Removed.
10210         * sinfo.ads Remove flag In_Assertion_Expression along with its
10211         use in nodes.
10212         (In_Assertion_Expression): Removed along with
10213         pragma Inline.  (Set_In_Assertion_Expression): Removed along
10214         with pragma Inline.
10216 2014-02-18  Sergey Rybin  <rybin@adacore.com frybin>
10218         * gnat_ugn.texi: gnatpp section: add note that '-j' cannot be
10219         used together with '-r', '-rf' or '-rnb' options.
10221 2014-02-18  Hristian Kirtchev  <kirtchev@adacore.com>
10223         * sem_attr.adb (Analyze_Attribute): Comment
10224         and code reformatting. Use separate routines to check the
10225         legality of attribute 'Old in certain pragmas. Verify
10226         the use of 'Old, 'Result and locally declared entities
10227         within the prefix of 'Old.
10228         (Check_References_In_Prefix): New routine.
10229         (Check_Use_In_Contract_Cases): New routine.
10230         (Check_Use_In_Test_Case): New routine.
10232 2014-02-18  Vincent Celier  <celier@adacore.com>
10234         * sem_aux.adb (Is_By_Reference_Type): For each components of
10235         a record type, check also if the component is volatile as it
10236         may have an aspect that makes it volatile. If it is, then the
10237         record type is a by reference type.
10239 2014-02-18  Robert Dewar  <dewar@adacore.com>
10241         * exp_attr.adb: Minor reformatting.
10242         * exp_ch4.ads, exp_ch4.adb (Expand_N_Reference): New procedure.
10243         * exp_util.adb (Remove_Side_Effects): Add conditional expressions
10244         as another case where we don't generate N_Reference nodes for
10245         primitive types.
10246         * expander.adb (Expand): Add call to Expand_N_Reference.
10248 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10250         * sem_prag.adb (Analyze_Refined_Pragma): Remove
10251         local variable Pack_Spec. Refinement pragmas may now apply to
10252         bodies of both visible and private subprograms.
10254 2014-02-06  Robert Dewar  <dewar@adacore.com>
10256         * exp_attr.adb (Expand_Loop_Entry_Attribute):
10257         Minor change (Attr => N) (Expand_Pred_Succ): New name
10258         Expand_Pred_Succ_Attribute (Expand_N_Attribute_Reference, case
10259         Max): Expand into if expression if Modify_Tree_For_C mode.
10260         (Expand_N_Attribute_Reference, case Min): ditto
10261         * sinfo.ads: Modify_Tree_For_C takes care of expanding Min and
10262         Max attributes.
10264 2014-02-06  Ed Schonberg  <schonberg@adacore.com>
10266         * sem_ch3.adb (Analyze_Object_Declaration): Do not generate
10267         predicate check if this is an internal declaration with
10268         No_Initialization set, as for an expanded aggregate component.
10270 2014-02-06  Doug Rupp  <rupp@adacore.com>
10272         * init.c (__gnat_default_resignal_p) [VMS]: Test for and resignal
10273         conditions with severity of "SUCCESS" or "INFORMATIONAL".
10275 2014-02-06  Yannick Moy  <moy@adacore.com>
10277         * sem_prag.adb (Analyze_Pragma): Analyze pragma
10278         Debug rewritten node before rewriting it as a null statement in
10279         GNATprove mode.
10281 2014-02-06  Robert Dewar  <dewar@adacore.com>
10283         * sem_attr.adb (Min_Max): New procedure.
10284         (Max_Alignment_For_Allocation_Max_Size_In_Storage_Elements): New
10285         procedure.
10287 2014-02-06  Sergey Rybin  <rybin@adacore.com frybin>
10289         * gnat_ugn.texi, vms_data.ads: Add documentation of '-t' option for
10290         gnatmetric/gnatpp.
10292 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10294         * sem_prag.adb (Analyze_Abstract_State): Update
10295         all calls to Create_Abstract_State to pass the proper state
10296         "declaration".
10297         (Create_Abstract_State): Add new formal parameter
10298         State_Decl along with comment on usage. Establish a link between
10299         the abstract state entity and the state declaration.
10301 2014-02-06  Robert Dewar  <dewar@adacore.com>
10303         * sem_attr.adb (Analyze_Attribute, case Max): Check for improper
10304         comparison of unordered enumeration type.
10305         (Analyze_Attribute, case Max): Check for improper comparison of
10306         unordered enumeration type.
10307         * sem_res.adb (Bad_Unordered_Enumeration_Reference): Moved to
10308         sem_util.adb.
10309         * sem_util.ads, sem_util.adb (Bad_Unordered_Enumeration_Reference):
10310         Moved here from Sem_Res.
10312 2014-02-06  Robert Dewar  <dewar@adacore.com>
10314         * sem_ch3.adb, sem_prag.adb, sem_res.adb, lib-xref.adb: Minor
10315         reformatting.
10317 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10319         * sem_ch6.adb (Process_Formals): Error message reformatting.
10321 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10323         * sem_ch3.adb (Handle_Late_Controlled_Primitive): Add local
10324         variable Spec. Do not inherit the null indicator from the
10325         subprogram body when generating the spec.
10327 2014-02-06  Robert Dewar  <dewar@adacore.com>
10329         * casing.adb (Determine_Casing): Consider SPARK_Mode to be
10330         mixed case.
10332 2014-02-06  Ed Schonberg  <schonberg@adacore.com>
10334         * exp_ch6.adb (Is_Build_In_Place_Function): Predicate is false
10335         when the function has a foreign convention, but not if only the
10336         limited return type has such a convention.
10338 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10340         * sem_ch3.adb (Handle_Late_Controlled_Primitive): Remove local
10341         variable Spec. Comment reformatting. Use Copy_Separate_Tree
10342         rather than New_Copy_Tree when building the corresponding
10343         subprogram declaration.
10345 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10347         * sem_prag.adb (Analyze_Global_Item): Remove
10348         the mode-related checks on abstract states with enabled external
10349         properties.
10350         (Property_Error): Removed.
10352 2014-02-06  Javier Miranda  <miranda@adacore.com>
10354         * lib-xref.adb (Generate_Reference): When
10355         generating the reference to the first private entity take care
10356         of handling swapped entities.
10358 2014-02-06  Sergey Rybin  <rybin@adacore.com frybin>
10360         * gnat_ugn.texi, vms_data.ads: Add documentation of -j option for
10361         gnatmetric.
10363 2014-02-06  Robert Dewar  <dewar@adacore.com>
10365         * exp_ch4.adb (Expand_N_Shift_Left): Handle shift counts greater
10366         than the word size when operating in Modify_Tree_For_C mode.
10367         * sinfo.ads: Add documentation section on Modify_Tree_For_C mode.
10369 2014-02-06  Robert Dewar  <dewar@adacore.com>
10371         * erroutc.adb (Warning_Specifically_Suppressed.Matches):
10372         compare is case insensitive.
10373         * gnat_rm.texi: Document that string compare for Warnings Off
10374         is now case insensitive.
10376 2014-02-06  Eric Botcazou  <ebotcazou@adacore.com>
10378         * gnat_rm.texi: Small wording tweak.
10380 2014-02-06  Pascal Obry  <obry@adacore.com>
10382         * prj-attr.adb, projects.texi, snames.ads-tmpl: Add Included_Patterns
10383         and Included_Artifact_Patterns attribute definitions.
10385 2014-02-06  Yannick Moy  <moy@adacore.com>
10387         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Set
10388         SPARK_Mode pragma component for all subprograms, including stubs.
10390 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10392         * sem_ch10.adb (Analyze_Package_Body_Stub): Maintain
10393         the configuration options of the enclosing context in a
10394         stack-like fasion.
10395         (Analyze_Subprogram_Body_Stub): Maintain the
10396         configuration options of the enclosing context in a stack-like
10397         fashion.
10399 2014-02-06  Robert Dewar  <dewar@adacore.com>
10401         * debug.adb: -gnatd.u sets Modify_Tree_For C
10402         * exp_ch4.adb (Expand_N_Op_Rotate_Left): Expand out
10403         if Modify_Tree_For_C (Expand_N_Op_Rotate_Right): ditto.
10404         (Expand_N_Op_Arithmetic_Right_Shift): ditto.
10405         * exp_intr.adb (Expand_Shift): Call expander so we do
10406         Modify_Tree_For_C expansions.
10407         * gnat1drv.adb (Adjust_Global_Switches): Set Modify_Tree_For_C
10408         if -gnatd.u set.
10410 2014-02-06  Fedor Rybin  <frybin@adacore.com>
10412         * prj-proc.ads (Tree_Loaded_Callback): new type Callback used
10413         after the phase 1 of the processing of each aggregated project
10414         to get access to project trees of aggregated projects.
10415         (Process_Project_Tree_Phase_1): new parameter On_New_Tree_Loaded
10416         If specified, On_New_Tree_Loaded is called after each aggregated
10417         project has been processed succesfully.
10418         (Process): new parameter On_New_Tree_Loaded.
10419         * prj-proc.adb (Process_Aggregated_Projects): On_New_Tree_Loaded
10420         callback added after processing of each aggregated project.
10421         (Recursive_Process): new parameter On_New_Tree_Loaded.
10422         (Process): new parameter On_New_Tree_Loaded.
10423         (Process_Project_Tree_Phase_1): new parameter On_New_Tree_Loaded.
10424         * prj-conf.ads (Parse_Project_And_Apply_Config): new parameter
10425         On_New_Tree_Loaded.
10426         * prj-conf.adb (Parse_Project_And_Apply_Config): new parameter
10427         On_New_Tree_Loaded.
10429 2014-02-06  Bob Duff  <duff@adacore.com>
10431         * gnat_ugn.texi: Implement --insert-blank-lines and
10432         --preserve-blank-lines switches.
10434 2014-02-06  Sergey Rybin  <rybin@adacore.com frybin>
10436         * gnat_ugn.texi, vms_data.ads: Add documentation of -j option for
10437         gnatelim.
10439 2014-02-06  Eric Botcazou  <ebotcazou@adacore.com>
10441         * gnat_rm.texi (Pragma Optimize_Alignment): Document the effect
10442         of the pragma on individual objects.
10444 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10446         * einfo.adb Node29 is now used as BIP_Initialization_Call.
10447         (BIP_Initialization_Call): New routine.
10448         (Set_BIP_Initialization_Call): New routine.
10449         (Write_Field29_Name): Add an entry for constants and variables.
10450         * einfo.ads Add new attribute BIP_Initialization_Call and update
10451         its usage in nodes.
10452         (BIP_Initialization_Call): New routine along with pragma Inline.
10453         (Set_BIP_Initialization_Call): New routine along with pragma Inline.
10454         * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
10455         Add local declaration Res_Decl. Capture the build-in-place
10456         initialization call when the related object declaration has
10457         created a transient block.
10458         * exp_ch7.adb (Process_Transient_Objects): Add local variable
10459         Fin_Insrt. Recognize a scenario where an object declaration acts
10460         as a transient context and is initialized by a build-in-place
10461         function call.
10463 2014-02-06  Pascal Obry  <obry@adacore.com>
10465         * prj-util.adb (For_Interface_Sources): Fix handling of required
10466         bodies for aggregate libs.
10468 2014-02-06  Robert Dewar  <dewar@adacore.com>
10470         * nlists.ads: Minor comment clarifications.
10472 2014-02-06  Robert Dewar  <dewar@adacore.com>
10474         * gnat1drv.adb (Adjust_Global_Switches): Set Modify_Tree_For_C
10475         if gnatd.V set.
10476         * opt.ads (Modify_Tree_For_C): New flag.
10477         * output.ads, output.adb (Last_Char): New function.
10479 2014-02-06  Pascal Obry  <obry@adacore.com>
10481         * projects.texi, prj-env.adb (Initialize_Default_Project_Path): Add
10482         share/gpr for cross-builds.
10484 2014-02-06  Robert Dewar  <dewar@adacore.com>
10486         * exp_util.ads, checks.adb, sem_prag.adb, prj-util.adb, sem_ch13.adb:
10487         Minor reformatting and code clean ups.
10489 2014-02-06  Pascal Obry  <obry@adacore.com>
10491         * prj-util.adb (For_Interface_Sources): Skip non compilable languages.
10492         * prj.ads: Minor typo fix in comment.
10494 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10496         * sem_prag.adb (Analyze_Depends_In_Decl_Part): Add
10497         local variable Expr. Flag clauses with extra parenthesis as this
10498         is not allowed by the syntax of the pragma. Code reformatting.
10500 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10502         * exp_attr.adb (Expand_N_Attribute_Reference): Alphabetize
10503         variables. Rename variabme Tnn to Temp. Do not create a temporary
10504         if assertions are disabled. Find enclosing routine _Postconditions
10505         and insert the temporary that captures the value of the prefix
10506         before the routine.
10507         * exp_ch6.adb (Build_Postconditions_Procedure):
10508         Insert the generated _Postconditions routine
10509         before the first source declaration of the related
10510         subprogram.
10511         (Insert_After_Last_Declaration): Removed.
10512         (Insert_Before_First_Source_Declaration): New routine.
10514 2014-02-06  Ed Schonberg  <schonberg@adacore.com>
10516         * exp_util.adb, exp_util.ads (Within_Internal_Subprogram):
10517         Utility to determine whether current expansion is for the body
10518         of a predefined primitive operation.
10519         (Make_Predicate_Check): Use Within_Internal_Subpgram
10520         * checks.adb (Apply_Predicate_Check): Use
10521         Within_Internal_Subprogram
10522         * sem_ch13.adb (Freeze_Entity_Checks): Ditto.
10524 2014-02-06  Pascal Obry  <obry@adacore.com>
10526         * prj.ads, prj-util.adb: Minor reformatting.
10528 2014-02-06  Ed Schonberg  <schonberg@adacore.com>
10530         * exp_ch6.adb (Expand_Subprogram_Contract, Append_Enabled_Item):
10531         Take into account the Split_PPC flag to ensure that conjuncts
10532         in a composite postcondition aspect are tested in source order.
10534 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10536         * sem_ch6.adb (Analyze_Generic_Subprogram_Body): Flag illegal
10537         use of SPARK_Mode.
10538         * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): Flag
10539         illegal use of SPARK_Mode.
10540         (Instantiate_Subprogram_Body): Flag illegal use of SPARK_Mode.
10541         * sem_prag.adb (Analyze_Pragma): Code reformatting.
10542         * sem_util.adb Add with and use clause for Aspects.
10543         (Check_SPARK_Mode_In_Generic): New routine.
10544         * sem_util.ads (Check_SPARK_Mode_In_Generic): New routine.
10546 2014-02-06  Thomas Quinot  <quinot@adacore.com>
10548         * a-calend.adb (Formatting_Operations.Split): Ensure that
10549         Time_Error is raised for invalid time values.
10551 2014-02-06  Arnaud Charlet  <charlet@adacore.com>
10553         * sem_prag.adb (Analyze_Pragma): Rewrite as a null statement
10554         in GNATprove_Mode.
10556 2014-02-06  Robert Dewar  <dewar@adacore.com>
10558         * einfo.ads, einfo.adb (Is_Discriminant_Check_Function): New flag.
10559         * exp_ch3.adb (Build_Dcheck_Function): Set
10560         Is_Discriminant_Check_Function.
10562 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10564         * exp_ch7.adb (Is_Subprogram_Call): Inspect
10565         the original tree in certain cases where a construct has been
10566         factored out and replaced by a reference to a temporary.
10568 2014-02-06  Ed Schonberg  <schonberg@adacore.com>
10570         * sem_ch3.adb (Process_Full_View): Fix typo in the order of
10571         parameters when propagating predicate function to full view.
10572         (Find_Type_Of_Object): Freeze base type of object type to catch
10573         premature use of discriminated private type without a full view.
10575 2014-02-06  Robert Dewar  <dewar@adacore.com>
10577         * sprint.adb: Minor reformatting.
10579 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10581         * exp_ch4.adb (Process_Transient_Object): Add local variable
10582         Temp_Ins. When the transient object is initialized by an
10583         aggregate, the hook must capture the object after the last
10584         component assignment takes place.
10585         * exp_ch7.adb (Detect_Subprogram_Call): Expose the subprogram to
10586         routine Is_Subprogram_Call.
10587         (Is_Subprogram_Call): Inspect an
10588         aggregate that has been heavily expanded for subprogram calls.
10589         (Process_Transient_Objects): Add local variables Expr, Ptr_Id
10590         and Temp_Ins.  Remove the nested declare block and adjust the
10591         indentation. When the transient object is initialized by an
10592         aggregate, the hook must capture the object after the last
10593         component assignment takes place.
10595 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10597         * sem_prag.adb (Analyze_Global_Item): Detect illegal uses of
10598         external states with enabled properties that do not match the
10599         global mode.
10600         (Property_Error): New routine.
10601         * sem_res.adb (Property_Error): New routine.
10602         (Resolve_Actuals): Detect illegal uses of external variables with
10603         enabled properties in procedure calls that do not match the mode of
10604         the corresponding formal parameter.
10606 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
10608         * sem_util.adb (Has_Enabled_Property): Rename
10609         formal parameter Prop_Nam to Property. Update the comment on usage
10610         and all occurrences in the body. Add local variable Prop_Nam. When
10611         inspecting a property with an expression, the property name
10612         appears as the first choice of the component association.
10614 2014-02-04  Robert Dewar  <dewar@adacore.com>
10616         * exp_ch5.adb, einfo.ads, freeze.adb, sem_ch8.adb: Minor reformatting.
10618 2014-02-04  Gary Dismukes  <dismukes@adacore.com>
10620         * sem_aggr.adb: Change "runtime" to "run time" in warning message,
10621         for consistency with other messages.
10623 2014-02-04  Ed Schonberg  <schonberg@adacore.com>
10625         * exp_ch5.adb  (Expand_Iterator_Loop):  For a container element
10626         iterator, indicate that the element is a constant if the container
10627         type does not have a variable indexing aspect.
10628         * sem_ch8.adb (Analyze_Object_Renaming): If the entity is already
10629         marked as constant, do not reset its Ekind, to ensure that
10630         container elements in an element loop are not modified if the
10631         container (e.g. a hashed set) only has a constant indexing aspect.
10633 2014-02-04  Arnaud Charlet  <charlet@adacore.com>
10635         * g-souinf.ads: Subprograms in this unit are actually not pure.
10636         * freeze.adb (Freeze_Subprogram): Do not reset Is_Pure for Intrinsics.
10637         * einfo.ads (Is_Pure): Update doc to match implementation.
10639 2014-02-04  Gary Dismukes  <dismukes@adacore.com>
10641         * exp_ch13.adb: Minor spelling fix.
10643 2014-02-04  Robert Dewar  <dewar@adacore.com>
10645         * opt.ads: Minor comment update.
10647 2014-02-04  Robert Dewar  <dewar@adacore.com>
10649         * exp_ch4.adb (Expand_N_Expression_With_Actions): Use Rewrite
10650         instead of Replace.
10652 2014-02-04  Ed Schonberg  <schonberg@adacore.com>
10654         * sem_aggr.adb (Resolve_Array_Aggregate): Suppress warnings
10655         on null expressions if component type is non-null, when the
10656         corresponding association covers an empty range of index values.
10658 2014-02-04  Robert Dewar  <dewar@adacore.com>
10660         * sinfo.ads: Further comments on N_Expression_With_Actions node.
10662 2014-02-04  Hristian Kirtchev  <kirtchev@adacore.com>
10664         * sem_prag.adb (Analyze_Refined_Depends_In_Decl_Part): Remove global
10665         variables Out_Items and Ref_Global. Remove local constant
10666         Body_Id along with dummy variables D1, D2, D3, D4, D5, D6, D7
10667         and D8. Remove the useless collection of global items as this
10668         was a leftover from an earlier version of the routine. Move
10669         several routines out to avoid deep nesting and indentation.
10670         (Inputs_Match): Add formal parameter Dep_Clause. Rename formal
10671         parameter Do_Checks to Post_Errors. Update the comment on usage.
10672         (Is_Matching_Input): Renamed to Input_Match. Add formal parameters
10673         Ref_Inputs and Do_Checks. Rename formal parameter Do_Checks
10674         to Post_Errors. Update the comment on usage. Account for the
10675         case where a self referential state may have a null input_list.
10676         (Is_Self_Referential): New routine.
10678 2014-02-04  Ed Schonberg  <schonberg@adacore.com>
10680         * sem_ch13.adb (Analyze_Attribute_Definition_Clause): If the
10681         entity renames an expression, as in the case of an object of
10682         an unconstrained type initialized by a function call, defer the
10683         rewriting of the expression to the expander.
10684         * exp_ch13.adb (Expand_N_Attribute_Definition_Clause, case
10685         'Alignment): If the entity renames an expression, introduce
10686         temporary to capture value, and rewrite original declaration to
10687         use temporary.
10689 2014-02-04  Gary Dismukes  <dismukes@adacore.com>
10691         * g-comlin.adb: Minor typo fix.
10693 2014-02-04  Ed Schonberg  <schonberg@adacore.com>
10695         * freeze.adb (Freeze_All): Types derived from a formal
10696         access_to_classwide type do not have a finalization master.
10698 2014-02-04  Robert Dewar  <dewar@adacore.com>
10700         * sprint.adb: Minor reformatting.
10702 2014-02-04  Robert Dewar  <dewar@adacore.com>
10704         * exp_ch4.adb (Expand_N_Expression_With_Actions): Eliminate
10705         cases where Actions is a null list.
10706         * sinfo.ads (N_Expression_With_Actions): Actions can be
10707         temporarily empty during semantic analysis, but must be non-empty
10708         in the final expanded tree.
10710 2014-01-31  Robert Dewar  <dewar@adacore.com>
10712         * exp_ch9.adb: Minor reformatting.
10714 2014-01-31  Emmanuel Briot  <briot@adacore.com>
10716         * g-comlin.adb (Set_Command_Line): Take the switches
10717         configuration from the Command_Line_Config.
10719 2014-01-31  Hristian Kirtchev  <kirtchev@adacore.com>
10721         * sem_prag.adb (Analyze_Refinement_Clause): Guard against a malformed
10722         refinement clause.
10724 2014-01-31  Vincent Celier  <celier@adacore.com>
10726         * projects.texi: Add more documentation about others used as an
10727         index in indexed attributes.
10729 2014-01-31  Robert Dewar  <dewar@adacore.com>
10731         * gnat_ugn.texi: Minor update.
10732         * gnat_rm.texi: Add example to Restriction_Warnings documentation.
10733         * exp_util.adb: Minor reformatting.
10735 2014-01-31  Ed Schonberg  <schonberg@adacore.com>
10737         * exp_ch9.adb (Expand_Entry_Barrier): Warn if the barrier
10738         depends on data that is not private to the protected object,
10739         and potentially modifiable in unsynchronized fashion.
10741 2014-01-31  Yannick Moy  <moy@adacore.com>
10743         * erroutc.adb (Validate_Specific_Warnings): Remove special case for
10744         GNATprove_Mode.
10746 2014-01-31  Robert Dewar  <dewar@adacore.com>
10748         * prj-attr.ads (First_Attribute_Of): Returns Empty_Attribute
10749         for Unknown_Package.
10750         * sem_ch6.adb, sem_attr.adb: Minor comment addition.
10752 2014-01-31  Hristian Kirtchev  <kirtchev@adacore.com>
10754         * exp_util.adb (Build_Allocate_Deallocate_Proc): Rewrite
10755         the logic that generates a runtime check to determine the
10756         controlled status of the object about to be allocated or
10757         deallocated. Class-wide types now always use a runtime check
10758         even if they appear as generic actuals.
10759         (Find_Object): Detect
10760         a special case that involves interface class-wide types because
10761         the object appears as a complex expression.
10763 2014-01-31  Ed Schonberg  <schonberg@adacore.com>
10765         * sem_ch6.adb (Process_Formals): In Ada2012 mode, place
10766         subprogram with an incomplete untagged formals on the list of
10767         private dependents, to verify that the type is properly completed
10768         in the private part.
10769         * sem_attr.adb: Code clean up.
10771 2014-01-31  Robert Dewar  <dewar@adacore.com>
10773         * exp_ch6.adb: Minor reformatting.
10775 2014-01-31  Vincent Celier  <celier@adacore.com>
10777         * prj-attr.adb (First_Attribute_Of): Return Unknown_Attribute
10778         when Pkg is unknown.
10780 2014-01-31  Hristian Kirtchev  <kirtchev@adacore.com>
10782         * sem_res.adb (Resolve_Entity_Name): Comment
10783         reformatting. Allow volatile objects in various generated checks.
10785 2014-01-31  Ed Schonberg  <schonberg@adacore.com>
10787         * sem_attr.adb (Analyze_Attribute, case 'Update): For a record
10788         component association, set the etype of the identifier, for
10789         SPARK use.
10791 2014-01-31  Ed Schonberg  <schonberg@adacore.com>
10793         * exp_ch6.adb (Has_Visibility_Of_Subprogram): If type is not
10794         declared in a package, not checks can apply to the subprogram.
10796 2014-01-31  Robert Dewar  <dewar@adacore.com>
10798         * erroutc.adb (Validate_Specific_Warnings): Warnings are
10799         controlled -gnatw.W.
10800         * gnat_ugn.texi: Document new warnings controlled by -gnatw.w.
10801         * opt.ads (Warn_On_Warnings_Off): Now controls more cases.
10803 2014-01-31  Arnaud Charlet  <charlet@adacore.com>
10805         * exp_disp.adb: Update comments.
10807 2014-01-31  Yannick Moy  <moy@adacore.com>
10809         * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration,
10810         Save_Global_References): Guard access to expression in aspect.
10812 2014-01-31  Yannick Moy  <moy@adacore.com>
10814         * sem_prag.adb (Analyze_Pragma/Pragma_SPARK_Mode):
10815         Issue an error when the pragma is applied to a generic unit,
10816         a generic declaration, or inside a generic.
10818 2014-01-31  Yannick Moy  <moy@adacore.com>
10820         * sem_ch8.adb (Analyze_Subprogram_Renaming): Set SPARK_Mode on renaming
10821         entity.
10823 2014-01-31  Robert Dewar  <dewar@adacore.com>
10825         * exp_ch9.adb, s-tassta.adb, s-tposen.adb, s-tposen.ads: Minor
10826         reformatting.
10828 2014-01-31  Tristan Gingold  <gingold@adacore.com>
10830         * exp_disp.adb: Add a historic note.
10832 2014-01-31  Robert Dewar  <dewar@adacore.com>
10834         * sem_warn.adb (Warn_On_Useless_Assignments): Add call to
10835         Process_Deferred_References.
10837 2014-01-31  Yannick Moy  <moy@adacore.com>
10839         * erroutc.adb (Validate_Specific_Warnings): Do not issue a message for
10840         ineffective pragma Warnings(Off) in GNATprove_Mode.
10842 2014-01-31  Bob Duff  <duff@adacore.com>
10844         * s-taskin.ads: Minor comment fix.
10845         * s-tassta.adb (Abort_Dependents): Don't abort all dependents;
10846         just direct dependents. If this is actually an abort, each task
10847         will take care of aborting its dependents, so all dependents will
10848         get aborted, as before. However, when this is called the second
10849         time from Vulnerable_Complete_Master "for convenience" (i.e. to
10850         kill off tasks waiting at terminate alternatives), aborting
10851         indirect dependents is wrong, because it causes some unrelated
10852         tasks to get aborted.
10854 2014-01-31  Robert Dewar  <dewar@adacore.com>
10856         * sem_ch4.adb: Minor reformatting.
10858 2014-01-31  Robert Dewar  <dewar@adacore.com>
10860         * exp_ch2.adb: New calling sequence for Is_LHS.
10861         * frontend.adb: Add call to Process_Deferred_References.
10862         * lib-xref.ads, lib-xref.adb (Process_Deferred_References): New.
10863         (Deferred_References): New table.
10864         * sem_ch8.adb (Find_Direct_Name): Make deferred reference table
10865         entries.
10866         (Find_Expanded_Name): Ditto.
10867         * sem_res.adb: New calling sequence for Is_LHS.
10868         * sem_util.ads, sem_util.adb (Is_LHS): New calling sequence.
10869         * sem_warn.adb: Call Process_Deferred_References before issuing
10870         warnings.
10872 2014-01-31  Tristan Gingold  <gingold@adacore.com>
10874         * exp_util.adb (Corresponding_Runtime_Package): Restrict the
10875         use of System_Tasking_Protected_Objects_Single_Entry.
10876         * exp_ch9.adb (Build_Simple_Entry_Call): Remove Mode parameter
10877         of Protected_Single_Entry_Call.
10878         (Expand_N_Timed_Entry_Call): Remove single_entry case.
10879         * exp_disp.adb (Make_Disp_Asynchronous_Select_Body): Remove
10880         single_entry case.
10881         (Make_Disp_Timed_Select_Body): Likewise.
10882         * rtsfind.ads (RE_Timed_Protected_Single_Entry_Call): Remove.
10883         * s-tposen.adb (Send_Program_Error, PO_Do_Or_Queue): Remove
10884         Self_Id parameter.
10885         (Wakeup_Entry_Caller): Remove Self_ID and New_State parameters.
10886         (Wait_For_Completion_With_Timeout): Remove.
10887         (Protected_Single_Entry_Call): Remove Mode parameter
10888         (always Simple_Call).
10889         (Service_Entry): Remove Self_Id constant (not used anymore).
10890         (Timed_Protected_Single_Entry_Call): Remove.
10891         * s-tposen.ads (Timed_Protected_Single_Entry_Call): Remove.
10892         (Protected_Single_Entry_Call): Remove Mode parameter.
10894 2014-01-29  Hristian Kirtchev  <kirtchev@adacore.com>
10896         * einfo.adb (Get_Pragma): Handle the retrieval of pragma Refined_Post.
10897         * einfo.ads (Get_Pragma): Update the comment on special pragmas
10898         handled by this routine.
10899         * sem_prag.adb (Analyze_Pragma): Add a legal pragma Refined_Post
10900         to the contract of the related subprogram body.
10901         * sem_util.adb (Add_Contract_Item): Handle the insertion of
10902         pragma Refined_Post into the contract of a subprogram body.
10903         * sinfo.ads Update the documentation of node N_Contract.
10904         * sem_res.adb (Resolve_Entity_Name): Add a guard
10905         to detect abstract states and variables only when checking the
10906         SPARK 2014 rules concerning volatile object placement.
10908 2014-01-29  Ed Schonberg  <schonberg@adacore.com>
10910         * sem_ch4.adb (Find_Equality_Types, Try_One_Interp): within an instance,
10911         null is compatible with any access type.
10913 2014-01-29  Hristian Kirtchev  <kirtchev@adacore.com>
10915         * sem_util.adb (Find_Placement_In_State_Space): Assume that the default
10916         placement is not in a package.
10918 2014-01-29  Hristian Kirtchev  <kirtchev@adacore.com>
10920         * sem_util.adb (Has_Enabled_Property): Compare the character field of
10921         the sole property.
10923 2014-01-29  Robert Dewar  <dewar@adacore.com>
10925         * sem_intr.adb, a-ztexio.ads, sinfo.ads, sem_res.adb, gnatlink.adb,
10926         vms_conv.adb, a-except.ads, a-except-2005.ads, a-teioed.adb,
10927         sem_warn.ads, treepr.ads, erroutc.ads, a-excach.adb: Minor reformatting.
10929 2014-01-29  Robert Dewar  <dewar@adacore.com>
10931         * sem_util.ads, sem_util.adb (In_Pragma_Expression): New function.
10932         * sem_warn.adb (Check_References): Suppress warnings if inside
10933         Initial_Condition pragma.
10935 2014-01-29  Hristian Kirtchev  <kirtchev@adacore.com>
10937         * sem_prag.adb (Check_Missing_Part_Of): List all values of
10938         State_Space_Kind for readability reasons. Do not emit an error on
10939         a private item when the enclosing package lacks aspect/pragma
10940         Abstract_State. Do not emit an error on a private package
10941         instantiation when the corresponding generic template lacks
10942         visible state.
10943         (Has_Visible_State): New routine.
10944         * sem_util.adb (Find_Placement_In_State_Space): The visible
10945         declarations of any kind of child units in general act as proper
10946         placement location.
10948 2014-01-29  Robert Dewar  <dewar@adacore.com>
10950         * a-except-2005.adb, a-except.adb, a-excpol-abort.adb, a-exstat.adb,
10951         ali.adb, a-numaux.ads, a-numaux-darwin.ads, a-numaux-libc-x86.ads,
10952         a-numaux-vms.ads, a-numaux-vxworks.ads, a-numaux-x86.ads, aspects.ads,
10953         a-taside.adb, a-teioed.adb, a-textio.adb, a-textio.ads, atree.adb,
10954         atree.ads, a-witeio.adb, a-witeio.ads, a-wtedit.adb, a-ztedit.adb,
10955         a-ztexio.adb, bcheck.adb, binde.adb, checks.adb, comperr.adb,
10956         cstand.adb, debug_a.adb, einfo.ads, errout.adb, erroutc.adb,
10957         eval_fat.adb, exp_aggr.adb, exp_attr.adb, exp_ch11.adb, exp_ch3.adb,
10958         exp_ch4.adb, exp_ch5.adb, exp_ch6.adb, exp_ch9.adb, exp_dbug.adb,
10959         exp_disp.adb, exp_fixd.adb, exp_imgv.adb, exp_intr.adb, exp_util.adb,
10960         freeze.adb, frontend.adb, g-comlin.ads, g-mbdira.adb, gnat1drv.adb,
10961         gprep.adb, g-spipat.adb, i-cpp.ads, i-vxwork.ads, i-vxwork-x86.ads,
10962         krunch.ads, layout.adb, lib-load.adb, lib-writ.adb, lib-writ.ads,
10963         live.adb, namet.ads, osint.adb, osint-c.adb, output.ads, par.adb,
10964         par-ch10.adb, par-ch13.adb, par-ch3.adb, par-ch4.adb, par-ch5.adb,
10965         par-ch6.adb, par-ch9.adb, par-endh.adb, par-labl.adb, par-prag.adb,
10966         par-sync.adb, par-tchk.adb, par-util.adb, prj.adb, repinfo.adb,
10967         rtsfind.adb, s-arit64.adb, s-asthan-vms-alpha.adb,
10968         s-asthan-vms-ia64.adb, s-bignum.adb, scans.adb, scng.adb, s-dimmks.ads,
10969         sem_aggr.adb, sem_attr.adb, sem_aux.adb, sem_cat.adb, sem_ch10.adb,
10970         sem_ch12.adb, sem_ch13.adb, sem_ch13.ads, sem_ch3.adb, sem_ch4.adb,
10971         sem_ch5.adb, sem_ch6.adb, sem_ch8.adb, sem_disp.adb, sem_elab.adb,
10972         sem_elim.adb, sem_eval.adb, sem_intr.adb, sem_prag.adb, sem_res.adb,
10973         sem_type.adb, sem_util.adb, sem_warn.adb, set_targ.adb, s-fatgen.adb,
10974         s-fatgen.ads, s-fileio.adb, s-imgcha.adb, s-imgrea.adb, sinfo.ads,
10975         sinput-c.adb, snames.ads-tmpl, s-os_lib.adb, sprint.adb,
10976         s-regpat.adb, s-secsta.adb, s-stalib.ads,
10977         s-stchop.adb, s-stoele.ads, stand.ads, s-taprop-solaris.adb,
10978         s-tasdeb-vms.adb, s-tasini.adb, s-tassta.adb, s-valdec.adb,
10979         s-valuti.adb, s-wchjis.adb, s-wchwts.adb, system.ads, system-vms_64.ads,
10980         system-vms-ia64.ads, treepr.adb, types.ads, uintp.adb, uname.adb,
10981         urealp.adb, usage.adb, vxaddr2line.adb: Minor reformatting.
10983 2014-01-29  Robert Dewar  <dewar@adacore.com>
10985         * expander.adb: Minor reformatting.
10987 2014-01-29  Javier Miranda  <miranda@adacore.com>
10989         * exp_ch3.adb (Predefined_Primitive_Bodies): Adding documentation to
10990         previous patch.
10992 2014-01-29  Javier Miranda  <miranda@adacore.com>
10994         * exp_ch3.adb (Predefined_Primitive_Bodies): Complete the code
10995         that checks if an interface types defines the predefined "="
10996         function because the compiler was erroneously not generating the
10997         predefined "=" primitive as soon as the name of some interface
10998         primitive is "=" (formals were not checked).
11000 2014-01-29  Ed Schonberg  <schonberg@adacore.com>
11002         * expander.adb (Expander): In GNATprove mode, do not process
11003         transient scopes: they are in general not created in this mode,
11004         and an attempt to examine them will lead to constraint errors when
11005         processing configuration pragmas that have analyzable expressions.
11007 2014-01-29  Vincent Celier  <celier@adacore.com>
11009         * clean.adb (Gnatclean): Fail if main project is an aggregate
11010         project or if there is an aggregate library project in the
11011         project tree.
11012         * gnatcmd.adb: Fail if the main project is an aggregate project
11013         or if there is an aggegate library project in the project tree.
11014         * make.adb (Initialize): : Fail if main project is an aggregate
11015         project or if there is an aggregate library project in the
11016         project tree.
11017         * makeutl.ads (Aggregate_Libraries_In): New Boolean function.
11018         * prj-makr.adb (Initialize): Fail if the main project is an
11019         aggregate project or an aggregate library project.
11021 2014-01-29  Vincent Celier  <celier@adacore.com>
11023         * prj-part.adb (Check_Import_Aggregate): New procedure
11024         to check if an imported project is an aggregate project.
11025         (Parse_Single_Project): Call Check_Import_Aggregate
11026         * projects.texi: Document that aggregate projects cannot be
11027         extended or imported.
11029 2014-01-29  Robert Dewar  <dewar@adacore.com>
11031         * exp_ch9.adb, sem_ch7.ads, s-regexp.adb, sem_ch13.adb: Minor
11032         reformatting and code clean up.
11033         * gnat_ugn.texi: Add documentation section on Atomic Variables
11034         and Optimization.
11036 2014-01-29  Hristian Kirtchev  <kirtchev@adacore.com>
11038         * einfo.adb Flag264 is now unused.
11039         (Has_Body_References): Removed.
11040         (Set_Has_Body_References): Removed.
11041         (Write_Entity_Flags): Remove the output for flag Has_Body_References.
11042         * einfo.ads Update the comment on usage of attribute
11043         Body_References. Remove attribute Has_Body_References and its
11044         usage in nodes.
11045         (Has_Body_References): Removed along with pragma Inline.
11046         (Set_Has_Body_References): Removed along with pragma Inline.
11047         * sem_prag.adb (Analyze_Global_Item): Move the call to
11048         Record_Possible_Body_Reference in the state related checks
11049         section. Add a comment intended function.
11050         (Analyze_Input_Output): Move the call to Record_Possible_Body_Reference
11051         in the state related checks section. Add a comment intended function.
11052         (Analyze_Refinement_Clause): Cleanup the illegal body reference
11053         reporting. Add a comment on timing of error reporting.
11054         (Record_Possible_Body_Reference): Reimplement the routine.
11056 2014-01-29  Vincent Celier  <celier@adacore.com>
11058         * makeutl.adb (Mains.Find_File_Add_Extension): Only look for specs for
11059         unit-based languages.
11060         (Mains.Complete_Mains.Do_Complete): Use the source file project
11061         tree when calling Find_File_Add_Extension. Use the correct
11062         project name when reporting an error.
11064 2014-01-29  Hristian Kirtchev  <kirtchev@adacore.com>
11066         * aspects.adb Add an entry for aspect Part_Of in table
11067         Canonical_Aspect.
11068         * aspects.ads Add an entry for aspect Part_Of in tables Aspect_Id,
11069         Aspect_Argument, Aspect_Names and Aspect_Delay.
11070         * atree.h Define Elist9.
11071         * atree.adb (Elist9): New routine.
11072         (Set_Elist9): New routine.
11073         * atree.ads (Elist9): New routine.
11074         (Set_Elist9): New routine.
11075         * einfo.adb Add Part_Of_Constituents and Encapsulating_State to
11076         the list of node usage.  Remove Refined_State from the list of
11077         node usage.
11078         (Encapsulating_State): New routine.
11079         (Get_Pragma):
11080         Handle pragma Part_Of; (Part_Of_Constituents): New routine.
11081         (Refined_State): Removed.
11082         (Set_Encapsulating_State): New routine.
11083         (Set_Part_Of_Constituents): New routine.
11084         (Set_Refined_State): Removed.
11085         (Write_Field9_Name): Add an entry
11086         for Part_Of_Constituents (Write_Field10_Name): Add an entry for
11087         Encapsulating_State. Remove the entry for Refined_State.
11088         * einfo.ads Add new attributes Encapsulating_State
11089         and Part_Of_Constituents alond with their usage in
11090         entities. Remove attribute Refined_State along with its
11091         usage in entities.
11092         (Encapsulating_State): New routine and
11093         pragma Inline.  (Get_Pragma): Update the comment on usage.
11094         (Part_Of_Constituents): New routine and pragma Inline.
11095         (Refined_State): Removed along with pragma Inline.
11096         (Set_Encapsulating_State): New routine and pragma Inline.
11097         (Set_Part_Of_Constituents): New routine and pragma Inline.
11098         (Set_Refined_State): Removed along with pragma Inline.
11099         * par-prag.adb Pragma Part_Of does not need any special processing
11100         by the parser.
11101         * sem_ch3.adb (Analyze_Declarations): Remove local variables
11102         Body_Id and Prag. Call separate routines to analyze the
11103         contract of a package [body].
11104         (Analyze_Object_Contract):
11105         Update the comment on usage. Remove local variables
11106         Items and Nam. Use Get_Pragma rather than traversing the
11107         classification list.  Verify whether the lack of indicator
11108         Part_Of agrees with the placement of the variable in state space.
11109         (Analyze_Object_Declaration): Initialize the encapsulating state
11110         of a variable.  (Requires_State_Refinement): Moved to sem_util.
11111         * sem_ch7.adb (Analyze_Package_Body_Contract): New routine.
11112         (Analyze_Package_Contract): New routine.
11113         * sem_ch7.ads (Analyze_Package_Body_Contract): New routine.
11114         (Analyze_Package_Contract): New routine.
11115         * sem_ch10.adb (Decorate_State): Initialize the encapsulating
11116         state and Part_Of constituents.
11117         * sem_ch13.adb (Analyze_Aspect_Specifications):
11118         Add processing for aspect Part_Of. Update all
11119         calls to Decorate_Delayed_Aspect_And_Pragma.
11120         (Check_Aspect_At_Freeze_Point): Aspect Part_Of does
11121         not need any special processing at freeze time.
11122         (Decorate_Delayed_Aspect_And_Pragma): Renamed to
11123         Decorate_Aspect_And_Pragma.  Add formal parameter Delayed and
11124         update the associated comment.
11125         * sem_prag.adb Add an entry for pragma Part_Of in table Sig_Flags.
11126         (Analyze_Abstract_State): Add new global variable State_Id. Remove
11127         local constants Errors and Loc. Remove local variables Is_Null
11128         and State_Nam. Create the entity of the abstract state on the
11129         spot, before all remaining checks are performed. Verify that a
11130         missing Part_Of option agrees with the placement of the abstract
11131         state within the state space.
11132         (Analyze_Depends_In_Decl_Part):
11133         Add new global variables Constits_Seen and States_Seen. Check
11134         that a state and a corresponding constituent do not appear
11135         in pragma [Refined_]Depends.
11136         (Analyze_Global_In_Decl_Part):
11137         Add new global variables Constits_Seen and States_Seen. Check
11138         that a state and a corresponding constituent do not appear
11139         in pragma [Refined_]Global.
11140         (Analyze_Global_Item):
11141         Remove the now obsolete code that deals with Part_Of.
11142         Add the entity of the global item to the list of processed
11143         items.  (Analyze_Initializes_In_Decl_Part): Add new global
11144         variables Constits_Seen and States_Seen. Check that a state
11145         and a corresponding constituent do not appear in pragma
11146         Initializes.
11147         (Analyze_Initialization_Item): Add the entity
11148         of the initialization item to the list of processed items.
11149         (Analyze_Input_Item): Add the entity of the initialization
11150         item to the list of processed items.
11151         (Analyze_Input_Output):
11152         Remove the now obsolete code that deals with Part_Of.  Add the
11153         entity of the input/output to the list of processed items.
11154         (Analyze_Part_Of): New routine.
11155         (Analyze_Part_Of_Option): Remove
11156         local constant Par_State. Add local constant Encaps and local
11157         variables Encaps_Id and Legal. Use Analyze_Part of to analyze
11158         the option. Turn the related state into a Part_Of constituent
11159         if the option is legal.
11160         (Analyze_Pragma): Add processing
11161         for pragma Part_Of.
11162         (Analyze_Refined_State_In_Decl_Part):
11163         Remove global constants Pack_Body and Spec_Id. Remove
11164         global variables Abstr_States and Hidden_States. Add new
11165         global variables Available_States, Body_Id, Body_States and
11166         Spec_Id. Add new local constant Body_Decl. Reimplement the
11167         logic that extracts the states available for refinement from
11168         the related package and the body hidden states of the said
11169         package.
11170         (Analyze_Refinement_Clause): Add local variable Part_Of_Constits.
11171         (Check_Applicable_Policy): Alphabetize body.
11172         (Check_Dependency_Clause): Replace Refined_State
11173         with Encapsulating_State.
11174         (Check_Matching_Constituent):
11175         Reimplement the logic that determines whether an item is a valid
11176         / invalid constituent of the current refined state. Return when
11177         a construct does not denote a valid abstract state. Extract the
11178         list of Part_Of constituents for further analysis. Check that all
11179         Part_Of constituents of a state have been used in its refinement.
11180         (Check_Matching_State): Update the comment on usage. Operate
11181         on the list of available states.
11182         (Check_Missing_Part_Of): New routine.
11183         (Check_Refined_Global_Item): Replace Refined_State
11184         with Encapsulating_State.
11185         (Check_State_And_Constituent_Use): New routine.
11186         (Create_Abstract_State): New routine.
11187         (Is_Matching_Input): Replace Refined_State with Encapsulating_State.
11188         (Is_Part_Of): Removed.
11189         (Collect_Body_States): New routine.
11190         (Collect_Constituent): Replace Refined_State with Encapsulating_State.
11191         (Collect_Hidden_States): Removed.
11192         (Report_Unrefined_States): Change the profile of the procedure along
11193         with the comment on usage.
11194         (Report_Unused_Constituents): New routine.
11195         (Report_Unused_Hidden_States): Removed.
11196         (Report_Unused_States): New routine.
11197         * sem_prag.ads (Check_Missing_Part_Of): New routine.
11198         * sem_util.adb (Add_Contract_Item): Pragma Part_Of can now
11199         appear in the classification pragmas of a package instantiation
11200         or a variable.
11201         (Find_Placement_In_State_Space): New routine.
11202         (Is_Child): Removed.
11203         (Is_Child_Or_Sibling): Remove formal
11204         parameter Private_Child. Remove the private child checks.
11205         (Requires_State_Refinement): Moved from sem_ch3.
11206         * sem_util.ads Add new type State_Space_Kind along with
11207         comment on its usage and values.
11208         (Add_Contract_Item): Update the comment on usage.
11209         (Find_Body_Discriminal): Alphabetize spec.
11210         (Find_Placement_In_State_Space): New routine.
11211         (Is_Child_Or_Sibling): Remove formal parameter Private_Child
11212         and update the comment on usage.
11213         (Requires_State_Refinement): Moved from sem_ch3.
11214         * sinfo.ads: Update the documentation of N_Contract.
11215         * snames.ads-tmpl The predefined name for Part_Of is now used
11216         to denote a pragma. Add Pragma_Id for Part_Of.
11218 2014-01-29  Emmanuel Briot  <briot@adacore.com>
11220         * s-regexp.adb (Create_Secondary_Table): Automatically grow the state
11221         machine as needed.
11222         (Dump): New subprogram.
11224 2014-01-29  Tristan Gingold  <gingold@adacore.com>
11226         * exp_ch9.adb (Expand_N_Protected_Type_Declaration): Add
11227         Expand_Entry_Declaration to factorize code.
11229 2014-01-29  Ed Schonberg  <schonberg@adacore.com>
11231         * checks.adb: minor clarification.
11232         * sem_ch7.adb (Declare_Inherited_Private_Subprograms): Limit
11233         search for primitive operations to the entities that immediately
11234         follow the type declaration.
11236 2014-01-29  Tristan Gingold  <gingold@adacore.com>
11238         * exp_ch9.adb (Build_Protected_Entry): Do not call
11239         Complete_Entry_Body anymore.
11240         * rtsfind.ads (RE_Complete_Single_Entry_Body): Remove.
11241         * s-tposen.ads, s-tposen.adb (Complete_Single_Entry_Body): Remove.
11243 2014-01-29  Pierre-Marie Derodat  <derodat@adacore.com>
11245         * s-os_lib.adb, s-os_lib.ads (Normalize_Pathname): Return an empty
11246         string when the Name input bigger than allowed. Adapt the function
11247         specification.
11249 2014-01-29  Ed Schonberg  <schonberg@adacore.com>
11251         * checks.adb (Install_Null_Excluding_Check): Do not emit warning
11252         if expression is within a case_expression of if_expression.
11254 2014-01-29  Robert Dewar  <dewar@adacore.com>
11256         * exp_ch9.adb, inline.ads: Minor reformatting.
11258 2014-01-29  Tristan Gingold  <gingold@adacore.com>
11260         * exp_ch9.adb (Is_Exception_Safe): Return true if no exceptions.
11262 2014-01-29  Yannick Moy  <moy@adacore.com>
11264         * inline.ads (Pending_Body_Info): Add SPARK_Mode and
11265         SPARK_Mode_Pragma components to be able to analyze generic
11266         instance.
11267         * sem_ch12.adb (Analyze_Package_Instantiation,
11268         Inline_Instance_Body, Need_Subprogram_Instance_Body,
11269         Load_Parent_Of_Generic): Pass in SPARK_Mode from instantiation
11270         for future analysis of the instance.
11271         (Instantiate_Package_Body,
11272         Instantiate_Subprogram_Body, Set_Instance_Inv): Set SPARK_Mode
11273         from instantiation to analyze the instance.
11275 2014-01-29  Robert Dewar  <dewar@adacore.com>
11277         * sem_ch7.adb, sem_prag.adb, sem_ch4.adb, sem_ch6.adb: Minor code
11278         reorganization.
11280 2014-01-29  Yannick Moy  <moy@adacore.com>
11282         * gnat_rm.texi: Update description of SPARK_Mode pragma.
11284 2014-01-29  Tristan Gingold  <gingold@adacore.com>
11286         * exp_ch9.adb (Expand_N_Protected_Body): Remove Num_Entries.
11288 2014-01-29  Thomas Quinot  <quinot@adacore.com>
11290         * sem_ch4.adb (Find_Component_In_Instance): Update comment.
11292 2014-01-29  Ed Schonberg  <schonberg@adacore.com>
11294         * exp_util.adb (Build_Task_Image_Prefix): Indicate that the
11295         resulting string is an internal entity. and thus requires no
11296         initialization. This is relevant when Initialize_ Scalars is
11297         enabled, because the resultant spurious initialization may lead to
11298         secondary stack anomalies that produce a mangled name for a task.
11300 2014-01-29  Yannick Moy  <moy@adacore.com>
11302         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): SPARK_Mode
11303         not inherited from spec anymore. Check consistency
11304         rules after processing of declarations.
11305         * sem_ch7.adb (Analyze_Package_Body_Helper): SPARK_Mode not inherited
11306         from spec anymore. Check consistency rules after processing of
11307         declarations.
11308         (Analyze_Package_Declaration): Set SPARK_Mode only for non-generic
11309         packages.
11310         * sem_prag.adb (Analyze_Pragma/Pragma_SPARK_Mode): Implement new
11311         consistency rules.
11313 2014-01-27  Robert Dewar  <dewar@adacore.com>
11315         * sem_res.adb (Resolve_Comparison_Op): Add type name/location
11316         to unordered msg.
11317         (Resolve_Range): Add type name/location to unordered msg.
11319 2014-01-27  Claire Dross  <dross@adacore.com>
11321         * a-cofove.adb/s (Copy): Add precondition so that Copy (Source,
11322         Capacity) is only called with Capacity >= Length (Source) and
11323         Capacity in Capacity_Range.
11324         * a-cfdlli.adb/s, a-cfhase.adb/s, a-cfhama.adb/s, a-cforse.adb/s,
11325         a-cforma.adb/s (Copy): Add precondition so that Copy (Source, Capacity)
11326         is only called with Capacity >= Source.Capacity. Raise Capacity_Error
11327         in the code is this is not the case.
11329 2014-01-27  Thomas Quinot  <quinot@adacore.com>
11331         * sem_ch4.adb (Analyze_Selected_Component): Fix handling of
11332         selected component in an instance where the component of the
11333         actual is not visibile at instantiation.
11335 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
11337         * sem_ch6.adb: sem_ch6.adb (Set_Actual_Subtypes): If the type
11338         has a dynamic predicate, generate freeze node for Actual_Subtype
11339         at once, because the declaration of the corresponding predicate
11340         function will make reference to it.
11342 2014-01-27  Tristan Gingold  <gingold@adacore.com>
11344         * exp_ch7.adb, exp_ch9.adb: Adjust comments.
11346 2014-01-27  Robert Dewar  <dewar@adacore.com>
11348         * exp_ch4.adb (Expand_N_Op_Expon): Remove unsigned type test
11349         for 2**X optimization.
11351 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
11353         * a-suenst.adb: strings.utf_encoding.strings (Decode): Check
11354         explicitly whether value is in range of Character, because the
11355         library is typically compiled with range checks disabled, and
11356         we cannot rely on the implicit check on the argument of 'Val.
11358 2014-01-27  Vincent Celier  <celier@adacore.com>
11360         * a-ciorma.adb, a-cihama.adb (Assign): Copy the Source to the Target,
11361         not the Target to itself.
11363 2014-01-27  Robert Dewar  <dewar@adacore.com>
11365         * vms_conv.ads, ali.adb, sem_ch6.ads, opt.ads, vms_cmds.ads: Minor
11366         changes to avoid incorrect use of unordered enum types.
11368 2014-01-27  Thomas Quinot  <quinot@adacore.com>
11370         * sem_ch4.adb: Minor reformatting.
11372 2014-01-27  Robert Dewar  <dewar@adacore.com>
11374         * scn.adb (Check_End_Of_Line): Removed.
11375         (Error_Long_Line): Removed.
11376         (Determine_License): Use versions of above routines from Scanner.
11377         * scng.adb (Check_End_Of_Line): Moved to spec.
11378         (Error_Long_Line): Removed, no longer used.
11379         * scng.ads (Check_End_Of_Line): Moved here from body.
11381 2014-01-27  Tristan Gingold  <gingold@adacore.com>
11383         * exp_ch7.adb (Build_Cleanup_Statements): Call
11384         Build_Protected_Subprogram_Call_Cleanup to insert the cleanup
11385         for protected body.
11386         * exp_ch9.adb (Build_Protected_Subprogram_Body): Likewise.
11387          Remove Service_Name variable.
11388         (Build_Protected_SUbprogam_Call_Cleanup): New procedure that
11389         factorize code from the above subprograms.
11390         * exp_ch9.ads (Build_Protected_Subprogram_Call_Cleanup): New procedure.
11392 2014-01-27  Hristian Kirtchev  <kirtchev@adacore.com>
11394         * einfo.adb (Has_Option): Reimplemented.
11395         * sem_prag.adb (Analyze_Refinement_Clause): Add global
11396         variables AR_Constit, AW_Constit, ER_Constit, EW_Constit,
11397         External_Constit_Seen and State. Add local variables Body_Ref,
11398         Body_Ref_Elmt and Extra_State. Reimplement part of the logic to
11399         avoid a cumbersome while pool. Verify the legality of an external
11400         state and relevant properties.
11401         (Check_External_Property): New routine.
11402         (Check_Matching_State): Remove parameter profile
11403         and update comment on usage.
11404         (Collect_Constituent): Store the
11405         relevant external property of a constituent.
11406         * sem_util.adb (Async_Readers_Enabled): Update the call to
11407         Has_Enabled_Property.
11408         (Async_Writers_Enabled): Update the call to Has_Enabled_Property.
11409         (Effective_Reads_Enabled): Update the call to Has_Enabled_Property.
11410         (Effective_Writes_Enabled): Update the call to Has_Enabled_Property.
11411         (Has_Enabled_Property): Rename formal parameter Extern to State_Id.
11412         Update comment on usage. Reimplement the logic to recognize the various
11413         formats of properties.
11415 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
11417         * par-ch5.adb: Minor reformatting.
11419 2014-01-27  Tristan Gingold  <gingold@adacore.com>
11421         * s-tposen.ads: Harmonize style and comments.
11423 2014-01-27  Vincent Celier  <celier@adacore.com>
11425         * projects.texi: Document that shared library projects, by
11426         default, cannot import projects that are not shared library
11427         projects.
11429 2014-01-27  Robert Dewar  <dewar@adacore.com>
11431         * sem_ch8.adb (Find_Selected_Component): Use Replace instead
11432         of Rewrite.
11434 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
11436         * a-suenco.adb, a-suenst.adb (Decode): Raise encoding error if
11437         any other exception is raised.
11438         (Convert): If both Input_Scheme and Output_Scheme are UTF_8 it is
11439         still necessary to perform a conversion in order to remove overlong
11440         encodings.
11442 2014-01-27  Robert Dewar  <dewar@adacore.com>
11444         * exp_smem.adb: Minor reformatting.
11446 2014-01-27  Thomas Quinot  <quinot@adacore.com>
11448         * a-calfor.ads: Fix incorrect reference to operator "-" in comment.
11450 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
11452         * sem_res.adb (Make_Call_Into_Operator): In ASIS mode, relocate
11453         nodes for operands to the original node for the call, to preserve
11454         Original_Node pointers within the resolved operands, given that
11455         they may have been rewritten as well. Previous approach copied
11456         the operands into a new tree and lost those pointers.
11458 2014-01-27  Claire Dross  <dross@adacore.com>
11461         * a-cofove.adb, a-cofove.ads: Add Strict_Equal function to the API.
11463 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
11465         * sem_util.adb (Check_Internal_Protected_Use): A call through
11466         an anonymous access parameter of the current protected function
11467         is not a potential modification of the current object.
11469 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
11471         * a-cobove.adb (Reserve_Capacity): Procedure raises
11472         Capacity_Error, not Constraint_Error, when request cannot be
11473         satisfied.
11475 2014-01-27  Vincent Celier  <celier@adacore.com>
11477         * a-coorma.adb, a-cohama.adb (Assign): Copy the Source to the Target,
11478         not the Target to itself.
11480 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
11482         * exp_ch4.adb (Expand_Concatenate): If the target of the
11483         concatenation is a library-level entity, always use the off-line
11484         version of concatenation, regardless of optimization level. This
11485         is space-efficient, and prevents linking problems when some
11486         units are compiled with different optimization levels.
11488 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
11490         * sem_ch5.adb: Code clean up.
11492 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
11494         * par-ch5.adb (P_Iterator_Specification): Improve error recovery
11495         when an array or container iterator includes a subtype indication,
11496         which is only legal in an element iterator.
11498 2014-01-27  Thomas Quinot  <quinot@adacore.com>
11500         * exp_ch7.adb: Minor reformatting.
11502 2014-01-27  Robert Dewar  <dewar@adacore.com>
11504         * opt.adb (SPARK_Mode): Default for library units is None rather
11505         than Off.
11506         * opt.ads: Remove AUTO from SPARK_Mode_Type SPARK_Mode_Type is
11507         no longer ordered.
11508         * sem_prag.adb (Analyze_Pragma, case SPARK_Mode): Remove AUTO
11509         possibility.
11510         * snames.ads-tmpl (Name_Auto): Removed, no longer used.
11512 2014-01-27  Robert Dewar  <dewar@adacore.com>
11514         * par-ch5.adb (P_Sequence_Of_Statements): Make entry in
11515         Suspicious_Labels table if we have identifier; followed by loop
11516         or block.
11517         * par-endh.adb (Evaluate_End_Entry): Search Suspicious_Labels table.
11518         * par.adb (Suspicious_Labels): New table.
11520 2014-01-27  Robert Dewar  <dewar@adacore.com>
11522         * exp_aggr.adb (Check_Bounds): Reason is range check, not
11523         length check.
11525 2014-01-27  Yannick Moy  <moy@adacore.com>
11527         * get_spark_xrefs.adb (Get_SPARK_Xrefs): Accept new type 'c' for
11528         reference.
11529         * lib-xref-spark_specific.adb (Is_Global_Constant): Remove useless
11530         function now.
11531         (Add_SPARK_Xrefs): Include references to constants.
11532         * spark_xrefs.ads Document new character 'c' for references to
11533         constants.
11535 2014-01-27  Thomas Quinot  <quinot@adacore.com>
11537         * exp_smem.adb (Add_Write_After): For a function call, insert write as
11538         an after action in a transient scope.
11540 2014-01-27  Thomas Quinot  <quinot@adacore.com>
11542         * exp_smem.adb (Expand_Shared_Passive_Variable): For a reference
11543         to a shared variable as an OUT formal in a call to an init proc,
11544         the 'Read call must be emitted after, not before, the call.
11546 2014-01-27  Robert Dewar  <dewar@adacore.com>
11548         * gnat_rm.texi: Remove mention of AUTO mode for SPARK_Mode pragma.
11550 2014-01-27  Robert Dewar  <dewar@adacore.com>
11552         * a-wichha.adb (Character_Set_Version): Change to output proper
11553         value.
11555 2014-01-27  Hristian Kirtchev  <kirtchev@adacore.com>
11557         * einfo.adb (Is_Input_Only_State): Removed.
11558         (Is_Non_Volatile_State): Removed.
11559         (Is_Output_State): Removed.
11560         * einfo.ads (Is_Input_Only_State): Remove attribute and
11561         subprogram. Update related entity.
11562         (Is_Non_Volatile_State):
11563         Remove attribute and subprogram. Update related entity.
11564         (Is_Output_State): Removed attribute and subprogram. Update
11565         related entity.
11566         * exp_ch6.adb (Expand_Subprogram_Contract): Update comment on
11567         generated code.
11568         * sem_ch3.adb (Analyze_Declarations): Analyze the contract of
11569         an object, not just variables.
11570         (Analyze_Object_Contract): New routine.
11571         (Analyze_Variable_Contract): Removed.
11572         (Process_Discriminants): Detect an illegal use of volatile
11573         discriminant in SPARK mode.
11574         * sem_ch5.adb (Analyze_Iterator_Specification):
11575         Detect an illegal use of volatile loop variable.
11576         (Analyze_Loop_Parameter_Specification): Detect an illegal use
11577         of volatile loop variable.
11578         * sem_ch6.adb (Process_Formals): Update the volatile object
11579         detection. Detect an illegal formal of mode IN OUT or OUT in
11580         SPARK mode. Enhance the error messages with references.
11581         * sem_ch12.adb (Instantiate_Object): Update the volatile object
11582         detection. Enhance the error messages with references.
11583         * sem_prag.adb (Analyze_Abstract_State): Enhance the error
11584         messages with references.
11585         (Analyze_Contract_Case): Enhance the error messages with references.
11586         (Analyze_External_Property): Call Check_Duplicate_Property to process
11587         an external property.
11588         (Analyze_External_Property_In_Decl_Part): New routine.
11589         (Analyze_External_State_In_Decl_Part): Removed.
11590         (Analyze_Global_Item): Detect an illegal
11591         use of a volatile constant. Detect an illegal use
11592         of a variable with enabled Effective_Reads. Enhance
11593         the error messages with references. Remove obsolete
11594         checks concerning Input_Only and Output_Only states.
11595         (Analyze_Initialization_Item): Enhance the error messages
11596         with references.
11597         (Analyze_Initializes_In_Decl_Part): Do not
11598         collect the states and variables when the initialization list
11599         is null.
11600         (Analyze_Input_Item): Enhance the error messages with references.
11601         (Analyze_Input_Output): Enhance the error messages with references.
11602         (Analyze_Pragma): Enhance the error messages with references.
11603         (Analyze_Refinement_Clause): Code reformatting.
11604         (Analyze_Refined_Depends_In_Decl_Part):
11605         Rename global variable Global to Reg_Global and update all
11606         occurrences. Add local variables D7 and D8. Update the error
11607         messages with references. Update the call to Collect_Global_Items.
11608         (Analyze_Refined_Global_In_Decl_Part): Add local variables
11609         Has_Proof_In_State, Proof_In_Constits and Proof_In_Items. Update
11610         the call to Collect_Global_Items.  Account for a Proof_In state
11611         in null / useless refinement checks. Verify the coverage of
11612         Proof_In states.
11613         (Check_Dependency_Clause): Remove local variable
11614         Out_Constits. Remove the retrieval and removal of constituents
11615         for an Output_Only state. Remove the reporting of unused
11616         Output_Only state constituents.
11617         (Check_Duplicate_Mode): Enhance
11618         the error message with a reference.
11619         (Check_Duplicate_Property): New routine.
11620         (Check_Duplicate_Option): Enhance the error message with a reference.
11621         (Check_External_Properties): Enhance the error message with a reference.
11622         (Check_Function_Return): Enhance the error message with a reference.
11623         (Check_In_Out_States): Update
11624         comment on usage. Add a specialized error message for Proof_In
11625         constituents. Enhance the error message with a reference.
11626         (Check_Input_States): Update comment on usage. Account for
11627         possible Proof_In constituents. Enhance the error message
11628         with a areference.
11629         (Check_Matching_Constituent): Enhance the error message with a
11630         reference.
11631         (Check_Matching_State): Enchance the error message with a reference.
11632         (Check_Mode): Add local variable From_Global. Update the call to
11633         Find_Mode.  Emit more precise error messages concerning extra items
11634         (Check_Mode_Restriction_In_Enclosing_Context): Consider
11635         pragma Refined_Global.  Enhance the error message with a
11636         reference.
11637         (Check_Mode_Restriction_In_Function): Enhance the error message with
11638         a reference.
11639         (Check_Output_States): Update comment on usage. Add local variable
11640         Posted.  Account for possible Proof_In constituents. Produce a detailed
11641         list of missing constituents.
11642         (Check_Proof_In_States): New routine.
11643         (Check_Refined_Global_Item): Handle Proof_In
11644         constituents. Enchance the error message with a reference.
11645         (Collect_Global_Items): Add formal parameters Proof_In_Items
11646         and Has_Proof_In_State. Update the comment on usage. Account
11647         for Proof_In items.
11648         (Create_Or_Modify_Clause): Enchance
11649         the error message with a reference.
11650         (Find_Mode): Add
11651         formal parameter From_Global. Update the comment on usage.
11652         Detect when the mode is governed by pragma [Refined_]Global.
11653         (Output_Constituents): Removed.
11654         (Report_Extra_Constituents):
11655         Report extra Proof_In constituents.
11656         (Report_Unused_Constituents): Removed.
11657         (Usage_Error): Code reformatting. Enhance the error
11658         messages with reference.
11659         * sem_prag.ads (Analyze_External_Property_In_Decl_Part): New routine.
11660         (Analyze_External_State_In_Decl_Part): Removed.
11661         * sem_res.adb (Resolve_Actuals): Update the volatile object
11662         detection. Enhance the error message with a reference.
11663         (Resolve_Entity_Name): Update the volatile object
11664         detection. Enhance the error message with a reference.
11665         * sem_util.adb (Is_Refined_State): Add a guard to avoid a crash.
11666         (Is_SPARK_Volatile_Object): New routine.
11667         (Has_Volatile_Component): New routine.
11668         * sem_util.ads (Is_Delegate): Alphabetized.
11669         (Is_SPARK_Volatile_Object): New routine.
11670         (Has_Volatile_Component): New routine.
11671         * snames.ads-tmpl: Remove names Name_Input_Only and Name_Output_Only.
11673 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
11675         * sem_attr.adb: Resolve fully prefix of 'Update.
11677 2014-01-27  Ben Brosgol  <brosgol@adacore.com>
11679         * gnat_rm.texi: Minor clarifications.
11681 2014-01-27  Robert Dewar  <dewar@adacore.com>
11683         * sem_elab.adb (Check_Internal_Call_Continue): Avoid complaining
11684         about call that is generated as part of an Initial_Condition
11685         check.
11686         * sem_prag.adb: Minor spelling correction.
11688 2014-01-27  Robert Dewar  <dewar@adacore.com>
11690         * sem_prag.adb (Set_Convention_From_Pragma): Check that
11691         convention Ghost can only apply to functions.
11692         * einfo.ads, einfo.adb (Is_Ghost_Subprogram): Add clarifying comment.
11694 2014-01-27  Robert Dewar  <dewar@adacore.com>
11696         * gnat_ugn.texi: Add Short_Enums to documentation of
11697         -gnatet/-gnateT.
11699 2014-01-27  Robert Dewar  <dewar@adacore.com>
11701         * sem_prag.adb (Analyze_Input_Item): Correct check for input
11702         item in same package.
11703         * sem_util.ads, sem_util.adb (Within_Scope): New function.
11705 2014-01-26  Arnaud Charlet  <charlet@adacore.com>
11707         * a-intnam-lynxos.ads, mlib-tgt-specific-lynxos.adb,
11708         s-osinte-lynxos-3.adb, s-osinte-lynxos-3.ads, s-osinte-lynxos.adb,
11709         s-osinte-lynxos.ads, s-taprop-lynxos.adb, s-tpopsp-lynxos.adb,
11710         system-lynxos-ppc.ads, system-lynxos-x86.ads: Removed, no longer
11711         maintained.
11713 2014-01-25  Eric Botcazou  <ebotcazou@adacore.com>
11715         * gcc-interface/Makefile.in: Fix oversight.
11717 2014-01-25  Eric Botcazou  <ebotcazou@adacore.com>
11719         * gcc-interface/utils.c (convert_to_fat_pointer): Un-obfuscate the
11720         conversion from a thin pointer with a shifted value.
11721         * gcc-interface/utils2.c (gnat_build_constructor): Propagate the
11722         read-only flag from the values onto the result.
11723         (gnat_invariant_expr): Accept read-only CONSTRUCTORs.
11725 2014-01-25  Tristan Gingold  <gingold@adacore.com>
11727         * gcc-interface/decl.c (gnat_to_gnu_entity): Always build a variable
11728         for E_Variable with a pragma Linker_Section.
11730 2014-01-25  Robert Dewar  <dewar@adacore.com>
11732         * gcc-interface/decl.c (gnat_to_gnu_param): Make sure an Out parameter
11733         with Default_Value aspect is passed in by copy.
11735 2014-01-24  Eric Botcazou  <ebotcazou@adacore.com>
11737         * set_targ.adb: Set Short_Enums.
11738         * gcc-interface/lang.opt (fshort-enums): New option.
11739         * gcc-interface/misc.c (gnat_handle_option): Handle it.
11740         (gnat_post_options): Do not modify the global settings.
11742 2014-01-24  Robert Dewar  <dewar@adacore.com>
11744         * g-rannum.ads, g-rannum.adb (Random_Ordinary_Fixed): New generic
11745         function.
11746         (Random_Decimal_Fixed): New generic function.
11747         * s-rannum.ads: Minor comment clarifications.
11749 2014-01-24  Robert Dewar  <dewar@adacore.com>
11751         * back_end.adb: Remove Short_Enums handling (handled in
11752         Ttypes/Get_Targ now) Minor added comments.
11753         * freeze.adb: Change name Short_Enums_On_Target to
11754         Target_Short_Enums.
11755         * get_targ.ads, get_targ.adb (Get_Short_Enums): New function.
11756         * opt.ads: Minor comment updates.
11757         * sem_ch13.adb: Change name Short_Enums_On_Target to
11758         Target_Short_Enums.
11759         * set_targ.adb: Set Short_Enums from gcc back end.
11760         * set_targ.ads (Short_Enums): New variable.
11761         * targparm.ads, targparm.adb: Remove Short_Enums entries (handled in
11762         Ttypes/Get_Targ now).
11763         * ttypes.ads (Target_Short_Enums): New constant boolean switch
11765 2014-01-24  Pascal Obry  <obry@adacore.com>
11767         * g-sercom-mingw.adb: Fix serial port name for port number > 10.
11769 2014-01-24  Gary Dismukes  <dismukes@adacore.com>
11771         * exp_disp.adb (Expand_Dispatching_Call): Call Unqualify on Param when
11772         comparing it with Ctrl_Arg, since Ctrl_Arg may have had qualification
11773         stripped off.
11775 2014-01-24  Robert Dewar  <dewar@adacore.com>
11777         * sinfo.ads, make.adb, prj-env.adb: Minor reformatting.
11779 2014-01-24  Vincent Celier  <celier@adacore.com>
11781         * prj.adb (Add_Aggregated_Project): Do not add a project in
11782         the list if it is already there.
11784 2014-01-24  Yannick Moy  <moy@adacore.com>
11786         * lib-xref-spark_specific.adb (Enclosing_Subprogram_Or_Package):
11787         Correct the search for a subrogram declaration to which a pragma is
11788         attached.
11790 2014-01-24  Bob Duff  <duff@adacore.com>
11792         * gnat_ugn.texi: Document --decimal-grouping and
11793         --based-grouping switches in gnatpp.
11795 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
11797         * sinfo.ads: Documentation update.
11799 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
11801         * sem_ch3.adb (Constant_Redeclaration): New declaration is
11802         illegal if previous one has an initial expression that is an
11803         aggregate expanded into assignments.
11805 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
11807         * sem_ch5.adb (Analyze_Loop_Parameter_Specification): Small
11808         code reorganization to remove spurious warning on a loop with
11809         an array element iterator that has a null range.
11811 2014-01-24  Vincent Celier  <celier@adacore.com>
11813         * make.adb (Binding_Phase): When setting the Ada paths, use
11814         the library ALI dir, not the object dir in libraries.
11816 2014-01-24  Yannick Moy  <moy@adacore.com>
11818         * sinfo.ads: Add documentation of check flag fields.
11820 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
11822         * sem_res.adb (Resolve_Actuals): If an actual is a view
11823         conversion of a discriminated object, and the formal type is
11824         discriminated and constrained, apply a discriminant check to
11825         the object itself.
11827 2014-01-24  Robert Dewar  <dewar@adacore.com>
11829         * prj.adb, prj-env.adb, back_end.adb: Add comment, minor code clean ups.
11831 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
11833         * sem_ch3.adb (Analyze_Declarations): At the end of an
11834         appropriate declarative part, call Freeze_All from the first
11835         declaration in the scope, not from the first unfrozen one. This
11836         is necessary to apply visibility checks to entities with delayed
11837         aspects. Otherwise, in the presence of instantiations and cleanups
11838         that they may generate, the delayed aspects may be analyzed too
11839         late and produce spurious visibility errors.
11840         * sem_attr.adb: Place etype on range.
11841         * sem_ch6.adb: Documentation expression functions.
11843 2014-01-24  Robert Dewar  <dewar@adacore.com>
11845         * exp_ch7.adb: Minor change of Indices to Indexes (preferred
11846         terminology in compiler).
11848 2014-01-24  Robert Dewar  <dewar@adacore.com>
11850         * scans.ads: Remove Tok_Raise from Sterm, Eterm, After_SM
11851         categories, now that Ada 95 supports raise expressions.
11853 2014-01-24  Robert Dewar  <dewar@adacore.com>
11855         * freeze.adb (Freeze_Enumeration_Type): Use new target parameter
11856         Short_Enums_On_Target.
11857         * sem_ch13.adb (Set_Enum_Esize): Take Short_Enums_On_Target
11858         into account.
11859         * targparm.ads, targparm.adb: Add new target parameter Short_Enums.
11861 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
11863         * sem_ch5.adb (Analyze_Iterator_Specification): If subtype
11864         indication is given explicity, check that it matches the array
11865         component type or the container element type of the domain
11866         of iteration.
11868 2014-01-24  Tristan Gingold  <gingold@adacore.com>
11870         * back_end.adb (Scan_Compiler_Arguments): Set Short_Enums_On_Target.
11871         * gcc-interface/misc.c (flag_short_enums): Declare.
11872         (gnat_post_options): Set it.
11874 2014-01-24  Vincent Celier  <celier@adacore.com>
11876         * prj-env.adb (Ada_Objects_Path): Use Ada_Objects_Path_No_Libs
11877         to cache the result when Including_Libraries is False.
11878         * prj-env.ads (Ada_Objects_Path): Update documentation
11879         * prj.adb (Free (Project_Id)): Also free Ada_Objects_Path_No_Libs
11880         (Get_Object_Directory): Return the Library_Ali_Dir only when
11881         when Including_Libraries is True.
11882         * prj.ads (Get_Object_Directory): Fix and complete documentation
11883         (Project_Data): New component Ada_Objects_Path_No_Libs
11885 2014-01-24  Robert Dewar  <dewar@adacore.com>
11887         * checks.adb (Expr_Known_Valid): Result of fpt operator never
11888         considered valid.
11890 2014-01-24  Eric Botcazou  <ebotcazou@adacore.com>
11892         * back_end.adb: Minor fix in comment.
11894 2014-01-24  Javier Miranda  <miranda@adacore.com>
11896         * sem_ch3.adb (Check_Abstract_Overriding): Code reestructuration
11897         required to report the error in case of task types.
11899 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
11901         * sem_attr.adb: Additional index checking.
11903 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
11905         * sem_attr.adb (Analyze_Attribute, case 'Update): Analyze
11906         expressions in each component association, and for records note
11907         the entity in each association choice, for subsequent resolution.
11908         (Resolve_Attribute, case 'Update): Complete resolution of
11909         expressions in each component association.
11911 2014-01-24  Robert Dewar  <dewar@adacore.com>
11913         * sem.adb (Sem): Avoid premature reference to Current_Sem_Unit
11914         (this was causing Is_Main_Unit_Or_Main_Unit_Spec to be set wrong,
11915         leading to wrong handling of SPARK_Mode for library units).
11917 2014-01-24  Robert Dewar  <dewar@adacore.com>
11919         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Set SPARK_Mode
11920         on generic instances (do not consider them to be internally
11921         generated)
11923 2014-01-24  Doug Rupp  <rupp@adacore.com>
11925         * s-osinte-android.ads (pthread_sigmask): Import sigprocmask
11926         vice pthread_sigmask.
11928 2014-01-24  Vincent Celier  <celier@adacore.com>
11930         * prj.adb (Debug_Output (Str, Str2)): Output if verbosity is
11931         not default.
11933 2014-01-24  Vincent Celier  <celier@adacore.com>
11935         * prj-ext.adb (Add): Do not output anything when Silent is True,
11936         whatever the verbosity. When Source is From_External_Attribute,
11937         set the corresponding environment variable if it is not already set.
11938         * prj-ext.ads (Add): New Boolean parameter Silent, defaulted
11939         to False
11940         * prj-proc.adb (Process_Expression_For_Associative_Array):
11941         For attribute External, call Prj.Ext.Add with Silent set to
11942         True for the child environment, to avoid useless output in non
11943         default verbosity.
11945 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
11947         * sem_res.adb (Set_Slice_Subtype): Handle properly a discrete
11948         range given by a subtype indication, and force evaluation of
11949         the bounds, as for a simple range.
11950         * exp_util.adb (Evaluate_Slice_Bounds): Utility to force evaluation
11951         of bounds of slice for various kinds of discrete ranges.
11952         (Evaluate_Name, Evaluate_Subtype_From_Expr): use
11953         Evaluate_Slice_Bounds.
11955 2014-01-24  Bob Duff  <duff@adacore.com>
11957         * s-taskin.ads (Activator): Make this Atomic, because
11958         Activation_Is_Complete reads it, and that can be called
11959         from any task. Previously, this component was only
11960         modified by the activator before activation, and by
11961         Self after activation.
11962         * a-taside.ads, a-taside.adb (Environment_Task,
11963         Activation_Is_Complete): Implement these missing functions.
11965 2014-01-24  Doug Rupp  <rupp@adacore.com>
11967         * init.c: Add a handler section for Android.
11969 2014-01-24  Arnaud Charlet  <charlet@adacore.com>
11971         * i-cexten.ads (Unsigned_33..64, Unsigned_33..64): New types.
11973 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
11975         * sem_ch4.adb (Operator_Check): If one operand is a
11976         Raise_Expression, set its type to that of the other operand.
11977         * sem_res.adb (Resolve_Raise_Expression): new procedure.
11978         (Resolve_Actuals): For an actual that is a Raise_Expression,
11979         set the type to that of the formal.
11980         * sem_type.adb (Find_Unique_Type): If one of the operands is a
11981         Raise_Expression, return type of the other operand.
11983 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
11985         * sem_aggr.adb (Resolve_Record_Aggregate): If a scalar
11986         component of the record has a type with a default aspect, and
11987         the corresponding aggregate component is initiaized with a box,
11988         use the default value in the rewritten aggregate.
11990 2014-01-24  Tristan Gingold  <gingold@adacore.com>
11992         * s-interr.ads, s-interr.adb, s-interr-hwint.adb, s-interr-vms.adb,
11993         s-interr-sigaction.adb,
11994         s-interr-dummy.adb (Install_Restricted_Handlers): Add Prio parameter.
11995         * exp_ch9.adb (Make_Initialize_Protection): Add Prio parameter
11996         to the call to Install_Restricted_Handlers.
11998 2014-01-24  Emmanuel Briot  <briot@adacore.com>
12000         * prj-nmsc.adb (Check_File): Add protection when the source is
12001         not fully initialized.
12003 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
12005         * sem_util.adb (Is_Post_State): In a postcondition, a selected
12006         component that denotes an implicit dereference is a reference
12007         to the post state of the subprogram.
12009 2014-01-24  Robert Dewar  <dewar@adacore.com>
12011         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): SPARK_Mode OFF
12012         for generated subprograms.
12013         (Analyze_Subprogram_Specification): Ditto.
12015 2014-01-24  Vincent Celier  <celier@adacore.com>
12017         * prj-dect.adb (Check_Attribute_Allowed): Detect more forbidden
12018         attributes in package Builder of aggregate and aggregate library
12019         projects.
12020         * prj-nmsc.adb (Process_Naming_Scheme.Check.Check_Aggregate):
12021         Remove procedure (Process_Naming_Scheme.Check.Check_Aggregated):
12022         Remove parameters.  Change error message from "... externally
12023         build library ..." to "... externally built project ...".
12024         (Process_Naming_Scheme.Check): Do not do any check in aggregate
12025         project, as attribute Library_Dir and Library_Name have already
12026         been detected as forbidden.
12028 2014-01-24  Vincent Celier  <celier@adacore.com>
12030         * prj-env.adb (Find_Project): If cached project path is not in
12031         project directory, look in current directory first and use cached
12032         project path only if project is not found in project directory.
12034 2014-01-24  Robert Dewar  <dewar@adacore.com>
12036         * sem_util.adb, lib-xref.adb: Correct false positive warnings.
12038 2014-01-24  Vincent Celier  <celier@adacore.com>
12040         * projects.texi: Document that aggregate projects are only
12041         supported by gprbuild, but not by gnatmake.  Document that the
12042         only attribute Switches in package Binder of aggregate projects
12043         will be ignored if its index is not others.  Document that
12044         attribute Global_Config_File is allowed in package Binder of
12045         aggregate projects.
12047 2014-01-24  Robert Dewar  <dewar@adacore.com>
12049         * sem_prag.adb: Minor code reorganization.
12050         * sem_util.adb: Minor fix of potential latent bug in Is_LHS.
12052 2014-01-24  Pascal Obry  <obry@adacore.com>
12054         * prj-attr.adb, projects.texi, snames.ads-tmpl: Add Excluded_Patterns
12055         attribute definition.
12057 2014-01-24  Vincent Celier  <celier@adacore.com>
12059         * makeutl.adb (Queue.Insert_No_Roots): In gprbuild, do not put
12060         in the Queue the same source (same path, same multi-source index)
12061         from the same project file, to avoid compiling several times
12062         the same source.
12064 2014-01-24  Eric Botcazou  <ebotcazou@adacore.com>
12066         * einfo.ads (First_Rep_Item): Remove obsolete stuff.
12067         (Has_Gigi_Rep_Item): Likewise.
12068         * sem_prag.adb (Analyze_Pragma) <Pragma_Linker_Section>: Do not set
12069         Has_Gigi_Rep_Item for objects.
12070         * gcc-interface/decl.c (prepend_one_attribute_to): Rename into...
12071         (prepend_one_attribute): ...this.
12072         (prepend_one_attribute_pragma): New function extracted from...
12073         (prepend_attributes): ...here.  Swap the parameters for consistency.
12074         (gnat_to_gnu_entity): Adjust calls to prepend_one_attribute_to and to
12075         prepend_attributes.
12076         <object>: Deal with a pragma Linker_Section on a constant
12077         or variable.  <E_Function>: Deal with a pragma Linker_Section
12078         on a subprogram.
12079         (get_minimal_subprog_decl): Adjust calls to prepend_one_attribute_to.
12081 2014-01-24  Vincent Celier  <celier@adacore.com>
12083         * opt.ads: Minor comment update.
12085 2014-01-24  Robert Dewar  <dewar@adacore.com>
12087         * sem_prag.adb (Analyze_Input_Output): Add missing error check
12088         for junk operand.
12089         * sem_util.adb (Is_Refined_State): Add defense against junk
12090         tree from error.
12092 2014-01-24  Pascal Obry  <obry@adacore.com>
12094         * projects.texi: Removes Build_Slaves attribute documentation.
12096 2014-01-23  Robert Dewar  <dewar@adacore.com>
12098         * opt.adb (Register_Opt_Config_Switches): Save SPARK_Mode_Pragma
12099         setting.
12101 2014-01-23  Ed Schonberg  <schonberg@adacore.com>
12103         * sem_util.adb (Is_Potentially_Unevaluated): Predicate only
12104         applies to expressions that come from source.
12105         * sem_attr.adb (Analyze_Attribute, case 'Old): Improve error
12106         message.
12107         (Analyze_Attribute, case 'Loop_Entry): Apply SPARK 2014 legality
12108         rule regarding potentially unevaluated expressions, to prefix
12109         of attribute.
12111 2014-01-23  Ed Schonberg  <schonberg@adacore.com>
12113         * exp_util.adb (Make_Invqriant_Call): If type of expression is
12114         a private extension, get invariant from base type.
12116 2014-01-23  Robert Dewar  <dewar@adacore.com>
12118         * sem_util.adb, sem_attr.adb: Minor reformatting.
12120 2014-01-23  Robert Dewar  <dewar@adacore.com>
12122         * opt.adb (Save_Opt_Config_Switches): Save SPARK_Mode_Pragma
12123         (Restore_Opt_Config_Switches): Restore SPARK_Mode_Pragma.
12124         * sem.adb (Semantics): Remove save/restore of
12125         SPARK_Mode[_Pragma]. Not needed since already done in
12126         Save/Restore_Opt_Config_Switches.
12128 2014-01-23  Robert Dewar  <dewar@adacore.com>
12130         * gnat_rm.texi, einfo.adb, einfo.ads, sem_prag.adb, gnat_ugn.texi,
12131         freeze.adb, repinfo.adb, aspects.adb, aspects.ads, sem_ch13.adb:
12132         Linker_Section enhancements.
12134 2014-01-23  Tristan Gingold  <gingold@adacore.com>
12136         * gnat_rm.texi: Minor editing.
12138 2014-01-23  Robert Dewar  <dewar@adacore.com>
12140         * opt.adb (Set_Opt_Config_Switches): Reset SPARK mode for
12141         with'ed internal units.
12142         * sem.adb (Semantics): Save and restore SPARK_Mode[_Pragma].
12144 2014-01-23  Javier Miranda  <miranda@adacore.com>
12146         * lib-xref.adb (Generate_Reference): As part of processing the
12147         "end-of-spec" reference generate an extra reference to the first
12148         private entity of the package.
12149         * xr_tabls.adb (Add_Reference): No action needed for the extra
12150         'E' reference associated; similar to the processing of the
12151         'e' reference.
12153 2014-01-23  Bob Duff  <duff@adacore.com>
12155         * gnat_ugn.texi: Change "--&pp off" to "--!pp off".
12157 2014-01-23  Ed Schonberg  <schonberg@adacore.com>
12159         * sem_util.ads, sem_util.adb (Is_Potentially_Unevaluated): new
12160         predicate to implement rule given in 6.1.1 (20/3).
12161         * sem_attr.adb (Analyze_Attribute, case 'Old): Reject prefix of
12162         'Old in a postcondition, if it is potentially unevaluated and
12163         it is not an entity name.
12165 2014-01-23  Bob Duff  <duff@adacore.com>
12167         * gnat_ugn.texi: Document the new "--&pp off" feature of gnatpp.
12169 2014-01-23  Robert Dewar  <dewar@adacore.com>
12171         * gnatlink.adb (Gnatlink): Fix problem of generating bad name
12172         msg on VMS.
12174 2014-01-23  Bob Duff  <duff@adacore.com>
12176         * g-dynhta.ads: Minor comment fix.
12178 2014-01-23  Yannick Moy  <moy@adacore.com>
12180         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Inherit SPARK_Mode
12181         from spec on body only when not already inherited on spec. Set
12182         SPARK_Mode from context on body without previous spec.  *
12183         * sem_prag.adb (Analyze_Pragma): Check placement of pragma on
12184         library-level entities.  Correct retrieval of entity from
12185         declaration, for cases where the declaration is not a unit.
12186         * sem_ch12.adb (Instantiate_Object): Avoid
12187         calling Is_Volatile_Object on an empty node.
12189 2014-01-23  Robert Dewar  <dewar@adacore.com>
12191         * gnatlink.adb (Gnatlink): Check for suspicious executable file
12192         names on windows.
12194 2014-01-23  Robert Dewar  <dewar@adacore.com>
12196         * a-ngelfu.ads: Remove bad uses of AND which should be AND THEN.
12197         * sem_res.adb (Check_No_Direct_Boolean_Operators): Don't give
12198         style errors in instances.
12199         * g-dynhta.ads (Static_HTable): Comment updates.
12201 2014-01-23  Vincent Celier  <celier@adacore.com>
12203         * prj-conf.adb (Get_Or_Create_Configuration_File): Do not attempt
12204         to find a configuration project file when Config_File_Name is
12205         No_Configuration_File.
12206         * prj-conf.ads (No_Configuration_File): New constant String.
12207         * prj-pars.adb (Parse): Call Get_Or_Create_Configuration_File
12208         with Config_File_Name set to No_Configuration_File, so that
12209         no existing configuration project file will be used, and the
12210         configuration project will be only created in memory when
12211         Add_Default_GNAT_Naming_Scheme is called.
12212         * projects.texi: Minor reformatting.
12214 2014-01-23  Vincent Celier  <celier@adacore.com>
12216         * prj-conf.adb (Get_Or_Create_Configuration_File): Never parse
12217         a config project file if On_Load_Config is not null.
12218         * prj-pars.adb: Minor comment changes.
12220 2014-01-23  Ed Schonberg  <schonberg@adacore.com>
12222         * lib-xref.adb (Output_References): Output progenitors of
12223         synchronized tagged types, for source navigation.
12225 2014-01-23  Robert Dewar  <dewar@adacore.com>
12227         * exp_util.adb, sinfo.adb, sinfo.ads, sem.adb, sem_res.adb,
12228         expander.adb, exp_ch11.adb, exp_ch11.ads, sem_ch11.adb, sem_ch11.ads,
12229         sprint.adb, sprint.ads: Remove unused node N_Subprogram_Info.
12231 2014-01-23  Emmanuel Briot  <briot@adacore.com>
12233         * prj-conf.adb (Get_Or_Create_Configuration_File): call
12234         On_Load_Config later.
12236 2014-01-23  Hristian Kirtchev  <kirtchev@adacore.com>
12238         * sem_ch3.adb (Analyze_Declarations): Do not
12239         generate the spec of the late primitive in ASIS mode. Add two
12240         comments to explain the special cases when the expansion is
12241         not performed.
12243 2014-01-23  Robert Dewar  <dewar@adacore.com>
12245         * sem_util.adb (Note_Possible_Modification): Fix error of
12246         misbehaving for implicit dereference cases in -gnatc mode.
12248 2014-01-23  Emmanuel Briot  <briot@adacore.com>
12250         * prj-pars.adb: Minor reformatting.
12252 2014-01-22  Ed Schonberg  <schonberg@adacore.com>
12254         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): A subprogram
12255         body generated for an expression function within a protected body
12256         needs a set of renaming declarations if the expression function
12257         comes from source.
12259 2014-01-22  Ed Schonberg  <schonberg@adacore.com>
12261         * lib-xref.adb (Get_Type_Reference): In semantics-only mode,
12262         list interface progenitor of a tagged concurrent type, for better
12263         source navigation.
12265 2014-01-22  Robert Dewar  <dewar@adacore.com>
12267         * lib.adb (In_Extended_Main_Code_Unit): Return False for
12268         Standard_Location.
12269         (In_Extended_Main_Source_Unit): Return False for Standard_Location.
12270         * lib.ads (In_Extended_Main_Code_Unit): Add documentation on
12271         treatment of Slocs No_Location and Standard_Location.
12272         * restrict.adb (Check_Restriction_No_Dependence): Explicitly
12273         check for entity with Standard_Location Sloc, rather than relying
12274         on Lib routines to do that.
12275         * sem_res.adb (Resolve_Call): Implement SPARK_05 restriction
12276         that a call cannot occur before a later occuring body within
12277         the same unit.
12279 2014-01-22  Thomas Quinot  <quinot@adacore.com>
12281         * rtsfind.adb: Update comment.
12283 2014-01-22  Hristian Kirtchev  <kirtchev@adacore.com>
12285         * sem_aux.ads, sem_aux.adb (Is_Body): New routine.
12286         * sem_ch3.adb (Analyze_Declarations): Add local variable
12287         Body_Seen. Generate the spec of a late controlled
12288         primitive body that is about to freeze its related type.
12289         (Handle_Late_Controlled_Primitive): New routine.
12291 2014-01-22  Robert Dewar  <dewar@adacore.com>
12293         * a-stream.adb: Minor reformatting.
12295 2014-01-22  Ed Schonberg  <schonberg@adacore.com>
12297         * sem_ch8.adb (From_Actual_Package): Introduce a recursive
12298         sub-procedure Declared_In_Actual to handle properly the visibility
12299         of actuals in actual packages, that are themselves actuals to a
12300         actual package of the current instance. This mimics properly the
12301         visibility of formals of formal packages declared with a box,
12302         within the corresponding generic unit.
12304 2014-01-22  Robert Dewar  <dewar@adacore.com>
12306         * checks.adb: Do not assume that a volatile variable is valid.
12308 2014-01-22  Thomas Quinot  <quinot@adacore.com>
12310         * g-catiio.ads (Image, Value): Clarify that these functions
12311         operate in the local time zone.  Minor documentation update.
12313 2014-01-22  Thomas Quinot  <quinot@adacore.com>
12315         * csets.adb, csets.ads, opt.ads: Minor documentation fixes.
12317 2014-01-22  Robert Dewar  <dewar@adacore.com>
12319         * sem_aux.adb, sem_aux.ads, sem_ch3.adb (Has_Unconstrained_Elements):
12320         Moved to sem_aux.adb.
12322 2014-01-22  Robert Dewar  <dewar@adacore.com>
12324         * vms_data.ads: Minor reformatting.
12326 2014-01-22  Robert Dewar  <dewar@adacore.com>
12328         * debug.adb: Document messages affected by -gnatd.E including
12329         the new ones that relate to late definition of equality.
12330         * sem_ch6.adb (Check_Untagged_Equality): In Ada 2012 mode, if
12331         debug flag -gnatd.E is set, then generate warnings rather than
12332         errors.
12333         (Check_Untagged_Equality): In earlier versions of Ada,
12334         generate warnings if Warn_On_Ada_2012_Incompatibility flag is set.
12336 2014-01-22  Robert Dewar  <dewar@adacore.com>
12338         * sem_prag.adb (Usage_Error): Output additional messages for
12339         unconstrained OUT parameters lacking an input dependency.
12341 2014-01-22  Robert Dewar  <dewar@adacore.com>
12343         * sem_ch4.adb: Minor reformatting.
12345 2014-01-22  Robert Dewar  <dewar@adacore.com>
12347         * restrict.ads: Minor reformatting.
12348         * sem_res.adb (Resolve_Call): Check for SPARK_05 restriction that
12349         forbids a call from within a subprogram to the same subprogram.
12351 2014-01-22  Thomas Quinot  <quinot@adacore.com>
12353         * a-stream.ads (Read_SEA, Write_SEA): New subprograms, optimized
12354         stream attributes for Stream_Element_Array.
12355         * a-stream.adb (Read_SEA, Write_SEA): Bodies for the above.
12356         * rtsfind.adb (Check_CRT): Do not reject a reference to an entity
12357         defined in the current scope.
12359 2014-01-22  Robert Dewar  <dewar@adacore.com>
12361         * debug.adb, exp_ch4.adb, erroutc.adb: Minor reformatting.
12363 2014-01-22  Thomas Quinot  <quinot@adacore.com>
12365         * sem_ch7.adb, sem_ch8.adb, exp_ch3.adb: Minor reformatting.
12367 2014-01-22  Thomas Quinot  <quinot@adacore.com>
12369         * sem_ch3.adb (Analyze_Object_Declaration): For a constant
12370         declaration initialized with a function call, whose type
12371         has variable size, need to remove side effects so that the
12372         initialization expression becomes a dereference of a temporary
12373         reference to the function result.
12375 2014-01-22  Yannick Moy  <moy@adacore.com>
12377         * errout.adb (Initialize): Remove trick to add dummy entry
12378         in Warnings table.
12379         * erroutc.adb (Set_Warnings_Mode_Off,
12380         Set_Warnings_Mode_On): Do nothing if warnings are suppressed by
12381         command line switch.
12382         * opt.ads (Warning_Mode): Document behavior
12383         wrt pragma Warnings, in normal mode and in GNATprove_Mode.
12385 2014-01-22  Robert Dewar  <dewar@adacore.com>
12387         * sem_ch3.adb, errout.adb, erroutc.adb: Minor reformatting.
12389 2014-01-22  Robert Dewar  <dewar@adacore.com>
12391         * sem_ch13.adb (Check_Pool_Size_Clash): New procedure
12392         (Analyze_Attribute_Definition_Clause, case Storage_Pool): call
12393         Check_Pool_Size_Clash (Analyze_Attribute_Definition_Clause,
12394         case Storage_Size): call Check_Pool_Size_Clash.
12396 2014-01-22  Robert Dewar  <dewar@adacore.com>
12398         * sem_ch3.adb, exp_util.adb, sem_dim.adb, sem_elab.adb, sem_ch8.adb,
12399         sem_eval.ads: Minor reformatting.
12401 2014-01-22  Thomas Quinot  <quinot@adacore.com>
12403         * sem_eval.adb (Compile_Time_Known_Bounds): Return False for
12404         Any_Composite to prevent cascaded errors.
12406 2014-01-22  Yannick Moy  <moy@adacore.com>
12408         * errout.adb (Initialize): Do not insert special entry in Warnings
12409         table in GNATprove_Mode.
12410         * erroutc.adb (Set_Warnings_Mode_On): Add info in Warnings table in
12411         GNATprove_Mode.
12412         * gnat1drv.adb (Adjust_Global_Switches): Do not suppress frontend
12413         warnings anymore.
12415 2014-01-22  Robert Dewar  <dewar@adacore.com>
12417         * sem_prag.adb (Analyze_Initializes_In_Decl_Part): Handle null
12418         initializes case.
12420 2014-01-22  Robert Dewar  <dewar@adacore.com>
12422         * snames.ads-tmpl: Update header.
12424 2014-01-22  Thomas Quinot  <quinot@adacore.com>
12426         * exp_util.adb (Insert_Actions): When inserting actions on a
12427         short circuit operator that has already been analyzed, do not park
12428         actions in node; instead introduce an N_Expression_With_Actions
12429         and insert actions immediately.
12430         Add guard for unexpected case of climbing up through statement
12431         in Actions list of an N_Expression_With_Actions.
12432         * sem_elab.adb (Insert_Elab_Check): Remove complex
12433         specialized circuitry for the case where the context is already
12434         analyzed, as it is not needed and introduces irregularities in
12435         finalization. Instead rely on the above change to Insert_Actions
12436         to ensure that late insertion on short circuit operators works
12437         as expected.
12439 2014-01-22  Ed Schonberg  <schonberg@adacore.com>
12441         * sem_ch4.adb (Operator_Check): Improve error message when an
12442         operand of concatenation is an access type.
12444 2014-01-22  Thomas Quinot  <quinot@adacore.com>
12446         * sem_dim.adb (Analyze_Dimension_Identifier): Add guard against
12447         cascaded error.
12449 2014-01-22  Ed Schonberg  <schonberg@adacore.com>
12451         * sem_ch8.adb (Find_Selected_Component): Handle properly the case
12452         of an expanded name in a proper body, whose prefix is a package
12453         in the context of the proper body, when there is a homonym of
12454         the package declared in the parent unit.
12456 2014-01-22  Robert Dewar  <dewar@adacore.com>
12458         * sem_warn.adb (Check_Use_Clause): Don't give no entities used
12459         msg if errors found.
12460         (Check_One_Unit): Same change.
12462 2014-01-22  Robert Dewar  <dewar@adacore.com>
12464         * ug_words: Add missing/wrong entries for VMS warning switches.
12465         * sem_prag.adb (Check_Duplicate_Pragma): Avoid flagging parent type.
12467 2014-01-22  Jerome Guitton  <guitton@adacore.com>
12469         * mlib-tgt-specific-vxworks.adb (Get_Target_Suffix): Replace xscale by
12470         arm.
12472 2014-01-22  Robert Dewar  <dewar@adacore.com>
12474         * gnat_rm.texi, gnat_ugn.texi: Document passive task optimization
12476 2014-01-22  Eric Botcazou  <ebotcazou@adacore.com>
12478         * gcc-interface/Makefile.in: Minor fixes.
12480 2014-01-21  Robert Dewar  <dewar@adacore.com>
12482         * par-ch4.adb (P_If_Expression): Rewritten to improve error recovery.
12483         * par-ch5.adb (P_Condition): New version with expression prescanned.
12484         * par.adb (P_Condition): New version with expression prescanned.
12486 2014-01-21  Robert Dewar  <dewar@adacore.com>
12488         * gnat_rm.texi: Document that Allow_Integer_Address is ignored
12489         if Address is not a private type.
12490         * sem_prag.adb (Analyze_Pragma, case Allow_Integer_Address):
12491         Ignore pragma if System.Address is not a private type.
12493 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
12495         * namet.ads (Name_Len): Initialize to 0 to avoid accessing an
12496         uninitialized value.
12498 2014-01-21  Thomas Quinot  <quinot@adacore.com>
12500         * gnat_rm.texi (Scalar_Storage_Order): Update documentation.
12502 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
12504         * sem_ch12.adb (Set_Instance_Env): In Ada 2012 mode, preserve
12505         the value of Assertions_Enabled flag when compiling an instance of
12506         an internal unit. This facilitates the use of pre/postconditions
12507         in generic internal units, such as the new elementary function
12508         libraries.
12510 2014-01-21  Robert Dewar  <dewar@adacore.com>
12512         * exp_aggr.adb: Minor reformatting.
12513         * sem_attr.adb: Minor reformatting.
12514         * sem_res.adb: Minor comment addition.
12515         * einfo.adb: Minor comment updates.
12516         * freeze.adb: Minor reformatting and code reorganization.
12518 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
12520         * par-ch4.adb (P_If_Expression): Handle more gracefully an
12521         elsif clause that does not have an else part.
12523 2014-01-21  Robert Dewar  <dewar@adacore.com>
12525         * checks.adb, sem_util.ads, sem_ch4.adb: Minor reformatting.
12526         * gcc-interface/Makefile.in: clean up target pairs.
12528 2014-01-21  Pascal Obry  <obry@adacore.com>
12530         * projects.texi: Minor typo fix.
12532 2014-01-21  Thomas Quinot  <quinot@adacore.com>
12534         * freeze.adb (Check_Component_Storage_Order): If a record type
12535         has an explicit Scalar_Storage_Order attribute definition clause,
12536         reject any component that itself is of a composite type and does
12537         not have one.
12539 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
12541         * sem_ch10.adb (Generate_Parent_Reference): Make public so it
12542         can be used to generate proper cross-reference information for
12543         the parent units of proper bodies.
12545 2014-01-21  Thomas Quinot  <quinot@adacore.com>
12547         * exp_pakd.adb (Expand_Packed_Element_Set,
12548         Expand_Packed_Element_Reference): No byte swapping required in
12549         the front-end for the case of a reverse storage order array,
12550         as this is now handled uniformly in the back-end.  However we
12551         still need to swap back an extracted element if it is itself a
12552         nested composite with reverse storage order.
12554 2014-01-21  Hristian Kirtchev  <kirtchev@adacore.com>
12556         * sem_prag.adb (Analyze_External_Property): Add processing for "others".
12557         (Analyze_Pragma): Update the grammar of pragma Abstract_State to
12558         include "others".
12560 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
12562         * gnat_ugn.texi: Minor updates.
12564 2014-01-21  Thomas Quinot  <quinot@adacore.com>
12566         * exp_pakd.adb: Update comment, minor reformatting.
12568 2014-01-21  Hristian Kirtchev  <kirtchev@adacore.com>
12570         * sem_ch3.adb (Analyze_Variable_Contract): Trigger the volatile
12571         object check when SPARK_Mode is on.
12572         * sem_ch6.adb (Process_Formals): Trigger the volatile object
12573         check when SPARK_Mode is on.
12574         * sem_ch12.adb (Instantiate_Object): Trigger the volatile object
12575         check when SPARK_Mode is on.
12576         * sem_ch13.adb (Analyze_Aspect_Specifications): Insert the
12577         corresponding pragma of aspect SPARK_Mode in the visible
12578         declarations of a package declaration.
12579         * sem_prag.adb (Analyze_Pragma): Trigger the volatile object
12580         check when SPARK_Mode is on.
12581         * sem_res.adb (Resolve_Actuals): Trigger the volatile object
12582         check when SPARK_Mode is on.
12583         (Resolve_Entity_Name): Trigger
12584         the volatile object check when SPARK_Mode is on.
12586 2014-01-21  Robert Dewar  <dewar@adacore.com>
12588         * sem_ch3.adb, sem_prag.adb, sem_prag.ads, sem_ch12.adb, sem_res.adb,
12589         sem_ch6.adb, a-except-2005.adb: Minor reformatting.
12591 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
12593         * exp_ch3.adb (Expand_N_Object_Declaration): When a class-wide
12594         object is declared, it is rewritten as a renaming of an dynamic
12595         expression that wraps the initial value.  The renaming declaration
12596         is first given an internal name, to prevent collisions with the
12597         entity already declared, and then the name is modified to reflect
12598         the original one. the modification of the name must preserve
12599         the source location of the original, to prevent spurious errors
12600         when compiling with style checks if the declaration involves
12601         more than one entity.
12603 2014-01-21  Hristian Kirtchev  <kirtchev@adacore.com>
12605         * aspects.adb Add entries for Async_Readers, Async_Writers,
12606         Effective_Reads and Effective_Writes in table Canonical_Aspect.
12607         * aspects.ads Add entries for Async_Readers, Async_Writers,
12608         Effective_Reads and Effective_Writes in tables Aspect_Id,
12609         Aspect_Names, Aspect_Delay and Implementation_Defined_Aspect.
12610         * atree.adb (Ekind_In): New version with 8 parameters.
12611         (Node34): New routine.
12612         (Set_Node34): New routine.
12613         * atree.ads (Ekind_In): New version with 8 parameters.
12614         (Node34): New routine.
12615         (Set_Node34): New routine.
12616         * einfo.adb Contract is now Node34.
12617         (Contract): Update the assertion and node usage.
12618         (Get_Pragma): Include pragmas Async_Readers, Async_Writers,
12619         Effective_Reads and Effective_Writes.
12620         (Set_Contract): Update the assertion and node usage.
12621         (Write_Field24_Name): Remove the output for a contract.
12622         (Write_Field34_Name): Add output for a contract.
12623         * einfo.ads Contract is now Node34. Update the comment on
12624         attribute usage and related node structures.
12625         (Get_Pragma): Update the comment on usage.
12626         * par-prag.adb (Prag): Pragmas Async_Readers, Async_Writers,
12627         Effective_Reads and Effective_Writes do not require special
12628         processing by the parser.
12629         * sem_ch3.adb (Analyze_Variable_Contract): New routine.
12630         (Analyze_Declarations): Analyze the contract of a variable at
12631         the end of the declarative region.
12632         (Analyze_Object_Declaration): Create a contract for a variable.
12633         * sem_ch6.adb (Analyze_Subprogram_Contract): Update the retrieval
12634         of classification pragmas.
12635         (Process_Formals): Detect an illegal
12636         use of a volatile object as a formal in a function.
12637         * sem_ch12.adb (Instantiate_Object): Detect an illegal use of
12638         a volatile object as an actual in generic instantiation.
12639         * sem_prag.adb Add entries for Async_Readers, Async_Writers,
12640         Effective_Reads and Effective_Writes in table Sig_Flags.
12641         (Analyze_External_State_In_Decl_Part): New routine.
12642         (Analyze_Global_Item): Detect an illegal use of a volatile object
12643         as a global item of a function.
12644         (Analyze_Pragma): Reimplement
12645         pragma Abstract_State. Add support for pragmas Async_Readers,
12646         Async_Writers, Effective_Reads and Effective_Writes.
12647         (Check_External_Properties): New routine.
12648         * sem_prag.ads (Analyze_External_State_In_Decl_Part): New routine.
12649         (Check_External_Properties): New routine.
12650         * sem_res.adb (Resolve_Actuals): Detect an illegal use of a
12651         volatile object as an actual in a call.
12652         (Resolve_Entity_Name):
12653         Add local variables Par, Prev and Usage_OK. Detect illegal
12654         contexts of volatile objects.
12655         * sem_util.adb (Add_Contract_Item): Add support for
12656         pragmas associated with the contract of a variable.
12657         (Async_Readers_Enabled): New routine.
12658         (Async_Writers_Enabled): New routine.
12659         (Effective_Reads_Enabled): New routine.
12660         (Effective_Writes_Enabled): New routine.
12661         (Has_Enabled_Property):
12662         New routine.
12663         (Is_Unchecked_Conversion_Instance): New routine.
12664         (Is_Volatile_Object): Add support for entities that may denote
12665         a volatile object.
12666         * sem_util.ads (Add_Contract_Item): Update the
12667         comment on usage.
12668         (Async_Readers_Enabled): New routine.
12669         (Async_Writers_Enabled): New routine.
12670         (Effective_Reads_Enabled): New routine.
12671         (Effective_Writes_Enabled): New routine.
12672         (Is_Unchecked_Conversion_Instance): New routine.
12673         * sinfo.ads Update the comment on the structure of N_Contract.
12674         * snames.ads-tmpl Add predefined names for Async_Readers,
12675         Async_Writers, Effective_Reads and Effective_Writes. Add
12676         pragma ids for Async_Readers, Async_Writers, Effective_Reads
12677         and Effective_Writes.
12679 2014-01-21  Robert Dewar  <dewar@adacore.com>
12681         * exp_ch4.adb (Eval_Op_Expon): Use CRT_Safe_Compile_Time_Known_Value
12682         * sem_eval.adb (Compile_Time_Known_Value): Remove special
12683         handling of CRT mode (CRT_Safe_Compile_Time_Known_Value): New
12684         function (Eval_Op_Expon): Add CRT_Safe in call to Test_Foldable
12685         (Test_Foldable): Add CRT_Safe parameter
12686         * sem_eval.ads (Compile_Time_Known_Value): Remove special
12687         handling of CRT mode.
12688         (CRT_Safe_Compile_Time_Known_Value): New function.
12690 2014-01-21  Robert Dewar  <dewar@adacore.com>
12692         * sem_prag.adb (Analyze_Pragma, case SPARK_Mode): Fix problem
12693         with pragma or aspect that applies to package spec or subprogram
12694         spec.
12696 2014-01-21  Robert Dewar  <dewar@adacore.com>
12698         * exp_aggr.adb: Minor reformatting.
12700 2014-01-21  Johannes Kanig  <kanig@adacore.com>
12702         * gnat1drv.adb (Gnat1drv) remove obsolete reference to -gnatd.H.
12704 2014-01-21  Bob Duff  <duff@adacore.com>
12706         * gnat_ugn.texi: Document the "checks" attribute in gnat2xml.
12708 2014-01-21  Steve Baird  <baird@adacore.com>
12710         * gnat_rm.texi: Improve description of SPARK_Mode pragma.
12712 2014-01-21  Vincent Celier  <celier@adacore.com>
12714         * prj-part.adb (Parse_Single_Project): Accept to extend a project
12715         if it has only be imported by an project being extended. When a
12716         project that has only been imported by a project being extended
12717         is imported by another project that is not being extended,
12718         reset the previous indication, so that it will be an error if
12719         this project is extended later.
12720         * prj-tree.adb (Create_Project): Include component From_Extended
12721         in table Projects_HT
12722         * prj-tree.ads (Project_Name_And_Node): New Boolean component
12723         From_Extended
12725 2014-01-21  Robert Dewar  <dewar@adacore.com>
12727         * atree.ads, atree.adb: Add Node33 and Set_Node33.
12728         * einfo.ads, einfo.adb (SPARK_Pragma): New field (SPARK_Aux_Pragma):
12729         New field (SPARK_Pragma_Inherited): New flag
12730         (SPARK_Aux_Pragma_Inherited): New flag (SPARK_Mode_Pragmas):
12731         Removed.
12732         * lib.ads, lib.adb: Remove SPARK_Mode_Pragma, no longer used.
12733         * opt.ads (SPARK_Mode_Pragma): New global variable.
12734         * sem.ads: Add Save_SPARK_Mode_Pragma field to Scope_Stack_Entry.
12735         * sem_ch3.adb: Use new SPARK_Mode data structures.
12736         * sem_ch6.adb: Set SPARK_Mode fields in subprogram specs and bodies.
12737         * sem_ch7.adb: Set SPARK_Mode fields in package spec and body entities.
12738         * sem_ch8.adb (Push_Scope): Save SPARK_Mode_Pragma.
12739         (Pop_Scope): Restore SPARK_Mode_Pragma.
12740         * sem_prag.adb (Analyze_Pragma, case SPARK_Mode): Rewrite for
12741         new data structures.
12743 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
12745         * back_end.adb: Undo previous change, not needed. Minor reformatting.
12747 2014-01-21  Thomas Quinot  <quinot@adacore.com>
12749         * exp_ch5.adb: Fix comment.
12750         * switch-c.adb: Minor comment update.
12751         * exp_ch3.adb: Minor reformatting.
12753 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
12755         * back_end.adb (Scan_Compiler_Arguments): Do not store object
12756         filename in gnatprove mode.
12758 2014-01-21  Thomas Quinot  <quinot@adacore.com>
12760         * sinfo.ads (No_Ctrl_Actions): Clarify documentation (flag also
12761         suppresses usage of primitive _assign for tagged types).
12762         * exp_aggr.adb (Build_Array_Aggr_Code.Gen_Assign): Set
12763         No_Ctrl_Actions for a tagged type that does not require
12764         finalization, as we want to disable usage of _assign (which
12765         may cause undesirable discriminant checks on an uninitialized,
12766         invalid target).
12768 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
12770         * sem_prag.adb: Reject invariant'class on completion.
12772 2014-01-21  Javier Miranda  <miranda@adacore.com>
12774         * exp_ch3.adb (Build_Init_Procedure): For
12775         derivations of interfaces, do not move the the initialization
12776         of the _parent field since such assignment is not generated.
12778 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
12780         * sem_res.adb (Rewrite_Renamed_Operator): Do not replace entity
12781         with the operator it renames if we are within an expression of
12782         a pre/postcondition, because the expression will be reanalyzed
12783         at a later point, and the analysis of the renaming may affect
12784         the visibility of the operator when in an instance.
12786 2014-01-21  Robert Dewar  <dewar@adacore.com>
12788         * sinfo.ads, sinfo.adb: Change Do_Discriminant_Check to use new Flag1.
12789         Add this flag to type conversion nodes and assignment nodes.
12790         * treepr.adb: Deal properly with Flag 1,2,3.
12791         * treeprs.adt: Minor comment update.
12793 2014-01-21  Robert Dewar  <dewar@adacore.com>
12795         * sem_eval.adb (Compile_Time_Known_Value): Add Ignore_CRT
12796         parameter.
12797         * sem_eval.ads (Compile_Time_Known_Value): Add Ignore_CRT
12798         parameter, completely rewrite spec.
12800 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
12802         * sem_ch10.adb (Install_Withed_Unit): If the unit is a subprogram
12803         instance that is inlined, it may have been rewritten as a wrapper
12804         package. In that case the unit that must be made visible is the
12805         related instance of the package.
12807 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
12809         * exp_ch9.adb (Expand_N_Selective_Accept.Add_Accept): Refine
12810         previous change in codepeer mode.
12812 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
12814         * exp_ch9.adb (Expand_N_Selective_Accept.Add_Accept): Always add
12815         call to Abort_Undefer, as expected by the runtime.
12816         * s-tasren.adb (Local_Complete_Rendezvous): Replace
12817         Defer_Abort_Nestable by Defer_Abort, since we do not expect abort to be
12818         deferred at this point. Update comments.
12820 2014-01-21  Thomas Quinot  <quinot@adacore.com>
12822         * exp_ch4.adb, exp_ch5.adb, checks.adb: Minor reformatting.
12824 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
12826         * switch-c.adb, usage.adb, gnat_ugn.texi: Mark -gnates as internal,
12827         remove from doc.
12829 2014-01-21  Robert Dewar  <dewar@adacore.com>
12831         * switch-c.adb, usage.adb, atree.adb, atree.ads: Minor reformatting.
12833 2014-01-21  Thomas Quinot  <quinot@adacore.com>
12835         * atree.adb, atree.ads (Num_Extension_Nodes): Switch to Node_Id, since
12836         this is value is used in Node_Id arithmetic operations.
12837         (Copy_Node, Exchange_Entities): Use loops indexed by Num_Extension_Nodes
12838         instead of hard-coded unrolled code.
12840 2014-01-21  Yannick Moy  <moy@adacore.com>
12842         * gnat1drv.adb: Minor code cleanup, removing useless code.
12844 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
12846         * opt.ads (SPARK_Switches_File_Name): New.
12847         * switch-c.adb (Scan_Front_End_Switches): Add handling of -gnates=xxx *
12848         * usage.adb (Usage): Document -gnates, in gnatprove mode only.
12849         * gnat_ugn.texi: Document -gnates.
12851 2014-01-21  Yannick Moy  <moy@adacore.com>
12853         * errout.adb (Special_Msg_Delete): Update comment. Remove
12854         special case for GNATprove which should not ignore mismatch
12855         in sizes for representation clauses.
12856         * sem_prag.adb (Analyze_Pragma): Remove special case for GNATprove
12857         which should not ignore pragma Pack.
12859 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
12861         * sem_ch4.adb: Code clean up.
12863 2014-01-21  Steve Baird  <baird@adacore.com>
12865         * gnat_rm.texi: Improve GNAT RM description of SPARK_Mode pragma.
12867 2014-01-21  Robert Dewar  <dewar@adacore.com>
12869         * gcc-interface/gigi.h: Get Flags array address.
12870         * gcc-interface/trans.c: Acquire Flags array address.
12871         * atree.adb: Add support for Flags array and Flag0,1,2,3.
12872         * atree.ads: Add support for Flags array and Flag0,1,2,3.
12873         * atree.h: Add support for Flags array and Flag0,1,2,3.
12874         * back_end.adb: Pass Flags array address to gigi.
12876 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
12878         * sem_ch8.adb (Attribute_Renaming): Transfer original attribute
12879         reference to generated body so that legality checks on stream
12880         attributes are properly applied. If type is tagged and already
12881         frozen, insert generated body at the point of the renaming
12882         declaration.
12884 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
12886         * sem_ch12.adb: Code clean up.
12887         * sem_ch8.adb: Minor reformatting
12889 2014-01-20  Robert Dewar  <dewar@adacore.com>
12891         * checks.adb: Check SPARK_Mode instead of GNATProve_Mode for
12892         converting warnings on inevitable exceptions to errors.
12893         * exp_ch4.adb: Check SPARK_Mode instead of GNATProve_Mode for
12894         converting warnings on inevitable exceptions to errors.
12895         * opt.adb (SPARK_Mode_Config): Handled like other config flags
12896         * opt.ads (SPARK_Mode_Type): Moved here from types (renamed from
12897         SPARK_Mode_Id) (SPARK_Mode_Type): Add pragma Ordered, remove
12898         SPARK_ from names (SPARK_Mode): New flag (SPARK_Mode_Config):
12899         New flag (Config_Switches_Type): Add SPARK_Mode field
12900         * sem.adb: Minor code reorganization (remove unnecessary with)
12901         * sem.ads (Scope_Stack_Entry): Add Save_SPARK_Mode field
12902         * sem_aggr.adb: Check SPARK_Mode instead of GNATProve_Mode for
12903         converting warnings on inevitable exceptions to errors.
12904         * sem_attr.adb: Check SPARK_Mode instead of GNATProve_Mode for
12905         converting warnings on inevitable exceptions to errors.
12906         * sem_ch3.adb: Check SPARK_Mode instead of GNATProve_Mode for
12907         converting warnings on inevitable exceptions to errors.
12908         * sem_ch4.adb: Check SPARK_Mode instead of GNATProve_Mode for
12909         converting warnings on inevitable exceptions to errors.
12910         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Reset SPARK_Mode
12911         from spec if needed
12912         * sem_ch7.adb (Analyze_Package_Body_Helper): Reset SPARK_Mode
12913         from spec if needed
12914         * sem_ch8.adb (Push_Scope): Save SPARK_Mode (Pop_Scope):
12915         Restore SPARK_Mode
12916         * sem_elab.adb: Check SPARK_Mode instead of GNATProve_Mode for
12917         converting warnings on inevitable exceptions to errors.
12918         * sem_prag.adb (Get_SPARK_Mode_From_Pragma): New function
12919         (Get_SPARK_Mode_Id): Removed (Get_SPARK_Mode_Type): New name
12920         of Get_SPARK_Mode_Id
12921         * sem_prag.ads (Get_SPARK_Mode_From_Pragma): New function
12922         * sem_res.adb: Check SPARK_Mode instead of GNATProve_Mode for
12923         converting warnings on inevitable exceptions to errors.
12924         * sem_util.adb: Check SPARK_Mode instead of GNATProve_Mode for
12925         converting warnings on inevitable exceptions to errors.
12926         * types.ads (SPARK_Mode_Id): Moved to opt.ads and renamed
12927         SPARK_Mode_Type
12929 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
12931         * sem_ch13.adb: Add semantic information to rewritten type
12932         reference.
12934 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
12936         * exp_ch5.adb (Expand_N_Assignment_Statement): If both sides
12937         are of a type with unknown discriminants, convert both to the
12938         underlying view of the type, so that the proper constraint check
12939         can be applied to the right-hand side.
12941 2014-01-20  Robert Dewar  <dewar@adacore.com>
12943         * atree.adb (Copy_Node): Fix failure to copy last component
12944         (Exchange_Entities): Fix failure to exchange last entity
12946 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
12948         * sem_ch12.adb: Code clean up.
12950 2014-01-20  Robert Dewar  <dewar@adacore.com>
12952         * gnat_rm.texi, sem_ch4.adb: Minor reformatting.
12954 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
12956         * sem_ch4.adb (Analyze_Quantified_Expression): If after
12957         pre-analysis  the loop parameter specification has been
12958         rewritten as a iterator specification, propagate the change to
12959         the quantified expression, for ASIS navigtion needs.
12961 2014-01-20  Vincent Celier  <celier@adacore.com>
12963         * par-ch10.adb: Minor error message change: escape [ and ].
12965 2014-01-20  Robert Dewar  <dewar@adacore.com>
12967         * checks.adb: Make warnings on exceptions into errors in GNATprove mode.
12968         * errout.adb: Implement [ and ] insertion characters.
12969         * errout.ads: Document new [ and ] insertion characters.
12970         * sem_ch12.adb, restrict.adb, frontend.adb, exp_ch7.adb: Minor
12971         addition of ??? comment.
12972         * lib-xref.adb, exp_util.adb, gnat1drv.adb: Minor reformatting
12973         * exp_ch4.adb, sem_ch3.adb, sem_ch4.adb, sem_ch6.adb, sem_elab.adb,
12974         sem_eval.adb, sem_res.adb, sem_util.adb, sem_attr.adb, sem_aggr.adb:
12975         Make warnings on exceptions into errors in GNATprove mode.
12976         * sem_dim.adb: Minor reformatting throughout Quote [ and ]
12977         in error messages.
12979 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
12981         * sem_ch13.adb: Code clean up.
12983 2014-01-20  Robert Dewar  <dewar@adacore.com>
12985         * errout.ads, errout.adb: Implement >? >x? >X? sequences in error
12986         messages.
12987         * sem_ch6.adb (Check_Statement_Sequence): Missing return is an
12988         error in GNATprove mode.
12990 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
12992         * par-ch4.adb (Is_Parameterless_Attribute): The Ada2012 attribute
12993         reference 'Old takes no parameters, and thus can appear as a
12994         prefix of a slice.
12996 2014-01-20  Eric Botcazou  <ebotcazou@adacore.com>
12998         * exp_aggr.adb: Fix minor typos.
13000 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
13002         * sem_attr.adb (Analyze_Attribute, case 'Constrained): In an
13003         instance the attribute is legal, and its value is determined
13004         statically if the type has no discriminants. This choice is
13005         more useful than rechecking the legality rule in the instance,
13006         is consistent with older usage, and is also consistent with all
13007         existing tests.
13009 2014-01-20  Arnaud Charlet  <charlet@adacore.com>
13011         * sem_cat.adb (Validate_Static_Object_Name): Change error into
13012         warning in Relaxed_Semantic_Mode.
13014 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
13016         * sem_attr.adb: Code and comments cleanup.
13018 2014-01-20  Yannick Moy  <moy@adacore.com>
13020         * debug.adb Free debug flags -gnatd.D, -gnatd.G and -gnatd.V *
13021         * errout.adb (Compilation_Errors): Remove special handling in
13022         GNATprove mode.
13023         * gnat1drv.adb (Adjust_Global_Switches): Remove handling of the
13024         removed debug flags.
13025         * gnat_rm.texi: Initial documentation for Abstract_State, Depends,
13026         Global, Initial_Condition, Initializes and Refined_State pragmas and
13027         aspects.
13028         * opt.ads (Frame_Condition_Mode, Formal_Extensions,
13029         SPARK_Strict_Mode): Remove global flags.
13030         * sem_ch3.adb (Analyze_Object_Declaration): Check of no hidden state
13031         always performed now, on packages declaring a null state.
13032         (Signed_Integer_Type_Declaration): Remove ill-designed attempt
13033         at providing pedantic mode for bounds of integer types.
13034         * sem_ch4.adb (Analyze_Quantified_Expression): Warning on suspicious
13035         "some" quantified expression now issued under control of -gnatw.t,
13036         like the other warning on unused bound variable.
13037         * sem_prag.adb (Check_Precondition_Postcondition): Remove useless test
13038         on removed flag.
13039         (Analyze_Pragma): Remove tests for SPARK 2014
13040         pragmas, not officially allowed by GNAT.
13042 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13044         * sem_prag.adb (Analyze_Pragma): Ensure that
13045         the sole argument of pragmas Abstract_State, Contract_Cases,
13046         Depends, Global and Initializes in in aggregate form.
13047         (Analyze_Refined_Pragma): Ensure that the sole argument of
13048         pragmas Refined_Depends, Refined_Global and Refined_State is in
13049         aggregate form.
13050         (Ensure_Aggregate_Form): New routine.
13052 2014-01-20  Doug Rupp  <rupp@adacore.com>
13054         * sem_attr.adb (Analyze_Attribute): case
13055         Attribute_Constrained => treat all prefixes as legal for Declib
13056         compatibility.
13058 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13060         * sem_prag.adb (Check_Mode): Reimplement the routine.
13061         (Find_Mode): New routine.
13063 2014-01-20  Robert Dewar  <dewar@adacore.com>
13065         * sem_ch4.adb (Operator_Check): Handle additional
13066         Allow_Integer_Address cases.
13068 2014-01-20  Robert Dewar  <dewar@adacore.com>
13070         * gnat_rm.texi (Allow_Integer_Address): Remove note about not
13071         allowed if address is non-private, no longer true.
13072         * sem_prag.adb (Analyze_Pragma, case Allow_Integer_Address):
13073         Remove check for address being private, causes difficulty when
13074         pragma used in gnat.adc file and is not needed, since we guard
13075         this in Address_Integer_Convert_OK.
13076         * exp_ch7.adb: Minor reformatting.
13077         * sem_ch4.adb: Handle operator operands in Allow_Integer_Address mode.
13079 2014-01-20  Robert Dewar  <dewar@adacore.com>
13081         * checks.adb (Apply_Range_Check): Remove gnatprove special
13082         casing of exponentiation.
13083         * sem_res.adb (Resolve_Op_Expon): Apply range check to right
13084         operand for integer case to check range against Natural.
13086 2014-01-20  Robert Dewar  <dewar@adacore.com>
13088         * s-tataat.adb: Minor reformatting.
13090 2014-01-20  Robert Dewar  <dewar@adacore.com>
13092         * einfo.adb (Is_Descendent_Of_Address): Now applies to all
13093         entities, and also fix documentation to remove mention of visible
13094         integer type, since this is not what the implementation does.
13095         * einfo.ads (Is_Descendent_Of_Address): Now applies to all
13096         entities, and also fix documentation to remove mention of visible
13097         integer type, since this is not what the implementation does.
13098         * gnat_rm.texi: Minor clarification of Allow_Integer_Address
13099         function.
13100         * sem_ch4.adb (Analyze_One_Call): Handle Allow_Integer_Address
13101         case for parameter type check.
13102         * sem_res.adb (Resolve): Use new function
13103         Address_Integer_Convert_OK.
13104         * sem_type.adb: Minor code reorganization (use Ekind_In) Minor
13105         reformatting throughout.
13106         * sem_util.adb (Address_Integer_Convert_OK): New function.
13107         * sem_util.ads: Minor reformatting (put specs in alpha order)
13108         (Address_Integer_Convert_OK): New function.
13110 2014-01-20  Thomas Quinot  <quinot@adacore.com>
13112         * exp_ch7.adb (Wrap_Transient_Expression):
13113         Insertion extra conditional expression only if
13114         Opt.Suppress_Control_Flow_Optimizations is set.
13116 2014-01-20  Arnaud Charlet  <charlet@adacore.com>
13118         * s-tataat.adb (Initialize_Attributes): Abort might already be
13119         deferred in Create_Task.
13121 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13123         * checks.adb (Apply_Scalar_Range_Check): Flag
13124         the exponent as requiring a range check when the expression is
13125         an exponentiation.
13127 2014-01-20  Fedor Rybin  <frybin@adacore.com>
13129         * gnat_ugn.texi: Documenting --passed-tests option for gnattest.
13131 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13133         * sem_util.adb (Default_Initialization): New routine.
13134         * sem_util.ads: Add new type Default_Initialization_Kind.
13135         (Default_Initialization): New routine.
13137 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13139         * sem_prag.adb (Check_Mode): Correct all error
13140         message logic dealing with in/in out parameters that may appear
13141         as inputs or have a self reference.
13143 2014-01-20  Robert Dewar  <dewar@adacore.com>
13145         * exp_ch9.adb, checks.adb, exp_intr.adb: Minor reformatting.
13146         * sem_res.adb (Resolve): Fix error causing infinite loop for
13147         integer used as address. Allow addresses as integers.
13149 2014-01-20  Arnaud Charlet  <charlet@adacore.com>
13151         * s-osinte-linux.ads (struct_sigaction): Fix rep clause.
13153 2014-01-20  Bob Duff  <duff@adacore.com>
13155         * par-ch8.adb (P_Use_Type_Clause): Detect syntax
13156         error when "use all" is not followed by "type".
13158 2014-01-20  Bob Duff  <duff@adacore.com>
13160         * exp_intr.adb (Expand_Unc_Deallocation): Remove warning on abort
13161         followed by free.
13163 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
13165         * checks.adb (Apply_Address_Clause_Check): If there is an
13166         alignment check on the expression in an address clause, and there
13167         is no local exception propagation, add an additional explanatory
13168         message to clarify the cause of previous warning.
13170 2014-01-20  Robert Dewar  <dewar@adacore.com>
13172         * exp_ch7.adb: Minor reformatting.
13173         * opt.ads: Minor comment updates.
13174         * sem.adb: Minor name change Is_Main_Unit =>
13175         Is_Main_Unit_Or_Main_Unit_Spec.
13176         * sem_ch6.adb: Minor reformatting and code reorganization.
13178 2014-01-20  Bob Duff  <duff@adacore.com>
13180         * gnat_ugn.texi: Update gnatpp switches.
13182 2014-01-20  Thomas Quinot  <quinot@adacore.com>
13184         * exp_ch9.adb: Minor comment edit.
13186 2014-01-20  Robert Dewar  <dewar@adacore.com>
13188         * gnat_rm.texi: Document that Allow_Integer_Address is permitted
13189         only if System.Address is a private type.
13190         * opt.ads (Allow_Integer_Address): No longer set by -gnates.
13191         * sem_prag.adb (Analyze_Pragma, case Allow_Integer_Address):
13192         Allowed only if type System.Address is private, since otherwise
13193         it makes no sense.
13194         * sem_res.adb: Fix failure to properly Analyze unchecked
13195         conversions that were introduced by Allow_Integer_Address.
13196         * switch-c.adb: Remove -gnates switch.
13197         * usage.adb: Remove -gnates switch.
13198         * gnat_ugn.texi: Remove documentation of -gnates flag.
13200 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
13202         * sem_ch6.adb (Analyze_Expression_Function): Pre-analyze and
13203         resolve expression to perform proper name capture.
13205 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
13207         * sem.adb (Semantics): When saving/restoring configuration
13208         switches, the spec of a pre- defined unit that is the main unit
13209         must be treated as a predefined unit as well.
13211 2014-01-20  Thomas Quinot  <quinot@adacore.com>
13213         * exp_ch7.adb (Wrap_Transient_Expression): For a Boolean
13214         expression, insert an extra conditional expression when saving
13215         the value of the expression, for the benefit of control flow
13216         graph based coverage analysis.
13217         * exp_ch3.adb: Minor reformatting.
13219 2014-01-20  Robert Dewar  <dewar@adacore.com>
13221         * gnat1drv.adb: Set Allow_Integer_Address in relaxed semantics mode.
13222         * gnat_rm.texi: Document pragma Allow_Integer_Address.
13223         * gnat_ugn.texi: Document pragma Allow_Integer_Address, -gnates.
13224         * opt.ads: New flag Allow_Integer_Address.
13225         * par-prag.adb: Dummy entry for pragma Allow_Integer_Address.
13226         * sem_ch5.adb: Minor reformatting.
13227         * sem_prag.adb: Implement pragma Allow_Integer_Address.
13228         * sem_res.adb (Resolve): Allow integer address value if
13229         switch set.
13230         * sem_util.adb: Minor reformatting.
13231         * snames.ads-tmpl: Add entry for pragma Allow_Integer_Address.
13232         * switch-c.adb: Recognize flag -gnates.
13233         * usage.adb: Document flag -gnates.
13235 2014-01-20  Thomas Quinot  <quinot@adacore.com>
13237         * s-tadeca.adb: Fix minor typos in comment.
13239 2014-01-20  Pascal Obry  <obry@adacore.com>
13241         * s-win32.ads (FreeLibrary): New import.
13243 2014-01-20  Robert Dewar  <dewar@adacore.com>
13245         * sem_res.adb, sem_cat.adb: Minor reformatting.
13246         * sem_ch11.adb (Analyze_Raise_Statement): Only give warning about
13247         assigning to OUT parameters for the current subprogram scope.
13248         * exp_ch4.adb: Minor reformatting.
13250 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
13252         * exp_ch4.adb (Process_Transient_Object,
13253         Find_Enclosing_Contexts): If the top-level if-expression that
13254         generated the transient object is an actual in a call, the proper
13255         Hook_Context is a construct enclosing the call.
13256         * einfo.ads: Indicate that Related_Expression is used to link a
13257         loop variable to the container expression over which the loop
13258         takes place.
13259         (Analyze_Iterator_Specification): Set the Related_Expression of
13260         the loop variable in a container element iterator.
13261         (Note_Possible_Modification): If the variable is the loop
13262         variable in a container element iterator, indicate that the
13263         enclosing container is also modified.
13265 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13267         * aspects.adb (Move_Or_Merge_Aspects): Reimplemented.
13269 2014-01-20  Robert Dewar  <dewar@adacore.com>
13271         * s-taasde.ads, gnat_ugn.texi, s-tadeca.adb, sem_res.adb, s-tadeca.ads:
13272         Minor reformatting and code clean up.
13274 2014-01-20  Arnaud Charlet  <charlet@adacore.com>
13276         * sem_cat.adb (Validate_Object_Declaration): Relax semantics
13277         of objects of private type if Relaxed_RM_Semantics.
13279 2014-01-20  Claire Dross  <dross@adacore.com>
13281         * a-cofove.ads (Vector): Capacity discriminant
13282         should be in range of the index.
13284 2014-01-20  Thomas Quinot  <quinot@adacore.com>
13286         * a-caldel.ads(To_Duration), s-taasde.ads(Time_Enqueue):
13287         Clarify specs s-tadeca.adb(Enqueue_Calendar): Compensate for
13288         possible difference between epoch of Ada.Calendar clock and Ada
13289         real-time/tasking clock.
13290         * s-taprop-posix.adb: Minor comment fix.
13292 2014-01-20  Doug Rupp  <rupp@adacore.com>
13294         * sysdep.c [vxworks]: Remove Vxworks version noise for RTP.
13296 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13298         * exp_attr.adb (Expand_N_Attribute_Reference): Generate validity
13299         checks on the prefix of attribute 'Old.
13300         * sem_ch3.adb (Process_Range_Expr_In_Decl): Suppress the
13301         generation of validity checks on a range that belongs to the
13302         iteration scheme of a quantified expression.
13303         * sem_ch5.adb (One_Bound): Suppress the generation of validity
13304         checks on a bound that belongs to the iteration scheme of a
13305         quantified expression, generate the check in all other cases.
13307 2014-01-20  Bob Duff  <duff@adacore.com>
13309         * gnat_ugn.texi: Enable --pp-new by default. Minor reorganization.
13311 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
13313         * sem_res.adb (Resolve): When compiling a predefined unit, ignore
13314         interpretations that do not come from other predefined units,
13315         to prevent spurious ambiguities in the presence of user-defined
13316         operators in the context of (an instance of) a predefined unit.
13318 2014-01-20  Robert Dewar  <dewar@adacore.com>
13320         * gnat_rm.texi: Document that Loop_Variant is included in
13321         Statement_Assertions.
13322         * sem_prag.adb (Check_Kind): Add Loop_Variant to
13323         Statement_Assertions (Check_Applicable_Policy): Add Loop_Variant
13324         to Statement_Assertions.
13326 2014-01-20  Doug Rupp  <rupp@adacore.com>
13328         * sysdep.c (__gnat_is_file_not_found_error) [vxworks6]: Add case
13329         for errno ENOENT from RTP on NFS mounted file system.
13331 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
13333         * sem_util.adb (Check_Function_Writable_Actuals): 1) Do not
13334         examine code that does not come from source. The check does not
13335         apply to code generated for constraint checks, and such code may
13336         generate spurious error messages when compiled with expansion
13337         disabled (as in a generic unit) because side effects may not
13338         have been removed.
13339         2) Make error messages more explicit: indicate the component
13340         of the  construct whose value is indeterminate because of a
13341         call to a function with in-out parameter in another component,
13342         when there is no mandated order of execution between the two
13343         components (actuals, aggregate components, alternatives).
13345 2014-01-20  Robert Dewar  <dewar@adacore.com>
13347         * gnat_rm.texi: Minor cleanup.
13349 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13351         * sem_attr.adb (Analyze_Attribute): Attributes 'Old and 'Result
13352         can now apply to a refined postcondition.
13353         * sem_ch6.adb (Analyze_Subprogram_Contract): Remove local
13354         variable Result_Seen. Add variables Case_Prag, Post_Prag,
13355         Seen_In_Case and Seen_In_Post. Update the mechanism that detects
13356         whether postconditions and/or constract-cases mention attribute
13357         'Result and introduce a post-state when applied to functions.
13358         (Check_Result_And_Post_State): Removed.
13359         * sem_prag.adb (Analyze_Pragma): Add local variable
13360         Result_Seen. Verify that the expression of pragma Refined_Post
13361         mentions attribute 'Result and introduces a post-state.
13362         * sem_util.ads, sem_util.adb (Check_Result_And_Post_State): New routine.
13364 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13366         * exp_ch7.adb (Is_Subprogram_Call): New routine.
13367         (Process_Transient_Objects): Make variable Must_Hook global with
13368         respect to all locally declared subprograms. Search the context
13369         for at least one subprogram call.
13370         (Requires_Hooking): Removed.
13372 2014-01-20  Claire Dross  <dross@adacore.com>
13374         * a-cfdlli.ads a-cfhama.ads a-cfhase.ads a-cforma.ads
13375         * a-cforse.ads a-cofove.ads: Add pragma Annotate (GNATprove,
13376         External_Axiomatization);
13378 2014-01-20  Robert Dewar  <dewar@adacore.com>
13380         * sem_attr.adb (Analyze_Attribute, case Loop_Entry): Allow
13381         Loop_Entry in Assert, Assert_And_Cut, and Assume pragmas.
13382         * sem_prag.adb (Analyze_Pragma, case Assert[_And_Cut], Assume):
13383         Allow Loop_Entry to be used in these pragmas if they appear in
13384         an appropriate context.
13385         (Placement_Error): Specialize error
13386         message for pragma Assert[_And_Cut] or pragma Assume containing
13387         Loop_Entry attribute.
13388         * a-exexpr-gcc.adb, sinput.adb: Minor reformatting.
13389         * s-excmac-arm.ads, s-except.ads, s-excmac-gcc.ads: Minor reformatting
13390         and code clean ups.
13392 2014-01-20  Robert Dewar  <dewar@adacore.com>
13394         * gnat1drv.adb: Minor comment update.
13396 2014-01-20  Tristan Gingold  <gingold@adacore.com>
13398         * raise-gcc.c (PERSONALITY_FUNCTION/arm): Remove unused
13399         variables, comment out unused code.
13400         * a-exexpr-gcc.adb: Move declarations to s-excmac-gcc.ads
13401         * s-excmac-gcc.ads: New file, extracted from a-exexpr-gcc.adb
13402         * s-excmac-arm.ads: New file.
13404 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13406         * exp_ch4.adb (Expand_N_Slice): Remove constant D and variables
13407         Drange and Index_Typ. Remove the circuitry which creates a
13408         range check to compare the index type of the array against the
13409         discrete_range.
13410         * sem_res.adb (Resolve_Slice): Add local variable Dexpr. Update
13411         the circuitry which creates a range check to handle a
13412         discrete_range denoted by a subtype indication.
13414 2014-01-20  Pierre-Marie Derodat  <derodat@adacore.com>
13416         * sinput.adb, sinput.ads (Sloc_Range): Traverse the tree of original
13417         nodes to get the original sloc range.
13419 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13421         * sem_prag.adb (Analyze_Pragma): Use Defining_Entity to obtain the
13422         entity of a [library level] package.
13424 2014-01-20  Tristan Gingold  <gingold@adacore.com>
13426         * raise-gcc.c (exception_class_eq): New function.
13427         (is_handled_by): Use it to compare exception classes.
13428         (PERSONALITY_STORAGE): Define.  (continue_unwind): New function to
13429         be called to return URC_CONTINUE_UNWIND.
13430         (personality_body): New function, extracted from PERSONALITY_ROUTINE.
13431         (PERSONALITY_ROUTINE): Add an implementation for the ARM unwinder.
13433 2014-01-20  Robert Dewar  <dewar@adacore.com>
13435         * opt.ads: Minor comment update.
13437 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13439         * exp_ch4.adb (Expand_N_Slice): Relocate some variables and
13440         constants to the "Local variables" area. Add new constant D. Add
13441         new variables Drange and Index_Typ.  Rename Pfx to Rep and Ptp
13442         to Pref_Typ and update all occurrences. Add circuitry to extract
13443         the discrete_range and the index type and build a range check.
13445 2014-01-20  Arnaud Charlet  <charlet@adacore.com>
13447         * gnat1drv.adb (Adjust_Global_Switches): Enable
13448         Treat_Categorization_Errors_As_Warnings when Relaxed_RM_Semantics
13449         is set.
13451 2014-01-20  Thomas Quinot  <quinot@adacore.com>
13453         * sem_ch5.adb, sem_ch4.adb: Minor reformatting.
13455 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13457         * sem_ch13.adb (Analyze_Aspect_Specifications):
13458         When aspect SPARK_Mode appears on a package body, insert the
13459         generated pragma at the top of the body declarations.
13461 2014-01-20  Robert Dewar  <dewar@adacore.com>
13463         * sem_aggr.adb, exp_prag.adb, sem_aux.adb, sinfo.ads, sem_ch10.adb,
13464         checks.adb, sem_prag.adb, sem_ch12.adb, freeze.adb, g-arrspl.adb,
13465         expander.adb, gnat1drv.adb, exp_ch4.adb, sem_ch6.adb,
13466         sem_ch8.adb, exp_dist.adb: Minor reformatting.
13468 2014-01-20  Yannick Moy  <moy@adacore.com>
13470         * gnat1drv.adb (Gnat1drv): Call Write_ALI with Object=True in GNATprove
13471         mode.
13473 2014-01-20  Pascal Obry  <obry@adacore.com>
13475         * g-arrspl.ads (Slice_Set): New definition (will use a copy on
13476         write scheme).
13477         * g-arrspl.adb: Adapt all routine to this new implementation.
13478         (Set): Copy the Slice_Set definition before reusing it.
13480 2014-01-20  Arnaud Charlet  <charlet@adacore.com>
13482         * sem_prag.adb (Process_Import_Or_Interface): In
13483         Relaxed_RM_Semantics, support old Ada 83 style of pragma Import.
13484         (Analyze_Pragma): Ditto for pragma Export.
13485         * exp_prag.adb (Expand_Pragma_Import_Or_Interface): Handle old pragma
13486         Import style.
13488 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13490         * einfo.ads: E_Abstract_State is now part of the entities that
13491         can be overloaded. Update type Overloadable_Kind to reflect the
13492         inclusion of abstract states.
13493         * sem_ch6.adb (New_Overloaded_Entity): A function can now
13494         overload an abstract state.
13495         * sem_prag.adb (Analyze_Constituent): Handle the overloading
13496         of states by functions. Use Entity_Of to obtain the entity of
13497         a constituent.  (Analyze_Global_Item): Handle the overloading of
13498         states by functions.
13499         (Analyze_Initialization_Item): Handle the
13500         overloading of states by functions.  Use Entity_Of to obtain the
13501         entity of an item.
13502         (Analyze_Input_Item): Handle the overloading
13503         of states by functions. Use Entity_Of to obtain the entity of an item.
13504         (Analyze_Input_Output): Handle the overloading of states by functions.
13505         (Analyze_Refinement_Clause): Handle the overloading
13506         of states by functions.  Use Entity_Of to obtain the entity of an item.
13507         (Appears_In): Use Entity_Of to obtain the entity of an element.
13508         (Check_Usage): Use Entity_Of to obtain the entity of
13509         an item. Add a guard to prevent a crash due to a previous error.
13510         (Resolve_State): New routine.
13512 2014-01-20  Yannick Moy  <moy@adacore.com>
13514         * spark_xrefs.ads, debug.adb, gnat1drv.adb, errout.adb, errout.ads,
13515         opt.ads: Minor comments updates.
13517 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
13519         * einfo.adb (Non_Limited_View): Applies to abstract states.
13520         (Set_From_Limited_With): Applies to abstract states.
13521         (Set_Non_Limited_View): Applies to abstract states.
13522         (Write_Field17): Output the non-limited view of an abstract state.
13523         * einfo.ads: Update the comment on usage and occurrences in
13524         nodes for attributes From_Limited_With and Non_Limited_View.
13525         * sem_aux.adb (Available_View): This routine can now handle
13526         abstract states.
13527         * sem_aux.ads (Available_View): This routine can now handle
13528         abstract states. Update the comment on usage.
13529         * sem_ch8.adb (Find_Expanded_Name): Handle abstract views
13530         of states and variables.
13531         (In_Pragmas_Depends_Or_Global): New routine.
13532         * sem_ch10.adb (Build_Limited_Views): Implement
13533         abstract (limited) views of variables and states.
13534         (Build_Shadow_Entity): This routine is now a procedure. Add
13535         formal parameter Shadow. Update the comment on usage. Add
13536         context-specific decoration for states and variables.
13537         (Decorate_State): New routine.  (Decorate_Variable): New routine.
13538         (Find_And_Process_States): New routine.
13539         (Process_Declarations): Renamed to Process_Declarations_And_States.
13540         (Process_Declarations_And_States): Add formal parameters
13541         Pack and Create_Abstract_Views. Update the comment on usage.
13542         (Process_States): New routine.
13543         * sem_prag.adb (Check_Dependency_Clause): Handle abstract
13544         views of states and variables. Match the abstract view of a state
13545         against its corresponding non-abstract view.
13546         (Is_Matching_Input):
13547         Handle abstract views of states and variables. Match the abstract
13548         view of a state against its corresponding non-abstract view.
13549         (Process_Global_Item): Handle abstract views of states and
13550         variables.
13552 2014-01-20  Bob Duff  <duff@adacore.com>
13554         * sem_ch10.adb (Expand_With_Clause): Don't
13555         recurse on the prefix if the current with-ed name refers to a
13556         package that renames its own parent, eg "package P.Q renames P;".
13558 2014-01-20  Yannick Moy  <moy@adacore.com>
13560         * exp_spark.adb (Expand_SPARK_Call): Remove procedure.
13561         * opt.adb, opt.ads (Full_Expander_Active): Remove function.
13562         * checks.adb, exp_ch6.adb, exp_ch9.adb, exp_disp.adb, sem_aggr.adb,
13563         * sem_ch10.adb, sem_ch5.adb, sem_ch6.adb, sem_ch8.adb, sem_ch9.adb,
13564         * sem_disp.adb, sem_res.adb Replace Full_Expander_Active by
13565         Expander_Active.
13567 2014-01-20  Yannick Moy  <moy@adacore.com>
13569         * sinfo.ads Update documentation of GNATprove mode.
13571 2014-01-20  Yannick Moy  <moy@adacore.com>
13573         * adabkend.adb, ali-util.adb, errout.adb, exp_ch7.adb,
13574         * exp_dbug.adb, freeze.adb, lib-xref.adb, restrict.adb,
13575         * sem_attr.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb, sem_ch8.adb,
13576         * sem_prag.adb, sem_res.adb, sem_util.adb Rename SPARK_Mode into
13577         GNATprove_Mode.
13578         * sem_ch13.adb: Remove blank.
13579         * exp_spark.adb, exp_spark.ads (Expand_SPARK_Call): Only replace
13580         subprograms by alias for renamings, not for inherited primitive
13581         operations.
13582         * exp_util.adb (Expand_Subtype_From_Expr): Apply the expansion
13583         in GNATprove mode.
13584         (Remove_Side_Effects): Apply the removal in
13585         GNATprove mode, for the full analysis of expressions.
13586         * expander.adb (Expand): Call the light SPARK expansion in GNATprove
13587         mode.
13588         (Expander_Mode_Restore, Expander_Mode_Save_And_Set): Ignore
13589         save/restore actions for Expander_Active flag in GNATprove mode,
13590         similar to what is done in ASIS mode.
13591         * frontend.adb (Frontend): Generic bodies are instantiated in
13592         GNATprove mode.
13593         * gnat1drv.adb (Adjust_Global_Switches): Set operating
13594         mode to Check_Semantics in GNATprove mode, although a light
13595         expansion is still performed.
13596         (Gnat1drv): Set Back_End_Mode to
13597         Declarations_Only in GNATprove mode, and later on special case
13598         the GNATprove mode to continue analysis anyway.
13599         * lib-writ.adb (Write_ALI): Always generate ALI files in
13600         GNATprove mode.
13601         * opt.adb, opt.ads (Full_Expander_Active): Make it equivalent to
13602         Expander_Active.
13603         (SPARK_Mode): Renamed as GNATprove_Mode.
13604         * sem_aggr.adb (Aggregate_Constraint_Checks): Add checks in the
13605         tree in GNATprove_Mode.
13606         * sem_ch12.adb (Analyze_Package_Instantiation): Always instantiate
13607         body in GNATprove mode.
13608         (Need_Subprogram_Instance_Body): Always instantiate body in GNATprove
13609         mode.
13610         * sem_ch3.adb (Constrain_Index, Process_Range_Expr_In_Decl):
13611         Make sure side effects are removed in GNATprove mode.
13613 2014-01-20  Eric Botcazou  <ebotcazou@adacore.com>
13615         * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Robustify tests
13616         for aliased objects with an unconstrained nominal subtype.
13617         * gcc-interface/trans.c (Call_to_gnu): Likewise.
13618         (gnat_to_gnu) <case N_Op_Not>: Robustify test for private type.
13619         <case N_Op_Minus>: Remove useless code.
13620         (Exception_Handler_to_gnu_zcx): Minor tweaks.
13622 2014-01-20  Eric Botcazou  <ebotcazou@adacore.com>
13624         * gcc-interface/decl.c (gnat_to_gnu_entity) <case E_Record_Subtype>:
13625         Tidy up.  For a subtype with discriminants and variant part, if a
13626         variant is statically selected and the fields all have a constant
13627         position, put them in order of increasing position.  Likewise if
13628         no variant part but representation clause is present.
13629         * gcc-interface/utils.c (make_packable_type): Robustify.
13630         (maybe_pad_type): Use local variable and tidy up condition.  If no
13631         alignment is specified, use the original one.
13632         (create_type_stub_decl): Minor tweak.
13633         (convert) <case VECTOR_CST>: Fix typo.
13634         <case CONSTRUCTOR>: Deal with padding types around the same type.
13635         Do not punt on missing fields.
13636         (unchecked_convert): Call finish_record_type to lay out the special
13637         record types made for conversions from/to problematic integer types.
13638         Bump the alignment of CONSTRUCTORs before converting them to a more
13639         aligned type.
13641 2014-01-20  Eric Botcazou  <ebotcazou@adacore.com>
13643         * gcc-interface/decl.c (gnat_to_gnu_entity) <case E_Component>: Remove
13644         obsolete code for type_annotate_only mode, simplify code and slightly
13645         improve wording of comments.
13647 2014-01-12  Eric Botcazou  <ebotcazou@adacore.com>
13649         PR ada/59772
13650         * gcc-interface/cuintp.c (build_cst_from_int): Use 32-bit integer type
13651         as intermediate type.
13652         (UI_To_gnu): Likewise.
13654 2014-01-03  Eric Botcazou  <ebotcazou@adacore.com>
13656         * gnatvsn.ads (Current_Year): Bump to 2014.
13658 2014-01-02  Tobias Burnus  <burnus@net-b.de>
13660         * gnat_ugn.texi: Bump @copying's copyright year.
13662 Copyright (C) 2014 Free Software Foundation, Inc.
13664 Copying and distribution of this file, with or without modification,
13665 are permitted in any medium without royalty provided the copyright
13666 notice and this notice are preserved.