[Ada] Minor fixes and tweaks to comments in the Repinfo unit
[gcc.git] / gcc / ada / ChangeLog
1 2018-05-28 Eric Botcazou <ebotcazou@adacore.com>
2
3 * repinfo.ads: Minor fixes and tweaks in comments.
4
5 2018-05-28 Eric Botcazou <ebotcazou@adacore.com>
6
7 * repinfo.adb (List_GCC_Expression): Remove Valop and replace calls to
8 it with calls to Unop.
9
10 2018-05-28 Eric Botcazou <ebotcazou@adacore.com>
11
12 * repinfo.ads (TCode): Adjust range.
13 (Truth_Andif_Expr): Remove.
14 (Truth_Orif_Expr): Likewise.
15 (Truth_And_Expr .. Dynamic_Val): Adjust value.
16 * repinfo.adb (Print_Expr): Remove handling of Truth_{And,Or}if_Expr.
17 (Rep_Value): Likewise.
18 * repinfo.h (Truth_Andif_Expr): Remove.
19 (Truth_Orif_Expr): Likewise.
20 (Truth_And_Expr .. Dynamic_Val): Adjust value.
21 * gcc-interface/decl.c (annotate_value) <TRUTH_ANDIF_EXPR>: Fall
22 through to TRUTH_AND_EXPR case.
23 <TRUTH_ORIF_EXPR>: Fall through to TRUTH_OR_EXPR case.
24
25 2018-05-28 Ed Schonberg <schonberg@adacore.com>
26
27 * exp_unst.adb (Visit_Node): For indexed components and attribute
28 references, examine index expressions or associated expressions as well
29 to record uplevel references.
30 (Vist_Node): For function and procedure calls, if a formal is an
31 unconstrained array and the actual is constrained, check whether bounds
32 of actual have uplevel references.
33
34 2018-05-28 Ed Schonberg <schonberg@adacore.com>
35
36 * einfo.ads, einfo.adb: Exceptions can be uplevel references, and thus
37 they can appear as components of activation records.
38 * exp_unst.adb (Visit_Node): A reference to an exception may be an
39 uplevel reference.
40
41 2018-05-28 Eric Botcazou <ebotcazou@adacore.com>
42
43 * exp_ch4.adb (Expand_Composite_Equality): Compute whether the size
44 depends on a discriminant manually instead of using the predicate
45 Size_Depends_On_Discriminant in the array type case.
46
47 2018-05-28 Ed Schonberg <schonberg@adacore.com>
48
49 * exp_unst.adb (Check_Static_Type): For a record subtype, check
50 discriminant constraints as well.
51 (Visit_Node): For a selected component, check type of prefix, as is
52 done for indexed components and slices.
53
54 2018-05-28 Javier Miranda <miranda@adacore.com>
55
56 * exp_ch4.adb (Real_Range_Check): Add a temporary to store the integer
57 value when converting a float value to a fixed-point value. This is
58 required for CCG because it handles fixed-point types by means of
59 unsigned integer type variables. The range check is now performed using
60 the integer value stored in this temporary.
61
62 2018-05-28 Yannick Moy <moy@adacore.com>
63
64 * sem_util.adb (Is_OK_Volatile_Context): Add attributes First, Last and
65 Length as valid non-interfering contexts for SPARK.
66
67 2018-05-28 Claire Dross <dross@adacore.com>
68
69 * sem_disp.ads, sem_disp.adb (Inheritance_Utilities): Package for
70 generic inheritance utilities.
71 (Generic_Inherited_Subprograms): Generic version of
72 Inherited_Subprograms, generic in Find_Dispatching_Type function.
73 (Generic_Is_Overriding_Subprogram): Generic version of
74 Is_Overriding_Subprogram, generic in Find_Dispatching_Type function.
75 (Inherited_Subprograms): Instance of Generic_Inherited_Subprograms with
76 Sem_Disp.Find_Dispatching_Type.
77 (Is_Overriding_Subprogram): Instance of
78 Generic_Is_Overriding_Subprogram with Sem_Disp.Find_Dispatching_Type.
79 (Inheritance_Utilities_Inst): Instance of Inheritance_Utilities
80 with Sem_Disp.Find_Dispatching_Type.
81
82 2018-05-28 Eric Botcazou <ebotcazou@adacore.com>
83
84 * exp_ch4.adb (Expand_Composite_Equality): For a composite (or FP)
85 component type, do not expand array equality using the unconstrained
86 base type, except for the case where the bounds of the type depend on a
87 discriminant.
88
89 2018-05-28 Ed Schonberg <schonberg@adacore.com>
90
91 * einfo.ads, einfo.adb (Needs_Activation_Record): New flag on
92 access-to-subprogram types, to indicate that an indirect call through
93 such a type requires an activation record when compiling for LLVM.
94 * sem_ch3.adb (Access_Subprogram_Declaration): Set new flag as needed.
95
96 2018-05-28 Ed Schonberg <schonberg@adacore.com>
97
98 * exp_ch4.adb (Real_Range_Check): Specialize float-to-fixed conversions
99 when bounds of fixed type are static, to remove some spuerfluous
100 implicit conversions and provide an accurate result when converting
101 back and forth between the fixed point type and a floating point type.
102
103 2018-05-28 Ed Schonberg <schonberg@adacore.com>
104
105 * exp_unst.adb (Unnest_Subprogram): Prevent creation of empty
106 activation records.
107
108 2018-05-28 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
109
110 * exp_unst.adb (Check_Static_Type): Add argument to indicate node to be
111 replaced, if any; all callers changed.
112 (Note_Uplevel_Ref): Likewise. Also replace reference to deferred
113 constant with private view so we take the address of that entity.
114 (Note_Uplevel_Bound): Add argument to indicate node to be replaced, if
115 any; all callers changed. Handle N_Indexed_Component like
116 N_Attribute_Reference. Add N_Type_Conversion case.
117 (Visit_Node): Indexed references can be uplevel if the type isn't
118 static.
119 (Unnest_Subprograms): Don't rewrite if no reference given. If call has
120 been relocated, set first_named pointer in original node as well.
121
122 2018-05-28 Ed Schonberg <schonberg@adacore.com>
123
124 * exp_aggr.adb (Flatten): Copy tree of expression in a component
125 association with a range or a set of discrete choices, rather than
126 relocating the node. This avoids inconsistencies in the tree when
127 handling nested subprograms with uplevel references for LLVM.
128
129 2018-05-28 Arnaud Charlet <charlet@adacore.com>
130
131 * exp_util.adb (Possible_Bit_Aligned_Component): Always return False in
132 codepeer mode.
133
134 2018-05-28 Arnaud Charlet <charlet@adacore.com>
135
136 * exp_unst.adb: Fix typo.
137
138 2018-05-28 Bob Duff <duff@adacore.com>
139
140 * libgnat/a-convec.adb (Query_Element): Minor cleanup: remove an
141 unnecessary use of 'Unrestricted_Access.
142
143 2018-05-28 Hristian Kirtchev <kirtchev@adacore.com>
144
145 * repinfo.adb (Expr_Value_S): New routine.
146 (List_Linker_Section): Properly extract the value of the section
147 argument.
148
149 2018-05-28 Patrick Bernardi <bernardi@adacore.com>
150
151 * doc/gnat_ugn/building_executable_programs_with_gnat.rst: Update the
152 description of the -D binder switch to reflect current usage.
153 * gnat_ugn.texi: Regenerate.
154
155 2018-05-28 Gary Dismukes <dismukes@adacore.com>
156
157 * exp_ch3.adb: Minor reformatting
158
159 2018-05-28 Justin Squirek <squirek@adacore.com>
160
161 * exp_ch3.adb
162 (Build_Initialization_Call): Add logic to pass the appropriate actual to match
163 new formal.
164 (Init_Formals): Add new formal *_skip_null_excluding_check
165 * exp_util.adb, exp_util.ads
166 (Enclosing_Init_Proc): Added to fetch the enclosing Init_Proc from the current
167 scope.
168 (Inside_Init_Proc): Refactored to use Enclosing_Init_Proc
169 (Needs_Conditional_Null_Excluding_Check): Added to factorize the predicate
170 used to determine how to generate an Init_Proc for a given type.
171 (Needs_Constant_Address): Minor reformatting
172 * sem_res.adb
173 (Resolve_Null): Add logic to generate a conditional check in certain cases
174
175 2018-05-28 Hristian Kirtchev <kirtchev@adacore.com>
176
177 * exp_aggr.adb, gnatlink.adb, sem_ch6.adb, sem_res.adb, sem_util.adb:
178 Minor reformatting.
179
180 2018-05-28 Hristian Kirtchev <kirtchev@adacore.com>
181
182 * sem_prag.adb (Process_Atomic_Independent_Shared_Volatile): Include
183 the declarations of single concurrent types because they fall in the
184 category of full type and object declarations.
185
186 2018-05-28 Eric Botcazou <ebotcazou@adacore.com>
187
188 * repinfo.adb (Compute_Max_Length): Skip _Parent component.
189 (List_Record_Layout): Likewise.
190
191 2018-05-28 Ed Schonberg <schonberg@adacore.com>
192
193 * sem_util.adb (Is_Function_Result): Add a warning if a postcondition
194 includes a call to function to which it applies. This may mean an
195 omission of an attribute reference 'Result, in particular if the
196 function is pqrameterless.
197
198 2018-05-28 Justin Squirek <squirek@adacore.com>
199
200 * sem_ch8.adb (Find_Expanded_Name): Add extra guard to make sure the
201 misresolved package name is not a case of mistaken identity.
202
203 2018-05-28 Yannick Moy <moy@adacore.com>
204
205 * sem_res.adb (Resolve_Range): Re-resolve the low bound of a range in
206 GNATprove mode, as the order of resolution (low then high) means that
207 all the information is not available when resolving the low bound the
208 first time.
209
210 2018-05-28 Eric Botcazou <ebotcazou@adacore.com>
211
212 * repinfo.adb (List_Array_Info): Start with an explicit blank line and
213 end with the linker section, if any.
214 (List_Entities): Do not output the linker section for record types,
215 array types and variables.
216 (Print_Expr): Factor out common processing for unary operators and
217 special values. Adjust and reorder the various cases.
218 (List_Object_Info): End with the linker section, if any.
219 (List_Record_Info): Likewise.
220 (List_Type_Info): Do not start with a blank line.
221
222 2018-05-25 Nicolas Roche <roche@adacore.com>
223
224 * libgnat/s-valrea.adb (Scan_Real): Abort computation once it is sure
225 that the result will be either -infinite or +infinite.
226
227 2018-05-25 Patrick Bernardi <bernardi@adacore.com>
228
229 * libgnat/s-parame.ads, libgnat/s-parame__vxworks.ads,
230 libgnat/s-parame__ae653.ads, libgnat/s-parame__hpux.ads (Size_Type):
231 Expand range of type to match the address space of the target.
232 (Task_Storage_Size): Remove unused type.
233
234 2018-05-25 Ed Schonberg <schonberg@adacore.com>
235
236 * sem_res.adb (Set_Mixed_Mode_Operand): If the operand is an expression
237 of a fixed point type and the parent is a multiplying operation,
238 resolve the operand with its own type because the context will impose a
239 resulting type on the result of the multiplication by means of
240 approriate conversion.
241
242 2018-05-25 Hristian Kirtchev <kirtchev@adacore.com>
243
244 * exp_ch3.adb (Default_Initialize_Object): Ensure that the analysis of
245 the in-place initialization aggregate created for pragmas
246 Initialize_Scalars or Normalize_Scalars is performed with checks
247 suppressed.
248
249 2018-05-25 Arnaud Charlet <charlet@adacore.com>
250
251 * exp_aggr.adb (Convert_To_Positional): Bump default for
252 Max_Others_Replicate to 32. Update comments.
253 * osint.ads (Unknown_Attributes): No longer pretend this is a constant.
254 (No_File_Info_Cache): Initialize separately.
255 * osint.adb (No_File_Info_Cache): Update initializer.
256
257 2018-05-25 Javier Miranda <miranda@adacore.com>
258
259 * sem_res.adb (Resolve_Membership_Op): Allow the use of the membership
260 test when the left operand is a class-wide interface and the right
261 operand is not a class-wide type.
262 * exp_ch4.adb (Tagged_Membership): Adding support for interface as the
263 left operand.
264
265 2018-05-25 Ed Schonberg <schonberg@adacore.com>
266
267 * exp_aggr.adb (Flatten): A quantified expression cannot be duplicated
268 in an others clause to prevent visibility issues with the generated
269 loop variable.
270 (Component_OK_For_Backend): Return false for a quantified expression.
271 (Check_Static_Component): Ditto.
272
273 2018-05-25 Hristian Kirtchev <kirtchev@adacore.com>
274
275 * libgnat/s-secsta.adb (SS_Allocate): Reimplemented.
276 (SS_Allocate_Dynamic): New routine. The allocation logic is now split
277 into three distring cases rather than in one loop which attempts to
278 handle all three cases. This rewrite eliminates an issue where the last
279 frame of the stack cannot be freed, thus causing the memory range of a
280 new frame to approach the overflow point of the memory index type.
281 Since the overflow is logically treated as a
282 too-much-memory-on-the-stack scenario, it causes a bogus Storage_Error.
283 (SS_Allocate_Static): New routine. The routine factorizes the static
284 secondary stack-related code from the former SS_Allocate.
285
286 2018-05-25 Sergey Rybin <rybin@adacore.com>
287
288 * doc/gnat_ugn/gnat_and_program_execution.rst: Add description of '-U'
289 option for gnatelim.
290
291 2018-05-25 Ed Schonberg <schonberg@adacore.com>
292
293 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Do not create
294 Class_Wide_Clone_Body when analyzing a subprogram_body_stub: the clone
295 is created when the proper body of the stub is analyzed.
296 * sem_util.adb (ZBuild_Class_Wide_Clone_Body): If the subprogram body
297 is the proper body of a subunit, the cloned body must be inserted in
298 the declarative list that contains the stub.
299
300 2018-05-25 Justin Squirek <squirek@adacore.com>
301
302 * exp_ch6.adb (Expand_Simple_Function_Return): Add guard in check to
303 generate code for 6.5(8-10) so that we don't get an assertion error
304 when dealing with an incomplete return type.
305
306 2018-05-25 Arnaud Charlet <charlet@adacore.com>
307
308 * pprint.adb (Expression_Name): Strip too long expressions to avoid
309 carrying very large strings.
310
311 2018-05-25 Patrick Bernardi <bernardi@adacore.com>
312
313 * switch-b.adb (Scan_Binder_Switches): binder switch -Q accepts Natural
314 numbers.
315
316 2018-05-25 Doug Rupp <rupp@adacore.com>
317
318 * tracebak.c (aarch64-linux): Implement.
319
320 2018-05-25 Justin Squirek <squirek@adacore.com>
321
322 * sem_ch8.adb: Minor reformatting.
323
324 2018-05-25 Piotr Trojanek <trojanek@adacore.com>
325
326 * sem_util.adb (Iterate_Call_Parameters): Fix code convention and
327 assertions.
328
329 2018-05-25 Hristian Kirtchev <kirtchev@adacore.com>
330
331 * einfo.adb, einfo.ads, exp_ch3.adb, exp_ch8.adb, exp_unst.adb,
332 pprint.adb, sem_ch12.adb, sem_ch3.adb, sem_prag.adb, sem_util.adb:
333 Minor reformatting.
334
335 2018-05-25 Ed Schonberg <schonberg@adacore.com>
336
337 * sem_ch12.adb (Instance_Exists): New function, subsidiary of
338 Validate_Derived_Type_Instance, to verify that all interfaces
339 implemented by the formal type are also implemented by the actual. The
340 verification is complicated when an interface of the formal is declared
341 in a generic unit and the actual is declared in an instance of it.
342 There is currently no mechanism to relate an interface declared within
343 a generic to the corresponding interface in an instance, so we must
344 traverse the list of interfaces of the actual, looking for a name
345 match, and verifying that that interface is declared in an instance.
346
347 2018-05-25 Piotr Trojanek <trojanek@adacore.com>
348
349 * sem_util.adb (Iterate_Call_Parameters): Rewrite with extra
350 assertions; replace function versions of Next_Formal/Next_Actual with
351 their procedural versions (which are more concise).
352
353 2018-05-25 Doug Rupp <rupp@adacore.com>
354
355 * libgnarl/s-osinte__aix.ads, libgnarl/s-osinte__android.ads,
356 libgnarl/s-osinte__darwin.ads, libgnarl/s-osinte__freebsd.ads,
357 libgnarl/s-osinte__hpux.ads, libgnarl/s-osinte__kfreebsd-gnu.ads,
358 libgnarl/s-osinte__linux.ads, libgnarl/s-osinte__lynxos178e.ads,
359 libgnarl/s-osinte__qnx.ads, libgnarl/s-osinte__rtems.ads
360 (Relative_Timed_Wait): Remove.
361 * libgnarl/s-tpopmo.adb (Timed_Sleep, Timed_Delay): Rewrite to allow
362 for incremental looping. Remove references to Rel_Time and
363 Relative_Timed_Wait.
364 * libgnat/s-osprim__posix.adb, libgnat/s-osprim__posix2008.adb
365 (Timed_Delay): Make separate.
366 * libgnat/s-optide.adb: New separate procedure.
367 * libgnat/s-osprim.ads (Max_System_Delay): New constant.
368 * libgnat/s-osprim__lynxos.ads (Max_Sensible_Delay): Set to 6 months.
369 (Max_System_Delay): New constant.
370
371 2018-05-25 Ed Schonberg <schonberg@adacore.com>
372
373 * sem_ch12.adb (Validate_Derived_Type_Instance): Verify that the actual
374 for a formal derived type implements all the interfaces declared for
375 the formal.
376
377 2018-05-25 Yannick Moy <moy@adacore.com>
378
379 * sem_prag.adb (Check_Applicable_Policy): Deal specially with CodePeer
380 and GNATprove modes when applicable policy is Ignore.
381
382 2018-05-25 Eric Botcazou <ebotcazou@adacore.com>
383
384 * freeze.adb (Freeze_Enumeration_Type): Do not give integer size to a
385 boolean type with convention C.
386 * libgnat/i-cexten.ads (bool): Change to boolean with convention C.
387 * gcc-interface/decl.c (gnat_to_gnu_entity): Add new local variable
388 FOREIGN and use it throughout the function.
389 <E_Enumeration_Type>: Set precision 1 on boolean types with foreign
390 convention.
391 <E_Enumeration_Subtype>: Likewise for subtypes.
392 <E_Record_Type>: Force the size of a storage unit on empty classes.
393 * gcc-interface/utils.c (make_type_from_size) <BOOLEAN_TYPE>: Skip
394 boolean types with precision 1 if the size is the expected one.
395
396 2018-05-25 Arnaud Charlet <charlet@adacore.com>
397
398 * pprint.adb (Expression_Name): Do not print non ASCII characters.
399
400 2018-05-25 Bob Duff <duff@adacore.com>
401
402 * libgnat/a-strunb__shared.ads, libgnat/a-stwiun__shared.ads,
403 libgnat/a-stzunb__shared.ads: (Initialize, Adjust): Add pragma Inline.
404
405 2018-05-25 Bob Duff <duff@adacore.com>
406
407 * sem_util.ads: Minor comment fix.
408
409 2018-05-25 Ed Schonberg <schonberg@adacore.com>
410
411 * exp_unst.adb (Visit_Node): Restrict check for uplevel references in
412 prefixes of array attributes, to prefixes that are entity names whose
413 type is constrained.
414 (Note_Uplevel_Bound): Verify that the bound is declared in an enclosing
415 subprogram, as itype created for loops in pre/postcondition may appear
416 in loops at the library level.
417
418 2018-05-25 Ed Schonberg <schonberg@adacore.com>
419
420 * sem_ch13.adb (Build_Predicate_Functions): The predicate function
421 declaration is inserted into the tree and analyzed at that point, so
422 should not be reinserted when the body is constructed. Inside a
423 generic, ensure that the body is not inserted twice in the tree.
424
425 2018-05-25 Yannick Moy <moy@adacore.com>
426
427 * sem_prag.adb (Check_Grouping): Modify test to ignore statements and
428 declarations not coming from source.
429
430 2018-05-25 Fedor Rybin <frybin@adacore.com>
431
432 * doc/gnat_ugn/gnat_utility_programs.rst: Document new switch
433 --copy-environment for gnattest.
434
435 2018-05-24 Piotr Trojanek <trojanek@adacore.com>
436
437 * sem_elab.adb (Non_Private_View): Simplify by removing a local Result
438 variable.
439 * sem_prag.adb (Get_Base_Subprogram): Same as above.
440
441 2018-05-24 Eric Botcazou <ebotcazou@adacore.com>
442
443 * fe.h (Set_Normalized_First_Bit): Declare.
444 (Set_Normalized_Position): Likewise.
445 * repinfo.adb (List_Record_Layout): Do not use irregular output for a
446 variable position. Fix minor spacing issue.
447 * gcc-interface/decl.c (annotate_rep): If a field has a variable
448 offset, compute the normalized position and annotate it in addition to
449 the bit offset.
450
451 2018-05-24 Eric Botcazou <ebotcazou@adacore.com>
452
453 * gcc-interface/trans.c (Handled_Sequence_Of_Statements_to_gnu):
454 Constify and rename variables. Fix formatting.
455 (gnat_to_gnu) <N_Exception_Handler>: Minor tweak.
456 <N_Raise_Statement>: Likewise.
457
458 2018-05-24 Javier Miranda <miranda@adacore.com>
459
460 * exp_ch8.adb (Build_Body_For_Renaming): Adding support to build the
461 body of a variant record equality renaming.
462 (Expand_N_Subprogram_Renaming_Declaration): Adapt the code to the new
463 implementation of Build_Body_For_Renaming.
464 * exp_ch3.ads (Build_Variant_Record_Equality): New library level
465 function that factorizes the functionality needed by
466 Build_Body_For_Renaming and Expand_Freeze_Record_Type to build the body
467 of a variant record equality subprogram.
468 * exp_ch3.adb (Build_Variant_Record_Equality): New subprogram.
469 (Build_Variant_Record_Equality): New local procedure of
470 Expand_Freeze_Record_Type containing all the code specific for freezing
471 the record type that cannot be place in the new library level function.
472
473 2018-05-24 Ed Schonberg <schonberg@adacore.com>
474
475 * einfo.ads, einfo.adb (Is_Activation_Record): New flag on
476 in_parameters, used when unesting subprograms for LLVM, to indicate
477 that a generated parameter carries the activation record from the
478 enclosing subprogram.
479 * exp_unst.adb (Check_Static_Type): Handle array attributes of types
480 whose bounds may contain up-level references that need to be added to
481 an activation recoord.
482 (Add_Extra_Formal): Set Is_Activation_Record on new formal.
483
484 2018-05-24 Yannick Moy <moy@adacore.com>
485
486 * pprint.adb (Expression_Image): Improve the printing of expressions,
487 by taking more cases into account, in particular qualified expressions
488 and aggregates. Also count more the number of parentheses to close
489 after the expression.
490
491 2018-05-24 Javier Miranda <miranda@adacore.com>
492
493 * sem_ch3.adb (Is_Visible_Component): For untagged types add missing
494 check for renamed discriminants.
495 * sem_ch4.adb (Analyze_Overloaded_Selected_Component,
496 Analyze_Selected_Component, Check_Misspelled_Selector): For calls to
497 Is_Visible_Component pass the associated selector node to allow
498 checking renamed discriminants on untagged types.
499
500 2018-05-24 Ed Schonberg <schonberg@adacore.com>
501
502 * sem_ch8.adb (Analyze_Use_Type): Do not assign the Prev_Use_Clause
503 link to a use_type clause if this would cause an infinite loop in the
504 machinery that detects redundant use clauses. This may happen when the
505 redundant clauses appear in the context of a child unit and the context
506 of its parent.
507
508 2018-05-24 Piotr Trojanek <trojanek@adacore.com>
509
510 * sinfo.ads: Fix grammar in comment.
511
512 2018-05-24 Justin Squirek <squirek@adacore.com>
513
514 * einfo.ads, einfo.adb (Append_Entity): Modified to use Link_Entities
515 and manage doubly-linked entity chain.
516 (Nested_Scenarios): Removed entity field used for optimization during
517 elaboration to make room for the new field Prev_Entity.
518 (Link_Entities): Added to replace redundant calls to Set_Next_Entity
519 and Set_Prev_Entity as well as centralize changes to the entity chain.
520 (Predicated_Parent): Modified to use Node38.
521 (Prev_Entity): Added to fetch new node field Prev_Entity in all entity
522 types.
523 (Remove_Entity): Moved from sem_util.
524 (Set_Nested_Scenarios): Deleted.
525 (Set_Predicated_Parent): Modified to use Node38.
526 (Set_Prev_Entity): Added to set Prev_Entity field.
527 (Set_Validated_Object): Modified to use Node38.
528 (Unlink_Next_Entity): Added to process Prev_Entity when an unlinking
529 action is required.
530 (Validated_Object): Modified to use Node38.
531 (Write_Field36_Name): Remove Nested_Scenarios, Validated_Object, and
532 predicated parent cases.
533 (Write_Field38_Name): Add predicated parent and Validated_Object cases.
534 * sem_ch3.adb (Process_Subtype): Add guard to protect against
535 inappropriate marking of Predicated_Parent to non-itype subtypes.
536 (Make_Class_Wide_Type): Preserve Prev_Entity field and set in new type.
537 (Copy_And_Swap): Add setting of Prev_Entity.
538 (Build_derived_Record_Type): Replace Set_Next_Entity w/ Link_Entities.
539 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Replace Set_Next_Entity
540 w/ Link_Entities.
541 (New_Overloaded_Entity): Remove block created to search for previous
542 entities in the entity chain with relevant calls to Prev_Entity as well
543 as replace duplicated code from Remove_Entity_And_Homonym with a call
544 to that subprogram.
545 * sem_ch7.adb (Exchange_Declarations): Replace Set_Next_Entity w/
546 Link_Entities.
547 * sem_elab.adb (Find_And_Process_Nested_Scenarios): Remove global and
548 initial subprogram declarations related to Nested_Scenarios.
549 (Process_Nested_Scenarios): Deleted.
550 (Save_Scenario): Deleted.
551 (Traverse_Body): Remove optimization for Nested_Scenarios so as to free
552 node space in the entity tree.
553 * sem_util.adb, sem_util.ads (Remove_Entity): Moved to einfo.
554 (Remove_Entity_And_Homonym): Added to separate functionality of
555 Remove_Entity from the homonym chain directly.
556 * exp_attr.adb (Expand_N_Attribute_Reference): Replace Set_Next_Entity
557 w/ Link_Entities and Unlink_Next_Entity.
558 * exp_ch3.adb (Expand_N_Object_Declaration): Replace Set_Next_Entity w/
559 Link_Entities.
560 * exp_ch6.adb (Replace_Renaming_Declaration_Id): Replace
561 Set_Next_Entity w/ Link_Entities.
562 * exp_disp.adb (Expand_Dispatching_Call): Replace Set_Next_Entity w/
563 Link_Entities and Unlink_Next_Entity.
564 * exp_spark.adb (Expand_SPARK_N_Object_Renaming_Declaration): Replace
565 call to Remove_Entity with its new incarnation.
566 * exp_util.adb (New_Class_Wide_Subtype): Add setting of Prev_Entity.
567 * freeze.adb (Freeze_Record_Type): Replace Set_Next_Entity w/
568 Link_Entities.
569
570 2018-05-24 Hristian Kirtchev <kirtchev@adacore.com>
571
572 * sem_ch10.adb (Expand_Limited_With_Clause): Update the call to
573 Install_Limited_Withed_Unit.
574 (Expand_With_Clause): Update the call to Install_Withed_Unit.
575 (Implicit_With_On_Parent): Update the call to Install_Withed_Unit.
576 (Install_Context_Clauses): Update the call to Install_Withed_Unit.
577 (Install_Limited_Context_Clauses): Update the calls to
578 Install_Limited_Withed_Unit.
579 (Install_Limited_Withed_Unit): Renamed to better illustrate its
580 purpose.
581 (Install_Private_With_Clauses): Update the calls to Install_Withed_Unit
582 and Install_Limited_Withed_Unit.
583 (Install_With_Clause): Uninstall a limited with clause if a [private]
584 with clause is given for the same package.
585 (Install_Withed_Unit): Renamed to better illustrate its purpose.
586 (Remove_Limited_With_Unit): New routine.
587
588 2018-05-24 Eric Botcazou <ebotcazou@adacore.com>
589
590 * raise-gcc.c (__gnat_SEH_error_handler): Remove prototype.
591 (__gnat_personality_seh0): Adjust and beef up comments, and
592 fix formatting throughout.
593 (__gnat_adjust_context): Deal minimally with version 2.
594 * seh_init.c (__gnat_map_SEH): Fix formatting.
595 (_gnat_SEH_error_handler): Adjust comments.
596 (__gnat_install_SEH_handler): Fix formatting.
597
598 2018-05-24 Hristian Kirtchev <kirtchev@adacore.com>
599
600 * exp_ch7.adb, sem_ch3.adb, sem_res.adb: Minor reformatting.
601
602 2018-05-24 Ed Schonberg <schonberg@adacore.com>
603
604 * exp_aggr.adb (Flatten): Add a warning on an others clause in an array
605 aggregate with static bounds when named associations cover all index
606 positions and the others clause is redundant.
607
608 2018-05-24 Raphael Amiard <amiard@adacore.com>
609
610 * libgnat/a-cohama.ads: Add documentation.
611
612 2018-05-24 Raphael Amiard <amiard@adacore.com>
613
614 * libgnat/a-convec.ads: Add documentation.
615
616 2018-05-24 Justin Squirek <squirek@adacore.com>
617
618 * exp_ch3.adb (Expand_N_Object_Declaration): Ignore raising an error in
619 expansion for limited tagged types when the node to be expanded is a
620 raise expression due to it not representing a valid object.
621 * exp_ch5.adb (Expand_N_Assignment_Statement): Add exception to error
622 message regarding assignments to limited types to ignore genereated
623 code.
624
625 2018-05-24 Hristian Kirtchev <kirtchev@adacore.com>
626
627 * exp_util.adb (New_Class_Wide_Subtype): Capture and restore relevant
628 Ghost-related attributes of the class-wide subtype because the copy
629 clobbers them.
630
631 2018-05-24 Justin Squirek <squirek@adacore.com>
632
633 * sem_res.adb (Resolve_Entity_Name): Add guard to protect against
634 marking use clauses as effective when the reference appears within
635 generated code.
636
637 2018-05-24 Cyrille Comar <comar@adacore.com>
638
639 * doc/gnat_rm/the_gnat_library.rst: Fix typos.
640 * gnat_rm.texi: Regenerate.
641
642 2018-05-24 Bob Duff <duff@adacore.com>
643
644 * exp_ch7.adb (Expand_Cleanup_Actions): Create a mark unconditionally
645 for build-in-place functions with a caller-unknown-size result.
646 (Create_Finalizer): For build-in-place functions with a
647 caller-unknown-size result, check at run time whether we need to
648 release the secondary stack.
649
650 2018-05-24 Hristian Kirtchev <kirtchev@adacore.com>
651
652 * sem_prag.adb (Analyze_Pragma): Use the full view of an internally
653 generated incomplete type.
654
655 2018-05-24 Hristian Kirtchev <kirtchev@adacore.com>
656
657 * expander.adb (Expand): Update the save and restore of the Ghost
658 region.
659 * exp_ch3.adb (Freeze_Type): Likewise.
660 * exp_disp.adb (Make_DT): Likewise.
661 * exp_util.adb (Build_DIC_Procedure_Body): Likewise.
662 (Build_DIC_Procedure_Declaration): Likewise.
663 (Build_Invariant_Procedure_Body): Likewise.
664 (Build_Invariant_Procedure_Declaration): Likewise.
665 (Make_Predicate_Call): Likewise.
666 * freeze.adb (Add_To_Result): Insert the freeze action of a living
667 entity prior to the start of the enclosing ignored Ghost region.
668 (Freeze_Entity): Update the save and restore of the Ghost region.
669 * ghost.adb (Install_Ghost_Mode): Reimplemented.
670 (Install_Ghost_Region): New routine.
671 (Mark_And_Set_Ghost_Assignment): Install a region rather than a mode.
672 (Mark_And_Set_Ghost_Body): Likewise.
673 (Mark_And_Set_Ghost_Completion): Likewise.
674 (Mark_And_Set_Ghost_Declaration): Likewise.
675 (Mark_And_Set_Ghost_Instantiation): Likewise.
676 (Mark_And_Set_Ghost_Procedure_Call): Likewise.
677 (Name_To_Ghost_Mode): New routine.
678 (Restore_Ghost_Region): New routine.
679 * ghost.ads (Install_Ghost_Region): New routine.
680 (Restore_Ghost_Region): New routine.
681 * opt.ads: Add new global variable Ignored_Ghost_Region.
682 * rtsfind.adb (Load_RTU): Update the save and restore of the Ghost
683 region. Install a clean region.
684 * sem.adb (Analyze): Likewise.
685 (Do_Analyze): Likewise.
686 * sem_ch3.adb (Analyze_Object_Declaration): Likewise
687 (Derive_Progenitor_Subprograms): Use local variable Iface_Alias to
688 capture the ultimate alias of the current primitive.
689 (Process_Full_View): Update the save and restore of the Ghost region.
690 Do not inherit DIC and invariant procedures.
691 * sem_ch5.adb (Analyze_Assignment): Update the save and restore of the
692 Ghost region.
693 * sem_ch6.adb (Analyze_Procedure_Call): Likewise.
694 (Analyze_Subprogram_Body_Helper): Likewise.
695 * sem_ch7.adb (Analyze_Package_Body_Helper): Likewise.
696 * sem_ch12.adb (Analyze_Package_Instantiation): Likewise.
697 (Analyze_Subprogram_Instantiation): Likewise.
698 (Instantiate_Package_Body): Likewise.
699 (Instantiate_Subprogram_Body): Likewise.
700 * sem_ch13.adb (Build_Predicate_Functions): Likewise.
701 (Build_Predicate_Function_Declaration): Likewise.
702 * sem_disp.adb
703 (Add_Dispatching_Operation): Do not consider DIC and invariant
704 procedures.
705 (Check_Dispatching_Operation): Use Add_Dispatching_Operation to collect
706 a dispatching subprogram.
707 (Check_Operation_From_Private_View): Likewise.
708 (Override_Dispatching_Operation): Likewise.
709 * sem_prag.adb (Analyze_Contract_Cases_In_Decl_Part): Update the save
710 and restore of the Ghost region.
711 (Analyze_Initial_Condition_In_Decl_Part): Likewise.
712 (Analyze_Pragma): Update the save and restore of the Ghost region.
713 (Analyze_Pre_Post_Condition_In_Decl_Part): Likewise.
714 * sem_util.adb (Is_Suitable_Primitive): New routine.
715 * sem_util.ads (Is_Suitable_Primitive): New routine.
716 * sinfo.ads: Update the section of Ghost regions.
717
718 2018-05-24 Piotr Trojanek <trojanek@adacore.com>
719
720 * doc/gnat_rm/implementation_defined_pragmas.rst (Contract_Cases):
721 Change "condition" to "case guard" after renaming in the contract
722 grammar.
723 * gnat_rm.texi: Regenerate.
724
725 2018-05-24 Hristian Kirtchev <kirtchev@adacore.com>
726
727 * exp_util.adb (Expand_Static_Predicates_In_Choices): Indicate that the
728 construct with discrete choices no longer contains a subtype with
729 predicates since the expansion already handled this case.
730
731 2018-05-24 Hristian Kirtchev <kirtchev@adacore.com>
732
733 * freeze.adb (Wrap_Imported_Subprogram): Generate an unchecked
734 conversion to the return type to avoid a side effect where an imported
735 relocated function generates a new anonymous access type, whose
736 accessibility level does not agree with with that of the wrapper.
737
738 2018-05-24 Javier Miranda <miranda@adacore.com>
739
740 * sem_util.adb (Abstract_Interface_List): Add missing support for
741 private types whose full view is a synchronized type.
742 * sem_ch3.adb (Build_Derived_Private_Type): Skip building the full
743 derivation of a private type parent type is a task type with
744 discriminants as gigi does not use such type directly.
745
746 2018-05-24 Hristian Kirtchev <kirtchev@adacore.com>
747
748 * sem_elab.adb (Build_Variable_Reference_Marker): Do not create a
749 variable marker when the reference appears in the formal part of a
750 compilation unit instance because there is no place to insert it.
751 (In_Compilation_Instance_Formal_Part): New routine.
752
753 2018-05-24 Piotr Trojanek <trojanek@adacore.com>
754
755 * layout.ads, repinfo.ads: Fix references to renamed Backend_Layout
756 configuration parameter.
757
758 2018-05-24 Doug Rupp <rupp@adacore.com>
759
760 * argv-lynxos178-raven-cert.c: New file.
761 * libgnat/system-lynxos178-x86.ads: New file.
762
763 2018-05-23 Hristian Kirtchev <kirtchev@adacore.com>
764
765 * exp_disp.adb, freeze.adb, gnat1drv.adb, sem_ch5.adb, sem_spark.adb:
766 Minor reformattings.
767
768 2018-05-23 Pascal Obry <obry@adacore.com>
769
770 * adaint.c (win32_wait): Properly free the handle/pid lists when
771 WaitForMultipleObjects fails (return WAIT_FAILED).
772
773 2018-05-23 Pascal Obry <obry@adacore.com>
774
775 * adaint.c (win32_wait): Add missing parentheses.
776
777 2018-05-23 Hristian Kirtchev <kirtchev@adacore.com>
778
779 * exp_ch3.adb (Check_Large_Modular_Array): Moved to Freeze.
780 (Expand_N_Object_Declaration): Do not check for a large modular array
781 here.
782 * freeze.adb (Check_Large_Modular_Array): Moved from Exp_Ch3.
783 (Freeze_Object_Declaration): Code cleanup. Check for a large modular
784 array.
785 * sem_ch3.adb: Minor reformatting.
786
787 2018-05-23 Ed Schonberg <schonberg@adacore.com>
788
789 * einfo.ads: New attribute on types: Predicated_Parent, to simplify the
790 retrieval of the applicable predicate function to an itype created for
791 a constrained array component.
792 * einfo.adb: Subprograms for Predicated_Parent.
793 (Predicate_Function): Use new attribute.
794 * exp_util.adb (Make_Predicate_Call): If the predicate function is not
795 available for a subtype, retrieve it from the base type, which may have
796 been frozen after the subtype declaration and not captured by the
797 subtype declaration.
798 * sem_aggr.adb (Resolve_Array_Aggregate): An Others association is
799 legal within a generated initiqlization procedure, as may happen with a
800 predicate check on a component, when the predicate function applies to
801 the base type of the component.
802 * sem_ch3.adb (Analyze_Subtype_Declaration): Clean up inheritance of
803 predicates for subtype declarations and for subtype indications in
804 other contexts.
805 (Process_Subtype): Likewise. Handle properly the case of a private type
806 with unknown discriminants whose full view is an unconstrained array.
807 Use Predicated_Parent to indicate source of predicate function on an
808 itype whose parent is itself an itype.
809 (Complete_Private_Subtype): If the private view has unknown
810 discriminants and the full view is an unconstrained array, set base
811 type of completion to the full view of parent.
812 (Inherit_Predicate_Flags): Prevent double assignment of predicate
813 function and flags.
814 (Build_Subtype): For a constrained array component, propagate predicate
815 information from original component type declaration.
816
817 2018-05-23 Boris Yakobowski <yakobowski@adacore.com>
818
819 * libgnat/a-ngelfu.ads (Arctanh, Arccoth): Fix faulty preconditions.
820
821 2018-05-23 Arnaud Charlet <charlet@adacore.com>
822
823 * checks.adb (Minimize_Eliminate_Overflows): Default initialize Lo and
824 Hi.
825 * sem_elab.adb: Make "out" parameters instead of "in out" when
826 relevant.
827
828 2018-05-23 Bob Duff <duff@adacore.com>
829
830 * gnatbind.adb (List_Applicable_Restrictions): Add
831 No_Implementation_Restrictions to the list of restrictions not to list.
832 Remove double negative "not No_Restriction_List". Comment the
833 commentary that is output, so it won't cause errors if used directly in
834 a gnat.adc.
835
836 2018-05-23 Ed Schonberg <schonberg@adacore.com>
837
838 * sem_prag.adb (Inherit_Class_Wide_Pre): Refine legality check on
839 class-wide precondition on a type extension when ancestor does not have
840 a class-wide precondition. Previously the compiler accepted such a
841 precondition when the ancestor had a class-wide postcondition.
842
843 2018-05-23 Javier Miranda <miranda@adacore.com>
844
845 * sem_attr.adb (Valid_Scalars): Do not invoke Error_Attr_P to report
846 the warning on occurrences of this attribute whose evaluation is always
847 true (since that subprogram aborts processing the attribute). In
848 addition, replace the node by its boolean result 'True' (required
849 because the backend has no knowledge of this attribute).
850
851 2018-05-23 Bob Duff <duff@adacore.com>
852
853 * libgnat/a-convec.adb: (Insert, Insert_Space): Suppress warnings. The
854 code in question is not reachable in the case where Count_Type'Last is
855 out of range.
856
857 2018-05-23 Yannick Moy <moy@adacore.com>
858
859 * doc/gnat_rm/implementation_defined_pragmas.rst: Clarify meaning of
860 local pragma Warnings Off without On.
861 * gnat_rm.texi: Regenerate.
862
863 2018-05-23 Olivier Hainque <hainque@adacore.com>
864
865 * libgnat/g-excact.ads (Is_Foreign_Exception): New predicate.
866 * libgnat/g-excact.adb: Implement.
867
868 2018-05-23 Ed Schonberg <schonberg@adacore.com>
869
870 * sem_ch5.adb (Analyze_Iterator_Specification): If a subtype indication
871 is present, verify its legality when the domain of iteration is a
872 GNAT-specific formal container, as is already done for arrays and
873 predefined containers.
874
875 2018-05-23 Yannick Moy <moy@adacore.com>
876
877 * sem_util.adb (Enclosing_Declaration): Fix the case of a named number
878 declaration, which was not taken into account.
879
880 2018-05-23 Hristian Kirtchev <kirtchev@adacore.com>
881
882 * debug.adb: Switch -gnatd_s is now used to stop elaboration checks on
883 synchronized suspension.
884 * rtsfind.ads: Add entries for units Ada.Synchronous_Barriers and
885 Ada.Synchronous_Task_Control and routines Suspend_Until_True and
886 Wait_For_Release.
887 * sem_elab.adb: Document switch -gnatd_s.
888 (In_Task_Body): New routine.
889 (Is_Potential_Scenario): Code cleanup. Stop the traversal of a task
890 body when the current construct denotes a synchronous suspension call,
891 and restriction No_Entry_Calls_In_Elaboration_Code or switch -gnatd_s
892 is in effect.
893 (Is_Synchronous_Suspension_Call): New routine.
894 * switch-c.adb (Scan_Front_End_Switches): Switch -gnatJ now sets switch
895 -gnatd_s.
896
897 2018-05-23 Javier Miranda <miranda@adacore.com>
898
899 * exp_disp.adb (Make_DT): Restrict the initialization of
900 External_Tag and Expanded_Name to an empty string to the case where
901 both pragmas apply (i.e. No_Tagged_Streams and Discard_Names), since
902 restricted runtimes are compiled with pragma Discard_Names.
903 * doc/gnat_rm/implementation_defined_pragmas.rst,
904 doc/gnat_rm/implementation_defined_characteristics.rst: Add
905 documentation.
906 * gnat_rm.texi: Regenerate.
907
908 2018-05-23 Maroua Maalej <maalej@adacore.com>
909
910 * sem_spark.adb: Fix of some permission rules of pointers in SPARK.
911
912 2018-05-23 Ed Schonberg <schonberg@adacore.com>
913
914 * sem_ch5.adb (Preanalyze_Range): The pre-analysis of the domain of
915 iteration of an Ada2012 loop is performed to determine the type of the
916 domain, but full analysis is performed once the loop is rewritten as a
917 while-loop during expansion. The pre-analysis suppresses expansion; it
918 must also suppress the generation of freeze nodes, which may otherwise
919 appear in the wrong scope before rewritting.
920
921 2018-05-23 Hristian Kirtchev <kirtchev@adacore.com>
922
923 * sem_elab.adb: Update the section on suppressing elaboration warnings.
924
925 2018-05-23 Hristian Kirtchev <kirtchev@adacore.com>
926
927 * einfo.adb (Is_Elaboration_Checks_OK_Id): Use predicate
928 Is_Elaboration_Target.
929 (Is_Elaboration_Target): New routine.
930 (Is_Elaboration_Warnings_OK_Id): Use predicate Is_Elaboration_Target.
931 (Set_Is_Elaboration_Checks_OK_Id): Use predicate Is_Elaboration_Target.
932 (Set_Is_Elaboration_Warnings_OK_Id): Use predicate
933 Is_Elaboration_Target.
934 * einfo.ads: Add new synthesized attribute Is_Elaboration_Target along
935 with occurrences in nodes.
936 (Is_Elaboration_Target): New routine.
937 * sem_prag.adb (Analyze_Pragma): Suppress elaboration warnings when an
938 elaboration target is subject to pragma Warnings (Off, ...).
939
940 2018-05-23 Eric Botcazou <ebotcazou@adacore.com>
941
942 * repinfo.adb (List_Type_Info): Remove obsolete stuff.
943
944 2018-05-23 Hristian Kirtchev <kirtchev@adacore.com>
945
946 * einfo.adb: Flag304 is now Is_Elaboration_Warnings_OK_Id.
947 (Is_Elaboration_Warnings_OK_Id): New routine.
948 (Set_Is_Elaboration_Warnings_OK_Id): New routine.
949 (Write_Entity_Flags): Output Flag304.
950 * einfo.ads: Add new attribute Is_Elaboration_Warnings_OK_Id along with
951 occurrences in entities.
952 (Is_Elaboration_Warnings_OK_Id): New routine along with pragma Inline.
953 (Set_Is_Elaboration_Warnings_OK_Id): New routine along with pragma
954 Inline.
955 * sem_attr.adb (Analyze_Access_Attribute): Capture the state of
956 elaboration warnings.
957 * sem_ch3.adb (Analyze_Object_Declaration): Capture the state of
958 elaboration warnings.
959 * sem_ch6.adb (Analyze_Abstract_Subprogram_Declaration): Capture the
960 state of elaboration warnings.
961 (Analyze_Subprogram_Body_Helper): Capture the state of elaboration
962 warnings.
963 (Analyze_Subprogram_Declaration): Capture the state of elaboration
964 warnings.
965 * sem_ch9.adb (Analyze_Entry_Declaration): Capture the state of
966 elaboration warnings.
967 (Analyze_Single_Task_Declaration): Capture the state of elaboration
968 warnings.
969 (Analyze_Task_Type_Declaration): Capture the state of elaboration
970 warnings.
971 * sem_ch12.adb (Analyze_Generic_Package_Declaration): Capture the state
972 of elaboration warnings.
973 (Analyze_Generic_Subprogram_Declaration): Capture the state of
974 elaboration warnings.
975 * sem_elab.adb: Add a section on suppressing elaboration warnings.
976 Type Processing_Attributes includes component Suppress_Warnings
977 intended to suppress any elaboration warnings along a path in the
978 graph. Update Initial_State to include a value for this component.
979 Types Target_Attributes and Task_Attriutes include component
980 Elab_Warnings_OK to indicate whether the target or task has elaboration
981 warnings enabled. component Elab_Warnings_OK.
982 (Build_Access_Marker): Propagate attribute
983 Is_Elaboration_Warnings_OK_Node from the attribute to the generated
984 call marker.
985 (Extract_Instantiation_Attributes): Set the value for Elab_Warnings_OK.
986 (Extract_Target_Attributes): Set the value for Elab_Warnings_OK.
987 (Extract_Task_Attributes): Set the value for Elab_Warnings_OK.
988 (Process_Conditional_ABE_Access): Suppress futher elaboration warnings
989 when already in this mode or when the attribute or target have warnings
990 suppressed.
991 (Process_Conditional_ABE_Activation_Impl): Do not emit any diagnostics
992 if warnings are suppressed.
993 (Process_Conditional_ABE_Call): Suppress further elaboration warnings
994 when already in this mode, or the target or call have warnings
995 suppressed.
996 (Process_Conditional_ABE_Call_Ada): Do not emit any diagnostics if
997 warnings are suppressed.
998 (Process_Conditional_ABE_Call_SPARK): Do not emit any diagnostics if
999 warnings are suppressed.
1000 (Process_Conditional_ABE_Instantiation): Suppress further elaboration
1001 warnings when already in this mode or when the instantiation has
1002 warnings suppressed.
1003 (Process_Conditional_ABE_Instantiation_Ada): Do not emit any
1004 diagnostics if warnings are suppressed.
1005 (Process_Conditional_ABE_Variable_Assignment_Ada): Use the more
1006 specific Is_Elaboration_Warnings_OK_Id rather than Warnings_Off.
1007 (Process_Conditional_ABE_Variable_Assignment_SPARK): Use the more
1008 specific Is_Elaboration_Warnings_OK_Id rather than Warnings_Off.
1009 (Process_Task_Object): Suppress further elaboration warnings when
1010 already in this mode, or when the object, activation call, or task type
1011 have warnings suppressed. Update the processing state to indicate that
1012 the path goes through a task body.
1013 * sinfo.adb (Is_Elaboration_Warnings_OK_Node): Accept attribute
1014 references.
1015 (Set_Is_Elaboration_Warnings_OK_Node): Accept attribute references.
1016 * sinfo.ads: Attribute Is_Elaboration_Warnings_OK_Node now applies to
1017 attribute references.
1018
1019 2018-05-23 Piotr Trojanek <trojanek@adacore.com>
1020
1021 * einfo.ads: Minor reformatting.
1022
1023 2018-05-23 Ed Schonberg <schonberg@adacore.com>
1024
1025 * sem_ch3.adb (Analyze_Object_Declaration): If expression is an
1026 anonymous_access_to_ subprogram formal, apply a conversion to force an
1027 accsssibility check that will fail statically, enforcing 3.10.2 (13).
1028
1029 2018-05-23 Daniel Mercier <mercier@adacore.com>
1030
1031 * gnat1drv.adb: Turn off length expansion in CodePeer mode.
1032
1033 2018-05-23 Bob Duff <duff@adacore.com>
1034
1035 * freeze.adb: (Check_Address_Clause): Deal with build-in-place
1036 aggregates in addition to build-in-place calls.
1037
1038 2018-05-23 Bob Duff <duff@adacore.com>
1039
1040 * einfo.ads: Minor reformatting.
1041 * sem_ch3.adb: Likewise.
1042 * sinfo.ads: Likewise.
1043
1044 2018-05-23 Hristian Kirtchev <kirtchev@adacore.com>
1045
1046 * exp_ch3.adb (Default_Initialize_Object): Do not optimize scalar array
1047 initialization when the component type has predicates.
1048 * exp_ch4.adb (Expand_N_Allocator): Do not optimize scalar array
1049 allocation when the component type has predicates.
1050
1051 2018-05-23 Hristian Kirtchev <kirtchev@adacore.com>
1052
1053 * einfo.adb, exp_disp.adb, sem_ch3.adb, sem_ch6.adb, sem_prag.adb:
1054 Minor reformatting.
1055
1056 2018-05-22 Justin Squirek <squirek@adacore.com>
1057
1058 * sem_ch6.adb (Analyze_Expression_Function): Propagate flags from the
1059 original function spec into the generated function spec due to
1060 expansion of expression functions during analysis.
1061 (Analyze_Subprogram_Body_Helper): Modify check on formal parameter
1062 references from the body to the subprogram spec in the case of
1063 expression functions because of inconsistances related to having a
1064 generated body.
1065 * libgnarl/s-osinte__android.ads: Flag parameters as unused.
1066 * libgnarl/s-osinte__lynxos178e.ads: Likewise.
1067 * libgnarl/s-osinte__qnx.adb: Likewise.
1068 * libgnarl/s-osinte__qnx.ads: Likewise.
1069
1070 2018-05-22 Doug Rupp <rupp@adacore.com>
1071
1072 * init.c (HAVE_ADJUST_CONTEXT_FOR_RAISE): Don't define on VxWorks7 for
1073 AArch64.
1074
1075 2018-05-22 Olivier Hainque <hainque@adacore.com>
1076
1077 * libgnat/a-except.adb (Exception_Propagation.Propagate_Exception):
1078 Expect an Exception_Occurence object, not an Access.
1079 (Complete_And_Propagate_Occurrence): Adjust accordingly.
1080 (Raise_From_Signal_Handler): Likewise.
1081 (Reraise_Occurrence_No_Defer): If we have a Machine_Occurrence
1082 available in the provided occurrence object, just re-propagate the
1083 latter as a bare "raise;" would do.
1084 * libgnat/a-exexpr.adb (Propagate_Exception): Adjust to spec change.
1085 * libgnat/a-exstat.adb (String_To_EO): Initialize X.Machine_Occurrence
1086 to null, to mark that the occurrence we're crafting from the stream
1087 contents is not being propagated (yet).
1088
1089 2018-05-22 Hristian Kirtchev <kirtchev@adacore.com>
1090
1091 * exp_aggr.adb (Initialize_Ctrl_Record_Component): Insert the generated
1092 code for a transient component in line with the rest of the
1093 initialization code, rather than before the aggregate. This ensures
1094 that the component has proper visibility of the discriminants.
1095
1096 2018-05-22 Jerome Lambourg <lambourg@adacore.com>
1097
1098 * adaint.c: Reorganize QNX-specific macros, use syspage to retreive the
1099 number of CPUs.
1100
1101 2018-05-22 Jerome Lambourg <lambourg@adacore.com>
1102
1103 * sigtramp-qnx.c: Properly restore link register in signal trampoline.
1104
1105 2018-05-22 Hristian Kirtchev <kirtchev@adacore.com>
1106
1107 * exp_aggr.adb (Aggr_Assignment_OK_For_Backend): Strip away any
1108 conversions before extracting the value of the expression.
1109 * exp_ch3.adb (Default_Initialize_Object): Optimize the default
1110 initialization of an array of scalars.
1111 (Get_Simple_Init_Val): Add processing for array types. Remove the
1112 processing of strings because this case is already handled by the array
1113 case.
1114 (Needs_Simple_Initialization): Moved to Sem_Util.
1115 (Simple_Init_Array_Type): New routine.
1116 (Simple_Init_Initialize_Scalars_Type): Reimplemented to use the new
1117 facilities from Sem_Util.
1118 (Simple_Initialization_OK): New routine.
1119 * exp_ch3.ads (Needs_Simple_Initialization): Moved to Sem_Util.
1120 * exp_ch4.adb (Expand_N_Allocator): Optimize the default allocation of
1121 an array of scalars.
1122 * sem_prag.adb (Analyze_Float_Value): New routine.
1123 (Analyze_Integer_Value): New routine.
1124 (Analyze_Pragma): Reimplement the analysis of pragma Initialize_Scalars
1125 to handled the extended form of the pragma.
1126 (Analyze_Type_Value_Pair): New routine.
1127 * sem_util.adb: Add invalid value-related data structures.
1128 (Examine_Array_Bounds): New routine.
1129 (Has_Static_Array_Bounds): Reimplemented.
1130 (Has_Static_Non_Empty_Array_Bounds): New routine.
1131 (Invalid_Scalar_Value): New routine.
1132 (Needs_Simple_Initialization): Moved from Exp_Ch3.
1133 (Set_Invalid_Scalar_Value): New routines.
1134 * sem_util.ads (Has_Static_Non_Empty_Array_Bounds): New routine.
1135 (Invalid_Scalar_Value): New routine.
1136 (Needs_Simple_Initialization): Moved from Exp_Ch3.
1137 (Set_Invalid_Scalar_Value): New routines.
1138 * snames.ads-tmpl: Add names for the salar type families used by pragma
1139 Initialize_Scalars.
1140
1141 2018-05-22 Javier Miranda <miranda@adacore.com>
1142
1143 * exp_disp.adb (Make_DT): Initialize the External_Tag with an empty
1144 string when pragma No_Tagged_Streams is applicable to the tagged type,
1145 and initialize the Expanded_Name with an empty string when pragma
1146 Discard_Names is applicable to the tagged type.
1147
1148 2018-05-22 Ed Schonberg <schonberg@adacore.com>
1149
1150 * sem_ch6.adb (Check_Conformance): Add RM reference for rule that a
1151 formal subprogram is never subtype conformqnt, and thus cannot be the
1152 prefix of 'Access. Reject as well the attribute when applied to a
1153 renaming of a formal subprogram.
1154
1155 2018-05-22 Hristian Kirtchev <kirtchev@adacore.com>
1156
1157 * exp_ch3.adb (Build_Array_Init_Proc): Update the call to
1158 Needs_Simple_Initialization.
1159 (Build_Init_Statements): Update the call to Get_Simple_Init_Val.
1160 (Check_Subtype_Bounds): Renamed to Extract_Subtype_Bounds. Update the
1161 profile and comment on usage.
1162 (Default_Initialize_Object): Do not use New_Copy_Tree to set the proper
1163 Sloc of a value obtained from aspect Default_Value because this could
1164 potentially replicate large trees. The proper Sloc is now set in
1165 Get_Simple_Init_Val.
1166 (Get_Simple_Init_Val): Reorganized by breaking the various cases into
1167 separate routines. Eliminate the use of global variables.
1168 (Init_Component): Update the call to Get_Simple_Init_Val.
1169 (Needs_Simple_Initialization): Update the parameter profile and all
1170 uses of T.
1171 (Simple_Init_Defaulted_Type): Copy the value of aspect Default_Value
1172 and set the proper Sloc.
1173 * exp_ch3.ads (Get_Simple_Init_Val): Update the parameter profile and
1174 comment on usage.
1175 (Needs_Simple_Initialization): Update the parameter profile.
1176
1177 2018-05-22 Patrick Bernardi <bernardi@adacore.com>
1178
1179 * sem_ch3.adb (Build_Discriminant_Constraints): Raise an error if the
1180 user tries to use a subtype indication as a discriminant constraint.
1181
1182 2018-05-22 Ed Schonberg <schonberg@adacore.com>
1183
1184 * exp_ch4.ads, exp_ch4.adb, exp_util.adb, expander.adb: Remove mention
1185 of N_Reduction_Expression and N_Reduction_Expression_Parameter.
1186 * par-ch4.adb: Remove parsing routines for reduction expressions.
1187 * sem.adb, sinfo.ads, sinfo.adb, sem_ch4.ads, sem_ch4.adb, sem_res.adb,
1188 sem_spark.adb, sprint.adb: Remove analysis routines for reduction
1189 expressions.
1190
1191 2018-05-22 Arnaud Charlet <charlet@adacore.com>
1192
1193 * sem_ch8.adb (Check_Frozen_Renaming): Do not emit error in
1194 Relaxed_RM_Semantics mode.
1195
1196 2018-05-22 Arnaud Charlet <charlet@adacore.com>
1197
1198 * comperr.adb (Delete_SCIL_Files): Take into account
1199 N_Generic_Package_Renaming_Declaration.
1200
1201 2018-05-22 Ed Schonberg <schonberg@adacore.com>
1202
1203 * sem_ch3.adb (Search_Derivation_Levels): Whenever a parent type is
1204 private, use the full view if available, because it may include renamed
1205 discriminants whose values are stored in the corresponding
1206 Stored_Constraint.
1207
1208 2018-05-22 Ed Schonberg <schonberg@adacore.com>
1209
1210 * einfo.ads, einfo.adb: New attribute Hidden_In_Formal_Instance,
1211 defined on packages that are actuals for formal packages, in order to
1212 set/reset the visibility of the formals of a formal package with given
1213 actuals, when there are subsequent uses of those formals in the
1214 enclosing generic, as required by RN 12.7 (10).
1215 * atree.ads, atree.adb: Add operations for Elist30.
1216 * atree.h: Add Elist30.
1217 * sem_ch12.adb (Analyze_Formal_Package_Instantiation): Collect formals
1218 that are not defaulted and are thus not visible within the current
1219 instance.
1220 (Check_Formal_Packages): Reset visibility of formals of a formal
1221 package that are not defaulted, on exit from current instance.
1222
1223 2018-05-22 Hristian Kirtchev <kirtchev@adacore.com>
1224
1225 * sem_prag.adb (Analyze_Input_Output): Emit an error when a non-null,
1226 non-'Result output appears in the output list of a function.
1227
1228 2018-05-22 Hristian Kirtchev <kirtchev@adacore.com>
1229
1230 * exp_attr.adb (Build_Array_VS_Func): Reimplemented.
1231 (Build_Record_VS_Func): Reimplemented.
1232 (Expand_N_Attribute): Reimplement the handling of attribute
1233 'Valid_Scalars.
1234 * sem_attr.adb (Analyze_Attribute): Reimplement the handling of
1235 attribute 'Valid_Scalars.
1236 * sem_util.adb (Scalar_Part_Present): Reimplemented.
1237 (Validated_View): New routine.
1238 * sem_util.ads (Scalar_Part_Present): Update the parameter profile and
1239 comment on usage.
1240 (Validated_View): New routine.
1241 * doc/gnat_rm/implementation_defined_attributes.rst: Update the
1242 documentation of attribute 'Valid_Scalars.
1243 * gnat_rm.texi: Regenerate.
1244
1245 2018-05-22 Bob Duff <duff@adacore.com>
1246
1247 * binde.adb: (Choose): Ignore a pragma Elaborate_Body that appears in
1248 the spec of a SAL_Interface package.
1249
1250 2018-05-22 Ed Schonberg <schonberg@adacore.com>
1251
1252 * freeze.adb (Freeze_Entity): When analyzing delayed aspects of an
1253 entity E within a generic unit, indicate that there are no remaining
1254 delayed aspects after invoking Analyze_Aspects_At_Freeze_Point. The
1255 entity E is not frozen yet but the aspects should not be reanalyzed at
1256 the freeze point, which may be outside of the generic and may not have
1257 the proper visibility.
1258
1259 2018-05-22 Bob Duff <duff@adacore.com>
1260
1261 * doc/gnat_ugn/gnat_utility_programs.rst: Add documentation for
1262 the new --split-line-before-record, --indent-named-statements and
1263 --no-align-modes gnatpp switches.
1264
1265 2018-05-22 Ed Schonberg <schonberg@adacore.com>
1266
1267 * sem_prag.adb (Process_Compile_Time_Warning_Or_Error): Handle properly
1268 a second argument that is a constant of a given string value.
1269
1270 2018-05-22 Doug Rupp <rupp@adacore.com>
1271
1272 * sigtramp-vxworks-target.inc: Align stack to 128bits on AArch64.
1273
1274 2018-05-22 Jerome Lambourg <lambourg@adacore.com>
1275
1276 * sigtramp-qnx.c: Fix stack alignment issue in the signal trampoline.
1277
1278 2018-05-22 Ed Schonberg <schonberg@adacore.com>
1279
1280 * freeze.adb (Freeze_Fixed_Point_Type): If the first subtype has
1281 delayed aspects, analyze them now, os that the representation of the
1282 type (size, bounds) can be computed and validated.
1283
1284 2018-05-22 Olivier Hainque <hainque@adacore.com>
1285
1286 * libgnat/s-dwalin.adb (Enable_Cache): Skip symbols outside of the
1287 executable code section boundaries.
1288
1289 2018-05-22 Javier Miranda <miranda@adacore.com>
1290
1291 * locales.c: New implementation for the Ada.Locales package.
1292 * libgnat/a-locale.ads: Remove comment indicating that this is not
1293 implemented.
1294 * doc/gnat_rm/standard_library_routines.rst: Remove comment indicating
1295 that this is not implemented.
1296 * gnat_rm.texi: Regenerate.
1297
1298 2018-05-22 Hristian Kirtchev <kirtchev@adacore.com>
1299
1300 * exp_ch5.adb, freeze.adb, pprint.adb, sem_ch4.adb, sem_res.adb: Minor
1301 reformattings.
1302
1303 2018-05-22 Justin Squirek <squirek@adacore.com>
1304
1305 * sem_ch12.adb (In_Same_Declarative_Part): Moved to sem_util.
1306 (Freeze_Subprogram_Body, Install_Body): Modify calls to
1307 In_Same_Declarative_Part.
1308 * sem_prag.adb (Analyze_Pragma-Pragma_Pure_Function): Add check to
1309 verify pragma declaration is within the same declarative list with
1310 corresponding error message.
1311 * sem_util.adb, sem_util.ads (In_Same_Declarative_Part): Moved from
1312 sem_ch12.adb and generalized to be useful outside the scope of
1313 freezing.
1314
1315 2018-05-22 Hristian Kirtchev <kirtchev@adacore.com>
1316
1317 * sem_ch6.adb (Analyze_Subprogram_Declaration): Set the proper
1318 categorization of the unit after processing the aspects in case one of
1319 its aspects is converted into a categorization pragma.
1320
1321 2018-05-21 Ed Schonberg <schonberg@adacore.com>
1322
1323 * freeze.adb (Warn_Overlay): Do not emit a wawrning on an object
1324 declaration with an explicit address clause and a type with default
1325 initialization, if the declaration carries an aspect
1326 Suppress_Initialization.
1327
1328 2018-05-21 Daniel Mercier <mercier@adacore.com>
1329
1330 * pprint.adb: Use mixed case for attribute names.
1331
1332 2018-05-21 Hristian Kirtchev <kirtchev@adacore.com>
1333
1334 * sem_ch6.adb (Analyze_Generic_Subprogram_Body): Rename the call to
1335 Analyze_Aspect_Specifications_On_Body_Or_Stub.
1336 (Analyze_Subprogram_Body_Helper): Rename the calls to
1337 Analyze_Aspect_Specifications_On_Body_Or_Stub.
1338 * sem_ch9.adb (Analyze_Entry_Body): Rename the call to
1339 Analyze_Aspect_Specifications_On_Body_Or_Stub.
1340 * sem_ch10.adb: Add with and use clause for Sem_Ch13.
1341 (Analyze_Package_Body_Stub): Add constant Id. Decorate the package stub
1342 prior to analyzing its aspects.
1343 (Analyze_Protected_Body_Stub): Add constant Id. Decorate the package
1344 stub prior to analyzing its aspects. Save and restore the configuration
1345 switches.
1346 (Analyze_Task_Body_Stub): Add constant Id. Decorate the package stub
1347 prior to analyzing its aspects.
1348 * sem_ch13.adb (Analyze_Aspect_Specifications_On_Body_Or_Stub): Renamed
1349 to Analyze_Aspects_On_Subprogram_Body_Or_Stub.
1350 * sem_ch13.ads (Analyze_Aspect_Specifications_On_Body_Or_Stub): Renamed
1351 to Analyze_Aspects_On_Subprogram_Body_Or_Stub.
1352 * sem_prag.adb: Code reformatting.
1353 (Analyze_Refined_Depends_Global_Post): Consider task body stubs.
1354
1355 2018-05-21 Jerome Lambourg <lambourg@adacore.com>
1356
1357 * gcc-interface/Makefile.in: Add g-soliop__qnx.ads to the runtime build
1358 for QNX.
1359
1360 2018-05-21 Hristian Kirtchev <kirtchev@adacore.com>
1361
1362 * exp_cg.adb: Remove with and use clause for Exp_Disp.
1363 * exp_ch9.adb: Remove with and use clause for Exp_Disp.
1364 * exp_disp.adb (Is_Predefined_Dispatching_Operation): Moved to Sem_Util.
1365 (Is_Predefined_Interface_Primitive): Moved to Sem_Util.
1366 (Is_Predefined_Internal_Operation): Moved to Sem_Util.
1367 * exp_disp.ads (Is_Predefined_Dispatching_Operation): Moved to Sem_Util.
1368 (Is_Predefined_Interface_Primitive): Moved to Sem_Util.
1369 (Is_Predefined_Internal_Operation): Moved to Sem_Util.
1370 * exp_dist.adb: Remove with and use clause for Exp_Disp.
1371 * freeze.adb: Remove with and use clause for Exp_Disp.
1372 * sem_cat.adb: Remove with and use clause for Exp_Disp.
1373 * sem_ch6.adb: Remove with and use clause for Exp_Disp.
1374 * sem_ch12.adb: Remove with and use clause for Exp_Disp.
1375 * sem_elab.adb (Check_Overriding_Primitive): Do not process predefined
1376 primitives.
1377 * sem_util.adb: Remove with and use clause for Exp_Disp.
1378 (Is_Predefined_Dispatching_Operation): Moved from Exp_Disp.
1379 (Is_Predefined_Interface_Primitive): Moved from Exp_Disp.
1380 (Is_Predefined_Internal_Operation): Moved from Exp_Disp.
1381 * sem_util.ads (Is_Predefined_Dispatching_Operation): Moved from
1382 Exp_Disp.
1383 (Is_Predefined_Interface_Primitive): Moved from Exp_Disp.
1384 (Is_Predefined_Internal_Operation): Moved from Exp_Disp.
1385
1386 2018-05-21 Ed Schonberg <schonberg@adacore.com>
1387
1388 * sem_res.adb (Valid_Conversion): Improve error message on an illegal
1389 type conversion whose expression has a limited view of a type.
1390
1391 2018-05-21 Ed Schonberg <schonberg@adacore.com>
1392
1393 * exp_ch5.adb (Build_Formal_Container_Iteration): If source has
1394 explicit name for iterator loop, preserve that name in expanded
1395 construct, for possible use in exit statements.
1396
1397 2018-05-21 Javier Miranda <miranda@adacore.com>
1398
1399 * sem_ch4.adb (Analyze_Membership_Op): Avoid compiler crash when the
1400 spec of a unit has Ada 2012 membership tests with multiple choices and
1401 the unit body is not compiled under Ada 2012 mode.
1402
1403 2018-05-21 Doug Rupp <rupp@adacore.com>
1404
1405 * sigtramp-vxworks-target.inc: Set cfa_reg properly from sigcontext
1406 pregs.
1407 (CFI_COMMON_REGS): Restore LR jic probed from prologue.
1408 (REGNO_PC_OFFSET): Change to correct value for Aarch64.
1409
1410 2018-05-21 Jose Ruiz <ruiz@adacore.com>
1411
1412 * doc/gnat_ugn/gnat_utility_programs.rst, exp_attr.adb,
1413 libgnarl/s-tassta.adb: Minor typo fixes
1414
1415 2018-05-21 Ed Schonberg <schonberg@adacore.com>
1416
1417 * sem_ch4.adb (Analyze_One_Call): Recognize complex cases where an
1418 indexed call originally in prefix forn is itself the prefix of a
1419 further call.
1420
1421 2018-05-21 Piotr Trojanek <trojanek@adacore.com>
1422
1423 * sem_eval.adb (Is_Null_Range): Clarify access to the full view of a
1424 type.
1425 (Not_Null_Range): Same as above.
1426
1427 2018-05-21 Hristian Kirtchev <kirtchev@adacore.com>
1428
1429 * exp_ch3.adb: Minor reformatting.
1430 * exp_ch6.adb: Likewise.
1431 * freeze.adb: Likewise.
1432 * inline.adb: Likewise.
1433 * sem_util.adb: Likewise.
1434
1435 2018-05-21 Yannick Moy <moy@adacore.com>
1436
1437 * inline.adb (Expand_Inlined_Call.Process_Formals): Use a type
1438 conversion instead of an unchecked type conversion when inlining a
1439 return statement, unless type qualification is required (for character
1440 and string literal) or no check can result from the conversion (for
1441 access types).
1442 * opt.ads: Update comment.
1443
1444 2018-05-21 Hristian Kirtchev <kirtchev@adacore.com>
1445
1446 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Install the elaboration
1447 model of the compilation unit spec, if any.
1448 * sem_ch7.adb (Analyze_Package_Body_Helper): Install the elaboration
1449 model of the compilation unit spec, if any.
1450 * sem_ch10.adb (Analyze_Subunit): Install the elaboration model of the
1451 parent compilation unit spec, if any.
1452 * sem_elab.adb (Check_Elaboration_Scenarios): Restore the elaboration
1453 model of the main unit.
1454 (Is_Same_Unit): The routine now uses Unit_Entity.
1455 (Is_Subunit): Removed.
1456 (Normalize_Unit): Removed.
1457 (Unit_Entity): New routine.
1458 * sem_prag.adb (Analyze_Pragma): Reimplement the handling of pragma
1459 Elaboration_Checks. The analysis now ensures that the pragma appears at
1460 the configuration level, and on the initial declaration of a unit.
1461 Other placements are either flagged as illegal, or ignored.
1462 (Check_Duplicate_Elaboration_Checks_Pragma): New routine.
1463 (Ignore_Elaboration_Checks_Pragma): New routine.
1464 * sem_util.adb (Install_Elaboration_Model): New routine.
1465 * sem_util.ads (Install_Elaboration_Model): New routine.
1466 * doc/gnat_rm/implementation_defined_pragmas.rst: Update the
1467 documentation of pragma Elaboration_Checks.
1468 * gnat_rm.texi: Regenerate.
1469
1470 2018-05-21 Olivier Hainque <hainque@adacore.com>
1471
1472 * libgnat/s-trasym__dwarf.adb (Executable_Name): Return argv[0] instead
1473 of empty string when argv[0] couldn't be found on PATH.
1474 (Enable_Cache): Raise Program_Error instead of attempting a null
1475 pointer dereference when the Exec_Module initialization failed.
1476
1477 2018-05-21 Piotr Trojanek <trojanek@adacore.com>
1478
1479 * libgnarl/a-reatim.ads (Clock_Time): Remove External aspect.
1480 * libgnarl/a-taside.ads (Tasking_State): Likewise.
1481 * libgnat/a-calend.ads (Clock_Time): Likewise.
1482
1483 2018-05-21 Yannick Moy <moy@adacore.com>
1484
1485 * sem_ch6.adb (Analyze_Procedure_Call): Refine test to recognize prefix
1486 call notation in inlined call in GNATprove mode.
1487
1488 2018-05-21 Hristian Kirtchev <kirtchev@adacore.com>
1489
1490 * einfo.adb (Is_External_State): An abstract state is also external
1491 when it is declared with option "synchronous".
1492 * einfo.ads: Update the documentation of synthesized attribute
1493 Is_External_State.
1494 * sem_util.adb (Find_Simple_Properties): New routine.
1495 (Is_Enabled_External_Property): New routine.
1496 (State_Has_Enabled_Property): Reimplemented. The two flavors of option
1497 External have precedence over option Synchronous when determining
1498 whether a property is in effect.
1499
1500 2018-05-21 Yannick Moy <moy@adacore.com>
1501
1502 * sem_eval.adb (Static_Length): Take into account case of variable of
1503 subtype string literal.
1504
1505 2018-05-21 Olivier Hainque <hainque@adacore.com>
1506
1507 * libgnat/s-objrea.ads (Get_Memory_Bounds): Rename as Get_Xcode_Bounds.
1508 (Object_Section): Rename Flag_Alloc component as Flag_Xcode.
1509 * libgnat/s-objrea.adb (Get_Xcode_Bounds): Adjust to new subprogram and
1510 component name.
1511 (Get_Section, ELF case): Set Flag_Xcode from SHF_EXECINSTR.
1512 * libgnat/s-dwalin.adb (Open): Adjust to the Get_Memory_Bounds name
1513 change.
1514
1515 2018-05-21 Olivier Hainque <hainque@adacore.com>
1516
1517 * libgnat/s-dwalin.ads (Dwarf_Context): Change type of Load_Address to
1518 Address, and type of Low, High to Storage_Offset.
1519 (Low): Rename as Low_Address and convey that the return value is a
1520 runtime reference accounting for a load address.
1521 * libgnat/s-dwalin.adb (Read_Aranges_Entry): Adjust to the
1522 address/offset type changes.
1523 (Aranges_Lookup): Likewise.
1524 (Symbolic_Address): Likewise.
1525 (Symbolic_Traceback): Likewise.
1526 (Dump_Cache): Likewise.
1527 (Is_Inside): Likewise.
1528 (Open): Likewise.
1529 (Set_Load_Address): Likewise.
1530 (Low_Address): Likewise, and account for C.Load_Address.
1531 * libgnat/s-trasym__dwarf.adb (Lt): Use Low_Address instead of Low.
1532 (Multi_Module_Symbolic_Traceback): Compare address in traceback
1533 with module Low_Address instead of Low.
1534
1535 2018-05-21 Olivier Hainque <hainque@adacore.com>
1536
1537 * libgnat/s-dwalin.ads (Dwarf_Context): Rename Load_Slide as
1538 Load_Address.
1539 * libgnat/s-dwalin.adb (Is_Inside): Adjust accordingly.
1540 (Set_Load_Address): Likewise.
1541 (Symbolic_Traceback): Likewise.
1542
1543 2018-05-21 Olivier Hainque <hainque@adacore.com>
1544
1545 * libgnat/s-trasym__dwarf.adb (Add_Module_To_Cache): Expect a
1546 Load_Address argument and pass it down to Init_Module.
1547 * libgnat/s-tsmona__linux.adb (Build_Cache_For_All_Modules): Pass
1548 lm.l_addr as the Load_Address to Add_Module_To_Cache.
1549
1550 2018-05-21 Piotr Trojanek <trojanek@adacore.com>
1551
1552 * einfo.adb (Has_Discriminants): Stronger assertion.
1553 (Set_Has_Discriminants): Stronger assertion.
1554 * sem_ch13.adb (Push_Scope_And_Install_Discriminants): Adapt to respect
1555 the stronger assertion on Has_Discriminant.
1556 (Uninstall_Discriminants_And_Pop_Scope): Same as above.
1557 * sem_util.adb (New_Copy_Tree): Same as above.
1558 * sem_ch7.adb (Generate_Parent_References): Prevent calls to
1559 Has_Discriminant on non-type entities that might happen when the
1560 compiled code has errors.
1561 * sem_ch3.adb (Derived_Type_Declaration): Only call
1562 Set_Has_Discriminant on type entities.
1563
1564 2018-05-21 Arnaud Charlet <charlet@adacore.com>
1565
1566 * exp_unst.adb (Unnest_Subprogram): Unnest all subprograms relevant for
1567 code generation.
1568
1569 2018-05-21 Piotr Trojanek <trojanek@adacore.com>
1570
1571 * lib.ads: Fix typo in enumeration in comment.
1572
1573 2018-05-21 Ed Schonberg <schonberg@adacore.com>
1574
1575 * sem_attr.adb (Analyze_Attribute, case Scalar_Storage_Order): The
1576 attribute reference is legal within a generic unit when the prefix is a
1577 formal private type.
1578
1579 2018-05-21 Hristian Kirtchev <kirtchev@adacore.com>
1580
1581 * exp_ch7.adb (Establish_Transient_Scope): Code cleanup. Do not
1582 delegate the secondary stack management when there is no suitable
1583 transient context, and the transient scope was intended to manage the
1584 secondary stack because this causes premature reclamation. Change the
1585 transient scope creation logic by special casing assignment statements
1586 of controlled components for type initialization procedures.
1587 (Find_Node_To_Be_Wrapped): Renamed to Find_Transient_Context. Update
1588 the comment on usage.
1589 (Find_Transient_Context): Change the initinte loop into a while loop.
1590 Iterations schemes and iterator specifications are not valid transient
1591 contexts because they rely on special processing. Assignment statements
1592 are now treated as a normal transient context, special cases are
1593 handled by the caller. Add special processing for pragma Check.
1594 (Is_OK_Construct): Removed. Its functionality has been merged in
1595 routine Find_Transient_Context.
1596 * sem_ch5.adb (Check_Call): Reimplemented. Add code to properly
1597 retrieve the subprogram being invoked. Use a more accurate predicate
1598 (Requires_Transient_Scope) to determine that the function will emply
1599 the secondary stack.
1600
1601 2018-05-21 Piotr Trojanek <trojanek@adacore.com>
1602
1603 * ada_get_targ.adb: Fix subprogram body headers.
1604 * adabkend.adb: Likewise.
1605 * checks.adb: Likewise.
1606 * exp_ch3.adb: Likewise.
1607 * exp_ch5.adb: Likewise.
1608 * exp_ch9.adb: Likewise.
1609 * exp_dist.adb: Likewise.
1610 * exp_tss.adb: Likewise.
1611 * inline.adb: Likewise.
1612 * lib-writ.adb: Likewise.
1613 * lib-xref-spark_specific.adb: Likewise.
1614 * libgnarl/s-osinte__darwin.adb: Likewise.
1615 * libgnarl/s-stusta.adb: Likewise.
1616 * libgnarl/s-taprop__solaris.adb: Likewise.
1617 * libgnarl/s-tposen.adb: Likewise.
1618 * libgnarl/s-vxwext__kernel-smp.adb: Likewise.
1619 * libgnarl/s-vxwext__kernel.adb: Likewise.
1620 * libgnat/a-btgbso.adb: Likewise.
1621 * libgnat/a-cfdlli.adb: Likewise.
1622 * libgnat/a-cfhama.adb: Likewise.
1623 * libgnat/a-cfinve.adb: Likewise.
1624 * libgnat/a-cimutr.adb: Likewise.
1625 * libgnat/a-coboho.adb: Likewise.
1626 * libgnat/a-cofove.adb: Likewise.
1627 * libgnat/a-cofuve.adb: Likewise.
1628 * libgnat/a-comutr.adb: Likewise.
1629 * libgnat/a-exexda.adb: Likewise.
1630 * libgnat/a-tags.adb: Likewise.
1631 * libgnat/a-tideau.adb: Likewise.
1632 * libgnat/a-wtdeau.adb: Likewise.
1633 * libgnat/a-ztdeau.adb: Likewise.
1634 * libgnat/g-alleve.adb: Likewise.
1635 * libgnat/s-excdeb.adb: Likewise.
1636 * libgnat/s-parint.adb: Likewise.
1637 * libgnat/s-shasto.adb: Likewise.
1638 * libgnat/s-traceb__hpux.adb: Likewise.
1639 * prepcomp.adb: Likewise.
1640 * sem_ch4.adb: Likewise.
1641 * sem_ch6.adb: Likewise.
1642 * sem_dist.adb: Likewise.
1643 * sem_prag.adb: Likewise.
1644 * sem_util.adb: Likewise.
1645 * sinfo.adb: Likewise.
1646 * switch.adb: Likewise.
1647
1648 2018-05-04 John Marino <gnugcc@marino.st>
1649
1650 PR ada/85635
1651 * link.c (BSD platforms): Add missing backslash.
1652
1653 2018-04-27 Eric Botcazou <ebotcazou@adacore.com>
1654
1655 PR ada/85540
1656 * init.c (__gnat_handle_vms_condition): Add missing parentheses.
1657
1658 2018-04-25 Eric Botcazou <ebotcazou@adacore.com>
1659
1660 PR ada/85007
1661 * gnat_ugn.texi: Regenerate.
1662
1663 2018-03-23 Eric Botcazou <ebotcazou@adacore.com>
1664
1665 PR ada/85007
1666 * gnatlink.adb (Gnatlink): Remove handling of -b switch.
1667 * doc/gnat_ugn/building_executable_programs_with_gnat.rst (gnatlink):
1668 Remove documentation of -b switch.
1669
1670 2018-03-23 Eric Botcazou <ebotcazou@adacore.com>
1671
1672 PR ada/85036
1673 * gnatlink.adb (Process_Args): Drop existing link switches if multiple
1674 switches are passed for --LINK.
1675
1676 2018-03-12 Eric Botcazou <ebotcazou@adacore.com>
1677
1678 PR ada/82813
1679 * gcc-interface/misc.c (gnat_post_options): Disable string overflow
1680 warnings.
1681
1682 2018-03-10 Eric Botcazou <ebotcazou@adacore.com>
1683
1684 * gcc-interface/trans.c (node_has_volatile_full_access) <N_Identifier>:
1685 Consider only entities for objects.
1686
1687 2018-03-07 Sebastian Huber <sebastian.huber@embedded-brains.de>
1688
1689 * gcc-interface/Makefile.in (OSCONS_CPP): Remove redundant
1690 $(GNATLIBCFLAGS).
1691 (OSCONS_EXTRACT): Add $(GNATLIBCFLAGS_FOR_C).
1692
1693 2018-03-06 Eric Botcazou <ebotcazou@adacore.com>
1694
1695 * gcc-interface/trans.c (convert_with_check): Fix typo in the condition
1696 guarding the overflow check emitted for the upper bound of a floating-
1697 point conversion.
1698
1699 2018-03-06 Eric Botcazou <ebotcazou@adacore.com>
1700
1701 * gcc-interface/utils.c (def_builtin_1): Bail out on error_mark_node.
1702
1703 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
1704
1705 * libgnat/i-cexten.ads (Float_128): New type.
1706
1707 2018-02-02 Eric Botcazou <ebotcazou@adacore.com>
1708
1709 * gcc-interface/decl.c (array_type_has_nonaliased_component): Return
1710 false if the component type is a pointer.
1711
1712 2018-01-11 Gary Dismukes <dismukes@adacore.com>
1713
1714 * exp_ch3.adb (Default_Initialize_Object): Call New_Copy_Tree on the
1715 result of Get_Simple_Init_Value and pass the source location of the
1716 object declaration's object_definition.
1717
1718 2018-01-11 Ed Schonberg <schonberg@adacore.com>
1719
1720 * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration): Handle
1721 properly object declarations with initializations that are
1722 build-in-place function calls, when there is an address specification,
1723 either as an aspect specification or an explicit attribute
1724 specification clause, for the initialized object.
1725 * freeze.adb (Check_Address_Clause): Do not remove side-effects from
1726 initial expressions in the case of a build-in-place call.
1727
1728 2018-01-11 Piotr Trojanek <trojanek@adacore.com>
1729
1730 * sem_eval.adb (Is_Null_Range): Retrieve the full view when called on a
1731 private (sub)type; refactor to avoid early return statement.
1732 (Not_Null_Range): Same as above.
1733
1734 2018-01-11 Hristian Kirtchev <kirtchev@adacore.com>
1735
1736 * freeze.adb (Freeze_Entity): Ensure that a Ghost type is not
1737 concurrent, nor effectively volatile.
1738 * ghost.adb (Check_Ghost_Type): New routine.
1739 * ghost.ads (Check_Ghost_Type): New routine.
1740 * sem_util.adb (Is_Declaration): Reimplemented. The routine can now
1741 consider specific subsets of declarations.
1742 (Is_Declaration_Other_Than_Renaming): Removed. Its functionality is
1743 replicated by Is_Declaration.
1744 * sem_util.ads (Is_Declaration): New parameter profile. Update the
1745 comment on usage.
1746 (Is_Declaration_Other_Than_Renaming): Removed.
1747
1748 2018-01-11 Hristian Kirtchev <kirtchev@adacore.com>
1749
1750 * sem_ch5.adb (Analyze_Assignment): Assignments to variables that act
1751 as Part_Of consituents of single protected types are illegal when they
1752 take place inside a protected function.
1753 (Diagnose_Non_Variable_Lhs): Use Within_Function to check for an
1754 enclosing function.
1755 (Is_Protected_Part_Of_Constituent): New routine.
1756 (Within_Function): New routine.
1757
1758 2018-01-11 Arnaud Charlet <charlet@adacore.com>
1759
1760 Bump copyright notices to 2018.
1761
1762 2018-01-11 Hristian Kirtchev <kirtchev@adacore.com>
1763
1764 * binde.adb, par-ch6.adb, par-ch9.adb, sem_ch12.adb, sem_ch13.adb:
1765 Minor reformatting.
1766
1767 2018-01-11 Justin Squirek <squirek@adacore.com>
1768
1769 * par-ch6.adb (Scan_Body_Or_Expression_Function): Add additional check
1770 to make sure a given expression function is properly parenthesized.
1771
1772 2018-01-11 Hristian Kirtchev <kirtchev@adacore.com>
1773
1774 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Check the
1775 categorization of a subprogram body which does not complete a previous
1776 declaration.
1777
1778 2018-01-11 Hristian Kirtchev <kirtchev@adacore.com>
1779
1780 * sem_ch10.adb (Check_Private_Child_Unit): Ensure that the enclosing
1781 scope of package Ada is Standard.
1782
1783 2018-01-11 Ed Schonberg <schonberg@adacore.com>
1784
1785 * sem_ch13.adb (Replace_Type_Ref): Handle properly reference to a
1786 subcomponent of the current entity when building the body for a dynamic
1787 predicate function for a record with composite subcomponents.
1788
1789 2018-01-11 Hristian Kirtchev <kirtchev@adacore.com>
1790
1791 * exp_aggr.adb (Convert_Aggr_In_Object_Decl): Update the call to
1792 Establish_Transient_Scope.
1793 (Convert_To_Assignments): Update the call to Establish_Transient_Scope.
1794 (Expand_Array_Aggregate): Update the call to Establish_Transient_Scope.
1795 * exp_ch6.adb (Expand_Call_Helper): Update the call to
1796 Establish_Transient_Scope.
1797 (Make_Build_In_Place_Call_In_Object_Declaration): Update the call to
1798 Establish_Transient_Scope.
1799 * exp_ch7.adb (Establish_Transient_Scope): Restructured. Delegate the
1800 management of the secondary stack to an enclosing scope if there is no
1801 suitable construct to wrap, and the transient scope was intended to
1802 manage the secondary stack.
1803 (Find_Node_To_Be_Wrapped): Restructured. A case_statement_alternative
1804 is a valid boundary for a transient expression which comes from the
1805 statements of the alternative, otherwise alternatives cannot be
1806 wrapped. Assignments of controlled objects which have controlled
1807 actions suppressed now stop the traversal as there is no point in
1808 looking for an enclosing construct. Add several N_xxx_Body choices to
1809 the termination conditions for completeness.
1810 * exp_ch7.ads (Establish_Transient_Scope): Update the parameter profile
1811 and the associated comment on usage.
1812 * exp_smem.adb (Add_Shared_Var_Lock_Procs): Update the call to
1813 Establish_Transient_Scope.
1814 (Add_Write_After): Update the call to Establish_Transient_Scope.
1815 * sem_res.adb (Check_Initialization_Call): Removed.
1816 (Resolve_Actuals): Account for additional cases where finalization
1817 actions are required by utilizing predicate Needs_Finalization rather
1818 than Is_Controlled.
1819 (Resolve_Call): Type initialization procedures can now utilize
1820 transient scopes to manage the secondary stack, thus preventing leaks
1821 during initialization. Remove the previous kludgy algorithm which
1822 attempts to manage the secondary stack at the object creation site.
1823
1824 2018-01-11 Jerome Lambourg <lambourg@adacore.com>
1825
1826 * libgnat/g-soliop__qnx.ads: New.
1827 * adaint.c, adaint.h, cstreams.c, s-oscons-tmplt.c, sysdep.c: Update
1828 for QNX.
1829
1830 2018-01-11 Bob Duff <duff@adacore.com>
1831
1832 * par-ch9.adb (P_Protected_Operation_Declaration_Opt): Give an error if
1833 a null procedure occurs in a protected definition.
1834
1835 2018-01-11 Bob Duff <duff@adacore.com>
1836
1837 * binderr.ads, namet.ads: Minor reformatting.
1838
1839 2018-01-11 Bob Duff <duff@adacore.com>
1840
1841 * doc/gnat_ugn/gnat_utility_programs.rst: Improve documentation of
1842 xml2gnat.
1843
1844 2018-01-11 Bob Duff <duff@adacore.com>
1845
1846 * binde.adb (Force_Elab_Order): Give an error if there are duplicate
1847 unit names.
1848
1849 2018-01-11 Ed Schonberg <schonberg@adacore.com>
1850
1851 * sem_ch6.adb (Freeze_Expr_Types): If an access value is the
1852 controlling argument of a dispatching call. freeze the corresponding
1853 designated type.
1854
1855 2018-01-11 Ben Brosgol <brosgol@adacore.com>
1856
1857 * doc/Makefile: Add Sphinx option -W to treat warnings as errors.
1858
1859 2018-01-11 Ben Brosgol <brosgol@adacore.com>
1860
1861 * doc/gnat_rm/implementation_defined_aspects.rst: Minor type/wording
1862 corrections.
1863 * gnat_rm.texi: Regenerate.
1864
1865 2018-01-11 Ed Schonberg <schonberg@adacore.com>
1866
1867 * sem_ch12.adb (Check_Fixed_Point_Type): Do not apply check if the
1868 formsl type corresponding to the actual fixed point type is private,
1869 because in this case there can be no suspicious arithmetic operations
1870 in the generic unless they reference a formal subprogram. Clarify
1871 warning.
1872
1873 2018-01-11 Javier Miranda <miranda@adacore.com>
1874
1875 * exp_util.adb (Remove_Side_Effects): No action done for functions
1876 returning class-wide types since it requires generating code using
1877 'reference and the CCG target has no secondary stack.
1878 * gnat1drv.adb: Disable building static dispatch tables when generating
1879 C code.
1880
1881 2018-01-11 Piotr Trojanek <trojanek@adacore.com>
1882
1883 * libgnat/a-direio.ads, libgnat/a-sequio.ads, libgnat/a-ststio.ads,
1884 libgnat/a-textio.ads, libgnat/a-witeio.ads, libgnat/a-ztexio.ads
1885 (File_Type): Add Default_Initial_Condition aspect.
1886
1887 2018-01-11 Pascal Obry <obry@adacore.com>
1888
1889 * libgnat/s-os_lib.adb (Normalize_Pathname): New implementation.
1890
1891 2018-01-11 Bob Duff <duff@adacore.com>
1892
1893 * doc/gnat_ugn/gnat_utility_programs.rst: Rewrite gnatpp documentation
1894 to match what the Libadalang-based version does.
1895 * doc/gnat_ugn/about_this_guide.rst: Update reference.
1896
1897 2018-01-11 Hristian Kirtchev <kirtchev@adacore.com>
1898
1899 * sem_res.adb (Uses_SS): A controlled type requires the secondary stack
1900 if it contains at least one component declaration employing a function
1901 call returning on the secondary stack.
1902
1903 2018-01-11 Yannick Moy <moy@adacore.com>
1904
1905 * doc/gnat_rm/standard_and_implementation_defined_restrictions.rst:
1906 Update description of restriction SPARK_05 with SPARK 2014.
1907 * gnat_rm.texi: Regenerate.
1908
1909 2018-01-11 Vasiliy Fofanov <fofanov@adacore.com>
1910
1911 * doc/gnat_ugn/gnat_utility_programs.rst: Fix layout.
1912
1913 2018-01-11 Hristian Kirtchev <kirtchev@adacore.com>
1914
1915 * exp_aggr.adb, exp_ch9.adb, exp_util.adb, sem_aggr.adb, sem_ch3.adb,
1916 sem_res.adb, sem_util.adb: Minor reformatting.
1917
1918 2018-01-11 Ed Schonberg <schonberg@adacore.com>
1919
1920 * sem_prag.adb (Analyze_Pragma, case Predicate): Indicate that the type
1921 has a delayed aspect which must be processed at the point the type is
1922 frozen. This mimics what is done when the predicate is provided by a
1923 source aspect.
1924
1925 2018-01-11 Doug Rupp <rupp@adacore.com>
1926
1927 * init.c (vxworks): Add macro checks for __aarch64__.
1928
1929 2018-01-11 Hristian Kirtchev <kirtchev@adacore.com>
1930
1931 * exp_util.adb (Add_Failure_Expression): New routine.
1932 (Make_Predicate_Check): Reimplement the handling of Predicate_Failure.
1933 * sem_util.adb (Is_Current_Instance): Code cleanup.
1934
1935 2018-01-11 Patrick Bernardi <bernardi@adacore.com>
1936
1937 * libgnat/s-parame*.adb, libgnat/s-parame*.ads: Remove unneeded
1938 Default_Sec_Stack_Size.
1939 * libgnat/s-secsta.adb (SS_Allocate): Handle the fixed secondary stack
1940 limit check so that the integer index does not overflow. Check the
1941 dynamic stack allocation does not cause the secondary stack pointer to
1942 overflow.
1943 (SS_Info): Align colons.
1944 (SS_Init): Cover the case when bootstraping with an old compiler that
1945 does not set Default_SS_Size.
1946
1947 2018-01-11 Ed Schonberg <schonberg@adacore.com>
1948
1949 * sem_ch3.adb (Add_Internal_Interface_Entities): When checking the
1950 legality of an inherited operation that may require overriding, ignore
1951 primitive_wrappers that correspond to explicit operations that override
1952 an interface primitive.
1953 * exp_util.adb (Build_Class_Wide_Expression, Replace_Entity): If the
1954 operation to which the class-wide expression applies is a protected op.
1955 with a primitive_wrapper, verify that the updated inherited expression
1956 does not contain an internal call to a protected function. This
1957 completes the implementation of AI12-0166.
1958
1959 2018-01-11 Hristian Kirtchev <kirtchev@adacore.com>
1960
1961 * ali.adb: Document the remaining letters available for ALI lines.
1962 (Scan_ALI): A with clause is internal when it is encoded on a 'Z' line.
1963 * ali.ads: Update type With_Record. Field
1964 Implicit_With_From_Instantiation is no longer in use. Add field
1965 Implicit_With.
1966 * csinfo.adb (CSinfo): Remove the setup for attribute
1967 Implicit_With_From_Instantiation.
1968 * lib-writ.adb (Collect_Withs): Correct the logic which marks a unit as
1969 either implicitly or explicitly withed.
1970 (Is_Implicit_With_Clause): New routine.
1971 (Write_ALI): Rename array Implicit_With to Has_Implicit_With to avoid
1972 confusion with the with clause attribute by the same name.
1973 (Write_With_Lines): Update the emission of 'W', 'Y', and 'Z' headers.
1974 * rtsfind.adb (Maybe_Add_With): Code cleanup.
1975 * sem_ch8.adb (Present_System_Aux): Code cleanup.
1976 * sem_ch10.adb (Expand_With_Clause): Mark the with clause as generated
1977 for a parent unit.
1978 (Implicit_With_On_Parent): Mark the with clause as generated for a
1979 parent unit.
1980 * sem_ch12.adb (Inherit_Context): With clauses inherited by an
1981 instantiation are no longer marked as Implicit_With_From_Instantiation
1982 because they are already marked as implicit.
1983 * sem_elab.adb (Ensure_Prior_Elaboration_Static): Remove the kludge
1984 which marks implicit with clauses as related to an instantiation.
1985 * sinfo.adb (Implicit_With_From_Instantiation): Removed.
1986 (Parent_With): New routine.
1987 (Set_Implicit_With_From_Instantiation): Removed.
1988 (Set_Parent_With): New routine.
1989 * sinfo.ads: Update the documentation of attribute Implicit_With.
1990 Remove attribute Implicit_With_From_Instantiation along with
1991 occurrences in nodes. Add attribute Parent_With along with occurrences
1992 in nodes.
1993 (Implicit_With_From_Instantiation): Removed along with pragma Inline.
1994 (Parent_With): New routine along with pragma Inline.
1995 (Set_Implicit_With_From_Instantiation): Removed along with pragma Inline.
1996 (Set_Parent_With): New routine along with pragma Inline.
1997
1998 2018-01-11 Hristian Kirtchev <kirtchev@adacore.com>
1999
2000 * sem_util.adb (Find_Enclosing_Scope): Return the unique defining
2001 entity when the enclosing construct is a body.
2002
2003 2018-01-11 Patrick Bernardi <bernardi@adacore.com>
2004
2005 * exp_ch9.adb (Expand_N_Task_Type_Declaration): Simplified
2006 Secondary_Stack_Size handling as a pragma is now generated for the
2007 corresponding aspect instead of an attribute. Pragma expression is
2008 relocated instead of evaluated. Discriminant of the corresponding
2009 record type is referenced rather than the type discriminant.
2010 (Create_Secondary_Stack_For_Task, Make_Task_Create_Call): Update
2011 Secondary_Stack_Size rep item checks to only look for the pragma rep.
2012 * sem_ch13.adb (Analyze_One_Aspect): Transform
2013 Aspect_Secondary_Stack_Size into a pragma instead of an attribute
2014 because the attribute does not have visibility on a task type's
2015 discriminants when the type's definition is expanded.
2016 (Analyze_Attribute_Definition_Clause): Remove handling of
2017 Attribute_Secondary_Stack_Size.
2018 * snames.adb-tmpl, snames.ads-tmpl: Remove
2019 Attribute_Secondary_Stack_Size, no longer used.
2020
2021 2018-01-11 Justin Squirek <squirek@adacore.com>
2022
2023 * sem_ch8.adb: Minor comment fix.
2024
2025 2018-01-11 Hristian Kirtchev <kirtchev@adacore.com>
2026
2027 * exp_ch4.adb (Process_Action): Do not abandon the inspection of an
2028 individual action because the action may denote a complex expression,
2029 such as a case statement, which in turn may contain additional
2030 transient objects.
2031
2032 2018-01-11 Ed Schonberg <schonberg@adacore.com>
2033
2034 * sem_aggr.adb (Resolve_Iterated_Component_Association): Perform
2035 analysis on a copy of the expression with a copy of the index variable,
2036 because full expansion will rewrite construct into a loop with the
2037 original loop variable.
2038 * exp_aggr.adb (Gen_Assign): Defer analysis and resolution if the
2039 expression is an iterated component association. Full analysis takes
2040 place when construct is rewritten as a loop.
2041 (In_Place_Assign_OK, Safe_Component): An iterated_component_association
2042 is not safe for in-place assignment.
2043 * sem_util.adb (Remove_Entity): Handle properly the case of an isolated
2044 entity with no homonym and no other entity in the scope.
2045
2046 2018-01-11 Justin Squirek <squirek@adacore.com>
2047
2048 * sem_prag.adb (Analyze_Pragma:Pragma_Loop_Variant): Modify error
2049 message to be printed on the pragma argument identifier.
2050
2051 2018-01-11 Hristian Kirtchev <kirtchev@adacore.com>
2052
2053 * exp_util.adb (Build_Invariant_Procedure_Declaration): Set the last
2054 entity of the generated invariant procedure in order to construct a
2055 proper entity chain.
2056
2057 2018-01-11 Piotr Trojanek <trojanek@adacore.com>
2058
2059 * sem_ch13.adb (Build_Predicate_Functions): Fix minor issues in
2060 comment.
2061
2062 2018-01-11 Arnaud Charlet <charlet@adacore.com>
2063
2064 * einfo.ads, einfo.adb (Activation_Record_Component,
2065 Set_Activation_Record_Component, Set_Is_Uplevel_Referenced_Entity):
2066 Allow E_Discriminant.
2067
2068 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
2069
2070 * gcc-interface/decl.c (gnat_to_gnu_component_type): Apply the check
2071 for atomic access once the component size is taken into account and
2072 also do it if the component type is Atomic or Volatile_Full_Access.
2073
2074 2018-01-04 Eric Botcazou <ebotcazou@adacore.com>
2075
2076 * gnatvsn.ads: Bump copyright year.
2077
2078 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
2079 Alan Hayward <alan.hayward@arm.com>
2080 David Sherwood <david.sherwood@arm.com>
2081
2082 * gcc-interface/misc.c (enumerate_modes): Treat GET_MODE_BITSIZE
2083 as polynomial.
2084
2085 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
2086 Alan Hayward <alan.hayward@arm.com>
2087 David Sherwood <david.sherwood@arm.com>
2088
2089 * gcc-interface/misc.c (enumerate_modes): Treat GET_MODE_PRECISION
2090 as polynomial.
2091
2092 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
2093 Alan Hayward <alan.hayward@arm.com>
2094 David Sherwood <david.sherwood@arm.com>
2095
2096 * gcc-interface/utils.c (gnat_types_compatible_p): Handle
2097 polynomial TYPE_VECTOR_SUBPARTS.
2098
2099 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
2100 Alan Hayward <alan.hayward@arm.com>
2101 David Sherwood <david.sherwood@arm.com>
2102
2103 * gcc-interface/misc.c (enumerate_modes): Handle polynomial
2104 GET_MODE_NUNITS.
2105
2106 2018-01-03 Jakub Jelinek <jakub@redhat.com>
2107
2108 Update copyright years.
2109
2110 * gnat_ugn.texi: Bump @copying's copyright year.
2111 * gnat_rm.texi: Likewise.
2112 \f
2113 Copyright (C) 2018 Free Software Foundation, Inc.
2114
2115 Copying and distribution of this file, with or without modification,
2116 are permitted in any medium without royalty provided the copyright
2117 notice and this notice are preserved.