2015-01-30 Jerome Guitton <guitton@adacore.com>
[official-gcc.git] / gcc / ada / ChangeLog
blob74279b19742ecda3184b48cf1756f38e87f940b3
1 2015-01-30  Jerome Guitton  <guitton@adacore.com>
3         * gcc-interface/Makefile.in (x86-vxworks): Update GCC_SPEC_FILES to
4         include cert link spec.
6 2015-01-30  Robert Dewar  <dewar@adacore.com>
8         * einfo.ads: Minor comment fix.
9         * freeze.adb (Freeze_Profile): Add test for suspicious import
10         in pure unit.
11         * sem_prag.adb (Process_Import_Or_Interface): Test for suspicious
12         use in Pure unit is now moved to Freeze (to properly catch
13         Pure_Function exemption).
15 2015-01-30  Bob Duff  <duff@adacore.com>
17         * sem_res.ads: Minor comment fix.
18         * sem_type.adb: sem_type.adb (Remove_Conversions): Need to
19         check both operands of an operator.
21 2015-01-30  Yannick Moy  <moy@adacore.com>
23         * a-assert.ads, a-assert.adb: Mark package spec in SPARK. Set assertion
24         policy for Pre to Ignore.
25         (Assert): Add precondition.
27 2015-01-30  Robert Dewar  <dewar@adacore.com>
29         * sem_prag.adb (Process_Import_Or_Interface): Warn if used in
30         Pure unit.
31         * s-valllu.ads (Scan_Raw_Long_Long_Unsigned): Clarify
32         documentation for some special cases of invalid attempts at
33         based integers.
35 2015-01-30  Gary Dismukes  <dismukes@adacore.com>
37         * errout.ads: Minor reformatting.
39 2015-01-30  Yannick Moy  <moy@adacore.com>
41         * inline.adb (Process_Formals): Use the sloc of
42         the inlined node instead of the sloc of the actual parameter,
43         when replacing formal parameters by the actual one.
45 2015-01-30  Arnaud Charlet  <charlet@adacore.com>
47         * g-expect.adb (Get_Command_Output): Use infinite timeout when
48         calling Expect.
50 2015-01-30  Ed Schonberg  <schonberg@adacore.com>
52         * sem_ch12.adb (Analyze_Associations): If an in-parameter is
53         defaulted in an instantiation, add an entry in the list of actuals
54         to indicate the default value of the formal (as is already done
55         for defaulted subprograms).
57 2015-01-30  Javier Miranda  <miranda@adacore.com>
59         * errout.adb (Error_Msg_PT): Minor error phrasing update.
61 2015-01-30  Robert Dewar  <dewar@adacore.com>
63         * sem_warn.adb (Warn_On_Known_Condition): Improve error message
64         for object case.
66 2015-01-30  Pierre-Marie de Rodat  <derodat@adacore.com>
68         * exp_dbug.adb (Get_Encoded_Name): When
69         -fgnat-encodings=minimal, do not generate names for biased types.
71 2015-01-30  Tristan Gingold  <gingold@adacore.com>
73         PR ada/64349
74         * env.c: Move vxworks and darwin includes out of #ifdef IN_RTS.
76 2015-01-30  Gary Dismukes  <dismukes@adacore.com>
78         * freeze.adb: Minor reformatting.
80 2015-01-30  Javier Miranda  <miranda@adacore.com>
82         * errout.ads (Error_Msg_PT): Replace Node_Id by Entity_Id and
83         improve its documentation.
84         * errout.adb (Error_Msg_PT): Improve the error message.
85         * sem_ch6.adb (Check_Conformance): Update call to Error_Msg_PT.
86         (Check_Synchronized_Overriding): Update call to Error_Msg_PT.
87         * sem_ch3.adb (Check_Abstract_Overriding): Code cleanup.
89 2015-01-30  Robert Dewar  <dewar@adacore.com>
91         * sem_warn.adb (Warn_On_Known_Condition): Do special casing of
92         message for False case.
94 2015-01-30  Doug Rupp  <rupp@adacore.com>
96         * s-vxwext-kernel.ads (Task_Cont): Remove imported subprogram body.
97         * s-vxwext-kernel.adb (Task_Cont): New subpprogram body specialized for
98         kernel.
100 2015-01-30  Gary Dismukes  <dismukes@adacore.com>
102         * sem_attr.adb (Declared_Within_Generic_Unit):
103         New function to test whether an entity is declared within the
104         declarative region of a given generic unit.
105         (Resolve_Attribute): For checking legality of subprogram'Access within
106         a generic unit, call new Boolean function Declared_Within_Generic_Unit
107         instead of simply comparing the results of Enclosing_Generic_Unit on
108         the prefix and access type.  Correct minor comment typos.
110 2015-01-30  Robert Dewar  <dewar@adacore.com>
112         * freeze.adb, exp_util.ads: Update comment.
113         * exp_util.adb, exp_ch3.adb: Minor code reorganization and reformatting.
114         * sem_util.adb: Minor: fix typo.
116 2015-01-30  Hristian Kirtchev  <kirtchev@adacore.com>
118         * sem_attr.adb (Analyze_Attribute): Ensure that
119         the check concerning Refined_Post takes precedence over the
120         other cases.
122 2015-01-30  Gary Dismukes  <dismukes@adacore.com>
124         * sem_prag.adb: Minor typo fixes and reformatting.
126 2015-01-30  Yannick Moy  <moy@adacore.com>
128         * sem_attr.adb: Code clean up.
130 2015-01-30  Robert Dewar  <dewar@adacore.com>
132         * ali.adb (Scan_ALI): Set Serious_Errors flag in Unit record.
133         * ali.ads (Unit_Record): Add new field Serious_Errors.
134         * lib-writ.adb (Write_Unit_Information): Set SE (serious errors)
135         attribute in U line.
136         * lib-writ.ads: New attribute SE (serious erors) in unit line.
138 2015-01-30  Hristian Kirtchev  <kirtchev@adacore.com>
140         * einfo.adb Update the usage of attributes Entry_Bodies_Array,
141         Lit_Indexes, Scale_Value, Storage_Size_Variable,
142         String_Literal_Low_Bound along associated routines and
143         Write_FieldX_Name.
144         (Pending_Access_Types): New routine.
145         (Set_Pending_Access_Types): New routine.
146         (Write_Field15_Name): Add an entry for Pending_Access_Types.
147         * einfo.ads Add new attribute Pending_Access_Types along
148         with usage in nodes.  Update the usage of attributes
149         Entry_Bodies_Array, Lit_Indexes, Scale_Value,
150         Storage_Size_Variable, String_Literal_Low_Bound.
151         (Pending_Access_Types): New routine along with pragma Inline.
152         (Set_Pending_Access_Types): New routine along with pragma Inline.
153         * exp_ch3.adb (Expand_Freeze_Array_Type): Add new local variable
154         Ins_Node. Determine the insertion node for anonynous access type
155         that acts as a component type of an array. Update the call to
156         Build_Finalization_Master.
157         (Expand_Freeze_Record_Type): Update
158         the calls to Build_Finalization_Master.
159         (Freeze_Type): Remove
160         local variable RACW_Seen. Factor out the code that deals with
161         remote access-to-class-wide types. Create a finalization master
162         when the designated type contains a private component. Fully
163         initialize all pending access types.
164         (Process_RACW_Types): New routine.
165         (Process_Pending_Access_Types): New routine.
166         * exp_ch4.adb (Expand_Allocator_Expression): Allocation no longer
167         needs to set primitive Finalize_Address.
168         (Expand_N_Allocator): Allocation no longer sets primitive
169         Finalize_Address.
170         * exp_ch6.adb (Add_Finalization_Master_Actual_To_Build_In_Place_Call):
171         Update the call to Build_Finalization_Master.
172         (Make_Build_In_Place_Call_In_Allocator): Allocation no longer
173         needs to set primitive Finalize_Address.
174         * exp_ch7.adb (Add_Pending_Access_Type): New routine.
175         (Build_Finalization_Master): New parameter profile. Associate
176         primitive Finalize_Address with the finalization master if the
177         designated type has been frozen, otherwise treat the access
178         type as pending. Simplify the insertion of the master and
179         related initialization code.
180         (Make_Finalize_Address_Body): Allow Finalize_Address for class-wide
181         abstract types.
182         (Make_Set_Finalize_Address_Call): Remove forlam parameter Typ.
183         Simplify the implementation.
184         * exp_ch7.ads (Build_Finalization_Master): New parameter profile
185         along with comment on usage.
186         (Make_Set_Finalize_Address_Call): Remove formal parameter Typ. Update
187         the comment on usage.
188         * exp_util.adb (Build_Allocate_Deallocate_Proc): Use routine
189         Finalize_Address to retrieve the primitive.
190         (Finalize_Address): New routine.
191         (Find_Finalize_Address): Removed.
192         * exp_util.ads (Finalize_Address): New routine.
193         * freeze.adb (Freeze_All): Remove the generation of finalization
194         masters.
195         * sem_ch3.adb (Analyze_Full_Type_Declaration): Propagate any
196         pending access types from the partial to the full view.
198 2015-01-30  Robert Dewar  <dewar@adacore.com>
200         * sem_disp.adb: Minor reformatting.
201         * sem_disp.ads: Documentation update.
203 2015-01-30  Ed Schonberg  <schonberg@adacore.com>
205         * sem_disp.adb (Is_Dynamically_Tagged): when applied to an entity
206         or a function call, return True if type is class-wide.
207         * sem_res.adb (Resolve_Case_Expression, Resolve_If_Expression);
208         Apply RM 4.5.7 (17/3): all or none of the dependent expression
209         of a conditional expression must be dynamically tagged.
211 2015-01-30  Ed Schonberg  <schonberg@adacore.com>
213         * sem_ch6.adb (Analyze_Function_Return): In an extended return
214         statement, apply accessibility check to result object when there
215         is no initializing expression (Ada 2012 RM 6.5 (5.4/3))
217 2015-01-30  Robert Dewar  <dewar@adacore.com>
219         * sem_ch4.adb (Analyze_If_Expression): Allow for non-standard
220         Boolean for case where ELSE is omitted.
221         * sem_res.adb: Minor reformatting.
223 2015-01-27  Bernd Edlinger  <bernd.edlinger@hotmail.de>
225         Fix build under cygwin/64.
226         * adaint.h: Add check for __CYGWIN__.
227         * mingw32.h: Prevent windows.h from including x86intrin.h in GCC.
229 2015-01-19  Bernd Edlinger  <bernd.edlinger@hotmail.de>
231         PR ada/64640
232         * adaint.c: Handle __CYGWIN__ like __MINGW32__ here.
233         * mingw32.h: Don't include <tchar.h> under cygwin.
234         (_O_U8TEXT, _O_U16TEXT, _O_WTEXT): Set to _O_TEXT if not yet defined.
236 2015-01-15  Thomas Schwinge  <thomas@codesourcery.com>
238         * gcc-interface/utils.c (DEF_FUNCTION_TYPE_VAR_8)
239         (DEF_FUNCTION_TYPE_VAR_12): New macros.
241 2015-01-09  Michael Collison  <michael.collison@linaro.org>
243         * gcc-interface/cuintp.c: Include hash-set.h, machmode.h,
244         vec.h, double-int.h, input.h, alias.h, symtab.h,
245         fold-const.h, wide-int.h, and inchash.h due to
246         flattening of tree.h.
247         * gcc-interface/decl.c: Ditto.
248         * gcc-interface/misc.c: Ditto.
249         * gcc-interface/targtyps.c: Include hash-set.h, machmode.h,
250         vec.h, double-int.h, input.h, alias.h, symtab.h, options.h,
251         fold-const.h, wide-int.h, and inchash.h due to
252         flattening of tree.h.
253         * gcc-interface/trans.c: Include hash-set.h, machmode.h,
254         vec.h, double-int.h, input.h, alias.h, symtab.h, real.h,
255         fold-const.h, wide-int.h, inchash.h due to
256         flattening of tree.h.
257         * gcc-interface/utils.c: Include hash-set.h, machmode.h,
258         vec.h, double-int.h, input.h, alias.h, symtab.h,
259         fold-const.h, wide-int.h, and inchash.h due to
260         flattening of tree.h.
261         * gcc-interface/utils2.c: Ditto.
263 2015-01-07  Robert Dewar  <dewar@adacore.com>
265         * sem_warn.adb (Check_One_Unit): Don't give unused entities
266         warning for a package which is used as a generic parameter.
268 2015-01-07  Bob Duff  <duff@adacore.com>
270         * usage.adb (Usage): Correct documentation of
271         -gnatw.f switches.
273 2015-01-07  Robert Dewar  <dewar@adacore.com>
275         * s-fileio.adb: Minor reformatting.
277 2015-01-07  Ed Schonberg  <schonberg@adacore.com>
279         * sem_ch12.adb (Instantiate_Object): If formal is an anonymous
280         access to subprogram, replace its formals with new entities when
281         building the object declaration, both if actual is present and
282         when it is defaulted.
284 2015-01-07  Ed Schonberg  <schonberg@adacore.com>
286         * sem_ch5.adb (Analyze_Assignment): If left-hand side is a view
287         conversion and type of expression has invariant, apply invariant
288         check on expression.
290 2015-01-07  Ed Schonberg  <schonberg@adacore.com>
292         * sem_ch3.adb (Create_Constrained_Components): A call to
293         Gather_Components may detect an error if an inherited discriminant
294         that controls a variant is non-static.
295         * sem_aggr.adb (Resolve_Record_Aggregate, Step 5): The call to
296         Gather_Components may report an error if an inherited discriminant
297         in a variant in non-static.
298         * sem_util.adb (Gather_Components): If a non-static discriminant
299         is inherited do not report error here, but let caller handle it.
300         (Find_Actual): Small optimization.
302 2015-01-07  Bob Duff  <duff@adacore.com>
304         * usage.adb (Usage): Document -gnatw.f switch.
306 2015-01-07  Ed Schonberg  <schonberg@adacore.com>
308         * sem_ch12.adb: Code clean up and minor reformatting.
310 2015-01-07  Robert Dewar  <dewar@adacore.com>
312         * exp_ch4.adb (Expand_N_Type_Conversion): Add guard for
313         Raise_Accessibility_Error call.
314         * s-valllu.ads (Scan_Raw_Long_Long_Unsigned): Add documentation
315         on handling of invalid digits in based constants.
316         * s-fatgen.ads: Minor reformatting.
317         * sem_attr.adb (Analyze_Attribute, case Unrestricted_Access):
318         Avoid noting bogus modification for Valid test.
319         * snames.ads-tmpl (Name_Attr_Long_Float): New Name.
320         * einfo.ads: Minor reformatting.
321         * sem_warn.adb: Minor comment clarification.
322         * sem_ch12.adb: Minor reformatting.
324 2015-01-07  Ed Schonberg  <schonberg@adacore.com>
326         * exp_ch5.adb (Expand_Predicated_Loop): Handle properly loops
327         over static predicates when the loop parameter specification
328         carries a Reverse indicator.
330 2015-01-07  Ed Schonberg  <schonberg@adacore.com>
332         * sem_ch12.adb (Instantiate_Object): If formal has a default,
333         actual is missing and formal has an anonymous access type, copy
334         access definition in full so that tree for instance is properly
335         formatted for ASIS use.
337 2015-01-07  Bob Duff  <duff@adacore.com>
339         * sem_elab.adb (Check_Internal_Call_Continue): Give a warning
340         for P'Access, where P is a subprogram in the same package as
341         the P'Access, and the P'Access is evaluated at elaboration
342         time, and occurs before the body of P. For example, "X : T :=
343         P'Access;" would allow a subsequent call to X.all to be an
344         access-before-elaboration error; hence the warning. This warning
345         is enabled by the -gnatw.f switch.
346         * opt.ads (Warn_On_Elab_Access): New flag for warning switch.
347         * warnsw.adb (Set_Dot_Warning_Switch): Set Warn_On_Elab_Access.
348         * gnat_ugn.texi: Document the new warning.
350 2015-01-07  Johannes Kanig  <kanig@adacore.com>
352         * lib-xref-spark_specific.adb (Collect_SPARK_Xrefs): Skip unneeded
353         cross ref files.
355 2015-01-07  Robert Dewar  <dewar@adacore.com>
357         * s-taprop-linux.adb, clean.adb: Minor reformatting.
359 2015-01-07  Arnaud Charlet  <charlet@adacore.com>
361         * s-tassta.adb: Relax some overzealous assertions.
363 2015-01-07  Ed Schonberg  <schonberg@adacore.com>
365         * sem_ch6.adb (Analyze_Return_Type): An call that returns a limited
366         view of a type is legal when context is a thunk generated for
367         operation inherited from an interface.
368         * exp_ch6.adb (Expand_Simple_Function_Return): If context is
369         a thunk and return type is an incomplete type do not continue
370         expansion; thunk will be fully elaborated when generating code.
372 2015-01-07  Doug Rupp  <rupp@adacore.com>
374         * s-osinte-mingw.ads (LARGE_INTEGR): New subtype.
375         (QueryPerformanceFrequency): New imported procedure.
376         * s-taprop-mingw.adb (RT_Resolution): Call above and return
377         resolution vice a hardcoded value.
378         * s-taprop-solaris.adb (RT_Resolution): Call clock_getres and return
379         resolution vice a hardcoded value.
380         * s-linux-android.ads (clockid_t): New subtype.
381         * s-osinte-aix.ads (clock_getres): New imported subprogram.
382         * s-osinte-android.ads (clock_getres): Likewise.
383         * s-osinte-freebsd.ads (clock_getres): Likewise.
384         * s-osinte-solaris-posix.ads (clock_getres): Likewise.
385         * s-osinte-darwin.ads (clock_getres): New subprogram.
386         * s-osinte-darwin.adb (clock_getres): New subprogram.
387         * thread.c (__gnat_clock_get_res) [__APPLE__]: New function.
388         * s-taprop-posix.adb (RT_Resolution): Call clock_getres to
389         calculate resolution vice hard coded value.
391 2015-01-07  Ed Schonberg  <schonberg@adacore.com>
393         * exp_util.adb (Make_CW_Equivalent_Type): If root type is a
394         limited view, use non-limited view when available to create
395         equivalent record type.
397 2015-01-07  Vincent Celier  <celier@adacore.com>
399         * gnatcmd.adb: Remove command Sync and any data and processing
400         related to this command. Remove project processing for gnatstack.
401         * prj-attr.adb: Remove package Synchonize and its attributes.
403 2015-01-07  Vincent Celier  <celier@adacore.com>
405         * clean.adb: Minor error message change.
407 2015-01-07  Tristan Gingold  <gingold@adacore.com>
409         PR ada/64349  
410         * env.c (__gnat_environ): Adjust for darwin9/darwin10.
412 2015-01-07  Javier Miranda  <miranda@adacore.com>
414         * sem_ch10.adb (Analyze_With_Clause): Compiling under -gnatq
415         protect the frontend against never ending recursion caused by
416         circularities in the sources.
418 2015-01-07  Robert Dewar  <dewar@adacore.com>
420         * a-reatim.adb, make.adb, exp_pakd.adb, i-cpoint.adb, sem_ch8.adb,
421         exp_ch3.adb: Minor reformatting.
423 2015-01-07  Doug Rupp  <rupp@adacore.com>
425         * s-linux.ads (clockid_t): New subtype.
426         * s-osinte-linux.ads (pragma Linker Options): Add -lrt.
427         (clockid_t): New subtype.
428         (clock_getres): Import system call.
429         * s-taprop-linux.adb (System.OS_Constants): With and rename.
430         (RT_Resolution): Remove
431         hardcoded value and call clock_getres.
432         * s-linux-sparc.ads, s-linux-mipsel.ads, s-linux-hppa.ads,
433         s-linux-alpha.ads, s-linux-x32.ads (clockid_t): Add new subtype.
435 2015-01-07  Robert Dewar  <dewar@adacore.com>
437         * sem_warn.adb (Check_One_Unit): Guard against context item
438         with no Entity field.
440 2015-01-07  Vincent Celier  <celier@adacore.com>
442         * clean.adb (Gnatclean): Warn that 'gnatclean -P' is obsolete.
443         * make.adb (Initialize): Warn that 'gnatmake -P' is obsolete.
445 2015-01-07  Vincent Celier  <celier@adacore.com>
447         * prj-conf.adb (Parse_Project_And_Apply_Config): Always finalize
448         errors/warnings in the first parsing of the project files,
449         to display the warnings when there is no errors.
451 2015-01-07  Tristan Gingold  <gingold@adacore.com>
453         * i-cpoint.adb (Copy_Terminated_Array): Nicely handle null target.
455 2015-01-07  Doug Rupp  <rupp@adacore.com>
457         * s-taprop-vxworks.adb (Stop_All_Tasks): Pass return
458         value from Int_Lock as parameter to Int_Unlock.
459         * s-osinte-vxworks.ads (Int_Unlock): Add parameter.
460         * s-vxwext.ads (Int_Unlock): Likewise.
461         * s-vxwext-kernel.adb (intUnlock, Int_Unlock): Likewise.
462         * s-vxwext-kernel.ads (Int_Unlock): Likewise.
463         * s-vxwext-rtp.adb (Int_Unlock): Likewise.
464         * s-vxwext-rtp.ads (Int_Unlock): Likewise.
466 2015-01-07  Pierre-Marie de Rodat  <derodat@adacore.com>
468         * exp_pakd.adb: Add a comment in exp_pakd.adb to explain why we
469         keep ___XP suffixes
471 2015-01-07  Tristan Gingold  <gingold@adacore.com>
473         * i-cpoint.adb (Copy_Terminated_Array): Use Copy_Array to
474         handle overlap.
476 2015-01-07  Eric Botcazou  <ebotcazou@adacore.com>
478         * sem_ch3.adb (Analyze_Full_Type_Declaration): Do not
479         automatically set No_Strict_Aliasing on access types.
480         * fe.h (No_Strict_Aliasing_CP): Declare.
481         * gcc-interface/trans.c (gigi): Force flag_strict_aliasing to 0 if
482         No_Strict_Aliasing_CP is set.
484 2015-01-07  Johannes Kanig  <kanig@adacore.com>
486         * sem_ch8.adb (Analyze_Subprogram_Renaming) do
487         not build function wrapper in gnatprove mode when the package
488         is externally axiomatized.
490 2015-01-07  Jose Ruiz  <ruiz@adacore.com>
492         * a-reatim.adb (Time_Of): Reduce the number of spurious overflows in
493         intermediate computations when the parameters have different signs.
495 2015-01-07  Javier Miranda  <miranda@adacore.com>
497         * exp_ch3.adb (Build_Init_Procedure): For derived types,
498         improve the code which takes care of identifying and moving to
499         the beginning of the init-proc the call to the init-proc of the
500         parent type.
502 2015-01-07  Olivier Hainque  <hainque@adacore.com>
504         * gcc-interface/trans.c (gnat_to_gnu, <N_Expression_With_Action>):
505         Elaborate the expression as part of the same stmt group as the actions.
507 2015-01-07  Robert Dewar  <dewar@adacore.com>
509         * sem_ch3.adb: Minor error message change.
511 2015-01-07  Ed Schonberg  <schonberg@adacore.com>
513         * sem_prag.adb (Analyze_Pragma, case Preelaborable_Initialization):
514         Following AI05-028, the pragam applies legally to any composite type.
516 2015-01-07  Arnaud Charlet  <charlet@adacore.com>
518         * s-osinte-vxworks.adb, s-osinte-vxworks.ads
519         (sigwait, sigwaitinfo): Removed, not needed after all on any
520         VxWorks configurations.
522 2015-01-07  Robert Dewar  <dewar@adacore.com>
524         * sem_ch3.adb, freeze.adb, exp_disp.adb: Minor reformatting.
526 2015-01-07  Javier Miranda  <miranda@adacore.com>
528         * exp_disp.adb (Expand_Interface_Conversion): Adding missing
529         generation of accessibility check.
531 2015-01-07  Ed Schonberg  <schonberg@adacore.com>
533         * sem_ch3.adb (Derived_Type_Declaration): In the case of an
534         illegal completion from a class- wide type, set etype of the
535         derived type properly to prevent cascaded errors.
537 2015-01-07  Robert Dewar  <dewar@adacore.com>
539         * prj.ads, i-cpoint.adb, freeze.adb, ghost.adb, prj-err.adb: Minor
540         reformatting.
542 2015-01-07  Robert Dewar  <dewar@adacore.com>
544         * restrict.adb (Check_Restriction_No_Use_Of_Attribute):
545         New procedure.
546         (OK_No_Use_Of_Entity_Name): New function.
547         (Set_Restriction_No_Use_Of_Entity): New procedure.
548         * restrict.ads (Check_Restriction_No_Use_Of_Attribute):
549         New procedure.
550         (OK_No_Use_Of_Entity_Name): New function.
551         (Set_Restriction_No_Use_Of_Entity): New procedure.
552         * sem_ch8.adb (Find_Direct_Name): Add check for violation of
553         No_Use_Of_Entity.
554         * sem_prag.adb (Process_Restrictions_Or_Restriction_Warnings):
555         Add processing for new restriction No_Use_Of_Entity.
557 2015-01-07  Eric Botcazou  <ebotcazou@adacore.com>
559         * freeze.adb (Freeze_Array_Type): Apply same handling to Is_Atomic
560         component type as to Has_Atomic_Components type.  Remove useless
561         test on Is_Aliased component type.
563 2015-01-07  Hristian Kirtchev  <kirtchev@adacore.com>
565         * alloc.ads Alphabetize several declarations. Add constants
566         Ignored_Ghost_Units_Initial and Ignored_Ghost_Units_Increment.
567         * atree.adb Add with and use clauses for Opt.
568         (Allocate_Initialize_Node): Mark a node as ignored Ghost
569         if it is created in an ignored Ghost region.
570         (Ekind_In): New variant.
571         (Is_Ignored_Ghost_Node): New routine.
572         (Set_Is_Ignored_Ghost_Node): New routine.
573         * atree.adb Aplhabetize several subprograms declarations. Flag
574         Spare0 is now known as Is_Ignored_Ghost_Node.
575         (Ekind_In): New variant.
576         (Is_Ignored_Ghost_Node): New routine.
577         (Set_Is_Ignored_Ghost_Node): New routine.
578         * einfo.adb: Flag 279 is now known as Contains_Ignored_Ghost_Code.
579         (Contains_Ignored_Ghost_Code): New routine.
580         (Set_Contains_Ignored_Ghost_Code): New routine.
581         (Set_Is_Checked_Ghost_Entity, Set_Is_Ignored_Ghost_Entity):
582         It is now possible to set this property on an unanalyzed entity.
583         (Write_Entity_Flags): Output the status of flag
584         Contains_Ignored_Ghost_Code.
585         * einfo.ads New attribute Contains_Ignored_Ghost_Code along with
586         usage in nodes.
587         (Contains_Ignored_Ghost_Code): New routine
588         along with pragma Inline.
589         (Set_Contains_Ignored_Ghost_Code): New routine along with pragma Inline.
590         * exp_ch3.adb Add with and use clauses for Ghost.
591         (Freeze_Type): Capture/restore the value of Ghost_Mode on entry/exit.
592         Set the Ghost_Mode in effect.
593         (Restore_Globals): New routine.
594         * exp_ch7.adb (Process_Declarations): Do not process a context
595         that invoves an ignored Ghost entity.
596         * exp_dbug.adb (Qualify_All_Entity_Names): Skip an ignored Ghost
597         construct that has been rewritten as a null statement.
598         * exp_disp.adb Add with and use clauses for Ghost.
599         (Make_DT): Capture/restore the value of Ghost_Mode on entry/exit. Set
600         the Ghost_Mode in effect.
601         (Restore_Globals): New routine.
602         * exp_util.adb (Requires_Cleanup_Actions): An ignored Ghost entity
603         does not require any clean up. Add two missing cases that deal
604         with block statements.
605         * freeze.adb Add with and use clauses for Ghost.
606         (Freeze_Entity): Capture/restore the value of Ghost_Mode on entry/exit.
607         Set the Ghost_Mode in effect.
608         (Restore_Globals): New routine.
609         * frontend.adb Add with and use clauses for Ghost. Remove any
610         ignored Ghost code from all units that qualify.
611         * ghost.adb New unit.
612         * ghost.ads New unit.
613         * gnat1drv.adb Add with clause for Ghost. Initialize and lock
614         the table in package Ghost.
615         * lib.ads: Alphabetize several subprogram declarations.
616         * lib-xref.adb (Output_References): Do not generate reference
617         information for ignored Ghost entities.
618         * opt.ads Add new type Ghost_Mode_Type and new global variable
619         Ghost_Mode.
620         * rtsfind.adb (Load_RTU): Provide a clean environment when
621         loading a runtime unit.
622         * sem.adb (Analyze): Capture/restore the value of Ghost_Mode on
623         entry/exit as the node may set a different mode.
624         (Do_Analyze):
625         Capture/restore the value of Ghost_Mode on entry/exit as the
626         unit may be withed from a unit with a different Ghost mode.
627         * sem_ch3.adb Add with and use clauses for Ghost.
628         (Analyze_Full_Type_Declaration, Analyze_Incomplete_Type_Decl,
629         Analyze_Number_Declaration, Analyze_Private_Extension_Declaration,
630         Analyze_Subtype_Declaration): Set the Ghost_Mode in effect. Mark
631         the entity as Ghost when there is a Ghost_Mode in effect.
632         (Array_Type_Declaration): The implicit base type inherits the
633         "ghostness" from the array type.
634         (Derive_Subprogram): The
635         alias inherits the "ghostness" from the parent subprogram.
636         (Make_Implicit_Base): The implicit base type inherits the
637         "ghostness" from the parent type.
638         * sem_ch5.adb Add with and use clauses for Ghost.
639         (Analyze_Assignment): Set the Ghost_Mode in effect.
640         * sem_ch6.adb Add with and use clauses for Ghost.
641         (Analyze_Abstract_Subprogram_Declaration, Analyze_Procedure_Call,
642         Analyze_Subprogram_Body_Helper, Analyze_Subprogram_Declaration):
643         Set the Ghost_Mode in effect. Mark the entity as Ghost when
644         there is a Ghost_Mode in effect.
645         * sem_ch7.adb Add with and use clauses for Ghost.
646         (Analyze_Package_Body_Helper, Analyze_Package_Declaration,
647         Analyze_Private_Type_Declaration): Set the Ghost_Mode in
648         effect. Mark the entity as Ghost when there is a Ghost_Mode
649         in effect.
650         * sem_ch8.adb Add with and use clauses for Ghost.
651         (Analyze_Exception_Renaming, Analyze_Generic_Renaming,
652         Analyze_Object_Renaming, Analyze_Package_Renaming,
653         Analyze_Subprogram_Renaming): Set the Ghost_Mode in effect. Mark
654         the entity as Ghost when there is a Ghost_Mode in effect.
655         (Find_Type): Check the Ghost context of a type.
656         * sem_ch11.adb Add with and use clauses for Ghost.
657         (Analyze_Exception_Declaration): Set the Ghost_Mode in
658         effect. Mark the entity as Ghost when there is a Ghost_Mode
659         in effect.
660         * sem_ch12.adb Add with and use clauses for Ghost.
661         (Analyze_Generic_Package_Declaration,
662         Analyze_Generic_Subprogram_Declaration): Set the Ghost_Mode in effect.
663         Mark the entity as Ghost when there is a Ghost_Mode in effect.
664         * sem_prag.adb Add with and use clauses for Ghost.
665         (Analyze_Pragma): Ghost-related checks are triggered when there
666         is a Ghost mode in effect.
667         (Create_Abstract_State): Mark the
668         entity as Ghost when there is a Ghost_Mode in effect.
669         * sem_res.adb Add with and use clauses for Ghost.
670         (Check_Ghost_Context): Removed.
671         * sem_util.adb (Check_Ghost_Completion): Removed.
672         (Check_Ghost_Derivation): Removed.
673         (Incomplete_Or_Partial_View):
674         Add a guard in case the entity has not been analyzed yet
675         and does carry a scope.
676         (Is_Declaration): New routine.
677         (Is_Ghost_Entity): Removed.
678         (Is_Ghost_Statement_Or_Pragma):
679         Removed.
680         (Is_Subject_To_Ghost): Removed.
681         (Set_Is_Ghost_Entity):
682         Removed.
683         (Within_Ghost_Scope): Removed.
684         * sem_util.adb (Check_Ghost_Completion): Removed.
685         (Check_Ghost_Derivation): Removed.
686         (Is_Declaration): New routine.
687         (Is_Ghost_Entity): Removed.
688         (Is_Ghost_Statement_Or_Pragma): Removed.
689         (Is_Subject_To_Ghost): Removed.
690         (Set_Is_Ghost_Entity): Removed.
691         (Within_Ghost_Scope): Removed.
692         * sinfo.ads Add a section on Ghost mode.
693         * treepr.adb (Print_Header_Flag): New routine.
694         (Print_Node_Header): Factor out code. Output flag
695         Is_Ignored_Ghost_Node.
696         * gcc-interface/Make-lang.in: Add dependency for unit Ghost.
698 2015-01-06  Eric Botcazou  <ebotcazou@adacore.com>
700         * freeze.adb (Freeze_Array_Type) <Complain_CS>: Remove always
701         true test and unreachable 'else' arm.
703 2015-01-06  Vincent Celier  <celier@adacore.com>
705         * prj-conf.adb (Check_Target): Improve error message when
706         there are mismatched targets between the on in the configuration
707         project file and the specified one, either in the main project
708         file or in the --target= switch.
710 2015-01-06  Pascal Obry  <obry@adacore.com>
712         * prj-attr.adb, projects.texi, snames.ads-tmpl: Add Mode and
713         Install_Name attribute definitions.
715 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
717         * freeze.adb (Wrap_Imported_Subprogram): Indicate that the
718         generated Import pragma for the internal imported procedure does
719         not come from an aspect, so that Is_Imported can be properly
720         set for it.
722 2015-01-06  Gary Dismukes  <dismukes@adacore.com>
724         * sem_ch12.adb (Might_Inline_Subp): Record whether
725         any subprograms in the generic package are marked with
726         pragma Inline_Always (setting flag Has_Inline_Always).
727         (Analyze_Package_Instantiation): Add test of Has_Inline_Always
728         alongside existing test of Front_End_Inlining as alternative
729         conditions for setting Inline_Now. Also add test of
730         Has_Inline_Always along with Front_End_Inlining test as an
731         alternative condition for setting Needs_Body to False.
733 2015-01-06  Tristan Gingold  <gingold@adacore.com>
735         * i-cpoint.adb (Copy_Array): Handle overlap.
737 2015-01-06  Pascal Obry  <obry@adacore.com>
739         * bindgen.adb: Minor style fix.
741 2015-01-06  Robert Dewar  <dewar@adacore.com>
743         * sem_util.ads, sem_util.adb: Minor reformatting.
745 2015-01-06  Vincent Celier  <celier@adacore.com>
747         * prj-conf.adb (Parse_Project_And_Apply_Config): Reset incomplete
748         with flags before parsing the projects.
749         * prj-err.adb (Error_Msg): Do nothing if there are incomplete withs.
750         * prj-part.adb (Post_Parse_Context_Clause): Set Incomplete_Withs
751         to True in the flags, when Ignore_Missing_With is True and an
752         imported project cannot be found.
753         * prj-proc.adb (Expression): When there are incomplete withs and
754         a variable or attribute is not found, set the variable/attribute
755         to unknown.
756         * prj.ads (Processing_Flags): New flag Incomplete_Withs,
757         defaulted to False.
759 2015-01-06  Vasiliy Fofanov  <fofanov@adacore.com>
761         * prj-proc.adb, prj-part.adb, prj.adb, prj.ads, prj-conf.adb,
762         prj-err.adb: Add new switch --no-command-line.
764 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
766         * sem_ch12.adb: Sloc of wrapper is that of instantiation.
768 2015-01-06  Robert Dewar  <dewar@adacore.com>
770         * sem_ch11.adb: Minor reformatting.
772 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
774         * exp_aggr.adb (Get_Assoc_Expr): New routine internal to
775         Build_Array_Aggr_Code, used to initialized components covered
776         by a box association. If the component type is scalar and has
777         a default aspect, use it to initialize such components.
779 2015-01-06  Pascal Obry  <obry@adacore.com>
781         * rtinit.c (__gnat_runtime_initialize): Add a parameter to
782         control the setup of the exception handler.
783         * initialize.c: Remove unused declaration.
784         * bindgen.adb: Always call __gnat_runtime_initialize and pass
785         whether the exeception handler must be set or not.
787 2015-01-06  Thomas Quinot  <quinot@adacore.com>
789         * freeze.adb (Set_SSO_From_Defaults): When setting scalar storage
790         order to native from default, make sure to also adjust bit order.
791         * exp_aggr.adb: Minor reformatting.
793 2015-01-06  Robert Dewar  <dewar@adacore.com>
795         * s-valllu.adb, s-valllu.ads, s-valuti.ads, s-valuns.adb, s-valuns.ads,
796         s-valrea.adb, s-valrea.ads: Add some additional guards for
797         Str'Last = Positive'Last.
799 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
801         * sem_ch12.adb, sem_ch8.adb: Ongoing work for wrappers for actual
802         subprograms.
804 2015-01-06  Javier Miranda  <miranda@adacore.com>
806         * exp_disp.adb (Expand_Interface_Conversion): Reapply patch.
808 2015-01-06  Thomas Quinot  <quinot@adacore.com>
810         * sem_util.ads: Minor reformatting.
811         * sem_cat.adb (In_RCI_Visible_Declarations): Change back to...
812         (In_RCI_Declaration) Return to old name, as proper checking of
813         entity being in the visible part depends on entity kind and must
814         be done by the caller.
816 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
818         * sem_ch12.adb, sem_ch12.ads, sem_ch8.adb: Ongoing work for wrappers
819         for operators in SPARK.
821 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
823         * sem_aggr.adb (Get_Value): In ASIS mode, preanalyze the
824         expression in an others association before making copies for
825         separate resolution and accessibility checks. This ensures that
826         the type of the expression is available to ASIS in all cases,
827         in particular if the expression is itself an aggregate.
829 2015-01-06  Eric Botcazou  <ebotcazou@adacore.com>
831         * einfo.ads (Has_Independent_Components): Document extended
832         usage.
833         * einfo.adb (Has_Independent_Components): Remove obsolete assertion.
834         (Set_Has_Independent_Components): Adjust assertion.
835         * sem_prag.adb (Analyze_Pragma): Also set Has_Independent_Components
836         for pragma Atomic_Components.  Set Has_Independent_Components
837         on the object instead of the type for an object declaration with
838         pragma Independent_Components.
840 2015-01-06  Olivier Hainque  <hainque@adacore.com>
842         * set_targ.adb (Read_Target_Dependent_Values): Set
843         Long_Double_Index when "long double" is read.
844         (elaboration code): Register_Back_End_Types only when not reading from
845         config files. Doing otherwise is pointless and error prone.
847 2015-01-06  Robert Dewar  <dewar@adacore.com>
849         * s-valrea.adb (Value_Real): Check for Str'Last = Positive'Last
851 2015-01-06  Robert Dewar  <dewar@adacore.com>
853         * a-wtgeau.adb, a-ztgeau.adb, a-tigeau.adb (String_Skip): Raise PE if
854         Str'Last = Positive'Last.
856 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
858         * sem_ch6.adb (Matches_Limited_View): Handle properly the case
859         where the non-limited type is a generic actual and appears as
860         a subtype of the non-limited view of the other.
861         * freeze.adb (Build_Renamed_Body): If the return type of the
862         declaration that is being completed is a limited view and the
863         non-limited view is available, use it in the specification of
864         the generated body.
866 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
868         * sem_ch3.adb (Find_Type_Name): If there is a previous tagged
869         incomplete view, the type of the classwide type common to both
870         views is the type being declared.
872 2015-01-06  Eric Botcazou  <ebotcazou@adacore.com>
874         * einfo.ads (Is_Independent): Further document extended usage.
876 2015-01-06  Eric Botcazou  <ebotcazou@adacore.com>
878         * einfo.ads (Is_Independent): Document extended usage.
879         * einfo.adb (Is_Independent): Remove obsolete assertion.
880         (Set_Is_Independent): Likewise.
881         * sem_prag.adb (Process_Atomic_Shared_Volatile): Rename into...
882         (Process_Atomic_Independent_Shared_Volatile): ...this.
883         Deal with pragma Independent here.
884         (Analyze_Pragma): Adjust
885         to above renaming and also invoke it for pragma Independent.
886         Adjust comment for Independent_Components.
888 2015-01-06  Robert Dewar  <dewar@adacore.com>
890         * snames.ads-tmpl: Remove entries for attribute Enum_Image.
891         * exp_attr.adb: Remove reference to Attribute_Enum_Image.
893 2015-01-06  Robert Dewar  <dewar@adacore.com>
895         * s-vallli.adb (Value_Long_Long_Integer): Handle case of Str'Last
896         = Positive'Last.
897         * s-valllu.adb (Value_Long_Long_Unsigned): Handle case of
898         Str'Last = Positive'Last.
900 2015-01-06  Robert Dewar  <dewar@adacore.com>
902         * sem_prag.adb (Process_Inline): Remove redundant construct
903         warning (-gnatw.r) for an ineffective pragma Inline.
905 2015-01-06  Robert Dewar  <dewar@adacore.com>
907         * s-valint.adb: Fix typo in last checkin.
908         * s-valuns.adb (Value_Unsigned): More efficient fix for
909         Positive'Last case.
910         * sem_attr.adb (Analyze_Attribute): Minor reformatting
911         (Eval_Attribute): Static ervaluation of 'Img for enumeration types.
913 2015-01-06  Robert Dewar  <dewar@adacore.com>
915         * s-valint.adb, s-valuns.adb (Value_Integer): Deal with case where
916         Str'Last = Positive'Last
918 2015-01-06  Thomas Quinot  <quinot@adacore.com>
920         * xoscons.adb: Display exception information and return non-zero
921         exit status in top level exception handler.
923 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
925         * sem_ch8.adb: Code clean up.
927 2015-01-06  Tristan Gingold  <gingold@adacore.com>
929         * targparm.ads: Remove obsolete comment.
931 2015-01-06  Olivier Hainque  <hainque@adacore.com>
933         * gcc-interface/decl.c (gnat_to_gnu_entity, case E_Variable): When
934         constructing a ref to variable, update inner_const_flag from the
935         variable TREE_READONLY attribute.
936         * gcc-interface/targtyps.c (WIDEST_HARDWARE_FP_SIZE): Remove default
937         definition.
938         (get_target_float_size): Remove.
939         (get_target_double_size): Remove.
940         (get_target_long_double_size): Remove.
942 2015-01-06  Pascal Obry  <obry@adacore.com>
944         * adaint.c (ProcListEvt): Set to NULL.
945         * rtinit.c: New file.
946         (__gnat_rt_init_count): New reference counter set to 0.
947         (__gnat_runtime_initialize): Move code here from __gnat_initialize when
948         this code is actually needed for the runtime initialization. This
949         routine returns immediately if the initialization has already been done.
950         * final.c: Revert previous change.
951         * rtfinal.c: New file.
952         (__gnat_runtime_finalize)[Win32]: Add finalization of the critical
953         section and event. The default version of this routine is empty (except
954         for the reference counting code). This routine returns immediately if
955         some others libraries are referencing the runtime.
956         * bindgen.adb (Gen_Adainit): Generate call to Runtime_Initialize
957         remove circuitry to initialize the signal handler as this is
958         now done by the runtime initialization routine.
959         (Gen_Adafinal): Generate call to Runtime_Finalize.
960         * gnat_ugn.texi: Update documentation about concurrency and
961         initialization/finalization of the run-time.
962         * gcc-interface/Makefile.in, gcc-interface/Make-lang.in: Add
963         references to rtfinal.o and rtinit.o
965 2015-01-06  Robert Dewar  <dewar@adacore.com>
967         * exp_attr.adb (Expand_N_Attribute_Reference): Add dummy entry
968         for Enum_Image.
969         * sem_attr.adb: Implement Enum_Image attribute.
970         * snames.ads-tmpl: Add entries for Enum_Image attribute.
972 2015-01-06  Robert Dewar  <dewar@adacore.com>
974         * namet.ads: Document use of Boolean2 for No_Use_Of_Entity.
975         * restrict.ads (No_Use_Of_Entity): New table.
976         * sem_prag.adb (Process_Restrictions_Or_Restriction_Warnings):
977         Ignore No_Use_Of_Entity (will be processed in parser).
978         * snames.ads-tmpl: Add entry for Name_No_Use_Of_Entity.
980 2015-01-06  Vincent Celier  <celier@adacore.com>
982         * prj-tree.adb (Imported_Or_Extended_Project_Of): Do not try
983         to check for an extended project, if a project does not have
984         yet a project declaration.
986 2015-01-06  Pierre-Marie Derodat  <derodat@adacore.com>
988         * scos.ads: Update documentation about the SCO table build
989         process and about table records format.
990         * par_sco.ads (SCO_Record): Rename to SCO_Record_Raw.
991         (SCO_Record_Filtered): New procedure.
992         (Set_SCO_Logical_Operator): New procedure.
993         (dsco): Update documentation.
994         * par_sco.adb: Update library-level comments.
995         (SCO_Generation_State_Type): New type.
996         (SCO_Generation_State): New variable.
997         (SCO_Raw_Table): New package instanciation.
998         (Condition_Pragma_Hash_Table): Rename to SCO_Raw_Hash_Table.
999         ("<"): New.
1000         (Tristate): New type.
1001         (Is_Logical_Operator): Return Tristate and update documentation.
1002         (Has_Decision): Update call to Is_Logical_Operator and complete
1003         documentation.
1004         (Set_Table_Entry): Rename to Set_Raw_Table_Entry, update
1005         comment, add an assertion for state checking and change
1006         references to SCO_Table into SCO_Raw_Table.
1007         (dsco): Refactor to dump the raw and the filtered tables.
1008         (Process_Decisions.Output_Decision_Operand): Handle putative
1009         short-circuit operators.
1010         (Process_Decisions.Output_Element): Update references
1011         to Set_Table_Entry and to Condition_Pragma_Hash_Table.
1012         (Process_Decisions.Process_Decision_Operand): Update call
1013         to Is_Logical_Operator.
1014         (Process_Decisions.Process_Node): Handle putative short-circuit
1015         operators and change references to
1016         SCO_Table into SCO_Raw_Table.
1017         (SCO_Output): Add an assertion
1018         for state checking and remove code that used to stamp out SCO entries.
1019         (SCO_Pragma_Disabled): Change reference to SCO_Table
1020         into SCO_Raw_Table.
1021         (SCO_Record): Rename to SCO_Record_Raw,
1022         add an assertion for state checking and change references
1023         to SCO_Table into SCO_Raw_Table.
1024         (Set_SCO_Condition): Add an assertion for state checking, update
1025         references to Condition_Pragma_Hash_Table and change references to
1026         SCO_Table into SCO_Raw_Table.
1027         (Set_SCO_Pragma_Enabled): Add an assertion for state checking and
1028         change references to SCO_Table into SCO_Raw_Table.
1029         (Set_SCO_Logical_Operator): New procedure.
1030         (Traverse_Declarations_Or_Statements.Set_Statement_Entry): Update
1031         references to Set_Table_Entry and to Condition_Pragma_Hash_Table.
1032         (SCO_Record_Fildered): New procedure.
1033         * gnat1drv.adb (Gnat1drv): Invoke the SCO filtering pass.
1034         * lib-writ.adb (Write_ALI): Invoke the SCO filtering pass and
1035         output SCOs.
1036         * par-load.adb (Load): Update reference to SCO_Record.
1037         * par.adb (Par): Update reference to SCO_Record.
1038         * put_scos.adb (Put_SCOs): Add an assertion to check that no
1039         putative SCO condition reaches this end.
1040         * sem_ch10.adb (Analyze_Proper_Body): Update reference to SCO_Record.
1041         * sem_res.adb (Resolve_Logical_Op): Validate putative SCOs
1042         when corresponding to an "and"/"or" operator affected by the
1043         Short_Circuit_And_Or pragma.
1045 2015-01-06  Robert Dewar  <dewar@adacore.com>
1047         * sem_ch8.adb (Analyze_Use_Package): Give more specific error
1048         msg for attempted USE of generic subprogram or subprogram.
1050 2015-01-06  Robert Dewar  <dewar@adacore.com>
1052         * s-valllu.adb, a-tiinau.adb, a-timoau.adb, a-ztinau.adb, a-ztmoau.adb,
1053         s-valuns.adb, s-valrea.adb, a-wtflau.adb, a-tiflau.adb, a-ztflau.adb,
1054         a-wtinau.adb, a-wtmoau.adb: Document recognition of : in place of #.
1056 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
1058         * sem_ch13.adb (Analyze_Aspect_Specifications): For aspects
1059         that specify stream subprograms, if the prefix is a class-wide
1060         type then the generated attribute definition clause must apply
1061         to the same class-wide type.
1062         (Default_Iterator): An iterator defined by an aspect of some
1063         container type T must have a first parameter of type T, T'class,
1064         or an access to such (from code reading RM 5.5.1 (2/3)).
1066 2015-01-06  Arnaud Charlet  <charlet@adacore.com>
1068         * gnat1drv.adb: Minor: complete previous change.
1070 2015-01-06  Olivier Hainque  <hainque@adacore.com>
1072         * set_targ.ads (C_Type_For): New function. Return the name of
1073         a C type supported by the back-end and suitable as a basis to
1074         construct the standard Ada floating point type identified by
1075         the T parameter. This is used as a common ground to feed both
1076         ttypes values and the GNAT tree nodes for the standard floating
1077         point types.
1078         * set_targ.adb (Long_Double_Index): The index at which "long
1079         double" gets registered in the FPT_Mode_Table. This is useful to
1080         know whether we have a "long double" available at all and get at
1081         it's characteristics without having to search the FPT_Mode_Table
1082         when we need to decide which C type should be used as the
1083         basis for Long_Long_Float in Ada.
1084         (Register_Float_Type): Fill Long_Double_Index.
1085         (FPT_Mode_Index_For): New function. Return the index in
1086         FPT_Mode_Table that designates the entry corresponding to the
1087         provided C type name.
1088         (FPT_Mode_Index_For): New function. Return the index in
1089         FPT_Mode_Table that designates the entry for a back-end type
1090         suitable as a basis to construct the standard Ada floating point
1091         type identified by the input T parameter.
1092         (elaboration code): Register_Back_End_Types unconditionally,
1093         so C_Type_For can operate regardless of -gnateT. Do it
1094         early so we can query it for the floating point sizes, via
1095         FPT_Mode_Index_For. Initialize Float_Size, Double_Size and
1096         Long_Double_Size from the FPT_Mode_Table, as cstand will do.
1097         * cstand.adb (Create_Float_Types): Use C_Type_For to determine
1098         which C type should be used as the basis for the construction
1099         of the Standard Ada floating point types.
1100         * get_targ.ads (Get_Float_Size, Get_Double_Size,
1101         Get_Long_Double_Size): Remove.
1102         * get_targ.adb: Likewise.
1104 2015-01-06  Thomas Quinot  <quinot@adacore.com>
1106         * sem_cat.adb (In_RCI_Declaration): Remove unnecessary
1107         parameter and rename to...
1108         (In_RCI_Visible_Declarations): Fix handling of private part of nested
1109         package.
1110         (Validate_RCI_Subprogram_Declaration): Reject illegal function
1111         returning anonymous access in RCI unit.
1113 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
1115         * sem_ch6.adb (New_Overloaded_Entity): In GNATprove mode, a
1116         function wrapper may be a homonym of another local declaration.
1117         * sem_ch8.adb (Analyze_Subprogram_Renaming): In GNATprove mode,
1118         build function and operator wrappers after the actual subprogram
1119         has been resolved, and replace the standard renaming declaration
1120         with the declaration of wrapper.
1121         * sem_ch12.ads (Build_Function_Wrapper, Build_Operator_Wraooer):
1122         make public for use elsewhere.
1123         * sem_ch12.adb (Build_Function_Wrapper, Build_Operator_Wraooer):
1124         rewrite, now that actual is fully resolved when wrapper is
1125         constructed.
1127 2015-01-06  Javier Miranda  <miranda@adacore.com>
1129         * exp_disp.adb: Revert previous change.
1131 2015-01-06  Robert Dewar  <dewar@adacore.com>
1133         * exp_util.adb: Change name Name_Table_Boolean to
1134         Name_Table_Boolean1.
1135         * namet.adb: Change name Name_Table_Boolean to Name_Table_Boolean1
1136         Introduce Name_Table_Boolean2/3.
1137         * namet.ads: Change name Name_Table_Boolean to Name_Table_Boolean1
1138         Introduce Name_Table_Boolean2/3.
1139         * par-ch13.adb: Change name Name_Table_Boolean to
1140         Name_Table_Boolean1.
1142 2015-01-06  Bob Duff  <duff@adacore.com>
1144         * gnat_rm.texi: Improve documentation regarding No_Task_Termination.
1146 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
1148         * sem_aggr.adb (Resolve_Record_Aggregte, Get_Value): For an
1149         others choice that covers multiple components, analyze each
1150         copy with the type of the component even in compile-only mode,
1151         to detect potential accessibility errors.
1153 2015-01-06  Hristian Kirtchev  <kirtchev@adacore.com>
1155         * sem_res.adb (Is_Assignment_Or_Object_Expression): New routine.
1156         (Resolve_Actuals): An effectively volatile out
1157         parameter cannot act as an in or in out actual in a call.
1158         (Resolve_Entity_Name): An effectively volatile out parameter
1159         cannot be read.
1161 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
1163         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): If the body is
1164         the expansion of an expression function it may be pre-analyzed
1165         if a 'access attribute is applied to the function, in which case
1166         last_entity may have been assigned already.
1168 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
1170         * sem_ch4.adb (Analyze_One_Call): If formal has an incomplete
1171         type and actual has the corresponding full view, there is no
1172         error, but a case of use of incomplete type in a predicate or
1173         invariant expression.
1175 2015-01-06  Vincent Celier  <celier@adacore.com>
1177         * makeutl.adb (Insert_No_Roots): Make sure that the same source
1178         in two different project tree is checked in both trees, if they
1179         are sources of two different projects, extended or not.
1181 2015-01-06  Arnaud Charlet  <charlet@adacore.com>
1183         * gnat1drv.adb: Minor code clean up.
1184         (Adjust_Global_Switches): Ignore gnatprove_mode in codepeer_mode.
1186 2015-01-06  Bob Duff  <duff@adacore.com>
1188         * osint.adb (Read_Source_File): Don't print out
1189         file name unless T = Source.
1191 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
1193         * sem_util.adb (Is_Variable, Is_OK_Variable_For_Out_Formal):
1194         recognize improper uses of constant_reference types as actuals
1195         for in-out parameters.
1196         (Check_Function_Call): Do not collect identifiers if function
1197         name is missing because of previous error.
1199 2015-01-06  Robert Dewar  <dewar@adacore.com>
1201         * ali-util.adb, sem_prag.adb, rtsfind.adb, sem_util.adb, sem_res.adb,
1202         ali.adb, binde.adb, namet.adb, namet.ads, gnatls.adb, bcheck.adb:
1203         Minor change of name Name_Table_Info => Name_Table_Int.
1205 2015-01-06  Robert Dewar  <dewar@adacore.com>
1207         * exp_strm.adb (Build_Elementary_Input_Call): Clarify comments
1208         in previous checkin.
1209         * freeze.adb (Freeze_Fixed_Point_Type): Add warning for shaving
1210         of bounds.
1211         * sem_prag.adb, sem_ch10.adb, sem_ch6.adb: Minor reformatting.
1213 2015-01-06  Vincent Celier  <celier@adacore.com>
1215         * a-strsup.adb (Times (Natural;String;Positive)): Raise
1216         Length_Error, not Index_Error, when the result is too long.
1218 2015-01-06  Thomas Quinot  <quinot@adacore.com>
1220         * a-direct.adb (Create_Path): Minor error handling and
1221         performance improvement.
1223 2015-01-06  Robert Dewar  <dewar@adacore.com>
1225         * checks.ads, sem_ch12.adb: Minor reformatting.
1226         * exp_ch4.adb (Expand_N_Op_Divide): Generate explicit divide by
1227         zero check for fixed-point case if Backend_Divide_Checks_On_Target
1228         is False.
1230 2015-01-06  Robert Dewar  <dewar@adacore.com>
1232         * sem_prag.adb (Analyze_Pragma, case No_Elaboration_Code_All):
1233         Do not set restriction No_Elaboration_Code unless the pragma
1234         appears in the main unit).
1236 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
1238         * sem_ch10.adb (Is_Regular_With_Clause): Add guard to verify
1239         that with clause has already been analyzed before checking kind
1240         of with_clause.
1242 2015-01-06  Robert Dewar  <dewar@adacore.com>
1244         * exp_strm.adb (Build_Elementary_Input_Call): Return base type
1245         (as required by RM).
1247 2015-01-06  Arnaud Charlet  <charlet@adacore.com>
1249         * a-reatim.adb ("/"): Add explicit pragma Unsuppress (Division_Check).
1251 2015-01-06  Robert Dewar  <dewar@adacore.com>
1253         * sem_prag.adb (Process_Suppress_Unsuppress): Add extra warning
1254         for ignoring pragma Suppress (Elaboration_Check) in SPARK mode.
1256 2015-01-06  Javier Miranda  <miranda@adacore.com>
1258         * exp_disp.adb (Expand_Interface_Conversion): No displacement
1259         of the pointer to the object needed when the type of the operand
1260         is not an interface type and the interface is one of its parent
1261         types (since they share the primary dispatch table).
1263 2015-01-06  Vincent Celier  <celier@adacore.com>
1265         * prj-env.adb: Minor comment update.
1267 2015-01-06  Javier Miranda  <miranda@adacore.com>
1269         * sem_res.adb (Valid_Conversion): Restrict the checks on anonymous
1270         access types whose target type is an interface type to operands
1271         that are access types; required to report an error when the
1272         operand is not an access type.
1274 2015-01-06  Bob Duff  <duff@adacore.com>
1276         * a-cfinve.adb (Copy): Set the discriminant to the Length when
1277         Capacity = 0.
1278         * a-cofove.ads (Capacity): Add a postcondition.
1279         * a-cfinve.ads (Capacity): Add a postcondition.
1280         (Reserve_Capacity): Correct the postcondition in the case where
1281         Capacity = 0; that means "Capacity => Length (Container)".
1282         * a-cofove.adb (Elems[c]): Add a comment
1283         explaining the dangers and how to avoid them.
1285 2015-01-06  Ed Schonberg  <schonberg@adacore.com>
1287         * sem_ch12.adb: Code clean up.
1289 2015-01-06  Arnaud Charlet  <charlet@adacore.com>
1291         * gnatvsn.ads: Bump copyright year.
1293 2015-01-06  Robert Dewar  <dewar@adacore.com>
1295         * s-taskin.ads, s-traces.ads: Minor reformatting.
1296         * exp_util.adb: Minor typo fix.
1298 2015-01-06  Vincent Celier  <celier@adacore.com>
1300         * gnatls.adb (Search_RTS): Invoke Initialize_Default_Project_Path
1301         with the runtime name.
1302         * prj-env.adb (Initialize_Default_Project_Path): When both
1303         Target_Name and Runtime_Name are not empty string, add to the
1304         project path the two directories .../lib/gnat and .../share/gpr
1305         related to the runtime.
1306         * prj-env.ads (Initialize_Default_Project_Path): New String
1307         parameter Runtime_Name, defaulted to the empty string.
1309 2015-01-06  Hristian Kirtchev  <kirtchev@adacore.com>
1311         * frontend.adb: Guard against the case where a configuration
1312         pragma may be split into multiple pragmas and the original
1313         rewritten as a null statement.
1314         * sem_prag.adb (Analyze_Pragma): Insert a brand new Check_Policy
1315         pragma using Insert_Before rather than Insert_Action. This
1316         takes care of the configuration pragma case where Insert_Action
1317         would fail.
1319 2015-01-06  Bob Duff  <duff@adacore.com>
1321         * a-coboho.ads (Element_Access): Add "pragma
1322         No_Strict_Aliasing (Element_Access);". This is needed because
1323         we are unchecked-converting from Address to Element_Access.
1324         * a-cofove.ads, a-cofove.adb (Elems,Elemsc): Fix bounds of the
1325         result to be 1.
1327 2015-01-06  Hristian Kirtchev  <kirtchev@adacore.com>
1329         * sem_res.adb (Resolve_Actuals): Remove the
1330         restriction which prohibits volatile actual parameters with
1331         enabled external propery Async_Writers to act appear in procedure
1332         calls where the corresponding formal is of mode OUT.
1334 2015-01-05  Jakub Jelinek  <jakub@redhat.com>
1336         * gnat_ugn.texi: Bump @copying's copyright year.
1338 2015-01-05  Eric Botcazou  <ebotcazou@adacore.com>
1340         PR ada/64492
1341         * gcc-interface/Makefile.in (../stamp-tools): Reinstate dropped code.
1343 2015-01-04  Uros Bizjak  <ubizjak@gmail.com>
1345         * gcc-interface/misc.c (internal_error_function): Use xasprintf instead
1346         of unchecked asprintf.
1349 Copyright (C) 2015 Free Software Foundation, Inc.
1351 Copying and distribution of this file, with or without modification,
1352 are permitted in any medium without royalty provided the copyright
1353 notice and this notice are preserved.