1 2017-01-06 Patrick Bernardi <bernardi@adacore.com>
3 * aspects.adb, aspects.ads, exp_ch3.adb, exp_ch9.adb, par-prag.adb,
4 sem_ch13.adb, sem_prag.adb, sem_prag.ads, snames.adb-tmpl,
5 snames.ads-tmpl, s-secsta.adb, s-secsta.ads, s-tarest.adb,
6 s-tarest.ads, s-taskin.adb, s-taskin.ads, s-tassta.adb, s-tassta.ads:
7 Reverted previous change for now.
9 2017-01-06 Ed Schonberg <schonberg@adacore.com>
11 * exp_ch3.adb (Build_Initialization_Call): Apply predicate
12 check to default discriminant value if checks are enabled.
13 (Build_Assignment): If type of component has static predicate,
14 apply check to its default value, if any.
16 2017-01-06 Patrick Bernardi <bernardi@adacore.com>
18 * aspect.adb, aspect.ads: Added new aspect Secondary_Stack_Size.
19 * exp_ch3.adb (Build_Init_Statements): As part of initialising
20 the value record of a task, set its _Secondary_Stack_Size field
22 * exp_ch9.adb (Expand_N_Task_Type_Declaration): Create
23 a _Secondary_Stack_Size field in the value record of
24 the task if a Secondary_Stack_Size rep item is present.
25 (Make_Task_Create_Call): Include secondary stack size
26 parameter. If No_Secondary_Stack restriction is in place, passes
28 * par-prag.adb, sem_prag.adb, sem_prag.ads: Added new pragma
30 * s-secsta.adb, s-secsta.ads (Minimum_Secondary_Stack_Size): New
31 function to define the overhead of the secondary stack.
32 * s-tarest.adb (Create_Restricted_Task,
33 Create_Restricted_Task_Sequential): Functions now include
34 Secondary_Stack_Size parameter to pass to Initialize_ATCB.
35 * s-tarest.adb (Create_Restricted_Task,
36 Create_Restricted_Task_Sequential): Calls to Initialize_ATCB
37 now include Secondary_Stack_Size parameter.
39 Secondary stack now allocated to the size specified by the
40 Secondary_Stack_Size parameter in the task's ATCB.
41 * s-taskin.adb, s-taskin.adb (Common_ATCB, Initialise_ATCB): New
42 Secondary_Stack_Size component.
43 * s-tassta.adb, s-tassta.ads (Create_Restricted_Task,
44 Create_Restricted_Task_Sequential): Function now include
45 Secondary_Stack_Size parameter.
46 (Task_Wrapper): Secondary stack
47 now allocated to the size specified by the Secondary_Stack_Size
48 parameter in the task's ATCB.
49 * sem_ch13.adb (Analyze_Aspect_Specification): Add support
50 for Secondary_Stack_Size aspect, turning the aspect into its
51 corresponding internal attribute.
52 (Analyze_Attribute_Definition):
53 Process Secondary_Stack_Size attribute.
54 * snames.adb-tmpl, snames.ads-tmpl: Added names
55 Name_Secondary_Stack_Size, Name_uSecondary_Stack_Size,
56 Attribute_Secondary_Stack_Size and Pragma_Secondary_Stack_Size.
58 2017-01-06 Pascal Obry <obry@adacore.com>
60 * a-direio.adb, a-direio.ads, a-sequio.adb, a-sequio.ads: Add Flush to
61 Sequential_IO and Direct_IO.
63 2017-01-06 Bob Duff <duff@adacore.com>
65 * snames.ads-tmpl (Renamed): New name for the pragma argument.
66 * par-ch2.adb: Allow the new pragma (with analysis deferred
68 * sinfo.ads, sinfo.adb (Map_Pragma_Name, Pragma_Name_Mapped):
69 Keep a mapping from new pragma names to old names.
70 * sem_prag.adb: Check legality of pragma Rename_Pragma, and
71 implement it by calling Map_Pragma_Name.
72 * checks.adb, contracts.adb, einfo.adb, errout.adb,
73 * exp_attr.adb, exp_ch3.adb, exp_ch6.adb, exp_ch7.adb, exp_ch9.adb,
74 * exp_prag.adb, exp_util.adb, freeze.adb, frontend.adb, ghost.adb,
75 * inline.adb, lib-writ.adb, scans.adb, scans.ads, sem_attr.adb,
76 * sem_aux.adb, sem_ch10.adb, sem_ch13.adb, sem_ch6.adb, sem_ch9.adb,
77 * sem_elab.adb, sem_res.adb, sem_util.adb, sem_util.ads,
78 * sem_warn.adb: Call Pragma_Name_Mapped instead of Pragma_Name
81 2017-01-06 Hristian Kirtchev <kirtchev@adacore.com>
83 * exp_ch9.adb: Minor reformatting.
85 2017-01-06 Tristan Gingold <gingold@adacore.com>
87 * exp_ch9.ads, exp_ch9.adb (Build_Entry_Names): Remove (unused).
88 * rtsfind.ads (RE_Task_Entry_Names_Array, RO_ST_Set_Entry_Names)
89 (RE_Protected_Entry_Names_Array, RO_PE_Set_Entry_Names): Remove
91 * s-taskin.ads, s-taskin.adb (Set_Entry_Names,
92 Task_Entry_Names_Array, Task_Entry_Names_Access): Remove.
93 * s-tpoben.ads, s-tpoben.adb (Set_Entry_Names,
94 Protected_Entry_Names_Array, Protected_Entry_Names_Access): Remove.
96 2017-01-06 Bob Duff <duff@adacore.com>
98 * sinfo.ads, sinfo.adb (Map_Pragma_Name): Preparation work,
99 dummy implementation of Map_Pragma_Name.
101 2017-01-06 Tristan Gingold <gingold@adacore.com>
103 * exp_ch9.adb (Expand_N_Protected_Type_Declaration): Make the
104 entry_body variable constant.
105 * s-taprob.ads (Entry_Body_Access): Move to s-tposen.
106 * s-tpoben.ads (Protected_Entry_Body_Access): Now access
108 * s-tposen.ads (Entry_Body_Access): Moved from s-taprob,
109 now access to constant.
111 2017-01-06 Gary Dismukes <dismukes@adacore.com>
113 * einfo.ads, sem_res.adb, sem_attr.adb, sem_ch6.adb: Minor
114 reformatting and typo fixes.
116 2017-01-06 Bob Duff <duff@adacore.com>
118 * snames.ads-tmpl: New names for pragma renaming.
119 * snames.adb-tmpl (Is_Configuration_Pragma_Name): Minor cleanup.
120 * par-prag.adb: Add new pragma name to case statement.
121 * sem_prag.adb (Rename_Pragma): Initial cut at semantic analysis
123 * sinfo.ads, sinfo.adb (Pragma_Name_Mapped): Preparation work,
124 Dummy implementation of Pragma_Name_Mapped.
126 2017-01-06 Ed Schonberg <schonberg@adacore.com>
128 * exp_ch6.adb (Expand_Protected_Subprogram_Call): Add guard to
129 better detect call within an entry_wrapper.
130 * sem_res.adb (Resolve_Call): A protected call within an
131 entity_wrapper is analyzed in the context of the protected
132 object but corresponds to a pre-analysis and is not an access
134 * sem_attr.adb: Minor reformatting.
136 2017-01-06 Justin Squirek <squirek@adacore.com>
138 * sem_attr.adb (Analyze_Attribute): Modify semantic checks for
139 Finalization_Size to allow a prefix of any non-class-wide type.
140 * sem_attr.ads Modify comment for Finalization_Size to include
141 definite type use case.
143 2017-01-06 Ed Schonberg <schonberg@adacore.com>
145 * einfo.ads, einfo.adb (Is_Entry_Wrapper): New flag, defined
146 on procedures that are wrappers created for entries that have
148 * sem_ch6.adb (Analyze_Subrogram_Body_Helper): If the subprogram
149 body is an entry_wrapper, compile it in the context of the
150 synchronized type, because a precondition may refer to funtions
152 * exp_ch9.adb (Build_Contract_Wrapper): Set Is_Entry_Wrapper on
154 * exp_ch6.adb (Expand_Protected_Subprogram_Call): if the call is
155 within an Entry_Wrapper this is an external call whose target
156 is the synchronized object that is the actual in the call to
159 2017-01-06 Yannick Moy <moy@adacore.com>
161 * sem_attr.adb (Analyze_Attribute/Attribute_Loop_Entry): Analyze node
162 in tree, which means not analyzing the previous prefix if the node has
163 been rewritten into its prefix.
165 2017-01-06 Gary Dismukes <dismukes@adacore.com>
167 * s-tpobop.adb: Minor reformatting.
169 2017-01-06 Ed Schonberg <schonberg@adacore.com>
171 * checks.adb (Ensure_Valid): Do not generate a validity check
172 within a generated predicate function, validity checks will have
173 been applied earlier when required.
175 2017-01-06 Tristan Gingold <gingold@adacore.com>
177 * s-tpoben.ads (Protection_Entries): Add comment and reorder
178 components for performances.
179 * s-tpobop.adb (PO_Do_Or_Queue): Implement Max_Queue_Length runtime
182 2017-01-06 Ed Schonberg <schonberg@adacore.com>
184 * sem_eval.adb (Check_Expression_Against_Static_Predicate):
185 If expression is compile-time known and obeys a static predicate
186 it must be labelled as static, to prevent spurious warnings and
187 run-time errors, e.g. in case statements. This is relevant when
188 the expression is the result of constant-folding a type conversion
189 whose expression is a variable with a known static value.
191 2017-01-06 Hristian Kirtchev <kirtchev@adacore.com>
193 * exp_attr.adb, sem_attr.ads: Minor reformatting.
195 2017-01-06 Justin Squirek <squirek@adacore.com>
197 * exp_attr.adb (Expand_N_Attribute_Reference): Add entry for
198 expansion of Finalization_Size attribute.
199 * sem_attr.adb (Analyze_Attribute): Add entry to check the
200 semantics of Finalization_Size.
201 (Eval_Attribute): Add null entry for Finalization_Size.
202 * sem_attr.ads: Add Finalization_Size to the implementation
203 dependent attribute list.
204 * snames.ads-tmpl: Add name entry for Finalization_Size attribute.
206 2017-01-06 Ed Schonberg <schonberg@adacore.com>
208 * sem_ch5.adb (Analyze_Loop_Statement): If the loop includes an
209 iterator specification with a serious syntactic error, transform
210 construct into an infinite loop in order to continue analysis
211 and prevent a compiler abort.
213 2017-01-06 Tristan Gingold <gingold@adacore.com>
215 * exp_ch9.adb (Expand_N_Protected_Type_Declaration): Do not generate
216 max_queue_lengths_array if unused.
218 2017-01-06 Bob Duff <duff@adacore.com>
220 * errout.adb (Set_Msg_Text): Protect against out-of-bounds
221 array access, in case "\" is at the end of Text.
222 * stylesw.adb (Set_Style_Check_Options): Don't include input
223 characters in the error message template, because they could
224 be control characters such as "\", which Errout will try to
227 2017-01-06 Ed Schonberg <schonberg@adacore.com>
229 * sem_ch4.adb (Find_Indexing_Operations, Inspect_Declarations):
230 For a private type examine the visible declarations that follow
231 the partial view, not just the private declarations that follow
234 2017-01-06 Hristian Kirtchev <kirtchev@adacore.com>
236 * exp_ch5.adb, sem_ch3.adb, checks.adb: Minor reformatting and
239 2017-01-06 Ed Schonberg <schonberg@adacore.com>
241 * exp_ch5.adb (Get_Default_Iterator): For a derived type, the
242 alias of the inherited op is the parent iterator, no need to
243 examine dispatch table positions which might not be established
244 yet if type is not frozen.
245 * sem_disp.adb (Check_Controlling_Formals): The formal of a
246 predicate function may be a subtype of a tagged type.
247 * sem_ch3.adb (Complete_Private_Subtype): Adjust inheritance
248 of representation items for the completion of a type extension
249 where a predicate applies to the partial view.
250 * checks.ads, checks.adb (Apply_Predicate_Check): Add optional
251 parameter that designates function whose actual receives a
252 predicate check, to improve warning message when the check will
253 lead to infinite recursion.
254 * sem_res.adb (Resolve_Actuals): Pass additional parameter to
255 Apply_Predicate_Check.
257 2017-01-06 Tristan Gingold <gingold@adacore.com>
259 * s-rident.ads (Profile_Info): Remove No_Entry_Queue from
260 Gnat_Extended_Ravenscar.
261 * exp_ch9.adb, s-tpoben.adb, s-tpoben.ads: Fix spelling.
263 2017-01-06 Gary Dismukes <dismukes@adacore.com>
265 * sem_util.ads: Minor typo fix and reformatting.
267 2017-01-06 Yannick Moy <moy@adacore.com>
269 * ghost.adb Minor fixing of references to SPARK RM.
270 (Check_Ghost_Context): Check whether reference is to a lvalue
271 before issuing an error about violation of SPARK RM 6.9(13)
272 when declaration has Ghost policy Check and reference has Ghost
274 * sem_util.adb Minor indentation.
275 * sem_ch10.adb (Analyze_Package_Body_Stub, Analyze_Protected_Body_Stub,
276 Analyze_Task_Body_Stub): Set Ekind of the defining identifier.
277 * sem_util.ads (Unique_Defining_Entity): Document the result
278 for package body stubs.
280 2017-01-06 Tristan Gingold <gingold@adacore.com>
282 * raise-gcc.c (abort): Macro to call Abort_Propagation.
283 * s-tpoben.ads (Protected_Entry_Queue_Max_Access): Make it access
285 * exp_ch9.adb (Expand_N_Protected_Type_Declaration):
286 Do not generate the Entry_Max_Queue_Lengths_Array if all default
288 * exp_util.adb (Corresponding_Runtime_Package): Consider
289 Max_Queue_Length pragma.
291 2017-01-06 Justin Squirek <squirek@adacore.com>
293 * exp_ch9.adb (Expand_N_Protected_Type_Declaration):
294 Remove declaration generation in the case of
295 System_Tasking_Protected_Objects_Single_Entry being used,
296 and add a warning message when this is detected to occur.
297 (Make_Initialize_Protection): Remove reference pass in the case
298 of System_Tasking_Protected_Objects_Single_Entry.
299 * rtsfind.ads: Remove RE_Protected_Entry_Queue_Max
300 * s-tposen.adb (Initialize_Protection_Entry): Remove
301 Entry_Queue_Max parameter.
302 * s-tposen.ads: Remove the types use to store the entry queue
304 * sem_prag.adb (Analyze_Pragma): Remove entry families restriction
306 2017-01-06 Yannick Moy <moy@adacore.com>
308 * sem_util.adb, sem_util.ads (Get_Enum_Lit_From_Pos): Strengthen
309 behavior of function, to also accept out of range positions
310 and raise Constraint_Error in such case, and to copy sloc from
311 literal if No_Location passed as location.
312 * uintp.adb, uintp.ads (UI_To_Int, UI_To_CC): Strengthen behavior
313 of functions to raise Constraint_Error in case of value not in
316 2017-01-06 Tristan Gingold <gingold@adacore.com>
318 * sem_util.adb, s-taprop-linux.adb (Finalize_TCB): Remove call to
319 Invalidate_Stack_Cache.
321 2017-01-06 Eric Botcazou <ebotcazou@adacore.com>
323 * s-os_lib.adb: Minor fix to the signature of Readlink.
325 2017-01-06 Javier Miranda <miranda@adacore.com>
327 * sem_ch6.adb (Conforming_Types): Handle another
328 confusion between views in a nested instance with an actual
329 private type whose full view is not in scope.
331 2017-01-06 Arnaud Charlet <charlet@adacore.com>
333 * exp_ch5.adb (Expand_N_If_Statement): Obey existing comment and
334 mark a rewritten if statement as explicit (Comes_From_Source).
336 2017-01-06 Gary Dismukes <dismukes@adacore.com>
338 * sem_prag.adb, rtsfind.adb, sem_util.adb: Minor typo fixes.
340 2017-01-06 Tristan Gingold <gingold@adacore.com>
342 * ada.ads, a-unccon.ads: Add pragma No_Elaboration_Code_All.
344 2017-01-06 Hristian Kirtchev <kirtchev@adacore.com>
346 * sem_case.adb: Minor reformatting.
348 2017-01-06 Thomas Quinot <quinot@adacore.com>
350 * g-socthi-mingw.adb: Remove now extraneous USE TYPE clause
352 2017-01-06 Justin Squirek <squirek@adacore.com>
354 * aspects.adb: Register aspect in Canonical_Aspect.
355 * aspects.ads: Associate qualities of Aspect_Max_Queue_Length
356 into respective tables.
357 * einfo.ads, einfo.adb: Add a new attribute for
358 handling the parameters for Pragma_Max_Entry_Queue
359 (Entry_Max_Queue_Lengths_Array) in E_Protected_Type. Subprograms
360 for accessing and setting were added as well.
361 * par-prag.adb (Prag): Register Pramga_Max_Entry_Queue.
362 * exp_ch9.adb (Expand_N_Protected_Type_Declaration): Emit
363 declaration for pramga arguments and store them in the protected
365 (Make_Initialize_Protection): Pass a reference to
366 the Entry_Max_Queue_Lengths_Array in the protected type node to
368 * rtsfind.adb: Minor grammar fix.
369 * rtsfind.ads: Register new types taken from the
370 runtime libraries RE_Protected_Entry_Queue_Max and
371 RE_Protected_Entry_Queue_Max_Array
372 * s-tposen.adb, s-tpoben.adb
373 (Initialize_Protection_Entry/Initialize_Protection_Entries):
374 Add extra parameter and add assignment to local object.
375 * s-tposen.ads, s-tpoben.ads: Add new types to
376 store entry queue maximums and a field to the entry object record.
377 * sem_ch13.adb (Analyze_Aspect_Specifications): Add case statement
378 for Aspect_Max_Queue_Length.
379 (Check_Aspect_At_Freeze_Point):
380 Add aspect to list of aspects that don't require delayed analysis.
381 * sem_prag.adb (Analyze_Pragma): Add case statement for
382 Pragma_Max_Queue_Length, check semantics, and register arugments
383 in the respective entry nodes.
384 * sem_util.adb, sem_util.ads Add functions Get_Max_Queue_Length
385 and Has_Max_Queue_Length
386 * snames.ads-tmpl: Add constant for the new aspect-name
387 Name_Max_Queue_Length and corrasponding pragma.
389 2017-01-06 Hristian Kirtchev <kirtchev@adacore.com>
391 * exp_util.adb (Is_Controlled_Function_Call):
392 Reimplemented. Consider any node which has an entity as the
393 function call may appear in various ways.
395 2017-01-06 Hristian Kirtchev <kirtchev@adacore.com>
397 * exp_attr.adb (Rewrite_Stream_Proc_Call): Use
398 an unchecked type conversion when performing a view conversion
399 to/from a private type. In all other cases use a regular type
400 conversion to ensure that any relevant checks are properly
403 2017-01-06 Hristian Kirtchev <kirtchev@adacore.com>
405 * sem_prag.adb, sem_ch8.adb: Minor reformatting.
407 2017-01-06 Ed Schonberg <schonberg@adacore.com>
409 * sem_case.adb (Explain_Non_Static_Bound): Suppress cascaded
410 error on case expression that is an entity, when coverage is
411 incomplete and entity has a static value obtained by local
413 (Handle_Static_Predicate): New procedure, subsidiary of
414 Check_Choices, to handle case alternatives that are either
415 subtype names or subtype indications involving subtypes that
416 have static predicates.
418 2017-01-06 Thomas Quinot <quinot@adacore.com>
420 * s-oscons-tmplt.c, g-socket.adb, g-socket.ads, g-sothco.ads:
421 (GNAT.Socket): Add support for Busy_Polling and Generic_Option
423 2017-01-06 Bob Duff <duff@adacore.com>
425 * sem_elab.adb (Activate_Elaborate_All_Desirable): Don't add
426 Elaborate_All(P) to P itself. That could happen in obscure cases,
427 and always introduced a cycle (P body must be elaborated before
429 * lib-writ.ads: Comment clarification.
430 * ali-util.ads: Minor comment fix.
431 * ali.adb: Minor reformatting.
433 2017-01-06 Tristan Gingold <gingold@adacore.com>
435 * a-exexpr-gcc.adb: Improve comment.
437 2017-01-03 James Cowgill <James.Cowgill@imgtec.com>
439 * s-linux-mips.ads: Use correct signal and errno constants.
440 (sa_handler_pos, sa_mask_pos): Fix offsets for 64-bit MIPS.
442 2017-01-03 James Cowgill <James.Cowgill@imgtec.com>
444 * s-linux-mips.ads: Rename from s-linux-mipsel.ads.
445 * gcc-interface/Makefile.in (MIPS/Linux): Merge mips and mipsel
448 2017-01-01 Eric Botcazou <ebotcazou@adacore.com>
450 * gnatvsn.ads: Bump copyright year.
452 2017-01-01 Jakub Jelinek <jakub@redhat.com>
454 * gnat_ugn.texi: Bump @copying's copyright year.
455 * gnat_rm.texi: Likewise.
457 Copyright (C) 2017 Free Software Foundation, Inc.
459 Copying and distribution of this file, with or without modification,
460 are permitted in any medium without royalty provided the copyright
461 notice and this notice are preserved.