]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/ada/ChangeLog
[Ada] Compiler abort on a dynamic predicate used in a precondition
[thirdparty/gcc.git] / gcc / ada / ChangeLog
CommitLineData
164597c5 12019-07-05 Ed Schonberg <schonberg@adacore.com>
2
3 * checks.adb (Apply_Predicate_Check): Except within the
4 subprogram body that defines the formal, do not apply predicate
5 check on a formal IN parameter: such a check is redundant and
6 its expansion can lead to out-of-scope references when it is
7 originates in a function call in a precondition,
8
572a4bc5 92019-07-05 Yannick Moy <moy@adacore.com>
10
11 * sem_res.adb (Resolve_Call): Cannot inline in quantified
12 expressions.
13 * sem_util.adb, sem_util.ads (In_Quantified_Expression): New
14 function.
15
2c3ad474 162019-07-05 Bob Duff <duff@adacore.com>
17
18 * doc/gnat_rm/standard_and_implementation_defined_restrictions.rst:
19 Fix typo.
20 * gnat_rm.texi: Regenerate.
21
2f67af4c 222019-07-05 Bob Duff <duff@adacore.com>
23
24 * exp_attr.adb (Input): Take the No_Stream_Optimizations
25 restriction into account.
26
1cb1fd0f 272019-07-05 Claire Dross <dross@adacore.com>
28
29 * libgnat/a-cofove.ads, libgnat/a-cofove.adb: Definite formal
30 vectors are now always bounded so that they do not need to be
31 limited anymore.
32
d2d09f3e 332019-07-05 Dmitriy Anisimkov <anisimko@adacore.com>
34
35 * libgnat/g-traceb.ads, libgnat/g-traceb.adb (Call_Chain): New
36 function.
37
14e0bfed 382019-07-04 James Clarke <jrtc27@debian.org>
39
40 * libgnarl/s-osinte__kfreebsd-gnu.ads (clockid_t): Make type
41 definition public.
42 (CLOCK_REALTIME): Make value public.
43
ecd07d3b 442019-07-04 Javier Miranda <miranda@adacore.com>
45
46 * exp_tss.adb (Init_Proc): Adding missing support for access to
47 subprograms and access to protected subprograms of non-default
48 C++ constructors.
49
e0ff1639 502019-07-04 Eric Botcazou <ebotcazou@adacore.com>
51
52 * gnat1drv.adb (Adjust_Global_Switches): Use proper interface to
53 set the validity settings in CodePeer mode.
54 * par-load.adb (Load): Remove all code dealing with validity
55 settings.
56 * validsw.ads (Validity_Check_Copies): Alphabetize.
57 * validsw.adb (Reset_Validity_Check_Options): Set all options to
58 off.
59 (Save_Validity_Check_Options): Save all options.
60
40bff3a0 612019-07-04 Hristian Kirtchev <kirtchev@adacore.com>
62
63 * exp_ch3.adb, exp_ch4.adb, exp_ch4.ads, exp_ch5.adb,
64 exp_ch7.adb, exp_ch9.adb, exp_ch11.adb, exp_unst.adb,
65 rtsfind.ads, sem_attr.adb, sem_ch10.adb, sem_ch12.adb,
66 sem_ch13.adb, sem_dim.adb, sem_disp.adb, xref_lib.adb: Minor
67 reformatting.
68
0ebaade4 692019-07-04 Joffrey Huguet <huguet@adacore.com>
70
71 * libgnarl/a-taside.ads: Add assertion policy to ignore
72 preconditions.
73 (Abort_Task, Is_Terminated, Is_Callable): Add preconditions.
74
f14a590b 752019-07-04 Eric Botcazou <ebotcazou@adacore.com>
76
77 * doc/gnat_rm/implementation_defined_pragmas.rst: Fix
78 capitalization and parenthesis glitches.
79 * gnat_rm.texi: Regenerate.
80
f5388f99 812019-07-04 Ed Schonberg <schonberg@adacore.com>
82
83 * sem_ch10.adb (Remove_Context_Clauses): Handle properly the
84 removal of a limited_with_clause which appears in the library
85 unit oF the main unit, when some other unit in the context has a
86 regular with_clause on the same unit, to prevent spurious
87 visibility errors in the subsequent analysis of pending instance
88 bodies.
89
c930bc82 902019-07-04 Hristian Kirtchev <kirtchev@adacore.com>
91
92 * sem_elab.adb: Add new type Elaboration_Phase_Status along with
93 a global to keep track of the elaboration phase status.
94 Initialize all internal data structures to Nil for services
95 Elaborated_Units, Internal_Representation, and Scenario_Storage.
96 (Build_Call_Marker): Do not create a call marker when the
97 elaboration phase is not active.
98 (Build_Variable_Reference_Marker): Do not create a call marker
99 when the elaboration phase is not active.
100 (Check_Elaboration_Scenarios): Destroy all internal structures
101 when the elaboration phase does not have to run. Do not execute
102 when the elaboration phase is not active.
103 (Elaboration_Phase_Active): New routine.
104 (Finalize_All_Data_Structures): New routine.
105 (Initialize): Initialize all internal data structures and signal
106 that the elaboration phase has started.
107 (Initialize_All_Data_Structures): New routine.
108 (Initialize_Elaborated_Units): Initialize all internal data
109 structures.
110 (Initialize_Internal_Representation): Initialize all internal
111 data structures.
112 (Initialize_Scenario_Storage): Initialize all internal data
113 structures.
114 (Kill_Elaboration_Scenario): Do not execute when the elaboration
115 phase is not active.
116 (Set_Elaboration_Phase): New routine.
117 (Update_Elaboration_Scenario): Do not execute when the
118 elaboration phase is not active.
119
39dec7f4 1202019-07-04 Gary Dismukes <dismukes@adacore.com>
121
122 * sem_ch6.adb (Analyze_Subprogram_Body_Helper): The special
123 treatment of calling Mask_Unfrozen_Types must also be done in
124 the case of an Ignored_Ghost_Entity, because Expander_Active is
125 False in that case.
126
92b004be 1272019-07-04 Yannick Moy <moy@adacore.com>
128
129 * sem_prag.adb (Check_Library_Level_Entity): Update for new rule
130 on SPARK_Mode.
131
12795e1c 1322019-07-04 Justin Squirek <squirek@adacore.com>
133
134 * sem_disp.adb (Check_Controlling_Formals): Obtain the full view
135 before type comparison.
136
63fe3141 1372019-07-04 Ed Schonberg <schonberg@adacore.com>
138
139 * exp_ch4.ads, exp_ch4.adb (Build_Eq_Call): New visible
140 subprogram, extracted from Expand_Composite_Equality, to handle
141 properly the composition of equality for variant record types.
142 * exp_ch3.adb (MAke_Eq_If): Use Build_Eq_Call for each
143 component, to handle properly the case of a component with a
144 user-defined equality. Revert to predefined equality if the
145 user-defined operation is abstract, to maintain compatibility
146 with older versions,
147
17fa952a 1482019-07-04 Justin Squirek <squirek@adacore.com>
149
150 * exp_ch3.adb (Build_Initialization_Call): Fixup
151 *_skip_null_excluding_check argument to handle new default.
152 (Init_Formals): Make *_skip_null_excluding_check formal default
153 to False
154 * exp_ch4.adb (Expand_N_Allocator): Add comment to note heavy
155 code duplication
156
cf32543d 1572019-07-04 Bob Duff <duff@adacore.com>
158
159 * sem_ch3.adb (Access_Definition): Do not create a master unless
160 Tasking_Allowed. Otherwise, this fails on restricted runtimes.
161
eb4dbf20 1622019-07-04 Hristian Kirtchev <kirtchev@adacore.com>
163
164 * sem_util.adb (Propagate_DIC_Attributes): Do not propagate the
165 Default_Initial_Condition attributes to an incomplete type.
166
25ddc6ba 1672019-07-04 Ed Schonberg <schonberg@adacore.com>
168
169 * sem_attr.adb (Check_Array_Type): An array type attribute such
170 as 'First can be applied to an unconstrained array tyope when
171 the attribute reference appears within an aspect specification
172 and the prefix is a current instance, given that the prefix of
173 the attribute will become a formal of the subprogram that
174 implements the aspect (typically a predicate check).
175
74a5962a 1762019-07-04 Piotr Trojanek <trojanek@adacore.com>
177
178 * sem_util.adb (Yields_Synchronized_Object): Fix typos in
179 comments.
180
c65d33a8 1812019-07-04 Yannick Moy <moy@adacore.com>
182
183 * sem_util.adb (Yields_Synchronized_Object): Adapt to new SPARK
184 rule.
185
afd77d39 1862019-07-04 Yannick Moy <moy@adacore.com>
187
188 * sem_spark.adb (Check_Statement): Only check permission of
189 object in extended return when it is of a deep type.
190
2281b807 1912019-07-04 Justin Squirek <squirek@adacore.com>
192
193 * sem_ch12.adb (Perform_Appropriate_Analysis): Added for
194 selecting which type of analysis based on wheither the
195 instantiation is a generic at the library-level. In which case
196 expansion during analysis.
197 (Preanalyze_Actuals): Modify calls to Analyze to use the new
198 routine.
199
542b3e26 2002019-07-04 Ed Schonberg <schonberg@adacore.com>
201
202 * exp_unst.adb: Handle conditional expressions.
203
7754aad4 2042019-07-04 Yannick Moy <moy@adacore.com>
205
206 * sem_spark.adb (Check_Package_Spec, Check_Package_Body): Only
207 analyze parts of the code marked in SPARK.
208
3843c1bd 2092019-07-04 Hristian Kirtchev <kirtchev@adacore.com>
210
211 * erroutc.adb, exp_aggr.adb, inline.adb, opt.adb, sem_ch3.adb:
212 Minor reformatting.
213
5bc0f990 2142019-07-04 Yannick Moy <moy@adacore.com>
215
216 * sem_spark.adb (Explanation, Get_Expl): New functions to get
217 the explanation for a permission mismatch.
218 (Perm_Error, Perm_Mismatch, Perm_Error_Loop_Exit): Take
219 explanation into account for issuing a more precise error
220 message.
221 (Set_Perm_Prefixes, Set_Perm_Extensions,
222 Set_Perm_Extensions_Move): Pass suitable argument for the
223 explanation node.
224
11903e68 2252019-07-04 Arnaud Charlet <charlet@adacore.com>
226
227 * exp_aggr.adb (In_Place_Assign_OK): Moved to top level and add
228 support for record aggregates.
229 (Component_Check): Use Is_CCG_Supported_Aggregate instead of a
230 similar local predicate.
231 (Convert_To_Assignments): Take advantage of In_Place_Assign_OK
232 predicate when possible.
233 (Is_CCG_Supported_Aggregate): Return False for records with
234 representation clauses and fix the logic for dealing with nested
235 aggregates.
236
b0c19ea3 2372019-07-04 Piotr Trojanek <trojanek@adacore.com>
238
239 * opt.adb (Set_Config_Switches): Keep assertions policy as
240 enabled when analysing internal units in GNATprove mode.
241
90f2b146 2422019-07-04 Arnaud Charlet <charlet@adacore.com>
243
244 * exp_ch4.adb (Expand_Short_Circuit_Operator): Strip
245 N_Variable_Reference_Marker when checking for the presence of
246 actions.
247
39ecad34 2482019-07-04 Arnaud Charlet <charlet@adacore.com>
249
250 * exp_aggr.adb (Check_Component): Take into account type
251 conversions.
252
c0e899f1 2532019-07-04 Dmitriy Anisimkov <anisimko@adacore.com>
254
255 * doc/gnat_ugn/platform_specific_information.rst: Document
256 Windows socket timeout particularity.
257 * gnat_ugn.texi: Regenerate.
258 * gsocket.h: Include versionhelpers.h.
259 * socket.c (__gnat_minus_500ms): New function.
260 * libgnat/g-sothco.ads (Minus_500ms_Windows_Timeout): New
261 imported function.
262 * libgnat/g-socket.adb (Set_Socket_Option): Refactor to remove
263 500ms from the requested timeout only on old Windows version.
264
363b1a8e 2652019-07-04 Thomas Quinot <quinot@adacore.com>
266
267 * get_scos.adb: Remove bogus, dead code.
268
4ae0a9ce 2692019-07-04 Ed Schonberg <schonberg@adacore.com>
270
271 * sem_dim.adb (Analyze_Dimension_Array_Aggregate): If the
272 component is an entity name, its dimensions are those of its
273 type.
274
d60fa3c9 2752019-07-03 Bob Duff <duff@adacore.com>
276
277 * doc/gnat_ugn/gnat_utility_programs.rst: Document new flags in
278 GNATpp.
279
877ad320 2802019-07-03 Hristian Kirtchev <kirtchev@adacore.com>
281
282 * binde.adb: Remove with clause for System.OS_Lib.
283 (Force_Elab_Order): Refactor the majority of the code in Butil.
284 Use the new forced units iterator to obtain unit names.
285 * bindo-builders.adb: Add with and use clauses for Binderr,
286 Butil, Opt, Output, Types, GNAT, and GNAT.Dynamic_HTables. Add
287 a hash table which maps units to line number in the forced
288 elaboration order file.
289 (Add_Unit): New routine.
290 (Build_Library_Graph): Create forced edges between pairs of
291 units listed in the forced elaboration order file.
292 (Create_Forced_Edge, Create_Forced_Edges, Destroy_Line_Number,
293 Duplicate_Unit_Error, Hash_Unit, Internal_Unit_Info,
294 Is_Duplicate_Unit, Missing_Unit_Info): New routines.
295 * bindo-graphs.adb (Is_Internal_Unit, Is_Predefined_Unit):
296 Refactor some of the behavior to Bindo-Units.
297 * bindo-graphs.ads: Enable the enumeration literal for forced
298 edges.
299 * bindo-units.adb, bindo-units.ads (Is_Internal_Unit,
300 Is_Predefined_Unit): New routines.
301 * butil.adb: Add with and use clauses for Opt, GNAT, and
302 System.OS_Lib. Add with clause for Unchecked_Deallocation.
303 (Has_Next, Iterate_Forced_Units, Next, Parse_Next_Unit_Name,
304 Read_Forced_Elab_Order_File): New routines.
305 * butil.ads: Add with and use clauses for Types. Add new
306 iterator over the units listed in the forced elaboration order
307 file.
308 (Has_Next, Iterate_Forced_Units, Next): New routine.
309 * namet.adb, namet.ads (Present): New routine.
310
01e6eb2f 3112019-07-03 Bob Duff <duff@adacore.com>
312
313 * sem_ch3.adb (Access_Definition): The code was creating a
314 master in the case where the designated type is a class-wide
315 interface type. Create a master in the noninterface case as
316 well. That is, create a master for all limited class-wide types.
317
9ad42832 3182019-07-03 Yannick Moy <moy@adacore.com>
319
320 * erroutc.adb (Sloc_In_Range): New function to determine whether
321 the range of a pragma Warnings covers a location, taking
322 instantiations into account.
323
f2a8d64e 3242019-07-03 Johannes Kanig <kanig@adacore.com>
325
326 * osint.ads, osint.adb (Get_First_Main_File_Name): New routine
327 to access the first file provided on the command line.
328
d4f28933 3292019-07-03 Ed Schonberg <schonberg@adacore.com>
330
331 * inline.adb (Process_Formals_In_Aspects): New procedure within
332 Expand_Inlined_Call, to perform a replacement of references to
333 formals that appear in aspect specifications within the body
334 being inlined.
335
23e7fc9b 3362019-07-03 Justin Squirek <squirek@adacore.com>
337
338 * sem_ch8.adb (Analyze_Object_Renaming): Add call to search for
339 the appropriate actual subtype of the object renaming being
340 analyzed.
341 (Check_Constrained_Object): Minor cleanup.
342
f8e6d133 3432019-07-03 Yannick Moy <moy@adacore.com>
344
345 * sem_spark.adb (Get_Observed_Or_Borrowed_Expr): New function to
346 return go through traversal function call.
347 (Check_Type): Consistently use underlying type.
348 (Get_Perm): Adapt for case of elaboration code where variables
349 are not declared in the environment. Remove incorrect handling
350 of borrow and observe.
351
d044ba5c 3522019-07-03 Hristian Kirtchev <kirtchev@adacore.com>
353
354 * inline.adb (Build_Return_Object_Formal): New routine.
355 (Can_Split_Unconstrained_Function): Code clean up.
356 (Copy_Formals,Copy_Return_Object): New routines.
357 (Split_Unconstrained_Function): Code clean up and refactoring.
358
8699de72 3592019-07-03 Gary Dismukes <dismukes@adacore.com>
360
361 * bindo-augmentors.adb, bindo-augmentors.ads,
362 bindo-builders.ads, bindo-elaborators.adb, sem_ch12.adb,
363 sem_ch13.adb, sem_spark.adb, sinfo.ads: Minor editorial
364 corrections and reformatting.
365
2ccf6539 3662019-07-03 Bob Duff <duff@adacore.com>
367
368 * sem_warn.adb (Check_Infinite_Loop_Warning): Avoid the warning
369 if an Iterator_Specification is present.
370
17b5260d 3712019-07-03 Bob Duff <duff@adacore.com>
372
373 * doc/gnat_ugn/gnat_utility_programs.rst: Document default
374 new-line behavior.
375
5f71d12c 3762019-07-03 Hristian Kirtchev <kirtchev@adacore.com>
377
378 * ali.adb: Add with and use clauses for GNAT,
379 GNAT.Dynamic_HTables, and Snames. Add a map from invocation
380 signature records to invocation signature ids. Add various
381 encodings of invocation-related attributes. Sort and update
382 table Known_ALI_Lines.
383 (Add_Invocation_Construct, Add_Invocation_Relation,
384 Body_Placement_Kind_To_Code, Code_To_Body_Placement_Kind,
385 Code_To_Invocation_Construct_Kind, Code_To_Invocation_Kind,
386 Code_To_Invocation_Graph_Line_Kind, Destroy, Hash): New
387 routines.
388 (Initialize_ALI): Sort the initialization sequence. Add
389 initialization for all invocation-related tables.
390 (Invocation_Construct_Kind_To_Code,
391 Invocation_Graph_Line_Kind_To_Code, Invocation_Kind_To_Code,
392 Invocation_Signature_Of, Present): New routines.
393 (Scan_ALI): Add the default values for invocation-related ids.
394 Scan invocation graph lines.
395 (Scan_Invocation_Graph_Line): New routine.
396 * ali.ads: Add with clause for GNAT.Dynamic_Tables. Add types
397 for invocation constructs, relations, and signatures. Add
398 tables for invocation constructs, relations, and signatures.
399 Update Unit_Record to capture invocation-related ids. Relocate
400 table Unit_Id_Tables and subtypes Unit_Id_Table, Unit_Id_Array
401 from Binde.
402 (Add_Invocation_Construct, Add_Invocation_Relation,
403 Body_Placement_Kind_To_Code, Code_To_Body_Placement_Kind,
404 Code_To_Invocation_Construct_Kind, Code_To_Invocation_Kind,
405 Code_To_Invocation_Graph_Line_Kind,
406 Invocation_Construct_Kind_To_Code,
407 Invocation_Graph_Line_Kind_To_Code, Invocation_Kind_To_Code,
408 Invocation_Signature_Of, Present): New routines.
409 * binde.adb: Add with and use clause for Types. Add use clause
410 for ALI.Unit_Id_Tables;
411 * binde.ads: Relocate table Unit_Id_Tables and subtypes
412 Unit_Id_Table, Unit_Id_Array to ALI.
413 * bindgen.adb: Remove with and use clause for ALI.
414 * bindgen.ads: Remove with and use clause for Binde. Add with
415 and use clause for ALI.
416 * bindo.adb, bindo.ads, bindo-augmentors.adb,
417 bindo-augmentors.ads, bindo-builders.adb, bindo-builders.ads,
418 bindo-diagnostics.adb, bindo-diagnostics.ads,
419 bindo-elaborators.adb, bindo-elaborators.ads, bindo-graphs.adb,
420 bindo-graphs.ads, bindo-units.adb, bindo-units.ads,
421 bindo-validators.adb, bindo-validators.ads, bindo-writers.adb,
422 bindo-writers.ads: New units.
423 * debug.adb: Use and describe GNAT debug switches -gnatd_F and
424 -gnatd_G. Add GNATbind debug switches in the ranges dA .. dZ,
425 d.a .. d.z, d.A .. d.Z, d.1 .. d.9, d_a .. d_z, d_A .. d_Z, and
426 d_1 .. d_9. Use and describe GNATbind debug switches -d_A,
427 -d_I, -d_L, -d_N, -d_O, -d_T, and -d_V.
428 * exp_util.adb, exp_util.ads (Exceptions_OK): Relocate to
429 Sem_Util.
430 * gnatbind.adb: Add with and use clause for Bindo. Use the new
431 Bindo elaboration order only when -d_N is in effect.
432 * lib-writ.adb
433 (Column, Extra, Invoker, Kind, Line, Locations, Name, Placement,
434 Scope, Signature, Target): New routines.
435 (Write_ALI): Output all invocation-related data.
436 (Write_Invocation_Graph): New routine.
437 * lib-writ.ads: Document the invocation graph ALI line.
438 * namet.adb, namet.ads (Present): New routines.
439 * sem_ch8.adb (Find_Direct_Name): Capture the status of
440 elaboration checks and warnings of an identifier.
441 (Find_Expanded_Name): Capture the status of elaboration checks
442 and warnings of an expanded name.
443 * sem_ch12.adb (Analyze_Generic_Package_Declaration): Ensure
444 that invocation graph-related data within the body of the main
445 unit is encoded in the ALI file.
446 (Analyze_Generic_Subprogram_Declaration): Ensure that invocation
447 graph-related data within the body of the main unit is encoded
448 in the ALI file.
449 (Analyze_Package_Instantiation): Perform minimal decoration of
450 the instance entity.
451 (Analyze_Subprogram_Instantiation): Perform minimal decoration
452 of the instance entity.
453 * sem_elab.adb: Perform heavy refactoring of all code. The unit
454 is now split into "services" which specialize in one area of ABE
455 checks. Add processing in order to capture invocation-graph
456 related attributes of the main unit, and encode them in the ALI
457 file. The Processing phase can now operate in multiple modes,
458 all described by type Processing_Kind. Scenarios and targets
459 are now distinct at the higher level, and carry their own
460 representations. This eliminates the need to constantly
461 recompute their attributes, and offers the various processors a
462 uniform interface. The various initial states of the Processing
463 phase are now encoded using type Processing_In_State, and
464 xxx_State constants.
465 * sem_elab.ads: Update the literals of type
466 Enclosing_Level_Kind. Add Inline pragmas on several routines.
467 * sem_prag.adb (Process_Inline): Ensure that invocation
468 graph-related data within the body of the main unit is encoded
469 in the ALI file.
470 * sem_util.adb (Enclosing_Generic_Body, Enclosing_Generic_Unit):
471 Code clean up.
472 (Exceptions_OK): Relocated from Sem_Util.
473 (Mark_Save_Invocation_Graph_Of_Body): New routine.
474 * sem_util.ads (Exceptions_OK): Relocated from Sem_Util.
475 (Mark_Save_Invocation_Graph_Of_Body): New routine.
476 * sinfo.adb (Is_Elaboration_Checks_OK_Node): Now applicable to
477 N_Variable_Reference_Marker.
478 (Is_Elaboration_Warnings_OK_Node): Now applicable to
479 N_Expanded_Name, N_Identifier, N_Variable_Reference_Marker.
480 (Is_Read): Use Flag4.
481 (Is_SPARK_Mode_On_Node): New applicable to
482 N_Variable_Reference_Marker.
483 (Is_Write): Use Flag5.
484 (Save_Invocation_Graph_Of_Body): New routine.
485 (Set_Is_Elaboration_Checks_OK_Node): Now applicable to
486 N_Variable_Reference_Marker.
487 (Set_Is_Elaboration_Warnings_OK_Node): Now applicable to
488 N_Expanded_Name, N_Identifier, N_Variable_Reference_Marker.
489 (Set_Is_SPARK_Mode_On_Node): New applicable to
490 N_Variable_Reference_Marker.
491 (Set_Save_Invocation_Graph_Of_Body): New routine.
492 * sinfo.ads: Update the documentation of attributes
493 Is_Elaboration_Checks_OK_Node, Is_Elaboration_Warnings_OK_Node,
494 Is_SPARK_Mode_On_Node. Update the flag usage of attributes
495 Is_Read, Is_Write. Add attribute Save_Invocation_Graph_Of_Body
496 and update its occurrence in nodes.
497 (Save_Invocation_Graph_Of_Body): New routine along with pragma
498 Inline.
499 (Set_Save_Invocation_Graph_Of_Body): New routine along with
500 pragma Inline.
501 * switch-b.adb (Scan_Binder_Switches): Refactor the scanning of
502 debug switches.
503 (Scan_Debug_Switches): New routine.
504 * libgnat/g-dynhta.adb, libgnat/g-dynhta.ads (Contains): New routine.
505 * libgnat/g-graphs.adb (Associate_Vertices): Update the use of
506 Component_Vertex_Iterator.
507 (Contains_Component, Contains_Edge, Contains_Vertex, Has_Next):
508 Reimplemented.
509 (Iterate_Component_Vertices): New routine.
510 (Iterate_Vertices): Removed.
511 (Next): Update the parameter profile.
512 (Number_Of_Component_Vertices, Number_Of_Outgoing_Edges): New
513 routines.
514 * libgnat/g-graphs.ads: Update the initialization of
515 No_Component. Add type Component_Vertex_Iterator. Remove type
516 Vertex_Iterator.
517 (Has_Next): Add new versions and remove old ones.
518 (Iterate_Component_Vertices): New routine.
519 (Iterate_Vertices): Removed.
520 (Next): Add new versions and remove old ones.
521 (Number_Of_Component_Vertices, Number_Of_Outgoing_Edges): New
522 routines.
523 * libgnat/g-sets.adb (Contains): Reimplemented.
524 * gcc-interface/Make-lang.in (GNATBIND_OBJS): Add
525 GNAT.Dynamic_HTables, GNAT.Graphs and Bindo units.
526 * rtsfind.ads: Remove extra space.
527
df177848 5282019-07-03 Yannick Moy <moy@adacore.com>
529
530 * sem_spark.adb: Add support for locally borrowing and observing
531 a path.
532 (Get_Root_Object): Add parameter Through_Traversal to denote
533 when we are interesting in getting to the traversed parameter.
534 (Is_Prefix_Or_Almost): New function to support detection of
535 illegal access to borrowed or observed paths.
536 (Check_Pragma): Add analysis of assertion pragmas.
537
f3f142ac 5382019-07-03 Ed Schonberg <schonberg@adacore.com>
539
540 * sem_ch13.adb (Build_Predicate_Functions): In a generic context
541 we do not build the bodies of predicate fuctions, but the
542 expression in a static predicate must be elaborated to allow
543 case coverage checking within the generic unit.
544 (Build_Discrete_Static_Predicate): In a generic context, return
545 without building function body once the
546 Static_Discrete_Predicate expression for the type has been
547 constructed.
548
99d90c85 5492019-07-03 Hristian Kirtchev <kirtchev@adacore.com>
550
551 * bindgen.adb, inline.adb, layout.adb, sem_ch12.adb,
552 sem_ch13.adb, sem_ch7.adb, styleg.adb: Minor reformatting.
553
800597f6 5542019-07-03 Bob Duff <duff@adacore.com>
555
556 * par-ch3.adb (P_Defining_Identifier): Call
557 Check_Defining_Identifier_Casing.
558 * style.ads, styleg.ads, styleg.adb
559 (Check_Defining_Identifier_Casing): New procedure to check for
560 mixed-case defining identifiers.
561 * stylesw.ads, stylesw.adb (Style_Check_Mixed_Case_Decls): New
562 flag for checking for mixed-case defining identifiers.
563 * doc/gnat_ugn/building_executable_programs_with_gnat.rst:
564 Document new feature.
565 * gnat_ugn.texi: Regenerate.
566
2c75027a 5672019-07-03 Eric Botcazou <ebotcazou@adacore.com>
568
569 * doc/gnat_ugn/building_executable_programs_with_gnat.rst
570 (Warning message control): Document that -gnatw.z/Z apply to
571 array types.
572 * freeze.adb (Freeze_Entity): Give -gnatw.z warning for array
573 types as well, but not if the specified alignment is the minimum
574 one.
575 * gnat_ugn.texi: Regenerate.
576
08237d0d 5772019-07-03 Bob Duff <duff@adacore.com>
578
579 * einfo.ads, exp_util.adb, layout.ads, sinfo.ads: Spell "laid"
580 correctly.
581
0396441f 5822019-07-03 Ed Schonberg <schonberg@adacore.com>
583
584 * sem_ch13.adb (Analyze_Attribute_Definition_Clause): No error
585 message on attribute applied to a renaming when the renamed
586 object is an aggregate (from code reading).
587 (Check_Aspect_At_End_Of_Declarations): In a generic context
588 where freeze nodes are not generated, the original expression
589 for an aspect may need to be analyzed to precent spurious
590 conformance errors when compared with the expression that is
591 anakyzed at the end of the current declarative list.
592
c8406f30 5932019-07-03 Eric Botcazou <ebotcazou@adacore.com>
594
595 * layout.adb (Layout_Type): Do not set the component size of an
596 array with a scalar component if the component type is
597 overaligned.
598
c38b32ea 5992019-07-03 Ed Schonberg <schonberg@adacore.com>
600
601 * inline.adb (Make_Loop_Labels_Unique): New procedure to modify
602 the source code of subprograms that are inlined by the
603 front-end, to prevent accidental duplication between loop labels
604 in the inlined code and the code surrounding the inlined call.
605
6d6f134e 6062019-07-03 Hristian Kirtchev <kirtchev@adacore.com>
607
608 * doc/gnat_ugn/elaboration_order_handling_in_gnat.rst: Update
609 the section on resolving elaboration circularities to eliminate
610 certain combinations of switches which together do not produce
611 the desired effect and confuse users.
612 * gnat_ugn.texi: Regenerate.
613
f3e16ef4 6142019-07-03 Arnaud Charlet <charlet@adacore.com>
615
616 * bindgen.adb (Gen_Main): Disable generation of reference to
617 Ada_Main_Program_Name for CCG.
618 * bindusg.adb (Display): Add -G to the command-line usage for
619 gnatbind.
620 * opt.ads (Generate_C_Code): Update comment.
621 * switch-b.adb (Scan_Binder_Switches): Add handling for -G.
622
f4a31b16 6232019-07-03 Arnaud Charlet <charlet@adacore.com>
624
625 * sem_ch7.adb (Has_Referencer): Do not consider inlined
626 subprograms when generating C code, which allows us to generate
627 static inline subprograms.
628
2f65e9f7 6292019-07-03 Justin Squirek <squirek@adacore.com>
630
631 * sem_ch6.adb (Check_Conformance): Add expression checking for
632 constant modifiers in anonymous access types (in addition to
633 "non-null" types) so that they are considered "matching" for
634 subsequent conformance tests.
635
c336ed70 6362019-07-03 Arnaud Charlet <charlet@adacore.com>
637
638 * doc/gnat_rm/standard_and_implementation_defined_restrictions.rst:
639 Clarify wording on No_Multiple_Elaboration.
640 * gnat_rm.texi: Regenerate.
641
78611c86 6422019-07-03 Ed Schonberg <schonberg@adacore.com>
643
644 * sem_ch8.adb (Find_Selected_Component): If the prefix is the
645 current instance of a type or subtype, complete the resolution
646 of the name by finding the component of the type denoted by the
647 selector name.
648
5a87a4d9 6492019-07-03 Eric Botcazou <ebotcazou@adacore.com>
650
651 * doc/gnat_rm/interfacing_to_other_languages.rst (Interfacing to C):
652 Document that boolean types with convention C now map to C99 bool.
653 * gnat_rm.texi: Regenerate.
654
371c539c 6552019-07-03 Javier Miranda <miranda@adacore.com>
656
657 * exp_attr.adb (Expand_Min_Max_Attribute): Code cleanup:
658 removing code that it is now never executed in the CCG compiler
659 (dead code).
660
89d2d652 6612019-07-02 Iain Sandoe <iain@sandoe.co.uk>
662
663 * libgnat/system-darwin-ppc.ads: Set Stack_Check_Probes True for
664 PPC Darwin.
665
d21e66fb 6662019-07-01 Ed Schonberg <schonberg@adacore.com>
667
668 * sem_ch12.adb (Is_Defaulted): New predicate in
669 Check_Formal_Package_Intance, to skip the conformance of checks
670 on parameters of a formal package that are defaulted,
671
7a42b778 6722019-07-01 Hristian Kirtchev <kirtchev@adacore.com>
673
674 * checks.adb, exp_ch9.adb, exp_unst.adb, sem_ch4.adb,
675 sem_prag.adb, sem_spark.adb: Minor reformatting.
676
fc8ae496 6772019-07-01 Ed Schonberg <schonberg@adacore.com>
678
679 * sem_attr.adb (Analyze_Attribute, case Enum_Rep): Allow prefix
680 of attribute to be an attribute reference of a discrete type.
681
9d27ea41 6822019-07-01 Eric Botcazou <ebotcazou@adacore.com>
683
684 * sem_ch12.adb (Analyze_Subprogram_Instantiation): Move up
685 handling of Has_Pragma_Inline_Always and deal with
686 Has_Pragma_No_Inline.
687
bcb8dcf3 6882019-07-01 Ed Schonberg <schonberg@adacore.com>
689
690 * sem_ch3.adb (Build_Derived_Record_Type): If the parent type is
691 declared as a subtype of a private type with an inherited
692 discriminant constraint, its generated full base appears as a
693 record subtype, so we need to retrieve its oen base type so that
694 the inherited constraint can be applied to it.
695
d087b9ca 6962019-07-01 Yannick Moy <moy@adacore.com>
697
698 * sem_spark.adb: Completely rework the algorithm for ownership
699 checking, as the rules in SPARK RM have changed a lot.
700 * sem_spark.ads: Update comments.
701
fe48ee0a 7022019-07-01 Dmitriy Anisimkov <anisimko@adacore.com>
703
704 * gsocket.h (Has_Sockaddr_Len): Use the offset of sin_family offset in
705 the sockaddr_in structure to determine the existence of length field
706 before the sin_family.
707
b20f7e2c 7082019-07-01 Ed Schonberg <schonberg@adacore.com>
709
710 * sem_prag.adb (Analyze_Pragma, case Weak_External): Pragma only
711 applies to entities with run-time addresses, not to types.
712
374fdf94 7132019-07-01 Piotr Trojanek <trojanek@adacore.com>
714
715 * einfo.adb, sem_ch7.adb, sem_prag.adb, sem_util.adb: Update
716 references to the SPARK RM after the removal of Rule 7.1.4(5).
717
bf13a79d 7182019-07-01 Piotr Trojanek <trojanek@adacore.com>
719
720 * sysdep.c: Cleanup references to LynuxWorks in docs and
721 comments.
722
866fa2d0 7232019-07-01 Ed Schonberg <schonberg@adacore.com>
724
725 * checks.adb (Insert_Valid_Check): Do not apply validity check
726 to variable declared within a protected object that uses the
727 Lock_Free implementation, to prevent unwarranted constant
728 folding, because entities within such an object msut be treated
729 as volatile.
730
bcb5ab83 7312019-07-01 Eric Botcazou <ebotcazou@adacore.com>
732
733 * exp_ch9.adb (Check_Inlining): Deal with Has_Pragma_No_Inline.
734
2db33bd6 7352019-07-01 Ed Schonberg <schonberg@adacore.com>
736
737 * exp_unst.adb (Visit_Node, Check_Static_Type): Improve the
738 handling of private and incomplete types whose full view is an
739 access type, to detect additional uplevel references in dynamic
740 bounds. This is relevant to N_Free_Statement among others that
741 manipulate types whose full viww may be an access type.
742
6b4f0b7d 7432019-07-01 Pat Rogers <rogers@adacore.com>
744
745 * doc/gnat_rm/representation_clauses_and_pragmas.rst: Correct
746 size indicated for R as a component of an array.
747 * gnat_rm.texi: Regenerate.
748
cdee70d7 7492019-07-01 Justin Squirek <squirek@adacore.com>
750
751 * libgnat/s-win32.ads: Add definition for ULONG, modify
752 OVERLAPPED type, and add appropriate pragmas.
753
2cf822b7 7542019-07-01 Bob Duff <duff@adacore.com>
755
756 * gnat1drv.adb (gnat1drv): Call Write_ALI if the main unit is
757 ignored-ghost.
758
0a1ece97 7592019-07-01 Yannick Moy <moy@adacore.com>
760
761 * sem_ch4.adb (Operator_Check): Refine error message.
762
ee4279ef 7632019-07-01 Piotr Trojanek <trojanek@adacore.com>
764
765 * libgnat/a-calend.ads: Revert "Global => null" contracts on
766 non-pure routines.
767
2c6b4ada 7682019-07-01 Piotr Trojanek <trojanek@adacore.com>
769
770 * exp_attr.adb, libgnat/g-graphs.ads: Fix typos in comments:
771 componant -> component.
772
175c4526 7732019-07-01 Hristian Kirtchev <kirtchev@adacore.com>
774
775 * libgnat/g-graphs.adb: Use type Directed_Graph rather than
776 Instance in various routines.
777 * libgnat/g-graphs.ads: Change type Instance to Directed_Graph.
778 Update various routines that mention the type.
779
a0d15509 7802019-07-01 Hristian Kirtchev <kirtchev@adacore.com>
781
782 * libgnat/g-sets.adb: Use type Membership_Set rathern than
783 Instance in various routines.
784 * libgnat/g-sets.ads: Change type Instance to Membership_Set.
785 Update various routines that mention the type.
786
205a23a3 7872019-07-01 Hristian Kirtchev <kirtchev@adacore.com>
788
789 * libgnat/g-lists.adb: Use type Doubly_Linked_List rather than
790 Instance in various routines.
791 * libgnat/g-lists.ads: Change type Instance to
792 Doubly_Linked_List. Update various routines that mention the
793 type.
794
17fdf8c2 7952019-07-01 Hristian Kirtchev <kirtchev@adacore.com>
796
797 * libgnat/g-dynhta.adb: Use type Dynamic_Hash_Table rather than
798 Instance in various routines.
799 * libgnat/g-dynhta.ads: Change type Instance to
800 Dynamic_Hash_Table. Update various routines that mention the
801 type.
802
216ffc64 8032019-07-01 Hristian Kirtchev <kirtchev@adacore.com>
804
805 * exp_attr.adb, exp_ch7.adb, exp_unst.adb, sem_ch3.adb,
806 sem_util.adb, uintp.adb, uintp.ads: Minor reformatting.
807
5051fe35 8082019-07-01 Javier Miranda <miranda@adacore.com>
809
810 * exp_attr.adb (Expand_Min_Max_Attribute): Disable expansion of
811 'Min/'Max on integer, enumeration, fixed point and floating
812 point types since the CCG backend now provides in file
813 standard.h routines to support it.
814
830a2a71 8152019-07-01 Hristian Kirtchev <kirtchev@adacore.com>
816
817 * impunit.adb: Add GNAT.Graphs to list Non_Imp_File_Names_95.
818 * Makefile.rtl, gcc-interface/Make-lang.in: Register unit
819 GNAT.Graphs.
820 * libgnat/g-dynhta.adb: Various minor cleanups (use Present
821 rather than direct comparisons).
822 (Delete): Reimplement to use Delete_Node.
823 (Delete_Node): New routine.
824 (Destroy_Bucket): Invoke the provided destructor.
825 (Present): New routines.
826 * libgnat/g-dynhta.ads: Add new generic formal Destroy_Value.
827 Use better names for the components of iterators.
828 * libgnat/g-graphs.adb, libgnat/g-graphs.ads: New unit.
829 * libgnat/g-lists.adb: Various minor cleanups (use Present
830 rather than direct comparisons).
831 (Delete_Node): Invoke the provided destructor.
832 (Present): New routine.
833 * libgnat/g-lists.ads: Add new generic formal Destroy_Element.
834 Use better names for the components of iterators.
835 (Present): New routine.
836 * libgnat/g-sets.adb, libgnat/g-sets.ads (Destroy, Preset,
837 Reset): New routines.
838
b0111d94 8392019-07-01 Dmitriy Anisimkov <anisimko@adacore.com>
840
841 * libgnat/g-sothco.adb (Get_Address): Fix the case when AF_INET6
842 is not defined.
843
7362896b 8442019-07-01 Ed Schonberg <schonberg@adacore.com>
845
846 * exp_attr.adb (Expand_Attribute_Reference, case Invalid_Value):
847 Resolve result of call to Get_Simple_Init_Val, which may be a
848 conversion of a literal.
849
0dae8dc2 8502019-07-01 Hristian Kirtchev <kirtchev@adacore.com>
851
852 * freeze.adb (Freeze_Expression): Remove the horrible useless
853 name hiding of N. Insert the freeze nodes generated by the
854 expression prior to the expression when the nearest enclosing
855 scope is transient.
856
487da8ff 8572019-07-01 Pierre-Marie de Rodat <derodat@adacore.com>
858
859 * doc/gnat_ugn/building_executable_programs_with_gnat.rst: Fix
860 formatting issues in the -gnatR section.
861 * gnat_ugn.texi: Regenerate.
862
1d79fa18 8632019-06-30 Iain Sandoe <iain@sandoe.co.uk>
864
865 * gnatlink.adb (Link_Step): Remove duplicate -static-libgcc switches.
866 Push -shared-libgcc explicitly, when it is the target default (unless
867 overidden by the static flag).
868 When the user has put an instance of shared/static-libgcc do not push
869 a duplicate of this.
870
a850edcd 8712019-06-29 Eric Botcazou <ebotcazou@adacore.com>
872
873 * gcc-interface/decl.c (gnat_to_gnu_entity): Beep up comment on SAVED,
874 and tweak comment on the assertion about the scopes of Itypes. Do not
875 skip the regular processing for Itypes that are E_Record_Subtype with
876 a Cloned_Subtype. Get the Cloned_Subtype for every E_Record_Subtype
877 if the type is dummy and hasn't got its own freeze node.
878 <E_Record_Subtype>: Save again the DECL of the Cloned_Subtype, if any.
879 <E_Access_Subtype>: Save again the DECL of the equivalent type.
880 (Gigi_Equivalent_Type) <E_Access_Subtype>: New case.
881
b1e46fb1 8822019-06-29 Eric Botcazou <ebotcazou@adacore.com>
883
884 * gcc-interface/utils.c (unchecked_convert): Tweak comment. Only skip
885 dereferences when padding to have the same size on both sides. Do it
886 for destination types with self-referential size too.
887
07e38949 8882019-06-29 Eric Botcazou <ebotcazou@adacore.com>
889
890 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Type>: If the
891 type requires strict alignment, then set the RM size to the type size.
892 Rework handling of alignment and sizes of tagged types in ASIS mode.
893 (validate_size): Rename local variable and remove special handling for
894 strict-alignment types.
895 * gcc-interface/utils.c (finish_record_type): Constify local variables
896 and use properly typed constants.
897
f4409741 8982019-06-29 Eric Botcazou <ebotcazou@adacore.com>
899
900 * gcc-interface/decl.c (gnat_to_gnu_field): Rework error messages for
901 fields requiring strict alignment, add explicit test on Storage_Unit
902 for position and size, and mention type alignment for position.
903
5882c515 9042019-06-29 Eric Botcazou <ebotcazou@adacore.com>
905
906 * gcc-interface/trans.c (mark_visited_r): Set TYPE_SIZES_GIMPLIFIED on
907 the main variant of a type, if any.
908
d0de0a27 9092019-06-29 Eric Botcazou <ebotcazou@adacore.com>
910
911 * gcc-interface/decl.c (set_nonaliased_component_on_array_type): Add
912 missing guard for the presence of TYPE_CANONICAL.
913 (set_reverse_storage_order_on_array_type): Likewise.
914
2074c859 9152019-06-29 Eric Botcazou <ebotcazou@adacore.com>
916
917 * gcc-interface/gigi.h (make_packable_type): Remove default value.
918 (value_factor_p): Tweak prototype.
919 * gcc-interface/decl.c (gnat_to_gnu_entity): Add comment.
920 (gnat_to_gnu_component_type): Likewise.
921 (gnat_to_gnu_field): Likewise. Fetch the position of the field earlier
922 and simplify the condition under which the type is packed. Declare
923 local variable is_bitfield. Pass 1 as max_align to make_packable_type
924 if it is set to true.
925 (copy_and_substitute_in_layout): Pass 0 to make_packable_type.
926 * gcc-interface/utils.c (make_packable_array_type): New function.
927 (make_packable_type): Use it to rewrite the type of array field.
928 (maybe_pad_type): Pass align parameter to make_packable_type.
929 (create_field_decl): Minor tweaks.
930 (value_factor_p): Assert that FACTOR is a power of 2 and replace the
931 modulo computation by a masking operation.
932
83c6da22 9332019-06-25 Eric Botcazou <ebotcazou@adacore.com>
934
935 * gcc-interface/decl.c (gnat_to_gnu_entity): Remove superfluous test
936 in previous change.
937 * gcc-interface/gigi.h (maybe_character_type): Fix formatting.
938 (maybe_character_value): Likewise.
939
aaabc7bc 9402019-06-24 Jan Hubicka <jh@suse.cz>
941
942 * gcc-interface/decl.c (gnat_to_gnu_entity): Check that
943 type is array or integer prior checking string flag.
83c6da22 944 * gcc-interface/gigi.h (maybe_character_type): Likewise.
945 (maybe_character_value): Likewise.
aaabc7bc 946
5fe09a56 9472019-06-24 Martin Sebor <msebor@redhat.com>
948
949 * gcc-interface/utils.c (handle_nonnull_attribute): Quote attribute
950 name.
951
bd9331d6 9522019-06-18 Arnaud Charlet <charlet@adacore.com>
953
83c6da22 954 PR ada/80590
bd9331d6 955 * sem_ch5.adb (Analyze_Loop_Statement): Avoid exception propagation
956 during normal processing.
957
8a5a7d1c 9582019-06-17 Arnaud Charlet <charlet@adacore.com>
959
83c6da22 960 PR ada/80590
8a5a7d1c 961 * exp_ch9.adb (Expand_N_Delay_Relative_Statement): Swap the two
962 conditions to avoid a unnecessary exception propagation in the default
963 case.
964
580934f6 9652019-05-28 Eric Botcazou <ebotcazou@adacore.com>
966
967 * gcc-interface/utils.c (handle_stack_protect_attribute): Move around.
968
c8956236 9692019-05-28 Eric Botcazou <ebotcazou@adacore.com>
970
971 * doc/gnat_rm/implementation_defined_pragmas.rst (Machine_Attribute):
972 Document additional optional parameters.
973 * sem_prag.adb (Analyze_Pragma) <Pragma_Machine_Attribute>: Accept
974 more than one optional parameter.
975 * gcc-interface/decl.c (prepend_one_attribute_pragma): Alphabetize
976 the list of supported pragmas. Simplify the handling of parameters
977 and add support for more than one optional parameter.
978 * gcc-interface/utils.c (attr_cold_hot_exclusions): New constant.
979 (gnat_internal_attribute_table): Add entry for no_icf, noipa, flatten,
980 used, cold, hot, target and target_clones.
981 (begin_subprog_body): Do not create the RTL for the subprogram here.
982 (handle_noicf_attribute): New static function.
983 (handle_noipa_attribute): Likewise.
984 (handle_flatten_attribute): Likewise.
985 (handle_used_attribute): Likewise.
986 (handle_cold_attribute): Likewise.
987 (handle_hot_attribute): Likewise.
988 (handle_target_attribute): Likewise.
989 (handle_target_clones_attribute): Likewise.
990
62b762c2 9912019-05-28 Eric Botcazou <ebotcazou@adacore.com>
992
993 * gcc-interface/trans.c (lvalue_required_for_attribute_p): Return 0
994 for 'Size too.
995 (Identifier_to_gnu): Use the actual subtype for a reference to a
996 packed array in a return statement.
997 (Attribute_to_gnu) <Attr_Size>: Do not strip VIEW_CONVERT_EXPRs from
998 the prefix in every case.
999
336a61a3 10002019-05-28 Eric Botcazou <ebotcazou@adacore.com>
1001
1002 * gcc-interface/trans.c (gnat_to_gnu): Remove superfluous tests on
1003 Backend_Overflow_Checks_On_Target and rework comments.
1004
983c5b5e 10052019-05-28 Eric Botcazou <ebotcazou@adacore.com>
1006
1007 * gcc-interface/trans.c (walk_nesting_tree): New static function.
1008 (finalize_nrv): Use it to walk the entire nesting tree.
1009
96b4b84e 10102019-05-28 Eric Botcazou <ebotcazou@adacore.com>
1011
1012 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Subtype>: Remove
1013 obsolete test on Is_For_Access_Subtype.
1014
0b74284e 10152019-05-28 Eric Botcazou <ebotcazou@adacore.com>
1016
1017 * gcc-interface/decl.c (components_to_record): Set a name on the type
1018 created for the REP part, if any.
1019 * gcc-interface/utils.c (finish_record_type): Only take the maximum
1020 when merging sizes for a variant part at offset 0.
1021 (merge_sizes): Rename has_rep parameter into max.
1022
689dab9d 10232019-05-28 Eric Botcazou <ebotcazou@adacore.com>
1024
1025 * gcc-interface/utils.c (gnat_internal_attribute_table): Add support
1026 for stack_protect attribute.
1027 (handle_stack_protect_attribute): New static function.
1028
804f7d39 10292019-05-28 Eric Botcazou <ebotcazou@adacore.com>
1030
1031 * gcc-interface/decl.c (intrin_arglists_compatible_p): Do not return
1032 false if the internal builtin uses a variable list.
1033
f07f94cc 10342019-05-27 Eric Botcazou <ebotcazou@adacore.com>
1035
1036 * gcc-interface/trans.c (Call_to_gnu): Do not initialize the temporary
1037 created out of addressability concerns if it's for the _Init parameter
1038 of an initialization procedure.
1039
abfd658b 10402019-05-27 Eric Botcazou <ebotcazou@adacore.com>
1041
1042 * gcc-interface/ada-builtin-types.def: New file.
1043 * gcc-interface/ada-builtins.def: Likewise.
1044 * gcc-interface/ada-tree.h (BUILT_IN_LIKELY): New macro.
1045 (BUILT_IN_UNLIKELY): Likewise.
1046 * gcc-interface/trans.c (independent_iterations_p): Initialize the
1047 auto-vector to 16 elements.
1048 (Call_to_gnu): Remove local variable and change the vector of actual
1049 parameters to an auto-vector. Do not convert actual parameters to
1050 the argument type for front-end built-in functions. Add support for
1051 front-end built-in functions.
1052 (build_noreturn_cond): Use internal instead of built-in function.
1053 * gcc-interface/utils.c (c_builtin_type): Include ada-builtin-types.def
1054 (install_builtin_function_types): Likewise.
1055 (install_builtin_functions): Include ada-builtins.def first.
1056
caab73a2 10572019-05-27 Eric Botcazou <ebotcazou@adacore.com>
1058
1059 * gcc-interface/utils.c (maybe_pad_type): Issue the warning for the
1060 specific case of component types preferably.
1061
f1ca2388 10622019-05-27 Eric Botcazou <ebotcazou@adacore.com>
1063
1064 * gcc-interface/trans.c (Identifier_to_gnu): Minor tweaks.
1065 (gnat_to_gnu): Do not convert the result if it is a reference to an
1066 unconstrained array used as the prefix of an attribute reference that
1067 requires an lvalue.
1068
e3f3573c 10692019-05-27 Eric Botcazou <ebotcazou@adacore.com>
1070
1071 * gcc-interface/trans.c (Gigi_Types_Compatible): New predicate.
1072 (Identifier_to_gnu): Use it to assert that the type of the identifier
1073 and that of its entity are compatible for gigi. Rename a couple of
1074 local variables and separate the processing of the result type.
1075
2306cd17 10762019-05-27 Eric Botcazou <ebotcazou@adacore.com>
1077
1078 * gcc-interface/trans.c (Call_to_gnu): Use the unpadded type when
1079 putting back an intermediate conversion the type of the actuals.
1080
6e4e9378 10812019-05-27 Eric Botcazou <ebotcazou@adacore.com>
1082
1083 * gcc-interface/trans.c (gnat_to_gnu) <Shift operations>: Convert the
1084 count to the unsigned version of its base type before proceeding.
1085
85b9be9b 10862019-05-16 Martin Sebor <msebor@redhat.com>
1087
3d6be0d5 1088 * gcc-interface/trans.c (check_inlining_for_nested_subprog): Quote
1089 reserved names.
85b9be9b 1090
65d973ca 10912019-05-08 Arnaud Charlet <charlet@adacore.com>
1092
1093 * standard.ads.h: New file.
1094
ff628b99 10952019-05-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1096
1097 * gcc-interface/Makefile.in (install-gcc-specs): Use foreach.
1098 Honor DESTDIR.
1099
ebd761d4 11002019-04-29 Michael K. Darling <darlingm@gmail.com>
1101
1102 * gnatvsn.ads: Bump Library_Version to 10.
1103
5f260823 11042019-04-24 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
1105 Bernd Edlinger <bernd.edlinger@hotmail.de>
1106 Jakub Jelinek <jakub@redhat.com>
1107
1108 PR target/89093
1109 * raise-gcc.c (TARGET_ATTRIBUTE): Define.
1110 (continue_unwind, personality_body, PERSONALITY_FUNCTION): Add
1111 TARGET_ATTRIBUTE.
1112
d7ca95c0 11132019-04-07 Eric Botcazou <ebotcazou@adacore.com>
1114
1115 * libgnat/i-cexten.ads (CFloat_128): New type.
1116
26b21081 11172019-03-22 Dmitriy Anisimkov <anisimko@adacore.com>
1118
1119 PR ada/89583
1120 * libgnat/g-socket.adb (Bind_Socket, Connect_Socket,
1121 Send_Socket): Fix the computation of structure lengths passed to
1122 low level routines.
1123 (Is_IPv6_Address): Fix the number of expected colons.
1124
2f6d557f 11252019-03-11 Martin Liska <mliska@suse.cz>
1126
d325ee67 1127 * gcc-interface/misc.c (gnat_post_options): Wrap option name in string
1128 format message and fix GNU coding style.
2f6d557f 1129
c1ad6672 11302019-02-08 Eric Botcazou <ebotcazou@adacore.com>
1131
1132 * gcc-interface/trans.c (gnat_to_gnu) <N_Aggregate>: Minor tweak.
1133 * gcc-interface/utils.c (convert): Do not pad when doing an unchecked
1134 conversion here. Use TREE_CONSTANT throughout the function.
1135 (unchecked_convert): Also pad if the source is a CONSTRUCTOR and the
1136 destination is a more aligned array type or a larger aggregate type,
1137 but not between original and packable versions of a type.
1138
62a6ebbd 11392019-02-08 Eric Botcazou <ebotcazou@adacore.com>
1140
1141 * gcc-interface/utils.c (max_size) <tcc_unary>: Be prepared for an
1142 operand with VOID_TYPE.
1143
da383d19 11442019-02-08 Eric Botcazou <ebotcazou@adacore.com>
1145
1146 * gcc-interface/trans.c (elaborate_all_entities): Do not elaborate the
1147 entities of a package renaming another one.
1148
09c123a0 11492019-02-08 Eric Botcazou <ebotcazou@adacore.com>
1150
1151 * gcc-interface/trans.c (Regular_Loop_to_gnu): Replace tests on
1152 individual flag_unswitch_loops and flag_tree_loop_vectorize switches
1153 with test on global optimize switch.
1154 (Raise_Error_to_gnu): Likewise.
1155
a9dd7273 11562019-02-07 Eric Botcazou <ebotcazou@adacore.com>
1157
1158 * libgnarl/s-linux__sparc.ads (ETIMEDOUT): Set to correct value.
1159
4836c4f1 11602019-02-06 Arnaud Charlet <charlet@adacore.com>
1161
1162 * libgnarl/s-linux__x32.ads: Resync list of signals with s-linux.ads
1163
6b56937c 11642019-01-27 Eric Botcazou <ebotcazou@adacore.com>
1165
1166 * repinfo.adb (List_Component_Layout): Remove superfluous space for
1167 zero-sized field.
1168 * gcc-interface/ada-tree.h (TYPE_IS_EXTRA_SUBTYPE_P): New macro.
1169 * gcc-interface/gigi.h (create_extra_subtype): Declare.
1170 * gcc-interface/decl.c (TYPE_ARRAY_SIZE_LIMIT): Likewise.
1171 (update_n_elem): New function.
1172 (gnat_to_gnu_entity): Use create_extra_subtype to create extra subtypes
1173 instead of doing it manually.
1174 <E_Array_Type>: Use update_n_elem to compute the maximum size. Use the
1175 index type instead of base type for the bounds. Set TYPE_ARRAY_MAX_SIZE
1176 of the array to the maximum size.
1177 <E_Array_Subtype>: Create an extra subtype using the index type of the
1178 base array type for self-referential bounds. Use update_n_elem to
1179 compute the maximum size. Set TYPE_ARRAY_MAX_SIZE of the array to the
1180 maximum size.
1181 (gnat_to_gnu_field): Clear DECL_NONADDRESSABLE_P on discriminants.
1182 * gcc-interface/misc.c (gnat_get_alias_set): Return the alias set of
1183 the base type for an extra subtype.
1184 (gnat_type_max_size): Remove obsolete code.
1185 * gcc-interface/trans.c (Attribute_to_gnu): Minor tweak.
1186 (can_be_lower_p): Deal with pathological types.
1187 * gcc-interface/utils.c (create_extra_subtype): New function.
1188 (create_field_decl): Minor tweak.
1189 (max_size) <tcc_reference>: Compute a better value by using the extra
1190 subtypes on the self-referential bounds.
1191 <tcc_binary>: Rewrite. Deal with "negative value" in unsigned types.
1192 <tcc_expression>: Likewise.
1193 * gcc-interface/utils2.c (compare_arrays): Retrieve the original bounds
1194 of the arrays upfront. Swap only if the second length is not constant.
1195 Use comparisons on the original bounds consistently for the null tests.
1196 (build_binary_op): Use TYPE_IS_EXTRA_SUBTYPE_P macro.
1197 (build_allocator): Minor tweak.
1198
ecb2c722 11992019-01-27 Eric Botcazou <ebotcazou@adacore.com>
1200
1201 * gcc-interface/decl.c (array_type_has_nonaliased_component): Return
1202 the same value for every dimension of a multidimensional array type.
1203
10f25579 12042019-01-26 Eric Botcazou <ebotcazou@adacore.com>
1205
1206 * gcc-interface/trans.c (Regular_Loop_to_gnu): Use the SLOC of the
1207 iteration scheme, if present, throughout the translation.
1208
aced6683 12092019-01-26 Eric Botcazou <ebotcazou@adacore.com>
1210
1211 * gcc-interface/trans.c (gnat_to_gnu) <N_Assignment_Statement>: Use
1212 DECL_SIZE_UNIT instead of TYPE_SIZE_UNIT for the size to be assigned
1213 by a call to memset if the LHS is a DECL.
1214
18b4b30e 12152019-01-26 Eric Botcazou <ebotcazou@adacore.com>
1216
1217 * gcc-interface/trans.c (struct loop_info_d): Remove artificial field.
1218 (Loop_Statement_to_gnu): Do not set it.
1219
6dce35b7 12202019-01-26 Eric Botcazou <ebotcazou@adacore.com>
1221
1222 * gcc-interface/trans.c (Iterate_Acc_Clause_Arg): Fix formatting.
1223 (Acc_gnat_to_gnu): Likewise.
1224 (Acc_Data_to_gnu): Likewise.
1225 (Acc_Var_to_gnu): Likewise.
1226 (Acc_Reduc_to_gnu): Likewise.
1227 (Acc_Size_List_to_gnu): Likewise.
1228 (Pragma_to_gnu) <Pragma_Acc_Loop>: Likewise.
1229 <Pragma_Acc_Data>): Likewise.
1230 (find_loop_for): Remove default value for parameters.
1231 * gcc-interface/trans.c (gnat_to_gnu) <N_Op_And>: Merge into...
1232 <N_Op_Eq>): ...this.
1233
f8cd11ee 12342019-01-26 Eric Botcazou <ebotcazou@adacore.com>
1235
1236 * gcc-interface/decl.c (annotate_value) <INTEGER_CST>: Use test on
1237 the sign bit instead of on the sign of the value.
1238 <PLUS_EXPR>: Turn addition of negative constant into subtraction.
1239 <MULT_EXPR>: Add test for degenerate case.
1240 <BIT_AND_EXPR>: Simplify.
1241
9a3c51d9 12422019-01-18 Sebastian Huber <sebastian.huber@embedded-brains.de>
1243
1244 * s-oscons-tmplt.c (AF_INET6): Do not undefine for RTEMS.
1245
07c11f2b 12462019-01-09 Sandra Loosemore <sandra@codesourcery.com>
1247
1248 PR other/16615
07c11f2b 1249 * exp_ch11.adb: Change "can not" to "cannot".
1250 * sem_ch4.adb: Likewise.
1251
f4d3c071 12522019-01-09 Sandra Loosemore <sandra@codesourcery.com>
1253
1254 PR other/16615
f4d3c071 1255 * exp_ch9.adb: Mechanically replace "can not" with "cannot".
1256 * libgnat/s-regpat.ads: Likewise.
1257 * par-ch4.adb: Likewise.
1258 * set_targ.adb: Likewise.
1259 * types.ads: Likewise.
1260
902071d1 12612019-01-08 Justin Squirek <squirek@adacore.com>
1262
1263 Revert:
902071d1 1264 2018-07-31 Justin Squirek <squirek@adacore.com>
1265
76fb0465 1266 * lib-writ.adb (Write_With_Lines): Modfiy the generation
1267 of dependencies within ali files so that source unit
1268 bodies are properly listed even if said bodies are
1269 missing. Perform legacy behavior in GNATprove mode.
1270 * lib-writ.ads: Modify documentation to reflect current
1271 behavior.
902071d1 1272
1273 and:
902071d1 1274 2018-09-26 Justin Squirek <squirek@adacore.com>
1275
76fb0465 1276 * lib-writ.adb, lib-writ.ads (Write_With_Lines): Add
1277 documentation and an extra conditional check for RCI
1278 units so that generated ali files will list the spec
1279 only instead of a body when a body is not found.
902071d1 1280
65a33d4a 12812019-01-04 Eric Botcazou <ebotcazou@adacore.com>
1282
1283 * gnatvsn.ads: Bump copyright year.
1284
3d8932fd 12852019-01-01 Jakub Jelinek <jakub@redhat.com>
8e8f6434 1286
fbd26352 1287 Update copyright years.
1288
277184bc 1289 * gnat_ugn.texi: Bump @copying's copyright year.
1290 * gnat_rm.texi: Likewise.
7dfbd804 1291\f
3d8932fd 1292Copyright (C) 2019 Free Software Foundation, Inc.
7dfbd804 1293
1294Copying and distribution of this file, with or without modification,
1295are permitted in any medium without royalty provided the copyright
1296notice and this notice are preserved.