2014-08-01 Robert Dewar <dewar@adacore.com>
[official-gcc.git] / gcc / ada / ChangeLog
bloba1e0c19af6b70add8f3ed037887e800a22f57c2b
1 2014-08-01  Robert Dewar  <dewar@adacore.com>
3         * snames.ads-tmpl, s-os_lib.adb, s-os_lib.ads, s-fileio.adb: Remove
4         VMS-specific code.
5         * prj-conf.adb: Minor reformatting.
6         * xr_tabls.adb (Read_File): Restore code which was enabled on
7         non VMS platforms before.
8         * prj-env.adb (Initialize_Default_Project_Path): Ditto.
9         * sem_ch5.adb: Minor reformatting.
10         * lib-writ.adb, lib-writ.ads, bindgen.adb, sem_vfpt.adb,
11         sem_vfpt.ads, ali.adb, ali.ads, opt.ads, bcheck.adb, exp_strm.adb:
12         Remove VMS-specific code.
14 2014-08-01  Vincent Celier  <celier@adacore.com>
16         * make.adb (Await_Compile): Remove loop that was only needed
17         for VMS.
19 2014-08-01  Robert Dewar  <dewar@adacore.com>
21         * a-calcon.ads, a-direct.adb, a-dirval-mingw.adb, a-dirval.adb,
22         a-dirval.ads, a-except-2005.adb, a-excpol-abort.adb,
23         a-numaux-darwin.ads, a-numaux.ads, bindgen.adb, bindusg.adb,
24         einfo.adb, einfo.ads, err_vars.ads, errout.ads, errutil.adb,
25         exp_ch3.adb, exp_ch4.adb, exp_ch7.adb, exp_ch7.ads, fname-uf.adb,
26         fname.adb, fname.ads, freeze.adb, g-debpoo.adb, g-dirope.ads,
27         g-excact.ads, g-expect.ads, g-socket.adb, g-socket.ads, g-sothco.ads,
28         g-traceb.ads, gnat_rm.texi, gnatlink.adb, gnatls.adb, i-cstrea.adb,
29         krunch.adb, krunch.ads, layout.adb, lib-util.adb, make.adb,
30         mlib.adb, osint-b.adb, osint-b.ads, osint-c.adb, osint.adb,
31         osint.ads, output.ads, par.adb, prj-conf.adb, prj-env.adb,
32         prj-makr.adb, prj-nmsc.adb, prj.adb, prj.ads, repinfo.adb, rtsfind.adb,
33         rtsfind.ads, s-excmac-gcc.ads, s-fatgen.adb, s-mastop.ads,
34         s-parame-ae653.ads, s-parame-hpux.ads, s-parame-vxworks.ads,
35         s-parame.ads, s-soflin.ads, s-stoele.adb, s-tasini.adb,
36         s-taspri-dummy.ads, s-taspri-hpux-dce.ads, s-taspri-mingw.ads,
37         s-taspri-posix-noaltstack.ads, s-taspri-posix.ads,
38         s-taspri-solaris.ads, s-taspri-vxworks.ads, s-trasym.ads,
39         sem_ch12.adb, sem_ch4.adb, sem_eval.adb, sem_intr.adb, sem_mech.adb,
40         sem_mech.ads, sem_prag.adb, sem_res.adb, sem_util.adb, sem_util.ads,
41         sinfo.adb, sinfo.ads, sinput-c.adb, symbols.ads, targparm.adb,
42         treepr.adb, types.ads, xr_tabls.adb, xr_tabls.ads: Remove VMS
43         specific code and comments.
45 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
47         * sem_ch5.adb (Analyze_Iterator_Specification): New procedure
48         Check_Reverse_Iteration, to verify the legality of the Reverse
49         indicator on various container types, and to detect illegal
50         reverse iterations on containers that only supoort forward
51         iteration.
53 2014-08-01  Vincent Celier  <celier@adacore.com>
55         * gnatcmd.adb: Remove the VMS specific stuff.  Integrate in
56         procedure GNATCmd the relevant declarations from packages VMS_Cmds
57         and VMS_Conv.
58         * gnatcmd.ads: Update comments to remove any trace of VMS
60 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
62         * sem_ch12.adb: sem_ch12.adb (Build_Wrapper): Capture entity for
63         defaulted actual that is an operator, before building wrapper
64         for it in GNATprove mode. Restrict construction of wrapper to
65         actuals that are operators.
67 2014-08-01  Vincent Celier  <celier@adacore.com>
69         * vms_conv.adb, vms_conv.ads, vms_data.ads, vms_cmds.ads: Remove VMS
70         specific packages no longer needed.
72 2014-08-01  Pascal Obry  <obry@adacore.com>
74         * s-os_lib.ads (System.CRTL): Move with clause to body.
75         (File_Size): New type.
76         (File_Length64): Use it.
77         (File_Length): Restore previous spec returning a Long_Integer.
78         * s-os_lib.adb (System.CRTL): Move with clause here.
80 2014-08-01  Vincent Celier  <celier@adacore.com>
82         * mlib-prj.adb: Update comments to remove any mention of VMS.
84 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
86         * ug_words, xgnatugn.adb, gcc-interface/Make-lang.in: Remove
87         xgnatugn.adb and ug_words.
89 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
91         * exp_attr.adb (Expand_N_Attribute_Reference): Check whether
92         expansion can be avoid for Machine, Model and Rounding.
93         (Is_Inline_Floating_Point_Attribute): Return true for Machine
94         & Model, as well as Rounding if wrapped in a conversion to an
95         integer type.
96         * sem_res.adb (Simplify_Type_Conversion): Deal with Rounding as well.
97         * gcc-interface/gigi.h (fp_arith_may_widen): Declare.
98         * gcc-interface/utils.c (fp_arith_may_widen): New global variable.
99         * gcc-interface/misc.c (enumerate_modes): Compute it.
100         * gcc-interface/trans.c (FP_ARITH_MAY_WIDEN): Delete.
101         (lvalue_required_for_attribute_p): Deal with Descriptor_Size,
102         Machine and Model.
103         (Attribute_to_gnu) <Attr_Model>: New case.
104         <Attr_Machine>): Likewise.
105         (convert_with_check): Test
106         fp_arith_may_widen variable.
108 2014-08-01  Pascal Obry  <obry@adacore.com>
110         * adaint.h (GNAT_FOPEN): New definition for Windows.
111         (GNAT_OPEN): Likewise.
112         (GNAT_STAT): Likewise.
113         (GNAT_FSTAT): Likewise.
114         (GNAT_LSTAT): Likewise.
115         (GNAT_STRUCT_STAT): Likewise.
116         * adaint.c (__gnat_stat): Fix computation of file size for
117         Windows.
119 2014-08-01  Vincent Celier  <celier@adacore.com>
121         * Makefile.rtl: Minor comment update.
123 2014-08-01  Vincent Celier  <celier@adacore.com>
125         * Make-generated.in: Remove dependencies for vms-help.
127 2014-08-01  Gary Dismukes  <dismukes@adacore.com>
129         * makeutl.ads, opt.ads: Minor grammar fixes.
130         * makeutl.adb: Minor code reorganization.
132 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
134         * gcc-interface/Makefile.in, gcc-interface/Make-lang.in,
135         gnatsym.adb: Remove gnatsym (VMS only tool).
137 2014-08-01  Ben Brosgol  <brosgol@adacore.com>
139         * gnat_ugn.texi, projects.texi, xgnatugn.adb: Removed all VMS
140         conditionalization from gnat_ugn.texi and projects.texi, and updated
141         (considerably simplified) xgnatugn.adb, to be removed soon.
143 2014-08-01  Vincent Celier  <celier@adacore.com>
145         * debug.adb: Remove doc for gnatmake/gprbuild switch -ds.
146         * make.adb (List_Bad_Compilations): Use Opt.No_Exit_Message
147         instead of Debug.Debug_Flag_S.
148         * makeutl.adb (Finish_Program, Fail_Program): Use Opt flag
149         No_Exit_Message instead of Debug.Debug_Flag_S to suppress exit
150         error messages.
151         * makeutl.ads (No_Exit_Message_Option): New constant string
152         for switch --no-exit-message.
153         * opt.ads (No_Exit_Message): New Boolean flag, defaulted to False.
154         * switch-m.adb (Scan_Make_Switches): Recognize new switch
155         --no-exit-message.
157 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
159         * exp_vfpt.adb, exp_vfpt.ads: Removed, no longer used.
160         * gcc-interface/Make-lang.in: Remove exp_vfpt.o
162 2014-08-01  Javier Miranda  <miranda@adacore.com>
164         * inline.ads (Inlined_Calls, Backend_Calls,
165         Backend_Inlined_Subps, Backend_Not_Inlined_Subps): Declarations
166         moved to inline.adb (Cannot_Inline): Update documentation.
167         (Check_And_Build_Body_To_Inline): Renamed.
168         (List_Inlining_Info): Subprogram moved here from package exp_ch6.
169         * inline.adb (Check_Inlining_Restrictions): New local variable.
170         (Inlined_Calls, Backend_Calls, Backend_Inlined_Subps,
171         Backend_Not_Inlined_Subps): Declarations moved here
172         from inline.ads (Number_Of_Statements): Removed.
173         (Remove_Pragmas): Avoid duplicated version of this subprogram.
174         (Build_Body_To_Inline): Code cleanup.
175         (Build_Body_To_Inline.Has_Excluded_Statament): Removed.
176         (Check_And_Build_Body_To_Inline): Renamed. Code cleanup.
177         (Check_Body_To_Inline): Removed.
178         (Generate_Body_To_Inline): Renamed as Generate_Subprogram_Body.
179         (Has_Excluded_Declaration): No action if not
180         Check_Inlining_Restrictions.
181         (Has_Excluded_Statement): No action if not Check_Inlining_Restrictions.
182         (Initialize): Initialize the lists of inlined calls and subprograms.
183         (List_Inlining_Info): Subprogram moved here from package exp_ch6.
184         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Update call
185         to Check_And_Build_Body_To_Inline since it has been renamed as
186         Check_And_Split_Unconstrained_Function
187         * exp_ch6.ad[sb] (List_Inlining_Info): Subprogram moved to
188         package inline.
189         * gnat1drv.adb Update call to Inline.List_Inlining_Info.
191 2014-08-01  Vincent Celier  <celier@adacore.com>
193         * debug.adb: Add documentation for new debug switch -ds.
194         * make.adb (List_Bad_Compilations): Do not issue any message
195         when switch -ds is specified.
196         * makeutl.adb (Fail_Program): Do not issue any message when
197         -ds is specified.
198         (Finish_Program): Ditto.
200 2014-08-01  Robert Dewar  <dewar@adacore.com>
202         * s-exnint.adb, s-exnint.ads, s-wwdwch.ads, s-carsi8.ads,
203         s-casi32.ads, indepsw.adb, a-timoau.ads, s-explli.adb, s-explli.ads,
204         s-casi16.ads, s-powtab.ads, g-wistsp.ads, a-ztmoau.adb,
205         indepsw-gnu.adb, s-imgllb.ads, types.adb, gnat.ads, s-proinf.adb,
206         indepsw-aix.adb, s-caun64.ads, s-imgllw.ads, s-traces-default.adb,
207         s-vxwork-x86.ads, s-expllu.adb, s-exnlli.adb, s-exnlli.ads,
208         s-traces.adb, widechar.ads, stand.adb, s-expint.adb,
209         s-tratas-default.adb, s-expint.ads, s-geveop.ads, s-caun32.ads,
210         s-expuns.adb, s-mantis.adb, s-mantis.ads, s-caun16.ads, s-tasinf.adb,
211         s-memcop.ads, s-dsaser.ads, s-imgbiu.ads, a-szmzco.ads, g-strspl.ads,
212         s-casi64.ads, g-zstspl.ads, indepsw-mingw.adb, tree_io.adb,
213         s-boarop.ads, uname.ads, s-fore.adb, s-fore.ads, g-timsta.adb,
214         g-timsta.ads, s-assert.adb, s-vector.ads, s-tratas.adb,
215         s-tratas.ads: Minor fix to copyright notices.
217 2014-08-01  Eric Botcazou  <ebotcazou@adacore.com>
219         * sinfo.ads: Remove long obsolete comment.
220 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
222         * sem_util.adb: Add guard to setting of No_Predicate_On_Actual.
223         * sem_ch3.adb: Minor reformatting.
225 2014-08-01  Pascal Obry  <obry@adacore.com>
227         * cstreams.c: Only enable large file support on know supported
228         platforms. Add missing defines/includes.
230 2014-08-01  Ed Schonberg  <schonberg@adacore.com>
232         * einfo.ads, einfo.adb New flags No_Predicate_On_Actual and
233         No_Dynamic_Predicate_On_Actual, to enforce the generic contract
234         on generic units that contain constructs that forbid subtypes
235         with predicates.
236         * sem_ch3.adb (Analyze_Subtype_Declaration, Process_Subtype):
237         Inherit flags indicating the presence of predicates in subtype
238         declarations with and without constraints.
239         (Inherit_Predicate_Flags): Utility for the above.
240         * sem_util.adb (Bad_Predicated_Subtype_Use): In a generic context,
241         indicate that the actual cannot have predicates, and preserve
242         warning. In an instance, report error if actual has predicates
243         and the construct appears in a package declaration.
244         * sem_ch12.adb (Diagnose_Predicated_Actual): Report error
245         for an actual with predicates, if the corresponding formal
246         carries No_Predicate_On_Actual or (in the case of a loop)
247         No_Dynamic_Predicate_On_Actual.
248         * sem_ch13.adb (Build_Predicate_Functions); Do not build a
249         Static_Predicate function if the type is non-static (in the
250         presence of previous errors),
251         * sem_ch5.adb (Analyze_Loop_Parameter_Specification): Set flag
252         No_Dynamic_Predicate_On_Actual in a generic context, to enforce
253         generic contract on actuals that cannot have predicates.
255 2014-08-01  Pascal Obry  <obry@adacore.com>
257         * a-direct.adb (C_Size): Returns an int64.
258         * osint.adb (System.CRTL): New with clause.
259         (File_Length.Internal): Returns an int64.
260         * s-os_lib.ads (File_Length): Returns an int64.
262 2014-08-01  Robert Dewar  <dewar@adacore.com>
264         * gnatchop.adb, gnatcmd.adb, make.adb, mlib-prj.adb, bindgen.adb,
265         mlib.ads, butil.adb, clean.adb, binde.adb, gnatls.adb, gnatname.adb,
266         osint.adb, krunch.adb: Minor reformatting.
268 2014-08-01  Robert Dewar  <dewar@adacore.com>
270         * inline.adb, inline.ads, fe.h, einfo.adb, einfo.ads, sem_util.adb,
271         sem_util.ads, exp_ch4.adb, exp_ch11.adb, exp_ch6.adb, cstand.adb,
272         sem_mech.adb, sem_ch6.adb, sem_ch8.adb, sem_ch11.adb, snames.ads-tmpl:
273         Remove VMS-specific code.
274         * gcc-interface/decl.c, gcc-interface/trans.c: Ditto.
276 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
278         * binde.adb, bindgen.adb, butil.adb, clean.adb, gnatbind.adb,
279         gnatchop.adb, gnatcmd.adb, gnatls.adb, gnatname.adb, krunch.adb,
280         make.adb, makeutl.adb, memtrack.adb, mlib-prj.adb, mlib.adb,
281         mlib.ads, tempdir.adb: Remove VMS handling.
283 2014-08-01  Pascal Obry  <obry@adacore.com>
285         * adaint.h, adaint.c (__gnat_file_length): Returns an __int64.
286         (__gnat_named_file_length): Likewise.
287         (__gnat_file_length_attr): Likewise.
288         * a-direct.adb (C_Size): Use size_t as returned type.
289         * osint.adb (File_Length): Adjust spec for Internal routine
290         (returns size_t).
291         * s-os_lib.adb (File_Length): Now returns a CRTL.size_t.
292         (System.CRTL): With claused moved to spec.
293         * s-os_lib.ads (System.CRTL): With clause moved to here.
295 2014-08-01  Pascal Obry  <obry@adacore.com>
297         * adaint.h, adaint.c (__gnat_open): Added.
298         * s-crtl.ads (open): Import __gnat_open for large file support.
300 2014-08-01  Robert Dewar  <dewar@adacore.com>
302         * sem_case.adb (Dup_Choice): Improve message for integer constants.
304 2014-08-01  Arnaud Charlet  <charlet@adacore.com>
306         * gnatlink.adb: Remove special handling of VMS, RTX and JVM.
308 2014-08-01  Pascal Obry  <obry@adacore.com>
310         * adaint.h (GNAT_OPEN): Defines as open64 where supported.
311         * adaint.c (GNAT_OPEN): Uses new macro where needed.
313 2014-07-31  Eric Botcazou  <ebotcazou@adacore.com>
315         * gcc-interface/utils.c (lookup_and_insert_pad_type): New function
316         extracted from...
317         (maybe_pad_type): ...here.  Call it to canonicalize the pad type.
318         * gcc-interface/gigi.h: Update comment.
320 2014-07-31  Javier Miranda  <miranda@adacore.com>
322         * debug.adb Remove documentation of -gnatd.k (no longer needed).
323         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Code cleanup.
324         * inline.ads (Backend_Inlined_Subps): New
325         Elist.  (Backend_Not_Inlined_Subps): New Elist.
326         (Has_Excluded_Declaration): Declaration previously located in
327         * inline.adb (Has_Excluded_Statement): Declaration previously
328         located in inline.adb
329         * inline.adb (Has_Single_Return): Moved out of
330         Build_Body_To_Inline to avoid having duplicated code.
331         (Number_Of_Statements): New subprogram.
332         (Register_Backend_Inlined_Subprogram): New subprogram.
333         (Register_Backend_Not_Inlined_Subprogram): New subprogram.
334         (Add_Inlined_Subprogram): Register backend inlined subprograms and
335         also register subprograms that cannot be inlined by the backend.
336         (Has_Excluded_Declaration): Moved out of Build_Body_To_Inline
337         to avoid having duplicated code.  Replace occurrences of
338         Debug_Flag_Dot_K by Back_End_Inlining.
339         * sem_res.adb (Resolve_Call): Code cleanup.
340         * exp_ch6.adb (Expand_Call): Complete previous patch. Replace
341         occurrence of Debug_Flag_Dot_K by Back_End_Inlining.
342         (List_Inlining_Info): Add listing of subprograms passed to the
343         backend and listing of subprograms that cannot be inlined by
344         the backend.
345         * sem_ch12.adb, sem_ch3.adb Replace occurrences of
346         Debug_Flag_Dot_K by Back_End_Inlining.
348 2014-07-31  Robert Dewar  <dewar@adacore.com>
350         * nlists.ads: Minor code fix (remove unwise Inline for
351         List_Length).
353 2014-07-31  Arnaud Charlet  <charlet@adacore.com>
355         * einfo.adb: Remove VMS specific code.
356         * exp_attr.adb: Remove VAX specific code.
357         * set_targ.adb: Remove handling of VAX_Float.
358         * sem_vfpt.adb: Remove references to Vax_Native.
359         * sem_attr.adb (Is_VAX_Float): Remove ref to VAX_Native.
361 2014-07-31  Robert Dewar  <dewar@adacore.com>
363         * sem_ch4.adb: Minor reformatting.
365 2014-07-31  Arnaud Charlet  <charlet@adacore.com>
367         * gcc-interface/trans.c, gcc-interface/misc.c: Remove references
368         to VMS. Misc clean ups.
369         * gcc-interface/Makefile.in (gnatlib-shared-vms): Remove.
371 2014-07-31  Robert Dewar  <dewar@adacore.com>
373         * cstand.adb, einfo.adb, einfo.ads, errout.adb, exp_attr.adb,
374         exp_prag.adb, frontend.adb, interfac.ads,
375         par-prag.adb, s-auxdec.ads, s-filofl.ads, s-fishfl.ads, s-fvadfl.ads,
376         s-fvaffl.ads, s-fvagfl.ads, s-vaflop.ads, sem_attr.adb, sem_attr.ads,
377         sem_ch13.adb, sem_ch3.adb, sem_ch8.adb, sem_prag.adb, snames.adb-tmpl,
378         snames.ads-tmpl: Remove obsolete VMS-specific code.
380 2014-07-31  Robert Dewar  <dewar@adacore.com>
382         * sem_ch3.adb, sem_ch13.adb: Minor reformatting.
384 2014-07-31  Arnaud Charlet  <charlet@adacore.com>
386         * a-intnam-linux.ads: Minor: update obsolete comments.
387         * s-taasde.adb: Minor: fix comment header.
389 2014-07-31  Arnaud Charlet  <charlet@adacore.com>
391         * s-auxdec-vms-ia64.adb, s-parame-vms-alpha.ads, s-asthan-vms-alpha.adb,
392         s-tpopde-vms.adb, s-mastop-vms.adb, s-tpopde-vms.ads, s-taprop-vms.adb,
393         mlib-tgt-vms_common.adb, mlib-tgt-vms_common.ads, s-inmaop-vms.adb,
394         g-enblsp-vms-alpha.adb, s-ransee-vms.adb, s-osprim-vms.adb,
395         s-osprim-vms.ads, g-socthi-vms.adb, g-socthi-vms.ads, system-vms_64.ads,
396         s-osinte-vms.adb, s-osinte-vms.ads, g-eacodu-vms.adb,
397         s-vaflop-vms-alpha.adb, s-parame-vms-ia64.ads, a-dirval-vms.adb,
398         a-caldel-vms.adb, mlib-tgt-specific-vms-alpha.adb, s-tasdeb-vms.adb,
399         symbols-vms.adb, a-intnam-vms.ads, g-expect-vms.adb,
400         symbols-processing-vms-alpha.adb, mlib-tgt-specific-vms-ia64.adb,
401         s-traent-vms.adb, s-traent-vms.ads, i-cstrea-vms.adb, a-numaux-vms.ads,
402         symbols-processing-vms-ia64.adb, s-interr-vms.adb, s-memory-vms_64.adb,
403         s-memory-vms_64.ads, g-enblsp-vms-ia64.adb, s-taspri-vms.ads,
404         s-auxdec-vms_64.ads, s-intman-vms.adb, s-intman-vms.ads,
405         s-tpopsp-vms.adb, s-asthan-vms-ia64.adb, a-calend-vms.adb,
406         a-calend-vms.ads, system-vms-ia64.ads, s-auxdec-vms-alpha.adb: Removed.
407         * namet.h (Is_Non_Ada_Error): Remove.
409 2014-07-31  Robert Dewar  <dewar@adacore.com>
411         * exp_util.adb, lib-writ.adb, sem_ch12.adb, s-direio.adb: Minor
412         reformatting.
414 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
416         * exp_attr.adb (Expand_Loop_Entry_Attribute): Update the comment
417         which demonstrates the expansion of while loops subject to
418         attribute 'Loop_Entry. The condition of a while loop along with
419         related condition actions is now wrapped in a function.  Instead
420         of repeating the condition, the expansion now calls the function.
422 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
424         * sem_case.adb (Check_Against_Predicate): Correct off-by-one
425         error when reporting of missing values in a case statement for
426         a type with a static predicate.
427         (Check_Choices): Reject a choice given by a subtype to which a
428         Dynamic_Predicate applies.
429         * sem_ch3.adb (Analyze_Subtype_Declaration): Inherit
430         Has_Dynamic_Predicate_Aspect flag from parent.
432 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
434         * sem_ch13.adb (Analyze_Aspect_Specifications): A predicate
435         cannot apply to a subtype of an incomplete type.
436         (Is_Static_Choice): Treat an Others_Clause as static. The
437         staticness of the expression and of the range are checked
438         elsewhere.
440 2014-07-31  Pascal Obry  <obry@adacore.com>
442         * adaint.h (__gnat_ftell64): Added.
443         (__gnat_fseek64): Added.
444         (__int64): Added.
445         * cstreams.c (__int64): Removed.
447 2014-07-31  Pascal Obry  <obry@adacore.com>
449         * a-stream.ads (Stream_Element_Offset): Now a signed 64bit type.
450         * i-cstrea.ads, s-crtl.ads (fseek64): Offset is always a 64bit value.
451         (ftell64): Always returns a 64bit value.
452         * cstreams.c (int64): New definition.
453         (_FILE_OFFSET_BITS): Set to 64 to enable 64bit offset support.
454         (__gnat_ftell64): Always returns a 64bit value. The implemenation now
455         uses ftello() on UNIX.
456         (__gnat_fseek64): Offset is always a 64bit value. The
457         implementation now uses fseeko() on UNIX.
458         * a-ststio.adb, s-direio.adb (Set_Position): Simplify code,
459         always use fseek64 to set the offset.
460         (Size): Simplify code, always use fseek64/ftell64.
461         * s-direio.ads (Count): Now an int64.
462         * g-socket.ads (Vector_Element): Adjust definition for Length
463         to be a size_t. This matches the C definition and avoid using
464         a 64bit integer on 32bit platforms now that Count is always 64bit.
465         * g-socthi-mingw.adb (Ada.Streams): Removed as not used anymore.
466         (C_Recvmsg): Change some conversion to account for change in
467         Vector_Element.
468         (C_Sendmsg): Likewise.
470 2014-07-31  Robert Dewar  <dewar@adacore.com>
472         * cstand.adb (Create_Standard): Remove handling of -gnatdm flag.
473         * debug.adb: Remove documentation of -gnatdm flag.
474         * gnat1drv.adb (Adjust_Global_Switches): Remove handling of
475         -gnatdm flag.
477 2014-07-31  Arnaud Charlet  <charlet@adacore.com>
479         * lib-writ.adb (Write_Unit_Information): Fix case where U =
480         No_Unit.
482 2014-07-31  Claire Dross  <dross@adacore.com>
484         * exp_util.adb, exp_util.ads
485         (Get_First_Parent_With_External_Axiomatization_For_Entity):
486         New routine to find the first parent of an entity with
487         a pragma Annotate (GNATprove, External_Axiomatization).
488         (Has_Annotate_Pragma_For_External_Axiomatization): New function
489         to check if a package has a pragma Annotate (GNATprove,
490         External_Axiomatization).
491         * einfo.ads, einfo.adb (Is_Generic_Actual_Subprogram): New
492         flag on the entity for the declaration created for a formal
493         subprogram in an instance. This is a renaming declaration,
494         or in GNATprove_Mode the declaration of an expression function
495         that captures the axiomatization of the actual.
496         * sem_ch6.adb (Analyze_Expression_Function): For a
497         Generic_Actual_Subprogram, place body immediately after the
498         declaration because it may be used in a subsequent declaration
499         in the instance.
500         * sem_ch12.adb (Build_Wrapper): Add code to handle instances where
501         the actual is a function, not an operator. Handle functions with
502         one and two parameters and binary and unary operators.
504 2014-07-31  Pascal Obry  <obry@adacore.com>
506         * cstreams.c (__gnat_is_regular_file_fd): Removed.
507         * adaint.c (__gnat_is_regular_file_fd): Added.
509 2014-07-31  Robert Dewar  <dewar@adacore.com>
511         * exp_strm.adb: Minor reformatting.
513 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
515         * sem_ch12.adb (Build_Wrapper): New procedure, subsidiary to
516         Analyze_Associations, to create a wrapper around operators that
517         are actuals to formal subprograms. This is done in GNATProve
518         mode in order to propagate the contracts of the operators to
519         the body of the instance.
521 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
523         * sem_attr.adb (Analyze_Attribute, case 'Old):  The reference is
524         legal if within an aspect specification for a generic subprogram.
526 2014-07-31  Javier Miranda  <miranda@adacore.com>
528         * gnat1drv.adb (Back_End_Inlining): Set to false if
529         Suppress_All_Inlining is set.
530         * debug.adb: Adding documentation for -gnatd.z.
531         * inline.adb (Add_Inlined_Body): Extend the -gnatn2
532         processing to -gnatn1 for calls to Inline_Always routines.
533         (Add_Inlined_Subprogram): Remove previous patch.
535 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
537         * sem_ch13.adb (Check_One_Function): Apply properly the static
538         semantic rules for indexing aspects and the functions they denote.
540 2014-07-31  Javier Miranda  <miranda@adacore.com>
542         * debug.adb: Complete documentation of -gnatd.z.
544 2014-07-31  Bob Duff  <duff@adacore.com>
546         * gnat_ugn.texi: Minor doc fixes.
548 2014-07-31  Robert Dewar  <dewar@adacore.com>
550         * sem_aggr.adb (Resolve_Array_Aggregate): Fix posting of missing
551         index value.
553 2014-07-31  Tristan Gingold  <gingold@adacore.com>
555         * s-unstyp.ads (Packed_Byte): Make this type universal aliasing.
556         (Packed_Bytes1): Make component aliased.
558 2014-07-31  Robert Dewar  <dewar@adacore.com>
560         * s-unstyp.ads, s-fileio.adb: Minor reformatting.
562 2014-07-31  Robert Dewar  <dewar@adacore.com>
564         * inline.adb, gnat1drv.adb, exp_ch6.adb, s-fileio.adb: Minor
565         reformatting.
567 2014-07-31  Eric Botcazou  <ebotcazou@adacore.com>
569         * gcc-interface/utils2.c ((build_binary_op): Don't set TREE_THIS_NOTRAP
570         on array references here, now done more selectively in trans.c.
572 2014-07-31  Doug Rupp  <rupp@adacore.com>
574         * gcc-interface/misc.c (gnat_init_gcc_fp(): Set flag_errno_math to 0.
576 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
578         * sem_util.adb (Is_Effectively_Volatile): New routine.
580 2014-07-31  Fedor Rybin  <frybin@adacore.com>
582         * gnat_ugn.texi: Document --test-duration option for gnattest.
584 2014-07-31  Javier Miranda  <miranda@adacore.com>
585             Eric Botcazou  <ebotcazou@adacore.com>
587         * opt.ads (Back_End_Inlining): New variable which controls
588         activation of inlining by back-end expansion.
589         * gnat1drv.adb (Adjust_Global_Switches): Initialize Back_End_Inlining
590         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Do not build
591         the body to be inlined by the frontend if Back_End_Inlining
592         is enabled.
593         * exp_ch6.adb (Register_Backend_Call): Moved to inline.adb.
594         (Expand_Call): If backend inlining is enabled let the backend to
595         handle inlined subprograms.
596         * inline.ads (Register_Backend_Call): Moved here from exp_ch6
597         * inline.adb (Register_Backend_Call): Moved here from exp_ch6.
598         (Add_Inlined_Subprogram): Add subprograms when Back_End_Inlining is set.
599         (Must_Inline): Do not return Inline_Call if Back_End_Inlining is
600         enabled.
601         * debug.adb Document -gnatd.z
602         * fe.h Import Back_End_Inlining variable.
603         * gcc-interface/utils.c (create_subprog_decl): If Back_End_Inlining is
604         enabled then declare attribute "always inline"
605         * gcc-interface/decl.c, gcc-interface/trans.c,
606         gcc-interface/gigi.h: Add handling of Inline_Always pragma.
608 2014-07-31  Robert Dewar  <dewar@adacore.com>
610         * a-ngelfu.ads: Minor comment fix.
612 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
614         * freeze.adb (Freeze_Record_Type): Replace all calls to
615         Is_SPARK_Volatile with Is_Effectively_Volatile and update
616         related comments.
617         * sem_ch3.adb (Analyze_Object_Contract, Process_Discriminants):
618         Replace all calls to Is_SPARK_Volatile with
619         Is_Effectively_Volatile and update related comments.
620         * sem_ch5.adb (Analyze_Iterator_Specification,
621         Analyze_Loop_Parameter_Specification): Replace all calls to
622         Is_SPARK_Volatile with Is_Effectively_Volatile and update
623         related comments.
624         * sem_ch6.adb (Process_Formals): Replace all calls to
625         Is_SPARK_Volatile with Is_Effectively_Volatile and update
626         related comments.
627         * sem_ch12.adb (Instantiate_Object): Replace the call to
628         Is_SPARK_Volatile_Object with Is_Effectively_Volatile_Object
629         and update related comment.
630         * sem_prag.adb (Analyze_External_Property_In_Decl_Part,
631         Analyze_Global_Item): Replace all calls to Is_SPARK_Volatile
632         with Is_Effectively_Volatile and update related comments.
633         * sem_res.adb (Resolve_Actuals, Resolve_Entity_Name): Replace
634         all calls to Is_SPARK_Volatile with Is_Effectively_Volatile and
635         update related comments.
636         * sem_util.adb (Has_Enabled_Property,
637         Variable_Has_Enabled_Property): Replace all calls
638         to Is_SPARK_Volatile with Is_Effectively_Volatile and
639         update related comments.
640         (Is_Effectively_Volatile): New routine.
641         (Is_Effectively_Volatile_Object): New routine.
642         (Is_SPARK_Volatile): Removed.
643         (Is_SPARK_Volatile_Object): Removed.
644         * sem_util.ads (Is_Effectively_Volatile): New routine.
645         (Is_Effectively_Volatile_Object): New routine.
646         (Is_SPARK_Volatile): Removed.
647         (Is_SPARK_Volatile_Object): Removed.
649 2014-07-31  Pascal Obry  <obry@adacore.com>
651         * s-fileio.adb (Open): Make sure a shared file gets inserted into
652         the global list atomically. This ensures that the file descriptor
653         won't be freed because another tasks is closing the file.
655 2014-07-31  Robert Dewar  <dewar@adacore.com>
657         * sem_ch3.adb (Process_Range_Expr_In_Decl): Add comments on
658         generation of _FIRST and _LAST variables even in GNATprove_Mode.
659         * gnat_ugn.texi: Minor editing.
660         * sem_prag.adb (Ensure_Aggregate_Form): Make sure generated
661         aggregate is marked Comes_From_Source if argument is CFS.
663 2014-07-31  Pascal Obry  <obry@adacore.com>
665         * s-fileio.adb: Remove obsolete comment.
667 2014-07-31  Vincent Celier  <celier@adacore.com>
669         * a-strbou.ads ("=" (Bounded_String, Bounded_String): Add
670         overriding keyword before function to avoid error when compiler
671         is called with -gnatyO (check overriding indicators).
673 2014-07-31  Tucker Taft  <taft@adacore.com>
675         * gnat_ugn.texi: Add a paragraph pointing the reader
676         to the "plugins" example.
678 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
680         * freeze.adb (Freeze_Expression): Document the
681         purpose of the parent chain traversal.
683 2014-07-31  Robert Dewar  <dewar@adacore.com>
685         * checks.ads, checks.adb (Activate_Overflow_Check): Do not set flag for
686         unconstrained fpt ops.
688 2014-07-31  Pascal Obry  <obry@adacore.com>
690         * s-fileio.adb (Open): Make sure a shared file gets inserted into
691         the global list atomically. This ensures that the file descriptor
692         won't be freed because another tasks is closing the file.
694 2014-07-31  Vincent Celier  <celier@adacore.com>
696         * projects.texi: Minor spelling error fix.
698 2014-07-31  Robert Dewar  <dewar@adacore.com>
700         * gnat_rm.texi: Document No_Elaboration_Code_All restriction.
701         * lib-writ.adb, lib-load.adb: Initialize No_Elab_Code field in unit
702         information.
703         * lib.ads, lib.adb (No_Elab_Code): New field in unit information.
704         * restrict.adb (Process_Restriction_Synonyms): Add handling
705         of No_Elaboration_Code_All.
706         * restrict.ads (Process_Restriction_Synonyms): Now handles
707         No_Elaboration_Code_All.
708         * sem_ch10.adb (Analyze_Context): Enforce transitive with for
709         No_Elaboration_Code_All.
710         * sem_prag.adb (Process_Restrictions_Or_Restriction_Warnings):
711         Handle setting of No_Elab_Code in unit information. Handle
712         No_Elaboration_Code_All.
713         * snames.ads-tmpl (Name_No_Elaboration_Code): New name for
714         pragma processing.
715         (Name_No_Elaboration_Code_All): New name for pragma processing.
717 2014-07-31  Eric Botcazou  <ebotcazou@adacore.com>
719         * exp_aggr.adb (Aggr_Assignment_OK_For_Backend): Reject array
720         types with a null range and use the Esize of the component
721         instead of its RM_Size to identify appropriate values.
723 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
725         * freeze.adb Add with and use clause for Aspects.
726         (Freeze_Expression): Emit an error when a volatile constant lacks
727         Boolean aspect Import.
728         (Has_Boolean_Aspect_Import): New routine.
730 2014-07-31  Gary Dismukes  <dismukes@adacore.com>
732         * exp_util.adb: Minor reformatting.
734 2014-07-31  Vincent Celier  <celier@adacore.com>
736         * errutil.adb (Error_Msg): Make sure that all components of
737         the error message object are initialized.
739 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
741         * sem_ch4.adb (Try_Container_Indexing): If the container type is
742         class-wide, use specific type to locate iteration primitives.
743         * sem_ch13.adb (Check_Indexing_Functions): Add legality checks for
744         rules in RM 4.1.6 (Illegal_Indexing): New diagnostic procedure.
745         Minor error message reformating.
746         * exp_ch5.adb (Expand_Iterator_Loop): Handle properly Iterator
747         aspect for a derived type.
749 2014-07-31  Robert Dewar  <dewar@adacore.com>
751         * debug.adb: Document debug flag d.X.
753 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
755         * sem_util.ads (Find_Specific_Type): Moved here from exp_disp.adb.
756         * sem_util.adb (Find_Specific_Type): If type is untagged private,
757         retrieve full view so that primitive operations can be located.
758         * exp_disp.adb Move Find_Specific_Type to sem_util.
759         * exp_ch4.adb (Expand_N_Op_Eq): If operands are class-wide, use
760         Find_Specific_Type to locate primitive equality.
761         * exp_util.adb (Make_CW_Equivalent_Type): A class_wide equivalent
762         type does not require initialization.
763         * exp_attr.adb (Compile_Stream_Body_In_Scope): Within an instance
764         body all visibility is established, and the enclosing package
765         declarations must not be installed.
767 2014-07-31  Yannick Moy  <moy@adacore.com>
769         * sem_parg.adb, sem_prag.ads (Collect_Subprogram_Inputs_Outputs):
770         Make subprogram public.
772 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
774         * exp_ch9.adb (Expand_N_Protected_Type_Declaration): New
775         predicate Discriminated_Size, to distinguish between private
776         components that depend on discriminants from those whose size
777         depends on some other non-static expression.
779 2014-07-31  Nicolas Setton  <setton@adacore.com>
781         * g-exptty.adb (Close): Fix binding to Waitpid: use the
782         tty version.
784 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
786         * sem_ch3.adb (Make_Index): Reject properly the use of 'Length
787         in a discrete range, when 'range was probably intended.
789 2014-07-31  Robert Dewar  <dewar@adacore.com>
791         * sem_warn.adb, sem_warn.ads (Has_Junk_Name): Moved from body to spec.
793 2014-07-31  Robert Dewar  <dewar@adacore.com>
795         * frontend.adb: Minor reformatting.
796         * sem.adb: Minor reformatting.
797         * sem_ch6.adb (Analyze_Null_Procedure): Set proper sloc for
798         identifiers on rewrite.
799         * par.adb: Minor comment updates.
800         * a-ngelfu.adb (Cos): Minor simplification.
801         * par-ch13.adb (Get_Aspect_Specifications): Improve messages
802         and recovery for bad aspect.
803         * exp_ch3.adb: Code clean up.
804         * sem_util.ads: Minor comment correction.
805         * sem_ch13.adb (Check_Array_Type): Properly handle large types.
806         * sem_ch3.adb: Code clean up.
807         * binderr.ads: Minor comment correction.
809 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
811         * exp_disp.adb (Expand_Interface_Conversion): A call whose
812         prefix is a static conversion to an interface type that is not
813         class-wide is not dispatching.
815 2014-07-31  Robert Dewar  <dewar@adacore.com>
817         * inline.adb, s-traceb.adb, s-traceb-hpux.adb, memtrack.adb,
818         s-traceb-mastop.adb: Minor reformatting.
820 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
822         * exp_ch3.adb (Expand_Record_Extension): In ASIS_Mode perform
823         expansion, to handle properly visibility of selected components
824         in instance bodies.
826 2014-07-31  Robert Dewar  <dewar@adacore.com>
828         * par-ch13.adb (Get_Aspect_Specifications): Set Inside_Depends.
829         * par-ch2.adb (P_Pragma): Set Inside_Depends.
830         * par-ch4.adb (P_Simple_Expression): Pass Inside_Depends to
831         Check_Unary_Plus_Or_Minus.
832         * scans.ads (Inside_Depends): New flag.
833         * scng.adb (Scan): Pass Inside_Depends to Check_Arrow.
834         * style.ads: Add Inside_Depends parameter to Check_Arrow Add
835         Inside_Depends parameter to Check_Unary_Plus_Or_Minus.
836         * styleg.adb (Check_Arrow): Handle Inside_Depends case.
837         (Check_Unary_Plus_Or_Minus): Handle Inside_Depends case.
838         * styleg.ads: Add Inside_Depends parameter to Check_Arrow Add.
839         Inside_Depends parameter to Check_Unary_Plus_Or_Minus.
841 2014-07-31  Javier Miranda  <miranda@adacore.com>
843         * s-vaflop.adb Move the body of function T_To_G before
844         T_To_D. Required for frontend inlining.
845         * inline.adb (Has_Excluded_Contract): New subprogram used to
846         check if a subprogram inlined by the frontend has contracts
847         which cannot be inlined.
849 2014-07-31  Bob Duff  <duff@adacore.com>
851         * s-traceb.adb, s-traceb-hpux.adb, s-traceb-mastop.adb:
852         (Call_Chain): Add 1 to number of frames to skip, to account for
853         the fact that there's one more frame on the stack.
854         * gcc-interface/Makefile.in (s-traceb.o): Adjust rules.
856 2014-07-31  Robert Dewar  <dewar@adacore.com>
858         * checks.adb (Enable_Overflow_Check): More precise setting of
859         Do_Overflow_Check flag for division.
861 2014-07-31  Eric Botcazou  <ebotcazou@adacore.com>
863         * exp_aggr.adb (Aggr_Assignment_OK_For_Backend): Reject packed
864         array types with implementation type.
866 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
868         * sem_ch10.adb (Process_State): Remove local variable Name. Add
869         local variable Decl. Partially declare an abstract state by
870         generating an entity and storing it in the state declaration.
871         * sem_prag.adb (Create_Abstract_State): Fully declare a
872         semi-declared abstract state.
874 2014-07-31  Robert Dewar  <dewar@adacore.com>
876         * prj-nmsc.adb: Minor reformatting.
878 2014-07-31  Bob Duff  <duff@adacore.com>
880         * s-tasdeb.adb (System.Tasking.Debug): Remove
881         all usage of the secondary stack from this package.
883 2014-07-31  Hristian Kirtchev  <kirtchev@adacore.com>
885         * freeze.adb (Freeze_Expression): Update the loop in charge
886         of finding a proper insertion place for freeze nodes to handle
887         N_Expression_With_Actions nodes.
889 2014-07-31  Robert Dewar  <dewar@adacore.com>
891         * sem_util.adb, a-ngelfu.ads, prj-nmsc.adb, prj-conf.adb: Minor
892         reformatting.
894 2014-07-31  Pascal Obry  <obry@adacore.com>
896         * prj-nmsc.adb: Minor reformatting.
898 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
900         * sem_util.adb (Has_Preelaborable_Initialization): Check that
901         type is tagged before checking whether a user-defined Initialize
902         procedure is present.
904 2014-07-31  Gary Dismukes  <dismukes@adacore.com>
906         * a-ngelfu.ads (Sqrt): Augment postcondition.
908 2014-07-31  Pascal Obry  <obry@adacore.com>
910         * prj-nmsc.adb (Check_Library_Attributes): An aggegate library
911         directory and ALI directory must be different than all object
912         and library directories of aggregated projects.
914 2014-07-31  Vincent Celier  <celier@adacore.com>
916         * prj-pars.adb, prj-conf.ads, prj-conf.adb (Locate_Runtime): Move spec
917         to package body, as it is not called from outside. Remove argument
918         Project_Tree, no longer used. When runtime cannot be found,
919         call Raise_Invalid_Config instead of failing the program.
921 2014-07-31  Robert Dewar  <dewar@adacore.com>
923         * bindgen.adb (Gen_Output_File_Ada): Generate pragma Suppress
924         (Overflow_Check).
925         * gnatlink.adb (Process_Args): Remove generation of -gnato0,
926         no longer needed.
928 2014-07-31  Robert Dewar  <dewar@adacore.com>
930         * gnat_ugn.texi: Document new switch -gnato0.
931         * sem_ch3.ads: Minor reformatting.
932         * gnatlink.adb (Process_Args): Compile bind file with -gnato0
933         (we do not want overflow checks when incrementing elaboration
934         counters).
935         * einfo.ads: Minor reformatting.
937 2014-07-31  Robert Dewar  <dewar@adacore.com>
939         * exp_ch5.adb, freeze.adb, exp_ch3.adb: Minor comment correction.
940         * s-arit64.adb: Minor reformatting.
942 2014-07-31  Robert Dewar  <dewar@adacore.com>
944         * gnat1drv.adb (Adjust_Global_Switches): Default for overflow
945         checking is enabled except in GNAT_Mode.
946         * switch-c.adb (Scan_Front_End_Switches): Implement -gnato0
947         (suppress overflow checks).
949 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
951         * exp_ch3.adb (Expand_Freeze_Record_Type): Do not build an
952         invariant procedure for an internally generated subtype that is
953         created for an object of a class-wide type.
955 2014-07-31  Vincent Celier  <celier@adacore.com>
957         * prj-nmsc.adb, errutil.adb: Make code similar to Errout.
959 2014-07-31  Gary Dismukes  <dismukes@adacore.com>
961         * gnat_rm.texi, sem_aux.ads, einfo.ads, sem_util.ads, sem_ch6.adb,
962         exp_disp.adb: Minor reformatting.
964 2014-07-31  Robert Dewar  <dewar@adacore.com>
966         * exp_ch5.adb, sem_ch3.adb, exp_ch7.adb, exp_util.adb, exp_ch9.adb,
967         sem_ch7.adb, checks.adb, s-exctra.adb, exp_ch6.adb, exp_disp.adb,
968         exp_dist.adb, sem_ch13.adb, exp_strm.adb, exp_ch3.adb: Minor
969         reformatting.
971 2014-07-31  Robert Dewar  <dewar@adacore.com>
973         * sem_ch13.adb: Minor reformatting.
975 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
977         * exp_ch3.adb (Build_Invariant_Checks): If the enclosing record
978         is an unchecked_union, warn that invariants will not be checked
979         on components that have them.
981 2014-07-31  Robert Dewar  <dewar@adacore.com>
983         * freeze.adb (Freeze_Entity): Check for error of
984         Type_Invariant'Class applied to a untagged type.
985         * sem_ch6.adb (Analyze_Null_Procedure): Unconditionally rewrite
986         as null body, so that we perform error checks even if expansion
987         is off.
989 2014-07-31  Ed Schonberg  <schonberg@adacore.com>
991         * sem_ch13.adb (Build_Invariant_Procedure): If body of procedure
992         is already present, nothing to do.
993         * exp_ch3.adb (Build_Component_Invariant_Call): For an access
994         component, check whether the access type has an invariant before
995         checking the designated type.
996         (Build_Record_Invariant_Proc): Change suffix of generated
997         name to prevent ambiguity when record type has invariants
998         in addition to those of components, and two subprograms are
999         constructed. Consistent with handling of array types.
1000         (Insert_Component_Invariant_Checks): Build invariant procedure
1001         body when one has not been created yet, in the case of composite
1002         types that are completions and whose full declarations carry
1003         invariants.
1005 2014-07-30  Thomas Quinot  <quinot@adacore.com>
1007         * gnat_rm.texi: Minor doc fixes.
1009 2014-07-30  Robert Dewar  <dewar@adacore.com>
1011         * a-rbtgbo.adb, sem_ch13.adb: Minor reformatting.
1013 2014-07-30  Vincent Celier  <celier@adacore.com>
1015         * errutil.adb (Set_Msg_Text): Process tilde ('~'): no processing
1016         of error message.
1017         * prj-nmsc.adb (Locate_Directory): Use a tilde ('~') in the
1018         message to report that a directory cannot be created, to avoid
1019         processing of the directory path that may contains special
1020         insertion characters.
1022 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1024         * a-crdlli.ads: Place declaration of Empty_List after full type
1025         declaration for Curosr, to prevent freezing error.
1027 2014-07-30  Robert Dewar  <dewar@adacore.com>
1029         * get_targ.adb: Minor code reorganization.
1030         * prj-proc.adb, prj-proc.ads, get_targ.ads, sem_ch6.adb: Minor
1031         reformatting.
1033 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1035         * a-cbhase.adb: a-cbhase.adb (Insert): Raise Constraint_Error,
1036         not Program_Error, when attempting to remove an element not in
1037         the set. This is the given semantics for all set containers.
1039 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1041         * a-rbtgbo.adb (Delete_Node_Sans_Free): If
1042         element is not present in tree return rather than violating
1043         an assertion. Constraint_Error will be raised in the caller if
1044         element is not in the container.
1046 2014-07-30  Arnaud Charlet  <charlet@adacore.com>
1048         * set_targ.adb (Read_Target_Dependent_Values): New subprogram.
1049         (elab body): Add provision for default target config file.
1050         * get_targ.ads, get_targ.adb (Get_Back_End_Config_File): New subprogram.
1052 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1054         * a-cbhase.adb (Delete): Raise Constraint_Error, not Program_Error,
1055         when attempting to remove an element not in the set. This is
1056         the given semantics for all set containers.
1057         * a-cborse.adb (Delete): Attempt removal first, to check for
1058         tampering, before checking whether this is an attempt to
1059         delete a  non-existing element, and in fthe latter case raise
1060         Constraint_Error.
1062 2014-07-30  Vincent Celier  <celier@adacore.com>
1064         * prj-proc.adb (Recursive_Process): Do not create a new
1065         Project_Id if the project is already in the list of projects of
1066         the tree.
1068 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1070         * sem_ch6.adb (Analyze_Function_Return): Reject a return expression
1071         whose type is an incomplete formal type.
1072         (Analyze_Return_Type): Reject a return type that is an untagged
1073         imcomplete formal type.
1074         (Process_Formals): Reject a formal parameter whose type is an
1075         untagged formal incomplete type.
1076         * sem_res.adb (Resolve_Actuals): Reject an actual whose type is
1077         an untagged formal incomplete type.
1079 2014-07-30  Robert Dewar  <dewar@adacore.com>
1081         * gnat_ugn.texi: Minor spelling correction.
1082         * makeutl.adb: Minor code reorganization.
1083         * exp_ch4.adb, exp_aggr.adb, exp_ch3.adb: Minor reformatting.
1085 2014-07-30  Robert Dewar  <dewar@adacore.com>
1087         * einfo.ads (Has_Unchecked_Union): Document that this is used
1088         to check for illegal Valid_Scalars attribute references.
1089         * exp_attr.adb (Build_Record_VS_Func): New function
1090         (Expand_N_Attribute_Reference, case Valid_Scalars): Call this
1091         function.
1092         * gnat_rm.texi: Document 'Valid_Scalars cannot be applied to
1093         Unchecked_Union Add note on 'Valid_Scalars generating a lot
1094         of code.
1095         * sem_attr.adb (Analyze_Attribute, case Valid_Scalars): Give
1096         error on attempt to apply Valid_Scalars to Unchecked_Union type.
1098 2014-07-30  Steve Baird  <baird@adacore.com>
1100         * exp_ch4.adb (Expand_N_Indexed_Component): Disable optimized handling
1101         of A(I..J)(K) in CodePeer_Mode.
1103 2014-07-30  Ben Brosgol  <brosgol@adacore.com>
1105         * gnat_ugn.texi: Fix typo.
1107 2014-07-30  Thomas Quinot  <quinot@adacore.com>
1109         * lib-writ.ads: document format change.
1111 2014-07-30  Pascal Obry  <obry@adacore.com>
1113         * prj-util.adb (For_Interface_Sources): Do not
1114         include sources from withed externally built projects.
1116 2014-07-30  Robert Dewar  <dewar@adacore.com>
1118         * lib.adb: Minor reformatting.
1119         * prj-util.adb: Minor reformatting.
1121 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1123         * exp_aggr.adb (Build_Record_Aggr_Code): For an array component
1124         that depends on discriminants, and which is given by an others
1125         clause, create an explicit subtype with the discriminant values
1126         of the enclosing aggregate, because the backend cannot otherwise
1127         retrieve the actual bounds of the array.
1129 2014-07-30  Fedor Rybin  <frybin@adacore.com>
1131         * gnat_ugn.texi: Improve gnattest documentation.
1133 2014-07-30  Pascal Obry  <obry@adacore.com>
1135         * makeutl.adb (Insert_Project_Sources): Properly handle sources
1136         that are aggregated. We want to include sources not only part
1137         of libraries but also if part of an aggregated project from an
1138         aggregate library.
1139         * prj.adb (For_Project_And_Aggregated_Context): Properly check
1140         state of root project.
1142 2014-07-30  Thomas Quinot  <quinot@adacore.com>
1144         * lib-load.ads: Minor reformatting.
1145         * sinfo.ads (Library_Unit): Update comment.
1146         * lib.ads (Notes): Simplify. The Unit component in Notes_Entry
1147         is redundant. Instead used the pragma Node_Id directly as the
1148         element type.
1150 2014-07-30  Thomas Quinot  <quinot@adacore.com>
1152         * lib.adb (Store_Note): Store only notes that do not come from
1153         an instance, and that are in the extended main source unit.
1154         * lib-writ (Write_Unit_Information): Annotations from subunits
1155         must be emitted along with those for the main unit, and they
1156         must carry a specific file name.
1157         * ali.ads (Notes_Record): Use a File_Name_Type instead of a
1158         Unit_Id for the source file containing the pragma, as in the
1159         case of annotations from subunits we might not have a readily
1160         available unit id.
1161         * ali.adb (Scan_ALI): Account for above change in data structure.
1163 2014-07-30  Vincent Celier  <celier@adacore.com>
1165         * makeutl.adb (Insert_Project_Sources): When the library project
1166         is an aggregate Stand-Alone Library, insert in the queue the
1167         Ada interface units, with Closure set to True;
1169 2014-07-30  Eric Botcazou  <ebotcazou@adacore.com>
1171         * sem_util.adb: Fix minor typo.
1172         * makeutl.adb: Minor reformatting.
1174 2014-07-30  Robert Dewar  <dewar@adacore.com>
1176         * exp_ch7.adb, checks.adb, makeutl.adb, makeutl.ads: Minor reformatting.
1178 2014-07-30  Yannick Moy  <moy@adacore.com>
1180         * checks.ads: Fix typo in comment.
1182 2014-07-30  Pierre-Marie Derodat  <derodat@adacore.com>
1184         * sem_util.adb (Set_Debug_Info_Needed): For scalar types, recurse on
1185         entities that materialize range bounds, if any.
1187 2014-07-30  Vincent Celier  <celier@adacore.com>
1189         * projects.texi: Minor spelling fix.
1191 2014-07-30  Hristian Kirtchev  <kirtchev@adacore.com>
1193         * checks.adb (Make_Bignum_Block): Use the new secondary stack
1194         build routines to manage the mark.
1195         * exp_ch7.adb (Create_Finalizer, Expand_Cleanup_Actions):
1196         Use the new secodary stack build routines to manage the mark.
1197         (Insert_Actions_In_Scope_Around): Add new formal parameter
1198         Manage_SS along with comment on its usage. Code and comment
1199         reformatting. Mark and release the secondary stack when the
1200         context warrants it.
1201         (Make_Transient_Block): Update the call
1202         to Insert_Actions_In_Scope_Around to account for parameter Manage_SS.
1203         (Wrap_Transient_Declaration): Remove local variable
1204         Uses_SS. Ensure that the secondary stack is marked and released
1205         when the related object declaration appears in a library level
1206         package or package body. Code and comment reformatting.
1207         * exp_util.ads, exp_util.adb (Build_SS_Mark_Call): New routine.
1208         (Build_SS_Release_Call): New routine.
1210 2014-07-30  Steve Baird  <baird@adacore.com>
1212         * exp_attr.adb: Revert previous change, not needed after all.
1214 2014-07-30  Vincent Celier  <celier@adacore.com>
1216         * makeutl.adb (Queue.Insert_Project_Sources): Insert with
1217         Closure => True for interfaces of Stand-Alone Libraries.
1218         * makeutl.ads (Source_Info (Format => Gprbuild)): Add new
1219         Boolean component Closure, defaulted to False.
1221 2014-07-30  Yannick Moy  <moy@adacore.com>
1223         * sem_res.adb: Fix typo in error message.
1225 2014-07-30  Robert Dewar  <dewar@adacore.com>
1227         * sem_ch3.adb (Process_Range_Expr_In_Decl): Use _FIRST/_LAST
1228         as name suffixes rather than L/H for subtype bounds.
1229         * tbuild.ads: Minor comment improvements and fixes
1230         (Make_External_Name): Document that suffix can start with an
1231         underscore.
1233 2014-07-30  Bob Duff  <duff@adacore.com>
1235         * gnat_ugn.texi: Document --rep-clauses switch.
1237 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1239         * sem_ch13.adb (Analyze_Aspect_Specifications): Default_Value and
1240         Default_Component_Value can only be specified for scalar type or
1241         arrays of scalar types respectively.  This legality check must
1242         be performed at the point the aspect is analyzed, in order to
1243         reject aspect specifications that apply to a partial view.
1245 2014-07-30  Thomas Quinot  <quinot@adacore.com>
1247         * freeze.adb: Minor reformatting.
1249 2014-07-30  Robert Dewar  <dewar@adacore.com>
1251         * exp_attr.adb (Expand_Attribute, case First/Last): Don't expand in
1252         codepeer mode.
1254 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1256         * freeze.adb (Check_Expression_Function): At the freeze point
1257         of an expression function, verify that the expression in the
1258         function does not contain references to any deferred constants
1259         that have no completion yet.
1260         (Freeze_Expression, Freeze_Before): call
1261         Check_Expression_Function.
1262         * a-ciorse.ads: Add Reference_Control_Type to detect tampering.
1263         * a-ciorse.adb: Add Adjust and Finalize routines for
1264         Reference_Control_Type. Use it in the construction of Reference
1265         and Constant_Reference values.
1267 2014-07-30  Robert Dewar  <dewar@adacore.com>
1269         * exp_aggr.adb: Update comments.
1270         * a-chtgbo.adb, a-chtgbo.ads, a-cbhase.adb, a-cbhase.ads: Minor
1271         reformatting.
1273 2014-07-30  Robert Dewar  <dewar@adacore.com>
1275         * cstand.adb (New_Standard_Entity): New version takes name
1276         string to call Make_Name.
1277         (Create_Standard): Use this routine to set name before setting other
1278         fields.
1280 2014-07-30  Robert Dewar  <dewar@adacore.com>
1282         * exp_attr.adb (Expand_Attribute, case First): Rewrite simple
1283         entity reference.
1284         (Expand_Attribute, case Last): Ditto.
1285         * exp_ch3.adb (Constrain_Index): New calling sequence for
1286         Process_Range_Expr_In_Decl.
1287         (Expand_N_Object_Declaration): Avoid setting Is_Known_Valid in one
1288         problematical case.
1289         * sem_ch3.adb (Constrain_Index): New calling sequence for
1290         Process_Range_Expr_In_Decl.
1291         (Set_Scalar_Range_For_Subtype): ditto.
1292         (Process_Range_Expr_In_Decl): Create constants to hold bounds for
1293         subtype.
1294         * sem_ch3.ads (Process_Range_Expr_In_Decl): Add Subtyp parameter.
1295         * sem_eval.adb (Compile_Time_Compare): Make sure we use base
1296         types if we are not assuming no invalid values.
1298 2014-07-30  Robert Dewar  <dewar@adacore.com>
1300         * clean.adb: Minor reformatting.
1301         * opt.ads: Minor fix to incorrect comment.
1303 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1305         * a-chtgbo.ads, a-chtgbo.adb (Delete_Node_At_Index): New
1306         subprogram, used by bounded hashed sets, to delete a node at
1307         a given index, whose element may have been improperly updated
1308         through a Reference_Preserving key.
1309         * a-cbhase.ads: Add Reference_Control_Type to package Generic_Keys.
1310         * a-cbhase.adb: Add Adjust and Finalize routines for
1311         Reference_Control_Type.
1312         (Delete, Insert): Raise Program_Error, not Constraint_Error,
1313         when operation is illegal.
1314         (Reference_Preserving_Key): Build aggregate for Reference_Control_Type
1315         * a-cmbutr.ads: Add Reference_Control_Type to detect tampering. Add
1316         private with_clause for Ada.Finalization.
1317         * a-cbmutr.adb: Add Adjust and Finalize routines for
1318         Reference_Control_Type. Use it in the construction of Reference
1319         and Constant_Reference values.
1321 2014-07-30  Robert Dewar  <dewar@adacore.com>
1323         * sem_ch3.adb, sem_ch3.ads: Minor code reorganization.
1325 2014-07-30  Pascal Obry  <obry@adacore.com>
1327         * clean.adb (Clean_Project): Properly check for directory
1328         existence before trying to enter it.
1330 2014-07-30  Robert Dewar  <dewar@adacore.com>
1332         * sem_ch3.ads, prj.ads, prj-nmsc.adb: Minor reformatting.
1334 2014-07-30  Robert Dewar  <dewar@adacore.com>
1336         * par-ch5.adb (P_Sequence_Of_Statements): Properly handle
1337         missing semicolon after name.
1339 2014-07-30  Pascal Obry  <obry@adacore.com>
1341         * prj.ads (Gprinstall_Flags): New constant.
1342         * prj-nmsc.adb (Check_Library_Attributes): Do not fails for
1343         missing library dir if Directories_Must_Exist_In_Projects
1344         is false.
1346 2014-07-30  Bob Duff  <duff@adacore.com>
1348         * a-except-2005.adb, a-except.adb: Remove obsolete comments.
1349         * s-traceb.ads: Updagte comments.
1351 2014-07-30  Robert Dewar  <dewar@adacore.com>
1353         * checks.adb, a-cihase.adb, a-cihase.ads, a-chtgop.adb, a-chtgop.ads,
1354         a-except.adb, a-except-2005.adb, a-cborse.adb, a-cborse.ads,
1355         a-exexda.adb, a-elchha.adb, exp_aggr.adb, a-cohase.adb: Minor
1356         reformatting.
1358 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1360         * a-chtgop.ads, a-chtgop.adb (Delete_Node_At_Index): New
1361         subprogram, used by all versions of hashed sets, to delete a node
1362         whose element has been improperly updated through a Reference_
1363         Preserving key.
1364         * a-cohase.adb: Remove Delete_Node, use new common procedure
1365         Delete_Node_At_Index.
1366         * a-cihase.ads: Add Reference_Control_Type to package Generic_Keys.
1367         * a-cihase.adb: Add Adjust and Finalize routines for
1368         Reference_Control_Type.
1369         (Reference_Preserving_Key): Build aggregate for
1370         Reference_Control_Type
1372 2014-07-30  Yannick Moy  <moy@adacore.com>
1374         * checks.adb, checks.ads (Determine_Range_R): New procedure to
1375         determine the possible range of a floating-point expression.
1377 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1379         * a-cborse.ads: Add Reference_Control_Type to package Generic_Keys.
1380         * a-cborse.adb: Add Adjust and Finalize routines for
1381         Reference_Control_Type.
1382         (Reference_Preserving_Key): Build aggregate for
1383         Reference_Control_Type.
1384         (Delete): Check for tampering, and raise Program_Error (not
1385         Constraint_Error) when attempting to delete an element not in
1386         the set.
1387         (Insert): Ditto.
1389 2014-07-30  Bob Duff  <duff@adacore.com>
1391         * a-elchha.adb, a-except-2005.adb, a-except.adb, a-exexda.adb,
1392         * a-exextr.adb, a-exstat.adb, exp_intr.ads, s-tassta.adb:
1393         Exception_Information is used to produce useful debugging
1394         information for the programmer. However, it was also used to
1395         implement the stream attributes for type Exception_Occurrence. The
1396         latter requires a stable and portable interface, which meant
1397         that we couldn't include a symbolic traceback. A separate set of
1398         routines was used to provide symbolic tracebacks under program
1399         control (i.e. not automatically). The goal of this ticket is
1400         to provide such automatic tracebacks, so the change here is to
1401         split the two functionalities: Exception_Information gives the
1402         maximally useful information for debugging (i.e. it now includes
1403         a symbolic traceback when a decorator is set, and it can be
1404         improved freely in the future without disturbing streaming).
1405         Untailored_Exception_Information always uses hexadecimal addresses
1406         in the traceback, has a stable and portable output, and is now
1407         used for streaming.
1409 2014-07-30  Eric Botcazou  <ebotcazou@adacore.com>
1411         * exp_aggr.adb (Expand_Array_Aggregate): Add missing test
1412         on the target of the assignment to find out whether it
1413         can be directly done by the back-end.
1414         * exp_util.adb (Is_Possibly_Unaligned_Slice): Remove obscure test.
1416 2014-07-30  Robert Dewar  <dewar@adacore.com>
1418         * inline.adb, a-coorse.adb, a-coorse.ads, a-cohase.adb, a-cohase.ads,
1419         a-tasatt.adb: Minor reformatting.
1421 2014-07-30  Robert Dewar  <dewar@adacore.com>
1423         * exp_ch4.adb: Minor reformatting.
1425 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1427         * a-coorse.adb, a-coorse.ads (Generic_Keys): Add a
1428         Reference_Control_Type to generic package, to keep additional
1429         information for Reference_Types that manipulate keys. Add Adjust and
1430         Finalize procedures for this type.
1431         (Finalize): When finalizing a reference_preserving_key, verify
1432         that the key of the new value is equivalent to the key of the
1433         original element, raise Program_Error otherwise.
1434         (Insert): Detect tampering.
1435         (Reference_Preserving_Key): Build proper Reference_Control_Type,
1436         and update Busy and Lock bits to detect tampering.
1437         * a-cohase.ads: Keep with-clause private.
1439 2014-07-30  Hristian Kirtchev  <kirtchev@adacore.com>
1441         * exp_ch4.adb (Expand_N_Op_Eq): Emit a warning when the operands
1442         of an equality are of an Unchecked_Union type and lack inferable
1443         discriminants.
1445 2014-07-30  Bob Duff  <duff@adacore.com>
1447         * g-exctra.adb, g-exctra.ads, s-exctra.adb, s-exctra.ads, Makefile.rtl,
1448         g-trasym.adb, g-trasym.ads, s-trasym.adb, s-trasym.ads: Move
1449         GNAT.Traceback.Symbolic and GNAT.Exception_Traces into the System
1450         hierarchy (System.Traceback.Symbolic and System.Exception_Traces), so
1451         we can call them from the runtimes. Leave renamings in place under GNAT.
1453 2014-07-30  Yannick Moy  <moy@adacore.com>
1455         * inline.adb (Check_And_Build_Body_To_Inline): Include code for
1456         inlining in GNATprove mode.
1458 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1460         * a-cohase.adb, a-cohase.ads (Generic_Keys): Add a
1461         Reference_Control_Type to generic package, to keep additional
1462         information for Reference_Types that manipulate keys. Add Adjust and
1463         Finalize procedures for this type.
1464         (Delete_Node): New procedure called when finalizing a
1465         Reference_Control_Type, to remove a node whose element has been
1466         improperly updated through a Reference.
1467         (Insert): Detect tampering.
1468         (Reference_Preserving_Key): Build proper Reference_Control_Type,
1469         and update Busy and Lock bits to detect tampering.
1471 2014-07-30  Bob Duff  <duff@adacore.com>
1473         * exp_intr.ads: Minor comment fix.
1475 2014-07-30  Gary Dismukes  <dismukes@adacore.com>
1477         * exp_prag.adb, a-tags.ads: Minor typo fixes.
1479 2014-07-30  Bob Duff  <duff@adacore.com>
1481         * a-excach.adb, a-excach-cert.adb, a-except-2005.ads,
1482         a-except.ads, g-traceb.adb, memtrack.adb,
1483         s-traceb.adb, s-traceb.ads, s-traceb-hpux.adb, s-traceb-mastop.adb:
1484         Cleanup: Make the three versions of System.Traceback.Call_Chain
1485         have the same interface. Use an array for the Traceback parameter
1486         instead of an Address.  This will enable reduction in code
1487         duplication.
1489 2014-07-30  Pat Rogers  <rogers@adacore.com>
1491         * gnat_ugn.texi: Corrected minor textual error in description
1492         of switch -gnatwl.
1494 2014-07-30  Bob Duff  <duff@adacore.com>
1496         * Makefile.rtl: Sort file names.
1498 2014-07-30  Arnaud Charlet  <charlet@adacore.com>
1500         * a-tasatt.adb: Complete previous change: kill spurious warning
1501         on e.g. sparc, and make sure we only use the fast path when the
1502         alignment is compatible.
1504 2014-07-30  Yannick Moy  <moy@adacore.com>
1506         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Mark new Spec_Id as
1507         coming from source.
1509 2014-07-30  Yannick Moy  <moy@adacore.com>
1511         * inline.adb (Build_Body_To_Inline): Issue more precise messages
1512         for declarations that prevent inlining.
1513         (Cannot_Inline): Change usual start of message to refer to contextual
1514         analysis in GNATprove mode.
1515         * sem_res.adb (Resolve_Call): Change usual start of message to
1516         refer to contextual analysis in GNATprove mode, when inlining
1517         not possible.
1519 2014-07-30  Robert Dewar  <dewar@adacore.com>
1521         * sem_res.adb, sem_ch6.adb: Minor code reorganization.
1522         * inline.adb: Minor reformatting.
1524 2014-07-30  Javier Miranda  <miranda@adacore.com>
1526         * a-tags.ads: Add comments.
1528 2014-07-30  Pat Rogers  <rogers@adacore.com>
1530         * gnat_rm.texi: Minor word error.
1532 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1534         * exp_prag.adb (Expand_Old): Insert declarationss of temporaries
1535         created to capture the value of the prefix of 'Old at the
1536         beginning of the current declarative part, to prevent data flow
1537         anomalies in the postcondition procedure that will follow.
1539 2014-07-30  Yannick Moy  <moy@adacore.com>
1541         * debug.adb: Retire debug flag -gnatdQ.
1542         * inline.adb (Can_Be_Inlined_In_GNATprove_Mode): Check SPARK_Mode
1543         on decl, not on body.  Ignore predicate functions.
1544         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Remove use of
1545         debug flag -gnatdQ.  Correctly analyze SPARK_Mode on decl and
1546         body when generating a decl for a body on which SPARK_Mode aspect
1547         is given.
1548         * sem_prag.adb (Analyze_Pragma|SPARK_Mode): Reorder tests for
1549         attaching pragma to entity, to account for declaration not coming
1550         from source.
1551         * sem_res.adb (Resolve_Call): Issue warning and flag subprogram
1552         as not always inlined in GNATprove mode, when called in an
1553         assertion context.
1555 2014-07-30  Vincent Celier  <celier@adacore.com>
1557         * debug.adb: Minor comment update.
1559 2014-07-30  Robert Dewar  <dewar@adacore.com>
1561         * s-tasuti.adb, s-tassta.adb: Minor reformatting.
1562         * sprint.adb (Sprint_Node): Handle N_Contract case.
1563         * exp_prag.adb: Minor reformatting.
1564         * freeze.adb (Freeze_Entity): Check useless postcondition for
1565         No_Return subprogram.
1566         * sem_prag.adb: Minor reformatting.
1568 2014-07-30  Javier Miranda  <miranda@adacore.com>
1570         * a-tags.ads: Complete comments about performance.
1572 2014-07-30  Fedor Rybin  <frybin@adacore.com>
1574         * gnat_ugn.texi: Adding description for --exit-status option to
1575         gnattest section.  Fixing index entry of --passed-tests option
1576         in gnattest section.
1578 2014-07-30  Javier Miranda  <miranda@adacore.com>
1580         * Makefile.rtl, gnat_rm.texi, i-cpp.adb, i-cpp.ads, impunit.adb,
1581         rtsfind.ads: Remove references to package Interfaces.CPP since this
1582         package is no longer needed.
1584 2014-07-30  Bob Duff  <duff@adacore.com>
1586         * s-taasde.adb (Timer_Queue): Don't use a
1587         build-in-place function call to initialize the Timer_Queue.
1588         * s-traent.adb, s-traent.ads, s-traent-vms.adb, s-traent-vms.ads:
1589         Turn off polling in these units, because otherwise we get
1590         elaboration circularities with Ada.Exceptions when the -gnatP
1591         switch is used.
1592         * s-tassta.adb (Create_Task): Make sure independent tasks
1593         are created with Parent = Environment_Task. This was not true,
1594         for example, in s-interr.adb, when Interrupt_Manager does "new
1595         Server_Task"; the Server_Task had Parent = Interrupt_Manager,
1596         which is wrong because the master is determined by the access
1597         type, which is at library level.
1598         * s-tasuti.adb (Make_Independent): Avoid setting Parent; it is
1599         now set correctly by Create_Task.
1600         (Make_Passive): Remove the workaround for the race condition in
1601         Make_Independent.
1602         * frontend.adb (Frontend): Revert to previous method of detecting
1603         temporary configuration pragma files, recognizing such files by
1604         ".tmp" in the name. This is more general than detecting pragmas
1605         Source_File_Name_Project, because it allows any tool to use
1606         this naming convention, no matter the content of the file.
1607         * gnat_ugn.texi: Document this naming convention.
1609 2014-07-30  Robert Dewar  <dewar@adacore.com>
1611         * exp_ch7.adb, s-tataat.adb, s-tataat.ads, s-parame-vms-alpha.ads,
1612         inline.adb, s-parame-hpux.ads, exp_smem.adb, s-tasini.adb,
1613         s-tasini.ads, s-parame-vms-ia64.ads, s-parame.ads, s-taskin.ads,
1614         s-parame-vxworks.ads, a-tasatt.adb, a-tasatt.ads: Minor reformatting.
1615         * a-suenco.adb (Convert): Handle overlong encodings in UTF8-UTF8
1616         conversion.
1618 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1620         * sem_ch5.adb: Improve error recovery.
1621         * inline.adb (Build_Body_To_Inline): Set Full_Analysis to false
1622         before analyzing the body, so that in GNATprove mode there is
1623         no light expansion. Whatever expansion is required by SPARK will
1624         be performed when analysing the inlined code.
1626 2014-07-30  Bob Duff  <duff@adacore.com>
1628         * s-tataat.adb, s-tataat.ads, a-tasatt.adb: Minor comment fixes.
1630 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1632         * sem_ch5.adb (Analyze_Loop_Statement): If loop has a label,
1633         verify that it is not hidden by an inner implicit declaration.
1635 2014-07-30  Thomas Quinot  <quinot@adacore.com>
1637         * sem.ads (Scope_Table_Entry): New component Locked_Shared_Objects.
1638         * sem_ch8.adb (Push_Scope): Initialize Locked_Shared_Objects.
1639         * exp_smem.adb (Add_Shared_Var_Lock_Procs): Handle the case where
1640         the call returns an unconstrained type: in this case there is
1641         already a transient scope, and we should not establish a new one.
1642         * exp_ch7.adb (Insert_Actions_In_Scope_Around): New formal Clean. If
1643         True, also insert cleanup actions in the tree.
1644         (Wrap_Transient_Declaration): Call Insert_Actions_In_Scope_Around
1645         with Clean set True.
1647 2014-07-30  Arnaud Charlet  <charlet@adacore.com>
1649         * s-taskin.ads (Direct_Index, Direct_Index_Range,
1650         Direct_Attribute_Element, Direct_Attribute_Array,
1651         Direct_Index_Vector, Direct_Attributes, Is_Defined,
1652         Indirect_Attributes): Removed.  (Atomic_Address,
1653         Attribute_Array, Attributes): New.
1654         * s-tasini.ads, s-tasini.adb (Proc_T, Initialize_Attributes,
1655         Finalize_Attributes_Link, Initialize_Attributes_Link): Removed.
1656         (Finalize_Attributes): Reimplement.
1657         * s-tassta.adb (Create_Task): Remove call to
1658         Initialize_Attributes_Link (Free_Task, Vulnerable_Free_Task):
1659         Replace Finalize_Attributes_Link by Finalize_Attributes.
1660         * a-tasatt.ads, a-tasatt.adb, s-tataat.ads, s-tataat.adb:
1661         Reimplement from scratch, using a simpler and more efficient
1662         implementation.
1663         * s-tporft.adb (Register_Foreign_Thread): Remove now obsolete comment.
1664         * s-parame.ads, s-parame-hpux.ads,
1665         * s-parame-vms-alpha.ads, s-parame-vms-ia64.ads,
1666         * s-parame-vxworks.ads (Max_Attribute_Count): New, replace
1667         Default_Attribute_Count.
1669 2014-07-30  Olivier Hainque  <hainque@adacore.com>
1671         * vxworks-ppc-link.spec: New file. Extra link
1672         instructions for ppc-vxworks.
1673         * vxworks-crtbe-link.spec: Likewise, for ZCX related support.
1674         * system-vxworks-ppc.ads: Adjust linker options to use spec files.
1675         * system-vxworks-arm.ads: Likewise.
1676         * gcc-interface/Makefile.in: Enable .spec files.
1678 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1680         * sem_aggr.adb: Minor comment reformatting.
1682 2014-07-30  Robert Dewar  <dewar@adacore.com>
1684         * sem_util.ads, sem_util.adb (Is_Junk_Name): Removed.
1685         * sem_warn.adb (Has_Junk_Name): New function
1686         (Check_References): Use Has_Junk_Name to delete junk warnings
1687         (Check_Unset_Reference): ditto.
1688         (Warn_On_Unreferenced_Entity): ditto.
1689         (Warn_On_Useless_Assignment): ditto.
1691 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1693         * checks.adb (Insert_Valid_Check): Do not check for the packed
1694         array type of a prefix that is an access type.
1696 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1698         * sem_attr.adb (Eval_Attribute): Evaluate the GNAT attribute
1699         Unconstrained_Array even if prefix is not frozen yet, as can
1700         occur with a private subtype used as a generic actual.
1702 2014-07-30  Gary Dismukes  <dismukes@adacore.com>
1704         * sem_attr.adb: Minor reformatting.
1706 2014-07-30  Pat Rogers  <rogers@adacore.com>
1708         * gnat_rm.texi: Corrected minor wording error in description
1709         of No_Exception_Registration.
1711 2014-07-30  Yannick Moy  <moy@adacore.com>
1713         * einfo.ads, einfo.adb: New flag Is_Inlined_Always for use in GNATprove
1714         mode. Realphabetize two subprograms.
1715         * inline.adb (Cannot_Inline): Use Is_Inlined_Always in GNATprove mode.
1716         (Can_Be_Inlined_In_GNATprove_Mode): Adapt to possible Empty Body_Id.
1717         (Check_And_Build_Body_To_Inline): Use Is_Inlined_Always in GNATprove
1718         mode.
1719         (Expand_Inline_Call): Use Is_Inlined_Always in GNATprove mode.
1720         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Do not use
1721         Is_Inline in GNATprove mode.
1722         (Analyze_Subprogram_Specification):
1723         Set Is_Inlined_Always at subprogram entity creation.
1724         * sem_res.adb (Resolve_Call): Do not deal with inlining during
1725         pre-analysis.  Issue warning on call to possibly inlined
1726         subprogram when body not seen.
1728 2014-07-30  Yannick Moy  <moy@adacore.com>
1730         * lib-xref.adb (Generate_Reference): Add special
1731         case for compiler-generated formals in GNATprove mode.
1733 2014-07-30  Yannick Moy  <moy@adacore.com>
1735         * sem_ch6.adb: Add comments.
1737 2014-07-30  Thomas Quinot  <quinot@adacore.com>
1739         * s-os_lib.ads (GM_Time_Of): Clarify documentation.
1741 2014-07-30  Robert Dewar  <dewar@adacore.com>
1743         * sem_aggr.adb, sem_res.adb: Minor reformatting.
1745 2014-07-30  Thomas Quinot  <quinot@adacore.com>
1747         * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case
1748         Bit_Order): Set Reverse_Bit_Order on the base type of the
1749         specified first subtype.
1751 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1753         * inline.adb (Expand_Inlined_Call): Use a renaming declaration
1754         to capture the value of actuals of a limited type rather than
1755         an object declaration, to prevent spurious errors when analyzing
1756         the inlined body.
1758 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1760         * sem_ch4.adb (Analyze_Type_Conversion): Treat an inlined body
1761         as an instance, and inhibit semantic checks on already analyzed
1762         code to prevent spurious errors.
1764 2014-07-30  Arnaud Charlet  <charlet@adacore.com>
1766         * a-exctra.ads ("="): New function, to restore compatibility.
1768 2014-07-30  Pascal Obry  <obry@adacore.com>
1770         * adaint.c (__gnat_to_os_time): Set isdst to -1 for the mktime
1771         routine to use the OS dst setting.
1773 2014-07-30  Pat Rogers  <rogers@adacore.com>
1775         * gnat_ugn.texi: Minor correction to description of -gnatw.K.
1777 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1779         * sem_util.adb (Wrong_Type): Disable some checks equally within
1780         instances and within inlined bodies, to suppress spurious type
1781         errors on already analyzed code.
1782         * sem_aggr.adb (Check_Expr_OK_In_Limited_Aggregate): Expression
1783         is legal in an inlined body, juts as it is in an instance body.
1785 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1787         * sem_res.adb (Resolve_Unchecked_Conversion): Within an inlined
1788         body the operand of an unchecked conversion may be a literal, in
1789         which case its type is the target type of the conversion. This
1790         is in contrast to conversions in other contexts, where the
1791         operand cannot be a literal and must be resolvable independent
1792         of the context.
1794 2014-07-30  Pierre-Marie Derodat  <derodat@adacore.com>
1796         * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create a
1797         mere scalar constant instead of a reference for a renaming of
1798         scalar literal.
1799         * gcc-interface/utils.c (renaming_from_generic_instantiation_p): New.
1800         * gcc-interface/gigi.h (renaming_from_generic_instantiation_p): New.
1802 2014-07-30  Robert Dewar  <dewar@adacore.com>
1804         * s-tasuti.adb, s-tasuti.ads, einfo.ads, sem_prag.adb, s-taasde.adb,
1805         g-socthi-vms.adb, s-taprop-mingw.adb, s-interr.adb, s-interr-hwint.adb,
1806         g-decstr.adb, s-tasdeb-vms.adb, g-expect-vms.adb, makeutl.adb,
1807         s-interr-vms.adb, g-socthi.adb, exp_aggr.adb, s-tasdeb.adb,
1808         g-awk.adb, gnatls.adb, s-taspri-posix.ads, g-catiio.adb,
1809         s-interr-sigaction.adb, s-os_lib.adb, s-fileio.adb: Minor reformatting
1810         & code reorganization.
1812 2014-07-30  Bob Duff  <duff@adacore.com>
1814         * s-tassta.adb, sem_util.ads: Minor reformatting.
1816 2014-07-30  Yannick Moy  <moy@adacore.com>
1818         * inline.adb (Build_Body_To_Inline): Detect when
1819         subprogram has multiple returns, or not a single last return
1820         statement, in GNATprove mode.
1821         (Cannot_Inline): Simplify logic to handle case of GNATprove
1822         inlining first.
1824 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1826         * sem_ch6.adb: Stubs are not subject to inlining.
1828 2014-07-30  Bob Duff  <duff@adacore.com>
1830         * s-tasuti.ads, s-tasuti.adb (Make_Independent): Change this
1831         from a procedure to a function, so that it can more easily be
1832         called before the "begin" of a task.
1833         * s-taasde.ads (Delay_Block): Make this type immutably limited,
1834         so we can use a build-in-place function call to initialize
1835         Timer_Queue in the body.
1836         * a-rttiev.adb, s-asthan-vms-alpha.adb, s-asthan-vms-ia64.adb,
1837         * s-interr.adb, s-interr-hwint.adb, s-interr-sigaction.adb,
1838         * s-interr-vms.adb, s-taasde.adb: Each independent task now calls
1839         Make_Independent before reaching its "begin", to avoid race
1840         conditions. This causes the activating task to wait until after
1841         Make_Independent is complete before proceeding.  In addition,
1842         we initialize data structures used by independent tasks before
1843         activating those tasks, to avoid possible use of uninitialized data.
1844         * s-interr.ads, s-intman.ads, s-taspri-posix.ads, s-tasdeb.ads:
1845         Minor comment fixes.
1847 2014-07-30  Bob Duff  <duff@adacore.com>
1849         * a-exctra.ads, s-traent-vms.ads, s-traent.ads (Tracebacks_Array): Move
1850         the declaration of Tracebacks_Array from Ada.Exceptions.Traceback to
1851         System.Traceback_Entries (s-traent.ads and s-traent-vms.ads).  Add
1852         subtypes renaming Tracebacks_Array in Ada.Exceptions.Traceback.
1853         * g-debpoo.adb: Refer to Tracebacks_Array in its new home.
1855 2014-07-30  Arnaud Charlet  <charlet@adacore.com>
1857         * a-tasatt.adb: Remove old comments.
1859 2014-07-30  Yannick Moy  <moy@adacore.com>
1861         * einfo.ads (Is_Inlined): Document new use in GNATprove mode.
1862         * inline.adb (Can_Be_Inlined_In_GNATprove_Mode): Add comments
1863         to explain rationale for inlining or not in GNATprove mode.
1864         (Expand_Inlined_Call): In GNATprove mode, set Is_Inlined flag
1865         to False when inlining is not possible.
1866         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Set Is_Inlined
1867         flag to indicate that subprogram is fully inlined. To be reversed
1868         if inlining problem is found.
1869         * sem_res.adb (Resolve_Call): Set Is_Inlined flag to False when
1870         call in potentially unevaluated context.
1872 2014-07-30  Jose Ruiz  <ruiz@adacore.com>
1874         * s-tarest.adb, s-tarest.ads: Fix comments.
1876 2014-07-30  Robert Dewar  <dewar@adacore.com>
1878         * exp_attr.adb, checks.adb, sem_util.adb, sem_util.ads, sem_attr.adb:
1879         Change No_Scalar_Parts predicate to Scalar_Part_Present and
1880         invert sense of test. This avoids the "not No_xxx" situation
1881         which is always ugly.
1883 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1885         * inline.adb (Expand_Inlined_Call): When generating code for
1886         an internal subprogram the expansion uses the location of the
1887         call, so that gdb can skip over it. In GNATprove mode we want to
1888         preserve slocs of original subprogram when expanding an inlined
1889         call, to obtain better warnings, even though subprogram appears
1890         not to come from source if it is the inlining of a subprogram
1891         body without a previous spec.
1893 2014-07-30  Eric Botcazou  <ebotcazou@adacore.com>
1895         * exp_aggr.adb (Aggr_Assignment_OK_For_Backend): Reject array
1896         types with atomic components.
1898 2014-07-30  Thomas Quinot  <quinot@adacore.com>
1900         * Make-generated.in: Remove now unnecessary targets after s-oscons
1901         reorg.
1903 2014-07-30  Yannick Moy  <moy@adacore.com>
1905         * sem_res.adb (Resolve_Call): Use ultimate alias
1906         of callee when available.
1908 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1910         * sem_ch6.adb (Analyze_Expression_Function): To check whether
1911         an expression function is a completion, use the specification of
1912         the previous declaration, not its entity, which may be internally
1913         generated in an inlined context.
1915 2014-07-30  Doug Rupp  <rupp@adacore.com>
1917         * adaint.c (__gnat_tmp_name) [__ANDROID__]: Default to putting
1918         temp files in /cache directory unless overridden by TMPDIR.
1920 2014-07-30  Jose Ruiz  <ruiz@adacore.com>
1922         * s-tassta.adb, s-tarest.adb (Initialize, Create_Task,
1923         Create_Restricted_Task): Remove redundant check. Number_Of_CPUs returns
1924         type CPU, so it can never be greater than CPU_Range'Last.
1926 2014-07-30  Bob Duff  <duff@adacore.com>
1928         * s-taskin.ads: Minor comment fix.
1930 2014-07-30  Thomas Quinot  <quinot@adacore.com>
1932         * g-socket.adb: Remove now useless WITH, USE, and USE TYPE
1933         clauses.
1935 2014-07-30  Yannick Moy  <moy@adacore.com>
1937         * debug.adb: Free debug flag dQ used for frontend inlining in
1938         GNATprove mode..
1939         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Remove test of
1940         debug flag..
1942 2014-07-30  Thomas Quinot  <quinot@adacore.com>
1944         * Make-generated.in: Remove generation of s-oscons.ads, only
1945         generate the xoscons utility, in runtime-agnostic rules.
1946         * gcc-interface/Makefile.in: Clean up rules. Remove VMS parts,
1947         no longer supported.
1949 2014-07-30  Bob Duff  <duff@adacore.com>
1951         * exp_ch6.adb (Add_Task_Actuals_To_Build_In_Place_Call): New
1952         parameter Chain to be used in the allocator case.
1953         (Make_Build_In_Place_Call_In_Allocator): If the allocated object
1954         has tasks, wrap the code in a block that will activate them,
1955         including the usual finalization code to kill them off in case
1956         of exception or abort.
1958 2014-07-30  Robert Dewar  <dewar@adacore.com>
1960         * treepr.adb, treepr.ads; Reorganize documentation for new pp routines
1961         Remove renamings (don't work for gdb).
1962         (par): New synonym for p (avoid gdb ambiguities).
1963         * inline.adb, sem_ch6.adb, sem_ch13.adb: Minor reformatting.
1965 2014-07-30  Bob Duff  <duff@adacore.com>
1967         * exp_ch9.ads, sem_prag.adb, exp_ch4.adb, sem_ch13.adb: Minor comment
1968         fixes.
1969         * treepr.ads, treepr.adb (ppp): Make this debugging routine
1970         accept any type covered by Union_Id.
1972 2014-07-30  Robert Dewar  <dewar@adacore.com>
1974         * sem_ch4.adb (Analyze_If_Expression): Resolve condition before
1975         analyzing branches.
1976         * sem_eval.adb (Out_Of_Range): Check for statically unevaluated
1977         expression case.
1979 2014-07-30  Robert Dewar  <dewar@adacore.com>
1981         * sem_ch13.adb (Analyze_Aspect, predicate cases): Diagnose use
1982         of predicate aspect on entity other than a type.
1984 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
1986         * sem_ch6.adb (Body_Has_Contract): New predicate to determine
1987         when a subprogram body without a previous spec cannot be inlined
1988         in GNATprove mode, because it includes aspects or pragmas that
1989         generate a SPARK contract clause.
1990         * inline.adb (Can_Be_Inlined_In_GNATprove_Mode): A subprogram
1991         instance cannot be inlined.
1993 2014-07-30  Robert Dewar  <dewar@adacore.com>
1995         * debug.adb: Document that d7 suppresses compilation time output.
1996         * errout.adb (Write_Header): Include compilation time in
1997         header output.
1998         * exp_intr.adb (Expand_Intrinsic_Call): Add
1999         Compilation_Date/Compilation_Time (Expand_Source_Info): Expand
2000         Compilation_Date/Compilation_Time.
2001         * g-souinf.ads (Compilation_Date): New function
2002         (Compilation_Time): New function.
2003         * gnat1drv.adb (Gnat1drv): Set Opt.Compilation_Time.
2004         * gnat_rm.texi (Compilation_Date): New function
2005         (Compilation_Time): New function.
2006         * opt.ads (Compilation_Time): New variable.
2007         * s-os_lib.ads, s-os_lib.adb (Current_Time_String): New function.
2008         * sem_intr.adb (Compilation_Date): New function.
2009         (Compilation_Time): New function.
2010         * snames.ads-tmpl (Name_Compilation_Date): New entry.
2011         (Name_Compilation_Time): New entry.
2013 2014-07-30  Yannick Moy  <moy@adacore.com>
2015         * inline.adb: Add comment.
2017 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
2019         * par-ch4.adb (Is_Parameterless_Attribute): 'Result is a
2020         parameterless attribute, and a postondition can mention an
2021         indexed component or a slice whose prefix is an attribute
2022         reference F'Result.
2024 2014-07-30  Robert Dewar  <dewar@adacore.com>
2026         * sprint.adb (Sprint_Node_Actual, case Object_Declaration):
2027         Avoid bomb when printing package Standard.
2029 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
2031         * sem_elab.adb (Check_Internal_Call_Continue): If an elaboration
2032         entity is created at this point, ensure that the name of the
2033         flag is unique, because the subprogram may be overloaded and
2034         other homonyms may also have elaboration flags created on the fly.
2036 2014-07-30  Hristian Kirtchev  <kirtchev@adacore.com>
2038         * sem_attr.adb (Analyze_Array_Component_Update): New routine.
2039         (Analyze_Attribute): Major cleanup of attribute
2040         'Update. The logic is now split into two distinct routines
2041         depending on the type of the prefix. The use of <> is now illegal
2042         in attribute 'Update.
2043         (Analyze_Record_Component_Update): New routine.
2044         (Check_Component_Reference): Removed.
2045         (Resolve_Attribute): Remove the return statement and ??? comment
2046         following the processing for attribute 'Update. As a result,
2047         the attribute now freezes its prefix.
2049 2014-07-30  Javier Miranda  <miranda@adacore.com>
2051         * exp_ch4.adb (Apply_Accessibility_Check): Do
2052         not call Base_Address() in VM targets.
2054 2014-07-30  Yannick Moy  <moy@adacore.com>
2056         * gnat1drv.adb (Adjust_Global_Switches): Set
2057         Ineffective_Inline_Warnings to True in GNATprove mode.
2058         * inline.adb (Cannot_Inline): Prepare new semantics for GNATprove
2059         mode of inlining.
2060         * opt.ads (Ineffective_Inline_Warnings): Add comment that
2061         describes use in GNATprove mode.
2062         * sem_prag.adb (Analyze_Pragma|SPARK_Mode): Ignore
2063         pragma when applied to the special body created for inlining.
2065 2014-07-30  Robert Dewar  <dewar@adacore.com>
2067         * inline.adb, exp_ch4.adb, sinput.adb, sem_ch6.adb, sem_ch13.adb:
2068         Minor reformatting.
2070 2014-07-30  Hristian Kirtchev  <kirtchev@adacore.com>
2072         * aspects.ads Add a comment explaining why SPARK 2014 aspects are
2073         not delayed. Update the delay status of most SPARK 2014 aspects.
2074         * sem_ch13.adb (Analyze_Aspect_Specifications): Update all calls
2075         to Decorate_Aspect_And_Pragma and Insert_Delayed_Pragma to refert
2076         to Decorate and Insert_Pragma. Add various comments concerning
2077         the delay status of several SPARK 2014 aspects. The insertion
2078         of Refined_State now uses routine Insert_After_SPARK_Mode.
2079         (Decorate): New routine.
2080         (Decorate_Aspect_And_Pragma): Removed.
2081         (Insert_Delayed_Pragma): Removed.
2082         (Insert_Pragma): New routine.
2084 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
2086         * inline.adb (Expand_Inlined_Call): In GNATprove mode, emit
2087         only a warning, not an error on an attempt to inline a recursive
2088         subprogram.
2090 2014-07-30  Robert Dewar  <dewar@adacore.com>
2092         * g-forstr.adb: Minor code reorganization (use J rather than I
2093         as a variable name).
2094         * gnat_rm.texi, sem_prag.adb, sem_util.adb, sem_ch13.adb,
2095         g-forstr.ads: Minor reformatting.
2097 2014-07-30  Eric Botcazou  <ebotcazou@adacore.com>
2099         * sprint.adb (Set_Debug_Sloc): Also reset the end location if
2100         we are debugging the generated code.
2102 2014-07-30  Yannick Moy  <moy@adacore.com>
2104         * sinput.ads, sinput.adb (Comes_From_Inlined_Body): New function that
2105         returns True for source pointer for an inlined body.
2107 2014-07-30  Javier Miranda  <miranda@adacore.com>
2109         * exp_ch4.adb (Apply_Accessibility_Check): Add
2110         missing calls to Base_Address().
2112 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
2114         * sem_ch6.adb (Hanalyze_Subprogram_Body_Helper): In GNATprove
2115         mode, subprogram bodies without a previous declaration are also
2116         candidates for front-end inlining.
2118 2014-07-30  Hristian Kirtchev  <kirtchev@adacore.com>
2120         * aspects.ads Aspects Async_Readers, Async_Writers,
2121         Effective_Reads and Effective_Writes do not need to be delayed.
2122         * sem_ch13.adb (Analyze_Aspect_Specifications): Propagate the
2123         optional Boolean expression when generating the corresponding
2124         pragma for an external property aspect.
2125         * sem_prag.adb (Analyze_External_Property_In_Decl_Part): Remove
2126         local constant Obj. Add local constant Obj_Id. Reimplement the
2127         check which ensures that the related variable is in fact volatile.
2128         (Analyze_Pragma): Reimplement the analysis of external property pragmas.
2129         * sem_util.adb (Is_Enabled): New routine.
2130         (Variable_Has_Enabled_Property): Reimplement the detection of
2131         an enabled external property.
2133 2014-07-30  Sergey Rybin  <rybin@adacore.com frybin>
2135         * gnat_ugn.texi, vms_data.ads: gnatstub: describe generating subunits
2136         for body stubs.
2138 2014-07-30  Pascal Obry  <obry@adacore.com>
2140         * g-forstr.adb, g-forstr.ads: New.
2141         * gnat_rm.texi, impunit.adb Makefile.rtl: Add new unit
2142         GNAT.Formatted_String.
2144 2014-07-30  Eric Botcazou  <ebotcazou@adacore.com>
2146         * exp_aggr.adb (Aggr_Assignment_OK_For_Backend): New predicate.
2147         (Expand_Array_Aggregate): Also enable in-place expansion for
2148         code generated by the compiler.  For an object declaration,
2149         set the kind of the object in addition to its type.  If an
2150         in-place assignment is to be generated and it can be directly
2151         done by the back-end, do not expand the aggregate.
2152         * fe.h (Is_Others_Aggregate): Declare.
2153         * gcc-interface/trans.c
2154         (gnat_to_gnu) <N_Assignment_Statement>: Add support for an
2155         aggregate with a single Others choice on the RHS by means of
2156         __builtin_memset.  Tidy up.
2158 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
2160         * gnat_rm.texi: minor reformatting.
2162 2014-07-30  Yannick Moy  <moy@adacore.com>
2164         * sem_ch6.adb (Analyze_Subprogram_Helper_Body): Remove body to inline
2165         in SPARK_Mode Off.
2167 2014-07-30  Robert Dewar  <dewar@adacore.com>
2169         * gnat_rm.texi: Document additional implementation-defined use
2170         of Constrained.
2172 2014-07-30  Robert Dewar  <dewar@adacore.com>
2174         * prj-proc.adb, prj-strt.adb: Update comments.
2176 2014-07-30  Gary Dismukes  <dismukes@adacore.com>
2178         * sinfo.ads, einfo.ads, checks.ads: Minor typo fix and reformatting.
2180 2014-07-30  Vincent Celier  <celier@adacore.com>
2182         * prj-proc.adb (Imported_Or_Extended_Project_From): New Boolean
2183         parameter No_Extending, defaulted to False. When No_Extending
2184         is True, do not look for an extending project.
2185         (Expression): For a variable reference that is not for the current
2186         project, get its Id calling Imported_Or_Extended_Project_From
2187         with No_Extending set to True.
2188         * prj-strt.adb (Parse_Variable_Reference): If a referenced
2189         variable is not found in the current project, check if it is
2190         defined in one of the projects it extends.
2192 2014-07-30  Robert Dewar  <dewar@adacore.com>
2194         * sem_util.adb (Predicate_Tests_On_Arguments): Omit tests for
2195         some additional cases of internally generated routines.
2197 2014-07-30  Ed Schonberg  <schonberg@adacore.com>
2199         * sem_ch10.adb (Analyze_Proper_Body): When compiling for ASIS,
2200         if the compilation unit is a subunit, extend optional processing
2201         to all subunits of the current one. This allows gnatstub to
2202         supress generation of spurious bodies.
2204 2014-07-30  Hristian Kirtchev  <kirtchev@adacore.com>
2206         * a-cbmutr.adb (Insert_Child): Use local variable First to keep
2207         track of the initial element's index within the tree.
2209 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
2211         * a-cbmutr.adb (Allocate_Node): Remove the two parameter version.
2212         (Insert_Child): Add local variable First. Capture the index of the
2213         first node being created to ensure correct cursor construction
2214         later on. Use the three parameter version of Allocate_Node
2215         when creating multiple children as this method allows aspect
2216         Default_Value to take effect (if applicable).
2218 2014-07-29  Eric Botcazou  <ebotcazou@adacore.com>
2220         * exp_aggr.adb (Safe_Slice_Assignment): Remove.
2221         (Expand_Array_Aggregate): For a safe slice assignment, just set
2222         the target and use the common code path.
2224 2014-07-29  Robert Dewar  <dewar@adacore.com>
2226         * sem_util.adb, sem_util.ads, sem_res.adb, exp_ch6.adb: Invert
2227         predicate No_Predicate_Test_On_Arguments, new name is
2228         Predicate_Tests_On_Arguments (with the opposite sense).
2230 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
2232         * sem_attr.adb (Resolve_Attribute): Clean up the code for
2233         attribute 'Access. Do not generate an elaboration flag for a
2234         stand alone expression function. The expression of an expression
2235         function is now frozen when the expression function appears as
2236         the prefix of attribute 'Access.
2237         * sem_ch6.adb (Analyze_Expression_Function): Remove local
2238         variable New_Decl and update all references to it after the
2239         rewriting has taken place. Establish the linkages between the
2240         generated spec and body.
2242 2014-07-29  Robert Dewar  <dewar@adacore.com>
2244         * sem_prag.adb (ip, rv): Prevent from being optimized away.
2245         * gnatls.adb (gnatls): Set E_Fatal exit status if ali file not found.
2246         * s-imgllb.adb, s-imgllw.adb, s-imgwiu.adb, s-imgbiu.adb: Minor
2247         reformatting.
2249 2014-07-29  Vincent Celier  <celier@adacore.com>
2251         * prj-pp.adb: Minor comment update.
2252         * frontend.adb: If a target dependency info file has been read
2253         through switch -gnateT= add it to the dependencies of the source
2254         being compiled.
2256 2014-07-29  Robert Dewar  <dewar@adacore.com>
2258         * sem_ch3.adb, prj.adb: Minor reformatting.
2260 2014-07-29  Vincent Celier  <celier@adacore.com>
2262         * prj-pp.adb (Pretty_Print.Output_Project_File): New
2263         procedure to output project file names between quotes without
2264         concatenation, even if the line is too long.
2265         (Pretty_Print): Use Output_Project_File for project being extended and
2266         project imported.
2268 2014-07-29  Vincent Celier  <celier@adacore.com>
2270         * gnat_ugn.texi: Document that configuration pragmas files are
2271         added to the dependencies, unless they contain only pragmas
2272         Source_File_Name_Project.
2274 2014-07-29  Robert Dewar  <dewar@adacore.com>
2276         * frontend.adb: Minor reformatting.
2278 2014-07-29  Robert Dewar  <dewar@adacore.com>
2280         * exp_ch6.adb (Add_Call_By_Copy_Code): Minor reformatting
2281         (Expand_Actuals): Make sure predicate checks are properly applied
2282         for the case of OUT or IN OUT parameters.
2283         * sem_res.adb: Minor reformatting (Resolve_Actuals): Skip
2284         predicate tests on arguments for Finalize
2285         * sem_util.adb (No_Predicate_Test_On_Arguments): Returns True
2286         if predicate tests on subprogram arguments should be skipped.
2287         * sem_util.ads (No_Predicate_Test_On_Arguments): New function
2289 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2291         * sem_ch3.adb (Analyze_Object_Declaration): If there is an address
2292         clause for the object and the expression is an aggregate, defer
2293         resolution and expansion of the aggregate until the freeze point
2294         of the entity.
2295         * sem_aggr.adb (Resolve_Aggregate): An others_clause is legal if
2296         the parent node is an N_Reference generated during expansion.
2298 2014-07-29  Vincent Celier  <celier@adacore.com>
2300         * prj.adb (Add_To_Buffer): Effectively double the size of the buffer.
2302 2014-07-29  Robert Dewar  <dewar@adacore.com>
2304         * frontend.adb, inline.adb, sem_util.adb, sem_res.adb,
2305         prepcomp.ads: Minor reformatting and code clean up.
2306         * exp_ch6.adb (Expand_Actuals): Generate predicate test
2307         unconditionally for case of OUT or IN OUT actual (before this
2308         was generated only for certain subcases, which is wrong, the
2309         test is always needed).
2311 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2313         * sem_ch3.adb: Move Has_Defaulted_Discriminants to sem_util.
2314         * sem_ch4.adb (Analyze_Allocator): Defer resolution of expression
2315         until context type is available.
2316         * sem_res.adb (Resolve_Allocator): In the case of a qualified
2317         expression, complete resolution of expression.
2318         (Check_Aliased_Parameter): New procedure within Resolve_Actuals,
2319         to apply Ada2012 checks on aliased formals, as well as
2320         accesibility checks when the context of the call is an allocator
2321         or a qualified expression.
2322         * sem_util.ads, sem_util.adb (Has_Defaulted_Discriminants):
2323         Moved here from sem_ch3.
2324         (Object_Access_Level): Handle properly aliased formals and
2325         aggregates.
2326         * exp_ch6.adb (Expand_Call): Remove check on aliased parameters,
2327         now properly performed in sem_res (Resolve_Actuals,
2328         Check_Aliased_Parameter).
2330 2014-07-29  Yannick Moy  <moy@adacore.com>
2332         * debug.adb Enable GNATprove inlining under debug flag -gnatdQ for now.
2333         * inline.ads, inline.adb (Can_Be_Inlined_In_GNATprove_Mode): New
2334         function to decide when a subprogram can be inlined in GNATprove mode.
2335         (Check_And_Build_Body_To_Inline): Include GNATprove_Mode as a
2336         condition for possible inlining.
2337         * sem_ch10.adb (Analyze_Compilation_Unit): Remove special case
2338         for Inline_Always in GNATprove mode.
2339         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Build inlined
2340         body for subprograms in GNATprove mode, under debug flag -gnatdQ.
2341         * sem_prag.adb Minor change in comments.
2342         * sem_res.adb (Resolve_Call): Only perform GNATprove inlining
2343         inside subprograms marked as SPARK_Mode On.
2344         * sinfo.ads: Minor typo fix.
2346 2014-07-29  Vincent Celier  <celier@adacore.com>
2348         * frontend.adb: Add dependency on gnat.adc when taken into account
2349         and on non-temporary configuration pragmas files specified in
2350         switches -gnatec.
2351         * prepcomp.ads, prepcomp.adb (Add_Dependency): New procedure to add
2352         dependencies on configuration pragmas files.
2354 2014-07-29  Pat Rogers  <rogers@adacore.com>
2356         * gnat_ugn.texi: Minor clarification to the explanation for the
2357         GNATtest -v switch.
2359 2014-07-29  Robert Dewar  <dewar@adacore.com>
2361         * types.ads (Mechanism_Type): Change range back to -18 .. Int'Last with
2362         documentation that explains the need for this extended range
2363         (use by C_Pass_By_Copy).
2365 2014-07-29  Robert Dewar  <dewar@adacore.com>
2367         * gnat_rm.texi, sem_prag.adb: Minor reformatting.
2369 2014-07-29  Sergey Rybin  <rybin@adacore.com frybin>
2371         * gnat_ugn.texi: gnatmetric: clarify documentation for cyclomatic
2372         complexity metrics.
2374 2014-07-29  Thomas Quinot  <quinot@adacore.com>
2376         PR ada/60652
2377         * s-oscons-tmplt.c: For Linux, define _BSD_SOURCE in order for
2378         CRTSCTS to be visible.
2380 2014-07-29  Bob Duff  <duff@adacore.com>
2382         * g-trasym.adb, g-trasym.ads: Code cleanup.
2384 2014-07-29  Doug Rupp  <rupp@adacore.com>
2386         * sigtramp-vxworks.c: Minor reformatting.
2388 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2390         * gnat_rm.texi: No doc needed for Ada2012 aspect
2391         Implicit_dereference.
2393 2014-07-29  Robert Dewar  <dewar@adacore.com>
2395         * sem_attr.adb (Attribute_12): New array
2396         (Analyze_Attribute): Check impl-defined Ada 2012 attributes.
2397         (Check_Ada_2012_Attribute): Removed.
2399 2014-07-29  Doug Rupp  <rupp@adacore.com>
2401         * init.c (vxworks6): Call sigtramp for RTP (as well as DKM) for ARM,
2402         PPC, and e500.
2403         * sigtramp-vxworks.c: New file.
2404         * sigtramp-armvxw.c, sigtramp-ppcvxw.c: removed files.
2406 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2408         * lib-xref.adb (Output_Refs, Check_Type_Reference): For a
2409         derived array type, add information about component type, which
2410         was previously missing in ali file.
2411         * gnat_rm.texi: Add documentation for Atomic_Always_Lock_Free.
2413 2014-07-29  Thomas Quinot  <quinot@adacore.com>
2415         * sem_ch3.adb (Constrain_Corresponding_Record): For the case
2416         of the subtype created for a record component, do not mark
2417         the subtype as frozen. For one thing, this is anomalous (in
2418         particular, the base type might not itself be frozen yet);
2419         furthermore, proper freezing of the subtype must happen in any
2420         case. So, we just mark the subtype as requiring delayed freezing
2421         (and we'll actually freeze it when generating the init_proc of
2422         the enclosing record).
2423         Also change the name of the constrained record subtype (append a
2424         'C' so that it is clearly different from the unconstrained record
2425         type, "related_idV") to make debugging easier.
2426         (Process_Full_View): When creating a full subtype for a pending
2427         private subtype, re-establish the scope of the private subtype
2428         so that we get proper visibility on outer discriminants.
2429         * exp_ch3.adb (Build_Init_Statements): Freeze any component
2430         subtype that is not frozen yet.
2432 2014-07-29  Vincent Celier  <celier@adacore.com>
2434         * prj-proc.adb (Recursive_Process): Always initialize the
2435         environment when the project is an aggregate project, even when
2436         it is not the root tree.
2437 2014-07-29  Robert Dewar  <dewar@adacore.com>
2439         * exp_ch5.adb, exp_ch9.adb: Minor comment additions.
2440         * gnat_rm.texi: Complete list of implementation aspects.
2441         * aspects.ads: Minor comment clarification.
2443 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2445         * exp_ch5.adb (Expand_N_Assignment_Statement): If the target type
2446         is a null-excluding access type, do not generate a constraint
2447         check if Suppress_Assignment_Checks is set on assignment node.
2448         * exp_ch9.adb (Build_Simple_Entry_Call): If actual is an out
2449         parameter of a null-excluding access type, there is access check
2450         on entry, so set Suppress_Assignment_Checks on generated statement
2451         that assigns actual to parameter block.
2452         * sinfo.ads: Document additional use of Suppress_Assignment_Checks.
2454 2014-07-29  Robert Dewar  <dewar@adacore.com>
2456         * gnat_rm.texi: Change theta to @ in documentation of aspect
2457         Dimension_System.
2459 2014-07-29  Robert Dewar  <dewar@adacore.com>
2461         * sem_attr.adb (Uneval_Old_Msg): Flags Uneval_Old_Accept/Warn
2462         are now on pragma.
2463         * sem_ch13.adb (Analyze_Aspect_Specifications): Remove setting
2464         of Uneval_Old_*
2465         * sem_prag.adb (Analyze_Pragma): Set Uneval_Old_* flags
2466         * sinfo.ads, sinfo.adb: Move Uneval_Old_Accept/Warn to N_Pragma node.
2468 2014-07-29  Javier Miranda  <miranda@adacore.com>
2470         * types.ads Update documentation on how to add new reason codes
2471         for exceptions.
2472         (RT_Exception_Code): Keep values ordered by their
2473         reason code.  Required by the .NET backend.
2474         (RT_CE_Exceptions): Subtype declaration removed.
2475         (RT_PE_Exceptions): Subtype declaration removed.
2476         (RT_SE_Exceptions): Subtype declaration removed.
2477         (Kind): New mapping table of RT_Exception_Codes.
2478         * exp_ch11.adb (Get_RT_Exception_Entity): Updated to use the
2479         new mapping table.
2480         * tbuild.adb (Make_Raise_Storage_Error): Updated to use the new
2481         mapping table.  (Make_Raise_Program_Error): Updated to use the
2482         new mapping table.
2483         (Make_Raise_Storage_Error): Updated to use the new mapping table.
2484         * a-except.adb Keep Rcheck_CE_xxx entities ordered according to
2485         their reason code.
2487 2014-07-29  Thomas Quinot  <quinot@adacore.com>
2489         * gnat_rm.texi: Document internal attributes used for PolyORB/DSA
2490         distributed stubs generation.
2491         * exp_ch3.adb: Minor reformatting.
2493 2014-07-29  Yannick Moy  <moy@adacore.com>
2495         * sinfo.ads: Document constraint between frontend and GNATprove.
2497 2014-07-29  Robert Dewar  <dewar@adacore.com>
2499         * a-except.adb: Minor comment clarification.
2501 2014-07-29  Robert Dewar  <dewar@adacore.com>
2503         * gnat_rm.texi: Complete list of implementation attributes.
2504         * snames.ads-tmpl: Clean up list of impl-defined attributes.
2506 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
2508         * freeze.adb (Freeze_Record_Type): Perform various
2509         volatility-related checks.
2511 2014-07-29  Robert Dewar  <dewar@adacore.com>
2513         * sem_ch3.adb, sem_eval.adb: Minor reformatting.
2515 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2517         * sem_attr.adb: sem_attr.adb (Access_Attribute): Handle properly
2518         the case where the attribute reference appears in a nested scope
2519         from that of the subprogram prefix.
2520         * sem_attr.adb: Minor reformatting.
2522 2014-07-29  Robert Dewar  <dewar@adacore.com>
2524         * gnat_ugn.texi: Clarify documentation of Initialize_Scalar
2525         initialization options.
2527 2014-07-29  Robert Dewar  <dewar@adacore.com>
2529         * sinfo.ads: Minor comment addition.
2531 2014-07-29  Bob Duff  <duff@adacore.com>
2533         * sem_eval.adb, sem_ch13.adb: Minor reformatting.
2535 2014-07-29  Doug Rupp  <rupp@adacore.com>
2537         * init.c: Complete previous change.
2539 2014-07-29  Robert Dewar  <dewar@adacore.com>
2541         * exp_ch4.adb (Expand_N_If_Expression): Deal with unconstrained
2542         array case.
2544 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2546         * sem_attr.adb (Access_Attribute): If the prefix is a subprogram
2547         and the completion will appear in the same declarative part,
2548         create elaboration flag.
2549         * exp_util.adb (Set_Elaboration_Flag): If the subprogram body
2550         is a completion of a declaration in the same declarative part,
2551         and the subprogram has had its address taken, add elaboration
2552         check inside the subprogram body, to detect elaboration errors
2553         that may occur through indirect calls.
2555 2014-07-29  Doug Rupp  <rupp@adacore.com>
2557         * sigtramp-armvxw.c: Enhance to handle RTP trampolining.
2558         * init.c: Remove guard on sigtramp for ARM VxWorks RTP.
2560 2014-07-29  Vincent Celier  <celier@adacore.com>
2562         * switch-c.adb (Scan_Front_End_Switches): Do not fail when two
2563         runtime directorie specified with two switches --RTS= designate
2564         the same directory, even when there are no literarily the same.
2566 2014-07-29  Robert Dewar  <dewar@adacore.com>
2568         * gnat_ugn.texi: Minor documentation clarification.
2569         * switch-c.adb: Minor reformatting.
2571 2014-07-29  Robert Dewar  <dewar@adacore.com>
2573         * sem_prag.adb (Analyze_Pragma, case Allow_Integer_Address):
2574         Fix incorrect RTE call which caused bomb if pragma was in
2575         configuration pragma file.
2577 2014-07-29  Jerome Lambourg  <lambourg@adacore.com>
2579         * expect.c (__gnat_expect_poll): Fix typo in previous change.
2580         * g-expect.adb: Update comments.
2582 2014-07-29  Arnaud Charlet  <charlet@adacore.com>
2584         * s-parame-hpux.ads, s-parame-vms-ia64.ads, s-parame.ads
2585         (Default_Attribute_Count): Bump to 16 on native platforms.
2587 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2589         * sem_res.adb: Add guard to front-end inlining for SPARK.
2591 2014-07-29  Robert Dewar  <dewar@adacore.com>
2593         * sem_ch10.adb, debug.adb, sem_prag.adb, sem_res.adb, sem_ch6.adb:
2594         Minor reformatting.
2596 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2598         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Build body to
2599         inline in GNATprove mode when subprogran is marked Inline_Always.
2600         * sem_res.adb (Resolve_Call): Expand call in place in GNATProve
2601         mode if body to inline is available.
2602         * sem_prag.adb (Analyze_Pragma, case Inline_Always): Make pragma
2603         effective in GNATprove mode.
2604         * sem_ch10.adb (Analyze_Compilation_Unit): Call
2605         Check_Package_Body_For_Inlining in GNATprove mode, so that body
2606         containing subprograms with Inline_Always can be available before
2607         calls to them.
2609 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2611         * inline.ads, inline.adb, sem_ch10.adb: Rename Check_Body_For_Inlining
2612         to Check_Package_Body_For_Inlining, to prevent confusion with other
2613         inlining subprograms.
2615 2014-07-29  Robert Dewar  <dewar@adacore.com>
2617         * opt.ads: Minor comment update.
2618         * sem_attr.adb (Uneval_Old_Msg): Deal with case of aspect, where
2619         we want setting of Uneval_Old at time of encountering the aspect.
2620         * sem_ch13.adb (Analyze_Aspect_Specifications): Capture setting
2621         of Opt.Uneval_Old.
2622         * sinfo.adb (Uneval_Old_Accept): New function (Uneval_Old_Warn):
2623         New function (Set_Uneval_Old_Accept): New procedure.
2624         (Set_Uneval_Old_Warn): New procedure.
2625         * sinfo.ads: Uneval_Old_Accept: New flag Uneval_Old_Warn: New flag.
2627 2014-07-29  Robert Dewar  <dewar@adacore.com>
2629         * sinfo.ads, inline.adb, inline.ads, sem_ch6.adb: Minor reformatting.
2630         * snames.ads-tmpl: Minor reformatting.
2631         * xsnamest.adb (XSnamesT): Remove special casing of Name_Error
2632         to give <Error>.  Not clear why this was there, but the compiler
2633         sources do not reference Name_Error, and this interfered with
2634         the circuits for pragma Unevaluated_Use_Of_Old.
2636 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
2638         * sem_prag.adb (Process_Atomic_Shared_Volatile): Allow volatile
2639         types in SPARK 2014 (again).
2640         * sem_res.adb (Is_OK_Volatile_Context): New routine.
2641         (Resolve_Entity_Name): Ensure that a volatile object with
2642         enabled properties Async_Writers or Effectire_Reads appears in
2643         a non-interfering context.
2645 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2647         * sem_ch6.adb: Move Build_Body_To_Inline,
2648         Check_And_Buid_Body_To_Inline, and Cannot_Inline to package Inline.
2649         * exp_ch6.adb: Mode Expand_Inlined_Body to package Inline.
2650         * inline.ads, inline.adb: Package now contains subprograms that
2651         implement front-end inlining.  No functional changes, no test
2652         needed.
2654 2014-07-29  Robert Dewar  <dewar@adacore.com>
2656         * exp_dbug.adb, g-expect.adb, sem_elab.adb: Minor typo fix.
2658 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2660         * sem_ch6.adb (Analyze_Return_Type): Reject a return type that
2661         is a limited view when the context is a package body, because
2662         there is no subsequent place at which the non-limited view may
2663         become visible.
2664         (Process_Formals): Ditto.
2665         * sinfo.ads, par-ch3.adb: Minor reformatting.
2667 2014-07-29  Jerome Lambourg  <lambourg@adacore.com>
2669         * expect.c (__gnat_expect_poll): New parameter dead_process
2670         used to return the dead process among the array of file
2671         descriptors. The Windows, VMS and HPUX implementations now
2672         properly report the dead process via this parameter. Other unixes
2673         don't need it.
2674         * g-expect.adb (Poll): Adapt to the C profile.
2675         (Expect_Internal): Use the new parameter to properly close the
2676         File Descriptor.  This then can be properly reported by the
2677         function First_Dead_Process as is expected.
2679 2014-07-29  Robert Dewar  <dewar@adacore.com>
2681         * gnat_ugn.texi: Minor clarification of -gnatQ switch.
2683 2014-07-29  Robert Dewar  <dewar@adacore.com>
2685         * einfo.adb (Derived_Type_Link): New function
2686         (Set_Derived_Type_Link): New procedure.
2687         (Write_Field31_Name): Output Derived_Type_Link.
2688         * einfo.ads: New field Derived_Type_Link.
2689         * exp_ch6.adb (Expand_Call): Warn if change of representation
2690         needed on call.
2691         * sem_ch13.adb: Minor addition of ??? comment.
2692         (Rep_Item_Too_Late): Warn on case that is legal but could cause an
2693         expensive implicit conversion.
2694         * sem_ch3.adb (Build_Derived_Type): Set Derived_Type_Link if needed.
2696 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
2698         * exp_ch3.adb (Build_Init_Procedure): Renamed Local_DF_Id
2699         to DF_Id. Add new local variable DF_Call. Do not perform any
2700         elaboration-related checks on the call to the partial finalization
2701         routine within an init proc to avoid generating bogus elaboration
2702         warnings on expansion-related code.
2703         * sem_elab.adb (Check_A_Call): Move constant Access_Case to
2704         the top level of the routine.  Ensure that Output_Calls takes
2705         into account flags -gnatel and -gnatwl when emitting warnings
2706         or info messages.
2707         (Check_Internal_Call_Continue): Update the call to Output_Calls.
2708         (Elab_Warning): Moved to the top level of routine Check_A_Call.
2709         (Emit): New routines.
2710         (Output_Calls): Add new formal parameter Check_Elab_Flag along with a
2711         comment on usage. Output all warnings or info messages only when the
2712         caller context demands it and the proper elaboration flag is set.
2714 2014-07-29  Yannick Moy  <moy@adacore.com>
2716         * sem_attr.adb (Analyze_Attribute/Attribute_Old):
2717         Check rule about Old appearing in potentially unevaluated
2718         expression everywhere, not only in Post.
2720 2014-07-29  Arnaud Charlet  <charlet@adacore.com>
2722         * sem_prag.adb: Update comment.
2723         * a-except.adb, a-except-2005.adb: Minor editing.
2725 2014-07-29  Pierre-Marie Derodat  <derodat@adacore.com>
2727         * exp_dbug.adb (Debug_Renaming_Declaration):
2728         Do not create renaming entities for renamings of non-packed
2729         objects and for exceptions.
2731 2014-07-29  Robert Dewar  <dewar@adacore.com>
2733         * sem_ch3.adb, sinfo.ads, types.ads, sem_prag.adb, a-except-2005.adb,
2734         sem_ch6.adb, par-ch3.adb: Minor reformatting.
2736 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2738         * sem_ch6.adb (Check_Return_Subtype_Indication): Reject a return
2739         subtype indication in an extended return statement when the
2740         return value is an ancestor of the return type of the function,
2741         and that return type is a null record extension.
2743 2014-07-29  Thomas Quinot  <quinot@adacore.com>
2745         * sem_ch13.adb (Rep_Item_Too_Late): Specialize/clarify error
2746         message produced for the case of a type-related representation
2747         item that is made illegal by 13.10(1).
2748         * gnat_rm.texi (Scalar_Storage_Order): Minor change in
2749         documentation.
2751 2014-07-29  Robert Dewar  <dewar@adacore.com>
2753         * gnat_ugn.texi: Add section on Wide_Wide_Character encodings.
2754         * erroutc.adb (Output_Error_Msgs): Take wide characters into
2755         account in computing position of error flags.
2756         * sinput.adb (Get_Column_Number): Take wide characters into
2757         account.
2759 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2761         * par-ch3.adb (P_Access_Type_Definition): The subtype indication
2762         in an access type definition can carry a null_exclusion indicator.
2763         * sem_ch3.adb (Access_Type_Declaration): If the subtype indication
2764         carries a null_exclusion indicator, verify that the subtype
2765         indication denotes an access type, and create a null-excluding
2766         subtype for it.
2767         * sinfo.ads, sinfo.adb: New attribute Null_Excluding_Subtype,
2768         defined on N_Access_To_Object_Definition to indicate that the
2769         subtype indication carries a null_exclusion indicator.
2771 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
2773         * exp_ch6.adb (Add_Extra_Actual): Do not construct
2774         the extra actual by name, generate a reference instead.
2776 2014-07-29  Arnaud Charlet  <charlet@adacore.com>
2778         * sem_prag.adb (Analyze_Pragma): Do not crash analyzing
2779         Allow_Integer_Address if already set.
2780         * a-except-2005.adb (Rcheck_PE_Stream_Operation_Not_Allowed):
2781         Fix order, for consistency with Rmsg_xx declarations.
2783 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2785         * sem_ch4.adb (Complete_Object_Operation): If the type of the
2786         candidate subprogram is a limited view, use non-limited view
2787         when available.
2789 2014-07-29  Robert Dewar  <dewar@adacore.com>
2791         * sem_ch13.adb: Minor change in RM reference.
2792         * sem_mech.ads: Minor reformatting.
2793         * einfo.ads: Minor comment fix.
2794         * types.ads: Minor correction to range given for Mechanism_Type.
2795         * exp_ch6.adb (Add_Invariant_And_Predicate_Checks): Do not
2796         check predicate on way out for OUT or IN OUT parameters.
2797         * par-ch3.adb (P_Constraint_Opt): Handle missing RANGE keyword
2798         better (P_Range_Constraint): Corresponding fix.
2799         * checks.ads: Minor comment clarification.
2801 2014-07-29  Gary Dismukes  <dismukes@adacore.com>
2803         * sem_ch8.adb (Analyze_Object_Renaming): Set the Is_Volatile
2804         and Treat_As_Volatile flags based on whether the renamed object
2805         is a volatile object.
2807 2014-07-29  Olivier Hainque  <hainque@adacore.com>
2809         * g-debpoo.adb
2810         (Default_Alignment): Rename as Storage_Alignment. This is not
2811         a "default" that can be overriden. Augment comment to clarify
2812         intent and document why we need to manage alignment padding.
2813         (Header_Offset): Set to Header'Object_Size instead of 'Size
2814         rounded up to Storage_Alignment. Storage_Alignment on the
2815         allocation header is not required by our internals so was
2816         overkill. 'Object_Size is enough to ensure proper alignment
2817         of the header address when substracted from a storage address
2818         aligned on Storage_Alignment.
2819         (Minimum_Allocation): Rename as Extra_Allocation, conveying that
2820         this is always added on top of the incoming allocation requests.
2821         (Align): New function, to perform alignment rounding operations.
2822         (Allocate): Add comments on the Storage_Address computation
2823         scheme and adjust so that the alignment padding applies to that
2824         (Storage_Address) only.
2826 2014-07-29  Robert Dewar  <dewar@adacore.com>
2828         * exp_ch3.adb (Default_Initialize_Object): Remove incorrect
2829         pragma Unreferenced.
2830         * cstand.adb (Create_Standard): Use E_Array_Type for standard
2831         string types. Make sure index of Any_String/Any_Array is in a list.
2832         * errout.adb: Minor reformatting.
2834 2014-07-29  Robert Dewar  <dewar@adacore.com>
2836         * gnat_ugn.texi: Clean up and correct documentation of warnings.
2837         * usage.adb: Minor corrections to make sure warnings are properly
2838         documented.
2839         * warnsw.adb (Set_Warning_Switch): Remove redundant return statement.
2840         (WA_Warnings): Add Warn_On_Suspicious_Modulus_Value.
2842 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2844         * exp_ch3.adb (Expand_N_Object_Declaration): The dummy block
2845         created to match internal sequence numbers between compilations
2846         with/without abort must have its type properly set.
2848 2014-07-29  Robert Dewar  <dewar@adacore.com>
2850         * ali.adb (Initialize_ALI): Initialize SSO_Default_Specified
2851         (Scan_ALI): Set SSO_Default in ALIs_Record (Scan_ALI): Set
2852         SSO_Default_Specified.
2853         * ali.ads (ALIs_Record): Add field SSO_Default
2854         (SSO_Default_Specified): New global switch.
2855         * bcheck.adb (Check_Consistent_SSO_Default): New procedure
2856         (Check_Configuration_Consistency): Call this procedure
2857         * einfo.adb (SSO_Set_High_By_Default): New
2858         function (SSO_Set_Low_By_Default): New function
2859         (Set_SSO_Set_High_By_Default): New procedure
2860         (Set_SSO_Set_Low_By_Default): New procedure (Write_Entity_Flags):
2861         List new flags
2862         * einfo.ads (SSO_Set_Low_By_Default): New flag
2863         (SSO_Set_High_By_Default): New flag
2864         * freeze.adb (Set_SSO_From_Default): New procedure
2865         (Freeze_Array_Type): Call Set_SSO_From_Default
2866         (Freeze_Record_Type): Call Set_SSO_From_Default
2867         * gnat_rm.texi: Document pragma Default_Scalar_Storage_Order
2868         * lib-writ.adb (Write_ALI): Set OL/OH in P line as needed
2869         * lib-writ.ads: Add OL/OH parameters to P line
2870         * opt.adb: Set Default_SSO, Default_SSO_Config as appropriate
2871         * opt.ads (Default_SSO): New global switch (Default_SSO_Config):
2872         New global switch
2873         * repinfo.adb (List_Scalar_Storage_Order): List SSO when it is
2874         set by default using pragma Default_Scalar_Storage_Order.
2875         * sem.ads (Scope_Stack_Entry): Add component Save_Default_SSO
2876         * sem_ch13.adb (Inherit_Delayed_Rep_Aspects):
2877         Clear SSO defaults when explicit SSO is inherited.
2878         (Analyze_Attribute_Definition_Clause): Clear SSO defaults when
2879         explicit SSO is specified.
2880         (Inherit_Aspects_At_Freeze_Point):
2881         Clear SSO default when inheriting SSO.
2882         * sem_ch3.adb (Set_Default_SSO): New procedure
2883         (Analyze_Private_Extension_Declaration): Set defualt SSO
2884         (Array_Type_Declaration): ditto (Build_Derived_Array_Type): ditto
2885         (Build_Derived_Private_Type): ditto (Build_Derived_Record_Type):
2886         ditto (Build_Derived_Type): ditto (Make_Class_Wide_Type): ditto
2887         (Record_Type_Declaration): ditto
2888         * sem_ch8.adb (Pop_Scope): Restore Default_SSO (Push_Scope):
2889         Save Default_SSO
2890         * sem_prag.adb (Analyze_Pragma, case
2891         Default_Scalar_Storage_Order): Set Default_SSO
2893 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2895         * sem_ch6.adb (Valid_Operator_Definition): Verify that
2896         all parameter have mode IN. This check must be done here for
2897         subprogram instantiations that have operator names, because their
2898         analysis does not follow the same path as that for subprogram
2899         declarations.
2901 2014-07-29  Robert Dewar  <dewar@adacore.com>
2903         * freeze.adb (Freeze_Entity, Concurrent_Type case): Add a guard
2904         to make sure that the Etype of a component of the corresponding
2905         record type is present before trying to freeze it.
2906         * sem_ch5.adb: Minor reformatting.
2908 2014-07-29  Robert Dewar  <dewar@adacore.com>
2910         * exp_attr.adb, types.ads, types.h, exp_ch11.adb, a-except.adb,
2911         a-except-2005.adb: Add new reason code PE_Stream_Operation_Not_Allowed,
2912         and then use it when a stream operation is used from a library generic
2913         when the restriction (No_Streams) is active.
2915 2014-07-29  Thomas Quinot  <quinot@adacore.com>
2917         * projects.texi: Fix minor typo.
2919 2014-07-29  Yannick Moy  <moy@adacore.com>
2921         * sem_attr.adb (Analyze_Attribute): Fix generation of warning.
2923 2014-07-29  Arnaud Charlet  <charlet@adacore.com>
2925         * sem_ch5.adb (Check_Unreachable_Code): Do not remove code in
2926         CodePeer mode.
2928 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
2930         * exp_ch7.adb (Find_Last_Init): Add local variable
2931         Deep_Init_Found. Check the statement immediately following the
2932         declaration if [Deep_]Initialization was not found.
2934 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
2936         * exp_util.adb (Is_Aliased): It appears that
2937         'reference-d and renamed objects still play some role in Boolean
2938         expression with actions and cannot be finalized immediately.
2940 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2942         * exp_dbug.adb (Qualify_Needed):  For debugging purposes,
2943         Loop names are not part of the full qualification of entity names.
2945 2014-07-29  Robert Dewar  <dewar@adacore.com>
2947         * einfo.adb (Has_Protected): Test base type.
2948         * sem_ch4.adb (Analyze_Allocator): Reorganize code to make sure
2949         that we always properly check No_Protected_Type_Allocators.
2951 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
2953         * sem_util.ads, sem_util.adb (Defining_Entity): Now applies to
2954         loop declarations as well.
2955         * exp_ch5.adb (Expand_Loop_Statement): Apply Qualify_Entity_Names
2956         to an iterator loop, because it may contain local renaming
2957         declarations that require debugging information.
2959 2014-07-29  Robert Dewar  <dewar@adacore.com>
2961         * sem_util.ads, exp_util.adb, sem_attr.adb: Minor reformatting.
2963 2014-07-29  Robert Dewar  <dewar@adacore.com>
2965         * einfo.ads, einfo.adb (Static_Real_Or_String_Predicate): New function
2966         (Set_Static_Real_Or_String_Predicate): New procedure
2967         * sem_ch13.adb (Build_Predicate_Functions): Accomodate static
2968         string predicates (Is_Predicate_Static): Handle static string
2969         predicates.
2970         * sem_eval.adb (Real_Or_String_Static_Predicate_Matches):
2971         New procedure (Check_Expression_Against_Static_Predicate):
2972         Deal with static string predicates, now fully implemented
2973         (Eval_Relational_Op): Allow string equality/inequality as static
2974         if not comes from source.
2976 2014-07-29  Robert Dewar  <dewar@adacore.com>
2978         * sem_aggr.adb, exp_ch5.adb, sem_ch5.adb, exp_util.adb, einfo.adb,
2979         einfo.ads, sem_util.adb, sem_attr.adb, sem_case.adb, sem_eval.adb,
2980         sem_eval.ads, sem_ch13.adb: General cleanup of static predicate
2981         handling. Change name of Discrete_Predicate to
2982         Discrete_Static_Predicate, and replace testing of the presence of this
2983         field by testing the flag Has_Static_Expression.
2985 2014-07-29  Robert Dewar  <dewar@adacore.com>
2987         * gnat_rm.texi: Document pragma Unevaluated_Use_Of_Old.
2988         * opt.adb: Handle Uneval_Old.
2989         * opt.ads (Uneval_Old, Uneval_Old_Config): New variables.
2990         * par-prag.adb: Add dummy entry for pragma Unevaluated_Use_Of_Old.
2991         * sem.ads (Save_Uneval_Old): New field in Scope_Stack_Entry.
2992         * sem_attr.adb (Uneval_Old_Msg): New procedure.
2993         * sem_ch8.adb (Push_Scope): Save Uneval_Old.
2994         (Pop_Scope): Restore Uneval_Old.
2995         * sem_prag.adb (Analyze_Pragma, case Unevaluated_Use_Of_Old):
2996         Implemented.
2997         * snames.ads-tmpl: Add entries for pragma Unevaluated_Use_Of_Old
2998         Add entries for Name_Warn, Name_Allow.
3000 2014-07-29  Robert Dewar  <dewar@adacore.com>
3002         * sem_aggr.adb (Resolve_Array_Aggregate): Change Is_Static_Range
3003         to Is_OK_Static_Range.
3004         * sem_attr.adb (Eval_Attribute): Make sure we properly flag
3005         static attributes (Eval_Attribute, case Size): Handle size of
3006         zero properly (Eval_Attribute, case Value_Size): Handle size of
3007         zero properly.
3008         * sem_ch13.adb: Minor reformatting.
3009         * sem_ch3.adb (Process_Range_Expr_In_Decl): Change
3010         Is_Static_Range to Is_OK_Static_Range.
3011         * sem_eval.adb (Eval_Case_Expression): Total rewrite, was
3012         wrong in several ways (Is_Static_Range): Moved here from spec
3013         (Is_Static_Subtype): Moved here from spec Change some incorrect
3014         Is_Static_Subtype calls to Is_OK_Static_Subtype.
3015         * sem_eval.ads: Add comments to section on
3016         Is_Static_Expression/Raises_Constraint_Error (Is_OK_Static_Range):
3017         Add clarifying comments (Is_Static_Range): Moved to body
3018         (Is_Statically_Unevaluated): New function.
3019         * sem_util.ads, sem_util.adb (Is_Preelaborable_Expression): Change
3020         Is_Static_Range to Is_OK_Static_Range.
3021         * sinfo.ads: Additional commments for Is_Static_Expression noting
3022         that clients should almost always use Is_OK_Static_Expression
3023         instead. Many other changes throughout front end units to obey
3024         this rule.
3025         * tbuild.ads, tbuild.adb (New_Occurrence_Of): Set Is_Static_Expression
3026         for enumeration literal.
3027         * exp_ch5.adb, sem_intr.adb, sem_ch5.adb, exp_attr.adb, exp_ch9.adb,
3028         lib-writ.adb, sem_ch9.adb, einfo.ads, checks.adb, checks.ads,
3029         sem_prag.adb, sem_ch12.adb, freeze.adb, sem_res.adb, exp_ch4.adb,
3030         exp_ch6.adb, sem_ch4.adb, sem_ch6.adb, exp_aggr.adb, sem_cat.adb:
3031         Replace all occurrences of Is_Static_Expression by
3032         Is_OK_Static_Expression.
3034 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
3036         * exp_ch4.adb (Process_Transient_Object): Remove constant
3037         In_Cond_Expr, use its initialization expression in place.
3038         * exp_ch7.adb (Process_Declarations): There is no need to check
3039         that a transient object being hooked is controlled as it would
3040         not have been hooked in the first place.
3041         * exp_util.adb (Is_Aliased): 'Reference-d or renamed transient
3042         objects are not considered aliased when the related context is
3043         a Boolean expression_with_actions.
3044         (Requires_Cleanup_Actions): There is no need to check that a transient
3045         object being hooked is controlled as it would not have been hooked in
3046         the first place.
3048 2014-07-29  Robert Dewar  <dewar@adacore.com>
3050         * errout.adb: Minor reformatting.
3052 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
3054         * exp_ch3.adb (Default_Initialize_Object): Add new variables
3055         Abrt_Blk and Dummy. Generate a dummy temporary when aborts are
3056         not allowed to ensure the symmetrical generation of symbols.
3057         * exp_ch7.adb (Build_Object_Declarations): Remove variables A_Expr
3058         and E_Decl. Add new variables Decl and Dummy. Generate a dummy
3059         temporary when aborts are not allowed to ensure symmertrical
3060         generation of symbols.
3061         * exp_intr.adb (Expand_Unc_Deallocation): Add new variable
3062         Dummy. Generate a dummy temporary when aborts are not allowed
3063         to ensure symmertrical generation of symbols.
3065 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
3067         * exp_dbug.adb (Debug_Renaming_Declaration): For an object
3068         renaming, indicate that the renamed entity itself needs debug
3069         information. This is necessary if that entity is a temporary,
3070         e.g. part of the expansion of an explicit dereference in an
3071         iterator.
3073 2014-07-29  Thomas Quinot  <quinot@adacore.com>
3075         * errout.adb (Set_Error_Posted): When propagating flag to
3076         an enclosing named association, also propagate to the parent
3077         of that node, so that named and positional associations are
3078         treated consistently.
3080 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
3082         * sem_attr.adb (Resolve_Attribute, case 'Update):  Set
3083         Do_Range_Check properly on array component expressions that
3084         have a scalar type. In GNATprove mode, only checks on scalar
3085         components must be marked by the front-end.
3087 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
3089         * sem_res.adb (Resolve_Type_Conversion): If the type of the
3090         expression is a limited view, use the non-limited view when
3091         available.
3093 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
3095         * exp_ch4.adb (Expand_N_Case_Expression): Mark the generated
3096         case statement as coming from a conditional expression.
3097         (Expand_N_If_Expression): Mark the generated if statement as
3098         coming from a conditional expression.
3099         * exp_ch5.adb (Expand_N_Case_Statement): Do not process controlled
3100         objects found in case statement alternatives when the case
3101         statement is actually a case expression.
3102         (Expand_N_If_Statement):
3103         Do not process controlled objects found in an if statement when
3104         the if statement is actually an if expression.
3105         * sinfo.adb (From_Conditional_Expression): New routine.
3106         (Set_From_Conditional_Expression): New routine.
3107         * sinfo.ads Add new semantic flag From_Conditional_Expression and
3108         update related nodes.
3109         (From_Conditional_Expression): New routine along with pragma Inline.
3110         (Set_From_Conditional_Expression): New routine along with pragma Inline.
3112 2014-07-29  Hristian Kirtchev  <kirtchev@adacore.com>
3114         * exp_ch7.adb (Build_BIP_Cleanup_Stmts): Remove
3115         formal parameter Obj_Id and update the comment on usage. Renamed
3116         Obj_Typ to Func_Typ and update all occurrences.
3117         (Find_Last_Init): Remove formal parameter Decl and update the comment
3118         on usage.
3119         Remove local constants Obj_Id and Obj_Typ. Remove local variables
3120         Init_Typ and Is_Conc. Remove the extraction of the initialization type.
3121         (Find_Last_Init_In_Block): Remove formal parameter
3122         Init_Typ and update the comment on usage.
3123         (Is_Init_Call): Remove formal parameter Init_Typ and update the comment
3124         on usage. Check whether the procedure call is an initialization
3125         procedure of either the object type or the initialization type.
3126         (Is_Init_Proc_Of): New routine.
3127         (Process_Object_Declaration): Obj_Id and Obj_Typ are now global to this
3128         routine. Add new variable Init_Typ. Add circuitry to extract the object
3129         type as well as the initialization type.
3131 2014-07-29  Robert Dewar  <dewar@adacore.com>
3133         * sem_case.adb: Minor reformatting.
3134         * sem_aux.ads: Minor reformatting.
3136 2014-07-29  Ed Schonberg  <schonberg@adacore.com>
3138         * sinfo.adb (Set_Else_Actions, Set_Then_Actions): Set parent
3139         pointer on these fields, even though they are semantic, because
3140         subsequent analysis and expansion of action nades may require
3141         exploring the tree, for example to locate a node to be wrapped
3142         when a function with controlled result is called.
3144 2014-07-29  Claire Dross  <dross@adacore.com>
3146         * sem_aux.adb (Get_Binary_Nkind): Use case on
3147         Name_Id instead of an intermediate string.
3148         (Get_Unary_Nkind): Use case on Name_Id instead of an intermediate
3149         string.
3151 2014-07-29  Sergey Rybin  <rybin@adacore.com frybin>
3153         * gnat_ugn.texi (gnatelim, gnatstub, gnatmetric): Add note
3154         about processing sources with preprocessor directives.
3156 2014-07-24  Martin Liska  <mliska@suse.cz>
3158         * gcc-interface/trans.c (finalize_nrv): Adjust function call.
3159         * gcc-interface/utils.c (rest_of_subprog_body_compilation): Likewise.
3160         (gnat_write_global_declarations): Likewise.
3162 2014-07-19  David Wohlferd  <dw@LimeGreenSocks.com>
3164         * gnat_rm.texi: Clean up for makeinfo 5.2.
3166 2014-07-19  David Wohlferd  <dw@LimeGreenSocks.com>
3168         * gnat_rm.texi (Machine Code Insertions): Clean up.
3170 2014-07-18  Robert Dewar  <dewar@adacore.com>
3172         * exp_ch7.adb: Minor reformatting.
3174 2014-07-18  Claire Dross  <dross@adacore.com>
3176         * sem_aux.ads (Get_Binary_Nkind): New function that returns
3177         the Node_Kind value of an entity defining a binary operator.
3178         (Get_Unary_Nkind): New function that returns the Node_Kind value
3179         of an entity defining a unary operator.
3181 2014-07-18  Pascal Obry  <obry@adacore.com>
3183         * sysdep.c: comment update.
3184         * adaint.c (__gnat_fputwc): Use wchar_t on a limited set of
3185         platforms where it is known to be supported.
3187 2014-07-18  Thomas Quinot  <quinot@adacore.com>
3189         * sem_dist.adb (Process_Remote_AST_Declaration): Need
3190         to set Fat_Type's Ekind in order to be able to use its
3191         Corresponding_Remote_Type attribute.
3193 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
3195         * einfo.adb Last_Aggregate_Assignment is now Node 30.
3196         (Last_Aggregate_Assignment): Include
3197         constants in the assertion. Update the underlying node.
3198         (Set_Last_Aggregate_Assignment): Include constants in the
3199         assertion. Update the underlying node.  (Write_Field11_Name):
3200         Remove the entry for Last_Aggregate_Assignment.
3201         (Write_Field30_Name): Add an entry for Last_Aggregate_Assignment.
3202         * einfo.ads Update the node designation and usage of attribute
3203         Last_Aggregate_Assignment.
3204         * exp_aggr.adb (Expand_Array_Aggregate): Store the last
3205         assignment statement used to initialize a controlled object.
3206         (Late_Expansion): Store the last assignment statement used to
3207         initialize a controlled record or an array of controlled objects.
3208         * exp_ch3.adb (Expand_N_Object_Declaration): Default
3209         initialization of objects is now performed in a separate routine.
3210         (Default_Initialize_Object): New routine.
3211         * exp_ch7.adb (Build_BIP_Cleanup_Stmts): Add formal parameter
3212         Obj_Id. Update the comment on usage.
3213         (Find_Last_Init): Remove formal parameter Typ. Update comment on usage.
3214         Reimplement the logic.  (Find_Last_Init_In_Block): New routine.
3215         (Is_Init_Call): Add formal parameter Init_Typ. Update the
3216         comment on usage.  Account for the type init proc when trying
3217         to determine whether a statement is an initialization call.
3218         (Make_Adjust_Call): Rename formal parameter For_Parent to
3219         Skip_Self. Update all occurrences of For_Parent. Account for
3220         non-tagged types. Update the call to Make_Call.
3221         (Make_Call): Rename formal parameter For_Parent to Skip_Self. Update
3222         comment on usage. Update all occurrences of For_Parent.
3223         (Make_Final_Call): Rename formal parameter For_Parent to
3224         Skip_Self. Update all occurrences of For_Parent. Account
3225         for non-tagged types. Update the call to Make_Call.
3226         (Process_Object_Declaration): Most variables and constants are
3227         now local to the routine.
3228         * exp_ch7.ads (Make_Adjust_Call): Rename formal parameter
3229         For_Parent to Skip_Self. Update the comment on usage.
3230         (Make_Final_Call): Rename formal parameter For_Parent to
3231         Skip_Self. Update the comment on usage.
3233 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3235         * sem_ch9.adb (Analyze_Requeue): The entry being referenced
3236         can be a procedure that is implemented by entry, and have a
3237         formal that is a synchronized interface.  It does not have to
3238         be declared as a protected operation.
3240 2014-07-18  Robert Dewar  <dewar@adacore.com>
3242         * gnat_rm.texi: Remove mention of obsolete attributes
3243         Max[_Interrupt]_Priority, which have never been implemented
3244         (or at the very least were removed long ago if they ever were
3245         implemented.  Add documentation of Max[_Interrupt]_Priority
3246         constants in package System.
3247         * ttypes.ads: Document actual handling of package System,
3248         rather than a historical fantasy version.  Remove mention of
3249         non-existent attributes Max[_Interrupt]_Priority.
3251 2014-07-18  Pascal Obry  <obry@adacore.com>
3253         * a-witeio.adb (Put): No 16-bit character output when text
3254         translation is disabled.
3255         * i-cstrea.ads: Code clean up.
3257 2014-07-18  Robert Dewar  <dewar@adacore.com>
3259         * gnat_rm.texi: Document that Wchar_T_Size and Word_Size are
3260         static attributes.
3262 2014-07-18  Arnaud Charlet  <charlet@adacore.com>
3264         * a-witeio.adb, initialize.c: Update comments. Minor clean ups.
3266 2014-07-18  Pascal Obry  <obry@adacore.com>
3268         * adaint.c: Do not include wchar.h on VxWorks.
3269         * mingw32.h: Remove obsolete definition.
3271 2014-07-18  Pascal Obry  <obry@adacore.com>
3273         * a-textio.adb, a-witeio.adb, a-ztexio.adb: Use C_Streams Default_Text.
3274         * i-cstrea.ads (Content_Encoding): Moved here, add convention C.
3275         * s-ficobl.ads (Content_Encoding): Moved to C_Streams.
3276         * s-fileio.adb (Open): Adjust to use Content_Encoding from C_Streams.
3278 2014-07-18  Pascal Obry  <obry@adacore.com>
3280         * a-textio.adb: Rename Is_Text_File to Text_Encoding.
3281         * a-ztexio.adb: Likewise.
3282         * a-witeio.adb: Likewise.
3283         (Open): Pass file's translation mode to set_text_mode.
3284         * s-ficobl.ads (Content_Encoding): New type.
3285         (Text_Content_Encoding): New subtype.
3286         (AFCB): Rename Is_Text_File to Text_Encoding.
3287         * s-fileio.adb (Open): Handles new text_translation
3288         values. Remove Is_Text_File which is equivalent to Text_Encoding
3289         in Text_Content_Encoding.
3290         * adaint.h (__gnat_set_mode): New routine.
3291         * sysdep.c (__gnat_set_wide_text_mode): Removed.
3292         (__gnat_set_mode): New routine.
3294 2014-07-18  Arnaud Charlet  <charlet@adacore.com>
3296         * gcc-interface/decl.c, gcc-interface/trans.c,
3297         gcc-interface/utils.c (Is_Packed_Array_Type): Renamed 
3298         Is_Packed_Array_Impl_Type.
3300 2014-07-18  Gary Dismukes  <dismukes@adacore.com>
3302         * sem_util.adb: Minor typo correction.
3304 2014-07-18  Ben Brosgol  <brosgol@adacore.com>
3306         * gnat_rm.texi: Complete previous change.
3308 2014-07-18  Pascal Obry  <obry@adacore.com>
3310         * s-fileio.adb: Minor style fix.
3312 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3314         * sem_ch13.adb (Analyze_Aspect_Specifications): Detect improper
3315         specification of stream attributes for subtypes that are not
3316         first subtypes, to prevent malformed rep_item chains in the case
3317         of such illegal specifications for discriminated private subtypes.
3318         (Check_Overloaded_Name): Verify that the name is an entity name
3319         before other checks.
3321 2014-07-18  Pascal Obry  <obry@adacore.com>
3323         * adaint.c (__gnat_fputwc) Do not disable on cross-build.
3325 2014-07-18  Robert Dewar  <dewar@adacore.com>
3327         * sem_prag.adb, sem_attr.adb,
3328         sem_aggr.adb, sinfo.ads, sem_eval.ads: Minor reformatting.
3330 2014-07-18  Pascal Obry  <obry@adacore.com>
3332         * sysdep.c (__gnat_wide_text_translation_required): Removed from here.
3333         * initialize.c (__gnat_wide_text_translation_required): Defined here.
3335 2014-07-18  Pascal Obry  <obry@adacore.com>
3337         * adaint.c (__gnat_fputwc): New routine.
3338         * s-crtl.ads (fputwc): Now imported as __gnat_fputwc.
3340 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
3342         * einfo.adb: Flag 270 is now used as Stores_Attribute_Old_Prefix.
3343         (Set_Stores_Attribute_Old_Prefix): New routine.
3344         (Stores_Attribute_Old_Prefix): New routine.
3345         (Write_Entity_Flags):
3346         Output flag Stores_Attribute_Old_Prefix.
3347         * einfo.ads Add new flag Stores_Attribute_Old_Prefix along with
3348         comment on usage.
3349         (Set_Stores_Attribute_Old_Prefix): New routine
3350         along with pragma Inline.
3351         (Stores_Attribute_Old_Prefix): New
3352         routine along with pragma Inline.
3353         * exp_attr.adb (Expand_N_Attribute_Reference): Mark the generated
3354         constant which captures the result of attribute 'Old's prefix.
3355         * sem_util.adb (In_Assertion_Expression_Pragma): Recognize a
3356         relocated expression which acted as a prefix of attribute 'Old.
3358 2014-07-18  Bob Duff  <duff@adacore.com>
3360         * s-spsufi.adb (Finalize_And_Deallocate): Set Subpool.Owner to
3361         null before dispatching to Deallocate_Subpool.
3362         * s-stposu.ads (Default_Subpool_For_Pool): Change mode of
3363         parameter of Default_Subpool_For_Pool to 'in out'.
3364         * s-stposu.adb (Set_Pool_Of_Subpool): Use raise expression. Add
3365         a message to the raise.
3366         * sem_util.adb: Minor reformatting.
3368 2014-07-18  Robert Dewar  <dewar@adacore.com>
3370         * sem_util.adb (Check_Expression_Against_Static_Predicate):
3371         Mark expression as non-static if it fails static predicate check,
3372         and issue additional warning.
3374 2014-07-18  Pascal Obry  <obry@adacore.com>
3376         * a-witeio.adb (Put): Control translation based on
3377         wide_text_translation_required.
3378         * adaint.c (CurrentCCSEncoding): New variable.
3379         * initialize.c (__gnat_initialize): On Windows initialize
3380         CurrentCCSEncoding based on values in GNAT_CCS_ENCODING
3381         environment variable.
3382         * mingw32.h (CurrentCCSEncoding): New external.
3383         (__gnat_wide_text_translation_required): Likewise.
3384         * sysdep.c (wide_text_translation_required): New variable.
3385         (__gnat_set_wide_text_mode): Set mode based on CurrentCCSEncoding.
3387 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
3389         * sem_prag.adb (Analyze_Refined_Depends_In_Decl_Part): Remove global
3390         variable Refined_States.  Add global variable Matched_Items.
3391         (Check_Dependency_Clause): Account for dependency
3392         clauses utilizing states with visible null refinements.
3393         (Is_Null_Refined_State): New routine.
3394         (Match_Items): Record each successfully matched item of pragma Depends.
3395         (Record_Item): New routine.
3397 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3399         * sem_attr.adb (Analyze_Attribute, case 'Update): Set
3400         Do_Range_Check flag on a dynamic index expression used in a
3401         component association in the argument of Update.
3403 2014-07-18  Gary Dismukes  <dismukes@adacore.com>
3405         * einfo.ads, sem_eval.ads, sem_ch13.adb: Minor reformatting.
3407 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
3409         * exp_ch6.adb (Expand_Simple_Function_Return): Redo the marking
3410         of enclosing blocks, loops and the enclosing function using a
3411         parent-based traversal.
3412         * exp_util.adb (Wrap_Statements_In_Block): Suppress the secondary
3413         stack reclamation if the iterator loop contains a return statement
3414         that uses the stack.
3415         * sem_ch5.adb (Analyze_Loop_Statement): There is no need to
3416         patch up the scope stack as the secondary stack management now
3417         takes into account the enclosing function of the iterator loop.
3419 2014-07-18  Robert Dewar  <dewar@adacore.com>
3421         * sem_ch3.adb, g-memdum.ads, i-cstrea.ads: Minor reformatting.
3423 2014-07-18  Robert Dewar  <dewar@adacore.com>
3425         * einfo.adb (Has_Static_Predicate): New function.
3426         (Set_Has_Static_Predicate): New procedure.
3427         * einfo.ads (Has_Static_Predicate): New flag.
3428         * sem_ch13.adb (Is_Predicate_Static): New function
3429         (Build_Predicate_Functions): Use Is_Predicate_Static to reorganize
3430         (Add_Call): Minor change in Sloc of generated expression
3431         (Add_Predicates): Remove setting of Static_Pred, no longer used.
3432         * sem_ch4.adb (Has_Static_Predicate): Removed this function,
3433         replace by use of the entity flag Has_Static_Predicate_Aspect.
3434         * sem_eval.adb (Eval_Static_Predicate_Check): Check real case
3435         and issue warning that predicate is not checked for now.
3436         * sem_eval.ads (Eval_Static_Predicate_Check): Fix comments in
3437         spec.
3438         * sem_util.adb (Check_Expression_Against_Static_Predicate):
3439         Carry out check for any case where there is a static predicate,
3440         and output appropriate message.
3441         * sinfo.ads: Minor comment corrections.
3443 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3445         * exp_ch3.adb (Expand_Freeze_Record_Type): If the type is derived
3446         from an untagged private type whose full view is tagged, the type
3447         is marked tagged for layout reasons, but it has no dispatch table,
3448         so Set_All_DT_Position must not be called.
3449         * exp_ch13.adb: If the freeze node is for a type internal to a
3450         record declaration, as is the case for a class-wide subtype
3451         of a parent component, the relevant scope is the scope of the
3452         enclosing record.
3454 2014-07-18  Thomas Quinot  <quinot@adacore.com>
3456         * g-memdum.adb, g-memdum.ads: Code clean ups.
3458 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
3460         * sem_prag.adb (Check_Dependency_Clause):
3461         Update the comment on usage. Reimplement the mechanism which
3462         attempts to match a single clause of Depends against one or
3463         more clauses of Refined_Depends.
3464         (Input_Match): Removed.
3465         (Inputs_Match): Removed.
3466         (Is_Self_Referential): Removed.
3467         (Normalize_Clause): Update the call to Split_Multiple_Outputs.
3468         (Normalize_Outputs): Rename variable Split to New_Claue and update
3469         all its occurrences.
3470         (Report_Extra_Clauses): Update the comment on usage.
3471         (Split_Multiple_Outputs): Renamed to Normalize_Outputs.
3473 2014-07-18  Gary Dismukes  <dismukes@adacore.com>
3475         * i-cstrea.ads: Minor reformatting.
3477 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
3479         * exp_util.adb (Wrap_Statements_In_Block): Propagate both
3480         secondary stack-related flags to the generated block.
3481         * sem_ch5.adb (Analyze_Loop_Statement): Update the scope chain
3482         once the loop is relocated in a block.
3484 2014-07-18  Robert Dewar  <dewar@adacore.com>
3486         * repinfo.ads: Add documentation on handling of back annotation
3487         for dynamic case.
3489 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3491         * sinfo.ads, sinfo.adb (Incomplete_View): New semantic attribute
3492         of full type declaration, denotes previous declaration for
3493         incomplete view of the type.
3494         * sem_ch3.adb (Analyze_Full_Type_Declaration): Set Incomplete_View
3495         of declaration if one is present.
3496         (Replace_Type): When constructing the signature of an inherited
3497         operation, handle properly the case where the operation has a
3498         formal whose type is an incomplete view.
3499         * sem_util.adb (Collect_Primitive_Operations): Handle properly
3500         the case of an operation declared after an incomplete declaration
3501         for a type T and before the full declaration of T.
3503 2014-07-18  Pascal Obry  <obry@adacore.com>
3505         * i-cstrea.ads: Add documentation for set_wide_text_mode.
3507 2014-07-18  Robert Dewar  <dewar@adacore.com>
3509         * a-witeio.adb: Minor code reorganization.
3510         * i-cstrea.ads: Add comment.
3512 2014-07-18  Thomas Quinot  <quinot@adacore.com>
3514         * s-oscons-tmplt.c (NAME_MAX): Minor cleaup and comment
3515         clarifications.
3517 2014-07-18  Robert Dewar  <dewar@adacore.com>
3519         * g-memdum.adb, g-memdum.ads, exp_strm.adb: Minor reformatting.
3521 2014-07-18  Pascal Obry  <obry@adacore.com>
3523         * s-crtl.ads, i-cstrea.ads (fputwc): New routine.
3524         * a-witeio.adb (Put): On platforms where there is translation
3525         done by the OS output the raw text.
3526         (New_Line): Use Put above to properly handle the LM wide characters.
3528 2014-07-18  Thomas Quinot  <quinot@adacore.com>
3530         * g-memdum.adb, g-memdum.ads (Dump): New parameter Prefix, defaulted
3531         to Absolute_Address.
3533 2014-07-18  Eric Botcazou  <ebotcazou@adacore.com>
3535         * opt.ads (Suppress_Back_Annotation): Remove as unused.
3536         * fe.h (Back_Annotate_Rep_Info): Likewise.
3537         (Global_Discard_Names): Likewise.
3539 2014-07-18  Robert Dewar  <dewar@adacore.com>
3541         * sem_ch13.adb (Is_Type_Ref): Check that type name is not
3542         parenthesized.
3544 2014-07-18  Vincent Celier  <celier@adacore.com>
3546         * s-osinte-vms.ads: Fix style errors.
3548 2014-07-18  Thomas Quinot  <quinot@adacore.com>
3550         * s-oscons-tmplt.c (_POSIX_SOURCE): Define in order to get
3551         NAME_MAX and PATH_MAX.
3553 2014-07-18  Bob Duff  <duff@adacore.com>
3555         * exp_strm.adb (Build_Record_Or_Elementary_Input_Function,
3556         Build_Record_Or_Elementary_Output_Procedure): For Input and
3557         Output attributes, do not read/write the discriminants if they
3558         have default values; that will be done by Read/Write.
3560 2014-07-18  Robert Dewar  <dewar@adacore.com>
3562         * sem_aggr.adb, exp_ch5.adb, sem_ch3.adb, layout.adb, sem_type.adb,
3563         exp_util.adb, exp_attr.adb, einfo.adb, einfo.ads, exp_pakd.adb,
3564         checks.adb, exp_pakd.ads, freeze.adb, sem_util.adb, exp_dbug.adb,
3565         exp_dbug.ads, exp_ch4.adb, sem_ch8.adb, exp_aggr.adb, sem_eval.adb,
3566         sem_ch13.adb: Change name Packed_Array_Type to Packed_Array_Impl_Type.
3568 2014-07-18  Robert Dewar  <dewar@adacore.com>
3570         * lib-writ.adb, makeutl.adb, ali.ads: Minor reformatting.
3572 2014-07-18  Vincent Celier  <celier@adacore.com>
3574         * lib-writ.ads: Update documentation about the D lines.
3576 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3578         * sem_ch13.adb (Replace_Type_References_Generic): Use type entity
3579         as a parameter, rather than its Chars field, in order to locate
3580         freeze node of type. If the predicate or invariant has references
3581         to types other than the one to which the contract applies, these
3582         types must be frozen, and the corresponding predicate functions
3583         created, before that freeze node.
3585 2014-07-18  Robert Dewar  <dewar@adacore.com>
3587         * freeze.adb, einfo.ads, einfo.adb: Minor code reorganization.
3588         * par_sco.adb: Minor reformatting.
3590 2014-07-18  Gary Dismukes  <dismukes@adacore.com>
3592         * exp_ch4.adb (Real_Range_Check): Turn off
3593         the Do_Range_Check flag on the conversion's current Expression
3594         argument rather than on the originally captured Operand node,
3595         as Expression may reflect a rewriting (as in conversions to a
3596         fixed-point type).
3598 2014-07-18  Vincent Celier  <celier@adacore.com>
3600         * ali.adb (Scan_ALI): Set Sdep_Record.Unit_Name, when the unit
3601         is not a subunit.
3602         * ali.ads (Sdep_Record): New component Unit_Name.
3603         * lib-writ.adb (Write_ALI): Write the unit name in D lines.
3604         * makeutl.adb (Check_Source_Info_In_ALI): Return False if a
3605         dependent unit is in a project and the source file name is not
3606         one of its sources.
3608 2014-07-18  Bob Duff  <duff@adacore.com>
3610         * s-addima.ads: Minor: add comment.
3612 2014-07-18  Thomas Quinot  <quinot@adacore.com>
3614         * freeze.adb (Check_Component_Storage_Order): Fix enforcement
3615         of nesting rules for composites with different SSOs.
3617 2014-07-18  Thomas Quinot  <quinot@adacore.com>
3619         * par_sco.adb (Is_Logical_Operator): An If_Expression is not
3620         a proper logical operator.
3621         (Has_Decision): An If_Expression indicates the presence of a decision
3622         although it is not a logical operator.
3624 2014-07-18  Robert Dewar  <dewar@adacore.com>
3626         * gnat_ugn.texi: Remove note that -gnatR not allowed with -gnatc.
3627         * switch-c.adb: Remove prohibition of -gnatR and -gnatc together.
3629 2014-07-18  Eric Botcazou  <ebotcazou@adacore.com>
3631         * sem_ch13.adb (Kill_Rep_Clause): Clear Comes_From_Source flag
3632         on the null statement.
3634 2014-07-18  Thomas Quinot  <quinot@adacore.com>
3636         * adaint.c: Minor comment rewording.
3637         * socket.c: Define macros _REENTRANT and _THREAD_SAFE so that
3638         use of errno in this file is thread safe.
3640 2014-07-18  Arnaud Charlet  <charlet@adacore.com>
3642         * gnat_ugn.texi: Doc clarification.
3643         * sem_ch13.adb (Kill_Rep_Clause): Use Replace not Rewrite.
3644         * sem_ch13.ads: Minor comment update.
3646 2014-07-18  Robert Dewar  <dewar@adacore.com>
3648         * repinfo.ads: Minor comment fix.
3650 2014-07-18  Robert Dewar  <dewar@adacore.com>
3652         * par-prag.adb: Add dummy entry for Default_Scalar_Storage_Order.
3653         * sem_prag.adb: Add dummy implementation of
3654         Default_Scalar_Storage_Order.
3655         * snames.ads-tmpl: Add dummy entry for
3656         Default_Scalar_Storage_Order pragma.
3658 2014-07-18  Robert Dewar  <dewar@adacore.com>
3660         * opt.adb (Tree_Read): Read Address_Is_Private,
3661         Ignore_Rep_Clauses, Ignore_Style_Check_Pragmas, Multiple_Unit_Index.
3662         (Tree_Write): Corresponding writes
3663         * opt.ads: Minor comment reformatting and fixes.
3664         * tree_io.ads: Increment ASIS_Version_Number.
3666 2014-07-18  Robert Dewar  <dewar@adacore.com>
3668         * sem_attr.adb, s-os_lib.ads, prj-tree.adb: Minor reformatting.
3669         * types.h: Fix typo.
3671 2014-07-18  Robert Dewar  <dewar@adacore.com>
3673         * freeze.adb (Check_Address_Clause): Use Kill_Rep_Clause (no
3674         functional change).
3675         * gnat_ugn.texi: Document that -gnatI removes rep clauses from
3676         ASIS trees.
3677         * sem_ch13.adb (Kill_Rep_Clause): New procedure
3678         (Analyze_Attribute_Definition_Clause): Use
3679         Kill_Rep_Clause. This is just a cleanup, no functional effect.
3680         (Analyze_Enumeration_Representation_Clause):
3681         Use Kill_Rep_Clause. This means that enum rep
3682         clauses are now properly removed from -gnatct trees.
3683         (Analyze_Record_Representation_Clause): Same change.
3684         * sem_ch13.ads (Kill_Rep_Clause): New procedure.
3686 2014-07-18  Pascal Obry  <obry@adacore.com>
3688         * s-os_lib.ads, s-os_lib.adb (GM_Time_Of): New routine to create an
3689         OS_Time from time parts.
3690         * adaint.h, adaint.c (__gnat_to_os_time): New routine.
3692 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3694         * sem_ch4.adb (Try_Container_Indexing): Refine previous patch for
3695         indexing over containers that are derived types: check whether
3696         signature of found operation has the correct first parameter
3697         before retrieving directly a primitive operation.
3699 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3701         * sem_attr.adb (Analyze_Attribute, case 'Update): Set
3702         Do_Range_Check flag on dynamic bounds of a range used in a
3703         component association in the argument of Update.
3705 2014-07-18  Thomas Quinot  <quinot@adacore.com>
3707         * adaint.c: #define _REENTRANT and _THREAD_SAFE in order for
3708         accesses to errno(3) to be thread safe.
3710 2014-07-18  Vincent Celier  <celier@adacore.com>
3712         * prj-tree.adb (Imported_Or_Extended_Project_Of): For each non
3713         limited imported project that is an extending project, return
3714         a project being extended if it has the expected name.
3716 2014-07-18  Pascal Obry  <obry@adacore.com>
3718         * s-os_lib.ads, s-os_lib.adb (Set_File_Last_Modify_Time_Stamp): New
3719         routine to set the last modification time stamp for the given file.
3720         * gnatchop.adb (File_Time_Stamp): Removed.
3721         (Write_Unit): Use
3722         Set_File_Last_Modify_Time_Stamp instead of ad-hoc implementation.
3724 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3726         * sem_aggr.adb (Aggregate_Constraint_Checks): Moved to sem_util.
3727         * sem_util.ads, sem_util.adb (Aggregate_Constraint_Checks):
3728         Moved here, so it can be shared with the resolution of 'Update,
3729         whose argument shares some features with aggregates.
3730         * sem_attr.adb (Resolve_Attribute, case 'Update): Apply
3731         Aggregate_Constraint_Checks with the expression of each
3732         association, so that the Do_Range_Check flag is set when needed.
3734 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3736         * sem_ch4.adb (Try_Container_Indexing):  If the container
3737         type is a derived type, the value of the inherited  aspect is
3738         the Reference operation declared for the parent type. However,
3739         Reference is also a primitive operation of the new type, and
3740         the inherited operation has a different signature. We retrieve
3741         the right one from the list of primitive operations of the
3742         derived type.
3744 2014-07-18  Vincent Celier  <celier@adacore.com>
3746         * debug.adb: Update comment.
3748 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
3750         * exp_util.adb (Needs_Finalization): There is no reason why a
3751         C type should not benefit from finalization actions.
3753 2014-07-18  Thomas Quinot  <quinot@adacore.com>
3755         * s-oscons-tmplt.c (NAME_MAX): Fix definition for Solaris
3756         (FILENAME_MAX): Remove unneeded definition.
3758 2014-07-18  Robert Dewar  <dewar@adacore.com>
3760         * exp_attr.adb, debug.adb: Update comments.
3762 2014-07-18  Vincent Celier  <celier@adacore.com>
3764         * par-ch4.adb (Simple_Expression): Add missing style check
3765         for binary adding operators.
3766         (Term): Add missing style check for multiplying operators.
3768 2014-07-18  Robert Dewar  <dewar@adacore.com>
3770         * impunit.adb: Minor comment correction.
3771         * widechar.adb, s-wchcon.ads: Minor comment corrections.
3773 2014-07-18  Robert Dewar  <dewar@adacore.com>
3775         * sem_ch13.adb (Build_Discrete_Static_Predicate): New name
3776         for Build_Static_Predicate (Build_Predicate_Functions):
3777         Don't try to build discrete predicate for real type.
3778         (Build_Predicate_Functions): Report attempt to use
3779         Static_Predicate function on real type as unimplemented.
3780         * sem_util.adb (Check_Expression_Against_Static_Predicate):
3781         Add guard to prevent blow up on predicate for real type.
3783 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3785         * einfo.adb (Set_Static_Predicate): Simplify assertion to handle
3786         properly static predicate on enumeration types and modular types
3787         (not subtypes).
3789 2014-07-18  Pierre-Marie Derodat  <derodat@adacore.com>
3791         * scos.ads (SCO_Unit_Table_Entry): Add a field to keep track of
3792         the corresponding source file index.
3793         * get_scos.ads (Get_SCOs): Add a default value for it.
3794         * par_sco.adb (SCO_Record): Fill the corresponding value.
3795         * scos.h: New.
3797 2014-07-18  Vincent Celier  <celier@adacore.com>
3799         * a-strunb-shared.adb, s-auxdec.ads, s-rannum.adb, atree.ads,
3800         urealp.adb, vms_data.ads, lib.ads, s-auxdec-vms_64.ads: Minor
3801         reformatting.
3802         * gnat_ugn.texi: Add documentation for new gnatmem switch -t.
3804 2014-07-18  Thomas Quinot  <quinot@adacore.com>
3806         * g-sercom.ads (Set): document possible data loss.
3808 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3810         * exp_attr.adb (Expand_N_Attribute_Reference, cases Input,
3811         Output, Read, Write): If the restriction No_Streams is active,
3812         replace each occurrence of a stream attribute by an explicit
3813         Raise statement.
3815 2014-07-18  Robert Dewar  <dewar@adacore.com>
3817         * par_sco.adb, a-reatim.ads, exp_attr.adb, sem_util.adb: Minor
3818         reformatting.
3820 2014-07-18  Robert Dewar  <dewar@adacore.com>
3822         * einfo.ads, einfo.adb (Has_Out_Or_In_Out_Parameter): New flag and
3823         function.
3824         (Set_Has_Out_Or_In_Out_Parameter): New procedure.
3825         * sem_ch6.adb (Set_Formal_Mode): Set Has_Out_Or_In_Out_Parameter flag.
3826         * sem_res.adb (Resolve_Call): Error if call of Ada 2012 function
3827         with OUT or IN OUT from earlier Ada mode (e.g. Ada 2005)
3829 2014-07-18  Robert Dewar  <dewar@adacore.com>
3831         * bcheck.adb (Check_Consistent_Restrictions):
3832         Remove obsolete code checking for violation of
3833         No_Standard_Allocators_After_Elaboration (main program)
3834         * bindgen.adb (Gen_Adainit): Handle
3835         No_Standard_Allocators_After_Elaboration
3836         (Gen_Output_File_Ada): ditto.
3837         * exp_ch4.adb (Expand_N_Allocator): Handle
3838         No_Standard_Allocators_After_Elaboration.
3839         * Makefile.rtl: Add entry for s-elaall
3840         * rtsfind.ads: Add entry for Check_Standard_Allocator.
3841         * s-elaall.ads, s-elaall.adb: New files.
3842         * sem_ch4.adb (Analyze_Allocator): Handle
3843         No_Standard_Allocators_After_Elaboration.
3845 2014-07-18  Robert Dewar  <dewar@adacore.com>
3847         * lib.adb, lib.ads, lib-writ.adb, lib-writ.ads, ali.adb,
3848         ali.ads, lib-load.adb: Remove Lib.Has_Allocator and all uses.
3849         Remove AB parameter from ali files and all uses.
3850         Remove Allocator_In_Body and all uses.
3852 2014-07-18  Robert Dewar  <dewar@adacore.com>
3854         * g-expect-vms.adb: Add comment.
3856 2014-07-18  Thomas Quinot  <quinot@adacore.com>
3858         * par_sco.adb (Is_Logical_Operation): return True for
3859         N_If_Expression.
3861 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3863         * sem_attr.adb (Resolve_Attribute, case 'Update): Do full
3864         analysis and resolution of each choice in the associations within
3865         the argument of Update, because they may be variable names.
3867 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
3869         * exp_attr.adb (Expand_Loop_Entry_Attribute): Insert any condition
3870         actions before the generated if statement.
3872 2014-07-18  Hristian Kirtchev  <kirtchev@adacore.com>
3874         * gnat_ugn.texi Enhance the documentation of
3875         switches -gnateA and -gnateV.
3877 2014-07-18  Ed Schonberg  <schonberg@adacore.com>
3879         * sem_util.adb (Build_Default_Subtype): Add missing condition
3880         so that code matches description: use the full view of the base
3881         only if the base is private and the subtype is not.
3883 2014-07-17  Gary Dismukes  <dismukes@adacore.com>
3885         * exp_disp.adb: Minor reformatting.
3886         * exp_disp.adb: Minor code reorganization.
3888 2014-07-17  Thomas Quinot  <quinot@adacore.com>
3890         * gnat_rm.texi, freeze.adb (Check_Component_Storage_Order): Do not
3891         require an explicit SSO attribute definition clause on a composite type
3892         just because one of its components has one.
3894 2014-07-17  Robert Dewar  <dewar@adacore.com>
3896         * sem_attr.adb (Analyze_Attribute, case Loop_Entry): Rewrite
3897         attribute out of existence if the enclosing pragma is ignored.
3898         * sem_util.adb: Minor reformatting.
3900 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
3902         * exp_aggr.adb (Expand_Array_Aggregate): Handle properly an
3903         array aggregate expanded into assignments when it appears as a
3904         local declaration in an inlined body.
3906 2014-07-17  Doug Rupp  <rupp@adacore.com>
3908         * init.c [__ANDROID__]: Modify for ZCX.
3909         * exp_aggr.adb: Minor reformatting
3910         * sigtramp-armvxw.c, sigtramp-ppcvxw.c: Update comments.
3912 2014-07-17  Robert Dewar  <dewar@adacore.com>
3914         * a-strunb-shared.ads, a-stwiun-shared.ads, a-stzunb-shared.ads,
3915         exp_ch7.adb, g-pehage.ads, g-socket.ads, gnat_ugn.texi, gnat_ugx.texi,
3916         scng.adb: Remove incorrect usage "allow to" and "allows to".
3918 2014-07-17  Robert Dewar  <dewar@adacore.com>
3920         * exp_dist.adb: Minor reformatting.
3922 2014-07-17  Bob Duff  <duff@adacore.com>
3924         * gnat_ugn.texi: Improve documentation of Unrestricted_Access.
3926 2014-07-17  Robert Dewar  <dewar@adacore.com>
3928         * sem_ch13.adb (Build_Invariant_Procedure): Add variable Nam
3929         (Add_Invariants): Set Nam to Name_Type_Invariant if from aspect.
3931 2014-07-17  Thomas Quinot  <quinot@adacore.com>
3933         * exp_pakd.adb (Create_Packed_Array_Type.Install_PAT): For a
3934         non-bit-packed array, propagate Reverse_Storage_Order to the
3935         packed array type.
3937 2014-07-17  Javier Miranda  <miranda@adacore.com>
3939         * exp_disp.adb: Fix comment.
3940         * exp_pakd.adb: Minor reformatting.
3942 2014-07-17  Robert Dewar  <dewar@adacore.com>
3944         * bindgen.adb (Gen_Elab_Calls): Skip reference to elab
3945         entity if none exists (Gen_Elab_Calls): Complain if clash with
3946         No_Multiple_Elaboration.
3947         * s-rident.ads, restrict.ads: Add restriction No_Multiple_Elaboration.
3948         * sem_util.adb (Build_Elaboration_Entity): Skip building entity
3949         if not needed.
3950         * gnat_rm.texi: Document restriction No_Multiple_Elaboration.
3951         * sem_ch4.adb: Minor comment updates.
3953 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
3955         * exp_ch9.adb (Buid_Protected_Subprogram_Call): Preserve type
3956         of function call for later use when shared passive objects
3957         are involved.
3959 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
3961         * par-ch13.adb (Get_Aspect_Specifications):
3962         Catch a case where the argument of SPARK aspect Refined_State
3963         is not properly parenthesized.
3965 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
3967         * exp_ch6.adb (Expand_Ctrl_Function_Call): Do not extend
3968         the lifetime of a reference to an Ada 2012 container element.
3969         (Is_Element_Reference): New routine.
3971 2014-07-17  Robert Dewar  <dewar@adacore.com>
3973         * ali.ads: Minor comment fix.
3974         * lib-writ.adb: Minor reformatting.
3976 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
3978         * sem_ch10.adb (Analyze_Proper_Body): When analyzing a subunit
3979         in ASIS mode, load another subunit only if it a subunit of the
3980         current one, not a sibling that has been reached through the
3981         analysis of an ancestor. This allows the construction of the
3982         ASIS tree for the subunit even when sibling subunits have errors.
3984 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
3986         * sem_ch3.adb (Analyze_Declarations): Remove the guard which
3987         prevents the analysis of various contracts when the associated
3988         construct is erroneous.
3989         * sem_util.adb (Save_SPARK_Mode_And_Set): Do not query the
3990         SPARK_Pragma of an illegal or a partially decorated construct.
3992 2014-07-17  Robert Dewar  <dewar@adacore.com>
3994         * s-imguns.ads: Minor reformatting.
3996 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
3998         * exp_ch7.adb (Build_Finalization_Master): Move all local
3999         variables to the proper code section. When looking for an existing
4000         finalization master, inspect the ultimate ancestor type of the
4001         full view.
4002         * sem_util.ads, sem_util.adb (Root_Type_Of_Full_View): New routine.
4004 2014-07-17  Robert Dewar  <dewar@adacore.com>
4006         * aspects.ads, aspects.adb: Add entries for aspect Annotate.
4007         * gnat_rm.texi: Document Entity argument for pragma Annotate and
4008         Annotate aspect.
4009         * sem_ch13.adb (Analyze_Aspect_Specification): Add processing
4010         for Annotate aspect.
4011         * sem_prag.adb (Analyze_Pragma, case Annotate): Allow optional
4012         Entity argument at end.
4013         * sinfo.ads (N_Aspect_Specification): Add note on Annotate aspect.
4015 2014-07-17  Tristan Gingold  <gingold@adacore.com>
4017         * s-imguns.ads: Fix minor typo.
4019 2014-07-17  Thomas Quinot  <quinot@adacore.com>
4021         * sprint.adb: Minor reformatting.
4023 2014-07-17  Robert Dewar  <dewar@adacore.com>
4025         * sprint.adb (Write_Itype): Print proper header for string
4026         literal subtype.
4028 2014-07-17  Steve Baird  <baird@adacore.com>
4030         * sinfo.ads, sem_scil.ads: Improve comments, minor reformatting.
4032 2014-07-17  Vincent Celier  <celier@adacore.com>
4034         * gnatbind.adb: Change in message "try ... for more information".
4036 2014-07-17  Robert Dewar  <dewar@adacore.com>
4038         * sprint.adb: Code clean up.
4040 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
4042         * exp_ch7.adb (Find_Last_Init): Relocate local variables to
4043         the relevant code section. Add new local constant Obj_Id. When
4044         a limited controlled object is initialized by a function call,
4045         the build-in-place object access function call acts as the last
4046         initialization statement.
4047         * exp_util.adb (Is_Object_Access_BIP_Func_Call): New routine.
4048         (Is_Secondary_Stack_BIP_Func_Call): Code reformatting.
4049         * exp_util.ads (Is_Object_Access_BIP_Func_Call): New routine.
4051 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
4053         * sem_ch8.adb (Analyze_Generic_Renaming): For generic subprograms,
4054         propagate intrinsic flag to renamed entity, to allow e.g. renaming
4055         of Unchecked_Conversion.
4056         * sem_ch3.adb (Analyze_Declarations): Do not analyze contracts
4057         if the declaration has errors.
4059 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
4061         * a-rbtgbk.adb: a-rbtgbk.adb (Generic_Insert_Post): Check whether
4062         container is busy before checking whether capacity allows for
4063         a further insertion. Insertion in a busy container that is full
4064         raises Program_Error rather than Capacity_Error. Previous to that
4065         patch which exception was raised varied among container types.
4067 2014-07-17  Robert Dewar  <dewar@adacore.com>
4069         * g-comlin.ads, g-comlin.adb: Minor clean up.
4071 2014-07-17  Bob Duff  <duff@adacore.com>
4073         * gnat_ugn.texi: Update gnatpp doc.
4075 2014-07-17  Robert Dewar  <dewar@adacore.com>
4077         * gnat_rm.texi: Document new restriction No_Long_Long_Integers.
4078         * exp_ch4.adb (Make_Array_Comparison_Op): Add note that we
4079         could do this by actually expanding a real generic.
4080         * a-tags.ads: Add comments about performance.
4081         * sprint.adb (Sprint_Node_Actual, case N_Object_Declaration):
4082         Print Etype of defining identifier, rather than the object
4083         definition. More information.
4085 2014-07-17  Thomas Quinot  <quinot@adacore.com>
4087         * exp_dist.adb: Minor documentation clarification.
4089 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
4091         * exp_util.adb (Is_Aliased): Revert previous change.
4093 2014-07-17  Vincent Celier  <celier@adacore.com>
4095         * g-comlin.adb (Try_Help): New procedure.
4096         (Getopt): Use new procedure Try_Help.
4097         * g-comlin.ads (Try_Help): New procedure.
4099 2014-07-17  Bob Duff  <duff@adacore.com>
4101         * gnat_ugn.texi: Minor update.
4103 2014-07-17  Robert Dewar  <dewar@adacore.com>
4105         * gnat_rm.texi: Improve documentation of Unrestricted_Access.
4106         * sinfo.ads: Document restriction on aggregates (must expand to
4107         assignments if one or more assignments needs expansion, e.g. for
4108         controlled types).
4109         * sem_ch13.adb: All warning messages regarding bit order should
4110         be info: messages.
4111         * gnat_ugn.texi: Minor correction of missing @ on @code
4113 2014-07-17  Robert Dewar  <dewar@adacore.com>
4115         * restrict.ads (Implementation_Restriction): Add No_Long_Long_Integer.
4116         * s-rident.ads (Partition_Boolean_Restrictions): Add
4117         No_Long_Long_Integer.
4118         * sem_ch3.adb (Modular_Type_Declaration): Size must be <=
4119         Long_Integer'Size if restriction No_Long_Long_Integer is active.
4120         (Signed_Integer_Type_Declaration): Do not allow Long_Long_Integer
4121         as the implicit base type for a signed integer type declaration
4122         if restriction No_Long_Long_Integer is active.
4123         * sem_util.ads, sem_util.adb (Set_Entity_With_Checks): Include check for
4124         No_Long_Long_Integer.
4126 2014-07-17  Robert Dewar  <dewar@adacore.com>
4128         * sem_ch3.adb, a-ztexio.ads, exp_imgv.adb, casing.adb, casing.ads,
4129         einfo.ads, checks.adb, sem_ch12.adb, a-textio.ads, freeze.adb,
4130         repinfo.adb, exp_ch6.adb, sem_ch4.adb, a-witeio.ads, sem_ch8.adb,
4131         sem_warn.adb, exp_aggr.adb, exp_dist.adb, par-tchk.adb, s-fatgen.adb,
4132         treepr.adb, lib-xref.adb: Remove the word kludge from ada sources.
4134 2014-07-17  Robert Dewar  <dewar@adacore.com>
4136         * debug.adb: Remove -gnatdQ.
4137         * exp_disp.adb: Remove -gnatdQ.
4138         * a-ztenio.ads, a-wtinio.ads, a-wtmoio.ads, a-ztcoau.ads, a-tiinio.ads,
4139         a-wtfiio.ads, a-timoio.ads, sem_ch12.adb, a-tifiio.ads, a-ztinio.ads,
4140         rtsfind.adb, rtsfind.ads, a-ztmoio.ads, a-wtdeio.ads, a-ztfiio.ads,
4141         a-tideio.ads, a-wtflio.ads, a-ztdeio.ads, sem_ch8.adb, a-tiflio.ads,
4142         sprint.adb, a-ztflio.ads, snames.ads-tmpl, a-wtenio.ads,
4143         a-tienio.ads: Rename Text_IO_Kludge to Text_IO_Special_Unit.
4145 2014-07-17  Robert Dewar  <dewar@adacore.com>
4147         * back_end.adb: Minor reformatting and comment additions.
4148         * checks.ads, checks.adb (Duplicated_Tag_Checks_Suppressed): New
4149         function.
4150         * exp_disp.adb (Make_DT): Use Duplicated_Tag_Checks_Suppressed.
4151         (Make_VM_TSD): Use Duplicated_Tag_Checks_Suppressed.
4152         * gnat_rm.texi: Document new check Duplicated_Tag_Checks_Suppressed.
4153         * gnat_ugn.texi: Additional documentation for Duplicated_Tag_Check.
4154         * snames.ads-tmpl (Duplicated_Tag_Checks_Suppressed): New check.
4155         * types.ads (Duplicated_Tag_Checks_Suppressed): New check.
4157 2014-07-17  Robert Dewar  <dewar@adacore.com>
4159         * gnat_rm.texi: Minor comment updates.
4161 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
4163         * sem_util.adb (Make_Explicit_Dereference): If the expression
4164         being dereferenced is a generalized indexing, reset the overloaded
4165         flag on the generalized indexing call, consistent with the
4166         resetting of the flag on the original indexed component.
4168 2014-07-17  Robert Dewar  <dewar@adacore.com>
4170         * gnat_ugn.texi: Document advise not to mix -gnatV? and
4171         optimization.
4173 2014-07-17  Robert Dewar  <dewar@adacore.com>
4175         * checks.adb (Insert_Valid_Check): Don't insist on a name
4176         for the prefix when we make calls to Force_Evaluation and
4177         Duplicate_Subexpr_No_Checks.
4178         * exp_util.adb (Is_Volatile_Reference): Handle all cases properly
4179         (Remove_Side_Effects): Handle all volatile references right
4180         (Side_Effect_Free): Volatile reference is never side effect free
4181         * sinfo.ads (N_Attribute_Reference): Add comments explaining
4182         that in the tree, the prefix can be a general expression.
4184 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
4186         * sem_ch6.adb (Analyze_Subprogram_Body_Contract,
4187         Analyze_Subprogram_Contract): Add comments on SPARK_Mode save/restore.
4188         * sem_ch7.adb (Analyze_Package_Body_Contract,
4189         Analyze_Package_Contract): Add comments on SPARK_Mode save/restore.
4191 2014-07-17  Robert Dewar  <dewar@adacore.com>
4193         * exp_ch7.ads, exp_util.ads: Document Insert_Action_After,
4194         Store_After_Actions_In_Scope.
4196 2014-07-17  Robert Dewar  <dewar@adacore.com>
4198         * sem_aux.ads: Minor comment addition.
4200 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
4202         * sem_res.adb (Make_Call_Into_Operator): If the call is already
4203         a rewriting of an operator node, there are no actuals to be
4204         propagated from original node to rewritten node when in ASIS mode.
4206 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
4208         * sem_ch6.adb (Analyze_Subprogram_Body_Contract,
4209         Analyze_Subprogram_Contract): Add new local variable Mode. Save
4210         and restore the SPARK mode of the related construct in a
4211         stack-like fashion.
4212         * sem_ch7.adb (Analyze_Package_Body_Contract,
4213         Analyze_Package_Contract): Add new local variable Mode. Save and
4214         restore the SPARK mode of the related construct in a stack-like fashion.
4215         * sem_util.adb Remove with and use clause for Opt.
4216         (Restore_SPARK_Mode): New routine.
4217         (Save_SPARK_Mode_And_Set): New routine.
4218         * sem_util.ads Add with and use clause for Opt.
4219         (Restore_SPARK_Mode): New routine.
4220         (Save_SPARK_Mode_And_Set): New routine.
4222 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
4224         * exp_util.adb (Is_Aliased): Transient objects
4225         within an expression with actions cannot be considered aliased.
4227 2014-07-17  Thomas Quinot  <quinot@adacore.com>
4229         * sem.ads (Scope_Stack_Entry): Reorganize storage of action lists;
4230         introduce a new list (cleanup actions) for each (transient) scope.
4231         * sinfo.ads, sinfo.adb (Cleanup_Actions): New attribute for
4232         N_Block_Statement
4233         * exp_ch7.ads (Store_Cleanup_Actions_In_Scope): New subprogram.
4234         * exp_ch7.adb (Store_Actions_In_Scope): New subprogram, common
4235         processing for Store_xxx_Actions_In_Scope.
4236         (Build_Cleanup_Statements): Allow for a list of additional
4237         cleanup statements to be passed by the caller.
4238         (Expand_Cleanup_Actions): Take custom cleanup actions associated
4239         with an N_Block_Statement into account.
4240         (Insert_Actions_In_Scope_Around): Account for Scope_Stack_Entry
4241         reorganization (refactoring only, no behaviour change).
4242         (Make_Transient_Block): Add assertion to ensure that the current
4243         scope is indeed a block (namely, the entity for the transient
4244         block being constructed syntactically, which has already been
4245         established as a scope).  If cleanup actions are present in the
4246         transient scope, transfer them now to the transient block.
4247         * exp_ch6.adb (Expand_Protected_Subprogram_Call): Freeze the
4248         called function while it is still present as the name in a call
4249         in the tree. This may not be the case later on if the call is
4250         rewritten into a transient block.
4251         * exp_smem.adb (Add_Shared_Var_Lock_Procs): The post-actions
4252         inserted after calling a protected operation on a shared passive
4253         protected must be performed in a block finalizer, not just
4254         inserted in the tree, so that they are executed even in case of
4255         a normal (RETURN) or abnormal (exception) transfer of control
4256         outside of the current scope.
4257         * exp_smem.ads (Add_Shared_Var_Lock_Procs): Update documentation
4258         * sem_ch8.adb, expander.adb, exp_ch11.adb: Adjust for
4259         Scope_Stack_Entry reorganization.
4261 2014-07-17  Thomas Quinot  <quinot@adacore.com>
4263         * exp_disp.adb (Make_DT, Make_VM_TSD): Do not omit Check_TSD
4264         call for types that do not have an explicit attribute definition
4265         clause for External_Tag, as their default tag may clash with an
4266         explicit tag defined for some other type.
4268 2014-07-17  Hristian Kirtchev  <kirtchev@adacore.com>
4270         * exp_util.adb (Is_Controlled_Function_Call): Recognize a
4271         controlled function call with multiple actual parameters that
4272         appears in Object.Operation form.
4274 2014-07-17  Thomas Quinot  <quinot@adacore.com>
4276         * einfo.ads, einfo.adb (Has_External_Tag_Rep_Clause): Remove
4277         entity flag.
4278         * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case
4279         External_Tag): No need to set entity flag.
4280         * sem_aux.ads, sem_aux.adb (Has_External_Tag_Rep_Clause):
4281         Reimplement correctly in terms of Has_Rep_Item.
4283 2014-07-17  Thomas Quinot  <quinot@adacore.com>
4285         * exp_ch7.adb (Establish_Transient_Scope.Find_Node_To_Be_Wrapped):
4286         Start examining the tree at the node passed to
4287         Establish_Transient_Scope (not its parent).
4288         * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
4289         The access type for the variable storing the reference to
4290         the call must be declared and frozen prior to establishing a
4291         transient scope.
4292         * exp_ch9.adb: Minor reformatting.
4294 2014-07-17  Pascal Obry  <obry@adacore.com>
4296         * s-os_lib.ads: Minor comment update.
4298 2014-07-17  Tristan Gingold  <gingold@adacore.com>
4300         * sysdep.c: Add ATTRIBUTE_UNUSED to avoid warnings.  Fix some
4301         indentation.
4302         * socket.c: Remove #warning to avoid warning.
4303         * expect.c: Indent some preprocessor directives to clarify
4304         nested if.  Do not use wait.h on PikeOS.  Add ATTRIBUTE_UNUSED
4305         to remove warnings.
4306         * env.c: Fix indentation.  Port to PikeOS.
4307         * gsocket.h: Port to PikeOS.  Remove #warning.
4308         * terminals.c: Port to PikeOS.  Fix indentation of the stubs.
4309         Add ATTRIBUTE_UNUSED to stubs arguments.  Fix return statement
4310         of stubbed __gnat_setup_parent_communication.
4311         * adaint.c: Port to PikeOS.  Reindent some preprocessor
4312         directives to clarify nested if.  Fix indentation.  Add missing
4313         ATTRIBUTE_UNUSED.
4315 2014-07-17  Robert Dewar  <dewar@adacore.com>
4317         * sem_attr.adb: Minor reformatting.
4319 2014-07-17  Robert Dewar  <dewar@adacore.com>
4321         * exp_ch7.adb, exp_ch7.ads, sinfo.ads: Minor reformatting.
4323 2014-07-17  Ed Schonberg  <schonberg@adacore.com>
4325         * sem_case.adb (Check_Choice_Set): If the case expression is the
4326         expression in a predicate, do not recheck coverage against itself,
4327         to prevent spurious errors.
4328         * sem_ch13.adb (Check_Aspect_At_End_Of_Declarations): Indicate that
4329         expression comes from an aspect specification, to prevent spurious
4330         errors when expression is a case expression in a predicate.
4332 2014-07-17  Pascal Obry  <obry@adacore.com>
4334         * adaint.c, adaint.h (__gnat_set_executable): Add mode parameter.
4335         * s-os_lib.ads, s-os_lib.adb (Set_Executable): Add Mode parameter.
4337 2014-07-17  Vincent Celier  <celier@adacore.com>
4339         * gnatchop.adb, make.adb, gnatbind.adb, clean.adb, gprep.adb,
4340         gnatxref.adb, gnatls.adb, gnatfind.adb, gnatname.adb: Do not output
4341         the usage for an erroneous invocation of a gnat tool.
4343 2014-07-16  Vincent Celier  <celier@adacore.com>
4345         * gnatls.adb: Get the target parameters only if -nostdinc was
4346         not specified.
4348 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
4350         * checks.adb (Insert_Valid_Check): If the expression is a packed
4351         component of a modular type of the right size the data is always
4352         valid. This os particularly useful if the component is part of
4353         a volatile variable.
4355 2014-07-16  Robert Dewar  <dewar@adacore.com>
4357         * gnat_rm.texi, sinfo.ads, freeze.adb, exp_aggr.adb: Minor reformatting
4359 2014-07-16  Thomas Quinot  <quinot@adacore.com>
4361         * exp_ch7.ads: Minor documentation fix.
4363 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
4365         * sem_ch3.adb (Find_Type_Name): Diagnose properly
4366         a private extension completion that is an interface definition
4367         with an interface list.
4369 2014-07-16  Arnaud Charlet  <charlet@adacore.com>
4371         * gnatls.adb (Gnatls): Code clean ups.
4373 2014-07-16  Thomas Quinot  <quinot@adacore.com>
4375         * sinfo.ads, sinfo.adb (N_Compound_Statement): New node kind.
4376         * sem.adb (Analyze): Handle N_Compound_Statement.
4377         * sprint.adb (Sprint_Node_Actual): Ditto.
4378         * sem_ch5.ads, sem_ch5.adb (Analyze_Compound_Statement): New
4379         procedure to handle N_Compound_Statement.
4380         * exp_aggr.adb (Collect_Initialization_Statements):
4381         Use a proper compound statement node, instead of a bogus
4382         expression-with-actions with a NULL statement as its expression,
4383         to wrap collected initialization statements.
4384         * freeze.ads, freeze.adb
4385         (Explode_Initialization_Compound_Statement): New public procedure,
4386         lifted from Freeze_Entity.
4387         (Freeze_Entity): When freezing
4388         an object with captured initialization statements and without
4389         delayed freezing, explode compount statement.
4390         * sem_ch4.adb (Analyze_Expression_With_Actions): Remove special
4391         case that used to handle bogus EWAs with NULL statement as
4392         the expression.
4393         * exp_ch13.adb (Expand_N_Freeze_Entity): For an object with
4394         delayed freezing and captured initialization statements, explode
4395         compound statement.
4397 2014-07-16  Gary Dismukes  <dismukes@adacore.com>
4399         * g-rewdat.adb, g-rewdat.ads: Minor reformatting.
4401 2014-07-16  Doug Rupp  <rupp@adacore.com>
4403         * s-interr-hwint.adb: Casing error on parameter.
4405 2014-07-16  Pascal Obry  <obry@adacore.com>
4407         * Makefile.rtl: Add g-rewdat.o dependencies in
4408         GNATRTL_NONTASKING_OBJS.
4410 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
4412         * sem_case.adb: Code clean up.
4414 2014-07-16  Vincent Celier  <celier@adacore.com>
4416         * make.adb: Do not read gnat.adc when gnatmake is invoked
4417         with -gnatA.
4419 2014-07-16  Pascal Obry  <obry@adacore.com>
4421         * gnat_rm.texi, impunit.adb, g-rewdat.adb, g-rewdat.ads: Initial
4422         implementation of GNAT.Rewrite_Data.
4424 2014-07-16  Vincent Celier  <celier@adacore.com>
4426         * gnatls.adb (Normalize): New function.
4427         (Gnatls): Get the target parameters. On targets other than VMS,
4428         normalize the path names in the source search path, the object search
4429         path and the project search path.
4431 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
4433         * sem_case.adb: Avoid self-checking of case expressions in
4434         dynamic predicates.
4436 2014-07-16  Robert Dewar  <dewar@adacore.com>
4438         * gnat_rm.texi: Document effect of Suppress_Initialization on tags and
4439         discriminants.
4441 2014-07-16  Eric Botcazou  <ebotcazou@adacore.com>
4443         * switch-b.adb (Scan_Binder_Switches): Add missing guard.
4445 2014-07-16  Ben Brosgol  <brosgol@adacore.com>
4447         * gnat_ugn.texi: Fix typo.
4449 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
4451         * exp_ch4.adb (Expand_N_Case_Expression): Do not expand case
4452         expression if it is the specification of a subtype predicate:
4453         it will be expanded when the return statement is analyzed, or
4454         when a static predicate is transformed into a static expression
4455         for evaluation by the front-end.
4456         * sem_ch13.adb (Get_RList): If the expression for a static
4457         predicate is a case expression, extract the alternatives of the
4458         branches with a True value to create the required statically
4459         evaluable expression.
4461 2014-07-16  Thomas Quinot  <quinot@adacore.com>
4463         * exp_prag.adb (Expand_Pragma_Check): Use the location of the
4464         expression, not the location of the aspect, for all generated
4465         code, so that in particular the call to raise_assert_failure
4466         gets the sloc of the associated condition.
4467         * exp_ch6.adb
4468         (Expand_Subprogram_Contract.Build_Postconditions_Procedure):
4469         Set an explicit End_Label on the handled sequence of statements
4470         for the _Postconditions procedure so that the implicit return
4471         statement does not erroneously get associated with code generated
4472         for the last condition in postconditions.
4474 2014-07-16  Thomas Quinot  <quinot@adacore.com>
4476         * ug_words: Fix name of VMS synonym for -gnatw.z (SIZE_ALIGNMENT,
4477         not SIZE_ALIGN) and -gnatw.Z (NOSIZE_ALIGNMENT, not NOSIZE_ALIGN).
4478         * vms_data.ads: Add missing spaces in VMS synonyms for -gnatw.z /
4479         -gnatw.Z.
4481 2014-07-16  Robert Dewar  <dewar@adacore.com>
4483         * sem_ch3.adb, sem_prag.adb, sem_util.adb, sem_res.adb, sem_ch13.adb:
4484         Minor code reorganization (use Is_Access_Type, not in Access_Kind).
4485         * exp_ch3.adb: Minor code reorganization, use Is_Access_Type,
4486         not in Access_Kind.
4487         * par-ch4.adb (At_Start_Of_Attribute): New function
4488         (P_Simple_Expression): Better msg for bad attribute prefix.
4489         * scans.ads: Minor reformatting.
4491 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
4493         * sem_attr.adb (Resolve_Attribute, case 'Update): If choice is a
4494         static constant, check that in belongs to the corresponding index
4495         subtype, to produce the proer warning when expansion is disabled.
4497 2014-07-16  Robert Dewar  <dewar@adacore.com>
4499         * freeze.adb (Freeze_Entity): Warn on incompatible size/alignment.
4500         * gnat_ugn.texi: Document -gnatw.z and -gnatw.Z.
4501         * ug_words: VMS synonyms (WARNINGS=[NO]SIZE_ALIGN) for -gnatw.z/-gnatw.Z
4502         * usage.adb: Add lines for -gnatw.z/-gnatw.Z.
4503         * vms_data.ads: VMS synonyms (WARNINGS=[NO]SIZE_ALIGN) for
4504         -gnatw.z/-gnatw.Z
4505         * warnsw.adb: Set Warn_On_Size_Alignment appropriately.
4506         * warnsw.ads (Warn_On_Size_Alignment): New flag Minor
4507         reformatting.
4509 2014-07-16  Hristian Kirtchev  <kirtchev@adacore.com>
4511         * exp_ch7.adb (Process_Declarations): Reinstate the check on
4512         a hook object to ensure that the related transient declaration
4513         is finalizable.
4514         * exp_util.adb (Is_Aliased): Do not consider expresison with
4515         actions as a special context.
4516         (Requires_Cleanup_Actions): Reinstate the check on a hook object to
4517         ensure that the related transient declaration is finalizable.
4519 2014-07-16  Robert Dewar  <dewar@adacore.com>
4521         * checks.ads, checks.adb (Allocation_Checks_Suppressed): New function.
4522         * snames.ads-tmpl: Add Allocation_Check to list of check names.
4523         * types.ads: Add Allocation_Check to list of check names.
4525 2014-07-16  Thomas Quinot  <quinot@adacore.com>
4527         * sem_util.adb (Enter_Name): replace bogus test for presence of
4528         Corresponding_Remote_Type with correct test on Ekind.
4529         * sem_res.adb (Valid_Conversion): ditto; also clarify validity
4530         of calls to Corresponding_ Remote_Type (documentation fix).
4532 2014-07-16  Robert Dewar  <dewar@adacore.com>
4534         * gnat_rm.texi: Document illegal case of Unrestricted_Access.
4535         * sem_attr.adb (Analyze_Access_Attribute): Set_Non_Aliased_Prefix
4536         where it applies.
4537         (Resolve_Attribute, case Access): Flag illegal Unrestricted_Access use.
4538         * sinfo.ads, sinfo.adb (Non_Aliased_Prefix): New flag.
4540 2014-07-16  Robert Dewar  <dewar@adacore.com>
4542         * gnat_ugn.texi: Document binder switch -Ra.
4543         * gnatbind.adb (List_Closure_Display): Implement -Ra switch
4544         (List_Closure_All).
4545         * opt.ads (List_Closure_All): New switch.
4546         * switch-b.adb (Scan_Binder_Switches): Recognize -Ra to set
4547         List_Closure_All.
4549 2014-07-16  Ben Brosgol  <brosgol@adacore.com>
4551         * gnat_rm.texi: Minor edits, to make case consistent in names
4552         of types and fields.
4554 2014-07-16  Robert Dewar  <dewar@adacore.com>
4556         * gnat_rm.texi: Document erroneous mixing of thin pointers and
4557         unrestricted access
4558         * gnat_ugn.texi: Add note on size of access types about thin
4559         pointers and the use of attribute Unrestricted_Access.
4561 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
4563         * a-cbdlli.ads, a-cbdlli.adb, a-cbhama.ads, a-cbhama.adb,
4564         * a-cbhase.ads, a-cbhase.adb, a-cborma.ads, a-cborma.adb,
4565         * a-cborse.ads, a-cborse.adb, a-cobove.ads a-cobove.adb: Add Control
4566         machinery to detect tampering on bounded vectors.
4568 2014-07-16  Robert Dewar  <dewar@adacore.com>
4570         * gnat_rm.texi: Document that leading/trailing asterisks are
4571         now implied for the pattern match string for pragma Warnings
4572         and Warning_As_Error.
4573         * sem_prag.adb (Acquire_Warning_Match_String): New procedure.
4574         (Analyze_Pragma, case Warning_As_Error): Call
4575         Acquire_Warning_Match_String.
4576         (Analyze_Pragma, case Warnings): Call Acquire_Warning_Match_String.
4578 2014-07-16  Bob Duff  <duff@adacore.com>
4580         * gnat_ugn.texi: Document need for project file
4581         for --incremental switch for gnat2xml.
4583 2014-07-16  Robert Dewar  <dewar@adacore.com>
4585         * gnat_rm.texi: Fix example of non-packable components in packed
4586         records section.
4588 2014-07-16  Robert Dewar  <dewar@adacore.com>
4590         * s-tpoben.adb, s-tasren.adb, s-interr.adb, s-interr-hwint.adb,
4591         s-shasto.adb, s-interr-vms.adb, s-interr-sigaction.adb: Avoid use of
4592         upper case in exception messages.
4594 2014-07-16  Robert Dewar  <dewar@adacore.com>
4596         * snames.ads-tmpl, sem_attr.adb, exp_attr.adb: Same_Storage attribute
4597         is renamed Has_Same_Storage.
4598         * gnat_rm.texi: Document missing SPARK pragmas and attributes.
4599         * sem_prag.adb: Minor comment fix (use LOCAL_NAME in syntax
4600         descriptions).
4602 2014-07-16  Robert Dewar  <dewar@adacore.com>
4604         * exp_util.adb, sem_attr.adb, exp_ch4.adb, a-cohase.ads,
4605         a-coinho-shared.adb, a-coinho-shared.ads: Minor reformatting.
4607 2014-07-16  Robert Dewar  <dewar@adacore.com>
4609         * gnat_ugn.texi: Add note that integrated
4610         preprocessing cannot be applied to configuration pragma files.
4612 2014-07-16  Yannick Moy  <moy@adacore.com>
4614         * sem_attr.adb (Analyze_Attribute/cases Pred
4615         and Succ): Always enable range check on fixed-point types if
4616         not suppressed for the type.
4618 2014-07-16  Hristian Kirtchev  <kirtchev@adacore.com>
4620         * sem_util.adb (State_Has_Enabled_Property):
4621         Account for an external property denoted by an others choice.
4623 2014-07-16  Hristian Kirtchev  <kirtchev@adacore.com>
4625         * exp_ch4.ads, exp_ch4.adb (Find_Hook_Context): Relocated to Exp_Util.
4626         * exp_ch7.adb (Process_Declarations): There is no need to check
4627         that a transient object being hooked is controlled as it would
4628         not have been hooked in the first place.
4629         * exp_ch9.adb Remove with and use clause for Exp_Ch4.
4630         * exp_util.adb (Find_Hook_Context): Relocated from Exp_Ch4.
4631         (Is_Aliased): A renaming of a transient controlled object is
4632         not considered aliasing when it occurs within an expression
4633         with actions.
4634         (Requires_Cleanup_Actions): There is no need to
4635         check that a transient object being hooked is controlled as it
4636         would not have been hooked in the first place.
4637         * exp_util.ads (Find_Hook_Context): Relocated from Exp_Ch4.
4639 2014-07-16  Hristian Kirtchev  <kirtchev@adacore.com>
4641         * sem_ch13.adb (Insert_After_SPARK_Mode): Moved to
4642         the outer level of routine Analyze_Aspect_Specifications. Ensure
4643         that the corresponding pragmas of aspects Initial_Condition and
4644         Initializes are inserted after pragma SPARK_Mode.
4646 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
4648         * sem_attr.adb (Analyze_Attribute, case 'Update): Handle
4649         properly a choice list with more than one choice, where each
4650         is an aggregate denoting a sequence of array indices for a
4651         multidimentional array. For SPARK use.
4653 2014-07-16  Vadim Godunko  <godunko@adacore.com>
4655         * a-coinho-shared.adb (Adjust): Create
4656         copy of internal shared object and element when source container
4657         is locked.
4658         (Copy): Likewise.
4659         (Query_Element): Likewise.
4660         (Update_Element): Likewise.
4661         (Constant_Reference): Likewise. Raise Constraint_Error on attempt
4662         to get reference for empty holder.
4663         (Reference): Likewise.
4665 2014-07-16  Thomas Quinot  <quinot@adacore.com>
4667         * exp_ch4.adb (Find_Hook_Context): New subprogram, extracted
4668         from Process_Transient_Oject.
4669         * exp_ch4.ads: Ditto.
4670         * exp_ch9.adb (Build_Class_Wide_Master): Insert the _master
4671         declaration as an action on the topmost enclosing expression,
4672         not on a possibly conditional subexpreession.
4674 2014-07-16  Vadim Godunko  <godunko@adacore.com>
4676         * a-coinho.adb, a-coinho-shared.adb, a-coinho.ads, a-coinho-shared.ads:
4677         Fix parameter mode of Update_Element.
4679 2014-07-16  Robert Dewar  <dewar@adacore.com>
4681         * a-coinho.adb, a-coinho-shared.adb, a-coinho-shared.ads: Minor
4682         reformatting.
4684 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
4686         * a-cohase.ads: Type Iterator must be controlled, so that the
4687         tampering bit is properly set through an iteration.
4688         * a-cohase.adb: Add Finalize operation for type Iterator.
4690 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
4692         * a-coinho-shared.adb, a-coinho-shared.ads: Proper structures for
4693         tampering checks.
4695 2014-07-16  Ed Schonberg  <schonberg@adacore.com>
4697         * a-coinho-shared.adb: Fix spurious accessibility check.
4699 2014-06-15  Jan Hubicka  <hubicka@ucw.cz>
4701         * gcc-interface/utils.c (process_attributes): Use set_decl_tls_model.
4703 2014-06-14  Bernd Edlinger  <bernd.edlinger@hotmail.de>
4705         PR ada/61505
4706         * gnat_rm.texi: Fix errors with makeinfo 5.1.
4708 2014-06-14  Arnaud Charlet  <charlet@adacore.com>
4710         PR ada/61505
4711         * gnat_rm.texi: Attempt to fix error with makeinfo 5.1.
4713 2014-06-13  Yannick Moy  <moy@adacore.com>
4715         * exp_attr.adb: Fix typo in comment.
4716         * gnat1drv.adb (Adjust_Global_Switches): Force float overflow
4717         checking in GNATprove_Mode.
4719 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
4721         * a-coinho-shared.adb, a-coinho-shared.ads: Update shared version.
4723 2014-06-13  Robert Dewar  <dewar@adacore.com>
4725         * sem_ch3.adb, sem_ch9.adb, a-coinho.adb, a-coinho.ads: Minor
4726         reformatting.
4728 2014-06-13  Hristian Kirtchev  <kirtchev@adacore.com>
4730         * sem_prag.adb (Analyze_Pragma): Add local
4731         variable Missing_Parentheses. Emit an error when a state
4732         declaration with options appears without parentheses. Add a
4733         guard to prevent a bogus error when a state declaration may be
4734         interpreted as an option if a previous declaration with options
4735         was not parenthesized.
4737 2014-06-13  Robert Dewar  <dewar@adacore.com>
4739         * checks.adb: Validate_Alignment_Check_Warnings: New procedure
4740         (Apply_Address_Clause_Check): Make Aligment_Warnings table entry.
4741         * checks.ads (Alignment_Warnings_Record): New type.
4742         (Alignment_Warnings): New table
4743         (Validate_Alignment_Check_Warnings): New procedure.
4744         * errout.adb (Delete_Warning_And_Continuations): New procedure
4745         (Error_Msg_Internal): Set Warning_Msg (Delete_Warning): Handle
4746         Warnings_Treated_As_Errors (Finalize): Minor reformatting
4747         * errout.ads (Warning_Msg): New variable
4748         (Delete_Warning_And_Continuations): New procedure
4749         * erroutc.adb (Delete_Msg): Handle Warnings_Treated_As_Errors count.
4750         * gnat1drv.adb (Post_Compilation_Validation_Checks): New procedure.
4752 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
4754         * a-coinho.adb, a-coinho.ads: Add Reference machinery.
4756 2014-06-13  Hristian Kirtchev  <kirtchev@adacore.com>
4758         * errout.adb (SPARK_Msg_N): New routine.
4759         (SPARK_Msg_NE): New routine.
4760         * errout.ads Add a section on SPARK-related error routines.
4761         (SPARK_Msg_N): New routine.
4762         (SPARK_Msg_NE): New routine.
4763         * sem_ch13.adb (Analyze_Aspect_Specifications): Ensure that
4764         pragma Abstract_State is always inserted after SPARK_Mode.
4765         (Insert_After_SPARK_Mode): New routine.
4766         * sem_prag.adb (Analyze_Abstract_State,
4767         Analyze_Constituent, Analyze_External_Property,
4768         Analyze_External_Property_In_Decl_Part, Analyze_Global_Item,
4769         Analyze_Global_List, Analyze_Initialization_Item,
4770         Analyze_Initialization_Item_With_Inputs, Analyze_Input_Item,
4771         Analyze_Input_List, Analyze_Input_Output, Analyze_Part_Of,
4772         Analyze_Pragma, Analyze_Refined_Depends_In_Decl_Part,
4773         Analyze_Refined_Global_In_Decl_Part,
4774         Analyze_Refined_State_In_Decl_Part, Analyze_Refinement_Clause,
4775         Check_Aspect_Specification_Order, Check_Constituent_Usage,
4776         Check_Declaration_Order, Check_Dependency_Clause,
4777         Check_Duplicate_Mode, Check_Duplicate_Option,
4778         Check_Duplicate_Property, Check_External_Properties,
4779         Check_External_Property, Check_Function_Return,
4780         Check_Matching_Constituent, Check_Matching_State,
4781         Check_Mode_Restriction_In_Enclosing_Context,
4782         Check_Mode_Restriction_In_Function, Check_Refined_Global_Item,
4783         Check_State_And_Constituent_Use, Create_Or_Modify_Clause,
4784         Has_Extra_Parentheses, Inconsistent_Mode_Error,
4785         Match_Error, Propagate_Part_Of, Report_Extra_Clauses,
4786         Report_Extra_Constituents_In_List, Report_Extra_Inputs,
4787         Report_Unrefined_States, Report_Unused_Constituents,
4788         Report_Unused_States, Role_Error, Usage_Error):
4789         Convert Error_Msg_XXX calls to SPARK_Msg_XXX calls
4790         to report semantic errors only when SPARK_Mode is on.
4791         (Analyze_Depends_In_Decl_Part): Do not check the syntax of
4792         pragma Depends explicitly, this is now done by the analysis.
4793         (Analyze_Global_In_Decl_List): Do not check the syntax of
4794         pragma Global explicitly, this is now done by the analysis.
4795         (Analyze_Initializes_In_Decl_Part): Do not check the syntax of
4796         pragma Initializes explicitly, this is now done by the analysis.
4797         (Analyze_Part_Of): Do not check the syntax of the encapsulating
4798         state, this is now done by the analysis.
4799         (Analyze_Pragma): Do
4800         not check the syntax of a state declaration, this is now done
4801         by the analysis.
4802         (Analyze_Refined_Depends_In_Decl_Part): Do not
4803         check the syntax of pragma Refined_Depends explicitly, this is now
4804         done by the analysis.
4805         (Analyze_Refined_Global_In_Decl_Part): Do
4806         not check the syntax of pragma Refined_Global explicitly, this is
4807         now done by the analysis.
4808         (Analyze_Refined_State_In_Decl_Part):
4809         Do not check the syntax of pragma Refined_State explicitly, this
4810         is now done by the analysis.
4811         (Check_Dependence_List_Syntax): Removed.
4812         (Check_Global_List_Syntax): Removed.
4813         (Check_Initialization_List_Syntax): Removed.
4814         (Check_Item_Syntax): Removed.
4815         (Check_Missing_Part_Of): Do not consider items from an instance.
4816         (Check_Refinement_List_Syntax): Removed.
4817         (Check_State_Declaration_Syntax): Removed.
4818         (Collect_Global_List): Do not raise Program_Error when the input is
4819         malformed.
4820         (Process_Global_List): Do not raise Program_Error when the input
4821         is malformed.
4822         * sem_ch13.adb: Minor reformatting.
4824 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
4826         * sem_ch3.adb (Find_Type_Name): Diagnose a private type completion
4827         that is an interface definition with an interface list.
4828         (Process_Full_View): Move error message on missmatched interfaces
4829         between views to the declaration of full view, for clarity.
4830         * sem_ch9.adb (Check_Interfaces): Move error message to full view,
4831         for clarity.
4833 2014-06-13  Robert Dewar  <dewar@adacore.com>
4835         * exp_attr.adb (Expand_N_Attribute_Reference, case Pred/Succ): Change
4836         reason to Overflow.
4838 2014-06-13  Robert Dewar  <dewar@adacore.com>
4840         * makeutl.adb: Minor reformatting.
4842 2014-06-13  Gail Schenker  <schenker@adacore.com>
4844         * debug.adb, sem_eval.adb (Why_Not_Static): Remove temporary code and
4845         associated flag (d.z), no longer needed.
4847 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
4849         * sem_ch13.adb (Analyze_Aspect_Specifications): For Import and
4850         Export aspects, do not check whether a corresponding Convention
4851         aspect has been specified. Convention is optional in Ada2012,
4852         and defaults to Convention_Ada.
4854 2014-06-13  Eric Botcazou  <ebotcazou@adacore.com>
4856         * checks.adb (Apply_Address_Clause_Check): Only issue the new
4857         warning if the propagation warning is issued.
4859 2014-06-13  Thomas Quinot  <quinot@adacore.com>
4861         * exp_ch4.adb: Minor reformatting.
4863 2014-06-13  Robert Dewar  <dewar@adacore.com>
4865         * exp_attr.adb (Expand_N_Attribute_Reference, case Pred):
4866         Handle float range check case (Expand_N_Attribute_Reference,
4867         case Succ): Handle float range check case.
4868         * sem_attr.adb (Analyze_Attribute, case Pred/Succ): Handle float
4869         range check case.
4871 2014-06-13  Vincent Celier  <celier@adacore.com>
4873         * makeutl.ads (Compute_Builder_Switches): Change name of
4874         parameter Root_Environment to Env.
4875         * prj-conf.adb (Check_Switches): Call Locate_Runtime with the
4876         Env parameter of procedure Get_Or_Create_Configuration_File.
4877         (Locate_Runtime): Call Find_Rts_In_Path with the Project_Path
4878         of new parameter Env.
4879         * prj-conf.ads (Locate_Runtime): New parameter Env of type
4880         Prj.Tree.Environment.
4882 2014-06-13  Robert Dewar  <dewar@adacore.com>
4884         * gnat_rm.texi: Minor comment clarification for Check_Float_Overflow.
4886 2014-06-13  Robert Dewar  <dewar@adacore.com>
4888         * exp_attr.adb, exp_ch9.adb, lib-writ.adb, g-comlin.adb: Minor
4889         reformatting.
4890         * sem_attr.adb: Minor code reformatting and simplification.
4891         * checks.adb: Fix minor typo.
4893 2014-06-13  Emmanuel Briot  <briot@adacore.com>
4895         * g-comlin.adb (Get_Argument): fix expansion
4896         of command line arguments (e.g. "*.adb") when using a custom
4897         parser. The parser was not passed to the recursive call, and
4898         thus we were trying to do the expansion on the default command
4899         line parser.
4901 2014-06-13  Thomas Quinot  <quinot@adacore.com>
4903         * exp_ch9.adb: Minor reformatting.
4905 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
4907         * exp_attr.adb (Expand_N_Attribute_Reference, case 'Old):
4908         To determine whether the attribute should be expanded, examine
4909         whether the enclosing postcondition pragma is to be checked,
4910         rather than using the internal flag Assertions_Enabled.
4912 2014-06-13  Ben Brosgol  <brosgol@adacore.com>
4914         * gnat_rm.texi: Minor fixes.
4915         * gnat_ugn.texi: Added a missing "@itemize".
4917 2014-06-13  Robert Dewar  <dewar@adacore.com>
4919         * debug.adb: Remove -gnatd.1 flag documentation.
4920         * layout.adb (Layout_Type): Remove special handling of size
4921         for anonymous access type.
4922         * sem_ch3.adb (Replace_Type): Remove special handling of size
4923         for anonymous access type.
4925 2014-06-13  Robert Dewar  <dewar@adacore.com>
4927         * debug.adb: Document debug flag -gnatd.1.
4928         * layout.adb (Layout_Type): Size change for anonymous access
4929         types under -gnatd.1.
4930         * sem_ch3.adb (Replace_Type): Size change for anonymous access
4931         types under -gnatd.1.
4933 2014-06-13  Robert Dewar  <dewar@adacore.com>
4935         * layout.adb (Layout_Type): Anonymous access types designating
4936         unconstrained arrays are always thin pointers.
4937         * sem_ch3.adb (Replace_Type): Anonymous access types designating
4938         unconstrained arrays are always thin pointers.
4940 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
4942         * sem_attr.adb (Analyze_Attribute): Use Check_Parameterless_Call
4943         to resolve the prefix of an attribute that is an entity name
4944         and may be a parameterless call.  Minor code reorganization.
4946 2014-06-13  Robert Dewar  <dewar@adacore.com>
4948         * lib.ads, lib.adb, lib-writ.adb, lib-load.adb (Is_Compiler_Unit):
4949         Removed.
4950         * opt.ads (Compiler_Unit): New flag.
4951         * par-ch5.adb (Test_Statement_Required): Call Check_Compiler_Unit
4952         for null statement sequence (not allowed in compiler unit).
4953         * par-prag.adb (Prag): Handle Compiler_Unit[_Warning] during
4954         parsing.
4955         * restrict.ads, restrict.adb (Check_Compiler_Unit): New version and new
4956         calling sequence.
4957         * sem_ch11.adb, sem_ch3.adb, sem_ch4.adb: New calling sequence for
4958         Check_Compiler_Unit.
4959         * sem_ch6.adb (Analyze_Extended_Return_Statement): Call
4960         Check_Compiler_Unit (this construct is not allowed in compiler
4961         units).
4962         * sem_prag.adb (Analyze_Pragma, case Compiler_Unit[_Warning]):
4963         Set Opt.Compiler_Unit.
4965 2014-06-13  Geert Bosch  <bosch@adacore.com>
4967         * gnat_rm.texi, s-tasinf-solaris.ads, sem_prag.adb, gnat_ugn.texi,
4968         s-tasinf-mingw.ads, s-tasinf.ads, s-tasinf-linux.ads,
4969         s-tasinf-vxworks.ads: Make Task_Info pragma and package obsolescent.
4971 2014-06-13  Robert Dewar  <dewar@adacore.com>
4973         * s-tasini.adb, s-tarest.adb, s-taprob.adb: Minor reformatting.
4975 2014-06-13  Hristian Kirtchev  <kirtchev@adacore.com>
4977         * freeze.adb (Freeze_Entity): Remove the check concerning volatile
4978         types in SPARK as it is poorly placed and poorly formulated. The
4979         check was flagging ALL volatile entities as illegal in SPARK.
4980         * sem_prag.adb (Process_Atomic_Shared_Volatile): Flag volatile
4981         types as illegal in SPARK.
4983 2014-06-13  Robert Dewar  <dewar@adacore.com>
4985         * sem_cat.adb: Minor reformatting.
4987 2014-06-13  Yannick Moy  <moy@adacore.com>
4989         * sem_prag.adb (Analyze_Pragma/Post_Class): Fix typo.
4991 2014-06-13  Arnaud Charlet  <charlet@adacore.com>
4993         * gnat_rm.texi: Add detail on SPARK_05 restriction.
4995 2014-06-13  Bob Duff  <duff@adacore.com>
4997         * s-solita.adb (Get_Sec_Stack_Addr, Init_Tasking_Soft_Links):
4998         Add assertions requiring the secondary stack to be initialized.
4999         * s-solita.ads (Init_Tasking_Soft_Links): Comment.
5000         * s-taprob.adb, s-tarest.adb, s-tasini.adb (elab code): Make sure the
5001         secondary stack is initialized before calling Init_Tasking_Soft_Links,
5002         by adding pragmas Elaborate_Body.
5004 2014-06-13  Thomas Quinot  <quinot@adacore.com>
5006         * sem_ch13.adb (Analyze_Stream_TSS_Definition): Remove temporary
5007         kludge disabling new legality check.
5009 2014-06-13  Hristian Kirtchev  <kirtchev@adacore.com>
5011         * freeze.adb (Freeze_Record_Type): Remove checks related to SPARK
5012         volatile types.
5013         (Freeze_Type): Volatile types are now illegal in SPARK.
5015 2014-06-13  Robert Dewar  <dewar@adacore.com>
5017         * aspects.ads, aspects.adb: Add aspect Thread_Local_Storage.
5018         * gnat_rm.texi: Document aspect Thread_Local_Storage.
5020 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
5022         * sem_cat.adb (Validate_Static_Object_Name): A constant whose
5023         value is a temporary that renames an aggregate is legal in a
5024         preelaborated unit. Illegalities, if any will be detected in
5025         the aggregate components.
5027 2014-06-13  Ed Schonberg  <schonberg@adacore.com>
5029         * einfo.ads: Minor reformatting an comment expansion.
5031 2014-06-13  Robert Dewar  <dewar@adacore.com>
5033         * back_end.ads, back_end.adb: Make_Id, Make_SC, Set_RND are moved to
5034         Tbuild.
5035         * tbuild.ads, tbuild.adb: Make_Id, Make_SC, Set_RND are moved here from
5036         Back_End.
5037         * gnat1drv.adb: Make_Id, Make_SC, Set_RND are moved to Tbuild
5038         * sem_warn.adb: Minor reformatting.
5040 2014-06-13  Doug Rupp  <rupp@adacore.com>
5042         * adaint.c (__gnat_open_new_temp) [VMS]: Open binary
5043         files with rfm=udf.
5045 2014-06-13  Yannick Moy  <moy@adacore.com>
5047         * sem_warn.adb (Check_Unset_References): Take
5048         case of Refined_Post into account in Within_Postcondition check.
5050 2014-06-13  Hristian Kirtchev  <kirtchev@adacore.com>
5052         * freeze.adb (Freeze_Record_Type): Volatile types are not allowed in
5053         SPARK.
5055 2014-06-13  Yannick Moy  <moy@adacore.com>
5057         * sem_ch13.adb (Analyze_Aspect_Specifications/Aspect_Import,
5058         Aspect_Export): Consider that variables may be set outside the program.
5060 2014-06-13  Robert Dewar  <dewar@adacore.com>
5062         * back_end.adb (Make_Id): New function.
5063         (Make_SC): New function.
5064         (Set_RND): New procedure.
5065         * back_end.ads (Make_Id): New function.
5066         (Make_SC): New function.
5067         (Set_RND): New procedure.
5068         * einfo.ads: Minor comment updates.
5069         * frontend.adb: Move Atree.Initialize call to Gnat1drv.
5070         * gnat1drv.adb (Gnat1drv): New calling sequence for
5071         Get_Target_Parameters.
5072         (Gnat1drv): Move Atree.Initialize here from Frontend.
5073         * targparm.adb (Get_Target_Parameters): New calling
5074         sequence (Get_Target_Parameters): Handle pragma Restriction
5075         (No_Dependence,..)
5076         * targparm.ads (Get_Target_Parameters): New calling sequence.
5078 2014-06-13  Gary Dismukes  <dismukes@adacore.com>
5080         * sem_prag.adb (Process_Import_Or_Interface): Exit the homonym
5081         loop if the pragma does not come from source, so that an implicit
5082         pragma Import only applies to the first declaration, avoiding
5083         possible conflicts with earlier explicit and implicit declarations
5084         due to multiple Provide_Shift_Operators pragmas.
5085         (Set_Imported): Remove previous fix that bypassed pragma duplication
5086         error.
5087         * gnat_rm.texi: Change 'equivalent' to 'similar' in description
5088         of Provide_Shift_Operators.
5090 2014-06-12  Jan Hubicka  <hubicka@ucw.cz>
5092         * gcc-interface/utils.c (process_attributes) <ATTR_LINK_SECTION>: Pass
5093         string pointer directly to set_decl_section_name.
5095 2014-06-11  Robert Dewar  <dewar@adacore.com>
5097         * sem_ch13.adb: Minor reformatting.
5099 2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>
5101         * sem_prag.adb (Check_Clause_Syntax): Add new
5102         local variable Outputs. Account for the case where multiple
5103         output items appear as an aggregate.
5105 2014-06-11  Robert Dewar  <dewar@adacore.com>
5107         * sem_warn.adb (Output_Obsolescent_Entity_Warnings): Tag warning
5108         with ?j? not ??.
5110 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
5112         * einfo.ads: Minor reformatting.
5114 2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>
5116         * a-cbdlli.adb, a-cdlili.adb, a-cidlli.adb, a-crdlli.adb (Insert): Add
5117         new variable First_Node. Update the position after all insertions have
5118         taken place to First_Node.
5120 2014-06-11  Robert Dewar  <dewar@adacore.com>
5122         * debug.adb: Remove debug flag -gnatd.1, no longer needed.
5123         * layout.adb (Layout_Type): Remove test of -gnatd.1.
5125 2014-06-11  Robert Dewar  <dewar@adacore.com>
5127         * sem_ch13.adb: Minor reformatting.
5129 2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>
5131         * sem_prag.adb (Check_Clause_Syntax): Add new
5132         local variable Outputs. Account for the case where multiple
5133         output items appear as an aggregate.
5135 2014-06-11  Robert Dewar  <dewar@adacore.com>
5137         * sem_warn.adb (Output_Obsolescent_Entity_Warnings): Tag warning
5138         with ?j? not ??.
5140 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
5142         * einfo.ads: Minor reformatting.
5144 2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>
5146         * a-cbdlli.adb, a-cdlili.adb, a-cidlli.adb, a-crdlli.adb (Insert): Add
5147         new variable First_Node. Update the position after all insertions have
5148         taken place to First_Node.
5150 2014-06-11  Robert Dewar  <dewar@adacore.com>
5152         * debug.adb: Remove debug flag -gnatd.1, no longer needed.
5153         * layout.adb (Layout_Type): Remove test of -gnatd.1.
5155 2014-06-11  Thomas Quinot  <quinot@adacore.com>
5157         * freeze.ads: Minor reformatting.
5158         * checks.adb (Determine_Range): Do not attempt to determine
5159         the range of a deferred constant whose full view has not been
5160         seen yet.
5161         * sem_res.adb (Resolve): Remove undesirable guard against
5162         resolving expressions from expression functions.
5164 2014-06-11  Robert Dewar  <dewar@adacore.com>
5166         * debug.adb (Debug_Flag_Dot_1): Set to enable fix for anonymous
5167         access types.
5168         * layout.adb (Layout_Type): Make anonymous access types for
5169         subprogram formal types and return types always thin. For now
5170         only enabled if -gnatd.1 set.
5172 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
5174         * sem_ch13.adb (Analyze_Stream_TSS_Definition): Apply legality
5175         rule for stream attributes of interface types (RM 13.13.2 (38/3)):
5176         subprogram must be a null procedure.
5178 2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>
5180         * sem_prag.adb (Analyze_Input_Item): Allow formal
5181         parameters to appear as input_items in an initialization_list
5182         of pragma Initializes. Encapsulation now applies to states and
5183         variables only (as it should). Add RM references to key errors.
5184         * sem_prag.adb (Set_Imported): Suppress errors
5185         about preceding Imports when the pragma does not come from source,
5186         which can happen through use of pragma Provide_Shift_Operators.
5188 2014-06-11  Thomas Quinot  <quinot@adacore.com>
5190         * sem_ch3.adb: Minor reformatting.
5191         * einfo.ads (Full_View): Minor comment update.
5193 2014-06-11  Robert Dewar  <dewar@adacore.com>
5195         * einfo.adb (Is_Independent): New flag.
5196         * einfo.ads (Is_Independent): New flag.
5197         (Has_Independent_Components): Clean up and fix comments.
5198         * sem_prag.adb (Fix_Error): Deal with changing argument
5199         [of] to entity [for].
5200         (Analyze_Pragma, case Independent): Set Is_Independent flag
5201         (Analyze_Pragma, case Independent_Components): Set Is_Independent flag
5202         in all components of specified record.
5204 2014-06-11  Thomas Quinot  <quinot@adacore.com>
5206         * sem_ch12.adb (Analyze_Formal_Decimal_Fixed_Point_Type):
5207         Set proper Etype on bounds of dummy type created for analysis
5208         of the generic.
5210 2014-06-11  Robert Dewar  <dewar@adacore.com>
5212         * debug.adb: Minor comment fix (add missing section of dot
5213         numeric flags).
5215 2014-06-11  Robert Dewar  <dewar@adacore.com>
5217         * gnat_rm.texi, switch-c.adb, sem_prag.adb, a-tgdico.ads, par-prag.adb,
5218         opt.ads, a-finali.ads, snames.ads-tmpl: Remove all traces of
5219         pragma/aspects Pure_05 Pure_12 Preelaborate_05.
5220         * errout.adb (Output_Messages): Avoid duplicate output for
5221         library level instance.
5222         * sem_elab.adb (Is_Call_Of_Generic_Formal): Moved to outer level
5223         (Check_Elab_Call): Add call to Is_Call_Of_Generic_Formal
5224         * exp_ch4.adb (Expand_N_Op_Expon): New interface for Exp_Modular.
5225         * s-expmod.ads, s-expmod.adb (Exp_Modular): Change interface to
5226         accomodate largest modulus value.
5227         * gnat_ugn.texi: Minor updates.
5229 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
5231         * sem_ch12.adb (Instantiate_Package_Body): Do not attempt to
5232         load body of generic package or its parent, if body is optional
5233         and the unit does not require a body.
5235 2014-06-11  Robert Dewar  <dewar@adacore.com>
5237         * gnat_rm.texi: Document System.Unsigned_Types.
5238         * impunit.adb: System.Unsigned_Types (s-unstyp.ads) is user accessible.
5239         * s-unstyp.ads: Update comments (this is now user available unit).
5241 2014-06-11  Robert Dewar  <dewar@adacore.com>
5243         * make.adb, sem_res.adb: Minor reformatting.
5245 2014-06-11  Thomas Quinot  <quinot@adacore.com>
5247         * a-astaco.ads, a-tags.ads, s-excdeb.ads, a-tgdico.ads, a-stmaco.ads,
5248         a-except-2005.ads, s-except.ads, a-taside.ads, a-dynpri.ads,
5249         a-chahan.ads, a-sytaco.ads, s-stalib.ads, a-strmap.ads: Change pragmas
5250         Preelaborate_05 to just Preelaborate in runtime units, and similarly
5251         change Pure_05 to just Pure.
5253 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
5255         * sem_ch6.adb (Analyze_Subprogram_Body_Contract): Do not attempt
5256         analysis if error has been posted on subprogram body.
5258 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
5260         * sem_ch13.adb (Analyze_Stream_TSS_Definition): Apply legality
5261         rule given in RM 13.1 (8/1) for operational attributes to stream
5262         attributes: the attribute must apply to a first subtype. Fixes
5263         missing errors in ACATS test bdd2004.
5265 2014-06-11  Robert Dewar  <dewar@adacore.com>
5267         * exp_ch3.adb (Build_Record_Init_Proc): Don't build for variant
5268         record type if restriction No_Implicit_Conditionals is active.
5269         (Expand_N_Object_Declaration): Don't allow default initialization
5270         for variant record type if restriction No_Implicit_Condition is active.
5271         (Build_Variant_Record_Equality): Don't build for variant
5272         record type if restriction No_Implicit_Conditionals is active.
5273         * exp_ch4.adb (Expand_N_Op_Eq): Error if variant records with
5274         No_Implicit_Conditionals.
5275         * sem_aux.ads, sem_aux.adb (Has_Variant_Part): New function.
5277 2014-06-11  Ramon Fernandez  <fernandez@adacore.com>
5279         * i-cstrin.ads: Update comments.
5281 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
5283         * sem_res.adb (Resolve_Selected_Component): Handle properly a
5284         selected component whose prefix is overloaded, when none of the
5285         interpretations matches the expected type.
5287 2014-06-11  Bob Duff  <duff@adacore.com>
5289         * make.adb (Wait_For_Available_Slot): Give a more
5290         informative error message; if the ALI file is not found, print
5291         the full path of what it's looking for.
5293 2014-06-11  Sergey Rybin  <rybin@adacore.com frybin>
5295         * gnat_ugn.texi, vms_data.ads: add description of gnatstub -W<par>
5296         option to specify the result file encoding.
5298 2014-06-11  Robert Dewar  <dewar@adacore.com>
5300         * errout.ads, sem_ch12.adb: Minor reformatting.
5301         * debug.adb, erroutc.adb: Remove -gnatd.q debug switch.
5302         * lib-xref.adb: Minor reformatting.
5303         * restrict.adb: Minor code reorganization (put routines in
5304         alpha order).
5306 2014-06-11  Yannick Moy  <moy@adacore.com>
5308         * einfo.ads: Minor typo in comment
5310 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
5312         * sinfo.ads, sinfo.adb: New attribute Uninitialized_Variable, for
5313         formal private types and private type extensions, to indicate
5314         variable in a generic unit whose uninitialized use suggest that
5315         actual type should be fully initialized.
5316         Needs_Initialized_Actual:  removed, functionaity replaced by
5317         the above.
5318         * lib-xref.adb (Generate_Reference): Generate a reference for
5319         variables of a formal type when the unit is not the main unit,
5320         to enable appropriate warnings in an instance.
5321         * sem_ch12.adb (Check_Ininialized_Type): Improve warning on use
5322         of variable in a generic unit that suggests that actual type
5323         should be full initialized.
5324         * sem_warn.adb; (May_Need_Initialized_Actual): Make into procedure
5325         and do not emot warning, which now only appears in an instance.
5327 2014-06-11  Eric Botcazou  <ebotcazou@adacore.com>
5329         * gnat_ugn.texi: Fix minor typo.
5331 2014-06-11  Hristian Kirtchev  <kirtchev@adacore.com>
5333         * sem_ch3.adb Add with and use clause for Sem_Ch10.
5334         (Analyze_Declarations): Code reformatting. Analyze the contract
5335         of a subprogram body stub at the end of the declarative region.
5336         * sem_ch6.adb (Analyze_Subprogram_Body_Contract): Spec_Id is
5337         now a variable. Do not process the body if its contract is not
5338         available. Account for subprogram body stubs when extracting
5339         the corresponding spec.
5340         * sem_ch6.ads (Analyze_Subprogram_Contract): Update the comment
5341         on usage.
5342         * sem_ch10.ads, sem_ch10.adb (Analyze_Subprogram_Body_Stub_Contract):
5343         New routine.
5344         * sem_prag.adb (Analyze_Depends_In_Decl_Part):
5345         Account for subprogram body stubs when extracting the
5346         corresponding spec.
5347         (Analyze_Global_In_Decl_List):
5348         Account for subprogram body stubs when extracting the
5349         corresponding spec.
5350         (Analyze_Refined_Depends_In_Decl_Part):
5351         Use Find_Related_Subprogram_Or_Body to retrieve the declaration
5352         of the related body. Spec_Is now a variable. Account for
5353         subprogram body stubs when extracting the corresponding spec.
5354         (Analyze_Refined_Global_In_Decl_Part): Use
5355         Find_Related_Subprogram_Or_Body to retrieve the declaration
5356         of the related body. Spec_Is now a variable. Account for
5357         subprogram body stubs when extracting the corresponding spec.
5358         (Collect_Subprogram_Inputs_Output): Account for subprogram body
5359         stubs when extracting the corresponding spec.
5361 2014-06-11  Vincent Celier  <celier@adacore.com>
5363         * gnatcmd.adb (Process_Link): Do not invoke gnatlink with
5364         -lgnarl or -lgnat.
5366 2014-06-11  Robert Dewar  <dewar@adacore.com>
5368         * debug.adb: Add debug flag -gnatd.q.
5369         * erroutc.adb (Prescan_Message): Bomb if untagged warning with
5370         -gnatd.q set.
5371         * styleg.adb (Check_Xtra_Parens): Message should be a style
5372         message.
5373         * sem_aggr.adb, sem_ch3.adb, exp_ch9.adb, checks.adb, sem_prag.adb,
5374         par-endh.adb, eval_fat.adb, freeze.adb, sem_util.adb, sem_attr.adb,
5375         sem_elab.adb, sem_ch6.adb, sem_warn.adb, sem_cat.adb,
5376         sem_ch13.adb, lib-xref.adb: Add remaining warning tags.
5378 2014-06-11  Ben Brosgol  <brosgol@adacore.com>
5380         * gnat_rm.texi: Revised chapter on Implementation Defined
5381         Characteristics.
5383 2014-06-11  Geert Bosch  <bosch@adacore.com>
5385         * s-exctab.adb: avoid race conditions in exception registration.
5387 2014-06-11  Robert Dewar  <dewar@adacore.com>
5389         * errout.adb (Warn_Insertion): New function.
5390         (Error_Msg): Use Warn_Insertion and Prescan_Message.
5391         (Error_Msg_Internal): Set Info field of error object.
5392         (Error_Msg_NEL): Use Prescan_Message.
5393         (Set_Msg_Text): Don't store info: at start of message.
5394         (Skip_Msg_Insertion_Warning): New name for Set_Msg_Insertion_Warning.
5395         (Skip_Msg_Insertion_Warning): Now just skips warning insertion.
5396         * errout.ads: Document new ?$? and >$> insertion sequences
5397         Document use of "(style)" and "info: "
5398         * erroutc.adb (dmsg): Print several missing fields
5399         (Get_Warning_Tag): Handle -gnatel case (?$?)  (Output_Msg_Text):
5400         Deal with new tagging of info messages
5401         * erroutc.ads: Is_Info_Msg: New global (Error_Msg_Object):
5402         Add field Info (Prescan_Message): New procedure, this procedure
5403         replaces the old Test_Style_Warning_Serious_Unconditional_Msg
5404         * errutil.adb, exp_util.adb, par-ch7.adb, sem_ch13.adb, sem_ch7.adb,
5405         sem_elab.adb: Follow new rules for info message (info belongs
5406         only at the start of a message, and only in the first message,
5407         not in any of the continuations).
5408         * gnat_ugn.texi: Document full set of warning tags.
5410 2014-06-11  Gary Dismukes  <dismukes@adacore.com>
5412         * sem_util.adb: Minor typo fix.
5414 2014-06-11  Ed Schonberg  <schonberg@adacore.com>
5416         * sem_warn.adb (Check_References): Do not emit spurious warnings
5417         on uninitialzed variable of a formal private type if variable
5418         is not read.
5420 2014-06-09  Jan Hubicka  <hubicka@ucw.cz>
5422         * gcc-interface/utils.c (process_attributes) <ATTR_LINK_SECTION>: Use
5423         set_decl_section_name accessor.
5425 2014-05-22  Thomas Schwinge  <thomas@codesourcery.com>
5427         * gcc-interface/utils.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
5428         (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
5429         (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
5431 2014-05-21  Robert Dewar  <dewar@adacore.com>
5433         * layout.adb: Minor reformatting.
5434         * sem_prag.adb (Analyze_Pragma, case Inspection_Point): Call
5435         dummy procedure ip.
5437 2014-05-21  Robert Dewar  <dewar@adacore.com>
5439         * restrict.ads (Implementation_Restriction): Add entry for
5440         No_Fixed_IO.
5441         * rtsfind.ads: Add entries for Fixed_IO and Decimal_IO in
5442         Ada.[Wide_[Wide_]Text_IO.
5443         * s-rident.ads (Restriction_Id): Add entry for No_Fixed_IO.
5444         * sem_attr.adb (Analyze_Attribute): Disallow fixed point types
5445         for Img, Image, Value, Wide_Image, Wide_Value, Wide_Wide_Image,
5446         Wide_Wide_Value if restriction No_Fixed_IO is set.
5447         * sem_util.adb (Set_Entity_Checks): Check restriction No_Fixed_IO.
5449 2014-05-21  Robert Dewar  <dewar@adacore.com>
5451         * gnatcmd.adb: Minor error msg changes (no upper case letter
5452         at start).
5453         * sem_ch12.adb, sem_ch5.adb, sem_res.adb, sem_util.adb: Minor
5454         reformatting.
5456 2014-05-21  Robert Dewar  <dewar@adacore.com>
5458         * debug.adb: Debug flag -gnatd.G inhibits static elab tracing
5459         via generic formals.
5460         * sem_elab.adb (Is_Call_Of_Generic_Formal): Return False if
5461         -gnatd.G is set.
5463 2014-05-21  Thomas Quinot  <quinot@adacore.com>
5465         * exp_pakd.adb (Revert_Storage_Order): Renamed from Byte_Swap to
5466         more accurately describe that this subprogram needs to come into
5467         play also in cases where no byte swapping is involved, because
5468         it also takes care of some required shifts (left-justification
5469         of values).
5471 2014-05-21  Thomas Quinot  <quinot@adacore.com>
5473         * freeze.adb (Check_Component_Storage_Order): Indicate whether
5474         a Scalar_Storage_Order attribute definition is present for the
5475         component's type.
5476         (Freeze_Record_Type): Suppress junk warnings
5477         about purportedly junk Bit_Order / Scalar_Storage_Order attribute
5478         definitions.
5480 2014-05-21  Robert Dewar  <dewar@adacore.com>
5482         * sem_ch8.adb (Analyze_Subprogram_Renaming): Put back call
5483         to Kill_Elaboration_Checks.
5485 2014-05-21  Gary Dismukes  <dismukes@adacore.com>
5487         * layout.adb (Assoc_Add): Suppress the optimization of the (E
5488         - C1) + C2 case, when the expression type is unsigned and C1 <
5489         C2, to avoid creating a negative literal when folding.
5491 2014-05-21  Hristian Kirtchev  <kirtchev@adacore.com>
5493         * freeze.adb (Freeze_Record_Type): Update the use of
5494         Is_SPARK_Volatile.
5495         * sem_ch3.adb (Analyze_Object_Contract): Update the use of
5496         Is_SPARK_Volatile.
5497         (Process_Discriminants): Update the use of Is_SPARK_Volatile.
5498         * sem_ch5.adb (Analyze_Iterator_Specification): Update the use
5499         of Is_SPARK_Volatile.
5500         (Analyze_Loop_Parameter_Specification):
5501         Update the use of Is_SPARK_Volatile.
5502         * sem_ch6.adb (Process_Formals): Catch an illegal use of an IN
5503         formal parameter when its type is volatile.
5504         * sem_prag.adb (Analyze_Global_Item): Update the use of
5505         Is_SPARK_Volatile.
5506         * sem_res.adb (Resolve_Entity_Name): Correct the guard which
5507         determines whether an entity is a volatile source SPARK object.
5508         * sem_util.adb (Has_Enabled_Property): Accout for external
5509         properties being set on objects other than abstract states
5510         and variables. An example would be a formal parameter.
5511         (Is_SPARK_Volatile): New routine.
5512         (Is_SPARK_Volatile_Object):
5513         Remove the entity-specific tests. Call routine Is_SPARK_Volatile
5514         when checking entities and/or types.
5515         * sem_util.ads (Is_SPARK_Volatile): New routine.
5517 2014-05-21  Robert Dewar  <dewar@adacore.com>
5519         * sem_warn.adb: Minor fix to warning messages (use ?? instead
5520         of ?).
5522 2014-05-21  Vincent Celier  <celier@adacore.com>
5524         * gnatcmd.adb (GNATCmd): For platforms other than VMS, recognize
5525         switch --version and --help.
5527 2014-05-21  Robert Dewar  <dewar@adacore.com>
5529         * sem_elab.adb (Is_Call_Of_Generic_Formal): New function.
5531 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
5533         * sem_ch5.adb (Analyze_Iterator_Specification): Set type of
5534         iterator variable when the domain of iteration is a formal
5535         container and this is an element iterator.
5537 2014-05-21  Bob Duff  <duff@adacore.com>
5539         * sem_ch12.adb: Minor reformatting.
5541 2014-05-21  Robert Dewar  <dewar@adacore.com>
5543         * sinfo.ads, sem_ch12.adb, sem_warn.adb: Minor reformatting.
5545 2014-05-21  Robert Dewar  <dewar@adacore.com>
5547         * sem_elab.adb: Minor reformatting.
5548         * s-taprop.ads: Minor comment fix.
5549         * sem_ch8.adb (Analyze_Subprogram_Renaming): Remove call to
5550         Kill_Elaboration_Checks.
5551         * errout.adb, erroutc.adb: Minor reformatting.
5553 2014-05-21  Thomas Quinot  <quinot@adacore.com>
5555         * exp_pakd.adb (Byte_Swap): Handle the case of a sub-byte
5556         component. No byte swapping occurs, but this procedure also takes
5557         care of appropriately justifying the argument.
5559 2014-05-21  Hristian Kirtchev  <kirtchev@adacore.com>
5561         * sem_ch6.adb: sem_ch6.adb (Analyze_Aspects_On_Body_Or_Stub):
5562         New routine.
5563         (Analyze_Subprogram_Body_Helper): Move the
5564         analysis of aspect specifications and the processing of the
5565         subprogram body contract after inlining has taken place.
5566         (Diagnose_Misplaced_Aspect_Specifications): Removed.
5568 2014-05-21  Javier Miranda  <miranda@adacore.com>
5570         * sem_ch3.adb (Build_Derived_Record_Type): Revert previous change.
5572 2014-05-21  Robert Dewar  <dewar@adacore.com>
5574         * sem_eval.ads, sem_eval.adb (Why_Not_Static): Messages are not
5575         continuations any more.
5577 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
5579         * sinfo.ads, sinfo.adb: New flag Needs_Initialized_Actual,
5580         present in formal_Private_Definitions and on private extension
5581         declarations of a formal derived type. Set when the use of the
5582         formal type in a generic suggests that the actual should be a
5583         fully initialized type.
5584         * sem_warn.adb (May_Need_Initialized_Actual): new subprogram
5585         to indicate that an entity of a generic type has default
5586         initialization, and that the corresponing actual type in any
5587         subsequent instantiation should be fully initialized.
5588         * sem_ch12.adb (Check_Initialized_Type): new subprogram,
5589         to emit a warning if the actual for a generic type on which
5590         Needs_Initialized_Actual is set is not a fully initialized type.
5592 2014-05-21  Robert Dewar  <dewar@adacore.com>
5594         * sem_elab.adb, prj-dect.adb: Minor reformatting.
5596 2014-05-21  Robert Dewar  <dewar@adacore.com>
5598         * erroutc.ads: Minor comment addition.
5600 2014-05-21  Robert Dewar  <dewar@adacore.com>
5602         * errout.ads: Add documentation for use of >*> tag.
5603         * restrict.adb: Make sure we use >*> tag for restriction warnings.
5605 2014-05-21  Gary Dismukes  <dismukes@adacore.com>
5607         * debug.adb: Add case of illegal overriding_indicator for a
5608         protected subprogram body to description of -gnatd.E switch.
5609         * sem_ch6.adb (Verify_Overriding_Indicator): Issue error message
5610         for cases of giving overriding_indicators on protected subprogram
5611         bodies, but change this to a warning if -gnatd.E is enabled. No
5612         longer give a style warning about missing indicators on protected
5613         subprogram bodies.
5615 2014-05-21  Robert Dewar  <dewar@adacore.com>
5617         * prj.ads, sem_ch12.adb, prj.adb, exp_pakd.adb,
5618         sem_elab.ads: Minor reformatting.
5619         * erroutc.adb, erroutc.ads (Warning_Specifically_Suppressed): Make Tag
5620         parameter optional.
5622 2014-05-21  Pascal Obry  <obry@adacore.com>
5624         * prj-dect.adb: Allow package Install in aggregate project.
5626 2014-05-21  Robert Dewar  <dewar@adacore.com>
5628         * sem_ch13.adb (Analyze_Aspect_Specifications):
5629         Insert_Delayed_Pragma is now used for the case of Attach_Handler.
5630         * sem_prag.adb: Minor comment improvements.
5632 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
5634         * sem_ch12.adb (Install_Body): When checking whether freezing of
5635         instantiation must be delayed, verify that the common enclosing
5636         subprogram to generic and instance is in fact an overloadable
5637         entity.
5639 2014-05-21  Vincent Celier  <celier@adacore.com>
5641         * makeutl.adb (Mains.Complete_Mains.Do_Complete): Look for all
5642         mains with the same name and fail if there is more than one.
5643         * prj.ads, prj.adb (Find_All_Sources): New function
5645 2014-05-21  Robert Dewar  <dewar@adacore.com>
5647         * sem_ch13.adb: Minor reformatting.
5648         * lib-xref-spark_specific.adb, sem_util.adb: Minor reformatting.
5649         * sem_prag.adb: Minor error message improvement.
5651 2014-05-21  Yannick Moy  <moy@adacore.com>
5653         * lib-xref-spark_specific.adb, lib-xref.ads, lib-xref.adb
5654         (Enclosing_Subprogram_Or_Package): Only return a library-level
5655         package.
5657 2014-05-21  Javier Miranda  <miranda@adacore.com>
5659         * sem_ch3.adb (Build_Derived_Record_Type): Initialize Parent_Base
5660         to the full view of the parent type when processing a derived type
5661         which is the full view of a private type not defined in a generic
5662         unit which is derived from a private type with discriminants
5663         whose full view is a non-tagged record type.
5665 2014-05-21  Javier Miranda  <miranda@adacore.com>
5667         * exp_ch4.adb (Expand_Allocator_Expression.Apply_Accessibility_Check):
5668         Complete previous patch.
5670 2014-05-21  Thomas Quinot  <quinot@adacore.com>
5672         PR ada/9535
5673         * g-socket.adb (Read and Write for Datagram_Socket_Stream_Type):
5674         Provide a behaviour more consistent with underlying datagram
5675         socket: do not attempt to loop over Send_Socket/Receive_Socket
5676         iterating along the buffer.
5678 2014-05-21  Hristian Kirtchev  <kirtchev@adacore.com>
5680         * freeze.adb (Freeze_Record_Type): Ensure that a discriminated
5681         or a tagged type is not labelled as volatile. Ensure that a
5682         non-volatile type has no volatile components.
5683         * sem_ch3.adb (Analyze_Object_Contract): Add local constant
5684         Obj_Typ. Code reformatting.  Ensure that a discriminated or
5685         tagged object is not labelled as volatile.
5686         * sem_prag.adb (Process_Atomic_Shared_Volatile): Ensure that
5687         pragma Volatile applies to a full type declaration or an object
5688         declaration when SPARK mode is on.
5690 2014-05-21  Sergey Rybin  <rybin@adacore.com frybin>
5692         * gnat_ugn.texi: For ASIS tools, reword the paragraph about
5693         providing options needed for compiling the argument source for
5694         the situation when a project file can be used as a tool parameter.
5696 2014-05-21  Gary Dismukes  <dismukes@adacore.com>
5698         * gnat_rm.texi: Minor typo fix.
5700 2014-05-21  Robert Dewar  <dewar@adacore.com>
5702         * stand.adb (Tree_Read): Read missing entities.
5703         (Tree_Write): Write missing entities.
5705 2014-05-21  Ben Brosgol  <brosgol@adacore.com>
5707         * gnat_ugn.texi: Wordsmithing edits to Coupling Metrics Control
5708         section in gnatmetric chapter.
5710 2014-05-21  Robert Dewar  <dewar@adacore.com>
5712         * exp_ch6.adb (Expand_Actuals): Spec moved here, since not used
5713         outside Exp_Ch6 (Expand_Actuals): Deal with proper insertion of
5714         post-call copy write back (see detailed comment in code).
5715         * exp_ch6.ads (Expand_Actuals): Moved to body, not used outside
5716         Exp_Ch6.
5717         * tbuild.ads: Minor reformatting.
5719 2014-05-21  Robert Dewar  <dewar@adacore.com>
5721         * stand.ads: Add warning about adding new entities and
5722         Tree_Read/Tree_Write.
5724 2014-05-21  Robert Dewar  <dewar@adacore.com>
5726         * sem_util.adb (Set_Entity_With_Checks): Don't complain about
5727         references to restricted entities within the units in which they
5728         are declared.
5730 2014-05-21  Robert Dewar  <dewar@adacore.com>
5732         * gnat1drv.adb (Check_Bad_Body): Use Source_File_Is_Body to
5733         simplify the needed test, and also deal with failure to catch
5734         situations with non-standard names.
5735         * sinput-l.ads, sinput-l.adb (Source_File_Is_No_Body): New function
5736         (Source_File_Is_Subunit): Removed, no longer used.
5738 2014-05-21  Javier Miranda  <miranda@adacore.com>
5740         * exp_ch4.adb
5741         (Expand_Allocator_Expression.Apply_Accessibility_Check): for a
5742         renaming of an access to interface object there is no need to
5743         generate extra code to reference the tag.
5745 2014-05-21  Robert Dewar  <dewar@adacore.com>
5747         * errout.adb, erroutc.adb, erroutc.ads: Allow warning tag in pragma
5748         Warnings (Off, string).
5750 2014-05-21  Robert Dewar  <dewar@adacore.com>
5752         * osint.adb: Fix three error messages to say invalid instead
5753         of erroneous.
5754         * par-ch4.adb, exp_aggr.adb, sem_attr.adb, sem_aux.adb, sem_ch3.adb,
5755         sem_ch5.adb, sem_ch6.adb, sem_ch7.adb, sem_dim.adb, sem_res.adb,
5756         sem_util.adb, sem_util.ads: Fix incorrect use of erroneous in comments.
5758 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
5760         * freeze.adb, sem_ch13.adb, sem_ch13.ads, sem_ch9.adb,
5761         sem_ch9.ads: Move discriminant manipulation routines for analysis of
5762         aspect specifications from sem_ch9 to sem_ch13, where they belong.
5764 2014-05-21  Robert Dewar  <dewar@adacore.com>
5766         * gnat_ugn.texi: Clearly document -gnatw.g (GNAT warnings).
5767         Clearly document -gnatyg (GNAT style switches).
5768         * usage.adb: Add line line for -gnatw.g (GNAT warnings) More
5769         detail for line for -gnatyg (GNAT style switches) -gnatw.d/D is
5770         available for VMS after all.
5771         * warnsw.adb: Reorganize to eliminate duplicated code
5772         (Restore_Warnings): Add a couple of missing entries
5773         (Save_Warnings): Add a couple of missing entries.
5774         * warnsw.ads: Add missing entries to Warning_Record (not clear
5775         what the impact is).
5777 2014-05-21  Robert Dewar  <dewar@adacore.com>
5779         * errout.adb (Set_Msg_Insertion_Warning): Handle ?*? (restriction
5780         warning) case.
5781         * errout.ads: Document ?*? (restriction warning) insertion.
5782         * erroutc.adb (Get_Warning_Tag): Deal with ?*? (restriction
5783         warning) case.
5784         * erroutc.ads: Document use of * for restriction warning tag.
5785         * restrict.adb (Restriction_Msg): Tag with ?*? instead of ??.
5787 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
5789         * sem_ch9.adb (Push_Scope_And_Install_Discriminants): Do not
5790         make discriminants immediately visible when analyzing an aspect
5791         of a subtype declaration.
5792         (Uninstall_Discriminants): Do not apply to the entity in a
5793         subtype declaration.
5795 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
5797         * sem_util.adb: Code clean up.
5799 2014-05-21  Eric Botcazou  <ebotcazou@adacore.com>
5801         * gnat_ugn.texi: Document -Werror.
5803 2014-05-21  Bob Duff  <duff@adacore.com>
5805         * sem_util.adb (Is_Dependent_Component_Of_Mutable_Object):
5806         This was returning False if the Object is a constant view. Fix
5807         it to return True in that case, because it might be a view of
5808         a variable.
5809         (Has_Discriminant_Dependent_Constraint): Fix latent
5810         bug; this function was crashing when passed a discriminant.
5812 2014-05-21  Robert Dewar  <dewar@adacore.com>
5814         * gnat_ugn.texi: Remove misplaced section that is now obsolete.
5815         * s-arit64.adb: Minor code reorganization.
5816         * sem_prag.adb: Minor comment fix (remove erroneous use of the
5817         term erroneous).
5819 2014-05-21  Robert Dewar  <dewar@adacore.com>
5821         * g-table.adb, g-dyntab.adb (Reallocate): Fix possible overflow in
5822         computing new table size.
5824 2014-05-21  Robert Dewar  <dewar@adacore.com>
5826         * einfo.ads: Minor reformatting.
5827         * ceinfo.adb: Deal with slight format change of einfo.ads.
5829 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
5831         * sem_prag.adb (Analyze_Part_Of): Further work on the proper
5832         implementation of the SPARK 2014 rule concerning private child
5833         units (LRM 7.2.6).
5835 2014-05-21  Vincent Celier  <celier@adacore.com>
5837         * makeusg.adb: Add switch -d to usage.
5839 2014-05-21  Ed Schonberg  <schonberg@adacore.com>
5841         * sem_util.adb (Find_Actual): If an actual that is the prefix
5842         of an enclosing prefixed call has been rewritten, use Nkind
5843         and Sloc to identify the corresponding formal, when handling
5844         deferred references.
5846 2014-05-21  Robert Dewar  <dewar@adacore.com>
5848         * debug.adb: Document -gnatd.z switch.
5849         * sem_eval.adb (Why_Non_Static): Test -gnatd.z switch.
5851 2014-05-21  Robert Dewar  <dewar@adacore.com>
5853         * einfo.ads (Can_Never_Be_Null): Minor comment update.
5854         * sem_prag.adb (Check_Arg_Is_Task_Dispatching_Policy): Minor
5855         error message change.
5856         * s-arit64.adb ("abs"): New function. Use expression functions
5857         for the simple conversions and arithmetic.
5859 2014-05-18  Eric Botcazou  <ebotcazou@adacore.com>
5861         * gcc-interface/trans.c (Subprogram_Body_to_gnu): Rework comment and
5862         set function_start_locus.
5864 2014-05-18  Eric Botcazou  <ebotcazou@adacore.com>
5866         * utils.c (gnat_write_global_declarations): Adjust the flags put on
5867         dummy_global.
5869 2014-05-18  Eric Botcazou  <ebotcazou@adacore.com>
5871         * gcc-interface/decl.c (change_qualified_type): New static function.
5872         (gnat_to_gnu_entity): Use it throughout to add qualifiers on types.
5873         <E_Array_Type>: Set TYPE_VOLATILE on the array type directly.
5874         <E_Array_Subtype>: Likewise.
5875         Do not set flags on an UNCONSTRAINED_ARRAY_TYPE directly.
5876         (gnat_to_gnu_component_type): Likewise.
5877         (gnat_to_gnu_param): Likewise.
5879 2014-05-18  Eric Botcazou  <ebotcazou@adacore.com>
5881         * fe.h (Set_Present_Expr): Move around.
5882         (End_Location): New macro.
5883         * gcc-interface/trans.c (Case_Statement_to_gnu): Use End_Location.
5885 2014-05-18  Eric Botcazou  <ebotcazou@adacore.com>
5887         * gcc-interface/decl.c (gnat_to_gnu_entity): Use Underlying_Type in
5888         lieu of more verbose construct.
5889         * gcc-interface/trans.c (Call_to_gnu): Likewise.
5890         (gnat_to_gnu): Likewise.  Remove obsolete code.
5892 2014-05-18  Eric Botcazou  <ebotcazou@adacore.com>
5894         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Subtype>: Do not
5895         consider that regular packed arrays can never be superflat.
5897 2014-05-17  Trevor Saunders  <tsaunders@mozilla.com>
5899         * gcc-interface/ada-tree.h: Remove usage of variable_size gty
5900         annotation.
5901         * gcc-interface/decl.c (annotate_value): Adjust.
5902         * gcc-interface/trans.c (Attribute_to_gnu): Likewise.
5903         (push_range_check_info): Likewise.
5904         (Loop_Statement_to_gnu): Likewise.
5905         (Subprogram_Body_to_gnu): Likewise.
5906         (Compilation_Unit_to_gnu): Likewise.
5907         (start_stmt_group): Likewise.
5908         * gcc-interface/utils.c (init_gnat_utils): Likewise.
5909         (gnat_pushlevel): Likewise.
5910         (maybe_pad_type): Likewise.
5912 2014-05-14  Eric Botcazou  <ebotcazou@adacore.com>
5914         * seh_init.c: Fix copyright year.
5916 2014-05-14  Bernd Edlinger  <bernd.edlinger@hotmail.de>
5918         * seh_init.c (__gnat_map_SEH): Compile also when __CYGWIN__ and __SEH__
5919         are defined.  Move include windows.h before system.h.
5920         * s-oscons-tmplt.c (DTR_CONTROL_ENABLE, RTS_CONTROL_ENABLE): Compile
5921         also when __CYGWIN__ is defined.  Include windef.h before winbase.h.
5923 2014-05-14  Richard Sandiford  <r.sandiford@uk.ibm.com>
5925         * gcc-interface/decl.c (gnat_to_gnu_entity): Convert integer_one_node
5926         to the appropriate type.
5927         * gcc-interface/trans.c (gnat_to_gnu): Likewise.
5928         (pos_to_constructor): Likewise.
5930 2014-05-13  Eric Botcazou  <ebotcazou@adacore.com>
5932         * gcc-interface/decl.c (annotate_value): Fix thinko in latest change.
5934 2014-05-06  Kenneth Zadeck  <zadeck@naturalbridge.com>
5935             Mike Stump  <mikestump@comcast.net>
5936             Richard Sandiford  <rdsandiford@googlemail.com>
5938         * gcc-interface/cuintp.c (UI_From_gnu): Use wide-int interfaces.
5939         * gcc-interface/decl.c (gnat_to_gnu_entity): Use TYPE_SIGN.
5940         (annotate_value): Use wide-int interfaces.
5941         * gcc-interface/utils.c (get_nonnull_operand): Use tree_fits_uhwi_p.
5943 2014-04-28  Richard Henderson  <rth@redhat.com>
5945         * gcc-interface/Makefile.in: Support aarch64-linux.
5947 2014-04-28  Eric Botcazou  <ebotcazou@adacore.com>
5949         * exp_dbug.ads (Get_External_Name): Add 'False' default to Has_Suffix,
5950         add 'Suffix' parameter and adjust comment.
5951         (Get_External_Name_With_Suffix): Delete.
5952         * exp_dbug.adb (Get_External_Name_With_Suffix): Merge into...
5953         (Get_External_Name): ...here.  Add 'False' default to Has_Suffix, add
5954         'Suffix' parameter.
5955         (Get_Encoded_Name): Remove 2nd argument in call to Get_External_Name.
5956         Call Get_External_Name instead of Get_External_Name_With_Suffix.
5957         (Get_Secondary_DT_External_Name): Likewise.
5958         * exp_cg.adb (Write_Call_Info): Likewise.
5959         * exp_disp.adb (Export_DT): Likewise.
5960         (Import_DT): Likewise.
5961         * comperr.ads (Compiler_Abort): Remove Code parameter and add From_GCC
5962         parameter with False default.
5963         * comperr.adb (Compiler_Abort): Likewise.  Adjust accordingly.
5964         * types.h (Fat_Pointer): Rename into...
5965         (String_Pointer): ...this.  Add comment on interfacing rules.
5966         * fe.h (Compiler_Abort): Adjust for above renaming.
5967         (Error_Msg_N): Likewise.
5968         (Error_Msg_NE): Likewise.
5969         (Get_External_Name): Likewise.  Add third parameter.
5970         (Get_External_Name_With_Suffix): Delete.
5971         * gcc-interface/decl.c (STDCALL_PREFIX): Define.
5972         (create_concat_name): Adjust call to Get_External_Name, remove call to
5973         Get_External_Name_With_Suffix, use STDCALL_PREFIX, adjust for renaming.
5974         * gcc-interface/trans.c (post_error): Likewise.
5975         (post_error_ne): Likewise.
5976         * gcc-interface/misc.c (internal_error_function): Likewise.
5978 2014-04-28  Richard Biener  <rguenther@suse.de>
5980         PR middle-end/60092
5981         * gcc-interface/utils.c: Define flag_isoc11.
5983 2014-04-26  Eric Botcazou  <ebotcazou@adacore.com>
5985         * gnatvsn.ads (Library_Version): Bump to 4.10.
5987 2014-04-23  Eric Botcazou  <ebotcazou@adacore.com>
5989         Revert
5990         2014-04-22  Richard Henderson  <rth@redhat.com>
5992         * gcc-interface/Makefile.in: Support aarch64-linux.
5994         2014-04-22  Eric Botcazou  <ebotcazou@adacore.com>
5996         * fe.h (Compiler_Abort): Replace Fat_Pointer with String_Pointer.
5997         (Error_Msg_N): Likewise.
5998         (Error_Msg_NE): Likewise.
5999         (Get_External_Name_With_Suffix): Likewise.
6000         * types.h (Fat_Pointer): Delete.
6001         (String_Pointer): New type.
6002         (DECLARE_STRING_POINTER): New macro.
6003         * gcc-interface/decl.c (create_concat_name): Adjust.
6004         * gcc-interface/trans.c (post_error): Likewise.
6005         (post_error_ne): Likewise.
6006         * gcc-interface/misc.c (internal_error_function): Likewise.
6008 2014-04-22  Richard Henderson  <rth@redhat.com>
6010         * gcc-interface/Makefile.in: Support aarch64-linux.
6012         * init.c [__linux__] (HAVE_GNAT_ALTERNATE_STACK): New define.
6013         (__gnat_alternate_stack): Enable for all linux except ia64.
6015 2014-04-22  Eric Botcazou  <ebotcazou@adacore.com>
6017         * fe.h (Compiler_Abort): Replace Fat_Pointer with String_Pointer.
6018         (Error_Msg_N): Likewise.
6019         (Error_Msg_NE): Likewise.
6020         (Get_External_Name_With_Suffix): Likewise.
6021         * types.h (Fat_Pointer): Delete.
6022         (String_Pointer): New type.
6023         (DECLARE_STRING_POINTER): New macro.
6024         * gcc-interface/decl.c (create_concat_name): Adjust.
6025         * gcc-interface/trans.c (post_error): Likewise.
6026         (post_error_ne): Likewise.
6027         * gcc-interface/misc.c (internal_error_function): Likewise.
6029 2014-04-15  Eric Botcazou  <ebotcazou@adacore.com>
6030             Pierre-Marie de Rodat  <derodat@adacore.com>
6032         * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Create a mere
6033         scalar constant instead of a reference for renaming of scalar literal.
6034         Do not create a new object for constant renaming except for a function
6035         call.  Make sure a VAR_DECL is created for the renaming pointer.
6036         * gcc-interface/trans.c (constant_decl_with_initializer_p): New.
6037         (fold_constant_decl_in_expr): New function.
6038         (Identifier_to_gnu): Use constant_decl_with_initializer_p.
6039         For a constant renaming, try to fold a constant DECL in the result.
6040         (lvalue_required_p) <N_Object_Renaming_Declaration>: Always return 1.
6041         (Identifier_to_gnu): Reference the renamed object of constant renaming
6042         pointers directly.
6043         * gcc-interface/utils.c (invalidate_global_renaming_pointers): Do not
6044         invalidate constant renaming pointers.
6046 2014-04-15  Eric Botcazou  <ebotcazou@adacore.com>
6048         * gcc-interface/utils.c (type_for_vector_element_p): New predicate.
6049         (build_vector_type_for_size): New function.
6050         (build_vector_type_for_array): Likewise.
6051         (unchecked_convert): Build an intermediate vector type to convert
6052         from a generic array type to a vector type.
6053         (handle_vector_size_attribute): Reimplement.
6054         (handle_vector_type_attribute): Likewise.
6056 2014-04-15  Eric Botcazou  <ebotcazou@adacore.com>
6058         * gcc-interface/decl.c (prepend_one_attribute_pragma): Call
6059         Is_OK_Static_Expression in lieu of Is_Static_Expression to
6060         detect valid arguments.
6062 2014-04-15  Eric Botcazou  <ebotcazou@adacore.com>
6064         * gcc-interface/trans.c (gnat_gimplify_stmt): Propagate loop hints.
6066 2014-04-14  Paolo Carlini  <paolo.carlini@oracle.com>
6068         * gcc-interface/decl.c (gnat_to_gnu_entity): Use TYPE_IDENTIFIER.
6069         (components_to_record): Likewise.
6070         * gcc-interface/utils.c (make_aligning_type): Likewise.
6071         (maybe_pad_type): Likewise.
6072         (finish_record_type): Likewise.
6073         (rest_of_record_type_compilation): Likewise.
6075 2014-04-14  Eric Botcazou  <ebotcazou@adacore.com>
6077         * snames.ads-tmpl (Name_Ivdep): New pragma-related name.
6078         * sem_prag.adb (Analyze_Pragma) <Pragma_Loop_Optimize>: Add support
6079         for Ivdep hint.
6080         * gnat_rm.texi (Implementation Defined Pragmas): Document new Ivdep
6081         hint for Loop_Optimize.
6082         * gnat_ugn.texi (Vectorization of loops): Mention new Ivdep hint.
6083         * gcc-interface/trans.c (Pragma_to_gnu) <Pragma_Loop_Optimize>: Deal
6084         with new Ivdep hint.
6085         * gcc-interface/ada-tree.h (LOOP_STMT_IVDEP): New macro.
6086         * gcc-interface/trans.c (Pragma_to_gnu) <Pragma_Loop_Optimize>: Deal
6087         with new Ivdep hint.
6088         (gnat_gimplify_stmt) <LOOP_STMT>: Propagate loop hints.
6090 2014-04-14  Eric Botcazou  <ebotcazou@adacore.com>
6091             Robert Dewar  <dewar@adacore.com>
6093         * opt.ads (Suppress_Back_Annotation): Remove as unused.
6094         * fe.h (Back_Annotate_Rep_Info): Likewise.
6095         (Global_Discard_Names): Likewise.
6096         (List_Representation_Info): Declare.
6097         * types.h (Uint_Minus_1): Likewise.
6098         * repinfo.ads: Document back-annotation change.
6099         * gcc-interface/gigi.h (init_gnat_decl): Declare.
6100         (destroy_gnat_decl): Likewise.
6101         * gcc-interface/decl.c (annotate_value): Do not create the cache of
6102         annotated values here but...
6103         <CALL_EXPR>: Only inline the call if -gnatR3 is specified or we are
6104         in ASIS mode.
6105         (init_gnat_decl): ...here instead.  New function.
6106         (destroy_gnat_decl): Likewise.
6107         * gcc-interface/trans.c (gigi): Call {init|destroy}_gnat_decl.
6108         * gcc-interface/utils.c (init_gnat_utils): Minor reformatting.
6110 2014-04-14  Eric Botcazou  <ebotcazou@adacore.com>
6112         * gcc-interface/decl.c (create_field_decl_from): Finalize non-constant
6113         offset for the field, if any.
6115 2014-04-09  Eric Botcazou  <ebotcazou@adacore.com>
6116             Svante Signell  <svante.signell@gmail.com>
6118         PR ada/54040
6119         PR ada/59346
6120         * s-osinte-x32.adb: New file.
6121         * s-linux.ads (Time): New section.
6122         * s-linux-alpha.ads (Time): Likewise.
6123         * s-linux-android.ads (Time: Likewise.
6124         * s-linux-hppa.ads (Time): Likewise.
6125         * s-linux-mipsel.ads (Time): Likewise.
6126         * s-linux-sparc.ads (Time): Likewise.
6127         * s-linux-x32.ads (Time): Likewise.
6128         * s-osprim-x32.ads (timespec): Adjust.
6129         (Clock): Likewise.
6130         (To_Timespec): Likewise.
6131         * s-osinte-linux.ads (Time): Define local subtypes for those defined
6132         in System.Linux.
6133         * s-taprop-linux.adb (Monotonic_Clock): Do not define timeval.
6134         * s-osinte-hpux.ads (timespec): Revert POSIX breakage.
6135         * s-osinte-kfreebsd-gnu.ads (timespec): Likewise.
6136         * s-osinte-solaris-posix.ads (timespec): Likewise.
6137         * s-osinte-posix.adb (To_Timespec): Likewise.
6138         * gcc-interface/Makefile.in (x32/Linux): Use s-osinte-x32.adb.
6140 2014-04-08  Eric Botcazou  <ebotcazou@adacore.com>
6142         PR ada/60411
6143         * gcc-interface/Makefile.in (arm% linux-android): Switch to EHABI.
6144         * s-linux-android.ads: New file.
6145         * s-intman-android.adb: Likewise.
6146         * s-osinte-android.ads: Adjust.
6147         * sigtramp-armdroid.c: Likewise.
6148         * sigtramp.h: Add Android support.
6150 2014-04-07  Eric Botcazou  <ebotcazou@adacore.com>
6152         * gcc-interface/Makefile.in (alpha-vms): Add missing line.
6154 2014-03-30  Eric Botcazou  <ebotcazou@adacore.com>
6156         PR ada/60703
6157         * system-linux-alpha.ads: Adjust for Ada 2005.
6158         * system-linux-mips.ads: Likewise.
6159         * system-linux-mips64el.ads: Likewise.
6160         * system-linux-mipsel.ads: Likewise.
6161         * system-linux-s390.ads: Likewise.
6162         * system-linux-s390x.ads: Likewise.
6163         * system-linux-sparc.ads: Likewise.
6164         * system-linux-sparcv9.ads: Likewise.
6165         * system-rtems.ads: Likewise.
6166         * system-vxworks-arm.ads: Likewise.
6168 2014-03-16  Andreas Schwab  <schwab@linux-m68k.org>
6170         PR ada/39172
6171         * gcc-interface/Makefile.in (target_cpu_default): Revert
6172         2013-10-11 change.
6174 2014-03-13  Eric Botcazou  <ebotcazou@adacore.com>
6176         PR ada/51483
6177         * cstand.adb (Register_Float_Type): Add 'precision' parameter and use
6178         it to set the RM size.  Use directly 'size' for the Esize.
6179         (Create_Back_End_Float_Types): Adjust call to above.
6180         * get_targ.ads (Register_Type_Proc): Add 'precision' parameter.
6181         * set_targ.ads (FPT_Mode_Entry): Add 'precision' component.
6182         (Write_Target_Dependent_Values): Adjust comment.
6183         * set_targ.adb (Register_Float_Type): Add 'precision' parameter and
6184         deal with it.
6185         (Write_Target_Dependent_Values): Write the precision in lieu of size.
6186         (Initialization): Read the precision in lieu of size and compute the
6187         size from the precision and the alignment.
6188         * gcc-interface/gigi.h (enumerate_modes): Add integer parameter.
6189         * gcc-interface/misc.c (enumerate_modes): Likewise.  Do not register
6190         types for vector modes, pass the size in addition to the precision.
6192 2014-03-10  Eric Botcazou  <ebotcazou@adacore.com>
6194         * gcc-interface/Make-lang.in (ADA_DEPFILES): Fix typo.
6196 2014-03-07  Doug Rupp  <rupp@adacore.com>
6198         PR ada/60411
6199         * system-linux-armel.ads (Backend_Overflow_Checks): Set to True.
6200         (Support_64_Bit_Divides): Removed, no longer used.
6201         (ZCX_By_Default): Enabled.
6203 2014-02-25  Doug Rupp  <rupp@adacore.com>
6205         * gcc-interface/Makefile.in (arm-linux):
6206         (EH_MECHANISM): Use ARM unwinder (-arm)
6207         (LIBGNAT_TARGET_PAIRS: Override defaults with a-exexpr-gcc.adb and
6208         s-excmac-arm.ads.
6209         (EXTRA_LIBGNAT_OBJS): Add raise-gcc.o
6210         (EXTRA_GNATRTL_NONTASKING_OBJS): Add g-cppexc.o s-excmac.o.
6211         (arm-wrs-vxworks): Add EH_MECHANISM=-gcc for kernel mode.
6212         (EXTRA_LIBGNAT_OBJS): Add sigtramp-armvxw.o
6213         Add dependencies for sigtramp-armvxw.o.
6215 2014-02-25  Eric Botcazou  <ebotcazou@adacore.com>
6217         * gcc-interface/trans.c (Pragma_to_gnu): Deal with Warning_As_Error.
6219 2014-02-25  Robert Dewar  <dewar@adacore.com>
6221         * rtsfind.adb (Is_RTE): Protect against entity with no scope
6222         field (previously this call blew up on the Standard entity).
6223         * sem_attr.adb (Analyze_Attribute, case Access): Remove
6224         test for No_Abort_Statements, this is now handled in
6225         Set_Entity_With_Checks.
6226         * exp_ch6.adb, sem_ch10.adb, sem_ch4.adb, sem_ch8.adb, sem_res.adb:
6227         Change name Set_Entity_With_Style_Check => Set_Entity_With_Checks.
6228         * sem_util.ads, sem_util.adb: Change name Set_Entity_With_Style_Check =>
6229         Set_Entity_With_Checks.
6230         (Set_Entity_With_Checks): Add checks for No_Dynamic_Attachment,
6231         Add checks for No_Abort_Statements.
6233 2014-02-25  Robert Dewar  <dewar@adacore.com>
6235         * exp_ch9.adb (Expand_Entry_Barrier): Add comment that call to
6236         Check_Restriction is OK.
6238 2014-02-25  Ed Schonberg  <schonberg@adacore.com>
6240         * sem_ch3.adb (Process_Full_View): Better error message when
6241         the full view of  a private type without discriminants is an
6242         unconstrained type.
6243         * sem_ch7.adb (Uninstall_Declarations): Ditto.
6245 2014-02-25  Eric Botcazou  <ebotcazou@adacore.com>
6247         * sigtramp-armvxw.c: Also restore r0.
6249 2014-02-25  Robert Dewar  <dewar@adacore.com>
6251         * errout.adb (Error_Msg_Internal): Warning_Msg_Char set
6252         unconditionally (Set_Msg_Insertion_Warning): Warning_Msg_Char
6253         set unconditionally.
6254         * erroutc.adb (Get_Warning_Tag): Does not give a leading space
6255         any more (Output_Msg_Text): Rewritten with new convention on
6256         output of warnings that are treated as errors.
6257         * erroutc.ads (Error_Msg_Object): Warn_Chr is always set even
6258         if Warn is False.
6259         * gnat_rm.texi: Updates to documentation on pragma
6260         Warning_As_Error.
6261         * warnsw.adb (Set_Dot_Warning_Switch): -gnatw.e should not
6262         set Warning_Doc_Switch.
6263         * lib-writ.ads: Add documentation note on ALI file generation
6264         for C.
6265         * exp_ch6.adb (Expand_Call): Remove check for No_Abort_Statements
6266         (belongs in Sem).
6267         * sem_attr.adb (Resolve_Attribute, case Access):
6268         Abort_Task'Access violates the No_Abort_Statements restriction.
6269         * sem_res.adb (Resolve_Call): Check restriction
6270         No_Abort_Statements for call to Abort_Task or a renaming of it.
6272 2014-02-25  Robert Dewar  <dewar@adacore.com>
6274         * sem_ch3.adb (Array_Type_Declaration): Check for case of using
6275         type name as index.
6276         * lib.ads: Minor reformatting.
6277         * einfo.ads: Minor reformatting.
6279 2014-02-25  Doug Rupp  <rupp@adacore.com>
6281         * sem_mech.adb (Set_Mechanisms): For convention Fortran on VMS
6282         use Short_Descriptor(S) as the argument passing mechanism.
6284 2014-02-25  Eric Botcazou  <ebotcazou@adacore.com>
6286         * sigtramp-ppcvxw.c (CFI_COMMON_REGS): Also include r0.
6288 2014-02-25  Robert Dewar  <dewar@adacore.com>
6290         * atree.ads (Warnings_Treated_As_Errors): New variable.
6291         * errout.adb (Error_Msg_Internal): Set Warn_Err flag in
6292         error object (Initialize): Initialize Warnings_As_Errors_Count
6293         (Write_Error_Summary): Include count of warnings treated as errors.
6294         * erroutc.adb (Warning_Treated_As_Error): New function.
6295         (Matches): Function moved to outer level of package.
6296         * erroutc.ads (Error_Msg_Object): Add Warn_Err flag.
6297         (Warning_Treated_As_Error): New function.
6298         * gnat_rm.texi: Document pragma Treat_Warning_As_Error.
6299         * opt.adb: Add handling of Warnings_As_Errors_Count[_Config].
6300         * opt.ads (Config_Switches_Type): Add entry for
6301         Warnings_As_Errors_Count.
6302         (Warnings_As_Errors_Count): New variable.
6303         (Warnings_As_Errors): New array.
6304         * par-prag.adb: Add dummy entry for Warning_As_Error.
6305         * sem_prag.adb (Analyze_Pragma): Implement new pragma
6306         Warning_As_Error.
6307         * snames.ads-tmpl: Add entries for Warning_As_Error pragma.
6309 2014-02-25  Eric Botcazou  <ebotcazou@adacore.com>
6311         * sigtramp.h: Fix minor inaccuracy.
6313 2014-02-25  Ben Brosgol  <brosgol@adacore.com>
6315         * gnat_ugn.texi: Added description of kill command.
6317 2014-02-25  Robert Dewar  <dewar@adacore.com>
6319         * gnat_rm.texi (Address_Clauses): Add a section discussing the
6320         problem of address clauses causing unexpected initialization,
6321         including the effect of Initialize_Scalars.
6323 2014-02-25  Robert Dewar  <dewar@adacore.com>
6325         * errout.adb: Various changes for better msgs for anonmous access
6326         subprogram types.
6327         * erroutc.ads, erroutc.adb (Buffer_Ends_With): Version with character
6328         argument.
6329         (Buffer_Remove): Version with character argument.
6330         * sem_attr.adb (Resolve_Attribute, case Access): Better handling
6331         of mismatching conventions for access-to-subprogram case.
6332         * sem_prag.adb (Set_Convention_From_Pragma): Deal with anonymous
6333         access types in record.
6334         * sem_util.ads, sem_util.adb (Set_Convention): Handle anonymous access
6335         types, including in records.
6337 2014-02-25  Doug Rupp  <rupp@adacore.com>
6339         * sigtramp-ppcvxw.c, sigtramp.h, sigtramp-armvxw.c: Comment
6340         enhancements and corrections.
6342 2014-02-25  Robert Dewar  <dewar@adacore.com>
6344         * gnat_rm.texi: New section "Conventions and Anonymous Access Types"
6346 2014-02-25  Robert Dewar  <dewar@adacore.com>
6348         * gnat_rm.texi: First set of documentation additions for
6349         predefined RM units.
6350         * checks.adb: Minor reformatting.
6351         * sem_elab.adb (Check_Task_Activation): Minor fix to error
6352         message.
6353         * sem_util.adb: Minor reformatting.
6355 2014-02-25  Arnaud Charlet  <charlet@adacore.com>
6357         * usage.adb (Usage): Add help on -gnateC.
6358         * switch-c.adb (Scan_Front_End_Switches): Add handling of -gnateC.
6359         * opt.ads (Generate_CodePeer_Messages): New flag.
6360         * gnat_ugn.texi: Document new switch -gnateC.
6362 2014-02-25  Ben Brosgol  <brosgol@adacore.com>
6364         * gnat_rm.texi: Corrected minor typos in Implementation Defined
6365         Aspects.
6366         * opt.ads: Minor reformatting.
6368 2014-02-25  Robert Dewar  <dewar@adacore.com>
6370         * binde.adb: Change messages to mention -gnatel instead of -gnatwl.
6371         * gnat_ugn.texi: Update documentation of -gnatwl Add documentation
6372         of -gnatel/-gnateL.
6373         * opt.ads (Warn_Info_Messages): New flag.
6374         * sem_elab.adb: Use Elab_Warnings, Elab_Info_Messages to control
6375         messages.
6376         * sem_prag.adb: Use Elab_Warnings, Elab_Info_Messages to control
6377         messages.
6378         * switch-m.ad, switch-c.adb: Recognize new -gnatel/EL switches.
6379         * usage.adb: Add documentation of -gnatel/-gnateL Update
6380         documentation of -gnatwl/-gnatwL.
6381         * warnsw.adb: New handling of Elab_Warnings, Elab_Info_Messages
6382         * warnsw.ads (Elab_Info_Messages): New field in Warning_Record
6384 2014-02-25  Robert Dewar  <dewar@adacore.com>
6386         * einfo.ads, einfo.adb (Has_Shift_Operator): New flag.
6387         * gnat_rm.texi: Document pragma Provide_Shift_Operators.
6388         * interfac.ads: Minor code reorganization (add pragma
6389         Compiler_Unit_Warning).
6390         * par-prag.adb: Add dummy entry for Provide_Shift_Operators.
6391         * sem_ch3.adb (Build_Derived_Numeric_Type): Copy
6392         Has_Shift_Operator flag.
6393         * sem_intr.adb (Check_Intrinsic_Subprogram): Make sure
6394         Check_Shift is always called (Check_Shift): Set Has_Shift_Operator.
6395         * sem_prag.adb: Implement pragma Provide_Shift_Operators.
6396         * snames.ads-tmpl: Add entries for pragma Provide_Shift_Operators
6397         Add entry for Name_Amount.
6398         * checks.adb (Selected_Range_Checks): When checking for a null
6399         range, make sure we use the base type, and not the subtype for
6400         deciding a range is null.
6401         * sem_ch5.adb (Analyze_Loop_Parameter_Specification): Check
6402         for suspicious loop bound which is outside the range of the
6403         loop subtype.
6404         * gnat_ugn.texi: Add documentation section "Determining the
6405         Chosen Elaboration Order"
6406         * sem_ch13.adb (UC_Entry): Add field Act_Unit
6407         (Validate_Unchecked_Conversion): Store Act_Unit
6408         (Validate_Unchecked_Conversions): Test Warnings_Off in Act_Unit
6409         * treepr.adb: Minor reformatting.
6411 2014-02-25  Arnaud Charlet  <charlet@adacore.com>
6413         * usage.adb: Minor: fix typo.
6415 2014-02-25  Robert Dewar  <dewar@adacore.com>
6417         * lib.ads, s-bitops.adb, s-bitops.ads, s-conca5.adb, gnat_rm.texi,
6418         s-conca5.ads, s-conca7.adb, s-conca7.ads, s-crc32.adb, s-crc32.ads,
6419         s-conca9.adb, s-conca9.ads, g-dyntab.adb, s-crtl.ads, g-dyntab.ads,
6420         s-excdeb.adb, s-addope.adb, s-addope.ads, s-carun8.adb, s-carun8.ads,
6421         g-htable.adb, g-htable.ads, g-hesora.adb, g-hesora.ads, s-conca2.adb,
6422         s-conca2.ads, a-comlin.adb, a-chlat1.ads, a-comlin.ads, errout.ads,
6423         a-except.adb, s-conca4.adb, a-except.ads, s-conca4.ads, s-conca6.adb,
6424         s-conca6.ads, g-spchge.adb, g-spchge.ads, g-u3spch.adb, g-u3spch.ads,
6425         a-strhas.ads, restrict.adb, aspects.adb, aspects.ads, s-conca8.adb,
6426         s-conca8.ads, back_end.adb, par-prag.adb, g-byorma.adb, g-byorma.ads,
6427         a-elchha.adb, a-elchha.ads, g-speche.adb, g-speche.ads, s-casuti.adb,
6428         s-assert.adb, s-casuti.ads, s-assert.ads, a-clrefi.adb, a-clrefi.ads,
6429         s-conca3.adb, s-conca3.ads, a-ioexce.ads: Implement pragma
6430         Compiler_Unit_Warning, change Compiler_Unit everywhere to
6431         Compiler_Unit_Warning.
6433 2014-02-25  Sergey Rybin  <rybin@adacore.com frybin>
6435         * sem_prag.adb (Analyze_Depends_In_Decl_Part): Do not normalize
6436         in ASIS mode aggregates that are used as aspect definitions.
6438 2014-02-25  Robert Dewar  <dewar@adacore.com>
6440         * exp_ch7.adb, sem_util.adb, sem_util.ads, exp_ch6.adb: Minor
6441         reformatting.
6443 2014-02-25  Ed Schonberg  <schonberg@adacore.com>
6445         * freeze.adb (Freeze_Entity): If the return type of a function
6446         is a limited view, and the non-limited view has not been seen yet,
6447         defer freezing to some later point.
6449 2014-02-25  Robert Dewar  <dewar@adacore.com>
6451         * sem_ch3.adb: Minor reformatting.
6453 2014-02-25  Robert Dewar  <dewar@adacore.com>
6455         * s-excdeb.ads, s-except.ads, s-exctab.adb, s-exctab.ads, s-finmas.ads,
6456         s-htable.adb, s-htable.ads, s-imenne.adb, s-imenne.ads, s-imgenu.adb,
6457         s-imgenu.ads, s-mastop.adb, s-mastop.ads, s-memory-vms_64.adb,
6458         s-memory-vms_64.ads, s-memory.adb, s-memory.ads, s-os_lib.adb,
6459         s-os_lib.ads, s-parame.adb, s-parame.ads, s-purexc.ads, s-restri.adb,
6460         s-restri.ads, s-rident.ads, s-secsta.adb, s-secsta.ads, s-soflin.adb,
6461         s-soflin.ads, s-sopco3.adb, s-sopco3.ads, s-sopco4.adb, s-sopco4.ads,
6462         s-sopco5.adb, s-sopco5.ads, s-spsufi.ads, s-stache.adb, s-stache.ads,
6463         s-stalib.adb, s-stalib.ads, s-stoele.adb, s-stoele.ads, s-strcom.adb,
6464         s-strcom.ads, s-strhas.adb, s-string.adb, s-string.ads, s-strops.adb,
6465         s-strops.ads, s-ststop.adb, s-ststop.ads, s-traceb.adb, s-traceb.ads,
6466         s-traent.adb, s-traent.ads, s-unstyp.ads, s-utf_32.adb, s-utf_32.ads,
6467         s-wchcnv.adb, s-wchcnv.ads, s-wchcon.adb, s-wchcon.ads, s-wchjis.adb,
6468         s-wchjis.ads, sem_ch11.adb, sem_ch4.adb, sem_ch5.adb, sem_prag.adb,
6469         snames.ads-tmpl: Change Compiler_Unit everywhere to
6470         Compiler_Unit_Warning.
6472 2014-02-25  Hristian Kirtchev  <kirtchev@adacore.com>
6474         * exp_ch6.adb (Add_Or_Save_Precondition): New routine.
6475         (Collect_Body_Postconditions_In_Decls): New routine.
6476         (Collect_Body_Postconditions_Of_Kind): Factor out code. Handle
6477         postcondition aspects or pragmas that appear on a subprogram
6478         body stub.
6479         (Collect_Spec_Preconditions): Factor out code. Handle
6480         precondition aspects or pragmas that appear on a subprogram
6481         body stub.
6482         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): The analysis of
6483         aspects that apply to a subprogram body stub is no longer delayed,
6484         the aspects are analyzed on the spot.
6485         (SPARK_Aspect_Error):
6486         Aspects that apply to a subprogram declaration cannot appear in
6487         a subunit.
6488         * sem_ch10.adb Remove with and use clause for Sem_Ch13.
6489         (Analyze_Proper_Body): Add local variable Comp_Unit. Unum
6490         is now a local variable. Code cleanup. Analysis related to
6491         the aspects of a subprogram body stub is now carried out by
6492         Analyze_Subprogram_Body_Helper. Do not propagate the aspects
6493         and/or pragmas of a subprogram body stub to the proper body
6494         as this is no longer needed. Do not analyze the aspects of a
6495         subprogram stub when the corresponding source unit is missing.
6496         (Analyze_Protected_Body_Stub): Flag the illegal use of aspects
6497         on a stub.
6498         (Analyze_Task_Body_Stub): Flag the illegal use of
6499         aspects on a stub.
6500         (Optional_Subunit): Add local variable Unum.
6501         * sem_ch13.adb (Insert_Delayed_Pragma): Do not analyze a generated
6502         pragma when it applies to a subprogram body stub.
6503         * sem_prag.adb (Analyze_Pragma): Pragmas Contract_Cases,
6504         Depends and Global can now apply to a subprogram body stub as
6505         long as it acts as its own spec.
6506         (Analyze_Refined_Pragma):
6507         Code reformatting. Refinement pragmas cannot apply to a subunit.
6509 2014-02-25  Hristian Kirtchev  <kirtchev@adacore.com>
6511         * einfo.ads Update the usage of flag
6512         Uses_Sec_Stack. Uses_Sec_Stack now applies to E_Loop entities.
6513         * exp_ch5.adb (Expand_Iterator_Loop): The temporary for a cursor
6514         now starts with the letter 'C'. This makes reading expanded
6515         code easier.
6516         * exp_ch7.adb (Establish_Transient_Scope): Add local variable
6517         Iter_Loop. Signal that an Ada 2012 iterator loop requires
6518         secondary stack management when creating a transient scope for
6519         an element reference.
6520         * exp_util.adb (Process_Statements_For_Controlled_Objects):
6521         When wrapping the statements of a loop, pass the E_Loop entity
6522         to the wrapping machinery.
6523         (Wrap_Statements_In_Block): Add
6524         formal parameter Scop along with comment on usage. Add local
6525         variables Block_Id, Block_Nod and Iter_Loop. Mark the generated
6526         block as requiring secondary stack management when the block is
6527         created inside an Ada 2012 iterator loop. This ensures that any
6528         reference objects are reclaimed on each iteration of the loop.
6529         * sem_ch5.adb (Analyze_Loop_Statement): Mark the generated block
6530         tasked with the handling of container iterators as requiring
6531         secondary stack management. This ensures that iterators are
6532         reclaimed when the loop terminates or is exited in any fashion.
6533         * sem_util.adb (Add_Block_Identifier): New routine.
6534         (Find_Enclosing_Iterator_Loop): New routine.
6535         * sem_util.ads (Add_Block_Identifier): New routine.
6536         (Find_Enclosing_Iterator_Loop): New routine.
6538 2014-02-25  Robert Dewar  <dewar@adacore.com>
6540         * sinfo.ads: Minor reformatting.
6542 2014-02-25  Tristan Gingold  <gingold@adacore.com>
6544         * s-expllu.ads, s-expuns.ads, s-expmod.ads: Minor comment fix.
6546 2014-02-25  Pascal Obry  <obry@adacore.com>
6548         * sinput-l.adb, osint.adb, osint.ads: Add Prep_Suffix to factorize code.
6550 2014-02-25  Tristan Gingold  <gingold@adacore.com>
6552         * sem_ch10.adb: Minor comment fix.
6554 2014-02-25  Bob Duff  <duff@adacore.com>
6556         * s-tasdeb.adb: Misc cleanup of this package,
6557         including printing addresses in hexadecimal.
6558         (Write): Fix minor bug when taking 'Address of an empty string.
6560 2014-02-25  Ed Schonberg  <schonberg@adacore.com>
6562         * sem_prag.adb (Analyze_Part_Of): Reject state refinement in a
6563         public child unit when it does not refer to the abstract state
6564         of a public ancestor.
6566 2014-02-25  Yannick Moy  <moy@adacore.com>
6568         * sem_prag.adb (Analyze_Pragma/Pragma_Validity_Checks): Ignore pragma
6569         Validity_Checks in GNATprove and CodePeer modes.
6571 2014-02-25  Pascal Obry  <obry@adacore.com>
6573         * prj-attr.adb, projects.texi, snames.ads-tmpl: Add package Install's
6574         Artifacts attribute.
6576 2014-02-25  Yannick Moy  <moy@adacore.com>
6578         * sem_prag.adb: Minor reformatting to get consistent messages.
6580 2014-02-25  Robert Dewar  <dewar@adacore.com>
6582         * checks.adb: Minor reformatting.
6583         * sinfo.ads (Do_Range_Check): Document that this flag is never
6584         passed to the back end.
6586 2014-02-25  Yannick Moy  <moy@adacore.com>
6588         * sem_ch3.adb, sem_ch5.adb, sem_ch9.adb, sem_prag.adb, sem_attr.adb,
6589         sem_ch6.adb: Remove useless references to SPARK RM in error messages.
6591 2014-02-25  Hristian Kirtchev  <kirtchev@adacore.com>
6593         * sem_res.adb (Appears_In_Check): New routine.
6594         (Resolve_Entity_Name): Remove local variables Prev and
6595         Usage_OK. Par is now a constant. Remove the parent chain traversal
6596         as the placement of a volatile object with enabled property
6597         Async_Writers and/or Effective_Reads must appear immediately
6598         within a legal construct.
6600 2014-02-25  Hristian Kirtchev  <kirtchev@adacore.com>
6602         * checks.adb (Apply_Selected_Range_Checks):
6603         Alphabetize local constants and variables. Add comments.
6604         Always insert a range check that requires runtime evaluation into
6605         the tree.
6607 2014-02-25  Robert Dewar  <dewar@adacore.com>
6609         * sem_attr.adb, sem_ch6.adb, par-ch3.adb: Minor reformatting.
6611 2014-02-25  Bob Duff  <duff@adacore.com>
6613         * s-tassta.adb (Finalize_Global_Tasks): Limit the number of loop
6614         iterations while waiting for independent tasks to terminate;
6615         if an independent task does not terminate, we do not want to
6616         hang here. In that case, the thread will be terminated when the
6617         process exits.
6618         * s-taprop-linux.adb (Abort_Task): Fix Assert to allow for ESRCH.
6620 2014-02-25  Ed Schonberg  <schonberg@adacore.com>
6622         * sem_prag.adb (Check_SPARK_Aspect_For_ASIS): New subprogram,
6623         used to perform pre-analysis of the expression for SPARK
6624         aspects that have a non-standard syntax, such as GLobal and
6625         Initializes. The procedure applies to the original expression
6626         in an aspect specification, prior to the analysis of the
6627         corresponding pragma, in order to provide semantic information
6628         for ASIS navigation purposes.
6629         (Analyze_Global_In_Decl_List, Analyze_Initializes_In_Decl_Part):
6630         Call new subprogram.
6632 2014-02-25  Yannick Moy  <moy@adacore.com>
6634         * sem_prag.adb: Remove obsolete reference to SPARK RM in error message.
6636 2014-02-25  Doug Rupp  <rupp@adacore.com>
6638         * init.c (HAVE_GNAT_ADJUST_CONTEXT_FOR_RAISE): Enable for ARM.
6639         (__gnat_adjust_context_for_raise): Bump the PC by 2.
6641 2014-02-25  Ed Schonberg  <schonberg@adacore.com>
6643         * par-ch3.adb (P_Basic_Declarative_Items): In the case of a
6644         misplaced IS, add a statement sequence to improper body only if
6645         one has not been parsed already.
6647 2014-02-25  Ed Schonberg  <schonberg@adacore.com>
6649         * sem_attr.adb (Analyze_Attribute, case 'Update): Check for
6650         mismatch when multidimensional array is updated with a single
6651         index.
6653 2014-02-25  Yannick Moy  <moy@adacore.com>
6655         * sem_ch3.adb, sem_ch5.adb, sem_prag.adb, sem_attr.adb, errout.ads,
6656         sem_ch6.adb: Mark most references to SPARK RM in error messages
6657         for removal.
6659 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
6661         * par-ch3.adb (P_Basic_Declarative_Items): If an improper body
6662         appears in a list of basic declarations, complete the tree with
6663         an empty statement list, to prevent cascaded errors and crashes
6664         if semantic analysis is attempted.
6666 2014-02-24  Thomas Quinot  <quinot@adacore.com>
6668         * g-sercom-mingw.adb (Open): Fix incorrect test for error return
6669         value.
6670         * erroutc.adb: Minor reformatting.
6672 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
6674         * sem_prag.adb (Check_Clause_Syntax): Account
6675         for a solitary input item in a dependency list.
6677 2014-02-24  Yannick Moy  <moy@adacore.com>
6679         * gnat1drv.adb (Adjust_Global_Switches): Do not
6680         use validity checks at all in GNATprove_Mode.
6682 2014-02-24  Robert Dewar  <dewar@adacore.com>
6684         * g-sercom-mingw.adb, g-sercom-linux.adb, sem_prag.adb, freeze.adb,
6685         atree.adb, atree.ads: Minor reformatting.
6687 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
6689         * sem_ch6.adb (Analyze_Subprogram_Body_Contract): Do not enforce
6690         global and dependence refinement when SPARK_Mode is off.
6691         * sem_ch7.adb (Analyze_Package_Body_Contract): Do not enforce
6692         state refinement when SPARK_Mode is off.
6693         * sem_ch13.adb (Analyze_Aspect_Specifications): Add local
6694         variable Decl. Insert the generated pragma for Refined_State
6695         after a potential pragma SPARK_Mode.
6696         * sem_prag.adb (Analyze_Depends_In_Decl_Part): Add local
6697         constant Deps. Remove local variable Expr. Check the syntax
6698         of pragma Depends when SPARK_Mode is off. Factor out the
6699         processing for extra parenthesis around individual clauses.
6700         (Analyze_Global_In_Decl_List): Items is now a constant. Check
6701         the syntax of pragma Global when SPARK_Mode is off.
6702         (Analyze_Initializes_In_Decl_Part): Check the syntax of pragma
6703         Initializes when SPARK_Mode is off.
6704         (Analyze_Part_Of): Check
6705         the syntax of the encapsulating state when SPARK_Mode is off.
6706         (Analyze_Pragma): Check the syntax of pragma Abstract_State when
6707         SPARK_Mode is off. Move the declaration order check with respect
6708         to pragma Initializes to the end of the processing. Do not verify
6709         the declaration order for pragma Initial_Condition when SPARK_Mode
6710         is off. Do not complain about a useless package refinement when
6711         SPARK_Mode is off.
6712         (Analyze_Refined_Depends_In_Decl_Part): Refs
6713         is now a constant. Check the syntax of pragma Refined_Depends
6714         when SPARK_Mode is off.
6715         (Analyze_Refined_Global_In_Decl_Part):
6716         Check the syntax of pragma Refined_Global when SPARK_Mode is off.
6717         (Analyze_Refined_State_In_Decl_Part): Check the syntax of pragma
6718         Refined_State when SPARK_Mode is off.
6719         (Check_Dependence_List_Syntax): New routine.
6720         (Check_Global_List_Syntax): New routine.
6721         (Check_Initialization_List_Syntax): New routine.
6722         (Check_Item_Syntax): New routine.
6723         (Check_State_Declaration_Syntax): New routine.
6724         (Check_Refinement_List_Syntax): New routine.
6725         (Has_Extra_Parentheses): Moved to the top level of Sem_Prag.
6727 2014-02-24  Robert Dewar  <dewar@adacore.com>
6729         * a-tags.adb, s-os_lib.adb: Minor reformatting.
6731 2014-02-24  Thomas Quinot  <quinot@adacore.com>
6733         * g-sercom-mingw.adb, g-sercom-linux.adb (Raise_Error): Include
6734         strerror message, not just numeric errno value.
6736 2014-02-24  Doug Rupp  <rupp@adacore.com>
6738         * raise-gcc.c (exception_class_eq): Make endian neutral.
6740 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
6742         * atree.ads, atree,adb (Copy_Separate_Tree): Remove Syntax_Only
6743         flag, and reset Etype and Analyzed attributes unconditionally
6744         when copying a tree that may be partly analyzed.
6745         * freeze.adb: Change calls to Copy_Separate_Tree accordingly.
6746         * sem_ch6.adb (Check_Inline_Pragma): If the Inline pragma appears
6747         within a subprogram body and applies to it, remove it from the
6748         body before making a copy of it, to prevent spurious errors when
6749         analyzing the copied body.
6751 2014-02-24  Thomas Quinot  <quinot@adacore.com>
6753         * s-os_lib.adb (Errno_Message): Do not depend on Integer'Image.
6754         * s-oscons-tmplt.c: On VxWorks, include adaint.h only after
6755         vxWorks.h has been included.  Also ensure that file attributes
6756         related definitions are output even in cases where socket support
6757         is not enabled.
6758         * a-tags.adb: Code clean up.
6759         * Make-generated.in (OSCONS_CPP, OSCONS_EXTRACT): Use -iquote
6760         instead of -I to add the main ada source directory to the header
6761         search path, in order to avoid conflict between our own "types.h"
6762         and VxWork's <types.h>.
6764 2014-02-24  Robert Dewar  <dewar@adacore.com>
6766         * atree.ads, atree.adb (Copy_Separate_Tree): Add Syntax_Only parameter.
6767         * debug.adb: Remove documentation of -gnatd.X, no longer used.
6768         * freeze.adb (Wrap_Imported_Subprogram): Fixed and activated.
6770 2014-02-24  Bob Duff  <duff@adacore.com>
6772         * gnat_ugn.texi: Improve documentation of gnatpp.
6774 2014-02-24  Thomas Quinot  <quinot@adacore.com>
6776         * g-stheme.adb, g-socthi-vms.adb, g-socthi-vms.ads,
6777         g-socthi-vxworks.adb, g-socthi-vxworks.ads, g-stseme.adb,
6778         g-socthi-mingw.adb, g-socthi-mingw.ads, g-socthi.adb,
6779         g-socthi.ads, g-socket.adb (Host_Error_Message): Return a string, not
6780         a chars_ptr, because on Windows this is a renaming of
6781         Socket_Error_Message.
6783 2014-02-24  Robert Dewar  <dewar@adacore.com>
6785         * a-direct.adb, sem_ch5.adb, a-cfdlli.adb, a-cfhase.adb, a-tags.adb,
6786         s-filatt.ads, a-cforma.adb, sem_ch6.adb, g-socthi-mingw.adb,
6787         a-cfhama.adb, a-cforse.adb, a-cofove.adb: Minor reformatting and code
6788         reorganization.
6790 2014-02-24  Thomas Quinot  <quinot@adacore.com>
6792         * Make-generated.in (OSCONS_CPP, OSCONS_EXTRACT): Make sure
6793         that the source directory containing s-oscons-tmplt.c is on the
6794         include path, so that all internal header files are available.
6796 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
6798         * sem_ch5.adb (Analyze_Loop_Parameter_Specification): If the
6799         domain of iteration is an attribute reference 'Old, this is an
6800         Ada 2012 iterator and the loop must be rewritten as such.
6802 2014-02-24  Thomas Quinot  <quinot@adacore.com>
6804         * s-fileio.adb (Errno_Message): Remove, use shared version from
6805         s-os_lib instead.
6806         * s-crtrun.ads, Makefile.rtl: Remove now unused unit.
6807         * g-stseme (Socket_Error_Message): Reimplement in terms of new
6808         s-os_lib function.
6809         * g-socthi.ads, g-socthi.adb: Change profile of
6810         Socket_Error_Message to return String to allow the above.
6811         * g-socket.adb, g-socthi-mingw.adb, g-socthi-mingw.ads,
6812         * g-socthi-vms.adb, g-socthi-vms.ads, g-socthi-vxworks.adb,
6813         * g-socthi-vxworks.ads: Update to account for the above profile
6814         change.
6815         * a-tags.adb: Use strlen builtin binding provided by s-crtl.
6816         * s-crtl.ads (strncpy): New procedure.
6817         * s-os_lib.adb (Copy_Attributes): Import just once (strncpy):
6818         Use import from s-crtl.
6819         * a-envvar.adb, osint.adb: Use imports of C runtime functions
6820         from s-crtl instead of re-importing locally.
6822 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
6824         * sem_prag.adb (Analyze_Global_Item): Emit the
6825         variable related checks concerning volatile objects only when
6826         SPARK_Mode is on.
6828 2014-02-24  Robert Dewar  <dewar@adacore.com>
6830         * sem_ch5.adb (Analyze_Iterator_Specification): use
6831         Error_Msg_Ada_2012_Feature.
6833 2014-02-24  Jose Ruiz  <ruiz@adacore.com>
6835         * s-rident.ads (Profile_Info): For Ravenscar, the restrictions
6836         No_Local_Timing_Events and No_Specific_Termination_Handlers
6837         must be set, according to the Ravenscar profile definition
6838         in D.13(6/3).
6840 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
6842         * sem_ch6.adb (Analyze_Expression_Function): If this is a
6843         completion, freeze return type and its designated type if needed.
6845 2014-02-24  Thomas Quinot  <quinot@adacore.com>
6847         * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case
6848         'Address): When moving initialization statements to a freeze
6849         entity, keep them under a single node (i.e. do not unwrap
6850         expressions with actions), and set the Initialization_Statements
6851         attribute again so that processing of a later pragma Import can
6852         still remove them.
6854 2014-02-24  Claire Dross  <dross@adacore.com>
6856         * a-cfdlli.adb, a-cfdlli.ads, a-cfhama.adb, a-cfhama.ads,
6857         a-cfhase.adb, a-cfhase.ads, a-cforma.adb, a-cforma.ads,
6858         a-cforse.adb, a-cforse.ads, a-cofove.adb, a-cofove.ads: Rename
6859         Left/Right to First_To_Previous/Current_To_Last.
6861 2014-02-24  Thomas Quinot  <quinot@adacore.com>
6863         * adaint.h (struct file_attributes): New component "error"
6864         (__gnat_error_attributes): Accessor for the above.
6865         * adaint.c (__gnat_error_attributes): New subprogram
6866         (__gnat_stat): Fix returned value (expect errno value)
6867         (__gnat_stat_to_attr): Add management of error component (set to
6868         stat errno value, except for missing files where it is set to 0,
6869         and exists is set to 0).
6870         * osint.ads (File_Attributes_Size): Update per change above,
6871         also clarify documentation.
6872         * s-filatt.ads: New file, binding to file attributes related
6873         functions.
6874         * Makefile.rtl (s-filatt): New runtime unit.
6875         * s-crtl.ads (strlen): Expose binding to GCC builtin (falls back
6876         to library function if not available on target).
6877         * s-os_lib.ads, s-os_lib.adb (Errno_Message): New subprogram.
6878         * s-oscons-tmplt.c (SIZEOF_struct_file_attributes,
6879         SIZEOF_struct_dirent_alloc): New constants.
6880         * Make-generated.in (s-oscons.ads): Now requires adaint.h.
6881         * a-direct.adb (Fetch_Next_Entry): Fix incorrect buffer sizes.
6882         Perform appropriate error checking if stat fails (do not just
6883         ignore existing files if stat fails)
6884         * gcc-interface/Make-lang.in (GNAT_ADA_OBJS, GNATBIND_OBJS): Update
6885         dependencies.
6887 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
6889         * sem_prag.adb (Analyze_Global_Item): Move the check concerning
6890         the use of volatile objects as global items in a function to
6891         the variable related checks section.
6892         * sem_util.adb (Async_Readers_Enabled): Directly call
6893         Has_Enabled_Property.
6894         (Async_Writers_Enabled): Directly call Has_Enabled_Property.
6895         (Effective_Reads_Enabled): Directly call Has_Enabled_Property.
6896         (Effective_Writes_Enabled): Directly call Has_Enabled_Property.
6897         (Has_Enabled_Property): Rename formal parameter State_Id to Item_Id.
6898         Update the comment on usage. State_Has_Enabled_Property how handles
6899         the original logic of the routine. Add processing for variables.
6900         (State_Has_Enabled_Property): New routine.
6901         (Variable_Has_Enabled_Property): New routine.
6903 2014-02-24  Robert Dewar  <dewar@adacore.com>
6905         * sinfo.ads, sem_ch12.adb, sem_res.adb, sem_ch4.adb, par-ch12.adb:
6906         Minor reformatting.
6907         * atree.ads, atree.adb (Node35): New function.
6908         (Set_Node35): New procedure.
6909         * debug.adb: Define new debug flag -gnatd.X.
6910         * einfo.ads, einfo.adb (Import_Pragma): New field.
6911         * freeze.adb (Wrap_Imported_Procedure): New procedure (not
6912         really active yet, has to be activated with -gnatd.X.
6913         * sem_prag.adb (Set_Imported): Set new Import_Pragma
6914         field (Set_Imported): Don't set Is_Public (see
6915         Freeze.Wrap_Imported_Subprogram)
6916         * par-ch3.adb (P_Component_List): Handle unexpected null component.
6918 2014-02-24  Yannick Moy  <moy@adacore.com>
6920         * sem_ch3.adb: Correct reference to SPARK RM in error messages.
6921         * gnat_rm.texi: Correct documentation of attribute Update.
6923 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
6925         * sem_ch5.adb (Analyze_Iterator_Specification): Reject container
6926         iterator in older versions of Ada.
6928 2014-02-24  Gary Dismukes  <dismukes@adacore.com>
6930         * sem_ch5.adb, sem_aux.ads, sem_ch12.adb, gnat_ugn.texi, par.adb,
6931         par-ch12.adb: Change spelling 'parametrization' to 'parameterization'.
6933 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
6935         * sinfo.ads, sinfo.adb: New attribute Generalized_Indexing, for
6936         indexed_components that are instances of Ada 2012 container
6937         indexing operations. Analysis and resolution of such nodes
6938         is performed on the attribute, and the original source is
6939         preserved for ASIS operations. If expansion is enabled, the
6940         indexed component is replaced by the value of this attribute,
6941         which is in a call to an Indexing aspect, in most case wrapped
6942         in a dereference operation.
6943         * sem_ch4.adb (Analyze_Indexed_Component): Create
6944         Generalized_Indexing attribute when appropriate.
6945         (Analyze_Call): If prefix is not overloadable and has an indexing
6946         aspect, transform into an indexed component so it can be analyzed
6947         as a potential container indexing.
6948         (Analyze_Expression): If node is an indexed component with a
6949         Generalized_ Indexing, do not re-analyze.
6950         * sem_res.adb (Resolve_Generalized_Indexing): Complete resolution
6951         of an indexed_component that has been transformed into a container
6952         indexing operation.
6953         (Resolve_Indexed_Component): Call the above when required.
6954         (Resolve): Do not insert an explicit dereference operation on
6955         an indexed_component whose type has an implicit dereference:
6956         the operation is inserted when resolving the related
6957         Generalized_Indexing.
6959 2014-02-24  Olivier Ramonat  <ramonat@adacore.com>
6961         * gnat_rm.texi, gnat_ugn.texi: Replace Ada Compiler by Ada Development
6962         Environment.
6964 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
6966         * sem_prag.adb (Check_Constituent_Usage): Remove leading spaces in
6967         error messages.
6968         (Inconsistent_Mode_Error): Remove leading spaces in error messages.
6969         Merge the expected and available mode errors.
6970         (Report_Unused_Constituents): Remove leading spaces in error messages.
6971         (Report_Unused_States): Remove leading spaces in error messages.
6973 2014-02-24  Thomas Quinot  <quinot@adacore.com>
6975         * par_sco.adb (Traverse_One): Refine categorization of statement
6976         SCOs.
6978 2014-02-24  Robert Dewar  <dewar@adacore.com>
6980         * aspects.ads, aspects.adb: Remove aspects Ada_2005 and Ada_2012,
6981         Pure_05, Pure_12 and Preelaborate_05.
6982         * gnat_rm.texi: Update accordingly.
6983         * sem_prag.adb: Document one argument form of Ada_05/Ada_2005
6984         pragmas Document one argument form of Ada_12/Ada_2012 pragmas
6985         Recognize one argument form of these pragmas only in GNAT mode
6986         (-gnatg).
6988 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
6990         * s-dimmks.ads: Replace symbol for temperature, previously the
6991         Greek letter Theta, by the ASCII @ sign.
6992         * s-diflio.ads: ditto.
6994 2014-02-24  Robert Dewar  <dewar@adacore.com>
6996         * exp_ch4.adb: Minor code reorganization (use OR for boolean
6997         variables).
6998         * sem_ch3.adb, sem_prag.adb, freeze.adb: Minor reformatting.
7000 2014-02-24  Ben Brosgol  <brosgol@adacore.com>
7002         * gnat_ugn.texi, projects.texi: Added the necessary conditionalization
7003         so that references to gnatmem and ASIS tools do not appear in the FSF
7004         edition of the GNAT User's Guide.
7006 2014-02-24  Yannick Moy  <moy@adacore.com>
7008         * freeze.adb (Freeze_Entity): Do not issue warning
7009         for pre/post being ignored on imported subprogram in GNATprove
7010         mode.
7012 2014-02-24  Robert Dewar  <dewar@adacore.com>
7014         * exp_ch5.adb, sem_ch5.adb, sem_type.adb, sem_res.adb, sem_attr.adb,
7015         stand.ads, sem_eval.adb: Minor reformatting.
7017 2014-02-24  Yannick Moy  <moy@adacore.com>
7019         * sem_prag.adb: Minor rewording in error message.
7021 2014-02-24  Johannes Kanig  <kanig@adacore.com>
7023         * exp_util.adb (Expand_Subtype_From_Expr): Do not expand subtypes in
7024         GNATprove_mode, gnat2why doesn't need nor use these types.
7026 2014-02-24  Gary Dismukes  <dismukes@adacore.com>
7028         * exp_ch4.adb (Expand_N_Op_Expon): On the AAMP
7029         target, in the case of signed integer exponentiation that uses a
7030         run-time routine, always select the Exp_* versions, since overflow
7031         checking is automatically done by AAMP arithmetic instructions.
7033 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
7035         * sem_ch13.adb (Analyze_Aspect_Specifications):
7036         When the related context is a package instace, insert pragma
7037         Abstract_State after all internally-generated renamings related
7038         to the instance "header".
7040 2014-02-24  Ed Schonberg  <schonberg@adacore.com>
7042         * sem_ch3.adb (Analyze_Declarations): Analyze Contract of abstract
7043         subprograms.
7044         * sem_disp.adb (Check_Dispatching_Context): A non-dispatching
7045         call to an abstract subprogram is legal if it appears in a
7046         pre/postcondition of another abstract operation.
7048 2014-02-24  Sergey Rybin  <rybin@adacore.com frybin>
7050         * gnat_ugn.texi: Misc updates.
7052 2014-02-24  Hristian Kirtchev  <kirtchev@adacore.com>
7054         * exp_prag.adb (Expand_Old): Set the type of the generated temporary.
7056 2014-02-24  Gary Dismukes  <dismukes@adacore.com>
7058         * layout.adb (Layout_Variant_Record): Instantiate
7059         Generic_Check_Choices and call Check_Choices before calling
7060         Build_Discr_Checking_Funcs, since we need Others_Discrete_Choices
7061         set to prevent generating incorrect discriminant-checking
7062         functions for 'others' variants (functions that unconditionally
7063         return True rather than accounting for the values covered by the
7064         'others' choice).
7065         * sem_eval.ads (Subtypes_Statically_Compatible): Add formal
7066         Formal_Derived_Matching.
7067         (Subtypes_Statically_Match): Add formal Formal_Derived_Matching.
7068         * sem_eval.adb (Subtypes_Statically_Compatible): Pass new
7069         Formal_Derived_Matching formal to Subtypes_Statically_Match.
7070         (Subtypes_Statically_Match): Suppress the Object_Size matching
7071         test in the case where Formal_Derived_Matching is True.
7072         * sem_ch12.adb (Validate_Derived_Type_Instance): Pass
7073         True for Formal_Derived_Matching_Formal on the call to
7074         Subtypes_Statically_Compatible.
7076 2014-02-23  Eric Botcazou  <ebotcazou@adacore.com>
7078         * gcc-interface/Make-lang.in (ADA_TOOLS_FLAGS_TO_PASS): Robustify.
7080 2014-02-23  Eric Botcazou  <ebotcazou@adacore.com>
7082         * gcc-interface/utils2.c (build_simple_component_ref): Fix formatting.
7083         Look through a conversion between original and packable version to get
7084         the base object.
7085         (build_component_ref): Rework comment and fix formatting.
7087 2014-02-20  Sergey Rybin  <rybin@adacore.com frybin>
7089         * gnat_ugn.texi, vms_data.ads (gnatelim): Add description of
7090         project-specific options.
7092 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
7094         * a-cbdlli.adb (Insert): When capacity exceeded, raise Capacity_Error,
7095         not Constraint_Error.
7096         * a-cbmutr.adb (Append_Child, Insert_Child, Prepend_Child): Ditto.
7097         * sem_ch5.adb: Code clean up.
7099 2014-02-20  Hristian Kirtchev  <kirtchev@adacore.com>
7101         * sem_prag.adb (Usage_Error): Remove local
7102         constant Typ. Remove the specialized diagnostics for unconstrained
7103         or tagged items as those are not part of the explicit input set
7104         of the related subprogram and should not be flagged.
7106 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
7108         * sem_attr.adb: Add guard to preserve all errors.
7110 2014-02-20  Vincent Celier  <celier@adacore.com>
7112         * switch-m.adb (Normalize_Compiler_Switches): Take into account
7113         switches that are recorded in ALI files: -gnateA, -gnateE,
7114         -gnateF, -gnateinn, -gnateu, -gnateV and -gnateY.
7116 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
7118         * sem_ch5.adb (Analyze_Iterator_Specification): Check legality
7119         of an element iterator form over a formal container with an
7120         Iterable aspect.
7121         * exp_ch5.adb (Build_Formal_Container_Iteration): Utility
7122         to create declaration and loop statements for both forms of
7123         container iterators.
7124         (Expand_Formal_Container_Element_Iterator): New procedure
7125         to handle loops of the form  "for E of C" when C is a formal
7126         container.
7127         (Expand_Formal_Container_Iterator): Code cleanup.
7129 2014-02-20  Hristian Kirtchev  <kirtchev@adacore.com>
7131         * sem_prag.adb (Add_Item_To_Name_Buffer): New routine.
7132         (Analyze_Contract_Case): Remove the use of
7133         "may". Replace "aspect Contract_Cases" to avoid categorization
7134         of aspect vs pragma.
7135         (Analyze_External_Property_In_Decl_Part): Remove the use of "formal".
7136         (Analyze_Global_Item): Remove
7137         the use of "formal", specify the subprogram.  Split the
7138         error message about a state with visible refinement into
7139         two. Remove the use of "global" from "volatile global item".
7140         (Analyze_Initialization_Item): Ensure that the SPARK RM reference
7141         is on one line.
7142         (Analyze_Input_Output): Update the call to
7143         Check_Mode. Specify the duplicated item. Reword the error
7144         message concerning an input of a null output list. Use "\"
7145         for error message continuation.
7146         (Analyze_Part_Of): Remove
7147         the use of "may". Use "\" for error message continuation.
7148         (Analyze_Refined_Depends_In_Decl_Part): Update the error
7149         message concerning a useless refinement to match the format
7150         of Refined_Global.
7151         (Analyze_Refined_Global_In_Decl_Part): Reword the error message
7152         concerning a useless refinement.
7153         (Analyze_Refinement_Clause): Use "\" for error message continuation.
7154         (Check_Constituent_Usage): Use "\" for error message continuation.
7155         (Check_Dependency_Clause): Use "\" for error message continuation.
7156         (Check_Matching_Constituent): Use "\" for error message continuation.
7157         (Check_Missing_Part_Of): Use "\" for error message continuation.
7158         (Check_Mode): Renamed to
7159         Check_Role. Update the comment on usage. Redo the error reporting
7160         to use Role_Error.
7161         (Check_Mode_Restriction_In_Enclosing_Context): Use "\" for error
7162         message continuation.
7163         (Find_Mode): Renamed to Find_Role. Update the parameter profile along
7164         with comment on usage. Update all occurrences of Is_Input and Is_Output.
7165         (Inconsistent_Mode_Error): Use "\" for error message continuation.
7166         (Input_Match): Use "\" for error message continuation.
7167         (Role_Error): New routine.
7168         (Set_Convention_From_Pragma): Use "\" for error message continuation.
7169         (Usage_Error): Add local variable Error_Msg. Build specialized error
7170         message showcasing the offending item kind. Redo the diagnostics for
7171         unconstrained types.
7173 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
7175         * exp_util.adb (Is_Iterated_Container): Use high-level primitives
7176         to determine whether a type is a container type, rather than
7177         examining only its type declaration, so that subtypes and derived
7178         types are handled properly.
7180 2014-02-20  Sergey Rybin  <rybin@adacore.com frybin>
7182         * gnat_ugn.texi: gnatmetric: add description of project-specific
7183         options.
7185 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
7187         * sem_attr.adb (Analyze_Attribute, case 'Update): Verify that
7188         all choices in an association for a record type have the same
7189         type, as is done for record aggregates.
7191 2014-02-20  Robert Dewar  <dewar@adacore.com>
7193         * a-cborma.adb, a-cbhama.adb, a-cbdlli.adb, a-cbmutr.adb: Use pragma
7194         Unmodified rather than Warnings (Off). Make comments
7195         uniform in the four affected units.
7197 2014-02-20  Robert Dewar  <dewar@adacore.com>
7199         * sem_ch13.adb (Analyze_Attribute_Definition_Clause, case
7200         Object_Size): For non-scalar types allow any value that is a
7201         multiple of 8.
7202         * gnat_rm.texi: Document Object_Size for composites more clearly.
7204 2014-02-20  Yannick Moy  <moy@adacore.com>
7206         * sem_util.ads, sem_util.adb (Default_Initialization): Remove function.
7208 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
7210         * stand.ads: Raise_Type: new predefined entity, used as the type
7211         of a Raise_Expression prior to resolution.
7212         * cstand.adb: Build entity for Raise_Type.
7213         * sem_ch11.adb (Analyze_Raise_Expression): use Raise_Type as the
7214         initial type of the node.
7215         * sem_type.adb (Covers): Raise_Type is compatible with all
7216         other types.
7217         * sem_res.adb (Resolve): Remove special handling of Any_Type on
7218         Raise_Expression nodes.
7219         (Resolve_Raise_Expression): Signal ambiguity if the type of the
7220         context is still Raise_Type.
7222 2014-02-20  Robert Dewar  <dewar@adacore.com>
7224         * sem_ch12.adb (Validate_Access_Type_Instance): Add message if
7225         mismatching predicates.
7226         * sem_ch6.adb (Check_Conformance): Give better messages on
7227         predicate mismatch.
7228         * sem_eval.adb (Predicates_Match): Move to spec.
7229         * sem_eval.ads (Predicates_Match): Moved here from body.
7231 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
7233         * a-cbmutr.adb: Use default value in Insert_Child.
7235 2014-02-20  Vincent Celier  <celier@adacore.com>
7237         * gnatcmd.adb, make.adb, prj-makr.adb, clean.adb: Call
7238         Stringt.Initialize in all project aware tools.
7240 2014-02-20  Doug Rupp  <rupp@adacore.com>
7242         * gnat_ugn.texi: Document gnatbind -X option.
7243         * vms_data.ads: Minor warnings documentation reformatting.
7245 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
7247         * exp_ch3.adb (Expand_Freeze_Array_Type): Only create invariant
7248         procedure for a base type.
7250 2014-02-20  Robert Dewar  <dewar@adacore.com>
7252         * sem_ch4.adb (Analyze_Case_Expression): Get type from first
7253         expression with type info.
7254         * sem_ch13.adb: Minor reformatting.
7255         * sem_eval.adb (Subtypes_Statically_Match): Make sure we return
7256         False if predicates do not match on the two types.
7258 2014-02-20  Arnaud Charlet  <charlet@adacore.com>
7260         * sem_prag.adb (Analyze_Pragma [pragma Attach_Handler]):
7261         In Relaxed_RM_Semantics mode, allow any static integer value,
7262         for compatibility with other compilers.
7264 2014-02-20  Vincent Celier  <celier@adacore.com>
7266         * errutil.adb (Initialize): Properly initialize entry in table
7267         Warnings when warnings are suppressed.
7269 2014-02-20  Robert Dewar  <dewar@adacore.com>
7271         * s-os_lib.ads: Add warning about non-portability of Rename_File.
7272         * sem_util.ads, sem_util.adb (Is_Junk_Name): New function.
7273         * sem_warn.adb: Use Is_Junk_Name to suppress some warnings.
7274         * gnat_ugn.texi: Document no warnings on junk variable names.
7275         * layout.adb: Minor code reorganization (use Ekind_In).
7276         * stringt.adb: Move initialization of Null_String_Id to Initialize
7277         routine.
7279 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
7281         * sem_ch13.adb: Initialize optional Element_Id.
7283 2014-02-20  Robert Dewar  <dewar@adacore.com>
7285         * s-os_lib.ads (Rename_File): Minor commment addition.
7287 2014-02-20  Thomas Quinot  <quinot@adacore.com>
7289         * einfo.ads: Minor reformatting.
7291 2014-02-20  Hristian Kirtchev  <kirtchev@adacore.com>
7293         * aspects.adb (Exchange_Aspects): New routine.
7294         * aspects.ads (Exchange_Aspects): New routine.
7295         * atree.adb (Rewrite): Do not check whether the save node has
7296         aspects as it never will, instead check the node about to be clobbered.
7297         * einfo.adb (Write_Field25_Name): Abstract_States can appear in
7298         entities of generic packages.
7299         * sem_ch6.adb (Analyze_Expression_Function): Fix the parent
7300         pointer of an aspect specification list after rewriting takes place.
7301         * sem_ch7.adb (Analyze_Package_Body_Helper): Swap the aspect
7302         specifications of the generic template and the copy used for analysis.
7303         * sem_ch12.adb (Analyze_Generic_Package_Declaration): Swap
7304         the aspect specifications of the generic template and the
7305         copy used for analysis.
7306         (Analyze_Package_Instantiation): Propagate the aspect specifications
7307         from the generic template to the instantiation.
7308         (Build_Instance_Compilation_Unit_Nodes): Propagate the aspect
7309         specifications from the generic template to the instantiation.
7310         * sem_ch13.adb (Analyze_Aspect_Specifications): Handle aspects
7311         Abstract_State, Initializes and Initial_Condition when they
7312         apply to a package instantiation.
7314 2014-02-20  Robert Dewar  <dewar@adacore.com>
7316         * stringt.adb: Add call to Initialize in package initialization.
7318 2014-02-20  Robert Dewar  <dewar@adacore.com>
7320         * a-crbtgk.adb, a-cihama.adb, a-coinve.adb, a-ciorse.adb, a-crbtgo.adb,
7321         a-cidlli.adb, a-cimutr.adb, a-cihase.adb, a-cohama.adb, a-coorse.adb,
7322         a-chtgke.adb, a-chtgop.adb, a-comutr.adb, a-ciorma.adb, a-cobove.adb,
7323         a-convec.adb, a-cohase.adb, a-chtgbk.adb, a-chtgbo.adb: Minor
7324         reformatting.
7326 2014-02-20  Bob Duff  <duff@adacore.com>
7328         * s-os_lib.ads: Minor: Remove incorrect comment.
7330 2014-02-20  Robert Dewar  <dewar@adacore.com>
7332         * sem_elab.adb (Check_Elab_Assign): Clearer warning message.
7334 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
7336         * a-cborma.adb (Assign): When creating a node without a specified
7337         element, insert an uninitialized element in the map, because
7338         the instance may provide an element type with a default
7339         initialization, e.g a scalar with a Default_Value aspect.
7340         * a-cbhama.adb (Assign_Key): Remove useless Allocate procedure.
7341         (Insert): In the version without explicit element, provide an
7342         uninitialized element, as above.
7343         * a-cbdlli.adb (Append): In the version without explicit element,
7344         provide an uninitalized element, as above.
7345         (Allocate): Remove unused version.
7347 2014-02-20  Robert Dewar  <dewar@adacore.com>
7349         * sem_elab.adb: Minor code reorganization (use Nkind_In).
7350         * stringt.adb: Remove temporary pragma Warnings (Off).
7351         * stringt.ads: Add pragma Elaborate_Body to ensure initialization
7352         of Null_String_Id.
7354 2014-02-20  Matthew Heaney  <heaney@adacore.com>
7356         * a-chtgbk.adb (Replace): Use correct offset when calculating bucket
7357         index.
7359 2014-02-20  Ed Schonberg  <schonberg@adacore.com>
7361         * sem_ch5.adb (Analyze_Iterator_Specification): Initialize
7362         properly the cursor type for subsequent volatile testing in SPARK
7363         mode, when domain is a formal container with an Iterabe aspect.
7365 2014-02-20  Robert Dewar  <dewar@adacore.com>
7367         * errout.adb (Set_Warnings_Mode_Off): Add Reason argument.
7368         (Set_Specific_Warning_Off): Add Reason argument.
7369         * errout.ads (Set_Warnings_Mode_Off): Add Reason argument.
7370         (Set_Specific_Warning_Off): Add Reason argument.
7371         * erroutc.adb (Warnings_Entry): Add Reason field
7372         (Specific_Warning_Entry): Add Reason field.
7373         (Warnings_Suppressed): return String_Id for Reason.
7374         (Warning_Specifically_Suppressed): return String_Id for Reason.
7375         * erroutc.ads (Warnings_Entry): Add Reason field.
7376         (Specific_Warning_Entry): Add Reason field.
7377         (Set_Specific_Warning_Off): Add Reason argument.
7378         (Set_Warnings_Mode_Off): Add Reason argument.
7379         (Warnings_Suppressed): return String_Id for Reason.
7380         (Warning_Specifically_Suppressed): return String_Id for Reason.
7381         * errutil.adb (Warnings_Suppressed): returns String_Id for Reason
7382         (Warning_Specifically_Suppressed): returns String_Id for Reason
7383         * gnat_rm.texi: Document that Warning parameter is string literal
7384         or a concatenation of string literals.
7385         * par-prag.adb: New handling for Reason argument.
7386         * sem_prag.adb (Analyze_Pragma, case Warning): New handling
7387         for Reason argument.
7388         * sem_util.ads, sem_util.adb (Get_Reason_String): New procedure.
7389         * sem_warn.ads (Warnings_Off_Entry): Add reason field.
7390         * stringt.adb: Set Null_String_Id.
7391         * stringt.ads (Null_String_Id): New constant.
7393 2014-02-20  Robert Dewar  <dewar@adacore.com>
7395         * einfo.ads: Minor comment addition: Etype of package is
7396         Standard_Void_Type.
7397         * checks.adb, exp_aggr.adb, exp_atag.adb, exp_attr.adb, exp_ch13.adb,
7398         exp_ch2.adb, exp_ch3.adb, exp_ch4.adb, exp_ch5.adb, exp_ch6.adb,
7399         exp_ch7.adb, exp_ch9.adb, exp_dbug.adb, exp_disp.adb, exp_imgv.adb,
7400         exp_intr.adb, exp_prag.adb, exp_sel.adb, exp_strm.adb, exp_util.adb,
7401         freeze.adb, rtsfind.adb, sem_aggr.adb, sem_attr.adb, sem_ch10.adb,
7402         sem_ch12.adb, sem_ch13.adb, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb,
7403         sem_ch6.adb, sem_ch8.adb, sem_dim.adb, sem_prag.adb, sem_res.adb,
7404         sem_util.adb, tbuild.adb, tbuild.ads: Remove New_Reference_To.
7405         Replace all calls with calls to New_Occurrence_Of.
7407 2014-02-20  Robert Dewar  <dewar@adacore.com>
7409         * par-util.adb (Ignore, case of right paren): Make this a
7410         serious error.
7412 2014-02-19  Robert Dewar  <dewar@adacore.com>
7414         * sem_ch5.adb, sem_prag.adb, sem_attr.adb: Minor reformatting.
7415         * debug.adb: Remove -gnatd.X switch, no longer used.
7416         * styleg.adb (Check_Then): Remove check of -gnatd.X, check is
7417         now always made.
7419 2014-02-19  Bob Duff  <duff@adacore.com>
7421         * g-socket.ads: Minor: Correct some comments.
7423 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7425         * sem_ch5.adb: Inhibit iterator rewriting in ASIS mode.
7427 2014-02-19  Arnaud Charlet  <charlet@adacore.com>
7429         * sem_ch13.adb (Analyze_Aspect_Specifications): Do not generate
7430         an error on out of range priorities if Relaxed_RM_Semantics.
7431         * sem_prag.adb (Analyze_Pragma): Ditto.
7433 2014-02-19  Bob Duff  <duff@adacore.com>
7435         * sem_attr.adb (Resolve_Attribute): Detect the case of F'Access
7436         where F denotes the renaming of an enumeration literal, and
7437         issue a specialized error message.
7439 2014-02-19  Matthew Heaney  <heaney@adacore.com>
7441         * a-chtgop.ads (Checked_Index): New operation.
7442         (Next): Changed mode of hash table.
7443         * a-chtgop.adb (Adjust, Delete_Node_Sans_Free): Detect tampering
7444         (Generic_Read, Reserve_Capacity): Ditto.
7445         (Generic_Equal): Detect tampering.
7446         (Next): Changed mode of hash table, detect tampering.
7447         * a-chtgke.ads (Checked_Index, Checked_Equivalent_Keys): New
7448         operation.
7449         (Find): Changed mode of hash table.
7450         * a-chtgke.adb (Checked_Equivalent_Keys): New operation
7451         (Delete_Key_Sans_Free, Generic_Conditional_Insert): Detect
7452         tampering.
7453         (Find): Changed mode of hash table, check for tampering.
7454         (Generic_Replace_Element): Check for tampering.
7455         * a-chtgbk.ads (Checked_Index, Checked_Equivalent_Keys): New operation.
7456         * a-chtgbk.adb (Checked_Index, Checked_Equivalent_Keys): New
7457         operation (Delete_Key_Sans_Free, Generic_Conditional_Insert):
7458         Detect tampering.
7459         (Find, Generic_Replace_Element): Check for tampering.
7460         * a-chtgbo.ads (Checked_Index): New operation.
7461         * a-chtgbo.adb (Checked_Index): New operation
7462         (Delete_Node_Sans_Free, Generic_Equal): Detect tampering.
7463         (Generic_Read, Next): Ditto.
7464         * a-cohase.adb, a-cihase.adb (Is_In): Changed mode of hash
7465         table (Difference, Intersection): Use variable view of
7466         source, detect tampering (Find, Is_Subset, Overlap): Use
7467         variable view of container (Symmetric_Difference, Union):
7468         Detect tampering (Vet): Use Checked_Index to detect tampering
7469         (Constant_Reference, Element, Find): Use variable view of
7470         container.
7471         (Update_Element_Preserving_Key): Detect tampering.
7472         * a-cbhase.adb (Difference, Find, Is_In): Use variable view
7473         of container.
7474         (Is_Subset): Ditto.
7475         (Equivalent_Sets, Overlap): Use Node's Next component.
7476         (Vet): Use Checked_Index to detect tampering.
7477         (Constant_Reference, Element, Find): Use variable view of container.
7478         (Update_Element_Preserving_Key): Detect tampering.
7479         * a-cohama.adb, a-cihama.adb, a-cbhama.adb (Constant_Reference,
7480         Element, Find): Use variable view of container.
7481         (Reference): Rename hash table component.
7482         (Vet): Use Checked_Index to detect tampering.
7484 2014-02-19  Arnaud Charlet  <charlet@adacore.com>
7486         * adabkend.adb (Scan_Compiler_Arguments): Add missing handling
7487         of -nostdinc.
7489 2014-02-19  Thomas Quinot  <quinot@adacore.com>
7491         * tbuild.adb (New_Occurrence_Of, New_Rerefence_To): Guard
7492         against calls without Def_Id.
7494 2014-02-19  Claire Dross  <dross@adacore.com>
7496         * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads, a-cforse.ads,
7497         a-cofove.ads: Add global annotations to subprograms.
7499 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
7501         * sem_prag.adb (Analyze_Initial_Condition_In_Decl_Part): Remove
7502         constants Errors, Pack_Id and Pack_Init. Remove variable Vars.
7503         Initial_Condition no longer requires the presence of pragma
7504         Initialized. Do not try to diagnose whether all variables mentioned in
7505         pragma Initializes also appear in Initial_Condition.
7506         (Collect_Variables): Removed.
7507         (Match_Variable): Removed.
7508         (Match_Variables): Removed.
7509         (Report_Unused_Variables): Removed.
7511 2014-02-19  Thomas Quinot  <quinot@adacore.com>
7513         * gnat_rm.texi (pragma Stream_Convert): Minor rewording.
7515 2014-02-19  Robert Dewar  <dewar@adacore.com>
7517         * sem_util.adb, sem_util.ads, prj-conf.adb, s-os_lib.adb: Minor
7518         reformatting.
7520 2014-02-19  Vincent Celier  <celier@adacore.com>
7522         * prj-part.adb (Parse_Single_Project): Use the fully resolved
7523         project path, with all symbolic links resolved, to check if the
7524         same project is imported with a different unresolved path.
7525         * prj-tree.ads (Project_Name_And_Node): Component Canonical_Path
7526         changed to Resolved_Path to reflect that all symbolic links
7527         are resolved.
7529 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7531         * sem_util.ads, sem_util.adb (Get_Cursor_Type): Moved to sem_util
7532         from sem_ch13, for use elsewhere.
7533         * sem_ch13.adb (Get_Cursor_Type): Moved to sem_util.
7534         * sem_ch5.adb (Analyze_Iterator_Specification): Set properly the
7535         cursor type on the loop variable when the iteration is over o
7536         formal container.
7538 2014-02-19  Vincent Celier  <celier@adacore.com>
7540         * prj-conf.adb (Add_Default_GNAT_Naming_Scheme): Add declaration
7541         for an empty Target (Check_Target): Never fail when an empty
7542         target is declared in the configuration project.
7544 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7546         * sem_prag.adb (Check_Arg_Is_Local_Name): Argument is local if
7547         the pragma comes fron a predicate aspect and the context is a
7548         record declaration within the scope that declares the type.
7550 2014-02-19  Robert Dewar  <dewar@adacore.com>
7552         * gnat_rm.texi: Minor clarifications.
7553         * expander.adb, sem_aggr.adb: Add comments.
7555 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7557         * sem_prag.adb (Check_Arg_Is_Local_Name): For an aspect that
7558         applies to a subprogram body, the name is the current scope,
7559         rather than being declared in the current scope.
7560         (Analyze_Pragma, case No_Return): Handle properly a No_Return
7561         aspect applied to a subprogram body.
7563 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7565         * sem_ch13.adb (Resolve_Iterable_Operation): Improve resolution
7566         of overloaded subprograms, and fix bug in handling of primitive
7567         operation Element.
7569 2014-02-19  Pascal Obry  <obry@adacore.com>
7571         * s-os_lib.adb: Minor reformatting.
7573 2014-02-19  Yannick Moy  <moy@adacore.com>
7575         * expander.adb (Expand): Do nothing inside generics.
7576         * sem_aggr.adb (Aggregate_Constraint_Checks): Do nothing inside
7577         generics.
7579 2014-02-19  Yannick Moy  <moy@adacore.com>
7581         * exp_ch2.adb: Remove useless 'with' of unit Uintp.
7583 2014-02-19  Robert Dewar  <dewar@adacore.com>
7585         * sem_ch3.adb, style.adb, sem_prag.adb, sem_ch13.adb: Minor reformatting
7586         * a-sequio.adb: Remove useless pragma Extensions_Allowed (no
7587         longer needed).
7589 2014-02-19  Claire Dross  <dross@adacore.com>
7591         * a-cfdlli.ads, a-cfhase.ads, a-cforma.ads, a-cfhama.ads,
7592         a-cforse.ads, a-cofove.ads: Add Iterable aspect to formal containers.
7594 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
7596         * sem_ch3.adb (Analyze_Declarations): Analyze
7597         a package contract at the end of the private declarations (if
7598         applicable), otherwise analyze it and the end of the visible
7599         declarations.
7601 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7603         * style.adb (Missing_Overriding): If subprogram is an
7604         instantiation, place warning on the instance node itself,
7605         without mention of the original generic. Do not emit message
7606         if explicit Ada version is older than the introduction of the
7607         overriding indicator.
7609 2014-02-19  Yannick Moy  <moy@adacore.com>
7611         * gnat_rm.texi: Doc clarifications.
7613 2014-02-19  Yannick Moy  <moy@adacore.com>
7615         * exp_util.adb (Remove_Side_Effects): Do not remove side-effects
7616         inside a generic.
7618 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7620         * sem_ch13.adb (Get_Cursor_Type): Obtain cursor type from
7621         specified First primitive, rather than by name.
7622         (Validate_Iterable_Aspect, Resolve_Iterable_Operation): Use it,
7623         and extend error checking for missing primitives and incorrect
7624         signatures.
7626 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7628         * sem_ch3.adb (Check_Pragma_Implemented): Detect additional
7629         errors when a Synchronization aspect on an overriding protected
7630         operation does not match the given aspect on the overridden
7631         operation of an ancestor interface.
7633 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
7635         * sem_prag.adb (Check_Loop_Pragma_Grouping): New routine.
7636         (Check_Loop_Pragma_Placement): Update
7637         comment on usage. Remove local variables Orig_Stmt and
7638         Within_Same_Sequence. Check that the current Loop_Invariant or
7639         Loop_Variant pragma is grouped together with other such pragmas.
7640         (Is_Loop_Pragma): New routine.
7641         (Prev_In_Loop): Removed.
7643 2014-02-19  Robert Dewar  <dewar@adacore.com>
7645         * par-ch6.adb (P_Return): For extended return, end column lines
7646         up with RETURN.
7647         * par.adb: Minor documentation clarification.
7649 2014-02-19  Yannick Moy  <moy@adacore.com>
7651         * sem_prag.adb (Check_Loop_Pragma_Placement): Add check
7652         that Loop_Invariant and Loop_Variant appear consecutively.
7653         * gnat_rm.texi Update documentation of Loop_Invariant and
7654         Loop_Variant pragmas.
7656 2014-02-19  Robert Dewar  <dewar@adacore.com>
7658         * debug.adb: Document -gnatd.X.
7659         * par-ch5.adb (P_If_Statement): Always check THEN, even if not
7660         first token
7661         (Check_Then_Column): Ditto.
7662         * styleg.adb (Check_Then): Allow THEN on line after IF.
7663         (Check_Then): Check THEN placement under control of -gnatd.X
7664         * styleg.ads (Check_Then): Now called even if THEN is not first
7665         token on line.
7666         * stylesw.ads (Style_Check_If_Then_Layout): Document new
7667         relaxed rules.
7668         * gnat_ugn.texi: For -gnatyi, THEN can now be on line after IF.
7670 2014-02-19  Robert Dewar  <dewar@adacore.com>
7672         * a-cfhama.adb, a-cfhase.adb, a-cforse.adb, a-cofove.adb, a-ngcefu.adb,
7673         a-teioed.adb, a-wtedit.adb, a-ztedit.adb, exp_ch5.adb, inline.adb,
7674         prj-pp.adb, prj-tree.adb, sem_ch12.adb, sem_ch8.adb,
7675         vms_conv.adb: Fix bad layout of IF statements
7677 2014-02-19  Robert Dewar  <dewar@adacore.com>
7679         * exp_util.adb (Side_Effect_Free): Scalar if expressions can be SEF.
7681 2014-02-19  Robert Dewar  <dewar@adacore.com>
7683         * exp_util.adb: Update comments.
7685 2014-02-19  Doug Rupp  <rupp@adacore.com>
7687         * bindgen.adb (Gen_Adainit) [VMS] New global Float_Format.
7688         * init.c (__gl_float_format): [VMS] New global.
7689         (__gnat_set_features): Call FP_CONTROL to set FPSR for the float
7690         representation in effect.
7692 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
7694         * exp_ch6.adb Add with and use clause for Exp_Prag.
7695         (Expand_Contract_Cases): Relocated to Exp_Prag.
7696         * exp_ch6.ads (Expand_Contract_Cases): Relocated to Exp_Prag.
7697         * exp_prag.adb Add with and use clauses for Checks and Validsw.
7698         (Expand_Contract_Cases): Relocated from Exp_Ch6. Update the
7699         structure of the expanded code to showcase the evaluation of
7700         attribute 'Old prefixes. Add local variable Old_Evals. Expand
7701         any attribute 'Old references found within a consequence. Add
7702         circuitry to evaluate the prefixes of attribute 'Old that
7703         belong to a selected consequence.
7704         (Expand_Old_In_Consequence): New routine.
7705         * exp_prag.ads (Expand_Contract_Cases): Relocated from Exp_Ch6.
7706         * sem_attr.adb (Check_Use_In_Contract_Cases): Warn that a
7707         potentially unevaluated prefix is always evaluated.
7709 2014-02-19  Robert Dewar  <dewar@adacore.com>
7711         * exp_attr.adb (Expand_Min_Max_Attribute): Use Insert_Declaration
7712         (Expand_Min_Max_Attribute): Use Matching_Standard_Type.
7713         * exp_ch4.adb (Expand_N_Expression_With_Actions): Remove special
7714         handling for the case of Modify_Tree_For_C, this approach did
7715         not work.
7716         * exp_util.adb (Matching_Standard_Type): New function
7717         (Side_Effect_Free): New top level functions (from
7718         Remove_Side_Effects).
7719         * exp_util.ads (Side_Effect_Free): New top level functions
7720         (moved from body).
7721         * sinfo.ads: Minor comment updates.
7723 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7725         * exp_ch6.adb (Expand_Simple_Function_Return): If return
7726         type is unconstrained and uses the secondary stack, mark the
7727         enclosing function accordingly, to ensure that the value is not
7728         prematurely removed.
7730 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
7732         * par.adb Alphabetize the routines in Par.Sync.
7733         (Resync_Past_Malformed_Aspect): New routine.
7734         * par-ch13.adb (Get_Aspect_Specifications): Alphabetize local
7735         variables. Code and comment reformatting. Detect missing
7736         parentheses on aspects [Refined_]Global and [Refined_]Depends
7737         with a non-null definition.
7738         * par-sync.adb: Alphabetize all routines in this separate unit.
7739         (Resync_Past_Malformed_Aspect): New routine.
7741 2014-02-19  Robert Dewar  <dewar@adacore.com>
7743         * sem_eval.ads, sem_eval.adb (Subtypes_Statically_Match): Return False
7744         if Esize values do not match.
7746 2014-02-19  Yannick Moy  <moy@adacore.com>
7748         * sinfo.ads: Minor comment update.
7750 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
7752         * atree.ads: Minor reformatting (change Entity_Info to Einfo).
7754 2014-02-19  Thomas Quinot  <quinot@adacore.com>
7756         * exp_ch7.adb (Find_Node_To_Be_Wrapped): An assignment statement
7757         that has the No_Ctrl_Actions flag is a suitable node to be
7758         wrapped if the assigned expression has no finalization actions.
7759         * sem_eval.adb (Eval_Entity_Name): For a compile time known
7760         boolean value, mark the corresponding condition SCO as constant.
7762 2014-02-19  Robert Dewar  <dewar@adacore.com>
7764         * exp_util.adb: Minor reformatting.
7765         * exp_util.ads (Matching_Standard_Type): New function.
7766         * exp_ch7.adb: Minor reformatting.
7768 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7770         * sem_ch13.adb (Get_Cursor_Type): Use scope of iterable type
7771         to find declaration for Cursor, to handle properly the case of
7772         a discriminated iterable type.
7774 2014-02-19  Vincent Celier  <celier@adacore.com>
7776         * gnatcmd.adb (GNATCmd): Always replace the object dirs of
7777         imported library projects with the library ALI dirs, when setting
7778         the object paths.
7779         * prj-env.ads (Ada_Objects_Path): Correct comments about
7780         argument Including_Libraries.
7782 2014-02-19  Gary Dismukes  <dismukes@adacore.com>
7784         * gnat_rm.texi: Minor spelling fixes.
7786 2014-02-19  Doug Rupp  <rupp@adacore.com>
7788         * init.c: Remove unneeded code.
7789         * fe.h (Float_Format): New macro
7790         * gcc-interface/trans.c (gigi): On VMS, set vms_float_format.
7792 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
7794         * sem_prag.adb (Check_Refined_Global_Item):
7795         A state or variable acts as a constituent only it is part of an
7796         encapsulating state and the state has visible refinement.
7798 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7800         * sem_ch6.adb (Analyze_Subprogram_Contract): Do not warn on a
7801         postcondition for a function when the expression does not mention
7802         'Result but the function has in-out parameters.
7804 2014-02-19  Robert Dewar  <dewar@adacore.com>
7806         * gnat_rm.texi: Add documentation on Value_Size forcing biased
7807         representation.
7809 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
7811         * lib-xref.ads Remove the small table of letter and symbol usage as we
7812         already have one.
7814 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
7816         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Emit specific error
7817         messages depending on the offending misplaced aspect specifications.
7818         (Diagnose_Misplaced_Aspect_Specifications): New routine.
7820 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7822         * sem_ch13.adb (Get_Cursor): Utility to retrieve cursor type
7823         for iterable aspect primitives.
7824         (Resolve_Iterable_Operation): Use expected signature of iterable
7825         aspect to resolve primitive when overloading is present.
7826         (Validate_Iterable_Aspect, Analyze_Aspects_At_Freeze_Point): use it.
7827         (Check_Signature): Removed.
7829 2014-02-19  Yannick Moy  <moy@adacore.com>
7831         * sem_ch10.adb (Analyze_Proper_Body): Issue error on missing
7832         subunit in GNATprove_Mode.
7833         * sinfo.ads (GNATprove_Mode): Document error issued in GNATprove_Mode.
7835 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
7837         * lib-xref.ads Alphabetize the contents of table
7838         Xref_Entity_Letters. Add an entry in table Xref_Entity_Letters
7839         for E_Abstract_State. List all letters and symbols in use.
7840         * sem_prag.adb (Analyze_Abstract_State): Update all calls
7841         to Create_Abstract_State to reflect the new signature.
7842         (Create_Abstract_State): Change subprogram profile and update
7843         the comment on usage. Use the proper location of the state
7844         declaration when creating a new abstract state entity. Do not
7845         generate an external name, but simply reuse the name coming from
7846         the state declaration.
7848 2014-02-19  Robert Dewar  <dewar@adacore.com>
7850         * exp_ch4.adb (Expand_N_Expression_With_Actions): Make sure
7851         declarations get properly inserted in Modify_Tree_For_C mode.
7852         * sinfo.ads: Minor comment addition.
7854 2014-02-19  Robert Dewar  <dewar@adacore.com>
7856         * par-ch9.adb, exp_ch5.adb, sem_ch5.adb, exp_attr.adb, sem_util.adb,
7857         sem_util.ads, sem_ch13.adb, sem_ch13.ads: Minor reformatting.
7859 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7861         * style.adb (Missing_Overriding): Warning does not apply in
7862         language versions prior to Ada 2005.
7863         * snames.ads-tmpl: Add Name_Iterable and Attribute_Iterable.
7864         * sem_attr.adb: Add Attribute_Iterable where needed.
7865         * exp_attr.adb: ditto.
7866         * exp_ch5.adb (Expand_Formal_Container_Loop): New procedure to
7867         handle loops and quantified expressions over types that have an
7868         iterable aspect.  Called from Expand_Iterator_Loop.
7869         * sem_ch5.adb (Analyze_Iterator_Specification): Recognize types
7870         with Iterable aspect.
7871         * sem_ch13.adb (Validate_Iterable_Aspect): Verify that the
7872         subprograms specified in the Iterable aspect have the proper
7873         signature involving container and cursor.
7874         (Check_Aspect_At_Freeze_Point): Analyze value of iterable aspect.
7875         * sem_ch13.ads (Validate_Iterable_Aspect): New subprogram.
7876         * sem_util.ads, sem_util.adb (Get_Iterable_Type_Primitive):
7877         New procedure to retrieve one of the primitives First, Last,
7878         or Has_Element, from the value of the iterable aspect of a
7879         formal container.
7880         (Is_Container_Element): Predicate to recognize expressions
7881         that denote an element of one of the predefined containers,
7882         for possible optimization.  This subprogram is not currently
7883         used, pending ARG discussions on the legality of the proposed
7884         optimization. Worth preserving for eventual use.
7885         (Is_Iterator): Recognize formal container types.
7886         * aspects.ads, aspects.adb: Add Aspect_Iterable where needed.
7888 2014-02-19  Robert Dewar  <dewar@adacore.com>
7890         * exp_attr.adb (Expand_Min_Max_Attribute): New procedure
7891         (Expand_N_Attribute_Reference): Use this procedure for Min and Max.
7892         * exp_ch4.adb (Expand_N_Expression_With_Actions): Remove object
7893         declarations from list of actions.
7894         * output.ads, output.adb (Delete_Last_Char): New procedure.
7895         * sinfo.ads: Document handling of Mod and expression with actions
7896         in Modify_Tree_For_C mode.
7898 2014-02-19  Ed Schonberg  <schonberg@adacore.com>
7900         * par-ch9.adb (P_Task): Add a null statement to produce a
7901         well-formed task body when due to a previous syntax error the
7902         statement list is empty.
7904 2014-02-19  Hristian Kirtchev  <kirtchev@adacore.com>
7906         * sem_prag.adb (Check_Dependency_Clause): Account
7907         for the case where a state with a non-null refinement matches a
7908         null output list. Comment reformatting.
7909         (Inputs_Match): Copy a solitary input to avoid an assertion failure
7910         when trying to match the same input in multiple clauses.
7912 2014-02-19  Gary Dismukes  <dismukes@adacore.com>
7914         * sem_attr.adb: Minor typo fix.
7916 2014-02-18  Robert Dewar  <dewar@adacore.com>
7918         * cstand.adb (Build_Signed_Integer_Type): Minor change of formal
7919         from Int to Nat (Build_Unsigned_Integer_Type): New procedure
7920         (Create_Standard): Create new unsigned types.
7921         * exp_ch4.adb (Expand_N_Op_Mod): Expand mod in Modify_Tree_For_C
7922         mode (Expand_N_Reference): Removed, problematic and not needed
7923         for now.
7924         * exp_ch4.ads (Expand_N_Reference): Removed, problematic and
7925         not needed for now.
7926         * exp_util.ads, exp_util.adb (Power_Of_Two): New function.
7927         * expander.adb: Remove call to Expand_N_Reference (problematic,
7928         and not needed now).
7929         * sem_aux.ads, sem_aux.adb (Corresponding_Unsigned_Type): New function.
7930         * stand.adb: Read and write unsigned type entities.
7931         * stand.ads: Add new unsigned types.
7933 2014-02-18  Hristian Kirtchev  <kirtchev@adacore.com>
7935         * sem_ch4.adb (Analyze_Call): Do not mark a function call
7936         as being inside an assertion expression as the flag is now removed.
7937         (Check_Ghost_Subprogram_Call): Do not query the
7938         In_Assertion_Expression flag as it is now removed, instead use
7939         a predicate function.
7940         * sem_elab.adb (Check_Internal_Call_Continue): Do not query the
7941         In_Assertion_Expression flag as it is now removed, instead use
7942         a predicate function.
7943         * sem_prag.ads: Add new table Assertion_Expression_Pragma.
7944         * sem_util.adb Add with and use clause for Sem_Prag.
7945         (In_Assertion_Expression_Pragma): New routine.
7946         * sem_util.ads (In_Assertion_Expression_Pragma): New routine.
7947         * sinfo.adb (In_Assertion_Expression): Removed.
7948         (Set_In_Assertion_Expression): Removed.
7949         * sinfo.ads Remove flag In_Assertion_Expression along with its
7950         use in nodes.
7951         (In_Assertion_Expression): Removed along with
7952         pragma Inline.  (Set_In_Assertion_Expression): Removed along
7953         with pragma Inline.
7955 2014-02-18  Sergey Rybin  <rybin@adacore.com frybin>
7957         * gnat_ugn.texi: gnatpp section: add note that '-j' cannot be
7958         used together with '-r', '-rf' or '-rnb' options.
7960 2014-02-18  Hristian Kirtchev  <kirtchev@adacore.com>
7962         * sem_attr.adb (Analyze_Attribute): Comment
7963         and code reformatting. Use separate routines to check the
7964         legality of attribute 'Old in certain pragmas. Verify
7965         the use of 'Old, 'Result and locally declared entities
7966         within the prefix of 'Old.
7967         (Check_References_In_Prefix): New routine.
7968         (Check_Use_In_Contract_Cases): New routine.
7969         (Check_Use_In_Test_Case): New routine.
7971 2014-02-18  Vincent Celier  <celier@adacore.com>
7973         * sem_aux.adb (Is_By_Reference_Type): For each components of
7974         a record type, check also if the component is volatile as it
7975         may have an aspect that makes it volatile. If it is, then the
7976         record type is a by reference type.
7978 2014-02-18  Robert Dewar  <dewar@adacore.com>
7980         * exp_attr.adb: Minor reformatting.
7981         * exp_ch4.ads, exp_ch4.adb (Expand_N_Reference): New procedure.
7982         * exp_util.adb (Remove_Side_Effects): Add conditional expressions
7983         as another case where we don't generate N_Reference nodes for
7984         primitive types.
7985         * expander.adb (Expand): Add call to Expand_N_Reference.
7987 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
7989         * sem_prag.adb (Analyze_Refined_Pragma): Remove
7990         local variable Pack_Spec. Refinement pragmas may now apply to
7991         bodies of both visible and private subprograms.
7993 2014-02-06  Robert Dewar  <dewar@adacore.com>
7995         * exp_attr.adb (Expand_Loop_Entry_Attribute):
7996         Minor change (Attr => N) (Expand_Pred_Succ): New name
7997         Expand_Pred_Succ_Attribute (Expand_N_Attribute_Reference, case
7998         Max): Expand into if expression if Modify_Tree_For_C mode.
7999         (Expand_N_Attribute_Reference, case Min): ditto
8000         * sinfo.ads: Modify_Tree_For_C takes care of expanding Min and
8001         Max attributes.
8003 2014-02-06  Ed Schonberg  <schonberg@adacore.com>
8005         * sem_ch3.adb (Analyze_Object_Declaration): Do not generate
8006         predicate check if this is an internal declaration with
8007         No_Initialization set, as for an expanded aggregate component.
8009 2014-02-06  Doug Rupp  <rupp@adacore.com>
8011         * init.c (__gnat_default_resignal_p) [VMS]: Test for and resignal
8012         conditions with severity of "SUCCESS" or "INFORMATIONAL".
8014 2014-02-06  Yannick Moy  <moy@adacore.com>
8016         * sem_prag.adb (Analyze_Pragma): Analyze pragma
8017         Debug rewritten node before rewriting it as a null statement in
8018         GNATprove mode.
8020 2014-02-06  Robert Dewar  <dewar@adacore.com>
8022         * sem_attr.adb (Min_Max): New procedure.
8023         (Max_Alignment_For_Allocation_Max_Size_In_Storage_Elements): New
8024         procedure.
8026 2014-02-06  Sergey Rybin  <rybin@adacore.com frybin>
8028         * gnat_ugn.texi, vms_data.ads: Add documentation of '-t' option for
8029         gnatmetric/gnatpp.
8031 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8033         * sem_prag.adb (Analyze_Abstract_State): Update
8034         all calls to Create_Abstract_State to pass the proper state
8035         "declaration".
8036         (Create_Abstract_State): Add new formal parameter
8037         State_Decl along with comment on usage. Establish a link between
8038         the abstract state entity and the state declaration.
8040 2014-02-06  Robert Dewar  <dewar@adacore.com>
8042         * sem_attr.adb (Analyze_Attribute, case Max): Check for improper
8043         comparison of unordered enumeration type.
8044         (Analyze_Attribute, case Max): Check for improper comparison of
8045         unordered enumeration type.
8046         * sem_res.adb (Bad_Unordered_Enumeration_Reference): Moved to
8047         sem_util.adb.
8048         * sem_util.ads, sem_util.adb (Bad_Unordered_Enumeration_Reference):
8049         Moved here from Sem_Res.
8051 2014-02-06  Robert Dewar  <dewar@adacore.com>
8053         * sem_ch3.adb, sem_prag.adb, sem_res.adb, lib-xref.adb: Minor
8054         reformatting.
8056 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8058         * sem_ch6.adb (Process_Formals): Error message reformatting.
8060 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8062         * sem_ch3.adb (Handle_Late_Controlled_Primitive): Add local
8063         variable Spec. Do not inherit the null indicator from the
8064         subprogram body when generating the spec.
8066 2014-02-06  Robert Dewar  <dewar@adacore.com>
8068         * casing.adb (Determine_Casing): Consider SPARK_Mode to be
8069         mixed case.
8071 2014-02-06  Ed Schonberg  <schonberg@adacore.com>
8073         * exp_ch6.adb (Is_Build_In_Place_Function): Predicate is false
8074         when the function has a foreign convention, but not if only the
8075         limited return type has such a convention.
8077 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8079         * sem_ch3.adb (Handle_Late_Controlled_Primitive): Remove local
8080         variable Spec. Comment reformatting. Use Copy_Separate_Tree
8081         rather than New_Copy_Tree when building the corresponding
8082         subprogram declaration.
8084 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8086         * sem_prag.adb (Analyze_Global_Item): Remove
8087         the mode-related checks on abstract states with enabled external
8088         properties.
8089         (Property_Error): Removed.
8091 2014-02-06  Javier Miranda  <miranda@adacore.com>
8093         * lib-xref.adb (Generate_Reference): When
8094         generating the reference to the first private entity take care
8095         of handling swapped entities.
8097 2014-02-06  Sergey Rybin  <rybin@adacore.com frybin>
8099         * gnat_ugn.texi, vms_data.ads: Add documentation of -j option for
8100         gnatmetric.
8102 2014-02-06  Robert Dewar  <dewar@adacore.com>
8104         * exp_ch4.adb (Expand_N_Shift_Left): Handle shift counts greater
8105         than the word size when operating in Modify_Tree_For_C mode.
8106         * sinfo.ads: Add documentation section on Modify_Tree_For_C mode.
8108 2014-02-06  Robert Dewar  <dewar@adacore.com>
8110         * erroutc.adb (Warning_Specifically_Suppressed.Matches):
8111         compare is case insensitive.
8112         * gnat_rm.texi: Document that string compare for Warnings Off
8113         is now case insensitive.
8115 2014-02-06  Eric Botcazou  <ebotcazou@adacore.com>
8117         * gnat_rm.texi: Small wording tweak.
8119 2014-02-06  Pascal Obry  <obry@adacore.com>
8121         * prj-attr.adb, projects.texi, snames.ads-tmpl: Add Included_Patterns
8122         and Included_Artifact_Patterns attribute definitions.
8124 2014-02-06  Yannick Moy  <moy@adacore.com>
8126         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Set
8127         SPARK_Mode pragma component for all subprograms, including stubs.
8129 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8131         * sem_ch10.adb (Analyze_Package_Body_Stub): Maintain
8132         the configuration options of the enclosing context in a
8133         stack-like fasion.
8134         (Analyze_Subprogram_Body_Stub): Maintain the
8135         configuration options of the enclosing context in a stack-like
8136         fashion.
8138 2014-02-06  Robert Dewar  <dewar@adacore.com>
8140         * debug.adb: -gnatd.u sets Modify_Tree_For C
8141         * exp_ch4.adb (Expand_N_Op_Rotate_Left): Expand out
8142         if Modify_Tree_For_C (Expand_N_Op_Rotate_Right): ditto.
8143         (Expand_N_Op_Arithmetic_Right_Shift): ditto.
8144         * exp_intr.adb (Expand_Shift): Call expander so we do
8145         Modify_Tree_For_C expansions.
8146         * gnat1drv.adb (Adjust_Global_Switches): Set Modify_Tree_For_C
8147         if -gnatd.u set.
8149 2014-02-06  Fedor Rybin  <frybin@adacore.com>
8151         * prj-proc.ads (Tree_Loaded_Callback): new type Callback used
8152         after the phase 1 of the processing of each aggregated project
8153         to get access to project trees of aggregated projects.
8154         (Process_Project_Tree_Phase_1): new parameter On_New_Tree_Loaded
8155         If specified, On_New_Tree_Loaded is called after each aggregated
8156         project has been processed succesfully.
8157         (Process): new parameter On_New_Tree_Loaded.
8158         * prj-proc.adb (Process_Aggregated_Projects): On_New_Tree_Loaded
8159         callback added after processing of each aggregated project.
8160         (Recursive_Process): new parameter On_New_Tree_Loaded.
8161         (Process): new parameter On_New_Tree_Loaded.
8162         (Process_Project_Tree_Phase_1): new parameter On_New_Tree_Loaded.
8163         * prj-conf.ads (Parse_Project_And_Apply_Config): new parameter
8164         On_New_Tree_Loaded.
8165         * prj-conf.adb (Parse_Project_And_Apply_Config): new parameter
8166         On_New_Tree_Loaded.
8168 2014-02-06  Bob Duff  <duff@adacore.com>
8170         * gnat_ugn.texi: Implement --insert-blank-lines and
8171         --preserve-blank-lines switches.
8173 2014-02-06  Sergey Rybin  <rybin@adacore.com frybin>
8175         * gnat_ugn.texi, vms_data.ads: Add documentation of -j option for
8176         gnatelim.
8178 2014-02-06  Eric Botcazou  <ebotcazou@adacore.com>
8180         * gnat_rm.texi (Pragma Optimize_Alignment): Document the effect
8181         of the pragma on individual objects.
8183 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8185         * einfo.adb Node29 is now used as BIP_Initialization_Call.
8186         (BIP_Initialization_Call): New routine.
8187         (Set_BIP_Initialization_Call): New routine.
8188         (Write_Field29_Name): Add an entry for constants and variables.
8189         * einfo.ads Add new attribute BIP_Initialization_Call and update
8190         its usage in nodes.
8191         (BIP_Initialization_Call): New routine along with pragma Inline.
8192         (Set_BIP_Initialization_Call): New routine along with pragma Inline.
8193         * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration):
8194         Add local declaration Res_Decl. Capture the build-in-place
8195         initialization call when the related object declaration has
8196         created a transient block.
8197         * exp_ch7.adb (Process_Transient_Objects): Add local variable
8198         Fin_Insrt. Recognize a scenario where an object declaration acts
8199         as a transient context and is initialized by a build-in-place
8200         function call.
8202 2014-02-06  Pascal Obry  <obry@adacore.com>
8204         * prj-util.adb (For_Interface_Sources): Fix handling of required
8205         bodies for aggregate libs.
8207 2014-02-06  Robert Dewar  <dewar@adacore.com>
8209         * nlists.ads: Minor comment clarifications.
8211 2014-02-06  Robert Dewar  <dewar@adacore.com>
8213         * gnat1drv.adb (Adjust_Global_Switches): Set Modify_Tree_For_C
8214         if gnatd.V set.
8215         * opt.ads (Modify_Tree_For_C): New flag.
8216         * output.ads, output.adb (Last_Char): New function.
8218 2014-02-06  Pascal Obry  <obry@adacore.com>
8220         * projects.texi, prj-env.adb (Initialize_Default_Project_Path): Add
8221         share/gpr for cross-builds.
8223 2014-02-06  Robert Dewar  <dewar@adacore.com>
8225         * exp_util.ads, checks.adb, sem_prag.adb, prj-util.adb, sem_ch13.adb:
8226         Minor reformatting and code clean ups.
8228 2014-02-06  Pascal Obry  <obry@adacore.com>
8230         * prj-util.adb (For_Interface_Sources): Skip non compilable languages.
8231         * prj.ads: Minor typo fix in comment.
8233 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8235         * sem_prag.adb (Analyze_Depends_In_Decl_Part): Add
8236         local variable Expr. Flag clauses with extra parenthesis as this
8237         is not allowed by the syntax of the pragma. Code reformatting.
8239 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8241         * exp_attr.adb (Expand_N_Attribute_Reference): Alphabetize
8242         variables. Rename variabme Tnn to Temp. Do not create a temporary
8243         if assertions are disabled. Find enclosing routine _Postconditions
8244         and insert the temporary that captures the value of the prefix
8245         before the routine.
8246         * exp_ch6.adb (Build_Postconditions_Procedure):
8247         Insert the generated _Postconditions routine
8248         before the first source declaration of the related
8249         subprogram.
8250         (Insert_After_Last_Declaration): Removed.
8251         (Insert_Before_First_Source_Declaration): New routine.
8253 2014-02-06  Ed Schonberg  <schonberg@adacore.com>
8255         * exp_util.adb, exp_util.ads (Within_Internal_Subprogram):
8256         Utility to determine whether current expansion is for the body
8257         of a predefined primitive operation.
8258         (Make_Predicate_Check): Use Within_Internal_Subpgram
8259         * checks.adb (Apply_Predicate_Check): Use
8260         Within_Internal_Subprogram
8261         * sem_ch13.adb (Freeze_Entity_Checks): Ditto.
8263 2014-02-06  Pascal Obry  <obry@adacore.com>
8265         * prj.ads, prj-util.adb: Minor reformatting.
8267 2014-02-06  Ed Schonberg  <schonberg@adacore.com>
8269         * exp_ch6.adb (Expand_Subprogram_Contract, Append_Enabled_Item):
8270         Take into account the Split_PPC flag to ensure that conjuncts
8271         in a composite postcondition aspect are tested in source order.
8273 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8275         * sem_ch6.adb (Analyze_Generic_Subprogram_Body): Flag illegal
8276         use of SPARK_Mode.
8277         * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): Flag
8278         illegal use of SPARK_Mode.
8279         (Instantiate_Subprogram_Body): Flag illegal use of SPARK_Mode.
8280         * sem_prag.adb (Analyze_Pragma): Code reformatting.
8281         * sem_util.adb Add with and use clause for Aspects.
8282         (Check_SPARK_Mode_In_Generic): New routine.
8283         * sem_util.ads (Check_SPARK_Mode_In_Generic): New routine.
8285 2014-02-06  Thomas Quinot  <quinot@adacore.com>
8287         * a-calend.adb (Formatting_Operations.Split): Ensure that
8288         Time_Error is raised for invalid time values.
8290 2014-02-06  Arnaud Charlet  <charlet@adacore.com>
8292         * sem_prag.adb (Analyze_Pragma): Rewrite as a null statement
8293         in GNATprove_Mode.
8295 2014-02-06  Robert Dewar  <dewar@adacore.com>
8297         * einfo.ads, einfo.adb (Is_Discriminant_Check_Function): New flag.
8298         * exp_ch3.adb (Build_Dcheck_Function): Set
8299         Is_Discriminant_Check_Function.
8301 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8303         * exp_ch7.adb (Is_Subprogram_Call): Inspect
8304         the original tree in certain cases where a construct has been
8305         factored out and replaced by a reference to a temporary.
8307 2014-02-06  Ed Schonberg  <schonberg@adacore.com>
8309         * sem_ch3.adb (Process_Full_View): Fix typo in the order of
8310         parameters when propagating predicate function to full view.
8311         (Find_Type_Of_Object): Freeze base type of object type to catch
8312         premature use of discriminated private type without a full view.
8314 2014-02-06  Robert Dewar  <dewar@adacore.com>
8316         * sprint.adb: Minor reformatting.
8318 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8320         * exp_ch4.adb (Process_Transient_Object): Add local variable
8321         Temp_Ins. When the transient object is initialized by an
8322         aggregate, the hook must capture the object after the last
8323         component assignment takes place.
8324         * exp_ch7.adb (Detect_Subprogram_Call): Expose the subprogram to
8325         routine Is_Subprogram_Call.
8326         (Is_Subprogram_Call): Inspect an
8327         aggregate that has been heavily expanded for subprogram calls.
8328         (Process_Transient_Objects): Add local variables Expr, Ptr_Id
8329         and Temp_Ins.  Remove the nested declare block and adjust the
8330         indentation. When the transient object is initialized by an
8331         aggregate, the hook must capture the object after the last
8332         component assignment takes place.
8334 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8336         * sem_prag.adb (Analyze_Global_Item): Detect illegal uses of
8337         external states with enabled properties that do not match the
8338         global mode.
8339         (Property_Error): New routine.
8340         * sem_res.adb (Property_Error): New routine.
8341         (Resolve_Actuals): Detect illegal uses of external variables with
8342         enabled properties in procedure calls that do not match the mode of
8343         the corresponding formal parameter.
8345 2014-02-06  Hristian Kirtchev  <kirtchev@adacore.com>
8347         * sem_util.adb (Has_Enabled_Property): Rename
8348         formal parameter Prop_Nam to Property. Update the comment on usage
8349         and all occurrences in the body. Add local variable Prop_Nam. When
8350         inspecting a property with an expression, the property name
8351         appears as the first choice of the component association.
8353 2014-02-04  Robert Dewar  <dewar@adacore.com>
8355         * exp_ch5.adb, einfo.ads, freeze.adb, sem_ch8.adb: Minor reformatting.
8357 2014-02-04  Gary Dismukes  <dismukes@adacore.com>
8359         * sem_aggr.adb: Change "runtime" to "run time" in warning message,
8360         for consistency with other messages.
8362 2014-02-04  Ed Schonberg  <schonberg@adacore.com>
8364         * exp_ch5.adb  (Expand_Iterator_Loop):  For a container element
8365         iterator, indicate that the element is a constant if the container
8366         type does not have a variable indexing aspect.
8367         * sem_ch8.adb (Analyze_Object_Renaming): If the entity is already
8368         marked as constant, do not reset its Ekind, to ensure that
8369         container elements in an element loop are not modified if the
8370         container (e.g. a hashed set) only has a constant indexing aspect.
8372 2014-02-04  Arnaud Charlet  <charlet@adacore.com>
8374         * g-souinf.ads: Subprograms in this unit are actually not pure.
8375         * freeze.adb (Freeze_Subprogram): Do not reset Is_Pure for Intrinsics.
8376         * einfo.ads (Is_Pure): Update doc to match implementation.
8378 2014-02-04  Gary Dismukes  <dismukes@adacore.com>
8380         * exp_ch13.adb: Minor spelling fix.
8382 2014-02-04  Robert Dewar  <dewar@adacore.com>
8384         * opt.ads: Minor comment update.
8386 2014-02-04  Robert Dewar  <dewar@adacore.com>
8388         * exp_ch4.adb (Expand_N_Expression_With_Actions): Use Rewrite
8389         instead of Replace.
8391 2014-02-04  Ed Schonberg  <schonberg@adacore.com>
8393         * sem_aggr.adb (Resolve_Array_Aggregate): Suppress warnings
8394         on null expressions if component type is non-null, when the
8395         corresponding association covers an empty range of index values.
8397 2014-02-04  Robert Dewar  <dewar@adacore.com>
8399         * sinfo.ads: Further comments on N_Expression_With_Actions node.
8401 2014-02-04  Hristian Kirtchev  <kirtchev@adacore.com>
8403         * sem_prag.adb (Analyze_Refined_Depends_In_Decl_Part): Remove global
8404         variables Out_Items and Ref_Global. Remove local constant
8405         Body_Id along with dummy variables D1, D2, D3, D4, D5, D6, D7
8406         and D8. Remove the useless collection of global items as this
8407         was a leftover from an earlier version of the routine. Move
8408         several routines out to avoid deep nesting and indentation.
8409         (Inputs_Match): Add formal parameter Dep_Clause. Rename formal
8410         parameter Do_Checks to Post_Errors. Update the comment on usage.
8411         (Is_Matching_Input): Renamed to Input_Match. Add formal parameters
8412         Ref_Inputs and Do_Checks. Rename formal parameter Do_Checks
8413         to Post_Errors. Update the comment on usage. Account for the
8414         case where a self referential state may have a null input_list.
8415         (Is_Self_Referential): New routine.
8417 2014-02-04  Ed Schonberg  <schonberg@adacore.com>
8419         * sem_ch13.adb (Analyze_Attribute_Definition_Clause): If the
8420         entity renames an expression, as in the case of an object of
8421         an unconstrained type initialized by a function call, defer the
8422         rewriting of the expression to the expander.
8423         * exp_ch13.adb (Expand_N_Attribute_Definition_Clause, case
8424         'Alignment): If the entity renames an expression, introduce
8425         temporary to capture value, and rewrite original declaration to
8426         use temporary.
8428 2014-02-04  Gary Dismukes  <dismukes@adacore.com>
8430         * g-comlin.adb: Minor typo fix.
8432 2014-02-04  Ed Schonberg  <schonberg@adacore.com>
8434         * freeze.adb (Freeze_All): Types derived from a formal
8435         access_to_classwide type do not have a finalization master.
8437 2014-02-04  Robert Dewar  <dewar@adacore.com>
8439         * sprint.adb: Minor reformatting.
8441 2014-02-04  Robert Dewar  <dewar@adacore.com>
8443         * exp_ch4.adb (Expand_N_Expression_With_Actions): Eliminate
8444         cases where Actions is a null list.
8445         * sinfo.ads (N_Expression_With_Actions): Actions can be
8446         temporarily empty during semantic analysis, but must be non-empty
8447         in the final expanded tree.
8449 2014-01-31  Robert Dewar  <dewar@adacore.com>
8451         * exp_ch9.adb: Minor reformatting.
8453 2014-01-31  Emmanuel Briot  <briot@adacore.com>
8455         * g-comlin.adb (Set_Command_Line): Take the switches
8456         configuration from the Command_Line_Config.
8458 2014-01-31  Hristian Kirtchev  <kirtchev@adacore.com>
8460         * sem_prag.adb (Analyze_Refinement_Clause): Guard against a malformed
8461         refinement clause.
8463 2014-01-31  Vincent Celier  <celier@adacore.com>
8465         * projects.texi: Add more documentation about others used as an
8466         index in indexed attributes.
8468 2014-01-31  Robert Dewar  <dewar@adacore.com>
8470         * gnat_ugn.texi: Minor update.
8471         * gnat_rm.texi: Add example to Restriction_Warnings documentation.
8472         * exp_util.adb: Minor reformatting.
8474 2014-01-31  Ed Schonberg  <schonberg@adacore.com>
8476         * exp_ch9.adb (Expand_Entry_Barrier): Warn if the barrier
8477         depends on data that is not private to the protected object,
8478         and potentially modifiable in unsynchronized fashion.
8480 2014-01-31  Yannick Moy  <moy@adacore.com>
8482         * erroutc.adb (Validate_Specific_Warnings): Remove special case for
8483         GNATprove_Mode.
8485 2014-01-31  Robert Dewar  <dewar@adacore.com>
8487         * prj-attr.ads (First_Attribute_Of): Returns Empty_Attribute
8488         for Unknown_Package.
8489         * sem_ch6.adb, sem_attr.adb: Minor comment addition.
8491 2014-01-31  Hristian Kirtchev  <kirtchev@adacore.com>
8493         * exp_util.adb (Build_Allocate_Deallocate_Proc): Rewrite
8494         the logic that generates a runtime check to determine the
8495         controlled status of the object about to be allocated or
8496         deallocated. Class-wide types now always use a runtime check
8497         even if they appear as generic actuals.
8498         (Find_Object): Detect
8499         a special case that involves interface class-wide types because
8500         the object appears as a complex expression.
8502 2014-01-31  Ed Schonberg  <schonberg@adacore.com>
8504         * sem_ch6.adb (Process_Formals): In Ada2012 mode, place
8505         subprogram with an incomplete untagged formals on the list of
8506         private dependents, to verify that the type is properly completed
8507         in the private part.
8508         * sem_attr.adb: Code clean up.
8510 2014-01-31  Robert Dewar  <dewar@adacore.com>
8512         * exp_ch6.adb: Minor reformatting.
8514 2014-01-31  Vincent Celier  <celier@adacore.com>
8516         * prj-attr.adb (First_Attribute_Of): Return Unknown_Attribute
8517         when Pkg is unknown.
8519 2014-01-31  Hristian Kirtchev  <kirtchev@adacore.com>
8521         * sem_res.adb (Resolve_Entity_Name): Comment
8522         reformatting. Allow volatile objects in various generated checks.
8524 2014-01-31  Ed Schonberg  <schonberg@adacore.com>
8526         * sem_attr.adb (Analyze_Attribute, case 'Update): For a record
8527         component association, set the etype of the identifier, for
8528         SPARK use.
8530 2014-01-31  Ed Schonberg  <schonberg@adacore.com>
8532         * exp_ch6.adb (Has_Visibility_Of_Subprogram): If type is not
8533         declared in a package, not checks can apply to the subprogram.
8535 2014-01-31  Robert Dewar  <dewar@adacore.com>
8537         * erroutc.adb (Validate_Specific_Warnings): Warnings are
8538         controlled -gnatw.W.
8539         * gnat_ugn.texi: Document new warnings controlled by -gnatw.w.
8540         * opt.ads (Warn_On_Warnings_Off): Now controls more cases.
8542 2014-01-31  Arnaud Charlet  <charlet@adacore.com>
8544         * exp_disp.adb: Update comments.
8546 2014-01-31  Yannick Moy  <moy@adacore.com>
8548         * sem_ch12.adb (Analyze_Generic_Subprogram_Declaration,
8549         Save_Global_References): Guard access to expression in aspect.
8551 2014-01-31  Yannick Moy  <moy@adacore.com>
8553         * sem_prag.adb (Analyze_Pragma/Pragma_SPARK_Mode):
8554         Issue an error when the pragma is applied to a generic unit,
8555         a generic declaration, or inside a generic.
8557 2014-01-31  Yannick Moy  <moy@adacore.com>
8559         * sem_ch8.adb (Analyze_Subprogram_Renaming): Set SPARK_Mode on renaming
8560         entity.
8562 2014-01-31  Robert Dewar  <dewar@adacore.com>
8564         * exp_ch9.adb, s-tassta.adb, s-tposen.adb, s-tposen.ads: Minor
8565         reformatting.
8567 2014-01-31  Tristan Gingold  <gingold@adacore.com>
8569         * exp_disp.adb: Add a historic note.
8571 2014-01-31  Robert Dewar  <dewar@adacore.com>
8573         * sem_warn.adb (Warn_On_Useless_Assignments): Add call to
8574         Process_Deferred_References.
8576 2014-01-31  Yannick Moy  <moy@adacore.com>
8578         * erroutc.adb (Validate_Specific_Warnings): Do not issue a message for
8579         ineffective pragma Warnings(Off) in GNATprove_Mode.
8581 2014-01-31  Bob Duff  <duff@adacore.com>
8583         * s-taskin.ads: Minor comment fix.
8584         * s-tassta.adb (Abort_Dependents): Don't abort all dependents;
8585         just direct dependents. If this is actually an abort, each task
8586         will take care of aborting its dependents, so all dependents will
8587         get aborted, as before. However, when this is called the second
8588         time from Vulnerable_Complete_Master "for convenience" (i.e. to
8589         kill off tasks waiting at terminate alternatives), aborting
8590         indirect dependents is wrong, because it causes some unrelated
8591         tasks to get aborted.
8593 2014-01-31  Robert Dewar  <dewar@adacore.com>
8595         * sem_ch4.adb: Minor reformatting.
8597 2014-01-31  Robert Dewar  <dewar@adacore.com>
8599         * exp_ch2.adb: New calling sequence for Is_LHS.
8600         * frontend.adb: Add call to Process_Deferred_References.
8601         * lib-xref.ads, lib-xref.adb (Process_Deferred_References): New.
8602         (Deferred_References): New table.
8603         * sem_ch8.adb (Find_Direct_Name): Make deferred reference table
8604         entries.
8605         (Find_Expanded_Name): Ditto.
8606         * sem_res.adb: New calling sequence for Is_LHS.
8607         * sem_util.ads, sem_util.adb (Is_LHS): New calling sequence.
8608         * sem_warn.adb: Call Process_Deferred_References before issuing
8609         warnings.
8611 2014-01-31  Tristan Gingold  <gingold@adacore.com>
8613         * exp_util.adb (Corresponding_Runtime_Package): Restrict the
8614         use of System_Tasking_Protected_Objects_Single_Entry.
8615         * exp_ch9.adb (Build_Simple_Entry_Call): Remove Mode parameter
8616         of Protected_Single_Entry_Call.
8617         (Expand_N_Timed_Entry_Call): Remove single_entry case.
8618         * exp_disp.adb (Make_Disp_Asynchronous_Select_Body): Remove
8619         single_entry case.
8620         (Make_Disp_Timed_Select_Body): Likewise.
8621         * rtsfind.ads (RE_Timed_Protected_Single_Entry_Call): Remove.
8622         * s-tposen.adb (Send_Program_Error, PO_Do_Or_Queue): Remove
8623         Self_Id parameter.
8624         (Wakeup_Entry_Caller): Remove Self_ID and New_State parameters.
8625         (Wait_For_Completion_With_Timeout): Remove.
8626         (Protected_Single_Entry_Call): Remove Mode parameter
8627         (always Simple_Call).
8628         (Service_Entry): Remove Self_Id constant (not used anymore).
8629         (Timed_Protected_Single_Entry_Call): Remove.
8630         * s-tposen.ads (Timed_Protected_Single_Entry_Call): Remove.
8631         (Protected_Single_Entry_Call): Remove Mode parameter.
8633 2014-01-29  Hristian Kirtchev  <kirtchev@adacore.com>
8635         * einfo.adb (Get_Pragma): Handle the retrieval of pragma Refined_Post.
8636         * einfo.ads (Get_Pragma): Update the comment on special pragmas
8637         handled by this routine.
8638         * sem_prag.adb (Analyze_Pragma): Add a legal pragma Refined_Post
8639         to the contract of the related subprogram body.
8640         * sem_util.adb (Add_Contract_Item): Handle the insertion of
8641         pragma Refined_Post into the contract of a subprogram body.
8642         * sinfo.ads Update the documentation of node N_Contract.
8643         * sem_res.adb (Resolve_Entity_Name): Add a guard
8644         to detect abstract states and variables only when checking the
8645         SPARK 2014 rules concerning volatile object placement.
8647 2014-01-29  Ed Schonberg  <schonberg@adacore.com>
8649         * sem_ch4.adb (Find_Equality_Types, Try_One_Interp): within an instance,
8650         null is compatible with any access type.
8652 2014-01-29  Hristian Kirtchev  <kirtchev@adacore.com>
8654         * sem_util.adb (Find_Placement_In_State_Space): Assume that the default
8655         placement is not in a package.
8657 2014-01-29  Hristian Kirtchev  <kirtchev@adacore.com>
8659         * sem_util.adb (Has_Enabled_Property): Compare the character field of
8660         the sole property.
8662 2014-01-29  Robert Dewar  <dewar@adacore.com>
8664         * sem_intr.adb, a-ztexio.ads, sinfo.ads, sem_res.adb, gnatlink.adb,
8665         vms_conv.adb, a-except.ads, a-except-2005.ads, a-teioed.adb,
8666         sem_warn.ads, treepr.ads, erroutc.ads, a-excach.adb: Minor reformatting.
8668 2014-01-29  Robert Dewar  <dewar@adacore.com>
8670         * sem_util.ads, sem_util.adb (In_Pragma_Expression): New function.
8671         * sem_warn.adb (Check_References): Suppress warnings if inside
8672         Initial_Condition pragma.
8674 2014-01-29  Hristian Kirtchev  <kirtchev@adacore.com>
8676         * sem_prag.adb (Check_Missing_Part_Of): List all values of
8677         State_Space_Kind for readability reasons. Do not emit an error on
8678         a private item when the enclosing package lacks aspect/pragma
8679         Abstract_State. Do not emit an error on a private package
8680         instantiation when the corresponding generic template lacks
8681         visible state.
8682         (Has_Visible_State): New routine.
8683         * sem_util.adb (Find_Placement_In_State_Space): The visible
8684         declarations of any kind of child units in general act as proper
8685         placement location.
8687 2014-01-29  Robert Dewar  <dewar@adacore.com>
8689         * a-except-2005.adb, a-except.adb, a-excpol-abort.adb, a-exstat.adb,
8690         ali.adb, a-numaux.ads, a-numaux-darwin.ads, a-numaux-libc-x86.ads,
8691         a-numaux-vms.ads, a-numaux-vxworks.ads, a-numaux-x86.ads, aspects.ads,
8692         a-taside.adb, a-teioed.adb, a-textio.adb, a-textio.ads, atree.adb,
8693         atree.ads, a-witeio.adb, a-witeio.ads, a-wtedit.adb, a-ztedit.adb,
8694         a-ztexio.adb, bcheck.adb, binde.adb, checks.adb, comperr.adb,
8695         cstand.adb, debug_a.adb, einfo.ads, errout.adb, erroutc.adb,
8696         eval_fat.adb, exp_aggr.adb, exp_attr.adb, exp_ch11.adb, exp_ch3.adb,
8697         exp_ch4.adb, exp_ch5.adb, exp_ch6.adb, exp_ch9.adb, exp_dbug.adb,
8698         exp_disp.adb, exp_fixd.adb, exp_imgv.adb, exp_intr.adb, exp_util.adb,
8699         freeze.adb, frontend.adb, g-comlin.ads, g-mbdira.adb, gnat1drv.adb,
8700         gprep.adb, g-spipat.adb, i-cpp.ads, i-vxwork.ads, i-vxwork-x86.ads,
8701         krunch.ads, layout.adb, lib-load.adb, lib-writ.adb, lib-writ.ads,
8702         live.adb, namet.ads, osint.adb, osint-c.adb, output.ads, par.adb,
8703         par-ch10.adb, par-ch13.adb, par-ch3.adb, par-ch4.adb, par-ch5.adb,
8704         par-ch6.adb, par-ch9.adb, par-endh.adb, par-labl.adb, par-prag.adb,
8705         par-sync.adb, par-tchk.adb, par-util.adb, prj.adb, repinfo.adb,
8706         rtsfind.adb, s-arit64.adb, s-asthan-vms-alpha.adb,
8707         s-asthan-vms-ia64.adb, s-bignum.adb, scans.adb, scng.adb, s-dimmks.ads,
8708         sem_aggr.adb, sem_attr.adb, sem_aux.adb, sem_cat.adb, sem_ch10.adb,
8709         sem_ch12.adb, sem_ch13.adb, sem_ch13.ads, sem_ch3.adb, sem_ch4.adb,
8710         sem_ch5.adb, sem_ch6.adb, sem_ch8.adb, sem_disp.adb, sem_elab.adb,
8711         sem_elim.adb, sem_eval.adb, sem_intr.adb, sem_prag.adb, sem_res.adb,
8712         sem_type.adb, sem_util.adb, sem_warn.adb, set_targ.adb, s-fatgen.adb,
8713         s-fatgen.ads, s-fileio.adb, s-imgcha.adb, s-imgrea.adb, sinfo.ads,
8714         sinput-c.adb, snames.ads-tmpl, s-os_lib.adb, sprint.adb,
8715         s-regpat.adb, s-secsta.adb, s-stalib.ads,
8716         s-stchop.adb, s-stoele.ads, stand.ads, s-taprop-solaris.adb,
8717         s-tasdeb-vms.adb, s-tasini.adb, s-tassta.adb, s-valdec.adb,
8718         s-valuti.adb, s-wchjis.adb, s-wchwts.adb, system.ads, system-vms_64.ads,
8719         system-vms-ia64.ads, treepr.adb, types.ads, uintp.adb, uname.adb,
8720         urealp.adb, usage.adb, vxaddr2line.adb: Minor reformatting.
8722 2014-01-29  Robert Dewar  <dewar@adacore.com>
8724         * expander.adb: Minor reformatting.
8726 2014-01-29  Javier Miranda  <miranda@adacore.com>
8728         * exp_ch3.adb (Predefined_Primitive_Bodies): Adding documentation to
8729         previous patch.
8731 2014-01-29  Javier Miranda  <miranda@adacore.com>
8733         * exp_ch3.adb (Predefined_Primitive_Bodies): Complete the code
8734         that checks if an interface types defines the predefined "="
8735         function because the compiler was erroneously not generating the
8736         predefined "=" primitive as soon as the name of some interface
8737         primitive is "=" (formals were not checked).
8739 2014-01-29  Ed Schonberg  <schonberg@adacore.com>
8741         * expander.adb (Expander): In GNATprove mode, do not process
8742         transient scopes: they are in general not created in this mode,
8743         and an attempt to examine them will lead to constraint errors when
8744         processing configuration pragmas that have analyzable expressions.
8746 2014-01-29  Vincent Celier  <celier@adacore.com>
8748         * clean.adb (Gnatclean): Fail if main project is an aggregate
8749         project or if there is an aggregate library project in the
8750         project tree.
8751         * gnatcmd.adb: Fail if the main project is an aggregate project
8752         or if there is an aggegate library project in the project tree.
8753         * make.adb (Initialize): : Fail if main project is an aggregate
8754         project or if there is an aggregate library project in the
8755         project tree.
8756         * makeutl.ads (Aggregate_Libraries_In): New Boolean function.
8757         * prj-makr.adb (Initialize): Fail if the main project is an
8758         aggregate project or an aggregate library project.
8760 2014-01-29  Vincent Celier  <celier@adacore.com>
8762         * prj-part.adb (Check_Import_Aggregate): New procedure
8763         to check if an imported project is an aggregate project.
8764         (Parse_Single_Project): Call Check_Import_Aggregate
8765         * projects.texi: Document that aggregate projects cannot be
8766         extended or imported.
8768 2014-01-29  Robert Dewar  <dewar@adacore.com>
8770         * exp_ch9.adb, sem_ch7.ads, s-regexp.adb, sem_ch13.adb: Minor
8771         reformatting and code clean up.
8772         * gnat_ugn.texi: Add documentation section on Atomic Variables
8773         and Optimization.
8775 2014-01-29  Hristian Kirtchev  <kirtchev@adacore.com>
8777         * einfo.adb Flag264 is now unused.
8778         (Has_Body_References): Removed.
8779         (Set_Has_Body_References): Removed.
8780         (Write_Entity_Flags): Remove the output for flag Has_Body_References.
8781         * einfo.ads Update the comment on usage of attribute
8782         Body_References. Remove attribute Has_Body_References and its
8783         usage in nodes.
8784         (Has_Body_References): Removed along with pragma Inline.
8785         (Set_Has_Body_References): Removed along with pragma Inline.
8786         * sem_prag.adb (Analyze_Global_Item): Move the call to
8787         Record_Possible_Body_Reference in the state related checks
8788         section. Add a comment intended function.
8789         (Analyze_Input_Output): Move the call to Record_Possible_Body_Reference
8790         in the state related checks section. Add a comment intended function.
8791         (Analyze_Refinement_Clause): Cleanup the illegal body reference
8792         reporting. Add a comment on timing of error reporting.
8793         (Record_Possible_Body_Reference): Reimplement the routine.
8795 2014-01-29  Vincent Celier  <celier@adacore.com>
8797         * makeutl.adb (Mains.Find_File_Add_Extension): Only look for specs for
8798         unit-based languages.
8799         (Mains.Complete_Mains.Do_Complete): Use the source file project
8800         tree when calling Find_File_Add_Extension. Use the correct
8801         project name when reporting an error.
8803 2014-01-29  Hristian Kirtchev  <kirtchev@adacore.com>
8805         * aspects.adb Add an entry for aspect Part_Of in table
8806         Canonical_Aspect.
8807         * aspects.ads Add an entry for aspect Part_Of in tables Aspect_Id,
8808         Aspect_Argument, Aspect_Names and Aspect_Delay.
8809         * atree.h Define Elist9.
8810         * atree.adb (Elist9): New routine.
8811         (Set_Elist9): New routine.
8812         * atree.ads (Elist9): New routine.
8813         (Set_Elist9): New routine.
8814         * einfo.adb Add Part_Of_Constituents and Encapsulating_State to
8815         the list of node usage.  Remove Refined_State from the list of
8816         node usage.
8817         (Encapsulating_State): New routine.
8818         (Get_Pragma):
8819         Handle pragma Part_Of; (Part_Of_Constituents): New routine.
8820         (Refined_State): Removed.
8821         (Set_Encapsulating_State): New routine.
8822         (Set_Part_Of_Constituents): New routine.
8823         (Set_Refined_State): Removed.
8824         (Write_Field9_Name): Add an entry
8825         for Part_Of_Constituents (Write_Field10_Name): Add an entry for
8826         Encapsulating_State. Remove the entry for Refined_State.
8827         * einfo.ads Add new attributes Encapsulating_State
8828         and Part_Of_Constituents alond with their usage in
8829         entities. Remove attribute Refined_State along with its
8830         usage in entities.
8831         (Encapsulating_State): New routine and
8832         pragma Inline.  (Get_Pragma): Update the comment on usage.
8833         (Part_Of_Constituents): New routine and pragma Inline.
8834         (Refined_State): Removed along with pragma Inline.
8835         (Set_Encapsulating_State): New routine and pragma Inline.
8836         (Set_Part_Of_Constituents): New routine and pragma Inline.
8837         (Set_Refined_State): Removed along with pragma Inline.
8838         * par-prag.adb Pragma Part_Of does not need any special processing
8839         by the parser.
8840         * sem_ch3.adb (Analyze_Declarations): Remove local variables
8841         Body_Id and Prag. Call separate routines to analyze the
8842         contract of a package [body].
8843         (Analyze_Object_Contract):
8844         Update the comment on usage. Remove local variables
8845         Items and Nam. Use Get_Pragma rather than traversing the
8846         classification list.  Verify whether the lack of indicator
8847         Part_Of agrees with the placement of the variable in state space.
8848         (Analyze_Object_Declaration): Initialize the encapsulating state
8849         of a variable.  (Requires_State_Refinement): Moved to sem_util.
8850         * sem_ch7.adb (Analyze_Package_Body_Contract): New routine.
8851         (Analyze_Package_Contract): New routine.
8852         * sem_ch7.ads (Analyze_Package_Body_Contract): New routine.
8853         (Analyze_Package_Contract): New routine.
8854         * sem_ch10.adb (Decorate_State): Initialize the encapsulating
8855         state and Part_Of constituents.
8856         * sem_ch13.adb (Analyze_Aspect_Specifications):
8857         Add processing for aspect Part_Of. Update all
8858         calls to Decorate_Delayed_Aspect_And_Pragma.
8859         (Check_Aspect_At_Freeze_Point): Aspect Part_Of does
8860         not need any special processing at freeze time.
8861         (Decorate_Delayed_Aspect_And_Pragma): Renamed to
8862         Decorate_Aspect_And_Pragma.  Add formal parameter Delayed and
8863         update the associated comment.
8864         * sem_prag.adb Add an entry for pragma Part_Of in table Sig_Flags.
8865         (Analyze_Abstract_State): Add new global variable State_Id. Remove
8866         local constants Errors and Loc. Remove local variables Is_Null
8867         and State_Nam. Create the entity of the abstract state on the
8868         spot, before all remaining checks are performed. Verify that a
8869         missing Part_Of option agrees with the placement of the abstract
8870         state within the state space.
8871         (Analyze_Depends_In_Decl_Part):
8872         Add new global variables Constits_Seen and States_Seen. Check
8873         that a state and a corresponding constituent do not appear
8874         in pragma [Refined_]Depends.
8875         (Analyze_Global_In_Decl_Part):
8876         Add new global variables Constits_Seen and States_Seen. Check
8877         that a state and a corresponding constituent do not appear
8878         in pragma [Refined_]Global.
8879         (Analyze_Global_Item):
8880         Remove the now obsolete code that deals with Part_Of.
8881         Add the entity of the global item to the list of processed
8882         items.  (Analyze_Initializes_In_Decl_Part): Add new global
8883         variables Constits_Seen and States_Seen. Check that a state
8884         and a corresponding constituent do not appear in pragma
8885         Initializes.
8886         (Analyze_Initialization_Item): Add the entity
8887         of the initialization item to the list of processed items.
8888         (Analyze_Input_Item): Add the entity of the initialization
8889         item to the list of processed items.
8890         (Analyze_Input_Output):
8891         Remove the now obsolete code that deals with Part_Of.  Add the
8892         entity of the input/output to the list of processed items.
8893         (Analyze_Part_Of): New routine.
8894         (Analyze_Part_Of_Option): Remove
8895         local constant Par_State. Add local constant Encaps and local
8896         variables Encaps_Id and Legal. Use Analyze_Part of to analyze
8897         the option. Turn the related state into a Part_Of constituent
8898         if the option is legal.
8899         (Analyze_Pragma): Add processing
8900         for pragma Part_Of.
8901         (Analyze_Refined_State_In_Decl_Part):
8902         Remove global constants Pack_Body and Spec_Id. Remove
8903         global variables Abstr_States and Hidden_States. Add new
8904         global variables Available_States, Body_Id, Body_States and
8905         Spec_Id. Add new local constant Body_Decl. Reimplement the
8906         logic that extracts the states available for refinement from
8907         the related package and the body hidden states of the said
8908         package.
8909         (Analyze_Refinement_Clause): Add local variable Part_Of_Constits.
8910         (Check_Applicable_Policy): Alphabetize body.
8911         (Check_Dependency_Clause): Replace Refined_State
8912         with Encapsulating_State.
8913         (Check_Matching_Constituent):
8914         Reimplement the logic that determines whether an item is a valid
8915         / invalid constituent of the current refined state. Return when
8916         a construct does not denote a valid abstract state. Extract the
8917         list of Part_Of constituents for further analysis. Check that all
8918         Part_Of constituents of a state have been used in its refinement.
8919         (Check_Matching_State): Update the comment on usage. Operate
8920         on the list of available states.
8921         (Check_Missing_Part_Of): New routine.
8922         (Check_Refined_Global_Item): Replace Refined_State
8923         with Encapsulating_State.
8924         (Check_State_And_Constituent_Use): New routine.
8925         (Create_Abstract_State): New routine.
8926         (Is_Matching_Input): Replace Refined_State with Encapsulating_State.
8927         (Is_Part_Of): Removed.
8928         (Collect_Body_States): New routine.
8929         (Collect_Constituent): Replace Refined_State with Encapsulating_State.
8930         (Collect_Hidden_States): Removed.
8931         (Report_Unrefined_States): Change the profile of the procedure along
8932         with the comment on usage.
8933         (Report_Unused_Constituents): New routine.
8934         (Report_Unused_Hidden_States): Removed.
8935         (Report_Unused_States): New routine.
8936         * sem_prag.ads (Check_Missing_Part_Of): New routine.
8937         * sem_util.adb (Add_Contract_Item): Pragma Part_Of can now
8938         appear in the classification pragmas of a package instantiation
8939         or a variable.
8940         (Find_Placement_In_State_Space): New routine.
8941         (Is_Child): Removed.
8942         (Is_Child_Or_Sibling): Remove formal
8943         parameter Private_Child. Remove the private child checks.
8944         (Requires_State_Refinement): Moved from sem_ch3.
8945         * sem_util.ads Add new type State_Space_Kind along with
8946         comment on its usage and values.
8947         (Add_Contract_Item): Update the comment on usage.
8948         (Find_Body_Discriminal): Alphabetize spec.
8949         (Find_Placement_In_State_Space): New routine.
8950         (Is_Child_Or_Sibling): Remove formal parameter Private_Child
8951         and update the comment on usage.
8952         (Requires_State_Refinement): Moved from sem_ch3.
8953         * sinfo.ads: Update the documentation of N_Contract.
8954         * snames.ads-tmpl The predefined name for Part_Of is now used
8955         to denote a pragma. Add Pragma_Id for Part_Of.
8957 2014-01-29  Emmanuel Briot  <briot@adacore.com>
8959         * s-regexp.adb (Create_Secondary_Table): Automatically grow the state
8960         machine as needed.
8961         (Dump): New subprogram.
8963 2014-01-29  Tristan Gingold  <gingold@adacore.com>
8965         * exp_ch9.adb (Expand_N_Protected_Type_Declaration): Add
8966         Expand_Entry_Declaration to factorize code.
8968 2014-01-29  Ed Schonberg  <schonberg@adacore.com>
8970         * checks.adb: minor clarification.
8971         * sem_ch7.adb (Declare_Inherited_Private_Subprograms): Limit
8972         search for primitive operations to the entities that immediately
8973         follow the type declaration.
8975 2014-01-29  Tristan Gingold  <gingold@adacore.com>
8977         * exp_ch9.adb (Build_Protected_Entry): Do not call
8978         Complete_Entry_Body anymore.
8979         * rtsfind.ads (RE_Complete_Single_Entry_Body): Remove.
8980         * s-tposen.ads, s-tposen.adb (Complete_Single_Entry_Body): Remove.
8982 2014-01-29  Pierre-Marie Derodat  <derodat@adacore.com>
8984         * s-os_lib.adb, s-os_lib.ads (Normalize_Pathname): Return an empty
8985         string when the Name input bigger than allowed. Adapt the function
8986         specification.
8988 2014-01-29  Ed Schonberg  <schonberg@adacore.com>
8990         * checks.adb (Install_Null_Excluding_Check): Do not emit warning
8991         if expression is within a case_expression of if_expression.
8993 2014-01-29  Robert Dewar  <dewar@adacore.com>
8995         * exp_ch9.adb, inline.ads: Minor reformatting.
8997 2014-01-29  Tristan Gingold  <gingold@adacore.com>
8999         * exp_ch9.adb (Is_Exception_Safe): Return true if no exceptions.
9001 2014-01-29  Yannick Moy  <moy@adacore.com>
9003         * inline.ads (Pending_Body_Info): Add SPARK_Mode and
9004         SPARK_Mode_Pragma components to be able to analyze generic
9005         instance.
9006         * sem_ch12.adb (Analyze_Package_Instantiation,
9007         Inline_Instance_Body, Need_Subprogram_Instance_Body,
9008         Load_Parent_Of_Generic): Pass in SPARK_Mode from instantiation
9009         for future analysis of the instance.
9010         (Instantiate_Package_Body,
9011         Instantiate_Subprogram_Body, Set_Instance_Inv): Set SPARK_Mode
9012         from instantiation to analyze the instance.
9014 2014-01-29  Robert Dewar  <dewar@adacore.com>
9016         * sem_ch7.adb, sem_prag.adb, sem_ch4.adb, sem_ch6.adb: Minor code
9017         reorganization.
9019 2014-01-29  Yannick Moy  <moy@adacore.com>
9021         * gnat_rm.texi: Update description of SPARK_Mode pragma.
9023 2014-01-29  Tristan Gingold  <gingold@adacore.com>
9025         * exp_ch9.adb (Expand_N_Protected_Body): Remove Num_Entries.
9027 2014-01-29  Thomas Quinot  <quinot@adacore.com>
9029         * sem_ch4.adb (Find_Component_In_Instance): Update comment.
9031 2014-01-29  Ed Schonberg  <schonberg@adacore.com>
9033         * exp_util.adb (Build_Task_Image_Prefix): Indicate that the
9034         resulting string is an internal entity. and thus requires no
9035         initialization. This is relevant when Initialize_ Scalars is
9036         enabled, because the resultant spurious initialization may lead to
9037         secondary stack anomalies that produce a mangled name for a task.
9039 2014-01-29  Yannick Moy  <moy@adacore.com>
9041         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): SPARK_Mode
9042         not inherited from spec anymore. Check consistency
9043         rules after processing of declarations.
9044         * sem_ch7.adb (Analyze_Package_Body_Helper): SPARK_Mode not inherited
9045         from spec anymore. Check consistency rules after processing of
9046         declarations.
9047         (Analyze_Package_Declaration): Set SPARK_Mode only for non-generic
9048         packages.
9049         * sem_prag.adb (Analyze_Pragma/Pragma_SPARK_Mode): Implement new
9050         consistency rules.
9052 2014-01-27  Robert Dewar  <dewar@adacore.com>
9054         * sem_res.adb (Resolve_Comparison_Op): Add type name/location
9055         to unordered msg.
9056         (Resolve_Range): Add type name/location to unordered msg.
9058 2014-01-27  Claire Dross  <dross@adacore.com>
9060         * a-cofove.adb/s (Copy): Add precondition so that Copy (Source,
9061         Capacity) is only called with Capacity >= Length (Source) and
9062         Capacity in Capacity_Range.
9063         * a-cfdlli.adb/s, a-cfhase.adb/s, a-cfhama.adb/s, a-cforse.adb/s,
9064         a-cforma.adb/s (Copy): Add precondition so that Copy (Source, Capacity)
9065         is only called with Capacity >= Source.Capacity. Raise Capacity_Error
9066         in the code is this is not the case.
9068 2014-01-27  Thomas Quinot  <quinot@adacore.com>
9070         * sem_ch4.adb (Analyze_Selected_Component): Fix handling of
9071         selected component in an instance where the component of the
9072         actual is not visibile at instantiation.
9074 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
9076         * sem_ch6.adb: sem_ch6.adb (Set_Actual_Subtypes): If the type
9077         has a dynamic predicate, generate freeze node for Actual_Subtype
9078         at once, because the declaration of the corresponding predicate
9079         function will make reference to it.
9081 2014-01-27  Tristan Gingold  <gingold@adacore.com>
9083         * exp_ch7.adb, exp_ch9.adb: Adjust comments.
9085 2014-01-27  Robert Dewar  <dewar@adacore.com>
9087         * exp_ch4.adb (Expand_N_Op_Expon): Remove unsigned type test
9088         for 2**X optimization.
9090 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
9092         * a-suenst.adb: strings.utf_encoding.strings (Decode): Check
9093         explicitly whether value is in range of Character, because the
9094         library is typically compiled with range checks disabled, and
9095         we cannot rely on the implicit check on the argument of 'Val.
9097 2014-01-27  Vincent Celier  <celier@adacore.com>
9099         * a-ciorma.adb, a-cihama.adb (Assign): Copy the Source to the Target,
9100         not the Target to itself.
9102 2014-01-27  Robert Dewar  <dewar@adacore.com>
9104         * vms_conv.ads, ali.adb, sem_ch6.ads, opt.ads, vms_cmds.ads: Minor
9105         changes to avoid incorrect use of unordered enum types.
9107 2014-01-27  Thomas Quinot  <quinot@adacore.com>
9109         * sem_ch4.adb: Minor reformatting.
9111 2014-01-27  Robert Dewar  <dewar@adacore.com>
9113         * scn.adb (Check_End_Of_Line): Removed.
9114         (Error_Long_Line): Removed.
9115         (Determine_License): Use versions of above routines from Scanner.
9116         * scng.adb (Check_End_Of_Line): Moved to spec.
9117         (Error_Long_Line): Removed, no longer used.
9118         * scng.ads (Check_End_Of_Line): Moved here from body.
9120 2014-01-27  Tristan Gingold  <gingold@adacore.com>
9122         * exp_ch7.adb (Build_Cleanup_Statements): Call
9123         Build_Protected_Subprogram_Call_Cleanup to insert the cleanup
9124         for protected body.
9125         * exp_ch9.adb (Build_Protected_Subprogram_Body): Likewise.
9126          Remove Service_Name variable.
9127         (Build_Protected_SUbprogam_Call_Cleanup): New procedure that
9128         factorize code from the above subprograms.
9129         * exp_ch9.ads (Build_Protected_Subprogram_Call_Cleanup): New procedure.
9131 2014-01-27  Hristian Kirtchev  <kirtchev@adacore.com>
9133         * einfo.adb (Has_Option): Reimplemented.
9134         * sem_prag.adb (Analyze_Refinement_Clause): Add global
9135         variables AR_Constit, AW_Constit, ER_Constit, EW_Constit,
9136         External_Constit_Seen and State. Add local variables Body_Ref,
9137         Body_Ref_Elmt and Extra_State. Reimplement part of the logic to
9138         avoid a cumbersome while pool. Verify the legality of an external
9139         state and relevant properties.
9140         (Check_External_Property): New routine.
9141         (Check_Matching_State): Remove parameter profile
9142         and update comment on usage.
9143         (Collect_Constituent): Store the
9144         relevant external property of a constituent.
9145         * sem_util.adb (Async_Readers_Enabled): Update the call to
9146         Has_Enabled_Property.
9147         (Async_Writers_Enabled): Update the call to Has_Enabled_Property.
9148         (Effective_Reads_Enabled): Update the call to Has_Enabled_Property.
9149         (Effective_Writes_Enabled): Update the call to Has_Enabled_Property.
9150         (Has_Enabled_Property): Rename formal parameter Extern to State_Id.
9151         Update comment on usage. Reimplement the logic to recognize the various
9152         formats of properties.
9154 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
9156         * par-ch5.adb: Minor reformatting.
9158 2014-01-27  Tristan Gingold  <gingold@adacore.com>
9160         * s-tposen.ads: Harmonize style and comments.
9162 2014-01-27  Vincent Celier  <celier@adacore.com>
9164         * projects.texi: Document that shared library projects, by
9165         default, cannot import projects that are not shared library
9166         projects.
9168 2014-01-27  Robert Dewar  <dewar@adacore.com>
9170         * sem_ch8.adb (Find_Selected_Component): Use Replace instead
9171         of Rewrite.
9173 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
9175         * a-suenco.adb, a-suenst.adb (Decode): Raise encoding error if
9176         any other exception is raised.
9177         (Convert): If both Input_Scheme and Output_Scheme are UTF_8 it is
9178         still necessary to perform a conversion in order to remove overlong
9179         encodings.
9181 2014-01-27  Robert Dewar  <dewar@adacore.com>
9183         * exp_smem.adb: Minor reformatting.
9185 2014-01-27  Thomas Quinot  <quinot@adacore.com>
9187         * a-calfor.ads: Fix incorrect reference to operator "-" in comment.
9189 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
9191         * sem_res.adb (Make_Call_Into_Operator): In ASIS mode, relocate
9192         nodes for operands to the original node for the call, to preserve
9193         Original_Node pointers within the resolved operands, given that
9194         they may have been rewritten as well. Previous approach copied
9195         the operands into a new tree and lost those pointers.
9197 2014-01-27  Claire Dross  <dross@adacore.com>
9200         * a-cofove.adb, a-cofove.ads: Add Strict_Equal function to the API.
9202 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
9204         * sem_util.adb (Check_Internal_Protected_Use): A call through
9205         an anonymous access parameter of the current protected function
9206         is not a potential modification of the current object.
9208 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
9210         * a-cobove.adb (Reserve_Capacity): Procedure raises
9211         Capacity_Error, not Constraint_Error, when request cannot be
9212         satisfied.
9214 2014-01-27  Vincent Celier  <celier@adacore.com>
9216         * a-coorma.adb, a-cohama.adb (Assign): Copy the Source to the Target,
9217         not the Target to itself.
9219 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
9221         * exp_ch4.adb (Expand_Concatenate): If the target of the
9222         concatenation is a library-level entity, always use the off-line
9223         version of concatenation, regardless of optimization level. This
9224         is space-efficient, and prevents linking problems when some
9225         units are compiled with different optimization levels.
9227 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
9229         * sem_ch5.adb: Code clean up.
9231 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
9233         * par-ch5.adb (P_Iterator_Specification): Improve error recovery
9234         when an array or container iterator includes a subtype indication,
9235         which is only legal in an element iterator.
9237 2014-01-27  Thomas Quinot  <quinot@adacore.com>
9239         * exp_ch7.adb: Minor reformatting.
9241 2014-01-27  Robert Dewar  <dewar@adacore.com>
9243         * opt.adb (SPARK_Mode): Default for library units is None rather
9244         than Off.
9245         * opt.ads: Remove AUTO from SPARK_Mode_Type SPARK_Mode_Type is
9246         no longer ordered.
9247         * sem_prag.adb (Analyze_Pragma, case SPARK_Mode): Remove AUTO
9248         possibility.
9249         * snames.ads-tmpl (Name_Auto): Removed, no longer used.
9251 2014-01-27  Robert Dewar  <dewar@adacore.com>
9253         * par-ch5.adb (P_Sequence_Of_Statements): Make entry in
9254         Suspicious_Labels table if we have identifier; followed by loop
9255         or block.
9256         * par-endh.adb (Evaluate_End_Entry): Search Suspicious_Labels table.
9257         * par.adb (Suspicious_Labels): New table.
9259 2014-01-27  Robert Dewar  <dewar@adacore.com>
9261         * exp_aggr.adb (Check_Bounds): Reason is range check, not
9262         length check.
9264 2014-01-27  Yannick Moy  <moy@adacore.com>
9266         * get_spark_xrefs.adb (Get_SPARK_Xrefs): Accept new type 'c' for
9267         reference.
9268         * lib-xref-spark_specific.adb (Is_Global_Constant): Remove useless
9269         function now.
9270         (Add_SPARK_Xrefs): Include references to constants.
9271         * spark_xrefs.ads Document new character 'c' for references to
9272         constants.
9274 2014-01-27  Thomas Quinot  <quinot@adacore.com>
9276         * exp_smem.adb (Add_Write_After): For a function call, insert write as
9277         an after action in a transient scope.
9279 2014-01-27  Thomas Quinot  <quinot@adacore.com>
9281         * exp_smem.adb (Expand_Shared_Passive_Variable): For a reference
9282         to a shared variable as an OUT formal in a call to an init proc,
9283         the 'Read call must be emitted after, not before, the call.
9285 2014-01-27  Robert Dewar  <dewar@adacore.com>
9287         * gnat_rm.texi: Remove mention of AUTO mode for SPARK_Mode pragma.
9289 2014-01-27  Robert Dewar  <dewar@adacore.com>
9291         * a-wichha.adb (Character_Set_Version): Change to output proper
9292         value.
9294 2014-01-27  Hristian Kirtchev  <kirtchev@adacore.com>
9296         * einfo.adb (Is_Input_Only_State): Removed.
9297         (Is_Non_Volatile_State): Removed.
9298         (Is_Output_State): Removed.
9299         * einfo.ads (Is_Input_Only_State): Remove attribute and
9300         subprogram. Update related entity.
9301         (Is_Non_Volatile_State):
9302         Remove attribute and subprogram. Update related entity.
9303         (Is_Output_State): Removed attribute and subprogram. Update
9304         related entity.
9305         * exp_ch6.adb (Expand_Subprogram_Contract): Update comment on
9306         generated code.
9307         * sem_ch3.adb (Analyze_Declarations): Analyze the contract of
9308         an object, not just variables.
9309         (Analyze_Object_Contract): New routine.
9310         (Analyze_Variable_Contract): Removed.
9311         (Process_Discriminants): Detect an illegal use of volatile
9312         discriminant in SPARK mode.
9313         * sem_ch5.adb (Analyze_Iterator_Specification):
9314         Detect an illegal use of volatile loop variable.
9315         (Analyze_Loop_Parameter_Specification): Detect an illegal use
9316         of volatile loop variable.
9317         * sem_ch6.adb (Process_Formals): Update the volatile object
9318         detection. Detect an illegal formal of mode IN OUT or OUT in
9319         SPARK mode. Enhance the error messages with references.
9320         * sem_ch12.adb (Instantiate_Object): Update the volatile object
9321         detection. Enhance the error messages with references.
9322         * sem_prag.adb (Analyze_Abstract_State): Enhance the error
9323         messages with references.
9324         (Analyze_Contract_Case): Enhance the error messages with references.
9325         (Analyze_External_Property): Call Check_Duplicate_Property to process
9326         an external property.
9327         (Analyze_External_Property_In_Decl_Part): New routine.
9328         (Analyze_External_State_In_Decl_Part): Removed.
9329         (Analyze_Global_Item): Detect an illegal
9330         use of a volatile constant. Detect an illegal use
9331         of a variable with enabled Effective_Reads. Enhance
9332         the error messages with references. Remove obsolete
9333         checks concerning Input_Only and Output_Only states.
9334         (Analyze_Initialization_Item): Enhance the error messages
9335         with references.
9336         (Analyze_Initializes_In_Decl_Part): Do not
9337         collect the states and variables when the initialization list
9338         is null.
9339         (Analyze_Input_Item): Enhance the error messages with references.
9340         (Analyze_Input_Output): Enhance the error messages with references.
9341         (Analyze_Pragma): Enhance the error messages with references.
9342         (Analyze_Refinement_Clause): Code reformatting.
9343         (Analyze_Refined_Depends_In_Decl_Part):
9344         Rename global variable Global to Reg_Global and update all
9345         occurrences. Add local variables D7 and D8. Update the error
9346         messages with references. Update the call to Collect_Global_Items.
9347         (Analyze_Refined_Global_In_Decl_Part): Add local variables
9348         Has_Proof_In_State, Proof_In_Constits and Proof_In_Items. Update
9349         the call to Collect_Global_Items.  Account for a Proof_In state
9350         in null / useless refinement checks. Verify the coverage of
9351         Proof_In states.
9352         (Check_Dependency_Clause): Remove local variable
9353         Out_Constits. Remove the retrieval and removal of constituents
9354         for an Output_Only state. Remove the reporting of unused
9355         Output_Only state constituents.
9356         (Check_Duplicate_Mode): Enhance
9357         the error message with a reference.
9358         (Check_Duplicate_Property): New routine.
9359         (Check_Duplicate_Option): Enhance the error message with a reference.
9360         (Check_External_Properties): Enhance the error message with a reference.
9361         (Check_Function_Return): Enhance the error message with a reference.
9362         (Check_In_Out_States): Update
9363         comment on usage. Add a specialized error message for Proof_In
9364         constituents. Enhance the error message with a reference.
9365         (Check_Input_States): Update comment on usage. Account for
9366         possible Proof_In constituents. Enhance the error message
9367         with a areference.
9368         (Check_Matching_Constituent): Enhance the error message with a
9369         reference.
9370         (Check_Matching_State): Enchance the error message with a reference.
9371         (Check_Mode): Add local variable From_Global. Update the call to
9372         Find_Mode.  Emit more precise error messages concerning extra items
9373         (Check_Mode_Restriction_In_Enclosing_Context): Consider
9374         pragma Refined_Global.  Enhance the error message with a
9375         reference.
9376         (Check_Mode_Restriction_In_Function): Enhance the error message with
9377         a reference.
9378         (Check_Output_States): Update comment on usage. Add local variable
9379         Posted.  Account for possible Proof_In constituents. Produce a detailed
9380         list of missing constituents.
9381         (Check_Proof_In_States): New routine.
9382         (Check_Refined_Global_Item): Handle Proof_In
9383         constituents. Enchance the error message with a reference.
9384         (Collect_Global_Items): Add formal parameters Proof_In_Items
9385         and Has_Proof_In_State. Update the comment on usage. Account
9386         for Proof_In items.
9387         (Create_Or_Modify_Clause): Enchance
9388         the error message with a reference.
9389         (Find_Mode): Add
9390         formal parameter From_Global. Update the comment on usage.
9391         Detect when the mode is governed by pragma [Refined_]Global.
9392         (Output_Constituents): Removed.
9393         (Report_Extra_Constituents):
9394         Report extra Proof_In constituents.
9395         (Report_Unused_Constituents): Removed.
9396         (Usage_Error): Code reformatting. Enhance the error
9397         messages with reference.
9398         * sem_prag.ads (Analyze_External_Property_In_Decl_Part): New routine.
9399         (Analyze_External_State_In_Decl_Part): Removed.
9400         * sem_res.adb (Resolve_Actuals): Update the volatile object
9401         detection. Enhance the error message with a reference.
9402         (Resolve_Entity_Name): Update the volatile object
9403         detection. Enhance the error message with a reference.
9404         * sem_util.adb (Is_Refined_State): Add a guard to avoid a crash.
9405         (Is_SPARK_Volatile_Object): New routine.
9406         (Has_Volatile_Component): New routine.
9407         * sem_util.ads (Is_Delegate): Alphabetized.
9408         (Is_SPARK_Volatile_Object): New routine.
9409         (Has_Volatile_Component): New routine.
9410         * snames.ads-tmpl: Remove names Name_Input_Only and Name_Output_Only.
9412 2014-01-27  Ed Schonberg  <schonberg@adacore.com>
9414         * sem_attr.adb: Resolve fully prefix of 'Update.
9416 2014-01-27  Ben Brosgol  <brosgol@adacore.com>
9418         * gnat_rm.texi: Minor clarifications.
9420 2014-01-27  Robert Dewar  <dewar@adacore.com>
9422         * sem_elab.adb (Check_Internal_Call_Continue): Avoid complaining
9423         about call that is generated as part of an Initial_Condition
9424         check.
9425         * sem_prag.adb: Minor spelling correction.
9427 2014-01-27  Robert Dewar  <dewar@adacore.com>
9429         * sem_prag.adb (Set_Convention_From_Pragma): Check that
9430         convention Ghost can only apply to functions.
9431         * einfo.ads, einfo.adb (Is_Ghost_Subprogram): Add clarifying comment.
9433 2014-01-27  Robert Dewar  <dewar@adacore.com>
9435         * gnat_ugn.texi: Add Short_Enums to documentation of
9436         -gnatet/-gnateT.
9438 2014-01-27  Robert Dewar  <dewar@adacore.com>
9440         * sem_prag.adb (Analyze_Input_Item): Correct check for input
9441         item in same package.
9442         * sem_util.ads, sem_util.adb (Within_Scope): New function.
9444 2014-01-26  Arnaud Charlet  <charlet@adacore.com>
9446         * a-intnam-lynxos.ads, mlib-tgt-specific-lynxos.adb,
9447         s-osinte-lynxos-3.adb, s-osinte-lynxos-3.ads, s-osinte-lynxos.adb,
9448         s-osinte-lynxos.ads, s-taprop-lynxos.adb, s-tpopsp-lynxos.adb,
9449         system-lynxos-ppc.ads, system-lynxos-x86.ads: Removed, no longer
9450         maintained.
9452 2014-01-25  Eric Botcazou  <ebotcazou@adacore.com>
9454         * gcc-interface/Makefile.in: Fix oversight.
9456 2014-01-25  Eric Botcazou  <ebotcazou@adacore.com>
9458         * gcc-interface/utils.c (convert_to_fat_pointer): Un-obfuscate the
9459         conversion from a thin pointer with a shifted value.
9460         * gcc-interface/utils2.c (gnat_build_constructor): Propagate the
9461         read-only flag from the values onto the result.
9462         (gnat_invariant_expr): Accept read-only CONSTRUCTORs.
9464 2014-01-25  Tristan Gingold  <gingold@adacore.com>
9466         * gcc-interface/decl.c (gnat_to_gnu_entity): Always build a variable
9467         for E_Variable with a pragma Linker_Section.
9469 2014-01-25  Robert Dewar  <dewar@adacore.com>
9471         * gcc-interface/decl.c (gnat_to_gnu_param): Make sure an Out parameter
9472         with Default_Value aspect is passed in by copy.
9474 2014-01-24  Eric Botcazou  <ebotcazou@adacore.com>
9476         * set_targ.adb: Set Short_Enums.
9477         * gcc-interface/lang.opt (fshort-enums): New option.
9478         * gcc-interface/misc.c (gnat_handle_option): Handle it.
9479         (gnat_post_options): Do not modify the global settings.
9481 2014-01-24  Robert Dewar  <dewar@adacore.com>
9483         * g-rannum.ads, g-rannum.adb (Random_Ordinary_Fixed): New generic
9484         function.
9485         (Random_Decimal_Fixed): New generic function.
9486         * s-rannum.ads: Minor comment clarifications.
9488 2014-01-24  Robert Dewar  <dewar@adacore.com>
9490         * back_end.adb: Remove Short_Enums handling (handled in
9491         Ttypes/Get_Targ now) Minor added comments.
9492         * freeze.adb: Change name Short_Enums_On_Target to
9493         Target_Short_Enums.
9494         * get_targ.ads, get_targ.adb (Get_Short_Enums): New function.
9495         * opt.ads: Minor comment updates.
9496         * sem_ch13.adb: Change name Short_Enums_On_Target to
9497         Target_Short_Enums.
9498         * set_targ.adb: Set Short_Enums from gcc back end.
9499         * set_targ.ads (Short_Enums): New variable.
9500         * targparm.ads, targparm.adb: Remove Short_Enums entries (handled in
9501         Ttypes/Get_Targ now).
9502         * ttypes.ads (Target_Short_Enums): New constant boolean switch
9504 2014-01-24  Pascal Obry  <obry@adacore.com>
9506         * g-sercom-mingw.adb: Fix serial port name for port number > 10.
9508 2014-01-24  Gary Dismukes  <dismukes@adacore.com>
9510         * exp_disp.adb (Expand_Dispatching_Call): Call Unqualify on Param when
9511         comparing it with Ctrl_Arg, since Ctrl_Arg may have had qualification
9512         stripped off.
9514 2014-01-24  Robert Dewar  <dewar@adacore.com>
9516         * sinfo.ads, make.adb, prj-env.adb: Minor reformatting.
9518 2014-01-24  Vincent Celier  <celier@adacore.com>
9520         * prj.adb (Add_Aggregated_Project): Do not add a project in
9521         the list if it is already there.
9523 2014-01-24  Yannick Moy  <moy@adacore.com>
9525         * lib-xref-spark_specific.adb (Enclosing_Subprogram_Or_Package):
9526         Correct the search for a subrogram declaration to which a pragma is
9527         attached.
9529 2014-01-24  Bob Duff  <duff@adacore.com>
9531         * gnat_ugn.texi: Document --decimal-grouping and
9532         --based-grouping switches in gnatpp.
9534 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
9536         * sinfo.ads: Documentation update.
9538 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
9540         * sem_ch3.adb (Constant_Redeclaration): New declaration is
9541         illegal if previous one has an initial expression that is an
9542         aggregate expanded into assignments.
9544 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
9546         * sem_ch5.adb (Analyze_Loop_Parameter_Specification): Small
9547         code reorganization to remove spurious warning on a loop with
9548         an array element iterator that has a null range.
9550 2014-01-24  Vincent Celier  <celier@adacore.com>
9552         * make.adb (Binding_Phase): When setting the Ada paths, use
9553         the library ALI dir, not the object dir in libraries.
9555 2014-01-24  Yannick Moy  <moy@adacore.com>
9557         * sinfo.ads: Add documentation of check flag fields.
9559 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
9561         * sem_res.adb (Resolve_Actuals): If an actual is a view
9562         conversion of a discriminated object, and the formal type is
9563         discriminated and constrained, apply a discriminant check to
9564         the object itself.
9566 2014-01-24  Robert Dewar  <dewar@adacore.com>
9568         * prj.adb, prj-env.adb, back_end.adb: Add comment, minor code clean ups.
9570 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
9572         * sem_ch3.adb (Analyze_Declarations): At the end of an
9573         appropriate declarative part, call Freeze_All from the first
9574         declaration in the scope, not from the first unfrozen one. This
9575         is necessary to apply visibility checks to entities with delayed
9576         aspects. Otherwise, in the presence of instantiations and cleanups
9577         that they may generate, the delayed aspects may be analyzed too
9578         late and produce spurious visibility errors.
9579         * sem_attr.adb: Place etype on range.
9580         * sem_ch6.adb: Documentation expression functions.
9582 2014-01-24  Robert Dewar  <dewar@adacore.com>
9584         * exp_ch7.adb: Minor change of Indices to Indexes (preferred
9585         terminology in compiler).
9587 2014-01-24  Robert Dewar  <dewar@adacore.com>
9589         * scans.ads: Remove Tok_Raise from Sterm, Eterm, After_SM
9590         categories, now that Ada 95 supports raise expressions.
9592 2014-01-24  Robert Dewar  <dewar@adacore.com>
9594         * freeze.adb (Freeze_Enumeration_Type): Use new target parameter
9595         Short_Enums_On_Target.
9596         * sem_ch13.adb (Set_Enum_Esize): Take Short_Enums_On_Target
9597         into account.
9598         * targparm.ads, targparm.adb: Add new target parameter Short_Enums.
9600 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
9602         * sem_ch5.adb (Analyze_Iterator_Specification): If subtype
9603         indication is given explicity, check that it matches the array
9604         component type or the container element type of the domain
9605         of iteration.
9607 2014-01-24  Tristan Gingold  <gingold@adacore.com>
9609         * back_end.adb (Scan_Compiler_Arguments): Set Short_Enums_On_Target.
9610         * gcc-interface/misc.c (flag_short_enums): Declare.
9611         (gnat_post_options): Set it.
9613 2014-01-24  Vincent Celier  <celier@adacore.com>
9615         * prj-env.adb (Ada_Objects_Path): Use Ada_Objects_Path_No_Libs
9616         to cache the result when Including_Libraries is False.
9617         * prj-env.ads (Ada_Objects_Path): Update documentation
9618         * prj.adb (Free (Project_Id)): Also free Ada_Objects_Path_No_Libs
9619         (Get_Object_Directory): Return the Library_Ali_Dir only when
9620         when Including_Libraries is True.
9621         * prj.ads (Get_Object_Directory): Fix and complete documentation
9622         (Project_Data): New component Ada_Objects_Path_No_Libs
9624 2014-01-24  Robert Dewar  <dewar@adacore.com>
9626         * checks.adb (Expr_Known_Valid): Result of fpt operator never
9627         considered valid.
9629 2014-01-24  Eric Botcazou  <ebotcazou@adacore.com>
9631         * back_end.adb: Minor fix in comment.
9633 2014-01-24  Javier Miranda  <miranda@adacore.com>
9635         * sem_ch3.adb (Check_Abstract_Overriding): Code reestructuration
9636         required to report the error in case of task types.
9638 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
9640         * sem_attr.adb: Additional index checking.
9642 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
9644         * sem_attr.adb (Analyze_Attribute, case 'Update): Analyze
9645         expressions in each component association, and for records note
9646         the entity in each association choice, for subsequent resolution.
9647         (Resolve_Attribute, case 'Update): Complete resolution of
9648         expressions in each component association.
9650 2014-01-24  Robert Dewar  <dewar@adacore.com>
9652         * sem.adb (Sem): Avoid premature reference to Current_Sem_Unit
9653         (this was causing Is_Main_Unit_Or_Main_Unit_Spec to be set wrong,
9654         leading to wrong handling of SPARK_Mode for library units).
9656 2014-01-24  Robert Dewar  <dewar@adacore.com>
9658         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Set SPARK_Mode
9659         on generic instances (do not consider them to be internally
9660         generated)
9662 2014-01-24  Doug Rupp  <rupp@adacore.com>
9664         * s-osinte-android.ads (pthread_sigmask): Import sigprocmask
9665         vice pthread_sigmask.
9667 2014-01-24  Vincent Celier  <celier@adacore.com>
9669         * prj.adb (Debug_Output (Str, Str2)): Output if verbosity is
9670         not default.
9672 2014-01-24  Vincent Celier  <celier@adacore.com>
9674         * prj-ext.adb (Add): Do not output anything when Silent is True,
9675         whatever the verbosity. When Source is From_External_Attribute,
9676         set the corresponding environment variable if it is not already set.
9677         * prj-ext.ads (Add): New Boolean parameter Silent, defaulted
9678         to False
9679         * prj-proc.adb (Process_Expression_For_Associative_Array):
9680         For attribute External, call Prj.Ext.Add with Silent set to
9681         True for the child environment, to avoid useless output in non
9682         default verbosity.
9684 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
9686         * sem_res.adb (Set_Slice_Subtype): Handle properly a discrete
9687         range given by a subtype indication, and force evaluation of
9688         the bounds, as for a simple range.
9689         * exp_util.adb (Evaluate_Slice_Bounds): Utility to force evaluation
9690         of bounds of slice for various kinds of discrete ranges.
9691         (Evaluate_Name, Evaluate_Subtype_From_Expr): use
9692         Evaluate_Slice_Bounds.
9694 2014-01-24  Bob Duff  <duff@adacore.com>
9696         * s-taskin.ads (Activator): Make this Atomic, because
9697         Activation_Is_Complete reads it, and that can be called
9698         from any task. Previously, this component was only
9699         modified by the activator before activation, and by
9700         Self after activation.
9701         * a-taside.ads, a-taside.adb (Environment_Task,
9702         Activation_Is_Complete): Implement these missing functions.
9704 2014-01-24  Doug Rupp  <rupp@adacore.com>
9706         * init.c: Add a handler section for Android.
9708 2014-01-24  Arnaud Charlet  <charlet@adacore.com>
9710         * i-cexten.ads (Unsigned_33..64, Unsigned_33..64): New types.
9712 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
9714         * sem_ch4.adb (Operator_Check): If one operand is a
9715         Raise_Expression, set its type to that of the other operand.
9716         * sem_res.adb (Resolve_Raise_Expression): new procedure.
9717         (Resolve_Actuals): For an actual that is a Raise_Expression,
9718         set the type to that of the formal.
9719         * sem_type.adb (Find_Unique_Type): If one of the operands is a
9720         Raise_Expression, return type of the other operand.
9722 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
9724         * sem_aggr.adb (Resolve_Record_Aggregate): If a scalar
9725         component of the record has a type with a default aspect, and
9726         the corresponding aggregate component is initiaized with a box,
9727         use the default value in the rewritten aggregate.
9729 2014-01-24  Tristan Gingold  <gingold@adacore.com>
9731         * s-interr.ads, s-interr.adb, s-interr-hwint.adb, s-interr-vms.adb,
9732         s-interr-sigaction.adb,
9733         s-interr-dummy.adb (Install_Restricted_Handlers): Add Prio parameter.
9734         * exp_ch9.adb (Make_Initialize_Protection): Add Prio parameter
9735         to the call to Install_Restricted_Handlers.
9737 2014-01-24  Emmanuel Briot  <briot@adacore.com>
9739         * prj-nmsc.adb (Check_File): Add protection when the source is
9740         not fully initialized.
9742 2014-01-24  Ed Schonberg  <schonberg@adacore.com>
9744         * sem_util.adb (Is_Post_State): In a postcondition, a selected
9745         component that denotes an implicit dereference is a reference
9746         to the post state of the subprogram.
9748 2014-01-24  Robert Dewar  <dewar@adacore.com>
9750         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): SPARK_Mode OFF
9751         for generated subprograms.
9752         (Analyze_Subprogram_Specification): Ditto.
9754 2014-01-24  Vincent Celier  <celier@adacore.com>
9756         * prj-dect.adb (Check_Attribute_Allowed): Detect more forbidden
9757         attributes in package Builder of aggregate and aggregate library
9758         projects.
9759         * prj-nmsc.adb (Process_Naming_Scheme.Check.Check_Aggregate):
9760         Remove procedure (Process_Naming_Scheme.Check.Check_Aggregated):
9761         Remove parameters.  Change error message from "... externally
9762         build library ..." to "... externally built project ...".
9763         (Process_Naming_Scheme.Check): Do not do any check in aggregate
9764         project, as attribute Library_Dir and Library_Name have already
9765         been detected as forbidden.
9767 2014-01-24  Vincent Celier  <celier@adacore.com>
9769         * prj-env.adb (Find_Project): If cached project path is not in
9770         project directory, look in current directory first and use cached
9771         project path only if project is not found in project directory.
9773 2014-01-24  Robert Dewar  <dewar@adacore.com>
9775         * sem_util.adb, lib-xref.adb: Correct false positive warnings.
9777 2014-01-24  Vincent Celier  <celier@adacore.com>
9779         * projects.texi: Document that aggregate projects are only
9780         supported by gprbuild, but not by gnatmake.  Document that the
9781         only attribute Switches in package Binder of aggregate projects
9782         will be ignored if its index is not others.  Document that
9783         attribute Global_Config_File is allowed in package Binder of
9784         aggregate projects.
9786 2014-01-24  Robert Dewar  <dewar@adacore.com>
9788         * sem_prag.adb: Minor code reorganization.
9789         * sem_util.adb: Minor fix of potential latent bug in Is_LHS.
9791 2014-01-24  Pascal Obry  <obry@adacore.com>
9793         * prj-attr.adb, projects.texi, snames.ads-tmpl: Add Excluded_Patterns
9794         attribute definition.
9796 2014-01-24  Vincent Celier  <celier@adacore.com>
9798         * makeutl.adb (Queue.Insert_No_Roots): In gprbuild, do not put
9799         in the Queue the same source (same path, same multi-source index)
9800         from the same project file, to avoid compiling several times
9801         the same source.
9803 2014-01-24  Eric Botcazou  <ebotcazou@adacore.com>
9805         * einfo.ads (First_Rep_Item): Remove obsolete stuff.
9806         (Has_Gigi_Rep_Item): Likewise.
9807         * sem_prag.adb (Analyze_Pragma) <Pragma_Linker_Section>: Do not set
9808         Has_Gigi_Rep_Item for objects.
9809         * gcc-interface/decl.c (prepend_one_attribute_to): Rename into...
9810         (prepend_one_attribute): ...this.
9811         (prepend_one_attribute_pragma): New function extracted from...
9812         (prepend_attributes): ...here.  Swap the parameters for consistency.
9813         (gnat_to_gnu_entity): Adjust calls to prepend_one_attribute_to and to
9814         prepend_attributes.
9815         <object>: Deal with a pragma Linker_Section on a constant
9816         or variable.  <E_Function>: Deal with a pragma Linker_Section
9817         on a subprogram.
9818         (get_minimal_subprog_decl): Adjust calls to prepend_one_attribute_to.
9820 2014-01-24  Vincent Celier  <celier@adacore.com>
9822         * opt.ads: Minor comment update.
9824 2014-01-24  Robert Dewar  <dewar@adacore.com>
9826         * sem_prag.adb (Analyze_Input_Output): Add missing error check
9827         for junk operand.
9828         * sem_util.adb (Is_Refined_State): Add defense against junk
9829         tree from error.
9831 2014-01-24  Pascal Obry  <obry@adacore.com>
9833         * projects.texi: Removes Build_Slaves attribute documentation.
9835 2014-01-23  Robert Dewar  <dewar@adacore.com>
9837         * opt.adb (Register_Opt_Config_Switches): Save SPARK_Mode_Pragma
9838         setting.
9840 2014-01-23  Ed Schonberg  <schonberg@adacore.com>
9842         * sem_util.adb (Is_Potentially_Unevaluated): Predicate only
9843         applies to expressions that come from source.
9844         * sem_attr.adb (Analyze_Attribute, case 'Old): Improve error
9845         message.
9846         (Analyze_Attribute, case 'Loop_Entry): Apply SPARK 2014 legality
9847         rule regarding potentially unevaluated expressions, to prefix
9848         of attribute.
9850 2014-01-23  Ed Schonberg  <schonberg@adacore.com>
9852         * exp_util.adb (Make_Invqriant_Call): If type of expression is
9853         a private extension, get invariant from base type.
9855 2014-01-23  Robert Dewar  <dewar@adacore.com>
9857         * sem_util.adb, sem_attr.adb: Minor reformatting.
9859 2014-01-23  Robert Dewar  <dewar@adacore.com>
9861         * opt.adb (Save_Opt_Config_Switches): Save SPARK_Mode_Pragma
9862         (Restore_Opt_Config_Switches): Restore SPARK_Mode_Pragma.
9863         * sem.adb (Semantics): Remove save/restore of
9864         SPARK_Mode[_Pragma]. Not needed since already done in
9865         Save/Restore_Opt_Config_Switches.
9867 2014-01-23  Robert Dewar  <dewar@adacore.com>
9869         * gnat_rm.texi, einfo.adb, einfo.ads, sem_prag.adb, gnat_ugn.texi,
9870         freeze.adb, repinfo.adb, aspects.adb, aspects.ads, sem_ch13.adb:
9871         Linker_Section enhancements.
9873 2014-01-23  Tristan Gingold  <gingold@adacore.com>
9875         * gnat_rm.texi: Minor editing.
9877 2014-01-23  Robert Dewar  <dewar@adacore.com>
9879         * opt.adb (Set_Opt_Config_Switches): Reset SPARK mode for
9880         with'ed internal units.
9881         * sem.adb (Semantics): Save and restore SPARK_Mode[_Pragma].
9883 2014-01-23  Javier Miranda  <miranda@adacore.com>
9885         * lib-xref.adb (Generate_Reference): As part of processing the
9886         "end-of-spec" reference generate an extra reference to the first
9887         private entity of the package.
9888         * xr_tabls.adb (Add_Reference): No action needed for the extra
9889         'E' reference associated; similar to the processing of the
9890         'e' reference.
9892 2014-01-23  Bob Duff  <duff@adacore.com>
9894         * gnat_ugn.texi: Change "--&pp off" to "--!pp off".
9896 2014-01-23  Ed Schonberg  <schonberg@adacore.com>
9898         * sem_util.ads, sem_util.adb (Is_Potentially_Unevaluated): new
9899         predicate to implement rule given in 6.1.1 (20/3).
9900         * sem_attr.adb (Analyze_Attribute, case 'Old): Reject prefix of
9901         'Old in a postcondition, if it is potentially unevaluated and
9902         it is not an entity name.
9904 2014-01-23  Bob Duff  <duff@adacore.com>
9906         * gnat_ugn.texi: Document the new "--&pp off" feature of gnatpp.
9908 2014-01-23  Robert Dewar  <dewar@adacore.com>
9910         * gnatlink.adb (Gnatlink): Fix problem of generating bad name
9911         msg on VMS.
9913 2014-01-23  Bob Duff  <duff@adacore.com>
9915         * g-dynhta.ads: Minor comment fix.
9917 2014-01-23  Yannick Moy  <moy@adacore.com>
9919         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Inherit SPARK_Mode
9920         from spec on body only when not already inherited on spec. Set
9921         SPARK_Mode from context on body without previous spec.  *
9922         * sem_prag.adb (Analyze_Pragma): Check placement of pragma on
9923         library-level entities.  Correct retrieval of entity from
9924         declaration, for cases where the declaration is not a unit.
9925         * sem_ch12.adb (Instantiate_Object): Avoid
9926         calling Is_Volatile_Object on an empty node.
9928 2014-01-23  Robert Dewar  <dewar@adacore.com>
9930         * gnatlink.adb (Gnatlink): Check for suspicious executable file
9931         names on windows.
9933 2014-01-23  Robert Dewar  <dewar@adacore.com>
9935         * a-ngelfu.ads: Remove bad uses of AND which should be AND THEN.
9936         * sem_res.adb (Check_No_Direct_Boolean_Operators): Don't give
9937         style errors in instances.
9938         * g-dynhta.ads (Static_HTable): Comment updates.
9940 2014-01-23  Vincent Celier  <celier@adacore.com>
9942         * prj-conf.adb (Get_Or_Create_Configuration_File): Do not attempt
9943         to find a configuration project file when Config_File_Name is
9944         No_Configuration_File.
9945         * prj-conf.ads (No_Configuration_File): New constant String.
9946         * prj-pars.adb (Parse): Call Get_Or_Create_Configuration_File
9947         with Config_File_Name set to No_Configuration_File, so that
9948         no existing configuration project file will be used, and the
9949         configuration project will be only created in memory when
9950         Add_Default_GNAT_Naming_Scheme is called.
9951         * projects.texi: Minor reformatting.
9953 2014-01-23  Vincent Celier  <celier@adacore.com>
9955         * prj-conf.adb (Get_Or_Create_Configuration_File): Never parse
9956         a config project file if On_Load_Config is not null.
9957         * prj-pars.adb: Minor comment changes.
9959 2014-01-23  Ed Schonberg  <schonberg@adacore.com>
9961         * lib-xref.adb (Output_References): Output progenitors of
9962         synchronized tagged types, for source navigation.
9964 2014-01-23  Robert Dewar  <dewar@adacore.com>
9966         * exp_util.adb, sinfo.adb, sinfo.ads, sem.adb, sem_res.adb,
9967         expander.adb, exp_ch11.adb, exp_ch11.ads, sem_ch11.adb, sem_ch11.ads,
9968         sprint.adb, sprint.ads: Remove unused node N_Subprogram_Info.
9970 2014-01-23  Emmanuel Briot  <briot@adacore.com>
9972         * prj-conf.adb (Get_Or_Create_Configuration_File): call
9973         On_Load_Config later.
9975 2014-01-23  Hristian Kirtchev  <kirtchev@adacore.com>
9977         * sem_ch3.adb (Analyze_Declarations): Do not
9978         generate the spec of the late primitive in ASIS mode. Add two
9979         comments to explain the special cases when the expansion is
9980         not performed.
9982 2014-01-23  Robert Dewar  <dewar@adacore.com>
9984         * sem_util.adb (Note_Possible_Modification): Fix error of
9985         misbehaving for implicit dereference cases in -gnatc mode.
9987 2014-01-23  Emmanuel Briot  <briot@adacore.com>
9989         * prj-pars.adb: Minor reformatting.
9991 2014-01-22  Ed Schonberg  <schonberg@adacore.com>
9993         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): A subprogram
9994         body generated for an expression function within a protected body
9995         needs a set of renaming declarations if the expression function
9996         comes from source.
9998 2014-01-22  Ed Schonberg  <schonberg@adacore.com>
10000         * lib-xref.adb (Get_Type_Reference): In semantics-only mode,
10001         list interface progenitor of a tagged concurrent type, for better
10002         source navigation.
10004 2014-01-22  Robert Dewar  <dewar@adacore.com>
10006         * lib.adb (In_Extended_Main_Code_Unit): Return False for
10007         Standard_Location.
10008         (In_Extended_Main_Source_Unit): Return False for Standard_Location.
10009         * lib.ads (In_Extended_Main_Code_Unit): Add documentation on
10010         treatment of Slocs No_Location and Standard_Location.
10011         * restrict.adb (Check_Restriction_No_Dependence): Explicitly
10012         check for entity with Standard_Location Sloc, rather than relying
10013         on Lib routines to do that.
10014         * sem_res.adb (Resolve_Call): Implement SPARK_05 restriction
10015         that a call cannot occur before a later occuring body within
10016         the same unit.
10018 2014-01-22  Thomas Quinot  <quinot@adacore.com>
10020         * rtsfind.adb: Update comment.
10022 2014-01-22  Hristian Kirtchev  <kirtchev@adacore.com>
10024         * sem_aux.ads, sem_aux.adb (Is_Body): New routine.
10025         * sem_ch3.adb (Analyze_Declarations): Add local variable
10026         Body_Seen. Generate the spec of a late controlled
10027         primitive body that is about to freeze its related type.
10028         (Handle_Late_Controlled_Primitive): New routine.
10030 2014-01-22  Robert Dewar  <dewar@adacore.com>
10032         * a-stream.adb: Minor reformatting.
10034 2014-01-22  Ed Schonberg  <schonberg@adacore.com>
10036         * sem_ch8.adb (From_Actual_Package): Introduce a recursive
10037         sub-procedure Declared_In_Actual to handle properly the visibility
10038         of actuals in actual packages, that are themselves actuals to a
10039         actual package of the current instance. This mimics properly the
10040         visibility of formals of formal packages declared with a box,
10041         within the corresponding generic unit.
10043 2014-01-22  Robert Dewar  <dewar@adacore.com>
10045         * checks.adb: Do not assume that a volatile variable is valid.
10047 2014-01-22  Thomas Quinot  <quinot@adacore.com>
10049         * g-catiio.ads (Image, Value): Clarify that these functions
10050         operate in the local time zone.  Minor documentation update.
10052 2014-01-22  Thomas Quinot  <quinot@adacore.com>
10054         * csets.adb, csets.ads, opt.ads: Minor documentation fixes.
10056 2014-01-22  Robert Dewar  <dewar@adacore.com>
10058         * sem_aux.adb, sem_aux.ads, sem_ch3.adb (Has_Unconstrained_Elements):
10059         Moved to sem_aux.adb.
10061 2014-01-22  Robert Dewar  <dewar@adacore.com>
10063         * vms_data.ads: Minor reformatting.
10065 2014-01-22  Robert Dewar  <dewar@adacore.com>
10067         * debug.adb: Document messages affected by -gnatd.E including
10068         the new ones that relate to late definition of equality.
10069         * sem_ch6.adb (Check_Untagged_Equality): In Ada 2012 mode, if
10070         debug flag -gnatd.E is set, then generate warnings rather than
10071         errors.
10072         (Check_Untagged_Equality): In earlier versions of Ada,
10073         generate warnings if Warn_On_Ada_2012_Incompatibility flag is set.
10075 2014-01-22  Robert Dewar  <dewar@adacore.com>
10077         * sem_prag.adb (Usage_Error): Output additional messages for
10078         unconstrained OUT parameters lacking an input dependency.
10080 2014-01-22  Robert Dewar  <dewar@adacore.com>
10082         * sem_ch4.adb: Minor reformatting.
10084 2014-01-22  Robert Dewar  <dewar@adacore.com>
10086         * restrict.ads: Minor reformatting.
10087         * sem_res.adb (Resolve_Call): Check for SPARK_05 restriction that
10088         forbids a call from within a subprogram to the same subprogram.
10090 2014-01-22  Thomas Quinot  <quinot@adacore.com>
10092         * a-stream.ads (Read_SEA, Write_SEA): New subprograms, optimized
10093         stream attributes for Stream_Element_Array.
10094         * a-stream.adb (Read_SEA, Write_SEA): Bodies for the above.
10095         * rtsfind.adb (Check_CRT): Do not reject a reference to an entity
10096         defined in the current scope.
10098 2014-01-22  Robert Dewar  <dewar@adacore.com>
10100         * debug.adb, exp_ch4.adb, erroutc.adb: Minor reformatting.
10102 2014-01-22  Thomas Quinot  <quinot@adacore.com>
10104         * sem_ch7.adb, sem_ch8.adb, exp_ch3.adb: Minor reformatting.
10106 2014-01-22  Thomas Quinot  <quinot@adacore.com>
10108         * sem_ch3.adb (Analyze_Object_Declaration): For a constant
10109         declaration initialized with a function call, whose type
10110         has variable size, need to remove side effects so that the
10111         initialization expression becomes a dereference of a temporary
10112         reference to the function result.
10114 2014-01-22  Yannick Moy  <moy@adacore.com>
10116         * errout.adb (Initialize): Remove trick to add dummy entry
10117         in Warnings table.
10118         * erroutc.adb (Set_Warnings_Mode_Off,
10119         Set_Warnings_Mode_On): Do nothing if warnings are suppressed by
10120         command line switch.
10121         * opt.ads (Warning_Mode): Document behavior
10122         wrt pragma Warnings, in normal mode and in GNATprove_Mode.
10124 2014-01-22  Robert Dewar  <dewar@adacore.com>
10126         * sem_ch3.adb, errout.adb, erroutc.adb: Minor reformatting.
10128 2014-01-22  Robert Dewar  <dewar@adacore.com>
10130         * sem_ch13.adb (Check_Pool_Size_Clash): New procedure
10131         (Analyze_Attribute_Definition_Clause, case Storage_Pool): call
10132         Check_Pool_Size_Clash (Analyze_Attribute_Definition_Clause,
10133         case Storage_Size): call Check_Pool_Size_Clash.
10135 2014-01-22  Robert Dewar  <dewar@adacore.com>
10137         * sem_ch3.adb, exp_util.adb, sem_dim.adb, sem_elab.adb, sem_ch8.adb,
10138         sem_eval.ads: Minor reformatting.
10140 2014-01-22  Thomas Quinot  <quinot@adacore.com>
10142         * sem_eval.adb (Compile_Time_Known_Bounds): Return False for
10143         Any_Composite to prevent cascaded errors.
10145 2014-01-22  Yannick Moy  <moy@adacore.com>
10147         * errout.adb (Initialize): Do not insert special entry in Warnings
10148         table in GNATprove_Mode.
10149         * erroutc.adb (Set_Warnings_Mode_On): Add info in Warnings table in
10150         GNATprove_Mode.
10151         * gnat1drv.adb (Adjust_Global_Switches): Do not suppress frontend
10152         warnings anymore.
10154 2014-01-22  Robert Dewar  <dewar@adacore.com>
10156         * sem_prag.adb (Analyze_Initializes_In_Decl_Part): Handle null
10157         initializes case.
10159 2014-01-22  Robert Dewar  <dewar@adacore.com>
10161         * snames.ads-tmpl: Update header.
10163 2014-01-22  Thomas Quinot  <quinot@adacore.com>
10165         * exp_util.adb (Insert_Actions): When inserting actions on a
10166         short circuit operator that has already been analyzed, do not park
10167         actions in node; instead introduce an N_Expression_With_Actions
10168         and insert actions immediately.
10169         Add guard for unexpected case of climbing up through statement
10170         in Actions list of an N_Expression_With_Actions.
10171         * sem_elab.adb (Insert_Elab_Check): Remove complex
10172         specialized circuitry for the case where the context is already
10173         analyzed, as it is not needed and introduces irregularities in
10174         finalization. Instead rely on the above change to Insert_Actions
10175         to ensure that late insertion on short circuit operators works
10176         as expected.
10178 2014-01-22  Ed Schonberg  <schonberg@adacore.com>
10180         * sem_ch4.adb (Operator_Check): Improve error message when an
10181         operand of concatenation is an access type.
10183 2014-01-22  Thomas Quinot  <quinot@adacore.com>
10185         * sem_dim.adb (Analyze_Dimension_Identifier): Add guard against
10186         cascaded error.
10188 2014-01-22  Ed Schonberg  <schonberg@adacore.com>
10190         * sem_ch8.adb (Find_Selected_Component): Handle properly the case
10191         of an expanded name in a proper body, whose prefix is a package
10192         in the context of the proper body, when there is a homonym of
10193         the package declared in the parent unit.
10195 2014-01-22  Robert Dewar  <dewar@adacore.com>
10197         * sem_warn.adb (Check_Use_Clause): Don't give no entities used
10198         msg if errors found.
10199         (Check_One_Unit): Same change.
10201 2014-01-22  Robert Dewar  <dewar@adacore.com>
10203         * ug_words: Add missing/wrong entries for VMS warning switches.
10204         * sem_prag.adb (Check_Duplicate_Pragma): Avoid flagging parent type.
10206 2014-01-22  Jerome Guitton  <guitton@adacore.com>
10208         * mlib-tgt-specific-vxworks.adb (Get_Target_Suffix): Replace xscale by
10209         arm.
10211 2014-01-22  Robert Dewar  <dewar@adacore.com>
10213         * gnat_rm.texi, gnat_ugn.texi: Document passive task optimization
10215 2014-01-22  Eric Botcazou  <ebotcazou@adacore.com>
10217         * gcc-interface/Makefile.in: Minor fixes.
10219 2014-01-21  Robert Dewar  <dewar@adacore.com>
10221         * par-ch4.adb (P_If_Expression): Rewritten to improve error recovery.
10222         * par-ch5.adb (P_Condition): New version with expression prescanned.
10223         * par.adb (P_Condition): New version with expression prescanned.
10225 2014-01-21  Robert Dewar  <dewar@adacore.com>
10227         * gnat_rm.texi: Document that Allow_Integer_Address is ignored
10228         if Address is not a private type.
10229         * sem_prag.adb (Analyze_Pragma, case Allow_Integer_Address):
10230         Ignore pragma if System.Address is not a private type.
10232 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
10234         * namet.ads (Name_Len): Initialize to 0 to avoid accessing an
10235         uninitialized value.
10237 2014-01-21  Thomas Quinot  <quinot@adacore.com>
10239         * gnat_rm.texi (Scalar_Storage_Order): Update documentation.
10241 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
10243         * sem_ch12.adb (Set_Instance_Env): In Ada 2012 mode, preserve
10244         the value of Assertions_Enabled flag when compiling an instance of
10245         an internal unit. This facilitates the use of pre/postconditions
10246         in generic internal units, such as the new elementary function
10247         libraries.
10249 2014-01-21  Robert Dewar  <dewar@adacore.com>
10251         * exp_aggr.adb: Minor reformatting.
10252         * sem_attr.adb: Minor reformatting.
10253         * sem_res.adb: Minor comment addition.
10254         * einfo.adb: Minor comment updates.
10255         * freeze.adb: Minor reformatting and code reorganization.
10257 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
10259         * par-ch4.adb (P_If_Expression): Handle more gracefully an
10260         elsif clause that does not have an else part.
10262 2014-01-21  Robert Dewar  <dewar@adacore.com>
10264         * checks.adb, sem_util.ads, sem_ch4.adb: Minor reformatting.
10265         * gcc-interface/Makefile.in: clean up target pairs.
10267 2014-01-21  Pascal Obry  <obry@adacore.com>
10269         * projects.texi: Minor typo fix.
10271 2014-01-21  Thomas Quinot  <quinot@adacore.com>
10273         * freeze.adb (Check_Component_Storage_Order): If a record type
10274         has an explicit Scalar_Storage_Order attribute definition clause,
10275         reject any component that itself is of a composite type and does
10276         not have one.
10278 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
10280         * sem_ch10.adb (Generate_Parent_Reference): Make public so it
10281         can be used to generate proper cross-reference information for
10282         the parent units of proper bodies.
10284 2014-01-21  Thomas Quinot  <quinot@adacore.com>
10286         * exp_pakd.adb (Expand_Packed_Element_Set,
10287         Expand_Packed_Element_Reference): No byte swapping required in
10288         the front-end for the case of a reverse storage order array,
10289         as this is now handled uniformly in the back-end.  However we
10290         still need to swap back an extracted element if it is itself a
10291         nested composite with reverse storage order.
10293 2014-01-21  Hristian Kirtchev  <kirtchev@adacore.com>
10295         * sem_prag.adb (Analyze_External_Property): Add processing for "others".
10296         (Analyze_Pragma): Update the grammar of pragma Abstract_State to
10297         include "others".
10299 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
10301         * gnat_ugn.texi: Minor updates.
10303 2014-01-21  Thomas Quinot  <quinot@adacore.com>
10305         * exp_pakd.adb: Update comment, minor reformatting.
10307 2014-01-21  Hristian Kirtchev  <kirtchev@adacore.com>
10309         * sem_ch3.adb (Analyze_Variable_Contract): Trigger the volatile
10310         object check when SPARK_Mode is on.
10311         * sem_ch6.adb (Process_Formals): Trigger the volatile object
10312         check when SPARK_Mode is on.
10313         * sem_ch12.adb (Instantiate_Object): Trigger the volatile object
10314         check when SPARK_Mode is on.
10315         * sem_ch13.adb (Analyze_Aspect_Specifications): Insert the
10316         corresponding pragma of aspect SPARK_Mode in the visible
10317         declarations of a package declaration.
10318         * sem_prag.adb (Analyze_Pragma): Trigger the volatile object
10319         check when SPARK_Mode is on.
10320         * sem_res.adb (Resolve_Actuals): Trigger the volatile object
10321         check when SPARK_Mode is on.
10322         (Resolve_Entity_Name): Trigger
10323         the volatile object check when SPARK_Mode is on.
10325 2014-01-21  Robert Dewar  <dewar@adacore.com>
10327         * sem_ch3.adb, sem_prag.adb, sem_prag.ads, sem_ch12.adb, sem_res.adb,
10328         sem_ch6.adb, a-except-2005.adb: Minor reformatting.
10330 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
10332         * exp_ch3.adb (Expand_N_Object_Declaration): When a class-wide
10333         object is declared, it is rewritten as a renaming of an dynamic
10334         expression that wraps the initial value.  The renaming declaration
10335         is first given an internal name, to prevent collisions with the
10336         entity already declared, and then the name is modified to reflect
10337         the original one. the modification of the name must preserve
10338         the source location of the original, to prevent spurious errors
10339         when compiling with style checks if the declaration involves
10340         more than one entity.
10342 2014-01-21  Hristian Kirtchev  <kirtchev@adacore.com>
10344         * aspects.adb Add entries for Async_Readers, Async_Writers,
10345         Effective_Reads and Effective_Writes in table Canonical_Aspect.
10346         * aspects.ads Add entries for Async_Readers, Async_Writers,
10347         Effective_Reads and Effective_Writes in tables Aspect_Id,
10348         Aspect_Names, Aspect_Delay and Implementation_Defined_Aspect.
10349         * atree.adb (Ekind_In): New version with 8 parameters.
10350         (Node34): New routine.
10351         (Set_Node34): New routine.
10352         * atree.ads (Ekind_In): New version with 8 parameters.
10353         (Node34): New routine.
10354         (Set_Node34): New routine.
10355         * einfo.adb Contract is now Node34.
10356         (Contract): Update the assertion and node usage.
10357         (Get_Pragma): Include pragmas Async_Readers, Async_Writers,
10358         Effective_Reads and Effective_Writes.
10359         (Set_Contract): Update the assertion and node usage.
10360         (Write_Field24_Name): Remove the output for a contract.
10361         (Write_Field34_Name): Add output for a contract.
10362         * einfo.ads Contract is now Node34. Update the comment on
10363         attribute usage and related node structures.
10364         (Get_Pragma): Update the comment on usage.
10365         * par-prag.adb (Prag): Pragmas Async_Readers, Async_Writers,
10366         Effective_Reads and Effective_Writes do not require special
10367         processing by the parser.
10368         * sem_ch3.adb (Analyze_Variable_Contract): New routine.
10369         (Analyze_Declarations): Analyze the contract of a variable at
10370         the end of the declarative region.
10371         (Analyze_Object_Declaration): Create a contract for a variable.
10372         * sem_ch6.adb (Analyze_Subprogram_Contract): Update the retrieval
10373         of classification pragmas.
10374         (Process_Formals): Detect an illegal
10375         use of a volatile object as a formal in a function.
10376         * sem_ch12.adb (Instantiate_Object): Detect an illegal use of
10377         a volatile object as an actual in generic instantiation.
10378         * sem_prag.adb Add entries for Async_Readers, Async_Writers,
10379         Effective_Reads and Effective_Writes in table Sig_Flags.
10380         (Analyze_External_State_In_Decl_Part): New routine.
10381         (Analyze_Global_Item): Detect an illegal use of a volatile object
10382         as a global item of a function.
10383         (Analyze_Pragma): Reimplement
10384         pragma Abstract_State. Add support for pragmas Async_Readers,
10385         Async_Writers, Effective_Reads and Effective_Writes.
10386         (Check_External_Properties): New routine.
10387         * sem_prag.ads (Analyze_External_State_In_Decl_Part): New routine.
10388         (Check_External_Properties): New routine.
10389         * sem_res.adb (Resolve_Actuals): Detect an illegal use of a
10390         volatile object as an actual in a call.
10391         (Resolve_Entity_Name):
10392         Add local variables Par, Prev and Usage_OK. Detect illegal
10393         contexts of volatile objects.
10394         * sem_util.adb (Add_Contract_Item): Add support for
10395         pragmas associated with the contract of a variable.
10396         (Async_Readers_Enabled): New routine.
10397         (Async_Writers_Enabled): New routine.
10398         (Effective_Reads_Enabled): New routine.
10399         (Effective_Writes_Enabled): New routine.
10400         (Has_Enabled_Property):
10401         New routine.
10402         (Is_Unchecked_Conversion_Instance): New routine.
10403         (Is_Volatile_Object): Add support for entities that may denote
10404         a volatile object.
10405         * sem_util.ads (Add_Contract_Item): Update the
10406         comment on usage.
10407         (Async_Readers_Enabled): New routine.
10408         (Async_Writers_Enabled): New routine.
10409         (Effective_Reads_Enabled): New routine.
10410         (Effective_Writes_Enabled): New routine.
10411         (Is_Unchecked_Conversion_Instance): New routine.
10412         * sinfo.ads Update the comment on the structure of N_Contract.
10413         * snames.ads-tmpl Add predefined names for Async_Readers,
10414         Async_Writers, Effective_Reads and Effective_Writes. Add
10415         pragma ids for Async_Readers, Async_Writers, Effective_Reads
10416         and Effective_Writes.
10418 2014-01-21  Robert Dewar  <dewar@adacore.com>
10420         * exp_ch4.adb (Eval_Op_Expon): Use CRT_Safe_Compile_Time_Known_Value
10421         * sem_eval.adb (Compile_Time_Known_Value): Remove special
10422         handling of CRT mode (CRT_Safe_Compile_Time_Known_Value): New
10423         function (Eval_Op_Expon): Add CRT_Safe in call to Test_Foldable
10424         (Test_Foldable): Add CRT_Safe parameter
10425         * sem_eval.ads (Compile_Time_Known_Value): Remove special
10426         handling of CRT mode.
10427         (CRT_Safe_Compile_Time_Known_Value): New function.
10429 2014-01-21  Robert Dewar  <dewar@adacore.com>
10431         * sem_prag.adb (Analyze_Pragma, case SPARK_Mode): Fix problem
10432         with pragma or aspect that applies to package spec or subprogram
10433         spec.
10435 2014-01-21  Robert Dewar  <dewar@adacore.com>
10437         * exp_aggr.adb: Minor reformatting.
10439 2014-01-21  Johannes Kanig  <kanig@adacore.com>
10441         * gnat1drv.adb (Gnat1drv) remove obsolete reference to -gnatd.H.
10443 2014-01-21  Bob Duff  <duff@adacore.com>
10445         * gnat_ugn.texi: Document the "checks" attribute in gnat2xml.
10447 2014-01-21  Steve Baird  <baird@adacore.com>
10449         * gnat_rm.texi: Improve description of SPARK_Mode pragma.
10451 2014-01-21  Vincent Celier  <celier@adacore.com>
10453         * prj-part.adb (Parse_Single_Project): Accept to extend a project
10454         if it has only be imported by an project being extended. When a
10455         project that has only been imported by a project being extended
10456         is imported by another project that is not being extended,
10457         reset the previous indication, so that it will be an error if
10458         this project is extended later.
10459         * prj-tree.adb (Create_Project): Include component From_Extended
10460         in table Projects_HT
10461         * prj-tree.ads (Project_Name_And_Node): New Boolean component
10462         From_Extended
10464 2014-01-21  Robert Dewar  <dewar@adacore.com>
10466         * atree.ads, atree.adb: Add Node33 and Set_Node33.
10467         * einfo.ads, einfo.adb (SPARK_Pragma): New field (SPARK_Aux_Pragma):
10468         New field (SPARK_Pragma_Inherited): New flag
10469         (SPARK_Aux_Pragma_Inherited): New flag (SPARK_Mode_Pragmas):
10470         Removed.
10471         * lib.ads, lib.adb: Remove SPARK_Mode_Pragma, no longer used.
10472         * opt.ads (SPARK_Mode_Pragma): New global variable.
10473         * sem.ads: Add Save_SPARK_Mode_Pragma field to Scope_Stack_Entry.
10474         * sem_ch3.adb: Use new SPARK_Mode data structures.
10475         * sem_ch6.adb: Set SPARK_Mode fields in subprogram specs and bodies.
10476         * sem_ch7.adb: Set SPARK_Mode fields in package spec and body entities.
10477         * sem_ch8.adb (Push_Scope): Save SPARK_Mode_Pragma.
10478         (Pop_Scope): Restore SPARK_Mode_Pragma.
10479         * sem_prag.adb (Analyze_Pragma, case SPARK_Mode): Rewrite for
10480         new data structures.
10482 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
10484         * back_end.adb: Undo previous change, not needed. Minor reformatting.
10486 2014-01-21  Thomas Quinot  <quinot@adacore.com>
10488         * exp_ch5.adb: Fix comment.
10489         * switch-c.adb: Minor comment update.
10490         * exp_ch3.adb: Minor reformatting.
10492 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
10494         * back_end.adb (Scan_Compiler_Arguments): Do not store object
10495         filename in gnatprove mode.
10497 2014-01-21  Thomas Quinot  <quinot@adacore.com>
10499         * sinfo.ads (No_Ctrl_Actions): Clarify documentation (flag also
10500         suppresses usage of primitive _assign for tagged types).
10501         * exp_aggr.adb (Build_Array_Aggr_Code.Gen_Assign): Set
10502         No_Ctrl_Actions for a tagged type that does not require
10503         finalization, as we want to disable usage of _assign (which
10504         may cause undesirable discriminant checks on an uninitialized,
10505         invalid target).
10507 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
10509         * sem_prag.adb: Reject invariant'class on completion.
10511 2014-01-21  Javier Miranda  <miranda@adacore.com>
10513         * exp_ch3.adb (Build_Init_Procedure): For
10514         derivations of interfaces, do not move the the initialization
10515         of the _parent field since such assignment is not generated.
10517 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
10519         * sem_res.adb (Rewrite_Renamed_Operator): Do not replace entity
10520         with the operator it renames if we are within an expression of
10521         a pre/postcondition, because the expression will be reanalyzed
10522         at a later point, and the analysis of the renaming may affect
10523         the visibility of the operator when in an instance.
10525 2014-01-21  Robert Dewar  <dewar@adacore.com>
10527         * sinfo.ads, sinfo.adb: Change Do_Discriminant_Check to use new Flag1.
10528         Add this flag to type conversion nodes and assignment nodes.
10529         * treepr.adb: Deal properly with Flag 1,2,3.
10530         * treeprs.adt: Minor comment update.
10532 2014-01-21  Robert Dewar  <dewar@adacore.com>
10534         * sem_eval.adb (Compile_Time_Known_Value): Add Ignore_CRT
10535         parameter.
10536         * sem_eval.ads (Compile_Time_Known_Value): Add Ignore_CRT
10537         parameter, completely rewrite spec.
10539 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
10541         * sem_ch10.adb (Install_Withed_Unit): If the unit is a subprogram
10542         instance that is inlined, it may have been rewritten as a wrapper
10543         package. In that case the unit that must be made visible is the
10544         related instance of the package.
10546 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
10548         * exp_ch9.adb (Expand_N_Selective_Accept.Add_Accept): Refine
10549         previous change in codepeer mode.
10551 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
10553         * exp_ch9.adb (Expand_N_Selective_Accept.Add_Accept): Always add
10554         call to Abort_Undefer, as expected by the runtime.
10555         * s-tasren.adb (Local_Complete_Rendezvous): Replace
10556         Defer_Abort_Nestable by Defer_Abort, since we do not expect abort to be
10557         deferred at this point. Update comments.
10559 2014-01-21  Thomas Quinot  <quinot@adacore.com>
10561         * exp_ch4.adb, exp_ch5.adb, checks.adb: Minor reformatting.
10563 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
10565         * switch-c.adb, usage.adb, gnat_ugn.texi: Mark -gnates as internal,
10566         remove from doc.
10568 2014-01-21  Robert Dewar  <dewar@adacore.com>
10570         * switch-c.adb, usage.adb, atree.adb, atree.ads: Minor reformatting.
10572 2014-01-21  Thomas Quinot  <quinot@adacore.com>
10574         * atree.adb, atree.ads (Num_Extension_Nodes): Switch to Node_Id, since
10575         this is value is used in Node_Id arithmetic operations.
10576         (Copy_Node, Exchange_Entities): Use loops indexed by Num_Extension_Nodes
10577         instead of hard-coded unrolled code.
10579 2014-01-21  Yannick Moy  <moy@adacore.com>
10581         * gnat1drv.adb: Minor code cleanup, removing useless code.
10583 2014-01-21  Arnaud Charlet  <charlet@adacore.com>
10585         * opt.ads (SPARK_Switches_File_Name): New.
10586         * switch-c.adb (Scan_Front_End_Switches): Add handling of -gnates=xxx *
10587         * usage.adb (Usage): Document -gnates, in gnatprove mode only.
10588         * gnat_ugn.texi: Document -gnates.
10590 2014-01-21  Yannick Moy  <moy@adacore.com>
10592         * errout.adb (Special_Msg_Delete): Update comment. Remove
10593         special case for GNATprove which should not ignore mismatch
10594         in sizes for representation clauses.
10595         * sem_prag.adb (Analyze_Pragma): Remove special case for GNATprove
10596         which should not ignore pragma Pack.
10598 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
10600         * sem_ch4.adb: Code clean up.
10602 2014-01-21  Steve Baird  <baird@adacore.com>
10604         * gnat_rm.texi: Improve GNAT RM description of SPARK_Mode pragma.
10606 2014-01-21  Robert Dewar  <dewar@adacore.com>
10608         * gcc-interface/gigi.h: Get Flags array address.
10609         * gcc-interface/trans.c: Acquire Flags array address.
10610         * atree.adb: Add support for Flags array and Flag0,1,2,3.
10611         * atree.ads: Add support for Flags array and Flag0,1,2,3.
10612         * atree.h: Add support for Flags array and Flag0,1,2,3.
10613         * back_end.adb: Pass Flags array address to gigi.
10615 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
10617         * sem_ch8.adb (Attribute_Renaming): Transfer original attribute
10618         reference to generated body so that legality checks on stream
10619         attributes are properly applied. If type is tagged and already
10620         frozen, insert generated body at the point of the renaming
10621         declaration.
10623 2014-01-21  Ed Schonberg  <schonberg@adacore.com>
10625         * sem_ch12.adb: Code clean up.
10626         * sem_ch8.adb: Minor reformatting
10628 2014-01-20  Robert Dewar  <dewar@adacore.com>
10630         * checks.adb: Check SPARK_Mode instead of GNATProve_Mode for
10631         converting warnings on inevitable exceptions to errors.
10632         * exp_ch4.adb: Check SPARK_Mode instead of GNATProve_Mode for
10633         converting warnings on inevitable exceptions to errors.
10634         * opt.adb (SPARK_Mode_Config): Handled like other config flags
10635         * opt.ads (SPARK_Mode_Type): Moved here from types (renamed from
10636         SPARK_Mode_Id) (SPARK_Mode_Type): Add pragma Ordered, remove
10637         SPARK_ from names (SPARK_Mode): New flag (SPARK_Mode_Config):
10638         New flag (Config_Switches_Type): Add SPARK_Mode field
10639         * sem.adb: Minor code reorganization (remove unnecessary with)
10640         * sem.ads (Scope_Stack_Entry): Add Save_SPARK_Mode field
10641         * sem_aggr.adb: Check SPARK_Mode instead of GNATProve_Mode for
10642         converting warnings on inevitable exceptions to errors.
10643         * sem_attr.adb: Check SPARK_Mode instead of GNATProve_Mode for
10644         converting warnings on inevitable exceptions to errors.
10645         * sem_ch3.adb: Check SPARK_Mode instead of GNATProve_Mode for
10646         converting warnings on inevitable exceptions to errors.
10647         * sem_ch4.adb: Check SPARK_Mode instead of GNATProve_Mode for
10648         converting warnings on inevitable exceptions to errors.
10649         * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Reset SPARK_Mode
10650         from spec if needed
10651         * sem_ch7.adb (Analyze_Package_Body_Helper): Reset SPARK_Mode
10652         from spec if needed
10653         * sem_ch8.adb (Push_Scope): Save SPARK_Mode (Pop_Scope):
10654         Restore SPARK_Mode
10655         * sem_elab.adb: Check SPARK_Mode instead of GNATProve_Mode for
10656         converting warnings on inevitable exceptions to errors.
10657         * sem_prag.adb (Get_SPARK_Mode_From_Pragma): New function
10658         (Get_SPARK_Mode_Id): Removed (Get_SPARK_Mode_Type): New name
10659         of Get_SPARK_Mode_Id
10660         * sem_prag.ads (Get_SPARK_Mode_From_Pragma): New function
10661         * sem_res.adb: Check SPARK_Mode instead of GNATProve_Mode for
10662         converting warnings on inevitable exceptions to errors.
10663         * sem_util.adb: Check SPARK_Mode instead of GNATProve_Mode for
10664         converting warnings on inevitable exceptions to errors.
10665         * types.ads (SPARK_Mode_Id): Moved to opt.ads and renamed
10666         SPARK_Mode_Type
10668 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
10670         * sem_ch13.adb: Add semantic information to rewritten type
10671         reference.
10673 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
10675         * exp_ch5.adb (Expand_N_Assignment_Statement): If both sides
10676         are of a type with unknown discriminants, convert both to the
10677         underlying view of the type, so that the proper constraint check
10678         can be applied to the right-hand side.
10680 2014-01-20  Robert Dewar  <dewar@adacore.com>
10682         * atree.adb (Copy_Node): Fix failure to copy last component
10683         (Exchange_Entities): Fix failure to exchange last entity
10685 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
10687         * sem_ch12.adb: Code clean up.
10689 2014-01-20  Robert Dewar  <dewar@adacore.com>
10691         * gnat_rm.texi, sem_ch4.adb: Minor reformatting.
10693 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
10695         * sem_ch4.adb (Analyze_Quantified_Expression): If after
10696         pre-analysis  the loop parameter specification has been
10697         rewritten as a iterator specification, propagate the change to
10698         the quantified expression, for ASIS navigtion needs.
10700 2014-01-20  Vincent Celier  <celier@adacore.com>
10702         * par-ch10.adb: Minor error message change: escape [ and ].
10704 2014-01-20  Robert Dewar  <dewar@adacore.com>
10706         * checks.adb: Make warnings on exceptions into errors in GNATprove mode.
10707         * errout.adb: Implement [ and ] insertion characters.
10708         * errout.ads: Document new [ and ] insertion characters.
10709         * sem_ch12.adb, restrict.adb, frontend.adb, exp_ch7.adb: Minor
10710         addition of ??? comment.
10711         * lib-xref.adb, exp_util.adb, gnat1drv.adb: Minor reformatting
10712         * exp_ch4.adb, sem_ch3.adb, sem_ch4.adb, sem_ch6.adb, sem_elab.adb,
10713         sem_eval.adb, sem_res.adb, sem_util.adb, sem_attr.adb, sem_aggr.adb:
10714         Make warnings on exceptions into errors in GNATprove mode.
10715         * sem_dim.adb: Minor reformatting throughout Quote [ and ]
10716         in error messages.
10718 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
10720         * sem_ch13.adb: Code clean up.
10722 2014-01-20  Robert Dewar  <dewar@adacore.com>
10724         * errout.ads, errout.adb: Implement >? >x? >X? sequences in error
10725         messages.
10726         * sem_ch6.adb (Check_Statement_Sequence): Missing return is an
10727         error in GNATprove mode.
10729 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
10731         * par-ch4.adb (Is_Parameterless_Attribute): The Ada2012 attribute
10732         reference 'Old takes no parameters, and thus can appear as a
10733         prefix of a slice.
10735 2014-01-20  Eric Botcazou  <ebotcazou@adacore.com>
10737         * exp_aggr.adb: Fix minor typos.
10739 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
10741         * sem_attr.adb (Analyze_Attribute, case 'Constrained): In an
10742         instance the attribute is legal, and its value is determined
10743         statically if the type has no discriminants. This choice is
10744         more useful than rechecking the legality rule in the instance,
10745         is consistent with older usage, and is also consistent with all
10746         existing tests.
10748 2014-01-20  Arnaud Charlet  <charlet@adacore.com>
10750         * sem_cat.adb (Validate_Static_Object_Name): Change error into
10751         warning in Relaxed_Semantic_Mode.
10753 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
10755         * sem_attr.adb: Code and comments cleanup.
10757 2014-01-20  Yannick Moy  <moy@adacore.com>
10759         * debug.adb Free debug flags -gnatd.D, -gnatd.G and -gnatd.V *
10760         * errout.adb (Compilation_Errors): Remove special handling in
10761         GNATprove mode.
10762         * gnat1drv.adb (Adjust_Global_Switches): Remove handling of the
10763         removed debug flags.
10764         * gnat_rm.texi: Initial documentation for Abstract_State, Depends,
10765         Global, Initial_Condition, Initializes and Refined_State pragmas and
10766         aspects.
10767         * opt.ads (Frame_Condition_Mode, Formal_Extensions,
10768         SPARK_Strict_Mode): Remove global flags.
10769         * sem_ch3.adb (Analyze_Object_Declaration): Check of no hidden state
10770         always performed now, on packages declaring a null state.
10771         (Signed_Integer_Type_Declaration): Remove ill-designed attempt
10772         at providing pedantic mode for bounds of integer types.
10773         * sem_ch4.adb (Analyze_Quantified_Expression): Warning on suspicious
10774         "some" quantified expression now issued under control of -gnatw.t,
10775         like the other warning on unused bound variable.
10776         * sem_prag.adb (Check_Precondition_Postcondition): Remove useless test
10777         on removed flag.
10778         (Analyze_Pragma): Remove tests for SPARK 2014
10779         pragmas, not officially allowed by GNAT.
10781 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
10783         * sem_prag.adb (Analyze_Pragma): Ensure that
10784         the sole argument of pragmas Abstract_State, Contract_Cases,
10785         Depends, Global and Initializes in in aggregate form.
10786         (Analyze_Refined_Pragma): Ensure that the sole argument of
10787         pragmas Refined_Depends, Refined_Global and Refined_State is in
10788         aggregate form.
10789         (Ensure_Aggregate_Form): New routine.
10791 2014-01-20  Doug Rupp  <rupp@adacore.com>
10793         * sem_attr.adb (Analyze_Attribute): case
10794         Attribute_Constrained => treat all prefixes as legal for Declib
10795         compatibility.
10797 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
10799         * sem_prag.adb (Check_Mode): Reimplement the routine.
10800         (Find_Mode): New routine.
10802 2014-01-20  Robert Dewar  <dewar@adacore.com>
10804         * sem_ch4.adb (Operator_Check): Handle additional
10805         Allow_Integer_Address cases.
10807 2014-01-20  Robert Dewar  <dewar@adacore.com>
10809         * gnat_rm.texi (Allow_Integer_Address): Remove note about not
10810         allowed if address is non-private, no longer true.
10811         * sem_prag.adb (Analyze_Pragma, case Allow_Integer_Address):
10812         Remove check for address being private, causes difficulty when
10813         pragma used in gnat.adc file and is not needed, since we guard
10814         this in Address_Integer_Convert_OK.
10815         * exp_ch7.adb: Minor reformatting.
10816         * sem_ch4.adb: Handle operator operands in Allow_Integer_Address mode.
10818 2014-01-20  Robert Dewar  <dewar@adacore.com>
10820         * checks.adb (Apply_Range_Check): Remove gnatprove special
10821         casing of exponentiation.
10822         * sem_res.adb (Resolve_Op_Expon): Apply range check to right
10823         operand for integer case to check range against Natural.
10825 2014-01-20  Robert Dewar  <dewar@adacore.com>
10827         * s-tataat.adb: Minor reformatting.
10829 2014-01-20  Robert Dewar  <dewar@adacore.com>
10831         * einfo.adb (Is_Descendent_Of_Address): Now applies to all
10832         entities, and also fix documentation to remove mention of visible
10833         integer type, since this is not what the implementation does.
10834         * einfo.ads (Is_Descendent_Of_Address): Now applies to all
10835         entities, and also fix documentation to remove mention of visible
10836         integer type, since this is not what the implementation does.
10837         * gnat_rm.texi: Minor clarification of Allow_Integer_Address
10838         function.
10839         * sem_ch4.adb (Analyze_One_Call): Handle Allow_Integer_Address
10840         case for parameter type check.
10841         * sem_res.adb (Resolve): Use new function
10842         Address_Integer_Convert_OK.
10843         * sem_type.adb: Minor code reorganization (use Ekind_In) Minor
10844         reformatting throughout.
10845         * sem_util.adb (Address_Integer_Convert_OK): New function.
10846         * sem_util.ads: Minor reformatting (put specs in alpha order)
10847         (Address_Integer_Convert_OK): New function.
10849 2014-01-20  Thomas Quinot  <quinot@adacore.com>
10851         * exp_ch7.adb (Wrap_Transient_Expression):
10852         Insertion extra conditional expression only if
10853         Opt.Suppress_Control_Flow_Optimizations is set.
10855 2014-01-20  Arnaud Charlet  <charlet@adacore.com>
10857         * s-tataat.adb (Initialize_Attributes): Abort might already be
10858         deferred in Create_Task.
10860 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
10862         * checks.adb (Apply_Scalar_Range_Check): Flag
10863         the exponent as requiring a range check when the expression is
10864         an exponentiation.
10866 2014-01-20  Fedor Rybin  <frybin@adacore.com>
10868         * gnat_ugn.texi: Documenting --passed-tests option for gnattest.
10870 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
10872         * sem_util.adb (Default_Initialization): New routine.
10873         * sem_util.ads: Add new type Default_Initialization_Kind.
10874         (Default_Initialization): New routine.
10876 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
10878         * sem_prag.adb (Check_Mode): Correct all error
10879         message logic dealing with in/in out parameters that may appear
10880         as inputs or have a self reference.
10882 2014-01-20  Robert Dewar  <dewar@adacore.com>
10884         * exp_ch9.adb, checks.adb, exp_intr.adb: Minor reformatting.
10885         * sem_res.adb (Resolve): Fix error causing infinite loop for
10886         integer used as address. Allow addresses as integers.
10888 2014-01-20  Arnaud Charlet  <charlet@adacore.com>
10890         * s-osinte-linux.ads (struct_sigaction): Fix rep clause.
10892 2014-01-20  Bob Duff  <duff@adacore.com>
10894         * par-ch8.adb (P_Use_Type_Clause): Detect syntax
10895         error when "use all" is not followed by "type".
10897 2014-01-20  Bob Duff  <duff@adacore.com>
10899         * exp_intr.adb (Expand_Unc_Deallocation): Remove warning on abort
10900         followed by free.
10902 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
10904         * checks.adb (Apply_Address_Clause_Check): If there is an
10905         alignment check on the expression in an address clause, and there
10906         is no local exception propagation, add an additional explanatory
10907         message to clarify the cause of previous warning.
10909 2014-01-20  Robert Dewar  <dewar@adacore.com>
10911         * exp_ch7.adb: Minor reformatting.
10912         * opt.ads: Minor comment updates.
10913         * sem.adb: Minor name change Is_Main_Unit =>
10914         Is_Main_Unit_Or_Main_Unit_Spec.
10915         * sem_ch6.adb: Minor reformatting and code reorganization.
10917 2014-01-20  Bob Duff  <duff@adacore.com>
10919         * gnat_ugn.texi: Update gnatpp switches.
10921 2014-01-20  Thomas Quinot  <quinot@adacore.com>
10923         * exp_ch9.adb: Minor comment edit.
10925 2014-01-20  Robert Dewar  <dewar@adacore.com>
10927         * gnat_rm.texi: Document that Allow_Integer_Address is permitted
10928         only if System.Address is a private type.
10929         * opt.ads (Allow_Integer_Address): No longer set by -gnates.
10930         * sem_prag.adb (Analyze_Pragma, case Allow_Integer_Address):
10931         Allowed only if type System.Address is private, since otherwise
10932         it makes no sense.
10933         * sem_res.adb: Fix failure to properly Analyze unchecked
10934         conversions that were introduced by Allow_Integer_Address.
10935         * switch-c.adb: Remove -gnates switch.
10936         * usage.adb: Remove -gnates switch.
10937         * gnat_ugn.texi: Remove documentation of -gnates flag.
10939 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
10941         * sem_ch6.adb (Analyze_Expression_Function): Pre-analyze and
10942         resolve expression to perform proper name capture.
10944 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
10946         * sem.adb (Semantics): When saving/restoring configuration
10947         switches, the spec of a pre- defined unit that is the main unit
10948         must be treated as a predefined unit as well.
10950 2014-01-20  Thomas Quinot  <quinot@adacore.com>
10952         * exp_ch7.adb (Wrap_Transient_Expression): For a Boolean
10953         expression, insert an extra conditional expression when saving
10954         the value of the expression, for the benefit of control flow
10955         graph based coverage analysis.
10956         * exp_ch3.adb: Minor reformatting.
10958 2014-01-20  Robert Dewar  <dewar@adacore.com>
10960         * gnat1drv.adb: Set Allow_Integer_Address in relaxed semantics mode.
10961         * gnat_rm.texi: Document pragma Allow_Integer_Address.
10962         * gnat_ugn.texi: Document pragma Allow_Integer_Address, -gnates.
10963         * opt.ads: New flag Allow_Integer_Address.
10964         * par-prag.adb: Dummy entry for pragma Allow_Integer_Address.
10965         * sem_ch5.adb: Minor reformatting.
10966         * sem_prag.adb: Implement pragma Allow_Integer_Address.
10967         * sem_res.adb (Resolve): Allow integer address value if
10968         switch set.
10969         * sem_util.adb: Minor reformatting.
10970         * snames.ads-tmpl: Add entry for pragma Allow_Integer_Address.
10971         * switch-c.adb: Recognize flag -gnates.
10972         * usage.adb: Document flag -gnates.
10974 2014-01-20  Thomas Quinot  <quinot@adacore.com>
10976         * s-tadeca.adb: Fix minor typos in comment.
10978 2014-01-20  Pascal Obry  <obry@adacore.com>
10980         * s-win32.ads (FreeLibrary): New import.
10982 2014-01-20  Robert Dewar  <dewar@adacore.com>
10984         * sem_res.adb, sem_cat.adb: Minor reformatting.
10985         * sem_ch11.adb (Analyze_Raise_Statement): Only give warning about
10986         assigning to OUT parameters for the current subprogram scope.
10987         * exp_ch4.adb: Minor reformatting.
10989 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
10991         * exp_ch4.adb (Process_Transient_Object,
10992         Find_Enclosing_Contexts): If the top-level if-expression that
10993         generated the transient object is an actual in a call, the proper
10994         Hook_Context is a construct enclosing the call.
10995         * einfo.ads: Indicate that Related_Expression is used to link a
10996         loop variable to the container expression over which the loop
10997         takes place.
10998         (Analyze_Iterator_Specification): Set the Related_Expression of
10999         the loop variable in a container element iterator.
11000         (Note_Possible_Modification): If the variable is the loop
11001         variable in a container element iterator, indicate that the
11002         enclosing container is also modified.
11004 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
11006         * aspects.adb (Move_Or_Merge_Aspects): Reimplemented.
11008 2014-01-20  Robert Dewar  <dewar@adacore.com>
11010         * s-taasde.ads, gnat_ugn.texi, s-tadeca.adb, sem_res.adb, s-tadeca.ads:
11011         Minor reformatting and code clean up.
11013 2014-01-20  Arnaud Charlet  <charlet@adacore.com>
11015         * sem_cat.adb (Validate_Object_Declaration): Relax semantics
11016         of objects of private type if Relaxed_RM_Semantics.
11018 2014-01-20  Claire Dross  <dross@adacore.com>
11020         * a-cofove.ads (Vector): Capacity discriminant
11021         should be in range of the index.
11023 2014-01-20  Thomas Quinot  <quinot@adacore.com>
11025         * a-caldel.ads(To_Duration), s-taasde.ads(Time_Enqueue):
11026         Clarify specs s-tadeca.adb(Enqueue_Calendar): Compensate for
11027         possible difference between epoch of Ada.Calendar clock and Ada
11028         real-time/tasking clock.
11029         * s-taprop-posix.adb: Minor comment fix.
11031 2014-01-20  Doug Rupp  <rupp@adacore.com>
11033         * sysdep.c [vxworks]: Remove Vxworks version noise for RTP.
11035 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
11037         * exp_attr.adb (Expand_N_Attribute_Reference): Generate validity
11038         checks on the prefix of attribute 'Old.
11039         * sem_ch3.adb (Process_Range_Expr_In_Decl): Suppress the
11040         generation of validity checks on a range that belongs to the
11041         iteration scheme of a quantified expression.
11042         * sem_ch5.adb (One_Bound): Suppress the generation of validity
11043         checks on a bound that belongs to the iteration scheme of a
11044         quantified expression, generate the check in all other cases.
11046 2014-01-20  Bob Duff  <duff@adacore.com>
11048         * gnat_ugn.texi: Enable --pp-new by default. Minor reorganization.
11050 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
11052         * sem_res.adb (Resolve): When compiling a predefined unit, ignore
11053         interpretations that do not come from other predefined units,
11054         to prevent spurious ambiguities in the presence of user-defined
11055         operators in the context of (an instance of) a predefined unit.
11057 2014-01-20  Robert Dewar  <dewar@adacore.com>
11059         * gnat_rm.texi: Document that Loop_Variant is included in
11060         Statement_Assertions.
11061         * sem_prag.adb (Check_Kind): Add Loop_Variant to
11062         Statement_Assertions (Check_Applicable_Policy): Add Loop_Variant
11063         to Statement_Assertions.
11065 2014-01-20  Doug Rupp  <rupp@adacore.com>
11067         * sysdep.c (__gnat_is_file_not_found_error) [vxworks6]: Add case
11068         for errno ENOENT from RTP on NFS mounted file system.
11070 2014-01-20  Ed Schonberg  <schonberg@adacore.com>
11072         * sem_util.adb (Check_Function_Writable_Actuals): 1) Do not
11073         examine code that does not come from source. The check does not
11074         apply to code generated for constraint checks, and such code may
11075         generate spurious error messages when compiled with expansion
11076         disabled (as in a generic unit) because side effects may not
11077         have been removed.
11078         2) Make error messages more explicit: indicate the component
11079         of the  construct whose value is indeterminate because of a
11080         call to a function with in-out parameter in another component,
11081         when there is no mandated order of execution between the two
11082         components (actuals, aggregate components, alternatives).
11084 2014-01-20  Robert Dewar  <dewar@adacore.com>
11086         * gnat_rm.texi: Minor cleanup.
11088 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
11090         * sem_attr.adb (Analyze_Attribute): Attributes 'Old and 'Result
11091         can now apply to a refined postcondition.
11092         * sem_ch6.adb (Analyze_Subprogram_Contract): Remove local
11093         variable Result_Seen. Add variables Case_Prag, Post_Prag,
11094         Seen_In_Case and Seen_In_Post. Update the mechanism that detects
11095         whether postconditions and/or constract-cases mention attribute
11096         'Result and introduce a post-state when applied to functions.
11097         (Check_Result_And_Post_State): Removed.
11098         * sem_prag.adb (Analyze_Pragma): Add local variable
11099         Result_Seen. Verify that the expression of pragma Refined_Post
11100         mentions attribute 'Result and introduces a post-state.
11101         * sem_util.ads, sem_util.adb (Check_Result_And_Post_State): New routine.
11103 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
11105         * exp_ch7.adb (Is_Subprogram_Call): New routine.
11106         (Process_Transient_Objects): Make variable Must_Hook global with
11107         respect to all locally declared subprograms. Search the context
11108         for at least one subprogram call.
11109         (Requires_Hooking): Removed.
11111 2014-01-20  Claire Dross  <dross@adacore.com>
11113         * a-cfdlli.ads a-cfhama.ads a-cfhase.ads a-cforma.ads
11114         * a-cforse.ads a-cofove.ads: Add pragma Annotate (GNATprove,
11115         External_Axiomatization);
11117 2014-01-20  Robert Dewar  <dewar@adacore.com>
11119         * sem_attr.adb (Analyze_Attribute, case Loop_Entry): Allow
11120         Loop_Entry in Assert, Assert_And_Cut, and Assume pragmas.
11121         * sem_prag.adb (Analyze_Pragma, case Assert[_And_Cut], Assume):
11122         Allow Loop_Entry to be used in these pragmas if they appear in
11123         an appropriate context.
11124         (Placement_Error): Specialize error
11125         message for pragma Assert[_And_Cut] or pragma Assume containing
11126         Loop_Entry attribute.
11127         * a-exexpr-gcc.adb, sinput.adb: Minor reformatting.
11128         * s-excmac-arm.ads, s-except.ads, s-excmac-gcc.ads: Minor reformatting
11129         and code clean ups.
11131 2014-01-20  Robert Dewar  <dewar@adacore.com>
11133         * gnat1drv.adb: Minor comment update.
11135 2014-01-20  Tristan Gingold  <gingold@adacore.com>
11137         * raise-gcc.c (PERSONALITY_FUNCTION/arm): Remove unused
11138         variables, comment out unused code.
11139         * a-exexpr-gcc.adb: Move declarations to s-excmac-gcc.ads
11140         * s-excmac-gcc.ads: New file, extracted from a-exexpr-gcc.adb
11141         * s-excmac-arm.ads: New file.
11143 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
11145         * exp_ch4.adb (Expand_N_Slice): Remove constant D and variables
11146         Drange and Index_Typ. Remove the circuitry which creates a
11147         range check to compare the index type of the array against the
11148         discrete_range.
11149         * sem_res.adb (Resolve_Slice): Add local variable Dexpr. Update
11150         the circuitry which creates a range check to handle a
11151         discrete_range denoted by a subtype indication.
11153 2014-01-20  Pierre-Marie Derodat  <derodat@adacore.com>
11155         * sinput.adb, sinput.ads (Sloc_Range): Traverse the tree of original
11156         nodes to get the original sloc range.
11158 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
11160         * sem_prag.adb (Analyze_Pragma): Use Defining_Entity to obtain the
11161         entity of a [library level] package.
11163 2014-01-20  Tristan Gingold  <gingold@adacore.com>
11165         * raise-gcc.c (exception_class_eq): New function.
11166         (is_handled_by): Use it to compare exception classes.
11167         (PERSONALITY_STORAGE): Define.  (continue_unwind): New function to
11168         be called to return URC_CONTINUE_UNWIND.
11169         (personality_body): New function, extracted from PERSONALITY_ROUTINE.
11170         (PERSONALITY_ROUTINE): Add an implementation for the ARM unwinder.
11172 2014-01-20  Robert Dewar  <dewar@adacore.com>
11174         * opt.ads: Minor comment update.
11176 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
11178         * exp_ch4.adb (Expand_N_Slice): Relocate some variables and
11179         constants to the "Local variables" area. Add new constant D. Add
11180         new variables Drange and Index_Typ.  Rename Pfx to Rep and Ptp
11181         to Pref_Typ and update all occurrences. Add circuitry to extract
11182         the discrete_range and the index type and build a range check.
11184 2014-01-20  Arnaud Charlet  <charlet@adacore.com>
11186         * gnat1drv.adb (Adjust_Global_Switches): Enable
11187         Treat_Categorization_Errors_As_Warnings when Relaxed_RM_Semantics
11188         is set.
11190 2014-01-20  Thomas Quinot  <quinot@adacore.com>
11192         * sem_ch5.adb, sem_ch4.adb: Minor reformatting.
11194 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
11196         * sem_ch13.adb (Analyze_Aspect_Specifications):
11197         When aspect SPARK_Mode appears on a package body, insert the
11198         generated pragma at the top of the body declarations.
11200 2014-01-20  Robert Dewar  <dewar@adacore.com>
11202         * sem_aggr.adb, exp_prag.adb, sem_aux.adb, sinfo.ads, sem_ch10.adb,
11203         checks.adb, sem_prag.adb, sem_ch12.adb, freeze.adb, g-arrspl.adb,
11204         expander.adb, gnat1drv.adb, exp_ch4.adb, sem_ch6.adb,
11205         sem_ch8.adb, exp_dist.adb: Minor reformatting.
11207 2014-01-20  Yannick Moy  <moy@adacore.com>
11209         * gnat1drv.adb (Gnat1drv): Call Write_ALI with Object=True in GNATprove
11210         mode.
11212 2014-01-20  Pascal Obry  <obry@adacore.com>
11214         * g-arrspl.ads (Slice_Set): New definition (will use a copy on
11215         write scheme).
11216         * g-arrspl.adb: Adapt all routine to this new implementation.
11217         (Set): Copy the Slice_Set definition before reusing it.
11219 2014-01-20  Arnaud Charlet  <charlet@adacore.com>
11221         * sem_prag.adb (Process_Import_Or_Interface): In
11222         Relaxed_RM_Semantics, support old Ada 83 style of pragma Import.
11223         (Analyze_Pragma): Ditto for pragma Export.
11224         * exp_prag.adb (Expand_Pragma_Import_Or_Interface): Handle old pragma
11225         Import style.
11227 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
11229         * einfo.ads: E_Abstract_State is now part of the entities that
11230         can be overloaded. Update type Overloadable_Kind to reflect the
11231         inclusion of abstract states.
11232         * sem_ch6.adb (New_Overloaded_Entity): A function can now
11233         overload an abstract state.
11234         * sem_prag.adb (Analyze_Constituent): Handle the overloading
11235         of states by functions. Use Entity_Of to obtain the entity of
11236         a constituent.  (Analyze_Global_Item): Handle the overloading of
11237         states by functions.
11238         (Analyze_Initialization_Item): Handle the
11239         overloading of states by functions.  Use Entity_Of to obtain the
11240         entity of an item.
11241         (Analyze_Input_Item): Handle the overloading
11242         of states by functions. Use Entity_Of to obtain the entity of an item.
11243         (Analyze_Input_Output): Handle the overloading of states by functions.
11244         (Analyze_Refinement_Clause): Handle the overloading
11245         of states by functions.  Use Entity_Of to obtain the entity of an item.
11246         (Appears_In): Use Entity_Of to obtain the entity of an element.
11247         (Check_Usage): Use Entity_Of to obtain the entity of
11248         an item. Add a guard to prevent a crash due to a previous error.
11249         (Resolve_State): New routine.
11251 2014-01-20  Yannick Moy  <moy@adacore.com>
11253         * spark_xrefs.ads, debug.adb, gnat1drv.adb, errout.adb, errout.ads,
11254         opt.ads: Minor comments updates.
11256 2014-01-20  Hristian Kirtchev  <kirtchev@adacore.com>
11258         * einfo.adb (Non_Limited_View): Applies to abstract states.
11259         (Set_From_Limited_With): Applies to abstract states.
11260         (Set_Non_Limited_View): Applies to abstract states.
11261         (Write_Field17): Output the non-limited view of an abstract state.
11262         * einfo.ads: Update the comment on usage and occurrences in
11263         nodes for attributes From_Limited_With and Non_Limited_View.
11264         * sem_aux.adb (Available_View): This routine can now handle
11265         abstract states.
11266         * sem_aux.ads (Available_View): This routine can now handle
11267         abstract states. Update the comment on usage.
11268         * sem_ch8.adb (Find_Expanded_Name): Handle abstract views
11269         of states and variables.
11270         (In_Pragmas_Depends_Or_Global): New routine.
11271         * sem_ch10.adb (Build_Limited_Views): Implement
11272         abstract (limited) views of variables and states.
11273         (Build_Shadow_Entity): This routine is now a procedure. Add
11274         formal parameter Shadow. Update the comment on usage. Add
11275         context-specific decoration for states and variables.
11276         (Decorate_State): New routine.  (Decorate_Variable): New routine.
11277         (Find_And_Process_States): New routine.
11278         (Process_Declarations): Renamed to Process_Declarations_And_States.
11279         (Process_Declarations_And_States): Add formal parameters
11280         Pack and Create_Abstract_Views. Update the comment on usage.
11281         (Process_States): New routine.
11282         * sem_prag.adb (Check_Dependency_Clause): Handle abstract
11283         views of states and variables. Match the abstract view of a state
11284         against its corresponding non-abstract view.
11285         (Is_Matching_Input):
11286         Handle abstract views of states and variables. Match the abstract
11287         view of a state against its corresponding non-abstract view.
11288         (Process_Global_Item): Handle abstract views of states and
11289         variables.
11291 2014-01-20  Bob Duff  <duff@adacore.com>
11293         * sem_ch10.adb (Expand_With_Clause): Don't
11294         recurse on the prefix if the current with-ed name refers to a
11295         package that renames its own parent, eg "package P.Q renames P;".
11297 2014-01-20  Yannick Moy  <moy@adacore.com>
11299         * exp_spark.adb (Expand_SPARK_Call): Remove procedure.
11300         * opt.adb, opt.ads (Full_Expander_Active): Remove function.
11301         * checks.adb, exp_ch6.adb, exp_ch9.adb, exp_disp.adb, sem_aggr.adb,
11302         * sem_ch10.adb, sem_ch5.adb, sem_ch6.adb, sem_ch8.adb, sem_ch9.adb,
11303         * sem_disp.adb, sem_res.adb Replace Full_Expander_Active by
11304         Expander_Active.
11306 2014-01-20  Yannick Moy  <moy@adacore.com>
11308         * sinfo.ads Update documentation of GNATprove mode.
11310 2014-01-20  Yannick Moy  <moy@adacore.com>
11312         * adabkend.adb, ali-util.adb, errout.adb, exp_ch7.adb,
11313         * exp_dbug.adb, freeze.adb, lib-xref.adb, restrict.adb,
11314         * sem_attr.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb, sem_ch8.adb,
11315         * sem_prag.adb, sem_res.adb, sem_util.adb Rename SPARK_Mode into
11316         GNATprove_Mode.
11317         * sem_ch13.adb: Remove blank.
11318         * exp_spark.adb, exp_spark.ads (Expand_SPARK_Call): Only replace
11319         subprograms by alias for renamings, not for inherited primitive
11320         operations.
11321         * exp_util.adb (Expand_Subtype_From_Expr): Apply the expansion
11322         in GNATprove mode.
11323         (Remove_Side_Effects): Apply the removal in
11324         GNATprove mode, for the full analysis of expressions.
11325         * expander.adb (Expand): Call the light SPARK expansion in GNATprove
11326         mode.
11327         (Expander_Mode_Restore, Expander_Mode_Save_And_Set): Ignore
11328         save/restore actions for Expander_Active flag in GNATprove mode,
11329         similar to what is done in ASIS mode.
11330         * frontend.adb (Frontend): Generic bodies are instantiated in
11331         GNATprove mode.
11332         * gnat1drv.adb (Adjust_Global_Switches): Set operating
11333         mode to Check_Semantics in GNATprove mode, although a light
11334         expansion is still performed.
11335         (Gnat1drv): Set Back_End_Mode to
11336         Declarations_Only in GNATprove mode, and later on special case
11337         the GNATprove mode to continue analysis anyway.
11338         * lib-writ.adb (Write_ALI): Always generate ALI files in
11339         GNATprove mode.
11340         * opt.adb, opt.ads (Full_Expander_Active): Make it equivalent to
11341         Expander_Active.
11342         (SPARK_Mode): Renamed as GNATprove_Mode.
11343         * sem_aggr.adb (Aggregate_Constraint_Checks): Add checks in the
11344         tree in GNATprove_Mode.
11345         * sem_ch12.adb (Analyze_Package_Instantiation): Always instantiate
11346         body in GNATprove mode.
11347         (Need_Subprogram_Instance_Body): Always instantiate body in GNATprove
11348         mode.
11349         * sem_ch3.adb (Constrain_Index, Process_Range_Expr_In_Decl):
11350         Make sure side effects are removed in GNATprove mode.
11352 2014-01-20  Eric Botcazou  <ebotcazou@adacore.com>
11354         * gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Robustify tests
11355         for aliased objects with an unconstrained nominal subtype.
11356         * gcc-interface/trans.c (Call_to_gnu): Likewise.
11357         (gnat_to_gnu) <case N_Op_Not>: Robustify test for private type.
11358         <case N_Op_Minus>: Remove useless code.
11359         (Exception_Handler_to_gnu_zcx): Minor tweaks.
11361 2014-01-20  Eric Botcazou  <ebotcazou@adacore.com>
11363         * gcc-interface/decl.c (gnat_to_gnu_entity) <case E_Record_Subtype>:
11364         Tidy up.  For a subtype with discriminants and variant part, if a
11365         variant is statically selected and the fields all have a constant
11366         position, put them in order of increasing position.  Likewise if
11367         no variant part but representation clause is present.
11368         * gcc-interface/utils.c (make_packable_type): Robustify.
11369         (maybe_pad_type): Use local variable and tidy up condition.  If no
11370         alignment is specified, use the original one.
11371         (create_type_stub_decl): Minor tweak.
11372         (convert) <case VECTOR_CST>: Fix typo.
11373         <case CONSTRUCTOR>: Deal with padding types around the same type.
11374         Do not punt on missing fields.
11375         (unchecked_convert): Call finish_record_type to lay out the special
11376         record types made for conversions from/to problematic integer types.
11377         Bump the alignment of CONSTRUCTORs before converting them to a more
11378         aligned type.
11380 2014-01-20  Eric Botcazou  <ebotcazou@adacore.com>
11382         * gcc-interface/decl.c (gnat_to_gnu_entity) <case E_Component>: Remove
11383         obsolete code for type_annotate_only mode, simplify code and slightly
11384         improve wording of comments.
11386 2014-01-12  Eric Botcazou  <ebotcazou@adacore.com>
11388         PR ada/59772
11389         * gcc-interface/cuintp.c (build_cst_from_int): Use 32-bit integer type
11390         as intermediate type.
11391         (UI_To_gnu): Likewise.
11393 2014-01-03  Eric Botcazou  <ebotcazou@adacore.com>
11395         * gnatvsn.ads (Current_Year): Bump to 2014.
11397 2014-01-02  Tobias Burnus  <burnus@net-b.de>
11399         * gnat_ugn.texi: Bump @copying's copyright year.
11401 Copyright (C) 2014 Free Software Foundation, Inc.
11403 Copying and distribution of this file, with or without modification,
11404 are permitted in any medium without royalty provided the copyright
11405 notice and this notice are preserved.